diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..be06905 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,14 @@ +.git +.venv +venv +data/ +node_modules/ +frontend/node_modules/ +frontend/dist/ +.pytest_cache/ +.coverage +.coverage.* +htmlcov/ +*.pyc +__pycache__/ +*.log diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index 5c35a81..7ad7a93 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -39,7 +39,7 @@ jobs: - name: Set up Node.js 20 uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 22 cache: 'npm' cache-dependency-path: frontend/package-lock.json diff --git a/.gitignore b/.gitignore index d7baf99..53bcb05 100644 --- a/.gitignore +++ b/.gitignore @@ -11,6 +11,6 @@ venv/ htmlcov/ *.log node_modules/ -.vitepress/dist/ -.vitepress/cache/ -dist/ +docs/.vitepress/dist/ +docs/.vitepress/cache/ +/dist/ diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index ff30988..ac299d1 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -1,4 +1,4 @@ -# Architecture: ContextCortex (v2.17.0) +# Architecture: ContextCortex (v2.17.1) ContextCortex provides fast, local, syntax-aware semantic and hybrid search over codebases, git repositories, markdown notes, architecture documents, and system documentation. It is built natively on the **Model Context Protocol (MCP) SDK 2.0.0+** using `FastMCP`, with an integrated FastAPI web engine, real-time diagnostic logging, pluggable relational and vector store backends (PostgreSQL 16 with pgvector, Qdrant, ChromaDB, and SQLite), automatic polling daemons, multi-provider webhooks, interactive dependency topology graph explorer, RFC 9728 OAuth 2.1 Protected Resource Server, 3-tier API key RBAC, and a React 19 administrative dashboard. diff --git a/DEVELOPER_DOCS.md b/DEVELOPER_DOCS.md index c0b434c..83d62ce 100644 --- a/DEVELOPER_DOCS.md +++ b/DEVELOPER_DOCS.md @@ -1,4 +1,4 @@ -# Developer Documentation: ContextCortex (v2.17.0) +# Developer Documentation: ContextCortex (v2.17.1) This document provides instructions for developing, testing, configuring, and running ContextCortex locally. diff --git a/Dockerfile b/Dockerfile index 2c8b8ae..8afdb0c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,14 @@ -FROM python:3.11-slim +# Stage 1: Build Frontend +FROM node:22-alpine AS frontend-builder +WORKDIR /app/frontend +RUN apk add --no-cache git +COPY frontend/package*.json ./ +RUN npm ci +COPY frontend/ ./ +RUN npm run build +# Stage 2: Runtime Environment +FROM python:3.11-slim WORKDIR /app RUN apt-get update && apt-get install -y --no-install-recommends \ @@ -14,6 +23,8 @@ COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt COPY . . +COPY --from=frontend-builder /app/frontend/dist ./frontend/dist +COPY --from=frontend-builder /app/frontend/dist ./www EXPOSE 3000 diff --git a/README.md b/README.md index f728056..0dfbf56 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# ContextCortex (v2.17.0) +# ContextCortex (v2.17.1) [![Build and Publish Docker Image](https://github.com/spelech/contextcortex/actions/workflows/docker-publish.yml/badge.svg)](https://github.com/spelech/contextcortex/actions/workflows/docker-publish.yml) diff --git a/REQUIREMENTS.md b/REQUIREMENTS.md index c1d45f5..51e81d5 100644 --- a/REQUIREMENTS.md +++ b/REQUIREMENTS.md @@ -1,8 +1,8 @@ -# Software Requirements Specification: ContextCortex (v2.17.0) +# Software Requirements Specification: ContextCortex (v2.17.1) > **Note:** This document is automatically generated and verified against the live test suite by `scripts/generate_requirements.py` and `tests/backend/test_requirements_sync.py`. -**Test Verification Baseline:** **1032 Automated Tests** (679 Pytest Backend + 303 Vitest Frontend + 50 Playwright E2E). +**Test Verification Baseline:** **1033 Automated Tests** (680 Pytest Backend + 303 Vitest Frontend + 50 Playwright E2E). --- @@ -573,10 +573,11 @@ classDiagram - `test_git_syncer_nonexistent_repo` - `test_git_progress_tracker_pending_cancellation` -#### `tests/backend/test_health_check_status.py` (3 tests) +#### `tests/backend/test_health_check_status.py` (4 tests) - `test_api_stats_reports_healthy_when_store_is_healthy` - `test_api_stats_reports_unhealthy_when_store_fails` - `test_api_stats_reports_healthy_with_real_embedded_store` - _Verify /admin/api/stats health check against a real embedded Qdrant vector store without mocks._ +- `test_main_app_favicon_and_root_redirect` - _Verify root app redirect, favicon routes, and static asset handling._ #### `tests/backend/test_indexer_and_embeddings.py` (25 tests) - `test_embeddings_generation` diff --git a/app/services/git_manager.py b/app/services/git_manager.py index 29e2d9e..895b8a2 100644 --- a/app/services/git_manager.py +++ b/app/services/git_manager.py @@ -137,7 +137,8 @@ def sanitize_url_for_logging(url: str) -> str: **os.environ, "GIT_TERMINAL_PROMPT": "0", "GIT_ASKPASS": "", - "SSH_ASKPASS": "" + "SSH_ASKPASS": "", + "GIT_CONFIG_PARAMETERS": "'http.https://github.com/.extraheader='", } def get_remote_head_sha( diff --git a/docs/TEST_COVERAGE.md b/docs/TEST_COVERAGE.md index 1fbaa75..6cd4a4b 100644 --- a/docs/TEST_COVERAGE.md +++ b/docs/TEST_COVERAGE.md @@ -1,4 +1,4 @@ -# Test Coverage Report: ContextCortex (v2.17.0) +# Test Coverage Report: ContextCortex (v2.17.1) This document provides comprehensive test coverage metrics and verification baselines for ContextCortex following the modular architectural restructuring, Codebase Navigator implementation, and test suite expansion. diff --git a/docs/reference/rest-api.md b/docs/reference/rest-api.md index 3ecbd44..f11070d 100644 --- a/docs/reference/rest-api.md +++ b/docs/reference/rest-api.md @@ -16,7 +16,7 @@ All administrative routes are prefixed with `/admin/api`. ```json { "status": "ok", - "version": "2.17.0", + "version": "2.17.1", "database": "connected", "vector_store": "healthy" } diff --git a/docs/screenshots/contextcortex-ui-v2.17.1.png b/docs/screenshots/contextcortex-ui-v2.17.1.png new file mode 100644 index 0000000..a0b0322 Binary files /dev/null and b/docs/screenshots/contextcortex-ui-v2.17.1.png differ diff --git a/frontend/.oxlintrc.json b/frontend/.oxlintrc.json index 6fa991d..60721ab 100644 --- a/frontend/.oxlintrc.json +++ b/frontend/.oxlintrc.json @@ -4,5 +4,6 @@ "rules": { "react/rules-of-hooks": "error", "react/only-export-components": ["warn", { "allowConstantExport": true }] - } + }, + "ignorePatterns": ["dist/**"] } diff --git a/frontend/dist/assets/_basePickBy-Cj4iqGU4.js b/frontend/dist/assets/_basePickBy-Cj4iqGU4.js new file mode 100644 index 0000000..f0d82ee --- /dev/null +++ b/frontend/dist/assets/_basePickBy-Cj4iqGU4.js @@ -0,0 +1 @@ +import{$ as e,A as t,C as n,D as r,E as i,G as a,H as o,I as s,K as c,M as l,N as u,P as d,R as f,S as p,T as m,U as ee,V as h,X as g,Y as _,ct as v,dt as y,et as te,f as ne,ft as re,h as b,j as ie,k as ae,lt as oe,mt as se,nt as x,pt as ce,q as le,st as S,ut as ue,v as de,w as fe,z as pe}from"./_baseUniq-DR4vVjyC.js";var me=/\s/;function he(e){for(var t=e.length;t--&&me.test(e.charAt(t)););return t}var ge=/^\s+/;function _e(e){return e&&e.slice(0,he(e)+1).replace(ge,``)}var C=NaN,ve=/^[-+]0x[0-9a-f]+$/i,ye=/^0b[01]+$/i,be=/^0o[0-7]+$/i,xe=parseInt;function Se(e){if(typeof e==`number`)return e;if(ue(e))return C;if(S(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=S(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=_e(e);var n=ye.test(e);return n||be.test(e)?xe(e.slice(2),n?2:8):ve.test(e)?C:+e}var w=1/0,Ce=17976931348623157e292;function T(e){return e?(e=Se(e),e===w||e===-w?(e<0?-1:1)*Ce:e===e?e:0):e===0?e:0}function E(e){var t=T(e),n=t%1;return t===t?n?t-n:t:0}var D=Object.create,we=function(){function e(){}return function(t){if(!S(t))return{};if(D)return D(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function O(e,t){var n=-1,r=e.length;for(t||=Array(r);++n1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&M(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r2?t[2]:void 0;for(i&&M(t[0],t[1],i)&&(r=1);++n-1?i[a?t[o]:o]:void 0}}var Wt=Math.max;function Gt(t,n,r){var i=t==null?0:t.length;if(!i)return-1;var a=r==null?0:E(r);return a<0&&(a=Wt(i+a,0)),e(t,b(n,3),a)}var Kt=Ut(Gt);function qt(e,t){var n=-1,r=c(e)?Array(e.length):[];return ne(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function Jt(e,t){return(v(e)?oe:qt)(e,b(t,3))}var Yt=Object.prototype.hasOwnProperty;function Xt(e,t){return e!=null&&Yt.call(e,t)}function Zt(e,t){return e!=null&&de(e,t,Xt)}var Qt=`[object String]`;function $t(e){return typeof e==`string`||!v(e)&&y(e)&&re(e)==Qt}function en(e,t,n,r){if(!S(e))return e;t=d(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i0){if(++t>=we)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Oe(e){return function(){return e}}var T=function(){try{var e=C(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),ke=De(T?function(e,t){return T(e,`toString`,{configurable:!0,enumerable:!1,value:Oe(t),writable:!0})}:x);function Ae(e,t){for(var n=-1,r=e==null?0:e.length;++n-1}var Ie=9007199254740991,Le=/^(?:0|[1-9]\d*)$/;function E(e,t){var n=typeof e;return t??=Ie,!!t&&(n==`number`||n!=`symbol`&&Le.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=Ve}function k(e){return e!=null&&O(e.length)&&!ce(e)}var He=Object.prototype;function A(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||He)}function Ue(e,t){for(var n=-1,r=Array(e);++n-1}function Zt(e,t){var n=this.__data__,r=B(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function V(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t0&&n(s)?t>1?yn(s,t-1,n,r,i):gn(i,s):r||(i[i.length]=s)}return i}function bn(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++is))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&er?new Z:void 0;for(a.set(e,t),a.set(t,e);++d=fi){var l=t?null:di(e);if(l)return rr(l);o=!1,i=Qn,c=new Z}else c=t?[]:s;outer:for(;++r{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformAlternation`),u=t(e=>{let t=e.elements.map(f);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformConcatenation`),d=t(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{min:t?parseInt(t,10):0,max:n?parseInt(n,10):1/0}}let t=parseInt(e,10);return{min:t,max:t}},`parseRepeat`),f=t(e=>{let t=p(e.primary);if(!e.repeat)return t;let{min:n,max:r}=d(e.repeat);return n===0&&r===1?{type:`optional`,element:t}:{type:`repetition`,element:t,min:n,max:r}},`transformElement`),p=t(e=>{switch(e.$type){case`AbnfStringLiteral`:return{type:`terminal`,value:e.value};case`AbnfNumVal`:return{type:`terminal`,value:e.value};case`AbnfRuleName`:return{type:`nonterminal`,name:e.name};case`AbnfGroup`:return l(e.element);case`AbnfOptionalGroup`:return{type:`optional`,element:l(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},`transformPrimary`),m=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:t(t=>{o.clear(),e.debug(`[ABNF Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[ABNF Parser] Parsed rules:`,i.rules.length),h(i),e.debug(`[ABNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/arc-BJA87daU.js b/frontend/dist/assets/arc-BJA87daU.js new file mode 100644 index 0000000..7ed8f9f --- /dev/null +++ b/frontend/dist/assets/arc-BJA87daU.js @@ -0,0 +1 @@ +import{n as e,t}from"./path-fybaL0A-.js";import{a as n,c as r,d as i,f as a,i as o,l as s,m as c,n as l,o as u,p as d,r as f,u as p}from"./dist-Bfr8PhAA.js";function m(e){return e.innerRadius}function h(e){return e.outerRadius}function g(e){return e.startAngle}function _(e){return e.endAngle}function v(e){return e&&e.padAngle}function y(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<1e-12))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function b(e,t,n,r,i,a,o){var c=e-n,l=t-r,u=(o?a:-a)/d(c*c+l*l),f=u*l,p=-u*c,m=e+f,h=t+p,g=n+f,_=r+p,v=(m+g)/2,y=(h+_)/2,b=g-m,x=_-h,S=b*b+x*x,C=i-a,w=m*_-g*h,T=(x<0?-1:1)*d(s(0,C*C*S-w*w)),E=(w*x-b*T)/S,D=(-w*b-x*T)/S,O=(w*x+b*T)/S,k=(-w*b+x*T)/S,A=E-v,j=D-y,M=O-v,N=k-y;return A*A+j*j>M*M+N*N&&(E=O,D=k),{cx:E,cy:D,x01:-f,y01:-p,x11:E*(i/C-1),y11:D*(i/C-1)}}function x(){var s=m,x=h,S=e(0),C=null,w=g,T=_,E=v,D=null,O=t(k);function k(){var e,t,m=+s.apply(this,arguments),h=+x.apply(this,arguments),g=w.apply(this,arguments)-r,_=T.apply(this,arguments)-r,v=l(_-g),k=_>g;if(D||=e=O(),h1e-12))D.moveTo(0,0);else if(v>c-1e-12)D.moveTo(h*u(g),h*a(g)),D.arc(0,0,h,g,_,!k),m>1e-12&&(D.moveTo(m*u(_),m*a(_)),D.arc(0,0,m,_,g,k));else{var A=g,j=_,M=g,N=_,P=v,F=v,I=E.apply(this,arguments)/2,L=I>1e-12&&(C?+C.apply(this,arguments):d(m*m+h*h)),R=p(l(h-m)/2,+S.apply(this,arguments)),z=R,B=R,V,H;if(L>1e-12){var U=o(L/m*a(I)),W=o(L/h*a(I));(P-=U*2)>1e-12?(U*=k?1:-1,M+=U,N-=U):(P=0,M=N=(g+_)/2),(F-=W*2)>1e-12?(W*=k?1:-1,A+=W,j-=W):(F=0,A=j=(g+_)/2)}var G=h*u(A),K=h*a(A),q=m*u(N),J=m*a(N);if(R>1e-12){var Y=h*u(j),X=h*a(j),Z=m*u(M),Q=m*a(M),$;if(v1e-12?B>1e-12?(V=b(Z,Q,G,K,h,B,k),H=b(Y,X,q,J,h,B,k),D.moveTo(V.cx+V.x01,V.cy+V.y01),B1e-12)||!(P>1e-12)?D.lineTo(q,J):z>1e-12?(V=b(q,J,Y,X,m,-z,k),H=b(G,K,Z,Q,m,-z,k),D.lineTo(V.cx+V.x01,V.cy+V.y01),z{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r():typeof define==`function`&&define.amd?define([],r):typeof e==`object`?e.layoutBase=r():n.layoutBase=r()})(e,function(){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=28)})([(function(e,t,n){function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,e.exports=r}),(function(e,t,n){var r=n(2),i=n(8),a=n(9);function o(e,t,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=e,this.target=t}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];o.prototype.getSource=function(){return this.source},o.prototype.getTarget=function(){return this.target},o.prototype.isInterGraph=function(){return this.isInterGraph},o.prototype.getLength=function(){return this.length},o.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},o.prototype.getBendpoints=function(){return this.bendpoints},o.prototype.getLca=function(){return this.lca},o.prototype.getSourceInLca=function(){return this.sourceInLca},o.prototype.getTargetInLca=function(){return this.targetInLca},o.prototype.getOtherEnd=function(e){if(this.source===e)return this.target;if(this.target===e)return this.source;throw`Node is not incident with this edge`},o.prototype.getOtherEndInGraph=function(e,t){for(var n=this.getOtherEnd(e),r=t.getGraphManager().getRoot();;){if(n.getOwner()==t)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},o.prototype.updateLength=function(){var e=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),e),this.isOverlapingSourceAndTarget||(this.lengthX=e[0]-e[2],this.lengthY=e[1]-e[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},o.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},e.exports=o}),(function(e,t,n){function r(e){this.vGraphObject=e}e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(13),o=n(0),s=n(16),c=n(5);function l(e,t,n,o){n==null&&o==null&&(o=t),r.call(this,o),e.graphManager!=null&&(e=e.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=o,this.edges=[],this.graphManager=e,this.rect=n!=null&&t!=null?new a(t.x,t.y,n.width,n.height):new a}for(var u in l.prototype=Object.create(r.prototype),r)l[u]=r[u];l.prototype.getEdges=function(){return this.edges},l.prototype.getChild=function(){return this.child},l.prototype.getOwner=function(){return this.owner},l.prototype.getWidth=function(){return this.rect.width},l.prototype.setWidth=function(e){this.rect.width=e},l.prototype.getHeight=function(){return this.rect.height},l.prototype.setHeight=function(e){this.rect.height=e},l.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},l.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},l.prototype.getCenter=function(){return new c(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},l.prototype.getLocation=function(){return new c(this.rect.x,this.rect.y)},l.prototype.getRect=function(){return this.rect},l.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},l.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},l.prototype.setRect=function(e,t){this.rect.x=e.x,this.rect.y=e.y,this.rect.width=t.width,this.rect.height=t.height},l.prototype.setCenter=function(e,t){this.rect.x=e-this.rect.width/2,this.rect.y=t-this.rect.height/2},l.prototype.setLocation=function(e,t){this.rect.x=e,this.rect.y=t},l.prototype.moveBy=function(e,t){this.rect.x+=e,this.rect.y+=t},l.prototype.getEdgeListToNode=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.target==e){if(r.source!=n)throw`Incorrect edge source!`;t.push(r)}}),t},l.prototype.getEdgesBetween=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.source!=n&&r.target!=n)throw`Incorrect edge source and/or target`;(r.target==e||r.source==e)&&t.push(r)}),t},l.prototype.getNeighborsList=function(){var e=new Set,t=this;return t.edges.forEach(function(n){if(n.source==t)e.add(n.target);else{if(n.target!=t)throw`Incorrect incidency!`;e.add(n.source)}}),e},l.prototype.withChildren=function(){var e=new Set,t,n;if(e.add(this),this.child!=null)for(var r=this.child.getNodes(),i=0;it?(this.rect.x-=(this.labelWidth-t)/2,this.setWidth(this.labelWidth)):this.labelPosHorizontal==`right`&&this.setWidth(t+this.labelWidth)),this.labelHeight&&(this.labelPosVertical==`top`?(this.rect.y-=this.labelHeight,this.setHeight(n+this.labelHeight)):this.labelPosVertical==`center`&&this.labelHeight>n?(this.rect.y-=(this.labelHeight-n)/2,this.setHeight(this.labelHeight)):this.labelPosVertical==`bottom`&&this.setHeight(n+this.labelHeight))}}},l.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw`assert failed`;return this.inclusionTreeDepth},l.prototype.transform=function(e){var t=this.rect.x;t>o.WORLD_BOUNDARY?t=o.WORLD_BOUNDARY:t<-o.WORLD_BOUNDARY&&(t=-o.WORLD_BOUNDARY);var n=this.rect.y;n>o.WORLD_BOUNDARY?n=o.WORLD_BOUNDARY:n<-o.WORLD_BOUNDARY&&(n=-o.WORLD_BOUNDARY);var r=new c(t,n),i=e.inverseTransformPoint(r);this.setLocation(i.x,i.y)},l.prototype.getLeft=function(){return this.rect.x},l.prototype.getRight=function(){return this.rect.x+this.rect.width},l.prototype.getTop=function(){return this.rect.y},l.prototype.getBottom=function(){return this.rect.y+this.rect.height},l.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},e.exports=l}),(function(e,t,n){var r=n(0);function i(){}for(var a in r)i[a]=r[a];i.MAX_ITERATIONS=2500,i.DEFAULT_EDGE_LENGTH=50,i.DEFAULT_SPRING_STRENGTH=.45,i.DEFAULT_REPULSION_STRENGTH=4500,i.DEFAULT_GRAVITY_STRENGTH=.4,i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,i.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,i.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,i.COOLING_ADAPTATION_FACTOR=.33,i.ADAPTATION_LOWER_NODE_LIMIT=1e3,i.ADAPTATION_UPPER_NODE_LIMIT=5e3,i.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,i.MAX_NODE_DISPLACEMENT=i.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,i.MIN_REPULSION_DIST=i.DEFAULT_EDGE_LENGTH/10,i.CONVERGENCE_CHECK_PERIOD=100,i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,i.MIN_EDGE_LENGTH=1,i.GRID_CALCULATION_CHECK_PERIOD=10,e.exports=i}),(function(e,t,n){function r(e,t){e==null&&t==null?(this.x=0,this.y=0):(this.x=e,this.y=t)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(e){this.x=e},r.prototype.setY=function(e){this.y=e},r.prototype.getDifference=function(e){return new DimensionD(this.x-e.x,this.y-e.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(e){return this.x+=e.width,this.y+=e.height,this},e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(0),o=n(7),s=n(3),c=n(1),l=n(13),u=n(12),d=n(11);function f(e,t,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=e,t!=null&&t instanceof o?this.graphManager=t:t!=null&&t instanceof Layout&&(this.graphManager=t.graphManager)}for(var p in f.prototype=Object.create(r.prototype),r)f[p]=r[p];f.prototype.getNodes=function(){return this.nodes},f.prototype.getEdges=function(){return this.edges},f.prototype.getGraphManager=function(){return this.graphManager},f.prototype.getParent=function(){return this.parent},f.prototype.getLeft=function(){return this.left},f.prototype.getRight=function(){return this.right},f.prototype.getTop=function(){return this.top},f.prototype.getBottom=function(){return this.bottom},f.prototype.isConnected=function(){return this.isConnected},f.prototype.add=function(e,t,n){if(t==null&&n==null){var r=e;if(this.graphManager==null)throw`Graph has no graph mgr!`;if(this.getNodes().indexOf(r)>-1)throw`Node already in graph!`;return r.owner=this,this.getNodes().push(r),r}var i=e;if(!(this.getNodes().indexOf(t)>-1&&this.getNodes().indexOf(n)>-1))throw`Source or target not in graph!`;if(t.owner!=n.owner||t.owner!=this)throw`Both owners must be this graph!`;return t.owner==n.owner?(i.source=t,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),t.edges.push(i),n!=t&&n.edges.push(i),i):null},f.prototype.remove=function(e){var t=e;if(e instanceof s){if(t==null)throw`Node is null!`;if(t.owner==null||t.owner!=this)throw`Owner graph is invalid!`;if(this.graphManager==null)throw`Owner graph manager is invalid!`;for(var n=t.edges.slice(),r,i=n.length,a=0;a-1&&u>-1))throw`Source and/or target doesn't know this edge!`;r.source.edges.splice(l,1),r.target!=r.source&&r.target.edges.splice(u,1);var o=r.source.owner.getEdges().indexOf(r);if(o==-1)throw`Not in owner's edge list!`;r.source.owner.getEdges().splice(o,1)}},f.prototype.updateLeftTop=function(){for(var e=i.MAX_VALUE,t=i.MAX_VALUE,n,r,a,o=this.getNodes(),s=o.length,c=0;cn&&(e=n),t>r&&(t=r)}return e==i.MAX_VALUE?null:(a=o[0].getParent().paddingLeft==null?this.margin:o[0].getParent().paddingLeft,this.left=t-a,this.top=e-a,new u(this.left,this.top))},f.prototype.updateBounds=function(e){for(var t=i.MAX_VALUE,n=-i.MAX_VALUE,r=i.MAX_VALUE,a=-i.MAX_VALUE,o,s,c,u,d,f=this.nodes,p=f.length,m=0;mo&&(t=o),nc&&(r=c),ao&&(t=o),nc&&(r=c),a=this.nodes.length){var c=0;n.forEach(function(t){t.owner==e&&c++}),c==this.nodes.length&&(this.isConnected=!0)}},e.exports=f}),(function(e,t,n){var r,i=n(1);function a(e){r=n(6),this.layout=e,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var e=this.layout.newGraph(),t=this.layout.newNode(null),n=this.add(e,t);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(e,t,n,r,i){if(n==null&&r==null&&i==null){if(e==null)throw`Graph is null!`;if(t==null)throw`Parent node is null!`;if(this.graphs.indexOf(e)>-1)throw`Graph already in this graph mgr!`;if(this.graphs.push(e),e.parent!=null)throw`Already has a parent!`;if(t.child!=null)throw`Already has a child!`;return e.parent=t,t.child=e,e}i=n,r=t,n=e;var a=r.getOwner(),o=i.getOwner();if(a==null||a.getGraphManager()!=this)throw`Source not in this graph mgr!`;if(o==null||o.getGraphManager()!=this)throw`Target not in this graph mgr!`;if(a==o)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw`Edge already in inter-graph edge list!`;if(this.edges.push(n),n.source==null||n.target==null)throw`Edge source and/or target is null!`;if(n.source.edges.indexOf(n)!=-1||n.target.edges.indexOf(n)!=-1)throw`Edge already in source and/or target incidency list!`;return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(e){if(e instanceof r){var t=e;if(t.getGraphManager()!=this)throw`Graph not in this graph mgr`;if(!(t==this.rootGraph||t.parent!=null&&t.parent.graphManager==this))throw`Invalid parent node!`;var n=[];n=n.concat(t.getEdges());for(var a,o=n.length,s=0;s=t.getRight()?n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight()):t.getX()<=e.getX()&&t.getRight()>=e.getRight()&&(n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight())),e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()?n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()):t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()&&(n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()));var a=Math.abs((t.getCenterY()-e.getCenterY())/(t.getCenterX()-e.getCenterX()));t.getCenterY()===e.getCenterY()&&t.getCenterX()===e.getCenterX()&&(a=1);var o=a*n[0],s=n[1]/a;n[0]o)return n[0]=r,n[1]=c,n[2]=a,n[3]=y,!1;if(ia)return n[0]=s,n[1]=i,n[2]=_,n[3]=o,!1;if(ra?(n[0]=u,n[1]=d,C=!0):(n[0]=l,n[1]=c,C=!0):T===D&&(r>a?(n[0]=s,n[1]=c,C=!0):(n[0]=f,n[1]=d,C=!0)),-E===D?a>r?(n[2]=v,n[3]=y,w=!0):(n[2]=_,n[3]=g,w=!0):E===D&&(a>r?(n[2]=h,n[3]=g,w=!0):(n[2]=b,n[3]=y,w=!0)),C&&w)return!1;if(r>a?i>o?(O=this.getCardinalDirection(T,D,4),k=this.getCardinalDirection(E,D,2)):(O=this.getCardinalDirection(-T,D,3),k=this.getCardinalDirection(-E,D,1)):i>o?(O=this.getCardinalDirection(-T,D,1),k=this.getCardinalDirection(-E,D,3)):(O=this.getCardinalDirection(T,D,2),k=this.getCardinalDirection(E,D,4)),!C)switch(O){case 1:j=c,A=r+-m/D,n[0]=A,n[1]=j;break;case 2:A=f,j=i+p*D,n[0]=A,n[1]=j;break;case 3:j=d,A=r+m/D,n[0]=A,n[1]=j;break;case 4:A=u,j=i+-p*D,n[0]=A,n[1]=j}if(!w)switch(k){case 1:N=g,M=a+-S/D,n[2]=M,n[3]=N;break;case 2:M=b,N=o+x*D,n[2]=M,n[3]=N;break;case 3:N=y,M=a+S/D,n[2]=M,n[3]=N;break;case 4:M=v,N=o+-x*D,n[2]=M,n[3]=N}}return!1},i.getCardinalDirection=function(e,t,n){return e>t?n:1+n%4},i.getIntersection=function(e,t,n,i){if(i==null)return this.getIntersection2(e,t,n);var a=e.x,o=e.y,s=t.x,c=t.y,l=n.x,u=n.y,d=i.x,f=i.y,p=void 0,m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0;return h=c-o,_=a-s,y=s*o-a*c,g=f-u,v=l-d,b=d*u-l*f,x=h*v-g*_,x===0?null:(p=(_*b-v*y)/x,m=(g*y-h*b)/x,new r(p,m))},i.angleOfVector=function(e,t,n,r){var i=void 0;return e===n?i=r=0){var u=(-c+Math.sqrt(c*c-4*s*l))/(2*s),d=(-c-Math.sqrt(c*c-4*s*l))/(2*s);return u>=0&&u<=1?[u]:d>=0&&d<=1?[d]:null}return null},i.HALF_PI=.5*Math.PI,i.ONE_AND_HALF_PI=1.5*Math.PI,i.TWO_PI=2*Math.PI,i.THREE_PI=3*Math.PI,e.exports=i}),(function(e,t,n){function r(){}r.sign=function(e){return e>0?1:e<0?-1:0},r.floor=function(e){return e<0?Math.ceil(e):Math.floor(e)},r.ceil=function(e){return e<0?Math.floor(e):Math.ceil(e)},e.exports=r}),(function(e,t,n){function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n0&&t;){for(s.push(l[0]);s.length>0&&t;){var u=s[0];s.splice(0,1),o.add(u);for(var d=u.getEdges(),a=0;a-1&&l.splice(h,1)}o=new Set,c=new Map}}return e},f.prototype.createDummyNodesForBendpoints=function(e){for(var t=[],n=e.source,r=this.graphManager.calcLowestCommonAncestor(e.source,e.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&t.splice(d,1),s.getNeighborsList().forEach(function(e){if(n.indexOf(e)<0){var t=r.get(e)-1;t==1&&l.push(e),r.set(e,t)}})}n=n.concat(l),(t.length==1||t.length==2)&&(i=!0,a=t[0])}return a},f.prototype.setGraphManager=function(e){this.graphManager=e},e.exports=f}),(function(e,t,n){function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=Math.sin(r.seed++)*1e4,r.x-Math.floor(r.x)},e.exports=r}),(function(e,t,n){var r=n(5);function i(e,t){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(e){this.lworldExtX=e},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(e){this.lworldExtY=e},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},i.prototype.transformX=function(e){var t=0,n=this.lworldExtX;return n!=0&&(t=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/n),t},i.prototype.transformY=function(e){var t=0,n=this.lworldExtY;return n!=0&&(t=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/n),t},i.prototype.inverseTransformX=function(e){var t=0,n=this.ldeviceExtX;return n!=0&&(t=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/n),t},i.prototype.inverseTransformY=function(e){var t=0,n=this.ldeviceExtY;return n!=0&&(t=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/n),t},i.prototype.inverseTransformPoint=function(e){return new r(this.inverseTransformX(e.x),this.inverseTransformY(e.y))},e.exports=i}),(function(e,t,n){function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);ta.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*a.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-a.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT_INCREMENTAL):(this.coolingFactor=e>a.ADAPTATION_LOWER_NODE_LIMIT?Math.max(a.COOLING_ADAPTATION_FACTOR,1-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*(1-a.COOLING_ADAPTATION_FACTOR)):1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.displacementThresholdPerNode=3*a.DEFAULT_EDGE_LENGTH/100,this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var e=this.getAllEdges(),t,n=0;n0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n,r,i,o,s=this.getAllNodes(),c;if(this.useFRGridVariant)for(this.totalIterations%a.GRID_CALCULATION_CHECK_PERIOD==1&&e&&this.updateGrid(),c=new Set,n=0;nc||s>c)&&(e.gravitationForceX=-this.gravityConstant*i,e.gravitationForceY=-this.gravityConstant*a)):(c=t.getEstimatedSize()*this.compoundGravityRangeFactor,(o>c||s>c)&&(e.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,e.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant))},l.prototype.isConverged=function(){var e,t=!1;return this.totalIterations>this.maxIterations/3&&(t=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),e=this.totalDisplacement=c.length||u>=c[0].length)){for(var d=0;de}}]),e}()}),(function(e,t,n){function r(){}r.svd=function(e){this.U=null,this.V=null,this.s=null,this.m=0,this.n=0,this.m=e.length,this.n=e[0].length;var t=Math.min(this.m,this.n);this.s=function(e){for(var t=[];e-->0;)t.push(0);return t}(Math.min(this.m+1,this.n)),this.U=function(e){return function e(t){if(t.length==0)return 0;for(var n=[],r=0;r0;)t.push(0);return t}(this.n),i=function(e){for(var t=[];e-->0;)t.push(0);return t}(this.m),a=!0,o=!0,s=Math.min(this.m-1,this.n),c=Math.max(0,Math.min(this.n-2,this.m)),l=0;l=0;k--)if(this.s[k]!==0){for(var A=k+1;A=0;L--){if(function(e,t){return e&&t}(L0;){var U=void 0,W=void 0;for(U=E-2;U>=-1&&U!==-1;U--)if(Math.abs(n[U])<=re+ne*(Math.abs(this.s[U])+Math.abs(this.s[U+1]))){n[U]=0;break}if(U===E-2)W=4;else{var G=void 0;for(G=E-1;G>=U&&G!==U;G--){var ie=(G===E?0:Math.abs(n[G]))+(G===U+1?0:Math.abs(n[G-1]));if(Math.abs(this.s[G])<=re+ne*ie){this.s[G]=0;break}}G===U?W=3:G===E-1?W=1:(W=2,U=G)}switch(U++,W){case 1:var K=n[E-2];n[E-2]=0;for(var q=E-2;q>=U;q--){var ae=r.hypot(this.s[q],K),J=this.s[q]/ae,Y=K/ae;if(this.s[q]=ae,q!==U&&(K=-Y*n[q-1],n[q-1]=J*n[q-1]),o)for(var X=0;X=this.s[U+1]);){var De=this.s[U];if(this.s[U]=this.s[U+1],this.s[U+1]=De,o&&UMath.abs(t)?(n=t/e,n=Math.abs(e)*Math.sqrt(1+n*n)):t==0?n=0:(n=e/t,n=Math.abs(t)*Math.sqrt(1+n*n)),n},e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:1,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,e),this.sequence1=t,this.sequence2=n,this.match_score=r,this.mismatch_penalty=a,this.gap_penalty=o,this.iMax=t.length+1,this.jMax=n.length+1,this.grid=Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===e&&r.callback===t&&this.listeners.splice(n,1)}},i.emit=function(e,t){for(var n=0;n{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(D()):typeof define==`function`&&define.amd?define([`layout-base`],r):typeof e==`object`?e.coseBase=r(D()):n.coseBase=r(n.layoutBase)})(e,function(e){return(()=>{var t={45:((e,t,n)=>{var r={};r.layoutBase=n(551),r.CoSEConstants=n(806),r.CoSEEdge=n(767),r.CoSEGraph=n(880),r.CoSEGraphManager=n(578),r.CoSELayout=n(765),r.CoSENode=n(991),r.ConstraintHandler=n(902),e.exports=r}),806:((e,t,n)=>{var r=n(551).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,i.ENFORCE_CONSTRAINTS=!0,i.APPLY_LAYOUT=!0,i.RELAX_MOVEMENT_ON_CONSTRAINTS=!0,i.TREE_REDUCTION_ON_INCREMENTAL=!0,i.PURE_INCREMENTAL=i.DEFAULT_INCREMENTAL,e.exports=i}),767:((e,t,n)=>{var r=n(551).FDLayoutEdge;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),880:((e,t,n)=>{var r=n(551).LGraph;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),578:((e,t,n)=>{var r=n(551).LGraphManager;function i(e){r.call(this,e)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),765:((e,t,n)=>{var r=n(551).FDLayout,i=n(578),a=n(880),o=n(991),s=n(767),c=n(806),l=n(902),u=n(551).FDLayoutConstants,d=n(551).LayoutConstants,f=n(551).Point,p=n(551).PointD,m=n(551).DimensionD,h=n(551).Layout,g=n(551).Integer,_=n(551).IGeometry,v=n(551).LGraph,y=n(551).Transform,b=n(551).LinkedList;function x(){r.call(this),this.toBeTiled={},this.constraints={}}for(var S in x.prototype=Object.create(r.prototype),r)x[S]=r[S];x.prototype.newGraphManager=function(){var e=new i(this);return this.graphManager=e,e},x.prototype.newGraph=function(e){return new a(null,this.graphManager,e)},x.prototype.newNode=function(e){return new o(this.graphManager,e)},x.prototype.newEdge=function(e){return new s(null,null,e)},x.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.isSubLayout||(this.idealEdgeLength=c.DEFAULT_EDGE_LENGTH<10?10:c.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=c.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.gravityConstant=u.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=u.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=u.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=u.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1)},x.prototype.initSpringEmbedder=function(){r.prototype.initSpringEmbedder.call(this),this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/u.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=.04,this.coolingAdjuster=1},x.prototype.layout=function(){return d.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},x.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),!this.incremental){var e=this.getFlatForest();if(e.length>0)this.positionNodesRadially(e);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}else if(c.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n)}return Object.keys(this.constraints).length>0&&(l.handleConstraints(this),this.initConstraintVariables()),this.initSpringEmbedder(),c.APPLY_LAYOUT&&this.runSpringEmbedder(),!0},x.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}if(this.totalIterations%u.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0){if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),t=this.nodesWithGravity.filter(function(t){return e.has(t)});this.graphManager.setAllNodesToApplyGravitation(t),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=c.PURE_INCREMENTAL?u.DEFAULT_COOLING_FACTOR_INCREMENTAL/2:u.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0}this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=c.PURE_INCREMENTAL?u.DEFAULT_COOLING_FACTOR_INCREMENTAL/2*((100-this.afterGrowthIterations)/100):u.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},x.prototype.getPositionsData=function(){for(var e=this.graphManager.getAllNodes(),t={},n=0;n0&&this.updateDisplacements();for(var n=0;n0&&(r.fixedNodeWeight=a)}}if(this.constraints.relativePlacementConstraint){var o=new Map,s=new Map;if(this.dummyToNodeForVerticalAlignment=new Map,this.dummyToNodeForHorizontalAlignment=new Map,this.fixedNodesOnHorizontal=new Set,this.fixedNodesOnVertical=new Set,this.fixedNodeSet.forEach(function(t){e.fixedNodesOnHorizontal.add(t),e.fixedNodesOnVertical.add(t)}),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical)for(var l=this.constraints.alignmentConstraint.vertical,n=0;n=2*e.length/3;r--)t=Math.floor(Math.random()*(r+1)),n=e[r],e[r]=e[t],e[t]=n;return e},this.nodesInRelativeHorizontal=[],this.nodesInRelativeVertical=[],this.nodeToRelativeConstraintMapHorizontal=new Map,this.nodeToRelativeConstraintMapVertical=new Map,this.nodeToTempPositionMapHorizontal=new Map,this.nodeToTempPositionMapVertical=new Map,this.constraints.relativePlacementConstraint.forEach(function(t){if(t.left){var n=o.has(t.left)?o.get(t.left):t.left,r=o.has(t.right)?o.get(t.right):t.right;e.nodesInRelativeHorizontal.includes(n)||(e.nodesInRelativeHorizontal.push(n),e.nodeToRelativeConstraintMapHorizontal.set(n,[]),e.dummyToNodeForVerticalAlignment.has(n)?e.nodeToTempPositionMapHorizontal.set(n,e.idToNodeMap.get(e.dummyToNodeForVerticalAlignment.get(n)[0]).getCenterX()):e.nodeToTempPositionMapHorizontal.set(n,e.idToNodeMap.get(n).getCenterX())),e.nodesInRelativeHorizontal.includes(r)||(e.nodesInRelativeHorizontal.push(r),e.nodeToRelativeConstraintMapHorizontal.set(r,[]),e.dummyToNodeForVerticalAlignment.has(r)?e.nodeToTempPositionMapHorizontal.set(r,e.idToNodeMap.get(e.dummyToNodeForVerticalAlignment.get(r)[0]).getCenterX()):e.nodeToTempPositionMapHorizontal.set(r,e.idToNodeMap.get(r).getCenterX())),e.nodeToRelativeConstraintMapHorizontal.get(n).push({right:r,gap:t.gap}),e.nodeToRelativeConstraintMapHorizontal.get(r).push({left:n,gap:t.gap})}else{var i=s.has(t.top)?s.get(t.top):t.top,a=s.has(t.bottom)?s.get(t.bottom):t.bottom;e.nodesInRelativeVertical.includes(i)||(e.nodesInRelativeVertical.push(i),e.nodeToRelativeConstraintMapVertical.set(i,[]),e.dummyToNodeForHorizontalAlignment.has(i)?e.nodeToTempPositionMapVertical.set(i,e.idToNodeMap.get(e.dummyToNodeForHorizontalAlignment.get(i)[0]).getCenterY()):e.nodeToTempPositionMapVertical.set(i,e.idToNodeMap.get(i).getCenterY())),e.nodesInRelativeVertical.includes(a)||(e.nodesInRelativeVertical.push(a),e.nodeToRelativeConstraintMapVertical.set(a,[]),e.dummyToNodeForHorizontalAlignment.has(a)?e.nodeToTempPositionMapVertical.set(a,e.idToNodeMap.get(e.dummyToNodeForHorizontalAlignment.get(a)[0]).getCenterY()):e.nodeToTempPositionMapVertical.set(a,e.idToNodeMap.get(a).getCenterY())),e.nodeToRelativeConstraintMapVertical.get(i).push({bottom:a,gap:t.gap}),e.nodeToRelativeConstraintMapVertical.get(a).push({top:i,gap:t.gap})}});else{var d=new Map,f=new Map;this.constraints.relativePlacementConstraint.forEach(function(e){if(e.left){var t=o.has(e.left)?o.get(e.left):e.left,n=o.has(e.right)?o.get(e.right):e.right;d.has(t)?d.get(t).push(n):d.set(t,[n]),d.has(n)?d.get(n).push(t):d.set(n,[t])}else{var r=s.has(e.top)?s.get(e.top):e.top,i=s.has(e.bottom)?s.get(e.bottom):e.bottom;f.has(r)?f.get(r).push(i):f.set(r,[i]),f.has(i)?f.get(i).push(r):f.set(i,[r])}});var p=function(e,t){var n=[],r=[],i=new b,a=new Set,o=0;return e.forEach(function(s,c){if(!a.has(c)){n[o]=[],r[o]=!1;var l=c;for(i.push(l),a.add(l),n[o].push(l);i.length!=0;)l=i.shift(),t.has(l)&&(r[o]=!0),e.get(l).forEach(function(e){a.has(e)||(i.push(e),a.add(e),n[o].push(e))});o++}}),{components:n,isFixed:r}},m=p(d,e.fixedNodesOnHorizontal);this.componentsOnHorizontal=m.components,this.fixedComponentsOnHorizontal=m.isFixed;var h=p(f,e.fixedNodesOnVertical);this.componentsOnVertical=h.components,this.fixedComponentsOnVertical=h.isFixed}}},x.prototype.updateDisplacements=function(){var e=this;if(this.constraints.fixedNodeConstraint&&this.constraints.fixedNodeConstraint.forEach(function(t){var n=e.idToNodeMap.get(t.nodeId);n.displacementX=0,n.displacementY=0}),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical)for(var t=this.constraints.alignmentConstraint.vertical,n=0;n1){var s;for(s=0;sr&&(r=Math.floor(o.y)),a=Math.floor(o.x+c.DEFAULT_COMPONENT_SEPERATION)}this.transform(new p(d.WORLD_CENTER_X-o.x/2,d.WORLD_CENTER_Y-o.y/2))},x.radialLayout=function(e,t,n){var r=Math.max(this.maxDiagonalInTree(e),c.DEFAULT_RADIAL_SEPARATION);x.branchRadialLayout(t,null,0,359,0,r);var i=v.calculateBounds(e),a=new y;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var o=0;o1;){var g=h[0];h.splice(0,1);var v=u.indexOf(g);v>=0&&u.splice(v,1),p--,d--}m=t==null?0:(u.indexOf(h[0])+1)%p;for(var y=Math.abs(r-n)/d,b=m;f!=d;b=++b%p){var S=u[b].getOtherEnd(e);if(S!=t){var C=(n+f*y)%360,w=(C+y)%360;x.branchRadialLayout(S,e,C,w,i+a,a),f++}}},x.maxDiagonalInTree=function(e){for(var t=g.MIN_VALUE,n=0;nt&&(t=r)}return t},x.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},x.prototype.groupZeroDegreeMembers=function(){var e=this,t={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r=`DummyCompound_`+n;e.memberGroups[r]=t[n];var i=t[n][0].getParent(),a=new o(e.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,e.idToDummyNode[r]=a;var s=e.getGraphManager().add(e.newGraph(),a),c=i.getChild();c.add(a);for(var l=0;li?(r.rect.x-=(r.labelWidth-i)/2,r.setWidth(r.labelWidth),r.labelMarginLeft=(r.labelWidth-i)/2):r.labelPosHorizontal==`right`&&r.setWidth(i+r.labelWidth)),r.labelHeight&&(r.labelPosVertical==`top`?(r.rect.y-=r.labelHeight,r.setHeight(a+r.labelHeight),r.labelMarginTop=r.labelHeight):r.labelPosVertical==`center`&&r.labelHeight>a?(r.rect.y-=(r.labelHeight-a)/2,r.setHeight(r.labelHeight),r.labelMarginTop=(r.labelHeight-a)/2):r.labelPosVertical==`bottom`&&r.setHeight(a+r.labelHeight))}})},x.prototype.repopulateCompounds=function(){for(var e=this.compoundOrder.length-1;e>=0;e--){var t=this.compoundOrder[e],n=t.id,r=t.paddingLeft,i=t.paddingTop,a=t.labelMarginLeft,o=t.labelMarginTop;this.adjustLocations(this.tiledMemberPack[n],t.rect.x,t.rect.y,r,i,a,o)}},x.prototype.repopulateZeroDegreeMembers=function(){var e=this,t=this.tiledZeroDegreePack;Object.keys(t).forEach(function(n){var r=e.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop,o=r.labelMarginLeft,s=r.labelMarginTop;e.adjustLocations(t[n],r.rect.x,r.rect.y,i,a,o,s)})},x.prototype.getToBeTiled=function(e){var t=e.id;if(this.toBeTiled[t]!=null)return this.toBeTiled[t];var n=e.getChild();if(n==null)return this.toBeTiled[t]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[t]=!1,!1;if(a.getChild()==null){this.toBeTiled[a.id]=!1;continue}if(!this.getToBeTiled(a))return this.toBeTiled[t]=!1,!1}return this.toBeTiled[t]=!0,!0},x.prototype.getNodeDegree=function(e){e.id;for(var t=e.getEdges(),n=0,r=0;ru&&(u=f.rect.height)}n+=u+e.verticalPadding}},x.prototype.tileCompoundMembers=function(e,t){var n=this;this.tiledMemberPack=[],Object.keys(e).forEach(function(r){var i=t[r];if(n.tiledMemberPack[r]=n.tileNodes(e[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height,i.setCenter(n.tiledMemberPack[r].centerX,n.tiledMemberPack[r].centerY),i.labelMarginLeft=0,i.labelMarginTop=0,c.NODE_DIMENSIONS_INCLUDE_LABELS){var a=i.rect.width,o=i.rect.height;i.labelWidth&&(i.labelPosHorizontal==`left`?(i.rect.x-=i.labelWidth,i.setWidth(a+i.labelWidth),i.labelMarginLeft=i.labelWidth):i.labelPosHorizontal==`center`&&i.labelWidth>a?(i.rect.x-=(i.labelWidth-a)/2,i.setWidth(i.labelWidth),i.labelMarginLeft=(i.labelWidth-a)/2):i.labelPosHorizontal==`right`&&i.setWidth(a+i.labelWidth)),i.labelHeight&&(i.labelPosVertical==`top`?(i.rect.y-=i.labelHeight,i.setHeight(o+i.labelHeight),i.labelMarginTop=i.labelHeight):i.labelPosVertical==`center`&&i.labelHeight>o?(i.rect.y-=(i.labelHeight-o)/2,i.setHeight(i.labelHeight),i.labelMarginTop=(i.labelHeight-o)/2):i.labelPosVertical==`bottom`&&i.setHeight(o+i.labelHeight))}})},x.prototype.tileNodes=function(e,t){var n=this.tileNodesByFavoringDim(e,t,!0),r=this.tileNodesByFavoringDim(e,t,!1),i=this.getOrgRatio(n);return this.getOrgRatio(r)s&&(s=e.getWidth())});var l=a/i,u=o/i,d=(n-r)**2+4*(l+r)*(u+n)*i,f=(r-n+Math.sqrt(d))/(2*(l+r)),p;t?(p=Math.ceil(f),p==f&&p++):p=Math.floor(f);var m=p*(l+r)-r;return s>m&&(m=s),m+=r*2,m},x.prototype.tileNodesByFavoringDim=function(e,t,n){var r=c.TILING_PADDING_VERTICAL,i=c.TILING_PADDING_HORIZONTAL,a=c.TILING_COMPARE_BY,o={rows:[],rowWidth:[],rowHeight:[],width:0,height:t,verticalPadding:r,horizontalPadding:i,centerX:0,centerY:0};a&&(o.idealRowWidth=this.calcIdealRowWidth(e,n));var s=function(e){return e.rect.width*e.rect.height},l=function(e,t){return s(t)-s(e)};e.sort(function(e,t){var n=l;return o.idealRowWidth?(n=a,n(e.id,t.id)):n(e,t)});for(var u=0,d=0,f=0;f0&&(a+=e.horizontalPadding),e.rowWidth[n]=a,e.width0&&(o+=e.verticalPadding);var s=0;o>e.rowHeight[n]&&(s=e.rowHeight[n],e.rowHeight[n]=o,s=e.rowHeight[n]-s),e.height+=s,e.rows[n].push(t)},x.prototype.getShortestRowIndex=function(e){for(var t=-1,n=Number.MAX_VALUE,r=0;rn&&(t=r,n=e.rowWidth[r]);return t},x.prototype.canAddHorizontal=function(e,t,n){if(e.idealRowWidth){var r=e.rows.length-1;return e.rowWidth[r]+t+e.horizontalPadding<=e.idealRowWidth}var i=this.getShortestRowIndex(e);if(i<0)return!0;var a=e.rowWidth[i];if(a+e.horizontalPadding+t<=e.width)return!0;var o=0;e.rowHeight[i]0&&(o=n+e.verticalPadding-e.rowHeight[i]);var s=e.width-a>=t+e.horizontalPadding?(e.height+o)/(a+t+e.horizontalPadding):(e.height+o)/e.width;o=n+e.verticalPadding;var c=e.widtha&&t!=n){r.splice(-1,1),e.rows[n].push(i),e.rowWidth[t]=e.rowWidth[t]-a,e.rowWidth[n]=e.rowWidth[n]+a,e.width=e.rowWidth[instance.getLongestRowIndex(e)];for(var o=Number.MIN_VALUE,s=0;so&&(o=r[s].height);t>0&&(o+=e.verticalPadding);var c=e.rowHeight[t]+e.rowHeight[n];e.rowHeight[t]=o,e.rowHeight[n]0)for(var d=i;d<=a;d++)l[0]+=this.grid[d][o-1].length+this.grid[d][o].length-1;if(a0)for(var d=o;d<=s;d++)l[3]+=this.grid[i-1][d].length+this.grid[i][d].length-1;for(var f=g.MAX_VALUE,p,m,h=0;h{var r=n(551).FDLayoutNode,i=n(551).IMath;function a(e,t,n,i){r.call(this,e,t,n,i)}for(var o in a.prototype=Object.create(r.prototype),r)a[o]=r[o];a.prototype.calculateDisplacement=function(){var e=this.graphManager.getLayout();this.getChild()!=null&&this.fixedNodeWeight?(this.displacementX+=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.fixedNodeWeight,this.displacementY+=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.fixedNodeWeight):(this.displacementX+=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY+=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren),Math.abs(this.displacementX)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementX=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementY=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementY)),this.child&&this.child.getNodes().length>0&&this.propogateDisplacementToChildren(this.displacementX,this.displacementY)},a.prototype.propogateDisplacementToChildren=function(e,t){for(var n=this.getChild().getNodes(),r,i=0;i{function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t0){var a=0;r.forEach(function(e){t==`horizontal`?(f.set(e,c.has(e)?l[c.get(e)]:i.get(e)),a+=f.get(e)):(f.set(e,c.has(e)?u[c.get(e)]:i.get(e)),a+=f.get(e))}),a/=r.length,e.forEach(function(e){n.has(e)||f.set(e,a)})}else{var o=0;e.forEach(function(e){o+=t==`horizontal`?c.has(e)?l[c.get(e)]:i.get(e):c.has(e)?u[c.get(e)]:i.get(e)}),o/=e.length,e.forEach(function(e){f.set(e,o)})}});for(var h=function(){var r=m.shift();e.get(r).forEach(function(e){if(f.get(e.id)o&&(o=v),ys&&(s=y)}}catch(e){p=!0,m=e}finally{try{!d&&h.return&&h.return()}finally{if(p)throw m}}var b=(r+o)/2-(a+s)/2,x=!0,S=!1,C=void 0;try{for(var w=e[Symbol.iterator](),T;!(x=(T=w.next()).done);x=!0){var E=T.value;f.set(E,f.get(E)+b)}}catch(e){S=!0,C=e}finally{try{!x&&w.return&&w.return()}finally{if(S)throw C}}})}return f},v=function(e){var t=0,n=0,r=0,i=0;if(e.forEach(function(e){e.left?l[c.get(e.left)]-l[c.get(e.right)]>=0?t++:n++:u[c.get(e.top)]-u[c.get(e.bottom)]>=0?r++:i++}),t>n&&r>i)for(var a=0;an)for(var o=0;oi)for(var s=0;s1)t.fixedNodeConstraint.forEach(function(e,t){S[t]=[e.position.x,e.position.y],C[t]=[l[c.get(e.nodeId)],u[c.get(e.nodeId)]]}),w=!0;else if(t.alignmentConstraint)(function(){var e=0;if(t.alignmentConstraint.vertical){for(var n=t.alignmentConstraint.vertical,i=function(t){var i=new Set;n[t].forEach(function(e){i.add(e)});var a=new Set([].concat(r(i)).filter(function(e){return E.has(e)})),o=void 0;o=a.size>0?l[c.get(a.values().next().value)]:g(i).x,n[t].forEach(function(t){S[e]=[o,u[c.get(t)]],C[e]=[l[c.get(t)],u[c.get(t)]],e++})},a=0;a0?l[c.get(i.values().next().value)]:g(n).y,o[t].forEach(function(t){S[e]=[l[c.get(t)],a],C[e]=[l[c.get(t)],u[c.get(t)]],e++})},d=0;dA&&(A=k[M].length,j=M);if(A0){var W={x:0,y:0};t.fixedNodeConstraint.forEach(function(e,t){var n={x:l[c.get(e.nodeId)],y:u[c.get(e.nodeId)]},r=e.position,i=h(r,n);W.x+=i.x,W.y+=i.y}),W.x/=t.fixedNodeConstraint.length,W.y/=t.fixedNodeConstraint.length,l.forEach(function(e,t){l[t]+=W.x}),u.forEach(function(e,t){u[t]+=W.y}),t.fixedNodeConstraint.forEach(function(e){l[c.get(e.nodeId)]=e.position.x,u[c.get(e.nodeId)]=e.position.y})}if(t.alignmentConstraint){if(t.alignmentConstraint.vertical)for(var G=t.alignmentConstraint.vertical,ie=function(e){var t=new Set;G[e].forEach(function(e){t.add(e)});var n=new Set([].concat(r(t)).filter(function(e){return E.has(e)})),i=void 0;i=n.size>0?l[c.get(n.values().next().value)]:g(t).x,t.forEach(function(e){E.has(e)||(l[c.get(e)]=i)})},K=0;K0?u[c.get(n.values().next().value)]:g(t).y,t.forEach(function(e){E.has(e)||(u[c.get(e)]=i)})},J=0;J{t.exports=e})},n={};function r(e){var i=n[e];if(i!==void 0)return i.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}return r(45)})()})})),k=r(e(((e,t)=>{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(O()):typeof define==`function`&&define.amd?define([`cose-base`],r):typeof e==`object`?e.cytoscapeFcose=r(O()):n.cytoscapeFcose=r(n.coseBase)})(e,function(e){return(()=>{var t={658:(e=>{e.exports=Object.assign==null?function(e){return[...arguments].slice(1).forEach(function(t){Object.keys(t).forEach(function(n){return e[n]=t[n]})}),e}:Object.assign.bind(Object)}),548:((e,t,n)=>{var r=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o=e[Symbol.iterator](),s;!(r=(s=o.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(e){i=!0,a=e}finally{try{!r&&o.return&&o.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw TypeError(`Invalid attempt to destructure non-iterable instance`)}}(),i=n(140).layoutBase.LinkedList,a={};a.getTopMostNodes=function(e){for(var t={},n=0;n0&&l.merge(e)});for(var u=0;u1){l=s[0],u=l.connectedEdges().length,s.forEach(function(e){e.connectedEdges().length0&&r.set(`dummy`+(r.size+1),p),m},a.relocateComponent=function(e,t,n){if(!n.fixedNodeConstraint){var i=1/0,a=-1/0,o=1/0,s=-1/0;if(n.quality==`draft`){var c=!0,l=!1,u=void 0;try{for(var d=t.nodeIndexes[Symbol.iterator](),f;!(c=(f=d.next()).done);c=!0){var p=f.value,m=r(p,2),h=m[0],g=m[1],_=n.cy.getElementById(h);if(_){var v=_.boundingBox(),y=t.xCoords[g]-v.w/2,b=t.xCoords[g]+v.w/2,x=t.yCoords[g]-v.h/2,S=t.yCoords[g]+v.h/2;ya&&(a=b),xs&&(s=S)}}}catch(e){l=!0,u=e}finally{try{!c&&d.return&&d.return()}finally{if(l)throw u}}var C=e.x-(a+i)/2,w=e.y-(s+o)/2;t.xCoords=t.xCoords.map(function(e){return e+C}),t.yCoords=t.yCoords.map(function(e){return e+w})}else{Object.keys(t).forEach(function(e){var n=t[e],r=n.getRect().x,c=n.getRect().x+n.getRect().width,l=n.getRect().y,u=n.getRect().y+n.getRect().height;ra&&(a=c),ls&&(s=u)});var T=e.x-(a+i)/2,E=e.y-(s+o)/2;Object.keys(t).forEach(function(e){var n=t[e];n.setCenter(n.getCenterX()+T,n.getCenterY()+E)})}}},a.calcBoundingBox=function(e,t,n,r){for(var i=2**53-1,a=-(2**53-1),o=2**53-1,s=-(2**53-1),c=void 0,l=void 0,u=void 0,d=void 0,f=e.descendants().not(`:parent`),p=f.length,m=0;mc&&(i=c),au&&(o=u),s{var r=n(548),i=n(140).CoSELayout,a=n(140).CoSENode,o=n(140).layoutBase.PointD,s=n(140).layoutBase.DimensionD,c=n(140).layoutBase.LayoutConstants,l=n(140).layoutBase.FDLayoutConstants,u=n(140).CoSEConstants;e.exports={coseLayout:function(e,t){var n=e.cy,d=e.eles,f=d.nodes(),p=d.edges(),m=void 0,h=void 0,g=void 0,_={};e.randomize&&(m=t.nodeIndexes,h=t.xCoords,g=t.yCoords);var v=function(e){return typeof e==`function`},y=function(e,t){return v(e)?e(t):e},b=r.calcParentsWithoutChildren(n,d),x=function e(t,n,i,c){for(var l=n.length,u=0;u0){var S=void 0;S=i.getGraphManager().add(i.newGraph(),p),e(S,f,i,c)}}},S=function(t,n,r){for(var i=0,a=0,o=0;o0?i/a:v(e.idealEdgeLength)?50:e.idealEdgeLength,u.MIN_REPULSION_DIST=l.MIN_REPULSION_DIST=l.DEFAULT_EDGE_LENGTH/10,u.DEFAULT_RADIAL_SEPARATION=l.DEFAULT_EDGE_LENGTH)},C=function(e,t){t.fixedNodeConstraint&&(e.constraints.fixedNodeConstraint=t.fixedNodeConstraint),t.alignmentConstraint&&(e.constraints.alignmentConstraint=t.alignmentConstraint),t.relativePlacementConstraint&&(e.constraints.relativePlacementConstraint=t.relativePlacementConstraint)};e.nestingFactor!=null&&(u.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=l.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=e.nestingFactor),e.gravity!=null&&(u.DEFAULT_GRAVITY_STRENGTH=l.DEFAULT_GRAVITY_STRENGTH=e.gravity),e.numIter!=null&&(u.MAX_ITERATIONS=l.MAX_ITERATIONS=e.numIter),e.gravityRange!=null&&(u.DEFAULT_GRAVITY_RANGE_FACTOR=l.DEFAULT_GRAVITY_RANGE_FACTOR=e.gravityRange),e.gravityCompound!=null&&(u.DEFAULT_COMPOUND_GRAVITY_STRENGTH=l.DEFAULT_COMPOUND_GRAVITY_STRENGTH=e.gravityCompound),e.gravityRangeCompound!=null&&(u.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=l.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=e.gravityRangeCompound),e.initialEnergyOnIncremental!=null&&(u.DEFAULT_COOLING_FACTOR_INCREMENTAL=l.DEFAULT_COOLING_FACTOR_INCREMENTAL=e.initialEnergyOnIncremental),e.tilingCompareBy!=null&&(u.TILING_COMPARE_BY=e.tilingCompareBy),c.QUALITY=e.quality==`proof`?2:0,u.NODE_DIMENSIONS_INCLUDE_LABELS=l.NODE_DIMENSIONS_INCLUDE_LABELS=c.NODE_DIMENSIONS_INCLUDE_LABELS=e.nodeDimensionsIncludeLabels,u.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=!e.randomize,u.ANIMATE=l.ANIMATE=c.ANIMATE=e.animate,u.TILE=e.tile,u.TILING_PADDING_VERTICAL=typeof e.tilingPaddingVertical==`function`?e.tilingPaddingVertical.call():e.tilingPaddingVertical,u.TILING_PADDING_HORIZONTAL=typeof e.tilingPaddingHorizontal==`function`?e.tilingPaddingHorizontal.call():e.tilingPaddingHorizontal,u.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=!0,u.PURE_INCREMENTAL=!e.randomize,c.DEFAULT_UNIFORM_LEAF_NODE_SIZES=e.uniformNodeDimensions,e.step==`transformed`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,u.ENFORCE_CONSTRAINTS=!1,u.APPLY_LAYOUT=!1),e.step==`enforced`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,u.ENFORCE_CONSTRAINTS=!0,u.APPLY_LAYOUT=!1),e.step==`cose`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,u.ENFORCE_CONSTRAINTS=!1,u.APPLY_LAYOUT=!0),e.step==`all`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!!e.randomize,u.ENFORCE_CONSTRAINTS=!0,u.APPLY_LAYOUT=!0),u.TREE_REDUCTION_ON_INCREMENTAL=!(e.fixedNodeConstraint||e.alignmentConstraint||e.relativePlacementConstraint);var w=new i,T=w.newGraphManager();return x(T.addRoot(),r.getTopMostNodes(f),w,e),S(w,T,p),C(w,e),w.runLayout(),_}}}),212:((e,t,n)=>{var r=function(){function e(e,t){for(var n=0;n0){if(f){var p=o.getTopMostNodes(t.eles.nodes());if(l=o.connectComponents(n,t.eles,p),l.forEach(function(e){var t=e.boundingBox();u.push({x:t.x1+t.w/2,y:t.y1+t.h/2})}),t.randomize&&l.forEach(function(e){t.eles=e,i.push(s(t))}),t.quality=="default"||t.quality==`proof`){var m=n.collection();if(t.tile){var h=new Map,g=[],_=[],v=0,y={nodeIndexes:h,xCoords:g,yCoords:_},b=[];if(l.forEach(function(e,t){e.edges().length==0&&(e.nodes().forEach(function(t,n){m.merge(e.nodes()[n]),t.isParent()||(y.nodeIndexes.set(e.nodes()[n].id(),v++),y.xCoords.push(e.nodes()[0].position().x),y.yCoords.push(e.nodes()[0].position().y))}),b.push(t))}),m.length>1){var x=m.boundingBox();u.push({x:x.x1+x.w/2,y:x.y1+x.h/2}),l.push(m),i.push(y);for(var S=b.length-1;S>=0;S--)l.splice(b[S],1),i.splice(b[S],1),u.splice(b[S],1)}}l.forEach(function(e,n){t.eles=e,a.push(c(t,i[n])),o.relocateComponent(u[n],a[n],t)})}else l.forEach(function(e,n){o.relocateComponent(u[n],i[n],t)});var C=new Set;if(l.length>1){var w=[],T=r.filter(function(e){return e.css(`display`)==`none`});l.forEach(function(e,n){var r=void 0;if(t.quality==`draft`&&(r=i[n].nodeIndexes),e.nodes().not(T).length>0){var s={};s.edges=[],s.nodes=[];var c=void 0;e.nodes().not(T).forEach(function(e){if(t.quality==`draft`){if(!e.isParent())c=r.get(e.id()),s.nodes.push({x:i[n].xCoords[c]-e.boundingbox().w/2,y:i[n].yCoords[c]-e.boundingbox().h/2,width:e.boundingbox().w,height:e.boundingbox().h});else{var l=o.calcBoundingBox(e,i[n].xCoords,i[n].yCoords,r);s.nodes.push({x:l.topLeftX,y:l.topLeftY,width:l.width,height:l.height})}}else a[n][e.id()]&&s.nodes.push({x:a[n][e.id()].getLeft(),y:a[n][e.id()].getTop(),width:a[n][e.id()].getWidth(),height:a[n][e.id()].getHeight()})}),e.edges().forEach(function(e){var c=e.source(),l=e.target();if(c.css(`display`)!=`none`&&l.css(`display`)!=`none`){if(t.quality==`draft`){var u=r.get(c.id()),d=r.get(l.id()),f=[],p=[];if(c.isParent()){var m=o.calcBoundingBox(c,i[n].xCoords,i[n].yCoords,r);f.push(m.topLeftX+m.width/2),f.push(m.topLeftY+m.height/2)}else f.push(i[n].xCoords[u]),f.push(i[n].yCoords[u]);if(l.isParent()){var h=o.calcBoundingBox(l,i[n].xCoords,i[n].yCoords,r);p.push(h.topLeftX+h.width/2),p.push(h.topLeftY+h.height/2)}else p.push(i[n].xCoords[d]),p.push(i[n].yCoords[d]);s.edges.push({startX:f[0],startY:f[1],endX:p[0],endY:p[1]})}else a[n][c.id()]&&a[n][l.id()]&&s.edges.push({startX:a[n][c.id()].getCenterX(),startY:a[n][c.id()].getCenterY(),endX:a[n][l.id()].getCenterX(),endY:a[n][l.id()].getCenterY()})}}),s.nodes.length>0&&(w.push(s),C.add(n))}});var E=d.packComponents(w,t.randomize).shifts;if(t.quality==`draft`)i.forEach(function(e,t){var n=e.xCoords.map(function(e){return e+E[t].dx}),r=e.yCoords.map(function(e){return e+E[t].dy});e.xCoords=n,e.yCoords=r});else{var D=0;C.forEach(function(e){Object.keys(a[e]).forEach(function(t){var n=a[e][t];n.setCenter(n.getCenterX()+E[D].dx,n.getCenterY()+E[D].dy)}),D++})}}}else{var O=t.eles.boundingBox();if(u.push({x:O.x1+O.w/2,y:O.y1+O.h/2}),t.randomize){var k=s(t);i.push(k)}t.quality=="default"||t.quality==`proof`?(a.push(c(t,i[0])),o.relocateComponent(u[0],a[0],t)):o.relocateComponent(u[0],i[0],t)}}var A=function(e,n){if(t.quality=="default"||t.quality==`proof`){typeof e==`number`&&(e=n);var r=void 0,o=void 0,s=e.data(`id`);return a.forEach(function(e){s in e&&(r={x:e[s].getRect().getCenterX(),y:e[s].getRect().getCenterY()},o=e[s])}),t.nodeDimensionsIncludeLabels&&(o.labelWidth&&(o.labelPosHorizontal==`left`?r.x+=o.labelWidth/2:o.labelPosHorizontal==`right`&&(r.x-=o.labelWidth/2)),o.labelHeight&&(o.labelPosVertical==`top`?r.y+=o.labelHeight/2:o.labelPosVertical==`bottom`&&(r.y-=o.labelHeight/2))),r??={x:e.position(`x`),y:e.position(`y`)},{x:r.x,y:r.y}}var c=void 0;return i.forEach(function(t){var n=t.nodeIndexes.get(e.id());n!=null&&(c={x:t.xCoords[n],y:t.yCoords[n]})}),c??={x:e.position(`x`),y:e.position(`y`)},{x:c.x,y:c.y}};if(t.quality=="default"||t.quality==`proof`||t.randomize){var j=o.calcParentsWithoutChildren(n,r),M=r.filter(function(e){return e.css(`display`)==`none`});t.eles=r.not(M),r.nodes().not(`:parent`).not(M).layoutPositions(e,t,A),j.length>0&&j.forEach(function(e){e.position(A(e))})}else console.log(`If randomize option is set to false, then quality option must be 'default' or 'proof'.`)}}]),e}()}),657:((e,t,n)=>{var r=n(548),i=n(140).layoutBase.Matrix,a=n(140).layoutBase.SVD;e.exports={spectralLayout:function(e){var t=e.cy,n=e.eles,o=n.nodes(),s=n.nodes(`:parent`),c=new Map,l=new Map,u=new Map,d=[],f=[],p=[],m=[],h=[],g=[],_=[],v=[],y=void 0,b=1e8,x=1e-9,S=e.piTol,C=e.samplingType,w=e.nodeSeparation,T=void 0,E=function(){for(var e=0,t=0,n=!1;t=i;){o=r[i++];for(var m=d[o],_=0;_u&&(u=h[x],f=x)}return f},O=function(e){var t=void 0;if(e){t=Math.floor(Math.random()*y);for(var n=0;n=1)break;u=l}for(var h=0;h=1)break;u=l}for(var b=0;b0&&(r.isParent()?d[t].push(u.get(r.id())):d[t].push(r.id()))})});var B=function(e){var n=l.get(e),r=void 0;c.get(e).forEach(function(i){r=t.getElementById(i).isParent()?u.get(i):i,d[n].push(r),d[l.get(r)].push(e)})},V=!0,ee=!1,te=void 0;try{for(var H=c.keys()[Symbol.iterator](),ne;!(V=(ne=H.next()).done);V=!0){var re=ne.value;B(re)}}catch(e){ee=!0,te=e}finally{try{!V&&H.return&&H.return()}finally{if(ee)throw te}}y=l.size;var U=void 0;if(y>2){T=y{var r=n(212),i=function(e){e&&e(`layout`,`fcose`,r)};typeof cytoscape<`u`&&i(cytoscape),e.exports=i}),140:(t=>{t.exports=e})},n={};function r(e){var i=n[e];if(i!==void 0)return i.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}return r(579)})()})}))(),1),A={L:`left`,R:`right`,T:`top`,B:`bottom`},j={L:i(e=>`${e},${e/2} 0,${e} 0,0`,`L`),R:i(e=>`0,${e/2} ${e},0 ${e},${e}`,`R`),T:i(e=>`0,0 ${e},0 ${e/2},${e}`,`T`),B:i(e=>`${e/2},0 ${e},${e} 0,${e}`,`B`)},M={L:i((e,t)=>e-t+2,`L`),R:i((e,t)=>e-2,`R`),T:i((e,t)=>e-t+2,`T`),B:i((e,t)=>e-2,`B`)},N=i(function(e){return F(e)?e===`L`?`R`:`L`:e===`T`?`B`:`T`},`getOppositeArchitectureDirection`),P=i(function(e){let t=e;return t===`L`||t===`R`||t===`T`||t===`B`},`isArchitectureDirection`),F=i(function(e){let t=e;return t===`L`||t===`R`},`isArchitectureDirectionX`),I=i(function(e){let t=e;return t===`T`||t===`B`},`isArchitectureDirectionY`),L=i(function(e,t){let n=F(e)&&I(t),r=I(e)&&F(t);return n||r},`isArchitectureDirectionXY`),R=i(function(e){let t=e[0],n=e[1],r=F(t)&&I(n),i=I(t)&&F(n);return r||i},`isArchitecturePairXY`),z=i(function(e){return e!==`LL`&&e!==`RR`&&e!==`TT`&&e!==`BB`},`isValidArchitectureDirectionPair`),B=i(function(e,t){let n=`${e}${t}`;return z(n)?n:void 0},`getArchitectureDirectionPair`),V=i(function([e,t],n){let r=n[0],i=n[1];return F(r)?I(i)?[e+(r===`L`?-1:1),t+(i===`T`?1:-1)]:[e+(r===`L`?-1:1),t]:F(i)?[e+(i===`L`?1:-1),t+(r===`T`?1:-1)]:[e,t+(r===`T`?1:-1)]},`shiftPositionByArchitectureDirectionPair`),ee=i(function(e){return e===`LT`||e===`TL`?[1,1]:e===`BL`||e===`LB`?[1,-1]:e===`BR`||e===`RB`?[-1,-1]:[-1,1]},`getArchitectureDirectionXYFactors`),te=i(function(e,t){return L(e,t)?`bend`:F(e)?`horizontal`:`vertical`},`getArchitectureDirectionAlignment`),H=i(function(e){return e.type===`service`},`isArchitectureService`),ne=i(function(e){return e.type===`junction`},`isArchitectureJunction`),re=i((e,t)=>{let[n,r]=[e,t].sort();return`${JSON.stringify(n)}-${JSON.stringify(r)}`},`architectureGroupAlignmentKey`),U=i(e=>e.data(),`edgeData`),W=i(e=>e.data(),`nodeData`),G=u.architecture,ie=class{constructor(){this.nodes=new Map,this.groups=new Map,this.edges=[],this.layoutHints=[],this.registeredIds=new Map,this.elements=new Map,this.diagramId=``,this.setAccTitle=o,this.getAccTitle=h,this.setDiagramTitle=d,this.getDiagramTitle=p,this.getAccDescription=f,this.setAccDescription=a,this.clear()}static{i(this,`ArchitectureDB`)}setDiagramId(e){this.diagramId=e}getDiagramId(){return this.diagramId}clear(){this.nodes=new Map,this.groups=new Map,this.edges=[],this.layoutHints=[],this.registeredIds=new Map,this.dataStructures=void 0,this.elements=new Map,this.diagramId=``,c()}addService({id:e,icon:t,in:n,title:r,iconText:i}){if(this.registeredIds.has(e))throw Error(`The service id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(n!==void 0){if(e===n)throw Error(`The service [${e}] cannot be placed within itself`);if(!this.registeredIds.has(n))throw Error(`The service [${e}]'s parent does not exist. Please make sure the parent is created before this service`);if(this.registeredIds.get(n)===`node`)throw Error(`The service [${e}]'s parent is not a group`)}this.registeredIds.set(e,`node`),this.nodes.set(e,{id:e,type:`service`,icon:t,iconText:i,title:r,edges:[],in:n})}getServices(){return[...this.nodes.values()].filter(H)}addJunction({id:e,in:t}){if(this.registeredIds.has(e))throw Error(`The junction id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(t!==void 0){if(e===t)throw Error(`The junction [${e}] cannot be placed within itself`);if(!this.registeredIds.has(t))throw Error(`The junction [${e}]'s parent does not exist. Please make sure the parent is created before this junction`);if(this.registeredIds.get(t)===`node`)throw Error(`The junction [${e}]'s parent is not a group`)}this.registeredIds.set(e,`node`),this.nodes.set(e,{id:e,type:`junction`,edges:[],in:t})}getJunctions(){return[...this.nodes.values()].filter(ne)}getNodes(){return[...this.nodes.values()]}getNode(e){return this.nodes.get(e)??null}addGroup({id:e,icon:t,in:n,title:r}){if(this.registeredIds.has(e))throw Error(`The group id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(n!==void 0){if(e===n)throw Error(`The group [${e}] cannot be placed within itself`);if(!this.registeredIds.has(n))throw Error(`The group [${e}]'s parent does not exist. Please make sure the parent is created before this group`);if(this.registeredIds.get(n)===`node`)throw Error(`The group [${e}]'s parent is not a group`)}this.registeredIds.set(e,`group`),this.groups.set(e,{id:e,icon:t,title:r,in:n})}getGroups(){return[...this.groups.values()]}addEdge({lhsId:e,rhsId:t,lhsDir:n,rhsDir:r,lhsInto:i,rhsInto:a,lhsGroup:o,rhsGroup:s,title:c}){if(!P(n))throw Error(`Invalid direction given for left hand side of edge ${e}--${t}. Expected (L,R,T,B) got ${String(n)}`);if(!P(r))throw Error(`Invalid direction given for right hand side of edge ${e}--${t}. Expected (L,R,T,B) got ${String(r)}`);if(!this.nodes.has(e)&&!this.groups.has(e))throw Error(`The left-hand id [${e}] does not yet exist. Please create the service/group before declaring an edge to it.`);if(!this.nodes.has(t)&&!this.groups.has(t))throw Error(`The right-hand id [${t}] does not yet exist. Please create the service/group before declaring an edge to it.`);let l=this.nodes.get(e).in,u=this.nodes.get(t).in;if(o&&l&&u&&l==u)throw Error(`The left-hand id [${e}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);if(s&&l&&u&&l==u)throw Error(`The right-hand id [${t}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);let d={lhsId:e,lhsDir:n,lhsInto:i,lhsGroup:o,rhsId:t,rhsDir:r,rhsInto:a,rhsGroup:s,title:c};this.edges.push(d);let f=this.nodes.get(e),p=this.nodes.get(t);f&&p&&(f.edges.push(this.edges[this.edges.length-1]),p.edges.push(this.edges[this.edges.length-1]))}getEdges(){return this.edges}addLayoutHint(e){if(e.members.length<2)throw Error(`An align directive requires at least two members; got ${e.members.length}`);let t=new Set;e.members.forEach(n=>{if(this.registeredIds.get(n)!==`node`)throw Error(`align ${e.direction} references [${n}], which is not a service or junction`);if(t.has(n))throw Error(`align ${e.direction} lists [${n}] more than once`);t.add(n)}),this.layoutHints.push(e)}getLayoutHints(){return this.layoutHints}getDataStructures(){if(this.dataStructures===void 0){let e=new Map,t=new Map;for(let[n,r]of this.nodes.entries()){let i=new Map;for(let t of r.edges){let r=this.getNode(t.lhsId)?.in,a=this.getNode(t.rhsId)?.in;if(r&&a&&r!==a){let n=te(t.lhsDir,t.rhsDir);n!==`bend`&&e.set(re(r,a),n)}if(t.lhsId===n){let e=B(t.lhsDir,t.rhsDir);e&&i.set(e,t.rhsId)}else{let e=B(t.rhsDir,t.lhsDir);e&&i.set(e,t.lhsId)}}t.set(n,i)}let n=new Set,r=new Set(t.keys()),a=i(e=>{let i=new Map([[e,[0,0]]]),a=[e];for(;a.length>0;){let e=a.shift();if(e){n.add(e),r.delete(e);let o=t.get(e);if(!o)throw Error(`BFS error: adjacency list for id ${e} not found. Please report this as a bug.`);let s=i.get(e);if(!s)throw Error(`BFS error: position for id ${e} not found in spatial map. Please report this as a bug.`);let[c,l]=s;o.forEach((e,t)=>{n.has(e)||(i.set(e,V([c,l],t)),a.push(e))})}}return i},`BFS`),o=[];for(;r.size>0;){let e=r.values().next().value;o.push(a(e))}this.dataStructures={adjList:t,spatialMaps:o,groupAlignments:e}}return this.dataStructures}setElementForId(e,t){this.elements.set(e,t)}getElementById(e){return this.elements.get(e)}getConfig(){return v({...G,...l().architecture})}getConfigField(e){return this.getConfig()[e]}},K=i((e,t)=>{T(e,t),e.groups.map(e=>t.addGroup(e)),e.services.map(e=>t.addService({...e,type:`service`})),e.junctions.map(e=>t.addJunction({...e,type:`junction`})),e.edges.map(e=>t.addEdge(e)),e.alignments?.map(e=>t.addLayoutHint({direction:e.direction,members:[...e.members]}))},`populateDb`),q={parser:{yy:void 0},parse:i(async e=>{let n=await w(`architecture`,e);t.debug(n);let r=q.parser?.yy;if(!(r instanceof ie))throw Error(`parser.parser?.yy was not a ArchitectureDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);K(n,r)},`parse`)},ae=i(e=>` + .edge { + stroke-width: ${e.archEdgeWidth}; + stroke: ${e.archEdgeColor}; + fill: none; + } + + .arrow { + fill: ${e.archEdgeArrowColor}; + } + + .node-bkg { + fill: none; + stroke: ${e.archGroupBorderColor}; + stroke-width: ${e.archGroupBorderWidth}; + stroke-dasharray: 8; + } + .node-icon-text { + display: flex; + align-items: center; + } + + .node-icon-text > div { + color: #fff; + margin: 1px; + height: fit-content; + text-align: center; + overflow: hidden; + display: -webkit-box; + -webkit-box-orient: vertical; + } +`,`getStyles`);function J(e,t){if(e===0)return t();let n=Math.random,r=e>>>0;Math.random=function(){r=r+1831565813>>>0;let e=r;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296};try{return t()}finally{Math.random=n}}i(J,`withSeededRandom`);var Y=i(e=>`${e}`,`wrapIcon`),X={prefix:`mermaid-architecture`,height:80,width:80,icons:{database:{body:Y(``)},server:{body:Y(``)},disk:{body:Y(``)},internet:{body:Y(``)},cloud:{body:Y(``)},unknown:y,blank:{body:Y(``)}}},oe=i(async function(e,t,n,r){let i=n.getConfigField(`padding`),a=n.getConfigField(`iconSize`),o=a/2,s=a/6,c=s/2;await Promise.all(t.edges().map(async t=>{let{source:a,sourceDir:l,sourceArrow:u,sourceGroup:d,target:f,targetDir:p,targetArrow:h,targetGroup:g,label:v}=U(t),{x:y,y:b}=t[0].sourceEndpoint(),{x,y:C}=t[0].midpoint(),{x:w,y:T}=t[0].targetEndpoint(),E=i+4;if(d&&(F(l)?y+=l===`L`?-E:E:b+=l===`T`?-E:E+18),g&&(F(p)?w+=p===`L`?-E:E:T+=p===`T`?-E:E+18),!d&&n.getNode(a)?.type===`junction`&&(F(l)?y+=l===`L`?o:-o:b+=l===`T`?o:-o),!g&&n.getNode(f)?.type===`junction`&&(F(p)?w+=p===`L`?o:-o:T+=p===`T`?o:-o),t[0]._private.rscratch){let t=e.insert(`g`);if(t.insert(`path`).attr(`d`,`M ${y},${b} L ${x},${C} L${w},${T} `).attr(`class`,`edge`).attr(`id`,`${r}-${_(a,f,{prefix:`L`})}`),u){let e=F(l)?M[l](y,s):y-c,n=I(l)?M[l](b,s):b-c;t.insert(`polygon`).attr(`points`,j[l](s)).attr(`transform`,`translate(${e},${n})`).attr(`class`,`arrow`)}if(h){let e=F(p)?M[p](w,s):w-c,n=I(p)?M[p](T,s):T-c;t.insert(`polygon`).attr(`points`,j[p](s)).attr(`transform`,`translate(${e},${n})`).attr(`class`,`arrow`)}if(v){let e=L(l,p)?`XY`:F(l)?`X`:`Y`,n=0;n=e===`X`?Math.abs(y-w):e===`Y`?Math.abs(b-T)/1.5:Math.abs(y-w)/2;let r=t.append(`g`);if(await S(r,v,{useHtmlLabels:!1,width:n,classes:`architecture-service-label`},m()),r.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`),e===`X`)r.attr(`transform`,`translate(`+x+`, `+C+`)`);else if(e===`Y`)r.attr(`transform`,`translate(`+x+`, `+C+`) rotate(-90)`);else if(e===`XY`){let e=B(l,p);if(e&&R(e)){let t=r.node().getBoundingClientRect(),[n,i]=ee(e);r.attr(`dominant-baseline`,`auto`).attr(`transform`,`rotate(${-1*n*i*45})`);let a=r.node().getBoundingClientRect();r.attr(`transform`,` + translate(${x}, ${C-t.height/2}) + translate(${n*a.width/2}, ${i*a.height/2}) + rotate(${-1*n*i*45}, 0, ${t.height/2}) + `)}}}}}))},`drawEdges`),Z=i(async function(e,t,n,r){let i=n.getConfigField(`padding`)*.75,a=n.getConfigField(`fontSize`),o=n.getConfigField(`iconSize`)/2;await Promise.all(t.nodes().map(async t=>{let s=W(t);if(s.type===`group`){let{h:c,w:l,x1:u,y1:d}=t.boundingBox(),f=e.append(`rect`);f.attr(`id`,`${r}-group-${s.id}`).attr(`x`,u+o).attr(`y`,d+o).attr(`width`,l).attr(`height`,c).attr(`class`,`node-bkg`);let p=e.append(`g`),h=u,g=d;if(s.icon){let e=p.append(`g`);e.html(`${await x(s.icon,{height:i,width:i,fallbackPrefix:X.prefix})}`),e.attr(`transform`,`translate(`+(h+o+1)+`, `+(g+o+1)+`)`),h+=i,g+=a/2-1-2}if(s.label){let e=p.append(`g`);await S(e,s.label,{useHtmlLabels:!1,width:l,classes:`architecture-service-label`},m()),e.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`start`).attr(`text-anchor`,`start`),e.attr(`transform`,`translate(`+(h+o+4)+`, `+(g+o+2)+`)`)}n.setElementForId(s.id,f)}}))},`drawGroups`),se=i(async function(e,t,n,r){let i=m();for(let a of n){let n=t.append(`g`),o=e.getConfigField(`iconSize`);if(a.title){let e=n.append(`g`);await S(e,a.title,{useHtmlLabels:!1,width:o*1.5,classes:`architecture-service-label`},i),e.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`),e.attr(`transform`,`translate(`+o/2+`, `+o+`)`)}let s=n.append(`g`);if(a.icon)s.html(`${await x(a.icon,{height:o,width:o,fallbackPrefix:X.prefix})}`);else if(a.iconText){s.html(`${await x(`blank`,{height:o,width:o,fallbackPrefix:X.prefix})}`);let e=s.append(`g`).append(`foreignObject`).attr(`width`,o).attr(`height`,o).append(`div`).attr(`class`,`node-icon-text`).attr(`style`,`height: ${o}px;`).append(`div`).html(g(a.iconText,i)),t=parseInt(window.getComputedStyle(e.node(),null).getPropertyValue(`font-size`).replace(/\D/g,``))??16;e.attr(`style`,`-webkit-line-clamp: ${Math.floor((o-2)/t)};`)}else s.append(`path`).attr(`class`,`node-bkg`).attr(`id`,`${r}-node-${a.id}`).attr(`d`,`M0,${o} V5 Q0,0 5,0 H${o-5} Q${o},0 ${o},5 V${o} Z`);n.attr(`id`,`${r}-service-${a.id}`).attr(`class`,`architecture-service`);let{width:c,height:l}=n.node().getBBox();a.width=c,a.height=l,e.setElementForId(a.id,n)}return 0},`drawServices`),ce=i(function(e,t,n,r){n.forEach(n=>{let i=t.append(`g`),a=e.getConfigField(`iconSize`);i.append(`g`).append(`rect`).attr(`id`,`${r}-node-${n.id}`).attr(`fill-opacity`,`0`).attr(`width`,a).attr(`height`,a),i.attr(`class`,`architecture-junction`);let{width:o,height:s}=i._groups[0][0].getBBox();i.width=o,i.height=s,e.setElementForId(n.id,i)})},`drawJunctions`);b([{name:X.prefix,icons:X}]),E.use(k.default);function le(e,t,n){e.forEach(e=>{t.add({group:`nodes`,data:{type:`service`,id:e.id,icon:e.icon,label:e.title,parent:e.in,width:n.getConfigField(`iconSize`),height:n.getConfigField(`iconSize`)},classes:`node-service`})})}i(le,`addServices`);function ue(e,t,n){e.forEach(e=>{t.add({group:`nodes`,data:{type:`junction`,id:e.id,parent:e.in,width:n.getConfigField(`iconSize`),height:n.getConfigField(`iconSize`)},classes:`node-junction`})})}i(ue,`addJunctions`);function de(e,t){t.nodes().map(t=>{let n=W(t);n.type!==`group`&&(n.x=t.position().x,n.y=t.position().y,e.getElementById(n.id).attr(`transform`,`translate(`+(n.x||0)+`,`+(n.y||0)+`)`))})}i(de,`positionNodes`);function fe(e,t){e.forEach(e=>{t.add({group:`nodes`,data:{type:`group`,id:e.id,icon:e.icon,label:e.title,parent:e.in},classes:`node-group`})})}i(fe,`addGroups`);function pe(e,t){e.forEach(e=>{let{lhsId:n,rhsId:r,lhsInto:i,lhsGroup:a,rhsInto:o,lhsDir:s,rhsDir:c,rhsGroup:l,title:u}=e,d=L(e.lhsDir,e.rhsDir)?`segments`:`straight`,f={id:`${n}-${r}`,label:u,source:n,sourceDir:s,sourceArrow:i,sourceGroup:a,sourceEndpoint:s===`L`?`0 50%`:s===`R`?`100% 50%`:s===`T`?`50% 0`:`50% 100%`,target:r,targetDir:c,targetArrow:o,targetGroup:l,targetEndpoint:c===`L`?`0 50%`:c===`R`?`100% 50%`:c===`T`?`50% 0`:`50% 100%`};t.add({group:`edges`,data:f,classes:d})})}i(pe,`addEdges`);function me(e,t,n,r=[]){let a=i((e,t)=>{let r=new Map;for(let[i,a]of e.entries()){let e=`${i}`,o=0,s=[...a.entries()];if(s.length===1){r.set(e,s[0][1]);continue}for(let i=0;i{let n=new Map,r=new Map;return t.forEach(([t,i],a)=>{let o=e.getNode(a)?.in??`default`,s=n.get(i)??new Map;n.has(i)||n.set(i,s);let c=r.get(t)??new Map;r.has(t)||r.set(t,c);for(let e of[s,c]){let t=e.get(o)??[];e.has(o)||e.set(o,t),t.push(a)}}),{horiz:[...a(n,`horizontal`).values()].filter(e=>e.length>1),vert:[...a(r,`vertical`).values()].filter(e=>e.length>1)}}).reduce(([e,t],{horiz:n,vert:r})=>[[...e,...n],[...t,...r]],[[],[]]),c=new Set;r.forEach(e=>e.members.forEach(e=>c.add(e)));let l=i(e=>e.filter(e=>!e.some(e=>c.has(e))),`dropOverlapping`),u=l(o),d=l(s);return r.forEach(e=>{e.members.length<2||(e.direction===`row`?u.push([...e.members]):d.push([...e.members]))}),{horizontal:u,vertical:d}}i(me,`getAlignments`);function he(e,t,n=[]){let r=[],a=t.getConfigField(`iconSize`),o=t.getConfigField(`idealEdgeLengthMultiplier`),s=o*a,c=new Set;n.forEach(e=>{for(let t=0;t`${e[0]},${e[1]}`,`posToStr`),u=i(e=>e.split(`,`).map(e=>parseInt(e)),`strToPos`);return e.forEach(e=>{let t=new Map([...e.entries()].map(([e,t])=>[l(t),e])),n=[l([0,0])],i={},s={L:[-1,0],R:[1,0],T:[0,1],B:[0,-1]};for(;n.length>0;){let e=n.shift();if(e){i[e]=1;let d=t.get(e);if(d){let f=u(e);Object.entries(s).forEach(([e,s])=>{let u=l([f[0]+s[0],f[1]+s[1]]),p=t.get(u);if(p&&!i[u]){if(n.push(u),c.has(`${d}|${p}`))return;r.push({[A[e]]:p,[A[N(e)]]:d,gap:o*a})}})}}}}),r}i(he,`getRelativeConstraints`);function ge(e,r,a,o,s,{spatialMaps:c,groupAlignments:l}){return new Promise(u=>{let d=n(`body`).append(`div`).attr(`id`,`cy`).attr(`style`,`display:none`),f=E({container:document.getElementById(`cy`),style:[{selector:`edge`,style:{"curve-style":`straight`,"source-endpoint":`data(sourceEndpoint)`,"target-endpoint":`data(targetEndpoint)`}},{selector:`edge[label]`,style:{label:`data(label)`}},{selector:`edge.segments`,style:{"curve-style":`segments`,"segment-weights":`0`,"segment-distances":[.5],"edge-distances":`endpoints`,"source-endpoint":`data(sourceEndpoint)`,"target-endpoint":`data(targetEndpoint)`}},{selector:`node`,style:{"compound-sizing-wrt-labels":`include`}},{selector:`node[label]`,style:{"text-valign":`bottom`,"text-halign":`center`,"font-size":`${s.getConfigField(`fontSize`)}px`}},{selector:`.node-service`,style:{label:`data(label)`,width:`data(width)`,height:`data(height)`}},{selector:`.node-junction`,style:{width:`data(width)`,height:`data(height)`}},{selector:`.node-group`,style:{padding:`${s.getConfigField(`padding`)}px`}}],layout:{name:`grid`,boundingBox:{x1:0,x2:100,y1:0,y2:100}}});d.remove(),fe(a,f),le(e,f,s),ue(r,f,s),pe(o,f);let p=s.getLayoutHints(),m=me(s,c,l,p),h=he(c,s,p),g=s.getConfigField(`iconSize`),_=s.getConfigField(`idealEdgeLengthMultiplier`)*g,v=.5*g,y=s.getConfigField(`edgeElasticity`),b=s.getConfigField(`seed`),x=f.layout({name:`fcose`,quality:`proof`,randomize:s.getConfigField(`randomize`),nodeSeparation:s.getConfigField(`nodeSeparation`),numIter:s.getConfigField(`numIter`),styleEnabled:!1,animate:!1,nodeDimensionsIncludeLabels:!1,idealEdgeLength(e){let[t,n]=e.connectedNodes(),{parent:r}=W(t),{parent:i}=W(n);return r===i?_:v},edgeElasticity(e){let[t,n]=e.connectedNodes(),{parent:r}=W(t),{parent:i}=W(n);return r===i?y:.001},alignmentConstraint:m,relativePlacementConstraint:h});x.one(`layoutstop`,()=>{function e(e,t,n,r){let i,a,{x:o,y:s}=e,{x:c,y:l}=t;a=(r-s+(o-n)*(s-l)/(o-c))/Math.sqrt(1+((s-l)/(o-c))**2),i=Math.sqrt((r-s)**2+(n-o)**2-a**2);let u=Math.sqrt((c-o)**2+(l-s)**2);i/=u;let d=(c-o)*(r-s)-(l-s)*(n-o);switch(!0){case d>=0:d=1;break;case d<0:d=-1}let f=(c-o)*(n-o)+(l-s)*(r-s);switch(!0){case f>=0:f=1;break;case f<0:f=-1}return a=Math.abs(a)*d,i*=f,{distances:a,weights:i}}i(e,`getSegmentWeights`),f.startBatch();for(let t of Object.values(f.edges()))if(t.data?.()){let{x:n,y:r}=t.source().position(),{x:i,y:a}=t.target().position();if(n!==i&&r!==a){let n=t.sourceEndpoint(),r=t.targetEndpoint(),{sourceDir:i}=U(t),[a,o]=I(i)?[n.x,r.y]:[r.x,n.y],{weights:s,distances:c}=e(n,r,a,o);t.style(`segment-distances`,c),t.style(`segment-weights`,s)}}f.endBatch(),J(b,()=>x.run())});try{J(b,()=>x.run())}catch(e){throw e instanceof RangeError&&e.message.includes(`Invalid array length`)?Error("Architecture layout failed: a declared `align row|column` directive likely contradicts the edge directions, or two declared alignments overlap on a shared node. Check that the order of members in each `align` chain is consistent with the edges between them, and that no node appears in two `align` directives along the same axis."):e}f.ready(e=>{t.info(`Ready`,e),u(f)})})}i(ge,`layoutArchitecture`);var _e={parser:q,get db(){return new ie},renderer:{draw:i(async(e,t,n,r)=>{let i=r.db;i.setDiagramId(t);let a=i.getServices(),o=i.getJunctions(),c=i.getGroups(),l=i.getEdges(),u=i.getDataStructures(),d=C(t),f=d.append(`g`);f.attr(`class`,`architecture-edges`);let p=d.append(`g`);p.attr(`class`,`architecture-services`);let m=d.append(`g`);m.attr(`class`,`architecture-groups`),await se(i,p,a,t),ce(i,p,o,t);let h=await ge(a,o,c,l,i,u);await oe(f,h,i,t),await Z(m,h,i,t),de(i,h),s(void 0,d,i.getConfigField(`padding`),i.getConfigField(`useMaxWidth`))},`draw`)},styles:ae};export{_e as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/array-BifhSqXX.js b/frontend/dist/assets/array-BifhSqXX.js new file mode 100644 index 0000000..b0a084a --- /dev/null +++ b/frontend/dist/assets/array-BifhSqXX.js @@ -0,0 +1 @@ +Array.prototype.slice;function e(e){return typeof e==`object`&&`length`in e?e:Array.from(e)}export{e as t}; \ No newline at end of file diff --git a/frontend/dist/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js b/frontend/dist/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js new file mode 100644 index 0000000..90e752b --- /dev/null +++ b/frontend/dist/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js @@ -0,0 +1,140 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{a as r,b as i,c as a,ot as o,s,x as c}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as l}from"./channel-_oCHZhRo.js";import{A as u,B as d,C as f,D as p,E as m,F as h,G as g,H as _,I as v,L as y,M as b,N as x,O as S,P as C,R as w,T,U as E,V as D,W as O,b as k,j as A,k as j,l as M,v as ee,w as te,z as ne}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as re,n as ie,o as ae,r as oe,s as se}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as ce,r as N}from"./chunk-5DYCD2WN-WToj2Jza.js";import{d as le,g as ue,o as de,s as fe,u as pe}from"./index-DoQkmpth.js";import{t as me}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as he}from"./graphlib-C9Tl7QrK.js";function ge(e){return Array.isArray(e)}function _e(e){if(k(e))return e;let t=g(e);if(!ve(e))return{};if(ge(e)){let t=Array.from(e);return e.length>0&&typeof e[0]==`string`&&Object.hasOwn(e,`index`)&&(t.index=e.index,t.input=e.input),t}if(ee(e)){let t=e,n=t.constructor;return new n(t.buffer,t.byteOffset,t.length)}if(t===`[object ArrayBuffer]`)return new ArrayBuffer(e.byteLength);if(t===`[object DataView]`){let t=e,n=t.buffer,r=t.byteOffset,i=t.byteLength,a=new ArrayBuffer(i),o=new Uint8Array(n,r,i);return new Uint8Array(a).set(o),new DataView(a)}if(t===`[object Boolean]`||t===`[object Number]`||t===`[object String]`){let n=e.constructor,r=new n(e.valueOf());return t===`[object String]`?be(r,e):P(r,e),r}if(t===`[object Date]`)return new Date(Number(e));if(t===`[object RegExp]`){let t=e,n=new RegExp(t.source,t.flags);return n.lastIndex=t.lastIndex,n}if(t===`[object Symbol]`)return Object(Symbol.prototype.valueOf.call(e));if(t===`[object Map]`){let t=e,n=new Map;return t.forEach((e,t)=>{n.set(t,e)}),n}if(t===`[object Set]`){let t=e,n=new Set;return t.forEach(e=>{n.add(e)}),n}if(t===`[object Arguments]`){let t=e,n={};return P(n,t),n.length=t.length,n[Symbol.iterator]=t[Symbol.iterator],n}let n={};return xe(n,e),P(n,e),ye(n,e),n}function ve(e){switch(g(e)){case f:case T:case te:case p:case m:case S:case j:case u:case x:case A:case b:case C:case h:case v:case y:case w:case ne:case d:case E:case O:case D:case _:return!0;default:return!1}}function P(e,t){for(let n in t)Object.hasOwn(t,n)&&(e[n]=t[n])}function ye(e,t){let n=Object.getOwnPropertySymbols(t);for(let r=0;r=n)&&(e[r]=t[r])}function xe(e,t){let n=Object.getPrototypeOf(t);n!==null&&typeof t.constructor==`function`&&Object.setPrototypeOf(e,n)}var F=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,15],r=[1,7],i=[1,13],a=[1,14],o=[1,19],s=[1,16],c=[1,17],l=[1,18],u=[8,30],d=[8,10,21,28,29,30,31,39,43,46],f=[1,23],p=[1,24],m=[8,10,15,16,21,28,29,30,31,39,43,46],h=[8,10,15,16,21,27,28,29,30,31,39,43,46],g=[1,49],_={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACELINE`,5:`NL`,7:`SPACE`,8:`EOF`,10:`BLOCK_DIAGRAM_KEY`,15:`LINK`,16:`START_LINK`,17:`LINK_LABEL`,18:`STR`,21:`SPACE_BLOCK`,27:`SIZE`,28:`COLUMNS`,29:`id-block`,30:`end`,31:`NODE_ID`,34:`DIR`,35:`NODE_DSTART`,36:`NODE_DEND`,37:`BLOCK_ARROW_START`,38:`BLOCK_ARROW_END`,39:`classDef`,40:`CLASSDEF_ID`,41:`CLASSDEF_STYLEOPTS`,42:`DEFAULT`,43:`class`,44:`CLASSENTITY_IDS`,45:`STYLECLASS`,46:`style`,47:`STYLE_ENTITY_IDS`,48:`STYLE_DEFINITION_DATA`},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:r.getLogger().debug(`Rule: separator (NL) `);break;case 5:r.getLogger().debug(`Rule: separator (Space) `);break;case 6:r.getLogger().debug(`Rule: separator (EOF) `);break;case 7:r.getLogger().debug(`Rule: hierarchy: `,a[s-1]),r.setHierarchy(a[s-1]);break;case 8:r.getLogger().debug(`Stop NL `);break;case 9:r.getLogger().debug(`Stop EOF `);break;case 10:r.getLogger().debug(`Stop NL2 `);break;case 11:r.getLogger().debug(`Stop EOF2 `);break;case 12:r.getLogger().debug(`Rule: statement: `,a[s]),this.$=typeof a[s].length==`number`?a[s]:[a[s]];break;case 13:r.getLogger().debug(`Rule: statement #2: `,a[s-1]),this.$=[a[s-1]].concat(a[s]);break;case 14:r.getLogger().debug(`Rule: link: `,a[s],e),this.$={edgeTypeStr:a[s],label:``};break;case 15:r.getLogger().debug(`Rule: LABEL link: `,a[s-3],a[s-1],a[s]),this.$={edgeTypeStr:a[s],label:a[s-1]};break;case 18:let t=parseInt(a[s]),n=r.generateId();this.$={id:n,type:`space`,label:``,width:t,children:[]};break;case 23:r.getLogger().debug(`Rule: (nodeStatement link node) `,a[s-2],a[s-1],a[s],` typestr: `,a[s-1].edgeTypeStr);let i=r.edgeStrToEdgeData(a[s-1].edgeTypeStr),o=r.edgeStrToEdgeStartData(a[s-1].edgeTypeStr),c=r.edgeStrToThickness(a[s-1].edgeTypeStr),l=r.edgeStrToPattern(a[s-1].edgeTypeStr);this.$=[{id:a[s-2].id,label:a[s-2].label,type:a[s-2].type,directions:a[s-2].directions},{id:a[s-2].id+`-`+a[s].id,start:a[s-2].id,end:a[s].id,label:a[s-1].label,type:`edge`,thickness:c,pattern:l,directions:a[s].directions,arrowTypeEnd:i,arrowTypeStart:o},{id:a[s].id,label:a[s].label,type:r.typeStr2Type(a[s].typeStr),directions:a[s].directions}];break;case 24:r.getLogger().debug(`Rule: nodeStatement (abc88 node size) `,a[s-1],a[s]),this.$={id:a[s-1].id,label:a[s-1].label,type:r.typeStr2Type(a[s-1].typeStr),directions:a[s-1].directions,widthInColumns:parseInt(a[s],10)};break;case 25:r.getLogger().debug(`Rule: nodeStatement (node) `,a[s]),this.$={id:a[s].id,label:a[s].label,type:r.typeStr2Type(a[s].typeStr),directions:a[s].directions,widthInColumns:1};break;case 26:r.getLogger().debug(`APA123`,this?this:`na`),r.getLogger().debug(`COLUMNS: `,a[s]),this.$={type:`column-setting`,columns:a[s]===`auto`?-1:parseInt(a[s])};break;case 27:r.getLogger().debug(`Rule: id-block statement : `,a[s-2],a[s-1]),r.generateId(),this.$={...a[s-2],type:`composite`,children:a[s-1]};break;case 28:r.getLogger().debug(`Rule: blockStatement : `,a[s-2],a[s-1],a[s]);let u=r.generateId();this.$={id:u,type:`composite`,label:``,children:a[s-1]};break;case 29:r.getLogger().debug(`Rule: node (NODE_ID separator): `,a[s]),this.$={id:a[s]};break;case 30:r.getLogger().debug(`Rule: node (NODE_ID nodeShapeNLabel separator): `,a[s-1],a[s]),this.$={id:a[s-1],label:a[s].label,typeStr:a[s].typeStr,directions:a[s].directions};break;case 31:r.getLogger().debug(`Rule: dirList: `,a[s]),this.$=[a[s]];break;case 32:r.getLogger().debug(`Rule: dirList: `,a[s-1],a[s]),this.$=[a[s-1]].concat(a[s]);break;case 33:r.getLogger().debug(`Rule: nodeShapeNLabel: `,a[s-2],a[s-1],a[s]),this.$={typeStr:a[s-2]+a[s],label:a[s-1]};break;case 34:r.getLogger().debug(`Rule: BLOCK_ARROW nodeShapeNLabel: `,a[s-3],a[s-2],` #3:`,a[s-1],a[s]),this.$={typeStr:a[s-3]+a[s],label:a[s-2],directions:a[s-1]};break;case 35:case 36:this.$={type:`classDef`,id:a[s-1].trim(),css:a[s].trim()};break;case 37:this.$={type:`applyClass`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 38:this.$={type:`applyStyles`,id:a[s-1].trim(),stylesStr:a[s].trim()}}},`anonymous`),table:[{9:1,10:[1,2]},{1:[3]},{10:t,11:3,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{8:[1,20]},e(u,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:t,21:r,28:i,29:a,31:o,39:s,43:c,46:l}),e(d,[2,16],{14:22,15:f,16:p}),e(d,[2,17]),e(d,[2,18]),e(d,[2,19]),e(d,[2,20]),e(d,[2,21]),e(d,[2,22]),e(m,[2,25],{27:[1,25]}),e(d,[2,26]),{19:26,26:12,31:o},{10:t,11:27,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(h,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(u,[2,13]),{26:35,31:o},{31:[2,14]},{17:[1,36]},e(m,[2,24]),{10:t,11:37,13:4,14:22,15:f,16:p,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(h,[2,30]),{18:[1,43]},{18:[1,44]},e(m,[2,23]),{18:[1,45]},{30:[1,46]},e(d,[2,28]),e(d,[2,35]),e(d,[2,36]),e(d,[2,37]),e(d,[2,38]),{36:[1,47]},{33:48,34:g},{15:[1,50]},e(d,[2,27]),e(h,[2,33]),{38:[1,51]},{33:52,34:g,38:[2,31]},{31:[2,15]},e(h,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};_.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return e.getLogger().debug(`Found block-beta`),10;case 1:return e.getLogger().debug(`Found id-block`),29;case 2:return e.getLogger().debug(`Found block`),10;case 3:e.getLogger().debug(`.`,t.yytext);break;case 4:e.getLogger().debug(`_`,t.yytext);break;case 5:return 5;case 6:return t.yytext=-1,28;case 7:return t.yytext=t.yytext.replace(/columns\s+/,``),e.getLogger().debug(`COLUMNS (LEX)`,t.yytext),28;case 8:this.pushState(`md_string`);break;case 9:return`MD_STR`;case 10:this.popState();break;case 11:this.pushState(`string`);break;case 12:e.getLogger().debug(`LEX: POPPING STR:`,t.yytext),this.popState();break;case 13:return e.getLogger().debug(`LEX: STR end:`,t.yytext),`STR`;case 14:return t.yytext=t.yytext.replace(/space\:/,``),e.getLogger().debug(`SPACE NUM (LEX)`,t.yytext),21;case 15:return t.yytext=`1`,e.getLogger().debug(`COLUMNS (LEX)`,t.yytext),21;case 16:return 42;case 17:return`LINKSTYLE`;case 18:return`INTERPOLATE`;case 19:return this.pushState(`CLASSDEF`),39;case 20:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 21:return this.popState(),this.pushState(`CLASSDEFID`),40;case 22:return this.popState(),41;case 23:return this.pushState(`CLASS`),43;case 24:return this.popState(),this.pushState(`CLASS_STYLE`),44;case 25:return this.popState(),45;case 26:return this.pushState(`STYLE_STMNT`),46;case 27:return this.popState(),this.pushState(`STYLE_DEFINITION`),47;case 28:return this.popState(),48;case 29:return this.pushState(`acc_title`),`acc_title`;case 30:return this.popState(),`acc_title_value`;case 31:return this.pushState(`acc_descr`),`acc_descr`;case 32:return this.popState(),`acc_descr_value`;case 33:this.pushState(`acc_descr_multiline`);break;case 34:this.popState();break;case 35:return`acc_descr_multiline_value`;case 36:return 30;case 37:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 38:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 39:return this.popState(),e.getLogger().debug(`Lex: ))`),`NODE_DEND`;case 40:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 41:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 42:return this.popState(),e.getLogger().debug(`Lex: (-`),`NODE_DEND`;case 43:return this.popState(),e.getLogger().debug(`Lex: -)`),`NODE_DEND`;case 44:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 45:return this.popState(),e.getLogger().debug(`Lex: ]]`),`NODE_DEND`;case 46:return this.popState(),e.getLogger().debug(`Lex: (`),`NODE_DEND`;case 47:return this.popState(),e.getLogger().debug(`Lex: ])`),`NODE_DEND`;case 48:return this.popState(),e.getLogger().debug(`Lex: /]`),`NODE_DEND`;case 49:return this.popState(),e.getLogger().debug(`Lex: /]`),`NODE_DEND`;case 50:return this.popState(),e.getLogger().debug(`Lex: )]`),`NODE_DEND`;case 51:return this.popState(),e.getLogger().debug(`Lex: )`),`NODE_DEND`;case 52:return this.popState(),e.getLogger().debug(`Lex: ]>`),`NODE_DEND`;case 53:return this.popState(),e.getLogger().debug(`Lex: ]`),`NODE_DEND`;case 54:return e.getLogger().debug(`Lexa: -)`),this.pushState(`NODE`),35;case 55:return e.getLogger().debug(`Lexa: (-`),this.pushState(`NODE`),35;case 56:return e.getLogger().debug(`Lexa: ))`),this.pushState(`NODE`),35;case 57:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 58:return e.getLogger().debug(`Lex: (((`),this.pushState(`NODE`),35;case 59:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 60:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 61:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 62:return e.getLogger().debug(`Lexc: >`),this.pushState(`NODE`),35;case 63:return e.getLogger().debug(`Lexa: ([`),this.pushState(`NODE`),35;case 64:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 65:return this.pushState(`NODE`),35;case 66:return this.pushState(`NODE`),35;case 67:return this.pushState(`NODE`),35;case 68:return this.pushState(`NODE`),35;case 69:return this.pushState(`NODE`),35;case 70:return this.pushState(`NODE`),35;case 71:return this.pushState(`NODE`),35;case 72:return e.getLogger().debug(`Lexa: [`),this.pushState(`NODE`),35;case 73:return this.pushState(`BLOCK_ARROW`),e.getLogger().debug(`LEX ARR START`),37;case 74:return e.getLogger().debug(`Lex: NODE_ID`,t.yytext),31;case 75:return e.getLogger().debug(`Lex: EOF`,t.yytext),8;case 76:this.pushState(`md_string`);break;case 77:this.pushState(`md_string`);break;case 78:return`NODE_DESCR`;case 79:this.popState();break;case 80:e.getLogger().debug(`Lex: Starting string`),this.pushState(`string`);break;case 81:e.getLogger().debug(`LEX ARR: Starting string`),this.pushState(`string`);break;case 82:return e.getLogger().debug(`LEX: NODE_DESCR:`,t.yytext),`NODE_DESCR`;case 83:e.getLogger().debug(`LEX POPPING`),this.popState();break;case 84:e.getLogger().debug(`Lex: =>BAE`),this.pushState(`ARROW_DIR`);break;case 85:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (right): dir:`,t.yytext),`DIR`;case 86:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (left):`,t.yytext),`DIR`;case 87:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (x):`,t.yytext),`DIR`;case 88:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (y):`,t.yytext),`DIR`;case 89:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (up):`,t.yytext),`DIR`;case 90:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (down):`,t.yytext),`DIR`;case 91:return t.yytext=`]>`,e.getLogger().debug(`Lex (ARROW_DIR end):`,t.yytext),this.popState(),this.popState(),`BLOCK_ARROW_END`;case 92:return e.getLogger().debug(`Lex: LINK`,`#`+t.yytext+`#`),15;case 93:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 94:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 95:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 96:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 97:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 98:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 99:this.pushState(`md_string`);break;case 100:return e.getLogger().debug(`Lex: Starting string`),this.pushState(`string`),`LINK_LABEL`;case 101:return this.popState(),e.getLogger().debug(`Lex: LINK`,`#`+t.yytext+`#`),15;case 102:return this.popState(),e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 103:return this.popState(),e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 104:return e.getLogger().debug(`Lex: COLON`,t.yytext),t.yytext=t.yytext.slice(1),27}},`anonymous`),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}}})();function v(){this.yy={}}return n(v,`Parser`),v.prototype=_,_.Parser=v,new v})();F.parser=F;var Se=F,I=new Map,L=[],R=new Map,z=`color`,B=`fill`,Ce=`bgFill`,we=`,`,V=new Map,H=``,Te=n(e=>s.sanitizeText(e,c()),`sanitizeText`),Ee=n(function(e,t=``){let n=V.get(e);n||(n={id:e,styles:[],textStyles:[]},V.set(e,n)),t?.split(we).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(z).exec(e)){let e=t.replace(B,Ce).replace(z,B);n.textStyles.push(e)}n.styles.push(t)})},`addStyleClass`),De=n(function(e,t=``){let n=I.get(e);t!=null&&(n.styles=t.split(we))},`addStyle2Node`),Oe=n(function(e,t){e.split(`,`).forEach(function(e){let n=I.get(e);if(n===void 0){let t=e.trim();n={id:t,type:`na`,children:[]},I.set(t,n)}n.classes||(n.classes=[]),n.classes.push(t)})},`setCssClass`),U=0,ke=n((t,n)=>{let r=t.flat(),i=[],a=r.find(e=>e?.type===`column-setting`)?.columns??-1;for(let t of r){if(typeof a==`number`&&a>0&&t.type!==`column-setting`&&typeof t.widthInColumns==`number`&&t.widthInColumns>a&&e.warn(`Block ${t.id} width ${t.widthInColumns} exceeds configured column width ${a}`),t.label&&=Te(t.label),t.type===`classDef`){Ee(t.id,t.css);continue}if(t.type===`applyClass`){Oe(t.id,t?.styleClass??``);continue}if(t.type===`applyStyles`){t?.stylesStr&&De(t.id,t?.stylesStr);continue}if(t.type===`column-setting`)n.columns=t.columns??-1;else if(t.type===`edge`){let e=(R.get(t.id)??0)+1;R.set(t.id,e),t.id=e+`-`+t.id,L.push(t)}else{t.label||=t.type===`composite`?``:t.id;let e=I.get(t.id);if(e===void 0?(t.type===`composite`&&(t.colorIndex=U++),I.set(t.id,t)):(t.type!==`na`&&(e.type=t.type),t.label!==t.id&&(e.label=t.label)),t.children&&ke(t.children,t),t.type===`space`){let e=t.width??1;for(let n=0;n{e.debug(`Clear called`),r(),G={id:`root`,type:`composite`,children:[],columns:-1},I=new Map([[`root`,G]]),W=[],V=new Map,L=[],R=new Map,H=``,U=0},`clear`);function je(t){switch(e.debug(`typeStr2Type`,t),t){case`[]`:return`square`;case`()`:return e.debug(`we have a round`),`round`;case`(())`:return`circle`;case`>]`:return`rect_left_inv_arrow`;case`{}`:return`diamond`;case`{{}}`:return`hexagon`;case`([])`:return`stadium`;case`[[]]`:return`subroutine`;case`[()]`:return`cylinder`;case`((()))`:return`doublecircle`;case`[//]`:return`lean_right`;case`[\\\\]`:return`lean_left`;case`[/\\]`:return`trapezoid`;case`[\\/]`:return`inv_trapezoid`;case`<[]>`:return`block_arrow`;default:return`na`}}n(je,`typeStr2Type`);function Me(t){switch(e.debug(`typeStr2Type`,t),t){case`==`:return`thick`;default:return`normal`}}n(Me,`edgeTypeStr2Type`);function Ne(e){switch(e.trim().slice(-1)){case`x`:return`arrow_cross`;case`o`:return`arrow_circle`;case`>`:return`arrow_point`;default:return``}}n(Ne,`edgeStrToEdgeData`);function Pe(e){switch(e.trim().charAt(0)){case`x`:return`arrow_cross`;case`o`:return`arrow_circle`;case`<`:return`arrow_point`;default:return`arrow_open`}}n(Pe,`edgeStrToEdgeStartData`);function Fe(e){return e.includes(`==`)?`thick`:`normal`}n(Fe,`edgeStrToThickness`);function Ie(e){return e.includes(`.-`)?`dotted`:`solid`}n(Ie,`edgeStrToPattern`);var Le=0,Re={getConfig:n(()=>i().block,`getConfig`),typeStr2Type:je,edgeTypeStr2Type:Me,edgeStrToEdgeData:Ne,edgeStrToEdgeStartData:Pe,edgeStrToThickness:Fe,edgeStrToPattern:Ie,getLogger:n(()=>e,`getLogger`),getBlocksFlat:n(()=>[...I.values()],`getBlocksFlat`),getBlocks:n(()=>W||[],`getBlocks`),getEdges:n(()=>L,`getEdges`),setHierarchy:n(e=>{G.children=e,ke(e,G),W=G.children},`setHierarchy`),getBlock:n(e=>I.get(e),`getBlock`),setBlock:n(e=>{I.set(e.id,e)},`setBlock`),getColumns:n(e=>{let t=I.get(e);return t?t.columns?t.columns:t.children?t.children.length:-1:-1},`getColumns`),getClasses:n(function(){return V},`getClasses`),clear:Ae,generateId:n(()=>(Le++,`id-`+Math.random().toString(36).substr(2,12)+`-`+Le),`generateId`),setDiagramId:n(e=>{H=e},`setDiagramId`),getDiagramId:n(()=>H,`getDiagramId`)},ze=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!re(t,r))return``;let i=ae(e.look),a=oe(n),o=``;for(let t=0;t{let n=l,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return o(r,i,a,t)},`fade`),Be=n(e=>`${ze(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + + + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + /* From the theme, as every other diagram does. Pinned at 1px here, so block drew a + thinner border than an identical flowchart node under any theme asking for more -- + the neo theme asks for 2. Nothing downstream corrected it: the neo rules set stroke + and filter, never stroke-width. */ + stroke-width: ${e.strokeWidth??1}px; + } + .flowchart-label text { + text-anchor: middle; + } + // .flowchart-label .text-outer-tspan { + // text-anchor: middle; + // } + // .flowchart-label .text-inner-tspan { + // text-anchor: start; + // } + + .node .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: 2.0px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + /* + * This is for backward compatibility with existing code that didn't + * add a \`

\` around edge labels. + * + * TODO: We should probably remove this in a future release. + */ + p { + margin: 0; + padding: 0; + display: inline; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${e.edgeLabelBackground}; + } + + .node .cluster { + // fill: ${K(e.mainBkg,.5)}; + fill: ${K(e.clusterBkg,.5)}; + stroke: ${K(e.clusterBorder,.2)}; + box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .flowchartTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + ${me()} +`,`getStyles`);function q(e,t){if(e===0||!Number.isInteger(e))throw Error(`Columns must be an integer !== 0.`);if(t<0||!Number.isInteger(t))throw Error(`Position must be a non-negative integer.`+t);return e<0?{px:t,py:0}:e===1?{px:0,py:t}:{px:t%e,py:Math.floor(t/e)}}n(q,`calculateBlockPosition`);var Ve=n(t=>{let n=0,r=0;for(let i of t.children){let{width:t,height:a,x:o,y:s}=i.size??{width:0,height:0,x:0,y:0};if(e.debug(`getMaxChildSize abc95 child:`,i.id,`width:`,t,`height:`,a,`x:`,o,`y:`,s,i.type),i.type===`space`)continue;let c=t/(i.widthInColumns??1);c>n&&(n=c),a>r&&(r=a)}return{width:n,height:r}},`getMaxChildSize`);function J(t,n,r=0,i=0,a=8){e.debug(`setBlockSizes abc95 (start)`,t.id,t?.size?.x,`block width =`,t?.size,`siblingWidth`,r),t?.size?.width||(t.size={width:r,height:i,x:0,y:0});let o=0,s=0;if(t.children?.length>0){for(let e of t.children)J(e,n,0,0,a);let c=Ve(t);o=c.width,s=c.height,e.debug(`setBlockSizes abc95 maxWidth of`,t.id,`:s children is `,o,s);for(let n of t.children)n.size&&(e.debug(`abc95 Setting size of children of ${t.id} id=${n.id} ${o} ${s} ${JSON.stringify(n.size)}`),n.size.width=o*(n.widthInColumns??1)+a*((n.widthInColumns??1)-1),n.size.height=s,n.size.x=0,n.size.y=0,e.debug(`abc95 updating size of ${t.id} children child:${n.id} maxWidth:${o} maxHeight:${s}`));for(let e of t.children)J(e,n,o,s,a);let l=t.columns??-1,u=0;for(let e of t.children)u+=e.widthInColumns??1;let d=t.children.length;l>0&&l0?Math.min(t.children.length,l):t.children.length;if(n>0){let r=(p-n*a-a)/n;e.debug(`abc95 (growing to fit) width`,t.id,p,t.size?.width,r);for(let e of t.children)e.size&&(e.size.width=r)}}t.size={width:p,height:m,x:0,y:0}}e.debug(`setBlockSizes abc94 (done)`,t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}n(J,`setBlockSizes`);function Y(t,n,r=8){e.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);let i=t.columns??-1;if(e.debug(`layoutBlocks columns abc95`,t.id,`=>`,i,t),t.children&&t.children.length>0){let a=t?.children[0]?.size?.width??0,o=t.children.length*a+(t.children.length-1)*r;e.debug(`widthOfChildren 88`,o,`posX`);let s=new Map;{let e=0;for(let n of t.children){if(!n.size)continue;let{py:t}=q(i,e),r=s.get(t)??0;n.size.height>r&&s.set(t,n.size.height);let a=n?.widthInColumns??1;i>0&&(a=Math.min(a,i-e%i)),e+=a}}let c=new Map;{let e=0,t=[...s.keys()].sort((e,t)=>e-t);for(let n of t)c.set(n,e),e+=(s.get(n)??0)+r}let l=0;e.debug(`abc91 block?.size?.x`,t.id,t?.size?.x);let u=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-r,d=0;for(let a of t.children){let o=t;if(!a.size)continue;let{width:f,height:p}=a.size,{px:m,py:h}=q(i,l);if(h!=d&&(d=h,u=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-r,e.debug(`New row in layout for block`,t.id,` and child `,a.id,d)),e.debug(`abc89 layout blocks (child) id: ${a.id} Pos: ${l} (px, py) ${m},${h} (${o?.size?.x},${o?.size?.y}) parent: ${o.id} width: ${f}${r}`),o.size){let t=f/2;a.size.x=u+r+t,e.debug(`abc91 layout blocks (calc) px, pyid:${a.id} startingPos=X${u} new startingPosX${a.size.x} ${t} padding=${r} width=${f} halfWidth=${t} => x:${a.size.x} y:${a.size.y} ${a.widthInColumns} (width * (child?.w || 1)) / 2 ${f*(a?.widthInColumns??1)/2}`),u=a.size.x+t;let n=c.get(h)??0,i=s.get(h)??p;a.size.y=o.size.y-o.size.height/2+n+i/2+r,e.debug(`abc88 layout blocks (calc) px, pyid:${a.id}startingPosX${u}${r}${t}=>x:${a.size.x}y:${a.size.y}${a.widthInColumns}(width * (child?.w || 1)) / 2${f*(a?.widthInColumns??1)/2}`)}a.children&&Y(a,n,r);let g=a?.widthInColumns??1;i>0&&(g=Math.min(g,i-l%i)),l+=g,e.debug(`abc88 columnsPos`,a,l)}}e.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}n(Y,`layoutBlocks`);function X(e,{minX:t,minY:n,maxX:r,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(e.size&&e.id!==`root`){let{x:a,y:o,width:s,height:c}=e.size;a-s/2r&&(r=a+s/2),o+c/2>i&&(i=o+c/2)}if(e.children)for(let a of e.children)({minX:t,minY:n,maxX:r,maxY:i}=X(a,{minX:t,minY:n,maxX:r,maxY:i}));return{minX:t,minY:n,maxX:r,maxY:i}}n(X,`findBounds`);function He(t){let n=t.getBlock(`root`);if(!n)return;let r=c()?.block?.padding??8;J(n,t,0,0,r),Y(n,t,r),e.debug(`getBlocks`,JSON.stringify(n,null,2));let{minX:i,minY:a,maxX:o,maxY:s}=X(n),l=s-a;return{x:i,y:a,width:o-i,height:l}}n(He,`layout`);function Z(e,t,n=!1){let r=e,a=`default`;(r?.classes?.length||0)>0&&(a=(r?.classes??[]).join(` `)),a+=` flowchart-label`;let o=(r?.classes??[]).flatMap(e=>t.getClasses().get(e)?.styles??[]),s=0,c=`rect`,l;switch(r.type){case`round`:s=5,c=`rect`;break;case`composite`:s=0,c=`composite`,l=0;break;case`square`:c=`rect`;break;case`diamond`:c=`question`;break;case`hexagon`:c=`hexagon`;break;case`block_arrow`:c=`block_arrow`;break;case`odd`:c=`rect_left_inv_arrow`;break;case`lean_right`:c=`lean_right`;break;case`lean_left`:c=`lean_left`;break;case`trapezoid`:c=`trapezoid`;break;case`inv_trapezoid`:c=`inv_trapezoid`;break;case`rect_left_inv_arrow`:c=`rect_left_inv_arrow`;break;case`circle`:c=`circle`;break;case`ellipse`:c=`ellipse`;break;case`stadium`:c=`stadium`;break;case`subroutine`:c=`subroutine`;break;case`cylinder`:c=`cylinder`;break;case`group`:c=`rect`;break;case`doublecircle`:c=`doublecircle`;break;default:c=`rect`}let u=M(r?.styles??[]),d=r.label,f=r.size??{width:0,height:0,x:0,y:0},p=t.getDiagramId();return{labelStyle:u.labelStyle,shape:c,label:d,labelText:d,rx:s,ry:s,class:a,cssClasses:a,cssStyles:r?.styles??[],cssCompiledStyles:o,style:u.style,id:r.id,domId:p?`${p}-${r.id}`:r.id,isGroup:!1,directions:r.directions,width:f.width||void 0,height:f.height||void 0,wrappingWidth:f.width||1/0,x:f.x,y:f.y,positioned:n,intersect:void 0,padding:l??i()?.block?.padding??0,widthInColumns:r.widthInColumns??1,colorIndex:r.colorIndex,look:i().look}}n(Z,`getNodeFromBlock`);async function Ue(e,t,n){let r=Z(t,n,!1);if(t.type===`group`)return;let a=i(),o=await N(e,r,{config:a}),s=o.node()?.getBBox()??{width:0,height:0},c=n.getBlock(r.id);c.size={width:s.width,height:s.height,x:0,y:0,node:o},n.setBlock(c),o.remove()}n(Ue,`calculateBlockSize`);async function We(e,t,n){let r=Z(t,n,!0);if(n.getBlock(r.id).type!==`space`){let n=i(),a=await N(e,r,{config:n});r.colorIndex!==void 0&&se(a,r.colorIndex,n.theme,n.themeVariables?.borderColorArray),t.intersect=r?.intersect,ce(r)}}n(We,`insertBlockPositioned`);async function Q(e,t,n,r){for(let i of t)await r(e,i,n),i.children&&await Q(e,i.children,n,r)}n(Q,`performOperations`);async function Ge(e,t,n){await Q(e,t,n,Ue)}n(Ge,`calculateBlockSizes`);async function Ke(e,t,n){await Q(e,t,n,We)}n(Ke,`insertBlocks`);async function $(e,t,n,r,i){let a=new he({multigraph:!0,compound:!0});a.setGraph({rankdir:`TB`,nodesep:10,ranksep:10,marginx:8,marginy:8});for(let e of n)e.size&&a.setNode(e.id,{width:e.size.width,height:e.size.height,intersect:e.intersect});for(let n of t)if(n.start&&n.end){let t=r.getBlock(n.start),o=r.getBlock(n.end);if(t?.size&&o?.size){let r=t.size,s=o.size,c=[{x:r.x,y:r.y},{x:r.x+(s.x-r.x)/2,y:r.y+(s.y-r.y)/2},{x:s.x,y:s.y}],l=i?`${i}-${n.id}`:n.id,u=`${n.thickness===`thick`?`edge-thickness-thick`:`edge-thickness-normal`} ${n.pattern===`dotted`?`edge-pattern-dotted`:`edge-pattern-solid`} flowchart-link LS-a1 LE-b1`;de(e,{...n,id:l,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:c,classes:u},{},`block`,a.node(n.start),a.node(n.end),i),n.label&&(await fe(e,{...n,label:n.label,labelStyle:`stroke: #333; stroke-width: 1.5px;fill:none;`,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:c,classes:u}),le({...n,x:c[1].x,y:c[1].y},{originalPath:c}))}}}n($,`insertEdges`);var qe={parser:Se,db:Re,renderer:{draw:n(async function(n,r,o,s){let{securityLevel:c,block:l}=i(),u=s.db;u.setDiagramId(r);let d;c===`sandbox`&&(d=t(`#i`+r));let f=t(c===`sandbox`?d.nodes()[0].contentDocument.body:`body`),p=c===`sandbox`?f.select(`[id="${r}"]`):t(`[id="${r}"]`);ue(p,i()),pe(p,[`point`,`circle`,`cross`],s.type,r);let m=u.getBlocks(),h=u.getBlocksFlat(),g=u.getEdges(),_=p.insert(`g`).attr(`class`,`block`);await Ge(_,m,u);let v=He(u);await Ke(_,m,u),await $(_,g,h,u,r);let y=_.node()?.getBBox(),b=y&&Number.isFinite(y.width)&&Number.isFinite(y.height)?y:v;if(b){let t=Math.max(1,Math.round(.125*(b.width/b.height))),n=b.height+t+10,r=b.width+10,{useMaxWidth:i}=l;a(p,n,r,!!i),e.debug(`Here Bounds`,v,b),p.attr(`viewBox`,`${b.x-5} ${b.y-5} ${b.width+10} ${b.height+10}`)}},`draw`),getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`)},styles:Be};export{qe as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js b/frontend/dist/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js new file mode 100644 index 0000000..dd8eef1 --- /dev/null +++ b/frontend/dist/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js @@ -0,0 +1,38 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,c as a,r as o,s,v as l,x as u,y as d,z as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{_ as p,n as m,r as h}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{r as g,s as _}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{a as v}from"./chunk-GWA4HPMP-C1P4FmAY.js";var y=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,24],r=[1,25],i=[1,26],a=[1,27],o=[1,28],s=[1,63],l=[1,64],u=[1,65],d=[1,66],f=[1,67],p=[1,68],m=[1,69],h=[1,29],g=[1,30],_=[1,31],v=[1,32],y=[1,33],b=[1,34],x=[1,35],S=[1,36],C=[1,37],w=[1,38],T=[1,39],E=[1,40],D=[1,41],O=[1,42],k=[1,43],A=[1,44],j=[1,45],M=[1,46],N=[1,47],P=[1,48],F=[1,50],I=[1,51],L=[1,52],R=[1,53],z=[1,54],B=[1,55],V=[1,56],H=[1,57],U=[1,58],W=[1,59],G=[1,60],ee=[14,42],te=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],ne=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],K=[1,82],q=[1,83],J=[1,84],Y=[1,85],X=[12,14,42],re=[12,14,33,42],ie=[12,14,33,42,76,77,79,80],Z=[12,33],ae=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],oe={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:`error`,6:`direction_tb`,7:`direction_bt`,8:`direction_rl`,9:`direction_lr`,11:`C4_CONTEXT`,12:`NEWLINE`,14:`EOF`,15:`C4_CONTAINER`,16:`C4_COMPONENT`,17:`C4_DYNAMIC`,18:`C4_DEPLOYMENT`,22:`title`,23:`accDescription`,24:`acc_title`,25:`acc_title_value`,26:`acc_descr`,27:`acc_descr_value`,28:`acc_descr_multiline_value`,33:`LBRACE`,34:`ENTERPRISE_BOUNDARY`,36:`SYSTEM_BOUNDARY`,37:`BOUNDARY`,38:`CONTAINER_BOUNDARY`,39:`NODE`,40:`NODE_L`,41:`NODE_R`,42:`RBRACE`,44:`PERSON`,45:`PERSON_EXT`,46:`SYSTEM`,47:`SYSTEM_DB`,48:`SYSTEM_QUEUE`,49:`SYSTEM_EXT`,50:`SYSTEM_EXT_DB`,51:`SYSTEM_EXT_QUEUE`,52:`CONTAINER`,53:`CONTAINER_DB`,54:`CONTAINER_QUEUE`,55:`CONTAINER_EXT`,56:`CONTAINER_EXT_DB`,57:`CONTAINER_EXT_QUEUE`,58:`COMPONENT`,59:`COMPONENT_DB`,60:`COMPONENT_QUEUE`,61:`COMPONENT_EXT`,62:`COMPONENT_EXT_DB`,63:`COMPONENT_EXT_QUEUE`,64:`REL`,65:`BIREL`,66:`REL_U`,67:`REL_D`,68:`REL_L`,69:`REL_R`,70:`REL_B`,71:`REL_INDEX`,72:`UPDATE_EL_STYLE`,73:`UPDATE_REL_STYLE`,74:`UPDATE_LAYOUT_CONFIG`,76:`STR`,77:`STR_KEY`,78:`STR_VALUE`,79:`ATTRIBUTE`,80:`ATTRIBUTE_EMPTY`},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:r.setDirection(`TB`);break;case 4:r.setDirection(`BT`);break;case 5:r.setDirection(`RL`);break;case 6:r.setDirection(`LR`);break;case 8:case 9:case 10:case 11:case 12:r.setC4Type(a[s-3]);break;case 19:r.setTitle(a[s].substring(6)),this.$=a[s].substring(6);break;case 20:r.setAccDescription(a[s].substring(15)),this.$=a[s].substring(15);break;case 21:this.$=a[s].trim(),r.setTitle(this.$);break;case 22:case 23:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 28:a[s].splice(2,0,`ENTERPRISE`),r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 29:a[s].splice(2,0,`SYSTEM`),r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 30:r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 31:a[s].splice(2,0,`CONTAINER`),r.addContainerBoundary(...a[s]),this.$=a[s];break;case 32:r.addDeploymentNode(`node`,...a[s]),this.$=a[s];break;case 33:r.addDeploymentNode(`nodeL`,...a[s]),this.$=a[s];break;case 34:r.addDeploymentNode(`nodeR`,...a[s]),this.$=a[s];break;case 35:r.popBoundaryParseStack();break;case 39:r.addPersonOrSystem(`person`,...a[s]),this.$=a[s];break;case 40:r.addPersonOrSystem(`external_person`,...a[s]),this.$=a[s];break;case 41:r.addPersonOrSystem(`system`,...a[s]),this.$=a[s];break;case 42:r.addPersonOrSystem(`system_db`,...a[s]),this.$=a[s];break;case 43:r.addPersonOrSystem(`system_queue`,...a[s]),this.$=a[s];break;case 44:r.addPersonOrSystem(`external_system`,...a[s]),this.$=a[s];break;case 45:r.addPersonOrSystem(`external_system_db`,...a[s]),this.$=a[s];break;case 46:r.addPersonOrSystem(`external_system_queue`,...a[s]),this.$=a[s];break;case 47:r.addContainer(`container`,...a[s]),this.$=a[s];break;case 48:r.addContainer(`container_db`,...a[s]),this.$=a[s];break;case 49:r.addContainer(`container_queue`,...a[s]),this.$=a[s];break;case 50:r.addContainer(`external_container`,...a[s]),this.$=a[s];break;case 51:r.addContainer(`external_container_db`,...a[s]),this.$=a[s];break;case 52:r.addContainer(`external_container_queue`,...a[s]),this.$=a[s];break;case 53:r.addComponent(`component`,...a[s]),this.$=a[s];break;case 54:r.addComponent(`component_db`,...a[s]),this.$=a[s];break;case 55:r.addComponent(`component_queue`,...a[s]),this.$=a[s];break;case 56:r.addComponent(`external_component`,...a[s]),this.$=a[s];break;case 57:r.addComponent(`external_component_db`,...a[s]),this.$=a[s];break;case 58:r.addComponent(`external_component_queue`,...a[s]),this.$=a[s];break;case 60:r.addRel(`rel`,...a[s]),this.$=a[s];break;case 61:r.addRel(`birel`,...a[s]),this.$=a[s];break;case 62:r.addRel(`rel_u`,...a[s]),this.$=a[s];break;case 63:r.addRel(`rel_d`,...a[s]),this.$=a[s];break;case 64:r.addRel(`rel_l`,...a[s]),this.$=a[s];break;case 65:r.addRel(`rel_r`,...a[s]),this.$=a[s];break;case 66:r.addRel(`rel_b`,...a[s]),this.$=a[s];break;case 67:a[s].splice(0,1),r.addRel(`rel`,...a[s]),this.$=a[s];break;case 68:r.updateElStyle(`update_el_style`,...a[s]),this.$=a[s];break;case 69:r.updateRelStyle(`update_rel_style`,...a[s]),this.$=a[s];break;case 70:r.updateLayoutConfig(`update_layout_config`,...a[s]),this.$=a[s];break;case 71:this.$=[a[s]];break;case 72:a[s].unshift(a[s-1]),this.$=a[s];break;case 73:case 75:this.$=a[s].trim();break;case 74:let e={};e[a[s-1].trim()]=a[s].trim(),this.$=e;break;case 76:this.$=``}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:70,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:71,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:72,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:73,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{14:[1,74]},e(ee,[2,13],{43:23,29:49,30:61,32:62,20:75,34:s,36:l,37:u,38:d,39:f,40:p,41:m,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G}),e(ee,[2,14]),e(te,[2,16],{12:[1,76]}),e(ee,[2,36],{12:[1,77]}),e(ne,[2,19]),e(ne,[2,20]),{25:[1,78]},{27:[1,79]},e(ne,[2,23]),{35:80,75:81,76:K,77:q,79:J,80:Y},{35:86,75:81,76:K,77:q,79:J,80:Y},{35:87,75:81,76:K,77:q,79:J,80:Y},{35:88,75:81,76:K,77:q,79:J,80:Y},{35:89,75:81,76:K,77:q,79:J,80:Y},{35:90,75:81,76:K,77:q,79:J,80:Y},{35:91,75:81,76:K,77:q,79:J,80:Y},{35:92,75:81,76:K,77:q,79:J,80:Y},{35:93,75:81,76:K,77:q,79:J,80:Y},{35:94,75:81,76:K,77:q,79:J,80:Y},{35:95,75:81,76:K,77:q,79:J,80:Y},{35:96,75:81,76:K,77:q,79:J,80:Y},{35:97,75:81,76:K,77:q,79:J,80:Y},{35:98,75:81,76:K,77:q,79:J,80:Y},{35:99,75:81,76:K,77:q,79:J,80:Y},{35:100,75:81,76:K,77:q,79:J,80:Y},{35:101,75:81,76:K,77:q,79:J,80:Y},{35:102,75:81,76:K,77:q,79:J,80:Y},{35:103,75:81,76:K,77:q,79:J,80:Y},{35:104,75:81,76:K,77:q,79:J,80:Y},e(X,[2,59]),{35:105,75:81,76:K,77:q,79:J,80:Y},{35:106,75:81,76:K,77:q,79:J,80:Y},{35:107,75:81,76:K,77:q,79:J,80:Y},{35:108,75:81,76:K,77:q,79:J,80:Y},{35:109,75:81,76:K,77:q,79:J,80:Y},{35:110,75:81,76:K,77:q,79:J,80:Y},{35:111,75:81,76:K,77:q,79:J,80:Y},{35:112,75:81,76:K,77:q,79:J,80:Y},{35:113,75:81,76:K,77:q,79:J,80:Y},{35:114,75:81,76:K,77:q,79:J,80:Y},{35:115,75:81,76:K,77:q,79:J,80:Y},{20:116,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{12:[1,118],33:[1,117]},{35:119,75:81,76:K,77:q,79:J,80:Y},{35:120,75:81,76:K,77:q,79:J,80:Y},{35:121,75:81,76:K,77:q,79:J,80:Y},{35:122,75:81,76:K,77:q,79:J,80:Y},{35:123,75:81,76:K,77:q,79:J,80:Y},{35:124,75:81,76:K,77:q,79:J,80:Y},{35:125,75:81,76:K,77:q,79:J,80:Y},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},e(ee,[2,15]),e(te,[2,17],{21:22,19:130,22:t,23:r,24:i,26:a,28:o}),e(ee,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:t,23:r,24:i,26:a,28:o,34:s,36:l,37:u,38:d,39:f,40:p,41:m,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G}),e(ne,[2,21]),e(ne,[2,22]),e(X,[2,39]),e(re,[2,71],{75:81,35:132,76:K,77:q,79:J,80:Y}),e(ie,[2,73]),{78:[1,133]},e(ie,[2,75]),e(ie,[2,76]),e(X,[2,40]),e(X,[2,41]),e(X,[2,42]),e(X,[2,43]),e(X,[2,44]),e(X,[2,45]),e(X,[2,46]),e(X,[2,47]),e(X,[2,48]),e(X,[2,49]),e(X,[2,50]),e(X,[2,51]),e(X,[2,52]),e(X,[2,53]),e(X,[2,54]),e(X,[2,55]),e(X,[2,56]),e(X,[2,57]),e(X,[2,58]),e(X,[2,60]),e(X,[2,61]),e(X,[2,62]),e(X,[2,63]),e(X,[2,64]),e(X,[2,65]),e(X,[2,66]),e(X,[2,67]),e(X,[2,68]),e(X,[2,69]),e(X,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},e(Z,[2,28]),e(Z,[2,29]),e(Z,[2,30]),e(Z,[2,31]),e(Z,[2,32]),e(Z,[2,33]),e(Z,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},e(te,[2,18]),e(ee,[2,38]),e(re,[2,72]),e(ie,[2,74]),e(X,[2,24]),e(X,[2,35]),e(ae,[2,25]),e(ae,[2,26],{12:[1,138]}),e(ae,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,l=``,u=0,d=0,f=0,p=2,m=1,h=o.slice.call(arguments,1),g=Object.create(this.lexer),_={yy:{}};for(var v in this.yy)Object.prototype.hasOwnProperty.call(this.yy,v)&&(_.yy[v]=this.yy[v]);g.setInput(e,_.yy),_.yy.lexer=g,_.yy.parser=this,g.yylloc===void 0&&(g.yylloc={});var y=g.yylloc;o.push(y);var b=g.options&&g.options.ranges;this.parseError=typeof _.yy.parseError==`function`?_.yy.parseError:Object.getPrototypeOf(this).parseError;function x(e){r.length-=2*e,a.length-=e,o.length-=e}n(x,`popStack`);function S(){var e=i.pop()||g.lex()||m;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(S,`lex`);for(var C,w,T,E,D,O={},k,A,j,M;;){if(T=r[r.length-1],this.defaultActions[T]?E=this.defaultActions[T]:(C??=S(),E=s[T]&&s[T][C]),E===void 0||!E.length||!E[0]){var N=``;for(k in M=[],s[T])this.terminals_[k]&&k>p&&M.push(`'`+this.terminals_[k]+`'`);N=g.showPosition?`Parse error on line `+(u+1)+`: +`+g.showPosition()+` +Expecting `+M.join(`, `)+`, got '`+(this.terminals_[C]||C)+`'`:`Parse error on line `+(u+1)+`: Unexpected `+(C==m?`end of input`:`'`+(this.terminals_[C]||C)+`'`),this.parseError(N,{text:g.match,token:this.terminals_[C]||C,line:g.yylineno,loc:y,expected:M})}if(E[0]instanceof Array&&E.length>1)throw Error(`Parse Error: multiple actions possible at state: `+T+`, token: `+C);switch(E[0]){case 1:r.push(C),a.push(g.yytext),o.push(g.yylloc),r.push(E[1]),C=null,w?(C=w,w=null):(d=g.yyleng,l=g.yytext,u=g.yylineno,y=g.yylloc,f>0&&f--);break;case 2:if(A=this.productions_[E[1]][1],O.$=a[a.length-A],O._$={first_line:o[o.length-(A||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(A||1)].first_column,last_column:o[o.length-1].last_column},b&&(O._$.range=[o[o.length-(A||1)].range[0],o[o.length-1].range[1]]),D=this.performAction.apply(O,[l,d,u,_.yy,E[1],a,o].concat(h)),D!==void 0)return D;A&&(r=r.slice(0,-1*A*2),a=a.slice(0,-1*A),o=o.slice(0,-1*A)),r.push(this.productions_[E[1]][0]),a.push(O.$),o.push(O._$),j=s[r[r.length-2]][r[r.length-1]],r.push(j);break;case 3:return!0}}return!0},`parse`)};oe.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return 6;case 1:return 7;case 2:return 8;case 3:return 9;case 4:return 22;case 5:return 23;case 6:return this.begin(`acc_title`),24;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),26;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:break;case 14:c;break;case 15:return 12;case 16:break;case 17:return 11;case 18:return 15;case 19:return 16;case 20:return 17;case 21:return 18;case 22:return this.begin(`person_ext`),45;case 23:return this.begin(`person`),44;case 24:return this.begin(`system_ext_queue`),51;case 25:return this.begin(`system_ext_db`),50;case 26:return this.begin(`system_ext`),49;case 27:return this.begin(`system_queue`),48;case 28:return this.begin(`system_db`),47;case 29:return this.begin(`system`),46;case 30:return this.begin(`boundary`),37;case 31:return this.begin(`enterprise_boundary`),34;case 32:return this.begin(`system_boundary`),36;case 33:return this.begin(`container_ext_queue`),57;case 34:return this.begin(`container_ext_db`),56;case 35:return this.begin(`container_ext`),55;case 36:return this.begin(`container_queue`),54;case 37:return this.begin(`container_db`),53;case 38:return this.begin(`container`),52;case 39:return this.begin(`container_boundary`),38;case 40:return this.begin(`component_ext_queue`),63;case 41:return this.begin(`component_ext_db`),62;case 42:return this.begin(`component_ext`),61;case 43:return this.begin(`component_queue`),60;case 44:return this.begin(`component_db`),59;case 45:return this.begin(`component`),58;case 46:return this.begin(`node`),39;case 47:return this.begin(`node`),39;case 48:return this.begin(`node_l`),40;case 49:return this.begin(`node_r`),41;case 50:return this.begin(`rel`),64;case 51:return this.begin(`birel`),65;case 52:return this.begin(`rel_u`),66;case 53:return this.begin(`rel_u`),66;case 54:return this.begin(`rel_d`),67;case 55:return this.begin(`rel_d`),67;case 56:return this.begin(`rel_l`),68;case 57:return this.begin(`rel_l`),68;case 58:return this.begin(`rel_r`),69;case 59:return this.begin(`rel_r`),69;case 60:return this.begin(`rel_b`),70;case 61:return this.begin(`rel_index`),71;case 62:return this.begin(`update_el_style`),72;case 63:return this.begin(`update_rel_style`),73;case 64:return this.begin(`update_layout_config`),74;case 65:return`EOF_IN_STRUCT`;case 66:return this.begin(`attribute`),`ATTRIBUTE_EMPTY`;case 67:this.begin(`attribute`);break;case 68:this.popState(),this.popState();break;case 69:return 80;case 70:break;case 71:return 80;case 72:this.begin(`string`);break;case 73:this.popState();break;case 74:return`STR`;case 75:this.begin(`string_kv`);break;case 76:return this.begin(`string_kv_key`),`STR_KEY`;case 77:this.popState(),this.begin(`string_kv_value`);break;case 78:return`STR_VALUE`;case 79:this.popState(),this.popState();break;case 80:return`STR`;case 81:return`LBRACE`;case 82:return`RBRACE`;case 83:return`SPACE`;case 84:return`EOL`;case 85:return 14}},`anonymous`),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:title\s[^#\n;]+)/,/^(?:accDescription\s[^#\n;]+)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:C4Context\b)/,/^(?:C4Container\b)/,/^(?:C4Component\b)/,/^(?:C4Dynamic\b)/,/^(?:C4Deployment\b)/,/^(?:Person_Ext\b)/,/^(?:Person\b)/,/^(?:SystemQueue_Ext\b)/,/^(?:SystemDb_Ext\b)/,/^(?:System_Ext\b)/,/^(?:SystemQueue\b)/,/^(?:SystemDb\b)/,/^(?:System\b)/,/^(?:Boundary\b)/,/^(?:Enterprise_Boundary\b)/,/^(?:System_Boundary\b)/,/^(?:ContainerQueue_Ext\b)/,/^(?:ContainerDb_Ext\b)/,/^(?:Container_Ext\b)/,/^(?:ContainerQueue\b)/,/^(?:ContainerDb\b)/,/^(?:Container\b)/,/^(?:Container_Boundary\b)/,/^(?:ComponentQueue_Ext\b)/,/^(?:ComponentDb_Ext\b)/,/^(?:Component_Ext\b)/,/^(?:ComponentQueue\b)/,/^(?:ComponentDb\b)/,/^(?:Component\b)/,/^(?:Deployment_Node\b)/,/^(?:Node\b)/,/^(?:Node_L\b)/,/^(?:Node_R\b)/,/^(?:Rel\b)/,/^(?:BiRel\b)/,/^(?:Rel_Up\b)/,/^(?:Rel_U\b)/,/^(?:Rel_Down\b)/,/^(?:Rel_D\b)/,/^(?:Rel_Left\b)/,/^(?:Rel_L\b)/,/^(?:Rel_Right\b)/,/^(?:Rel_R\b)/,/^(?:Rel_Back\b)/,/^(?:RelIndex\b)/,/^(?:UpdateElementStyle\b)/,/^(?:UpdateRelStyle\b)/,/^(?:UpdateLayoutConfig\b)/,/^(?:$)/,/^(?:[(][ ]*[,])/,/^(?:[(])/,/^(?:[)])/,/^(?:,,)/,/^(?:,)/,/^(?:[ ]*["]["])/,/^(?:[ ]*["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[ ]*[\$])/,/^(?:[^=]*)/,/^(?:[=][ ]*["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:[^,]+)/,/^(?:\{)/,/^(?:\})/,/^(?:[\s]+)/,/^(?:[\n\r]+)/,/^(?:$)/],conditions:{acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},string_kv_value:{rules:[78,79],inclusive:!1},string_kv_key:{rules:[77],inclusive:!1},string_kv:{rules:[76],inclusive:!1},string:{rules:[73,74],inclusive:!1},attribute:{rules:[68,69,70,71,72,75,80],inclusive:!1},update_layout_config:{rules:[65,66,67,68],inclusive:!1},update_rel_style:{rules:[65,66,67,68],inclusive:!1},update_el_style:{rules:[65,66,67,68],inclusive:!1},rel_b:{rules:[65,66,67,68],inclusive:!1},rel_r:{rules:[65,66,67,68],inclusive:!1},rel_l:{rules:[65,66,67,68],inclusive:!1},rel_d:{rules:[65,66,67,68],inclusive:!1},rel_u:{rules:[65,66,67,68],inclusive:!1},rel_bi:{rules:[],inclusive:!1},rel:{rules:[65,66,67,68],inclusive:!1},node_r:{rules:[65,66,67,68],inclusive:!1},node_l:{rules:[65,66,67,68],inclusive:!1},node:{rules:[65,66,67,68],inclusive:!1},index:{rules:[],inclusive:!1},rel_index:{rules:[65,66,67,68],inclusive:!1},component_ext_queue:{rules:[65,66,67,68],inclusive:!1},component_ext_db:{rules:[65,66,67,68],inclusive:!1},component_ext:{rules:[65,66,67,68],inclusive:!1},component_queue:{rules:[65,66,67,68],inclusive:!1},component_db:{rules:[65,66,67,68],inclusive:!1},component:{rules:[65,66,67,68],inclusive:!1},container_boundary:{rules:[65,66,67,68],inclusive:!1},container_ext_queue:{rules:[65,66,67,68],inclusive:!1},container_ext_db:{rules:[65,66,67,68],inclusive:!1},container_ext:{rules:[65,66,67,68],inclusive:!1},container_queue:{rules:[65,66,67,68],inclusive:!1},container_db:{rules:[65,66,67,68],inclusive:!1},container:{rules:[65,66,67,68],inclusive:!1},birel:{rules:[65,66,67,68],inclusive:!1},system_boundary:{rules:[65,66,67,68],inclusive:!1},enterprise_boundary:{rules:[65,66,67,68],inclusive:!1},boundary:{rules:[65,66,67,68],inclusive:!1},system_ext_queue:{rules:[65,66,67,68],inclusive:!1},system_ext_db:{rules:[65,66,67,68],inclusive:!1},system_ext:{rules:[65,66,67,68],inclusive:!1},system_queue:{rules:[65,66,67,68],inclusive:!1},system_db:{rules:[65,66,67,68],inclusive:!1},system:{rules:[65,66,67,68],inclusive:!1},person_ext:{rules:[65,66,67,68],inclusive:!1},person:{rules:[65,66,67,68],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,82,83,84,85],inclusive:!0}}}})();function se(){this.yy={}}return n(se,`Parser`),se.prototype=oe,oe.Parser=se,new se})();y.parser=y;var b=y,x=n(e=>u()[e],`getRequiredConfig`),S=new Set([`label`,`descr`,`techn`,`type`]),C=n((e,t)=>{for(let[n,r]of Object.entries(t))if(r!==void 0){if(typeof r==`object`){let[t,n]=Object.entries(r)[0];e[t]=S.has(t)?{text:n}:n}else e[n]=r}},`assignAttributes`),w=n(()=>({alias:`global`,label:{text:`global`},type:{text:`global`},tags:null,link:null,parentBoundary:``}),`createGlobalBoundary`),T=[],E=[``],D=`global`,O=``,k=[w()],A=[],j=``,M=!1,N=4,P=2,F,I=n(function(){return F},`getC4Type`),L=n(function(e){F=f(e,u())},`setC4Type`),R=n(function(e,t,n,r,i,a,o,s,l){if(e==null||t==null||n==null||r==null)return;let u={},d=A.find(e=>e.from===t&&e.to===n);if(d?u=d:A.push(u),u.type=e,u.from=t,u.to=n,u.label={text:r},i==null)u.techn??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];u[e]=S.has(e)?{text:t}:t}else u.techn={text:i};if(a==null)u.descr??={text:``};else if(typeof a==`object`){let[e,t]=Object.entries(a)[0];u[e]=S.has(e)?{text:t}:t}else u.descr={text:a};C(u,{sprite:o,tags:s,link:l}),u.wrap=le()},`addRel`),z=n(function(e,t,n,r,i,a,o){if(t===null||n===null)return;let s={},l=T.find(e=>e.alias===t);if(l&&t===l.alias?s=l:(s.alias=t,T.push(s)),n==null?s.label={text:``}:s.label={text:n},r==null)s.descr??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];s[e]=S.has(e)?{text:t}:t}else s.descr={text:r};C(s,{sprite:i,tags:a,link:o}),s.typeC4Shape={text:e},s.parentBoundary=D,s.wrap=le()},`addPersonOrSystem`),B=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=T.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,T.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.techn??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.techn={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{sprite:a,tags:o,link:s}),l.wrap=le(),l.typeC4Shape={text:e},l.parentBoundary=D},`addContainer`),V=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=T.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,T.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.techn??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.techn={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{sprite:a,tags:o,link:s}),l.wrap=le(),l.typeC4Shape={text:e},l.parentBoundary=D},`addComponent`),H=n(function(e,t,n,r,i){if(e===null||t===null)return;let a={},o=k.find(t=>t.alias===e);if(o&&e===o.alias?a=o:(a.alias=e,k.push(a)),t==null?a.label={text:``}:a.label={text:t},n==null)a.type={text:`system`};else if(typeof n==`object`){let[e,t]=Object.entries(n)[0];a[e]=S.has(e)?{text:t}:t}else a.type={text:n};C(a,{tags:r,link:i}),a.parentBoundary=D,a.wrap=le(),O=D,D=e,E.push(O)},`addPersonOrSystemBoundary`),U=n(function(e,t,n,r,i){if(e===null||t===null)return;let a={},o=k.find(t=>t.alias===e);if(o&&e===o.alias?a=o:(a.alias=e,k.push(a)),t==null?a.label={text:``}:a.label={text:t},n==null)a.type={text:`container`};else if(typeof n==`object`){let[e,t]=Object.entries(n)[0];a[e]=S.has(e)?{text:t}:t}else a.type={text:n};C(a,{tags:r,link:i}),a.parentBoundary=D,a.wrap=le(),O=D,D=e,E.push(O)},`addContainerBoundary`),W=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=k.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,k.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.type={text:`node`};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.type={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{tags:o,link:s}),l.nodeType=e,l.parentBoundary=D,l.wrap=le(),O=D,D=t,E.push(O)},`addDeploymentNode`),G=n(function(){D=O,E.pop(),O=E.pop(),E.push(O)},`popBoundaryParseStack`),ee=n(function(e,t,n,r,i,a,o,s,l,u,d){let f=T.find(e=>e.alias===t);if(!(f===void 0&&(f=k.find(e=>e.alias===t),f===void 0))){if(n!=null){if(typeof n==`object`){let[e,t]=Object.entries(n)[0];f[e]=t}else f.bgColor=n}if(r!=null){if(typeof r==`object`){let[e,t]=Object.entries(r)[0];f[e]=t}else f.fontColor=r}if(i!=null){if(typeof i==`object`){let[e,t]=Object.entries(i)[0];f[e]=t}else f.borderColor=i}if(a!=null){if(typeof a==`object`){let[e,t]=Object.entries(a)[0];f[e]=t}else f.shadowing=a}if(o!=null){if(typeof o==`object`){let[e,t]=Object.entries(o)[0];f[e]=t}else f.shape=o}if(s!=null){if(typeof s==`object`){let[e,t]=Object.entries(s)[0];f[e]=t}else f.sprite=s}if(l!=null){if(typeof l==`object`){let[e,t]=Object.entries(l)[0];f[e]=t}else f.techn=l}if(u!=null){if(typeof u==`object`){let[e,t]=Object.entries(u)[0];f[e]=t}else f.legendText=u}if(d!=null){if(typeof d==`object`){let[e,t]=Object.entries(d)[0];f[e]=t}else f.legendSprite=d}}},`updateElStyle`),te=n(function(e,t,n,r,i,a,o){let s=A.find(e=>e.from===t&&e.to===n);if(s!==void 0){if(r!=null){if(typeof r==`object`){let[e,t]=Object.entries(r)[0];s[e]=t}else s.textColor=r}if(i!=null){if(typeof i==`object`){let[e,t]=Object.entries(i)[0];s[e]=t}else s.lineColor=i}if(a!=null){if(typeof a==`object`){let[e,t]=Object.entries(a)[0];s[e]=parseInt(t)}else s.offsetX=parseInt(a)}if(o!=null){if(typeof o==`object`){let[e,t]=Object.entries(o)[0];s[e]=parseInt(t)}else s.offsetY=parseInt(o)}}},`updateRelStyle`),ne=n(function(e,t,n){let r=N,i=P;if(typeof t==`object`){let e=Object.values(t)[0];r=parseInt(e)}else r=parseInt(t);if(typeof n==`object`){let e=Object.values(n)[0];i=parseInt(e)}else i=parseInt(n);r>=1&&(N=r),i>=1&&(P=i)},`updateLayoutConfig`),K=n(function(){return N},`getC4ShapeInRow`),q=n(function(){return P},`getC4BoundaryInRow`),J=n(function(){return D},`getCurrentBoundaryParse`),Y=n(function(){return O},`getParentBoundaryParse`),X=n(function(e){return e==null?T:T.filter(t=>t.parentBoundary===e)},`getC4ShapeArray`),re=n(function(e){return T.find(t=>t.alias===e)??k.find(t=>t.alias===e)},`getC4Shape`),ie=n(function(e){return Object.keys(X(e))},`getC4ShapeKeys`),Z=n(function(e){return e==null?k:k.filter(t=>t.parentBoundary===e)},`getBoundaries`),ae=Z,oe=n(function(){return A},`getRels`),se=n(function(){return j},`getTitle`),ce=n(function(e){M=e},`setWrap`),le=n(function(){return M},`autoWrap`),ue={addPersonOrSystem:z,addPersonOrSystemBoundary:H,addContainer:B,addContainerBoundary:U,addComponent:V,addDeploymentNode:W,popBoundaryParseStack:G,addRel:R,updateElStyle:ee,updateRelStyle:te,updateLayoutConfig:ne,autoWrap:le,setWrap:ce,getC4ShapeArray:X,getC4Shape:re,getC4ShapeKeys:ie,getBoundaries:Z,getBoundarys:ae,getCurrentBoundaryParse:J,getParentBoundaryParse:Y,getRels:oe,getTitle:se,getC4Type:I,getC4ShapeInRow:K,getC4BoundaryInRow:q,setAccTitle:i,getAccTitle:d,getAccDescription:l,setAccDescription:r,getConfig:n(()=>x(`c4`),`getConfig`),clear:n(function(){T=[],k=[w()],O=``,D=`global`,E=[``],A=[],E=[``],j=``,M=!1,N=4,P=2},`clear`),LINETYPE:{SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},ARROWTYPE:{FILLED:0,OPEN:1},PLACEMENT:{LEFTOF:0,RIGHTOF:1,OVER:2},setTitle:n(function(e){j=f(e,u())},`setTitle`),setC4Type:L},de=n(function(e,t){return v(e,t)},`drawRect`),fe=n((e,t,n,r)=>{let i=e.append(`g`),a=0;for(let e of t){let t=e.textColor?e.textColor:`#444444`,o=e.lineColor?e.lineColor:`#444444`,s=e.offsetX?parseInt(String(e.offsetX)):0,l=e.offsetY?parseInt(String(e.offsetY)):0;if(a===0){let t=i.append(`line`);t.attr(`x1`,e.startPoint.x),t.attr(`y1`,e.startPoint.y),t.attr(`x2`,e.endPoint.x),t.attr(`y2`,e.endPoint.y),t.attr(`stroke-width`,`1`),t.attr(`stroke`,o),t.style(`fill`,`none`),e.type!==`rel_b`&&t.attr(`marker-end`,`url(#`+r+`-arrowhead)`),(e.type===`birel`||e.type===`rel_b`)&&t.attr(`marker-start`,`url(#`+r+`-arrowend)`),a=-1}else{let t=i.append(`path`);t.attr(`fill`,`none`).attr(`stroke-width`,`1`).attr(`stroke`,o).attr(`d`,`Mstartx,starty Qcontrolx,controly stopx,stopy `.replaceAll(`startx`,e.startPoint.x).replaceAll(`starty`,e.startPoint.y).replaceAll(`controlx`,e.startPoint.x+(e.endPoint.x-e.startPoint.x)/2-(e.endPoint.x-e.startPoint.x)/4).replaceAll(`controly`,e.startPoint.y+(e.endPoint.y-e.startPoint.y)/2).replaceAll(`stopx`,e.endPoint.x).replaceAll(`stopy`,e.endPoint.y)),e.type!==`rel_b`&&t.attr(`marker-end`,`url(#`+r+`-arrowhead)`),(e.type===`birel`||e.type===`rel_b`)&&t.attr(`marker-start`,`url(#`+r+`-arrowend)`)}let u=e.label.width,d=n.messageFont();xe(n)(e.label.text,i,Math.min(e.startPoint.x,e.endPoint.x)+Math.abs(e.endPoint.x-e.startPoint.x)/2+s,Math.min(e.startPoint.y,e.endPoint.y)+Math.abs(e.endPoint.y-e.startPoint.y)/2+l,u,e.label.height,{fill:t},d),e.techn&&e.techn.text!==``&&(d=n.messageFont(),xe(n)(`[`+e.techn.text+`]`,i,Math.min(e.startPoint.x,e.endPoint.x)+Math.abs(e.endPoint.x-e.startPoint.x)/2+s,Math.min(e.startPoint.y,e.endPoint.y)+Math.abs(e.endPoint.y-e.startPoint.y)/2+n.messageFontSize+5+l,Math.max(u,e.techn.width),e.techn.height,{fill:t,"font-style":`italic`},d))}},`drawRels`),pe=n(function(e,t,n){let r=e.append(`g`),i=t.bgColor?t.bgColor:`none`,a=t.borderColor?t.borderColor:`#444444`,o=t.fontColor?t.fontColor:`black`,s={"stroke-width":1,"stroke-dasharray":`7.0,7.0`};t.nodeType&&(s={"stroke-width":1}),de(r,{x:t.x,y:t.y,fill:i,stroke:a,width:t.width,height:t.height,rx:2.5,ry:2.5,attrs:s});let l=n.boundaryFont();l.fontWeight=`bold`,l.fontSize+=2,l.fontColor=o,xe(n)(t.label.text,r,t.x,t.y+t.label.Y,t.width,t.height,{fill:`#444444`},l),t.type&&t.type.text!==``&&(l=n.boundaryFont(),l.fontColor=o,xe(n)(t.type.text,r,t.x,t.y+t.type.Y,t.width,t.height,{fill:`#444444`},l)),t.descr&&t.descr.text!==``&&(l=n.boundaryFont(),l.fontSize-=2,l.fontColor=o,xe(n)(t.descr.text,r,t.x,t.y+t.descr.Y,t.width,t.height,{fill:`#444444`},l))},`drawBoundary`),me=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-database`).attr(`fill-rule`,`evenodd`).attr(`clip-rule`,`evenodd`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z`)},`insertDatabaseIcon`),he=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-computer`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z`)},`insertComputerIcon`),ge=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-clock`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z`)},`insertClockIcon`),_e=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowhead`).attr(`refX`,9).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`)},`insertArrowHead`),ve=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowend`).attr(`refX`,1).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 z`)},`insertArrowEnd`),ye=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-filled-head`).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`insertArrowFilledHead`),be=n(function(e,t){let n=e.append(`defs`).append(`marker`).attr(`id`,t+`-crosshead`).attr(`markerWidth`,15).attr(`markerHeight`,8).attr(`orient`,`auto`).attr(`refX`,16).attr(`refY`,4);n.append(`path`).attr(`fill`,`black`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1px`).attr(`d`,`M 9,2 V 6 L16,4 Z`),n.append(`path`).attr(`fill`,`none`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1px`).attr(`d`,`M 0,1 L 6,7 M 6,1 L 0,7`)},`insertArrowCrossHead`),xe=(function(){function e(e,t,n,r,a,o,s){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,a,o,l,u){let{fontSize:d,fontFamily:f,fontWeight:p}=u,m=e.split(s.lineBreakRegex);for(let e=0;e{if(n===`sandbox`){let n=t(`#i`+e).node()?.contentDocument;if(!n)throw Error(`Sandbox iframe #i${e} is missing its content document`);return{root:t(n.body),doc:n}}return{root:t(`body`),doc:document}},`getDiagramRoot`),Ce=new Set([`system_queue`,`external_system_queue`,`container_queue`,`external_container_queue`,`component_queue`,`external_component_queue`]),we=new Set([`system_db`,`external_system_db`,`container_db`,`external_container_db`,`component_db`,`external_component_db`]),Te={person:`person`,box:`rounded`,rounded:`rounded`,cylinder:`cylinder`,database:`cylinder`,db:`cylinder`,queue:`h-cyl`,pipe:`h-cyl`,component:`fr-rect`},Ee=n(e=>e?Te[e.toLowerCase()]:void 0,`keywordShape`),De=n(e=>{let t=Ee(e.shape)??Ee(e.sprite);if(t)return t;if(e.tags)for(let t of e.tags.split(`,`)){let e=Ee(t.trim());if(e)return e}let n=e.typeC4Shape.text;return n===`person`||n===`external_person`?`person`:we.has(n)?`cylinder`:Ce.has(n)?`h-cyl`:`rounded`},`resolveNodeShape`),Oe={person:`Person`,system:`Software System`,container:`Container`,component:`Component`},ke=n(e=>{let t=e.replace(/^external_/,``).replace(/_(db|queue)$/,``);return Oe[t]??t.replace(/_/g,` `)},`stereotypeLabel`),Ae=n(e=>e.startsWith(`external_`),`isExternal`),je=n(e=>{let t=ke(e.typeC4Shape.text);return e.techn?.text?`[${t}: ${e.techn.text}]`:`[${t}]`},`stereotypeText`),Me=[`person`,`system`,`system_db`,`system_queue`,`container`,`container_db`,`container_queue`,`component`,`component_db`,`component_queue`].flatMap(e=>[e,`external_${e}`]),Ne=new Set(Me),Pe=n(e=>Ne.has(e),`isC4ElementType`),Fe=n((e,t)=>{let n=e.typeC4Shape.text,r=e.bgColor??(Pe(n)&&t[`${n}_bg_color`]),i=e.borderColor??(Pe(n)&&t[`${n}_border_color`]),a=[];return r&&a.push(`fill:${r}`),i&&a.push(`stroke:${i}`),a.push(`color:${e.fontColor??`#FFFFFF`}`),a},`elementCssStyles`),Ie=n((e,t,n,r,i)=>{let a=e.typeC4Shape.text,o=[`c4-shape`,`c4-${a}`];Ae(a)&&o.push(`c4-external`);let s=De(e),l=Fe(e,t);return(s===`rounded`||s===`fr-rect`)&&l.push(`rx:12px`,`ry:12px`),{id:e.alias,label:e.label.text,stereotype:je(e),description:e.descr?.text?[e.descr.text]:void 0,labelType:`string`,isGroup:!1,shape:s,cssClasses:o.join(` `),cssStyles:l,padding:n,look:r,useHtmlLabels:!1,width:i}},`buildC4Node`),Le=0,Re=0,ze=4,Be=2;y.yy=ue;var $={},Ve=class{static{n(this,`Bounds`)}constructor(e){this.name=``,this.data={},this.data.startx=void 0,this.data.stopx=void 0,this.data.starty=void 0,this.data.stopy=void 0,this.data.widthLimit=void 0,this.nextData={},this.nextData.startx=void 0,this.nextData.stopx=void 0,this.nextData.starty=void 0,this.nextData.stopy=void 0,this.nextData.cnt=0,He(e.db.getConfig())}setData(e,t,n,r){this.nextData.startx=this.data.startx=e,this.nextData.stopx=this.data.stopx=t,this.nextData.starty=this.data.starty=n,this.nextData.stopy=this.data.stopy=r}updateVal(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])}insert(e){this.nextData.cnt=this.nextData.cnt+1;let t=this.nextData.stopx,n=this.data.widthLimit,r=this.nextData.startx===this.nextData.stopx?t+e.margin:t+e.margin*2,i=r+e.width,a=this.nextData.starty+e.margin*2,o=a+e.height;(r>=n||i>=n||this.nextData.cnt>ze)&&(r=this.nextData.startx+e.margin+$.nextLinePaddingX,a=this.nextData.stopy+e.margin*2,this.nextData.stopx=i=r+e.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=o=a+e.height,this.nextData.cnt=1),e.x=r,e.y=a,this.updateVal(this.data,`startx`,r,Math.min),this.updateVal(this.data,`starty`,a,Math.min),this.updateVal(this.data,`stopx`,i,Math.max),this.updateVal(this.data,`stopy`,o,Math.max),this.updateVal(this.nextData,`startx`,r,Math.min),this.updateVal(this.nextData,`starty`,a,Math.min),this.updateVal(this.nextData,`stopx`,i,Math.max),this.updateVal(this.nextData,`stopy`,o,Math.max)}init(e){this.name=``,this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,widthLimit:void 0},this.nextData={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,cnt:0},He(e.db.getConfig())}bumpLastMargin(e){this.data.stopx+=e,this.data.stopy+=e}},He=n(function(e){o($,e),e?.fontFamily&&($.personFontFamily=$.systemFontFamily=$.messageFontFamily=e.fontFamily),e?.fontSize&&($.personFontSize=$.systemFontSize=$.messageFontSize=e.fontSize),e?.fontWeight&&($.personFontWeight=$.systemFontWeight=$.messageFontWeight=e.fontWeight)},`setConf`),Ue=n(e=>({fontFamily:e.boundaryFontFamily,fontSize:e.boundaryFontSize,fontWeight:e.boundaryFontWeight}),`boundaryFont`),We=n(e=>({fontFamily:e.messageFontFamily,fontSize:e.messageFontSize,fontWeight:e.messageFontWeight}),`messageFont`);function Ge(e,t,n,r,i){let a=t[e];if(!a.width){if(n)a.text=p(a.text,i,r),a.textLines=a.text.split(s.lineBreakRegex).length,a.width=i,a.height=m(a.text,r);else{let e=a.text.split(s.lineBreakRegex);a.textLines=e.length;let t=0;a.height=0,a.width=0;for(let n of e)a.width=Math.max(h(n,r),a.width),t=m(n,r),a.height+=t}}return a}n(Ge,`calcC4ShapeTextWH`);var Ke=n(function(e,t,n){let r=n.data.startx,i=n.data.starty;t.x=r,t.y=i,t.width=n.data.stopx-r,t.height=n.data.stopy-i,t.intersect=e=>g.rect({x:t.x+t.width/2,y:t.y+t.height/2,width:t.width,height:t.height},e),t.label.y=$.c4ShapeMargin-35;let a=t.wrap&&$.wrap,o=Ue($);o.fontSize+=2,o.fontWeight=`bold`,Ge(`label`,t,a,o,h(t.label.text,o)),Q.drawBoundary(e,t,$)},`drawBoundary`),qe=n(async function(e,t,r,i){let a=u(),o=a.look??`classic`,s={config:a},l=t.attr(`id`)??``,d=i.map(e=>r[Number(e)]),f=n(e=>{let t=e.shape?_[e.shape]:void 0;if(!t)throw Error(`C4: no shape handler for "${e.shape}"`);return t},`shapeHandlerFor`);await Promise.all(d.map(async e=>{let n=Ie(e,$,$.c4ShapePadding,o,$.width);n.domId=`${l}-${n.id}`;let r=await f(n)(t,n,s);e.width=n.width??$.width,e.height=n.height??$.height,e.margin=$.c4ShapeMargin,r.remove()}));for(let t of d)e.insert(t);await Promise.all(d.map(async e=>{let n=Ie(e,$,$.c4ShapePadding,o,$.width);n.domId=`${l}-${n.id}`,n.x=e.x+e.width/2,n.y=e.y+e.height/2;let r=t.append(`g`).attr(`transform`,`translate(${e.x+e.width/2}, ${e.y+e.height/2})`);await f(n)(r,n,s),e.intersect=n.intersect})),e.bumpLastMargin($.c4ShapeMargin)},`drawC4ShapeArray`),Je=class{static{n(this,`Point`)}constructor(e,t){this.x=e,this.y=t}},Ye=n(function(e,t){if(!e.intersect)throw Error(`C4 element "${e.alias}" has no intersect function. Please report this to https://github.com/mermaid-js/mermaid/issues`);let{x:n,y:r}=e.intersect(t);return new Je(n,r)},`getIntersectPoint`),Xe=n(function(e,t){let n={x:0,y:0};n.x=t.x+t.width/2,n.y=t.y+t.height/2;let r=Ye(e,n);return n.x=e.x+e.width/2,n.y=e.y+e.height/2,{startPoint:r,endPoint:Ye(t,n)}},`getIntersectPoints`),Ze=n(function(e,t,n,r,i){let a=r.db.getC4Type(),o=0;for(let e of t){o+=1;let t=e.wrap&&$.wrap,r=We($);a===`C4Dynamic`&&(e.label.text=o+`: `+e.label.text);let i=h(e.label.text,r);Ge(`label`,e,t,r,i),e.techn&&e.techn.text!==``&&(i=h(e.techn.text,r),Ge(`techn`,e,t,r,i)),e.descr&&e.descr.text!==``&&(i=h(e.descr.text,r),Ge(`descr`,e,t,r,i));let s=n(e.from),l=n(e.to);if(!s||!l)throw Error(`C4 rel "${e.from}" -> "${e.to}" references an unknown shape or boundary`);let u=Xe(s,l);if(!u.startPoint||!u.endPoint)throw Error(`Could not calculate intersection points for rel "${e.from}" -> "${e.to}"`);e.startPoint=u.startPoint,e.endPoint=u.endPoint}Q.drawRels(e,t,$,i)},`drawRels`);async function Qe(e,t,n,r,i){let a=i.db,o=new Ve(i);o.data.widthLimit=n.data.widthLimit/Math.min(Be,r.length);for(let[s,l]of r.entries()){let r=0;l.image={width:0,height:0,Y:0},l.sprite&&(l.image.width=48,l.image.height=48,l.image.Y=r,r=l.image.Y+l.image.height);let u=l.wrap&&$.wrap,d=Ue($);d.fontSize+=2,d.fontWeight=`bold`;let f=Ge(`label`,l,u,d,o.data.widthLimit);if(f.Y=r+8,r=f.Y+f.height,l.type&&l.type.text!==``){l.type.text=`[`+l.type.text+`]`;let e=Ge(`type`,l,u,Ue($),o.data.widthLimit);e.Y=r+5,r=e.Y+e.height}if(l.descr&&l.descr.text!==``){let e=Ue($);e.fontSize-=2;let t=Ge(`descr`,l,u,e,o.data.widthLimit);t.Y=r+20,r=t.Y+t.height}if(s==0||s%Be===0){let e=n.data.startx+$.diagramMarginX,t=n.data.stopy+$.diagramMarginY+r;o.setData(e,e,t,t)}else{let e=o.data.stopx===o.data.startx?o.data.startx:o.data.stopx+$.diagramMarginX,t=o.data.starty;o.setData(e,e,t,t)}o.name=l.alias;let p=a.getC4ShapeArray(l.alias),m=a.getC4ShapeKeys(l.alias);m.length>0&&await qe(o,e,p,m),t=l.alias;let h=a.getBoundaries(t);h.length>0&&await Qe(e,t,o,h,i),l.alias!==`global`&&Ke(e,l,o),n.data.stopy=Math.max(o.data.stopy+$.c4ShapeMargin,n.data.stopy),n.data.stopx=Math.max(o.data.stopx+$.c4ShapeMargin,n.data.stopx),Le=Math.max(Le,n.data.stopx),Re=Math.max(Re,n.data.stopy)}}n(Qe,`drawInsideBoundary`);var $e={drawPersonOrSystemArray:qe,drawBoundary:Ke,setConf:He,draw:n(async function(t,n,r,i){$=x(`c4`);let o=u().securityLevel,{root:s}=Se(n,o),l=i.db;l.setWrap($.wrap),ze=l.getC4ShapeInRow(),Be=l.getC4BoundaryInRow(),e.debug(`C:${JSON.stringify($,null,2)}`);let d=s.select(`[id="${n}"]`);Q.insertComputerIcon(d,n),Q.insertDatabaseIcon(d,n),Q.insertClockIcon(d,n);let f=new Ve(i);f.setData($.diagramMarginX,$.diagramMarginX,$.diagramMarginY,$.diagramMarginY),f.data.widthLimit=screen.availWidth,Le=$.diagramMarginX,Re=$.diagramMarginY;let p=l.getTitle();await Qe(d,``,f,l.getBoundaries(``),i),Q.insertArrowHead(d,n),Q.insertArrowEnd(d,n),Q.insertArrowCrossHead(d,n),Q.insertArrowFilledHead(d,n),Ze(d,l.getRels(),l.getC4Shape,i,n),f.data.stopx=Le,f.data.stopy=Re;let m=f.data,h=m.startx,g=m.starty,_=Re-g+2*$.diagramMarginY,v=Le-h,y=v+2*$.diagramMarginX;p&&d.append(`text`).text(p).attr(`x`,v/2-4*$.diagramMarginX).attr(`y`,g+$.diagramMarginY),a(d,_,y,$.useMaxWidth);let b=p?60:0;d.attr(`viewBox`,h-$.diagramMarginX+` -`+($.diagramMarginY+b)+` `+y+` `+(_+b)),e.debug(`models:`,m)},`draw`)},et=n(()=>{let e=u().c4??{},t=new CSSStyleSheet;for(let n of Me){let r=t.cssRules[t.insertRule(`.c4-shape.c4-${n} .label {}`,t.cssRules.length)],i=e[`${n}FontFamily`],a=e[`${n}FontSize`],o=e[`${n}FontWeight`];i&&r.style.setProperty(`font-family`,i),a&&r.style.setProperty(`font-size`,typeof a==`number`?`${a}px`:a),o&&r.style.setProperty(`font-weight`,String(o))}return[...t.cssRules].filter(e=>e.style.length>0).map(e=>` ${e.cssText}`).join(` +`)},`elementFontStyles`),tt={parser:b,db:ue,renderer:$e,styles:n(e=>`.person { + stroke: ${e.personBorder}; + fill: ${e.personBkg}; + } +${et()} + + /* The element font colour is set inline per element (default white); the + label text takes it via currentColor. */ + .c4-shape .label, + .c4-shape .label text { + color: inherit; + fill: currentColor; + } + /* Structurizr typography: bold name, smaller stereotype/type and description lines. */ + .c4-shape .label .c4-name { + font-weight: bold; + } + .c4-shape .label .c4-type { + font-size: 0.75em; + } + .c4-shape .label .c4-descr { + font-size: 0.82em; + } + .c4-shape .basic, + .c4-shape rect, + .c4-shape path, + .c4-shape circle, + .c4-shape ellipse, + .c4-shape line { + stroke-width: 2px; + } +`,`getStyles`),init:n(({c4:e,wrap:t})=>{$e.setConf(e),ue.setWrap(t)},`init`)};export{tt as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/channel-_oCHZhRo.js b/frontend/dist/assets/channel-_oCHZhRo.js new file mode 100644 index 0000000..e3f17de --- /dev/null +++ b/frontend/dist/assets/channel-_oCHZhRo.js @@ -0,0 +1 @@ +import{ct as e,st as t}from"./chunk-O7XYJQB3-Bce2lzyF.js";var n=(n,r)=>e.lang.round(t.parse(n)[r]);export{n as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-2Q5K7J3B-C1jixKkw.js b/frontend/dist/assets/chunk-2Q5K7J3B-C1jixKkw.js new file mode 100644 index 0000000..4c6fa39 --- /dev/null +++ b/frontend/dist/assets/chunk-2Q5K7J3B-C1jixKkw.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=class{constructor(e){this.init=e,this.records=this.init()}static{e(this,`ImperativeState`)}reset(){this.records=this.init()}};export{t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-3FUC2YCW-CmoZ3fbX.js b/frontend/dist/assets/chunk-3FUC2YCW-CmoZ3fbX.js new file mode 100644 index 0000000..087c84b --- /dev/null +++ b/frontend/dist/assets/chunk-3FUC2YCW-CmoZ3fbX.js @@ -0,0 +1,2 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/sizeCapture-INFHLROL-B0uUizjq.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js"])))=>i.map(i=>d[i]); +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{b as n,et as r,x as i}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as a}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{o}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as s,n as c,r as l,t as u}from"./chunk-5DYCD2WN-WToj2Jza.js";import{a as d,f,h as p,i as m,o as h,p as g,r as ee,s as _,u as v}from"./index-DoQkmpth.js";import{t as y}from"./graphlib-C9Tl7QrK.js";function b(e,{edgePathsClass:t=`edges edgePaths`}={}){let n=e.insert(`g`).attr(`class`,`root`);return{clusters:n.insert(`g`).attr(`class`,`clusters`),edgePaths:n.insert(`g`).attr(`class`,t),edgeLabels:n.insert(`g`).attr(`class`,`edgeLabels`),nodes:n.insert(`g`).attr(`class`,`nodes`),rootGroups:n}}t(b,`createLayoutElementGroups`);async function x(e,t,n){if(t.label){let{shapeSvg:r,bbox:i}=await o(e,n===void 0?t:{...t,width:n});t.labelBBox={width:i.width,height:i.height},r.remove()}else t.labelBBox={width:0,height:0}}t(x,`measureGroupLabel`);async function S(e,t,n){let r=await l(e,t,n),i=r.node()?.getBBox()??{width:0,height:0};return t.width=i.width,t.height=i.height,r}t(S,`insertMeasuredNode`);function C(e,t,n){let r=e,i=new Set;for(;r;){if(r.dir)return r.dir;if(!r.parentId||i.has(r.parentId))break;i.add(r.parentId),r=t.get(r.parentId)}return n}t(C,`resolveNodeDir`);async function w(e,t,n={}){let a=new y({multigraph:!0,compound:!0}),o=[...t.edges],s=i(),c=b(e),{edgeLabels:l,nodes:u}=c,f=new Map,p=new Map(t.nodes.map(e=>[e.id,e])),m=t.direction,h=e.node()!=null;await Promise.all(t.nodes.map(async e=>{if(e.isGroup){if(h){let t=n.unwrapGroupLabels&&e.labelType!==`markdown`;await x(u,e,t?1/0:void 0)}a.setNode(e.id,{...e})}else{if(h){let t=await S(u,e,{config:s,dir:C(e,p,m)});f.set(e.id,t)}a.setNode(e.id,{...e})}}));for(let e of o)h&&d(e)&&await _(l,e),a.setEdge(e.start,e.end,{...e},e.id),t.edges.some(t=>t.id===e.id)||t.edges.push(e);if(globalThis.mermaidCaptureSizes){let{captureNodeSizes:n}=await r(async()=>{let{captureNodeSizes:e}=await import(`./sizeCapture-INFHLROL-B0uUizjq.js`);return{captureNodeSizes:e}},__vite__mapDeps([0,1]));n(e,t)}return{graph:a,groups:c,nodeElements:f}}t(w,`createGraphWithElements`);var T=new Map,E=new Map,D=new Map,O=t(()=>{E.clear(),D.clear(),T.clear()},`clear`),k=t((t,n)=>{let r=E.get(n)||[];return e.trace(`In isDescendant`,n,` `,t,` = `,r.includes(t)),r.includes(t)},`isDescendant`),A=t((t,n)=>{let r=E.get(n)||[];return e.info(`Descendants of `,n,` is `,r),e.info(`Edge is `,t),t.v===n||t.w===n?!1:r?r.includes(t.v)||k(t.v,n)||k(t.w,n)||r.includes(t.w):(e.debug(`Tilt, `,n,`,not in descendants`),!1)},`edgeInCluster`),j=t((t,n,r,i)=>{e.debug(`Copying children of `,t,`root`,i,`data`,n.node(t),i);let a=n.children(t)||[];t!==i&&a.push(t),e.debug(`Copying (nodes) clusterId`,t,`nodes`,a),a.forEach(a=>{if(n.children(a).length>0)j(a,n,r,i);else{let o=n.node(a);e.info(`cp `,a,` to `,i,` with parent `,t),r.setNode(a,o),i!==n.parent(a)&&(e.debug(`Setting parent`,a,n.parent(a)),r.setParent(a,n.parent(a))),t!==i&&a!==t?(e.debug(`Setting parent`,a,t),r.setParent(a,t)):(e.info(`In copy `,t,`root`,i,`data`,n.node(t),i),e.debug(`Not Setting parent for node=`,a,`cluster!==rootId`,t!==i,`node!==clusterId`,a!==t));let s=n.edges(a);e.debug(`Copying Edges`,s),s.forEach(a=>{e.info(`Edge`,a);let o=n.edge(a.v,a.w,a.name);e.info(`Edge data`,o,i);try{A(a,i)?(e.info(`Copying as `,a.v,a.w,o,a.name),r.setEdge(a.v,a.w,o,a.name),e.info(`newGraph edges `,r.edges(),r.edge(r.edges()[0]))):e.info(`Skipping copy of edge `,a.v,`-->`,a.w,` rootId: `,i,` clusterId:`,t)}catch(t){e.error(t)}})}e.debug(`Removing node`,a),n.removeNode(a)})},`copy`),M=t((e,t)=>{let n=t.children(e),r=[...n];for(let i of n)D.set(i,e),r=[...r,...M(i,t)];return r},`extractDescendants`),N=t((e,t,n)=>{let r=e.edges().filter(e=>e.v===t||e.w===t),i=e.edges().filter(e=>e.v===n||e.w===n),a=r.map(e=>({v:e.v===t?n:e.v,w:e.w===t?t:e.w})),o=i.map(e=>({v:e.v,w:e.w}));return a.filter(e=>o.some(t=>e.v===t.v&&e.w===t.w))},`findCommonEdges`),P=t((t,n,r)=>{let i=n.children(t);if(e.trace(`Searching children of id `,t,i),i.length<1)return t;let a;for(let e of i){let t=P(e,n,r),i=N(n,r,t);if(t){if(i.length>0)a=t;else return t}}return a},`findNonClusterChild`),F=t(e=>!T.has(e)||!T.get(e).externalConnections?e:T.has(e)?T.get(e).id:e,`getAnchorId`),I=t((t,n)=>{if(!t||n>10){e.debug(`Opting out, no graph `);return}e.debug(`Opting in, graph `),t.nodes().forEach(function(n){t.children(n).length>0&&(e.debug(`Cluster identified`,n,` Replacement id in edges: `,P(n,t,n)),E.set(n,M(n,t)),T.set(n,{id:P(n,t,n),clusterData:t.node(n)}))}),t.nodes().forEach(function(n){let r=t.children(n),i=t.edges();r.length>0?(e.debug(`Cluster identified`,n,E),i.forEach(t=>{k(t.v,n)^k(t.w,n)&&(e.debug(`Edge: `,t,` leaves cluster `,n),e.debug(`Descendants of XXX `,n,`: `,E.get(n)),T.get(n).externalConnections=!0)})):e.debug(`Not a cluster `,n,E)});for(let e of T.keys()){let n=T.get(e).id,r=t.parent(n);r!==e&&T.has(r)&&!T.get(r).externalConnections&&(T.get(e).id=r);let i=t.edges().some(t=>t.v===e);if(n&&T.get(e)?.externalConnections&&i&&B(t,n,e)){let r=V(t,e,t.parent(n));r&&(T.get(e).id=r)}}t.edges().forEach(function(n){let r=t.edge(n);e.debug(`Edge `+n.v+` -> `+n.w+`: `+JSON.stringify(n)),e.debug(`Edge `+n.v+` -> `+n.w+`: `+JSON.stringify(t.edge(n)));let i=n.v,a=n.w;if(e.debug(`Fix XXX`,T,`ids:`,n.v,n.w,`Translating: `,T.get(n.v),` --- `,T.get(n.w)),T.get(n.v)||T.get(n.w)){if(e.debug(`Fixing and trying - removing XXX`,n.v,n.w,n.name),i=F(n.v),a=F(n.w),t.removeEdge(n.v,n.w,n.name),i!==n.v){let e=t.parent(i);T.get(e).externalConnections=!0,r.fromCluster=n.v}if(a!==n.w){let e=t.parent(a);T.get(e).externalConnections=!0,r.toCluster=n.w}e.debug(`Fix Replacing with XXX`,i,a,n.name),t.setEdge(i,a,r,n.name)}}),L(t,0),e.trace(T)},`adjustClustersAndEdges`),L=t((t,n)=>{if(n>10){e.error(`Bailing out`);return}let r=t.nodes(),i=!1;for(let e of r){let n=t.children(e);i||=n.length>0}if(!i){e.debug(`Done, no node has children`,t.nodes());return}e.debug(`Nodes = `,r,n);for(let i of r)if(e.debug(`Extracting node`,i,T,T.has(i)&&!T.get(i).externalConnections,!t.parent(i),t.node(i),t.children(`D`),` Depth `,n),!T.has(i))e.debug(`Not a cluster`,i,n);else if(!T.get(i).externalConnections&&t.children(i)&&t.children(i).length>0){e.debug(`Cluster without external connections, without a parent and with children`,i,n);let r=t.graph().rankdir===`TB`?`LR`:`TB`;T.get(i)?.clusterData?.dir&&(r=T.get(i).clusterData.dir,e.debug(`Fixing dir`,T.get(i).clusterData.dir,r));let a=new y({multigraph:!0,compound:!0}).setGraph({rankdir:r,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});j(i,t,a,i),t.setNode(i,{clusterNode:!0,id:i,clusterData:T.get(i).clusterData,label:T.get(i).label,graph:a})}else e.debug(`Cluster ** `,i,` **not meeting the criteria !externalConnections:`,!T.get(i).externalConnections,` no parent: `,!t.parent(i),` children `,t.children(i)&&t.children(i).length>0,t.children(`D`),n),e.debug(T);r=t.nodes(),e.debug(`New list of nodes`,r);for(let i of r){let r=t.node(i);e.debug(` Now next level`,i,r),r?.clusterNode&&L(r.graph,n+1)}},`extractor`),R=t((e,t)=>{if(t.length===0)return[];let n=Object.assign([],t);return t.forEach(t=>{let r=R(e,e.children(t));n=[...n,...r]}),n},`sorter`),z=t(e=>R(e,e.children()),`sortNodesByHierarchy`),B=t((e,t,n)=>{let r=e.parent(t);for(;r&&r!==n;){let t=T.get(r);if(t&&!t.externalConnections)return!0;r=e.parent(r)}return!1},`isNodeInExtractableCluster`),V=t((e,t,n)=>{let r=e.children(t)??[];for(let i of r){if(i===n||k(i,n))continue;let r=P(i,e,t);if(r&&!B(e,r,t))return r}return null},`findSafeAnchorNode`);function H({prepareLayout:e,measureLayout:n,runLayoutCore:r,paintLayout:i,afterPaint:a,paintOptions:o}){let s=n??W;return t(async function(t,n,c,l){let u=n.select(`g`);(c?.insertMarkers??v)(u,t.markers,t.type,t.diagramId),U();let d={element:u,helpers:c,options:l};d.preparedLayout=await e?.(t,d);let f=await s(t,d),p=await r(t,d),m={...d,measure:f};i?await i(t,m,p):await G(t,m,o),await a?.(t,m,p)},`render`)}t(H,`createCommonLayoutRenderer`);function U(){u(),ee(),g(),O()}t(U,`clearLayoutRenderState`);async function W(e,{element:t},n){return await w(t,e,n)}t(W,`defaultMeasureLayout`);async function G(e,t,n={}){let{measure:r}=t,{groups:i}=r;for(let r of n.getNodes?.(e,t)??e.nodes)n.skipNode?.(r,t)||await K(i,r,t,n);let a=J(e.nodes);for(let r of e.edges)Y(r,n)||await X(i,r,a,e,n,t)}t(G,`paintLayoutData`);async function K(e,t,n,r){t.clusterNode?s(t):q(t,n,r)?await p(e.clusters,t):s(t)}t(K,`paintLayoutNode`);function q(e,t,n){return e.isGroup===!0&&(n.isCluster?.(e,t)??!0)}t(q,`shouldPaintAsCluster`);function J(e){let t=new Map;for(let n of e)n?.id&&t.set(n.id,n);return t}t(J,`buildNodeLookup`);function Y(e,t){return e.isLayoutOnly||!!t.skipEdge?.(e)}t(Y,`shouldSkipPaintEdge`);async function X(e,t,n,r,i,a){let o=h(e.edgePaths,{...t},i.clusterDb??new Map,r.type,Z(t.start,t,n,a,i),Z(t.end,t,n,a,i),r.diagramId,Q(t,i));d(t)&&(m.has(t.id)||await _(e.edgeLabels,t),$(t,o))}t(X,`paintLayoutEdge`);function Z(e,t,n,r,i){return i.getEdgeNode?.(e,t,r)??(e?n.get(e)??{}:{})}t(Z,`getRenderedNode`);function Q(e,t){return typeof t.skipIntersect==`function`?t.skipIntersect(e):t.skipIntersect??!1}t(Q,`shouldSkipIntersect`);function $(t,r){let i=r?.updatedPath??r?.originalPath,o=n(),{subGraphTitleTotalMargin:s}=c({flowchart:o.flowchart??{}});if(t.label){let n=m.get(t.id),o=t.x,c=t.y;if(i){let n=a.calcLabelPosition(i);e.debug(`Moving label `+t.label+` from (`,o,`,`,c,`) to (`,n.x,`,`,n.y,`) abc88`),r?.updatedPath&&(o=n.x,c=n.y)}n.attr(`transform`,`translate(${o}, ${c+s/2})`)}if(t?.startLabelLeft){let e=f.get(t.id).startLeft,n=t?.x,r=t?.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeStart?10:0,`start_left`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.startLabelRight){let e=f.get(t.id).startRight,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeStart?10:0,`start_right`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.endLabelLeft){let e=f.get(t.id).endLeft,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,`end_left`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.endLabelRight){let e=f.get(t.id).endRight,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,`end_right`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}}t($,`positionRenderedEdgeLabel`);export{W as a,z as c,b as i,T as n,P as o,H as r,S as s,I as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-5DYCD2WN-WToj2Jza.js b/frontend/dist/assets/chunk-5DYCD2WN-WToj2Jza.js new file mode 100644 index 0000000..824607e --- /dev/null +++ b/frontend/dist/assets/chunk-5DYCD2WN-WToj2Jza.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{u as n}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{s as r}from"./chunk-7INBJB4K-BkZ96Hf7.js";var i=t(({flowchart:e})=>{let t=e?.subGraphTitleMargin?.top??0,n=e?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:n,subGraphTitleTotalMargin:t+n}},`getSubGraphTitleMargins`),a=new Map;async function o(e,t,i){let o,s;t.shape===`rect`&&(t.shape=t.rx&&t.ry?`roundedRect`:`squareRect`);let c=t.shape?r[t.shape]:void 0;if(!c)throw Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let n;i.config.securityLevel===`sandbox`?n=`_top`:t.linkTarget&&(n=t.linkTarget||`_blank`),o=e.insert(`svg:a`).attr(`xlink:href`,t.link).attr(`target`,n??null),s=await c(o,t,i)}else s=await c(e,t,i),o=s;return o.attr(`data-look`,n(t.look)),t.tooltip&&s.attr(`title`,t.tooltip),a.set(t.id,o),t.haveCallback&&o.attr(`class`,o.attr(`class`)+` clickable`),o}t(o,`insertNode`);var s=t((e,t)=>{a.set(t.id,e)},`setNodeElem`),c=t(()=>{a.clear()},`clear`),l=t(t=>{let n=a.get(t.id);e.trace(`Transforming node`,t.diff,t,`translate(`+(t.x-t.width/2-5)+`, `+t.width/2+`)`);let r=t.diff||0;return t.clusterNode?n.attr(`transform`,`translate(`+(t.x+r-t.width/2)+`, `+(t.y-t.height/2-8)+`)`):n.attr(`transform`,`translate(`+t.x+`, `+t.y+`)`),r},`positionNode`);export{s as a,l as i,i as n,o as r,c as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-5VM5RSS4-ZNzvKenW.js b/frontend/dist/assets/chunk-5VM5RSS4-ZNzvKenW.js new file mode 100644 index 0000000..31131d3 --- /dev/null +++ b/frontend/dist/assets/chunk-5VM5RSS4-ZNzvKenW.js @@ -0,0 +1,15 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=e(()=>` + /* Font Awesome icon styling - consolidated */ + .label-icon { + display: inline-block; + height: 1em; + overflow: visible; + vertical-align: -0.125em; + } + + .node .label-icon path { + fill: currentColor; + stroke: revert; + stroke-width: revert; + } +`,`getIconStyles`);export{t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-742MDFTN-5mFByRwZ.js b/frontend/dist/assets/chunk-742MDFTN-5mFByRwZ.js new file mode 100644 index 0000000..04ac6bd --- /dev/null +++ b/frontend/dist/assets/chunk-742MDFTN-5mFByRwZ.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{b as n,z as r}from"./chunk-O7XYJQB3-Bce2lzyF.js";var i=Object.freeze({left:0,top:0,width:16,height:16}),a=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),o=Object.freeze({...i,...a}),s=Object.freeze({...o,body:``,hidden:!1}),c=Object.freeze({width:null,height:null}),l=Object.freeze({...c,...a}),u=(e,t,n,r=``)=>{let i=e.split(`:`);if(e.slice(0,1)===`@`){if(i.length<2||i.length>3)return null;r=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){let e=i.pop(),n=i.pop(),a={provider:i.length>0?i[0]:r,prefix:n,name:e};return t&&!d(a)?null:a}let a=i[0],o=a.split(`-`);if(o.length>1){let e={provider:r,prefix:o.shift(),name:o.join(`-`)};return t&&!d(e)?null:e}if(n&&r===``){let e={provider:r,prefix:``,name:a};return t&&!d(e,n)?null:e}return null},d=(e,t)=>e?!!((t&&e.prefix===``||e.prefix)&&e.name):!1;function f(e,t){let n={};!e.hFlip!=!t.hFlip&&(n.hFlip=!0),!e.vFlip!=!t.vFlip&&(n.vFlip=!0);let r=((e.rotate||0)+(t.rotate||0))%4;return r&&(n.rotate=r),n}function p(e,t){let n=f(e,t);for(let r in s)r in a?r in e&&!(r in n)&&(n[r]=a[r]):r in t?n[r]=t[r]:r in e&&(n[r]=e[r]);return n}function m(e,t){let n=e.icons,r=e.aliases||Object.create(null),i=Object.create(null);function a(e){if(n[e])return i[e]=[];if(!(e in i)){i[e]=null;let t=r[e]&&r[e].parent,n=t&&a(t);n&&(i[e]=[t].concat(n))}return i[e]}return(t||Object.keys(n).concat(Object.keys(r))).forEach(a),i}function h(e,t,n){let r=e.icons,i=e.aliases||Object.create(null),a={};function o(e){a=p(r[e]||i[e],a)}return o(t),n.forEach(o),p(e,a)}function g(e,t){if(e.icons[t])return h(e,t,[]);let n=m(e,[t])[t];return n?h(e,t,n):null}var _=/(-?[0-9.]*[0-9]+[0-9.]*)/g,v=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function y(e,t,n){if(t===1)return e;if(n||=100,typeof e==`number`)return Math.ceil(e*t*n)/n;if(typeof e!=`string`)return e;let r=e.split(_);if(r===null||!r.length)return e;let i=[],a=r.shift(),o=v.test(a);for(;;){if(o){let e=parseFloat(a);isNaN(e)?i.push(a):i.push(Math.ceil(e*t*n)/n)}else i.push(a);if(a=r.shift(),a===void 0)return i.join(``);o=!o}}function b(e,t=`defs`){let n=``,r=e.indexOf(`<`+t);for(;r>=0;){let i=e.indexOf(`>`,r),a=e.indexOf(``,a);if(o===-1)break;n+=e.slice(i+1,a).trim(),e=e.slice(0,r).trim()+e.slice(o+1)}return{defs:n,content:e}}function x(e,t){return e?``+e+``+t:t}function S(e,t,n){let r=b(e);return x(r.defs,t+r.content+n)}var C=e=>e===`unset`||e===`undefined`||e===`none`;function w(e,t){let n={...o,...e},r={...l,...t},i={left:n.left,top:n.top,width:n.width,height:n.height},a=n.body;[n,r].forEach(e=>{let t=[],n=e.hFlip,r=e.vFlip,o=e.rotate;n?r?o+=2:(t.push(`translate(`+(i.width+i.left).toString()+` `+(0-i.top).toString()+`)`),t.push(`scale(-1 1)`),i.top=i.left=0):r&&(t.push(`translate(`+(0-i.left).toString()+` `+(i.height+i.top).toString()+`)`),t.push(`scale(1 -1)`),i.top=i.left=0);let s;switch(o<0&&(o-=Math.floor(o/4)*4),o%=4,o){case 1:s=i.height/2+i.top,t.unshift(`rotate(90 `+s.toString()+` `+s.toString()+`)`);break;case 2:t.unshift(`rotate(180 `+(i.width/2+i.left).toString()+` `+(i.height/2+i.top).toString()+`)`);break;case 3:s=i.width/2+i.left,t.unshift(`rotate(-90 `+s.toString()+` `+s.toString()+`)`)}o%2==1&&(i.left!==i.top&&(s=i.left,i.left=i.top,i.top=s),i.width!==i.height&&(s=i.width,i.width=i.height,i.height=s)),t.length&&(a=S(a,``,``))});let s=r.width,c=r.height,u=i.width,d=i.height,f,p;s===null?(p=c===null?`1em`:c===`auto`?d:c,f=y(p,u/d)):(f=s===`auto`?u:s,p=c===null?y(f,d/u):c===`auto`?d:c);let m={},h=(e,t)=>{C(t)||(m[e]=t.toString())};h(`width`,f),h(`height`,p);let g=[i.left,i.top,u,d];return m.viewBox=g.join(` `),{attributes:m,viewBox:g,body:a}}var T=/\sid="(\S+)"/g,E=new Map;function D(e){e=e.replace(/[0-9]+$/,``)||`a`;let t=E.get(e)||0;return E.set(e,t+1),t?`${e}${t}`:e}function O(e){let t=[],n;for(;n=T.exec(e);)t.push(n[1]);if(!t.length)return e;let r=`suffix`+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(t=>{let n=D(t),i=t.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);e=e.replace(RegExp(`([#;"])(`+i+`)([")]|\\.[a-z])`,`g`),`$1`+n+r+`$3`)}),e=e.replace(new RegExp(r,`g`),``),e}function k(e,t){let n=e.indexOf(`xlink:`)===-1?``:` xmlns:xlink="http://www.w3.org/1999/xlink"`;for(let e in t)n+=` `+e+`="`+t[e]+`"`;return``+e+``}var A={body:`?`,height:80,width:80},j=new Map,M=new Map,N=t(t=>{for(let n of t){if(!n.name)throw Error(`Invalid icon loader. Must have a "name" property with non-empty string value.`);if(e.debug(`Registering icon pack:`,n.name),`loader`in n)M.set(n.name,n.loader);else if(`icons`in n)j.set(n.name,n.icons);else throw e.error(`Invalid icon loader:`,n),Error(`Invalid icon loader. Must have either "icons" or "loader" property.`)}},`registerIconPacks`),P=t(async(t,n)=>{let r=u(t,!0,n!==void 0);if(!r)throw Error(`Invalid icon name: ${t}`);let i=r.prefix||n;if(!i)throw Error(`Icon name must contain a prefix: ${t}`);let a=j.get(i);if(!a){let t=M.get(i);if(!t)throw Error(`Icon set not found: ${r.prefix}`);try{a={...await t(),prefix:i},j.set(i,a)}catch(t){throw e.error(t),Error(`Failed to load icon set: ${r.prefix}`)}}let o=g(a,r.name);if(!o)throw Error(`Icon not found: ${t}`);return o},`getRegisteredIconData`),F=t(async e=>{try{return await P(e),!0}catch{return!1}},`isIconAvailable`),I=t(async(t,i,a)=>{let o;try{o=await P(t,i?.fallbackPrefix)}catch(t){e.error(t),o=A}let s=w(o,i),c=k(O(s.body),{...s.attributes,...a});return r(c,n())},`getIconSVG`);export{A as i,F as n,N as r,I as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-7INBJB4K-BkZ96Hf7.js b/frontend/dist/assets/chunk-7INBJB4K-BkZ96Hf7.js new file mode 100644 index 0000000..fd4f019 --- /dev/null +++ b/frontend/dist/assets/chunk-7INBJB4K-BkZ96Hf7.js @@ -0,0 +1,62 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,B as i,M as a,T as o,b as s,f as c,g as l,x as u,z as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as f,p,r as m,u as h}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{a as g,i as _,r as v,t as y}from"./chunk-7PRAP22T-DSs4vaIy.js";import{n as b,t as x}from"./chunk-742MDFTN-5mFByRwZ.js";import{n as S,r as C}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{s as w}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{t as T}from"./rough.esm-Dy-Kn_BL.js";var E=1,D=3;async function O(e){let t=e.getElementsByTagName(`img`);if(!t||t.length===0)return;let r=!k(e);await Promise.all([...t].map(e=>new Promise(t=>{function i(){if(e.style.display=`flex`,e.style.flexDirection=`column`,r){let t=u().fontSize?u().fontSize:window.getComputedStyle(document.body).fontSize,[n=c.fontSize]=p(t),r=n*5+`px`;e.style.minWidth=r,e.style.maxWidth=r}else e.style.width=`100%`;t(e)}n(i,`setupImage`),setTimeout(()=>{e.complete&&i()}),e.addEventListener(`error`,i),e.addEventListener(`load`,i)})))}n(O,`configureLabelImages`);function k(e){return e.nodeType===D?e.textContent?.trim()!==``:e.nodeType!==E||e.tagName.toLowerCase()===`img`?!1:[...e.childNodes].some(k)}n(k,`hasTextBesidesImages`);var A=3,j=32,M=n(async(e,n,r)=>{let i=u(),a=e.insert(`g`).attr(`class`,r??`node default`).attr(`id`,n.domId||n.id),o=a.insert(`g`).attr(`class`,`label`).attr(`style`,h(n.labelStyle)),s=[{text:typeof n.label==`string`?n.label:n.label?.[0]??``,cssClass:`c4-name`},{text:n.stereotype,cssClass:`c4-type`},...(n.description??[]).map(e=>({text:e,cssClass:`c4-descr`}))].filter(e=>e.text),c=n.width?Math.max(n.width-2*(n.padding??0),j):u().flowchart?.wrappingWidth??200,l=i.c4?.wrap??!0?c:1/0,p=await Promise.all(s.map(async e=>{let r=o.append(`g`).attr(`class`,e.cssClass),a=await S(r,d(f(e.text??``),i),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:l,style:n.labelStyle},i);return t(a).selectAll(`tspan.text-outer-tspan`).attr(`text-anchor`,`middle`),t(a).selectAll(`tspan.text-inner-tspan`).attr(`font-weight`,null).attr(`font-style`,null),{el:r,box:r.node().getBBox()}})),m=Math.max(...p.map(({box:e})=>e.width),0),g=0;for(let{el:e,box:t}of p)e.attr(`transform`,`translate(${m/2-t.x-t.width/2}, ${g-t.y})`),g+=t.height+A;let _=p.length>0?g-A:0;return o.insert(`rect`,`:first-child`),o.attr(`transform`,`translate(${-m/2}, ${-_/2})`),{shapeSvg:a,bbox:o.node().getBBox(),halfPadding:(n.padding??0)/2,label:o}},`c4LabelHelper`),N=n((e,t)=>{let{x:r,y:i,width:a,height:o}=e;return a>=t?e:`left`in e?{x:r,y:i,width:t,height:o,top:i,left:r,bottom:i+o,right:r+t,toJSON:n(()=>({}),`toJSON`)}:{x:r-(t-a)/2,y:i,width:t,height:o}},`withMinWidth`),P=n(async(e,n,r)=>{if(n.stereotype!==void 0)return M(e,n,r);let i,a=n.useHtmlLabels||l(u()?.htmlLabels);i=r||`node default`;let o=e.insert(`g`).attr(`class`,i).attr(`id`,n.domId||n.id),s=o.insert(`g`).attr(`class`,`label`).attr(`style`,h(n.labelStyle)),c;c=n.label===void 0?``:typeof n.label==`string`?n.label:n.label[0];let p=!!n.icon||!!n.img,m=n.labelType===`markdown`,g=c&&!n.width?n.minWidth??0:0,_=await S(s,d(f(c),u()),{useHtmlLabels:a,width:n.width||n.wrappingWidth||u().flowchart?.wrappingWidth,minWidth:g,classes:m?`markdown-node-label`:``,style:n.labelStyle,addSvgBackground:p,markdown:m},u()),v=(n?.padding??0)/2,y;if(a){let e=_.children[0],n=t(_);await O(e),y=await C.measure(()=>e.getBoundingClientRect()),y=N(y,g),n.attr(`width`,y.width),n.attr(`height`,y.height)}else y=await C.measure(()=>_.getBBox()),y=N(y,g);return a?s.attr(`transform`,`translate(`+-y.width/2+`, `+-y.height/2+`)`):s.attr(`transform`,`translate(0, `+-y.height/2+`)`),n.centerLabel&&s.attr(`transform`,`translate(`+-y.width/2+`, `+-y.height/2+`)`),s.insert(`rect`,`:first-child`),{shapeSvg:o,bbox:y,halfPadding:v,label:s}},`labelHelper`),F=n(async(e,n,r)=>{let i=r.useHtmlLabels??o(u()),a=e.insert(`g`).attr(`class`,`label`).attr(`style`,r.labelStyle||``),s=await S(a,d(f(n),u()),{useHtmlLabels:i,width:r.width||u()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),c=r.padding/2,l;if(o(u())){let e=s.children[0],n=t(s);l=await C.measure(()=>e.getBoundingClientRect()),n.attr(`width`,l.width),n.attr(`height`,l.height)}else l=await C.measure(()=>s.getBBox());return i?a.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`):a.attr(`transform`,`translate(0, `+-l.height/2+`)`),r.centerLabel&&a.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`),a.insert(`rect`,`:first-child`),{shapeSvg:e,bbox:l,halfPadding:c,label:a}},`insertLabel`),I=n((e,t,n)=>{if(n){e.width=n.width,e.height=n.height;return}let r=t.node().getBBox();e.width=r.width,e.height=r.height},`updateNodeBounds`),L=n((e,t)=>(e.look===`handDrawn`?`rough-node`:`node`)+` `+e.cssClasses+` `+(t||``),`getNodeClasses`);function R(e){let t=e.map((e,t)=>`${t===0?`M`:`L`}${e.x},${e.y}`);return t.push(`Z`),t.join(` `)}n(R,`createPathFromPoints`);function z(e,t,n,r,i,a){let o=[],s=n-e,c=r-t,l=s/a,u=2*Math.PI/l,d=t+c/2;for(let t=0;t<=50;t++){let n=e+t/50*s,r=d+i*Math.sin(u*(n-e));o.push({x:n,y:r})}return o}n(z,`generateFullSineWavePoints`);function B(e,t,n,r,i,a){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;ie.tagName===`path`),r=document.createElementNS(`http://www.w3.org/2000/svg`,`path`),i=t.map(e=>e.getAttribute(`d`)).filter(e=>e!==null).join(` `);r.setAttribute(`d`,i);let a=t.find(e=>e.getAttribute(`fill`)!==`none`),o=t.find(e=>e.getAttribute(`stroke`)!==`none`),s=n((e,t)=>e?.getAttribute(t)??void 0,`getAttr`);if(a){let e={fill:s(a,`fill`),"fill-opacity":s(a,`fill-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&r.setAttribute(e,t)})}if(o){let e={stroke:s(o,`stroke`),"stroke-width":s(o,`stroke-width`)??`1`,"stroke-opacity":s(o,`stroke-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&r.setAttribute(e,t)})}let c=document.createElementNS(`http://www.w3.org/2000/svg`,`g`);return c.appendChild(r),c}n(ee,`mergePaths`);var V=n((e,t)=>{var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2,c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=a===0?0:s*i/a,l=s):(i<0&&(o=-o),c=o,l=i===0?0:o*a/i),{x:n+c,y:r+l}},`intersectRect`);function te(e,t){return e.intersect(t)}n(te,`intersectNode`);var H=te;function U(e,t,n,r){var i=e.x,a=e.y,o=i-r.x,s=a-r.y,c=Math.sqrt(t*t*s*s+n*n*o*o),l=Math.abs(t*n*o/c);r.x0}n(G,`sameSign`);var ae=W;function oe(e,t,n){let r=e.x,i=e.y,a=[],o=1/0,s=1/0;typeof t.forEach==`function`?t.forEach(function(e){o=Math.min(o,e.x),s=Math.min(s,e.y)}):(o=Math.min(o,t.x),s=Math.min(s,t.y));let c=r-e.width/2-o,l=i-e.height/2-s;for(let r=0;r1&&a.sort(function(e,t){let r=e.x-n.x,i=e.y-n.y,a=Math.sqrt(r*r+i*i),o=t.x-n.x,s=t.y-n.y,c=Math.sqrt(o*o+s*s);return a[`M`,e+i,t,`H`,e+n-i,`A`,i,i,0,0,1,e+n,t+i,`V`,t+r-i,`A`,i,i,0,0,1,e+n-i,t+r,`H`,e+i,`A`,i,i,0,0,1,e,t+r-i,`V`,t+i,`A`,i,i,0,0,1,e+i,t,`Z`].join(` `),`createRoundedRectPathD`),se=n(async(e,t,n,r=!1,i=!1)=>{let a=t||``;typeof a==`object`&&(a=a[0]);let s=u(),c=o(s);return await S(e,a,{style:n,isTitle:r,useHtmlLabels:c,markdown:!1,isNode:i,width:1/0},s)},`createLabel`);function ce(t,n){let{labelStyles:r}=_(n);n.labelStyle=r;let i=L(n),a=i;i||(a=`anchor`);let o=t.insert(`g`).attr(`class`,a).attr(`id`,n.domId||n.id),{cssStyles:s}=n,c=T.svg(o),l=g(n,{fill:`black`,stroke:`none`,fillStyle:`solid`});n.look!==`handDrawn`&&(l.roughness=0);let u=c.circle(0,0,2,l),d=o.insert(()=>u,`:first-child`);return d.attr(`class`,`anchor`).attr(`style`,h(s)),I(n,d),n.intersect=function(t){return e.info(`Circle intersect`,n,1,t),K.circle(n,1,t)},o}n(ce,`anchor`);function le(e,t,n,r,i,a,o){let s=(e+n)/2,c=(t+r)/2,l=Math.atan2(r-t,n-e),u=(n-e)/2,d=(r-t)/2,f=u/i,p=d/a,m=Math.sqrt(f**2+p**2);if(m>1)throw Error(`The given radii are too small to create an arc between the points.`);let h=Math.sqrt(1-m**2),g=s+h*a*Math.sin(l)*(o?-1:1),_=c-h*i*Math.cos(l)*(o?-1:1),v=Math.atan2((t-_)/a,(e-g)/i),y=Math.atan2((r-_)/a,(n-g)/i)-v;o&&y<0&&(y+=2*Math.PI),!o&&y>0&&(y-=2*Math.PI);let b=[];for(let e=0;e<20;e++){let t=v+e/19*y,n=g+i*Math.cos(t),r=_+a*Math.sin(t);b.push({x:n,y:r})}return b}n(le,`generateArcPoints`);function ue(e,t,n){let[r,i]=[t,n].sort((e,t)=>t-e);return i*(1-Math.sqrt(1-(e/r/2)**2))}n(ue,`calculateArcSagitta`);async function de(e,t){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let a=t.padding??0,o=t.look===`neo`?16:a,s=t.look===`neo`?12:a,c=n(e=>e+s,`calcTotalHeight`),l=n(e=>{let t=e/2;return[t/(2.5+e/50),t]},`calcEllipseRadius`),{shapeSvg:u,bbox:d}=await P(e,t,L(t)),f=c(t?.height?t?.height:d.height),[p,m]=l(f),h=ue(f,p,m),v=(t?.width?t?.width:d.width)+o*2+h-h,y=f,{cssStyles:b}=t,x=[{x:v/2,y:-y/2},{x:-v/2,y:-y/2},...le(-v/2,-y/2,-v/2,y/2,p,m,!1),{x:v/2,y:y/2},...le(v/2,y/2,v/2,-y/2,p,m,!0)],S=T.svg(u),C=g(t,{});t.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`);let w=R(x),E=S.path(w,C),D=u.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),b&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,b),i&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,i),D.attr(`transform`,`translate(${p/2}, 0)`),I(t,D),t.intersect=function(e){return K.polygon(t,x,e)},u}n(de,`bowTieRect`);async function fe(e,t,{config:{themeVariables:r}}){let{labelStyles:i,nodeStyles:a}=_(t);t.labelStyle=i;let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=r?.nodeBorder??r?.lineColor??`currentColor`,u=t.padding??12,d=Math.max(s.width+u*2,t.width??0,80),f=Math.max(Math.min(d*.08,12),5),p=Math.max(s.height+u*2+f,t.height??0),m=-p/2+f,h=p/2,v=d*.72,y=[`M${-d/2},${m}`,`L${-v/2},${h}`,`A${v/2},${f} 0 0 0 ${v/2},${h}`,`L${d/2},${m}`,`A${d/2},${f} 0 0 0 ${-d/2},${m}`,`Z`].join(` `),{cssStyles:b}=t,x=o.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(o).path(y,g(t,{}));x.node()?.appendChild(e),b&&x.attr(`style`,b)}else x.append(`path`).attr(`d`,y).attr(`style`,a);x.append(`ellipse`).attr(`cx`,0).attr(`cy`,m).attr(`rx`,d/2).attr(`ry`,f).attr(`style`,`fill:none;stroke:${l};stroke-width:1px`),I(t,x);let S=m+(h-m)/2;c.attr(`transform`,`translate(${-(s.width/2)-(s.x-(s.left??0))}, ${S-s.height/2-(s.y-(s.top??0))})`);let C=n((e,t,n)=>Array.from({length:13},(r,i)=>{let a=Math.PI-i*Math.PI/12;return{x:e*Math.cos(a),y:t+n*f*Math.sin(a)}}),`arc`),w=[...C(d/2,m,-1),...C(v/2,h,1).reverse()];return t.intersect=function(e){return K.polygon(t,w,e)},o}n(fe,`bucket`);var pe=20,me=8,he=80,ge=8;function _e(e){let{themeVariables:t}=u(),n=t.clusterBkg,r=t.clusterBorder;switch(e){case`flow`:return{rx:10,fill:`none`,stroke:t.flowContainerStroke||t.secondaryBorderColor,strokeWidth:.75,cssClass:`flow-collapsed`};default:return{rx:ge,fill:n,stroke:r,cssClass:`collapsed-group`}}}n(_e,`getCollapsedStyle`);async function ve(e,t){let n=_e(t.metadata?.containerType),{fill:r,stroke:i}=n,{nodeStyles:a}=_(t),{shapeSvg:s,bbox:c}=await P(e,t,L(t)),{theme:l,themeVariables:d}=u();w(s,t.colorIndex,l,d.borderColorArray);let f=t.padding??8,p=c.height,m=Math.max(c.width+f*2,he,t?.width??0),v=Math.max(p+me+pe+f*2,t?.height??0),y=-m/2,b=-v/2,x=-(me+pe)/2,S=s.select(`.label`);S&&(t.useHtmlLabels??o(u())?S.attr(`transform`,`translate(${-c.width/2}, ${-c.height/2+x})`):S.attr(`transform`,`translate(0, ${-c.height/2+x})`));let C;if(t.look===`handDrawn`){let e=T.svg(s),a=g(t,{fill:r,stroke:i,...n.strokeWidth===void 0?{}:{strokeWidth:n.strokeWidth},...r===`none`?{fillWeight:0}:{fillStyle:`solid`}}),o=e.path(q(y,b,m,v,n.rx),a);C=s.insert(()=>o,`:first-child`),C.attr(`class`,`basic label-container `+n.cssClass).attr(`style`,h(t.cssStyles))}else C=s.insert(`rect`,`:first-child`),C.attr(`class`,`basic label-container `+n.cssClass).attr(`style`,a).attr(`rx`,n.rx).attr(`ry`,n.rx).attr(`x`,y).attr(`y`,b).attr(`width`,m).attr(`height`,v).attr(`fill`,r).attr(`stroke`,i),n.strokeWidth!==void 0&&C.attr(`stroke-width`,n.strokeWidth+`px`);let E=b+f+p+me;s.append(`line`).attr(`class`,`collapsed-separator`).attr(`x1`,y+8).attr(`y1`,E).attr(`x2`,y+m-8).attr(`y2`,E).attr(`stroke`,i).attr(`stroke-dasharray`,`3, 3`);let D=E+pe/2;for(let e=-1;e<=1;e++)s.append(`circle`).attr(`class`,`collapsed-indicator`).attr(`cx`,e*10).attr(`cy`,D).attr(`r`,2.5).attr(`fill`,i);return I(t,C),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},s}n(ve,`collapsedGroup`);function J(e,t,n,r){return e.insert(`polygon`,`:first-child`).attr(`points`,r.map(function(e){return e.x+`,`+e.y}).join(` `)).attr(`class`,`label-container`).attr(`transform`,`translate(`+-t/2+`,`+n/2+`)`)}n(J,`insertPolygonShape`);var ye=[`right`,`left`,`up`,`down`],be=`point`,xe=n(e=>{let t=new Set;for(let n of e)switch(n){case`x`:t.add(`right`),t.add(`left`);break;case`y`:t.add(`up`),t.add(`down`);break;default:t.add(n)}return t},`expandAndDeduplicateDirections`),Se=n(e=>ye.filter(t=>e.has(t)).join(`|`)||be,`getDirectionKey`),Ce={"right|left|up|down":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:0,y:0},{x:t,y:0},{x:r/2,y:2*n},{x:r-t,y:0},{x:r,y:0},{x:r,y:-e/3},{x:r+2*n,y:-e/2},{x:r,y:-2*e/3},{x:r,y:-e},{x:r-t,y:-e},{x:r/2,y:-e-2*n},{x:t,y:-e},{x:0,y:-e},{x:0,y:-2*e/3},{x:-2*n,y:-e/2},{x:0,y:-e/3}],`right|left|up|down`),"right|left|up":n(({height:e,midpoint:t,width:n})=>[{x:t,y:0},{x:n-t,y:0},{x:n,y:-e/2},{x:n-t,y:-e},{x:t,y:-e},{x:0,y:-e/2}],`right|left|up`),"right|left|down":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:t,y:-e},{x:n-t,y:-e},{x:n,y:0}],`right|left|down`),"right|up|down":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:n,y:-e+t},{x:0,y:-e}],`right|up|down`),"left|up|down":n(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:0,y:-e+t},{x:n,y:-e}],`left|up|down`),"right|left":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`right|left`),"up|down":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`up|down`),"right|up":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:0,y:-e}],`right|up`),"right|down":n(({height:e,width:t})=>[{x:0,y:0},{x:t,y:0},{x:0,y:-e}],`right|down`),"left|up":n(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:n,y:-e}],`left|up`),"left|down":n(({height:e,width:t})=>[{x:t,y:0},{x:0,y:0},{x:t,y:-e}],`left|down`),right:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e+n}],`right`),left:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`left`),up:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n}],`up`),down:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`down`),[be]:()=>[{x:0,y:0}]},we=n((e,t,n,r)=>{let i=xe(e),a=(n.padding??0)/2,o=t.height+4*a,s=o/2,c=r??t.width+2*s+2*a;return(Ce[Se(i)]??Ce[be])({height:o,midpoint:s,padding:a,width:c})},`getArrowPoints`);async function Te(e,t){let n=t,{shapeSvg:r,bbox:i}=await P(e,n,L(n)),a=n.padding??0,o=i.height+2*a,s=o/2,c=i.width+2*s+a,l=n.width??0,u=n.positioned&&(n.widthInColumns??1)>1&&l>c?l:c,d=we(n.directions??[],i,n,u),f=J(r,u,o,d);return f.attr(`style`,n.style??null),I(n,f),n.intersect=function(e){return K.polygon(n,d,e)},r}n(Te,`block_arrow`);async function Ee(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await P(e,t,L(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+18,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(a).path(q(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`line`).attr(`x1`,-u/2).attr(`y1`,f+18).attr(`x2`,u/2).attr(`y2`,f+18).attr(`style`,`stroke:${c};stroke-width:1px`);for(let e=0;e<3;e++)m.append(`circle`).attr(`cx`,-u/2+12+e*9).attr(`cy`,f+9).attr(`r`,2.5).attr(`style`,`fill:${c};stroke:none`);m.append(`rect`).attr(`class`,`browser-address-bar`).attr(`x`,-u/2+44).attr(`y`,f+4).attr(`width`,Math.max(u-56,10)).attr(`height`,10).attr(`rx`,3).attr(`ry`,3).attr(`style`,`fill:none;stroke:${c};stroke-width:1px;opacity:0.6`),I(t,m);let h=f+18+(d-18)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}n(Ee,`browser`);var De=12;async function Oe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?28:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width??c.width)+(t.look===`neo`?a*2:a+De),u=(t?.height??c.height)+(t.look===`neo`?o*2:o),d=l,f=-u,p=[{x:0+De,y:f},{x:d,y:f},{x:d,y:0},{x:0,y:0},{x:0,y:f+De},{x:0+De,y:f}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(p),i=e.path(r,n);m=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-l/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=J(s,l,u,p);return r&&m.attr(`style`,r),I(t,m),t.intersect=function(e){return K.polygon(t,p,e)},s}n(Oe,`card`);function ke(e,t){let{nodeStyles:n}=_(t);t.label=``;let r=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId??t.id),{cssStyles:i}=t,a=Math.max(28,t.width??0),o=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],s=T.svg(r),c=g(t,{});t.look!==`handDrawn`&&(c.roughness=0,c.fillStyle=`solid`);let l=R(o),u=s.path(l,c),d=r.insert(()=>u,`:first-child`);return i&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,i),n&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,n),t.width=28,t.height=28,t.intersect=function(e){return K.polygon(t,o,e)},r}n(ke,`choice`);async function Ae(t,n,r){let{labelStyles:i,nodeStyles:a}=_(n);n.labelStyle=i;let{shapeSvg:o,bbox:s,halfPadding:c}=await P(t,n,L(n)),l=r?.padding??c,u=Math.sqrt(s.width**2+s.height**2)/2,d=n.look===`neo`?u+32:u+l,f,{cssStyles:p}=n;if(n.look===`handDrawn`){let e=T.svg(o),t=g(n,{}),r=e.circle(0,0,d*2,t);f=o.insert(()=>r,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,h(p))}else f=o.insert(`circle`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,a).attr(`r`,d).attr(`cx`,0).attr(`cy`,0);return I(n,f),n.calcIntersect=function(e,t){let n=e.width/2;return K.circle(e,n,t)},n.intersect=function(t){return e.info(`Circle intersect`,n,d,t),K.circle(n,d,t)},o}n(Ae,`circle`);async function je(e,t){let n=t,{shapeSvg:r,bbox:i,halfPadding:a}=await P(e,n,[`node`,n.cssClasses,n.class].filter(Boolean).join(` `)),o=r.insert(`rect`,`:first-child`),s=n.padding??0,c=n.positioned?n.width??0:i.width+s,l=n.positioned?n.height??0:i.height+s,u=n.positioned?-c/2:-i.width/2-a,d=n.positioned?-l/2:-i.height/2-a;return o.attr(`class`,`basic cluster composite label-container`).attr(`style`,n.style??null).attr(`rx`,n.rx??null).attr(`ry`,n.ry??null).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l),I(n,o),n.intersect=function(e){return K.rect(n,e)},r}n(je,`composite`);async function Me(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await P(e,t,L(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+20,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(a).path(q(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`text`).attr(`x`,-u/2+12).attr(`y`,f+16).attr(`class`,`console-glyph`).attr(`style`,`font-family:monospace;font-weight:bold;font-size:14px;fill:${c}`).text(`>_`),I(t,m);let h=f+20+(d-20)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}n(Me,`consoleWindow`);function Ne(e){let t=Math.cos(Math.PI/4),n=Math.sin(Math.PI/4),r=e*2,i={x:r/2*t,y:r/2*n},a={x:-(r/2)*t,y:r/2*n},o={x:-(r/2)*t,y:-(r/2)*n},s={x:r/2*t,y:-(r/2)*n};return`M ${a.x},${a.y} L ${s.x},${s.y} + M ${i.x},${i.y} L ${o.x},${o.y}`}n(Ne,`createLine`);function Pe(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r,n.label=``;let a=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),o=Math.max(30,n?.width??0),{cssStyles:s}=n,c=T.svg(a),l=g(n,{});n.look!==`handDrawn`&&(l.roughness=0,l.fillStyle=`solid`);let u=c.circle(0,0,o*2,l),d=Ne(o),f=c.path(d,l),p=a.insert(()=>u,`:first-child`);return p.insert(()=>f),p.attr(`class`,`outer-path`),s&&n.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,s),i&&n.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,i),I(n,p),n.intersect=function(t){return e.info(`crossedCircle intersect`,n,{radius:o,point:t}),K.circle(n,o,t)},a}n(Pe,`crossedCircle`);function Y(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iS,`:first-child`).attr(`stroke-opacity`,0),C.insert(()=>b,`:first-child`),C.attr(`class`,`text`),f&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),C.attr(`transform`,`translate(${d}, 0)`),o.attr(`transform`,`translate(${-l/2+d-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,m,e)},i}n(Fe,`curlyBraceLeft`);function X(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iS,`:first-child`).attr(`stroke-opacity`,0),C.insert(()=>b,`:first-child`),C.attr(`class`,`text`),f&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),C.attr(`transform`,`translate(${-d}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,m,e)},i}n(Ie,`curlyBraceRight`);function Z(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iE,`:first-child`).attr(`stroke-opacity`,0),D.insert(()=>x,`:first-child`),D.insert(()=>C,`:first-child`),D.attr(`class`,`text`),f&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(${d-d/4}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,D),t.intersect=function(e){return K.polygon(t,h,e)},i}n(Le,`curlyBraces`);async function Re(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(5,c.height+o*2,t?.height??0),u=l/2,d=u-Math.sqrt(Math.max(0,u**2-(c.height/2)**2)),f=Math.max(l/4,d),p=Math.max(20,c.width+a*2+f*2,(c.width+a*2)*1.25,t?.width??0),{cssStyles:m}=t,h=T.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=p,b=l,x=y-u,S=b/4,C=[{x,y:0},{x:S,y:0},{x:0,y:b/2},{x:S,y:b},{x,y:b},...B(-x,-b/2,u,50,270,90)],w=R(C),E=h.path(w,v),D=s.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&D.selectChildren(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&D.selectChildren(`path`).attr(`style`,r),D.attr(`transform`,`translate(${-p/2}, ${-l/2})`),I(t,D),t.intersect=function(e){return K.polygon(t,C,e)},s}n(Re,`curvedTrapezoid`);async function ze(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??20,c=Math.max(a.width+s*2,t.width??0,100),l=Math.min(Math.max(c*.23,16),56),u=l*.27,d=Math.max(a.height+s*2,t.height?t.height-(2*l-u):0),f=Math.min(c*.177,d*.45),p=d+2*l-u,m=-p/2,h=m+2*l-u,v=i.insert(`g`,`:first-child`).attr(`class`,`basic label-container`),{cssStyles:y}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=e.path(q(-c/2,h,c,d,f),n),a=e.circle(0,m+l,l*2,n);v.insert(()=>a,`:first-child`),v.insert(()=>r,`:first-child`),y&&v.attr(`style`,y)}else v.append(`rect`).attr(`x`,-c/2).attr(`y`,h).attr(`width`,c).attr(`height`,d).attr(`rx`,f).attr(`ry`,f).attr(`style`,r),v.append(`circle`).attr(`cx`,0).attr(`cy`,m+l).attr(`r`,l).attr(`style`,r);I(t,v);let b=h+d/2;o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${b-a.height/2-(a.y-(a.top??0))})`);let x=m+l,S=Math.asin(Math.min(1,(h-x)/l))*180/Math.PI,C=[...B(0,-x,l,24,180+S,-S),...B(-(-c/2+f),-(h+f),f,12,90,0),...B(-(-c/2+f),-(p/2-f),f,12,360,270),...B(-(c/2-f),-(p/2-f),f,12,270,180),...B(-(c/2-f),-(h+f),f,12,180,90)];return t.intersect=function(e){return K.polygon(t,C,e)},i}n(ze,`person`);var Be=n((e,t,n,r,i,a)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createCylinderPathD`),Ve=n((e,t,n,r,i,a)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createOuterCylinderPathD`),He=n((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),Ue=8,We=8;async function Ge(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?24:i,o=t.look===`neo`?24:i,s=t.width??0;if(t.width&&(t.width-=o,t.widtho,`:first-child`),v=c.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=Be(0,0,d,m,f,p);v=c.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,h(y)).attr(`style`,r)}return v.attr(`label-offset-y`,p),v.attr(`transform`,`translate(${-d/2}, ${-(m/2+p)})`),I(t,v),u.attr(`transform`,`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+(t.padding??0)/1.5-(l.y-(l.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(f!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-p)){let i=p*p*(1-r*r/(f*f));i>0&&(i=Math.sqrt(i)),i=p-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},c}n(Ge,`cylinder`);async function Ke(e,t,n){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o}=await P(e,t,L(t)),s=Math.max(o.width+n.labelPaddingX*2,t?.width||0),c=Math.max(o.height+n.labelPaddingY*2,t?.height||0),l=-s/2,u=-c/2,d,{rx:f,ry:p}=t,{cssStyles:m}=t;if(n?.rx&&n.ry&&(f=n.rx,p=n.ry),t.look===`handDrawn`){let e=T.svg(a),n=g(t,{}),r=f||p?e.path(q(l,u,s,c,f||0),n):e.rectangle(l,u,s,c,n);d=a.insert(()=>r,`:first-child`),d.attr(`class`,`basic label-container`).attr(`style`,h(m))}else d=a.insert(`rect`,`:first-child`),d.attr(`class`,`basic label-container`).attr(`style`,i).attr(`rx`,h(f)).attr(`ry`,h(p)).attr(`x`,l).attr(`y`,u).attr(`width`,s).attr(`height`,c);return I(t,d,t.look===`handDrawn`?void 0:{width:s,height:c}),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},a}n(Ke,`drawRect`);async function qe(e,t){let{cssClasses:n,labelPaddingX:r,labelPaddingY:i,padding:a,width:o,height:s}=t,c=await Ke(e,t,{rx:0,ry:0,classes:n??``,labelPaddingX:r??(a??0)*2,labelPaddingY:i??a??0});if(t.look===`handDrawn`){let e=T.svg(c),n=g(t,{}),r=c.select(`.basic.label-container > path:nth-child(2)`),i=r.node();if(!i)return c;let a=null;if(i instanceof SVGGraphicsElement)a=i.getBBox();else return c;return c.insert(()=>e.line(a.x,a.y,a.x+a.width,a.y,n),`.basic.label-container g.label`),c.insert(()=>e.line(a.x,a.y+a.height,a.x+a.width,a.y+a.height,n),`.basic.label-container g.label`),r.remove(),c}let l=c.select(`.basic.label-container`),u=(Number(l.attr(`width`))||o)??0,d=(Number(l.attr(`height`))||s)??0;return u>0&&d>0&&l.attr(`stroke-dasharray`,`${u} ${d}`),c}n(qe,`datastore`);async function Je(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?16:t.padding??0,{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=s.width+i,u=s.height+a,d=u*.2,f=-l/2,p=-u/2-d/2,{cssStyles:m}=t,h=T.svg(o),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:f,y:p+d},{x:-f,y:p+d},{x:-f,y:-p},{x:f,y:-p},{x:f,y:p},{x:-f,y:p},{x:-f,y:p+d}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=o.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${f+(t.padding??0)/2-(s.x-(s.left??0))}, ${p+d+(t.padding??0)/2-(s.y-(s.top??0))})`),I(t,x),t.intersect=function(e){return K.rect(t,e)},o}n(Je,`dividedRectangle`);async function Ye(t,n){let{labelStyles:r,nodeStyles:i}=_(n),a=n.look===`neo`?12:5;n.labelStyle=r;let o=n.padding??0,s=n.look===`neo`?16:o,{shapeSvg:c,bbox:l}=await P(t,n,L(n)),u=Math.sqrt(l.width**2+l.height**2)/2,d=(n?.width?n?.width/2:u)+(s??0),f=d+a,p,{cssStyles:m}=n;if(n.look===`handDrawn`){let e=T.svg(c),t=g(n,{roughness:.2,strokeWidth:2.5}),r=g(n,{roughness:.2,strokeWidth:1.5}),i=e.circle(0,0,f*2,t),a=e.circle(0,0,d*2,r);p=c.insert(`g`,`:first-child`),p.attr(`class`,h(n.cssClasses)).attr(`style`,h(m)),p.node()?.appendChild(i),p.node()?.appendChild(a)}else{p=c.insert(`g`,`:first-child`);let e=p.insert(`circle`,`:first-child`),t=p.insert(`circle`);p.attr(`class`,`basic label-container`).attr(`style`,i),e.attr(`class`,`outer-circle`).attr(`style`,i).attr(`r`,f).attr(`cx`,0).attr(`cy`,0),t.attr(`class`,`inner-circle`).attr(`style`,i).attr(`r`,d).attr(`cx`,0).attr(`cy`,0)}return I(n,p),n.intersect=function(t){return e.info(`DoubleCircle intersect`,n,f,t),K.circle(n,f,t)},c}n(Ye,`doublecircle`);async function Xe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,halfPadding:o}=await P(e,t,L(t)),{theme:s,themeVariables:c}=u();w(i,t.colorIndex,s,c.borderColorArray);let l=o??10,d=a.width/2+l*2,f=a.height/2+l*2,p,{cssStyles:m}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=e.ellipse(0,0,d*2,f*2,n);p=i.insert(()=>r,`:first-child`),p.attr(`class`,`basic label-container`),m&&p.attr(`style`,m)}else p=i.insert(`ellipse`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,r).attr(`rx`,d).attr(`ry`,f).attr(`cx`,0).attr(`cy`,0);return t.width=d*2,t.height=f*2,I(t,p),t.calcIntersect=function(e,t){let n=e.width/2,r=e.height/2;return K.ellipse(e,n,r,t)},t.intersect=function(e){return K.ellipse(t,d,f,e)},i}n(Xe,`usecaseEllipse`);function Ze(t,n,{config:{themeVariables:r}}){let{labelStyles:i,nodeStyles:a}=_(n);n.label=``,n.labelStyle=i;let o=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),{cssStyles:s}=n,c=T.svg(o),{nodeBorder:l}=r,u=g(n,{fillStyle:`solid`});n.look!==`handDrawn`&&(u.roughness=0);let d=c.circle(0,0,14,u),f=o.insert(()=>d,`:first-child`);return f.selectAll(`path`).attr(`style`,`fill: ${l} !important;`),s&&s.length>0&&n.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,s),a&&n.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,a),I(n,f),n.intersect=function(t){return e.info(`filledCircle intersect`,n,{radius:7,point:t}),K.circle(n,7,t)},o}n(Ze,`filledCircle`);var Qe=10,$e=10;async function et(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.padding??0,o=n.look===`neo`?a*2:a;(n.width||n.height)&&(n.height=n?.height??0,n.heightb,`:first-child`).attr(`transform`,`translate(${-d/2}, ${d/2})`).attr(`class`,`outer-path`);return m&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,m),i&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,i),n.width=u,n.height=d,I(n,x),l.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${-d/2+(n.padding??0)/2+(c.y-(c.top??0))})`),n.intersect=function(t){return e.info(`Triangle intersect`,n,p,t),K.polygon(n,p,t)},s}n(et,`flippedTriangle`);async function tt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??12,c=Math.max(a.width+s*2,t.width??0,90),l=a.height+s*2,u=Math.max(Math.min(l*.16,14),8),d=Math.max(l+u,t.height??0),f=d-u,p=Math.max(c*.38,28),m=-d/2,h=[{x:-c/2,y:m},{x:-c/2+p,y:m},{x:-c/2+p,y:m+u},{x:c/2,y:m+u},{x:c/2,y:d/2},{x:-c/2,y:d/2}],v=[`M${h[0].x},${h[0].y}`,...h.slice(1).map(e=>`L${e.x},${e.y}`),`Z`].join(` `),{cssStyles:y}=t,b;if(t.look===`handDrawn`){let e=T.svg(i).path(v,g(t,{}));b=i.insert(()=>e,`:first-child`).attr(`class`,`basic label-container`),y&&b.attr(`style`,y)}else b=i.insert(`path`,`:first-child`).attr(`d`,v).attr(`class`,`basic label-container`).attr(`style`,r);t.look===`handDrawn`?I(t,b):I(t,b,{width:c,height:d});let x=m+u+f/2;return o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${x-a.height/2-(a.y-(a.top??0))})`),t.intersect=function(e){return K.polygon(t,h,e)},i}n(tt,`folder`);function nt(e,t,{dir:n,config:{state:r,themeVariables:i}}){let{nodeStyles:a}=_(t);t.label=``;let o=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId??t.id),{cssStyles:s}=t,c=Math.max(70,t?.width??0),l=Math.max(10,t?.height??0);(n===`LR`||n===`RL`)&&(c=Math.max(10,t?.width??0),l=Math.max(70,t?.height??0));let u=-1*c/2,d=-1*l/2,f=T.svg(o),p=g(t,{stroke:i.lineColor,fill:i.lineColor});t.look!==`handDrawn`&&(p.roughness=0,p.fillStyle=`solid`);let m=f.rectangle(u,d,c,l,p),h=o.insert(()=>m,`:first-child`);s&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,s),a&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,a),I(t,h);let v=r?.padding??0;return t.width&&t.height&&(t.width+=v/2||0,t.height+=v/2||0),t.intersect=function(e){return K.rect(t,e)},o}n(nt,`forkJoin`);async function rt(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.look===`neo`?16:n.padding??0,o=n.look===`neo`?12:n.padding??0;(n.width||n.height)&&(n.height=(n?.height??0)-o*2,n.height<10&&(n.height=10),n.width=(n?.width??0)-a*2,n.width<15&&(n.width=15));let{shapeSvg:s,bbox:c}=await P(t,n,L(n)),l=(n?.height?n?.height:Math.max(10,c.height))+o*2,u=l/2,d=u-Math.sqrt(Math.max(0,u**2-(c.height/2)**2)),f=(n?.width?n?.width:Math.max(15,c.width)+d*2)+a*2,{cssStyles:p}=n,m=T.svg(s),h=g(n,{});n.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-f/2,y:-l/2},{x:f/2-u,y:-l/2},...B(-f/2+u,0,u,50,90,270),{x:f/2-u,y:l/2},{x:-f/2,y:l/2}],y=R(v),b=m.path(y,h),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),p&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,p),i&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,i),I(n,x),n.intersect=function(t){return e.info(`Pill intersect`,n,{radius:u,point:t}),K.polygon(n,v,t)},s}n(rt,`halfRoundedRectangle`);var it=n((e,t,n,r,i)=>[`M${e+i},${t}`,`L${e+n-i},${t}`,`L${e+n},${t-r/2}`,`L${e+n-i},${t-r}`,`L${e+i},${t-r}`,`L${e},${t-r/2}`,`Z`].join(` `),`createHexagonPathD`);async function at(e,t){let{labelStyles:n,nodeStyles:r}=_(t),i=t.look===`neo`?3.5:4;t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?70:a,s=t.look===`neo`?32:a;if(t.width||t.height){let e=(t.height??0)/i;t.width=(t?.width??0)-2*e-s,t.height=(t.height??0)-o}let{shapeSvg:c,bbox:l}=await P(e,t,L(t)),u=(t?.height?t?.height:l.height)+o,d=u/i,f=(t?.width?t?.width:l.width)+2*d+s,p=[{x:d,y:0},{x:f-d,y:0},{x:f,y:-u/2},{x:f-d,y:-u},{x:d,y:-u},{x:0,y:-u/2}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=T.svg(c),n=g(t,{}),r=it(0,0,f,u,d),i=e.path(r,n);m=c.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-f/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=J(c,f,u,p);return r&&m.attr(`style`,r),t.width=f,t.height=u,I(t,m),t.intersect=function(e){return K.polygon(t,p,e)},c}n(at,`hexagon`);async function ot(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.label=``,n.labelStyle=r;let{shapeSvg:a}=await P(t,n,L(n)),o=Math.max(30,n?.width??0),s=Math.max(30,n?.height??0),{cssStyles:c}=n,l=T.svg(a),u=g(n,{});n.look!==`handDrawn`&&(u.roughness=0,u.fillStyle=`solid`);let d=[{x:0,y:0},{x:o,y:0},{x:0,y:s},{x:o,y:s}],f=R(d),p=l.path(f,u),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`basic label-container outer-path`),c&&n.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,c),i&&n.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,i),m.attr(`transform`,`translate(${-o/2}, ${-s/2})`),I(n,m),n.intersect=function(t){return e.info(`Pill intersect`,n,{points:d}),K.polygon(n,d,t)},a}n(ot,`hourglass`);async function st(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await P(t,n,`icon-shape default`),p=n.pos===`t`,m=c,h=c,{nodeBorder:v}=r,{stylesMap:b}=y(n),S=-h/2,C=-m/2,w=n.label?8:0,E=T.svg(u),D=g(n,{stroke:`none`,fill:`none`});n.look!==`handDrawn`&&(D.roughness=0,D.fillStyle=`solid`);let O=E.rectangle(S,C,h,m,D),k=Math.max(h,d.width),A=m+d.height+w,j=E.rectangle(-k/2,-A/2,k,A,{...D,fill:`transparent`,stroke:`none`}),M=u.insert(()=>O,`:first-child`),N=u.insert(()=>j);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${p?d.height/2+w/2-i/2-o:-d.height/2-w/2-i/2-o})`),e.attr(`style`,`color: ${b.get(`stroke`)??v};`)}return f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${p?-A/2:A/2-d.height})`),M.attr(`transform`,`translate(0,${p?d.height/2+w/2:-d.height/2-w/2})`),I(n,N),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=p?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+w},{x:r+h/2,y:i-a/2+d.height+w},{x:r+h/2,y:i+a/2},{x:r-h/2,y:i+a/2},{x:r-h/2,y:i-a/2+d.height+w},{x:r-d.width/2,y:i-a/2+d.height+w}]:[{x:r-h/2,y:i-a/2},{x:r+h/2,y:i-a/2},{x:r+h/2,y:i-a/2+m},{x:r+d.width/2,y:i-a/2+m},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+m},{x:r-h/2,y:i-a/2+m}],K.polygon(n,o,t)},u}n(st,`icon`);async function ct(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await P(t,n,`icon-shape default`),p=n.label?8:0,m=n.pos===`t`,{nodeBorder:h,mainBkg:v}=r,{stylesMap:b}=y(n),S=T.svg(u),C=g(n,{});n.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`),C.stroke=b.get(`fill`)??v;let w=u.append(`g`);n.icon&&w.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let E=w.node().getBBox(),D=E.width,O=E.height,k=E.x,A=E.y,j=Math.max(D,O)*Math.SQRT2+40,M=S.circle(0,0,j,C),N=Math.max(j,d.width),F=j+d.height+p,L=S.rectangle(-N/2,-F/2,N,F,{...C,fill:`transparent`,stroke:`none`}),R=u.insert(()=>M,`:first-child`),z=u.insert(()=>L);return w.attr(`transform`,`translate(${-D/2-k},${m?d.height/2+p/2-O/2-A:-d.height/2-p/2-O/2-A})`),w.attr(`style`,`color: ${b.get(`stroke`)??h};`),f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-F/2:F/2-d.height})`),R.attr(`transform`,`translate(0,${m?d.height/2+p/2:-d.height/2-p/2})`),I(n,z),n.intersect=function(t){return e.info(`iconSquare intersect`,n,t),K.rect(n,t)},u}n(ct,`iconCircle`);async function lt(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await P(t,n,`icon-shape default`),m=n.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:b,mainBkg:S}=r,{stylesMap:C}=y(n),w=-v/2,E=-h/2,D=n.label?8:0,O=T.svg(u),k=g(n,{});n.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=C.get(`fill`)??S;let A=O.path(q(w,E,v,h,5),k),j=Math.max(v,d.width),M=h+d.height+D,N=O.rectangle(-j/2,-M/2,j,M,{...k,fill:`transparent`,stroke:`none`}),F=u.insert(()=>A,`:first-child`).attr(`class`,`icon-shape2`),L=u.insert(()=>N);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${C.get(`stroke`)??b};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-M/2:M/2-d.height})`),F.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),I(n,L),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=m?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+D},{x:r+v/2,y:i-a/2+d.height+D},{x:r+v/2,y:i+a/2},{x:r-v/2,y:i+a/2},{x:r-v/2,y:i-a/2+d.height+D},{x:r-d.width/2,y:i-a/2+d.height+D}]:[{x:r-v/2,y:i-a/2},{x:r+v/2,y:i-a/2},{x:r+v/2,y:i-a/2+h},{x:r+d.width/2,y:i-a/2+h},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+h},{x:r-v/2,y:i-a/2+h}],K.polygon(n,o,t)},u}n(lt,`iconRounded`);async function ut(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await P(t,n,`icon-shape default`),m=n.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:b,mainBkg:S}=r,{stylesMap:C}=y(n),w=-v/2,E=-h/2,D=n.label?8:0,O=T.svg(u),k=g(n,{});n.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=C.get(`fill`)??S;let A=O.path(q(w,E,v,h,.1),k),j=Math.max(v,d.width),M=h+d.height+D,N=O.rectangle(-j/2,-M/2,j,M,{...k,fill:`transparent`,stroke:`none`}),F=u.insert(()=>A,`:first-child`),L=u.insert(()=>N);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${C.get(`stroke`)??b};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-M/2:M/2-d.height})`),F.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),I(n,L),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=m?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+D},{x:r+v/2,y:i-a/2+d.height+D},{x:r+v/2,y:i+a/2},{x:r-v/2,y:i+a/2},{x:r-v/2,y:i-a/2+d.height+D},{x:r-d.width/2,y:i-a/2+d.height+D}]:[{x:r-v/2,y:i-a/2},{x:r+v/2,y:i-a/2},{x:r+v/2,y:i-a/2+h},{x:r+d.width/2,y:i-a/2+h},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+h},{x:r-v/2,y:i-a/2+h}],K.polygon(n,o,t)},u}n(ut,`iconSquare`);async function dt(t,n,{config:{flowchart:r}}){let i=new Image;i.src=n?.img??``,await i.decode();let a=Number(i.naturalWidth.toString().replace(`px`,``)),o=Number(i.naturalHeight.toString().replace(`px`,``));n.imageAspectRatio=a/o;let{labelStyles:s}=_(n);n.labelStyle=s;let c=r?.wrappingWidth;n.defaultWidth=r?.wrappingWidth;let l=Math.max(n.label?c??0:0,n?.assetWidth??a),u=n.constraint===`on`&&n?.assetHeight?n.assetHeight*n.imageAspectRatio:l,d=n.constraint===`on`?u/n.imageAspectRatio:n?.assetHeight??o;n.width=Math.max(u,c??0);let{shapeSvg:f,bbox:p,label:m}=await P(t,n,`image-shape default`),h=n.pos===`t`,v=-u/2,y=-d/2,b=n.label?8:0,x=T.svg(f),S=g(n,{});n.look!==`handDrawn`&&(S.roughness=0,S.fillStyle=`solid`);let C=x.rectangle(v,y,u,d,S),w=Math.max(u,p.width),E=d+p.height+b,D=x.rectangle(-w/2,-E/2,w,E,{...S,fill:`none`,stroke:`none`}),O=f.insert(()=>C,`:first-child`),k=f.insert(()=>D);if(n.img){let e=f.append(`image`);e.attr(`href`,n.img),e.attr(`width`,u),e.attr(`height`,d),e.attr(`preserveAspectRatio`,`none`),e.attr(`transform`,`translate(${-u/2},${h?E/2-d:-E/2})`)}return m.attr(`transform`,`translate(${-p.width/2-(p.x-(p.left??0))},${h?-d/2-p.height/2-b/2:d/2-p.height/2+b/2})`),O.attr(`transform`,`translate(0,${h?p.height/2+b/2:-p.height/2-b/2})`),I(n,k),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=h?[{x:r-p.width/2,y:i-a/2},{x:r+p.width/2,y:i-a/2},{x:r+p.width/2,y:i-a/2+p.height+b},{x:r+u/2,y:i-a/2+p.height+b},{x:r+u/2,y:i+a/2},{x:r-u/2,y:i+a/2},{x:r-u/2,y:i-a/2+p.height+b},{x:r-p.width/2,y:i-a/2+p.height+b}]:[{x:r-u/2,y:i-a/2},{x:r+u/2,y:i-a/2},{x:r+u/2,y:i-a/2+d},{x:r+p.width/2,y:i-a/2+d},{x:r+p.width/2/2,y:i+a/2},{x:r-p.width/2,y:i+a/2},{x:r-p.width/2,y:i-a/2+d},{x:r-u/2,y:i-a/2+d}],K.polygon(n,o,t)},f}n(dt,`imageSquare`);async function ft(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a*2,t.height??0),u=Math.max(c.width+o*2,(t.width??0)-l),d=[{x:0,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:-3*l/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(ft,`inv_trapezoid`);async function pt(e,t){let{shapeSvg:n,bbox:r,label:i}=await P(e,t,`label`),a=n.insert(`rect`,`:first-child`);return a.attr(`width`,.1).attr(`height`,.1),n.attr(`class`,`label edgeLabel`),i.attr(`transform`,`translate(${-(r.width/2)-(r.x-(r.left??0))}, ${-(r.height/2)-(r.y-(r.top??0))})`),I(t,a),t.intersect=function(e){return K.rect(t,e)},n}n(pt,`labelRect`);async function mt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:0,y:0},{x:u+3*l/6,y:0},{x:u,y:-l},{x:-(3*l)/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(mt,`lean_left`);async function ht(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:-3*l/6,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:0,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(ht,`lean_right`);function gt(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.label=``,n.labelStyle=r;let a=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),{cssStyles:o}=n,s=Math.max(35,n?.width??0),c=Math.max(35,n?.height??0),l=[{x:s,y:0},{x:0,y:c+7/2},{x:s-14,y:c+7/2},{x:0,y:2*c},{x:s,y:c-7/2},{x:14,y:c-7/2}],u=T.svg(a),d=g(n,{});n.look!==`handDrawn`&&(d.roughness=0,d.fillStyle=`solid`);let f=R(l),p=u.path(f,d),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`outer-path`),o&&n.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,o),i&&n.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,i),m.attr(`transform`,`translate(-${s/2},${-c})`),I(n,m),n.intersect=function(t){return e.info(`lightningBolt intersect`,n,t),K.polygon(n,l,t)},a}n(gt,`lightningBolt`);var _t=n((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createCylinderPathD`),vt=n((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createOuterCylinderPathD`),yt=n((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),bt=10,xt=10;async function St(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?24:i;if(t.width||t.height){let e=t.width??0;t.width=(t.width??0)-a,t.widtho,`:first-child`).attr(`class`,`line`),v=s.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=_t(0,0,u,p,d,f,m);v=s.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,h(y)).attr(`style`,r)}return v.attr(`label-offset-y`,f),v.attr(`transform`,`translate(${-u/2}, ${-(p/2+f)})`),I(t,v),l.attr(`transform`,`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${-(c.height/2)+f-(c.y-(c.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(d!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-f)){let i=f*f*(1-r*r/(d*d));i>0&&(i=Math.sqrt(i)),i=f-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},s}n(St,`linedCylinder`);async function Ct(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=(t.width??0)*10/11-a*2,t.width<10&&(t.width=10),t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10));let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=(t?.width?t?.width:c.width)+(a??0)*2,d=(t?.height?t?.height:c.height)+(o??0)*2,f=t.look===`neo`?d/4:d/8,p=d+f,{cssStyles:m}=t,h=T.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:-u/2-u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:p/2},...z(-u/2-u/2*.1,p/2,u/2+u/2*.1,p/2,f,.8),{x:u/2+u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:-p/2},{x:-u/2,y:-p/2},{x:-u/2,y:p/2*1.1},{x:-u/2,y:-p/2}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),x.attr(`transform`,`translate(0,${-f/2})`),l.attr(`transform`,`translate(${-u/2+(t.padding??0)+u/2*.1/2-(c.x-(c.left??0))},${-d/2+(t.padding??0)-f-(c.y-(c.top??0))})`),I(t,x),t.intersect=function(e){return K.polygon(t,y,e)},s}n(Ct,`linedWaveEdgedRect`);var wt=56,Tt=72,Et=8,Dt=2,Ot=8,kt={normal:`usecase-actor-shape usecase-actor-normal`,hollow:`usecase-actor-hollow`,awesome:`usecase-actor-awesome`,icon:`usecase-actor-icon`},At=Math.PI/3,jt=.6,Mt=n((e,t)=>{let n=t*jt,r=t*Math.sqrt(1-jt**2),i=Math.cos(At),a=-Math.sin(At),o=n*-a,s=e+n*i,c=r*i,l=r*a;return`M ${o-c} ${s-l} L ${o+c} ${s+l}`},`businessMarkerPathForCircle`),Nt={normal:Mt(-24,12),hollow:Mt(-23,9),awesome:Mt(-21,13),icon:`M 12 -8 L 26 -26`},Pt=n((e,t,n)=>{let r=(t.x??0)-(t.left??0),i=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${-t.width/2-r},${n-t.height/2-i})`)},`positionLabel`),Ft=n((e,t,n,r,i=!1)=>{if(t.look===`handDrawn`){let a=T.svg(e).path(n,g(t,i?{fill:`none`}:{}));return e.insert(()=>a,`:first-child`).attr(`class`,r)}let a=e.append(`path`).attr(`class`,r).attr(`d`,n);return i&&a.attr(`fill`,`none`),a},`appendActorPath`),It=n((e,t,n,r,i,a,o=!1)=>{if(t.look===`handDrawn`){let s=T.svg(e).circle(n,r,i*2,g(t,o?{fill:`none`}:{}));return e.insert(()=>s,`:first-child`).attr(`class`,a)}let s=e.append(`circle`).attr(`class`,a).attr(`cx`,n).attr(`cy`,r).attr(`r`,i);return o&&s.attr(`fill`,`none`),s},`appendActorCircle`),Lt=n((e,t,n)=>{t.business&&e.append(`path`).attr(`class`,`usecase-business-marker usecase-actor-business-marker`).attr(`d`,Nt[n]).attr(`fill`,`none`).attr(`style`,`stroke: inherit !important; stroke-width: inherit !important`)},`appendBusinessActorMarker`);async function Rt(e,t,n,r){let{labelStyles:i,nodeStyles:a}=_(t);t.labelStyle=i;let{shapeSvg:o,bbox:s,label:c}=await P(e,n===`icon`||t.stereotype!==void 0?{...t,icon:n===`icon`?void 0:t.icon,stereotype:void 0}:t,L(t,`usecase-actor-variant usecase-actor-${n}`)),l=t.accessibleName??t.label;l&&o.attr(`role`,`img`).attr(`aria-label`,l),c.attr(`class`,`label actor-label usecase-actor-label`);let{theme:d,themeVariables:f}=u();w(o,t.colorIndex,d,f.borderColorArray);let p,m;if(t.stereotype){let e=await F(o,`\xAB${t.stereotype}\xBB`,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0,width:t.wrappingWidth});p=e.label.attr(`class`,`label usecase-stereotype`),m=e.bbox}let h=o.append(`g`).attr(`class`,`usecase-actor-glyph ${kt[n]}`).attr(`style`,a||null);await r(h,t),Lt(h,t,n);let g=t.padding??Ot,v=m?.height??0,y=Tt+Et+s.height+(m?v+Dt:0),b=Math.max(wt,s.width,m?.width??0)+g*2,x=y+g*2,S=-y/2;h.attr(`transform`,`translate(0,${S+Tt/2})`);let C=S+Tt+Et;return p&&m&&(C+=v/2,Pt(p,m,C),C+=v/2+Dt),Pt(c,s,C+s.height/2),I(t,o.insert(`rect`,`:first-child`).attr(`class`,`usecase-actor-outline`).attr(`x`,-b/2).attr(`y`,-x/2).attr(`width`,b).attr(`height`,x).attr(`opacity`,0).attr(`aria-hidden`,`true`)),t.intersect=e=>K.rect(t,e),o}n(Rt,`renderUsecaseActor`);var zt=[`M 0 -12`,`C 6.627 -12 12 -17.373 12 -24`,`C 12 -30.627 6.627 -36 0 -36`,`C -6.627 -36 -12 -30.627 -12 -24`,`C -12 -17.373 -6.627 -12 0 -12 Z`,`M 0 -12 V 8`,`M -17 -5 H 17`,`M 0 8 L -15 28`,`M 0 8 L 15 28`].join(` `);async function Bt(e,t){return Rt(e,t,`normal`,(e,t)=>{Ft(e,t,zt,`usecase-actor-stick`)})}n(Bt,`usecaseActor`);var Vt=[`M 0 -34`,`C 7.18 -34 13 -28.18 13 -21`,`C 13 -13.82 7.18 -8 0 -8`,`C -7.18 -8 -13 -13.82 -13 -21`,`C -13 -28.18 -7.18 -34 0 -34 Z`,`M -24 25`,`C -24 7 -14 -3 0 -3`,`C 14 -3 24 7 24 25`,`C 24 28 21 30 18 30`,`H -18`,`C -21 30 -24 28 -24 25 Z`].join(` `);async function Ht(e,t){return Rt(e,t,`awesome`,(e,t)=>{Ft(e,t,Vt,`usecase-actor-awesome-silhouette`)})}n(Ht,`usecaseActorAwesome`);var Ut=[`M -22 -10`,`H 22`,`V 0`,`H 6`,`L 22 17`,`L 13 28`,`L 0 13`,`L -13 28`,`L -22 17`,`L -6 0`,`H -22`,`Z`].join(` `);async function Wt(e,t){return Rt(e,t,`hollow`,(e,t)=>{It(e,t,0,-23,9,`usecase-actor-hollow-head`,!0),Ft(e,t,Ut,`usecase-actor-hollow-body`,!0)})}n(Wt,`usecaseActorHollow`);var Gt=52,Kt=42,qt=-2,Jt=n(async(e,t)=>{let n=-Gt/2,r=qt-Gt/2;if(t.look===`handDrawn`){let i=T.svg(e).rectangle(n,r,Gt,Gt,g(t,{}));e.insert(()=>i,`:first-child`).attr(`class`,`usecase-actor-icon-frame`)}else e.append(`rect`).attr(`class`,`usecase-actor-icon-frame`).attr(`x`,n).attr(`y`,r).attr(`width`,Gt).attr(`height`,Gt).attr(`rx`,4).attr(`ry`,4);let i=t.icon??``,a=await b(i.includes(`:`)?i:`fa:${i}`),o=await x(i,{height:Kt,width:Kt,fallbackPrefix:`fa`}),s=e.append(`g`).attr(`class`,`usecase-actor-icon-symbol${a?``:` usecase-actor-icon-fallback`}`).attr(`aria-hidden`,`true`).html(`${o}`),c=s.node()?.getBBox();c&&s.attr(`transform`,`translate(${-c.width/2-c.x},${qt-c.height/2-c.y})`)},`drawIconActor`);async function Yt(e,t){return Rt(e,t,`icon`,Jt)}n(Yt,`usecaseActorIcon`);var Xt=n((e,t,n)=>{let r=(t.x??0)-(t.left??0),i=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${-t.width/2-r},${n-t.height/2-i})`)},`positionLabel`);async function Zt(e,t){let n=t,{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(e,n.stereotype?{...t,stereotype:void 0}:t,L(t,`usecase-business-shape`));c.attr(`class`,`label usecase-label`);let{theme:l,themeVariables:d}=u();w(a,t.colorIndex,l,d.borderColorArray);let f,p;if(n.stereotype){let e=await F(a,`\xAB${n.stereotype}\xBB`,{labelStyle:r,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0,width:t.wrappingWidth});f=e.label.attr(`class`,`label usecase-stereotype`),p=e.bbox}let m=p?2:0,h=o.height+(p?.height??0)+m,v=Math.max(o.width,p?.width??0),y=s??10,b=v/2+y*2,x=h/2+y*2,S=Math.min(Math.max(y/5,1),y/2),C=v/2+S,E=b-S,D=C/b,O=E/b,k=x*Math.sqrt(Math.max(0,1-D*D)),A=-x*Math.sqrt(Math.max(0,1-O*O));f&&p&&Xt(f,p,-h/2+p.height/2),Xt(c,o,h/2-o.height/2);let j;if(t.look===`handDrawn`){let e=T.svg(a).ellipse(0,0,b*2,x*2,g(t,{}));j=a.insert(()=>e,`:first-child`).attr(`class`,`basic label-container usecase-business-ellipse`)}else j=a.insert(`ellipse`,`:first-child`).attr(`class`,`basic label-container usecase-business-ellipse`).attr(`style`,i).attr(`rx`,b).attr(`ry`,x).attr(`cx`,0).attr(`cy`,0);a.append(`path`).attr(`class`,`usecase-business-marker`).attr(`d`,`M ${C} ${k} L ${E} ${A}`).attr(`fill`,`none`).attr(`style`,i||null);let M=n.accessibleName??n.label;return M&&a.attr(`role`,`img`).attr(`aria-label`,M),I(t,j),t.calcIntersect=(e,t)=>K.ellipse(e,e.width/2,e.height/2,t),t.intersect=e=>K.ellipse(t,b,x,e),a}n(Zt,`usecaseBusiness`);var Qt=8,$t=4,en=1,tn=n((e,t,n,r)=>{let i=(t.x??0)-(t.left??0),a=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${n-t.width/2-i},${r-t.height/2-a})`)},`positionLabel`),nn=n(e=>{let t=Number.parseFloat(e??``);return Number.isFinite(t)&&t>=0?t:en},`numericStrokeWidth`);async function rn(e,t){let r=t,{labelStyles:i,nodeStyles:a}=_(t),{stylesMap:o}=y(t);t.labelStyle=i;let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t,`usecase-json-table`));s.attr(`role`,`img`),r.accessibleName&&s.attr(`aria-label`,r.accessibleName),l.attr(`class`,`label usecase-json-title`);let u=s.append(`g`).attr(`class`,`usecase-json-table-grid`),d=[];for(let e of r.jsonRows??[]){let n=await F(u,e.key,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0}),r=await F(u,e.value,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0});d.push({key:{label:n.label.attr(`class`,`label usecase-json-key`),bbox:n.bbox},value:{label:r.label.attr(`class`,`label usecase-json-value`),bbox:r.bbox}})}let f=Math.max(0,...d.map(({key:e})=>e.bbox.width))+Qt*2,p=Math.max(0,...d.map(({value:e})=>e.bbox.width))+Qt*2,m=c.width+Qt*2,h=Math.max(m,f+p),v=p+Math.max(0,h-f-p),b=c.height+$t*2,x=d.map(({key:e,value:t})=>Math.max(e.bbox.height,t.bbox.height)+$t*2),S=b+x.reduce((e,t)=>e+t,0),C=nn(o.get(`stroke-width`)),w=h+C*2,E=S+C*2,D=-h/2,O=-S/2,k=t.look===`handDrawn`?T.svg(s):void 0,A=k?g(t,{}):void 0,j=n((e,t,n,r,i,o)=>{if(k&&A){let a=k.rectangle(n,r,i,o,A);return e.insert(()=>a,`:first-child`).attr(`class`,t)}return e.insert(`rect`,`:first-child`).attr(`class`,t).attr(`x`,n).attr(`y`,r).attr(`width`,i).attr(`height`,o).attr(`style`,a)},`insertCell`),M=j(s,`label-container usecase-json-border`,-w/2,-E/2,w,E);j(u,`usecase-json-cell usecase-json-title-cell`,D,O,h,b),u.node()?.append(l.node()),tn(l,c,0,O+b/2);let N=O+b;return d.forEach(({key:e,value:t},n)=>{let r=x[n],i=u.append(`g`).attr(`class`,`usecase-json-row`).attr(`data-row-index`,n).attr(`transform`,`translate(0,${N})`);j(i,`usecase-json-cell usecase-json-key-cell`,D,0,f,r),j(i,`usecase-json-cell usecase-json-value-cell`,D+f,0,v,r),i.node()?.append(e.label.node(),t.label.node()),tn(e.label,e.bbox,D+f/2,r/2),tn(t.label,t.bbox,D+f+v/2,r/2),N+=r}),I(t,M),t.intersect=e=>K.rect(t,e),s}n(rn,`usecaseJsonTable`);async function an(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,s=t.look===`neo`?10:5;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2-2*s,10),t.height=Math.max((t?.height??0)-o*2-2*s,10));let{shapeSvg:c,bbox:l,label:u}=await P(e,t,L(t)),d=(t?.width?t?.width:l.width)+a*2+2*s,f=(t?.height?t?.height:l.height)+o*2+2*s,p=d-2*s,m=f-2*s,h=-p/2,v=-m/2,{cssStyles:y}=t,b=T.svg(c),x=g(t,{}),S=[{x:h-s,y:v+s},{x:h-s,y:v+m+s},{x:h+p-s,y:v+m+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v+m-s},{x:h+p+s,y:v+m-s},{x:h+p+s,y:v-s},{x:h+s,y:v-s},{x:h+s,y:v},{x:h,y:v},{x:h,y:v+s}],C=[{x:h,y:v+s},{x:h+p-s,y:v+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v},{x:h,y:v}];t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let w=R(S),E=b.path(w,x),D=R(C),O=b.path(D,x);t.look!==`handDrawn`&&(E=ee(E),O=ee(O));let k=c.insert(`g`,`:first-child`);return k.insert(()=>E),k.insert(()=>O),k.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,r),u.attr(`transform`,`translate(${-(l.width/2)-s-(l.x-(l.left??0))}, ${-(l.height/2)+s-(l.y-(l.top??0))})`),I(t,k),t.intersect=function(e){return K.polygon(t,S,e)},c}n(an,`multiRect`);async function on(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??0,c=t.look===`neo`?16:s,l=t.look===`neo`?12:s,u=!0;(t.width||t.height)&&(u=!1,t.width=(t?.width??0)-c*2,t.height=(t?.height??0)-l*3);let d=Math.max(a.width,t?.width??0)+c*2,f=Math.max(a.height,t?.height??0)+l*3,p=t.look===`neo`?f/4:f/8,m=f+(u?p/2:-p/2),h=-d/2,v=-m/2,{cssStyles:y}=t,b=z(h-10,v+m+10,h+d-10,v+m+10,p,.8),x=b?.[b.length-1],S=[{x:h-10,y:v+10},{x:h-10,y:v+m+10},...b,{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:x.y-20},{x:h+d+10,y:x.y-20},{x:h+d+10,y:v-10},{x:h+10,y:v-10},{x:h+10,y:v},{x:h,y:v},{x:h,y:v+10}],C=[{x:h,y:v+10},{x:h+d-10,y:v+10},{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:v},{x:h,y:v}],w=T.svg(i),E=g(t,{});t.look!==`handDrawn`&&(E.roughness=0,E.fillStyle=`solid`);let D=R(S),O=w.path(D,E),k=R(C),A=w.path(k,E),j=i.insert(()=>O,`:first-child`);return j.insert(()=>A),j.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&j.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&j.selectAll(`path`).attr(`style`,r),j.attr(`transform`,`translate(0,${-p/2})`),o.attr(`transform`,`translate(${-(a.width/2)-10-(a.x-(a.left??0))}, ${-(a.height/2)+10-p-(a.y-(a.top??0))})`),I(t,j),t.intersect=function(e){return K.polygon(t,S,e)},i}n(on,`multiWaveEdgedRectangle`);async function sn(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r,t.useHtmlLabels||o(s())||(t.centerLabel=!0);let{shapeSvg:a,bbox:c,label:l}=await P(e,t,L(t)),u=Math.max(c.width+(t.padding??0)*2,t?.width??0),d=Math.max(c.height+(t.padding??0)*2,t?.height??0),f=-u/2,p=-d/2,{cssStyles:m}=t,h=T.svg(a),v=g(t,{fill:n.noteBkgColor,stroke:n.noteBorderColor});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=h.rectangle(f,p,u,d,v),b=a.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),l.attr(`class`,`label noteLabel`),m&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,m),i&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,i),l.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,b),t.intersect=function(e){return K.rect(t,e)},a}n(sn,`note`);var cn=n((e,t,n)=>[`M${e+n/2},${t}`,`L${e+n},${t-n/2}`,`L${e+n/2},${t-n}`,`L${e},${t-n/2}`,`Z`].join(` `),`createDecisionBoxPathD`);async function ln(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await P(e,t,L(t)),o=a.width+(t.padding??0)+(a.height+(t.padding??0)),s=.5,c=[{x:o/2,y:0},{x:o,y:-o/2},{x:o/2,y:-o},{x:0,y:-o/2}],l,{cssStyles:u}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=cn(0,0,o),a=e.path(r,n);l=i.insert(()=>a,`:first-child`).attr(`transform`,`translate(${-o/2+s}, ${o/2})`),u&&l.attr(`style`,u)}else l=J(i,o,o,c),l.attr(`transform`,`translate(${-o/2+s}, ${o/2})`);return r&&l.attr(`style`,r),I(t,l),t.calcIntersect=function(e,t){let n=e.width,r=[{x:n/2,y:0},{x:n,y:-n/2},{x:n/2,y:-n},{x:0,y:-n/2}];return K.polygon(e,r,t)},t.intersect=function(e){return this.calcIntersect(t,e)},i}n(ln,`question`);async function un(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?21:i??0,o=t.look===`neo`?12:i??0,{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=c.width+(t.look===`neo`?a*2:a),d=Math.max(c.height+(t.look===`neo`?o*2:o),t.height??0),f=d/4,p=-Math.max(u,(t.width??0)-f)/2,m=-d/2,h=m/2,v=[{x:p+h,y:m},{x:p,y:0},{x:p+h,y:-m},{x:-p,y:-m},{x:-p,y:m}],{cssStyles:y}=t,b=T.svg(s),x=g(t,{});t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let S=R(v),C=b.path(S,x),w=s.insert(()=>C,`:first-child`);return w.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,r),w.attr(`transform`,`translate(${-h/2},0)`),l.attr(`transform`,`translate(${-h/2-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,w),t.intersect=function(e){return K.polygon(t,v,e)},s}n(un,`rect_left_inv_arrow`);async function dn(n,r){let{labelStyles:i,nodeStyles:a}=_(r);r.labelStyle=i;let s;s=r.cssClasses?`node `+r.cssClasses:`node default`;let c=n.insert(`g`).attr(`class`,s).attr(`id`,r.domId||r.id),l=c.insert(`g`),d=c.insert(`g`).attr(`class`,`label`).attr(`style`,a),f=r.description,p=r.label,m=await se(d,p,r.labelStyle,!0,!0),h={width:0,height:0};if(o(u())){let e=m.children[0],n=t(m);h=e.getBoundingClientRect(),n.attr(`width`,h.width),n.attr(`height`,h.height)}e.info(`Text 2`,f);let v=f||[],y=m.getBBox(),b=await se(d,Array.isArray(v)?v.join(`
`):v,r.labelStyle,!0,!0),x=b.children[0],S=t(b);h=x.getBoundingClientRect(),S.attr(`width`,h.width),S.attr(`height`,h.height);let C=(r.padding||0)/2;t(b).attr(`transform`,`translate( `+(h.width>y.width?0:(y.width-h.width)/2)+`, `+(y.height+C+5)+`)`),t(m).attr(`transform`,`translate( `+(h.width(e.debug(`Rough node insert CXC`,i),a),`:first-child`),k=c.insert(()=>(e.debug(`Rough node insert CXC`,i),i),`:first-child`)}else k=l.insert(`rect`,`:first-child`),A=l.insert(`line`),k.attr(`class`,`outer title-state`).attr(`style`,a).attr(`x`,-h.width/2-C).attr(`y`,-h.height/2-C).attr(`width`,h.width+(r.padding||0)).attr(`height`,h.height+(r.padding||0)),A.attr(`class`,`divider`).attr(`x1`,-h.width/2-C).attr(`x2`,h.width/2+C).attr(`y1`,-h.height/2-C+y.height+C).attr(`y2`,-h.height/2-C+y.height+C);return I(r,k),r.intersect=function(e){return K.rect(r,e)},c}n(dn,`rectWithTitle`);async function fn(e,t,{config:{themeVariables:n}}){let r=n?.radius??5;return Ke(e,t,{rx:r,ry:r,classes:``,labelPaddingX:(t?.padding??0)*1,labelPaddingY:(t?.padding??0)*1})}n(fn,`roundedRect`);var pn=8;async function mn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?12:t.padding??0,{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=(t?.width??s.width)+i*2+(t.look===`neo`?pn:pn*2),u=(t?.height??s.height)+a*2,d=l-pn,f=u,p=pn-l/2,m=-u/2,{cssStyles:v}=t,y=T.svg(o),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:p,y:m},{x:p+d,y:m},{x:p+d,y:m+f},{x:p-pn,y:m+f},{x:p-pn,y:m},{x:p,y:m},{x:p,y:m+f}],S=y.polygon(x.map(e=>[e.x,e.y]),b),C=o.insert(()=>S,`:first-child`);return C.attr(`class`,`basic label-container outer-path`).attr(`style`,h(v)),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),v&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${pn/2-s.width/2-(s.x-(s.left??0))}, ${-(s.height/2)-(s.y-(s.top??0))})`),I(t,C),t.intersect=function(e){return K.rect(t,e)},o}n(mn,`shadedProcess`);async function hn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2,10),t.height=Math.max((t?.height??0)/1.5-o*2,10));let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=(t?.width?t?.width:c.width)+a*2,d=((t?.height?t?.height:c.height)+o*2)*1.5,f=u,p=d/1.5,m=-f/2,h=-p/2,{cssStyles:v}=t,y=T.svg(s),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:m,y:h},{x:m,y:h+p},{x:m+f,y:h+p},{x:m+f,y:h-p/2}],S=R(x),C=y.path(S,b),w=s.insert(()=>C,`:first-child`);return w.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,r),w.attr(`transform`,`translate(0, ${p/4})`),l.attr(`transform`,`translate(${-f/2+(t.padding??0)-(c.x-(c.left??0))}, ${-p/4+(t.padding??0)-(c.y-(c.top??0))})`),I(t,w),t.intersect=function(e){return K.polygon(t,x,e)},s}n(hn,`slopedRect`);async function gn(e,t){let n=t.padding??0,r=t.look===`neo`?16:n*2,i=t.look===`neo`?12:n,a=await Ke(e,t,{rx:0,ry:0,classes:``,labelPaddingX:t.labelPaddingX??r,labelPaddingY:i});if(t.colorIndex!==void 0){let{theme:e,themeVariables:n}=u();w(a,t.colorIndex,e,n.borderColorArray)}return a}n(gn,`squareRect`);var _n=50,vn=n((e,t,n)=>{let r=e.height+n,i=r*Math.cos(Math.PI/(2*(_n-1))),a=Math.sqrt(Math.max(0,i**2-e.height**2));return{w:Math.max(e.width+r/4+t,1.5*r+(r-i),e.width+t+r-a),h:r}},`stadiumDimensions`);async function yn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?40:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),{w:l,h:u}=vn(c,a,o),d=u/2,{cssStyles:f}=t,p=T.svg(s),m=g(t,{});t.look!==`handDrawn`&&(m.roughness=0,m.fillStyle=`solid`);let h=[{x:-l/2+d,y:-u/2},{x:l/2-d,y:-u/2},...B(-l/2+d,0,d,_n,90,270),{x:l/2-d,y:u/2},...B(l/2-d,0,d,_n,270,450)],v=R(h),y=p.path(v,m),b=s.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),f&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,r),I(t,b),t.intersect=function(e){return K.polygon(t,h,e)},s}n(yn,`stadium`);async function bn(e,t){return Ke(e,t,{rx:t.look===`neo`?3:5,ry:t.look===`neo`?3:5,classes:`flowchart-node`})}n(bn,`state`);function xn(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{cssStyles:a}=t,{lineColor:o,stateBorder:s,nodeBorder:c,nodeShadow:l}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let u=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId??t.id),d=T.svg(u),f=g(t,{});t.look!==`handDrawn`&&(f.roughness=0,f.fillStyle=`solid`);let p=d.circle(0,0,t.width,{...f,stroke:o,strokeWidth:2}),m=s??c,h=(t.width??0)*5/14,v=d.circle(0,0,h,{...f,fill:m,stroke:m,strokeWidth:2,fillStyle:`solid`}),y=u.insert(()=>p,`:first-child`);if(y.insert(()=>v),t.look!==`handDrawn`&&y.attr(`class`,`outer-path`),a&&y.selectAll(`path`).attr(`style`,a),i&&y.selectAll(`path`).attr(`style`,i),t.width<25&&l&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;y.attr(`style`,`filter:url(#${n})`)}return I(t,y),t.intersect=function(e){return K.circle(t,(t.width??0)/2,e)},u}n(xn,`stateEnd`);function Sn(e,t,{config:{themeVariables:n}}){let{lineColor:r,nodeShadow:i}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let a=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId||t.id),o;if(t.look===`handDrawn`){let e=T.svg(a).circle(0,0,t.width,v(r));o=a.insert(()=>e),o.attr(`class`,`state-start`).attr(`r`,(t.width??7)/2).attr(`width`,t.width??14).attr(`height`,t.height??14)}else o=a.insert(`circle`,`:first-child`),o.attr(`class`,`state-start`).attr(`r`,(t.width??7)/2).attr(`width`,t.width??14).attr(`height`,t.height??14);if(t.width<25&&i&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;o.attr(`style`,`filter:url(#${n})`)}return I(t,o),t.intersect=function(e){return K.circle(t,(t.width??7)/2,e)},a}n(Sn,`stateStart`);var Cn=8;async function wn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t?.padding??8,a=t.look===`neo`?28:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.width+2*Cn+a,t.width??0),u=Math.max(c.height+o,t.height??0),d=l-2*Cn,f=u,p=-l/2,m=-u/2,v=[{x:0,y:0},{x:d,y:0},{x:d,y:-f},{x:0,y:-f},{x:0,y:0},{x:-8,y:0},{x:d+8,y:0},{x:d+8,y:-f},{x:-8,y:-f},{x:-8,y:0}];if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=e.rectangle(p,m,d+16,f,n),i=e.line(p+Cn,m,p+Cn,m+f,n),a=e.line(p+Cn+d,m,p+Cn+d,m+f,n);s.insert(()=>i,`:first-child`),s.insert(()=>a,`:first-child`);let o=s.insert(()=>r,`:first-child`),{cssStyles:c}=t;o.attr(`class`,`basic label-container`).attr(`style`,h(c)),I(t,o)}else{let e=J(s,d,f,v);r&&e.attr(`style`,r),I(t,e)}return t.intersect=function(e){return K.polygon(t,v,e)},s}n(wn,`subroutine`);var Tn=.2;async function En(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.height=Math.max((t?.height??0)-o*2,10),t.width=Math.max((t?.width??0)-a*2-Tn*(t.height+o*2),10));let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.height?t?.height:c.height)+o*2,u=Tn*l,d=Tn*l,f=(t?.width?t?.width:c.width)+a*2+u-u,p=l,m=-f/2,h=-p/2,{cssStyles:v}=t,y=T.svg(s),b=g(t,{}),x=[{x:m-u/2,y:h},{x:m+f+u/2,y:h},{x:m+f+u/2,y:h+p},{x:m-u/2,y:h+p}],S=[{x:m+f-u/2,y:h+p},{x:m+f+u/2,y:h+p},{x:m+f+u/2,y:h+p-d}];t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let C=R(x),w=y.path(C,b),E=R(S),D=y.path(E,{...b,fillStyle:`solid`}),O=s.insert(()=>D,`:first-child`);return O.insert(()=>w,`:first-child`),O.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,r),I(t,O),t.intersect=function(e){return K.polygon(t,x,e)},s}n(En,`taggedRect`);async function Dn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=Math.max(a.width+(t.padding??0)*2,t?.width??0),c=Math.max(a.height+(t.padding??0)*2,t?.height??0),l=c/8,u=.2*s,d=.2*c,f=c+l,{cssStyles:p}=t,m=T.svg(i),h=g(t,{});t.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-s/2-s/2*.1,y:f/2},...z(-s/2-s/2*.1,f/2,s/2+s/2*.1,f/2,l,.8),{x:s/2+s/2*.1,y:-f/2},{x:-s/2-s/2*.1,y:-f/2}],y=-s/2+s/2*.1,b=-f/2-d*.4,x=[{x:y+s-u,y:(b+c)*1.3},{x:y+s,y:b+c-d},{x:y+s,y:(b+c)*.9},...z(y+s,(b+c)*1.25,y+s-u,(b+c)*1.3,-c*.02,.5)],S=R(v),C=m.path(S,h),w=R(x),E=m.path(w,{...h,fillStyle:`solid`}),D=i.insert(()=>E,`:first-child`);return D.insert(()=>C,`:first-child`),D.attr(`class`,`basic label-container outer-path`),p&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,p),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(0,${-l/2})`),o.attr(`transform`,`translate(${-s/2+(t.padding??0)-(a.x-(a.left??0))},${-c/2+(t.padding??0)-l/2-(a.y-(a.top??0))})`),I(t,D),t.intersect=function(e){return K.polygon(t,v,e)},i}n(Dn,`taggedWaveEdgedRectangle`);async function On(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await P(e,t,L(t)),o=Math.max(a.width+(t.padding??0),t?.width||0),s=Math.max(a.height+(t.padding??0),t?.height||0),c=-o/2,l=-s/2,u=i.insert(`rect`,`:first-child`);return u.attr(`class`,`text`).attr(`style`,r).attr(`rx`,0).attr(`ry`,0).attr(`x`,c).attr(`y`,l).attr(`width`,o).attr(`height`,s),I(t,u),t.intersect=function(e){return K.rect(t,e)},i}n(On,`text`);var kn=n((e,t,n,r,i,a)=>`M${e},${t} + a${i},${a} 0,0,1 0,${-r} + l${n},0 + a${i},${a} 0,0,1 0,${r} + M${n},${-r} + a${i},${a} 0,0,0 0,${r} + l${-n},0`,`createCylinderPathD`),An=n((e,t,n,r,i,a)=>[`M${e},${t}`,`M${e+n},${t}`,`a${i},${a} 0,0,0 0,${-r}`,`l${-n},0`,`a${i},${a} 0,0,0 0,${r}`,`l${n},0`].join(` `),`createOuterCylinderPathD`),jn=n((e,t,n,r,i,a)=>[`M${e+n/2},${-r/2}`,`a${i},${a} 0,0,0 0,${r}`].join(` `),`createInnerCylinderPathD`),Mn=5,Nn=10;async function Pn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?12:i/2,o=t.height??0;if(t.height&&(t.height-=a,t.heighta,`:first-child`),v=s.insert(()=>i,`:first-child`),v.attr(`class`,`basic label-container`),m&&v.attr(`style`,m)}else{let e=kn(0,0,p,u,f,d);v=s.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container`).attr(`style`,h(m)).attr(`style`,r),v.attr(`class`,`basic label-container outer-path`),m&&v.selectAll(`path`).attr(`style`,m),r&&v.selectAll(`path`).attr(`style`,r)}return v.attr(`label-offset-x`,f),v.attr(`transform`,`translate(${-p/2}, ${u/2} )`),l.attr(`transform`,`translate(${-(c.width/2)-f-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,v),t.intersect=function(e){let n=K.rect(t,e),r=n.y-(t.y??0);if(d!=0&&(Math.abs(r)<(t.height??0)/2||Math.abs(r)==(t.height??0)/2&&Math.abs(n.x-(t.x??0))>(t.width??0)/2-f)){let i=f*f*(1-r*r/(d*d));i!=0&&(i=Math.sqrt(Math.abs(i))),i=f-i,e.x-(t.x??0)>0&&(i=-i),n.x+=i}return n},s}n(Pn,`tiltedCylinder`);async function Fn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=(t.look,i),o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:-3*l/6,y:0},{x:u+3*l/6,y:0},{x:u,y:-l},{x:0,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(Fn,`trapezoid`);async function In(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.height=(t.height??0)-o*2,t.height<5&&(t.height=5),t.width=(t.width??0)-a*2,t.width<15&&(t.width=15));let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width?t?.width:c.width)+a*2,u=(t?.height?t?.height:c.height)+o*2,{cssStyles:d}=t,f=T.svg(s),p=g(t,{});t.look!==`handDrawn`&&(p.roughness=0,p.fillStyle=`solid`);let m=[{x:-l/2*.8,y:-u/2},{x:l/2*.8,y:-u/2},{x:l/2,y:-u/2*.6},{x:l/2,y:u/2},{x:-l/2,y:u/2},{x:-l/2,y:-u/2*.6}],h=R(m),v=f.path(h,p),y=s.insert(()=>v,`:first-child`);return y.attr(`class`,`basic label-container outer-path`),d&&t.look!==`handDrawn`&&y.selectChildren(`path`).attr(`style`,d),r&&t.look!==`handDrawn`&&y.selectChildren(`path`).attr(`style`,r),I(t,y),t.intersect=function(e){return K.polygon(t,m,e)},s}n(In,`trapezoidalPentagon`);var Ln=10,Rn=10;async function zn(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.padding??0,o=n.look===`neo`?a*2:a;(n.width||n.height)&&(n.width=((n?.width??0)-o)/2,n.widthC,`:first-child`).attr(`transform`,`translate(${-m/2}, ${m/2})`).attr(`class`,`outer-path`);return y&&n.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,y),i&&n.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,i),n.width=p,n.height=m,I(n,w),d.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${m/2-(c.height+(n.padding??0)/(f?2:1)-(c.y-(c.top??0)))})`),n.intersect=function(t){return e.info(`Triangle intersect`,n,v,t),K.polygon(n,v,t)},s}n(zn,`triangle`);async function Bn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,s=!0;(t.width||t.height)&&(s=!1,t.width=(t?.width??0)-a*2,t.width<10&&(t.width=10),t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10));let{shapeSvg:c,bbox:l,label:u}=await P(e,t,L(t)),d=(t?.width?t?.width:l.width)+(a??0)*2,f=(t?.height?t?.height:l.height)+(o??0)*2,p=t.look===`neo`?f/4:f/8,m=f+(s?p:-p),{cssStyles:h}=t,v=14-d,y=v>0?v/2:0,b=T.svg(c),x=g(t,{});t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let S=[{x:-d/2-y,y:m/2},...z(-d/2-y,m/2,d/2+y,m/2,p,.8),{x:d/2+y,y:-m/2},{x:-d/2-y,y:-m/2}],C=R(S),w=b.path(C,x),E=c.insert(()=>w,`:first-child`);return E.attr(`class`,`basic label-container outer-path`),h&&t.look!==`handDrawn`&&E.selectAll(`path`).attr(`style`,h),r&&t.look!==`handDrawn`&&E.selectAll(`path`).attr(`style`,r),E.attr(`transform`,`translate(0,${-p/2})`),u.attr(`transform`,`translate(${-d/2+(t.padding??0)-(l.x-(l.left??0))},${-f/2+(t.padding??0)-p-(l.y-(l.top??0))})`),I(t,E),t.intersect=function(e){return K.polygon(t,S,e)},c}n(Bn,`waveEdgedRectangle`);async function Vn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?20:i;if(t.width||t.height){t.width=t?.width??0,t.width<20&&(t.width=20),t.height=t?.height??0,t.height<10&&(t.height=10);let e=Math.min(t.height*.2,t.height/4);t.height=Math.ceil(t.height-o-20/9*e),t.width-=a*2}let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width?t?.width:c.width)+a*2,u=(t?.height?t?.height:c.height)+o,d=u/8,f=u+d*2,{cssStyles:p}=t,m=T.svg(s),h=g(t,{});t.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-l/2,y:f/2},...z(-l/2,f/2,l/2,f/2,d,1),{x:l/2,y:-f/2},...z(l/2,-f/2,-l/2,-f/2,d,-1)],y=R(v),b=m.path(y,h),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container`),p&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,p),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),I(t,x),t.intersect=function(e){return K.polygon(t,v,e)},s}n(Vn,`waveRectangle`);var Q=10;async function Hn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?12:t.padding??0;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-i*2-Q,10),t.height=Math.max((t?.height??0)-a*2-Q,10));let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=(t?.width?t?.width:s.width)+i*2+Q,u=(t?.height?t?.height:s.height)+a*2+Q,d=l-Q,f=u-Q,p=-d/2,m=-f/2,{cssStyles:h}=t,v=T.svg(o),y=g(t,{}),b=[{x:p-Q,y:m-Q},{x:p-Q,y:m+f},{x:p+d,y:m+f},{x:p+d,y:m-Q}],x=`M${p-Q},${m-Q} L${p+d},${m-Q} L${p+d},${m+f} L${p-Q},${m+f} L${p-Q},${m-Q} + M${p-Q},${m} L${p+d},${m} + M${p},${m-Q} L${p},${m+f}`;t.look!==`handDrawn`&&(y.roughness=0,y.fillStyle=`solid`);let S=v.path(x,y),C=o.insert(()=>S,`:first-child`);return C.attr(`transform`,`translate(${Q/2}, ${Q/2})`),C.attr(`class`,`basic label-container outer-path`),h&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,h),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${-(s.width/2)+Q/2-(s.x-(s.left??0))}, ${-(s.height/2)+Q/2-(s.y-(s.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,b,e)},o}n(Hn,`windowPane`);var Un=new Set([`redux-color`,`redux-dark-color`]),Wn=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]);async function Gn(e,n){let r=n;r.alias&&(n.label=r.alias);let{theme:i,themeVariables:a}=s(),{rowEven:o,rowOdd:c,nodeBorder:u,borderColorArray:d}=a;if(n.look===`handDrawn`){let{themeVariables:t}=s(),{background:r}=t;await Gn(e,{...n,id:n.id+`-background`,domId:(n.domId||n.id)+`-background`,look:`default`,cssStyles:[`stroke: none`,`fill: ${r}`]})}let f=s();n.useHtmlLabels=f.htmlLabels;let p=f.er?.diagramPadding??10,h=f.er?.entityPadding??6,{cssStyles:v}=n,{labelStyles:y,nodeStyles:b}=_(n);if(r.attributes.length===0&&n.label){let t={rx:0,ry:0,labelPaddingX:p,labelPaddingY:p*1.5,classes:``};m(n.label,f)+t.labelPaddingX*20){let e=C.width+p*2-(O+k+A+j);O+=e/P,k+=e/P,A>0&&(A+=e/P),j>0&&(j+=e/P)}let R=O+k+A+j,z=T.svg(S),B=g(n,{});n.look!==`handDrawn`&&(B.roughness=0,B.fillStyle=`solid`);let ee=0;D.length>0&&(ee=D.reduce((e,t)=>e+(t?.rowHeight??0),0));let V=Math.max(F.width+p*2,n?.width||0,R),te=Math.max((ee??0)+C.height,n?.height||0),H=-V/2,U=-te/2;if(S.selectAll(`g:not(:first-child)`).each((e,n,r)=>{let i=t(r[n]),a=i.attr(`transform`),o=0,s=0;if(a){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(a);e&&(o=parseFloat(e[1]),s=parseFloat(e[2]),i.attr(`class`).includes(`attribute-name`)?o+=O:i.attr(`class`).includes(`attribute-keys`)?o+=O+k:i.attr(`class`).includes(`attribute-comment`)&&(o+=O+k+A))}i.attr(`transform`,`translate(${H+p/2+o}, ${s+U+C.height+h/2})`)}),S.select(`.name`).attr(`transform`,`translate(`+-C.width/2+`, `+(U+h/2)+`)`),i!=null&&Un.has(i)){let e=r.colorIndex??0;S.attr(`data-color-id`,`color-${e%d.length}`)}let ne=z.rectangle(H,U,V,te,B),re=S.insert(()=>ne,`:first-child`).attr(`class`,`outer-path`).attr(`style`,v.join(``));E.push(0);for(let[e,t]of D.entries()){let n=(e+1)%2==0&&t.yOffset!==0,r=z.rectangle(H,C.height+U+t?.yOffset,V,t?.rowHeight,{...B,fill:n?o:c,stroke:u});S.insert(()=>r,`g.label`).attr(`style`,v.join(``)).attr(`class`,`row-rect-${n?`even`:`odd`}`)}let ie=1e-4,W=qn(H,C.height+U,V+H,C.height+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B);if(S.insert(()=>G).attr(`class`,`divider`),W=qn(O+H,C.height+U,O+H,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`),M){let e=O+k+H;W=qn(e,C.height+U,e,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}if(N){let e=O+k+A+H;W=qn(e,C.height+U,e,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}for(let e of E){let t=C.height+U+e;W=qn(H,t,V+H,t,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}if(I(n,re),b&&n.look!==`handDrawn`){if(i!=null&&Wn.has(i))S.selectAll(`path`).attr(`style`,b);else{let e=b.split(`;`)?.filter(e=>e.includes(`stroke`))?.map(e=>`${e}`).join(`; `);S.selectAll(`path`).attr(`style`,e??``),S.selectAll(`.row-rect-even path`).attr(`style`,b)}}return n.intersect=function(e){return K.rect(n,e)},S}n(Gn,`erBox`);async function Kn(e,n,r,i=0,o=0,s=[],c=``){let u=e.insert(`g`).attr(`class`,`label ${s.join(` `)}`).attr(`transform`,`translate(${i}, ${o})`).attr(`style`,c);n!==a(n)&&(n=a(n),n=n.replaceAll(`<`,`<`).replaceAll(`>`,`>`));let d=u.node().appendChild(await S(u,n,{width:m(n,r)+100,style:c,useHtmlLabels:r.htmlLabels},r));if(n.includes(`<`)||n.includes(`>`)){let e=d.children[0];for(e.textContent=e.textContent.replaceAll(`<`,`<`).replaceAll(`>`,`>`);e.childNodes[0];)e=e.childNodes[0],e.textContent=e.textContent.replaceAll(`<`,`<`).replaceAll(`>`,`>`)}let f=d.getBBox();if(l(r.htmlLabels)){let e=d.children[0];e.style.textAlign=`start`;let n=t(d);f=e.getBoundingClientRect(),n.attr(`width`,f.width),n.attr(`height`,f.height)}return f}n(Kn,`addText`);function qn(e,t,n,r,i){return e===n?[{x:e-i/2,y:t},{x:e+i/2,y:t},{x:n+i/2,y:r},{x:n-i/2,y:r}]:[{x:e,y:t-i/2},{x:e,y:t+i/2},{x:n,y:r+i/2},{x:n,y:r-i/2}]}n(qn,`lineToPolygon`);async function Jn(e,t,n,r,i=n.class.padding??12){let a=r?0:3,o=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId||t.id),s=null,c=null,l=null,u=null,d=0,f=0,p=0;if(s=o.insert(`g`).attr(`class`,`annotation-group text`),t.annotations.length>0){let e=t.annotations[0];await Yn(s,{text:`\xAB${e}\xBB`},0),d=s.node().getBBox().height}c=o.insert(`g`).attr(`class`,`label-group text`),await Yn(c,t,0,[`font-weight: bolder`]);let m=c.node().getBBox();f=m.height,l=o.insert(`g`).attr(`class`,`members-group text`);let h=0;for(let e of t.members){let t=await Yn(l,e,h,[e.parseClassifier()]);h+=t+a}p=l.node().getBBox().height,p<=0&&(p=i/2),u=o.insert(`g`).attr(`class`,`methods-group text`);let g=0;for(let e of t.methods){let t=await Yn(u,e,g,[e.parseClassifier()]);g+=t+a}let _=o.node().getBBox();if(s!==null){let e=s.node().getBBox();s.attr(`transform`,`translate(${-e.width/2})`)}return c.attr(`transform`,`translate(${-m.width/2}, ${d})`),_=o.node().getBBox(),l.attr(`transform`,`translate(0, ${d+f+i*2})`),_=o.node().getBBox(),u.attr(`transform`,`translate(0, ${d+f+(p?p+i*4:i*2)})`),_=o.node().getBBox(),{shapeSvg:o,bbox:_}}n(Jn,`textHelper`);async function Yn(e,n,a,o=[]){let c=e.insert(`g`).attr(`class`,`label`).attr(`style`,o.join(`; `)),u=s(),d=`useHtmlLabels`in n?n.useHtmlLabels:l(u.htmlLabels)??!0,p=``;p=`text`in n?n.text:n.label,!d&&p.startsWith(`\\`)&&(p=p.substring(1)),r(p)&&(d=!0);let h=await S(c,i(f(p)),{width:m(p,u)+50,classes:`markdown-node-label`,useHtmlLabels:d},u),g,_=1;if(d){let e=h.children[0],n=t(h);_=e.innerHTML.split(`
`).length,e.innerHTML.includes(``)&&(_+=e.innerHTML.split(``).length-1),await O(e),g=e.getBoundingClientRect(),n.attr(`width`,g.width),n.attr(`height`,g.height)}else{o.includes(`font-weight: bolder`)&&t(h).selectAll(`tspan`).attr(`font-weight`,``),_=h.children.length;let e=h.children[0];(h.textContent===``||h.textContent.includes(`>`))&&(e.textContent=p[0]+p.substring(1).replaceAll(`>`,`>`).replaceAll(`<`,`<`).trim(),p[1]===` `&&(e.textContent=e.textContent[0]+` `+e.textContent.substring(1))),e.textContent===`undefined`&&(e.textContent=``),g=h.getBBox()}return c.attr(`transform`,`translate(0,`+(-g.height/(2*_)+a)+`)`),g.height}n(Yn,`addText`);async function Xn(e,n){let r=u(),{theme:i,themeVariables:a}=r,{useGradient:o,borderColorArray:s}=a,c=r.class.padding??12,d=c,f=n.useHtmlLabels??l(r.htmlLabels)??!0,p=n;p.annotations=p.annotations??[],p.members=p.members??[],p.methods=p.methods??[];let{shapeSvg:m,bbox:h}=await Jn(e,n,r,f,d);w(m,n.colorIndex,i,s);let{labelStyles:v,nodeStyles:y}=_(n);n.labelStyle=v,n.cssStyles=p.styles||``;let b=p.styles?.join(`;`)||y||``;n.cssStyles||=b.replaceAll(`!important`,``).split(`;`);let x=p.members.length===0&&p.methods.length===0&&!r.class?.hideEmptyMembersBox,S=T.svg(m),C=g(n,{});n.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`);let E=Math.max(n.width??0,h.width),D=Math.max(n.height??0,h.height),O=(n.height??0)>h.height;p.members.length===0&&p.methods.length===0?D+=d:p.members.length>0&&p.methods.length===0&&(D+=d*2);let k=-E/2,A=-D/2,j=x?c*2:p.members.length===0&&p.methods.length===0?-c:0;O&&(j=c*2);let M=S.rectangle(k-c,A-c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0),E+2*c,D+2*c+j,C),N=m.insert(()=>M,`:first-child`);N.attr(`class`,`basic label-container outer-path`);let P=N.node().getBBox(),F=m.select(`.annotation-group`).node().getBBox().height-(x?c/2:0)||0,L=m.select(`.label-group`).node().getBBox().height-(x?c/2:0)||0,R=m.select(`.members-group`).node().getBBox().height-(x?c/2:0)||0,z=(F+L+A+c-(A-c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0)))/2;if(m.selectAll(`.text`).each((e,n,i)=>{let a=t(i[n]),o=a.attr(`transform`),s=0;if(o){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(o);e&&(s=parseFloat(e[2]))}let l=s+A+c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0);if(a.attr(`class`).includes(`methods-group`)){let e=Math.max(R,d/2);l=O?Math.max(z,F+L+e+A+d*2+c)+d*2:F+L+e+A+d*4+c}p.members.length===0&&p.methods.length===0&&r.class?.hideEmptyMembersBox&&(l=p.annotations.length>0?s-d:s),f||(l-=4);let u=k;(a.attr(`class`).includes(`label-group`)||a.attr(`class`).includes(`annotation-group`))&&(u=-a.node()?.getBBox().width/2||0,m.selectAll(`text`).each(function(e,t,n){window.getComputedStyle(n[t]).textAnchor===`middle`&&(u=0)})),a.attr(`transform`,`translate(${u}, ${l})`)}),p.members.length>0||p.methods.length>0||x){let e=F+L+A+c,t=S.line(P.x,e,P.x+P.width,e+.001,C);m.insert(()=>t).attr(`class`,`divider${n.look===`neo`&&!o?` neo-line`:``}`).attr(`style`,b)}if(x||p.members.length>0||p.methods.length>0){let e=F+L+R+A+d*2+c,t=S.line(P.x,O?Math.max(z,e):e,P.x+P.width,(O?Math.max(z,e):e)+.001,C);m.insert(()=>t).attr(`class`,`divider${n.look===`neo`&&!o?` neo-line`:``}`).attr(`style`,b)}if(p.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,b),N.select(`:nth-child(2)`).attr(`style`,b),m.selectAll(`.divider`).select(`path`).attr(`style`,b),n.labelStyle?m.selectAll(`span`).attr(`style`,n.labelStyle):m.selectAll(`span`).attr(`style`,b),!f){let e=RegExp(/color\s*:\s*([^;]*)/),t=e.exec(b);if(t){let e=t[0].replace(`color`,`fill`);m.selectAll(`tspan`).attr(`style`,e)}else if(v){let t=e.exec(v);if(t){let e=t[0].replace(`color`,`fill`);m.selectAll(`tspan`).attr(`style`,e)}}}return I(n,N),n.intersect=function(e){return K.rect(n,e)},m}n(Xn,`classBox`);async function Zn(e,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n,o=n,s=`verifyMethod`in n,c=L(n),l=u(),{themeVariables:d}=l,{borderColorArray:f,requirementEdgeLabelBackground:p}=d,m=l.layout===`elk`?`start`:`center`,h=e.insert(`g`).attr(`class`,c).attr(`id`,n.domId??n.id),v;v=s?await $(h,`<<${a.type}>>`,0,n.labelStyle):await $(h,`<<Element>>`,0,n.labelStyle);let y=v,b=await $(h,a.name,y,n.labelStyle+`; font-weight: bold;`);if(y+=b+20,s){let e=await $(h,`${a.requirementId?`ID: ${a.requirementId}`:``}`,y,n.labelStyle,m);y+=e;let t=await $(h,`${a.text?`Text: ${a.text}`:``}`,y,n.labelStyle,m);y+=t;let r=await $(h,`${a.risk?`Risk: ${a.risk}`:``}`,y,n.labelStyle,m);y+=r,await $(h,`${a.verifyMethod?`Verification: ${a.verifyMethod}`:``}`,y,n.labelStyle,m)}else{let e=await $(h,`${o.type?`Type: ${o.type}`:``}`,y,n.labelStyle,m);y+=e,await $(h,`${o.docRef?`Doc Ref: ${o.docRef}`:``}`,y,n.labelStyle,m)}let x=(h.node()?.getBBox().width??200)+20,S=(h.node()?.getBBox().height??200)+20,C=-x/2,w=-S/2,E=T.svg(h),D=g(n,{});n.look!==`handDrawn`&&(D.roughness=0,D.fillStyle=`solid`);let O=E.rectangle(C,w,x,S,D),k=h.insert(()=>O,`:first-child`);if(k.attr(`class`,`basic label-container outer-path`).attr(`style`,i),f?.length){let e=n.colorIndex??0;h.attr(`data-color-id`,`color-${e%f.length}`)}if(h.selectAll(`.label`).each((e,n,r)=>{let i=t(r[n]),a=i.attr(`transform`),o=0,s=0;if(a){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(a);e&&(o=parseFloat(e[1]),s=parseFloat(e[2]))}let c=s-S/2,l=C+10;(n===0||n===1)&&(l=o),i.attr(`transform`,`translate(${l}, ${c+20})`)}),y>v+b+20){let e=w+v+b+20,t;if(n.look===`neo`){let n=.001,r=[[C,e],[C+x,e],[C+x,e+n],[C,e+n]];t=E.polygon(r,D)}else t=E.line(C,e,C+x,e,D);h.insert(()=>t).attr(`class`,`divider`)}return I(n,k),n.intersect=function(e){return K.rect(n,e)},i&&n.look!==`handDrawn`&&(p||f?.length)&&h.selectAll(`path`).attr(`style`,i),h}n(Zn,`requirementBox`);async function $(e,n,r,a=``,o=`center`){if(n===``)return 0;let s=e.insert(`g`).attr(`class`,`label`).attr(`style`,a),c=u(),l=c.htmlLabels??!0,d=await S(s,i(f(n)),{width:m(n,c)+50,classes:`markdown-node-label`,useHtmlLabels:l,style:a},c),p;if(l){let e=d.children[0],n=t(d);o===`start`&&t(e).style(`text-align`,`left`),p=e.getBoundingClientRect(),n.attr(`width`,p.width),n.attr(`height`,p.height)}else{let e=d.children[0];for(let t of e.children)a&&t.setAttribute(`style`,a);if(o===`start`){e.setAttribute(`text-anchor`,`start`);for(let t of e.children)t.setAttribute(`text-anchor`,`start`)}p=d.getBBox(),p.height+=6}return s.attr(`transform`,`translate(${-p.width/2},${-p.height/2+r})`),p.height}n($,`addText`);var Qn=n(e=>{switch(e){case`Very High`:return`red`;case`High`:return`orange`;case`Medium`:return null;case`Low`:return`blue`;case`Very Low`:return`lightblue`}},`colorFromPriority`);async function $n(e,t,{config:n}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r||``;let a=t.width;t.width=(t.width??200)-10;let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=t.padding||10,u=``,d;`ticket`in t&&t.ticket&&n?.kanban?.ticketBaseUrl&&(u=n?.kanban?.ticketBaseUrl.replace(`#TICKET#`,t.ticket),d=o.insert(`svg:a`,`:first-child`).attr(`class`,`kanban-ticket-link`).attr(`xlink:href`,u).attr(`target`,`_blank`));let f={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||``,width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1},p,m;d?{label:p,bbox:m}=await F(d,`ticket`in t&&t.ticket||``,f):{label:p,bbox:m}=await F(o,`ticket`in t&&t.ticket||``,f);let{label:h,bbox:v}=await F(o,`assigned`in t&&t.assigned||``,f);t.width=a;let y=t?.width||0,b=Math.max(m.height,v.height)/2,x=Math.max(s.height+20,t?.height||0)+b,S=-y/2,C=-x/2;c.attr(`transform`,`translate(`+(l-y/2)+`, `+(-b-s.height/2)+`)`),p.attr(`transform`,`translate(`+(l-y/2)+`, `+(-b+s.height/2)+`)`),h.attr(`transform`,`translate(`+(l+y/2-v.width-20)+`, `+(-b+s.height/2)+`)`);let w,{rx:E,ry:D}=t,{cssStyles:O}=t;if(t.look===`handDrawn`){let e=T.svg(o),n=g(t,{}),r=E||D?e.path(q(S,C,y,x,E||0),n):e.rectangle(S,C,y,x,n);w=o.insert(()=>r,`:first-child`),w.attr(`class`,`basic label-container`).attr(`style`,O||null)}else{w=o.insert(`rect`,`:first-child`),w.attr(`class`,`basic label-container __APA__`).attr(`style`,i).attr(`rx`,E??5).attr(`ry`,D??5).attr(`x`,S).attr(`y`,C).attr(`width`,y).attr(`height`,x);let e=`priority`in t&&t.priority;if(e){let t=o.append(`line`),n=S+2,r=C+Math.floor((E??0)/2),i=C+x-Math.floor((E??0)/2);t.attr(`x1`,n).attr(`y1`,r).attr(`x2`,n).attr(`y2`,i).attr(`stroke-width`,`4`).attr(`stroke`,Qn(e))}}return I(t,w),t.height=x,t.intersect=function(e){return K.rect(t,e)},o}n($n,`kanbanItem`);async function er(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(t,n,L(n)),l=o.width+10*s,u=o.height+8*s,d=.15*l,{cssStyles:f}=n,p=o.width+20,m=o.height+20,v=Math.max(l,p),y=Math.max(u,m);c.attr(`transform`,`translate(${-o.width/2}, ${-o.height/2})`);let b,x=`M0 0 + a${d},${d} 1 0,0 ${v*.25},${-1*y*.1} + a${d},${d} 1 0,0 ${v*.25},0 + a${d},${d} 1 0,0 ${v*.25},0 + a${d},${d} 1 0,0 ${v*.25},${y*.1} + + a${d},${d} 1 0,0 ${v*.15},${y*.33} + a${d*.8},${d*.8} 1 0,0 0,${y*.34} + a${d},${d} 1 0,0 ${-1*v*.15},${y*.33} + + a${d},${d} 1 0,0 ${-1*v*.25},${y*.15} + a${d},${d} 1 0,0 ${-1*v*.25},0 + a${d},${d} 1 0,0 ${-1*v*.25},0 + a${d},${d} 1 0,0 ${-1*v*.25},${-1*y*.15} + + a${d},${d} 1 0,0 ${-1*v*.1},${-1*y*.33} + a${d*.8},${d*.8} 1 0,0 0,${-1*y*.34} + a${d},${d} 1 0,0 ${v*.1},${-1*y*.33} + H0 V0 Z`;if(n.look===`handDrawn`){let e=T.svg(a),t=g(n,{}),r=e.path(x,t);b=a.insert(()=>r,`:first-child`),b.attr(`class`,`basic label-container`).attr(`style`,h(f))}else b=a.insert(`path`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,i).attr(`d`,x);return b.attr(`transform`,`translate(${-v/2}, ${-y/2})`),I(n,b),n.calcIntersect=function(e,t){return K.rect(e,t)},n.intersect=function(t){return e.info(`Bang intersect`,n,t),K.rect(n,t)},a}n(er,`bang`);async function tr(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(t,n,L(n)),l=o.width+2*s,u=o.height+2*s,d=.15*l,f=.25*l,p=.35*l,m=.2*l,{cssStyles:v}=n,y,b=`M0 0 + a${d},${d} 0 0,1 ${l*.25},${-1*l*.1} + a${p},${p} 1 0,1 ${l*.4},${-1*l*.1} + a${f},${f} 1 0,1 ${l*.35},${l*.2} + + a${d},${d} 1 0,1 ${l*.15},${u*.35} + a${m},${m} 1 0,1 ${-1*l*.15},${u*.65} + + a${f},${d} 1 0,1 ${-1*l*.25},${l*.15} + a${p},${p} 1 0,1 ${-1*l*.5},0 + a${d},${d} 1 0,1 ${-1*l*.25},${-1*l*.15} + + a${d},${d} 1 0,1 ${-1*l*.1},${-1*u*.35} + a${m},${m} 1 0,1 ${l*.1},${-1*u*.65} + H0 V0 Z`;if(n.look===`handDrawn`){let e=T.svg(a),t=g(n,{}),r=e.path(b,t);y=a.insert(()=>r,`:first-child`),y.attr(`class`,`basic label-container`).attr(`style`,h(v))}else y=a.insert(`path`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,i).attr(`d`,b);return c.attr(`transform`,`translate(${-o.width/2}, ${-o.height/2})`),y.attr(`transform`,`translate(${-l/2}, ${-u/2})`),I(n,y),n.calcIntersect=function(e,t){return K.rect(e,t)},n.intersect=function(t){return e.info(`Cloud intersect`,n,t),K.rect(n,t)},a}n(tr,`cloud`);async function nr(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,halfPadding:o,label:s}=await P(e,t,L(t)),c=a.width+8*o,l=a.height+2*o,u=t.look===`neo`?` + M${-c/2} ${l/2-5} + v${-l+10} + q0,-5 5,-5 + h${c-10} + q5,0 5,5 + v${l-5} + H${-c/2} + Z + `:` + M${-c/2} ${l/2-5} + v${-l+10} + q0,-5 5,-5 + h${c-10} + q5,0 5,5 + v${l-10} + q0,5 -5,5 + h${-(c-10)} + q-5,0 -5,-5 + Z + `;if(!t.domId)throw Error(`defaultMindmapNode: node "${t.id}" is missing a domId \u2014 was render.ts domId prefixing skipped?`);let d=i.append(`path`).attr(`id`,t.domId).attr(`class`,`node-bkg node-`+t.type).attr(`style`,r).attr(`d`,u);return i.append(`line`).attr(`class`,`node-line-`).attr(`x1`,-c/2).attr(`y1`,l/2).attr(`x2`,c/2).attr(`y2`,l/2),s.attr(`transform`,`translate(${-a.width/2}, ${-a.height/2})`),i.append(()=>s.node()),I(t,d),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},i}n(nr,`defaultMindmapNode`);async function rr(e,t){return Ae(e,t,{padding:t.padding??0})}n(rr,`mindmapCircle`);var ir=[{semanticName:`Process`,name:`Rectangle`,shortName:`rect`,description:`Standard process shape`,aliases:[`proc`,`process`,`rectangle`],internalAliases:[`squareRect`],handler:gn},{semanticName:`Event`,name:`Rounded Rectangle`,shortName:`rounded`,description:`Represents an event`,aliases:[`event`],internalAliases:[`roundedRect`],handler:fn},{semanticName:`Terminal Point`,name:`Stadium`,shortName:`stadium`,description:`Terminal point`,aliases:[`terminal`,`pill`],handler:yn},{semanticName:`Subprocess`,name:`Framed Rectangle`,shortName:`fr-rect`,description:`Subprocess`,aliases:[`subprocess`,`subproc`,`framed-rectangle`,`subroutine`],handler:wn},{semanticName:`Database`,name:`Cylinder`,shortName:`cyl`,description:`Database storage`,aliases:[`db`,`database`,`cylinder`],handler:Ge},{semanticName:`Data Store`,name:`Data Store`,shortName:`datastore`,description:`Data flow diagram data store`,aliases:[`data-store`],handler:qe},{semanticName:`Folder`,name:`Folder`,shortName:`folder`,description:`Folder or directory`,aliases:[`directory`],handler:tt},{semanticName:`Bucket`,name:`Bucket`,shortName:`bucket`,description:`Object storage bucket`,handler:fe},{semanticName:`Console`,name:`Console (terminal window)`,shortName:`console`,description:`Terminal or console window`,handler:Me},{semanticName:`Browser`,name:`Browser`,shortName:`browser`,description:`Browser window`,handler:Ee},{semanticName:`Person`,name:`Person`,shortName:`person`,description:`Person (circular head above a rounded body)`,handler:ze},{semanticName:`Start`,name:`Circle`,shortName:`circle`,description:`Starting point`,aliases:[`circ`],handler:Ae},{semanticName:`Bang`,name:`Bang`,shortName:`bang`,description:`Bang`,aliases:[`bang`],handler:er},{semanticName:`Cloud`,name:`Cloud`,shortName:`cloud`,description:`cloud`,aliases:[`cloud`],handler:tr},{semanticName:`Decision`,name:`Diamond`,shortName:`diam`,description:`Decision-making step`,aliases:[`decision`,`diamond`,`question`],handler:ln},{semanticName:`Prepare Conditional`,name:`Hexagon`,shortName:`hex`,description:`Preparation or condition step`,aliases:[`hexagon`,`prepare`],handler:at},{semanticName:`Data Input/Output`,name:`Lean Right`,shortName:`lean-r`,description:`Represents input or output`,aliases:[`lean-right`,`in-out`],internalAliases:[`lean_right`],handler:ht},{semanticName:`Data Input/Output`,name:`Lean Left`,shortName:`lean-l`,description:`Represents output or input`,aliases:[`lean-left`,`out-in`],internalAliases:[`lean_left`],handler:mt},{semanticName:`Priority Action`,name:`Trapezoid Base Bottom`,shortName:`trap-b`,description:`Priority action`,aliases:[`priority`,`trapezoid-bottom`,`trapezoid`],handler:Fn},{semanticName:`Manual Operation`,name:`Trapezoid Base Top`,shortName:`trap-t`,description:`Represents a manual task`,aliases:[`manual`,`trapezoid-top`,`inv-trapezoid`],internalAliases:[`inv_trapezoid`],handler:ft},{semanticName:`Stop`,name:`Double Circle`,shortName:`dbl-circ`,description:`Represents a stop point`,aliases:[`double-circle`],internalAliases:[`doublecircle`],handler:Ye},{semanticName:`Text Block`,name:`Text Block`,shortName:`text`,description:`Text block`,handler:On},{semanticName:`Card`,name:`Notched Rectangle`,shortName:`notch-rect`,description:`Represents a card`,aliases:[`card`,`notched-rectangle`],handler:Oe},{semanticName:`Lined/Shaded Process`,name:`Lined Rectangle`,shortName:`lin-rect`,description:`Lined process shape`,aliases:[`lined-rectangle`,`lined-process`,`lin-proc`,`shaded-process`],handler:mn},{semanticName:`Start`,name:`Small Circle`,shortName:`sm-circ`,description:`Small starting point`,aliases:[`start`,`small-circle`],internalAliases:[`stateStart`],handler:Sn},{semanticName:`Stop`,name:`Framed Circle`,shortName:`fr-circ`,description:`Stop point`,aliases:[`stop`,`framed-circle`],internalAliases:[`stateEnd`],handler:xn},{semanticName:`Fork/Join`,name:`Filled Rectangle`,shortName:`fork`,description:`Fork or join in process flow`,aliases:[`join`],internalAliases:[`forkJoin`],handler:nt},{semanticName:`Collate`,name:`Hourglass`,shortName:`hourglass`,description:`Represents a collate operation`,aliases:[`hourglass`,`collate`],handler:ot},{semanticName:`Comment`,name:`Curly Brace`,shortName:`brace`,description:`Adds a comment`,aliases:[`comment`,`brace-l`],handler:Fe},{semanticName:`Comment Right`,name:`Curly Brace`,shortName:`brace-r`,description:`Adds a comment`,handler:Ie},{semanticName:`Comment with braces on both sides`,name:`Curly Braces`,shortName:`braces`,description:`Adds a comment`,handler:Le},{semanticName:`Com Link`,name:`Lightning Bolt`,shortName:`bolt`,description:`Communication link`,aliases:[`com-link`,`lightning-bolt`],handler:gt},{semanticName:`Document`,name:`Document`,shortName:`doc`,description:`Represents a document`,aliases:[`doc`,`document`],handler:Bn},{semanticName:`Delay`,name:`Half-Rounded Rectangle`,shortName:`delay`,description:`Represents a delay`,aliases:[`half-rounded-rectangle`],handler:rt},{semanticName:`Direct Access Storage`,name:`Horizontal Cylinder`,shortName:`h-cyl`,description:`Direct access storage`,aliases:[`das`,`horizontal-cylinder`],handler:Pn},{semanticName:`Disk Storage`,name:`Lined Cylinder`,shortName:`lin-cyl`,description:`Disk storage`,aliases:[`disk`,`lined-cylinder`],handler:St},{semanticName:`Display`,name:`Curved Trapezoid`,shortName:`curv-trap`,description:`Represents a display`,aliases:[`curved-trapezoid`,`display`],handler:Re},{semanticName:`Divided Process`,name:`Divided Rectangle`,shortName:`div-rect`,description:`Divided process shape`,aliases:[`div-proc`,`divided-rectangle`,`divided-process`],handler:Je},{semanticName:`Extract`,name:`Triangle`,shortName:`tri`,description:`Extraction process`,aliases:[`extract`,`triangle`],handler:zn},{semanticName:`Internal Storage`,name:`Window Pane`,shortName:`win-pane`,description:`Internal storage`,aliases:[`internal-storage`,`window-pane`],handler:Hn},{semanticName:`Junction`,name:`Filled Circle`,shortName:`f-circ`,description:`Junction point`,aliases:[`junction`,`filled-circle`],handler:Ze},{semanticName:`Loop Limit`,name:`Trapezoidal Pentagon`,shortName:`notch-pent`,description:`Loop limit step`,aliases:[`loop-limit`,`notched-pentagon`],handler:In},{semanticName:`Manual File`,name:`Flipped Triangle`,shortName:`flip-tri`,description:`Manual file operation`,aliases:[`manual-file`,`flipped-triangle`],handler:et},{semanticName:`Manual Input`,name:`Sloped Rectangle`,shortName:`sl-rect`,description:`Manual input step`,aliases:[`manual-input`,`sloped-rectangle`],handler:hn},{semanticName:`Multi-Document`,name:`Stacked Document`,shortName:`docs`,description:`Multiple documents`,aliases:[`documents`,`st-doc`,`stacked-document`],handler:on},{semanticName:`Multi-Process`,name:`Stacked Rectangle`,shortName:`st-rect`,description:`Multiple processes`,aliases:[`procs`,`processes`,`stacked-rectangle`],handler:an},{semanticName:`Stored Data`,name:`Bow Tie Rectangle`,shortName:`bow-rect`,description:`Stored data`,aliases:[`stored-data`,`bow-tie-rectangle`],handler:de},{semanticName:`Summary`,name:`Crossed Circle`,shortName:`cross-circ`,description:`Summary`,aliases:[`summary`,`crossed-circle`],handler:Pe},{semanticName:`Tagged Document`,name:`Tagged Document`,shortName:`tag-doc`,description:`Tagged document`,aliases:[`tag-doc`,`tagged-document`],handler:Dn},{semanticName:`Tagged Process`,name:`Tagged Rectangle`,shortName:`tag-rect`,description:`Tagged process`,aliases:[`tagged-rectangle`,`tag-proc`,`tagged-process`],handler:En},{semanticName:`Paper Tape`,name:`Flag`,shortName:`flag`,description:`Paper tape`,aliases:[`paper-tape`],handler:Vn},{semanticName:`Odd`,name:`Odd`,shortName:`odd`,description:`Odd shape`,internalAliases:[`rect_left_inv_arrow`],handler:un},{semanticName:`Lined Document`,name:`Lined Document`,shortName:`lin-doc`,description:`Lined document`,aliases:[`lined-document`],handler:Ct}],ar=n(()=>{let e=[...Object.entries({state:bn,choice:ke,note:sn,composite:je,rectWithTitle:dn,labelRect:pt,block_arrow:Te,collapsedGroup:ve,iconSquare:ut,iconCircle:ct,icon:st,iconRounded:lt,imageSquare:dt,anchor:ce,kanbanItem:$n,mindmapCircle:rr,defaultMindmapNode:nr,classBox:Xn,erBox:Gn,requirementBox:Zn,usecaseActor:Bt,usecaseActorHollow:Wt,usecaseActorAwesome:Ht,usecaseActorIcon:Yt,usecaseBusiness:Zt,usecaseEllipse:Xe,usecaseJsonTable:rn}),...ir.flatMap(e=>[e.shortName,...`aliases`in e?e.aliases:[],...`internalAliases`in e?e.internalAliases:[]].map(t=>[t,e.handler]))];return Object.fromEntries(e)},`generateShapeMap`)();function or(e){return e in ar}n(or,`isValidShape`);export{or as a,I as c,V as i,q as n,P as o,K as r,ar as s,se as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-7M6MHVWA-ZnPgs1Wx.js b/frontend/dist/assets/chunk-7M6MHVWA-ZnPgs1Wx.js new file mode 100644 index 0000000..d5b5886 --- /dev/null +++ b/frontend/dist/assets/chunk-7M6MHVWA-ZnPgs1Wx.js @@ -0,0 +1,213 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as r,H as i,U as a,a as o,d as s,ot as c,q as l,s as u,tt as d,v as f,w as p,x as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as g}from"./channel-_oCHZhRo.js";import{c as _,g as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as ee,n as te,o as ne,r as y}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{a as b}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{_ as x,n as S,t as C,v as w}from"./index-DoQkmpth.js";import{t as T}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as E}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as D}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as O}from"./chunk-WEXAMYUT-I3m-hOmT.js";var re=`flowchart-`,ie=class{constructor(){this.vertexCounter=0,this.config=m(),this.diagramId=``,this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=a,this.setAccDescription=i,this.setDiagramTitle=l,this.getAccTitle=h,this.getAccDescription=f,this.getDiagramTitle=p,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen(`gen-2`)}static{n(this,`FlowDB`)}sanitizeText(e){return u.sanitizeText(e,this.config)}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}setDiagramId(e){this.diagramId=e}lookUpDomId(e){for(let t of this.vertices.values())if(t.id===e)return this.diagramId?`${this.diagramId}-${t.domId}`:t.domId;return this.diagramId?`${this.diagramId}-${e}`:e}addVertex(t,n,r,i,a,o,s={},c){if(!t||t.trim().length===0)return;let l;if(c!==void 0){let e;e=c.includes(` +`)?c+` +`:`{ +`+c+` +}`,l=w(e,{schema:x})}let u=this.subGraphLookup.get(t);if(u&&l){u.metadata={...u.metadata,...l};return}let d=this.edges.find(e=>e.id===t);if(d){let e=l;e?.animate!==void 0&&(d.animate=e.animate),e?.animation!==void 0&&(d.animation=e.animation),e?.curve!==void 0&&(d.interpolate=e.curve);return}let f,p=this.vertices.get(t);if(p===void 0&&(n===void 0&&r===void 0&&i!=null&&e.warn(`Style applied to unknown node "${t}". This may indicate a typo. The node will be created automatically.`),p={id:t,labelType:`text`,domId:re+t+`-`+this.vertexCounter,styles:[],classes:[]},this.vertices.set(t,p)),this.vertexCounter++,n===void 0?p.text===void 0&&(p.text=t):(this.config=m(),f=this.sanitizeText(n.text.trim()),p.labelType=n.type,f.startsWith(`"`)&&f.endsWith(`"`)&&(f=f.substring(1,f.length-1)),p.text=f),r!==void 0&&(p.type=r),i?.forEach(e=>{p.styles.push(e)}),a?.forEach(e=>{p.classes.push(e)}),o!==void 0&&(p.dir=o),p.props===void 0?p.props=s:s!==void 0&&Object.assign(p.props,s),l!==void 0){if(l.shape){if(l.shape!==l.shape.toLowerCase()||l.shape.includes(`_`))throw Error(`No such shape: ${l.shape}. Shape names should be lowercase.`);if(!b(l.shape))throw Error(`No such shape: ${l.shape}.`);p.type=l?.shape}l?.label&&(p.text=l?.label,p.labelType=this.sanitizeNodeLabelType(l?.labelType)),l?.icon&&(p.icon=l?.icon,!l.label?.trim()&&p.text===t&&(p.text=``)),l?.form&&(p.form=l?.form),l?.pos&&(p.pos=l?.pos),l?.img&&(p.img=l?.img,!l.label?.trim()&&p.text===t&&(p.text=``)),l?.constraint&&(p.constraint=l.constraint),l.w&&(p.assetWidth=Number(l.w)),l.h&&(p.assetHeight=Number(l.h))}}addSingleLink(t,n,r,i){let a={start:t,end:n,type:void 0,text:``,labelType:`text`,classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};e.info(`abc78 Got edge...`,a);let o=r.text;if(o!==void 0&&(a.text=this.sanitizeText(o.text.trim()),a.text.startsWith(`"`)&&a.text.endsWith(`"`)&&(a.text=a.text.substring(1,a.text.length-1)),a.labelType=this.sanitizeNodeLabelType(o.type)),r!==void 0&&(a.type=r.type,a.stroke=r.stroke,a.length=r.length>10?10:r.length),i&&!this.edges.some(e=>e.id===i))a.id=i,a.isUserDefinedId=!0;else{let e=this.edges.filter(e=>e.start===a.start&&e.end===a.end);a.id=e.length===0?_(a.start,a.end,{counter:0,prefix:`L`}):_(a.start,a.end,{counter:e.length+1,prefix:`L`})}if(this.edges.length<(this.config.maxEdges??500))e.info(`Pushing edge...`),this.edges.push(a);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}. + +Initialize mermaid with maxEdges set to a higher number to allow more edges. +You cannot set this config via configuration inside the diagram as it is a secure config. +You have to call mermaid.initialize.`)}isLinkData(e){return typeof e==`object`&&!!e&&`id`in e&&typeof e.id==`string`}addLink(t,n,r){let i=this.isLinkData(r)?r.id.replace(`@`,``):void 0;e.info(`addLink`,t,n,i);for(let e of t)for(let a of n){let o=e===t[t.length-1],s=a===n[0];o&&s?this.addSingleLink(e,a,r,i):this.addSingleLink(e,a,r,void 0)}}updateLinkInterpolate(e,t){e.forEach(e=>{e==="default"?this.edges.defaultInterpolate=t:this.edges[e].interpolate=t})}updateLink(e,t){e.forEach(e=>{if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);e==="default"?this.edges.defaultStyle=t:(this.edges[e].style=t,(this.edges[e]?.style?.length??0)>0&&!this.edges[e]?.style?.some(e=>e?.startsWith(`fill`))&&this.edges[e]?.style?.push(`fill:none`))})}addClass(e,t){let n=t.join().replace(/\\,/g,`§§§`).replace(/,/g,`;`).replace(/§§§/g,`,`).split(`;`);e.split(`,`).forEach(e=>{let t=this.classes.get(e);t===void 0&&(t={id:e,styles:[],textStyles:[]},this.classes.set(e,t)),n?.forEach(e=>{if(/color/.exec(e)){let n=e.replace(`fill`,`bgFill`);t.textStyles.push(n)}t.styles.push(e)})})}setDirection(e){this.direction=e.trim(),/.*/.exec(this.direction)&&(this.direction=`LR`),/.*v/.exec(this.direction)&&(this.direction=`TB`),this.direction===`TD`&&(this.direction=`TB`)}setClass(e,t){for(let n of e.split(`,`)){let e=this.vertices.get(n);e&&e.classes.push(t);let r=this.edges.find(e=>e.id===n);r&&r.classes.push(t);let i=this.subGraphLookup.get(n);i&&i.classes.push(t)}}setTooltip(e,t){if(t!==void 0){t=this.sanitizeText(t);for(let n of e.split(`,`))this.tooltips.set(this.version===`gen-1`?this.lookUpDomId(n):n,t)}}setClickFun(e,t,n){if(m().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{let n=this.lookUpDomId(e),i=document.querySelector(`[id="${n}"]`);i!==null&&i.addEventListener(`click`,()=>{v.runFunc(t,...r)},!1)}))}setLink(e,t,n){e.split(`,`).forEach(e=>{let r=this.vertices.get(e);r!==void 0&&(r.link=v.formatUrl(t,this.config),r.linkTarget=n)}),this.setClass(e,`clickable`)}getTooltip(e){return this.tooltips.get(e)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFun(e,t,n)}),this.setClass(e,`clickable`)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}getClasses(){return this.classes}setupToolTips(e){let n=E();t(e).select(`svg`).selectAll(`g.node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.text(r.attr(`title`)).style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(d.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}clear(e=`gen-2`){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.diagramId=``,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=e,this.config=m(),o()}setGen(e){this.version=e||`gen-2`}defaultStyle(){return`fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;`}addSubGraph(t,r,i){let a=t.text.trim(),o=i.text;t===i&&/\s/.exec(i.text)&&(a=void 0);let s=n(e=>{let t={boolean:{},number:{},string:{}},n=[],r;return{nodeList:e.filter(function(e){let i=typeof e;return e.stmt&&e.stmt===`dir`?(r=e.value,!1):e.trim()===``?!1:i in t?t[i].hasOwnProperty(e)?!1:t[i][e]=!0:!n.includes(e)&&n.push(e)}),dir:r}},`uniq`)(r.flat()),c=s.nodeList,l=s.dir,u=m().flowchart??{};if(l??=u.inheritDir?this.getDirection()??m().direction??void 0:void 0,this.version===`gen-1`)for(let e=0;e2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=t,this.subGraphs[t].id===e)return{result:!0,count:0};let r=0,i=1;for(;r=0){let n=this.indexNodes2(e,t);if(n.result)return{result:!0,count:i+n.count};i+=n.count}r+=1}return{result:!1,count:i}}getDepthFirstPos(e){return this.posCrossRef[e]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2(`none`,this.subGraphs.length-1)}getSubGraphs(){return this.subGraphs}firstGraph(){return this.firstGraphFlag?(this.firstGraphFlag=!1,!0):!1}destructStartLink(e){let t=e.trim(),n=`arrow_open`;switch(t[0]){case`<`:n=`arrow_point`,t=t.slice(1);break;case`x`:n=`arrow_cross`,t=t.slice(1);break;case`o`:n=`arrow_circle`,t=t.slice(1)}let r=`normal`;return t.includes(`=`)&&(r=`thick`),t.includes(`.`)&&(r=`dotted`),{type:n,stroke:r}}countChar(e,t){let n=t.length,r=0;for(let i=0;i`:r=`arrow_point`,t.startsWith(`<`)&&(r=`double_`+r,n=n.slice(1));break;case`o`:r=`arrow_circle`,t.startsWith(`o`)&&(r=`double_`+r,n=n.slice(1))}let i=`normal`,a=n.length-1;n.startsWith(`=`)&&(i=`thick`),n.startsWith(`~`)&&(i=`invisible`);let o=this.countChar(`.`,n);return o&&(i=`dotted`,a=o),{type:r,stroke:i,length:a}}destructLink(e,t){let n=this.destructEndLink(e),r;if(t){if(r=this.destructStartLink(t),r.stroke!==n.stroke)return{type:`INVALID`,stroke:`INVALID`};if(r.type===`arrow_open`)r.type=n.type;else{if(r.type!==n.type)return{type:`INVALID`,stroke:`INVALID`};r.type=`double_`+r.type}return r.type===`double_arrow`&&(r.type=`double_arrow_point`),r.length=n.length,r}return n}exists(e,t){for(let n of e)if(n.nodes.includes(t))return!0;return!1}makeUniq(e,t){let n=[];return e.nodes.forEach((r,i)=>{this.exists(t,r)||n.push(e.nodes[i])}),{nodes:n}}getTypeFromVertex(e){if(e.img)return`imageSquare`;if(e.icon)return e.form===`circle`?`iconCircle`:e.form===`square`?`iconSquare`:e.form===`rounded`?`iconRounded`:`icon`;switch(e.type){case`square`:case void 0:return`squareRect`;case`round`:return`roundedRect`;case`ellipse`:return`ellipse`;default:return e.type}}findNode(e,t){return e.find(e=>e.id===t)}destructEdgeType(e){let t=`none`,n=`arrow_point`;switch(e){case`arrow_point`:case`arrow_circle`:case`arrow_cross`:n=e;break;case`double_arrow_point`:case`double_arrow_circle`:case`double_arrow_cross`:t=e.replace(`double_`,``),n=t}return{arrowTypeStart:t,arrowTypeEnd:n}}addNodeFromVertex(e,t,n,r,i,a){let o=n.get(e.id),s=r.get(e.id)??!1,c=this.findNode(t,e.id);if(c)c.cssStyles=e.styles,c.cssCompiledStyles=this.getCompiledStyles(e.classes),c.cssClasses=e.classes.join(` `);else{let n={id:e.id,label:e.text,labelType:e.labelType,labelStyle:``,parentId:o,padding:i.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:this.getCompiledStyles([`default`,`node`,...e.classes]),cssClasses:`default `+e.classes.join(` `),dir:e.dir,domId:e.domId,look:a,link:e.link,linkTarget:e.linkTarget,tooltip:this.getTooltip(e.id),icon:e.icon,pos:e.pos,img:e.img,assetWidth:e.assetWidth,assetHeight:e.assetHeight,constraint:e.constraint};s?t.push({...n,isGroup:!0,shape:`rect`}):t.push({...n,isGroup:!1,shape:this.getTypeFromVertex(e),minWidth:i.flowchart?.minNodeWidth})}}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}getData(){let e=m(),t=[],r=[],i=this.getSubGraphs(),a=new Map,o=new Map,s=new Map;for(let e of i)for(let t of e.nodes)this.subGraphLookup.has(t)&&s.set(t,e.id);let c=new Map,l=new Map;for(let e of i){let t=s.get(e.id);t!==void 0&&l.set(t,[...l.get(t)??[],e.id])}let u=0,d=n(e=>{c.set(e,u++);for(let t of l.get(e)??[])d(t)},`walk`);for(let e of i)s.has(e.id)||d(e.id);let f=n(e=>this.subGraphLookup.get(e)?.metadata?.view===`collapsed`,`isCollapsed`),p=n(e=>{let t,n=new Set,r=e;for(;r!==void 0&&!n.has(r);)n.add(r),f(r)&&(t=r),r=s.get(r);return t},`outermostCollapsed`),h=new Set,g=new Map;for(let e of i){let t=p(e.id);if(t!==void 0){e.id!==t&&(h.add(e.id),g.set(e.id,t));for(let n of e.nodes)n!==t&&(h.add(n),g.set(n,t))}}for(let e=i.length-1;e>=0;e--){let t=i[e];if(!h.has(t.id)){t.nodes.length>0&&o.set(t.id,!0);for(let e of t.nodes)a.set(e,t.id)}}for(let n=i.length-1;n>=0;n--){let r=i[n];h.has(r.id)||(r.metadata?.view===`collapsed`?t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`collapsedGroup`,dir:r.dir,isGroup:!1,look:e.look,colorIndex:c.get(r.id)}):t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`rect`,dir:r.dir,isGroup:!0,look:e.look,colorIndex:c.get(r.id),metadata:r.metadata}))}this.getVertices().forEach(n=>{h.has(n.id)||this.addNodeFromVertex(n,t,a,o,e,e.look||`classic`)});let v=this.getEdges();return v.forEach((t,n)=>{let{arrowTypeStart:i,arrowTypeEnd:a}=this.destructEdgeType(t.type),o=[...v.defaultStyle??[]],s=g.get(t.start)??t.start,c=g.get(t.end)??t.end;if(s===c&&(g.has(t.start)||g.has(t.end)))return;t.style&&o.push(...t.style);let l={id:_(s,c,{counter:n,prefix:`L`},t.id),isUserDefinedId:t.isUserDefinedId,start:s,end:c,type:t.type??`normal`,label:t.text,labelType:t.labelType,labelpos:`c`,thickness:t.stroke,minlen:t.length,classes:t?.stroke===`invisible`?``:`edge-thickness-normal edge-pattern-solid flowchart-link`,arrowTypeStart:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:i,arrowTypeEnd:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:a,arrowheadStyle:`fill: #333`,cssCompiledStyles:this.getCompiledStyles(t.classes),labelStyle:o,style:o,pattern:t.stroke,look:e.look,animate:t.animate,animation:t.animation,curve:t.interpolate||this.edges.defaultInterpolate||e.flowchart?.curve};r.push(l)}),{nodes:t,edges:r,other:{},config:e}}defaultConfig(){return s.flowchart}},ae={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing state diagram (v2)`,n);let{securityLevel:a,flowchart:o,layout:s}=m();i.db.setDiagramId(n),e.debug(`Before getData: `);let c=i.db.getData();e.debug(`Data: `,c);let l=D(n,a),u=i.db.getDirection();c.type=i.type,c.layoutAlgorithm=C(s),c.direction=u,c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=[`point`,`circle`,`cross`],c.diagramId=n,e.debug(`REF1:`,c),await S(c,l);let d=c.config.flowchart?.diagramPadding??8;v.insertTitle(l,`flowchartTitleText`,o?.titleTopMargin||0,i.db.getDiagramTitle()),O(l,d,`flowchart`,o?.useMaxWidth||!1)},`draw`)},oe=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,4],r=[1,3],i=[1,5],a=[1,8,9,10,11,27,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],o=[2,2],s=[1,13],c=[1,14],l=[1,15],u=[1,16],d=[1,23],f=[1,25],p=[1,26],m=[1,27],h=[1,50],g=[1,49],_=[1,29],v=[1,30],ee=[1,31],te=[1,32],ne=[1,33],y=[1,45],b=[1,47],x=[1,43],S=[1,48],C=[1,44],w=[1,51],T=[1,46],E=[1,52],D=[1,53],O=[1,34],re=[1,35],ie=[1,36],ae=[1,37],oe=[1,38],k=[1,58],A=[1,8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],j=[1,62],M=[1,61],N=[1,63],se=[8,9,11,75,77,78],ce=[1,79],le=[1,92],ue=[1,97],de=[1,96],fe=[1,93],pe=[1,89],me=[1,95],he=[1,91],ge=[1,98],_e=[1,94],ve=[1,99],ye=[1,90],be=[8,9,10,11,40,75,77,78],P=[8,9,10,11,40,46,75,77,78],F=[8,9,10,11,29,40,44,46,48,50,52,54,56,58,60,63,65,67,68,70,75,77,78,89,102,105,106,109,111,114,115,116],xe=[8,9,11,44,60,75,77,78,89,102,105,106,109,111,114,115,116],Se=[44,60,89,102,105,106,109,111,114,115,116],Ce=[1,122],we=[1,123],Te=[1,125],Ee=[1,124],De=[44,60,62,74,89,102,105,106,109,111,114,115,116],Oe=[1,134],ke=[1,148],Ae=[1,149],je=[1,150],Me=[1,151],Ne=[1,136],Pe=[1,138],Fe=[1,142],Ie=[1,143],Le=[1,144],Re=[1,145],ze=[1,146],Be=[1,147],Ve=[1,152],He=[1,153],Ue=[1,132],We=[1,133],Ge=[1,140],Ke=[1,135],qe=[1,139],Je=[1,137],Ye=[8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],Xe=[1,155],Ze=[1,157],I=[8,9,11],L=[8,9,10,11,14,44,60,89,105,106,109,111,114,115,116],R=[1,177],z=[1,173],B=[1,174],V=[1,178],H=[1,175],U=[1,176],Qe=[77,116,119],W=[8,9,10,11,12,14,27,29,32,44,60,75,84,85,86,87,88,89,90,105,109,111,114,115,116],$e=[10,106],et=[31,49,51,53,55,57,62,64,66,67,69,71,116,117,118],G=[1,248],K=[1,246],q=[1,250],J=[1,244],Y=[1,245],X=[1,247],Z=[1,249],Q=[1,251],tt=[1,269],nt=[8,9,11,106],$=[8,9,10,11,60,84,105,106,109,110,111,112],rt={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeparator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,vertexStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,shapeData:39,SHAPE_DATA:40,link:41,node:42,styledVertex:43,AMP:44,vertex:45,STYLE_SEPARATOR:46,idString:47,DOUBLECIRCLESTART:48,DOUBLECIRCLEEND:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,VERTEX_WITH_PROPS_START:58,"NODE_STRING[field]":59,COLON:60,"NODE_STRING[value]":61,PIPE:62,CYLINDERSTART:63,CYLINDEREND:64,DIAMOND_START:65,DIAMOND_STOP:66,TAGEND:67,TRAPSTART:68,TRAPEND:69,INVTRAPSTART:70,INVTRAPEND:71,linkStatement:72,arrowText:73,TESTSTR:74,START_LINK:75,edgeText:76,LINK:77,LINK_ID:78,edgeTextToken:79,STR:80,MD_STR:81,textToken:82,keywords:83,STYLE:84,LINKSTYLE:85,CLASSDEF:86,CLASS:87,CLICK:88,DOWN:89,UP:90,textNoTagsToken:91,stylesOpt:92,"idString[vertex]":93,"idString[class]":94,CALLBACKNAME:95,CALLBACKARGS:96,HREF:97,LINK_TARGET:98,"STR[link]":99,"STR[tooltip]":100,alphaNum:101,DEFAULT:102,numList:103,INTERPOLATE:104,NUM:105,COMMA:106,style:107,styleComponent:108,NODE_STRING:109,UNIT:110,BRKT:111,PCT:112,idStringToken:113,MINUS:114,MULT:115,UNICODE_TEXT:116,TEXT:117,TAGSTART:118,EDGE_TEXT:119,alphaNumToken:120,direction_tb:121,direction_bt:122,direction_rl:123,direction_lr:124,direction_td:125,$accept:0,$end:1},terminals_:{2:`error`,8:`SEMI`,9:`NEWLINE`,10:`SPACE`,11:`EOF`,12:`GRAPH`,13:`NODIR`,14:`DIR`,27:`subgraph`,29:`SQS`,31:`SQE`,32:`end`,34:`acc_title`,35:`acc_title_value`,36:`acc_descr`,37:`acc_descr_value`,38:`acc_descr_multiline_value`,40:`SHAPE_DATA`,44:`AMP`,46:`STYLE_SEPARATOR`,48:`DOUBLECIRCLESTART`,49:`DOUBLECIRCLEEND`,50:`PS`,51:`PE`,52:`(-`,53:`-)`,54:`STADIUMSTART`,55:`STADIUMEND`,56:`SUBROUTINESTART`,57:`SUBROUTINEEND`,58:`VERTEX_WITH_PROPS_START`,59:`NODE_STRING[field]`,60:`COLON`,61:`NODE_STRING[value]`,62:`PIPE`,63:`CYLINDERSTART`,64:`CYLINDEREND`,65:`DIAMOND_START`,66:`DIAMOND_STOP`,67:`TAGEND`,68:`TRAPSTART`,69:`TRAPEND`,70:`INVTRAPSTART`,71:`INVTRAPEND`,74:`TESTSTR`,75:`START_LINK`,77:`LINK`,78:`LINK_ID`,80:`STR`,81:`MD_STR`,84:`STYLE`,85:`LINKSTYLE`,86:`CLASSDEF`,87:`CLASS`,88:`CLICK`,89:`DOWN`,90:`UP`,93:`idString[vertex]`,94:`idString[class]`,95:`CALLBACKNAME`,96:`CALLBACKARGS`,97:`HREF`,98:`LINK_TARGET`,99:`STR[link]`,100:`STR[tooltip]`,102:`DEFAULT`,104:`INTERPOLATE`,105:`NUM`,106:`COMMA`,109:`NODE_STRING`,110:`UNIT`,111:`BRKT`,112:`PCT`,114:`MINUS`,115:`MULT`,116:`UNICODE_TEXT`,117:`TEXT`,118:`TAGSTART`,119:`EDGE_TEXT`,121:`direction_tb`,122:`direction_bt`,123:`direction_rl`,124:`direction_lr`,125:`direction_td`},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[39,2],[39,1],[20,4],[20,3],[20,4],[20,2],[20,2],[20,1],[42,1],[42,6],[42,5],[43,1],[43,3],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,8],[45,4],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,4],[45,4],[45,1],[41,2],[41,3],[41,3],[41,1],[41,3],[41,4],[76,1],[76,2],[76,1],[76,1],[72,1],[72,2],[73,3],[30,1],[30,2],[30,1],[30,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[103,1],[103,3],[92,1],[92,3],[107,1],[107,2],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[82,1],[82,1],[82,1],[82,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[79,1],[79,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[47,1],[47,2],[101,1],[101,2],[33,1],[33,1],[33,1],[33,1],[33,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:(!Array.isArray(a[s])||a[s].length>0)&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 183:this.$=a[s];break;case 11:r.setDirection(`TB`),this.$=`TB`;break;case 12:r.setDirection(a[s-1]),this.$=a[s-1];break;case 27:this.$=a[s-1].nodes;break;case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 33:this.$=r.addSubGraph(a[s-6],a[s-1],a[s-4]);break;case 34:this.$=r.addSubGraph(a[s-3],a[s-1],a[s-3]);break;case 35:this.$=r.addSubGraph(void 0,a[s-1],void 0);break;case 37:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 38:case 39:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 43:this.$=a[s-1]+a[s];break;case 44:this.$=a[s];break;case 45:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s]),r.addLink(a[s-3].stmt,a[s-1],a[s-2]),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 46:r.addLink(a[s-2].stmt,a[s],a[s-1]),this.$={stmt:a[s],nodes:a[s].concat(a[s-2].nodes)};break;case 47:r.addLink(a[s-3].stmt,a[s-1],a[s-2]),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 48:this.$={stmt:a[s-1],nodes:a[s-1]};break;case 49:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s]),this.$={stmt:a[s-1],nodes:a[s-1],shapeData:a[s]};break;case 50:this.$={stmt:a[s],nodes:a[s]};break;case 51:this.$=[a[s]];break;case 52:r.addVertex(a[s-5][a[s-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s-4]),this.$=a[s-5].concat(a[s]);break;case 53:this.$=a[s-4].concat(a[s]);break;case 54:this.$=a[s];break;case 55:this.$=a[s-2],r.setClass(a[s-2],a[s]);break;case 56:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`square`);break;case 57:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`doublecircle`);break;case 58:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`circle`);break;case 59:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`ellipse`);break;case 60:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`stadium`);break;case 61:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`subroutine`);break;case 62:this.$=a[s-7],r.addVertex(a[s-7],a[s-1],`rect`,void 0,void 0,void 0,Object.fromEntries([[a[s-5],a[s-3]]]));break;case 63:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`cylinder`);break;case 64:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`round`);break;case 65:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`diamond`);break;case 66:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`hexagon`);break;case 67:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`odd`);break;case 68:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`trapezoid`);break;case 69:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`inv_trapezoid`);break;case 70:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_right`);break;case 71:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_left`);break;case 72:this.$=a[s],r.addVertex(a[s]);break;case 73:a[s-1].text=a[s],this.$=a[s-1];break;case 74:case 75:a[s-2].text=a[s-1],this.$=a[s-2];break;case 76:this.$=a[s];break;case 77:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,text:a[s-1]};break;case 78:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,text:a[s-1],id:a[s-3]};break;case 79:this.$={text:a[s],type:`text`};break;case 80:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 81:this.$={text:a[s],type:`string`};break;case 82:this.$={text:a[s],type:`markdown`};break;case 83:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length};break;case 84:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,id:a[s-1]};break;case 85:this.$=a[s-1];break;case 86:this.$={text:a[s],type:`text`};break;case 87:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 88:this.$={text:a[s],type:`string`};break;case 89:case 104:this.$={text:a[s],type:`markdown`};break;case 101:this.$={text:a[s],type:`text`};break;case 102:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 103:this.$={text:a[s],type:`text`};break;case 105:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 106:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 107:case 115:this.$=a[s-1],r.setClickEvent(a[s-1],a[s]);break;case 108:case 116:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 109:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 110:this.$=a[s-4],r.setClickEvent(a[s-4],a[s-3],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 111:this.$=a[s-2],r.setLink(a[s-2],a[s]);break;case 112:this.$=a[s-4],r.setLink(a[s-4],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 113:this.$=a[s-4],r.setLink(a[s-4],a[s-2],a[s]);break;case 114:this.$=a[s-6],r.setLink(a[s-6],a[s-4],a[s]),r.setTooltip(a[s-6],a[s-2]);break;case 117:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 118:this.$=a[s-3],r.setLink(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 119:this.$=a[s-3],r.setLink(a[s-3],a[s-2],a[s]);break;case 120:this.$=a[s-5],r.setLink(a[s-5],a[s-4],a[s]),r.setTooltip(a[s-5],a[s-2]);break;case 121:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 122:this.$=a[s-4],r.updateLink([a[s-2]],a[s]);break;case 123:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 124:this.$=a[s-8],r.updateLinkInterpolate([a[s-6]],a[s-2]),r.updateLink([a[s-6]],a[s]);break;case 125:this.$=a[s-8],r.updateLinkInterpolate(a[s-6],a[s-2]),r.updateLink(a[s-6],a[s]);break;case 126:this.$=a[s-6],r.updateLinkInterpolate([a[s-4]],a[s]);break;case 127:this.$=a[s-6],r.updateLinkInterpolate(a[s-4],a[s]);break;case 128:case 130:this.$=[a[s]];break;case 129:case 131:a[s-2].push(a[s]),this.$=a[s-2];break;case 133:this.$=a[s-1]+a[s];break;case 181:this.$=a[s];break;case 182:this.$=a[s-1]+``+a[s];break;case 184:this.$=a[s-1]+``+a[s];break;case 185:this.$={stmt:`dir`,value:`TB`};break;case 186:this.$={stmt:`dir`,value:`BT`};break;case 187:this.$={stmt:`dir`,value:`RL`};break;case 188:this.$={stmt:`dir`,value:`LR`};break;case 189:this.$={stmt:`dir`,value:`TD`}}},`anonymous`),table:[{3:1,4:2,9:t,10:r,12:i},{1:[3]},e(a,o,{5:6}),{4:7,9:t,10:r,12:i},{4:8,9:t,10:r,12:i},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},e(a,[2,9]),e(a,[2,10]),e(a,[2,11]),{8:[1,55],9:[1,56],10:k,15:54,18:57},e(A,[2,3]),e(A,[2,4]),e(A,[2,5]),e(A,[2,6]),e(A,[2,7]),e(A,[2,8]),{8:j,9:M,11:N,21:59,41:60,72:64,75:[1,65],77:[1,67],78:[1,66]},{8:j,9:M,11:N,21:68},{8:j,9:M,11:N,21:69},{8:j,9:M,11:N,21:70},{8:j,9:M,11:N,21:71},{8:j,9:M,11:N,21:72},{8:j,9:M,10:[1,73],11:N,21:74},e(A,[2,36]),{35:[1,75]},{37:[1,76]},e(A,[2,39]),e(se,[2,50],{18:77,39:78,10:k,40:ce}),{10:[1,80]},{10:[1,81]},{10:[1,82]},{10:[1,83]},{14:le,44:ue,60:de,80:[1,87],89:fe,95:[1,84],97:[1,85],101:86,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},e(A,[2,185]),e(A,[2,186]),e(A,[2,187]),e(A,[2,188]),e(A,[2,189]),e(be,[2,51]),e(be,[2,54],{46:[1,100]}),e(P,[2,72],{113:113,29:[1,101],44:h,48:[1,102],50:[1,103],52:[1,104],54:[1,105],56:[1,106],58:[1,107],60:g,63:[1,108],65:[1,109],67:[1,110],68:[1,111],70:[1,112],89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),e(F,[2,181]),e(F,[2,142]),e(F,[2,143]),e(F,[2,144]),e(F,[2,145]),e(F,[2,146]),e(F,[2,147]),e(F,[2,148]),e(F,[2,149]),e(F,[2,150]),e(F,[2,151]),e(F,[2,152]),e(a,[2,12]),e(a,[2,18]),e(a,[2,19]),{9:[1,114]},e(xe,[2,26],{18:115,10:k}),e(A,[2,27]),{42:116,43:39,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(A,[2,40]),e(A,[2,41]),e(A,[2,42]),e(Se,[2,76],{73:117,62:[1,119],74:[1,118]}),{76:120,79:121,80:Ce,81:we,116:Te,119:Ee},{75:[1,126],77:[1,127]},e(De,[2,83]),e(A,[2,28]),e(A,[2,29]),e(A,[2,30]),e(A,[2,31]),e(A,[2,32]),{10:Oe,12:ke,14:Ae,27:je,28:128,32:Me,44:Ne,60:Pe,75:Fe,80:[1,130],81:[1,131],83:141,84:Ie,85:Le,86:Re,87:ze,88:Be,89:Ve,90:He,91:129,105:Ue,109:We,111:Ge,114:Ke,115:qe,116:Je},e(Ye,o,{5:154}),e(A,[2,37]),e(A,[2,38]),e(se,[2,48],{44:Xe}),e(se,[2,49],{18:156,10:k,40:Ze}),e(be,[2,44]),{44:h,47:158,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{102:[1,159],103:160,105:[1,161]},{44:h,47:162,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{44:h,47:163,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,107],{10:[1,164],96:[1,165]}),{80:[1,166]},e(I,[2,115],{120:168,10:[1,167],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,117],{10:[1,169]}),e(L,[2,183]),e(L,[2,170]),e(L,[2,171]),e(L,[2,172]),e(L,[2,173]),e(L,[2,174]),e(L,[2,175]),e(L,[2,176]),e(L,[2,177]),e(L,[2,178]),e(L,[2,179]),e(L,[2,180]),{44:h,47:170,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{30:171,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:179,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:181,50:[1,180],67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:182,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:183,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:184,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{109:[1,185]},{30:186,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:187,65:[1,188],67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:189,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:190,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:191,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(F,[2,182]),e(a,[2,20]),e(xe,[2,25]),e(se,[2,46],{39:192,18:193,10:k,40:ce}),e(Se,[2,73],{10:[1,194]}),{10:[1,195]},{30:196,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{77:[1,197],79:198,116:Te,119:Ee},e(Qe,[2,79]),e(Qe,[2,81]),e(Qe,[2,82]),e(Qe,[2,168]),e(Qe,[2,169]),{76:199,79:121,80:Ce,81:we,116:Te,119:Ee},e(De,[2,84]),{8:j,9:M,10:Oe,11:N,12:ke,14:Ae,21:201,27:je,29:[1,200],32:Me,44:Ne,60:Pe,75:Fe,83:141,84:Ie,85:Le,86:Re,87:ze,88:Be,89:Ve,90:He,91:202,105:Ue,109:We,111:Ge,114:Ke,115:qe,116:Je},e(W,[2,101]),e(W,[2,103]),e(W,[2,104]),e(W,[2,157]),e(W,[2,158]),e(W,[2,159]),e(W,[2,160]),e(W,[2,161]),e(W,[2,162]),e(W,[2,163]),e(W,[2,164]),e(W,[2,165]),e(W,[2,166]),e(W,[2,167]),e(W,[2,90]),e(W,[2,91]),e(W,[2,92]),e(W,[2,93]),e(W,[2,94]),e(W,[2,95]),e(W,[2,96]),e(W,[2,97]),e(W,[2,98]),e(W,[2,99]),e(W,[2,100]),{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,203],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},{10:k,18:204},{44:[1,205]},e(be,[2,43]),{10:[1,206],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{10:[1,207]},{10:[1,208],106:[1,209]},e($e,[2,128]),{10:[1,210],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{10:[1,211],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{80:[1,212]},e(I,[2,109],{10:[1,213]}),e(I,[2,111],{10:[1,214]}),{80:[1,215]},e(L,[2,184]),{80:[1,216],98:[1,217]},e(be,[2,55],{113:113,44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),{31:[1,218],67:R,82:219,116:V,117:H,118:U},e(et,[2,86]),e(et,[2,88]),e(et,[2,89]),e(et,[2,153]),e(et,[2,154]),e(et,[2,155]),e(et,[2,156]),{49:[1,220],67:R,82:219,116:V,117:H,118:U},{30:221,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{51:[1,222],67:R,82:219,116:V,117:H,118:U},{53:[1,223],67:R,82:219,116:V,117:H,118:U},{55:[1,224],67:R,82:219,116:V,117:H,118:U},{57:[1,225],67:R,82:219,116:V,117:H,118:U},{60:[1,226]},{64:[1,227],67:R,82:219,116:V,117:H,118:U},{66:[1,228],67:R,82:219,116:V,117:H,118:U},{30:229,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{31:[1,230],67:R,82:219,116:V,117:H,118:U},{67:R,69:[1,231],71:[1,232],82:219,116:V,117:H,118:U},{67:R,69:[1,234],71:[1,233],82:219,116:V,117:H,118:U},e(se,[2,45],{18:156,10:k,40:Ze}),e(se,[2,47],{44:Xe}),e(Se,[2,75]),e(Se,[2,74]),{62:[1,235],67:R,82:219,116:V,117:H,118:U},e(Se,[2,77]),e(Qe,[2,80]),{77:[1,236],79:198,116:Te,119:Ee},{30:237,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(Ye,o,{5:238}),e(W,[2,102]),e(A,[2,35]),{43:239,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{10:k,18:240},{10:G,60:K,84:q,92:241,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:252,104:[1,253],105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:254,104:[1,255],105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{105:[1,256]},{10:G,60:K,84:q,92:257,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{44:h,47:258,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,108]),{80:[1,259]},{80:[1,260],98:[1,261]},e(I,[2,116]),e(I,[2,118],{10:[1,262]}),e(I,[2,119]),e(P,[2,56]),e(et,[2,87]),e(P,[2,57]),{51:[1,263],67:R,82:219,116:V,117:H,118:U},e(P,[2,64]),e(P,[2,59]),e(P,[2,60]),e(P,[2,61]),{109:[1,264]},e(P,[2,63]),e(P,[2,65]),{66:[1,265],67:R,82:219,116:V,117:H,118:U},e(P,[2,67]),e(P,[2,68]),e(P,[2,70]),e(P,[2,69]),e(P,[2,71]),e([10,44,60,89,102,105,106,109,111,114,115,116],[2,85]),e(Se,[2,78]),{31:[1,266],67:R,82:219,116:V,117:H,118:U},{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,267],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},e(be,[2,53]),{43:268,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,121],{106:tt}),e(nt,[2,130],{108:270,10:G,60:K,84:q,105:J,109:Y,110:X,111:Z,112:Q}),e($,[2,132]),e($,[2,134]),e($,[2,135]),e($,[2,136]),e($,[2,137]),e($,[2,138]),e($,[2,139]),e($,[2,140]),e($,[2,141]),e(I,[2,122],{106:tt}),{10:[1,271]},e(I,[2,123],{106:tt}),{10:[1,272]},e($e,[2,129]),e(I,[2,105],{106:tt}),e(I,[2,106],{113:113,44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),e(I,[2,110]),e(I,[2,112],{10:[1,273]}),e(I,[2,113]),{98:[1,274]},{51:[1,275]},{62:[1,276]},{66:[1,277]},{8:j,9:M,11:N,21:278},e(A,[2,34]),e(be,[2,52]),{10:G,60:K,84:q,105:J,107:279,108:243,109:Y,110:X,111:Z,112:Q},e($,[2,133]),{14:le,44:ue,60:de,89:fe,101:280,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},{14:le,44:ue,60:de,89:fe,101:281,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},{98:[1,282]},e(I,[2,120]),e(P,[2,58]),{30:283,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(P,[2,66]),e(Ye,o,{5:284}),e(nt,[2,131],{108:270,10:G,60:K,84:q,105:J,109:Y,110:X,111:Z,112:Q}),e(I,[2,126],{120:168,10:[1,285],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,127],{120:168,10:[1,286],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,114]),{31:[1,287],67:R,82:219,116:V,117:H,118:U},{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,288],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},{10:G,60:K,84:q,92:289,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:290,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},e(P,[2,62]),e(A,[2,33]),e(I,[2,124],{106:tt}),e(I,[2,125],{106:tt})],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var ee=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function te(e){r.length-=2*e,a.length-=e,o.length-=e}n(te,`popStack`);function ne(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(ne,`lex`);for(var y,b,x,S,C,w={},T,E,D,O;;){if(x=r[r.length-1],this.defaultActions[x]?S=this.defaultActions[x]:(y??=ne(),S=s[x]&&s[x][y]),S===void 0||!S.length||!S[0]){var re=``;for(T in O=[],s[x])this.terminals_[T]&&T>f&&O.push(`'`+this.terminals_[T]+`'`);re=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+O.join(`, `)+`, got '`+(this.terminals_[y]||y)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(y==p?`end of input`:`'`+(this.terminals_[y]||y)+`'`),this.parseError(re,{text:h.match,token:this.terminals_[y]||y,line:h.yylineno,loc:v,expected:O})}if(S[0]instanceof Array&&S.length>1)throw Error(`Parse Error: multiple actions possible at state: `+x+`, token: `+y);switch(S[0]){case 1:r.push(y),a.push(h.yytext),o.push(h.yylloc),r.push(S[1]),y=null,b?(y=b,b=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(E=this.productions_[S[1]][1],w.$=a[a.length-E],w._$={first_line:o[o.length-(E||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(E||1)].first_column,last_column:o[o.length-1].last_column},ee&&(w._$.range=[o[o.length-(E||1)].range[0],o[o.length-1].range[1]]),C=this.performAction.apply(w,[c,u,l,g.yy,S[1],a,o].concat(m)),C!==void 0)return C;E&&(r=r.slice(0,-1*E*2),a=a.slice(0,-1*E),o=o.slice(0,-1*E)),r.push(this.productions_[S[1]][0]),a.push(w.$),o.push(w._$),D=s[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0},`parse`)};rt.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),34;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),36;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return this.pushState(`shapeData`),t.yytext=``,40;case 8:return this.pushState(`shapeDataStr`),40;case 9:return this.popState(),40;case 10:return t.yytext=t.yytext.replace(/\n\s*/g,`
`),40;case 11:return 40;case 12:this.popState();break;case 13:this.begin(`callbackname`);break;case 14:this.popState();break;case 15:this.popState(),this.begin(`callbackargs`);break;case 16:return 95;case 17:this.popState();break;case 18:return 96;case 19:return`MD_STR`;case 20:this.popState();break;case 21:this.begin(`md_string`);break;case 22:return`STR`;case 23:this.popState();break;case 24:this.pushState(`string`);break;case 25:return 84;case 26:return 102;case 27:return 85;case 28:return 104;case 29:return 86;case 30:return 87;case 31:return 97;case 32:this.begin(`click`);break;case 33:this.popState();break;case 34:return 88;case 35:return e.lex.firstGraph()&&this.begin(`dir`),12;case 36:return e.lex.firstGraph()&&this.begin(`dir`),12;case 37:return e.lex.firstGraph()&&this.begin(`dir`),12;case 38:return e.lex.firstGraph()&&this.begin(`dir`),12;case 39:return 27;case 40:return 32;case 41:return 98;case 42:return 98;case 43:return 98;case 44:return 98;case 45:return this.popState(),13;case 46:return this.popState(),14;case 47:return this.popState(),14;case 48:return this.popState(),14;case 49:return this.popState(),14;case 50:return this.popState(),14;case 51:return this.popState(),14;case 52:return this.popState(),14;case 53:return this.popState(),14;case 54:return this.popState(),14;case 55:return this.popState(),14;case 56:return 121;case 57:return 122;case 58:return 123;case 59:return 124;case 60:return 125;case 61:return 78;case 62:return 105;case 63:return 111;case 64:return 46;case 65:return 60;case 66:return 44;case 67:return 8;case 68:return 106;case 69:return 115;case 70:return this.popState(),77;case 71:return this.pushState(`edgeText`),75;case 72:return 119;case 73:return this.popState(),77;case 74:return this.pushState(`thickEdgeText`),75;case 75:return 119;case 76:return this.popState(),77;case 77:return this.pushState(`dottedEdgeText`),75;case 78:return 119;case 79:return 77;case 80:return this.popState(),53;case 81:return`TEXT`;case 82:return this.pushState(`ellipseText`),52;case 83:return this.popState(),55;case 84:return this.pushState(`text`),54;case 85:return this.popState(),57;case 86:return this.pushState(`text`),56;case 87:return 58;case 88:return this.pushState(`text`),67;case 89:return this.popState(),64;case 90:return this.pushState(`text`),63;case 91:return this.popState(),49;case 92:return this.pushState(`text`),48;case 93:return this.popState(),69;case 94:return this.popState(),71;case 95:return 117;case 96:return this.pushState(`trapText`),68;case 97:return this.pushState(`trapText`),70;case 98:return 118;case 99:return 67;case 100:return 90;case 101:return`SEP`;case 102:return 89;case 103:return 115;case 104:return 111;case 105:return 44;case 106:return 109;case 107:return 114;case 108:return 116;case 109:return this.popState(),62;case 110:return this.pushState(`text`),62;case 111:return this.popState(),51;case 112:return this.pushState(`text`),50;case 113:return this.popState(),31;case 114:return this.pushState(`text`),29;case 115:return this.popState(),66;case 116:return this.pushState(`text`),65;case 117:return`TEXT`;case 118:return`QUOTE`;case 119:return 9;case 120:return 10;case 121:return 11}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:swimlane-beta\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:[^\S\n\r]+)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},shapeData:{rules:[8,11,12,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},callbackargs:{rules:[17,18,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},callbackname:{rules:[14,15,16,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},href:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},click:{rules:[21,24,33,34,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},dottedEdgeText:{rules:[21,24,76,78,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},thickEdgeText:{rules:[21,24,73,75,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},edgeText:{rules:[21,24,70,72,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},trapText:{rules:[21,24,79,82,84,86,90,92,93,94,95,96,97,110,112,114,116],inclusive:!1},ellipseText:{rules:[21,24,79,80,81,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},text:{rules:[21,24,79,82,83,84,85,86,89,90,91,92,96,97,109,110,111,112,113,114,115,116,117],inclusive:!1},vertex:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},dir:{rules:[21,24,45,46,47,48,49,50,51,52,53,54,55,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_descr:{rules:[3,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_title:{rules:[1,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},md_string:{rules:[19,20,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},string:{rules:[21,22,23,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,44,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,73,74,76,77,79,82,84,86,87,88,90,92,96,97,98,99,100,101,102,103,104,105,106,107,108,110,112,114,116,118,119,120,121],inclusive:!0}}}})();function it(){this.yy={}}return n(it,`Parser`),it.prototype=rt,rt.Parser=it,new it})();oe.parser=oe;var k=oe,A=Object.assign({},k);A.parse=e=>{let t=e.replace(/}\s*\n/g,`} +`);return k.parse(t)};var j=A,M=n(e=>{let{theme:t,bkgColorArray:r,borderColorArray:i}=e;if(!ee(t,i))return``;let a=ne(e.look),o=y(r),s=``;for(let t=0;t`${l}.node ${e}, ${l}.rough-node ${e}`,`collapsedRule`),d=n(e=>`${l}.swimlane.cluster .swimlane-title${e}, ${l}.swimlane.cluster .swimlane-body${e}`,`laneRule`);s+=` + + ${l}.cluster:not(.swimlane) rect { + stroke: ${e}; + ${c} + } + + ${l}.cluster:not(.swimlane) path { + stroke: ${e}; + ${c} + } + + /* Lane, classic and neo. */ + ${l}.swimlane.cluster rect.swimlane-title, + ${l}.swimlane.cluster rect.swimlane-body { + stroke: ${e}; + ${c} + } + + /* Lane, handDrawn: roughjs emits the hachure fill first, then the outline. */ + ${d(` path:nth-of-type(2)`)} { + stroke: ${e}; + } +${o?` + /* A roughjs fill is drawn as lines, so the lane fill is a stroke here. */ + ${d(` path:first-of-type`)} { + stroke: ${r[t%r.length]}; + } +`:``} + ${u(`.collapsed-group`)}, + ${u(`.collapsed-group path`)} { + stroke: ${e}; + ${c} + } + + /* The ellipsis dots and the separator take clusterBorder further down, so without + these the container is palette-coloured while its own markers are not. */ + ${u(`.collapsed-indicator`)} { + fill: ${e}; + } + + ${u(`.collapsed-separator`)} { + stroke: ${e}; + } + `}return s},`genColor`),N=n((e,t)=>{let n=g,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return c(r,i,a,t)},`fade`),se=n(e=>`${M(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}px; + } + .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label { + text-anchor: middle; + } + + .node .katex path { + fill: #000; + stroke: #000; + stroke-width: 1px; + } + + .rough-node .label,.node .label, .image-shape .label, .icon-shape .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + + .root .anchor path { + fill: ${e.lineColor} !important; + stroke-width: 0; + stroke: ${e.lineColor}; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth??2}px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${N(e.edgeLabelBackground,.5)}; + // background-color: + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + /* Collapsed subgraph node (@{ view: collapsed }) */ + .node .collapsed-indicator { + fill: ${e.clusterBorder}; + stroke: none; + opacity: 0.6; + } + + .node .collapsed-separator { + stroke: ${e.clusterBorder}; + stroke-width: 0.75px; + } + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .flowchartTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + + rect.text { + fill: none; + stroke-width: 0; + } + + .icon-shape, .image-shape { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + padding: 2px; + } + .label rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + ${T()} +`,`getStyles`),ce=n(({styles:e=se}={})=>({parser:j,get db(){return new ie},renderer:ae,styles:e,init:n(e=>{e.flowchart||={},e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,r({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}})},`init`)}),`createFlowDiagram`),le=ce();export{le as n,se as r,ce as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-7PRAP22T-DSs4vaIy.js b/frontend/dist/assets/chunk-7PRAP22T-DSs4vaIy.js new file mode 100644 index 0000000..9f10977 --- /dev/null +++ b/frontend/dist/assets/chunk-7PRAP22T-DSs4vaIy.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{x as t}from"./chunk-O7XYJQB3-Bce2lzyF.js";var n=e(e=>{let{handDrawnSeed:n}=t();return{fill:e,hachureAngle:120,hachureGap:1.5,fillWeight:1.5,roughness:.7,stroke:e,seed:n}},`solidStateFill`),r=e(e=>Array.isArray(e)?e:e?e.split(`;`).map(e=>e.trim()).filter(Boolean):[],`normalizeStyleList`),i=e(e=>{let t=a([...e.cssCompiledStyles||[],...e.cssStyles||[],...r(e.labelStyle)]);return{stylesMap:t,stylesArray:[...t]}},`compileStyles`),a=e(e=>{let t=new Map;return e.forEach(e=>{let[n,r]=e.split(`:`);t.set(n.trim(),r?.trim())}),t},`styles2Map`),o=e(e=>e===`color`||e===`font-size`||e===`font-family`||e===`font-weight`||e===`font-style`||e===`text-decoration`||e===`text-align`||e===`text-transform`||e===`line-height`||e===`letter-spacing`||e===`word-spacing`||e===`text-shadow`||e===`text-overflow`||e===`white-space`||e===`word-wrap`||e===`word-break`||e===`overflow-wrap`||e===`hyphens`,`isLabelStyle`),s=e(e=>{let{stylesArray:t}=i(e),n=[],r=[],a=[],s=[];return t.forEach(e=>{let t=e[0];o(t)?n.push(e.join(`:`)+` !important`):(r.push(e.join(`:`)+` !important`),t.includes(`stroke`)&&a.push(e.join(`:`)+` !important`),t===`fill`&&s.push(e.join(`:`)+` !important`))}),{labelStyles:n.join(`;`),nodeStyles:r.join(`;`),stylesArray:t,borderStyles:a,backgroundStyles:s}},`styles2String`),c=e((e,n)=>{let{themeVariables:r,handDrawnSeed:a}=t(),{nodeBorder:o,mainBkg:s}=r,{stylesMap:c}=i(e);return Object.assign({roughness:.7,fill:c.get(`fill`)||s,fillStyle:`hachure`,fillWeight:1.5,hachureGap:1.5,stroke:c.get(`stroke`)||o,seed:a,strokeWidth:c.get(`stroke-width`)?.replace(`px`,``)||1.3,fillLineDash:[0,0],strokeLineDash:l(c.get(`stroke-dasharray`))},n)},`userNodeOverrides`),l=e(e=>{if(!e)return[0,0];let t=e.trim().split(/\s+/).map(Number);if(t.length===1){let e=isNaN(t[0])?0:t[0];return[e,e]}return[isNaN(t[0])?0:t[0],isNaN(t[1])?0:t[1]]},`getStrokeDashArray`);export{c as a,s as i,o as n,n as r,i as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-FOHPRMQF-DHwB1DNv.js b/frontend/dist/assets/chunk-FOHPRMQF-DHwB1DNv.js new file mode 100644 index 0000000..370929b --- /dev/null +++ b/frontend/dist/assets/chunk-FOHPRMQF-DHwB1DNv.js @@ -0,0 +1,161 @@ +var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,n)=>t(e,`name`,{value:n,configurable:!0}),s=(e,t)=>function(){return e&&(t=(0,e[r(e)[0]])(e=0)),t},c=(e,t)=>function(){return t||(0,e[r(e)[0]])((t={exports:{}}).exports,t),t.exports},l=(e,n)=>{for(var r in n)t(e,r,{get:n[r],enumerable:!0})},u=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(let c of r(i))!a.call(e,c)&&c!==o&&t(e,c,{get:()=>i[c],enumerable:!(s=n(i,c))||s.enumerable});return e},d=(e,t,n)=>(u(e,t,`default`),n&&u(n,t,`default`)),f=(n,r,a)=>(a=n==null?{}:e(i(n)),u(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),p=e=>u(t({},`__esModule`,{value:!0}),e),m={};l(m,{AnnotatedTextEdit:()=>T,ChangeAnnotation:()=>de,ChangeAnnotationIdentifier:()=>w,CodeAction:()=>We,CodeActionContext:()=>Ue,CodeActionKind:()=>Ve,CodeActionTriggerKind:()=>He,CodeDescription:()=>se,CodeLens:()=>Ge,Color:()=>S,ColorInformation:()=>te,ColorPresentation:()=>ne,Command:()=>le,CompletionItem:()=>Oe,CompletionItemKind:()=>Se,CompletionItemLabelDetails:()=>De,CompletionItemTag:()=>we,CompletionList:()=>ke,CreateFile:()=>D,DeleteFile:()=>fe,Diagnostic:()=>ce,DiagnosticRelatedInformation:()=>ie,DiagnosticSeverity:()=>ae,DiagnosticTag:()=>oe,DocumentHighlight:()=>Fe,DocumentHighlightKind:()=>Pe,DocumentLink:()=>qe,DocumentSymbol:()=>Be,DocumentUri:()=>h,EOL:()=>ft,FoldingRange:()=>re,FoldingRangeKind:()=>C,FormattingOptions:()=>Ke,Hover:()=>je,InlayHint:()=>it,InlayHintKind:()=>nt,InlayHintLabelPart:()=>rt,InlineCompletionContext:()=>ut,InlineCompletionItem:()=>ot,InlineCompletionList:()=>st,InlineCompletionTriggerKind:()=>ct,InlineValueContext:()=>tt,InlineValueEvaluatableExpression:()=>et,InlineValueText:()=>Qe,InlineValueVariableLookup:()=>$e,InsertReplaceEdit:()=>Te,InsertTextFormat:()=>Ce,InsertTextMode:()=>Ee,Location:()=>x,LocationLink:()=>ee,MarkedString:()=>Ae,MarkupContent:()=>xe,MarkupKind:()=>be,OptionalVersionedTextDocumentIdentifier:()=>ve,ParameterInformation:()=>Me,Position:()=>y,Range:()=>b,RenameFile:()=>O,SelectedCompletionInfo:()=>lt,SelectionRange:()=>Je,SemanticTokenModifiers:()=>Xe,SemanticTokenTypes:()=>Ye,SemanticTokens:()=>Ze,SignatureInformation:()=>Ne,StringValue:()=>at,SymbolInformation:()=>Re,SymbolKind:()=>Ie,SymbolTag:()=>Le,TextDocument:()=>pt,TextDocumentEdit:()=>E,TextDocumentIdentifier:()=>ge,TextDocumentItem:()=>ye,TextEdit:()=>ue,URI:()=>g,VersionedTextDocumentIdentifier:()=>_e,WorkspaceChange:()=>he,WorkspaceEdit:()=>k,WorkspaceFolder:()=>dt,WorkspaceSymbol:()=>ze,integer:()=>_,uinteger:()=>v});var h,g,_,v,y,b,x,ee,S,te,ne,C,re,ie,ae,oe,se,ce,le,ue,de,w,T,E,D,O,fe,k,pe,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le,Re,ze,Be,Ve,He,Ue,We,Ge,Ke,qe,Je,Ye,Xe,Ze,Qe,$e,et,tt,nt,rt,it,at,ot,st,ct,lt,ut,dt,ft,pt,mt,A,ht=s({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(h||={}),(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(g||={}),(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(_||={}),(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(v||={}),(function(e){function t(e,t){return e===Number.MAX_VALUE&&(e=v.MAX_VALUE),t===Number.MAX_VALUE&&(t=v.MAX_VALUE),{line:e,character:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.uinteger(t.line)&&A.uinteger(t.character)}o(n,`is`),e.is=n})(y||={}),(function(e){function t(e,t,n,r){if(A.uinteger(e)&&A.uinteger(t)&&A.uinteger(n)&&A.uinteger(r))return{start:y.create(e,t),end:y.create(n,r)};if(y.is(e)&&y.is(t))return{start:e,end:t};throw Error(`Range#create called with invalid arguments[${e}, ${t}, ${n}, ${r}]`)}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&y.is(t.start)&&y.is(t.end)}o(n,`is`),e.is=n})(b||={}),(function(e){function t(e,t){return{uri:e,range:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.range)&&(A.string(t.uri)||A.undefined(t.uri))}o(n,`is`),e.is=n})(x||={}),(function(e){function t(e,t,n,r){return{targetUri:e,targetRange:t,targetSelectionRange:n,originSelectionRange:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.targetRange)&&A.string(t.targetUri)&&b.is(t.targetSelectionRange)&&(b.is(t.originSelectionRange)||A.undefined(t.originSelectionRange))}o(n,`is`),e.is=n})(ee||={}),(function(e){function t(e,t,n,r){return{red:e,green:t,blue:n,alpha:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.numberRange(t.red,0,1)&&A.numberRange(t.green,0,1)&&A.numberRange(t.blue,0,1)&&A.numberRange(t.alpha,0,1)}o(n,`is`),e.is=n})(S||={}),(function(e){function t(e,t){return{range:e,color:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.range)&&S.is(t.color)}o(n,`is`),e.is=n})(te||={}),(function(e){function t(e,t,n){return{label:e,textEdit:t,additionalTextEdits:n}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.string(t.label)&&(A.undefined(t.textEdit)||ue.is(t))&&(A.undefined(t.additionalTextEdits)||A.typedArray(t.additionalTextEdits,ue.is))}o(n,`is`),e.is=n})(ne||={}),(function(e){e.Comment=`comment`,e.Imports=`imports`,e.Region=`region`})(C||={}),(function(e){function t(e,t,n,r,i,a){let o={startLine:e,endLine:t};return A.defined(n)&&(o.startCharacter=n),A.defined(r)&&(o.endCharacter=r),A.defined(i)&&(o.kind=i),A.defined(a)&&(o.collapsedText=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.uinteger(t.startLine)&&A.uinteger(t.startLine)&&(A.undefined(t.startCharacter)||A.uinteger(t.startCharacter))&&(A.undefined(t.endCharacter)||A.uinteger(t.endCharacter))&&(A.undefined(t.kind)||A.string(t.kind))}o(n,`is`),e.is=n})(re||={}),(function(e){function t(e,t){return{location:e,message:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&x.is(t.location)&&A.string(t.message)}o(n,`is`),e.is=n})(ie||={}),(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(ae||={}),(function(e){e.Unnecessary=1,e.Deprecated=2})(oe||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&A.string(t.href)}o(t,`is`),e.is=t})(se||={}),(function(e){function t(e,t,n,r,i,a){let o={range:e,message:t};return A.defined(n)&&(o.severity=n),A.defined(r)&&(o.code=r),A.defined(i)&&(o.source=i),A.defined(a)&&(o.relatedInformation=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&A.string(t.message)&&(A.number(t.severity)||A.undefined(t.severity))&&(A.integer(t.code)||A.string(t.code)||A.undefined(t.code))&&(A.undefined(t.codeDescription)||A.string(t.codeDescription?.href))&&(A.string(t.source)||A.undefined(t.source))&&(A.undefined(t.relatedInformation)||A.typedArray(t.relatedInformation,ie.is))}o(n,`is`),e.is=n})(ce||={}),(function(e){function t(e,t,...n){let r={title:e,command:t};return A.defined(n)&&n.length>0&&(r.arguments=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.title)&&A.string(t.command)}o(n,`is`),e.is=n})(le||={}),(function(e){function t(e,t){return{range:e,newText:t}}o(t,`replace`),e.replace=t;function n(e,t){return{range:{start:e,end:e},newText:t}}o(n,`insert`),e.insert=n;function r(e){return{range:e,newText:``}}o(r,`del`),e.del=r;function i(e){let t=e;return A.objectLiteral(t)&&A.string(t.newText)&&b.is(t.range)}o(i,`is`),e.is=i})(ue||={}),(function(e){function t(e,t,n){let r={label:e};return t!==void 0&&(r.needsConfirmation=t),n!==void 0&&(r.description=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.string(t.label)&&(A.boolean(t.needsConfirmation)||t.needsConfirmation===void 0)&&(A.string(t.description)||t.description===void 0)}o(n,`is`),e.is=n})(de||={}),(function(e){function t(e){let t=e;return A.string(t)}o(t,`is`),e.is=t})(w||={}),(function(e){function t(e,t,n){return{range:e,newText:t,annotationId:n}}o(t,`replace`),e.replace=t;function n(e,t,n){return{range:{start:e,end:e},newText:t,annotationId:n}}o(n,`insert`),e.insert=n;function r(e,t){return{range:e,newText:``,annotationId:t}}o(r,`del`),e.del=r;function i(e){let t=e;return ue.is(t)&&(de.is(t.annotationId)||w.is(t.annotationId))}o(i,`is`),e.is=i})(T||={}),(function(e){function t(e,t){return{textDocument:e,edits:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&ve.is(t.textDocument)&&Array.isArray(t.edits)}o(n,`is`),e.is=n})(E||={}),(function(e){function t(e,t,n){let r={kind:`create`,uri:e};return t!==void 0&&(t.overwrite!==void 0||t.ignoreIfExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`create`&&A.string(t.uri)&&(t.options===void 0||(t.options.overwrite===void 0||A.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||A.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(D||={}),(function(e){function t(e,t,n,r){let i={kind:`rename`,oldUri:e,newUri:t};return n!==void 0&&(n.overwrite!==void 0||n.ignoreIfExists!==void 0)&&(i.options=n),r!==void 0&&(i.annotationId=r),i}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`rename`&&A.string(t.oldUri)&&A.string(t.newUri)&&(t.options===void 0||(t.options.overwrite===void 0||A.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||A.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(O||={}),(function(e){function t(e,t,n){let r={kind:`delete`,uri:e};return t!==void 0&&(t.recursive!==void 0||t.ignoreIfNotExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`delete`&&A.string(t.uri)&&(t.options===void 0||(t.options.recursive===void 0||A.boolean(t.options.recursive))&&(t.options.ignoreIfNotExists===void 0||A.boolean(t.options.ignoreIfNotExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(fe||={}),(function(e){function t(e){let t=e;return t&&(t.changes!==void 0||t.documentChanges!==void 0)&&(t.documentChanges===void 0||t.documentChanges.every(e=>A.string(e.kind)?D.is(e)||O.is(e)||fe.is(e):E.is(e)))}o(t,`is`),e.is=t})(k||={}),pe=class{static{o(this,`TextEditChangeImpl`)}constructor(e,t){this.edits=e,this.changeAnnotations=t}insert(e,t,n){let r,i;if(n===void 0?r=ue.insert(e,t):w.is(n)?(i=n,r=T.insert(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.insert(e,t,i)),this.edits.push(r),i!==void 0)return i}replace(e,t,n){let r,i;if(n===void 0?r=ue.replace(e,t):w.is(n)?(i=n,r=T.replace(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.replace(e,t,i)),this.edits.push(r),i!==void 0)return i}delete(e,t){let n,r;if(t===void 0?n=ue.del(e):w.is(t)?(r=t,n=T.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(t),n=T.del(e,r)),this.edits.push(n),r!==void 0)return r}add(e){this.edits.push(e)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(e){if(e===void 0)throw Error(`Text edit change is not configured to manage change annotations.`)}},me=class{static{o(this,`ChangeAnnotations`)}constructor(e){this._annotations=e===void 0?Object.create(null):e,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(e,t){let n;if(w.is(e)?n=e:(n=this.nextId(),t=e),this._annotations[n]!==void 0)throw Error(`Id ${n} is already in use.`);if(t===void 0)throw Error(`No annotation provided for id ${n}`);return this._annotations[n]=t,this._size++,n}nextId(){return this._counter++,this._counter.toString()}},he=class{static{o(this,`WorkspaceChange`)}constructor(e){this._textEditChanges=Object.create(null),e===void 0?this._workspaceEdit={}:(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new me(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach(e=>{if(E.is(e)){let t=new pe(e.edits,this._changeAnnotations);this._textEditChanges[e.textDocument.uri]=t}})):e.changes&&Object.keys(e.changes).forEach(t=>{let n=new pe(e.changes[t]);this._textEditChanges[t]=n}))}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(e){if(ve.is(e)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let t={uri:e.uri,version:e.version},n=this._textEditChanges[t.uri];if(!n){let e=[],r={textDocument:t,edits:e};this._workspaceEdit.documentChanges.push(r),n=new pe(e,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw Error(`Workspace edit is not configured for normal text edit changes.`);let t=this._textEditChanges[e];if(!t){let n=[];this._workspaceEdit.changes[e]=n,t=new pe(n),this._textEditChanges[e]=t}return t}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new me,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=D.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=D.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}renameFile(e,t,n,r){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let i;de.is(n)||w.is(n)?i=n:r=n;let a,o;if(i===void 0?a=O.create(e,t,r):(o=w.is(i)?i:this._changeAnnotations.manage(i),a=O.create(e,t,r,o)),this._workspaceEdit.documentChanges.push(a),o!==void 0)return o}deleteFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=fe.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=fe.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}},(function(e){function t(e){return{uri:e}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)}o(n,`is`),e.is=n})(ge||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&A.integer(t.version)}o(n,`is`),e.is=n})(_e||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&(t.version===null||A.integer(t.version))}o(n,`is`),e.is=n})(ve||={}),(function(e){function t(e,t,n,r){return{uri:e,languageId:t,version:n,text:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&A.string(t.languageId)&&A.integer(t.version)&&A.string(t.text)}o(n,`is`),e.is=n})(ye||={}),(function(e){e.PlainText=`plaintext`,e.Markdown=`markdown`;function t(t){let n=t;return n===e.PlainText||n===e.Markdown}o(t,`is`),e.is=t})(be||={}),(function(e){function t(e){let t=e;return A.objectLiteral(e)&&be.is(t.kind)&&A.string(t.value)}o(t,`is`),e.is=t})(xe||={}),(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(Se||={}),(function(e){e.PlainText=1,e.Snippet=2})(Ce||={}),(function(e){e.Deprecated=1})(we||={}),(function(e){function t(e,t,n){return{newText:e,insert:t,replace:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.newText)&&b.is(t.insert)&&b.is(t.replace)}o(n,`is`),e.is=n})(Te||={}),(function(e){e.asIs=1,e.adjustIndentation=2})(Ee||={}),(function(e){function t(e){let t=e;return t&&(A.string(t.detail)||t.detail===void 0)&&(A.string(t.description)||t.description===void 0)}o(t,`is`),e.is=t})(De||={}),(function(e){function t(e){return{label:e}}o(t,`create`),e.create=t})(Oe||={}),(function(e){function t(e,t){return{items:e||[],isIncomplete:!!t}}o(t,`create`),e.create=t})(ke||={}),(function(e){function t(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,`\\$&`)}o(t,`fromPlainText`),e.fromPlainText=t;function n(e){let t=e;return A.string(t)||A.objectLiteral(t)&&A.string(t.language)&&A.string(t.value)}o(n,`is`),e.is=n})(Ae||={}),(function(e){function t(e){let t=e;return!!t&&A.objectLiteral(t)&&(xe.is(t.contents)||Ae.is(t.contents)||A.typedArray(t.contents,Ae.is))&&(e.range===void 0||b.is(e.range))}o(t,`is`),e.is=t})(je||={}),(function(e){function t(e,t){return t?{label:e,documentation:t}:{label:e}}o(t,`create`),e.create=t})(Me||={}),(function(e){function t(e,t,...n){let r={label:e};return A.defined(t)&&(r.documentation=t),r.parameters=A.defined(n)?n:[],r}o(t,`create`),e.create=t})(Ne||={}),(function(e){e.Text=1,e.Read=2,e.Write=3})(Pe||={}),(function(e){function t(e,t){let n={range:e};return A.number(t)&&(n.kind=t),n}o(t,`create`),e.create=t})(Fe||={}),(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(Ie||={}),(function(e){e.Deprecated=1})(Le||={}),(function(e){function t(e,t,n,r,i){let a={name:e,kind:t,location:{uri:r,range:n}};return i&&(a.containerName=i),a}o(t,`create`),e.create=t})(Re||={}),(function(e){function t(e,t,n,r){return r===void 0?{name:e,kind:t,location:{uri:n}}:{name:e,kind:t,location:{uri:n,range:r}}}o(t,`create`),e.create=t})(ze||={}),(function(e){function t(e,t,n,r,i,a){let o={name:e,detail:t,kind:n,range:r,selectionRange:i};return a!==void 0&&(o.children=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.name)&&A.number(t.kind)&&b.is(t.range)&&b.is(t.selectionRange)&&(t.detail===void 0||A.string(t.detail))&&(t.deprecated===void 0||A.boolean(t.deprecated))&&(t.children===void 0||Array.isArray(t.children))&&(t.tags===void 0||Array.isArray(t.tags))}o(n,`is`),e.is=n})(Be||={}),(function(e){e.Empty=``,e.QuickFix=`quickfix`,e.Refactor=`refactor`,e.RefactorExtract=`refactor.extract`,e.RefactorInline=`refactor.inline`,e.RefactorRewrite=`refactor.rewrite`,e.Source=`source`,e.SourceOrganizeImports=`source.organizeImports`,e.SourceFixAll=`source.fixAll`})(Ve||={}),(function(e){e.Invoked=1,e.Automatic=2})(He||={}),(function(e){function t(e,t,n){let r={diagnostics:e};return t!=null&&(r.only=t),n!=null&&(r.triggerKind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.typedArray(t.diagnostics,ce.is)&&(t.only===void 0||A.typedArray(t.only,A.string))&&(t.triggerKind===void 0||t.triggerKind===He.Invoked||t.triggerKind===He.Automatic)}o(n,`is`),e.is=n})(Ue||={}),(function(e){function t(e,t,n){let r={title:e},i=!0;return typeof t==`string`?(i=!1,r.kind=t):le.is(t)?r.command=t:r.edit=t,i&&n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.title)&&(t.diagnostics===void 0||A.typedArray(t.diagnostics,ce.is))&&(t.kind===void 0||A.string(t.kind))&&(t.edit!==void 0||t.command!==void 0)&&(t.command===void 0||le.is(t.command))&&(t.isPreferred===void 0||A.boolean(t.isPreferred))&&(t.edit===void 0||k.is(t.edit))}o(n,`is`),e.is=n})(We||={}),(function(e){function t(e,t){let n={range:e};return A.defined(t)&&(n.data=t),n}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&(A.undefined(t.command)||le.is(t.command))}o(n,`is`),e.is=n})(Ge||={}),(function(e){function t(e,t){return{tabSize:e,insertSpaces:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.uinteger(t.tabSize)&&A.boolean(t.insertSpaces)}o(n,`is`),e.is=n})(Ke||={}),(function(e){function t(e,t,n){return{range:e,target:t,data:n}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&(A.undefined(t.target)||A.string(t.target))}o(n,`is`),e.is=n})(qe||={}),(function(e){function t(e,t){return{range:e,parent:t}}o(t,`create`),e.create=t;function n(t){let n=t;return A.objectLiteral(n)&&b.is(n.range)&&(n.parent===void 0||e.is(n.parent))}o(n,`is`),e.is=n})(Je||={}),(function(e){e.namespace=`namespace`,e.type=`type`,e.class=`class`,e.enum=`enum`,e.interface=`interface`,e.struct=`struct`,e.typeParameter=`typeParameter`,e.parameter=`parameter`,e.variable=`variable`,e.property=`property`,e.enumMember=`enumMember`,e.event=`event`,e.function=`function`,e.method=`method`,e.macro=`macro`,e.keyword=`keyword`,e.modifier=`modifier`,e.comment=`comment`,e.string=`string`,e.number=`number`,e.regexp=`regexp`,e.operator=`operator`,e.decorator=`decorator`})(Ye||={}),(function(e){e.declaration=`declaration`,e.definition=`definition`,e.readonly=`readonly`,e.static=`static`,e.deprecated=`deprecated`,e.abstract=`abstract`,e.async=`async`,e.modification=`modification`,e.documentation=`documentation`,e.defaultLibrary=`defaultLibrary`})(Xe||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&(t.resultId===void 0||typeof t.resultId==`string`)&&Array.isArray(t.data)&&(t.data.length===0||typeof t.data[0]==`number`)}o(t,`is`),e.is=t})(Ze||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&A.string(t.text)}o(n,`is`),e.is=n})(Qe||={}),(function(e){function t(e,t,n){return{range:e,variableName:t,caseSensitiveLookup:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&A.boolean(t.caseSensitiveLookup)&&(A.string(t.variableName)||t.variableName===void 0)}o(n,`is`),e.is=n})($e||={}),(function(e){function t(e,t){return{range:e,expression:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&(A.string(t.expression)||t.expression===void 0)}o(n,`is`),e.is=n})(et||={}),(function(e){function t(e,t){return{frameId:e,stoppedLocation:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(e.stoppedLocation)}o(n,`is`),e.is=n})(tt||={}),(function(e){e.Type=1,e.Parameter=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(nt||={}),(function(e){function t(e){return{value:e}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&(t.tooltip===void 0||A.string(t.tooltip)||xe.is(t.tooltip))&&(t.location===void 0||x.is(t.location))&&(t.command===void 0||le.is(t.command))}o(n,`is`),e.is=n})(rt||={}),(function(e){function t(e,t,n){let r={position:e,label:t};return n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&y.is(t.position)&&(A.string(t.label)||A.typedArray(t.label,rt.is))&&(t.kind===void 0||nt.is(t.kind))&&t.textEdits===void 0||A.typedArray(t.textEdits,ue.is)&&(t.tooltip===void 0||A.string(t.tooltip)||xe.is(t.tooltip))&&(t.paddingLeft===void 0||A.boolean(t.paddingLeft))&&(t.paddingRight===void 0||A.boolean(t.paddingRight))}o(n,`is`),e.is=n})(it||={}),(function(e){function t(e){return{kind:`snippet`,value:e}}o(t,`createSnippet`),e.createSnippet=t})(at||={}),(function(e){function t(e,t,n,r){return{insertText:e,filterText:t,range:n,command:r}}o(t,`create`),e.create=t})(ot||={}),(function(e){function t(e){return{items:e}}o(t,`create`),e.create=t})(st||={}),(function(e){e.Invoked=0,e.Automatic=1})(ct||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t})(lt||={}),(function(e){function t(e,t){return{triggerKind:e,selectedCompletionInfo:t}}o(t,`create`),e.create=t})(ut||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&g.is(t.uri)&&A.string(t.name)}o(t,`is`),e.is=t})(dt||={}),ft=[` +`,`\r +`,`\r`],(function(e){function t(e,t,n,r){return new mt(e,t,n,r)}o(t,`create`),e.create=t;function n(e){let t=e;return!!(A.defined(t)&&A.string(t.uri)&&(A.undefined(t.languageId)||A.string(t.languageId))&&A.uinteger(t.lineCount)&&A.func(t.getText)&&A.func(t.positionAt)&&A.func(t.offsetAt))}o(n,`is`),e.is=n;function r(e,t){let n=e.getText(),r=i(t,(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),a=n.length;for(let t=r.length-1;t>=0;t--){let i=r[t],o=e.offsetAt(i.range.start),s=e.offsetAt(i.range.end);if(s<=a)n=n.substring(0,o)+i.newText+n.substring(s,n.length);else throw Error(`Overlapping edit`);a=o}return n}o(r,`applyEdits`),e.applyEdits=r;function i(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),a=e.slice(n);i(r,t),i(a,t);let o=0,s=0,c=0;for(;o0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return y.create(0,e);for(;ne?r=i:n=i+1}let i=n-1;return y.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line],r=e.line+1n(e))}o(c,`stringArray`),e.stringArray=c}}),vt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/events.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Emitter=e.Event=void 0;var t=gt(),n;(function(e){let t={dispose(){}};e.None=function(){return t}})(n||(e.Event=n={}));var r=class{static{o(this,`CallbackList`)}add(e,t=null,n){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(n)&&n.push({dispose:o(()=>this.remove(e,t),`dispose`)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r{this._callbacks||=new r,this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,n);let a={dispose:o(()=>{this._callbacks&&(this._callbacks.remove(t,n),a.dispose=e._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))},`dispose`)};return Array.isArray(i)&&i.push(a),a},this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&=(this._callbacks.dispose(),void 0)}};e.Emitter=i,i._noop=function(){}}}),yt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/cancellation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CancellationTokenSource=e.CancellationToken=void 0;var t=gt(),n=_t(),r=vt(),i;(function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:r.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:r.Event.None});function t(t){let r=t;return r&&(r===e.None||r===e.Cancelled||n.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}o(t,`is`),e.is=t})(i||(e.CancellationToken=i={}));var a=Object.freeze(function(e,n){let r=(0,t.default)().timer.setTimeout(e.bind(n),0);return{dispose(){r.dispose()}}}),s=class{static{o(this,`MutableToken`)}constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?a:(this._emitter||=new r.Emitter,this._emitter.event)}dispose(){this._emitter&&=(this._emitter.dispose(),void 0)}};e.CancellationTokenSource=class{static{o(this,`CancellationTokenSource`)}get token(){return this._token||=new s,this._token}cancel(){this._token?this._token.cancel():this._token=i.Cancelled}dispose(){this._token?this._token instanceof s&&this._token.dispose():this._token=i.None}}}}),bt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messages.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Message=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType=e.RequestType0=e.AbstractMessageSignature=e.ParameterStructures=e.ResponseError=e.ErrorCodes=void 0;var t=_t(),n;(function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3})(n||(e.ErrorCodes=n={})),e.ResponseError=class e extends Error{static{o(this,`ResponseError`)}constructor(r,i,a){super(i),this.code=t.number(r)?r:n.UnknownErrorCode,this.data=a,Object.setPrototypeOf(this,e.prototype)}toJson(){let e={code:this.code,message:this.message};return this.data!==void 0&&(e.data=this.data),e}};var r=class e{static{o(this,`ParameterStructures`)}constructor(e){this.kind=e}static is(t){return t===e.auto||t===e.byName||t===e.byPosition}toString(){return this.kind}};e.ParameterStructures=r,r.auto=new r(`auto`),r.byPosition=new r(`byPosition`),r.byName=new r(`byName`);var i=class{static{o(this,`AbstractMessageSignature`)}constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return r.auto}};e.AbstractMessageSignature=i,e.RequestType0=class extends i{static{o(this,`RequestType0`)}constructor(e){super(e,0)}},e.RequestType=class extends i{static{o(this,`RequestType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType1=class extends i{static{o(this,`RequestType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType2=class extends i{static{o(this,`RequestType2`)}constructor(e){super(e,2)}},e.RequestType3=class extends i{static{o(this,`RequestType3`)}constructor(e){super(e,3)}},e.RequestType4=class extends i{static{o(this,`RequestType4`)}constructor(e){super(e,4)}},e.RequestType5=class extends i{static{o(this,`RequestType5`)}constructor(e){super(e,5)}},e.RequestType6=class extends i{static{o(this,`RequestType6`)}constructor(e){super(e,6)}},e.RequestType7=class extends i{static{o(this,`RequestType7`)}constructor(e){super(e,7)}},e.RequestType8=class extends i{static{o(this,`RequestType8`)}constructor(e){super(e,8)}},e.RequestType9=class extends i{static{o(this,`RequestType9`)}constructor(e){super(e,9)}},e.NotificationType=class extends i{static{o(this,`NotificationType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType0=class extends i{static{o(this,`NotificationType0`)}constructor(e){super(e,0)}},e.NotificationType1=class extends i{static{o(this,`NotificationType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType2=class extends i{static{o(this,`NotificationType2`)}constructor(e){super(e,2)}},e.NotificationType3=class extends i{static{o(this,`NotificationType3`)}constructor(e){super(e,3)}},e.NotificationType4=class extends i{static{o(this,`NotificationType4`)}constructor(e){super(e,4)}},e.NotificationType5=class extends i{static{o(this,`NotificationType5`)}constructor(e){super(e,5)}},e.NotificationType6=class extends i{static{o(this,`NotificationType6`)}constructor(e){super(e,6)}},e.NotificationType7=class extends i{static{o(this,`NotificationType7`)}constructor(e){super(e,7)}},e.NotificationType8=class extends i{static{o(this,`NotificationType8`)}constructor(e){super(e,8)}},e.NotificationType9=class extends i{static{o(this,`NotificationType9`)}constructor(e){super(e,9)}};var a;(function(e){function n(e){let n=e;return n&&t.string(n.method)&&(t.string(n.id)||t.number(n.id))}o(n,`isRequest`),e.isRequest=n;function r(e){let n=e;return n&&t.string(n.method)&&e.id===void 0}o(r,`isNotification`),e.isNotification=r;function i(e){let n=e;return n&&(n.result!==void 0||!!n.error)&&(t.string(n.id)||t.number(n.id)||n.id===null)}o(i,`isResponse`),e.isResponse=i})(a||(e.Message=a={}))}}),xt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/linkedMap.js"(e){var t;Object.defineProperty(e,"__esModule",{value:!0}),e.LRUCache=e.LinkedMap=e.Touch=void 0;var n;(function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last})(n||(e.Touch=n={}));var r=class{static{o(this,`LinkedMap`)}constructor(){this[t]=`LinkedMap`,this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=n.None){let r=this._map.get(e);if(r)return t!==n.None&&this.touch(r,t),r.value}set(e,t,r=n.None){let i=this._map.get(e);if(i)i.value=t,r!==n.None&&this.touch(i,r);else{switch(i={key:e,value:t,next:void 0,previous:void 0},r){case n.None:this.addItemLast(i);break;case n.First:this.addItemFirst(i);break;case n.Last:this.addItemLast(i);break;default:this.addItemLast(i)}this._map.set(e,i),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw Error(`Invalid list`);let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let n=this._state,r=this._head;for(;r;){if(t?e.bind(t)(r.value,r.key,this):e(r.value,r.key,this),this._state!==n)throw Error(`LinkedMap got modified during iteration.`);r=r.next}}keys(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.key,done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}values(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.value,done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}entries(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:[t.key,t.value],done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}[(t=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,n=this.size;for(;t&&n>e;)this._map.delete(t.key),t=t.next,n--;this._head=t,this._size=n,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw Error(`Invalid list`);this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw Error(`Invalid list`);this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw Error(`Invalid list`);e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw Error(`Invalid list`);e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,n=e.previous;if(!t||!n)throw Error(`Invalid list`);t.previous=n,n.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw Error(`Invalid list`);if(t===n.First||t===n.Last){if(t===n.First){if(e===this._head)return;let t=e.next,n=e.previous;e===this._tail?(n.next=void 0,this._tail=n):(t.previous=n,n.next=t),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===n.Last){if(e===this._tail)return;let t=e.next,n=e.previous;e===this._head?(t.previous=void 0,this._head=t):(t.previous=n,n.next=t),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,n)=>{e.push([n,t])}),e}fromJSON(e){this.clear();for(let[t,n]of e)this.set(t,n)}};e.LinkedMap=r,e.LRUCache=class extends r{static{o(this,`LRUCache`)}constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=n.AsNew){return super.get(e,t)}peek(e){return super.get(e,n.None)}set(e,t){return super.set(e,t,n.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}}}),St=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/disposable.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Disposable=void 0;var t;(function(e){function t(e){return{dispose:e}}o(t,`create`),e.create=t})(t||(e.Disposable=t={}))}}),Ct=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=void 0;var t=yt(),n;(function(e){e.Continue=0,e.Cancelled=1})(n||={}),e.SharedArraySenderStrategy=class{static{o(this,`SharedArraySenderStrategy`)}constructor(){this.buffers=new Map}enableCancellation(e){if(e.id===null)return;let t=new SharedArrayBuffer(4),r=new Int32Array(t,0,1);r[0]=n.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){let r=this.buffers.get(t);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,n.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};var r=class{static{o(this,`SharedArrayBufferCancellationToken`)}constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===n.Cancelled}get onCancellationRequested(){throw Error(`Cancellation over SharedArrayBuffer doesn't support cancellation events`)}},i=class{static{o(this,`SharedArrayBufferCancellationTokenSource`)}constructor(e){this.token=new r(e)}cancel(){}dispose(){}};e.SharedArrayReceiverStrategy=class{static{o(this,`SharedArrayReceiverStrategy`)}constructor(){this.kind=`request`}createCancellationTokenSource(e){let n=e.$cancellationData;return n===void 0?new t.CancellationTokenSource:new i(n)}}}}),wt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/semaphore.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Semaphore=void 0;var t=gt();e.Semaphore=class{static{o(this,`Semaphore`)}constructor(e=1){if(e<=0)throw Error(`Capacity must be greater than 0`);this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise((t,n)=>{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length!==0&&this._active!==this._capacity&&(0,t.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw Error(`To many thunks active`);try{let t=e.thunk();t instanceof Promise?t.then(t=>{this._active--,e.resolve(t),this.runNext()},t=>{this._active--,e.reject(t),this.runNext()}):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}}}}),Tt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageReader.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=void 0;var t=gt(),n=_t(),r=vt(),i=wt(),a;(function(e){function t(e){let t=e;return t&&n.func(t.listen)&&n.func(t.dispose)&&n.func(t.onError)&&n.func(t.onClose)&&n.func(t.onPartialMessage)}o(t,`is`),e.is=t})(a||(e.MessageReader=a={}));var s=class{static{o(this,`AbstractMessageReader`)}constructor(){this.errorEmitter=new r.Emitter,this.closeEmitter=new r.Emitter,this.partialMessageEmitter=new r.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:Error(`Reader received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageReader=s;var c;(function(e){function n(e){let n,r,i=new Map,a,o=new Map;if(e===void 0||typeof e==`string`)n=e??`utf-8`;else{if(n=e.charset??`utf-8`,e.contentDecoder!==void 0&&(r=e.contentDecoder,i.set(r.name,r)),e.contentDecoders!==void 0)for(let t of e.contentDecoders)i.set(t.name,t);if(e.contentTypeDecoder!==void 0&&(a=e.contentTypeDecoder,o.set(a.name,a)),e.contentTypeDecoders!==void 0)for(let t of e.contentTypeDecoders)o.set(t.name,t)}return a===void 0&&(a=(0,t.default)().applicationJson.decoder,o.set(a.name,a)),{charset:n,contentDecoder:r,contentDecoders:i,contentTypeDecoder:a,contentTypeDecoders:o}}o(n,`fromOptions`),e.fromOptions=n})(c||={}),e.ReadableStreamMessageReader=class extends s{static{o(this,`ReadableStreamMessageReader`)}constructor(e,n){super(),this.readable=e,this.options=c.fromOptions(n),this.buffer=(0,t.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new i.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;let t=this.readable.onData(e=>{this.onData(e)});return this.readable.onError(e=>this.fireError(e)),this.readable.onClose(()=>this.fireClose()),t}onData(e){try{for(this.buffer.append(e);;){if(this.nextMessageLength===-1){let e=this.buffer.tryReadHeaders(!0);if(!e)return;let t=e.get(`content-length`);if(!t){this.fireError(Error(`Header must provide a Content-Length property. +${JSON.stringify(Object.fromEntries(e))}`));return}let n=parseInt(t);if(isNaN(n)){this.fireError(Error(`Content-Length value must be a number. Got ${t}`));return}this.nextMessageLength=n}let e=this.buffer.tryReadBody(this.nextMessageLength);if(e===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let t=this.options.contentDecoder===void 0?e:await this.options.contentDecoder.decode(e),n=await this.options.contentTypeDecoder.decode(t,this.options);this.callback(n)}).catch(e=>{this.fireError(e)})}}catch(e){this.fireError(e)}}clearPartialMessageTimer(){this.partialMessageTimer&&=(this.partialMessageTimer.dispose(),void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,t.default)().timer.setTimeout((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}}}}),Et=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageWriter.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=void 0;var t=gt(),n=_t(),r=wt(),i=vt(),a=`Content-Length: `,s=`\r +`,c;(function(e){function t(e){let t=e;return t&&n.func(t.dispose)&&n.func(t.onClose)&&n.func(t.onError)&&n.func(t.write)}o(t,`is`),e.is=t})(c||(e.MessageWriter=c={}));var l=class{static{o(this,`AbstractMessageWriter`)}constructor(){this.errorEmitter=new i.Emitter,this.closeEmitter=new i.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e,t,n){this.errorEmitter.fire([this.asError(e),t,n])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(e){return e instanceof Error?e:Error(`Writer received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageWriter=l;var u;(function(e){function n(e){return e===void 0||typeof e==`string`?{charset:e??`utf-8`,contentTypeEncoder:(0,t.default)().applicationJson.encoder}:{charset:e.charset??`utf-8`,contentEncoder:e.contentEncoder,contentTypeEncoder:e.contentTypeEncoder??(0,t.default)().applicationJson.encoder}}o(n,`fromOptions`),e.fromOptions=n})(u||={}),e.WriteableStreamMessageWriter=class extends l{static{o(this,`WriteableStreamMessageWriter`)}constructor(e,t){super(),this.writable=e,this.options=u.fromOptions(t),this.errorCount=0,this.writeSemaphore=new r.Semaphore(1),this.writable.onError(e=>this.fireError(e)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then(e=>this.options.contentEncoder===void 0?e:this.options.contentEncoder.encode(e)).then(t=>{let n=[];return n.push(a,t.byteLength.toString(),s),n.push(s),this.doWrite(e,n,t)},e=>{throw this.fireError(e),e}))}async doWrite(e,t,n){try{return await this.writable.write(t.join(``),`ascii`),this.writable.write(n)}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}}}),Dt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractMessageBuffer=void 0;var t=13,n=10,r=`\r +`;e.AbstractMessageBuffer=class{static{o(this,`AbstractMessageBuffer`)}constructor(e=`utf-8`){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e==`string`?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let i=0,a=0,o=0,s=0;row:for(;athis._totalLength)throw Error(`Cannot read so many bytes!`);if(this._chunks[0].byteLength===e){let t=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(t)}if(this._chunks[0].byteLength>e){let t=this._chunks[0],n=this.asNative(t,e);return this._chunks[0]=t.slice(e),this._totalLength-=e,n}let t=this.allocNative(e),n=0;for(;e>0;){let r=this._chunks[0];if(r.byteLength>e){let i=r.slice(0,e);t.set(i,n),n+=e,this._chunks[0]=r.slice(e),this._totalLength-=e,e-=e}else t.set(r,n),n+=r.byteLength,this._chunks.shift(),this._totalLength-=r.byteLength,e-=r.byteLength}return t}}}}),Ot=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/connection.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createMessageConnection=e.ConnectionOptions=e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.RequestCancellationReceiverStrategy=e.IdCancellationReceiverStrategy=e.ConnectionStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=e.NullLogger=e.ProgressType=e.ProgressToken=void 0;var t=gt(),n=_t(),r=bt(),i=xt(),a=vt(),s=yt(),c;(function(e){e.type=new r.NotificationType(`$/cancelRequest`)})(c||={});var l;(function(e){function t(e){return typeof e==`string`||typeof e==`number`}o(t,`is`),e.is=t})(l||(e.ProgressToken=l={}));var u;(function(e){e.type=new r.NotificationType(`$/progress`)})(u||={}),e.ProgressType=class{static{o(this,`ProgressType`)}constructor(){}};var d;(function(e){function t(e){return n.func(e)}o(t,`is`),e.is=t})(d||={}),e.NullLogger=Object.freeze({error:o(()=>{},`error`),warn:o(()=>{},`warn`),info:o(()=>{},`info`),log:o(()=>{},`log`)});var f;(function(e){e[e.Off=0]=`Off`,e[e.Messages=1]=`Messages`,e[e.Compact=2]=`Compact`,e[e.Verbose=3]=`Verbose`})(f||(e.Trace=f={}));var p;(function(e){e.Off=`off`,e.Messages=`messages`,e.Compact=`compact`,e.Verbose=`verbose`})(p||(e.TraceValues=p={})),(function(e){function t(t){if(!n.string(t))return e.Off;switch(t=t.toLowerCase(),t){case`off`:return e.Off;case`messages`:return e.Messages;case`compact`:return e.Compact;case`verbose`:return e.Verbose;default:return e.Off}}o(t,`fromString`),e.fromString=t;function r(t){switch(t){case e.Off:return`off`;case e.Messages:return`messages`;case e.Compact:return`compact`;case e.Verbose:return`verbose`;default:return`off`}}o(r,`toString`),e.toString=r})(f||(e.Trace=f={}));var m;(function(e){e.Text=`text`,e.JSON=`json`})(m||(e.TraceFormat=m={})),(function(e){function t(t){return n.string(t)?(t=t.toLowerCase(),t===`json`?e.JSON:e.Text):e.Text}o(t,`fromString`),e.fromString=t})(m||(e.TraceFormat=m={}));var h;(function(e){e.type=new r.NotificationType(`$/setTrace`)})(h||(e.SetTraceNotification=h={}));var g;(function(e){e.type=new r.NotificationType(`$/logTrace`)})(g||(e.LogTraceNotification=g={}));var _;(function(e){e[e.Closed=1]=`Closed`,e[e.Disposed=2]=`Disposed`,e[e.AlreadyListening=3]=`AlreadyListening`})(_||(e.ConnectionErrors=_={}));var v=class e extends Error{static{o(this,`ConnectionError`)}constructor(t,n){super(n),this.code=t,Object.setPrototypeOf(this,e.prototype)}};e.ConnectionError=v;var y;(function(e){function t(e){let t=e;return t&&n.func(t.cancelUndispatched)}o(t,`is`),e.is=t})(y||(e.ConnectionStrategy=y={}));var b;(function(e){function t(e){let t=e;return t&&(t.kind===void 0||t.kind===`id`)&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(b||(e.IdCancellationReceiverStrategy=b={}));var x;(function(e){function t(e){let t=e;return t&&t.kind===`request`&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(x||(e.RequestCancellationReceiverStrategy=x={}));var ee;(function(e){e.Message=Object.freeze({createCancellationTokenSource(e){return new s.CancellationTokenSource}});function t(e){return b.is(e)||x.is(e)}o(t,`is`),e.is=t})(ee||(e.CancellationReceiverStrategy=ee={}));var S;(function(e){e.Message=Object.freeze({sendCancellation(e,t){return e.sendNotification(c.type,{id:t})},cleanup(e){}});function t(e){let t=e;return t&&n.func(t.sendCancellation)&&n.func(t.cleanup)}o(t,`is`),e.is=t})(S||(e.CancellationSenderStrategy=S={}));var te;(function(e){e.Message=Object.freeze({receiver:ee.Message,sender:S.Message});function t(e){let t=e;return t&&ee.is(t.receiver)&&S.is(t.sender)}o(t,`is`),e.is=t})(te||(e.CancellationStrategy=te={}));var ne;(function(e){function t(e){let t=e;return t&&n.func(t.handleMessage)}o(t,`is`),e.is=t})(ne||(e.MessageStrategy=ne={}));var C;(function(e){function t(e){let t=e;return t&&(te.is(t.cancellationStrategy)||y.is(t.connectionStrategy)||ne.is(t.messageStrategy))}o(t,`is`),e.is=t})(C||(e.ConnectionOptions=C={}));var re;(function(e){e[e.New=1]=`New`,e[e.Listening=2]=`Listening`,e[e.Closed=3]=`Closed`,e[e.Disposed=4]=`Disposed`})(re||={});function ie(p,y,x,ee){let S=x===void 0?e.NullLogger:x,C=0,ie=0,ae=0,oe,se=new Map,ce,le=new Map,ue=new Map,de,w=new i.LinkedMap,T=new Map,E=new Set,D=new Map,O=f.Off,fe=m.Text,k,pe=re.New,me=new a.Emitter,he=new a.Emitter,ge=new a.Emitter,_e=new a.Emitter,ve=new a.Emitter,ye=ee&&ee.cancellationStrategy?ee.cancellationStrategy:te.Message;function be(e){if(e===null)throw Error(`Can't send requests with id null since the response can't be correlated.`);return`req-`+e.toString()}o(be,`createRequestQueueKey`);function xe(e){return e===null?`res-unknown-`+(++ae).toString():`res-`+e.toString()}o(xe,`createResponseQueueKey`);function Se(){return`not-`+(++ie).toString()}o(Se,`createNotificationQueueKey`);function Ce(e,t){r.Message.isRequest(t)?e.set(be(t.id),t):r.Message.isResponse(t)?e.set(xe(t.id),t):e.set(Se(),t)}o(Ce,`addMessageToQueue`);function we(e){}o(we,`cancelUndispatched`);function Te(){return pe===re.Listening}o(Te,`isListening`);function Ee(){return pe===re.Closed}o(Ee,`isClosed`);function De(){return pe===re.Disposed}o(De,`isDisposed`);function Oe(){(pe===re.New||pe===re.Listening)&&(pe=re.Closed,he.fire(void 0))}o(Oe,`closeHandler`);function ke(e){me.fire([e,void 0,void 0])}o(ke,`readErrorHandler`);function Ae(e){me.fire(e)}o(Ae,`writeErrorHandler`),p.onClose(Oe),p.onError(ke),y.onClose(Oe),y.onError(Ae);function je(){de||w.size===0||(de=(0,t.default)().timer.setImmediate(()=>{de=void 0,Ne()}))}o(je,`triggerMessageQueue`);function Me(e){r.Message.isRequest(e)?Fe(e):r.Message.isNotification(e)?Le(e):r.Message.isResponse(e)?Ie(e):Re(e)}o(Me,`handleMessage`);function Ne(){if(w.size===0)return;let e=w.shift();try{let t=ee?.messageStrategy;ne.is(t)?t.handleMessage(e,Me):Me(e)}finally{je()}}o(Ne,`processMessageQueue`);let Pe=o(e=>{try{if(r.Message.isNotification(e)&&e.method===c.type.method){let t=e.params.id,n=be(t),i=w.get(n);if(r.Message.isRequest(i)){let r=ee?.connectionStrategy,a=r&&r.cancelUndispatched?r.cancelUndispatched(i,we):void 0;if(a&&(a.error!==void 0||a.result!==void 0)){w.delete(n),D.delete(t),a.id=i.id,He(a,e.method,Date.now()),y.write(a).catch(()=>S.error(`Sending response for canceled message failed.`));return}}let a=D.get(t);if(a!==void 0){a.cancel(),We(e);return}E.add(t)}Ce(w,e)}finally{je()}},`callback`);function Fe(e){if(De())return;function t(t,n,i){let a={jsonrpc:`2.0`,id:e.id};t instanceof r.ResponseError?a.error=t.toJson():a.result=t===void 0?null:t,He(a,n,i),y.write(a).catch(()=>S.error(`Sending response failed.`))}o(t,`reply`);function i(t,n,r){let i={jsonrpc:`2.0`,id:e.id,error:t.toJson()};He(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(i,`replyError`);function a(t,n,r){t===void 0&&(t=null);let i={jsonrpc:`2.0`,id:e.id,result:t};He(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(a,`replySuccess`),Ue(e);let s=se.get(e.method),c,l;s&&(c=s.type,l=s.handler);let u=Date.now();if(l||oe){let o=e.id??String(Date.now()),s=b.is(ye.receiver)?ye.receiver.createCancellationTokenSource(o):ye.receiver.createCancellationTokenSource(e);e.id!==null&&E.has(e.id)&&s.cancel(),e.id!==null&&D.set(o,s);try{let d;if(l){if(e.params===void 0){if(c!==void 0&&c.numberOfParams!==0){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines ${c.numberOfParams} params but received none.`),e.method,u);return}d=l(s.token)}else if(Array.isArray(e.params)){if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byName){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by name but received parameters by position`),e.method,u);return}d=l(...e.params,s.token)}else{if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byPosition){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by position but received parameters by name`),e.method,u);return}d=l(e.params,s.token)}}else oe&&(d=oe(e.method,e.params,s.token));let f=d;d?f.then?f.then(n=>{D.delete(o),t(n,e.method,u)},t=>{D.delete(o),t instanceof r.ResponseError?i(t,e.method,u):t&&n.string(t.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${t.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}):(D.delete(o),t(d,e.method,u)):(D.delete(o),a(d,e.method,u))}catch(a){D.delete(o),a instanceof r.ResponseError?t(a,e.method,u):a&&n.string(a.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${a.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}}else i(new r.ResponseError(r.ErrorCodes.MethodNotFound,`Unhandled method ${e.method}`),e.method,u)}o(Fe,`handleRequest`);function Ie(e){if(!De()){if(e.id===null)e.error?S.error(`Received response message without id: Error is: +${JSON.stringify(e.error,void 0,4)}`):S.error(`Received response message without id. No further error information provided.`);else{let t=e.id,n=T.get(t);if(Ge(e,n),n!==void 0){T.delete(t);try{if(e.error){let t=e.error;n.reject(new r.ResponseError(t.code,t.message,t.data))}else if(e.result!==void 0)n.resolve(e.result);else throw Error(`Should never happen.`)}catch(e){e.message?S.error(`Response handler '${n.method}' failed with message: ${e.message}`):S.error(`Response handler '${n.method}' failed unexpectedly.`)}}}}}o(Ie,`handleResponse`);function Le(e){if(De())return;let t,n;if(e.method===c.type.method){let t=e.params.id;E.delete(t),We(e);return}{let r=le.get(e.method);r&&(n=r.handler,t=r.type)}if(n||ce)try{if(We(e),n){if(e.params===void 0)t!==void 0&&t.numberOfParams!==0&&t.parameterStructures!==r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received none.`),n();else if(Array.isArray(e.params)){let i=e.params;e.method===u.type.method&&i.length===2&&l.is(i[0])?n({token:i[0],value:i[1]}):(t!==void 0&&(t.parameterStructures===r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines parameters by name but received parameters by position`),t.numberOfParams!==e.params.length&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received ${i.length} arguments`)),n(...i))}else t!==void 0&&t.parameterStructures===r.ParameterStructures.byPosition&&S.error(`Notification ${e.method} defines parameters by position but received parameters by name`),n(e.params)}else ce&&ce(e.method,e.params)}catch(t){t.message?S.error(`Notification handler '${e.method}' failed with message: ${t.message}`):S.error(`Notification handler '${e.method}' failed unexpectedly.`)}else ge.fire(e)}o(Le,`handleNotification`);function Re(e){if(!e){S.error(`Received empty message.`);return}S.error(`Received message which is neither a response nor a notification message: +${JSON.stringify(e,null,4)}`);let t=e;if(n.string(t.id)||n.number(t.id)){let e=t.id,n=T.get(e);n&&n.reject(Error(`The received response has neither a result nor an error property.`))}}o(Re,`handleInvalidMessage`);function ze(e){if(e!=null)switch(O){case f.Verbose:return JSON.stringify(e,null,4);case f.Compact:return JSON.stringify(e);default:return}}o(ze,`stringifyTrace`);function Be(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&e.params&&(t=`Params: ${ze(e.params)} + +`),k.log(`Sending request '${e.method} - (${e.id})'.`,t)}else Ke(`send-request`,e)}}o(Be,`traceSendingRequest`);function Ve(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&(t=e.params?`Params: ${ze(e.params)} + +`:`No parameters provided. + +`),k.log(`Sending notification '${e.method}'.`,t)}else Ke(`send-notification`,e)}}o(Ve,`traceSendingNotification`);function He(e,t,n){if(!(O===f.Off||!k)){if(fe===m.Text){let r;(O===f.Verbose||O===f.Compact)&&(e.error&&e.error.data?r=`Error data: ${ze(e.error.data)} + +`:e.result?r=`Result: ${ze(e.result)} + +`:e.error===void 0&&(r=`No result returned. + +`)),k.log(`Sending response '${t} - (${e.id})'. Processing request took ${Date.now()-n}ms`,r)}else Ke(`send-response`,e)}}o(He,`traceSendingResponse`);function Ue(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&e.params&&(t=`Params: ${ze(e.params)} + +`),k.log(`Received request '${e.method} - (${e.id})'.`,t)}else Ke(`receive-request`,e)}}o(Ue,`traceReceivedRequest`);function We(e){if(!(O===f.Off||!k||e.method===g.type.method)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&(t=e.params?`Params: ${ze(e.params)} + +`:`No parameters provided. + +`),k.log(`Received notification '${e.method}'.`,t)}else Ke(`receive-notification`,e)}}o(We,`traceReceivedNotification`);function Ge(e,t){if(!(O===f.Off||!k)){if(fe===m.Text){let n;if((O===f.Verbose||O===f.Compact)&&(e.error&&e.error.data?n=`Error data: ${ze(e.error.data)} + +`:e.result?n=`Result: ${ze(e.result)} + +`:e.error===void 0&&(n=`No result returned. + +`)),t){let r=e.error?` Request failed: ${e.error.message} (${e.error.code}).`:``;k.log(`Received response '${t.method} - (${e.id})' in ${Date.now()-t.timerStart}ms.${r}`,n)}else k.log(`Received response ${e.id} without active response promise.`,n)}else Ke(`receive-response`,e)}}o(Ge,`traceReceivedResponse`);function Ke(e,t){if(!k||O===f.Off)return;let n={isLSPMessage:!0,type:e,message:t,timestamp:Date.now()};k.log(n)}o(Ke,`logLSPMessage`);function qe(){if(Ee())throw new v(_.Closed,`Connection is closed.`);if(De())throw new v(_.Disposed,`Connection is disposed.`)}o(qe,`throwIfClosedOrDisposed`);function Je(){if(Te())throw new v(_.AlreadyListening,`Connection is already listening`)}o(Je,`throwIfListening`);function Ye(){if(!Te())throw Error(`Call listen() first.`)}o(Ye,`throwIfNotListening`);function Xe(e){return e===void 0?null:e}o(Xe,`undefinedToNull`);function Ze(e){if(e!==null)return e}o(Ze,`nullToUndefined`);function Qe(e){return e!=null&&!Array.isArray(e)&&typeof e==`object`}o(Qe,`isNamedParam`);function $e(e,t){switch(e){case r.ParameterStructures.auto:return Qe(t)?Ze(t):[Xe(t)];case r.ParameterStructures.byName:if(!Qe(t))throw Error(`Received parameters by name but param is not an object literal.`);return Ze(t);case r.ParameterStructures.byPosition:return[Xe(t)];default:throw Error(`Unknown parameter structure ${e.toString()}`)}}o($e,`computeSingleParam`);function et(e,t){let n,r=e.numberOfParams;switch(r){case 0:n=void 0;break;case 1:n=$e(e.parameterStructures,t[0]);break;default:n=[];for(let e=0;e{qe();let i,a;if(n.string(e)){i=e;let n=t[0],o=0,s=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(o=1,s=n);let c=t.length,l=c-o;switch(l){case 0:a=void 0;break;case 1:a=$e(s,t[o]);break;default:if(s===r.ParameterStructures.byName)throw Error(`Received ${l} parameters for 'by Name' notification parameter structure.`);a=t.slice(o,c).map(e=>Xe(e))}}else{let n=t;i=e.method,a=et(e,n)}let o={jsonrpc:`2.0`,method:i,params:a};return Ve(o),y.write(o).catch(e=>{throw S.error(`Sending notification failed.`),e})},`sendNotification`),onNotification:o((e,t)=>{qe();let r;return n.func(e)?ce=e:t&&(n.string(e)?(r=e,le.set(e,{type:void 0,handler:t})):(r=e.method,le.set(e.method,{type:e,handler:t}))),{dispose:o(()=>{r===void 0?ce=void 0:le.delete(r)},`dispose`)}},`onNotification`),onProgress:o((e,t,n)=>{if(ue.has(t))throw Error(`Progress handler for token ${t} already registered`);return ue.set(t,n),{dispose:o(()=>{ue.delete(t)},`dispose`)}},`onProgress`),sendProgress:o((e,t,n)=>tt.sendNotification(u.type,{token:t,value:n}),`sendProgress`),onUnhandledProgress:_e.event,sendRequest:o((e,...t)=>{qe(),Ye();let i,a,c;if(n.string(e)){i=e;let n=t[0],o=t[t.length-1],l=0,u=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(l=1,u=n);let d=t.length;s.CancellationToken.is(o)&&(--d,c=o);let f=d-l;switch(f){case 0:a=void 0;break;case 1:a=$e(u,t[l]);break;default:if(u===r.ParameterStructures.byName)throw Error(`Received ${f} parameters for 'by Name' request parameter structure.`);a=t.slice(l,d).map(e=>Xe(e))}}else{let n=t;i=e.method,a=et(e,n);let r=e.numberOfParams;c=s.CancellationToken.is(n[r])?n[r]:void 0}let l=C++,u;c&&(u=c.onCancellationRequested(()=>{let e=ye.sender.sendCancellation(tt,l);return e===void 0?(S.log(`Received no promise from cancellation strategy when cancelling id ${l}`),Promise.resolve()):e.catch(()=>{S.log(`Sending cancellation messages for id ${l} failed`)})}));let d={jsonrpc:`2.0`,id:l,method:i,params:a};return Be(d),typeof ye.sender.enableCancellation==`function`&&ye.sender.enableCancellation(d),new Promise(async(e,t)=>{let n=o(t=>{e(t),ye.sender.cleanup(l),u?.dispose()},`resolveWithCleanup`),a=o(e=>{t(e),ye.sender.cleanup(l),u?.dispose()},`rejectWithCleanup`),s={method:i,timerStart:Date.now(),resolve:n,reject:a};try{await y.write(d),T.set(l,s)}catch(e){throw S.error(`Sending request failed.`),s.reject(new r.ResponseError(r.ErrorCodes.MessageWriteError,e.message?e.message:`Unknown reason`)),e}})},`sendRequest`),onRequest:o((e,t)=>{qe();let r=null;return d.is(e)?(r=void 0,oe=e):n.string(e)?(r=null,t!==void 0&&(r=e,se.set(e,{handler:t,type:void 0}))):t!==void 0&&(r=e.method,se.set(e.method,{type:e,handler:t})),{dispose:o(()=>{r!==null&&(r===void 0?oe=void 0:se.delete(r))},`dispose`)}},`onRequest`),hasPendingResponse:o(()=>T.size>0,`hasPendingResponse`),trace:o(async(e,t,r)=>{let i=!1,a=m.Text;r!==void 0&&(n.boolean(r)?i=r:(i=r.sendNotification||!1,a=r.traceFormat||m.Text)),O=e,fe=a,k=O===f.Off?void 0:t,i&&!Ee()&&!De()&&await tt.sendNotification(h.type,{value:f.toString(e)})},`trace`),onError:me.event,onClose:he.event,onUnhandledNotification:ge.event,onDispose:ve.event,end:o(()=>{y.end()},`end`),dispose:o(()=>{if(De())return;pe=re.Disposed,ve.fire(void 0);let e=new r.ResponseError(r.ErrorCodes.PendingResponseRejected,`Pending response rejected since connection got disposed`);for(let t of T.values())t.reject(e);T=new Map,D=new Map,E=new Set,w=new i.LinkedMap,n.func(y.dispose)&&y.dispose(),n.func(p.dispose)&&p.dispose()},`dispose`),listen:o(()=>{qe(),Je(),pe=re.Listening,p.listen(Pe)},`listen`),inspect:o(()=>{(0,t.default)().console.log(`inspect`)},`inspect`)};return tt.onNotification(g.type,e=>{if(O===f.Off||!k)return;let t=O===f.Verbose||O===f.Compact;k.log(e.message,t?e.verbose:void 0)}),tt.onNotification(u.type,e=>{let t=ue.get(e.token);t?t(e.value):_e.fire(e)}),tt}o(ie,`createMessageConnection`),e.createMessageConnection=ie}}),kt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/api.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProgressType=e.ProgressToken=e.createMessageConnection=e.NullLogger=e.ConnectionOptions=e.ConnectionStrategy=e.AbstractMessageBuffer=e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=e.CancellationToken=e.CancellationTokenSource=e.Emitter=e.Event=e.Disposable=e.LRUCache=e.Touch=e.LinkedMap=e.ParameterStructures=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.ErrorCodes=e.ResponseError=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType0=e.RequestType=e.Message=e.RAL=void 0,e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=void 0;var t=bt();Object.defineProperty(e,"Message",{enumerable:!0,get:o(function(){return t.Message},`get`)}),Object.defineProperty(e,"RequestType",{enumerable:!0,get:o(function(){return t.RequestType},`get`)}),Object.defineProperty(e,"RequestType0",{enumerable:!0,get:o(function(){return t.RequestType0},`get`)}),Object.defineProperty(e,"RequestType1",{enumerable:!0,get:o(function(){return t.RequestType1},`get`)}),Object.defineProperty(e,"RequestType2",{enumerable:!0,get:o(function(){return t.RequestType2},`get`)}),Object.defineProperty(e,"RequestType3",{enumerable:!0,get:o(function(){return t.RequestType3},`get`)}),Object.defineProperty(e,"RequestType4",{enumerable:!0,get:o(function(){return t.RequestType4},`get`)}),Object.defineProperty(e,"RequestType5",{enumerable:!0,get:o(function(){return t.RequestType5},`get`)}),Object.defineProperty(e,"RequestType6",{enumerable:!0,get:o(function(){return t.RequestType6},`get`)}),Object.defineProperty(e,"RequestType7",{enumerable:!0,get:o(function(){return t.RequestType7},`get`)}),Object.defineProperty(e,"RequestType8",{enumerable:!0,get:o(function(){return t.RequestType8},`get`)}),Object.defineProperty(e,"RequestType9",{enumerable:!0,get:o(function(){return t.RequestType9},`get`)}),Object.defineProperty(e,"ResponseError",{enumerable:!0,get:o(function(){return t.ResponseError},`get`)}),Object.defineProperty(e,"ErrorCodes",{enumerable:!0,get:o(function(){return t.ErrorCodes},`get`)}),Object.defineProperty(e,"NotificationType",{enumerable:!0,get:o(function(){return t.NotificationType},`get`)}),Object.defineProperty(e,"NotificationType0",{enumerable:!0,get:o(function(){return t.NotificationType0},`get`)}),Object.defineProperty(e,"NotificationType1",{enumerable:!0,get:o(function(){return t.NotificationType1},`get`)}),Object.defineProperty(e,"NotificationType2",{enumerable:!0,get:o(function(){return t.NotificationType2},`get`)}),Object.defineProperty(e,"NotificationType3",{enumerable:!0,get:o(function(){return t.NotificationType3},`get`)}),Object.defineProperty(e,"NotificationType4",{enumerable:!0,get:o(function(){return t.NotificationType4},`get`)}),Object.defineProperty(e,"NotificationType5",{enumerable:!0,get:o(function(){return t.NotificationType5},`get`)}),Object.defineProperty(e,"NotificationType6",{enumerable:!0,get:o(function(){return t.NotificationType6},`get`)}),Object.defineProperty(e,"NotificationType7",{enumerable:!0,get:o(function(){return t.NotificationType7},`get`)}),Object.defineProperty(e,"NotificationType8",{enumerable:!0,get:o(function(){return t.NotificationType8},`get`)}),Object.defineProperty(e,"NotificationType9",{enumerable:!0,get:o(function(){return t.NotificationType9},`get`)}),Object.defineProperty(e,"ParameterStructures",{enumerable:!0,get:o(function(){return t.ParameterStructures},`get`)});var n=xt();Object.defineProperty(e,"LinkedMap",{enumerable:!0,get:o(function(){return n.LinkedMap},`get`)}),Object.defineProperty(e,"LRUCache",{enumerable:!0,get:o(function(){return n.LRUCache},`get`)}),Object.defineProperty(e,"Touch",{enumerable:!0,get:o(function(){return n.Touch},`get`)});var r=St();Object.defineProperty(e,"Disposable",{enumerable:!0,get:o(function(){return r.Disposable},`get`)});var i=vt();Object.defineProperty(e,"Event",{enumerable:!0,get:o(function(){return i.Event},`get`)}),Object.defineProperty(e,"Emitter",{enumerable:!0,get:o(function(){return i.Emitter},`get`)});var a=yt();Object.defineProperty(e,"CancellationTokenSource",{enumerable:!0,get:o(function(){return a.CancellationTokenSource},`get`)}),Object.defineProperty(e,"CancellationToken",{enumerable:!0,get:o(function(){return a.CancellationToken},`get`)});var s=Ct();Object.defineProperty(e,"SharedArraySenderStrategy",{enumerable:!0,get:o(function(){return s.SharedArraySenderStrategy},`get`)}),Object.defineProperty(e,"SharedArrayReceiverStrategy",{enumerable:!0,get:o(function(){return s.SharedArrayReceiverStrategy},`get`)});var c=Tt();Object.defineProperty(e,"MessageReader",{enumerable:!0,get:o(function(){return c.MessageReader},`get`)}),Object.defineProperty(e,"AbstractMessageReader",{enumerable:!0,get:o(function(){return c.AbstractMessageReader},`get`)}),Object.defineProperty(e,"ReadableStreamMessageReader",{enumerable:!0,get:o(function(){return c.ReadableStreamMessageReader},`get`)});var l=Et();Object.defineProperty(e,"MessageWriter",{enumerable:!0,get:o(function(){return l.MessageWriter},`get`)}),Object.defineProperty(e,"AbstractMessageWriter",{enumerable:!0,get:o(function(){return l.AbstractMessageWriter},`get`)}),Object.defineProperty(e,"WriteableStreamMessageWriter",{enumerable:!0,get:o(function(){return l.WriteableStreamMessageWriter},`get`)});var u=Dt();Object.defineProperty(e,"AbstractMessageBuffer",{enumerable:!0,get:o(function(){return u.AbstractMessageBuffer},`get`)});var d=Ot();Object.defineProperty(e,"ConnectionStrategy",{enumerable:!0,get:o(function(){return d.ConnectionStrategy},`get`)}),Object.defineProperty(e,"ConnectionOptions",{enumerable:!0,get:o(function(){return d.ConnectionOptions},`get`)}),Object.defineProperty(e,"NullLogger",{enumerable:!0,get:o(function(){return d.NullLogger},`get`)}),Object.defineProperty(e,"createMessageConnection",{enumerable:!0,get:o(function(){return d.createMessageConnection},`get`)}),Object.defineProperty(e,"ProgressToken",{enumerable:!0,get:o(function(){return d.ProgressToken},`get`)}),Object.defineProperty(e,"ProgressType",{enumerable:!0,get:o(function(){return d.ProgressType},`get`)}),Object.defineProperty(e,"Trace",{enumerable:!0,get:o(function(){return d.Trace},`get`)}),Object.defineProperty(e,"TraceValues",{enumerable:!0,get:o(function(){return d.TraceValues},`get`)}),Object.defineProperty(e,"TraceFormat",{enumerable:!0,get:o(function(){return d.TraceFormat},`get`)}),Object.defineProperty(e,"SetTraceNotification",{enumerable:!0,get:o(function(){return d.SetTraceNotification},`get`)}),Object.defineProperty(e,"LogTraceNotification",{enumerable:!0,get:o(function(){return d.LogTraceNotification},`get`)}),Object.defineProperty(e,"ConnectionErrors",{enumerable:!0,get:o(function(){return d.ConnectionErrors},`get`)}),Object.defineProperty(e,"ConnectionError",{enumerable:!0,get:o(function(){return d.ConnectionError},`get`)}),Object.defineProperty(e,"CancellationReceiverStrategy",{enumerable:!0,get:o(function(){return d.CancellationReceiverStrategy},`get`)}),Object.defineProperty(e,"CancellationSenderStrategy",{enumerable:!0,get:o(function(){return d.CancellationSenderStrategy},`get`)}),Object.defineProperty(e,"CancellationStrategy",{enumerable:!0,get:o(function(){return d.CancellationStrategy},`get`)}),Object.defineProperty(e,"MessageStrategy",{enumerable:!0,get:o(function(){return d.MessageStrategy},`get`)}),e.RAL=gt().default}}),At=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/ril.js"(e){Object.defineProperty(e,"__esModule",{value:!0});var t=kt(),n=class e extends t.AbstractMessageBuffer{static{o(this,`MessageBuffer`)}constructor(e=`utf-8`){super(e),this.asciiDecoder=new TextDecoder(`ascii`)}emptyBuffer(){return e.emptyBuffer}fromString(e,t){return new TextEncoder().encode(e)}toString(e,t){return t===`ascii`?this.asciiDecoder.decode(e):new TextDecoder(t).decode(e)}asNative(e,t){return t===void 0?e:e.slice(0,t)}allocNative(e){return new Uint8Array(e)}};n.emptyBuffer=new Uint8Array;var r=class{static{o(this,`ReadableStreamWrapper`)}constructor(e){this.socket=e,this._onData=new t.Emitter,this._messageListener=e=>{e.data.arrayBuffer().then(e=>{this._onData.fire(new Uint8Array(e))},()=>{(0,t.RAL)().console.error(`Converting blob to array buffer failed.`)})},this.socket.addEventListener(`message`,this._messageListener)}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}onData(e){return this._onData.event(e)}},i=class{static{o(this,`WritableStreamWrapper`)}constructor(e){this.socket=e}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}write(e,t){if(typeof e==`string`){if(t!==void 0&&t!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t}`);this.socket.send(e)}else this.socket.send(e);return Promise.resolve()}end(){this.socket.close()}},a=new TextEncoder,s=Object.freeze({messageBuffer:Object.freeze({create:o(e=>new n(e),`create`)}),applicationJson:Object.freeze({encoder:Object.freeze({name:`application/json`,encode:o((e,t)=>{if(t.charset!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(a.encode(JSON.stringify(e,void 0,0)))},`encode`)}),decoder:Object.freeze({name:`application/json`,decode:o((e,t)=>{if(!(e instanceof Uint8Array))throw Error(`In a Browser environments only Uint8Arrays are supported.`);return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))},`decode`)})}),stream:Object.freeze({asReadableStream:o(e=>new r(e),`asReadableStream`),asWritableStream:o(e=>new i(e),`asWritableStream`)}),console,timer:Object.freeze({setTimeout(e,t,...n){let r=setTimeout(e,t,...n);return{dispose:o(()=>clearTimeout(r),`dispose`)}},setImmediate(e,...t){let n=setTimeout(e,0,...t);return{dispose:o(()=>clearTimeout(n),`dispose`)}},setInterval(e,t,...n){let r=setInterval(e,t,...n);return{dispose:o(()=>clearInterval(r),`dispose`)}}})});function c(){return s}o(c,`RIL`),(function(e){function n(){t.RAL.install(s)}o(n,`install`),e.install=n})(c||={}),e.default=c}}),jt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.createMessageConnection=e.BrowserMessageWriter=e.BrowserMessageReader=void 0,At().default.install();var r=kt();n(kt(),e),e.BrowserMessageReader=class extends r.AbstractMessageReader{static{o(this,`BrowserMessageReader`)}constructor(e){super(),this._onData=new r.Emitter,this._messageListener=e=>{this._onData.fire(e.data)},e.addEventListener(`error`,e=>this.fireError(e)),e.onmessage=this._messageListener}listen(e){return this._onData.event(e)}},e.BrowserMessageWriter=class extends r.AbstractMessageWriter{static{o(this,`BrowserMessageWriter`)}constructor(e){super(),this.port=e,this.errorCount=0,e.addEventListener(`error`,e=>this.fireError(e))}write(e){try{return this.port.postMessage(e),Promise.resolve()}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){}};function i(e,t,n,i){return n===void 0&&(n=r.NullLogger),r.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,r.createMessageConnection)(e,t,n,i)}o(i,`createMessageConnection`),e.createMessageConnection=i}}),Mt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/browser.js"(e,t){t.exports=jt()}}),j=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProtocolNotificationType=e.ProtocolNotificationType0=e.ProtocolRequestType=e.ProtocolRequestType0=e.RegistrationType=e.MessageDirection=void 0;var t=jt(),n;(function(e){e.clientToServer=`clientToServer`,e.serverToClient=`serverToClient`,e.both=`both`})(n||(e.MessageDirection=n={})),e.RegistrationType=class{static{o(this,`RegistrationType`)}constructor(e){this.method=e}},e.ProtocolRequestType0=class extends t.RequestType0{static{o(this,`ProtocolRequestType0`)}constructor(e){super(e)}},e.ProtocolRequestType=class extends t.RequestType{static{o(this,`ProtocolRequestType`)}constructor(e){super(e,t.ParameterStructures.byName)}},e.ProtocolNotificationType0=class extends t.NotificationType0{static{o(this,`ProtocolNotificationType0`)}constructor(e){super(e)}},e.ProtocolNotificationType=class extends t.NotificationType{static{o(this,`ProtocolNotificationType`)}constructor(e){super(e,t.ParameterStructures.byName)}}}}),Nt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.objectLiteral=e.typedArray=e.stringArray=e.array=e.func=e.error=e.number=e.string=e.boolean=void 0;function t(e){return e===!0||e===!1}o(t,`boolean`),e.boolean=t;function n(e){return typeof e==`string`||e instanceof String}o(n,`string`),e.string=n;function r(e){return typeof e==`number`||e instanceof Number}o(r,`number`),e.number=r;function i(e){return e instanceof Error}o(i,`error`),e.error=i;function a(e){return typeof e==`function`}o(a,`func`),e.func=a;function s(e){return Array.isArray(e)}o(s,`array`),e.array=s;function c(e){return s(e)&&e.every(e=>n(e))}o(c,`stringArray`),e.stringArray=c;function l(e,t){return Array.isArray(e)&&e.every(t)}o(l,`typedArray`),e.typedArray=l;function u(e){return typeof e==`object`&&!!e}o(u,`objectLiteral`),e.objectLiteral=u}}),Pt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ImplementationRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/implementation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ImplementationRequest=n={}))}}),Ft=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TypeDefinitionRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/typeDefinition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeDefinitionRequest=n={}))}}),It=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DidChangeWorkspaceFoldersNotification=e.WorkspaceFoldersRequest=void 0;var t=j(),n;(function(e){e.method=`workspace/workspaceFolders`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(n||(e.WorkspaceFoldersRequest=n={}));var r;(function(e){e.method=`workspace/didChangeWorkspaceFolders`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(r||(e.DidChangeWorkspaceFoldersNotification=r={}))}}),Lt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ConfigurationRequest=void 0;var t=j(),n;(function(e){e.method=`workspace/configuration`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ConfigurationRequest=n={}))}}),Rt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ColorPresentationRequest=e.DocumentColorRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/documentColor`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DocumentColorRequest=n={}));var r;(function(e){e.method=`textDocument/colorPresentation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.ColorPresentationRequest=r={}))}}),zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.FoldingRangeRefreshRequest=e.FoldingRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/foldingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.FoldingRangeRequest=n={}));var r;(function(e){e.method=`workspace/foldingRange/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.FoldingRangeRefreshRequest=r={}))}}),Bt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DeclarationRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/declaration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DeclarationRequest=n={}))}}),Vt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SelectionRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/selectionRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.SelectionRangeRequest=n={}))}}),Ht=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorkDoneProgressCancelNotification=e.WorkDoneProgressCreateRequest=e.WorkDoneProgress=void 0;var t=jt(),n=j(),r;(function(e){e.type=new t.ProgressType;function n(t){return t===e.type}o(n,`is`),e.is=n})(r||(e.WorkDoneProgress=r={}));var i;(function(e){e.method=`window/workDoneProgress/create`,e.messageDirection=n.MessageDirection.serverToClient,e.type=new n.ProtocolRequestType(e.method)})(i||(e.WorkDoneProgressCreateRequest=i={}));var a;(function(e){e.method=`window/workDoneProgress/cancel`,e.messageDirection=n.MessageDirection.clientToServer,e.type=new n.ProtocolNotificationType(e.method)})(a||(e.WorkDoneProgressCancelNotification=a={}))}}),Ut=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CallHierarchyOutgoingCallsRequest=e.CallHierarchyIncomingCallsRequest=e.CallHierarchyPrepareRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/prepareCallHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.CallHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`callHierarchy/incomingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.CallHierarchyIncomingCallsRequest=r={}));var i;(function(e){e.method=`callHierarchy/outgoingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.CallHierarchyOutgoingCallsRequest=i={}))}}),Wt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SemanticTokensRefreshRequest=e.SemanticTokensRangeRequest=e.SemanticTokensDeltaRequest=e.SemanticTokensRequest=e.SemanticTokensRegistrationType=e.TokenFormat=void 0;var t=j(),n;(function(e){e.Relative=`relative`})(n||(e.TokenFormat=n={}));var r;(function(e){e.method=`textDocument/semanticTokens`,e.type=new t.RegistrationType(e.method)})(r||(e.SemanticTokensRegistrationType=r={}));var i;(function(e){e.method=`textDocument/semanticTokens/full`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(i||(e.SemanticTokensRequest=i={}));var a;(function(e){e.method=`textDocument/semanticTokens/full/delta`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(a||(e.SemanticTokensDeltaRequest=a={}));var o;(function(e){e.method=`textDocument/semanticTokens/range`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(o||(e.SemanticTokensRangeRequest=o={}));var s;(function(e){e.method=`workspace/semanticTokens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(s||(e.SemanticTokensRefreshRequest=s={}))}}),Gt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ShowDocumentRequest=void 0;var t=j(),n;(function(e){e.method=`window/showDocument`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ShowDocumentRequest=n={}))}}),Kt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.LinkedEditingRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/linkedEditingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.LinkedEditingRangeRequest=n={}))}}),qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WillDeleteFilesRequest=e.DidDeleteFilesNotification=e.DidRenameFilesNotification=e.WillRenameFilesRequest=e.DidCreateFilesNotification=e.WillCreateFilesRequest=e.FileOperationPatternKind=void 0;var t=j(),n;(function(e){e.file=`file`,e.folder=`folder`})(n||(e.FileOperationPatternKind=n={}));var r;(function(e){e.method=`workspace/willCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.WillCreateFilesRequest=r={}));var i;(function(e){e.method=`workspace/didCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(i||(e.DidCreateFilesNotification=i={}));var a;(function(e){e.method=`workspace/willRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(a||(e.WillRenameFilesRequest=a={}));var o;(function(e){e.method=`workspace/didRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(o||(e.DidRenameFilesNotification=o={}));var s;(function(e){e.method=`workspace/didDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(s||(e.DidDeleteFilesNotification=s={}));var c;(function(e){e.method=`workspace/willDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(c||(e.WillDeleteFilesRequest=c={}))}}),Jt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MonikerRequest=e.MonikerKind=e.UniquenessLevel=void 0;var t=j(),n;(function(e){e.document=`document`,e.project=`project`,e.group=`group`,e.scheme=`scheme`,e.global=`global`})(n||(e.UniquenessLevel=n={}));var r;(function(e){e.$import=`import`,e.$export=`export`,e.local=`local`})(r||(e.MonikerKind=r={}));var i;(function(e){e.method=`textDocument/moniker`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.MonikerRequest=i={}))}}),Yt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TypeHierarchySubtypesRequest=e.TypeHierarchySupertypesRequest=e.TypeHierarchyPrepareRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/prepareTypeHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`typeHierarchy/supertypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.TypeHierarchySupertypesRequest=r={}));var i;(function(e){e.method=`typeHierarchy/subtypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.TypeHierarchySubtypesRequest=i={}))}}),Xt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.InlineValueRefreshRequest=e.InlineValueRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/inlineValue`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlineValueRequest=n={}));var r;(function(e){e.method=`workspace/inlineValue/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.InlineValueRefreshRequest=r={}))}}),Zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.InlayHintRefreshRequest=e.InlayHintResolveRequest=e.InlayHintRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/inlayHint`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlayHintRequest=n={}));var r;(function(e){e.method=`inlayHint/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.InlayHintResolveRequest=r={}));var i;(function(e){e.method=`workspace/inlayHint/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(i||(e.InlayHintRefreshRequest=i={}))}}),Qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DiagnosticRefreshRequest=e.WorkspaceDiagnosticRequest=e.DocumentDiagnosticRequest=e.DocumentDiagnosticReportKind=e.DiagnosticServerCancellationData=void 0;var t=jt(),n=Nt(),r=j(),i;(function(e){function t(e){let t=e;return t&&n.boolean(t.retriggerRequest)}o(t,`is`),e.is=t})(i||(e.DiagnosticServerCancellationData=i={}));var a;(function(e){e.Full=`full`,e.Unchanged=`unchanged`})(a||(e.DocumentDiagnosticReportKind=a={}));var s;(function(e){e.method=`textDocument/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(s||(e.DocumentDiagnosticRequest=s={}));var c;(function(e){e.method=`workspace/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(c||(e.WorkspaceDiagnosticRequest=c={}));var l;(function(e){e.method=`workspace/diagnostic/refresh`,e.messageDirection=r.MessageDirection.serverToClient,e.type=new r.ProtocolRequestType0(e.method)})(l||(e.DiagnosticRefreshRequest=l={}))}}),$t=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DidCloseNotebookDocumentNotification=e.DidSaveNotebookDocumentNotification=e.DidChangeNotebookDocumentNotification=e.NotebookCellArrayChange=e.DidOpenNotebookDocumentNotification=e.NotebookDocumentSyncRegistrationType=e.NotebookDocument=e.NotebookCell=e.ExecutionSummary=e.NotebookCellKind=void 0;var t=(ht(),p(m)),n=Nt(),r=j(),i;(function(e){e.Markup=1,e.Code=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(i||(e.NotebookCellKind=i={}));var a;(function(e){function r(e,t){let n={executionOrder:e};return(t===!0||t===!1)&&(n.success=t),n}o(r,`create`),e.create=r;function i(e){let r=e;return n.objectLiteral(r)&&t.uinteger.is(r.executionOrder)&&(r.success===void 0||n.boolean(r.success))}o(i,`is`),e.is=i;function a(e,t){return e===t?!0:e==null||t==null?!1:e.executionOrder===t.executionOrder&&e.success===t.success}o(a,`equals`),e.equals=a})(a||(e.ExecutionSummary=a={}));var s;(function(e){function r(e,t){return{kind:e,document:t}}o(r,`create`),e.create=r;function s(e){let r=e;return n.objectLiteral(r)&&i.is(r.kind)&&t.DocumentUri.is(r.document)&&(r.metadata===void 0||n.objectLiteral(r.metadata))}o(s,`is`),e.is=s;function c(e,t){let n=new Set;return e.document!==t.document&&n.add(`document`),e.kind!==t.kind&&n.add(`kind`),e.executionSummary!==t.executionSummary&&n.add(`executionSummary`),(e.metadata!==void 0||t.metadata!==void 0)&&!l(e.metadata,t.metadata)&&n.add(`metadata`),(e.executionSummary!==void 0||t.executionSummary!==void 0)&&!a.equals(e.executionSummary,t.executionSummary)&&n.add(`executionSummary`),n}o(c,`diff`),e.diff=c;function l(e,t){if(e===t)return!0;if(e==null||t==null||typeof e!=typeof t||typeof e!=`object`)return!1;let r=Array.isArray(e),i=Array.isArray(t);if(r!==i)return!1;if(r&&i){if(e.length!==t.length)return!1;for(let n=0;n0}o(t,`hasId`),e.hasId=t})(T||(e.StaticRegistrationOptions=T={}));var E;(function(e){function t(e){let t=e;return t&&(t.documentSelector===null||se.is(t.documentSelector))}o(t,`is`),e.is=t})(E||(e.TextDocumentRegistrationOptions=E={}));var D;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(t.workDoneProgress===void 0||r.boolean(t.workDoneProgress))}o(t,`is`),e.is=t;function n(e){let t=e;return t&&r.boolean(t.workDoneProgress)}o(n,`hasWorkDoneProgress`),e.hasWorkDoneProgress=n})(D||(e.WorkDoneProgressOptions=D={}));var O;(function(e){e.method=`initialize`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(O||(e.InitializeRequest=O={}));var fe;(function(e){e.unknownProtocolVersion=1})(fe||(e.InitializeErrorCodes=fe={}));var k;(function(e){e.method=`initialized`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(k||(e.InitializedNotification=k={}));var pe;(function(e){e.method=`shutdown`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType0(e.method)})(pe||(e.ShutdownRequest=pe={}));var me;(function(e){e.method=`exit`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType0(e.method)})(me||(e.ExitNotification=me={}));var he;(function(e){e.method=`workspace/didChangeConfiguration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(he||(e.DidChangeConfigurationNotification=he={}));var ge;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4,e.Debug=5})(ge||(e.MessageType=ge={}));var _e;(function(e){e.method=`window/showMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(_e||(e.ShowMessageNotification=_e={}));var ve;(function(e){e.method=`window/showMessageRequest`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(ve||(e.ShowMessageRequest=ve={}));var ye;(function(e){e.method=`window/logMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(ye||(e.LogMessageNotification=ye={}));var be;(function(e){e.method=`telemetry/event`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(be||(e.TelemetryEventNotification=be={}));var xe;(function(e){e.None=0,e.Full=1,e.Incremental=2})(xe||(e.TextDocumentSyncKind=xe={}));var Se;(function(e){e.method=`textDocument/didOpen`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Se||(e.DidOpenTextDocumentNotification=Se={}));var Ce;(function(e){function t(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}o(t,`isIncremental`),e.isIncremental=t;function n(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}o(n,`isFull`),e.isFull=n})(Ce||(e.TextDocumentContentChangeEvent=Ce={}));var we;(function(e){e.method=`textDocument/didChange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(we||(e.DidChangeTextDocumentNotification=we={}));var Te;(function(e){e.method=`textDocument/didClose`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Te||(e.DidCloseTextDocumentNotification=Te={}));var Ee;(function(e){e.method=`textDocument/didSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ee||(e.DidSaveTextDocumentNotification=Ee={}));var De;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(De||(e.TextDocumentSaveReason=De={}));var Oe;(function(e){e.method=`textDocument/willSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Oe||(e.WillSaveTextDocumentNotification=Oe={}));var ke;(function(e){e.method=`textDocument/willSaveWaitUntil`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ke||(e.WillSaveTextDocumentWaitUntilRequest=ke={}));var Ae;(function(e){e.method=`workspace/didChangeWatchedFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ae||(e.DidChangeWatchedFilesNotification=Ae={}));var je;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(je||(e.FileChangeType=je={}));var Me;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(n.URI.is(t.baseUri)||n.WorkspaceFolder.is(t.baseUri))&&r.string(t.pattern)}o(t,`is`),e.is=t})(Me||(e.RelativePattern=Me={}));var Ne;(function(e){e.Create=1,e.Change=2,e.Delete=4})(Ne||(e.WatchKind=Ne={}));var Pe;(function(e){e.method=`textDocument/publishDiagnostics`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(Pe||(e.PublishDiagnosticsNotification=Pe={}));var Fe;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(Fe||(e.CompletionTriggerKind=Fe={}));var Ie;(function(e){e.method=`textDocument/completion`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ie||(e.CompletionRequest=Ie={}));var Le;(function(e){e.method=`completionItem/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Le||(e.CompletionResolveRequest=Le={}));var Re;(function(e){e.method=`textDocument/hover`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Re||(e.HoverRequest=Re={}));var ze;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(ze||(e.SignatureHelpTriggerKind=ze={}));var Be;(function(e){e.method=`textDocument/signatureHelp`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Be||(e.SignatureHelpRequest=Be={}));var Ve;(function(e){e.method=`textDocument/definition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ve||(e.DefinitionRequest=Ve={}));var He;(function(e){e.method=`textDocument/references`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(He||(e.ReferencesRequest=He={}));var Ue;(function(e){e.method=`textDocument/documentHighlight`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ue||(e.DocumentHighlightRequest=Ue={}));var We;(function(e){e.method=`textDocument/documentSymbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(We||(e.DocumentSymbolRequest=We={}));var Ge;(function(e){e.method=`textDocument/codeAction`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ge||(e.CodeActionRequest=Ge={}));var Ke;(function(e){e.method=`codeAction/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ke||(e.CodeActionResolveRequest=Ke={}));var qe;(function(e){e.method=`workspace/symbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(qe||(e.WorkspaceSymbolRequest=qe={}));var Je;(function(e){e.method=`workspaceSymbol/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Je||(e.WorkspaceSymbolResolveRequest=Je={}));var Ye;(function(e){e.method=`textDocument/codeLens`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ye||(e.CodeLensRequest=Ye={}));var Xe;(function(e){e.method=`codeLens/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Xe||(e.CodeLensResolveRequest=Xe={}));var Ze;(function(e){e.method=`workspace/codeLens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(Ze||(e.CodeLensRefreshRequest=Ze={}));var Qe;(function(e){e.method=`textDocument/documentLink`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Qe||(e.DocumentLinkRequest=Qe={}));var $e;(function(e){e.method=`documentLink/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})($e||(e.DocumentLinkResolveRequest=$e={}));var et;(function(e){e.method=`textDocument/formatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(et||(e.DocumentFormattingRequest=et={}));var tt;(function(e){e.method=`textDocument/rangeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(tt||(e.DocumentRangeFormattingRequest=tt={}));var nt;(function(e){e.method=`textDocument/rangesFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(nt||(e.DocumentRangesFormattingRequest=nt={}));var rt;(function(e){e.method=`textDocument/onTypeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(rt||(e.DocumentOnTypeFormattingRequest=rt={}));var it;(function(e){e.Identifier=1})(it||(e.PrepareSupportDefaultBehavior=it={}));var at;(function(e){e.method=`textDocument/rename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(at||(e.RenameRequest=at={}));var ot;(function(e){e.method=`textDocument/prepareRename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ot||(e.PrepareRenameRequest=ot={}));var st;(function(e){e.method=`workspace/executeCommand`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(st||(e.ExecuteCommandRequest=st={}));var ct;(function(e){e.method=`workspace/applyEdit`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(`workspace/applyEdit`)})(ct||(e.ApplyWorkspaceEditRequest=ct={}))}}),nn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/connection.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createProtocolConnection=void 0;var t=jt();function n(e,n,r,i){return t.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,t.createMessageConnection)(e,n,r,i)}o(n,`createProtocolConnection`),e.createProtocolConnection=n}}),rn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/api.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.LSPErrorCodes=e.createProtocolConnection=void 0,n(jt(),e),n((ht(),p(m)),e),n(j(),e),n(tn(),e);var r=nn();Object.defineProperty(e,"createProtocolConnection",{enumerable:!0,get:o(function(){return r.createProtocolConnection},`get`)});var i;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(i||(e.LSPErrorCodes=i={}))}}),an=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.createProtocolConnection=void 0;var r=Mt();n(Mt(),e),n(rn(),e);function i(e,t,n,i){return(0,r.createMessageConnection)(e,t,n,i)}o(i,`createProtocolConnection`),e.createProtocolConnection=i}}),on={};l(on,{AbstractAstReflection:()=>fn,AbstractCstNode:()=>ZA,AbstractLangiumParser:()=>oj,AbstractParserErrorMessageProvider:()=>cj,AbstractThreadedAsyncParser:()=>AN,AstUtils:()=>Cn,BiMap:()=>pM,Cancellation:()=>Z,CompositeCstNodeImpl:()=>$A,ContextCache:()=>xM,CstNodeBuilder:()=>XA,CstUtils:()=>sn,DEFAULT_TOKENIZE_OPTIONS:()=>YM,DONE_RESULT:()=>bn,DatatypeSymbol:()=>nj,DefaultAstNodeDescriptionProvider:()=>RM,DefaultAstNodeLocator:()=>BM,DefaultAsyncParser:()=>kN,DefaultCommentProvider:()=>ON,DefaultConfigurationProvider:()=>HM,DefaultDocumentBuilder:()=>GM,DefaultDocumentValidator:()=>NM,DefaultHydrator:()=>NN,DefaultIndexManager:()=>KM,DefaultJsonSerializer:()=>DM,DefaultLangiumDocumentFactory:()=>aM,DefaultLangiumDocuments:()=>oM,DefaultLangiumProfiler:()=>tP,DefaultLexer:()=>XM,DefaultLexerErrorMessageProvider:()=>JM,DefaultLinker:()=>cM,DefaultNameProvider:()=>uM,DefaultReferenceDescriptionProvider:()=>zM,DefaultReferences:()=>dM,DefaultScopeComputation:()=>mM,DefaultScopeProvider:()=>wM,DefaultServiceRegistry:()=>OM,DefaultTokenBuilder:()=>Fj,DefaultValueConverter:()=>Ij,DefaultWorkspaceLock:()=>MN,DefaultWorkspaceManager:()=>qM,Deferred:()=>Kj,Disposable:()=>WM,DisposableCache:()=>yM,DocumentCache:()=>SM,DocumentState:()=>Q,DocumentValidator:()=>LM,EMPTY_SCOPE:()=>vM,EMPTY_STREAM:()=>yn,EmptyFileSystem:()=>XN,EmptyFileSystemProvider:()=>YN,ErrorWithLocation:()=>ia,GrammarAST:()=>Rn,GrammarUtils:()=>ra,IndentationAwareLexer:()=>qN,IndentationAwareTokenBuilder:()=>KN,JSDocDocumentationProvider:()=>DN,LangiumCompletionParser:()=>uj,LangiumParser:()=>sj,LangiumParserErrorMessageProvider:()=>lj,LeafCstNodeImpl:()=>QA,LexingMode:()=>GN,MapScope:()=>gM,Module:()=>IN,MultiMap:()=>fM,MultiMapScope:()=>_M,OperationCancelled:()=>Uj,ParserWorker:()=>jN,ProfilingTask:()=>nP,Reduction:()=>Sn,RefResolving:()=>sM,RegExpUtils:()=>sa,RootCstNodeImpl:()=>tj,SimpleCache:()=>bM,StreamImpl:()=>gn,StreamScope:()=>hM,TextDocument:()=>Jj,TreeStreamImpl:()=>xn,URI:()=>tM,UriTrie:()=>iM,UriUtils:()=>rM,VALIDATE_EACH_NODE:()=>MM,ValidationCategory:()=>AM,ValidationRegistry:()=>jM,ValueConverter:()=>Lj,WorkspaceCache:()=>CM,assertCondition:()=>oa,assertUnreachable:()=>aa,createCompletionParser:()=>Mj,createDefaultCoreModule:()=>PN,createDefaultSharedCoreModule:()=>FN,createGrammarConfig:()=>_o,createLangiumParser:()=>Nj,createParser:()=>mj,delayNextTick:()=>Rj,diagnosticData:()=>kM,eagerLoad:()=>zN,getDiagnosticRange:()=>PM,indentationBuilderDefaultOptions:()=>WN,inject:()=>LN,interruptAndCheck:()=>Gj,isAstNode:()=>M,isAstNodeDescription:()=>un,isAstNodeWithComment:()=>TM,isCompositeCstNode:()=>pn,isIMultiModeLexerDefinition:()=>QM,isJSDoc:()=>tN,isLeafCstNode:()=>mn,isLinkingError:()=>dn,isMultiReference:()=>ln,isNamed:()=>lM,isOperationCancelled:()=>Wj,isReference:()=>cn,isRootCstNode:()=>hn,isTokenTypeArray:()=>ZM,isTokenTypeDictionary:()=>$M,loadGrammarFromJson:()=>eP,parseJSDoc:()=>eN,prepareLangiumParser:()=>Pj,setInterruptionPeriod:()=>Hj,startCancelableOperation:()=>Vj,stream:()=>N,toDiagnosticData:()=>IM,toDiagnosticSeverity:()=>FM});var sn={};l(sn,{DefaultNameRegexp:()=>Wi,RangeComparison:()=>Vi,compareRange:()=>Hi,findCommentNode:()=>Ki,findDeclarationNodeAtOffset:()=>Gi,findLeafNodeAtOffset:()=>Ji,findLeafNodeBeforeOffset:()=>Yi,flattenCst:()=>Li,getDatatypeNode:()=>Fi,getInteriorNodes:()=>ea,getNextNode:()=>Qi,getPreviousNode:()=>Zi,getStartlineNode:()=>$i,inRange:()=>Ui,isChildNode:()=>Ri,isCommentNode:()=>qi,streamCst:()=>Ii,toDocumentSegment:()=>Bi,tokenToRange:()=>zi});function M(e){return typeof e==`object`&&!!e&&typeof e.$type==`string`}o(M,`isAstNode`);function cn(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`ref`in e}o(cn,`isReference`);function ln(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`items`in e}o(ln,`isMultiReference`);function un(e){return typeof e==`object`&&!!e&&typeof e.name==`string`&&typeof e.type==`string`&&typeof e.path==`string`}o(un,`isAstNodeDescription`);function dn(e){return typeof e==`object`&&!!e&&typeof e.info==`object`&&typeof e.message==`string`}o(dn,`isLinkingError`);var fn=class{static{o(this,`AbstractAstReflection`)}constructor(){this.subtypes={},this.allSubtypes={}}getAllTypes(){return Object.keys(this.types)}getReferenceType(e){let t=this.types[e.container.$type];if(!t)throw Error(`Type ${e.container.$type||`undefined`} not found.`);let n=t.properties[e.property]?.referenceType;if(!n)throw Error(`Property ${e.property||`undefined`} of type ${e.container.$type} is not a reference.`);return n}getTypeMetaData(e){return this.types[e]||{name:e,properties:{},superTypes:[]}}isInstance(e,t){return M(e)&&this.isSubtype(e.$type,t)}isSubtype(e,t){if(e===t)return!0;let n=this.subtypes[e];n||=this.subtypes[e]={};let r=n[t];if(r!==void 0)return r;{let r=this.types[e],i=r?r.superTypes.some(e=>this.isSubtype(e,t)):!1;return n[t]=i,i}}getAllSubTypes(e){let t=this.allSubtypes[e];if(t)return t;{let t=this.getAllTypes(),n=[];for(let r of t)this.isSubtype(r,e)&&n.push(r);return this.allSubtypes[e]=n,n}}};function pn(e){return typeof e==`object`&&!!e&&Array.isArray(e.content)}o(pn,`isCompositeCstNode`);function mn(e){return typeof e==`object`&&!!e&&typeof e.tokenType==`object`}o(mn,`isLeafCstNode`);function hn(e){return pn(e)&&typeof e.fullText==`string`}o(hn,`isRootCstNode`);var gn=class e{static{o(this,`StreamImpl`)}constructor(e,t){this.startFn=e,this.nextFn=t}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),[Symbol.iterator]:()=>e};return e}[Symbol.iterator](){return this.iterator()}isEmpty(){return!!this.iterator().next().done}count(){let e=this.iterator(),t=0,n=e.next();for(;!n.done;)t++,n=e.next();return t}toArray(){let e=[],t=this.iterator(),n;do n=t.next(),n.value!==void 0&&e.push(n.value);while(!n.done);return e}toSet(){return new Set(this)}toMap(e,t){let n=this.map(n=>[e?e(n):n,t?t(n):n]);return new Map(n)}toString(){return this.join()}concat(t){return new e(()=>({first:this.startFn(),firstDone:!1,iterator:t[Symbol.iterator]()}),e=>{let t;if(!e.firstDone){do if(t=this.nextFn(e.first),!t.done)return t;while(!t.done);e.firstDone=!0}do if(t=e.iterator.next(),!t.done)return t;while(!t.done);return bn})}join(e=`,`){let t=this.iterator(),n=``,r,i=!1;do r=t.next(),r.done||(i&&(n+=e),n+=_n(r.value)),i=!0;while(!r.done);return n}indexOf(e,t=0){let n=this.iterator(),r=0,i=n.next();for(;!i.done;){if(r>=t&&i.value===e)return r;i=n.next(),r++}return-1}every(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(!e(n.value))return!1;n=t.next()}return!0}some(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return!0;n=t.next()}return!1}forEach(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;)e(r.value,n),r=t.next(),n++}map(t){return new e(this.startFn,e=>{let{done:n,value:r}=this.nextFn(e);return n?bn:{done:!1,value:t(r)}})}filter(t){return new e(this.startFn,e=>{let n;do if(n=this.nextFn(e),!n.done&&t(n.value))return n;while(!n.done);return bn})}nonNullable(){return this.filter(e=>e!=null)}reduce(e,t){let n=this.iterator(),r=t,i=n.next();for(;!i.done;)r=r===void 0?i.value:e(r,i.value),i=n.next();return r}reduceRight(e,t){return this.recursiveReduce(this.iterator(),e,t)}recursiveReduce(e,t,n){let r=e.next();if(r.done)return n;let i=this.recursiveReduce(e,t,n);return i===void 0?r.value:t(i,r.value)}find(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return n.value;n=t.next()}}findIndex(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;){if(e(r.value))return n;r=t.next(),n++}return-1}includes(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(n.value===e)return!0;n=t.next()}return!1}flatMap(t){return new e(()=>({this:this.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:n,value:r}=this.nextFn(e.this);if(!n){let n=t(r);if(vn(n))e.iterator=n[Symbol.iterator]();else return{done:!1,value:n}}}while(e.iterator);return bn})}flat(t){if(t===void 0&&(t=1),t<=0)return this;let n=t>1?this.flat(t-1):this;return new e(()=>({this:n.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:t,value:r}=n.nextFn(e.this);if(!t){if(vn(r))e.iterator=r[Symbol.iterator]();else return{done:!1,value:r}}}while(e.iterator);return bn})}head(){let e=this.iterator().next();if(!e.done)return e.value}tail(t=1){return new e(()=>{let e=this.startFn();for(let n=0;n({size:0,state:this.startFn()}),e=>(e.size++,e.size>t?bn:this.nextFn(e.state)))}distinct(t){return new e(()=>({set:new Set,internalState:this.startFn()}),e=>{let n;do if(n=this.nextFn(e.internalState),!n.done){let r=t?t(n.value):n.value;if(!e.set.has(r))return e.set.add(r),n}while(!n.done);return bn})}exclude(e,t){let n=new Set;for(let r of e){let e=t?t(r):r;n.add(e)}return this.filter(e=>{let r=t?t(e):e;return!n.has(r)})}};function _n(e){return typeof e==`string`?e:e===void 0?`undefined`:typeof e.toString==`function`?e.toString():Object.prototype.toString.call(e)}o(_n,`toString`);function vn(e){return!!e&&typeof e[Symbol.iterator]==`function`}o(vn,`isIterable`);var yn=new gn(()=>void 0,()=>bn),bn=Object.freeze({done:!0,value:void 0});function N(...e){if(e.length===1){let t=e[0];if(t instanceof gn)return t;if(vn(t))return new gn(()=>t[Symbol.iterator](),e=>e.next());if(typeof t.length==`number`)return new gn(()=>({index:0}),e=>e.index1?new gn(()=>({collIndex:0,arrIndex:0}),t=>{do{if(t.iterator){let e=t.iterator.next();if(!e.done)return e;t.iterator=void 0}if(t.array){if(t.arrIndex({iterators:n?.includeRoot?[[e][Symbol.iterator]()]:[t(e)[Symbol.iterator]()],pruned:!1}),e=>{for(e.pruned&&=(e.iterators.pop(),!1);e.iterators.length>0;){let n=e.iterators[e.iterators.length-1].next();if(n.done)e.iterators.pop();else return e.iterators.push(t(n.value)[Symbol.iterator]()),n}return bn})}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),prune:o(()=>{e.state.pruned=!0},`prune`),[Symbol.iterator]:()=>e};return e}},Sn;(function(e){function t(e){return e.reduce((e,t)=>e+t,0)}o(t,`sum`),e.sum=t;function n(e){return e.reduce((e,t)=>e*t,0)}o(n,`product`),e.product=n;function r(e){return e.reduce((e,t)=>Math.min(e,t))}o(r,`min`),e.min=r;function i(e){return e.reduce((e,t)=>Math.max(e,t))}o(i,`max`),e.max=i})(Sn||={});var Cn={};l(Cn,{assignMandatoryProperties:()=>Fn,copyAstNode:()=>Ln,findRootNode:()=>On,getContainerOfType:()=>Tn,getDocument:()=>Dn,getReferenceNodes:()=>kn,hasContainerOfType:()=>En,linkContentToContainer:()=>wn,streamAllContents:()=>jn,streamAst:()=>Mn,streamContents:()=>An,streamReferences:()=>Pn});function wn(e,t={}){for(let[n,r]of Object.entries(e))n.startsWith(`$`)||(Array.isArray(r)?r.forEach((r,i)=>{M(r)&&(r.$container=e,r.$containerProperty=n,r.$containerIndex=i,t.deep&&wn(r,t))}):M(r)&&(r.$container=e,r.$containerProperty=n,t.deep&&wn(r,t)))}o(wn,`linkContentToContainer`);function Tn(e,t){let n=e;for(;n;){if(t(n))return n;n=n.$container}}o(Tn,`getContainerOfType`);function En(e,t){let n=e;for(;n;){if(t(n))return!0;n=n.$container}return!1}o(En,`hasContainerOfType`);function Dn(e){let t=On(e).$document;if(!t)throw Error(`AST node has no document.`);return t}o(Dn,`getDocument`);function On(e){for(;e.$container;)e=e.$container;return e}o(On,`findRootNode`);function kn(e){return cn(e)?e.ref?[e.ref]:[]:ln(e)?e.items.map(e=>e.ref):[]}o(kn,`getReferenceNodes`);function An(e,t){if(!e)throw Error(`Node must be an AstNode.`);let n=t?.range;return new gn(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndexAn(e,t))}o(jn,`streamAllContents`);function Mn(e,t){if(!e)throw Error(`Root node must be an AstNode.`);return t?.range&&!Nn(e,t.range)?new xn(e,()=>[]):new xn(e,e=>An(e,t),{includeRoot:!0})}o(Mn,`streamAst`);function Nn(e,t){if(!t)return!0;let n=e.$cstNode?.range;return n?Ui(n,t):!1}o(Nn,`isAstNodeInRange`);function Pn(e){return new gn(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndexBn,AbstractParserRule:()=>Hn,AbstractRule:()=>Wn,AbstractType:()=>Kn,Action:()=>Jn,Alternatives:()=>Xn,ArrayLiteral:()=>Qn,ArrayType:()=>er,Assignment:()=>nr,BooleanLiteral:()=>ir,CharacterRange:()=>or,Condition:()=>cr,Conjunction:()=>ur,CrossReference:()=>fr,Disjunction:()=>mr,EndOfFile:()=>gr,Grammar:()=>vr,GrammarImport:()=>br,Group:()=>Sr,InferredType:()=>wr,InfixRule:()=>Er,InfixRuleOperatorList:()=>Or,InfixRuleOperators:()=>Ar,Interface:()=>Mr,Keyword:()=>Pr,LangiumGrammarAstReflection:()=>Pi,LangiumGrammarTerminals:()=>zn,NamedArgument:()=>Ir,NegatedToken:()=>Rr,Negation:()=>Br,NumberLiteral:()=>Hr,Parameter:()=>Wr,ParameterReference:()=>Kr,ParserRule:()=>Jr,ReferenceType:()=>Xr,RegexToken:()=>Qr,ReturnType:()=>ei,RuleCall:()=>ni,SimpleType:()=>ii,StringLiteral:()=>oi,TerminalAlternatives:()=>ci,TerminalElement:()=>ui,TerminalGroup:()=>fi,TerminalRule:()=>mi,TerminalRuleCall:()=>gi,Type:()=>vi,TypeAttribute:()=>bi,TypeDefinition:()=>Si,UnionType:()=>wi,UnorderedGroup:()=>Ei,UntilToken:()=>Oi,ValueLiteral:()=>Ai,Wildcard:()=>Mi,isAbstractElement:()=>Vn,isAbstractParserRule:()=>Un,isAbstractRule:()=>Gn,isAbstractType:()=>qn,isAction:()=>Yn,isAlternatives:()=>Zn,isArrayLiteral:()=>$n,isArrayType:()=>tr,isAssignment:()=>rr,isBooleanLiteral:()=>ar,isCharacterRange:()=>sr,isCondition:()=>lr,isConjunction:()=>dr,isCrossReference:()=>pr,isDisjunction:()=>hr,isEndOfFile:()=>_r,isGrammar:()=>yr,isGrammarImport:()=>xr,isGroup:()=>Cr,isInferredType:()=>Tr,isInfixRule:()=>Dr,isInfixRuleOperatorList:()=>kr,isInfixRuleOperators:()=>jr,isInterface:()=>Nr,isKeyword:()=>Fr,isNamedArgument:()=>Lr,isNegatedToken:()=>zr,isNegation:()=>Vr,isNumberLiteral:()=>Ur,isParameter:()=>Gr,isParameterReference:()=>qr,isParserRule:()=>Yr,isReferenceType:()=>Zr,isRegexToken:()=>$r,isReturnType:()=>ti,isRuleCall:()=>ri,isSimpleType:()=>ai,isStringLiteral:()=>si,isTerminalAlternatives:()=>li,isTerminalElement:()=>di,isTerminalGroup:()=>pi,isTerminalRule:()=>hi,isTerminalRuleCall:()=>_i,isType:()=>yi,isTypeAttribute:()=>xi,isTypeDefinition:()=>Ci,isUnionType:()=>Ti,isUnorderedGroup:()=>Di,isUntilToken:()=>ki,isValueLiteral:()=>ji,isWildcard:()=>Ni,reflection:()=>P});var zn={ID:/\^?[_a-zA-Z][\w_]*/,STRING:/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'/,NUMBER:/NaN|-?((\d*\.\d+|\d+)([Ee][+-]?\d+)?|Infinity)/,RegexLiteral:/\/(?![*+?])(?:[^\r\n\[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*\])+\/[a-z]*/,WS:/\s+/,ML_COMMENT:/\/\*[\s\S]*?\*\//,SL_COMMENT:/\/\/[^\n\r]*/},Bn={$type:`AbstractElement`,cardinality:`cardinality`};function Vn(e){return P.isInstance(e,Bn.$type)}o(Vn,`isAbstractElement`);var Hn={$type:`AbstractParserRule`};function Un(e){return P.isInstance(e,Hn.$type)}o(Un,`isAbstractParserRule`);var Wn={$type:`AbstractRule`};function Gn(e){return P.isInstance(e,Wn.$type)}o(Gn,`isAbstractRule`);var Kn={$type:`AbstractType`};function qn(e){return P.isInstance(e,Kn.$type)}o(qn,`isAbstractType`);var Jn={$type:`Action`,cardinality:`cardinality`,feature:`feature`,inferredType:`inferredType`,operator:`operator`,type:`type`};function Yn(e){return P.isInstance(e,Jn.$type)}o(Yn,`isAction`);var Xn={$type:`Alternatives`,cardinality:`cardinality`,elements:`elements`};function Zn(e){return P.isInstance(e,Xn.$type)}o(Zn,`isAlternatives`);var Qn={$type:`ArrayLiteral`,elements:`elements`};function $n(e){return P.isInstance(e,Qn.$type)}o($n,`isArrayLiteral`);var er={$type:`ArrayType`,elementType:`elementType`};function tr(e){return P.isInstance(e,er.$type)}o(tr,`isArrayType`);var nr={$type:`Assignment`,cardinality:`cardinality`,feature:`feature`,operator:`operator`,predicate:`predicate`,terminal:`terminal`};function rr(e){return P.isInstance(e,nr.$type)}o(rr,`isAssignment`);var ir={$type:`BooleanLiteral`,true:`true`};function ar(e){return P.isInstance(e,ir.$type)}o(ar,`isBooleanLiteral`);var or={$type:`CharacterRange`,cardinality:`cardinality`,left:`left`,lookahead:`lookahead`,parenthesized:`parenthesized`,right:`right`};function sr(e){return P.isInstance(e,or.$type)}o(sr,`isCharacterRange`);var cr={$type:`Condition`};function lr(e){return P.isInstance(e,cr.$type)}o(lr,`isCondition`);var ur={$type:`Conjunction`,left:`left`,right:`right`};function dr(e){return P.isInstance(e,ur.$type)}o(dr,`isConjunction`);var fr={$type:`CrossReference`,cardinality:`cardinality`,deprecatedSyntax:`deprecatedSyntax`,isMulti:`isMulti`,terminal:`terminal`,type:`type`};function pr(e){return P.isInstance(e,fr.$type)}o(pr,`isCrossReference`);var mr={$type:`Disjunction`,left:`left`,right:`right`};function hr(e){return P.isInstance(e,mr.$type)}o(hr,`isDisjunction`);var gr={$type:`EndOfFile`,cardinality:`cardinality`};function _r(e){return P.isInstance(e,gr.$type)}o(_r,`isEndOfFile`);var vr={$type:`Grammar`,imports:`imports`,interfaces:`interfaces`,isDeclared:`isDeclared`,name:`name`,rules:`rules`,types:`types`};function yr(e){return P.isInstance(e,vr.$type)}o(yr,`isGrammar`);var br={$type:`GrammarImport`,path:`path`};function xr(e){return P.isInstance(e,br.$type)}o(xr,`isGrammarImport`);var Sr={$type:`Group`,cardinality:`cardinality`,elements:`elements`,guardCondition:`guardCondition`,predicate:`predicate`};function Cr(e){return P.isInstance(e,Sr.$type)}o(Cr,`isGroup`);var wr={$type:`InferredType`,name:`name`};function Tr(e){return P.isInstance(e,wr.$type)}o(Tr,`isInferredType`);var Er={$type:`InfixRule`,call:`call`,dataType:`dataType`,inferredType:`inferredType`,name:`name`,operators:`operators`,parameters:`parameters`,returnType:`returnType`};function Dr(e){return P.isInstance(e,Er.$type)}o(Dr,`isInfixRule`);var Or={$type:`InfixRuleOperatorList`,associativity:`associativity`,operators:`operators`};function kr(e){return P.isInstance(e,Or.$type)}o(kr,`isInfixRuleOperatorList`);var Ar={$type:`InfixRuleOperators`,precedences:`precedences`};function jr(e){return P.isInstance(e,Ar.$type)}o(jr,`isInfixRuleOperators`);var Mr={$type:`Interface`,attributes:`attributes`,name:`name`,superTypes:`superTypes`};function Nr(e){return P.isInstance(e,Mr.$type)}o(Nr,`isInterface`);var Pr={$type:`Keyword`,cardinality:`cardinality`,predicate:`predicate`,value:`value`};function Fr(e){return P.isInstance(e,Pr.$type)}o(Fr,`isKeyword`);var Ir={$type:`NamedArgument`,calledByName:`calledByName`,parameter:`parameter`,value:`value`};function Lr(e){return P.isInstance(e,Ir.$type)}o(Lr,`isNamedArgument`);var Rr={$type:`NegatedToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function zr(e){return P.isInstance(e,Rr.$type)}o(zr,`isNegatedToken`);var Br={$type:`Negation`,value:`value`};function Vr(e){return P.isInstance(e,Br.$type)}o(Vr,`isNegation`);var Hr={$type:`NumberLiteral`,value:`value`};function Ur(e){return P.isInstance(e,Hr.$type)}o(Ur,`isNumberLiteral`);var Wr={$type:`Parameter`,name:`name`};function Gr(e){return P.isInstance(e,Wr.$type)}o(Gr,`isParameter`);var Kr={$type:`ParameterReference`,parameter:`parameter`};function qr(e){return P.isInstance(e,Kr.$type)}o(qr,`isParameterReference`);var Jr={$type:`ParserRule`,dataType:`dataType`,definition:`definition`,entry:`entry`,fragment:`fragment`,inferredType:`inferredType`,name:`name`,parameters:`parameters`,returnType:`returnType`};function Yr(e){return P.isInstance(e,Jr.$type)}o(Yr,`isParserRule`);var Xr={$type:`ReferenceType`,isMulti:`isMulti`,referenceType:`referenceType`};function Zr(e){return P.isInstance(e,Xr.$type)}o(Zr,`isReferenceType`);var Qr={$type:`RegexToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,regex:`regex`};function $r(e){return P.isInstance(e,Qr.$type)}o($r,`isRegexToken`);var ei={$type:`ReturnType`,name:`name`};function ti(e){return P.isInstance(e,ei.$type)}o(ti,`isReturnType`);var ni={$type:`RuleCall`,arguments:`arguments`,cardinality:`cardinality`,predicate:`predicate`,rule:`rule`};function ri(e){return P.isInstance(e,ni.$type)}o(ri,`isRuleCall`);var ii={$type:`SimpleType`,primitiveType:`primitiveType`,stringType:`stringType`,typeRef:`typeRef`};function ai(e){return P.isInstance(e,ii.$type)}o(ai,`isSimpleType`);var oi={$type:`StringLiteral`,value:`value`};function si(e){return P.isInstance(e,oi.$type)}o(si,`isStringLiteral`);var ci={$type:`TerminalAlternatives`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function li(e){return P.isInstance(e,ci.$type)}o(li,`isTerminalAlternatives`);var ui={$type:`TerminalElement`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function di(e){return P.isInstance(e,ui.$type)}o(di,`isTerminalElement`);var fi={$type:`TerminalGroup`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function pi(e){return P.isInstance(e,fi.$type)}o(pi,`isTerminalGroup`);var mi={$type:`TerminalRule`,definition:`definition`,fragment:`fragment`,hidden:`hidden`,name:`name`,type:`type`};function hi(e){return P.isInstance(e,mi.$type)}o(hi,`isTerminalRule`);var gi={$type:`TerminalRuleCall`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,rule:`rule`};function _i(e){return P.isInstance(e,gi.$type)}o(_i,`isTerminalRuleCall`);var vi={$type:`Type`,name:`name`,type:`type`};function yi(e){return P.isInstance(e,vi.$type)}o(yi,`isType`);var bi={$type:`TypeAttribute`,defaultValue:`defaultValue`,isOptional:`isOptional`,name:`name`,type:`type`};function xi(e){return P.isInstance(e,bi.$type)}o(xi,`isTypeAttribute`);var Si={$type:`TypeDefinition`};function Ci(e){return P.isInstance(e,Si.$type)}o(Ci,`isTypeDefinition`);var wi={$type:`UnionType`,types:`types`};function Ti(e){return P.isInstance(e,wi.$type)}o(Ti,`isUnionType`);var Ei={$type:`UnorderedGroup`,cardinality:`cardinality`,elements:`elements`};function Di(e){return P.isInstance(e,Ei.$type)}o(Di,`isUnorderedGroup`);var Oi={$type:`UntilToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function ki(e){return P.isInstance(e,Oi.$type)}o(ki,`isUntilToken`);var Ai={$type:`ValueLiteral`};function ji(e){return P.isInstance(e,Ai.$type)}o(ji,`isValueLiteral`);var Mi={$type:`Wildcard`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function Ni(e){return P.isInstance(e,Mi.$type)}o(Ni,`isWildcard`);var Pi=class extends fn{static{o(this,`LangiumGrammarAstReflection`)}constructor(){super(...arguments),this.types={AbstractElement:{name:Bn.$type,properties:{cardinality:{name:Bn.cardinality}},superTypes:[]},AbstractParserRule:{name:Hn.$type,properties:{},superTypes:[Wn.$type,Kn.$type]},AbstractRule:{name:Wn.$type,properties:{},superTypes:[]},AbstractType:{name:Kn.$type,properties:{},superTypes:[]},Action:{name:Jn.$type,properties:{cardinality:{name:Jn.cardinality},feature:{name:Jn.feature},inferredType:{name:Jn.inferredType},operator:{name:Jn.operator},type:{name:Jn.type,referenceType:Kn.$type}},superTypes:[Bn.$type]},Alternatives:{name:Xn.$type,properties:{cardinality:{name:Xn.cardinality},elements:{name:Xn.elements,defaultValue:[]}},superTypes:[Bn.$type]},ArrayLiteral:{name:Qn.$type,properties:{elements:{name:Qn.elements,defaultValue:[]}},superTypes:[Ai.$type]},ArrayType:{name:er.$type,properties:{elementType:{name:er.elementType}},superTypes:[Si.$type]},Assignment:{name:nr.$type,properties:{cardinality:{name:nr.cardinality},feature:{name:nr.feature},operator:{name:nr.operator},predicate:{name:nr.predicate},terminal:{name:nr.terminal}},superTypes:[Bn.$type]},BooleanLiteral:{name:ir.$type,properties:{true:{name:ir.true,defaultValue:!1}},superTypes:[cr.$type,Ai.$type]},CharacterRange:{name:or.$type,properties:{cardinality:{name:or.cardinality},left:{name:or.left},lookahead:{name:or.lookahead},parenthesized:{name:or.parenthesized,defaultValue:!1},right:{name:or.right}},superTypes:[ui.$type]},Condition:{name:cr.$type,properties:{},superTypes:[]},Conjunction:{name:ur.$type,properties:{left:{name:ur.left},right:{name:ur.right}},superTypes:[cr.$type]},CrossReference:{name:fr.$type,properties:{cardinality:{name:fr.cardinality},deprecatedSyntax:{name:fr.deprecatedSyntax,defaultValue:!1},isMulti:{name:fr.isMulti,defaultValue:!1},terminal:{name:fr.terminal},type:{name:fr.type,referenceType:Kn.$type}},superTypes:[Bn.$type]},Disjunction:{name:mr.$type,properties:{left:{name:mr.left},right:{name:mr.right}},superTypes:[cr.$type]},EndOfFile:{name:gr.$type,properties:{cardinality:{name:gr.cardinality}},superTypes:[Bn.$type]},Grammar:{name:vr.$type,properties:{imports:{name:vr.imports,defaultValue:[]},interfaces:{name:vr.interfaces,defaultValue:[]},isDeclared:{name:vr.isDeclared,defaultValue:!1},name:{name:vr.name},rules:{name:vr.rules,defaultValue:[]},types:{name:vr.types,defaultValue:[]}},superTypes:[]},GrammarImport:{name:br.$type,properties:{path:{name:br.path}},superTypes:[]},Group:{name:Sr.$type,properties:{cardinality:{name:Sr.cardinality},elements:{name:Sr.elements,defaultValue:[]},guardCondition:{name:Sr.guardCondition},predicate:{name:Sr.predicate}},superTypes:[Bn.$type]},InferredType:{name:wr.$type,properties:{name:{name:wr.name}},superTypes:[Kn.$type]},InfixRule:{name:Er.$type,properties:{call:{name:Er.call},dataType:{name:Er.dataType},inferredType:{name:Er.inferredType},name:{name:Er.name},operators:{name:Er.operators},parameters:{name:Er.parameters,defaultValue:[]},returnType:{name:Er.returnType,referenceType:Kn.$type}},superTypes:[Hn.$type]},InfixRuleOperatorList:{name:Or.$type,properties:{associativity:{name:Or.associativity},operators:{name:Or.operators,defaultValue:[]}},superTypes:[]},InfixRuleOperators:{name:Ar.$type,properties:{precedences:{name:Ar.precedences,defaultValue:[]}},superTypes:[]},Interface:{name:Mr.$type,properties:{attributes:{name:Mr.attributes,defaultValue:[]},name:{name:Mr.name},superTypes:{name:Mr.superTypes,defaultValue:[],referenceType:Kn.$type}},superTypes:[Kn.$type]},Keyword:{name:Pr.$type,properties:{cardinality:{name:Pr.cardinality},predicate:{name:Pr.predicate},value:{name:Pr.value}},superTypes:[Bn.$type]},NamedArgument:{name:Ir.$type,properties:{calledByName:{name:Ir.calledByName,defaultValue:!1},parameter:{name:Ir.parameter,referenceType:Wr.$type},value:{name:Ir.value}},superTypes:[]},NegatedToken:{name:Rr.$type,properties:{cardinality:{name:Rr.cardinality},lookahead:{name:Rr.lookahead},parenthesized:{name:Rr.parenthesized,defaultValue:!1},terminal:{name:Rr.terminal}},superTypes:[ui.$type]},Negation:{name:Br.$type,properties:{value:{name:Br.value}},superTypes:[cr.$type]},NumberLiteral:{name:Hr.$type,properties:{value:{name:Hr.value}},superTypes:[Ai.$type]},Parameter:{name:Wr.$type,properties:{name:{name:Wr.name}},superTypes:[]},ParameterReference:{name:Kr.$type,properties:{parameter:{name:Kr.parameter,referenceType:Wr.$type}},superTypes:[cr.$type]},ParserRule:{name:Jr.$type,properties:{dataType:{name:Jr.dataType},definition:{name:Jr.definition},entry:{name:Jr.entry,defaultValue:!1},fragment:{name:Jr.fragment,defaultValue:!1},inferredType:{name:Jr.inferredType},name:{name:Jr.name},parameters:{name:Jr.parameters,defaultValue:[]},returnType:{name:Jr.returnType,referenceType:Kn.$type}},superTypes:[Hn.$type]},ReferenceType:{name:Xr.$type,properties:{isMulti:{name:Xr.isMulti,defaultValue:!1},referenceType:{name:Xr.referenceType}},superTypes:[Si.$type]},RegexToken:{name:Qr.$type,properties:{cardinality:{name:Qr.cardinality},lookahead:{name:Qr.lookahead},parenthesized:{name:Qr.parenthesized,defaultValue:!1},regex:{name:Qr.regex}},superTypes:[ui.$type]},ReturnType:{name:ei.$type,properties:{name:{name:ei.name}},superTypes:[]},RuleCall:{name:ni.$type,properties:{arguments:{name:ni.arguments,defaultValue:[]},cardinality:{name:ni.cardinality},predicate:{name:ni.predicate},rule:{name:ni.rule,referenceType:Wn.$type}},superTypes:[Bn.$type]},SimpleType:{name:ii.$type,properties:{primitiveType:{name:ii.primitiveType},stringType:{name:ii.stringType},typeRef:{name:ii.typeRef,referenceType:Kn.$type}},superTypes:[Si.$type]},StringLiteral:{name:oi.$type,properties:{value:{name:oi.value}},superTypes:[Ai.$type]},TerminalAlternatives:{name:ci.$type,properties:{cardinality:{name:ci.cardinality},elements:{name:ci.elements,defaultValue:[]},lookahead:{name:ci.lookahead},parenthesized:{name:ci.parenthesized,defaultValue:!1}},superTypes:[ui.$type]},TerminalElement:{name:ui.$type,properties:{cardinality:{name:ui.cardinality},lookahead:{name:ui.lookahead},parenthesized:{name:ui.parenthesized,defaultValue:!1}},superTypes:[Bn.$type]},TerminalGroup:{name:fi.$type,properties:{cardinality:{name:fi.cardinality},elements:{name:fi.elements,defaultValue:[]},lookahead:{name:fi.lookahead},parenthesized:{name:fi.parenthesized,defaultValue:!1}},superTypes:[ui.$type]},TerminalRule:{name:mi.$type,properties:{definition:{name:mi.definition},fragment:{name:mi.fragment,defaultValue:!1},hidden:{name:mi.hidden,defaultValue:!1},name:{name:mi.name},type:{name:mi.type}},superTypes:[Wn.$type]},TerminalRuleCall:{name:gi.$type,properties:{cardinality:{name:gi.cardinality},lookahead:{name:gi.lookahead},parenthesized:{name:gi.parenthesized,defaultValue:!1},rule:{name:gi.rule,referenceType:mi.$type}},superTypes:[ui.$type]},Type:{name:vi.$type,properties:{name:{name:vi.name},type:{name:vi.type}},superTypes:[Kn.$type]},TypeAttribute:{name:bi.$type,properties:{defaultValue:{name:bi.defaultValue},isOptional:{name:bi.isOptional,defaultValue:!1},name:{name:bi.name},type:{name:bi.type}},superTypes:[]},TypeDefinition:{name:Si.$type,properties:{},superTypes:[]},UnionType:{name:wi.$type,properties:{types:{name:wi.types,defaultValue:[]}},superTypes:[Si.$type]},UnorderedGroup:{name:Ei.$type,properties:{cardinality:{name:Ei.cardinality},elements:{name:Ei.elements,defaultValue:[]}},superTypes:[Bn.$type]},UntilToken:{name:Oi.$type,properties:{cardinality:{name:Oi.cardinality},lookahead:{name:Oi.lookahead},parenthesized:{name:Oi.parenthesized,defaultValue:!1},terminal:{name:Oi.terminal}},superTypes:[ui.$type]},ValueLiteral:{name:Ai.$type,properties:{},superTypes:[]},Wildcard:{name:Mi.$type,properties:{cardinality:{name:Mi.cardinality},lookahead:{name:Mi.lookahead},parenthesized:{name:Mi.parenthesized,defaultValue:!1}},superTypes:[ui.$type]}}}},P=new Pi;function Fi(e){let t=e,n=!1;for(;t;){let e=Tn(t.grammarSource,Yr);if(e&&e.dataType)t=t.container,n=!0;else if(n)return t;else return}}o(Fi,`getDatatypeNode`);function Ii(e){return new xn(e,e=>pn(e)?e.content:[],{includeRoot:!0})}o(Ii,`streamCst`);function Li(e){return Ii(e).filter(mn)}o(Li,`flattenCst`);function Ri(e,t){for(;e.container;)if(e=e.container,e===t)return!0;return!1}o(Ri,`isChildNode`);function zi(e){return{start:{character:e.startColumn-1,line:e.startLine-1},end:{character:e.endColumn,line:e.endLine-1}}}o(zi,`tokenToRange`);function Bi(e){if(!e)return;let{offset:t,end:n,range:r}=e;return{range:r,offset:t,end:n,length:n-t}}o(Bi,`toDocumentSegment`);var Vi;(function(e){e[e.Before=0]=`Before`,e[e.After=1]=`After`,e[e.OverlapFront=2]=`OverlapFront`,e[e.OverlapBack=3]=`OverlapBack`,e[e.Inside=4]=`Inside`,e[e.Outside=5]=`Outside`})(Vi||={});function Hi(e,t){if(e.end.linet.end.line||e.start.line===t.end.line&&e.start.character>=t.end.character)return Vi.After;let n=e.start.line>t.start.line||e.start.line===t.start.line&&e.start.character>=t.start.character,r=e.end.lineVi.After}o(Ui,`inRange`);var Wi=/^[\w\p{L}]$/u;function Gi(e,t,n=Wi){if(e){if(t>0){let r=t-e.offset,i=e.text.charAt(r);n.test(i)||t--}return Ji(e,t)}}o(Gi,`findDeclarationNodeAtOffset`);function Ki(e,t){if(e){let n=Zi(e,!0);if(n&&qi(n,t))return n;if(hn(e)){let n=e.content.findIndex(e=>!e.hidden);for(let r=n-1;r>=0;r--){let n=e.content[r];if(qi(n,t))return n}}}}o(Ki,`findCommentNode`);function qi(e,t){return mn(e)&&t.includes(e.tokenType.name)}o(qi,`isCommentNode`);function Ji(e,t){if(mn(e))return e;if(pn(e)){let n=Xi(e,t,!1);if(n)return Ji(n,t)}}o(Ji,`findLeafNodeAtOffset`);function Yi(e,t){if(mn(e))return e;if(pn(e)){let n=Xi(e,t,!0);if(n)return Yi(n,t)}}o(Yi,`findLeafNodeBeforeOffset`);function Xi(e,t,n){let r=0,i=e.content.length-1,a;for(;r<=i;){let o=Math.floor((r+i)/2),s=e.content[o];if(s.offset<=t&&s.end>t)return s;s.end<=t?(a=n?s:void 0,r=o+1):i=o-1}return a}o(Xi,`binarySearch`);function Zi(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e);for(;r>0;){r--;let e=n.content[r];if(t||!e.hidden)return e}e=n}}o(Zi,`getPreviousNode`);function Qi(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e),i=n.content.length-1;for(;rWa,findNameAssignment:()=>Ga,findNodeForKeyword:()=>Ha,findNodeForProperty:()=>za,findNodesForKeyword:()=>Va,findNodesForKeywordInternal:()=>Ua,findNodesForProperty:()=>Ra,getActionAtElement:()=>qa,getActionType:()=>ro,getAllReachableRules:()=>Na,getAllRulesUsedForCrossReferences:()=>Fa,getCrossReferenceTerminal:()=>Ia,getEntryRule:()=>ja,getExplicitRuleType:()=>to,getHiddenRules:()=>Ma,getRuleType:()=>ao,getRuleTypeName:()=>io,getTypeName:()=>no,isArrayCardinality:()=>Ya,isArrayOperator:()=>Xa,isCommentTerminal:()=>La,isDataType:()=>$a,isDataTypeRule:()=>Za,isOptionalCardinality:()=>Ja,terminalRegex:()=>oo});var ia=class extends Error{static{o(this,`ErrorWithLocation`)}constructor(e,t){super(e?`${t} at ${e.range.start.line}:${e.range.start.character}`:t)}};function aa(e,t=`Error: Got unexpected value.`){throw Error(t)}o(aa,`assertUnreachable`);function oa(e,t=`Error: Condition is violated.`){if(!e)throw Error(t)}o(oa,`assertCondition`);var sa={};l(sa,{NEWLINE_REGEXP:()=>xa,escapeRegExp:()=>Oa,getTerminalParts:()=>wa,isMultilineComment:()=>Ta,isWhitespace:()=>Da,partialMatches:()=>ka,partialRegExp:()=>Aa,whitespaceCharacters:()=>Ea});function F(e){return e.charCodeAt(0)}o(F,`cc`);function ca(e,t){Array.isArray(e)?e.forEach(function(e){t.push(e)}):t.push(e)}o(ca,`insertToSet`);function la(e,t){if(e[t]===!0)throw`duplicate flag `+t;e[t],e[t]=!0}o(la,`addFlag`);function ua(e){if(e===void 0)throw Error(`Internal Error - Should never get here!`);return!0}o(ua,`ASSERT_EXISTS`);function da(){throw Error(`Internal Error - Should never get here!`)}o(da,`ASSERT_NEVER_REACH_HERE`);function fa(e){return e.type===`Character`}o(fa,`isCharacter`);var pa=[];for(let e=F(`0`);e<=F(`9`);e++)pa.push(e);var ma=[F(`_`)].concat(pa);for(let e=F(`a`);e<=F(`z`);e++)ma.push(e);for(let e=F(`A`);e<=F(`Z`);e++)ma.push(e);var ha=[F(` `),F(`\f`),F(` +`),F(`\r`),F(` `),F(`\v`),F(` `),F(`\xA0`),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(`\u2028`),F(`\u2029`),F(` `),F(` `),F(` `),F(``)],ga=/[0-9a-fA-F]/,_a=/[0-9]/,va=/[1-9]/,ya=class{static{o(this,`RegExpParser`)}constructor(){this.idx=0,this.input=``,this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar(`/`);let t=this.disjunction();this.consumeChar(`/`);let n={type:`Flags`,loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case`g`:la(n,`global`);break;case`i`:la(n,`ignoreCase`);break;case`m`:la(n,`multiLine`);break;case`u`:la(n,`unicode`);break;case`y`:la(n,`sticky`)}if(this.idx!==this.input.length)throw Error(`Redundant input: `+this.input.substring(this.idx));return{type:`Pattern`,flags:n,value:t,loc:this.loc(0)}}disjunction(){let e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()===`|`;)this.consumeChar(`|`),e.push(this.alternative());return{type:`Disjunction`,value:e,loc:this.loc(t)}}alternative(){let e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:`Alternative`,value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let e=this.idx;switch(this.popChar()){case`^`:return{type:`StartAnchor`,loc:this.loc(e)};case`$`:return{type:`EndAnchor`,loc:this.loc(e)};case`\\`:switch(this.popChar()){case`b`:return{type:`WordBoundary`,loc:this.loc(e)};case`B`:return{type:`NonWordBoundary`,loc:this.loc(e)}}throw Error(`Invalid Assertion Escape`);case`(`:this.consumeChar(`?`);let t;switch(this.popChar()){case`=`:t=`Lookahead`;break;case`!`:t=`NegativeLookahead`;break;case`<`:switch(this.popChar()){case`=`:t=`Lookbehind`;break;case`!`:t=`NegativeLookbehind`}}ua(t);let n=this.disjunction();return this.consumeChar(`)`),{type:t,value:n,loc:this.loc(e)}}return da()}quantifier(e=!1){let t,n=this.idx;switch(this.popChar()){case`*`:t={atLeast:0,atMost:1/0};break;case`+`:t={atLeast:1,atMost:1/0};break;case`?`:t={atLeast:0,atMost:1};break;case`{`:let n=this.integerIncludingZero();switch(this.popChar()){case`}`:t={atLeast:n,atMost:n};break;case`,`:let e;this.isDigit()?(e=this.integerIncludingZero(),t={atLeast:n,atMost:e}):t={atLeast:n,atMost:1/0},this.consumeChar(`}`)}if(e===!0&&t===void 0)return;ua(t)}if((e!==!0||t!==void 0)&&ua(t))return this.peekChar(0)===`?`?(this.consumeChar(`?`),t.greedy=!1):t.greedy=!0,t.type=`Quantifier`,t.loc=this.loc(n),t}atom(){let e,t=this.idx;switch(this.peekChar()){case`.`:e=this.dotAll();break;case`\\`:e=this.atomEscape();break;case`[`:e=this.characterClass();break;case`(`:e=this.group()}return e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),ua(e)?(e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e):da()}dotAll(){return this.consumeChar(`.`),{type:`Set`,complement:!0,value:[F(` +`),F(`\r`),F(`\u2028`),F(`\u2029`)]}}atomEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`1`:case`2`:case`3`:case`4`:case`5`:case`6`:case`7`:case`8`:case`9`:return this.decimalEscapeAtom();case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:`GroupBackReference`,value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case`d`:e=pa;break;case`D`:e=pa,t=!0;break;case`s`:e=ha;break;case`S`:e=ha,t=!0;break;case`w`:e=ma;break;case`W`:e=ma,t=!0}return ua(e)?{type:`Set`,value:e,complement:t}:da()}controlEscapeAtom(){let e;switch(this.popChar()){case`f`:e=F(`\f`);break;case`n`:e=F(` +`);break;case`r`:e=F(`\r`);break;case`t`:e=F(` `);break;case`v`:e=F(`\v`)}return ua(e)?{type:`Character`,value:e}:da()}controlLetterEscapeAtom(){this.consumeChar(`c`);let e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error(`Invalid `);return{type:`Character`,value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar(`0`),{type:`Character`,value:F(`\0`)}}hexEscapeSequenceAtom(){return this.consumeChar(`x`),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar(`u`),this.parseHexDigits(4)}identityEscapeAtom(){return{type:`Character`,value:F(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case` +`:case`\r`:case`\u2028`:case`\u2029`:case`\\`:case`]`:throw Error(`TBD`);default:return{type:`Character`,value:F(this.popChar())}}}characterClass(){let e=[],t=!1;for(this.consumeChar(`[`),this.peekChar(0)===`^`&&(this.consumeChar(`^`),t=!0);this.isClassAtom();){let t=this.classAtom();if(t.type,fa(t)&&this.isRangeDash()){this.consumeChar(`-`);let n=this.classAtom();if(n.type,fa(n)){if(n.value=this.input.length)throw Error(`Unexpected end of input`);this.idx++}loc(e){return{begin:e,end:this.idx}}},ba=class{static{o(this,`BaseRegExpVisitor`)}visitChildren(e){for(let t in e){let n=e[t];e.hasOwnProperty(t)&&(n.type===void 0?Array.isArray(n)&&n.forEach(e=>{this.visit(e)},this):this.visit(n))}}visit(e){switch(e.type){case`Pattern`:this.visitPattern(e);break;case`Flags`:this.visitFlags(e);break;case`Disjunction`:this.visitDisjunction(e);break;case`Alternative`:this.visitAlternative(e);break;case`StartAnchor`:this.visitStartAnchor(e);break;case`EndAnchor`:this.visitEndAnchor(e);break;case`WordBoundary`:this.visitWordBoundary(e);break;case`NonWordBoundary`:this.visitNonWordBoundary(e);break;case`Lookahead`:this.visitLookahead(e);break;case`NegativeLookahead`:this.visitNegativeLookahead(e);break;case`Lookbehind`:this.visitLookbehind(e);break;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);break;case`Character`:this.visitCharacter(e);break;case`Set`:this.visitSet(e);break;case`Group`:this.visitGroup(e);break;case`GroupBackReference`:this.visitGroupBackReference(e);break;case`Quantifier`:this.visitQuantifier(e)}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},xa=/\r?\n/gm,Sa=new ya,Ca=new class extends ba{static{o(this,`TerminalRegExpVisitor`)}constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join(``)}reset(e){this.multiline=!1,this.regex=e,this.startRegexp=``,this.isStarting=!0,this.endRegexpStack=[]}visitGroup(e){e.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(e){let t=String.fromCharCode(e.value);if(!this.multiline&&t===` +`&&(this.multiline=!0),e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let e=Oa(t);this.endRegexpStack.push(e),this.isStarting&&(this.startRegexp+=e)}}visitSet(e){if(!this.multiline){let t=this.regex.substring(e.loc.begin,e.loc.end),n=new RegExp(t);this.multiline=!!` +`.match(n)}if(e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let t=this.regex.substring(e.loc.begin,e.loc.end);this.endRegexpStack.push(t),this.isStarting&&(this.startRegexp+=t)}}visitChildren(e){e.type===`Group`&&e.quantifier||super.visitChildren(e)}};function wa(e){try{typeof e!=`string`&&(e=e.source),e=`/${e}/`;let t=Sa.pattern(e),n=[];for(let r of t.value.value)Ca.reset(e),Ca.visit(r),n.push({start:Ca.startRegexp,end:Ca.endRegex});return n}catch{return[]}}o(wa,`getTerminalParts`);function Ta(e){try{return typeof e==`string`&&(e=new RegExp(e)),e=e.toString(),Ca.reset(e),Ca.visit(Sa.pattern(e)),Ca.multiline}catch{return!1}}o(Ta,`isMultilineComment`);var Ea=`\f +\r \v \xA0            \u2028\u2029   `.split(``);function Da(e){let t=typeof e==`string`?new RegExp(e):e;return Ea.some(e=>t.test(e))}o(Da,`isWhitespace`);function Oa(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}o(Oa,`escapeRegExp`);function ka(e,t){let n=Aa(e),r=t.match(n);return!!r&&r[0].length>0}o(ka,`partialMatches`);function Aa(e){typeof e==`string`&&(e=new RegExp(e));let t=e,n=e.source,r=0;function i(){let e=``,a;function s(t){e+=n.substr(r,t),r+=t}o(s,`appendRaw`);function c(t){e+=`(?:`+n.substr(r,t)+`|$)`,r+=t}for(o(c,`appendOptional`);r`,r)-r+1);break;default:c(2)}break;case`[`:a=/\[(?:\\.|.)*?\]/g,a.lastIndex=r,a=a.exec(n)||[],c(a[0].length);break;case`|`:case`^`:case`$`:case`*`:case`+`:case`?`:s(1);break;case`{`:a=/\{\d+,?\d*\}/g,a.lastIndex=r,a=a.exec(n),a?s(a[0].length):c(1);break;case`(`:if(n[r+1]===`?`)switch(n[r+2]){case`:`:e+=`(?:`,r+=3,e+=i()+`|$)`;break;case`=`:e+=`(?=`,r+=3,e+=i()+`)`;break;case`!`:a=r,r+=3,i(),e+=n.substr(a,r-a);break;case`<`:switch(n[r+3]){case`=`:case`!`:a=r,r+=4,i(),e+=n.substr(a,r-a);break;default:s(n.indexOf(`>`,r)-r+1),e+=i()+`|$)`}}else s(1),e+=i()+`|$)`;break;case`)`:return++r,e;default:c(1)}return e}return o(i,`process`),new RegExp(i(),e.flags)}o(Aa,`partialRegExp`);function ja(e){return e.rules.find(e=>Yr(e)&&e.entry)}o(ja,`getEntryRule`);function Ma(e){return e.rules.filter(e=>hi(e)&&e.hidden)}o(Ma,`getHiddenRules`);function Na(e,t){let n=new Set,r=ja(e);if(!r)return new Set(e.rules);let i=[r].concat(Ma(e));for(let e of i)Pa(e,n,t);let a=new Set;for(let t of e.rules)(n.has(t.name)||hi(t)&&t.hidden)&&a.add(t);return a}o(Na,`getAllReachableRules`);function Pa(e,t,n){t.add(e.name),jn(e).forEach(e=>{if(ri(e)||n&&_i(e)){let r=e.rule.ref;r&&!t.has(r.name)&&Pa(r,t,n)}})}o(Pa,`ruleDfs`);function Fa(e){let t=new Set;return jn(e).forEach(e=>{pr(e)&&(Yr(e.type.ref)&&t.add(e.type.ref),Tr(e.type.ref)&&Yr(e.type.ref.$container)&&t.add(e.type.ref.$container))}),t}o(Fa,`getAllRulesUsedForCrossReferences`);function Ia(e){if(e.terminal)return e.terminal;if(e.type.ref)return Ga(e.type.ref)?.terminal}o(Ia,`getCrossReferenceTerminal`);function La(e){return e.hidden&&!Da(oo(e))}o(La,`isCommentTerminal`);function Ra(e,t){return!e||!t?[]:Ba(e,t,e.astNode,!0)}o(Ra,`findNodesForProperty`);function za(e,t,n){if(!e||!t)return;let r=Ba(e,t,e.astNode,!0);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(za,`findNodeForProperty`);function Ba(e,t,n,r){if(!r){let n=Tn(e.grammarSource,rr);if(n&&n.feature===t)return[e]}return pn(e)&&e.astNode===n?e.content.flatMap(e=>Ba(e,t,n,!1)):[]}o(Ba,`findNodesForPropertyInternal`);function Va(e,t){return e?Ua(e,t,e?.astNode):[]}o(Va,`findNodesForKeyword`);function Ha(e,t,n){if(!e)return;let r=Ua(e,t,e?.astNode);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(Ha,`findNodeForKeyword`);function Ua(e,t,n){if(e.astNode!==n)return[];if(Fr(e.grammarSource)&&e.grammarSource.value===t)return[e];let r=Ii(e).iterator(),i,a=[];do if(i=r.next(),!i.done){let e=i.value;e.astNode===n?Fr(e.grammarSource)&&e.grammarSource.value===t&&a.push(e):r.prune()}while(!i.done);return a}o(Ua,`findNodesForKeywordInternal`);function Wa(e){let t=e.astNode;for(;t===e.container?.astNode;){let t=Tn(e.grammarSource,rr);if(t)return t;e=e.container}}o(Wa,`findAssignment`);function Ga(e){let t=e;return Tr(t)&&(Yn(t.$container)?t=t.$container.$container:Un(t.$container)?t=t.$container:aa(t.$container)),Ka(e,t,new Map)}o(Ga,`findNameAssignment`);function Ka(e,t,n){function r(t,r){let i;return Tn(t,rr)||(i=Ka(r,r,n)),n.set(e,i),i}if(o(r,`go`),n.has(e))return n.get(e);n.set(e,void 0);for(let i of jn(t))if(rr(i)&&i.feature.toLowerCase()===`name`)return n.set(e,i),i;else if(ri(i)&&Yr(i.rule.ref))return r(i,i.rule.ref);else if(ai(i)&&i.typeRef?.ref)return r(i,i.typeRef.ref)}o(Ka,`findNameAssignmentInternal`);function qa(e){let t=e.$container;if(Cr(t)){let n=t.elements,r=n.indexOf(e);for(let e=r-1;e>=0;e--){let t=n[e];if(Yn(t))return t;{let t=jn(n[e]).find(Yn);if(t)return t}}}if(Vn(t))return qa(t)}o(qa,`getActionAtElement`);function Ja(e,t){return e===`?`||e===`*`||Cr(t)&&!!t.guardCondition}o(Ja,`isOptionalCardinality`);function Ya(e){return e===`*`||e===`+`}o(Ya,`isArrayCardinality`);function Xa(e){return e===`+=`}o(Xa,`isArrayOperator`);function Za(e){return Qa(e,new Set)}o(Za,`isDataTypeRule`);function Qa(e,t){if(t.has(e))return!0;t.add(e);for(let n of jn(e))if(ri(n)){if(!n.rule.ref||Yr(n.rule.ref)&&!Qa(n.rule.ref,t)||Dr(n.rule.ref))return!1}else if(rr(n))return!1;else if(Yn(n))return!1;return!!e.definition}o(Qa,`isDataTypeRuleInternal`);function $a(e){return eo(e.type,new Set)}o($a,`isDataType`);function eo(e,t){if(t.has(e))return!0;if(t.add(e),tr(e)||Zr(e))return!1;if(Ti(e))return e.types.every(e=>eo(e,t));if(ai(e)){if(e.primitiveType!==void 0||e.stringType!==void 0)return!0;if(e.typeRef!==void 0){let n=e.typeRef.ref;return yi(n)?eo(n.type,t):!1}return!1}return!1}o(eo,`isDataTypeInternal`);function to(e){if(!hi(e)){if(e.inferredType)return e.inferredType.name;if(e.dataType)return e.dataType;if(e.returnType){let t=e.returnType.ref;if(t)return t.name}}}o(to,`getExplicitRuleType`);function no(e){if(Un(e))return Yr(e)&&Za(e)?e.name:to(e)??e.name;if(Nr(e)||yi(e)||ti(e))return e.name;if(Yn(e)){let t=ro(e);if(t)return t}else if(Tr(e))return e.name;throw Error(`Cannot get name of Unknown Type`)}o(no,`getTypeName`);function ro(e){if(e.inferredType)return e.inferredType.name;if(e.type?.ref)return no(e.type.ref)}o(ro,`getActionType`);function io(e){return hi(e)?e.type?.name??`string`:Yr(e)&&Za(e)?e.name:to(e)??e.name}o(io,`getRuleTypeName`);function ao(e){return hi(e)?e.type?.name??`string`:to(e)??e.name}o(ao,`getRuleType`);function oo(e){let t={s:!1,i:!1,u:!1},n=co(e.definition,t),r=Object.entries(t).filter(([,e])=>e).map(([e])=>e).join(``);return new RegExp(n,r)}o(oo,`terminalRegex`);var so=`[\\s\\S]`;function co(e,t){if(li(e))return lo(e);if(pi(e))return uo(e);if(sr(e))return mo(e);if(_i(e)){let t=e.rule.ref;if(!t)throw Error(`Missing rule reference.`);return go(co(t.definition),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}if(zr(e))return po(e);if(ki(e))return fo(e);if($r(e)){let n=e.regex.lastIndexOf(`/`),r=e.regex.substring(1,n),i=e.regex.substring(n+1);return t&&(t.i=i.includes(`i`),t.s=i.includes(`s`),t.u=i.includes(`u`)),go(r,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}if(Ni(e))return go(so,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized});throw Error(`Invalid terminal element: ${e?.$type}, ${e?.$cstNode?.text}`)}o(co,`abstractElementToRegex`);function lo(e){return go(e.elements.map(e=>co(e)).join(`|`),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(lo,`terminalAlternativesToRegex`);function uo(e){return go(e.elements.map(e=>co(e)).join(``),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(uo,`terminalGroupToRegex`);function fo(e){return go(`${so}*?${co(e.terminal)}`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(fo,`untilTokenToRegex`);function po(e){return go(`(?!${co(e.terminal)})${so}*?`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(po,`negateTokenToRegex`);function mo(e){return e.right?go(`[${ho(e.left)}-${ho(e.right)}]`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1}):go(ho(e.left),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(mo,`characterRangeToRegex`);function ho(e){return Oa(e.value)}o(ho,`keywordToRegex`);function go(e,t){return(t.parenthesized||t.lookahead||t.wrap!==!1)&&(e=`(${t.lookahead??(t.parenthesized?``:`?:`)}${e})`),t.cardinality?`${e}${t.cardinality}`:e}o(go,`withCardinality`);function _o(e){let t=[],n=e.Grammar;for(let e of n.rules)hi(e)&&La(e)&&Ta(oo(e))&&t.push(e.name);return{multilineCommentRules:t,nameRegexp:Wi}}o(_o,`createGrammarConfig`);var vo=typeof global==`object`&&global&&global.Object===Object&&global,yo=typeof self==`object`&&self&&self.Object===Object&&self,bo=vo||yo||Function(`return this`)(),xo=bo.Symbol,So=Object.prototype,Co=So.hasOwnProperty,wo=So.toString,To=xo?xo.toStringTag:void 0;function Eo(e){var t=Co.call(e,To),n=e[To];try{e[To]=void 0;var r=!0}catch{}var i=wo.call(e);return r&&(t?e[To]=n:delete e[To]),i}o(Eo,`getRawTag`);var Do=Eo,Oo=Object.prototype.toString;function ko(e){return Oo.call(e)}o(ko,`objectToString`);var Ao=ko,jo=`[object Null]`,Mo=`[object Undefined]`,No=xo?xo.toStringTag:void 0;function Po(e){return e==null?e===void 0?Mo:jo:No&&No in Object(e)?Do(e):Ao(e)}o(Po,`baseGetTag`);var Fo=Po;function Io(e){return typeof e==`object`&&!!e}o(Io,`isObjectLike`);var Lo=Io,Ro=`[object Symbol]`;function zo(e){return typeof e==`symbol`||Lo(e)&&Fo(e)==Ro}o(zo,`isSymbol`);var Bo=zo;function Vo(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n0){if(++t>=Qs)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}o(tc,`shortOut`);var nc=tc;function rc(e){return function(){return e}}o(rc,`constant`);var ic=rc,ac=(function(){try{var e=Hs(Object,`defineProperty`);return e({},``,{}),e}catch{}})(),oc=nc(ac?function(e,t){return ac(e,`toString`,{configurable:!0,enumerable:!1,value:ic(t),writable:!0})}:gs);function sc(e,t){for(var n=-1,r=e==null?0:e.length;++n-1}o(_c,`arrayIncludes`);var vc=_c,yc=9007199254740991,bc=/^(?:0|[1-9]\d*)$/;function xc(e,t){var n=typeof e;return t??=yc,!!t&&(n==`number`||n!=`symbol`&&bc.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=Lc}o(Rc,`isLength`);var zc=Rc;function Bc(e){return e!=null&&zc(e.length)&&!Ss(e)}o(Bc,`isArrayLike`);var Vc=Bc;function Hc(e,t,n){if(!ts(n))return!1;var r=typeof t;return(r==`number`?Vc(n)&&Sc(t,n.length):r==`string`&&t in n)?Ec(n[t],e):!1}o(Hc,`isIterateeCall`);var Uc=Hc;function Wc(e){return Ic(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&Uc(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r-1}o(Bu,`listCacheHas`);var Vu=Bu;function Hu(e,t){var n=this.__data__,r=Pu(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(Hu,`listCacheSet`);var Uu=Hu;function Wu(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t0&&n(s)?t>1?Pd(s,t-1,n,r,i):Ad(i,s):r||(i[i.length]=s)}return i}o(Pd,`baseFlatten`);var Fd=Pd;function Id(e){return e!=null&&e.length?Fd(e,1):[]}o(Id,`flatten`);var Ld=Id,Rd=Jl(Object.getPrototypeOf,Object);function zd(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++rs))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Lm?new jm:void 0;for(a.set(e,t),a.set(t,e);++d2?t[2]:void 0;for(i&&Uc(t[0],t[1],i)&&(r=1);++n=hg&&(a=Fm,o=!1,t=new jm(t));outer:for(;++i-1?i[a?t[s]:s]:void 0}}o(Rg,`createFind`);var zg=Rg,Bg=Math.max;function Vg(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:ms(n);return i<0&&(i=Bg(r+i,0)),uc(e,Yh(t,3),i)}o(Vg,`findIndex`);var Hg=zg(Vg);function Ug(e){return e&&e.length?e[0]:void 0}o(Ug,`head`);var Wg=Ug;function Gg(e,t){var n=-1,r=Vc(e)?Array(e.length):[];return rg(e,function(e,i,a){r[++n]=t(e,i,a)}),r}o(Gg,`baseMap`);var Kg=Gg;function qg(e,t){return(I(e)?Ho:Kg)(e,Yh(t,3))}o(qg,`map`);var B=qg;function Jg(e,t){return Fd(B(e,t),1)}o(Jg,`flatMap`);var Yg=Jg,Xg=Object.prototype.hasOwnProperty,Zg=sg(function(e,t,n){Xg.call(e,n)?e[n].push(t):wc(e,n,[t])}),Qg=Object.prototype.hasOwnProperty;function $g(e,t){return e!=null&&Qg.call(e,t)}o($g,`baseHas`);var e_=$g;function t_(e,t){return e!=null&&Fh(e,t,e_)}o(t_,`has`);var V=t_,n_=`[object String]`;function r_(e){return typeof e==`string`||!I(e)&&Lo(e)&&Fo(e)==n_}o(r_,`isString`);var i_=r_;function a_(e,t){return Ho(t,function(t){return e[t]})}o(a_,`baseValues`);var o_=a_;function s_(e){return e==null?[]:o_(e,eu(e))}o(s_,`values`);var H=s_,c_=Math.max;function l_(e,t,n,r){e=Vc(e)?e:H(e),n=n&&!r?ms(n):0;var i=e.length;return n<0&&(n=c_(i+n,0)),i_(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&gc(e,t,n)>-1}o(l_,`includes`);var u_=l_,d_=Math.max;function f_(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:ms(n);return i<0&&(i=d_(r+i,0)),gc(e,t,i)}o(f_,`indexOf`);var p_=f_,m_=`[object Map]`,h_=`[object Set]`,g_=Object.prototype.hasOwnProperty;function __(e){if(e==null)return!0;if(Vc(e)&&(I(e)||typeof e==`string`||typeof e.splice==`function`||ll(e)||Ul(e)||rl(e)))return!e.length;var t=Kf(e);if(t==m_||t==h_)return!e.size;if(Jc(e))return!Ql(e).length;for(var n in e)if(g_.call(e,n))return!1;return!0}o(__,`isEmpty`);var U=__,v_=`[object RegExp]`;function y_(e){return Lo(e)&&Fo(e)==v_}o(y_,`baseIsRegExp`);var b_=y_,x_=Vl&&Vl.isRegExp,S_=x_?Ll(x_):b_;function C_(e){return e===void 0}o(C_,`isUndefined`);var w_=C_,T_=`Expected a function`;function E_(e){if(typeof e!=`function`)throw TypeError(T_);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}o(E_,`negate`);var D_=E_;function O_(e,t,n,r){if(!ts(e))return e;t=xd(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i=G_){var l=t?null:W_(e);if(l)return Um(l);o=!1,i=Fm,c=new jm}else c=t?[]:s;outer:for(;++r{t.accept(e)})}},rv=class extends nv{static{o(this,`NonTerminal`)}constructor(e){super([]),this.idx=1,nu(this,N_(e,e=>e!==void 0))}set definition(e){}get definition(){return this.referencedRule===void 0?[]:this.referencedRule.definition}accept(e){e.visit(this)}},iv=class extends nv{static{o(this,`Rule`)}constructor(e){super(e.definition),this.orgText=``,nu(this,N_(e,e=>e!==void 0))}},av=class extends nv{static{o(this,`Alternative`)}constructor(e){super(e.definition),this.ignoreAmbiguities=!1,nu(this,N_(e,e=>e!==void 0))}},ov=class extends nv{static{o(this,`Option`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},sv=class extends nv{static{o(this,`RepetitionMandatory`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},cv=class extends nv{static{o(this,`RepetitionMandatoryWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},W=class extends nv{static{o(this,`Repetition`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},lv=class extends nv{static{o(this,`RepetitionWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},uv=class extends nv{static{o(this,`Alternation`)}get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,nu(this,N_(e,e=>e!==void 0))}},G=class{static{o(this,`Terminal`)}constructor(e){this.idx=1,nu(this,N_(e,e=>e!==void 0))}accept(e){e.visit(this)}};function dv(e){return B(e,fv)}o(dv,`serializeGrammar`);function fv(e){function t(e){return B(e,fv)}if(o(t,`convertDefinition`),e instanceof rv){let t={type:`NonTerminal`,name:e.nonTerminalName,idx:e.idx};return i_(e.label)&&(t.label=e.label),t}if(e instanceof av)return{type:`Alternative`,definition:t(e.definition)};if(e instanceof ov)return{type:`Option`,idx:e.idx,definition:t(e.definition)};if(e instanceof sv)return{type:`RepetitionMandatory`,idx:e.idx,definition:t(e.definition)};if(e instanceof cv)return{type:`RepetitionMandatoryWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof lv)return{type:`RepetitionWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof W)return{type:`Repetition`,idx:e.idx,definition:t(e.definition)};if(e instanceof uv)return{type:`Alternation`,idx:e.idx,definition:t(e.definition)};if(e instanceof G){let t={type:`Terminal`,name:e.terminalType.name,label:ev(e.terminalType),idx:e.idx};i_(e.label)&&(t.terminalLabel=e.label);let n=e.terminalType.PATTERN;return e.terminalType.PATTERN&&(t.pattern=S_(n)?n.source:n),t}if(e instanceof iv)return{type:`Rule`,name:e.name,orgText:e.orgText,definition:t(e.definition)};throw Error(`non exhaustive match`)}o(fv,`serializeProduction`);var pv=class{static{o(this,`GAstVisitor`)}visit(e){let t=e;switch(t.constructor){case rv:return this.visitNonTerminal(t);case av:return this.visitAlternative(t);case ov:return this.visitOption(t);case sv:return this.visitRepetitionMandatory(t);case cv:return this.visitRepetitionMandatoryWithSeparator(t);case lv:return this.visitRepetitionWithSeparator(t);case W:return this.visitRepetition(t);case uv:return this.visitAlternation(t);case G:return this.visitTerminal(t);case iv:return this.visitRule(t);default:throw Error(`non exhaustive match`)}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}};function mv(e){return e instanceof av||e instanceof ov||e instanceof W||e instanceof sv||e instanceof cv||e instanceof lv||e instanceof G||e instanceof iv}o(mv,`isSequenceProd`);function hv(e,t=[]){return e instanceof ov||e instanceof W||e instanceof lv?!0:e instanceof uv?U_(e.definition,e=>hv(e,t)):e instanceof rv&&u_(t,e)?!1:e instanceof nv&&(e instanceof rv&&t.push(e),Ng(e.definition,e=>hv(e,t)))}o(hv,`isOptionalProd`);function gv(e){return e instanceof uv}o(gv,`isBranchingProd`);function _v(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(_v,`getProductionDslName`);var vv=class{static{o(this,`RestWalker`)}walk(e,t=[]){z(e.definition,(n,r)=>{let i=Sg(e.definition,r+1);if(n instanceof rv)this.walkProdRef(n,i,t);else if(n instanceof G)this.walkTerminal(n,i,t);else if(n instanceof av)this.walkFlat(n,i,t);else if(n instanceof ov)this.walkOption(n,i,t);else if(n instanceof sv)this.walkAtLeastOne(n,i,t);else if(n instanceof cv)this.walkAtLeastOneSep(n,i,t);else if(n instanceof lv)this.walkManySep(n,i,t);else if(n instanceof W)this.walkMany(n,i,t);else if(n instanceof uv)this.walkOr(n,i,t);else throw Error(`non exhaustive match`)})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){let r=t.concat(n);this.walk(e,r)}walkOption(e,t,n){let r=t.concat(n);this.walk(e,r)}walkAtLeastOne(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkAtLeastOneSep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkMany(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkManySep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkOr(e,t,n){let r=t.concat(n);z(e.definition,e=>{let t=new av({definition:[e]});this.walk(t,r)})}};function yv(e,t,n){return[new ov({definition:[new G({terminalType:e.separator})].concat(e.definition)})].concat(t,n)}o(yv,`restForRepetitionWithSeparator`);function bv(e){if(e instanceof rv)return bv(e.referencedRule);if(e instanceof G)return Cv(e);if(mv(e))return xv(e);if(gv(e))return Sv(e);throw Error(`non exhaustive match`)}o(bv,`first`);function xv(e){let t=[],n=e.definition,r=0,i=n.length>r,a,o=!0;for(;i&&o;)a=n[r],o=hv(a),t=t.concat(bv(a)),r+=1,i=n.length>r;return Y_(t)}o(xv,`firstForSequence`);function Sv(e){return Y_(Ld(B(e.definition,e=>bv(e))))}o(Sv,`firstForBranching`);function Cv(e){return[e.terminalType]}o(Cv,`firstForTerminal`);var wv=`_~IN~_`,Tv=class extends vv{static{o(this,`ResyncFollowsWalker`)}constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){let r=Dv(e.referencedRule,e.idx)+this.topProd.name,i=bv(new av({definition:t.concat(n)}));this.follows[r]=i}};function Ev(e){let t={};return z(e,e=>{let n=new Tv(e).startWalking();nu(t,n)}),t}o(Ev,`computeAllProdsFollows`);function Dv(e,t){return e.name+t+wv}o(Dv,`buildBetweenProdsFollowPrefix`);var Ov={},kv=new ya;function Av(e){let t=e.toString();if(Ov.hasOwnProperty(t))return Ov[t];{let e=kv.pattern(t);return Ov[t]=e,e}}o(Av,`getRegExpAst`);function jv(){Ov={}}o(jv,`clearRegExpParserCache`);var Mv=`Complement Sets are not supported for first char optimization`,Nv=`Unable to use "first char" lexer optimizations: +`;function Pv(e,t=!1){try{let t=Av(e);return Fv(t.value,{},t.flags.ignoreCase)}catch(n){if(n.message===Mv)t&&Z_(`${Nv} Unable to optimize: < ${e.toString()} > + Complement Sets cannot be automatically optimized. + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n=``;t&&(n=` + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),X_(`${Nv} + Failed parsing: < ${e.toString()} > + Using the @chevrotain/regexp-to-ast library + Please open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}o(Pv,`getOptimizedStartCodesIndices`);function Fv(e,t,n){switch(e.type){case`Disjunction`:for(let r=0;r{if(typeof e==`number`)Iv(e,t,n);else{let r=e;if(n===!0)for(let e=r.from;e<=r.to;e++)Iv(e,t,n);else{for(let e=r.from;e<=r.to&&e=by){let e=r.from>=by?r.from:by,n=r.to,i=Sy(e),a=Sy(n);for(let e=i;e<=a;e++)t[e]=e}}}});break;case`Group`:Fv(a.value,t,n);break;default:throw Error(`Non Exhaustive Match`)}let o=a.quantifier!==void 0&&a.quantifier.atLeast===0;if(a.type===`Group`&&zv(a)===!1||a.type!==`Group`&&o===!1)break}break;default:throw Error(`non exhaustive match!`)}return H(t)}o(Fv,`firstCharOptimizedIndices`);function Iv(e,t,n){let r=Sy(e);t[r]=r,n===!0&&Lv(e,t)}o(Iv,`addOptimizedIdxToResult`);function Lv(e,t){let n=String.fromCharCode(e),r=n.toUpperCase();if(r!==n){let e=Sy(r.charCodeAt(0));t[e]=e}else{let e=n.toLowerCase();if(e!==n){let n=Sy(e.charCodeAt(0));t[n]=n}}}o(Lv,`handleIgnoreCase`);function Rv(e,t){return Hg(e.value,e=>{if(typeof e==`number`)return u_(t,e);{let n=e;return Hg(t,e=>n.from<=e&&e<=n.to)!==void 0}})}o(Rv,`findCode`);function zv(e){let t=e.quantifier;return t&&t.atLeast===0?!0:e.value?I(e.value)?Ng(e.value,zv):zv(e.value):!1}o(zv,`isWholeOptional`);var Bv=class extends ba{static{o(this,`CharCodeFinder`)}constructor(e){super(),this.targetCharCodes=e,this.found=!1}visitChildren(e){if(this.found!==!0){switch(e.type){case`Lookahead`:this.visitLookahead(e);return;case`NegativeLookahead`:this.visitNegativeLookahead(e);return;case`Lookbehind`:this.visitLookbehind(e);return;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);return}super.visitChildren(e)}}visitCharacter(e){u_(this.targetCharCodes,e.value)&&(this.found=!0)}visitSet(e){e.complement?Rv(e,this.targetCharCodes)===void 0&&(this.found=!0):Rv(e,this.targetCharCodes)!==void 0&&(this.found=!0)}};function Vv(e,t){if(t instanceof RegExp){let n=Av(t),r=new Bv(e);return r.visit(n),r.found}return Hg(t,t=>u_(e,t.charCodeAt(0)))!==void 0}o(Vv,`canMatchCharCode`);var Hv=`PATTERN`,Uv=`defaultMode`,Wv=`modes`;function Gv(e,t){t=ug(t,{debug:!1,safeMode:!1,positionTracking:`full`,lineTerminatorCharacters:[`\r`,` +`],tracer:o((e,t)=>t(),`tracer`)});let n=t.tracer;n(`initCharCodeToOptimizedIndexMap`,()=>{Cy()});let r;n(`Reject Lexer.NA`,()=>{r=z_(e,e=>e[Hv]===Vy.NA)});let i=!1,a;n(`Transform Patterns`,()=>{i=!1,a=B(r,e=>{let t=e[Hv];if(S_(t)){let e=t.source;return e.length===1&&e!==`^`&&e!==`$`&&e!==`.`&&!t.ignoreCase?e:e.length===2&&e[0]===`\\`&&!u_([`d`,`D`,`s`,`S`,`t`,`r`,`n`,`t`,`0`,`c`,`b`,`B`,`f`,`v`,`w`,`W`],e[1])?e[1]:ly(t)}if(Ss(t))return i=!0,{exec:t};if(typeof t==`object`)return i=!0,t;if(typeof t==`string`){if(t.length===1)return t;{let e=t.replace(/[\\^$.*+?()[\]{}|]/g,`\\$&`);return ly(new RegExp(e))}}throw Error(`non exhaustive match`)})});let s,c,l,u,d;n(`misc mapping`,()=>{s=B(r,e=>e.tokenTypeIdx),c=B(r,e=>{let t=e.GROUP;if(t!==Vy.SKIPPED){if(i_(t))return t;if(w_(t))return!1;throw Error(`non exhaustive match`)}}),l=B(r,e=>{let t=e.LONGER_ALT;if(t)return I(t)?B(t,e=>p_(r,e)):[p_(r,t)]}),u=B(r,e=>e.PUSH_MODE),d=B(r,e=>V(e,`POP_MODE`))});let f;n(`Line Terminator Handling`,()=>{let e=vy(t.lineTerminatorCharacters);f=B(r,e=>!1),t.positionTracking!==`onlyOffset`&&(f=B(r,t=>V(t,`LINE_BREAKS`)?!!t.LINE_BREAKS:gy(t,e)===!1&&Vv(e,t.PATTERN)))});let p,m,h,g;n(`Misc Mapping #2`,()=>{p=B(r,py),m=B(a,my),h=L_(r,(e,t)=>{let n=t.GROUP;return i_(n)&&n!==Vy.SKIPPED&&(e[n]=[]),e},{}),g=B(a,(e,t)=>({pattern:a[t],longerAlt:l[t],canLineTerminator:f[t],isCustom:p[t],short:m[t],group:c[t],push:u[t],pop:d[t],tokenTypeIdx:s[t],tokenType:r[t]}))});let _=!0,v=[];return t.safeMode||n(`First Char Optimization`,()=>{v=L_(r,(e,n,r)=>{if(typeof n.PATTERN==`string`)yy(e,Sy(n.PATTERN.charCodeAt(0)),g[r]);else if(I(n.START_CHARS_HINT)){let t;z(n.START_CHARS_HINT,n=>{let i=Sy(typeof n==`string`?n.charCodeAt(0):n);t!==i&&(t=i,yy(e,i,g[r]))})}else if(S_(n.PATTERN)){if(n.PATTERN.unicode)_=!1,t.ensureOptimizations&&X_(`${Nv} Unable to analyze < ${n.PATTERN.toString()} > pattern. + The regexp unicode flag is not currently supported by the regexp-to-ast library. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{let i=Pv(n.PATTERN,t.ensureOptimizations);U(i)&&(_=!1),z(i,t=>{yy(e,t,g[r])})}}else t.ensureOptimizations&&X_(`${Nv} TokenType: <${n.name}> is using a custom token pattern without providing parameter. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),_=!1;return e},[])}),{emptyGroups:h,patternIdxToConfig:g,charCodeToPatternIdxToConfig:v,hasCustom:i,canBeOptimized:_}}o(Gv,`analyzeTokenTypes`);function Kv(e,t){let n=[],r=Jv(e);n=n.concat(r.errors);let i=Yv(r.valid),a=i.valid;return n=n.concat(i.errors),n=n.concat(qv(a)),n=n.concat(ry(a)),n=n.concat(iy(a,t)),n=n.concat(ay(a)),n}o(Kv,`validatePatterns`);function qv(e){let t=[],n=Lg(e,e=>S_(e[Hv]));return t=t.concat(Zv(n)),t=t.concat(ey(n)),t=t.concat(ty(n)),t=t.concat(ny(n)),t=t.concat(Qv(n)),t}o(qv,`validateRegExpPattern`);function Jv(e){let t=Lg(e,e=>!V(e,Hv));return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- missing static 'PATTERN' property`,type:K.MISSING_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Jv,`findMissingPatterns`);function Yv(e){let t=Lg(e,e=>{let t=e[Hv];return!S_(t)&&!Ss(t)&&!V(t,`exec`)&&!i_(t)});return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.`,type:K.INVALID_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Yv,`findInvalidPatterns`);var Xv=/[^\\][$]/;function Zv(e){class t extends ba{static{o(this,`EndAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitEndAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return Xv.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain end of input anchor '$' + See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.EOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(Zv,`findEndOfInputAnchor`);function Qv(e){return B(Lg(e,e=>e.PATTERN.test(``)),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' must not match an empty string`,type:K.EMPTY_MATCH_PATTERN,tokenTypes:[e]}))}o(Qv,`findEmptyMatchRegExps`);var $v=/[^\\[][\^]|^\^/;function ey(e){class t extends ba{static{o(this,`StartAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitStartAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return $v.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain start of input anchor '^' + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.SOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(ey,`findStartOfInputAnchor`);function ty(e){return B(Lg(e,e=>{let t=e[Hv];return t instanceof RegExp&&(t.multiline||t.global)}),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' may NOT contain global('g') or multiline('m')`,type:K.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}))}o(ty,`findUnsupportedFlags`);function ny(e){let t=[],n=B(e,n=>L_(e,(e,r)=>n.PATTERN.source===r.PATTERN.source&&!u_(t,r)&&r.PATTERN!==Vy.NA?(t.push(r),e.push(r),e):e,[]));return n=wm(n),B(Lg(n,e=>e.length>1),e=>{let t=B(e,e=>e.name);return{message:`The same RegExp pattern ->${Wg(e).PATTERN}<-has been used in all of the following Token Types: ${t.join(`, `)} <-`,type:K.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}})}o(ny,`findDuplicatePatterns`);function ry(e){return B(Lg(e,e=>{if(!V(e,`GROUP`))return!1;let t=e.GROUP;return t!==Vy.SKIPPED&&t!==Vy.NA&&!i_(t)}),e=>({message:`Token Type: ->`+e.name+`<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String`,type:K.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}))}o(ry,`findInvalidGroupType`);function iy(e,t){return B(Lg(e,e=>e.PUSH_MODE!==void 0&&!u_(t,e.PUSH_MODE)),e=>({message:`Token Type: ->${e.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${e.PUSH_MODE}<-which does not exist`,type:K.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}))}o(iy,`findModesThatDoNotExist`);function ay(e){let t=[],n=L_(e,(e,t,n)=>{let r=t.PATTERN;return r===Vy.NA||(i_(r)?e.push({str:r,idx:n,tokenType:t}):S_(r)&&sy(r)&&e.push({str:r.source,idx:n,tokenType:t})),e},[]);return z(e,(e,r)=>{z(n,({str:n,idx:i,tokenType:a})=>{if(r${a.name}<- can never be matched. +Because it appears AFTER the Token Type ->${e.name}<-in the lexer's definition. +See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;t.push({message:n,type:K.UNREACHABLE_PATTERN,tokenTypes:[e,a]})}})}),t}o(ay,`findUnreachablePatterns`);function oy(e,t){if(S_(t)){if(cy(t))return!1;let n=t.exec(e);return n!==null&&n.index===0}if(Ss(t))return t(e,0,[],{});if(V(t,`exec`))return t.exec(e,0,[],{});if(typeof t==`string`)return t===e;throw Error(`non exhaustive match`)}o(oy,`tryToMatchStrToPattern`);function sy(e){return Hg([`.`,`\\`,`[`,`]`,`|`,`^`,`$`,`(`,`)`,`?`,`*`,`+`,`{`],t=>e.source.indexOf(t)!==-1)===void 0}o(sy,`noMetaChar`);function cy(e){return/(\(\?=)|(\(\?!)|(\(\?<=)|(\(\? property in its definition +`,type:K.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),V(e,Wv)||r.push({message:`A MultiMode Lexer cannot be initialized without a <`+Wv+`> property in its definition +`,type:K.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),V(e,Wv)&&V(e,Uv)&&!V(e.modes,e.defaultMode)&&r.push({message:`A MultiMode Lexer cannot be initialized with a ${Uv}: <${e.defaultMode}>which does not exist +`,type:K.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),V(e,Wv)&&z(e.modes,(e,t)=>{z(e,(n,i)=>{w_(n)?r.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${t}> at index: <${i}> +`,type:K.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED}):V(n,`LONGER_ALT`)&&z(I(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT],i=>{!w_(i)&&!u_(e,i)&&r.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${i.name}> on token <${n.name}> outside of mode <${t}> +`,type:K.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})})})}),r}o(uy,`performRuntimeChecks`);function dy(e,t,n){let r=[],i=!1,a=z_(wm(Ld(H(e.modes))),e=>e[Hv]===Vy.NA),o=vy(n);return t&&z(a,e=>{let t=gy(e,o);if(t!==!1){let n={message:_y(e,t),type:t.issue,tokenType:e};r.push(n)}else V(e,`LINE_BREAKS`)?e.LINE_BREAKS===!0&&(i=!0):Vv(o,e.PATTERN)&&(i=!0)}),t&&!i&&r.push({message:`Warning: No LINE_BREAKS Found. + This Lexer has been defined to track line and column information, + But none of the Token Types can be identified as matching a line terminator. + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS + for details.`,type:K.NO_LINE_BREAKS_FLAGS}),r}o(dy,`performWarningRuntimeChecks`);function fy(e){let t={};return z(eu(e),n=>{let r=e[n];if(I(r))t[n]=[];else throw Error(`non exhaustive match`)}),t}o(fy,`cloneEmptyGroups`);function py(e){let t=e.PATTERN;if(S_(t))return!1;if(Ss(t)||V(t,`exec`))return!0;if(i_(t))return!1;throw Error(`non exhaustive match`)}o(py,`isCustomPattern`);function my(e){return i_(e)&&e.length===1?e.charCodeAt(0):!1}o(my,`isShortPattern`);var hy={test:o(function(e){let t=e.length;for(let n=this.lastIndex;n Token Type + Root cause: ${t.errMsg}. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(t.issue===K.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. + The problem is in the <${e.name}> Token Type + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error(`non exhaustive match`)}o(_y,`buildLineBreakIssueMessage`);function vy(e){return B(e,e=>i_(e)?e.charCodeAt(0):e)}o(vy,`getCharCodes`);function yy(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}o(yy,`addToMapOfArrays`);var by=256,xy=[];function Sy(e){return e255?255+~~(e/255):e}}o(Cy,`initCharCodeToOptimizedIndexMap`);function wy(e,t){let n=e.tokenTypeIdx;return n===t.tokenTypeIdx||t.isParent===!0&&t.categoryMatchesMap[n]===!0}o(wy,`tokenStructuredMatcher`);function Ty(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}o(Ty,`tokenStructuredMatcherNoCategories`);var Ey=1,Dy={};function Oy(e){let t=ky(e);Ay(t),My(t),jy(t),z(t,e=>{e.isParent=e.categoryMatches.length>0})}o(Oy,`augmentTokenTypes`);function ky(e){let t=Sm(e),n=e,r=!0;for(;r;){n=wm(Ld(B(n,e=>e.CATEGORIES)));let e=vg(n,t);t=t.concat(e),U(e)?r=!1:n=e}return t}o(ky,`expandCategories`);function Ay(e){z(e,e=>{Py(e)||(Dy[Ey]=e,e.tokenTypeIdx=Ey++),Fy(e)&&!I(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),Fy(e)||(e.CATEGORIES=[]),Iy(e)||(e.categoryMatches=[]),Ly(e)||(e.categoryMatchesMap={})})}o(Ay,`assignTokenDefaultProps`);function jy(e){z(e,e=>{e.categoryMatches=[],z(e.categoryMatchesMap,(t,n)=>{e.categoryMatches.push(Dy[n].tokenTypeIdx)})})}o(jy,`assignCategoriesTokensProp`);function My(e){z(e,e=>{Ny([],e)})}o(My,`assignCategoriesMapProp`);function Ny(e,t){z(e,e=>{t.categoryMatchesMap[e.tokenTypeIdx]=!0}),z(t.CATEGORIES,n=>{let r=e.concat(t);u_(r,n)||Ny(r,n)})}o(Ny,`singleAssignCategoriesToksMap`);function Py(e){return V(e,`tokenTypeIdx`)}o(Py,`hasShortKeyProperty`);function Fy(e){return V(e,`CATEGORIES`)}o(Fy,`hasCategoriesProperty`);function Iy(e){return V(e,`categoryMatches`)}o(Iy,`hasExtendingTokensTypesProperty`);function Ly(e){return V(e,`categoryMatchesMap`)}o(Ly,`hasExtendingTokensTypesMapProperty`);function Ry(e){return V(e,`tokenTypeIdx`)}o(Ry,`isTokenType`);var zy={buildUnableToPopLexerModeMessage(e){return`Unable to pop Lexer Mode after encountering Token ->${e.image}<- The Mode Stack is empty`},buildUnexpectedCharactersMessage(e,t,n,r,i,a){return`unexpected character: ->${e.charAt(t)}<- at offset: ${t}, skipped ${n} characters.`}},K;(function(e){e[e.MISSING_PATTERN=0]=`MISSING_PATTERN`,e[e.INVALID_PATTERN=1]=`INVALID_PATTERN`,e[e.EOI_ANCHOR_FOUND=2]=`EOI_ANCHOR_FOUND`,e[e.UNSUPPORTED_FLAGS_FOUND=3]=`UNSUPPORTED_FLAGS_FOUND`,e[e.DUPLICATE_PATTERNS_FOUND=4]=`DUPLICATE_PATTERNS_FOUND`,e[e.INVALID_GROUP_TYPE_FOUND=5]=`INVALID_GROUP_TYPE_FOUND`,e[e.PUSH_MODE_DOES_NOT_EXIST=6]=`PUSH_MODE_DOES_NOT_EXIST`,e[e.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]=`MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE`,e[e.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]=`MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY`,e[e.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]=`MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST`,e[e.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]=`LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED`,e[e.SOI_ANCHOR_FOUND=11]=`SOI_ANCHOR_FOUND`,e[e.EMPTY_MATCH_PATTERN=12]=`EMPTY_MATCH_PATTERN`,e[e.NO_LINE_BREAKS_FLAGS=13]=`NO_LINE_BREAKS_FLAGS`,e[e.UNREACHABLE_PATTERN=14]=`UNREACHABLE_PATTERN`,e[e.IDENTIFY_TERMINATOR=15]=`IDENTIFY_TERMINATOR`,e[e.CUSTOM_LINE_BREAK=16]=`CUSTOM_LINE_BREAK`,e[e.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]=`MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE`})(K||={});var By={deferDefinitionErrorsHandling:!1,positionTracking:`full`,lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` +`,`\r`],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:zy,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(By);var Vy=class{static{o(this,`Lexer`)}constructor(e,t=By){if(this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(e,t)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()},typeof t==`boolean`)throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. +a boolean 2nd argument is no longer supported`);this.config=nu({},By,t);let n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof n==`number`&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT(`Lexer Constructor`,()=>{let n,r=!0;this.TRACE_INIT(`Lexer Config handling`,()=>{if(this.config.lineTerminatorsPattern===By.lineTerminatorsPattern)this.config.lineTerminatorsPattern=hy;else if(this.config.lineTerminatorCharacters===By.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error(`"safeMode" and "ensureOptimizations" flags are mutually exclusive.`);this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),I(e)?n={modes:{defaultMode:Sm(e)},defaultMode:Uv}:(r=!1,n=Sm(e))}),this.config.skipValidations===!1&&(this.TRACE_INIT(`performRuntimeChecks`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(uy(n,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT(`performWarningRuntimeChecks`,()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(dy(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),n.modes=n.modes?n.modes:{},z(n.modes,(e,t)=>{n.modes[t]=z_(e,e=>w_(e))});let i=eu(n.modes);if(z(n.modes,(e,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,()=>{if(this.modes.push(n),this.config.skipValidations===!1&&this.TRACE_INIT(`validatePatterns`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(Kv(e,i))}),U(this.lexerDefinitionErrors)){Oy(e);let r;this.TRACE_INIT(`analyzeTokenTypes`,()=>{r=Gv(e,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[n]=r.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=r.charCodeToPatternIdxToConfig,this.emptyGroups=nu({},this.emptyGroups,r.emptyGroups),this.hasCustom=r.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=r.canBeOptimized}})}),this.defaultMode=n.defaultMode,!U(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Errors detected in definition of Lexer: +`+e)}z(this.lexerDefinitionWarning,e=>{Z_(e.message)}),this.TRACE_INIT(`Choosing sub-methods implementations`,()=>{if(r&&(this.handleModes=Ys),this.trackStartLines===!1&&(this.computeNewColumn=gs),this.trackEndLines===!1&&(this.updateTokenEndLineColumnLocation=Ys),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else if(/onlyOffset/i.test(this.config.positionTracking))this.createTokenInstance=this.createOffsetOnlyToken;else throw Error(`Invalid config option: "${this.config.positionTracking}"`);this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)}),this.TRACE_INIT(`Failed Optimization Warnings`,()=>{let e=L_(this.canModeBeOptimized,(e,t,n)=>(t===!1&&e.push(n),e),[]);if(t.ensureOptimizations&&!U(e))throw Error(`Lexer Modes: < ${e.join(`, `)} > cannot be optimized. + Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. + Or inspect the console log for details on how to resolve these issues.`)}),this.TRACE_INIT(`clearRegExpParserCache`,()=>{jv()}),this.TRACE_INIT(`toFastProperties`,()=>{$_(this)})})}tokenize(e,t=this.defaultMode){if(!U(this.lexerDefinitionErrors)){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Unable to Tokenize because Errors detected in definition of Lexer: +`+e)}return this.tokenizeInternal(e,t)}tokenizeInternal(e,t){let n,r,i,a,s,c,l,u,d,f,p,m,h,g,_,v=e,y=v.length,b=0,x=0,ee=this.hasCustom?0:Math.floor(e.length/10),S=Array(ee),te=[],ne=this.trackStartLines?1:void 0,C=this.trackStartLines?1:void 0,re=fy(this.emptyGroups),ie=this.trackStartLines,ae=this.config.lineTerminatorsPattern,oe=0,se=[],ce=[],le=[],ue=[];Object.freeze(ue);let de=!1,w=o(e=>{if(le.length===1&&e.tokenType.PUSH_MODE===void 0){let t=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);te.push({offset:e.startOffset,line:e.startLine,column:e.startColumn,length:e.image.length,message:t})}else{le.pop();let e=bg(le);se=this.patternIdxToConfig[e],ce=this.charCodeToPatternIdxToConfig[e],oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=!!(ce&&t)}},`pop_mode`);function T(e){le.push(e),ce=this.charCodeToPatternIdxToConfig[e],se=this.patternIdxToConfig[e],oe=se.length,oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=!!(ce&&t)}o(T,`push_mode`),T.call(this,t);let E,D=this.config.recoveryEnabled;for(;bc.length){c=a,d=a.length,l=u,E=t;break}}}break}}if(d!==-1){if(f=E.group,f!==void 0&&(c=c===null?e.substring(b,b+d):c,p=E.tokenTypeIdx,m=this.createTokenInstance(c,b,p,E.tokenType,ne,C,d),this.handlePayload(m,l),f===!1?x=this.addToken(S,x,m):re[f].push(m)),ie===!0&&E.canLineTerminator===!0){let t=0,n,r;ae.lastIndex=0;do c=c===null?e.substring(b,b+d):c,n=ae.test(c),n===!0&&(r=ae.lastIndex-1,t++);while(n===!0);t===0?C=this.computeNewColumn(C,d):(ne+=t,C=d-r,this.updateTokenEndLineColumnLocation(m,f,r,t,ne,C,d))}else C=this.computeNewColumn(C,d);b+=d,this.handleModes(E,w,T,m)}else{let t=b,n=ne,i=C,a=D===!1;for(;a===!1&&b ${Hy(e)} <--`:`token of type --> ${e.name} <--`} but found --> '${t.image}' <--`},buildNotAllInputParsedMessage({firstRedundant:e,ruleName:t}){return`Redundant input, expecting EOF but found: `+e.image},buildNoViableAltMessage({expectedPathsPerAlt:e,actual:t,previous:n,customUserDescription:r,ruleName:i}){let a=` +but found: '`+Wg(t).image+`'`;return r?`Expecting: `+r+a:`Expecting: one of these possible Token sequences: +${B(B(L_(e,(e,t)=>e.concat(t),[]),e=>`[${B(e,e=>Hy(e)).join(`, `)}]`),(e,t)=>` ${t+1}. ${e}`).join(` +`)}`+a},buildEarlyExitMessage({expectedIterationPaths:e,actual:t,customUserDescription:n,ruleName:r}){let i=` +but found: '`+Wg(t).image+`'`;return n?`Expecting: `+n+i:`Expecting: expecting at least one iteration which starts with one of these possible Token sequences:: + <${B(e,e=>`[${B(e,e=>Hy(e)).join(`,`)}]`).join(` ,`)}>`+i}};Object.freeze(ib);var ab={buildRuleNotFoundError(e,t){return`Invalid grammar, reference to a rule which is not defined: ->`+t.nonTerminalName+`<- +inside top level rule: ->`+e.name+`<-`}},ob={buildDuplicateFoundError(e,t){function n(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(n,`getExtraProductionArgument`);let r=e.name,i=Wg(t),a=i.idx,s=_v(i),c=n(i),l=`->${s}${a>0?a:``}<- ${c?`with argument: ->${c}<-`:``} + appears more than once (${t.length} times) in the top level rule: ->${r}<-. + For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES + `;return l=l.replace(/[ \t]+/g,` `),l=l.replace(/\s\s+/g,` +`),l},buildNamespaceConflictError(e){return`Namespace conflict found in grammar. +The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${e.name}>. +To resolve this make sure each Terminal and Non-Terminal names are unique +This is easy to accomplish by using the convention that Terminal names start with an uppercase letter +and Non-Terminal names start with a lower case letter.`},buildAlternationPrefixAmbiguityError(e){let t=B(e.prefixPath,e=>Hy(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx;return`Ambiguous alternatives: <${e.ambiguityIndices.join(` ,`)}> due to common lookahead prefix +in inside <${e.topLevelRule.name}> Rule, +<${t}> may appears as a prefix path in all these alternatives. +See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX +For Further details.`},buildAlternationAmbiguityError(e){let t=e.alternation.idx===0?``:e.alternation.idx,n=e.prefixPath.length===0,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(` ,`)}> in inside <${e.topLevelRule.name}> Rule, +`;if(n)r+=`These alternatives are all empty (match no tokens), making them indistinguishable. +Only the last alternative may be empty. +`;else{let t=B(e.prefixPath,e=>Hy(e)).join(`, `);r+=`<${t}> may appears as a prefix path in all these alternatives. +`}return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r},buildEmptyRepetitionError(e){let t=_v(e.repetition);return e.repetition.idx!==0&&(t+=e.repetition.idx),`The repetition <${t}> within Rule <${e.topLevelRule.name}> can never consume any tokens. +This could lead to an infinite loop.`},buildTokenNameError(e){return`deprecated`},buildEmptyAlternationError(e){return`Ambiguous empty alternative: <${e.emptyChoiceIdx+1}> in inside <${e.topLevelRule.name}> Rule. +Only the last alternative may be an empty alternative.`},buildTooManyAlternativesError(e){return`An Alternation cannot have more than 256 alternatives: + inside <${e.topLevelRule.name}> Rule. + has ${e.alternation.definition.length+1} alternatives.`},buildLeftRecursionError(e){let t=e.topLevelRule.name;return`Left Recursion found in grammar. +rule: <${t}> can be invoked from itself (directly or indirectly) +without consuming any Tokens. The grammar path that causes this is: + ${`${t} --> ${B(e.leftRecursionPath,e=>e.name).concat([t]).join(` --> `)}`} + To fix this refactor your grammar to remove the left recursion. +see: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError(e){return`deprecated`},buildDuplicateRuleNameError(e){let t;return t=e.topLevelRule instanceof iv?e.topLevelRule.name:e.topLevelRule,`Duplicate definition, rule: ->${t}<- is already defined in the grammar: ->${e.grammarName}<-`}};function sb(e,t){let n=new cb(e,t);return n.resolveRefs(),n.errors}o(sb,`resolveGrammar`);var cb=class extends pv{static{o(this,`GastRefResolverVisitor`)}constructor(e,t){super(),this.nameToTopRule=e,this.errMsgProvider=t,this.errors=[]}resolveRefs(){z(H(this.nameToTopRule),e=>{this.currTopLevel=e,e.accept(this)})}visitNonTerminal(e){let t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{let t=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:t,type:pS.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}}},lb=class extends vv{static{o(this,`AbstractNextPossibleTokensWalker`)}constructor(e,t){super(),this.topProd=e,this.path=t,this.possibleTokTypes=[],this.nextProductionName=``,this.nextProductionOccurrence=0,this.found=!1,this.isAtEndOfPath=!1}startWalking(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error(`The path does not start with the walker's top Rule!`);return this.ruleStack=Sm(this.path.ruleStack).reverse(),this.occurrenceStack=Sm(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes}walk(e,t=[]){this.found||super.walk(e,t)}walkProdRef(e,t,n){if(e.referencedRule.name===this.nextProductionName&&e.idx===this.nextProductionOccurrence){let r=t.concat(n);this.updateExpectedNext(),this.walk(e.referencedRule,r)}}updateExpectedNext(){U(this.ruleStack)?(this.nextProductionName=``,this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())}},ub=class extends lb{static{o(this,`NextAfterTokenWalker`)}constructor(e,t){super(e,t),this.path=t,this.nextTerminalName=``,this.nextTerminalOccurrence=0,this.nextTerminalName=this.path.lastTok.name,this.nextTerminalOccurrence=this.path.lastTokOccurrence}walkTerminal(e,t,n){if(this.isAtEndOfPath&&e.terminalType.name===this.nextTerminalName&&e.idx===this.nextTerminalOccurrence&&!this.found){let e=new av({definition:t.concat(n)});this.possibleTokTypes=bv(e),this.found=!0}}},db=class extends vv{static{o(this,`AbstractNextTerminalAfterProductionWalker`)}constructor(e,t){super(),this.topRule=e,this.occurrence=t,this.result={token:void 0,occurrence:void 0,isEndOfRule:void 0}}startWalking(){return this.walk(this.topRule),this.result}},fb=class extends db{static{o(this,`NextTerminalAfterManyWalker`)}walkMany(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkMany(e,t,n)}},pb=class extends db{static{o(this,`NextTerminalAfterManySepWalker`)}walkManySep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkManySep(e,t,n)}},mb=class extends db{static{o(this,`NextTerminalAfterAtLeastOneWalker`)}walkAtLeastOne(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOne(e,t,n)}},hb=class extends db{static{o(this,`NextTerminalAfterAtLeastOneSepWalker`)}walkAtLeastOneSep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOneSep(e,t,n)}};function gb(e,t,n=[]){n=Sm(n);let r=[],i=0;function a(t){return t.concat(Sg(e,i+1))}o(a,`remainingPathWith`);function s(e){let i=gb(a(e),t,n);return r.concat(i)}for(o(s,`getAlternativesForProd`);n.length{U(e.definition)===!1&&(r=s(e.definition))}),r;else if(t instanceof G)n.push(t.terminalType);else throw Error(`non exhaustive match`);i++}return r.push({partialPath:n,suffixDef:Sg(e,i)}),r}o(gb,`possiblePathsFrom`);function _b(e,t,n,r){let i=`EXIT_NONE_TERMINAL`,a=[i],o=`EXIT_ALTERNATIVE`,s=!1,c=t.length,l=c-r-1,u=[],d=[];for(d.push({idx:-1,def:e,ruleStack:[],occurrenceStack:[]});!U(d);){let e=d.pop();if(e===o){s&&bg(d).idx<=l&&d.pop();continue}let r=e.def,f=e.idx,p=e.ruleStack,m=e.occurrenceStack;if(U(r))continue;let h=r[0];if(h===i){let e={idx:f,def:Sg(r),ruleStack:wg(p),occurrenceStack:wg(m)};d.push(e)}else if(h instanceof G){if(f=0;e--){let t={idx:f,def:h.definition[e].definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t),d.push(o)}else if(h instanceof av)d.push({idx:f,def:h.definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m});else if(h instanceof iv)d.push(vb(h,f,p,m));else throw Error(`non exhaustive match`)}return u}o(_b,`nextPossibleTokensAfter`);function vb(e,t,n,r){let i=Sm(n);i.push(e.name);let a=Sm(r);return a.push(1),{idx:t,def:e.definition,ruleStack:i,occurrenceStack:a}}o(vb,`expandTopLevelRule`);var q;(function(e){e[e.OPTION=0]=`OPTION`,e[e.REPETITION=1]=`REPETITION`,e[e.REPETITION_MANDATORY=2]=`REPETITION_MANDATORY`,e[e.REPETITION_MANDATORY_WITH_SEPARATOR=3]=`REPETITION_MANDATORY_WITH_SEPARATOR`,e[e.REPETITION_WITH_SEPARATOR=4]=`REPETITION_WITH_SEPARATOR`,e[e.ALTERNATION=5]=`ALTERNATION`})(q||={});function yb(e){if(e instanceof ov||e===`Option`)return q.OPTION;if(e instanceof W||e===`Repetition`)return q.REPETITION;if(e instanceof sv||e===`RepetitionMandatory`)return q.REPETITION_MANDATORY;if(e instanceof cv||e===`RepetitionMandatoryWithSeparator`)return q.REPETITION_MANDATORY_WITH_SEPARATOR;if(e instanceof lv||e===`RepetitionWithSeparator`)return q.REPETITION_WITH_SEPARATOR;if(e instanceof uv||e===`Alternation`)return q.ALTERNATION;throw Error(`non exhaustive match`)}o(yb,`getProdType`);function bb(e){let{occurrence:t,rule:n,prodType:r,maxLookahead:i}=e,a=yb(r);return a===q.ALTERNATION?jb(t,n,i):Mb(t,n,a,i)}o(bb,`getLookaheadPaths`);function xb(e,t,n,r,i,a){let o=jb(e,t,n);return a(o,r,Fb(o)?Ty:wy,i)}o(xb,`buildLookaheadFuncForOr`);function Sb(e,t,n,r,i,a){let o=Mb(e,t,i,n),s=Fb(o)?Ty:wy;return a(o[0],s,r)}o(Sb,`buildLookaheadFuncForOptionalProd`);function Cb(e,t,n,r){let i=e.length,a=Ng(e,e=>Ng(e,e=>e.length===1));if(t)return function(t){let r=B(t,e=>e.GATE);for(let t=0;tLd(e)),(e,t,n)=>(z(t,t=>{V(e,t.tokenTypeIdx)||(e[t.tokenTypeIdx]=n),z(t.categoryMatches,t=>{V(e,t)||(e[t]=n)})}),e),{});return function(){let e=this.LA(1);return t[e.tokenTypeIdx]}}return function(){for(let t=0;te.length===1),i=e.length;if(r&&!n){let t=Ld(e);if(t.length===1&&U(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=L_(t,(e,t,n)=>(e[t.tokenTypeIdx]=!0,z(t.categoryMatches,t=>{e[t]=!0}),e),[]);return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){nextPath:for(let n=0;ngb([e],1)),r=Db(n.length),i=B(n,e=>{let t={};return z(e,e=>{z(Ob(e.partialPath),e=>{t[e]=!0})}),t}),a=n;for(let e=1;e<=t;e++){let n=a;a=Db(n.length);for(let o=0;o{z(Ob(e.partialPath),e=>{i[o][e]=!0})})}}}}return r}o(Ab,`lookAheadSequenceFromAlternatives`);function jb(e,t,n,r){let i=new Eb(e,q.ALTERNATION,r);return t.accept(i),Ab(i.result,n)}o(jb,`getLookaheadPathsForOr`);function Mb(e,t,n,r){let i=new Eb(e,n);t.accept(i);let a=i.result,o=new Tb(t,e,n).startWalking();return Ab([new av({definition:a}),new av({definition:o})],r)}o(Mb,`getLookaheadPathsForOptionalProd`);function Nb(e,t){compareOtherPath:for(let n=0;n{let r=t[n];return e===r||r.categoryMatchesMap[e.tokenTypeIdx]})}o(Pb,`isStrictPrefixOfPath`);function Fb(e){return Ng(e,e=>Ng(e,e=>Ng(e,e=>U(e.categoryMatches))))}o(Fb,`areTokenCategoriesNotUsed`);function Ib(e){return B(e.lookaheadStrategy.validate({rules:e.rules,tokenTypes:e.tokenTypes,grammarName:e.grammarName}),e=>Object.assign({type:pS.CUSTOM_LOOKAHEAD_VALIDATION},e))}o(Ib,`validateLookahead`);function Lb(e,t,n,r){let i=Yg(e,e=>Rb(e,n)),a=ex(e,t,n),o=Yg(e,e=>Xb(e,n)),s=Yg(e,t=>Hb(t,e,r,n));return i.concat(a,o,s)}o(Lb,`validateGrammar`);function Rb(e,t){let n=new Vb;e.accept(n);let r=n.allProductions;return B(H(N_(Zg(r,zb),e=>e.length>1)),n=>{let r=Wg(n),i=t.buildDuplicateFoundError(e,n),a=_v(r),o={message:i,type:pS.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:a,occurrence:r.idx},s=Bb(r);return s&&(o.parameter=s),o})}o(Rb,`validateDuplicateProductions`);function zb(e){return`${_v(e)}_#_${e.idx}_#_${Bb(e)}`}o(zb,`identifyProductionForDuplicates`);function Bb(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(Bb,`getExtraProductionArgument`);var Vb=class extends pv{static{o(this,`OccurrenceValidationCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(e){this.allProductions.push(e)}visitOption(e){this.allProductions.push(e)}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}visitAlternation(e){this.allProductions.push(e)}visitTerminal(e){this.allProductions.push(e)}};function Hb(e,t,n,r){let i=[];if(L_(t,(t,n)=>n.name===e.name?t+1:t,0)>1){let t=r.buildDuplicateRuleNameError({topLevelRule:e,grammarName:n});i.push({message:t,type:pS.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}o(Hb,`validateRuleDoesNotAlreadyExist`);function Ub(e,t,n){let r=[],i;return u_(t,e)||(i=`Invalid rule override, rule: ->${e}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:pS.INVALID_RULE_OVERRIDE,ruleName:e})),r}o(Ub,`validateRuleIsOverridden`);function Wb(e,t,n,r=[]){let i=[],a=Gb(t.definition);if(U(a))return[];{let t=e.name;u_(a,e)&&i.push({message:n.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:r}),type:pS.LEFT_RECURSION,ruleName:t});let o=Yg(vg(a,r.concat([e])),t=>{let i=Sm(r);return i.push(t),Wb(e,t,n,i)});return i.concat(o)}}o(Wb,`validateNoLeftRecursion`);function Gb(e){let t=[];if(U(e))return t;let n=Wg(e);if(n instanceof rv)t.push(n.referencedRule);else if(n instanceof av||n instanceof ov||n instanceof sv||n instanceof cv||n instanceof lv||n instanceof W)t=t.concat(Gb(n.definition));else if(n instanceof uv)t=Ld(B(n.definition,e=>Gb(e.definition)));else if(!(n instanceof G))throw Error(`non exhaustive match`);let r=hv(n),i=e.length>1;if(r&&i){let n=Sg(e);return t.concat(Gb(n))}return t}o(Gb,`getFirstNoneTerminal`);var Kb=class extends pv{static{o(this,`OrCollector`)}constructor(){super(...arguments),this.alternations=[]}visitAlternation(e){this.alternations.push(e)}};function qb(e,t){let n=new Kb;e.accept(n);let r=n.alternations;return Yg(r,n=>Yg(wg(n.definition),(r,i)=>U(_b([r],[],wy,1))?[{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:pS.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}]:[]))}o(qb,`validateEmptyOrAlternative`);function Jb(e,t,n){let r=new Kb;e.accept(r);let i=r.alternations;return i=z_(i,e=>e.ignoreAmbiguities===!0),Yg(i,r=>{let i=r.idx,a=jb(i,e,r.maxLookahead||t,r),o=Qb(a,r,e,n),s=$b(a,r,e,n);return o.concat(s)})}o(Jb,`validateAmbiguousAlternationAlternatives`);var Yb=class extends pv{static{o(this,`RepetitionCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}};function Xb(e,t){let n=new Kb;e.accept(n);let r=n.alternations;return Yg(r,n=>n.definition.length>255?[{message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:pS.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}]:[])}o(Xb,`validateTooManyAlts`);function Zb(e,t,n){let r=[];return z(e,e=>{let i=new Yb;e.accept(i);let a=i.allProductions;z(a,i=>{let a=yb(i),o=i.maxLookahead||t,s=i.idx,c=Mb(s,e,a,o)[0];if(U(Ld(c))){let t=n.buildEmptyRepetitionError({topLevelRule:e,repetition:i});r.push({message:t,type:pS.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}})}),r}o(Zb,`validateSomeNonEmptyLookaheadPath`);function Qb(e,t,n,r){let i=[];return B(L_(e,(n,r,a)=>(t.definition[a].ignoreAmbiguities===!0||z(r,r=>{let o=[a];z(e,(e,n)=>{a!==n&&Nb(e,r)&&t.definition[n].ignoreAmbiguities!==!0&&o.push(n)}),o.length>1&&!Nb(i,r)&&(i.push(r),n.push({alts:o,path:r}))}),n),[]),e=>{let i=B(e.alts,e=>e+1);return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:pS.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:t.idx,alternatives:e.alts}})}o(Qb,`checkAlternativesAmbiguities`);function $b(e,t,n,r){let i=L_(e,(e,t,n)=>{let r=B(t,e=>({idx:n,path:e}));return e.concat(r)},[]);return wm(Yg(i,e=>{if(t.definition[e.idx].ignoreAmbiguities===!0)return[];let a=e.idx,o=e.path;return B(Lg(i,e=>t.definition[e.idx].ignoreAmbiguities!==!0&&e.idx{let i=[e.idx+1,a+1],o=t.idx===0?``:t.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:pS.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}})}))}o($b,`checkPrefixAlternativesAmbiguities`);function ex(e,t,n){let r=[],i=B(t,e=>e.name);return z(e,e=>{let t=e.name;if(u_(i,t)){let i=n.buildNamespaceConflictError(e);r.push({message:i,type:pS.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}}),r}o(ex,`checkTerminalAndNoneTerminalsNameSpace`);function tx(e){let t=ug(e,{errMsgProvider:ab}),n={};return z(e.rules,e=>{n[e.name]=e}),sb(n,t.errMsgProvider)}o(tx,`resolveGrammar`);function nx(e){return e=ug(e,{errMsgProvider:ob}),Lb(e.rules,e.tokenTypes,e.errMsgProvider,e.grammarName)}o(nx,`validateGrammar`);var rx=`MismatchedTokenException`,ix=`NoViableAltException`,ax=`EarlyExitException`,ox=`NotAllInputParsedException`,sx=[rx,ix,ax,ox];Object.freeze(sx);function cx(e){return u_(sx,e.name)}o(cx,`isRecognitionException`);var lx=class extends Error{static{o(this,`RecognitionException`)}constructor(e,t){super(e),this.token=t,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}},ux=class extends lx{static{o(this,`MismatchedTokenException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=rx}},dx=class extends lx{static{o(this,`NoViableAltException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ix}},fx=class extends lx{static{o(this,`NotAllInputParsedException`)}constructor(e,t){super(e,t),this.name=ox}},px=class extends lx{static{o(this,`EarlyExitException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ax}},mx={},hx=`InRuleRecoveryException`,gx=class extends Error{static{o(this,`InRuleRecoveryException`)}constructor(e){super(e),this.name=hx}},_x=class{static{o(this,`Recoverable`)}initRecoverable(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=V(e,`recoveryEnabled`)?e.recoveryEnabled:dS.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=vx)}getTokenToInsert(e){let t=nb(e,``,NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t}canTokenTypeBeInsertedInRecovery(e){return!0}canTokenTypeBeDeletedInRecovery(e){return!0}tryInRepetitionRecovery(e,t,n,r){let i=this.findReSyncTokenType(),a=this.exportLexerState(),s=[],c=!1,l=this.LA(1),u=this.LA(1),d=o(()=>{let e=this.LA(0),t=new ux(this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:l,previous:e,ruleName:this.getCurrRuleFullName()}),l,this.LA(0));t.resyncedTokens=wg(s),this.SAVE_ERROR(t)},`generateErrorMessage`);for(;!c;)if(this.tokenMatcher(u,r)){d();return}else if(n.call(this)){d(),e.apply(this,t);return}else this.tokenMatcher(u,i)?c=!0:(u=this.SKIP_TOKEN(),this.addToResyncTokens(u,s));this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(e,t,n){return!(n===!1||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t)))}getFollowsForInRuleRecovery(e,t){let n=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){let e=this.SKIP_TOKEN();return this.consumeToken(),e}throw new gx(`sad sad panda`)}canPerformInRuleRecovery(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)}canRecoverWithSingleTokenInsertion(e,t){if(!this.canTokenTypeBeInsertedInRecovery(e)||U(t))return!1;let n=this.LA(1);return Hg(t,e=>this.tokenMatcher(n,e))!==void 0}canRecoverWithSingleTokenDeletion(e){return this.canTokenTypeBeDeletedInRecovery(e)?this.tokenMatcher(this.LA(2),e):!1}isInCurrentRuleReSyncSet(e){let t=this.getCurrFollowKey();return u_(this.getFollowSetFromFollowKey(t),e)}findReSyncTokenType(){let e=this.flattenFollowSet(),t=this.LA(1),n=2;for(;;){let r=Hg(e,e=>rb(t,e));if(r!==void 0)return r;t=this.LA(n),n++}}getCurrFollowKey(){if(this.RULE_STACK.length===1)return mx;let e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){let e=this.RULE_STACK,t=this.RULE_OCCURRENCE_STACK;return B(e,(n,r)=>r===0?mx:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:t[r],inRule:this.shortRuleNameToFullName(e[r-1])})}flattenFollowSet(){return Ld(B(this.buildFullFollowKeyStack(),e=>this.getFollowSetFromFollowKey(e)))}getFollowSetFromFollowKey(e){if(e===mx)return[tb];let t=e.ruleName+e.idxInCallingRule+wv+e.inRule;return this.resyncFollows[t]}addToResyncTokens(e,t){return this.tokenMatcher(e,tb)||t.push(e),t}reSyncTo(e){let t=[],n=this.LA(1);for(;this.tokenMatcher(n,e)===!1;)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,t);return wg(t)}attemptInRepetitionRecovery(e,t,n,r,i,a,o){}getCurrentGrammarPath(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:Sm(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}}getHumanReadableRuleStack(){return B(this.RULE_STACK,e=>this.shortRuleNameToFullName(e))}};function vx(e,t,n,r,i,a,o){let s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(c===void 0){let e=this.getCurrRuleFullName(),t=this.getGAstProductions()[e];c=new a(t,i).startWalking(),this.firstAfterRepMap[s]=c}let l=c.token,u=c.occurrence,d=c.isEndOfRule;this.RULE_STACK.length===1&&d&&l===void 0&&(l=tb,u=1),l!==void 0&&u!==void 0&&this.shouldInRepetitionRecoveryBeTried(l,u,o)&&this.tryInRepetitionRecovery(e,t,n,l)}o(vx,`attemptInRepetitionRecovery`);var yx=4,bx=8,xx=8,Sx=1<Wb(e,e,ob))}validateEmptyOrAlternatives(e){return Yg(e,e=>qb(e,ob))}validateAmbiguousAlternationAlternatives(e,t){return Yg(e,e=>Jb(e,t,ob))}validateSomeNonEmptyLookaheadPath(e,t){return Zb(e,t,ob)}buildLookaheadForAlternation(e){return xb(e.prodOccurrence,e.rule,e.maxLookahead,e.hasPredicates,e.dynamicTokensEnabled,Cb)}buildLookaheadForOptional(e){return Sb(e.prodOccurrence,e.rule,e.maxLookahead,e.dynamicTokensEnabled,yb(e.prodType),wb)}},Ax=class{static{o(this,`LooksAhead`)}initLooksAhead(e){this.dynamicTokensEnabled=V(e,`dynamicTokensEnabled`)?e.dynamicTokensEnabled:dS.dynamicTokensEnabled,this.maxLookahead=V(e,`maxLookahead`)?e.maxLookahead:dS.maxLookahead,this.lookaheadStrategy=V(e,`lookaheadStrategy`)?e.lookaheadStrategy:new kx({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(e){z(e,e=>{this.TRACE_INIT(`${e.name} Rule Lookahead`,()=>{let{alternation:t,repetition:n,option:r,repetitionMandatory:i,repetitionMandatoryWithSeparator:a,repetitionWithSeparator:o}=Mx(e);z(t,t=>{let n=t.idx===0?``:t.idx;this.TRACE_INIT(`${_v(t)}${n}`,()=>{let n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:t.idx,rule:e,maxLookahead:t.maxLookahead||this.maxLookahead,hasPredicates:t.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=Ox(this.fullRuleNameToShort[e.name],Sx,t.idx);this.setLaFuncCache(r,n)})}),z(n,t=>{this.computeLookaheadFunc(e,t.idx,wx,`Repetition`,t.maxLookahead,_v(t))}),z(r,t=>{this.computeLookaheadFunc(e,t.idx,Cx,`Option`,t.maxLookahead,_v(t))}),z(i,t=>{this.computeLookaheadFunc(e,t.idx,Tx,`RepetitionMandatory`,t.maxLookahead,_v(t))}),z(a,t=>{this.computeLookaheadFunc(e,t.idx,Dx,`RepetitionMandatoryWithSeparator`,t.maxLookahead,_v(t))}),z(o,t=>{this.computeLookaheadFunc(e,t.idx,Ex,`RepetitionWithSeparator`,t.maxLookahead,_v(t))})})})}computeLookaheadFunc(e,t,n,r,i,a){this.TRACE_INIT(`${a}${t===0?``:t}`,()=>{let a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:t,rule:e,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),o=Ox(this.fullRuleNameToShort[e.name],n,t);this.setLaFuncCache(o,a)})}getKeyForAutomaticLookahead(e,t){return Ox(this.getLastExplicitRuleShortName(),e,t)}getLaFuncFromCache(e){return this.lookAheadFuncsCache.get(e)}setLaFuncCache(e,t){this.lookAheadFuncsCache.set(e,t)}},jx=new class extends pv{static{o(this,`DslMethodsCollectorVisitor`)}constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(e){this.dslMethods.option.push(e)}visitRepetitionWithSeparator(e){this.dslMethods.repetitionWithSeparator.push(e)}visitRepetitionMandatory(e){this.dslMethods.repetitionMandatory.push(e)}visitRepetitionMandatoryWithSeparator(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)}visitRepetition(e){this.dslMethods.repetition.push(e)}visitAlternation(e){this.dslMethods.alternation.push(e)}};function Mx(e){jx.reset(),e.accept(jx);let t=jx.dslMethods;return jx.reset(),t}o(Mx,`collectMethods`);function Nx(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffsete.msg);throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>: + ${t.join(` + +`).replace(/\n/g,` + `)}`)}},`validateVisitor`)},n.prototype.constructor=n,n._RULE_NAMES=t,n}o(Bx,`createBaseSemanticVisitorConstructor`);function Vx(e,t,n){let r=o(function(){},`derivedConstructor`);Rx(r,e+`BaseSemanticsWithDefaults`);let i=Object.create(n.prototype);return z(t,e=>{i[e]=zx}),r.prototype=i,r.prototype.constructor=r,r}o(Vx,`createBaseVisitorConstructorWithDefaults`);var Hx;(function(e){e[e.REDUNDANT_METHOD=0]=`REDUNDANT_METHOD`,e[e.MISSING_METHOD=1]=`MISSING_METHOD`})(Hx||={});function Ux(e,t){return Wx(e,t)}o(Ux,`validateVisitor`);function Wx(e,t){return wm(B(Lg(t,t=>Ss(e[t])===!1),t=>({msg:`Missing visitor method: <${t}> on ${e.constructor.name} CST Visitor.`,type:Hx.MISSING_METHOD,methodName:t})))}o(Wx,`validateMissingCstMethods`);var Gx=class{static{o(this,`TreeBuilder`)}initTreeBuilder(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=V(e,`nodeLocationTracking`)?e.nodeLocationTracking:dS.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=Ys,this.cstFinallyStateUpdate=Ys,this.cstPostTerminal=Ys,this.cstPostNonTerminal=Ys,this.cstPostRule=Ys;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Px,this.setNodeLocationFromNode=Px,this.cstPostRule=Ys,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Nx,this.setNodeLocationFromNode=Nx,this.cstPostRule=Ys,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=Ys,this.setInitialNodeLocation=Ys;else throw Error(`Invalid config option: "${e.nodeLocationTracking}"`)}setInitialNodeLocationOnlyOffsetRecovery(e){e.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(e){let t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(e){let t={name:e,children:Object.create(null)};this.setInitialNodeLocation(t),this.CST_STACK.push(t)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?(n.endOffset=t.endOffset,n.endLine=t.endLine,n.endColumn=t.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?n.endOffset=t.endOffset:n.startOffset=NaN}cstPostTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Fx(n,t,e),this.setNodeLocationFromToken(n.location,t)}cstPostNonTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Ix(n,t,e),this.setNodeLocationFromNode(n.location,e.location)}getBaseCstVisitorConstructor(){if(w_(this.baseCstVisitorConstructor)){let e=Bx(this.className,eu(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if(w_(this.baseCstVisitorWithDefaultsConstructor)){let e=Vx(this.className,eu(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-1]}getPreviousExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-2]}getLastExplicitRuleOccurrenceIndex(){let e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]}},Kx=class{static{o(this,`LexerAdapter`)}initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(e){if(this.selfAnalysisDone!==!0)throw Error(`Missing invocation at the end of the Parser's constructor.`);this.reset(),this.tokVector=e,this.tokVectorLength=e.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):uS}LA(e){let t=this.currIdx+e;return t<0||this.tokVectorLength<=t?uS:this.tokVector[t]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(e){this.currIdx=e}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},qx=class{static{o(this,`RecognizerApi`)}ACTION(e){return e.call(this)}consume(e,t,n){return this.consumeInternal(t,e,n)}subrule(e,t,n){return this.subruleInternal(t,e,n)}option(e,t){return this.optionInternal(t,e)}or(e,t){return this.orInternal(t,e)}many(e,t){return this.manyInternal(e,t)}atLeastOne(e,t){return this.atLeastOneInternal(e,t)}CONSUME(e,t){return this.consumeInternal(e,0,t)}CONSUME1(e,t){return this.consumeInternal(e,1,t)}CONSUME2(e,t){return this.consumeInternal(e,2,t)}CONSUME3(e,t){return this.consumeInternal(e,3,t)}CONSUME4(e,t){return this.consumeInternal(e,4,t)}CONSUME5(e,t){return this.consumeInternal(e,5,t)}CONSUME6(e,t){return this.consumeInternal(e,6,t)}CONSUME7(e,t){return this.consumeInternal(e,7,t)}CONSUME8(e,t){return this.consumeInternal(e,8,t)}CONSUME9(e,t){return this.consumeInternal(e,9,t)}SUBRULE(e,t){return this.subruleInternal(e,0,t)}SUBRULE1(e,t){return this.subruleInternal(e,1,t)}SUBRULE2(e,t){return this.subruleInternal(e,2,t)}SUBRULE3(e,t){return this.subruleInternal(e,3,t)}SUBRULE4(e,t){return this.subruleInternal(e,4,t)}SUBRULE5(e,t){return this.subruleInternal(e,5,t)}SUBRULE6(e,t){return this.subruleInternal(e,6,t)}SUBRULE7(e,t){return this.subruleInternal(e,7,t)}SUBRULE8(e,t){return this.subruleInternal(e,8,t)}SUBRULE9(e,t){return this.subruleInternal(e,9,t)}OPTION(e){return this.optionInternal(e,0)}OPTION1(e){return this.optionInternal(e,1)}OPTION2(e){return this.optionInternal(e,2)}OPTION3(e){return this.optionInternal(e,3)}OPTION4(e){return this.optionInternal(e,4)}OPTION5(e){return this.optionInternal(e,5)}OPTION6(e){return this.optionInternal(e,6)}OPTION7(e){return this.optionInternal(e,7)}OPTION8(e){return this.optionInternal(e,8)}OPTION9(e){return this.optionInternal(e,9)}OR(e){return this.orInternal(e,0)}OR1(e){return this.orInternal(e,1)}OR2(e){return this.orInternal(e,2)}OR3(e){return this.orInternal(e,3)}OR4(e){return this.orInternal(e,4)}OR5(e){return this.orInternal(e,5)}OR6(e){return this.orInternal(e,6)}OR7(e){return this.orInternal(e,7)}OR8(e){return this.orInternal(e,8)}OR9(e){return this.orInternal(e,9)}MANY(e){this.manyInternal(0,e)}MANY1(e){this.manyInternal(1,e)}MANY2(e){this.manyInternal(2,e)}MANY3(e){this.manyInternal(3,e)}MANY4(e){this.manyInternal(4,e)}MANY5(e){this.manyInternal(5,e)}MANY6(e){this.manyInternal(6,e)}MANY7(e){this.manyInternal(7,e)}MANY8(e){this.manyInternal(8,e)}MANY9(e){this.manyInternal(9,e)}MANY_SEP(e){this.manySepFirstInternal(0,e)}MANY_SEP1(e){this.manySepFirstInternal(1,e)}MANY_SEP2(e){this.manySepFirstInternal(2,e)}MANY_SEP3(e){this.manySepFirstInternal(3,e)}MANY_SEP4(e){this.manySepFirstInternal(4,e)}MANY_SEP5(e){this.manySepFirstInternal(5,e)}MANY_SEP6(e){this.manySepFirstInternal(6,e)}MANY_SEP7(e){this.manySepFirstInternal(7,e)}MANY_SEP8(e){this.manySepFirstInternal(8,e)}MANY_SEP9(e){this.manySepFirstInternal(9,e)}AT_LEAST_ONE(e){this.atLeastOneInternal(0,e)}AT_LEAST_ONE1(e){return this.atLeastOneInternal(1,e)}AT_LEAST_ONE2(e){this.atLeastOneInternal(2,e)}AT_LEAST_ONE3(e){this.atLeastOneInternal(3,e)}AT_LEAST_ONE4(e){this.atLeastOneInternal(4,e)}AT_LEAST_ONE5(e){this.atLeastOneInternal(5,e)}AT_LEAST_ONE6(e){this.atLeastOneInternal(6,e)}AT_LEAST_ONE7(e){this.atLeastOneInternal(7,e)}AT_LEAST_ONE8(e){this.atLeastOneInternal(8,e)}AT_LEAST_ONE9(e){this.atLeastOneInternal(9,e)}AT_LEAST_ONE_SEP(e){this.atLeastOneSepFirstInternal(0,e)}AT_LEAST_ONE_SEP1(e){this.atLeastOneSepFirstInternal(1,e)}AT_LEAST_ONE_SEP2(e){this.atLeastOneSepFirstInternal(2,e)}AT_LEAST_ONE_SEP3(e){this.atLeastOneSepFirstInternal(3,e)}AT_LEAST_ONE_SEP4(e){this.atLeastOneSepFirstInternal(4,e)}AT_LEAST_ONE_SEP5(e){this.atLeastOneSepFirstInternal(5,e)}AT_LEAST_ONE_SEP6(e){this.atLeastOneSepFirstInternal(6,e)}AT_LEAST_ONE_SEP7(e){this.atLeastOneSepFirstInternal(7,e)}AT_LEAST_ONE_SEP8(e){this.atLeastOneSepFirstInternal(8,e)}AT_LEAST_ONE_SEP9(e){this.atLeastOneSepFirstInternal(9,e)}RULE(e,t,n=fS){if(u_(this.definedRulesNames,e)){let t={message:ob.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:pS.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(t)}this.definedRulesNames.push(e);let r=this.defineRule(e,t,n);return this[e]=r,r}OVERRIDE_RULE(e,t,n=fS){let r=Ub(e,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);let i=this.defineRule(e,t,n);return this[e]=i,i}BACKTRACK(e,t){return function(){this.isBackTrackingStack.push(1);let n=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(cx(e))return!1;throw e}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return dv(H(this.gastProductionsCache))}},Jx=class{static{o(this,`RecognizerEngine`)}initRecognizerEngine(e,t){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=Ty,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},V(t,`serializedGrammar`))throw Error(`The Parser's configuration can no longer contain a property. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 + For Further details.`);if(I(e)){if(U(e))throw Error(`A Token Vocabulary cannot be empty. + Note that the first argument for the parser constructor + is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset==`number`)throw Error(`The Parser constructor no longer accepts a token vector as the first argument. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 + For Further details.`)}if(I(e))this.tokensMap=L_(e,(e,t)=>(e[t.name]=t,e),{});else if(V(e,`modes`)&&Ng(Ld(H(e.modes)),Ry)){let t=Y_(Ld(H(e.modes)));this.tokensMap=L_(t,(e,t)=>(e[t.name]=t,e),{})}else if(ts(e))this.tokensMap=Sm(e);else throw Error(` argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition`);this.tokensMap.EOF=tb;let n=Ng(V(e,`modes`)?Ld(H(e.modes)):H(e),e=>U(e.categoryMatches));this.tokenMatcher=n?Ty:wy,Oy(H(this.tokensMap))}defineRule(e,t,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${e}> may not be defined after the 'performSelfAnalysis' method has been called' +Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);let r=V(n,`resyncEnabled`)?n.resyncEnabled:fS.resyncEnabled,i=V(n,`recoveryValueFunc`)?n.recoveryValueFunc:fS.recoveryValueFunc,a=this.ruleShortNameIdx<t.call(this)&&e.call(this),`lookAheadFunc`)}}else i=e;if(r.call(this)===!0)return i.call(this)}atLeastOneInternal(e,t){let n=this.getKeyForAutomaticLookahead(Tx,e);return this.atLeastOneInternalLogic(e,t,n)}atLeastOneInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookAheadFunc`)}}else i=t;if(r.call(this)===!0){let e=this.doSingleRepetition(i);for(;r.call(this)===!0&&e===!0;)e=this.doSingleRepetition(i)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY,t.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,t],r,Tx,e,mb)}atLeastOneSepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Dx,e);this.atLeastOneSepFirstInternalLogic(e,t,n)}atLeastOneSepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,hb],t,Dx,e,hb)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY_WITH_SEPARATOR,t.ERR_MSG)}manyInternal(e,t){let n=this.getKeyForAutomaticLookahead(wx,e);return this.manyInternalLogic(e,t,n)}manyInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookaheadFunction`)}}else i=t;let a=!0;for(;r.call(this)===!0&&a===!0;)a=this.doSingleRepetition(i);this.attemptInRepetitionRecovery(this.manyInternal,[e,t],r,wx,e,fb,a)}manySepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Ex,e);this.manySepFirstInternalLogic(e,t,n)}manySepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,pb],t,Ex,e,pb)}}repetitionSepSecondInternal(e,t,n,r,i){for(;n();)this.CONSUME(t),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,t,n,r,i],n,Dx,e,i)}doSingleRepetition(e){let t=this.getLexerPosition();return e.call(this),this.getLexerPosition()>t}orInternal(e,t){let n=this.getKeyForAutomaticLookahead(Sx,t),r=I(e)?e:e.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(i!==void 0)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){let e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new fx(t,e))}}subruleInternal(e,t,n){let r;try{let i=n===void 0?void 0:n.ARGS;return this.subruleIdx=t,r=e.apply(this,i),this.cstPostNonTerminal(r,n!==void 0&&n.LABEL!==void 0?n.LABEL:e.ruleName),r}catch(t){throw this.subruleInternalError(t,n,e.ruleName)}}subruleInternalError(e,t,n){throw cx(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,t!==void 0&&t.LABEL!==void 0?t.LABEL:n),delete e.partialCstResult),e}consumeInternal(e,t,n){let r;try{let t=this.LA(1);this.tokenMatcher(t,e)===!0?(this.consumeToken(),r=t):this.consumeInternalError(e,t,n)}catch(n){r=this.consumeInternalRecovery(e,t,n)}return this.cstPostTerminal(n!==void 0&&n.LABEL!==void 0?n.LABEL:e.name,r),r}consumeInternalError(e,t,n){let r,i=this.LA(0);throw r=n!==void 0&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new ux(r,t,i))}consumeInternalRecovery(e,t,n){if(this.recoveryEnabled&&n.name===`MismatchedTokenException`&&!this.isBackTracking()){let r=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,r)}catch(e){throw e.name===hx?n:e}}throw n}saveRecogState(){let e=this.errors,t=Sm(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK}}reloadRecogState(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK}ruleInvocationStateUpdate(e,t,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t)}isBackTracking(){return this.isBackTrackingStack.length!==0}getCurrRuleFullName(){let e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]}shortRuleNameToFullName(e){return this.shortRuleNameToFull[e]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),tb)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},Yx=class{static{o(this,`ErrorHandler`)}initErrorHandler(e){this._errors=[],this.errorMessageProvider=V(e,`errorMessageProvider`)?e.errorMessageProvider:dS.errorMessageProvider}SAVE_ERROR(e){if(cx(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:Sm(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error(`Trying to save an Error which is not a RecognitionException`)}get errors(){return Sm(this._errors)}set errors(e){this._errors=e}raiseEarlyExitException(e,t,n){let r=this.getCurrRuleFullName(),i=this.getGAstProductions()[r],a=Mb(e,i,t,this.maxLookahead)[0],o=[];for(let e=1;e<=this.maxLookahead;e++)o.push(this.LA(e));let s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new px(s,this.LA(1),this.LA(0)))}raiseNoAltException(e,t){let n=this.getCurrRuleFullName(),r=this.getGAstProductions()[n],i=jb(e,r,this.maxLookahead),a=[];for(let e=1;e<=this.maxLookahead;e++)a.push(this.LA(e));let o=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:o,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new dx(s,this.LA(1),o))}},Xx=class{static{o(this,`ContentAssist`)}initContentAssist(){}computeContentAssist(e,t){let n=this.gastProductionsCache[e];if(w_(n))throw Error(`Rule ->${e}<- does not exist in this grammar.`);return _b([n],t,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(e){let t=Wg(e.ruleStack),n=this.getGAstProductions()[t];return new ub(n,e).startWalking()}},Zx={description:`This Object indicates the Parser is during Recording Phase`};Object.freeze(Zx);var Qx=!0,$x=2**bx-1,eS=$y({name:`RECORDING_PHASE_TOKEN`,pattern:Vy.NA});Oy([eS]);var tS=nb(eS,`This IToken indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(tS);var nS={name:`This CSTNode indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},rS=class{static{o(this,`GastRecorder`)}initGastRecorder(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT(`Enable Recording`,()=>{for(let e=0;e<10;e++){let t=e>0?e:``;this[`CONSUME${t}`]=function(t,n){return this.consumeInternalRecord(t,e,n)},this[`SUBRULE${t}`]=function(t,n){return this.subruleInternalRecord(t,e,n)},this[`OPTION${t}`]=function(t){return this.optionInternalRecord(t,e)},this[`OR${t}`]=function(t){return this.orInternalRecord(t,e)},this[`MANY${t}`]=function(t){this.manyInternalRecord(e,t)},this[`MANY_SEP${t}`]=function(t){this.manySepFirstInternalRecord(e,t)},this[`AT_LEAST_ONE${t}`]=function(t){this.atLeastOneInternalRecord(e,t)},this[`AT_LEAST_ONE_SEP${t}`]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}}this.consume=function(e,t,n){return this.consumeInternalRecord(t,e,n)},this.subrule=function(e,t,n){return this.subruleInternalRecord(t,e,n)},this.option=function(e,t){return this.optionInternalRecord(t,e)},this.or=function(e,t){return this.orInternalRecord(t,e)},this.many=function(e,t){this.manyInternalRecord(e,t)},this.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD})}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT(`Deleting Recording methods`,()=>{let e=this;for(let t=0;t<10;t++){let n=t>0?t:``;delete e[`CONSUME${n}`],delete e[`SUBRULE${n}`],delete e[`OPTION${n}`],delete e[`OR${n}`],delete e[`MANY${n}`],delete e[`MANY_SEP${n}`],delete e[`AT_LEAST_ONE${n}`],delete e[`AT_LEAST_ONE_SEP${n}`]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})}ACTION_RECORD(e){}BACKTRACK_RECORD(e,t){return()=>!0}LA_RECORD(e){return uS}topLevelRuleRecord(e,t){try{let n=new iv({definition:[],name:e});return n.name=e,this.recordingProdStack.push(n),t.call(this),this.recordingProdStack.pop(),n}catch(e){if(e.KNOWN_RECORDER_ERROR!==!0)try{e.message+=` + This error was thrown during the "grammar recording phase" For more info see: + https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch{throw e}throw e}}optionInternalRecord(e,t){return iS.call(this,ov,e,t)}atLeastOneInternalRecord(e,t){iS.call(this,sv,t,e)}atLeastOneSepFirstInternalRecord(e,t){iS.call(this,cv,t,e,Qx)}manyInternalRecord(e,t){iS.call(this,W,t,e)}manySepFirstInternalRecord(e,t){iS.call(this,lv,t,e,Qx)}orInternalRecord(e,t){return aS.call(this,e,t)}subruleInternalRecord(e,t,n){if(sS(t),!e||V(e,`ruleName`)===!1){let n=Error(` argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}> + inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=e.ruleName,a=new rv({idx:t,nonTerminalName:i,label:n?.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?nS:Zx}consumeInternalRecord(e,t,n){if(sS(t),!Py(e)){let n=Error(` argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}> + inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=new G({idx:t,terminalType:e,label:n?.LABEL});return r.definition.push(i),tS}};function iS(e,t,n,r=!1){sS(n);let i=bg(this.recordingProdStack),a=Ss(t)?t:t.DEF,o=new e({definition:[],idx:n});return r&&(o.separator=t.SEP),V(t,`MAX_LOOKAHEAD`)&&(o.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(o),a.call(this),i.definition.push(o),this.recordingProdStack.pop(),Zx}o(iS,`recordProd`);function aS(e,t){sS(t);let n=bg(this.recordingProdStack),r=I(e)===!1,i=r===!1?e:e.DEF,a=new uv({definition:[],idx:t,ignoreAmbiguities:r&&e.IGNORE_AMBIGUITIES===!0});return V(e,`MAX_LOOKAHEAD`)&&(a.maxLookahead=e.MAX_LOOKAHEAD),a.hasPredicates=U_(i,e=>Ss(e.GATE)),n.definition.push(a),z(i,e=>{let t=new av({definition:[]});a.definition.push(t),V(e,`IGNORE_AMBIGUITIES`)?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:V(e,`GATE`)&&(t.ignoreAmbiguities=!0),this.recordingProdStack.push(t),e.ALT.call(this),this.recordingProdStack.pop()}),Zx}o(aS,`recordOrProd`);function oS(e){return e===0?``:`${e}`}o(oS,`getIdxSuffix`);function sS(e){if(e<0||e>$x){let t=Error(`Invalid DSL Method idx value: <${e}> + Idx value must be a none negative value smaller than ${$x+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}o(sS,`assertMethodIdxIsValid`);var cS=class{static{o(this,`PerformanceTracer`)}initPerformanceTracer(e){if(V(e,`traceInitPerf`)){let t=e.traceInitPerf,n=typeof t==`number`;this.traceInitMaxIdent=n?t:1/0,this.traceInitPerf=n?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=dS.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(e,t){if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()}};function lS(e,t){t.forEach(t=>{let n=t.prototype;Object.getOwnPropertyNames(n).forEach(r=>{if(r===`constructor`)return;let i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(e.prototype,r,i):e.prototype[r]=t.prototype[r]})})}o(lS,`applyMixins`);var uS=nb(tb,``,NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(uS);var dS=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:ib,nodeLocationTracking:`none`,traceInitPerf:!1,skipValidations:!1}),fS=Object.freeze({recoveryValueFunc:o(()=>void 0,`recoveryValueFunc`),resyncEnabled:!0}),pS;(function(e){e[e.INVALID_RULE_NAME=0]=`INVALID_RULE_NAME`,e[e.DUPLICATE_RULE_NAME=1]=`DUPLICATE_RULE_NAME`,e[e.INVALID_RULE_OVERRIDE=2]=`INVALID_RULE_OVERRIDE`,e[e.DUPLICATE_PRODUCTIONS=3]=`DUPLICATE_PRODUCTIONS`,e[e.UNRESOLVED_SUBRULE_REF=4]=`UNRESOLVED_SUBRULE_REF`,e[e.LEFT_RECURSION=5]=`LEFT_RECURSION`,e[e.NONE_LAST_EMPTY_ALT=6]=`NONE_LAST_EMPTY_ALT`,e[e.AMBIGUOUS_ALTS=7]=`AMBIGUOUS_ALTS`,e[e.CONFLICT_TOKENS_RULES_NAMESPACE=8]=`CONFLICT_TOKENS_RULES_NAMESPACE`,e[e.INVALID_TOKEN_NAME=9]=`INVALID_TOKEN_NAME`,e[e.NO_NON_EMPTY_LOOKAHEAD=10]=`NO_NON_EMPTY_LOOKAHEAD`,e[e.AMBIGUOUS_PREFIX_ALTS=11]=`AMBIGUOUS_PREFIX_ALTS`,e[e.TOO_MANY_ALTS=12]=`TOO_MANY_ALTS`,e[e.CUSTOM_LOOKAHEAD_VALIDATION=13]=`CUSTOM_LOOKAHEAD_VALIDATION`})(pS||={});function mS(e=void 0){return function(){return e}}o(mS,`EMPTY_ALT`);var hS=class e{static{o(this,`Parser`)}static performSelfAnalysis(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT(`performSelfAnalysis`,()=>{let t;this.selfAnalysisDone=!0;let n=this.className;this.TRACE_INIT(`toFastProps`,()=>{$_(this)}),this.TRACE_INIT(`Grammar Recording`,()=>{try{this.enableRecording(),z(this.definedRulesNames,e=>{let t=this[e].originalGrammarAction,n;this.TRACE_INIT(`${e} Rule`,()=>{n=this.topLevelRuleRecord(e,t)}),this.gastProductionsCache[e]=n})}finally{this.disableRecording()}});let r=[];if(this.TRACE_INIT(`Grammar Resolving`,()=>{r=tx({rules:H(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(r)}),this.TRACE_INIT(`Grammar Validations`,()=>{if(U(r)&&this.skipValidations===!1){let e=nx({rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),errMsgProvider:ob,grammarName:n}),t=Ib({lookaheadStrategy:this.lookaheadStrategy,rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),grammarName:n});this.definitionErrors=this.definitionErrors.concat(e,t)}}),U(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT(`computeAllProdsFollows`,()=>{let e=Ev(H(this.gastProductionsCache));this.resyncFollows=e}),this.TRACE_INIT(`ComputeLookaheadFunctions`,()=>{var e,t;(t=(e=this.lookaheadStrategy).initialize)==null||t.call(e,{rules:H(this.gastProductionsCache)}),this.preComputeLookaheadFunctions(H(this.gastProductionsCache))})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!U(this.definitionErrors))throw t=B(this.definitionErrors,e=>e.message),Error(`Parser Definition Errors detected: + ${t.join(` +------------------------------- +`)}`)})}constructor(e,t){this.definitionErrors=[],this.selfAnalysisDone=!1;let n=this;if(n.initErrorHandler(t),n.initLexerAdapter(),n.initLooksAhead(t),n.initRecognizerEngine(e,t),n.initRecoverable(t),n.initTreeBuilder(t),n.initContentAssist(),n.initGastRecorder(t),n.initPerformanceTracer(t),V(t,`ignoredIssues`))throw Error(`The IParserConfig property has been deprecated. + Please use the flag on the relevant DSL method instead. + See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES + For further details.`);this.skipValidations=V(t,`skipValidations`)?t.skipValidations:dS.skipValidations}};hS.DEFER_DEFINITION_ERRORS_HANDLING=!1,lS(hS,[_x,Ax,Gx,Kx,Jx,qx,Yx,Xx,rS,cS]);var gS=class extends hS{static{o(this,`EmbeddedActionsParser`)}constructor(e,t=dS){let n=Sm(t);n.outputCst=!1,super(e,n)}};function _S(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n-1}o(AS,`listCacheHas`);var jS=AS;function MS(e,t){var n=this.__data__,r=wS(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(MS,`listCacheSet`);var NS=MS;function PS(e){var t=-1,n=e==null?0:e.length;for(this.clear();++ts))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Nw?new Dw:void 0;for(a.set(e,t),a.set(t,e);++d-1&&e%1==0&&e-1&&e%1==0&&e<=LT}o(RT,`isLength`);var zT=RT,BT=`[object Arguments]`,VT=`[object Array]`,HT=`[object Boolean]`,UT=`[object Date]`,WT=`[object Error]`,GT=`[object Function]`,KT=`[object Map]`,qT=`[object Number]`,JT=`[object Object]`,YT=`[object RegExp]`,XT=`[object Set]`,ZT=`[object String]`,QT=`[object WeakMap]`,$T=`[object ArrayBuffer]`,eE=`[object DataView]`,tE=`[object Float32Array]`,nE=`[object Float64Array]`,rE=`[object Int8Array]`,iE=`[object Int16Array]`,aE=`[object Int32Array]`,oE=`[object Uint8Array]`,sE=`[object Uint8ClampedArray]`,cE=`[object Uint16Array]`,lE=`[object Uint32Array]`,J={};J[tE]=J[nE]=J[rE]=J[iE]=J[aE]=J[oE]=J[sE]=J[cE]=J[lE]=!0,J[BT]=J[VT]=J[$T]=J[HT]=J[eE]=J[UT]=J[WT]=J[GT]=J[KT]=J[qT]=J[JT]=J[YT]=J[XT]=J[ZT]=J[QT]=!1;function uE(e){return yT(e)&&zT(e.length)&&!!J[sC(e)]}o(uE,`baseIsTypedArray`);var dE=uE;function fE(e){return function(t){return e(t)}}o(fE,`baseUnary`);var pE=fE,mE=typeof exports==`object`&&exports&&!exports.nodeType&&exports,hE=mE&&typeof module==`object`&&module&&!module.nodeType&&module,gE=hE&&hE.exports===mE&&WS.process,_E=(function(){try{return hE&&hE.require&&hE.require(`util`).types||gE&&gE.binding&&gE.binding(`util`)}catch{}})(),vE=_E&&_E.isTypedArray,yE=vE?pE(vE):dE,bE=Object.prototype.hasOwnProperty;function xE(e,t){var n=oT(e),r=!n&&ET(e),i=!n&&!r&&MT(e),a=!n&&!r&&!i&&yE(e),o=n||r||i||a,s=o?_T(e.length,String):[],c=s.length;for(var l in e)(t||bE.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||IT(l,c)))&&s.push(l);return s}o(xE,`arrayLikeKeys`);var SE=xE,CE=Object.prototype;function wE(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||CE)}o(wE,`isPrototype`);var TE=wE;function EE(e,t){return function(n){return e(t(n))}}o(EE,`overArg`);var DE=EE(Object.keys,Object),OE=Object.prototype.hasOwnProperty;function kE(e){if(!TE(e))return DE(e);var t=[];for(var n in Object(e))OE.call(e,n)&&n!=`constructor`&&t.push(n);return t}o(kE,`baseKeys`);var AE=kE;function jE(e){return e!=null&&zT(e.length)&&!hC(e)}o(jE,`isArrayLike`);var ME=jE;function NE(e){return ME(e)?SE(e):AE(e)}o(NE,`keys`);var PE=NE;function FE(e){return cT(e,PE,hT)}o(FE,`getAllKeys`);var IE=FE,LE=1,RE=Object.prototype.hasOwnProperty;function zE(e,t,n,r,i,a){var o=n&LE,s=IE(e),c=s.length;if(c!=IE(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:RE.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++lek(e,t,n)))}o(ak,`alternation`);function ok(e,t,n){let r=X(e,t,n,{type:RO});return dk(e,r),uk(e,t,n,fk(e,t,r,n,sk(e,t,n)))}o(ok,`option`);function sk(e,t,n){let r=IO(MO(n.definition,n=>ek(e,t,n)),e=>e!==void 0);return r.length===1?r[0]:r.length===0?void 0:mk(e,r)}o(sk,`block`);function ck(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:KO});dk(e,s);let c=X(e,t,n,{type:qO});return a.loopback=s,c.loopback=s,e.decisionMap[LO(t,i?`RepetitionMandatoryWithSeparator`:`RepetitionMandatory`,n.idx)]=s,Y(o,s),i===void 0?(Y(s,a),Y(s,c)):(Y(s,c),Y(s,i.left),Y(i.right,a)),{left:a,right:c}}o(ck,`plus`);function lk(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:GO});dk(e,s);let c=X(e,t,n,{type:qO}),l=X(e,t,n,{type:WO});return s.loopback=l,c.loopback=l,Y(s,a),Y(s,c),Y(o,l),i===void 0?Y(l,s):(Y(l,c),Y(l,i.left),Y(i.right,a)),e.decisionMap[LO(t,i?`RepetitionWithSeparator`:`Repetition`,n.idx)]=s,{left:s,right:c}}o(lk,`star`);function uk(e,t,n,r){let i=r.left,a=r.right;return Y(i,a),e.decisionMap[LO(t,`Option`,n.idx)]=i,r}o(uk,`optional`);function dk(e,t){return e.decisionStates.push(t),t.decision=e.decisionStates.length-1,t.decision}o(dk,`defineDecisionState`);function fk(e,t,n,r,...i){let a=X(e,t,r,{type:UO,start:n});n.end=a;for(let e of i)e===void 0?Y(n,a):(Y(n,e.left),Y(e.right,a));let o={left:n,right:a};return e.decisionMap[LO(t,pk(r),r.idx)]=n,o}o(fk,`makeAlts`);function pk(e){if(e instanceof uv)return`Alternation`;if(e instanceof ov)return`Option`;if(e instanceof W)return`Repetition`;if(e instanceof lv)return`RepetitionWithSeparator`;if(e instanceof sv)return`RepetitionMandatory`;if(e instanceof cv)return`RepetitionMandatoryWithSeparator`;throw Error(`Invalid production type encountered`)}o(pk,`getProdType`);function mk(e,t){let n=t.length;for(let r=0;re.alt)}get key(){let e=``;for(let t in this.map)e+=t+`:`;return e}};function Sk(e,t=!0){return`${t?`a${e.alt}`:``}s${e.state.stateNumber}:${e.stack.map(e=>e.stateNumber.toString()).join(`_`)}`}o(Sk,`getATNConfigKey`);function Ck(e,t,n){for(var r=-1,i=e.length;++r0&&n(s)?t>1?Mk(s,t-1,n,r,i):aT(i,s):r||(i[i.length]=s)}return i}o(Mk,`baseFlatten`);var Nk=Mk;function Pk(e,t){return Nk(MO(e,t),1)}o(Pk,`flatMap`);var Fk=Pk;function Ik(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a-1}o(Wk,`arrayIncludes`);var Gk=Wk;function Kk(e,t,n){for(var r=-1,i=e==null?0:e.length;++r=Zk){var l=t?null:Xk(e);if(l)return Bw(l);o=!1,i=jw,c=new Dw}else c=t?[]:s;outer:for(;++r{let i=r.toString(),a=n[i];return a===void 0?(a={atnStartState:e,decision:t,states:{}},n[i]=a,a):a}}o(xA,`createDFACache`);var SA=class{static{o(this,`PredicateSet`)}constructor(){this.predicates=[]}is(e){return e>=this.predicates.length||this.predicates[e]}set(e,t){this.predicates[e]=t}toString(){let e=``,t=this.predicates.length;for(let n=0;nconsole.log(e))}initialize(e){this.atn=QO(e.rules),this.dfas=EA(this.atn)}validateAmbiguousAlternationAlternatives(){return[]}validateEmptyOrAlternatives(){return[]}buildLookaheadForAlternation(e){let{prodOccurrence:t,rule:n,hasPredicates:r,dynamicTokensEnabled:i}=e,a=this.dfas,o=this.logging,s=LO(n,`Alternation`,t),c=this.atn.decisionMap[s].decision,l=MO(bb({maxLookahead:1,occurrence:t,prodType:`Alternation`,rule:n}),e=>MO(e,e=>e[0]));if(TA(l,!1)&&!i){let e=bA(l,(e,t,n)=>(lA(t,t=>{t&&(e[t.tokenTypeIdx]=n,lA(t.categoryMatches,t=>{e[t]=n}))}),e),{});return r?function(t){let n=this.LA(1),r=e[n.tokenTypeIdx];if(t!==void 0&&r!==void 0){let e=t[r]?.GATE;if(e!==void 0&&e.call(this)===!1)return}return r}:function(){let t=this.LA(1);return e[t.tokenTypeIdx]}}return r?function(e){let t=new SA,n=e===void 0?0:e.length;for(let r=0;rMO(e,e=>e[0]));if(TA(l)&&l[0][0]&&!i){let e=l[0],t=rA(e);if(t.length===1&&mA(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=bA(t,(e,t)=>(t!==void 0&&(e[t.tokenTypeIdx]=!0,lA(t.categoryMatches,t=>{e[t]=!0})),e),{});return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){let e=DA.call(this,a,c,CA,o);return typeof e!=`object`&&e===0}}};function TA(e,t=!0){let n=new Set;for(let r of e){let e=new Set;for(let i of r){if(i===void 0){if(t)break;return!1}let r=[i.tokenTypeIdx].concat(i.categoryMatches);for(let t of r)if(n.has(t)){if(!e.has(t))return!1}else n.add(t),e.add(t)}}return!0}o(TA,`isLL1Sequence`);function EA(e){let t=e.decisionStates.length,n=Array(t);for(let r=0;rHy(e)).join(`, `),n=e.production.idx===0?``:e.production.idx,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(`, `)}> in <${MA(e.production)}${n}> inside <${e.topLevelRule.name}> Rule, +<${t}> may appears as a prefix path in all these alternatives. +`;return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r}o(jA,`buildAmbiguityError`);function MA(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(MA,`getProductionDslName`);function NA(e,t,n){return{actualToken:n,possibleTokenTypes:tA(Fk(t.configs.elements,e=>e.state.transitions).filter(e=>e instanceof YO).map(e=>e.tokenType),e=>e.tokenTypeIdx),tokenPath:e}}o(NA,`buildAdaptivePredictError`);function PA(e,t){return e.edges[t.tokenTypeIdx]}o(PA,`getExistingTargetState`);function FA(e,t,n){let r=new xk,i=[];for(let a of e.elements){if(n.is(a.alt)===!1)continue;if(a.state.type===HO){i.push(a);continue}let e=a.state.transitions.length;for(let n=0;n0&&!WA(a))for(let e of i)a.add(e);return a}o(FA,`computeReachSet`);function IA(e,t){if(e instanceof YO&&rb(t,e.tokenType))return e.target}o(IA,`getReachableTarget`);function LA(e,t){let n;for(let r of e.elements)if(t.is(r.alt)===!0){if(n===void 0)n=r.alt;else if(n!==r.alt)return}return n}o(LA,`getUniqueAlt`);function RA(e){return{configs:e,edges:{},isAcceptState:!1,prediction:-1}}o(RA,`newDFAState`);function zA(e,t,n,r){return r=BA(e,r),t.edges[n.tokenTypeIdx]=r,r}o(zA,`addDFAEdge`);function BA(e,t){if(t===bk)return t;let n=t.configs.key,r=e.states[n];return r===void 0?(t.configs.finalize(),e.states[n]=t,t):r}o(BA,`addDFAState`);function VA(e){let t=new xk,n=e.transitions.length;for(let r=0;r0){let n=[...e.stack];HA({state:n.pop(),alt:e.alt,stack:n},t)}else t.add(e);return}n.epsilonOnlyTransitions||t.add(e);let r=n.transitions.length;for(let i=0;i1)return!0;return!1}o(JA,`hasConflictingAltSet`);function YA(e){for(let t of Array.from(e.values()))if(Object.keys(t).length===1)return!0;return!1}o(YA,`hasStateAssociatedWithOneAlt`),ht();var XA=class{static{o(this,`CstNodeBuilder`)}constructor(){this.nodeStack=[]}get current(){return this.nodeStack[this.nodeStack.length-1]??this.rootNode}buildRootNode(e){return this.rootNode=new tj(e),this.rootNode.root=this.rootNode,this.nodeStack=[this.rootNode],this.rootNode}buildCompositeNode(e){let t=new $A;return t.grammarSource=e,t.root=this.rootNode,this.current.content.push(t),this.nodeStack.push(t),t}buildLeafNode(e,t){let n=new QA(e.startOffset,e.image.length,zi(e),e.tokenType,!t);return n.grammarSource=t,n.root=this.rootNode,this.current.content.push(n),n}removeNode(e){let t=e.container;if(t){let n=t.content.indexOf(e);n>=0&&t.content.splice(n,1)}}addHiddenNodes(e){let t=[];for(let n of e){let e=new QA(n.startOffset,n.image.length,zi(n),n.tokenType,!0);e.root=this.rootNode,t.push(e)}let n=this.current,r=!1;if(n.content.length>0){n.content.push(...t);return}for(;n.container;){let e=n.container.content.indexOf(n);if(e>0){n.container.content.splice(e,0,...t),r=!0;break}n=n.container}r||this.rootNode.content.unshift(...t)}construct(e){let t=this.current;typeof e.$type==`string`&&!e.$infixName&&(this.current.astNode=e),e.$cstNode=t;let n=this.nodeStack.pop();n?.content.length===0&&this.removeNode(n)}},ZA=class{static{o(this,`AbstractCstNode`)}get hidden(){return!1}get astNode(){let e=typeof this._astNode?.$type==`string`?this._astNode:this.container?.astNode;if(!e)throw Error(`This node has no associated AST element`);return e}set astNode(e){this._astNode=e}get text(){return this.root.fullText.substring(this.offset,this.end)}},QA=class extends ZA{static{o(this,`LeafCstNodeImpl`)}get offset(){return this._offset}get length(){return this._length}get end(){return this._offset+this._length}get hidden(){return this._hidden}get tokenType(){return this._tokenType}get range(){return this._range}constructor(e,t,n,r,i=!1){super(),this._hidden=i,this._offset=e,this._tokenType=r,this._length=t,this._range=n}},$A=class extends ZA{static{o(this,`CompositeCstNodeImpl`)}constructor(){super(...arguments),this.content=new ej(this)}get offset(){return this.firstNonHiddenNode?.offset??0}get length(){return this.end-this.offset}get end(){return this.lastNonHiddenNode?.end??0}get range(){let e=this.firstNonHiddenNode,t=this.lastNonHiddenNode;if(e&&t){if(this._rangeCache===void 0){let{range:n}=e,{range:r}=t;this._rangeCache={start:n.start,end:r.end.line=0;e--){let t=this.content[e];if(!t.hidden)return t}return this.content[this.content.length-1]}},ej=class e extends Array{static{o(this,`CstNodeContainer`)}constructor(t){super(),this.parent=t,Object.setPrototypeOf(this,e.prototype)}push(...e){return this.addParents(e),super.push(...e)}unshift(...e){return this.addParents(e),super.unshift(...e)}splice(e,t,...n){return this.addParents(n),super.splice(e,t,...n)}addParents(e){for(let t of e)t.container=this.parent}},tj=class extends $A{static{o(this,`RootCstNodeImpl`)}get text(){return this._text.substring(this.offset,this.end)}get fullText(){return this._text}constructor(e){super(),this._text=``,this._text=e??``}},nj=Symbol(`Datatype`);function rj(e){return e.$type===nj}o(rj,`isDataTypeNode`);var ij=`​`,aj=o(e=>e.endsWith(ij)?e:e+ij,`withRuleSuffix`),oj=class{static{o(this,`AbstractLangiumParser`)}constructor(e){this._unorderedGroups=new Map,this.allRules=new Map,this.lexer=e.parser.Lexer;let t=this.lexer.definition,n=e.LanguageMetaData.mode===`production`;this.wrapper=e.shared.profilers.LangiumProfiler?.isActive(`parsing`)?new pj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider},e.shared.profilers.LangiumProfiler.createTask(`parsing`,e.LanguageMetaData.languageId)):new fj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider})}alternatives(e,t){this.wrapper.wrapOr(e,t)}optional(e,t){this.wrapper.wrapOption(e,t)}many(e,t){this.wrapper.wrapMany(e,t)}atLeastOne(e,t){this.wrapper.wrapAtLeastOne(e,t)}getRule(e){return this.allRules.get(e)}isRecording(){return this.wrapper.IS_RECORDING}get unorderedGroups(){return this._unorderedGroups}getRuleStack(){return this.wrapper.RULE_STACK}finalize(){this.wrapper.wrapSelfAnalysis()}},sj=class extends oj{static{o(this,`LangiumParser`)}get current(){return this.stack[this.stack.length-1]}constructor(e){super(e),this.nodeBuilder=new XA,this.stack=[],this.assignmentMap=new Map,this.operatorPrecedence=new Map,this.linker=e.references.Linker,this.converter=e.parser.ValueConverter,this.astReflection=e.shared.AstReflection}rule(e,t){let n=this.computeRuleType(e),r;Dr(e)&&(r=e.name,this.registerPrecedenceMap(e));let i=this.wrapper.DEFINE_RULE(aj(e.name),this.startImplementation(n,r,t).bind(this));return this.allRules.set(e.name,i),Yr(e)&&e.entry&&(this.mainRule=i),i}registerPrecedenceMap(e){let t=e.name,n=new Map;for(let t=0;t0&&(t=this.construct()),t===void 0)throw Error(`No result from parser`);if(this.stack.length>0)throw Error(`Parser stack is not empty after parsing`);return t}startImplementation(e,t,n){return r=>{let i=!this.isRecording()&&e!==void 0;if(i){let n={$type:e};this.stack.push(n),e===nj?n.value=``:t!==void 0&&(n.$infixName=t)}return n(r),i?this.construct():void 0}}extractHiddenTokens(e){let t=this.lexerResult.hidden;if(!t.length)return[];let n=e.startOffset;for(let e=0;en)return t.splice(0,e);return t.splice(0,t.length)}consume(e,t,n){let r=this.wrapper.wrapConsume(e,t);if(!this.isRecording()&&this.isValidToken(r)){let e=this.extractHiddenTokens(r);this.nodeBuilder.addHiddenNodes(e);let t=this.nodeBuilder.buildLeafNode(r,n),{assignment:i,crossRef:a}=this.getAssignment(n),o=this.current;if(i){let e=Fr(n)?r.image:this.converter.convert(r.image,t);this.assign(i.operator,i.feature,e,t,a)}else if(rj(o)){let e=r.image;Fr(n)||(e=this.converter.convert(e,t).toString()),o.value+=e}}}isValidToken(e){return!e.isInsertedInRecovery&&!isNaN(e.startOffset)&&typeof e.endOffset==`number`&&!isNaN(e.endOffset)}subrule(e,t,n,r,i){let a;!this.isRecording()&&!n&&(a=this.nodeBuilder.buildCompositeNode(r));let o;try{o=this.wrapper.wrapSubrule(e,t,i)}finally{this.isRecording()||(o===void 0&&!n&&(o=this.construct()),o!==void 0&&a&&a.length>0&&this.performSubruleAssignment(o,r,a))}}performSubruleAssignment(e,t,n){let{assignment:r,crossRef:i}=this.getAssignment(t);if(r)this.assign(r.operator,r.feature,e,n,i);else if(!r){let t=this.current;if(rj(t))t.value+=e.toString();else if(typeof e==`object`&&e){let n=this.assignWithoutOverride(e,t);this.stack.pop(),this.stack.push(n)}}}action(e,t){if(!this.isRecording()){let n=this.current;if(t.feature&&t.operator){n=this.construct(),this.nodeBuilder.removeNode(n.$cstNode),this.nodeBuilder.buildCompositeNode(t).content.push(n.$cstNode);let r={$type:e};this.stack.push(r),this.assign(t.operator,t.feature,n,n.$cstNode)}else n.$type=e}}construct(){if(this.isRecording())return;let e=this.stack.pop();return this.nodeBuilder.construct(e),`$infixName`in e?this.constructInfix(e,this.operatorPrecedence.get(e.$infixName)):rj(e)?this.converter.convert(e.value,e.$cstNode):(Fn(this.astReflection,e),e)}constructInfix(e,t){let n=e.parts;if(!Array.isArray(n)||n.length===0)return;let r=e.operators;if(!Array.isArray(r)||n.length<2)return n[0];let i=0,a=-1;for(let e=0;ea?(a=o.precedence,i=e):o.precedence===a&&(o.rightAssoc||(i=e))}let o=r.slice(0,i),s=r.slice(i+1),c=n.slice(0,i+1),l=n.slice(i+1),u={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:c,operators:o},d={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:l,operators:s},f=this.constructInfix(u,t),p=this.constructInfix(d,t);return{$type:e.$type,$cstNode:e.$cstNode,left:f,operator:r[i],right:p}}getAssignment(e){if(!this.assignmentMap.has(e)){let t=Tn(e,rr);this.assignmentMap.set(e,{assignment:t,crossRef:t&&pr(t.terminal)?t.terminal.isMulti?`multi`:`single`:void 0})}return this.assignmentMap.get(e)}assign(e,t,n,r,i){let a=this.current,o;switch(o=i===`single`&&typeof n==`string`?this.linker.buildReference(a,t,r,n):i===`multi`&&typeof n==`string`?this.linker.buildMultiReference(a,t,r,n):n,e){case`=`:a[t]=o;break;case`?=`:a[t]=!0;break;case`+=`:Array.isArray(a[t])||(a[t]=[]),a[t].push(o)}}assignWithoutOverride(e,t){for(let[n,r]of Object.entries(t)){let t=e[n];t===void 0?e[n]=r:Array.isArray(t)&&Array.isArray(r)&&(r.push(...t),e[n]=r)}let n=e.$cstNode;return n&&(n.astNode=void 0,e.$cstNode=void 0),e}get definitionErrors(){return this.wrapper.definitionErrors}},cj=class{static{o(this,`AbstractParserErrorMessageProvider`)}buildMismatchTokenMessage(e){return ib.buildMismatchTokenMessage(e)}buildNotAllInputParsedMessage(e){return ib.buildNotAllInputParsedMessage(e)}buildNoViableAltMessage(e){return ib.buildNoViableAltMessage(e)}buildEarlyExitMessage(e){return ib.buildEarlyExitMessage(e)}},lj=class extends cj{static{o(this,`LangiumParserErrorMessageProvider`)}buildMismatchTokenMessage({expected:e,actual:t}){return`Expecting ${e.LABEL?"`"+e.LABEL+"`":e.name.endsWith(`:KW`)?`keyword '${e.name.substring(0,e.name.length-3)}'`:`token of type '${e.name}'`} but found \`${t.image}\`.`}buildNotAllInputParsedMessage({firstRedundant:e}){return`Expecting end of file but found \`${e.image}\`.`}},uj=class extends oj{static{o(this,`LangiumCompletionParser`)}constructor(){super(...arguments),this.tokens=[],this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}action(){}construct(){}parse(e){this.resetState();let t=this.lexer.tokenize(e,{mode:`partial`});return this.tokens=t.tokens,this.wrapper.input=[...this.tokens],this.mainRule.call(this.wrapper,{}),this.unorderedGroups.clear(),{tokens:this.tokens,elementStack:[...this.lastElementStack],tokenIndex:this.nextTokenIndex}}rule(e,t){let n=this.wrapper.DEFINE_RULE(aj(e.name),this.startImplementation(t).bind(this));return this.allRules.set(e.name,n),e.entry&&(this.mainRule=n),n}resetState(){this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}startImplementation(e){return t=>{let n=this.keepStackSize();try{e(t)}finally{this.resetStackSize(n)}}}removeUnexpectedElements(){this.elementStack.splice(this.stackSize)}keepStackSize(){let e=this.elementStack.length;return this.stackSize=e,e}resetStackSize(e){this.removeUnexpectedElements(),this.stackSize=e}consume(e,t,n){this.wrapper.wrapConsume(e,t),this.isRecording()||(this.lastElementStack=[...this.elementStack,n],this.nextTokenIndex=this.currIdx+1)}subrule(e,t,n,r,i){this.before(r),this.wrapper.wrapSubrule(e,t,i),this.after(r)}before(e){this.isRecording()||this.elementStack.push(e)}after(e){if(!this.isRecording()){let t=this.elementStack.lastIndexOf(e);t>=0&&this.elementStack.splice(t)}}get currIdx(){return this.wrapper.currIdx}},dj={recoveryEnabled:!0,nodeLocationTracking:`full`,skipValidations:!0,errorMessageProvider:new lj},fj=class extends gS{static{o(this,`ChevrotainWrapper`)}constructor(e,t){let n=t&&`maxLookahead`in t;super(e,{...dj,lookaheadStrategy:n?new kx({maxLookahead:t.maxLookahead}):new wA({logging:t.skipValidations?()=>{}:void 0}),...t})}get IS_RECORDING(){return this.RECORDING_PHASE}DEFINE_RULE(e,t,n){return this.RULE(e,t,n)}wrapSelfAnalysis(){this.performSelfAnalysis()}wrapConsume(e,t){return this.consume(e,t,void 0)}wrapSubrule(e,t,n){return this.subrule(e,t,{ARGS:[n]})}wrapOr(e,t){this.or(e,t)}wrapOption(e,t){this.option(e,t)}wrapMany(e,t){this.many(e,t)}wrapAtLeastOne(e,t){this.atLeastOne(e,t)}rule(e){return e.call(this,{})}},pj=class extends fj{static{o(this,`ProfilerWrapper`)}constructor(e,t,n){super(e,t),this.task=n}rule(e){this.task.start(),this.task.startSubTask(this.ruleName(e));try{return super.rule(e)}finally{this.task.stopSubTask(this.ruleName(e)),this.task.stop()}}ruleName(e){return e.ruleName}subrule(e,t,n){this.task.startSubTask(this.ruleName(t));try{return super.subrule(e,t,n)}finally{this.task.stopSubTask(this.ruleName(t))}}};function mj(e,t,n){return hj({parser:t,tokens:n,ruleNames:new Map},e),t}o(mj,`createParser`);function hj(e,t){let n=Na(t,!1),r=N(t.rules).filter(Yr).filter(e=>n.has(e));for(let t of r){let n={...e,consume:1,optional:1,subrule:1,many:1,or:1};e.parser.rule(t,_j(n,t.definition))}let i=N(t.rules).filter(Dr).filter(e=>n.has(e));for(let t of i)e.parser.rule(t,gj(e,t))}o(hj,`buildRules`);function gj(e,t){let n=t.call.rule.ref;if(!n)throw Error(`Could not resolve reference to infix operator rule: `+t.call.rule.$refText);if(hi(n))throw Error(`Cannot use terminal rule in infix expression`);let r=t.operators.precedences.flatMap(e=>e.operators),i={$type:`Group`,elements:[]},a={$container:i,$type:`Assignment`,feature:`parts`,operator:`+=`,terminal:t.call},s={$container:i,$type:`Group`,elements:[],cardinality:`*`};i.elements.push(a,s);let c={$container:s,$type:`Assignment`,feature:`operators`,operator:`+=`,terminal:{$type:`Alternatives`,elements:r}},l={...a,$container:s};s.elements.push(c,l);let u=r.map(t=>e.tokens[t.value]).map((t,n)=>({ALT:o(()=>e.parser.consume(n,t,c),`ALT`)})),d;return t=>{d??=kj(e,n),e.parser.subrule(0,d,!1,a,t),e.parser.many(0,{DEF:o(()=>{e.parser.alternatives(0,u),e.parser.subrule(1,d,!1,l,t)},`DEF`)})}}o(gj,`buildInfixRule`);function _j(e,t,n=!1){let r;if(Fr(t))r=Dj(e,t);else if(Yn(t))r=vj(e,t);else if(rr(t))r=_j(e,t.terminal);else if(pr(t))r=Ej(e,t);else if(ri(t))r=yj(e,t);else if(Zn(t))r=Sj(e,t);else if(Di(t))r=Cj(e,t);else if(Cr(t))r=wj(e,t);else if(_r(t)){let n=e.consume++;r=o(()=>e.parser.consume(n,tb,t),`method`)}else throw new ia(t.$cstNode,`Unexpected element type: ${t.$type}`);return Oj(e,n?void 0:Tj(t),r,t.cardinality)}o(_j,`buildElement`);function vj(e,t){let n=no(t);return()=>e.parser.action(n,t)}o(vj,`buildAction`);function yj(e,t){let n=t.rule.ref;if(Un(n)){let r=e.subrule++,i=Yr(n)&&n.fragment,a=t.arguments.length>0?bj(n,t.arguments):()=>({}),o;return s=>{o??=kj(e,n),e.parser.subrule(r,o,i,t,a(s))}}if(hi(n)){let r=e.consume++,i=jj(e,n.name);return()=>e.parser.consume(r,i,t)}if(n)aa(n);else throw new ia(t.$cstNode,`Undefined rule: ${t.rule.$refText}`)}o(yj,`buildRuleCall`);function bj(e,t){if(t.some(e=>e.calledByName)){let e=t.map(e=>({parameterName:e.parameter?.ref?.name,predicate:xj(e.value)}));return t=>{let n={};for(let{parameterName:r,predicate:i}of e)r&&(n[r]=i(t));return n}}{let n=t.map(e=>xj(e.value));return t=>{let r={};for(let i=0;it(e)||n(e)}if(dr(e)){let t=xj(e.left),n=xj(e.right);return e=>t(e)&&n(e)}if(Vr(e)){let t=xj(e.value);return e=>!t(e)}if(qr(e)){let t=e.parameter.ref.name;return e=>e!==void 0&&e[t]===!0}if(ar(e)){let t=!!e.true;return()=>t}aa(e)}o(xj,`buildPredicate`);function Sj(e,t){if(t.elements.length===1)return _j(e,t.elements[0]);{let n=[];for(let r of t.elements){let t={ALT:_j(e,r,!0)},i=Tj(r);i&&(t.GATE=xj(i)),n.push(t)}let r=e.or++;return t=>e.parser.alternatives(r,n.map(e=>{let n={ALT:o(()=>e.ALT(t),`ALT`)},r=e.GATE;return r&&(n.GATE=()=>r(t)),n}))}}o(Sj,`buildAlternatives`);function Cj(e,t){if(t.elements.length===1)return _j(e,t.elements[0]);let n=[];for(let r of t.elements){let t={ALT:_j(e,r,!0)},i=Tj(r);i&&(t.GATE=xj(i)),n.push(t)}let r=e.or++,i=o((e,t)=>`uGroup_${e}_${t.getRuleStack().join(`-`)}`,`idFunc`),a=o(t=>e.parser.alternatives(r,n.map((n,a)=>{let s={ALT:o(()=>!0,`ALT`)},c=e.parser;s.ALT=()=>{if(n.ALT(t),!c.isRecording()){let e=i(r,c);c.unorderedGroups.get(e)||c.unorderedGroups.set(e,[]);let t=c.unorderedGroups.get(e);t?.[a]===void 0&&(t[a]=!0)}};let l=n.GATE;return s.GATE=l?()=>l(t):()=>!c.unorderedGroups.get(i(r,c))?.[a],s})),`alternatives`),s=Oj(e,Tj(t),a,`*`);return t=>{s(t),e.parser.isRecording()||e.parser.unorderedGroups.delete(i(r,e.parser))}}o(Cj,`buildUnorderedGroup`);function wj(e,t){let n=t.elements.map(t=>_j(e,t));return e=>n.forEach(t=>t(e))}o(wj,`buildGroup`);function Tj(e){if(Cr(e))return e.guardCondition}o(Tj,`getGuardCondition`);function Ej(e,t,n=t.terminal){if(!n){if(!t.type.ref)throw Error(`Could not resolve reference to type: `+t.type.$refText);let n=Ga(t.type.ref)?.terminal;if(!n)throw Error(`Could not find name assignment for type: `+no(t.type.ref));return Ej(e,t,n)}if(ri(n)&&Yr(n.rule.ref)){let r=n.rule.ref,i=e.subrule++,a;return n=>{a??=kj(e,r),e.parser.subrule(i,a,!1,t,n)}}if(ri(n)&&hi(n.rule.ref)){let r=e.consume++,i=jj(e,n.rule.ref.name);return()=>e.parser.consume(r,i,t)}if(Fr(n)){let r=e.consume++,i=jj(e,n.value);return()=>e.parser.consume(r,i,t)}throw Error(`Could not build cross reference parser`)}o(Ej,`buildCrossReference`);function Dj(e,t){let n=e.consume++,r=e.tokens[t.value];if(!r)throw Error(`Could not find token for keyword: `+t.value);return()=>e.parser.consume(n,r,t)}o(Dj,`buildKeyword`);function Oj(e,t,n,r){let i=t&&xj(t);if(!r){if(i){let t=e.or++;return r=>e.parser.alternatives(t,[{ALT:o(()=>n(r),`ALT`),GATE:o(()=>i(r),`GATE`)},{ALT:mS(),GATE:o(()=>!i(r),`GATE`)}])}return n}if(r===`*`){let t=e.many++;return r=>e.parser.many(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}if(r===`+`){let t=e.many++;if(i){let r=e.or++;return a=>e.parser.alternatives(r,[{ALT:o(()=>e.parser.atLeastOne(t,{DEF:o(()=>n(a),`DEF`)}),`ALT`),GATE:o(()=>i(a),`GATE`)},{ALT:mS(),GATE:o(()=>!i(a),`GATE`)}])}return r=>e.parser.atLeastOne(t,{DEF:o(()=>n(r),`DEF`)})}if(r===`?`){let t=e.optional++;return r=>e.parser.optional(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}aa(r)}o(Oj,`wrap`);function kj(e,t){let n=Aj(e,t),r=e.parser.getRule(n);if(!r)throw Error(`Rule "${n}" not found."`);return r}o(kj,`getRule`);function Aj(e,t){if(Un(t))return t.name;if(e.ruleNames.has(t))return e.ruleNames.get(t);{let n=t,r=n.$container,i=t.$type;for(;!Yr(r);)(Cr(r)||Zn(r)||Di(r))&&(i=r.elements.indexOf(n).toString()+`:`+i),n=r,r=r.$container;return i=r.name+`:`+i,e.ruleNames.set(t,i),i}}o(Aj,`getRuleName`);function jj(e,t){let n=e.tokens[t];if(!n)throw Error(`Token "${t}" not found."`);return n}o(jj,`getToken`);function Mj(e){let t=e.Grammar,n=e.parser.Lexer,r=new uj(e);return mj(t,r,n.definition),r.finalize(),r}o(Mj,`createCompletionParser`);function Nj(e){let t=Pj(e);return t.finalize(),t}o(Nj,`createLangiumParser`);function Pj(e){let t=e.Grammar,n=e.parser.Lexer;return mj(t,new sj(e),n.definition)}o(Pj,`prepareLangiumParser`);var Fj=class{static{o(this,`DefaultTokenBuilder`)}constructor(){this.diagnostics=[]}buildTokens(e,t){let n=N(Na(e,!1)),r=this.buildTerminalTokens(n),i=this.buildKeywordTokens(n,r,t);return i.push(...r),i}flushLexingReport(e){return{diagnostics:this.popDiagnostics()}}popDiagnostics(){let e=[...this.diagnostics];return this.diagnostics=[],e}buildTerminalTokens(e){return e.filter(hi).filter(e=>!e.fragment).map(e=>this.buildTerminalToken(e)).toArray()}buildTerminalToken(e){let t=oo(e),n=this.requiresCustomPattern(t)?this.regexPatternFunction(t):t,r={name:e.name,PATTERN:n};return typeof n==`function`&&(r.LINE_BREAKS=!0),e.hidden&&(r.GROUP=Da(t)?Vy.SKIPPED:`hidden`),r}requiresCustomPattern(e){return!!(e.flags.includes(`u`)||e.flags.includes(`s`))}regexPatternFunction(e){let t=new RegExp(e,e.flags+`y`);return(e,n)=>(t.lastIndex=n,t.exec(e))}buildKeywordTokens(e,t,n){return e.filter(Un).flatMap(e=>jn(e).filter(Fr)).distinct(e=>e.value).toArray().sort((e,t)=>t.value.length-e.value.length).map(e=>this.buildKeywordToken(e,t,!!n?.caseInsensitive))}buildKeywordToken(e,t,n){let r=this.buildKeywordPattern(e,n),i={name:e.value,PATTERN:r,LONGER_ALT:this.findLongerAlt(e,t)};return typeof r==`function`&&(i.LINE_BREAKS=!0),i}buildKeywordPattern(e,t){return t?new RegExp(Oa(e.value),`i`):e.value}findLongerAlt(e,t){return t.reduce((t,n)=>{let r=n?.PATTERN;return r?.source&&ka(`^`+r.source+`$`,e.value)&&t.push(n),t},[])}},Ij=class{static{o(this,`DefaultValueConverter`)}convert(e,t){let n=t.grammarSource;if(pr(n)&&(n=Ia(n)),ri(n)){let r=n.rule.ref;if(!r)throw Error(`This cst node was not parsed by a rule.`);return this.runConverter(r,e,t)}return e}runConverter(e,t,n){switch(e.name.toUpperCase()){case`INT`:return Lj.convertInt(t);case`STRING`:return Lj.convertString(t);case`ID`:return Lj.convertID(t)}switch(ao(e)?.toLowerCase()){case`number`:return Lj.convertNumber(t);case`boolean`:return Lj.convertBoolean(t);case`bigint`:return Lj.convertBigint(t);case`date`:return Lj.convertDate(t);default:return t}}},Lj;(function(e){function t(e){let t=``;for(let r=1;r{typeof setImmediate>`u`?setTimeout(e,0):setImmediate(e)})}o(Rj,`delayNextTick`);var zj=0,Bj=10;function Vj(){return zj=performance.now(),new Z.CancellationTokenSource}o(Vj,`startCancelableOperation`);function Hj(e){Bj=e}o(Hj,`setInterruptionPeriod`);var Uj=Symbol(`OperationCancelled`);function Wj(e){return e===Uj}o(Wj,`isOperationCancelled`);async function Gj(e){if(e===Z.CancellationToken.None)return;let t=performance.now();if(t-zj>=Bj&&(zj=t,await Rj(),zj=performance.now()),e.isCancellationRequested)throw Uj}o(Gj,`interruptAndCheck`);var Kj=class{static{o(this,`Deferred`)}constructor(){this.promise=new Promise((e,t)=>{this.resolve=t=>(e(t),this),this.reject=e=>(t(e),this)})}},qj=class e{static{o(this,`FullTextDocument`)}constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(t,n){for(let n of t)if(e.isIncremental(n)){let e=Qj(n.range),t=this.offsetAt(e.start),r=this.offsetAt(e.end);this._content=this._content.substring(0,t)+n.text+this._content.substring(r,this._content.length);let i=Math.max(e.start.line,0),a=Math.max(e.end.line,0),o=this._lineOffsets,s=Xj(n.text,!1,t);if(a-i===s.length)for(let e=0,t=s.length;ee?r=i:n=i+1}let i=n-1;return e=this.ensureBeforeEOL(e,t[i]),{line:i,character:e-t[i]}}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line];if(e.character<=0)return n;let r=e.line+1t&&Zj(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}static isFull(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}},Jj;(function(e){function t(e,t,n,r){return new qj(e,t,n,r)}o(t,`create`),e.create=t;function n(e,t,n){if(e instanceof qj)return e.update(t,n),e;throw Error(`TextDocument.update: document must be created by TextDocument.create`)}o(n,`update`),e.update=n;function r(e,t){let n=e.getText(),r=Yj(t.map($j),(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),i=0,a=[];for(let t of r){let r=e.offsetAt(t.range.start);if(ri&&a.push(n.substring(i,r)),t.newText.length&&a.push(t.newText),i=e.offsetAt(t.range.end)}return a.push(n.substr(i)),a.join(``)}o(r,`applyEdits`),e.applyEdits=r})(Jj||={});function Yj(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),i=e.slice(n);Yj(r,t),Yj(i,t);let a=0,o=0,s=0;for(;an.line||t.line===n.line&&t.character>n.character?{start:n,end:t}:e}o(Qj,`getWellformedRange`);function $j(e){let t=Qj(e.range);return t===e.range?e:{newText:e.newText,range:t}}o($j,`getWellformedEdit`);var eM;(()=>{var e={975:e=>{function t(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}o(t,`e`);function n(e,t){for(var n,r=``,i=0,a=-1,o=0,s=0;s<=e.length;++s){if(s2){var c=r.lastIndexOf(`/`);if(c!==r.length-1){c===-1?(r=``,i=0):i=(r=r.slice(0,c)).length-1-r.lastIndexOf(`/`),a=s,o=0;continue}}else if(r.length===2||r.length===1){r=``,i=0,a=s,o=0;continue}}t&&(r.length>0?r+=`/..`:r=`..`,i=2)}else r.length>0?r+=`/`+e.slice(a+1,s):r=e.slice(a+1,s),i=s-a-1}a=s,o=0}else n===46&&o!==-1?++o:o=-1}return r}o(n,`r`);var r={resolve:o(function(){for(var e,r=``,i=!1,a=arguments.length-1;a>=-1&&!i;a--){var o;a>=0?o=arguments[a]:(e===void 0&&(e=process.cwd()),o=e),t(o),o.length!==0&&(r=o+`/`+r,i=o.charCodeAt(0)===47)}return r=n(r,!i),i?r.length>0?`/`+r:`/`:r.length>0?r:`.`},`resolve`),normalize:o(function(e){if(t(e),e.length===0)return`.`;var r=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return(e=n(e,!r)).length!==0||r||(e=`.`),e.length>0&&i&&(e+=`/`),r?`/`+e:e},`normalize`),isAbsolute:o(function(e){return t(e),e.length>0&&e.charCodeAt(0)===47},`isAbsolute`),join:o(function(){if(arguments.length===0)return`.`;for(var e,n=0;n0&&(e===void 0?e=i:e+=`/`+i)}return e===void 0?`.`:r.normalize(e)},`join`),relative:o(function(e,n){if(t(e),t(n),e===n||(e=r.resolve(e))===(n=r.resolve(n)))return``;for(var i=1;il){if(n.charCodeAt(s+d)===47)return n.slice(s+d+1);if(d===0)return n.slice(s+d)}else o>l&&(e.charCodeAt(i+d)===47?u=d:d===0&&(u=0));break}var f=e.charCodeAt(i+d);if(f!==n.charCodeAt(s+d))break;f===47&&(u=d)}var p=``;for(d=i+u+1;d<=a;++d)d!==a&&e.charCodeAt(d)!==47||(p.length===0?p+=`..`:p+=`/..`);return p.length>0?p+n.slice(s+u):(s+=u,n.charCodeAt(s)===47&&++s,n.slice(s))},`relative`),_makeLong:o(function(e){return e},`_makeLong`),dirname:o(function(e){if(t(e),e.length===0)return`.`;for(var n=e.charCodeAt(0),r=n===47,i=-1,a=!0,o=e.length-1;o>=1;--o)if((n=e.charCodeAt(o))===47){if(!a){i=o;break}}else a=!1;return i===-1?r?`/`:`.`:r&&i===1?`//`:e.slice(0,i)},`dirname`),basename:o(function(e,n){if(n!==void 0&&typeof n!=`string`)throw TypeError(`"ext" argument must be a string`);t(e);var r,i=0,a=-1,o=!0;if(n!==void 0&&n.length>0&&n.length<=e.length){if(n.length===e.length&&n===e)return``;var s=n.length-1,c=-1;for(r=e.length-1;r>=0;--r){var l=e.charCodeAt(r);if(l===47){if(!o){i=r+1;break}}else c===-1&&(o=!1,c=r+1),s>=0&&(l===n.charCodeAt(s)?--s==-1&&(a=r):(s=-1,a=c))}return i===a?a=c:a===-1&&(a=e.length),e.slice(i,a)}for(r=e.length-1;r>=0;--r)if(e.charCodeAt(r)===47){if(!o){i=r+1;break}}else a===-1&&(o=!1,a=r+1);return a===-1?``:e.slice(i,a)},`basename`),extname:o(function(e){t(e);for(var n=-1,r=0,i=-1,a=!0,o=0,s=e.length-1;s>=0;--s){var c=e.charCodeAt(s);if(c!==47)i===-1&&(a=!1,i=s+1),c===46?n===-1?n=s:o!==1&&(o=1):n!==-1&&(o=-1);else if(!a){r=s+1;break}}return n===-1||i===-1||o===0||o===1&&n===i-1&&n===r+1?``:e.slice(n,i)},`extname`),format:o(function(e){if(typeof e!=`object`||!e)throw TypeError(`The "pathObject" argument must be of type Object. Received type `+typeof e);return(function(e,t){var n=t.dir||t.root,r=t.base||(t.name||``)+(t.ext||``);return n?n===t.root?n+r:n+`/`+r:r})(0,e)},`format`),parse:o(function(e){t(e);var n={root:``,dir:``,base:``,ext:``,name:``};if(e.length===0)return n;var r,i=e.charCodeAt(0),a=i===47;a?(n.root=`/`,r=1):r=0;for(var o=-1,s=0,c=-1,l=!0,u=e.length-1,d=0;u>=r;--u)if((i=e.charCodeAt(u))!==47)c===-1&&(l=!1,c=u+1),i===46?o===-1?o=u:d!==1&&(d=1):o!==-1&&(d=-1);else if(!l){s=u+1;break}return o===-1||c===-1||d===0||d===1&&o===c-1&&o===s+1?c!==-1&&(n.base=n.name=s===0&&a?e.slice(1,c):e.slice(s,c)):(s===0&&a?(n.name=e.slice(1,o),n.base=e.slice(1,c)):(n.name=e.slice(s,o),n.base=e.slice(s,c)),n.ext=e.slice(o,c)),s>0?n.dir=e.slice(0,s-1):a&&(n.dir=`/`),n},`parse`),sep:`/`,delimiter:`:`,win32:null,posix:null};r.posix=r,e.exports=r}},t={};function n(r){var i=t[r];if(i!==void 0)return i.exports;var a=t[r]={exports:{}};return e[r](a,a.exports,n),a.exports}o(n,`r`),n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};let i;n.r(r),n.d(r,{URI:o(()=>d,`URI`),Utils:o(()=>te,`Utils`)}),typeof process==`object`?i=process.platform===`win32`:typeof navigator==`object`&&(i=navigator.userAgent.indexOf(`Windows`)>=0);let a=/^\w[\w\d+.-]*$/,s=/^\//,c=/^\/\//;function l(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!a.test(e.scheme))throw Error(`[UriError]: Scheme contains illegal characters.`);if(e.path){if(e.authority){if(!s.test(e.path))throw Error(`[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character`)}else if(c.test(e.path))throw Error(`[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")`)}}o(l,`a`);let u=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class d{static{o(this,`l`)}static isUri(e){return e instanceof d||!!e&&typeof e.authority==`string`&&typeof e.fragment==`string`&&typeof e.path==`string`&&typeof e.query==`string`&&typeof e.scheme==`string`&&typeof e.fsPath==`string`&&typeof e.with==`function`&&typeof e.toString==`function`}scheme;authority;path;query;fragment;constructor(e,t,n,r,i,a=!1){typeof e==`object`?(this.scheme=e.scheme||``,this.authority=e.authority||``,this.path=e.path||``,this.query=e.query||``,this.fragment=e.fragment||``):(this.scheme=(function(e,t){return e||t?e:`file`})(e,a),this.authority=t||``,this.path=(function(e,t){switch(e){case`https`:case`http`:case`file`:t?t[0]!==`/`&&(t=`/`+t):t=`/`}return t})(this.scheme,n||``),this.query=r||``,this.fragment=i||``,l(this,a))}get fsPath(){return _(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:n,path:r,query:i,fragment:a}=e;return t===void 0?t=this.scheme:t===null&&(t=``),n===void 0?n=this.authority:n===null&&(n=``),r===void 0?r=this.path:r===null&&(r=``),i===void 0?i=this.query:i===null&&(i=``),a===void 0?a=this.fragment:a===null&&(a=``),t===this.scheme&&n===this.authority&&r===this.path&&i===this.query&&a===this.fragment?this:new p(t,n,r,i,a)}static parse(e,t=!1){let n=u.exec(e);return n?new p(n[2]||``,x(n[4]||``),x(n[5]||``),x(n[7]||``),x(n[9]||``),t):new p(``,``,``,``,``)}static file(e){let t=``;if(i&&(e=e.replace(/\\/g,`/`)),e[0]===`/`&&e[1]===`/`){let n=e.indexOf(`/`,2);n===-1?(t=e.substring(2),e=`/`):(t=e.substring(2,n),e=e.substring(n)||`/`)}return new p(`file`,t,e,``,``)}static from(e){let t=new p(e.scheme,e.authority,e.path,e.query,e.fragment);return l(t,!0),t}toString(e=!1){return v(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof d)return e;{let t=new p(e);return t._formatted=e.external,t._fsPath=e._sep===f?e.fsPath:null,t}}return e}}let f=i?1:void 0;class p extends d{static{o(this,`d`)}_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||=_(this,!1),this._fsPath}toString(e=!1){return e?v(this,!0):(this._formatted||=v(this,!1),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=f),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let m={58:`%3A`,47:`%2F`,63:`%3F`,35:`%23`,91:`%5B`,93:`%5D`,64:`%40`,33:`%21`,36:`%24`,38:`%26`,39:`%27`,40:`%28`,41:`%29`,42:`%2A`,43:`%2B`,44:`%2C`,59:`%3B`,61:`%3D`,32:`%20`};function h(e,t,n){let r,i=-1;for(let a=0;a=97&&o<=122||o>=65&&o<=90||o>=48&&o<=57||o===45||o===46||o===95||o===126||t&&o===47||n&&o===91||n&&o===93||n&&o===58)i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r!==void 0&&(r+=e.charAt(a));else{r===void 0&&(r=e.substr(0,a));let t=m[o];t===void 0?i===-1&&(i=a):(i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r+=t)}}return i!==-1&&(r+=encodeURIComponent(e.substring(i))),r===void 0?e:r}o(h,`m`);function g(e){let t;for(let n=0;n1&&e.scheme===`file`?`//${e.authority}${e.path}`:e.path.charCodeAt(0)===47&&(e.path.charCodeAt(1)>=65&&e.path.charCodeAt(1)<=90||e.path.charCodeAt(1)>=97&&e.path.charCodeAt(1)<=122)&&e.path.charCodeAt(2)===58?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,i&&(n=n.replace(/\//g,`\\`)),n}o(_,`v`);function v(e,t){let n=t?g:h,r=``,{scheme:i,authority:a,path:o,query:s,fragment:c}=e;if(i&&(r+=i,r+=`:`),(a||i===`file`)&&(r+=`/`,r+=`/`),a){let e=a.indexOf(`@`);if(e!==-1){let t=a.substr(0,e);a=a.substr(e+1),e=t.lastIndexOf(`:`),e===-1?r+=n(t,!1,!1):(r+=n(t.substr(0,e),!1,!1),r+=`:`,r+=n(t.substr(e+1),!1,!0)),r+=`@`}a=a.toLowerCase(),e=a.lastIndexOf(`:`),e===-1?r+=n(a,!1,!0):(r+=n(a.substr(0,e),!1,!0),r+=a.substr(e))}if(o){if(o.length>=3&&o.charCodeAt(0)===47&&o.charCodeAt(2)===58){let e=o.charCodeAt(1);e>=65&&e<=90&&(o=`/${String.fromCharCode(e+32)}:${o.substr(3)}`)}else if(o.length>=2&&o.charCodeAt(1)===58){let e=o.charCodeAt(0);e>=65&&e<=90&&(o=`${String.fromCharCode(e+32)}:${o.substr(2)}`)}r+=n(o,!0,!1)}return s&&(r+=`?`,r+=n(s,!1,!1)),c&&(r+=`#`,r+=t?c:h(c,!1,!1)),r}o(v,`b`);function y(e){try{return decodeURIComponent(e)}catch{return e.length>3?e.substr(0,3)+y(e.substr(3)):e}}o(y,`C`);let b=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(e){return e.match(b)?e.replace(b,(e=>y(e))):e}o(x,`w`);var ee=n(975);let S=ee.posix||ee;var te;(function(e){e.joinPath=function(e,...t){return e.with({path:S.join(e.path,...t)})},e.resolvePath=function(e,...t){let n=e.path,r=!1;n[0]!==`/`&&(n=`/`+n,r=!0);let i=S.resolve(n,...t);return r&&i[0]===`/`&&!e.authority&&(i=i.substring(1)),e.with({path:i})},e.dirname=function(e){if(e.path.length===0||e.path===`/`)return e;let t=S.dirname(e.path);return t.length===1&&t.charCodeAt(0)===46&&(t=``),e.with({path:t})},e.basename=function(e){return S.basename(e.path)},e.extname=function(e){return S.extname(e.path)}})(te||={}),eM=r})();var{URI:tM,Utils:nM}=eM,rM;(function(e){e.basename=nM.basename,e.dirname=nM.dirname,e.extname=nM.extname,e.joinPath=nM.joinPath,e.resolvePath=nM.resolvePath;let t=typeof process==`object`&&process?.platform===`win32`;function n(e,t){return e?.toString()===t?.toString()}o(n,`equals`),e.equals=n;function r(e,n){let r=typeof e==`string`?tM.parse(e).path:e.path,i=typeof n==`string`?tM.parse(n).path:n.path,a=r.split(`/`).filter(e=>e.length>0),o=i.split(`/`).filter(e=>e.length>0);if(t){let e=/^[A-Z]:$/;if(a[0]&&e.test(a[0])&&(a[0]=a[0].toLowerCase()),o[0]&&e.test(o[0])&&(o[0]=o[0].toLowerCase()),a[0]!==o[0])return i.substring(1)}let s=0;for(;s({name:e.name,uri:rM.joinPath(tM.parse(t),e.name).toString(),element:e.element})):[]}all(){return this.collectValues(this.root)}findAll(e){let t=this.getNode(rM.normalize(e),!1);return t?this.collectValues(t):[]}getNode(e,t){let n=e.split(`/`);e.charAt(e.length-1)===`/`&&n.pop();let r=this.root;for(let e of n){let n=r.children.get(e);if(!n){if(t)n={name:e,children:new Map,parent:r},r.children.set(e,n);else return}r=n}return r}collectValues(e){let t=[];e.element&&t.push(e.element);for(let n of e.children.values())t.push(...this.collectValues(n));return t}},Q;(function(e){e[e.Changed=0]=`Changed`,e[e.Parsed=1]=`Parsed`,e[e.IndexedContent=2]=`IndexedContent`,e[e.ComputedScopes=3]=`ComputedScopes`,e[e.Linked=4]=`Linked`,e[e.IndexedReferences=5]=`IndexedReferences`,e[e.Validated=6]=`Validated`})(Q||={});var aM=class{static{o(this,`DefaultLangiumDocumentFactory`)}constructor(e){this.serviceRegistry=e.ServiceRegistry,this.textDocuments=e.workspace.TextDocuments,this.fileSystemProvider=e.workspace.FileSystemProvider}async fromUri(e,t=Z.CancellationToken.None){let n=await this.fileSystemProvider.readFile(e);return this.createAsync(e,n,t)}fromTextDocument(e,t,n){return t??=tM.parse(e.uri),Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromString(e,t,n){return Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromModel(e,t){return this.create(t,{$model:e})}create(e,t,n){if(typeof t==`string`){let r=this.parse(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}if(`$model`in t){let n={value:t.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(n,e)}{let r=this.parse(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}async createAsync(e,t,n){if(typeof t==`string`){let r=await this.parseAsync(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}{let r=await this.parseAsync(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}createLangiumDocument(e,t,n,r){let i;if(n)i={parseResult:e,uri:t,state:Q.Parsed,references:[],textDocument:n};else{let n=this.createTextDocumentGetter(t,r);i={parseResult:e,uri:t,state:Q.Parsed,references:[],get textDocument(){return n()}}}return e.value.$document=i,i}async update(e,t){let n=e.parseResult.value.$cstNode?.root.fullText,r=this.textDocuments?.get(e.uri.toString()),i=r?r.getText():await this.fileSystemProvider.readFile(e.uri);if(r)Object.defineProperty(e,"textDocument",{value:r});else{let t=this.createTextDocumentGetter(e.uri,i);Object.defineProperty(e,"textDocument",{get:t})}return n!==i&&(e.parseResult=await this.parseAsync(e.uri,i,t),e.parseResult.value.$document=e),e.state=Q.Parsed,e}parse(e,t,n){return this.serviceRegistry.getServices(e).parser.LangiumParser.parse(t,n)}parseAsync(e,t,n){return this.serviceRegistry.getServices(e).parser.AsyncParser.parse(t,n)}createTextDocumentGetter(e,t){let n=this.serviceRegistry,r;return()=>r??=Jj.create(e.toString(),n.getServices(e).LanguageMetaData.languageId,0,t??``)}},oM=class{static{o(this,`DefaultLangiumDocuments`)}constructor(e){this.documentTrie=new iM,this.services=e,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.documentBuilder=()=>e.workspace.DocumentBuilder}get all(){return N(this.documentTrie.all())}addDocument(e){let t=e.uri.toString();if(this.documentTrie.has(t))throw Error(`A document with the URI '${t}' is already present.`);this.documentTrie.insert(t,e)}getDocument(e){let t=e.toString();return this.documentTrie.find(t)}getDocuments(e){let t=e.toString();return this.documentTrie.findAll(t)}async getOrCreateDocument(e,t){let n=this.getDocument(e);return n||(n=await this.langiumDocumentFactory.fromUri(e,t),this.addDocument(n),n)}createDocument(e,t,n){if(n)return this.langiumDocumentFactory.fromString(t,e,n).then(e=>(this.addDocument(e),e));{let n=this.langiumDocumentFactory.fromString(t,e);return this.addDocument(n),n}}hasDocument(e){return this.documentTrie.has(e.toString())}invalidateDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&this.documentBuilder().resetToState(n,Q.Changed),n}deleteDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&(n.state=Q.Changed,this.documentTrie.delete(t)),n}deleteDocuments(e){let t=e.toString(),n=this.documentTrie.findAll(t);for(let e of n)e.state=Q.Changed;return this.documentTrie.delete(t),n}},sM=Symbol(`RefResolving`),cM=class{static{o(this,`DefaultLinker`)}constructor(e){this.reflection=e.shared.AstReflection,this.langiumDocuments=()=>e.shared.workspace.LangiumDocuments,this.scopeProvider=e.references.ScopeProvider,this.astNodeLocator=e.workspace.AstNodeLocator,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async link(e,t=Z.CancellationToken.None){if(this.profiler?.isActive(`linking`)){let n=this.profiler.createTask(`linking`,this.languageId);n.start();try{for(let r of Mn(e.parseResult.value))await Gj(t),Pn(r).forEach(t=>{let i=`${r.$type}:${t.property}`;n.startSubTask(i);try{this.doLink(t,e)}finally{n.stopSubTask(i)}})}finally{n.stop()}}else for(let n of Mn(e.parseResult.value))await Gj(t),Pn(n).forEach(t=>this.doLink(t,e))}doLink(e,t){let n=e.reference;if(`_ref`in n&&n._ref===void 0){n._ref=sM;try{let t=this.getCandidate(e);dn(t)?n._ref=t:(n._nodeDescription=t,n._ref=this.loadAstNode(t)??this.createLinkingError(e,t))}catch(t){console.error(`An error occurred while resolving reference to '${n.$refText}':`,t);let r=t.message??String(t);n._ref={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${r}`}}t.references.push(n)}else if(`_items`in n&&n._items===void 0){n._items=sM;try{let t=this.getCandidates(e),r=[];if(dn(t))n._linkingError=t;else for(let e of t){let t=this.loadAstNode(e);t&&r.push({ref:t,$nodeDescription:e})}n._items=r}catch(t){n._linkingError={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${t}`},n._items=[]}t.references.push(n)}}unlink(e){for(let t of e.references)`_ref`in t?(t._ref=void 0,delete t._nodeDescription):`_items`in t&&(t._items=void 0,delete t._linkingError);e.references=[]}getCandidate(e){return this.scopeProvider.getScope(e).getElement(e.reference.$refText)??this.createLinkingError(e)}getCandidates(e){let t=this.scopeProvider.getScope(e).getElements(e.reference.$refText).distinct(e=>`${e.documentUri}#${e.path}`).toArray();return t.length>0?t:this.createLinkingError(e)}buildReference(e,t,n,r){let i=this,a={$refNode:n,$refText:r,_ref:void 0,get ref(){if(M(this._ref))return this._ref;if(un(this._nodeDescription)){let n=i.loadAstNode(this._nodeDescription);this._ref=n??i.createLinkingError({reference:a,container:e,property:t},this._nodeDescription)}else if(this._ref===void 0){this._ref=sM;let n=On(e).$document,r=i.getLinkedNode({reference:a,container:e,property:t});if(r.error&&n&&n.state0))return this._linkingError=i.createLinkingError({reference:a,container:e,property:t})}};return a}throwCyclicReferenceError(e,t,n){throw Error(`Cyclic reference resolution detected: ${this.astNodeLocator.getAstNodePath(e)}/${t} (symbol '${n}')`)}getLinkedNode(e){try{let t=this.getCandidate(e);if(dn(t))return{error:t};let n=this.loadAstNode(t);return n?{node:n,descr:t}:{descr:t,error:this.createLinkingError(e,t)}}catch(t){console.error(`An error occurred while resolving reference to '${e.reference.$refText}':`,t);let n=t.message??String(t);return{error:{info:e,message:`An error occurred while resolving reference to '${e.reference.$refText}': ${n}`}}}}loadAstNode(e){if(e.node)return e.node;let t=this.langiumDocuments().getDocument(e.documentUri);if(t)return this.astNodeLocator.getAstNode(t.parseResult.value,e.path)}createLinkingError(e,t){let n=On(e.container).$document;return n&&n.statepr(e)&&e.isMulti)}findDeclarations(e){if(e){let t=Wa(e),n=e.astNode;if(t&&n){let r=n[t.feature];if(cn(r)||ln(r))return kn(r);if(Array.isArray(r)){for(let t of r)if((cn(t)||ln(t))&&t.$refNode&&t.$refNode.offset<=e.offset&&t.$refNode.end>=e.end)return kn(t)}}if(n){let t=this.nameProvider.getNameNode(n);if(t&&(t===e||Ri(e,t)))return this.getSelfNodes(n)}}return[]}getSelfNodes(e){if(this.hasMultiReference){let t=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e)),n=this.getNodeFromReferenceDescription(t.head());if(n){for(let t of Pn(n))if(ln(t.reference)&&t.reference.items.some(t=>t.ref===e))return t.reference.items.map(e=>e.ref)}return[e]}return[e]}getNodeFromReferenceDescription(e){if(!e)return;let t=this.documents.getDocument(e.sourceUri);if(t)return this.nodeLocator.getAstNode(t.parseResult.value,e.sourcePath)}findDeclarationNodes(e){let t=this.findDeclarations(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e)??e.$cstNode;t&&n.push(t)}return n}findReferences(e,t){let n=[];t.includeDeclaration&&n.push(...this.getSelfReferences(e));let r=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e));return t.documentUri&&(r=r.filter(e=>rM.equals(e.sourceUri,t.documentUri))),n.push(...r),N(n)}getSelfReferences(e){let t=this.getSelfNodes(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e);if(t){let r=Dn(e),i=this.nodeLocator.getAstNodePath(e);n.push({sourceUri:r.uri,sourcePath:i,targetUri:r.uri,targetPath:i,segment:Bi(t),local:!0})}}return n}},fM=class{static{o(this,`MultiMap`)}constructor(e){if(this.map=new Map,e)for(let[t,n]of e)this.add(t,n)}get size(){return Sn.sum(N(this.map.values()).map(e=>e.length))}clear(){this.map.clear()}delete(e,t){if(t===void 0)return this.map.delete(e);{let n=this.map.get(e);if(n){let r=n.indexOf(t);if(r>=0)return n.length===1?this.map.delete(e):n.splice(r,1),!0}return!1}}get(e){return this.map.get(e)??[]}getStream(e){let t=this.map.get(e);return t?N(t):yn}has(e,t){if(t===void 0)return this.map.has(e);{let n=this.map.get(e);return n?n.indexOf(t)>=0:!1}}add(e,t){return this.map.has(e)?this.map.get(e).push(t):this.map.set(e,[t]),this}addAll(e,t){return this.map.has(e)?this.map.get(e).push(...t):this.map.set(e,Array.from(t)),this}forEach(e){this.map.forEach((t,n)=>t.forEach(t=>e(t,n,this)))}[Symbol.iterator](){return this.entries().iterator()}entries(){return N(this.map.entries()).flatMap(([e,t])=>t.map(t=>[e,t]))}keys(){return N(this.map.keys())}values(){return N(this.map.values()).flat()}entriesGroupedByKey(){return N(this.map.entries())}},pM=class{static{o(this,`BiMap`)}get size(){return this.map.size}constructor(e){if(this.map=new Map,this.inverse=new Map,e)for(let[t,n]of e)this.set(t,n)}clear(){this.map.clear(),this.inverse.clear()}set(e,t){return this.map.set(e,t),this.inverse.set(t,e),this}get(e){return this.map.get(e)}getKey(e){return this.inverse.get(e)}delete(e){let t=this.map.get(e);return t!==void 0&&(this.map.delete(e),this.inverse.delete(t),!0)}},mM=class{static{o(this,`DefaultScopeComputation`)}constructor(e){this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider}async collectExportedSymbols(e,t=Z.CancellationToken.None){return this.collectExportedSymbolsForNode(e.parseResult.value,e,void 0,t)}async collectExportedSymbolsForNode(e,t,n=An,r=Z.CancellationToken.None){let i=[];this.addExportedSymbol(e,i,t);for(let a of n(e))await Gj(r),this.addExportedSymbol(a,i,t);return i}addExportedSymbol(e,t,n){let r=this.nameProvider.getName(e);r&&t.push(this.descriptions.createDescription(e,r,n))}async collectLocalSymbols(e,t=Z.CancellationToken.None){let n=e.parseResult.value,r=new fM;for(let i of jn(n))await Gj(t),this.addLocalSymbol(i,e,r);return r}addLocalSymbol(e,t,n){let r=e.$container;if(r){let i=this.nameProvider.getName(e);i&&n.add(r,this.descriptions.createDescription(e,i,t))}}},hM=class{static{o(this,`StreamScope`)}constructor(e,t,n){this.elements=e,this.outerScope=t,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.find(e=>e.name.toLowerCase()===t):this.elements.find(t=>t.name===e);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.filter(e=>e.name.toLowerCase()===t):this.elements.filter(t=>t.name===e);return(this.concatOuterScope||n.isEmpty())&&this.outerScope?n.concat(this.outerScope.getElements(e)):n}},gM=class{static{o(this,`MapScope`)}constructor(e,t,n){this.elements=new Map,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.set(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t),r=n?[n]:[];return(this.concatOuterScope||r.length>0)&&this.outerScope?N(r).concat(this.outerScope.getElements(e)):N(r)}getAllElements(){let e=N(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},_M=class{static{o(this,`MultiMapScope`)}constructor(e,t,n){this.elements=new fM,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.add(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t)[0];if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);return(this.concatOuterScope||n.length===0)&&this.outerScope?N(n).concat(this.outerScope.getElements(e)):N(n)}getAllElements(){let e=N(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},vM={getElement(){},getElements(){return yn},getAllElements(){return yn}},yM=class{static{o(this,`DisposableCache`)}constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(e){this.toDispose.push(e)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach(e=>e.dispose())}throwIfDisposed(){if(this.isDisposed)throw Error(`This cache has already been disposed`)}},bM=class extends yM{static{o(this,`SimpleCache`)}constructor(){super(...arguments),this.cache=new Map}has(e){return this.throwIfDisposed(),this.cache.has(e)}set(e,t){this.throwIfDisposed(),this.cache.set(e,t)}get(e,t){if(this.throwIfDisposed(),this.cache.has(e))return this.cache.get(e);if(t){let n=t();return this.cache.set(e,n),n}}delete(e){return this.throwIfDisposed(),this.cache.delete(e)}clear(){this.throwIfDisposed(),this.cache.clear()}},xM=class extends yM{static{o(this,`ContextCache`)}constructor(e){super(),this.cache=new Map,this.converter=e??(e=>e)}has(e,t){return this.throwIfDisposed(),this.cacheForContext(e).has(t)}set(e,t,n){this.throwIfDisposed(),this.cacheForContext(e).set(t,n)}get(e,t,n){this.throwIfDisposed();let r=this.cacheForContext(e);if(r.has(t))return r.get(t);if(n){let e=n();return r.set(t,e),e}}delete(e,t){return this.throwIfDisposed(),this.cacheForContext(e).delete(t)}clear(e){if(this.throwIfDisposed(),e){let t=this.converter(e);this.cache.delete(t)}else this.cache.clear()}cacheForContext(e){let t=this.converter(e),n=this.cache.get(t);return n||(n=new Map,this.cache.set(t,n)),n}},SM=class extends xM{static{o(this,`DocumentCache`)}constructor(e,t){super(e=>e.toString()),t?(this.toDispose.push(e.workspace.DocumentBuilder.onDocumentPhase(t,e=>{this.clear(e.uri.toString())})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{for(let e of t)this.clear(e)}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{let n=e.concat(t);for(let e of n)this.clear(e)}))}},CM=class extends bM{static{o(this,`WorkspaceCache`)}constructor(e,t){super(),t?(this.toDispose.push(e.workspace.DocumentBuilder.onBuildPhase(t,()=>{this.clear()})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{t.length>0&&this.clear()}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate(()=>{this.clear()}))}},wM=class{static{o(this,`DefaultScopeProvider`)}constructor(e){this.reflection=e.shared.AstReflection,this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider,this.indexManager=e.shared.workspace.IndexManager,this.globalScopeCache=new CM(e.shared)}getScope(e){let t=[],n=this.reflection.getReferenceType(e),r=Dn(e.container).localSymbols;if(r){let i=e.container;do r.has(i)&&t.push(r.getStream(i).filter(e=>this.reflection.isSubtype(e.type,n))),i=i.$container;while(i)}let i=this.getGlobalScope(n,e);for(let e=t.length-1;e>=0;e--)i=this.createScope(t[e],i);return i}createScope(e,t,n){return new hM(N(e),t,n)}createScopeForNodes(e,t,n){return new hM(N(e).map(e=>{let t=this.nameProvider.getName(e);if(t)return this.descriptions.createDescription(e,t)}).nonNullable(),t,n)}getGlobalScope(e,t){return this.globalScopeCache.get(e,()=>new _M(this.indexManager.allElements(e)))}};function TM(e){return typeof e.$comment==`string`}o(TM,`isAstNodeWithComment`);function EM(e){return typeof e==`object`&&!!e&&(`$ref`in e||`$error`in e)}o(EM,`isIntermediateReference`);var DM=class{static{o(this,`DefaultJsonSerializer`)}constructor(e){this.ignoreProperties=new Set([`$container`,`$containerProperty`,`$containerIndex`,`$document`,`$cstNode`]),this.langiumDocuments=e.shared.workspace.LangiumDocuments,this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider,this.commentProvider=e.documentation.CommentProvider}serialize(e,t){let n=t??{},r=t?.replacer,i=o((e,t)=>this.replacer(e,t,n),`defaultReplacer`),a=r?(e,t)=>r(e,t,i):i;try{return this.currentDocument=Dn(e),JSON.stringify(e,a,t?.space)}finally{this.currentDocument=void 0}}deserialize(e,t){let n=t??{},r=JSON.parse(e);return this.linkNode(r,r,n),r}replacer(e,t,{refText:n,sourceText:r,textRegions:i,comments:a,uriConverter:o}){if(!this.ignoreProperties.has(e)){if(cn(t)){let e=t.ref,r=n?t.$refText:void 0;if(e){let t=Dn(e),n=``;this.currentDocument&&this.currentDocument!==t&&(n=o?o(t.uri,e):t.uri.toString());let i=this.astNodeLocator.getAstNodePath(e);return{$ref:`${n}#${i}`,$refText:r}}return{$error:t.error?.message??`Could not resolve reference`,$refText:r}}if(ln(t)){let e=n?t.$refText:void 0,r=[];for(let e of t.items){let t=e.ref,n=Dn(e.ref),i=``;this.currentDocument&&this.currentDocument!==n&&(i=o?o(n.uri,t):n.uri.toString());let a=this.astNodeLocator.getAstNodePath(t);r.push(`${i}#${a}`)}return{$refs:r,$refText:e}}if(M(t)){let n;if(i&&(n=this.addAstNodeRegionWithAssignmentsTo({...t}),(!e||t.$document)&&n?.$textRegion&&(n.$textRegion.documentURI=this.currentDocument?.uri.toString())),r&&!e&&(n??={...t},n.$sourceText=t.$cstNode?.text),a){n??={...t};let e=this.commentProvider.getComment(t);e&&(n.$comment=e.replace(/\r/g,``))}return n??t}return t}}addAstNodeRegionWithAssignmentsTo(e){let t=o(e=>({offset:e.offset,end:e.end,length:e.length,range:e.range}),`createDocumentSegment`);if(e.$cstNode){let n=e.$textRegion=t(e.$cstNode),r=n.assignments={};return Object.keys(e).filter(e=>!e.startsWith(`$`)).forEach(n=>{let i=Ra(e.$cstNode,n).map(t);i.length!==0&&(r[n]=i)}),e}}linkNode(e,t,n,r,i,a){for(let[r,i]of Object.entries(e))if(Array.isArray(i))for(let a=0;a{await this.handleException(()=>e.call(t,n,r,i),`An error occurred during validation`,r,n)}}async handleException(e,t,n,r){try{await e()}catch(e){if(Wj(e))throw e;console.error(`${t}:`,e),e instanceof Error&&e.stack&&console.error(e.stack),n(`error`,`${t}: ${e instanceof Error?e.message:String(e)}`,{node:r})}}addEntry(e,t){if(e===`AstNode`){this.entries.add(`AstNode`,t);return}for(let n of this.reflection.getAllSubTypes(e))this.entries.add(n,t)}getChecks(e,t){let n=N(this.entries.get(e)).concat(this.entries.get(`AstNode`));return t&&(n=n.filter(e=>t.includes(e.category))),n.map(e=>e.check)}registerBeforeDocument(e,t=this){this.entriesBefore.push(this.wrapPreparationException(e,`An error occurred during set-up of the validation`,t))}registerAfterDocument(e,t=this){this.entriesAfter.push(this.wrapPreparationException(e,`An error occurred during tear-down of the validation`,t))}wrapPreparationException(e,t,n){return async(r,i,a,o)=>{await this.handleException(()=>e.call(n,r,i,a,o),t,i,r)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}getAllValidationCategories(e){return this.knownCategories}},MM=Object.freeze({validateNode:!0,validateChildren:!0}),NM=class{static{o(this,`DefaultDocumentValidator`)}constructor(e){this.validationRegistry=e.validation.ValidationRegistry,this.metadata=e.LanguageMetaData,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async validateDocument(e,t={},n=Z.CancellationToken.None){let r=e.parseResult,i=[];if(await Gj(n),(!t.categories||t.categories.includes(`built-in`))&&(this.processLexingErrors(r,i,t),t.stopAfterLexingErrors&&i.some(e=>e.data?.code===LM.LexingError)||(this.processParsingErrors(r,i,t),t.stopAfterParsingErrors&&i.some(e=>e.data?.code===LM.ParsingError))||(this.processLinkingErrors(e,i,t),t.stopAfterLinkingErrors&&i.some(e=>e.data?.code===LM.LinkingError))))return i;try{i.push(...await this.validateAst(r.value,t,n))}catch(e){if(Wj(e))throw e;console.error(`An error occurred during validation:`,e)}return await Gj(n),i}processLexingErrors(e,t,n){let r=[...e.lexerErrors,...e.lexerReport?.diagnostics??[]];for(let e of r){let n=e.severity??`error`,r={severity:FM(n),range:{start:{line:e.line-1,character:e.column-1},end:{line:e.line-1,character:e.column+e.length-1}},message:e.message,data:IM(n),source:this.getSource()};t.push(r)}}processParsingErrors(e,t,n){for(let n of e.parserErrors){let e;if(isNaN(n.token.startOffset)){if(`previousToken`in n){let t=n.previousToken;if(isNaN(t.startOffset)){let t={line:0,character:0};e={start:t,end:t}}else{let n={line:t.endLine-1,character:t.endColumn};e={start:n,end:n}}}}else e=zi(n.token);if(e){let r={severity:FM(`error`),range:e,message:n.message,data:kM(LM.ParsingError),source:this.getSource()};t.push(r)}}}processLinkingErrors(e,t,n){for(let n of e.references){let e=n.error;if(e){let r={node:e.info.container,range:n.$refNode?.range,property:e.info.property,index:e.info.index,data:{code:LM.LinkingError,containerType:e.info.container.$type,property:e.info.property,refText:e.info.reference.$refText}};t.push(this.toDiagnostic(`error`,e.message,r))}}}async validateAst(e,t,n=Z.CancellationToken.None){let r=[],i=o((e,t,n)=>{r.push(this.toDiagnostic(e,t,n))},`acceptor`);return await this.validateAstBefore(e,t,i,n),await this.validateAstNodes(e,t,i,n),await this.validateAstAfter(e,t,i,n),r}async validateAstBefore(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksBefore;for(let a of i)await Gj(r),await a(e,n,t.categories??[],r)}async validateAstNodes(e,t,n,r=Z.CancellationToken.None){if(this.profiler?.isActive(`validating`)){let i=this.profiler.createTask(`validating`,this.languageId);i.start();try{let a=Mn(e).iterator();for(let e of a){i.startSubTask(e.$type);let o=this.validateSingleNodeOptions(e,t);if(o.validateNode)try{let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}finally{i.stopSubTask(e.$type)}o.validateChildren||a.prune()}}finally{i.stop()}}else{let i=Mn(e).iterator();for(let e of i){await Gj(r);let a=this.validateSingleNodeOptions(e,t);if(a.validateNode){let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}a.validateChildren||i.prune()}}}validateSingleNodeOptions(e,t){return MM}async validateAstAfter(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksAfter;for(let a of i)await Gj(r),await a(e,n,t.categories??[],r)}toDiagnostic(e,t,n){return{message:t,range:PM(n),severity:FM(e),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}};function PM(e){if(e.range)return e.range;let t;return typeof e.property==`string`?t=za(e.node.$cstNode,e.property,e.index):typeof e.keyword==`string`&&(t=Ha(e.node.$cstNode,e.keyword,e.index)),t??=e.node.$cstNode,t?t.range:{start:{line:0,character:0},end:{line:0,character:0}}}o(PM,`getDiagnosticRange`);function FM(e){switch(e){case`error`:return 1;case`warning`:return 2;case`info`:return 3;case`hint`:return 4;default:throw Error(`Invalid diagnostic severity: `+e)}}o(FM,`toDiagnosticSeverity`);function IM(e){switch(e){case`error`:return kM(LM.LexingError);case`warning`:return kM(LM.LexingWarning);case`info`:return kM(LM.LexingInfo);case`hint`:return kM(LM.LexingHint);default:throw Error(`Invalid diagnostic severity: `+e)}}o(IM,`toDiagnosticData`);var LM;(function(e){e.LexingError=`lexing-error`,e.LexingWarning=`lexing-warning`,e.LexingInfo=`lexing-info`,e.LexingHint=`lexing-hint`,e.ParsingError=`parsing-error`,e.LinkingError=`linking-error`})(LM||={});var RM=class{static{o(this,`DefaultAstNodeDescriptionProvider`)}constructor(e){this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider}createDescription(e,t,n){let r=n??Dn(e);t??=this.nameProvider.getName(e);let i=this.astNodeLocator.getAstNodePath(e);if(!t)throw Error(`Node at path ${i} has no name.`);let a,s=o(()=>a??=Bi(this.nameProvider.getNameNode(e)??e.$cstNode),`nameSegmentGetter`);return{node:e,name:t,get nameSegment(){return s()},selectionSegment:Bi(e.$cstNode),type:e.$type,documentUri:r.uri,path:i}}},zM=class{static{o(this,`DefaultReferenceDescriptionProvider`)}constructor(e){this.nodeLocator=e.workspace.AstNodeLocator}async createDescriptions(e,t=Z.CancellationToken.None){let n=[],r=e.parseResult.value;for(let e of Mn(r))await Gj(t),Pn(e).forEach(e=>{e.reference.error||n.push(...this.createInfoDescriptions(e))});return n}createInfoDescriptions(e){let t=e.reference;if(t.error||!t.$refNode)return[];let n=[];cn(t)&&t.$nodeDescription?n=[t.$nodeDescription]:ln(t)&&(n=t.items.map(e=>e.$nodeDescription).filter(e=>e!==void 0));let r=Dn(e.container).uri,i=this.nodeLocator.getAstNodePath(e.container),a=[],o=Bi(t.$refNode);for(let e of n)a.push({sourceUri:r,sourcePath:i,targetUri:e.documentUri,targetPath:e.path,segment:o,local:rM.equals(e.documentUri,r)});return a}},BM=class{static{o(this,`DefaultAstNodeLocator`)}constructor(){this.segmentSeparator=`/`,this.indexSeparator=`@`}getAstNodePath(e){if(e.$container){let t=this.getAstNodePath(e.$container),n=this.getPathSegment(e);return t+this.segmentSeparator+n}return``}getPathSegment({$containerProperty:e,$containerIndex:t}){if(!e)throw Error(`Missing '$containerProperty' in AST node.`);return t===void 0?e:e+this.indexSeparator+t}getAstNode(e,t){return t.split(this.segmentSeparator).reduce((e,t)=>{if(!e||t.length===0)return e;let n=t.indexOf(this.indexSeparator);if(n>0){let r=t.substring(0,n),i=parseInt(t.substring(n+1));return e[r]?.[i]}return e[t]},e)}},VM={};d(VM,f(vt(),1));var HM=class{static{o(this,`DefaultConfigurationProvider`)}constructor(e){this._ready=new Kj,this.onConfigurationSectionUpdateEmitter=new VM.Emitter,this.settings={},this.workspaceConfig=!1,this.serviceRegistry=e.ServiceRegistry}get ready(){return this._ready.promise}initialize(e){this.workspaceConfig=e.capabilities.workspace?.configuration??!1}async initialized(e){if(this.workspaceConfig){if(e.register){let t=this.serviceRegistry.all;e.register({section:t.map(e=>this.toSectionName(e.LanguageMetaData.languageId))})}if(e.fetchConfiguration){let t=this.serviceRegistry.all.map(e=>({section:this.toSectionName(e.LanguageMetaData.languageId)})),n=await e.fetchConfiguration(t);t.forEach((e,t)=>{this.updateSectionConfiguration(e.section,n[t])})}}this._ready.resolve()}updateConfiguration(e){typeof e.settings==`object`&&e.settings!==null&&Object.entries(e.settings).forEach(([e,t])=>{this.updateSectionConfiguration(e,t),this.onConfigurationSectionUpdateEmitter.fire({section:e,configuration:t})})}updateSectionConfiguration(e,t){this.settings[e]=t}async getConfiguration(e,t){await this.ready;let n=this.toSectionName(e);if(this.settings[n])return this.settings[n][t]}toSectionName(e){return`${e}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}},UM=f(an(),1),WM;(function(e){function t(e){return{dispose:o(async()=>await e(),`dispose`)}}o(t,`create`),e.create=t})(WM||={});var GM=class{static{o(this,`DefaultDocumentBuilder`)}constructor(e){this.updateBuildOptions={validation:{categories:[`built-in`,`fast`]}},this.updateListeners=[],this.buildPhaseListeners=new fM,this.documentPhaseListeners=new fM,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=Q.Changed,this.langiumDocuments=e.workspace.LangiumDocuments,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.textDocuments=e.workspace.TextDocuments,this.indexManager=e.workspace.IndexManager,this.fileSystemProvider=e.workspace.FileSystemProvider,this.workspaceManager=()=>e.workspace.WorkspaceManager,this.serviceRegistry=e.ServiceRegistry}async build(e,t={},n=Z.CancellationToken.None){for(let n of e){let e=n.uri.toString();if(n.state===Q.Validated){if(typeof t.validation==`boolean`&&t.validation)this.resetToState(n,Q.IndexedReferences);else if(typeof t.validation==`object`){let r=this.findMissingValidationCategories(n,t);r.length>0&&(this.buildState.set(e,{completed:!1,options:{validation:{categories:r}},result:this.buildState.get(e)?.result}),n.state=Q.IndexedReferences)}}else this.buildState.delete(e)}this.currentState=Q.Changed,await this.emitUpdate(e.map(e=>e.uri),[]),await this.buildDocuments(e,t,n)}async update(e,t,n=Z.CancellationToken.None){this.currentState=Q.Changed;let r=[];for(let e of t){let t=this.langiumDocuments.deleteDocuments(e);for(let e of t)r.push(e.uri),this.cleanUpDeleted(e)}let i=(await Promise.all(e.map(e=>this.findChangedUris(e)))).flat();for(let e of i){let t=this.langiumDocuments.getDocument(e);t===void 0&&(t=this.langiumDocumentFactory.fromModel({$type:`INVALID`},e),t.state=Q.Changed,this.langiumDocuments.addDocument(t)),this.resetToState(t,Q.Changed)}let a=N(i).concat(r).map(e=>e.toString()).toSet();this.langiumDocuments.all.filter(e=>!a.has(e.uri.toString())&&this.shouldRelink(e,a)).forEach(e=>this.resetToState(e,Q.ComputedScopes)),await this.emitUpdate(i,r),await Gj(n);let o=this.sortDocuments(this.langiumDocuments.all.filter(e=>e.state=1}findMissingValidationCategories(e,t){let n=this.buildState.get(e.uri.toString()),r=this.serviceRegistry.getServices(e.uri).validation.ValidationRegistry.getAllValidationCategories(e),i=n?.result?.validationChecks?new Set(n?.result?.validationChecks):n?.completed?r:new Set;return N(t===void 0||t.validation===!0?r:typeof t.validation==`object`?t.validation.categories??r:[]).filter(e=>!i.has(e)).toArray()}async findChangedUris(e){if(this.langiumDocuments.getDocument(e)??this.textDocuments?.get(e))return[e];try{let t=await this.fileSystemProvider.stat(e);if(t.isDirectory)return await this.workspaceManager().searchFolder(e);if(this.workspaceManager().shouldIncludeEntry(t))return[e]}catch{}return[]}async emitUpdate(e,t){await Promise.all(this.updateListeners.map(n=>n(e,t)))}sortDocuments(e){let t=0,n=e.length-1;for(;t=0&&!this.hasTextDocument(e[n]);)n--;te.error!==void 0)?!0:this.indexManager.isAffected(e,t)}onUpdate(e){return this.updateListeners.push(e),WM.create(()=>{let t=this.updateListeners.indexOf(e);t>=0&&this.updateListeners.splice(t,1)})}resetToState(e,t){switch(t){case Q.Changed:case Q.Parsed:this.indexManager.removeContent(e.uri);case Q.IndexedContent:e.localSymbols=void 0;case Q.ComputedScopes:this.serviceRegistry.getServices(e.uri).references.Linker.unlink(e);case Q.Linked:this.indexManager.removeReferences(e.uri);case Q.IndexedReferences:e.diagnostics=void 0,this.buildState.delete(e.uri.toString());case Q.Validated:}e.state>t&&(e.state=t)}cleanUpDeleted(e){this.buildState.delete(e.uri.toString()),this.indexManager.remove(e.uri),e.state=Q.Changed}async buildDocuments(e,t,n){this.prepareBuild(e,t),await this.runCancelable(e,Q.Parsed,n,e=>this.langiumDocumentFactory.update(e,n)),await this.runCancelable(e,Q.IndexedContent,n,e=>this.indexManager.updateContent(e,n)),await this.runCancelable(e,Q.ComputedScopes,n,async e=>{e.localSymbols=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectLocalSymbols(e,n)});let r=e.filter(e=>this.shouldLink(e));await this.runCancelable(r,Q.Linked,n,e=>this.serviceRegistry.getServices(e.uri).references.Linker.link(e,n)),await this.runCancelable(r,Q.IndexedReferences,n,e=>this.indexManager.updateReferences(e,n));let i=e.filter(e=>this.shouldValidate(e)?!0:(this.markAsCompleted(e),!1));await this.runCancelable(i,Q.Validated,n,async e=>{await this.validate(e,n),this.markAsCompleted(e)})}markAsCompleted(e){let t=this.buildState.get(e.uri.toString());t&&(t.completed=!0)}prepareBuild(e,t){for(let n of e){let e=n.uri.toString(),r=this.buildState.get(e);(!r||r.completed)&&this.buildState.set(e,{completed:!1,options:t,result:r?.result})}}async runCancelable(e,t,n,r){for(let i of e)i.statee.state===t);await this.notifyBuildPhase(i,t,n),this.currentState=t}onBuildPhase(e,t){return this.buildPhaseListeners.add(e,t),WM.create(()=>{this.buildPhaseListeners.delete(e,t)})}onDocumentPhase(e,t){return this.documentPhaseListeners.add(e,t),WM.create(()=>{this.documentPhaseListeners.delete(e,t)})}waitUntil(e,t,n){let r;return t&&`path`in t?r=t:n=t,n??=Z.CancellationToken.None,r?this.awaitDocumentState(e,r,n):this.awaitBuilderState(e,n)}awaitDocumentState(e,t,n){let r=this.langiumDocuments.getDocument(t);return r?r.state>=e?Promise.resolve(t):n.isCancellationRequested?Promise.reject(Uj):this.currentState>=e&&e>r.state?Promise.reject(new UM.ResponseError(UM.LSPErrorCodes.RequestFailed,`Document state of ${t.toString()} is ${Q[r.state]}, requiring ${Q[e]}, but workspace state is already ${Q[this.currentState]}. Returning undefined.`)):new Promise((r,i)=>{let a=this.onDocumentPhase(e,e=>{rM.equals(e.uri,t)&&(a.dispose(),o.dispose(),r(e.uri))}),o=n.onCancellationRequested(()=>{a.dispose(),o.dispose(),i(Uj)})}):Promise.reject(new UM.ResponseError(UM.LSPErrorCodes.ServerCancelled,`No document found for URI: ${t.toString()}`))}awaitBuilderState(e,t){return this.currentState>=e?Promise.resolve():t.isCancellationRequested?Promise.reject(Uj):new Promise((n,r)=>{let i=this.onBuildPhase(e,()=>{i.dispose(),a.dispose(),n()}),a=t.onCancellationRequested(()=>{i.dispose(),a.dispose(),r(Uj)})})}async notifyDocumentPhase(e,t,n){let r=this.documentPhaseListeners.get(t).slice();for(let t of r)try{await Gj(n),await t(e,n)}catch(e){if(!Wj(e))throw e}}async notifyBuildPhase(e,t,n){if(e.length===0)return;let r=this.buildPhaseListeners.get(t).slice();for(let t of r)await Gj(n),await t(e,n)}shouldLink(e){return this.getBuildOptions(e).eagerLinking??!0}shouldValidate(e){return!!this.getBuildOptions(e).validation}async validate(e,t){let n=this.serviceRegistry.getServices(e.uri).validation.DocumentValidator,r=this.getBuildOptions(e),i=typeof r.validation==`object`?{...r.validation}:{};i.categories=this.findMissingValidationCategories(e,r);let a=await n.validateDocument(e,i,t);e.diagnostics?e.diagnostics.push(...a):e.diagnostics=a;let o=this.buildState.get(e.uri.toString());o&&(o.result??={},o.result.validationChecks?o.result.validationChecks=N(o.result.validationChecks).concat(i.categories).distinct().toArray():o.result.validationChecks=[...i.categories])}getBuildOptions(e){return this.buildState.get(e.uri.toString())?.options??{}}},KM=class{static{o(this,`DefaultIndexManager`)}constructor(e){this.symbolIndex=new Map,this.symbolByTypeIndex=new xM,this.referenceIndex=new Map,this.documents=e.workspace.LangiumDocuments,this.serviceRegistry=e.ServiceRegistry,this.astReflection=e.AstReflection}findAllReferences(e,t){let n=Dn(e).uri,r=[];return this.referenceIndex.forEach(e=>{e.forEach(e=>{rM.equals(e.targetUri,n)&&e.targetPath===t&&r.push(e)})}),N(r)}allElements(e,t){let n=N(this.symbolIndex.keys());return t&&(n=n.filter(e=>!t||t.has(e))),n.map(t=>this.getFileDescriptions(t,e)).flat()}getFileDescriptions(e,t){return t?this.symbolByTypeIndex.get(e,t,()=>(this.symbolIndex.get(e)??[]).filter(e=>this.astReflection.isSubtype(e.type,t))):this.symbolIndex.get(e)??[]}remove(e){this.removeContent(e),this.removeReferences(e)}removeContent(e){let t=e.toString();this.symbolIndex.delete(t),this.symbolByTypeIndex.clear(t)}removeReferences(e){let t=e.toString();this.referenceIndex.delete(t)}async updateContent(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectExportedSymbols(e,t),r=e.uri.toString();this.symbolIndex.set(r,n),this.symbolByTypeIndex.clear(r)}async updateReferences(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).workspace.ReferenceDescriptionProvider.createDescriptions(e,t);this.referenceIndex.set(e.uri.toString(),n)}isAffected(e,t){let n=this.referenceIndex.get(e.uri.toString());return n?n.some(e=>!e.local&&t.has(e.targetUri.toString())):!1}},qM=class{static{o(this,`DefaultWorkspaceManager`)}constructor(e){this.initialBuildOptions={},this._ready=new Kj,this.serviceRegistry=e.ServiceRegistry,this.langiumDocuments=e.workspace.LangiumDocuments,this.documentBuilder=e.workspace.DocumentBuilder,this.fileSystemProvider=e.workspace.FileSystemProvider,this.mutex=e.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(e){this.folders=e.workspaceFolders??void 0}initialized(e){return this.mutex.write(e=>this.initializeWorkspace(this.folders??[],e))}async initializeWorkspace(e,t=Z.CancellationToken.None){let n=await this.performStartup(e);await Gj(t),await this.documentBuilder.build(n,this.initialBuildOptions,t)}async performStartup(e){let t=[],n=o(e=>{t.push(e),this.langiumDocuments.hasDocument(e.uri)||this.langiumDocuments.addDocument(e)},`collector`);await this.loadAdditionalDocuments(e,n);let r=[];await Promise.all(e.map(e=>this.getRootFolder(e)).map(async e=>this.traverseFolder(e,r)));let i=N(r).distinct(e=>e.toString()).filter(e=>!this.langiumDocuments.hasDocument(e));return await this.loadWorkspaceDocuments(i,n),this._ready.resolve(),t}async loadWorkspaceDocuments(e,t){await Promise.all(e.map(async e=>{t(await this.langiumDocuments.getOrCreateDocument(e))}))}loadAdditionalDocuments(e,t){return Promise.resolve()}getRootFolder(e){return tM.parse(e.uri)}async traverseFolder(e,t){try{let n=await this.fileSystemProvider.readDirectory(e);await Promise.all(n.map(async e=>{this.shouldIncludeEntry(e)&&(e.isDirectory?await this.traverseFolder(e.uri,t):e.isFile&&t.push(e.uri))}))}catch(t){console.error(`Failure to read directory content of `+e.toString(!0),t)}}async searchFolder(e){let t=[];return await this.traverseFolder(e,t),t}shouldIncludeEntry(e){let t=rM.basename(e.uri);return t.startsWith(`.`)?!1:e.isDirectory?t!==`node_modules`&&t!==`out`:e.isFile?this.serviceRegistry.hasServices(e.uri):!1}},JM=class{static{o(this,`DefaultLexerErrorMessageProvider`)}buildUnexpectedCharactersMessage(e,t,n,r,i){return zy.buildUnexpectedCharactersMessage(e,t,n,r,i)}buildUnableToPopLexerModeMessage(e){return zy.buildUnableToPopLexerModeMessage(e)}},YM={mode:`full`},XM=class{static{o(this,`DefaultLexer`)}constructor(e){this.errorMessageProvider=e.parser.LexerErrorMessageProvider,this.tokenBuilder=e.parser.TokenBuilder;let t=this.tokenBuilder.buildTokens(e.Grammar,{caseInsensitive:e.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(t);let n=$M(t)?Object.values(t):t,r=e.LanguageMetaData.mode===`production`;this.chevrotainLexer=new Vy(n,{positionTracking:`full`,skipValidations:r,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(e,t=YM){let n=this.chevrotainLexer.tokenize(e);return{tokens:n.tokens,errors:n.errors,hidden:n.groups.hidden??[],report:this.tokenBuilder.flushLexingReport?.(e)}}toTokenTypeDictionary(e){if($M(e))return e;let t=QM(e)?Object.values(e.modes).flat():e,n={};return t.forEach(e=>n[e.name]=e),n}};function ZM(e){return Array.isArray(e)&&(e.length===0||`name`in e[0])}o(ZM,`isTokenTypeArray`);function QM(e){return e&&`modes`in e&&`defaultMode`in e}o(QM,`isIMultiModeLexerDefinition`);function $M(e){return!ZM(e)&&!QM(e)}o($M,`isTokenTypeDictionary`),ht();function eN(e,t,n){let r,i;typeof e==`string`?(i=t,r=n):(i=e.range.start,r=t),i||=y.create(0,0);let a=nN(e),o=vN(r);return dN({index:0,tokens:aN({lines:a,position:i,options:o}),position:i})}o(eN,`parseJSDoc`);function tN(e,t){let n=vN(t),r=nN(e);if(r.length===0)return!1;let i=r[0],a=r[r.length-1],o=n.start,s=n.end;return!!o?.exec(i)&&!!s?.exec(a)}o(tN,`isJSDoc`);function nN(e){let t=``;return t=typeof e==`string`?e:e.text,t.split(xa)}o(nN,`getLines`);var rN=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,iN=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function aN(e){let t=[],n=e.position.line,r=e.position.character;for(let i=0;i=s.length){if(t.length>0){let e=y.create(n,r);t.push({type:`break`,content:``,range:b.create(e,e)})}}else{rN.lastIndex=c;let e=rN.exec(s);if(e){let i=e[0],a=e[1],o=y.create(n,r+c),l=y.create(n,r+c+i.length);t.push({type:`tag`,content:a,range:b.create(o,l)}),c+=i.length,c=lN(s,c)}if(c0&&t[t.length-1].type===`break`?t.slice(0,-1):t}o(aN,`tokenize`);function oN(e,t,n,r){let i=[];if(e.length===0){let e=y.create(n,r),a=y.create(n,r+t.length);i.push({type:`text`,content:t,range:b.create(e,a)})}else{let a=0;for(let o of e){let e=o.index,s=t.substring(a,e);s.length>0&&i.push({type:`text`,content:t.substring(a,e),range:b.create(y.create(n,a+r),y.create(n,e+r))});let c=s.length+1,l=o[1];if(i.push({type:`inline-tag`,content:l,range:b.create(y.create(n,a+c+r),y.create(n,a+c+l.length+r))}),c+=l.length,o.length===4){c+=o[2].length;let e=o[3];i.push({type:`text`,content:e,range:b.create(y.create(n,a+c+r),y.create(n,a+c+e.length+r))})}else i.push({type:`text`,content:``,range:b.create(y.create(n,a+c+r),y.create(n,a+c+r))});a=e+o[0].length}let o=t.substring(a);o.length>0&&i.push({type:`text`,content:o,range:b.create(y.create(n,a+r),y.create(n,a+r+o.length))})}return i}o(oN,`buildInlineTokens`);var sN=/\S/,cN=/\s*$/;function lN(e,t){let n=e.substring(t).match(sN);return n?t+n.index:e.length}o(lN,`skipWhitespace`);function uN(e){let t=e.match(cN);if(t&&typeof t.index==`number`)return t.index}o(uN,`lastCharacter`);function dN(e){let t=y.create(e.position.line,e.position.character);if(e.tokens.length===0)return new bN([],b.create(t,t));let n=[];for(;e.indext.name===e)}getTags(e){return this.getAllTags().filter(t=>t.name===e)}getAllTags(){return this.elements.filter(e=>`name`in e)}toString(){let e=``;for(let t of this.elements)if(e.length===0)e=t.toString();else{let n=t.toString();e+=EN(e)+n}return e.trim()}toMarkdown(e){let t=``;for(let n of this.elements)if(t.length===0)t=n.toMarkdown(e);else{let r=n.toMarkdown(e);t+=EN(t)+r}return t.trim()}},xN=class{static{o(this,`JSDocTagImpl`)}constructor(e,t,n,r){this.name=e,this.content=t,this.inline=n,this.range=r}toString(){let e=`@${this.name}`,t=this.content.toString();return this.content.inlines.length===1?e=`${e} ${t}`:this.content.inlines.length>1&&(e=`${e} +${t}`),this.inline?`{${e}}`:e}toMarkdown(e){return e?.renderTag?.(this)??this.toMarkdownDefault(e)}toMarkdownDefault(e){let t=this.content.toMarkdown(e);if(this.inline){let n=SN(this.name,t,e??{});if(typeof n==`string`)return n}let n=``;e?.tag===`italic`||e?.tag===void 0?n=`*`:e?.tag===`bold`?n=`**`:e?.tag===`bold-italic`&&(n=`***`);let r=`${n}@${this.name}${n}`;return this.content.inlines.length===1?r=`${r} \u2014 ${t}`:this.content.inlines.length>1&&(r=`${r} +${t}`),this.inline?`{${r}}`:r}};function SN(e,t,n){if(e===`linkplain`||e===`linkcode`||e===`link`){let r=t.indexOf(` `),i=t;if(r>0){let e=lN(t,r);i=t.substring(e),t=t.substring(0,r)}return(e===`linkcode`||e===`link`&&n.link===`code`)&&(i=`\`${i}\``),n.renderLink?.(t,i)??CN(t,i)}}o(SN,`renderInlineTag`);function CN(e,t){try{return tM.parse(e,!0),`[${t}](${e})`}catch{return e}}o(CN,`renderLinkDefault`);var wN=class{static{o(this,`JSDocTextImpl`)}constructor(e,t){this.inlines=e,this.range=t}toString(){let e=``;for(let t=0;tn.range.start.line&&(e+=` +`)}return e}toMarkdown(e){let t=``;for(let n=0;nr.range.start.line&&(t+=` +`)}return t}},TN=class{static{o(this,`JSDocLineImpl`)}constructor(e,t){this.text=e,this.range=t}toString(){return this.text}toMarkdown(){return this.text}};function EN(e){return e.endsWith(` +`)?` +`:` + +`}o(EN,`fillNewlines`);var DN=class{static{o(this,`JSDocDocumentationProvider`)}constructor(e){this.indexManager=e.shared.workspace.IndexManager,this.commentProvider=e.documentation.CommentProvider}getDocumentation(e){let t=this.commentProvider.getComment(e);if(t&&tN(t))return eN(t).toMarkdown({renderLink:o((t,n)=>this.documentationLinkRenderer(e,t,n),`renderLink`),renderTag:o(t=>this.documentationTagRenderer(e,t),`renderTag`)})}documentationLinkRenderer(e,t,n){let r=this.findNameInLocalSymbols(e,t)??this.findNameInGlobalScope(e,t);if(r&&r.nameSegment){let e=r.nameSegment.range.start.line+1,t=r.nameSegment.range.start.character+1;return`[${n}](${r.documentUri.with({fragment:`L${e},${t}`}).toString()})`}}documentationTagRenderer(e,t){}findNameInLocalSymbols(e,t){let n=Dn(e).localSymbols;if(!n)return;let r=e;do{let e=n.getStream(r).find(e=>e.name===t);if(e)return e;r=r.$container}while(r)}findNameInGlobalScope(e,t){return this.indexManager.allElements().find(e=>e.name===t)}},ON=class{static{o(this,`DefaultCommentProvider`)}constructor(e){this.grammarConfig=()=>e.parser.GrammarConfig}getComment(e){return TM(e)?e.$comment:Ki(e.$cstNode,this.grammarConfig().multilineCommentRules)?.text}},kN=class{static{o(this,`DefaultAsyncParser`)}constructor(e){this.syncParser=e.parser.LangiumParser}parse(e,t){return Promise.resolve(this.syncParser.parse(e))}},AN=class{static{o(this,`AbstractThreadedAsyncParser`)}constructor(e){this.threadCount=8,this.terminationDelay=200,this.workerPool=[],this.queue=[],this.hydrator=e.serializer.Hydrator}initializeWorkers(){for(;this.workerPool.length{if(this.queue.length>0){let t=this.queue.shift();t&&(e.lock(),t.resolve(e))}}),this.workerPool.push(e)}}async parse(e,t){let n=await this.acquireParserWorker(t),r=new Kj,i,a=t.onCancellationRequested(()=>{i=setTimeout(()=>{this.terminateWorker(n)},this.terminationDelay)});return n.parse(e).then(e=>{let t=this.hydrator.hydrate(e);r.resolve(t)}).catch(e=>{r.reject(e)}).finally(()=>{a.dispose(),clearTimeout(i)}),r.promise}terminateWorker(e){e.terminate();let t=this.workerPool.indexOf(e);t>=0&&this.workerPool.splice(t,1)}async acquireParserWorker(e){this.initializeWorkers();for(let e of this.workerPool)if(e.ready)return e.lock(),e;let t=new Kj;return e.onCancellationRequested(()=>{let e=this.queue.indexOf(t);e>=0&&this.queue.splice(e,1),t.reject(Uj)}),this.queue.push(t),t.promise}},jN=class{static{o(this,`ParserWorker`)}get ready(){return this._ready}get onReady(){return this.onReadyEmitter.event}constructor(e,t,n,r){this.onReadyEmitter=new VM.Emitter,this.deferred=new Kj,this._ready=!0,this._parsing=!1,this.sendMessage=e,this._terminate=r,t(e=>{let t=e;this.deferred.resolve(t),this.unlock()}),n(e=>{this.deferred.reject(e),this.unlock()})}terminate(){this.deferred.reject(Uj),this._terminate()}lock(){this._ready=!1}unlock(){this._parsing=!1,this._ready=!0,this.onReadyEmitter.fire()}parse(e){if(this._parsing)throw Error(`Parser worker is busy`);return this._parsing=!0,this.deferred=new Kj,this.sendMessage(e),this.deferred.promise}},MN=class{static{o(this,`DefaultWorkspaceLock`)}constructor(){this.previousTokenSource=new Z.CancellationTokenSource,this.writeQueue=[],this.readQueue=[],this.done=!0}write(e){this.cancelWrite();let t=Vj();return this.previousTokenSource=t,this.enqueue(this.writeQueue,e,t.token)}read(e){return this.enqueue(this.readQueue,e)}enqueue(e,t,n=Z.CancellationToken.None){let r=new Kj,i={action:t,deferred:r,cancellationToken:n};return e.push(i),this.performNextOperation(),r.promise}async performNextOperation(){if(!this.done)return;let e=[];if(this.writeQueue.length>0)e.push(this.writeQueue.shift());else if(this.readQueue.length>0)e.push(...this.readQueue.splice(0,this.readQueue.length));else return;this.done=!1,await Promise.all(e.map(async({action:e,deferred:t,cancellationToken:n})=>{try{let r=await Promise.resolve().then(()=>e(n));t.resolve(r)}catch(e){Wj(e)?t.resolve(void 0):t.reject(e)}})),this.done=!0,this.performNextOperation()}cancelWrite(){this.previousTokenSource.cancel()}},NN=class{static{o(this,`DefaultHydrator`)}constructor(e){this.grammarElementIdMap=new pM,this.tokenTypeIdMap=new pM,this.grammar=e.Grammar,this.lexer=e.parser.Lexer,this.linker=e.references.Linker}dehydrate(e){return{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport?this.dehydrateLexerReport(e.lexerReport):void 0,parserErrors:e.parserErrors.map(e=>({...e,message:e.message})),value:this.dehydrateAstNode(e.value,this.createDehyrationContext(e.value))}}dehydrateLexerReport(e){return e}createDehyrationContext(e){let t=new Map,n=new Map;for(let n of Mn(e))t.set(n,{});if(e.$cstNode)for(let t of Ii(e.$cstNode))n.set(t,{});return{astNodes:t,cstNodes:n}}dehydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode!==void 0&&(n.$cstNode=this.dehydrateCstNode(e.$cstNode,t));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`)){if(Array.isArray(i)){let e=[];n[r]=e;for(let n of i)M(n)?e.push(this.dehydrateAstNode(n,t)):cn(n)?e.push(this.dehydrateReference(n,t)):e.push(n)}else M(i)?n[r]=this.dehydrateAstNode(i,t):cn(i)?n[r]=this.dehydrateReference(i,t):i!==void 0&&(n[r]=i)}return n}dehydrateReference(e,t){let n={};return n.$refText=e.$refText,e.$refNode&&(n.$refNode=t.cstNodes.get(e.$refNode)),n}dehydrateCstNode(e,t){let n=t.cstNodes.get(e);return hn(e)?n.fullText=e.fullText:n.grammarSource=this.getGrammarElementId(e.grammarSource),n.hidden=e.hidden,n.astNode=t.astNodes.get(e.astNode),pn(e)?n.content=e.content.map(e=>this.dehydrateCstNode(e,t)):mn(e)&&(n.tokenType=e.tokenType.name,n.offset=e.offset,n.length=e.length,n.startLine=e.range.start.line,n.startColumn=e.range.start.character,n.endLine=e.range.end.line,n.endColumn=e.range.end.character),n}hydrate(e){let t=e.value,n=this.createHydrationContext(t);return`$cstNode`in t&&this.hydrateCstNode(t.$cstNode,n),{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport,parserErrors:e.parserErrors,value:this.hydrateAstNode(t,n)}}createHydrationContext(e){let t=new Map,n=new Map;for(let n of Mn(e))t.set(n,{});let r;if(e.$cstNode)for(let t of Ii(e.$cstNode)){let e;`fullText`in t?(e=new tj(t.fullText),r=e):`content`in t?e=new $A:`tokenType`in t&&(e=this.hydrateCstLeafNode(t)),e&&(n.set(t,e),e.root=r)}return{astNodes:t,cstNodes:n}}hydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode&&(n.$cstNode=t.cstNodes.get(e.$cstNode));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`)){if(Array.isArray(i)){let e=[];n[r]=e;for(let a of i)M(a)?e.push(this.setParent(this.hydrateAstNode(a,t),n)):cn(a)?e.push(this.hydrateReference(a,n,r,t)):e.push(a)}else M(i)?n[r]=this.setParent(this.hydrateAstNode(i,t),n):cn(i)?n[r]=this.hydrateReference(i,n,r,t):i!==void 0&&(n[r]=i)}return n}setParent(e,t){return e.$container=t,e}hydrateReference(e,t,n,r){return this.linker.buildReference(t,n,r.cstNodes.get(e.$refNode),e.$refText)}hydrateCstNode(e,t,n=0){let r=t.cstNodes.get(e);if(typeof e.grammarSource==`number`&&(r.grammarSource=this.getGrammarElement(e.grammarSource)),r.astNode=t.astNodes.get(e.astNode),pn(r))for(let i of e.content){let e=this.hydrateCstNode(i,t,n++);r.content.push(e)}return r}hydrateCstLeafNode(e){let t=this.getTokenType(e.tokenType),n=e.offset,r=e.length,i=e.startLine,a=e.startColumn,o=e.endLine,s=e.endColumn,c=e.hidden;return new QA(n,r,{start:{line:i,character:a},end:{line:o,character:s}},t,c)}getTokenType(e){return this.lexer.definition[e]}getGrammarElementId(e){if(e)return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.get(e)}getGrammarElement(e){return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.getKey(e)}createGrammarElementIdMap(){let e=0;for(let t of Mn(this.grammar))Vn(t)&&this.grammarElementIdMap.set(t,e++)}};function PN(e){return{documentation:{CommentProvider:o(e=>new ON(e),`CommentProvider`),DocumentationProvider:o(e=>new DN(e),`DocumentationProvider`)},parser:{AsyncParser:o(e=>new kN(e),`AsyncParser`),GrammarConfig:o(e=>_o(e),`GrammarConfig`),LangiumParser:o(e=>Nj(e),`LangiumParser`),CompletionParser:o(e=>Mj(e),`CompletionParser`),ValueConverter:o(()=>new Ij,`ValueConverter`),TokenBuilder:o(()=>new Fj,`TokenBuilder`),Lexer:o(e=>new XM(e),`Lexer`),ParserErrorMessageProvider:o(()=>new lj,`ParserErrorMessageProvider`),LexerErrorMessageProvider:o(()=>new JM,`LexerErrorMessageProvider`)},workspace:{AstNodeLocator:o(()=>new BM,`AstNodeLocator`),AstNodeDescriptionProvider:o(e=>new RM(e),`AstNodeDescriptionProvider`),ReferenceDescriptionProvider:o(e=>new zM(e),`ReferenceDescriptionProvider`)},references:{Linker:o(e=>new cM(e),`Linker`),NameProvider:o(()=>new uM,`NameProvider`),ScopeProvider:o(e=>new wM(e),`ScopeProvider`),ScopeComputation:o(e=>new mM(e),`ScopeComputation`),References:o(e=>new dM(e),`References`)},serializer:{Hydrator:o(e=>new NN(e),`Hydrator`),JsonSerializer:o(e=>new DM(e),`JsonSerializer`)},validation:{DocumentValidator:o(e=>new NM(e),`DocumentValidator`),ValidationRegistry:o(e=>new jM(e),`ValidationRegistry`)},shared:o(()=>e.shared,`shared`)}}o(PN,`createDefaultCoreModule`);function FN(e){return{ServiceRegistry:o(e=>new OM(e),`ServiceRegistry`),workspace:{LangiumDocuments:o(e=>new oM(e),`LangiumDocuments`),LangiumDocumentFactory:o(e=>new aM(e),`LangiumDocumentFactory`),DocumentBuilder:o(e=>new GM(e),`DocumentBuilder`),IndexManager:o(e=>new KM(e),`IndexManager`),WorkspaceManager:o(e=>new qM(e),`WorkspaceManager`),FileSystemProvider:o(t=>e.fileSystemProvider(t),`FileSystemProvider`),WorkspaceLock:o(()=>new MN,`WorkspaceLock`),ConfigurationProvider:o(e=>new HM(e),`ConfigurationProvider`)},profilers:{}}}o(FN,`createDefaultSharedCoreModule`);var IN;(function(e){e.merge=(e,t)=>UN(UN({},e),t)})(IN||={});function LN(e,t,n,r,i,a,o,s,c){return BN([e,t,n,r,i,a,o,s,c].reduce(UN,{}))}o(LN,`inject`);var RN=Symbol(`isProxy`);function zN(e){if(e&&e[RN])for(let t of Object.values(e))zN(t);return e}o(zN,`eagerLoad`);function BN(e,t){let n=new Proxy({},{deleteProperty:o(()=>!1,`deleteProperty`),set:o(()=>{throw Error(`Cannot set property on injected service container`)},`set`),get:o((r,i)=>i===RN||HN(r,i,e,t||n),`get`),getOwnPropertyDescriptor:o((r,i)=>(HN(r,i,e,t||n),Object.getOwnPropertyDescriptor(r,i)),`getOwnPropertyDescriptor`),has:o((t,n)=>n in e,`has`),ownKeys:o(()=>[...Object.getOwnPropertyNames(e)],`ownKeys`)});return n}o(BN,`_inject`);var VN=Symbol();function HN(e,t,n,r){if(t in e){if(e[t]instanceof Error)throw Error(`Construction failure. Please make sure that your dependencies are constructable. Cause: `+e[t]);if(e[t]===VN)throw Error(`Cycle detected. Please make "`+String(t)+`" lazy. Visit https://langium.org/docs/reference/configuration-services/#resolving-cyclic-dependencies`);return e[t]}if(t in n){let i=n[t];e[t]=VN;try{e[t]=typeof i==`function`?i(r):BN(i,r)}catch(n){throw e[t]=n instanceof Error?n:void 0,n}return e[t]}}o(HN,`_resolve`);function UN(e,t){if(t){for(let[n,r]of Object.entries(t))if(r!=null){if(typeof r==`object`){let t=e[n];e[n]=UN(typeof t==`object`&&t?t:{},r)}else e[n]=r}}return e}o(UN,`_merge`);var WN={indentTokenName:`INDENT`,dedentTokenName:`DEDENT`,whitespaceTokenName:`WS`,ignoreIndentationDelimiters:[]},GN;(function(e){e.REGULAR=`indentation-sensitive`,e.IGNORE_INDENTATION=`ignore-indentation`})(GN||={});var KN=class extends Fj{static{o(this,`IndentationAwareTokenBuilder`)}constructor(e=WN){super(),this.indentationStack=[0],this.whitespaceRegExp=/[ \t]+/y,this.options={...WN,...e},this.indentTokenType=$y({name:this.options.indentTokenName,pattern:this.indentMatcher.bind(this),line_breaks:!1}),this.dedentTokenType=$y({name:this.options.dedentTokenName,pattern:this.dedentMatcher.bind(this),line_breaks:!1})}buildTokens(e,t){let n=super.buildTokens(e,t);if(!ZM(n))throw Error(`Invalid tokens built by default builder`);let{indentTokenName:r,dedentTokenName:i,whitespaceTokenName:a,ignoreIndentationDelimiters:o}=this.options,s,c,l,u=[];for(let e of n){for(let[t,n]of o)e.name===t?e.PUSH_MODE=GN.IGNORE_INDENTATION:e.name===n&&(e.POP_MODE=!0);e.name===i?s=e:e.name===r?c=e:e.name===a?l=e:u.push(e)}if(!s||!c||!l)throw Error(`Some indentation/whitespace tokens not found!`);return o.length>0?{modes:{[GN.REGULAR]:[s,c,...u,l],[GN.IGNORE_INDENTATION]:[...u,l]},defaultMode:GN.REGULAR}:[s,c,l,...u]}flushLexingReport(e){return{...super.flushLexingReport(e),remainingDedents:this.flushRemainingDedents(e)}}isStartOfLine(e,t){return t===0||`\r +`.includes(e[t-1])}matchWhitespace(e,t,n,r){this.whitespaceRegExp.lastIndex=t;let i=this.whitespaceRegExp.exec(e);return{currIndentLevel:i?.[0].length??0,prevIndentLevel:this.indentationStack.at(-1),match:i}}createIndentationTokenInstance(e,t,n,r){let i=this.getLineNumber(t,r);return nb(e,n,r,r+n.length,i,i,1,n.length)}getLineNumber(e,t){return e.substring(0,t).split(/\r\n|\r|\n/).length}indentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);return i<=a?null:(this.indentationStack.push(i),o)}dedentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);if(i>=a)return null;let s=this.indentationStack.lastIndexOf(i);if(s===-1)return this.diagnostics.push({severity:`error`,message:`Invalid dedent level ${i} at offset: ${t}. Current indentation stack: ${this.indentationStack}`,offset:t,length:o?.[0]?.length??0,line:this.getLineNumber(e,t),column:1}),null;let c=this.indentationStack.length-s-1,l=e.substring(0,t).match(/[\r\n]+$/)?.[0].length??1;for(let r=0;r1;)t.push(this.createIndentationTokenInstance(this.dedentTokenType,e,``,e.length)),this.indentationStack.pop();return this.indentationStack=[0],t}},qN=class extends XM{static{o(this,`IndentationAwareLexer`)}constructor(e){if(super(e),e.parser.TokenBuilder instanceof KN)this.indentationTokenBuilder=e.parser.TokenBuilder;else throw Error(`IndentationAwareLexer requires an accompanying IndentationAwareTokenBuilder`)}tokenize(e,t=YM){let n=super.tokenize(e),r=n.report;t?.mode===`full`&&n.tokens.push(...r.remainingDedents),r.remainingDedents=[];let{indentTokenType:i,dedentTokenType:a}=this.indentationTokenBuilder,o=i.tokenTypeIdx,s=a.tokenTypeIdx,c=[],l=n.tokens.length-1;for(let e=0;e=0&&c.push(n.tokens[l]),n.tokens=c,n}},JN={};l(JN,{AstUtils:()=>Cn,BiMap:()=>pM,Cancellation:()=>Z,ContextCache:()=>xM,CstUtils:()=>sn,DONE_RESULT:()=>bn,Deferred:()=>Kj,Disposable:()=>WM,DisposableCache:()=>yM,DocumentCache:()=>SM,EMPTY_STREAM:()=>yn,ErrorWithLocation:()=>ia,GrammarUtils:()=>ra,MultiMap:()=>fM,OperationCancelled:()=>Uj,Reduction:()=>Sn,RegExpUtils:()=>sa,SimpleCache:()=>bM,StreamImpl:()=>gn,TreeStreamImpl:()=>xn,URI:()=>tM,UriTrie:()=>iM,UriUtils:()=>rM,WorkspaceCache:()=>CM,assertCondition:()=>oa,assertUnreachable:()=>aa,delayNextTick:()=>Rj,interruptAndCheck:()=>Gj,isOperationCancelled:()=>Wj,loadGrammarFromJson:()=>eP,setInterruptionPeriod:()=>Hj,startCancelableOperation:()=>Vj,stream:()=>N}),d(JN,VM);var YN=class{static{o(this,`EmptyFileSystemProvider`)}stat(e){throw Error(`No file system is available.`)}statSync(e){throw Error(`No file system is available.`)}async exists(){return!1}existsSync(){return!1}readBinary(){throw Error(`No file system is available.`)}readBinarySync(){throw Error(`No file system is available.`)}readFile(){throw Error(`No file system is available.`)}readFileSync(){throw Error(`No file system is available.`)}async readDirectory(){return[]}readDirectorySync(){return[]}},XN={fileSystemProvider:o(()=>new YN,`fileSystemProvider`)},ZN={Grammar:o(()=>void 0,`Grammar`),LanguageMetaData:o(()=>({caseInsensitive:!1,fileExtensions:[`.langium`],languageId:`langium`}),`LanguageMetaData`)},QN={AstReflection:o(()=>new Pi,`AstReflection`)};function $N(){let e=LN(FN(XN),QN),t=LN(PN({shared:e}),ZN);return e.ServiceRegistry.register(t),t}o($N,`createMinimalGrammarServices`);function eP(e){let t=$N(),n=t.serializer.JsonSerializer.deserialize(e);return t.shared.workspace.LangiumDocumentFactory.fromModel(n,tM.parse(`memory:/${n.name??`grammar`}.langium`)),n}o(eP,`loadGrammarFromJson`),d(on,JN);var tP=class{static{o(this,`DefaultLangiumProfiler`)}constructor(e){this.activeCategories=new Set,this.allCategories=new Set([`validating`,`parsing`,`linking`]),this.activeCategories=e??new Set(this.allCategories),this.records=new fM}isActive(e){return this.activeCategories.has(e)}start(...e){e?e.forEach(e=>this.activeCategories.add(e)):this.activeCategories=new Set(this.allCategories)}stop(...e){e?e.forEach(e=>this.activeCategories.delete(e)):this.activeCategories.clear()}createTask(e,t){if(!this.isActive(e))throw Error(`Category "${e}" is not active.`);return console.log(`Creating profiling task for '${e}.${t}'.`),new nP(t=>this.records.add(e,this.dumpRecord(e,t)),t)}dumpRecord(e,t){console.info(`Task ${e}.${t.identifier} executed in ${t.duration.toFixed(2)}ms and ended at ${t.date.toISOString()}`);let n=[];for(let e of t.entries.keys()){let r=t.entries.get(e),i=r.reduce((e,t)=>e+t);n.push({name:`${t.identifier}.${e}`,count:r.length,duration:i})}let r=t.duration-n.map(e=>e.duration).reduce((e,t)=>e+t,0);n.push({name:t.identifier,count:1,duration:r}),n.sort((e,t)=>t.duration-e.duration);function i(e){return Math.round(100*e)/100}return o(i,`Round`),console.table(n.map(e=>({Element:e.name,Count:e.count,"Self %":i(100*e.duration/t.duration),"Time (ms)":i(e.duration)}))),t}getRecords(...e){return e.length===0?this.records.values():this.records.entries().filter(t=>e.some(e=>e===t[0])).flatMap(e=>e[1])}},nP=class{static{o(this,`ProfilingTask`)}constructor(e,t){this.stack=[],this.entries=new fM,this.addRecord=e,this.identifier=t}start(){if(this.startTime!==void 0)throw Error(`Task "${this.identifier}" is already started.`);this.startTime=performance.now()}stop(){if(this.startTime===void 0)throw Error(`Task "${this.identifier}" was not started.`);if(this.stack.length!==0)throw Error(`Task "${this.identifier}" cannot be stopped before sub-task(s): ${this.stack.map(e=>e.id).join(`, `)}.`);let e={identifier:this.identifier,date:new Date,duration:performance.now()-this.startTime,entries:this.entries};this.addRecord(e),this.startTime=void 0,this.entries.clear()}startSubTask(e){this.stack.push({id:e,start:performance.now(),content:0})}stopSubTask(e){let t=this.stack.pop();if(!t)throw Error(`Task "${this.identifier}.${e}" was not started.`);if(t.id!==e)throw Error(`Sub-Task "${t.id}" is not already stopped.`);let n=performance.now()-t.start;this.stack.at(-1)!==void 0&&(this.stack[this.stack.length-1].content+=n);let r=n-t.content;this.entries.add(e,r)}},rP;(e=>{e.Terminals={ARROW_DIRECTION:/L|R|T|B/,ARROW_GROUP:/\{group\}/,ARROW_INTO:/<|>/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,ARCH_ICON:/\([\w-:]+\)/,ARCH_TITLE:/\[(?:"([^"\\]|\\.)*"|'([^'\\]|\\.)*'|[^\[\]\r\n]+)\]/}})(rP||={});var iP;(e=>{e.Terminals={DOMAIN_NAME:/complex|complicated|clear|chaotic|confusion/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(iP||={});var aP;(e=>{e.Terminals={EM_ID:/[_a-zA-Z][\w_]*/,EM_FID:/\d{1,3}/,EM_DATA_INLINE:/\{(.*)\}|"(.*)"|'(.*)'/,EM_DATA_BLOCK:/\{[\t ]*\r?\n(?:[\S\s]*?\r?\n)?\}(?:\r?\n|(?!\S))/,EM_ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,EM_ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,EM_TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,EM_WS:/\s+/,EM_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,EM_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,EM_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,EM_ML_COMMENT:/\/\*[\s\S]*?\*\//,EM_SL_COMMENT:/\/\/[^\n\r]*/}})(aP||={});var oP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,REFERENCE:/\w([-\./\w]*[-\w])?/}})(oP||={});var sP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(sP||={});var cP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(cP||={});var lP;(e=>{e.Terminals={NUMBER_PIE:/(?:-?[0-9]+\.[0-9]+(?!\.))|(?:-?(0|[1-9][0-9]*)(?!\.))/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(lP||={});var uP;(e=>{e.Terminals={GRATICULE:/circle|polygon/,BOOLEAN:/true|false/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NUMBER:/(?:[0-9]+\.[0-9]+(?!\.))|(?:0|[1-9][0-9]*(?!\.))/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(uP||={});var dP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ABNF_RULENAME:/[A-Za-z][A-Za-z0-9-]*/,ABNF_STRING:/"[^"]*"/,ABNF_NUMVAL:/%[xXdDbB][0-9A-Fa-f]+(?:-[0-9A-Fa-f]+|\.[0-9A-Fa-f]+)*/,ABNF_REPEAT:/[0-9]*\*[0-9]*/,ABNF_EXACT_REPEAT:/[0-9]+/,ABNF_WHITESPACE:/[\t \r\n]+/,ABNF_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,ABNF_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,ABNF_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,ABNF_COMMENT:/;[^\n\r]*/}})(dP||={});var fP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,EBNF_ID:/[A-Z_a-z][\w-]*/,EBNF_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,EBNF_SPECIAL_SEQUENCE:/\?(?=[^?;]*[^?\s;][^?;]*\?)[^?;]*\?/,EBNF_WHITESPACE:/[\t \r\n]+/,EBNF_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,EBNF_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,EBNF_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,EBNF_BLOCK_COMMENT:/\/\*[\s\S]*?\*\//,EBNF_ISO_COMMENT:/\(\*[\s\S]*?\*\)/}})(fP||={});var pP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,RR_ID:/[A-Z_a-z][\w-]*/,RR_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,RR_WHITESPACE:/[\t \r\n]+/,RR_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,RR_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,RR_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,RR_BLOCK_COMMENT:/\/\*[\s\S]*?\*\//}})(pP||={});var mP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,PEG_ID:/[A-Z_a-z][\w-]*/,PEG_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,PEG_WHITESPACE:/[\t \r\n]+/,PEG_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,PEG_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,PEG_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,PEG_LINE_COMMENT:/#[^\n\r]*/}})(mP||={});var hP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,TREEMAP_KEYWORD:/treemap-beta|treemap/,CLASS_DEF:/classDef\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\s+([^;\r\n]*))?(?:;)?/,STYLE_SEPARATOR:/:::/,SEPARATOR:/:/,COMMA:/,/,INDENTATION:/[ \t]{1,}/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,ID2:/[a-zA-Z_][a-zA-Z0-9_]*/,NUMBER2:/[0-9_\.\,]+/,STRING2:/"[^"]*"|'[^']*'/}})(hP||={});var gP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,CLASS_ANNOTATION:/[ \t]+:::[ \t]*[A-Za-z_][\w-]*/,ICON_ANNOTATION:/[ \t]+icon\([\w-]*(?::[\w-]+)?\)/,DESC_ANNOTATION:/[ \t]+##[^\n\r]*/,INDENTATION:/[ \t]{1,}/,QUOTED_NAME:/"[^"]*"|'[^']*'/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,BARE_NAME:/(?!:::|icon\(|##)[^ \t\n\r"'](?:(?![ \t]+:::[ \t]*[A-Za-z_]|[ \t]+icon\(|[ \t]+##)[^\n\r])*/}})(gP||={});var _P;(e=>{e.Terminals={WARDLEY_NUMBER:/[0-9]+\.[0-9]+/,ARROW:/->/,LINK_PORT:/\+<>|\+>|\+|-\.->|>|\+'[^']*'<>|\+'[^']*'<|\+'[^']*'>/,LINK_LABEL:/;[^\n\r]+/,STRATEGY:/build|buy|outsource|market/,KW_WARDLEY:/wardley-beta/,KW_SIZE:/size/,KW_EVOLUTION:/evolution/,KW_ANCHOR:/anchor/,KW_COMPONENT:/component/,KW_LABEL:/label/,KW_INERTIA:/inertia/,KW_EVOLVE:/evolve/,KW_PIPELINE:/pipeline/,KW_NOTE:/note/,KW_ANNOTATIONS:/annotations/,KW_ANNOTATION:/annotation/,KW_ACCELERATOR:/accelerator/,KW_DEACCELERATOR:/deaccelerator/,NAME_WITH_SPACES:/(?!title\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/,WS:/[ \t]+/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(_P||={}),{...rP.Terminals,...iP.Terminals,...aP.Terminals,...oP.Terminals,...sP.Terminals,...cP.Terminals,...lP.Terminals,...uP.Terminals,...dP.Terminals,...fP.Terminals,...pP.Terminals,...mP.Terminals,...gP.Terminals,...hP.Terminals,..._P.Terminals};var vP={$type:`AbnfAlternation`,alternatives:`alternatives`},yP={$type:`AbnfConcatenation`,elements:`elements`},bP={$type:`AbnfElement`,primary:`primary`,repeat:`repeat`},xP={$type:`AbnfGroup`,element:`element`},SP={$type:`AbnfNumVal`,value:`value`},CP={$type:`AbnfOptionalGroup`,element:`element`},wP={$type:`AbnfPrimary`},TP={$type:`AbnfRule`,definition:`definition`,name:`name`},EP={$type:`AbnfRuleName`,name:`name`},DP={$type:`AbnfStringLiteral`,value:`value`},OP={$type:`Accelerator`,name:`name`,x:`x`,y:`y`},kP={$type:`Alignment`,direction:`direction`,members:`members`},AP={$type:`Anchor`,evolution:`evolution`,name:`name`,visibility:`visibility`},jP={$type:`Annotation`,number:`number`,text:`text`,x:`x`,y:`y`},MP={$type:`Annotations`,x:`x`,y:`y`},NP={$type:`Architecture`,accDescr:`accDescr`,accTitle:`accTitle`,alignments:`alignments`,edges:`edges`,groups:`groups`,junctions:`junctions`,services:`services`,title:`title`};function PP(e){return $.isInstance(e,NP.$type)}o(PP,`isArchitecture`);var FP={$type:`Axis`,label:`label`,name:`name`},IP={$type:`Branch`,name:`name`,order:`order`};function LP(e){return $.isInstance(e,IP.$type)}o(LP,`isBranch`);var RP={$type:`Checkout`,branch:`branch`},zP={$type:`CherryPicking`,id:`id`,parent:`parent`,tags:`tags`},BP={$type:`ClassDefStatement`,className:`className`,styleText:`styleText`},VP={$type:`Commit`,id:`id`,message:`message`,tags:`tags`,type:`type`};function HP(e){return $.isInstance(e,VP.$type)}o(HP,`isCommit`);var UP={$type:`Common`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`},WP={$type:`Component`,decorator:`decorator`,evolution:`evolution`,inertia:`inertia`,label:`label`,name:`name`,visibility:`visibility`},GP={$type:`Curve`,entries:`entries`,label:`label`,name:`name`},KP={$type:`Cynefin`,accDescr:`accDescr`,accTitle:`accTitle`,domains:`domains`,title:`title`,transitions:`transitions`};function qP(e){return $.isInstance(e,KP.$type)}o(qP,`isCynefin`);var JP={$type:`Deaccelerator`,name:`name`,x:`x`,y:`y`},YP={$type:`Decorator`,strategy:`strategy`},XP={$type:`Direction`,accDescr:`accDescr`,accTitle:`accTitle`,dir:`dir`,statements:`statements`,title:`title`},ZP={$type:`DomainBlock`,domain:`domain`,items:`items`};function QP(e){return $.isInstance(e,ZP.$type)}o(QP,`isDomainBlock`);var $P={$type:`DomainItem`,label:`label`};function eF(e){return $.isInstance(e,$P.$type)}o(eF,`isDomainItem`);var tF={$type:`EbnfChoice`,alternatives:`alternatives`},nF={$type:`EbnfExceptionPostfix`,except:`except`},rF={$type:`EbnfGroup`,element:`element`},iF={$type:`EbnfNonTerminal`,name:`name`},aF={$type:`EbnfOneOrMorePostfix`,operator:`operator`},oF={$type:`EbnfOptional`,element:`element`},sF={$type:`EbnfOptionalPostfix`,operator:`operator`},cF={$type:`EbnfPostfix`},lF={$type:`EbnfPrimary`},uF={$type:`EbnfRepetition`,element:`element`},dF={$type:`EbnfRule`,definition:`definition`,name:`name`},fF={$type:`EbnfSequence`,elements:`elements`},pF={$type:`EbnfSpecial`,text:`text`},mF={$type:`EbnfTerm`,base:`base`,postfixes:`postfixes`},hF={$type:`EbnfTerminal`,value:`value`},gF={$type:`EbnfZeroOrMorePostfix`,operator:`operator`},_F={$type:`Edge`,lhsDir:`lhsDir`,lhsGroup:`lhsGroup`,lhsId:`lhsId`,lhsInto:`lhsInto`,rhsDir:`rhsDir`,rhsGroup:`rhsGroup`,rhsId:`rhsId`,rhsInto:`rhsInto`,title:`title`},vF={$type:`EmDataEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,name:`name`},yF={$type:`EmFrame`},bF={$type:`EmGwt`,givenStatements:`givenStatements`,sourceFrame:`sourceFrame`,thenStatements:`thenStatements`,whenStatements:`whenStatements`},xF={$type:`EmGwtStatement`,entityIdentifier:`entityIdentifier`},SF={$type:`EmModelEntity`,name:`name`};function CF(e){return e===`rmo`||e===`readmodel`||e===`ui`||e===`cmd`||e===`command`||e===`evt`||e===`event`||e===`pcr`||e===`processor`}o(CF,`isEmModelEntityType`);var wF={$type:`EmNoteEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,sourceFrame:`sourceFrame`},TF={$type:`EmResetFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`};function EF(e){return $.isInstance(e,TF.$type)}o(EF,`isEmResetFrame`);var DF={$type:`EmTimeFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`},OF={$type:`Entry`,axis:`axis`,value:`value`},kF={$type:`EventModel`,accDescr:`accDescr`,accTitle:`accTitle`,dataEntities:`dataEntities`,frames:`frames`,gwtEntities:`gwtEntities`,modelEntities:`modelEntities`,noteEntities:`noteEntities`,title:`title`},AF={$type:`Evolution`,stages:`stages`},jF={$type:`EvolutionStage`,boundary:`boundary`,name:`name`,secondName:`secondName`},MF={$type:`Evolve`,component:`component`,target:`target`},NF={$type:`GitGraph`,accDescr:`accDescr`,accTitle:`accTitle`,statements:`statements`,title:`title`};function PF(e){return $.isInstance(e,NF.$type)}o(PF,`isGitGraph`);var FF={$type:`Group`,icon:`icon`,id:`id`,in:`in`,title:`title`},IF={$type:`Info`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`};function LF(e){return $.isInstance(e,IF.$type)}o(LF,`isInfo`);var RF={$type:`Item`,classSelector:`classSelector`,name:`name`},zF={$type:`Junction`,id:`id`,in:`in`},BF={$type:`Label`,negX:`negX`,negY:`negY`,offsetX:`offsetX`,offsetY:`offsetY`},VF={$type:`Leaf`,classSelector:`classSelector`,name:`name`,value:`value`},HF={$type:`Link`,arrow:`arrow`,from:`from`,fromPort:`fromPort`,linkLabel:`linkLabel`,to:`to`,toPort:`toPort`},UF={$type:`Merge`,branch:`branch`,id:`id`,tags:`tags`,type:`type`};function WF(e){return $.isInstance(e,UF.$type)}o(WF,`isMerge`);var GF={$type:`Note`,evolution:`evolution`,text:`text`,visibility:`visibility`},KF={$type:`Option`,name:`name`,value:`value`},qF={$type:`Packet`,accDescr:`accDescr`,accTitle:`accTitle`,blocks:`blocks`,title:`title`};function JF(e){return $.isInstance(e,qF.$type)}o(JF,`isPacket`);var YF={$type:`PacketBlock`,bits:`bits`,end:`end`,label:`label`,start:`start`};function XF(e){return $.isInstance(e,YF.$type)}o(XF,`isPacketBlock`);var ZF={$type:`PegAny`,dot:`dot`},QF={$type:`PegGroup`,element:`element`},$F={$type:`PegIdentifier`,name:`name`},eI={$type:`PegLiteral`,value:`value`},tI={$type:`PegOrderedChoice`,alternatives:`alternatives`},nI={$type:`PegPrefix`,operator:`operator`,suffix:`suffix`},rI={$type:`PegPrimary`},iI={$type:`PegRule`,definition:`definition`,name:`name`},aI={$type:`PegSequence`,elements:`elements`},oI={$type:`PegSuffix`,operator:`operator`,primary:`primary`},sI={$type:`Pie`,accDescr:`accDescr`,accTitle:`accTitle`,sections:`sections`,showData:`showData`,title:`title`};function cI(e){return $.isInstance(e,sI.$type)}o(cI,`isPie`);var lI={$type:`PieSection`,label:`label`,value:`value`};function uI(e){return $.isInstance(e,lI.$type)}o(uI,`isPieSection`);var dI={$type:`Pipeline`,components:`components`,parent:`parent`},fI={$type:`PipelineComponent`,evolution:`evolution`,label:`label`,name:`name`},pI={$type:`Radar`,accDescr:`accDescr`,accTitle:`accTitle`,axes:`axes`,curves:`curves`,options:`options`,title:`title`},mI={$type:`Railroad`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function hI(e){return $.isInstance(e,mI.$type)}o(hI,`isRailroad`);var gI={$type:`RailroadAbnf`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function _I(e){return $.isInstance(e,gI.$type)}o(_I,`isRailroadAbnf`);var vI={$type:`RailroadChoiceExpr`,alternatives:`alternatives`},yI={$type:`RailroadEbnf`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function bI(e){return $.isInstance(e,yI.$type)}o(bI,`isRailroadEbnf`);var xI={$type:`RailroadExpression`},SI={$type:`RailroadNonTerminalExpr`,name:`name`},CI={$type:`RailroadOneOrMoreExpr`,element:`element`},wI={$type:`RailroadOptionalExpr`,element:`element`},TI={$type:`RailroadPeg`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function EI(e){return $.isInstance(e,TI.$type)}o(EI,`isRailroadPeg`);var DI={$type:`RailroadRule`,definition:`definition`,name:`name`},OI={$type:`RailroadSequenceExpr`,elements:`elements`},kI={$type:`RailroadSpecialExpr`,text:`text`},AI={$type:`RailroadTerminalExpr`,value:`value`},jI={$type:`RailroadZeroOrMoreExpr`,element:`element`},MI={$type:`Section`,classSelector:`classSelector`,name:`name`},NI={$type:`Service`,icon:`icon`,iconText:`iconText`,id:`id`,in:`in`,title:`title`},PI={$type:`Size`,height:`height`,width:`width`},FI={$type:`Statement`},II={$type:`Transition`,from:`from`,label:`label`,to:`to`};function LI(e){return $.isInstance(e,II.$type)}o(LI,`isTransition`);var RI={$type:`Treemap`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`,TreemapRows:`TreemapRows`};function zI(e){return $.isInstance(e,RI.$type)}o(zI,`isTreemap`);var BI={$type:`TreemapRow`,indent:`indent`,item:`item`},VI={$type:`TreeNode`,classAnnotation:`classAnnotation`,descAnnotation:`descAnnotation`,iconAnnotation:`iconAnnotation`,indent:`indent`,name:`name`},HI={$type:`TreeView`,accDescr:`accDescr`,accTitle:`accTitle`,nodes:`nodes`,title:`title`},UI={$type:`Wardley`,accDescr:`accDescr`,accelerators:`accelerators`,accTitle:`accTitle`,anchors:`anchors`,annotation:`annotation`,annotations:`annotations`,components:`components`,deaccelerators:`deaccelerators`,evolution:`evolution`,evolves:`evolves`,links:`links`,notes:`notes`,pipelines:`pipelines`,size:`size`,title:`title`};function WI(e){return $.isInstance(e,UI.$type)}o(WI,`isWardley`);var GI=class extends fn{constructor(){super(...arguments),this.types={AbnfAlternation:{name:vP.$type,properties:{alternatives:{name:vP.alternatives,defaultValue:[]}},superTypes:[]},AbnfConcatenation:{name:yP.$type,properties:{elements:{name:yP.elements,defaultValue:[]}},superTypes:[]},AbnfElement:{name:bP.$type,properties:{primary:{name:bP.primary},repeat:{name:bP.repeat}},superTypes:[]},AbnfGroup:{name:xP.$type,properties:{element:{name:xP.element}},superTypes:[wP.$type]},AbnfNumVal:{name:SP.$type,properties:{value:{name:SP.value}},superTypes:[wP.$type]},AbnfOptionalGroup:{name:CP.$type,properties:{element:{name:CP.element}},superTypes:[wP.$type]},AbnfPrimary:{name:wP.$type,properties:{},superTypes:[]},AbnfRule:{name:TP.$type,properties:{definition:{name:TP.definition},name:{name:TP.name}},superTypes:[]},AbnfRuleName:{name:EP.$type,properties:{name:{name:EP.name}},superTypes:[wP.$type]},AbnfStringLiteral:{name:DP.$type,properties:{value:{name:DP.value}},superTypes:[wP.$type]},Accelerator:{name:OP.$type,properties:{name:{name:OP.name},x:{name:OP.x},y:{name:OP.y}},superTypes:[]},Alignment:{name:kP.$type,properties:{direction:{name:kP.direction},members:{name:kP.members,defaultValue:[]}},superTypes:[]},Anchor:{name:AP.$type,properties:{evolution:{name:AP.evolution},name:{name:AP.name},visibility:{name:AP.visibility}},superTypes:[]},Annotation:{name:jP.$type,properties:{number:{name:jP.number},text:{name:jP.text},x:{name:jP.x},y:{name:jP.y}},superTypes:[]},Annotations:{name:MP.$type,properties:{x:{name:MP.x},y:{name:MP.y}},superTypes:[]},Architecture:{name:NP.$type,properties:{accDescr:{name:NP.accDescr},accTitle:{name:NP.accTitle},alignments:{name:NP.alignments,defaultValue:[]},edges:{name:NP.edges,defaultValue:[]},groups:{name:NP.groups,defaultValue:[]},junctions:{name:NP.junctions,defaultValue:[]},services:{name:NP.services,defaultValue:[]},title:{name:NP.title}},superTypes:[]},Axis:{name:FP.$type,properties:{label:{name:FP.label},name:{name:FP.name}},superTypes:[]},Branch:{name:IP.$type,properties:{name:{name:IP.name},order:{name:IP.order}},superTypes:[FI.$type]},Checkout:{name:RP.$type,properties:{branch:{name:RP.branch}},superTypes:[FI.$type]},CherryPicking:{name:zP.$type,properties:{id:{name:zP.id},parent:{name:zP.parent},tags:{name:zP.tags,defaultValue:[]}},superTypes:[FI.$type]},ClassDefStatement:{name:BP.$type,properties:{className:{name:BP.className},styleText:{name:BP.styleText}},superTypes:[]},Commit:{name:VP.$type,properties:{id:{name:VP.id},message:{name:VP.message},tags:{name:VP.tags,defaultValue:[]},type:{name:VP.type}},superTypes:[FI.$type]},Common:{name:UP.$type,properties:{accDescr:{name:UP.accDescr},accTitle:{name:UP.accTitle},title:{name:UP.title}},superTypes:[]},Component:{name:WP.$type,properties:{decorator:{name:WP.decorator},evolution:{name:WP.evolution},inertia:{name:WP.inertia,defaultValue:!1},label:{name:WP.label},name:{name:WP.name},visibility:{name:WP.visibility}},superTypes:[]},Curve:{name:GP.$type,properties:{entries:{name:GP.entries,defaultValue:[]},label:{name:GP.label},name:{name:GP.name}},superTypes:[]},Cynefin:{name:KP.$type,properties:{accDescr:{name:KP.accDescr},accTitle:{name:KP.accTitle},domains:{name:KP.domains,defaultValue:[]},title:{name:KP.title},transitions:{name:KP.transitions,defaultValue:[]}},superTypes:[]},Deaccelerator:{name:JP.$type,properties:{name:{name:JP.name},x:{name:JP.x},y:{name:JP.y}},superTypes:[]},Decorator:{name:YP.$type,properties:{strategy:{name:YP.strategy}},superTypes:[]},Direction:{name:XP.$type,properties:{accDescr:{name:XP.accDescr},accTitle:{name:XP.accTitle},dir:{name:XP.dir},statements:{name:XP.statements,defaultValue:[]},title:{name:XP.title}},superTypes:[NF.$type]},DomainBlock:{name:ZP.$type,properties:{domain:{name:ZP.domain},items:{name:ZP.items,defaultValue:[]}},superTypes:[]},DomainItem:{name:$P.$type,properties:{label:{name:$P.label}},superTypes:[]},EbnfChoice:{name:tF.$type,properties:{alternatives:{name:tF.alternatives,defaultValue:[]}},superTypes:[]},EbnfExceptionPostfix:{name:nF.$type,properties:{except:{name:nF.except}},superTypes:[cF.$type]},EbnfGroup:{name:rF.$type,properties:{element:{name:rF.element}},superTypes:[lF.$type]},EbnfNonTerminal:{name:iF.$type,properties:{name:{name:iF.name}},superTypes:[lF.$type]},EbnfOneOrMorePostfix:{name:aF.$type,properties:{operator:{name:aF.operator}},superTypes:[cF.$type]},EbnfOptional:{name:oF.$type,properties:{element:{name:oF.element}},superTypes:[lF.$type]},EbnfOptionalPostfix:{name:sF.$type,properties:{operator:{name:sF.operator}},superTypes:[cF.$type]},EbnfPostfix:{name:cF.$type,properties:{},superTypes:[]},EbnfPrimary:{name:lF.$type,properties:{},superTypes:[]},EbnfRepetition:{name:uF.$type,properties:{element:{name:uF.element}},superTypes:[lF.$type]},EbnfRule:{name:dF.$type,properties:{definition:{name:dF.definition},name:{name:dF.name}},superTypes:[]},EbnfSequence:{name:fF.$type,properties:{elements:{name:fF.elements,defaultValue:[]}},superTypes:[]},EbnfSpecial:{name:pF.$type,properties:{text:{name:pF.text}},superTypes:[lF.$type]},EbnfTerm:{name:mF.$type,properties:{base:{name:mF.base},postfixes:{name:mF.postfixes,defaultValue:[]}},superTypes:[]},EbnfTerminal:{name:hF.$type,properties:{value:{name:hF.value}},superTypes:[lF.$type]},EbnfZeroOrMorePostfix:{name:gF.$type,properties:{operator:{name:gF.operator}},superTypes:[cF.$type]},Edge:{name:_F.$type,properties:{lhsDir:{name:_F.lhsDir},lhsGroup:{name:_F.lhsGroup,defaultValue:!1},lhsId:{name:_F.lhsId},lhsInto:{name:_F.lhsInto,defaultValue:!1},rhsDir:{name:_F.rhsDir},rhsGroup:{name:_F.rhsGroup,defaultValue:!1},rhsId:{name:_F.rhsId},rhsInto:{name:_F.rhsInto,defaultValue:!1},title:{name:_F.title}},superTypes:[]},EmDataEntity:{name:vF.$type,properties:{dataBlockValue:{name:vF.dataBlockValue},dataType:{name:vF.dataType},name:{name:vF.name}},superTypes:[]},EmFrame:{name:yF.$type,properties:{},superTypes:[]},EmGwt:{name:bF.$type,properties:{givenStatements:{name:bF.givenStatements,defaultValue:[]},sourceFrame:{name:bF.sourceFrame,referenceType:yF.$type},thenStatements:{name:bF.thenStatements,defaultValue:[]},whenStatements:{name:bF.whenStatements,defaultValue:[]}},superTypes:[]},EmGwtStatement:{name:xF.$type,properties:{entityIdentifier:{name:xF.entityIdentifier,referenceType:SF.$type}},superTypes:[]},EmModelEntity:{name:SF.$type,properties:{name:{name:SF.name}},superTypes:[]},EmNoteEntity:{name:wF.$type,properties:{dataBlockValue:{name:wF.dataBlockValue},dataType:{name:wF.dataType},sourceFrame:{name:wF.sourceFrame,referenceType:yF.$type}},superTypes:[]},EmResetFrame:{name:TF.$type,properties:{dataInlineValue:{name:TF.dataInlineValue},dataReference:{name:TF.dataReference,referenceType:vF.$type},dataType:{name:TF.dataType},entityIdentifier:{name:TF.entityIdentifier},modelEntityType:{name:TF.modelEntityType},name:{name:TF.name},sourceFrames:{name:TF.sourceFrames,defaultValue:[],referenceType:yF.$type}},superTypes:[yF.$type]},EmTimeFrame:{name:DF.$type,properties:{dataInlineValue:{name:DF.dataInlineValue},dataReference:{name:DF.dataReference,referenceType:vF.$type},dataType:{name:DF.dataType},entityIdentifier:{name:DF.entityIdentifier},modelEntityType:{name:DF.modelEntityType},name:{name:DF.name},sourceFrames:{name:DF.sourceFrames,defaultValue:[],referenceType:yF.$type}},superTypes:[yF.$type]},Entry:{name:OF.$type,properties:{axis:{name:OF.axis,referenceType:FP.$type},value:{name:OF.value}},superTypes:[]},EventModel:{name:kF.$type,properties:{accDescr:{name:kF.accDescr},accTitle:{name:kF.accTitle},dataEntities:{name:kF.dataEntities,defaultValue:[]},frames:{name:kF.frames,defaultValue:[]},gwtEntities:{name:kF.gwtEntities,defaultValue:[]},modelEntities:{name:kF.modelEntities,defaultValue:[]},noteEntities:{name:kF.noteEntities,defaultValue:[]},title:{name:kF.title}},superTypes:[]},Evolution:{name:AF.$type,properties:{stages:{name:AF.stages,defaultValue:[]}},superTypes:[]},EvolutionStage:{name:jF.$type,properties:{boundary:{name:jF.boundary},name:{name:jF.name},secondName:{name:jF.secondName}},superTypes:[]},Evolve:{name:MF.$type,properties:{component:{name:MF.component},target:{name:MF.target}},superTypes:[]},GitGraph:{name:NF.$type,properties:{accDescr:{name:NF.accDescr},accTitle:{name:NF.accTitle},statements:{name:NF.statements,defaultValue:[]},title:{name:NF.title}},superTypes:[]},Group:{name:FF.$type,properties:{icon:{name:FF.icon},id:{name:FF.id},in:{name:FF.in},title:{name:FF.title}},superTypes:[]},Info:{name:IF.$type,properties:{accDescr:{name:IF.accDescr},accTitle:{name:IF.accTitle},title:{name:IF.title}},superTypes:[]},Item:{name:RF.$type,properties:{classSelector:{name:RF.classSelector},name:{name:RF.name}},superTypes:[]},Junction:{name:zF.$type,properties:{id:{name:zF.id},in:{name:zF.in}},superTypes:[]},Label:{name:BF.$type,properties:{negX:{name:BF.negX,defaultValue:!1},negY:{name:BF.negY,defaultValue:!1},offsetX:{name:BF.offsetX},offsetY:{name:BF.offsetY}},superTypes:[]},Leaf:{name:VF.$type,properties:{classSelector:{name:VF.classSelector},name:{name:VF.name},value:{name:VF.value}},superTypes:[RF.$type]},Link:{name:HF.$type,properties:{arrow:{name:HF.arrow},from:{name:HF.from},fromPort:{name:HF.fromPort},linkLabel:{name:HF.linkLabel},to:{name:HF.to},toPort:{name:HF.toPort}},superTypes:[]},Merge:{name:UF.$type,properties:{branch:{name:UF.branch},id:{name:UF.id},tags:{name:UF.tags,defaultValue:[]},type:{name:UF.type}},superTypes:[FI.$type]},Note:{name:GF.$type,properties:{evolution:{name:GF.evolution},text:{name:GF.text},visibility:{name:GF.visibility}},superTypes:[]},Option:{name:KF.$type,properties:{name:{name:KF.name},value:{name:KF.value,defaultValue:!1}},superTypes:[]},Packet:{name:qF.$type,properties:{accDescr:{name:qF.accDescr},accTitle:{name:qF.accTitle},blocks:{name:qF.blocks,defaultValue:[]},title:{name:qF.title}},superTypes:[]},PacketBlock:{name:YF.$type,properties:{bits:{name:YF.bits},end:{name:YF.end},label:{name:YF.label},start:{name:YF.start}},superTypes:[]},PegAny:{name:ZF.$type,properties:{dot:{name:ZF.dot}},superTypes:[rI.$type]},PegGroup:{name:QF.$type,properties:{element:{name:QF.element}},superTypes:[rI.$type]},PegIdentifier:{name:$F.$type,properties:{name:{name:$F.name}},superTypes:[rI.$type]},PegLiteral:{name:eI.$type,properties:{value:{name:eI.value}},superTypes:[rI.$type]},PegOrderedChoice:{name:tI.$type,properties:{alternatives:{name:tI.alternatives,defaultValue:[]}},superTypes:[]},PegPrefix:{name:nI.$type,properties:{operator:{name:nI.operator},suffix:{name:nI.suffix}},superTypes:[]},PegPrimary:{name:rI.$type,properties:{},superTypes:[]},PegRule:{name:iI.$type,properties:{definition:{name:iI.definition},name:{name:iI.name}},superTypes:[]},PegSequence:{name:aI.$type,properties:{elements:{name:aI.elements,defaultValue:[]}},superTypes:[]},PegSuffix:{name:oI.$type,properties:{operator:{name:oI.operator},primary:{name:oI.primary}},superTypes:[]},Pie:{name:sI.$type,properties:{accDescr:{name:sI.accDescr},accTitle:{name:sI.accTitle},sections:{name:sI.sections,defaultValue:[]},showData:{name:sI.showData,defaultValue:!1},title:{name:sI.title}},superTypes:[]},PieSection:{name:lI.$type,properties:{label:{name:lI.label},value:{name:lI.value}},superTypes:[]},Pipeline:{name:dI.$type,properties:{components:{name:dI.components,defaultValue:[]},parent:{name:dI.parent}},superTypes:[]},PipelineComponent:{name:fI.$type,properties:{evolution:{name:fI.evolution},label:{name:fI.label},name:{name:fI.name}},superTypes:[]},Radar:{name:pI.$type,properties:{accDescr:{name:pI.accDescr},accTitle:{name:pI.accTitle},axes:{name:pI.axes,defaultValue:[]},curves:{name:pI.curves,defaultValue:[]},options:{name:pI.options,defaultValue:[]},title:{name:pI.title}},superTypes:[]},Railroad:{name:mI.$type,properties:{accDescr:{name:mI.accDescr},accTitle:{name:mI.accTitle},rules:{name:mI.rules,defaultValue:[]},title:{name:mI.title}},superTypes:[]},RailroadAbnf:{name:gI.$type,properties:{accDescr:{name:gI.accDescr},accTitle:{name:gI.accTitle},rules:{name:gI.rules,defaultValue:[]},title:{name:gI.title}},superTypes:[]},RailroadChoiceExpr:{name:vI.$type,properties:{alternatives:{name:vI.alternatives,defaultValue:[]}},superTypes:[xI.$type]},RailroadEbnf:{name:yI.$type,properties:{accDescr:{name:yI.accDescr},accTitle:{name:yI.accTitle},rules:{name:yI.rules,defaultValue:[]},title:{name:yI.title}},superTypes:[]},RailroadExpression:{name:xI.$type,properties:{},superTypes:[]},RailroadNonTerminalExpr:{name:SI.$type,properties:{name:{name:SI.name}},superTypes:[xI.$type]},RailroadOneOrMoreExpr:{name:CI.$type,properties:{element:{name:CI.element}},superTypes:[xI.$type]},RailroadOptionalExpr:{name:wI.$type,properties:{element:{name:wI.element}},superTypes:[xI.$type]},RailroadPeg:{name:TI.$type,properties:{accDescr:{name:TI.accDescr},accTitle:{name:TI.accTitle},rules:{name:TI.rules,defaultValue:[]},title:{name:TI.title}},superTypes:[]},RailroadRule:{name:DI.$type,properties:{definition:{name:DI.definition},name:{name:DI.name}},superTypes:[]},RailroadSequenceExpr:{name:OI.$type,properties:{elements:{name:OI.elements,defaultValue:[]}},superTypes:[xI.$type]},RailroadSpecialExpr:{name:kI.$type,properties:{text:{name:kI.text}},superTypes:[xI.$type]},RailroadTerminalExpr:{name:AI.$type,properties:{value:{name:AI.value}},superTypes:[xI.$type]},RailroadZeroOrMoreExpr:{name:jI.$type,properties:{element:{name:jI.element}},superTypes:[xI.$type]},Section:{name:MI.$type,properties:{classSelector:{name:MI.classSelector},name:{name:MI.name}},superTypes:[RF.$type]},Service:{name:NI.$type,properties:{icon:{name:NI.icon},iconText:{name:NI.iconText},id:{name:NI.id},in:{name:NI.in},title:{name:NI.title}},superTypes:[]},Size:{name:PI.$type,properties:{height:{name:PI.height},width:{name:PI.width}},superTypes:[]},Statement:{name:FI.$type,properties:{},superTypes:[]},Transition:{name:II.$type,properties:{from:{name:II.from},label:{name:II.label},to:{name:II.to}},superTypes:[]},TreeNode:{name:VI.$type,properties:{classAnnotation:{name:VI.classAnnotation},descAnnotation:{name:VI.descAnnotation},iconAnnotation:{name:VI.iconAnnotation},indent:{name:VI.indent},name:{name:VI.name}},superTypes:[]},TreeView:{name:HI.$type,properties:{accDescr:{name:HI.accDescr},accTitle:{name:HI.accTitle},nodes:{name:HI.nodes,defaultValue:[]},title:{name:HI.title}},superTypes:[]},Treemap:{name:RI.$type,properties:{accDescr:{name:RI.accDescr},accTitle:{name:RI.accTitle},title:{name:RI.title},TreemapRows:{name:RI.TreemapRows,defaultValue:[]}},superTypes:[]},TreemapRow:{name:BI.$type,properties:{indent:{name:BI.indent},item:{name:BI.item}},superTypes:[]},Wardley:{name:UI.$type,properties:{accDescr:{name:UI.accDescr},accelerators:{name:UI.accelerators,defaultValue:[]},accTitle:{name:UI.accTitle},anchors:{name:UI.anchors,defaultValue:[]},annotation:{name:UI.annotation,defaultValue:[]},annotations:{name:UI.annotations,defaultValue:[]},components:{name:UI.components,defaultValue:[]},deaccelerators:{name:UI.deaccelerators,defaultValue:[]},evolution:{name:UI.evolution},evolves:{name:UI.evolves,defaultValue:[]},links:{name:UI.links,defaultValue:[]},notes:{name:UI.notes,defaultValue:[]},pipelines:{name:UI.pipelines,defaultValue:[]},size:{name:UI.size},title:{name:UI.title}},superTypes:[]}}}static{o(this,`MermaidAstReflection`)}},$=new GI,KI,qI=o(()=>KI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"ArchitectureGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Architecture","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"architecture-beta"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"groups","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"services","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"junctions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"edges","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"alignments","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"LeftPort","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"lhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"RightPort","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"rhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Keyword","value":":"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Arrow","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Assignment","feature":"lhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"--"},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]}},{"$type":"Keyword","value":"-"}]}]},{"$type":"Assignment","feature":"rhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Group","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"group"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Service","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"service"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"iconText","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Junction","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"junction"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Edge","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"lhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"lhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"rhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"rhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Alignment","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"align"},{"$type":"Assignment","feature":"direction","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"row"},{"$type":"Keyword","value":"column"}]}},{"$type":"Assignment","feature":"members","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"members","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},"cardinality":"+"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ARROW_DIRECTION","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"L"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"R"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"T"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"B"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_GROUP","definition":{"$type":"RegexToken","regex":"/\\\\{group\\\\}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_INTO","definition":{"$type":"RegexToken","regex":"/<|>/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@19"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@20"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"ARCH_ICON","definition":{"$type":"RegexToken","regex":"/\\\\([\\\\w-:]+\\\\)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_TITLE","definition":{"$type":"RegexToken","regex":"/\\\\[(?:\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'|[^\\\\[\\\\]\\\\r\\\\n]+)\\\\]/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`ArchitectureGrammarGrammar`),JI,YI=o(()=>JI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"CynefinGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Cynefin","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"cynefin-beta"},{"$type":"Keyword","value":"cynefin-beta:"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Assignment","feature":"domains","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"transitions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"DomainBlock","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"domain","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Assignment","feature":"items","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"DomainItem","definition":{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Transition","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"from","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":"-->"},{"$type":"Assignment","feature":"to","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"DOMAIN_NAME","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"complex"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"complicated"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"clear"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"chaotic"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"confusion"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@11"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@12"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`CynefinGrammarGrammar`),XI,ZI=o(()=>XI??=eP('{"$type":"Grammar","isDeclared":true,"name":"EventModeling","interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"rules":[{"$type":"ParserRule","entry":true,"name":"EventModel","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"eventmodeling"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"frames","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"dataEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"noteEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"gwtEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntityType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rmo"},{"$type":"Keyword","value":"readmodel"},{"$type":"Keyword","value":"ui"},{"$type":"Keyword","value":"cmd"},{"$type":"Keyword","value":"command"},{"$type":"Keyword","value":"evt"},{"$type":"Keyword","value":"event"},{"$type":"Keyword","value":"pcr"},{"$type":"Keyword","value":"processor"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"json"},{"$type":"Keyword","value":"jsobj"},{"$type":"Keyword","value":"figma"},{"$type":"Keyword","value":"salt"},{"$type":"Keyword","value":"uri"},{"$type":"Keyword","value":"md"},{"$type":"Keyword","value":"html"},{"$type":"Keyword","value":"text"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataInline","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataInlineValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataBlock","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataBlockValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"QualifiedName","dataType":"string","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"."},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmTimeFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"tf"},{"$type":"Keyword","value":"timeframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmResetFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rf"},{"$type":"Keyword","value":"resetframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmFrame","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"entity"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"data"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmNoteEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"note"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwt","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"gwt"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"given"},{"$type":"Assignment","feature":"givenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"},{"$type":"Group","elements":[{"$type":"Keyword","value":"when"},{"$type":"Assignment","feature":"whenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}],"cardinality":"?"},{"$type":"Keyword","value":"then"},{"$type":"Assignment","feature":"thenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwtStatement","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@9"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_EID","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_FI","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"EM_ID","definition":{"$type":"RegexToken","regex":"/[_a-zA-Z][\\\\w_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_FID","definition":{"$type":"RegexToken","regex":"/\\\\d{1,3}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_INLINE","definition":{"$type":"RegexToken","regex":"/\\\\{(.*)\\\\}|\\"(.*)\\"|\'(.*)\'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_BLOCK","definition":{"$type":"RegexToken","regex":"/\\\\{[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?\\\\}(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"EM_WS","definition":{"$type":"RegexToken","regex":"/\\\\s+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SL_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\/[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"imports":[],"types":[]}'),`EventModelingGrammar`),QI,$I=o(()=>QI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"GitGraphGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"GitGraph","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Keyword","value":":"}]},{"$type":"Keyword","value":"gitGraph:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Keyword","value":":"}]}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"Assignment","feature":"statements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Direction","definition":{"$type":"Assignment","feature":"dir","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"LR"},{"$type":"Keyword","value":"TB"},{"$type":"Keyword","value":"BT"}]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Commit","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"commit"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"msg:","cardinality":"?"},{"$type":"Assignment","feature":"message","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Branch","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"branch"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"order:"},{"$type":"Assignment","feature":"order","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Merge","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"merge"},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Checkout","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"checkout"},{"$type":"Keyword","value":"switch"}]},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CherryPicking","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"cherry-pick"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"parent:"},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@14"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"REFERENCE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\w([-\\\\./\\\\w]*[-\\\\w])?/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`GitGraphGrammarGrammar`),eL,tL=o(()=>eL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"InfoGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Info","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"info"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"showInfo"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"?"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@7"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`InfoGrammarGrammar`),nL,rL=o(()=>nL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"PacketGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Packet","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"packet"},{"$type":"Keyword","value":"packet-beta"}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"Assignment","feature":"blocks","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PacketBlock","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"start","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"end","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}],"cardinality":"?"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"+"},{"$type":"Assignment","feature":"bits","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]}]},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@9"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PacketGrammarGrammar`),iL,aL=o(()=>iL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"PieGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Pie","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"pie"},{"$type":"Assignment","feature":"showData","operator":"?=","terminal":{"$type":"Keyword","value":"showData"},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Assignment","feature":"sections","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PieSection","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"FLOAT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?(0|[1-9][0-9]*)(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@2"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@3"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@11"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@12"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PieGrammarGrammar`),oL,sL=o(()=>oL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RadarGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Radar","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":"radar-beta:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":":"}]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"axis"},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"curve"},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Label","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Axis","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Curve","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Keyword","value":"}"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Entries","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"DetailedEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"axis","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@2"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":":","cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"NumberEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Option","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"showLegend"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"ticks"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"max"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"min"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"graticule"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"GRATICULE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"circle"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"polygon"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@16"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[{"$type":"Interface","name":"Entry","attributes":[{"$type":"TypeAttribute","name":"axis","isOptional":true,"type":{"$type":"ReferenceType","referenceType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@2"}},"isMulti":false}},{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}],"superTypes":[]}],"types":[]}`),`RadarGrammarGrammar`),cL,lL=o(()=>cL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadAbnfGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_RULENAME","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Za-z][A-Za-z0-9-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_NUMVAL","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/%[xXdDbB][0-9A-Fa-f]+(?:-[0-9A-Fa-f]+|\\\\.[0-9A-Fa-f]+)*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_REPEAT","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[0-9]*\\\\*[0-9]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_EXACT_REPEAT","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[0-9]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_COMMENT","definition":{"$type":"RegexToken","regex":"/;[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadAbnf","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-abnf-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"="},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfAlternation","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfConcatenation","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},"cardinality":"+"},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfElement","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"repeat","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"repeat","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"primary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfPrimary","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfStringLiteral","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfNumVal","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfRuleName","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfGroup","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfOptionalGroup","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadAbnf","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfAlternation","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfConcatenation","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfElement","attributes":[{"$type":"TypeAttribute","name":"repeat","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"primary","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"AbnfStringLiteral","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfNumVal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfRuleName","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"AbnfOptionalGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadAbnfGrammarGrammar`),uL,dL=o(()=>uL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadEbnfGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_SPECIAL_SEQUENCE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\?(?=[^?;]*[^?\\\\s;][^?;]*\\\\?)[^?;]*\\\\?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_BLOCK_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_ISO_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\(\\\\*[\\\\s\\\\S]*?\\\\*\\\\)/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadEbnf","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-ebnf-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"="},{"$type":"Keyword","value":"::="}]},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfChoice","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"|"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfSequence","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":",","cardinality":"?"},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfTerm","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"base","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"postfixes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfPrimary","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfTerminal","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfNonTerminal","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfSpecial","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfGroup","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOptional","returnType":{"$ref":"#/interfaces@11"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfRepetition","returnType":{"$ref":"#/interfaces@12"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"{"},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":"}"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfPostfix","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@25"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@26"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@27"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOptionalPostfix","returnType":{"$ref":"#/interfaces@13"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"?"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfZeroOrMorePostfix","returnType":{"$ref":"#/interfaces@14"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"*"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOneOrMorePostfix","returnType":{"$ref":"#/interfaces@15"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"+"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfExceptionPostfix","returnType":{"$ref":"#/interfaces@16"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"except","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadEbnf","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfChoice","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfSequence","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfTerm","attributes":[{"$type":"TypeAttribute","name":"base","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false},{"$type":"TypeAttribute","name":"postfixes","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@6"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"EbnfPostfix","attributes":[],"superTypes":[]},{"$type":"Interface","name":"EbnfTerminal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfNonTerminal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfSpecial","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"text","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfOptional","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfRepetition","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfOptionalPostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfZeroOrMorePostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfOneOrMorePostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfExceptionPostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"except","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadEbnfGrammarGrammar`),fL,pL=o(()=>fL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"RR_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"RR_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"RR_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_BLOCK_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"Railroad","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"="},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadExpression","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadSequenceExpr","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"sequence"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadChoiceExpr","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"choice"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadOptionalExpr","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"optional"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadOneOrMoreExpr","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"oneOrMore"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadZeroOrMoreExpr","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"zeroOrMore"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadTerminalExpr","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"terminal"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadNonTerminalExpr","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"nonterminal"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadSpecialExpr","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"special"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"Railroad","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"RailroadRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"RailroadExpression","attributes":[],"superTypes":[]},{"$type":"Interface","name":"RailroadSequenceExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}}},"isOptional":false}]},{"$type":"Interface","name":"RailroadChoiceExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}}},"isOptional":false}]},{"$type":"Interface","name":"RailroadOptionalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadOneOrMoreExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadZeroOrMoreExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadTerminalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"RailroadNonTerminalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"RailroadSpecialExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"text","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadGrammarGrammar`),mL,hL=o(()=>mL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadPegGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"PEG_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"PEG_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/#[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadPeg","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-peg-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"<-"},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegOrderedChoice","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegSequence","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"+"},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegPrefix","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"&"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"!"}}],"cardinality":"?"},{"$type":"Assignment","feature":"suffix","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegSuffix","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"primary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"?"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"*"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"+"}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegPrimary","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegLiteral","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegIdentifier","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegGroup","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegAny","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Assignment","feature":"dot","operator":"=","terminal":{"$type":"Keyword","value":"."}},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadPeg","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegOrderedChoice","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegSequence","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegPrefix","attributes":[{"$type":"TypeAttribute","name":"operator","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"suffix","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegSuffix","attributes":[{"$type":"TypeAttribute","name":"primary","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@6"}},"isOptional":false},{"$type":"TypeAttribute","name":"operator","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"PegPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"PegLiteral","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"PegIdentifier","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"PegGroup","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"PegAny","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"dot","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadPegGrammarGrammar`),gL,_L=o(()=>gL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"TreemapGrammar","rules":[{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"Treemap","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]},{"$type":"Assignment","feature":"TreemapRows","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"TREEMAP_KEYWORD","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap-beta"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"CLASS_DEF","definition":{"$type":"RegexToken","regex":"/classDef\\\\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\\\\s+([^;\\\\r\\\\n]*))?(?:;)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STYLE_SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":::"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"COMMA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":","},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"TreemapRow","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"item","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"ClassDef","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Item","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Section","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Leaf","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ID2","definition":{"$type":"RegexToken","regex":"/[a-zA-Z_][a-zA-Z0-9_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER2","definition":{"$type":"RegexToken","regex":"/[0-9_\\\\.\\\\,]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"MyNumber","dataType":"number","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"STRING2","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[{"$type":"Interface","name":"Item","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"classSelector","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"Section","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[]},{"$type":"Interface","name":"Leaf","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}]},{"$type":"Interface","name":"ClassDefStatement","attributes":[{"$type":"TypeAttribute","name":"className","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"styleText","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"Treemap","attributes":[{"$type":"TypeAttribute","name":"TreemapRows","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@15"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * Treemap grammar for Langium\\n * Converted from mindmap grammar\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treemap keyword, allowing for empty lines and comments before the\\n * treemap declaration.\\n */"}`),`TreemapGrammarGrammar`),vL,yL=o(()=>vL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"TreeViewGrammar","rules":[{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"TreeView","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"treeView-beta"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"nodes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"CLASS_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+:::[ \\\\t]*[A-Za-z_][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ICON_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+icon\\\\([\\\\w-]*(?::[\\\\w-]+)?\\\\)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"DESC_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+##[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"QUOTED_NAME","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"BARE_NAME","definition":{"$type":"RegexToken","regex":"/(?!:::|icon\\\\(|##)[^ \\\\t\\\\n\\\\r\\"'](?:(?![ \\\\t]+:::[ \\\\t]*[A-Za-z_]|[ \\\\t]+icon\\\\(|[ \\\\t]+##)[^\\\\n\\\\r])*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"TreeNode","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}]},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"classAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"iconAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"descAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"TreeView","attributes":[{"$type":"TypeAttribute","name":"nodes","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@14"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * TreeView grammar for Langium\\n *\\n * Supports both quoted labels (\\"my file\\") and bare labels (index.js).\\n * Annotations (:::class, icon(), ## description) are parsed directly into\\n * AST fields by the grammar. Value conversion for stripping quotes, extracting\\n * class names, icon names, and description text happens in valueConverter.ts.\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treeView keyword, allowing for empty lines and comments before the\\n * treeView declaration.\\n */"}`),`TreeViewGrammarGrammar`),bL,xL=o(()=>bL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"WardleyGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Wardley","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@25"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@42"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"size","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"anchors","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"links","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"evolves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"pipelines","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"notes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"annotations","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Assignment","feature":"annotation","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"accelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"deaccelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Size","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@26"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"width","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"height","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolution","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@27"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EvolutionStage","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"@"},{"$type":"Assignment","feature":"boundary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}],"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"secondName","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Anchor","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Component","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"decorator","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Keyword","value":")"}]}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Label","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"negX","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetX","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"negY","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetY","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Decorator","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"strategy","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Link","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"from","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"fromPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"arrow","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"cardinality":"?"},{"$type":"Assignment","feature":"to","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"toPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"linkLabel","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolve","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@32"},"arguments":[]},{"$type":"Assignment","feature":"component","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"target","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Pipeline","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@33"},"arguments":[]},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"+"},{"$type":"Keyword","value":"}"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PipelineComponent","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Note","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@34"},"arguments":[]},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotations","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@35"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotation","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@36"},"arguments":[]},{"$type":"Assignment","feature":"number","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CoordinateValue","dataType":"number","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Accelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@37"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Deaccelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@38"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"WARDLEY_NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"->"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_PORT","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<>"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+>"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_ARROW","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-->"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-.->"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":">"},"parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'<>/","parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'/","parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_LABEL","definition":{"$type":"RegexToken","regex":"/;[^\\\\n\\\\r]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRATEGY","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"build"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"buy"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"outsource"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"market"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_WARDLEY","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"wardley-beta"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_SIZE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"size"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLUTION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolution"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANCHOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"anchor"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_COMPONENT","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"component"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_LABEL","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"label"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_INERTIA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"inertia"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLVE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolve"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_PIPELINE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"pipeline"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_NOTE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"note"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATIONS","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotations"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotation"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"accelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_DEACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"deaccelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NAME_WITH_SPACES","definition":{"$type":"RegexToken","regex":"/(?!title\\\\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \\\\t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@44"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@45"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@46"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@47"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@48"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`WardleyGrammarGrammar`),SL={languageId:`architecture`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},CL={languageId:`cynefin`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},wL={languageId:`eventmodeling`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},TL={languageId:`gitGraph`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},EL={languageId:`info`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},DL={languageId:`packet`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},OL={languageId:`pie`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},kL={languageId:`radar`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},AL={languageId:`railroadAbnf`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},jL={languageId:`railroadEbnf`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},ML={languageId:`railroad`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},NL={languageId:`railroadPeg`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},PL={languageId:`treemap`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},FL={languageId:`treeView`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},IL={languageId:`wardley`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},LL={AstReflection:o(()=>new GI,`AstReflection`)},RL={Grammar:o(()=>qI(),`Grammar`),LanguageMetaData:o(()=>SL,`LanguageMetaData`),parser:{}},zL={Grammar:o(()=>YI(),`Grammar`),LanguageMetaData:o(()=>CL,`LanguageMetaData`),parser:{}},BL={Grammar:o(()=>ZI(),`Grammar`),LanguageMetaData:o(()=>wL,`LanguageMetaData`),parser:{}},VL={Grammar:o(()=>$I(),`Grammar`),LanguageMetaData:o(()=>TL,`LanguageMetaData`),parser:{}},HL={Grammar:o(()=>tL(),`Grammar`),LanguageMetaData:o(()=>EL,`LanguageMetaData`),parser:{}},UL={Grammar:o(()=>rL(),`Grammar`),LanguageMetaData:o(()=>DL,`LanguageMetaData`),parser:{}},WL={Grammar:o(()=>aL(),`Grammar`),LanguageMetaData:o(()=>OL,`LanguageMetaData`),parser:{}},GL={Grammar:o(()=>sL(),`Grammar`),LanguageMetaData:o(()=>kL,`LanguageMetaData`),parser:{}},KL={Grammar:o(()=>lL(),`Grammar`),LanguageMetaData:o(()=>AL,`LanguageMetaData`),parser:{}},qL={Grammar:o(()=>dL(),`Grammar`),LanguageMetaData:o(()=>jL,`LanguageMetaData`),parser:{}},JL={Grammar:o(()=>pL(),`Grammar`),LanguageMetaData:o(()=>ML,`LanguageMetaData`),parser:{}},YL={Grammar:o(()=>hL(),`Grammar`),LanguageMetaData:o(()=>NL,`LanguageMetaData`),parser:{}},XL={Grammar:o(()=>_L(),`Grammar`),LanguageMetaData:o(()=>PL,`LanguageMetaData`),parser:{}},ZL={Grammar:o(()=>yL(),`Grammar`),LanguageMetaData:o(()=>FL,`LanguageMetaData`),parser:{}},QL={Grammar:o(()=>xL(),`Grammar`),LanguageMetaData:o(()=>IL,`LanguageMetaData`),parser:{}},$L={ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/accTitle[\t ]*:([^\n\r]*)/,TITLE:/title([\t ][^\n\r]*|)/},eR=class extends Ij{static{o(this,`AbstractMermaidValueConverter`)}runConverter(e,t,n){let r=this.runCommonConverter(e,t,n);return r===void 0&&(r=this.runCustomConverter(e,t,n)),r===void 0?super.runConverter(e,t,n):r}runCommonConverter(e,t,n){let r=$L[e.name];if(r===void 0)return;let i=r.exec(t);if(i!==null){if(i[1]!==void 0)return i[1].trim().replace(/[\t ]{2,}/gm,` `);if(i[2]!==void 0)return i[2].replace(/^\s*/gm,``).replace(/\s+$/gm,``).replace(/[\t ]{2,}/gm,` `).replace(/[\n\r]{2,}/gm,` +`)}}},tR=class extends eR{static{o(this,`CommonValueConverter`)}runCustomConverter(e,t,n){}},nR=class extends Fj{static{o(this,`AbstractMermaidTokenBuilder`)}constructor(e){super(),this.keywords=new Set(e)}buildKeywordTokens(e,t,n){let r=super.buildKeywordTokens(e,t,n);return r.forEach(e=>{this.keywords.has(e.name)&&e.PATTERN!==void 0&&(e.PATTERN=RegExp(e.PATTERN.toString()+`(?:(?=%%)|(?!\\S))`))}),r}};(class extends nR{static{o(this,`CommonTokenBuilder`)}});export{FN as C,PN as S,EF as T,YL as _,zL as a,QL as b,VL as c,UL as d,WL as f,JL as g,qL as h,tR as i,HL as l,KL as m,eR as n,XN as o,GL as p,RL as r,BL as s,nR as t,LL as u,ZL as v,LN as w,o as x,XL as y}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-GTNCS2PH-CoZ--rjp.js b/frontend/dist/assets/chunk-GTNCS2PH-CoZ--rjp.js new file mode 100644 index 0000000..61573c5 --- /dev/null +++ b/frontend/dist/assets/chunk-GTNCS2PH-CoZ--rjp.js @@ -0,0 +1,88 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,a as r,b as i,c as a,x as o,z as s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{y as c}from"./index-DoQkmpth.js";var l=``,u=``,d=``,f=[],p=new Map,m=t(e=>s(e,o()),`sanitizeText`),h=t(e=>{switch(e.type){case`terminal`:return{...e,value:m(e.value)};case`nonterminal`:return{...e,name:m(e.name)};case`sequence`:return{...e,elements:e.elements.map(h)};case`choice`:return{...e,alternatives:e.alternatives.map(h)};case`optional`:return{...e,element:h(e.element)};case`repetition`:return{...e,element:h(e.element),separator:e.separator?h(e.separator):void 0};case`special`:return{...e,text:m(e.text)}}},`sanitizeAstNode`),g=t(()=>{l=``,u=``,d=``,f.length=0,p.clear(),r(),e.debug(`[Railroad] Database cleared`)},`clear`),_=t(t=>{l=m(t),e.debug(`[Railroad] Title set:`,t)},`setTitle`),v=t(()=>l,`getTitle`),y={clear:g,setTitle:_,getTitle:v,addRule:t(t=>{let n={...t,name:m(t.name),definition:h(t.definition),comment:t.comment?m(t.comment):void 0};e.debug(`[Railroad] Adding rule:`,n.name),p.has(n.name)&&e.warn(`[Railroad] Rule '${n.name}' is already defined. Overwriting.`),f.push(n),p.set(n.name,n)},`addRule`),getRules:t(()=>f,`getRules`),getRule:t(e=>p.get(e),`getRule`),setAccTitle:t(t=>{u=m(t).replace(/^\s+/g,``),e.debug(`[Railroad] Accessibility title set:`,t)},`setAccTitle`),getAccTitle:t(()=>u,`getAccTitle`),setAccDescription:t(t=>{d=m(t).replace(/\n\s+/g,` +`),e.debug(`[Railroad] Accessibility description set:`,t)},`setAccDescription`),getAccDescription:t(()=>d,`getAccDescription`),setDiagramTitle:_,getDiagramTitle:v},b={compactMode:!1,padding:10,verticalSeparation:8,horizontalSeparation:10,arcRadius:10,fontSize:14,fontFamily:`monospace`,terminalFill:`#FFFFC0`,terminalStroke:`#000000`,terminalTextColor:`#000000`,nonTerminalFill:`#FFFFFF`,nonTerminalStroke:`#000000`,nonTerminalTextColor:`#000000`,lineColor:`#000000`,strokeWidth:2,markerFill:`#000000`,commentFill:`#E8E8E8`,commentStroke:`#888888`,commentTextColor:`#666666`,specialFill:`#F0E0FF`,specialStroke:`#8800CC`,ruleNameColor:`#000066`,showMarkers:!0,markerRadius:5},x=/^#(?:[\da-f]{3,4}|[\da-f]{6}|[\da-f]{8})$|^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch)\([\d\s%+,./-]+\)$|^[a-z]+$/i,S=/^[\w "',.-]+$/,C=new Set([`compactMode`,`padding`,`verticalSeparation`,`horizontalSeparation`,`arcRadius`,`fontSize`,`fontFamily`,`terminalFill`,`terminalStroke`,`terminalTextColor`,`nonTerminalFill`,`nonTerminalStroke`,`nonTerminalTextColor`,`lineColor`,`strokeWidth`,`markerFill`,`commentFill`,`commentStroke`,`commentTextColor`,`specialFill`,`specialStroke`,`ruleNameColor`,`showMarkers`,`markerRadius`]),w=t(e=>e?Object.keys(e).every(e=>e===`railroad`||C.has(e)):!1,`isRailroadStyleOptions`),T=t(e=>e?`railroad`in e&&e.railroad?e.railroad:w(e)?e:{}:{},`extractRailroadOverrides`),E=t(e=>{if(!e||w(e))return{};let{railroad:t,svgId:n,theme:r,look:i,...a}=e;return a},`extractThemeOverrides`),D=t((e,t)=>{if(typeof e!=`string`)return t;let n=e.trim();return x.test(n)?n:t},`sanitizeColorValue`),O=t((e,t)=>{if(typeof e!=`string`)return t;let n=e.trim();return S.test(n)?n:t},`sanitizeFontFamilyValue`),k=t((e,t)=>{let n=typeof e==`number`?e:typeof e==`string`?Number.parseFloat(e):NaN;return Number.isFinite(n)&&n>=0?n:t},`sanitizeNumberValue`),A=t(e=>{let t=typeof e==`number`?e:typeof e==`string`?Number.parseFloat(e):NaN;return Number.isFinite(t)&&t>0?t:void 0},`parseThemeFontSize`),j=t(e=>{let t=O(e.fontFamily,b.fontFamily),n=A(e.fontSize)??b.fontSize;return{...b,fontFamily:t,fontSize:n,terminalFill:D(e.secondBkg??e.secondaryColor,b.terminalFill),terminalStroke:D(e.secondaryBorderColor??e.lineColor,b.terminalStroke),terminalTextColor:D(e.secondaryTextColor??e.textColor,b.terminalTextColor),nonTerminalFill:D(e.mainBkg??e.background,b.nonTerminalFill),nonTerminalStroke:D(e.primaryBorderColor??e.lineColor,b.nonTerminalStroke),nonTerminalTextColor:D(e.primaryTextColor??e.textColor,b.nonTerminalTextColor),lineColor:D(e.lineColor,b.lineColor),markerFill:D(e.lineColor,b.markerFill),commentFill:D(e.labelBackground??e.tertiaryColor,b.commentFill),commentStroke:D(e.tertiaryBorderColor??e.lineColor,b.commentStroke),commentTextColor:D(e.tertiaryTextColor??e.textColor,b.commentTextColor),specialFill:D(e.tertiaryColor??e.secondaryColor,b.specialFill),specialStroke:D(e.tertiaryBorderColor??e.secondaryBorderColor,b.specialStroke),ruleNameColor:D(e.titleColor??e.textColor,b.ruleNameColor)}},`buildThemeDefaults`),M=t(e=>{let t=i(),r=j({...n(),...t.themeVariables??{},...E(e)}),a={...t.railroad??{},...T(e)};return{compactMode:a.compactMode??r.compactMode,padding:k(a.padding,r.padding),verticalSeparation:k(a.verticalSeparation,r.verticalSeparation),horizontalSeparation:k(a.horizontalSeparation,r.horizontalSeparation),arcRadius:k(a.arcRadius,r.arcRadius),fontSize:k(a.fontSize,r.fontSize),fontFamily:O(a.fontFamily,r.fontFamily),terminalFill:D(a.terminalFill,r.terminalFill),terminalStroke:D(a.terminalStroke,r.terminalStroke),terminalTextColor:D(a.terminalTextColor,r.terminalTextColor),nonTerminalFill:D(a.nonTerminalFill,r.nonTerminalFill),nonTerminalStroke:D(a.nonTerminalStroke,r.nonTerminalStroke),nonTerminalTextColor:D(a.nonTerminalTextColor,r.nonTerminalTextColor),lineColor:D(a.lineColor,r.lineColor),strokeWidth:k(a.strokeWidth,r.strokeWidth),markerFill:D(a.markerFill,r.markerFill),commentFill:D(a.commentFill,r.commentFill),commentStroke:D(a.commentStroke,r.commentStroke),commentTextColor:D(a.commentTextColor,r.commentTextColor),specialFill:D(a.specialFill,r.specialFill),specialStroke:D(a.specialStroke,r.specialStroke),ruleNameColor:D(a.ruleNameColor,r.ruleNameColor),showMarkers:a.showMarkers??r.showMarkers,markerRadius:k(a.markerRadius,r.markerRadius)}},`buildRailroadStyleOptions`),N=t(e=>{let{fontFamily:t,fontSize:n,terminalFill:r,terminalStroke:i,terminalTextColor:a,nonTerminalFill:o,nonTerminalStroke:s,nonTerminalTextColor:c,lineColor:l,strokeWidth:u,markerFill:d,commentFill:f,commentStroke:p,commentTextColor:m,specialFill:h,specialStroke:g,ruleNameColor:_}=M(e);return` + .railroad-diagram { + font-family: ${t}; + font-size: ${n}px; + } + + .railroad-terminal rect { + fill: ${r}; + stroke: ${i}; + stroke-width: ${u}px; + } + + .railroad-terminal text { + fill: ${a}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-nonterminal rect { + fill: ${o}; + stroke: ${s}; + stroke-width: ${u}px; + } + + .railroad-nonterminal text { + fill: ${c}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-line { + stroke: ${l}; + stroke-width: ${u}px; + fill: none; + } + + .railroad-start circle, + .railroad-end circle { + fill: ${d}; + } + + .railroad-comment ellipse { + fill: ${f}; + stroke: ${p}; + stroke-width: ${u}px; + } + + .railroad-comment text { + fill: ${m}; + font-style: italic; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-special rect { + fill: ${h}; + stroke: ${g}; + stroke-width: ${u}px; + stroke-dasharray: 5,3; + } + + .railroad-special text { + fill: ${c}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-rule-name { + font-weight: bold; + fill: ${_}; + font-family: ${t}; + font-size: ${n}px; + } + + .railroad-group { + /* Grouping container, no specific styles */ + } +`},`getStyles`),P=class{constructor(){this.d=``}static{t(this,`PathBuilder`)}moveTo(e,t){return this.d+=`M ${e} ${t} `,this}lineTo(e,t){return this.d+=`L ${e} ${t} `,this}horizontalTo(e){return this.d+=`H ${e} `,this}verticalTo(e){return this.d+=`V ${e} `,this}arcTo(e,t,n,r,i,a,o){return this.d+=`A ${e} ${t} ${n} ${+!!r} ${+!!i} ${a} ${o} `,this}build(){return this.d.trim()}},F=class{constructor(e,t=M()){this.textCache=new Map,this.svg=e,this.config=t}static{t(this,`RailroadRenderer`)}measureText(e){if(this.textCache.has(e))return this.textCache.get(e);let t=this.svg.append(`text`).attr(`font-family`,this.config.fontFamily).attr(`font-size`,this.config.fontSize).text(e),n=t.node().getBBox(),r={width:n.width,height:n.height};return t.remove(),this.textCache.set(e,r),r}renderTerminal(e,t){let n=this.measureText(t),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-terminal`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i).attr(`rx`,10).attr(`ry`,10),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(t),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderNonTerminal(e,t){let n=this.measureText(t),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-nonterminal`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(t),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderSequence(e,t){let n=t.map(t=>this.renderExpression(e,t)),r=0,i=0,a=0;for(let e of n)r+=e.dimensions.width,i=Math.max(i,e.dimensions.up),a=Math.max(a,e.dimensions.down);r+=(n.length-1)*this.config.horizontalSeparation;let o=e.append(`g`).attr(`class`,`railroad-sequence`),s=0;for(let e=0;ethis.renderExpression(e,t)),r=0,i=0;for(let e of n)r=Math.max(r,e.dimensions.width),i+=e.dimensions.height;i+=(n.length-1)*this.config.verticalSeparation;let a=this.config.arcRadius,o=a*4,s=r+o,c=e.append(`g`).attr(`class`,`railroad-choice`),l=0,u=i/2;for(let e of n){let t=l,n=t+e.dimensions.up,i=a*2+(r-e.dimensions.width)/2;c.node().appendChild(e.element).setAttribute(`transform`,`translate(${i}, ${t})`);let o=new P,d=n>u;n===u?o.moveTo(0,u).lineTo(i,n):o.moveTo(0,u).arcTo(a,a,0,!1,d,a,u+(d?a:-a)).lineTo(a,n-(d?a:-a)).arcTo(a,a,0,!1,!d,a*2,n).lineTo(i,n),c.append(`path`).attr(`class`,`railroad-line`).attr(`d`,o.build());let f=new P,p=i+e.dimensions.width,m=s-a*2;n===u?f.moveTo(p,n).lineTo(s,u):f.moveTo(p,n).lineTo(m,n).arcTo(a,a,0,!1,!d,s-a,n+(d?-a:a)).lineTo(s-a,u+(d?a:-a)).arcTo(a,a,0,!1,d,s,u),c.append(`path`).attr(`class`,`railroad-line`).attr(`d`,f.build()),l+=e.dimensions.height+this.config.verticalSeparation}return{element:c.node(),dimensions:{width:s,height:i,up:u,down:i-u}}}renderOptional(e,t){let n=this.renderExpression(e,t),r=this.config.arcRadius,i=r*2,a=n.dimensions.width+r*4,o=n.dimensions.height+i,s=e.append(`g`).attr(`class`,`railroad-optional`),c=r*2,l=i;s.node().appendChild(n.element).setAttribute(`transform`,`translate(${c}, ${l})`);let u=l+n.dimensions.up,d=new P().moveTo(0,u).lineTo(r*2,u);s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,d.build());let f=new P().moveTo(c+n.dimensions.width,u).lineTo(a,u);s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,f.build());let p=new P().moveTo(0,u).arcTo(r,r,0,!1,!1,r,u-r).lineTo(r,r).arcTo(r,r,0,!1,!0,r*2,0).lineTo(a-r*2,0).arcTo(r,r,0,!1,!0,a-r,r).lineTo(a-r,u-r).arcTo(r,r,0,!1,!1,a,u);return s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,p.build()),{element:s.node(),dimensions:{width:a,height:o,up:u,down:o-u}}}renderRepetition(e,t,n){let r=this.renderExpression(e,t),i=this.config.arcRadius,a=i*2,o=r.dimensions.width+i*4,s=n===0,c=r.dimensions.height+a+(s?a:0),l=e.append(`g`).attr(`class`,`railroad-repetition`),u=i*2,d=s?a:0;l.node().appendChild(r.element).setAttribute(`transform`,`translate(${u}, ${d})`);let f=d+r.dimensions.up;l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(0,f).lineTo(i*2,f).build()),l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(u+r.dimensions.width,f).lineTo(o,f).build());let p=d+r.dimensions.height+i,m=new P().moveTo(u+r.dimensions.width,f).arcTo(i,i,0,!1,!0,u+r.dimensions.width+i,f+i).lineTo(u+r.dimensions.width+i,p).arcTo(i,i,0,!1,!0,u+r.dimensions.width,p+i).lineTo(i*2,p+i).arcTo(i,i,0,!1,!0,i,p).lineTo(i,f+i).arcTo(i,i,0,!1,!0,i*2,f);if(l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,m.build()),s){let e=new P().moveTo(0,f).arcTo(i,i,0,!1,!1,i,f-i).lineTo(i,i).arcTo(i,i,0,!1,!0,i*2,0).lineTo(o-i*2,0).arcTo(i,i,0,!1,!0,o-i,i).lineTo(o-i,f-i).arcTo(i,i,0,!1,!1,o,f);l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,e.build())}return{element:l.node(),dimensions:{width:o,height:c,up:f,down:c-f}}}renderSpecial(e,t){let n=this.measureText(`? `+t+` ?`),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-special`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(`? `+t+` ?`),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderExpression(e,t){switch(t.type){case`terminal`:return this.renderTerminal(e,t.value);case`nonterminal`:return this.renderNonTerminal(e,t.name);case`sequence`:return this.renderSequence(e,t.elements);case`choice`:return this.renderChoice(e,t.alternatives);case`optional`:return this.renderOptional(e,t.element);case`repetition`:return this.renderRepetition(e,t.element,t.min);case`special`:return this.renderSpecial(e,t.text);default:throw Error(`Unknown node type: ${t.type}`)}}renderRule(e,t){let n=this.svg.append(`g`).attr(`class`,`railroad-rule`).attr(`transform`,`translate(0, ${t})`),r=e.name+` =`,i=this.measureText(r).width+20,a=i+20,o=n.append(`g`),s=this.renderExpression(o,e.definition),c=Math.max(20,s.dimensions.up),l=c-s.dimensions.up;return o.attr(`transform`,`translate(${a}, ${l})`),n.append(`g`).attr(`class`,`railroad-rule-name-group`).append(`text`).attr(`class`,`railroad-rule-name`).attr(`x`,0).attr(`y`,c).text(r),n.append(`g`).attr(`class`,`railroad-start`).append(`circle`).attr(`cx`,i).attr(`cy`,c).attr(`r`,this.config.markerRadius),n.append(`g`).attr(`class`,`railroad-end`).append(`circle`).attr(`cx`,a+s.dimensions.width+10).attr(`cy`,c).attr(`r`,this.config.markerRadius),n.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(i+this.config.markerRadius,c).lineTo(a,c).build()),n.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(a+s.dimensions.width,c).lineTo(a+s.dimensions.width+10-this.config.markerRadius,c).build()),{height:Math.max(40,l+s.dimensions.height+this.config.padding*2),width:a+s.dimensions.width+10+this.config.markerRadius}}renderDiagram(e){let t=this.config.padding,n=0;for(let r of e){let e=this.renderRule(r,t);t+=e.height+this.config.verticalSeparation,n=Math.max(n,e.width)}return{width:n+this.config.padding*2,height:t+this.config.padding}}},I=t((e,t,n)=>{a(e,t.height,t.width,n),e.attr(`viewBox`,`0 0 ${t.width} ${t.height}`)},`configureRailroadSvgSize`),L={draw:t((t,n,r)=>{e.debug(`[Railroad] Rendering diagram +`+t);try{let t=c(n);t.attr(`class`,`railroad-diagram`);let r=i().railroad?.useMaxWidth??!0,a=y.getRules();if(e.debug(`[Railroad] Rendering ${a.length} rules`),a.length===0){e.warn(`[Railroad] No rules to render`),I(t,{height:100,width:200},r);return}I(t,new F(t,M()).renderDiagram(a),r),e.debug(`[Railroad] Render complete`)}catch(t){throw e.error(`[Railroad] Render error:`,t),t}},`draw`)};export{N as n,L as r,y as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-GWA4HPMP-C1P4FmAY.js b/frontend/dist/assets/chunk-GWA4HPMP-C1P4FmAY.js new file mode 100644 index 0000000..60e92fb --- /dev/null +++ b/frontend/dist/assets/chunk-GWA4HPMP-C1P4FmAY.js @@ -0,0 +1 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{j as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as r}from"./dist-Bfr8PhAA.js";var i=r(),a=t((e,t)=>{let n=e.append(`rect`);if(n.attr(`x`,t.x),n.attr(`y`,t.y),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`width`,t.width),n.attr(`height`,t.height),t.name&&n.attr(`name`,t.name),t.rx&&n.attr(`rx`,t.rx),t.ry&&n.attr(`ry`,t.ry),t.attrs!==void 0)for(let e in t.attrs)n.attr(e,t.attrs[e]);return t.class&&n.attr(`class`,t.class),n},`drawRect`),o=t((e,t)=>{a(e,{x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,stroke:t.stroke,class:`rect`}).lower()},`drawBackgroundRect`),s=t((e,t)=>{let r=t.text.replace(n,` `),i=e.append(`text`);i.attr(`x`,t.x),i.attr(`y`,t.y),i.attr(`class`,`legend`),i.style(`text-anchor`,t.anchor),t.class&&i.attr(`class`,t.class);let a=i.append(`tspan`);return a.attr(`x`,t.x+t.textMargin*2),a.text(r),i},`drawText`),c=t((e,t,n,r)=>{let a=e.append(`image`);a.attr(`x`,t),a.attr(`y`,n);let o=(0,i.sanitizeUrl)(r);a.attr(`xlink:href`,o)},`drawImage`),l=t((e,t,n,r)=>{let a=e.append(`use`);a.attr(`x`,t),a.attr(`y`,n);let o=(0,i.sanitizeUrl)(r);a.attr(`xlink:href`,`#${o}`)},`drawEmbeddedImage`),u=t(()=>({x:0,y:0,width:100,height:100,fill:`#EDF2AE`,stroke:`#666`,anchor:`start`,rx:0,ry:0}),`getNoteRect`),d=t(()=>({x:0,y:0,width:100,height:100,"text-anchor":`start`,style:`#666`,textMargin:0,rx:0,ry:0,tspan:!0}),`getTextObj`),f=t(()=>{let t=e(`.mermaidTooltip`);return t.empty()&&(t=e(`body`).append(`div`).attr(`class`,`mermaidTooltip`).style(`opacity`,0).style(`position`,`absolute`).style(`text-align`,`center`).style(`max-width`,`200px`).style(`padding`,`2px`).style(`font-size`,`12px`).style(`background`,`#ffffde`).style(`border`,`1px solid #333`).style(`border-radius`,`2px`).style(`pointer-events`,`none`).style(`z-index`,`100`)),t},`createTooltip`);export{a,d as c,c as i,o as n,s as o,l as r,u as s,f as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-J5ZVWO5B-oDCd-gWO.js b/frontend/dist/assets/chunk-J5ZVWO5B-oDCd-gWO.js new file mode 100644 index 0000000..5dfe2fe --- /dev/null +++ b/frontend/dist/assets/chunk-J5ZVWO5B-oDCd-gWO.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=new Set([`redux-color`,`redux-dark-color`]),n=12,r=64,i=e(e=>Array.isArray(e)&&e.length>0,`hasPalette`),a=e((e,n)=>e!=null&&t.has(e)&&i(n),`isColorTheme`),o=/^[\w-]+$/,s=e(e=>{let t=typeof e==`string`||typeof e==`number`?String(e):``;return o.test(t)?t:`classic`},`safeLook`),c=e(e=>i(e)?e.length:0,`paletteSlotCount`),l=e((e,t)=>i(t)?c(t):typeof e==`number`&&Number.isInteger(e)&&e>0&&e<=r?e:n,`colorSlotCount`),u=e((e,t,n,r)=>{if(t===void 0||!a(n,r))return;let i=t%c(r);e.attr(`data-color-id`,`color-${i}`)},`stampColorSlot`);export{c as a,a as i,l as n,s as o,i as r,u as s,t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-JWPE2WC7-DVXcaiue.js b/frontend/dist/assets/chunk-JWPE2WC7-DVXcaiue.js new file mode 100644 index 0000000..89f16f4 --- /dev/null +++ b/frontend/dist/assets/chunk-JWPE2WC7-DVXcaiue.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";function t(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}e(t,`populateCommonDb`);export{t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-MBY4JIJT-CGQ6Fu8G.js b/frontend/dist/assets/chunk-MBY4JIJT-CGQ6Fu8G.js new file mode 100644 index 0000000..fc924e7 --- /dev/null +++ b/frontend/dist/assets/chunk-MBY4JIJT-CGQ6Fu8G.js @@ -0,0 +1,72 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,F as i,b as a,s as o,z as s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as c}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{n as l,t as u}from"./chunk-742MDFTN-5mFByRwZ.js";function d(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var f=d();function p(e){f=e}var m={exec:()=>null};function h(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(_.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var g=(()=>{try{return!0}catch{return!1}})(),_={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,`i`)},ee=/^(?:[ \t]*(?:\n|$))+/,te=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,ne=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,v=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,re=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,y=/(?:[*+-]|\d{1,9}[.)])/,ie=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,ae=h(ie).replace(/bull/g,y).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),oe=h(ie).replace(/bull/g,y).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),b=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,se=/^[^\n]+/,x=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,ce=h(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,x).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),le=h(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,y).getRegex(),S=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,C=/|$))/,ue=h(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,C).replace(`tag`,S).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),de=h(b).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex(),w={blockquote:h(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,de).getRegex(),code:te,def:ce,fences:ne,heading:re,hr:v,html:ue,lheading:ae,list:le,newline:ee,paragraph:de,table:m,text:se},fe=h(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex(),pe={...w,lheading:oe,table:fe,paragraph:h(b).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,fe).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex()},me={...w,html:h(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,C).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:m,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:h(b).replace(`hr`,v).replace(`heading`,` *#{1,6} *[^ +]`).replace(`lheading`,ae).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},he=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,ge=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,_e=/^( {2,}|\\)\n(?!\s*$)/,ve=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,g?"(?`+)[^`]+\k(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),Te=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,Ee=h(Te,`u`).replace(/punct/g,T).getRegex(),De=h(Te,`u`).replace(/punct/g,xe).getRegex(),Oe=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,ke=h(Oe,`gu`).replace(/notPunctSpace/g,ye).replace(/punctSpace/g,E).replace(/punct/g,T).getRegex(),Ae=h(Oe,`gu`).replace(/notPunctSpace/g,Ce).replace(/punctSpace/g,Se).replace(/punct/g,xe).getRegex(),je=h(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,ye).replace(/punctSpace/g,E).replace(/punct/g,T).getRegex(),Me=h(/\\(punct)/,`gu`).replace(/punct/g,T).getRegex(),Ne=h(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Pe=h(C).replace(`(?:-->|$)`,`-->`).getRegex(),Fe=h(`^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^`).replace(`comment`,Pe).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),D=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,Ie=h(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace(`label`,D).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Le=h(/^!?\[(label)\]\[(ref)\]/).replace(`label`,D).replace(`ref`,x).getRegex(),Re=h(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,x).getRegex(),ze=h(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,Le).replace(`nolink`,Re).getRegex(),Be=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,O={_backpedal:m,anyPunctuation:Me,autolink:Ne,blockSkip:we,br:_e,code:ge,del:m,emStrongLDelim:Ee,emStrongRDelimAst:ke,emStrongRDelimUnd:je,escape:he,link:Ie,nolink:Re,punctuation:be,reflink:Le,reflinkSearch:ze,tag:Fe,text:ve,url:m},Ve={...O,link:h(/^!?\[(label)\]\((.*?)\)/).replace(`label`,D).getRegex(),reflink:h(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,D).getRegex()},k={...O,emStrongRDelimAst:Ae,emStrongLDelim:De,url:h(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`protocol`,Be).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:h(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":`>`,'"':`"`,"'":`'`},We=e=>Ue[e];function M(e,t){if(t){if(_.escapeTest.test(e))return e.replace(_.escapeReplace,We)}else if(_.escapeTestNoEncode.test(e))return e.replace(_.escapeReplaceNoEncode,We);return e}function Ge(e){try{e=encodeURI(e).replace(_.percentDecode,`%`)}catch{return null}return e}function Ke(e,t){let n=e.replace(_.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(_.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t){if(n.length>t)n.splice(t);else for(;n.length0?-2:-1}function Je(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`);r.state.inLink=!0;let c={type:e[0].charAt(0)===`!`?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:r.inlineTokens(s)};return r.state.inLink=!1,c}function Ye(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(` +`).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return r.length>=i.length?e.slice(i.length):e}).join(` +`)}var P=class{options;rules;lexer;constructor(e){this.options=e||f}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=t[0].replace(this.rules.other.codeRemoveIndent,``);return{type:`code`,raw:t[0],codeBlockStyle:`indented`,text:this.options.pedantic?e:N(e,` +`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=Ye(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=N(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:N(t[0],` +`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=N(t[0],` +`).split(` +`),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o;for(o=0;o1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=t[2].split(` +`,1)[0].replace(this.rules.other.listReplaceTabs,e=>` `.repeat(3*e.length)),l=e.split(` +`,1)[0],u=!c.trim(),d=0;if(this.options.pedantic?(d=2,s=c.trimStart()):u?d=t[1].length+1:(d=t[2].search(this.rules.other.nonSpaceChar),d=d>4?1:d,s=c.slice(d),d+=t[1].length),u&&this.rules.other.blankLine.test(l)&&(r+=l+` +`,e=e.substring(l.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(d),n=this.rules.other.hrRegex(d),i=this.rules.other.fencesBeginRegex(d),a=this.rules.other.headingBeginRegex(d),o=this.rules.other.htmlBeginRegex(d);for(;e;){let f=e.split(` +`,1)[0],p;if(l=f,this.options.pedantic?(l=l.replace(this.rules.other.listReplaceNesting,` `),p=l):p=l.replace(this.rules.other.tabCharGlobal,` `),i.test(l)||a.test(l)||o.test(l)||t.test(l)||n.test(l))break;if(p.search(this.rules.other.nonSpaceChar)>=d||!l.trim())s+=` +`+p.slice(d);else{if(u||c.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(c)||a.test(c)||n.test(c))break;s+=` +`+l}!u&&!l.trim()&&(u=!0),r+=f+` +`,e=e.substring(f.length+1),c=p.slice(d)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0));let f=null,p;this.options.gfm&&(f=this.rules.other.listIsTask.exec(s),f&&(p=f[0]!==`[ ] `,s=s.replace(this.rules.other.listReplaceTask,``))),i.items.push({type:`list_item`,raw:r,task:!!f,checked:p,loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e=0;ee.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}if(i.loose)for(let e=0;e({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t)return{type:`heading`,raw:t[0],depth:t[2].charAt(0)===`=`?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;let t=N(e.slice(0,-1),`\\`);if((e.length-t.length)%2==0)return}else{let e=qe(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let n=t[2],r=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):``;return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?n.slice(1):n.slice(1,-1)),Je(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,`$1`),title:r&&r.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let e=t[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `).toLowerCase()];if(!e){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return Je(n,e,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[2])||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=0,c=r[0][0]===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+n);(r=c.exec(t))!=null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i)continue;if(a=[...i].length,r[3]||r[4]){o+=a;continue}if((r[5]||r[6])&&n%3&&!((n+a)%3)){s+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o+s);let t=[...r[0]][0].length,c=e.slice(0,n+r.index+t+a);if(Math.min(n,a)%2){let e=c.slice(1,-1);return{type:`em`,raw:c,text:e,tokens:this.lexer.inlineTokens(e)}}let l=c.slice(2,-2);return{type:`strong`,raw:c,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e){let t=this.rules.inline.del.exec(e);if(t)return{type:`del`,raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:t[0],escaped:e}}}},F=class e{tokens;options;state;tokenizer;inlineQueue;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||f,this.options.tokenizer=this.options.tokenizer||new P,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let t={other:_,block:A.normal,inline:j.normal};this.options.pedantic?(t.block=A.pedantic,t.inline=j.pedantic):this.options.gfm&&(t.block=A.gfm,t.inline=this.options.breaks?j.breaks:j.gfm),this.tokenizer.rules=t}static get rules(){return{block:A,inline:j}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(_.carriageReturn,` +`),this.blockTokens(e,this.tokens);for(let e=0;e(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.space(e)){e=e.substring(r.raw.length);let n=t.at(-1);r.raw.length===1&&n!==void 0?n.raw+=` +`:t.push(r);continue}if(r=this.tokenizer.code(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.text,this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(r=this.tokenizer.fences(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.heading(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.hr(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.blockquote(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.list(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.html(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.def(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title},t.push(r));continue}if(r=this.tokenizer.table(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.lheading(e)){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startBlock){let t=1/0,n=e.slice(1),r;this.options.extensions.startBlock.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i))){let a=t.at(-1);n&&a?.type===`paragraph`?(a.raw+=(a.raw.endsWith(` +`)?``:` +`)+r.raw,a.text+=` +`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=a.text):t.push(r),n=i.length!==e.length,e=e.substring(r.raw.length);continue}if(r=this.tokenizer.text(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n=e,r=null;if(this.tokens.links){let e=Object.keys(this.tokens.links);if(e.length>0)for(;(r=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)e.includes(r[0].slice(r[0].lastIndexOf(`[`)+1,-1))&&(n=n.slice(0,r.index)+`[`+`a`.repeat(r[0].length-2)+`]`+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(r=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,r.index)+`++`+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let i;for(;(r=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)i=r[2]?r[2].length:0,n=n.slice(0,r.index+i)+`[`+`a`.repeat(r[0].length-i-2)+`]`+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let a=!1,o=``;for(;e;){a||(o=``),a=!1;let r;if(this.options.extensions?.inline?.some(n=>(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.escape(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.tag(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.link(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(r.raw.length);let n=t.at(-1);r.type===`text`&&n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(r=this.tokenizer.emStrong(e,n,o)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.codespan(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.br(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.del(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.autolink(e)){e=e.substring(r.raw.length),t.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(e))){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(r=this.tokenizer.inlineText(i)){e=e.substring(r.raw.length),r.raw.slice(-1)!==`_`&&(o=r.raw.slice(-1)),a=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw Error(t)}}return t}},I=class{options;parser;constructor(e){this.options=e||f}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(_.notSpaceStart)?.[0],i=e.replace(_.endingNewline,``)+` +`;return r?`

`+(n?i:M(i,!0))+`
+`:`
`+(n?i:M(i,!0))+`
+`}blockquote({tokens:e}){return`
+${this.parser.parse(e)}
+`}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`${this.parser.parseInline(e)} +`}hr(e){return`
+`}list(e){let t=e.ordered,n=e.start,r=``;for(let t=0;t +`+r+` +`}listitem(e){let t=``;if(e.task){let n=this.checkbox({checked:!!e.checked});e.loose?e.tokens[0]?.type===`paragraph`?(e.tokens[0].text=n+` `+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&e.tokens[0].tokens[0].type===`text`&&(e.tokens[0].tokens[0].text=n+` `+M(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:`text`,raw:n+` `,text:n+` `,escaped:!0}):t+=n+` `}return t+=this.parser.parse(e.tokens,!!e.loose),`
  • ${t}
  • +`}checkbox({checked:e}){return``}paragraph({tokens:e}){return`

    ${this.parser.parseInline(e)}

    +`}table(e){let t=``,n=``;for(let t=0;t${r}`,` + +`+t+` +`+r+`
    +`}tablerow({text:e}){return` +${e} +`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+` +`}strong({tokens:e}){return`${this.parser.parseInline(e)}`}em({tokens:e}){return`${this.parser.parseInline(e)}`}codespan({text:e}){return`${M(e,!0)}`}br(e){return`
    `}del({tokens:e}){return`${this.parser.parseInline(e)}`}link({href:e,title:t,tokens:n}){let r=this.parser.parseInline(n),i=Ge(e);if(i===null)return r;e=i;let a=`
    `+r+``,a}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=Ge(e);if(i===null)return M(n);e=i;let a=`${n}`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:M(e.text)}},L=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}},R=class e{options;renderer;textRenderer;constructor(e){this.options=e||f,this.options.renderer=this.options.renderer||new I,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new L}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e,t=!0){let n=``;for(let r=0;r{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new I(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new P(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new z;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];t[r]=z.passThroughHooks.has(n)?e=>{if(this.defaults.async&&z.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return F.lex(e,t??this.defaults)}parser(e,t){return R.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer():e?F.lex:F.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser():e?R.parse:R.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer():e?F.lex:F.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser():e?R.parse:R.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=` +Please report this to https://github.com/markedjs/marked.`,e){let e=`

    An error occurred:

    `+M(n.message+``,!0)+`
    `;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}};function V(e,t){return B.parse(e,t)}V.options=V.setOptions=function(e){return B.setOptions(e),V.defaults=B.defaults,p(V.defaults),V},V.getDefaults=d,V.defaults=f,V.use=function(...e){return B.use(...e),V.defaults=B.defaults,p(V.defaults),V},V.walkTokens=function(e,t){return B.walkTokens(e,t)},V.parseInline=B.parseInline,V.Parser=R,V.parser=R.parse,V.Renderer=I,V.TextRenderer=L,V.Lexer=F,V.lexer=F.lex,V.Tokenizer=P,V.Hooks=z,V.parse=V,V.options,V.setOptions,V.use,V.walkTokens,V.parseInline,R.parse,F.lex;function Xe(e){var t=[...arguments].slice(1),n=Array.from(typeof e==`string`?[e]:e);n[n.length-1]=n[n.length-1].replace(/\r?\n([\t ]*)$/,``);var r=n.reduce(function(e,t){var n=t.match(/\n([\t ]+|(?!\s).)/g);return n?e.concat(n.map(function(e){return e.match(/[\t ]/g)?.length??0})):e},[]);if(r.length){var i=RegExp(` +[ ]{${Math.min.apply(Math,r)}}`,`g`);n=n.map(function(e){return e.replace(i,` +`)})}n[0]=n[0].replace(/^\r?\n/,``);var a=n[0];return t.forEach(function(e,t){var r=a.match(/(?:^|\n)( *)$/),i=r?r[1]:``,o=e;typeof e==`string`&&e.includes(` +`)&&(o=String(e).split(` +`).map(function(e,t){return t===0?e:`${i}${e}`}).join(` +`)),a+=o+n[t+1]}),a}var H=typeof performance<`u`&&typeof performance.now==`function`,U=n(()=>H?performance.now():0,`now`),W=`🧜 `,Ze=`Mermaid render`,Qe=`Mermaid`,$e={parse:`tertiary`,prepare:`secondary`,measure:`primary`,layout:`primary-dark`,layoutCore:`error`,draw:`primary-light`,paint:`secondary-dark`,serialize:`tertiary-dark`,render:`primary-light`};(class{constructor(){this.enabled=!1,this.autoPrint=!0,this.records=[],this.maxRecords=200,this.roots=[],this.stack=[],this.buckets={}}static{n(this,`Profiler`)}enable(){return this.enabled=!0,this}disable(){return this.enabled=!1,this}start(e){this.enabled&&(this.roots=[],this.stack=[],this.buckets={},this.begin(e))}tickSync(e,t){if(!this.enabled)return t();let n=U();try{return t()}finally{this.buckets[e]=(this.buckets[e]??0)+(U()-n)}}async tick(e,t){if(!this.enabled)return t();let n=U();try{return await t()}finally{this.buckets[e]=(this.buckets[e]??0)+(U()-n)}}stop(){if(!this.enabled)return;for(;this.stack.length>0;)this.end();let e=this.roots.at(-1),t=this.runLabel??e?.name;return e&&(this.records.push({label:t??e.name,tree:e,buckets:{...this.buckets}}),this.records.length>this.maxRecords&&this.records.splice(0,this.records.length-this.maxRecords),this.autoPrint&&this.printSummary(e,t)),this.runLabel=void 0,e}begin(e){if(!this.enabled)return;let t={name:e,start:U(),duration:-1,children:[]},n=this.stack.at(-1);if(n?n.children.push(t):this.roots.push(t),this.stack.push(t),H&&typeof performance.mark==`function`)try{performance.mark(`${W}${e} \u25B6`)}catch{}}end(){if(!this.enabled)return;let e=this.stack.pop();if(!e)return;let t=U();if(e.duration=t-e.start,H&&typeof performance.measure==`function`)try{performance.measure(`${W}${e.name}`,{start:e.start,end:t,detail:{devtools:{dataType:`track-entry`,track:Ze,trackGroup:Qe,color:$e[e.name]??`primary`,tooltipText:`${e.name} \u2014 ${e.duration.toFixed(1)} ms`}}})}catch{}}async span(e,t){if(!this.enabled)return t();this.begin(e);try{return await t()}finally{this.end()}}report(){return this.records.at(-1)?.tree??this.roots.at(-1)}clear(){this.records.length=0,this.roots=[],this.stack=[],this.runLabel=void 0}reset(){this.roots=[],this.stack=[]}printSummary(e=this.report(),t){if(!e)return;let r=e.duration,i=t&&t!==e.name?`${e.name} [${t}]`:e.name,a=[`ms % phase`],o=n((e,t)=>{let n=` `.repeat(t),i=e.duration.toFixed(1).padStart(8),s=r>0?`${(e.duration/r*100).toFixed(0).padStart(3)}%`:` -`;a.push(`${i} ${s} ${n}${e.name}`);for(let n of e.children)o(n,t+1);if(e.children.length>0){let t=e.children.reduce((e,t)=>e+t.duration,0),r=e.duration-t;if(r>.5){let e=r.toFixed(1).padStart(8);a.push(`${e} ${n} (self)`)}}},`walk`);o(e,0);let s=Object.keys(this.buckets);if(s.length>0){a.push(`—— buckets (summed) ——`);for(let e of s)a.push(`${this.buckets[e].toFixed(1).padStart(8)} ${e}`)}console.log(`${W}mermaid render profile \xB7 ${i} +${a.join(` +`)}`)}}),globalThis.injected??={includeLargeFeatures:!0,profiling:!1,version:`0.0.0`};function et(e,{markdownAutoWrap:t}){return Xe(e.replace(//g,` +`).replace(/\n{2,}/g,` +`))}n(et,`preprocessMarkdown`);function tt(e){return e.split(/\\n|\n|/gi).map(e=>e.trim().match(/<[^>]+>|[^\s<>]+/g)?.map(e=>({content:e,type:`normal`}))??[])}n(tt,`nonMarkdownToLines`);function G(e,t={}){let r=et(e,t),i=V.lexer(r),a=[[]],o=0;function s(e,t=`normal`){e.type===`text`?e.text.split(` +`).forEach((e,n)=>{n!==0&&(o++,a.push([])),e.split(` `).forEach(e=>{e=e.replace(/'/g,`'`),e&&a[o].push({content:e,type:t})})}):e.type===`strong`||e.type===`em`?e.tokens.forEach(t=>{s(t,e.type)}):e.type===`html`&&a[o].push({content:e.text,type:`normal`})}return n(s,`processNode`),i.forEach(e=>{e.type===`paragraph`?e.tokens?.forEach(e=>{s(e)}):e.type===`html`?a[o].push({content:e.text,type:`normal`}):a[o].push({content:e.raw,type:`normal`})}),a}n(G,`markdownToLines`);function nt(e){return e?`

    ${e.replace(/\\n|\n/g,`
    `)}

    `:``}n(nt,`nonMarkdownToHTML`);function rt(t,{markdownAutoWrap:r}={}){let i=V.lexer(t);function a(t){return t.type===`text`?r===!1?t.text.replace(/\n */g,`
    `).replace(/ /g,` `):t.text.replace(/\n */g,`
    `):t.type===`strong`?`${t.tokens?.map(a).join(``)}`:t.type===`em`?`${t.tokens?.map(a).join(``)}`:t.type===`paragraph`?`

    ${t.tokens?.map(a).join(``)}

    `:t.type===`space`?``:t.type===`html`?`${t.text}`:t.type===`escape`?t.text:(e.warn(`Unsupported markdown: ${t.type}`),t.raw)}return n(a,`output`),i.map(a).join(``)}n(rt,`markdownToHTML`);var it=(function(e){var t=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.msRequestAnimationFrame||function(e){return setTimeout(e,16)};function r(){var n=this;n.reads=[],n.writes=[],n.raf=t.bind(e)}n(r,`FastDom`),r.prototype={constructor:r,runTasks:n(function(e){for(var t;t=e.shift();)t()},`runTasks`),measure:n(function(e,t){var n=t?e.bind(t):e;return this.reads.push(n),i(this),n},`measure`),mutate:n(function(e,t){var n=t?e.bind(t):e;return this.writes.push(n),i(this),n},`mutate`),clear:n(function(e){return o(this.reads,e)||o(this.writes,e)},`clear`),extend:n(function(e){if(typeof e!=`object`)throw Error(`expected object`);var t=Object.create(this);return s(t,e),t.fastdom=this,t.initialize&&t.initialize(),t},`extend`),catch:null};function i(e){e.scheduled||(e.scheduled=!0,e.raf(a.bind(null,e)))}n(i,`scheduleFlush`);function a(e){var t=e.writes,n=e.reads,r;try{n.length,e.runTasks(n),t.length,e.runTasks(t)}catch(e){r=e}if(e.scheduled=!1,(n.length||t.length)&&i(e),r){if(r.message,e.catch)e.catch(r);else throw r}}n(a,`flush`);function o(e,t){var n=e.indexOf(t);return!!~n&&!!e.splice(n,1)}n(o,`remove`);function s(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])}return n(s,`mixin`),e.fastdom=e.fastdom||new r})(typeof window<`u`?window:globalThis),at={initialize:n(function(){this._tasks=new Map},`initialize`),mutate:n(function(e,t){return K(this,`mutate`,e,t)},`mutate`),measure:n(function(e,t){return K(this,`measure`,e,t)},`measure`),clear:n(function(e){var t=this._tasks,n=t.get(e);this.fastdom.clear(n),t.delete(e)},`clear`)};function K(e,t,n,r){var i=e._tasks,a=e.fastdom,o,s=new Promise(function(e,c){o=a[t](function(){i.delete(s);try{e(r?n.call(r):n())}catch(e){c(e)}},r)});return i.set(s,o),s}n(K,`create`);var{initialize:ot,mutate:st,measure:ct,clear:lt}=at,ut=at,dt=it.extend({raf(e){typeof queueMicrotask==`function`?queueMicrotask(e):setTimeout(e,0)}}).extend(ut);function ft(e){return Intl.Segmenter?[...new Intl.Segmenter().segment(e)].map(e=>e.segment):[...e]}n(ft,`splitTextToChars`);function pt(e,t){return q(e,[],ft(t.content),t.type)}n(pt,`splitWordToFitWidth`);function q(e,t,n,r){if(n.length===0)return[{content:t.join(``),type:r},{content:``,type:r}];let[i,...a]=n,o=[...t,i];return e([{content:o.join(``),type:r}])?q(e,o,a,r):(t.length===0&&i&&(t.push(i),n.shift()),[{content:t.join(``),type:r},{content:n.join(``),type:r}])}n(q,`splitWordToFitWidthRecursion`);function mt(e,t){if(e.some(({content:e})=>e.includes(` +`)))throw Error(`splitLineToFitWidth does not support newlines in the line`);return J(e,t)}n(mt,`splitLineToFitWidth`);function J(e,t,n=[],r=[]){if(e.length===0)return r.length>0&&n.push(r),n.length>0?n:[];let i=``;e[0].content===` `&&(i=` `,e.shift());let a=e.shift()??{content:` `,type:`normal`},o=[...r];if(i!==``&&o.push({content:i,type:`normal`}),o.push(a),t(o))return J(e,t,n,o);if(r.length>0)n.push(r),e.unshift(a);else if(a.content){let[r,i]=pt(t,a);n.push([r]),i.content&&e.unshift(i)}return J(e,t,n)}n(J,`splitLineToFitWidthRecursion`);function Y(e,t){t&&e.attr(`style`,t)}n(Y,`applyStyle`);var ht=16384;async function X(e,t,n,c,l=!1,u=a(),d=0){let f=e.append(`foreignObject`);f.attr(`width`,`${Math.min(10*n,ht)}px`),f.attr(`height`,`${Math.min(10*n,ht)}px`);let p=f.append(`xhtml:div`),m=r(t.label)?await i(t.label.replace(o.lineBreakRegex,` +`),u):s(t.label,u),h=t.isNode?`nodeLabel`:`edgeLabel`,g=p.append(`span`);g.html(m),Y(g,t.labelStyle),g.attr(`class`,`${h} ${c}`),Y(p,t.labelStyle),p.style(`display`,`table-cell`),p.style(`white-space`,`nowrap`),p.style(`line-height`,`1.5`),n!==1/0&&(p.style(`max-width`,n+`px`),p.style(`text-align`,`center`)),p.attr(`xmlns`,`http://www.w3.org/1999/xhtml`),l&&p.attr(`class`,`labelBkg`);let _=await dt.measure(()=>p.node().getBoundingClientRect());return _.width===n?(p.style(`display`,`table`),p.style(`white-space`,`break-spaces`),p.style(`width`,n+`px`)):_.widthgt(s,o,t)<=e,`checkWidth`),i=r(t)?[t]:mt(t,r);for(let e of i)$(Z(l,u,o,a),e),u++}if(i){let e=l.node().getBBox();return c.attr(`x`,e.x-2).attr(`y`,e.y-2).attr(`width`,e.width+4).attr(`height`,e.height+4),s.node()}return l.node()}n(vt,`createFormattedText`);function Q(e){return e.replace(/&(amp|lt|gt);/g,(e,t)=>{switch(t){case`amp`:return`&`;case`lt`:return`<`;case`gt`:return`>`;default:return e}})}n(Q,`decodeHTMLEntities`);function $(e,t){e.text(``),t.forEach((t,n)=>{let r=e.append(`tspan`).attr(`font-style`,t.type===`em`?`italic`:`normal`).attr(`class`,`text-inner-tspan`).attr(`font-weight`,t.type===`strong`?`bold`:`normal`);n===0?r.text(Q(t.content)):r.text(` `+Q(t.content))})}n($,`updateTextContentAndStyles`);async function yt(e,t={}){let n=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(e,r,i)=>(n.push((async()=>{let n=`${r}:${i}`;return await l(n)?await u(n,void 0,{class:`label-icon`}):``})()),e));let r=await Promise.all(n);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>r.shift()??``)}n(yt,`replaceIconSubstring`);var bt=n(async(n,i=``,{style:a=``,isTitle:o=!1,classes:s=``,useHtmlLabels:l=!0,markdown:u=!0,isNode:d=!0,width:f=200,minWidth:p=0,addSvgBackground:m=!1}={},h)=>{if(e.debug(`XYZ createText`,i,a,o,s,l,d,`addSvgBackground: `,m),l){let e=u?rt(i,h):nt(i),t=await yt(c(e),h),o=i.replace(/\\\\/g,`\\`);return await X(n,{isNode:d,label:r(i)?o:t,labelStyle:a.replace(`fill:`,`color:`)},f,s,m,h,p)}{let e=c(i.replace(//g,`
    `)),r=vt(f,n,u?G(e.replace(`
    `,`
    `),h):tt(e),i?m:!1,!d);if(d){/stroke:/.exec(a)&&(a=a.replace(`stroke:`,`lineColor:`));let e=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/color:/g,`fill:`);t(r).attr(`style`,e)}else{let e=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/background:/g,`fill:`);t(r).select(`rect`).attr(`style`,e.replace(/background:/g,`fill:`));let n=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/color:/g,`fill:`);t(r).select(`text`).attr(`style`,n)}return o?t(r).selectAll(`tspan.text-outer-tspan`).classed(`title-row`,!0):t(r).selectAll(`tspan.text-outer-tspan`).classed(`row`,!0),r}},`createText`);export{Xe as a,G as i,bt as n,dt as r,_t as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-NETBCI7D-Br7cqgBT.js b/frontend/dist/assets/chunk-NETBCI7D-Br7cqgBT.js new file mode 100644 index 0000000..9960acf --- /dev/null +++ b/frontend/dist/assets/chunk-NETBCI7D-Br7cqgBT.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as t}from"./index-DoQkmpth.js";var n=5,r=1e-5,i=2,a=.6,o=1e-6;function s(e){let t=[];for(let n=0;n=1-o||p<=o||p>=1-o?null:{point:{x:e.x+f*i,y:e.y+f*a},tA:f,tB:p}}e(c,`segmentIntersection`);function l(e){return Math.abs(e.b.x-e.a.x)>=Math.abs(e.b.y-e.a.y)}e(l,`isHorizontalSeg`);function u(e,t,r){if(e.curve!==`rounded`)return!1;let i=e.points,a=i[t],o=i[t+1];if(!a||!o)return!1;let s=Math.hypot(o.x-a.x,o.y-a.y),c=r*s,l=t>0?_(i[t-1],a,o,n):null;if(l&&c=Math.abs(n)?+(t>=0):+(n>=0)}e(m,`getArcSweepFlag`);function h(e,n){if(e.length<2)return e.map(e=>({...e}));let r=e.map(e=>({...e})),i=n.arrowTypeStart&&t[n.arrowTypeStart];if(i){let t=e[0],n=e[1],a=Math.atan2(n.y-t.y,n.x-t.x);r[0].x=t.x+i*Math.cos(a),r[0].y=t.y+i*Math.sin(a)}let a=n.arrowTypeEnd&&t[n.arrowTypeEnd];if(a){let t=e.length,n=e[t-2],i=e[t-1],o=Math.atan2(i.y-n.y,i.x-n.x);r[t-1].x=i.x-a*Math.cos(o),r[t-1].y=i.y-a*Math.sin(o)}return r}e(h,`applyMarkerOffsets`);function g(e,t,n,r,i){let a=e.point.x,o=e.point.y,s={x:a-t*e.r,y:o-n*e.r},c={x:a+t*e.r,y:o+n*e.r},l=[`L${p(s)}`];return i===`arc`?l.push(`A${f(e.r)},${f(e.r)} 0 0 ${r} ${p(c)}`):l.push(`M${p(c)}`),l}e(g,`emitJump`);function _(e,t,n,i){let a=t.x-e.x,o=t.y-e.y,s=n.x-t.x,c=n.y-t.y,l=Math.hypot(a,o),u=Math.hypot(s,c);if(l0){let t=_(c[e-1],c[e],c[e+1]??c[e],n);t&&(b=t.cutLen)}let x=o,S=null;l&&ee.t-t.t).filter(e=>{let t=Math.min(e.d-b,x-e.d)-i;return e.r=Math.min(e.r,t),e.r>=C});for(let e=0;et){let n=t/2;w[e].r=Math.min(w[e].r,n),w[e+1].r=Math.min(w[e+1].r,n)}}for(let e of w)e.r=2?r:null}catch{return null}}e(x,`decodeDataPoints`);function S(e,t,n){if(!n.enabled)return;let r=e.node();if(!r)return;let i=new Map;for(let e of t)i.set(e.id,e);let a=new Map;for(let e of r.querySelectorAll(`path[data-id]`)){let t=e.getAttribute(`data-id`);t!==null&&!a.has(t)&&a.set(t,e)}let o=[];for(let e of t){let t=a.get(e.id);if(!t)continue;let n=x(t.getAttribute(`data-points`))??e.points;o.push({...e,points:n})}let s=d(o);if(s.length===0)return;let c=new Map;for(let e of s){let t=c.get(e.jumpEdgeId)??[];t.push(e),c.set(e.jumpEdgeId,t)}for(let e of o){let t=c.get(e.id);if(!t||t.length===0)continue;let r=i.get(e.id)?.curve;if(r!==void 0&&!b(r))continue;let o=a.get(e.id);if(!o||r===void 0&&!y(o.getAttribute(`d`)??``))continue;let s=o.getAttribute(`style`)??``,l=/stroke-dasharray\s*:\s*0\s+([\d.]+)\s+[\d.]+\s+([\d.]+)/.exec(s),u=l?Number.parseFloat(l[1]):null,d=l?Number.parseFloat(l[2]):null,f=v(e,t,n);if(o.setAttribute(`d`,f),u!==null&&d!==null&&typeof o.getTotalLength==`function`){let e=o.getTotalLength(),t=`0 ${u} ${Math.max(0,e-u-d)} ${d}`,n=s.replace(/stroke-dasharray\s*:[^;]*;?/g,`stroke-dasharray: ${t};`).replace(/;\s*;+/g,`;`);o.setAttribute(`style`,n)}}}e(S,`applyLineJumpsToSvg`);export{S as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-O7XYJQB3-Bce2lzyF.js b/frontend/dist/assets/chunk-O7XYJQB3-Bce2lzyF.js new file mode 100644 index 0000000..5a69edf --- /dev/null +++ b/frontend/dist/assets/chunk-O7XYJQB3-Bce2lzyF.js @@ -0,0 +1,128 @@ +import{h as e,m as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var i={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{let t=e/255;return e>.03928?((t+.055)/1.055)**2.4:t/12.92},hue2rgb:(e,t,n)=>(n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e),hsl2rgb:({h:e,s:t,l:n},r)=>{if(!t)return n*2.55;e/=360,t/=100,n/=100;let a=n<.5?n*(1+t):n+t-n*t,o=2*n-a;switch(r){case`r`:return i.hue2rgb(o,a,e+1/3)*255;case`g`:return i.hue2rgb(o,a,e)*255;case`b`:return i.hue2rgb(o,a,e-1/3)*255}},rgb2hsl:({r:e,g:t,b:n},r)=>{e/=255,t/=255,n/=255;let i=Math.max(e,t,n),a=Math.min(e,t,n),o=(i+a)/2;if(r===`l`)return o*100;if(i===a)return 0;let s=i-a,c=o>.5?s/(2-i-a):s/(i+a);if(r===`s`)return c*100;switch(i){case e:return((t-n)/s+(tt>n?Math.min(t,Math.max(n,e)):Math.min(n,Math.max(t,e)),round:e=>Math.round(e*1e10)/1e10},unit:{dec2hex:e=>{let t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}}},o={};for(let e=0;e<=255;e++)o[e]=a.unit.dec2hex(e);var s={ALL:0,RGB:1,HSL:2},c=class{constructor(){this.type=s.ALL}get(){return this.type}set(e){if(this.type&&this.type!==e)throw Error(`Cannot change both RGB and HSL channels at the same time`);this.type=e}reset(){this.type=s.ALL}is(e){return this.type===e}},l=new class{constructor(e,t){this.color=t,this.changed=!1,this.data=e,this.type=new c}set(e,t){return this.color=t,this.changed=!1,this.data=e,this.type.type=s.ALL,this}_ensureHSL(){let e=this.data,{h:t,s:n,l:r}=e;t===void 0&&(e.h=a.channel.rgb2hsl(e,`h`)),n===void 0&&(e.s=a.channel.rgb2hsl(e,`s`)),r===void 0&&(e.l=a.channel.rgb2hsl(e,`l`))}_ensureRGB(){let e=this.data,{r:t,g:n,b:r}=e;t===void 0&&(e.r=a.channel.hsl2rgb(e,`r`)),n===void 0&&(e.g=a.channel.hsl2rgb(e,`g`)),r===void 0&&(e.b=a.channel.hsl2rgb(e,`b`))}get r(){let e=this.data,t=e.r;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`r`))}get g(){let e=this.data,t=e.g;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`g`))}get b(){let e=this.data,t=e.b;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`b`))}get h(){let e=this.data,t=e.h;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`h`))}get s(){let e=this.data,t=e.s;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`s`))}get l(){let e=this.data,t=e.l;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`l`))}get a(){return this.data.a}set r(e){this.type.set(s.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(s.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(s.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(s.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(s.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(s.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}({r:0,g:0,b:0,a:0},`transparent`),u={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(e.charCodeAt(0)!==35)return;let t=e.match(u.re);if(!t)return;let n=t[1],r=parseInt(n,16),i=n.length,a=i%4==0,o=i>4,s=o?1:17,c=o?8:4,d=a?0:-1,f=o?255:15;return l.set({r:(r>>c*(d+3)&f)*s,g:(r>>c*(d+2)&f)*s,b:(r>>c*(d+1)&f)*s,a:a?(r&f)*s/255:1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`#${o[Math.round(t)]}${o[Math.round(n)]}${o[Math.round(r)]}${o[Math.round(i*255)]}`:`#${o[Math.round(t)]}${o[Math.round(n)]}${o[Math.round(r)]}`}},d={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{let t=e.match(d.hueRe);if(t){let[,e,n]=t;switch(n){case`grad`:return a.channel.clamp.h(parseFloat(e)*.9);case`rad`:return a.channel.clamp.h(parseFloat(e)*180/Math.PI);case`turn`:return a.channel.clamp.h(parseFloat(e)*360)}}return a.channel.clamp.h(parseFloat(e))},parse:e=>{let t=e.charCodeAt(0);if(t!==104&&t!==72)return;let n=e.match(d.re);if(!n)return;let[,r,i,o,s,c]=n;return l.set({h:d._hue2deg(r),s:a.channel.clamp.s(parseFloat(i)),l:a.channel.clamp.l(parseFloat(o)),a:s?a.channel.clamp.a(c?parseFloat(s)/100:parseFloat(s)):1},e)},stringify:e=>{let{h:t,s:n,l:r,a:i}=e;return i<1?`hsla(${a.lang.round(t)}, ${a.lang.round(n)}%, ${a.lang.round(r)}%, ${i})`:`hsl(${a.lang.round(t)}, ${a.lang.round(n)}%, ${a.lang.round(r)}%)`}},f={colors:{aliceblue:`#f0f8ff`,antiquewhite:`#faebd7`,aqua:`#00ffff`,aquamarine:`#7fffd4`,azure:`#f0ffff`,beige:`#f5f5dc`,bisque:`#ffe4c4`,black:`#000000`,blanchedalmond:`#ffebcd`,blue:`#0000ff`,blueviolet:`#8a2be2`,brown:`#a52a2a`,burlywood:`#deb887`,cadetblue:`#5f9ea0`,chartreuse:`#7fff00`,chocolate:`#d2691e`,coral:`#ff7f50`,cornflowerblue:`#6495ed`,cornsilk:`#fff8dc`,crimson:`#dc143c`,cyanaqua:`#00ffff`,darkblue:`#00008b`,darkcyan:`#008b8b`,darkgoldenrod:`#b8860b`,darkgray:`#a9a9a9`,darkgreen:`#006400`,darkgrey:`#a9a9a9`,darkkhaki:`#bdb76b`,darkmagenta:`#8b008b`,darkolivegreen:`#556b2f`,darkorange:`#ff8c00`,darkorchid:`#9932cc`,darkred:`#8b0000`,darksalmon:`#e9967a`,darkseagreen:`#8fbc8f`,darkslateblue:`#483d8b`,darkslategray:`#2f4f4f`,darkslategrey:`#2f4f4f`,darkturquoise:`#00ced1`,darkviolet:`#9400d3`,deeppink:`#ff1493`,deepskyblue:`#00bfff`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1e90ff`,firebrick:`#b22222`,floralwhite:`#fffaf0`,forestgreen:`#228b22`,fuchsia:`#ff00ff`,gainsboro:`#dcdcdc`,ghostwhite:`#f8f8ff`,gold:`#ffd700`,goldenrod:`#daa520`,gray:`#808080`,green:`#008000`,greenyellow:`#adff2f`,grey:`#808080`,honeydew:`#f0fff0`,hotpink:`#ff69b4`,indianred:`#cd5c5c`,indigo:`#4b0082`,ivory:`#fffff0`,khaki:`#f0e68c`,lavender:`#e6e6fa`,lavenderblush:`#fff0f5`,lawngreen:`#7cfc00`,lemonchiffon:`#fffacd`,lightblue:`#add8e6`,lightcoral:`#f08080`,lightcyan:`#e0ffff`,lightgoldenrodyellow:`#fafad2`,lightgray:`#d3d3d3`,lightgreen:`#90ee90`,lightgrey:`#d3d3d3`,lightpink:`#ffb6c1`,lightsalmon:`#ffa07a`,lightseagreen:`#20b2aa`,lightskyblue:`#87cefa`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#b0c4de`,lightyellow:`#ffffe0`,lime:`#00ff00`,limegreen:`#32cd32`,linen:`#faf0e6`,magenta:`#ff00ff`,maroon:`#800000`,mediumaquamarine:`#66cdaa`,mediumblue:`#0000cd`,mediumorchid:`#ba55d3`,mediumpurple:`#9370db`,mediumseagreen:`#3cb371`,mediumslateblue:`#7b68ee`,mediumspringgreen:`#00fa9a`,mediumturquoise:`#48d1cc`,mediumvioletred:`#c71585`,midnightblue:`#191970`,mintcream:`#f5fffa`,mistyrose:`#ffe4e1`,moccasin:`#ffe4b5`,navajowhite:`#ffdead`,navy:`#000080`,oldlace:`#fdf5e6`,olive:`#808000`,olivedrab:`#6b8e23`,orange:`#ffa500`,orangered:`#ff4500`,orchid:`#da70d6`,palegoldenrod:`#eee8aa`,palegreen:`#98fb98`,paleturquoise:`#afeeee`,palevioletred:`#db7093`,papayawhip:`#ffefd5`,peachpuff:`#ffdab9`,peru:`#cd853f`,pink:`#ffc0cb`,plum:`#dda0dd`,powderblue:`#b0e0e6`,purple:`#800080`,rebeccapurple:`#663399`,red:`#ff0000`,rosybrown:`#bc8f8f`,royalblue:`#4169e1`,saddlebrown:`#8b4513`,salmon:`#fa8072`,sandybrown:`#f4a460`,seagreen:`#2e8b57`,seashell:`#fff5ee`,sienna:`#a0522d`,silver:`#c0c0c0`,skyblue:`#87ceeb`,slateblue:`#6a5acd`,slategray:`#708090`,slategrey:`#708090`,snow:`#fffafa`,springgreen:`#00ff7f`,tan:`#d2b48c`,teal:`#008080`,thistle:`#d8bfd8`,transparent:`#00000000`,turquoise:`#40e0d0`,violet:`#ee82ee`,wheat:`#f5deb3`,white:`#ffffff`,whitesmoke:`#f5f5f5`,yellow:`#ffff00`,yellowgreen:`#9acd32`},parse:e=>{e=e.toLowerCase();let t=f.colors[e];if(t)return u.parse(t)},stringify:e=>{let t=u.stringify(e);for(let e in f.colors)if(f.colors[e]===t)return e}},p={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{let t=e.charCodeAt(0);if(t!==114&&t!==82)return;let n=e.match(p.re);if(!n)return;let[,r,i,o,s,c,u,d,f]=n;return l.set({r:a.channel.clamp.r(i?parseFloat(r)*2.55:parseFloat(r)),g:a.channel.clamp.g(s?parseFloat(o)*2.55:parseFloat(o)),b:a.channel.clamp.b(u?parseFloat(c)*2.55:parseFloat(c)),a:d?a.channel.clamp.a(f?parseFloat(d)/100:parseFloat(d)):1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`rgba(${a.lang.round(t)}, ${a.lang.round(n)}, ${a.lang.round(r)}, ${a.lang.round(i)})`:`rgb(${a.lang.round(t)}, ${a.lang.round(n)}, ${a.lang.round(r)})`}},m={format:{keyword:f,hex:u,rgb:p,rgba:p,hsl:d,hsla:d},parse:e=>{if(typeof e!=`string`)return e;let t=u.parse(e)||p.parse(e)||d.parse(e)||f.parse(e);if(t)return t;throw Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(s.HSL)||e.data.r===void 0?d.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?p.stringify(e):u.stringify(e)},ee=(e,t)=>{let n=m.parse(e);for(let e in t)n[e]=a.channel.clamp[e](t[e]);return m.stringify(n)},h=(e,t,n=0,r=1)=>{if(typeof e!=`number`)return ee(e,{a:t});let i=l.set({r:a.channel.clamp.r(e),g:a.channel.clamp.g(t),b:a.channel.clamp.b(n),a:a.channel.clamp.a(r)});return m.stringify(i)},g=e=>{let{r:t,g:n,b:r}=m.parse(e),i=.2126*a.channel.toLinear(t)+.7152*a.channel.toLinear(n)+.0722*a.channel.toLinear(r);return a.lang.round(i)},te=e=>g(e)>=.5,_=e=>!te(e),v=(e,t,n)=>{let r=m.parse(e),i=r[t],o=a.channel.clamp[t](i+n);return i!==o&&(r[t]=o),m.stringify(r)},y=(e,t)=>v(e,`l`,t),b=(e,t)=>v(e,`l`,-t),x=(e,t)=>{let n=m.parse(e),r={};for(let e in t)t[e]&&(r[e]=n[e]+t[e]);return ee(e,r)},ne=(e,t,n=50)=>{let{r,g:i,b:a,a:o}=m.parse(e),{r:s,g:c,b:l,a:u}=m.parse(t),d=n/100,f=d*2-1,p=o-u,ee=((f*p===-1?f:(f+p)/(1+f*p))+1)/2,g=1-ee;return h(r*ee+s*g,i*ee+c*g,a*ee+l*g,o*d+u*(1-d))},S=(e,t=100)=>{let n=m.parse(e);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,ne(n,e,t)};function re(e,t){this.v=e,this.k=t}function ie(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n`u`?null:O(BigInt.prototype.toString),Pe=typeof Symbol>`u`?null:O(Symbol.prototype.toString),E=O(Object.prototype.hasOwnProperty),Fe=O(Object.prototype.toString),D=O(RegExp.prototype.test),Ie=Le(TypeError);function O(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return ve(e,t,n)}}function Le(e){return function(){return T(e,[...arguments])}}function k(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Te;if(fe&&fe(e,null),!we(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(pe(t)||(t[r]=e),i=e)}e[i]=!0}return e}function Re(e){for(let t=0;t/g),et=w(/\${[\w\W]*/g),tt=w(/^data-[\-\w.\u00B7-\uFFFF]+$/),nt=w(/^aria-[\-\w]+$/),rt=w(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),it=w(/^(?:\w+script|data):/i),at=w(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ot=w(/^html$/i),st=w(/^[a-z][.\w]*(-[.\w]+)+$/i),ct=w(/<[/\w!]/g),lt=w(/<[/\w]/g),ut=w(/<\/no(script|embed|frames)/i),dt=w(/\/>/i),M={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},ft=[`style`,`script`,`xmp`,`iframe`,`noembed`,`noframes`,`plaintext`,`noscript`],pt=C(k({},ft)),mt=function(){let e={};return ye(ft,t=>{e[t]=w(RegExp(`])`,`i`))}),C(e)}(),ht=function(){return typeof window>`u`?null:window},gt=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},_t=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},N=function(e,t,n,r){return E(e,t)&&we(e[t])?k(r.base?A(r.base):{},e[t],r.transform):n},vt=function(e,t,n){let r=E(e,t)?e[t]:void 0;return r&&typeof r==`object`?A(r):n()};function yt(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ht(),t=e=>yt(e);if(t.version=`3.4.16`,t.removed=[],!e||!e.document||e.document.nodeType!==M.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=j(d,`cloneNode`),p=j(d,`remove`),m=j(d,`removeAttributeNode`),ee=j(d,`nextSibling`),h=j(d,`childNodes`),g=j(d,`parentNode`),te=j(d,`shadowRoot`),_=j(d,`attributes`),v=o&&o.prototype?j(o.prototype,`nodeType`):null,y=o&&o.prototype?j(o.prototype,`nodeName`):null,b=o&&o.prototype?j(o.prototype,`ownerDocument`):null,x=function(e){return v?v(e):e.nodeType},ne=function(e){return y?y(e):e.nodeName};if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let S,re=``,ie,ae=!1,oe=0,se=function(){if(oe>0)throw Ie(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},ce=function(e){se(),oe++;try{return S.createHTML(e)}finally{oe--}},le=function(e){se(),oe++;try{return S.createScriptURL(e)}finally{oe--}},ue=function(){return ae||=(ie=gt(u,i),!0),ie},fe=n,pe=fe.implementation,me=fe.createNodeIterator,he=fe.createDocumentFragment,_e=fe.getElementsByTagName,ve=r.importNode,T=_t();t.isSupported=typeof de==`function`&&typeof g==`function`&&pe&&pe.createHTMLDocument!==void 0;let je=Qe,Me=$e,Ne=et,Pe=tt,Fe=nt,O=it,Le=at,Re=st,ft=rt,P=null,bt=k({},[...Ve,...He,...Ue,...Ge,...qe]),F=null,xt=k({},[...Je,...Ye,...Xe,...Ze]),I=Object.seal(ge(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),St=null,Ct=null,L=Object.seal(ge(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),wt=!0,Tt=!0,Et=!1,Dt=!0,R=!1,z=!0,B=!1,Ot=!1,V=null,H=null,U=!1,W=!1,kt=!1,At=!1,jt=!0,Mt=!1,Nt=`user-content-`,Pt=!0,Ft=!1,It={},Lt=null,Rt=k({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),zt=null,Bt=k({},[`audio`,`video`,`img`,`source`,`image`,`track`]),Vt=null,Ht=k({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Ut=`http://www.w3.org/1998/Math/MathML`,Wt=`http://www.w3.org/2000/svg`,G=`http://www.w3.org/1999/xhtml`,Gt=G,Kt=!1,qt=null,Jt=k({},[Ut,Wt,G],Ee),K=C([`mi`,`mo`,`mn`,`ms`,`mtext`]),q=k({},K),Yt=C([`annotation-xml`]),Xt=k({},Yt),Zt=k({},[`title`,`style`,`font`,`a`,`script`]),Qt=null,$t=[`application/xhtml+xml`,`text/html`],J=null,en=null,tn=n.createElement(`form`),nn=function(e){return e instanceof RegExp||e instanceof Function},rn=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(en&&en===e)return;(!e||typeof e!=`object`)&&(e={}),e=A(e),Qt=$t.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,J=Qt===`application/xhtml+xml`?Ee:Te,P=N(e,`ALLOWED_TAGS`,bt,{transform:J}),F=N(e,`ALLOWED_ATTR`,xt,{transform:J}),qt=N(e,`ALLOWED_NAMESPACES`,Jt,{transform:Ee}),Vt=N(e,`ADD_URI_SAFE_ATTR`,Ht,{transform:J,base:Ht}),zt=N(e,`ADD_DATA_URI_TAGS`,Bt,{transform:J,base:Bt}),Lt=N(e,`FORBID_CONTENTS`,Rt,{transform:J}),St=N(e,`FORBID_TAGS`,A({}),{transform:J}),Ct=N(e,`FORBID_ATTR`,A({}),{transform:J}),It=E(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?A(e.USE_PROFILES):e.USE_PROFILES:!1,wt=e.ALLOW_ARIA_ATTR!==!1,Tt=e.ALLOW_DATA_ATTR!==!1,Et=e.ALLOW_UNKNOWN_PROTOCOLS||!1,Dt=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,R=e.SAFE_FOR_TEMPLATES||!1,z=e.SAFE_FOR_XML!==!1,B=e.WHOLE_DOCUMENT||!1,W=e.RETURN_DOM||!1,kt=e.RETURN_DOM_FRAGMENT||!1,At=e.RETURN_TRUSTED_TYPE||!1,U=e.FORCE_BODY||!1,jt=e.SANITIZE_DOM!==!1,Mt=e.SANITIZE_NAMED_PROPS||!1,Pt=e.KEEP_CONTENT!==!1,Ft=e.IN_PLACE||!1,ft=Be(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:rt,Gt=typeof e.NAMESPACE==`string`?e.NAMESPACE:G,q=vt(e,`MATHML_TEXT_INTEGRATION_POINTS`,()=>k({},K)),Xt=vt(e,`HTML_INTEGRATION_POINTS`,()=>k({},Yt));let t=vt(e,`CUSTOM_ELEMENT_HANDLING`,()=>ge(null));if(I=ge(null),E(t,`tagNameCheck`)&&nn(t.tagNameCheck)&&(I.tagNameCheck=t.tagNameCheck),E(t,`attributeNameCheck`)&&nn(t.attributeNameCheck)&&(I.attributeNameCheck=t.attributeNameCheck),E(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(I.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),w(I),R&&(Tt=!1),kt&&(W=!0),It&&(P=k({},qe),F=ge(null),It.html===!0&&(k(P,Ve),k(F,Je)),It.svg===!0&&(k(P,He),k(F,Ye),k(F,Ze)),It.svgFilters===!0&&(k(P,Ue),k(F,Ye),k(F,Ze)),It.mathMl===!0&&(k(P,Ge),k(F,Xe),k(F,Ze))),L.tagCheck=null,L.attributeCheck=null,E(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?L.tagCheck=e.ADD_TAGS:we(e.ADD_TAGS)&&(P===bt&&(P=A(P)),k(P,e.ADD_TAGS,J))),E(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?L.attributeCheck=e.ADD_ATTR:we(e.ADD_ATTR)&&(F===xt&&(F=A(F)),k(F,e.ADD_ATTR,J))),E(e,`ADD_FORBID_CONTENTS`)&&we(e.ADD_FORBID_CONTENTS)&&(Lt===Rt&&(Lt=A(Lt)),k(Lt,e.ADD_FORBID_CONTENTS,J)),Pt&&(P[`#text`]=!0),B&&k(P,[`html`,`head`,`body`]),P.table&&(k(P,[`tbody`]),delete St.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw Ie(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw Ie(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=S;S=e.TRUSTED_TYPES_POLICY;try{re=ce(``)}catch(e){throw S=t,e}}else e.TRUSTED_TYPES_POLICY===null?(S=void 0,re=``):(S===void 0&&(S=ue()),S&&typeof re==`string`&&(re=ce(``)));C&&C(e),en=e},an=k({},[...He,...Ue,...We]),on=k({},[...Ge,...Ke]),sn=function(e,t,n){return t.namespaceURI===G?e===`svg`:t.namespaceURI===Ut?e===`svg`&&(n===`annotation-xml`||q[n]):!!an[e]},cn=function(e,t,n){return t.namespaceURI===G?e===`math`:t.namespaceURI===Wt?e===`math`&&Xt[n]:!!on[e]},ln=function(e,t,n){return t.namespaceURI===Wt&&!Xt[n]||t.namespaceURI===Ut&&!q[n]?!1:!on[e]&&(Zt[e]||!an[e])},un=function(e){let t=g(e);(!t||!t.tagName)&&(t={namespaceURI:Gt,tagName:`template`});let n=Te(e.tagName),r=Te(t.tagName);return qt[e.namespaceURI]?e.namespaceURI===Wt?sn(n,t,r):e.namespaceURI===Ut?cn(n,t,r):e.namespaceURI===G?ln(n,t,r):!!(Qt===`application/xhtml+xml`&&qt[e.namespaceURI]):!1},Y=function(e){Se(t.removed,{element:e});try{g(e).removeChild(e)}catch{if(p(e),!g(e))throw Ie(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},dn=function(e,t,n){try{m(e,t)}catch{try{e.removeAttribute(n)}catch{}}},fn=function(e){Z(e);let t=h(e);if(t){let e=[];ye(t,t=>{Se(e,t)}),ye(e,e=>{try{p(e)}catch{}})}let n=_(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;typeof i==`string`&&dn(e,r,i)}},X=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch{r=null}Se(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch{try{n.removeAttribute(e)}catch{}}if(e===`is`){if(W||kt)try{Y(n)}catch{}else try{n.setAttribute(e,``)}catch{}}},pn=function(e){let t=_(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;typeof i!=`string`||F[J(i)]||dn(e,r,i)}},Z=function(e){let t=[e];for(;t.length>0;){let e=t.pop();x(e)===M.element&&pn(e);let n=h(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},mn=function(e,t){return z?e===`patchsrc`||e===`for`&&t!==`label`&&t!==`output`:!1},hn=function(e){if(!z)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=x(e);if(n===M.processingInstruction||n===M.comment&&D(lt,e.data)){try{p(e)}catch{}continue}if(n===M.element){let t=e,n=J(ne(e));try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&mn(`for`,n)&&t.removeAttribute(`for`)}catch{}}let r=h(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},gn=function(e){let t=null,r=null;if(U)e=``+e;else{let t=De(e,/^[\r\n\t ]+/);r=t&&t[0]}Qt===`application/xhtml+xml`&&Gt===G&&(e=``+e+``);let i=S?ce(e):e;if(Gt===G)try{t=new l().parseFromString(i,Qt)}catch{}if(!t||!t.documentElement){t=pe.createDocument(Gt,`template`,null);try{t.documentElement.innerHTML=Kt?re:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),Gt===G?_e.call(t,B?`html`:`body`)[0]:B?t.documentElement:a},_n=function(e){let t=b?b(e):e.ownerDocument;return me.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},vn=function(e){return e=Oe(e,je,` `),e=Oe(e,Me,` `),e=Oe(e,Ne,` `),e},yn=function(e){e.normalize();let t=b?b(e):e.ownerDocument,n=me.call(t||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),r=n.nextNode();for(;r;)r.data=vn(r.data),r=n.nextNode();let i=e.querySelectorAll?.call(e,`template`);i&&ye(i,e=>{xn(e.content)&&yn(e.content)})},bn=function(e){let t=y?y(e):null;return typeof t!=`string`||J(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==_(e)||typeof e.removeAttribute!=`function`||typeof e.removeAttributeNode!=`function`||typeof e.getAttributeNode!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==v(e)||e.childNodes!==h(e)},xn=function(e){if(!v||typeof e!=`object`||!e)return!1;try{return v(e)===M.documentFragment}catch{return!1}},Q=function(e){if(!v||typeof e!=`object`||!e)return!1;try{return typeof v(e)==`number`}catch{return!1}};function $(e,n,r){e.length!==0&&ye(e,e=>{e.call(t,n,r,en)})}let Sn=function(e,t){return!!(z&&e.hasChildNodes()&&!Q(e.firstElementChild)&&D(ct,e.textContent)&&D(ct,e.innerHTML)||z&&e.namespaceURI===G&&pt[t]&&(Q(e.firstElementChild)||typeof e.textContent==`string`&&D(mt[t],e.textContent))||e.nodeType===M.processingInstruction||z&&e.nodeType===M.comment&&D(lt,e.data))},Cn=function(e,t){return e instanceof RegExp?D(e,t):e instanceof Function&&!!e(t,...[...arguments].slice(2))},wn=function(e,t,n){if(!St[t]&&An(t)&&Cn(I.tagNameCheck,t))return!1;if(Pt&&!Lt[t]){let t=g(e),r=h(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,ee(e))}}}return Y(e),!0},Tn=function(e,t,n,r){return e.length===0?t:t===n||t===r?A(t):t},En=function(e,t){return e===t||g(e)!==null?!1:(Ft&&Z(e),!0)},Dn=function(e,n){if($(T.beforeSanitizeElements,e,null),En(e,n))return!0;if(bn(e))return Y(e),!0;let r=J(ne(e));if(P=Tn(T.uponSanitizeElement,P,bt,V),$(T.uponSanitizeElement,e,{tagName:r,allowedTags:P}),En(e,n))return!0;if(Sn(e,r))return Y(e),!0;if(St[r]||!(L.tagCheck instanceof Function&&L.tagCheck(r))&&!P[r]){let t=wn(e,r,n);return t===!1&&($(T.afterSanitizeElements,e,null),En(e,n))?!0:t}if(x(e)===M.element&&!un(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&D(ut,e.innerHTML))return Y(e),!0;if(R&&e.nodeType===M.text){let n=vn(e.textContent);e.textContent!==n&&(Se(t.removed,{element:e.cloneNode()}),e.textContent=n)}return $(T.afterSanitizeElements,e,null),En(e,n)},On=function(e,t,r){if(Ct[t]||mn(t,e)||jt&&(t===`id`||t===`name`)&&(r in n||r in tn))return!1;let i=F[t]||L.attributeCheck instanceof Function&&L.attributeCheck(t,e);return Tt&&D(Pe,t)||wt&&D(Fe,t)?!0:i?Vt[t]||D(ft,Oe(r,Le,``))||(t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&ke(r,`data:`)===0&&zt[e]||Et&&!D(O,Oe(r,Le,``))?!0:!r:An(e)&&Cn(I.tagNameCheck,e)&&Cn(I.attributeNameCheck,t,e)||t===`is`&&I.allowCustomizedBuiltInElements&&Cn(I.tagNameCheck,r)},kn=k({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),An=function(e){return!kn[Te(e)]&&D(Re,e)},jn=function(e,t,n,r){if(S&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return ce(r);case`TrustedScriptURL`:return le(r)}return r},Mn=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!bn(e)||(Y(e),!1)}catch{return X(t,e),!1}},Nn=function(e,n){if($(T.beforeSanitizeAttributes,e,null),En(e,n))return;let r=e.attributes;if(!r||bn(e))return;F=Tn(T.uponSanitizeAttribute,F,xt,H);let i={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:F,forceKeepAttr:void 0},a=r.length,o=J(e.nodeName);for(;a--;){let n=r[a],s=n.name,c=n.namespaceURI,l=n.value,u=J(s),d=l,f=s===`value`?d:Ae(d),p=!1;if(i.attrName=u,i.attrValue=f,i.keepAttr=!0,i.forceKeepAttr=void 0,$(T.uponSanitizeAttribute,e,i),f=i.attrValue,Mt&&(u===`id`||u===`name`)&&ke(f,Nt)!==0&&(X(s,e,n),f=Nt+f,p=!0),z&&D(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){X(s,e,n);continue}if(u===`attributename`&&De(f,`href`)){X(s,e,n);continue}if(!i.forceKeepAttr){if(!i.keepAttr){X(s,e,n);continue}if(!Dt&&D(dt,f)){X(s,e,n);continue}if(R&&(f=vn(f)),!On(o,u,f)){X(s,e,n);continue}f=jn(o,u,c,f),f!==d&&Mn(e,s,c,f)&&p&&xe(t.removed)}}$(T.afterSanitizeAttributes,e,null),En(e,n)},Pn=function(e){let t=null,n=_n(e);for($(T.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if($(T.uponSanitizeShadowNode,t,null),Dn(t,e),Nn(t,e),xn(t.content)&&Pn(t.content),x(t)===M.element){let e=te(t);xn(e)&&(Fn(e),Pn(e))}$(T.afterSanitizeShadowDOM,e,null)},Fn=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){Pn(e.shadow);continue}let n=e.node,r=x(n)===M.element,i=h(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=y?y(n):null;if(typeof e==`string`&&J(e)===`template`){let e=n.content;xn(e)&&t.push({node:e,shadow:null})}}if(r){let e=te(n);xn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if(Kt=!e,Kt&&(e=``),typeof e!=`string`&&!Q(e)&&(e=ze(e),typeof e!=`string`))throw Ie(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ot?(P=V,F=H):rn(n),(T.uponSanitizeElement.length>0||T.uponSanitizeAttribute.length>0)&&(P=A(P)),T.uponSanitizeAttribute.length>0&&(F=A(F)),t.removed=[];let c=Ft&&typeof e!=`string`&&Q(e);if(c){hn(e);let t=ne(e);if(typeof t==`string`){let n=J(t);if(!P[n]||St[n])throw fn(e),Ie(`root node is forbidden and cannot be sanitized in-place`)}if(bn(e))throw fn(e),Ie(`root node is clobbered and cannot be sanitized in-place`);try{Fn(e)}catch(t){throw fn(e),t}}else if(Q(e))i=gn(``),a=i.ownerDocument.importNode(e,!0),a.nodeType===M.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Fn(i);else{if(!W&&!R&&!B&&e.indexOf(`<`)===-1)return S&&At?ce(e):e;if(i=gn(e),!i)return W?null:At?re:``}i&&U&&Y(i.firstChild);let l=c?e:i;try{let e=_n(l);for(;o=e.nextNode();)Dn(o,l),Nn(o,l),xn(o.content)&&Pn(o.content)}catch(n){throw c&&(fn(e),ye(t.removed,e=>{e.element&&Z(e.element)})),n}if(c){let n=!1;if(ye(t.removed,t=>{t.element&&(t.element===e&&(n=!0),Z(t.element))}),n)throw Ie(`a node selected for removal could not be safely returned; refusing to sanitize in place`);return R&&yn(e),e}if(W){if(R&&yn(i),kt)for(s=he.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(F.shadowroot||F.shadowrootmode)&&(s=ve.call(r,s,!0)),s}let u=B?i.outerHTML:i.innerHTML;return B&&P[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&D(ot,i.ownerDocument.doctype.name)&&(u=` +`+u),R&&(u=vn(u)),S&&At?ce(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};rn(e),Ot=!0,V=P,H=F},t.clearConfig=function(){en=null,Ot=!1,V=null,H=null,S=ie,re=``},t.isValidAttribute=function(e,t,n){en||rn({});let r=J(e),i=J(t);return On(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&E(T,e)&&Se(T[e],t)},t.removeHook=function(e,t){if(E(T,e)){if(t!==void 0){let n=be(T[e],t);return n===-1?void 0:Ce(T[e],n,1)[0]}return xe(T[e])}},t.removeHooks=function(e){E(T,e)&&(T[e]=[])},t.removeAllHooks=function(){T=_t()},t}var P=yt(),bt=`modulepreload`,F=function(e){return`/`+e},xt={},I=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?import.meta.resolve(e):new URL(e,import.meta.url).href}r=o(t.map(t=>{if(t=F(t,n),t=s(t),t in xt)return;xt[t]=!0;let r=t.endsWith(`.css`);for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}let i=document.createElement(`link`);if(i.rel=r?`stylesheet`:bt,r||(i.as=`script`),i.crossOrigin=``,i.href=t,a&&i.setAttribute(`nonce`,a),document.head.appendChild(i),r)return new Promise((e,n)=>{i.addEventListener(`load`,e),i.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},St=/^([^\S\n\r]*)-{3}\s*[\n\r](.*?)[\n\r]\1-{3}\s*[\n\r]+/s,Ct=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,L=/\s/,wt=n(e=>{let t=``,n=0,r=0;for(;rn&&L.test(e[o-1]);)o--;t+=e.slice(n,o)+` +`,n=a+1,r=n}return t+e.slice(n)},`stripAnyComments`),Tt=class extends Error{static{n(this,`UnknownDiagramError`)}constructor(e){super(e),this.name=`UnknownDiagramError`}},Et={},Dt=n(function(e,t){e=wt(e.replace(St,``).replace(Ct,``));for(let[n,{detector:r}]of Object.entries(Et))if(r(e,t))return n;throw new Tt(`No diagram type detected matching given configuration for text: ${e}`)},`detectType`),R=n((...e)=>{for(let{id:t,detector:n,loader:r}of e)z(t,n,r)},`registerLazyLoadedDiagrams`),z=n((e,n,r)=>{Et[e]&&t.warn(`Detector with key ${e} already exists. Overwriting.`),Et[e]={detector:n,loader:r},t.debug(`Detector with key ${e} added${r?` with loader`:``}`)},`addDetector`),B=n(e=>Et[e].loader,`getDiagramLoader`),Ot=n((e,t,{depth:n=2}={})=>{let r={depth:n};if(Array.isArray(t)&&!Array.isArray(e))return t.forEach(t=>Ot(e,t,r)),e;if(Array.isArray(t)&&Array.isArray(e))return t.forEach(t=>{e.includes(t)||e.push(t)}),e;if(e==null||n<=0)return typeof e==`object`&&e&&typeof t==`object`?Object.assign(e,t):t;if(t!=null&&typeof e==`object`&&typeof t==`object`){let r=e;Object.entries(t).forEach(([t,i])=>{if(typeof i==`object`){if(i===null)return;Object.hasOwn(e,t)||Object.defineProperty(e,t,{value:void 0,writable:!0,enumerable:!0,configurable:!0}),r[t]===void 0&&(r[t]=Array.isArray(i)?[]:{}),typeof r[t]==`object`&&(r[t]=Ot(r[t],i,{depth:n-1}))}else typeof r[t]!=`object`&&(Object.hasOwn(e,t)?r[t]=i:Object.defineProperty(e,t,{value:i,writable:!0,enumerable:!0,configurable:!0}))})}return e},`assignWithDepth`),V=Ot,H=`#ffffff`,U=`#f2f2f2`,W=n((e,t)=>t?x(e,{s:-40,l:10}):x(e,{s:-40,l:-10}),`mkBorder`),kt=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#fff4dd`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.useGradient=!0,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||`navy`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||b(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||b(this.mainBkg,10)):(this.rowOdd=this.rowOdd||y(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||y(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]}),Object.hasOwn(e,`nodeBorder`)&&!Object.hasOwn(e,`useGradient`)&&(this.useGradient=!1)}},At=n(e=>{let t=new kt;return t.calculate(e),t},`getThemeVariables`),jt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.mainBkg=`#1f2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.lineColor=`calculated`,this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=`calculated`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#F9FFFE`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`calculated`,this.activationBkgColor=`calculated`,this.sequenceNumberColor=`black`,this.clusterBkg=`#302F3D`,this.sectionBkgColor=b(`#EAE8D9`,30),this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`#EAE8D9`,this.excludeBkgColor=b(this.sectionBkgColor,10),this.taskBorderColor=h(255,255,255,70),this.taskBkgColor=`calculated`,this.taskTextColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=h(255,255,255,50),this.activeTaskBkgColor=`#81B1DB`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#E83737`,this.critBkgColor=`#E83737`,this.taskTextDarkColor=`calculated`,this.todayLineColor=`#DB5757`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=this.rowOdd||y(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||b(this.mainBkg,10),this.labelColor=`calculated`,this.errorBkgColor=`#a44141`,this.errorTextColor=`#ddd`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`}updateColors(){this.secondBkg=y(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=y(this.labelBackground,25),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.background,this.taskBkgColor=y(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=S(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#555`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=`#f4f4f4`,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=x(this.primaryColor,{h:64}),this.fillType3=x(this.secondaryColor,{h:64}),this.fillType4=x(this.primaryColor,{h:-64}),this.fillType5=x(this.secondaryColor,{h:-64}),this.fillType6=x(this.primaryColor,{h:128}),this.fillType7=x(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||`#0b0000`,this.cScale2=this.cScale2||`#4d1037`,this.cScale3=this.cScale3||`#3f5258`,this.cScale4=this.cScale4||`#4f2f1b`,this.cScale5=this.cScale5||`#6e0a0a`,this.cScale6=this.cScale6||`#3b0048`,this.cScale7=this.cScale7||`#995a01`,this.cScale8=this.cScale8||`#154706`,this.cScale9=this.cScale9||`#161722`,this.cScale10=this.cScale10||`#00296f`,this.cScale11=this.cScale11||`#01629c`,this.cScale12=this.cScale12||`#010029`,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330});for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Mt=n(e=>{let t=new jt;return t.calculate(e),t},`getThemeVariables`),Nt=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#ECECFF`,this.secondaryColor=x(this.primaryColor,{h:120}),this.secondaryColor=`#ffffde`,this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.background=`white`,this.mainBkg=`#ECECFF`,this.secondBkg=`#ffffde`,this.lineColor=`#333333`,this.border1=`#9370DB`,this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.border2=`#aaaa33`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`rgba(232,232,232, 0.8)`,this.textColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.clusterBkg=`#FBFBFF`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor=`calculated`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBorderColor=`calculated`,this.critBkgColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.sectionBkgColor=h(102,102,255,.49),this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#fff400`,this.taskBorderColor=`#534fbc`,this.taskBkgColor=`#8a90dd`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`#534fbc`,this.activeTaskBkgColor=`#bfc7ff`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`navy`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=`calculated`,this.rowEven=`calculated`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))`,this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||b(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||b(this.tertiaryColor,40);for(let e=0;e{this[e]===`calculated`&&(this[e]=void 0)}),typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Pt=n(e=>{let t=new Nt;return t.calculate(e),t},`getThemeVariables`),Ft=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#cde498`,this.secondaryColor=`#cdffb2`,this.background=`white`,this.mainBkg=`#cde498`,this.secondBkg=`#cdffb2`,this.lineColor=`green`,this.border1=`#13540c`,this.border2=`#6eaa49`,this.arrowheadColor=`green`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.tertiaryColor=y(`#cde498`,10),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.primaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#333`,this.edgeLabelBackground=`#e8e8e8`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`#333`,this.signalTextColor=`#333`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`#326932`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`#6eaa49`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#6eaa49`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`#487e3a`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))`}updateColors(){this.actorBorder=b(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||b(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||b(this.tertiaryColor,40);for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},It=n(e=>{let t=new Ft;return t.calculate(e),t},`getThemeVariables`),Lt=class{static{n(this,`Theme`)}constructor(){this.primaryColor=`#eee`,this.contrast=`#707070`,this.secondaryColor=y(this.contrast,55),this.background=`#ffffff`,this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.mainBkg=`#eee`,this.secondBkg=`calculated`,this.lineColor=`#666`,this.border1=`#999`,this.border2=`calculated`,this.note=`#ffa`,this.text=`#333`,this.critical=`#d42`,this.done=`#bbb`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`white`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=this.actorBorder,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`calculated`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBkgColor=`calculated`,this.critBorderColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.rowOdd=this.rowOdd||y(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||`#f4f4f4`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){this.secondBkg=y(this.contrast,55),this.border2=this.contrast,this.actorBorder=y(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor=`#999`,this.noteBkgColor=`#666`,this.noteTextColor=`#fff`,this.cScale0=this.cScale0||`#555`,this.cScale1=this.cScale1||`#F4F4F4`,this.cScale2=this.cScale2||`#555`,this.cScale3=this.cScale3||`#BBB`,this.cScale4=this.cScale4||`#777`,this.cScale5=this.cScale5||`#999`,this.cScale6=this.cScale6||`#DDD`,this.cScale7=this.cScale7||`#FFF`,this.cScale8=this.cScale8||`#DDD`,this.cScale9=this.cScale9||`#BBB`,this.cScale10=this.cScale10||`#999`,this.cScale11=this.cScale11||`#777`;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Rt=n(e=>{let t=new Lt;return t.calculate(e),t},`getThemeVariables`),zt=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#000000`,this.stateBorder=`#000000`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));`,this.tertiaryColor=`#ffffff`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=`#E9E9F1`,n=x(e,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||e,this.cScale1=this.cScale1||t,this.cScale2=this.cScale2||n,this.cScale3=this.cScale3||x(e,{h:30}),this.cScale4=this.cScale4||x(e,{h:60}),this.cScale5=this.cScale5||x(e,{h:90}),this.cScale6=this.cScale6||x(e,{h:120}),this.cScale7=this.cScale7||x(e,{h:150}),this.cScale8=this.cScale8||x(e,{h:210,l:150}),this.cScale9=this.cScale9||x(e,{h:270}),this.cScale10=this.cScale10||x(e,{h:300}),this.cScale11=this.cScale11||x(e,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Bt=n(e=>{let t=new zt;return t.calculate(e),t},`getThemeVariables`),Vt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#2a2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Ht=n(e=>{let t=new Vt;return t.calculate(e),t},`getThemeVariables`),Ut=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=W(`#28253D`,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.clusterBkg=`#F9F9FB`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#FEF9C3`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=`#E9E9F1`,n=x(e,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground=`#F9F9FB`,this.altBackground=`#F9F9FB`,this.stateEdgeLabelBackground=`#FFFFFF`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Wt=n(e=>{let t=new Ut;return t.calculate(e),t},`getThemeVariables`),G=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.filterColor=`#FFFFFF`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground=`#16141F`,this.altBackground=`#16141F`,this.compositeTitleBackground=`#16141F`,this.stateEdgeLabelBackground=`#16141F`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Gt=n(e=>{let t=new G;return t.calculate(e),t},`getThemeVariables`),Kt=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=W(`#28253D`,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.clusterBkg=`#F9F9FB`,this.clusterBorder=`#BDBCCC`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[`#FDF4FF`,`#F0FDFA`,`#FFF7ED`,`#ECFEFF`,`#F0FDF4`,`#F5F3FF`,`#FEF2F2`,`#FEFCE8`,`#EEF2FF`,`#F7FEE7`,`#F0F9FF`,`#FFF1F2`],this.usecaseActorBorder=`#A78BFA`,this.usecaseActorBkg=`#F5F3FF`,this.usecaseBorder=`#2DD4BF`,this.usecaseBkg=`#F0FDFA`,this.usecaseBoundaryBorder=`#BDBCCC`,this.usecaseBoundaryBkg=`#FAFAFC`,this.usecaseIncludeLine=`#38BDF8`,this.usecaseExtendLine=`#FB923C`,this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=x(e,{h:180,l:5});this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||`#FFFFFF`,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#F9F9FB`,this.compositeTitleBackground=this.compositeTitleBackground||`#F9F9FB`,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`,this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||`white`;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},qt=n(e=>{let t=new Kt;return t.calculate(e),t},`getThemeVariables`),Jt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[],this.usecaseActorBorder=`#A78BFA`,this.usecaseBorder=`#2DD4BF`,this.usecaseBoundaryBorder=`#BDBCCC`,this.usecaseIncludeLine=`#38BDF8`,this.usecaseExtendLine=`#FB923C`,this.filterColor=`#FFFFFF`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.rootLabelColor=`#FFFFFF`,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||`#16141F`,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||`#16141F`,this.altBackground=this.altBackground||`#16141F`,this.compositeTitleBackground=this.compositeTitleBackground||`#16141F`,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`,this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||this.background;for(let e=0;e{this[`fillType`+t]=this[`fillType`+t]||e});for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},K={base:{getThemeVariables:At},dark:{getThemeVariables:Mt},default:{getThemeVariables:Pt},forest:{getThemeVariables:It},neutral:{getThemeVariables:Rt},neo:{getThemeVariables:Bt},"neo-dark":{getThemeVariables:Ht},redux:{getThemeVariables:Wt},"redux-dark":{getThemeVariables:Gt},"redux-color":{getThemeVariables:qt},"redux-dark-color":{getThemeVariables:n(e=>{let t=new Jt;return t.calculate(e),t},`getThemeVariables`)}},q={flowchart:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:`basis`,padding:15,wrappingWidth:120,minNodeWidth:120,inheritDir:!1},swimlane:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,layout:`swimlane`,lineHops:`arc`,ignoreCrossLaneEdges:!0,optimizeRanksByCrossings:!0,automaticLaneOrdering:!1},agentflow:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,diagramPadding:8,nodeSpacing:50,rankSpacing:50,wrappingWidth:120,minNodeWidth:120},sequence:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:`"Open Sans", sans-serif`,actorFontWeight:400,noteFontSize:14,noteFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,noteFontWeight:400,noteAlign:`center`,messageFontSize:16,messageFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:`%Y-%m-%d`,topAxis:!1,displayMode:``,weekday:`sunday`},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],titleColor:``,titleFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,titleFontSize:`4ex`},class:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,htmlLabels:!1,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},state:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,layout:`elk`,wrappingWidth:120,minNodeWidth:120,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:`20`,compositTitleSize:35,radius:5},er:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,diagramPadding:20,layoutDirection:`TB`,minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:`gray`,fill:`honeydew`,fontSize:12},pie:{useMaxWidth:!0,textPosition:.75,donutHole:0,legendPosition:`right`,highlightSlice:``},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:`top`,yAxisPosition:`left`,quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,showLegend:!0,legendFontSize:14,legendPadding:10,xAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},yAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},chartOrientation:`vertical`,plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,rect_fill:`#f9f9f9`,text_color:`#333`,rect_border_size:`0.5px`,rect_border_color:`#bbb`,rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:`cose-bilkent`},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:``},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:`main`,mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:`"Open Sans", sans-serif`,personFontWeight:`normal`,external_personFontSize:14,external_personFontFamily:`"Open Sans", sans-serif`,external_personFontWeight:`normal`,systemFontSize:14,systemFontFamily:`"Open Sans", sans-serif`,systemFontWeight:`normal`,external_systemFontSize:14,external_systemFontFamily:`"Open Sans", sans-serif`,external_systemFontWeight:`normal`,system_dbFontSize:14,system_dbFontFamily:`"Open Sans", sans-serif`,system_dbFontWeight:`normal`,external_system_dbFontSize:14,external_system_dbFontFamily:`"Open Sans", sans-serif`,external_system_dbFontWeight:`normal`,system_queueFontSize:14,system_queueFontFamily:`"Open Sans", sans-serif`,system_queueFontWeight:`normal`,external_system_queueFontSize:14,external_system_queueFontFamily:`"Open Sans", sans-serif`,external_system_queueFontWeight:`normal`,boundaryFontSize:14,boundaryFontFamily:`"Open Sans", sans-serif`,boundaryFontWeight:`normal`,messageFontSize:12,messageFontFamily:`"Open Sans", sans-serif`,messageFontWeight:`normal`,containerFontSize:14,containerFontFamily:`"Open Sans", sans-serif`,containerFontWeight:`normal`,external_containerFontSize:14,external_containerFontFamily:`"Open Sans", sans-serif`,external_containerFontWeight:`normal`,container_dbFontSize:14,container_dbFontFamily:`"Open Sans", sans-serif`,container_dbFontWeight:`normal`,external_container_dbFontSize:14,external_container_dbFontFamily:`"Open Sans", sans-serif`,external_container_dbFontWeight:`normal`,container_queueFontSize:14,container_queueFontFamily:`"Open Sans", sans-serif`,container_queueFontWeight:`normal`,external_container_queueFontSize:14,external_container_queueFontFamily:`"Open Sans", sans-serif`,external_container_queueFontWeight:`normal`,componentFontSize:14,componentFontFamily:`"Open Sans", sans-serif`,componentFontWeight:`normal`,external_componentFontSize:14,external_componentFontFamily:`"Open Sans", sans-serif`,external_componentFontWeight:`normal`,component_dbFontSize:14,component_dbFontFamily:`"Open Sans", sans-serif`,component_dbFontWeight:`normal`,external_component_dbFontSize:14,external_component_dbFontFamily:`"Open Sans", sans-serif`,external_component_dbFontWeight:`normal`,component_queueFontSize:14,component_queueFontFamily:`"Open Sans", sans-serif`,component_queueFontWeight:`normal`,external_component_queueFontSize:14,external_component_queueFontFamily:`"Open Sans", sans-serif`,external_component_queueFontWeight:`normal`,wrap:!0,wrapPadding:10,person_bg_color:`#08427B`,person_border_color:`#073B6F`,external_person_bg_color:`#686868`,external_person_border_color:`#8A8A8A`,system_bg_color:`#1168BD`,system_border_color:`#3C7FC0`,system_db_bg_color:`#1168BD`,system_db_border_color:`#3C7FC0`,system_queue_bg_color:`#1168BD`,system_queue_border_color:`#3C7FC0`,external_system_bg_color:`#999999`,external_system_border_color:`#8A8A8A`,external_system_db_bg_color:`#999999`,external_system_db_border_color:`#8A8A8A`,external_system_queue_bg_color:`#999999`,external_system_queue_border_color:`#8A8A8A`,container_bg_color:`#438DD5`,container_border_color:`#3C7FC0`,container_db_bg_color:`#438DD5`,container_db_border_color:`#3C7FC0`,container_queue_bg_color:`#438DD5`,container_queue_border_color:`#3C7FC0`,external_container_bg_color:`#B3B3B3`,external_container_border_color:`#A6A6A6`,external_container_db_bg_color:`#B3B3B3`,external_container_db_border_color:`#A6A6A6`,external_container_queue_bg_color:`#B3B3B3`,external_container_queue_border_color:`#A6A6A6`,component_bg_color:`#85BBF0`,component_border_color:`#78A8D8`,component_db_bg_color:`#85BBF0`,component_db_border_color:`#78A8D8`,component_queue_bg_color:`#85BBF0`,component_queue_border_color:`#78A8D8`,external_component_bg_color:`#CCCCCC`,external_component_border_color:`#BFBFBF`,external_component_db_bg_color:`#CCCCCC`,external_component_db_border_color:`#BFBFBF`,external_component_queue_bg_color:`#CCCCCC`,external_component_queue_border_color:`#BFBFBF`},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:`gradient`,nodeAlignment:`justify`,showValues:!0,prefix:``,suffix:``,nodeWidth:10,nodePadding:12,labelStyle:`legacy`},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1,showIcons:!1,defaultIconPack:``,filenameIcons:{},extensionIcons:{}},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1,nodeSeparation:75,idealEdgeLengthMultiplier:1.5,edgeElasticity:.45,numIter:2500,seed:1},eventmodeling:{useMaxWidth:!0,padding:30,rowHeight:32},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},usecase:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,wrappingWidth:120,minNodeWidth:120,actorFontSize:14,actorFontFamily:`"Open Sans", sans-serif`,actorFontWeight:`normal`,usecaseFontSize:12,usecaseFontFamily:`"Open Sans", sans-serif`,usecaseFontWeight:`normal`,nodeSpacing:50,rankSpacing:50,diagramPadding:20,colorScheme:`role`},venn:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,width:800,height:450,padding:8,useDebugLayout:!1},cynefin:{useMaxWidth:!0,width:800,height:600,padding:40,showDomainDescriptions:!0,boundaryAmplitude:8,seed:0},theme:`default`,look:`classic`,handDrawnSeed:0,layout:`elk`,maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:`"trebuchet ms", verdana, arial, sans-serif;`,logLevel:5,securityLevel:`strict`,startOnLoad:!0,arrowMarkerAbsolute:!1,secure:[`secure`,`securityLevel`,`startOnLoad`,`maxTextSize`,`suppressErrorRendering`,`maxEdges`],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},Yt={...q,deterministicIDSeed:void 0,elk:{mergeEdges:!1,straightenEdges:!0,lineHops:!0,preset:`default`,nodePlacementStrategy:void 0,layeringStrategy:void 0,cycleBreakingStrategy:void 0,layeringLayerBound:4,nodePlacementAlignment:void 0,forceNodeModelOrder:!1,considerModelOrder:`NODES_AND_EDGES`,keepEntryNodeOnTop:!1},themeCSS:void 0,themeVariables:K.default.getThemeVariables(),sequence:{...q.sequence,messageFont:n(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`),noteFont:n(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},`noteFont`),actorFont:n(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},`actorFont`)},class:{theme:q.class?.theme,look:q.class?.look,layout:q.class?.layout,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...q.gantt,tickInterval:void 0,useWidth:void 0},c4:{...q.c4,useWidth:void 0,personFont:n(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},`personFont`),flowchart:{...q.flowchart,inheritDir:!1},external_personFont:n(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},`external_personFont`),systemFont:n(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},`systemFont`),external_systemFont:n(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},`external_systemFont`),system_dbFont:n(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},`system_dbFont`),external_system_dbFont:n(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},`external_system_dbFont`),system_queueFont:n(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},`system_queueFont`),external_system_queueFont:n(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},`external_system_queueFont`),containerFont:n(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},`containerFont`),external_containerFont:n(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},`external_containerFont`),container_dbFont:n(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},`container_dbFont`),external_container_dbFont:n(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},`external_container_dbFont`),container_queueFont:n(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},`container_queueFont`),external_container_queueFont:n(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},`external_container_queueFont`),componentFont:n(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},`componentFont`),external_componentFont:n(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},`external_componentFont`),component_dbFont:n(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},`component_dbFont`),external_component_dbFont:n(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},`external_component_dbFont`),component_queueFont:n(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},`component_queueFont`),external_component_queueFont:n(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},`external_component_queueFont`),boundaryFont:n(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},`boundaryFont`),messageFont:n(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`)},pie:{...q.pie,useWidth:984},xyChart:{...q.xyChart,useWidth:void 0},requirement:{...q.requirement,useWidth:void 0},packet:{...q.packet},eventmodeling:{...q.eventmodeling},treeView:{...q.treeView,useWidth:void 0},radar:{...q.radar},usecase:{...q.usecase},railroad:{...q.railroad,fontSize:void 0,fontFamily:void 0,terminalFill:void 0,terminalStroke:void 0,terminalTextColor:void 0,nonTerminalFill:void 0,nonTerminalStroke:void 0,nonTerminalTextColor:void 0,lineColor:void 0,markerFill:void 0,commentFill:void 0,commentStroke:void 0,commentTextColor:void 0,specialFill:void 0,specialStroke:void 0,ruleNameColor:void 0},ishikawa:{...q.ishikawa},sankey:{...q.sankey,nodeColors:void 0},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:`,`},venn:{...q.venn},cynefin:{...q.cynefin}},Xt=n((e,t=``)=>Object.keys(e).reduce((n,r)=>Array.isArray(e[r])?n:typeof e[r]==`object`&&e[r]!==null?[...n,t+r,...Xt(e[r],``)]:[...n,t+r],[]),`keyify`),Zt=new Set(Xt(Yt,``)),Qt=Yt,$t={"flowchart-v2":`flowchart`,"flowchart-elk":`flowchart`,classDiagram:`class`,stateDiagram:`state`,xychart:`xyChart`,railroadAbnf:`railroad`,railroadEbnf:`railroad`,railroadPeg:`railroad`},J=n(e=>$t[e]??e,`getDiagramConfigKey`),en={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},tn=n((e,n)=>{for(let r of Object.keys(e)){let i=e[r];(r.startsWith(`__`)||r.includes(`proto`)||r.includes(`constr`)||typeof i!=`string`||!n.test(i))&&(t.debug(`sanitize deleting dictionary entry:`,r,i),delete e[r])}},`sanitizeDictionaryConfig`),nn=n(e=>{if(t.debug(`sanitizeDirective called with`,e),!(typeof e!=`object`||!e)){if(Array.isArray(e)){e.forEach(e=>nn(e));return}for(let n of Object.keys(e)){if(t.debug(`Checking key`,n),n.startsWith(`__`)||n.includes(`proto`)||n.includes(`constr`)||!Zt.has(n)||e[n]==null){t.debug(`sanitize deleting key: `,n),delete e[n];continue}if(typeof e[n]==`object`){let r=en[n];r?tn(e[n],r):(t.debug(`sanitizing object`,n),nn(e[n]));continue}for(let r of[`themeCSS`,`fontFamily`,`altFontFamily`])n.includes(r)&&(t.debug(`sanitizing css option`,n),e[n]=rn(e[n]))}if(e.themeVariables)for(let t of Object.keys(e.themeVariables)){let n=e.themeVariables[t];n?.match&&!n.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]=``)}t.debug(`After sanitization`,e)}},`sanitizeDirective`),rn=n(e=>{let t=0,n=0;for(let r of e){if(te===`theme`?t===`null`||Object.hasOwn(K,t):e!==`look`||sn.has(t),`isUsableAppearance`),ln=n((e,t,n)=>{if(e)return[e[t]?.[n],e[n]].find(e=>e!==void 0&&cn(n,e))},`readAppearance`),un=n(e=>!(e===!1||[`false`,`null`,`0`].includes(String(e).trim().toLowerCase())),`evaluate`),Y=V({},an),dn,fn={},X=[],pn=V({},an),Z,mn=n((e,t)=>{if(!Z)return;let n=[t,...[...X].reverse(),fn,an],r=e[Z];for(let t of on)for(let i of n){let n=ln(i,Z,t);if(n!==void 0){e[t]=n,r?.[t]!==void 0&&(r[t]=n);break}}},`resolveAppearance`),hn=n((e,t)=>{let n=V({},e),r={};for(let e of t)$(e),r=V(r,e);if(n=V(n,r),mn(n,r),(r.theme||n.theme!==e.theme)&&n.theme&&Object.hasOwn(K,n.theme)){let e=V(V({},dn).themeVariables||{},r.themeVariables);n.themeVariables=K[n.theme].getThemeVariables(e)}return pn=n,Dn(pn),pn},`updateCurrentConfig`),gn=n(e=>{Z=e===void 0?void 0:J(e),hn(Y,X)},`setDiagramConfigScope`),_n=n(e=>(Y=V({},an),Y=V(Y,e),fn=V({},e),e.theme&&Object.hasOwn(K,e.theme)&&(Y.themeVariables=K[e.theme].getThemeVariables(e.themeVariables)),hn(Y,X),Y),`setSiteConfig`),vn=n(e=>{dn=V({},e)},`saveConfigFromInitialize`),yn=n(e=>(Y=V(Y,e),fn=V(fn,e),hn(Y,X),Y),`updateSiteConfig`),bn=n(()=>V({},Y),`getSiteConfig`),xn=n(e=>(hn(pn,[e]),Q()),`setConfig`),Q=n(()=>V({},pn),`getConfig`),$=n(e=>{e&&([`secure`,...Y.secure??[]].forEach(n=>{Object.hasOwn(e,n)&&(t.debug(`Denied attempt to modify a secure key ${n}`,e[n]),delete e[n])}),Object.keys(e).forEach(t=>{t.startsWith(`__`)&&delete e[t]}),Object.keys(e).forEach(t=>{typeof e[t]==`string`&&(e[t].includes(`<`)||e[t].includes(`>`)||e[t].includes(`url(data:`))&&delete e[t],typeof e[t]==`object`&&$(e[t])}))},`sanitize`),Sn=n(e=>{nn(e),e.fontFamily&&!e.themeVariables?.fontFamily&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),X.push(e),hn(Y,X)},`addDirective`),Cn=n((e=Y)=>{X=[],Z=void 0,hn(e,X)},`reset`),wn={LAZY_LOAD_DEPRECATED:`The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.`,FLOWCHART_HTML_LABELS_DEPRECATED:`flowchart.htmlLabels is deprecated. Please use global htmlLabels instead.`},Tn={},En=n(e=>{Tn[e]||(t.warn(wn[e]),Tn[e]=!0)},`issueWarning`),Dn=n(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&En(`LAZY_LOAD_DEPRECATED`)},`checkConfig`),On=n(()=>{let e={};dn&&(e=V(e,dn));for(let t of X)e=V(e,t);return e},`getUserDefinedConfig`),kn=n(e=>(e.flowchart?.htmlLabels!=null&&En(`FLOWCHART_HTML_LABELS_DEPRECATED`),un(e.htmlLabels??e.flowchart?.htmlLabels??!0)),`getEffectiveHtmlLabels`),An=/<\/?br\s*\/?>/gi,jn=new RegExp(An.source,`i`),Mn=n(e=>e?Hn(e).replace(/\\n/g,`#br#`).split(`#br#`):[``],`getRows`),Nn=(()=>{let e=!1;return()=>{e||=(Pn(),!0)}})();function Pn(){let e=`data-temp-href-target`;P.addHook(`beforeSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(`target`)&&t.setAttribute(e,t.getAttribute(`target`)??``)}),P.addHook(`afterSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(e)&&(t.setAttribute(`target`,t.getAttribute(e)??``),t.removeAttribute(e),t.getAttribute(`target`)===`_blank`&&t.setAttribute(`rel`,`noopener`))})}n(Pn,`setupDompurifyHooks`);var Fn=n(e=>(Nn(),P.sanitize(e)),`removeScript`),In=n((e,t)=>{if(kn(t)){let n=t.securityLevel;n===`antiscript`||n===`strict`||n===`sandbox`?e=Fn(e):n!==`loose`&&(e=Hn(e),e=e.replace(//g,`>`),e=e.replace(/=/g,`=`),e=Vn(e))}return e},`sanitizeMore`),Ln=n((e,t)=>e&&(e=t.dompurifyConfig?P.sanitize(In(e,t),t.dompurifyConfig).toString():P.sanitize(In(e,t),{FORBID_TAGS:[`style`]}).toString(),e),`sanitizeText`),Rn=n((e,t)=>typeof e==`string`?Ln(e,t):e.flat().map(e=>Ln(e,t)),`sanitizeTextOrArray`),zn=n(e=>jn.test(e),`hasBreaks`),Bn=n(e=>e.split(An),`splitBreaks`),Vn=n(e=>e.replace(/#br#/g,`
    `),`placeholderToBreak`),Hn=n(e=>e.replace(An,`#br#`),`breakToPlaceholder`),Un=n(e=>{let t=``;return e&&(t=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},`getUrl`),Wn=n(function(...e){let t=e.filter(e=>!isNaN(e));return Math.max(...t)},`getMax`),Gn=n(function(...e){let t=e.filter(e=>!isNaN(e));return Math.min(...t)},`getMin`),Kn=n(function(e){let t=e.split(/(,)/),n=[];for(let e=0;e0&&e+1Math.max(0,e.split(t).length-1),`countOccurrence`),Jn=n((e,t)=>{let n=qn(e,`~`),r=qn(t,`~`);return n===1&&r===1},`shouldCombineSets`),Yn=n(e=>{let t=qn(e,`~`),n=!1;if(t<=1)return e;t%2!=0&&e.startsWith(`~`)&&(e=e.substring(1),n=!0);let r=[...e],i=r.indexOf(`~`),a=r.lastIndexOf(`~`);for(;i!==-1&&a!==-1&&i!==a;)r[i]=`<`,r[a]=`>`,i=r.indexOf(`~`),a=r.lastIndexOf(`~`);return n&&r.unshift(`~`),r.join(``)},`processSet`),Xn=n(()=>window.MathMLElement!==void 0,`isMathMLSupported`),Zn=/\$\$(.*?)\$\$/g,Qn=n(e=>(e.match(Zn)?.length??0)>0,`hasKatex`),$n=n(async(e,t)=>{let n=document.createElement(`div`);n.innerHTML=await tr(e,t),n.id=`katex-temp`,n.style.visibility=`hidden`,n.style.position=`absolute`,n.style.top=`0`,document.querySelector(`body`)?.insertAdjacentElement(`beforeend`,n);let r={width:n.clientWidth,height:n.clientHeight};return n.remove(),r},`calculateMathMLDimensions`),er=n(async(e,t)=>{if(!Qn(e))return e;if(!(Xn()||t.legacyMathML||t.forceLegacyMathML))return e.replace(Zn,`MathML is unsupported in this environment.`);{let{default:n}=await I(async()=>{let{default:e}=await import(`./katex-CXMH3UgJ.js`);return{default:e}},[]),r=t.forceLegacyMathML||!Xn()&&t.legacyMathML?`htmlAndMathml`:`mathml`;return e.split(An).map(e=>Qn(e)?`
    ${e}
    `:`
    ${e}
    `).join(``).replace(Zn,(e,t)=>n.renderToString(t,{throwOnError:!0,displayMode:!0,output:r}).replace(/\n/g,` `).replace(//g,``))}},`renderKatexUnsanitized`),tr=n(async(e,t)=>Ln(await er(e,t),t),`renderKatexSanitized`),nr={getRows:Mn,sanitizeText:Ln,sanitizeTextOrArray:Rn,hasBreaks:zn,splitBreaks:Bn,lineBreakRegex:An,removeScript:Fn,getUrl:Un,evaluate:un,getMax:Wn,getMin:Gn},rr=n(function(e,t){for(let n of t)e.attr(n[0],n[1])},`d3Attrs`),ir=n(function(e,t,n){let r=new Map;return n?(r.set(`width`,`100%`),r.set(`style`,`max-width: ${t}px;`)):(r.set(`height`,e),r.set(`width`,t)),r},`calculateSvgSizeAttrs`),ar=n(function(e,t,n,r){rr(e,ir(t,n,r))},`configureSvgSize`),or=n(function(e,n,r,i){let a=n.node().getBBox(),o=a.width,s=a.height;t.info(`SVG bounds: ${o}x${s}`,a);let c=0,l=0;t.info(`Graph bounds: ${c}x${l}`,e),c=o+r*2,l=s+r*2,t.info(`Calculated bounds: ${c}x${l}`),ar(n,l,c,i);let u=`${a.x-r} ${a.y-r} ${a.width+2*r} ${a.height+2*r}`;n.attr(`viewBox`,u)},`setupGraphViewbox`),sr={};function cr(e){return[...e.cssRules].map(e=>e.cssText).join(` +`)}n(cr,`cssStyleSheetToString`);var lr=n((e,n,r,i)=>{let a=``;return e in sr&&sr[e]?a=sr[e]({...r,svgId:i}):t.warn(`No theme found for ${e}`),`& { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + fill: ${r.textColor} + } + @keyframes edge-animation-frame { + from { + stroke-dashoffset: 0; + } + } + @keyframes dash { + to { + stroke-dashoffset: 0; + } + } + & .edge-animation-slow { + stroke-dasharray: 9,5 !important; + stroke-dashoffset: 900; + animation: dash 50s linear infinite; + stroke-linecap: round; + } + & .edge-animation-fast { + stroke-dasharray: 9,5 !important; + stroke-dashoffset: 900; + animation: dash 20s linear infinite; + stroke-linecap: round; + } + /* Classes common for multiple diagrams */ + + & .error-icon { + fill: ${r.errorBkgColor}; + } + & .error-text { + fill: ${r.errorTextColor}; + stroke: ${r.errorTextColor}; + } + + & .edge-thickness-normal { + stroke-width: ${r.strokeWidth??1}px; + } + & .edge-thickness-thick { + stroke-width: 3.5px + } + & .edge-pattern-solid { + stroke-dasharray: 0; + } + & .edge-thickness-invisible { + stroke-width: 0; + fill: none; + } + & .edge-pattern-dashed{ + stroke-dasharray: 3; + } + .edge-pattern-dotted { + stroke-dasharray: 2; + } + + & .marker { + fill: ${r.lineColor}; + stroke: ${r.lineColor}; + } + & .marker.cross { + stroke: ${r.lineColor}; + } + + & svg { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + } + & p { + margin: 0 + } + + ${a} + .node .neo-node { + stroke: ${r.nodeBorder}; + } + + [data-look="neo"].node rect, [data-look="neo"].cluster rect, [data-look="neo"].node polygon { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + [data-look="neo"].swimlane.cluster rect { + filter: none; + } + + + [data-look="neo"].node path { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + stroke-width: ${r.strokeWidth??1}px; + } + + [data-look="neo"].node .outer-path { + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].node .neo-line path { + stroke: ${r.nodeBorder}; + filter: none; + } + + [data-look="neo"].node circle{ + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].node circle .state-start{ + fill: #000000; + } + + [data-look="neo"].icon-shape .icon { + fill: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].icon-shape .icon-neo path { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + ${n} +`},`getStyles`),ur=n((e,t)=>{t!==void 0&&(sr[e]=t)},`addStylesForDiagram`),dr=lr,fr={};r(fr,{clear:()=>_r,getAccDescription:()=>xr,getAccTitle:()=>yr,getDiagramTitle:()=>Cr,setAccDescription:()=>br,setAccTitle:()=>vr,setDiagramTitle:()=>Sr});var pr=``,mr=``,hr=``,gr=n(e=>Ln(e,Q()),`sanitizeText`),_r=n(()=>{pr=``,hr=``,mr=``},`clear`),vr=n(e=>{pr=gr(e).replace(/^\s+/g,``)},`setAccTitle`),yr=n(()=>pr,`getAccTitle`),br=n(e=>{hr=gr(e).replace(/\n\s+/g,` +`)},`setAccDescription`),xr=n(()=>hr,`getAccDescription`),Sr=n(e=>{mr=gr(e)},`setDiagramTitle`),Cr=n(()=>mr,`getDiagramTitle`),wr=t,Tr=e,Er=Q,Dr=xn,Or=an,kr=n(e=>Ln(e,Er()),`sanitizeText`),Ar=or,jr=n(()=>fr,`getCommonDb`),Mr={},Nr=n((e,t,n)=>{Mr[e]&&wr.warn(`Diagram with id ${e} already registered. Overwriting.`),Mr[e]=t,n&&z(e,n),ur(e,t.styles),t.injectUtils?.(wr,Tr,Er,kr,Ar,jr(),()=>{})},`registerDiagram`),Pr=n(e=>{if(e in Mr)return Mr[e];throw new Fr(e)},`getDiagram`),Fr=class extends Error{static{n(this,`DiagramNotFoundError`)}constructor(e){super(`Diagram ${e} not found.`)}};export{yn as $,Qn as A,kr as B,B as C,Pt as D,bn as E,tr as F,Dr as G,br as H,Cn as I,_n as J,gn as K,rn as L,Kn as M,Nr as N,Un as O,R as P,K as Q,nn as R,Pr as S,kn as T,vr as U,vn as V,xn as W,Ar as X,or as Y,dr as Z,St as _,_r as a,_ as at,Q as b,ar as c,a as ct,Or as d,I as et,Qt as f,un as g,Ct as h,$n as i,v as it,An as j,On as k,cr as l,Et as m,Sn as n,b as nt,fr as o,h as ot,Dt as p,Sr as q,V as r,y as rt,nr as s,m as st,Tt as t,P as tt,an as u,xr as v,Cr as w,Er as x,yr as y,Ln as z}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-WEXAMYUT-I3m-hOmT.js b/frontend/dist/assets/chunk-WEXAMYUT-I3m-hOmT.js new file mode 100644 index 0000000..505f528 --- /dev/null +++ b/frontend/dist/assets/chunk-WEXAMYUT-I3m-hOmT.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";var r=t((t,r,o,s)=>{t.attr(`class`,o);let{width:c,height:l,x:u,y:d}=i(t,r);n(t,l,c,s);let f=a(u,d,c,l,r);t.attr(`viewBox`,f),e.debug(`viewBox configured: ${f} with padding: ${r}`)},`setupViewPortForSVG`),i=t((e,t)=>{let n=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:n.width+t*2,height:n.height+t*2,x:n.x,y:n.y}},`calculateDimensionsWithPadding`),a=t((e,t,n,r,i)=>`${e-i} ${t-i} ${n} ${r}`,`createViewBox`);export{r as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-XXDRQBXY-C1_eEj17.js b/frontend/dist/assets/chunk-XXDRQBXY-C1_eEj17.js new file mode 100644 index 0000000..de422e3 --- /dev/null +++ b/frontend/dist/assets/chunk-XXDRQBXY-C1_eEj17.js @@ -0,0 +1 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var n=t((t,n)=>{let r;return n===`sandbox`&&(r=e(`#i`+t)),e(n===`sandbox`?r.nodes()[0].contentDocument.body:`body`).select(`[id="${t}"]`)},`getDiagramElement`);export{n as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-Y2CYZVJY-DsF7k-Jl.js b/frontend/dist/assets/chunk-Y2CYZVJY-DsF7k-Jl.js new file mode 100644 index 0000000..70c3d40 --- /dev/null +++ b/frontend/dist/assets/chunk-Y2CYZVJY-DsF7k-Jl.js @@ -0,0 +1 @@ +var e=Object.defineProperty,t=(t,n)=>e(t,`name`,{value:n,configurable:!0}),n=(t,n)=>{for(var r in n)e(t,r,{get:n[r],enumerable:!0})};export{t as n,n as t}; \ No newline at end of file diff --git a/frontend/dist/assets/chunk-ZIGJFQKS-BJ6myxnF.js b/frontend/dist/assets/chunk-ZIGJFQKS-BJ6myxnF.js new file mode 100644 index 0000000..4f9ffb3 --- /dev/null +++ b/frontend/dist/assets/chunk-ZIGJFQKS-BJ6myxnF.js @@ -0,0 +1,2 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{R as r,h as i,p as a,r as o,s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as c}from"./dist-Bfr8PhAA.js";function l(e){this._context=e}l.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};function u(e){return new l(e)}var d=class{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}};function f(e){return new d(e,!0)}function ee(e){return new d(e,!1)}function p(){}function m(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function h(e){this._context=e}h.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:m(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function te(e){return new h(e)}function ne(e){this._context=e}ne.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function re(e){return new ne(e)}function ie(e){this._context=e}ie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ae(e){return new ie(e)}function oe(e,t){this._basis=new h(e),this._beta=t}oe.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r=e[0],i=t[0],a=e[n]-r,o=t[n]-i,s=-1,c;++s<=n;)c=s/n,this._basis.point(this._beta*e[s]+(1-this._beta)*(r+c*a),this._beta*t[s]+(1-this._beta)*(i+c*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};var se=(function e(t){function n(e){return t===1?new h(e):new oe(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function g(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function _(e,t){this._context=e,this._k=(1-t)/6}_.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:g(this,this._x1,this._y1)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ce=(function e(t){function n(e){return new _(e,t)}return n.tension=function(t){return e(+t)},n})(0);function v(e,t){this._context=e,this._k=(1-t)/6}v.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var le=(function e(t){function n(e){return new v(e,t)}return n.tension=function(t){return e(+t)},n})(0);function y(e,t){this._context=e,this._k=(1-t)/6}y.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ue=(function e(t){function n(e){return new y(e,t)}return n.tension=function(t){return e(+t)},n})(0);function b(e,t,n){var r=e._x1,i=e._y1,a=e._x2,o=e._y2;if(e._l01_a>1e-12){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,c=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/c,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/c}if(e._l23_a>1e-12){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*l+e._x1*e._l23_2a-t*e._l12_2a)/u,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/u}e._context.bezierCurveTo(r,i,a,o,e._x2,e._y2)}function de(e,t){this._context=e,this._alpha=t}de.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var fe=(function e(t){function n(e){return t?new de(e,t):new _(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function pe(e,t){this._context=e,this._alpha=t}pe.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var me=(function e(t){function n(e){return t?new pe(e,t):new v(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function he(e,t){this._context=e,this._alpha=t}he.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ge=(function e(t){function n(e){return t?new he(e,t):new y(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function _e(e){this._context=e}_e.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function ve(e){return new _e(e)}function ye(e){return e<0?-1:1}function be(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(ye(a)+ye(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function xe(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function x(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-r)/3;e._context.bezierCurveTo(r+s,i+s*t,a-s,o-s*n,a,o)}function S(e){this._context=e}S.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:x(this,this._t0,xe(this,this._t0))}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,e!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,x(this,xe(this,n=be(this,e,t)),n);break;default:x(this,this._t0,n=be(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Se(e){this._context=new Ce(e)}(Se.prototype=Object.create(S.prototype)).point=function(e,t){S.prototype.point.call(this,t,e)};function Ce(e){this._context=e}Ce.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function we(e){return new S(e)}function Te(e){return new Se(e)}function Ee(e){this._context=e}Ee.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n){if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=De(e),i=De(t),a=0,o=1;o=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};function w(e){return new C(e,.5)}function T(e){return new C(e,0)}function ke(e){return new C(e,1)}function E(e){if(typeof e!=`object`||!e)return!1;if(Object.getPrototypeOf(e)===null)return!0;if(Object.prototype.toString.call(e)!==`[object Object]`){let t=e[Symbol.toStringTag];return t==null||!Object.getOwnPropertyDescriptor(e,Symbol.toStringTag)?.writable?!1:e.toString()===`[object ${t}]`}let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function Ae(){}function je(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}function D(e){return e==null?e===void 0?`[object Undefined]`:`[object Null]`:Object.prototype.toString.call(e)}var Me=`[object RegExp]`,O=`[object String]`,k=`[object Number]`,A=`[object Boolean]`,j=`[object Arguments]`,Ne=`[object Symbol]`,Pe=`[object Date]`,Fe=`[object Map]`,Ie=`[object Set]`,Le=`[object Array]`,Re=`[object ArrayBuffer]`,ze=`[object Object]`,M=`[object DataView]`,Be=`[object Uint8Array]`,Ve=`[object Uint8ClampedArray]`,He=`[object Uint16Array]`,Ue=`[object Uint32Array]`,We=`[object Int8Array]`,Ge=`[object Int16Array]`,Ke=`[object Int32Array]`,qe=`[object Float32Array]`,Je=`[object Float64Array]`,Ye=typeof globalThis==`object`&&globalThis||typeof window==`object`&&window||typeof self==`object`&&self||typeof global==`object`&&global||(function(){return this})();function N(e){return Ye.Buffer!==void 0&&Ye.Buffer.isBuffer(e)}function Xe(e){return Number.isSafeInteger(e)&&e>=0}function Ze(e){return e!=null&&typeof e!=`function`&&Xe(e.length)}function Qe(e){return e===`__proto__`}function P(e){return e==null||typeof e!=`object`&&typeof e!=`function`}function F(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function $e(e,t){return I(e,void 0,e,new Map,t)}function I(e,t,n,r=new Map,i=void 0){let a=i?.(e,t,n,r);if(a!==void 0)return a;if(P(e))return e;if(r.has(e))return r.get(e);if(Array.isArray(e)){let t=Array(e.length);r.set(e,t);for(let a=0;a{let o=t?.(n,r,i,a);if(o!==void 0)return o;if(typeof e==`object`){if(D(e)===`[object Object]`&&typeof e.constructor!=`function`){let t={};return a.set(e,t),L(t,e,i,a),t}switch(Object.prototype.toString.call(e)){case k:case O:case A:{let t=new e.constructor(e?.valueOf());return L(t,e),t}case j:{let t={};return L(t,e),t.length=e.length,t[Symbol.iterator]=e[Symbol.iterator],t}default:return}}})}function nt(e){return tt(e)}function R(e){return typeof e==`object`&&!!e&&D(e)===`[object Arguments]`}function z(e){return typeof e==`object`&&!!e}function rt(e){return z(e)&&Ze(e)}function B(e){return F(e)}function V(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(`Expected a function`);let n=function(...r){let i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);let o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(V.Cache||Map),n}V.Cache=Map;function it(e){if(P(e))return e;if(Array.isArray(e)||F(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);let t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);let n=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new n(e);if(e instanceof RegExp){let t=new n(e);return t.lastIndex=e.lastIndex,t}if(e instanceof DataView)return new n(e.buffer.slice(0));if(e instanceof Error){let t;return t=e instanceof AggregateError?new n(e.errors,e.message,{cause:e.cause}):new n(e.message,{cause:e.cause}),t.stack=e.stack,Object.assign(t,e),t}return typeof File<`u`&&e instanceof File?new n([e],e.name,{type:e.type,lastModified:e.lastModified}):typeof e==`object`?Object.assign(Object.create(t),e):e}function at(e,...t){let n=t.slice(0,-1),r=t[t.length-1],i=e;for(let e=0;ee.args);r(e),i=o(i,[...e])}else i=n.args;if(!i)return;let s=a(e,t),c=`config`;return i[c]!==void 0&&(s===`flowchart-v2`&&(s=`flowchart`),i[s]=i[c],delete i[c]),i},`detectInit`),dt=n(function(t,n=null){try{let r=RegExp(`[%]{2}(?![{]${lt.source})(?=[}][%]{2}).* +`,`ig`);t=t.trim().replace(r,``).replace(/'/gm,`"`),e.debug(`Detecting diagram directive${n===null?``:` type:`+n} based on the text:${t}`);let a,o=[];for(;(a=i.exec(t))!==null;)if(a.index===i.lastIndex&&i.lastIndex++,a&&!n||n&&a[1]?.match(n)||n&&a[2]?.match(n)){let e=a[1]?a[1]:a[2],t=a[3]?a[3].trim():a[4]?JSON.parse(a[4].trim()):null;o.push({type:e,args:t})}return o.length===0?{type:t,args:null}:o.length===1?o[0]:o}catch(r){return e.error(`ERROR: ${r.message} - Unable to parse directive type: '${n}' based on the text: '${t}'`),{type:void 0,args:null}}},`detectDirective`),ft=n(function(e){return e.replace(i,``)},`removeDirectives`),pt=n(function(e,t){for(let[n,r]of t.entries())if(r.match(e))return n;return-1},`isSubstringInArray`);function U(e,t){return e?ct[`curve${e.charAt(0).toUpperCase()+e.slice(1)}`]??t:t}n(U,`interpolateToCurve`);function mt(e,t){let n=e.trim();if(n)return t.securityLevel===`loose`?n:(0,st.sanitizeUrl)(n)}n(mt,`formatUrl`);var ht=n((t,...n)=>{let r=t.split(`.`),i=r.length-1,a=r[i],o=window;for(let n=0;n{n+=W(e,t),t=e}),G(e,n/2)}n(gt,`traverseEdge`);function _t(e){return e.length===1?e[0]:gt(e)}n(_t,`calcLabelPosition`);var vt=n((e,t=2)=>{let n=10**t;return Math.round(e*n)/n},`roundNumber`),G=n((e,t)=>{let n,r=t;for(let t of e){if(n){let e=W(t,n);if(e===0)return n;if(e=1)return{x:t.x,y:t.y};if(i>0&&i<1)return{x:vt((1-i)*n.x+i*t.x,5),y:vt((1-i)*n.y+i*t.y,5)}}}n=t}throw Error(`Could not find a suitable point for the given distance`)},`calculatePoint`),yt=n((t,n,r)=>{e.info(`our points ${JSON.stringify(n)}`),n[0]!==r&&(n=n.reverse());let i=G(n,25),a=t?10:5,o=Math.atan2(n[0].y-i.y,n[0].x-i.x),s={x:0,y:0};return s.x=Math.sin(o)*a+(n[0].x+i.x)/2,s.y=-Math.cos(o)*a+(n[0].y+i.y)/2,s},`calcCardinalityPosition`);function bt(t,n,r){let i=structuredClone(r);e.info(`our points`,i),n!==`start_left`&&n!==`start_right`&&i.reverse();let a=G(i,25+t),o=10+t*.5,s=Math.atan2(i[0].y-a.y,i[0].x-a.x),c={x:0,y:0};return n===`start_left`?(c.x=Math.sin(s+Math.PI)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s+Math.PI)*o+(i[0].y+a.y)/2):n===`end_right`?(c.x=Math.sin(s-Math.PI)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s-Math.PI)*o+(i[0].y+a.y)/2-5):n===`end_left`?(c.x=Math.sin(s)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2-5):(c.x=Math.sin(s)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2),c}n(bt,`calcTerminalLabelPosition`);function K(e){let t=``,n=``;for(let r of e)r!==void 0&&(r.startsWith(`color:`)||r.startsWith(`text-align:`)?n=n+r+`;`:t=t+r+`;`);return{style:t,labelStyle:n}}n(K,`getStylesFromArray`);var xt=0,St=n(()=>(xt++,`id-`+Math.random().toString(36).substr(2,12)+`-`+xt),`generateId`);function Ct(e){let t=``;for(let n=0;nCt(e.length),`random`),Tt=n(function(){return{x:0,y:0,fill:void 0,anchor:`start`,style:`#666`,width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:``}},`getTextObj`),Et=n(function(e,t){let n=t.text.replace(s.lineBreakRegex,` `),[,r]=Z(t.fontSize),i=e.append(`text`);i.attr(`x`,t.x),i.attr(`y`,t.y),i.style(`text-anchor`,t.anchor),i.style(`font-family`,t.fontFamily),i.style(`font-size`,r),i.style(`font-weight`,t.fontWeight),i.attr(`fill`,t.fill),t.class!==void 0&&i.attr(`class`,t.class);let a=i.append(`tspan`);return a.attr(`x`,t.x+t.textMargin*2),a.attr(`fill`,t.fill),a.text(n),i},`drawSimpleText`),Dt=V((e,t,n)=>{if(!e||(n=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,joinWith:`
    `},n),s.hasBreaks(e)))return e;let r=e.split(` `).filter(Boolean),i=[],a=``;return r.forEach((e,o)=>{let s=J(`${e} `,n),c=J(a,n);if(s>t){let{hyphenatedStrings:r,remainingWord:o}=Ot(e,t,`-`,n);i.push(a,...r),a=o}else c+s>=t?(i.push(a),a=e):a=[a,e].filter(Boolean).join(` `);o+1===r.length&&i.push(a)}),i.filter(e=>e!==``).join(n.joinWith)},(e,t,n)=>`${e}${t}${n.fontSize}${n.fontWeight}${n.fontFamily}${n.joinWith}`),Ot=V((e,t,n=`-`,r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,margin:0},r);let i=[...e],a=[],o=``;return i.forEach((e,s)=>{let c=`${o}${e}`;if(J(c,r)>=t){let e=s+1,t=i.length===e,r=`${c}${n}`;a.push(t?c:r),o=``}else o=c}),{hyphenatedStrings:a,remainingWord:o}},(e,t,n=`-`,r)=>`${e}${t}${n}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function q(e,t){return Y(e,t).height}n(q,`calculateTextHeight`);function J(e,t){return Y(e,t).width}n(J,`calculateTextWidth`);var Y=V((e,n)=>{let{fontSize:r=12,fontFamily:i=`Arial`,fontWeight:a=400}=n;if(!e)return{width:0,height:0};let[,o]=Z(r),c=[`sans-serif`,i],l=e.split(s.lineBreakRegex),u=[],d=t(`body`);if(!d.remove)return{width:0,height:0,lineHeight:0};let f=d.append(`svg`);for(let e of c){let t=0,n={width:0,height:0,lineHeight:0};for(let r of l){let i=Tt();i.text=r||`​`;let s=Et(f,i).style(`font-size`,o).style(`font-weight`,a).style(`font-family`,e),c=(s._groups||s)[0][0].getBBox();if(c.width===0&&c.height===0)throw Error(`svg element not in render tree`);n.width=Math.round(Math.max(n.width,c.width)),t=Math.round(c.height),n.height+=t,n.lineHeight=Math.round(Math.max(n.lineHeight,t))}u.push(n)}return f.remove(),u[isNaN(u[1].height)||isNaN(u[1].width)||isNaN(u[1].lineHeight)||u[0].height>u[1].height&&u[0].width>u[1].width&&u[0].lineHeight>u[1].lineHeight?0:1]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),kt=class{constructor(e=!1,t){this.count=0,this.count=t?t.length:0,this.next=e?()=>this.count++:()=>Date.now()}static{n(this,`InitIDGenerator`)}},X,At=n(function(e){return X||=document.createElement(`div`),e=escape(e).replace(/%26/g,`&`).replace(/%23/g,`#`).replace(/%3B/g,`;`),X.innerHTML=e,unescape(X.textContent)},`entityDecode`);function jt(e){return`str`in e}n(jt,`isDetailedError`);var Mt=n((e,t,n,r)=>{if(!r)return;let i=e.node()?.getBBox();i&&e.append(`text`).text(r).attr(`text-anchor`,`middle`).attr(`x`,i.x+i.width/2).attr(`y`,-n).attr(`class`,t)},`insertTitle`),Z=n(e=>{if(typeof e==`number`)return[e,e+`px`];let t=parseInt(e??``,10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+`px`]:[t,e]},`parseFontSize`);function Q(e,t){return ot({},e,t)}n(Q,`cleanAndMerge`);var Nt={assignWithDepth:o,wrapLabel:Dt,calculateTextHeight:q,calculateTextWidth:J,calculateTextDimensions:Y,cleanAndMerge:Q,detectInit:ut,detectDirective:dt,isSubstringInArray:pt,interpolateToCurve:U,calcLabelPosition:_t,calcCardinalityPosition:yt,calcTerminalLabelPosition:bt,formatUrl:mt,getStylesFromArray:K,generateId:St,random:wt,runFunc:ht,entityDecode:At,insertTitle:Mt,isLabelCoordinateInPath:$,parseFontSize:Z,InitIDGenerator:kt},Pt=n(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/#\w+;/g,function(e){let t=e.substring(1,e.length-1);return/^\+?\d+$/.test(t)?`fl°°`+t+`¶ß`:`fl°`+t+`¶ß`}),t},`encodeEntities`),Ft=n(function(e){return e.replace(/fl°°/g,`&#`).replace(/fl°/g,`&`).replace(/¶ß/g,`;`)},`decodeEntities`),It=n((e,t,{counter:n=0,prefix:r,suffix:i},a)=>a||`${r?`${r}_`:``}${e}_${t}_${n}${i?`_${i}`:``}`,`getEdgeId`);function Lt(e){return e??null}n(Lt,`handleUndefinedAttr`);function $(e,t){let n=Math.round(e.x),r=Math.round(e.y),i=t.replace(/(\d+\.\d+)/g,e=>Math.round(parseFloat(e)).toString());return i.includes(n.toString())||i.includes(r.toString())}n($,`isLabelCoordinateInPath`);export{ce as $,Je as A,Ne as B,j as C,M as D,A as E,k as F,D as G,Ue as H,ze as I,w as J,ke as K,Me as L,Ke as M,We as N,Pe as O,Fe as P,fe as Q,Ie as R,N as S,Le as T,Be as U,He as V,Ve as W,we as X,Oe as Y,Te as Z,Dt as _,Ft as a,P as b,It as c,U as d,te as et,jt as f,Nt as g,ft as h,Q as i,Ge as j,qe as k,K as l,wt as m,q as n,ee as nt,Pt as o,Z as p,T as q,J as r,u as rt,St as s,Y as t,f as tt,Lt as u,B as v,Re as w,Ze as x,R as y,O as z}; \ No newline at end of file diff --git a/frontend/dist/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js b/frontend/dist/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js new file mode 100644 index 0000000..831d0dd --- /dev/null +++ b/frontend/dist/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js @@ -0,0 +1,217 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,M as i,U as a,a as o,q as s,s as c,tt as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{c as h,g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as _,n as v,o as y,r as b}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as x,t as S}from"./index-DoQkmpth.js";import{t as C}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as w}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as T}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as E}from"./chunk-WEXAMYUT-I3m-hOmT.js";var D=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,18],r=[1,19],i=[1,20],a=[1,41],o=[1,26],s=[1,42],c=[1,24],l=[1,25],u=[1,32],d=[1,33],f=[1,34],p=[1,45],m=[1,35],h=[1,36],g=[1,37],_=[1,38],v=[1,27],y=[1,28],b=[1,29],x=[1,30],S=[1,31],C=[1,44],w=[1,46],T=[1,43],E=[1,47],D=[1,9],O=[1,8,9],k=[1,58],A=[1,59],j=[1,60],M=[1,61],N=[1,62],P=[1,63],F=[1,64],I=[1,8,9,41],ee=[1,77],L=[1,8,9,12,13,22,39,41,44,46,68,69,70,71,72,73,74,79,81],R=[1,8,9,12,13,18,20,22,39,41,44,46,47,60,68,69,70,71,72,73,74,79,81,86,100,102,103],z=[13,60,86,100,102,103],B=[13,60,73,74,86,100,102,103],te=[13,60,68,69,70,71,72,86,100,102,103],V=[1,103],H=[1,121],U=[1,117],W=[1,113],G=[1,119],K=[1,114],q=[1,115],J=[1,116],Y=[1,118],X=[1,120],ne=[22,50,60,61,82,86,87,88,89,90],re=[1,128],Z=[12,39],ie=[1,8,9,39,41,44,46],Q=[1,8,9,22],ae=[1,153],oe=[1,8,9,61],$=[1,8,9,22,50,60,61,82,86,87,88,89,90],se={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,classLiteralName:17,DOT:18,className:19,GENERICTYPE:20,relationStatement:21,LABEL:22,namespaceStatement:23,classStatement:24,memberStatement:25,annotationStatement:26,clickStatement:27,styleStatement:28,cssClassStatement:29,noteStatement:30,classDefStatement:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,namespaceIdentifier:38,STRUCT_START:39,classStatements:40,STRUCT_STOP:41,NAMESPACE:42,classIdentifier:43,STYLE_SEPARATOR:44,members:45,ANNOTATION_START:46,ANNOTATION_END:47,CLASS:48,emptyBody:49,SPACE:50,MEMBER:51,SEPARATOR:52,relation:53,NOTE_FOR:54,noteText:55,NOTE:56,CLASSDEF:57,classList:58,stylesOpt:59,ALPHA:60,COMMA:61,direction_tb:62,direction_bt:63,direction_rl:64,direction_lr:65,relationType:66,lineType:67,AGGREGATION:68,EXTENSION:69,COMPOSITION:70,DEPENDENCY:71,LOLLIPOP:72,LINE:73,DOTTED_LINE:74,CALLBACK:75,LINK:76,LINK_TARGET:77,CLICK:78,CALLBACK_NAME:79,CALLBACK_ARGS:80,HREF:81,STYLE:82,CSSCLASS:83,style:84,styleComponent:85,NUM:86,COLON:87,UNIT:88,BRKT:89,PCT:90,commentToken:91,textToken:92,graphCodeTokens:93,textNoTagsToken:94,TAGSTART:95,TAGEND:96,"==":97,"--":98,DEFAULT:99,MINUS:100,keywords:101,UNICODE_TEXT:102,BQUOTE_STR:103,$accept:0,$end:1},terminals_:{2:`error`,7:`CLASS_DIAGRAM`,8:`NEWLINE`,9:`EOF`,12:`SQS`,13:`STR`,14:`SQE`,18:`DOT`,20:`GENERICTYPE`,22:`LABEL`,33:`acc_title`,34:`acc_title_value`,35:`acc_descr`,36:`acc_descr_value`,37:`acc_descr_multiline_value`,39:`STRUCT_START`,41:`STRUCT_STOP`,42:`NAMESPACE`,44:`STYLE_SEPARATOR`,46:`ANNOTATION_START`,47:`ANNOTATION_END`,48:`CLASS`,50:`SPACE`,51:`MEMBER`,52:`SEPARATOR`,54:`NOTE_FOR`,56:`NOTE`,57:`CLASSDEF`,60:`ALPHA`,61:`COMMA`,62:`direction_tb`,63:`direction_bt`,64:`direction_rl`,65:`direction_lr`,68:`AGGREGATION`,69:`EXTENSION`,70:`COMPOSITION`,71:`DEPENDENCY`,72:`LOLLIPOP`,73:`LINE`,74:`DOTTED_LINE`,75:`CALLBACK`,76:`LINK`,77:`LINK_TARGET`,78:`CLICK`,79:`CALLBACK_NAME`,80:`CALLBACK_ARGS`,81:`HREF`,82:`STYLE`,83:`CSSCLASS`,86:`NUM`,87:`COLON`,88:`UNIT`,89:`BRKT`,90:`PCT`,93:`graphCodeTokens`,95:`TAGSTART`,96:`TAGEND`,97:`==`,98:`--`,99:`DEFAULT`,100:`MINUS`,101:`keywords`,102:`UNICODE_TEXT`,103:`BQUOTE_STR`},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,1],[15,3],[15,2],[19,1],[19,3],[19,1],[19,2],[19,2],[19,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[23,4],[23,5],[38,2],[38,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[24,1],[24,3],[24,4],[24,3],[24,6],[24,4],[24,7],[24,6],[43,2],[43,3],[49,0],[49,2],[49,2],[26,4],[45,1],[45,2],[25,1],[25,2],[25,1],[25,1],[21,3],[21,4],[21,4],[21,5],[30,3],[30,2],[31,3],[58,1],[58,3],[32,1],[32,1],[32,1],[32,1],[53,3],[53,2],[53,2],[53,1],[66,1],[66,1],[66,1],[66,1],[66,1],[67,1],[67,1],[27,3],[27,4],[27,3],[27,4],[27,4],[27,5],[27,3],[27,4],[27,4],[27,5],[27,4],[27,5],[27,5],[27,6],[28,3],[29,3],[59,1],[59,3],[84,1],[84,2],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[91,1],[91,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[94,1],[94,1],[94,1],[94,1],[16,1],[16,1],[16,1],[16,1],[17,1],[55,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 8:this.$=a[s-1];break;case 9:case 10:case 13:case 15:this.$=a[s];break;case 11:case 14:this.$=a[s-2]+`.`+a[s];break;case 12:case 16:this.$=a[s-1]+a[s];break;case 17:case 18:this.$=a[s-1]+`~`+a[s]+`~`;break;case 19:r.addRelation(a[s]);break;case 20:a[s-1].title=r.cleanupLabel(a[s]),r.addRelation(a[s-1]);break;case 31:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 32:case 33:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 34:r.addClassesToNamespace(a[s-3],a[s-1][0],a[s-1][1]),r.popNamespace();break;case 35:r.addClassesToNamespace(a[s-4],a[s-1][0],a[s-1][1]),r.popNamespace();break;case 36:this.$=r.addNamespace(a[s]);break;case 37:this.$=r.addNamespace(a[s-1],a[s]);break;case 38:this.$=[[a[s]],[]];break;case 39:this.$=[[a[s-1]],[]];break;case 40:a[s][0].unshift(a[s-2]),this.$=a[s];break;case 41:this.$=[[],[a[s]]];break;case 42:this.$=[[],[a[s-1]]];break;case 43:a[s][1].unshift(a[s-2]),this.$=a[s];break;case 44:case 45:this.$=[[],[]];break;case 46:this.$=a[s];break;case 48:r.setCssClass(a[s-2],a[s]);break;case 49:r.addMembers(a[s-3],a[s-1]);break;case 51:r.setCssClass(a[s-5],a[s-3]),r.addMembers(a[s-5],a[s-1]);break;case 52:r.addAnnotation(a[s-3],a[s-1]);break;case 53:r.addAnnotation(a[s-6],a[s-4]),r.addMembers(a[s-6],a[s-1]);break;case 54:r.addAnnotation(a[s-5],a[s-3]);break;case 55:this.$=a[s],r.addClass(a[s]);break;case 56:this.$=a[s-1],r.addClass(a[s-1]),r.setClassLabel(a[s-1],a[s]);break;case 60:r.addAnnotation(a[s],a[s-2]);break;case 61:case 74:this.$=[a[s]];break;case 62:a[s].push(a[s-1]),this.$=a[s];break;case 63:break;case 64:r.addMember(a[s-1],r.cleanupLabel(a[s]));break;case 65:break;case 66:break;case 67:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:`none`,relationTitle2:`none`};break;case 68:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:`none`};break;case 69:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:`none`,relationTitle2:a[s-1]};break;case 70:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 71:this.$=r.addNote(a[s],a[s-1]);break;case 72:this.$=r.addNote(a[s]);break;case 73:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 75:this.$=a[s-2].concat([a[s]]);break;case 76:r.setDirection(`TB`);break;case 77:r.setDirection(`BT`);break;case 78:r.setDirection(`RL`);break;case 79:r.setDirection(`LR`);break;case 80:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 81:this.$={type1:`none`,type2:a[s],lineType:a[s-1]};break;case 82:this.$={type1:a[s-1],type2:`none`,lineType:a[s]};break;case 83:this.$={type1:`none`,type2:`none`,lineType:a[s]};break;case 84:this.$=r.relationType.AGGREGATION;break;case 85:this.$=r.relationType.EXTENSION;break;case 86:this.$=r.relationType.COMPOSITION;break;case 87:this.$=r.relationType.DEPENDENCY;break;case 88:this.$=r.relationType.LOLLIPOP;break;case 89:this.$=r.lineType.LINE;break;case 90:this.$=r.lineType.DOTTED_LINE;break;case 91:case 97:this.$=a[s-2],r.setClickEvent(a[s-1],a[s]);break;case 92:case 98:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 93:this.$=a[s-2],r.setLink(a[s-1],a[s]);break;case 94:this.$=a[s-3],r.setLink(a[s-2],a[s-1],a[s]);break;case 95:this.$=a[s-3],r.setLink(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 96:this.$=a[s-4],r.setLink(a[s-3],a[s-2],a[s]),r.setTooltip(a[s-3],a[s-1]);break;case 99:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 100:this.$=a[s-4],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 101:this.$=a[s-3],r.setLink(a[s-2],a[s]);break;case 102:this.$=a[s-4],r.setLink(a[s-3],a[s-1],a[s]);break;case 103:this.$=a[s-4],r.setLink(a[s-3],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 104:this.$=a[s-5],r.setLink(a[s-4],a[s-2],a[s]),r.setTooltip(a[s-4],a[s-1]);break;case 105:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 106:r.setCssClass(a[s-1],a[s]);break;case 107:this.$=[a[s]];break;case 108:a[s-2].push(a[s]),this.$=a[s-2];break;case 110:this.$=a[s-1]+a[s]}},`anonymous`),table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:t,35:r,37:i,38:22,42:a,43:23,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},e(D,[2,5],{8:[1,48]}),{8:[1,49]},e(O,[2,19],{22:[1,50]}),e(O,[2,21]),e(O,[2,22]),e(O,[2,23]),e(O,[2,24]),e(O,[2,25]),e(O,[2,26]),e(O,[2,27]),e(O,[2,28]),e(O,[2,29]),e(O,[2,30]),{34:[1,51]},{36:[1,52]},e(O,[2,33]),e(O,[2,63],{53:53,66:56,67:57,13:[1,54],22:[1,55],68:k,69:A,70:j,71:M,72:N,73:P,74:F}),{39:[1,65]},e(I,[2,47],{39:[1,67],44:[1,66],46:[1,68]}),e(O,[2,65]),e(O,[2,66]),{16:69,60:p,86:C,100:w,102:T},{16:39,17:40,19:70,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:71,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:72,60:p,86:C,100:w,102:T,103:E},{60:[1,73]},{13:[1,74]},{16:39,17:40,19:75,60:p,86:C,100:w,102:T,103:E},{13:ee,55:76},{58:78,60:[1,79]},e(O,[2,76]),e(O,[2,77]),e(O,[2,78]),e(O,[2,79]),e(L,[2,13],{16:39,17:40,19:81,18:[1,80],20:[1,82],60:p,86:C,100:w,102:T,103:E}),e(L,[2,15],{20:[1,83]}),{15:84,16:85,17:86,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:87,60:p,86:C,100:w,102:T,103:E},e(R,[2,133]),e(R,[2,134]),e(R,[2,135]),e(R,[2,136]),e([1,8,9,12,13,20,22,39,41,44,46,68,69,70,71,72,73,74,79,81],[2,137]),e(D,[2,6],{10:5,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,19:21,38:22,43:23,16:39,17:40,5:88,33:t,35:r,37:i,42:a,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E}),{5:89,10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:t,35:r,37:i,38:22,42:a,43:23,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E},e(O,[2,20]),e(O,[2,31]),e(O,[2,32]),{13:[1,91],16:39,17:40,19:90,60:p,86:C,100:w,102:T,103:E},{53:92,66:56,67:57,68:k,69:A,70:j,71:M,72:N,73:P,74:F},e(O,[2,64]),{67:93,73:P,74:F},e(z,[2,83],{66:94,68:k,69:A,70:j,71:M,72:N}),e(B,[2,84]),e(B,[2,85]),e(B,[2,86]),e(B,[2,87]),e(B,[2,88]),e(te,[2,89]),e(te,[2,90]),{8:[1,96],23:99,24:97,30:98,38:22,40:95,42:a,43:23,48:s,54:u,56:d},{16:100,60:p,86:C,100:w,102:T},{41:[1,102],45:101,51:V},{16:104,60:p,86:C,100:w,102:T},{47:[1,105]},{13:[1,106]},{13:[1,107]},{79:[1,108],81:[1,109]},{22:H,50:U,59:110,60:W,82:G,84:111,85:112,86:K,87:q,88:J,89:Y,90:X},{60:[1,122]},{13:ee,55:123},e(I,[2,72]),e(I,[2,138]),{22:H,50:U,59:124,60:W,61:[1,125],82:G,84:111,85:112,86:K,87:q,88:J,89:Y,90:X},e(ne,[2,74]),{16:39,17:40,19:126,60:p,86:C,100:w,102:T,103:E},e(L,[2,16]),e(L,[2,17]),e(L,[2,18]),{11:127,12:re,39:[2,36]},e(Z,[2,9],{16:85,17:86,15:130,18:[1,129],60:p,86:C,100:w,102:T,103:E}),e(Z,[2,10]),e(ie,[2,55],{11:131,12:re}),e(D,[2,7]),{9:[1,132]},e(Q,[2,67]),{16:39,17:40,19:133,60:p,86:C,100:w,102:T,103:E},{13:[1,135],16:39,17:40,19:134,60:p,86:C,100:w,102:T,103:E},e(z,[2,82],{66:136,68:k,69:A,70:j,71:M,72:N}),e(z,[2,81]),{41:[1,137]},{23:99,24:97,30:98,38:22,40:138,42:a,43:23,48:s,54:u,56:d},{8:[1,139],41:[2,38]},{8:[1,140],41:[2,41]},{8:[1,141],41:[2,44]},e(I,[2,48],{39:[1,142]}),{41:[1,143]},e(I,[2,50]),{41:[2,61],45:144,51:V},{47:[1,145]},{16:39,17:40,19:146,60:p,86:C,100:w,102:T,103:E},e(O,[2,91],{13:[1,147]}),e(O,[2,93],{13:[1,149],77:[1,148]}),e(O,[2,97],{13:[1,150],80:[1,151]}),{13:[1,152]},e(O,[2,105],{61:ae}),e(oe,[2,107],{85:154,22:H,50:U,60:W,82:G,86:K,87:q,88:J,89:Y,90:X}),e($,[2,109]),e($,[2,111]),e($,[2,112]),e($,[2,113]),e($,[2,114]),e($,[2,115]),e($,[2,116]),e($,[2,117]),e($,[2,118]),e($,[2,119]),e(O,[2,106]),e(I,[2,71]),e(O,[2,73],{61:ae}),{60:[1,155]},e(L,[2,14]),{39:[2,37]},{13:[1,156]},{15:157,16:85,17:86,60:p,86:C,100:w,102:T,103:E},e(Z,[2,12]),e(ie,[2,56]),{1:[2,4]},e(Q,[2,69]),e(Q,[2,68]),{16:39,17:40,19:158,60:p,86:C,100:w,102:T,103:E},e(z,[2,80]),e(I,[2,34]),{41:[1,159]},{23:99,24:97,30:98,38:22,40:160,41:[2,39],42:a,43:23,48:s,54:u,56:d},{23:99,24:97,30:98,38:22,40:161,41:[2,42],42:a,43:23,48:s,54:u,56:d},{23:99,24:97,30:98,38:22,40:162,41:[2,45],42:a,43:23,48:s,54:u,56:d},{45:163,51:V},e(I,[2,49]),{41:[2,62]},e(I,[2,52],{39:[1,164]}),e(O,[2,60]),e(O,[2,92]),e(O,[2,94]),e(O,[2,95],{77:[1,165]}),e(O,[2,98]),e(O,[2,99],{13:[1,166]}),e(O,[2,101],{13:[1,168],77:[1,167]}),{22:H,50:U,60:W,82:G,84:169,85:112,86:K,87:q,88:J,89:Y,90:X},e($,[2,110]),e(ne,[2,75]),{14:[1,170]},e(Z,[2,11]),e(Q,[2,70]),e(I,[2,35]),{41:[2,40]},{41:[2,43]},{41:[2,46]},{41:[1,171]},{41:[1,173],45:172,51:V},e(O,[2,96]),e(O,[2,100]),e(O,[2,102]),e(O,[2,103],{77:[1,174]}),e(oe,[2,108],{85:154,22:H,50:U,60:W,82:G,86:K,87:q,88:J,89:Y,90:X}),e(ie,[2,8]),e(I,[2,51]),{41:[1,175]},e(I,[2,54]),e(O,[2,104]),e(I,[2,53])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],127:[2,37],132:[2,4],144:[2,62],160:[2,40],161:[2,43],162:[2,46]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};se.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return 62;case 1:return 63;case 2:return 64;case 3:return 65;case 4:break;case 5:break;case 6:return this.begin(`acc_title`),33;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),35;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 8;case 14:break;case 15:return 7;case 16:return 7;case 17:return`EDGE_STATE`;case 18:this.begin(`callback_name`);break;case 19:this.popState();break;case 20:this.popState(),this.begin(`callback_args`);break;case 21:return 79;case 22:this.popState();break;case 23:return 80;case 24:this.popState();break;case 25:return`STR`;case 26:this.begin(`string`);break;case 27:return 82;case 28:return 57;case 29:return this.begin(`namespace`),42;case 30:return this.popState(),8;case 31:break;case 32:return this.begin(`namespace-body`),39;case 33:this.popState(),this.less(0);break;case 34:return this.popState(),41;case 35:return`EOF_IN_STRUCT`;case 36:return 8;case 37:break;case 38:return`EDGE_STATE`;case 39:return this.begin(`class`),48;case 40:return this.popState(),8;case 41:break;case 42:return this.popState(),this.popState(),41;case 43:return this.begin(`class-body`),39;case 44:return this.popState(),41;case 45:return`EOF_IN_STRUCT`;case 46:return`EDGE_STATE`;case 47:return`OPEN_IN_STRUCT`;case 48:break;case 49:return`MEMBER`;case 50:return 83;case 51:return 75;case 52:return 76;case 53:return 78;case 54:return 54;case 55:return 56;case 56:return 46;case 57:return 47;case 58:return 81;case 59:this.popState();break;case 60:return`GENERICTYPE`;case 61:this.begin(`generic`);break;case 62:this.popState();break;case 63:return`BQUOTE_STR`;case 64:this.begin(`bqstring`);break;case 65:return 77;case 66:return 77;case 67:return 77;case 68:return 77;case 69:return 69;case 70:return 69;case 71:return 71;case 72:return 71;case 73:return 70;case 74:return 68;case 75:return 72;case 76:return 73;case 77:return 74;case 78:return 22;case 79:return 44;case 80:return 100;case 81:return 18;case 82:return`PLUS`;case 83:return 87;case 84:return 61;case 85:return 89;case 86:return 89;case 87:return 90;case 88:return`EQUALS`;case 89:return`EQUALS`;case 90:return 60;case 91:return 12;case 92:return 14;case 93:return`PUNCTUATION`;case 94:return 86;case 95:return 102;case 96:return 50;case 97:return 50;case 98:return 9}},`anonymous`),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:\[\*\])/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:["])/,/^(?:[^"]*)/,/^(?:["])/,/^(?:style\b)/,/^(?:classDef\b)/,/^(?:namespace\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[{])/,/^(?:[}])/,/^(?:[}])/,/^(?:$)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:\[\*\])/,/^(?:class\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[}])/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\[\*\])/,/^(?:[{])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:note for\b)/,/^(?:note\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:href\b)/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:~)/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:[`])/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:\s*\(\))/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?::)/,/^(?:,)/,/^(?:#)/,/^(?:#)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:\[)/,/^(?:\])/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:\s)/,/^(?:$)/],conditions:{"namespace-body":{rules:[26,29,34,35,36,37,38,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},namespace:{rules:[26,29,30,31,32,33,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},"class-body":{rules:[26,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},class:{rules:[26,40,41,42,43,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr_multiline:{rules:[11,12,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr:{rules:[9,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_title:{rules:[7,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_args:{rules:[22,23,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_name:{rules:[19,20,21,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},href:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},struct:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},generic:{rules:[26,50,51,52,53,54,55,56,57,58,59,60,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},bqstring:{rules:[26,50,51,52,53,54,55,56,57,58,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},string:{rules:[24,25,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,26,27,28,29,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98],inclusive:!0}}}})();function ce(){this.yy={}}return n(ce,`Parser`),ce.prototype=se,se.Parser=ce,new ce})();D.parser=D;var O=D,k=[`#`,`+`,`~`,`-`,``],A=class{static{n(this,`ClassMember`)}constructor(e,t){this.memberType=t,this.visibility=``,this.classifier=``,this.text=``;let n=m(e,f());this.parseMember(n)}getDisplayDetails(){let e=this.visibility+i(this.id);this.memberType===`method`&&(e+=`(${i(this.parameters.trim())})`,this.returnType&&(e+=` : `+i(this.returnType))),e=e.trim();let t=this.parseClassifier();return{displayText:e,cssStyle:t}}parseMember(e){let t=``;if(this.memberType===`method`){let n=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(e);if(n){let e=n[1]?n[1].trim():``;if(k.includes(e)&&(this.visibility=e),this.id=n[2],this.parameters=n[3]?n[3].trim():``,t=n[4]?n[4].trim():``,this.returnType=n[5]?n[5].trim():``,t===``){let e=this.returnType.substring(this.returnType.length-1);/[$*]/.exec(e)&&(t=e,this.returnType=this.returnType.substring(0,this.returnType.length-1))}}}else{let n=e.length,r=e.substring(0,1),i=e.substring(n-1);k.includes(r)&&(this.visibility=r),/[$*]/.exec(i)&&(t=i),this.id=e.substring(this.visibility===``?0:1,t===``?n:n-1)}this.classifier=t,this.id=this.id.startsWith(` `)?` `+this.id.trim():this.id.trim();let n=`${this.visibility?`\\`+this.visibility:``}${i(this.id)}${this.memberType===`method`?`(${i(this.parameters)})${this.returnType?` : `+i(this.returnType):``}`:``}`;this.text=n.replaceAll(`<`,`<`).replaceAll(`>`,`>`),this.text.startsWith(`\\<`)&&(this.text=this.text.replace(`\\<`,`~`))}parseClassifier(){switch(this.classifier){case`*`:return`font-style:italic;`;case`$`:return`text-decoration:underline;`;default:return``}}},j=`classId-`,M=0,N=n(e=>c.sanitizeText(e,f()),`sanitizeText`),P=class i{constructor(){this.relations=[],this.classes=new Map,this.styleClasses=new Map,this.notes=new Map,this.interfaces=[],this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId=``,this.functions=[],this.lineType={LINE:0,DOTTED_LINE:1},this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3,LOLLIPOP:4},this.setupToolTips=n(e=>{let n=w();t(e).select(`svg`).selectAll(`g`).filter(function(){return t(this).attr(`title`)!==null}).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(!i)return;let a=e.currentTarget.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.html(l.sanitize(i)).style(`left`,`${window.scrollX+a.left+a.width/2}px`).style(`top`,`${window.scrollY+a.bottom+4}px`),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})},`setupToolTips`),this.direction=`TB`,this.setAccTitle=a,this.getAccTitle=p,this.setAccDescription=r,this.getAccDescription=u,this.setDiagramTitle=s,this.getDiagramTitle=d,this.getConfig=n(()=>f().class,`getConfig`),this.functions.push(this.setupToolTips.bind(this)),this.clear(),this.addRelation=this.addRelation.bind(this),this.addClassesToNamespace=this.addClassesToNamespace.bind(this),this.addNamespace=this.addNamespace.bind(this),this.popNamespace=this.popNamespace.bind(this),this.setCssClass=this.setCssClass.bind(this),this.addMembers=this.addMembers.bind(this),this.addClass=this.addClass.bind(this),this.setClassLabel=this.setClassLabel.bind(this),this.addAnnotation=this.addAnnotation.bind(this),this.addMember=this.addMember.bind(this),this.cleanupLabel=this.cleanupLabel.bind(this),this.addNote=this.addNote.bind(this),this.defineClass=this.defineClass.bind(this),this.setDirection=this.setDirection.bind(this),this.setLink=this.setLink.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.clear=this.clear.bind(this),this.setTooltip=this.setTooltip.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setCssStyle=this.setCssStyle.bind(this)}static{n(this,`ClassDB`)}splitClassNameAndType(e){let t=c.sanitizeText(e,f()),n=``,r=t;if(t.indexOf(`~`)>0){let e=t.split(`~`);r=N(e[0]),n=N(e[1])}return{className:r,type:n}}setClassLabel(e,t){let n=c.sanitizeText(e,f());t&&=N(t);let{className:r}=this.splitClassNameAndType(n);this.classes.get(r).label=t,this.classes.get(r).text=`${t}${this.classes.get(r).type?`<${this.classes.get(r).type}>`:``}`}addClass(e){let t=c.sanitizeText(e,f()),{className:n,type:r}=this.splitClassNameAndType(t);if(this.classes.has(n))return;let i=c.sanitizeText(n,f());this.classes.set(i,{id:i,type:r,label:i,text:`${i}${r?`<${r}>`:``}`,shape:`classBox`,cssClasses:`default`,methods:[],members:[],annotations:[],styles:[],domId:j+i+`-`+M}),M++}addInterface(e,t){let n={id:`interface${this.interfaces.length}`,label:e,classId:t};this.interfaces.push(n)}setDiagramId(e){this.diagramId=e}lookUpDomId(e){let t=c.sanitizeText(e,f());if(this.classes.has(t)){let e=this.classes.get(t).domId;return this.diagramId?`${this.diagramId}-${e}`:e}throw Error(`Class not found: `+t)}clear(){this.relations=[],this.classes=new Map,this.notes=new Map,this.interfaces=[],this.functions=[],this.functions.push(this.setupToolTips.bind(this)),this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId=``,this.direction=`TB`,o()}getClass(e){return this.classes.get(e)}getClasses(){return this.classes}getRelations(){return this.relations}getNote(e){let t=typeof e==`number`?`note${e}`:e;return this.notes.get(t)}getNotes(){return this.notes}addRelation(t){e.debug(`Adding relation: `+JSON.stringify(t));let n=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];t.relation.type1===this.relationType.LOLLIPOP&&!n.includes(t.relation.type2)?(this.addClass(t.id2),this.addInterface(t.id1,t.id2),t.id1=`interface${this.interfaces.length-1}`):t.relation.type2===this.relationType.LOLLIPOP&&!n.includes(t.relation.type1)?(this.addClass(t.id1),this.addInterface(t.id2,t.id1),t.id2=`interface${this.interfaces.length-1}`):(this.addClass(t.id1),this.addClass(t.id2)),t.id1=this.splitClassNameAndType(t.id1).className,t.id2=this.splitClassNameAndType(t.id2).className,t.relationTitle1=c.sanitizeText(t.relationTitle1.trim(),f()),t.relationTitle2=c.sanitizeText(t.relationTitle2.trim(),f()),this.relations.push(t)}addAnnotation(e,t){let n=this.splitClassNameAndType(e).className;this.classes.get(n).annotations.push(t)}addMember(e,t){this.addClass(e);let n=this.splitClassNameAndType(e).className,r=this.classes.get(n);if(typeof t==`string`){let e=t.trim();e.startsWith(`<<`)&&e.endsWith(`>>`)?r.annotations.push(N(e.substring(2,e.length-2))):e.indexOf(`)`)>0?r.methods.push(new A(e,`method`)):e&&r.members.push(new A(e,`attribute`))}}addMembers(e,t){Array.isArray(t)&&(t.reverse(),t.forEach(t=>this.addMember(e,t)))}addNote(e,t){let n=this.notes.size,r={id:`note${n}`,class:t,text:e,index:n};return this.notes.set(r.id,r),r.id}cleanupLabel(e){return e.startsWith(`:`)&&(e=e.substring(1)),N(e.trim())}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=e;/\d/.exec(e[0])&&(n=j+n),n=this.splitClassNameAndType(n).className;let r=this.classes.get(n);r&&(r.cssClasses+=` `+t)})}defineClass(e,t){for(let n of e){let e=this.styleClasses.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.styleClasses.set(n,e)),t&&t.forEach(t=>{if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.classes.forEach(e=>{e.cssClasses.includes(n)&&e.styles.push(...t.flatMap(e=>e.split(`,`)))})}}setTooltip(e,t){e.split(`,`).forEach(e=>{if(t!==void 0){let n=this.splitClassNameAndType(e).className,r=this.classes.get(n);r&&(r.tooltip=N(t))}})}getTooltip(e,t){return t&&this.namespaces.has(t)?this.namespaces.get(t).classes.get(e).tooltip:this.classes.get(e).tooltip}setLink(e,t,n){let r=f();e.split(`,`).forEach(e=>{let i=e;/\d/.exec(e[0])&&(i=j+i),i=this.splitClassNameAndType(i).className;let a=this.classes.get(i);a&&(a.link=g.formatUrl(t,r),a.linkTarget=r.securityLevel===`sandbox`?`_top`:typeof n==`string`?N(n):`_blank`)}),this.setCssClass(e,`clickable`)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFunc(e,t,n);let r=this.splitClassNameAndType(e).className,i=this.classes.get(r);i&&(i.haveCallback=!0)}),this.setCssClass(e,`clickable`)}setClickFunc(e,t,n){let r=c.sanitizeText(e,f());if(f().securityLevel!==`loose`||t===void 0)return;let i=this.splitClassNameAndType(r).className;if(this.classes.has(i)){let e=[];if(typeof n==`string`){e=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t{let n=this.lookUpDomId(i),r=document.querySelector(`[id="${n}"]`);r!==null&&r.addEventListener(`click`,()=>{g.runFunc(t,...e)},!1)})}}bindFunctions(e){this.functions.forEach(t=>{t(e)})}escapeHtml(e){return e.replace(/&/g,`&`).replace(//g,`>`).replace(/"/g,`"`).replace(/'/g,`'`)}getDirection(){return this.direction}setDirection(e){this.direction=e}static resolveQualifiedId(e,t){let n=t.at(-1);return n?`${n}.${e}`:e}static getAncestorIds(e){let t=e.split(`.`),n=Array(t.length);n[0]=t[0];for(let e=1;e0?a[e-1]:void 0,o=e===a.length-1,s=o&&t?t:r[e];this.namespaces.has(n)?o&&(this.namespaces.get(n).explicit=!0):this.namespaces.set(n,this.createNamespaceNode(n,s,i,o)),i&&this.linkParentChild(i,n)}return n}popNamespace(){this.namespaceStack.pop()}getNamespace(e){return this.namespaces.get(e)}getNamespaces(){return this.namespaces}addClassesToNamespace(e,t,n){if(this.namespaces.has(e)){for(let n of t){let{className:t}=this.splitClassNameAndType(n),r=this.getClass(t);r.parent=e,this.namespaces.get(e).classes.set(t,r)}for(let t of n){let n=this.getNote(t);n.parent=e,this.namespaces.get(e).notes.set(t,n)}}}setCssStyle(e,t){let n=this.classes.get(e);if(!(!t||!n))for(let e of t)e.includes(`,`)?n.styles.push(...e.split(`,`)):n.styles.push(e)}getArrowMarker(e){let t;switch(e){case 0:t=`aggregation`;break;case 1:t=`extension`;break;case 2:t=`composition`;break;case 3:t=`dependency`;break;case 4:t=`lollipop`;break;default:t=`none`}return t}resolveExplicitAncestor(e){let t=e;for(;t;){let e=this.namespaces.get(t);if(!e)return;if(e.explicit)return t;t=e.parent}}getData(){let e=[],t=[],n=f(),r=n.class?.hierarchicalNamespaces??!0;for(let t of this.namespaces.values()){if(!r&&!t.explicit)continue;let i={id:t.id,label:r?t.label:t.id,isGroup:!0,padding:n.class.padding??16,shape:`rect`,cssStyles:[],look:n.look,parentId:r?t.parent:void 0};e.push(i)}let i=0;for(let t of this.classes.values()){let a=r?t.parent:this.resolveExplicitAncestor(t.parent),o={...t,type:void 0,isGroup:!1,parentId:a,look:n.look,colorIndex:i++};e.push(o)}for(let i of this.notes.values()){let a=r?i.parent:this.resolveExplicitAncestor(i.parent),o={id:i.id,label:i.text,isGroup:!1,shape:`note`,padding:n.class.padding??6,cssStyles:[`text-align: left`,`white-space: nowrap`,`fill: ${n.themeVariables.noteBkgColor}`,`stroke: ${n.themeVariables.noteBorderColor}`],look:n.look,parentId:a,labelType:`markdown`};e.push(o);let s=this.classes.get(i.class)?.id;if(s){let e={id:`edgeNote${i.index}`,start:i.id,end:s,type:`normal`,thickness:`normal`,classes:`relation`,arrowTypeStart:`none`,arrowTypeEnd:`none`,arrowheadStyle:``,labelStyle:[``],style:[`fill: none`],pattern:`dotted`,look:n.look};t.push(e)}}for(let t of this.interfaces){let r={id:t.id,label:t.label,isGroup:!1,shape:`rect`,cssStyles:[`opacity: 0;`],look:n.look};e.push(r)}let a=0;for(let e of this.relations){a++;let r={id:h(e.id1,e.id2,{prefix:`id`,counter:a}),start:e.id1,end:e.id2,type:`normal`,label:e.title,labelpos:`c`,thickness:`normal`,classes:`relation`,arrowTypeStart:this.getArrowMarker(e.relation.type1),arrowTypeEnd:this.getArrowMarker(e.relation.type2),startLabelRight:e.relationTitle1===`none`?``:e.relationTitle1,endLabelLeft:e.relationTitle2===`none`?``:e.relationTitle2,arrowheadStyle:``,labelStyle:[`display: inline-block`],style:e.style||``,pattern:e.relation.lineType==1?`dashed`:`solid`,look:n.look,labelType:`markdown`};t.push(r)}return{nodes:e,edges:t,other:{},config:n,direction:this.getDirection()}}},F=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!_(t,r))return``;let i=y(e.look),a=b(n),o=``;for(let t=0;t{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`)},styles:n(e=>`${F(e)} + g.classGroup text { + fill: ${e.nodeBorder||e.classText}; + stroke: none; + font-family: ${e.fontFamily}; + font-size: 10px; + + .title { + font-weight: bolder; + } + +} + + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + +.nodeLabel, .edgeLabel { + color: ${e.classText}; +} + +.noteLabel .nodeLabel, .noteLabel .edgeLabel { + color: ${e.noteTextColor}; +} +.edgeLabel .label rect { + fill: ${e.mainBkg}; +} +.label text { + fill: ${e.classText}; +} + +.labelBkg { + background: ${e.mainBkg}; +} +.edgeLabel .label span { + background: ${e.mainBkg}; +} + +.classTitle { + font-weight: bolder; +} +.node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth}; + } + + +.divider { + stroke: ${e.nodeBorder}; + stroke-width: 1; +} + +g.clickable { + cursor: pointer; +} + +g.classGroup rect { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; +} + +g.classGroup line { + stroke: ${e.nodeBorder}; + stroke-width: 1; +} + +.classLabel .box { + stroke: none; + stroke-width: 0; + fill: ${e.mainBkg}; + opacity: 0.5; +} + +.classLabel .label { + fill: ${e.nodeBorder}; + font-size: 10px; +} + +.relation { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth}; + fill: none; +} + +.dashed-line{ + stroke-dasharray: 3; +} + +.dotted-line{ + stroke-dasharray: 1 2; +} + +[id$="-compositionStart"], .composition { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-compositionEnd"], .composition { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-dependencyStart"], .dependency { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-dependencyEnd"], .dependency { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-extensionStart"], .extension { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-extensionEnd"], .extension { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-aggregationStart"], .aggregation { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-aggregationEnd"], .aggregation { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-lollipopStart"], .lollipop { + fill: ${e.mainBkg} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-lollipopEnd"], .lollipop { + fill: ${e.mainBkg} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +.edgeTerminals { + font-size: 11px; + line-height: initial; +} + +.classTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; +} + +.edgeLabel[data-look="neo"] { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; +} + ${C()} +`,`getStyles`),init:n(e=>{e.class||={},e.class.arrowMarkerAbsolute=e.arrowMarkerAbsolute},`init`)};export{I as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js b/frontend/dist/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js new file mode 100644 index 0000000..3affc47 --- /dev/null +++ b/frontend/dist/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js @@ -0,0 +1 @@ +import{_ as e,m as t,p as n,y as r}from"./src-D_iIdUkB.js";import{n as i}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{t as a}from"./cytoscape.esm-CECbKnxF.js";var o=e(((e,t)=>{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r():typeof define==`function`&&define.amd?define([],r):typeof e==`object`?e.layoutBase=r():n.layoutBase=r()})(e,function(){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=26)})([(function(e,t,n){function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,e.exports=r}),(function(e,t,n){var r=n(2),i=n(8),a=n(9);function o(e,t,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=e,this.target=t}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];o.prototype.getSource=function(){return this.source},o.prototype.getTarget=function(){return this.target},o.prototype.isInterGraph=function(){return this.isInterGraph},o.prototype.getLength=function(){return this.length},o.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},o.prototype.getBendpoints=function(){return this.bendpoints},o.prototype.getLca=function(){return this.lca},o.prototype.getSourceInLca=function(){return this.sourceInLca},o.prototype.getTargetInLca=function(){return this.targetInLca},o.prototype.getOtherEnd=function(e){if(this.source===e)return this.target;if(this.target===e)return this.source;throw`Node is not incident with this edge`},o.prototype.getOtherEndInGraph=function(e,t){for(var n=this.getOtherEnd(e),r=t.getGraphManager().getRoot();;){if(n.getOwner()==t)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},o.prototype.updateLength=function(){var e=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),e),this.isOverlapingSourceAndTarget||(this.lengthX=e[0]-e[2],this.lengthY=e[1]-e[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},o.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},e.exports=o}),(function(e,t,n){function r(e){this.vGraphObject=e}e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(13),o=n(0),s=n(16),c=n(4);function l(e,t,n,o){n==null&&o==null&&(o=t),r.call(this,o),e.graphManager!=null&&(e=e.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=o,this.edges=[],this.graphManager=e,this.rect=n!=null&&t!=null?new a(t.x,t.y,n.width,n.height):new a}for(var u in l.prototype=Object.create(r.prototype),r)l[u]=r[u];l.prototype.getEdges=function(){return this.edges},l.prototype.getChild=function(){return this.child},l.prototype.getOwner=function(){return this.owner},l.prototype.getWidth=function(){return this.rect.width},l.prototype.setWidth=function(e){this.rect.width=e},l.prototype.getHeight=function(){return this.rect.height},l.prototype.setHeight=function(e){this.rect.height=e},l.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},l.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},l.prototype.getCenter=function(){return new c(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},l.prototype.getLocation=function(){return new c(this.rect.x,this.rect.y)},l.prototype.getRect=function(){return this.rect},l.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},l.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},l.prototype.setRect=function(e,t){this.rect.x=e.x,this.rect.y=e.y,this.rect.width=t.width,this.rect.height=t.height},l.prototype.setCenter=function(e,t){this.rect.x=e-this.rect.width/2,this.rect.y=t-this.rect.height/2},l.prototype.setLocation=function(e,t){this.rect.x=e,this.rect.y=t},l.prototype.moveBy=function(e,t){this.rect.x+=e,this.rect.y+=t},l.prototype.getEdgeListToNode=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.target==e){if(r.source!=n)throw`Incorrect edge source!`;t.push(r)}}),t},l.prototype.getEdgesBetween=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.source!=n&&r.target!=n)throw`Incorrect edge source and/or target`;(r.target==e||r.source==e)&&t.push(r)}),t},l.prototype.getNeighborsList=function(){var e=new Set,t=this;return t.edges.forEach(function(n){if(n.source==t)e.add(n.target);else{if(n.target!=t)throw`Incorrect incidency!`;e.add(n.source)}}),e},l.prototype.withChildren=function(){var e=new Set,t,n;if(e.add(this),this.child!=null)for(var r=this.child.getNodes(),i=0;it&&(this.rect.x-=(this.labelWidth-t)/2,this.setWidth(this.labelWidth)),this.labelHeight>n&&(this.labelPos==`center`?this.rect.y-=(this.labelHeight-n)/2:this.labelPos==`top`&&(this.rect.y-=this.labelHeight-n),this.setHeight(this.labelHeight))}}},l.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw`assert failed`;return this.inclusionTreeDepth},l.prototype.transform=function(e){var t=this.rect.x;t>o.WORLD_BOUNDARY?t=o.WORLD_BOUNDARY:t<-o.WORLD_BOUNDARY&&(t=-o.WORLD_BOUNDARY);var n=this.rect.y;n>o.WORLD_BOUNDARY?n=o.WORLD_BOUNDARY:n<-o.WORLD_BOUNDARY&&(n=-o.WORLD_BOUNDARY);var r=new c(t,n),i=e.inverseTransformPoint(r);this.setLocation(i.x,i.y)},l.prototype.getLeft=function(){return this.rect.x},l.prototype.getRight=function(){return this.rect.x+this.rect.width},l.prototype.getTop=function(){return this.rect.y},l.prototype.getBottom=function(){return this.rect.y+this.rect.height},l.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},e.exports=l}),(function(e,t,n){function r(e,t){e==null&&t==null?(this.x=0,this.y=0):(this.x=e,this.y=t)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(e){this.x=e},r.prototype.setY=function(e){this.y=e},r.prototype.getDifference=function(e){return new DimensionD(this.x-e.x,this.y-e.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(e){return this.x+=e.width,this.y+=e.height,this},e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(0),o=n(6),s=n(3),c=n(1),l=n(13),u=n(12),d=n(11);function f(e,t,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=e,t!=null&&t instanceof o?this.graphManager=t:t!=null&&t instanceof Layout&&(this.graphManager=t.graphManager)}for(var p in f.prototype=Object.create(r.prototype),r)f[p]=r[p];f.prototype.getNodes=function(){return this.nodes},f.prototype.getEdges=function(){return this.edges},f.prototype.getGraphManager=function(){return this.graphManager},f.prototype.getParent=function(){return this.parent},f.prototype.getLeft=function(){return this.left},f.prototype.getRight=function(){return this.right},f.prototype.getTop=function(){return this.top},f.prototype.getBottom=function(){return this.bottom},f.prototype.isConnected=function(){return this.isConnected},f.prototype.add=function(e,t,n){if(t==null&&n==null){var r=e;if(this.graphManager==null)throw`Graph has no graph mgr!`;if(this.getNodes().indexOf(r)>-1)throw`Node already in graph!`;return r.owner=this,this.getNodes().push(r),r}var i=e;if(!(this.getNodes().indexOf(t)>-1&&this.getNodes().indexOf(n)>-1))throw`Source or target not in graph!`;if(t.owner!=n.owner||t.owner!=this)throw`Both owners must be this graph!`;return t.owner==n.owner?(i.source=t,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),t.edges.push(i),n!=t&&n.edges.push(i),i):null},f.prototype.remove=function(e){var t=e;if(e instanceof s){if(t==null)throw`Node is null!`;if(t.owner==null||t.owner!=this)throw`Owner graph is invalid!`;if(this.graphManager==null)throw`Owner graph manager is invalid!`;for(var n=t.edges.slice(),r,i=n.length,a=0;a-1&&u>-1))throw`Source and/or target doesn't know this edge!`;r.source.edges.splice(l,1),r.target!=r.source&&r.target.edges.splice(u,1);var o=r.source.owner.getEdges().indexOf(r);if(o==-1)throw`Not in owner's edge list!`;r.source.owner.getEdges().splice(o,1)}},f.prototype.updateLeftTop=function(){for(var e=i.MAX_VALUE,t=i.MAX_VALUE,n,r,a,o=this.getNodes(),s=o.length,c=0;cn&&(e=n),t>r&&(t=r)}return e==i.MAX_VALUE?null:(a=o[0].getParent().paddingLeft==null?this.margin:o[0].getParent().paddingLeft,this.left=t-a,this.top=e-a,new u(this.left,this.top))},f.prototype.updateBounds=function(e){for(var t=i.MAX_VALUE,n=-i.MAX_VALUE,r=i.MAX_VALUE,a=-i.MAX_VALUE,o,s,c,u,d,f=this.nodes,p=f.length,m=0;mo&&(t=o),nc&&(r=c),ao&&(t=o),nc&&(r=c),a=this.nodes.length){var c=0;n.forEach(function(t){t.owner==e&&c++}),c==this.nodes.length&&(this.isConnected=!0)}},e.exports=f}),(function(e,t,n){var r,i=n(1);function a(e){r=n(5),this.layout=e,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var e=this.layout.newGraph(),t=this.layout.newNode(null),n=this.add(e,t);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(e,t,n,r,i){if(n==null&&r==null&&i==null){if(e==null)throw`Graph is null!`;if(t==null)throw`Parent node is null!`;if(this.graphs.indexOf(e)>-1)throw`Graph already in this graph mgr!`;if(this.graphs.push(e),e.parent!=null)throw`Already has a parent!`;if(t.child!=null)throw`Already has a child!`;return e.parent=t,t.child=e,e}i=n,r=t,n=e;var a=r.getOwner(),o=i.getOwner();if(a==null||a.getGraphManager()!=this)throw`Source not in this graph mgr!`;if(o==null||o.getGraphManager()!=this)throw`Target not in this graph mgr!`;if(a==o)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw`Edge already in inter-graph edge list!`;if(this.edges.push(n),n.source==null||n.target==null)throw`Edge source and/or target is null!`;if(n.source.edges.indexOf(n)!=-1||n.target.edges.indexOf(n)!=-1)throw`Edge already in source and/or target incidency list!`;return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(e){if(e instanceof r){var t=e;if(t.getGraphManager()!=this)throw`Graph not in this graph mgr`;if(!(t==this.rootGraph||t.parent!=null&&t.parent.graphManager==this))throw`Invalid parent node!`;var n=[];n=n.concat(t.getEdges());for(var a,o=n.length,s=0;s=t.getRight()?n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight()):t.getX()<=e.getX()&&t.getRight()>=e.getRight()&&(n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight())),e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()?n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()):t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()&&(n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()));var a=Math.abs((t.getCenterY()-e.getCenterY())/(t.getCenterX()-e.getCenterX()));t.getCenterY()===e.getCenterY()&&t.getCenterX()===e.getCenterX()&&(a=1);var o=a*n[0],s=n[1]/a;n[0]o)return n[0]=r,n[1]=c,n[2]=a,n[3]=y,!1;if(ia)return n[0]=s,n[1]=i,n[2]=_,n[3]=o,!1;if(ra?(n[0]=u,n[1]=d,C=!0):(n[0]=l,n[1]=c,C=!0):T===D&&(r>a?(n[0]=s,n[1]=c,C=!0):(n[0]=f,n[1]=d,C=!0)),-E===D?a>r?(n[2]=v,n[3]=y,w=!0):(n[2]=_,n[3]=g,w=!0):E===D&&(a>r?(n[2]=h,n[3]=g,w=!0):(n[2]=b,n[3]=y,w=!0)),C&&w)return!1;if(r>a?i>o?(O=this.getCardinalDirection(T,D,4),k=this.getCardinalDirection(E,D,2)):(O=this.getCardinalDirection(-T,D,3),k=this.getCardinalDirection(-E,D,1)):i>o?(O=this.getCardinalDirection(-T,D,1),k=this.getCardinalDirection(-E,D,3)):(O=this.getCardinalDirection(T,D,2),k=this.getCardinalDirection(E,D,4)),!C)switch(O){case 1:j=c,A=r+-m/D,n[0]=A,n[1]=j;break;case 2:A=f,j=i+p*D,n[0]=A,n[1]=j;break;case 3:j=d,A=r+m/D,n[0]=A,n[1]=j;break;case 4:A=u,j=i+-p*D,n[0]=A,n[1]=j}if(!w)switch(k){case 1:N=g,M=a+-S/D,n[2]=M,n[3]=N;break;case 2:M=b,N=o+x*D,n[2]=M,n[3]=N;break;case 3:N=y,M=a+S/D,n[2]=M,n[3]=N;break;case 4:M=v,N=o+-x*D,n[2]=M,n[3]=N}}return!1},i.getCardinalDirection=function(e,t,n){return e>t?n:1+n%4},i.getIntersection=function(e,t,n,i){if(i==null)return this.getIntersection2(e,t,n);var a=e.x,o=e.y,s=t.x,c=t.y,l=n.x,u=n.y,d=i.x,f=i.y,p=void 0,m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0;return h=c-o,_=a-s,y=s*o-a*c,g=f-u,v=l-d,b=d*u-l*f,x=h*v-g*_,x===0?null:(p=(_*b-v*y)/x,m=(g*y-h*b)/x,new r(p,m))},i.angleOfVector=function(e,t,n,r){var i=void 0;return e===n?i=r0?1:e<0?-1:0},r.floor=function(e){return e<0?Math.ceil(e):Math.floor(e)},r.ceil=function(e){return e<0?Math.floor(e):Math.ceil(e)},e.exports=r}),(function(e,t,n){function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n0&&t;){for(s.push(l[0]);s.length>0&&t;){var u=s[0];s.splice(0,1),o.add(u);for(var d=u.getEdges(),a=0;a-1&&l.splice(h,1)}o=new Set,c=new Map}}return e},f.prototype.createDummyNodesForBendpoints=function(e){for(var t=[],n=e.source,r=this.graphManager.calcLowestCommonAncestor(e.source,e.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&t.splice(d,1),s.getNeighborsList().forEach(function(e){if(n.indexOf(e)<0){var t=r.get(e)-1;t==1&&l.push(e),r.set(e,t)}})}n=n.concat(l),(t.length==1||t.length==2)&&(i=!0,a=t[0])}return a},f.prototype.setGraphManager=function(e){this.graphManager=e},e.exports=f}),(function(e,t,n){function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=Math.sin(r.seed++)*1e4,r.x-Math.floor(r.x)},e.exports=r}),(function(e,t,n){var r=n(4);function i(e,t){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(e){this.lworldExtX=e},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(e){this.lworldExtY=e},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},i.prototype.transformX=function(e){var t=0,n=this.lworldExtX;return n!=0&&(t=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/n),t},i.prototype.transformY=function(e){var t=0,n=this.lworldExtY;return n!=0&&(t=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/n),t},i.prototype.inverseTransformX=function(e){var t=0,n=this.ldeviceExtX;return n!=0&&(t=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/n),t},i.prototype.inverseTransformY=function(e){var t=0,n=this.ldeviceExtY;return n!=0&&(t=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/n),t},i.prototype.inverseTransformPoint=function(e){return new r(this.inverseTransformX(e.x),this.inverseTransformY(e.y))},e.exports=i}),(function(e,t,n){function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);ta.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*a.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-a.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT_INCREMENTAL):(this.coolingFactor=e>a.ADAPTATION_LOWER_NODE_LIMIT?Math.max(a.COOLING_ADAPTATION_FACTOR,1-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*(1-a.COOLING_ADAPTATION_FACTOR)):1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var e=this.getAllEdges(),t,n=0;n0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n,r,i,o,s=this.getAllNodes(),c;if(this.useFRGridVariant)for(this.totalIterations%a.GRID_CALCULATION_CHECK_PERIOD==1&&e&&this.updateGrid(),c=new Set,n=0;nc||s>c)&&(e.gravitationForceX=-this.gravityConstant*i,e.gravitationForceY=-this.gravityConstant*a)):(c=t.getEstimatedSize()*this.compoundGravityRangeFactor,(o>c||s>c)&&(e.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,e.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant))},l.prototype.isConverged=function(){var e,t=!1;return this.totalIterations>this.maxIterations/3&&(t=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),e=this.totalDisplacement=c.length||u>=c[0].length)){for(var d=0;de}}]),e}()}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:1,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,e),this.sequence1=t,this.sequence2=n,this.match_score=r,this.mismatch_penalty=a,this.gap_penalty=o,this.iMax=t.length+1,this.jMax=n.length+1,this.grid=Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===e&&r.callback===t&&this.listeners.splice(n,1)}},i.emit=function(e,t){for(var n=0;n{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(o()):typeof define==`function`&&define.amd?define([`layout-base`],r):typeof e==`object`?e.coseBase=r(o()):n.coseBase=r(n.layoutBase)})(e,function(e){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=7)})([(function(t,n){t.exports=e}),(function(e,t,n){var r=n(0).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TREE_REDUCTION_ON_INCREMENTAL=!1,e.exports=i}),(function(e,t,n){var r=n(0).FDLayoutEdge;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).LGraph;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).LGraphManager;function i(e){r.call(this,e)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).FDLayoutNode,i=n(0).IMath;function a(e,t,n,i){r.call(this,e,t,n,i)}for(var o in a.prototype=Object.create(r.prototype),r)a[o]=r[o];a.prototype.move=function(){var e=this.graphManager.getLayout();this.displacementX=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementX=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementY=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementY)),this.child==null||this.child.getNodes().length==0?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),e.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},a.prototype.propogateDisplacementToChildren=function(e,t){for(var n=this.getChild().getNodes(),r,i=0;i0)this.positionNodesRadially(e);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}else if(c.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n)}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},v.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}if(this.totalIterations%l.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0){if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),t=this.nodesWithGravity.filter(function(t){return e.has(t)});this.graphManager.setAllNodesToApplyGravitation(t),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0}this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},v.prototype.getPositionsData=function(){for(var e=this.graphManager.getAllNodes(),t={},n=0;n1){var s;for(s=0;sr&&(r=Math.floor(o.y)),a=Math.floor(o.x+c.DEFAULT_COMPONENT_SEPERATION)}this.transform(new f(u.WORLD_CENTER_X-o.x/2,u.WORLD_CENTER_Y-o.y/2))},v.radialLayout=function(e,t,n){var r=Math.max(this.maxDiagonalInTree(e),c.DEFAULT_RADIAL_SEPARATION);v.branchRadialLayout(t,null,0,359,0,r);var i=g.calculateBounds(e),a=new _;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var o=0;o1;){var _=g[0];g.splice(0,1);var y=u.indexOf(_);y>=0&&u.splice(y,1),p--,d--}m=t==null?0:(u.indexOf(g[0])+1)%p;for(var b=Math.abs(r-n)/d,x=m;f!=d;x=++x%p){var S=u[x].getOtherEnd(e);if(S!=t){var C=(n+f*b)%360,w=(C+b)%360;v.branchRadialLayout(S,e,C,w,i+a,a),f++}}},v.maxDiagonalInTree=function(e){for(var t=m.MIN_VALUE,n=0;nt&&(t=r)}return t},v.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},v.prototype.groupZeroDegreeMembers=function(){var e=this,t={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r=`DummyCompound_`+n;e.memberGroups[r]=t[n];var i=t[n][0].getParent(),a=new o(e.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,e.idToDummyNode[r]=a;var s=e.getGraphManager().add(e.newGraph(),a),c=i.getChild();c.add(a);for(var l=0;l=0;e--){var t=this.compoundOrder[e],n=t.id,r=t.paddingLeft,i=t.paddingTop;this.adjustLocations(this.tiledMemberPack[n],t.rect.x,t.rect.y,r,i)}},v.prototype.repopulateZeroDegreeMembers=function(){var e=this,t=this.tiledZeroDegreePack;Object.keys(t).forEach(function(n){var r=e.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop;e.adjustLocations(t[n],r.rect.x,r.rect.y,i,a)})},v.prototype.getToBeTiled=function(e){var t=e.id;if(this.toBeTiled[t]!=null)return this.toBeTiled[t];var n=e.getChild();if(n==null)return this.toBeTiled[t]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[t]=!1,!1;if(a.getChild()==null){this.toBeTiled[a.id]=!1;continue}if(!this.getToBeTiled(a))return this.toBeTiled[t]=!1,!1}return this.toBeTiled[t]=!0,!0},v.prototype.getNodeDegree=function(e){e.id;for(var t=e.getEdges(),n=0,r=0;rc&&(c=u.rect.height)}n+=c+e.verticalPadding}},v.prototype.tileCompoundMembers=function(e,t){var n=this;this.tiledMemberPack=[],Object.keys(e).forEach(function(r){var i=t[r];n.tiledMemberPack[r]=n.tileNodes(e[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height})},v.prototype.tileNodes=function(e,t){var n={rows:[],rowWidth:[],rowHeight:[],width:0,height:t,verticalPadding:c.TILING_PADDING_VERTICAL,horizontalPadding:c.TILING_PADDING_HORIZONTAL};e.sort(function(e,t){return e.rect.width*e.rect.height>t.rect.width*t.rect.height?-1:+(e.rect.width*e.rect.height0&&(a+=e.horizontalPadding),e.rowWidth[n]=a,e.width0&&(o+=e.verticalPadding);var s=0;o>e.rowHeight[n]&&(s=e.rowHeight[n],e.rowHeight[n]=o,s=e.rowHeight[n]-s),e.height+=s,e.rows[n].push(t)},v.prototype.getShortestRowIndex=function(e){for(var t=-1,n=Number.MAX_VALUE,r=0;rn&&(t=r,n=e.rowWidth[r]);return t},v.prototype.canAddHorizontal=function(e,t,n){var r=this.getShortestRowIndex(e);if(r<0)return!0;var i=e.rowWidth[r];if(i+e.horizontalPadding+t<=e.width)return!0;var a=0;e.rowHeight[r]0&&(a=n+e.verticalPadding-e.rowHeight[r]);var o=e.width-i>=t+e.horizontalPadding?(e.height+a)/(i+t+e.horizontalPadding):(e.height+a)/e.width;a=n+e.verticalPadding;var s=e.widtha&&t!=n){r.splice(-1,1),e.rows[n].push(i),e.rowWidth[t]=e.rowWidth[t]-a,e.rowWidth[n]=e.rowWidth[n]+a,e.width=e.rowWidth[instance.getLongestRowIndex(e)];for(var o=Number.MIN_VALUE,s=0;so&&(o=r[s].height);t>0&&(o+=e.verticalPadding);var c=e.rowHeight[t]+e.rowHeight[n];e.rowHeight[t]=o,e.rowHeight[n]0)for(var u=i;u<=a;u++)c[0]+=this.grid[u][o-1].length+this.grid[u][o].length-1;if(a0)for(var u=o;u<=s;u++)c[3]+=this.grid[i-1][u].length+this.grid[i][u].length-1;for(var d=m.MAX_VALUE,f,p,h=0;h{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(s()):typeof define==`function`&&define.amd?define([`cose-base`],r):typeof e==`object`?e.cytoscapeCoseBilkent=r(s()):n.cytoscapeCoseBilkent=r(n.coseBase)})(e,function(e){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=1)})([(function(t,n){t.exports=e}),(function(e,t,n){var r=n(0).layoutBase.LayoutConstants,i=n(0).layoutBase.FDLayoutConstants,a=n(0).CoSEConstants,o=n(0).CoSELayout,s=n(0).CoSENode,c=n(0).layoutBase.PointD,l=n(0).layoutBase.DimensionD,u={ready:function(){},stop:function(){},quality:`default`,nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:`end`,animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function d(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n}function f(e){this.options=d(u,e),p(this.options)}var p=function(e){e.nodeRepulsion!=null&&(a.DEFAULT_REPULSION_STRENGTH=i.DEFAULT_REPULSION_STRENGTH=e.nodeRepulsion),e.idealEdgeLength!=null&&(a.DEFAULT_EDGE_LENGTH=i.DEFAULT_EDGE_LENGTH=e.idealEdgeLength),e.edgeElasticity!=null&&(a.DEFAULT_SPRING_STRENGTH=i.DEFAULT_SPRING_STRENGTH=e.edgeElasticity),e.nestingFactor!=null&&(a.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=e.nestingFactor),e.gravity!=null&&(a.DEFAULT_GRAVITY_STRENGTH=i.DEFAULT_GRAVITY_STRENGTH=e.gravity),e.numIter!=null&&(a.MAX_ITERATIONS=i.MAX_ITERATIONS=e.numIter),e.gravityRange!=null&&(a.DEFAULT_GRAVITY_RANGE_FACTOR=i.DEFAULT_GRAVITY_RANGE_FACTOR=e.gravityRange),e.gravityCompound!=null&&(a.DEFAULT_COMPOUND_GRAVITY_STRENGTH=i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=e.gravityCompound),e.gravityRangeCompound!=null&&(a.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=e.gravityRangeCompound),e.initialEnergyOnIncremental!=null&&(a.DEFAULT_COOLING_FACTOR_INCREMENTAL=i.DEFAULT_COOLING_FACTOR_INCREMENTAL=e.initialEnergyOnIncremental),r.QUALITY=e.quality==`draft`?0:e.quality==`proof`?2:1,a.NODE_DIMENSIONS_INCLUDE_LABELS=i.NODE_DIMENSIONS_INCLUDE_LABELS=r.NODE_DIMENSIONS_INCLUDE_LABELS=e.nodeDimensionsIncludeLabels,a.DEFAULT_INCREMENTAL=i.DEFAULT_INCREMENTAL=r.DEFAULT_INCREMENTAL=!e.randomize,a.ANIMATE=i.ANIMATE=r.ANIMATE=e.animate,a.TILE=e.tile,a.TILING_PADDING_VERTICAL=typeof e.tilingPaddingVertical==`function`?e.tilingPaddingVertical.call():e.tilingPaddingVertical,a.TILING_PADDING_HORIZONTAL=typeof e.tilingPaddingHorizontal==`function`?e.tilingPaddingHorizontal.call():e.tilingPaddingHorizontal};f.prototype.run=function(){var e,t,n=this.options;this.idToLNode={};var r=this.layout=new o,i=this;i.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:`layoutstart`,layout:this});var a=r.newGraphManager();this.gm=a;var s=this.options.eles.nodes(),c=this.options.eles.edges();this.root=a.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(s),r);for(var l=0;l0){var h=n.getGraphManager().add(n.newGraph(),u);this.processChildrenList(h,o,n)}}},f.prototype.stop=function(){return this.stopped=!0,this};var m=function(e){e(`layout`,`cose-bilkent`,f)};typeof cytoscape<`u`&&m(cytoscape),e.exports=m})])})}))(),1);a.use(c.default);function l(e,t){e.forEach(e=>{let n={id:e.id,labelText:e.label,height:e.height,width:e.width,padding:e.padding??0};Object.keys(e).forEach(t=>{[`id`,`label`,`height`,`width`,`padding`,`x`,`y`].includes(t)||(n[t]=e[t])}),t.add({group:`nodes`,data:n,position:{x:e.x??0,y:e.y??0}})})}i(l,`addNodes`);function u(e,t){e.forEach(e=>{let n={id:e.id,source:e.start,target:e.end};Object.keys(e).forEach(t=>{[`id`,`start`,`end`].includes(t)||(n[t]=e[t])}),t.add({group:`edges`,data:n})})}i(u,`addEdges`);function d(e){return new Promise(r=>{let i=n(`body`).append(`div`).attr(`id`,`cy`).attr(`style`,`display:none`),o=a({container:document.getElementById(`cy`),style:[{selector:`edge`,style:{"curve-style":`bezier`}}]});i.remove(),l(e.nodes,o),u(e.edges,o),o.nodes().forEach(function(e){e.layoutDimensions=()=>{let t=e.data();return{w:t.width,h:t.height}}}),o.layout({name:`cose-bilkent`,quality:`proof`,styleEnabled:!1,animate:!1}).run(),o.ready(e=>{t.info(`Cytoscape ready`,e),r(o)})})}i(d,`createCytoscapeInstance`);function f(e){return e.nodes().map(e=>{let t=e.data(),n=e.position(),r={id:t.id,x:n.x,y:n.y};return Object.keys(t).forEach(e=>{e!==`id`&&(r[e]=t[e])}),r})}i(f,`extractPositionedNodes`);function p(e){return e.edges().map(e=>{let t=e.data(),n=e._private.rscratch,r={id:t.id,source:t.source,target:t.target,startX:n.startX,startY:n.startY,midX:n.midX,midY:n.midY,endX:n.endX,endY:n.endY};return Object.keys(t).forEach(e=>{[`id`,`source`,`target`].includes(e)||(r[e]=t[e])}),r})}i(p,`extractPositionedEdges`);async function m(e,n){t.debug(`Starting cose-bilkent layout algorithm`);try{h(e);let n=await d(e),r=f(n),i=p(n);return t.debug(`Layout completed: ${r.length} nodes, ${i.length} edges`),{nodes:r,edges:i}}catch(e){throw t.error(`Error in cose-bilkent layout algorithm:`,e),e}}i(m,`executeCoseBilkentLayout`);function h(e){if(!e)throw Error(`Layout data is required`);if(!e.config)throw Error(`Configuration is required in layout data`);if(!e.rootNode)throw Error(`Root node is required`);if(!e.nodes||!Array.isArray(e.nodes))throw Error(`No nodes found in layout data`);if(!Array.isArray(e.edges))throw Error(`Edges array is required in layout data`);return!0}i(h,`validateLayoutData`);var g=i(async(e,t,{insertCluster:n,insertEdge:r,insertEdgeLabel:i,insertMarkers:a,insertNode:o,log:s,positionEdgeLabel:c},{algorithm:l})=>{let u={},d={},f=t.select(`g`);a(f,e.markers,e.type,e.diagramId);let p=f.insert(`g`).attr(`class`,`subgraphs`),h=f.insert(`g`).attr(`class`,`edgePaths`),g=f.insert(`g`).attr(`class`,`edgeLabels`),_=f.insert(`g`).attr(`class`,`nodes`);s.debug(`Inserting nodes into DOM for dimension calculation`),await Promise.all(e.nodes.map(async t=>{if(t.isGroup){let e={...t};d[t.id]=e,u[t.id]=e,await n(p,t)}else{let n={...t};u[t.id]=n;let r=await o(_,t,{config:e.config,dir:e.direction||`TB`}),i=r.node().getBBox();n.width=i.width,n.height=i.height,n.domId=r,s.debug(`Node ${t.id} dimensions: ${i.width}x${i.height}`)}})),s.debug(`Running cose-bilkent layout algorithm`);let v=await m({...e,nodes:e.nodes.map(e=>{let t=u[e.id];return{...e,width:t.width,height:t.height}})},e.config);s.debug(`Positioning nodes based on layout results`),v.nodes.forEach(e=>{let t=u[e.id];t?.domId&&(t.domId.attr(`transform`,`translate(${e.x}, ${e.y})`),t.x=e.x,t.y=e.y,s.debug(`Positioned node ${t.id} at center (${e.x}, ${e.y})`))}),v.edges.forEach(t=>{let n=e.edges.find(e=>e.id===t.id);n&&(n.points=[{x:t.startX,y:t.startY},{x:t.midX,y:t.midY},{x:t.endX,y:t.endY}])}),s.debug(`Inserting and positioning edges`),await Promise.all(e.edges.map(async t=>{await i(g,t);let n=u[t.start??``],a=u[t.end??``];if(n&&a){let i=v.edges.find(e=>e.id===t.id);if(i){s.debug(`APA01 positionedEdge`,i);let o={...t};c(o,r(h,o,d,e.type,n,a,e.diagramId))}else{let i={...t,points:[{x:n.x||0,y:n.y||0},{x:a.x||0,y:a.y||0}]};c(i,r(h,i,d,e.type,n,a,e.diagramId))}}})),s.debug(`Cose-bilkent rendering completed`)},`render`);export{g as render}; \ No newline at end of file diff --git a/frontend/dist/assets/cynefin-OW5HDTMX-DebjIew_.js b/frontend/dist/assets/cynefin-OW5HDTMX-DebjIew_.js new file mode 100644 index 0000000..5a5c26a --- /dev/null +++ b/frontend/dist/assets/cynefin-OW5HDTMX-DebjIew_.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{A as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createCynefinServices}; \ No newline at end of file diff --git a/frontend/dist/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js b/frontend/dist/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js new file mode 100644 index 0000000..87aa78d --- /dev/null +++ b/frontend/dist/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js @@ -0,0 +1,62 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=t(()=>({domains:new Map,transitions:[]}),`createDefaultData`),v=_(),y={getDomains:t(()=>v.domains,`getDomains`),getTransitions:t(()=>v.transitions,`getTransitions`),setDomains:t(e=>{if(e)for(let t of e){let e=t.domain,n=(t.items??[]).map(e=>({label:e.label}));v.domains.set(e,{name:e,items:n})}},`setDomains`),setTransitions:t(t=>{t&&(v.transitions=t.filter(t=>t.from!==t.to||(e.warn(`Cynefin: self-loop transition on domain "${t.from}" is not meaningful and will be skipped.`),!1)).map(e=>({from:e.from,to:e.to,label:e.label||void 0})))},`setTransitions`),getConfig:t(()=>p({...c.cynefin,...o().cynefin}),`getConfig`),clear:t(()=>{a(),v=_()},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r},b=t(e=>{g(e,y),y.setDomains(e.domains),y.setTransitions(e.transitions)},`populate`),x={parse:t(async t=>{let n=await h(`cynefin`,t);e.debug(n),b(n)},`parse`)};function S(e){let t=e+1831565813|0;return t=Math.imul(t^t>>>15,t|1),t^=t+Math.imul(t^t>>>7,t|61),((t^t>>>14)>>>0)/4294967296}t(S,`seededRandom`);function C(e){let t=0;for(let n=0;n{let n=e/2,r=t/2;return{complex:{cx:n/2,cy:r/2,x:0,y:0,w:n,h:r},complicated:{cx:n+n/2,cy:r/2,x:n,y:0,w:n,h:r},chaotic:{cx:n/2,cy:r+r/2,x:0,y:r,w:n,h:r},clear:{cx:n+n/2,cy:r+r/2,x:n,y:r,w:n,h:r},confusion:{cx:n,cy:r,x:n*.7,y:r*.7,w:n*.6,h:r*.6}}},`getDomainLayouts`),j=t(()=>{let e=n(),t=o();return p(e,t.themeVariables).cynefin},`getCynefinDomainColors`),M=3,N={draw:t((t,n,r,i)=>{let a=i.db,o=a.getDomains(),c=a.getTransitions(),l=a.getDiagramTitle(),u=a.getAccTitle(),d=a.getAccDescription(),f=a.getConfig(),p=j();e.debug(`Rendering Cynefin diagram`);let h=f.width,g=f.height,_=f.padding,v=f.showDomainDescriptions,y=f.boundaryAmplitude,b=h+_*2,x=g+_*2,S={complex:p.complexBg,complicated:p.complicatedBg,clear:p.clearBg,chaotic:p.chaoticBg,confusion:p.confusionBg},C=m(n);s(C,x,b,f.useMaxWidth??!0),C.attr(`viewBox`,`0 0 ${b} ${x}`),u&&C.append(`title`).text(u),d&&C.append(`desc`).text(d);let N=C.append(`g`).attr(`transform`,`translate(${_}, ${_})`),P=A(h,g),F=w(f.seed,n),I=N.append(`g`).attr(`class`,`cynefin-backgrounds`),L=[`complex`,`complicated`,`chaotic`,`clear`];for(let e of L){let t=P[e];I.append(`rect`).attr(`class`,`cynefinDomain`).attr(`x`,t.x).attr(`y`,t.y).attr(`width`,t.w).attr(`height`,t.h).attr(`fill`,S[e]).attr(`fill-opacity`,.4).attr(`stroke`,`none`)}let R=N.append(`g`).attr(`class`,`cynefin-boundaries`);R.append(`path`).attr(`class`,`cynefinBoundary`).attr(`d`,T(h,g,F,y)).attr(`fill`,`none`),R.append(`path`).attr(`class`,`cynefinBoundary`).attr(`d`,E(h,g,F+100,y)).attr(`fill`,`none`),R.append(`path`).attr(`class`,`cynefinCliff`).attr(`d`,D(h,g)).attr(`fill`,`none`);let z=h*.15,B=g*.15;N.append(`path`).attr(`class`,`cynefinConfusion`).attr(`d`,O(h/2,g/2,z,B)).attr(`fill`,S.confusion).attr(`fill-opacity`,.5);let V=N.append(`g`).attr(`class`,`cynefin-labels`);for(let e of L){let t=P[e];V.append(`text`).attr(`class`,`cynefinDomainLabel`).attr(`x`,t.cx).attr(`y`,v?t.cy-30:t.cy).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(e.charAt(0).toUpperCase()+e.slice(1))}if(V.append(`text`).attr(`class`,`cynefinDomainLabel`).attr(`x`,h/2).attr(`y`,v?g/2-10:g/2).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(`Confusion`),v){let e=N.append(`g`).attr(`class`,`cynefin-subtitles`);for(let t of L){let n=P[t],r=k[t];e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,n.cx).attr(`y`,n.cy-10).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(r.model),e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,n.cx).attr(`y`,n.cy+5).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(r.practice)}e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,h/2).attr(`y`,g/2+8).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(k.confusion.practice)}let H=N.append(`g`).attr(`class`,`cynefin-items`);for(let e of[`complex`,`complicated`,`chaotic`,`clear`,`confusion`]){let t=o.get(e);if(!t||t.items.length===0)continue;let n=P[e],r=e===`confusion`,i=t.items,a=0;r&&t.items.length>M&&(a=t.items.length-M,i=t.items.slice(0,M));let s;if(r){let e=v?22:14;s=n.cy+e}else s=n.cy+(v?25:15);if([...i].forEach((t,r)=>{let i=s+r*30,a=H.append(`g`),o=a.append(`text`).attr(`class`,`cynefinItemText`).attr(`x`,0).attr(`y`,13).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).text(t.label),c=t.label.length*7,l=o.node();if(l&&typeof l.getBBox==`function`){let e=l.getBBox();e.width>0&&(c=e.width)}let u=c+20,d=n.cx-u/2;a.attr(`transform`,`translate(${d}, ${i})`),a.insert(`rect`,`text`).attr(`class`,`cynefinItem`).attr(`x`,0).attr(`y`,0).attr(`width`,u).attr(`height`,26).attr(`rx`,4).attr(`ry`,4).attr(`fill`,S[e]).attr(`fill-opacity`,.95),o.attr(`x`,u/2).attr(`y`,13)}),a>0){let t=s+i.length*30,r=`+${a} more`,o=H.append(`g`),c=o.append(`text`).attr(`class`,`cynefinItemText`).attr(`x`,0).attr(`y`,13).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).text(r),l=r.length*7,u=c.node();if(u&&typeof u.getBBox==`function`){let e=u.getBBox();e.width>0&&(l=e.width)}let d=l+20,f=n.cx-d/2;o.attr(`transform`,`translate(${f}, ${t})`),o.insert(`rect`,`text`).attr(`class`,`cynefinItemOverflow`).attr(`x`,0).attr(`y`,0).attr(`width`,d).attr(`height`,26).attr(`rx`,4).attr(`ry`,4).attr(`fill`,S[e]).attr(`fill-opacity`,.6),c.attr(`x`,d/2).attr(`y`,13)}}if(c.length>0){let t=C.select(`defs`).empty()?C.append(`defs`):C.select(`defs`),r=`cynefin-arrow-${n}`;t.append(`marker`).attr(`id`,r).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`class`,`cynefinArrowHead`);let i=N.append(`g`).attr(`class`,`cynefin-arrows`);c.forEach(t=>{let n=P[t.from],a=P[t.to];if(!n||!a)return;if(t.from===t.to){e.warn(`Cynefin renderer: skipping self-loop on domain "${t.from}"`);return}let o=n.cx,s=n.cy,c=a.cx,l=a.cy,u=(o+c)/2,d=(s+l)/2,f=c-o,p=l-s,m=Math.sqrt(f*f+p*p),h=m*.15,g=-p/m,_=f/m,v=u+g*h,y=d+_*h;i.append(`path`).attr(`class`,`cynefinArrowLine`).attr(`d`,`M${o},${s} Q${v},${y} ${c},${l}`).attr(`fill`,`none`).attr(`marker-end`,`url(#${r})`),t.label&&i.append(`text`).attr(`class`,`cynefinArrowLabel`).attr(`x`,v).attr(`y`,y-6).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`auto`).text(t.label)})}l&&N.append(`text`).attr(`class`,`cynefinTitle`).attr(`x`,h/2).attr(`y`,-_/2).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(l)},`draw`)},P=t(()=>{let e=n(),t=o();return p(e,t.themeVariables).cynefin},`getCynefinTheme`),F={parser:x,db:y,renderer:N,styles:t(()=>{let e=P();return` + .cynefinDomain { + stroke: none; + } + .cynefinDomainLabel { + font-size: ${e.domainFontSize}px; + font-weight: bold; + fill: ${e.labelColor}; + } + .cynefinSubtitle { + font-size: ${e.itemFontSize-1}px; + fill: ${e.textColor}; + font-style: italic; + } + .cynefinItem { + fill-opacity: 0.95; + stroke: ${e.boundaryColor}; + stroke-width: 1; + } + .cynefinItemText { + font-size: ${e.itemFontSize}px; + fill: ${e.textColor}; + } + .cynefinItemOverflow { + fill-opacity: 0.6; + stroke: ${e.boundaryColor}; + stroke-width: 1; + stroke-dasharray: 3 2; + } + .cynefinBoundary { + stroke: ${e.boundaryColor}; + stroke-width: ${e.boundaryWidth}; + stroke-dasharray: 6 3; + } + .cynefinCliff { + stroke: ${e.cliffColor}; + stroke-width: ${e.cliffWidth}; + } + .cynefinConfusion { + stroke: ${e.boundaryColor}; + stroke-width: 1.5; + stroke-dasharray: 4 2; + } + .cynefinArrowLine { + stroke: ${e.arrowColor}; + stroke-width: ${e.arrowWidth}; + fill: none; + } + .cynefinArrowHead { + fill: ${e.arrowColor}; + stroke: none; + } + .cynefinArrowLabel { + font-size: ${e.itemFontSize-1}px; + fill: ${e.textColor}; + } + .cynefinTitle { + font-size: ${e.domainFontSize+2}px; + font-weight: bold; + fill: ${e.labelColor}; + } + `},`styles`)};export{F as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/cytoscape.esm-CECbKnxF.js b/frontend/dist/assets/cytoscape.esm-CECbKnxF.js new file mode 100644 index 0000000..486bfe9 --- /dev/null +++ b/frontend/dist/assets/cytoscape.esm-CECbKnxF.js @@ -0,0 +1,321 @@ +function e(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a,o=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||n.return==null||n.return()}finally{if(s)throw a}}}}function s(e,t,n){return(t=h(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function c(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function l(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function u(){throw TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function d(){throw TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function f(e,n){return t(e)||l(e,n)||_(e,n)||u()}function p(e){return n(e)||c(e)||_(e)||d()}function m(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return String(e)}function h(e){var t=m(e,`string`);return typeof t==`symbol`?t:t+``}function g(e){"@babel/helpers - typeof";return g=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},g(e)}function _(t,n){if(t){if(typeof t==`string`)return e(t,n);var r={}.toString.call(t).slice(8,-1);return r===`Object`&&t.constructor&&(r=t.constructor.name),r===`Map`||r===`Set`?Array.from(t):r===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?e(t,n):void 0}}var v=typeof window>`u`?null:window,y=v?v.navigator:null;v&&v.document;var b=g(``),x=g({}),S=g(function(){}),C=typeof HTMLElement>`u`?`undefined`:g(HTMLElement),w=function(e){return e&&e.instanceString&&E(e.instanceString)?e.instanceString():null},T=function(e){return e!=null&&g(e)==b},E=function(e){return e!=null&&g(e)===S},D=function(e){return!N(e)&&(Array.isArray?Array.isArray(e):e!=null&&e instanceof Array)},O=function(e){return e!=null&&g(e)===x&&!D(e)&&e.constructor===Object},k=function(e){return e!=null&&g(e)===x},A=function(e){return e!=null&&g(e)===g(1)&&!isNaN(e)},j=function(e){return A(e)&&Math.floor(e)===e},M=function(e){if(C!==`undefined`)return e!=null&&e instanceof HTMLElement},N=function(e){return P(e)||F(e)},P=function(e){return w(e)===`collection`&&e._private.single},F=function(e){return w(e)===`collection`&&!e._private.single},I=function(e){return w(e)===`core`},L=function(e){return w(e)===`stylesheet`},R=function(e){return w(e)===`event`},z=function(e){return e==null||!!(e===``||e.match(/^\s+$/))},B=function(e){return typeof HTMLElement>`u`?!1:e instanceof HTMLElement},V=function(e){return O(e)&&A(e.x1)&&A(e.x2)&&A(e.y1)&&A(e.y2)},H=function(e){return k(e)&&E(e.then)},U=function(){return y&&y.userAgent.match(/msie|trident|edge/i)},W=function(e,t){t||=function(){if(arguments.length===1)return arguments[0];if(arguments.length===0)return`undefined`;for(var e=[],t=0;tt)},ce=function(e,t){return-1*se(e,t)},X=Object.assign==null?function(e){for(var t=arguments,n=1;n1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}var u=RegExp(`^`+re+`$`).exec(e);if(u){if(n=parseInt(u[1]),n<0?n=(360- -1*n%360)%360:n>360&&(n%=360),n/=360,r=parseFloat(u[2]),r<0||r>100||(r/=100,i=parseFloat(u[3]),i<0||i>100)||(i/=100,a=u[4],a!==void 0&&(a=parseFloat(a),a<0||a>1)))return;if(r===0)o=s=c=Math.round(i*255);else{var d=i<.5?i*(1+r):i+r-i*r,f=2*i-d;o=Math.round(255*l(f,d,n+1/3)),s=Math.round(255*l(f,d,n)),c=Math.round(255*l(f,d,n-1/3))}t=[o,s,c,a]}return t},de=function(e){var t,n=RegExp(`^`+te+`$`).exec(e);if(n){t=[];for(var r=[],i=1;i<=3;i++){var a=n[i];if(a[a.length-1]===`%`&&(r[i]=!0),a=parseFloat(a),r[i]&&(a=a/100*255),a<0||a>255)return;t.push(Math.floor(a))}var o=r[1]||r[2]||r[3],s=r[1]&&r[2]&&r[3];if(o&&!s)return;var c=n[4];if(c!==void 0){if(c=parseFloat(c),c<0||c>1)return;t.push(c)}}return t},fe=function(e){return me[e.toLowerCase()]},pe=function(e){return(D(e)?e:null)||fe(e)||le(e)||de(e)||ue(e)},me={transparent:[0,0,0,0],aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],grey:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},he=function(e){for(var t=e.map,n=e.keys,r=n.length,i=0;i=s||t<0||_&&n>=d}function C(){var e=t();if(S(e))return w(e);p=setTimeout(C,x(e))}function w(e){return p=void 0,v&&l?y(e):(l=u=void 0,f)}function T(){p!==void 0&&clearTimeout(p),h=0,l=m=u=p=void 0}function E(){return p===void 0?f:w(t())}function D(){var e=t(),n=S(e);if(l=arguments,u=this,m=e,n){if(p===void 0)return b(m);if(_)return clearTimeout(p),p=setTimeout(C,s),y(m)}return p===void 0&&(p=setTimeout(C,s)),f}return D.cancel=T,D.flush=E,D}return it=o,it}var st=ve(ot()),ct=v?v.performance:null,lt=ct&&ct.now?function(){return ct.now()}:function(){return Date.now()},ut=function(){if(v){if(v.requestAnimationFrame)return function(e){v.requestAnimationFrame(e)};if(v.mozRequestAnimationFrame)return function(e){v.mozRequestAnimationFrame(e)};if(v.webkitRequestAnimationFrame)return function(e){v.webkitRequestAnimationFrame(e)};if(v.msRequestAnimationFrame)return function(e){v.msRequestAnimationFrame(e)}}return function(e){e&&setTimeout(function(){e(lt())},1e3/60)}}(),dt=function(e){return ut(e)},ft=lt,pt=9261,mt=65599,ht=5381,gt=function(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pt,n;n=e.next(),!n.done;)t=t*mt+n.value|0;return t},_t=function(e){return(arguments.length>1&&arguments[1]!==void 0?arguments[1]:pt)*mt+e|0},vt=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ht;return(t<<5)+t+e|0},yt=function(e,t){return e*2097152+t},bt=function(e){return e[0]*2097152+e[1]},xt=function(e,t){return[_t(e[0],t[0]),vt(e[1],t[1])]},St=function(e,t){var n={value:0,done:!1},r=0,i=e.length;return gt({next:function(){return r=0;r--)e[r]===t&&e.splice(r,1)},Jt=function(e){e.splice(0,e.length)},Yt=function(e,t){for(var n=0;n`u`?`undefined`:g(Set))===$t?en:Set,nn=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(e===void 0||t===void 0||!I(e)){Lt(`An element must have a core reference and parameters set`);return}var r=t.group;if(r??=t.data&&t.data.source!=null&&t.data.target!=null?`edges`:`nodes`,r!==`nodes`&&r!==`edges`){Lt("An element must be of type `nodes` or `edges`; you specified `"+r+"`");return}this.length=1,this[0]=this;var i=this._private={cy:e,single:!0,data:t.data||{},position:t.position||{x:0,y:0},autoWidth:void 0,autoHeight:void 0,autoPadding:void 0,compoundBoundsClean:!1,listeners:[],group:r,style:{},rstyle:{},styleCxts:[],styleKeys:{},removed:!0,selected:!!t.selected,selectable:t.selectable===void 0||!!t.selectable,locked:!!t.locked,grabbed:!1,grabbable:t.grabbable===void 0||!!t.grabbable,pannable:t.pannable===void 0?r===`edges`:!!t.pannable,active:!1,classes:new tn,animation:{current:[],queue:[]},rscratch:{},scratch:t.scratch||{},edges:[],children:[],parent:t.parent&&t.parent.isNode()?t.parent:null,traversalCache:{},backgrounding:!1,bbCache:null,bbCacheShift:{x:0,y:0},bodyBounds:null,overlayBounds:null,labelBounds:{all:null,source:null,target:null,main:null},arrowBounds:{source:null,target:null,"mid-source":null,"mid-target":null}};if(i.position.x??(i.position.x=0),i.position.y??(i.position.y=0),t.renderedPosition){var a=t.renderedPosition,o=e.pan(),s=e.zoom();i.position={x:(a.x-o.x)/s,y:(a.y-o.y)/s}}var c=[];D(t.classes)?c=t.classes:T(t.classes)&&(c=t.classes.split(/\s+/));for(var l=0,u=c.length;lt)},l=function(e,t,i,a,o){var s;if(i??=0,o??=n,i<0)throw Error(`lo must be non-negative`);for(a??=e.length;in;0<=n?t++:t--)l.push(t);return l}).apply(this).reverse(),c=[],a=0,o=s.length;ah;0<=h?++f:--f)g.push(a(e,r));return g},m=function(e,t,r,i){var a,o,s;for(i??=n,a=e[r];r>t;){if(s=r-1>>1,o=e[s],i(a,o)<0){e[r]=o,r=s;continue}break}return e[r]=a},h=function(e,t,r){var i,a,o,s,c;for(r??=n,a=e.length,c=t,o=e[t],i=2*t+1;i0;){var x=_.pop(),S=h(x),C=x.id();if(d[C]=S,S!==1/0)for(var w=x.neighborhood().intersect(p),E=0;E0)for(n.unshift(t);u[i];){var a=u[i];n.unshift(a.edge),n.unshift(a.node),r=a.node,i=r.id()}return o.spawn(n)}}}},gn={kruskal:function(e){e||=function(e){return 1};for(var t=this.byGroup(),n=t.nodes,r=t.edges,i=n.length,a=Array(i),o=n,s=function(e){for(var t=0;t0;){if(b(),S++,y===l){for(var C=[],w=i,T=l,E=g[T];C.unshift(w),E!=null&&C.unshift(E),w=h[T],w!=null;)T=w.id(),E=g[T];return{found:!0,distance:u[y],path:this.spawn(C),steps:S}}f[y]=!0;for(var D=v._private.edges,O=0;OE&&(p[w]=E,g[w]=C,_[w]=y),!i){var D=C*l+S;!i&&p[D]>E&&(p[D]=E,g[D]=S,_[D]=y)}}}for(var O=0;O1&&arguments[1]!==void 0?arguments[1]:a,r=v(e),i=[],o=r;;){if(o==null)return t.spawn();var c=_(o),l=c.edge,u=c.pred;if(i.unshift(o[0]),o.same(n)&&i.length>0)break;l!=null&&i.unshift(l),o=u}return s.spawn(i)},x=0;x=0;l--){var u=c[l],d=u[1],f=u[2];(t[d]===o&&t[f]===s||t[d]===s&&t[f]===o)&&c.splice(l,1)}for(var p=0;pr;)t=wn(Math.floor(Math.random()*t.length),e,t),n--;return t},En={kargerStein:function(){var e=this,t=this.byGroup(),n=t.nodes,r=t.edges;r.unmergeBy(function(e){return e.isLoop()});var i=n.length,a=r.length,o=Math.ceil((Math.log(i)/Math.LN2)**2),s=Math.floor(i/Cn);if(i<2){Lt(`At least 2 nodes are required for Karger-Stein algorithm`);return}for(var c=[],l=0;l1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=1/0,i=t;i1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=-1/0,i=t;i1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=0,i=0,a=t;a1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0;r?e=e.slice(t,n):(n0&&e.splice(0,t));for(var o=0,s=e.length-1;s>=0;s--){var c=e[s];a?isFinite(c)||(e[s]=-1/0,o++):e.splice(s,1)}i&&e.sort(function(e,t){return e-t});var l=e.length,u=Math.floor(l/2);return l%2==0?(e[u-1+o]+e[u+o])/2:e[u+1+o]},Fn=function(e,t){return t===0?e:Fn(t,e%t)},In=function(e){for(var t=e[0],n=0;n0&&(t=Fn(t,e[n]));else return 0;return t},Ln=function(e){return Math.PI*e/180},Rn=function(e,t){return Math.atan2(t,e)-Math.PI/2},zn=Math.log2||function(e){return Math.log(e)/Math.log(2)},Bn=function(e){return e>0?1:e<0?-1:0},Vn=function(e,t){return Math.sqrt(Hn(e,t))},Hn=function(e,t){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r},Un=function(e){for(var t=e.length,n=0,r=0;r=e.x1&&e.y2>=e.y1)return{x1:e.x1,y1:e.y1,x2:e.x2,y2:e.y2,w:e.x2-e.x1,h:e.y2-e.y1};if(e.w!=null&&e.h!=null&&e.w>=0&&e.h>=0)return{x1:e.x1,y1:e.y1,x2:e.x1+e.w,y2:e.y1+e.h,w:e.w,h:e.h}}},Yn=function(e){return{x1:e.x1,x2:e.x2,w:e.w,y1:e.y1,y2:e.y2,h:e.h}},Xn=function(e){e.x1=1/0,e.y1=1/0,e.x2=-1/0,e.y2=-1/0,e.w=0,e.h=0},Zn=function(e,t){e.x1=Math.min(e.x1,t.x1),e.x2=Math.max(e.x2,t.x2),e.w=e.x2-e.x1,e.y1=Math.min(e.y1,t.y1),e.y2=Math.max(e.y2,t.y2),e.h=e.y2-e.y1},Qn=function(e,t,n){e.x1=Math.min(e.x1,t),e.x2=Math.max(e.x2,t),e.w=e.x2-e.x1,e.y1=Math.min(e.y1,n),e.y2=Math.max(e.y2,n),e.h=e.y2-e.y1},$n=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return e.x1-=t,e.x2+=t,e.y1-=t,e.y2+=t,e.w=e.x2-e.x1,e.h=e.y2-e.y1,e},er=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[0],n,r,i,a;if(t.length===1)n=r=i=a=t[0];else if(t.length===2)n=i=t[0],a=r=t[1];else if(t.length===4){var o=f(t,4);n=o[0],r=o[1],i=o[2],a=o[3]}return e.x1-=a,e.x2+=r,e.y1-=n,e.y2+=i,e.w=e.x2-e.x1,e.h=e.y2-e.y1,e},tr=function(e,t){e.x1=t.x1,e.y1=t.y1,e.x2=t.x2,e.y2=t.y2,e.w=e.x2-e.x1,e.h=e.y2-e.y1},nr=function(e,t){return!(e.x1>t.x2||t.x1>e.x2||e.x2t.y2||t.y1>e.y2)},rr=function(e,t,n){return e.x1<=t&&t<=e.x2&&e.y1<=n&&n<=e.y2},ir=function(e,t){return rr(e,t.x,t.y)},ar=function(e,t){return rr(e,t.x1,t.y1)&&rr(e,t.x2,t.y2)},or=Math.hypot??function(e,t){return Math.sqrt(e*e+t*t)};function sr(e,t){if(e.length<3)throw Error(`Need at least 3 vertices`);var n=function(e,t){return{x:e.x+t.x,y:e.y+t.y}},r=function(e,t){return{x:e.x-t.x,y:e.y-t.y}},i=function(e,t){return{x:e.x*t,y:e.y*t}},a=function(e,t){return e.x*t.y-e.y*t.x},o=function(e){var t=or(e.x,e.y);return t===0?{x:0,y:0}:{x:e.x/t,y:e.y/t}},s=function(e){for(var t=0,n=0;n7&&arguments[7]!==void 0?arguments[7]:`auto`,c=s===`auto`?Nr(i,a):s,l=i/2,u=a/2;c=Math.min(c,l,u);var d=c!==l,f=c!==u,p;if(d){var m=n-l+c-o,h=r-u-o;if(p=Tr(e,t,n,r,m,h,n+l-c+o,h,!1),p.length>0)return p}if(f){var g=n+l+o;if(p=Tr(e,t,n,r,g,r-u+c-o,g,r+u-c+o,!1),p.length>0)return p}if(d){var _=n-l+c-o,v=r+u+o;if(p=Tr(e,t,n,r,_,v,n+l-c+o,v,!1),p.length>0)return p}if(f){var y=n-l-o;if(p=Tr(e,t,n,r,y,r-u+c-o,y,r+u-c+o,!1),p.length>0)return p}var b,x=n-l+c,S=r-u+c;if(b=Cr(e,t,n,r,x,S,c+o),b.length>0&&b[0]<=x&&b[1]<=S)return[b[0],b[1]];var C=n+l-c,w=r-u+c;if(b=Cr(e,t,n,r,C,w,c+o),b.length>0&&b[0]>=C&&b[1]<=w)return[b[0],b[1]];var T=n+l-c,E=r+u-c;if(b=Cr(e,t,n,r,T,E,c+o),b.length>0&&b[0]>=T&&b[1]>=E)return[b[0],b[1]];var D=n-l+c,O=r+u-c;return b=Cr(e,t,n,r,D,O,c+o),b.length>0&&b[0]<=D&&b[1]>=O?[b[0],b[1]]:[]},ur=function(e,t,n,r,i,a,o){var s=o,c=Math.min(n,i),l=Math.max(n,i),u=Math.min(r,a),d=Math.max(r,a);return c-s<=e&&e<=l+s&&u-s<=t&&t<=d+s},dr=function(e,t,n,r,i,a,o,s,c){var l={x1:Math.min(n,o,i)-c,x2:Math.max(n,o,i)+c,y1:Math.min(r,s,a)-c,y2:Math.max(r,s,a)+c};return!(el.x2||tl.y2)},fr=function(e,t,n,r){n-=r;var i=t*t-4*e*n;if(i<0)return[];var a=Math.sqrt(i),o=2*e;return[(-t+a)/o,(-t-a)/o]},pr=function(e,t,n,r,i){e===0&&(e=1e-5),t/=e,n/=e,r/=e;var a,o=(3*n-t*t)/9,s=-(27*r)+t*(9*n-t*t*2),c,l,u,d,f;if(s/=54,a=o*o*o+s*s,i[1]=0,d=t/3,a>0){l=s+Math.sqrt(a),l=l<0?-((-l)**(1/3)):l**(1/3),u=s-Math.sqrt(a),u=u<0?-((-u)**(1/3)):u**(1/3),i[0]=-d+l+u,d+=(l+u)/2,i[4]=i[2]=-d,d=Math.sqrt(3)*(-u+l)/2,i[3]=d,i[5]=-d;return}if(i[5]=i[3]=0,a===0){f=s<0?-((-s)**(1/3)):s**(1/3),i[0]=-d+2*f,i[4]=i[2]=-(f+d);return}o=-o,c=o*o*o,c=Math.acos(s/Math.sqrt(c)),f=2*Math.sqrt(o),i[0]=-d+f*Math.cos(c/3),i[2]=-d+f*Math.cos((c+2*Math.PI)/3),i[4]=-d+f*Math.cos((c+4*Math.PI)/3)},mr=function(e,t,n,r,i,a,o,s){var c=1*n*n-4*n*i+2*n*o+4*i*i-4*i*o+o*o+r*r-4*r*a+2*r*s+4*a*a-4*a*s+s*s,l=9*n*i-3*n*n-3*n*o-6*i*i+3*i*o+9*r*a-3*r*r-3*r*s-6*a*a+3*a*s,u=3*n*n-6*n*i+n*o-n*e+2*i*i+2*i*e-o*e+3*r*r-6*r*a+r*s-r*t+2*a*a+2*a*t-s*t,d=1*n*i-n*n+n*e-i*e+r*a-r*r+r*t-a*t,f=[];pr(c,l,u,d,f);for(var p=1e-7,m=[],h=0;h<6;h+=2)Math.abs(f[h+1])=0&&f[h]<=1&&m.push(f[h]);m.push(1),m.push(0);for(var g=-1,_,v,y,b=0;b=0?yc?(e-i)*(e-i)+(t-a)*(t-a):l-d},gr=function(e,t,n){for(var r,i,a,o,s,c=0,l=0;l=e&&e>=a||r<=e&&e<=a)s=(e-r)/(a-r)*(o-i)+i,s>t&&c++;else continue}return c%2!=0},_r=function(e,t,n,r,i,a,o,s,c){var l=Array(n.length),u;s[0]==null?u=s:(u=Math.atan(s[1]/s[0]),s[0]<0?u+=Math.PI/2:u=-u-Math.PI/2);for(var d=Math.cos(-u),f=Math.sin(-u),p=0;p0?yr(br(l,-c)):l)},vr=function(e,t,n,r,i,a,o,s){for(var c=Array(n.length*2),l=0;l=0&&h<=1&&_.push(h),g>=0&&g<=1&&_.push(g),_.length===0)return[];var v=_[0]*s[0]+e,y=_[0]*s[1]+t;return _.length>1?_[0]==_[1]?[v,y]:[v,y,_[1]*s[0]+e,_[1]*s[1]+t]:[v,y]},wr=function(e,t,n){return t<=e&&e<=n||n<=e&&e<=t?e:e<=t&&t<=n||n<=t&&t<=e?t:n},Tr=function(e,t,n,r,i,a,o,s,c){var l=e-i,u=n-e,d=o-i,f=t-a,p=r-t,m=s-a,h=d*f-m*l,g=u*f-p*l,_=m*u-d*p;if(_!==0){var v=h/_,y=g/_,b=.001,x=0-b,S=1+b;return x<=v&&v<=S&&x<=y&&y<=S||c?[e+v*u,t+v*p]:[]}return h===0||g===0?wr(e,n,o)===o?[o,s]:wr(e,n,i)===i?[i,a]:wr(i,o,n)===n?[n,r]:[]:[]},Er=function(e,t,n,r,i){var a=[],o=r/2,s=i/2,c=t,l=n;a.push({x:c+o*e[0],y:l+s*e[1]});for(var u=1;u0?yr(br(u,-s)):u}else f=n;for(var m,h,g,_,v=0;v2){for(var p=[l[0],l[1]],m=(p[0]-e)**2+(p[1]-t)**2,h=1;hl&&(l=t)},get:function(e){return c[e]}},d=0;d0?v.edgesTo(_)[0]:_.edgesTo(v)[0];var b=r(y);_=_.id(),l[_]>l[m]+b&&(l[_]=l[m]+b,d.nodes.indexOf(_)<0?d.push(_):d.updateItem(_),c[_]=0,n[_]=[]),l[_]==l[m]+b&&(c[_]=c[_]+c[m],n[_].push(m))}else for(var x=0;x0;){for(var T=t.pop(),E=0;E0&&o.push(n[s]);o.length!==0&&i.push(r.collection(o))}return i},ri=function(e,t){for(var n=0;n5&&arguments[5]!==void 0?arguments[5]:si,o=r,s,c,l=0;l=2?pi(e,t,n,0,ui,di):pi(e,t,n,0,li)},squaredEuclidean:function(e,t,n){return pi(e,t,n,0,ui)},manhattan:function(e,t,n){return pi(e,t,n,0,li)},max:function(e,t,n){return pi(e,t,n,-1/0,fi)}};mi[`squared-euclidean`]=mi.squaredEuclidean,mi.squaredeuclidean=mi.squaredEuclidean;function hi(e,t,n,r,i,a){var o=E(e)?e:mi[e]||mi.euclidean;return t===0&&E(e)?o(i,a):o(t,n,r,i,a)}var gi=Kt({k:2,m:2,sensitivityThreshold:1e-4,distance:`euclidean`,maxIterations:10,attributes:[],testMode:!1,testCentroids:null}),_i=function(e){return gi(e)},vi=function(e,t,n,r,i){var a=i===`kMedoids`?function(e){return r[e](n)}:function(e){return n[e]},o=function(e){return r[e](t)},s=n,c=t;return hi(e,r.length,a,o,s,c)},yi=function(e,t,n){for(var r=n.length,i=Array(r),a=Array(r),o=Array(t),s=null,c=0;cn)return!1;return!0},wi=function(e,t,n){for(var r=0;ro&&(o=t[c][l],s=l);i[s].push(e[c])}for(var u=0;u=i.threshold||i.mode===`dendrogram`&&e.length===1)return!1;var p=t[a],m=t[r[a]],h=i.mode===`dendrogram`?{left:p,right:m,key:p.key}:{value:p.value.concat(m.value),key:p.key};e[p.index]=h,e.splice(m.index,1),t[p.key]=h;for(var g=0;gn[m.key][_.key]&&(s=n[m.key][_.key])):i.linkage===`max`?(s=n[p.key][_.key],n[p.key][_.key]0&&r.push(i);return r},Ji=function(e,t,n){for(var r=[],i=0;io&&(a=c,o=t[i*e+c])}a>0&&r.push(a)}for(var l=0;lc&&(s=l,c=u)}n[i]=a[s]}return r=Ji(e,t,n),r},Xi=function(e){for(var t=this.cy(),n=this.nodes(),r=Wi(e),i={},a=0;a=E?(D=E,E=k,O=A):k>D&&(D=k);for(var j=0;j0);S[w%r.minIterations*o+L]=R,I+=R}if(I>0&&(w>=r.minIterations-1||w==r.maxIterations-1)){for(var z=0,B=0;B1||i>1)&&(o=!0),u[t]=[],e.outgoers().forEach(function(e){e.isEdge()&&u[t].push(e.id())})}else d[t]=[void 0,e.target().id()]}):a.forEach(function(e){var t=e.id();e.isNode()?(e.degree(!0)%2&&(s?c?o=!0:c=t:s=t),u[t]=[],e.connectedEdges().forEach(function(e){return u[t].push(e.id())})):d[t]=[e.source().id(),e.target().id()]});var f={found:!1,trail:void 0};if(o)return f;if(c&&s){if(i){if(l&&c!=l)return f;l=c}else if(l&&c!=l&&s!=l)return f;else l||=c}else l||=a[0].id();var p=function(e){for(var t=e,n=[e],r,a,o;u[t].length;)r=u[t].shift(),a=d[r][0],o=d[r][1],t==o?!i&&t!=a&&(u[a]=u[a].filter(function(e){return e!=r}),t=a):(u[o]=u[o].filter(function(e){return e!=r}),t=o),n.unshift(r),n.unshift(t);return n},m=[],h=[];for(h=p(l);h.length!=1;)u[h[0]].length==0?(m.unshift(a.getElementById(h.shift())),m.unshift(a.getElementById(h.shift()))):h=p(h.shift()).concat(h);for(var g in m.unshift(a.getElementById(h.shift())),u)if(u[g].length)return f;return f.found=!0,f.trail=this.spawn(m,!0),f}},ea=function(){var e=this,t={},n=0,r=0,i=[],a=[],o={},s=function(n,r){for(var o=a.length-1,s=[],c=e.spawn();a[o].x!=n||a[o].y!=r;)s.push(a.pop().edge),o--;s.push(a.pop().edge),s.forEach(function(n){var r=n.connectedNodes().intersection(e);c.merge(n),r.forEach(function(n){var r=n.id(),i=n.connectedEdges().intersection(e);c.merge(n),t[r].cutVertex?c.merge(i.filter(function(e){return e.isLoop()})):c.merge(i)})}),i.push(c)},c=function(l,u,d){l===d&&(r+=1),t[u]={id:n,low:n++,cutVertex:!1};var f=e.getElementById(u).connectedEdges().intersection(e);if(f.size()===0)i.push(e.spawn(e.getElementById(u)));else{var p,m,h,g;f.forEach(function(e){p=e.source().id(),m=e.target().id(),h=p===u?m:p,h!==d&&(g=e.id(),o[g]||(o[g]=!0,a.push({x:u,y:h,edge:e})),h in t?t[u].low=Math.min(t[u].low,t[h].id):(c(l,h,u),t[u].low=Math.min(t[u].low,t[h].low),t[u].id<=t[h].low&&(t[u].cutVertex=!0,s(u,h))))})}};e.forEach(function(e){if(e.isNode()){var n=e.id();n in t||(r=0,c(n,n),t[n].cutVertex=r>1)}});var l=Object.keys(t).filter(function(e){return t[e].cutVertex}).map(function(t){return e.getElementById(t)});return{cut:e.spawn(l),components:i}},ta={hopcroftTarjanBiconnected:ea,htbc:ea,htb:ea,hopcroftTarjanBiconnectedComponents:ea},na=function(){var e=this,t={},n=0,r=[],i=[],a=e.spawn(e),o=function(s){if(i.push(s),t[s]={index:n,low:n++,explored:!1},e.getElementById(s).connectedEdges().intersection(e).forEach(function(e){var n=e.target().id();n!==s&&(n in t||o(n),t[n].explored||(t[s].low=Math.min(t[s].low,t[n].low)))}),t[s].index===t[s].low){for(var c=e.spawn();;){var l=i.pop();if(c.merge(e.getElementById(l)),t[l].low=t[s].index,t[l].explored=!0,l===s)break}var u=c.edgesWith(c),d=c.merge(u);r.push(d),a=a.difference(d)}};return e.forEach(function(e){if(e.isNode()){var n=e.id();n in t||o(n)}}),{cut:a,components:r}},ra={tarjanStronglyConnected:na,tsc:na,tscc:na,tarjanStronglyConnectedComponents:na},ia={};[an,hn,gn,vn,bn,Sn,En,Br,Hr,Wr,Kr,oi,Ni,Hi,Zi,$i,ta,ra].forEach(function(e){X(ia,e)});var aa=0,oa=1,sa=2,ca=function(e){if(!(this instanceof ca))return new ca(e);this.id=`Thenable/1.0.7`,this.state=aa,this.fulfillValue=void 0,this.rejectReason=void 0,this.onFulfilled=[],this.onRejected=[],this.proxy={then:this.then.bind(this)},typeof e==`function`&&e.call(this,this.fulfill.bind(this),this.reject.bind(this))};ca.prototype={fulfill:function(e){return la(this,oa,`fulfillValue`,e)},reject:function(e){return la(this,sa,`rejectReason`,e)},then:function(e,t){var n=this,r=new ca;return n.onFulfilled.push(fa(e,r,`fulfill`)),n.onRejected.push(fa(t,r,`reject`)),ua(n),r.proxy}};var la=function(e,t,n,r){return e.state===aa&&(e.state=t,e[n]=r,ua(e)),e},ua=function(e){e.state===oa?da(e,`onFulfilled`,e.fulfillValue):e.state===sa&&da(e,`onRejected`,e.rejectReason)},da=function(e,t,n){if(e[t].length!==0){var r=e[t];e[t]=[];var i=function(){for(var e=0;e0}},clearQueue:function(){return function(){var e=this,t=e.length===void 0?[e]:e;if(!(this._private.cy||this).styleEnabled())return this;for(var n=0;n-1}return Oo=t,Oo}var jo,Mo;function No(){if(Mo)return jo;Mo=1;var e=xo();function t(t,n){var r=this.__data__,i=e(r,t);return i<0?(++this.size,r.push([t,n])):r[i][1]=n,this}return jo=t,jo}var Po,Fo;function Io(){if(Fo)return Po;Fo=1;var e=ho(),t=wo(),n=Do(),r=Ao(),i=No();function a(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&n%1==0&&n0&&this.spawn(r).updateStyle().emit(`class`),t},addClass:function(e){return this.toggleClass(e,!0)},hasClass:function(e){var t=this[0];return t!=null&&t._private.classes.has(e)},toggleClass:function(e,t){D(e)||(e=e.match(/\S+/g)||[]);for(var n=this,r=t===void 0,i=[],a=0,o=n.length;a0&&this.spawn(i).updateStyle().emit(`class`),n},removeClass:function(e){return this.toggleClass(e,!1)},flashClass:function(e,t){var n=this;if(t==null)t=250;else if(t===0)return n;return n.addClass(e),setTimeout(function(){n.removeClass(e)},t),n}};_c.className=_c.classNames=_c.classes;var Z={metaChar:`[\\!\\"\\#\\$\\%\\&\\'\\(\\)\\*\\+\\,\\.\\/\\:\\;\\<\\=\\>\\?\\@\\[\\]\\^\\\`\\{\\|\\}\\~]`,comparatorOp:`=|\\!=|>|>=|<|<=|\\$=|\\^=|\\*=`,boolOp:`\\?|\\!|\\^`,string:`"(?:\\\\"|[^"])*"|'(?:\\\\'|[^'])*'`,number:Y,meta:`degree|indegree|outdegree`,separator:`\\s*,\\s*`,descendant:`\\s+`,child:`\\s+>\\s+`,subject:`\\$`,group:`node|edge|\\*`,directedEdge:`\\s+->\\s+`,undirectedEdge:`\\s+<->\\s+`};Z.variable=`(?:[\\w-.]|(?:\\\\`+Z.metaChar+`))+`,Z.className=`(?:[\\w-]|(?:\\\\`+Z.metaChar+`))+`,Z.value=Z.string+`|`+Z.number,Z.id=Z.variable,(function(){var e=Z.comparatorOp.split(`|`),t,n;for(n=0;n=0)&&t!==`=`&&(Z.comparatorOp+=`|\\!`+t)})();var vc=function(){return{checks:[]}},Q={GROUP:0,COLLECTION:1,FILTER:2,DATA_COMPARE:3,DATA_EXIST:4,DATA_BOOL:5,META_COMPARE:6,STATE:7,ID:8,CLASS:9,UNDIRECTED_EDGE:10,DIRECTED_EDGE:11,NODE_SOURCE:12,NODE_TARGET:13,NODE_NEIGHBOR:14,CHILD:15,DESCENDANT:16,PARENT:17,ANCESTOR:18,COMPOUND_SPLIT:19,TRUE:20},yc=[{selector:`:selected`,matches:function(e){return e.selected()}},{selector:`:unselected`,matches:function(e){return!e.selected()}},{selector:`:selectable`,matches:function(e){return e.selectable()}},{selector:`:unselectable`,matches:function(e){return!e.selectable()}},{selector:`:locked`,matches:function(e){return e.locked()}},{selector:`:unlocked`,matches:function(e){return!e.locked()}},{selector:`:visible`,matches:function(e){return e.visible()}},{selector:`:hidden`,matches:function(e){return!e.visible()}},{selector:`:transparent`,matches:function(e){return e.transparent()}},{selector:`:grabbed`,matches:function(e){return e.grabbed()}},{selector:`:free`,matches:function(e){return!e.grabbed()}},{selector:`:removed`,matches:function(e){return e.removed()}},{selector:`:inside`,matches:function(e){return!e.removed()}},{selector:`:grabbable`,matches:function(e){return e.grabbable()}},{selector:`:ungrabbable`,matches:function(e){return!e.grabbable()}},{selector:`:animated`,matches:function(e){return e.animated()}},{selector:`:unanimated`,matches:function(e){return!e.animated()}},{selector:`:parent`,matches:function(e){return e.isParent()}},{selector:`:childless`,matches:function(e){return e.isChildless()}},{selector:`:child`,matches:function(e){return e.isChild()}},{selector:`:orphan`,matches:function(e){return e.isOrphan()}},{selector:`:nonorphan`,matches:function(e){return e.isChild()}},{selector:`:compound`,matches:function(e){return e.isNode()?e.isParent():e.source().isParent()||e.target().isParent()}},{selector:`:loop`,matches:function(e){return e.isLoop()}},{selector:`:simple`,matches:function(e){return e.isSimple()}},{selector:`:active`,matches:function(e){return e.active()}},{selector:`:inactive`,matches:function(e){return!e.active()}},{selector:`:backgrounding`,matches:function(e){return e.backgrounding()}},{selector:`:nonbackgrounding`,matches:function(e){return!e.backgrounding()}}].sort(function(e,t){return ce(e.selector,t.selector)}),bc=function(){for(var e={},t,n=0;n0&&l.edgeCount>0)return zt("The selector `"+e+"` is invalid because it uses both a compound selector and an edge selector"),!1;if(l.edgeCount>1)return zt("The selector `"+e+"` is invalid because it uses multiple edge selectors"),!1;l.edgeCount===1&&zt("The selector `"+e+"` is deprecated. Edge selectors do not take effect on changes to source and target nodes after an edge is added, for performance reasons. Use a class or data selector on edges instead, updating the class or data of an edge when your app detects a change in source or target nodes.")}return!0},toString:function(){if(this.toStringCache!=null)return this.toStringCache;for(var e=function(e){return e??``},t=function(t){return T(t)?`"`+t+`"`:e(t)},n=function(e){return` `+e+` `},r=function(r,a){var o=r.type,s=r.value;switch(o){case Q.GROUP:var c=e(s);return c.substring(0,c.length-1);case Q.DATA_COMPARE:var l=r.field,u=r.operator;return`[`+l+n(e(u))+t(s)+`]`;case Q.DATA_BOOL:var d=r.operator,f=r.field;return`[`+e(d)+f+`]`;case Q.DATA_EXIST:return`[`+r.field+`]`;case Q.META_COMPARE:var p=r.operator;return`[[`+r.field+n(e(p))+t(s)+`]]`;case Q.STATE:return s;case Q.ID:return`#`+s;case Q.CLASS:return`.`+s;case Q.PARENT:case Q.CHILD:return i(r.parent,a)+n(`>`)+i(r.child,a);case Q.ANCESTOR:case Q.DESCENDANT:return i(r.ancestor,a)+` `+i(r.descendant,a);case Q.COMPOUND_SPLIT:var m=i(r.left,a),h=i(r.subject,a),g=i(r.right,a);return m+(m.length>0?` `:``)+h+g;case Q.TRUE:return``}},i=function(e,t){return e.checks.reduce(function(n,i,a){return n+(t===e&&a===0?`$`:``)+r(i,t)},``)},a=``,o=0;o1&&o=0&&(t=t.replace(`!`,``),u=!0),t.indexOf(`@`)>=0&&(t=t.replace(`@`,``),l=!0),(i||o||l)&&(s=!i&&!a?``:``+e,c=``+n),l&&(e=s=s.toLowerCase(),n=c=c.toLowerCase()),t){case`*=`:r=s.indexOf(c)>=0;break;case`$=`:r=s.indexOf(c,s.length-c.length)>=0;break;case`^=`:r=s.indexOf(c)===0;break;case`=`:r=e===n;break;case`>`:d=!0,r=e>n;break;case`>=`:d=!0,r=e>=n;break;case`<`:d=!0,r=e0;){var l=i.shift();t(l),a.add(l.id()),o&&r(i,a,l)}return e}function Uc(e,t,n){if(n.isParent())for(var r=n._private.children,i=0;i1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Uc)};function Wc(e,t,n){if(n.isChild()){var r=n._private.parent;t.has(r.id())||e.push(r)}}Vc.forEachUp=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Wc)};function Gc(e,t,n){Wc(e,t,n),Uc(e,t,n)}Vc.forEachUpAndDown=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Gc)},Vc.ancestors=Vc.parents;var Kc=qc={data:hc.data({field:`data`,bindingEvent:`data`,allowBinding:!0,allowSetting:!0,settingEvent:`data`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),removeData:hc.removeData({field:`data`,event:`data`,triggerFnName:`trigger`,triggerEvent:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),scratch:hc.data({field:`scratch`,bindingEvent:`scratch`,allowBinding:!0,allowSetting:!0,settingEvent:`scratch`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeScratch:hc.removeData({field:`scratch`,event:`scratch`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0}),rscratch:hc.data({field:`rscratch`,allowBinding:!1,allowSetting:!0,settingTriggersEvent:!1,allowGetting:!0}),removeRscratch:hc.removeData({field:`rscratch`,triggerEvent:!1}),id:function(){var e=this[0];if(e)return e._private.data.id}},qc;Kc.attr=Kc.data,Kc.removeAttr=Kc.removeData;var Jc=qc,Yc={};function Xc(e){return function(t){var n=this;if(t===void 0&&(t=!0),n.length!==0&&n.isNode()&&!n.removed()){for(var r=0,i=n[0],a=i._private.edges,o=0;ot}),minIndegree:Zc(`indegree`,function(e,t){return et}),minOutdegree:Zc(`outdegree`,function(e,t){return et})}),X(Yc,{totalDegree:function(e){for(var t=0,n=this.nodes(),r=0;r0,d=u;u&&(l=l[0]);var f=d?l.position():{x:0,y:0};t===void 0?i!==void 0&&c.position({x:i.x+f.x,y:i.y+f.y}):c.position(e,t+f[e])}else{var p=n.position(),m=o?n.parent():null,h=m&&m.length>0,g=h;h&&(m=m[0]);var _=g?m.position():{x:0,y:0};return i={x:p.x-_.x,y:p.y-_.y},e===void 0?i:i[e]}}else if(!a)return;return this}},Qc.modelPosition=Qc.point=Qc.position,Qc.modelPositions=Qc.points=Qc.positions,Qc.renderedPoint=Qc.renderedPosition,Qc.relativePoint=Qc.relativePosition;var nl=$c,rl=function(e){switch(e){case`left`:case`right-inside`:return`left`;case`right`:case`left-inside`:return`right`;default:return`center`}},il=function(e){switch(e){case`top`:case`bottom-inside`:return`top`;case`bottom`:case`top-inside`:return`bottom`;default:return`center`}},al=function(e){switch(e){case`left`:return`right`;case`right`:return`left`;case`left-inside`:return`left`;case`right-inside`:return`right`;default:return`center`}},ol=sl={},sl;sl.renderedBoundingBox=function(e){var t=this.boundingBox(e),n=this.cy(),r=n.zoom(),i=n.pan(),a=t.x1*r+i.x,o=t.x2*r+i.x,s=t.y1*r+i.y,c=t.y2*r+i.y;return{x1:a,x2:o,y1:s,y2:c,w:o-a,h:c-s}},sl.dirtyCompoundBoundsCache=function(){var e=arguments.length>0&&arguments[0]!==void 0&&arguments[0],t=this.cy();return!t.styleEnabled()||!t.hasCompoundNodes()||this.forEachUp(function(t){if(t.isParent()){var n=t._private;n.compoundBoundsClean=!1,n.bbCache=null,e||t.emitAndNotify(`bounds`)}}),this},sl.updateCompoundBounds=function(){var e=arguments.length>0&&arguments[0]!==void 0&&arguments[0],t=this.cy();if(!t.styleEnabled()||!t.hasCompoundNodes()||!e&&t.batching())return this;function n(e){if(!e.isParent())return;var t=e._private,n=e.children(),r=e.pstyle(`compound-sizing-wrt-labels`).value===`include`,i={width:{val:e.pstyle(`min-width`).pfValue,left:e.pstyle(`min-width-bias-left`),right:e.pstyle(`min-width-bias-right`)},height:{val:e.pstyle(`min-height`).pfValue,top:e.pstyle(`min-height-bias-top`),bottom:e.pstyle(`min-height-bias-bottom`)}},a=n.boundingBox({includeLabels:r,includeOverlays:!1,useCache:!1}),o=t.position;(a.w===0||a.h===0)&&(a={w:e.pstyle(`width`).pfValue,h:e.pstyle(`height`).pfValue},a.x1=o.x-a.w/2,a.x2=o.x+a.w/2,a.y1=o.y-a.h/2,a.y2=o.y+a.h/2);function s(e,t,n){var r=0,i=0,a=t+n;return e>0&&a>0&&(r=t/a*e,i=n/a*e),{biasDiff:r,biasComplementDiff:i}}function c(e,t,n,r){if(n.units===`%`)switch(r){case`width`:return e>0?n.pfValue*e:0;case`height`:return t>0?n.pfValue*t:0;case`average`:return e>0&&t>0?n.pfValue*(e+t)/2:0;case`min`:return e>0&&t>0?e>t?n.pfValue*t:n.pfValue*e:0;case`max`:return e>0&&t>0?e>t?n.pfValue*e:n.pfValue*t:0;default:return 0}else if(n.units===`px`)return n.pfValue;else return 0}var l=i.width.left.value;i.width.left.units===`px`&&i.width.val>0&&(l=l*100/i.width.val);var u=i.width.right.value;i.width.right.units===`px`&&i.width.val>0&&(u=u*100/i.width.val);var d=i.height.top.value;i.height.top.units===`px`&&i.height.val>0&&(d=d*100/i.height.val);var f=i.height.bottom.value;i.height.bottom.units===`px`&&i.height.val>0&&(f=f*100/i.height.val);var p=s(i.width.val-a.w,l,u),m=p.biasDiff,h=p.biasComplementDiff,g=s(i.height.val-a.h,d,f),_=g.biasDiff,v=g.biasComplementDiff;t.autoPadding=c(a.w,a.h,e.pstyle(`padding`),e.pstyle(`padding-relative-to`).value),t.autoWidth=Math.max(a.w,i.width.val),o.x=(-m+a.x1+a.x2+h)/2,t.autoHeight=Math.max(a.h,i.height.val),o.y=(-_+a.y1+a.y2+v)/2}for(var r=0;re.x2?r:e.x2,e.y1=ne.y2?i:e.y2,e.w=e.x2-e.x1,e.h=e.y2-e.y1)},ul=function(e,t){return t==null?e:ll(e,t.x1,t.y1,t.x2,t.y2)},dl=function(e,t,n){return Xt(e,t,n)},fl=function(e,t,n){if(!t.cy().headless()){var r=t._private,i=r.rstyle,a=i.arrowWidth/2,o=t.pstyle(n+`-arrow-shape`).value,s,c;if(o!==`none`){n===`source`?(s=i.srcX,c=i.srcY):n===`target`?(s=i.tgtX,c=i.tgtY):(s=i.midX,c=i.midY);var l=r.arrowBounds=r.arrowBounds||{},u=l[n]=l[n]||{};u.x1=s-a,u.y1=c-a,u.x2=s+a,u.y2=c+a,u.w=u.x2-u.x1,u.h=u.y2-u.y1,$n(u,1),ll(e,u.x1,u.y1,u.x2,u.y2)}}},pl=function(e,t,n){if(!t.cy().headless()){var r=n?n+`-`:``,i=t._private,a=i.rstyle;if(t.pstyle(r+`label`).strValue){var o=t.pstyle(`text-halign`),s=t.pstyle(`text-valign`),c=dl(a,`labelWidth`,n),l=dl(a,`labelHeight`,n),u=dl(a,`labelX`,n),d=dl(a,`labelY`,n),f=t.pstyle(r+`text-margin-x`).pfValue,p=t.pstyle(r+`text-margin-y`).pfValue,m=t.isEdge(),h=t.pstyle(r+`text-rotation`),g=t.pstyle(`text-outline-width`).pfValue,_=t.pstyle(`text-border-width`).pfValue/2,v=t.pstyle(`text-background-padding`).pfValue,y=2,b=l,x=c,S=x/2,C=b/2,w,T,E,D;if(m)w=u-S,T=u+S,E=d-C,D=d+C;else{switch(rl(o.value)){case`left`:w=u-x,T=u;break;case`center`:w=u-S,T=u+S;break;case`right`:w=u,T=u+x}switch(il(s.value)){case`top`:E=d-b,D=d;break;case`center`:E=d-C,D=d+C;break;case`bottom`:E=d,D=d+b}}var O=f-Math.max(g,_)-v-y,k=f+Math.max(g,_)+v+y,A=p-Math.max(g,_)-v-y,j=p+Math.max(g,_)+v+y;w+=O,T+=k,E+=A,D+=j;var M=n||`main`,N=i.labelBounds,P=N[M]=N[M]||{};P.x1=w,P.y1=E,P.x2=T,P.y2=D,P.w=T-w,P.h=D-E,P.leftPad=O,P.rightPad=k,P.topPad=A,P.botPad=j;var F=m&&h.strValue===`autorotate`,I=h.pfValue!=null&&h.pfValue!==0;if(F||I){var L=F?dl(i.rstyle,`labelAngle`,n):h.pfValue,R=Math.cos(L),z=Math.sin(L),B=(w+T)/2,V=(E+D)/2;if(!m){switch(rl(o.value)){case`left`:B=T;break;case`right`:B=w}switch(il(s.value)){case`top`:V=D;break;case`bottom`:V=E}}var H=function(e,t){return e-=B,t-=V,{x:e*R-t*z+B,y:e*z+t*R+V}},U=H(w,E),W=H(w,D),G=H(T,E),K=H(T,D);w=Math.min(U.x,W.x,G.x,K.x),T=Math.max(U.x,W.x,G.x,K.x),E=Math.min(U.y,W.y,G.y,K.y),D=Math.max(U.y,W.y,G.y,K.y)}var q=M+`Rot`,J=N[q]=N[q]||{};J.x1=w,J.y1=E,J.x2=T,J.y2=D,J.w=T-w,J.h=D-E,ll(e,w,E,T,D),ll(i.labelBounds.all,w,E,T,D)}return e}},ml=function(e,t){if(!t.cy().headless()){var n=t.pstyle(`outline-opacity`).value,r=t.pstyle(`outline-width`).value+t.pstyle(`outline-offset`).value;hl(e,t,n,r,`outside`,r/2)}},hl=function(e,t,n,r,i,a){if(!(n===0||r<=0||i===`inside`)){var o=t.cy().renderer(),s=o.nodeShapes[o.getNodeShape(t)];if(s){var c=t.position(),l=c.x,u=c.y,d=t.width(),f=t.height();s.hasMiterBounds?(i===`center`&&(r/=2),ul(e,s.miterBounds(l,u,d,f,r))):a!=null&&a>0&&er(e,[a,a,a,a])}}},gl=function(e,t){if(!t.cy().headless()){var n=t.pstyle(`border-opacity`).value,r=t.pstyle(`border-width`).pfValue,i=t.pstyle(`border-position`).value;hl(e,t,n,r,i)}},_l=function(e,t){var n=e._private.cy,r=n.styleEnabled(),i=n.headless(),a=Jn(),o=e._private,s=e.isNode(),c=e.isEdge(),l,u,d,f,p,m,h=o.rstyle,g=s&&r?e.pstyle(`bounds-expansion`).pfValue:[0],_=function(e){return e.pstyle(`display`).value!==`none`},v=!r||_(e)&&(!c||_(e.source())&&_(e.target()));if(v){var y=0,b=0;r&&t.includeOverlays&&(y=e.pstyle(`overlay-opacity`).value,y!==0&&(b=e.pstyle(`overlay-padding`).value));var x=0,S=0;r&&t.includeUnderlays&&(x=e.pstyle(`underlay-opacity`).value,x!==0&&(S=e.pstyle(`underlay-padding`).value));var C=Math.max(b,S),w=0,T=0;if(r&&(w=e.pstyle(`width`).pfValue,T=w/2),s&&t.includeNodes){var E=e.position();p=E.x,m=E.y;var D=e.outerWidth()/2,O=e.outerHeight()/2;l=p-D,u=p+D,d=m-O,f=m+O,ll(a,l,d,u,f),r&&ml(a,e),r&&t.includeOutlines&&!i&&ml(a,e),r&&gl(a,e)}else if(c&&t.includeEdges){if(r&&!i){var k=e.pstyle(`curve-style`).strValue;if(l=Math.min(h.srcX,h.midX,h.tgtX),u=Math.max(h.srcX,h.midX,h.tgtX),d=Math.min(h.srcY,h.midY,h.tgtY),f=Math.max(h.srcY,h.midY,h.tgtY),l-=T,u+=T,d-=T,f+=T,ll(a,l,d,u,f),k===`haystack`){var A=h.haystackPts;if(A&&A.length===2){if(l=A[0].x,d=A[0].y,u=A[1].x,f=A[1].y,l>u){var j=l;l=u,u=j}if(d>f){var M=d;d=f,f=M}ll(a,l-T,d-T,u+T,f+T)}}else if(k===`bezier`||k===`unbundled-bezier`||ee(k,`segments`)||ee(k,`taxi`)){var N;switch(k){case`bezier`:case`unbundled-bezier`:N=h.bezierPts;break;case`segments`:case`taxi`:case`round-segments`:case`round-taxi`:N=h.linePts}if(N!=null)for(var P=0;Pu){var R=l;l=u,u=R}if(d>f){var z=d;d=f,f=z}l-=T,u+=T,d-=T,f+=T,ll(a,l,d,u,f)}}if(r&&t.includeEdges&&c&&(fl(a,e,`mid-source`),fl(a,e,`mid-target`),fl(a,e,`source`),fl(a,e,`target`)),r&&e.pstyle(`ghost`).value===`yes`){var B=e.pstyle(`ghost-offset-x`).pfValue,V=e.pstyle(`ghost-offset-y`).pfValue;ll(a,a.x1+B,a.y1+V,a.x2+B,a.y2+V)}var H=o.bodyBounds=o.bodyBounds||{};tr(H,a),er(H,g),$n(H,1),r&&(l=a.x1,u=a.x2,d=a.y1,f=a.y2,ll(a,l-C,d-C,u+C,f+C));var U=o.overlayBounds=o.overlayBounds||{};tr(U,a),er(U,g),$n(U,1);var W=o.labelBounds=o.labelBounds||{};W.all==null?W.all=Jn():Xn(W.all),r&&t.includeLabels&&(t.includeMainLabels&&pl(a,e,null),c&&(t.includeSourceLabels&&pl(a,e,`source`),t.includeTargetLabels&&pl(a,e,`target`)))}return a.x1=cl(a.x1),a.y1=cl(a.y1),a.x2=cl(a.x2),a.y2=cl(a.y2),a.w=cl(a.x2-a.x1),a.h=cl(a.y2-a.y1),a.w>0&&a.h>0&&v&&(er(a,g),$n(a,1)),a},vl=function(e){var t=0,n=function(e){return+!!e<0&&arguments[0]!==void 0?arguments[0]:Hl,t=arguments.length>1?arguments[1]:void 0,n=0;n=0;s--)o(s);return this},Wl.removeAllListeners=function(){return this.removeListener(`*`)},Wl.emit=Wl.trigger=function(e,t,n){var r=this.listeners,i=r.length;return this.emitting++,D(t)||(t=[t]),ql(this,function(e,a){n!=null&&(r=[{event:a.event,type:a.type,namespace:a.namespace,callback:n}],i=r.length);for(var o=function(){var n=r[s];if(n.type===a.type&&(!n.namespace||n.namespace===a.namespace||n.namespace===zl)&&e.eventMatches(e.context,n,a)){var i=[a];t!=null&&Yt(i,t),e.beforeEmit(e.context,n,a),n.conf&&n.conf.one&&(e.listeners=e.listeners.filter(function(e){return e!==n}));var o=e.callbackContext(e.context,n,a),c=n.callback.apply(o,i);e.afterEmit(e.context,n,a),c===!1&&(a.stopPropagation(),a.preventDefault())}},s=0;s1&&!r){var i=this.length-1,a=this[i],o=a._private.data.id;this[i]=void 0,this[e]=a,n.set(o,{ele:a,index:e})}return this.length--,this},unmergeOne:function(e){e=e[0];var t=this._private,n=e._private.data.id,r=t.map.get(n);if(!r)return this;var i=r.index;return this.unmergeAt(i),this},unmerge:function(e){var t=this._private.cy;if(!e)return this;if(e&&T(e)){var n=e;e=t.mutableElements().filter(n)}for(var r=0;r=0;t--){var n=this[t];e(n)&&this.unmergeAt(t)}return this},map:function(e,t){for(var n=[],r=this,i=0;in&&(n=s,r=o)}return{value:n,ele:r}},min:function(e,t){for(var n=1/0,r,i=this,a=0;a=0&&i`u`?`undefined`:g(Symbol))!=e&&g(Symbol.iterator)!=e&&(tu[Symbol.iterator]=function(){var e=this,t={value:void 0,done:!1},n=0,r=this.length;return s({next:function(){return n1&&arguments[1]!==void 0?arguments[1]:!0,n=this[0],r=n.cy();if(r.styleEnabled()&&n)return n._private.styleDirty&&(n._private.styleDirty=!1,r.style().apply(n)),n._private.style[e]??(t?r.style().getDefaultProperty(e):null)},numericStyle:function(e){var t=this[0];if(t.cy().styleEnabled()&&t){var n=t.pstyle(e);return n.pfValue===void 0?n.value:n.pfValue}},numericStyleUnits:function(e){var t=this[0];if(t.cy().styleEnabled()&&t)return t.pstyle(e).units},renderedStyle:function(e){var t=this.cy();if(!t.styleEnabled())return this;var n=this[0];if(n)return t.style().getRenderedStyle(n,e)},style:function(e,t){var n=this.cy();if(!n.styleEnabled())return this;var r=!1,i=n.style();if(O(e)){var a=e;i.applyBypass(this,a,r),this.emitAndNotify(`style`)}else if(T(e)){if(t===void 0){var o=this[0];return o?i.getStylePropertyValue(o,e):void 0}i.applyBypass(this,e,t,r),this.emitAndNotify(`style`)}else if(e===void 0){var s=this[0];return s?i.getRawStyle(s):void 0}return this},removeStyle:function(e){var t=this.cy();if(!t.styleEnabled())return this;var n=!1,r=t.style(),i=this;if(e===void 0)for(var a=0;a0&&t.push(u[0]),t.push(s[0])}return this.spawn(t,!0).filter(e)},`neighborhood`),closedNeighborhood:function(e){return this.neighborhood().add(this).filter(e)},openNeighborhood:function(e){return this.neighborhood(e)}}),mu.neighbourhood=mu.neighborhood,mu.closedNeighbourhood=mu.closedNeighborhood,mu.openNeighbourhood=mu.openNeighborhood,X(mu,{source:Bc(function(e){var t=this[0],n;return t&&(n=t._private.source||t.cy().collection()),n&&e?n.filter(e):n},`source`),target:Bc(function(e){var t=this[0],n;return t&&(n=t._private.target||t.cy().collection()),n&&e?n.filter(e):n},`target`),sources:vu({attr:`source`}),targets:vu({attr:`target`})});function vu(e){return function(t){for(var n=[],r=0;r0);return a},component:function(){var e=this[0];return e.cy().mutableElements().components(e)[0]}}),mu.componentsOf=mu.components;var xu=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0&&arguments[2],r=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(e===void 0){Lt(`A collection must have a reference to the core`);return}var i=new Qt,a=!1;if(!t)t=[];else if(t.length>0&&O(t[0])&&!P(t[0])){a=!0;for(var o=[],s=new tn,c=0,l=t.length;c0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=this,r=n.cy(),i=r._private,a=[],o=[],s,c=0,l=n.length;c0){for(var I=s.length===n.length?n:new xu(r,s),L=0;L0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=this,r=[],i={},a=n._private.cy;function o(e){for(var t=e._private.edges,n=0;n0&&(e?E.emitAndNotify(`remove`):t&&E.emit(`remove`));for(var D=0;D0?i=o:r=o;while(Math.abs(a)>1e-7&&++s<10);return o}function _(t){for(var r=0,o=1,s=i-1;o!==s&&c[o]<=t;++o)r+=a;--o;var l=(t-c[o])/(c[o+1]-c[o]),u=r+l*a,d=p(u,e,n);return d>=.001?m(t,u):d===0?u:g(t,r,r+a)}var v=!1;function y(){v=!0,(e!==t||n!==r)&&h()}var b=function(i){return v||y(),e===t&&n===r?i:i===0?0:i===1?1:f(_(i),t,r)};b.getControlPoints=function(){return[{x:e,y:t},{x:n,y:r}]};var x=`generateBezier(`+[e,t,n,r]+`)`;return b.toString=function(){return x},b}var Tu=function(){function e(e){return-e.tension*e.x-e.friction*e.v}function t(t,n,r){var i={x:t.x+r.dx*n,v:t.v+r.dv*n,tension:t.tension,friction:t.friction};return{dx:i.v,dv:e(i)}}function n(n,r){var i={dx:n.v,dv:e(n)},a=t(n,r*.5,i),o=t(n,r*.5,a),s=t(n,r,o),c=1/6*(i.dx+2*(a.dx+o.dx)+s.dx),l=1/6*(i.dv+2*(a.dv+o.dv)+s.dv);return n.x+=c*r,n.v+=l*r,n}return function e(t,r,i){var a={x:-1,v:0,tension:null,friction:null},o=[0],s=0,c=1/1e4,l=16/1e3,u,d,f;for(t=parseFloat(t)||500,r=parseFloat(r)||20,i||=null,a.tension=t,a.friction=r,u=i!==null,u?(s=e(t,r),d=s/i*l):d=l;f=n(f||a,d),o.push(1+f.x),s+=16,Math.abs(f.x)>c&&Math.abs(f.v)>c;);return u?function(e){return o[e*(o.length-1)|0]}:s}}(),Eu=function(e,t,n,r){var i=wu(e,t,n,r);return function(e,t,n){return e+(t-e)*i(n)}},Du={linear:function(e,t,n){return e+(t-e)*n},ease:Eu(.25,.1,.25,1),"ease-in":Eu(.42,0,1,1),"ease-out":Eu(0,0,.58,1),"ease-in-out":Eu(.42,0,.58,1),"ease-in-sine":Eu(.47,0,.745,.715),"ease-out-sine":Eu(.39,.575,.565,1),"ease-in-out-sine":Eu(.445,.05,.55,.95),"ease-in-quad":Eu(.55,.085,.68,.53),"ease-out-quad":Eu(.25,.46,.45,.94),"ease-in-out-quad":Eu(.455,.03,.515,.955),"ease-in-cubic":Eu(.55,.055,.675,.19),"ease-out-cubic":Eu(.215,.61,.355,1),"ease-in-out-cubic":Eu(.645,.045,.355,1),"ease-in-quart":Eu(.895,.03,.685,.22),"ease-out-quart":Eu(.165,.84,.44,1),"ease-in-out-quart":Eu(.77,0,.175,1),"ease-in-quint":Eu(.755,.05,.855,.06),"ease-out-quint":Eu(.23,1,.32,1),"ease-in-out-quint":Eu(.86,0,.07,1),"ease-in-expo":Eu(.95,.05,.795,.035),"ease-out-expo":Eu(.19,1,.22,1),"ease-in-out-expo":Eu(1,0,0,1),"ease-in-circ":Eu(.6,.04,.98,.335),"ease-out-circ":Eu(.075,.82,.165,1),"ease-in-out-circ":Eu(.785,.135,.15,.86),spring:function(e,t,n){if(n===0)return Du.linear;var r=Tu(e,t,n);return function(e,t,n){return e+(t-e)*r(n)}},"cubic-bezier":Eu};function Ou(e,t,n,r,i){if(r===1||t===n)return n;var a=i(t,n,r);return e==null?a:((e.roundValue||e.color)&&(a=Math.round(a)),e.min!==void 0&&(a=Math.max(a,e.min)),e.max!==void 0&&(a=Math.min(a,e.max)),a)}function ku(e,t){return e.pfValue!=null||e.value!=null?e.pfValue!=null&&(t==null||t.type.units!==`%`)?e.pfValue:e.value:e}function Au(e,t,n,r,i){var a=i==null?null:i.type;n<0?n=0:n>1&&(n=1);var o=ku(e,i),s=ku(t,i);if(A(o)&&A(s))return Ou(a,o,s,n,r);if(D(o)&&D(s)){for(var c=[],l=0;l0?(d===`spring`&&f.push(o.duration),o.easingImpl=Du[d].apply(null,f)):o.easingImpl=Du[d]}}var p=o.easingImpl,m=o.duration===0?1:(n-c)/o.duration;if(o.applying&&(m=o.progress),m<0?m=0:m>1&&(m=1),o.delay==null){var h=o.startPosition,g=o.position;if(g&&i&&!e.locked()){var _={};Mu(h.x,g.x)&&(_.x=Au(h.x,g.x,m,p)),Mu(h.y,g.y)&&(_.y=Au(h.y,g.y,m,p)),e.position(_)}var v=o.startPan,y=o.pan,b=a.pan,x=y!=null&&r;x&&(Mu(v.x,y.x)&&(b.x=Au(v.x,y.x,m,p)),Mu(v.y,y.y)&&(b.y=Au(v.y,y.y,m,p)),e.emit(`pan`));var S=o.startZoom,C=o.zoom,w=C!=null&&r;w&&(Mu(S,C)&&(a.zoom=qn(a.minZoom,Au(S,C,m,p),a.maxZoom)),e.emit(`zoom`)),(x||w)&&e.emit(`viewport`);var E=o.style;if(E&&E.length>0&&i){for(var D=0;D=0;t--){var n=e[t];n()}e.splice(0,e.length)},u=a.length-1;u>=0;u--){var d=a[u],f=d._private;if(f.stopped){a.splice(u,1),f.hooked=!1,f.playing=!1,f.started=!1,l(f.frames);continue}!f.playing&&!f.applying||(f.playing&&f.applying&&(f.applying=!1),f.started||Nu(t,d,e),ju(t,d,e,n),f.applying&&=!1,l(f.frames),f.step!=null&&f.step(e),d.completed()&&(a.splice(u,1),f.hooked=!1,f.playing=!1,f.started=!1,l(f.completes)),s=!0)}return!n&&a.length===0&&o.length===0&&r.push(t),s}for(var a=!1,o=0;o0?t.notify(`draw`,n):t.notify(`draw`)),n.unmerge(r),t.emit(`step`)}var Fu={animate:hc.animate(),animation:hc.animation(),animated:hc.animated(),clearQueue:hc.clearQueue(),delay:hc.delay(),delayAnimation:hc.delayAnimation(),stop:hc.stop(),addToAnimationPool:function(e){var t=this;t.styleEnabled()&&t._private.aniEles.merge(e)},stopAnimationLoop:function(){this._private.animationsRunning=!1},startAnimationLoop:function(){var e=this;if(e._private.animationsRunning=!0,!e.styleEnabled())return;function t(){e._private.animationsRunning&&dt(function(n){Pu(n,e),t()})}var n=e.renderer();n&&n.beforeRender?n.beforeRender(function(t,n){Pu(n,e)},n.beforeRenderPriorities.animations):t()}},Iu={qualifierCompare:function(e,t){return e==null||t==null?e==null&&t==null:e.sameText(t)},eventMatches:function(e,t,n){var r=t.qualifier;return r==null||e!==n.target&&P(n.target)&&r.matches(n.target)},addEventFields:function(e,t){t.cy=e,t.target=e},callbackContext:function(e,t,n){return t.qualifier==null?e:n.target}},Lu=function(e){return T(e)?new Lc(e):e},Ru={createEmitter:function(){var e=this._private;return e.emitter||=new Ul(Iu,this),this},emitter:function(){return this._private.emitter},on:function(e,t,n){return this.emitter().on(e,Lu(t),n),this},removeListener:function(e,t,n){return this.emitter().removeListener(e,Lu(t),n),this},removeAllListeners:function(){return this.emitter().removeAllListeners(),this},one:function(e,t,n){return this.emitter().one(e,Lu(t),n),this},once:function(e,t,n){return this.emitter().one(e,Lu(t),n),this},emit:function(e,t){return this.emitter().emit(e,t),this},emitAndNotify:function(e,t){return this.emit(e),this.notify(e,t),this}};hc.eventAliasesOn(Ru);var zu={png:function(e){var t=this._private.renderer;return e||={},t.png(e)},jpg:function(e){var t=this._private.renderer;return e||={},e.bg=e.bg||`#fff`,t.jpg(e)}};zu.jpeg=zu.jpg;var Bu={layout:function(e){var t=this;if(e==null){Lt(`Layout options must be specified to make a layout`);return}if(e.name==null){Lt("A `name` must be specified to make a layout");return}var n=e.name,r=t.extension(`layout`,n);if(r==null){Lt("No such layout `"+n+"` found. Did you forget to import it and `cytoscape.use()` it?");return}return new r(X({},e,{cy:t,eles:T(e.eles)?t.$(e.eles):e.eles==null?t.$():e.eles}))}};Bu.createLayout=Bu.makeLayout=Bu.layout;var Vu={notify:function(e,t){var n=this._private;if(this.batching()){n.batchNotifications=n.batchNotifications||{};var r=n.batchNotifications[e]=n.batchNotifications[e]||this.collection();t!=null&&r.merge(t);return}if(n.notificationsEnabled){var i=this.renderer();this.destroyed()||!i||i.notify(e,t)}},notifications:function(e){var t=this._private;return e===void 0?t.notificationsEnabled:(t.notificationsEnabled=!!e,this)},noNotifications:function(e){this.notifications(!1),e(),this.notifications(!0)},batching:function(){return this._private.batchCount>0},startBatch:function(){var e=this._private;return e.batchCount??=0,e.batchCount===0&&(e.batchStyleEles=this.collection(),e.batchNotifications={}),e.batchCount++,this},endBatch:function(){var e=this._private;if(e.batchCount===0)return this;if(e.batchCount--,e.batchCount===0){e.batchStyleEles.updateStyle();var t=this.renderer();Object.keys(e.batchNotifications).forEach(function(n){var r=e.batchNotifications[n];r.empty()?t.notify(n):t.notify(n,r)})}return this},batch:function(e){return this.startBatch(),e(),this.endBatch(),this},batchData:function(e){var t=this;return this.batch(function(){for(var n=Object.keys(e),r=0;r0;)t.removeChild(t.childNodes[0]);e._private.renderer=null,e.mutableElements().forEach(function(e){var t=e._private;t.rscratch={},t.rstyle={},t.animation.current=[],t.animation.queue=[]})},onRender:function(e){return this.on(`render`,e)},offRender:function(e){return this.off(`render`,e)}};Uu.invalidateDimensions=Uu.resize;var Wu={collection:function(e,t){return T(e)?this.$(e):N(e)?e.collection():D(e)?(t||={},new xu(this,e,t.unique,t.removed)):new xu(this)},nodes:function(e){var t=this.$(function(e){return e.isNode()});return e?t.filter(e):t},edges:function(e){var t=this.$(function(e){return e.isEdge()});return e?t.filter(e):t},$:function(e){var t=this._private.elements;return e?t.filter(e):t.spawnSelf()},mutableElements:function(){return this._private.elements}};Wu.elements=Wu.filter=Wu.$;var Gu={},Ku=`t`,qu=`f`;Gu.apply=function(e){for(var t=this,n=t._private.cy.collection(),r=0;r0;if(f||d&&p){var m=void 0;f&&p||f?m=l.properties:p&&(m=l.mappedProperties);for(var h=0;h1&&(b=1),s.color){var S=r.valueMin[0],C=r.valueMax[0],w=r.valueMin[1],T=r.valueMax[1],E=r.valueMin[2],D=r.valueMax[2],O=r.valueMin[3]==null?1:r.valueMin[3],k=r.valueMax[3]==null?1:r.valueMax[3],j=[Math.round(S+(C-S)*b),Math.round(w+(T-w)*b),Math.round(E+(D-E)*b),Math.round(O+(k-O)*b)];a={bypass:r.bypass,name:r.name,value:j,strValue:`rgb(`+j[0]+`, `+j[1]+`, `+j[2]+`)`}}else if(s.number){var M=r.valueMin+(r.valueMax-r.valueMin)*b;a=this.parse(r.name,M,r.bypass,f)}else return!1;if(!a)return h(),!1;a.mapping=r,r=a;break;case o.data:for(var N=r.field.split(`.`),P=d.data,F=0;F0&&a>0){for(var s={},c=!1,l=0;l0?e.delayAnimation(o).play().promise().then(t):t()}).then(function(){return e.animation({style:s,duration:a,easing:e.pstyle(`transition-timing-function`).value,queue:!1}).play().promise()}).then(function(){n.removeBypasses(e,i),e.emitAndNotify(`style`),r.transitioning=!1})}else r.transitioning&&=(this.removeBypasses(e,i),e.emitAndNotify(`style`),!1)},Gu.checkTrigger=function(e,t,n,r,i,a){var o=this.properties[t],s=i(o);e.removed()||s!=null&&s(n,r,e)&&a(o)},Gu.checkZOrderTrigger=function(e,t,n,r){var i=this;this.checkTrigger(e,t,n,r,function(e){return e.triggersZOrder},function(){i._private.cy.notify(`zorder`,e)})},Gu.checkBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBounds},function(t){e.dirtyCompoundBoundsCache(),e.dirtyBoundingBoxCache()})},Gu.checkConnectedEdgesBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBoundsOfConnectedEdges},function(t){e.connectedEdges().forEach(function(e){e.dirtyBoundingBoxCache()})})},Gu.checkParallelEdgesBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBoundsOfParallelEdges},function(t){e.parallelEdges().forEach(function(e){e.dirtyBoundingBoxCache()})})},Gu.checkTriggers=function(e,t,n,r){e.dirtyStyleCache(),this.checkZOrderTrigger(e,t,n,r),this.checkBoundsTrigger(e,t,n,r),this.checkConnectedEdgesBoundsTrigger(e,t,n,r),this.checkParallelEdgesBoundsTrigger(e,t,n,r)};var Ju={};Ju.applyBypass=function(e,t,n,r){var i=this,a=[],o=!0;if(t===`*`||t===`**`){if(n!==void 0)for(var s=0;si.length?r.substr(i.length):``}function c(){a=a.length>o.length?a.substr(o.length):``}for(;!r.match(/^\s*$/);){var l=r.match(/^\s*((?:.|\s)+?)\s*\{((?:.|\s)+?)\}/);if(!l){zt(`Halting stylesheet parsing: String stylesheet contains more to parse but no selector and block found in: `+r);break}i=l[0];var u=l[1];if(u!==`core`&&new Lc(u).invalid){zt(`Skipping parsing of block: Invalid selector found in string stylesheet: `+u),s();continue}var d=l[2],f=!1;a=d;for(var p=[];!a.match(/^\s*$/);){var m=a.match(/^\s*(.+?)\s*:\s*(.+?)(?:\s*;|\s*$)/);if(!m){zt(`Skipping parsing of block: Invalid formatting of style property and value definitions found in:`+d),f=!0;break}o=m[0];var h=m[1],g=m[2];if(!t.properties[h]){zt(`Skipping property: Invalid property name in: `+o),c();continue}if(!n.parse(h,g)){zt(`Skipping property: Invalid property definition in: `+o),c();continue}p.push({name:h,val:g}),c()}if(f){s();break}n.selector(u);for(var _=0;_=7&&t[0]===`d`&&(u=new RegExp(s.data.regex).exec(t))){if(n)return!1;var f=s.data;return{name:e,value:u,strValue:``+t,mapped:f,field:u[1],bypass:n}}if(t.length>=10&&t[0]===`m`&&(d=new RegExp(s.mapData.regex).exec(t))){if(n||l.multiple)return!1;var p=s.mapData;if(!(l.color||l.number))return!1;var m=this.parse(e,d[4]);if(!m||m.mapped)return!1;var h=this.parse(e,d[5]);if(!h||h.mapped)return!1;if(m.pfValue===h.pfValue||m.strValue===h.strValue)return zt("`"+e+`: `+t+"` is not a valid mapper because the output range is zero; converting to `"+e+`: `+m.strValue+"`"),this.parse(e,m.strValue);if(l.color){var g=m.value,_=h.value;if(g[0]===_[0]&&g[1]===_[1]&&g[2]===_[2]&&(g[3]===_[3]||(g[3]==null||g[3]===1)&&(_[3]==null||_[3]===1)))return!1}return{name:e,value:d,strValue:``+t,mapped:p,field:d[1],fieldMin:parseFloat(d[2]),fieldMax:parseFloat(d[3]),valueMin:m.value,valueMax:h.value,bypass:n}}}if(l.multiple&&r!==`multiple`){var v=c?t.split(/\s+/):D(t)?t:[t];if(l.evenMultiple&&v.length%2!=0)return null;for(var y=[],b=[],x=[],S=``,C=!1,w=0;w0?` `:``)+O.strValue}return l.validate&&!l.validate(y,b)?null:l.singleEnum&&C?y.length===1&&T(y[0])?{name:e,value:y[0],strValue:y[0],bypass:n}:null:{name:e,value:y,pfValue:x,strValue:S,bypass:n,units:b}}var k=function(){for(var r=0;rl.max||l.strictMax&&t===l.max))return null;var F={name:e,value:t,strValue:``+t+(A||``),units:A,bypass:n};return F.pfValue=l.unitless||A!==`px`&&A!==`em`||A===`px`||!A?t:this.getEmSizeInPixels()*t,(A===`ms`||A===`s`)&&(F.pfValue=A===`ms`?t:1e3*t),(A===`deg`||A===`rad`)&&(F.pfValue=A===`rad`?t:Ln(t)),A===`%`&&(F.pfValue=t/100),F}if(l.propList){var I=[],L=``+t;if(L!==`none`){for(var R=L.split(/\s*,\s*|\s+/),z=0;z0&&o>0&&!isNaN(n.w)&&!isNaN(n.h)&&n.w>0&&n.h>0){s=Math.min((a-2*t)/n.w,(o-2*t)/n.h),s=s>this._private.maxZoom?this._private.maxZoom:s,s=s=n.minZoom&&(n.maxZoom=t),this},minZoom:function(e){return e===void 0?this._private.minZoom:this.zoomRange({min:e})},maxZoom:function(e){return e===void 0?this._private.maxZoom:this.zoomRange({max:e})},getZoomedViewport:function(e){var t=this._private,n=t.pan,r=t.zoom,i,a,o=!1;if(t.zoomingEnabled||(o=!0),A(e)?a=e:O(e)&&(a=e.level,e.position==null?e.renderedPosition!=null&&(i=e.renderedPosition):i=On(e.position,r,n),i!=null&&!t.panningEnabled&&(o=!0)),a=a>t.maxZoom?t.maxZoom:a,a=at.maxZoom||!t.zoomingEnabled?a=!0:(t.zoom=s,i.push(`zoom`))}if(r&&(!a||!e.cancelOnFailedZoom)&&t.panningEnabled){var c=e.pan;A(c.x)&&(t.pan.x=c.x,o=!1),A(c.y)&&(t.pan.y=c.y,o=!1),o||i.push(`pan`)}return i.length>0&&(i.push(`viewport`),this.emit(i.join(` `)),this.notify(`viewport`)),this},center:function(e){var t=this.getCenterPan(e);return t&&(this._private.pan=t,this.emit(`pan viewport`),this.notify(`viewport`)),this},getCenterPan:function(e,t){if(this._private.panningEnabled){if(T(e)){var n=e;e=this.mutableElements().filter(n)}else N(e)||(e=this.mutableElements());if(e.length!==0){var r=e.boundingBox(),i=this.width(),a=this.height();return t=t===void 0?this._private.zoom:t,{x:(i-t*(r.x1+r.x2))/2,y:(a-t*(r.y1+r.y2))/2}}}},reset:function(){return!this._private.panningEnabled||!this._private.zoomingEnabled||this.viewport({pan:{x:0,y:0},zoom:1}),this},invalidateSize:function(){this._private.sizeCache=null},size:function(){var e=this._private,t=e.container,n=this;return e.sizeCache=e.sizeCache||(t?function(){var e=n.window().getComputedStyle(t),r=function(t){return parseFloat(e.getPropertyValue(t))};return{width:t.clientWidth-r(`padding-left`)-r(`padding-right`),height:t.clientHeight-r(`padding-top`)-r(`padding-bottom`)}}():{width:1,height:1})},width:function(){return this.size().width},height:function(){return this.size().height},extent:function(){var e=this._private.pan,t=this._private.zoom,n=this.renderedExtent(),r={x1:(n.x1-e.x)/t,x2:(n.x2-e.x)/t,y1:(n.y1-e.y)/t,y2:(n.y2-e.y)/t};return r.w=r.x2-r.x1,r.h=r.y2-r.y1,r},renderedExtent:function(){var e=this.width(),t=this.height();return{x1:0,y1:0,x2:e,y2:t,w:e,h:t}},multiClickDebounceTime:function(e){if(e)this._private.multiClickDebounceTime=e;else return this._private.multiClickDebounceTime;return this}};ad.centre=ad.center,ad.autolockNodes=ad.autolock,ad.autoungrabifyNodes=ad.autoungrabify;var od={data:hc.data({field:`data`,bindingEvent:`data`,allowBinding:!0,allowSetting:!0,settingEvent:`data`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeData:hc.removeData({field:`data`,event:`data`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0}),scratch:hc.data({field:`scratch`,bindingEvent:`scratch`,allowBinding:!0,allowSetting:!0,settingEvent:`scratch`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeScratch:hc.removeData({field:`scratch`,event:`scratch`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0})};od.attr=od.data,od.removeAttr=od.removeData;var sd=function(e){var t=this;e=X({},e);var n=e.container;n&&!M(n)&&M(n[0])&&(n=n[0]);var r=n?n._cyreg:null;r||={},r&&r.cy&&(r.cy.destroy(),r={});var i=r.readies=r.readies||[];n&&(n._cyreg=r),r.cy=t;var a=v!==void 0&&n!==void 0&&!e.headless,o=e;o.layout=X({name:a?`grid`:`null`},o.layout),o.renderer=X({name:a?`canvas`:`null`},o.renderer);var s=function(e,t,n){return t===void 0?n===void 0?e:n:t},c=this._private={container:n,ready:!1,options:o,elements:new xu(this),listeners:[],aniEles:new xu(this),data:o.data||{},scratch:{},layout:null,renderer:null,destroyed:!1,notificationsEnabled:!0,minZoom:1e-50,maxZoom:1e50,zoomingEnabled:s(!0,o.zoomingEnabled),userZoomingEnabled:s(!0,o.userZoomingEnabled),panningEnabled:s(!0,o.panningEnabled),userPanningEnabled:s(!0,o.userPanningEnabled),boxSelectionEnabled:s(!0,o.boxSelectionEnabled),autolock:s(!1,o.autolock,o.autolockNodes),autoungrabify:s(!1,o.autoungrabify,o.autoungrabifyNodes),autounselectify:s(!1,o.autounselectify),styleEnabled:o.styleEnabled===void 0?a:o.styleEnabled,zoom:A(o.zoom)?o.zoom:1,pan:{x:O(o.pan)&&A(o.pan.x)?o.pan.x:0,y:O(o.pan)&&A(o.pan.y)?o.pan.y:0},animation:{current:[],queue:[]},hasCompoundNodes:!1,multiClickDebounceTime:s(250,o.multiClickDebounceTime)};this.createEmitter(),this.selectionType(o.selectionType),this.zoomRange({min:o.minZoom,max:o.maxZoom});var l=function(e,t){if(e.some(H))return ma.all(e).then(t);t(e)};c.styleEnabled&&t.setStyle([]);var u=X({},o,o.renderer);t.initRenderer(u);var d=function(e,n,r){t.notifications(!1);var i=t.mutableElements();i.length>0&&i.remove(),e!=null&&(O(e)||D(e))&&t.add(e),t.one(`layoutready`,function(e){t.notifications(!0),t.emit(e),t.one(`load`,n),t.emitAndNotify(`load`)}).one(`layoutstop`,function(){t.one(`done`,r),t.emit(`done`)});var a=X({},t._private.options.layout);a.eles=t.elements(),t.layout(a).run()};l([o.style,o.elements],function(e){var n=e[0],a=e[1];c.styleEnabled&&t.style().append(n),d(a,function(){t.startAnimationLoop(),c.ready=!0,E(o.ready)&&t.on(`ready`,o.ready);for(var e=0;e0,s=!!e.boundingBox,c=Jn(s?e.boundingBox:structuredClone(t.extent())),l;if(N(e.roots))l=e.roots;else if(D(e.roots)){for(var u=[],d=0;d0;){var M=j(),P=E(M,k);if(P)M.outgoers().filter(function(e){return e.isNode()&&n.has(e)}).forEach(A);else if(P===null){zt("Detected double maximal shift for node `"+M.id()+"`. Bailing maximal adjustment due to cycle. Use `options.maximal: true` only on DAGs.");break}}}var F=0;if(e.avoidOverlap)for(var I=0;I0&&_[0].length<=3?a/2:0),l=2*Math.PI/_[r].length*i;return r===0&&_[0].length===1&&(o=1),{x:ee.x+o*Math.cos(l),y:ee.y+o*Math.sin(l)}}var u=_[r].length,d=Math.max(u===1?0:s?(c.w-e.padding*2-Y.w)/((e.grid?ne:u)-1):(c.w-e.padding*2-Y.w)/((e.grid?ne:u)+1),F);return{x:ee.x+(i+1-(u+1)/2)*d,y:ee.y+(r+1-(U+1)/2)*te}},ie={downward:0,leftward:90,upward:180,rightward:-90};return Object.keys(ie).indexOf(e.direction)===-1&&Lt(`Invalid direction '${e.direction}' specified for breadthfirst layout. Valid values are: ${Object.keys(ie).join(`, `)}`),n.nodes().layoutPositions(this,e,function(t){return Ot(re(t),c,ie[e.direction])}),this};var md={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,radius:void 0,startAngle:3/2*Math.PI,sweep:void 0,clockwise:!0,sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function hd(e){this.options=X({},md,e)}hd.prototype.run=function(){var e=this.options,t=e,n=e.cy,r=t.eles,i=t.counterclockwise===void 0?t.clockwise:!t.counterclockwise,a=r.nodes().not(`:parent`);t.sort&&(a=a.sort(t.sort));for(var o=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()}),s={x:o.x1+o.w/2,y:o.y1+o.h/2},c=(t.sweep===void 0?2*Math.PI-2*Math.PI/a.length:t.sweep)/Math.max(1,a.length-1),l,u=0,d=0;d1&&t.avoidOverlap){u*=1.75;var h=Math.cos(c)-Math.cos(0),g=Math.sin(c)-Math.sin(0),_=Math.sqrt(u*u/(h*h+g*g));l=Math.max(_,l)}return r.nodes().layoutPositions(this,t,function(e,n){var r=t.startAngle+n*c*(i?1:-1),a=l*Math.cos(r),o=l*Math.sin(r);return{x:s.x+a,y:s.y+o}}),this};var gd={fit:!0,padding:30,startAngle:3/2*Math.PI,sweep:void 0,clockwise:!0,equidistant:!1,minNodeSpacing:10,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,height:void 0,width:void 0,spacingFactor:void 0,concentric:function(e){return e.degree()},levelWidth:function(e){return e.maxDegree()/4},animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function _d(e){this.options=X({},gd,e)}_d.prototype.run=function(){for(var e=this.options,t=e,n=t.counterclockwise===void 0?t.clockwise:!t.counterclockwise,r=e.cy,i=t.eles,a=i.nodes().not(`:parent`),o=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:r.width(),h:r.height()}),s={x:o.x1+o.w/2,y:o.y1+o.h/2},c=[],l=0,u=0;u0&&Math.abs(_[0].value-y.value)>=h&&(_=[],g.push(_)),_.push(y)}var b=l+t.minNodeSpacing;if(!t.avoidOverlap){var x=g.length>0&&g[0].length>1,S=(Math.min(o.w,o.h)/2-b)/(g.length+x?1:0);b=Math.min(b,S)}for(var C=0,w=0;w1&&t.avoidOverlap){var D=Math.cos(E)-Math.cos(0),O=Math.sin(E)-Math.sin(0),k=Math.sqrt(b*b/(D*D+O*O));C=Math.max(k,C)}T.r=C,C+=b}if(t.equidistant){for(var A=0,j=0,M=0;M=e.numIter||(Od(r,e),r.temperature*=e.coolingFactor,r.temperature=e.animationThreshold&&a(),dt(u)):(Bd(r,e),s())};u()}else{for(;l;)l=o(c),c++;Bd(r,e),s()}return this},bd.prototype.stop=function(){return this.stopped=!0,this.thread&&this.thread.stop(),this.emit(`layoutstop`),this},bd.prototype.destroy=function(){return this.thread&&this.thread.stop(),this};var xd=function(e,t,n){for(var r=n.eles.edges(),i=n.eles.nodes(),a=Jn(n.boundingBox?n.boundingBox:{x1:0,y1:0,w:e.width(),h:e.height()}),o={isCompound:e.hasCompoundNodes(),layoutNodes:[],idToIndex:{},nodeSize:i.size(),graphSet:[],indexToGraph:[],layoutEdges:[],edgeSize:r.size(),temperature:n.initialTemp,clientWidth:a.w,clientHeight:a.h,boundingBox:a},s=n.eles.components(),c={},l=0;l0){o.graphSet.push(C);for(var l=0;lr.count?0:r.graph},Cd=function(e,t,n,r){var i=r.graphSet[n];if(-10)var c=r.nodeOverlap*s,l=Math.sqrt(i*i+a*a),u=c*i/l,d=c*a/l;else var f=Nd(e,i,a),p=Nd(t,-1*i,-1*a),m=p.x-f.x,h=p.y-f.y,g=m*m+h*h,l=Math.sqrt(g),c=(e.nodeRepulsion+t.nodeRepulsion)/g,u=c*m/l,d=c*h/l;e.isLocked||(e.offsetX-=u,e.offsetY-=d),t.isLocked||(t.offsetX+=u,t.offsetY+=d)}},Md=function(e,t,n,r){if(n>0)var i=e.maxX-t.minX;else var i=t.maxX-e.minX;if(r>0)var a=e.maxY-t.minY;else var a=t.maxY-e.minY;return i>=0&&a>=0?Math.sqrt(i*i+a*a):0},Nd=function(e,t,n){var r=e.positionX,i=e.positionY,a=e.height||1,o=e.width||1,s=n/t,c=a/o,l={};return t===0&&0n?(l.x=r,l.y=i+a/2,l):0t&&-1*c<=s&&s<=c?(l.x=r-o/2,l.y=i-o*n/2/t,l):0=c)?(l.x=r+a*t/2/n,l.y=i+a/2,l):0>n&&(s<=-1*c||s>=c)?(l.x=r-a*t/2/n,l.y=i-a/2,l):l},Pd=function(e,t){for(var n=0;nn){var h=t.gravity*f/m,g=t.gravity*p/m;d.offsetX+=h,d.offsetY+=g}}}}},Id=function(e,t){var n=[],r=0,i=-1;for(n.push.apply(n,e.graphSet[0]),i+=e.graphSet[0].length;r<=i;){var a=n[r++],o=e.idToIndex[a],s=e.layoutNodes[o],c=s.children;if(0n)var i={x:n*e/r,y:n*t/r};else var i={x:e,y:t};return i},zd=function(e,t){var n=e.parentId;if(n!=null){var r=t.layoutNodes[t.idToIndex[n]],i=!1;if((r.maxX==null||e.maxX+r.padRight>r.maxX)&&(r.maxX=e.maxX+r.padRight,i=!0),(r.minX==null||e.minX-r.padLeftr.maxY)&&(r.maxY=e.maxY+r.padBottom,i=!0),(r.minY==null||e.minY-r.padToph&&(f+=m+t.componentSpacing,d=0,p=0,m=0)}}},Vd={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,avoidOverlapPadding:10,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,condense:!1,rows:void 0,cols:void 0,position:function(e){},sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function Hd(e){this.options=X({},Vd,e)}Hd.prototype.run=function(){var e=this.options,t=e,n=e.cy,r=t.eles,i=r.nodes().not(`:parent`);t.sort&&(i=i.sort(t.sort));var a=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()});if(a.h===0||a.w===0)r.nodes().layoutPositions(this,t,function(e){return{x:a.x1,y:a.y1}});else{var o=i.size(),s=Math.sqrt(o*a.h/a.w),c=Math.round(s),l=Math.round(a.w/a.h*s),u=function(e){if(e==null)return Math.min(c,l);Math.min(c,l)==c?c=e:l=e},d=function(e){if(e==null)return Math.max(c,l);Math.max(c,l)==c?c=e:l=e},f=t.rows,p=t.cols==null?t.columns:t.cols;if(f!=null&&p!=null)c=f,l=p;else if(f!=null&&p==null)c=f,l=Math.ceil(o/c);else if(f==null&&p!=null)l=p,c=Math.ceil(o/l);else if(l*c>o){var m=u(),h=d();(m-1)*h>=o?u(m-1):(h-1)*m>=o&&d(h-1)}else for(;l*c=o?d(_+1):u(g+1)}var v=a.w/l,y=a.h/c;if(t.condense&&(v=0,y=0),t.avoidOverlap)for(var b=0;b=l&&(j=0,A++)},N={},P=0;P(y=hr(e,t,b[x],b[x+1],b[x+2],b[x+3])))return g(n,y),!0}else if(o.edgeType===`bezier`||o.edgeType===`multibezier`||o.edgeType===`self`||o.edgeType===`compound`){for(var b=o.allpts,x=0;x+5(y=mr(e,t,b[x],b[x+1],b[x+2],b[x+3],b[x+4],b[x+5])))return g(n,y),!0}for(var h=h||r.source,v=v||r.target,S=i.getArrowWidth(c,d),C=[{name:`source`,x:o.arrowStartX,y:o.arrowStartY,angle:o.srcArrowAngle},{name:`target`,x:o.arrowEndX,y:o.arrowEndY,angle:o.tgtArrowAngle},{name:`mid-source`,x:o.midX,y:o.midY,angle:o.midsrcArrowAngle},{name:`mid-target`,x:o.midX,y:o.midY,angle:o.midtgtArrowAngle}],x=0;x0&&(_(h),_(v))}function y(e,t,n){return Xt(e,t,n)}function b(n,r){var i=n._private,a=f,o=r?r+`-`:``;n.boundingBox();var s=i.labelBounds[r||`main`],c=n.pstyle(o+`label`).value;if(!(n.pstyle(`text-events`).strValue!==`yes`||!c)){var l=y(i.rscratch,`labelX`,r),u=y(i.rscratch,`labelY`,r),d=y(i.rscratch,`labelAngle`,r),p=n.pstyle(o+`text-margin-x`).pfValue,m=n.pstyle(o+`text-margin-y`).pfValue,h=s.x1-a-p,_=s.x2+a-p,v=s.y1-a-m,b=s.y2+a-m;if(d){var x=Math.cos(d),S=Math.sin(d),C=function(e,t){return e-=l,t-=u,{x:e*x-t*S+l,y:e*S+t*x+u}},w=C(h,v),T=C(h,b),E=C(_,v),D=C(_,b);if(gr(e,t,[w.x+p,w.y+m,E.x+p,E.y+m,D.x+p,D.y+m,T.x+p,T.y+m]))return g(n),!0}else if(rr(s,e,t))return g(n),!0}}for(var x=o.length-1;x>=0;x--){var S=o[x];S.isNode()?_(S)||b(S):v(S)||b(S)||b(S,`source`)||b(S,`target`)}return s},ef.getAllInBox=function(e,t,n,r){var i=this.getCachedZSortedEles().interactive,a=2/this.cy.zoom(),o=[],s=Math.min(e,n),c=Math.max(e,n),l=Math.min(t,r),u=Math.max(t,r);e=s,n=c,t=l,r=u;var d=Jn({x1:e,y1:t,x2:n,y2:r}),p=[{x:d.x1,y:d.y1},{x:d.x2,y:d.y1},{x:d.x2,y:d.y2},{x:d.x1,y:d.y2}],m=[[p[0],p[1]],[p[1],p[2]],[p[2],p[3]],[p[3],p[0]]];function h(e,t,n){return Xt(e,t,n)}function g(e,t){var n=e._private,r=a,i=``;e.boundingBox();var o=n.labelBounds.main;if(!o)return null;var s=h(n.rscratch,`labelX`,t),c=h(n.rscratch,`labelY`,t),l=h(n.rscratch,`labelAngle`,t),u=e.pstyle(i+`text-margin-x`).pfValue,d=e.pstyle(i+`text-margin-y`).pfValue,f=o.x1-r-u,p=o.x2+r-u,m=o.y1-r-d,g=o.y2+r-d;if(l){var _=Math.cos(l),v=Math.sin(l),y=function(e,t){return e-=s,t-=c,{x:e*_-t*v+s,y:e*v+t*_+c}};return[y(f,m),y(p,m),y(p,g),y(f,g)]}return[{x:f,y:m},{x:p,y:m},{x:p,y:g},{x:f,y:g}]}function _(e,t,n,r){function i(e,t,n){return(n.y-e.y)*(t.x-e.x)>(t.y-e.y)*(n.x-e.x)}return i(e,n,r)!==i(t,n,r)&&i(e,t,n)!==i(e,t,r)}for(var v=0;v0?-(Math.PI-e.ang):Math.PI+e.ang},wf=function(e,t,n,r,i){if(e===xf?Cf(of,af):Sf(t,e,af),Sf(t,n,of),sf=af.nx*of.ny-af.ny*of.nx,cf=af.nx*of.nx-af.ny*-of.ny,df=Math.asin(Math.max(-1,Math.min(1,sf))),Math.abs(df)<1e-6){nf=t.x,rf=t.y,pf=hf=0;return}lf=1,uf=!1,cf<0?df<0?df=Math.PI+df:(df=Math.PI-df,lf=-1,uf=!0):df>0&&(lf=-1,uf=!0),hf=t.radius===void 0?r:t.radius,ff=df/2,gf=Math.min(af.len/2,of.len/2),i?(mf=Math.abs(Math.cos(ff)*hf/Math.sin(ff)),mf>gf?(mf=gf,pf=Math.abs(mf*Math.sin(ff)/Math.cos(ff))):pf=hf):(mf=Math.min(gf,hf),pf=Math.abs(mf*Math.sin(ff)/Math.cos(ff))),yf=t.x+of.nx*mf,bf=t.y+of.ny*mf,nf=yf-of.ny*pf*lf,rf=bf+of.nx*pf*lf,_f=t.x+af.nx*mf,vf=t.y+af.ny*mf,xf=t};function Tf(e,t){t.radius===0?e.lineTo(t.cx,t.cy):e.arc(t.cx,t.cy,t.radius,t.startAngle,t.endAngle,t.counterClockwise)}function Ef(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0;return r===0||t.radius===0?{cx:t.x,cy:t.y,radius:0,startX:t.x,startY:t.y,stopX:t.x,stopY:t.y,startAngle:void 0,endAngle:void 0,counterClockwise:void 0}:(wf(e,t,n,r,i),{cx:nf,cy:rf,radius:pf,startX:_f,startY:vf,stopX:yf,stopY:bf,startAngle:af.ang+Math.PI/2*lf,endAngle:of.ang-Math.PI/2*lf,counterClockwise:uf})}var Df=.01,Of=Math.sqrt(2*Df),kf={};kf.findMidptPtsEtc=function(e,t){var n=t.posPts,r=t.intersectionPts,i=t.vectorNormInverse,a,o=e.pstyle(`source-endpoint`),s=e.pstyle(`target-endpoint`),c=o.units!=null&&s.units!=null,l=function(e,t,n,r){var i=r-t,a=n-e,o=Math.sqrt(a*a+i*i);return{x:-i/o,y:a/o}};switch(e.pstyle(`edge-distances`).value){case`node-position`:a=n;break;case`intersection`:a=r;break;case`endpoints`:if(c){var u=f(this.manualEndptToPx(e.source()[0],o),2),d=u[0],p=u[1],m=f(this.manualEndptToPx(e.target()[0],s),2),h=m[0],g=m[1],_={x1:d,y1:p,x2:h,y2:g};i=l(d,p,h,g),a=_}else zt(`Edge ${e.id()} has edge-distances:endpoints specified without manual endpoints specified via source-endpoint and target-endpoint. Falling back on edge-distances:intersection (default).`),a=r}return{midptPts:a,vectorNormInverse:i}},kf.findHaystackPoints=function(e){for(var t=0;t0?Math.max(e-t,0):Math.min(e+t,0)},O=D(T,C),k=D(E,w),A=!1;_===l?g=Math.abs(O)>Math.abs(k)?i:r:_===c||_===s?(g=r,A=!0):(_===a||_===o)&&(g=i,A=!0);var j=g===r,M=j?k:O,N=j?E:T,P=Bn(N),F=!1;!(A&&(y||x))&&(_===s&&N<0||_===c&&N>0||_===a&&N>0||_===o&&N<0)&&(P*=-1,M=P*Math.abs(M),F=!0);var I=y?(b<0?1+b:b)*M:(b<0?M:0)+b*P,L=function(e){return Math.abs(e)=Math.abs(M)},R=L(I),z=L(Math.abs(M)-Math.abs(I));if((R||z)&&!F){if(j){var B=Math.abs(N)<=f/2,V=Math.abs(T)<=p/2;if(B){var H=(u.x1+u.x2)/2;n.segpts=[H,u.y1,H,u.y2]}else if(V){var U=(u.y1+u.y2)/2;n.segpts=[u.x1,U,u.x2,U]}else n.segpts=[u.x1,u.y2]}else{var W=Math.abs(N)<=d/2,G=Math.abs(E)<=m/2;if(W){var K=(u.y1+u.y2)/2;n.segpts=[u.x1,K,u.x2,K]}else if(G){var q=(u.x1+u.x2)/2;n.segpts=[q,u.y1,q,u.y2]}else n.segpts=[u.x2,u.y1]}}else if(j){var J=u.y1+I+(h?f/2*P:0);n.segpts=[u.x1,J,u.x2,J]}else{var ee=u.x1+I+(h?d/2*P:0);n.segpts=[ee,u.y1,ee,u.y2]}if(n.isRound){var Y=e.pstyle(`taxi-radius`).value,te=e.pstyle(`radius-type`).value[0]===`arc-radius`;n.radii=Array(n.segpts.length/2).fill(Y),n.isArcRadius=Array(n.segpts.length/2).fill(te)}},kf.tryToCorrectInvalidPoints=function(e,t){var n=e._private.rscratch;if(n.edgeType===`bezier`){var r=t.srcPos,i=t.tgtPos,a=t.srcW,o=t.srcH,s=t.tgtW,c=t.tgtH,l=t.srcShape,u=t.tgtShape,d=t.srcCornerRadius,f=t.tgtCornerRadius,p=t.srcRs,m=t.tgtRs,h=!A(n.startX)||!A(n.startY),g=!A(n.arrowStartX)||!A(n.arrowStartY),_=!A(n.endX)||!A(n.endY),v=!A(n.arrowEndX)||!A(n.arrowEndY),y=3*(this.getArrowWidth(e.pstyle(`width`).pfValue,e.pstyle(`arrow-scale`).value)*this.arrowShapeWidth),b=Vn({x:n.ctrlpts[0],y:n.ctrlpts[1]},{x:n.startX,y:n.startY}),x=bh.poolIndex()){var g=m;m=h,h=g}var _=u.srcPos=m.position(),v=u.tgtPos=h.position(),y=u.srcW=m.outerWidth(),b=u.srcH=m.outerHeight(),S=u.tgtW=h.outerWidth(),C=u.tgtH=h.outerHeight(),w=u.srcShape=n.nodeShapes[t.getNodeShape(m)],T=u.tgtShape=n.nodeShapes[t.getNodeShape(h)],E=u.srcCornerRadius=m.pstyle(`corner-radius`).value===`auto`?`auto`:m.pstyle(`corner-radius`).pfValue,D=u.tgtCornerRadius=h.pstyle(`corner-radius`).value===`auto`?`auto`:h.pstyle(`corner-radius`).pfValue,O=u.tgtRs=h._private.rscratch,k=u.srcRs=m._private.rscratch;u.dirCounts={north:0,west:0,south:0,east:0,northwest:0,southwest:0,northeast:0,southeast:0};for(var j=0;j=Of||(G=Math.sqrt(Math.max(W*W,Df)+Math.max(U*U,Df)));var K=u.vector={x:W,y:U},q=u.vectorNorm={x:K.x/G,y:K.y/G},J={x:-q.y,y:q.x};u.nodesOverlap=!A(G)||T.checkPoint(L[0],L[1],0,S,C,v.x,v.y,D,O)||w.checkPoint(z[0],z[1],0,y,b,_.x,_.y,E,k),u.vectorNormInverse=J,d={nodesOverlap:u.nodesOverlap,dirCounts:u.dirCounts,calculatedIntersection:!0,hasBezier:u.hasBezier,hasUnbundled:u.hasUnbundled,eles:u.eles,srcPos:v,srcRs:O,tgtPos:_,tgtRs:k,srcW:S,srcH:C,tgtW:y,tgtH:b,srcIntn:B,tgtIntn:R,srcShape:T,tgtShape:w,posPts:{x1:H.x2,y1:H.y2,x2:H.x1,y2:H.y1},intersectionPts:{x1:V.x2,y1:V.y2,x2:V.x1,y2:V.y1},vector:{x:-K.x,y:-K.y},vectorNorm:{x:-q.x,y:-q.y},vectorNormInverse:{x:-J.x,y:-J.y}}}var Y=I?d:u;N.nodesOverlap=Y.nodesOverlap,N.srcIntn=Y.srcIntn,N.tgtIntn=Y.tgtIntn,N.isRound=P.startsWith(`round`),r&&(m.isParent()||m.isChild()||h.isParent()||h.isChild())&&(m.parents().anySame(h)||h.parents().anySame(m)||m.same(h)&&m.isParent())?t.findCompoundLoopPoints(M,Y,j,F):m===h?t.findLoopPoints(M,Y,j,F):P.endsWith(`segments`)?t.findSegmentsPoints(M,Y):P.endsWith(`taxi`)?t.findTaxiPoints(M,Y):P===`straight`||!F&&u.eles.length%2==1&&j===Math.floor(u.eles.length/2)?t.findStraightEdgePoints(M):t.findBezierPoints(M,Y,j,F,I),t.findEndpoints(M),t.tryToCorrectInvalidPoints(M,Y),t.checkForInvalidEdgeWarning(M),t.storeAllpts(M),t.storeEdgeProjections(M),t.calculateArrowAngles(M),t.recalculateEdgeLabelProjections(M),t.calculateLabelAngles(M)}},x=0;x0){var ne=s,re=Hn(ne,An(i)),ie=Hn(ne,An(te)),ae=re;ie2&&Hn(ne,{x:te[2],y:te[3]})0){var _e=c,ve=Hn(_e,An(i)),ye=Hn(_e,An(ge)),be=ve;ye2&&Hn(_e,{x:ge[2],y:ge[3]})=l||v){d={cp:h,segment:_};break}}if(d)break}var y=d.cp,b=d.segment,x=(l-f)/b.length,S=b.t1-b.t0,C=c?b.t0+S*x:b.t1-S*x;C=qn(0,C,1),t=Gn(y.p0,y.p1,y.p2,C),i=Lf(y.p0,y.p1,y.p2,C);break;case`straight`:case`segments`:case`haystack`:for(var w=0,T,E,D,O,k=r.allpts.length,A=0;A+3=l));A+=2);var j=(l-E)/T;j=qn(0,j,1),t=Kn(D,O,j),i=If(D,O)}o(`labelX`,n,t.x),o(`labelY`,n,t.y),o(`labelAutoAngle`,n,i)}};c(`source`),c(`target`),this.applyLabelDimensions(e)}},Pf.applyLabelDimensions=function(e){this.applyPrefixedLabelDimensions(e),e.isEdge()&&(this.applyPrefixedLabelDimensions(e,`source`),this.applyPrefixedLabelDimensions(e,`target`))},Pf.applyPrefixedLabelDimensions=function(e,t){var n=e._private,r=this.getLabelText(e,t),i=Ct(r,e._private.labelDimsKey);if(Xt(n.rscratch,`prefixedLabelDimsKey`,t)!==i){Zt(n.rscratch,`prefixedLabelDimsKey`,t,i);var a=this.calculateLabelDimensions(e,r),o=e.pstyle(`line-height`).pfValue,s=e.pstyle(`font-size`).pfValue,c=e.pstyle(`text-wrap`).strValue,l=Xt(n.rscratch,`labelWrapCachedLines`,t)||[],u=c===`wrap`?Math.max(l.length,1):1,d=s*o,f=a.width,p=a.height+(u-1)*(o-1)*s;Zt(n.rstyle,`labelWidth`,t,f),Zt(n.rscratch,`labelWidth`,t,f),Zt(n.rstyle,`labelHeight`,t,p),Zt(n.rscratch,`labelHeight`,t,p),Zt(n.rscratch,`labelLineHeight`,t,d),Zt(n.rscratch,`labelActualDescent`,t,a.labelActualDescent)}},Pf.getLabelText=function(e,t){var n=e._private,r=t?t+`-`:``,i=e.pstyle(r+`label`).strValue,a=e.pstyle(`text-transform`).value,s=function(e,r){return r?(Zt(n.rscratch,e,t,r),r):Xt(n.rscratch,e,t)};if(!i)return``;a==`none`||(a==`uppercase`?i=i.toUpperCase():a==`lowercase`&&(i=i.toLowerCase()));var c=e.pstyle(`text-wrap`).value;if(c===`wrap`){var l=s(`labelKey`);if(l!=null&&s(`labelWrapKey`)===l)return s(`labelWrapCachedText`);for(var u=`​`,d=i.split(` +`),f=e.pstyle(`text-max-width`).pfValue,p=e.pstyle(`text-overflow-wrap`).value===`anywhere`,m=[],h=/[\s\u200b]+|$/g,g=0;gf){var y=_.matchAll(h),b=``,x=0,S=o(y),C;try{for(S.s();!(C=S.n()).done;){var w=C.value,T=w[0],E=_.substring(x,w.index);x=w.index+T.length;var D=b.length===0?E:b+E+T;this.calculateLabelDimensions(e,D).width<=f?b+=E+T:(b&&m.push(b),b=E+T)}}catch(e){S.e(e)}finally{S.f()}b.match(/^[\s\u200b]+$/)||m.push(b)}else m.push(_)}s(`labelWrapCachedLines`,m),i=s(`labelWrapCachedText`,m.join(` +`)),s(`labelWrapKey`,l)}else if(c===`ellipsis`){var O=e.pstyle(`text-max-width`).pfValue,k=``,A=`…`,j=!1;if(this.calculateLabelDimensions(e,i).widthO);M++)k+=i[M],M===i.length-1&&(j=!0);return j||(k+=A),k}return i},Pf.getLabelJustification=function(e){var t=e.pstyle(`text-justification`).strValue,n=e.pstyle(`text-halign`).strValue;return t===`auto`?e.isNode()?al(n):`center`:t},Pf.calculateLabelDimensions=function(e,t){var n=this.cy.window().document,r=0,i=e.pstyle(`font-style`).strValue,a=e.pstyle(`font-size`).pfValue,o=e.pstyle(`font-family`).strValue,s=e.pstyle(`font-weight`).strValue,c=e.pstyle(`text-metrics`).strValue||`font`,l=this.labelCalcCanvas,u=this.labelCalcCanvasContext;if(!l){l=this.labelCalcCanvas=n.createElement(`canvas`),u=this.labelCalcCanvasContext=l.getContext(`2d`);var d=l.style;d.position=`absolute`,d.left=`-9999px`,d.top=`-9999px`,d.zIndex=`-1`,d.visibility=`hidden`,d.pointerEvents=`none`}u.font=`${i} ${s} ${a}px ${o}`;for(var f=0,p=0,m=t.split(` +`),h=m.length,g=0,_=0,v=0;v1&&arguments[1]!==void 0?arguments[1]:!0;if(t.merge(e),n)for(var r=0;r=e.desktopTapThreshold2}var E=a(t);b&&(e.hoverData.tapholdCancelled=!0);var D=function(){var t=e.hoverData.dragDelta=e.hoverData.dragDelta||[];t.length===0?(t.push(v[0]),t.push(v[1])):(t[0]+=v[0],t[1]+=v[1])};n=!0,i(m,[`mousemove`,`vmousemove`,`tapdrag`],t,{x:l[0],y:l[1]});var O=function(e){return{originalEvent:t,type:e,position:{x:l[0],y:l[1]}}},k=function(){e.data.bgActivePosistion=void 0,e.hoverData.selecting||r.emit(O(`boxstart`)),f[4]=1,e.hoverData.selecting=!0,e.redrawHint(`select`,!0),e.redraw()};if(e.hoverData.which===3){if(b){var j=O(`cxtdrag`);_?_.emit(j):r.emit(j),e.hoverData.cxtDragged=!0,(!e.hoverData.cxtOver||m!==e.hoverData.cxtOver)&&(e.hoverData.cxtOver&&e.hoverData.cxtOver.emit(O(`cxtdragout`)),e.hoverData.cxtOver=m,m&&m.emit(O(`cxtdragover`)))}}else if(e.hoverData.dragging){if(n=!0,r.panningEnabled()&&r.userPanningEnabled()){var M;if(e.hoverData.justStartedPan){var N=e.hoverData.mdownPos;M={x:(l[0]-N[0])*s,y:(l[1]-N[1])*s},e.hoverData.justStartedPan=!1}else M={x:v[0]*s,y:v[1]*s};r.panBy(M),r.emit(O(`dragpan`)),e.hoverData.dragged=!0}l=e.projectIntoViewport(t.clientX,t.clientY)}else if(f[4]==1&&(_==null||_.pannable()))b&&(!e.hoverData.dragging&&r.boxSelectionEnabled()&&(E||!r.panningEnabled()||!r.userPanningEnabled())?k():!e.hoverData.selecting&&r.panningEnabled()&&r.userPanningEnabled()&&o(_,e.hoverData.downs)&&(e.hoverData.dragging=!0,e.hoverData.justStartedPan=!0,f[4]=0,e.data.bgActivePosistion=An(u),e.redrawHint(`select`,!0),e.redraw()),_&&_.pannable()&&_.active()&&_.unactivate());else{if(_&&_.pannable()&&_.active()&&_.unactivate(),(!_||!_.grabbed())&&m!=g&&(g&&i(g,[`mouseout`,`tapdragout`],t,{x:l[0],y:l[1]}),m&&i(m,[`mouseover`,`tapdragover`],t,{x:l[0],y:l[1]}),e.hoverData.last=m),_){if(b){if(r.boxSelectionEnabled()&&E)_&&_.grabbed()&&(h(y),_.emit(O(`freeon`)),y.emit(O(`free`)),e.dragData.didDrag&&(_.emit(O(`dragfreeon`)),y.emit(O(`dragfree`)))),k();else if(_&&_.grabbed()&&e.nodeIsDraggable(_)){var P=!e.dragData.didDrag;P&&e.redrawHint(`eles`,!0),e.dragData.didDrag=!0,e.hoverData.draggingEles||p(y,{inDragLayer:!0});var F={x:0,y:0};if(A(v[0])&&A(v[1])&&(F.x+=v[0],F.y+=v[1],P)){var I=e.hoverData.dragDelta;I&&A(I[0])&&A(I[1])&&(F.x+=I[0],F.y+=I[1])}e.hoverData.draggingEles=!0,y.silentShift(F).emit(O(`position`)).emit(O(`drag`)),e.redrawHint(`drag`,!0),e.redraw()}}else D()}n=!0}if(f[2]=l[0],f[3]=l[1],n)return t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),!1}},!1);var E,D,O;e.registerBinding(t,`mouseup`,function(t){if(!(e.hoverData.which===1&&t.which!==1&&e.hoverData.capture)&&e.hoverData.capture){e.hoverData.capture=!1;var r=e.cy,o=e.projectIntoViewport(t.clientX,t.clientY),s=e.selection,c=e.findNearestElement(o[0],o[1],!0,!1),l=e.dragData.possibleDragElements,u=e.hoverData.down,d=a(t);e.data.bgActivePosistion&&(e.redrawHint(`select`,!0),e.redraw()),e.hoverData.tapholdCancelled=!0,e.data.bgActivePosistion=void 0,u&&u.unactivate();var f=function(e){return{originalEvent:t,type:e,position:{x:o[0],y:o[1]}}};if(e.hoverData.which===3){var p=f(`cxttapend`);if(u?u.emit(p):r.emit(p),!e.hoverData.cxtDragged){var m=f(`cxttap`);u?u.emit(m):r.emit(m)}e.hoverData.cxtDragged=!1,e.hoverData.which=null}else if(e.hoverData.which===1){if(i(c,[`mouseup`,`tapend`,`vmouseup`],t,{x:o[0],y:o[1]}),!e.dragData.didDrag&&!e.hoverData.dragged&&!e.hoverData.selecting&&!e.hoverData.isOverThresholdDrag&&(i(u,[`click`,`tap`,`vclick`],t,{x:o[0],y:o[1]}),D=!1,t.timeStamp-O<=r.multiClickDebounceTime()?(E&&clearTimeout(E),D=!0,O=null,i(u,[`dblclick`,`dbltap`,`vdblclick`],t,{x:o[0],y:o[1]})):(E=setTimeout(function(){D||i(u,[`oneclick`,`onetap`,`voneclick`],t,{x:o[0],y:o[1]})},r.multiClickDebounceTime()),O=t.timeStamp)),u==null&&!e.dragData.didDrag&&!e.hoverData.selecting&&!e.hoverData.dragged&&!a(t)&&(r.$(n).unselect([`tapunselect`]),l.length>0&&e.redrawHint(`eles`,!0),e.dragData.possibleDragElements=l=r.collection()),c==u&&!e.dragData.didDrag&&!e.hoverData.selecting&&c!=null&&c._private.selectable&&(e.hoverData.dragging||(r.selectionType()===`additive`||d?c.selected()?c.unselect([`tapunselect`]):c.select([`tapselect`]):d||(r.$(n).unmerge(c).unselect([`tapunselect`]),c.select([`tapselect`]))),e.redrawHint(`eles`,!0)),e.hoverData.selecting){var g=r.collection(e.getAllInBox(s[0],s[1],s[2],s[3]));e.redrawHint(`select`,!0),g.length>0&&e.redrawHint(`eles`,!0),r.emit(f(`boxend`)),r.selectionType()===`additive`||d||r.$(n).unmerge(g).unselect(),g.emit(f(`box`)).stdFilter(function(e){return e.selectable()&&!e.selected()}).select().emit(f(`boxselect`)),e.redraw()}if(e.hoverData.dragging&&(e.hoverData.dragging=!1,e.redrawHint(`select`,!0),e.redrawHint(`eles`,!0),e.redraw()),!s[4]){e.redrawHint(`drag`,!0),e.redrawHint(`eles`,!0);var _=u&&u.grabbed();h(l),_&&(u.emit(f(`freeon`)),l.emit(f(`free`)),e.dragData.didDrag&&(u.emit(f(`dragfreeon`)),l.emit(f(`dragfree`))))}}s[4]=0,e.hoverData.down=null,e.hoverData.cxtStarted=!1,e.hoverData.draggingEles=!1,e.hoverData.selecting=!1,e.hoverData.isOverThresholdDrag=!1,e.dragData.didDrag=!1,e.hoverData.dragged=!1,e.hoverData.dragDelta=[],e.hoverData.mdownPos=null,e.hoverData.mdownGPos=null,e.hoverData.which=null}},!1);var k=[],j=4,M,N=1e5,P=function(e){for(var t=Math.abs(e[0]),n=1;n=j){M=!1;var i=k;if(i[0]>=5){var a=P(i)?i[0]:In(i);a>1&&(M=!0,N=a)}}else k.push(Math.abs(r)),n=!0}else M&&(N=Math.min(Math.abs(r),N));if(!e.scrollingPage){var o=e.cy,s=o.zoom(),c=o.pan(),l=e.projectIntoViewport(t.clientX,t.clientY),u=[l[0]*s+c.x,l[1]*s+c.y];if(e.hoverData.draggingEles||e.hoverData.dragging||e.hoverData.cxtStarted||C()){t.preventDefault();return}if(o.panningEnabled()&&o.userPanningEnabled()&&o.zoomingEnabled()&&o.userZoomingEnabled()){t.preventDefault(),e.data.wheelZooming=!0,clearTimeout(e.data.wheelTimeout),e.data.wheelTimeout=setTimeout(function(){e.data.wheelZooming=!1,e.redrawHint(`eles`,!0),e.redraw()},150);var d;n&&Math.abs(r)>5&&(r=Bn(r)*5),d=r/-250,M&&(d/=N,d*=3),d*=e.wheelSensitivity,t.deltaMode===1&&(d*=33);var f=o.zoom()*10**d;t.type===`gesturechange`&&(f=e.gestureStartZoom*t.scale),o.zoom({level:f,renderedPosition:{x:u[0],y:u[1]}}),o.emit({type:t.type===`gesturechange`?`pinchzoom`:`scrollzoom`,originalEvent:t,position:{x:l[0],y:l[1]}})}}}};e.registerBinding(e.container,`wheel`,F,!0),e.registerBinding(t,`scroll`,function(t){e.scrollingPage=!0,clearTimeout(e.scrollingPageTimeout),e.scrollingPageTimeout=setTimeout(function(){e.scrollingPage=!1},250)},!0),e.registerBinding(e.container,`gesturestart`,function(t){e.gestureStartZoom=e.cy.zoom(),e.hasTouchStarted||t.preventDefault()},!0),e.registerBinding(e.container,`gesturechange`,function(t){e.hasTouchStarted||F(t)},!0),e.registerBinding(e.container,`mouseout`,function(t){var n=e.projectIntoViewport(t.clientX,t.clientY);e.cy.emit({originalEvent:t,type:`mouseout`,position:{x:n[0],y:n[1]}})},!1),e.registerBinding(e.container,`mouseover`,function(t){var n=e.projectIntoViewport(t.clientX,t.clientY);e.cy.emit({originalEvent:t,type:`mouseover`,position:{x:n[0],y:n[1]}})},!1);var I,L,R,z,B,V,H,U,W,G,K,q,J,ee=function(e,t,n,r){return Math.sqrt((n-e)*(n-e)+(r-t)*(r-t))},Y=function(e,t,n,r){return(n-e)*(n-e)+(r-t)*(r-t)},te;e.registerBinding(e.container,`touchstart`,te=function(t){if(e.hasTouchStarted=!0,w(t)){_(),e.touchData.capture=!0,e.data.bgActivePosistion=void 0;var n=e.cy,r=e.touchData.now,a=e.touchData.earlier;if(t.touches[0]){var o=e.projectIntoViewport(t.touches[0].clientX,t.touches[0].clientY);r[0]=o[0],r[1]=o[1]}if(t.touches[1]){var o=e.projectIntoViewport(t.touches[1].clientX,t.touches[1].clientY);r[2]=o[0],r[3]=o[1]}if(t.touches[2]){var o=e.projectIntoViewport(t.touches[2].clientX,t.touches[2].clientY);r[4]=o[0],r[5]=o[1]}var s=function(e){return{originalEvent:t,type:e,position:{x:r[0],y:r[1]}}};if(t.touches[1]){e.touchData.singleTouchMoved=!0,h(e.dragData.touchDragEles);var c=e.findContainerClientCoords();W=c[0],G=c[1],K=c[2],q=c[3],I=t.touches[0].clientX-W,L=t.touches[0].clientY-G,R=t.touches[1].clientX-W,z=t.touches[1].clientY-G,J=0<=I&&I<=K&&0<=R&&R<=K&&0<=L&&L<=q&&0<=z&&z<=q;var u=n.pan(),d=n.zoom();B=ee(I,L,R,z),V=Y(I,L,R,z),H=[(I+R)/2,(L+z)/2],U=[(H[0]-u.x)/d,(H[1]-u.y)/d];var f=200,g=f*f;if(V=1){for(var T=e.touchData.startPosition=[null,null,null,null,null,null],E=0;E=e.touchTapThreshold2}if(n&&e.touchData.cxt){t.preventDefault();var x=t.touches[0].clientX-W,S=t.touches[0].clientY-G,C=t.touches[1].clientX-W,T=t.touches[1].clientY-G,E=Y(x,S,C,T),D=E/V,O=150,k=O*O,j=1.5;if(D>=j*j||E>=k){e.touchData.cxt=!1,e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var M=d(`cxttapend`);e.touchData.start?(e.touchData.start.unactivate().emit(M),e.touchData.start=null):a.emit(M)}}if(n&&e.touchData.cxt){var M=d(`cxtdrag`);e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0),e.touchData.start?e.touchData.start.emit(M):a.emit(M),e.touchData.start&&(e.touchData.start._private.grabbed=!1),e.touchData.cxtDragged=!0;var N=e.findNearestElement(s[0],s[1],!0,!0);(!e.touchData.cxtOver||N!==e.touchData.cxtOver)&&(e.touchData.cxtOver&&e.touchData.cxtOver.emit(d(`cxtdragout`)),e.touchData.cxtOver=N,N&&N.emit(d(`cxtdragover`)))}else if(n&&t.touches[2]&&a.boxSelectionEnabled())t.preventDefault(),e.data.bgActivePosistion=void 0,this.lastThreeTouch=+new Date,e.touchData.selecting||a.emit(d(`boxstart`)),e.touchData.selecting=!0,e.touchData.didSelect=!0,r[4]=1,!r||r.length===0||r[0]===void 0?(r[0]=(s[0]+s[2]+s[4])/3,r[1]=(s[1]+s[3]+s[5])/3,r[2]=(s[0]+s[2]+s[4])/3+1,r[3]=(s[1]+s[3]+s[5])/3+1):(r[2]=(s[0]+s[2]+s[4])/3,r[3]=(s[1]+s[3]+s[5])/3),e.redrawHint(`select`,!0),e.redraw();else if(n&&t.touches[1]&&!e.touchData.didSelect&&a.zoomingEnabled()&&a.panningEnabled()&&a.userZoomingEnabled()&&a.userPanningEnabled()){t.preventDefault(),e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var P=e.dragData.touchDragEles;if(P){e.redrawHint(`drag`,!0);for(var F=0;F0&&!e.hoverData.draggingEles&&!e.swipePanning&&e.data.bgActivePosistion!=null&&(e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0),e.redraw())}},!1);var re;e.registerBinding(t,`touchcancel`,re=function(t){var n=e.touchData.start;e.touchData.capture=!1,n&&n.unactivate()});var ie,ae,oe,se;if(e.registerBinding(t,`touchend`,ie=function(t){var r=e.touchData.start;if(e.touchData.capture)t.touches.length===0&&(e.touchData.capture=!1),t.preventDefault();else return;var a=e.selection;e.swipePanning=!1,e.hoverData.draggingEles=!1;var o=e.cy,s=o.zoom(),c=e.touchData.now,l=e.touchData.earlier;if(t.touches[0]){var u=e.projectIntoViewport(t.touches[0].clientX,t.touches[0].clientY);c[0]=u[0],c[1]=u[1]}if(t.touches[1]){var u=e.projectIntoViewport(t.touches[1].clientX,t.touches[1].clientY);c[2]=u[0],c[3]=u[1]}if(t.touches[2]){var u=e.projectIntoViewport(t.touches[2].clientX,t.touches[2].clientY);c[4]=u[0],c[5]=u[1]}var d=function(e){return{originalEvent:t,type:e,position:{x:c[0],y:c[1]}}};r&&r.unactivate();var f;if(e.touchData.cxt){if(f=d(`cxttapend`),r?r.emit(f):o.emit(f),!e.touchData.cxtDragged){var p=d(`cxttap`);r?r.emit(p):o.emit(p)}e.touchData.start&&(e.touchData.start._private.grabbed=!1),e.touchData.cxt=!1,e.touchData.start=null,e.redraw();return}if(!t.touches[2]&&o.boxSelectionEnabled()&&e.touchData.selecting){e.touchData.selecting=!1;var m=o.collection(e.getAllInBox(a[0],a[1],a[2],a[3]));a[0]=void 0,a[1]=void 0,a[2]=void 0,a[3]=void 0,a[4]=0,e.redrawHint(`select`,!0),o.emit(d(`boxend`)),m.emit(d(`box`)).stdFilter(function(e){return e.selectable()&&!e.selected()}).select().emit(d(`boxselect`)),m.nonempty()&&e.redrawHint(`eles`,!0),e.redraw()}if(r?.unactivate(),t.touches[2])e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);else if(!t.touches[1]&&!t.touches[0]&&!t.touches[0]){e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var g=e.dragData.touchDragEles;if(r!=null){var _=r._private.grabbed;h(g),e.redrawHint(`drag`,!0),e.redrawHint(`eles`,!0),_&&(r.emit(d(`freeon`)),g.emit(d(`free`)),e.dragData.didDrag&&(r.emit(d(`dragfreeon`)),g.emit(d(`dragfree`)))),i(r,[`touchend`,`tapend`,`vmouseup`,`tapdragout`],t,{x:c[0],y:c[1]}),r.unactivate(),e.touchData.start=null}else i(e.findNearestElement(c[0],c[1],!0,!0),[`touchend`,`tapend`,`vmouseup`,`tapdragout`],t,{x:c[0],y:c[1]});var v=e.touchData.startPosition[0]-c[0],y=v*v,b=e.touchData.startPosition[1]-c[1],x=(y+b*b)*s*s;e.touchData.singleTouchMoved||(r||o.$(`:selected`).unselect([`tapunselect`]),i(r,[`tap`,`vclick`],t,{x:c[0],y:c[1]}),ae=!1,t.timeStamp-se<=o.multiClickDebounceTime()?(oe&&clearTimeout(oe),ae=!0,se=null,i(r,[`dbltap`,`vdblclick`],t,{x:c[0],y:c[1]})):(oe=setTimeout(function(){ae||i(r,[`onetap`,`voneclick`],t,{x:c[0],y:c[1]})},o.multiClickDebounceTime()),se=t.timeStamp)),r!=null&&!e.dragData.didDrag&&r._private.selectable&&x`u`){var ce=[],X=function(e){return{clientX:e.clientX,clientY:e.clientY,force:1,identifier:e.pointerId,pageX:e.pageX,pageY:e.pageY,radiusX:e.width/2,radiusY:e.height/2,screenX:e.screenX,screenY:e.screenY,target:e.target}},le=function(e){return{event:e,touch:X(e)}},ue=function(e){ce.push(le(e))},de=function(e){for(var t=0;t0)return l[0]}return null},p=Object.keys(d),m=0;m0?d:lr(i,a,e,t,n,r,o,s)},checkPoint:function(e,t,n,r,i,a,o,s){s=s===`auto`?Nr(r,i):s;var c=2*s;if(_r(e,t,this.points,a,o,r,i-c,[0,-1],n)||_r(e,t,this.points,a,o,r-c,i,[0,-1],n))return!0;var l=r/2+2*n,u=i/2+2*n;return!!(gr(e,t,[a-l,o-u,a-l,o,a+l,o,a+l,o-u])||Sr(e,t,c,c,a+r/2-s,o+i/2-s,n)||Sr(e,t,c,c,a-r/2+s,o+i/2-s,n))}}},Yf.registerNodeShapes=function(){var e=this.nodeShapes={},t=this;this.generateEllipse(),this.generatePolygon(`triangle`,Ar(3,0)),this.generateRoundPolygon(`round-triangle`,Ar(3,0)),this.generatePolygon(`rectangle`,Ar(4,0)),e.square=e.rectangle,this.generateRoundRectangle(),this.generateCutRectangle(),this.generateBarrel(),this.generateBottomRoundrectangle();var n=[0,1,1,0,0,-1,-1,0];this.generatePolygon(`diamond`,n),this.generateRoundPolygon(`round-diamond`,n),this.generatePolygon(`pentagon`,Ar(5,0)),this.generateRoundPolygon(`round-pentagon`,Ar(5,0)),this.generatePolygon(`hexagon`,Ar(6,0)),this.generateRoundPolygon(`round-hexagon`,Ar(6,0)),this.generatePolygon(`heptagon`,Ar(7,0)),this.generateRoundPolygon(`round-heptagon`,Ar(7,0)),this.generatePolygon(`octagon`,Ar(8,0)),this.generateRoundPolygon(`round-octagon`,Ar(8,0));var r=Array(20),i=Mr(5,0),a=Mr(5,Math.PI/5),o=.5*(3-Math.sqrt(5));o*=1.57;for(var s=0;s=e.deqFastCost*h)break}else if(i){if(p>=e.deqCost*c||p>=e.deqAvgCost*s)break}else if(m>=e.deqNoDrawCost*ep)break;var g=e.deq(t,d,u);if(g.length>0)for(var _=0;_0&&(e.onDeqd(t,l),!i&&e.shouldRedraw(t,l,d,u)&&r())},a=e.priority||It;n.beforeRender(i,a(t))}}}},np=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Pt;r(this,e),this.idsByKey=new Qt,this.keyForId=new Qt,this.cachesByLvl=new Qt,this.lvls=[],this.getKey=t,this.doesEleInvalidateKey=n}return a(e,[{key:`getIdsFor`,value:function(e){e??Lt(`Can not get id list for null key`);var t=this.idsByKey,n=this.idsByKey.get(e);return n||(n=new tn,t.set(e,n)),n}},{key:`addIdForKey`,value:function(e,t){e!=null&&this.getIdsFor(e).add(t)}},{key:`deleteIdForKey`,value:function(e,t){e!=null&&this.getIdsFor(e).delete(t)}},{key:`getNumberOfIdsForKey`,value:function(e){return e==null?0:this.getIdsFor(e).size}},{key:`updateKeyMappingFor`,value:function(e){var t=e.id(),n=this.keyForId.get(t),r=this.getKey(e);this.deleteIdForKey(n,t),this.addIdForKey(r,t),this.keyForId.set(t,r)}},{key:`deleteKeyMappingFor`,value:function(e){var t=e.id(),n=this.keyForId.get(t);this.deleteIdForKey(n,t),this.keyForId.delete(t)}},{key:`keyHasChangedFor`,value:function(e){var t=e.id();return this.keyForId.get(t)!==this.getKey(e)}},{key:`isInvalid`,value:function(e){return this.keyHasChangedFor(e)||this.doesEleInvalidateKey(e)}},{key:`getCachesAt`,value:function(e){var t=this.cachesByLvl,n=this.lvls,r=t.get(e);return r||(r=new Qt,t.set(e,r),n.push(e)),r}},{key:`getCache`,value:function(e,t){return this.getCachesAt(t).get(e)}},{key:`get`,value:function(e,t){var n=this.getKey(e),r=this.getCache(n,t);return r!=null&&this.updateKeyMappingFor(e),r}},{key:`getForCachedKey`,value:function(e,t){var n=this.keyForId.get(e.id());return this.getCache(n,t)}},{key:`hasCache`,value:function(e,t){return this.getCachesAt(t).has(e)}},{key:`has`,value:function(e,t){var n=this.getKey(e);return this.hasCache(n,t)}},{key:`setCache`,value:function(e,t,n){n.key=e,this.getCachesAt(t).set(e,n)}},{key:`set`,value:function(e,t,n){var r=this.getKey(e);this.setCache(r,t,n),this.updateKeyMappingFor(e)}},{key:`deleteCache`,value:function(e,t){this.getCachesAt(t).delete(e)}},{key:`delete`,value:function(e,t){var n=this.getKey(e);this.deleteCache(n,t)}},{key:`invalidateKey`,value:function(e){var t=this;this.lvls.forEach(function(n){return t.deleteCache(e,n)})}},{key:`invalidate`,value:function(e){var t=e.id(),n=this.keyForId.get(t);this.deleteKeyMappingFor(e);var r=this.doesEleInvalidateKey(e);return r&&this.invalidateKey(n),r||this.getNumberOfIdsForKey(n)===0}}])}(),rp=25,ip=50,ap=-4,op=3,sp=7.99,cp=8,lp=1024,up=1024,dp=1024,fp=.2,pp=.8,mp=10,hp=.15,gp=.1,_p=.9,vp=.9,yp=100,bp=1,xp={dequeue:`dequeue`,downscale:`downscale`,highQuality:`highQuality`},Sp=Kt({getKey:null,doesEleInvalidateKey:Pt,drawElement:null,getBoundingBox:null,getRotationPoint:null,getRotationOffset:null,isVisible:Nt,allowEdgeTxrCaching:!0,allowParentTxrCaching:!0}),Cp=function(e,t){var n=this;n.renderer=e,n.onDequeues=[];var r=Sp(t);X(n,r),n.lookup=new np(r.getKey,r.doesEleInvalidateKey),n.setupDequeueing()},wp=Cp.prototype;wp.reasons=xp,wp.getTextureQueue=function(e){var t=this;return t.eleImgCaches=t.eleImgCaches||{},t.eleImgCaches[e]=t.eleImgCaches[e]||[]},wp.getRetiredTextureQueue=function(e){var t=this,n=t.eleImgCaches.retired=t.eleImgCaches.retired||{};return n[e]=n[e]||[]},wp.getElementQueue=function(){var e=this;return e.eleCacheQueue=e.eleCacheQueue||new pn(function(e,t){return t.reqs-e.reqs})},wp.getElementKeyToQueue=function(){var e=this;return e.eleKeyToCacheQueue=e.eleKeyToCacheQueue||{}},wp.getElement=function(e,t,n,r,i){var a=this,o=this.renderer,s=o.cy.zoom(),c=this.lookup;if(!t||t.w===0||t.h===0||isNaN(t.w)||isNaN(t.h)||!e.visible()||e.removed()||!a.allowEdgeTxrCaching&&e.isEdge()||!a.allowParentTxrCaching&&e.isParent())return null;if(r??=Math.ceil(zn(s*n)),r=sp||r>op)return null;var l=2**r,u=t.h*l,d=t.w*l,f=o.eleTextBiggerThanMin(e,l);if(!this.isVisible(e,f))return null;var p=c.get(e,r);if(p&&p.invalidated&&(p.invalidated=!1,p.texture.invalidatedWidth-=p.width),p)return p;var m=u<=rp?rp:u<=ip?ip:Math.ceil(u/ip)*ip;if(u>dp||d>up)return null;var h=a.getTextureQueue(m),g=h[h.length-2],_=function(){return a.recycleTexture(m,d)||a.addTexture(m,d)};g||=h[h.length-1],g||=_(),g.width-g.usedWidthr;D--)T=a.getElement(e,t,n,D,xp.downscale);E()}else return a.queueElement(e,S.level-1),S}else{var O;if(!y&&!b&&!x)for(var k=r-1;k>=ap;k--){var A=c.get(e,k);if(A){O=A;break}}if(v(O))return a.queueElement(e,r),O;g.context.translate(g.usedWidth,0),g.context.scale(l,l),this.drawElement(g.context,e,t,f,!1),g.context.scale(1/l,1/l),g.context.translate(-g.usedWidth,0)}return p={x:g.usedWidth,texture:g,level:r,scale:l,width:d,height:u,scaledLabelShown:f},g.usedWidth+=Math.ceil(d+cp),g.eleCaches.push(p),c.set(e,r,p),a.checkTextureFullness(g),p},wp.invalidateElements=function(e){for(var t=0;t=fp*e.width&&this.retireTexture(e)},wp.checkTextureFullness=function(e){var t=this.getTextureQueue(e.height);e.usedWidth/e.width>pp&&e.fullnessChecks>=mp?qt(t,e):e.fullnessChecks++},wp.retireTexture=function(e){var t=this,n=e.height,r=t.getTextureQueue(n),i=this.lookup;qt(r,e),e.retired=!0;for(var a=e.eleCaches,o=0;o=t)return o.retired=!1,o.usedWidth=0,o.invalidatedWidth=0,o.fullnessChecks=0,Jt(o.eleCaches),o.context.setTransform(1,0,0,1,0,0),o.context.clearRect(0,0,o.width,o.height),qt(i,o),r.push(o),o}},wp.queueElement=function(e,t){var n=this,r=n.getElementQueue(),i=n.getElementKeyToQueue(),a=this.getKey(e),o=i[a];if(o)o.level=Math.max(o.level,t),o.eles.merge(e),o.reqs++,r.updateItem(o);else{var s={eles:e.spawn().merge(e),level:t,reqs:1,key:a};r.push(s),i[a]=s}},wp.dequeue=function(e){for(var t=this,n=t.getElementQueue(),r=t.getElementKeyToQueue(),i=[],a=t.lookup,o=0;o0;o++){var s=n.pop(),c=s.key,l=s.eles[0],u=a.hasCache(l,s.level);if(r[c]=null,!u){i.push(s);var d=t.getBoundingBox(l);t.getElement(l,d,e,s.level,xp.dequeue)}}return i},wp.removeFromQueue=function(e){var t=this,n=t.getElementQueue(),r=t.getElementKeyToQueue(),i=this.getKey(e),a=r[i];a!=null&&(a.eles.length===1?(a.reqs=Mt,n.updateItem(a),n.pop(),r[i]=null):a.eles.unmerge(e))},wp.onDequeue=function(e){this.onDequeues.push(e)},wp.offDequeue=function(e){qt(this.onDequeues,e)},wp.setupDequeueing=tp.setupDequeueing({deqRedrawThreshold:yp,deqCost:hp,deqAvgCost:gp,deqNoDrawCost:_p,deqFastCost:vp,deq:function(e,t,n){return e.dequeue(t,n)},onDeqd:function(e,t){for(var n=0;n=Op||n>Dp)return null}r.validateLayersElesOrdering(n,e);var o=r.layersByLevel,s=2**n,c=o[n]=o[n]||[],l,u=r.levelIsComplete(n,e),d,f=function(){var t=function(t){if(r.validateLayersElesOrdering(t,e),r.levelIsComplete(t,e))return d=o[t],!0},i=function(e){if(!d)for(var r=n+e;Ep<=r&&r<=Dp&&!t(r);r+=e);};i(1),i(-1);for(var a=c.length-1;a>=0;a--){var s=c[a];s.invalid&&qt(c,s)}};if(!u)f();else return c;var p=function(){if(!l){l=Jn();for(var t=0;tRp||a>Rp||i*a>Lp)return null;var o=r.makeLayer(l,n);if(t!=null){var u=c.indexOf(t)+1;c.splice(u,0,o)}else(e.insert===void 0||e.insert)&&c.unshift(o);return o};if(r.skipping&&!a)return null;for(var h=null,g=e.length/Tp,_=!a,v=0;v=g||!ar(h.bb,y.boundingBox()))&&(h=m({insert:!0,after:h}),!h))return null;d||_?r.queueLayer(h,y):r.drawEleInLayer(h,y,n,t),h.eles.push(y),x[n]=h}return d||(_?null:c)},Vp.getEleLevelForLayerLevel=function(e,t){return e},Vp.drawEleInLayer=function(e,t,n,r){var i=this,a=this.renderer,o=e.context,s=t.boundingBox();s.w===0||s.h===0||!t.visible()||(n=i.getEleLevelForLayerLevel(n,r),a.setImgSmoothing(o,!1),a.drawCachedElement(o,t,null,null,n,zp),a.setImgSmoothing(o,!0))},Vp.levelIsComplete=function(e,t){var n=this.layersByLevel[e];if(!n||n.length===0)return!1;for(var r=0,i=0;i0||a.invalid)return!1;r+=a.eles.length}return r===t.length},Vp.validateLayersElesOrdering=function(e,t){var n=this.layersByLevel[e];if(n)for(var r=0;r0){t=!0;break}}return t},Vp.invalidateElements=function(e){var t=this;e.length!==0&&(t.lastInvalidationTime=ft(),!(e.length===0||!t.haveLayers())&&t.updateElementsInLayers(e,function(e,n,r){t.invalidateLayer(e)}))},Vp.invalidateLayer=function(e){if(this.lastInvalidationTime=ft(),!e.invalid){var t=e.level,n=e.eles,r=this.layersByLevel[t];qt(r,e),e.elesQueue=[],e.invalid=!0,e.replacement&&(e.replacement.invalid=!0);for(var i=0;i3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0,o=this,s=t._private.rscratch;if(!(a&&!t.visible())&&!(s.badLine||s.allpts==null||isNaN(s.allpts[0]))){var c;n&&(c=n,e.translate(-c.x1,-c.y1));var l=a?t.pstyle(`opacity`).value:1,u=a?t.pstyle(`line-opacity`).value:1,d=t.pstyle(`curve-style`).value,f=t.pstyle(`line-style`).value,p=t.pstyle(`width`).pfValue,m=t.pstyle(`line-cap`).value,h=t.pstyle(`line-outline-width`).value,g=t.pstyle(`line-outline-color`).value,_=l*u,v=l*u,y=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_;d===`straight-triangle`?(o.eleStrokeStyle(e,t,n),o.drawEdgeTrianglePath(t,e,s.allpts)):(e.lineWidth=p,e.lineCap=m,o.eleStrokeStyle(e,t,n),o.drawEdgePath(t,e,s.allpts,f),e.lineCap=`butt`)},b=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_;if(e.lineWidth=p+h,e.lineCap=m,h>0)o.colorStrokeStyle(e,g[0],g[1],g[2],n);else{e.lineCap=`butt`;return}d===`straight-triangle`?o.drawEdgeTrianglePath(t,e,s.allpts):(o.drawEdgePath(t,e,s.allpts,f),e.lineCap=`butt`)},x=function(){i&&o.drawEdgeOverlay(e,t)},S=function(){i&&o.drawEdgeUnderlay(e,t)},C=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:v;o.drawArrowheads(e,t,n)},w=function(){o.drawElementText(e,t,null,r)};if(e.lineJoin=`round`,t.pstyle(`ghost`).value===`yes`){var T=t.pstyle(`ghost-offset-x`).pfValue,E=t.pstyle(`ghost-offset-y`).pfValue,D=_*t.pstyle(`ghost-opacity`).value;e.translate(T,E),y(D),C(D),e.translate(-T,-E)}else b();S(),y(),C(),x(),w(),n&&e.translate(c.x1,c.y1)}};var am=function(e){if(![`overlay`,`underlay`].includes(e))throw Error(`Invalid state`);return function(t,n){if(n.visible()){var r=n.pstyle(`${e}-opacity`).value;if(r!==0){var i=this,a=i.usePaths(),o=n._private.rscratch,s=2*n.pstyle(`${e}-padding`).pfValue,c=n.pstyle(`${e}-color`).value;t.lineWidth=s,t.lineCap=o.edgeType===`self`&&!a?`butt`:`round`,i.colorStrokeStyle(t,c[0],c[1],c[2],r),i.drawEdgePath(n,t,o.allpts,`solid`)}}}};im.drawEdgeOverlay=am(`overlay`),im.drawEdgeUnderlay=am(`underlay`),im.drawEdgePath=function(e,t,n,r){var i=e._private.rscratch,a=t,s,c=!1,l=this.usePaths(),u=e.pstyle(`line-dash-pattern`).pfValue,d=e.pstyle(`line-dash-offset`).pfValue;if(l){var f=n.join(`$`);i.pathCacheKey&&i.pathCacheKey===f?(s=t=i.pathCache,c=!0):(s=t=new Path2D,i.pathCacheKey=f,i.pathCache=s)}if(a.setLineDash)switch(r){case`dotted`:a.setLineDash([1,1]);break;case`dashed`:a.setLineDash(u),a.lineDashOffset=d;break;case`solid`:a.setLineDash([])}if(!c&&!i.badLine)switch(t.beginPath&&t.beginPath(),t.moveTo(n[0],n[1]),i.edgeType){case`bezier`:case`self`:case`compound`:case`multibezier`:for(var p=2;p+35&&arguments[5]!==void 0?arguments[5]:!0,o=this;if(r==null){if(a&&!o.eleTextBiggerThanMin(t))return}else if(r===!1)return;if(t.isNode()){var s=t.pstyle(`label`);if(!s||!s.value)return;var c=o.getLabelJustification(t),l=t.pstyle(`text-metrics`).strValue===`glyph`;e.textAlign=c,e.textBaseline=l?`alphabetic`:`bottom`}else{var u=t.element()._private.rscratch.badLine,d=t.pstyle(`label`),f=t.pstyle(`source-label`),p=t.pstyle(`target-label`);if(u||(!d||!d.value)&&(!f||!f.value)&&(!p||!p.value))return;e.textAlign=`center`,e.textBaseline=`bottom`}var m=!n,h;n&&(h=n,e.translate(-h.x1,-h.y1)),i==null?(o.drawText(e,t,null,m,a),t.isEdge()&&(o.drawText(e,t,`source`,m,a),o.drawText(e,t,`target`,m,a))):o.drawText(e,t,i,m,a),n&&e.translate(h.x1,h.y1)},sm.getFontCache=function(e){var t;this.fontCaches=this.fontCaches||[];for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:!0,r=t.pstyle(`font-style`).strValue,i=t.pstyle(`font-size`).pfValue+`px`,a=t.pstyle(`font-family`).strValue,o=t.pstyle(`font-weight`).strValue,s=n?t.effectiveOpacity()*t.pstyle(`text-opacity`).value:1,c=t.pstyle(`text-outline-opacity`).value*s,l=t.pstyle(`color`).value,u=t.pstyle(`text-outline-color`).value;e.font=r+` `+o+` `+i+` `+a,e.lineJoin=`round`,this.colorFillStyle(e,l[0],l[1],l[2],s),this.colorStrokeStyle(e,u[0],u[1],u[2],c)};function cm(e,t,n,r,i){var a=Math.min(r,i)/2,o=t+r/2,s=n+i/2;e.beginPath(),e.arc(o,s,a,0,Math.PI*2),e.closePath()}function lm(e,t,n,r,i){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:5,o=Math.min(a,r/2,i/2);e.beginPath(),e.moveTo(t+o,n),e.lineTo(t+r-o,n),e.quadraticCurveTo(t+r,n,t+r,n+o),e.lineTo(t+r,n+i-o),e.quadraticCurveTo(t+r,n+i,t+r-o,n+i),e.lineTo(t+o,n+i),e.quadraticCurveTo(t,n+i,t,n+i-o),e.lineTo(t,n+o),e.quadraticCurveTo(t,n,t+o,n),e.closePath()}sm.getTextAngle=function(e,t){var n,r=e._private.rscratch,i=t?t+`-`:``,a=e.pstyle(i+`text-rotation`);if(a.strValue===`autorotate`){var o=Xt(r,`labelAngle`,t);n=e.isEdge()?o:0}else n=a.strValue===`none`?0:a.pfValue;return n},sm.drawText=function(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=t._private.rscratch,o=i?t.effectiveOpacity():1;if(!(i&&(o===0||t.pstyle(`text-opacity`).value===0))){n===`main`&&(n=null);var s=Xt(a,`labelX`,n),c=Xt(a,`labelY`,n),l,u,d=this.getLabelText(t,n);if(d!=null&&d!==``&&!isNaN(s)&&!isNaN(c)){this.setupTextStyle(e,t,i);var f=n?n+`-`:``,p=Xt(a,`labelWidth`,n),m=Xt(a,`labelHeight`,n),h=Xt(a,`labelActualDescent`,n),g=t.pstyle(f+`text-margin-x`).pfValue,_=t.pstyle(f+`text-margin-y`).pfValue,v=t.isEdge(),y=t.pstyle(`text-halign`).value,b=t.pstyle(`text-valign`).value;v&&(y=`center`,b=`center`),s+=g,c+=_;var x=r?this.getTextAngle(t,n):0;x!==0&&(l=s,u=c,e.translate(l,u),e.rotate(x),s=0,c=0);var S=rl(y),C=il(b);switch(C){case`top`:break;case`center`:c+=m/2;break;case`bottom`:c+=m}var w=t.pstyle(`text-background-opacity`).value,T=t.pstyle(`text-border-opacity`).value,E=t.pstyle(`text-border-width`).pfValue,D=t.pstyle(`text-background-padding`).pfValue,O=t.pstyle(`text-background-shape`).strValue,k=O===`round-rectangle`||O===`roundrectangle`,A=O===`circle`,j=2;if(w>0||E>0&&T>0){var M=e.fillStyle,N=e.strokeStyle,P=e.lineWidth,F=t.pstyle(`text-background-color`).value,I=t.pstyle(`text-border-color`).value,L=t.pstyle(`text-border-style`).value,R=w>0,z=E>0&&T>0,B=s-D;switch(S){case`left`:B-=p;break;case`center`:B-=p/2}var V=c-m-D,H=p+2*D,U=m+2*D;if(R&&(e.fillStyle=`rgba(${F[0]},${F[1]},${F[2]},${w*o})`),z&&(e.strokeStyle=`rgba(${I[0]},${I[1]},${I[2]},${T*o})`,e.lineWidth=E,e.setLineDash))switch(L){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash([4,2]);break;case`double`:e.lineWidth=E/4,e.setLineDash([]);break;default:e.setLineDash([])}if(k?(e.beginPath(),lm(e,B,V,H,U,j)):A?(e.beginPath(),cm(e,B,V,H,U)):(e.beginPath(),e.rect(B,V,H,U)),R&&e.fill(),z&&e.stroke(),z&&L===`double`){var W=E/2;e.beginPath(),k?lm(e,B+W,V+W,H-2*W,U-2*W,j):e.rect(B+W,V+W,H-2*W,U-2*W),e.stroke()}e.fillStyle=M,e.strokeStyle=N,e.lineWidth=P,e.setLineDash&&e.setLineDash([])}var G=2*t.pstyle(`text-outline-width`).pfValue;if(G>0&&(e.lineWidth=G),c-=h,t.pstyle(`text-wrap`).value===`wrap`){var K=Xt(a,`labelWrapCachedLines`,n),q=Xt(a,`labelLineHeight`,n),J=p/2,ee=this.getLabelJustification(t);switch(ee===`auto`||(S===`left`?ee===`left`?s+=-p:ee===`center`&&(s+=-J):S===`center`?ee===`left`?s+=-J:ee===`right`&&(s+=J):S===`right`&&(ee===`center`?s+=J:ee===`right`&&(s+=p))),C){case`top`:c-=(K.length-1)*q;break;case`center`:case`bottom`:c-=(K.length-1)*q}for(var Y=0;Y0&&e.strokeText(K[Y],s,c),e.fillText(K[Y],s,c),c+=q}else G>0&&e.strokeText(d,s,c),e.fillText(d,s,c);x!==0&&(e.rotate(-x),e.translate(-l,-u))}}};var um={};um.drawNode=function(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0,o=this,s,c,l=t._private,u=l.rscratch,d=t.position();if(!(!A(d.x)||!A(d.y))&&!(a&&!t.visible())){var f=a?t.effectiveOpacity():1,p=o.usePaths(),m,h=!1,g=t.padding();s=t.width()+2*g,c=t.height()+2*g;var _;n&&(_=n,e.translate(-_.x1,-_.y1));for(var v=t.pstyle(`background-image`).value,y=Array(v.length),b=Array(v.length),x=0,S=0;S0&&arguments[0]!==void 0?arguments[0]:D;o.eleFillStyle(e,t,n)},W=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:I;o.colorStrokeStyle(e,O[0],O[1],O[2],t)},G=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:B;o.colorStrokeStyle(e,R[0],R[1],R[2],t)},K=function(e,t,n,r){var i=o.nodePathCache=o.nodePathCache||[],a=wt(n===`polygon`?n+`,`+r.join(`,`):n,``+t,``+e,``+H),s=i[a],c,l=!1;return s==null?(c=new Path2D,i[a]=u.pathCache=c):(c=s,l=!0,u.pathCache=c),{path:c,cacheHit:l}},q=t.pstyle(`shape`).strValue,J=t.pstyle(`shape-polygon-points`).pfValue;if(p){e.translate(d.x,d.y);var ee=K(s,c,q,J);m=ee.path,h=ee.cacheHit}var Y=function(){if(!h){var n=d;p&&(n={x:0,y:0}),o.nodeShapes[o.getNodeShape(t)].draw(m||e,n.x,n.y,s,c,H,u)}p?e.fill(m):e.fill()},te=function(){for(var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:f,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,i=l.backgrounding,a=0,s=0;s0&&arguments[0]!==void 0&&arguments[0],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f;o.hasPie(t)&&(o.drawPie(e,t,r),n&&(p||o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u)))},re=function(){var n=arguments.length>0&&arguments[0]!==void 0&&arguments[0],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f;o.hasStripe(t)&&(e.save(),p?e.clip(u.pathCache):(o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u),e.clip()),o.drawStripe(e,t,r),e.restore(),n&&(p||o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u)))},ie=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:f,n=(T>0?T:-T)*t,r=T>0?0:255;T!==0&&(o.colorFillStyle(e,r,r,r,n),p?e.fill(m):e.fill())},ae=function(){if(E>0){if(e.lineWidth=E,e.lineCap=M,e.lineJoin=j,e.setLineDash)switch(k){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash(P),e.lineDashOffset=F;break;case`solid`:case`double`:e.setLineDash([])}if(N!==`center`){if(e.save(),e.lineWidth*=2,N===`inside`)p?e.clip(m):e.clip();else{var t=new Path2D;t.rect(-s/2-E,-c/2-E,s+2*E,c+2*E),t.addPath(m),e.clip(t,`evenodd`)}p?e.stroke(m):e.stroke(),e.restore()}else p?e.stroke(m):e.stroke();if(k===`double`){e.lineWidth=E/3;var n=e.globalCompositeOperation;e.globalCompositeOperation=`destination-out`,p?e.stroke(m):e.stroke(),e.globalCompositeOperation=n}e.setLineDash&&e.setLineDash([])}},oe=function(){if(L>0){if(e.lineWidth=L,e.lineCap=`butt`,e.setLineDash)switch(z){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash([4,2]);break;case`solid`:case`double`:e.setLineDash([])}var n=d;p&&(n={x:0,y:0});var r=o.getNodeShape(t),i=E;N===`inside`&&(i=0),N===`outside`&&(i*=2);var a=(s+i+(L+V))/s,l=(c+i+(L+V))/c,u=s*a,f=c*l,m=o.nodeShapes[r].points,h;if(p&&(h=K(u,f,r,m).path),r===`ellipse`)o.drawEllipsePath(h||e,n.x,n.y,u,f);else if([`round-diamond`,`round-heptagon`,`round-hexagon`,`round-octagon`,`round-pentagon`,`round-polygon`,`round-triangle`,`round-tag`].includes(r)){var g=0,_=0,v=0;r===`round-diamond`?g=(i+V+L)*1.4:r===`round-heptagon`?(g=(i+V+L)*1.075,v=-(i/2+V+L)/35):r===`round-hexagon`?g=(i+V+L)*1.12:r===`round-pentagon`?(g=(i+V+L)*1.13,v=-(i/2+V+L)/15):r===`round-tag`?(g=(i+V+L)*1.12,_=(i/2+L+V)*.07):r===`round-triangle`&&(g=(i+V+L)*(Math.PI/2),v=-(i+V/2+L)/Math.PI),g!==0&&(a=(s+g)/s,u=s*a,[`round-hexagon`,`round-tag`].includes(r)||(l=(c+g)/c,f=c*l)),H=H===`auto`?Pr(u,f):H;for(var y=u/2,b=f/2,x=H+(i+L+V)/2,S=Array(m.length/2),C=Array(m.length/2),w=0;w0){if(r||=n.position(),i==null||a==null){var f=n.padding();i=n.width()+2*f,a=n.height()+2*f}o.colorFillStyle(t,l[0],l[1],l[2],c),o.nodeShapes[u].draw(t,r.x,r.y,i+s*2,a+s*2,d),t.fill()}}}};um.drawNodeOverlay=dm(`overlay`),um.drawNodeUnderlay=dm(`underlay`),um.hasPie=function(e){return e=e[0],e._private.hasPie},um.hasStripe=function(e){return e=e[0],e._private.hasStripe},um.drawPie=function(e,t,n,r){t=t[0],r||=t.position();var i=t.cy().style(),a=t.pstyle(`pie-size`),o=t.pstyle(`pie-hole`),s=t.pstyle(`pie-start-angle`).pfValue,c=r.x,l=r.y,u=t.width(),d=t.height(),f=Math.min(u,d)/2,p,m=0;if(this.usePaths()&&(c=0,l=0),a.units===`%`?f*=a.pfValue:a.pfValue!==void 0&&(f=a.pfValue/2),o.units===`%`?p=f*o.pfValue:o.pfValue!==void 0&&(p=o.pfValue/2),!(p>=f))for(var h=1;h<=i.pieBackgroundN;h++){var g=t.pstyle(`pie-`+h+`-background-size`).value,_=t.pstyle(`pie-`+h+`-background-color`).value,v=t.pstyle(`pie-`+h+`-background-opacity`).value*n,y=g/100;y+m>1&&(y=1-m);var b=1.5*Math.PI+2*Math.PI*m;b+=s;var x=2*Math.PI*y,S=b+x;g===0||m>=1||m+y>1||(p===0?(e.beginPath(),e.moveTo(c,l),e.arc(c,l,f,b,S),e.closePath()):(e.beginPath(),e.arc(c,l,f,b,S),e.arc(c,l,p,S,b,!0),e.closePath()),this.colorFillStyle(e,_[0],_[1],_[2],v),e.fill(),m+=y)}},um.drawStripe=function(e,t,n,r){t=t[0],r||=t.position();var i=t.cy().style(),a=r.x,o=r.y,s=t.width(),c=t.height(),l=0,u=this.usePaths();e.save();var d=t.pstyle(`stripe-direction`).value,f=t.pstyle(`stripe-size`);switch(d){case`vertical`:break;case`righward`:e.rotate(-Math.PI/2)}var p=s,m=c;f.units===`%`?(p*=f.pfValue,m*=f.pfValue):f.pfValue!==void 0&&(p=f.pfValue,m=f.pfValue),u&&(a=0,o=0),o-=p/2,a-=m/2;for(var h=1;h<=i.stripeBackgroundN;h++){var g=t.pstyle(`stripe-`+h+`-background-size`).value,_=t.pstyle(`stripe-`+h+`-background-color`).value,v=t.pstyle(`stripe-`+h+`-background-opacity`).value*n,y=g/100;y+l>1&&(y=1-l),!(g===0||l>=1||l+y>1)&&(e.beginPath(),e.rect(a,o+m*l,p,m*y),e.closePath(),this.colorFillStyle(e,_[0],_[1],_[2],v),e.fill(),l+=y)}e.restore()};var fm={},pm=100;fm.getPixelRatio=function(){var e=this.data.contexts[0];if(this.forcedPixelRatio!=null)return this.forcedPixelRatio;var t=this.cy.window(),n=e.backingStorePixelRatio||e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1;return(t.devicePixelRatio||1)/n},fm.paintCache=function(e){for(var t=this.paintCaches=this.paintCaches||[],n=!0,r,i=0;it.minMbLowQualFrames&&(t.motionBlurPxRatio=t.mbPxRBlurry)),t.clearingMotionBlur&&(t.motionBlurPxRatio=1),t.textureDrawLastFrame&&!d&&(u[t.NODE]=!0,u[t.SELECT_BOX]=!0);var v=n.style(),y=n.zoom(),b=o===void 0?y:o,x=n.pan(),S={x:x.x,y:x.y},C={zoom:y,pan:{x:x.x,y:x.y}},w=t.prevViewport;w!==void 0&&C.zoom===w.zoom&&C.pan.x===w.pan.x&&C.pan.y===w.pan.y&&!(h&&!m)&&(t.motionBlurPxRatio=1),s&&(S=s),b*=c,S.x*=c,S.y*=c;var T=t.getCachedZSortedEles();function E(e,n,r,i,a){var o=e.globalCompositeOperation;e.globalCompositeOperation=`destination-out`,t.colorFillStyle(e,255,255,255,t.motionBlurTransparency),e.fillRect(n,r,i,a),e.globalCompositeOperation=o}function D(e,n){var a,c,u,d;!t.clearingMotionBlur&&(e===l.bufferContexts[t.MOTIONBLUR_BUFFER_NODE]||e===l.bufferContexts[t.MOTIONBLUR_BUFFER_DRAG])?(a={x:x.x*p,y:x.y*p},c=y*p,u=t.canvasWidth*p,d=t.canvasHeight*p):(a=S,c=b,u=t.canvasWidth,d=t.canvasHeight),e.setTransform(1,0,0,1,0,0),n===`motionBlur`?E(e,0,0,u,d):!r&&(n===void 0||n)&&e.clearRect(0,0,u,d),i||(e.translate(a.x,a.y),e.scale(c,c)),s&&e.translate(s.x,s.y),o&&e.scale(o,o)}if(d||(t.textureDrawLastFrame=!1),d){if(t.textureDrawLastFrame=!0,!t.textureCache){t.textureCache={},t.textureCache.bb=n.mutableElements().boundingBox(),t.textureCache.texture=t.data.bufferCanvases[t.TEXTURE_BUFFER];var O=t.data.bufferContexts[t.TEXTURE_BUFFER];O.setTransform(1,0,0,1,0,0),O.clearRect(0,0,t.canvasWidth*t.textureMult,t.canvasHeight*t.textureMult),t.render({forcedContext:O,drawOnlyNodeLayer:!0,forcedPxRatio:c*t.textureMult});var C=t.textureCache.viewport={zoom:n.zoom(),pan:n.pan(),width:t.canvasWidth,height:t.canvasHeight};C.mpan={x:(0-C.pan.x)/C.zoom,y:(0-C.pan.y)/C.zoom}}u[t.DRAG]=!1,u[t.NODE]=!1;var k=l.contexts[t.NODE],A=t.textureCache.texture,C=t.textureCache.viewport;k.setTransform(1,0,0,1,0,0),f?E(k,0,0,C.width,C.height):k.clearRect(0,0,C.width,C.height);var j=v.core(`outside-texture-bg-color`).value,M=v.core(`outside-texture-bg-opacity`).value;t.colorFillStyle(k,j[0],j[1],j[2],M),k.fillRect(0,0,C.width,C.height);var y=n.zoom();D(k,!1),k.clearRect(C.mpan.x,C.mpan.y,C.width/C.zoom/c,C.height/C.zoom/c),k.drawImage(A,C.mpan.x,C.mpan.y,C.width/C.zoom/c,C.height/C.zoom/c)}else t.textureOnViewport&&!r&&(t.textureCache=null);var N=n.extent(),P=t.pinching||t.hoverData.dragging||t.swipePanning||t.data.wheelZooming||t.hoverData.draggingEles||t.cy.animated(),F=t.hideEdgesOnViewport&&P,I=[];if(I[t.NODE]=!u[t.NODE]&&f&&!t.clearedForMotionBlur[t.NODE]||t.clearingMotionBlur,I[t.NODE]&&(t.clearedForMotionBlur[t.NODE]=!0),I[t.DRAG]=!u[t.DRAG]&&f&&!t.clearedForMotionBlur[t.DRAG]||t.clearingMotionBlur,I[t.DRAG]&&(t.clearedForMotionBlur[t.DRAG]=!0),u[t.NODE]||i||a||I[t.NODE]){var L=f&&!I[t.NODE]&&p!==1,k=r||(L?t.data.bufferContexts[t.MOTIONBLUR_BUFFER_NODE]:l.contexts[t.NODE]);D(k,f&&!L?`motionBlur`:void 0),F?t.drawCachedNodes(k,T.nondrag,c,N):t.drawLayeredElements(k,T.nondrag,c,N),t.debug&&t.drawDebugPoints(k,T.nondrag),!i&&!f&&(u[t.NODE]=!1)}if(!a&&(u[t.DRAG]||i||I[t.DRAG])){var L=f&&!I[t.DRAG]&&p!==1,k=r||(L?t.data.bufferContexts[t.MOTIONBLUR_BUFFER_DRAG]:l.contexts[t.DRAG]);D(k,f&&!L?`motionBlur`:void 0),F?t.drawCachedNodes(k,T.drag,c,N):t.drawCachedElements(k,T.drag,c,N),t.debug&&t.drawDebugPoints(k,T.drag),!i&&!f&&(u[t.DRAG]=!1)}if(this.drawSelectionRectangle(e,D),f&&p!==1){var R=l.contexts[t.NODE],z=t.data.bufferCanvases[t.MOTIONBLUR_BUFFER_NODE],B=l.contexts[t.DRAG],V=t.data.bufferCanvases[t.MOTIONBLUR_BUFFER_DRAG],H=function(e,n,r){e.setTransform(1,0,0,1,0,0),r||!_?e.clearRect(0,0,t.canvasWidth,t.canvasHeight):E(e,0,0,t.canvasWidth,t.canvasHeight);var i=p;e.drawImage(n,0,0,t.canvasWidth*i,t.canvasHeight*i,0,0,t.canvasWidth,t.canvasHeight)};(u[t.NODE]||I[t.NODE])&&(H(R,z,I[t.NODE]),u[t.NODE]=!1),(u[t.DRAG]||I[t.DRAG])&&(H(B,V,I[t.DRAG]),u[t.DRAG]=!1)}t.prevViewport=C,t.clearingMotionBlur&&(t.clearingMotionBlur=!1,t.motionBlurCleared=!0,t.motionBlur=!0),f&&(t.motionBlurTimeout=setTimeout(function(){t.motionBlurTimeout=null,t.clearedForMotionBlur[t.NODE]=!1,t.clearedForMotionBlur[t.DRAG]=!1,t.motionBlur=!1,t.clearingMotionBlur=!d,t.mbFrames=0,u[t.NODE]=!0,u[t.DRAG]=!0,t.redraw()},pm)),r||n.emit(`render`)};var mm;fm.drawSelectionRectangle=function(e,t){var n=this,r=n.cy,i=n.data,a=r.style(),o=e.drawOnlyNodeLayer,s=e.drawAllLayers,c=i.canvasNeedsRedraw,l=e.forcedContext;if(n.showFps||!o&&c[n.SELECT_BOX]&&!s){var u=l||i.contexts[n.SELECT_BOX];if(t(u),n.selection[4]==1&&(n.hoverData.selecting||n.touchData.selecting)){var d=n.cy.zoom(),f=a.core(`selection-box-border-width`).value/d;u.lineWidth=f,u.fillStyle=`rgba(`+a.core(`selection-box-color`).value[0]+`,`+a.core(`selection-box-color`).value[1]+`,`+a.core(`selection-box-color`).value[2]+`,`+a.core(`selection-box-opacity`).value+`)`,u.fillRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]),f>0&&(u.strokeStyle=`rgba(`+a.core(`selection-box-border-color`).value[0]+`,`+a.core(`selection-box-border-color`).value[1]+`,`+a.core(`selection-box-border-color`).value[2]+`,`+a.core(`selection-box-opacity`).value+`)`,u.strokeRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]))}if(i.bgActivePosistion&&!n.hoverData.selecting){var d=n.cy.zoom(),p=i.bgActivePosistion;u.fillStyle=`rgba(`+a.core(`active-bg-color`).value[0]+`,`+a.core(`active-bg-color`).value[1]+`,`+a.core(`active-bg-color`).value[2]+`,`+a.core(`active-bg-opacity`).value+`)`,u.beginPath(),u.arc(p.x,p.y,a.core(`active-bg-size`).pfValue/d,0,2*Math.PI),u.fill()}var m=n.lastRedrawTime;if(n.showFps&&m){m=Math.round(m);var h=Math.round(1e3/m),g=`1 frame = `+m+` ms = `+h+` fps`;u.setTransform(1,0,0,1,0,0),u.fillStyle=`rgba(255, 0, 0, 0.75)`,u.strokeStyle=`rgba(255, 0, 0, 0.75)`,u.font=`30px Arial`,mm||=u.measureText(g).actualBoundingBoxAscent,u.fillText(g,0,mm),u.strokeRect(0,mm+10,250,20),u.fillRect(0,mm+10,250*Math.min(h/60,1),20)}s||(c[n.SELECT_BOX]=!1)}};function hm(e,t,n){var r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS))throw Error(e.getShaderInfoLog(r));return r}function gm(e,t,n){var r=hm(e,e.VERTEX_SHADER,t),i=hm(e,e.FRAGMENT_SHADER,n),a=e.createProgram();if(e.attachShader(a,r),e.attachShader(a,i),e.linkProgram(a),!e.getProgramParameter(a,e.LINK_STATUS))throw Error(`Could not initialize shaders`);return a}function _m(e,t,n){n===void 0&&(n=t);var r=e.makeOffscreenCanvas(t,n),i=r.context=r.getContext(`2d`);return r.clear=function(){return i.clearRect(0,0,r.width,r.height)},r.clear(),r}function vm(e){var t=e.pixelRatio,n=e.cy.zoom(),r=e.cy.pan();return{zoom:n*t,pan:{x:r.x*t,y:r.y*t}}}function ym(e){var t=e.pixelRatio;return e.cy.zoom()*t}function bm(e,t,n,r,i){var a=r*n+t.x,o=i*n+t.y;return o=Math.round(e.canvasHeight-o),[a,o]}function xm(e,t){return t.picking?!0:e.pstyle(`background-fill`).value!==`solid`||e.pstyle(`background-image`).strValue!==`none`?!1:e.pstyle(`border-width`).value===0||e.pstyle(`border-opacity`).value===0||e.pstyle(`border-style`).value===`solid`}function Sm(e,t){if(e.length!==t.length)return!1;for(var n=0;n>0&255)/255,n[1]=(e>>8&255)/255,n[2]=(e>>16&255)/255,n[3]=(e>>24&255)/255,n}function Tm(e){return e[0]+(e[1]<<8)+(e[2]<<16)+(e[3]<<24)}function Em(e,t){var n=e.createTexture();return n.buffer=function(t){e.bindTexture(e.TEXTURE_2D,n),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR_MIPMAP_NEAREST),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),e.generateMipmap(e.TEXTURE_2D),e.bindTexture(e.TEXTURE_2D,null)},n.deleteTexture=function(){e.deleteTexture(n)},n}function Dm(e,t){switch(t){case`float`:return[1,e.FLOAT,4];case`vec2`:return[2,e.FLOAT,4];case`vec3`:return[3,e.FLOAT,4];case`vec4`:return[4,e.FLOAT,4];case`int`:return[1,e.INT,4];case`ivec2`:return[2,e.INT,4]}}function Om(e,t,n){switch(t){case e.FLOAT:return new Float32Array(n);case e.INT:return new Int32Array(n)}}function km(e,t,n,r,i,a){switch(t){case e.FLOAT:return new Float32Array(n.buffer,a*r,i);case e.INT:return new Int32Array(n.buffer,a*r,i)}}function Am(e,t,n,r){var i=f(Dm(e,t),2),a=i[0],o=i[1],s=Om(e,o,r),c=e.createBuffer();return e.bindBuffer(e.ARRAY_BUFFER,c),e.bufferData(e.ARRAY_BUFFER,s,e.STATIC_DRAW),o===e.FLOAT?e.vertexAttribPointer(n,a,o,!1,0,0):o===e.INT&&e.vertexAttribIPointer(n,a,o,0,0),e.enableVertexAttribArray(n),e.bindBuffer(e.ARRAY_BUFFER,null),c}function jm(e,t,n,r){var i=f(Dm(e,n),3),a=i[0],o=i[1],s=i[2],c=Om(e,o,t*a),l=a*s,u=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,u),e.bufferData(e.ARRAY_BUFFER,t*l,e.DYNAMIC_DRAW),e.enableVertexAttribArray(r),o===e.FLOAT?e.vertexAttribPointer(r,a,o,!1,l,0):o===e.INT&&e.vertexAttribIPointer(r,a,o,l,0),e.vertexAttribDivisor(r,1),e.bindBuffer(e.ARRAY_BUFFER,null);for(var d=Array(t),p=0;pi&&(a=i/t,o=t*a,s=n*a),{scale:a,texW:o,texH:s}}},{key:`draw`,value:function(e,t,n){var r=this;if(this.locked)throw Error(`can't draw, atlas is locked`);var i=this.texSize,a=this.texRows,o=this.texHeight,s=this.getScale(t),c=s.scale,l=s.texW,u=s.texH,d=function(e,r){if(n&&r){var i=r.context,a=e.x,s=e.row,l=a,u=o*s;i.save(),i.translate(l,u),i.scale(c,c),n(i,t),i.restore()}},f=[null,null],p=function(){d(r.freePointer,r.canvas),f[0]={x:r.freePointer.x,y:r.freePointer.row*o,w:l,h:u},f[1]={x:r.freePointer.x+l,y:r.freePointer.row*o,w:0,h:u},r.freePointer.x+=l,r.freePointer.x==i&&(r.freePointer.x=0,r.freePointer.row++)},m=function(){var e=r.scratch,t=r.canvas;e.clear(),d({x:0,row:0},e);var n=i-r.freePointer.x,a=l-n,s=o,c=r.freePointer.x,p=r.freePointer.row*o,m=n;t.context.drawImage(e,0,0,m,s,c,p,m,s),f[0]={x:c,y:p,w:m,h:u};var h=n,g=(r.freePointer.row+1)*o,_=a;t&&t.context.drawImage(e,h,0,_,s,0,g,_,s),f[1]={x:0,y:g,w:_,h:u},r.freePointer.x=a,r.freePointer.row++},h=function(){r.freePointer.x=0,r.freePointer.row++};if(this.freePointer.x+l<=i)p();else if(this.freePointer.row>=a-1)return!1;else this.freePointer.x===i?(h(),p()):this.enableWrapping?m():(h(),p());return this.keyToLocation.set(e,f),this.needsBuffer=!0,f}},{key:`getOffsets`,value:function(e){return this.keyToLocation.get(e)}},{key:`isEmpty`,value:function(){return this.freePointer.x===0&&this.freePointer.row===0}},{key:`canFit`,value:function(e){if(this.locked)return!1;var t=this.texSize,n=this.texRows,r=this.getScale(e).texW;return this.freePointer.x+r>t?this.freePointer.row1&&arguments[1]!==void 0?arguments[1]:{},r=n.forceRedraw,i=r!==void 0&&r,a=n.filterEle,s=a===void 0?function(){return!0}:a,c=n.filterType,l=c===void 0?function(){return!0}:c,u=!1,d=!1,f=o(e),p;try{for(f.s();!(p=f.n()).done;){var m=p.value;if(s(m)){var h=o(this.renderTypes.values()),g;try{var _=function(){var e=g.value,n=e.type;if(l(n)){var r=t.collections.get(e.collection),a=e.getKey(m),o=Array.isArray(a)?a:[a];if(i)o.forEach(function(e){return r.markKeyForGC(e)}),d=!0;else{var s=e.getID?e.getID(m):m.id(),c=t._key(n,s),f=t.typeAndIdToKey.get(c);f!==void 0&&!Sm(o,f)&&(u=!0,t.typeAndIdToKey.delete(c),f.forEach(function(e){return r.markKeyForGC(e)}))}}};for(h.s();!(g=h.n()).done;)_()}catch(e){h.e(e)}finally{h.f()}}}}catch(e){f.e(e)}finally{f.f()}return d&&(this.gc(),u=!1),u}},{key:`gc`,value:function(){var e=o(this.collections.values()),t;try{for(e.s();!(t=e.n()).done;)t.value.gc()}catch(t){e.e(t)}finally{e.f()}}},{key:`getOrCreateAtlas`,value:function(e,t,n,r){var i=this.renderTypes.get(t),a=this.collections.get(i.collection),o=!1,s=a.draw(r,n,function(t){i.drawClipped?(t.save(),t.beginPath(),t.rect(0,0,n.w,n.h),t.clip(),i.drawElement(t,e,n,!0,!0),t.restore()):i.drawElement(t,e,n,!0,!0),o=!0});if(o){var c=i.getID?i.getID(e):e.id(),l=this._key(t,c);this.typeAndIdToKey.has(l)?this.typeAndIdToKey.get(l).push(r):this.typeAndIdToKey.set(l,[r])}return s}},{key:`getAtlasInfo`,value:function(e,t){var n=this,r=this.renderTypes.get(t),i=r.getKey(e);return(Array.isArray(i)?i:[i]).map(function(i){var a=r.getBoundingBox(e,i),o=n.getOrCreateAtlas(e,t,a,i),s=f(o.getOffsets(i),2),c=s[0];return{atlas:o,tex:c,tex1:c,tex2:s[1],bb:a}})}},{key:`getDebugInfo`,value:function(){var e=[],t=o(this.collections),n;try{for(t.s();!(n=t.n()).done;){var r=f(n.value,2),i=r[0],a=r[1].getCounts(),s=a.keyCount,c=a.atlasCount;e.push({type:i,keyCount:s,atlasCount:c})}}catch(e){t.e(e)}finally{t.f()}return e}}])}(),Km=function(){function e(t){r(this,e),this.globalOptions=t,this.atlasSize=t.webglTexSize,this.maxAtlasesPerBatch=t.webglTexPerBatch,this.batchAtlases=[]}return a(e,[{key:`getMaxAtlasesPerBatch`,value:function(){return this.maxAtlasesPerBatch}},{key:`getAtlasSize`,value:function(){return this.atlasSize}},{key:`getIndexArray`,value:function(){return Array.from({length:this.maxAtlasesPerBatch},function(e,t){return t})}},{key:`startBatch`,value:function(){this.batchAtlases=[]}},{key:`getAtlasCount`,value:function(){return this.batchAtlases.length}},{key:`getAtlases`,value:function(){return this.batchAtlases}},{key:`canAddToCurrentBatch`,value:function(e){return this.batchAtlases.length!==this.maxAtlasesPerBatch||this.batchAtlases.includes(e)}},{key:`getAtlasIndexForBatch`,value:function(e){var t=this.batchAtlases.indexOf(e);if(t<0){if(this.batchAtlases.length===this.maxAtlasesPerBatch)throw Error(`cannot add more atlases to batch`);this.batchAtlases.push(e),t=this.batchAtlases.length-1}return t}}])}(),qm=` + float circleSD(vec2 p, float r) { + return distance(vec2(0), p) - r; // signed distance + } +`,Jm=` + float rectangleSD(vec2 p, vec2 b) { + vec2 d = abs(p)-b; + return distance(vec2(0),max(d,0.0)) + min(max(d.x,d.y),0.0); + } +`,Ym=` + float roundRectangleSD(vec2 p, vec2 b, vec4 cr) { + cr.xy = (p.x > 0.0) ? cr.xy : cr.zw; + cr.x = (p.y > 0.0) ? cr.x : cr.y; + vec2 q = abs(p) - b + cr.x; + return min(max(q.x, q.y), 0.0) + distance(vec2(0), max(q, 0.0)) - cr.x; + } +`,Xm=` + float ellipseSD(vec2 p, vec2 ab) { + p = abs( p ); // symmetry + + // find root with Newton solver + vec2 q = ab*(p-ab); + float w = (q.x1.0) ? d : -d; + } +`,Zm={SCREEN:{name:`screen`,screen:!0},PICKING:{name:`picking`,picking:!0}},Qm={IGNORE:1,USE_BB:2},$m=0,eh=1,th=2,nh=3,rh=4,ih=5,ah=6,oh=7,sh=function(){function e(t,n,i){r(this,e),this.r=t,this.gl=n,this.maxInstances=i.webglBatchSize,this.atlasSize=i.webglTexSize,this.bgColor=i.bgColor,this.debug=i.webglDebug,this.batchDebugInfo=[],i.enableWrapping=!0,i.createTextureCanvas=_m,this.atlasManager=new Gm(t,i),this.batchManager=new Km(i),this.simpleShapeOptions=new Map,this.program=this._createShaderProgram(Zm.SCREEN),this.pickingProgram=this._createShaderProgram(Zm.PICKING),this.vao=this._createVAO()}return a(e,[{key:`addAtlasCollection`,value:function(e,t){this.atlasManager.addAtlasCollection(e,t)}},{key:`addTextureAtlasRenderType`,value:function(e,t){this.atlasManager.addRenderType(e,t)}},{key:`addSimpleShapeRenderType`,value:function(e,t){this.simpleShapeOptions.set(e,t)}},{key:`invalidate`,value:function(e){var t=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:{}).type,n=this.atlasManager;return t?n.invalidate(e,{filterType:function(e){return e===t},forceRedraw:!0}):n.invalidate(e)}},{key:`gc`,value:function(){this.atlasManager.gc()}},{key:`_createShaderProgram`,value:function(e){var t=this.gl,n=`#version 300 es + precision highp float; + + uniform mat3 uPanZoomMatrix; + uniform int uAtlasSize; + + // instanced + in vec2 aPosition; // a vertex from the unit square + + in mat3 aTransform; // used to transform verticies, eg into a bounding box + in int aVertType; // the type of thing we are rendering + + // the z-index that is output when using picking mode + in vec4 aIndex; + + // For textures + in int aAtlasId; // which shader unit/atlas to use + in vec4 aTex; // x/y/w/h of texture in atlas + + // for edges + in vec4 aPointAPointB; + in vec4 aPointCPointD; + in vec2 aLineWidth; // also used for node border width + + // simple shapes + in vec4 aCornerRadius; // for round-rectangle [top-right, bottom-right, top-left, bottom-left] + in vec4 aColor; // also used for edges + in vec4 aBorderColor; // aLineWidth is used for border width + + // output values passed to the fragment shader + out vec2 vTexCoord; + out vec4 vColor; + out vec2 vPosition; + // flat values are not interpolated + flat out int vAtlasId; + flat out int vVertType; + flat out vec2 vTopRight; + flat out vec2 vBotLeft; + flat out vec4 vCornerRadius; + flat out vec4 vBorderColor; + flat out vec2 vBorderWidth; + flat out vec4 vIndex; + + void main(void) { + int vid = gl_VertexID; + vec2 position = aPosition; // TODO make this a vec3, simplifies some code below + + if(aVertType == ${$m}) { + float texX = aTex.x; // texture coordinates + float texY = aTex.y; + float texW = aTex.z; + float texH = aTex.w; + + if(vid == 1 || vid == 2 || vid == 4) { + texX += texW; + } + if(vid == 2 || vid == 4 || vid == 5) { + texY += texH; + } + + float d = float(uAtlasSize); + vTexCoord = vec2(texX / d, texY / d); // tex coords must be between 0 and 1 + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + } + else if(aVertType == ${rh} || aVertType == ${oh} + || aVertType == ${ih} || aVertType == ${ah}) { // simple shapes + + // the bounding box is needed by the fragment shader + vBotLeft = (aTransform * vec3(0, 0, 1)).xy; // flat + vTopRight = (aTransform * vec3(1, 1, 1)).xy; // flat + vPosition = (aTransform * vec3(position, 1)).xy; // will be interpolated + + // calculations are done in the fragment shader, just pass these along + vColor = aColor; + vCornerRadius = aCornerRadius; + vBorderColor = aBorderColor; + vBorderWidth = aLineWidth; + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + } + else if(aVertType == ${eh}) { + vec2 source = aPointAPointB.xy; + vec2 target = aPointAPointB.zw; + + // adjust the geometry so that the line is centered on the edge + position.y = position.y - 0.5; + + // stretch the unit square into a long skinny rectangle + vec2 xBasis = target - source; + vec2 yBasis = normalize(vec2(-xBasis.y, xBasis.x)); + vec2 point = source + xBasis * position.x + yBasis * aLineWidth[0] * position.y; + + gl_Position = vec4(uPanZoomMatrix * vec3(point, 1.0), 1.0); + vColor = aColor; + } + else if(aVertType == ${th}) { + vec2 pointA = aPointAPointB.xy; + vec2 pointB = aPointAPointB.zw; + vec2 pointC = aPointCPointD.xy; + vec2 pointD = aPointCPointD.zw; + + // adjust the geometry so that the line is centered on the edge + position.y = position.y - 0.5; + + vec2 p0, p1, p2, pos; + if(position.x == 0.0) { // The left side of the unit square + p0 = pointA; + p1 = pointB; + p2 = pointC; + pos = position; + } else { // The right side of the unit square, use same approach but flip the geometry upside down + p0 = pointD; + p1 = pointC; + p2 = pointB; + pos = vec2(0.0, -position.y); + } + + vec2 p01 = p1 - p0; + vec2 p12 = p2 - p1; + vec2 p21 = p1 - p2; + + // Find the normal vector. + vec2 tangent = normalize(normalize(p12) + normalize(p01)); + vec2 normal = vec2(-tangent.y, tangent.x); + + // Find the vector perpendicular to p0 -> p1. + vec2 p01Norm = normalize(vec2(-p01.y, p01.x)); + + // Determine the bend direction. + float sigma = sign(dot(p01 + p21, normal)); + float width = aLineWidth[0]; + + if(sign(pos.y) == -sigma) { + // This is an intersecting vertex. Adjust the position so that there's no overlap. + vec2 point = 0.5 * width * normal * -sigma / dot(normal, p01Norm); + gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0); + } else { + // This is a non-intersecting vertex. Treat it like a mitre join. + vec2 point = 0.5 * width * normal * sigma * dot(normal, p01Norm); + gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0); + } + + vColor = aColor; + } + else if(aVertType == ${nh} && vid < 3) { + // massage the first triangle into an edge arrow + if(vid == 0) + position = vec2(-0.15, -0.3); + if(vid == 1) + position = vec2( 0.0, 0.0); + if(vid == 2) + position = vec2( 0.15, -0.3); + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + vColor = aColor; + } + else { + gl_Position = vec4(2.0, 0.0, 0.0, 1.0); // discard vertex by putting it outside webgl clip space + } + + vAtlasId = aAtlasId; + vVertType = aVertType; + vIndex = aIndex; + } + `,r=this.batchManager.getIndexArray(),i=gm(t,n,`#version 300 es + precision highp float; + + // declare texture unit for each texture atlas in the batch + ${r.map(function(e){return`uniform sampler2D uTexture${e};`}).join(` + `)} + + uniform vec4 uBGColor; + uniform float uZoom; + + in vec2 vTexCoord; + in vec4 vColor; + in vec2 vPosition; // model coordinates + + flat in int vAtlasId; + flat in vec4 vIndex; + flat in int vVertType; + flat in vec2 vTopRight; + flat in vec2 vBotLeft; + flat in vec4 vCornerRadius; + flat in vec4 vBorderColor; + flat in vec2 vBorderWidth; + + out vec4 outColor; + + ${qm} + ${Jm} + ${Ym} + ${Xm} + + vec4 blend(vec4 top, vec4 bot) { // blend colors with premultiplied alpha + return vec4( + top.rgb + (bot.rgb * (1.0 - top.a)), + top.a + (bot.a * (1.0 - top.a)) + ); + } + + vec4 distInterp(vec4 cA, vec4 cB, float d) { // interpolate color using Signed Distance + // scale to the zoom level so that borders don't look blurry when zoomed in + // note 1.5 is an aribitrary value chosen because it looks good + return mix(cA, cB, 1.0 - smoothstep(0.0, 1.5 / uZoom, abs(d))); + } + + void main(void) { + if(vVertType == ${$m}) { + // look up the texel from the texture unit + ${r.map(function(e){return`if(vAtlasId == ${e}) outColor = texture(uTexture${e}, vTexCoord);`}).join(` + else `)} + } + else if(vVertType == ${nh}) { + // mimics how canvas renderer uses context.globalCompositeOperation = 'destination-out'; + outColor = blend(vColor, uBGColor); + outColor.a = 1.0; // make opaque, masks out line under arrow + } + else if(vVertType == ${rh} && vBorderWidth == vec2(0.0)) { // simple rectangle with no border + outColor = vColor; // unit square is already transformed to the rectangle, nothing else needs to be done + } + else if(vVertType == ${rh} || vVertType == ${oh} + || vVertType == ${ih} || vVertType == ${ah}) { // use SDF + + float outerBorder = vBorderWidth[0]; + float innerBorder = vBorderWidth[1]; + float borderPadding = outerBorder * 2.0; + float w = vTopRight.x - vBotLeft.x - borderPadding; + float h = vTopRight.y - vBotLeft.y - borderPadding; + vec2 b = vec2(w/2.0, h/2.0); // half width, half height + vec2 p = vPosition - vec2(vTopRight.x - b[0] - outerBorder, vTopRight.y - b[1] - outerBorder); // translate to center + + float d; // signed distance + if(vVertType == ${rh}) { + d = rectangleSD(p, b); + } else if(vVertType == ${oh} && w == h) { + d = circleSD(p, b.x); // faster than ellipse + } else if(vVertType == ${oh}) { + d = ellipseSD(p, b); + } else { + d = roundRectangleSD(p, b, vCornerRadius.wzyx); + } + + // use the distance to interpolate a color to smooth the edges of the shape, doesn't need multisampling + // we must smooth colors inwards, because we can't change pixels outside the shape's bounding box + if(d > 0.0) { + if(d > outerBorder) { + discard; + } else { + outColor = distInterp(vBorderColor, vec4(0), d - outerBorder); + } + } else { + if(d > innerBorder) { + vec4 outerColor = outerBorder == 0.0 ? vec4(0) : vBorderColor; + vec4 innerBorderColor = blend(vBorderColor, vColor); + outColor = distInterp(innerBorderColor, outerColor, d); + } + else { + vec4 outerColor; + if(innerBorder == 0.0 && outerBorder == 0.0) { + outerColor = vec4(0); + } else if(innerBorder == 0.0) { + outerColor = vBorderColor; + } else { + outerColor = blend(vBorderColor, vColor); + } + outColor = distInterp(vColor, outerColor, d - innerBorder); + } + } + } + else { + outColor = vColor; + } + + ${e.picking?`if(outColor.a == 0.0) discard; + else outColor = vIndex;`:``} + } + `);i.aPosition=t.getAttribLocation(i,`aPosition`),i.aIndex=t.getAttribLocation(i,`aIndex`),i.aVertType=t.getAttribLocation(i,`aVertType`),i.aTransform=t.getAttribLocation(i,`aTransform`),i.aAtlasId=t.getAttribLocation(i,`aAtlasId`),i.aTex=t.getAttribLocation(i,`aTex`),i.aPointAPointB=t.getAttribLocation(i,`aPointAPointB`),i.aPointCPointD=t.getAttribLocation(i,`aPointCPointD`),i.aLineWidth=t.getAttribLocation(i,`aLineWidth`),i.aColor=t.getAttribLocation(i,`aColor`),i.aCornerRadius=t.getAttribLocation(i,`aCornerRadius`),i.aBorderColor=t.getAttribLocation(i,`aBorderColor`),i.uPanZoomMatrix=t.getUniformLocation(i,`uPanZoomMatrix`),i.uAtlasSize=t.getUniformLocation(i,`uAtlasSize`),i.uBGColor=t.getUniformLocation(i,`uBGColor`),i.uZoom=t.getUniformLocation(i,`uZoom`),i.uTextures=[];for(var a=0;a1&&arguments[1]!==void 0?arguments[1]:Zm.SCREEN;this.panZoomMatrix=e,this.renderTarget=t,this.batchDebugInfo=[],this.wrappedCount=0,this.simpleCount=0,this.startBatch()}},{key:`startBatch`,value:function(){this.instanceCount=0,this.batchManager.startBatch()}},{key:`endFrame`,value:function(){this.endBatch()}},{key:`_isVisible`,value:function(e,t){return e.visible()?t&&t.isVisible?t.isVisible(e):!0:!1}},{key:`drawTexture`,value:function(e,t,n){var r=this.atlasManager,i=this.batchManager,a=r.getRenderTypeOpts(n);if(this._isVisible(e,a)&&!(e.isEdge()&&!this._isValidEdge(e))){if(this.renderTarget.picking&&a.getTexPickingMode){var s=a.getTexPickingMode(e);if(s===Qm.IGNORE)return;if(s==Qm.USE_BB){this.drawPickingRectangle(e,t,n);return}}var c=o(r.getAtlasInfo(e,n)),l;try{for(c.s();!(l=c.n()).done;){var u=l.value,d=u.atlas,p=u.tex1,m=u.tex2;i.canAddToCurrentBatch(d)||this.endBatch();for(var h=i.getAtlasIndexForBatch(d),g=0,_=[[p,!0],[m,!1]];g<_.length;g++){var v=f(_[g],2),y=v[0],b=v[1];if(y.w!=0){var x=this.instanceCount;this.vertTypeBuffer.getView(x)[0]=$m,wm(t,this.indexBuffer.getView(x));var S=this.atlasIdBuffer.getView(x);S[0]=h;var C=this.texBuffer.getView(x);C[0]=y.x,C[1]=y.y,C[2]=y.w,C[3]=y.h;var w=this.transformBuffer.getMatrixView(x);this.setTransformMatrix(e,w,a,u,b),this.instanceCount++,b||this.wrappedCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}}catch(e){c.e(e)}finally{c.f()}}}},{key:`setTransformMatrix`,value:function(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=0;if(n.shapeProps&&n.shapeProps.padding&&(a=e.pstyle(n.shapeProps.padding).pfValue),r){var o=r.bb,s=r.tex1,c=r.tex2,l=s.w/(s.w+c.w);i||(l=1-l);var u=this._getAdjustedBB(o,a,i,l);this._applyTransformMatrix(t,u,n,e)}else{var d=n.getBoundingBox(e),f=this._getAdjustedBB(d,a,!0,1);this._applyTransformMatrix(t,f,n,e)}}},{key:`_applyTransformMatrix`,value:function(e,t,n,r){var i,a;Im(e);var o=n.getRotation?n.getRotation(r):0;if(o!==0){var s=n.getRotationPoint(r),c=s.x,l=s.y;Rm(e,e,[c,l]),zm(e,e,o);var u=n.getRotationOffset(r);i=u.x+(t.xOffset||0),a=u.y+(t.yOffset||0)}else i=t.x1,a=t.y1;Rm(e,e,[i,a]),Bm(e,e,[t.w,t.h])}},{key:`_getAdjustedBB`,value:function(e,t,n,r){var i=e.x1,a=e.y1,o=e.w,s=e.h,c=e.yOffset;t&&(i-=t,a-=t,o+=2*t,s+=2*t);var l=0,u=o*r;return n&&r<1?o=u:!n&&r<1&&(l=o-u,i+=l,o=u),{x1:i,y1:a,w:o,h:s,xOffset:l,yOffset:c}}},{key:`drawPickingRectangle`,value:function(e,t,n){var r=this.atlasManager.getRenderTypeOpts(n),i=this.instanceCount;this.vertTypeBuffer.getView(i)[0]=rh,wm(t,this.indexBuffer.getView(i)),Cm([0,0,0],1,this.colorBuffer.getView(i));var a=this.transformBuffer.getMatrixView(i);this.setTransformMatrix(e,a,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}},{key:`drawNode`,value:function(e,t,n){var r=this.simpleShapeOptions.get(n);if(this._isVisible(e,r)){var i=r.shapeProps,a=this._getVertTypeForShape(e,i.shape);if(a===void 0||r.isSimple&&!r.isSimple(e,this.renderTarget)){this.drawTexture(e,t,n);return}var o=this.instanceCount;if(this.vertTypeBuffer.getView(o)[0]=a,a===ih||a===ah){var s=r.getBoundingBox(e),c=this._getCornerRadius(e,i.radius,s),l=this.cornerRadiusBuffer.getView(o);l[0]=c,l[1]=c,l[2]=c,l[3]=c,a===ah&&(l[0]=0,l[2]=0)}wm(t,this.indexBuffer.getView(o));var u=this.renderTarget.picking?1:n===`node-body`?e.effectiveOpacity():1,d=this.renderTarget.picking?1:e.pstyle(i.opacity).value*u,f=e.pstyle(i.color).value;Cm(f,d,this.colorBuffer.getView(o));var p=this.lineWidthBuffer.getView(o);if(p[0]=0,p[1]=0,i.border){var m=e.pstyle(`border-width`).value;if(m>0){var h=e.pstyle(`border-color`).value;Cm(h,u*e.pstyle(`border-opacity`).value,this.borderColorBuffer.getView(o));var g=e.pstyle(`border-position`).value;if(g===`inside`)p[0]=0,p[1]=-m;else if(g===`outside`)p[0]=m,p[1]=0;else{var _=m/2;p[0]=_,p[1]=-_}}}var v=this.transformBuffer.getMatrixView(o);this.setTransformMatrix(e,v,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}},{key:`_getVertTypeForShape`,value:function(e,t){switch(e.pstyle(t).value){case`rectangle`:return rh;case`ellipse`:return oh;case`roundrectangle`:case`round-rectangle`:return ih;case`bottom-round-rectangle`:return ah;default:return}}},{key:`_getCornerRadius`,value:function(e,t,n){var r=n.w,i=n.h;if(e.pstyle(t).value===`auto`)return Nr(r,i);var a=e.pstyle(t).pfValue,o=r/2,s=i/2;return Math.min(a,s,o)}},{key:`drawEdgeArrow`,value:function(e,t,n){if(e.visible()){var r=e._private.rscratch,i,a,o;if(n===`source`?(i=r.arrowStartX,a=r.arrowStartY,o=r.srcArrowAngle):(i=r.arrowEndX,a=r.arrowEndY,o=r.tgtArrowAngle),!(isNaN(i)||i==null||isNaN(a)||a==null||isNaN(o)||o==null)&&e.pstyle(n+`-arrow-shape`).value!==`none`){var s=e.pstyle(n+`-arrow-color`).value,c=e.pstyle(`opacity`).value*e.pstyle(`line-opacity`).value,l=e.pstyle(`width`).pfValue,u=e.pstyle(`arrow-scale`).value,d=this.r.getArrowWidth(l,u),f=this.instanceCount,p=this.transformBuffer.getMatrixView(f);Im(p),Rm(p,p,[i,a]),Bm(p,p,[d,d]),zm(p,p,o),this.vertTypeBuffer.getView(f)[0]=nh,wm(t,this.indexBuffer.getView(f)),Cm(s,c,this.colorBuffer.getView(f)),this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}},{key:`drawEdgeLine`,value:function(e,t){if(e.visible()){var n=this._getEdgePoints(e);if(n){var r=e.pstyle(`opacity`).value,i=e.pstyle(`line-opacity`).value,a=e.pstyle(`width`).pfValue,o=e.pstyle(`line-color`).value,s=r*i;if(n.length/2+this.instanceCount>this.maxInstances&&this.endBatch(),n.length==4){var c=this.instanceCount;this.vertTypeBuffer.getView(c)[0]=eh,wm(t,this.indexBuffer.getView(c)),Cm(o,s,this.colorBuffer.getView(c));var l=this.lineWidthBuffer.getView(c);l[0]=a;var u=this.pointAPointBBuffer.getView(c);u[0]=n[0],u[1]=n[1],u[2]=n[2],u[3]=n[3],this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}else for(var d=0;d=this.maxInstances&&this.endBatch()}}}}},{key:`_isValidEdge`,value:function(e){var t=e._private.rscratch;return!(t.badLine||t.allpts==null||isNaN(t.allpts[0]))}},{key:`_getEdgePoints`,value:function(e){var t=e._private.rscratch;if(this._isValidEdge(e)){var n=t.allpts;if(n.length==4)return n;var r=this._getNumSegments(e);return this._getCurveSegmentPoints(n,r)}}},{key:`_getNumSegments`,value:function(e){return Math.min(15,this.maxInstances)}},{key:`_getCurveSegmentPoints`,value:function(e,t){if(e.length==4)return e;for(var n=Array((t+1)*2),r=0;r<=t;r++)if(r==0)n[0]=e[0],n[1]=e[1];else if(r==t)n[r*2]=e[e.length-2],n[r*2+1]=e[e.length-1];else{var i=r/t;this._setCurvePoint(e,i,n,r*2)}return n}},{key:`_setCurvePoint`,value:function(e,t,n,r){if(e.length<=2)n[r]=e[0],n[r+1]=e[1];else{for(var i=Array(e.length-2),a=0;a0}},s=function(e){return e.pstyle(`text-events`).strValue===`yes`?Qm.USE_BB:Qm.IGNORE},c=function(e){var t=e.position(),n=t.x,r=t.y,i=e.outerWidth(),a=e.outerHeight();return{w:i,h:a,x1:n-i/2,y1:r-a/2}};n.drawing.addAtlasCollection(`node`,{texRows:e.webglTexRowsNodes}),n.drawing.addAtlasCollection(`label`,{texRows:e.webglTexRows}),n.drawing.addTextureAtlasRenderType(`node-body`,{collection:`node`,getKey:t.getStyleKey,getBoundingBox:t.getElementBox,drawElement:t.drawElement}),n.drawing.addSimpleShapeRenderType(`node-body`,{getBoundingBox:c,isSimple:xm,shapeProps:{shape:`shape`,color:`background-color`,opacity:`background-opacity`,radius:`corner-radius`,border:!0}}),n.drawing.addSimpleShapeRenderType(`node-overlay`,{getBoundingBox:c,isVisible:o(`overlay`),shapeProps:{shape:`overlay-shape`,color:`overlay-color`,opacity:`overlay-opacity`,padding:`overlay-padding`,radius:`overlay-corner-radius`}}),n.drawing.addSimpleShapeRenderType(`node-underlay`,{getBoundingBox:c,isVisible:o(`underlay`),shapeProps:{shape:`underlay-shape`,color:`underlay-color`,opacity:`underlay-opacity`,padding:`underlay-padding`,radius:`underlay-corner-radius`}}),n.drawing.addTextureAtlasRenderType(`label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getLabelKey,null),getBoundingBox:fh(t.getLabelBox,null),drawClipped:!0,drawElement:t.drawLabel,getRotation:i(null),getRotationPoint:t.getLabelRotationPoint,getRotationOffset:t.getLabelRotationOffset,isVisible:a(`label`)}),n.drawing.addTextureAtlasRenderType(`edge-source-label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getSourceLabelKey,`source`),getBoundingBox:fh(t.getSourceLabelBox,`source`),drawClipped:!0,drawElement:t.drawSourceLabel,getRotation:i(`source`),getRotationPoint:t.getSourceLabelRotationPoint,getRotationOffset:t.getSourceLabelRotationOffset,isVisible:a(`source-label`)}),n.drawing.addTextureAtlasRenderType(`edge-target-label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getTargetLabelKey,`target`),getBoundingBox:fh(t.getTargetLabelBox,`target`),drawClipped:!0,drawElement:t.drawTargetLabel,getRotation:i(`target`),getRotationPoint:t.getTargetLabelRotationPoint,getRotationOffset:t.getTargetLabelRotationOffset,isVisible:a(`target-label`)});var l=st(function(){console.log(`garbage collect flag set`),n.data.gc=!0},1e4);n.onUpdateEleCalcs(function(e,t){var r=!1;t&&t.length>0&&(r|=n.drawing.invalidate(t)),r&&l()}),ph(n)};function lh(e){var t=e.cy.container();return pe(t&&t.style&&t.style.backgroundColor||`white`)}function uh(e,t){var n=e._private.rscratch;return Xt(n,`labelWrapCachedLines`,t)||[]}var dh=function(e,t){return function(n){var r=e(n),i=uh(n,t);return i.length>1?i.map(function(e,t){return`${r}_${t}`}):r}},fh=function(e,t){return function(n,r){var i=e(n);if(typeof r==`string`){var a=r.indexOf(`_`);if(a>0){var o=Number(r.substring(a+1)),s=uh(n,t),c=i.h/s.length,l=c*o,u=i.y1+l;return{x1:i.x1,w:i.w,y1:u,h:c,yOffset:l}}}return i}};function ph(e){var t=e.render;e.render=function(n){n||={};var r=e.cy;e.webgl&&(r.zoom()>sp?(mh(e),t.call(e,n)):(hh(e),wh(e,n,Zm.SCREEN)))};var n=e.matchCanvasSize;e.matchCanvasSize=function(t){n.call(e,t),e.pickingFrameBuffer.setFramebufferAttachmentSizes(e.canvasWidth,e.canvasHeight),e.pickingFrameBuffer.needsDraw=!0},e.findNearestElements=function(t,n,r,i){return Sh(e,t,n)};var r=e.invalidateCachedZSortedEles;e.invalidateCachedZSortedEles=function(){r.call(e),e.pickingFrameBuffer.needsDraw=!0};var i=e.notify;e.notify=function(t,n){i.call(e,t,n),t===`viewport`||t===`bounds`?e.pickingFrameBuffer.needsDraw=!0:t===`background`&&e.drawing.invalidate(n,{type:`node-body`})}}function mh(e){var t=e.data.contexts[e.WEBGL];t.clear(t.COLOR_BUFFER_BIT|t.DEPTH_BUFFER_BIT)}function hh(e){var t=function(t){t.save(),t.setTransform(1,0,0,1,0,0),t.clearRect(0,0,e.canvasWidth,e.canvasHeight),t.restore()};t(e.data.contexts[e.NODE]),t(e.data.contexts[e.DRAG])}function gh(e){var t=e.canvasWidth,n=e.canvasHeight,r=vm(e),i=r.pan,a=r.zoom,o=Fm();Rm(o,o,[i.x,i.y]),Bm(o,o,[a,a]);var s=Fm();Vm(s,t,n);var c=Fm();return Lm(c,s,o),c}function _h(e,t){var n=e.canvasWidth,r=e.canvasHeight,i=vm(e),a=i.pan,o=i.zoom;t.setTransform(1,0,0,1,0,0),t.clearRect(0,0,n,r),t.translate(a.x,a.y),t.scale(o,o)}function vh(e,t){e.drawSelectionRectangle(t,function(t){return _h(e,t)})}function yh(e){var t=e.data.contexts[e.NODE];t.save(),_h(e,t),t.strokeStyle=`rgba(0, 0, 0, 0.3)`,t.beginPath(),t.moveTo(-1e3,0),t.lineTo(1e3,0),t.stroke(),t.beginPath(),t.moveTo(0,-1e3),t.lineTo(0,1e3),t.stroke(),t.restore()}function bh(e){var t=function(t,n,r){for(var i=t.atlasManager.getAtlasCollection(n),a=e.data.contexts[e.NODE],o=i.atlases,s=0;s=0&&b.add(S)}return b}function Sh(e,t,n){var r=xh(e,t,n),i=e.getCachedZSortedEles(),a,s,c=o(r),l;try{for(c.s();!(l=c.n()).done;){var u=i[l.value];if(!a&&u.isNode()&&(a=u),!s&&u.isEdge()&&(s=u),a&&s)break}}catch(e){c.e(e)}finally{c.f()}return[a,s].filter(Boolean)}function Ch(e,t,n){var r=e.drawing;t+=1,n.isNode()?(r.drawNode(n,t,`node-underlay`),r.drawNode(n,t,`node-body`),r.drawTexture(n,t,`label`),r.drawNode(n,t,`node-overlay`)):(r.drawEdgeLine(n,t),r.drawEdgeArrow(n,t,`source`),r.drawEdgeArrow(n,t,`target`),r.drawTexture(n,t,`label`),r.drawTexture(n,t,`edge-source-label`),r.drawTexture(n,t,`edge-target-label`))}function wh(e,t,n){var r;e.webglDebug&&(r=performance.now());var i=e.drawing,a=0;if(n.screen&&e.data.canvasNeedsRedraw[e.SELECT_BOX]&&vh(e,t),e.data.canvasNeedsRedraw[e.NODE]||n.picking){var s=e.data.contexts[e.WEBGL];n.screen?(s.clearColor(0,0,0,0),s.enable(s.BLEND),s.blendFunc(s.ONE,s.ONE_MINUS_SRC_ALPHA)):s.disable(s.BLEND),s.clear(s.COLOR_BUFFER_BIT|s.DEPTH_BUFFER_BIT),s.viewport(0,0,s.canvas.width,s.canvas.height);var c=gh(e),l=e.getCachedZSortedEles();if(a=l.length,i.startFrame(c,n),n.screen){for(var u=0;u0&&a>0){f.clearRect(0,0,i,a),f.globalCompositeOperation=`source-over`;var p=this.getCachedZSortedEles();if(e.full)f.translate(-n.x1*c,-n.y1*c),f.scale(c,c),this.drawElements(f,p),f.scale(1/c,1/c),f.translate(n.x1*c,n.y1*c);else{var m=t.pan(),h={x:m.x*c,y:m.y*c};c*=t.zoom(),f.translate(h.x,h.y),f.scale(c,c),this.drawElements(f,p),f.scale(1/c,1/c),f.translate(-h.x,-h.y)}e.bg&&(f.globalCompositeOperation=`destination-over`,f.fillStyle=e.bg,f.rect(0,0,i,a),f.fill())}return d};function Nh(e,t){for(var n=atob(e),r=new ArrayBuffer(n.length),i=new Uint8Array(r),a=0;a`u`?`undefined`:g(OffscreenCanvas))===`undefined`?(n=this.cy.window().document.createElement(`canvas`),n.width=e,n.height=t):n=new OffscreenCanvas(e,t),n},[Wp,Zp,im,om,sm,um,fm,ch,Th,Mh,Ih].forEach(function(e){X($,e)});var Bh=[{type:`layout`,extensions:Yd},{type:`renderer`,extensions:[{name:`null`,impl:Xd},{name:`base`,impl:Qf},{name:`canvas`,impl:Lh}]}],Vh={},Hh={};function Uh(e,t,n){var r=n,i=function(n){zt("Can not register `"+t+"` for `"+e+"` since `"+n+"` already exists in the prototype and can not be overridden")};if(e===`core`){if(sd.prototype[t])return i(t);sd.prototype[t]=n}else if(e===`collection`){if(xu.prototype[t])return i(t);xu.prototype[t]=n}else if(e===`layout`){for(var a=function(e){this.options=e,n.call(this,e),O(this._private)||(this._private={}),this._private.cy=e.cy,this._private.listeners=[],this.createEmitter()},o=a.prototype=Object.create(n.prototype),s=[],c=0;ct}function ft(e,t){return et||a&&o&&c&&!s&&!l||r&&o&&c||!n&&c||!i)return 1;if(!r&&!a&&!l&&e=s?c:c*(n[r]==`desc`?-1:1)}return e.index-t.index}function gt(e,t,n){t=t.length?x(t,function(e){return b(e)?function(t){return te(t,e.length===1?e[0]:e)}:e}):[ge];var r=-1;return t=x(t,h(de)),pt(Ce(e,function(e,n,i){return{criteria:x(t,function(t){return t(e)}),index:++r,value:e}}),function(e,t){return ht(e,t,n)})}var _t=ue(`length`),vt=`\\ud800-\\udfff`,yt=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,bt=`\\ufe0e\\ufe0f`,xt=`[`+vt+`]`,B=`[`+yt+`]`,V=`\\ud83c[\\udffb-\\udfff]`,St=`(?:`+B+`|`+V+`)`,Ct=`[^`+vt+`]`,wt=`(?:\\ud83c[\\udde6-\\uddff]){2}`,Tt=`[\\ud800-\\udbff][\\udc00-\\udfff]`,Et=`\\u200d`,Dt=St+`?`,Ot=`[`+bt+`]?`,kt=`(?:`+Et+`(?:`+[Ct,wt,Tt].join(`|`)+`)`+Ot+Dt+`)*`,At=Ot+Dt+kt,jt=`(?:`+[Ct+B+`?`,B,wt,Tt,xt].join(`|`)+`)`,Mt=RegExp(V+`(?=`+V+`)|`+jt+At,`g`);function Nt(e){for(var t=Mt.lastIndex=0;Mt.test(e);)++t;return t}function Pt(e){return $e(e)?Nt(e):_t(e)}function Ft(e,t){return Me(e,t,function(t,n){return ae(e,n)})}var H=We(function(e,t){return e==null?{}:Ft(e,t)}),It=Math.ceil,Lt=Math.max;function Rt(e,t,n,r){for(var i=-1,a=Lt(It((t-e)/(n||1)),0),o=Array(a);a--;)o[r?a:++i]=e,e+=n;return o}function zt(e){return function(t,n,r){return r&&typeof r!=`number`&&Pe(t,n,r)&&(n=r=void 0),t=Fe(t),n===void 0?(n=t,t=0):n=Fe(n),r=r===void 0?t1&&Pe(e,t[0],t[1])?t=[]:n>2&&Pe(t[0],t[1],t[2])&&(t=[t[0]]),gt(e,d(t,1),[])}),Ut=0;function G(e){var t=++Ut;return m(e)+t}function Wt(e,t,n){for(var r=-1,i=e.length,a=t.length,o={};++r0;--s)if(o=t[s].dequeue(),o){r=r.concat(K(e,t,n,o,!0));break}}}return r}function K(e,t,n,r,i){var a=i?[]:void 0;return y(e.inEdges(r.v),function(r){var o=e.edge(r),s=e.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,q(t,n,s)}),y(e.outEdges(r.v),function(r){var i=e.edge(r),a=r.w,o=e.node(a);o.in-=i,q(t,n,o)}),e.removeNode(r.v),a}function Qt(e,t){var n=new M,r=0,i=0;y(e.nodes(),function(e){n.setNode(e,{v:e,in:0,out:0})}),y(e.edges(),function(e){var a=n.edge(e.v,e.w)||0,o=t(e),s=a+o;n.setEdge(e.v,e.w,s),i=Math.max(i,n.node(e.v).out+=o),r=Math.max(r,n.node(e.w).in+=o)});var a=U(i+r+3).map(function(){return new Kt}),o=r+1;return y(n.nodes(),function(e){q(a,o,n.node(e))}),{graph:n,buckets:a,zeroIdx:o}}function q(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}function $t(e){var t=e.graph().acyclicer===`greedy`?Xt(e,n(e)):en(e);y(t,function(t){var n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,G(`rev`))});function n(e){return function(t){return e.edge(t).weight}}}function en(e){var t=[],n={},r={};function i(a){Object.prototype.hasOwnProperty.call(r,a)||(r[a]=!0,n[a]=!0,y(e.outEdges(a),function(e){Object.prototype.hasOwnProperty.call(n,e.w)?t.push(e):i(e.w)}),delete n[a])}return y(e.nodes(),i),t}function tn(e){y(e.edges(),function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}})}function J(e,t,n,r){var i;do i=G(r);while(e.hasNode(i));return n.dummy=t,e.setNode(i,n),i}function nn(e){var t=new M().setGraph(e.graph());return y(e.nodes(),function(n){t.setNode(n,e.node(n))}),y(e.edges(),function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},i=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})}),t}function rn(e){var t=new M({multigraph:e.isMultigraph()}).setGraph(e.graph());return y(e.nodes(),function(n){e.children(n).length||t.setNode(n,e.node(n))}),y(e.edges(),function(n){t.setEdge(n,e.edge(n))}),t}function an(e,t){var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2;if(!i&&!a)throw Error(`Not possible to find intersection inside of the rectangle`);var c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=s*i/a,l=s):(i<0&&(o=-o),c=o,l=o*a/i),{x:n+c,y:r+l}}function Y(e){var t=k(U(ln(e)+1),function(){return[]});return y(e.nodes(),function(n){var r=e.node(n),i=r.rank;w(i)||(t[i][r.order]=n)}),t}function on(e){var t=R(k(e.nodes(),function(t){return e.node(t).rank}));y(e.nodes(),function(n){var r=e.node(n);je(r,`rank`)&&(r.rank-=t)})}function sn(e){var t=R(k(e.nodes(),function(t){return e.node(t).rank})),n=[];y(e.nodes(),function(r){var i=e.node(r).rank-t;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=e.graph().nodeRankFactor;y(n,function(t,n){w(t)&&n%i!==0?--r:r&&y(t,function(t){e.node(t).rank+=r})})}function cn(e,t,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),J(e,`border`,i,t)}function ln(e){return I(k(e.nodes(),function(t){var n=e.node(t).rank;if(!w(n))return n}))}function un(e,t){var n={lhs:[],rhs:[]};return y(e,function(e){t(e)?n.lhs.push(e):n.rhs.push(e)}),n}function dn(e,t){var n=rt();try{return t()}finally{console.log(e+` time: `+(rt()-n)+`ms`)}}function fn(e,t){return t()}function pn(e){function t(n){var r=e.children(n),i=e.node(n);if(r.length&&y(r,t),Object.prototype.hasOwnProperty.call(i,`minRank`)){i.borderLeft=[],i.borderRight=[];for(var a=i.minRank,o=i.maxRank+1;ao.lim&&(s=o,c=!0),z(C(t.edges(),function(t){return c===Gn(e,e.node(t.v),s)&&c!==Gn(e,e.node(t.w),s)}),function(e){return X(t,e)})}function Hn(e,t,n,r){var i=n.v,a=n.w;e.removeEdge(i,a),e.setEdge(r.v,r.w,{}),$(e),In(e,t),Un(e,t)}function Un(e,t){var n=Fn(e,A(e.nodes(),function(e){return!t.node(e).parent}));n=n.slice(1),y(n,function(n){var r=e.node(n).parent,i=t.edge(n,r),a=!1;i||(i=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?i.minlen:-i.minlen)})}function Wn(e,t,n){return e.hasEdge(t,n)}function Gn(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}function Kn(e){switch(e.graph().ranker){case`network-simplex`:Yn(e);break;case`tight-tree`:Jn(e);break;case`longest-path`:qn(e);break;default:Yn(e)}}var qn=En;function Jn(e){En(e),Dn(e)}function Yn(e){Q(e)}function Xn(e){var t=J(e,`root`,{},`_root`),n=Qn(e),r=I(v(n))-1,i=2*r+1;e.graph().nestingRoot=t,y(e.edges(),function(t){e.edge(t).minlen*=i});var a=$n(e)+1;y(e.children(),function(o){Zn(e,t,i,a,r,n,o)}),e.graph().nodeRankFactor=i}function Zn(e,t,n,r,i,a,o){var s=e.children(o);if(!s.length){o!==t&&e.setEdge(t,o,{weight:0,minlen:n});return}var c=cn(e,`_bt`),l=cn(e,`_bb`),u=e.node(o);e.setParent(c,o),u.borderTop=c,e.setParent(l,o),u.borderBottom=l,y(s,function(s){Zn(e,t,n,r,i,a,s);var u=e.node(s),d=u.borderTop?u.borderTop:s,f=u.borderBottom?u.borderBottom:s,p=u.borderTop?r:2*r,m=d===f?i-a[o]+1:1;e.setEdge(c,d,{weight:p,minlen:m,nestingEdge:!0}),e.setEdge(f,l,{weight:p,minlen:m,nestingEdge:!0})}),e.parent(o)||e.setEdge(t,c,{weight:0,minlen:i+a[o]})}function Qn(e){var t={};function n(r,i){var a=e.children(r);a&&a.length&&y(a,function(e){n(e,i+1)}),t[r]=i}return y(e.children(),function(e){n(e,1)}),t}function $n(e){return S(e.edges(),function(t,n){return t+e.edge(n).weight},0)}function er(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,y(e.edges(),function(t){e.edge(t).nestingEdge&&e.removeEdge(t)})}function tr(e,t,n){var r={},i;y(n,function(n){for(var a=e.parent(n),o,s;a;){if(o=e.parent(a),o?(s=r[o],r[o]=a):(s=i,i=a),s&&s!==a){t.setEdge(s,a);return}a=o}})}function nr(e,t,n){var r=rr(e),i=new M({compound:!0}).setGraph({root:r}).setDefaultNodeLabel(function(t){return e.node(t)});return y(e.nodes(),function(a){var o=e.node(a),s=e.parent(a);(o.rank===t||o.minRank<=t&&t<=o.maxRank)&&(i.setNode(a),i.setParent(a,s||r),y(e[n](a),function(t){var n=t.v===a?t.w:t.v,r=i.edge(n,a),o=w(r)?0:r.weight;i.setEdge(n,a,{weight:e.edge(t).weight+o})}),Object.prototype.hasOwnProperty.call(o,`minRank`)&&i.setNode(a,{borderLeft:o.borderLeft[t],borderRight:o.borderRight[t]}))}),i}function rr(e){for(var t;e.hasNode(t=G(`_root`)););return t}function ir(e,t){for(var n=0,r=1;r0;)t%2&&(n+=s[t+1]),t=t-1>>1,s[t]+=e.weight;c+=e.weight*n})),c}function or(e){var t={},n=C(e.nodes(),function(t){return!e.children(t).length}),r=I(k(n,function(t){return e.node(t).rank})),i=k(U(r+1),function(){return[]});function a(n){je(t,n)||(t[n]=!0,i[e.node(n).rank].push(n),y(e.successors(n),a))}var o=W(n,function(t){return e.node(t).rank});return y(o,a),i}function sr(e,t){return k(t,function(t){var n=e.inEdges(t);if(n.length){var r=S(n,function(t,n){var r=e.edge(n),i=e.node(n.v);return{sum:t.sum+r.weight*i.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}})}function cr(e,t){var n={};return y(e,function(e,t){var r=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};w(e.barycenter)||(r.barycenter=e.barycenter,r.weight=e.weight)}),y(t.edges(),function(e){var t=n[e.v],r=n[e.w];!w(t)&&!w(r)&&(r.indegree++,t.out.push(n[e.w]))}),lr(C(n,function(e){return!e.indegree}))}function lr(e){var t=[];function n(e){return function(t){t.merged||(w(t.barycenter)||w(e.barycenter)||t.barycenter>=e.barycenter)&&ur(e,t)}}function r(t){return function(n){n.in.push(t),--n.indegree===0&&e.push(n)}}for(;e.length;){var i=e.pop();t.push(i),y(i.in.reverse(),n(i)),y(i.out,r(i))}return k(C(t,function(e){return!e.merged}),function(e){return H(e,[`vs`,`i`,`barycenter`,`weight`])})}function ur(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}function dr(e,t){var n=un(e,function(e){return Object.prototype.hasOwnProperty.call(e,`barycenter`)}),r=n.lhs,i=W(n.rhs,function(e){return-e.i}),a=[],o=0,s=0,c=0;r.sort(pr(!!t)),c=fr(a,i,c),y(r,function(e){c+=e.vs.length,a.push(e.vs),o+=e.barycenter*e.weight,s+=e.weight,c=fr(a,i,c)});var l={vs:O(a)};return s&&(l.barycenter=o/s,l.weight=s),l}function fr(e,t,n){for(var r;t.length&&(r=j(t)).i<=n;)t.pop(),e.push(r.vs),n++;return n}function pr(e){return function(t,n){return t.barycentern.barycenter?1:e?n.i-t.i:t.i-n.i}}function mr(e,t,n,r){var i=e.children(t),a=e.node(t),o=a?a.borderLeft:void 0,s=a?a.borderRight:void 0,c={};o&&(i=C(i,function(e){return e!==o&&e!==s}));var l=sr(e,i);y(l,function(t){if(e.children(t.v).length){var i=mr(e,t.v,n,r);c[t.v]=i,Object.prototype.hasOwnProperty.call(i,`barycenter`)&&gr(t,i)}});var u=cr(l,n);hr(u,c);var d=dr(u,r);if(o&&(d.vs=O([o,d.vs,s]),e.predecessors(o).length)){var f=e.node(e.predecessors(o)[0]),p=e.node(e.predecessors(s)[0]);Object.prototype.hasOwnProperty.call(d,`barycenter`)||(d.barycenter=0,d.weight=0),d.barycenter=(d.barycenter*d.weight+f.order+p.order)/(d.weight+2),d.weight+=2}return d}function hr(e,t){y(e,function(e){e.vs=O(e.vs.map(function(e){return t[e]?t[e].vs:e}))})}function gr(e,t){w(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}function _r(e){var t=ln(e),n=vr(e,U(1,t+1),`inEdges`),r=vr(e,U(t-1,-1,-1),`outEdges`),i=or(e);br(e,i);for(var a=1/0,o,s=0,c=0;c<4;++s,++c){yr(s%2?n:r,s%4>=2),i=Y(e);var l=ir(e,i);lo||s>t[c].lim));for(l=c,c=r;(c=e.parent(c))!==l;)a.push(c);return{path:i.concat(a.reverse()),lca:l}}function Cr(e){var t={},n=0;function r(i){var a=n;y(e.children(i),r),t[i]={low:a,lim:n++}}return y(e.children(),r),t}function wr(e,t){var n={};function r(t,r){var i=0,a=0,o=t.length,s=j(r);return y(r,function(t,c){var l=Er(e,t),u=l?e.node(l).order:o;(l||t===s)&&(y(r.slice(a,c+1),function(t){y(e.predecessors(t),function(r){var a=e.node(r),o=a.order;(oo)&&Dr(n,t,s)})})}function i(t,n){var i=-1,a,o=0;return y(n,function(s,c){if(e.node(s).dummy===`border`){var l=e.predecessors(s);l.length&&(a=e.node(l[0]).order,r(n,o,c,i,a),o=c,i=a)}r(n,o,n.length,a,t.length)}),n}return S(t,i),n}function Er(e,t){if(e.node(t).dummy)return A(e.predecessors(t),function(t){return e.node(t).dummy})}function Dr(e,t,n){if(t>n){var r=t;t=n,n=r}Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,configurable:!0,value:{},writable:!0});var i=e[t];Object.defineProperty(i,n,{enumerable:!0,configurable:!0,value:!0,writable:!0})}function Or(e,t,n){if(t>n){var r=t;t=n,n=r}return!!e[t]&&Object.prototype.hasOwnProperty.call(e[t],n)}function kr(e,t,n,r){var i={},a={},o={};return y(t,function(e){y(e,function(e,t){i[e]=e,a[e]=e,o[e]=t})}),y(t,function(e){var t=-1;y(e,function(e){var s=r(e);if(s.length){s=W(s,function(e){return o[e]});for(var c=(s.length-1)/2,l=Math.floor(c),u=Math.ceil(c);l<=u;++l){var d=s[l];a[e]===e&&t{var t=n(` buildLayoutGraph`,()=>Zr(e));n(` runLayout`,()=>Vr(t,n)),n(` updateInputGraph`,()=>Hr(e,t))})}function Vr(e,t){t(` makeSpaceForEdgeLabels`,()=>Qr(e)),t(` removeSelfEdges`,()=>si(e)),t(` acyclic`,()=>$t(e)),t(` nestingGraph.run`,()=>Xn(e)),t(` rank`,()=>Kn(rn(e))),t(` injectEdgeLabelProxies`,()=>$r(e)),t(` removeEmptyRanks`,()=>sn(e)),t(` nestingGraph.cleanup`,()=>er(e)),t(` normalizeRanks`,()=>on(e)),t(` assignRankMinMax`,()=>ei(e)),t(` removeEdgeLabelProxies`,()=>ti(e)),t(` normalize.run`,()=>Cn(e)),t(` parentDummyChains`,()=>xr(e)),t(` addBorderSegments`,()=>pn(e)),t(` order`,()=>_r(e)),t(` insertSelfEdges`,()=>ci(e)),t(` adjustCoordinateSystem`,()=>hn(e)),t(` position`,()=>Rr(e)),t(` positionSelfEdges`,()=>li(e)),t(` removeBorderNodes`,()=>oi(e)),t(` normalize.undo`,()=>Tn(e)),t(` fixupEdgeLabelCoords`,()=>ii(e)),t(` undoCoordinateSystem`,()=>gn(e)),t(` translateGraph`,()=>ni(e)),t(` assignNodeIntersects`,()=>ri(e)),t(` reversePoints`,()=>ai(e)),t(` acyclic.undo`,()=>tn(e))}function Hr(e,t){y(e.nodes(),function(n){var r=e.node(n),i=t.node(n);r&&(r.x=i.x,r.y=i.y,t.children(n).length&&(r.width=i.width,r.height=i.height))}),y(e.edges(),function(n){var r=e.edge(n),i=t.edge(n);r.points=i.points,Object.prototype.hasOwnProperty.call(i,`x`)&&(r.x=i.x,r.y=i.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}var Ur=[`nodesep`,`edgesep`,`ranksep`,`marginx`,`marginy`],Wr={ranksep:50,edgesep:20,nodesep:50,rankdir:`tb`},Gr=[`acyclicer`,`ranker`,`rankdir`,`align`],Kr=[`width`,`height`],qr={width:0,height:0},Jr=[`minlen`,`weight`,`width`,`height`,`labeloffset`],Yr={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:`r`},Xr=[`labelpos`];function Zr(e){var t=new M({multigraph:!0,compound:!0}),n=di(e.graph());return t.setGraph(L({},Wr,ui(n,Ur),H(n,Gr))),y(e.nodes(),function(n){var r=di(e.node(n));t.setNode(n,Te(ui(r,Kr),qr)),t.setParent(n,e.parent(n))}),y(e.edges(),function(n){var r=di(e.edge(n));t.setEdge(n,L({},Yr,ui(r,Jr),H(r,Xr)))}),t}function Qr(e){var t=e.graph();t.ranksep/=2,y(e.edges(),function(n){var r=e.edge(n);r.minlen*=2,r.labelpos.toLowerCase()!==`c`&&(t.rankdir===`TB`||t.rankdir===`BT`?r.width+=r.labeloffset:r.height+=r.labeloffset)})}function $r(e){y(e.edges(),function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v);J(e,`edge-proxy`,{rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t},`_ep`)}})}function ei(e){var t=0;y(e.nodes(),function(n){var r=e.node(n);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=I(t,r.maxRank))}),e.graph().maxRank=t}function ti(e){y(e.nodes(),function(t){var n=e.node(t);n.dummy===`edge-proxy`&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))})}function ni(e){var t=1/0,n=0,r=1/0,i=0,a=e.graph(),o=a.marginx||0,s=a.marginy||0;function c(e){var a=e.x,o=e.y,s=e.width,c=e.height;t=Math.min(t,a-s/2),n=Math.max(n,a+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}y(e.nodes(),function(t){c(e.node(t))}),y(e.edges(),function(t){var n=e.edge(t);Object.prototype.hasOwnProperty.call(n,`x`)&&c(n)}),t-=o,r-=s,y(e.nodes(),function(n){var i=e.node(n);i.x-=t,i.y-=r}),y(e.edges(),function(n){var i=e.edge(n);y(i.points,function(e){e.x-=t,e.y-=r}),Object.prototype.hasOwnProperty.call(i,`x`)&&(i.x-=t),Object.prototype.hasOwnProperty.call(i,`y`)&&(i.y-=r)}),a.width=n-t+o,a.height=i-r+s}function ri(e){y(e.edges(),function(t){var n=e.edge(t),r=e.node(t.v),i=e.node(t.w),a,o;n.points?(a=n.points[0],o=n.points[n.points.length-1]):(n.points=[],a=i,o=r),n.points.unshift(an(r,a)),n.points.push(an(i,o))})}function ii(e){y(e.edges(),function(t){var n=e.edge(t);if(Object.prototype.hasOwnProperty.call(n,`x`))switch((n.labelpos===`l`||n.labelpos===`r`)&&(n.width-=n.labeloffset),n.labelpos){case`l`:n.x-=n.width/2+n.labeloffset;break;case`r`:n.x+=n.width/2+n.labeloffset}})}function ai(e){y(e.edges(),function(t){var n=e.edge(t);n.reversed&&n.points.reverse()})}function oi(e){y(e.nodes(),function(t){if(e.children(t).length){var n=e.node(t),r=e.node(n.borderTop),i=e.node(n.borderBottom),a=e.node(j(n.borderLeft)),o=e.node(j(n.borderRight));n.width=Math.abs(o.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),y(e.nodes(),function(t){e.node(t).dummy===`border`&&e.removeNode(t)})}function si(e){y(e.edges(),function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||=[],n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}function ci(e){var t=Y(e);y(t,function(t){var n=0;y(t,function(t,r){var i=e.node(t);i.order=r+n,y(i.selfEdges,function(t){J(e,`selfedge`,{width:t.label.width,height:t.label.height,rank:i.rank,order:r+ ++n,e:t.e,label:t.label},`_se`)}),delete i.selfEdges})})}function li(e){y(e.nodes(),function(t){var n=e.node(t);if(n.dummy===`selfedge`){var r=e.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}})}function ui(e,t){return P(H(e,t),Number)}function di(e){var t={};return y(e,function(e,n){t[n.toLowerCase()]=e}),t}var fi=t((e,t,n)=>Math.max(t,Math.min(n,e)),`clamp`),pi=t((e=`TB`)=>{switch(e){case`BT`:return`bottom`;case`LR`:return`right`;case`RL`:return`left`;default:return`top`}},`getDefaultSelfLoopSide`),mi=t(e=>e===`flowchart`||e===`flowchart-v2`||e===`stateDiagram`||e===`er`||e===`classDiagram`,`shouldMergeSelfLoopSegments`),hi=[`x`,`y`,`width`,`height`,`labelBBox`,`intersect`,`calcIntersect`,`diff`,`clusterNode`],gi=t((e,t,n,r,i)=>{let a=[],o=new Set;if(n.forEach(({start:e,end:t})=>{e!==r&&o.add(e),t!==r&&o.add(t)}),o.forEach(t=>{let n=e.node(t);typeof n?.x==`number`&&typeof n?.y==`number`&&a.push(n)}),a.length===0&&n.forEach(({edge:e})=>{(e.points??[]).forEach(e=>{typeof e?.x==`number`&&typeof e?.y==`number`&&a.push(e)})}),a.length===0)return pi(i);let s=a.reduce((e,t)=>({x:e.x+t.x/a.length,y:e.y+t.y/a.length}),{x:0,y:0}),c=s.x-t.x,l=s.y-t.y;return Math.abs(c)>Math.abs(l)?c>0?`right`:`left`:Math.abs(l)>0?l>0?`bottom`:`top`:pi(i)},`getSelfLoopSide`),_i=t((e,t=`top`,n=0,r=0)=>{let i=e.x,a=e.y-n,o=e.width/2,s=e.height/2,c=Math.max(36,Math.min(100,e.width*.8)),l=fi(Math.max(r,e.width*.35),36,c),u=fi(Math.min(e.width,e.height)*.45,24,48);switch(t){case`bottom`:{let e=a+s;return[{x:i-l/2,y:e},{x:i-l/2,y:e+u},{x:i+l/2,y:e+u},{x:i+l/2,y:e}]}case`right`:{let e=i+o;return[{x:e,y:a-l/2},{x:e+u,y:a-l/2},{x:e+u,y:a+l/2},{x:e,y:a+l/2}]}case`left`:{let e=i-o;return[{x:e,y:a-l/2},{x:e-u,y:a-l/2},{x:e-u,y:a+l/2},{x:e,y:a+l/2}]}default:{let e=a-s;return[{x:i-l/2,y:e},{x:i-l/2,y:e-u},{x:i+l/2,y:e-u},{x:i+l/2,y:e}]}}},`getSelfLoopPoints`),vi=t((e,t,n=`top`,r=0,i={})=>{let a=e.x,o=e.y-r,s=i.width??0,c=i.height??0;switch(n){case`bottom`:return{x:a,y:Math.max(...t.map(e=>e.y))+c/2+4};case`right`:return{x:Math.max(...t.map(e=>e.x))+s/2+4,y:o};case`left`:return{x:Math.min(...t.map(e=>e.x))-s/2-4,y:o};default:return{x:a,y:Math.min(...t.map(e=>e.y))-c/2-4}}},`getSelfLoopLabelPosition`),yi=t((e,t=0,{mergeSelfLoops:n=!0}={})=>{let r=new Map,i=[],a=e.graph()?.rankdir;return e.edges().forEach(t=>{let a=e.edge(t);if(n&&a.selfLoop){let e=a.selfLoop.id;r.has(e)||r.set(e,[]),r.get(e).push({edge:a,start:t.v,end:t.w})}else i.push({edge:a,start:t.v,end:t.w})}),r.forEach(n=>{if(n.length!==3){n.forEach(e=>i.push(e));return}n.sort((e,t)=>e.edge.selfLoop.order-t.edge.selfLoop.order);let[r,o,s]=n,c=r.edge.originalEdge??o.edge.originalEdge??s.edge.originalEdge??o.edge,l=e.node(c.start);if(!l){n.forEach(e=>i.push(e));return}let u={width:o.edge.width,height:o.edge.height},d=gi(e,l,n,c.start,a),f=_i(l,d,t,u.width??0),p=vi(l,f,d,t,u),m={...o.edge,...c,id:c.id,points:f,start:c.start,end:c.end,x:p.x,y:p.y,width:u.width,height:u.height,labelStyle:o.edge.labelStyle,fromCluster:r.edge.fromCluster??o.edge.fromCluster??s.edge.fromCluster,toCluster:r.edge.toCluster??o.edge.toCluster??s.edge.toCluster};delete m.selfLoop,delete m.originalEdge,i.push({edge:m,start:m.start,end:m.end})}),i},`getEdgesToRender`),bi=t(async({element:n,graph:a,diagramType:s,id:c,parentCluster:l,siteConfig:d})=>{let f=a.graph().rankdir;e.trace(`Dir in recursive render - dir:`,f);let{clusters:p,edgePaths:m,edgeLabels:h,nodes:g,rootGroups:ee}=ze(n,{edgePathsClass:`edgePaths`});a.nodes()?e.info(`Recursive render XXX`,a.nodes()):e.info(`No nodes found for`,a),a.edges().length>0&&e.info(`Recursive edges`,a.edge(a.edges()[0]));let _=mi(s);await Promise.all(a.nodes().map(async function(t){let n=a.node(t);if(l!==void 0){let n=JSON.parse(JSON.stringify(l.clusterData));e.trace(`Setting data for parent cluster XXX + Node.id = `,t,` + data=`,n.height,` +Parent cluster`,l.height),a.setNode(l.id,n),a.parent(t)||(e.trace(`Setting parent`,t,l.id),a.setParent(t,l.id,n))}if(e.info(`(Insert) Node XXX`+t+`: `+JSON.stringify(a.node(t))),n?.clusterNode){e.info(`Cluster identified XBX`,t,n.width,a.node(t));let{ranksep:o,nodesep:l}=a.graph();n.graph.setGraph({...n.graph.graph(),ranksep:o+25,nodesep:l});let u=await Di({element:g,graph:n.graph,diagramType:s,id:c,parentCluster:a.node(t),siteConfig:d}),f=u.elem;r(n,f),n.diff=u.diff||0,e.info(`New compound node after recursive render XAX`,t,`width`,n.width,`height`,n.height),i(f,n)}else a.children(t).length>0?(e.trace(`Cluster - the non recursive path XBX`,t,n.id,n,n.width,`Graph:`,a),e.trace(Be(n.id,a)),N.set(n.id,{id:Be(n.id,a),node:n})):(e.trace(`Node - the non recursive path XAX`,t,g,a.node(t),f),await He(g,a.node(t),{config:d,dir:f}))})),await t(async()=>{let t=a.edges().map(async function(t){let n=a.edge(t.v,t.w,t.name);if(e.info(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(t)),e.info(`Edge `+t.v+` -> `+t.w+`: `,t,` `,JSON.stringify(a.edge(t))),e.info(`Fix`,N,`ids:`,t.v,t.w,`Translating: `,N.get(t.v),N.get(t.w)),_&&n.selfLoop){if(n.selfLoop.order!==1)return;let e={...n.originalEdge,...n,id:n.selfLoop.id,startLabelLeft:n.originalEdge?.startLabelLeft??n.startLabelLeft,startLabelRight:n.originalEdge?.startLabelRight??n.startLabelRight,endLabelLeft:n.originalEdge?.endLabelLeft??n.endLabelLeft,endLabelRight:n.originalEdge?.endLabelRight??n.endLabelRight};await u(h,e),n.width=e.width,n.height=e.height,n.labelStyle=e.labelStyle;return}await u(h,n)});await Promise.all(t)},`processEdges`)();let{subGraphTitleTotalMargin:te}=o(d);return{elem:ee,graph:a,groups:{clusters:p,edgePaths:m,edgeLabels:h,nodes:g,rootGroups:ee},diagramType:s,id:c,mergeSelfLoops:_,subGraphTitleTotalMargin:te}},`measureDagreGraph`),xi=t(t=>{e.info(`############################################# XXX`),e.info(`### Layout ### XXX`),e.info(`############################################# XXX`),Br(t)},`runDagreGraphLayout`),Si=t((e,t,n)=>{let r=e.node(t);if(!r)return;let i={...r};return r?.clusterNode?i.y=(r.y??0)+n:e.children(t).length>0?i.height=(r.height??0)+n:i.y=(r.y??0)+n/2,i},`normalizeDagreNode`),Ci=t((e,t)=>{hi.forEach(n=>{t[n]!==void 0&&(e[n]=t[n])})},`applyDagreNodeLayout`),wi=t((e,t,n,r)=>({...e,start:e.start??t,end:e.end??n,points:(e.points??[]).map(e=>({...e,y:typeof e.y==`number`?e.y+r:e.y}))}),`normalizeDagreEdge`),Ti=t((e,t)=>{let{graph:n,mergeSelfLoops:r,subGraphTitleTotalMargin:i=0}=t,a=new Map(e.nodes.map(e=>[e.id,e]));Re(n).forEach(e=>{let t=Si(n,e,i);if(!t)return;Ci(n.node(e),t);let r=a.get(e);r&&Ci(r,t)});let o=i/2;return e.edges=yi(n,o,{mergeSelfLoops:r}).map(({edge:e,start:t,end:n})=>wi(e,t,n,o)),e},`applyDagreLayoutResult`),Ei=t(async({elem:t,graph:n,groups:{clusters:r,edgePaths:i},diagramType:o,id:u,mergeSelfLoops:d,subGraphTitleTotalMargin:f})=>{let p=0;await Promise.all(Re(n).map(async function(t){let i=n.node(t);if(e.info(`Position XBX => `+t+`: (`+i.x,`,`+i.y,`) width: `,i.width,` height: `,i.height),i?.clusterNode)i.y+=f,e.info(`A tainted cluster node XBX1`,t,i.id,i.width,i.height,i.x,i.y,n.parent(t)),N.get(i.id).node=i,a(i);else if(n.children(t).length>0){e.info(`A pure cluster node XBX1`,t,i.id,i.x,i.y,i.width,i.height,n.parent(t)),i.height+=f,n.node(i.parentId);let a=i?.padding/2||0,o=i?.labelBBox?.height||0,s=o-a||0;e.debug(`OffsetY`,s,`labelHeight`,o,`halfPadding`,a),await c(r,i),N.get(i.id).node=i}else{let t=n.node(i.parentId);i.y+=f/2,e.info(`A regular node XBX1 - using the padding`,i.id,`parent`,i.parentId,i.width,i.height,i.x,i.y,`offsetY`,i.offsetY,`parent`,t,t?.offsetY,i),a(i)}}));let m=f/2;return yi(n,m,{mergeSelfLoops:d}).forEach(function({edge:t,start:r,end:a}){e.info(`Edge `+r+` -> `+a+`: `+JSON.stringify(t),t),t.points.forEach(e=>e.y+=m);let c=n.node(r),d=n.node(a),f=l(i,t,N,o,c,d,u);s(t,f)}),n.nodes().forEach(function(t){let r=n.node(t);e.info(t,r.type,r.diff),r.isGroup&&(p=r.diff)}),e.warn(`Returning from recursive render XAX`,t,p),{elem:t,diff:p}},`paintDagreLayoutCore`),Di=t(async e=>{let t=await bi(e);return xi(t.graph),await Ei(t)},`renderDagreSubgraph`),Oi=t(t=>{let n=new M({multigraph:!0,compound:!0}).setGraph({rankdir:t.direction,nodesep:t.config?.nodeSpacing||t.nodeSpacing||t.config?.flowchart?.nodeSpacing,ranksep:t.config?.rankSpacing||t.rankSpacing||t.config?.flowchart?.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});return t.nodes.forEach(e=>{n.setNode(e.id,{...e}),e.parentId&&n.setParent(e.id,e.parentId)}),e.debug(`Edges:`,t.edges),t.edges.forEach(e=>{if(e.start===e.end){let t=e.start,r=t+`---`+t+`---1`,i=t+`---`+t+`---2`,a=n.node(t);n.setNode(r,{domId:r,id:r,parentId:a.parentId,labelStyle:``,label:``,padding:0,shape:`labelRect`,style:``,width:10,height:10}),n.setParent(r,a.parentId),n.setNode(i,{domId:i,id:i,parentId:a.parentId,labelStyle:``,padding:0,shape:`labelRect`,label:``,style:``,width:10,height:10}),n.setParent(i,a.parentId);let o=structuredClone(e),s=structuredClone(e),c=structuredClone(e),l=structuredClone(e);s.originalEdge=o,s.selfLoop={id:o.id,order:0},c.originalEdge=o,c.selfLoop={id:o.id,order:1},l.originalEdge=o,l.selfLoop={id:o.id,order:2},s.label=``,s.arrowTypeEnd=`none`,s.endLabelLeft=``,s.endLabelRight=``,s.startLabelLeft=``,s.id=t+`-cyclic-special-1`,c.startLabelRight=``,c.startLabelLeft=``,c.endLabelLeft=``,c.endLabelRight=``,c.arrowTypeStart=`none`,c.arrowTypeEnd=`none`,c.id=t+`-cyclic-special-mid`,l.label=``,l.startLabelRight=``,l.startLabelLeft=``,l.arrowTypeStart=`none`,a.isGroup&&(s.fromCluster=t,l.toCluster=t),l.id=t+`-cyclic-special-2`,l.arrowTypeStart=`none`,n.setEdge(t,r,s,t+`-cyclic-special-0`),n.setEdge(r,i,c,t+`-cyclic-special-1`),n.setEdge(i,t,l,t+`-cyclic-special-2`)}else n.setEdge(e.start,e.end,{...e},e.id)}),Ue(n),{graph:n}},`prepareLayoutForDagre`),ki=t(async(e,{element:t,preparedLayout:r})=>{let i=r??Oi(e),a=n(),o=await bi({element:t,graph:i.graph,diagramType:e.type,id:e.diagramId,parentCluster:void 0,siteConfig:a});return i.measuredLayout=o,o},`measureDagreLayout`),Ai=t((e,t)=>{let n=t.preparedLayout?.measuredLayout;if(!n)throw Error(`runDagreLayoutCore requires measureDagreLayout to run first`);return xi(n.graph),Ti(e,n),n},`runDagreLayoutCore`),ji=Ve({prepareLayout:Oi,measureLayout:ki,runLayoutCore:Ai,paintOptions:{clusterDb:N,getNodes:t((e,{measure:t})=>Re(t.graph).map(e=>t.graph.node(e)).filter(Boolean),`getDagrePaintNodes`),getEdgeNode:t((e,t,{measure:n})=>e?n.graph.node(e):void 0,`getDagreEdgeNode`),skipNode:t((e,{measure:t})=>!t.graph.hasNode(e.id),`skipNode`),isCluster:t((e,{measure:t})=>t.graph.hasNode(e.id)&&(t.graph.children(e.id)??[]).length>0,`isCluster`)}});export{Ti as applyDagreLayoutResult,yi as getEdgesToRender,ki as measureDagreLayout,Oi as prepareLayoutForDagre,ji as render,Ai as runDagreLayoutCore}; \ No newline at end of file diff --git a/frontend/dist/assets/defaultLocale-BFoDCU3G.js b/frontend/dist/assets/defaultLocale-BFoDCU3G.js new file mode 100644 index 0000000..3304660 --- /dev/null +++ b/frontend/dist/assets/defaultLocale-BFoDCU3G.js @@ -0,0 +1 @@ +function e(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString(`en`).replace(/,/g,``):e.toString(10)}function t(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf(`e`),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function n(e){return e=t(Math.abs(e)),e?e[1]:NaN}function r(e,t){return function(n,r){for(var i=n.length,a=[],o=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),a.push(n.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function i(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}var a=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function o(e){if(!(t=a.exec(e)))throw Error(`invalid format: `+e);var t;return new s({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}o.prototype=s.prototype;function s(e){this.fill=e.fill===void 0?` `:e.fill+``,this.align=e.align===void 0?`>`:e.align+``,this.sign=e.sign===void 0?`-`:e.sign+``,this.symbol=e.symbol===void 0?``:e.symbol+``,this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?``:e.type+``}s.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?`0`:``)+(this.width===void 0?``:Math.max(1,this.width|0))+(this.comma?`,`:``)+(this.precision===void 0?``:`.`+Math.max(0,this.precision|0))+(this.trim?`~`:``)+this.type};function c(e){out:for(var t=e.length,n=1,r=-1,i;n0&&(r=0)}return r>0?e.slice(0,r)+e.slice(i+1):e}var l;function u(e,n){var r=t(e,n);if(!r)return l=void 0,e.toPrecision(n);var i=r[0],a=r[1],o=a-(l=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,s=i.length;return o===s?i:o>s?i+Array(o-s+1).join(`0`):o>0?i.slice(0,o)+`.`+i.slice(o):`0.`+Array(1-o).join(`0`)+t(e,Math.max(0,n+o-1))[0]}function d(e,n){var r=t(e,n);if(!r)return e+``;var i=r[0],a=r[1];return a<0?`0.`+Array(-a).join(`0`)+i:i.length>a+1?i.slice(0,a+1)+`.`+i.slice(a+1):i+Array(a-i.length+2).join(`0`)}var f={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+``,d:e,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>d(e*100,t),r:d,s:u,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function p(e){return e}var m=Array.prototype.map,h=[`y`,`z`,`a`,`f`,`p`,`n`,`µ`,`m`,``,`k`,`M`,`G`,`T`,`P`,`E`,`Z`,`Y`];function g(e){var t=e.grouping===void 0||e.thousands===void 0?p:r(m.call(e.grouping,Number),e.thousands+``),a=e.currency===void 0?``:e.currency[0]+``,s=e.currency===void 0?``:e.currency[1]+``,u=e.decimal===void 0?`.`:e.decimal+``,d=e.numerals===void 0?p:i(m.call(e.numerals,String)),g=e.percent===void 0?`%`:e.percent+``,_=e.minus===void 0?`−`:e.minus+``,v=e.nan===void 0?`NaN`:e.nan+``;function y(e,n){e=o(e);var r=e.fill,i=e.align,p=e.sign,m=e.symbol,y=e.zero,b=e.width,x=e.comma,S=e.precision,C=e.trim,w=e.type;w===`n`?(x=!0,w=`g`):f[w]||(S===void 0&&(S=12),C=!0,w=`g`),(y||r===`0`&&i===`=`)&&(y=!0,r=`0`,i=`=`);var T=(n&&n.prefix!==void 0?n.prefix:``)+(m===`$`?a:m===`#`&&/[boxX]/.test(w)?`0`+w.toLowerCase():``),E=(m===`$`?s:/[%p]/.test(w)?g:``)+(n&&n.suffix!==void 0?n.suffix:``),D=f[w],O=/[defgprs%]/.test(w);S=S===void 0?6:/[gprs]/.test(w)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S));function k(e){var n=T,a=E,o,s,f;if(w===`c`)a=D(e)+a,e=``;else{e=+e;var m=e<0||1/e<0;if(e=isNaN(e)?v:D(Math.abs(e),S),C&&(e=c(e)),m&&+e==0&&p!==`+`&&(m=!1),n=(m?p===`(`?p:_:p===`-`||p===`(`?``:p)+n,a=(w===`s`&&!isNaN(e)&&l!==void 0?h[8+l/3]:``)+a+(m&&p===`(`?`)`:``),O){for(o=-1,s=e.length;++of||f>57){a=(f===46?u+e.slice(o+1):e.slice(o))+a,e=e.slice(0,o);break}}}x&&!y&&(e=t(e,1/0));var g=n.length+e.length+a.length,k=g>1)+n+e+a+k.slice(g);break;default:e=k+n+e+a}return d(e)}return k.toString=function(){return e+``},k}function b(e,t){var r=Math.max(-8,Math.min(8,Math.floor(n(t)/3)))*3,i=10**-r,a=y((e=o(e),e.type=`f`,e),{suffix:h[8+r/3]});return function(e){return a(i*e)}}return{format:y,formatPrefix:b}}var _,v,y;b({thousands:`,`,grouping:[3],currency:[`$`,``]});function b(e){return _=g(e),v=_.format,y=_.formatPrefix,_}export{n as i,y as n,o as r,v as t}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-22UHCM2B-B4G_FQZz.js b/frontend/dist/assets/diagram-22UHCM2B-B4G_FQZz.js new file mode 100644 index 0000000..2afccde --- /dev/null +++ b/frontend/dist/assets/diagram-22UHCM2B-B4G_FQZz.js @@ -0,0 +1,200 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as r,H as i,U as a,a as o,d as s,ot as c,q as l,s as u,tt as d,v as f,w as p,x as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as g}from"./channel-_oCHZhRo.js";import{c as _,g as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as y,n as b,o as x,r as S}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{a as C}from"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{_ as w,n as T,t as E,v as D}from"./index-DoQkmpth.js";import{t as O}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as k}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as A}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as j}from"./chunk-WEXAMYUT-I3m-hOmT.js";var M={SHAPE_UNSUPPORTED:`SHAPE_UNSUPPORTED`,SHAPE_REMOVED:`SHAPE_REMOVED`,EDGE_OPERATOR_UNSUPPORTED:`EDGE_OPERATOR_UNSUPPORTED`,REFERENCE_EDGE_LABEL_REJECTED:`REFERENCE_EDGE_LABEL_REJECTED`,CONNECTOR_REF_UNRESOLVED:`CONNECTOR_REF_UNRESOLVED`,CONNECTOR_REF_NOT_A_CONNECTOR:`CONNECTOR_REF_NOT_A_CONNECTOR`,METADATA_KEY_MISAPPLIED:`METADATA_KEY_MISAPPLIED`,DUPLICATE_ID_NODE:`DUPLICATE_ID_NODE`,RESERVED_SYNTHETIC_ID:`RESERVED_SYNTHETIC_ID`,CONTAINMENT_VIOLATION:`CONTAINMENT_VIOLATION`,EDGE_SEMANTIC_CONTRADICTION:`EDGE_SEMANTIC_CONTRADICTION`,FLOW_NO_INPUT:`FLOW_NO_INPUT`},N=new Set([M.SHAPE_UNSUPPORTED,M.SHAPE_REMOVED,M.CONTAINMENT_VIOLATION]);new Set(Object.values(M).filter(e=>!N.has(e)));var P=new Map([[`task`,`roundedRect`],[`tool`,`subroutine`],[`input`,`lean-right`],[`decision`,`diamond`],[`refdoc`,`lin-doc`],[`action`,`hexagon`],[`round`,`rect`]]),ee=new Set(`doc.stadium.terminal.circle.trapezoid.inv_trapezoid.inv-trapezoid.doublecircle.double-circle.typeDeclaration.procs.lean_left.lean-left.in-out.cylinder.ellipse.odd.tag-rect.tagged-rectangle.delay.half-rounded-rectangle.lin-rect.lined-rectangle.win-pane.window-pane.curv-trap.curved-trapezoid`.split(`.`)),te=new Set([`roundedRect`,`subroutine`,`subprocess`,`subproc`,`framed-rectangle`,`lean-right`,`diamond`,`lin-doc`,`lined-document`,`hexagon`,`hex`,`connector`,`collapsedGroup`]),F=`roundedRect`;function I(e){return e&&(P.get(e)??e)}n(I,`resolveShapeAlias`);function ne(t,n){for(let r of t)if(!r.isGroup){if((!r.shape||r.shape===`squareRect`||r.shape===`rect`)&&(r.shape=F),ee.has(r.shape)){let t=`shape "${r.shape}" was removed in v0.8.1, using "${F}"`;n?.emitError?n.emitError(`SHAPE_REMOVED`,t,{nodeId:r.id}):e.warn(`agentflow: ${t}`),r.shape=F;continue}if(!te.has(r.shape)){let t=`shape "${r.shape}" is not supported, using "${F}"`;n?.emitWarning?n.emitWarning(`SHAPE_UNSUPPORTED`,t,{nodeId:r.id}):e.warn(`agentflow: ${t}`),r.shape=F}}}n(ne,`normaliseNodeShapes`);var L=new Map([[`tool`,0],[`task`,1],[`decision`,2],[`input`,3],[`refdoc`,4],[`connector`,5],[`action`,6]]),R=L.size,z=n(e=>`af-kind-${e}`,`kindClass`),B=[...L.keys()],V=n(e=>Math.max(1,e-R),`containerSlotCount`),H=n((e,t)=>{let n=R+e%V(t);return t>0?n%t:n},`containerSlot`);function re(e,t,n){let r=m().themeVariables?.borderColorArray,i=Array.isArray(r)?r.length:0,a=n.size;for(let r of e??[]){if(r.isGroup||r.shape===`collapsedGroup`){r.colorIndex=H(n.get(String(r.id))??a++,i);continue}let e=t(String(r.id));e&&L.has(e)&&(r.cssClasses=`${r.cssClasses??``} ${z(e)}`.replace(/\s+/g,` `).trim())}}n(re,`assignColorSlots`);var ie=`agentflow-`,ae=new Set([`shape`,`view`,`icon`,`img`,`form`,`pos`,`w`,`h`,`class`,`style`,`labelType`]),oe=new Set([`subroutine`,`subprocess`,`subproc`,`framed-rectangle`,`tool`]),se={flow:`flowGroup`};function ce(e){if(Array.isArray(e))return e.map(e=>ce(e));if(typeof e!=`object`||!e)return e;let t={};for(let n of Object.keys(e))n!==`__proto__`&&n!==`constructor`&&n!==`prototype`&&(t[n]=ce(e[n]));return t}n(ce,`stripPrototypeKeys`);function le(e){let t=!1,n=!1,r=0,i,a=[];for(let o of e.split(` +`)){if(i!==void 0){let e=o.length-o.trimStart().length;if(o.trim()===``||e>i){a.push(o);continue}i=void 0}let e=-1;for(let i=0;i0){a.push(o);continue}let s=e>=0?o.slice(0,e):o,c=e>=0?o.slice(e):``;if(/:\s*[>|][\d+-]*\s*$/.test(s)){i=o.length-o.trimStart().length,a.push(o);continue}a.push(s.replace(/,([\t ]*)$/,`$1`)+c)}return a.join(` +`)}n(le,`stripLineTrailingCommas`);var ue=class{constructor(){this.vertexCounter=0,this.config=m(),this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.diagramId=``,this.preserveCommentsWhenParsing=!0,this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,this.funs=[],this.setAccTitle=a,this.setAccDescription=i,this.setDiagramTitle=l,this.getAccTitle=h,this.getAccDescription=f,this.getDiagramTitle=p,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addGlobal=this.addGlobal.bind(this),this.addConnector=this.addConnector.bind(this),this.addConnectorMapping=this.addConnectorMapping.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.setFrontmatterLineOffset=this.setFrontmatterLineOffset.bind(this),this.addVertexMapping=this.addVertexMapping.bind(this),this.extendVertexMapping=this.extendVertexMapping.bind(this),this.addEdgeMapping=this.addEdgeMapping.bind(this),this.addSubgraphMapping=this.addSubgraphMapping.bind(this),this.emitWarning=this.emitWarning.bind(this),this.emitError=this.emitError.bind(this),this.getDiagnostics=this.getDiagnostics.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen(`gen-2`)}static{n(this,`AgentFlowDB`)}sanitizeText(e){return u.sanitizeText(e,this.config)}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}setDiagramId(e){this.diagramId=e}lookUpDomId(e){for(let t of this.vertices.values())if(t.id===e)return this.diagramId?`${this.diagramId}-${t.domId}`:t.domId;return this.diagramId?`${this.diagramId}-${e}`:e}addVertex(e,t,n,r,i,a,o={},s,c){if(!e||e.trim().length===0)return;let l;if(s!==void 0){let e;e=s.includes(` +`)?s+` +`:`{ +`+s+` +}`;try{l=D(e,{schema:w})??{}}catch(e){let t=s.includes(` +`)?le(s):s;if(t!==s)try{l=D(t+` +`,{schema:w})??{}}catch{this.rethrowMetadataYamlError(e,s,c)}else this.rethrowMetadataYamlError(e,s,c)}l=ce(l)}let u;if(l&&typeof l.shape==`string`){let e=l;u=e.shape;let t=I(u);t&&t!==u&&(e.shape=t)}let d=this.subGraphLookup.get(e);if(d&&l){d.metadata={...d.metadata,...l};return}let f=this.connectors.get(e);if(f&&l){f.metadata={...f.metadata,...l};return}if(e===`connectors`)return;let p=this.edges.find(t=>t.id===e);if(p){let e=l;e?.animate!==void 0&&(p.animate=e.animate),e?.animation!==void 0&&(p.animation=e.animation),e?.curve!==void 0&&(p.interpolate=e.curve),l&&(p.metadata={...p.metadata,...l});return}let h,g=this.vertices.get(e);if(g===void 0&&(g={id:e,labelType:`text`,domId:ie+e+`-`+this.vertexCounter,styles:[],classes:[]},this.vertices.set(e,g)),this.vertexCounter++,t===void 0?g.text===void 0&&(g.text=e):(this.config=m(),h=this.sanitizeText(t.text.trim()),g.labelType=t.type,h.startsWith(`"`)&&h.endsWith(`"`)&&(h=h.substring(1,h.length-1)),g.text=h),n!==void 0&&(g.type=n),r?.forEach(e=>{g.styles.push(e)}),i?.forEach(e=>{g.classes.push(e)}),a!==void 0&&(g.dir=a),g.props===void 0?g.props=o:o!==void 0&&Object.assign(g.props,o),l){if(g.metadata={...g.metadata,...l},l.shape){let e=u??l.shape;if(typeof e!=`string`)throw this.positionedShapeError(`No such shape: ${JSON.stringify(e)}.`,c);if(e!==e.toLowerCase()||e.includes(`_`))throw this.positionedShapeError(`No such shape: ${e}. Shape names should be lowercase.`,c);if(!C(l.shape))throw this.positionedShapeError(`No such shape: ${l.shape}.`,c);g.type=l?.shape}l?.label&&(g.text=this.sanitizeText(l.label),g.labelType=this.sanitizeNodeLabelType(l?.labelType))}}positionedShapeError(e,t){let n=Error(e);if(!t)return n;let r=t.first_line+this.frontmatterLineOffset;return Object.assign(n,{hash:{text:``,token:null,line:r-1,loc:{first_line:r,last_line:t.last_line+this.frontmatterLineOffset,first_column:t.first_column,last_column:t.last_column},expected:[]}}),n}rethrowMetadataYamlError(e,t,r){let i=e;if(!i||i.name!==`YAMLException`||!i.mark||!r)throw e;let a;try{let e=!t.includes(` +`),o=e?`{ +`+t+` +}`:t+` +`,s=r.first_line+this.frontmatterLineOffset,c=r.first_column+2,l=n((t,n)=>e?{line:s,column:c+(t===1?n:0)}:{line:s+t,column:t===0?c+n:n},`toSource`),u=l(i.mark.line,i.mark.column),d=i.reason??(i.message??``).split(` +`)[0].replace(/\s*\(\d+:\d+\)\s*$/,``),f=o.split(` +`),p=[];if(e)p.push(1);else for(let e=i.mark.line-1;e<=i.mark.line+1;e++)e<0||e>=f.length||(e!==f.length-1||f[e]!==``||e===i.mark.line)&&p.push(e);let m=Math.max(...p.map(e=>String(l(e,0).line).length)),h=[];for(let e of p){let t=l(e,0).line,n=` ${String(t).padStart(m)} | `;h.push(n+f[e].replace(/\t/g,`→`)),e===i.mark.line&&h.push(`-`.repeat(n.length+i.mark.column)+`^`)}a={message:`${d} (${u.line}:${u.column+1}) + +${h.join(` +`)}`,markLine:u.line-1,markColumn:u.column,hash:{text:``,token:null,line:u.line-1,loc:{first_line:u.line,last_line:u.line,first_column:u.column,last_column:u.column+1},expected:[]}}}catch{}throw a&&(i.message=a.message,i.mark.line=a.markLine,i.mark.column=a.markColumn,i.hash=a.hash),i}addSingleLink(t,n,r,i){let a={start:t,end:n,type:void 0,text:``,labelType:`text`,classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};e.info(`abc78 Got edge...`,a);let o=r.text;if(o!==void 0&&(a.text=this.sanitizeText(o.text.trim()),a.text.startsWith(`"`)&&a.text.endsWith(`"`)&&(a.text=a.text.substring(1,a.text.length-1)),a.labelType=this.sanitizeNodeLabelType(o.type)),r!==void 0&&(a.type=r.type,a.stroke=r.stroke,a.length=r.length>10?10:r.length,r.edgeSemantic&&(a.edgeSemantic=r.edgeSemantic)),i&&!this.edges.some(e=>e.id===i))a.id=i,a.isUserDefinedId=!0;else{let e=this.edges.filter(e=>e.start===a.start&&e.end===a.end);a.id=e.length===0?_(a.start,a.end,{counter:0,prefix:`L`}):_(a.start,a.end,{counter:e.length+1,prefix:`L`})}if(this.edges.length<(this.config.maxEdges??500))e.info(`Pushing edge...`),this.edges.push(a);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}. + +Initialize mermaid with maxEdges set to a higher number to allow more edges. +You cannot set this config via configuration inside the diagram as it is a secure config. +You have to call mermaid.initialize.`)}isLinkData(e){return typeof e==`object`&&!!e&&`id`in e&&typeof e.id==`string`}addLink(t,n,r){let i=this.isLinkData(r)?r.id.replace(`@`,``):void 0;e.info(`addLink`,t,n,i);for(let e of t)for(let a of n){let o=e===t[t.length-1],s=a===n[0];o&&s?this.addSingleLink(e,a,r,i):this.addSingleLink(e,a,r,void 0)}}updateLinkInterpolate(e,t){e.forEach(e=>{if(e==="default"){this.edges.defaultInterpolate=t;return}if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);this.edges[e].interpolate=t})}updateLink(e,t){e.forEach(e=>{if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);e==="default"?this.edges.defaultStyle=t:(this.edges[e].style=t,(this.edges[e]?.style?.length??0)>0&&!this.edges[e]?.style?.some(e=>e?.startsWith(`fill`))&&this.edges[e]?.style?.push(`fill:none`))})}addClass(e,t){let n=t.join().replace(/\\,/g,`§§§`).replace(/,/g,`;`).replace(/§§§/g,`,`).split(`;`);e.split(`,`).forEach(e=>{let t=this.classes.get(e);t===void 0&&(t={id:e,styles:[],textStyles:[]},this.classes.set(e,t)),n?.forEach(e=>{if(/color/.exec(e)){let n=e.replace(`fill`,`bgFill`);t.textStyles.push(n)}t.styles.push(e)})})}setDirection(e){this.direction=e.trim(),/.*/.exec(this.direction)&&(this.direction=`LR`),/.*v/.exec(this.direction)&&(this.direction=`TB`),this.direction===`TD`&&(this.direction=`TB`)}setClass(e,t){for(let n of e.split(`,`)){let e=this.vertices.get(n);e&&e.classes.push(t);let r=this.edges.find(e=>e.id===n);r&&r.classes.push(t);let i=this.subGraphLookup.get(n);i&&i.classes.push(t)}}setTooltip(e,t){if(t!==void 0){t=this.sanitizeText(t);for(let n of e.split(`,`))this.tooltips.set(this.version===`gen-1`?this.lookUpDomId(n):n,t)}}setClickFun(e,t,n){if(m().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{let n=this.lookUpDomId(e),i=document.querySelector(`[id="${n}"]`);i!==null&&i.addEventListener(`click`,()=>{v.runFunc(t,...r)},!1)}))}setLink(e,t,n){e.split(`,`).forEach(e=>{let r=this.vertices.get(e);r!==void 0&&(r.link=v.formatUrl(t,this.config),r.linkTarget=n)}),this.setClass(e,`clickable`)}getTooltip(e){return this.tooltips.get(e)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFun(e,t,n)}),this.setClass(e,`clickable`)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}isToolDefinition(e){return oe.has(e.type)}getTools(){let e=[];for(let t of this.vertices.values())this.isToolDefinition(t)&&e.push(t);return e}getClasses(){return this.classes}setupToolTips(e){let n=k();t(e).select(`svg`).selectAll(`g.node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.text(r.attr(`title`)).style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(d.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}clear(e=`gen-2`){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=e,this.config=m(),this.diagramId=``,this.vertexCounter=0,this.direction=void 0,this.secCount=-1,this.posCrossRef=[],this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,o()}setGen(e){this.version=e||`gen-2`}defaultStyle(){return`fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;`}addSubGraph(t,r,i,a){let o=t?.text?.trim(),s=i?.text;t===i&&i?.text&&/\s/.exec(i.text)&&(o=void 0);let c=n(e=>{let t={boolean:{},number:{},string:{}},n=[],r;return{nodeList:e.filter(function(e){let i=typeof e;return e.stmt&&e.stmt===`dir`?(r=e.value,!1):e.trim()===``?!1:i in t?t[i].hasOwnProperty(e)?!1:t[i][e]=!0:!n.includes(e)&&n.push(e)}),dir:r}},`uniq`)(r.flat()),l=c.nodeList,u=c.dir,d=m().flowchart??{};if(u??=d.inheritDir?this.getDirection()??m().direction??void 0:void 0,this.version===`gen-1`)for(let e=0;ee!==o&&!this.globalNodes.has(e)),title:s.trim(),classes:[],dir:u,labelType:this.sanitizeNodeLabelType(i?.type),type:a??`flow`};e.info(`Adding`,f.id,f.nodes,f.dir),f.nodes=this.makeUniq(f,this.subGraphs).nodes;let p=this.getPosForId(o);if(p!==-1){let e=this.subGraphs[p];for(let t of f.nodes)e.nodes.includes(t)||e.nodes.push(t);f.title&&(e.title=f.title),f.dir&&(e.dir=f.dir),f.type&&(e.type=f.type),this.subGraphLookup.set(o,e)}else this.subGraphs.push(f),this.subGraphLookup.set(o,f);return o}addGlobal(e){for(let t of e.flat()){if(typeof t!=`string`)continue;let e=t.trim();e!==``&&this.globalNodes.add(e)}for(let e of this.subGraphs)e.nodes=e.nodes.filter(e=>!this.globalNodes.has(e))}getPosForId(e){for(let[t,n]of this.subGraphs.entries())if(n.id===e)return t;return-1}indexNodes2(e,t){let n=this.subGraphs[t].nodes;if(this.secCount+=1,this.secCount>2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=t,this.subGraphs[t].id===e)return{result:!0,count:0};let r=0,i=1;for(;r=0){let n=this.indexNodes2(e,t);if(n.result)return{result:!0,count:i+n.count};i+=n.count}r+=1}return{result:!1,count:i}}getDepthFirstPos(e){return this.posCrossRef[e]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2(`none`,this.subGraphs.length-1)}addConnector(e,t){let n=e?.text?.trim();if(!n)return``;let r=t?.text?.trim()??``,i=r.length>0?this.sanitizeText(r):n,a=this.connectors.get(n);return a?r.length>0&&(a.text=i):(a={id:n,labelType:`text`,domId:ie+n+`-`+this.vertexCounter,styles:[],classes:[],isConnector:!0,text:i},this.connectors.set(n,a),this.vertices.set(n,a),this.vertexCounter++),n}getSubGraphs(){return this.subGraphs}getConnectors(){return[...this.connectors.values()]}firstGraph(){return this.firstGraphFlag?(this.firstGraphFlag=!1,!0):!1}computeEdgeSemantic(e,t){if(e===`arrow_point`&&t===`normal`)return`sequence`;if(e===`arrow_cross`&&t===`normal`)return`failure`;if(e===`arrow_open`&&t===`dotted`)return`reference`}destructStartLink(e){let t=e.trim(),n=`normal`;return t.includes(`.`)&&(n=`dotted`),{type:`arrow_open`,stroke:n}}countChar(e,t){let n=t.length,r=0;for(let i=0;i`:r=`arrow_point`;break;case`-`:case`.`:r=`arrow_open`,n=t}let i=`normal`,a=n.length-1,o=this.countChar(`.`,n);return o>0&&(i=`dotted`,a=o),{type:r,stroke:i,length:a}}destructLink(e,t){let n=this.destructEndLink(e),r;return t?(r=this.destructStartLink(t),r.stroke===n.stroke?(r.type=n.type,r.length=n.length,{...r,edgeSemantic:this.computeEdgeSemantic(r.type,r.stroke)}):{type:`INVALID`,stroke:`INVALID`}):{...n,edgeSemantic:this.computeEdgeSemantic(n.type,n.stroke)}}exists(e,t){for(let n of e)if(n.nodes.includes(t))return!0;return!1}makeUniq(e,t){let n=[];return e.nodes.forEach((r,i)=>{this.exists(t,r)||n.push(e.nodes[i])}),{nodes:n}}getTypeFromVertex(e){let t=typeof e.type==`string`?I(e.type):e.type;switch(t){case`square`:case void 0:return`squareRect`;case`round`:return`roundedRect`;case`ellipse`:return`ellipse`;default:return t}}findNode(e,t){return e.find(e=>e.id===t)}destructEdgeType(e){let t=`none`,n=`arrow_point`;switch(e){case`arrow_point`:case`arrow_circle`:case`arrow_cross`:case`arrow_hierarchy`:n=e;break;case`double_arrow_point`:case`double_arrow_circle`:case`double_arrow_cross`:t=e.replace(`double_`,``),n=t}return{arrowTypeStart:t,arrowTypeEnd:n}}addNodeFromVertex(e,t,n,r,i,a){let o=n.get(e.id),s=r.get(e.id)??!1,c=this.findNode(t,e.id);if(c)c.cssStyles=e.styles,c.cssCompiledStyles=this.getCompiledStyles(e.classes),c.cssClasses=e.classes.join(` `);else{let n={id:e.id,label:e.text,labelType:e.labelType,labelStyle:``,parentId:o,padding:i.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:this.getCompiledStyles([`default`,`node`,...e.classes]),cssClasses:`default `+e.classes.join(` `),dir:e.dir,domId:e.domId,look:a,link:e.link,linkTarget:e.linkTarget,tooltip:this.getTooltip(e.id),metadata:e.metadata};s?t.push({...n,isGroup:!0,shape:`rect`}):t.push({...n,isGroup:!1,shape:this.getTypeFromVertex(e),wrappingWidth:i.agentflow?.wrappingWidth,minWidth:i.agentflow?.minNodeWidth})}}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}runPostParseValidators(){this.postParseValidationRun||=!0}getData(){this.runPostParseValidators();let e=m(),t=[],r=[],i=this.getSubGraphs(),a=new Map,o=new Map,s=new Set,c=new Map,l=n((e,t,n=new Set)=>{if(n.has(e))return;n.add(e);let r=this.subGraphLookup.get(e);if(r)for(let e of r.nodes)e===t||n.has(e)||(s.add(e),c.set(e,t),l(e,t,n))},`collectDescendants`);for(let e of i)e.metadata?.view===`collapsed`&&!s.has(e.id)&&l(e.id,e.id);let u=n((e,t)=>{let n=new Set,r=t;for(;r!==void 0&&!n.has(r);){if(r===e)return!0;n.add(r),r=a.get(r)}return!1},`wouldCloseContainmentCycle`);for(let e=i.length-1;e>=0;e--){let t=i[e];if(!s.has(t.id)){t.nodes.length>0&&o.set(t.id,!0);for(let e of t.nodes){if(u(e,t.id)){this.emitWarning(M.CONTAINMENT_VIOLATION,`Container "${t.id}" cannot contain "${e}" because "${e}" already contains it. The nesting that would close the loop is dropped.`,{nodeId:e});continue}a.set(e,t.id)}}}for(let n=i.length-1;n>=0;n--){let r=i[n];if(!s.has(r.id)){if(r.metadata?.view===`collapsed`){let n={...r.metadata,containerType:r.type};t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`collapsedGroup`,dir:r.dir,isGroup:!1,look:e.look,metadata:n})}else t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:se[r.type??`flow`],dir:r.dir,isGroup:!0,look:e.look,metadata:r.metadata})}}this.getVertices().forEach(n=>{s.has(n.id)||this.addNodeFromVertex(n,t,a,o,e,e.look||`classic`)});let d=this.getEdges();d.forEach((t,n)=>{let i=c.get(t.start)??t.start,a=c.get(t.end)??t.end;if(i===a&&t.start!==t.end)return;let{arrowTypeStart:o,arrowTypeEnd:s}=this.destructEdgeType(t.type),l=[...d.defaultStyle??[]];t.style&&l.push(...t.style);let u={id:_(i,a,{counter:n,prefix:`L`},t.id),isUserDefinedId:t.isUserDefinedId,start:i,end:a,type:t.type??`normal`,label:t.text,labelType:t.labelType,labelpos:`c`,thickness:t.stroke,minlen:t.length,classes:t?.stroke===`invisible`?``:`edge-thickness-normal edge-pattern-solid flowchart-link`,arrowTypeStart:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:o,arrowTypeEnd:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:s,arrowheadStyle:`fill: #333`,cssCompiledStyles:this.getCompiledStyles(t.classes),labelStyle:l,style:l,pattern:t.stroke,look:e.look,animate:t.animate,animation:t.animation,curve:t.interpolate||this.edges.defaultInterpolate||e.flowchart?.curve,metadata:t.metadata};r.push(u)}),ne(t,this);let f=new Map,p=new Map;for(let e of i){let t=a.get(e.id);t!==void 0&&p.set(t,[...p.get(t)??[],e.id])}let h=0,g=n(e=>{if(!f.has(e)){f.set(e,h++);for(let t of p.get(e)??[])g(t)}},`walkContainers`);for(let e of i)a.get(e.id)===void 0&&g(e.id);let v=new Set(this.getConnectors().map(e=>e.id));return re(t,e=>{if(v.has(e))return`connector`;let t=this.vertices.get(e);return t?this.deriveVertexKind(t,I(t.type)):void 0},f),{nodes:t,edges:r,other:{},config:e,connectors:this.getConnectors()}}defaultConfig(){return s.flowchart}deriveVertexKind(e,t){return this.isToolDefinition(e)?`tool`:t===`hexagon`||t===`hex`?`action`:t===`lean-right`||t===`lean_right`?`input`:t===`lin-doc`||t===`lined-document`?`refdoc`:t===`diamond`?`decision`:`task`}getSemanticModel(){this.runPostParseValidators();let e=new Set(this.subGraphs.map(e=>e.id)),t=[],n=[];for(let[r,i]of this.vertices){if(e.has(r))continue;if(i.isConnector){let e={id:r};if(i.text!==void 0&&i.text!==r&&(e.title=i.text),i.metadata&&Object.keys(i.metadata).length>0){let t={};for(let[e,n]of Object.entries(i.metadata))ae.has(e)||(t[e]=n);Object.keys(t).length>0&&(e.metadata=t)}n.push(e);continue}let a={id:r};i.text!==void 0&&(a.label=i.text);let o=typeof i.type==`string`?I(i.type):i.type;if(o!==void 0&&(a.shape=o),a.vertexKind=this.deriveVertexKind(i,o),i.metadata&&Object.keys(i.metadata).length>0){let e={};for(let[t,n]of Object.entries(i.metadata))ae.has(t)||(e[t]=n);Object.keys(e).length>0&&(a.metadata=e)}t.push(a)}let r={vertices:t,edges:this.edges.map(e=>{let t={start:e.start,end:e.end};return e.id!==void 0&&(t.id=e.id),typeof e.text==`string`&&e.text.length>0&&(t.label=e.text),e.type!==void 0&&(t.type=e.type),e.stroke!==void 0&&(t.stroke=e.stroke),e.edgeSemantic!==void 0&&(t.edgeSemantic=e.edgeSemantic),e.length!==void 0&&(t.length=e.length),e.metadata&&Object.keys(e.metadata).length>0&&(t.metadata={...e.metadata}),t}),subGraphs:this.subGraphs.map(e=>{let t={id:e.id,nodes:[...e.nodes]};if(e.type!==void 0&&(t.type=e.type),e.title!==void 0&&(t.title=e.title),e.dir!==void 0&&(t.direction=e.dir),e.metadata&&Object.keys(e.metadata).length>0){let n={};for(let[t,r]of Object.entries(e.metadata))ae.has(t)||(n[t]=r);Object.keys(n).length>0&&(t.metadata=n)}return t}),connectors:n,diagnostics:this.diagnostics};return this.direction!==void 0&&(r.direction=this.direction),r}setFrontmatterLineOffset(e){this.frontmatterLineOffset=e??0}toElementPosition(e){let t=e?.first_line??0,n=e?.first_column??0,r=e?.last_line??t,i=e?.last_column??n,[a,o]=e?.range??[0,0];return{startLine:t+this.frontmatterLineOffset,startColumn:n,endLine:r+this.frontmatterLineOffset,endColumn:i,startIndex:a,endIndex:o}}pushMapping(e,t,n){if(!e)return;let r={id:e,type:t,position:this.toElementPosition(n)};return this.elementMappings.push(r),r}addVertexMapping(e,t,n,r){let i=this.pushMapping(e,`vertex`,r);i&&n==null&&this.bareVertexMappings.add(i)}extendVertexMapping(e,t){if(!e||!t)return;let n=this.toElementPosition(t);for(let t=this.elementMappings.length-1;t>=0;t--){let r=this.elementMappings[t];if(r.type===`vertex`&&r.id===e){this.bareVertexMappings.has(r)&&(r.type=`attachment`,this.bareVertexMappings.delete(r)),(n.endLine>r.position.endLine||n.endLine===r.position.endLine&&n.endColumn>r.position.endColumn)&&(r.position.endLine=n.endLine,r.position.endColumn=n.endColumn,r.position.endIndex=n.endIndex);return}}this.pushMapping(e,`attachment`,t)}addEdgeMapping(e,t,n,r){let i=Array.isArray(t)?t.map(e=>typeof e==`string`?e:e?.id??``).filter(Boolean):[],a=i.length>0?i.join(`>`):`edge`;this.pushMapping(a,`edge`,r)}addSubgraphMapping(e,t,n,r){let i=(typeof e==`string`?e:e?.text)??``,a=this.toElementPosition(n),o=r?this.toElementPosition(r):a;i&&this.elementMappings.push({id:i,type:`subgraph`,position:{startLine:a.startLine,startColumn:a.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:a.startIndex,endIndex:o.endIndex}})}addConnectorMapping(e,t,n,r){let i=e?.text?.trim()??``;if(!i)return;let a=this.toElementPosition(n),o=r?this.toElementPosition(r):a;this.elementMappings.push({id:i,type:`connector`,position:{startLine:a.startLine,startColumn:a.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:a.startIndex,endIndex:o.endIndex}})}getElementMappings(){return[...this.elementMappings]}getElementById(e){return this.elementMappings.find(t=>t.id===e)}getElementsOnLine(e){return this.elementMappings.filter(t=>e>=t.position.startLine&&e<=t.position.endLine)}getElementAtPosition(e,t){let r=this.elementMappings.filter(n=>{let{startLine:r,startColumn:i,endLine:a,endColumn:o}=n.position;return!(ea||e===r&&to)});if(r.length===0)return;let i=n(({position:e})=>[e.endLine-e.startLine,e.endColumn-e.startColumn],`span`);return r.reduce((e,t)=>{let[n,r]=i(e),[a,o]=i(t);return a===n?oe.id===s.id&&e.severity===s.severity&&e.message===s.message&&e.nodeId===s.nodeId&&e.edgeId===s.edgeId))return;this.diagnostics.push(s);let c=`agentflow[${t}]: ${r}`;n===`error`?e.error(c):e.warn(c)}emitWarning(e,t,n){this.emitDiagnostic(e,`warning`,t,n)}emitError(e,t,n){this.emitDiagnostic(e,`error`,t,n)}getDiagnostics(){return[...this.diagnostics]}},de={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.debug(`Drawing agentflow diagram`,n);let{securityLevel:a,agentflow:o,layout:s}=m();i.db.setDiagramId(n),e.debug(`Before getData: `);let c=i.db.getData();e.debug(`Data: `,c);let l=A(n,a),u=i.db.getDirection();c.type=i.type,c.layoutAlgorithm=E(s),c.layoutAlgorithm===`dagre`&&s===`elk`&&e.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback."),c.direction=u,c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=[`point`,`circle`,`cross`,`hierarchy`],c.diagramId=n,e.debug(`REF1:`,c),await T(c,l);let d=o?.diagramPadding??8;v.insertTitle(l,`agentflowTitleText`,o?.titleTopMargin??0,i.db.getDiagramTitle()),j(l,d,`agentflow`,o?.useMaxWidth??!0)},`draw`)},fe=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,5],r=[1,4],i=[1,3],a=[1,6],o=[1,8,9,10,11,12,28,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],s=[2,2],c=[1,15],l=[1,16],u=[1,17],d=[1,18],f=[1,19],p=[1,26],m=[1,27],h=[1,28],g=[1,30],_=[1,31],v=[1,32],y=[1,55],b=[1,54],x=[1,34],S=[1,35],C=[1,36],w=[1,37],T=[1,38],E=[1,50],D=[1,52],O=[1,48],k=[1,53],A=[1,49],j=[1,56],M=[1,51],N=[1,57],P=[1,58],ee=[1,39],te=[1,40],F=[1,41],I=[1,42],ne=[1,43],L=[1,64],R=[1,8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],z=[1,70],B=[1,68],V=[1,67],H=[1,69],re=[8,9,10,12,78,80,81],ie=[1,88],ae=[1,101],oe=[1,106],se=[1,105],ce=[1,102],le=[1,98],ue=[1,104],de=[1,100],fe=[1,107],pe=[1,103],me=[1,108],he=[1,99],ge=[8,9,10,11,12,43,78,80,81],U=[8,9,10,11,12,43,49,78,80,81],W=[8,9,10,11,12,30,43,47,49,51,53,55,57,59,61,63,66,68,70,71,73,78,80,81,92,105,108,109,112,114,117,118,119],_e=[8,9,10,12,47,63,78,80,81,92,105,108,109,112,114,117,118,119],ve=[47,63,92,105,108,109,112,114,117,118,119],ye=[1,131],be=[1,132],xe=[1,134],Se=[1,133],Ce=[47,63,65,77,92,105,108,109,112,114,117,118,119],we=[1,143],Te=[1,157],Ee=[1,158],De=[1,159],Oe=[1,162],ke=[1,161],Ae=[1,160],je=[1,145],Me=[1,147],Ne=[1,151],Pe=[1,139],Fe=[1,140],Ie=[1,152],Le=[1,153],Re=[1,154],ze=[1,155],Be=[1,156],Ve=[1,163],He=[1,164],Ue=[1,141],We=[1,142],Ge=[1,149],Ke=[1,144],qe=[1,148],Je=[1,146],Ye=[8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],Xe=[1,168],Ze=[1,170],G=[8,9,10,12],K=[8,9,10,11,12,15,47,63,92,108,109,112,114,117,118,119],q=[1,190],J=[1,186],Y=[1,187],X=[1,191],Z=[1,188],Q=[1,189],Qe=[80,119,122],$=[8,9,10,11,12,13,15,28,30,33,35,36,43,47,63,78,87,88,89,90,91,92,93,108,112,114,117,118,119],$e=[11,109],et=[32,52,54,56,58,60,65,67,69,70,72,74,119,120,121],tt=[1,269],nt=[1,267],rt=[1,271],it=[1,265],at=[1,266],ot=[1,268],st=[1,270],ct=[1,272],lt=[1,292],ut=[8,9,10,12,109],dt=[8,9,10,11,12,63,87,108,109,112,113,114,115],ft={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,COMMENT:8,SEMI:9,NEWLINE:10,SPACE:11,EOF:12,GRAPH:13,NODIR:14,DIR:15,FirstStmtSeparator:16,ending:17,endToken:18,spaceList:19,spaceListNewline:20,vertexStatement:21,separator:22,styleStatement:23,linkStyleStatement:24,classDefStatement:25,classStatement:26,clickStatement:27,flow:28,textNoTags:29,SQS:30,text:31,SQE:32,end:33,shapeData:34,global:35,connector:36,direction:37,acc_title:38,acc_title_value:39,acc_descr:40,acc_descr_value:41,acc_descr_multiline_value:42,SHAPE_DATA:43,link:44,node:45,styledVertex:46,AMP:47,vertex:48,STYLE_SEPARATOR:49,idString:50,DOUBLECIRCLESTART:51,DOUBLECIRCLEEND:52,PS:53,PE:54,"(-":55,"-)":56,STADIUMSTART:57,STADIUMEND:58,SUBROUTINESTART:59,SUBROUTINEEND:60,VERTEX_WITH_PROPS_START:61,"NODE_STRING[field]":62,COLON:63,"NODE_STRING[value]":64,PIPE:65,CYLINDERSTART:66,CYLINDEREND:67,DIAMOND_START:68,DIAMOND_STOP:69,TAGEND:70,TRAPSTART:71,TRAPEND:72,INVTRAPSTART:73,INVTRAPEND:74,linkStatement:75,arrowText:76,TESTSTR:77,START_LINK:78,edgeText:79,LINK:80,LINK_ID:81,edgeTextToken:82,STR:83,MD_STR:84,textToken:85,keywords:86,STYLE:87,LINKSTYLE:88,CLASSDEF:89,CLASS:90,CLICK:91,DOWN:92,UP:93,textNoTagsToken:94,stylesOpt:95,"idString[vertex]":96,"idString[class]":97,CALLBACKNAME:98,CALLBACKARGS:99,HREF:100,LINK_TARGET:101,"STR[link]":102,"STR[tooltip]":103,alphaNum:104,DEFAULT:105,numList:106,INTERPOLATE:107,NUM:108,COMMA:109,style:110,styleComponent:111,NODE_STRING:112,UNIT:113,BRKT:114,PCT:115,idStringToken:116,MINUS:117,MULT:118,UNICODE_TEXT:119,TEXT:120,TAGSTART:121,EDGE_TEXT:122,alphaNumToken:123,direction_tb:124,direction_bt:125,direction_rl:126,direction_lr:127,direction_td:128,$accept:0,$end:1},terminals_:{2:`error`,8:`COMMENT`,9:`SEMI`,10:`NEWLINE`,11:`SPACE`,12:`EOF`,13:`GRAPH`,14:`NODIR`,15:`DIR`,28:`flow`,30:`SQS`,32:`SQE`,33:`end`,35:`global`,36:`connector`,38:`acc_title`,39:`acc_title_value`,40:`acc_descr`,41:`acc_descr_value`,42:`acc_descr_multiline_value`,43:`SHAPE_DATA`,47:`AMP`,49:`STYLE_SEPARATOR`,51:`DOUBLECIRCLESTART`,52:`DOUBLECIRCLEEND`,53:`PS`,54:`PE`,55:`(-`,56:`-)`,57:`STADIUMSTART`,58:`STADIUMEND`,59:`SUBROUTINESTART`,60:`SUBROUTINEEND`,61:`VERTEX_WITH_PROPS_START`,62:`NODE_STRING[field]`,63:`COLON`,64:`NODE_STRING[value]`,65:`PIPE`,66:`CYLINDERSTART`,67:`CYLINDEREND`,68:`DIAMOND_START`,69:`DIAMOND_STOP`,70:`TAGEND`,71:`TRAPSTART`,72:`TRAPEND`,73:`INVTRAPSTART`,74:`INVTRAPEND`,77:`TESTSTR`,78:`START_LINK`,80:`LINK`,81:`LINK_ID`,83:`STR`,84:`MD_STR`,87:`STYLE`,88:`LINKSTYLE`,89:`CLASSDEF`,90:`CLASS`,91:`CLICK`,92:`DOWN`,93:`UP`,96:`idString[vertex]`,97:`idString[class]`,98:`CALLBACKNAME`,99:`CALLBACKARGS`,100:`HREF`,101:`LINK_TARGET`,102:`STR[link]`,103:`STR[tooltip]`,105:`DEFAULT`,107:`INTERPOLATE`,108:`NUM`,109:`COMMA`,112:`NODE_STRING`,113:`UNIT`,114:`BRKT`,115:`PCT`,117:`MINUS`,118:`MULT`,119:`UNICODE_TEXT`,120:`TEXT`,121:`TAGSTART`,122:`EDGE_TEXT`,124:`direction_tb`,125:`direction_bt`,126:`direction_rl`,127:`direction_lr`,128:`direction_td`},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,2],[4,3],[17,2],[17,1],[18,1],[18,1],[18,1],[16,1],[16,1],[16,2],[16,1],[20,2],[20,2],[20,2],[20,1],[20,1],[20,1],[19,2],[19,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,10],[7,6],[7,7],[7,4],[7,4],[7,7],[7,8],[7,4],[7,5],[7,1],[7,2],[7,2],[7,1],[22,1],[22,1],[22,1],[22,1],[34,2],[34,1],[21,4],[21,3],[21,4],[21,2],[21,2],[21,1],[45,1],[45,6],[45,5],[46,1],[46,3],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,8],[48,4],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,4],[48,4],[48,1],[44,2],[44,3],[44,3],[44,1],[44,3],[44,4],[79,1],[79,2],[79,1],[79,1],[75,1],[75,2],[76,3],[31,1],[31,2],[31,1],[31,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[29,1],[29,2],[29,1],[29,1],[25,5],[26,5],[27,2],[27,4],[27,3],[27,5],[27,3],[27,5],[27,5],[27,7],[27,2],[27,4],[27,2],[27,4],[27,4],[27,6],[23,5],[24,5],[24,5],[24,9],[24,9],[24,7],[24,7],[106,1],[106,3],[95,1],[95,3],[110,1],[110,2],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[85,1],[85,1],[85,1],[85,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[82,1],[82,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[50,1],[50,2],[104,1],[104,2],[37,1],[37,1],[37,1],[37,1],[37,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:(!Array.isArray(a[s])||a[s].length>0)&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 198:this.$=a[s];break;case 5:case 33:case 34:case 35:case 36:case 37:this.$=[];break;case 13:r.setDirection(`TB`),this.$=`TB`;break;case 14:r.setDirection(a[s-1]),this.$=a[s-1];break;case 32:this.$=a[s-1].nodes;break;case 38:this.$=r.addSubGraph(a[s-6],a[s-1],a[s-4],`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-6],a[s-4],o[s-8],o[s]);break;case 39:this.$=r.addSubGraph(a[s-7],a[s-1],a[s-5],`flow`),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-3],o[s-3]),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-7],a[s-5],o[s-9],o[s]);break;case 40:this.$=r.addSubGraph(a[s-3],a[s-1],{text:``,type:`text`},`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-3],{text:``,type:`text`},o[s-5],o[s]);break;case 41:this.$=r.addSubGraph(a[s-4],a[s-1],{text:``,type:`text`},`flow`),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-3],o[s-3]),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-4],{text:``,type:`text`},o[s-6],o[s]);break;case 42:this.$=r.addSubGraph(void 0,a[s-1],void 0,`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(void 0,void 0,o[s-3],o[s]);break;case 43:r.addGlobal(a[s-1]),this.$=[];break;case 44:this.$=r.addConnector(a[s-4],a[s-2]),r.addConnectorMapping&&r.addConnectorMapping(a[s-4],a[s-2],o[s-6],o[s]);break;case 45:this.$=r.addConnector(a[s-5],a[s-3]),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-1],o[s-1]),r.addConnectorMapping&&r.addConnectorMapping(a[s-5],a[s-3],o[s-7],o[s]);break;case 46:this.$=r.addConnector(a[s-1],{text:``,type:`text`}),r.addConnectorMapping&&r.addConnectorMapping(a[s-1],{text:``,type:`text`},o[s-3],o[s]);break;case 47:this.$=r.addConnector(a[s-2],{text:``,type:`text`}),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-1],o[s-1]),r.addConnectorMapping&&r.addConnectorMapping(a[s-2],{text:``,type:`text`},o[s-4],o[s]);break;case 49:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 50:case 51:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 56:this.$=a[s-1]+a[s];break;case 57:this.$=a[s];break;case 58:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s],o[s]),r.extendVertexMapping&&r.extendVertexMapping(a[s-1][a[s-1].length-1],o[s]),r.addLink(a[s-3].stmt,a[s-1],a[s-2]),r.addEdgeMapping&&r.addEdgeMapping(a[s-3].stmt,a[s-1],a[s-2],this._$),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 59:r.addLink(a[s-2].stmt,a[s],a[s-1]),r.addEdgeMapping&&r.addEdgeMapping(a[s-2].stmt,a[s],a[s-1],this._$),this.$={stmt:a[s],nodes:a[s].concat(a[s-2].nodes)};break;case 60:r.addLink(a[s-3].stmt,a[s-1],a[s-2]),r.addEdgeMapping&&r.addEdgeMapping(a[s-3].stmt,a[s-1],a[s-2],this._$),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 61:this.$={stmt:a[s-1],nodes:a[s-1]};break;case 62:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s],o[s]),r.extendVertexMapping&&r.extendVertexMapping(a[s-1][a[s-1].length-1],o[s]),this.$={stmt:a[s-1],nodes:a[s-1],shapeData:a[s]};break;case 63:this.$={stmt:a[s],nodes:a[s]};break;case 64:this.$=[a[s]];break;case 65:r.addVertex(a[s-5][a[s-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s-4],o[s-4]),r.extendVertexMapping&&r.extendVertexMapping(a[s-5][a[s-5].length-1],o[s-4]),this.$=a[s-5].concat(a[s]);break;case 66:this.$=a[s-4].concat(a[s]);break;case 67:this.$=a[s];break;case 68:this.$=a[s-2],r.setClass(a[s-2],a[s]);break;case 69:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`square`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`square`,this._$);break;case 70:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`doublecircle`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`doublecircle`,this._$);break;case 71:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`circle`),r.addVertexMapping&&r.addVertexMapping(a[s-5],a[s-2],`circle`,this._$);break;case 72:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`ellipse`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`ellipse`,this._$);break;case 73:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`stadium`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`stadium`,this._$);break;case 74:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`subroutine`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`subroutine`,this._$);break;case 75:this.$=a[s-7],r.addVertex(a[s-7],a[s-1],`rect`,void 0,void 0,void 0,Object.fromEntries([[a[s-5],a[s-3]]])),r.addVertexMapping&&r.addVertexMapping(a[s-7],a[s-1],`rect`,this._$);break;case 76:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`cylinder`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`cylinder`,this._$);break;case 77:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`round`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`round`,this._$);break;case 78:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`diamond`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`diamond`,this._$);break;case 79:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`hexagon`),r.addVertexMapping&&r.addVertexMapping(a[s-5],a[s-2],`hexagon`,this._$);break;case 80:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`odd`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`odd`,this._$);break;case 81:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`trapezoid`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`trapezoid`,this._$);break;case 82:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`inv_trapezoid`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`inv_trapezoid`,this._$);break;case 83:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_right`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`lean_right`,this._$);break;case 84:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_left`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`lean_left`,this._$);break;case 85:this.$=a[s],r.addVertex(a[s]),r.addVertexMapping&&r.addVertexMapping(a[s],void 0,void 0,this._$);break;case 86:a[s-1].text=a[s],this.$=a[s-1];break;case 87:case 88:a[s-2].text=a[s-1],this.$=a[s-2];break;case 89:this.$=a[s];break;case 90:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,text:a[s-1]};break;case 91:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,text:a[s-1],id:a[s-3]};break;case 92:this.$={text:a[s],type:`text`};break;case 93:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 94:this.$={text:a[s],type:`string`};break;case 95:this.$={text:a[s],type:`markdown`};break;case 96:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic};break;case 97:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,id:a[s-1]};break;case 98:this.$=a[s-1];break;case 99:this.$={text:a[s],type:`text`};break;case 100:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 101:this.$={text:a[s],type:`string`};break;case 102:case 119:this.$={text:a[s],type:`markdown`};break;case 116:this.$={text:a[s],type:`text`};break;case 117:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 118:this.$={text:a[s],type:`text`};break;case 120:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 121:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 122:case 130:this.$=a[s-1],r.setClickEvent(a[s-1],a[s]);break;case 123:case 131:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 124:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 125:this.$=a[s-4],r.setClickEvent(a[s-4],a[s-3],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 126:this.$=a[s-2],r.setLink(a[s-2],a[s]);break;case 127:this.$=a[s-4],r.setLink(a[s-4],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 128:this.$=a[s-4],r.setLink(a[s-4],a[s-2],a[s]);break;case 129:this.$=a[s-6],r.setLink(a[s-6],a[s-4],a[s]),r.setTooltip(a[s-6],a[s-2]);break;case 132:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 133:this.$=a[s-3],r.setLink(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 134:this.$=a[s-3],r.setLink(a[s-3],a[s-2],a[s]);break;case 135:this.$=a[s-5],r.setLink(a[s-5],a[s-4],a[s]),r.setTooltip(a[s-5],a[s-2]);break;case 136:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 137:this.$=a[s-4],r.updateLink([a[s-2]],a[s]);break;case 138:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 139:this.$=a[s-8],r.updateLinkInterpolate([a[s-6]],a[s-2]),r.updateLink([a[s-6]],a[s]);break;case 140:this.$=a[s-8],r.updateLinkInterpolate(a[s-6],a[s-2]),r.updateLink(a[s-6],a[s]);break;case 141:this.$=a[s-6],r.updateLinkInterpolate([a[s-4]],a[s]);break;case 142:this.$=a[s-6],r.updateLinkInterpolate(a[s-4],a[s]);break;case 143:case 145:this.$=[a[s]];break;case 144:case 146:a[s-2].push(a[s]),this.$=a[s-2];break;case 148:this.$=a[s-1]+a[s];break;case 196:this.$=a[s];break;case 197:this.$=a[s-1]+``+a[s];break;case 199:this.$=a[s-1]+``+a[s];break;case 200:this.$={stmt:`dir`,value:`TB`};break;case 201:this.$={stmt:`dir`,value:`BT`};break;case 202:this.$={stmt:`dir`,value:`RL`};break;case 203:this.$={stmt:`dir`,value:`LR`};break;case 204:this.$={stmt:`dir`,value:`TD`}}},`anonymous`),table:[{3:1,4:2,8:t,10:r,11:i,13:a},{1:[3]},e(o,s,{5:7}),{4:8,8:t,10:r,11:i,13:a},{4:9,8:t,10:r,11:i,13:a},{4:10,8:t,10:r,11:i,13:a},{14:[1,11],15:[1,12]},{1:[2,1],6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(o,[2,10]),e(o,[2,11]),e(o,[2,12]),e(o,[2,13]),{8:[1,63],9:[1,60],10:[1,61],11:L,16:59,19:62},e(R,[2,3]),e(R,[2,4]),e(R,[2,5]),e(R,[2,6]),e(R,[2,7]),e(R,[2,8]),e(R,[2,9]),{8:z,9:B,10:V,12:H,22:65,44:66,75:71,78:[1,72],80:[1,74],81:[1,73]},{8:z,9:B,10:V,12:H,22:75},{8:z,9:B,10:V,12:H,22:76},{8:z,9:B,10:V,12:H,22:77},{8:z,9:B,10:V,12:H,22:78},{8:z,9:B,10:V,12:H,22:79},{8:z,9:B,10:V,11:[1,80],12:H,22:81},{8:z,9:B,10:V,12:H,22:82},{11:[1,83]},e(R,[2,48]),{39:[1,84]},{41:[1,85]},e(R,[2,51]),e(re,[2,63],{19:86,34:87,11:L,43:ie}),{11:[1,89]},{11:[1,90]},{11:[1,91]},{11:[1,92]},{15:ae,47:oe,63:se,83:[1,96],92:ce,98:[1,93],100:[1,94],104:95,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},e(R,[2,200]),e(R,[2,201]),e(R,[2,202]),e(R,[2,203]),e(R,[2,204]),e(ge,[2,64]),e(ge,[2,67],{49:[1,109]}),e(U,[2,85],{116:122,30:[1,110],47:y,51:[1,111],53:[1,112],55:[1,113],57:[1,114],59:[1,115],61:[1,116],63:b,66:[1,117],68:[1,118],70:[1,119],71:[1,120],73:[1,121],92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),e(W,[2,196]),e(W,[2,157]),e(W,[2,158]),e(W,[2,159]),e(W,[2,160]),e(W,[2,161]),e(W,[2,162]),e(W,[2,163]),e(W,[2,164]),e(W,[2,165]),e(W,[2,166]),e(W,[2,167]),e(o,[2,14]),e(o,[2,20]),e(o,[2,21]),{10:[1,123]},e(o,[2,23]),e(_e,[2,31],{19:124,11:L}),e(R,[2,32]),{45:125,46:44,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(R,[2,52]),e(R,[2,53]),e(R,[2,54]),e(R,[2,55]),e(ve,[2,89],{76:126,65:[1,128],77:[1,127]}),{79:129,82:130,83:ye,84:be,119:xe,122:Se},{78:[1,135],80:[1,136]},e(Ce,[2,96]),e(R,[2,33]),e(R,[2,34]),e(R,[2,35]),e(R,[2,36]),e(R,[2,37]),{11:we,13:Te,15:Ee,28:De,29:137,33:Oe,35:ke,36:Ae,47:je,63:Me,78:Ne,83:Pe,84:Fe,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:138,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e(Ye,s,{5:165}),e(Ye,s,{5:166}),{11:we,13:Te,15:Ee,28:De,29:167,33:Oe,35:ke,36:Ae,47:je,63:Me,78:Ne,83:Pe,84:Fe,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:138,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e(R,[2,49]),e(R,[2,50]),e(re,[2,61],{47:Xe}),e(re,[2,62],{19:169,11:L,43:Ze}),e(ge,[2,57]),{47:y,50:171,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{105:[1,172],106:173,108:[1,174]},{47:y,50:175,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{47:y,50:176,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,122],{11:[1,177],99:[1,178]}),{83:[1,179]},e(G,[2,130],{123:181,11:[1,180],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,132],{11:[1,182]}),e(K,[2,198]),e(K,[2,185]),e(K,[2,186]),e(K,[2,187]),e(K,[2,188]),e(K,[2,189]),e(K,[2,190]),e(K,[2,191]),e(K,[2,192]),e(K,[2,193]),e(K,[2,194]),e(K,[2,195]),{47:y,50:183,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{31:184,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:192,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:194,53:[1,193],70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:195,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:196,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:197,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{112:[1,198]},{31:199,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:200,68:[1,201],70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:202,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:203,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:204,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(W,[2,197]),e(o,[2,22]),e(_e,[2,30]),e(re,[2,59],{34:205,19:206,11:L,43:ie}),e(ve,[2,86],{11:[1,207]}),{11:[1,208]},{31:209,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{80:[1,210],82:211,119:xe,122:Se},e(Qe,[2,92]),e(Qe,[2,94]),e(Qe,[2,95]),e(Qe,[2,183]),e(Qe,[2,184]),{79:212,82:130,83:ye,84:be,119:xe,122:Se},e(Ce,[2,97]),{8:z,9:B,10:V,11:we,12:H,13:Te,15:Ee,22:214,28:De,30:[1,213],33:Oe,34:215,35:ke,36:Ae,43:ie,47:je,63:Me,78:Ne,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:216,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e($,[2,116]),e($,[2,118]),e($,[2,119]),e($,[2,172]),e($,[2,173]),e($,[2,174]),e($,[2,175]),e($,[2,176]),e($,[2,177]),e($,[2,178]),e($,[2,179]),e($,[2,180]),e($,[2,181]),e($,[2,182]),e($,[2,103]),e($,[2,104]),e($,[2,105]),e($,[2,106]),e($,[2,107]),e($,[2,108]),e($,[2,109]),e($,[2,110]),e($,[2,111]),e($,[2,112]),e($,[2,113]),e($,[2,114]),e($,[2,115]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,217],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,218],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{8:z,9:B,10:V,11:we,12:H,13:Te,15:Ee,22:220,28:De,30:[1,219],33:Oe,34:221,35:ke,36:Ae,43:ie,47:je,63:Me,78:Ne,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:216,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},{11:L,19:222},{47:[1,223]},e(ge,[2,56]),{11:[1,224],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{11:[1,225]},{11:[1,226],109:[1,227]},e($e,[2,143]),{11:[1,228],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{11:[1,229],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{83:[1,230]},e(G,[2,124],{11:[1,231]}),e(G,[2,126],{11:[1,232]}),{83:[1,233]},e(K,[2,199]),{83:[1,234],101:[1,235]},e(ge,[2,68],{116:122,47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),{32:[1,236],70:q,85:237,119:X,120:Z,121:Q},e(et,[2,99]),e(et,[2,101]),e(et,[2,102]),e(et,[2,168]),e(et,[2,169]),e(et,[2,170]),e(et,[2,171]),{52:[1,238],70:q,85:237,119:X,120:Z,121:Q},{31:239,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{54:[1,240],70:q,85:237,119:X,120:Z,121:Q},{56:[1,241],70:q,85:237,119:X,120:Z,121:Q},{58:[1,242],70:q,85:237,119:X,120:Z,121:Q},{60:[1,243],70:q,85:237,119:X,120:Z,121:Q},{63:[1,244]},{67:[1,245],70:q,85:237,119:X,120:Z,121:Q},{69:[1,246],70:q,85:237,119:X,120:Z,121:Q},{31:247,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{32:[1,248],70:q,85:237,119:X,120:Z,121:Q},{70:q,72:[1,249],74:[1,250],85:237,119:X,120:Z,121:Q},{70:q,72:[1,252],74:[1,251],85:237,119:X,120:Z,121:Q},e(re,[2,58],{19:169,11:L,43:Ze}),e(re,[2,60],{47:Xe}),e(ve,[2,88]),e(ve,[2,87]),{65:[1,253],70:q,85:237,119:X,120:Z,121:Q},e(ve,[2,90]),e(Qe,[2,93]),{80:[1,254],82:211,119:xe,122:Se},{31:255,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(Ye,s,{5:256}),{8:z,9:B,10:V,12:H,22:257,43:Ze},e($,[2,117]),e(R,[2,42]),e(R,[2,43]),{31:258,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(R,[2,46]),{8:z,9:B,10:V,12:H,22:259,43:Ze},{46:260,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{11:L,19:261},{11:tt,63:nt,87:rt,95:262,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:273,107:[1,274],108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:275,107:[1,276],108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{108:[1,277]},{11:tt,63:nt,87:rt,95:278,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{47:y,50:279,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,123]),{83:[1,280]},{83:[1,281],101:[1,282]},e(G,[2,131]),e(G,[2,133],{11:[1,283]}),e(G,[2,134]),e(U,[2,69]),e(et,[2,100]),e(U,[2,70]),{54:[1,284],70:q,85:237,119:X,120:Z,121:Q},e(U,[2,77]),e(U,[2,72]),e(U,[2,73]),e(U,[2,74]),{112:[1,285]},e(U,[2,76]),e(U,[2,78]),{69:[1,286],70:q,85:237,119:X,120:Z,121:Q},e(U,[2,80]),e(U,[2,81]),e(U,[2,83]),e(U,[2,82]),e(U,[2,84]),e([11,47,63,92,105,108,109,112,114,117,118,119],[2,98]),e(ve,[2,91]),{32:[1,287],70:q,85:237,119:X,120:Z,121:Q},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,288],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(Ye,s,{5:289}),{32:[1,290],70:q,85:237,119:X,120:Z,121:Q},e(R,[2,47]),e(ge,[2,66]),{46:291,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,136],{109:lt}),e(ut,[2,145],{111:293,11:tt,63:nt,87:rt,108:it,112:at,113:ot,114:st,115:ct}),e(dt,[2,147]),e(dt,[2,149]),e(dt,[2,150]),e(dt,[2,151]),e(dt,[2,152]),e(dt,[2,153]),e(dt,[2,154]),e(dt,[2,155]),e(dt,[2,156]),e(G,[2,137],{109:lt}),{11:[1,294]},e(G,[2,138],{109:lt}),{11:[1,295]},e($e,[2,144]),e(G,[2,120],{109:lt}),e(G,[2,121],{116:122,47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),e(G,[2,125]),e(G,[2,127],{11:[1,296]}),e(G,[2,128]),{101:[1,297]},{54:[1,298]},{65:[1,299]},{69:[1,300]},{8:z,9:B,10:V,12:H,22:301,34:302,43:ie},e(R,[2,40]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,303],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{8:z,9:B,10:V,12:H,22:304,34:305,43:ie},e(ge,[2,65]),{11:tt,63:nt,87:rt,108:it,110:306,111:264,112:at,113:ot,114:st,115:ct},e(dt,[2,148]),{15:ae,47:oe,63:se,92:ce,104:307,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},{15:ae,47:oe,63:se,92:ce,104:308,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},{101:[1,309]},e(G,[2,135]),e(U,[2,71]),{31:310,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(U,[2,79]),e(Ye,s,{5:311}),{8:z,9:B,10:V,12:H,22:312,43:Ze},e(R,[2,41]),e(R,[2,44]),{8:z,9:B,10:V,12:H,22:313,43:Ze},e(ut,[2,146],{111:293,11:tt,63:nt,87:rt,108:it,112:at,113:ot,114:st,115:ct}),e(G,[2,141],{123:181,11:[1,314],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,142],{123:181,11:[1,315],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,129]),{32:[1,316],70:q,85:237,119:X,120:Z,121:Q},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,317],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(Ye,s,{5:318}),e(R,[2,45]),{11:tt,63:nt,87:rt,95:319,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:320,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},e(U,[2,75]),e(R,[2,38]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,321],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(G,[2,139],{109:lt}),e(G,[2,140],{109:lt}),e(R,[2,39])],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};ft.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),38;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),40;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return this.pushState(`shapeData`),t.yytext=``,43;case 8:return this.pushState(`shapeDataStr`),43;case 9:return this.popState(),43;case 10:return t.yytext=t.yytext.replace(/\n\s*/g,`
    `),43;case 11:return 43;case 12:this.popState();break;case 13:this.begin(`callbackname`);break;case 14:this.popState();break;case 15:this.popState(),this.begin(`callbackargs`);break;case 16:return 98;case 17:this.popState();break;case 18:return 99;case 19:return`MD_STR`;case 20:this.popState();break;case 21:this.begin(`md_string`);break;case 22:return`STR`;case 23:this.popState();break;case 24:this.pushState(`string`);break;case 25:return 87;case 26:return 105;case 27:return 88;case 28:return 107;case 29:return 89;case 30:return 90;case 31:return 100;case 32:this.begin(`click`);break;case 33:this.popState();break;case 34:return 91;case 35:return e.lex.firstGraph()&&this.begin(`dir`),13;case 36:return 28;case 37:return 36;case 38:return 35;case 39:return 33;case 40:return 101;case 41:return 101;case 42:return 101;case 43:return 101;case 44:return this.popState(),14;case 45:return this.popState(),15;case 46:return this.popState(),15;case 47:return this.popState(),15;case 48:return this.popState(),15;case 49:return this.popState(),15;case 50:return this.popState(),15;case 51:return this.popState(),15;case 52:return this.popState(),15;case 53:return this.popState(),15;case 54:return this.popState(),15;case 55:return 124;case 56:return 125;case 57:return 126;case 58:return 127;case 59:return 128;case 60:return 81;case 61:return 108;case 62:return 114;case 63:return 49;case 64:return 63;case 65:return 47;case 66:return 9;case 67:return 109;case 68:return 118;case 69:return this.popState(),80;case 70:return this.pushState(`edgeText`),78;case 71:return 122;case 72:return 80;case 73:break;case 74:return this.popState(),56;case 75:return`TEXT`;case 76:return this.pushState(`ellipseText`),55;case 77:return this.popState(),58;case 78:return this.pushState(`text`),57;case 79:return this.popState(),60;case 80:return this.pushState(`text`),59;case 81:return 61;case 82:return this.pushState(`text`),70;case 83:return this.popState(),67;case 84:return this.pushState(`text`),66;case 85:return this.popState(),52;case 86:return this.pushState(`text`),51;case 87:break;case 88:return this.popState(),72;case 89:return this.popState(),74;case 90:return 120;case 91:return this.pushState(`trapText`),71;case 92:return this.pushState(`trapText`),73;case 93:return 121;case 94:return 70;case 95:return 93;case 96:return`SEP`;case 97:return 92;case 98:return 118;case 99:return 114;case 100:return 47;case 101:return 8;case 102:return 112;case 103:return 117;case 104:return 119;case 105:return this.popState(),65;case 106:return this.pushState(`text`),65;case 107:return this.popState(),54;case 108:return this.pushState(`text`),53;case 109:return this.popState(),32;case 110:return this.pushState(`text`),30;case 111:return this.popState(),69;case 112:return this.pushState(`text`),68;case 113:break;case 114:return`TEXT`;case 115:return`QUOTE`;case 116:return 10;case 117:return 11;case 118:return 12}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:agentflow-beta\b)/,/^(?:flow\b)/,/^(?:connector\b)/,/^(?:global\b[ \t]*)/,/^(?:end\b[ \t]*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*--+[x>]\s*)/,/^(?:\s*--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*-\.+-\s*)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|(?:[^\\\[\]\(\)\{\}\/%]+|(?!))+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:[ \t]*%%(?!\{)[^\n]*)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:(?:[^\[\]\(\)\{\}\|\"%]+|(?!))+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeData:{rules:[8,11,12,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackargs:{rules:[17,18,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackname:{rules:[14,15,16,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},href:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},click:{rules:[21,24,33,34,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},edgeText:{rules:[21,24,69,71,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},trapText:{rules:[21,24,76,78,80,84,86,87,88,89,90,91,92,106,108,110,112],inclusive:!1},ellipseText:{rules:[21,24,73,74,75,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},text:{rules:[21,24,76,77,78,79,80,83,84,85,86,91,92,105,106,107,108,109,110,111,112,113,114],inclusive:!1},vertex:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr:{rules:[3,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_title:{rules:[1,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},md_string:{rules:[19,20,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},string:{rules:[21,22,23,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,72,76,78,80,81,82,84,86,91,92,93,94,95,96,97,98,99,100,101,102,103,104,106,108,110,112,115,116,117,118],inclusive:!0}}}})();function pt(){this.yy={}}return n(pt,`Parser`),pt.prototype=ft,ft.Parser=pt,new pt})();fe.parser=fe;var pe=fe,me=Object.assign({},pe);me.parse=e=>{let t=e.replace(/}[^\S\n]*\n/g,`} +`);return pe.parse(t)};var he=me,ge=n(e=>{let{theme:t,bkgColorArray:r,borderColorArray:i}=e;if(!y(t,i))return``;let a=x(e.look),o=S(r),s=b(e.THEME_COLOR_LIMIT,i),c=n(e=>i[e%i.length],`border`),l=n(e=>o?`fill: ${r[e%r.length]};`:``,`fill`),u=``;for(let e of B){let t=L.get(e),n=`[data-look="${a}"].node.${z(e)}`;u+=` + + ${n} rect, + ${n} path, + ${n} polygon { + stroke: ${c(t)}; + ${l(t)} + } +`}for(let e=0;e`${r} ${e}, ${i} ${e}`,`rule`);u+=` + + ${o(`rect`)}, + ${o(`path`)} { + stroke: ${c(t)}; + ${l(t)} + } +`}return u},`genColor`),U=n((e,t)=>{let n=g,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return c(r,i,a,t)},`fade`),W={parser:he,get db(){return new ue},renderer:de,styles:n(e=>`${ge(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}px; + } + .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label { + text-anchor: middle; + } + .node .katex path { + fill: ${e.nodeTextColor||e.textColor}; + stroke: ${e.nodeTextColor||e.textColor}; + stroke-width: 1px; + } + + .rough-node .label,.node .label, .image-shape .label, .icon-shape .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + + .root .anchor path { + fill: ${e.lineColor} !important; + stroke-width: 0; + stroke: ${e.lineColor}; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth??2}px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${U(e.edgeLabelBackground,.5)}; + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .flow-cluster rect { + fill: none; + stroke: ${e.clusterBorder}; + stroke-width: 0.75px; + } + + .node .collapsed-indicator { + fill: ${e.nodeBorder}; + stroke: none; + stroke-width: 0; + opacity: 0.5; + } + + .node .collapsed-separator { + stroke-width: 0.75px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .agentflowTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + + rect.text { + fill: none; + stroke-width: 0; + } + + .icon-shape, .image-shape { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + padding: 2px; + } + .label rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + ${O()} +`,`getStyles`),init:n(e=>{e.agentflow??={},e.layout&&r({layout:e.layout}),e.flowchart??={},e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,r({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}})},`init`)};export{W as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-3UASUU5V-Dv_f5rjj.js b/frontend/dist/assets/diagram-3UASUU5V-Dv_f5rjj.js new file mode 100644 index 0000000..30cbcb6 --- /dev/null +++ b/frontend/dist/assets/diagram-3UASUU5V-Dv_f5rjj.js @@ -0,0 +1,24 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as r,H as i,U as a,a as o,b as s,c,f as l,q as u,v as d,w as f,y as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./ordinal-BDEzSJ7C.js";import{t as h}from"./defaultLocale-BFoDCU3G.js";import{i as g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as _,n as v}from"./chunk-7PRAP22T-DSs4vaIy.js";import{y}from"./index-DoQkmpth.js";import{n as b}from"./mermaid-parser.core-CUrDj5TF.js";import{t as x}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as S}from"./chunk-WEXAMYUT-I3m-hOmT.js";function C(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function w(){return this.eachAfter(C)}function T(e,t){let n=-1;for(let r of this)e.call(t,r,++n,this);return this}function E(e,t){for(var n=this,r=[n],i,a,o=-1;n=r.pop();)if(e.call(t,n,++o,this),i=n.children)for(a=i.length-1;a>=0;--a)r.push(i[a]);return this}function D(e,t){for(var n=this,r=[n],i=[],a,o,s,c=-1;n=r.pop();)if(i.push(n),a=n.children)for(o=0,s=a.length;o=0;)n+=r[i].value;t.value=n})}function A(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function j(e){for(var t=this,n=M(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function M(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function N(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function P(){return Array.from(this)}function F(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function I(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*L(){var e=this,t,n=[e],r,i,a;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,a=r.length;i=0;--s)i.push(a=o[s]=new W(o[s])),a.parent=r,a.depth=r.depth+1;return n.eachBefore(U)}function z(){return R(this).eachBefore(H)}function B(e){return e.children}function V(e){return Array.isArray(e)?e[1]:null}function H(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function U(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function W(e){this.data=e,this.depth=this.height=0,this.parent=null}W.prototype=R.prototype={constructor:W,count:w,each:T,eachAfter:D,eachBefore:E,find:O,sum:k,sort:A,path:j,ancestors:N,descendants:P,leaves:F,links:I,copy:z,[Symbol.iterator]:L};function G(e){if(typeof e!=`function`)throw Error();return e}function K(){return 0}function q(e){return function(){return e}}function ee(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function te(e,t,n,r,i){for(var a=e.children,o,s=-1,c=a.length,l=e.value&&(r-t)/e.value;++sv&&(v=l),S=g*g*x,y=Math.max(v/S,S/_),y>b){g-=l;break}b=y}o.push(c={value:g,dice:p1?t:1)},n})(re);function oe(){var e=ae,t=!1,n=1,r=1,i=[0],a=K,o=K,s=K,c=K,l=K;function u(e){return e.x0=e.y0=0,e.x1=n,e.y1=r,e.eachBefore(d),i=[0],t&&e.eachBefore(ee),e}function d(t){var n=i[t.depth],r=t.x0+n,u=t.y0+n,d=t.x1-n,f=t.y1-n;d{v(e)&&(n?.textStyles?n.textStyles.push(e):n.textStyles=[e]),n?.styles?n.styles.push(e):n.styles=[e]}),this.classes.set(e,n)}getClasses(){return this.classes}getStylesForClass(e){return this.classes.get(e)?.styles??[]}clear(){o(),this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.root=void 0}};function Y(e){if(!e.length)return[];let t=[],n=[];return e.forEach(e=>{let r={name:e.name,children:e.type===`Leaf`?void 0:[]};for(r.classSelector=e?.classSelector,e?.cssCompiledStyles&&(r.cssCompiledStyles=e.cssCompiledStyles),e.type===`Leaf`&&e.value!==void 0&&(r.value=e.value);n.length>0&&n[n.length-1].level>=e.level;)n.pop();if(n.length===0)t.push(r);else{let e=n[n.length-1].node;e.children?e.children.push(r):e.children=[r]}e.type!==`Leaf`&&n.push({node:r,level:e.level})}),t}n(Y,`buildHierarchy`);var se=n((e,t)=>{x(e,t);let r=[];for(let n of e.TreemapRows??[])n.$type===`ClassDefStatement`&&t.addClass(n.className??``,n.styleText??``);for(let n of e.TreemapRows??[]){let e=n.item;if(!e)continue;let i=n.indent?parseInt(n.indent):0,a=ce(e),o=e.classSelector?t.getStylesForClass(e.classSelector):[],s=o.length>0?o:void 0,c={level:i,name:a,type:e.$type,value:e.value,classSelector:e.classSelector,cssCompiledStyles:s};r.push(c)}let i=Y(r),a=n((e,n)=>{for(let r of e)t.addNode(r,n),r.children&&r.children.length>0&&a(r.children,n+1)},`addNodesRecursively`);a(i,0)},`populate`),ce=n(e=>e.name?String(e.name):``,`getItemName`),X={parser:{yy:void 0},parse:n(async t=>{try{let n=await b(`treemap`,t);e.debug(`Treemap AST:`,n);let r=X.parser?.yy;if(!(r instanceof J))throw Error(`parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);se(n,r)}catch(t){throw e.error(`Error parsing treemap:`,t),t}},`parse`)},Z=10,Q=10,$=25,le={draw:n((r,i,a,o)=>{let l=o.db,u=l.getConfig(),d=u.padding??Z,f=l.getDiagramTitle(),p=l.getRoot(),{themeVariables:g}=s();if(!p)return;let v=f?30:0,b=y(i),x=u.nodeWidth?u.nodeWidth*Q:960,C=u.nodeHeight?u.nodeHeight*Q:500,w=x,T=C+v;b.attr(`viewBox`,`0 0 ${w} ${T}`),c(b,T,w,u.useMaxWidth);let E;try{let e=u.valueFormat||`,`;if(e===`$0,0`)E=n(e=>`$`+h(`,`)(e),`valueFormat`);else if(e.startsWith(`$`)&&e.includes(`,`)){let t=/\.\d+/.exec(e),r=t?t[0]:``;E=n(e=>`$`+h(`,`+r)(e),`valueFormat`)}else if(e.startsWith(`$`)){let t=e.substring(1);E=n(e=>`$`+h(t||``)(e),`valueFormat`)}else E=h(e)}catch(t){e.error(`Error creating format function:`,t),E=h(`,`)}let D=m().range([`transparent`,g.cScale0,g.cScale1,g.cScale2,g.cScale3,g.cScale4,g.cScale5,g.cScale6,g.cScale7,g.cScale8,g.cScale9,g.cScale10,g.cScale11]),O=m().range([`transparent`,g.cScalePeer0,g.cScalePeer1,g.cScalePeer2,g.cScalePeer3,g.cScalePeer4,g.cScalePeer5,g.cScalePeer6,g.cScalePeer7,g.cScalePeer8,g.cScalePeer9,g.cScalePeer10,g.cScalePeer11]),k=m().range([g.cScaleLabel0,g.cScaleLabel1,g.cScaleLabel2,g.cScaleLabel3,g.cScaleLabel4,g.cScaleLabel5,g.cScaleLabel6,g.cScaleLabel7,g.cScaleLabel8,g.cScaleLabel9,g.cScaleLabel10,g.cScaleLabel11]);f&&b.append(`text`).attr(`x`,w/2).attr(`y`,v/2).attr(`class`,`treemapTitle`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(f);let A=b.append(`g`).attr(`transform`,`translate(0, ${v})`).attr(`class`,`treemapContainer`),j=R(p).sum(e=>e.value??0).sort((e,t)=>(t.value??0)-(e.value??0)),M=oe().size([x,C]).paddingTop(e=>e.children&&e.children.length>0?$+Q:0).paddingInner(d).paddingLeft(e=>e.children&&e.children.length>0?Q:0).paddingRight(e=>e.children&&e.children.length>0?Q:0).paddingBottom(e=>e.children&&e.children.length>0?Q:0).round(!0)(j),N=M.descendants().filter(e=>e.children&&e.children.length>0),P=A.selectAll(`.treemapSection`).data(N).enter().append(`g`).attr(`class`,`treemapSection`).attr(`transform`,e=>`translate(${e.x0},${e.y0})`);P.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,$).attr(`class`,`treemapSectionHeader`).attr(`fill`,`none`).attr(`fill-opacity`,.6).attr(`stroke-width`,.6).attr(`style`,e=>e.depth===0?`display: none;`:``),P.append(`clipPath`).attr(`id`,(e,t)=>`clip-section-${i}-${t}`).append(`rect`).attr(`width`,e=>Math.max(0,e.x1-e.x0-12)).attr(`height`,$),P.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,e=>e.y1-e.y0).attr(`class`,(e,t)=>`treemapSection section${t}`).attr(`fill`,e=>D(e.data.name)).attr(`fill-opacity`,.6).attr(`stroke`,e=>O(e.data.name)).attr(`stroke-width`,2).attr(`stroke-opacity`,.4).attr(`style`,e=>{if(e.depth===0)return`display: none;`;let t=_({cssCompiledStyles:e.data.cssCompiledStyles});return t.nodeStyles+`;`+t.borderStyles.join(`;`)}),P.append(`text`).attr(`class`,`treemapSectionLabel`).attr(`x`,6).attr(`y`,$/2).attr(`dominant-baseline`,`middle`).text(e=>e.depth===0?``:e.data.name).attr(`font-weight`,`bold`).attr(`clip-path`,(e,t)=>`url(#clip-section-${i}-${t})`).attr(`style`,e=>e.depth===0?`display: none;`:`dominant-baseline: middle; font-size: 12px; fill:`+k(e.data.name)+`; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).each(function(e){if(e.depth===0)return;let n=t(this),r=e.data.name;n.text(r);let i=e.x1-e.x0,a;a=u.showValues!==!1&&e.value?i-10-30-10-6:i-6-6;let o=Math.max(15,a),s=n.node();if(s.getComputedTextLength()>o){let e=r;for(;e.length>0;){if(e=r.substring(0,e.length-1),e.length===0){n.text(`...`),s.getComputedTextLength()>o&&n.text(``);break}if(n.text(e+`...`),s.getComputedTextLength()<=o)break}}}),u.showValues!==!1&&P.append(`text`).attr(`class`,`treemapSectionValue`).attr(`x`,e=>e.x1-e.x0-10).attr(`y`,$/2).attr(`text-anchor`,`end`).attr(`dominant-baseline`,`middle`).text(e=>e.value?E(e.value):``).attr(`font-style`,`italic`).attr(`style`,e=>e.depth===0?`display: none;`:`text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:`+k(e.data.name)+`; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`));let F=M.leaves(),I=F.length>20,L=I?16:38,z=I?14:28,B=I?4:8,V=I?4:6,H=I?2:4,U=I?8:10,W=I?1:2,G=A.selectAll(`.treemapLeafGroup`).data(F).enter().append(`g`).attr(`class`,(e,t)=>`treemapNode treemapLeafGroup leaf${t}${e.data.classSelector?` ${e.data.classSelector}`:``}x`).attr(`transform`,e=>`translate(${e.x0},${e.y0})`);G.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,e=>e.y1-e.y0).attr(`class`,`treemapLeaf`).attr(`fill`,e=>e.parent?D(e.parent.data.name):D(e.data.name)).attr(`style`,e=>_({cssCompiledStyles:e.data.cssCompiledStyles}).nodeStyles).attr(`fill-opacity`,.3).attr(`stroke`,e=>e.parent?D(e.parent.data.name):D(e.data.name)).attr(`stroke-width`,3),G.append(`clipPath`).attr(`id`,(e,t)=>`clip-${i}-${t}`).append(`rect`).attr(`width`,e=>Math.max(0,e.x1-e.x0-4)).attr(`height`,e=>Math.max(0,e.y1-e.y0-4)),G.append(`text`).attr(`class`,`treemapLabel`).attr(`x`,e=>(e.x1-e.x0)/2).attr(`y`,e=>(e.y1-e.y0)/2).attr(`style`,e=>`text-anchor: middle; dominant-baseline: middle; font-size: ${L}px;fill:`+k(e.data.name)+`;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).attr(`clip-path`,(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.data.name).each(function(e){let n=t(this),r=e.x1-e.x0,i=e.y1-e.y0,a=n.node(),o=r-2*H,s=i-2*H;if(oo&&c>B;)c--,n.style(`font-size`,`${c}px`);let u=Math.max(V,Math.min(z,Math.round(c*l))),d=c+W+u;for(;d>s&&c>B&&(c--,u=Math.max(V,Math.min(z,Math.round(c*l))),!(uo||c(e.x1-e.x0)/2).attr(`y`,function(e){return(e.y1-e.y0)/2}).attr(`style`,e=>`text-anchor: middle; dominant-baseline: hanging; font-size: ${z}px;fill:`+k(e.data.name)+`;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).attr(`clip-path`,(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.value?E(e.value):``).each(function(e){let n=t(this),r=this.parentNode;if(!r){n.style(`display`,`none`);return}let i=t(r).select(`.treemapLabel`);if(i.empty()||i.style(`display`)===`none`){n.style(`display`,`none`);return}let a=parseFloat(i.style(`font-size`)),o=Math.max(V,Math.min(z,Math.round(a*.6)));n.style(`font-size`,`${o}px`);let s=(e.y1-e.y0)/2+a/2+W;n.attr(`y`,s);let c=e.x1-e.x0,l=e.y1-e.y0-4,u=c-2*H;n.node().getComputedTextLength()>u||s+o>l||o{let t=r(),n=s(),i=g(t,n.themeVariables),a=g(ue,e),o=a.titleColor??i.titleColor,c=a.labelColor??i.textColor,l=a.valueColor??i.textColor;return` + .treemapNode.section { + stroke: ${a.sectionStrokeColor}; + stroke-width: ${a.sectionStrokeWidth}; + fill: ${a.sectionFillColor}; + } + .treemapNode.leaf { + stroke: ${a.leafStrokeColor}; + stroke-width: ${a.leafStrokeWidth}; + fill: ${a.leafFillColor}; + } + .treemapLabel { + fill: ${c}; + font-size: ${a.labelFontSize}; + } + .treemapValue { + fill: ${l}; + font-size: ${a.valueFontSize}; + } + .treemapTitle { + fill: ${o}; + font-size: ${a.titleFontSize}; + } + `},`getStyles`)};export{de as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-ATOU4E4O-BNgT_lbL.js b/frontend/dist/assets/diagram-ATOU4E4O-BNgT_lbL.js new file mode 100644 index 0000000..253c2f5 --- /dev/null +++ b/frontend/dist/assets/diagram-ATOU4E4O-BNgT_lbL.js @@ -0,0 +1,3 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,X as a,a as o,b as s,f as c,q as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{_ as h,i as g,t as ee}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{T as te}from"./chunk-FOHPRMQF-DHwB1DNv.js";import{n as ne}from"./mermaid-parser.core-CUrDj5TF.js";import{t as re}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=`position frame`,v=`frame positioned`,y=`position relation`,b=`relation positioned`,ie=n(function(t){e.debug(`options str`,t)},`setOptions`),ae=n(function(){return{}},`getOptions`),oe=n(function(){x(),o()},`clear`);function x(){S={}}n(x,`reset`);var se=c.eventmodeling,ce=n(()=>g({...se,...s().eventmodeling}),`getConfig`),S={};function C(){let t=le,{ast:n}=S,r=E();if(!n)throw Error(`No data for EventModel`);return n.frames.forEach((i,a)=>{let o=N(i,n.dataEntities,r);t=q(t,{$kind:_,index:a,frame:i,textProps:o});let s;B(i)?(e.debug(`source frame`,i.sourceFrames),s=n.frames.filter(e=>i.sourceFrames.some(t=>t.$refText===e.name)),s.forEach(e=>{t=q(t,{$kind:y,index:a,frame:i,sourceFrame:e})})):t=q(t,{$kind:y,index:a,frame:i})}),t={...t,sortedSwimlanesArray:L(t.swimlanes)},t}n(C,`getState`);function w(e){S.ast=e}n(w,`setAst`);var T={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:`bold`,boxTextPadding:10,swimlaneTextFontWeight:`bold`,labelUiAutomation:`UI/Automation`,labelUiAutomationPrefix:`UI/A: `,labelCommandReadModel:`Command/Read Model`,labelCommandReadModelPrefix:`C/RM: `,labelEvents:`Events`,labelEventsPrefix:`Stream: `};function E(){return T}n(E,`getDiagramProps`);var le={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function D(e){let t=e.split(`.`);if(t.length===2)return t[0]}n(D,`extractNamespace`);function O(e){let t=e.split(`.`);return t.length===2?t[1]:e}n(O,`extractName`);function k(e,t){if(!(!t||t.length===0))return Object.values(e).find(e=>e.namespace===t)}n(k,`findSwimlaneByNamespace`);function A(e,t,n){return Math.max(t,...Object.keys(e).filter(e=>{let r=Number.parseInt(e);return r>t&&rNumber.parseInt(e)))+1}n(A,`findNextAvailableIndex`);function j(e,t){let n=D(e.entityIdentifier),r=k(t,n);switch(e.modelEntityType){case`ui`:case`pcr`:case`processor`:return r?{index:r.index,label:r.namespace||T.labelUiAutomation}:n?{index:A(t,0,100),label:T.labelUiAutomationPrefix+n}:{index:0,label:T.labelUiAutomation};case`rmo`:case`readmodel`:case`cmd`:case`command`:return r?{index:r.index,label:r.namespace||T.labelCommandReadModel}:n?{index:A(t,100,200),label:T.labelCommandReadModelPrefix+n}:{index:100,label:T.labelCommandReadModel};default:return r?{index:r.index,label:r.namespace||T.labelEvents}:n?{index:A(t,200,300),label:T.labelEventsPrefix+n}:{index:200,label:T.labelEvents}}}n(j,`calculateSwimlaneProps`);function M(e){let{themeVariables:t}=s();switch(e.modelEntityType){case`ui`:return{fill:t.emUiFill??`white`,stroke:t.emUiStroke??`#dbdada`};case`pcr`:case`processor`:return{fill:t.emProcessorFill??`#edb3f6`,stroke:t.emProcessorStroke??`#b88cbf`};case`rmo`:case`readmodel`:return{fill:t.emReadModelFill??`#d3f1a2`,stroke:t.emReadModelStroke??`#a3b732`};case`cmd`:case`command`:return{fill:t.emCommandFill??`#bcd6fe`,stroke:t.emCommandStroke??`#679ac3`};case`evt`:case`event`:return{fill:t.emEventFill??`#ffb778`,stroke:t.emEventStroke??`#c19a0f`};default:return{fill:`red`,stroke:`black`}}}n(M,`calculateEntityVisualProps`);function N(t,n,r){let i=s(),a=m(O(t.entityIdentifier)??``,i),o,c={fontSize:16,fontWeight:700,fontFamily:`"trebuchet ms", verdana, arial, sans-serif`,joinWith:`
    `},l=`${h(a,r.textMaxWidth,c)}`;if(t.dataInlineValue&&(o=t.dataInlineValue,o=o.substring(o.indexOf(`{`)+1),o=o.substring(0,o.lastIndexOf(`}`)-1),o=m(o,i),o=h(o,r.textMaxWidth,c),o=o.replaceAll(` `,` `)),t.dataReference){let e=n.find(e=>e.name===t.dataReference?.$refText);e&&(o=e.dataBlockValue,o=o.substring(o.indexOf(`{ +`)+2),o=o.substring(0,o.lastIndexOf(`}`)-1),o=m(o,i),o=h(o,r.textMaxWidth,c),o=o.replaceAll(` `,` `),o+=`
    `)}let u=o!==void 0;u&&(l+=`

    ${o}`);let d={fontSize:c.fontSize,fontWeight:c.fontWeight,fontFamily:c.fontFamily},f=ee(l,d),p=u?f.width/3:f.width,g={content:l,width:p,height:f.height};return e.debug(`[${t.name}] ${t.entityIdentifier} text`,g),g}n(N,`calculateTextProps`);function P(e,t){let n=t,r=M(n.frame),i={width:n.textProps.width+2*T.boxTextPadding,height:n.textProps.height+2*T.boxTextPadding};return[{$kind:v,frame:n.frame,index:n.index,visual:r,dimension:i,textProps:n.textProps}]}n(P,`decidePositionFrame`);function F(e,t,n){return t===void 0?T.contentStartX:t.index===e.index&&e.r?e.r+T.boxPadding:n===void 0?T.contentStartX:n.r-T.boxOverlap+T.boxPadding}n(F,`calculateX`);function I(e,t){let n=[...e.map(e=>e.r),t];return Math.max(...n)}n(I,`calculateMaxRight`);function L(e){return Object.values(e).sort((e,t)=>e.index-t.index)}n(L,`sortedSwimlanesArray`);function R(e,t){let n=t,r=j(n.frame,e.swimlanes),i;i=r.index in e.swimlanes?e.swimlanes[r.index]:{index:r.index,label:r.label,r:0,y:r.index*T.swimlaneMinHeight+T.swimlaneGap,height:T.swimlaneMinHeight,maxHeight:T.swimlaneMinHeight};let a=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,o=e.previousSwimlaneNumber===void 0?void 0:e.swimlanes[e.previousSwimlaneNumber],s={width:Math.max(T.boxMinWidth,Math.min(T.boxMaxWidth,n.dimension.width))+2*T.boxPadding,height:Math.max(T.boxMinHeight,Math.min(T.boxMaxHeight,n.dimension.height))+2*T.boxPadding},c=F(i,o,a),l=c+s.width+T.boxPadding,u=I(Object.values(e.swimlanes),l);i.r=c+s.width,i.maxHeight=Math.max(i.maxHeight,s.height),i.height=Math.max(T.swimlaneMinHeight,i.maxHeight)+2*T.swimlanePadding;let d={x:c,y:T.swimlanePadding+i.y,r:l,dimension:s,leftSibling:!1,swimlane:i,visual:n.visual,text:n.textProps.content,frame:n.frame,index:n.index},f={...e,boxes:[...e.boxes,d],swimlanes:{...e.swimlanes,[`${i.index}`]:i},previousSwimlaneNumber:r.index,previousFrame:n.frame,maxR:u},p=L(f.swimlanes);p.length>0&&(p[0].y=0);for(let e=1;e0}n(B,`hasSourceFrame`);function V(e,t){if(t!=null)return e.find(e=>e.frame.name===t.name)}n(V,`findBoxByFrame`);function H(e,t,n){if(!(n<0))for(let r=n;r>=0;r--){let n=e[r];if(n.swimlane.index!==t)return n}}n(H,`findBoxByLineIndex`);function U(e,t){let n=t;if(te(n.frame)||z(n.index,n.frame))return[];let r=V(e.boxes,n.frame);if(r===void 0)throw Error(`Target box not found for frame ${n.frame.name}`);let i;return i=n.sourceFrame?V(e.boxes,n.sourceFrame):H(e.boxes,r.swimlane.index,n.index-1),i===void 0?[]:[{$kind:b,frame:n.frame,index:n.index,sourceBox:i,targetBox:r}]}n(U,`decidePositionRelation`);function W(e,t){let n=t,r={visual:{fill:`none`,stroke:`#000`},source:{x:n.sourceBox.x,y:n.sourceBox.y},target:{x:n.targetBox.x,y:n.targetBox.y},sourceBox:n.sourceBox,targetBox:n.targetBox};return{...e,relations:[...e.relations,r]}}n(W,`evolveRelationPositioned`);var ue={[_]:P,[y]:U},de={[v]:R,[b]:W};function G(t,n){let r=ue[n.$kind];if(r==null)return[];let i=r(t,n);return e.debug(`decided events`,i),i}n(G,`decide`);function K(t,n){let r=n.reduce((e,t)=>{let n=de[t.$kind];return n==null?e:n(e,t)},t);return e.debug(`evolve events`,{state:t,newState:r,events:n}),r}n(K,`evolve`);function q(e,t){return K(e,G(e,t))}n(q,`dispatch`);var J={getConfig:ce,setOptions:ie,getOptions:ae,clear:oe,setAccTitle:i,getAccTitle:p,getAccDescription:u,setAccDescription:r,setDiagramTitle:l,getDiagramTitle:d,setAst:w,getDiagramProps:E,getState:C},fe={parse:n(async t=>{let n=await ne(`eventmodeling`,t);e.debug(n),J.setAst(n),re(n,J)},`parse`)},Y=f()?.eventmodeling;function X(e,t){return n=>{let r=n.swimlane.y+t.swimlanePadding,i=e.append(`g`).attr(`class`,`em-box`);i.append(`rect`).attr(`x`,n.x).attr(`y`,r).attr(`rx`,`3`).attr(`width`,n.dimension.width).attr(`height`,n.dimension.height).attr(`stroke`,n.visual.stroke).attr(`fill`,n.visual.fill),i.append(`foreignObject`).attr(`x`,n.x+t.boxPadding).attr(`y`,r+10).attr(`width`,n.dimension.width-2*t.boxPadding).attr(`height`,n.dimension.height-2*t.boxPadding).append(`xhtml:div`).style(`display`,`table`).style(`height`,`100%`).style(`width`,`100%`).append(`span`).style(`display`,`table-cell`).style(`text-align`,`center`).style(`vertical-align`,`middle`).html(n.text)}}n(X,`renderD3Box`);function Z(e,t){return e>t}n(Z,`dirUpwards`);function Q(t,n,r,i){return a=>{let o=a.sourceBox.swimlane.y+n.swimlanePadding,s=a.targetBox.swimlane.y+n.swimlanePadding,c=Z(o,s),l=a.sourceBox.x+a.sourceBox.dimension.width*2/3,u=a.targetBox.x+a.targetBox.dimension.width/3,d,f;e.debug(`rendering relation up=${c} for `,{sourceBox:a.sourceBox,targetBox:a.targetBox}),c?(d=o,f=s+a.targetBox.dimension.height):(d=o+a.sourceBox.dimension.height,f=s);let p=i.emRelationStroke??a.visual.stroke;t.append(`path`).attr(`class`,`em-relation`).attr(`fill`,a.visual.fill).attr(`stroke`,p).attr(`stroke-width`,`1`).attr(`marker-end`,`url(#${r})`).attr(`d`,`M${l} ${d} L${u} ${f}`)}}n(Q,`renderD3Relation`);function $(e,t,n,r){return i=>{let a=e.append(`g`).attr(`class`,`em-swimlane`),o=r.emSwimlaneBackgroundOdd??`rgb(250,250,250)`,s=r.emSwimlaneBackgroundStroke??`rgb(240,240,240)`;a.append(`rect`).attr(`x`,0).attr(`y`,i.y).attr(`rx`,`3`).attr(`width`,t+n.swimlanePadding).attr(`height`,i.height).attr(`fill`,o).attr(`stroke`,s),a.append(`text`).attr(`font-weight`,n.swimlaneTextFontWeight).attr(`x`,30).attr(`y`,i.y+30).text(i.label)}}n($,`renderD3Swimlane`);var pe={parser:fe,db:J,renderer:{draw:n(function(n,r,i,o){if(e.debug(`in eventmodeling renderer`,n+` +`,`id:`,r,i),!Y)throw Error(`EventModeling config not found`);let s=o.db,{themeVariables:c,eventmodeling:l}=f(),u=t(`[id="${r}"]`),d=s.getDiagramProps(),p=s.getState(),m=`em-arrowhead-${r}`,h=c.emArrowhead??`#000000`;p.sortedSwimlanesArray.forEach($(u,p.maxR,d,c)),p.boxes.forEach(X(u,d)),p.relations.forEach(Q(u,d,m,c)),u.append(`defs`).append(`marker`).attr(`id`,m).attr(`markerWidth`,`10`).attr(`markerHeight`,`7`).attr(`refX`,`10`).attr(`refY`,`3.5`).attr(`orient`,`auto`).append(`polygon`).attr(`points`,`0 0, 10 3.5, 0 7`).attr(`fill`,h),a(void 0,u,l?.padding??30,l?.useMaxWidth)},`draw`)},styles:n(e=>``,`getStyles`)};export{pe as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-CDSNMT55-DcWw9GHj.js b/frontend/dist/assets/diagram-CDSNMT55-DcWw9GHj.js new file mode 100644 index 0000000..a4a4aea --- /dev/null +++ b/frontend/dist/assets/diagram-CDSNMT55-DcWw9GHj.js @@ -0,0 +1,30 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,b as a,c as o,f as s,q as c,v as l,w as u,y as d,z as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{r as m,t as h}from"./chunk-742MDFTN-5mFByRwZ.js";import{y as g}from"./index-DoQkmpth.js";import{n as _}from"./mermaid-parser.core-CUrDj5TF.js";import{t as v}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as y}from"./chunk-2Q5K7J3B-C1jixKkw.js";var b=/[─━│┃└┗├┣]/,x=/[└┗├┣]/,S=/[─━]/,C=/^[\s│┃]+$/,w=/^\s*(title[\t ]|accTitle[\t ]*:|accDescr[\t ]*[:{])/,T=/^\s*%%/,E=` `;function D(e){return e.some(e=>b.test(e))}t(D,`isBoxDrawingFormat`);function O(e){for(let t of e){let e=x.exec(t);if(e?.index&&e.index>0)return e.index}return 4}t(O,`inferSegmentWidth`);function k(e,t){return e.replace(/\bline\s+(\d+)\b/gi,(e,n)=>{let r=parseInt(n,10),i=t.get(r);return i?`line ${i}`:e})}t(k,`remapErrorLines`);function A(e){let t=e.split(` +`),n=new Map,r=-1;for(let[e,n]of t.entries())if(n.trim()===`treeView-beta`){r=e;break}if(r===-1)return{text:e,lineMap:n};let i=[];for(let e=r+1;e({cnt:1,stack:[{id:0,level:-1,name:`/`,nodeType:`directory`,children:[]}]})),M=t(()=>{j.reset(),i()},`clear`),N=t(()=>j.records.stack[0],`getRoot`),P=t(()=>j.records.cnt,`getCount`),F=s.treeView,I={clear:M,addNode:t((e,t,n,r,i,a)=>{for(;e<=j.records.stack[j.records.stack.length-1].level;)j.records.stack.pop();let o={id:j.records.cnt++,level:e,name:t,nodeType:n,icon:i,cssClass:r,description:a,children:[]};j.records.stack[j.records.stack.length-1].children.push(o),j.records.stack.push(o)},`addNode`),getRoot:N,getCount:P,getConfig:t(()=>p(F,a().treeView),`getConfig`),getAccTitle:d,getAccDescription:l,getDiagramTitle:u,setAccDescription:n,setAccTitle:r,setDiagramTitle:c},L=t(e=>{v(e,I);for(let t of e.nodes){let e=typeof t.indent==`number`?t.indent:0,n=t.name,r=n.endsWith(`/`);r&&(n=n.slice(0,-1));let i=r?`directory`:`file`,o=t.classAnnotation||void 0,s=t.iconAnnotation,c=s===void 0?void 0:s||`none`,l=t.descAnnotation||void 0,u=l?f(l,a()):void 0;I.addNode(e,n,i,o,c,u)}},`populate`),R={parse:t(async t=>{let{text:n,lineMap:r}=A(t);try{let t=await _(`treeView`,n);e.debug(t),L(t)}catch(e){throw r.size>0&&e instanceof Error&&(e.message=k(e.message,r)),e}},`parse`)},z={prefix:`mermaid-treeview`,height:24,width:24,icons:{folder:{body:``},file:{body:``}}};function B(e,t){let n=t?.filenameIcons?.[e];if(n)return n;let r=e.lastIndexOf(`.`);if(r>0){let n=e.substring(r).toLowerCase(),i=t?.extensionIcons;return i?.[n]??i?.[n.slice(1)]}}t(B,`detectIcon`);function V(e,t){return e.includes(`:`)?e:e in z.icons||!t?`${z.prefix}:${e}`:`${t}:${e}`}t(V,`qualifyIcon`);function H(e,t){if(e.icon!==`none`){if(e.icon)return V(e.icon,t.defaultIconPack);if(t.showIcons){if(e.nodeType===`file`){let n=B(e.name,t);if(n===`none`)return;if(n)return V(n,t.defaultIconPack)}return`${z.prefix}:${e.nodeType===`directory`?`folder`:`file`}`}}}t(H,`getNodeIcon`),m([{name:z.prefix,icons:z}]);var U=14,W=4,G=16,K=t(async(e,n)=>{let r=[],i=t(e=>{let t=H(e,n);t&&r.push({icon:t,node:e}),e.children.forEach(i)},`collect`);i(e);let a=await Promise.all(r.map(async({icon:e,node:t})=>({id:t.id,svg:await h(e,{height:U,width:U})})));return new Map(a.map(({id:e,svg:t})=>[e,t]))},`resolveNodeIcons`),q=t((e,t,n,r,i,a)=>{let o=r.append(`g`),s=`treeView-node-label`;n.nodeType===`directory`&&(s+=` treeView-node-dir`),n.cssClass&&(s+=` ${n.cssClass}`);let c=U+W,l=H(n,i),u=l!==void 0;l&&o.append(`g`).attr(`class`,`treeView-node-icon`).attr(`transform`,`translate(${e+i.paddingX}, ${t+i.paddingY})`).html(a.get(n.id)??``);let d=o.append(`text`).text(n.name).attr(`dominant-baseline`,`middle`).attr(`class`,s),{height:f,width:p}=d.node().getBBox(),m=f+i.paddingY*2,h=e+i.paddingX+(u?c:0);d.attr(`x`,h),d.attr(`y`,t+m/2);let g=h+p;return n.BBox={x:e,y:t,width:p+i.paddingX*2+(u?c:0),height:m},n.cssClass?.split(/\s+/).includes(`highlight`)&&o.insert(`rect`,`:first-child`).attr(`x`,e).attr(`y`,t+1).attr(`width`,0).attr(`height`,m-2).attr(`rx`,3).attr(`class`,`treeView-highlight-bg`),{node:n,nodeGroup:o,labelRightEdge:g,centerY:t+m/2}},`positionLabel`),J=t((e,t,n,r,i,a)=>e.append(`line`).attr(`x1`,t).attr(`y1`,n).attr(`x2`,r).attr(`y2`,i).attr(`stroke-width`,a).attr(`class`,`treeView-node-line`),`positionLine`),Y=t((e,n,r,i)=>{let a=0,o=0,s=[],c=t((e,t,n,r)=>{let c=r*(n.rowIndent+n.paddingX),l=q(c,a,t,e,n,i);s.push(l);let{height:u,width:d}=t.BBox;J(e,c-n.rowIndent,a+u/2,c,a+u/2,n.lineThickness),o=Math.max(o,c+d),a+=u},`drawNode`),l=t((t,n=0)=>{c(e,t,r,n),t.children.forEach(e=>{l(e,n+1)});let{x:i,y:a,height:o}=t.BBox;if(t.children.length){let{y:n,height:s}=t.children[t.children.length-1].BBox;J(e,i+r.paddingX,a+o,i+r.paddingX,n+s/2+r.lineThickness/2,r.lineThickness)}},`processNode`);l(n);let u=s.filter(e=>e.node.description);if(u.length>0){let e=Math.max(...s.map(e=>e.labelRightEdge))+G;for(let t of u){let n=t.nodeGroup.append(`text`).text(t.node.description).attr(`dominant-baseline`,`middle`).attr(`class`,`treeView-node-description`).attr(`x`,e).attr(`y`,t.centerY).node().getBBox();o=Math.max(o,e+n.width+r.paddingX)}}for(let e of s)if(e.node.cssClass?.split(/\s+/).includes(`highlight`)){let t=e.nodeGroup.select(`.treeView-highlight-bg`);if(!t.empty()){let n=o-e.node.BBox.x+8;t.attr(`width`,n),o=Math.max(o,e.node.BBox.x+n+2)}}return{totalHeight:a,totalWidth:o}},`drawTree`),X={draw:t(async(t,n,r,i)=>{e.debug(`Rendering treeView diagram +`+t);let a=i.db,s=a.getRoot(),c=a.getConfig(),l=g(n),u=l.append(`g`);u.attr(`class`,`tree-view`);let{totalHeight:d,totalWidth:f}=Y(u,s,c,await K(s,c));l.attr(`viewBox`,`-${c.lineThickness/2} 0 ${f} ${d}`),o(l,d,f,c.useMaxWidth)},`draw`)},Z={labelFontSize:`16px`,labelColor:`black`,lineColor:`black`,iconColor:`#546e7a`,descriptionColor:`#6a9955`,highlightBg:`rgba(255, 193, 7, 0.15)`,highlightStroke:`#ffc107`},Q={db:I,renderer:X,parser:R,styles:t(({treeView:e})=>{let{labelFontSize:t,labelColor:n,lineColor:r,iconColor:i,descriptionColor:a,highlightBg:o,highlightStroke:s}=p(Z,e);return` + .treeView-node-label { + font-size: ${t}; + fill: ${n}; + white-space: pre; + } + .treeView-node-dir { + font-weight: bold; + } + .treeView-node-line { + stroke: ${r}; + } + .treeView-node-icon { + color: ${i}; + } + .treeView-node-description { + font-size: ${t}; + fill: ${a}; + font-style: italic; + white-space: pre; + } + .treeView-highlight-bg { + fill: ${o}; + stroke: ${s}; + stroke-width: 1; + } + `},`styles`)};export{Q as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-MLGK6HIB-DILal1CA.js b/frontend/dist/assets/diagram-MLGK6HIB-DILal1CA.js new file mode 100644 index 0000000..9ef5457 --- /dev/null +++ b/frontend/dist/assets/diagram-MLGK6HIB-DILal1CA.js @@ -0,0 +1,24 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,b as a,c as o,f as s,q as c,v as l,w as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as f}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as p}from"./index-DoQkmpth.js";import{n as m}from"./mermaid-parser.core-CUrDj5TF.js";import{t as h}from"./chunk-JWPE2WC7-DVXcaiue.js";var g=s.packet,_=class{constructor(){this.packet=[],this.setAccTitle=r,this.getAccTitle=d,this.setDiagramTitle=c,this.getDiagramTitle=u,this.getAccDescription=l,this.setAccDescription=n}static{t(this,`PacketDB`)}getConfig(){let e=f({...g,...a().packet});return e.showBits&&(e.paddingY+=10),e}getPacket(){return this.packet}pushWord(e){e.length>0&&this.packet.push(e)}clear(){i(),this.packet=[]}},v=1e4,y=t((t,n)=>{h(t,n);let r=-1,i=[],a=1,{bitsPerRow:o}=n.getConfig();for(let{start:s,end:c,bits:l,label:u}of t.blocks){if(s!==void 0&&c!==void 0&&c{if(e.start===void 0)throw Error(`start should have been set during first phase`);if(e.end===void 0)throw Error(`end should have been set during first phase`);if(e.start>e.end)throw Error(`Block start ${e.start} is greater than block end ${e.end}.`);if(e.end+1<=t*n)return[e,void 0];let r=t*n-1,i=t*n;return[{start:e.start,end:r,label:e.label,bits:r-e.start},{start:i,end:e.end,label:e.label,bits:e.end-i}]},`getNextFittingBlock`),x={parser:{yy:void 0},parse:t(async t=>{let n=await m(`packet`,t),r=x.parser?.yy;if(!(r instanceof _))throw Error(`parser.parser?.yy was not a PacketDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);e.debug(n),y(n,r)},`parse`)},S=t((e,t,n,r)=>{let i=r.db,a=i.getConfig(),{rowHeight:s,paddingY:c,bitWidth:l,bitsPerRow:u}=a,d=i.getPacket(),f=i.getDiagramTitle(),m=s+c,h=m*(d.length+1)-(f?0:s),g=l*u+2,_=p(t);_.attr(`viewBox`,`0 0 ${g} ${h}`),o(_,h,g,a.useMaxWidth);for(let[e,t]of d.entries())C(_,t,e,a);_.append(`text`).text(f).attr(`x`,g/2).attr(`y`,h-m/2).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).attr(`class`,`packetTitle`)},`draw`),C=t((e,t,n,{rowHeight:r,paddingX:i,paddingY:a,bitWidth:o,bitsPerRow:s,showBits:c})=>{let l=e.append(`g`),u=n*(r+a)+a;for(let e of t){let t=e.start%s*o+1,n=(e.end-e.start+1)*o-i;if(l.append(`rect`).attr(`x`,t).attr(`y`,u).attr(`width`,n).attr(`height`,r).attr(`class`,`packetBlock`),l.append(`text`).attr(`x`,t+n/2).attr(`y`,u+r/2).attr(`class`,`packetLabel`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).text(e.label),!c)continue;let a=e.end===e.start,d=u-2;l.append(`text`).attr(`x`,t+(a?n/2:0)).attr(`y`,d).attr(`class`,`packetByte start`).attr(`dominant-baseline`,`auto`).attr(`text-anchor`,a?`middle`:`start`).text(e.start),a||l.append(`text`).attr(`x`,t+n).attr(`y`,d).attr(`class`,`packetByte end`).attr(`dominant-baseline`,`auto`).attr(`text-anchor`,`end`).text(e.end)}},`drawWord`),w={draw:S},T={byteFontSize:`10px`,startByteColor:`black`,endByteColor:`black`,labelColor:`black`,labelFontSize:`12px`,titleColor:`black`,titleFontSize:`14px`,blockStrokeColor:`black`,blockStrokeWidth:`1`,blockFillColor:`#efefef`},E={parser:x,get db(){return new _},renderer:w,styles:t(({packet:e}={})=>{let t=f(T,e);return` + .packetByte { + font-size: ${t.byteFontSize}; + } + .packetByte.start { + fill: ${t.startByteColor}; + } + .packetByte.end { + fill: ${t.endByteColor}; + } + .packetLabel { + fill: ${t.labelColor}; + font-size: ${t.labelFontSize}; + } + .packetTitle { + fill: ${t.titleColor}; + font-size: ${t.titleFontSize}; + } + .packetBlock { + stroke: ${t.blockStrokeColor}; + stroke-width: ${t.blockStrokeWidth}; + fill: ${t.blockFillColor}; + } + `},`styles`)};export{E as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/diagram-MPIPVDR6-8w_EEv4v.js b/frontend/dist/assets/diagram-MPIPVDR6-8w_EEv4v.js new file mode 100644 index 0000000..379ca46 --- /dev/null +++ b/frontend/dist/assets/diagram-MPIPVDR6-8w_EEv4v.js @@ -0,0 +1,41 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _={showLegend:!0,ticks:5,max:null,min:0,graticule:`circle`},v=32,y={axes:[],curves:[],options:_},b=structuredClone(y),x=c.radar,S=t(()=>p({...x,...o().radar}),`getConfig`),C=t(()=>b.axes,`getAxes`),w=t(()=>b.curves,`getCurves`),T=t(()=>b.options,`getOptions`),E=t(e=>{b.axes=e.map(e=>({name:e.name,label:e.label??e.name}))},`setAxes`),D=t(e=>{b.curves=e.map(e=>({name:e.name,label:e.label??e.name,entries:O(e.entries)}))},`setCurves`),O=t(e=>{if(e[0].axis==null)return e.map(e=>e.value);let t=C();if(t.length===0)throw Error(`Axes must be populated before curves for reference entries`);return t.map(t=>{let n=e.find(e=>e.axis?.$refText===t.name);if(n===void 0)throw Error(`Missing entry for axis `+t.label);return n.value})},`computeCurveEntries`),k={getAxes:C,getCurves:w,getOptions:T,setAxes:E,setCurves:D,setOptions:t(t=>{let n=t.reduce((e,t)=>(e[t.name]=t,e),{});b.options={showLegend:n.showLegend?.value??_.showLegend,ticks:n.ticks?.value??_.ticks,max:n.max?.value??_.max,min:n.min?.value??_.min,graticule:n.graticule?.value??_.graticule},b.options.ticks>v&&(e.warn(`Radar diagram ticks (${b.options.ticks}) exceeds maximum allowed (${v}). Using ${v} instead.`),b.options.ticks=v)},`setOptions`),getConfig:S,clear:t(()=>{a(),b=structuredClone(y)},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r},A=t(e=>{g(e,k);let{axes:t,curves:n,options:r}=e;k.setAxes(t),k.setCurves(n),k.setOptions(r)},`populate`),j={parse:t(async t=>{let n=await h(`radar`,t);e.debug(n),A(n)},`parse`)},M=t((e,t,n,r)=>{let i=r.db,a=i.getAxes(),o=i.getCurves(),s=i.getOptions(),c=i.getConfig(),l=i.getDiagramTitle(),u=N(m(t),c),d=s.max??Math.max(...o.map(e=>Math.max(...e.entries))),f=s.min,p=Math.min(c.width,c.height)/2;P(u,a,p,s.ticks,s.graticule),F(u,a,p,c),I(u,a,o,f,d,s.graticule,c),z(u,o,s.showLegend,c),u.append(`text`).attr(`class`,`radarTitle`).text(l).attr(`x`,0).attr(`y`,-c.height/2-c.marginTop)},`draw`),N=t((e,t)=>{let n=t.width+t.marginLeft+t.marginRight,r=t.height+t.marginTop+t.marginBottom,i={x:t.marginLeft+t.width/2,y:t.marginTop+t.height/2};return s(e,r,n,t.useMaxWidth??!0),e.attr(`viewBox`,`0 0 ${n} ${r}`).attr(`overflow`,`visible`),e.append(`g`).attr(`transform`,`translate(${i.x}, ${i.y})`)},`drawFrame`),P=t((e,t,n,r,i)=>{if(i===`circle`)for(let t=0;t{let n=2*t*Math.PI/i-Math.PI/2;return`${o*Math.cos(n)},${o*Math.sin(n)}`}).join(` `);e.append(`polygon`).attr(`points`,s).attr(`class`,`radarGraticule`)}}},`drawGraticule`),F=t((e,t,n,r)=>{let i=t.length;for(let a=0;a.01?`start`:c<-.01?`end`:`middle`,d=l>.01?`hanging`:l<-.01?`auto`:`central`;e.append(`text`).text(o).attr(`x`,n*r.axisLabelFactor*c+4*c).attr(`y`,n*r.axisLabelFactor*l+4*l).attr(`text-anchor`,u).attr(`dominant-baseline`,d).attr(`class`,`radarAxisLabel`)}},`drawAxes`);function I(e,t,n,r,i,a,o){let s=t.length,c=Math.min(o.width,o.height)/2;n.forEach((t,n)=>{if(t.entries.length!==s)return;let l=t.entries.map((e,t)=>{let n=2*Math.PI*t/s-Math.PI/2,a=L(e,r,i,c);return{x:a*Math.cos(n),y:a*Math.sin(n)}});a===`circle`?e.append(`path`).attr(`d`,R(l,o.curveTension)).attr(`class`,`radarCurve-${n}`):a===`polygon`&&e.append(`polygon`).attr(`points`,l.map(e=>`${e.x},${e.y}`).join(` `)).attr(`class`,`radarCurve-${n}`)})}t(I,`drawCurves`);function L(e,t,n,r){return r*(Math.min(Math.max(e,t),n)-t)/(n-t)}t(L,`relativeRadius`);function R(e,t){let n=e.length,r=`M${e[0].x},${e[0].y}`;for(let i=0;i{let r=e.append(`g`).attr(`transform`,`translate(${i}, ${a+n*20})`);r.append(`rect`).attr(`width`,12).attr(`height`,12).attr(`class`,`radarLegendBox-${n}`),r.append(`text`).attr(`x`,16).attr(`y`,0).attr(`class`,`radarLegendText`).text(t.label)})}t(z,`drawLegend`);var B={draw:M},V=t((e,t)=>{let n=``;for(let r=0;r{let t=n(),r=o(),i=p(t,r.themeVariables);return{themeVariables:i,radarOptions:p(i.radar,e)}},`buildRadarStyleOptions`),U={parser:j,db:k,renderer:B,styles:t(({radar:e}={})=>{let{themeVariables:t,radarOptions:n}=H(e);return` + .radarTitle { + font-size: ${t.fontSize}; + color: ${t.titleColor}; + dominant-baseline: hanging; + text-anchor: middle; + } + .radarAxisLine { + stroke: ${n.axisColor}; + stroke-width: ${n.axisStrokeWidth}; + } + .radarAxisLabel { + font-size: ${n.axisLabelFontSize}px; + color: ${n.axisColor}; + } + .radarGraticule { + fill: ${n.graticuleColor}; + fill-opacity: ${n.graticuleOpacity}; + stroke: ${n.graticuleColor}; + stroke-width: ${n.graticuleStrokeWidth}; + } + .radarLegendText { + text-anchor: start; + font-size: ${n.legendFontSize}px; + dominant-baseline: hanging; + } + ${V(t,n)} + `},`styles`)};export{U as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/dist-Bfr8PhAA.js b/frontend/dist/assets/dist-Bfr8PhAA.js new file mode 100644 index 0000000..ca70aba --- /dev/null +++ b/frontend/dist/assets/dist-Bfr8PhAA.js @@ -0,0 +1 @@ +import{_ as e}from"./src-D_iIdUkB.js";var t=Math.abs,n=Math.atan2,r=Math.cos,i=Math.max,a=Math.min,o=Math.sin,s=Math.sqrt,c=1e-12,l=Math.PI,u=l/2,d=2*l;function f(e){return e>1?0:e<-1?l:Math.acos(e)}function p(e){return e>=1?u:e<=-1?-u:Math.asin(e)}var m=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.BLANK_URL=e.relativeFirstCharacters=e.whitespaceEscapeCharsRegex=e.urlSchemeRegex=e.ctrlCharactersRegex=e.htmlCtrlEntityRegex=e.htmlEntitiesRegex=e.invalidProtocolRegex=void 0,e.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,e.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,e.htmlCtrlEntityRegex=/&(newline|tab);/gi,e.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,e.urlSchemeRegex=/^.+(:|:)/gim,e.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,e.relativeFirstCharacters=[`.`,`/`],e.BLANK_URL=`about:blank`})),h=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.sanitizeUrl=o;var t=m();function n(e){return t.relativeFirstCharacters.indexOf(e[0])>-1}function r(e){return e.replace(t.ctrlCharactersRegex,``).replace(t.htmlEntitiesRegex,function(e,t){return String.fromCharCode(t)})}function i(e){return URL.canParse(e)}function a(e){try{return decodeURIComponent(e)}catch{return e}}function o(e){if(!e)return t.BLANK_URL;var o,s=a(e.trim());do s=r(s).replace(t.htmlCtrlEntityRegex,``).replace(t.ctrlCharactersRegex,``).replace(t.whitespaceEscapeCharsRegex,``).trim(),s=a(s),o=s.match(t.ctrlCharactersRegex)||s.match(t.htmlEntitiesRegex)||s.match(t.htmlCtrlEntityRegex)||s.match(t.whitespaceEscapeCharsRegex);while(o&&o.length>0);var c=s;if(!c)return t.BLANK_URL;if(n(c))return c;var l=c.trimStart(),u=l.match(t.urlSchemeRegex);if(!u)return c;var d=u[0].toLowerCase().trim();if(t.invalidProtocolRegex.test(d))return t.BLANK_URL;var f=l.replace(/\\/g,`/`);if(d===`mailto:`||d.includes(`://`))return f;if(d===`http:`||d===`https:`){if(!i(f))return t.BLANK_URL;var p=new URL(f);return p.protocol=p.protocol.toLowerCase(),p.hostname=p.hostname.toLowerCase(),p.toString()}return f}}));export{n as a,u as c,l as d,o as f,p as i,i as l,d as m,t as n,r as o,s as p,f as r,c as s,h as t,a as u}; \ No newline at end of file diff --git a/frontend/dist/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js b/frontend/dist/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js new file mode 100644 index 0000000..004edd5 --- /dev/null +++ b/frontend/dist/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{f as n,t as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=n().RailroadEbnf.parser.LangiumParser,l=t(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformChoice`),u=t(e=>{let t=e.elements.map(p);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformSequence`),d=t(e=>{switch(e.$type){case`EbnfTerminal`:return{type:`terminal`,value:e.value};case`EbnfNonTerminal`:return{type:`nonterminal`,name:e.name};case`EbnfSpecial`:return{type:`special`,text:e.text};case`EbnfGroup`:return l(e.element);case`EbnfOptional`:return{type:`optional`,element:l(e.element)};case`EbnfRepetition`:return{type:`repetition`,element:l(e.element),min:0,max:1/0};default:throw Error(`Unsupported EBNF primary node: ${e.$type}`)}},`transformPrimary`),f=t((e,t)=>{switch(t.$type){case`EbnfOptionalPostfix`:return{type:`optional`,element:e};case`EbnfZeroOrMorePostfix`:return{type:`repetition`,element:e,min:0,max:1/0};case`EbnfOneOrMorePostfix`:return{type:`repetition`,element:e,min:1,max:1/0};case`EbnfExceptionPostfix`:return{type:`sequence`,elements:[e,{type:`terminal`,value:`-`},d(t.except)]};default:throw Error(`Unsupported EBNF postfix node: ${t.$type}`)}},`transformPostfix`),p=t(e=>e.postfixes.reduce((e,t)=>f(e,t),d(e.base)),`transformTerm`),m=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:t(t=>{o.clear(),e.debug(`[EBNF Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[EBNF Parser] Parsed rules:`,i.rules.length),h(i),e.debug(`[EBNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/elk-276RUBZZ-On_DNuCd.js b/frontend/dist/assets/elk-276RUBZZ-On_DNuCd.js new file mode 100644 index 0000000..b744b05 --- /dev/null +++ b/frontend/dist/assets/elk-276RUBZZ-On_DNuCd.js @@ -0,0 +1,27 @@ +import{_ as e,v as t,y as n}from"./src-D_iIdUkB.js";import{n as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as i}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{rt as a}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{c as o,l as s,m as c}from"./index-DoQkmpth.js";import{a as l,r as u}from"./chunk-3FUC2YCW-CmoZ3fbX.js";import{t as d}from"./chunk-NETBCI7D-Br7cqgBT.js";var f=n(e(((e,n)=>{(function(t){if(typeof e==`object`&&n!==void 0)n.exports=t();else if(typeof define==`function`&&define.amd)define([],t);else{var r=typeof window<`u`?window:typeof global<`u`?global:typeof self<`u`?self:this;r.ELK=t()}})(function(){return(function(){function e(n,r,i){function a(s,c){if(!r[s]){if(!n[s]){var l=typeof t==`function`&&t;if(!c&&l)return l(s,!0);if(o)return o(s,!0);var u=Error(`Cannot find module '`+s+`'`);throw u.code=`MODULE_NOT_FOUND`,u}var d=r[s]={exports:{}};n[s][0].call(d.exports,function(e){var t=n[s][1][e];return a(t||e)},d,d.exports,e,n,r,i)}return r[s].exports}for(var o=typeof t==`function`&&t,s=0;s0&&arguments[0]!==void 0?arguments[0]:{},r=n.defaultLayoutOptions,o=r===void 0?{}:r,s=n.algorithms,c=s===void 0?[`layered`,`stress`,`mrtree`,`radial`,`force`,`disco`,`sporeOverlap`,`sporeCompaction`,`rectpacking`]:s,l=n.workerFactory,u=n.workerUrl;if(i(this,e),this.defaultLayoutOptions=o,this.initialized=!1,u===void 0&&l===void 0)throw Error(`Cannot construct an ELK without both 'workerUrl' and 'workerFactory'.`);var d=l;u!==void 0&&l===void 0&&(d=function(e){return new Worker(e)});var f=d(u);if(typeof f.postMessage!=`function`)throw TypeError(`Created worker does not provide the required 'postMessage' function.`);this.worker=new a(f),this.worker.postMessage({cmd:`register`,algorithms:c}).then(function(e){return t.initialized=!0}).catch(console.err)}return r(e,[{key:`layout`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.layoutOptions,r=n===void 0?this.defaultLayoutOptions:n,i=t.logging,a=i!==void 0&&i,o=t.measureExecutionTime,s=o!==void 0&&o;return e?this.worker.postMessage({cmd:`layout`,graph:e,layoutOptions:r,options:{logging:a,measureExecutionTime:s}}):Promise.reject(Error(`Missing mandatory parameter 'graph'.`))}},{key:`knownLayoutAlgorithms`,value:function(){return this.worker.postMessage({cmd:`algorithms`})}},{key:`knownLayoutOptions`,value:function(){return this.worker.postMessage({cmd:`options`})}},{key:`knownLayoutCategories`,value:function(){return this.worker.postMessage({cmd:`categories`})}},{key:`terminateWorker`,value:function(){this.worker&&this.worker.terminate()}}]),e}();var a=function(){function e(t){var n=this;if(i(this,e),t===void 0)throw Error(`Missing mandatory parameter 'worker'.`);this.resolvers={},this.worker=t,this.worker.onmessage=function(e){setTimeout(function(){n.receive(n,e)},0)}}return r(e,[{key:`postMessage`,value:function(e){var t=this.id||0;this.id=t+1,e.id=t;var n=this;return new Promise(function(r,i){n.resolvers[t]=function(e,t){e?(n.convertGwtStyleError(e),i(e)):r(t)},n.worker.postMessage(e)})}},{key:`receive`,value:function(e,t){var n=t.data,r=e.resolvers[n.id];r&&(delete e.resolvers[n.id],n.error?r(n.error):r(null,n.data))}},{key:`terminate`,value:function(){this.worker&&this.worker.terminate()}},{key:`convertGwtStyleError`,value:function(e){if(e){var t=e.__java$exception;t&&(t.cause&&t.cause.backingJsObject&&(e.cause=t.cause.backingJsObject,this.convertGwtStyleError(e.cause)),delete e.__java$exception)}}}]),e}()},{}],2:[function(e,t,n){(function(e){(function(){var r;typeof window<`u`?r=window:e===void 0?typeof self<`u`&&(r=self):r=e;var i;function a(){}function o(){}function s(){}function c(){}function l(){}function u(){}function d(){}function f(){}function p(){}function m(){}function h(){}function g(){}function _(){}function v(){}function y(){}function b(){}function x(){}function S(){}function ee(){}function te(){}function ne(){}function C(){}function re(){}function ie(){}function ae(){}function oe(){}function se(){}function ce(){}function le(){}function ue(){}function de(){}function fe(){}function pe(){}function me(){}function he(){}function ge(){}function _e(){}function ve(){}function ye(){}function be(){}function xe(){}function Se(){}function Ce(){}function we(){}function Te(){}function Ee(){}function De(){}function Oe(){}function ke(){}function Ae(){}function je(){}function Me(){}function Ne(){}function Pe(){}function Fe(){}function Ie(){}function Le(){}function Re(){}function ze(){}function Be(){}function Ve(){}function He(){}function Ue(){}function We(){}function Ge(){}function Ke(){}function qe(){}function Je(){}function Ye(){}function Xe(){}function Ze(){}function Qe(){}function $e(){}function et(){}function tt(){}function nt(){}function rt(){}function it(){}function at(){}function ot(){}function st(){}function ct(){}function lt(){}function ut(){}function dt(){}function ft(){}function pt(){}function mt(){}function ht(){}function gt(){}function _t(){}function vt(){}function yt(){}function bt(){}function xt(){}function St(){}function Ct(){}function wt(){}function Tt(){}function Et(){}function Dt(){}function Ot(){}function kt(){}function At(){}function jt(){}function Mt(){}function Nt(){}function Pt(){}function Ft(){}function It(){}function Lt(){}function Rt(){}function zt(){}function Bt(){}function eee(){}function Vt(){}function tee(){}function nee(){}function Ht(){}function ree(){}function iee(){}function aee(){}function oee(){}function see(){}function cee(){}function lee(){}function uee(){}function dee(){}function fee(){}function pee(){}function mee(){}function hee(){}function Ut(){}function gee(){}function _ee(){}function vee(){}function yee(){}function bee(){}function xee(){}function See(){}function Cee(){}function wee(){}function Wt(){}function Gt(){}function Tee(){}function Eee(){}function Dee(){}function Oee(){}function kee(){}function Aee(){}function jee(){}function Mee(){}function Nee(){}function Pee(){}function Fee(){}function Iee(){}function Lee(){}function Ree(){}function zee(){}function Bee(){}function Vee(){}function Hee(){}function Uee(){}function Wee(){}function Gee(){}function Kee(){}function qee(){}function Jee(){}function Yee(){}function Xee(){}function Zee(){}function Qee(){}function $ee(){}function ete(){}function tte(){}function nte(){}function rte(){}function ite(){}function ate(){}function ote(){}function ste(){}function cte(){}function lte(){}function ute(){}function dte(){}function fte(){}function pte(){}function mte(){}function hte(){}function gte(){}function _te(){}function vte(){}function yte(){}function bte(){}function xte(){}function Ste(){}function Cte(){}function wte(){}function Tte(){}function Ete(){}function Dte(){}function Ote(){}function kte(){}function Ate(){}function jte(){}function Mte(){}function Nte(){}function Pte(){}function Fte(){}function Ite(){}function Lte(){}function Rte(){}function zte(){}function Bte(){}function Vte(){}function Hte(){}function Ute(){}function Wte(){}function Gte(){}function Kte(){}function qte(){}function Jte(){}function Yte(){}function Xte(){}function Zte(){}function Qte(){}function $te(){}function ene(){}function tne(){}function nne(){}function rne(){}function ine(){}function ane(){}function one(){}function sne(){}function cne(){}function lne(){}function une(){}function dne(){}function fne(){}function pne(){}function mne(){}function hne(){}function gne(){}function Kt(){}function _ne(){}function vne(){}function yne(){}function bne(){}function xne(){}function Sne(){}function Cne(){}function wne(){}function Tne(){}function Ene(){}function Dne(){}function One(){}function kne(){}function Ane(){}function jne(){}function Mne(){}function Nne(){}function Pne(){}function Fne(){}function Ine(){}function Lne(){}function Rne(){}function zne(){}function Bne(){}function Vne(){}function Hne(){}function Une(){}function Wne(){}function Gne(){}function Kne(){}function qne(){}function Jne(){}function Yne(){}function Xne(){}function Zne(){}function Qne(){}function $ne(){}function ere(){}function tre(){}function nre(){}function rre(){}function ire(){}function are(){}function ore(){}function sre(){}function cre(){}function lre(){}function ure(){}function dre(){}function fre(){}function pre(){}function mre(){}function hre(){}function gre(){}function _re(){}function vre(){}function yre(){}function bre(){}function xre(){}function Sre(){}function Cre(){}function wre(){}function Tre(){}function Ere(){}function Dre(){}function Ore(){}function kre(){}function Are(){}function jre(){}function Mre(){}function Nre(){}function Pre(){}function Fre(){}function qt(){}function Ire(){}function Lre(){}function Rre(){}function zre(){}function Bre(){}function Vre(){}function Hre(){}function Ure(){}function Wre(){}function Gre(){}function Kre(){}function qre(){}function Jre(){}function Yre(){}function Xre(){}function Zre(){}function Qre(){}function $re(){}function eie(){}function tie(){}function nie(){}function rie(){}function iie(){}function aie(){}function oie(){}function sie(){}function cie(){}function lie(){}function uie(){}function die(){}function fie(){}function pie(){}function mie(){}function hie(){}function gie(){}function _ie(){}function vie(){}function yie(){}function bie(){}function xie(){}function Sie(){}function Cie(){}function wie(){}function Tie(){}function Eie(){}function Die(){}function Oie(){}function kie(){}function Aie(){}function jie(){}function Mie(){}function Nie(){}function Pie(){}function Fie(){}function Iie(){}function Lie(){}function Rie(){}function zie(){}function Bie(){}function Vie(){}function Hie(){}function Uie(){}function Wie(){}function Gie(){}function Kie(){}function qie(){}function Jie(){}function Yie(){}function Xie(){}function Zie(){}function Qie(){}function $ie(){}function eae(){}function tae(){}function nae(){}function rae(){}function iae(){}function aae(){}function oae(){}function sae(){}function cae(){}function lae(){}function uae(){}function dae(){}function fae(){}function pae(){}function mae(){}function hae(){}function gae(){}function _ae(){}function vae(){}function yae(){}function bae(){}function xae(){}function Sae(){}function Cae(){}function wae(){}function Tae(){}function Eae(){}function Dae(){}function Oae(){}function kae(){}function Aae(){}function jae(){}function Mae(){}function Nae(){}function Pae(){}function Fae(){}function Iae(){}function Lae(){}function Rae(){}function zae(){}function Bae(){}function Vae(){}function Hae(){}function Uae(){}function Wae(){}function Gae(){}function Kae(){}function qae(){}function Jae(){}function Yae(){}function Xae(){}function Zae(){}function Qae(){}function $ae(){}function eoe(){}function toe(){}function noe(){}function roe(){}function ioe(){}function aoe(){}function ooe(){}function soe(){}function coe(){}function loe(){}function uoe(){}function doe(){}function foe(){}function poe(){}function moe(){}function hoe(){}function goe(){}function _oe(){}function voe(){}function yoe(){}function boe(){}function xoe(){}function Jt(){}function Yt(){}function Soe(){}function Xt(){}function Coe(){}function woe(){}function Toe(){}function Eoe(){}function Doe(){}function Ooe(){}function koe(){}function Aoe(){}function joe(){}function Moe(){}function Noe(){}function Poe(){}function Foe(){}function Ioe(){}function Loe(){}function Roe(){}function zoe(){}function Boe(){}function Voe(){}function Hoe(){}function Uoe(){}function Woe(){}function Zt(){}function Goe(){}function Qt(){}function Koe(){}function qoe(){}function Joe(){}function Yoe(){}function Xoe(){}function Zoe(){}function Qoe(){}function $oe(){}function ese(){}function tse(){}function nse(){}function rse(){}function ise(){}function ase(){}function ose(){}function sse(){}function cse(){}function lse(){}function use(){}function dse(){}function $t(){}function fse(){}function pse(){}function mse(){}function hse(){}function gse(){}function _se(){}function vse(){}function yse(){}function bse(){}function xse(){}function Sse(){}function Cse(){}function wse(){}function en(){}function Tse(){}function Ese(){}function Dse(){}function tn(){}function Ose(){}function nn(){}function rn(){}function kse(){}function Ase(){}function jse(){}function Mse(){}function Nse(){}function Pse(){}function Fse(){}function Ise(){}function an(){}function Lse(){}function Rse(){}function on(){}function zse(){}function sn(){}function Bse(){}function Vse(){}function Hse(){}function cn(){}function Use(){}function Wse(){}function Gse(){}function Kse(){}function qse(){}function Jse(){}function Yse(){}function Xse(){}function Zse(){}function Qse(){}function $se(){}function ece(){}function tce(){}function nce(){}function rce(){}function ice(){}function ln(){}function un(){}function ace(){}function oce(){}function sce(){}function cce(){}function lce(){}function uce(){}function dce(){}function fce(){}function pce(){}function mce(){}function hce(){}function gce(){}function _ce(){}function vce(){}function yce(){}function bce(){}function xce(){}function Sce(){}function Cce(){}function wce(){}function Tce(){}function Ece(){}function Dce(){}function Oce(){}function kce(){}function Ace(){}function jce(){}function Mce(){}function Nce(){}function Pce(){}function Fce(){}function Ice(){}function Lce(){}function Rce(){}function zce(){}function Bce(){}function Vce(){}function Hce(){}function Uce(){}function Wce(){}function Gce(){}function Kce(){}function qce(){}function Jce(){}function Yce(){}function Xce(){}function Zce(){}function Qce(){}function $ce(){}function ele(){}function tle(){}function nle(){}function rle(){}function ile(){}function ale(){}function ole(){}function sle(){}function cle(){}function lle(){}function ule(){}function dle(){}function fle(){}function ple(){}function mle(){}function hle(){}function gle(){}function _le(){}function vle(){}function yle(){}function ble(){}function xle(){}function Sle(){}function Cle(){}function wle(){}function Tle(){}function Ele(){}function Dle(){}function Ole(){}function kle(){}function Ale(){}function jle(){}function Mle(){}function Nle(){}function Ple(){}function Fle(){}function Ile(){}function Lle(){}function Rle(){}function zle(){}function Ble(){}function Vle(){}function Hle(){}function Ule(){}function Wle(){}function Gle(){}function Kle(){}function qle(){}function Jle(){}function Yle(){}function Xle(){}function Zle(){}function Qle(){}function $le(){}function eue(){}function dn(){fi()}function tue(){Fo()}function nue(){Rk()}function rue(){qw()}function iue(){bO()}function aue(){I9e()}function oue(){XM()}function sue(){e6e()}function cue(){Nk()}function lue(){Io()}function uue(){Ff()}function due(){Ibe()}function fue(){cC()}function pue(){sWe()}function mue(){mJe()}function hue(){DRe()}function gue(){gJe()}function _ue(){eGe()}function vue(){TRe()}function yue(){Fw()}function bue(){vJe()}function xue(){_Je()}function Sue(){HBe()}function Cue(){yJe()}function wue(){wA()}function Tue(){Ro()}function Eue(){bP()}function Due(){mP()}function Oue(){bJe()}function kue(){kYe()}function Aue(){ORe()}function jue(){o6e()}function Mue(){kRe()}function Nue(){Aut()}function Pue(){Hrt()}function Fue(){zx()}function Iue(){Q$e()}function Lue(){rN()}function Rue(){fze()}function zue(){Rx()}function Bue(){Ylt()}function Vue(){PA()}function Hue(){Qlt()}function Uue(){gM()}function Wue(){yA()}function Gue(){bM()}function Kue(){ek()}function fn(){rke()}function que(){gb()}function Jue(){bA()}function Yue(){vP()}function Xue(){Iw()}function Zue(){wD()}function Que(){uC()}function $ue(){_N()}function ede(){Odt()}function tde(e){Gh(e)}function nde(e){this.a=e}function pn(e){this.a=e}function rde(e){this.a=e}function ide(e){this.a=e}function ade(e){this.a=e}function ode(e){this.a=e}function sde(e){this.a=e}function cde(e){this.a=e}function mn(e){this.a=e}function hn(e){this.a=e}function lde(e){this.a=e}function ude(e){this.a=e}function gn(e){this.a=e}function dde(e){this.a=e}function fde(e){this.a=e}function _n(e){this.a=e}function vn(e){this.a=e}function pde(e){this.a=e}function yn(e){this.a=e}function mde(e){this.a=e}function hde(e){this.a=e}function gde(e){this.a=e}function bn(e){this.b=e}function _de(e){this.c=e}function vde(e){this.a=e}function yde(e){this.a=e}function bde(e){this.a=e}function xde(e){this.a=e}function Sde(e){this.a=e}function Cde(e){this.a=e}function wde(e){this.a=e}function Tde(e){this.a=e}function Ede(e){this.a=e}function Dde(e){this.a=e}function Ode(e){this.a=e}function kde(e){this.a=e}function Ade(e){this.a=e}function xn(e){this.a=e}function Sn(e){this.a=e}function Cn(e){this.a=e}function wn(e){this.a=e}function Tn(){this.a=[]}function jde(e,t){e.a=t}function Mde(e,t){e.a=t}function Nde(e,t){e.b=t}function Pde(e,t){e.b=t}function Fde(e,t){e.b=t}function Ide(e,t){e.j=t}function Lde(e,t){e.g=t}function Rde(e,t){e.i=t}function zde(e,t){e.c=t}function Bde(e,t){e.c=t}function Vde(e,t){e.d=t}function Hde(e,t){e.d=t}function En(e,t){e.k=t}function Ude(e,t){e.c=t}function Wde(e,t){e.c=t}function Gde(e,t){e.a=t}function Kde(e,t){e.a=t}function qde(e,t){e.f=t}function Jde(e,t){e.a=t}function Yde(e,t){e.b=t}function Dn(e,t){e.d=t}function On(e,t){e.i=t}function Xde(e,t){e.o=t}function Zde(e,t){e.r=t}function Qde(e,t){e.a=t}function $de(e,t){e.b=t}function efe(e,t){e.e=t}function tfe(e,t){e.f=t}function nfe(e,t){e.g=t}function rfe(e,t){e.e=t}function ife(e,t){e.f=t}function afe(e,t){e.f=t}function kn(e,t){e.a=t}function An(e,t){e.b=t}function ofe(e,t){e.n=t}function sfe(e,t){e.a=t}function cfe(e,t){e.c=t}function lfe(e,t){e.c=t}function ufe(e,t){e.c=t}function dfe(e,t){e.a=t}function ffe(e,t){e.a=t}function pfe(e,t){e.d=t}function mfe(e,t){e.d=t}function hfe(e,t){e.e=t}function gfe(e,t){e.e=t}function _fe(e,t){e.g=t}function vfe(e,t){e.f=t}function yfe(e,t){e.j=t}function bfe(e,t){e.a=t}function xfe(e,t){e.a=t}function Sfe(e,t){e.b=t}function Cfe(e){e.b=e.a}function wfe(e){e.c=e.d.d}function jn(e){this.a=e}function Mn(e){this.a=e}function Nn(e){this.a=e}function Pn(e){this.a=e}function Fn(e){this.a=e}function In(e){this.a=e}function Tfe(e){this.a=e}function Ln(e){this.a=e}function Rn(e){this.a=e}function zn(e){this.a=e}function Bn(e){this.a=e}function Vn(e){this.a=e}function Efe(e){this.a=e}function Dfe(e){this.a=e}function Hn(e){this.b=e}function Un(e){this.b=e}function Wn(e){this.b=e}function Gn(e){this.a=e}function Ofe(e){this.a=e}function Kn(e){this.c=e}function w(e){this.c=e}function kfe(e){this.c=e}function qn(e){this.d=e}function Jn(e){this.a=e}function Yn(e){this.a=e}function Afe(e){this.a=e}function Xn(e){this.a=e}function Zn(e){this.a=e}function Qn(e){this.a=e}function $n(e){this.a=e}function er(e){this.a=e}function tr(e){this.a=e}function nr(e){this.a=e}function jfe(e){this.a=e}function Mfe(e){this.a=e}function rr(e){this.a=e}function Nfe(e){this.a=e}function Pfe(e){this.a=e}function Ffe(e){this.a=e}function Ife(e){this.a=e}function Lfe(e){this.a=e}function Rfe(e){this.a=e}function zfe(e){this.a=e}function Bfe(e){this.a=e}function Vfe(e){this.a=e}function Hfe(e){this.a=e}function Ufe(e){this.a=e}function Wfe(e){this.a=e}function Gfe(e){this.a=e}function Kfe(e){this.a=e}function qfe(e){this.a=e}function ir(e){this.a=e}function Jfe(e){this.a=e}function Yfe(e){this.a=e}function Xfe(e){this.a=e}function Zfe(e){this.a=e}function ar(e){this.a=e}function Qfe(e){this.a=e}function $fe(e){this.a=e}function or(e){this.a=e}function sr(e){this.a=e}function epe(e){this.a=e}function tpe(e){this.a=e}function npe(e){this.a=e}function rpe(e){this.a=e}function ipe(e){this.a=e}function ape(e){this.a=e}function cr(e){this.a=e}function lr(e){this.a=e}function ur(e){this.a=e}function dr(e){this.a=e}function fr(e){this.e=e}function pr(e){this.a=e}function ope(e){this.a=e}function mr(e){this.a=e}function spe(e){this.a=e}function cpe(e){this.a=e}function lpe(e){this.a=e}function upe(e){this.a=e}function dpe(e){this.a=e}function fpe(e){this.a=e}function ppe(e){this.a=e}function mpe(e){this.a=e}function hpe(e){this.a=e}function gpe(e){this.a=e}function _pe(e){this.a=e}function vpe(e){this.a=e}function ype(e){this.a=e}function bpe(e){this.a=e}function xpe(e){this.a=e}function Spe(e){this.a=e}function Cpe(e){this.a=e}function wpe(e){this.a=e}function Tpe(e){this.a=e}function Epe(e){this.a=e}function Dpe(e){this.a=e}function Ope(e){this.a=e}function kpe(e){this.a=e}function Ape(e){this.a=e}function jpe(e){this.a=e}function Mpe(e){this.a=e}function Npe(e){this.a=e}function Ppe(e){this.a=e}function Fpe(e){this.a=e}function Ipe(e){this.a=e}function Lpe(e){this.a=e}function Rpe(e){this.a=e}function zpe(e){this.a=e}function Bpe(e){this.a=e}function Vpe(e){this.a=e}function Hpe(e){this.a=e}function Upe(e){this.a=e}function Wpe(e){this.a=e}function Gpe(e){this.a=e}function Kpe(e){this.a=e}function qpe(e){this.a=e}function Jpe(e){this.a=e}function Ype(e){this.a=e}function Xpe(e){this.a=e}function Zpe(e){this.a=e}function Qpe(e){this.a=e}function $pe(e){this.a=e}function eme(e){this.a=e}function tme(e){this.a=e}function nme(e){this.a=e}function rme(e){this.a=e}function ime(e){this.c=e}function ame(e){this.b=e}function ome(e){this.a=e}function sme(e){this.a=e}function cme(e){this.a=e}function lme(e){this.a=e}function ume(e){this.a=e}function dme(e){this.a=e}function fme(e){this.a=e}function pme(e){this.a=e}function mme(e){this.a=e}function hme(e){this.a=e}function gme(e){this.a=e}function _me(e){this.a=e}function vme(e){this.a=e}function yme(e){this.a=e}function bme(e){this.a=e}function xme(e){this.a=e}function Sme(e){this.a=e}function Cme(e){this.a=e}function wme(e){this.a=e}function Tme(e){this.a=e}function Eme(e){this.a=e}function Dme(e){this.a=e}function Ome(e){this.a=e}function kme(e){this.a=e}function Ame(e){this.a=e}function jme(e){this.a=e}function Mme(e){this.a=e}function hr(e){this.a=e}function gr(e){this.a=e}function Nme(e){this.a=e}function Pme(e){this.a=e}function Fme(e){this.a=e}function Ime(e){this.a=e}function Lme(e){this.a=e}function Rme(e){this.a=e}function zme(e){this.a=e}function Bme(e){this.a=e}function Vme(e){this.a=e}function Hme(e){this.a=e}function Ume(e){this.a=e}function Wme(e){this.a=e}function Gme(e){this.a=e}function Kme(e){this.a=e}function qme(e){this.a=e}function Jme(e){this.a=e}function Yme(e){this.a=e}function Xme(e){this.a=e}function Zme(e){this.a=e}function Qme(e){this.a=e}function $me(e){this.a=e}function ehe(e){this.a=e}function the(e){this.a=e}function nhe(e){this.a=e}function rhe(e){this.a=e}function ihe(e){this.a=e}function _r(e){this.a=e}function ahe(e){this.f=e}function ohe(e){this.a=e}function she(e){this.a=e}function che(e){this.a=e}function lhe(e){this.a=e}function uhe(e){this.a=e}function dhe(e){this.a=e}function fhe(e){this.a=e}function phe(e){this.a=e}function mhe(e){this.a=e}function hhe(e){this.a=e}function ghe(e){this.a=e}function _he(e){this.a=e}function vhe(e){this.a=e}function yhe(e){this.a=e}function bhe(e){this.a=e}function xhe(e){this.a=e}function She(e){this.a=e}function Che(e){this.a=e}function whe(e){this.a=e}function The(e){this.a=e}function Ehe(e){this.a=e}function Dhe(e){this.a=e}function Ohe(e){this.a=e}function khe(e){this.a=e}function Ahe(e){this.a=e}function jhe(e){this.a=e}function Mhe(e){this.a=e}function Nhe(e){this.a=e}function vr(e){this.a=e}function Phe(e){this.a=e}function yr(e){this.b=e}function Fhe(e){this.a=e}function Ihe(e){this.a=e}function Lhe(e){this.a=e}function Rhe(e){this.a=e}function zhe(e){this.a=e}function Bhe(e){this.a=e}function Vhe(e){this.a=e}function Hhe(e){this.b=e}function Uhe(e){this.a=e}function br(e){this.a=e}function Whe(e){this.a=e}function Ghe(e){this.a=e}function Khe(e){this.c=e}function xr(e){this.e=e}function Sr(e){this.a=e}function Cr(e){this.a=e}function wr(e){this.a=e}function qhe(e){this.d=e}function Jhe(e){this.a=e}function Yhe(e){this.a=e}function Xhe(e){this.a=e}function Tr(e){this.e=e}function Er(){this.a=0}function Dr(){Pm(this)}function T(){au(this)}function Or(){_Fe(this)}function Zhe(){}function kr(){this.c=nHt}function Qhe(e,t){e.b+=t}function $he(e,t){t.Wb(e)}function ege(e){return e.a}function tge(e){return e.a}function nge(e){return e.a}function rge(e){return e.a}function ige(e){return e.a}function E(e){return e.e}function age(){return null}function oge(){return null}function sge(){La(),P_t()}function cge(e){e.b.Of(e.e)}function lge(e){e.b=new la}function Ar(e,t){e.b=t-e.b}function jr(e,t){e.a=t-e.a}function Mr(e,t){e.push(t)}function uge(e,t){e.sort(t)}function dge(e,t){t.jd(e.a)}function fge(e,t){tj(t,e)}function pge(e,t,n){e.Yd(n,t)}function Nr(e,t){e.e=t,t.b=e}function mge(e){wf(),this.a=e}function hge(e){wf(),this.a=e}function gge(e){wf(),this.a=e}function Pr(e){gh(),this.a=e}function _ge(e){Xg(),lG.le(e)}function vge(){vge=C,new Dr}function Fr(){WTe.call(this)}function yge(){WTe.call(this)}function bge(){Fr.call(this)}function Ir(){Fr.call(this)}function xge(){Fr.call(this)}function Lr(){Fr.call(this)}function Rr(){Fr.call(this)}function zr(){Fr.call(this)}function Br(){Fr.call(this)}function Vr(){Fr.call(this)}function Sge(){Fr.call(this)}function Hr(){Fr.call(this)}function Cge(){Fr.call(this)}function wge(){this.a=this}function Ur(){this.Bb|=256}function Tge(){this.b=new lCe}function Wr(e,t){e.length=t}function Gr(e,t){M(e.a,t)}function Ege(e,t){tet(e.c,t)}function Dge(e,t){Lm(e.b,t)}function Oge(e,t){JO(e.a,t)}function kge(e,t){$T(e.a,t)}function Kr(e,t){AC(e.e,t)}function qr(e){_j(e.c,e.b)}function Age(e,t){e.kc().Nb(t)}function jge(e){this.a=y1e(e)}function Jr(){this.a=new Dr}function Mge(){this.a=new Dr}function Nge(){this.a=new gbe}function Yr(){this.a=new T}function Xr(){this.a=new T}function Pge(){this.a=new T}function Zr(){this.a=new Xe}function Qr(){this.a=new qUe}function Fge(){this.a=new Vt}function Ige(){this.a=new wRe}function Lge(){this.a=new eOe}function Rge(){this.a=new T}function zge(){this.a=new T}function Bge(){this.a=new T}function Vge(){this.a=new T}function Hge(){this.d=new T}function Uge(){this.a=new Qze}function Wge(){this.a=new Jr}function Gge(){this.a=new Dr}function Kge(){this.b=new Dr}function qge(){this.b=new T}function Jge(){this.e=new T}function Yge(){this.a=new wue}function Xge(){this.d=new T}function Zge(){QIe.call(this)}function Qge(){QIe.call(this)}function $ge(){T.call(this)}function e_e(){bge.call(this)}function $r(){Yr.call(this)}function t_e(){Qd.call(this)}function n_e(){Vge.call(this)}function ei(){Zhe.call(this)}function ti(){ei.call(this)}function ni(){Zhe.call(this)}function ri(){ni.call(this)}function r_e(){b_e.call(this)}function i_e(){b_e.call(this)}function a_e(){b_e.call(this)}function o_e(){C_e.call(this)}function ii(){Ose.call(this)}function s_e(){Ose.call(this)}function ai(){vo.call(this)}function c_e(){E_e.call(this)}function l_e(){E_e.call(this)}function u_e(){Dr.call(this)}function d_e(){Dr.call(this)}function f_e(){Dr.call(this)}function oi(){EJe.call(this)}function p_e(){Jr.call(this)}function m_e(){Ur.call(this)}function si(){gTe.call(this)}function ci(){Dr.call(this)}function li(){gTe.call(this)}function ui(){Dr.call(this)}function h_e(){Dr.call(this)}function g_e(){sn.call(this)}function __e(){g_e.call(this)}function v_e(){sn.call(this)}function y_e(){Qle.call(this)}function b_e(){this.a=new Jr}function x_e(){this.a=new Dr}function S_e(){this.a=new T}function C_e(){this.a=new Dr}function di(){this.a=new vo}function w_e(){this.j=new T}function T_e(){this.a=new bye}function E_e(){this.a=new zse}function D_e(){this.a=new goe}function fi(){fi=C,GW=new o}function pi(){pi=C,XW=new k_e}function mi(){mi=C,ZW=new O_e}function O_e(){_n.call(this,``)}function k_e(){_n.call(this,``)}function A_e(e){mqe.call(this,e)}function j_e(e){mqe.call(this,e)}function M_e(e){mn.call(this,e)}function N_e(e){nbe.call(this,e)}function P_e(e){nbe.call(this,e)}function F_e(e){N_e.call(this,e)}function I_e(e){N_e.call(this,e)}function L_e(e){N_e.call(this,e)}function R_e(e){ny.call(this,e)}function z_e(e){ny.call(this,e)}function B_e(e){VOe.call(this,e)}function V_e(e){obe.call(this,e)}function hi(e){lo.call(this,e)}function gi(e){lo.call(this,e)}function H_e(e){lo.call(this,e)}function _i(e){P9e.call(this,e)}function vi(e){_i.call(this,e)}function yi(e){KNe.call(this,e)}function U_e(e){yi.call(this,e)}function bi(){wn.call(this,{})}function W_e(){W_e=C,zTt=new te}function xi(){xi=C,tG=new Vwe}function G_e(){G_e=C,iG=new a}function Si(){Si=C,cG=new v}function Ci(){Ci=C,dG=new x}function wi(e){Bu(),this.a=e}function Ti(e){lC(),this.a=e}function Ei(e){em(),this.f=e}function Di(e){em(),this.f=e}function K_e(e){nke(),this.a=e}function q_e(e){e.b=null,e.c=0}function J_e(e,t){e.e=t,Sst(e,t)}function Y_e(e,t){e.a=t,ott(e)}function Oi(e,t,n){e.a[t.g]=n}function X_e(e,t,n){y8e(n,e,t)}function Z_e(e,t){HOe(t.i,e.n)}function Q_e(e,t){ZZe(e).Cd(t)}function $_e(e,t){e.a.ec().Mc(t)}function eve(e,t){return e.g-t.g}function tve(e,t){return e*e/t}function ki(e){return Gh(e),e}function D(e){return Gh(e),e}function Ai(e){return Gh(e),e}function nve(e){return new Cn(e)}function rve(e){return new mh(e)}function ive(e){return Gh(e),e}function ave(e){return Gh(e),e}function ji(e){yi.call(this,e)}function Mi(e){yi.call(this,e)}function ove(e){yi.call(this,e)}function Ni(e){KNe.call(this,e)}function Pi(e){yi.call(this,e)}function Fi(e){yi.call(this,e)}function Ii(e){yi.call(this,e)}function sve(e){yi.call(this,e)}function Li(e){yi.call(this,e)}function Ri(e){yi.call(this,e)}function zi(e){yi.call(this,e)}function Bi(e){yi.call(this,e)}function Vi(e){yi.call(this,e)}function Hi(e){yi.call(this,e)}function Ui(e){yi.call(this,e)}function Wi(e){Gh(e),this.a=e}function Gi(e){return Tw(e),e}function Ki(e){CPe(e,e.length)}function qi(e){return e.b==e.c}function Ji(e){return!!e&&e.b}function cve(e){return!!e&&e.k}function lve(e){return!!e&&e.j}function uve(e,t,n){e.c.Ef(t,n)}function dve(e,t){e.be(t),t.ae(e)}function Yi(e){wf(),this.a=ph(e)}function Xi(){this.a=kd(ph(PP))}function fve(){throw E(new Br)}function pve(){throw E(new Br)}function Zi(){throw E(new Br)}function mve(){throw E(new Br)}function hve(){throw E(new Br)}function gve(){throw E(new Br)}function Qi(){Qi=C,Xg()}function $i(){In.call(this,``)}function ea(){In.call(this,``)}function ta(){In.call(this,``)}function na(){In.call(this,``)}function ra(e){Mi.call(this,e)}function ia(e){Mi.call(this,e)}function aa(e){Fi.call(this,e)}function oa(e){Wn.call(this,e)}function _ve(e){oa.call(this,e)}function sa(e){qu.call(this,e)}function ca(e){sEe.call(this,e,0)}function la(){URe.call(this,12,3)}function O(e,t){return _Re(e,t)}function ua(e,t){return yb(e,t)}function vve(e,t){return e.a-t.a}function yve(e,t){return e.a-t.a}function bve(e,t){return e.a-t.a}function xve(e,t){return t in e.a}function Sve(e){return e.a?e.b:0}function Cve(e){return e.a?e.b:0}function wve(e,t,n){t.Cd(e.a[n])}function Tve(e,t,n){t.Pe(e.a[n])}function Eve(e,t){e.b=new Vl(t)}function Dve(e,t){return e.b=t,e}function Ove(e,t){return e.c=t,e}function kve(e,t){return e.f=t,e}function Ave(e,t){return e.g=t,e}function da(e,t){return e.a=t,e}function fa(e,t){return e.f=t,e}function jve(e,t){return e.k=t,e}function pa(e,t){return e.a=t,e}function Mve(e,t){return e.e=t,e}function ma(e,t){return e.e=t,e}function Nve(e,t){return e.f=t,e}function Pve(e,t){e.b=!0,e.d=t}function Fve(e,t){return e.b-t.b}function Ive(e,t){return e.g-t.g}function Lve(e,t){return e?0:t-1}function Rve(e,t){return e?0:t-1}function zve(e,t){return e?t-1:0}function Bve(e,t){return e.s-t.s}function Vve(e,t){return t.rg(e)}function ha(e,t){return e.b=t,e}function ga(e,t){return e.a=t,e}function _a(e,t){return e.c=t,e}function va(e,t){return e.d=t,e}function ya(e,t){return e.e=t,e}function ba(e,t){return e.f=t,e}function xa(e,t){return e.a=t,e}function Sa(e,t){return e.b=t,e}function Ca(e,t){return e.c=t,e}function wa(e,t){return e.c=t,e}function Ta(e,t){return e.b=t,e}function Ea(e,t){return e.d=t,e}function Da(e,t){return e.e=t,e}function Hve(e,t){return e.f=t,e}function Oa(e,t){return e.g=t,e}function ka(e,t){return e.a=t,e}function Aa(e,t){return e.i=t,e}function ja(e,t){return e.j=t,e}function Uve(e,t){wA(),G_(t,e)}function Wve(e,t,n){CNe(e.a,t,n)}function Ma(e){yf.call(this,e)}function Gve(e){L1e.call(this,e)}function Kve(e){uIe.call(this,e)}function Na(e){uIe.call(this,e)}function Pa(e){kx.call(this,e)}function qve(e){Ig.call(this,e)}function Jve(e){Ig.call(this,e)}function Yve(){Dwe.call(this,``)}function Fa(){this.a=0,this.b=0}function Xve(){this.b=0,this.a=0}function Zve(e,t){e.b=0,Qx(e,t)}function Qve(e,t){return e.k=t,e}function $ve(e,t){return e.j=t,e}function eye(e,t){e.c=t,e.b=!0}function tye(){tye=C,rEt=c5e()}function Ia(){Ia=C,iVt=X6e()}function nye(){nye=C,Y5=X5e()}function La(){La=C,h7=dS()}function Ra(){Ra=C,R7=Z6e()}function rye(){rye=C,wHt=Q6e()}function za(){za=C,b9=rtt()}function Ba(e){return e.e&&e.e()}function iye(e){return e.l|e.m<<22}function aye(e,t){return e.c._b(t)}function oye(e,t){return E$e(e.b,t)}function Va(e){return e?e.d:null}function sye(e){return e?e.g:null}function cye(e){return e?e.i:null}function Ha(e){return Ad(e),e.o}function Ua(e,t){return e.a+=t,e}function Wa(e,t){return e.a+=t,e}function Ga(e,t){return e.a+=t,e}function Ka(e,t){return e.a+=t,e}function lye(e,t){for(;e.Bd(t););}function qa(e){this.a=new go(e)}function uye(){throw E(new Br)}function dye(){throw E(new Br)}function fye(){throw E(new Br)}function pye(){throw E(new Br)}function mye(){throw E(new Br)}function hye(){throw E(new Br)}function Ja(e){this.a=new mm(e)}function gye(){this.a=new Yj(NFt)}function _ye(){this.b=new Yj(yPt)}function vye(){this.a=new Yj(kIt)}function yye(){this.b=new Yj(_3)}function bye(){this.b=new Yj(_3)}function Ya(e){this.a=0,this.b=e}function xye(e){Ngt(),tvt(this,e)}function Xa(e){return Hh(e),e.a}function Za(e){return e.b!=e.d.c}function Sye(e,t){return e.d[t.p]}function Cye(e,t){return bst(e,t)}function wye(e,t,n){e.splice(t,n)}function Qa(e,t){for(;e.Re(t););}function Tye(e){e.c?gct(e):_ct(e)}function Eye(){throw E(new Br)}function Dye(){throw E(new Br)}function Oye(){throw E(new Br)}function kye(){throw E(new Br)}function Aye(){throw E(new Br)}function jye(){throw E(new Br)}function Mye(){throw E(new Br)}function Nye(){throw E(new Br)}function Pye(){throw E(new Br)}function Fye(){throw E(new Br)}function Iye(){throw E(new Hr)}function Lye(){throw E(new Hr)}function $a(e){this.a=new Rye(e)}function Rye(e){IJe(this,e,B9e())}function eo(e){return!e||mFe(e)}function to(e){return A9[e]!=-1}function zye(){oG!=0&&(oG=0),sG=-1}function Bye(){xTt??=[]}function no(e,t){zu.call(this,e,t)}function ro(e,t){no.call(this,e,t)}function Vye(e,t){this.a=e,this.b=t}function Hye(e,t){this.a=e,this.b=t}function Uye(e,t){this.a=e,this.b=t}function Wye(e,t){this.a=e,this.b=t}function Gye(e,t){this.a=e,this.b=t}function Kye(e,t){this.a=e,this.b=t}function qye(e,t){this.a=e,this.b=t}function io(e,t){this.e=e,this.d=t}function Jye(e,t){this.b=e,this.c=t}function Yye(e,t){this.b=e,this.a=t}function Xye(e,t){this.b=e,this.a=t}function Zye(e,t){this.b=e,this.a=t}function Qye(e,t){this.b=e,this.a=t}function $ye(e,t){this.a=e,this.b=t}function ao(e,t){this.a=e,this.b=t}function ebe(e,t){this.a=e,this.f=t}function oo(e,t){this.g=e,this.i=t}function so(e,t){this.f=e,this.g=t}function tbe(e,t){this.b=e,this.c=t}function nbe(e){vTe(e.dc()),this.c=e}function rbe(e,t){this.a=e,this.b=t}function ibe(e,t){this.a=e,this.b=t}function abe(e){this.a=P(ph(e),15)}function obe(e){this.a=P(ph(e),15)}function sbe(e){this.a=P(ph(e),85)}function co(e){this.b=P(ph(e),85)}function lo(e){this.b=P(ph(e),51)}function uo(){this.q=new r.Date}function fo(e,t){this.a=e,this.b=t}function cbe(e,t){return km(e.b,t)}function po(e,t){return e.b.Hc(t)}function lbe(e,t){return e.b.Ic(t)}function ube(e,t){return e.b.Qc(t)}function dbe(e,t){return e.b.Hc(t)}function fbe(e,t){return e.c.uc(t)}function pbe(e,t){return NT(e.c,t)}function mo(e,t){return e.a._b(t)}function mbe(e,t){return e>t&&t0}function rs(e,t){return dT(e,t)<0}function exe(e,t){return Gp(e.a,t)}function txe(e,t){yRe.call(this,e,t)}function nxe(e){_h(),VOe.call(this,e)}function rxe(e,t){mNe(e,e.length,t)}function is(e,t){NPe(e,e.length,t)}function as(e,t){return e.a.get(t)}function ixe(e,t){return km(e.e,t)}function os(e){return Gh(e),!1}function ss(e){this.a=P(ph(e),229)}function cs(e){cv.call(this,e,21)}function ls(e,t){so.call(this,e,t)}function us(e,t){so.call(this,e,t)}function axe(e,t){this.b=e,this.a=t}function ds(e,t){this.d=e,this.e=t}function oxe(e,t){this.a=e,this.b=t}function sxe(e,t){this.a=e,this.b=t}function cxe(e,t){this.a=e,this.b=t}function lxe(e,t){this.a=e,this.b=t}function fs(e,t){this.a=e,this.b=t}function uxe(e,t){this.b=e,this.a=t}function dxe(e,t){this.b=e,this.a=t}function fxe(e,t){so.call(this,e,t)}function pxe(e,t){so.call(this,e,t)}function ps(e,t){so.call(this,e,t)}function ms(e,t){so.call(this,e,t)}function hs(e,t){so.call(this,e,t)}function gs(e,t){so.call(this,e,t)}function _s(e,t){so.call(this,e,t)}function vs(e,t){this.b=e,this.a=t}function ys(e,t){so.call(this,e,t)}function bs(e,t){this.b=e,this.a=t}function xs(e,t){so.call(this,e,t)}function mxe(e,t){this.b=e,this.a=t}function Ss(e,t){so.call(this,e,t)}function Cs(e,t){so.call(this,e,t)}function ws(e,t){so.call(this,e,t)}function Ts(e,t,n){e.splice(t,0,n)}function hxe(e,t,n){e.Mb(n)&&t.Cd(n)}function gxe(e,t,n){t.Pe(e.a.Ye(n))}function _xe(e,t,n){t.Dd(e.a.Ze(n))}function vxe(e,t,n){t.Cd(e.a.Kb(n))}function yxe(e,t){return $u(e.c,t)}function bxe(e,t){return $u(e.e,t)}function Es(e,t){so.call(this,e,t)}function Ds(e,t){so.call(this,e,t)}function Os(e,t){so.call(this,e,t)}function xxe(e,t){so.call(this,e,t)}function ks(e,t){so.call(this,e,t)}function As(e,t){so.call(this,e,t)}function Sxe(e,t){this.a=e,this.b=t}function Cxe(e,t){this.a=e,this.b=t}function wxe(e,t){this.a=e,this.b=t}function Txe(e,t){this.a=e,this.b=t}function Exe(e,t){this.a=e,this.b=t}function Dxe(e,t){this.a=e,this.b=t}function Oxe(e,t){this.b=e,this.a=t}function kxe(e,t){this.b=e,this.a=t}function Axe(e,t){this.b=e,this.a=t}function js(e,t){this.c=e,this.d=t}function jxe(e,t){this.e=e,this.d=t}function Mxe(e,t){this.a=e,this.b=t}function Nxe(e,t){this.a=e,this.b=t}function Pxe(e,t){this.a=e,this.b=t}function Fxe(e,t){this.b=e,this.a=t}function Ixe(e,t){this.b=t,this.c=e}function Ms(e,t){so.call(this,e,t)}function Ns(e,t){so.call(this,e,t)}function Ps(e,t){so.call(this,e,t)}function Lxe(e,t){so.call(this,e,t)}function Fs(e,t){so.call(this,e,t)}function Is(e,t){so.call(this,e,t)}function Ls(e,t){so.call(this,e,t)}function Rs(e,t){so.call(this,e,t)}function zs(e,t){so.call(this,e,t)}function Bs(e,t){so.call(this,e,t)}function Vs(e,t){so.call(this,e,t)}function Hs(e,t){so.call(this,e,t)}function Us(e,t){so.call(this,e,t)}function Ws(e,t){so.call(this,e,t)}function Gs(e,t){so.call(this,e,t)}function Ks(e,t){so.call(this,e,t)}function qs(e,t){so.call(this,e,t)}function Js(e,t){so.call(this,e,t)}function Ys(e,t){so.call(this,e,t)}function Xs(e,t){so.call(this,e,t)}function Zs(e,t){so.call(this,e,t)}function Qs(e,t){so.call(this,e,t)}function $s(e,t){so.call(this,e,t)}function ec(e,t){so.call(this,e,t)}function tc(e,t){so.call(this,e,t)}function nc(e,t){so.call(this,e,t)}function rc(e,t){so.call(this,e,t)}function ic(e,t){so.call(this,e,t)}function ac(e,t){so.call(this,e,t)}function oc(e,t){so.call(this,e,t)}function sc(e,t){so.call(this,e,t)}function cc(e,t){so.call(this,e,t)}function lc(e,t){so.call(this,e,t)}function Rxe(e,t){this.b=e,this.a=t}function zxe(e,t){so.call(this,e,t)}function Bxe(e,t){this.a=e,this.b=t}function Vxe(e,t){this.a=e,this.b=t}function Hxe(e,t){this.a=e,this.b=t}function Uxe(e,t){so.call(this,e,t)}function Wxe(e,t){so.call(this,e,t)}function Gxe(e,t){this.a=e,this.b=t}function Kxe(e,t){return Rf(),t!=e}function uc(e){return jd(e.a),e.b}function dc(e){return Drt(e,e.c),e}function qxe(){return tye(),new rEt}function Jxe(){If(),this.a=new Zd}function Yxe(){rM(),this.a=new Jr}function Xxe(){B_(),this.b=new Jr}function Zxe(e,t){this.b=e,this.d=t}function Qxe(e,t){this.a=e,this.b=t}function $xe(e,t){this.a=e,this.b=t}function eSe(e,t){this.a=e,this.b=t}function tSe(e,t){this.b=e,this.a=t}function nSe(e,t){so.call(this,e,t)}function rSe(e,t){so.call(this,e,t)}function fc(e,t){so.call(this,e,t)}function pc(e,t){so.call(this,e,t)}function mc(e,t){so.call(this,e,t)}function hc(e,t){so.call(this,e,t)}function iSe(e,t){so.call(this,e,t)}function aSe(e,t){so.call(this,e,t)}function gc(e,t){so.call(this,e,t)}function oSe(e,t){so.call(this,e,t)}function _c(e,t){so.call(this,e,t)}function vc(e,t){so.call(this,e,t)}function yc(e,t){so.call(this,e,t)}function bc(e,t){so.call(this,e,t)}function xc(e,t){so.call(this,e,t)}function Sc(e,t){so.call(this,e,t)}function sSe(e,t){so.call(this,e,t)}function Cc(e,t){so.call(this,e,t)}function cSe(e,t){so.call(this,e,t)}function wc(e,t){so.call(this,e,t)}function Tc(e,t){so.call(this,e,t)}function lSe(e,t){so.call(this,e,t)}function Ec(e,t){so.call(this,e,t)}function uSe(e,t){so.call(this,e,t)}function dSe(e,t){this.b=e,this.a=t}function fSe(e,t){this.b=e,this.a=t}function pSe(e,t){this.b=e,this.a=t}function mSe(e,t){this.b=e,this.a=t}function hSe(e,t){this.a=e,this.b=t}function gSe(e,t){this.a=e,this.b=t}function _Se(e,t){this.a=e,this.b=t}function k(e,t){this.a=e,this.b=t}function Dc(e,t){so.call(this,e,t)}function Oc(e,t){so.call(this,e,t)}function kc(e,t){so.call(this,e,t)}function Ac(e,t){so.call(this,e,t)}function jc(e,t){so.call(this,e,t)}function Mc(e,t){so.call(this,e,t)}function Nc(e,t){so.call(this,e,t)}function Pc(e,t){so.call(this,e,t)}function Fc(e,t){so.call(this,e,t)}function Ic(e,t){so.call(this,e,t)}function Lc(e,t){so.call(this,e,t)}function Rc(e,t){so.call(this,e,t)}function zc(e,t){so.call(this,e,t)}function Bc(e,t){so.call(this,e,t)}function Vc(e,t){so.call(this,e,t)}function Hc(e,t){so.call(this,e,t)}function Uc(e,t){so.call(this,e,t)}function Wc(e,t){so.call(this,e,t)}function vSe(e,t){so.call(this,e,t)}function Gc(e,t){so.call(this,e,t)}function ySe(e,t){this.a=e,this.b=t}function bSe(e,t){this.a=e,this.b=t}function xSe(e,t){this.a=e,this.b=t}function SSe(e,t){this.a=e,this.b=t}function CSe(e,t){this.a=e,this.b=t}function wSe(e,t){this.a=e,this.b=t}function Kc(e,t){this.a=e,this.b=t}function TSe(e,t){this.a=e,this.b=t}function ESe(e,t){this.a=e,this.b=t}function DSe(e,t){this.a=e,this.b=t}function OSe(e,t){this.a=e,this.b=t}function kSe(e,t){this.a=e,this.b=t}function ASe(e,t){this.a=e,this.b=t}function jSe(e,t){this.b=e,this.a=t}function MSe(e,t){this.b=e,this.a=t}function NSe(e,t){this.b=e,this.a=t}function PSe(e,t){this.b=e,this.a=t}function FSe(e,t){this.a=e,this.b=t}function ISe(e,t){this.a=e,this.b=t}function qc(e,t){so.call(this,e,t)}function LSe(e,t){this.a=e,this.b=t}function RSe(e,t){this.a=e,this.b=t}function Jc(e,t){so.call(this,e,t)}function zSe(e,t){this.f=e,this.c=t}function Yc(e,t){return $u(e.g,t)}function BSe(e,t){return $u(t.b,e)}function VSe(e,t){return uD(e.a,t)}function HSe(e,t){return-e.b.af(t)}function USe(e,t){e&&Qh(f7,e,t)}function Xc(e,t){e.i=null,OS(e,t)}function WSe(e,t,n){I8e(t,KA(e,n))}function GSe(e,t,n){I8e(t,KA(e,n))}function KSe(e,t){not(e.a,P(t,58))}function qSe(e,t){KGe(e.a,P(t,12))}function Zc(e,t){this.a=e,this.b=t}function JSe(e,t){this.a=e,this.b=t}function YSe(e,t){this.a=e,this.b=t}function XSe(e,t){this.a=e,this.b=t}function ZSe(e,t){this.a=e,this.b=t}function QSe(e,t){this.d=e,this.b=t}function $Se(e,t){this.e=e,this.a=t}function Qc(e,t){this.b=e,this.c=t}function $c(e,t){this.i=e,this.g=t}function el(e,t){this.d=e,this.e=t}function eCe(e,t){kKe(new Lu(e),t)}function tl(e){return lD(e.c,e.b)}function nl(e){return e?e.md():null}function A(e){return e??null}function rl(e){return typeof e===OP}function il(e){return typeof e===DP}function al(e){return typeof e===Vvt}function ol(e,t){return dT(e,t)==0}function sl(e,t){return dT(e,t)>=0}function cl(e,t){return dT(e,t)!=0}function ll(e,t){return VYe(e.Kc(),t)}function ul(e,t){return e.Rd().Xb(t)}function tCe(e){return RE(e),e.d.gc()}function dl(e){return bp(e==null),e}function fl(e,t){return e.a+=``+t,e}function pl(e,t){return e.a+=``+t,e}function ml(e,t){return e.a+=``+t,e}function hl(e,t){return e.a+=``+t,e}function gl(e,t){return e.a+=``+t,e}function _l(e,t){return e.a+=``+t,e}function nCe(e){return``+(Gh(e),e)}function rCe(e){Pm(this),mC(this,e)}function iCe(){ERe(),bNe.call(this)}function aCe(e,t){GNe.call(this,e,t)}function oCe(e,t){GNe.call(this,e,t)}function vl(e,t){GNe.call(this,e,t)}function yl(e,t){iy(e,t,e.c.b,e.c)}function bl(e,t){iy(e,t,e.a,e.a.a)}function xl(e){return ov(e,0),null}function sCe(){this.b=0,this.a=!1}function cCe(){this.b=0,this.a=!1}function lCe(){this.b=new go(xx(12))}function uCe(){uCe=C,oDt=nT(sO())}function dCe(){dCe=C,NOt=nT(wot())}function fCe(){fCe=C,NPt=nT(qYe())}function Sl(){Sl=C,vge(),uG=new Dr}function Cl(e){return e.a=0,e.b=0,e}function pCe(e,t){return e.a=t.g+1,e}function wl(e,t){lf.call(this,e,t)}function Tl(e,t){Wd.call(this,e,t)}function El(e,t){$c.call(this,e,t)}function mCe(e,t){ad.call(this,e,t)}function Dl(e,t){WC.call(this,e,t)}function Ol(e,t){Jo(),Qh(v7,e,t)}function hCe(e,t){e.q.setTime(Dv(t))}function gCe(e){r.clearTimeout(e)}function _Ce(e){return ph(e),new Hl(e)}function vCe(e,t){return A(e)===A(t)}function yCe(e,t){return e.a.a.a.cc(t)}function kl(e,t){return p_(e.a,0,t)}function Al(e){return zPe(P(e,74))}function jl(e){return C_((Gh(e),e))}function bCe(e){return C_((Gh(e),e))}function xCe(e){return vu(e.l,e.m,e.h)}function Ml(e,t){return _u(e.a,t.a)}function SCe(e,t){return DPe(e.a,t.a)}function CCe(e,t){return aE(e.a,t.a)}function Nl(e,t){return e.indexOf(t)}function wCe(e,t){return e.j[t.p]==2}function Pl(e,t){return e==t?0:e?1:-1}function Fl(e){return e<10?`0`+e:``+e}function Il(e){return typeof e===Vvt}function TCe(e){return e==kJ||e==MJ}function ECe(e){return e==kJ||e==AJ}function DCe(e,t){return _u(e.g,t.g)}function Ll(e){return Ab(e.b.b,e,0)}function OCe(){Np.call(this,0,0,0,0)}function Rl(){Xn.call(this,new ry)}function zl(e,t){bb(e,0,e.length,t)}function kCe(e,t){return M(e.a,t),t}function ACe(e,t){return Lf(),t.a+=e}function jCe(e,t){return Lf(),t.a+=e}function MCe(e,t){return Lf(),t.c+=e}function NCe(e,t){return M(e.c,t),e}function Bl(e,t){return OC(e.a,t),e}function PCe(e){this.a=qxe(),this.b=e}function FCe(e){this.a=qxe(),this.b=e}function Vl(e){this.a=e.a,this.b=e.b}function Hl(e){this.a=e,dn.call(this)}function ICe(e){this.a=e,dn.call(this)}function Ul(){wg.call(this,0,0,0,0)}function Wl(e){return OC(new Zh,e)}function LCe(e){return ag(P(e,123))}function Gl(e){return e.vh()&&e.wh()}function Kl(e){return e!=V8&&e!=H8}function ql(e){return e==t8||e==n8}function Jl(e){return e==i8||e==e8}function RCe(e){return e==L0||e==I0}function zCe(e,t){return _u(e.g,t.g)}function BCe(e,t){return new WC(t,e)}function VCe(e,t){return new WC(t,e)}function Yl(e){return wje(e.b.Kc(),e.a)}function Xl(e,t){Gw(e,t),eS(e,e.D)}function Zl(e,t,n){Xx(e,t),Vx(e,n)}function Ql(e,t,n){Wx(e,t),Ux(e,n)}function $l(e,t,n){Gx(e,t),Kx(e,n)}function eu(e,t,n){Hx(e,t),Jx(e,n)}function tu(e,t,n){qx(e,t),Yx(e,n)}function HCe(e,t,n){mDe.call(this,e,t,n)}function nu(e){zSe.call(this,e,!0)}function UCe(){ls.call(this,`Tail`,3)}function WCe(){ls.call(this,`Head`,1)}function ru(e){AM(),IYe.call(this,e)}function iu(e){Np.call(this,e,e,e,e)}function au(e){e.c=V(WW,FP,1,0,5,1)}function GCe(e){return e.b&&yN(e),e.a}function KCe(e){return e.b&&yN(e),e.c}function qCe(e,t){_K||(e.b=t)}function JCe(e,t){return e[e.length]=t}function YCe(e,t){return e[e.length]=t}function XCe(e,t){return Ex(t,E_(e))}function ZCe(e,t){return Ex(t,E_(e))}function QCe(e,t){return yS(uh(e.d),t)}function $Ce(e,t){return yS(uh(e.g),t)}function ewe(e,t){return yS(uh(e.j),t)}function ou(e,t){Wd.call(this,e.b,t)}function twe(e,t){tb(Jv(e.a),IRe(t))}function nwe(e,t){tb(Ib(e.a),LRe(t))}function rwe(e,t,n){$l(n,n.i+e,n.j+t)}function iwe(e,t,n){Sh(e.c[t.g],t.g,n)}function awe(e,t,n){P(e.c,71).Gi(t,n)}function su(e,t,n){return Sh(e,t,n),n}function owe(e){Dx(e.Sf(),new Zfe(e))}function cu(e){return e==null?0:US(e)}function swe(e){return e==null?0:US(e)}function lu(e){xP(),Tr.call(this,e)}function cwe(e){this.a=e,xje.call(this,e)}function uu(){uu=C,r.Math.log(2)}function du(){du=C,s9=(Xbe(),mVt)}function lwe(){lwe=C,D2=new NE(p8)}function fu(){fu=C,new uwe,new T}function uwe(){new Dr,new Dr,new Dr}function dwe(){throw E(new Ri(_Tt))}function fwe(){throw E(new Ri(_Tt))}function pwe(){throw E(new Ri(vTt))}function mwe(){throw E(new Ri(vTt))}function pu(e){this.a=e,co.call(this,e)}function mu(e){this.a=e,co.call(this,e)}function hwe(e,t){gh(),this.a=e,this.b=t}function gwe(e,t){ph(t),bg(e).Jc(new m)}function hu(e,t){qp(e.c,e.c.length,t)}function gu(e){return e.at)}function ywe(e,t){return dT(e,t)>0?e:t}function vu(e,t,n){return{l:e,m:t,h:n}}function bwe(e,t){e.a!=null&&qSe(t,e.a)}function xwe(e){U_(e,null),K_(e,null)}function Swe(e,t,n){return Qh(e.g,n,t)}function yu(e,t,n){return AD(t,n,e.c)}function Cwe(e,t,n){return Qh(e.k,n,t)}function wwe(e,t,n){return kht(e,t,n),n}function Twe(e,t){return z_(),t.n.b+=e}function Ewe(e){r_.call(this),this.b=e}function Dwe(e){$De.call(this),this.a=e}function Owe(){ls.call(this,`Range`,2)}function bu(e){this.b=e,this.a=new T}function kwe(e){this.b=new jt,this.a=e}function Awe(e){e.a=new me,e.c=new me}function jwe(e){e.a=new Dr,e.d=new Dr}function Mwe(e){q_(e,null),J_(e,null)}function Nwe(e,t){return Nht(e.a,t,null)}function Pwe(e,t){return Qh(e.a,t.a,t)}function xu(e){return new k(e.a,e.b)}function Fwe(e){return new k(e.c,e.d)}function Iwe(e){return new k(e.c,e.d)}function Su(e,t){return xmt(e.c,e.b,t)}function j(e,t){return e!=null&&kO(e,t)}function Cu(e,t){return XXe(e.Kc(),t)!=-1}function wu(e){return e.Ob()?e.Pb():null}function Lwe(e){this.b=(Vg(),new Kn(e))}function Rwe(e){this.a=e,Dr.call(this)}function zwe(){ad.call(this,null,null)}function Bwe(){od.call(this,null,null)}function Vwe(){so.call(this,`INSTANCE`,0)}function Hwe(){i8e(),this.a=new Yj(CJ)}function Uwe(e){return ND(e,0,e.length)}function Wwe(e,t){return new PTe(e.Kc(),t)}function Gwe(e,t){return e.a.Bc(t)!=null}function Kwe(e,t){RN(e),e.Gc(P(t,15))}function qwe(e,t,n){e.c.bd(t,P(n,136))}function Jwe(e,t,n){e.c.Ui(t,P(n,136))}function Ywe(e,t){e.c&&(pMe(t),LLe(t))}function Xwe(e,t){e.q.setHours(t),dN(e,t)}function Zwe(e,t){Sd(t,e.a.a.a,e.a.a.b)}function Qwe(e,t,n,r){Sh(e.a[t.g],n.g,r)}function Tu(e,t,n){return e.a[t.g][n.g]}function $we(e,t){return e.e[t.c.p][t.p]}function eTe(e,t){return e.c[t.c.p][t.p]}function Eu(e,t){return e.a[t.c.p][t.p]}function tTe(e,t){return e.j[t.p]=Aat(t)}function Du(e,t){return e.a.Bc(t)!=null}function nTe(e,t){return D(N(t.a))<=e}function rTe(e,t){return D(N(t.a))>=e}function iTe(e,t){return zUe(e.f,t.Pg())}function Ou(e,t){return e.a*t.a+e.b*t.b}function aTe(e,t){return e.a0?t/(e*e):t*100}function SEe(e,t){return e>0?t*t/e:t*t*100}function xd(e,t){return P(ix(e.a,t),34)}function CEe(e,t){return wA(),fj(e,t.e,t)}function wEe(e,t,n){return zo(),n.Mg(e,t)}function TEe(e){return zx(),e.e.a+e.f.a/2}function EEe(e,t,n){return zx(),n.e.a-e*t}function DEe(e){return zx(),e.e.b+e.f.b/2}function OEe(e,t,n){return zx(),n.e.b-e*t}function kEe(e){e.d=new gEe(e),e.e=new Dr}function AEe(){this.a=new g_,this.b=new g_}function jEe(e){this.c=e,this.a=1,this.b=1}function MEe(e){dP(),lge(this),this.Ff(e)}function NEe(e,t,n){gb(),e.pf(t)&&n.Cd(e)}function PEe(e,t,n){return M(t,Y1e(e,n))}function Sd(e,t,n){return e.a+=t,e.b+=n,e}function FEe(e,t,n){return e.a*=t,e.b*=n,e}function IEe(e,t){return e.a=t.a,e.b=t.b,e}function Cd(e){return e.a=-e.a,e.b=-e.b,e}function wd(e,t,n){return e.a-=t,e.b-=n,e}function LEe(e){vo.call(this),_S(this,e)}function REe(){so.call(this,`GROW_TREE`,0)}function zEe(){so.call(this,`POLYOMINO`,0)}function Td(e,t,n){lb.call(this,e,t,n,2)}function BEe(e,t,n){WT(Jv(e.a),t,IRe(n))}function VEe(e,t){Yo(),ad.call(this,e,t)}function HEe(e,t){Xo(),od.call(this,e,t)}function UEe(e,t){Xo(),HEe.call(this,e,t)}function WEe(e,t){Xo(),od.call(this,e,t)}function GEe(e,t){return e.c.Fc(P(t,136))}function KEe(e,t,n){WT(Ib(e.a),t,LRe(n))}function qEe(e){this.c=e,Gx(e,0),Kx(e,0)}function Ed(e,t){du(),Bp.call(this,e,t)}function JEe(e,t){du(),Ed.call(this,e,t)}function YEe(e,t){du(),Ed.call(this,e,t)}function XEe(e,t){du(),Bp.call(this,e,t)}function ZEe(e,t){du(),YEe.call(this,e,t)}function QEe(e,t){du(),XEe.call(this,e,t)}function $Ee(e,t){du(),Bp.call(this,e,t)}function eDe(e,t,n){return t.zl(e.e,e.c,n)}function tDe(e,t,n){return t.Al(e.e,e.c,n)}function nDe(e,t,n){return jN(Lb(e,t),n)}function Dd(e,t){return pT(e.e,P(t,54))}function rDe(e){return e==null?null:Fgt(e)}function iDe(e){return e==null?null:G9e(e)}function aDe(e){return e==null?null:PE(e)}function oDe(e){return e==null?null:PE(e)}function Od(e){return bp(e==null||il(e)),e}function N(e){return bp(e==null||al(e)),e}function kd(e){return bp(e==null||rl(e)),e}function Ad(e){e.o??zit(e)}function sDe(e){if(!e)throw E(new Lr)}function cDe(e){if(!e)throw E(new Ir)}function jd(e){if(!e)throw E(new Hr)}function Md(e){if(!e)throw E(new Rr)}function lDe(e){if(!e)throw E(new Vr)}function Nd(){Nd=C,_7=new c_e,new l_e}function Pd(){Pd=C,y4=new yr(`root`)}function uDe(){EJe.call(this),this.Bb|=pI}function dDe(e,t){this.d=e,wfe(this),this.b=t}function fDe(e,t){Qy.call(this,e),this.a=t}function pDe(e,t){Qy.call(this,e),this.a=t}function mDe(e,t,n){Ry.call(this,e,t,n,null)}function hDe(e,t,n){Ry.call(this,e,t,n,null)}function Fd(e,t){this.c=e,io.call(this,e,t)}function Id(e,t){this.a=e,Fd.call(this,e,t)}function gDe(e){this.q=new r.Date(Dv(e))}function _De(e){return e>8?0:e+1}function vDe(e,t){_K||M(e.a,t)}function yDe(e,t){return Io(),jC(t.d.i,e)}function bDe(e,t){return cC(),new Ilt(t,e)}function xDe(e,t,n){return e.Ne(t,n)<=0?n:t}function SDe(e,t,n){return e.Ne(t,n)<=0?t:n}function CDe(e,t){return P(ix(e.b,t),143)}function wDe(e,t){return P(ix(e.c,t),233)}function Ld(e){return P(Ep(e.a,e.b),294)}function TDe(e){return new k(e.c,e.d+e.a)}function EDe(e){return Gh(e),e?1231:1237}function DDe(e){return z_(),RCe(P(e,203))}function Rd(){Rd=C,lq=sE((TD(),x5))}function ODe(e,t){t.a?Irt(e,t):Du(e.a,t.b)}function zd(e,t,n){++e.j,e.tj(),Xy(e,t,n)}function kDe(e,t,n){++e.j,e.qj(t,e.Zi(t,n))}function ADe(e,t,n){e.fd(t).Rb(n)}function jDe(e,t,n){return n=qM(e,t,6,n),n}function Bd(e,t,n){return n=qM(e,t,3,n),n}function Vd(e,t,n){return n=qM(e,t,9,n),n}function Hd(e,t){return c_(t,Iyt),e.f=t,e}function MDe(e,t){return(t&AP)%e.d.length}function NDe(e,t,n){return Xft(e.c,e.b,t,n)}function PDe(e,t){this.c=e,kx.call(this,t)}function FDe(e,t){this.a=e,Hhe.call(this,t)}function Ud(e,t){this.a=e,Hhe.call(this,t)}function Wd(e,t){yr.call(this,e),this.a=t}function IDe(e,t){Khe.call(this,e),this.a=t}function Gd(e,t){Khe.call(this,e),this.a=t}function LDe(e){iD.call(this,0,0),this.f=e}function RDe(e,t,n){return e.a+=ND(t,0,n),e}function Kd(e){return!e.a&&(e.a=new ee),e.a}function zDe(e,t){var n=e.e;return e.e=t,n}function BDe(e,t){var n=t;return!!e.Fe(n)}function VDe(e,t){return rd(),e==t?0:e?1:-1}function qd(e,t){e.a.bd(e.b,t),++e.b,e.c=-1}function Jd(e){e.b?Jd(e.b):e.f.c.zc(e.e,e.d)}function HDe(e){Pm(e.e),e.d.b=e.d,e.d.a=e.d}function UDe(e,t,n){wo(),jde(e,t.Ve(e.a,n))}function WDe(e,t,n){return zm(e,P(t,22),n)}function Yd(e,t){return ua(Array(t),e)}function GDe(e){return nm(um(e,32))^nm(e)}function Xd(e){return String.fromCharCode(e)}function KDe(e){return e==null?null:e.message}function qDe(e,t,n){return e.apply(t,n)}function JDe(e,t){e[TI].call(e,t)}function YDe(e,t){e[TI].call(e,t)}function XDe(e,t){return Io(),!jC(t.d.i,e)}function ZDe(e,t,n,r){Np.call(this,e,t,n,r)}function QDe(){Qd.call(this),this.a=new Fa}function $De(){this.n=new Fa,this.o=new Fa}function eOe(){this.b=new Fa,this.c=new T}function tOe(){this.a=new T,this.b=new T}function nOe(){this.a=new Vt,this.b=new Tge}function Zd(){this.b=new ry,this.a=new ry}function rOe(){this.b=new Jr,this.a=new Jr}function iOe(){this.b=new Dr,this.a=new Dr}function aOe(){this.b=new _ye,this.a=new iae}function oOe(){this.a=new Tue,this.b=new Ure}function sOe(){this.a=new T,this.d=new T}function Qd(){this.n=new ni,this.i=new Ul}function cOe(e){this.a=(vS(e,hF),new Hy(e))}function lOe(e){this.a=(vS(e,hF),new Hy(e))}function uOe(e){return e<100?null:new Pa(e)}function dOe(e,t){return e.n.a=(Gh(t),t+10)}function fOe(e,t){return e.n.a=(Gh(t),t+10)}function pOe(e,t){return t==e||Uk(zj(t),e)}function mOe(e,t){return Qh(e.a,t,``)==null}function hOe(e,t){return t.qi(e.a)}function $d(e,t){return e.a+=t.a,e.b+=t.b,e}function ef(e,t){return e.a-=t.a,e.b-=t.b,e}function gOe(e){return Wr(e.j.c,0),e.a=-1,e}function tf(e,t,n){return n=qM(e,t,11,n),n}function _Oe(e,t,n){n!=null&&TS(t,dk(e,n))}function vOe(e,t,n){n!=null&&ES(t,dk(e,n))}function nf(e,t,n,r){F.call(this,e,t,n,r)}function rf(e,t,n,r){F.call(this,e,t,n,r)}function yOe(e,t,n,r){rf.call(this,e,t,n,r)}function bOe(e,t,n,r){wm.call(this,e,t,n,r)}function af(e,t,n,r){wm.call(this,e,t,n,r)}function of(e,t,n,r){wm.call(this,e,t,n,r)}function xOe(e,t,n,r){af.call(this,e,t,n,r)}function sf(e,t,n,r){af.call(this,e,t,n,r)}function cf(e,t,n,r){of.call(this,e,t,n,r)}function SOe(e,t,n,r){sf.call(this,e,t,n,r)}function COe(e,t,n,r){dPe.call(this,e,t,n,r)}function lf(e,t){Mi.call(this,PU+e+bU+t)}function uf(e,t){return e.jk().wi().ri(e,t)}function df(e,t){return e.jk().wi().ti(e,t)}function wOe(e,t){return Gh(e),A(e)===A(t)}function ff(e,t){return Gh(e),A(e)===A(t)}function TOe(e,t){return e.b.Bd(new sxe(e,t))}function EOe(e,t){return e.b.Bd(new cxe(e,t))}function DOe(e,t){return e.b.Bd(new lxe(e,t))}function OOe(e,t){return e.e=P(e.d.Kb(t),159)}function pf(e,t,n){return e.lastIndexOf(t,n)}function kOe(e,t,n){return aE(e[t.a],e[n.a])}function AOe(e,t){return W(t,(mP(),d1),e)}function jOe(e,t){return _u(t.a.d.p,e.a.d.p)}function MOe(e,t){return _u(e.a.d.p,t.a.d.p)}function NOe(e,t){return aE(e.c-e.s,t.c-t.s)}function POe(e,t){return aE(e.b.e.a,t.b.e.a)}function FOe(e,t){return aE(e.c.e.a,t.c.e.a)}function IOe(e){return e.c?Ab(e.c.a,e,0):-1}function mf(e){return e==L8||e==z8||e==R8}function LOe(e,t){this.c=e,Hm.call(this,e,t)}function ROe(e,t,n){this.a=e,sEe.call(this,t,n)}function zOe(e){this.c=e,vl.call(this,tF,0)}function BOe(e,t,n){this.c=t,this.b=n,this.a=e}function hf(e){Rf(),this.d=e,this.a=new Iu}function VOe(e){wf(),this.a=(Vg(),new oa(e))}function HOe(e,t){ql(e.f)?Ait(e,t):f7e(e,t)}function UOe(e,t){kje.call(this,e,e.length,t)}function WOe(e,t){_K||t&&(e.d=t)}function GOe(e,t){return j(t,15)&&Mct(e.c,t)}function KOe(e,t,n){return P(e.c,71).Wk(t,n)}function gf(e,t,n){return P(e.c,71).Xk(t,n)}function qOe(e,t,n){return eDe(e,P(t,343),n)}function JOe(e,t,n){return tDe(e,P(t,343),n)}function YOe(e,t,n){return E5e(e,P(t,343),n)}function XOe(e,t,n){return A7e(e,P(t,343),n)}function _f(e,t){return t==null?null:TT(e.b,t)}function ZOe(e){return al(e)?(Gh(e),e):e.ue()}function vf(e){return!isNaN(e)&&!isFinite(e)}function yf(e){Awe(this),Fg(this),XS(this,e)}function bf(e){au(this),Fje(this.c,0,e.Pc())}function xf(e,t,n){this.a=e,this.b=t,this.c=n}function QOe(e,t,n){this.a=e,this.b=t,this.c=n}function $Oe(e,t,n){this.d=e,this.b=n,this.a=t}function eke(e){this.a=e,yo(),LC(Date.now())}function tke(e){Fh(e.a),KWe(e.c,e.b),e.b=null}function Sf(){Sf=C,aK=new he,oEt=new ge}function nke(){nke=C,TVt=V(WW,FP,1,0,5,1)}function rke(){rke=C,QVt=V(WW,FP,1,0,5,1)}function Cf(){Cf=C,$Vt=V(WW,FP,1,0,5,1)}function wf(){wf=C,new mge((Vg(),Vg(),QG))}function ike(e){return Sb(),iS((TGe(),dEt),e)}function ake(e){return Zw(),iS((MWe(),vEt),e)}function oke(e){return fO(),iS((wHe(),DEt),e)}function ske(e){return dx(),iS((THe(),OEt),e)}function cke(e){return vM(),iS((CXe(),kEt),e)}function lke(e){return Ix(),iS((AWe(),MEt),e)}function uke(e){return Cb(),iS((kWe(),PEt),e)}function dke(e){return Xb(),iS((jWe(),LEt),e)}function fke(e){return SP(),iS((uCe(),oDt),e)}function pke(e){return KC(),iS((DGe(),cDt),e)}function mke(e){return TO(),iS((kGe(),uDt),e)}function hke(e){return wO(),iS((OGe(),mDt),e)}function gke(e){return No(),iS((VBe(),hDt),e)}function _ke(e){return fx(),iS((EHe(),NDt),e)}function vke(e){return Yb(),iS((NWe(),aOt),e)}function yke(e){return vA(),iS((PKe(),lOt),e)}function bke(e){return ow(),iS((jGe(),hOt),e)}function xke(e){return YD(),iS((AGe(),xOt),e)}function Tf(e,t){if(!e)throw E(new Fi(t))}function Ef(e){if(!e)throw E(new Ii(Wvt))}function Df(e,t){if(e!=t)throw E(new Vr)}function Ske(e,t,n){this.a=e,this.b=t,this.c=n}function Of(e,t,n){this.a=e,this.b=t,this.c=n}function Cke(e,t,n){this.a=e,this.b=t,this.c=n}function kf(e,t,n){this.b=e,this.a=t,this.c=n}function Af(e,t,n){this.b=e,this.c=t,this.a=n}function jf(e,t,n){this.a=e,this.b=t,this.c=n}function Mf(e,t,n){this.e=t,this.b=e,this.d=n}function wke(e,t,n){this.b=e,this.a=t,this.c=n}function Tke(e,t,n){return wo(),e.a.Yd(t,n),t}function Nf(e){var t=new Ze;return t.e=e,t}function Pf(e){var t=new Hge;return t.b=e,t}function Ff(){Ff=C,oY=new vte,sY=new yte}function If(){If=C,ROt=new Kte,LOt=new qte}function Lf(){Lf=C,UOt=new tre,WOt=new nre}function Eke(e){return kS(),iS((uWe(),ekt),e)}function Dke(e){return yP(),iS((dCe(),NOt),e)}function Oke(e){return iw(),iS((NGe(),IOt),e)}function kke(e){return aw(),iS((MGe(),qOt),e)}function Ake(e){return tA(),iS((FKe(),YOt),e)}function jke(e){return dM(),iS((KYe(),tkt),e)}function Mke(e){return GA(),iS((Eqe(),nkt),e)}function Nke(e){return Ky(),iS((NHe(),rkt),e)}function Pke(e){return bS(),iS((cWe(),ikt),e)}function Fke(e){return lS(),iS((lWe(),akt),e)}function Ike(e){return FD(),iS((IKe(),okt),e)}function Lke(e){return px(),iS((kHe(),skt),e)}function Rke(e){return TA(),iS((kqe(),pkt),e)}function zke(e){return uM(),iS((gZe(),mkt),e)}function Bke(e){return qC(),iS((fWe(),hkt),e)}function Vke(e){return Zb(),iS((pWe(),_kt),e)}function Hke(e){return Bv(),iS((OHe(),vkt),e)}function Uke(e){return qk(),iS((Oqe(),fkt),e)}function Wke(e){return _w(),iS((dWe(),lkt),e)}function Gke(e){return kA(),iS((Dqe(),ukt),e)}function Kke(e){return wb(),iS((AHe(),dkt),e)}function qke(e){return XE(),iS((RKe(),ykt),e)}function Jke(e){return Zj(),iS((bXe(),MMt),e)}function Yke(e){return hT(),iS((mWe(),FMt),e)}function Xke(e){return IO(),iS((PGe(),IMt),e)}function Zke(e){return CO(),iS((LKe(),zMt),e)}function Qke(e){return FM(),iS((_Ze(),GMt),e)}function $ke(e){return ID(),iS((FGe(),JMt),e)}function eAe(e){return Qb(),iS((jHe(),XMt),e)}function tAe(e){return uS(),iS((_We(),QMt),e)}function nAe(e){return CC(),iS((hWe(),nNt),e)}function rAe(e){return Nw(),iS((gWe(),iNt),e)}function iAe(e){return Xw(),iS((vWe(),sNt),e)}function aAe(e){return cS(),iS((yWe(),dNt),e)}function oAe(e){return sw(),iS((bWe(),pNt),e)}function sAe(e){return sS(),iS((OWe(),jNt),e)}function cAe(e){return Vv(),iS((MHe(),RNt),e)}function lAe(e){return O_(),iS((IHe(),qNt),e)}function uAe(e){return k_(),iS((LHe(),YNt),e)}function dAe(e){return Wy(),iS((RHe(),dPt),e)}function fAe(e){return D_(),iS((zHe(),vPt),e)}function pAe(e){return Ok(),iS((YGe(),bPt),e)}function mAe(e){return LM(),iS((fCe(),NPt),e)}function hAe(e){return Pw(),iS((xWe(),IPt),e)}function gAe(e){return Jw(),iS((JGe(),TFt),e)}function _Ae(e){return iv(),iS((PHe(),OFt),e)}function vAe(e){return AS(),iS((FHe(),PFt),e)}function yAe(e){return iA(),iS((zKe(),IFt),e)}function bAe(e){return Yw(),iS((SWe(),UFt),e)}function xAe(e){return _b(),iS((BHe(),zFt),e)}function SAe(e){return uk(),iS((qGe(),wIt),e)}function CAe(e){return SC(),iS((CWe(),OIt),e)}function wAe(e){return ED(),iS((wWe(),AIt),e)}function TAe(e){return LO(),iS((TWe(),MIt),e)}function EAe(e){return TE(),iS((EWe(),RIt),e)}function DAe(e){return my(),iS((VHe(),xLt),e)}function OAe(e){return dC(),iS((DHe(),AOt),e)}function kAe(e){return DA(),iS((Aqe(),TOt),e)}function AAe(e){return Tb(),iS((DWe(),TLt),e)}function jAe(e){return JC(),iS((HHe(),kLt),e)}function MAe(e){return Wj(),iS((BKe(),MLt),e)}function NAe(e){return Bo(),iS((sVe(),FLt),e)}function PAe(e){return KT(),iS((FWe(),NLt),e)}function FAe(e){return Vo(),iS((cVe(),LLt),e)}function IAe(e){return Gy(),iS((UHe(),zLt),e)}function LAe(e){return MA(),iS((VKe(),WLt),e)}function RAe(e){return Ho(),iS((lVe(),SRt),e)}function zAe(e){return cw(),iS((WHe(),TRt),e)}function BAe(e){return uO(),iS((UKe(),FRt),e)}function VAe(e){return VA(),iS((WYe(),RRt),e)}function HAe(e){return RO(),iS((jqe(),HRt),e)}function UAe(e){return eA(),iS((Mqe(),ezt),e)}function WAe(e){return GT(),iS((HKe(),nBt),e)}function GAe(e){return Lx(),iS((IWe(),iBt),e)}function KAe(e){return wE(),iS((XGe(),aBt),e)}function qAe(e){return hA(),iS((Nqe(),fBt),e)}function JAe(e){return _T(),iS((PWe(),bBt),e)}function YAe(e){return kk(),iS((ZGe(),SBt),e)}function XAe(e){return Ej(),iS((SXe(),CBt),e)}function ZAe(e){return pO(),iS((WKe(),EBt),e)}function QAe(e){return rA(),iS((Pqe(),OBt),e)}function $Ae(e){return rj(),iS((Fqe(),kBt),e)}function eje(e){return nP(),iS((GKe(),ABt),e)}function tje(e){return TD(),iS((QGe(),IBt),e)}function nje(e){return UM(),iS((xXe(),RBt),e)}function rje(e){return gT(),iS((LWe(),VBt),e)}function ije(e,t){return Gh(e),e+(Gh(t),t)}function aje(e){return zf(),iS((GHe(),WBt),e)}function oje(e){return ZE(),iS(($Ge(),YBt),e)}function sje(e){return Mw(),iS((eKe(),tVt),e)}function Rf(){Rf=C,PNt=(nP(),g5),v2=X8}function zf(){zf=C,HBt=new AMe,UBt=new cPe}function cje(e){return!e.e&&(e.e=new T),e.e}function Bf(e,t){this.c=e,this.a=t,this.b=t-e}function lje(e,t,n){this.a=e,this.b=t,this.c=n}function Vf(e,t,n){this.a=e,this.b=t,this.c=n}function Hf(e,t,n){this.a=e,this.b=t,this.c=n}function Uf(e,t,n){this.a=e,this.b=t,this.c=n}function uje(e,t,n){this.a=e,this.b=t,this.c=n}function dje(e,t,n){this.a=e,this.b=t,this.c=n}function Wf(e,t,n){this.e=e,this.a=t,this.c=n}function fje(e,t,n){du(),ILe.call(this,e,t,n)}function Gf(e,t,n){du(),Ph.call(this,e,t,n)}function pje(e,t,n){du(),Ph.call(this,e,t,n)}function mje(e,t,n){du(),Ph.call(this,e,t,n)}function hje(e,t,n){du(),Gf.call(this,e,t,n)}function gje(e,t,n){du(),Gf.call(this,e,t,n)}function _je(e,t,n){du(),gje.call(this,e,t,n)}function vje(e,t,n){du(),pje.call(this,e,t,n)}function yje(e,t,n){du(),mje.call(this,e,t,n)}function Kf(e){Np.call(this,e.d,e.c,e.a,e.b)}function bje(e){Np.call(this,e.d,e.c,e.a,e.b)}function xje(e){this.d=e,wfe(this),this.b=FNe(e.d)}function Sje(e){return Sj(),iS((GYe(),bVt),e)}function qf(e,t){return ph(e),ph(t),new Hye(e,t)}function Jf(e,t){return ph(e),ph(t),new oMe(e,t)}function Cje(e,t){return ph(e),ph(t),new sMe(e,t)}function wje(e,t){return ph(e),ph(t),new Qye(e,t)}function Yf(e){return jd(e.b!=0),Ox(e,e.a.a)}function Tje(e){return jd(e.b!=0),Ox(e,e.c.b)}function Eje(e){return!e.c&&(e.c=new ln),e.c}function Xf(e){var t=new T;return rx(t,e),t}function Dje(e){var t=new Jr;return rx(t,e),t}function Oje(e){var t=new Nge;return HS(t,e),t}function Zf(e){var t=new vo;return HS(t,e),t}function P(e,t){return bp(e==null||kO(e,t)),e}function kje(e,t,n){WNe.call(this,t,n),this.a=e}function Aje(e,t){this.c=e,this.b=t,this.a=!1}function jje(){this.a=`;,;`,this.b=``,this.c=``}function Mje(e,t,n){this.b=e,aCe.call(this,t,n)}function Nje(e,t,n){this.c=e,ds.call(this,t,n)}function Pje(e,t,n){js.call(this,e,t),this.b=n}function Fje(e,t,n){art(n,0,e,t,n.length,!1)}function Qf(e,t,n,r,i){e.b=t,e.c=n,e.d=r,e.a=i}function Ije(e,t,n,r,i){e.d=t,e.c=n,e.a=r,e.b=i}function Lje(e,t){t&&(e.b=t,e.a=(Hh(t),t.a))}function $f(e,t){if(!e)throw E(new Fi(t))}function ep(e,t){if(!e)throw E(new Ii(t))}function Rje(e,t){if(!e)throw E(new ove(t))}function zje(e,t){return Ro(),_u(e.d.p,t.d.p)}function Bje(e,t){return zx(),aE(e.e.b,t.e.b)}function Vje(e,t){return zx(),aE(e.e.a,t.e.a)}function Hje(e,t){return _u(bMe(e.d),bMe(t.d))}function tp(e,t){return t&&Lh(e,t.d)?t:null}function Uje(e,t){return t==(nP(),g5)?e.c:e.d}function Wje(e){return MC(gPe(Il(e)?zC(e):e))}function Gje(e){return new k(e.c+e.b,e.d+e.a)}function Kje(e){return e!=null&&!zE(e,y7,b7)}function qje(e,t){return(R$e(e)<<4|R$e(t))&OF}function Jje(e,t,n,r,i){e.c=t,e.d=n,e.b=r,e.a=i}function Yje(e){var t=e.b;e.b=e.c,e.c=t}function Xje(e){var t,n=e.d;t=e.a,e.d=t,e.a=n}function Zje(e,t){var n=e.c;return PJe(e,t),n}function Qje(e,t){return e.g=t<0?-1:t,e}function np(e,t){return bqe(e),e.a*=t,e.b*=t,e}function $je(e,t,n){pqe.call(this,t,n),this.d=e}function rp(e,t,n){el.call(this,e,t),this.c=n}function ip(e,t,n){el.call(this,e,t),this.c=n}function eMe(e){Cf(),sn.call(this),this.ci(e)}function tMe(){By(),uFe.call(this,(qo(),N7))}function nMe(e){return xP(),++W9,new zp(0,e)}function rMe(){rMe=C,f9=(Vg(),new Gn(xW))}function ap(){ap=C,new FO((mi(),ZW),(pi(),XW))}function iMe(){iMe=C,OG=V(DG,X,17,256,0,1)}function aMe(){this.b=D(N(hO((XM(),eJ))))}function op(e){this.b=e,this.a=am(this.b.a).Od()}function oMe(e,t){this.b=e,this.a=t,dn.call(this)}function sMe(e,t){this.a=e,this.b=t,dn.call(this)}function cMe(e,t,n){this.a=e,El.call(this,t,n)}function lMe(e,t,n){this.a=e,El.call(this,t,n)}function sp(e,t,n){hx(e,t,new mh(n))}function uMe(e,t,n){var r=e[t];return e[t]=n,r}function cp(e){return yb(e.slice(),e)}function lp(e){var t=e.n;return e.a.b+t.d+t.a}function dMe(e){var t=e.n;return e.e.b+t.d+t.a}function fMe(e){var t=e.n;return e.e.a+t.b+t.c}function pMe(e){e.a.b=e.b,e.b.a=e.a,e.a=e.b=null}function up(e,t){return iy(e,t,e.c.b,e.c),!0}function mMe(e){return e.a?e.a:xg(e)}function hMe(e){return Ug(),xA(e)==I_(SA(e))}function gMe(e){return Ug(),SA(e)==I_(xA(e))}function dp(e,t){return Bk(e,new js(t.a,t.b))}function _Me(e,t){return eg(),ik(e,t),new jFe(e,t)}function vMe(e,t){return e.c=t)throw E(new e_e)}function _m(e,t){return MT(e,(Gh(t),new jfe(t)))}function vm(e,t){return MT(e,(Gh(t),new Mfe(t)))}function XNe(e,t,n){return kvt(e,P(t,12),P(n,12))}function ZNe(e){return fC(),P(e,12).g.c.length!=0}function QNe(e){return fC(),P(e,12).e.c.length!=0}function $Ne(e,t){return cC(),aE(t.a.o.a,e.a.o.a)}function ePe(e,t){(t.Bb&GH)!=0&&!e.a.o&&(e.a.o=t)}function tPe(e,t){t.Ug(`General 'Rotator`,1),vgt(e)}function nPe(e,t,n){t.qf(n,D(N(xh(e.b,n)))*e.a)}function rPe(e,t,n){return fM(),_C(e,t)&&_C(e,n)}function ym(e){return rj(),!e.Hc(G8)&&!e.Hc(q8)}function iPe(e){return e.e?$Ue(e.e):null}function bm(e){return Il(e)?``+e:Ect(e)}function aPe(e){for(var t=e;t.f;)t=t.f;return t}function oPe(e,t,n){return Sh(t,0,Op(t[0],n[0])),t}function xm(e,t,n,r){var i=e.i;i.i=t,i.a=n,i.b=r}function F(e,t,n,r){ju.call(this,e,t,n),this.b=r}function Sm(e,t,n,r,i){ub.call(this,e,t,n,r,i,-1)}function Cm(e,t,n,r,i){db.call(this,e,t,n,r,i,-1)}function wm(e,t,n,r){rp.call(this,e,t,n),this.b=r}function sPe(e){zSe.call(this,e,!1),this.a=!1}function cPe(){vSe.call(this,`LOOKAHEAD_LAYOUT`,1)}function lPe(e){this.b=e,cd.call(this,e),CTe(this)}function uPe(e){this.b=e,ud.call(this,e),wTe(this)}function Tm(e,t,n){this.a=e,nf.call(this,t,n,5,6)}function dPe(e,t,n,r){this.b=e,ju.call(this,t,n,r)}function fPe(e,t){this.b=e,_de.call(this,e.b),this.a=t}function pPe(e){this.a=m4e(e.a),this.b=new bf(e.b)}function mPe(e,t){gh(),rbe.call(this,e,bT(new Wi(t)))}function Em(e,t){return xP(),++W9,new Nh(e,t,0)}function Dm(e,t){return xP(),++W9,new Nh(6,e,t)}function Om(e,t){for(Gh(t);e.Ob();)t.Cd(e.Pb())}function km(e,t){return rl(t)?e_(e,t):!!Kp(e.f,t)}function Am(e,t){return t.Vh()?pT(e.b,P(t,54)):t}function hPe(e,t){return ff(e.substr(0,t.length),t)}function jm(e){return new pm(new ATe(e.a.length,e.a))}function Mm(e){return new k(e.c+e.b/2,e.d+e.a/2)}function gPe(e){return vu(~e.l&QF,~e.m&QF,~e.h&$F)}function Nm(e){return typeof e===EP||typeof e===kP}function Pm(e){e.f=new PCe(e),e.i=new FCe(e),++e.g}function _Pe(e){if(!e)throw E(new Hr);return e.d}function Fm(e){var t=yw(e);return jd(t!=null),t}function vPe(e){var t=u1e(e);return jd(t!=null),t}function Im(e,t){var n=e.a.gc();return RUe(t,n),n-t}function Lm(e,t){return e.a.zc(t,e)==null}function Rm(e,t){return e.a.zc(t,(rd(),vG))==null}function yPe(e){return new Mp(null,OPe(e,e.length))}function bPe(e,t,n){return ypt(e,P(t,42),P(n,176))}function zm(e,t,n){return PS(e.a,t),uMe(e.b,t.g,n)}function xPe(e,t,n){gm(n,e.a.c.length),uy(e.a,n,t)}function I(e,t,n,r){TQe(t,n,e.length),SPe(e,t,n,r)}function SPe(e,t,n,r){var i;for(i=t;i0?r.Math.log(e/t):-100}function DPe(e,t){return dT(e,t)<0?-1:+(dT(e,t)>0)}function qm(e,t){Kwe(e,j(t,160)?t:P(t,2036).Rl())}function Jm(e,t){if(e==null)throw E(new Li(t))}function OPe(e,t){return gqe(t,e.length),new kMe(e,t)}function Ym(e,t){return t?XS(e,t):!1}function kPe(){return xi(),U(O(MTt,1),Z,549,0,[tG])}function Xm(e){return e.e==0?e:new Bm(-e.e,e.d,e.a)}function APe(e,t){return aE(e.c.c+e.c.b,t.c.c+t.c.b)}function Zm(e,t){iy(e.d,t,e.b.b,e.b),++e.a,e.c=null}function jPe(e,t){return e.c?jPe(e.c,t):M(e.b,t),e}function MPe(e,t,n){var r=ax(e,t);return Yv(e,t,n),r}function NPe(e,t,n){var r;for(r=0;r=e.g}function Sh(e,t,n){return cDe(n==null||mdt(e,n)),e[t]=n}function Ch(e,t){return sv(t,e.length+1),e.substr(t)}function wh(e,t){for(Gh(t);e.c=e?new _be:RJe(e-1)}function Bh(e){return!e.a&&e.c?e.c.b:e.a}function Vh(e){return j(e,616)?e:new KLe(e)}function Hh(e){e.c?Hh(e.c):(lE(e),e.d=!0)}function Uh(e){e.c?e.c.$e():(e.d=!0,bot(e))}function _Fe(e){e.b=!1,e.c=!1,e.d=!1,e.a=!1}function vFe(e){return e.c.i.c==e.d.i.c}function yFe(e,t){var n=e.Ih(t);n>=0?e.ki(n):Qtt(e,t)}function bFe(e,t){e.c<0||e.b.b0;)e=e<<1|e<0;return e}function BFe(e,t){var n=new Eh(e);return Mr(t.c,n),n}function VFe(e,t){e.u.Hc((rj(),G8))&&bnt(e,t),RWe(e,t)}function rg(e,t){return A(e)===A(t)||e!=null&&NT(e,t)}function ig(e,t){return Gp(e.a,t)?e.b[P(t,22).g]:null}function HFe(){return No(),U(O(Oq,1),Z,489,0,[Dq])}function UFe(){return Bo(),U(O(PLt,1),Z,490,0,[v3])}function WFe(){return Vo(),U(O(ILt,1),Z,558,0,[y3])}function GFe(){return Ho(),U(O(xRt,1),Z,539,0,[O3])}function ag(e){return!e.n&&(e.n=new F(Q5,e,1,7)),e.n}function og(e){return!e.c&&(e.c=new F(e7,e,9,9)),e.c}function sg(e){return!e.c&&(e.c=new cf(H5,e,5,8)),e.c}function KFe(e){return!e.b&&(e.b=new cf(H5,e,4,7)),e.b}function cg(e){return e.j.c.length=0,yg(e.c),gOe(e.a),e}function lg(e){return e.e==SW&&gfe(e,p2e(e.g,e.b)),e.e}function ug(e){return e.f==SW&&vfe(e,O6e(e.g,e.b)),e.f}function dg(e,t,n,r){return lXe(e,t,n,!1),LT(e,r),e}function qFe(e,t){this.b=e,Hm.call(this,e,t),CTe(this)}function JFe(e,t){this.b=e,LOe.call(this,e,t),wTe(this)}function fg(e){this.d=e,this.a=this.d.b,this.b=this.d.c}function pg(e,t){this.b=e,this.c=t,this.a=new _o(this.b)}function mg(e,t){return sv(t,e.length),e.charCodeAt(t)}function YFe(e,t){fE(e,D(nS(t,`x`)),D(nS(t,`y`)))}function XFe(e,t){fE(e,D(nS(t,`x`)),D(nS(t,`y`)))}function hg(e,t){return lE(e),new Mp(e,new UGe(t,e.a))}function gg(e,t){return lE(e),new Mp(e,new WUe(t,e.a))}function _g(e,t){return lE(e),new fDe(e,new HUe(t,e.a))}function vg(e,t){return lE(e),new pDe(e,new UUe(t,e.a))}function ZFe(e,t){return new VIe(P(ph(e),50),P(ph(t),50))}function QFe(e,t){return aE(e.d.c+e.d.b/2,t.d.c+t.d.b/2)}function $Fe(e,t,n){n.a?Kx(e,t.b-e.f/2):Gx(e,t.a-e.g/2)}function eIe(e,t){return aE(e.g.c+e.g.b/2,t.g.c+t.g.b/2)}function tIe(e,t){return Pbe(),aE((Gh(e),e),(Gh(t),t))}function nIe(e){return e!=null&&po(x7,e.toLowerCase())}function yg(e){var t;for(t=e.Kc();t.Ob();)t.Pb(),t.Qb()}function bg(e){var t=e.b;return!t&&(e.b=t=new lde(e)),t}function xg(e){return HJe(e)||null}function rIe(e,t){var n=e/t,r=C_(n);return n>r&&++r,r}function iIe(e,t,n){var r=P(e.d.Kb(n),159);r&&r.Nb(t)}function aIe(e,t,n){gpt(e.a,n),PXe(n),sit(e.b,n),Wpt(t,n)}function Sg(e,t,n,r){this.a=e,this.c=t,this.b=n,this.d=r}function Cg(e,t,n,r){this.c=e,this.b=t,this.a=n,this.d=r}function oIe(e,t,n,r){this.c=e,this.b=t,this.d=n,this.a=r}function wg(e,t,n,r){this.c=e,this.d=t,this.b=n,this.a=r}function sIe(e,t,n,r){this.a=e,this.d=t,this.c=n,this.b=r}function Tg(e,t,n,r){this.a=e,this.e=t,this.d=n,this.c=r}function cIe(e,t,n,r){this.a=e,this.c=t,this.d=n,this.b=r}function Eg(e,t,n){this.a=ryt,this.d=e,this.b=t,this.c=n}function Dg(e,t,n,r){so.call(this,e,t),this.a=n,this.b=r}function lIe(e,t){this.d=(Gh(e),e),this.a=16449,this.c=t}function uIe(e){this.a=new T,this.e=V(q9,X,53,e,0,2)}function dIe(e){e.Ug(`No crossing minimization`,1),e.Vg()}function fIe(){yi.call(this,`There is no more element.`)}function pIe(e,t,n,r){this.a=e,this.b=t,this.c=n,this.d=r}function mIe(e,t,n,r){this.a=e,this.b=t,this.c=n,this.d=r}function Og(e,t,n,r){this.e=e,this.a=t,this.c=n,this.d=r}function hIe(e,t,n,r){this.a=e,this.c=t,this.d=n,this.b=r}function gIe(e,t,n,r){du(),GUe.call(this,t,n,r),this.a=e}function _Ie(e,t,n,r){du(),GUe.call(this,t,n,r),this.a=e}function kg(e,t,n){var r=n_t(e);return t.ti(n,r)}function Ag(e){var t,n=(t=new kr,t);return Nx(n,e),n}function jg(e){var t,n=(t=new kr,t);return i9e(n,e),n}function vIe(e,t){return yC(t,xh(e.f,t)),null}function yIe(e){return!e.b&&(e.b=new F(U5,e,12,3)),e.b}function bIe(e){return bp(e==null||Nm(e)&&e.Tm!==ne),e}function Mg(e){return e.n&&(e.e!==eyt&&e.je(),e.j=null),e}function Ng(e){if(RE(e.d),e.d.d!=e.c)throw E(new Vr)}function Pg(e){return jd(e.b0&&d8e(this)}function xIe(e,t){this.a=e,dDe.call(this,e,P(e.d,15).fd(t))}function SIe(e,t){return aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function CIe(e,t){return aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function wIe(e){return uj(e)&&ki(Od(J(e,(mP(),A1))))}function TIe(e,t){return fj(e,P(K(t,(mP(),Y1)),17),t)}function EIe(e,t){return P(K(e,(Y(),PQ)),15).Fc(t),t}function Lg(e,t){return e.b=t.b,e.c=t.c,e.d=t.d,e.a=t.a,e}function DIe(e,t,n,r){this.b=e,this.c=r,vl.call(this,t,n)}function OIe(e,t,n){e.i=0,e.e=0,t!=n&&RZe(e,t,n)}function kIe(e,t,n){e.i=0,e.e=0,t!=n&&zZe(e,t,n)}function AIe(e,t,n){return Lo(),N1e(P(xh(e.e,t),529),n)}function Rg(e){var t;return t=e.f,t||(e.f=new io(e,e.c))}function jIe(e,t){return CT(e.j,t.s,t.c)+CT(t.e,e.s,e.c)}function MIe(e,t){e.e&&!e.e.a&&(Qhe(e.e,t),MIe(e.e,t))}function NIe(e,t){e.d&&!e.d.a&&(Qhe(e.d,t),NIe(e.d,t))}function PIe(e,t){return-aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function FIe(e){return P(e.ld(),149).Pg()+`:`+PE(e.md())}function IIe(){EA(this,new $ue),this.wb=(vh(),z7),Ra()}function LIe(e){this.b=new T,nw(this.b,this.b),this.a=e}function zg(e,t){new vo,this.a=new ai,this.b=e,this.c=t}function Bg(){Bg=C,nK=new ue,rK=new ue,iK=new de}function Vg(){Vg=C,QG=new ae,$G=new se,eK=new ce}function Hg(){Hg=C,wEt=new Ge,EEt=new yNe,TEt=new Ke}function Ug(){Ug=C,zq=new T,Rq=new Dr,Lq=new T}function Wg(e,t){if(e==null)throw E(new Li(t));return e}function Gg(e){return!e.a&&(e.a=new F($5,e,10,11)),e.a}function Kg(e){return!e.q&&(e.q=new F(M7,e,11,10)),e.q}function R(e){return!e.s&&(e.s=new F(w7,e,21,17)),e.s}function RIe(e){return ph(e),z4e(new pm(Vu(e.a.Kc(),new d)))}function zIe(e,t){return $w(e),$w(t),eve(P(e,22),P(t,22))}function qg(e,t,n){hx(e,t,new Cn(ZOe(n)))}function Jg(e,t,n,r,i,a){db.call(this,e,t,n,r,i,a?-2:-1)}function BIe(e,t,n,r){el.call(this,t,n),this.b=e,this.a=r}function VIe(e,t){F_e.call(this,new mm(e)),this.a=e,this.b=t}function Yg(e){this.b=e,this.c=e,e.e=null,e.c=null,this.a=1}function HIe(e){Lf();var t=P(e.g,10);t.n.a=e.d.c+t.d.b}function Xg(){Xg=C;var e,t=!L0e();e=new b,lG=t?new y:e}function Zg(e){return Vg(),j(e,59)?new sa(e):new qu(e)}function Qg(e){return j(e,16)?new jp(P(e,16)):Dje(e.Kc())}function UIe(e){return new DTe(e,e.e.Rd().gc()*e.c.Rd().gc())}function WIe(e){return new OTe(e,e.e.Rd().gc()*e.c.Rd().gc())}function $g(e){return e&&e.hashCode?e.hashCode():td(e)}function e_(e,t){return t==null?!!Kp(e.f,null):dNe(e.i,t)}function GIe(e,t){var n=Gwe(e.a,t);return n&&(t.d=null),n}function KIe(e,t,n){return e.f?e.f.ef(t,n):!1}function t_(e,t,n,r){Sh(e.c[t.g],n.g,r),Sh(e.c[n.g],t.g,r)}function n_(e,t,n,r){Sh(e.c[t.g],t.g,n),Sh(e.b[t.g],t.g,r)}function qIe(e,t,n){return D(N(n.a))<=e&&D(N(n.b))>=t}function JIe(e,t){this.g=e,this.d=U(O(UJ,1),jR,10,0,[t])}function YIe(e){this.c=e,this.b=new Ja(P(ph(new qe),50))}function XIe(e){this.c=e,this.b=new Ja(P(ph(new dee),50))}function ZIe(e){this.b=e,this.a=new Ja(P(ph(new At),50))}function QIe(){this.b=new Jr,this.d=new vo,this.e=new $r}function r_(){this.c=new Fa,this.d=new Fa,this.e=new Fa}function i_(){this.a=new ai,this.b=(vS(3,hF),new Hy(3))}function a_(e,t){this.e=e,this.a=WW,this.b=glt(t),this.c=t}function o_(e){this.c=e.c,this.d=e.d,this.b=e.b,this.a=e.a}function $Ie(e,t,n,r,i,a){this.a=e,xS.call(this,t,n,r,i,a)}function eLe(e,t,n,r,i,a){this.a=e,xS.call(this,t,n,r,i,a)}function s_(e,t,n,r,i,a,o){return new ey(e.e,t,n,r,i,a,o)}function tLe(e,t,n){return n>=0&&ff(e.substr(n,t.length),t)}function nLe(e,t){return j(t,149)&&ff(e.b,P(t,149).Pg())}function rLe(e,t){return e.a?t.Gh().Kc():P(t.Gh(),71).Ii()}function iLe(e,t){var n=e.b.Qc(t);return bHe(n,e.b.gc()),n}function c_(e,t){if(e==null)throw E(new Li(t));return e}function l_(e){return e.u||=(_y(e),new FDe(e,e)),e.u}function u_(e){this.a=(Vg(),j(e,59)?new sa(e):new qu(e))}function d_(e){return P(NC(e,16),29)||e.ii()}function f_(e,t){var n=Ha(e.Rm);return t==null?n:n+`: `+t}function p_(e,t,n){return Zy(t,n,e.length),e.substr(t,n-t)}function aLe(e,t){Qd.call(this),Px(this),this.a=e,this.c=t}function oLe(e){!e||f_(e,e.ie())}function sLe(e){Qi(),r.setTimeout(function(){throw e},0)}function cLe(){return fO(),U(O(DK,1),Z,436,0,[EK,TK])}function lLe(){return dx(),U(O(AK,1),Z,435,0,[OK,kK])}function uLe(){return fx(),U(O(Uq,1),Z,432,0,[Vq,Hq])}function dLe(){return dC(),U(O(kOt,1),Z,517,0,[aY,iY])}function fLe(){return Bv(),U(O(lQ,1),Z,429,0,[sQ,cQ])}function pLe(){return px(),U(O(hZ,1),Z,428,0,[pZ,mZ])}function mLe(){return Ky(),U(O(QX,1),Z,431,0,[XX,ZX])}function hLe(){return Qb(),U(O(YMt,1),Z,430,0,[e2,t2])}function gLe(){return Vv(),U(O(LNt,1),Z,531,0,[b2,y2])}function _Le(){return AS(),U(O(NFt,1),Z,501,0,[b4,x4])}function vLe(){return O_(),U(O(KNt,1),Z,523,0,[w2,C2])}function yLe(){return k_(),U(O(JNt,1),Z,522,0,[T2,E2])}function bLe(){return Wy(),U(O(uPt,1),Z,528,0,[A2,k2])}function xLe(){return wb(),U(O(OZ,1),Z,488,0,[DZ,EZ])}function SLe(){return my(),U(O(bLt,1),Z,491,0,[s3,yLt])}function CLe(){return JC(),U(O(OLt,1),Z,492,0,[ELt,DLt])}function wLe(){return iv(),U(O(DFt,1),Z,433,0,[v4,EFt])}function TLe(){return _b(),U(O(RFt,1),Z,434,0,[LFt,D4])}function ELe(){return D_(),U(O(_Pt,1),Z,465,0,[j2,M2])}function DLe(){return Gy(),U(O(RLt,1),Z,438,0,[x3,b3])}function OLe(){return cw(),U(O(wRt,1),Z,437,0,[k3,CRt])}function kLe(){return zf(),U(O(P5,1),Z,347,0,[HBt,UBt])}function m_(e,t,n,r){return n>=0?e.Uh(t,n,r):e.Ch(null,n,r)}function h_(e){return e.b.b==0?e.a.sf():Yf(e.b)}function ALe(e){if(e.p!=5)throw E(new Rr);return nm(e.f)}function jLe(e){if(e.p!=5)throw E(new Rr);return nm(e.k)}function MLe(e){return A(e.a)===A((uC(),r9))&&bmt(e),e.a}function NLe(e,t){e.b=t,e.c>0&&e.b>0&&(e.g=Pp(e.c,e.b,e.a))}function PLe(e,t){e.c=t,e.c>0&&e.b>0&&(e.g=Pp(e.c,e.b,e.a))}function FLe(e,t){Qde(this,new k(e.a,e.b)),$de(this,Zf(t))}function g_(){I_e.call(this,new go(xx(12))),vTe(!0),this.a=2}function __(e,t,n){xP(),Tr.call(this,e),this.b=t,this.a=n}function ILe(e,t,n){du(),xr.call(this,t),this.a=e,this.b=n}function LLe(e){var t=e.c.d.b;e.b=t,e.a=e.c.d,t.a=e.c.d.b=e}function RLe(e){return e.b==0?null:(jd(e.b!=0),Ox(e,e.a.a))}function v_(e,t){return t==null?nl(Kp(e.f,null)):as(e.i,t)}function zLe(e,t,n,r,i){return new IA(e,(Sb(),fK),t,n,r,i)}function y_(e,t){return dHe(t),eJe(e,V(q9,HF,28,t,15,1),t)}function b_(e,t){return Wg(e,`set1`),Wg(t,`set2`),new ibe(e,t)}function BLe(e,t){return aG[e.charCodeAt(0)]??e}function VLe(e,t){var n=t,r=new ve;return Aht(e,n,r),r.d}function x_(e,t,n,r){var i=new QDe;t.a[n.g]=i,zm(e.b,r,i)}function HLe(e,t){return $d(Cd(Bqe(e.f,t)),e.f.d)}function S_(e){var t;xJe(e.a),owe(e.a),t=new ar(e.a),KE(t)}function ULe(e,t){Uct(e,!0),Dx(e.e.Rf(),new Af(e,!0,t))}function WLe(e,t){return Ug(),e==I_(xA(t))||e==I_(SA(t))}function GLe(e,t){return zx(),P(K(t,(rN(),p4)),17).a==e}function C_(e){return Math.max(Math.min(e,AP),-2147483648)|0}function KLe(e){this.a=P(ph(e),277),this.b=(Vg(),new UTe(e))}function qLe(e,t,n){this.i=new T,this.b=e,this.g=t,this.a=n}function JLe(e,t,n){this.a=new T,this.e=e,this.f=t,this.c=n}function w_(e,t,n){this.c=new T,this.e=e,this.f=t,this.b=n}function YLe(e){Qd.call(this),Px(this),this.a=e,this.c=!0}function XLe(e){function t(){}return t.prototype=e||{},new t}function ZLe(e){if(e.Ae())return null;var t=e.n;return UW[t]}function T_(e){return e.Db>>16==3?P(e.Cb,27):null}function E_(e){return e.Db>>16==9?P(e.Cb,27):null}function QLe(e){return e.Db>>16==6?P(e.Cb,74):null}function D_(){D_=C,j2=new rSe(cL,0),M2=new rSe(lL,1)}function O_(){O_=C,w2=new Uxe(lL,0),C2=new Uxe(cL,1)}function k_(){k_=C,T2=new Wxe(hL,0),E2=new Wxe(`UP`,1)}function $Le(){$Le=C,NTt=nT((xi(),U(O(MTt,1),Z,549,0,[tG])))}function eRe(e){var t=new qa(xx(e.length));return wZe(t,e),t}function tRe(e,t){return e.b+=t.b,e.c+=t.c,e.d+=t.d,e.a+=t.a,e}function nRe(e,t){return IXe(e,t)?(oJe(e),!0):!1}function A_(e,t){if(t==null)throw E(new zr);return K0e(e,t)}function j_(e,t){var n=e.q.getHours();e.q.setDate(t),dN(e,n)}function rRe(e,t,n){var r=e.Ih(t);r>=0?e.bi(r,n):Pat(e,t,n)}function iRe(e,t){var n=e.Ih(t);return n>=0?e.Wh(n):cj(e,t)}function aRe(e,t){var n;for(ph(t),n=e.a;n;n=n.c)t.Yd(n.g,n.i)}function M_(e,t,n){e.b=new VS(kZe(e,t,n).c.length)}function N_(e,t,n){R_(),e&&Qh(p7,e,t),e&&Qh(f7,e,n)}function oRe(e,t){return If(),rd(),P(t.a,17).a0}function lRe(e){var t=e.d;return t=e.bj(e.f),tb(e,t),t.Ob()}function uRe(e,t){var n=new Ap(t);return L7e(n,e),new bf(n)}function dRe(e){if(e.p!=0)throw E(new Rr);return cl(e.f,0)}function fRe(e){if(e.p!=0)throw E(new Rr);return cl(e.k,0)}function pRe(e){return e.Db>>16==7?P(e.Cb,241):null}function F_(e){return e.Db>>16==6?P(e.Cb,241):null}function mRe(e){return e.Db>>16==7?P(e.Cb,167):null}function I_(e){return e.Db>>16==11?P(e.Cb,27):null}function L_(e){return e.Db>>16==17?P(e.Cb,29):null}function hRe(e){return e.Db>>16==3?P(e.Cb,155):null}function gRe(e){var t;return lE(e),t=new Jr,hg(e,new Wfe(t))}function _Re(e,t){var n=e.a=e.a||[];return n[t]||(n[t]=e.ve(t))}function vRe(e,t){var n=e.q.getHours();e.q.setMonth(t),dN(e,n)}function yRe(e,t){Fu(this),this.f=t,this.g=e,Mg(this),this.je()}function bRe(e,t){this.a=e,this.c=xu(this.a),this.b=new o_(t)}function xRe(e,t,n){this.a=t,this.c=e,this.b=(ph(n),new bf(n))}function SRe(e,t,n){this.a=t,this.c=e,this.b=(ph(n),new bf(n))}function CRe(e){this.a=e,this.b=V(MNt,X,2043,e.e.length,0,2)}function wRe(){this.a=new Rl,this.e=new Jr,this.g=0,this.i=0}function R_(){R_=C,p7=new Dr,f7=new Dr,USe(tEt,new Ise)}function TRe(){TRe=C,mNt=tm(new Zh,(vA(),SJ),(yP(),nX))}function ERe(){ERe=C,hNt=tm(new Zh,(vA(),SJ),(yP(),nX))}function DRe(){DRe=C,_Nt=tm(new Zh,(vA(),SJ),(yP(),nX))}function ORe(){ORe=C,zNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function z_(){z_=C,HNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function kRe(){kRe=C,GNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function B_(){B_=C,XNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function V_(e,t,n,r,i,a){return new Hb(e.e,t,e.Lj(),n,r,i,a)}function H_(e,t,n){return t==null?XA(e.f,null,n):uE(e.i,t,n)}function U_(e,t){e.c&&Db(e.c.g,e),e.c=t,e.c&&M(e.c.g,e)}function W_(e,t){e.c&&Db(e.c.a,e),e.c=t,e.c&&M(e.c.a,e)}function G_(e,t){e.i&&Db(e.i.j,e),e.i=t,e.i&&M(e.i.j,e)}function K_(e,t){e.d&&Db(e.d.e,e),e.d=t,e.d&&M(e.d.e,e)}function q_(e,t){e.a&&Db(e.a.k,e),e.a=t,e.a&&M(e.a.k,e)}function J_(e,t){e.b&&Db(e.b.f,e),e.b=t,e.b&&M(e.b.f,e)}function ARe(e,t){rFe(e,e.b,e.c),P(e.b.b,68),t&&P(t.b,68).b}function jRe(e,t){return aE(P(e.c,65).c.e.b,P(t.c,65).c.e.b)}function MRe(e,t){return aE(P(e.c,65).c.e.a,P(t.c,65).c.e.a)}function NRe(e){return Qw(),rd(),P(e.a,86).d.e!=0}function Y_(e,t){j(e.Cb,184)&&(P(e.Cb,184).tb=null),GS(e,t)}function X_(e,t){j(e.Cb,90)&&$A(_y(P(e.Cb,90)),4),GS(e,t)}function PRe(e,t){hE(e,t),j(e.Cb,90)&&$A(_y(P(e.Cb,90)),2)}function FRe(e,t){t.c!=null&&Dh(e,new mh(t.c))}function IRe(e){var t,n=(Ra(),t=new kr,t);return Nx(n,e),n}function LRe(e){var t,n=(Ra(),t=new kr,t);return Nx(n,e),n}function RRe(e){for(var t;;)if(t=e.Pb(),!e.Ob())return t}function zRe(e,t,n){return M(e.a,(eg(),ik(t,n),new oo(t,n))),e}function Z_(e,t){return Qo(),ex(t)?new hp(t,e):new Qc(t,e)}function Q_(e){return AM(),dT(e,0)>=0?yD(e):Xm(yD(kb(e)))}function BRe(e){var t=P(cp(e.b),9);return new xf(e.a,t,e.c)}function VRe(e,t){var n=P(TT(Rg(e.a),t),16);return n?n.gc():0}function HRe(e,t,n){var r;I$e(t,n,e.c.length),r=n-t,wye(e.c,t,r)}function $_(e,t,n){I$e(t,n,e.gc()),this.c=e,this.a=t,this.b=n-t}function ev(e){this.c=new vo,this.b=e.b,this.d=e.c,this.a=e.a}function tv(e){this.a=r.Math.cos(e),this.b=r.Math.sin(e)}function nv(e,t,n,r){this.c=e,this.d=r,q_(this,t),J_(this,n)}function URe(e,t){P_e.call(this,new go(xx(e))),vS(t,Jvt),this.a=t}function WRe(e,t,n){return new IA(e,(Sb(),dK),null,!1,t,n)}function GRe(e,t,n){return new IA(e,(Sb(),pK),t,n,null,!1)}function KRe(){return Zw(),U(O(xK,1),Z,108,0,[vK,yK,bK])}function qRe(){return Xb(),U(O(IEt,1),Z,472,0,[sq,oq,aq])}function JRe(){return Cb(),U(O(NEt,1),Z,471,0,[rq,nq,iq])}function YRe(){return Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])}function XRe(){return Yb(),U(O(_J,1),Z,391,0,[hJ,mJ,gJ])}function ZRe(){return kS(),U(O(MX,1),Z,372,0,[jX,AX,kX])}function QRe(){return bS(),U(O(nZ,1),Z,322,0,[eZ,$X,tZ])}function $Re(){return lS(),U(O(oZ,1),Z,351,0,[rZ,aZ,iZ])}function eze(){return _w(),U(O(ckt,1),Z,460,0,[_Z,gZ,vZ])}function tze(){return qC(),U(O(rQ,1),Z,299,0,[tQ,nQ,eQ])}function nze(){return Zb(),U(O(gkt,1),Z,311,0,[aQ,oQ,iQ])}function rze(){return hT(),U(O(PMt,1),Z,390,0,[P0,NMt,F0])}function ize(){return uS(),U(O(ZMt,1),Z,463,0,[i2,n2,r2])}function aze(){return CC(),U(O(tNt,1),Z,387,0,[$Mt,a2,eNt])}function oze(){return Nw(),U(O(rNt,1),Z,349,0,[c2,o2,s2])}function sze(){return Xw(),U(O(oNt,1),Z,350,0,[l2,aNt,u2])}function cze(){return cS(),U(O(uNt,1),Z,352,0,[lNt,d2,cNt])}function lze(){return sw(),U(O(fNt,1),Z,388,0,[p2,m2,f2])}function uze(){return sS(),U(O(ANt,1),Z,464,0,[h2,g2,_2])}function rv(e){return Sw(U(O(K3,1),X,8,0,[e.i.n,e.n,e.a]))}function dze(){return Pw(),U(O(FPt,1),Z,392,0,[PPt,B2,z2])}function fze(){fze=C,kFt=tm(new Zh,(Ok(),F2),(LM(),CPt))}function iv(){iv=C,v4=new iSe(`DFS`,0),EFt=new iSe(`BFS`,1)}function pze(e,t,n){var r=new zie;r.b=t,r.a=n,++t.b,M(e.d,r)}function mze(e,t,n){var r=new Vl(n.d);$d(r,e),fE(t,r.a,r.b)}function hze(e,t){cTe(e,nm(uv(lm(t,24),jI)),nm(uv(t,jI)))}function av(e,t){if(e<0||e>t)throw E(new Mi(HI+e+UI+t))}function ov(e,t){if(e<0||e>=t)throw E(new Mi(HI+e+UI+t))}function sv(e,t){if(e<0||e>=t)throw E(new ra(HI+e+UI+t))}function cv(e,t){this.b=(Gh(e),e),this.a=(t&uI)==0?t|64|ZP:t}function gze(e){var t;return lE(e),t=(Bg(),Bg(),rK),Cx(e,t)}function _ze(e,t,n){var r=vN(e,t,!1);return r.b<=t&&r.a<=n}function vze(){return Tb(),U(O(wLt,1),Z,439,0,[c3,CLt,SLt])}function yze(){return TE(),U(O(LIt,1),Z,394,0,[IIt,Q4,FIt])}function bze(){return ED(),U(O(kIt,1),Z,445,0,[L4,R4,z4])}function xze(){return LO(),U(O(jIt,1),Z,456,0,[B4,H4,V4])}function Sze(){return Yw(),U(O(HFt,1),Z,393,0,[O4,BFt,VFt])}function Cze(){return SC(),U(O(DIt,1),Z,300,0,[I4,EIt,TIt])}function wze(){return _T(),U(O(yBt,1),Z,346,0,[_8,g8,v8])}function Tze(){return KT(),U(O(_3,1),Z,444,0,[m3,h3,g3])}function Eze(){return Lx(),U(O(rBt,1),Z,278,0,[o8,s8,c8])}function Dze(){return gT(),U(O(BBt,1),Z,280,0,[zBt,M5,N5])}function lv(e){return ph(e),j(e,16)?new bf(P(e,16)):Xf(e.Kc())}function Oze(e,t){return e&&e.equals?e.equals(t):A(e)===A(t)}function uv(e,t){return MC(BNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function dv(e,t){return MC(VNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function fv(e,t){return MC(HNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function kze(e,t){var n=(Gh(e),e).g;return sDe(!!n),Gh(t),n(t)}function Aze(e,t){var n,r=Im(e,t);return n=e.a.fd(r),new tbe(e,n)}function jze(e){return e.Db>>16==6?P(xj(e),241):null}function Mze(e){if(e.p!=2)throw E(new Rr);return nm(e.f)&OF}function Nze(e){if(e.p!=2)throw E(new Rr);return nm(e.k)&OF}function z(e){return jd(e.ar)}function Yze(e,t){var n=jb(t);return P(xh(e.c,n),17).a}function gv(e,t,n){var r=e.d[t.p];e.d[t.p]=e.d[n.p],e.d[n.p]=r}function Xze(e,t,n){var r;e.n&&t&&n&&(r=new Ese,M(e.e,r))}function _v(e,t){if(Lm(e.a,t),t.d)throw E(new yi(xyt));t.d=e}function Zze(e,t){this.a=new T,this.d=new T,this.f=e,this.c=t}function Qze(){this.c=new Hwe,this.a=new JUe,this.b=new Kge,Fbe()}function $ze(){lw(),this.b=new Dr,this.a=new Dr,this.c=new T}function eBe(e,t,n){this.d=e,this.j=t,this.e=n,this.o=-1,this.p=3}function tBe(e,t,n){this.d=e,this.k=t,this.f=n,this.o=-1,this.p=5}function nBe(e,t,n,r,i,a){Gqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function rBe(e,t,n,r,i,a){Kqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function iBe(e,t,n,r,i,a){vUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function aBe(e,t,n,r,i,a){Yqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function oBe(e,t,n,r,i,a){yUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function sBe(e,t,n,r,i,a){qqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function cBe(e,t,n,r,i,a){Jqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function lBe(e,t,n,r,i,a){bUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function uBe(e,t,n,r){xr.call(this,n),this.b=e,this.c=t,this.d=r}function dBe(e,t){this.f=e,this.a=(By(),u9),this.c=u9,this.b=t}function fBe(e,t){this.g=e,this.d=(By(),d9),this.a=d9,this.b=t}function pBe(e,t){!e.c&&(e.c=new DC(e,0)),ON(e.c,(UN(),w9),t)}function mBe(e,t){return Wit(e,t,j(t,102)&&(P(t,19).Bb&pI)!=0)}function hBe(e,t){return DPe(LC(e.q.getTime()),LC(t.q.getTime()))}function gBe(e){return yp(e.e.Rd().gc()*e.c.Rd().gc(),16,new ode(e))}function _Be(e){return!!e.u&&Jv(e.u.a).i!=0&&!(e.n&&QO(e.n))}function vBe(e){return!!e.a&&Ib(e.a.a).i!=0&&!(e.b&&$O(e.b))}function yBe(e,t){return t==0?!!e.o&&e.o.f!=0:mO(e,t)}function bBe(e,t,n){var r=P(e.Zb().xc(t),16);return!!r&&r.Hc(n)}function xBe(e,t,n){var r=P(e.Zb().xc(t),16);return!!r&&r.Mc(n)}function SBe(e,t){var n=1-t;return e.a[n]=FS(e.a[n],n),FS(e,t)}function CBe(e,t){var n,r=uv(e,_I);return n=cm(t,32),dv(n,r)}function wBe(e,t,n){Z3e(new xRe((ph(e),new bf(e)),t,n))}function vv(e,t,n){Q3e(new SRe((ph(e),new bf(e)),t,n))}function yv(e,t,n,r,i,a){return lXe(e,t,n,a),IT(e,r),zT(e,i),e}function TBe(e,t,n,r){return e.a+=``+p_(t==null?IP:PE(t),n,r),e}function bv(e,t){this.a=e,qn.call(this,e),av(t,e.gc()),this.b=t}function EBe(e){this.a=V(WW,FP,1,dZe(r.Math.max(8,e))<<1,5,1)}function xv(e){return P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199)}function Sv(e){return P(rO(e,V(VJ,AR,18,e.c.length,0,1)),483)}function DBe(e){return e.a?e.e.length==0?e.a.a:e.a.a+(``+e.e):e.c}function Cv(e){for(;e.d>0&&e.a[--e.d]==0;);e.a[e.d++]==0&&(e.e=0)}function OBe(e){return jd(e.b.b!=e.d.a),e.c=e.b=e.b.b,--e.a,e.c.c}function kBe(e,t,n){e.a=t,e.c=n,e.b.a.$b(),Fg(e.d),Wr(e.e.a.c,0)}function ABe(e,t){var n;e.e=new D_e,n=sM(t),hu(n,e.c),pct(e,n,0)}function wv(e,t,n,r){var i=new Koe;i.a=t,i.b=n,i.c=r,up(e.a,i)}function B(e,t,n,r){var i=new Koe;i.a=t,i.b=n,i.c=r,up(e.b,i)}function jBe(e,t,n){if(e<0||tn)throw E(new Mi(yet(e,t,n)))}function Tv(e,t){if(e<0||e>=t)throw E(new Mi(jtt(e,t)));return e}function MBe(e){if(!(`stack`in e))try{throw e}catch{}return e}function Ev(e){return Lo(),j(e.g,10)?P(e.g,10):null}function NBe(e){return!bg(e).dc()&&(gwe(e,new h),!0)}function Dv(e){var t;return Il(e)?(t=e,t==-0?0:t):lKe(e)}function PBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function FBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function IBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function LBe(e){var t;return Hh(e),t=new fe,Qa(e.a,new Vfe(t)),t}function RBe(){var e,t=(n=(e=new kr,e),n),n;return M(fHt,t),t}function Ov(e){var t;return Hh(e),t=new pe,Qa(e.a,new Hfe(t)),t}function zBe(e,t){return e.a<=e.b&&(t.Dd(e.a++),!0)}function BBe(e){rC.call(this,e,(Sb(),uK),null,!1,null,!1)}function VBe(){VBe=C,hDt=nT((No(),U(O(Oq,1),Z,489,0,[Dq])))}function HBe(){HBe=C,wNt=LFe(G(1),G(4)),CNt=LFe(G(1),G(2))}function UBe(e,t){return new Vf(t,wd(xu(t.e),e,e),(rd(),!0))}function kv(e){return new Hy((vS(e,_F),bx(yE(yE(5,e),e/10|0))))}function WBe(e){return yp(e.e.Rd().gc()*e.c.Rd().gc(),273,new ade(e))}function GBe(e){return P(rO(e,V(EOt,Sbt,12,e.c.length,0,1)),2042)}function KBe(e){return z_(),!gy(e)&&!(!gy(e)&&e.c.i.c==e.d.i.c)}function qBe(e,t){return Rx(),P(K(t,(rN(),u4)),17).a>=e.gc()}function Av(e,t){L_t(t,e),Yje(e.d),Yje(P(K(e,(mP(),L1)),214))}function jv(e,t){R_t(t,e),Xje(e.d),Xje(P(K(e,(mP(),L1)),214))}function JBe(e,t,n){e.d&&Db(e.d.e,e),e.d=t,e.d&&Jp(e.d.e,n,e)}function YBe(e,t,n){return n.f.c.length>0?bPe(e.a,t,n):bPe(e.b,t,n)}function XBe(e,t,n){var r=b2e();try{return qDe(e,t,n)}finally{CHe(r)}}function Mv(e,t){var n=A_(e,t),r=null;return n&&(r=n.pe()),r}function Nv(e,t){var n=A_(e,t),r=null;return n&&(r=n.se()),r}function Pv(e,t){var n=ax(e,t),r=null;return n&&(r=n.se()),r}function Fv(e,t){var n=A_(e,t),r=null;return n&&(r=ket(n)),r}function ZBe(e,t,n){var r=RD(n);return PM(e.g,r,t),PM(e.i,t,n),t}function QBe(e,t,n){this.d=new nme(this),this.e=e,this.i=t,this.f=n}function $Be(e,t,n,r){this.e=null,this.c=e,this.d=t,this.a=n,this.b=r}function eVe(e,t,n,r){jwe(this),this.c=e,this.e=t,this.f=n,this.b=r}function tVe(e,t,n,r){this.d=e,this.n=t,this.g=n,this.o=r,this.p=-1}function nVe(e,t,n,r){return j(n,59)?new lEe(e,t,n,r):new qNe(e,t,n,r)}function Iv(e){return j(e,16)?P(e,16).dc():!e.Kc().Ob()}function rVe(e){if(e.e.g!=e.b)throw E(new Vr);return!!e.c&&e.d>0}function Lv(e){return jd(e.b!=e.d.c),e.c=e.b,e.b=e.b.a,++e.a,e.c.c}function iVe(e,t){Gh(t),Sh(e.a,e.c,t),e.c=e.c+1&e.a.length-1,L3e(e)}function Rv(e,t){Gh(t),e.b=e.b-1&e.a.length-1,Sh(e.a,e.b,t),L3e(e)}function aVe(e){var t=e.Gh();this.a=j(t,71)?P(t,71).Ii():t.Kc()}function oVe(e){return new cv(wqe(P(e.a.md(),16).gc(),e.a.ld()),16)}function sVe(){sVe=C,FLt=nT((Bo(),U(O(PLt,1),Z,490,0,[v3])))}function cVe(){cVe=C,LLt=nT((Vo(),U(O(ILt,1),Z,558,0,[y3])))}function lVe(){lVe=C,SRt=nT((Ho(),U(O(xRt,1),Z,539,0,[O3])))}function uVe(){return YD(),U(O(zJ,1),Z,389,0,[RJ,IJ,FJ,LJ])}function dVe(){return Sb(),U(O(mK,1),Z,304,0,[uK,dK,fK,pK])}function fVe(){return TO(),U(O(lDt,1),Z,332,0,[gq,hq,_q,vq])}function pVe(){return wO(),U(O(pDt,1),Z,406,0,[wq,Cq,Tq,Eq])}function mVe(){return KC(),U(O(sDt,1),Z,417,0,[mq,dq,fq,pq])}function hVe(){return ow(),U(O(mOt,1),Z,416,0,[kJ,MJ,AJ,jJ])}function gVe(){return aw(),U(O(KOt,1),Z,421,0,[bX,xX,SX,CX])}function _Ve(){return iw(),U(O(FOt,1),Z,371,0,[gX,mX,hX,pX])}function vVe(){return IO(),U(O(B0,1),Z,203,0,[R0,z0,L0,I0])}function yVe(){return ID(),U(O(qMt,1),Z,284,0,[Z0,KMt,Q0,$0])}function bVe(e){var t;return e.j==(nP(),m5)&&(t=krt(e),$u(t,X8))}function xVe(e,t){var n=t.a;U_(n,t.c.d),K_(n,t.d.d),vC(n.a,e.n)}function SVe(e,t){var n=P(ix(e.b,t),67);return!n&&(n=new vo),n}function zv(e){return Lo(),j(e.g,154)?P(e.g,154):null}function CVe(e){e.a=null,e.e=null,Wr(e.b.c,0),Wr(e.f.c,0),e.c=null}function Bv(){Bv=C,sQ=new Js(sL,0),cQ=new Js(`TOP_LEFT`,1)}function Vv(){Vv=C,b2=new zxe(`UPPER`,0),y2=new zxe(`LOWER`,1)}function wVe(e,t){return Ou(new k(t.e.a+t.f.a/2,t.e.b+t.f.b/2),e)}function TVe(e,t){return P(Ju(_m(P(Dy(e.k,t),15).Oc(),HX)),113)}function EVe(e,t){return P(Ju(vm(P(Dy(e.k,t),15).Oc(),HX)),113)}function DVe(){return Ok(),U(O(yPt,1),Z,405,0,[N2,P2,F2,I2])}function OVe(){return Jw(),U(O(wFt,1),Z,353,0,[_4,h4,g4,m4])}function kVe(){return uk(),U(O(CIt,1),Z,354,0,[F4,xIt,SIt,bIt])}function AVe(){return TD(),U(O(S5,1),Z,386,0,[b5,x5,y5,v5])}function jVe(){return kk(),U(O(xBt,1),Z,291,0,[S8,y8,b8,x8])}function MVe(){return wE(),U(O(p8,1),Z,223,0,[f8,u8,l8,d8])}function NVe(){return ZE(),U(O(JBt,1),Z,320,0,[F5,GBt,qBt,KBt])}function PVe(){return Mw(),U(O(eVt,1),Z,415,0,[I5,QBt,ZBt,$Bt])}function FVe(e){return R_(),km(p7,e)?P(xh(p7,e),341).Qg():null}function Hv(e,t,n){return t<0?cj(e,n):P(n,69).wk().Bk(e,e.hi(),t)}function IVe(e,t,n){var r=RD(n);return PM(e.j,r,t),Qh(e.k,t,n),t}function LVe(e,t,n){var r=RD(n);return PM(e.d,r,t),Qh(e.e,t,n),t}function RVe(e){var t=(Ia(),n=new nn,n),n;return e&&Hj(t,e),t}function zVe(e){var t=e.aj(e.i);return e.i>0&&tN(e.g,0,t,0,e.i),t}function BVe(e,t){var n;for(n=e.j.c.length;n>24}function WVe(e){if(e.p!=1)throw E(new Rr);return nm(e.k)<<24>>24}function GVe(e){if(e.p!=7)throw E(new Rr);return nm(e.k)<<16>>16}function KVe(e){if(e.p!=7)throw E(new Rr);return nm(e.f)<<16>>16}function Uv(e,t){return t.e==0||e.e==0?JG:(pM(),Xj(e,t))}function qVe(e,t){return A(t)===A(e)?`(this Map)`:t==null?IP:PE(t)}function JVe(e,t,n){return dm(N(nl(Kp(e.f,t))),N(nl(Kp(e.f,n))))}function YVe(e,t,n){var r=P(xh(e.g,n),60);M(e.a.c,new Kc(t,r))}function XVe(e,t,n){e.i=0,e.e=0,t!=n&&(zZe(e,t,n),RZe(e,t,n))}function ZVe(e,t,n,r,i){M(t,vtt(i,mat(i,n,r))),p9e(e,i,t)}function QVe(e,t,n,r,i){this.i=e,this.a=t,this.e=n,this.j=r,this.f=i}function $Ve(e,t){r_.call(this),this.a=e,this.b=t,M(this.a.b,this)}function eHe(e){this.b=new Dr,this.c=new Dr,this.d=new Dr,this.a=e}function tHe(e,t){var n=new na;return e.Gd(n),n.a+=`..`,t.Hd(n),n.a}function nHe(e,t){for(var n=t;n;)Sd(e,n.i,n.j),n=I_(n);return e}function rHe(e,t,n){var r=RD(n);return Qh(e.b,r,t),Qh(e.c,t,n),t}function Wv(e){for(var t=0;e.Ob();)e.Pb(),t=yE(t,1);return bx(t)}function Gv(e,t){Qo();var n=P(e,69).vk();return L9e(n,t),n.xl(t)}function iHe(e,t,n){if(n){var r=n.oe();e.a[t]=r(n)}else delete e.a[t]}function aHe(e,t){var n=e.q.getHours();e.q.setFullYear(t+VF),dN(e,n)}function oHe(e,t){return P(t==null?nl(Kp(e.f,null)):as(e.i,t),288)}function sHe(e,t){return e==(DA(),JJ)&&t==JJ?4:e==JJ||t==JJ?8:32}function Kv(e,t,n){return sN(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function cHe(e,t,n){return pN(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function lHe(e,t,n){return tat(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function uHe(e){e.b!=e.c&&(e.a=V(WW,FP,1,8,5,1),e.b=0,e.c=0)}function qv(e){return jd(e.a=0&&e.a[n]===t[n];n--);return n<0}function oy(e){var t;return e?new Ap(e):(t=new Rl,HS(t,e),t)}function SHe(e,t){var n,r=!1;do n=mZe(e,t),r|=n;while(n);return r}function CHe(e){e&&OKe((Si(),cG)),--oG,e&&sG!=-1&&(gCe(sG),sG=-1)}function sy(e){s7e(),cTe(this,nm(uv(lm(e,24),jI)),nm(uv(e,jI)))}function wHe(){wHe=C,DEt=nT((fO(),U(O(DK,1),Z,436,0,[EK,TK])))}function THe(){THe=C,OEt=nT((dx(),U(O(AK,1),Z,435,0,[OK,kK])))}function EHe(){EHe=C,NDt=nT((fx(),U(O(Uq,1),Z,432,0,[Vq,Hq])))}function DHe(){DHe=C,AOt=nT((dC(),U(O(kOt,1),Z,517,0,[aY,iY])))}function OHe(){OHe=C,vkt=nT((Bv(),U(O(lQ,1),Z,429,0,[sQ,cQ])))}function kHe(){kHe=C,skt=nT((px(),U(O(hZ,1),Z,428,0,[pZ,mZ])))}function AHe(){AHe=C,dkt=nT((wb(),U(O(OZ,1),Z,488,0,[DZ,EZ])))}function jHe(){jHe=C,XMt=nT((Qb(),U(O(YMt,1),Z,430,0,[e2,t2])))}function MHe(){MHe=C,RNt=nT((Vv(),U(O(LNt,1),Z,531,0,[b2,y2])))}function NHe(){NHe=C,rkt=nT((Ky(),U(O(QX,1),Z,431,0,[XX,ZX])))}function PHe(){PHe=C,OFt=nT((iv(),U(O(DFt,1),Z,433,0,[v4,EFt])))}function FHe(){FHe=C,PFt=nT((AS(),U(O(NFt,1),Z,501,0,[b4,x4])))}function IHe(){IHe=C,qNt=nT((O_(),U(O(KNt,1),Z,523,0,[w2,C2])))}function LHe(){LHe=C,YNt=nT((k_(),U(O(JNt,1),Z,522,0,[T2,E2])))}function RHe(){RHe=C,dPt=nT((Wy(),U(O(uPt,1),Z,528,0,[A2,k2])))}function zHe(){zHe=C,vPt=nT((D_(),U(O(_Pt,1),Z,465,0,[j2,M2])))}function BHe(){BHe=C,zFt=nT((_b(),U(O(RFt,1),Z,434,0,[LFt,D4])))}function VHe(){VHe=C,xLt=nT((my(),U(O(bLt,1),Z,491,0,[s3,yLt])))}function HHe(){HHe=C,kLt=nT((JC(),U(O(OLt,1),Z,492,0,[ELt,DLt])))}function UHe(){UHe=C,zLt=nT((Gy(),U(O(RLt,1),Z,438,0,[x3,b3])))}function WHe(){WHe=C,TRt=nT((cw(),U(O(wRt,1),Z,437,0,[k3,CRt])))}function GHe(){GHe=C,WBt=nT((zf(),U(O(P5,1),Z,347,0,[HBt,UBt])))}function KHe(){return GT(),U(O(a8,1),Z,88,0,[r8,n8,t8,e8,i8])}function qHe(){return nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])}function JHe(e,t,n){return P(t==null?XA(e.f,null,n):uE(e.i,t,n),288)}function YHe(e){return(e.k==(DA(),JJ)||e.k==GJ)&&yd(e,(Y(),bQ))}function cy(e){return e.c&&e.d?Gze(e.c)+`->`+Gze(e.d):`e_`+td(e)}function ly(e,t){var n,r;for(Gh(t),r=e.Kc();r.Ob();)n=r.Pb(),t.Cd(n)}function XHe(e,t){var n=new bi;qg(n,`x`,t.a),qg(n,`y`,t.b),Dh(e,n)}function ZHe(e,t){var n=new bi;qg(n,`x`,t.a),qg(n,`y`,t.b),Dh(e,n)}function QHe(e,t){for(var n=t;n;)Sd(e,-n.i,-n.j),n=I_(n);return e}function $He(e,t){for(var n=t,r=0;n>0;)r+=e.a[n],n-=n&-n;return r}function uy(e,t,n){var r=(ov(t,e.c.length),e.c[t]);return e.c[t]=n,r}function eUe(e,t,n){e.a.c.length=0,Tmt(e,t,n),e.a.c.length==0||Mut(e,t)}function dy(e){e.i=0,is(e.b,null),is(e.c,null),e.a=null,e.e=null,++e.g}function fy(){fy=C,_K=!0,mEt=!1,hEt=!1,_Et=!1,gEt=!1}function py(e){fy(),!_K&&(this.c=e,this.e=!0,this.a=new T)}function tUe(e,t){this.c=0,this.b=t,oCe.call(this,e,17493),this.a=this.c}function nUe(e){Cvt(),lge(this),this.a=new vo,tQe(this,e),up(this.a,e)}function rUe(){au(this),this.b=new k(cI,cI),this.a=new k(lI,lI)}function my(){my=C,s3=new sSe(YR,0),yLt=new sSe(`TARGET_WIDTH`,1)}function hy(e,t){return(lE(e),Xa(new Mp(e,new UGe(t,e.a)))).Bd(SK)}function iUe(){return vA(),U(O(CJ,1),Z,367,0,[vJ,yJ,bJ,xJ,SJ])}function aUe(){return tA(),U(O(JOt,1),Z,375,0,[TX,DX,OX,EX,wX])}function oUe(){return FD(),U(O(fZ,1),Z,348,0,[cZ,sZ,uZ,dZ,lZ])}function sUe(){return CO(),U(O(RMt,1),Z,323,0,[LMt,H0,U0,V0,W0])}function cUe(){return XE(),U(O(y$,1),Z,171,0,[v$,m$,h$,g$,_$])}function lUe(){return iA(),U(O(FFt,1),Z,368,0,[T4,S4,E4,C4,w4])}function uUe(){return Wj(),U(O(jLt,1),Z,373,0,[u3,l3,f3,d3,p3])}function dUe(){return MA(),U(O(ULt,1),Z,324,0,[BLt,S3,HLt,C3,VLt])}function fUe(){return uO(),U(O(L3,1),Z,170,0,[F3,P3,M3,I3,N3])}function pUe(){return pO(),U(O(I8,1),Z,256,0,[P8,F8,wBt,N8,TBt])}function mUe(e){return Qi(),function(){return XBe(e,this,arguments)}}function gy(e){return!e.c||!e.d?!1:!!e.c.i&&e.c.i==e.d.i}function hUe(e,t){return j(t,143)?ff(e.c,P(t,143).c):!1}function _y(e){return e.t||(e.t=new Bhe(e),WT(new K_e(e),0,e.t)),e.t}function gUe(e){this.b=e,Lu.call(this,e),this.a=P(NC(this.b.a,4),129)}function _Ue(e){this.b=e,ld.call(this,e),this.a=P(NC(this.b.a,4),129)}function vy(e,t,n,r,i){KUe.call(this,t,r,i),this.c=e,this.b=n}function vUe(e,t,n,r,i){eBe.call(this,t,r,i),this.c=e,this.a=n}function yUe(e,t,n,r,i){tBe.call(this,t,r,i),this.c=e,this.a=n}function bUe(e,t,n,r,i){KUe.call(this,t,r,i),this.c=e,this.a=n}function yy(e,t){return P(ix(e.d,t),23)||P(ix(e.e,t),23)}function xUe(e,t){var n=t.ld(),r=e.Fe(n);return!!r&&rg(r.e,t.md())}function SUe(e,t){var n=t.ld();return new oo(n,e.e.pc(n,P(t.md(),16)))}function CUe(e,t){return e.a.get(t)??V(WW,FP,1,0,5,1)}function wUe(e){var t=e.length;return ff(fI.substr(fI.length-t,t),e)}function by(e){if(Cj(e))return e.c=e.a,e.a.Pb();throw E(new Hr)}function TUe(e,t){return t==0||e.e==0?e:t>0?Cst(e,t):F0e(e,-t)}function xy(e,t){return t==0||e.e==0?e:t>0?F0e(e,t):Cst(e,-t)}function EUe(e){txe.call(this,e==null?IP:PE(e),j(e,82)?P(e,82):null)}function DUe(e){var t;return e.c||(t=e.r,j(t,90)&&(e.c=P(t,29))),e.c}function Sy(e){var t=new i_;return VC(t,e),W(t,(mP(),j1),null),t}function OUe(e){var t=e.c.i,n=e.d.i;return t.k==(DA(),GJ)&&n.k==GJ}function Cy(e){return vu(e&QF,e>>22&QF,e<0?$F:0)}function kUe(e){var t,n,r,i;for(n=e,r=0,i=n.length;r=0?e.Lh(r,n,!0):mj(e,t,n)}function jUe(e,t,n){return aE(Ou(cO(e),xu(t.b)),Ou(cO(e),xu(n.b)))}function MUe(e,t,n){return aE(Ou(cO(e),xu(t.e)),Ou(cO(e),xu(n.e)))}function NUe(e,t){return r.Math.min(ab(t.a,e.d.d.c),ab(t.b,e.d.d.c))}function Ty(e,t){e._i(e.i+1),Au(e,e.i,e.Zi(e.i,t)),e.Mi(e.i++,t),e.Ni()}function Ey(e){var t,n;++e.j,t=e.g,n=e.i,e.g=null,e.i=0,e.Oi(n,t),e.Ni()}function PUe(e,t,n){var r=new Rwe(e.a);mC(r,e.a.a),XA(r.f,t,n),e.a.a=r}function FUe(e,t,n,r){var i;for(i=0;it)throw E(new Mi(ptt(e,t,`index`)));return e}function Ay(e,t){var n=(ov(t,e.c.length),e.c[t]);return wye(e.c,t,1),n}function zUe(e,t){var n=(Gh(e),e),r=(Gh(t),t);return n==r?0:nt.p?-1:0}function tWe(e){var t;return e.a||(t=e.r,j(t,156)&&(e.a=P(t,156))),e.a}function nWe(e,t,n){var r;return++e.e,--e.f,r=P(e.d[t].gd(n),136),r.md()}function rWe(e){var t=e.ld();return qf(P(e.md(),16).Nc(),new cde(t))}function iWe(e,t){return km(e.a,t)?(My(e.a,t),!0):!1}function Iy(e,t,n){return Tv(t,e.e.Rd().gc()),Tv(n,e.c.Rd().gc()),e.a[t][n]}function Ly(e,t,n){this.a=e,this.b=t,this.c=n,M(e.t,this),M(t.i,this)}function Ry(e,t,n,r){this.f=e,this.e=t,this.d=n,this.b=r,this.c=r?r.d:null}function zy(){this.b=new vo,this.a=new vo,this.b=new vo,this.a=new vo}function By(){By=C;var e,t;u9=(Ra(),t=new Ur,t),d9=(e=new oi,e)}function aWe(e){var t;return lE(e),t=new Mje(e,e.a.e,e.a.d|4),new fDe(e,t)}function oWe(e){var t;for(Hh(e),t=0;e.a.Bd(new Be);)t=yE(t,1);return t}function Vy(e,t){return Gh(t),e.c=0,`Initial capacity must not be negative`)}function Uy(){Uy=C,G3=new yr(`org.eclipse.elk.labels.labelManager`)}function sWe(){sWe=C,fX=new Wd(`separateLayerConnections`,(iw(),gX))}function Wy(){Wy=C,A2=new nSe(`REGULAR`,0),k2=new nSe(`CRITICAL`,1)}function Gy(){Gy=C,x3=new lSe(`FIXED`,0),b3=new lSe(`CENTER_NODE`,1)}function Ky(){Ky=C,XX=new Lxe(`QUADRATIC`,0),ZX=new Lxe(`SCANLINE`,1)}function cWe(){cWe=C,ikt=nT((bS(),U(O(nZ,1),Z,322,0,[eZ,$X,tZ])))}function lWe(){lWe=C,akt=nT((lS(),U(O(oZ,1),Z,351,0,[rZ,aZ,iZ])))}function uWe(){uWe=C,ekt=nT((kS(),U(O(MX,1),Z,372,0,[jX,AX,kX])))}function dWe(){dWe=C,lkt=nT((_w(),U(O(ckt,1),Z,460,0,[_Z,gZ,vZ])))}function fWe(){fWe=C,hkt=nT((qC(),U(O(rQ,1),Z,299,0,[tQ,nQ,eQ])))}function pWe(){pWe=C,_kt=nT((Zb(),U(O(gkt,1),Z,311,0,[aQ,oQ,iQ])))}function mWe(){mWe=C,FMt=nT((hT(),U(O(PMt,1),Z,390,0,[P0,NMt,F0])))}function hWe(){hWe=C,nNt=nT((CC(),U(O(tNt,1),Z,387,0,[$Mt,a2,eNt])))}function gWe(){gWe=C,iNt=nT((Nw(),U(O(rNt,1),Z,349,0,[c2,o2,s2])))}function _We(){_We=C,QMt=nT((uS(),U(O(ZMt,1),Z,463,0,[i2,n2,r2])))}function vWe(){vWe=C,sNt=nT((Xw(),U(O(oNt,1),Z,350,0,[l2,aNt,u2])))}function yWe(){yWe=C,dNt=nT((cS(),U(O(uNt,1),Z,352,0,[lNt,d2,cNt])))}function bWe(){bWe=C,pNt=nT((sw(),U(O(fNt,1),Z,388,0,[p2,m2,f2])))}function xWe(){xWe=C,IPt=nT((Pw(),U(O(FPt,1),Z,392,0,[PPt,B2,z2])))}function SWe(){SWe=C,UFt=nT((Yw(),U(O(HFt,1),Z,393,0,[O4,BFt,VFt])))}function CWe(){CWe=C,OIt=nT((SC(),U(O(DIt,1),Z,300,0,[I4,EIt,TIt])))}function wWe(){wWe=C,AIt=nT((ED(),U(O(kIt,1),Z,445,0,[L4,R4,z4])))}function TWe(){TWe=C,MIt=nT((LO(),U(O(jIt,1),Z,456,0,[B4,H4,V4])))}function EWe(){EWe=C,RIt=nT((TE(),U(O(LIt,1),Z,394,0,[IIt,Q4,FIt])))}function DWe(){DWe=C,TLt=nT((Tb(),U(O(wLt,1),Z,439,0,[c3,CLt,SLt])))}function OWe(){OWe=C,jNt=nT((sS(),U(O(ANt,1),Z,464,0,[h2,g2,_2])))}function kWe(){kWe=C,PEt=nT((Cb(),U(O(NEt,1),Z,471,0,[rq,nq,iq])))}function AWe(){AWe=C,MEt=nT((Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])))}function jWe(){jWe=C,LEt=nT((Xb(),U(O(IEt,1),Z,472,0,[sq,oq,aq])))}function MWe(){MWe=C,vEt=nT((Zw(),U(O(xK,1),Z,108,0,[vK,yK,bK])))}function NWe(){NWe=C,aOt=nT((Yb(),U(O(_J,1),Z,391,0,[hJ,mJ,gJ])))}function PWe(){PWe=C,bBt=nT((_T(),U(O(yBt,1),Z,346,0,[_8,g8,v8])))}function FWe(){FWe=C,NLt=nT((KT(),U(O(_3,1),Z,444,0,[m3,h3,g3])))}function IWe(){IWe=C,iBt=nT((Lx(),U(O(rBt,1),Z,278,0,[o8,s8,c8])))}function LWe(){LWe=C,VBt=nT((gT(),U(O(BBt,1),Z,280,0,[zBt,M5,N5])))}function qy(e,t){return!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),uD(e.o,t)}function RWe(e,t){var n;e.C&&(n=P(ig(e.b,t),127).n,n.d=e.C.d,n.a=e.C.a)}function zWe(e){var t,n,r,i=e.d;t=e.a,n=e.b,r=e.c,e.d=n,e.a=r,e.b=i,e.c=t}function BWe(e){return!e.g&&(e.g=new on),!e.g.b&&(e.g.b=new Ihe(e)),e.g.b}function Jy(e){return!e.g&&(e.g=new on),!e.g.c&&(e.g.c=new zhe(e)),e.g.c}function VWe(e){return!e.g&&(e.g=new on),!e.g.d&&(e.g.d=new Lhe(e)),e.g.d}function HWe(e){return!e.g&&(e.g=new on),!e.g.a&&(e.g.a=new Rhe(e)),e.g.a}function UWe(e,t,n,r){return n&&(r=n.Rh(t,eD(n.Dh(),e.c.uk()),null,r)),r}function WWe(e,t,n,r){return n&&(r=n.Th(t,eD(n.Dh(),e.c.uk()),null,r)),r}function Yy(e,t,n,r){var i=V(q9,HF,28,t+1,15,1);return Gdt(i,e,t,n,r),i}function V(e,t,n,r,i,a){var o=b3e(i,r);return i!=10&&U(O(e,a),t,n,i,o),o}function GWe(e,t,n){var r,i=new WC(t,e);for(r=0;rn||t=0?e.Lh(n,!0,!0):mj(e,t,!0)}function gGe(e,t,n){var r=kZe(e,t,n);return e.b=new VS(r.c.length),Xst(e,r)}function _Ge(e){if(e.b<=0)throw E(new Hr);return--e.b,e.a-=e.c.c,G(e.a)}function vGe(e){var t;if(!e.a)throw E(new fIe);return t=e.a,e.a=I_(e.a),t}function yGe(e){for(;!e.a;)if(!DOe(e.c,new Ufe(e)))return!1;return!0}function hb(e){var t;return ph(e),j(e,204)?(t=P(e,204),t):new gde(e)}function bGe(e){gb(),P(e.of((vP(),z6)),181).Fc((rj(),K8)),e.qf(R6,null)}function gb(){gb=C,jRt=new Hoe,NRt=new Uoe,MRt=oQe((vP(),R6),jRt,D6,NRt)}function _b(){_b=C,LFt=new oSe(`LEAF_NUMBER`,0),D4=new oSe(`NODE_SIZE`,1)}function vb(e){e.a=V(q9,HF,28,e.b+1,15,1),e.c=V(q9,HF,28,e.b,15,1),e.d=0}function xGe(e,t){e.a.Ne(t.d,e.b)>0&&(M(e.c,new Pje(t.c,t.d,e.d)),e.b=t.d)}function SGe(e,t){if(e.g==null||t>=e.i)throw E(new wl(t,e.i));return e.g[t]}function CGe(e,t,n){if(Aw(e,n),n!=null&&!e.fk(n))throw E(new Ir);return n}function yb(e,t){return lx(t)!=10&&U($w(t),t.Sm,t.__elementTypeId$,lx(t),e),e}function bb(e,t,n,r){var i;r=(Bg(),r||nK),i=e.slice(t,n),mtt(i,e,t,n,-t,r)}function xb(e,t,n,r,i){return t<0?mj(e,n,r):P(n,69).wk().yk(e,e.hi(),t,r,i)}function wGe(e,t){return aE(D(N(K(e,(Y(),$Q)))),D(N(K(t,$Q))))}function TGe(){TGe=C,dEt=nT((Sb(),U(O(mK,1),Z,304,0,[uK,dK,fK,pK])))}function Sb(){Sb=C,uK=new ls(`All`,0),dK=new WCe,fK=new Owe,pK=new UCe}function Cb(){Cb=C,rq=new hs(cL,0),nq=new hs(sL,1),iq=new hs(lL,2)}function EGe(){EGe=C,_N(),VHt=cI,BHt=lI,UHt=new Rn(cI),HHt=new Rn(lI)}function DGe(){DGe=C,cDt=nT((KC(),U(O(sDt,1),Z,417,0,[mq,dq,fq,pq])))}function OGe(){OGe=C,mDt=nT((wO(),U(O(pDt,1),Z,406,0,[wq,Cq,Tq,Eq])))}function kGe(){kGe=C,uDt=nT((TO(),U(O(lDt,1),Z,332,0,[gq,hq,_q,vq])))}function AGe(){AGe=C,xOt=nT((YD(),U(O(zJ,1),Z,389,0,[RJ,IJ,FJ,LJ])))}function jGe(){jGe=C,hOt=nT((ow(),U(O(mOt,1),Z,416,0,[kJ,MJ,AJ,jJ])))}function MGe(){MGe=C,qOt=nT((aw(),U(O(KOt,1),Z,421,0,[bX,xX,SX,CX])))}function NGe(){NGe=C,IOt=nT((iw(),U(O(FOt,1),Z,371,0,[gX,mX,hX,pX])))}function PGe(){PGe=C,IMt=nT((IO(),U(O(B0,1),Z,203,0,[R0,z0,L0,I0])))}function FGe(){FGe=C,JMt=nT((ID(),U(O(qMt,1),Z,284,0,[Z0,KMt,Q0,$0])))}function wb(){wb=C,DZ=new Hs(wR,0),EZ=new Hs(`IMPROVE_STRAIGHTNESS`,1)}function IGe(e,t){var n,r=t/e.c.Rd().gc()|0;return n=t%e.c.Rd().gc(),Iy(e,r,n)}function LGe(e){var t;if(e.nl())for(t=e.i-1;t>=0;--t)H(e,t);return zVe(e)}function RGe(e){var t,n;if(!e.b)return null;for(n=e.b;t=n.a[0];)n=t;return n}function zGe(e){var t,n;if(!e.b)return null;for(n=e.b;t=n.a[1];)n=t;return n}function BGe(e){return j(e,180)?``+P(e,180).a:e==null?null:PE(e)}function VGe(e){return j(e,180)?``+P(e,180).a:e==null?null:PE(e)}function HGe(e,t){if(t.a)throw E(new yi(xyt));Lm(e.a,t),t.a=e,!e.j&&(e.j=t)}function UGe(e,t){vl.call(this,t.zd(),t.yd()&-16449),Gh(e),this.a=e,this.c=t}function WGe(e,t){return new Vf(t,Sd(xu(t.e),t.f.a+e,t.f.b+e),(rd(),!1))}function GGe(e,t){return Rf(),M(e,new Kc(t,G(t.e.c.length+t.g.c.length)))}function KGe(e,t){return Rf(),M(e,new Kc(t,G(t.e.c.length+t.g.c.length)))}function qGe(){qGe=C,wIt=nT((uk(),U(O(CIt,1),Z,354,0,[F4,xIt,SIt,bIt])))}function JGe(){JGe=C,TFt=nT((Jw(),U(O(wFt,1),Z,353,0,[_4,h4,g4,m4])))}function YGe(){YGe=C,bPt=nT((Ok(),U(O(yPt,1),Z,405,0,[N2,P2,F2,I2])))}function XGe(){XGe=C,aBt=nT((wE(),U(O(p8,1),Z,223,0,[f8,u8,l8,d8])))}function ZGe(){ZGe=C,SBt=nT((kk(),U(O(xBt,1),Z,291,0,[S8,y8,b8,x8])))}function QGe(){QGe=C,IBt=nT((TD(),U(O(S5,1),Z,386,0,[b5,x5,y5,v5])))}function $Ge(){$Ge=C,YBt=nT((ZE(),U(O(JBt,1),Z,320,0,[F5,GBt,qBt,KBt])))}function eKe(){eKe=C,tVt=nT((Mw(),U(O(eVt,1),Z,415,0,[I5,QBt,ZBt,$Bt])))}function Tb(){Tb=C,c3=new Cc(_xt,0),CLt=new Cc(vV,1),SLt=new Cc(wR,2)}function Eb(e,t,n,r,i){return Gh(e),Gh(t),Gh(n),Gh(r),Gh(i),new Vm(e,t,r)}function tKe(e,t){var n=P(My(e.e,t),400);return n?(pMe(n),n.e):null}function Db(e,t){var n=Ab(e,t,0);return n!=-1&&(Ay(e,n),!0)}function nKe(e,t,n){var r;return Hh(e),r=new Re,r.a=t,e.a.Nb(new uxe(r,n)),r.a}function rKe(e){var t;return Hh(e),t=V(Z9,hI,28,0,15,1),Qa(e.a,new Bfe(t)),t}function Ob(e){var t;if(!DS(e))throw E(new Hr);return e.e=1,t=e.d,e.d=null,t}function kb(e){var t;return Il(e)&&(t=0-e,!isNaN(t))?t:MC(mw(e))}function Ab(e,t,n){for(;n=0?jO(e,n,!0,!0):mj(e,t,!0)}function qb(e){var t=rS(NC(e,32));return t??=(WD(e),rS(NC(e,32))),t}function Jb(e){var t;return e.Oh()||(t=bh(e.Dh())-e.ji(),e.$h().Mk(t)),e.zh()}function fKe(e,t){bq=new Mt,fDt=t,yq=e,P(yq.b,68),ZWe(yq,bq,null),Jpt(yq)}function Yb(){Yb=C,hJ=new Cs(`XY`,0),mJ=new Cs(`X`,1),gJ=new Cs(`Y`,2)}function Xb(){Xb=C,sq=new gs(`TOP`,0),oq=new gs(sL,1),aq=new gs(Lyt,2)}function Zb(){Zb=C,aQ=new qs(wR,0),oQ=new qs(`TOP`,1),iQ=new qs(Lyt,2)}function Qb(){Qb=C,e2=new nc(`INPUT_ORDER`,0),t2=new nc(`PORT_DEGREE`,1)}function $b(){$b=C,hG=vu(QF,QF,524287),BTt=vu(0,0,eI),gG=Cy(1),Cy(2),_G=Cy(0)}function ex(e){var t;return e.d!=e.r&&(t=Ik(e),e.e=!!t&&t.lk()==xwt,e.d=t),e.e}function tx(e,t,n){var r=e.g[t];return Au(e,t,e.Zi(t,n)),e.Ri(t,n,r),e.Ni(),r}function nx(e,t){var n=e.dd(t);return n>=0&&(e.gd(n),!0)}function rx(e,t){var n;for(ph(e),ph(t),n=!1;t.Ob();)n|=e.Fc(t.Pb());return n}function ix(e,t){var n=P(xh(e.e,t),400);return n?(Ywe(e,n),n.e):null}function pKe(e){var t=e/60|0,n=e%60;return n==0?``+t:``+t+`:`+(``+n)}function ax(e,t){var n=e.a[t],r=(vw(),pG)[typeof n];return r?r(n):XQe(typeof n)}function ox(e,t){var n,r;return lE(e),r=new WUe(t,e.a),n=new zOe(r),new Mp(e,n)}function sx(e){var t=e.b.c.length==0?null:Ep(e.b,0);return t!=null&&LS(e,0),t}function mKe(e,t){var n,r,i=t.c.i;n=P(xh(e.f,i),60),r=n.d.c-n.e.c,eC(t.a,r,0)}function cx(e,t){var n;for(++e.d,++e.c[t],n=t+1;n=0;)++t[0]}function _Ke(e,t){Gx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function vKe(e,t){Kx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function yKe(e,t){Wx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function bKe(e,t){Ux(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function xKe(e,t,n){return Ou(new k(n.e.a+n.f.a/2,n.e.b+n.f.b/2),e)==(Gh(t),t)}function SKe(e,t){return j(t,102)&&(P(t,19).Bb&pI)!=0?new Dl(t,e):new WC(t,e)}function CKe(e,t){return j(t,102)&&(P(t,19).Bb&pI)!=0?new Dl(t,e):new WC(t,e)}function lx(e){return e.__elementTypeCategory$==null?10:e.__elementTypeCategory$}function wKe(e,t){return t==(Sf(),Sf(),oEt)?e.toLocaleLowerCase():e.toLowerCase()}function TKe(e){if(!e.e)throw E(new Hr);return e.c=e.a=e.e,e.e=e.e.e,--e.d,e.a.f}function ux(e){if(!e.c)throw E(new Hr);return e.e=e.a=e.c,e.c=e.c.c,++e.d,e.a.f}function EKe(e){var t;for(++e.a,t=e.c.a.length;e.ae.a[r]&&(r=n);return r}function MKe(e){var t=P(K(e,(Y(),fQ)),313);return t?t.a==e:!1}function NKe(e){var t=P(K(e,(Y(),fQ)),313);return t?t.i==e:!1}function PKe(){PKe=C,lOt=nT((vA(),U(O(CJ,1),Z,367,0,[vJ,yJ,bJ,xJ,SJ])))}function FKe(){FKe=C,YOt=nT((tA(),U(O(JOt,1),Z,375,0,[TX,DX,OX,EX,wX])))}function IKe(){IKe=C,okt=nT((FD(),U(O(fZ,1),Z,348,0,[cZ,sZ,uZ,dZ,lZ])))}function LKe(){LKe=C,zMt=nT((CO(),U(O(RMt,1),Z,323,0,[LMt,H0,U0,V0,W0])))}function RKe(){RKe=C,ykt=nT((XE(),U(O(y$,1),Z,171,0,[v$,m$,h$,g$,_$])))}function zKe(){zKe=C,IFt=nT((iA(),U(O(FFt,1),Z,368,0,[T4,S4,E4,C4,w4])))}function BKe(){BKe=C,MLt=nT((Wj(),U(O(jLt,1),Z,373,0,[u3,l3,f3,d3,p3])))}function VKe(){VKe=C,WLt=nT((MA(),U(O(ULt,1),Z,324,0,[BLt,S3,HLt,C3,VLt])))}function HKe(){HKe=C,nBt=nT((GT(),U(O(a8,1),Z,88,0,[r8,n8,t8,e8,i8])))}function UKe(){UKe=C,FRt=nT((uO(),U(O(L3,1),Z,170,0,[F3,P3,M3,I3,N3])))}function WKe(){WKe=C,EBt=nT((pO(),U(O(I8,1),Z,256,0,[P8,F8,wBt,N8,TBt])))}function GKe(){GKe=C,ABt=nT((nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])))}function dx(){dx=C,OK=new pxe(`BY_SIZE`,0),kK=new pxe(`BY_SIZE_AND_SHAPE`,1)}function fx(){fx=C,Vq=new Ss(`EADES`,0),Hq=new Ss(`FRUCHTERMAN_REINGOLD`,1)}function px(){px=C,pZ=new zs(`READING_DIRECTION`,0),mZ=new zs(`ROTATION`,1)}function mx(){mx=C,vOt=new mee,yOt=new _ee,gOt=new vee,_Ot=new gee,bOt=new yee}function KKe(e){this.b=new T,this.a=new T,this.c=new T,this.d=new T,this.e=e}function qKe(e){this.g=e,this.f=new T,this.a=r.Math.min(this.g.c.c,this.g.d.c)}function JKe(e,t,n){Qd.call(this),Px(this),this.a=e,this.c=n,this.b=t.d,this.f=t.e}function YKe(e,t,n){var r,i;for(i=new w(n);i.a=0&&t0?t-1:t;return Qve($ve(Uqe(Qje(new di,n),e.n),e.j),e.k)}function vx(e){var t,n=(t=new si,t);tb((!e.q&&(e.q=new F(M7,e,11,10)),e.q),n)}function yx(e){return(e.i&2?`interface `:e.i&1?``:`class `)+(Ad(e),e.o)}function bx(e){return dT(e,AP)>0?AP:dT(e,xF)<0?xF:nm(e)}function xx(e){return e<3?(vS(e,Qvt),e+1):e=-.01&&e.a<=fL&&(e.a=0),e.b>=-.01&&e.b<=fL&&(e.b=0),e}function Tx(e){fM();var t,n=zV;for(t=0;tn&&(n=e[t]);return n}function lqe(e,t){var n=Qj(e.Dh(),t);if(!n)throw E(new Fi(HH+t+WH));return n}function Ex(e,t){for(var n=e;I_(n);)if(n=I_(n),n==t)return!0;return!1}function uqe(e,t){var n,r=t.a.ld(),i;for(n=P(t.a.md(),16).gc(),i=0;ie||e>t)throw E(new ia(`fromIndex: 0, toIndex: `+e+MI+t))}function kx(e){if(e<0)throw E(new Fi(`Illegal Capacity: `+e));this.g=this.aj(e)}function Ax(e,t){return uu(),fS(bF),r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)}function jx(e,t){var n,r,i,a;for(r=e.d,i=0,a=r.length;i0&&(e.a/=t,e.b/=t),e}function Mx(e){var t;return e.w?e.w:(t=jze(e),t&&!t.Vh()&&(e.w=t),t)}function Nx(e,t){var n,r=e.a;n=V$e(e,t,null),r!=t&&!e.e&&(n=JN(e,t,n)),n&&n.oj()}function xqe(e,t,n){var r=t,i;do i=D(e.p[r.p])+n,e.p[r.p]=i,r=e.a[r.p];while(r!=t)}function Sqe(e,t,n){var r=function(){return e.apply(r,arguments)};return t.apply(r,n),r}function Cqe(e){var t;return e==null?null:(t=P(e,195),E7e(t,t.length))}function H(e,t){if(e.g==null||t>=e.i)throw E(new wl(t,e.i));return e.Wi(t,e.g[t])}function wqe(e,t){Vg();var n,r=new T;for(n=0;n=14&&t<=16))),e}function iS(e,t){var n;return Gh(t),n=e[`:`+t],$f(!!n,`Enum constant undefined: `+t),n}function aS(e,t,n,r,i,a){var o=fh(e,t);return Wqe(n,o),o.i=i?8:0,o.f=r,o.e=i,o.g=a,o}function Gqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=1,this.c=e,this.a=n}function Kqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=2,this.c=e,this.a=n}function qqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=6,this.c=e,this.a=n}function Jqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=7,this.c=e,this.a=n}function Yqe(e,t,n,r,i){this.d=t,this.j=r,this.e=i,this.o=-1,this.p=4,this.c=e,this.a=n}function Xqe(e,t){var n,r,i,a;for(r=t,i=0,a=r.length;i=0))throw E(new Fi(`tolerance (`+e+`) must be >= 0`));return e}function aJe(e,t){var n;return j(t,44)?e.c.Mc(t):(n=uD(e,t),BD(e,t),n)}function pS(e,t,n){return aT(e,t),GS(e,n),Zx(e,0),Qx(e,1),RT(e,!0),FT(e,!0),e}function mS(e,t){var n=e.gc();if(t<0||t>n)throw E(new lf(t,n));return new LOe(e,t)}function hS(e,t){e.b=r.Math.max(e.b,t.d),e.e+=t.r+(e.a.c.length==0?0:e.c),M(e.a,t)}function oJe(e){Md(e.c>=0),Q0e(e.d,e.c)<0&&(e.a=e.a-1&e.d.a.length-1,e.b=e.d.c),e.c=-1}function gS(e){var t,n;for(n=e.c.Cc().Kc();n.Ob();)t=P(n.Pb(),16),t.$b();e.c.$b(),e.d=0}function sJe(e){var t,n,r,i;for(n=e.a,r=0,i=n.length;r=0}function kJe(e,t){e.r>0&&e.c0&&e.g!=0&&kJe(e.i,t/e.r*e.i.d))}function AJe(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.c))}function SS(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,4,n,e.c))}function CS(e,t){var n=e.k;e.k=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,2,n,e.k))}function wS(e,t){var n=e.D;e.D=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,2,n,e.D))}function TS(e,t){var n=e.f;e.f=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,8,n,e.f))}function ES(e,t){var n=e.i;e.i=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,7,n,e.i))}function jJe(e,t){var n=e.a;e.a=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,8,n,e.a))}function MJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,n,e.b))}function NJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,n,e.b))}function PJe(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.c))}function FJe(e,t){var n=e.d;e.d=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.d))}function IJe(e,t,n){var r;e.b=t,e.a=n,r=(e.a&512)==512?new y_e:new Qle,e.c=Ust(r,e.b,e.a)}function LJe(e,t){return aM(e.e,t)?(Qo(),ex(t)?new hp(t,e):new Qc(t,e)):new ZSe(t,e)}function RJe(e){var t,n;return 0>e?new _be:(t=e+1,n=new tUe(t,e),new pDe(null,n))}function zJe(e,t){Vg();var n=new go(1);return rl(e)?H_(n,e,t):XA(n.f,e,t),new Kn(n)}function BJe(e,t){var n=e.c,r=t.e[e.p];return r>0?P(Ep(n.a,r-1),10):null}function VJe(e,t){var n=e.o+e.p,r=t.o+t.p;return nt?(t<<=1,t>0?t:mF):t}function DS(e){switch(yTe(e.e!=3),e.e){case 2:return!1;case 0:return!0}return VUe(e)}function WJe(e,t){var n;return j(t,8)?(n=P(t,8),e.a==n.a&&e.b==n.b):!1}function GJe(e,t){var n=new Mt;P(t.b,68),P(t.b,68),P(t.b,68),Dx(t.a,new Uf(e,n,t))}function KJe(e,t){var n,r;for(r=t.vc().Kc();r.Ob();)n=P(r.Pb(),44),Hk(e,n.ld(),n.md())}function qJe(e,t){var n=e.d;e.d=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,11,n,e.d))}function OS(e,t){var n=e.j;e.j=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,13,n,e.j))}function JJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,21,n,e.b))}function YJe(e,t){(fy(),_K?null:t.c).length==0&&vDe(t,new xe),H_(e.a,_K?null:t.c,t)}function XJe(e,t){t.Ug(`Hierarchical port constraint processing`,1),G2e(e),pvt(e),t.Vg()}function kS(){kS=C,jX=new Ps(`START`,0),AX=new Ps(`MIDDLE`,1),kX=new Ps(`END`,2)}function AS(){AS=C,b4=new aSe(`P1_NODE_PLACEMENT`,0),x4=new aSe(`P2_EDGE_ROUTING`,1)}function jS(){jS=C,iJ=new yr(sbt),aJ=new yr(cbt),rJ=new yr(lbt),nJ=new yr(ubt)}function MS(e){var t;return Df(e.f.g,e.d),jd(e.b),e.c=e.a,t=P(e.a.Pb(),44),e.b=FXe(e),t}function NS(e){var t;return e.b==null?(Xo(),Xo(),a9):(t=e.ul()?e.tl():e.sl(),t)}function ZJe(e,t){var n=t==null?-1:Ab(e.b,t,0);return n<0?!1:(LS(e,n),!0)}function PS(e,t){var n;return Gh(t),n=t.g,!e.b[n]&&(Sh(e.b,n,t),++e.c,!0)}function FS(e,t){var n=1-t,r=e.a[n];return e.a[n]=r.a[t],r.a[t]=e,e.b=!0,r.b=!1,r}function QJe(e,t){var n,r;for(r=t.Kc();r.Ob();)n=P(r.Pb(),272),e.b=!0,Lm(e.e,n),n.b=e}function $Je(e,t){var n=P(K(e,(mP(),n0)),8),r=P(K(t,n0),8);return aE(n.b,r.b)}function IS(e,t,n){var r,i,a=t>>5;return i=t&31,r=uv(um(e.n[n][a],nm(cm(i,1))),3),r}function eYe(e,t,n){var r,i,a=e.a.length-1;for(i=e.b,r=0;r0):(!e.c&&(e.c=Q_(LC(e.f))),e.c).e}function fYe(e,t){t?e.B??(e.B=e.D,e.D=null):e.B!=null&&(e.D=e.B,e.B=null)}function pYe(e,t){return ow(),e==kJ&&t==MJ||e==MJ&&t==kJ||e==jJ&&t==AJ||e==AJ&&t==jJ}function mYe(e,t){return ow(),e==kJ&&t==AJ||e==kJ&&t==jJ||e==MJ&&t==jJ||e==MJ&&t==AJ}function hYe(e,t){return uu(),fS(fL),r.Math.abs(0-t)<=fL||t==0?0:e/t}function gYe(e,t){return D(N(Ju(MT(gg(new Mp(null,new cv(e.c.b,16)),new Zpe(e)),t))))}function $S(e,t){return D(N(Ju(MT(gg(new Mp(null,new cv(e.c.b,16)),new Xpe(e)),t))))}function _Ye(){return uM(),U(O($Z,1),Z,259,0,[WZ,KZ,qZ,JZ,YZ,XZ,QZ,UZ,GZ,ZZ])}function vYe(){return FM(),U(O(WMt,1),Z,243,0,[Y0,q0,J0,VMt,HMt,BMt,UMt,X0,G0,K0])}function yYe(e,t){var n;t.Ug(`General Compactor`,1),n=$1e(P(J(e,(PA(),A4)),393)),n.Cg(e)}function bYe(e,t){var n=P(J(e,(PA(),j4)),17),r=P(J(t,j4),17);return _u(n.a,r.a)}function eC(e,t,n){var r,i;for(i=dO(e,0);i.b!=i.d.c;)r=P(Lv(i),8),r.a+=t,r.b+=n;return e}function tC(e,t,n){var r;for(r=e.b[n&e.f];r;r=r.b)if(n==r.a&&zh(t,r.g))return r;return null}function nC(e,t,n){var r;for(r=e.c[n&e.f];r;r=r.d)if(n==r.f&&zh(t,r.i))return r;return null}function xYe(e,t,n){var r=0,i,a;for(i=0;i>>31;r!=0&&(e[n]=r)}function rC(e,t,n,r,i,a){var o;this.c=e,o=new T,t3e(e,o,t,e.b,n,r,i,a),this.a=new bv(o,0)}function SYe(){this.c=new Ya(0),this.b=new Ya(PV),this.d=new Ya(txt),this.a=new Ya(RL)}function iC(e,t,n,r,i,a,o){so.call(this,e,t),this.d=n,this.e=r,this.c=i,this.b=a,this.a=Oy(o)}function aC(e,t,n,r,i,a,o,s,c,l,u,d,f){return ftt(e,t,n,r,i,a,o,s,c,l,u,d,f),mE(e,!1),e}function CYe(e){return e.b.c.i.k==(DA(),GJ)?P(K(e.b.c.i,(Y(),WQ)),12):e.b.c}function wYe(e){return e.b.d.i.k==(DA(),GJ)?P(K(e.b.d.i,(Y(),WQ)),12):e.b.d}function TYe(e){var t=Ov(e);return ol(t.a,0)?(So(),So(),sEt):(So(),new _Ee(t.b))}function oC(e){var t=LBe(e);return ol(t.a,0)?(xo(),xo(),sK):(xo(),new gd(t.b))}function sC(e){var t=LBe(e);return ol(t.a,0)?(xo(),xo(),sK):(xo(),new gd(t.c))}function EYe(e){switch(e.g){case 2:return nP(),g5;case 4:return nP(),X8;default:return e}}function DYe(e){switch(e.g){case 1:return nP(),m5;case 3:return nP(),Z8;default:return e}}function OYe(e){switch(e.g){case 0:return new Doe;case 1:return new Ooe;default:return null}}function cC(){cC=C,dX=new Wd(`edgelabelcenterednessanalysis.includelabel`,(rd(),vG))}function lC(){lC=C,kNt=HD(pCe(vp(vp(new Zh,(vA(),bJ),(yP(),KY)),xJ,IY),SJ),GY)}function kYe(){kYe=C,NNt=HD(pCe(vp(vp(new Zh,(vA(),bJ),(yP(),KY)),xJ,IY),SJ),GY)}function uC(){uC=C,n9=new p_e,r9=U(O(w7,1),qU,179,0,[]),eHt=U(O(M7,1),Cwt,62,0,[])}function dC(){dC=C,aY=new xxe(`TO_INTERNAL_LTR`,0),iY=new xxe(`TO_INPUT_DIRECTION`,1)}function fC(){fC=C,tY=new Tee,$J=new Eee,eY=new Dee,QJ=new Oee,nY=new kee,rY=new Aee}function AYe(e,t){t.Ug(Mbt,1),KE(kbe(new ar((Po(),new Tg(e,!1,!1,new Wt))))),t.Vg()}function jYe(e,t,n){n.Ug(`DFS Treeifying phase`,1),k0e(e,t),Yot(e,t),e.a=null,e.b=null,n.Vg()}function pC(e,t){return rd(),rl(e)?zUe(e,kd(t)):al(e)?dm(e,N(t)):il(e)?UNe(e,Od(t)):e.Fd(t)}function mC(e,t){var n,r;for(Gh(t),r=t.vc().Kc();r.Ob();)n=P(r.Pb(),44),e.zc(n.ld(),n.md())}function MYe(e,t,n){var r;for(r=n.Kc();r.Ob();)if(!Kv(e,t,r.Pb()))return!1;return!0}function NYe(e,t,n,r,i){var a;return n&&(a=eD(t.Dh(),e.c),i=n.Rh(t,-1-(a==-1?r:a),null,i)),i}function PYe(e,t,n,r,i){var a;return n&&(a=eD(t.Dh(),e.c),i=n.Th(t,-1-(a==-1?r:a),null,i)),i}function FYe(e){var t;if(e.b==-2){if(e.e==0)t=-1;else for(t=0;e.a[t]==0;t++);e.b=t}return e.b}function IYe(e){if(Gh(e),e.length==0)throw E(new aa(`Zero length BigInteger`));uut(this,e)}function hC(e){this.i=e.gc(),this.i>0&&(this.g=this.aj(this.i+(this.i/8|0)+1),e.Qc(this.g))}function LYe(e,t,n){this.g=e,this.d=t,this.e=n,this.a=new T,Utt(this),Vg(),hu(this.a,null)}function gC(e,t){t.q=e,e.d=r.Math.max(e.d,t.r),e.b+=t.d+(e.a.c.length==0?0:e.c),M(e.a,t)}function _C(e,t){var n,r,i=e.c,a;return n=e.c+e.b,a=e.d,r=e.d+e.a,t.a>i&&t.aa&&t.bi?n=i:sv(t,n+1),e.a=p_(e.a,0,t)+(``+r)+Ch(e.a,n)}function QYe(e,t){e.a=yE(e.a,1),e.c=r.Math.min(e.c,t),e.b=r.Math.max(e.b,t),e.d=yE(e.d,t)}function $Ye(e,t){return t1||e.Ob())return++e.a,e.g=0,t=e.i,e.Ob(),t;throw E(new Hr)}function fXe(e){switch(e.a.g){case 1:return new Yxe;case 3:return new P3e;default:return new Nue}}function pXe(e,t){switch(t){case 1:return!!e.n&&e.n.i!=0;case 2:return e.k!=null}return yBe(e,t)}function LC(e){return iI>22),i=e.h+t.h+(r>>22);return vu(n&QF,r&QF,i&$F)}function NXe(e,t){var n=e.l-t.l,r=e.m-t.m+(n>>22),i=e.h-t.h+(r>>22);return vu(n&QF,r&QF,i&$F)}function PXe(e){var t,n;for(Wgt(e),n=new w(e.d);n.ar)throw E(new lf(t,r));return e.Si()&&(n=uRe(e,n)),e.Ei(t,n)}function pw(e,t,n,r,i){var a,o;for(o=n;o<=i;o++)for(a=t;a<=r;a++)sk(e,a,o)||EM(e,a,o,!0,!1)}function uZe(e){fM();var t,n=V(K3,X,8,2,0,1),r=0;for(t=0;t<2;t++)r+=.5,n[t]=Y4e(r,e);return n}function mw(e){var t=~e.l+1&QF,n=~e.m+ +(t==0)&QF;return vu(t,n,~e.h+ +(t==0&&n==0)&$F)}function dZe(e){var t;if(e<0)return xF;if(e==0)return 0;for(t=mF;(t&e)==0;t>>=1);return t}function hw(e,t,n){return e>=128?!1:cl(e<64?uv(cm(1,e),n):uv(cm(1,e-64),t),0)}function gw(e,t,n){return n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n)),e}function W(e,t,n){return n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n)),e}function fZe(e){var t,n=new Py;return VC(n,e),W(n,(jS(),iJ),e),t=new Dr,gft(e,n,t),$ht(e,n,t),n}function pZe(e){var t=e.t-e.k[e.o.p]*e.d+e.j[e.o.p]>e.f,n=e.u+e.e[e.o.p]*e.d>e.f*e.s*e.d;return t||n}function mZe(e,t){var n=!1,r=e.a[t].length,i,a;for(a=0;a=0,`Negative initial capacity`),$f(t>=0,`Non-positive load factor`),Pm(this)}function CZe(e,t,n,r,i){var a,o=e.length;if(a=n.length,t<0||r<0||i<0||t+i>o||r+i>a)throw E(new bge)}function wZe(e,t){Vg();var n,r,i,a,o=!1;for(r=t,i=0,a=r.length;i1||t>=0&&e.b<3)}function ww(e){var t=~e.l+1&QF,n=~e.m+ +(t==0)&QF,r=~e.h+ +(t==0&&n==0)&$F;e.l=t,e.m=n,e.h=r}function IZe(e){Vg();var t,n,r=1;for(n=e.Kc();n.Ob();)t=n.Pb(),r=31*r+(t==null?0:US(t)),r|=0;return r}function LZe(e,t,n,r,i){var a=$rt(e,t);return n&&ww(a),i&&(e=s3e(e,t),mG=r?mw(e):vu(e.l,e.m,e.h)),a}function RZe(e,t,n){e.g=WA(e,t,(nP(),X8),e.b),e.d=WA(e,n,X8,e.b),e.g.c!=0&&e.d.c!=0&&f9e(e)}function zZe(e,t,n){e.g=WA(e,t,(nP(),g5),e.j),e.d=WA(e,n,g5,e.j),e.g.c!=0&&e.d.c!=0&&f9e(e)}function BZe(e,t){switch(t){case 7:return!!e.e&&e.e.i!=0;case 8:return!!e.d&&e.d.i!=0}return JE(e,t)}function VZe(e,t){switch(t.g){case 0:j(e.b,641)||(e.b=new XYe);break;case 1:j(e.b,642)||(e.b=new aMe)}}function HZe(e){switch(e.g){case 0:return new Poe;default:throw E(new Fi(fH+(e.f==null?``+e.g:e.f)))}}function UZe(e){switch(e.g){case 0:return new Moe;default:throw E(new Fi(fH+(e.f==null?``+e.g:e.f)))}}function WZe(e,t,n){return!Xa(hg(new Mp(null,new cv(e.c,16)),new rr(new bSe(t,n)))).Bd((wo(),SK))}function GZe(e,t){return Ou(cO(P(K(t,(rN(),c4)),88)),new k(e.c.e.a-e.b.e.a,e.c.e.b-e.b.e.b))<=0}function KZe(e,t){for(;e.g==null&&!e.c?lRe(e):e.g==null||e.i!=0&&P(e.g[e.i-1],51).Ob();)KSe(t,Pj(e))}function Tw(e){var t,n;for(n=new w(e.a.b);n.ar)}function ZZe(e){return M(e.c,(lw(),ORt)),Ax(e.a,D(N(hO((aD(),O0)))))?new Sse:new nhe(e)}function QZe(e){for(;!e.d||!e.d.Ob();)if(e.b&&!qi(e.b))e.d=P(Fm(e.b),51);else return null;return e.d}function $Ze(e){switch(e.g){case 1:return txt;default:case 2:return 0;case 3:return RL;case 4:return PV}}function eQe(){xP();var e;return JHt||(e=uEe(oP(`M`,!0)),e=Rp(oP(`M`,!1),e),JHt=e,JHt)}function Mw(){Mw=C,I5=new qc(`ELK`,0),QBt=new qc(`JSON`,1),ZBt=new qc(`DOT`,2),$Bt=new qc(`SVG`,3)}function Nw(){Nw=C,c2=new ac(`STACKED`,0),o2=new ac(`REVERSE_STACKED`,1),s2=new ac(`SEQUENCED`,2)}function Pw(){Pw=C,PPt=new mc(wR,0),B2=new mc(`MIDDLE_TO_MIDDLE`,1),z2=new mc(`AVOID_OVERLAP`,2)}function Fw(){Fw=C,vX=new cne,yX=new lne,VOt=new one,BOt=new une,zOt=new sne,_X=(Gh(zOt),new le)}function Iw(){Iw=C,vBt=new iu(15),_Bt=new ou((vP(),A6),vBt),h8=V6,pBt=rzt,mBt=w6,gBt=E6,hBt=T6}function Lw(e,t){var n,r,i,a,o;for(r=t,i=0,a=r.length;i=e.b.c.length||(sQe(e,2*t+1),n=2*t+2,n0&&(t.Cd(n),n.i&&n1e(n))}function lQe(e,t,n){var r;for(r=n-1;r>=0&&e[r]===t[r];r--);return r<0?0:rs(uv(e[r],_I),uv(t[r],_I))?-1:1}function uQe(e,t,n){var r,i;this.g=e,this.c=t,this.a=this,this.d=this,i=UJe(n),r=V(PTt,fF,227,i,0,1),this.b=r}function Vw(e,t,n,r,i){var a,o;for(o=n;o<=i;o++)for(a=t;a<=r;a++)if(sk(e,a,o))return!0;return!1}function dQe(e,t){var n,r;for(r=e.Zb().Cc().Kc();r.Ob();)if(n=P(r.Pb(),16),n.Hc(t))return!0;return!1}function fQe(e,t,n){var r,i,a,o;for(Gh(n),o=!1,a=e.fd(t),i=n.Kc();i.Ob();)r=i.Pb(),a.Rb(r),o=!0;return o}function Hw(e,t){var n,r=P(NC(e.a,4),129);return n=V(g7,FU,424,t,0,1),r!=null&&tN(r,0,n,0,r.length),n}function pQe(e,t){var n=new yM(!!(e.f&256),e.i,e.a,e.d,!!(e.f&16),e.j,e.g,t);return e.e??(n.c=e),n}function mQe(e,t){var n;return e===t?!0:j(t,85)?(n=P(t,85),eet(am(e),n.vc())):!1}function hQe(e,t,n){var r,i;for(i=n.Kc();i.Ob();)if(r=P(i.Pb(),44),e.Be(t,r.md()))return!0;return!1}function gQe(e,t,n){return e.d[t.p][n.p]||(p4e(e,t,n),e.d[t.p][n.p]=!0,e.d[n.p][t.p]=!0),e.a[t.p][n.p]}function _Qe(e,t){var n;return!e||e==t||!yd(t,(Y(),NQ))?!1:(n=P(K(t,(Y(),NQ)),10),n!=e)}function Uw(e){switch(e.i){case 2:return!0;case 1:return!1;case-1:++e.c;default:return e.$l()}}function vQe(e){switch(e.i){case-2:return!0;case-1:return!1;case 1:--e.c;default:return e._l()}}function yQe(e){yRe.call(this,`The given string does not match the expected format for individual spacings.`,e)}function bQe(e,t){var n;t.Ug(`Min Size Preprocessing`,1),n=Zet(e),OO(e,(xM(),Y4),n.a),OO(e,K4,n.b),t.Vg()}function xQe(e){var t=0,n,r=V(K3,X,8,e.b,0,1);for(n=dO(e,0);n.b!=n.d.c;)r[t++]=P(Lv(n),8);return r}function Ww(e,t,n){var r=new vo,i,a;for(a=dO(n,0);a.b!=a.d.c;)i=P(Lv(a),8),up(r,new Vl(i));fQe(e,t,r)}function SQe(e,t){var n=yE(e,t);return rs(fv(e,t),0)|sl(fv(e,n),0)?n:yE(tF,fv(um(n,63),1))}function CQe(e,t){var n=P(e.d.Bc(t),16),r;return n?(r=e.e.hc(),r.Gc(n),e.e.d-=n.gc(),n.$b(),r):null}function wQe(e){var t=e.a.c.length;if(t>0)return gm(t-1,e.a.c.length),Ay(e.a,t-1);throw E(new Sge)}function TQe(e,t,n){if(e>t)throw E(new Fi(BI+e+vyt+t));if(e<0||t>n)throw E(new ia(BI+e+VI+t+MI+n))}function Gw(e,t){e.D==null&&e.B!=null&&(e.D=e.B,e.B=null),wS(e,t==null?null:(Gh(t),t)),e.C&&e.hl(null)}function EQe(e,t){var n=hO((aD(),O0))!=null&&t.Sg()!=null?D(N(t.Sg()))/D(N(hO(O0))):1;Qh(e.b,t,n)}function DQe(e,t){var n,r=e.c[t];if(r!=0)for(e.c[t]=0,e.d-=r,n=t+1;nNV?e-n>NV:n-e>NV}function ZQe(e,t){var n;for(n=0;ni&&(Z8e(t.q,i),r=n!=t.q.d)),r}function e$e(e,t){var n,i,a,o,s,c,l=t.i,u=t.j;return i=e.f,a=i.i,o=i.j,s=l-a,c=u-o,n=r.Math.sqrt(s*s+c*c),n}function t$e(e,t){var n,r=KD(e);return r||(!_Vt&&(_Vt=new Jse),n=(NN(),Vit(t)),r=new qhe(n),tb(r.El(),e)),r}function sT(e,t){var n=P(e.c.Bc(t),16),r;return n?(r=e.hc(),r.Gc(n),e.d-=n.gc(),n.$b(),e.mc(r)):e.jc()}function n$e(e,t){var n,r=Lj(e.d,1)!=0;for(n=!0;n;)n=!1,n=t.c.mg(t.e,r),n|=$j(e,t,r,!1),r=!r;WS(e)}function r$e(e,t,n,r){var i,a;e.a=t,a=+!r,e.f=(i=new uet(e.c,e.a,n,a),new Hct(n,e.a,i,e.e,e.b,e.c==(sS(),g2)))}function cT(e){var t;return jd(e.a!=e.b),t=e.d.a[e.a],lDe(e.b==e.d.c&&t!=null),e.c=e.a,e.a=e.a+1&e.d.a.length-1,t}function i$e(e){var t;if(e.c!=0)return e.c;for(t=0;t=e.c.b:e.a<=e.c.b))throw E(new Hr);return t=e.a,e.a+=e.c.c,++e.b,G(t)}function lT(e){var t=new Dwe(e.a);return VC(t,e),W(t,(Y(),WQ),e),t.o.a=e.g,t.o.b=e.f,t.n.a=e.i,t.n.b=e.j,t}function uT(e){return(nP(),c5).Hc(e.j)?D(N(K(e,(Y(),c$)))):Sw(U(O(K3,1),X,8,0,[e.i.n,e.n,e.a])).b}function o$e(e){var t=Wl(ONt);return P(K(e,(Y(),OQ)),21).Hc((uM(),YZ))&&vp(t,(vA(),bJ),(yP(),eX)),t}function s$e(e){var t,n,r,i=new Jr;for(r=new w(e);r.a=0?t:-t;r>0;)r%2==0?(n*=n,r=r/2|0):(i*=n,--r);return t<0?1/i:i}function f$e(e,t){var n,r,i=1;for(n=e,r=t>=0?t:-t;r>0;)r%2==0?(n*=n,r=r/2|0):(i*=n,--r);return t<0?1/i:i}function pT(e,t){var n,r,i,a=(i=e?KD(e):null,btt((r=t,i&&i.Gl(),r)));return a==t&&(n=KD(e),n&&n.Gl()),a}function p$e(e,t,n){var r,i=e.f;return e.f=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,0,i,t),n?n.nj(r):n=r),n}function m$e(e,t,n){var r,i=e.b;return e.b=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,3,i,t),n?n.nj(r):n=r),n}function mT(e,t,n){var r,i=e.a;return e.a=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,1,i,t),n?n.nj(r):n=r),n}function h$e(e){var t,n,r,i;if(e!=null){for(n=0;n=r||t-129&&e<128?(iMe(),t=e+128,n=OG[t],!n&&(n=OG[t]=new jn(e)),n):new jn(e)}function xT(e){var t,n;return e>-129&&e<128?(GMe(),t=e+128,n=FG[t],!n&&(n=FG[t]=new Nn(e)),n):new Nn(e)}function C$e(e,t){var n;e.a.c.length>0&&(n=P(Ep(e.a,e.a.c.length-1),579),tQe(n,t))||M(e.a,new nUe(t))}function w$e(e){Lf();var t=e.d.c-e.e.c,n=P(e.g,154);Dx(n.b,new Rpe(t)),Dx(n.c,new zpe(t)),ly(n.i,new Bpe(t))}function T$e(e){var t=new ta;return t.a+=`VerticalSegment `,hl(t,e.e),t.a+=` `,gl(t,_Te(new Xi,new w(e.k))),t.a}function ST(e,t){var n=0,r,i;for(i=SE(e,t).Kc();i.Ob();)r=P(i.Pb(),12),n+=K(r,(Y(),QQ))==null?0:1;return n}function CT(e,t,n){var r=0,i,a;for(a=dO(e,0);a.b!=a.d.c&&(i=D(N(Lv(a))),!(i>n));)i>=t&&++r;return r}function E$e(e,t){ph(e);try{return e._b(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function wT(e,t){ph(e);try{return e.Hc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function D$e(e,t){ph(e);try{return e.Mc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function TT(e,t){ph(e);try{return e.xc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return null;throw E(e)}}function O$e(e,t){ph(e);try{return e.Bc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return null;throw E(e)}}function ET(e,t){switch(t.g){case 2:case 1:return SE(e,t);case 3:case 4:return UE(SE(e,t))}return Vg(),Vg(),QG}function DT(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (name: `,pl(t,e.zb),t.a+=`)`,t.a)}function k$e(e){var t=P(ix(e.c.c,``),233);return t||(t=new ev(Ca(Sa(new Qt,``),`Other`)),oO(e.c.c,``,t)),t}function OT(e,t,n){var r,i=e.sb;return e.sb=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,4,i,t),n?n.nj(r):n=r),n}function kT(e,t,n){var r,i=e.r;return e.r=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,8,i,e.r),n?n.nj(r):n=r),n}function A$e(e,t,n){var r=new Hb(e.e,4,13,(i=t.c,i||(CP(),q7)),null,NO(e,t),!1),i;return n?n.nj(r):n=r,n}function j$e(e,t,n){var r=new Hb(e.e,3,13,null,(i=t.c,i||(CP(),q7)),NO(e,t),!1),i;return n?n.nj(r):n=r,n}function AT(e,t){var n=P(t,691),r=n.el();return!r&&n.fl(r=j(t,90)?new QSe(e,P(t,29)):new dBe(e,P(t,156))),r}function jT(e,t,n){var r;e._i(e.i+1),r=e.Zi(t,n),t!=e.i&&tN(e.g,t,e.g,t+1,e.i-t),Sh(e.g,t,r),++e.i,e.Mi(t,n),e.Ni()}function M$e(e,t){var n;return t.a&&(n=t.a.a.length,e.a?gl(e.a,e.b):e.a=new Gu(e.d),TBe(e.a,t.a,t.d.length,n)),e}function N$e(e,t){var n;e.c=t,e.a=a0e(t),e.a<54&&(e.f=(n=t.d>1?CBe(t.a[0],t.a[1]):CBe(t.a[0],0),Dv(t.e>0?n:kb(n))))}function MT(e,t){var n=new Re;return e.a.Bd(n)?(Bu(),new wi(Gh(nKe(e,n.a,t)))):(Hh(e),Bu(),Bu(),oK)}function P$e(e,t){var n;e.c.length!=0&&(n=P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199),zl(n,new mte),Unt(n,t))}function F$e(e,t){var n;e.c.length!=0&&(n=P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199),zl(n,new hte),Unt(n,t))}function NT(e,t){return rl(e)?ff(e,t):al(e)?wOe(e,t):il(e)?(Gh(e),A(e)===A(t)):RNe(e)?e.Fb(t):Wp(e)?vCe(e,t):Oze(e,t)}function PT(e,t,n){if(t<0)Qtt(e,n);else{if(!n.rk())throw E(new Fi(HH+n.xe()+UH));P(n,69).wk().Ek(e,e.hi(),t)}}function I$e(e,t,n){if(e<0||t>n)throw E(new Mi(BI+e+VI+t+`, size: `+n));if(e>t)throw E(new Fi(BI+e+vyt+t))}function L$e(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (source: `,pl(t,e.d),t.a+=`)`,t.a)}function R$e(e){return e>=65&&e<=70?e-65+10:e>=97&&e<=102?e-97+10:e>=48&&e<=57?e-48:0}function z$e(e){SP();var t,n,r,i;for(n=sO(),r=0,i=n.length;r=0?yD(e):Xm(yD(kb(e))))}function W$e(e,t,n,r,i,a){this.e=new T,this.f=(uS(),i2),M(this.e,e),this.d=t,this.a=n,this.b=r,this.f=i,this.c=a}function G$e(e,t,n){e.n=Dp(Y9,[X,dI],[376,28],14,[n,C_(r.Math.ceil(t/32))],2),e.o=t,e.p=n,e.j=t-1>>1,e.k=n-1>>1}function K$e(e){return e-=e>>1&1431655765,e=(e>>2&858993459)+(e&858993459),e=(e>>4)+e&252645135,e+=e>>8,e+=e>>16,e&63}function q$e(e,t){var n,r;for(r=new Lu(e);r.e!=r.i.gc();)if(n=P(gO(r),142),A(t)===A(n))return!0;return!1}function J$e(e,t,n){var r,i,a=(i=Mj(e.b,t),i);return a&&(r=P(jN(Lb(e,a),``),29),r)?Hit(e,r,t,n):null}function UT(e,t,n){var r,i,a=(i=Mj(e.b,t),i);return a&&(r=P(jN(Lb(e,a),``),29),r)?Uit(e,r,t,n):null}function Y$e(e,t){var n=Bx(e.i,t);if(n==null)throw E(new Vi(`Node did not exist in input.`));return yC(t,n),null}function X$e(e,t){var n=Qj(e,t);if(j(n,331))return P(n,35);throw E(new Fi(HH+t+`' is not a valid attribute`))}function WT(e,t,n){var r=e.gc();if(t>r)throw E(new lf(t,r));if(e.Si()&&e.Hc(n))throw E(new Fi(vU));e.Gi(t,n)}function Z$e(e,t){t.Ug(`Sort end labels`,1),To(hg(ox(new Mp(null,new cv(e.b,16)),new Qee),new $ee),new ete),t.Vg()}function GT(){GT=C,r8=new jc(dL,0),n8=new jc(lL,1),t8=new jc(cL,2),e8=new jc(hL,3),i8=new jc(`UP`,4)}function KT(){KT=C,m3=new Tc(`P1_STRUCTURE`,0),h3=new Tc(`P2_PROCESSING_ORDER`,1),g3=new Tc(`P3_EXECUTION`,2)}function Q$e(){Q$e=C,jFt=HD(HD(Go(HD(HD(Go(vp(new Zh,(Ok(),P2),(LM(),R2)),F2),OPt),APt),I2),wPt),jPt)}function $$e(e){switch(P(K(e,(Y(),MQ)),311).g){case 1:W(e,MQ,(Zb(),iQ));break;case 2:W(e,MQ,(Zb(),oQ))}}function e1e(e){switch(e){case 0:return new a_e;case 1:return new r_e;case 2:return new i_e;default:throw E(new Lr)}}function t1e(e){switch(e.g){case 2:return n8;case 1:return t8;case 4:return e8;case 3:return i8;default:return r8}}function qT(e,t){switch(e.b.g){case 0:case 1:return t;case 2:case 3:return new wg(t.d,0,t.a,t.b);default:return null}}function JT(e){switch(e.g){case 1:return g5;case 2:return Z8;case 3:return X8;case 4:return m5;default:return h5}}function YT(e){switch(e.g){case 1:return m5;case 2:return g5;case 3:return Z8;case 4:return X8;default:return h5}}function XT(e){switch(e.g){case 1:return X8;case 2:return m5;case 3:return g5;case 4:return Z8;default:return h5}}function ZT(e,t,n,r){switch(t){case 1:return!e.n&&(e.n=new F(Q5,e,1,7)),e.n;case 2:return e.k}return W3e(e,t,n,r)}function QT(e,t,n){var r,i;return e.Pj()?(i=e.Qj(),r=dj(e,t,n),e.Jj(e.Ij(7,G(n),r,t,i)),r):dj(e,t,n)}function $T(e,t){var n,r,i;e.d==null?(++e.e,--e.f):(i=t.ld(),n=t.Bi(),r=(n&AP)%e.d.length,nWe(e,r,Zit(e,r,n,i)))}function eE(e,t){var n=(e.Bb&pF)!=0;t?e.Bb|=pF:e.Bb&=-1025,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,10,n,t))}function tE(e,t){var n=(e.Bb&uI)!=0;t?e.Bb|=uI:e.Bb&=-4097,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,12,n,t))}function nE(e,t){var n=(e.Bb&RU)!=0;t?e.Bb|=RU:e.Bb&=-8193,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,15,n,t))}function rE(e,t){var n=(e.Bb&zU)!=0;t?e.Bb|=zU:e.Bb&=-2049,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,11,n,t))}function n1e(e){var t;e.g&&(t=e.c.kg()?e.f:e.a,Ost(t.a,e.o,!0),Ost(t.a,e.o,!1),W(e.o,(mP(),Q1),(rA(),L8)))}function r1e(e){var t;if(!e.a)throw E(new Ii(`Cannot offset an unassigned cut.`));t=e.c-e.b,e.b+=t,NIe(e,t),MIe(e,t)}function i1e(e,t){var n=xh(e.k,t);if(n==null)throw E(new Vi(`Port did not exist in input.`));return yC(t,n),null}function a1e(e){var t,n;for(n=Git(Mx(e)).Kc();n.Ob();)if(t=kd(n.Pb()),JM(e,t))return _He((Zbe(),VVt),t);return null}function o1e(e){var t,n;for(n=e.p.a.ec().Kc();n.Ob();)if(t=P(n.Pb(),218),t.f&&e.b[t.c]<-1e-10)return t;return null}function s1e(e){var t,n=jh(new ta,91);for(t=!0;e.Ob();)t||(n.a+=PP),t=!1,hl(n,e.Pb());return(n.a+=`]`,n).a}function c1e(e){var t=new T,n,r;for(r=new w(e.b);r.at?1:e==t?e==0?aE(1/e,1/t):0:isNaN(e)?+!isNaN(t):-1}function u1e(e){var t=e.a[e.c-1&e.a.length-1];return t==null?null:(e.c=e.c-1&e.a.length-1,Sh(e.a,e.c,null),t)}function d1e(e){var t,n,r=0;for(n=e.length,t=0;t=1?n8:e8):n}function g1e(e){switch(P(K(e,(mP(),S1)),223).g){case 1:return new zre;case 3:return new Wre;default:return new Rre}}function lE(e){if(e.c)lE(e.c);else if(e.d)throw E(new Ii(`Stream already terminated, can't be modified or used`))}function uE(e,t,n){var r=e.a.get(t);return e.a.set(t,n===void 0?null:n),r===void 0?(++e.c,++e.b.g):++e.d,r}function _1e(e,t,n){var r,i;for(i=e.a.ec().Kc();i.Ob();)if(r=P(i.Pb(),10),$C(n,P(Ep(t,r.p),16)))return r;return null}function dE(e,t,n){var r=0;return t&&(Jl(e.a)?r+=t.f.a/2:r+=t.f.b/2),n&&(Jl(e.a)?r+=n.f.a/2:r+=n.f.b/2),r}function v1e(e,t,n){var r=n;!r&&(r=Qje(new di,0)),r.Ug(_bt,2),v4e(e.b,t,r.eh(1)),fmt(e,t,r.eh(1)),u_t(t,r.eh(1)),r.Vg()}function fE(e,t,n){var r=(Ia(),i=new tn,i),i;return Xx(r,t),Vx(r,n),e&&tb((!e.a&&(e.a=new ju(z5,e,5)),e.a),r),r}function pE(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (identifier: `,pl(t,e.k),t.a+=`)`,t.a)}function mE(e,t){var n=(e.Bb&GH)!=0;t?e.Bb|=GH:e.Bb&=-32769,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,18,n,t))}function hE(e,t){var n=(e.Bb&GH)!=0;t?e.Bb|=GH:e.Bb&=-32769,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,18,n,t))}function gE(e,t){var n=(e.Bb&ZP)!=0;t?e.Bb|=ZP:e.Bb&=-16385,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,16,n,t))}function _E(e,t){var n=(e.Bb&pI)!=0;t?e.Bb|=pI:e.Bb&=-65537,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,20,n,t))}function vE(e){var t=V(K9,EF,28,2,15,1);return e-=pI,t[0]=(e>>10)+mI&OF,t[1]=(e&1023)+56320&OF,ND(t,0,t.length)}function y1e(e){var t=OA(e);return t>34028234663852886e22?cI:t<-34028234663852886e22?lI:t}function yE(e,t){var n;return Il(e)&&Il(t)&&(n=e+t,iI`+hv(t.c):`e_`+US(t),e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))}function S1e(e,t){return ff(t.b&&t.c?hv(t.b)+`->`+hv(t.c):`e_`+US(t),e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))}function CE(e,t){return uu(),fS(bF),r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t))}function wE(){wE=C,f8=new Nc(dL,0),u8=new Nc(`POLYLINE`,1),l8=new Nc(`ORTHOGONAL`,2),d8=new Nc(`SPLINES`,3)}function TE(){TE=C,IIt=new Sc(`ASPECT_RATIO_DRIVEN`,0),Q4=new Sc(`MAX_SCALE_DRIVEN`,1),FIt=new Sc(`AREA_DRIVEN`,2)}function C1e(e,t,n){var r;try{MZe(e,t,n)}catch(e){throw e=ew(e),j(e,606)?(r=e,E(new EUe(r))):E(e)}return t}function w1e(e){var t,n,r;for(n=0,r=e.length;nt&&r.Ne(e[a-1],e[a])>0;--a)o=e[a],Sh(e,a,e[a-1]),Sh(e,a-1,o)}function jE(e,t){var n=t.f,r,i,a,o;if(oO(e.c.d,n,t),t.g!=null)for(i=t.g,a=0,o=i.length;at){OBe(n);break}}Zm(n,t)}function A1e(e,t){var n,i=D(N(gD(Ev(t),(mP(),c0))));n=r.Math.max(0,i/2-.5),zk(t,n,1),M(e,new Oxe(t,n))}function j1e(e,t,n){var r;n.Ug(`Straight Line Edge Routing`,1),n.dh(t,mxt),r=P(J(t,(Pd(),y4)),27),ppt(e,r),n.dh(t,YV)}function ME(e,t){e.n.c.length==0&&M(e.n,new w_(e.s,e.t,e.i)),M(e.b,t),q4e(P(Ep(e.n,e.n.c.length-1),209),t),tft(e,t)}function NE(e){var t;this.a=(t=P(e.e&&e.e(),9),new xf(t,P(Yd(t,t.length),9),0)),this.b=V(WW,FP,1,this.a.a.length,5,1)}function PE(e){var t;return Array.isArray(e)&&e.Tm===ne?Ha($w(e))+`@`+(t=US(e)>>>0,t.toString(16)):e.toString()}function M1e(e,t){return e.h==eI&&e.m==0&&e.l==0?(t&&(mG=vu(0,0,0)),xCe(($b(),gG))):(t&&(mG=vu(e.l,e.m,e.h)),vu(0,0,0))}function N1e(e,t){switch(t.g){case 2:return e.b;case 1:return e.c;case 4:return e.d;case 3:return e.a;default:return!1}}function P1e(e,t){switch(t.g){case 2:return e.b;case 1:return e.c;case 4:return e.d;case 3:return e.a;default:return!1}}function FE(e,t,n,r){switch(t){case 3:return e.f;case 4:return e.g;case 5:return e.i;case 6:return e.j}return ZT(e,t,n,r)}function IE(e,t){if(t==e.d)return e.e;if(t==e.e)return e.d;throw E(new Fi(`Node `+t+` not part of edge `+e))}function F1e(e,t){var n=Qj(e.Dh(),t);if(j(n,102))return P(n,19);throw E(new Fi(HH+t+`' is not a valid reference`))}function LE(e,t,n,r){if(t<0)Pat(e,n,r);else{if(!n.rk())throw E(new Fi(HH+n.xe()+UH));P(n,69).wk().Ck(e,e.hi(),t,r)}}function RE(e){var t;if(e.b){if(RE(e.b),e.b.d!=e.c)throw E(new Vr)}else e.d.dc()&&(t=P(e.f.c.xc(e.e),16),t&&(e.d=t))}function I1e(e){Rd();var t=e.o.b,n,r,i;for(r=P(P(Dy(e.r,(nP(),m5)),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i=n.e,i.b+=t}function L1e(e){var t,n,r;for(this.a=new Rl,r=new w(e);r.a=i)return t.c+n;return t.c+t.b.gc()}function z1e(e,t){Nd();var n,r=LGe(e),i=t,a;for(bb(r,0,r.length,i),n=0;n0&&(r+=i,++n);return n>1&&(r+=e.d*(n-1)),r}function V1e(e){var t,n,r,i,a=m7e(e);return n=eo(e.c),r=!n,r&&(i=new Tn,hx(a,`knownLayouters`,i),t=new Mhe(i),ly(e.c,t)),a}function HE(e){var t,n,r=new $i;for(r.a+=`[`,t=0,n=e.gc();t0&&(sv(t-1,e.length),e.charCodeAt(t-1)==58)&&!zE(e,y7,b7))}function WE(e,t){var n;return A(e)===A(t)?!0:j(t,92)?(n=P(t,92),e.e==n.e&&e.d==n.d&&xHe(e,n.a)):!1}function GE(e){switch(nP(),e.g){case 4:return Z8;case 1:return X8;case 3:return m5;case 2:return g5;default:return h5}}function G1e(e){var t,n;if(e.b)return e.b;for(n=_K?null:e.d;n;){if(t=_K?null:n.b,t)return t;n=_K?null:n.d}return Co(),hK}function KE(e){var t,n,r=D(N(e.a.of((vP(),q6))));for(n=new w(e.a.Sf());n.a>5,t=e&31,r=V(q9,HF,28,n+1,15,1),r[n]=1<3;)i*=10,--a;e=(e+(i>>1))/i|0}return r.i=e,!0}function eD(e,t){var n=(e.i??aN(e),e.i),r=t.Lj(),i;if(r!=-1){for(i=n.length;r=0;--r)for(t=n[r],i=0;i>1,this.k=t-1>>1}function f0e(e){gb(),P(e.of((vP(),D6)),181).Hc((UM(),A5))&&(P(e.of(z6),181).Fc((rj(),J8)),P(e.of(D6),181).Mc(A5))}function p0e(e){var t=e.d==(GA(),WX),n=x5e(e);t&&!n||!t&&n?W(e.a,(mP(),J$),(RO(),Z3)):W(e.a,(mP(),J$),(RO(),X3))}function aD(){aD=C,zo(),O0=(mP(),v0),EMt=Oy(U(O(j3,1),_V,149,0,[s0,c0,u0,d0,m0,h0,g0,_0,b0,S0,l0,f0,y0]))}function m0e(e,t){var n=P(ay(e,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15);return n.Qc(MMe(n.gc()))}function h0e(e,t){var n,r=new nr(e.a.ad(t,!0));if(r.a.gc()<=1)throw E(new zr);return n=r.a.ec().Kc(),n.Pb(),P(n.Pb(),40)}function g0e(e,t,n){var r=D(e.p[t.i.p])+D(e.d[t.i.p])+t.n.b+t.a.b;return D(e.p[n.i.p])+D(e.d[n.i.p])+n.n.b+n.a.b-r}function oD(e,t){var n;return e.i>0&&(t.lengthe.i&&Sh(t,e.i,null),t}function sD(e){var t;return e.Db&64?DT(e):(t=new Wu(DT(e)),t.a+=` (instanceClassName: `,pl(t,e.D),t.a+=`)`,t.a)}function cD(e){var t,n,r,i=0;for(n=0,r=e.length;n0&&(e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Zit(e,i,r,t),n!=-1)}function v0e(e,t){var n,i;e.a=yE(e.a,1),e.c=r.Math.min(e.c,t),e.b=r.Math.max(e.b,t),e.d+=t,n=t-e.f,i=e.e+n,e.f=i-e.e-n,e.e=i}function dD(e,t){switch(t){case 3:Ux(e,0);return;case 4:Wx(e,0);return;case 5:Gx(e,0);return;case 6:Kx(e,0);return}vT(e,t)}function fD(e,t){switch(t.g){case 1:return Jf(e.j,(fC(),$J));case 2:return Jf(e.j,(fC(),tY));default:return Vg(),Vg(),QG}}function pD(e){gh();var t=e.Pc();switch(t.length){case 0:return QW;case 1:return new wp(ph(t[0]));default:return new u_(w1e(t))}}function y0e(e,t){e.Xj();try{e.d.bd(e.e++,t),e.f=e.d.j,e.g=-1}catch(e){throw e=ew(e),j(e,77)?E(new Vr):E(e)}}function mD(){mD=C,c9=new Xse,iHt=new Zse,aHt=new Qse,oHt=new $se,sHt=new ece,cHt=new tce,lHt=new nce,uHt=new rce,dHt=new ice}function hD(e,t){Sl();var n=Kd((Ci(),Ci(),dG)),r=null;return t==n&&(r=P(v_(uG,e),624)),r||(r=new ZPe(e),t==n&&H_(uG,e,r)),r}function b0e(e){return IO(),(e.q?e.q:(Vg(),Vg(),$G))._b((mP(),V1))?P(K(e,V1),203):P(K(Bh(e),H1),203)}function gD(e,t){var n,r=null;return yd(e,(mP(),p0))&&(n=P(K(e,p0),96),n.pf(t)&&(r=n.of(t))),r??=K(Bh(e),t),r}function x0e(e,t){var n,r,i;return j(t,44)?(n=P(t,44),r=n.ld(),i=TT(e.Rc(),r),zh(i,n.md())&&(i!=null||e.Rc()._b(r))):!1}function _D(e,t){var n,r,i;return e.f>0&&(e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Knt(e,i,r,t),n)?n.md():null}function vD(e,t,n){var r,i,a;return e.Pj()?(r=e.i,a=e.Qj(),jT(e,r,t),i=e.Ij(3,null,t,r,a),n?n.nj(i):n=i):jT(e,e.i,t),n}function S0e(e,t,n){var r=new Hb(e.e,4,10,(i=t.c,j(i,90)?P(i,29):(CP(),J7)),null,NO(e,t),!1),i;return n?n.nj(r):n=r,n}function C0e(e,t,n){var r=new Hb(e.e,3,10,null,(i=t.c,j(i,90)?P(i,29):(CP(),J7)),NO(e,t),!1),i;return n?n.nj(r):n=r,n}function w0e(e){Rd();var t=new Vl(P(e.e.of((vP(),E6)),8));return e.B.Hc((UM(),T5))&&(t.a<=0&&(t.a=20),t.b<=0&&(t.b=20)),t}function yD(e){AM();var t,n=nm(e);return t=nm(um(e,32)),t==0?n>10||n<0?new Xv(1,n):YTt[n]:new Ize(n,t)}function bD(e,t){var n;return Il(e)&&Il(t)&&(n=e%t,iI=0?a=a.a[1]:(i=a,a=a.a[0])}return i}function OD(e,t,n){for(var r,i=null,a=e.b;a;){if(r=e.a.Ne(t,a.d),n&&r==0)return a;r<=0?a=a.a[0]:(i=a,a=a.a[1])}return i}function N0e(e,t,n,r){var i=!1,a,o;return mht(e.f,n,r)&&(_2e(e.f,e.a[t][n],e.a[t][r]),a=e.a[t],o=a[r],a[r]=a[n],a[n]=o,i=!0),i}function P0e(e,t,n){var r,i=P(xh(e.b,n),183),a,o;for(r=0,o=new w(t.j);o.a>5,r,i,a;return t&=31,i=e.d+n+(t==0?0:1),r=V(q9,HF,28,i,15,1),v7e(r,e.a,n,t),a=new Bm(e.e,i,r),Cv(a),a}function I0e(e,t){var n,r,i;for(r=new pm(Vu(OE(e).a.Kc(),new d));Cj(r);)if(n=P(by(r),18),i=n.d.i,i.c==t)return!1;return!0}function AD(e,t,n){var i,a,o,s=e.k,c=t.k;return i=n[s.g][c.g],a=N(gD(e,i)),o=N(gD(t,i)),r.Math.max((Gh(a),a),(Gh(o),o))}function L0e(){return Error.stackTraceLimit>0?(r.Error.stackTraceLimit=Error.stackTraceLimit=64,!0):`stack`in Error()}function R0e(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))>0}function jD(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))<0}function z0e(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))<=0}function MD(e,t){for(var n=0;!t[n]||t[n]==``;)n++;for(var r=t[n++];n0&&this.b>0&&(this.g=Pp(this.c,this.b,this.a))}function K0e(e,t){var n=e.a,r;t=String(t),n.hasOwnProperty(t)&&(r=n[t]);var i=(vw(),pG)[typeof r];return i?i(r):XQe(typeof r)}function RD(e){var t,n,r=null;if(t=dU in e.a,n=!t,n)throw E(new Vi(`Every element must have an id.`));return r=ij(A_(e,dU)),r}function zD(e){var t,n=vet(e);for(t=null;e.c==2;)hP(e),t||(t=(xP(),xP(),++W9,new lu(2)),LN(t,n),n=t),n.Jm(vet(e));return n}function BD(e,t){var n,r,i;return e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Knt(e,i,r,t),n?(aJe(e,n),n.md()):null}function q0e(e,t){return e.e>t.e?1:e.et.d?e.e:e.d=48&&e<48+r.Math.min(10,10)?e-48:e>=97&&e<97?e-97+10:e>=65&&e<65?e-65+10:-1}function Y0e(e,t){if(t.c==e)return t.d;if(t.d==e)return t.c;throw E(new Fi(`Input edge is not connected to the input port.`))}function X0e(e){if(qD(DH,e))return rd(),yG;if(qD(OH,e))return rd(),vG;throw E(new Fi(`Expecting true or false`))}function VD(e){switch(typeof e){case OP:return jw(e);case Vvt:return jl(e);case DP:return EDe(e);default:return e==null?0:td(e)}}function HD(e,t){if(e.a<0)throw E(new Ii(`Did not call before(...) or after(...) before calling add(...).`));return mEe(e,e.a,t),e}function UD(e){return R_(),j(e,162)?P(xh(f7,tEt),295).Rg(e):km(f7,$w(e))?P(xh(f7,$w(e)),295).Rg(e):null}function WD(e){var t,n;return e.Db&32||(n=(t=P(NC(e,16),29),bh(t||e.ii())-bh(e.ii())),n!=0&&GD(e,32,V(WW,FP,1,n,5,1))),e}function GD(e,t,n){var r;(e.Db&t)==0?n!=null&&pst(e,t,n):n==null?jrt(e,t):(r=pk(e,t),r==-1?e.Eb=n:Sh(rS(e.Eb),r,n))}function Z0e(e,t,n,r){var i,a;t.c.length!=0&&(i=Lat(n,r),a=ent(t),To(Cx(new Mp(null,new cv(a,1)),new Yie),new sIe(e,n,i,r)))}function Q0e(e,t){var n,r=e.a.length-1,i,a;return n=t-e.b&r,a=e.c-t&r,i=e.c-e.b&r,lDe(n=a?(PQe(e,t),-1):(NQe(e,t),1)}function KD(e){var t,n,r=e.Jh();if(!r)for(t=0,n=e.Ph();n;n=n.Ph()){if(++t>gI)return n.Qh();if(r=n.Jh(),r||n==e)break}return r}function $0e(e,t){var n;return A(t)===A(e)?!0:!j(t,21)||(n=P(t,21),n.gc()!=e.gc())?!1:e.Ic(n)}function e2e(e,t){return e.et.e?1:e.ft.f?1:US(e)-US(t)}function qD(e,t){return Gh(e),t==null?!1:ff(e,t)?!0:e.length==t.length&&ff(e.toLowerCase(),t.toLowerCase())}function JD(e){var t,n;return dT(e,-129)>0&&dT(e,128)<0?(WMe(),t=nm(e)+128,n=AG[t],!n&&(n=AG[t]=new Mn(e)),n):new Mn(e)}function YD(){YD=C,RJ=new Ds(wR,0),IJ=new Ds(`INSIDE_PORT_SIDE_GROUPS`,1),FJ=new Ds(`GROUP_MODEL_ORDER`,2),LJ=new Ds(vbt,3)}function t2e(e){var t;return e.b||eye(e,(t=hOe(e.e,e.a),!t||!ff(OH,_D((!t.b&&(t.b=new Td((CP(),$7),o9,t)),t.b),`qualified`)))),e.c}function n2e(e,t){for(var n=(sv(t,e.length),e.charCodeAt(t)),r=t+1;r2e3&&(ITt=e,sG=r.setTimeout(zye,10))),oG++==0&&(DKe((Si(),cG)),!0)}function x2e(e,t,n){var r;(mEt?(G1e(e),!0):hEt||_Et?(Co(),!0):gEt&&(Co(),!1))&&(r=new eke(t),r.b=n,w9e(e,r))}function eO(e,t){var n=!e.A.Hc((TD(),x5))||e.q==(rA(),R8);e.u.Hc((rj(),G8))?n?Qgt(e,t):Dgt(e,t):e.u.Hc(q8)&&(n?igt(e,t):x_t(e,t))}function S2e(e){var t;A(J(e,(vP(),g6)))===A((_T(),_8))&&(I_(e)?(t=P(J(I_(e),g6),346),OO(e,g6,t)):OO(e,g6,v8))}function C2e(e){var t,n;return yd(e.d.i,(mP(),Y1))?(t=P(K(e.c.i,Y1),17),n=P(K(e.d.i,Y1),17),_u(t.a,n.a)>0):!1}function w2e(e,t,n){return new wg(r.Math.min(e.a,t.a)-n/2,r.Math.min(e.b,t.b)-n/2,r.Math.abs(e.a-t.a)+n,r.Math.abs(e.b-t.b)+n)}function T2e(e){var t;this.d=new T,this.j=new Fa,this.g=new Fa,t=e.g.b,this.f=P(K(Bh(t),(mP(),_1)),88),this.e=D(N(yO(t,m0)))}function E2e(e){this.d=new T,this.e=new ry,this.c=V(q9,HF,28,(nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,15,1),this.b=e}function tO(e,t,n){var r=n[e.g][t];switch(e.g){case 1:case 3:return new k(0,r);case 2:case 4:return new k(r,0);default:return null}}function D2e(e,t,n){var r,i=P(h_(t.f),205);try{i.rf(e,n),bFe(t.f,i)}catch(e){throw e=ew(e),j(e,103)?(r=e,E(r)):E(e)}}function O2e(e,t,n){var r=null,i,a,o,s=Ymt(dS(),t),c;return a=null,s&&(i=null,c=Pmt(s,n),o=null,c!=null&&(o=e.qf(s,c)),i=o,a=i),r=a,r}function nO(e,t,n,r){var i=e.length;if(t>=i)return i;for(t=t>0?t:0;tr&&Sh(t,r,null),t}function k2e(e,t){var n,r=e.a.length;for(t.lengthr&&Sh(t,r,null),t}function iO(e,t){var n,r;if(++e.j,t!=null&&(n=(r=e.a.Cb,j(r,99)?P(r,99).th():null),Jnt(t,n))){GD(e.a,4,n);return}GD(e.a,4,P(t,129))}function A2e(e){var t;if(e==null)return null;if(t=Qit(EN(e,!0)),t==null)throw E(new Hi(`Invalid hexBinary value: '`+e+`'`));return t}function aO(e,t,n){var r;t.a.length>0&&(M(e.b,new Aje(t.a,n)),r=t.a.length,0r&&(t.a+=Uwe(V(K9,EF,28,-r,15,1))))}function j2e(e,t,n){var r,i,a;if(!n[t.d])for(n[t.d]=!0,i=new w(eT(t));i.a=e.b>>1)for(r=e.c,n=e.b;n>t;--n)r=r.b;else for(r=e.a.a,n=0;n=0?e.Wh(i):cj(e,r)):n<0?cj(e,r):P(r,69).wk().Bk(e,e.hi(),n)}function H2e(e){var t,n,r=(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),e.o);for(n=r.c.Kc();n.e!=n.i.gc();)t=P(n.Yj(),44),t.md();return Jy(r)}function hO(e){var t;if(j(e.a,4)){if(t=UD(e.a),t==null)throw E(new Ii(lSt+e.b+`'. `+sSt+(Ad(m7),m7.k)+cSt));return t}return e.a}function U2e(e,t){var n,r;if(e.j.length!=t.j.length)return!1;for(n=0,r=e.j.length;n=64&&t<128&&(i=dv(i,cm(1,t-64)));return i}function yO(e,t){var n,r=null;return yd(e,(vP(),K6))&&(n=P(K(e,K6),96),n.pf(t)&&(r=n.of(t))),r==null&&Bh(e)&&(r=K(Bh(e),t)),r}function W2e(e,t){var n=P(K(e,(mP(),j1)),75);return Cu(t,SOt)?n?Fg(n):(n=new ai,W(e,j1,n)):n&&W(e,j1,null),n}function bO(){bO=C,Iq=(vP(),Bzt),Pq=fzt,yDt=c6,Fq=A6,CDt=(Rk(),FK),SDt=NK,wDt=LK,xDt=MK,bDt=(qw(),kq),jq=gDt,Mq=_Dt,Nq=vDt}function xO(e){switch(Pbe(),this.c=new T,this.d=e,e.g){case 0:case 2:this.a=$h(NJ),this.b=cI;break;case 3:case 1:this.a=NJ,this.b=lI}}function G2e(e){var t;mf(P(K(e,(mP(),Q1)),101))&&(t=e.b,Znt((ov(0,t.c.length),P(t.c[0],30))),Znt(P(Ep(t,t.c.length-1),30)))}function K2e(e,t){t.Ug(`Self-Loop post-processing`,1),To(hg(hg(ox(new Mp(null,new cv(e.b,16)),new vne),new yne),new bne),new xne),t.Vg()}function q2e(e,t,n){var r,i;if(e.c)Gx(e.c,e.c.i+t),Kx(e.c,e.c.j+n);else for(i=new w(e.b);i.a=0&&(n.d=e.t);break;case 3:e.t>=0&&(n.a=e.t)}e.C&&(n.b=e.C.b,n.c=e.C.c)}function CO(){CO=C,LMt=new $s(vV,0),H0=new $s(JR,1),U0=new $s(`LINEAR_SEGMENTS`,2),V0=new $s(`BRANDES_KOEPF`,3),W0=new $s(Qbt,4)}function wO(){wO=C,wq=new xs(_L,0),Cq=new xs(vL,1),Tq=new xs(yL,2),Eq=new xs(bL,3),wq.a=!1,Cq.a=!0,Tq.a=!1,Eq.a=!0}function TO(){TO=C,gq=new ys(_L,0),hq=new ys(vL,1),_q=new ys(yL,2),vq=new ys(bL,3),gq.a=!1,hq.a=!0,_q.a=!1,vq.a=!0}function EO(e,t,n,r){var i;return n>=0?e.Sh(t,n,r):(e.Ph()&&(r=(i=e.Fh(),i>=0?e.Ah(r):e.Ph().Th(e,-1-i,null,r))),e.Ch(t,n,r))}function DO(e,t){switch(t){case 7:!e.e&&(e.e=new cf(U5,e,7,4)),RN(e.e);return;case 8:!e.d&&(e.d=new cf(U5,e,8,5)),RN(e.d);return}dD(e,t)}function OO(e,t,n){return n==null?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),BD(e.o,t)):(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),Hk(e.o,t,n)),e}function t4e(e,t){Vg();var n=e,r,i,a=t;for(j(e,21)&&!j(t,21)&&(n=t,a=e),i=n.Kc();i.Ob();)if(r=i.Pb(),a.Hc(r))return!1;return!0}function n4e(e,t,n,r){return t.an.b)}function kO(e,t){return rl(e)?!!TTt[t]:e.Sm?!!e.Sm[t]:al(e)?!!wTt[t]:il(e)?!!CTt[t]:!1}function r4e(e){var t=e.a;do t=P(by(new pm(Vu(DE(t).a.Kc(),new d))),18).c.i,t.k==(DA(),qJ)&&e.b.Fc(t);while(t.k==(DA(),qJ));e.b=UE(e.b)}function i4e(e,t){var n,i,a=e;for(i=new pm(Vu(DE(t).a.Kc(),new d));Cj(i);)n=P(by(i),18),n.c.i.c&&(a=r.Math.max(a,n.c.i.c.p));return a}function a4e(e,t){var n,r,i=0;for(r=P(P(Dy(e.r,t),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i+=n.d.d+n.b.Mf().b+n.d.a,r.Ob()&&(i+=e.w);return i}function o4e(e,t){var n,r,i=0;for(r=P(P(Dy(e.r,t),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i+=n.d.b+n.b.Mf().a+n.d.c,r.Ob()&&(i+=e.w);return i}function s4e(e){var t,n,r=0,i=sM(e);if(i.c.length==0)return 1;for(n=new w(i);n.a=0?e.Lh(o,n,!0):mj(e,a,n)):P(a,69).wk().yk(e,e.hi(),i,n,r)}function d4e(e,t,n,r){var i=z$e(t.pf((vP(),C6))?P(t.of(C6),21):e.j);i!=(SP(),cq)&&(n&&!PD(i)||tet($it(e,i,r),t))}function f4e(e){switch(e.g){case 1:return KC(),mq;case 3:return KC(),dq;case 2:return KC(),pq;case 4:return KC(),fq;default:return null}}function p4e(e,t,n){if(e.e)switch(e.b){case 1:OIe(e.c,t,n);break;case 0:kIe(e.c,t,n)}else XVe(e.c,t,n);e.a[t.p][n.p]=e.c.i,e.a[n.p][t.p]=e.c.e}function m4e(e){var t,n;if(e==null)return null;for(n=V(UJ,X,199,e.length,0,2),t=0;t=0)return i;if(e.ol()){for(r=0;r=i)throw E(new lf(t,i));if(e.Si()&&(r=e.dd(n),r>=0&&r!=t))throw E(new Fi(vU));return e.Xi(t,n)}function FO(e,t){if(this.a=P(ph(e),253),this.b=P(ph(t),253),e.Ed(t)>0||e==(pi(),XW)||t==(mi(),ZW))throw E(new Fi(`Invalid range: `+tHe(e,t)))}function g4e(e){var t,n;for(this.b=new T,this.c=e,this.a=!1,n=new w(e.a);n.a0),(t&-t)==t)return C_(t*Lj(e,31)*4656612873077393e-25);do n=Lj(e,31),r=n%t;while(n-r+(t-1)<0);return C_(r)}function C4e(e,t,n){switch(n.g){case 1:e.a=t.a/2,e.b=0;break;case 2:e.a=t.a,e.b=t.b/2;break;case 3:e.a=t.a/2,e.b=t.b;break;case 4:e.a=0,e.b=t.b/2}}function HO(e,t,n,r){var i,a;for(i=t;i1&&(a=_4e(e,t)),a}function T4e(e){var t=D(N(J(e,(vP(),X6))))*r.Math.sqrt((!e.a&&(e.a=new F($5,e,10,11)),e.a).i);return new k(t,t/D(N(J(e,Y6))))}function GO(e){var t;return e.f&&e.f.Vh()&&(t=P(e.f,54),e.f=P(pT(e,t),84),e.f!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,8,t,e.f))),e.f}function KO(e){var t;return e.i&&e.i.Vh()&&(t=P(e.i,54),e.i=P(pT(e,t),84),e.i!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,7,t,e.i))),e.i}function qO(e){var t;return e.b&&e.b.Db&64&&(t=e.b,e.b=P(pT(e,t),19),e.b!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,21,t,e.b))),e.b}function JO(e,t){var n,r,i;e.d==null?(++e.e,++e.f):(r=t.Bi(),hot(e,e.f+1),i=(r&AP)%e.d.length,n=e.d[i],!n&&(n=e.d[i]=e.dk()),n.Fc(t),++e.f)}function YO(e,t,n){var r;return t.tk()?!1:t.Ik()==-2?t.qk()==e.e.Dh()&&n==null:(r=t.ik(),r==null?n==null:NT(r,n))}function XO(){var e;vS(16,Qvt),e=UJe(16),this.b=V($W,fF,303,e,0,1),this.c=V($W,fF,303,e,0,1),this.a=null,this.e=null,this.i=0,this.f=e-1,this.g=0}function ZO(e){$De.call(this),this.k=(DA(),JJ),this.j=(vS(6,hF),new Hy(6)),this.b=(vS(2,hF),new Hy(2)),this.d=new ti,this.f=new ri,this.a=e}function E4e(e){var t,n;e.c.length<=1||(t=oct(e,(nP(),m5)),Tet(e,P(t.a,17).a,P(t.b,17).a),n=oct(e,g5),Tet(e,P(n.a,17).a,P(n.b,17).a))}function D4e(e,t,n){var r,i=e.a.b;for(r=i.c.length;r102?-1:e<=57?e-48:e<65?-1:e<=70?e-65+10:e<97?-1:e-97+10}function ik(e,t){if(e==null)throw E(new Li(`null key in entry: null=`+t));if(t==null)throw E(new Li(`null value in entry: `+e+`=null`))}function M4e(e,t){for(var n,r;e.Ob();)if(!t.Ob()||(n=e.Pb(),r=t.Pb(),!(A(n)===A(r)||n!=null&&NT(n,r))))return!1;return!t.Ob()}function N4e(e,t){var n=U(O(Z9,1),hI,28,15,[rT(e.a[0],t),rT(e.a[1],t),rT(e.a[2],t)]);return e.d&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function P4e(e,t){var n=U(O(Z9,1),hI,28,15,[iT(e.a[0],t),iT(e.a[1],t),iT(e.a[2],t)]);return e.d&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function ak(e,t,n){mf(P(K(t,(mP(),Q1)),101))||(eUe(e,t,NA(t,n)),eUe(e,t,NA(t,(nP(),m5))),eUe(e,t,NA(t,Z8)),Vg(),hu(t.j,new tme(e)))}function F4e(e){var t,n;for(e.c||wmt(e),n=new ai,t=new w(e.a),z(t);t.a0&&(sv(0,t.length),t.charCodeAt(0)==43)?(sv(1,t.length+1),t.substr(1)):t))}function e3e(e){var t;return e==null?null:new ru((t=EN(e,!0),t.length>0&&(sv(0,t.length),t.charCodeAt(0)==43)?(sv(1,t.length+1),t.substr(1)):t))}function t3e(e,t,n,r,i,a,o,s){var c,l;r&&(c=r.a[0],c&&t3e(e,t,n,c,i,a,o,s),Tk(e,n,r.d,i,a,o,s)&&t.Fc(r),l=r.a[1],l&&t3e(e,t,n,l,i,a,o,s))}function sk(e,t,n){try{return ol(IS(e,t,n),1)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function n3e(e,t,n){try{return ol(IS(e,t,n),0)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function r3e(e,t,n){try{return ol(IS(e,t,n),2)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function i3e(e,t){if(e.g==-1)throw E(new Rr);e.Xj();try{e.d.hd(e.g,t),e.f=e.d.j}catch(e){throw e=ew(e),j(e,77)?E(new Vr):E(e)}}function a3e(e){var t,n,r,i,a;for(r=new w(e.b);r.aa&&Sh(t,a,null),t}function o3e(e,t){var n,r=e.gc();if(t==null){for(n=0;n0&&(c+=i),l[u]=o,o+=s*(c+r)}function _3e(e){var t,n,r=e.f;for(e.n=V(Z9,hI,28,r,15,1),e.d=V(Z9,hI,28,r,15,1),t=0;t0?e.c:0),++a;e.b=i,e.d=o}function S3e(e,t){var n=U(O(Z9,1),hI,28,15,[BO(e,(Ix(),XK),t),BO(e,ZK,t),BO(e,QK,t)]);return e.f&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function C3e(e,t,n){var r;try{EM(e,t+e.j,n+e.k,!1,!0)}catch(e){throw e=ew(e),j(e,77)?(r=e,E(new Mi(r.g+TL+t+PP+n+`).`))):E(e)}}function w3e(e,t,n){var r;try{EM(e,t+e.j,n+e.k,!0,!1)}catch(e){throw e=ew(e),j(e,77)?(r=e,E(new Mi(r.g+TL+t+PP+n+`).`))):E(e)}}function T3e(e){var t;yd(e,(mP(),R1))&&(t=P(K(e,R1),21),t.Hc((Ej(),w8))?(t.Mc(w8),t.Fc(E8)):t.Hc(E8)&&(t.Mc(E8),t.Fc(w8)))}function E3e(e){var t;yd(e,(mP(),R1))&&(t=P(K(e,R1),21),t.Hc((Ej(),j8))?(t.Mc(j8),t.Fc(k8)):t.Hc(k8)&&(t.Mc(k8),t.Fc(j8)))}function gk(e,t,n,r){var i,a,o,s;return e.a??j9e(e,t),o=t.b.j.c.length,a=n.d.p,s=r.d.p,i=s-1,i<0&&(i=o-1),a<=i?e.a[i]-e.a[a]:e.a[o-1]-e.a[a]+e.a[i]}function D3e(e){var t,n;if(!e.b)for(e.b=kv(P(e.f,27).kh().i),n=new Lu(P(e.f,27).kh());n.e!=n.i.gc();)t=P(gO(n),135),M(e.b,new Di(t));return e.b}function O3e(e){var t,n;if(!e.e)for(e.e=kv(og(P(e.f,27)).i),n=new Lu(og(P(e.f,27)));n.e!=n.i.gc();)t=P(gO(n),123),M(e.e,new ahe(t));return e.e}function k3e(e){var t,n;if(!e.a)for(e.a=kv(Gg(P(e.f,27)).i),n=new Lu(Gg(P(e.f,27)));n.e!=n.i.gc();)t=P(gO(n),27),M(e.a,new sd(e,t));return e.a}function _k(e){var t;if(!e.C&&(e.D!=null||e.B!=null)){if(t=qht(e),t)e.hl(t);else try{e.hl(null)}catch(e){if(e=ew(e),!j(e,63))throw E(e)}}return e.C}function A3e(e){switch(e.q.g){case 5:h8e(e,(nP(),Z8)),h8e(e,m5);break;case 4:Lmt(e,(nP(),Z8)),Lmt(e,m5);break;default:Het(e,(nP(),Z8)),Het(e,m5)}}function j3e(e){switch(e.q.g){case 5:g8e(e,(nP(),X8)),g8e(e,g5);break;case 4:Rmt(e,(nP(),X8)),Rmt(e,g5);break;default:Uet(e,(nP(),X8)),Uet(e,g5)}}function vk(e,t){var n,i,a=new Fa;for(i=e.Kc();i.Ob();)n=P(i.Pb(),36),kM(n,a.a,0),a.a+=n.f.a+t,a.b=r.Math.max(a.b,n.f.b);return a.b>0&&(a.b+=t),a}function yk(e,t){var n,i,a=new Fa;for(i=e.Kc();i.Ob();)n=P(i.Pb(),36),kM(n,0,a.b),a.b+=n.f.b+t,a.a=r.Math.max(a.a,n.f.a);return a.a>0&&(a.a+=t),a}function M3e(e){var t,n,i=AP;for(n=new w(e.a);n.a>16==6?e.Cb.Th(e,5,J5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||e.ii()),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function F3e(e){Xg();var t=e.e;if(t&&t.stack){var n=t.stack,r=t+` +`;return n.substring(0,r.length)==r&&(n=n.substring(r.length)),n.split(` +`)}return[]}function I3e(e){var t=(pJe(),UTt);return t[e>>>28]|t[e>>24&15]<<4|t[e>>20&15]<<8|t[e>>16&15]<<12|t[e>>12&15]<<16|t[e>>8&15]<<20|t[e>>4&15]<<24|t[e&15]<<28}function L3e(e){var t,n,i;e.b==e.c&&(i=e.a.length,n=dZe(r.Math.max(8,i))<<1,e.b==0?Wr(e.a,n):(t=Yd(e.a,n),eYe(e,t,i),e.a=t,e.b=0),e.c=i)}function R3e(e,t){var n=e.b;return n.pf((vP(),F6))?n.ag()==(nP(),g5)?-n.Mf().a-D(N(n.of(F6))):t+D(N(n.of(F6))):n.ag()==(nP(),g5)?-n.Mf().a:t}function xk(e){var t;return e.b.c.length!=0&&P(Ep(e.b,0),72).a?P(Ep(e.b,0),72).a:(t=xg(e),t??``+(e.c?Ab(e.c.a,e,0):-1))}function Sk(e){var t;return e.f.c.length!=0&&P(Ep(e.f,0),72).a?P(Ep(e.f,0),72).a:(t=xg(e),t??``+(e.i?Ab(e.i.j,e,0):-1))}function z3e(e,t){var n,r;if(t<0||t>=e.gc())return null;for(n=t;n0?e.c:0),a=r.Math.max(a,t.d),++i;e.e=o,e.b=a}function H3e(e){var t,n;if(!e.b)for(e.b=kv(P(e.f,123).kh().i),n=new Lu(P(e.f,123).kh());n.e!=n.i.gc();)t=P(gO(n),135),M(e.b,new Di(t));return e.b}function U3e(e,t){var n,r,i;if(t.dc())return Nd(),Nd(),_7;for(n=new PDe(e,t.gc()),i=new Lu(e);i.e!=i.i.gc();)r=gO(i),t.Hc(r)&&tb(n,r);return n}function W3e(e,t,n,r){return t==0?r?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),e.o):(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),Jy(e.o)):jO(e,t,n,r)}function Ck(e){var t,n;if(e.rb)for(t=0,n=e.rb.i;t>22),i+=r>>22,i<0)?!1:(e.l=n&QF,e.m=r&QF,e.h=i&$F,!0)}function Tk(e,t,n,r,i,a,o){var s,c;return!(t.Te()&&(c=e.a.Ne(n,r),c<0||!i&&c==0)||t.Ue()&&(s=e.a.Ne(n,a),s>0||!o&&s==0))}function J3e(e,t){if(Fw(),e.j.g-t.j.g!=0)return 0;switch(e.j.g){case 2:return kE(t,yX)-kE(e,yX);case 4:return kE(e,vX)-kE(t,vX)}return 0}function Y3e(e){switch(e.g){case 0:return yZ;case 1:return bZ;case 2:return xZ;case 3:return SZ;case 4:return CZ;case 5:return wZ;default:return null}}function Ek(e,t,n){var r=(i=new li,aT(i,t),GS(i,n),tb((!e.c&&(e.c=new F(P7,e,12,10)),e.c),i),i),i;return Zx(r,0),Qx(r,1),RT(r,!0),FT(r,!0),r}function Dk(e,t){var n,r;if(t>=e.i)throw E(new wl(t,e.i));return++e.j,n=e.g[t],r=e.i-t-1,r>0&&tN(e.g,t+1,e.g,t,r),Sh(e.g,--e.i,null),e.Qi(t,n),e.Ni(),n}function X3e(e,t){var n,r;return e.Db>>16==17?e.Cb.Th(e,21,D7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||e.ii()),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function Z3e(e){var t,n,r,i;for(Vg(),hu(e.c,e.a),i=new w(e.c);i.an.a.c.length))throw E(new Fi(`index must be >= 0 and <= layer node count`));e.c&&Db(e.c.a,e),e.c=n,n&&Jp(n.a,t,e)}function d6e(e,t){var n,r,i;for(r=new pm(Vu(EE(e).a.Kc(),new d));Cj(r);)return n=P(by(r),18),i=P(t.Kb(n),10),new pn(ph(i.n.b+i.o.b/2));return fi(),fi(),GW}function f6e(e,t){this.c=new Dr,this.a=e,this.b=t,this.d=P(K(e,(Y(),o$)),312),this.e=A(K(e,(mP(),Jjt)))===A((wb(),EZ))?new Qge:new Zge}function jk(e,t){var n,r=null;return e.pf((vP(),K6))&&(n=P(e.of(K6),96),n.pf(t)&&(r=n.of(t))),r==null&&e.Tf()&&(r=e.Tf().of(t)),r??=hO(t),r}function Mk(e,t){var n=e.fd(t),r;try{return r=n.Pb(),n.Qb(),r}catch(e){throw e=ew(e),j(e,112)?E(new Mi(`Can't remove element `+t)):E(e)}}function p6e(e,t){var n,r=new uo,i=new xZe(r.q.getFullYear()-VF,r.q.getMonth(),r.q.getDate());if(n=zft(e,t,i),n==0||n0?t:0),++n;return new k(i,a)}function b6e(e,t){var n,r;return e.Db>>16==6?e.Cb.Th(e,6,U5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),X5)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function x6e(e,t){var n,r;return e.Db>>16==7?e.Cb.Th(e,1,B5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),lVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function S6e(e,t){var n,r;return e.Db>>16==9?e.Cb.Th(e,9,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),dVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function C6e(e,t){var n,r;return e.Db>>16==5?e.Cb.Th(e,9,k7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),W7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function w6e(e,t){var n,r;return e.Db>>16==7?e.Cb.Th(e,6,J5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),X7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function T6e(e,t){var n,r;return e.Db>>16==3?e.Cb.Th(e,0,G5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),B7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function E6e(){this.a=new Pse,this.g=new XO,this.j=new XO,this.b=new Dr,this.d=new XO,this.i=new XO,this.k=new Dr,this.c=new Dr,this.e=new Dr,this.f=new Dr}function D6e(e,t,n){var r,i,a;for(n<0&&(n=0),a=e.i,i=n;igI)return Pk(e,r);if(r==e)return!0}}return!1}function k6e(e){switch(nd(),e.q.g){case 5:fnt(e,(nP(),Z8)),fnt(e,m5);break;case 4:dat(e,(nP(),Z8)),dat(e,m5);break;default:Rgt(e,(nP(),Z8)),Rgt(e,m5)}}function A6e(e){switch(nd(),e.q.g){case 5:drt(e,(nP(),X8)),drt(e,g5);break;case 4:Y2e(e,(nP(),X8)),Y2e(e,g5);break;default:zgt(e,(nP(),X8)),zgt(e,g5)}}function j6e(e){var t=P(K(e,(XM(),HDt)),17),n;t?(n=t.a,n==0?W(e,(jS(),aJ),new YE):W(e,(jS(),aJ),new sy(n))):W(e,(jS(),aJ),new sy(1))}function M6e(e,t){var n=e.i;switch(t.g){case 1:return-(e.n.b+e.o.b);case 2:return e.n.a-n.o.a;case 3:return e.n.b-n.o.b;case 4:return-(e.n.a+e.o.a)}return 0}function N6e(e,t){switch(e.g){case 0:return t==(XE(),h$)?mX:hX;case 1:return t==(XE(),h$)?mX:pX;case 2:return t==(XE(),h$)?pX:hX;default:return pX}}function Fk(e,t){var n,i,a;for(Db(e.a,t),e.e-=t.r+(e.a.c.length==0?0:e.c),a=hxt,i=new w(e.a);i.a>16==3?e.Cb.Th(e,12,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),sVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function F6e(e,t){var n,r;return e.Db>>16==11?e.Cb.Th(e,10,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),uVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function I6e(e,t){var n,r;return e.Db>>16==10?e.Cb.Th(e,11,D7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),Y7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function L6e(e,t){var n,r;return e.Db>>16==10?e.Cb.Th(e,12,M7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),Z7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function Ik(e){var t;return!(e.Bb&1)&&e.r&&e.r.Vh()&&(t=P(e.r,54),e.r=P(pT(e,t),142),e.r!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,8,t,e.r))),e.r}function Lk(e,t,n){var i=U(O(Z9,1),hI,28,15,[j7e(e,(Ix(),XK),t,n),j7e(e,ZK,t,n),j7e(e,QK,t,n)]);return e.f&&(i[0]=r.Math.max(i[0],i[2]),i[2]=i[0]),i}function R6e(e,t){var n,r,i=X2e(e,t);if(i.c.length!=0)for(hu(i,new zte),n=i.c.length,r=0;r>19,l=t.h>>19;return c==l?(i=e.h,s=t.h,i==s?(r=e.m,o=t.m,r==o?(n=e.l,a=t.l,n-a):r-o):i-s):l-c}function Rk(){Rk=C,RK=(vM(),GK),LK=new Tl(QI,RK),IK=(dx(),kK),FK=new Tl($I,IK),PK=(fO(),EK),NK=new Tl(eL,PK),MK=new Tl(tL,(rd(),!0))}function zk(e,t,n){var r=t*n,i;j(e.g,154)?(i=zv(e),i.f.d?i.f.a||(e.d.a+=r+fL):(e.d.d-=r+fL,e.d.a+=r+fL)):j(e.g,10)&&(e.d.d-=r,e.d.a+=2*r)}function G6e(e,t,n){var i,a=e[n.g],o,s,c;for(c=new w(t.d);c.a0?e.b:0),++n;t.b=i,t.e=a}function q6e(e){var t,n,r=e.b;if(mbe(e.i,r.length)){for(n=r.length*2,e.b=V($W,fF,303,n,0,1),e.c=V($W,fF,303,n,0,1),e.f=n-1,e.i=0,t=e.a;t;t=t.c)nj(e,t,t);++e.g}}function J6e(e,t,n,r){var i,a,o,s;for(i=0;is&&(c=s/i),a>o&&(l=o/a),ku(e,r.Math.min(c,l)),e}function X6e(){_N();var e,t;try{if(t=P(U8e((qo(),N7),eU),2113),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new kse}function Z6e(){_N();var e,t;try{if(t=P(U8e((qo(),N7),iW),2040),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new ace}function Q6e(){EGe();var e,t;try{if(t=P(U8e((qo(),N7),bW),2122),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new Qce}function $6e(e,t,n){var r,i=e.e;return e.e=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,4,i,t),n?n.nj(r):n=r),i!=t&&(n=t?JN(e,Rj(e,t),n):JN(e,e.a,n)),n}function e8e(){uo.call(this),this.e=-1,this.a=!1,this.p=xF,this.k=-1,this.c=-1,this.b=-1,this.g=!1,this.f=-1,this.j=-1,this.n=-1,this.i=-1,this.d=-1,this.o=xF}function t8e(e,t){var n,r=e.b.d.d,i;if(e.a||(r+=e.b.d.a),i=t.b.d.d,t.a||(i+=t.b.d.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function n8e(e,t){var n,r=e.b.b.d,i;if(e.a||(r+=e.b.b.a),i=t.b.b.d,t.a||(i+=t.b.b.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function r8e(e,t){var n,r=e.b.g.d,i;if(e.a||(r+=e.b.g.a),i=t.b.g.d,t.a||(i+=t.b.g.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function i8e(){i8e=C,oOt=tm(vp(vp(vp(new Zh,(vA(),xJ),(yP(),NY)),xJ,LY),SJ,WY),SJ,xY),cOt=vp(vp(new Zh,xJ,dY),xJ,SY),sOt=tm(new Zh,SJ,wY)}function a8e(e){var t=P(K(e,(Y(),bQ)),85),n,r,i,a=e.n;for(r=t.Cc().Kc();r.Ob();)n=P(r.Pb(),314),i=n.i,i.c+=a.a,i.d+=a.b,n.c?gct(n):_ct(n);W(e,bQ,null)}function o8e(e,t,n){var r,i=e.b;switch(r=i.d,t.g){case 1:return-r.d-n;case 2:return i.o.a+r.c+n;case 3:return i.o.b+r.a+n;case 4:return-r.b-n;default:return-1}}function s8e(e,t,n){var r,i;for(n.Ug(`Interactive node placement`,1),e.a=P(K(t,(Y(),o$)),312),i=new w(t.b);i.a0&&(o=(a&AP)%e.d.length,i=Knt(e,o,a,t),i)?(s=i.nd(n),s):(r=e.ck(a,t,n),e.c.Fc(r),null)}function C8e(e,t){var n,r,i,a;switch(AT(e,t).Kl()){case 3:case 2:for(n=bN(t),i=0,a=n.i;i=0;i--)if(ff(e[i].d,t)||ff(e[i].d,n)){e.length>=i+1&&e.splice(0,i+1);break}return e}function Wk(e,t){var n;return Il(e)&&Il(t)&&(n=e/t,iI0&&(e.b+=2,e.a+=i):(e.b+=1,e.a+=r.Math.min(i,a))}function F8e(e){var t=P(K(P(SO(e.b,0),40),(rN(),fFt)),107);W(e,(tP(),H2),new k(0,0)),but(new zy,e,t.b+t.c-D(N(K(e,K2))),t.d+t.a-D(N(K(e,q2))))}function I8e(e,t){var n,r=!1;if(rl(t)&&(r=!0,Dh(e,new mh(kd(t)))),r||j(t,242)&&(r=!0,Dh(e,(n=ZOe(P(t,242)),new Cn(n)))),!r)throw E(new Ni(pCt))}function L8e(e,t,n,r){var i=new Hb(e.e,1,10,(o=t.c,j(o,90)?P(o,29):(CP(),J7)),(a=n.c,j(a,90)?P(a,29):(CP(),J7)),NO(e,t),!1),a,o;return r?r.nj(i):r=i,r}function R8e(e){var t,n;switch(P(K(Bh(e),(mP(),Bjt)),429).g){case 0:return t=e.n,n=e.o,new k(t.a+n.a/2,t.b+n.b/2);case 1:return new Vl(e.n);default:return null}}function qk(){qk=C,MZ=new Us(wR,0),jZ=new Us(`LEFTUP`,1),PZ=new Us(`RIGHTUP`,2),AZ=new Us(`LEFTDOWN`,3),NZ=new Us(`RIGHTDOWN`,4),kZ=new Us(`BALANCED`,5)}function z8e(e,t,n){var r=aE(e.a[t.p],e.a[n.p]),i,a;if(r==0){if(i=P(K(t,(Y(),PQ)),15),a=P(K(n,PQ),15),i.Hc(n))return-1;if(a.Hc(t))return 1}return r}function B8e(e){switch(e.g){case 1:return new soe;case 2:return new coe;case 3:return new ooe;case 0:return null;default:throw E(new Fi(ZV+(e.f==null?``+e.g:e.f)))}}function V8e(e,t,n){switch(t){case 1:!e.n&&(e.n=new F(Q5,e,1,7)),RN(e.n),!e.n&&(e.n=new F(Q5,e,1,7)),th(e.n,P(n,16));return;case 2:CS(e,kd(n));return}qZe(e,t,n)}function H8e(e,t,n){switch(t){case 3:Ux(e,D(N(n)));return;case 4:Wx(e,D(N(n)));return;case 5:Gx(e,D(N(n)));return;case 6:Kx(e,D(N(n)));return}V8e(e,t,n)}function Jk(e,t,n){var r,i,a=(r=new li,r);i=fA(a,t,null),i&&i.oj(),GS(a,n),tb((!e.c&&(e.c=new F(P7,e,12,10)),e.c),a),Zx(a,0),Qx(a,1),RT(a,!0),FT(a,!0)}function U8e(e,t){var n=as(e.i,t),r,i;return j(n,241)?(i=P(n,241),i.zi(),i.wi()):j(n,507)?(r=P(n,2037),i=r.b,i):null}function W8e(e,t,n,r){var i,a;return ph(t),ph(n),a=P(_f(e.d,t),17),oKe(!!a,`Row %s not in %s`,t,e.e),i=P(_f(e.b,n),17),oKe(!!i,`Column %s not in %s`,n,e.c),JXe(e,a.a,i.a,r)}function G8e(e,t,n,r,i,a,o){var s,c,l,u=i[a],d;if(l=a==o-1,s=l?r:0,d=b3e(s,u),r!=10&&U(O(e,o-a),t[a],n[a],s,d),!l)for(++a,c=0;c1||s==-1?(a=P(c,15),i.Wb(r0e(e,a))):i.Wb(WM(e,P(c,58)))))}function e5e(e,t,n,r){Bye();var i=xTt;STt=r;function a(){for(var e=0;e0)return!1;return!0}function r5e(e){var t,n,r,i,a;for(r=new EC(new Fn(e.b).a);r.b;)n=MS(r),t=P(n.ld(),10),a=P(P(n.md(),42).a,10),i=P(P(n.md(),42).b,8),$d(Cl(t.n),$d(xu(a.n),i))}function i5e(e){switch(P(K(e.b,(mP(),Njt)),387).g){case 1:To(gg(ox(new Mp(null,new cv(e.d,16)),new jre),new Mre),new Nre);break;case 2:elt(e);break;case 0:Dtt(e)}}function a5e(e,t,n){var r=n,i,a;for(!r&&(r=new di),r.Ug(`Layout`,e.a.c.length),a=new w(e.a);a.aAV)return n;i>-1e-6&&++n}return n}function u5e(e,t){var n;t==e.b?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t)):(n=null,e.b&&(n=m_(e.b,e,-4,n)),t&&(n=EO(t,e,-4,n)),n=m$e(e,t,n),n&&n.oj())}function d5e(e,t){var n;t==e.f?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,t,t)):(n=null,e.f&&(n=m_(e.f,e,-1,n)),t&&(n=EO(t,e,-1,n)),n=p$e(e,t,n),n&&n.oj())}function f5e(e,t,n,r){var i,a,o,s;return Gl(e.e)&&(i=t.Lk(),s=t.md(),a=n.md(),o=s_(e,1,i,s,a,i.Jk()?pN(e,i,a,j(i,102)&&(P(i,19).Bb&pI)!=0):-1,!0),r?r.nj(o):r=o),r}function p5e(e){var t,n,r;if(e==null)return null;if(n=P(e,15),n.dc())return``;for(r=new $i,t=n.Kc();t.Ob();)pl(r,(UN(),kd(t.Pb()))),r.a+=` `;return kl(r,r.a.length-1)}function m5e(e){var t,n,r;if(e==null)return null;if(n=P(e,15),n.dc())return``;for(r=new $i,t=n.Kc();t.Ob();)pl(r,(UN(),kd(t.Pb()))),r.a+=` `;return kl(r,r.a.length-1)}function h5e(e,t,n){var r=e.c[t.c.p][t.p],i=e.c[n.c.p][n.p];return r.a!=null&&i.a!=null?dm(r.a,i.a):r.a==null?i.a==null?0:1:-1}function g5e(e,t,n){return n.Ug(`Tree layout`,1),cg(e.b),Um(e.b,(Ok(),N2),N2),Um(e.b,P2,P2),Um(e.b,F2,F2),Um(e.b,I2,I2),e.a=BN(e.b,t),a5e(e,t,n.eh(1)),n.Vg(),t}function _5e(e,t){var n,r,i,a,o,s;if(t)for(a=t.a.length,n=new hm(a),s=(n.b-n.a)*n.c<0?($o(),G9):new Ru(n);s.Ob();)o=P(s.Pb(),17),i=Pv(t,o.a),r=new hhe(e),XFe(r.a,i)}function v5e(e,t){var n,r,i,a,o,s;if(t)for(a=t.a.length,n=new hm(a),s=(n.b-n.a)*n.c<0?($o(),G9):new Ru(n);s.Ob();)o=P(s.Pb(),17),i=Pv(t,o.a),r=new ohe(e),YFe(r.a,i)}function y5e(e){var t;if(e!=null&&e.length>0&&mg(e,e.length-1)==33)try{return t=Vit(p_(e,0,e.length-1)),t.e==null}catch(e){if(e=ew(e),!j(e,33))throw E(e)}return!1}function b5e(e,t,n){var r=cE(Bh(t)),i=new jA;switch(G_(i,t),n.g){case 1:tj(i,YT(GE(r)));break;case 2:tj(i,GE(r))}return W(i,(mP(),Z1),N(K(e,Z1))),i}function x5e(e){var t=P(by(new pm(Vu(DE(e.a).a.Kc(),new d))),18),n=P(by(new pm(Vu(OE(e.a).a.Kc(),new d))),18);return ki(Od(K(t,(Y(),r$))))||ki(Od(K(n,r$)))}function tA(){tA=C,TX=new Ns(`ONE_SIDE`,0),DX=new Ns(`TWO_SIDES_CORNER`,1),OX=new Ns(`TWO_SIDES_OPPOSING`,2),EX=new Ns(`THREE_SIDES`,3),wX=new Ns(`FOUR_SIDES`,4)}function S5e(e,t){var n,r,i,a=new T;for(i=0,r=t.Kc();r.Ob();){for(n=G(P(r.Pb(),17).a+i);n.a=e.f)break;Mr(a.c,n)}return a}function C5e(e,t){var n,r,i,a,o;for(a=new w(t.a);a.a0&&t6e(this,this.c-1,(nP(),X8)),this.c0&&e[0].length>0&&(this.c=ki(Od(K(Bh(e[0][0]),(Y(),FQ))))),this.a=V(ENt,X,2117,e.length,0,2),this.b=V(DNt,X,2118,e.length,0,2),this.d=new YQe}function I5e(e){return e.c.length==0?!1:(ov(0,e.c.length),P(e.c[0],18)).c.i.k==(DA(),qJ)||hy(gg(new Mp(null,new cv(e,16)),new vie),new yie)}function L5e(e,t){var n,i,a,o,s,c=sM(t),l;for(o=t.f,l=t.g,s=r.Math.sqrt(o*o+l*l),a=0,i=new w(c);i.a=0?(n=Wk(e,rI),r=bD(e,rI)):(t=um(e,1),n=Wk(t,5e8),r=bD(t,5e8),r=yE(cm(r,1),uv(e,1))),dv(cm(r,32),uv(n,_I))}function $5e(e,t,n){var r=(jd(t.b!=0),P(Ox(t,t.a.a),8)),i;switch(n.g){case 0:r.b=0;break;case 2:r.b=e.f;break;case 3:r.a=0;break;default:r.a=e.g}return i=dO(t,0),Zm(i,r),t}function e7e(e,t,n,r){var i,a,o,s,c=e.b;switch(a=t.d,o=a.j,s=tO(o,c.d[o.g],n),i=$d(xu(a.n),a.a),a.j.g){case 1:case 3:s.a+=i.a;break;case 2:case 4:s.b+=i.b}iy(r,s,r.c.b,r.c)}function t7e(e,t,n){var r,i,a,o=Ab(e.e,t,0);for(a=new Jge,a.b=n,r=new bv(e.e,o);r.b1;t>>=1)t&1&&(r=Uv(r,n)),n=n.d==1?Uv(n,n):new c2e(Zut(n.a,n.d,V(q9,HF,28,n.d<<1,15,1)));return r=Uv(r,n),r}function s7e(){s7e=C;var e,t,n,r;for(cK=V(Z9,hI,28,25,15,1),lK=V(Z9,hI,28,33,15,1),r=152587890625e-16,t=32;t>=0;t--)lK[t]=r,r*=.5;for(n=1,e=24;e>=0;e--)cK[e]=n,n*=.5}function c7e(e){var t,n;if(ki(Od(J(e,(mP(),k1))))){for(n=new pm(Vu(Ij(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),74),uj(t)&&ki(Od(J(t,A1))))return!0}return!1}function l7e(e,t){var n,r,i;Lm(e.f,t)&&(t.b=e,r=t.c,Ab(e.j,r,0)!=-1||M(e.j,r),i=t.d,Ab(e.j,i,0)!=-1||M(e.j,i),n=t.a.b,n.c.length!=0&&(!e.i&&(e.i=new T2e(e)),iXe(e.i,n)))}function u7e(e){var t,n=e.c.d,r=n.j,i=e.d.d,a=i.j;return r==a?n.p=0&&ff(e.substr(t,3),`GMT`)||t>=0&&ff(e.substr(t,3),`UTC`))&&(n[0]=t+3),zut(e,n,r)}function f7e(e,t){var n,r,i,a=e.g.a,o=e.g.b;for(r=new w(e.d);r.an;a--)e[a]|=t[a-n-1]>>>o,e[a-1]=t[a-n-1]<0&&tN(e.g,t,e.g,t+r,s),o=n.Kc(),e.i+=r,i=0;i>4&15,a=e[r]&15,o[i++]=hVt[n],o[i++]=hVt[a];return ND(o,0,o.length)}function mA(e){var t,n;return e>=pI?(t=mI+(e-pI>>10&1023)&OF,n=56320+(e-pI&1023)&OF,String.fromCharCode(t)+(``+String.fromCharCode(n))):String.fromCharCode(e&OF)}function D7e(e,t){Rd();var n,r,i=P(P(Dy(e.r,t),21),87),a;return i.gc()>=2&&(r=P(i.Kc().Pb(),117),n=e.u.Hc((rj(),W8)),a=e.u.Hc(J8),!r.a&&!n&&(i.gc()==2||a))}function O7e(e,t,n,r,i){for(var a=Gst(e,t,n,r,i),o,s=!1;!a;)Oj(e,i,!0),s=!0,a=Gst(e,t,n,r,i);s&&Oj(e,i,!1),o=uw(i),o.c.length!=0&&(e.d&&e.d.Gg(o),O7e(e,i,n,r,o))}function hA(){hA=C,m8=new Pc(wR,0),cBt=new Pc(`DIRECTED`,1),uBt=new Pc(`UNDIRECTED`,2),oBt=new Pc(`ASSOCIATION`,3),lBt=new Pc(`GENERALIZATION`,4),sBt=new Pc(`DEPENDENCY`,5)}function k7e(e,t){var n;if(!E_(e))throw E(new Ii(zSt));switch(n=E_(e),t.g){case 1:return-(e.j+e.f);case 2:return e.i-n.g;case 3:return e.j-n.f;case 4:return-(e.i+e.g)}return 0}function A7e(e,t,n){var r=t.Lk(),i,a=t.md();return i=r.Jk()?s_(e,4,r,a,null,pN(e,r,a,j(r,102)&&(P(r,19).Bb&pI)!=0),!0):s_(e,r.tk()?2:1,r,a,r.ik(),-1,!0),n?n.nj(i):n=i,n}function gA(e,t){var n,r;for(Gh(t),r=e.b.c.length,M(e.b,t);r>0;){if(n=r,r=(r-1)/2|0,e.a.Ne(Ep(e.b,r),t)<=0)return uy(e.b,n,t),!0;uy(e.b,n,Ep(e.b,r))}return uy(e.b,r,t),!0}function j7e(e,t,n,i){var a=0,o;if(n)a=iT(e.a[n.g][t.g],i);else for(o=0;o=s)}function N7e(e){switch(e.g){case 0:return new Soe;case 1:return new Coe;default:throw E(new Fi(`No implementation is available for the width approximator `+(e.f==null?``+e.g:e.f)))}}function P7e(e,t,n,r){var i=!1;if(rl(r)&&(i=!0,sp(t,n,kd(r))),i||il(r)&&(i=!0,P7e(e,t,n,r)),i||j(r,242)&&(i=!0,qg(t,n,P(r,242))),!i)throw E(new Ni(pCt))}function F7e(e,t){var n=t.qi(e.a),r,i;if(n&&(i=_D((!n.b&&(n.b=new Td((CP(),$7),o9,n)),n.b),ZU),i!=null)){for(r=1;r<(UA(),hHt).length;++r)if(ff(hHt[r],i))return r}return 0}function I7e(e,t){var n=t.qi(e.a),r,i;if(n&&(i=_D((!n.b&&(n.b=new Td((CP(),$7),o9,n)),n.b),ZU),i!=null)){for(r=1;r<(UA(),gHt).length;++r)if(ff(gHt[r],i))return r}return 0}function L7e(e,t){var n,r,i,a;if(Gh(t),a=e.a.gc(),a0);a.a[i]!=n;)a=a.a[i],i=+(e.a.Ne(n.d,a.d)>0);a.a[i]=r,r.b=n.b,r.a[0]=n.a[0],r.a[1]=n.a[1],n.a[0]=null,n.a[1]=null}function H7e(e){var t=new T,n=V(J9,aL,28,e.a.c.length,16,1),r,i;for(CPe(n,n.length),i=new w(e.a);i.a0&&Eut((ov(0,n.c.length),P(n.c[0],30)),e),n.c.length>1&&Eut(P(Ep(n,n.c.length-1),30),e),t.Vg()}function G7e(e){rj();var t=Zp(G8,U(O(Y8,1),Z,279,0,[q8])),n;return!(BC(b_(t,e))>1||(n=Zp(W8,U(O(Y8,1),Z,279,0,[U8,J8])),BC(b_(n,e))>1))}function K7e(e,t){j(v_((qo(),N7),e),507)?H_(N7,e,new YSe(this,t)):H_(N7,e,this),EA(this,t),t==(Ra(),R7)?(this.wb=P(this,2038),P(t,2040)):this.wb=(vh(),z7)}function q7e(e){var t,n,r;if(e==null)return null;for(t=null,n=0;n=DF?`error`:r>=900?`warn`:r>=800?`info`:`log`),aFe(n,e.a),e.b&&Not(t,n,e.b,`Exception: `,!0))}function K(e,t){var n;return!e.q&&(e.q=new Dr),xh(e.q,t)??(n=t.Sg(),j(n,4)&&(n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n))),n)}function vA(){vA=C,vJ=new ws(`P1_CYCLE_BREAKING`,0),yJ=new ws(`P2_LAYERING`,1),bJ=new ws(`P3_NODE_ORDERING`,2),xJ=new ws(`P4_NODE_PLACEMENT`,3),SJ=new ws(`P5_EDGE_ROUTING`,4)}function X7e(e,t){mx();var n;if(e.c==t.c){if(e.b==t.b||pYe(e.b,t.b)){if(n=TCe(e.b)?1:-1,e.a&&!t.a)return n;if(!e.a&&t.a)return-n}return _u(e.b.g,t.b.g)}return aE(e.c,t.c)}function Z7e(e,t){var n,r,i;if(n9e(e,t))return!0;for(r=new w(t);r.a=i||t<0)throw E(new Mi(yU+t+bU+i));if(n>=i||n<0)throw E(new Mi(xU+n+bU+i));return r=t==n?e.xj(n):(a=e.Cj(n),e.qj(t,a),a),r}function t9e(e){var t,n,r=e;if(e)for(t=0,n=e.Eh();n;n=n.Eh()){if(++t>gI)return t9e(n);if(r=n,n==e)throw E(new Ii(`There is a cycle in the containment hierarchy of `+e))}return r}function CA(e){var t,n,r=new UC(PP,`[`,`]`);for(n=e.Kc();n.Ob();)t=n.Pb(),jy(r,A(t)===A(e)?`(this Collection)`:t==null?IP:PE(t));return r.a?r.e.length==0?r.a.a:r.a.a+(``+r.e):r.c}function n9e(e,t){var n,r=!1;if(t.gc()<2)return!1;for(n=0;n1&&(e.j.b+=e.e)):(e.j.a+=n.a,e.j.b=r.Math.max(e.j.b,n.b),e.d.c.length>1&&(e.j.a+=e.e))}function wA(){wA=C,ZOt=U(O(_5,1),TR,64,0,[(nP(),Z8),X8,m5]),XOt=U(O(_5,1),TR,64,0,[X8,m5,g5]),QOt=U(O(_5,1),TR,64,0,[m5,g5,Z8]),$Ot=U(O(_5,1),TR,64,0,[g5,Z8,X8])}function o9e(e,t,n,r){var i,a,o=e.c.d,s=e.d.d,c,l,u;if(o.j!=s.j)for(u=e.b,i=o.j,c=null;i!=s.j;)c=t==0?XT(i):JT(i),a=tO(i,u.d[i.g],n),l=tO(c,u.d[c.g],n),up(r,$d(a,l)),i=c}function s9e(e,t,n,r){var i,a,o=a6e(e.a,t,n),s=P(o.a,17).a,c;return a=P(o.b,17).a,r&&(c=P(K(t,(Y(),QQ)),10),i=P(K(n,QQ),10),c&&i&&(XVe(e.b,c,i),s+=e.b.i,a+=e.b.e)),s>a}function c9e(e){var t,n,r,i,a,o,s,c,l;for(this.a=m4e(e),this.b=new T,n=e,r=0,i=n.length;rLd(e.d).c?(e.i+=e.g.c,SD(e.d)):Ld(e.d).c>Ld(e.g).c?(e.e+=e.d.c,SD(e.g)):(e.i+=aNe(e.g),e.e+=aNe(e.d),SD(e.g),SD(e.d))}function p9e(e,t,n){var r,i,a=t.q,o=t.r;for(new nv((Wy(),k2),t,a,1),new nv(k2,a,o,1),i=new w(n);i.ac&&(l=c/i),a>o&&(u=o/a),s=r.Math.min(l,u),e.a+=s*(t.a-e.a),e.b+=s*(t.b-e.b)}function y9e(e,t,n,r,i){var a,o=!1;for(a=P(Ep(n.b,0),27);xft(e,t,a,r,i)&&(o=!0,X8e(n,a),n.b.c.length!=0);)a=P(Ep(n.b,0),27);return n.b.c.length==0&&Fk(n.j,n),o&&hk(t.q),o}function b9e(e,t){fM();var n,r,i,a;if(t.b<2)return!1;for(a=dO(t,0),n=P(Lv(a),8),r=n;a.b!=a.d.c;){if(i=P(Lv(a),8),Kj(e,r,i))return!0;r=i}return!!Kj(e,r,n)}function x9e(e,t,n,r){var i,a;return n==0?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),gf(e.o,t,r)):(a=P(_x((i=P(NC(e,16),29),i||e.ii()),n),69),a.wk().Ak(e,WD(e),n-bh(e.ii()),t,r))}function EA(e,t){var n;t==e.sb?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,4,t,t)):(n=null,e.sb&&(n=P(e.sb,54).Th(e,1,K5,n)),t&&(n=P(t,54).Rh(e,1,K5,n)),n=OT(e,t,n),n&&n.oj())}function S9e(e,t){var n,r,i,a;if(t)i=nS(t,`x`),n=new fhe(e),Hx(n.a,(Gh(i),i)),a=nS(t,`y`),r=new phe(e),Jx(r.a,(Gh(a),a));else throw E(new Vi(`All edge sections need an end point.`))}function C9e(e,t){var n,r,i,a;if(t)i=nS(t,`x`),n=new lhe(e),qx(n.a,(Gh(i),i)),a=nS(t,`y`),r=new uhe(e),Yx(r.a,(Gh(a),a));else throw E(new Vi(`All edge sections need a start point.`))}function w9e(e,t){var n,r,i,a,o,s,c;for(r=aQe(e),a=0,s=r.length;a>22-t,i=e.h<>22-t):t<44?(n=0,r=e.l<>44-t):(n=0,r=0,i=e.l<e)throw E(new Fi(`k must be smaller than n`));return t==0||t==e?1:e==0?0:E8e(e)/(E8e(t)*E8e(e-t))}function N9e(e,t){for(var n=new nu(e),r,i,a;n.g==null&&!n.c?lRe(n):n.g==null||n.i!=0&&P(n.g[n.i-1],51).Ob();)if(a=P(Pj(n),58),j(a,167))for(r=P(a,167),i=0;i>4],t[n*2+1]=N9[a&15];return ND(t,0,t.length)}function K9e(e){eg();var t,n;switch(e.c.length){case 0:return ATt;case 1:return t=P(Jtt(new w(e)),44),_Me(t.ld(),t.md());default:return n=P(rO(e,V(YW,oF,44,e.c.length,0,1)),173),new _i(n)}}function q9e(e){var t=new Iu,n=new Iu,r,i,a,o;for(Rv(t,e),Rv(n,e);n.b!=n.c;)for(i=P(Fm(n),36),o=new w(i.a);o.a0&&MM(e,n,t),i):hrt(e,t,n):r}function PA(){PA=C,mIt=(vP(),V6),vIt=J6,cIt=w6,lIt=E6,uIt=D6,sIt=C6,dIt=k6,pIt=z6,k4=(Ylt(),GFt),A4=KFt,hIt=QFt,N4=tIt,gIt=$Ft,_It=eIt,fIt=JFt,j4=XFt,M4=ZFt,P4=nIt,yIt=iIt,oIt=WFt}function X9e(e,t){var n,r,i,a,o;if(e.e<=t||_ze(e,e.g,t))return e.g;for(a=e.r,r=e.g,o=e.r,i=(a-r)/2+r;r+11&&(e.e.b+=e.a)):(e.e.a+=n.a,e.e.b=r.Math.max(e.e.b,n.b),e.d.c.length>1&&(e.e.a+=e.a))}function net(e){var t,n,r,i=e.i;switch(t=i.b,r=i.j,n=i.g,i.a.g){case 0:n.a=(e.g.b.o.a-r.a)/2;break;case 1:n.a=t.d.n.a+t.d.a.a;break;case 2:n.a=t.d.n.a+t.d.a.a-r.a;break;case 3:n.b=t.d.n.b+t.d.a.b}}function ret(e,t,n){var r,i,a;for(i=new pm(Vu(EE(n).a.Kc(),new d));Cj(i);)r=P(by(i),18),!gy(r)&&!(!gy(r)&&r.c.i.c==r.d.i.c)&&(a=kat(e,r,n,new $ge),a.c.length>1&&Mr(t.c,a))}function iet(e,t,n,r,i){if(rr&&(e.a=r),e.bi&&(e.b=i),e}function aet(e){if(j(e,143))return Eot(P(e,143));if(j(e,233))return V1e(P(e,233));if(j(e,23))return D9e(P(e,23));throw E(new Fi(mCt+CA(new Wi(U(O(WW,1),FP,1,5,[e])))))}function oet(e,t,n,r,i){var a=!0,o,s;for(o=0;o>>i|n[o+r+1]<>>i,++o}return a}function set(e,t,n,r){var i,a,o;if(t.k==(DA(),qJ)){for(a=new pm(Vu(DE(t).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),o=i.c.i.k,o==qJ&&e.c.a[i.c.i.c.p]==r&&e.c.a[t.c.p]==n)return!0}return!1}function cet(e,t){var n,r,i,a;return t&=63,n=e.h&$F,t<22?(a=n>>>t,i=e.m>>t|n<<22-t,r=e.l>>t|e.m<<22-t):t<44?(a=0,i=n>>>t-22,r=e.m>>t-22|e.h<<44-t):(a=0,i=0,r=n>>>t-44),vu(r&QF,i&QF,a&$F)}function uet(e,t,n,r){var i;this.b=r,this.e=e==(sS(),g2),i=t[n],this.d=Dp(J9,[X,aL],[183,28],16,[i.length,i.length],2),this.a=Dp(q9,[X,HF],[53,28],15,[i.length,i.length],2),this.c=new N5e(t,n)}function det(e){var t,n,r;for(e.k=new URe((nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,e.j.c.length),r=new w(e.j);r.a=n)return RA(e,t,r.p),!0;return!1}function LA(e,t,n,r){var i,a,o=n.length,s,c,l;for(a=0,i=-1,l=wKe((sv(t,e.length+1),e.substr(t)),(Sf(),aK)),s=0;sa&&hPe(l,wKe(n[s],aK))&&(i=s,a=c);return i>=0&&(r[0]=t+a),i}function get(e){var t;return e.Db&64?AA(e):(t=new Gu(YSt),!e.a||gl(gl((t.a+=` "`,t),e.a),`"`),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function _et(e,t,n){var r,i,a,o,s=nM(e.e.Dh(),t);for(i=P(e.g,124),r=0,o=0;on?ptt(e,n,`start index`):t<0||t>n?ptt(t,n,`end index`):CM(`end index (%s) must not be less than start index (%s)`,U(O(WW,1),FP,1,5,[G(t),G(e)]))}function bet(e,t){var n,r,i,a;for(r=0,i=e.length;r0&&Cet(e,a,n));t.p=0}function zA(e){var t;this.c=new vo,this.f=e.e,this.e=e.d,this.i=e.g,this.d=e.c,this.b=e.b,this.k=e.j,this.a=e.a,this.j=e.i?e.i:(t=P(Ba(L3),9),new xf(t,P(Yd(t,t.length),9),0)),this.g=e.f}function wet(e){var t=jh(gl(new Gu(`Predicates.`),`and`),40),n=!0,r,i;for(i=new qn(e);i.b0?s[o-1]:V(UJ,jR,10,0,0,1),i=s[o],l=o=0?e.ki(i):Qtt(e,r);else throw E(new Fi(HH+r.xe()+UH))}else PT(e,n,r)}function ket(e){var t,n=null;if(t=!1,j(e,211)&&(t=!0,n=P(e,211).a),t||j(e,263)&&(t=!0,n=``+P(e,263).a),t||j(e,493)&&(t=!0,n=``+P(e,493).a),!t)throw E(new Ni(pCt));return n}function Aet(e,t,n){var r,i,a,o,s,c=nM(e.e.Dh(),t);for(r=0,s=e.i,i=P(e.g,124),o=0;o=e.d.b.c.length&&(t=new Eh(e.d),t.p=r.p-1,M(e.d.b,t),n=new Eh(e.d),n.p=r.p,M(e.d.b,n)),W_(r,P(Ep(e.d.b,r.p),30))}function Let(e,t,n){var r,i,a;if(!e.b[t.g]){for(e.b[t.g]=!0,r=n,!r&&(r=new zy),up(r.b,t),a=e.a[t.g].Kc();a.Ob();)i=P(a.Pb(),65),i.b!=t&&Let(e,i.b,r),i.c!=t&&Let(e,i.c,r),up(r.a,i);return r}return null}function Ret(e){switch(e.g){case 0:case 1:case 2:return nP(),Z8;case 3:case 4:case 5:return nP(),m5;case 6:case 7:case 8:return nP(),g5;case 9:case 10:case 11:return nP(),X8;default:return nP(),h5}}function zet(e,t){var n;return e.c.length!=0&&(n=b0e((ov(0,e.c.length),P(e.c[0],18)).c.i),z_(),n==(IO(),L0)||n==I0||hy(gg(new Mp(null,new cv(e,16)),new bie),new yme(t)))}function KA(e,t){if(j(t,207))return $Ce(e,P(t,27));if(j(t,193))return ewe(e,P(t,123));if(j(t,452))return QCe(e,P(t,166));throw E(new Fi(mCt+CA(new Wi(U(O(WW,1),FP,1,5,[t])))))}function Bet(e,t,n){var r,i;if(this.f=e,r=P(xh(e.b,t),260),i=r?r.a:0,RUe(n,i),n>=(i/2|0))for(this.e=r?r.c:null,this.d=i;n++0;)ux(this);this.b=t,this.a=null}function Vet(e,t){var n,r;t.a?Qot(e,t):(n=P(Do(e.b,t.b),60),n&&n==e.a[t.b.f]&&n.a&&n.a!=t.b.a&&n.c.Fc(t.b),r=P(Eo(e.b,t.b),60),r&&e.a[r.f]==t.b&&r.a&&r.a!=t.b.a&&t.b.c.Fc(r),Du(e.b,t.b))}function Het(e,t){var n=P(ig(e.b,t),127),r;if(P(P(Dy(e.r,t),21),87).dc()){n.n.b=0,n.n.c=0;return}n.n.b=e.C.b,n.n.c=e.C.c,e.A.Hc((TD(),x5))&&rlt(e,t),r=o4e(e,t),hM(e,t)==(pO(),P8)&&(r+=2*e.w),n.a.a=r}function Uet(e,t){var n=P(ig(e.b,t),127),r;if(P(P(Dy(e.r,t),21),87).dc()){n.n.d=0,n.n.a=0;return}n.n.d=e.C.d,n.n.a=e.C.a,e.A.Hc((TD(),x5))&&ilt(e,t),r=a4e(e,t),hM(e,t)==(pO(),P8)&&(r+=2*e.w),n.a.b=r}function Wet(e,t){var n,r,i,a=new T;for(r=new w(t);r.ar&&(sv(t-1,e.length),e.charCodeAt(t-1)<=32);)--t;return r>0||tn.a&&(r.Hc((eA(),e6))?i=(t.a-n.a)/2:r.Hc(n6)&&(i=t.a-n.a)),t.b>n.b&&(r.Hc((eA(),i6))?a=(t.b-n.b)/2:r.Hc(r6)&&(a=t.b-n.b)),B7e(e,i,a)}function ftt(e,t,n,r,i,a,o,s,c,l,u,d,f){j(e.Cb,90)&&$A(_y(P(e.Cb,90)),4),GS(e,n),e.f=o,tE(e,s),rE(e,c),eE(e,l),nE(e,u),RT(e,d),gE(e,f),FT(e,!0),Zx(e,i),e.Zk(a),aT(e,t),r!=null&&(e.i=null,OS(e,r))}function ptt(e,t,n){if(e<0)return CM(Hvt,U(O(WW,1),FP,1,5,[n,G(e)]));if(t<0)throw E(new Fi(Uvt+t));return CM(`%s (%s) must not be greater than size (%s)`,U(O(WW,1),FP,1,5,[n,G(e),G(t)]))}function mtt(e,t,n,r,i,a){var o=r-n,s,c,l;if(o<7){O1e(t,n,r,a);return}if(c=n+i,s=r+i,l=c+(s-c>>1),mtt(t,e,c,l,-i,a),mtt(t,e,l,s,-i,a),a.Ne(e[l-1],e[l])<=0){for(;n=0?e.bi(a,n):Pat(e,i,n);else throw E(new Fi(HH+i.xe()+UH))}else LE(e,r,i,n)}function ytt(e){var t,n;if(e.f){for(;e.n>0;){if(t=P(e.k.Xb(e.n-1),76),n=t.Lk(),j(n,102)&&(P(n,19).Bb&GH)!=0&&(!e.e||n.pk()!=R5||n.Lj()!=0)&&t.md()!=null)return!0;--e.n}return!1}return e.n>0}function btt(e){var t,n=P(e,54)._h(),r,i;if(n)try{if(r=null,t=Mj((qo(),N7),qut(H1e(n))),t&&(i=t.ai(),i&&(r=i.Fl(ave(n.e)))),r&&r!=e)return btt(r)}catch(e){if(e=ew(e),!j(e,63))throw E(e)}return e}function xtt(e,t,n){var r,i,a;n.Ug(`Remove overlaps`,1),n.dh(t,mxt),r=P(J(t,(Pd(),y4)),27),e.f=r,e.a=UO(P(J(t,(PA(),P4)),300)),i=N(J(t,(vP(),J6))),nfe(e,(Gh(i),i)),a=sM(r),Kht(e,t,a,n),n.dh(t,YV)}function Stt(e){var t,n,r;if(ki(Od(J(e,(vP(),_6))))){for(r=new T,n=new pm(Vu(Ij(e).a.Kc(),new d));Cj(n);)t=P(by(n),74),uj(t)&&ki(Od(J(t,v6)))&&Mr(r.c,t);return r}return Vg(),Vg(),QG}function Ctt(e){if(!e)return W_e(),zTt;var t=e.valueOf?e.valueOf():e;if(t!==e){var n=pG[typeof t];return n?n(t):XQe(typeof t)}return e instanceof Array||e instanceof r.Array?new xn(e):new wn(e)}function wtt(e,t,n){var i,a,o=e.o;switch(i=P(ig(e.p,n),252),a=i.i,a.b=oj(i),a.a=aj(i),a.b=r.Math.max(a.b,o.a),a.b>o.a&&!t&&(a.b=o.a),a.c=-(a.b-o.a)/2,n.g){case 1:a.d=-a.a;break;case 3:a.d=o.b}iN(i),oN(i)}function Ttt(e,t,n){var i,a,o=e.o;switch(i=P(ig(e.p,n),252),a=i.i,a.b=oj(i),a.a=aj(i),a.a=r.Math.max(a.a,o.b),a.a>o.b&&!t&&(a.a=o.b),a.d=-(a.a-o.b)/2,n.g){case 4:a.c=-a.b;break;case 2:a.c=o.a}iN(i),oN(i)}function Ett(e,t){var n,r,i,a,o;if(!t.dc()){if(i=P(t.Xb(0),131),t.gc()==1){hst(e,i,i,1,0,t);return}for(n=1;n0)try{i=GM(t,xF,AP)}catch(e){throw e=ew(e),j(e,130)?(r=e,E(new Nb(r))):E(e)}return n=(!e.a&&(e.a=new wr(e)),e.a),i=0?P(H(n,i),58):null}function jtt(e,t){if(e<0)return CM(Hvt,U(O(WW,1),FP,1,5,[`index`,G(e)]));if(t<0)throw E(new Fi(Uvt+t));return CM(`%s (%s) must be less than size (%s)`,U(O(WW,1),FP,1,5,[`index`,G(e),G(t)]))}function Mtt(e){var t,n,r,i,a;if(e==null)return IP;for(a=new UC(PP,`[`,`]`),n=e,r=0,i=n.length;r`,E(new Fi(r.a))}function Ytt(e){var t,n=-e.a;return t=U(O(K9,1),EF,28,15,[43,48,48,48,48]),n<0&&(t[0]=45,n=-n),t[1]=t[1]+((n/60|0)/10|0)&OF,t[2]=t[2]+(n/60|0)%10&OF,t[3]=t[3]+(n%60/10|0)&OF,t[4]=t[4]+n%10&OF,ND(t,0,t.length)}function Xtt(e){var t,n,r,i;for(e.g=new NE(P(ph(_5),297)),r=0,n=(nP(),Z8),t=0;t=0?e.Lh(n,!0,!0):mj(e,i,!0),160)),P(r,220).Zl(t);else throw E(new Fi(HH+t.xe()+UH))}function $tt(e){var t,n;return e>-0x800000000000&&e<0x800000000000?e==0?0:(t=e<0,t&&(e=-e),n=C_(r.Math.floor(r.Math.log(e)/.6931471805599453)),(!t||e!=r.Math.pow(2,n))&&++n,n):kXe(LC(e))}function ent(e){var t,n,r,i,a=new Rl,o,s;for(n=new w(e);n.a2&&s.e.b+s.j.b<=2&&(i=s,r=o),a.a.zc(i,a),i.q=r);return a}function tnt(e,t,n){n.Ug(`Eades radial`,1),n.dh(t,YV),e.d=P(J(t,(Pd(),y4)),27),e.c=D(N(J(t,(PA(),M4)))),e.e=UO(P(J(t,P4),300)),e.a=Q1e(P(J(t,yIt),434)),e.b=B8e(P(J(t,fIt),354)),c8e(e),n.dh(t,YV)}function nnt(e,t){if(t.Ug(`Target Width Setter`,1),qy(e,(gM(),o3)))OO(e,(xM(),Z4),N(J(e,o3)));else throw E(new zi(`A target width has to be set if the TargetWidthWidthApproximator should be used.`));t.Vg()}function rnt(e,t){var n,r=new ZO(e),i;return VC(r,t),W(r,(Y(),wQ),t),W(r,(mP(),Q1),(rA(),R8)),W(r,J$,(RO(),Y3)),En(r,(DA(),GJ)),n=new jA,G_(n,r),tj(n,(nP(),g5)),i=new jA,G_(i,r),tj(i,X8),r}function int(e){switch(e.g){case 0:return new Ti((sS(),h2));case 1:return new Oue;case 2:return new kue;default:throw E(new Fi(`No implementation is available for the crossing minimizer `+(e.f==null?``+e.g:e.f)))}}function ant(e,t){var n,r,i,a,o;for(e.c[t.p]=!0,M(e.a,t),o=new w(t.j);o.a=a)o.$b();else for(i=o.Kc(),r=0;r0?Zi():o<0&&gnt(e,t,-o),!0)}function aj(e){var t,n,r,i,a,o,s=0;if(e.b==0){for(o=N4e(e,!0),t=0,r=o,i=0,a=r.length;i0&&(s+=n,++t);t>1&&(s+=e.c*(t-1))}else s=Sve(oC(_g(hg(yPe(e.a),new et),new tt)));return s>0?s+e.n.d+e.n.a:0}function oj(e){var t,n,r,i,a,o,s=0;if(e.b==0)s=Sve(oC(_g(hg(yPe(e.a),new Qe),new $e)));else{for(o=P4e(e,!0),t=0,r=o,i=0,a=r.length;i0&&(s+=n,++t);t>1&&(s+=e.c*(t-1))}return s>0?s+e.n.b+e.n.c:0}function vnt(e){var t,n;if(e.c.length!=2)throw E(new Ii(`Order only allowed for two paths.`));t=(ov(0,e.c.length),P(e.c[0],18)),n=(ov(1,e.c.length),P(e.c[1],18)),t.d.i!=n.c.i&&(e.c.length=0,Mr(e.c,n),Mr(e.c,t))}function ynt(e,t,n){var r;for(Ql(n,t.g,t.f),$l(n,t.i,t.j),r=0;r<(!t.a&&(t.a=new F($5,t,10,11)),t.a).i;r++)ynt(e,P(H((!t.a&&(t.a=new F($5,t,10,11)),t.a),r),27),P(H((!n.a&&(n.a=new F($5,n,10,11)),n.a),r),27))}function bnt(e,t){var n,i,a,o=P(ig(e.b,t),127);for(n=o.a,a=P(P(Dy(e.r,t),21),87).Kc();a.Ob();)i=P(a.Pb(),117),i.c&&(n.a=r.Math.max(n.a,fMe(i.c)));if(n.a>0)switch(t.g){case 2:o.n.c=e.s;break;case 4:o.n.b=e.s}}function xnt(e,t){var n=P(K(t,(XM(),Xq)),17).a-P(K(e,Xq),17).a,r,i;return n==0?(r=ef(xu(P(K(e,(jS(),nJ)),8)),P(K(e,rJ),8)),i=ef(xu(P(K(t,nJ),8)),P(K(t,rJ),8)),aE(r.a*r.b,i.a*i.b)):n}function Snt(e,t){var n=P(K(t,(rN(),d4)),17).a-P(K(e,d4),17).a,r,i;return n==0?(r=ef(xu(P(K(e,(tP(),V2)),8)),P(K(e,H2),8)),i=ef(xu(P(K(t,V2),8)),P(K(t,H2),8)),aE(r.a*r.b,i.a*i.b)):n}function Cnt(e){var t,n=new ta;return n.a+=`e_`,t=DXe(e),t!=null&&(n.a+=``+t),e.c&&e.d&&(gl((n.a+=` `,n),Sk(e.c)),gl(hl((n.a+=`[`,n),e.c.i),`]`),gl((n.a+=kR,n),Sk(e.d)),gl(hl((n.a+=`[`,n),e.d.i),`]`)),n.a}function wnt(e){switch(e.g){case 0:return new Rue;case 1:return new zue;case 2:return new Iue;case 3:return new Fue;default:throw E(new Fi(`No implementation is available for the layout phase `+(e.f==null?``+e.g:e.f)))}}function Tnt(e,t,n,i,a){var o=0;switch(a.g){case 1:o=r.Math.max(0,t.b+e.b-(n.b+i));break;case 3:o=r.Math.max(0,-e.b-i);break;case 2:o=r.Math.max(0,-e.a-i);break;case 4:o=r.Math.max(0,t.a+e.a-(n.a+i))}return o}function Ent(e,t,n){var r,i,a,o,s;if(n)for(i=n.a.length,r=new hm(i),s=(r.b-r.a)*r.c<0?($o(),G9):new Ru(r);s.Ob();)o=P(s.Pb(),17),a=Pv(n,o.a),sCt in a.a||cU in a.a?zlt(e,a,t):J_t(e,a,t),STe(P(xh(e.b,RD(a)),74))}function Dnt(e){var t,n;switch(e.b){case-1:return!0;case 0:return n=e.t,n>1||n==-1?(e.b=-1,!0):(t=Ik(e),t&&(Qo(),t.lk()==xwt)?(e.b=-1,!0):(e.b=1,!1));default:case 1:return!1}}function Ont(e,t){var n,r,i,a;if(hP(e),e.c!=0||e.a!=123)throw E(new Ui(TP((fu(),FCt))));if(a=t==112,r=e.d,n=fd(e.i,125,r),n<0)throw E(new Ui(TP((fu(),ICt))));return i=p_(e.i,r,n),e.d=n+1,dGe(i,a,(e.e&512)==512)}function knt(e){var t,n,r=e.a.c.length,i,a,o,s;if(r>0)for(o=e.c.d,s=e.d.d,i=ku(ef(new k(s.a,s.b),o),1/(r+1)),a=new k(o.a,o.b),n=new w(e.a);n.a=0&&r=0?e.Lh(n,!0,!0):mj(e,i,!0),160)),P(r,220).Wl(t);throw E(new Fi(HH+t.xe()+WH))}function Pnt(){Qbe();var e;return pHt?P(Mj((qo(),N7),iW),2038):(Ol(YW,new Wce),Pht(),e=P(j(v_((qo(),N7),iW),560)?v_(N7,iW):new MFe,560),pHt=!0,Avt(e),Bvt(e),Qh((Jbe(),UVt),e,new oce),H_(N7,iW,e),e)}function Fnt(e,t){var n,r,i,a;e.j=-1,Gl(e.e)?(n=e.i,a=e.i!=0,Ty(e,t),r=new Hb(e.e,3,e.c,null,t,n,a),i=t.zl(e.e,e.c,null),i=E5e(e,t,i),i?(i.nj(r),i.oj()):AC(e.e,r)):(Ty(e,t),i=t.zl(e.e,e.c,null),i&&i.oj())}function lj(e,t){var n,r,i=0;if(r=t[0],r>=e.length)return-1;for(n=(sv(r,e.length),e.charCodeAt(r));n>=48&&n<=57&&(i=i*10+(n-48),++r,!(r>=e.length));)n=(sv(r,e.length),e.charCodeAt(r));return r>t[0]?t[0]=r:i=-1,i}function Int(e){var t,n,i,a=P(e.a,17).a,o=P(e.b,17).a;return n=a,i=o,t=r.Math.max(r.Math.abs(a),r.Math.abs(o)),a<=0&&a==o?(n=0,i=o-1):a==-t&&o!=t?(n=o,i=a,o>=0&&++n):(n=-o,i=a),new Kc(G(n),G(i))}function Lnt(e,t,n,r){var i,a,o,s,c,l;for(i=0;i=0&&l>=0&&c=e.i)throw E(new Mi(yU+t+bU+e.i));if(n>=e.i)throw E(new Mi(xU+n+bU+e.i));return r=e.g[n],t!=n&&(t>16),t=r>>16&16,n=16-t,e>>=t,r=e-256,t=r>>16&8,n+=t,e<<=t,r=e-uI,t=r>>16&4,n+=t,e<<=t,r=e-ZP,t=r>>16&2,n+=t,e<<=t,r=e>>14,t=r&~(r>>1),n+2-t)}function znt(e){Ug();var t,n,r,i;for(zq=new T,Rq=new Dr,Lq=new T,t=(!e.a&&(e.a=new F($5,e,10,11)),e.a),$gt(t),i=new Lu(t);i.e!=i.i.gc();)r=P(gO(i),27),Ab(zq,r,0)==-1&&(n=new T,M(Lq,n),g2e(r,n));return Lq}function Bnt(e,t,n){var r,i,a,o;e.a=n.b.d,j(t,326)?(i=cM(P(t,74),!1,!1),a=FA(i),r=new npe(e),ly(a,r),cN(a,i),t.of((vP(),x6))!=null&&ly(P(t.of(x6),75),r)):(o=P(t,422),o.rh(o.nh()+e.a.a),o.sh(o.oh()+e.a.b))}function Vnt(e,t){var n,r,i=new T;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),n.c.g==e.g&&A(K(n.b,(rN(),p4)))!==A(K(n.c,p4))&&!hy(new Mp(null,new cv(i,16)),new jme(n))&&Mr(i.c,n);return hu(i,new oae),i}function Hnt(e,t,n){var r,i,a,o;return j(t,153)&&j(n,153)?(a=P(t,153),o=P(n,153),e.a[a.a][o.a]+e.a[o.a][a.a]):j(t,250)&&j(n,250)&&(r=P(t,250),i=P(n,250),r.a==i.a)?P(K(i.a,(XM(),Xq)),17).a:0}function Unt(e,t){var n,i,a,o,s,c,l,u=D(N(K(t,(mP(),S0))));for(l=e[0].n.a+e[0].o.a+e[0].d.c+u,c=1;c=0?n:(s=Ih(ef(new k(o.c+o.b/2,o.d+o.a/2),new k(a.c+a.b/2,a.d+a.a/2))),-(gdt(a,o)-1)*s)}function Gnt(e,t,n){var r;To(new Mp(null,(!n.a&&(n.a=new F(W5,n,6,6)),new cv(n.a,16))),new CSe(e,t)),To(new Mp(null,(!n.n&&(n.n=new F(Q5,n,1,7)),new cv(n.n,16))),new wSe(e,t)),r=P(J(n,(vP(),x6)),75),r&&eC(r,e,t)}function mj(e,t,n){var r,i,a=HN((UA(),l9),e.Dh(),t);if(a)return Qo(),P(a,69).xk()||(a=mv(Rb(l9,a))),i=(r=e.Ih(a),P(r>=0?e.Lh(r,!0,!0):mj(e,a,!0),160)),P(i,220).Sl(t,n);throw E(new Fi(HH+t.xe()+WH))}function Knt(e,t,n,r){var i=e.d[t],a,o,s,c;if(i){if(a=i.g,c=i.i,r!=null){for(s=0;s=n&&(r=t,l=(c.c+c.a)/2,o=l-n,c.c<=l-n&&(i=new Bf(c.c,o),Jp(e,r++,i)),s=l+n,s<=c.a&&(a=new Bf(s,c.a),av(r,e.c.length),Ts(e.c,r,a)))}function $nt(e,t,n){var r,i,a,o,s,c;if(!t.dc()){for(i=new vo,c=t.Kc();c.Ob();)for(s=P(c.Pb(),40),Qh(e.a,G(s.g),G(n)),o=(r=dO(new hr(s).a.d,0),new gr(r));Za(o.a);)a=P(Lv(o.a),65).c,iy(i,a,i.c.b,i.c);$nt(e,i,n+1)}}function ert(e){var t;if(!e.c&&e.g==null)e.d=e.bj(e.f),tb(e,e.d),t=e.d;else if(e.g==null)return!0;else if(e.i==0)return!1;else t=P(e.g[e.i-1],51);return t==e.b&&null.Vm>=null.Um()?(Pj(e),ert(e)):t.Ob()}function trt(e){if(this.a=e,e.c.i.k==(DA(),GJ))this.c=e.c,this.d=P(K(e.c.i,(Y(),TQ)),64);else if(e.d.i.k==GJ)this.c=e.d,this.d=P(K(e.d.i,(Y(),TQ)),64);else throw E(new Fi(`Edge `+e+` is not an external edge.`))}function nrt(e,t){var n,r,i=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,i,e.b)),t?t!=e&&(GS(e,t.zb),$x(e,t.d),n=(r=t.c,r??t.zb),SS(e,n==null||ff(n,t.zb)?null:n)):(GS(e,null),$x(e,0),SS(e,null))}function rrt(e,t){var n;this.e=(gh(),ph(e),gh(),pD(e)),this.c=(ph(t),pD(t)),vTe(this.e.Rd().dc()==this.c.Rd().dc()),this.d=D1e(this.e),this.b=D1e(this.c),n=Dp(WW,[X,FP],[5,1],5,[this.e.Rd().gc(),this.c.Rd().gc()],2),this.a=n,sJe(this)}function irt(e){var t=(!aG&&(aG=v_t()),aG);return`"`+e.replace(/[\x00-\x1f\xad\u0600-\u0603\u06dd\u070f\u17b4\u17b5\u200b-\u200f\u2028-\u202e\u2060-\u2064\u206a-\u206f\ufeff\ufff9-\ufffb"\\]/g,function(e){return BLe(e,t)})+`"`}function art(e,t,n,i,a,o){var s,c,l,u,d;if(a!=0)for(A(e)===A(n)&&(e=e.slice(t,t+a),t=0),l=n,c=t,u=t+a;c=o)throw E(new lf(t,o));return i=n[t],o==1?r=null:(r=V(g7,FU,424,o-1,0,1),tN(n,0,r,0,t),a=o-t-1,a>0&&tN(n,t+1,r,t,a)),iO(e,r),ntt(e,t,i),i}function lrt(e){var t,n;if(e.f){for(;e.n0?GE(n):YT(GE(n))),OO(t,t0,a)}function prt(e,t){var n;t.Ug(`Partition preprocessing`,1),n=P(ay(hg(ox(hg(new Mp(null,new cv(e.a,16)),new nne),new rne),new ine),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),To(n.Oc(),new ane),t.Vg()}function mrt(e,t){var n,r,i,a,o=e.j;for(t.a!=t.b&&hu(o,new Fre),i=o.c.length/2|0,r=0;r0&&MM(e,n,t),a):r.a==null?i.a==null?0:(MM(e,n,t),1):(MM(e,t,n),-1)}function grt(e,t){var n,r,i=t.b.b,a,o;for(e.a=V(JW,BL,15,i,0,1),e.b=V(J9,aL,28,i,16,1),o=dO(t.b,0);o.b!=o.d.c;)a=P(Lv(o),40),e.a[a.g]=new vo;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),e.a[n.b.g].Fc(n),e.a[n.c.g].Fc(n)}function _rt(e,t){var n,r,i,a;e.Pj()?(n=e.Ej(),a=e.Qj(),++e.j,e.qj(n,e.Zi(n,t)),r=e.Ij(3,null,t,n,a),e.Mj()?(i=e.Nj(t,null),i?(i.nj(r),i.oj()):e.Jj(r)):e.Jj(r)):(oFe(e,t),e.Mj()&&(i=e.Nj(t,null),i&&i.oj()))}function vrt(e,t,n){var r,i,a;e.Pj()?(a=e.Qj(),jT(e,t,n),r=e.Ij(3,null,n,t,a),e.Mj()?(i=e.Nj(n,null),e.Tj()&&(i=e.Uj(n,i)),i?(i.nj(r),i.oj()):e.Jj(r)):e.Jj(r)):(jT(e,t,n),e.Mj()&&(i=e.Nj(n,null),i&&i.oj()))}function _j(e,t){var n,r,i,a,o=nM(e.e.Dh(),t);for(i=new an,n=P(e.g,124),a=e.i;--a>=0;)r=n[a],o.am(r.Lk())&&tb(i,r);!E_t(e,i)&&Gl(e.e)&&Kr(e,t.Jk()?s_(e,6,t,(Vg(),QG),null,-1,!1):s_(e,t.tk()?2:1,t,null,null,-1,!1))}function yrt(e,t){var n,r,i,a,o;return e.a==(TA(),BZ)||(a=t.a.c,n=t.a.c+t.a.b,!(t.j&&(r=t.A,o=r.c.c.a-r.o.a/2,i=a-(r.n.a+r.o.a),i>o)||t.q&&(r=t.C,o=r.c.c.a-r.o.a/2,i=r.n.a-n,i>o)))}function brt(e){B_();var t,n=new ry,r,i,a,o,s;for(i=new w(e.e.b);i.a1?e.e*=D(e.a):e.f/=D(e.a),HQe(e),a2e(e),clt(e),W(e.b,(bO(),Nq),e.g)}function Ert(e,t,n){var r=0,i,a,o,s,c=n;for(t||(r=n*(e.c.length-1),c*=-1),a=new w(e);a.a=0?e.Ah(null):e.Ph().Th(e,-1-t,null,null)),e.Bh(P(i,54),n),r&&r.oj(),e.vh()&&e.wh()&&n>-1&&AC(e,new Sm(e,9,n,a,i)),i):a}function Rrt(e,t){var n,r,i,a=e.b.Ce(t),o;for(r=(n=e.a.get(a),n??V(WW,FP,1,0,5,1)),o=0;o>5,i>=e.d)return e.e<0;if(n=e.a[i],t=1<<(t&31),e.e<0){if(r=FYe(e),i>16)),15).dd(a),s0&&(!(ql(e.a.c)&&t.n.d)&&!(Jl(e.a.c)&&t.n.b)&&(t.g.d+=r.Math.max(0,i/2-.5)),!(ql(e.a.c)&&t.n.a)&&!(Jl(e.a.c)&&t.n.c)&&(t.g.a-=i-1))}function Xrt(e){var t,n,i,a=new T,o=idt(e,a);if(t=P(K(e,(Y(),QQ)),10),t)for(i=new w(t.j);i.a>t,a=e.m>>t|n<<22-t,i=e.l>>t|e.m<<22-t):t<44?(o=r?$F:0,a=n>>t-22,i=e.m>>t-22|n<<44-t):(o=r?$F:0,a=r?QF:0,i=n>>t-44),vu(i&QF,a&QF,o&$F)}function wj(e){var t,n,i,a,o,s;for(this.c=new T,this.d=e,i=cI,a=cI,t=lI,n=lI,s=dO(e,0);s.b!=s.d.c;)o=P(Lv(s),8),i=r.Math.min(i,o.a),a=r.Math.min(a,o.b),t=r.Math.max(t,o.a),n=r.Math.max(n,o.b);this.a=new wg(i,a,t-i,n-a)}function eit(e,t){var n,r,i,a,o,s;for(a=new w(e.b);a.a0&&j(t,44)&&(e.a._j(),l=P(t,44),c=l.ld(),a=c==null?0:US(c),o=MDe(e.a,a),n=e.a.d[o],n)){for(r=P(n.g,379),u=n.i,s=0;s=2)for(n=a.Kc(),t=N(n.Pb());n.Ob();)o=t,t=N(n.Pb()),i=r.Math.min(i,(Gh(t),t-(Gh(o),o)));return i}function vit(e,t){var n,r,i=new T;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),n.b.g==e.g&&!ff(n.b.c,LV)&&A(K(n.b,(rN(),p4)))!==A(K(n.c,p4))&&!hy(new Mp(null,new cv(i,16)),new Mme(n))&&Mr(i.c,n);return hu(i,new uae),i}function yit(e,t){var n,r,i;if(A(t)===A(ph(e)))return!0;if(!j(t,15)||(r=P(t,15),i=e.gc(),i!=r.gc()))return!1;if(j(r,59)){for(n=0;n0&&(i=n),o=new w(e.f.e);o.a0?(--t,--n):r>=0&&i<0?(t+=1,n+=1):r>0&&i>=0?(--t,n+=1):(t+=1,--n),new Kc(G(t),G(n))}function Fit(e,t){return e.ct.c?1:e.bt.b?1:e.a==t.a?e.d==(Vv(),b2)&&t.d==y2?-1:+(e.d==y2&&t.d==b2):US(e.a)-US(t.a)}function Iit(e,t){var n,r,i,a=t.a,o=a.c.i==t.b?a.d:a.c;return r=a.c.i==t.b?a.c:a.d,i=g0e(e.a,o,r),i>0&&i0):i<0&&-i0)}function Lit(e,t,n,r){var i=(t-e.d)/e.c.c.length,a=0,o,s,c,l,u,d;for(e.a+=n,e.d=t,d=new w(e.c);d.a>24;return o}function zit(e){if(e.ze()){var t=e.c;e.o=t.Ae()?`[`+t.n:t.ze()?`[`+t.xe():`[L`+t.xe()+`;`,e.b=t.we()+`[]`,e.k=t.ye()+`[]`;return}var n=e.j,r=e.d;r=r.split(`/`),e.o=MD(`.`,[n,MD(`$`,r)]),e.b=MD(`.`,[n,MD(`.`,r)]),e.k=r[r.length-1]}function Bit(e,t){var n,r,i,a,o=null;for(a=new w(e.e.a);a.a=0;t-=2)for(n=0;n<=t;n+=2)(e.b[n]>e.b[n+2]||e.b[n]===e.b[n+2]&&e.b[n+1]>e.b[n+3])&&(r=e.b[n+2],e.b[n+2]=e.b[n],e.b[n]=r,r=e.b[n+3],e.b[n+3]=e.b[n+1],e.b[n+1]=r);e.c=!0}}function Jit(e,t){var n,r,i,a,o,s,c,l=-1,u=0;for(o=e,s=0,c=o.length;s0&&++u;++l}return u}function Aj(e){var t,n=new Gu(Ha(e.Rm));return n.a+=`@`,gl(n,(t=US(e)>>>0,t.toString(16))),e.Vh()?(n.a+=` (eProxyURI: `,hl(n,e._h()),e.Kh()&&(n.a+=` eClass: `,hl(n,e.Kh())),n.a+=`)`):e.Kh()&&(n.a+=` (eClass: `,hl(n,e.Kh()),n.a+=`)`),n.a}function jj(e){var t,n,r,i;if(e.e)throw E(new Ii((Ad(wK),qI+wK.k+JI)));for(e.d==(GT(),r8)&&ZN(e,t8),n=new w(e.a.a);n.a>24}return n}function $it(e,t,n){var r,i=P(ig(e.i,t),314),a;if(!i){if(i=new JKe(e.d,t,n),zm(e.i,t,i),PD(t))Qwe(e.a,t.c,t.b,i);else switch(a=Ret(t),r=P(ig(e.p,a),252),a.g){case 1:case 3:i.j=!0,Oi(r,t.b,i);break;case 4:case 2:i.k=!0,Oi(r,t.c,i)}}return i}function eat(e,t){var n,r,i,a,o,s,c=dd(e.c-e.b&e.a.length-1),l=null,u=null;for(a=new fg(e);a.a!=a.b;)i=P(cT(a),10),n=(s=P(K(i,(Y(),zQ)),12),s?s.i:null),r=(o=P(K(i,BQ),12),o?o.i:null),(l!=n||u!=r)&&(Ort(c,t),l=n,u=r),Mr(c.c,i);Ort(c,t)}function tat(e,t,n,r){var i,a,o,s=new an,c=nM(e.e.Dh(),t),l;if(i=P(e.g,124),Qo(),P(t,69).xk())for(o=0;o=0)return a;for(o=1,c=new w(t.j);c.a=0)return a;for(o=1,c=new w(t.j);c.a0&&t.Ne((ov(i-1,e.c.length),P(e.c[i-1],10)),a)>0;)uy(e,i,(ov(i-1,e.c.length),P(e.c[i-1],10))),--i;ov(i,e.c.length),e.c[i]=a}n.a=new Dr,n.b=new Dr}function aat(e,t,n){var r,i,a,o,s,c,l,u=(r=P(t.e&&t.e(),9),new xf(r,P(Yd(r,r.length),9),0));for(c=nN(n,`[\\[\\]\\s,]+`),a=c,o=0,s=a.length;o=0?(t||(t=new ea,r>0&&pl(t,(Zy(0,r,e.length),e.substr(0,r)))),t.a+=`\\`,Ah(t,n&OF)):t&&Ah(t,n&OF);return t?t.a:e}function sat(e){var t,n,i;for(n=new w(e.a.a.b);n.a0&&(!(ql(e.a.c)&&t.n.d)&&!(Jl(e.a.c)&&t.n.b)&&(t.g.d-=r.Math.max(0,i/2-.5)),!(ql(e.a.c)&&t.n.a)&&!(Jl(e.a.c)&&t.n.c)&&(t.g.a+=r.Math.max(0,i-1)))}function cat(e,t,n){var r,i;if((e.c-e.b&e.a.length-1)==2)t==(nP(),Z8)||t==X8?(Sx(P(yw(e),15),(kk(),y8)),Sx(P(yw(e),15),b8)):(Sx(P(yw(e),15),(kk(),b8)),Sx(P(yw(e),15),y8));else for(i=new fg(e);i.a!=i.b;)r=P(cT(i),15),Sx(r,n)}function lat(e,t){var n,r,i=Xf(new Phe(e)),a,o,s=new bv(i,i.c.length),c;for(a=Xf(new Phe(t)),c=new bv(a,a.c.length),o=null;s.b>0&&c.b>0&&(n=(jd(s.b>0),P(s.a.Xb(s.c=--s.b),27)),r=(jd(c.b>0),P(c.a.Xb(c.c=--c.b),27)),n==r);)o=n;return o}function uat(e,t,n){var r,i,a,o;Yze(e,t)>Yze(e,n)?(r=SE(n,(nP(),X8)),e.d=r.dc()?0:fp(P(r.Xb(0),12)),o=SE(t,g5),e.b=o.dc()?0:fp(P(o.Xb(0),12))):(i=SE(n,(nP(),g5)),e.d=i.dc()?0:fp(P(i.Xb(0),12)),a=SE(t,X8),e.b=a.dc()?0:fp(P(a.Xb(0),12)))}function dat(e,t){var n=e.o.a,r,i,a;for(a=P(P(Dy(e.r,t),21),87).Kc();a.Ob();)i=P(a.Pb(),117),i.e.a=n*D(N(i.b.of(uq))),i.e.b=(r=i.b,r.pf((vP(),F6))?r.ag()==(nP(),Z8)?-r.Mf().b-D(N(r.of(F6))):D(N(r.of(F6))):r.ag()==(nP(),Z8)?-r.Mf().b:0)}function fat(e,t){var n,r,i,a;for(t.Ug(`Self-Loop pre-processing`,1),r=new w(e.a);r.ae.c));o++)i.a>=e.s&&(a<0&&(a=o),s=o);return c=(e.s+e.c)/2,a>=0&&(r=Llt(e,t,a,s),c=Kbe((ov(r,t.c.length),P(t.c[r],339))),Qnt(t,r,n)),c}function Nj(e,t,n){var r,i,a,o=(a=new Vse,a),s,c,l;for(FJe(o,(Gh(t),t)),l=(!o.b&&(o.b=new Td((CP(),$7),o9,o)),o.b),c=1;c0&&ymt(this,i)}function gat(e,t,n,r,i,a){var o,s,c;if(!i[t.a]){for(i[t.a]=!0,o=r,!o&&(o=new Py),M(o.e,t),c=a[t.a].Kc();c.Ob();)s=P(c.Pb(),290),s.d!=n&&s.c!=n&&(s.c!=t&&gat(e,s.c,t,o,i,a),s.d!=t&&gat(e,s.d,t,o,i,a),M(o.c,s),nw(o.d,s.b));return o}return null}function _at(e){var t=0,n,r,i,a,o,s;for(i=new w(e.e);i.a=2}function vat(e,t,n,r,i){var a=e.c.d.j,o=P(SO(n,0),8),s,c,l,u;for(u=1;u1||(t=Zp(w8,U(O(M8,1),Z,95,0,[C8,E8])),BC(b_(t,e))>1)||(r=Zp(j8,U(O(M8,1),Z,95,0,[A8,k8])),BC(b_(r,e))>1))}function bat(e,t,n){var r,i,a;for(a=new w(e.t);a.a0&&(r.b.n-=r.c,r.b.n<=0&&r.b.u>0&&up(t,r.b));for(i=new w(e.i);i.a0&&(r.a.u-=r.c,r.a.u<=0&&r.a.n>0&&up(n,r.a))}function Pj(e){var t,n,r,i,a;if(e.g==null&&(e.d=e.bj(e.f),tb(e,e.d),e.c))return a=e.f,a;if(t=P(e.g[e.i-1],51),i=t.Pb(),e.e=t,n=e.bj(i),n.Ob())e.d=n,tb(e,n);else for(e.d=null;!t.Ob()&&(Sh(e.g,--e.i,null),e.i!=0);)r=P(e.g[e.i-1],51),t=r;return i}function xat(e,t){var n,r=t,i=r.Lk(),a,o,s;if(aM(e.e,i)){if(i.Si()&&Kv(e,i,r.md()))return!1}else for(s=nM(e.e.Dh(),i),n=P(e.g,124),a=0;a1||n>1)return 2;return t+n==1?2:0}function Lj(e,t){var n,i,a,o=e.a*OI+e.b*1502,s,c=e.b*OI+11;return n=r.Math.floor(c*kI),o+=n,c-=n*AI,o%=AI,e.a=o,e.b=c,t<=24?r.Math.floor(e.a*cK[t]):(a=e.a*(1<=2147483648&&(i-=4294967296),i)}function jat(e,t,n){var r,i,a=new T,o,s,c,l=new vo;for(o=new vo,Pft(e,l,o,t),Zmt(e,l,o,t,n),c=new w(e);c.ar.b.g&&Mr(a.c,r);return a}function Mat(e,t,n){var r,i,a,o,s=e.c,c;for(o=(n.q?n.q:(Vg(),Vg(),$G)).vc().Kc();o.Ob();)a=P(o.Pb(),44),r=!Xa(hg(new Mp(null,new cv(s,16)),new rr(new gSe(t,a)))).Bd((wo(),SK)),r&&(c=a.md(),j(c,4)&&(i=UD(c),i!=null&&(c=i)),t.qf(P(a.ld(),149),c))}function Nat(e,t,n){var r,i;if(cg(e.b),Um(e.b,(KT(),m3),(Ho(),O3)),Um(e.b,h3,t.g),Um(e.b,g3,t.a),e.a=BN(e.b,t),n.Ug(`Compaction by shrinking a tree`,e.a.c.length),t.i.c.length>1)for(i=new w(e.a);i.a=0?e.Lh(r,!0,!0):mj(e,a,!0),160)),P(i,220).Xl(t,n)}else throw E(new Fi(HH+t.xe()+UH))}function Rj(e,t){var n,r,i,a,o;if(t){for(a=j(e.Cb,90)||j(e.Cb,102),o=!a&&j(e.Cb,331),r=new Lu((!t.a&&(t.a=new Vp(t,j7,t)),t.a));r.e!=r.i.gc();)if(n=P(gO(r),89),i=ZM(n),a?j(i,90):o?j(i,156):i)return i;return a?(CP(),J7):(CP(),q7)}return null}function Fat(e,t){var n,r,i,a;for(t.Ug(`Resize child graph to fit parent.`,1),r=new w(e.b);r.a=2*t&&M(n,new Bf(o[r-1]+t,o[r]-t));return n}function Rat(e,t,n){var r,i,a,o,s,c,l,u;if(n)for(a=n.a.length,r=new hm(a),s=(r.b-r.a)*r.c<0?($o(),G9):new Ru(r);s.Ob();)o=P(s.Pb(),17),i=Pv(n,o.a),i&&(c=IVe(e,(l=(Ia(),u=new s_e,u),t&&Yat(l,t),l),i),CS(c,Fv(i,dU)),sA(i,c),ktt(i,c),Cw(e,i,c))}function zj(e){var t,n,r,i,a,o;if(!e.j){if(o=new qse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(l_(e));r.e!=r.i.gc();)n=P(gO(r),29),i=zj(n),th(o,i),tb(o,n);t.a.Bc(e)}Kw(o),e.j=new El((P(H(R((vh(),z7).o),11),19),o.i),o.g),_y(e).b&=-33}return e.j}function zat(e){var t,n,r,i;if(e==null)return null;if(r=EN(e,!0),i=EW.length,ff(r.substr(r.length-i,i),EW)){if(n=r.length,n==4){if(t=(sv(0,r.length),r.charCodeAt(0)),t==43)return UHt;if(t==45)return HHt}else if(n==3)return UHt}return new jge(r)}function Bat(e){var t,n=e.l,r;return n&n-1||(r=e.m,r&r-1)||(t=e.h,t&t-1)||t==0&&r==0&&n==0?-1:t==0&&r==0&&n!=0?lJe(n):t==0&&r!=0&&n==0?lJe(r)+22:t!=0&&r==0&&n==0?lJe(t)+44:-1}function Bj(e,t){var n,r,i=t.a&e.f,a=null,o;for(r=e.b[i];;r=r.b){if(r==t){a?a.b=t.b:e.b[i]=t.b;break}a=r}for(o=t.f&e.f,a=null,n=e.c[o];;n=n.d){if(n==t){a?a.d=t.d:e.c[o]=t.d;break}a=n}t.e?t.e.c=t.c:e.a=t.c,t.c?t.c.e=t.e:e.e=t.e,--e.i,++e.g}function Vat(e,t){var n;t.d?t.d.b=t.b:e.a=t.b,t.b?t.b.d=t.d:e.e=t.d,!t.e&&!t.c?(n=P(Wh(P(My(e.b,t.a),260)),260),n.a=0,++e.c):(n=P(Wh(P(xh(e.b,t.a),260)),260),--n.a,t.e?t.e.c=t.c:n.b=P(Wh(t.c),511),t.c?t.c.e=t.e:n.c=P(Wh(t.e),511)),--e.d}function Hat(e){var t,n=e.o,i,a,o,s,c,l,u,d;for(t=e.p,s=AP,a=xF,c=AP,o=xF,u=0;u0),a.a.Xb(a.c=--a.b),qd(a,i),jd(a.b3&&Ub(e,0,t-3))}function Kat(e){var t,n,r,i;return A(K(e,(mP(),D1)))===A((_T(),g8))?!e.e&&A(K(e,d1))!==A((qC(),eQ)):(r=P(K(e,f1),299),i=ki(Od(K(e,m1)))||A(K(e,h1))===A((bS(),$X)),t=P(K(e,u1),17).a,n=e.a.c.length,!i&&r!=(qC(),eQ)&&(t==0||t>n))}function qat(e){for(var t,n=0;n0);n++);if(n>0&&n0);t++);return t>0&&n>16!=6&&t){if(Pk(e,t))throw E(new Fi(JH+xrt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?b6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,6,r)),r=jDe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,6,t,t))}function Hj(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=3&&t){if(Pk(e,t))throw E(new Fi(JH+ipt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?P6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,12,r)),r=Bd(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t))}function Yat(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=9&&t){if(Pk(e,t))throw E(new Fi(JH+Dlt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?S6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,9,r)),r=Vd(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,9,t,t))}function Uj(e){var t,n,r=Ik(e),i,a=e.j;if(a==null&&r)return e.Jk()?null:r.ik();if(j(r,156)){if(n=r.jk(),n&&(i=n.wi(),i!=e.i)){if(t=P(r,156),t.nk())try{e.g=i.ti(t,a)}catch(t){if(t=ew(t),j(t,82))e.g=null;else throw E(t)}e.i=i}return e.g}return null}function Xat(e){var t=new T;return M(t,new fs(new k(e.c,e.d),new k(e.c+e.b,e.d))),M(t,new fs(new k(e.c,e.d),new k(e.c,e.d+e.a))),M(t,new fs(new k(e.c+e.b,e.d+e.a),new k(e.c+e.b,e.d))),M(t,new fs(new k(e.c+e.b,e.d+e.a),new k(e.c,e.d+e.a))),t}function Zat(e){var t,n,r;if(e==null)return IP;try{return PE(e)}catch(i){if(i=ew(i),j(i,103))return t=i,r=Ha($w(e))+`@`+(n=(yo(),VD(e)>>>0),n.toString(16)),x2e(AXe(),(Co(),`Exception during lenientFormat for `+r),t),`<`+r+` threw `+Ha(t.Rm)+`>`;throw E(i)}}function Qat(e,t,n){var r,i,a;for(a=t.a.ec().Kc();a.Ob();)i=P(a.Pb(),74),r=P(xh(e.b,i),272),!r&&(I_(xA(i))==I_(SA(i))?$ot(e,i,n):xA(i)==I_(SA(i))?xh(e.c,i)==null&&xh(e.b,SA(i))!=null&&Eht(e,i,n,!1):xh(e.d,i)==null&&xh(e.b,xA(i))!=null&&Eht(e,i,n,!0))}function $at(e,t){var n,r,i,a,o,s,c;for(i=e.Kc();i.Ob();)for(r=P(i.Pb(),10),s=new jA,G_(s,r),tj(s,(nP(),X8)),W(s,(Y(),ZQ),(rd(),!0)),o=t.Kc();o.Ob();)a=P(o.Pb(),10),c=new jA,G_(c,a),tj(c,g5),W(c,ZQ,!0),n=new i_,W(n,ZQ,!0),U_(n,s),K_(n,c)}function eot(e,t,n,r){var i=P0e(e,t,n),a=P0e(e,n,t),o=P(xh(e.c,t),118),s=P(xh(e.c,n),118);i1)for(t=Yu((n=new Qr,++e.b,n),e.d),s=dO(a,0);s.b!=s.d.c;)o=P(Lv(s),125),tM(Ao(ko(jo(Oo(new Zr,1),0),t),o))}function iot(e,t,n){var r,i,a,o,s;for(n.Ug(`Breaking Point Removing`,1),e.a=P(K(t,(mP(),S1)),223),a=new w(t.b);a.a>16!=11&&t){if(Pk(e,t))throw E(new Fi(JH+Elt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?F6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,10,r)),r=tf(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,11,t,t))}function aot(e){var t,n,r,i;for(r=new EC(new Fn(e.b).a);r.b;)n=MS(r),i=P(n.ld(),12),t=P(n.md(),10),W(t,(Y(),WQ),i),W(i,QQ,t),W(i,jQ,(rd(),!0)),tj(i,P(K(t,TQ),64)),K(t,TQ),W(i.i,(mP(),Q1),(rA(),B8)),P(K(Bh(i.i),OQ),21).Fc((uM(),YZ))}function oot(e,t,n){var r,i,a=0,o=0,s,c;if(e.c)for(c=new w(e.d.i.j);c.aa.a?-1:i.ac){for(u=e.d,e.d=V(SVt,awt,66,2*c+4,0,1),a=0;a=0x8000000000000000?($b(),hG):(i=!1,e<0&&(i=!0,e=-e),r=0,e>=nI&&(r=C_(e/nI),e-=r*nI),n=0,e>=tI&&(n=C_(e/tI),e-=n*tI),t=C_(e),a=vu(t,n,r),i&&ww(a),a)}function bot(e){var t,n,r,i,a=new T;if(Dx(e.b,new qfe(a)),e.b.c.length=0,a.c.length!=0){for(t=(ov(0,a.c.length),P(a.c[0],82)),n=1,r=a.c.length;n=-t&&i==t?new Kc(G(n-1),G(i)):new Kc(G(n),G(i-1))}function wot(){return yP(),U(O(MOt,1),Z,81,0,[_Y,mY,vY,PY,$Y,RY,aX,UY,ZY,kY,qY,HY,QY,TY,sX,cY,KY,tX,FY,eX,lX,YY,lY,XY,uX,rX,cX,IY,SY,LY,NY,oX,fY,bY,BY,dY,VY,jY,EY,WY,OY,hY,pY,MY,DY,GY,iX,uY,JY,AY,zY,CY,xY,nX,yY,wY,gY])}function Tot(e,t,n){e.d=0,e.b=0,t.k==(DA(),YJ)&&n.k==YJ&&P(K(t,(Y(),WQ)),10)==P(K(n,WQ),10)&&(jb(t).j==(nP(),Z8)?uat(e,t,n):uat(e,n,t)),t.k==YJ&&n.k==qJ?jb(t).j==(nP(),Z8)?e.d=1:e.b=1:n.k==YJ&&t.k==qJ&&(jb(n).j==(nP(),Z8)?e.b=1:e.d=1),G4e(e,t,n)}function Eot(e){var t,n,r,i,a,o,s,c,l,u,d=m7e(e);return t=e.a,c=t!=null,c&&sp(d,`category`,e.a),i=eo(new Pn(e.d)),o=!i,o&&(l=new Tn,hx(d,`knownOptions`,l),n=new Ahe(l),ly(new Pn(e.d),n)),a=eo(e.g),s=!a,s&&(u=new Tn,hx(d,`supportedFeatures`,u),r=new jhe(u),ly(e.g,r)),d}function Dot(e){var t,n,r=!1,i,a,o,s,c,l;for(t=336,n=0,a=new cOe(e.length),s=e,c=0,l=s.length;c>16!=7&&t){if(Pk(e,t))throw E(new Fi(JH+get(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?x6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=P(t,54).Rh(e,1,B5,r)),r=jNe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,7,t,t))}function Aot(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=3&&t){if(Pk(e,t))throw E(new Fi(JH+L$e(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?T6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=P(t,54).Rh(e,0,G5,r)),r=MNe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t))}function Xj(e,t){pM();var n,r,i,a,o,s,c,l,u;return t.d>e.d&&(s=e,e=t,t=s),t.d<63?Rst(e,t):(o=(e.d&-2)<<4,l=TUe(e,o),u=TUe(t,o),r=TN(e,xy(l,o)),i=TN(t,xy(u,o)),c=Xj(l,u),n=Xj(r,i),a=Xj(TN(l,r),TN(i,u)),a=VN(VN(a,c),n),a=xy(a,o),c=xy(c,o<<1),VN(VN(c,a),n))}function Zj(){Zj=C,N0=new Xs(Qbt,0),OMt=new Xs(`LONGEST_PATH`,1),kMt=new Xs(`LONGEST_PATH_SOURCE`,2),A0=new Xs(`COFFMAN_GRAHAM`,3),DMt=new Xs(JR,4),AMt=new Xs(`STRETCH_WIDTH`,5),M0=new Xs(`MIN_WIDTH`,6),k0=new Xs(`BF_MODEL_ORDER`,7),j0=new Xs(`DF_MODEL_ORDER`,8)}function jot(e,t,n){var r,i,a,o=ET(e,n),s=V(UJ,jR,10,t.length,0,1);for(r=0,a=o.Kc();a.Ob();)i=P(a.Pb(),12),ki(Od(K(i,(Y(),jQ))))&&(s[r++]=P(K(i,QQ),10));if(r=0;a+=n?1:-1)o|=t.c.lg(c,a,n,r&&!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,(Y(),i$))))),o|=t.q.ug(c,a,n),o|=Qct(e,c[a],n,r);return Lm(e.c,t),o}function eM(e,t,n){var r,i,a,o,s,c,l,u,d,f;for(u=GBe(e.j),d=0,f=u.length;d1&&(e.a=!0),_Ne(P(n.b,68),$d(xu(P(t.b,68).c),ku(ef(xu(P(n.b,68).a),P(t.b,68).a),i))),ARe(e,t),Iot(e,n)}function Lot(e){var t,n,r,i,a,o,s;for(a=new w(e.a.a);a.a0&&a>0?o.p=t++:r>0?o.p=n++:a>0?o.p=i++:o.p=n++}Vg(),hu(e.j,new Zte)}function zot(e){var t,n=null;t=P(Ep(e.g,0),18);do{if(n=t.d.i,yd(n,(Y(),BQ)))return P(K(n,BQ),12).i;if(n.k!=(DA(),JJ)&&Cj(new pm(Vu(OE(n).a.Kc(),new d))))t=P(by(new pm(Vu(OE(n).a.Kc(),new d))),18);else if(n.k!=JJ)return null}while(n&&n.k!=(DA(),JJ));return n}function Bot(e,t){var n,r,i,a,o,s=t.j,c,l,u;for(o=t.g,c=P(Ep(s,s.c.length-1),113),u=(ov(0,s.c.length),P(s.c[0],113)),l=gk(e,o,c,u),a=1;al&&(c=n,u=i,l=r);t.a=u,t.c=c}function Vot(e,t,n){var r,i,a,o,s,c,l=new Ja(new mme(e));for(o=U(O(EOt,1),Sbt,12,0,[t,n]),s=0,c=o.length;sc-e.b&&sc-e.a&&s0?a.a?(s=a.b.Mf().a,n>s&&(i=(n-s)/2,a.d.b=i,a.d.c=i)):a.d.c=e.s+n:ym(e.u)&&(r=S7e(a.b),r.c<0&&(a.d.b=-r.c),r.c+r.b>a.b.Mf().a&&(a.d.c=r.c+r.b-a.b.Mf().a))}function sst(e,t){var n,r,i,a,o=new T;n=t;do a=P(xh(e.b,n),131),a.B=n.c,a.D=n.d,Mr(o.c,a),n=P(xh(e.k,n),18);while(n);return r=(ov(0,o.c.length),P(o.c[0],131)),r.j=!0,r.A=P(r.d.a.ec().Kc().Pb(),18).c.i,i=P(Ep(o,o.c.length-1),131),i.q=!0,i.C=P(i.d.a.ec().Kc().Pb(),18).d.i,o}function cst(e){var t=P(e.a,17).a,n=P(e.b,17).a;if(t>=0){if(t==n)return new Kc(G(-t-1),G(-t-1));if(t==-n)return new Kc(G(-t),G(n+1))}return r.Math.abs(t)>r.Math.abs(n)?t<0?new Kc(G(-t),G(n)):new Kc(G(-t),G(n+1)):new Kc(G(t+1),G(n))}function lst(e){var t,n=P(K(e,(mP(),M1)),171);t=P(K(e,(Y(),MQ)),311),n==(XE(),h$)?(W(e,M1,v$),W(e,MQ,(Zb(),oQ))):n==_$?(W(e,M1,v$),W(e,MQ,(Zb(),iQ))):t==(Zb(),oQ)?(W(e,M1,h$),W(e,MQ,aQ)):t==iQ&&(W(e,M1,_$),W(e,MQ,aQ))}function rM(){rM=C,O2=new Uie,aPt=vp(new Zh,(vA(),bJ),(yP(),FY)),cPt=tm(vp(new Zh,bJ,YY),SJ,JY),lPt=HD(HD(Go(tm(vp(new Zh,vJ,aX),SJ,iX),xJ),rX),oX),oPt=tm(vp(vp(vp(new Zh,yJ,RY),xJ,BY),xJ,VY),SJ,zY),sPt=tm(vp(vp(new Zh,xJ,VY),xJ,bY),SJ,yY)}function iM(){iM=C,fPt=vp(tm(new Zh,(vA(),SJ),(yP(),CY)),bJ,FY),gPt=HD(HD(Go(tm(vp(new Zh,vJ,aX),SJ,iX),xJ),rX),oX),pPt=tm(vp(vp(vp(new Zh,yJ,RY),xJ,BY),xJ,VY),SJ,zY),hPt=vp(vp(new Zh,bJ,YY),SJ,JY),mPt=tm(vp(vp(new Zh,xJ,VY),xJ,bY),SJ,yY)}function ust(e,t,n,r,i){var a,o;(!gy(t)&&t.c.i.c==t.d.i.c||!WJe(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])),n))&&!gy(t)&&(t.c==i?md(t.a,0,new Vl(n)):up(t.a,new Vl(n)),r&&!mo(e.a,n)&&(o=P(K(t,(mP(),j1)),75),o||(o=new ai,W(t,j1,o)),a=new Vl(n),iy(o,a,o.c.b,o.c),Lm(e.a,a)))}function dst(e,t){var n,r,i,a=nm(bE(uF,ng(nm(bE(t==null?0:US(t),dF)),15)));for(n=a&e.b.length-1,i=null,r=e.b[n];r;i=r,r=r.a)if(r.d==a&&zh(r.i,t))return i?i.a=r.a:e.b[n]=r.a,dve(P(Wh(r.c),604),P(Wh(r.f),604)),Nr(P(Wh(r.b),227),P(Wh(r.e),227)),--e.f,++e.e,!0;return!1}function fst(e){var t,n;for(n=new pm(Vu(DE(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),18),t.c.i.k!=(DA(),KJ))throw E(new zi(LR+xk(e)+`' has its layer constraint set to FIRST, but has at least one incoming edge that does not come from a FIRST_SEPARATE node. That must not happen.`))}function pst(e,t,n){var r,i=K$e(e.Db&254),a,o,s,c,l;if(i==0)e.Eb=n;else{if(i==1)s=V(WW,FP,1,2,5,1),a=pk(e,t),a==0?(s[0]=n,s[1]=e.Eb):(s[0]=e.Eb,s[1]=n);else for(s=V(WW,FP,1,i+1,5,1),o=rS(e.Eb),r=2,c=0,l=0;r<=128;r<<=1)r==t?s[l++]=n:(e.Db&r)!=0&&(s[l++]=o[c++]);e.Eb=s}e.Db|=t}function mst(e,t,n){var i,a,o,s;for(this.b=new T,a=0,i=0,s=new w(e);s.a0&&(o=P(Ep(this.b,0),176),a+=o.o,i+=o.p),a*=2,i*=2,t>1?a=C_(r.Math.ceil(a*t)):i=C_(r.Math.ceil(i/t)),this.a=new iD(a,i)}function hst(e,t,n,i,a,o){var s,c,l,u,d=i,f,p,m,h,g,_,v;for(t.j&&t.o?(m=P(xh(e.f,t.A),60),g=m.d.c+m.d.b,--d):g=t.a.c+t.a.b,f=a,n.q&&n.o?(m=P(xh(e.f,n.C),60),u=m.d.c,++f):u=n.a.c,_=u-g,l=r.Math.max(2,f-d),c=_/l,h=g+c,p=d;p=0;o+=i?1:-1){for(s=t[o],c=r==(nP(),X8)?i?SE(s,r):UE(SE(s,r)):i?UE(SE(s,r)):SE(s,r),a&&(e.c[s.p]=c.gc()),d=c.Kc();d.Ob();)u=P(d.Pb(),12),e.d[u.p]=l++;nw(n,c)}}function vst(e,t,n){var r,i,a=D(N(e.b.Kc().Pb())),o,s,c,l=D(N(OXe(t.b))),u;for(r=ku(xu(e.a),l-n),i=ku(xu(t.a),n-a),u=$d(r,i),ku(u,1/(l-a)),this.a=u,this.b=new T,s=!0,o=e.b.Kc(),o.Pb();o.Ob();)c=D(N(o.Pb())),s&&c-n>AV&&(this.b.Fc(n),s=!1),this.b.Fc(c);s&&this.b.Fc(n)}function yst(e){var t,n,r,i;if(Blt(e,e.n),e.d.c.length>0){for(Ki(e.c);Jrt(e,P(z(new w(e.e.a)),125))>5,i,a,o;if(t&=31,r>=e.d)return e.e<0?(AM(),JTt):(AM(),JG);if(a=e.d-r,i=V(q9,HF,28,a+1,15,1),oet(i,a,e.a,r,t),e.e<0){for(n=0;n0&&e.a[n]<<32-t){for(n=0;n=0?!1:(n=HN((UA(),l9),i,t),!n||(r=n.Ik(),(r>1||r==-1)&&qh(Rb(l9,n))!=3))):!1}function Est(e,t,n,r){var i,a,o,s=cA(P(H((!t.b&&(t.b=new cf(H5,t,4,7)),t.b),0),84)),c=cA(P(H((!t.c&&(t.c=new cf(H5,t,5,8)),t.c),0),84));return I_(s)==I_(c)||Ex(c,s)?null:(o=T_(t),o==n?r:(a=P(xh(e.a,o),10),a&&(i=a.e,i)?i:null))}function Dst(e,t,n){var r,i,a,o,s;for(n.Ug(`Longest path to source layering`,1),e.a=t,s=e.a.a,e.b=V(q9,HF,28,s.c.length,15,1),r=0,o=new w(s);o.a0&&(n[0]+=e.d,s-=n[0]),n[2]>0&&(n[2]+=e.d,s-=n[2]),o=r.Math.max(0,s),n[1]=r.Math.max(n[1],s),FUe(e,ZK,a.c+i.b+n[0]-(n[1]-s)/2,n),t==ZK&&(e.c.b=o,e.c.c=a.c+i.b+(o-s)/2)}function Vst(){this.c=V(Z9,hI,28,(nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,15,1),this.b=V(Z9,hI,28,U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5]).length,15,1),this.a=V(Z9,hI,28,U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5]).length,15,1),rxe(this.c,cI),rxe(this.b,lI),rxe(this.a,lI)}function oM(e,t,n){var r,i,a,o;if(t<=n?(i=t,a=n):(i=n,a=t),r=0,e.b==null)e.b=V(q9,HF,28,2,15,1),e.b[0]=i,e.b[1]=a,e.c=!0;else{if(r=e.b.length,e.b[r-1]+1==i){e.b[r-1]=a;return}o=V(q9,HF,28,r+2,15,1),tN(e.b,0,o,0,r),e.b=o,e.b[r-1]>=i&&(e.c=!1,e.a=!1),e.b[r++]=i,e.b[r]=a,e.c||kj(e)}}function Hst(e,t,n){var r,i,a,o,s,c,l=t.d;for(e.a=new Hy(l.c.length),e.c=new Dr,s=new w(l);s.a=0?e.Lh(l,!1,!0):mj(e,n,!1),61));n:for(a=d.Kc();a.Ob();){for(i=P(a.Pb(),58),u=0;u1;)lM(i,i.i-1);return r}function Yst(e,t){var n=new Iu,r,i,a,o,s,c;for(a=new w(e.b);a.ae.d[o.p]&&(n+=$He(e.b,a),Rv(e.a,G(a)));for(;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function Zst(e){var t,n,r,i,a,o,s,c,l;for(e.a=new Zd,l=0,i=0,r=new w(e.i.b);r.ac.d&&(d=c.d+c.a+u));n.c.d=d,t.a.zc(n,t),l=r.Math.max(l,n.c.d+n.c.a)}return l}function uM(){uM=C,WZ=new Gs(`COMMENTS`,0),KZ=new Gs(`EXTERNAL_PORTS`,1),qZ=new Gs(`HYPEREDGES`,2),JZ=new Gs(`HYPERNODES`,3),YZ=new Gs(`NON_FREE_PORTS`,4),XZ=new Gs(`NORTH_SOUTH_PORTS`,5),QZ=new Gs(Bbt,6),UZ=new Gs(`CENTER_LABELS`,7),GZ=new Gs(`END_LABELS`,8),ZZ=new Gs(`PARTITIONS`,9)}function ect(e,t,n,r,i){return r<0?(r=LA(e,i,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF]),t),r<0&&(r=LA(e,i,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]),t)),r<0?!1:(n.k=r,!0)):r>0&&(n.k=r-1,!0)}function tct(e,t,n,r,i){return r<0?(r=LA(e,i,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF]),t),r<0&&(r=LA(e,i,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]),t)),r<0?!1:(n.k=r,!0)):r>0&&(n.k=r-1,!0)}function nct(e,t,n,r,i,a){var o,s=32,c,l;if(r<0){if(t[0]>=e.length||(s=mg(e,t[0]),s!=43&&s!=45)||(++t[0],r=lj(e,t),r<0))return!1;s==45&&(r=-r)}return s==32&&t[0]-n==2&&i.b==2&&(c=new uo,l=c.q.getFullYear()-VF+VF-80,o=l%100,a.a=r==o,r+=(l/100|0)*100+(r=0?yD(e):Xm(yD(kb(e)))),ZG[t]=sl(cm(e,t),0)?yD(cm(e,t)):Xm(yD(kb(cm(e,t)))),e=bE(e,5);for(;t=u&&(l=i);l&&(d=r.Math.max(d,l.a.o.a)),d>p&&(f=u,p=d)}return f}function uct(e){var t,n,r,i,a=new Ja(P(ph(new dt),50)),o,s=lI;for(n=new w(e.d);n.ajxt?hu(l,e.b):i<=jxt&&i>Mxt?hu(l,e.d):i<=Mxt&&i>Nxt?hu(l,e.c):i<=Nxt&&hu(l,e.a),o=pct(e,l,o);return a}function mct(e,t,n,r){var i=(r.c+r.a)/2,a,o,s,c,l;for(Fg(t.j),up(t.j,i),Fg(n.e),up(n.e,i),l=new Xve,s=new w(e.f);s.a1,s&&(r=new k(i,n.b),up(t.a,r)),_S(t.a,U(O(K3,1),X,8,0,[f,d]))}function yct(e,t,n){var r,i;for(t=48;n--)M9[n]=n-48<<24>>24;for(r=70;r>=65;r--)M9[r]=r-65+10<<24>>24;for(i=102;i>=97;i--)M9[i]=i-97+10<<24>>24;for(a=0;a<10;a++)N9[a]=48+a&OF;for(e=10;e<=15;e++)N9[e]=65+e-10&OF}function Sct(e,t){t.Ug(`Process graph bounds`,1),W(e,(tP(),K2),uc(sC(_g(new Mp(null,new cv(e.b,16)),new bae)))),W(e,q2,uc(sC(_g(new Mp(null,new cv(e.b,16)),new xae)))),W(e,zPt,uc(oC(_g(new Mp(null,new cv(e.b,16)),new Sae)))),W(e,BPt,uc(oC(_g(new Mp(null,new cv(e.b,16)),new Cae)))),t.Vg()}function Cct(e){var t,n,i,a=P(K(e,(mP(),W1)),21),o=P(K(e,q1),21);n=new k(e.f.a+e.d.b+e.d.c,e.f.b+e.d.d+e.d.a),t=new Vl(n),a.Hc((TD(),v5))&&(i=P(K(e,K1),8),o.Hc((UM(),T5))&&(i.a<=0&&(i.a=20),i.b<=0&&(i.b=20)),t.a=r.Math.max(n.a,i.a),t.b=r.Math.max(n.b,i.b)),ki(Od(K(e,G1)))||qft(e,n,t)}function wct(e,t){var n,r,i,a;for(a=SE(t,(nP(),m5)).Kc();a.Ob();)r=P(a.Pb(),12),n=P(K(r,(Y(),QQ)),10),n&&tM(Ao(ko(jo(Oo(new Zr,0),.1),e.i[t.p].d),e.i[n.p].a));for(i=SE(t,Z8).Kc();i.Ob();)r=P(i.Pb(),12),n=P(K(r,(Y(),QQ)),10),n&&tM(Ao(ko(jo(Oo(new Zr,0),.1),e.i[n.p].d),e.i[t.p].a))}function _M(e){var t,n,r,i,a,o;if(!e.c){if(o=new Hse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(Jv(e));r.e!=r.i.gc();)n=P(gO(r),89),i=ZM(n),j(i,90)&&th(o,_M(P(i,29))),tb(o,n);t.a.Bc(e),t.a.gc()}l0e(o),Kw(o),e.c=new El((P(H(R((vh(),z7).o),15),19),o.i),o.g),_y(e).b&=-33}return e.c}function Tct(e){var t;if(e.c!=10)throw E(new Ui(TP((fu(),TU))));switch(t=e.a,t){case 110:t=10;break;case 114:t=13;break;case 116:t=9;break;case 92:case 124:case 46:case 94:case 45:case 63:case 42:case 43:case 123:case 125:case 40:case 41:case 91:case 93:break;default:throw E(new Ui(TP((fu(),MU))))}return t}function Ect(e){var t,n,r,i,a;if(e.l==0&&e.m==0&&e.h==0)return`0`;if(e.h==eI&&e.m==0&&e.l==0)return`-9223372036854775808`;if(e.h>>19)return`-`+Ect(mw(e));for(n=e,r=``;n.l!=0||n.m!=0||n.h!=0;){if(i=Cy(rI),n=_mt(n,i,!0),t=``+iye(mG),n.l!=0||n.m!=0||n.h!=0)for(a=9-t.length;a>0;a--)t=`0`+t;r=t+r}return r}function Dct(e){var t=!1,n=0,r,i,a,o,s;for(i=new w(e.d.b);i.a=e.a||!U5e(t,n))return-1;if(Iv(P(i.Kb(t),20)))return 1;for(a=0,s=P(i.Kb(t),20).Kc();s.Ob();)if(o=P(s.Pb(),18),l=o.c.i==t?o.d.i:o.c.i,c=jct(e,l,n,i),c==-1||(a=r.Math.max(a,c),a>e.c-1))return-1;return a+1}function Mct(e,t){var n,r,i,a,o,s;if(A(t)===A(e))return!0;if(!j(t,15)||(r=P(t,15),s=e.gc(),r.gc()!=s))return!1;if(o=r.Kc(),e.Yi()){for(n=0;n0){if(e._j(),t!=null){for(a=0;a>24;case 97:case 98:case 99:case 100:case 101:case 102:return e-97+10<<24>>24;case 65:case 66:case 67:case 68:case 69:case 70:return e-65+10<<24>>24;default:throw E(new aa(`Invalid hexadecimal`))}}function vM(){vM=C,qK=new ps(`SPIRAL`,0),HK=new ps(`LINE_BY_LINE`,1),UK=new ps(`MANHATTAN`,2),VK=new ps(`JITTER`,3),GK=new ps(`QUADRANTS_LINE_BY_LINE`,4),KK=new ps(`QUADRANTS_MANHATTAN`,5),WK=new ps(`QUADRANTS_JITTER`,6),BK=new ps(`COMBINE_LINE_BY_LINE_MANHATTAN`,7),zK=new ps(`COMBINE_JITTER_MANHATTAN`,8)}function Lct(e,t,n,r){var i,a,o,s,c=Gk(e,n),l=Gk(t,n);for(i=!1;c&&l&&(r||B3e(c,l,n));)o=Gk(c,n),s=Gk(l,n),Fb(t),Fb(e),a=c.c,WN(c,!1),WN(l,!1),n?(Ak(t,l.p,a),t.p=l.p,Ak(e,c.p+1,a),e.p=c.p):(Ak(e,c.p,a),e.p=c.p,Ak(t,l.p+1,a),t.p=l.p),W_(c,null),W_(l,null),c=o,l=s,i=!0;return i}function Rct(e){switch(e.g){case 0:return new Cue;case 1:return new xue;case 3:return new Lbe;case 4:return new cie;case 5:return new rOe;case 6:return new Sue;case 2:return new bue;case 7:return new mue;case 8:return new gue;default:throw E(new Fi(`No implementation is available for the layerer `+(e.f==null?``+e.g:e.f)))}}function zct(e,t,n,r){var i=!1,a=!1,o,s,c;for(s=new w(r.j);s.a=t.length)throw E(new Mi(`Greedy SwitchDecider: Free layer not in graph.`));this.c=t[e],this.e=new hf(r),RS(this.e,this.c,(nP(),g5)),this.i=new hf(r),RS(this.i,this.c,X8),this.f=new YMe(this.c),this.a=!a&&i.i&&!i.s&&this.c[0].k==(DA(),GJ),this.a&&Eet(this,e,t.length)}function Uct(e,t){var n,r,i,a=!e.B.Hc((UM(),C5)),o=e.B.Hc(E5),s;e.a=new d0e(o,a,e.c),e.n&&Lg(e.a.n,e.n),Oi(e.g,(Ix(),ZK),e.a),t||(r=new $D(1,a,e.c),r.n.a=e.k,zm(e.p,(nP(),Z8),r),i=new $D(1,a,e.c),i.n.d=e.k,zm(e.p,m5,i),s=new $D(0,a,e.c),s.n.c=e.k,zm(e.p,g5,s),n=new $D(0,a,e.c),n.n.b=e.k,zm(e.p,X8,n))}function Wct(e){var t=P(K(e.d,(mP(),S1)),223),n,r;switch(t.g){case 2:n=B_t(e);break;case 3:n=(r=new T,To(hg(gg(ox(ox(new Mp(null,new cv(e.d.b,16)),new pre),new mre),new hre),new ere),new Wpe(r)),r);break;default:throw E(new Ii(`Compaction not supported for `+t+` edges.`))}rmt(e,n),ly(new Pn(e.g),new Hpe(e))}function Gct(e,t){var n,r,i,a,o,s,c;if(t.Ug(`Process directions`,1),n=P(K(e,(rN(),c4)),88),n!=(GT(),e8))for(i=dO(e.b,0);i.b!=i.d.c;){switch(r=P(Lv(i),40),s=P(K(r,(tP(),o4)),17).a,c=P(K(r,s4),17).a,n.g){case 4:c*=-1;break;case 1:a=s,s=c,c=a;break;case 2:o=s,s=-c,c=o}W(r,o4,G(s)),W(r,s4,G(c))}t.Vg()}function Kct(e,t){var n=new Ot;return t&&VC(n,P(xh(e.a,B5),96)),j(t,422)&&VC(n,P(xh(e.a,V5),96)),j(t,366)?(VC(n,P(xh(e.a,Q5),96)),n):(j(t,84)&&VC(n,P(xh(e.a,H5),96)),j(t,207)?(VC(n,P(xh(e.a,$5),96)),n):j(t,193)?(VC(n,P(xh(e.a,e7),96)),n):(j(t,326)&&VC(n,P(xh(e.a,U5),96)),n))}function qct(e){var t,n,r,i,a,o,s,c=new rUe;for(s=new w(e.a);s.a0&&t=0)return!1;if(t.p=n.b,M(n.e,t),i==(DA(),qJ)||i==YJ){for(o=new w(t.j);o.ae.d[s.p]&&(n+=$He(e.b,a),Rv(e.a,G(a)))):++o;for(n+=e.b.d*o;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function glt(e){var t,n,r,i,a=0,o;return t=Ik(e),t.kk()&&(a|=4),(e.Bb&RU)!=0&&(a|=2),j(e,102)?(n=P(e,19),i=qO(n),(n.Bb&GH)!=0&&(a|=32),i&&(bh(L_(i)),a|=8,o=i.t,(o>1||o==-1)&&(a|=16),(i.Bb&GH)!=0&&(a|=64)),(n.Bb&pI)!=0&&(a|=zU),a|=pF):j(t,469)?a|=512:(r=t.kk(),r&&r.i&1&&(a|=256)),e.Bb&512&&(a|=128),a}function _lt(e,t){var n;return e.f==f9?(n=qh(Rb((UA(),l9),t)),e.e?n==4&&t!=(gj(),g9)&&t!=(gj(),p9)&&t!=(gj(),m9)&&t!=(gj(),h9):n==2):e.d&&(e.d.Hc(t)||e.d.Hc(mv(Rb((UA(),l9),t)))||e.d.Hc(HN((UA(),l9),e.b,t)))?!0:e.f&&cot((UA(),e.f),ug(Rb(l9,t)))?(n=qh(Rb(l9,t)),e.e?n==4:n==2):!1}function vlt(e){var t,n,r,i,a,o,s,c,l,u,d,f=-1,p=0;for(l=e,u=0,d=l.length;u0&&++p;++f}return p}function ylt(e,t,n,i){var a,o,s=P(J(n,(vP(),V6)),8),c,l=s.a,u,d=s.b+e,f;return a=r.Math.atan2(d,l),a<0&&(a+=JV),a+=t,a>JV&&(a-=JV),c=P(J(i,V6),8),u=c.a,f=c.b+e,o=r.Math.atan2(f,u),o<0&&(o+=JV),o+=t,o>JV&&(o-=JV),uu(),fS(1e-10),r.Math.abs(a-o)<=1e-10||a==o||isNaN(a)&&isNaN(o)?0:ao?1:Pl(isNaN(a),isNaN(o))}function wM(e){var t,n,r,i,a,o,s=new Dr;for(r=new w(e.a.b);r.a=e.o)throw E(new e_e);s=t>>5,o=t&31,a=cm(1,nm(cm(o,1))),i?e.n[n][s]=dv(e.n[n][s],a):e.n[n][s]=uv(e.n[n][s],Wje(a)),a=cm(a,1),r?e.n[n][s]=dv(e.n[n][s],a):e.n[n][s]=uv(e.n[n][s],Wje(a))}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function Slt(e,t,n,r){var i,a,o,s,c,l,u,d,f=new Ja(new pme(e));for(s=U(O(UJ,1),jR,10,0,[t,n]),c=0,l=s.length;c0&&(r=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!r||gl(gl((t.a+=` "`,t),r),`"`))),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function Dlt(e){var t,n,r;return e.Db&64?AA(e):(t=new Gu(ZSt),n=e.k,n?gl(gl((t.a+=` "`,t),n),`"`):(!e.n&&(e.n=new F(Q5,e,1,7)),e.n.i>0&&(r=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!r||gl(gl((t.a+=` "`,t),r),`"`))),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function Olt(e,t){var n,r,i,a,o;for(t==(Nw(),o2)&&JA(P(Dy(e.a,(tA(),TX)),15)),i=P(Dy(e.a,(tA(),TX)),15).Kc();i.Ob();)switch(r=P(i.Pb(),105),n=P(Ep(r.j,0),113).d.j,a=new bf(r.j),hu(a,new Sre),t.g){case 2:lA(e,a,n,(kS(),AX),1);break;case 1:case 0:o=qat(a),lA(e,new $_(a,0,o),n,(kS(),AX),0),lA(e,new $_(a,o,a.c.length),n,AX,1)}}function DM(e,t){var n,r,i,a,o,s,c;if(t==null||t.length==0)return null;if(i=P(v_(e.a,t),143),!i){for(r=(s=new Bn(e.b).a.vc().Kc(),new Vn(s));r.a.Ob();)if(n=(a=P(r.a.Pb(),44),P(a.md(),143)),o=n.c,c=t.length,ff(o.substr(o.length-c,c),t)&&(t.length==o.length||mg(o,o.length-t.length-1)==46)){if(i)return null;i=n}i&&H_(e.a,t,i)}return i}function klt(e,t){var n=new _t,r=P(ay(gg(new Mp(null,new cv(e.f,16)),n),Eb(new Ee,new De,new Pe,new Fe,U(O(xK,1),Z,108,0,[(Zw(),bK),yK]))),21),i=r.gc(),a;return r=P(ay(gg(new Mp(null,new cv(t.f,16)),n),Eb(new Ee,new De,new Pe,new Fe,U(O(xK,1),Z,108,0,[bK,yK]))),21),a=r.gc(),ii.p?(tj(a,m5),a.d&&(s=a.o.b,t=a.a.b,a.a.b=s-t)):a.j==m5&&i.p>e.p&&(tj(a,Z8),a.d&&(s=a.o.b,t=a.a.b,a.a.b=-(s-t)));break}return i}function OM(e,t,n,r,i){var a,o,s,c,l,u,d;if(!(j(t,207)||j(t,366)||j(t,193)))throw E(new Fi(`Method only works for ElkNode-, ElkLabel and ElkPort-objects.`));return o=e.a/2,c=t.i+r-o,u=t.j+i-o,l=c+t.g+e.a,d=u+t.f+e.a,a=new ai,up(a,new k(c,u)),up(a,new k(c,d)),up(a,new k(l,d)),up(a,new k(l,u)),s=new wj(a),VC(s,t),n&&Qh(e.b,t,s),s}function kM(e,t,n){var r,i,a=new k(t,n),o,s,c,l,u,d,f;for(u=new w(e.a);u.a1,s&&(r=new k(i,n.b),up(t.a,r)),_S(t.a,U(O(K3,1),X,8,0,[f,d]))}function FM(){FM=C,Y0=new ec(wR,0),q0=new ec(`NIKOLOV`,1),J0=new ec(`NIKOLOV_PIXEL`,2),VMt=new ec(`NIKOLOV_IMPROVED`,3),HMt=new ec(`NIKOLOV_IMPROVED_PIXEL`,4),BMt=new ec(`DUMMYNODE_PERCENTAGE`,5),UMt=new ec(`NODECOUNT_PERCENTAGE`,6),X0=new ec(`NO_BOUNDARY`,7),G0=new ec(`MODEL_ORDER_LEFT_TO_RIGHT`,8),K0=new ec(`MODEL_ORDER_RIGHT_TO_LEFT`,9)}function Jlt(e){var t,n,r=e.length,i,a;for(t=new ea,a=0;a=40,o&&Ldt(e),Opt(e),yst(e),n=o1e(e),r=0;n&&r0&&up(e.f,a)):(e.c[o]-=l+1,e.c[o]<=0&&e.a[o]>0&&up(e.e,a))))}function but(e,t,n,r){var i,a,o,s,c=new k(n,r),l,u;for(ef(c,P(K(t,(tP(),H2)),8)),u=dO(t.b,0);u.b!=u.d.c;)l=P(Lv(u),40),$d(l.e,c),up(e.b,l);for(s=P(ay(gRe(new Mp(null,new cv(t.a,16))),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15).Kc();s.Ob();){for(o=P(s.Pb(),65),a=dO(o.a,0);a.b!=a.d.c;)i=P(Lv(a),8),i.a+=c.a,i.b+=c.b;up(e.a,o)}}function xut(e,t){var n,r,i,a;if(0<(j(e,16)?P(e,16).gc():Wv(e.Kc()))){if(i=t,1=0&&ca*2?(u=new Fx(d),l=Lp(o)/Ip(o),c=cP(u,t,new ni,n,r,i,l),$d(Cl(u.e),c),d.c.length=0,a=0,Mr(d.c,u),Mr(d.c,o),a=Lp(u)*Ip(u)+Lp(o)*Ip(o)):(Mr(d.c,o),a+=Lp(o)*Ip(o));return d}function Eut(e,t){var n,r,i,a,o,s=P(K(t,(mP(),Q1)),101);if(s==(rA(),z8)||s==R8)for(i=new k(t.f.a+t.d.b+t.d.c,t.f.b+t.d.d+t.d.a).b,o=new w(e.a);o.an?t:n;l<=d;++l)l==n?s=r++:(a=i[l],u=m.am(a.Lk()),l==t&&(c=l==d&&!u?r-1:r),u&&++r);return f=P(QT(e,t,n),76),s!=c&&Kr(e,new db(e.e,7,o,G(s),p.md(),c)),f}}else return P(dj(e,t,n),76);return P(QT(e,t,n),76)}function Out(e,t){var n,r,i,a,o,s,c;for(t.Ug(`Port order processing`,1),c=P(K(e,(mP(),oMt)),430),r=new w(e.b);r.a=0&&(s=q3e(e,o),!(s&&(l<22?c.l|=1<>>1,o.m=u>>>1|(d&1)<<21,o.l=f>>>1|(u&1)<<21,--l;return n&&ww(c),a&&(r?(mG=mw(e),i&&(mG=NXe(mG,($b(),gG)))):mG=vu(e.l,e.m,e.h)),c}function Mut(e,t){var n,r,i,a,o,s,c,l=e.e[t.c.p][t.p]+1,u,d;for(c=t.c.a.c.length+1,s=new w(e.a);s.a0&&(sv(0,e.length),e.charCodeAt(0)==45||(sv(0,e.length),e.charCodeAt(0)==43))),r=o;rn)throw E(new aa(sI+e+`"`));return s}function Nut(e){var t,n,i,a,o,s=new vo,c;for(o=new w(e.a);o.a1)&&t==1&&P(e.a[e.b],10).k==(DA(),KJ)?hN(P(e.a[e.b],10),(kk(),y8)):r&&(!n||(e.c-e.b&e.a.length-1)>1)&&t==1&&P(e.a[e.c-1&e.a.length-1],10).k==(DA(),KJ)?hN(P(e.a[e.c-1&e.a.length-1],10),(kk(),b8)):(e.c-e.b&e.a.length-1)==2?(hN(P(yw(e),10),(kk(),y8)),hN(P(yw(e),10),b8)):eat(e,i),uHe(e)}function Lut(e,t,n){var i,a,o=0,s,c;for(a=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));a.e!=a.i.gc();)i=P(gO(a),27),s=``,(!i.n&&(i.n=new F(Q5,i,1,7)),i.n).i==0||(s=P(H((!i.n&&(i.n=new F(Q5,i,1,7)),i.n),0),135).a),c=new Ow(o++,t,s),VC(c,i),W(c,(tP(),t4),i),c.e.b=i.j+i.f/2,c.f.a=r.Math.max(i.g,1),c.e.a=i.i+i.g/2,c.f.b=r.Math.max(i.f,1),up(t.b,c),XA(n.f,i,c)}function Rut(e){var t,n,r=P(K(e,(Y(),WQ)),27),i,a=P(J(r,(mP(),W1)),181).Hc((TD(),x5));e.e||(i=P(K(e,OQ),21),t=new k(e.f.a+e.d.b+e.d.c,e.f.b+e.d.d+e.d.a),i.Hc((uM(),KZ))?(OO(r,Q1,(rA(),R8)),iP(r,t.a,t.b,!1,!0)):ki(Od(J(r,G1)))||iP(r,t.a,t.b,!0,!0)),a?OO(r,W1,sE(x5)):OO(r,W1,(n=P(Ba(S5),9),new xf(n,P(Yd(n,n.length),9),0)))}function zut(e,t,n){var r,i,a,o;if(t[0]>=e.length)return n.o=0,!0;switch(mg(e,t[0])){case 43:i=1;break;case 45:i=-1;break;default:return n.o=0,!0}if(++t[0],a=t[0],o=lj(e,t),o==0&&t[0]==a)return!1;if(t[0]s&&(s=i,u.c.length=0),i==s&&M(u,new Kc(n.c.i,n)));Vg(),hu(u,e.c),Jp(e.b,c.p,u)}}function Uut(e,t){var n,r,i,a,o,s,c,l,u;for(o=new w(t.b);o.as&&(s=i,u.c.length=0),i==s&&M(u,new Kc(n.d.i,n)));Vg(),hu(u,e.c),Jp(e.f,c.p,u)}}function Wut(e,t){var n,r,i,a,o,s,c,l=Od(K(t,(rN(),gFt)));if(l==null||(Gh(l),l)){for(grt(e,t),i=new T,c=dO(t.b,0);c.b!=c.d.c;)o=P(Lv(c),40),n=Let(e,o,null),n&&(VC(n,t),Mr(i.c,n));if(e.a=null,e.b=null,i.c.length>1)for(r=new w(i);r.a=0&&s!=n&&(a=new Sm(e,1,s,o,null),r?r.nj(a):r=a),n>=0&&(a=new Sm(e,1,n,s==n?o:null,t),r?r.nj(a):r=a)),r}function qut(e){var t,n,r;if(e.b==null){if(r=new $i,e.i!=null&&(pl(r,e.i),r.a+=`:`),e.f&256){for(e.f&256&&e.a!=null&&(nIe(e.i)||(r.a+=`//`),pl(r,e.a)),e.d!=null&&(r.a+=`/`,pl(r,e.d)),e.f&16&&(r.a+=`/`),t=0,n=e.j.length;tf?!1:(d=(c=vN(r,f,!1),c.a),u+s+d<=t.b&&(fb(n,a-n.s),n.c=!0,fb(r,a-n.s),WO(r,n.s,n.t+n.d+s),r.k=!0,gC(n.q,r),p=!0,i&&(hS(t,r),r.j=t,e.c.length>o&&(Fk((ov(o,e.c.length),P(e.c[o],186)),r),(ov(o,e.c.length),P(e.c[o],186)).a.c.length==0&&Ay(e,o)))),p)}function edt(e,t){var n,r,i,a,o,s;if(t.Ug(`Partition midprocessing`,1),i=new g_,To(hg(new Mp(null,new cv(e.a,16)),new $te),new jpe(i)),i.d!=0){for(s=P(ay(gze((a=i.i,new Mp(null,(a||(i.i=new zu(i,i.c))).Nc()))),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),r=s.Kc(),n=P(r.Pb(),17);r.Ob();)o=P(r.Pb(),17),$at(P(Dy(i,n),21),P(Dy(i,o),21)),n=o;t.Vg()}}function tdt(e,t,n){var r,i,a,o,s,c,l,u;if(t.p==0){for(t.p=1,o=n,o||=(i=new T,a=(r=P(Ba(_5),9),new xf(r,P(Yd(r,r.length),9),0)),new Kc(i,a)),P(o.a,15).Fc(t),t.k==(DA(),GJ)&&P(o.b,21).Fc(P(K(t,(Y(),TQ)),64)),c=new w(t.j);c.a0){if(i=P(e.Ab.g,2033),t==null){for(a=0;an.s&&co)return nP(),X8;break;case 4:case 3:if(u<0)return nP(),Z8;if(u+n>a)return nP(),m5}return c=(l+s/2)/o,r=(u+n/2)/a,c+r<=1&&c-r<=0?(nP(),g5):c+r>=1&&c-r>=0?(nP(),X8):r<.5?(nP(),Z8):(nP(),m5)}function udt(e,t){var n=!1,r,i,a,o,s,c,l,u=D(N(K(t,(mP(),v0)))),d,f,p,m=bF*u,h;for(i=new w(t.b);i.ac+m&&(h=d.g+f.g,f.a=(f.g*f.a+d.g*d.a)/h,f.g=h,d.f=f,n=!0)),a=s,d=f;return n}function ddt(e,t,n,r,i,a,o){var s,c,l,u,d,f=new Ul;for(l=t.Kc();l.Ob();)for(s=P(l.Pb(),853),d=new w(s.Rf());d.a0?c.a?(u=c.b.Mf().b,a>u&&(e.v||c.c.d.c.length==1?(s=(a-u)/2,c.d.d=s,c.d.a=s):(n=P(Ep(c.c.d,0),187).Mf().b,i=(n-u)/2,c.d.d=r.Math.max(0,i),c.d.a=a-i-u))):c.d.a=e.t+a:ym(e.u)&&(o=S7e(c.b),o.d<0&&(c.d.d=-o.d),o.d+o.a>c.b.Mf().b&&(c.d.a=o.d+o.a-c.b.Mf().b))}function XM(){XM=C,Xq=new ou((vP(),H6),G(1)),$q=new ou(J6,80),WDt=new ou(Hzt,5),PDt=new ou(c6,JL),HDt=new ou(U6,G(1)),UDt=new ou(G6,(rd(),!0)),Jq=new iu(50),BDt=new ou(A6,Jq),Wq=y6,Yq=I6,FDt=new ou(m6,!1),qq=k6,RDt=T6,zDt=D6,LDt=w6,IDt=C6,VDt=z6,Kq=(I9e(),DDt),eJ=jDt,Gq=EDt,Zq=ODt,Qq=ADt,qDt=Z6,JDt=$6,KDt=X6,GDt=Y6,tJ=(gT(),M5),new ou(Q6,tJ)}function mdt(e,t){var n;switch(lx(e)){case 6:return rl(t);case 7:return al(t);case 8:return il(t);case 3:return Array.isArray(t)&&(n=lx(t),!(n>=14&&n<=16));case 11:return t!=null&&typeof t===kP;case 12:return t!=null&&(typeof t===EP||typeof t==kP);case 0:return kO(t,e.__elementTypeId$);case 2:return Nm(t)&&t.Tm!==ne;case 1:return Nm(t)&&t.Tm!==ne||kO(t,e.__elementTypeId$);default:return!0}}function hdt(e){var t,n,i=e.o,a;Rd(),e.A.dc()||NT(e.A,lq)?a=i.a:(a=e.D?r.Math.max(i.a,oj(e.f)):oj(e.f),e.A.Hc((TD(),y5))&&!e.B.Hc((UM(),O5))&&(a=r.Math.max(a,oj(P(ig(e.p,(nP(),Z8)),252))),a=r.Math.max(a,oj(P(ig(e.p,m5),252)))),t=YYe(e),t&&(a=r.Math.max(a,t.a))),i.a=ki(Od(e.e.Tf().of((vP(),T6))))?r.Math.max(i.a,a):a,n=e.f.i,n.c=0,n.b=a,iN(e.f)}function gdt(e,t){var n,i=r.Math.min(r.Math.abs(e.c-(t.c+t.b)),r.Math.abs(e.c+e.b-t.c)),a,o=r.Math.min(r.Math.abs(e.d-(t.d+t.a)),r.Math.abs(e.d+e.a-t.d));return n=r.Math.abs(e.c+e.b/2-(t.c+t.b/2)),n>e.b/2+t.b/2||(a=r.Math.abs(e.d+e.a/2-(t.d+t.a/2)),a>e.a/2+t.a/2)?1:n==0&&a==0?0:n==0?o/a+1:a==0?i/n+1:r.Math.min(i/n,o/a)+1}function _dt(e,t){var n,r,i,a=0,o,s=0,c=0;for(i=new w(e.f.e);i.a0&&e.d!=(Yb(),gJ)&&(s+=o*(r.d.a+e.a[t.a][r.a]*(t.d.a-r.d.a)/n)),n>0&&e.d!=(Yb(),mJ)&&(c+=o*(r.d.b+e.a[t.a][r.a]*(t.d.b-r.d.b)/n)));switch(e.d.g){case 1:return new k(s/a,t.d.b);case 2:return new k(t.d.a,c/a);default:return new k(s/a,c/a)}}function vdt(e){var t,n=(!e.a&&(e.a=new ju(z5,e,5)),e.a).i+2,r,i,a,o=new Hy(n);for(M(o,new k(e.j,e.k)),To(new Mp(null,(!e.a&&(e.a=new ju(z5,e,5)),new cv(e.a,16))),new rhe(o)),M(o,new k(e.b,e.c)),t=1;t0&&(fw(c,!1,(GT(),t8)),fw(c,!0,n8)),Dx(t.g,new Pxe(e,n)),Qh(e.g,t,n)}function xdt(){xdt=C;var e;for(jG=U(O(q9,1),HF,28,15,[-1,-1,30,19,15,13,11,11,10,9,9,8,8,8,8,7,7,7,7,7,7,7,6,6,6,6,6,6,6,6,6,6,6,6,6,6,5]),MG=V(q9,HF,28,37,15,1),WTt=U(O(q9,1),HF,28,15,[-1,-1,63,40,32,28,25,23,21,20,19,19,18,18,17,17,16,16,16,15,15,15,15,14,14,14,14,14,14,13,13,13,13,13,13,13,13]),NG=V(Y9,dI,28,37,14,1),e=2;e<=36;e++)MG[e]=C_(r.Math.pow(e,jG[e])),NG[e]=Wk(tF,MG[e])}function Sdt(e){var t;if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i!=1)throw E(new Fi(BSt+(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i));return t=new ai,tw(P(H((!e.b&&(e.b=new cf(H5,e,4,7)),e.b),0),84))&&XS(t,lvt(e,tw(P(H((!e.b&&(e.b=new cf(H5,e,4,7)),e.b),0),84)),!1)),tw(P(H((!e.c&&(e.c=new cf(H5,e,5,8)),e.c),0),84))&&XS(t,lvt(e,tw(P(H((!e.c&&(e.c=new cf(H5,e,5,8)),e.c),0),84)),!0)),t}function Cdt(e,t){var n,r,i=t.d?e.a.c==(O_(),w2)?DE(t.b):OE(t.b):e.a.c==(O_(),C2)?DE(t.b):OE(t.b),a=!1,o;for(r=new pm(Vu(i.a.Kc(),new d));Cj(r);)if(n=P(by(r),18),o=ki(e.a.f[e.a.g[t.b.p].p]),!(!o&&!gy(n)&&n.c.i.c==n.d.i.c)&&!(ki(e.a.n[e.a.g[t.b.p].p])||ki(e.a.n[e.a.g[t.b.p].p]))&&(a=!0,mo(e.b,e.a.g[m3e(n,t.b).p])))return t.c=!0,t.a=n,t;return t.c=a,t.a=null,t}function wdt(e,t,n){var r=n.gc(),i,a,o,s,c,l;if(r==0)return!1;if(e.Pj()){if(c=e.Qj(),$E(e,t,n),o=r==1?e.Ij(3,null,n.Kc().Pb(),t,c):e.Ij(5,null,n,t,c),e.Mj()){for(s=r<100?null:new Pa(r),a=t+r,i=t;i0){for(s=0;s>16==-15&&e.Cb.Yh()&&Pb(new ub(e.Cb,9,13,n,e.c,NO(Ib(P(e.Cb,62)),e))):j(e.Cb,90)&&e.Db>>16==-23&&e.Cb.Yh()&&(t=e.c,j(t,90)||(t=(CP(),J7)),j(n,90)||(n=(CP(),J7)),Pb(new ub(e.Cb,9,10,n,t,NO(Jv(P(e.Cb,29)),e)))))),e.c}function jdt(e,t,n){var r,i,a,o,s,c,l,u,d;for(n.Ug(`Hyperedge merging`,1),uit(e,t),c=new bv(t.b,0);c.b0,s=IE(t,a),JTe(n?s.b:s.g,t),eT(s).c.length==1&&iy(r,s,r.c.b,r.c),i=new Kc(a,t),Rv(e.o,i),Db(e.e.a,a))}function Rdt(e,t){var n,i=r.Math.abs(Mm(e.b).a-Mm(t.b).a),a,o,s,c=r.Math.abs(Mm(e.b).b-Mm(t.b).b),l;return a=0,l=0,n=1,s=1,i>e.b.b/2+t.b.b/2&&(a=r.Math.min(r.Math.abs(e.b.c-(t.b.c+t.b.b)),r.Math.abs(e.b.c+e.b.b-t.b.c)),n=1-a/i),c>e.b.a/2+t.b.a/2&&(l=r.Math.min(r.Math.abs(e.b.d-(t.b.d+t.b.a)),r.Math.abs(e.b.d+e.b.a-t.b.d)),s=1-l/c),o=r.Math.min(n,s),(1-o)*r.Math.sqrt(i*i+c*c)}function zdt(e){var t,n,r,i;for(eP(e,e.e,e.f,(D_(),j2),!0,e.c,e.i),eP(e,e.e,e.f,j2,!1,e.c,e.i),eP(e,e.e,e.f,M2,!0,e.c,e.i),eP(e,e.e,e.f,M2,!1,e.c,e.i),Adt(e,e.c,e.e,e.f,e.i),r=new bv(e.i,0);r.b=65;n--)A9[n]=n-65<<24>>24;for(r=122;r>=97;r--)A9[r]=r-97+26<<24>>24;for(i=57;i>=48;i--)A9[i]=i-48+52<<24>>24;for(A9[43]=62,A9[47]=63,a=0;a<=25;a++)j9[a]=65+a&OF;for(o=26,c=0;o<=51;++o,c++)j9[o]=97+c&OF;for(e=52,s=0;e<=61;++e,s++)j9[e]=48+s&OF;j9[62]=43,j9[63]=47}function Vdt(e,t){var n,i,a=QS(e),o,s,c=QS(t);return a==c?e.e==t.e&&e.a<54&&t.a<54?e.ft.f):(i=e.e-t.e,n=(e.d>0?e.d:r.Math.floor((e.a-1)*dyt)+1)-(t.d>0?t.d:r.Math.floor((t.a-1)*dyt)+1),n>i+1?a:n0&&(s=Uv(s,Mft(i))),q0e(o,s))):au&&(p=0,m+=l+t,l=0),kM(s,p,m),n=r.Math.max(n,p+d.a),l=r.Math.max(l,d.b),p+=d.a+t;return new k(n+t,m+l+t)}function Wdt(e,t){var n,r,i,a,o,s,c;if(!E_(e))throw E(new Ii(zSt));if(r=E_(e),a=r.g,i=r.f,a<=0&&i<=0)return nP(),h5;switch(s=e.i,c=e.j,t.g){case 2:case 1:if(s<0)return nP(),g5;if(s+e.g>a)return nP(),X8;break;case 4:case 3:if(c<0)return nP(),Z8;if(c+e.f>i)return nP(),m5}return o=(s+e.g/2)/a,n=(c+e.f/2)/i,o+n<=1&&o-n<=0?(nP(),g5):o+n>=1&&o-n>=0?(nP(),X8):n<.5?(nP(),Z8):(nP(),m5)}function Gdt(e,t,n,r,i){var a=yE(uv(t[0],_I),uv(r[0],_I)),o;if(e[0]=nm(a),a=lm(a,32),n>=i){for(o=1;o0&&(i.b[o++]=0,i.b[o++]=a.b[0]-1),t=1;t0&&(Dn(c,c.d-i.d),i.c==(Wy(),k2)&&Jde(c,c.a-i.d),c.d<=0&&c.i>0&&iy(t,c,t.c.b,t.c)));for(a=new w(e.f);a.a0&&(On(s,s.i-i.d),i.c==(Wy(),k2)&&Yde(s,s.b-i.d),s.i<=0&&s.d>0&&iy(n,s,n.c.b,n.c)))}function Ydt(e,t,n,r,i){var a,o,s,c,l,u,d,f,p;for(Vg(),hu(e,new gse),o=Zf(e),p=new T,f=new T,s=null,c=0;o.b!=0;)a=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),163),!s||Lp(s)*Ip(s)/21&&(c>Lp(s)*Ip(s)/2||o.b==0)&&(d=new Fx(f),u=Lp(s)/Ip(s),l=cP(d,t,new ni,n,r,i,u),$d(Cl(d.e),l),s=d,Mr(p.c,d),c=0,f.c.length=0));return nw(p,f),p}function tN(e,t,n,r,i){yo();var a,o,s,c,l,u,d;if(Jm(e,`src`),Jm(n,`dest`),d=$w(e),c=$w(n),Rje(!!(d.i&4),`srcType is not an array`),Rje(!!(c.i&4),`destType is not an array`),u=d.c,o=c.c,Rje(u.i&1?u==o:!(o.i&1),`Array types don't match`),CZe(e,t,n,r,i),!(u.i&1)&&d!=c){if(l=rS(e),a=rS(n),A(e)===A(n)&&tr;)Sh(a,s,l[--t]);else for(s=r+i;r0),r.a.Xb(r.c=--r.b),d>f+c&&Fh(r);for(o=new w(p);o.a0),r.a.Xb(r.c=--r.b)}}function Qdt(){xP();var e,t,n,r,i,a;if(V9)return V9;for(e=(++W9,new pv(4)),DN(e,oP(zW,!0)),KN(e,oP(`M`,!0)),KN(e,oP(`C`,!0)),a=(++W9,new pv(4)),r=0;r<11;r++)oM(a,r,r);return t=(++W9,new pv(4)),DN(t,oP(`M`,!0)),oM(t,4448,4607),oM(t,65438,65439),i=(++W9,new lu(2)),LN(i,e),LN(i,B9),n=(++W9,new lu(2)),n.Jm(Rp(a,oP(`L`,!0))),n.Jm(t),n=(++W9,new Zv(3,n)),n=(++W9,new Km(i,n)),V9=n,V9}function nN(e,t){var n=new RegExp(t,`g`),r,i,a,o,s,c=V(LG,X,2,0,6,1),l;for(r=0,l=e,a=null;;){if(s=n.exec(l),s==null||l==``){c[r]=l;break}o=s.index,c[r]=(Zy(0,o,l.length),l.substr(0,o)),l=p_(l,o+s[0].length,l.length),n.lastIndex=0,a==l&&(c[r]=(Zy(0,1,l.length),l.substr(0,1)),l=(sv(1,l.length+1),l.substr(1))),a=l,++r}if(e.length>0){for(i=c.length;i>0&&c[i-1]==``;)--i;i0&&(f-=i[0]+e.c,i[0]+=e.c),i[2]>0&&(f-=i[2]+e.c),i[1]=r.Math.max(i[1],f),Yp(e.a[1],n.c+t.b+i[0]-(i[1]-f)/2,i[1]);for(o=e.a,c=0,u=o.length;c0?(e.n.c.length-1)*e.i:0,i=new w(e.n);i.a1)for(r=dO(i,0);r.b!=r.d.c;)for(n=P(Lv(r),235),a=0,c=new w(n.e);c.a0&&(t[0]+=e.c,f-=t[0]),t[2]>0&&(f-=t[2]+e.c),t[1]=r.Math.max(t[1],f),Xp(e.a[1],i.d+n.d+t[0]-(t[1]-f)/2,t[1]);else for(h=i.d+n.d,m=i.a-n.d-n.a,s=e.a,l=0,d=s.length;l0||CE(a.b.d,e.b.d+e.b.a)==0&&i.b<0||CE(a.b.d+a.b.a,e.b.d)==0&&i.b>0){c=0;break}}else c=r.Math.min(c,ztt(e,a,i));c=r.Math.min(c,oft(e,o,c,i))}return c}function cN(e,t){var n,r,i,a,o,s,c;if(e.b<2)throw E(new Fi(`The vector chain must contain at least a source and a target point.`));for(i=(jd(e.b!=0),P(e.a.a.c,8)),tu(t,i.a,i.b),c=new cd((!t.a&&(t.a=new ju(z5,t,5)),t.a)),o=dO(e,1);o.a=0&&a!=n))throw E(new Fi(vU));for(i=0,c=0;cD(Eu(o.g,o.d[0]).a)?(jd(c.b>0),c.a.Xb(c.c=--c.b),qd(c,o),i=!0):s.e&&s.e.gc()>0&&(a=(!s.e&&(s.e=new T),s.e).Mc(t),l=(!s.e&&(s.e=new T),s.e).Mc(n),(a||l)&&((!s.e&&(s.e=new T),s.e).Fc(o),++o.c));i||Mr(r.c,o)}function uft(e,t,n){var r,i,a,o,s,c,l,u,d=e.a.i+e.a.g/2,f=e.a.i+e.a.g/2,p,m=t.i+t.g/2,h,g=t.j+t.f/2,_;return s=new k(m,g),l=P(J(t,(vP(),V6)),8),l.a+=d,l.b+=f,a=(s.b-l.b)/(s.a-l.a),r=s.b-a*s.a,h=n.i+n.g/2,_=n.j+n.f/2,c=new k(h,_),u=P(J(n,V6),8),u.a+=d,u.b+=f,o=(c.b-u.b)/(c.a-u.a),i=c.b-o*c.a,p=(r-i)/(o-a),l.a>>0,`0`+t.toString(16)),r=`\\x`+p_(n,n.length-2,n.length)):e>=pI?(n=(t=e>>>0,`0`+t.toString(16)),r=`\\v`+p_(n,n.length-6,n.length)):r=``+String.fromCharCode(e&OF)}return r}function vft(e){var t,n,r;if(Kl(P(K(e,(mP(),Q1)),101)))for(n=new w(e.j);n.a=t.o&&n.f<=t.f||t.a*.5<=n.f&&t.a*1.5>=n.f){if(o=P(Ep(t.n,t.n.c.length-1),209),o.e+o.d+n.g+i<=r&&(a=P(Ep(t.n,t.n.c.length-1),209),a.f-e.f+n.f<=e.b||e.a.c.length==1))return ME(t,n),!0;if(t.s+n.g<=r&&(t.t+t.d+n.f+i<=e.b||e.a.c.length==1))return M(t.b,n),s=P(Ep(t.n,t.n.c.length-1),209),M(t.n,new w_(t.s,s.f+s.a+t.i,t.i)),q4e(P(Ep(t.n,t.n.c.length-1),209),n),tft(t,n),!0}return!1}function Sft(e,t,n){var r,i,a,o;return e.Pj()?(i=null,a=e.Qj(),r=e.Ij(1,o=tx(e,t,n),n,t,a),e.Mj()&&!(e.Yi()&&o!=null?NT(o,n):A(o)===A(n))?(o!=null&&(i=e.Oj(o,i)),i=e.Nj(n,i),e.Tj()&&(i=e.Wj(o,n,i)),i?(i.nj(r),i.oj()):e.Jj(r)):(e.Tj()&&(i=e.Wj(o,n,i)),i?(i.nj(r),i.oj()):e.Jj(r)),o):(o=tx(e,t,n),e.Mj()&&!(e.Yi()&&o!=null?NT(o,n):A(o)===A(n))&&(i=null,o!=null&&(i=e.Oj(o,null)),i=e.Nj(n,i),i&&i.oj()),o)}function Cft(e,t){var n,r,i,a,o;if(t.Ug(`Path-Like Graph Wrapping`,1),e.b.c.length==0){t.Vg();return}if(i=new Qrt(e),o=(i.i??(i.i=$S(i,new $re)),D(i.i)*i.f),n=o/(i.i??(i.i=$S(i,new $re)),D(i.i)),i.b>n){t.Vg();return}switch(P(K(e,(mP(),T0)),351).g){case 2:a=new nie;break;case 0:a=new Kre;break;default:a=new rie}if(r=a.og(e,i),!a.pg())switch(P(K(e,D0),352).g){case 2:r=Wtt(i,r);break;case 1:r=S5e(i,r)}Hpt(e,i,r),t.Vg()}function dN(e,t){var n,i,a,o,s,c,l,u;t%=24,e.q.getHours()!=t&&(i=new r.Date(e.q.getTime()),i.setDate(i.getDate()+1),c=e.q.getTimezoneOffset()-i.getTimezoneOffset(),c>0&&(l=c/60|0,u=c%60,a=e.q.getDate(),n=e.q.getHours(),n+l>=24&&++a,o=new r.Date(e.q.getFullYear(),e.q.getMonth(),a,t+l,e.q.getMinutes()+u,e.q.getSeconds(),e.q.getMilliseconds()),e.q.setTime(o.getTime()))),s=e.q.getTime(),e.q.setTime(s+36e5),e.q.getHours()!=t&&e.q.setTime(s)}function wft(e,t){var n,r,i,a;if(hze(e.d,e.e),e.c.a.$b(),D(N(K(t.j,(mP(),n1))))!=0||D(N(K(t.j,n1)))!=0)for(n=zL,A(K(t.j,s1))!==A((ID(),Z0))&&W(t.j,(Y(),DQ),(rd(),!0)),a=P(K(t.j,C0),17).a,i=0;ii&&++l,M(o,(ov(s+l,t.c.length),P(t.c[s+l],17))),c+=(ov(s+l,t.c.length),P(t.c[s+l],17)).a-r,++n;n=_&&e.e[l.p]>h*e.b||b>=n*_)&&(Mr(p.c,c),c=new T,XS(s,o),o.a.$b(),u-=d,m=r.Math.max(m,u*e.b+g),u+=b,y=b,b=0,d=0,g=0);return new Kc(m,p)}function fN(e){var t,n,r,i,a,o,s;if(!e.d){if(s=new Gse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(l_(e));r.e!=r.i.gc();)n=P(gO(r),29),th(s,fN(n));t.a.Bc(e),t.a.gc()}for(o=s.i,i=(!e.q&&(e.q=new F(M7,e,11,10)),new Lu(e.q));i.e!=i.i.gc();++o)P(gO(i),411);th(s,(!e.q&&(e.q=new F(M7,e,11,10)),e.q)),Kw(s),e.d=new El((P(H(R((vh(),z7).o),9),19),s.i),s.g),e.e=P(s.g,688),e.e??=eHt,_y(e).b&=-17}return e.d}function pN(e,t,n,r){var i,a,o,s,c,l=nM(e.e.Dh(),t);if(c=0,i=P(e.g,124),Qo(),P(t,69).xk()){for(o=0;o1||m==-1){if(d=P(h,71),f=P(u,71),d.dc())f.$b();else for(o=!!qO(t),a=0,s=e.a?d.Kc():d.Ii();s.Ob();)l=P(s.Pb(),58),i=P(ix(e,l),58),i?(o?(c=f.dd(i),c==-1?f.Gi(a,i):a!=c&&f.Ui(a,i)):f.Gi(a,i),++a):e.b&&!o&&(f.Gi(a,l),++a)}else h==null?u.Wb(null):(i=ix(e,h),i==null?e.b&&!qO(t)&&u.Wb(h):u.Wb(i))}}function kft(e,t){var n=new _te,i,a,o,s,c,l,u;for(a=new pm(Vu(DE(t).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),!gy(i)&&(c=i.c.i,U5e(c,sY))){if(u=jct(e,c,sY,oY),u==-1)continue;n.b=r.Math.max(n.b,u),!n.a&&(n.a=new T),M(n.a,c)}for(s=new pm(Vu(OE(t).a.Kc(),new d));Cj(s);)if(o=P(by(s),18),!gy(o)&&(l=o.d.i,U5e(l,oY))){if(u=jct(e,l,oY,sY),u==-1)continue;n.d=r.Math.max(n.d,u),!n.c&&(n.c=new T),M(n.c,l)}return n}function Aft(e,t,n,r){var i,a,o,s,c,l,u;if(n.d.i!=t.i){for(i=new ZO(e),En(i,(DA(),qJ)),W(i,(Y(),WQ),n),W(i,(mP(),Q1),(rA(),R8)),Mr(r.c,i),o=new jA,G_(o,i),tj(o,(nP(),g5)),s=new jA,G_(s,i),tj(s,X8),u=n.d,K_(n,o),a=new i_,VC(a,n),W(a,j1,null),U_(a,s),K_(a,u),l=new bv(n.b,0);l.b1e6)throw E(new ji(`power of ten too big`));if(e<=AP)return xy(hj(XG[1],t),t);for(r=hj(XG[1],AP),i=r,n=LC(e-AP),t=C_(e%AP);dT(n,AP)>0;)i=Uv(i,r),n=xE(n,AP);for(i=Uv(i,hj(XG[1],t)),i=xy(i,AP),n=LC(e-AP);dT(n,AP)>0;)i=xy(i,AP),n=xE(n,AP);return i=xy(i,t),i}function Nft(e){var t,n,r,i,a,o,s,c,l,u;for(c=new w(e.a);c.al&&r>l)u=s,l=D(t.p[s.p])+D(t.d[s.p])+s.o.b+s.d.a;else{i=!1,n._g()&&n.bh(`bk node placement breaks on `+s+` which should have been after `+u);break}if(!i)break}return n._g()&&n.bh(t+` is feasible: `+i),i}function Ift(e,t,n,r){var i,a=new ZO(e),o,s,c,l,u,d,f;if(En(a,(DA(),YJ)),W(a,(mP(),Q1),(rA(),R8)),i=0,t){for(o=new jA,W(o,(Y(),WQ),t),W(a,WQ,t.i),tj(o,(nP(),g5)),G_(o,a),f=Sv(t.e),l=f,u=0,d=l.length;u0){if(i<0&&u.a&&(i=c,a=l[0],r=0),i>=0){if(s=u.b,c==i&&(s-=r++,s==0))return 0;if(!i_t(t,l,u,s,o)){c=i-1,l[0]=a;continue}}else if(i=-1,!i_t(t,l,u,0,o))return 0}else{if(i=-1,mg(u.c,0)==32){if(d=l[0],gKe(t,l),l[0]>d)continue}else if(tLe(t,u.c,l[0])){l[0]+=u.c.length;continue}return 0}return Igt(o,n)?l[0]:0}function Bft(e,t,n){var r,i,a,o,s,c,l,u=new fm(new rpe(n)),d,f;for(s=V(J9,aL,28,e.f.e.c.length,16,1),CPe(s,s.length),n[t.a]=0,l=new w(e.f.e);l.a=0&&!sk(e,u,d);)--d;i[u]=d}for(p=0;p=0&&!sk(e,s,m);)--s;a[m]=s}for(c=0;ct[f]&&fr[c]&&EM(e,c,f,!1,!0)}function Hft(e){var t,n=ki(Od(K(e,(XM(),FDt)))),r,i,a=e.a.c.d,o,s=e.a.d.d,c;n?(o=ku(ef(new k(s.a,s.b),a),.5),c=ku(xu(e.e),.5),t=ef($d(new k(a.a,a.b),o),c),IEe(e.d,t)):(i=D(N(K(e.a,WDt))),r=e.d,a.a>=s.a?a.b>=s.b?(r.a=s.a+(a.a-s.a)/2+i,r.b=s.b+(a.b-s.b)/2-i-e.e.b):(r.a=s.a+(a.a-s.a)/2+i,r.b=a.b+(s.b-a.b)/2+i):a.b>=s.b?(r.a=a.a+(s.a-a.a)/2+i,r.b=s.b+(a.b-s.b)/2+i):(r.a=a.a+(s.a-a.a)/2+i,r.b=a.b+(s.b-a.b)/2-i-e.e.b))}function gN(e){var t,n,r,i,a,o,s,c;if(!e.f){if(c=new Use,s=new Use,t=n9,o=t.a.zc(e,t),o==null){for(a=new Lu(l_(e));a.e!=a.i.gc();)i=P(gO(a),29),th(c,gN(i));t.a.Bc(e),t.a.gc()}for(r=(!e.s&&(e.s=new F(w7,e,21,17)),new Lu(e.s));r.e!=r.i.gc();)n=P(gO(r),179),j(n,102)&&tb(s,P(n,19));Kw(s),e.r=new cMe(e,(P(H(R((vh(),z7).o),6),19),s.i),s.g),th(c,e.r),Kw(c),e.f=new El((P(H(R(z7.o),5),19),c.i),c.g),_y(e).b&=-3}return e.f}function Uft(e){Wo(e,new oA(ya(ha(va(_a(new Zt,ML),`ELK DisCo`),`Layouter for arranging unconnected subgraphs. The subgraphs themselves are, by default, not laid out.`),new Ft))),B(e,ML,NL,hO(Iq)),B(e,ML,PL,hO(Pq)),B(e,ML,FL,hO(yDt)),B(e,ML,IL,hO(Fq)),B(e,ML,$I,hO(CDt)),B(e,ML,eL,hO(SDt)),B(e,ML,QI,hO(wDt)),B(e,ML,tL,hO(xDt)),B(e,ML,Jyt,hO(bDt)),B(e,ML,Yyt,hO(jq)),B(e,ML,Xyt,hO(Mq)),B(e,ML,Zyt,hO(Nq))}function _N(){_N=C,hVt=U(O(K9,1),EF,28,15,[48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70]),gVt=RegExp(`[ +\r\f]+`);try{t7=U(O(tHt,1),FP,2114,0,[new br((Sl(),hD(`yyyy-MM-dd'T'HH:mm:ss'.'SSSZ`,Kd((Ci(),Ci(),dG))))),new br(hD(`yyyy-MM-dd'T'HH:mm:ss'.'SSS`,Kd(dG))),new br(hD(`yyyy-MM-dd'T'HH:mm:ss`,Kd(dG))),new br(hD(`yyyy-MM-dd'T'HH:mm`,Kd(dG))),new br(hD(`yyyy-MM-dd`,Kd(dG)))])}catch(e){if(e=ew(e),!j(e,82))throw E(e)}}function Wft(e,t){var n,r,i=Lj(e.d,1)!=0,a;if(r=Plt(e,t),r==0&&ki(Od(K(t.j,(Y(),DQ)))))return 0;!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,i$)))||A(K(t.j,(mP(),s1)))===A((ID(),Z0))?t.c.mg(t.e,i):i=ki(Od(K(t.j,DQ))),$j(e,t,i,!0),ki(Od(K(t.j,i$)))&&W(t.j,i$,(rd(),!1)),ki(Od(K(t.j,DQ)))&&(W(t.j,DQ,(rd(),!1)),W(t.j,i$,!0)),n=Plt(e,t);do{if(WS(e),n==0)return 0;i=!i,a=n,$j(e,t,i,!1),n=Plt(e,t)}while(a>n);return a}function Gft(e,t){var n,r,i=Lj(e.d,1)!=0,a;if(r=YA(e,t),r==0&&ki(Od(K(t.j,(Y(),DQ)))))return 0;!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,i$)))||A(K(t.j,(mP(),s1)))===A((ID(),Z0))?t.c.mg(t.e,i):i=ki(Od(K(t.j,DQ))),$j(e,t,i,!0),ki(Od(K(t.j,i$)))&&W(t.j,i$,(rd(),!1)),ki(Od(K(t.j,DQ)))&&(W(t.j,DQ,(rd(),!1)),W(t.j,i$,!0)),n=YA(e,t);do{if(WS(e),n==0)return 0;i=!i,a=n,$j(e,t,i,!1),n=YA(e,t)}while(a>n);return a}function Kft(e,t,n,i){var a,o,s,c,l=ef(new k(n.a,n.b),e),u=l.a*t.b-l.b*t.a,d=t.a*i.b-t.b*i.a,f=(l.a*i.b-l.b*i.a)/d,p=u/d;return d==0?u==0?(a=$d(new k(n.a,n.b),ku(new k(i.a,i.b),.5)),o=ab(e,a),s=ab($d(new k(e.a,e.b),t),a),c=r.Math.sqrt(i.a*i.a+i.b*i.b)*.5,o=0&&f<=1&&p>=0&&p<=1?$d(new k(e.a,e.b),ku(new k(t.a,t.b),f)):null}function qft(e,t,n){var r=P(K(e,(mP(),c1)),21),i,a,o,s;if(n.a>t.a&&(r.Hc((eA(),e6))?e.c.a+=(n.a-t.a)/2:r.Hc(n6)&&(e.c.a+=n.a-t.a)),n.b>t.b&&(r.Hc((eA(),i6))?e.c.b+=(n.b-t.b)/2:r.Hc(r6)&&(e.c.b+=n.b-t.b)),P(K(e,(Y(),OQ)),21).Hc((uM(),KZ))&&(n.a>t.a||n.b>t.b))for(s=new w(e.a);s.at.a&&(r.Hc((eA(),e6))?e.c.a+=(n.a-t.a)/2:r.Hc(n6)&&(e.c.a+=n.a-t.a)),n.b>t.b&&(r.Hc((eA(),i6))?e.c.b+=(n.b-t.b)/2:r.Hc(r6)&&(e.c.b+=n.b-t.b)),P(K(e,(Y(),OQ)),21).Hc((uM(),KZ))&&(n.a>t.a||n.b>t.b))for(o=new w(e.a);o.a0?e.i:0)>t&&l>0&&(o=0,s+=l+e.i,a=r.Math.max(a,p),i+=l+e.i,l=0,p=0,n&&(++f,M(e.n,new w_(e.s,s,e.i))),c=0),p+=u.g+(c>0?e.i:0),l=r.Math.max(l,u.f),n&&q4e(P(Ep(e.n,f),209),u),o+=u.g+(c>0?e.i:0),++c;return a=r.Math.max(a,p),i+=l,n&&(e.r=a,e.d=i,V3e(e.j)),new wg(e.s,e.t,a,i)}function yN(e){var t,n,i,a,o,s,c,l,u,d,f,p;for(e.b=!1,f=cI,l=lI,p=cI,u=lI,i=e.e.a.ec().Kc();i.Ob();)for(n=P(i.Pb(),272),a=n.a,f=r.Math.min(f,a.c),l=r.Math.max(l,a.c+a.b),p=r.Math.min(p,a.d),u=r.Math.max(u,a.d+a.a),s=new w(n.c);s.ae.o.a&&(d=(l-e.o.a)/2,c.b=r.Math.max(c.b,d),c.c=r.Math.max(c.c,d))}}function Qft(e){var t,n,r,i,a=new $ze,o,s,c;for(NCe(a,(lw(),DRt)),r=(i=ZS(e,V(LG,X,2,0,6,1)),new qn(new Wi(new fo(e,i).b)));r.bs?1:-1,i==-1)d=-c,u=o==c?ky(t.a,s,e.a,a):Yy(t.a,s,e.a,a);else if(d=o,o==c){if(i==0)return AM(),JG;u=ky(e.a,a,t.a,s)}else u=Yy(e.a,a,t.a,s);return l=new Bm(d,u.length,u),Cv(l),l}function $ft(e,t){var n,r,i,a=Fdt(t);if(!t.c&&(t.c=new F(e7,t,9,9)),To(new Mp(null,(!t.c&&(t.c=new F(e7,t,9,9)),new cv(t.c,16))),new cpe(a)),i=P(K(a,(Y(),OQ)),21),zht(t,i),i.Hc((uM(),KZ)))for(r=new Lu((!t.c&&(t.c=new F(e7,t,9,9)),t.c));r.e!=r.i.gc();)n=P(gO(r),123),Sgt(e,t,a,n);return P(J(t,(mP(),W1)),181).gc()!=0&&rct(t,a),ki(Od(K(a,Qjt)))&&i.Fc(ZZ),yd(a,a0)&&Q_e(new rD(D(N(K(a,a0)))),a),A(J(t,D1))===A((_T(),g8))?jvt(e,t,a):svt(e,t,a),a}function ept(e){var t,n,r,i,a,o,s,c;for(i=new w(e.b);i.a0?p_(n.a,0,a-1):``):(Zy(0,a-1,e.length),e.substr(0,a-1)):n?n.a:e}function tpt(e,t){var n,r,i,a,o,s,c;for(t.Ug(`Sort By Input Model `+K(e,(mP(),s1)),1),i=0,r=new w(e.b);r.a=e.b.length?(a[i++]=o.b[r++],a[i++]=o.b[r++]):r>=o.b.length?(a[i++]=e.b[n++],a[i++]=e.b[n++]):o.b[r]0?e.i:0)),++t;for(oE(e.n,l),e.d=n,e.r=i,e.g=0,e.f=0,e.e=0,e.o=cI,e.p=cI,o=new w(e.b);o.a0&&(i=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!i||gl(gl((t.a+=` "`,t),i),`"`))),n=(!e.b&&(e.b=new cf(H5,e,4,7)),!(e.b.i<=1&&(!e.c&&(e.c=new cf(H5,e,5,8)),e.c.i<=1))),n?t.a+=` [`:t.a+=` `,gl(t,_Te(new Xi,new Lu(e.b))),n&&(t.a+=`]`),t.a+=kR,n&&(t.a+=`[`),gl(t,_Te(new Xi,new Lu(e.c))),n&&(t.a+=`]`),t.a)}function apt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x=e.c,S=t.c,ee,te,ne,C;for(n=Ab(x.a,e,0),r=Ab(S.a,t,0),y=P(fD(e,(uS(),n2)).Kc().Pb(),12),ne=P(fD(e,r2).Kc().Pb(),12),b=P(fD(t,n2).Kc().Pb(),12),C=P(fD(t,r2).Kc().Pb(),12),_=Sv(y.e),ee=Sv(ne.g),v=Sv(b.e),te=Sv(C.g),Ak(e,r,S),o=v,u=0,m=o.length;ud?new nv((Wy(),A2),n,t,u-d):u>0&&d>0&&(new nv((Wy(),A2),t,n,0),new nv(A2,n,t,0))),s)}function lpt(e,t,n){var r,i,a;for(e.a=new T,a=dO(t.b,0);a.b!=a.d.c;){for(i=P(Lv(a),40);P(K(i,(rN(),p4)),17).a>e.a.c.length-1;)M(e.a,new Kc(zL,zV));r=P(K(i,p4),17).a,n==(GT(),t8)||n==n8?(i.e.aD(N(P(Ep(e.a,r),42).b))&&An(P(Ep(e.a,r),42),i.e.a+i.f.a)):(i.e.bD(N(P(Ep(e.a,r),42).b))&&An(P(Ep(e.a,r),42),i.e.b+i.f.b))}}function upt(e,t,n,r){var i,a=cE(r),o,s=ki(Od(K(r,(mP(),Kjt)))),c,l,u;if((s||ki(Od(K(e,O1))))&&!Kl(P(K(e,Q1),101)))i=GE(a),c=rdt(e,n,n==(uS(),r2)?i:YT(i));else switch(c=new jA,G_(c,e),t?(u=c.n,u.a=t.a-e.n.a,u.b=t.b-e.n.b,iet(u,0,0,e.o.a,e.o.b),tj(c,ldt(c,a))):(i=GE(a),tj(c,n==(uS(),r2)?i:YT(i))),o=P(K(r,(Y(),OQ)),21),l=c.j,a.g){case 2:case 1:(l==(nP(),Z8)||l==m5)&&o.Fc((uM(),XZ));break;case 4:case 3:(l==(nP(),X8)||l==g5)&&o.Fc((uM(),XZ))}return c}function dpt(e,t){var n,i,a,o,s,c;for(s=new EC(new Fn(e.f.b).a);s.b;){if(o=MS(s),a=P(o.ld(),602),t==1){if(a.Af()!=(GT(),i8)&&a.Af()!=e8)continue}else if(a.Af()!=(GT(),t8)&&a.Af()!=n8)continue;switch(i=P(P(o.md(),42).b,86),c=P(P(o.md(),42).a,194),n=c.c,a.Af().g){case 2:i.g.c=e.e.a,i.g.b=r.Math.max(1,i.g.b+n);break;case 1:i.g.c=i.g.c+n,i.g.b=r.Math.max(1,i.g.b-n);break;case 4:i.g.d=e.e.b,i.g.a=r.Math.max(1,i.g.a+n);break;case 3:i.g.d=i.g.d+n,i.g.a=r.Math.max(1,i.g.a-n)}}}function fpt(e,t){var n,i,a,o,s,c=V(q9,HF,28,t.b.c.length,15,1),l,u=V(XJ,Z,273,t.b.c.length,0,1),d,f,p,m,h,g;for(l=V(UJ,jR,10,t.b.c.length,0,1),f=e.a,p=0,m=f.length;p0&&l[i]&&(h=yu(e.b,l[i],a)),g=r.Math.max(g,a.c.c.b+h);for(o=new w(d.e);o.a1)throw E(new Fi(CW));c||(a=Gv(t,r.Kc().Pb()),o.Fc(a))}return lZe(e,Aet(e,t,n),o)}function ON(e,t,n){var r,i,a,o,s,c,l,u;if(aM(e.e,t))c=(Qo(),P(t,69).xk()?new hp(t,e):new Qc(t,e)),_j(c.c,c.b),Su(c,P(n,16));else{for(u=nM(e.e.Dh(),t),r=P(e.g,124),o=0;o`}c!=null&&(t.a+=``+c)}else e.e?(s=e.e.zb,s!=null&&(t.a+=``+s)):(t.a+=`?`,e.b?(t.a+=` super `,kN(e.b,t)):e.f&&(t.a+=` extends `,kN(e.f,t)))}function Spt(e){e.b=null,e.a=null,e.o=null,e.q=null,e.v=null,e.w=null,e.B=null,e.p=null,e.Q=null,e.R=null,e.S=null,e.T=null,e.U=null,e.V=null,e.W=null,e.bb=null,e.eb=null,e.ab=null,e.H=null,e.db=null,e.c=null,e.d=null,e.f=null,e.n=null,e.r=null,e.s=null,e.u=null,e.G=null,e.J=null,e.e=null,e.j=null,e.i=null,e.g=null,e.k=null,e.t=null,e.F=null,e.I=null,e.L=null,e.M=null,e.O=null,e.P=null,e.$=null,e.N=null,e.Z=null,e.cb=null,e.K=null,e.D=null,e.A=null,e.C=null,e._=null,e.fb=null,e.X=null,e.Y=null,e.gb=!1,e.hb=!1}function Cpt(e){var t,n,i=pP((!e.c&&(e.c=Q_(LC(e.f))),e.c),0),a;if(e.e==0||e.a==0&&e.f!=-1&&e.e<0)return i;if(t=+(QS(e)<0),n=e.e,a=(i.length+1+r.Math.abs(C_(e.e)),new na),t==1&&(a.a+=`-`),e.e>0){if(n-=i.length-t,n>=0){for(a.a+=`0.`;n>RG.length;n-=RG.length)RMe(a,RG);RDe(a,RG,C_(n)),gl(a,(sv(t,i.length+1),i.substr(t)))}else n=t-n,gl(a,p_(i,t,C_(n))),a.a+=`.`,gl(a,Ch(i,C_(n)))}else{for(gl(a,(sv(t,i.length+1),i.substr(t)));n<-RG.length;n+=RG.length)RMe(a,RG);RDe(a,RG,C_(-n))}return a.a}function AN(e){var t,n,r,i,a,o,s,c,l;return!(e.k!=(DA(),JJ)||e.j.c.length<=1||(a=P(K(e,(mP(),Q1)),101),a==(rA(),R8))||(i=(IO(),r=(e.q?e.q:(Vg(),Vg(),$G))._b(V1)?P(K(e,V1),203):P(K(Bh(e),H1),203),r),i==R0)||i!=L0&&i!=I0&&(o=D(N(gD(e,S0))),t=P(K(e,x0),140),!t&&(t=new ZDe(o,o,o,o)),l=SE(e,(nP(),g5)),c=t.d+t.a+(l.gc()-1)*o,c>e.o.b||(n=SE(e,X8),s=t.d+t.a+(n.gc()-1)*o,s>e.o.b)))}function wpt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;t.Ug(`Orthogonal edge routing`,1),l=D(N(K(e,(mP(),y0)))),n=D(N(K(e,l0))),r=D(N(K(e,f0))),f=new ah(0,n),g=0,o=new bv(e.b,0),s=null,u=null,c=null,d=null;do u=o.b0?(p=(m-1)*n,s&&(p+=r),u&&(p+=r),pt||ki(Od(J(c,(gM(),t3)))))&&(i=0,a+=u.b+n,Mr(d.c,u),u=new Zze(a,n),r=new kw(0,u.f,u,n),hS(u,r),i=0),r.b.c.length==0||!ki(Od(J(I_(c),(gM(),r3))))&&(c.f>=r.o&&c.f<=r.f||r.a*.5<=c.f&&r.a*1.5>=c.f)?ME(r,c):(o=new kw(r.s+r.r+n,u.f,u,n),hS(u,o),ME(o,c)),i=c.i+c.g;return Mr(d.c,u),d}function FN(e){var t,n,r,i;if(!(e.b==null||e.b.length<=2)&&!e.a){for(t=0,i=0;i=e.b[i+1])i+=2;else if(n0)for(r=new bf(P(Dy(e.a,a),21)),Vg(),hu(r,new ur(t)),i=new bv(a.b,0);i.b0&&r>=-6?r>=0?Xu(a,n-C_(e.e),`.`):(kC(a,t-1,t-1,`0.`),Xu(a,t+1,ND(RG,0,-C_(r)-1))):(n-t>=1&&(Xu(a,t,`.`),++n),Xu(a,n,`E`),r>0&&Xu(a,++n,`+`),Xu(a,++n,``+bm(LC(r)))),e.g=a.a,e.g)):e.g}function zpt(e,t){var n,i=D(N(K(t,(mP(),Yjt)))),a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(K(t,C0),17).a,ee,te;p=4,a=3,ee=20/S,m=!1,l=0,s=AP;do{for(o=l!=1,f=l!=0,te=0,_=e.a,y=0,x=_.length;yS)?(l=2,s=AP):l==0?(l=1,s=te):(l=0,s=te)):(m=te>=s||s-te0?1:Pl(isNaN(i),!1))>=0^(fS(TV),(r.Math.abs(c)<=TV||c==0?0:c<0?-1:c>0?1:Pl(isNaN(c),!1))>=0)?r.Math.max(c,i):(fS(TV),(r.Math.abs(i)<=TV||i==0?0:i<0?-1:i>0?1:Pl(isNaN(i),!1))>0?r.Math.sqrt(c*c+i*i):-r.Math.sqrt(c*c+i*i))}function LN(e,t){var n,r,i,a,o,s;if(t){if(!e.a&&(e.a=new Yr),e.e==2){Gr(e.a,t);return}if(t.e==1){for(i=0;i=pI?pl(n,vE(r)):Ah(n,r&OF),o=(++W9,new __(10,null,0)),xPe(e.a,o,s-1)):(n=(o.Mm().length+a,new ea),pl(n,o.Mm())),t.e==0?(r=t.Km(),r>=pI?pl(n,vE(r)):Ah(n,r&OF)):pl(n,t.Mm()),P(o,530).b=n.a}}function Hpt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(!n.dc()){for(s=0,f=0,r=n.Kc(),m=P(r.Pb(),17).a;s1&&(c=l.Hg(c,e.a,s));return c.c.length==1?P(Ep(c,c.c.length-1),238):c.c.length==2?Ept((ov(0,c.c.length),P(c.c[0],238)),(ov(1,c.c.length),P(c.c[1],238)),o,a):null}function qpt(e,t,n){var r,i,a,o,s,c,l;for(n.Ug(`Find roots`,1),e.a.c.length=0,i=dO(t.b,0);i.b!=i.d.c;)r=P(Lv(i),40),r.b.b==0&&(W(r,(tP(),a4),(rd(),!0)),M(e.a,r));switch(e.a.c.length){case 0:a=new Ow(0,t,`DUMMY_ROOT`),W(a,(tP(),a4),(rd(),!0)),W(a,W2,!0),up(t.b,a);break;case 1:break;default:for(o=new Ow(0,t,LV),c=new w(e.a);c.a=r.Math.abs(i.b)?(i.b=0,o.d+o.a>s.d&&o.ds.c&&o.c0){if(t=new $c(e.i,e.g),n=e.i,a=n<100?null:new Pa(n),e.Tj())for(r=0;r0){for(s=e.g,l=e.i,Ey(e),a=l<100?null:new Pa(l),r=0;r>13|(e.m&15)<<9,i=e.m>>4&8191,a=e.m>>17|(e.h&255)<<5,o=(e.h&1048320)>>8,s=t.l&8191,c=t.l>>13|(t.m&15)<<9,l=t.m>>4&8191,u=t.m>>17|(t.h&255)<<5,d=(t.h&1048320)>>8,f,p,m,h,g,_,v,y,b,x,S,ee,te=n*s,ne=r*s,C=i*s,re=a*s,ie=o*s;return c!=0&&(ne+=n*c,C+=r*c,re+=i*c,ie+=a*c),l!=0&&(C+=n*l,re+=r*l,ie+=i*l),u!=0&&(re+=n*u,ie+=r*u),d!=0&&(ie+=n*d),p=te&QF,m=(ne&511)<<13,f=p+m,g=te>>22,_=ne>>9,v=(C&262143)<<4,y=(re&31)<<17,h=g+_+v+y,x=C>>18,S=re>>5,ee=(ie&4095)<<8,b=x+S+ee,h+=f>>22,f&=QF,b+=h>>22,h&=QF,b&=$F,vu(f,h,b)}function Qpt(e){var t,n,i,a,o,s,c=P(Ep(e.j,0),12);if(c.g.c.length!=0&&c.e.c.length!=0)throw E(new Ii(`Interactive layout does not support NORTH/SOUTH ports with incoming _and_ outgoing edges.`));if(c.g.c.length!=0){for(o=cI,n=new w(c.g);n.a4){if(e.fk(t)){if(e.al()){if(i=P(t,54),r=i.Eh(),c=r==e.e&&(e.ml()?i.yh(i.Fh(),e.il())==e.jl():-1-i.Fh()==e.Lj()),e.nl()&&!c&&!r&&i.Jh()){for(a=0;a0&&Cet(e,s,d);for(i=new w(d);i.ae.d[o.p]&&(n+=$He(e.b,a)*P(c.b,17).a,Rv(e.a,G(a)));for(;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function nmt(e,t){var n,r,i,a,o,s,c,l,u=P(K(e,(Y(),TQ)),64),d;if(r=P(Ep(e.j,0),12),u==(nP(),Z8)?tj(r,m5):u==m5&&tj(r,Z8),P(K(t,(mP(),W1)),181).Hc((TD(),x5))){if(c=D(N(K(e,g0))),l=D(N(K(e,_0))),o=D(N(K(e,m0))),s=P(K(t,e0),21),s.Hc((rj(),G8)))for(n=l,d=e.o.a/2-r.n.a,a=new w(r.f);a.a0&&(l=e.n.a/a);break;case 2:case 4:i=e.i.o.b,i>0&&(l=e.n.b/i)}W(e,(Y(),$Q),l)}if(c=e.o,o=e.a,r)o.a=r.a,o.b=r.b,e.d=!0;else if(t!=V8&&t!=H8&&s!=h5)switch(s.g){case 1:o.a=c.a/2;break;case 2:o.a=c.a,o.b=c.b/2;break;case 3:o.a=c.a/2,o.b=c.b;break;case 4:o.b=c.b/2}else o.a=c.a/2,o.b=c.b/2}function zN(e){var t,n,r,i,a,o,s,c,l,u;if(e.Pj()){if(u=e.Ej(),c=e.Qj(),u>0){if(t=new hC(e.pj()),n=u,a=n<100?null:new Pa(n),zd(e,n,t.g),i=n==1?e.Ij(4,H(t,0),null,0,c):e.Ij(6,t,null,-1,c),e.Mj()){for(r=new Lu(t);r.e!=r.i.gc();)a=e.Oj(gO(r),a);a?(a.nj(i),a.oj()):e.Jj(i)}else a?(a.nj(i),a.oj()):e.Jj(i)}else zd(e,e.Ej(),e.Fj()),e.Jj(e.Ij(6,(Vg(),QG),null,-1,c))}else if(e.Mj()){if(u=e.Ej(),u>0){for(s=e.Fj(),l=u,zd(e,u,s),a=l<100?null:new Pa(l),r=0;r1&&Lp(o)*Ip(o)/2>s[0]){for(a=0;as[a];)++a;m=new $_(h,0,a+1),d=new Fx(m),u=Lp(o)/Ip(o),c=cP(d,t,new ni,n,r,i,u),$d(Cl(d.e),c),ep(gA(f,d),bI),p=new $_(h,a+1,h.c.length),m6e(f,p),h.c.length=0,l=0,mNe(s,s.length,0)}else g=f.b.c.length==0?null:Ep(f.b,0),g!=null&&LS(f,0),l>0&&(s[l]=s[l-1]),s[l]+=Lp(o)*Ip(o),++l,Mr(h.c,o);return h}function cmt(e,t){var n=t.b,r,i,a=new bf(n.j);i=0,r=n.j,r.c.length=0,$m(P(TC(e.b,(nP(),Z8),(kS(),jX)),15),n),i=HO(a,i,new wre,r),$m(P(TC(e.b,Z8,AX),15),n),i=HO(a,i,new _re,r),$m(P(TC(e.b,Z8,kX),15),n),$m(P(TC(e.b,X8,jX),15),n),$m(P(TC(e.b,X8,AX),15),n),i=HO(a,i,new Tre,r),$m(P(TC(e.b,X8,kX),15),n),$m(P(TC(e.b,m5,jX),15),n),i=HO(a,i,new Ere,r),$m(P(TC(e.b,m5,AX),15),n),i=HO(a,i,new Dre,r),$m(P(TC(e.b,m5,kX),15),n),$m(P(TC(e.b,g5,jX),15),n),i=HO(a,i,new bre,r),$m(P(TC(e.b,g5,AX),15),n),$m(P(TC(e.b,g5,kX),15),n)}function lmt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p;for(s=new w(t);s.a.5?v-=s*2*(h-.5):h<.5&&(v+=o*2*(.5-h)),a=c.d.b,v_.a-g-d&&(v=_.a-g-d),c.n.a=t+v}}function hmt(e){var t,n,r=P(K(e,(mP(),M1)),171),i,a;if(r==(XE(),h$)){for(n=new pm(Vu(DE(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),18),!OUe(t))throw E(new zi(LR+xk(e)+`' has its layer constraint set to FIRST_SEPARATE, but has at least one incoming edge. FIRST_SEPARATE nodes must not have incoming edges.`))}else if(r==_$){for(a=new pm(Vu(OE(e).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),!OUe(i))throw E(new zi(LR+xk(e)+`' has its layer constraint set to LAST_SEPARATE, but has at least one outgoing edge. LAST_SEPARATE nodes must not have outgoing edges.`))}}function BN(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m;if(e.e&&e.c.c>19&&(t=mw(t),c=!c),o=Bat(t),a=!1,i=!1,r=!1,e.h==eI&&e.m==0&&e.l==0){if(i=!0,a=!0,o==-1)e=xCe(($b(),hG)),r=!0,c=!c;else return s=$rt(e,o),c&&ww(s),n&&(mG=vu(0,0,0)),s}else e.h>>19&&(a=!0,e=mw(e),r=!0,c=!c);return o==-1?W6e(e,t)<0?(n&&(mG=a?mw(e):vu(e.l,e.m,e.h)),vu(0,0,0)):jut(r?e:vu(e.l,e.m,e.h),t,c,a,i,n):LZe(e,o,c,a,n)}function VN(e,t){var n,r,i,a,o=e.e,s,c=t.e,l,u,d,f,p,m;if(o==0)return t;if(c==0)return e;if(a=e.d,s=t.d,a+s==2)return n=uv(e.a[0],_I),r=uv(t.a[0],_I),o==c?(u=yE(n,r),m=nm(u),p=nm(um(u,32)),p==0?new Xv(o,m):new Bm(o,2,U(O(q9,1),HF,28,15,[m,p]))):(AM(),sl(o<0?xE(r,n):xE(n,r),0)?yD(o<0?xE(r,n):xE(n,r)):Xm(yD(kb(o<0?xE(r,n):xE(n,r)))));if(o==c)f=o,d=a>=s?Yy(e.a,a,t.a,s):Yy(t.a,s,e.a,a);else{if(i=a==s?lQe(e.a,t.a,a):a>s?1:-1,i==0)return AM(),JG;i==1?(f=o,d=ky(e.a,a,t.a,s)):(f=c,d=ky(t.a,s,e.a,a))}return l=new Bm(f,d.length,d),Cv(l),l}function vmt(e,t){var n,r,i,a,o,s,c;if(!(e.g>t.f||t.g>e.f)){for(n=0,r=0,o=e.w.a.ec().Kc();o.Ob();)i=P(o.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,t.g,t.f)&&++n;for(s=e.r.a.ec().Kc();s.Ob();)i=P(s.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,t.g,t.f)&&--n;for(c=t.w.a.ec().Kc();c.Ob();)i=P(c.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,e.g,e.f)&&++r;for(a=t.r.a.ec().Kc();a.Ob();)i=P(a.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,e.g,e.f)&&--r;n=0)return n;switch(qh(Rb(e,n))){case 2:if(ff(``,AT(e,n.qk()).xe())){if(c=ug(Rb(e,n)),s=lg(Rb(e,n)),u=Hit(e,t,c,s),u)return u;for(i=$lt(e,t),o=0,d=i.gc();o1)throw E(new Fi(CW));for(u=nM(e.e.Dh(),t),r=P(e.g,124),o=0;o1,u=new Ny(p.b);gu(u.a)||gu(u.b);)l=P(gu(u.a)?z(u.a):z(u.b),18),f=l.c==p?l.d:l.c,r.Math.abs(Sw(U(O(K3,1),X,8,0,[f.i.n,f.n,f.a])).b-s.b)>1&&ust(e,l,s,o,p)}}function wmt(e){var t,n,i,a=new bv(e.e,0),o,s;if(i=new bv(e.a,0),e.d)for(n=0;nAV;){for(o=t,s=0;r.Math.abs(t-o)0),a.a.Xb(a.c=--a.b),Zdt(e,e.b-s,o,i,a),jd(a.b0),i.a.Xb(i.c=--i.b)}if(!e.d)for(n=0;n0?(e.f[d.p]=m/(d.e.c.length+d.g.c.length),e.c=r.Math.min(e.c,e.f[d.p]),e.b=r.Math.max(e.b,e.f[d.p])):c&&(e.f[d.p]=m)}}function Emt(e){e.b=null,e.bb=null,e.fb=null,e.qb=null,e.a=null,e.c=null,e.d=null,e.e=null,e.f=null,e.n=null,e.M=null,e.L=null,e.Q=null,e.R=null,e.K=null,e.db=null,e.eb=null,e.g=null,e.i=null,e.j=null,e.k=null,e.gb=null,e.o=null,e.p=null,e.q=null,e.r=null,e.$=null,e.ib=null,e.S=null,e.T=null,e.t=null,e.s=null,e.u=null,e.v=null,e.w=null,e.B=null,e.A=null,e.C=null,e.D=null,e.F=null,e.G=null,e.H=null,e.I=null,e.J=null,e.P=null,e.Z=null,e.U=null,e.V=null,e.W=null,e.X=null,e.Y=null,e._=null,e.ab=null,e.cb=null,e.hb=null,e.nb=null,e.lb=null,e.mb=null,e.ob=null,e.pb=null,e.jb=null,e.kb=null,e.N=!1,e.O=!1}function Dmt(e,t,n){var r,i,a,o;for(n.Ug(`Graph transformation (`+e.a+`)`,1),o=lv(t.a),a=new w(t.b);a.a=s.b.c)&&(s.b=t),(!s.c||t.c<=s.c.c)&&(s.d=s.c,s.c=t),(!s.e||t.d>=s.e.d)&&(s.e=t),(!s.f||t.d<=s.f.d)&&(s.f=t);return r=new xO((ow(),kJ)),vv(e,yOt,new Wi(U(O(OJ,1),FP,382,0,[r]))),o=new xO(MJ),vv(e,vOt,new Wi(U(O(OJ,1),FP,382,0,[o]))),i=new xO(AJ),vv(e,_Ot,new Wi(U(O(OJ,1),FP,382,0,[i]))),a=new xO(jJ),vv(e,gOt,new Wi(U(O(OJ,1),FP,382,0,[a]))),Vj(r.c,kJ),Vj(i.c,AJ),Vj(a.c,jJ),Vj(o.c,MJ),s.a.c.length=0,nw(s.a,r.c),nw(s.a,UE(i.c)),nw(s.a,a.c),nw(s.a,UE(o.c)),s}function Amt(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h;for(t.Ug(Yxt,1),m=D(N(J(e,(xM(),Z4)))),s=D(N(J(e,(gM(),a3)))),c=P(J(e,i3),107),BS((!e.a&&(e.a=new F($5,e,10,11)),e.a)),d=Mpt((!e.a&&(e.a=new F($5,e,10,11)),e.a),m,s),!e.a&&(e.a=new F($5,e,10,11)),u=new w(d);u.a0&&(e.a=c+(m-1)*a,t.c.b+=e.a,t.f.b+=e.a)),h.a.gc()!=0&&(p=new ah(1,a),m=fht(p,t,h,g,t.f.b+c-t.c.b),m>0&&(t.f.b+=c+(m-1)*a))}function Mmt(e,t,n){var i,a,o,s,c,l,u,d=D(N(K(e,(mP(),d0)))),f,p,m,h,g,_,v,y,b,x;for(i=D(N(K(e,_Mt))),p=new en,W(p,d0,d+i),u=t,v=u.d,g=u.c.i,y=u.d.i,_=Ll(g.c),b=Ll(y.c),a=new T,f=_;f<=b;f++)c=new ZO(e),En(c,(DA(),qJ)),W(c,(Y(),WQ),u),W(c,Q1,(rA(),R8)),W(c,p0,p),m=P(Ep(e.b,f),30),f==_?Ak(c,m.a.c.length-n,m):W_(c,m),x=D(N(K(u,T1))),x<0&&(x=0,W(u,T1,x)),c.o.b=x,h=r.Math.floor(x/2),s=new jA,tj(s,(nP(),g5)),G_(s,c),s.n.b=h,l=new jA,tj(l,X8),G_(l,c),l.n.b=h,K_(u,s),o=new i_,VC(o,u),W(o,j1,null),U_(o,l),K_(o,v),Y6e(c,u,o),Mr(a.c,o),u=o;return a}function WN(e,t){var n,r,i,a,o,s,c=P(NA(e,(nP(),g5)).Kc().Pb(),12).e,l,u,d,f,p=P(NA(e,X8).Kc().Pb(),12).g,m,h,g,_,v,y;for(s=c.c.length,y=rv(P(Ep(e.j,0),12));s-->0;){for(h=(ov(0,c.c.length),P(c.c[0],18)),i=(ov(0,p.c.length),P(p.c[0],18)),v=i.d.e,a=Ab(v,i,0),JBe(h,i.d,a),U_(i,null),K_(i,null),m=h.a,t&&up(m,new Vl(y)),r=dO(i.a,0);r.b!=r.d.c;)n=P(Lv(r),8),up(m,new Vl(n));for(_=h.b,f=new w(i.b);f.ao)&&Lm(e.b,P(g.b,18));++s}a=o}}}function Pmt(e,t){var n;if(t==null||ff(t,IP)||t.length==0&&e.k!=(VA(),V3))return null;switch(e.k.g){case 1:return qD(t,DH)?(rd(),yG):qD(t,OH)?(rd(),vG):null;case 2:try{return G(GM(t,xF,AP))}catch(e){if(e=ew(e),j(e,130))return null;throw E(e)}case 4:try{return OA(t)}catch(e){if(e=ew(e),j(e,130))return null;throw E(e)}case 3:return t;case 5:return kQe(e),Nnt(e,t);case 6:return kQe(e),aat(e,e.a,t);case 7:try{return n=Lrt(e),n.cg(t),n}catch(e){if(e=ew(e),j(e,33))return null;throw E(e)}default:throw E(new Ii(`Invalid type set for this layout option.`))}}function Fmt(e){var t;switch(e.d){case 1:if(e.Sj())return e.o!=-2;break;case 2:if(e.Sj())return e.o==-2;break;case 3:case 5:case 4:case 6:case 7:return e.o>-2;default:return!1}switch(t=e.Rj(),e.p){case 0:return t!=null&&ki(Od(t))!=cl(e.k,0);case 1:return t!=null&&P(t,222).a!=nm(e.k)<<24>>24;case 2:return t!=null&&P(t,180).a!=(nm(e.k)&OF);case 6:return t!=null&&cl(P(t,168).a,e.k);case 5:return t!=null&&P(t,17).a!=nm(e.k);case 7:return t!=null&&P(t,191).a!=nm(e.k)<<16>>16;case 3:return t!=null&&D(N(t))!=e.j;case 4:return t!=null&&P(t,161).a!=e.j;default:return t==null?e.n!=null:!NT(t,e.n)}}function GN(e,t,n){var r,i,a,o;return e.ol()&&e.nl()&&(o=Am(e,P(n,58)),A(o)!==A(n))?(e.xj(t),e.Dj(t,CGe(e,t,o)),e.al()&&(a=(i=P(n,54),e.ml()?e.kl()?i.Th(e.b,qO(P(_x(d_(e.b),e.Lj()),19)).n,P(_x(d_(e.b),e.Lj()).Hk(),29).kk(),null):i.Th(e.b,eD(i.Dh(),qO(P(_x(d_(e.b),e.Lj()),19))),null,null):i.Th(e.b,-1-e.Lj(),null,null)),!P(o,54).Ph()&&(a=(r=P(o,54),e.ml()?e.kl()?r.Rh(e.b,qO(P(_x(d_(e.b),e.Lj()),19)).n,P(_x(d_(e.b),e.Lj()).Hk(),29).kk(),a):r.Rh(e.b,eD(r.Dh(),qO(P(_x(d_(e.b),e.Lj()),19))),null,a):r.Rh(e.b,-1-e.Lj(),null,a))),a&&a.oj()),Gl(e.b)&&e.Jj(e.Ij(9,n,o,t,!1)),o):n}function Imt(e){var t,n,r=new T,i,a,o,s,c,l,u;for(o=new w(e.e.a);o.a0&&(s=r.Math.max(s,hYe(e.C.b+i.d.b,a))),d=i,f=a,p=o;e.C&&e.C.c>0&&(m=p+e.C.c,u&&(m+=d.d.c),s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(f-1)<=fL||f==1?0:m/(1-f)))),n.n.b=0,n.a.a=s}function Rmt(e,t){var n=P(ig(e.b,t),127),i,a,o,s,c,l=P(P(Dy(e.r,t),21),87),u,d,f,p,m;if(l.dc()){n.n.d=0,n.n.a=0;return}for(u=e.u.Hc((rj(),G8)),s=0,e.A.Hc((TD(),x5))&&ilt(e,t),c=l.Kc(),d=null,p=0,f=0;c.Ob();)i=P(c.Pb(),117),o=D(N(i.b.of((nd(),uq)))),a=i.b.Mf().b,d?(m=f+d.d.a+e.w+i.d.d,s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(p-o)<=fL||p==o||isNaN(p)&&isNaN(o)?0:m/(o-p)))):e.C&&e.C.d>0&&(s=r.Math.max(s,hYe(e.C.d+i.d.d,o))),d=i,p=o,f=a;e.C&&e.C.a>0&&(m=f+e.C.a,u&&(m+=d.d.a),s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(p-1)<=fL||p==1?0:m/(1-p)))),n.n.d=0,n.a.b=s}function zmt(e,t,n,r,i,a,o,s){var c,l,u,d,f,p,m=!1,h,g,_;if(l=vot(n.q,t.f+t.b-n.q.f),p=r.f>t.b&&s,_=i-(n.q.e+l-o),d=(c=vN(r,_,!1),c.a),p&&d>r.f)return!1;if(p){for(f=0,g=new w(t.d);g.a=(ov(a,e.c.length),P(e.c[a],186)).e,!p&&d>t.b&&!u)?!1:((u||p||d<=t.b)&&(u&&d>t.b?(n.d=d,fb(n,X9e(n,d))):(Z8e(n.q,l),n.c=!0),fb(r,i-(n.s+n.r)),WO(r,n.q.e+n.q.d,t.f),hS(t,r),e.c.length>a&&(Fk((ov(a,e.c.length),P(e.c[a],186)),r),(ov(a,e.c.length),P(e.c[a],186)).a.c.length==0&&Ay(e,a)),m=!0),m)}function Bmt(e,t,n){var r,i,a,o,s,c;for(this.g=e,s=t.d.length,c=n.d.length,this.d=V(UJ,jR,10,s+c,0,1),o=0;o0?jx(this,this.f/this.a):Eu(t.g,t.d[0]).a!=null&&Eu(n.g,n.d[0]).a!=null?jx(this,(D(Eu(t.g,t.d[0]).a)+D(Eu(n.g,n.d[0]).a))/2):Eu(t.g,t.d[0]).a==null?Eu(n.g,n.d[0]).a!=null&&jx(this,Eu(n.g,n.d[0]).a):jx(this,Eu(t.g,t.d[0]).a)}function Vmt(e,t){var n,r,i,a,o,s,c,l,u,d;for(e.a=new nFe($Xe(a8)),r=new w(t.a);r.a=1&&(g-o>0&&d>=0?(c.n.a+=h,c.n.b+=a*o):g-o<0&&u>=0&&(c.n.a+=h*g,c.n.b+=a));e.o.a=t.a,e.o.b=t.b,W(e,(mP(),W1),(TD(),r=P(Ba(S5),9),new xf(r,P(Yd(r,r.length),9),0)))}function Kmt(e,t,n,r,i,a){var o;if(!(t==null||!zE(t,FVt,IVt)))throw E(new Fi(`invalid scheme: `+t));if(!e&&!(n!=null&&Nl(n,mA(35))==-1&&n.length>0&&(sv(0,n.length),n.charCodeAt(0)!=47)))throw E(new Fi(`invalid opaquePart: `+n));if(e&&!(t!=null&&po(x7,t.toLowerCase()))&&!(n==null||!zE(n,y7,b7))||e&&t!=null&&po(x7,t.toLowerCase())&&!y5e(n))throw E(new Fi(cwt+n));if(!W1e(r))throw E(new Fi(`invalid device: `+r));if(!QQe(i))throw o=i==null?`invalid segments: null`:`invalid segment: `+LQe(i),E(new Fi(o));if(a!=null&&Nl(a,mA(35))!=-1)throw E(new Fi(`invalid query: `+a))}function qmt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v;if(n.Ug(`Network simplex layering`,1),e.b=t,v=P(K(t,(mP(),C0)),17).a*4,_=e.b.a,_.c.length<1){n.Vg();return}for(o=nut(e,_),g=null,a=dO(o,0);a.b!=a.d.c;){for(i=P(Lv(a),15),c=v*C_(r.Math.sqrt(i.gc())),s=kut(i),HM(da(jve(fa(Nf(s),c),g),!0),n.eh(1)),p=e.b.b,h=new w(s.a);h.a1)for(g=V(q9,HF,28,e.b.b.c.length,15,1),f=0,u=new w(e.b.b);u.a0){aO(e,n,0),n.a+=String.fromCharCode(r),i=n2e(t,a),aO(e,n,i),a+=i-1;continue}r==39?a+10&&m.a<=0){c.c.length=0,Mr(c.c,m);break}p=m.i-m.d,p>=s&&(p>s&&(c.c.length=0,s=p),Mr(c.c,m))}c.c.length!=0&&(o=P(Ep(c,VO(i,c.c.length)),118),y.a.Bc(o),o.g=u++,Jdt(o,t,n,r),c.c.length=0)}for(g=e.c.length+1,f=new w(e);f.alI||t.o==T2&&u=s&&i<=c)s<=i&&a<=c?(n[u++]=i,n[u++]=a,r+=2):s<=i?(n[u++]=i,n[u++]=c,e.b[r]=c+1,o+=2):a<=c?(n[u++]=s,n[u++]=a,r+=2):(n[u++]=s,n[u++]=c,e.b[r]=c+1);else if(cbF)&&c<10);ma(e.c,new cee),eht(e),wPe(e.c),Omt(e.f)}function oht(e,t){var n=P(K(e,(mP(),Q1)),101),i,a,o,s=e.f,c,l,u,d,f,p,m,h,g;for(o=e.d,c=s.a+o.b+o.c,l=0-o.d-e.c.b,d=s.b+o.d+o.a-e.c.b,u=new T,f=new T,a=new w(t);a.a=2){for(c=dO(n,0),o=P(Lv(c),8),s=P(Lv(c),8);s.a0&&fw(l,!0,(GT(),n8)),s.k==(DA(),GJ)&&_Fe(l),Qh(e.f,s,t)}}function lht(e){var t,n,i,a=P(K(e,(tP(),t4)),27),o,s,c,l,u=AP,d=AP,f,p,m,h,g,_,v,y,b,x;for(c=xF,l=xF,b=dO(e.b,0);b.b!=b.d.c;)v=P(Lv(b),40),m=v.e,h=v.f,u=r.Math.min(u,m.a-h.a/2),d=r.Math.min(d,m.b-h.b/2),c=r.Math.max(c,m.a+h.a/2),l=r.Math.max(l,m.b+h.b/2);for(p=P(J(a,(rN(),fFt)),107),y=dO(e.b,0);y.b!=y.d.c;)v=P(Lv(y),40),f=K(v,t4),j(f,207)&&(o=P(f,27),$l(o,v.e.a,v.e.b),qj(o,v));for(_=dO(e.a,0);_.b!=_.d.c;)g=P(Lv(_),65),i=P(K(g,t4),74),i&&(t=g.a,n=cM(i,!0,!0),cN(t,n));x=c-u+(p.b+p.c),s=l-d+(p.d+p.a),ki(Od(J(a,(vP(),T6))))||iP(a,x,s,!1,!1),OO(a,u6,x-(p.b+p.c)),OO(a,l6,s-(p.d+p.a))}function uht(e,t){var n,r,i,a,o,s,c=!0,l,u,f;for(i=0,l=e.g[t.p],u=t.o.b+e.o,n=e.d[t.p][2],uy(e.b,l,G(P(Ep(e.b,l),17).a-1+n)),uy(e.c,l,D(N(Ep(e.c,l)))-u+n*e.f),++l,l>=e.j?(++e.j,M(e.b,G(1)),M(e.c,u)):(r=e.d[t.p][1],uy(e.b,l,G(P(Ep(e.b,l),17).a+1-r)),uy(e.c,l,D(N(Ep(e.c,l)))+u-r*e.f)),(e.r==(FM(),q0)&&(P(Ep(e.b,l),17).a>e.k||P(Ep(e.b,l-1),17).a>e.k)||e.r==J0&&(D(N(Ep(e.c,l)))>e.n||D(N(Ep(e.c,l-1)))>e.n))&&(c=!1),o=new pm(Vu(DE(t).a.Kc(),new d));Cj(o);)a=P(by(o),18),s=a.c.i,e.g[s.p]==l&&(f=uht(e,s),i+=P(f.a,17).a,c&&=ki(Od(f.b)));return e.g[t.p]=l,i+=e.d[t.p][0],new Kc(G(i),(rd(),!!c))}function dht(e,t){var n=D(N(K(t,(mP(),c0)))),r,i,a,o;n<2&&W(t,c0,2),r=P(K(t,_1),88),r==(GT(),r8)&&W(t,_1,cE(t)),i=P(K(t,lMt),17),i.a==0?W(t,(Y(),t$),new YE):W(t,(Y(),t$),new sy(i.a)),a=Od(K(t,B1)),a??W(t,B1,(rd(),A(K(t,S1))===A((wE(),l8)))),To(new Mp(null,new cv(t.a,16)),new cr(e)),To(ox(new Mp(null,new cv(t.b,16)),new Ht),new lr(e)),o=new Hmt(t),W(t,(Y(),o$),o),cg(e.a),Um(e.a,(vA(),vJ),P(K(t,g1),188)),Um(e.a,yJ,P(K(t,F1),188)),Um(e.a,bJ,P(K(t,h1),188)),Um(e.a,xJ,P(K(t,U1),188)),Um(e.a,SJ,dXe(P(K(t,S1),223))),Bl(e.a,$_t(t)),W(t,e$,BN(e.a,t))}function fht(e,t,n,i,a){var o,s,c,l,u,d,f=new Dr,p,m,h,g,_,v;for(s=new T,ett(e,n,e.d.Ag(),s,f),ett(e,i,e.d.Bg(),s,f),e.b=.2*(g=_it(ox(new Mp(null,new cv(s,16)),new $ie)),_=_it(ox(new Mp(null,new cv(s,16)),new eae)),r.Math.min(g,_)),o=0,c=0;c=2&&(v=jat(s,!0,p),!e.e&&(e.e=new Ome(e)),Z0e(e.e,v,s,e.b)),W5e(s,p),xht(s),m=-1,d=new w(s);d.as)}function hht(e,t){var n,i,a,o,s,c,l,u=cI,d=cI,f,p,m,h,g,_,v,y;for(c=lI,l=lI,p=new w(t.i);p.a-1){for(a=dO(c,0);a.b!=a.d.c;)i=P(Lv(a),131),i.v=s;for(;c.b!=0;)for(i=P(Mk(c,0),131),n=new w(i.i);n.a-1){for(o=new w(c);o.a0)&&(Xde(l,r.Math.min(l.o,a.o-1)),On(l,l.i-1),l.i==0&&Mr(c.c,l))}}function Sht(e,t,n,i,a){var o,s,c,l=cI;return s=!1,c=Kft(e,ef(new k(t.a,t.b),e),$d(new k(n.a,n.b),a),ef(new k(i.a,i.b),n)),o=!!c&&!(r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH||r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH),c=Kft(e,ef(new k(t.a,t.b),e),n,a),c&&((r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH)==(r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH)||o?l=r.Math.min(l,Ih(ef(c,n))):s=!0),c=Kft(e,ef(new k(t.a,t.b),e),i,a),c&&(s||(r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH)==(r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH)||o)&&(l=r.Math.min(l,Ih(ef(c,i)))),l}function Cht(e){Wo(e,new oA(ga(ya(ha(va(_a(new Zt,hR),gbt),`Minimizes the stress within a layout using stress majorization. Stress exists if the euclidean distance between a pair of nodes doesn't match their graph theoretic distance, that is, the shortest path between the two nodes. The method allows to specify individual edge lengths.`),new ree),YL))),B(e,hR,tR,hO(dJ)),B(e,hR,rR,(rd(),!0)),B(e,hR,sR,hO(tOt)),B(e,hR,gR,hO(nOt)),B(e,hR,oR,hO(rOt)),B(e,hR,cR,hO(eOt)),B(e,hR,iR,hO(pJ)),B(e,hR,lR,hO(iOt)),B(e,hR,dbt,hO(uJ)),B(e,hR,pbt,hO(cJ)),B(e,hR,mbt,hO(lJ)),B(e,hR,hbt,hO(fJ)),B(e,hR,fbt,hO(sJ))}function wht(e){var t=null,n,r,i,a,o,s,c;for(r=new w(e);r.a0&&n.c==0&&(!t&&(t=new T),Mr(t.c,n));if(t)for(;t.c.length!=0;){if(n=P(Ay(t,0),239),n.b&&n.b.c.length>0){for(a=(!n.b&&(n.b=new T),new w(n.b));a.aAb(e,n,0))return new Kc(i,n)}else if(D(Eu(i.g,i.d[0]).a)>D(Eu(n.g,n.d[0]).a))return new Kc(i,n)}for(s=(!n.e&&(n.e=new T),n.e).Kc();s.Ob();)o=P(s.Pb(),239),c=(!o.b&&(o.b=new T),o.b),av(0,c.c.length),Ts(c.c,0,n),o.c==c.c.length&&Mr(t.c,o)}return null}function Tht(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_;for(t.Ug(`Interactive crossing minimization`,1),o=0,a=new w(e.b);a.a0&&(n+=c.n.a+c.o.a/2,++d),m=new w(c.j);m.a0&&(n/=d),_=V(Z9,hI,28,r.a.c.length,15,1),s=0,l=new w(r.a);l.a=s&&i<=c)s<=i&&a<=c?r+=2:s<=i?(e.b[r]=c+1,o+=2):a<=c?(n[u++]=i,n[u++]=s-1,r+=2):(n[u++]=i,n[u++]=s-1,e.b[r]=c+1,o+=2);else if(c2?(d=new T,nw(d,new $_(v,1,v.b)),o=dvt(d,b+e.a),y=new wj(o),VC(y,t),Mr(n.c,y)):y=P(i?xh(e.b,xA(t)):xh(e.b,SA(t)),272),l=xA(t),i&&(l=SA(t)),s=met(_,l),u=b+e.a,s.a?(u+=r.Math.abs(_.b-f.b),g=new k(f.a,(f.b+_.b)/2)):(u+=r.Math.abs(_.a-f.a),g=new k((f.a+_.a)/2,f.b)),Qh(i?e.d:e.c,t,new u3e(y,s,g,u)),Qh(e.b,t,y),h=(!t.n&&(t.n=new F(Q5,t,1,7)),t.n),m=new Lu(h);m.e!=m.i.gc();)p=P(gO(m),135),a=OM(e,p,!0,0,0),Mr(n.c,a)}function Dht(e){var t,n,r,i,a,o,s;if(!e.A.dc()){if(e.A.Hc((TD(),b5))&&(P(ig(e.b,(nP(),Z8)),127).k=!0,P(ig(e.b,m5),127).k=!0,t=e.q!=(rA(),z8)&&e.q!=R8,Ide(P(ig(e.b,X8),127),t),Ide(P(ig(e.b,g5),127),t),Ide(e.g,t),e.A.Hc(x5)&&(P(ig(e.b,Z8),127).j=!0,P(ig(e.b,m5),127).j=!0,P(ig(e.b,X8),127).k=!0,P(ig(e.b,g5),127).k=!0,e.g.k=!0)),e.A.Hc(y5))for(e.a.j=!0,e.a.k=!0,e.g.j=!0,e.g.k=!0,s=e.B.Hc((UM(),O5)),i=sO(),a=0,o=i.length;a0),P(u.a.Xb(u.c=--u.b),18));a!=r&&u.b>0;)e.a[a.p]=!0,e.a[r.p]=!0,a=(jd(u.b>0),P(u.a.Xb(u.c=--u.b),18));u.b>0&&Fh(u)}}function Aht(e,t,n){var r,i,a,o,s,c,l,u,d,f,p;if(!e.b)return!1;for(o=null,f=null,c=new $y(null,null),i=1,c.a[1]=e.b,d=c;d.a[i];)l=i,s=f,f=d,d=d.a[i],r=e.a.Ne(t,d.d),i=r<0?0:1,r==0&&(!n.c||rg(d.e,n.d))&&(o=d),!(d&&d.b)&&!Ji(d.a[i])&&(Ji(d.a[1-i])?f=f.a[l]=FS(d,i):Ji(d.a[1-i])||(p=f.a[1-l],p&&(!Ji(p.a[1-l])&&!Ji(p.a[l])?(f.b=!1,p.b=!0,d.b=!0):(a=+(s.a[1]==f),Ji(p.a[l])?s.a[a]=SBe(f,l):Ji(p.a[1-l])&&(s.a[a]=FS(f,l)),d.b=s.a[a].b=!0,s.a[a].a[0].b=!1,s.a[a].a[1].b=!1))));return o&&(n.b=!0,n.d=o.e,d!=o&&(u=new $y(d.d,d.e),V7e(e,c,o,u),f==o&&(f=u)),f.a[+(f.a[1]==d)]=d.a[+!d.a[0]],--e.c),e.b=c.a[1],e.b&&(e.b.b=!1),n.b}function jht(e){var t,n,i,a,o,s,c,l,u,d,f,p;for(a=new w(e.a.a.b);a.a0?i-=864e5:i+=864e5,c=new gDe(yE(LC(t.q.getTime()),i))),u=new na,l=e.a.length,a=0;a=97&&r<=122||r>=65&&r<=90){for(o=a+1;o=l)throw E(new Fi(`Missing trailing '`));o+1=14&&u<=16))?t.a._b(r)?(n.a?gl(n.a,n.b):n.a=new Gu(n.d),ml(n.a,`[...]`)):(s=rS(r),l=new jp(t),jy(n,Fht(s,l))):j(r,183)?jy(n,Ftt(P(r,183))):j(r,195)?jy(n,z5e(P(r,195))):j(r,201)?jy(n,F9e(P(r,201))):j(r,2111)?jy(n,B5e(P(r,2111))):j(r,53)?jy(n,Ptt(P(r,53))):j(r,376)?jy(n,unt(P(r,376))):j(r,846)?jy(n,Ntt(P(r,846))):j(r,109)&&jy(n,Mtt(P(r,109))):jy(n,r==null?IP:PE(r));return n.a?n.e.length==0?n.a.a:n.a.a+(``+n.e):n.c}function qN(e,t){var n,r,i,a=e.F;t==null?(e.F=null,Gw(e,null)):(e.F=(Gh(t),t),r=Nl(t,mA(60)),r==-1?(i=t,Nl(t,mA(46))==-1&&(r=Nl(t,mA(91)),r!=-1&&(i=(Zy(0,r,t.length),t.substr(0,r))),!ff(i,DP)&&!ff(i,BU)&&!ff(i,VU)&&!ff(i,HU)&&!ff(i,UU)&&!ff(i,WU)&&!ff(i,GU)&&!ff(i,KU)?(i=Swt,r!=-1&&(i+=``+(sv(r,t.length+1),t.substr(r)))):i=t),Gw(e,i),i==t&&(e.F=e.D)):(i=(Zy(0,r,t.length),t.substr(0,r)),Nl(t,mA(46))==-1&&!ff(i,DP)&&!ff(i,BU)&&!ff(i,VU)&&!ff(i,HU)&&!ff(i,UU)&&!ff(i,WU)&&!ff(i,GU)&&!ff(i,KU)&&(i=Swt),n=Hu(t,mA(62)),n!=-1&&(i+=``+(sv(n+1,t.length+1),t.substr(n+1))),Gw(e,i))),e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,5,a,t))}function Iht(e,t){var n,r,i,a,o,s,c=t.length-1,l,u,d;if(s=(sv(c,t.length),t.charCodeAt(c)),s==93){if(o=Nl(t,mA(91)),o>=0)return i=F1e(e,(Zy(1,o,t.length),t.substr(1,o-1))),u=(Zy(o+1,c,t.length),t.substr(o+1,c-(o+1))),V_t(e,u,i)}else{if(n=-1,HTt??=RegExp(`\\d`),HTt.test(String.fromCharCode(s))&&(n=pf(t,mA(46),c-1),n>=0)){r=P(wy(e,lqe(e,(Zy(1,n,t.length),t.substr(1,n-1))),!1),61),l=0;try{l=GM((sv(n+1,t.length+1),t.substr(n+1)),xF,AP)}catch(e){throw e=ew(e),j(e,130)?(a=e,E(new Nb(a))):E(e)}if(l>16==-10?n=P(e.Cb,292).Yk(t,n):e.Db>>16==-15&&(!t&&(t=(CP(),q7)),!l&&(l=(CP(),q7)),e.Cb.Yh()&&(c=new Hb(e.Cb,1,13,l,t,NO(Ib(P(e.Cb,62)),e),!1),n?n.nj(c):n=c));else if(j(e.Cb,90))e.Db>>16==-23&&(j(t,90)||(t=(CP(),J7)),j(l,90)||(l=(CP(),J7)),e.Cb.Yh()&&(c=new Hb(e.Cb,1,10,l,t,NO(Jv(P(e.Cb,29)),e),!1),n?n.nj(c):n=c));else if(j(e.Cb,457))for(s=P(e.Cb,850),o=(!s.b&&(s.b=new Sr(new ui)),s.b),a=(r=new EC(new Fn(o.a).a),new Cr(r));a.a.b;)i=P(MS(a.a).ld(),89),n=JN(i,Rj(i,s),n)}return n}function zht(e,t){var n,r,i,a,o=ki(Od(J(e,(mP(),k1)))),s,c,l,u,d,f=P(J(e,e0),21);for(c=!1,l=!1,d=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));d.e!=d.i.gc()&&(!c||!l);){for(a=P(gO(d),123),s=0,i=jm(oS(U(O(KW,1),FP,20,0,[(!a.d&&(a.d=new cf(U5,a,8,5)),a.d),(!a.e&&(a.e=new cf(U5,a,7,4)),a.e)])));Cj(i)&&(r=P(by(i),74),u=o&&uj(r)&&ki(Od(J(r,A1))),n=$pt((!r.b&&(r.b=new cf(H5,r,4,7)),r.b),a)?e==I_(cA(P(H((!r.c&&(r.c=new cf(H5,r,5,8)),r.c),0),84))):e==I_(cA(P(H((!r.b&&(r.b=new cf(H5,r,4,7)),r.b),0),84))),!((u||n)&&(++s,s>1))););(s>0||f.Hc((rj(),G8))&&(!a.n&&(a.n=new F(Q5,a,1,7)),a.n).i>0)&&(c=!0),s>1&&(l=!0)}c&&t.Fc((uM(),KZ)),l&&t.Fc((uM(),qZ))}function Bht(e){var t,n,i,a,o,s,c,l,u,d,f,p=P(J(e,(vP(),w6)),21);if(p.dc())return null;if(c=0,s=0,p.Hc((TD(),b5))){for(d=P(J(e,I6),101),i=2,n=2,a=2,o=2,t=I_(e)?P(J(I_(e),p6),88):P(J(e,p6),88),u=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));u.e!=u.i.gc();)if(l=P(gO(u),123),f=P(J(l,B6),64),f==(nP(),h5)&&(f=Wdt(l,t),OO(l,B6,f)),d==(rA(),R8))switch(f.g){case 1:i=r.Math.max(i,l.i+l.g);break;case 2:n=r.Math.max(n,l.j+l.f);break;case 3:a=r.Math.max(a,l.i+l.g);break;case 4:o=r.Math.max(o,l.j+l.f)}else switch(f.g){case 1:i+=l.g+2;break;case 2:n+=l.f+2;break;case 3:a+=l.g+2;break;case 4:o+=l.f+2}c=r.Math.max(i,a),s=r.Math.max(n,o)}return iP(e,c,s,!0,!0)}function YN(e,t,n,i,a){var o,s,c,l,u,d,f,p,m,h,g,_,v,y=P(ay(Cx(hg(new Mp(null,new cv(t.d,16)),new Jpe(n)),new Ype(n)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),b,x;for(f=AP,d=xF,l=new w(t.b.j);l.a0,l?l&&(f=_.p,o?++f:--f,d=P(Ep(_.c.a,f),10),r=rZe(d),p=!(Kj(r,S,n[0])||rPe(r,S,n[0]))):p=!0),m=!1,x=t.D.i,x&&x.c&&s.e&&(u=o&&x.p>0||!o&&x.p=0){for(c=null,s=new bv(u.a,l+1);s.bs?1:Pl(!1,isNaN(s)))<0&&(fS(TV),(r.Math.abs(s-1)<=TV||s==1?0:s<1?-1:s>1?1:Pl(isNaN(s),!1))<0)&&(fS(TV),(r.Math.abs(0-c)<=TV||c==0?0:0c?1:Pl(!1,isNaN(c)))<0)&&(fS(TV),(r.Math.abs(c-1)<=TV||c==1?0:c<1?-1:c>1?1:Pl(isNaN(c),!1))<0)),o)}function qht(e){var t,n=e.D==null?e.B:e.D,r,i;if(t=Nl(n,mA(91)),t!=-1){r=(Zy(0,t,n.length),n.substr(0,t)),i=new $i;do i.a+=`[`;while((t=fd(n,91,++t))!=-1);ff(r,DP)?i.a+=`Z`:ff(r,BU)?i.a+=`B`:ff(r,VU)?i.a+=`C`:ff(r,HU)?i.a+=`D`:ff(r,UU)?i.a+=`F`:ff(r,WU)?i.a+=`I`:ff(r,GU)?i.a+=`J`:ff(r,KU)?i.a+=`S`:(i.a+=`L`,i.a+=``+r,i.a+=`;`);try{return null}catch(e){if(e=ew(e),!j(e,63))throw E(e)}}else if(Nl(n,mA(46))==-1){if(ff(n,DP))return J9;if(ff(n,BU))return X9;if(ff(n,VU))return K9;if(ff(n,HU))return Z9;if(ff(n,UU))return Q9;if(ff(n,WU))return q9;if(ff(n,GU))return Y9;if(ff(n,KU))return $9}return null}function Jht(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;for(e.e=t,s=znt(t),S=new T,r=new w(s);r.a=0&&h=u.c.c.length?sHe((DA(),JJ),qJ):sHe((DA(),qJ),qJ),d*=2,o=n.a.g,n.a.g=r.Math.max(o,o+(d-o)),s=n.b.g,n.b.g=r.Math.max(s,s+(d-s)),a=t}}function Qht(e){var t,n,i,a;for(To(hg(new Mp(null,new cv(e.a.b,16)),new rre),new ire),r5e(e),To(hg(new Mp(null,new cv(e.a.b,16)),new are),new ore),e.c==(wE(),d8)&&(To(hg(ox(new Mp(null,new cv(new Pn(e.f),1)),new sre),new cre),new Vpe(e)),To(hg(gg(ox(ox(new Mp(null,new cv(e.d.b,16)),new lre),new ure),new dre),new fre),new Upe(e))),a=new k(cI,cI),t=new k(lI,lI),i=new w(e.a.b);i.a `):t.a+=`Root `,n=e.Dh().zb,ff(n.substr(0,3),`Elk`)?gl(t,(sv(3,n.length+1),n.substr(3))):t.a+=``+n,i=e.jh(),i){gl((t.a+=` `,t),i);return}if(j(e,366)&&(l=P(e,135).a,l)){gl((t.a+=` `,t),l);return}for(o=new Lu(e.kh());o.e!=o.i.gc();)if(a=P(gO(o),135),l=a.a,l){gl((t.a+=` `,t),l);return}if(j(e,326)&&(r=P(e,74),!r.b&&(r.b=new cf(H5,r,4,7)),r.b.i!=0&&(!r.c&&(r.c=new cf(H5,r,5,8)),r.c.i!=0))){for(t.a+=` (`,s=new cd((!r.b&&(r.b=new cf(H5,r,4,7)),r.b));s.e!=s.i.gc();)s.e>0&&(t.a+=PP),$N(P(gO(s),167),t);for(t.a+=kR,c=new cd((!r.c&&(r.c=new cf(H5,r,5,8)),r.c));c.e!=c.i.gc();)c.e>0&&(t.a+=PP),$N(P(gO(c),167),t);t.a+=`)`}}function $ht(e,t,n){var i,a,o,s,c,l,u,f;for(l=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));l.e!=l.i.gc();)for(c=P(gO(l),27),a=new pm(Vu(Ij(c).a.Kc(),new d));Cj(a);){if(i=P(by(a),74),!i.b&&(i.b=new cf(H5,i,4,7)),!(i.b.i<=1&&(!i.c&&(i.c=new cf(H5,i,5,8)),i.c.i<=1)))throw E(new Bi(`Graph must not contain hyperedges.`));if(!yj(i)&&c!=cA(P(H((!i.c&&(i.c=new cf(H5,i,5,8)),i.c),0),84)))for(u=new tOe,VC(u,i),W(u,(jS(),iJ),i),zde(u,P(nl(Kp(n.f,c)),153)),Hde(u,P(xh(n,cA(P(H((!i.c&&(i.c=new cf(H5,i,5,8)),i.c),0),84))),153)),M(t.c,u),s=new Lu((!i.n&&(i.n=new F(Q5,i,1,7)),i.n));s.e!=s.i.gc();)o=P(gO(s),135),f=new $Ve(u,o.a),VC(f,o),W(f,iJ,o),f.e.a=r.Math.max(o.g,1),f.e.b=r.Math.max(o.f,1),Hft(f),M(t.d,f)}}function egt(e,t,n){var i,a,o,s,c,l,u,d,f,p;switch(n.Ug(`Node promotion heuristic`,1),e.i=t,e.r=P(K(t,(mP(),P1)),243),e.r!=(FM(),G0)&&e.r!=K0?Vgt(e):Zst(e),d=P(K(e.i,Gjt),17).a,o=new Jte,e.r.g){case 2:case 1:PN(e,o);break;case 3:for(e.r=X0,PN(e,o),l=0,c=new w(e.b);c.ae.k&&(e.r=q0,PN(e,o));break;case 4:for(e.r=X0,PN(e,o),u=0,a=new w(e.c);a.ae.n&&(e.r=J0,PN(e,o));break;case 6:p=C_(r.Math.ceil(e.g.length*d/100)),PN(e,new kpe(p));break;case 5:f=C_(r.Math.ceil(e.e*d/100)),PN(e,new Ape(f));break;case 8:yvt(e,!0);break;case 9:yvt(e,!1);break;default:PN(e,o)}e.r!=G0&&e.r!=K0?est(e,t):xlt(e,t),n.Vg()}function tgt(e){var t,n,r,i,a,o,s,c,l,u,d=e.b,f,p,m,h,g,_,v,y;for(u=new bv(d,0),qd(u,new Eh(e)),v=!1,o=1;u.b0&&(p.d+=d.n.d,p.d+=d.d),p.a>0&&(p.a+=d.n.a,p.a+=d.d),p.b>0&&(p.b+=d.n.b,p.b+=d.d),p.c>0&&(p.c+=d.n.c,p.c+=d.d),p}function rgt(e,t,n){var i,a,o,s,c,l,u,d,f,p=n.d,m,h;for(f=n.c,o=new k(n.f.a+n.d.b+n.d.c,n.f.b+n.d.d+n.d.a),s=o.b,u=new w(e.a);u.a0&&(e.c[t.c.p][t.p].d+=Lj(e.i,24)*kI*.07000000029802322-.03500000014901161,e.c[t.c.p][t.p].a=e.c[t.c.p][t.p].d/e.c[t.c.p][t.p].b)}}function sgt(e){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;for(m=new w(e);m.ai.d,i.d=r.Math.max(i.d,t),c&&n&&(i.d=r.Math.max(i.d,i.a),i.a=i.d+a);break;case 3:n=t>i.a,i.a=r.Math.max(i.a,t),c&&n&&(i.a=r.Math.max(i.a,i.d),i.d=i.a+a);break;case 2:n=t>i.c,i.c=r.Math.max(i.c,t),c&&n&&(i.c=r.Math.max(i.b,i.c),i.b=i.c+a);break;case 4:n=t>i.b,i.b=r.Math.max(i.b,t),c&&n&&(i.b=r.Math.max(i.b,i.c),i.c=i.b+a)}}}function ugt(e,t){var n,r,i,a,o,s,c,l=``,u;return t.length==0?e.ne(ryt,wF,-1,-1):(u=qA(t),ff(u.substr(0,3),`at `)&&(u=(sv(3,u.length+1),u.substr(3))),u=u.replace(/\[.*?\]/g,``),o=u.indexOf(`(`),o==-1?(o=u.indexOf(`@`),o==-1?(l=u,u=``):(l=qA((sv(o+1,u.length+1),u.substr(o+1))),u=qA((Zy(0,o,u.length),u.substr(0,o))))):(n=u.indexOf(`)`,o),l=(Zy(o+1,n,u.length),u.substr(o+1,n-(o+1))),u=qA((Zy(0,o,u.length),u.substr(0,o)))),o=Nl(u,mA(46)),o!=-1&&(u=(sv(o+1,u.length+1),u.substr(o+1))),(u.length==0||ff(u,`Anonymous function`))&&(u=wF),s=Hu(l,mA(58)),i=pf(l,mA(58),s-1),c=-1,r=-1,a=ryt,s!=-1&&i!=-1&&(a=(Zy(0,i,l.length),l.substr(0,i)),c=dEe((Zy(i+1,s,l.length),l.substr(i+1,s-(i+1)))),r=dEe((sv(s+1,l.length+1),l.substr(s+1)))),e.ne(a,u,c,r))}function dgt(e){var t,n,r,i,a,o,s,c,l,u,d;for(l=new w(e);l.a0||u.j==g5&&u.e.c.length-u.g.c.length<0)){t=!1;break}for(i=new w(u.g);i.a=u&&S>=_&&(p+=h.n.b+g.n.b+g.a.b-x,++c));if(n)for(s=new w(y.e);s.a=u&&S>=_&&(p+=h.n.b+g.n.b+g.a.b-x,++c))}c>0&&(ee+=p/c,++m)}m>0?(t.a=a*ee/m,t.g=m):(t.a=0,t.g=0)}function pgt(e){var t,n,r,i,a=e.f.b,o,s,c,l,u,d,f=a.a,p,m,h,g,_,v,y,b,x,S,ee;for(u=a.b,m=e.e.g,p=e.e.f,Ql(e.e,a.a,a.b),S=f/m,ee=u/p,l=new Lu(ag(e.e));l.e!=l.i.gc();)c=P(gO(l),135),Gx(c,c.i*S),Kx(c,c.j*ee);for(v=new Lu(og(e.e));v.e!=v.i.gc();)_=P(gO(v),123),b=_.i,x=_.j,b>0&&Gx(_,b*S),x>0&&Kx(_,x*ee);for(xC(e.b,new eee),t=new T,s=new EC(new Fn(e.c).a);s.b;)o=MS(s),r=P(o.ld(),74),n=P(o.md(),407).a,i=cM(r,!1,!1),d=$5e(xA(r),FA(i),n),cN(d,i),y=Q7e(r),y&&Ab(t,y,0)==-1&&(Mr(t.c,y),$Fe(y,(jd(d.b!=0),P(d.a.a.c,8)),n));for(g=new EC(new Fn(e.d).a);g.b;)h=MS(g),r=P(h.ld(),74),n=P(h.md(),407).a,i=cM(r,!1,!1),d=$5e(SA(r),Ew(FA(i)),n),d=Ew(d),cN(d,i),y=$7e(r),y&&Ab(t,y,0)==-1&&(Mr(t.c,y),$Fe(y,(jd(d.b!=0),P(d.c.b.c,8)),n))}function mgt(e,t,n,r){var i,a,o,s=new Agt(t),c;return xot(s,r),i=!0,e&&e.pf((vP(),p6))&&(a=P(e.of((vP(),p6)),88),i=a==(GT(),r8)||a==t8||a==n8),Uct(s,!1),Dx(s.e.Rf(),new Af(s,!1,i)),x_(s,s.f,(Ix(),XK),(nP(),Z8)),x_(s,s.f,QK,m5),x_(s,s.g,XK,g5),x_(s,s.g,QK,X8),e4e(s,Z8),e4e(s,m5),VFe(s,X8),VFe(s,g5),Rd(),o=s.A.Hc((TD(),v5))&&s.B.Hc((UM(),D5))?w0e(s):null,o&&Eve(s.a,o),lgt(s),A3e(s),j3e(s),Dht(s),hdt(s),k6e(s),eO(s,Z8),eO(s,m5),flt(s),Gpt(s),n?(I1e(s),A6e(s),eO(s,X8),eO(s,g5),c=s.B.Hc((UM(),O5)),wtt(s,c,Z8),wtt(s,c,m5),Ttt(s,c,X8),Ttt(s,c,g5),To(new Mp(null,new cv(new Bn(s.i),0)),new it),To(hg(new Mp(null,ch(s.r).a.oc()),new at),new ot),k5e(s),s.e.Pf(s.o),To(new Mp(null,ch(s.r).a.oc()),new st),s.o):s.o}function hgt(e){var t,n,i,a,o,s,c,l,u=cI,d,f,p,m,h,g;for(i=new w(e.a.b);i.a1)for(m=new Xpt(h,b,i),ly(b,new Qxe(e,m)),Mr(s.c,m),f=b.a.ec().Kc();f.Ob();)d=P(f.Pb(),42),Db(o,d.b);if(c.a.gc()>1)for(m=new Xpt(h,c,i),ly(c,new $xe(e,m)),Mr(s.c,m),f=c.a.ec().Kc();f.Ob();)d=P(f.Pb(),42),Db(o,d.b)}}function bgt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g=e.n,_=e.o,v;if(p=e.d,f=D(N(gD(e,(mP(),o0)))),t){for(d=f*(t.gc()-1),m=0,l=t.Kc();l.Ob();)s=P(l.Pb(),10),d+=s.o.a,m=r.Math.max(m,s.o.b);for(v=g.a-(d-_.a)/2,o=g.b-p.d+m,i=_.a/(t.gc()+1),a=i,c=t.Kc();c.Ob();)s=P(c.Pb(),10),s.n.a=v,s.n.b=o-s.o.b,v+=s.o.a+f,u=Uat(s),u.n.a=s.o.a/2-u.a.a,u.n.b=s.o.b,h=P(K(s,(Y(),pQ)),12),h.e.c.length+h.g.c.length==1&&(h.n.a=a-h.a.a,h.n.b=0,G_(h,e)),a+=i}if(n){for(d=f*(n.gc()-1),m=0,l=n.Kc();l.Ob();)s=P(l.Pb(),10),d+=s.o.a,m=r.Math.max(m,s.o.b);for(v=g.a-(d-_.a)/2,o=g.b+_.b+p.a-m,i=_.a/(n.gc()+1),a=i,c=n.Kc();c.Ob();)s=P(c.Pb(),10),s.n.a=v,s.n.b=o,v+=s.o.a+f,u=Uat(s),u.n.a=s.o.a/2-u.a.a,u.n.b=0,h=P(K(s,(Y(),pQ)),12),h.e.c.length+h.g.c.length==1&&(h.n.a=a-h.a.a,h.n.b=_.b,G_(h,e)),a+=i}}function xgt(e,t){var n,i,a,o,s,c;if(P(K(t,(Y(),OQ)),21).Hc((uM(),KZ))){for(c=new w(t.a);c.a=0&&o0&&(P(ig(e.b,t),127).a.b=n)}function Ogt(e,t,n,r){var i,a,o,s,c,l,u,d,f=D(N(K(e,(mP(),g0)))),p=D(N(K(e,_0))),m,h;if(d=D(N(K(e,m0))),s=e.o,a=P(Ep(e.j,0),12),o=a.n,h=jet(a,d),h){if(t.Hc((rj(),G8)))switch(P(K(e,(Y(),TQ)),64).g){case 1:h.c=(s.a-h.b)/2-o.a,h.d=p;break;case 3:h.c=(s.a-h.b)/2-o.a,h.d=-p-h.a;break;case 2:n&&a.e.c.length==0&&a.g.c.length==0?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=s.b+p-o.b,h.c=-f-h.b;break;case 4:n&&a.e.c.length==0&&a.g.c.length==0?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=s.b+p-o.b,h.c=f}else if(t.Hc(q8))switch(P(K(e,(Y(),TQ)),64).g){case 1:case 3:h.c=o.a+f;break;case 2:case 4:n&&!a.c?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=o.b+p}for(i=h.d,l=new w(a.f);l.a=e.length)return{done:!0};var r=e[n++];return{value:[r,t.get(r)],done:!1}}}},Oct()||(e.prototype.createObject=function(){return{}},e.prototype.get=function(e){return this.obj[`:`+e]},e.prototype.set=function(e,t){this.obj[`:`+e]=t},e.prototype[TI]=function(e){delete this.obj[`:`+e]},e.prototype.keys=function(){var e=[];for(var t in this.obj)t.charCodeAt(0)==58&&e.push(t.substring(1));return e}),e}function tP(){tP=C,t4=new yr(sbt),new yr(cbt),new Wd(`DEPTH`,G(0)),G2=new Wd(`FAN`,G(0)),RPt=new Wd(ixt,G(0)),a4=new Wd(`ROOT`,(rd(),!1)),Y2=new Wd(`LEFTNEIGHBOR`,null),HPt=new Wd(`RIGHTNEIGHBOR`,null),X2=new Wd(`LEFTSIBLING`,null),i4=new Wd(`RIGHTSIBLING`,null),W2=new Wd(`DUMMY`,!1),new Wd(`LEVEL`,G(0)),VPt=new Wd(`REMOVABLE_EDGES`,new vo),o4=new Wd(`XCOOR`,G(0)),s4=new Wd(`YCOOR`,G(0)),Z2=new Wd(`LEVELHEIGHT`,0),$2=new Wd(`LEVELMIN`,0),Q2=new Wd(`LEVELMAX`,0),K2=new Wd(`GRAPH_XMIN`,0),q2=new Wd(`GRAPH_YMIN`,0),zPt=new Wd(`GRAPH_XMAX`,0),BPt=new Wd(`GRAPH_YMAX`,0),LPt=new Wd(`COMPACT_LEVEL_ASCENSION`,!1),U2=new Wd(`COMPACT_CONSTRAINTS`,new T),J2=new Wd(`ID`,``),n4=new Wd(`POSITION`,G(0)),r4=new Wd(`PRELIM`,0),e4=new Wd(`MODIFIER`,0),H2=new yr(lbt),V2=new yr(ubt)}function Fgt(e){Bdt();var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(e==null)return null;if(d=e.length*8,d==0)return``;for(s=d%24,p=d/24|0,f=s==0?p:p+1,a=null,a=V(K9,EF,28,f*4,15,1),l=0,u=0,t=0,n=0,r=0,o=0,i=0,c=0;c>24,l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,h=n&-128?(n>>4^240)<<24>>24:n>>4<<24>>24,g=r&-128?(r>>6^252)<<24>>24:r>>6<<24>>24,a[o++]=j9[m],a[o++]=j9[h|l<<4],a[o++]=j9[u<<2|g],a[o++]=j9[r&63];return s==8?(t=e[i],l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,a[o++]=j9[m],a[o++]=j9[l<<4],a[o++]=61,a[o++]=61):s==16&&(t=e[i],n=e[i+1],u=(n&15)<<24>>24,l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,h=n&-128?(n>>4^240)<<24>>24:n>>4<<24>>24,a[o++]=j9[m],a[o++]=j9[h|l<<4],a[o++]=j9[u<<2],a[o++]=61),ND(a,0,a.length)}function Igt(e,t){var n,i,a,o,s,c,l;if(e.e==0&&e.p>0&&(e.p=-(e.p-1)),e.p>xF&&aHe(t,e.p-VF),s=t.q.getDate(),j_(t,1),e.k>=0&&vRe(t,e.k),e.c>=0?j_(t,e.c):e.k>=0?(l=new xZe(t.q.getFullYear()-VF,t.q.getMonth(),35),i=35-l.q.getDate(),j_(t,r.Math.min(i,s))):j_(t,s),e.f<0&&(e.f=t.q.getHours()),e.b>0&&e.f<12&&(e.f+=12),Xwe(t,e.f==24&&e.g?0:e.f),e.j>=0&&QUe(t,e.j),e.n>=0&&qWe(t,e.n),e.i>=0&&hCe(t,yE(bE(Wk(LC(t.q.getTime()),DF),DF),e.i)),e.a&&(a=new uo,aHe(a,a.q.getFullYear()-VF-80),rs(LC(t.q.getTime()),LC(a.q.getTime()))&&aHe(t,a.q.getFullYear()-VF+100)),e.d>=0){if(e.c==-1)n=(7+e.d-t.q.getDay())%7,n>3&&(n-=7),c=t.q.getMonth(),j_(t,t.q.getDate()+n),t.q.getMonth()!=c&&j_(t,t.q.getDate()+(n>0?-7:7));else if(t.q.getDay()!=e.d)return!1}return e.o>xF&&(o=t.q.getTimezoneOffset(),hCe(t,yE(LC(t.q.getTime()),(e.o-o)*60*DF))),!0}function Lgt(e,t){var n,r,i=K(t,(Y(),WQ)),a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b;if(j(i,207)){for(m=P(i,27),h=t.e,f=new Vl(t.c),a=t.d,f.a+=a.b,f.b+=a.d,b=P(J(m,(mP(),q1)),181),$u(b,(UM(),w5))&&(p=P(J(m,Xjt),107),Mde(p,a.a),Vde(p,a.d),Nde(p,a.b),Bde(p,a.c)),n=new T,u=new w(t.a);u.ar.c.length-1;)M(r,new Kc(zL,zV));n=P(K(i,p4),17).a,ql(P(K(e,c4),88))?(i.e.aD(N((ov(n,r.c.length),P(r.c[n],42)).b))&&An((ov(n,r.c.length),P(r.c[n],42)),i.e.a+i.f.a)):(i.e.bD(N((ov(n,r.c.length),P(r.c[n],42)).b))&&An((ov(n,r.c.length),P(r.c[n],42)),i.e.b+i.f.b))}for(a=dO(e.b,0);a.b!=a.d.c;)i=P(Lv(a),40),n=P(K(i,(rN(),p4)),17).a,W(i,(tP(),$2),N((ov(n,r.c.length),P(r.c[n],42)).a)),W(i,Q2,N((ov(n,r.c.length),P(r.c[n],42)).b));t.Vg()}function Vgt(e){var t,n,i,a,o,s,c,l,u,f,p,m,h,g,_;for(e.o=D(N(K(e.i,(mP(),v0)))),e.f=D(N(K(e.i,f0))),e.j=e.i.b.c.length,c=e.j-1,m=0,e.k=0,e.n=0,e.b=Oy(V(DG,X,17,e.j,0,1)),e.c=Oy(V(TG,X,345,e.j,7,1)),s=new w(e.i.b);s.a0&&M(e.q,f),M(e.p,f);t-=i,h=l+t,u+=t*e.f,uy(e.b,c,G(h)),uy(e.c,c,u),e.k=r.Math.max(e.k,h),e.n=r.Math.max(e.n,u),e.e+=t,t+=_}}function nP(){nP=C;var e;h5=new Vc(dL,0),Z8=new Vc(_L,1),X8=new Vc(vL,2),m5=new Vc(yL,3),g5=new Vc(bL,4),n5=(Vg(),new oa((e=P(Ba(_5),9),new xf(e,P(Yd(e,e.length),9),0)))),r5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[]))),Q8=yT(Zp(X8,U(O(_5,1),TR,64,0,[]))),d5=yT(Zp(m5,U(O(_5,1),TR,64,0,[]))),p5=yT(Zp(g5,U(O(_5,1),TR,64,0,[]))),c5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[m5]))),t5=yT(Zp(X8,U(O(_5,1),TR,64,0,[g5]))),u5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[g5]))),i5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8]))),f5=yT(Zp(m5,U(O(_5,1),TR,64,0,[g5]))),$8=yT(Zp(X8,U(O(_5,1),TR,64,0,[m5]))),s5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,g5]))),e5=yT(Zp(X8,U(O(_5,1),TR,64,0,[m5,g5]))),l5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[m5,g5]))),a5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,m5]))),o5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,m5,g5])))}function Hgt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;for(t.Ug(Lbt,1),h=new T,S=new T,l=new w(e.b);l.a0&&(x-=h),mmt(s,x),f=0,m=new w(s.a);m.a0),c.a.Xb(c.c=--c.b)),l=.4*i*f,!o&&c.b0&&(c=(sv(0,t.length),t.charCodeAt(0)),c!=64)){if(c==37&&(d=t.lastIndexOf(`%`),l=!1,d!=0&&(d==f-1||(l=(sv(d+1,t.length),t.charCodeAt(d+1)==46))))){if(o=(Zy(1,d,t.length),t.substr(1,d-1)),y=ff(`%`,o)?null:n_t(o),r=0,l)try{r=GM((sv(d+2,t.length+1),t.substr(d+2)),xF,AP)}catch(e){throw e=ew(e),j(e,130)?(s=e,E(new Nb(s))):E(e)}for(g=NS(e.Gh());g.Ob();)if(m=IC(g),j(m,519)&&(i=P(m,598),v=i.d,(y==null?v==null:ff(y,v))&&r--==0))return i;return null}if(u=t.lastIndexOf(`.`),p=u==-1?t:(Zy(0,u,t.length),t.substr(0,u)),n=0,u!=-1)try{n=GM((sv(u+1,t.length+1),t.substr(u+1)),xF,AP)}catch(e){if(e=ew(e),j(e,130))p=t;else throw E(e)}for(p=ff(`%`,p)?null:n_t(p),h=NS(e.Gh());h.Ob();)if(m=IC(h),j(m,197)&&(a=P(m,197),_=a.xe(),(p==null?_==null:ff(p,_))&&n--==0))return a;return null}return Iht(e,t)}function Zgt(e){var t,n,r,i,a,o,s,c,l,u=new Dr,f,p,m,h,g,_,v,y;for(c=new g_,r=new w(e.a.a.b);r.at.d.c){if(m=e.c[t.a.d],_=e.c[f.a.d],m==_)continue;tM(Ao(ko(jo(Oo(new Zr,1),100),m),_))}}}}}function Qgt(e,t){var n,i,a,o,s,c,l,u,d,f,p=P(P(Dy(e.r,t),21),87),m,h,g,_,v,y,b,x,S,ee;if(t==(nP(),X8)||t==g5){Dgt(e,t);return}for(o=t==Z8?(KC(),dq):(KC(),mq),x=t==Z8?(Xb(),sq):(Xb(),aq),n=P(ig(e.b,t),127),i=n.i,a=i.c+Tx(U(O(Z9,1),hI,28,15,[n.n.b,e.C.b,e.k])),v=i.c+i.b-Tx(U(O(Z9,1),hI,28,15,[n.n.c,e.C.c,e.k])),s=pa(Pf(o),e.t),y=t==Z8?lI:cI,f=p.Kc();f.Ob();)u=P(f.Pb(),117),!(!u.c||u.c.d.c.length<=0)&&(_=u.b.Mf(),g=u.e,m=u.c,h=m.i,h.b=(l=m.n,m.e.a+l.b+l.c),h.a=(c=m.n,m.e.b+c.d+c.a),c_(x,Iyt),m.f=x,nb(m,(Cb(),iq)),h.c=g.a-(h.b-_.a)/2,S=r.Math.min(a,g.a),ee=r.Math.max(v,g.a+_.a),h.cee&&(h.c=ee-h.b),M(s.d,new $p(h,qT(s,h))),y=t==Z8?r.Math.max(y,g.b+u.b.Mf().b):r.Math.min(y,g.b));for(y+=t==Z8?e.t:-e.t,b=nD((s.e=y,s)),b>0&&(P(ig(e.b,t),127).a.b=b),d=p.Kc();d.Ob();)u=P(d.Pb(),117),!(!u.c||u.c.d.c.length<=0)&&(h=u.c.i,h.c-=u.e.a,h.d-=u.e.b)}function $gt(e){var t=new Dr,n,r,i,a,o,s,c,l,u,f,p,m;for(c=new Lu(e);c.e!=c.i.gc();){for(s=P(gO(c),27),n=new Jr,Qh(Rq,s,n),m=new It,i=P(ay(new Mp(null,new ih(new pm(Vu(Fj(s).a.Kc(),new d)))),pNe(m,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)])))),85),tJe(n,P(i.xc((rd(),!0)),16),new Lt),r=P(ay(hg(P(i.xc(!1),15).Lc(),new Rt),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),o=r.Kc();o.Ob();)a=P(o.Pb(),74),p=Q7e(a),p&&(l=P(nl(Kp(t.f,p)),21),l||(l=wst(p),XA(t.f,p,l)),XS(n,l));for(i=P(ay(new Mp(null,new ih(new pm(Vu(Ij(s).a.Kc(),new d)))),pNe(m,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK])))),85),tJe(n,P(i.xc(!0),16),new zt),r=P(ay(hg(P(i.xc(!1),15).Lc(),new Bt),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),f=r.Kc();f.Ob();)u=P(f.Pb(),74),p=$7e(u),p&&(l=P(nl(Kp(t.f,p)),21),l||(l=wst(p),XA(t.f,p,l)),XS(n,l))}}function e_t(e,t){wN();var n,r,i,a,o,s,c=dT(e,0)<0,l,u,d,f,p,m,h;if(c&&(e=kb(e)),dT(e,0)==0)switch(t){case 0:return`0`;case 1:return vI;case 2:return`0.00`;case 3:return`0.000`;case 4:return`0.0000`;case 5:return`0.00000`;case 6:return`0.000000`;default:return p=new ta,t<0?p.a+=`0E+`:p.a+=`0E`,p.a+=t==xF?`2147483648`:``+-t,p.a}u=18,d=V(K9,EF,28,u+1,15,1),n=u,h=e;do l=h,h=Wk(h,10),d[--n]=nm(yE(48,xE(l,bE(h,10))))&OF;while(dT(h,0)!=0);if(i=xE(xE(xE(u,n),t),1),t==0)return c&&(d[--n]=45),ND(d,n,u-n);if(t>0&&dT(i,-6)>=0){if(dT(i,0)>=0){for(a=n+nm(i),s=u-1;s>=a;s--)d[s+1]=d[s];return d[++a]=46,c&&(d[--n]=45),ND(d,n,u-n+1)}for(o=2;rs(o,yE(kb(i),1));o++)d[--n]=48;return d[--n]=46,d[--n]=48,c&&(d[--n]=45),ND(d,n,u-n)}return m=n+1,r=u,f=new na,c&&(f.a+=`-`),r-m>=1?(jh(f,d[n]),f.a+=`.`,f.a+=ND(d,n+1,u-n-1)):f.a+=ND(d,n,u-n),f.a+=`E`,dT(i,0)>0&&(f.a+=`+`),f.a+=``+bm(i),f.a}function iP(e,t,n,i,a){var o,s,c,l,u,d,f,p,m,h,g,_=new k(e.g,e.f),v,y,b,x,S,ee;if(g=Zet(e),g.a=r.Math.max(g.a,t),g.b=r.Math.max(g.b,n),ee=g.a/_.a,d=g.b/_.b,x=g.a-_.a,l=g.b-_.b,i)for(s=I_(e)?P(J(I_(e),(vP(),p6)),88):P(J(e,(vP(),p6)),88),c=A(J(e,(vP(),I6)))===A((rA(),R8)),y=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));y.e!=y.i.gc();)switch(v=P(gO(y),123),b=P(J(v,B6),64),b==(nP(),h5)&&(b=Wdt(v,s),OO(v,B6,b)),b.g){case 1:c||Gx(v,v.i*ee);break;case 2:Gx(v,v.i+x),c||Kx(v,v.j*d);break;case 3:c||Gx(v,v.i*ee),Kx(v,v.j+l);break;case 4:c||Kx(v,v.j*d)}if(Ql(e,g.a,g.b),a)for(p=new Lu((!e.n&&(e.n=new F(Q5,e,1,7)),e.n));p.e!=p.i.gc();)f=P(gO(p),135),m=f.i+f.g/2,h=f.j+f.f/2,S=m/_.a,u=h/_.b,S+u>=1&&(S-u>0&&h>=0?(Gx(f,f.i+x),Kx(f,f.j+l*u)):S-u<0&&m>=0&&(Gx(f,f.i+x*S),Kx(f,f.j+l)));return OO(e,(vP(),w6),(TD(),o=P(Ba(S5),9),new xf(o,P(Yd(o,o.length),9),0))),new k(ee,d)}function t_t(e){Wo(e,new oA(ga(ya(ha(va(_a(new Zt,iH),`ELK Radial`),`A radial layout provider which is based on the algorithm of Peter Eades published in "Drawing free trees.", published by International Institute for Advanced Study of Social Information Science, Fujitsu Limited in 1991. The radial layouter takes a tree and places the nodes in radial order around the root. The nodes of the same tree level are placed on the same radius.`),new doe),iH))),B(e,iH,fV,hO(mIt)),B(e,iH,ZL,hO(vIt)),B(e,iH,sR,hO(cIt)),B(e,iH,gR,hO(lIt)),B(e,iH,oR,hO(uIt)),B(e,iH,cR,hO(sIt)),B(e,iH,iR,hO(dIt)),B(e,iH,lR,hO(pIt)),B(e,iH,tH,hO(k4)),B(e,iH,eH,hO(A4)),B(e,iH,$V,hO(hIt)),B(e,iH,nH,hO(N4)),B(e,iH,rH,hO(gIt)),B(e,iH,Ext,hO(_It)),B(e,iH,Txt,hO(fIt)),B(e,iH,xxt,hO(j4)),B(e,iH,Sxt,hO(M4)),B(e,iH,Cxt,hO(P4)),B(e,iH,wxt,hO(yIt)),B(e,iH,bxt,hO(oIt))}function aP(e){var t,n,r,i,a,o,s,c,l,u,d;if(e==null)throw E(new aa(IP));if(l=e,a=e.length,c=!1,a>0&&(t=(sv(0,e.length),e.charCodeAt(0)),(t==45||t==43)&&(e=(sv(1,e.length+1),e.substr(1)),--a,c=t==45)),a==0)throw E(new aa(sI+l+`"`));for(;e.length>0&&(sv(0,e.length),e.charCodeAt(0)==48);)e=(sv(1,e.length+1),e.substr(1)),--a;if(a>(xdt(),WTt)[10])throw E(new aa(sI+l+`"`));for(i=0;i0&&(d=-parseInt((Zy(0,r,e.length),e.substr(0,r)),10),e=(sv(r,e.length+1),e.substr(r)),a-=r,n=!1);a>=o;){if(r=parseInt((Zy(0,o,e.length),e.substr(0,o)),10),e=(sv(o,e.length+1),e.substr(o)),a-=o,n)n=!1;else{if(dT(d,s)<0)throw E(new aa(sI+l+`"`));d=bE(d,u)}d=xE(d,r)}if(dT(d,0)>0||!c&&(d=kb(d),dT(d,0)<0))throw E(new aa(sI+l+`"`));return d}function n_t(e){NN();var t,n,r,i,a,o,s,c;if(e==null)return null;if(i=Nl(e,mA(37)),i<0)return e;for(c=new Gu((Zy(0,i,e.length),e.substr(0,i))),t=V(X9,QH,28,4,15,1),s=0,r=0,o=e.length;ii+2&&hw((sv(i+1,e.length),e.charCodeAt(i+1)),NVt,PVt)&&hw((sv(i+2,e.length),e.charCodeAt(i+2)),NVt,PVt)){if(n=qje((sv(i+1,e.length),e.charCodeAt(i+1)),(sv(i+2,e.length),e.charCodeAt(i+2))),i+=2,r>0?(n&192)==128?t[s++]=n<<24>>24:r=0:n>=128&&((n&224)==192?(t[s++]=n<<24>>24,r=2):(n&240)==224?(t[s++]=n<<24>>24,r=3):(n&248)==240&&(t[s++]=n<<24>>24,r=4)),r>0){if(s==r){switch(s){case 2:jh(c,((t[0]&31)<<6|t[1]&63)&OF);break;case 3:jh(c,((t[0]&15)<<12|(t[1]&63)<<6|t[2]&63)&OF)}s=0,r=0}}else{for(a=0;a=2){if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i==0)n=(Ia(),a=new rn,a),tb((!e.a&&(e.a=new F(W5,e,6,6)),e.a),n);else if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i>1)for(p=new cd((!e.a&&(e.a=new F(W5,e,6,6)),e.a));p.e!=p.i.gc();)Yk(p);cN(t,P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166))}if(f)for(i=new Lu((!e.a&&(e.a=new F(W5,e,6,6)),e.a));i.e!=i.i.gc();)for(n=P(gO(i),166),u=new Lu((!n.a&&(n.a=new ju(z5,n,5)),n.a));u.e!=u.i.gc();)l=P(gO(u),377),c.a=r.Math.max(c.a,l.a),c.b=r.Math.max(c.b,l.b);for(s=new Lu((!e.n&&(e.n=new F(Q5,e,1,7)),e.n));s.e!=s.i.gc();)o=P(gO(s),135),d=P(J(o,h8),8),d&&$l(o,d.a,d.b),f&&(c.a=r.Math.max(c.a,o.i+o.g),c.b=r.Math.max(c.b,o.j+o.f));return c}function i_t(e,t,n,r,i){var a,o,s;if(gKe(e,t),o=t[0],a=mg(n.c,0),s=-1,FZe(n)){if(r>0){if(o+r>e.length)return!1;s=lj((Zy(0,o+r,e.length),e.substr(0,o+r)),t)}else s=lj(e,t)}switch(a){case 71:return s=LA(e,o,U(O(LG,1),X,2,6,[iyt,ayt]),t),i.e=s,!0;case 77:return ect(e,t,i,s,o);case 76:return tct(e,t,i,s,o);case 69:return itt(e,t,o,i);case 99:return att(e,t,o,i);case 97:return s=LA(e,o,U(O(LG,1),X,2,6,[`AM`,`PM`]),t),i.b=s,!0;case 121:return nct(e,t,o,s,n,i);case 100:return s<=0?!1:(i.c=s,!0);case 83:return s<0?!1:c0e(s,o,t[0],i);case 104:s==12&&(s=0);case 75:case 72:return s<0?!1:(i.f=s,i.g=!1,!0);case 107:return s<0?!1:(i.f=s,i.g=!0,!0);case 109:return s<0?!1:(i.j=s,!0);case 115:return s<0?!1:(i.n=s,!0);case 90:if(one[l]&&(_=l),f=new w(e.a.b);f.a1;){if(a=pot(t),f=o.g,h=P(J(t,i3),107),g=D(N(J(t,$4))),(!t.a&&(t.a=new F($5,t,10,11)),t.a).i>1&&D(N(J(t,(xM(),J4))))!=cI&&(o.c+(h.b+h.c))/(o.b+(h.d+h.a))1&&D(N(J(t,(xM(),q4))))!=cI&&(o.c+(h.b+h.c))/(o.b+(h.d+h.a))>g&&OO(a,(xM(),Z4),r.Math.max(D(N(J(t,Y4))),D(N(J(a,Z4)))-D(N(J(t,q4))))),m=new hSe(i,d),l=fvt(m,a,p),u=l.g,u>=f&&u==u){for(s=0;s<(!a.a&&(a.a=new F($5,a,10,11)),a.a).i;s++)ynt(e,P(H((!a.a&&(a.a=new F($5,a,10,11)),a.a),s),27),P(H((!t.a&&(t.a=new F($5,t,10,11)),t.a),s),27));fqe(t,m),PLe(o,l.c),NLe(o,l.b)}--c}OO(t,(xM(),W4),o.b),OO(t,G4,o.c),n.Vg()}function c_t(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y;for(t.Ug(`Interactive node layering`,1),n=new T,p=new w(e.a);p.a=c){jd(y.b>0),y.a.Xb(y.c=--y.b);break}_.a>l&&(i?(nw(i.b,_.b),i.a=r.Math.max(i.a,_.a),Fh(y)):(M(_.b,d),_.c=r.Math.min(_.c,l),_.a=r.Math.max(_.a,c),i=_))}i||(i=new qge,i.c=l,i.a=c,qd(y,i),M(i.b,d))}for(s=e.b,u=0,v=new w(n);v.am&&(o&&(yl(ee,p),yl(ne,G(u.b-1))),oe=n.b,se+=p+t,p=0,d=r.Math.max(d,n.b+n.c+ae)),Gx(c,oe),Kx(c,se),d=r.Math.max(d,oe+ae+n.c),p=r.Math.max(p,f),oe+=ae+t;if(d=r.Math.max(d,i),ie=se+p+n.a,ieGL,C=r.Math.abs(p.b-h.b)>GL,(!n&&ne&&C||n&&(ne||C))&&up(_.a,x)),XS(_.a,i),p=i.b==0?x:(jd(i.b!=0),P(i.c.b.c,8)),TXe(m,f,g),wYe(a)==te&&(Bh(te.i)!=a.a&&(g=new Fa,Fet(g,Bh(te.i),y)),W(_,f$,g)),R9e(m,_,y),d.a.zc(m,d);U_(_,S),K_(_,te)}for(u=d.a.ec().Kc();u.Ob();)l=P(u.Pb(),18),U_(l,null),K_(l,null);t.Vg()}function d_t(e,t){var n,r,i=P(K(e,(rN(),c4)),88),a,o,s,c,l,u=i==(GT(),t8)||i==n8?e8:n8,d,f;for(n=P(ay(hg(new Mp(null,new cv(e.b,16)),new gae),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),c=P(ay(gg(n.Oc(),new Ime(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),c.Gc(P(ay(gg(n.Oc(),new Lme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),16)),c.jd(new Rme(u)),f=new Ja(new zme(i)),r=new Dr,s=c.Kc();s.Ob();)o=P(s.Pb(),240),l=P(o.a,40),ki(Od(o.c))?(f.a.zc(l,(rd(),vG)),new nr(f.a.Zc(l,!1)).a.gc()>0&&Qh(r,l,P(new nr(f.a.Zc(l,!1)).a.Vc(),40)),new nr(f.a.ad(l,!0)).a.gc()>1&&Qh(r,h0e(f,l),l)):(new nr(f.a.Zc(l,!1)).a.gc()>0&&(a=P(new nr(f.a.Zc(l,!1)).a.Vc(),40),A(a)===A(nl(Kp(r.f,l)))&&P(K(l,(tP(),U2)),15).Fc(a)),new nr(f.a.ad(l,!0)).a.gc()>1&&(d=h0e(f,l),A(nl(Kp(r.f,d)))===A(l)&&P(K(d,(tP(),U2)),15).Fc(l)),f.a.Bc(l))}function f_t(e){var t,n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(e.gc()==1)return P(e.Xb(0),235);if(e.gc()<=0)return new Py;for(a=e.Kc();a.Ob();){for(n=P(a.Pb(),235),h=0,d=AP,f=AP,l=xF,u=xF,m=new w(n.e);m.ac&&(b=0,x+=s+v,s=0),vut(g,n,b,x),t=r.Math.max(t,b+_.a),s=r.Math.max(s,_.b),b+=_.a+v;return g}function p_t(e){Bdt();var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(e==null||(a=Wb(e),m=d1e(a),m%4!=0))return null;if(h=m/4|0,h==0)return V(X9,QH,28,0,15,1);for(d=null,t=0,n=0,r=0,i=0,o=0,s=0,c=0,l=0,p=0,f=0,u=0,d=V(X9,QH,28,h*3,15,1);p>4)<<24>>24,d[f++]=((n&15)<<4|r>>2&15)<<24>>24,d[f++]=(r<<6|i)<<24>>24}return!to(o=a[u++])||!to(s=a[u++])?null:(t=A9[o],n=A9[s],c=a[u++],l=a[u++],A9[c]==-1||A9[l]==-1?c==61&&l==61?n&15?null:(g=V(X9,QH,28,p*3+1,15,1),tN(d,0,g,0,p*3),g[f]=(t<<2|n>>4)<<24>>24,g):c!=61&&l==61?(r=A9[c],r&3?null:(g=V(X9,QH,28,p*3+2,15,1),tN(d,0,g,0,p*3),g[f++]=(t<<2|n>>4)<<24>>24,g[f]=((n&15)<<4|r>>2&15)<<24>>24,g)):null:(r=A9[c],i=A9[l],d[f++]=(t<<2|n>>4)<<24>>24,d[f++]=((n&15)<<4|r>>2&15)<<24>>24,d[f++]=(r<<6|i)<<24>>24,d))}function m_t(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for(t.Ug(Lbt,1),m=P(K(e,(mP(),S1)),223),i=new w(e.b);i.a=2){for(h=!0,f=new w(a.j),n=P(z(f),12),p=null;f.a0){if(i=f.gc(),u=C_(r.Math.floor((i+1)/2))-1,a=C_(r.Math.ceil((i+1)/2))-1,t.o==E2)for(d=a;d>=u;d--)t.a[x.p]==x&&(g=P(f.Xb(d),42),h=P(g.a,10),!mo(n,g.b)&&m>e.b.e[h.p]&&(t.a[h.p]=x,t.g[x.p]=t.g[h.p],t.a[x.p]=t.g[x.p],t.f[t.g[x.p].p]=(rd(),!!(ki(t.f[t.g[x.p].p])&x.k==(DA(),qJ))),m=e.b.e[h.p]));else for(d=u;d<=a;d++)t.a[x.p]==x&&(v=P(f.Xb(d),42),_=P(v.a,10),!mo(n,v.b)&&m0&&(a=P(Ep(_.c.a,ee-1),10),s=e.i[a.p],ne=r.Math.ceil(yu(e.n,a,_)),o=S.a.e-_.d.d-(s.a.e+a.o.b+a.d.a)-ne),u=cI,ee<_.c.a.c.length-1&&(l=P(Ep(_.c.a,ee+1),10),d=e.i[l.p],ne=r.Math.ceil(yu(e.n,l,_)),u=d.a.e-l.d.d-(S.a.e+_.o.b+_.d.a)-ne),n&&(uu(),fS(TV),r.Math.abs(o-u)<=TV||o==u||isNaN(o)&&isNaN(u))?!0:(i=eh(b.a),c=-eh(b.b),f=-eh(te.a),y=eh(te.b),g=b.a.e.e-b.a.a-(b.b.e.e-b.b.a)>0&&te.a.e.e-te.a.a-(te.b.e.e-te.b.a)<0,h=b.a.e.e-b.a.a-(b.b.e.e-b.b.a)<0&&te.a.e.e-te.a.a-(te.b.e.e-te.b.a)>0,m=b.a.e.e+b.b.ate.b.e.e+te.a.a,x=0,!g&&!h&&(p?o+f>0?x=f:u-i>0&&(x=i):m&&(o+c>0?x=c:u-y>0&&(x=y))),S.a.e+=x,S.b&&(S.d.e+=x),!1))}function __t(e,t,n){var i=new wg(t.Lf().a,t.Lf().b,t.Mf().a,t.Mf().b),a=new Ul,o,s,c,l,u,d,f,p;if(e.c)for(s=new w(t.Rf());s.al&&(r.a+=Uwe(V(K9,EF,28,-l,15,1))),r.a+=`Is`,Nl(c,mA(32))>=0)for(i=0;i=r.o.b/2}else v=!d;v?(_=P(K(r,(Y(),p$)),15),_?f?a=_:(i=P(K(r,dQ),15),i?a=_.gc()<=i.gc()?_:i:(a=new T,W(r,dQ,a))):(a=new T,W(r,p$,a))):(i=P(K(r,(Y(),dQ)),15),i?d?a=i:(_=P(K(r,p$),15),_?a=i.gc()<=_.gc()?i:_:(a=new T,W(r,p$,a))):(a=new T,W(r,dQ,a))),a.Fc(e),W(e,(Y(),pQ),n),t.d==n?(K_(t,null),n.e.c.length+n.g.c.length==0&&G_(n,null),nQe(n)):(U_(t,null),n.e.c.length+n.g.c.length==0&&G_(n,null)),Fg(t.a)}function C_t(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae,oe,se;for(n.Ug(`MinWidth layering`,1),m=t.b,te=t.a,se=P(K(t,(mP(),Ujt)),17).a,c=P(K(t,Wjt),17).a,e.b=D(N(K(t,c0))),e.d=cI,x=new w(te);x.a0?(u=0,_&&(u+=c),u+=(C-1)*s,b&&(u+=c),ne&&b&&(u=r.Math.max(u,Jot(b,s,y,te))),u=e.a&&(i=kft(e,b),f=r.Math.max(f,i.b),S=r.Math.max(S,i.d),M(c,new Kc(b,i)));for(C=new T,u=0;u0),v.a.Xb(v.c=--v.b),re=new Eh(e.b),qd(v,re),jd(v.b0){for(f=u<100?null:new Pa(u),l=new hC(t),m=l.g,_=V(q9,HF,28,u,15,1),r=0,b=new kx(u),i=0;i=0;)if(p==null?A(p)===A(m[c]):NT(p,m[c])){_.length<=r&&(g=_,_=V(q9,HF,28,2*_.length,15,1),tN(g,0,_,0,r)),_[r++]=i,tb(b,m[c]);break v}if(p=p,A(p)===A(s))break}}if(l=b,m=b.g,u=r,r>_.length&&(g=_,_=V(q9,HF,28,r,15,1),tN(g,0,_,0,r)),r>0){for(y=!0,a=0;a=0;)Dk(e,_[o]);if(r!=u){for(i=u;--i>=r;)Dk(l,i);g=_,_=V(q9,HF,28,r,15,1),tN(g,0,_,0,r)}t=l}}}else for(t=U3e(e,t),i=e.i;--i>=0;)t.Hc(e.g[i])&&(Dk(e,i),y=!0);if(y){if(_!=null){for(n=t.gc(),d=n==1?V_(e,4,t.Kc().Pb(),null,_[0],h):V_(e,6,t,_,_[0],h),f=n<100?null:new Pa(n),i=t.Kc();i.Ob();)p=i.Pb(),f=JOe(e,P(p,76),f);f?(f.nj(d),f.oj()):AC(e.e,d)}else{for(f=uOe(t.gc()),i=t.Kc();i.Ob();)p=i.Pb(),f=JOe(e,P(p,76),f);f&&f.oj()}return!0}return!1}function D_t(e,t){var n=new g4e(t),r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b;for(n.a||Fut(t),l=qct(t),c=new g_,_=new Vst,g=new w(t.a);g.a0||n.o==E2&&a=n}function A_t(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y=t,b,x,S,ee,te,ne,C,re,ie;for(v=new g_,b=new g_,u=Mv(y,cCt),r=new pIe(e,n,v,b),$9e(r.a,r.b,r.c,r.d,u),c=(ee=v.i,ee||(v.i=new zu(v,v.c))),ne=c.Kc();ne.Ob();)for(te=P(ne.Pb(),166),i=P(Dy(v,te),21),h=i.Kc();h.Ob();)if(m=h.Pb(),x=P(Bx(e.d,m),166),x)s=(!te.e&&(te.e=new cf(W5,te,10,9)),te.e),tb(s,x);else throw o=Fv(y,dU),f=_Ct+m+vCt+o,p=f+pU,E(new Vi(p));for(l=(S=b.i,S||(b.i=new zu(b,b.c))),re=l.Kc();re.Ob();)for(C=P(re.Pb(),166),a=P(Dy(b,C),21),_=a.Kc();_.Ob();)if(g=_.Pb(),x=P(Bx(e.d,g),166),x)d=(!C.g&&(C.g=new cf(W5,C,9,10)),C.g),tb(d,x);else throw o=Fv(y,dU),f=_Ct+g+vCt+o,p=f+pU,E(new Vi(p));!n.b&&(n.b=new cf(H5,n,4,7)),n.b.i!=0&&(!n.c&&(n.c=new cf(H5,n,5,8)),n.c.i!=0)&&(!n.b&&(n.b=new cf(H5,n,4,7)),n.b.i<=1&&(!n.c&&(n.c=new cf(H5,n,5,8)),n.c.i<=1))&&(!n.a&&(n.a=new F(W5,n,6,6)),n.a).i==1&&(ie=P(H((!n.a&&(n.a=new F(W5,n,6,6)),n.a),0),166),!GO(ie)&&!KO(ie)&&(TS(ie,P(H((!n.b&&(n.b=new cf(H5,n,4,7)),n.b),0),84)),ES(ie,P(H((!n.c&&(n.c=new cf(H5,n,5,8)),n.c),0),84))))}function j_t(e){var t,n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re;for(b=e.a,x=0,S=b.length;x0?(f=P(Ep(p.c.a,s-1),10),ne=yu(e.b,p,f),_=p.n.b-p.d.d-(f.n.b+f.o.b+f.d.a+ne)):_=p.n.b-p.d.d,u=r.Math.min(_,u),s1&&(s=r.Math.min(s,r.Math.abs(P(SO(c.a,1),8).b-d.b)))));else for(g=new w(t.j);g.aa&&(o=p.a-a,s=AP,i.c.length=0,a=p.a),p.a>=a&&(Mr(i.c,c),c.a.b>1&&(s=r.Math.min(s,r.Math.abs(P(SO(c.a,c.a.b-2),8).b-p.b)))));if(i.c.length!=0&&o>t.o.a/2&&s>t.o.b/2){for(m=new jA,G_(m,t),tj(m,(nP(),Z8)),m.n.a=t.o.a/2,v=new jA,G_(v,t),tj(v,m5),v.n.a=t.o.a/2,v.n.b=t.o.b,l=new w(i);l.a=u.b?U_(c,v):U_(c,m)):(u=P(Tje(c.a),8),_=c.a.b==0?rv(c.c):P(vd(c.a),8),_.b>=u.b?K_(c,v):K_(c,m)),f=P(K(c,(mP(),j1)),75),f&&QE(f,u,!0);t.n.a=a-t.o.a/2}}function N_t(e,t,n){var i,a,o,s,c,l,u,d,f,p;for(c=dO(e.b,0);c.b!=c.d.c;)if(s=P(Lv(c),40),!ff(s.c,LV))for(u=vit(s,e),t==(GT(),t8)||t==n8?hu(u,new Vae):hu(u,new Hae),l=u.c.length,i=0;i=0?GE(s):YT(GE(s)),e.qf(t0,p)),l=new Fa,f=!1,e.pf(X1)?(IEe(l,P(e.of(X1),8)),f=!0):lTe(l,o.a/2,o.b/2),p.g){case 4:W(u,M1,(XE(),h$)),W(u,yQ,(_w(),vZ)),u.o.b=o.b,h<0&&(u.o.a=-h),tj(d,(nP(),X8)),f||(l.a=o.a),l.a-=o.a;break;case 2:W(u,M1,(XE(),_$)),W(u,yQ,(_w(),gZ)),u.o.b=o.b,h<0&&(u.o.a=-h),tj(d,(nP(),g5)),f||(l.a=0);break;case 1:W(u,MQ,(Zb(),oQ)),u.o.a=o.a,h<0&&(u.o.b=-h),tj(d,(nP(),m5)),f||(l.b=o.b),l.b-=o.b;break;case 3:W(u,MQ,(Zb(),iQ)),u.o.a=o.a,h<0&&(u.o.b=-h),tj(d,(nP(),Z8)),f||(l.b=0)}if(IEe(d.n,l),W(u,X1,l),t==L8||t==z8||t==R8){if(m=0,t==L8&&e.pf($1))switch(p.g){case 1:case 2:m=P(e.of($1),17).a;break;case 3:case 4:m=-P(e.of($1),17).a}else switch(p.g){case 4:case 2:m=a.b,t==z8&&(m/=i.b);break;case 1:case 3:m=a.a,t==z8&&(m/=i.a)}W(u,$Q,m)}return W(u,TQ,p),u}function P_t(){La();function e(e){var t=this;this.dispatch=function(t){var n=t.data;switch(n.cmd){case`algorithms`:var r=tD((Vg(),new Wn(new Bn(h7.b))));e.postMessage({id:n.id,data:r});break;case`categories`:var i=tD((Vg(),new Wn(new Bn(h7.c))));e.postMessage({id:n.id,data:i});break;case`options`:var a=tD((Vg(),new Wn(new Bn(h7.d))));e.postMessage({id:n.id,data:a});break;case`register`:Wmt(n.algorithms),e.postMessage({id:n.id});break;case`layout`:Rft(n.graph,n.layoutOptions||{},n.options||{}),e.postMessage({id:n.id,data:n.graph})}},this.saveDispatch=function(n){try{t.dispatch(n)}catch(t){e.postMessage({id:n.data.id,error:t})}}}function r(t){var n=this;this.dispatcher=new e({postMessage:function(e){n.onmessage({data:e})}}),this.postMessage=function(e){setTimeout(function(){n.dispatcher.saveDispatch({data:e})},0)}}if(typeof document===LI&&typeof self!==LI){var i=new e(self);self.onmessage=i.saveDispatch}else typeof t!==LI&&t.exports&&(Object.defineProperty(n,"__esModule",{value:!0}),t.exports={default:r,Worker:r})}function F_t(e,t,n){var r,i,a,o,s,c,l,u=new ZO(n),d,f;for(VC(u,t),W(u,(Y(),WQ),t),u.o.a=t.g,u.o.b=t.f,u.n.a=t.i,u.n.b=t.j,M(n.a,u),Qh(e.a,t,u),((!t.a&&(t.a=new F($5,t,10,11)),t.a).i!=0||ki(Od(J(t,(mP(),k1)))))&&W(u,mQ,(rd(),!0)),l=P(K(n,OQ),21),d=P(K(u,(mP(),Q1)),101),d==(rA(),H8)?W(u,Q1,V8):d!=V8&&l.Fc((uM(),YZ)),f=0,r=P(K(n,_1),88),c=new Lu((!t.c&&(t.c=new F(e7,t,9,9)),t.c));c.e!=c.i.gc();)s=P(gO(c),123),i=I_(t),(A(J(i,s1))!==A((ID(),Z0))||A(J(i,g1))===A((FD(),dZ))||A(J(i,g1))===A((FD(),lZ))||ki(Od(J(i,l1)))||A(J(i,t1))!==A((YD(),RJ))||A(J(i,P1))===A((FM(),G0))||A(J(i,P1))===A((FM(),K0))||A(J(i,F1))===A((Zj(),k0))||A(J(i,F1))===A((Zj(),j0)))&&!ki(Od(J(t,a1)))&&OO(s,UQ,G(f++)),ki(Od(J(s,J1)))||Cgt(e,s,u,l,r,d);for(o=new Lu((!t.n&&(t.n=new F(Q5,t,1,7)),t.n));o.e!=o.i.gc();)a=P(gO(o),135),!ki(Od(J(a,J1)))&&a.a&&M(u.b,lT(a));return ki(Od(K(u,Z$)))&&l.Fc((uM(),WZ)),ki(Od(K(u,O1)))&&(l.Fc((uM(),JZ)),l.Fc(qZ),W(u,Q1,V8)),u}function cP(e,t,n,i,a,o,s){var c,l,u,d,f,p,m,h,g=0,_,v,y,b,x,S,ee,te,ne,C,re=0,ie,ae,oe,se;for(u=new w(e.b);u.ag&&(o&&(yl(ee,m),yl(ne,G(d.b-1)),M(e.d,h),c.c.length=0),oe=n.b,se+=m+t,m=0,f=r.Math.max(f,n.b+n.c+ae)),Mr(c.c,l),q2e(l,oe,se),f=r.Math.max(f,oe+ae+n.c),m=r.Math.max(m,p),oe+=ae+t,h=l;if(nw(e.a,c),M(e.d,P(Ep(c,c.c.length-1),163)),f=r.Math.max(f,i),ie=se+m+n.a,iei.d.d+i.d.a?u.f.d=!0:(u.f.d=!0,u.f.a=!0))),r.b!=r.d.c&&(t=n);u&&(a=P(xh(e.f,o.d.i),60),t.ba.d.d+a.d.a?u.f.d=!0:(u.f.d=!0,u.f.a=!0))}for(s=new pm(Vu(DE(m).a.Kc(),new d));Cj(s);)o=P(by(s),18),o.a.b!=0&&(t=P(vd(o.a),8),o.d.j==(nP(),Z8)&&(_=new mN(t,new k(t.a,i.d.d),i,o),_.f.a=!0,_.a=o.d,Mr(g.c,_)),o.d.j==m5&&(_=new mN(t,new k(t.a,i.d.d+i.d.a),i,o),_.f.d=!0,_.a=o.d,Mr(g.c,_)))}return g}function V_t(e,t,n){var r,i,a,o,s,c=new T,l,u,d=t.length,f;for(o=DZe(n),l=0;l=m&&(v>m&&(p.c.length=0,m=v),Mr(p.c,o));p.c.length!=0&&(f=P(Ep(p,VO(t,p.c.length)),131),re.a.Bc(f),f.s=h++,bat(f,ne,S),p.c.length=0)}for(b=e.c.length+1,s=new w(e);s.aC.s&&(Fh(n),Db(C.i,r),r.c>0&&(r.a=C,M(C.t,r),r.b=ee,M(ee.i,r)))}function W_t(e,t,n,r,i){var a,o,s,c,l,u,d,f,p,m,h=new Hy(t.b),g,_,v,y,b=new Hy(t.b),x,S,ee,te,ne,C,re;for(f=new Hy(t.b),te=new Hy(t.b),g=new Hy(t.b),ee=dO(t,0);ee.b!=ee.d.c;)for(x=P(Lv(ee),12),s=new w(x.g);s.a0,_=x.g.c.length>0,l&&_?Mr(f.c,x):l?Mr(h.c,x):_&&Mr(b.c,x);for(m=new w(h);m.ay.nh()-u.b&&(p=y.nh()-u.b),m>y.oh()-u.d&&(m=y.oh()-u.d),d0){for(x=dO(e.f,0);x.b!=x.d.c;)b=P(Lv(x),10),b.p+=m-e.e;Iet(e),Fg(e.f),yct(e,i,h)}else{for(up(e.f,h),h.p=i,e.e=r.Math.max(e.e,i),o=new pm(Vu(DE(h).a.Kc(),new d));Cj(o);)a=P(by(o),18),!a.c.i.c&&a.c.i.k==(DA(),KJ)&&(up(e.f,a.c.i),a.c.i.p=i-1);e.c=i}}else Iet(e),Fg(e.f),i=0,Cj(new pm(Vu(DE(h).a.Kc(),new d)))?(m=0,m=i4e(m,h),i=m+2,yct(e,i,h)):(up(e.f,h),h.p=0,e.e=r.Math.max(e.e,0),e.b=P(Ep(e.d.b,0),30),e.c=0);for(e.f.b==0||Iet(e),e.d.a.c.length=0,y=new T,u=new w(e.d.b);u.a=48&&t<=57){for(r=t-48;i=48&&t<=57;)if(r=r*10+t-48,r<0)throw E(new Ui(TP((fu(),ewt))))}else throw E(new Ui(TP((fu(),XCt))));if(n=r,t==44){if(i>=e.j)throw E(new Ui(TP((fu(),QCt))));if((t=mg(e.i,i++))>=48&&t<=57){for(n=t-48;i=48&&t<=57;)if(n=n*10+t-48,n<0)throw E(new Ui(TP((fu(),ewt))));if(r>n)throw E(new Ui(TP((fu(),$Ct))))}else n=-1}if(t!=125)throw E(new Ui(TP((fu(),ZCt))));e.bm(i)?(a=(xP(),xP(),++W9,new Zv(9,a)),e.d=i+1):(a=(xP(),xP(),++W9,new Zv(3,a)),e.d=i),a.Om(r),a.Nm(n),hP(e)}}return a}function $_t(e){var t,n=P(K(e,(Y(),OQ)),21),r,i,a;switch(t=Wl(oOt),i=P(K(e,(mP(),D1)),346),i==(_T(),g8)&&OC(t,sOt),ki(Od(K(e,E1)))?vp(t,(vA(),vJ),(yP(),tX)):vp(t,(vA(),bJ),(yP(),tX)),K(e,(Uy(),G3))!=null&&OC(t,cOt),(ki(Od(K(e,zjt)))||ki(Od(K(e,Fjt))))&&tm(t,(vA(),SJ),(yP(),hY)),P(K(e,_1),88).g){case 2:case 3:case 4:tm(vp(t,(vA(),vJ),(yP(),_Y)),SJ,gY)}switch(n.Hc((uM(),WZ))&&tm(vp(vp(t,(vA(),vJ),(yP(),mY)),xJ,fY),SJ,pY),A(K(e,P1))!==A((FM(),Y0))&&vp(t,(vA(),bJ),(yP(),qY)),n.Hc(ZZ)&&(vp(t,(vA(),vJ),(yP(),$Y)),vp(t,yJ,ZY),vp(t,bJ,QY)),A(K(e,e1))!==A((TA(),BZ))&&A(K(e,S1))!==A((wE(),u8))&&tm(t,(vA(),SJ),(yP(),AY)),ki(Od(K(e,Ljt)))&&vp(t,(vA(),bJ),(yP(),kY)),ki(Od(K(e,m1)))&&vp(t,(vA(),bJ),(yP(),sX)),Kat(e)&&(r=A(K(e,D1))===A(g8)?P(K(e,d1),299):P(K(e,f1),299),a=r==(qC(),tQ)?(yP(),XY):(yP(),uX),vp(t,(vA(),xJ),a)),P(K(e,wMt),388).g){case 1:vp(t,(vA(),xJ),(yP(),cX));break;case 2:tm(vp(vp(t,(vA(),bJ),(yP(),cY)),xJ,lY),SJ,uY)}return A(K(e,s1))!==A((ID(),Z0))&&vp(t,(vA(),bJ),(yP(),lX)),t}function evt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y;if(km(e.a,t)){if(mo(P(xh(e.a,t),49),n))return 1}else Qh(e.a,t,new Jr);if(km(e.a,n)){if(mo(P(xh(e.a,n),49),t))return-1}else Qh(e.a,n,new Jr);if(km(e.e,t)){if(mo(P(xh(e.e,t),49),n))return-1}else Qh(e.e,t,new Jr);if(km(e.e,n)){if(mo(P(xh(e.a,n),49),t))return 1}else Qh(e.e,n,new Jr);if(e.c==(ID(),Q0)||!yd(t,(Y(),UQ))||!yd(n,(Y(),UQ))){for(d=null,l=new w(t.j);l.ao?jM(e,t,n):jM(e,n,t),io)}return r=P(K(t,(Y(),UQ)),17).a,a=P(K(n,UQ),17).a,r>a?jM(e,t,n):jM(e,n,t),ra)}function uP(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(n==null)return null;if(e.a!=t.jk())throw E(new Fi(YH+t.xe()+XH));if(j(t,469)){if(g=fct(P(t,685),n),!g)throw E(new Fi(ZH+n+`' is not a valid enumerator of '`+t.xe()+`'`));return g}switch(AT((UA(),l9),t).Nl()){case 2:n=EN(n,!1);break;case 3:n=EN(n,!0)}if(r=AT(l9,t).Jl(),r)return r.jk().wi().ti(r,n);if(f=AT(l9,t).Ll(),f){for(g=new T,l=Bw(n),u=0,d=l.length;u1)for(h=new cd((!e.a&&(e.a=new F(W5,e,6,6)),e.a));h.e!=h.i.gc();)Yk(h);for(s=P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166),_=oe,oe>S+x?_=S+x:oeee+g?v=ee+g:seS-x&&_ee-g&&voe+ae?ne=oe+ae:Sse+te?C=se+te:eeoe-ae&&nese-te&&Cn&&(p=n-1),m=fe+Lj(t,24)*kI*f-f/2,m<0?m=1:m>i&&(m=i-1),a=(Ia(),l=new tn,l),Xx(a,p),Vx(a,m),tb((!s.a&&(s.a=new ju(z5,s,5)),s.a),a)}function avt(e){Wo(e,new oA(ya(ha(va(_a(new Zt,cH),`ELK Rectangle Packing`),`Algorithm for packing of unconnected boxes, i.e. graphs without edges. The given order of the boxes is always preserved and the main reading direction of the boxes is left to right. The algorithm is divided into two phases. One phase approximates the width in which the rectangles can be placed. The next phase places the rectangles in rows using the previously calculated width as bounding width and bundles rectangles with a similar height in blocks. A compaction step reduces the size of the drawing. Finally, the rectangles are expanded to fill their bounding box and eliminate empty unused spaces.`),new xoe))),B(e,cH,FL,1.3),B(e,cH,aR,(rd(),!1)),B(e,cH,IL,dLt),B(e,cH,ZL,15),B(e,cH,rV,hO(eLt)),B(e,cH,sR,hO(aLt)),B(e,cH,gR,hO(sLt)),B(e,cH,oR,hO(cLt)),B(e,cH,cR,hO(iLt)),B(e,cH,iR,hO(n3)),B(e,cH,lR,hO(fLt)),B(e,cH,Vxt,hO(gLt)),B(e,cH,Hxt,hO(hLt)),B(e,cH,Bxt,hO(o3)),B(e,cH,zxt,hO(_Lt)),B(e,cH,Uxt,hO(uLt)),B(e,cH,Wxt,hO(r3)),B(e,cH,Gxt,hO(lLt)),B(e,cH,Kxt,hO(mLt)),B(e,cH,tR,hO(nLt)),B(e,cH,hV,hO(rLt)),B(e,cH,Lxt,hO(e3)),B(e,cH,Ixt,hO(tLt)),B(e,cH,Rxt,hO(t3)),B(e,cH,Fxt,hO(pLt))}function pP(e,t){wN();var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te=e.e,ne,C,re,ie,ae;if(m=e.d,i=e.a,te==0)switch(t){case 0:return`0`;case 1:return vI;case 2:return`0.00`;case 3:return`0.000`;case 4:return`0.0000`;case 5:return`0.00000`;case 6:return`0.000000`;default:return S=new ta,t<0?S.a+=`0E+`:S.a+=`0E`,S.a+=-t,S.a}if(y=m*10+1+7,b=V(K9,EF,28,y+1,15,1),n=y,m==1){if(s=i[0],s<0){ae=uv(s,_I);do h=ae,ae=Wk(ae,10),b[--n]=48+nm(xE(h,bE(ae,10)))&OF;while(dT(ae,0)!=0)}else{ae=s;do h=ae,ae=ae/10|0,b[--n]=48+(h-ae*10)&OF;while(ae!=0)}}else{C=V(q9,HF,28,m,15,1),ie=m,tN(i,0,C,0,ie);I:for(;;){for(ee=0,l=ie-1;l>=0;l--)re=yE(cm(ee,32),uv(C[l],_I)),_=Q5e(re),C[l]=nm(_),ee=nm(lm(_,32));v=nm(ee),g=n;do b[--n]=48+v%10&OF;while((v=v/10|0)!=0&&n!=0);for(r=9-g+n,c=0;c0;c++)b[--n]=48;for(d=ie-1;C[d]==0;d--)if(d==0)break I;ie=d+1}for(;b[n]==48;)++n}if(p=te<0,o=y-n-t-1,t==0)return p&&(b[--n]=45),ND(b,n,y-n);if(t>0&&o>=-6){if(o>=0){for(u=n+o,f=y-1;f>=u;f--)b[f+1]=b[f];return b[++u]=46,p&&(b[--n]=45),ND(b,n,y-n+1)}for(d=2;d<-o+1;d++)b[--n]=48;return b[--n]=46,b[--n]=48,p&&(b[--n]=45),ND(b,n,y-n)}return ne=n+1,a=y,x=new na,p&&(x.a+=`-`),a-ne>=1?(jh(x,b[n]),x.a+=`.`,x.a+=ND(b,n+1,y-n-1)):x.a+=ND(b,n,y-n),x.a+=`E`,o>0&&(x.a+=`+`),x.a+=``+o,x.a}function ovt(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;switch(e.c=t,e.g=new Dr,n=(Ko(),new Ei(e.c)),i=new ar(n),KE(i),b=kd(J(e.c,(yA(),XLt))),l=P(J(e.c,T3),324),S=P(J(e.c,E3),437),s=P(J(e.c,GLt),490),x=P(J(e.c,w3),438),e.j=D(N(J(e.c,ZLt))),c=e.a,l.g){case 0:c=e.a;break;case 1:c=e.b;break;case 2:c=e.i;break;case 3:c=e.e;break;case 4:c=e.f;break;default:throw E(new Fi(fH+(l.f==null?``+l.g:l.f)))}if(e.d=new qLe(c,S,s),W(e.d,(wC(),xq),Od(J(e.c,qLt))),e.d.c=ki(Od(J(e.c,KLt))),Gg(e.c).i==0)return e.d;for(f=new Lu(Gg(e.c));f.e!=f.i.gc();){for(d=P(gO(f),27),m=d.g/2,p=d.f/2,ee=new k(d.i+m,d.j+p);km(e.g,ee);)Sd(ee,(r.Math.random()-.5)*GL,(r.Math.random()-.5)*GL);g=P(J(d,(vP(),S6)),140),_=new bRe(ee,new wg(ee.a-m-e.j/2-g.b,ee.b-p-e.j/2-g.d,d.g+e.j+(g.b+g.c),d.f+e.j+(g.d+g.a))),M(e.d.i,_),Qh(e.g,ee,new Kc(_,d))}switch(x.g){case 0:if(b==null)e.d.d=P(Ep(e.d.i,0),68);else for(y=new w(e.d.i);y.a0?ie+1:1);for(o=new w(S.g);o.a0?ie+1:1)}e.c[l]==0?up(e.e,h):e.a[l]==0&&up(e.f,h),++l}for(m=-1,p=1,d=new T,e.d=P(K(t,(Y(),t$)),234);le>0;){for(;e.e.b!=0;)oe=P(Yf(e.e),10),e.b[oe.p]=m--,yut(e,oe),--le;for(;e.f.b!=0;)se=P(Yf(e.f),10),e.b[se.p]=p++,yut(e,se),--le;if(le>0){for(f=xF,v=new w(y);v.a=f&&(b>f&&(d.c.length=0,f=b),Mr(d.c,h)));u=e.sg(d),e.b[u.p]=p++,yut(e,u),--le}}for(ae=y.c.length+1,l=0;le.b[ce]&&(lN(r,!0),W(t,vQ,(rd(),!0)));e.a=null,e.c=null,e.b=null,Fg(e.f),Fg(e.e),n.Vg()}function lvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166),ee;for(d=new ai,x=new Dr,ee=vdt(S),XA(x.f,S,ee),p=new Dr,i=new vo,h=jm(oS(U(O(KW,1),FP,20,0,[(!t.d&&(t.d=new cf(U5,t,8,5)),t.d),(!t.e&&(t.e=new cf(U5,t,7,4)),t.e)])));Cj(h);){if(m=P(by(h),74),(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i!=1)throw E(new Fi(BSt+(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i));m!=e&&(_=P(H((!m.a&&(m.a=new F(W5,m,6,6)),m.a),0),166),iy(i,_,i.c.b,i.c),g=P(nl(Kp(x.f,_)),13),g||(g=vdt(_),XA(x.f,_,g)),f=n?ef(new Vl(P(Ep(ee,ee.c.length-1),8)),P(Ep(g,g.c.length-1),8)):ef(new Vl((ov(0,ee.c.length),P(ee.c[0],8))),(ov(0,g.c.length),P(g.c[0],8))),XA(p.f,_,f))}if(i.b!=0)for(v=P(Ep(ee,n?ee.c.length-1:0),8),u=1;u1&&iy(d,v,d.c.b,d.c),wx(a)));v=y}return d}function uvt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C;for(n.Ug(fxt,1),C=P(ay(hg(new Mp(null,new cv(t,16)),new Xae),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),u=P(ay(hg(new Mp(null,new cv(t,16)),new Vme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),m=P(ay(hg(new Mp(null,new cv(t,16)),new Bme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),h=V(L2,VV,40,t.gc(),0,1),o=0;o=0&&ne=0&&!h[p]){h[p]=i,u.gd(s),--s;break}if(p=ne-f,p=0&&!h[p]){h[p]=i,u.gd(s),--s;break}}for(m.jd(new Zae),c=h.length-1;c>=0;c--)!h[c]&&!m.dc()&&(h[c]=P(m.Xb(0),40),m.gd(0));for(l=0;l=0;c--)up(n,(ov(c,o.c.length),P(o.c[c],8)));return n}function fvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b=D(N(J(t,(xM(),Z4)))),x;for(m=D(N(J(t,Y4))),p=D(N(J(t,K4))),BS((!t.a&&(t.a=new F($5,t,10,11)),t.a)),v=Mpt((!t.a&&(t.a=new F($5,t,10,11)),t.a),b,e.b),_=0;_f&&Fk((ov(f,t.c.length),P(t.c[f],186)),u),u=null;t.c.length>f&&(ov(f,t.c.length),P(t.c[f],186)).a.c.length==0;)Db(t,(ov(f,t.c.length),t.c[f]));if(!u){--o;continue}if(!ki(Od(P(Ep(u.b,0),27).of((gM(),t3))))&&$ut(t,m,a,u,g,n,f,r)){h=!0;continue}if(g){if(p=m.b,d=u.f,!ki(Od(P(Ep(u.b,0),27).of(t3)))&&zmt(t,m,a,u,n,f,r,i)){if(h=!0,p=e.j){e.a=-1,e.c=1;return}if(t=mg(e.i,e.d++),e.a=t,e.b==1){switch(t){case 92:if(r=10,e.d>=e.j)throw E(new Ui(TP((fu(),TU))));e.a=mg(e.i,e.d++);break;case 45:(e.e&512)==512&&e.d=e.j||mg(e.i,e.d)!=63)break;if(++e.d>=e.j)throw E(new Ui(TP((fu(),EU))));switch(t=mg(e.i,e.d++),t){case 58:r=13;break;case 61:r=14;break;case 33:r=15;break;case 91:r=19;break;case 62:r=18;break;case 60:if(e.d>=e.j)throw E(new Ui(TP((fu(),EU))));if(t=mg(e.i,e.d++),t==61)r=16;else if(t==33)r=17;else throw E(new Ui(TP((fu(),DCt))));break;case 35:for(;e.d=e.j)throw E(new Ui(TP((fu(),TU))));e.a=mg(e.i,e.d++);break;default:r=0}e.c=r}function gvt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(n.Ug(`Process compaction`,1),ki(Od(K(t,(rN(),eFt))))){for(i=P(K(t,c4),88),p=D(N(K(t,f4))),lpt(e,t,i),d_t(t,p/2/2),m=t.b,zS(m,new Nme(i)),l=dO(m,0);l.b!=l.d.c;)if(c=P(Lv(l),40),!ki(Od(K(c,(tP(),a4))))){if(r=Yct(c,i),h=mft(c,t),d=0,f=0,r)switch(g=r.e,i.g){case 2:d=g.a-p-c.f.a,h.e.a-p-c.f.ad&&(d=h.e.a+h.f.a+p),f=d+c.f.a;break;case 4:d=g.b-p-c.f.b,h.e.b-p-c.f.bd&&(d=h.e.b+h.f.b+p),f=d+c.f.b}else if(h)switch(i.g){case 2:d=h.e.a-p-c.f.a,f=d+c.f.a;break;case 1:d=h.e.a+h.f.a+p,f=d+c.f.a;break;case 4:d=h.e.b-p-c.f.b,f=d+c.f.b;break;case 3:d=h.e.b+h.f.b+p,f=d+c.f.b}A(K(t,l4))===A((Pw(),z2))?(a=d,o=f,s=Dw(hg(new Mp(null,new cv(e.a,16)),new tSe(a,o))),s.a==null?(s=i==(GT(),t8)||i==i8?Dw(hg(Tqe(new Mp(null,new cv(e.a,16))),new Pme(a))):Dw(hg(Tqe(new Mp(null,new cv(e.a,16))),new Fme(a))),s.a!=null&&(i==t8||i==n8?c.e.a=D(N((jd(s.a!=null),P(s.a,42)).a)):c.e.b=D(N((jd(s.a!=null),P(s.a,42)).a)))):i==(GT(),t8)||i==n8?c.e.a=d:c.e.b=d,s.a!=null&&(u=Ab(e.a,(jd(s.a!=null),s.a),0),u>0&&u!=P(K(c,p4),17).a&&(W(c,LPt,(rd(),!0)),W(c,p4,G(u))))):i==(GT(),t8)||i==n8?c.e.a=d:c.e.b=d}n.Vg()}}function _vt(e){var t,n,r,i,a,o,s,c,l;for(e.b=1,hP(e),t=null,e.c==0&&e.a==94?(hP(e),t=(xP(),xP(),++W9,new pv(4)),oM(t,0,NW),s=(++W9,new pv(4))):s=(xP(),xP(),++W9,new pv(4)),i=!0;(l=e.c)!=1;){if(l==0&&e.a==93&&!i){t&&(KN(t,s),s=t);break}if(n=e.a,r=!1,l==10)switch(n){case 100:case 68:case 119:case 87:case 115:case 83:DN(s,KM(n)),r=!0;break;case 105:case 73:case 99:case 67:n=(DN(s,KM(n)),-1),n<0&&(r=!0);break;case 112:case 80:if(c=Ont(e,n),!c)throw E(new Ui(TP((fu(),OU))));DN(s,c),r=!0;break;default:n=Tct(e)}else if(l==24&&!i){if(t&&(KN(t,s),s=t),a=_vt(e),KN(s,a),e.c!=0||e.a!=93)throw E(new Ui(TP((fu(),BCt))));break}if(hP(e),!r){if(l==0){if(n==91)throw E(new Ui(TP((fu(),VCt))));if(n==93)throw E(new Ui(TP((fu(),HCt))));if(n==45&&!i&&e.a!=93)throw E(new Ui(TP((fu(),AU))))}if(e.c!=0||e.a!=45||n==45&&i)oM(s,n,n);else{if(hP(e),(l=e.c)==1)throw E(new Ui(TP((fu(),kU))));if(l==0&&e.a==93)oM(s,n,n),oM(s,45,45);else if(l==0&&e.a==93||l==24)throw E(new Ui(TP((fu(),AU))));else{if(o=e.a,l==0){if(o==91)throw E(new Ui(TP((fu(),VCt))));if(o==93)throw E(new Ui(TP((fu(),HCt))));if(o==45)throw E(new Ui(TP((fu(),AU))))}else l==10&&(o=Tct(e));if(hP(e),n>o)throw E(new Ui(TP((fu(),GCt))));oM(s,n,o)}}}i=!1}if(e.c==1)throw E(new Ui(TP((fu(),kU))));return kj(s),FN(s),e.b=0,hP(e),s}function vvt(e,t,n){var r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x,S;if(n.Ug(`Coffman-Graham Layering`,1),t.a.c.length==0){n.Vg();return}for(S=P(K(t,(mP(),Vjt)),17).a,c=0,o=0,p=new w(t.a);p.a=S||!I0e(v,r))&&(r=BFe(t,u)),W_(v,r),a=new pm(Vu(DE(v).a.Kc(),new d));Cj(a);)i=P(by(a),18),!e.a[i.p]&&(g=i.c.i,--e.e[g.p],e.e[g.p]==0&&ep(gA(m,g),bI));for(l=u.c.length-1;l>=0;--l)M(t.b,(ov(l,u.c.length),P(u.c[l],30)));t.a.c.length=0,n.Vg()}function yvt(e,t){var n,r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x=!1;do for(x=!1,a=t?new Pn(e.a.b).a.gc()-2:1;t?a>=0:aP(K(_,UQ),17).a)&&(b=!1);if(b){for(c=t?a+1:a-1,s=SVe(e.a,G(c)),o=!1,y=!0,r=!1,u=dO(s,0);u.b!=u.d.c;)l=P(Lv(u),10),yd(l,UQ)?l.p!=f.p&&(o|=t?P(K(l,UQ),17).aP(K(f,UQ),17).a,y=!1):!o&&y&&l.k==(DA(),KJ)&&(r=!0,p=t?P(by(new pm(Vu(DE(l).a.Kc(),new d))),18).c.i:P(by(new pm(Vu(OE(l).a.Kc(),new d))),18).d.i,p==f&&(n=t?P(by(new pm(Vu(OE(l).a.Kc(),new d))),18).d.i:P(by(new pm(Vu(DE(l).a.Kc(),new d))),18).c.i,(t?P(xd(e.a,n),17).a-P(xd(e.a,p),17).a:P(xd(e.a,p),17).a-P(xd(e.a,n),17).a)<=2&&(y=!1)));if(r&&y&&(n=t?P(by(new pm(Vu(OE(f).a.Kc(),new d))),18).d.i:P(by(new pm(Vu(DE(f).a.Kc(),new d))),18).c.i,(t?P(xd(e.a,n),17).a-P(xd(e.a,f),17).a:P(xd(e.a,f),17).a-P(xd(e.a,n),17).a)<=2&&n.k==(DA(),JJ)&&(y=!1)),o||y){for(g=Wat(e,f,t);g.a.gc()!=0;)h=P(g.a.ec().Kc().Pb(),10),g.a.Bc(h),XS(g,Wat(e,h,t));--m,x=!0}}}while(x)}function bvt(e){Nj(e.c,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#decimal`])),Nj(e.d,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#integer`])),Nj(e.e,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#boolean`])),Nj(e.f,XU,U(O(LG,1),X,2,6,[sW,`EBoolean`,hU,`EBoolean:Object`])),Nj(e.i,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#byte`])),Nj(e.g,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#hexBinary`])),Nj(e.j,XU,U(O(LG,1),X,2,6,[sW,`EByte`,hU,`EByte:Object`])),Nj(e.n,XU,U(O(LG,1),X,2,6,[sW,`EChar`,hU,`EChar:Object`])),Nj(e.t,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#double`])),Nj(e.u,XU,U(O(LG,1),X,2,6,[sW,`EDouble`,hU,`EDouble:Object`])),Nj(e.F,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#float`])),Nj(e.G,XU,U(O(LG,1),X,2,6,[sW,`EFloat`,hU,`EFloat:Object`])),Nj(e.I,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#int`])),Nj(e.J,XU,U(O(LG,1),X,2,6,[sW,`EInt`,hU,`EInt:Object`])),Nj(e.N,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#long`])),Nj(e.O,XU,U(O(LG,1),X,2,6,[sW,`ELong`,hU,`ELong:Object`])),Nj(e.Z,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#short`])),Nj(e.$,XU,U(O(LG,1),X,2,6,[sW,`EShort`,hU,`EShort:Object`])),Nj(e._,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#string`]))}function xvt(e,t,n,r,i,a,o){var s,c,l,u,d,f=P(r.a,17).a,p=P(r.b,17).a,m;return d=e.b,m=e.c,s=0,u=0,t==(GT(),t8)||t==n8?(u=uc(U$e(_g(gg(new Mp(null,new cv(n.b,16)),new $ae),new Pae))),d.e.b+d.f.b/2>u?(l=++p,s=D(N(Ju(_m(gg(new Mp(null,new cv(n.b,16)),new pSe(i,l)),new Fae))))):(c=++f,s=D(N(Ju(vm(gg(new Mp(null,new cv(n.b,16)),new mSe(i,c)),new Iae)))))):(u=uc(U$e(_g(gg(new Mp(null,new cv(n.b,16)),new Bae),new Nae))),d.e.a+d.f.a/2>u?(l=++p,s=D(N(Ju(_m(gg(new Mp(null,new cv(n.b,16)),new dSe(i,l)),new Lae))))):(c=++f,s=D(N(Ju(vm(gg(new Mp(null,new cv(n.b,16)),new fSe(i,c)),new Rae)))))),t==t8?(yl(e.a,new k(D(N(K(d,(tP(),$2))))-i,s)),yl(e.a,new k(m.e.a+m.f.a+i+a,s)),yl(e.a,new k(m.e.a+m.f.a+i+a,m.e.b+m.f.b/2)),yl(e.a,new k(m.e.a+m.f.a,m.e.b+m.f.b/2))):t==n8?(yl(e.a,new k(D(N(K(d,(tP(),Q2))))+i,d.e.b+d.f.b/2)),yl(e.a,new k(d.e.a+d.f.a+i,s)),yl(e.a,new k(m.e.a-i-a,s)),yl(e.a,new k(m.e.a-i-a,m.e.b+m.f.b/2)),yl(e.a,new k(m.e.a,m.e.b+m.f.b/2))):t==i8?(yl(e.a,new k(s,D(N(K(d,(tP(),$2))))-i)),yl(e.a,new k(s,m.e.b+m.f.b+i+a)),yl(e.a,new k(m.e.a+m.f.a/2,m.e.b+m.f.b+i+a)),yl(e.a,new k(m.e.a+m.f.a/2,m.e.b+m.f.b+i))):(e.a.b==0||(P(vd(e.a),8).b=D(N(K(d,(tP(),Q2))))+i*P(o.b,17).a),yl(e.a,new k(s,D(N(K(d,(tP(),Q2))))+i*P(o.b,17).a)),yl(e.a,new k(s,m.e.b-i*P(o.a,17).a-a))),new Kc(G(f),G(p))}function Svt(e){var t,n,r,i,a,o=!0,s,c,l,u,d=null,f,p;if(r=null,i=null,t=!1,p=LVt,l=null,a=null,s=0,c=nO(e,s,FVt,IVt),c=0&&ff(e.substr(s,2),`//`)?(s+=2,c=nO(e,s,y7,b7),r=(Zy(s,c,e.length),e.substr(s,c-s)),s=c):d!=null&&(s==e.length||(sv(s,e.length),e.charCodeAt(s)!=47))&&(o=!1,c=ITe(e,mA(35),s),c==-1&&(c=e.length),r=(Zy(s,c,e.length),e.substr(s,c-s)),s=c);if(!n&&s0&&mg(u,u.length-1)==58&&(i=u,s=c)),sDj(a))&&(d=a);for(!d&&(d=(ov(0,g.c.length),P(g.c[0],185))),h=new w(t.b);h.af&&(ie=0,ae+=d+te,d=0),but(S,s,ie,ae),t=r.Math.max(t,ie+ee.a),d=r.Math.max(d,ee.b),ie+=ee.a+te;for(x=new Dr,n=new Dr,C=new w(e);C.a=-1900),n>=4?gl(e,U(O(LG,1),X,2,6,[iyt,ayt])[s]):gl(e,U(O(LG,1),X,2,6,[`BC`,`AD`])[s]);break;case 121:P2e(e,n,r);break;case 77:_ut(e,n,r);break;case 107:c=i.q.getHours(),c==0?Ub(e,24,n):Ub(e,c,n);break;case 83:Gat(e,n,i);break;case 69:u=r.q.getDay(),n==5?gl(e,U(O(LG,1),X,2,6,[`S`,`M`,`T`,`W`,`T`,`F`,`S`])[u]):n==4?gl(e,U(O(LG,1),X,2,6,[UF,WF,GF,KF,qF,JF,YF])[u]):gl(e,U(O(LG,1),X,2,6,[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`])[u]);break;case 97:i.q.getHours()>=12&&i.q.getHours()<24?gl(e,U(O(LG,1),X,2,6,[`AM`,`PM`])[1]):gl(e,U(O(LG,1),X,2,6,[`AM`,`PM`])[0]);break;case 104:d=i.q.getHours()%12,d==0?Ub(e,12,n):Ub(e,d,n);break;case 75:f=i.q.getHours()%12,Ub(e,f,n);break;case 72:p=i.q.getHours(),Ub(e,p,n);break;case 99:m=r.q.getDay(),n==5?gl(e,U(O(LG,1),X,2,6,[`S`,`M`,`T`,`W`,`T`,`F`,`S`])[m]):n==4?gl(e,U(O(LG,1),X,2,6,[UF,WF,GF,KF,qF,JF,YF])[m]):n==3?gl(e,U(O(LG,1),X,2,6,[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`])[m]):Ub(e,m,1);break;case 76:h=r.q.getMonth(),n==5?gl(e,U(O(LG,1),X,2,6,[`J`,`F`,`M`,`A`,`M`,`J`,`J`,`A`,`S`,`O`,`N`,`D`])[h]):n==4?gl(e,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF])[h]):n==3?gl(e,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`])[h]):Ub(e,h+1,n);break;case 81:g=r.q.getMonth()/3|0,n<4?gl(e,U(O(LG,1),X,2,6,[`Q1`,`Q2`,`Q3`,`Q4`])[g]):gl(e,U(O(LG,1),X,2,6,[`1st quarter`,`2nd quarter`,`3rd quarter`,`4th quarter`])[g]);break;case 100:_=r.q.getDate(),Ub(e,_,n);break;case 109:l=i.q.getMinutes(),Ub(e,l,n);break;case 115:o=i.q.getSeconds(),Ub(e,o,n);break;case 122:n<4?gl(e,a.c[0]):gl(e,a.c[1]);break;case 118:gl(e,a.b);break;case 90:n<3?gl(e,Ytt(a)):n==3?gl(e,cnt(a)):gl(e,lnt(a.a));break;default:return!1}return!0}function _P(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae;if(Nlt(t),c=P(H((!t.b&&(t.b=new cf(H5,t,4,7)),t.b),0),84),u=P(H((!t.c&&(t.c=new cf(H5,t,5,8)),t.c),0),84),s=cA(c),l=cA(u),o=(!t.a&&(t.a=new F(W5,t,6,6)),t.a).i==0?null:P(H((!t.a&&(t.a=new F(W5,t,6,6)),t.a),0),166),ee=P(xh(e.a,s),10),re=P(xh(e.a,l),10),te=null,ie=null,j(c,193)&&(S=P(xh(e.a,c),305),j(S,12)?te=P(S,12):j(S,10)&&(ee=P(S,10),te=P(Ep(ee.j,0),12))),j(u,193)&&(C=P(xh(e.a,u),305),j(C,12)?ie=P(C,12):j(C,10)&&(re=P(C,10),ie=P(Ep(re.j,0),12))),!ee||!re)throw E(new Bi(`The source or the target of edge `+t+` could not be found. This usually happens when an edge connects a node laid out by ELK Layered to a node in another level of hierarchy laid out by either another instance of ELK Layered or another layout algorithm alltogether. The former can be solved by setting the hierarchyHandling option to INCLUDE_CHILDREN.`));for(h=new i_,VC(h,t),W(h,(Y(),WQ),t),W(h,(mP(),j1),null),p=P(K(r,OQ),21),ee==re&&p.Fc((uM(),QZ)),te||=(x=(uS(),r2),ne=null,o&&Kl(P(K(ee,Q1),101))&&(ne=new k(o.j,o.k),nHe(ne,T_(t)),QHe(ne,n),Ex(l,s)&&(x=n2,$d(ne,ee.n))),upt(ee,ne,x,r)),ie||=(x=(uS(),n2),ae=null,o&&Kl(P(K(re,Q1),101))&&(ae=new k(o.b,o.c),nHe(ae,T_(t)),QHe(ae,n)),upt(re,ae,x,Bh(re))),U_(h,te),K_(h,ie),(te.e.c.length>1||te.g.c.length>1||ie.e.c.length>1||ie.g.c.length>1)&&p.Fc((uM(),qZ)),f=new Lu((!t.n&&(t.n=new F(Q5,t,1,7)),t.n));f.e!=f.i.gc();)if(d=P(gO(f),135),!ki(Od(J(d,J1)))&&d.a)switch(g=lT(d),M(h.b,g),P(K(g,b1),278).g){case 1:case 2:p.Fc((uM(),GZ));break;case 0:p.Fc((uM(),UZ)),W(g,b1,(Lx(),o8))}if(a=P(K(r,h1),322),_=P(K(r,U1),323),i=a==(bS(),$X)||_==(CO(),H0),o&&(!o.a&&(o.a=new ju(z5,o,5)),o.a).i!=0&&i){for(v=FA(o),m=new ai,b=dO(v,0);b.b!=b.d.c;)y=P(Lv(b),8),up(m,new Vl(y));W(h,GQ,m)}return h}function Ovt(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne=0,C=0,re,ie,ae,oe;for(ee=new Dr,x=P(Ju(_m(gg(new Mp(null,new cv(e.b,16)),new zae),new qae)),17).a+1,te=V(q9,HF,28,x,15,1),g=V(q9,HF,28,x,15,1),h=0;h1)for(s=ie+1;sl.b.e.b*(1-_)+l.c.e.b*_));m++);if(S.gc()>0&&(ae=l.a.b==0?xu(l.b.e):P(vd(l.a),8),y=$d(xu(P(S.Xb(S.gc()-1),40).e),P(S.Xb(S.gc()-1),40).f),f=$d(xu(P(S.Xb(0),40).e),P(S.Xb(0),40).f),m>=S.gc()-1&&ae.b>y.b&&l.c.e.b>y.b||m<=0&&ae.bl.b.e.a*(1-_)+l.c.e.a*_));m++);if(S.gc()>0&&(ae=l.a.b==0?xu(l.b.e):P(vd(l.a),8),y=$d(xu(P(S.Xb(S.gc()-1),40).e),P(S.Xb(S.gc()-1),40).f),f=$d(xu(P(S.Xb(0),40).e),P(S.Xb(0),40).f),m>=S.gc()-1&&ae.a>y.a&&l.c.e.a>y.a||m<=0&&ae.a=D(N(K(e,(tP(),BPt))))&&++C):(p.f&&p.d.e.a<=D(N(K(e,(tP(),K2))))&&++ne,p.g&&p.c.e.a+p.c.f.a>=D(N(K(e,(tP(),zPt))))&&++C)}else b==0?mnt(l):b<0&&(++te[ie],++g[oe],re=xvt(l,t,e,new Kc(G(ne),G(C)),n,r,new Kc(G(g[oe]),G(te[ie]))),ne=P(re.a,17).a,C=P(re.b,17).a)}function kvt(e,t,n){var r=t,i,a,o,s,c=n,l,u,d,f,p,m,h,g,_,v;if(e.b&&r.j==(nP(),g5)&&c.j==(nP(),g5)&&(v=r,r=c,c=v),km(e.a,r)){if(mo(P(xh(e.a,r),49),c))return 1}else Qh(e.a,r,new Jr);if(km(e.a,c)){if(mo(P(xh(e.a,c),49),r))return-1}else Qh(e.a,c,new Jr);if(km(e.d,r)){if(mo(P(xh(e.d,r),49),c))return-1}else Qh(e.d,r,new Jr);if(km(e.d,c)){if(mo(P(xh(e.a,c),49),r))return 1}else Qh(e.d,c,new Jr);if(r.j!=c.j)return _=zCe(r.j,c.j),_==-1?NM(e,c,r):NM(e,r,c),_;if(r.e.c.length!=0&&c.e.c.length!=0){if(e.b&&(_=RQe(r,c),_!=0))return _==-1?NM(e,c,r):_==1&&NM(e,r,c),_;if(a=P(Ep(r.e,0),18).c.i,u=P(Ep(c.e,0),18).c.i,a==u)return i=P(K(P(Ep(r.e,0),18),(Y(),UQ)),17).a,l=P(K(P(Ep(c.e,0),18),UQ),17).a,i>l?NM(e,r,c):NM(e,c,r),il);for(m=e.c,h=0,g=m.length;hl?NM(e,r,c):NM(e,c,r),il)):e.b&&(_=RQe(r,c),_!=0)?(_==-1?NM(e,c,r):_==1&&NM(e,r,c),_):(o=0,d=0,yd(P(Ep(r.g,0),18),UQ)&&(o=P(K(P(Ep(r.g,0),18),UQ),17).a),yd(P(Ep(c.g,0),18),UQ)&&(d=P(K(P(Ep(r.g,0),18),UQ),17).a),s&&s==f?ki(Od(K(P(Ep(r.g,0),18),r$)))&&!ki(Od(K(P(Ep(c.g,0),18),r$)))?(NM(e,r,c),1):!ki(Od(K(P(Ep(r.g,0),18),r$)))&&ki(Od(K(P(Ep(c.g,0),18),r$)))?(NM(e,c,r),-1):(o>d?NM(e,r,c):NM(e,c,r),od)):(e.f&&(e.f._b(s)&&(o=P(e.f.xc(s),17).a),e.f._b(f)&&(d=P(e.f.xc(f),17).a)),o>d?NM(e,r,c):NM(e,c,r),od)))):r.e.c.length!=0&&c.g.c.length!=0?(NM(e,r,c),1):r.g.c.length!=0&&c.e.c.length!=0?(NM(e,c,r),-1):yd(r,(Y(),UQ))&&yd(c,UQ)?(i=P(K(r,UQ),17).a,l=P(K(c,UQ),17).a,i>l?NM(e,r,c):NM(e,c,r),il)):(NM(e,c,r),-1)}function Avt(e){e.gb||(e.gb=!0,e.b=PC(e,0),JS(e.b,18),YS(e.b,19),e.a=PC(e,1),JS(e.a,1),YS(e.a,2),YS(e.a,3),YS(e.a,4),YS(e.a,5),e.o=PC(e,2),JS(e.o,8),JS(e.o,9),YS(e.o,10),YS(e.o,11),YS(e.o,12),YS(e.o,13),YS(e.o,14),YS(e.o,15),YS(e.o,16),YS(e.o,17),YS(e.o,18),YS(e.o,19),YS(e.o,20),YS(e.o,21),YS(e.o,22),YS(e.o,23),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),e.p=PC(e,3),JS(e.p,2),JS(e.p,3),JS(e.p,4),JS(e.p,5),YS(e.p,6),YS(e.p,7),vx(e.p),vx(e.p),e.q=PC(e,4),JS(e.q,8),e.v=PC(e,5),YS(e.v,9),vx(e.v),vx(e.v),vx(e.v),e.w=PC(e,6),JS(e.w,2),JS(e.w,3),JS(e.w,4),YS(e.w,5),e.B=PC(e,7),YS(e.B,1),vx(e.B),vx(e.B),vx(e.B),e.Q=PC(e,8),YS(e.Q,0),vx(e.Q),e.R=PC(e,9),JS(e.R,1),e.S=PC(e,10),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),e.T=PC(e,11),YS(e.T,10),YS(e.T,11),YS(e.T,12),YS(e.T,13),YS(e.T,14),vx(e.T),vx(e.T),e.U=PC(e,12),JS(e.U,2),JS(e.U,3),YS(e.U,4),YS(e.U,5),YS(e.U,6),YS(e.U,7),vx(e.U),e.V=PC(e,13),YS(e.V,10),e.W=PC(e,14),JS(e.W,18),JS(e.W,19),JS(e.W,20),YS(e.W,21),YS(e.W,22),YS(e.W,23),e.bb=PC(e,15),JS(e.bb,10),JS(e.bb,11),JS(e.bb,12),JS(e.bb,13),JS(e.bb,14),JS(e.bb,15),JS(e.bb,16),YS(e.bb,17),vx(e.bb),vx(e.bb),e.eb=PC(e,16),JS(e.eb,2),JS(e.eb,3),JS(e.eb,4),JS(e.eb,5),JS(e.eb,6),JS(e.eb,7),YS(e.eb,8),YS(e.eb,9),e.ab=PC(e,17),JS(e.ab,0),JS(e.ab,1),e.H=PC(e,18),YS(e.H,0),YS(e.H,1),YS(e.H,2),YS(e.H,3),YS(e.H,4),YS(e.H,5),vx(e.H),e.db=PC(e,19),YS(e.db,2),e.c=FC(e,20),e.d=FC(e,21),e.e=FC(e,22),e.f=FC(e,23),e.i=FC(e,24),e.g=FC(e,25),e.j=FC(e,26),e.k=FC(e,27),e.n=FC(e,28),e.r=FC(e,29),e.s=FC(e,30),e.t=FC(e,31),e.u=FC(e,32),e.fb=FC(e,33),e.A=FC(e,34),e.C=FC(e,35),e.D=FC(e,36),e.F=FC(e,37),e.G=FC(e,38),e.I=FC(e,39),e.J=FC(e,40),e.L=FC(e,41),e.M=FC(e,42),e.N=FC(e,43),e.O=FC(e,44),e.P=FC(e,45),e.X=FC(e,46),e.Y=FC(e,47),e.Z=FC(e,48),e.$=FC(e,49),e._=FC(e,50),e.cb=FC(e,51),e.K=FC(e,52))}function jvt(e,t,n){var r,i,a,o=new vo,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(K(n,(mP(),_1)),88),ee,te,ne,C,re,ie;for(h=0,XS(o,(!t.a&&(t.a=new F($5,t,10,11)),t.a));o.b!=0;)u=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),27),l=I_(u),(A(J(l,s1))!==A((ID(),Z0))||A(J(l,g1))===A((FD(),dZ))||A(J(l,g1))===A((FD(),lZ))||ki(Od(J(l,l1)))||A(J(l,t1))!==A((YD(),RJ))||A(J(l,P1))===A((FM(),G0))||A(J(l,P1))===A((FM(),K0))||A(J(l,F1))===A((Zj(),k0))||A(J(l,F1))===A((Zj(),j0)))&&!ki(Od(J(u,a1)))&&OO(u,(Y(),UQ),G(h++)),_=!ki(Od(J(u,J1))),_&&(f=(!u.a&&(u.a=new F($5,u,10,11)),u.a).i!=0,m=c7e(u),p=A(J(u,D1))===A((_T(),g8)),ie=!qy(u,(vP(),s6))||wUe(kd(J(u,s6))),b=null,ie&&p&&(f||m)&&(b=Fdt(u),W(b,_1,S),yd(b,a0)&&Q_e(new rD(D(N(K(b,a0)))),b),P(J(u,W1),181).gc()!=0&&(d=b,To(new Mp(null,(!u.c&&(u.c=new F(e7,u,9,9)),new cv(u.c,16))),new lpe(d)),rct(u,b))),ee=n,te=P(xh(e.a,I_(u)),10),te&&(ee=te.e),y=F_t(e,u,ee),b&&(y.e=b,b.e=y,XS(o,(!u.a&&(u.a=new F($5,u,10,11)),u.a))));for(h=0,iy(o,t,o.c.b,o.c);o.b!=0;){for(a=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),27),c=new Lu((!a.b&&(a.b=new F(U5,a,12,3)),a.b));c.e!=c.i.gc();)s=P(gO(c),74),Nlt(s),(A(J(t,s1))!==A((ID(),Z0))||A(J(t,g1))===A((FD(),dZ))||A(J(t,g1))===A((FD(),lZ))||ki(Od(J(t,l1)))||A(J(t,t1))!==A((YD(),RJ))||A(J(t,P1))===A((FM(),G0))||A(J(t,P1))===A((FM(),K0))||A(J(t,F1))===A((Zj(),k0))||A(J(t,F1))===A((Zj(),j0)))&&OO(s,(Y(),UQ),G(h++)),C=cA(P(H((!s.b&&(s.b=new cf(H5,s,4,7)),s.b),0),84)),re=cA(P(H((!s.c&&(s.c=new cf(H5,s,5,8)),s.c),0),84)),!(ki(Od(J(s,J1)))||ki(Od(J(C,J1)))||ki(Od(J(re,J1))))&&(g=uj(s)&&ki(Od(J(C,k1)))&&ki(Od(J(s,A1))),x=a,g||Ex(re,C)?x=C:Ex(C,re)&&(x=re),ee=n,te=P(xh(e.a,x),10),te&&(ee=te.e),v=_P(e,s,x,ee),W(v,(Y(),hQ),Est(e,s,t,n)));if(p=A(J(a,D1))===A((_T(),g8)),p)for(i=new Lu((!a.a&&(a.a=new F($5,a,10,11)),a.a));i.e!=i.i.gc();)r=P(gO(i),27),ie=!qy(r,(vP(),s6))||wUe(kd(J(r,s6))),ne=A(J(r,D1))===A(g8),ie&&ne&&iy(o,r,o.c.b,o.c)}}function Y(){Y=C;var e,t;WQ=new yr(sbt),hQ=new yr(`coordinateOrigin`),e$=new yr(`processors`),mQ=new Wd(`compoundNode`,(rd(),!1)),jQ=new Wd(`insideConnections`,!1),GQ=new yr(`originalBendpoints`),KQ=new yr(`originalDummyNodePosition`),qQ=new yr(`originalLabelEdge`),n$=new yr(`representedLabels`),bQ=new yr(`endLabels`),xQ=new yr(`endLabel.origin`),IQ=new Wd(`labelSide`,(kk(),S8)),HQ=new Wd(`maxEdgeThickness`,0),r$=new Wd(`reversed`,!1),t$=new yr(cbt),zQ=new Wd(`longEdgeSource`,null),BQ=new Wd(`longEdgeTarget`,null),RQ=new Wd(`longEdgeHasLabelDummies`,!1),LQ=new Wd(`longEdgeBeforeLabelDummy`,!1),yQ=new Wd(`edgeConstraint`,(_w(),_Z)),NQ=new yr(`inLayerLayoutUnit`),MQ=new Wd(`inLayerConstraint`,(Zb(),aQ)),PQ=new Wd(`inLayerSuccessorConstraint`,new T),FQ=new Wd(`inLayerSuccessorConstraintBetweenNonDummies`,!1),QQ=new yr(`portDummy`),gQ=new Wd(`crossingHint`,G(0)),OQ=new Wd(`graphProperties`,(t=P(Ba($Z),9),new xf(t,P(Yd(t,t.length),9),0))),TQ=new Wd(`externalPortSide`,(nP(),h5)),EQ=new Wd(`externalPortSize`,new Fa),CQ=new yr(`externalPortReplacedDummies`),wQ=new yr(`externalPortReplacedDummy`),SQ=new Wd(`externalPortConnections`,(e=P(Ba(_5),9),new xf(e,P(Yd(e,e.length),9),0))),$Q=new Wd(Byt,0),uQ=new yr(`barycenterAssociates`),p$=new yr(`TopSideComments`),dQ=new yr(`BottomSideComments`),pQ=new yr(`CommentConnectionPort`),AQ=new Wd(`inputCollect`,!1),XQ=new Wd(`outputCollect`,!1),vQ=new Wd(`cyclic`,!1),_Q=new yr(`crossHierarchyMap`),f$=new yr(`targetOffset`),new Wd(`splineLabelSize`,new Fa),o$=new yr(`spacings`),ZQ=new Wd(`partitionConstraint`,!1),fQ=new yr(`breakingPoint.info`),u$=new yr(`splines.survivingEdge`),l$=new yr(`splines.route.start`),s$=new yr(`splines.edgeChain`),YQ=new yr(`originalPortConstraints`),a$=new yr(`selfLoopHolder`),c$=new yr(`splines.nsPortY`),UQ=new yr(`modelOrder`),VQ=new yr(`longEdgeTargetNode`),DQ=new Wd(Vbt,!1),i$=new Wd(Vbt,!1),kQ=new yr(`layerConstraints.hiddenNodes`),JQ=new yr(`layerConstraints.opposidePort`),d$=new yr(`targetNode.modelOrder`)}function Mvt(e,t,n,i){var a,o,s,c,l,u,d,f,p,m,h;for(f=dO(e.b,0);f.b!=f.d.c;)if(d=P(Lv(f),40),!ff(d.c,LV))for(o=P(ay(new Mp(null,new cv(Vnt(d,e),16)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),t==(GT(),t8)||t==n8?o.jd(new Uae):o.jd(new Wae),h=o.gc(),a=0;a0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(l-m)/(r.Math.abs(c-p)/40)>50&&(m>l?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a+i/5.3,d.e.b+d.f.b*s-i/2)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a+i/5.3,d.e.b+d.f.b*s+i/2)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a,d.e.b+d.f.b*s))):t==n8?(u=D(N(K(d,(tP(),$2)))),d.e.a-i>u?yl(P(o.Xb(a),65).a,new k(u-n,d.e.b+d.f.b*s)):P(o.Xb(a),65).a.b>0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(l-m)/(r.Math.abs(c-p)/40)>50&&(m>l?yl(P(o.Xb(a),65).a,new k(d.e.a-i/5.3,d.e.b+d.f.b*s-i/2)):yl(P(o.Xb(a),65).a,new k(d.e.a-i/5.3,d.e.b+d.f.b*s+i/2)))),yl(P(o.Xb(a),65).a,new k(d.e.a,d.e.b+d.f.b*s))):t==i8?(u=D(N(K(d,(tP(),Q2)))),d.e.b+d.f.b+i0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(c-p)/(r.Math.abs(l-m)/40)>50&&(p>c?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s-i/2,d.e.b+i/5.3+d.f.b)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s+i/2,d.e.b+i/5.3+d.f.b)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,d.e.b+d.f.b))):(u=D(N(K(d,(tP(),$2)))),GZe(P(o.Xb(a),65),e)?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,P(vd(P(o.Xb(a),65).a),8).b)):d.e.b-i>u?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,u-n)):P(o.Xb(a),65).a.b>0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(c-p)/(r.Math.abs(l-m)/40)>50&&(p>c?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s-i/2,d.e.b-i/5.3)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s+i/2,d.e.b-i/5.3)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,d.e.b)))}function vP(){vP=C;var e,t;s6=new yr(pSt),W6=new yr(mSt),nzt=(RO(),q3),tzt=new Tl(GB,nzt),new Er,c6=new Tl(FL,null),rzt=new yr(hSt),szt=(eA(),Zp(a6,U(O(o6,1),Z,298,0,[t6]))),d6=new Tl(rV,szt),f6=new Tl(WB,(rd(),!1)),czt=(GT(),r8),p6=new Tl(JB,czt),dzt=(wE(),f8),uzt=new Tl(xB,dzt),mzt=new Tl(dSt,!1),hzt=(_T(),_8),g6=new Tl(bB,hzt),Tzt=new iu(12),A6=new Tl(IL,Tzt),y6=new Tl(tR,!1),b6=new Tl(hV,!1),k6=new Tl(iR,!1),Nzt=(rA(),H8),I6=new Tl(nR,Nzt),V6=new yr(fV),H6=new yr(XL),U6=new yr($L),G6=new yr(eR),_zt=new ai,x6=new Tl(iV,_zt),ozt=new Tl(sV,!1),gzt=new Tl(cV,!1),new yr(gSt),vzt=new ei,S6=new Tl(pV,vzt),O6=new Tl(HB,!1),new Er,Lzt=new Tl(_St,1),u6=new yr(vSt),l6=new yr(ySt),Z6=new Tl(uR,!1),new Tl(bSt,!0),G(0),new Tl(xSt,G(100)),new Tl(SSt,!1),G(0),new Tl(CSt,G(4e3)),G(0),new Tl(wSt,G(400)),new Tl(TSt,!1),new Tl(ESt,!1),new Tl(DSt,!0),new Tl(OSt,!1),azt=(ZE(),F5),izt=new Tl(fSt,azt),Rzt=new Tl(AB,10),zzt=new Tl(jB,10),Bzt=new Tl(NL,20),Vzt=new Tl(MB,10),Hzt=new Tl(QL,2),Uzt=new Tl(NB,10),Wzt=new Tl(PB,0),q6=new Tl(LB,5),Gzt=new Tl(FB,1),Kzt=new Tl(IB,1),J6=new Tl(ZL,20),qzt=new Tl(RB,10),Xzt=new Tl(zB,10),K6=new yr(BB),Yzt=new OCe,Jzt=new Tl(mV,Yzt),Ozt=new yr(dV),Dzt=!1,Ezt=new Tl(uV,Dzt),bzt=new iu(5),yzt=new Tl(YB,bzt),xzt=(Ej(),t=P(Ba(M8),9),new xf(t,P(Yd(t,t.length),9),0)),C6=new Tl(cR,xzt),jzt=(pO(),P8),Azt=new Tl(QB,jzt),M6=new yr($B),N6=new yr(eV),P6=new yr(tV),j6=new yr(nV),Szt=(e=P(Ba(S5),9),new xf(e,P(Yd(e,e.length),9),0)),w6=new Tl(sR,Szt),wzt=sE((UM(),T5)),D6=new Tl(oR,wzt),Czt=new k(0,0),E6=new Tl(gR,Czt),T6=new Tl(aR,!1),lzt=(Lx(),o8),h6=new Tl(aV,lzt),m6=new Tl(rR,!1),new yr(kSt),G(1),new Tl(ASt,null),Mzt=new yr(lV),L6=new yr(oV),Izt=(nP(),h5),B6=new Tl(UB,Izt),F6=new yr(VB),Pzt=(rj(),sE(q8)),z6=new Tl(lR,Pzt),R6=new Tl(XB,!1),Fzt=new Tl(ZB,!0),new Er,$6=new Tl(dR,1),eBt=new Tl(jSt,null),X6=new Tl(fR,150),Y6=new Tl(pR,1.414),Q6=new Tl(mR,null),Zzt=new Tl(MSt,1),_6=new Tl(KB,!1),v6=new Tl(qB,!1),fzt=new Tl(PL,1),pzt=(hA(),m8),new Tl(NSt,pzt),kzt=!0,$zt=(gT(),M5),tBt=M5,Qzt=M5}function yP(){yP=C,_Y=new ks(`DIRECTION_PREPROCESSOR`,0),mY=new ks(`COMMENT_PREPROCESSOR`,1),vY=new ks(`EDGE_AND_LAYER_CONSTRAINT_EDGE_REVERSER`,2),PY=new ks(`INTERACTIVE_EXTERNAL_PORT_POSITIONER`,3),$Y=new ks(`PARTITION_PREPROCESSOR`,4),RY=new ks(`LABEL_DUMMY_INSERTER`,5),aX=new ks(`SELF_LOOP_PREPROCESSOR`,6),UY=new ks(`LAYER_CONSTRAINT_PREPROCESSOR`,7),ZY=new ks(`PARTITION_MIDPROCESSOR`,8),kY=new ks(`HIGH_DEGREE_NODE_LAYER_PROCESSOR`,9),qY=new ks(`NODE_PROMOTION`,10),HY=new ks(`LAYER_CONSTRAINT_POSTPROCESSOR`,11),QY=new ks(`PARTITION_POSTPROCESSOR`,12),TY=new ks(`HIERARCHICAL_PORT_CONSTRAINT_PROCESSOR`,13),sX=new ks(`SEMI_INTERACTIVE_CROSSMIN_PROCESSOR`,14),cY=new ks(`BREAKING_POINT_INSERTER`,15),KY=new ks(`LONG_EDGE_SPLITTER`,16),tX=new ks(`PORT_SIDE_PROCESSOR`,17),FY=new ks(`INVERTED_PORT_PROCESSOR`,18),eX=new ks(`PORT_LIST_SORTER`,19),lX=new ks(`SORT_BY_INPUT_ORDER_OF_MODEL`,20),YY=new ks(`NORTH_SOUTH_PORT_PREPROCESSOR`,21),lY=new ks(`BREAKING_POINT_PROCESSOR`,22),XY=new ks(Nbt,23),uX=new ks(Pbt,24),rX=new ks(`SELF_LOOP_PORT_RESTORER`,25),cX=new ks(`SINGLE_EDGE_GRAPH_WRAPPER`,26),IY=new ks(`IN_LAYER_CONSTRAINT_PROCESSOR`,27),SY=new ks(`END_NODE_PORT_LABEL_MANAGEMENT_PROCESSOR`,28),LY=new ks(`LABEL_AND_NODE_SIZE_PROCESSOR`,29),NY=new ks(`INNERMOST_NODE_MARGIN_CALCULATOR`,30),oX=new ks(`SELF_LOOP_ROUTER`,31),fY=new ks(`COMMENT_NODE_MARGIN_CALCULATOR`,32),bY=new ks(`END_LABEL_PREPROCESSOR`,33),BY=new ks(`LABEL_DUMMY_SWITCHER`,34),dY=new ks(`CENTER_LABEL_MANAGEMENT_PROCESSOR`,35),VY=new ks(`LABEL_SIDE_SELECTOR`,36),jY=new ks(`HYPEREDGE_DUMMY_MERGER`,37),EY=new ks(`HIERARCHICAL_PORT_DUMMY_SIZE_PROCESSOR`,38),WY=new ks(`LAYER_SIZE_AND_GRAPH_HEIGHT_CALCULATOR`,39),OY=new ks(`HIERARCHICAL_PORT_POSITION_PROCESSOR`,40),hY=new ks(`CONSTRAINTS_POSTPROCESSOR`,41),pY=new ks(`COMMENT_POSTPROCESSOR`,42),MY=new ks(`HYPERNODE_PROCESSOR`,43),DY=new ks(`HIERARCHICAL_PORT_ORTHOGONAL_EDGE_ROUTER`,44),GY=new ks(`LONG_EDGE_JOINER`,45),iX=new ks(`SELF_LOOP_POSTPROCESSOR`,46),uY=new ks(`BREAKING_POINT_REMOVER`,47),JY=new ks(`NORTH_SOUTH_PORT_POSTPROCESSOR`,48),AY=new ks(`HORIZONTAL_COMPACTOR`,49),zY=new ks(`LABEL_DUMMY_REMOVER`,50),CY=new ks(`FINAL_SPLINE_BENDPOINTS_CALCULATOR`,51),xY=new ks(`END_LABEL_SORTER`,52),nX=new ks(`REVERSED_EDGE_RESTORER`,53),yY=new ks(`END_LABEL_POSTPROCESSOR`,54),wY=new ks(`HIERARCHICAL_NODE_RESIZER`,55),gY=new ks(`DIRECTION_POSTPROCESSOR`,56)}function bP(){bP=C,k$=(px(),pZ),Jkt=new Tl(XR,k$),oAt=new Tl(ZR,(rd(),!1)),F$=(Bv(),sQ),dAt=new Tl(QR,F$),EAt=new Tl($R,!1),DAt=new Tl(ez,!0),bkt=new Tl(tz,!1),U$=(Qb(),e2),HAt=new Tl(nz,U$),G(1),XAt=new Tl(rz,G(7)),ZAt=new Tl(iz,!1),sAt=new Tl(az,!1),O$=(FD(),cZ),qkt=new Tl(oz,O$),R$=(Zj(),N0),TAt=new Tl(sz,R$),I$=(XE(),v$),_At=new Tl(cz,I$),G(-1),gAt=new Tl(lz,null),G(-1),vAt=new Tl(uz,G(-1)),G(-1),yAt=new Tl(dz,G(4)),G(-1),xAt=new Tl(fz,G(2)),L$=(FM(),Y0),wAt=new Tl(pz,L$),G(0),CAt=new Tl(mz,G(0)),mAt=new Tl(hz,G(AP)),D$=(bS(),eZ),Kkt=new Tl(gz,D$),jkt=new Tl(_z,!1),Rkt=new Tl(vz,.1),Wkt=new Tl(yz,!1),Bkt=new Tl(bz,null),Vkt=new Tl(xz,null),G(-1),Hkt=new Tl(Sz,null),G(-1),Ukt=new Tl(Cz,G(-1)),G(0),Mkt=new Tl(wz,G(40)),E$=(qC(),nQ),Ikt=new Tl(Tz,E$),T$=eQ,Nkt=new Tl(Ez,T$),H$=(CO(),V0),VAt=new Tl(Dz,H$),MAt=new yr(Oz),z$=(wb(),EZ),OAt=new Tl(kz,z$),B$=(qk(),MZ),AAt=new Tl(Az,B$),new Er,FAt=new Tl(jz,.3),LAt=new yr(Mz),V$=(IO(),R0),RAt=new Tl(Nz,V$),M$=(CC(),a2),$kt=new Tl(Pz,M$),N$=(Nw(),c2),eAt=new Tl(Fz,N$),P$=(Xw(),u2),tAt=new Tl(Iz,P$),rAt=new Tl(Lz,.2),Zkt=new Tl(Rz,2),KAt=new Tl(zz,null),JAt=new Tl(Bz,10),qAt=new Tl(Vz,10),YAt=new Tl(Hz,20),G(0),UAt=new Tl(Uz,G(0)),G(0),WAt=new Tl(Wz,G(0)),G(0),GAt=new Tl(Gz,G(0)),xkt=new Tl(Kz,!1),x$=(TA(),BZ),Ckt=new Tl(qz,x$),b$=(Ky(),ZX),Skt=new Tl(Jz,b$),lAt=new Tl(Yz,!1),G(0),cAt=new Tl(Xz,G(16)),G(0),uAt=new Tl(Zz,G(5)),K$=(sw(),p2),_jt=new Tl(Qz,K$),QAt=new Tl($z,10),tjt=new Tl(eB,1),G$=(lS(),aZ),cjt=new Tl(tB,G$),ijt=new yr(nB),W$=G(1),G(0),ojt=new Tl(rB,W$),q$=(cS(),d2),xjt=new Tl(iB,q$),vjt=new yr(aB),pjt=new Tl(oB,!0),djt=new Tl(sB,2),hjt=new Tl(cB,!0),j$=(kA(),CZ),Xkt=new Tl(lB,j$),A$=(GA(),GX),Ykt=new Tl(uB,A$),w$=(ID(),Z0),Akt=new Tl(dB,w$),kkt=new Tl(fB,!1),Okt=new Tl(pB,!1),S$=(YD(),RJ),wkt=new Tl(mB,S$),C$=(hT(),P0),Dkt=new Tl(hB,C$),Tkt=new Tl(gB,0),Ekt=new Tl(_B,0),pAt=uZ,fAt=$X,bAt=M0,SAt=M0,hAt=A0,zkt=(_T(),g8),Gkt=eZ,Lkt=eZ,Pkt=eZ,Fkt=g8,NAt=W0,PAt=V0,kAt=V0,jAt=V0,IAt=U0,BAt=W0,zAt=W0,nAt=(wE(),d8),iAt=d8,aAt=u2,Qkt=u8,$At=m2,ejt=f2,njt=m2,rjt=f2,ljt=m2,ujt=f2,ajt=iZ,sjt=aZ,Sjt=m2,Cjt=f2,yjt=m2,bjt=f2,mjt=f2,fjt=f2,gjt=f2}function Nvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe=0,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le;for(oe=t,le=0,fe=oe.length;le0&&(e.a[ye.p]=Oe++)}for(Ne=0,se=n,ue=0,pe=se.length;ue0;){for(ye=(jd(Ce.b>0),P(Ce.a.Xb(Ce.c=--Ce.b),12)),Se=0,c=new w(ye.e);c.a0&&(ye.j==(nP(),Z8)?(e.a[ye.p]=Ne,++Ne):(e.a[ye.p]=Ne+me+ge,++ge))}Ne+=ge}for(xe=new Dr,h=new Rl,ae=t,ce=0,de=ae.length;ceu.b&&(u.b=we)):ye.i.c==De&&(weu.c&&(u.c=we));for(bb(g,0,g.length,null),Me=V(q9,HF,28,g.length,15,1),i=V(q9,HF,28,Ne+1,15,1),v=0;v0;)te%2>0&&(a+=Ie[te+1]),te=(te-1)/2|0,++Ie[te];for(C=V(INt,FP,374,g.length*2,0,1),x=0;x0&&h_(ce.f),J(v,eBt)!=null&&(c=P(J(v,eBt),347),xe=c.Tg(v),Ql(v,r.Math.max(v.g,xe.a),r.Math.max(v.f,xe.b)));if(pe=P(J(t,A6),107),m=t.g-(pe.b+pe.c),p=t.f-(pe.d+pe.a),we.bh(`Available Child Area: (`+m+`|`+p+`)`),OO(t,c6,m/p),D2e(t,a,i.eh(de)),P(J(t,Q6),280)==N5&&(G_t(t),Ql(t,pe.b+D(N(J(t,u6)))+pe.c,pe.d+D(N(J(t,l6)))+pe.a)),we.bh(`Executed layout algorithm: `+kd(J(t,s6))+` on node `+t.k),P(J(t,Q6),280)==M5){if(m<0||p<0)throw E(new zi(`The size defined by the parent parallel node is too small for the space provided by the paddings of the child hierarchical node. `+t.k));for(qy(t,u6)||qy(t,l6)||G_t(t),g=D(N(J(t,u6))),h=D(N(J(t,l6))),we.bh(`Desired Child Area: (`+g+`|`+h+`)`),he=m/g,ge=p/h,me=r.Math.min(he,r.Math.min(ge,D(N(J(t,Zzt))))),OO(t,$6,me),we.bh(t.k+` -- Local Scale Factor (X|Y): (`+he+`|`+ge+`)`),x=P(J(t,d6),21),o=0,s=0,me'?`:ff(DCt,e)?`'(?<' or '(? toIndex: `,VI=`, toIndex: `,HI=`Index: `,UI=`, Size: `,WI=`org.eclipse.elk.alg.common`,GI={50:1},yyt=`org.eclipse.elk.alg.common.compaction`,byt=`Scanline/EventHandler`,KI=`org.eclipse.elk.alg.common.compaction.oned`,xyt=`CNode belongs to another CGroup.`,Syt=`ISpacingsHandler/1`,qI=`The `,JI=` instance has been finished already.`,Cyt=`The direction `,wyt=` is not supported by the CGraph instance.`,Tyt=`OneDimensionalCompactor`,Eyt=`OneDimensionalCompactor/lambda$0$Type`,Dyt=`Quadruplet`,Oyt=`ScanlineConstraintCalculator`,kyt=`ScanlineConstraintCalculator/ConstraintsScanlineHandler`,Ayt=`ScanlineConstraintCalculator/ConstraintsScanlineHandler/lambda$0$Type`,jyt=`ScanlineConstraintCalculator/Timestamp`,Myt=`ScanlineConstraintCalculator/lambda$0$Type`,YI={178:1,46:1},XI=`org.eclipse.elk.alg.common.compaction.options`,ZI=`org.eclipse.elk.core.data`,QI=`org.eclipse.elk.polyomino.traversalStrategy`,$I=`org.eclipse.elk.polyomino.lowLevelSort`,eL=`org.eclipse.elk.polyomino.highLevelSort`,tL=`org.eclipse.elk.polyomino.fill`,nL={134:1},rL=`polyomino`,iL=`org.eclipse.elk.alg.common.networksimplex`,aL={183:1,3:1,4:1},Nyt=`org.eclipse.elk.alg.common.nodespacing`,oL=`org.eclipse.elk.alg.common.nodespacing.cellsystem`,sL=`CENTER`,Pyt={217:1,336:1},Fyt={3:1,4:1,5:1,603:1},cL=`LEFT`,lL=`RIGHT`,Iyt=`Vertical alignment cannot be null`,Lyt=`BOTTOM`,uL=`org.eclipse.elk.alg.common.nodespacing.internal`,dL=`UNDEFINED`,fL=.01,pL=`org.eclipse.elk.alg.common.nodespacing.internal.algorithm`,Ryt=`LabelPlacer/lambda$0$Type`,zyt=`LabelPlacer/lambda$1$Type`,Byt=`portRatioOrPosition`,mL=`org.eclipse.elk.alg.common.overlaps`,hL=`DOWN`,gL=`org.eclipse.elk.alg.common.polyomino`,_L=`NORTH`,vL=`EAST`,yL=`SOUTH`,bL=`WEST`,xL=`org.eclipse.elk.alg.common.polyomino.structures`,Vyt=`Direction`,SL=`Grid is only of size `,CL=`. Requested point (`,wL=`) is out of bounds.`,TL=` Given center based coordinates were (`,EL=`org.eclipse.elk.graph.properties`,Hyt=`IPropertyHolder`,Uyt={3:1,96:1,137:1},DL=`org.eclipse.elk.alg.common.spore`,Wyt=`org.eclipse.elk.alg.common.utils`,OL={205:1},kL=`org.eclipse.elk.core`,Gyt=`Connected Components Compaction`,Kyt=`org.eclipse.elk.alg.disco`,AL=`org.eclipse.elk.alg.disco.graph`,jL=`org.eclipse.elk.alg.disco.options`,qyt=`CompactionStrategy`,Jyt=`org.eclipse.elk.disco.componentCompaction.strategy`,Yyt=`org.eclipse.elk.disco.componentCompaction.componentLayoutAlgorithm`,Xyt=`org.eclipse.elk.disco.debug.discoGraph`,Zyt=`org.eclipse.elk.disco.debug.discoPolys`,Qyt=`componentCompaction`,ML=`org.eclipse.elk.disco`,NL=`org.eclipse.elk.spacing.componentComponent`,PL=`org.eclipse.elk.edge.thickness`,FL=`org.eclipse.elk.aspectRatio`,IL=`org.eclipse.elk.padding`,LL=`org.eclipse.elk.alg.disco.transform`,RL=1.5707963267948966,zL=17976931348623157e292,BL={3:1,4:1,5:1,198:1},$yt={3:1,6:1,4:1,5:1,100:1,115:1},VL=`org.eclipse.elk.alg.force`,ebt=`ComponentsProcessor`,tbt=`ComponentsProcessor/1`,nbt=`ElkGraphImporter/lambda$0$Type`,HL=`org.eclipse.elk.alg.force.graph`,rbt=`Component Layout`,ibt=`org.eclipse.elk.alg.force.model`,UL=`org.eclipse.elk.force.model`,abt=`org.eclipse.elk.force.iterations`,obt=`org.eclipse.elk.force.repulsivePower`,WL=`org.eclipse.elk.force.temperature`,GL=.001,KL=`org.eclipse.elk.force.repulsion`,qL=`org.eclipse.elk.alg.force.options`,JL=1.600000023841858,YL=`org.eclipse.elk.force`,XL=`org.eclipse.elk.priority`,ZL=`org.eclipse.elk.spacing.nodeNode`,QL=`org.eclipse.elk.spacing.edgeLabel`,$L=`org.eclipse.elk.randomSeed`,eR=`org.eclipse.elk.separateConnectedComponents`,tR=`org.eclipse.elk.interactive`,nR=`org.eclipse.elk.portConstraints`,rR=`org.eclipse.elk.edgeLabels.inline`,iR=`org.eclipse.elk.omitNodeMicroLayout`,aR=`org.eclipse.elk.nodeSize.fixedGraphSize`,oR=`org.eclipse.elk.nodeSize.options`,sR=`org.eclipse.elk.nodeSize.constraints`,cR=`org.eclipse.elk.nodeLabels.placement`,lR=`org.eclipse.elk.portLabels.placement`,uR=`org.eclipse.elk.topdownLayout`,dR=`org.eclipse.elk.topdown.scaleFactor`,fR=`org.eclipse.elk.topdown.hierarchicalNodeWidth`,pR=`org.eclipse.elk.topdown.hierarchicalNodeAspectRatio`,mR=`org.eclipse.elk.topdown.nodeType`,sbt=`origin`,cbt=`random`,lbt=`boundingBox.upLeft`,ubt=`boundingBox.lowRight`,dbt=`org.eclipse.elk.stress.fixed`,fbt=`org.eclipse.elk.stress.desiredEdgeLength`,pbt=`org.eclipse.elk.stress.dimension`,mbt=`org.eclipse.elk.stress.epsilon`,hbt=`org.eclipse.elk.stress.iterationLimit`,hR=`org.eclipse.elk.stress`,gbt=`ELK Stress`,gR=`org.eclipse.elk.nodeSize.minimum`,_R=`org.eclipse.elk.alg.force.stress`,_bt=`Layered layout`,vR=`org.eclipse.elk.alg.layered`,yR=`org.eclipse.elk.alg.layered.compaction.components`,bR=`org.eclipse.elk.alg.layered.compaction.oned`,xR=`org.eclipse.elk.alg.layered.compaction.oned.algs`,SR=`org.eclipse.elk.alg.layered.compaction.recthull`,CR=`org.eclipse.elk.alg.layered.components`,wR=`NONE`,vbt=`MODEL_ORDER`,TR={3:1,6:1,4:1,9:1,5:1,126:1},ybt={3:1,6:1,4:1,5:1,150:1,100:1,115:1},ER=`org.eclipse.elk.alg.layered.compound`,DR={47:1},OR=`org.eclipse.elk.alg.layered.graph`,kR=` -> `,bbt=`Not supported by LGraph`,xbt=`Port side is undefined`,AR={3:1,6:1,4:1,5:1,483:1,150:1,100:1,115:1},jR={3:1,6:1,4:1,5:1,150:1,199:1,210:1,100:1,115:1},Sbt={3:1,6:1,4:1,5:1,150:1,2042:1,210:1,100:1,115:1},Cbt=`([{"' \r +`,wbt=`)]}"' \r +`,Tbt=`The given string contains parts that cannot be parsed as numbers.`,MR=`org.eclipse.elk.core.math`,Ebt={3:1,4:1,140:1,214:1,423:1},Dbt={3:1,4:1,107:1,214:1,423:1},NR=`org.eclipse.elk.alg.layered.graph.transform`,Obt=`ElkGraphImporter`,kbt=`ElkGraphImporter/lambda$1$Type`,Abt=`ElkGraphImporter/lambda$2$Type`,jbt=`ElkGraphImporter/lambda$4$Type`,PR=`org.eclipse.elk.alg.layered.intermediate`,Mbt=`Node margin calculation`,Nbt=`ONE_SIDED_GREEDY_SWITCH`,Pbt=`TWO_SIDED_GREEDY_SWITCH`,FR=`No implementation is available for the layout processor `,IR=`IntermediateProcessorStrategy`,LR=`Node '`,Fbt=`FIRST_SEPARATE`,Ibt=`LAST_SEPARATE`,Lbt=`Odd port side processing`,RR=`org.eclipse.elk.alg.layered.intermediate.compaction`,zR=`org.eclipse.elk.alg.layered.intermediate.greedyswitch`,BR=`org.eclipse.elk.alg.layered.p3order.counting`,VR={230:1},HR=`org.eclipse.elk.alg.layered.intermediate.loops`,UR=`org.eclipse.elk.alg.layered.intermediate.loops.ordering`,WR=`org.eclipse.elk.alg.layered.intermediate.loops.routing`,GR=`org.eclipse.elk.alg.layered.intermediate.preserveorder`,KR=`org.eclipse.elk.alg.layered.intermediate.wrapping`,qR=`org.eclipse.elk.alg.layered.options`,JR=`INTERACTIVE`,YR=`GREEDY`,Rbt=`DEPTH_FIRST`,zbt=`EDGE_LENGTH`,Bbt=`SELF_LOOPS`,Vbt=`firstTryWithInitialOrder`,XR=`org.eclipse.elk.layered.directionCongruency`,ZR=`org.eclipse.elk.layered.feedbackEdges`,QR=`org.eclipse.elk.layered.interactiveReferencePoint`,$R=`org.eclipse.elk.layered.mergeEdges`,ez=`org.eclipse.elk.layered.mergeHierarchyEdges`,tz=`org.eclipse.elk.layered.allowNonFlowPortsToSwitchSides`,nz=`org.eclipse.elk.layered.portSortingStrategy`,rz=`org.eclipse.elk.layered.thoroughness`,iz=`org.eclipse.elk.layered.unnecessaryBendpoints`,az=`org.eclipse.elk.layered.generatePositionAndLayerIds`,oz=`org.eclipse.elk.layered.cycleBreaking.strategy`,sz=`org.eclipse.elk.layered.layering.strategy`,cz=`org.eclipse.elk.layered.layering.layerConstraint`,lz=`org.eclipse.elk.layered.layering.layerChoiceConstraint`,uz=`org.eclipse.elk.layered.layering.layerId`,dz=`org.eclipse.elk.layered.layering.minWidth.upperBoundOnWidth`,fz=`org.eclipse.elk.layered.layering.minWidth.upperLayerEstimationScalingFactor`,pz=`org.eclipse.elk.layered.layering.nodePromotion.strategy`,mz=`org.eclipse.elk.layered.layering.nodePromotion.maxIterations`,hz=`org.eclipse.elk.layered.layering.coffmanGraham.layerBound`,gz=`org.eclipse.elk.layered.crossingMinimization.strategy`,_z=`org.eclipse.elk.layered.crossingMinimization.forceNodeModelOrder`,vz=`org.eclipse.elk.layered.crossingMinimization.hierarchicalSweepiness`,yz=`org.eclipse.elk.layered.crossingMinimization.semiInteractive`,bz=`org.eclipse.elk.layered.crossingMinimization.inLayerPredOf`,xz=`org.eclipse.elk.layered.crossingMinimization.inLayerSuccOf`,Sz=`org.eclipse.elk.layered.crossingMinimization.positionChoiceConstraint`,Cz=`org.eclipse.elk.layered.crossingMinimization.positionId`,wz=`org.eclipse.elk.layered.crossingMinimization.greedySwitch.activationThreshold`,Tz=`org.eclipse.elk.layered.crossingMinimization.greedySwitch.type`,Ez=`org.eclipse.elk.layered.crossingMinimization.greedySwitchHierarchical.type`,Dz=`org.eclipse.elk.layered.nodePlacement.strategy`,Oz=`org.eclipse.elk.layered.nodePlacement.favorStraightEdges`,kz=`org.eclipse.elk.layered.nodePlacement.bk.edgeStraightening`,Az=`org.eclipse.elk.layered.nodePlacement.bk.fixedAlignment`,jz=`org.eclipse.elk.layered.nodePlacement.linearSegments.deflectionDampening`,Mz=`org.eclipse.elk.layered.nodePlacement.networkSimplex.nodeFlexibility`,Nz=`org.eclipse.elk.layered.nodePlacement.networkSimplex.nodeFlexibility.default`,Pz=`org.eclipse.elk.layered.edgeRouting.selfLoopDistribution`,Fz=`org.eclipse.elk.layered.edgeRouting.selfLoopOrdering`,Iz=`org.eclipse.elk.layered.edgeRouting.splines.mode`,Lz=`org.eclipse.elk.layered.edgeRouting.splines.sloppy.layerSpacingFactor`,Rz=`org.eclipse.elk.layered.edgeRouting.polyline.slopedEdgeZoneWidth`,zz=`org.eclipse.elk.layered.spacing.baseValue`,Bz=`org.eclipse.elk.layered.spacing.edgeNodeBetweenLayers`,Vz=`org.eclipse.elk.layered.spacing.edgeEdgeBetweenLayers`,Hz=`org.eclipse.elk.layered.spacing.nodeNodeBetweenLayers`,Uz=`org.eclipse.elk.layered.priority.direction`,Wz=`org.eclipse.elk.layered.priority.shortness`,Gz=`org.eclipse.elk.layered.priority.straightness`,Kz=`org.eclipse.elk.layered.compaction.connectedComponents`,qz=`org.eclipse.elk.layered.compaction.postCompaction.strategy`,Jz=`org.eclipse.elk.layered.compaction.postCompaction.constraints`,Yz=`org.eclipse.elk.layered.highDegreeNodes.treatment`,Xz=`org.eclipse.elk.layered.highDegreeNodes.threshold`,Zz=`org.eclipse.elk.layered.highDegreeNodes.treeHeight`,Qz=`org.eclipse.elk.layered.wrapping.strategy`,$z=`org.eclipse.elk.layered.wrapping.additionalEdgeSpacing`,eB=`org.eclipse.elk.layered.wrapping.correctionFactor`,tB=`org.eclipse.elk.layered.wrapping.cutting.strategy`,nB=`org.eclipse.elk.layered.wrapping.cutting.cuts`,rB=`org.eclipse.elk.layered.wrapping.cutting.msd.freedom`,iB=`org.eclipse.elk.layered.wrapping.validify.strategy`,aB=`org.eclipse.elk.layered.wrapping.validify.forbiddenIndices`,oB=`org.eclipse.elk.layered.wrapping.multiEdge.improveCuts`,sB=`org.eclipse.elk.layered.wrapping.multiEdge.distancePenalty`,cB=`org.eclipse.elk.layered.wrapping.multiEdge.improveWrappedEdges`,lB=`org.eclipse.elk.layered.edgeLabels.sideSelection`,uB=`org.eclipse.elk.layered.edgeLabels.centerLabelPlacementStrategy`,dB=`org.eclipse.elk.layered.considerModelOrder.strategy`,fB=`org.eclipse.elk.layered.considerModelOrder.portModelOrder`,pB=`org.eclipse.elk.layered.considerModelOrder.noModelOrder`,mB=`org.eclipse.elk.layered.considerModelOrder.components`,hB=`org.eclipse.elk.layered.considerModelOrder.longEdgeStrategy`,gB=`org.eclipse.elk.layered.considerModelOrder.crossingCounterNodeInfluence`,_B=`org.eclipse.elk.layered.considerModelOrder.crossingCounterPortInfluence`,vB=`layering`,Hbt=`layering.minWidth`,Ubt=`layering.nodePromotion`,yB=`crossingMinimization`,bB=`org.eclipse.elk.hierarchyHandling`,Wbt=`crossingMinimization.greedySwitch`,Gbt=`nodePlacement`,Kbt=`nodePlacement.bk`,qbt=`edgeRouting`,xB=`org.eclipse.elk.edgeRouting`,SB=`spacing`,CB=`priority`,wB=`compaction`,Jbt=`compaction.postCompaction`,Ybt=`Specifies whether and how post-process compaction is applied.`,TB=`highDegreeNodes`,EB=`wrapping`,Xbt=`wrapping.cutting`,Zbt=`wrapping.validify`,DB=`wrapping.multiEdge`,OB=`edgeLabels`,kB=`considerModelOrder`,AB=`org.eclipse.elk.spacing.commentComment`,jB=`org.eclipse.elk.spacing.commentNode`,MB=`org.eclipse.elk.spacing.edgeEdge`,NB=`org.eclipse.elk.spacing.edgeNode`,PB=`org.eclipse.elk.spacing.labelLabel`,FB=`org.eclipse.elk.spacing.labelPortHorizontal`,IB=`org.eclipse.elk.spacing.labelPortVertical`,LB=`org.eclipse.elk.spacing.labelNode`,RB=`org.eclipse.elk.spacing.nodeSelfLoop`,zB=`org.eclipse.elk.spacing.portPort`,BB=`org.eclipse.elk.spacing.individual`,VB=`org.eclipse.elk.port.borderOffset`,HB=`org.eclipse.elk.noLayout`,UB=`org.eclipse.elk.port.side`,WB=`org.eclipse.elk.debugMode`,GB=`org.eclipse.elk.alignment`,KB=`org.eclipse.elk.insideSelfLoops.activate`,qB=`org.eclipse.elk.insideSelfLoops.yo`,JB=`org.eclipse.elk.direction`,YB=`org.eclipse.elk.nodeLabels.padding`,XB=`org.eclipse.elk.portLabels.nextToPortIfPossible`,ZB=`org.eclipse.elk.portLabels.treatAsGroup`,QB=`org.eclipse.elk.portAlignment.default`,$B=`org.eclipse.elk.portAlignment.north`,eV=`org.eclipse.elk.portAlignment.south`,tV=`org.eclipse.elk.portAlignment.west`,nV=`org.eclipse.elk.portAlignment.east`,rV=`org.eclipse.elk.contentAlignment`,iV=`org.eclipse.elk.junctionPoints`,aV=`org.eclipse.elk.edgeLabels.placement`,oV=`org.eclipse.elk.port.index`,sV=`org.eclipse.elk.commentBox`,cV=`org.eclipse.elk.hypernode`,lV=`org.eclipse.elk.port.anchor`,uV=`org.eclipse.elk.partitioning.activate`,dV=`org.eclipse.elk.partitioning.partition`,fV=`org.eclipse.elk.position`,pV=`org.eclipse.elk.margins`,mV=`org.eclipse.elk.spacing.portsSurrounding`,hV=`org.eclipse.elk.interactiveLayout`,gV=`org.eclipse.elk.core.util`,_V={3:1,4:1,5:1,601:1},Qbt=`NETWORK_SIMPLEX`,vV=`SIMPLE`,yV={106:1,47:1},bV=`org.eclipse.elk.alg.layered.p1cycles`,xV=`org.eclipse.elk.alg.layered.p2layers`,SV={413:1,230:1},$bt={846:1,3:1,4:1},CV=`org.eclipse.elk.alg.layered.p3order`,wV=`org.eclipse.elk.alg.layered.p4nodes`,ext={3:1,4:1,5:1,854:1},TV=1e-5,EV=`org.eclipse.elk.alg.layered.p4nodes.bk`,DV=`org.eclipse.elk.alg.layered.p5edges`,OV=`org.eclipse.elk.alg.layered.p5edges.orthogonal`,kV=`org.eclipse.elk.alg.layered.p5edges.orthogonal.direction`,AV=1e-6,jV=`org.eclipse.elk.alg.layered.p5edges.splines`,MV=.09999999999999998,NV=1e-8,txt=4.71238898038469,PV=3.141592653589793,FV=`org.eclipse.elk.alg.mrtree`,IV=.10000000149011612,LV=`SUPER_ROOT`,RV=`org.eclipse.elk.alg.mrtree.graph`,zV=-17976931348623157e292,BV=`org.eclipse.elk.alg.mrtree.intermediate`,nxt=`Processor compute fanout`,VV={3:1,6:1,4:1,5:1,534:1,100:1,115:1},rxt=`Set neighbors in level`,HV=`org.eclipse.elk.alg.mrtree.options`,ixt=`DESCENDANTS`,UV=`org.eclipse.elk.mrtree.compaction`,WV=`org.eclipse.elk.mrtree.edgeEndTextureLength`,axt=`org.eclipse.elk.mrtree.treeLevel`,oxt=`org.eclipse.elk.mrtree.positionConstraint`,sxt=`org.eclipse.elk.mrtree.weighting`,cxt=`org.eclipse.elk.mrtree.edgeRoutingMode`,lxt=`org.eclipse.elk.mrtree.searchOrder`,uxt=`Position Constraint`,GV=`org.eclipse.elk.mrtree`,dxt=`org.eclipse.elk.tree`,fxt=`Processor arrange level`,KV=`org.eclipse.elk.alg.mrtree.p2order`,qV=`org.eclipse.elk.alg.mrtree.p4route`,pxt=`org.eclipse.elk.alg.radial`,JV=6.283185307179586,mxt=`Before`,hxt=5e-324,YV=`After`,gxt=`org.eclipse.elk.alg.radial.intermediate`,_xt=`COMPACTION`,XV=`org.eclipse.elk.alg.radial.intermediate.compaction`,vxt={3:1,4:1,5:1,100:1},yxt=`org.eclipse.elk.alg.radial.intermediate.optimization`,ZV=`No implementation is available for the layout option `,QV=`org.eclipse.elk.alg.radial.options`,bxt=`org.eclipse.elk.radial.centerOnRoot`,xxt=`org.eclipse.elk.radial.orderId`,Sxt=`org.eclipse.elk.radial.radius`,$V=`org.eclipse.elk.radial.rotate`,eH=`org.eclipse.elk.radial.compactor`,tH=`org.eclipse.elk.radial.compactionStepSize`,Cxt=`org.eclipse.elk.radial.sorter`,wxt=`org.eclipse.elk.radial.wedgeCriteria`,Txt=`org.eclipse.elk.radial.optimizationCriteria`,nH=`org.eclipse.elk.radial.rotation.targetAngle`,rH=`org.eclipse.elk.radial.rotation.computeAdditionalWedgeSpace`,Ext=`org.eclipse.elk.radial.rotation.outgoingEdgeAngles`,Dxt=`Compaction`,Oxt=`rotation`,iH=`org.eclipse.elk.radial`,kxt=`org.eclipse.elk.alg.radial.p1position.wedge`,Axt=`org.eclipse.elk.alg.radial.sorting`,jxt=5.497787143782138,Mxt=3.9269908169872414,Nxt=2.356194490192345,Pxt=`org.eclipse.elk.alg.rectpacking`,aH=`org.eclipse.elk.alg.rectpacking.intermediate`,oH=`org.eclipse.elk.alg.rectpacking.options`,Fxt=`org.eclipse.elk.rectpacking.trybox`,Ixt=`org.eclipse.elk.rectpacking.currentPosition`,Lxt=`org.eclipse.elk.rectpacking.desiredPosition`,Rxt=`org.eclipse.elk.rectpacking.inNewRow`,zxt=`org.eclipse.elk.rectpacking.widthApproximation.strategy`,Bxt=`org.eclipse.elk.rectpacking.widthApproximation.targetWidth`,Vxt=`org.eclipse.elk.rectpacking.widthApproximation.optimizationGoal`,Hxt=`org.eclipse.elk.rectpacking.widthApproximation.lastPlaceShift`,Uxt=`org.eclipse.elk.rectpacking.packing.strategy`,Wxt=`org.eclipse.elk.rectpacking.packing.compaction.rowHeightReevaluation`,Gxt=`org.eclipse.elk.rectpacking.packing.compaction.iterations`,Kxt=`org.eclipse.elk.rectpacking.whiteSpaceElimination.strategy`,sH=`widthApproximation`,qxt=`Compaction Strategy`,Jxt=`packing.compaction`,cH=`org.eclipse.elk.rectpacking`,lH=`org.eclipse.elk.alg.rectpacking.p1widthapproximation`,uH=`org.eclipse.elk.alg.rectpacking.p2packing`,Yxt=`No Compaction`,Xxt=`org.eclipse.elk.alg.rectpacking.p3whitespaceelimination`,dH=`org.eclipse.elk.alg.rectpacking.util`,fH=`No implementation available for `,pH=`org.eclipse.elk.alg.spore`,mH=`org.eclipse.elk.alg.spore.options`,hH=`org.eclipse.elk.sporeCompaction`,gH=`org.eclipse.elk.underlyingLayoutAlgorithm`,Zxt=`org.eclipse.elk.processingOrder.treeConstruction`,Qxt=`org.eclipse.elk.processingOrder.spanningTreeCostFunction`,_H=`org.eclipse.elk.processingOrder.preferredRoot`,vH=`org.eclipse.elk.processingOrder.rootSelection`,yH=`org.eclipse.elk.structure.structureExtractionStrategy`,$xt=`org.eclipse.elk.compaction.compactionStrategy`,eSt=`org.eclipse.elk.compaction.orthogonal`,tSt=`org.eclipse.elk.overlapRemoval.maxIterations`,nSt=`org.eclipse.elk.overlapRemoval.runScanline`,bH=`processingOrder`,rSt=`overlapRemoval`,xH=`org.eclipse.elk.sporeOverlap`,iSt=`org.eclipse.elk.alg.spore.p1structure`,SH=`org.eclipse.elk.alg.spore.p2processingorder`,CH=`org.eclipse.elk.alg.spore.p3execution`,aSt=`Topdown Layout`,oSt=`Invalid index: `,wH=`org.eclipse.elk.core.alg`,TH={341:1},EH={295:1},sSt=`Make sure its type is registered with the `,cSt=` utility class.`,DH=`true`,OH=`false`,lSt=`Couldn't clone property '`,kH=.05,AH=`org.eclipse.elk.core.options`,uSt=1.2999999523162842,jH=`org.eclipse.elk.box`,dSt=`org.eclipse.elk.expandNodes`,fSt=`org.eclipse.elk.box.packingMode`,pSt=`org.eclipse.elk.algorithm`,mSt=`org.eclipse.elk.resolvedAlgorithm`,hSt=`org.eclipse.elk.bendPoints`,gSt=`org.eclipse.elk.labelManager`,_St=`org.eclipse.elk.scaleFactor`,vSt=`org.eclipse.elk.childAreaWidth`,ySt=`org.eclipse.elk.childAreaHeight`,bSt=`org.eclipse.elk.animate`,xSt=`org.eclipse.elk.animTimeFactor`,SSt=`org.eclipse.elk.layoutAncestors`,CSt=`org.eclipse.elk.maxAnimTime`,wSt=`org.eclipse.elk.minAnimTime`,TSt=`org.eclipse.elk.progressBar`,ESt=`org.eclipse.elk.validateGraph`,DSt=`org.eclipse.elk.validateOptions`,OSt=`org.eclipse.elk.zoomToFit`,kSt=`org.eclipse.elk.font.name`,ASt=`org.eclipse.elk.font.size`,jSt=`org.eclipse.elk.topdown.sizeApproximator`,MSt=`org.eclipse.elk.topdown.scaleCap`,NSt=`org.eclipse.elk.edge.type`,PSt=`partitioning`,FSt=`nodeLabels`,MH=`portAlignment`,NH=`nodeSize`,PH=`port`,ISt=`portLabels`,FH=`topdown`,LSt=`insideSelfLoops`,IH=`org.eclipse.elk.fixed`,LH=`org.eclipse.elk.random`,RSt={3:1,34:1,22:1,347:1},zSt=`port must have a parent node to calculate the port side`,BSt=`The edge needs to have exactly one edge section. Found: `,RH=`org.eclipse.elk.core.util.adapters`,zH=`org.eclipse.emf.ecore`,BH=`org.eclipse.elk.graph`,VSt=`EMapPropertyHolder`,HSt=`ElkBendPoint`,USt=`ElkGraphElement`,WSt=`ElkConnectableShape`,GSt=`ElkEdge`,KSt=`ElkEdgeSection`,qSt=`EModelElement`,JSt=`ENamedElement`,YSt=`ElkLabel`,XSt=`ElkNode`,ZSt=`ElkPort`,QSt={94:1,93:1},VH=`org.eclipse.emf.common.notify.impl`,HH=`The feature '`,UH=`' is not a valid changeable feature`,$St=`Expecting null`,WH=`' is not a valid feature`,eCt=`The feature ID`,tCt=` is not a valid feature ID`,GH=32768,nCt={110:1,94:1,93:1,58:1,54:1,99:1},KH=`org.eclipse.emf.ecore.impl`,qH=`org.eclipse.elk.graph.impl`,JH=`Recursive containment not allowed for `,YH=`The datatype '`,XH=`' is not a valid classifier`,ZH=`The value '`,QH={195:1,3:1,4:1},$H=`The class '`,eU=`http://www.eclipse.org/elk/ElkGraph`,rCt=`property`,tU=`value`,nU=`source`,iCt=`properties`,aCt=`identifier`,rU=`height`,iU=`width`,aU=`parent`,oU=`text`,sU=`children`,oCt=`hierarchical`,sCt=`sources`,cU=`targets`,cCt=`sections`,lU=`bendPoints`,lCt=`outgoingShape`,uCt=`incomingShape`,dCt=`outgoingSections`,fCt=`incomingSections`,uU=`org.eclipse.emf.common.util`,pCt=`Severe implementation error in the Json to ElkGraph importer.`,dU=`id`,fU=`org.eclipse.elk.graph.json`,mCt=`Unhandled parameter types: `,hCt=`startPoint`,gCt=`An edge must have at least one source and one target (edge id: '`,pU=`').`,_Ct=`Referenced edge section does not exist: `,vCt=` (edge id: '`,yCt=`target`,bCt=`sourcePoint`,xCt=`targetPoint`,mU=`group`,hU=`name`,SCt=`connectableShape cannot be null`,CCt=`edge cannot be null`,gU=`Passed edge is not 'simple'.`,_U=`org.eclipse.elk.graph.util`,vU=`The 'no duplicates' constraint is violated`,yU=`targetIndex=`,bU=`, size=`,xU=`sourceIndex=`,SU={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1},CU={3:1,4:1,20:1,31:1,56:1,16:1,51:1,15:1,59:1,70:1,66:1,61:1,596:1},wU=`logging`,wCt=`measureExecutionTime`,TCt=`parser.parse.1`,ECt=`parser.parse.2`,TU=`parser.next.1`,EU=`parser.next.2`,DCt=`parser.next.3`,OCt=`parser.next.4`,DU=`parser.factor.1`,kCt=`parser.factor.2`,ACt=`parser.factor.3`,jCt=`parser.factor.4`,MCt=`parser.factor.5`,NCt=`parser.factor.6`,PCt=`parser.atom.1`,FCt=`parser.atom.2`,ICt=`parser.atom.3`,LCt=`parser.atom.4`,OU=`parser.atom.5`,RCt=`parser.cc.1`,kU=`parser.cc.2`,zCt=`parser.cc.3`,BCt=`parser.cc.5`,VCt=`parser.cc.6`,HCt=`parser.cc.7`,AU=`parser.cc.8`,UCt=`parser.ope.1`,WCt=`parser.ope.2`,GCt=`parser.ope.3`,jU=`parser.descape.1`,KCt=`parser.descape.2`,qCt=`parser.descape.3`,JCt=`parser.descape.4`,YCt=`parser.descape.5`,MU=`parser.process.1`,XCt=`parser.quantifier.1`,ZCt=`parser.quantifier.2`,QCt=`parser.quantifier.3`,$Ct=`parser.quantifier.4`,ewt=`parser.quantifier.5`,twt=`org.eclipse.emf.common.notify`,nwt={424:1,686:1},rwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,70:1,61:1},NU={378:1,152:1},PU=`index=`,FU={3:1,4:1,5:1,129:1},iwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,61:1},awt={3:1,6:1,4:1,5:1,198:1},owt={3:1,4:1,5:1,173:1,379:1},swt=`;/?:@&=+$,`,cwt=`invalid authority: `,lwt=`EAnnotation`,uwt=`ETypedElement`,dwt=`EStructuralFeature`,fwt=`EAttribute`,pwt=`EClassifier`,mwt=`EEnumLiteral`,hwt=`EGenericType`,gwt=`EOperation`,_wt=`EParameter`,vwt=`EReference`,ywt=`ETypeParameter`,IU=`org.eclipse.emf.ecore.util`,LU={79:1},bwt={3:1,20:1,16:1,15:1,61:1,597:1,79:1,71:1,97:1},xwt=`org.eclipse.emf.ecore.util.FeatureMap$Entry`,RU=8192,zU=2048,BU=`byte`,VU=`char`,HU=`double`,UU=`float`,WU=`int`,GU=`long`,KU=`short`,Swt=`java.lang.Object`,qU={3:1,4:1,5:1,254:1},Cwt={3:1,4:1,5:1,688:1},wwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,71:1},JU={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,79:1,71:1,97:1},YU=`mixed`,XU=`http:///org/eclipse/emf/ecore/util/ExtendedMetaData`,ZU=`kind`,Twt={3:1,4:1,5:1,689:1},Ewt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,70:1,61:1,79:1,71:1,97:1},QU={20:1,31:1,56:1,16:1,15:1,61:1,71:1},$U={51:1,128:1,287:1},eW={76:1,343:1},tW=`The value of type '`,nW=`' must be of type '`,rW=1352,iW=`http://www.eclipse.org/emf/2002/Ecore`,aW=-32768,oW=`constraints`,sW=`baseType`,Dwt=`getEStructuralFeature`,Owt=`getFeatureID`,cW=`feature`,kwt=`getOperationID`,Awt=`operation`,jwt=`defaultValue`,Mwt=`eTypeParameters`,Nwt=`isInstance`,Pwt=`getEEnumLiteral`,Fwt=`eContainingClass`,lW={57:1},Iwt={3:1,4:1,5:1,124:1},Lwt=`org.eclipse.emf.ecore.resource`,Rwt={94:1,93:1,599:1,2034:1},uW=`org.eclipse.emf.ecore.resource.impl`,zwt=`unspecified`,dW=`simple`,fW=`attribute`,Bwt=`attributeWildcard`,pW=`element`,mW=`elementWildcard`,hW=`collapse`,gW=`itemType`,_W=`namespace`,vW=`##targetNamespace`,yW=`whiteSpace`,Vwt=`wildcards`,bW=`http://www.eclipse.org/emf/2003/XMLType`,xW=`##any`,SW=`uninitialized`,CW=`The multiplicity constraint is violated`,wW=`org.eclipse.emf.ecore.xml.type`,Hwt=`ProcessingInstruction`,Uwt=`SimpleAnyType`,Wwt=`XMLTypeDocumentRoot`,TW=`org.eclipse.emf.ecore.xml.type.impl`,EW=`INF`,Gwt=`processing`,Kwt=`ENTITIES_._base`,qwt=`minLength`,Jwt=`ENTITY`,DW=`NCName`,Ywt=`IDREFS_._base`,Xwt=`integer`,OW=`token`,kW=`pattern`,Zwt=`[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*`,Qwt=`\\i\\c*`,$wt=`[\\i-[:]][\\c-[:]]*`,eTt=`nonPositiveInteger`,AW=`maxInclusive`,tTt=`NMTOKEN`,nTt=`NMTOKENS_._base`,rTt=`nonNegativeInteger`,jW=`minInclusive`,iTt=`normalizedString`,aTt=`unsignedByte`,oTt=`unsignedInt`,sTt=`18446744073709551615`,cTt=`unsignedShort`,lTt=`processingInstruction`,MW=`org.eclipse.emf.ecore.xml.type.internal`,NW=1114111,uTt=`Internal Error: shorthands: \\u`,PW=`xml:isDigit`,FW=`xml:isWord`,IW=`xml:isSpace`,LW=`xml:isNameChar`,RW=`xml:isInitialNameChar`,dTt=`09٠٩۰۹०९০৯੦੯૦૯୦୯௧௯౦౯೦೯൦൯๐๙໐໙༠༩`,fTt=`AZazÀÖØöøıĴľŁňŊžƀǃǍǰǴǵǺȗɐʨʻˁΆΆΈΊΌΌΎΡΣώϐϖϚϚϜϜϞϞϠϠϢϳЁЌЎяёќўҁҐӄӇӈӋӌӐӫӮӵӸӹԱՖՙՙաֆאתװײءغفيٱڷںھۀێېۓەەۥۦअहऽऽक़ॡঅঌএঐওনপরললশহড়ঢ়য়ৡৰৱਅਊਏਐਓਨਪਰਲਲ਼ਵਸ਼ਸਹਖ਼ੜਫ਼ਫ਼ੲੴઅઋઍઍએઑઓનપરલળવહઽઽૠૠଅଌଏଐଓନପରଲଳଶହଽଽଡ଼ଢ଼ୟୡஅஊஎஐஒகஙசஜஜஞடணதநபமவஷஹఅఌఎఐఒనపళవహౠౡಅಌಎಐಒನಪಳವಹೞೞೠೡഅഌഎഐഒനപഹൠൡกฮะะาำเๅກຂຄຄງຈຊຊຍຍດທນຟມຣລລວວສຫອຮະະາຳຽຽເໄཀཇཉཀྵႠჅაჶᄀᄀᄂᄃᄅᄇᄉᄉᄋᄌᄎᄒᄼᄼᄾᄾᅀᅀᅌᅌᅎᅎᅐᅐᅔᅕᅙᅙᅟᅡᅣᅣᅥᅥᅧᅧᅩᅩᅭᅮᅲᅳᅵᅵᆞᆞᆨᆨᆫᆫᆮᆯᆷᆸᆺᆺᆼᇂᇫᇫᇰᇰᇹᇹḀẛẠỹἀἕἘἝἠὅὈὍὐὗὙὙὛὛὝὝὟώᾀᾴᾶᾼιιῂῄῆῌῐΐῖΊῠῬῲῴῶῼΩΩKÅ℮℮ↀↂ〇〇〡〩ぁゔァヺㄅㄬ一龥가힣`,pTt=`Private Use`,zW=`ASSIGNED`,BW=`\0€ÿĀſƀɏɐʯʰ˿̀ͯͰϿЀӿ԰֏֐׿؀ۿ܀ݏހ޿ऀॿঀ৿਀੿઀૿଀୿஀௿ఀ౿ಀ೿ഀൿ඀෿฀๿຀໿ༀ࿿က႟Ⴀჿᄀᇿሀ፿Ꭰ᏿᐀ᙿ ᚟ᚠ᛿ក៿᠀᢯Ḁỿἀ῿ ⁰₟₠⃏⃐⃿℀⅏⅐↏←⇿∀⋿⌀⏿␀␿⑀⑟①⓿─╿▀▟■◿☀⛿✀➿⠀⣿⺀⻿⼀⿟⿰⿿ 〿぀ゟ゠ヿ㄀ㄯ㄰㆏㆐㆟ㆠㆿ㈀㋿㌀㏿㐀䶵一鿿ꀀ꒏꒐꓏가힣豈﫿ffﭏﭐ﷿︠︯︰﹏﹐﹯ﹰ﻾＀￯`,mTt=`UNASSIGNED`,VW={3:1,122:1},hTt=`org.eclipse.emf.ecore.xml.type.util`,HW={3:1,4:1,5:1,381:1},gTt=`org.eclipse.xtext.xbase.lib`,_Tt=`Cannot add elements to a Range`,vTt=`Cannot set elements in a Range`,yTt=`Cannot remove elements from a Range`,bTt=`user.agent`,Q,UW,xTt,STt=-1;r.goog=r.goog||{},r.goog.global=r.goog.global||r,UW={},q(1,null,{},a),Q.Fb=function(e){return vCe(this,e)},Q.Gb=function(){return this.Rm},Q.Hb=function(){return td(this)},Q.Ib=function(){var e;return Ha($w(this))+`@`+(e=US(this)>>>0,e.toString(16))},Q.equals=function(e){return this.Fb(e)},Q.hashCode=function(){return this.Hb()},Q.toString=function(){return this.Ib()};var CTt,wTt,TTt;q(297,1,{297:1,2124:1},vZe),Q.ve=function(e){var t=new vZe;return t.i=4,t.c=e>1?_Re(this,e-1):this,t},Q.we=function(){return Ad(this),this.b},Q.xe=function(){return Ha(this)},Q.ye=function(){return Ad(this),this.k},Q.ze=function(){return!!(this.i&4)},Q.Ae=function(){return!!(this.i&1)},Q.Ib=function(){return yx(this)},Q.i=0;var ETt=1,WW=L(jP,`Object`,1),DTt=L(jP,`Class`,297);q(2096,1,MP),L(NP,`Optional`,2096),q(1191,2096,MP,o),Q.Fb=function(e){return e===this},Q.Hb=function(){return 2040732332},Q.Ib=function(){return`Optional.absent()`},Q.Jb=function(e){return ph(e),fi(),GW};var GW;L(NP,`Absent`,1191),q(636,1,{},Xi),L(NP,`Joiner`,636);var OTt=gp(NP,`Predicate`);q(589,1,{178:1,589:1,3:1,46:1},nde),Q.Mb=function(e){return NZe(this,e)},Q.Lb=function(e){return NZe(this,e)},Q.Fb=function(e){var t;return j(e,589)?(t=P(e,589),lit(this.a,t.a)):!1},Q.Hb=function(){return IZe(this.a)+306654252},Q.Ib=function(){return wet(this.a)},L(NP,`Predicates/AndPredicate`,589),q(419,2096,{419:1,3:1},pn),Q.Fb=function(e){var t;return j(e,419)?(t=P(e,419),NT(this.a,t.a)):!1},Q.Hb=function(){return 1502476572+US(this.a)},Q.Ib=function(){return Gvt+this.a+`)`},Q.Jb=function(e){return new pn(Wg(e.Kb(this.a),`the Function passed to Optional.transform() must not return null.`))},L(NP,`Present`,419),q(204,1,LP),Q.Nb=function(e){Om(this,e)},Q.Qb=function(){fve()},L(RP,`UnmodifiableIterator`,204),q(2076,204,zP),Q.Qb=function(){fve()},Q.Rb=function(e){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(RP,`UnmodifiableListIterator`,2076),q(399,2076,zP),Q.Ob=function(){return this.c0},Q.Pb=function(){if(this.c>=this.d)throw E(new Hr);return this.Xb(this.c++)},Q.Tb=function(){return this.c},Q.Ub=function(){if(this.c<=0)throw E(new Hr);return this.Xb(--this.c)},Q.Vb=function(){return this.c-1},Q.c=0,Q.d=0,L(RP,`AbstractIndexedListIterator`,399),q(713,204,LP),Q.Ob=function(){return DS(this)},Q.Pb=function(){return Ob(this)},Q.e=1,L(RP,`AbstractIterator`,713),q(2084,1,{229:1}),Q.Zb=function(){var e;return e=this.f,e||(this.f=this.ac())},Q.Fb=function(e){return Rw(this,e)},Q.Hb=function(){return US(this.Zb())},Q.dc=function(){return this.gc()==0},Q.ec=function(){return rm(this)},Q.Ib=function(){return PE(this.Zb())},L(RP,`AbstractMultimap`,2084),q(742,2084,BP),Q.$b=function(){gS(this)},Q._b=function(e){return aye(this,e)},Q.ac=function(){return new io(this,this.c)},Q.ic=function(e){return this.hc()},Q.bc=function(){return new zu(this,this.c)},Q.jc=function(){return this.mc(this.hc())},Q.kc=function(){return new j_e(this)},Q.lc=function(){return pA(this.c.vc().Nc(),new c,64,this.d)},Q.cc=function(e){return Dy(this,e)},Q.fc=function(e){return sT(this,e)},Q.gc=function(){return this.d},Q.mc=function(e){return Vg(),new Wn(e)},Q.nc=function(){return new A_e(this)},Q.oc=function(){return pA(this.c.Cc().Nc(),new s,64,this.d)},Q.pc=function(e,t){return new Ry(this,e,t,null)},Q.d=0,L(RP,`AbstractMapBasedMultimap`,742),q(1696,742,BP),Q.hc=function(){return new Hy(this.a)},Q.jc=function(){return Vg(),Vg(),QG},Q.cc=function(e){return P(Dy(this,e),15)},Q.fc=function(e){return P(sT(this,e),15)},Q.Zb=function(){return Rg(this)},Q.Fb=function(e){return Rw(this,e)},Q.qc=function(e){return P(Dy(this,e),15)},Q.rc=function(e){return P(sT(this,e),15)},Q.mc=function(e){return Zg(P(e,15))},Q.pc=function(e,t){return nVe(this,e,P(t,15),null)},L(RP,`AbstractListMultimap`,1696),q(748,1,VP),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.c.Ob()||this.e.Ob()},Q.Pb=function(){var e;return this.e.Ob()||(e=P(this.c.Pb(),44),this.b=e.ld(),this.a=P(e.md(),16),this.e=this.a.Kc()),this.sc(this.b,this.e.Pb())},Q.Qb=function(){this.e.Qb(),P(Wh(this.a),16).dc()&&this.c.Qb(),--this.d.d},L(RP,`AbstractMapBasedMultimap/Itr`,748),q(1129,748,VP,A_e),Q.sc=function(e,t){return t},L(RP,`AbstractMapBasedMultimap/1`,1129),q(1130,1,{},s),Q.Kb=function(e){return P(e,16).Nc()},L(RP,`AbstractMapBasedMultimap/1methodref$spliterator$Type`,1130),q(1131,748,VP,j_e),Q.sc=function(e,t){return new oo(e,t)},L(RP,`AbstractMapBasedMultimap/2`,1131);var kTt=gp(HP,`Map`);q(2065,1,UP),Q.wc=function(e){xC(this,e)},Q.yc=function(e,t,n){return AE(this,e,t,n)},Q.$b=function(){this.vc().$b()},Q.tc=function(e){return lk(this,e)},Q._b=function(e){return!!O5e(this,e,!1)},Q.uc=function(e){var t,n,r;for(n=this.vc().Kc();n.Ob();)if(t=P(n.Pb(),44),r=t.md(),A(e)===A(r)||e!=null&&NT(e,r))return!0;return!1},Q.Fb=function(e){var t,n,r;if(e===this)return!0;if(!j(e,85)||(r=P(e,85),this.gc()!=r.gc()))return!1;for(n=r.vc().Kc();n.Ob();)if(t=P(n.Pb(),44),!this.tc(t))return!1;return!0},Q.xc=function(e){return nl(O5e(this,e,!1))},Q.Hb=function(){return QXe(this.vc())},Q.dc=function(){return this.gc()==0},Q.ec=function(){return new Pn(this)},Q.zc=function(e,t){throw E(new Ri(`Put not supported on this map`))},Q.Ac=function(e){mC(this,e)},Q.Bc=function(e){return nl(O5e(this,e,!0))},Q.gc=function(){return this.vc().gc()},Q.Ib=function(){return V5e(this)},Q.Cc=function(){return new Bn(this)},L(HP,`AbstractMap`,2065),q(2085,2065,UP),Q.bc=function(){return new co(this)},Q.vc=function(){return PNe(this)},Q.ec=function(){return this.g||=this.bc()},Q.Cc=function(){return this.i||=new sbe(this)},L(RP,`Maps/ViewCachingAbstractMap`,2085),q(402,2085,UP,io),Q.xc=function(e){return QKe(this,e)},Q.Bc=function(e){return CQe(this,e)},Q.$b=function(){this.d==this.e.c?this.e.$b():Cp(new Tp(this))},Q._b=function(e){return E$e(this.d,e)},Q.Ec=function(){return new rde(this)},Q.Dc=function(){return this.Ec()},Q.Fb=function(e){return this===e||NT(this.d,e)},Q.Hb=function(){return US(this.d)},Q.ec=function(){return this.e.ec()},Q.gc=function(){return this.d.gc()},Q.Ib=function(){return PE(this.d)},L(RP,`AbstractMapBasedMultimap/AsMap`,402);var KW=gp(jP,`Iterable`);q(31,1,WP),Q.Jc=function(e){ly(this,e)},Q.Lc=function(){return this.Oc()},Q.Nc=function(){return new cv(this,0)},Q.Oc=function(){return new Mp(null,this.Nc())},Q.Fc=function(e){throw E(new Ri(`Add not supported on this collection`))},Q.Gc=function(e){return XS(this,e)},Q.$b=function(){yg(this)},Q.Hc=function(e){return QE(this,e,!1)},Q.Ic=function(e){return $C(this,e)},Q.dc=function(){return this.gc()==0},Q.Mc=function(e){return QE(this,e,!0)},Q.Pc=function(){return INe(this)},Q.Qc=function(e){return ck(this,e)},Q.Ib=function(){return CA(this)},L(HP,`AbstractCollection`,31);var qW=gp(HP,`Set`);q(GP,31,KP),Q.Nc=function(){return new cv(this,1)},Q.Fb=function(e){return $0e(this,e)},Q.Hb=function(){return QXe(this)},L(HP,`AbstractSet`,GP),q(2068,GP,KP),L(RP,`Sets/ImprovedAbstractSet`,2068),q(2069,2068,KP),Q.$b=function(){this.Rc().$b()},Q.Hc=function(e){return x0e(this,e)},Q.dc=function(){return this.Rc().dc()},Q.Mc=function(e){var t;return this.Hc(e)&&j(e,44)?(t=P(e,44),this.Rc().ec().Mc(t.ld())):!1},Q.gc=function(){return this.Rc().gc()},L(RP,`Maps/EntrySet`,2069),q(1127,2069,KP,rde),Q.Hc=function(e){return wT(this.a.d.vc(),e)},Q.Kc=function(){return new Tp(this.a)},Q.Rc=function(){return this.a},Q.Mc=function(e){var t;return wT(this.a.d.vc(),e)?(t=P(Wh(P(e,44)),44),AUe(this.a.e,t.ld()),!0):!1},Q.Nc=function(){return qf(this.a.d.vc().Nc(),new ide(this.a))},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapEntries`,1127),q(1128,1,{},ide),Q.Kb=function(e){return SUe(this.a,P(e,44))},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapEntries/0methodref$wrapEntry$Type`,1128),q(746,1,VP,Tp),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){var e;return e=P(this.b.Pb(),44),this.a=P(e.md(),16),SUe(this.c,e)},Q.Ob=function(){return this.b.Ob()},Q.Qb=function(){Ef(!!this.a),this.b.Qb(),this.c.e.d-=this.a.gc(),this.a.$b(),this.a=null},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapIterator`,746),q(542,2068,KP,co),Q.$b=function(){this.b.$b()},Q.Hc=function(e){return this.b._b(e)},Q.Jc=function(e){ph(e),this.b.wc(new xde(e))},Q.dc=function(){return this.b.dc()},Q.Kc=function(){return new hi(this.b.vc().Kc())},Q.Mc=function(e){return this.b._b(e)?(this.b.Bc(e),!0):!1},Q.gc=function(){return this.b.gc()},L(RP,`Maps/KeySet`,542),q(327,542,KP,zu),Q.$b=function(){var e;Cp((e=this.b.vc().Kc(),new Jye(this,e)))},Q.Ic=function(e){return this.b.ec().Ic(e)},Q.Fb=function(e){return this===e||NT(this.b.ec(),e)},Q.Hb=function(){return US(this.b.ec())},Q.Kc=function(){var e;return e=this.b.vc().Kc(),new Jye(this,e)},Q.Mc=function(e){var t,n=0;return t=P(this.b.Bc(e),16),t&&(n=t.gc(),t.$b(),this.a.d-=n),n>0},Q.Nc=function(){return this.b.ec().Nc()},L(RP,`AbstractMapBasedMultimap/KeySet`,327),q(747,1,VP,Jye),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.c.Ob()},Q.Pb=function(){return this.a=P(this.c.Pb(),44),this.a.ld()},Q.Qb=function(){var e;Ef(!!this.a),e=P(this.a.md(),16),this.c.Qb(),this.b.a.d-=e.gc(),e.$b(),this.a=null},L(RP,`AbstractMapBasedMultimap/KeySet/1`,747),q(503,402,{85:1,133:1},Fd),Q.bc=function(){return this.Sc()},Q.ec=function(){return this.Uc()},Q.Sc=function(){return new no(this.c,this.Wc())},Q.Tc=function(){return this.Wc().Tc()},Q.Uc=function(){var e;return e=this.b,e||(this.b=this.Sc())},Q.Vc=function(){return this.Wc().Vc()},Q.Wc=function(){return P(this.d,133)},L(RP,`AbstractMapBasedMultimap/SortedAsMap`,503),q(446,503,qP,Id),Q.bc=function(){return new ro(this.a,P(P(this.d,133),139))},Q.Sc=function(){return new ro(this.a,P(P(this.d,133),139))},Q.ec=function(){var e;return e=this.b,P(e||(this.b=new ro(this.a,P(P(this.d,133),139))),277)},Q.Uc=function(){var e;return e=this.b,P(e||(this.b=new ro(this.a,P(P(this.d,133),139))),277)},Q.Wc=function(){return P(P(this.d,133),139)},Q.Xc=function(e){return P(P(this.d,133),139).Xc(e)},Q.Yc=function(e){return P(P(this.d,133),139).Yc(e)},Q.Zc=function(e,t){return new Id(this.a,P(P(this.d,133),139).Zc(e,t))},Q.$c=function(e){return P(P(this.d,133),139).$c(e)},Q._c=function(e){return P(P(this.d,133),139)._c(e)},Q.ad=function(e,t){return new Id(this.a,P(P(this.d,133),139).ad(e,t))},L(RP,`AbstractMapBasedMultimap/NavigableAsMap`,446),q(502,327,Kvt,no),Q.Nc=function(){return this.b.ec().Nc()},L(RP,`AbstractMapBasedMultimap/SortedKeySet`,502),q(401,502,JP,ro),L(RP,`AbstractMapBasedMultimap/NavigableKeySet`,401),q(551,31,WP,Ry),Q.Fc=function(e){var t,n;return RE(this),n=this.d.dc(),t=this.d.Fc(e),t&&(++this.f.d,n&&Jd(this)),t},Q.Gc=function(e){var t,n,r;return!e.dc()&&(r=(RE(this),this.d.gc()),t=this.d.Gc(e),t&&(n=this.d.gc(),this.f.d+=n-r,r==0&&Jd(this)),t)},Q.$b=function(){var e=(RE(this),this.d.gc());e!=0&&(this.d.$b(),this.f.d-=e,Up(this))},Q.Hc=function(e){return RE(this),this.d.Hc(e)},Q.Ic=function(e){return RE(this),this.d.Ic(e)},Q.Fb=function(e){return e===this||(RE(this),NT(this.d,e))},Q.Hb=function(){return RE(this),US(this.d)},Q.Kc=function(){return RE(this),new xje(this)},Q.Mc=function(e){var t;return RE(this),t=this.d.Mc(e),t&&(--this.f.d,Up(this)),t},Q.gc=function(){return tCe(this)},Q.Nc=function(){return RE(this),this.d.Nc()},Q.Ib=function(){return RE(this),PE(this.d)},L(RP,`AbstractMapBasedMultimap/WrappedCollection`,551);var JW=gp(HP,`List`);q(744,551,{20:1,31:1,16:1,15:1},qNe),Q.jd=function(e){zS(this,e)},Q.Nc=function(){return RE(this),this.d.Nc()},Q.bd=function(e,t){var n;RE(this),n=this.d.dc(),P(this.d,15).bd(e,t),++this.a.d,n&&Jd(this)},Q.cd=function(e,t){var n,r,i;return!t.dc()&&(i=(RE(this),this.d.gc()),n=P(this.d,15).cd(e,t),n&&(r=this.d.gc(),this.a.d+=r-i,i==0&&Jd(this)),n)},Q.Xb=function(e){return RE(this),P(this.d,15).Xb(e)},Q.dd=function(e){return RE(this),P(this.d,15).dd(e)},Q.ed=function(){return RE(this),new cwe(this)},Q.fd=function(e){return RE(this),new xIe(this,e)},Q.gd=function(e){var t;return RE(this),t=P(this.d,15).gd(e),--this.a.d,Up(this),t},Q.hd=function(e,t){return RE(this),P(this.d,15).hd(e,t)},Q.kd=function(e,t){return RE(this),nVe(this.a,this.e,P(this.d,15).kd(e,t),this.b?this.b:this)},L(RP,`AbstractMapBasedMultimap/WrappedList`,744),q(1126,744,{20:1,31:1,16:1,15:1,59:1},lEe),L(RP,`AbstractMapBasedMultimap/RandomAccessWrappedList`,1126),q(628,1,VP,xje),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return Ng(this),this.b.Ob()},Q.Pb=function(){return Ng(this),this.b.Pb()},Q.Qb=function(){TTe(this)},L(RP,`AbstractMapBasedMultimap/WrappedCollection/WrappedIterator`,628),q(745,628,YP,cwe,xIe),Q.Qb=function(){TTe(this)},Q.Rb=function(e){var t=tCe(this.a)==0;(Ng(this),P(this.b,128)).Rb(e),++this.a.a.d,t&&Jd(this.a)},Q.Sb=function(){return(Ng(this),P(this.b,128)).Sb()},Q.Tb=function(){return(Ng(this),P(this.b,128)).Tb()},Q.Ub=function(){return(Ng(this),P(this.b,128)).Ub()},Q.Vb=function(){return(Ng(this),P(this.b,128)).Vb()},Q.Wb=function(e){(Ng(this),P(this.b,128)).Wb(e)},L(RP,`AbstractMapBasedMultimap/WrappedList/WrappedListIterator`,745),q(743,551,Kvt,mDe),Q.Nc=function(){return RE(this),this.d.Nc()},L(RP,`AbstractMapBasedMultimap/WrappedSortedSet`,743),q(1125,743,JP,HCe),L(RP,`AbstractMapBasedMultimap/WrappedNavigableSet`,1125),q(1124,551,KP,hDe),Q.Nc=function(){return RE(this),this.d.Nc()},L(RP,`AbstractMapBasedMultimap/WrappedSet`,1124),q(1133,1,{},c),Q.Kb=function(e){return rWe(P(e,44))},L(RP,`AbstractMapBasedMultimap/lambda$1$Type`,1133),q(1132,1,{},cde),Q.Kb=function(e){return new oo(this.a,e)},L(RP,`AbstractMapBasedMultimap/lambda$2$Type`,1132);var YW=gp(HP,`Map/Entry`);q(358,1,XP),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),zh(this.ld(),t.ld())&&zh(this.md(),t.md())):!1},Q.Hb=function(){var e=this.ld(),t=this.md();return(e==null?0:US(e))^(t==null?0:US(t))},Q.nd=function(e){throw E(new Br)},Q.Ib=function(){return this.ld()+`=`+this.md()},L(RP,qvt,358),q(2086,31,WP),Q.$b=function(){this.od().$b()},Q.Hc=function(e){var t;return j(e,44)?(t=P(e,44),bBe(this.od(),t.ld(),t.md())):!1},Q.Mc=function(e){var t;return j(e,44)?(t=P(e,44),xBe(this.od(),t.ld(),t.md())):!1},Q.gc=function(){return this.od().d},L(RP,`Multimaps/Entries`,2086),q(749,2086,WP,mn),Q.Kc=function(){return this.a.kc()},Q.od=function(){return this.a},Q.Nc=function(){return this.a.lc()},L(RP,`AbstractMultimap/Entries`,749),q(750,749,KP,M_e),Q.Nc=function(){return this.a.lc()},Q.Fb=function(e){return eet(this,e)},Q.Hb=function(){return uYe(this)},L(RP,`AbstractMultimap/EntrySet`,750),q(751,31,WP,hn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return dQe(this.a,e)},Q.Kc=function(){return this.a.nc()},Q.gc=function(){return this.a.d},Q.Nc=function(){return this.a.oc()},L(RP,`AbstractMultimap/Values`,751),q(2087,31,{849:1,20:1,31:1,16:1}),Q.Jc=function(e){ph(e),bg(this).Jc(new Dde(e))},Q.Nc=function(){var e;return e=bg(this).Nc(),pA(e,new g,64|e.yd()&1296,this.a.d)},Q.Fc=function(e){return Zi(),!0},Q.Gc=function(e){return ph(this),ph(e),j(e,552)?NBe(P(e,849)):!e.dc()&&rx(this,e.Kc())},Q.Hc=function(e){var t;return t=P(TT(Rg(this.a),e),16),(t?t.gc():0)>0},Q.Fb=function(e){return Nit(this,e)},Q.Hb=function(){return US(bg(this))},Q.dc=function(){return bg(this).dc()},Q.Mc=function(e){return gnt(this,e,1)>0},Q.Ib=function(){return PE(bg(this))},L(RP,`AbstractMultiset`,2087),q(2089,2068,KP),Q.$b=function(){gS(this.a.a)},Q.Hc=function(e){var t,n;return j(e,504)?(n=P(e,425),P(n.a.md(),16).gc()<=0?!1:(t=VRe(this.a,n.a.ld()),t==P(n.a.md(),16).gc())):!1},Q.Mc=function(e){var t,n,r,i;return j(e,504)&&(n=P(e,425),t=n.a.ld(),r=P(n.a.md(),16).gc(),r!=0)?(i=this.a,_nt(i,t,r)):!1},L(RP,`Multisets/EntrySet`,2089),q(1139,2089,KP,lde),Q.Kc=function(){return new H_e(PNe(Rg(this.a.a)).Kc())},Q.gc=function(){return Rg(this.a.a).gc()},L(RP,`AbstractMultiset/EntrySet`,1139),q(627,742,BP),Q.hc=function(){return this.pd()},Q.jc=function(){return this.qd()},Q.cc=function(e){return this.rd(e)},Q.fc=function(e){return this.sd(e)},Q.Zb=function(){var e;return e=this.f,e||(this.f=this.ac())},Q.qd=function(){return Vg(),Vg(),eK},Q.Fb=function(e){return Rw(this,e)},Q.rd=function(e){return P(Dy(this,e),21)},Q.sd=function(e){return P(sT(this,e),21)},Q.mc=function(e){return Vg(),new oa(P(e,21))},Q.pc=function(e,t){return new hDe(this,e,P(t,21))},L(RP,`AbstractSetMultimap`,627),q(1723,627,BP),Q.hc=function(){return new Ja(this.b)},Q.pd=function(){return new Ja(this.b)},Q.jc=function(){return Vh(new Ja(this.b))},Q.qd=function(){return Vh(new Ja(this.b))},Q.cc=function(e){return P(P(Dy(this,e),21),87)},Q.rd=function(e){return P(P(Dy(this,e),21),87)},Q.fc=function(e){return P(P(sT(this,e),21),87)},Q.sd=function(e){return P(P(sT(this,e),21),87)},Q.mc=function(e){return j(e,277)?Vh(P(e,277)):(Vg(),new UTe(P(e,87)))},Q.Zb=function(){var e;return e=this.f,e||(this.f=j(this.c,139)?new Id(this,P(this.c,139)):j(this.c,133)?new Fd(this,P(this.c,133)):new io(this,this.c))},Q.pc=function(e,t){return j(t,277)?new HCe(this,e,P(t,277)):new mDe(this,e,P(t,87))},L(RP,`AbstractSortedSetMultimap`,1723),q(1724,1723,BP),Q.Zb=function(){var e;return e=this.f,P(P(e||(this.f=j(this.c,139)?new Id(this,P(this.c,139)):j(this.c,133)?new Fd(this,P(this.c,133)):new io(this,this.c)),133),139)},Q.ec=function(){var e;return e=this.i,P(P(e||(this.i=j(this.c,139)?new ro(this,P(this.c,139)):j(this.c,133)?new no(this,P(this.c,133)):new zu(this,this.c)),87),277)},Q.bc=function(){return j(this.c,139)?new ro(this,P(this.c,139)):j(this.c,133)?new no(this,P(this.c,133)):new zu(this,this.c)},L(RP,`AbstractSortedKeySortedSetMultimap`,1724),q(2109,1,{2046:1}),Q.Fb=function(e){return O8e(this,e)},Q.Hb=function(){var e;return QXe((e=this.g,e||(this.g=new gn(this))))},Q.Ib=function(){var e;return V5e((e=this.f,e||(this.f=new ETe(this))))},L(RP,`AbstractTable`,2109),q(679,GP,KP,gn),Q.$b=function(){mve()},Q.Hc=function(e){var t,n;return j(e,479)?(t=P(e,697),n=P(TT(JPe(this.a),ul(t.c.e,t.b)),85),!!n&&wT(n.vc(),new oo(ul(t.c.c,t.a),Iy(t.c,t.b,t.a)))):!1},Q.Kc=function(){return UIe(this.a)},Q.Mc=function(e){var t,n;return j(e,479)?(t=P(e,697),n=P(TT(JPe(this.a),ul(t.c.e,t.b)),85),!!n&&D$e(n.vc(),new oo(ul(t.c.c,t.a),Iy(t.c,t.b,t.a)))):!1},Q.gc=function(){return NMe(this.a)},Q.Nc=function(){return WBe(this.a)},L(RP,`AbstractTable/CellSet`,679),q(2025,31,WP,dde),Q.$b=function(){mve()},Q.Hc=function(e){return Z5e(this.a,e)},Q.Kc=function(){return WIe(this.a)},Q.gc=function(){return NMe(this.a)},Q.Nc=function(){return gBe(this.a)},L(RP,`AbstractTable/Values`,2025),q(1697,1696,BP),L(RP,`ArrayListMultimapGwtSerializationDependencies`,1697),q(520,1697,BP,la,URe),Q.hc=function(){return new Hy(this.a)},Q.a=0,L(RP,`ArrayListMultimap`,520),q(678,2109,{678:1,2046:1,3:1},rrt),L(RP,`ArrayTable`,678),q(2021,399,zP,DTe),Q.Xb=function(e){return new yZe(this.a,e)},L(RP,`ArrayTable/1`,2021),q(2022,1,{},ade),Q.td=function(e){return new yZe(this.a,e)},L(RP,`ArrayTable/1methodref$getCell$Type`,2022),q(2110,1,{697:1}),Q.Fb=function(e){var t;return e===this?!0:j(e,479)?(t=P(e,697),zh(ul(this.c.e,this.b),ul(t.c.e,t.b))&&zh(ul(this.c.c,this.a),ul(t.c.c,t.a))&&zh(Iy(this.c,this.b,this.a),Iy(t.c,t.b,t.a))):!1},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[ul(this.c.e,this.b),ul(this.c.c,this.a),Iy(this.c,this.b,this.a)]))},Q.Ib=function(){return`(`+ul(this.c.e,this.b)+`,`+ul(this.c.c,this.a)+`)=`+Iy(this.c,this.b,this.a)},L(RP,`Tables/AbstractCell`,2110),q(479,2110,{479:1,697:1},yZe),Q.a=0,Q.b=0,Q.d=0,L(RP,`ArrayTable/2`,479),q(2024,1,{},ode),Q.td=function(e){return IGe(this.a,e)},L(RP,`ArrayTable/2methodref$getValue$Type`,2024),q(2023,399,zP,OTe),Q.Xb=function(e){return IGe(this.a,e)},L(RP,`ArrayTable/3`,2023),q(2077,2065,UP),Q.$b=function(){Cp(this.kc())},Q.vc=function(){return new bde(this)},Q.lc=function(){return new lIe(this.kc(),this.gc())},L(RP,`Maps/IteratorBasedAbstractMap`,2077),q(842,2077,UP),Q.$b=function(){throw E(new Br)},Q._b=function(e){return oye(this.c,e)},Q.kc=function(){return new kTe(this,this.c.b.c.gc())},Q.lc=function(){return yp(this.c.b.c.gc(),16,new sde(this))},Q.xc=function(e){var t=P(_f(this.c,e),17);return t?this.vd(t.a):null},Q.dc=function(){return this.c.b.c.dc()},Q.ec=function(){return om(this.c)},Q.zc=function(e,t){var n=P(_f(this.c,e),17);if(!n)throw E(new Fi(this.ud()+` `+e+` not in `+om(this.c)));return this.wd(n.a,t)},Q.Bc=function(e){throw E(new Br)},Q.gc=function(){return this.c.b.c.gc()},L(RP,`ArrayTable/ArrayMap`,842),q(2020,1,{},sde),Q.td=function(e){return XPe(this.a,e)},L(RP,`ArrayTable/ArrayMap/0methodref$getEntry$Type`,2020),q(2018,358,XP,Vye),Q.ld=function(){return pEe(this.a,this.b)},Q.md=function(){return this.a.vd(this.b)},Q.nd=function(e){return this.a.wd(this.b,e)},Q.b=0,L(RP,`ArrayTable/ArrayMap/1`,2018),q(2019,399,zP,kTe),Q.Xb=function(e){return XPe(this.a,e)},L(RP,`ArrayTable/ArrayMap/2`,2019),q(2017,842,UP,fPe),Q.ud=function(){return`Column`},Q.vd=function(e){return Iy(this.b,this.a,e)},Q.wd=function(e,t){return JXe(this.b,this.a,e,t)},Q.a=0,L(RP,`ArrayTable/Row`,2017),q(843,842,UP,ETe),Q.vd=function(e){return new fPe(this.a,e)},Q.zc=function(e,t){return P(t,85),hve()},Q.wd=function(e,t){return P(t,85),gve()},Q.ud=function(){return`Row`},L(RP,`ArrayTable/RowMap`,843),q(1157,1,QP,Hye),Q.Ad=function(e){return!!(this.a.yd()&-262&e)},Q.yd=function(){return this.a.yd()&-262},Q.zd=function(){return this.a.zd()},Q.Nb=function(e){this.a.Nb(new Wye(e,this.b))},Q.Bd=function(e){return this.a.Bd(new Uye(e,this.b))},L(RP,`CollectSpliterators/1`,1157),q(1158,1,$P,Uye),Q.Cd=function(e){this.a.Cd(this.b.Kb(e))},L(RP,`CollectSpliterators/1/lambda$0$Type`,1158),q(1159,1,$P,Wye),Q.Cd=function(e){this.a.Cd(this.b.Kb(e))},L(RP,`CollectSpliterators/1/lambda$1$Type`,1159),q(1154,1,QP,BOe),Q.Ad=function(e){return!!((16464|this.b)&e)},Q.yd=function(){return 16464|this.b},Q.zd=function(){return this.a.zd()},Q.Nb=function(e){this.a.Qe(new Kye(e,this.c))},Q.Bd=function(e){return this.a.Re(new Gye(e,this.c))},Q.b=0,L(RP,`CollectSpliterators/1WithCharacteristics`,1154),q(1155,1,eF,Gye),Q.Dd=function(e){this.a.Cd(this.b.td(e))},L(RP,`CollectSpliterators/1WithCharacteristics/lambda$0$Type`,1155),q(1156,1,eF,Kye),Q.Dd=function(e){this.a.Cd(this.b.td(e))},L(RP,`CollectSpliterators/1WithCharacteristics/lambda$1$Type`,1156),q(1150,1,QP),Q.Ad=function(e){return(this.a&e)!=0},Q.yd=function(){return this.a},Q.zd=function(){return this.e&&(this.b=ywe(this.b,this.e.zd())),ywe(this.b,0)},Q.Nb=function(e){this.e&&=(this.e.Nb(e),null),this.c.Nb(new qye(this,e)),this.b=0},Q.Bd=function(e){for(;;){if(this.e&&this.e.Bd(e))return cl(this.b,tF)&&(this.b=xE(this.b,1)),!0;if(this.e=null,!this.c.Bd(new fde(this)))return!1}},Q.a=0,Q.b=0,L(RP,`CollectSpliterators/FlatMapSpliterator`,1150),q(1152,1,$P,fde),Q.Cd=function(e){OOe(this.a,e)},L(RP,`CollectSpliterators/FlatMapSpliterator/lambda$0$Type`,1152),q(1153,1,$P,qye),Q.Cd=function(e){iIe(this.a,this.b,e)},L(RP,`CollectSpliterators/FlatMapSpliterator/lambda$1$Type`,1153),q(1151,1150,QP,$Be),L(RP,`CollectSpliterators/FlatMapSpliteratorOfObject`,1151),q(253,1,nF),Q.Fd=function(e){return this.Ed(P(e,253))},Q.Ed=function(e){var t;return e==(mi(),ZW)?1:e==(pi(),XW)?-1:(t=(ap(),pC(this.a,e.a)),t==0?j(this,526)==j(e,526)?0:j(this,526)?1:-1:t)},Q.Id=function(){return this.a},Q.Fb=function(e){return f3e(this,e)},L(RP,`Cut`,253),q(1823,253,nF,k_e),Q.Ed=function(e){return e==this?0:1},Q.Gd=function(e){throw E(new yge)},Q.Hd=function(e){e.a+=`+∞)`},Q.Id=function(){throw E(new Ii(Yvt))},Q.Hb=function(){return yo(),VD(this)},Q.Jd=function(e){return!1},Q.Ib=function(){return`+∞`};var XW;L(RP,`Cut/AboveAll`,1823),q(526,253,{253:1,526:1,3:1,34:1},BTe),Q.Gd=function(e){hl((e.a+=`(`,e),this.a)},Q.Hd=function(e){jh(hl(e,this.a),93)},Q.Hb=function(){return~US(this.a)},Q.Jd=function(e){return ap(),pC(this.a,e)<0},Q.Ib=function(){return`/`+this.a+`\\`},L(RP,`Cut/AboveValue`,526),q(1822,253,nF,O_e),Q.Ed=function(e){return e==this?0:-1},Q.Gd=function(e){e.a+=`(-∞`},Q.Hd=function(e){throw E(new yge)},Q.Id=function(){throw E(new Ii(Yvt))},Q.Hb=function(){return yo(),VD(this)},Q.Jd=function(e){return!0},Q.Ib=function(){return`-∞`};var ZW;L(RP,`Cut/BelowAll`,1822),q(1824,253,nF,VTe),Q.Gd=function(e){hl((e.a+=`[`,e),this.a)},Q.Hd=function(e){jh(hl(e,this.a),41)},Q.Hb=function(){return US(this.a)},Q.Jd=function(e){return ap(),pC(this.a,e)<=0},Q.Ib=function(){return`\\`+this.a+`/`},L(RP,`Cut/BelowValue`,1824),q(547,1,rF),Q.Jc=function(e){ly(this,e)},Q.Ib=function(){return s1e(P(Wg(this,`use Optional.orNull() instead of Optional.or(null)`),20).Kc())},L(RP,`FluentIterable`,547),q(442,547,rF,Hl),Q.Kc=function(){return new pm(Vu(this.a.Kc(),new d))},L(RP,`FluentIterable/2`,442),q(1059,547,rF,ICe),Q.Kc=function(){return jm(this)},L(RP,`FluentIterable/3`,1059),q(724,399,zP,ATe),Q.Xb=function(e){return this.a[e].Kc()},L(RP,`FluentIterable/3/1`,724),q(2070,1,{}),Q.Ib=function(){return PE(this.Kd().b)},L(RP,`ForwardingObject`,2070),q(2071,2070,Xvt),Q.Kd=function(){return this.Ld()},Q.Jc=function(e){ly(this,e)},Q.Lc=function(){return this.Oc()},Q.Nc=function(){return new cv(this,0)},Q.Oc=function(){return new Mp(null,this.Nc())},Q.Fc=function(e){return this.Ld(),dye()},Q.Gc=function(e){return this.Ld(),fye()},Q.$b=function(){this.Ld(),pye()},Q.Hc=function(e){return this.Ld().Hc(e)},Q.Ic=function(e){return this.Ld().Ic(e)},Q.dc=function(){return this.Ld().b.dc()},Q.Kc=function(){return this.Ld().Kc()},Q.Mc=function(e){return this.Ld(),mye()},Q.gc=function(){return this.Ld().b.gc()},Q.Pc=function(){return this.Ld().Pc()},Q.Qc=function(e){return this.Ld().Qc(e)},L(RP,`ForwardingCollection`,2071),q(2078,31,iF),Q.Kc=function(){return this.Od()},Q.Fc=function(e){throw E(new Br)},Q.Gc=function(e){throw E(new Br)},Q.Md=function(){return this.c||=this.Nd()},Q.$b=function(){throw E(new Br)},Q.Hc=function(e){return e!=null&&QE(this,e,!1)},Q.Nd=function(){switch(this.gc()){case 0:return gh(),gh(),QW;case 1:return gh(),new wp(ph(this.Od().Pb()));default:return new mPe(this,this.Pc())}},Q.Mc=function(e){throw E(new Br)},L(RP,`ImmutableCollection`,2078),q(727,2078,iF,mge),Q.Kc=function(){return hb(this.a.Kc())},Q.Hc=function(e){return e!=null&&this.a.Hc(e)},Q.Ic=function(e){return this.a.Ic(e)},Q.dc=function(){return this.a.dc()},Q.Od=function(){return hb(this.a.Kc())},Q.gc=function(){return this.a.gc()},Q.Pc=function(){return this.a.Pc()},Q.Qc=function(e){return this.a.Qc(e)},Q.Ib=function(){return PE(this.a)},L(RP,`ForwardingImmutableCollection`,727),q(307,2078,aF),Q.Kc=function(){return this.Od()},Q.ed=function(){return this.Pd(0)},Q.fd=function(e){return this.Pd(e)},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.kd=function(e,t){return this.Qd(e,t)},Q.bd=function(e,t){throw E(new Br)},Q.cd=function(e,t){throw E(new Br)},Q.Md=function(){return this},Q.Fb=function(e){return yit(this,e)},Q.Hb=function(){return hXe(this)},Q.dd=function(e){return e==null?-1:o3e(this,e)},Q.Od=function(){return this.Pd(0)},Q.Pd=function(e){return pd(this,e)},Q.gd=function(e){throw E(new Br)},Q.hd=function(e,t){throw E(new Br)},Q.Qd=function(e,t){var n;return bT((n=new abe(this),new $_(n,e,t)))};var QW;L(RP,`ImmutableList`,307),q(2105,307,aF),Q.Kc=function(){return hb(this.Rd().Kc())},Q.kd=function(e,t){return bT(this.Rd().kd(e,t))},Q.Hc=function(e){return e!=null&&this.Rd().Hc(e)},Q.Ic=function(e){return this.Rd().Ic(e)},Q.Fb=function(e){return NT(this.Rd(),e)},Q.Xb=function(e){return ul(this,e)},Q.Hb=function(){return US(this.Rd())},Q.dd=function(e){return this.Rd().dd(e)},Q.dc=function(){return this.Rd().dc()},Q.Od=function(){return hb(this.Rd().Kc())},Q.gc=function(){return this.Rd().gc()},Q.Qd=function(e,t){return bT(this.Rd().kd(e,t))},Q.Pc=function(){return this.Rd().Qc(V(WW,FP,1,this.Rd().gc(),5,1))},Q.Qc=function(e){return this.Rd().Qc(e)},Q.Ib=function(){return PE(this.Rd())},L(RP,`ForwardingImmutableList`,2105),q(729,1,sF),Q.vc=function(){return am(this)},Q.wc=function(e){xC(this,e)},Q.ec=function(){return om(this)},Q.yc=function(e,t,n){return AE(this,e,t,n)},Q.Cc=function(){return this.Vd()},Q.$b=function(){throw E(new Br)},Q._b=function(e){return this.xc(e)!=null},Q.uc=function(e){return this.Vd().Hc(e)},Q.Td=function(){return new hge(this)},Q.Ud=function(){return new gge(this)},Q.Fb=function(e){return mQe(this,e)},Q.Hb=function(){return am(this).Hb()},Q.dc=function(){return this.gc()==0},Q.zc=function(e,t){return pve()},Q.Bc=function(e){throw E(new Br)},Q.Ib=function(){return O9e(this)},Q.Vd=function(){return this.e?this.e:this.e=this.Ud()},Q.c=null,Q.d=null,Q.e=null;var ATt;L(RP,`ImmutableMap`,729),q(730,729,sF),Q._b=function(e){return oye(this,e)},Q.uc=function(e){return fbe(this.b,e)},Q.Sd=function(){return S$e(new ude(this))},Q.Td=function(){return S$e(zFe(this.b))},Q.Ud=function(){return wf(),new mge(RFe(this.b))},Q.Fb=function(e){return pbe(this.b,e)},Q.xc=function(e){return _f(this,e)},Q.Hb=function(){return US(this.b.c)},Q.dc=function(){return this.b.c.dc()},Q.gc=function(){return this.b.c.gc()},Q.Ib=function(){return PE(this.b.c)},L(RP,`ForwardingImmutableMap`,730),q(2072,2071,cF),Q.Kd=function(){return this.Wd()},Q.Ld=function(){return this.Wd()},Q.Nc=function(){return new cv(this,1)},Q.Fb=function(e){return e===this||this.Wd().Fb(e)},Q.Hb=function(){return this.Wd().Hb()},L(RP,`ForwardingSet`,2072),q(1085,2072,cF,ude),Q.Kd=function(){return tg(this.a.b)},Q.Ld=function(){return tg(this.a.b)},Q.Hc=function(e){if(j(e,44)&&P(e,44).ld()==null)return!1;try{return dbe(tg(this.a.b),e)}catch(e){if(e=ew(e),j(e,212))return!1;throw E(e)}},Q.Wd=function(){return tg(this.a.b)},Q.Qc=function(e){var t=iLe(tg(this.a.b),e);return tg(this.a.b).b.gc()=0?`+`:``)+(n/60|0),t=Fl(r.Math.abs(n)%60),(J7e(),$Tt)[this.q.getDay()]+` `+eEt[this.q.getMonth()]+` `+Fl(this.q.getDate())+` `+Fl(this.q.getHours())+`:`+Fl(this.q.getMinutes())+`:`+Fl(this.q.getSeconds())+` GMT`+e+t+` `+this.q.getFullYear()};var fG=L(HP,`Date`,206);q(2015,206,lyt,e8e),Q.a=!1,Q.b=0,Q.c=0,Q.d=0,Q.e=0,Q.f=0,Q.g=!1,Q.i=0,Q.j=0,Q.k=0,Q.n=0,Q.o=0,Q.p=0,L(`com.google.gwt.i18n.shared.impl`,`DateRecord`,2015),q(2064,1,{}),Q.pe=function(){return null},Q.qe=function(){return null},Q.re=function(){return null},Q.se=function(){return null},Q.te=function(){return null},L(ZF,`JSONValue`,2064),q(221,2064,{221:1},Tn,xn),Q.Fb=function(e){return j(e,221)?Oze(this.a,P(e,221).a):!1},Q.oe=function(){return rge},Q.Hb=function(){return $g(this.a)},Q.pe=function(){return this},Q.Ib=function(){var e,t,n=new Gu(`[`);for(t=0,e=this.a.length;t0&&(n.a+=`,`),hl(n,ax(this,t));return n.a+=`]`,n.a},L(ZF,`JSONArray`,221),q(493,2064,{493:1},Sn),Q.oe=function(){return ige},Q.qe=function(){return this},Q.Ib=function(){return rd(),``+this.a},Q.a=!1;var LTt,RTt;L(ZF,`JSONBoolean`,493),q(997,63,SF,U_e),L(ZF,`JSONException`,997),q(1036,2064,{},te),Q.oe=function(){return age},Q.Ib=function(){return IP};var zTt;L(ZF,`JSONNull`,1036),q(263,2064,{263:1},Cn),Q.Fb=function(e){return j(e,263)?this.a==P(e,263).a:!1},Q.oe=function(){return tge},Q.Hb=function(){return jl(this.a)},Q.re=function(){return this},Q.Ib=function(){return this.a+``},Q.a=0,L(ZF,`JSONNumber`,263),q(190,2064,{190:1},bi,wn),Q.Fb=function(e){return j(e,190)?Oze(this.a,P(e,190).a):!1},Q.oe=function(){return nge},Q.Hb=function(){return $g(this.a)},Q.se=function(){return this},Q.Ib=function(){var e,t,n,r,i,a,o=new Gu(`{`);for(e=!0,a=ZS(this,V(LG,X,2,0,6,1)),n=a,r=0,i=n.length;r=0?`:`+this.c:``)+`)`},Q.c=0;var IG=L(jP,`StackTraceElement`,319);TTt={3:1,484:1,34:1,2:1};var LG=L(jP,tyt,2);q(111,427,{484:1},$i,ea,Wu),L(jP,`StringBuffer`,111),q(104,427,{484:1},ta,na,Gu),L(jP,`StringBuilder`,104),q(702,77,oI,ra),L(jP,`StringIndexOutOfBoundsException`,702),q(2145,1,{});var GTt;q(48,63,{3:1,103:1,63:1,82:1,48:1},Br,Ri),L(jP,`UnsupportedOperationException`,48),q(247,242,{3:1,34:1,242:1,247:1},HT,xye),Q.Fd=function(e){return Vdt(this,P(e,247))},Q.ue=function(){return OA(Rpt(this))},Q.Fb=function(e){var t;return this===e?!0:j(e,247)?(t=P(e,247),this.e==t.e&&Vdt(this,t)==0):!1},Q.Hb=function(){var e;return this.b==0?this.a<54?(e=LC(this.f),this.b=nm(uv(e,-1)),this.b=33*this.b+nm(uv(lm(e,32),-1)),this.b=17*this.b+C_(this.e),this.b):(this.b=17*i$e(this.c)+C_(this.e),this.b):this.b},Q.Ib=function(){return Rpt(this)},Q.a=0,Q.b=0,Q.d=0,Q.e=0,Q.f=0;var KTt,RG,zG,BG,VG,HG,UG,qTt,WG=L(`java.math`,`BigDecimal`,247);q(92,242,{3:1,34:1,242:1,92:1},Xv,Ize,Bm,c2e,ru),Q.Fd=function(e){return q0e(this,P(e,92))},Q.ue=function(){return OA(pP(this,0))},Q.Fb=function(e){return WE(this,e)},Q.Hb=function(){return i$e(this)},Q.Ib=function(){return pP(this,0)},Q.b=-2,Q.c=0,Q.d=0,Q.e=0;var JTt,GG,YTt,KG,qG,JG,YG=L(`java.math`,`BigInteger`,92),XTt,ZTt,XG,ZG;q(498,2065,UP),Q.$b=function(){Pm(this)},Q._b=function(e){return km(this,e)},Q.uc=function(e){return hQe(this,e,this.i)||hQe(this,e,this.f)},Q.vc=function(){return new Fn(this)},Q.xc=function(e){return xh(this,e)},Q.zc=function(e,t){return Qh(this,e,t)},Q.Bc=function(e){return My(this,e)},Q.gc=function(){return ho(this)},Q.g=0,L(HP,`AbstractHashMap`,498),q(267,GP,KP,Fn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return PBe(this,e)},Q.Kc=function(){return new EC(this.a)},Q.Mc=function(e){var t;return PBe(this,e)?(t=P(e,44).ld(),this.a.Bc(t),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractHashMap/EntrySet`,267),q(268,1,VP,EC),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return MS(this)},Q.Ob=function(){return this.b},Q.Qb=function(){aKe(this)},Q.b=!1,Q.d=0,L(HP,`AbstractHashMap/EntrySetIterator`,268),q(426,1,VP,qn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return ts(this)},Q.Pb=function(){return Pg(this)},Q.Qb=function(){Fh(this)},Q.b=0,Q.c=-1,L(HP,`AbstractList/IteratorImpl`,426),q(98,426,YP,bv),Q.Qb=function(){Fh(this)},Q.Rb=function(e){qd(this,e)},Q.Sb=function(){return this.b>0},Q.Tb=function(){return this.b},Q.Ub=function(){return jd(this.b>0),this.a.Xb(this.c=--this.b)},Q.Vb=function(){return this.b-1},Q.Wb=function(e){Md(this.c!=-1),this.a.hd(this.c,e)},L(HP,`AbstractList/ListIteratorImpl`,98),q(244,56,gF,$_),Q.bd=function(e,t){av(e,this.b),this.c.bd(this.a+e,t),++this.b},Q.Xb=function(e){return ov(e,this.b),this.c.Xb(this.a+e)},Q.gd=function(e){var t;return ov(e,this.b),t=this.c.gd(this.a+e),--this.b,t},Q.hd=function(e,t){return ov(e,this.b),this.c.hd(this.a+e,t)},Q.gc=function(){return this.b},Q.a=0,Q.b=0,L(HP,`AbstractList/SubList`,244),q(266,GP,KP,Pn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a._b(e)},Q.Kc=function(){var e;return e=this.a.vc().Kc(),new zn(e)},Q.Mc=function(e){return this.a._b(e)?(this.a.Bc(e),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractMap/1`,266),q(541,1,VP,zn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a.Ob()},Q.Pb=function(){var e;return e=P(this.a.Pb(),44),e.ld()},Q.Qb=function(){this.a.Qb()},L(HP,`AbstractMap/1/1`,541),q(231,31,WP,Bn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a.uc(e)},Q.Kc=function(){var e;return e=this.a.vc().Kc(),new Vn(e)},Q.gc=function(){return this.a.gc()},L(HP,`AbstractMap/2`,231),q(301,1,VP,Vn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a.Ob()},Q.Pb=function(){var e;return e=P(this.a.Pb(),44),e.md()},Q.Qb=function(){this.a.Qb()},L(HP,`AbstractMap/2/1`,301),q(494,1,{494:1,44:1}),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),rg(this.d,t.ld())&&rg(this.e,t.md())):!1},Q.ld=function(){return this.d},Q.md=function(){return this.e},Q.Hb=function(){return cu(this.d)^cu(this.e)},Q.nd=function(e){return zDe(this,e)},Q.Ib=function(){return this.d+`=`+this.e},L(HP,`AbstractMap/AbstractEntry`,494),q(397,494,{494:1,397:1,44:1},ds),L(HP,`AbstractMap/SimpleEntry`,397),q(2082,1,yI),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),rg(this.ld(),t.ld())&&rg(this.md(),t.md())):!1},Q.Hb=function(){return cu(this.ld())^cu(this.md())},Q.Ib=function(){return this.ld()+`=`+this.md()},L(HP,qvt,2082),q(2090,2065,qP),Q.Xc=function(e){return Va(this.Ee(e))},Q.tc=function(e){return xUe(this,e)},Q._b=function(e){return BDe(this,e)},Q.vc=function(){return new Hn(this)},Q.Tc=function(){return _Pe(this.Ge())},Q.Yc=function(e){return Va(this.He(e))},Q.xc=function(e){var t=e;return nl(this.Fe(t))},Q.$c=function(e){return Va(this.Ie(e))},Q.ec=function(){return new Efe(this)},Q.Vc=function(){return _Pe(this.Je())},Q._c=function(e){return Va(this.Ke(e))},L(HP,`AbstractNavigableMap`,2090),q(629,GP,KP,Hn),Q.Hc=function(e){return j(e,44)&&xUe(this.b,P(e,44))},Q.Kc=function(){return this.b.De()},Q.Mc=function(e){var t;return j(e,44)?(t=P(e,44),this.b.Le(t)):!1},Q.gc=function(){return this.b.gc()},L(HP,`AbstractNavigableMap/EntrySet`,629),q(1146,GP,JP,Efe),Q.Nc=function(){return new cs(this)},Q.$b=function(){this.a.$b()},Q.Hc=function(e){return BDe(this.a,e)},Q.Kc=function(){return new Dfe(this.a.vc().b.De())},Q.Mc=function(e){return BDe(this.a,e)?(this.a.Bc(e),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractNavigableMap/NavigableKeySet`,1146),q(1147,1,VP,Dfe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return ts(this.a.a)},Q.Pb=function(){return yEe(this.a).ld()},Q.Qb=function(){tke(this.a)},L(HP,`AbstractNavigableMap/NavigableKeySet/1`,1147),q(2103,31,WP),Q.Fc=function(e){return ep(gA(this,e),bI),!0},Q.Gc=function(e){return Gh(e),$f(e!=this,`Can't add a queue to itself`),XS(this,e)},Q.$b=function(){for(;sx(this)!=null;);},L(HP,`AbstractQueue`,2103),q(310,31,{4:1,20:1,31:1,16:1},Iu,EBe),Q.Fc=function(e){return iVe(this,e),!0},Q.$b=function(){uHe(this)},Q.Hc=function(e){return IXe(new fg(this),e)},Q.dc=function(){return qi(this)},Q.Kc=function(){return new fg(this)},Q.Mc=function(e){return nRe(new fg(this),e)},Q.gc=function(){return this.c-this.b&this.a.length-1},Q.Nc=function(){return new cv(this,272)},Q.Qc=function(e){var t=this.c-this.b&this.a.length-1;return e.lengtht&&Sh(e,t,null),e},Q.b=0,Q.c=0,L(HP,`ArrayDeque`,310),q(459,1,VP,fg),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a!=this.b},Q.Pb=function(){return cT(this)},Q.Qb=function(){oJe(this)},Q.a=0,Q.b=0,Q.c=-1,L(HP,`ArrayDeque/IteratorImpl`,459),q(13,56,fyt,T,Hy,bf),Q.bd=function(e,t){Jp(this,e,t)},Q.Fc=function(e){return M(this,e)},Q.cd=function(e,t){return FQe(this,e,t)},Q.Gc=function(e){return nw(this,e)},Q.$b=function(){Wr(this.c,0)},Q.Hc=function(e){return Ab(this,e,0)!=-1},Q.Jc=function(e){Dx(this,e)},Q.Xb=function(e){return Ep(this,e)},Q.dd=function(e){return Ab(this,e,0)},Q.dc=function(){return this.c.length==0},Q.Kc=function(){return new w(this)},Q.gd=function(e){return Ay(this,e)},Q.Mc=function(e){return Db(this,e)},Q.ce=function(e,t){HRe(this,e,t)},Q.hd=function(e,t){return uy(this,e,t)},Q.gc=function(){return this.c.length},Q.jd=function(e){hu(this,e)},Q.Pc=function(){return cp(this.c)},Q.Qc=function(e){return rO(this,e)};var QTt=L(HP,`ArrayList`,13);q(7,1,VP,w),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return gu(this)},Q.Pb=function(){return z(this)},Q.Qb=function(){Gm(this)},Q.a=0,Q.b=-1,L(HP,`ArrayList/1`,7),q(2112,r.Function,{},ie),Q.Me=function(e,t){return aE(e,t)},q(151,56,pyt,Wi),Q.Hc=function(e){return cJe(this,e)!=-1},Q.Jc=function(e){var t,n,r,i;for(Gh(e),n=this.a,r=0,i=n.length;r0)throw E(new Fi(NI+e+` greater than `+this.e));return this.f.Te()?zLe(this.c,this.b,this.a,e,t):WRe(this.c,e,t)},Q.zc=function(e,t){if(!Tk(this.c,this.f,e,this.b,this.a,this.e,this.d))throw E(new Fi(e+` outside the range `+this.b+` to `+this.e));return TZe(this.c,e,t)},Q.Bc=function(e){var t=e;return Tk(this.c,this.f,t,this.b,this.a,this.e,this.d)?VLe(this.c,t):null},Q.Le=function(e){return Lh(this,e.ld())&&KWe(this.c,e)},Q.gc=function(){var e,t=this.f.Te()?this.a?DD(this.c,this.b,!0):DD(this.c,this.b,!1):RGe(this.c),n;if(!(t&&Lh(this,t.d)&&t))return 0;for(e=0,n=new rC(this.c,this.f,this.b,this.a,this.e,this.d);ts(n.a);n.b=P(Pg(n.a),44))++e;return e},Q.ad=function(e,t){if(this.f.Te()&&this.c.a.Ne(e,this.b)<0)throw E(new Fi(NI+e+gyt+this.b));return this.f.Ue()?zLe(this.c,e,t,this.e,this.d):GRe(this.c,e,t)},Q.a=!1,Q.d=!1,L(HP,`TreeMap/SubMap`,631),q(304,22,PI,ls),Q.Te=function(){return!1},Q.Ue=function(){return!1};var uK,dK,fK,pK,mK=aS(HP,`TreeMap/SubMapType`,304,eG,dVe,ike);q(1143,304,PI,WCe),Q.Ue=function(){return!0},aS(HP,`TreeMap/SubMapType/1`,1143,mK,null,null),q(1144,304,PI,Owe),Q.Te=function(){return!0},Q.Ue=function(){return!0},aS(HP,`TreeMap/SubMapType/2`,1144,mK,null,null),q(1145,304,PI,UCe),Q.Te=function(){return!0},aS(HP,`TreeMap/SubMapType/3`,1145,mK,null,null);var dEt;q(157,GP,{3:1,20:1,31:1,16:1,277:1,21:1,87:1,157:1},Nge,Ja,nr),Q.Nc=function(){return new cs(this)},Q.Fc=function(e){return Rm(this,e)},Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a._b(e)},Q.Kc=function(){return this.a.ec().Kc()},Q.Mc=function(e){return Du(this,e)},Q.gc=function(){return this.a.gc()};var fEt=L(HP,`TreeSet`,157);q(1082,1,{},jfe),Q.Ve=function(e,t){return xDe(this.a,e,t)},L(FI,`BinaryOperator/lambda$0$Type`,1082),q(1083,1,{},Mfe),Q.Ve=function(e,t){return SDe(this.a,e,t)},L(FI,`BinaryOperator/lambda$1$Type`,1083),q(952,1,{},ye),Q.Kb=function(e){return e},L(FI,`Function/lambda$0$Type`,952),q(395,1,vF,rr),Q.Mb=function(e){return!this.a.Mb(e)},L(FI,`Predicate/lambda$2$Type`,395),q(581,1,{581:1});var pEt=L(II,`Handler`,581);q(2107,1,MP),Q.xe=function(){return`DUMMY`},Q.Ib=function(){return this.xe()};var hK;L(II,`Level`,2107),q(1706,2107,MP,be),Q.xe=function(){return`INFO`},L(II,`Level/LevelInfo`,1706),q(1843,1,{},Mge);var gK;L(II,`LogManager`,1843),q(1896,1,MP,eke),Q.b=null,L(II,`LogRecord`,1896),q(525,1,{525:1},py),Q.e=!1;var mEt=!1,hEt=!1,_K=!1,gEt=!1,_Et=!1;L(II,`Logger`,525),q(835,581,{581:1},xe),L(II,`SimpleConsoleLogHandler`,835),q(108,22,{3:1,34:1,22:1,108:1},us);var vK,yK,bK,xK=aS(RI,`Collector/Characteristics`,108,eG,KRe,ake),vEt;q(758,1,{},Vm),L(RI,`CollectorImpl`,758),q(1074,1,{},Se),Q.Ve=function(e,t){return M$e(P(e,213),P(t,213))},L(RI,`Collectors/10methodref$merge$Type`,1074),q(1075,1,{},Ce),Q.Kb=function(e){return DBe(P(e,213))},L(RI,`Collectors/11methodref$toString$Type`,1075),q(1076,1,{},Nfe),Q.Kb=function(e){return rd(),!!Al(e)},L(RI,`Collectors/12methodref$test$Type`,1076),q(144,1,{},we),Q.Yd=function(e,t){P(e,16).Fc(t)},L(RI,`Collectors/20methodref$add$Type`,144),q(146,1,{},Te),Q.Xe=function(){return new T},L(RI,`Collectors/21methodref$ctor$Type`,146),q(359,1,{},Ee),Q.Xe=function(){return new Jr},L(RI,`Collectors/23methodref$ctor$Type`,359),q(360,1,{},De),Q.Yd=function(e,t){Lm(P(e,49),t)},L(RI,`Collectors/24methodref$add$Type`,360),q(1069,1,{},Oe),Q.Ve=function(e,t){return wbe(P(e,15),P(t,16))},L(RI,`Collectors/4methodref$addAll$Type`,1069),q(1073,1,{},ke),Q.Yd=function(e,t){jy(P(e,213),P(t,484))},L(RI,`Collectors/9methodref$add$Type`,1073),q(1072,1,{},jje),Q.Xe=function(){return new UC(this.a,this.b,this.c)},L(RI,`Collectors/lambda$15$Type`,1072),q(1077,1,{},Ae),Q.Xe=function(){var e;return e=new ry,oO(e,(rd(),!1),new T),oO(e,!0,new T),e},L(RI,`Collectors/lambda$22$Type`,1077),q(1078,1,{},Pfe),Q.Xe=function(){return U(O(WW,1),FP,1,5,[this.a])},L(RI,`Collectors/lambda$25$Type`,1078),q(1079,1,{},Ffe),Q.Yd=function(e,t){HMe(this.a,rS(e))},L(RI,`Collectors/lambda$26$Type`,1079),q(1080,1,{},Ife),Q.Ve=function(e,t){return oPe(this.a,rS(e),rS(t))},L(RI,`Collectors/lambda$27$Type`,1080),q(1081,1,{},je),Q.Kb=function(e){return rS(e)[0]},L(RI,`Collectors/lambda$28$Type`,1081),q(728,1,{},Me),Q.Ve=function(e,t){return Op(e,t)},L(RI,`Collectors/lambda$4$Type`,728),q(145,1,{},Ne),Q.Ve=function(e,t){return bbe(P(e,16),P(t,16))},L(RI,`Collectors/lambda$42$Type`,145),q(361,1,{},Pe),Q.Ve=function(e,t){return xbe(P(e,49),P(t,49))},L(RI,`Collectors/lambda$50$Type`,361),q(362,1,{},Fe),Q.Kb=function(e){return P(e,49)},L(RI,`Collectors/lambda$51$Type`,362),q(1068,1,{},Lfe),Q.Yd=function(e,t){YZe(this.a,P(e,85),t)},L(RI,`Collectors/lambda$7$Type`,1068),q(1070,1,{},Ie),Q.Ve=function(e,t){return RXe(P(e,85),P(t,85),new Oe)},L(RI,`Collectors/lambda$8$Type`,1070),q(1071,1,{},Rfe),Q.Kb=function(e){return T1e(this.a,P(e,85))},L(RI,`Collectors/lambda$9$Type`,1071),q(550,1,{}),Q.$e=function(){Uh(this)},Q.d=!1,L(RI,`TerminatableStream`,550),q(827,550,zI,fDe),Q.$e=function(){Uh(this)},L(RI,`DoubleStreamImpl`,827),q(1847,736,QP,Mje),Q.Re=function(e){return B4e(this,P(e,189))},Q.a=null,L(RI,`DoubleStreamImpl/2`,1847),q(1848,1,SI,zfe),Q.Pe=function(e){YCe(this.a,e)},L(RI,`DoubleStreamImpl/2/lambda$0$Type`,1848),q(1845,1,SI,Bfe),Q.Pe=function(e){JCe(this.a,e)},L(RI,`DoubleStreamImpl/lambda$0$Type`,1845),q(1846,1,SI,Vfe),Q.Pe=function(e){v0e(this.a,e)},L(RI,`DoubleStreamImpl/lambda$2$Type`,1846),q(1397,735,QP,tUe),Q.Re=function(e){return zBe(this,P(e,202))},Q.a=0,Q.b=0,Q.c=0,L(RI,`IntStream/5`,1397),q(806,550,zI,pDe),Q.$e=function(){Uh(this)},Q._e=function(){return Hh(this),this.a},L(RI,`IntStreamImpl`,806),q(807,550,zI,_be),Q.$e=function(){Uh(this)},Q._e=function(){return Hh(this),bTe(),lEt},L(RI,`IntStreamImpl/Empty`,807),q(1687,1,eF,Hfe),Q.Dd=function(e){QYe(this.a,e)},L(RI,`IntStreamImpl/lambda$4$Type`,1687);var yEt=gp(RI,`Stream`);q(26,550,{533:1,687:1,848:1},Mp),Q.$e=function(){Uh(this)};var SK;L(RI,`StreamImpl`,26),q(1102,500,QP,zOe),Q.Bd=function(e){for(;yGe(this);)if(this.a.Bd(e))return!0;else Uh(this.b),this.b=null,this.a=null;return!1},L(RI,`StreamImpl/1`,1102),q(1103,1,$P,Ufe),Q.Cd=function(e){Lje(this.a,P(e,848))},L(RI,`StreamImpl/1/lambda$0$Type`,1103),q(1104,1,vF,Wfe),Q.Mb=function(e){return Lm(this.a,e)},L(RI,`StreamImpl/1methodref$add$Type`,1104),q(1105,500,QP,DIe),Q.Bd=function(e){var t;return this.a||=(t=new T,this.b.a.Nb(new Gfe(t)),Vg(),hu(t,this.c),new cv(t,16)),ZKe(this.a,e)},Q.a=null,L(RI,`StreamImpl/5`,1105),q(1106,1,$P,Gfe),Q.Cd=function(e){M(this.a,e)},L(RI,`StreamImpl/5/2methodref$add$Type`,1106),q(737,500,QP,UGe),Q.Bd=function(e){for(this.b=!1;!this.b&&this.c.Bd(new oxe(this,e)););return this.b},Q.b=!1,L(RI,`StreamImpl/FilterSpliterator`,737),q(1096,1,$P,oxe),Q.Cd=function(e){JNe(this.a,this.b,e)},L(RI,`StreamImpl/FilterSpliterator/lambda$0$Type`,1096),q(1091,736,QP,HUe),Q.Re=function(e){return TOe(this,P(e,189))},L(RI,`StreamImpl/MapToDoubleSpliterator`,1091),q(1095,1,$P,sxe),Q.Cd=function(e){gxe(this.a,this.b,e)},L(RI,`StreamImpl/MapToDoubleSpliterator/lambda$0$Type`,1095),q(1090,735,QP,UUe),Q.Re=function(e){return EOe(this,P(e,202))},L(RI,`StreamImpl/MapToIntSpliterator`,1090),q(1094,1,$P,cxe),Q.Cd=function(e){_xe(this.a,this.b,e)},L(RI,`StreamImpl/MapToIntSpliterator/lambda$0$Type`,1094),q(734,500,QP,WUe),Q.Bd=function(e){return DOe(this,e)},L(RI,`StreamImpl/MapToObjSpliterator`,734),q(1093,1,$P,lxe),Q.Cd=function(e){vxe(this.a,this.b,e)},L(RI,`StreamImpl/MapToObjSpliterator/lambda$0$Type`,1093),q(1092,500,QP,DJe),Q.Bd=function(e){for(;ns(this.b,0);){if(!this.a.Bd(new Le))return!1;this.b=xE(this.b,1)}return this.a.Bd(e)},Q.b=0,L(RI,`StreamImpl/SkipSpliterator`,1092),q(1097,1,$P,Le),Q.Cd=function(e){},L(RI,`StreamImpl/SkipSpliterator/lambda$0$Type`,1097),q(626,1,$P,Re),Q.Cd=function(e){jde(this,e)},L(RI,`StreamImpl/ValueConsumer`,626),q(1098,1,$P,ze),Q.Cd=function(e){wo()},L(RI,`StreamImpl/lambda$0$Type`,1098),q(1099,1,$P,Be),Q.Cd=function(e){wo()},L(RI,`StreamImpl/lambda$1$Type`,1099),q(1100,1,{},Kfe),Q.Ve=function(e,t){return Tke(this.a,e,t)},L(RI,`StreamImpl/lambda$4$Type`,1100),q(1101,1,$P,uxe),Q.Cd=function(e){UDe(this.b,this.a,e)},L(RI,`StreamImpl/lambda$5$Type`,1101),q(1107,1,$P,qfe),Q.Cd=function(e){mXe(this.a,P(e,380))},L(RI,`TerminatableStream/lambda$0$Type`,1107),q(2142,1,{}),q(2014,1,{},Ve),L(`javaemul.internal`,`ConsoleLogger`,2014);var bEt=0;q(2134,1,{}),q(1830,1,$P,He),Q.Cd=function(e){P(e,317)},L(WI,`BowyerWatsonTriangulation/lambda$0$Type`,1830),q(1831,1,$P,Jfe),Q.Cd=function(e){XS(this.a,P(e,317).e)},L(WI,`BowyerWatsonTriangulation/lambda$1$Type`,1831),q(1832,1,$P,Ue),Q.Cd=function(e){P(e,177)},L(WI,`BowyerWatsonTriangulation/lambda$2$Type`,1832),q(1827,1,GI,Yfe),Q.Ne=function(e,t){return JVe(this.a,P(e,177),P(t,177))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(WI,`NaiveMinST/lambda$0$Type`,1827),q(449,1,{},ir),L(WI,`NodeMicroLayout`,449),q(177,1,{177:1},fs),Q.Fb=function(e){var t;return j(e,177)?(t=P(e,177),rg(this.a,t.a)&&rg(this.b,t.b)||rg(this.a,t.b)&&rg(this.b,t.a)):!1},Q.Hb=function(){return cu(this.a)+cu(this.b)};var xEt=L(WI,`TEdge`,177);q(317,1,{317:1},pft),Q.Fb=function(e){var t;return j(e,317)?(t=P(e,317),Bb(this,t.a)&&Bb(this,t.b)&&Bb(this,t.c)):!1},Q.Hb=function(){return cu(this.a)+cu(this.b)+cu(this.c)},L(WI,`TTriangle`,317),q(225,1,{225:1},bu),L(WI,`Tree`,225),q(1218,1,{},xRe),L(yyt,`Scanline`,1218);var SEt=gp(yyt,byt);q(1758,1,{},KKe),L(KI,`CGraph`,1758),q(316,1,{316:1},wRe),Q.b=0,Q.c=0,Q.d=0,Q.g=0,Q.i=0,Q.k=lI,L(KI,`CGroup`,316),q(830,1,{},Ige),L(KI,`CGroup/CGroupBuilder`,830),q(60,1,{60:1},eOe),Q.Ib=function(){var e;return this.j?kd(this.j.Kb(this)):(Ad(CK),CK.o+`@`+(e=td(this)>>>0,e.toString(16)))},Q.f=0,Q.i=lI;var CK=L(KI,`CNode`,60);q(829,1,{},Lge),L(KI,`CNode/CNodeBuilder`,829);var CEt;q(1590,1,{},We),Q.ff=function(e,t){return 0},Q.gf=function(e,t){return 0},L(KI,Syt,1590),q(1853,1,{},Ge),Q.cf=function(e){var t,n,i,a,o,s,c,l,u=cI,d,f,p,m,h,g;for(i=new w(e.a.b);i.ar.d.c||r.d.c==a.d.c&&r.d.b0?e+this.n.d+this.n.a:0},Q.kf=function(){var e,t,n,i,a=0;if(this.e)this.b?a=this.b.a:this.a[1][1]&&(a=this.a[1][1].kf());else if(this.g)a=VE(this,Lk(this,null,!0));else for(t=(Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])),n=0,i=t.length;n0?a+this.n.b+this.n.c:0},Q.lf=function(){var e,t,n,r,i;if(this.g)for(e=Lk(this,null,!1),n=(Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])),r=0,i=n.length;r0&&(i[0]+=this.d,n-=i[0]),i[2]>0&&(i[2]+=this.d,n-=i[2]),this.c.a=r.Math.max(0,n),this.c.d=t.d+e.d+(this.c.a-n)/2,i[1]=r.Math.max(i[1],n),IUe(this,ZK,t.d+e.d+i[0]-(i[1]-n)/2,i)},Q.b=null,Q.d=0,Q.e=!1,Q.f=!1,Q.g=!1;var eq=0,tq=0;L(oL,`GridContainerCell`,1538),q(471,22,{3:1,34:1,22:1,471:1},hs);var nq,rq,iq,NEt=aS(oL,`HorizontalLabelAlignment`,471,eG,JRe,uke),PEt;q(314,217,{217:1,314:1},YLe,JKe,aLe),Q.jf=function(){return dMe(this)},Q.kf=function(){return fMe(this)},Q.a=0,Q.c=!1;var FEt=L(oL,`LabelCell`,314);q(252,336,{217:1,336:1,252:1},$D),Q.jf=function(){return aj(this)},Q.kf=function(){return oj(this)},Q.lf=function(){iN(this)},Q.mf=function(){oN(this)},Q.b=0,Q.c=0,Q.d=!1,L(oL,`StripContainerCell`,252),q(1691,1,vF,Qe),Q.Mb=function(e){return cve(P(e,217))},L(oL,`StripContainerCell/lambda$0$Type`,1691),q(1692,1,{},$e),Q.Ye=function(e){return P(e,217).kf()},L(oL,`StripContainerCell/lambda$1$Type`,1692),q(1693,1,vF,et),Q.Mb=function(e){return lve(P(e,217))},L(oL,`StripContainerCell/lambda$2$Type`,1693),q(1694,1,{},tt),Q.Ye=function(e){return P(e,217).jf()},L(oL,`StripContainerCell/lambda$3$Type`,1694),q(472,22,{3:1,34:1,22:1,472:1},gs);var aq,oq,sq,IEt=aS(oL,`VerticalLabelAlignment`,472,eG,qRe,dke),LEt;q(800,1,{},Agt),Q.c=0,Q.d=0,Q.k=0,Q.s=0,Q.t=0,Q.v=!1,Q.w=0,Q.D=!1,Q.F=!1,L(uL,`NodeContext`,800),q(1536,1,GI,nt),Q.Ne=function(e,t){return DCe(P(e,64),P(t,64))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(uL,`NodeContext/0methodref$comparePortSides$Type`,1536),q(1537,1,GI,rt),Q.Ne=function(e,t){return w7e(P(e,117),P(t,117))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(uL,`NodeContext/1methodref$comparePortContexts$Type`,1537),q(164,22,{3:1,34:1,22:1,164:1},iC);var REt,zEt,BEt,VEt,HEt,UEt,WEt,GEt,KEt,qEt,JEt,YEt,XEt,ZEt,QEt,$Et,eDt,tDt,nDt,rDt,iDt,cq,aDt=aS(uL,`NodeLabelLocation`,164,eG,sO,fke),oDt;q(117,1,{117:1},urt),Q.a=!1,L(uL,`PortContext`,117),q(1541,1,$P,it),Q.Cd=function(e){Tye(P(e,314))},L(pL,Ryt,1541),q(1542,1,vF,at),Q.Mb=function(e){return!!P(e,117).c},L(pL,zyt,1542),q(1543,1,$P,ot),Q.Cd=function(e){Tye(P(e,117).c)},L(pL,`LabelPlacer/lambda$2$Type`,1543);var lq;q(1540,1,$P,st),Q.Cd=function(e){Rd(),cge(P(e,117))},L(pL,`NodeLabelAndSizeUtilities/lambda$0$Type`,1540),q(801,1,$P,Af),Q.Cd=function(e){Bbe(this.b,this.c,this.a,P(e,187))},Q.a=!1,Q.c=!1,L(pL,`NodeLabelCellCreator/lambda$0$Type`,801),q(1539,1,$P,Qfe),Q.Cd=function(e){Ege(this.a,P(e,187))},L(pL,`PortContextCreator/lambda$0$Type`,1539);var uq;q(1902,1,{},ct),L(mL,`GreedyRectangleStripOverlapRemover`,1902),q(1903,1,GI,lt),Q.Ne=function(e,t){return YTe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`GreedyRectangleStripOverlapRemover/0methodref$compareByYCoordinate$Type`,1903),q(1849,1,{},Hge),Q.a=5,Q.e=0,L(mL,`RectangleStripOverlapRemover`,1849),q(1850,1,GI,ut),Q.Ne=function(e,t){return XTe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`RectangleStripOverlapRemover/0methodref$compareLeftRectangleBorders$Type`,1850),q(1852,1,GI,dt),Q.Ne=function(e,t){return APe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`RectangleStripOverlapRemover/1methodref$compareRightRectangleBorders$Type`,1852),q(417,22,{3:1,34:1,22:1,417:1},_s);var dq,fq,pq,mq,sDt=aS(mL,`RectangleStripOverlapRemover/OverlapRemovalDirection`,417,eG,mVe,pke),cDt;q(226,1,{226:1},$p),L(mL,`RectangleStripOverlapRemover/RectangleNode`,226),q(1851,1,$P,$fe),Q.Cd=function(e){l3e(this.a,P(e,226))},L(mL,`RectangleStripOverlapRemover/lambda$1$Type`,1851),q(1323,1,GI,ft),Q.Ne=function(e,t){return Ppt(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator`,1323),q(1326,1,{},pt),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$0$Type`,1326),q(1327,1,vF,mt),Q.Mb=function(e){return P(e,332).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$1$Type`,1327),q(1328,1,vF,ht),Q.Mb=function(e){return P(e,332).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$2$Type`,1328),q(1321,1,GI,gt),Q.Ne=function(e,t){return klt(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinNumOfExtensionDirectionsComparator`,1321),q(1324,1,{},_t),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/MinNumOfExtensionDirectionsComparator/lambda$0$Type`,1324),q(781,1,GI,vt),Q.Ne=function(e,t){return EXe(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinNumOfExtensionsComparator`,781),q(1319,1,GI,yt),Q.Ne=function(e,t){return VJe(P(e,330),P(t,330))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinPerimeterComparator`,1319),q(1320,1,GI,bt),Q.Ne=function(e,t){return h4e(P(e,330),P(t,330))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinPerimeterComparatorWithShape`,1320),q(1322,1,GI,xt),Q.Ne=function(e,t){return dut(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/SingleExtensionSideGreaterThanRestComparator`,1322),q(1325,1,{},St),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/SingleExtensionSideGreaterThanRestComparator/lambda$0$Type`,1325),q(782,1,{},vs),Q.Ve=function(e,t){return YBe(this,P(e,42),P(t,176))},L(gL,`SuccessorCombination`,782),q(649,1,{},Ct),Q.Ve=function(e,t){var n;return Int((n=P(e,42),P(t,176),n))},L(gL,`SuccessorJitter`,649),q(648,1,{},wt),Q.Ve=function(e,t){var n;return cst((n=P(e,42),P(t,176),n))},L(gL,`SuccessorLineByLine`,648),q(573,1,{},Tt),Q.Ve=function(e,t){var n;return Pit((n=P(e,42),P(t,176),n))},L(gL,`SuccessorManhattan`,573),q(1344,1,{},Et),Q.Ve=function(e,t){var n;return Cot((n=P(e,42),P(t,176),n))},L(gL,`SuccessorMaxNormWindingInMathPosSense`,1344),q(409,1,{},or),Q.Ve=function(e,t){return bPe(this,e,t)},Q.c=!1,Q.d=!1,Q.e=!1,Q.f=!1,L(gL,`SuccessorQuadrantsGeneric`,409),q(1345,1,{},Dt),Q.Kb=function(e){return P(e,334).a},L(gL,`SuccessorQuadrantsGeneric/lambda$0$Type`,1345),q(332,22,{3:1,34:1,22:1,332:1},ys),Q.a=!1;var hq,gq,_q,vq,lDt=aS(xL,Vyt,332,eG,fVe,mke),uDt;q(1317,1,{}),Q.Ib=function(){var e,t,n=` `,r,i,a;for(e=G(0),i=0;i=0?`b`+e+`[`+cy(this.a)+`]`:`b[`+cy(this.a)+`]`):`b_`+td(this)},L(HL,`FBendpoint`,250),q(290,137,{3:1,290:1,96:1,137:1},tOe),Q.Ib=function(){return cy(this)},L(HL,`FEdge`,290),q(235,137,{3:1,235:1,96:1,137:1},Py);var TDt=L(HL,`FGraph`,235);q(454,309,{3:1,454:1,309:1,96:1,137:1},$Ve),Q.Ib=function(){return this.b==null||this.b.length==0?`l[`+cy(this.a)+`]`:`l_`+this.b},L(HL,`FLabel`,454),q(153,309,{3:1,153:1,309:1,96:1,137:1},Ewe),Q.Ib=function(){return Gze(this)},Q.a=0,L(HL,`FNode`,153),q(2100,1,{}),Q.vf=function(e){Edt(this,e)},Q.wf=function(){x3e(this)},Q.d=0,L(ibt,`AbstractForceModel`,2100),q(641,2100,{641:1},XYe),Q.uf=function(e,t){var n,i,a,o,s;return dmt(this.f,e,t),a=ef(xu(t.d),e.d),s=r.Math.sqrt(a.a*a.a+a.b*a.b),i=r.Math.max(0,s-Ih(e.e)/2-Ih(t.e)/2),n=Hnt(this.e,e,t),o=n>0?-EPe(i,this.c)*n:xEe(i,this.b)*P(K(e,(XM(),Xq)),17).a,ku(a,o/s),a},Q.vf=function(e){Edt(this,e),this.a=P(K(e,(XM(),Gq)),17).a,this.c=D(N(K(e,$q))),this.b=D(N(K(e,Zq)))},Q.xf=function(e){return e0&&(o-=tve(i,this.a)*n),ku(a,o*this.b/s),a},Q.vf=function(e){var t,n,i,a,o,s,c;for(Edt(this,e),this.b=D(N(K(e,(XM(),eJ)))),this.c=this.b/P(K(e,Gq),17).a,i=e.e.c.length,o=0,a=0,c=new w(e.e);c.a0},Q.a=0,Q.b=0,Q.c=0,L(ibt,`FruchtermanReingoldModel`,642),q(860,1,nL,aue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UL),``),`Force Model`),`Determines the model for force calculation.`),Bq),(VA(),B3)),Uq),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,abt),``),`Iterations`),`The number of iterations on the force model.`),G(300)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,obt),``),`Repulsive Power`),`Determines how many bend points are added to the edge; such bend points are regarded as repelling particles in the force model`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WL),``),`FR Temperature`),`The temperature is used as a scaling factor for particle displacements.`),GL),z3),TG),sE(F3)))),wv(e,WL,UL,MDt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,KL),``),`Eades Repulsion`),`Factor for repulsive forces in Eades' model.`),5),z3),TG),sE(F3)))),wv(e,KL,UL,kDt),y_t((new oue,e))};var EDt,DDt,Bq,ODt,kDt,ADt,jDt,MDt;L(qL,`ForceMetaDataProvider`,860),q(432,22,{3:1,34:1,22:1,432:1},Ss);var Vq,Hq,Uq=aS(qL,`ForceModelStrategy`,432,eG,uLe,_ke),NDt;q(DF,1,nL,oue),Q.hf=function(e){y_t(e)};var PDt,FDt,Wq,Gq,Kq,IDt,LDt,RDt,zDt,qq,BDt,Jq,Yq,VDt,Xq,HDt,Zq,Qq,UDt,WDt,$q,eJ,GDt,KDt,qDt,tJ,JDt;L(qL,`ForceOptions`,DF),q(1001,1,{},aee),Q.sf=function(){var e;return e=new Fge,e},Q.tf=function(e){},L(qL,`ForceOptions/ForceFactory`,1001);var nJ,rJ,iJ,aJ;q(861,1,nL,sue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dbt),``),`Fixed Position`),`Prevent that the node is moved by the layout algorithm.`),(rd(),!1)),(VA(),R3)),bG),sE((uO(),P3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fbt),``),`Desired Edge Length`),`Either specified for parent nodes or for individual edges, where the latter takes higher precedence.`),100),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[M3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pbt),``),`Layout Dimension`),`Dimensions that are permitted to be altered during layout.`),oJ),B3),_J),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mbt),``),`Stress Epsilon`),`Termination criterion for the iterative process.`),GL),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hbt),``),`Iteration Limit`),`Maximum number of performed iterations. Takes higher precedence than 'epsilon'.`),G(AP)),H3),DG),sE(F3)))),Cht((new cue,e))};var YDt,XDt,oJ,ZDt,QDt,$Dt;L(qL,`StressMetaDataProvider`,861),q(1004,1,nL,cue),Q.hf=function(e){Cht(e)};var sJ,cJ,lJ,uJ,dJ,fJ,eOt,tOt,nOt,rOt,pJ,iOt;L(qL,`StressOptions`,1004),q(1005,1,{},ree),Q.sf=function(){var e;return e=new nOe,e},Q.tf=function(e){},L(qL,`StressOptions/StressFactory`,1005),q(1110,205,OL,nOe),Q.rf=function(e,t){var n,r,i,a,o;for(t.Ug(gbt,1),ki(Od(J(e,(Nk(),dJ))))?ki(Od(J(e,pJ)))||S_((n=new ir((Ko(),new Ei(e))),n)):wat(new Fge,e,t.eh(1)),i=fZe(e),r=nft(this.a,i),o=r.Kc();o.Ob();)a=P(o.Pb(),235),!(a.e.c.length<=1)&&(kpt(this.b,a),kit(this.b),Dx(a.d,new iee));i=f_t(r),Y_t(i),t.Vg()},L(_R,`StressLayoutProvider`,1110),q(1111,1,$P,iee),Q.Cd=function(e){Hft(P(e,454))},L(_R,`StressLayoutProvider/lambda$0$Type`,1111),q(1002,1,{},Tge),Q.c=0,Q.e=0,Q.g=0,L(_R,`StressMajorization`,1002),q(391,22,{3:1,34:1,22:1,391:1},Cs);var mJ,hJ,gJ,_J=aS(_R,`StressMajorization/Dimension`,391,eG,XRe,vke),aOt;q(1003,1,GI,rpe),Q.Ne=function(e,t){return kOe(this.a,P(e,153),P(t,153))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(_R,`StressMajorization/lambda$0$Type`,1003),q(1192,1,{},Qze),L(vR,`ElkLayered`,1192),q(1193,1,$P,ipe),Q.Cd=function(e){Ltt(this.a,P(e,36))},L(vR,`ElkLayered/lambda$0$Type`,1193),q(1194,1,$P,ape),Q.Cd=function(e){AOe(this.a,P(e,36))},L(vR,`ElkLayered/lambda$1$Type`,1194),q(1281,1,{},Hwe);var oOt,sOt,cOt;L(vR,`GraphConfigurator`,1281),q(770,1,$P,cr),Q.Cd=function(e){T9e(this.a,P(e,10))},L(vR,`GraphConfigurator/lambda$0$Type`,770),q(771,1,{},Ht),Q.Kb=function(e){return i8e(),new Mp(null,new cv(P(e,30).a,16))},L(vR,`GraphConfigurator/lambda$1$Type`,771),q(772,1,$P,lr),Q.Cd=function(e){T9e(this.a,P(e,10))},L(vR,`GraphConfigurator/lambda$2$Type`,772),q(1109,205,OL,Uge),Q.rf=function(e,t){var n=$ft(new Gge,e);A(J(e,(mP(),D1)))===A((_T(),g8))?v1e(this.a,n,t):Cit(this.a,n,t),t.$g()||Lgt(new lue,n)},L(vR,`LayeredLayoutProvider`,1109),q(367,22,{3:1,34:1,22:1,367:1},ws);var vJ,yJ,bJ,xJ,SJ,CJ=aS(vR,`LayeredPhases`,367,eG,iUe,yke),lOt;q(1717,1,{},CJe),Q.i=0;var uOt;L(yR,`ComponentsToCGraphTransformer`,1717);var dOt;q(1718,1,{},nee),Q.yf=function(e,t){return r.Math.min(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},Q.zf=function(e,t){return r.Math.min(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},L(yR,`ComponentsToCGraphTransformer/1`,1718),q(86,1,{86:1}),Q.i=0,Q.k=!0,Q.o=lI;var wJ=L(bR,`CNode`,86);q(470,86,{470:1,86:1},cEe,ZD),Q.Ib=function(){return``},L(yR,`ComponentsToCGraphTransformer/CRectNode`,470),q(1688,1,{},oee);var TJ,EJ;L(yR,`OneDimensionalComponentsCompaction`,1688),q(1689,1,{},see),Q.Kb=function(e){return NRe(P(e,42))},Q.Fb=function(e){return this===e},L(yR,`OneDimensionalComponentsCompaction/lambda$0$Type`,1689),q(1690,1,{},cee),Q.Kb=function(e){return b1e(P(e,42))},Q.Fb=function(e){return this===e},L(yR,`OneDimensionalComponentsCompaction/lambda$1$Type`,1690),q(1720,1,{},nFe),L(bR,`CGraph`,1720),q(194,1,{194:1},QD),Q.b=0,Q.c=0,Q.e=0,Q.g=!0,Q.i=lI,L(bR,`CGroup`,194),q(1719,1,{},lee),Q.yf=function(e,t){return r.Math.max(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},Q.zf=function(e,t){return r.Math.max(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},L(bR,Syt,1719),q(1721,1,{},Ynt),Q.d=!1;var fOt,DJ=L(bR,Tyt,1721);q(1722,1,{},uee),Q.Kb=function(e){return Nbe(),rd(),P(P(e,42).a,86).d.e!=0},Q.Fb=function(e){return this===e},L(bR,Eyt,1722),q(833,1,{},kp),Q.a=!1,Q.b=!1,Q.c=!1,Q.d=!1,L(bR,Dyt,833),q(1898,1,{},vNe),L(xR,Oyt,1898);var OJ=gp(SR,byt);q(1899,1,{382:1},XIe),Q.bf=function(e){Fst(this,P(e,476))},L(xR,kyt,1899),q(VF,1,GI,dee),Q.Ne=function(e,t){return eIe(P(e,86),P(t,86))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(xR,Ayt,VF),q(476,1,{476:1},Axe),Q.a=!1,L(xR,jyt,476),q(1901,1,GI,fee),Q.Ne=function(e,t){return r8e(P(e,476),P(t,476))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(xR,Myt,1901),q(148,1,{148:1},js,Pje),Q.Fb=function(e){var t;return e==null||pOt!=$w(e)?!1:(t=P(e,148),rg(this.c,t.c)&&rg(this.d,t.d))},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.c,this.d]))},Q.Ib=function(){return`(`+this.c+PP+this.d+(this.a?`cx`:``)+this.b+`)`},Q.a=!0,Q.c=0,Q.d=0;var pOt=L(SR,`Point`,148);q(416,22,{3:1,34:1,22:1,416:1},Es);var kJ,AJ,jJ,MJ,mOt=aS(SR,`Point/Quadrant`,416,eG,hVe,bke),hOt;q(1708,1,{},Bge),Q.b=null,Q.c=null,Q.d=null,Q.e=null,Q.f=null;var gOt,_Ot,vOt,yOt,bOt;L(SR,`RectilinearConvexHull`,1708),q(583,1,{382:1},xO),Q.bf=function(e){xGe(this,P(e,148))},Q.b=0;var NJ;L(SR,`RectilinearConvexHull/MaximalElementsEventHandler`,583),q(1710,1,GI,pee),Q.Ne=function(e,t){return tIe(N(e),N(t))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/MaximalElementsEventHandler/lambda$0$Type`,1710),q(1709,1,{382:1},qKe),Q.bf=function(e){Oot(this,P(e,148))},Q.a=0,Q.b=null,Q.c=null,Q.d=null,Q.e=null,L(SR,`RectilinearConvexHull/RectangleEventHandler`,1709),q(1711,1,GI,mee),Q.Ne=function(e,t){return Bze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$0$Type`,1711),q(1712,1,GI,_ee),Q.Ne=function(e,t){return Vze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$1$Type`,1712),q(1713,1,GI,vee),Q.Ne=function(e,t){return zze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$2$Type`,1713),q(1714,1,GI,gee),Q.Ne=function(e,t){return Hze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$3$Type`,1714),q(1715,1,GI,yee),Q.Ne=function(e,t){return X7e(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$4$Type`,1715),q(1716,1,{},SRe),L(SR,`Scanline`,1716),q(2104,1,{}),L(CR,`AbstractGraphPlacer`,2104),q(335,1,{335:1},MEe),Q.Ff=function(e){return this.Gf(e)?(fj(this.b,P(K(e,(Y(),SQ)),21),e),!0):!1},Q.Gf=function(e){var t=P(K(e,(Y(),SQ)),21),n,r;for(r=P(Dy(PJ,t),21).Kc();r.Ob();)if(n=P(r.Pb(),21),!P(Dy(this.b,n),15).dc())return!1;return!0};var PJ;L(CR,`ComponentGroup`,335),q(779,2104,{},Vge),Q.Hf=function(e){var t,n;for(n=new w(this.a);n.an&&(d=0,f+=c+i,c=0),l=o.c,kM(o,d+l.a,f+l.b),Cl(l),a=r.Math.max(a,d+u.a),c=r.Math.max(c,u.b),d+=u.a+i;t.f.a=a,t.f.b=f+c},Q.Jf=function(e,t){var n,r,i,a,o;if(A(K(t,(mP(),t1)))===A((YD(),RJ))){for(r=e.Kc();r.Ob();){for(n=P(r.Pb(),36),o=0,a=new w(n.a);a.an&&!P(K(o,(Y(),SQ)),21).Hc((nP(),Z8))||l&&P(K(l,(Y(),SQ)),21).Hc((nP(),X8))||P(K(o,(Y(),SQ)),21).Hc((nP(),g5)))&&(p=f,m+=c+i,c=0),u=o.c,P(K(o,(Y(),SQ)),21).Hc((nP(),Z8))&&(p=a+i),kM(o,p+u.a,m+u.b),a=r.Math.max(a,p+d.a),P(K(o,SQ),21).Hc(m5)&&(f=r.Math.max(f,p+d.a+i)),Cl(u),c=r.Math.max(c,d.b),p+=d.a+i,l=o;t.f.a=a,t.f.b=m+c},Q.Jf=function(e,t){},L(CR,`ModelOrderRowGraphPlacer`,1313),q(1311,1,GI,See),Q.Ne=function(e,t){return _Xe(P(e,36),P(t,36))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(CR,`SimpleRowGraphPlacer/1`,1311);var SOt;q(1280,1,YI,Cee),Q.Lb=function(e){var t;return t=P(K(P(e,249).b,(mP(),j1)),75),!!t&&t.b!=0},Q.Fb=function(e){return this===e},Q.Mb=function(e){var t;return t=P(K(P(e,249).b,(mP(),j1)),75),!!t&&t.b!=0},L(ER,`CompoundGraphPostprocessor/1`,1280),q(1279,1,DR,Kge),Q.Kf=function(e,t){v4e(this,P(e,36),t)},L(ER,`CompoundGraphPreprocessor`,1279),q(453,1,{453:1},W$e),Q.c=!1,L(ER,`CompoundGraphPreprocessor/ExternalPort`,453),q(249,1,{249:1},kf),Q.Ib=function(){return bd(this.c)+`:`+Cnt(this.b)},L(ER,`CrossHierarchyEdge`,249),q(777,1,GI,ur),Q.Ne=function(e,t){return u6e(this,P(e,249),P(t,249))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(ER,`CrossHierarchyEdgeComparator`,777),q(305,137,{3:1,305:1,96:1,137:1}),Q.p=0,L(OR,`LGraphElement`,305),q(18,305,{3:1,18:1,305:1,96:1,137:1},i_),Q.Ib=function(){return Cnt(this)};var VJ=L(OR,`LEdge`,18);q(36,305,{3:1,20:1,36:1,305:1,96:1,137:1},wJe),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new w(this.b)},Q.Ib=function(){return this.b.c.length==0?`G-unlayered`+CA(this.a):this.a.c.length==0?`G-layered`+CA(this.b):`G[layerless`+CA(this.a)+`, layers`+CA(this.b)+`]`};var COt=L(OR,`LGraph`,36),wOt;q(666,1,{}),Q.Lf=function(){return this.e.n},Q.of=function(e){return K(this.e,e)},Q.Mf=function(){return this.e.o},Q.Nf=function(){return this.e.p},Q.pf=function(e){return yd(this.e,e)},Q.Of=function(e){this.e.n.a=e.a,this.e.n.b=e.b},Q.Pf=function(e){this.e.o.a=e.a,this.e.o.b=e.b},Q.Qf=function(e){this.e.p=e},L(OR,`LGraphAdapters/AbstractLShapeAdapter`,666),q(474,1,{853:1},dr),Q.Rf=function(){var e,t;if(!this.b)for(this.b=dd(this.a.b.c.length),t=new w(this.a.b);t.a0&&WQe((sv(t-1,e.length),e.charCodeAt(t-1)),wbt);)--t;if(a> `,e),Sk(n)),gl(hl((e.a+=`[`,e),n.i),`]`)),e.a},Q.c=!0,Q.d=!1;var QJ,$J,eY,tY,nY,rY,EOt=L(OR,`LPort`,12);q(408,1,rF,pr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new ope(new w(this.a.e))},L(OR,`LPort/1`,408),q(1309,1,VP,ope),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(z(this.a),18).c},Q.Ob=function(){return gu(this.a)},Q.Qb=function(){Gm(this.a)},L(OR,`LPort/1/1`,1309),q(369,1,rF,mr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){var e;return e=new w(this.a.g),new spe(e)},L(OR,`LPort/2`,369),q(776,1,VP,spe),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(z(this.a),18).d},Q.Ob=function(){return gu(this.a)},Q.Qb=function(){Gm(this.a)},L(OR,`LPort/2/1`,776),q(1302,1,rF,wxe),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new Ny(this)},L(OR,`LPort/CombineIter`,1302),q(208,1,VP,Ny),Q.Nb=function(e){Om(this,e)},Q.Qb=function(){uye()},Q.Ob=function(){return ed(this)},Q.Pb=function(){return gu(this.a)?z(this.a):z(this.b)},L(OR,`LPort/CombineIter/1`,208),q(1303,1,YI,Tee),Q.Lb=function(e){return ZNe(e)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).g.c.length!=0},L(OR,`LPort/lambda$0$Type`,1303),q(1304,1,YI,Eee),Q.Lb=function(e){return QNe(e)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).e.c.length!=0},L(OR,`LPort/lambda$1$Type`,1304),q(1305,1,YI,Dee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),Z8)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),Z8)},L(OR,`LPort/lambda$2$Type`,1305),q(1306,1,YI,Oee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),X8)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),X8)},L(OR,`LPort/lambda$3$Type`,1306),q(1307,1,YI,kee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),m5)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),m5)},L(OR,`LPort/lambda$4$Type`,1307),q(1308,1,YI,Aee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),g5)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),g5)},L(OR,`LPort/lambda$5$Type`,1308),q(30,305,{3:1,20:1,305:1,30:1,96:1,137:1},Eh),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new w(this.a)},Q.Ib=function(){return`L_`+Ab(this.b.b,this,0)+CA(this.a)},L(OR,`Layer`,30),q(1330,1,{},Gge),L(NR,Obt,1330),q(1334,1,{},jee),Q.Kb=function(e){return cA(P(e,84))},L(NR,`ElkGraphImporter/0methodref$connectableShapeToNode$Type`,1334),q(1337,1,{},Mee),Q.Kb=function(e){return cA(P(e,84))},L(NR,`ElkGraphImporter/1methodref$connectableShapeToNode$Type`,1337),q(1331,1,$P,cpe),Q.Cd=function(e){frt(this.a,P(e,123))},L(NR,nbt,1331),q(1332,1,$P,lpe),Q.Cd=function(e){frt(this.a,P(e,123))},L(NR,kbt,1332),q(1333,1,{},Nee),Q.Kb=function(e){return new Mp(null,new cv(sg(P(e,74)),16))},L(NR,Abt,1333),q(1335,1,vF,upe),Q.Mb=function(e){return XCe(this.a,P(e,27))},L(NR,jbt,1335),q(1336,1,{},Pee),Q.Kb=function(e){return new Mp(null,new cv(KFe(P(e,74)),16))},L(NR,`ElkGraphImporter/lambda$5$Type`,1336),q(1338,1,vF,dpe),Q.Mb=function(e){return ZCe(this.a,P(e,27))},L(NR,`ElkGraphImporter/lambda$7$Type`,1338),q(1339,1,vF,Fee),Q.Mb=function(e){return wIe(P(e,74))},L(NR,`ElkGraphImporter/lambda$8$Type`,1339),q(1297,1,{},lue);var DOt;L(NR,`ElkGraphLayoutTransferrer`,1297),q(1298,1,vF,fpe),Q.Mb=function(e){return XDe(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$0$Type`,1298),q(1299,1,$P,ppe),Q.Cd=function(e){Io(),M(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$1$Type`,1299),q(1300,1,vF,mpe),Q.Mb=function(e){return yDe(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$2$Type`,1300),q(1301,1,$P,hpe),Q.Cd=function(e){Io(),M(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$3$Type`,1301),q(819,1,{},Zd),L(PR,`BiLinkedHashMultiMap`,819),q(1550,1,DR,Iee),Q.Kf=function(e,t){cYe(P(e,36),t)},L(PR,`CommentNodeMarginCalculator`,1550),q(1551,1,{},Lee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`CommentNodeMarginCalculator/lambda$0$Type`,1551),q(1552,1,$P,Ree),Q.Cd=function(e){Zft(P(e,10))},L(PR,`CommentNodeMarginCalculator/lambda$1$Type`,1552),q(1553,1,DR,zee),Q.Kf=function(e,t){qst(P(e,36),t)},L(PR,`CommentPostprocessor`,1553),q(1554,1,DR,Bee),Q.Kf=function(e,t){Tgt(P(e,36),t)},L(PR,`CommentPreprocessor`,1554),q(1555,1,DR,Vee),Q.Kf=function(e,t){Hot(P(e,36),t)},L(PR,`ConstraintsPostprocessor`,1555),q(1556,1,DR,Hee),Q.Kf=function(e,t){aXe(P(e,36),t)},L(PR,`EdgeAndLayerConstraintEdgeReverser`,1556),q(1557,1,DR,Uee),Q.Kf=function(e,t){u0e(P(e,36),t)},L(PR,`EndLabelPostprocessor`,1557),q(1558,1,{},Wee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelPostprocessor/lambda$0$Type`,1558),q(1559,1,vF,Gee),Q.Mb=function(e){return YHe(P(e,10))},L(PR,`EndLabelPostprocessor/lambda$1$Type`,1559),q(1560,1,$P,Kee),Q.Cd=function(e){a8e(P(e,10))},L(PR,`EndLabelPostprocessor/lambda$2$Type`,1560),q(1561,1,DR,qee),Q.Kf=function(e,t){Ket(P(e,36),t)},L(PR,`EndLabelPreprocessor`,1561),q(1562,1,{},Jee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelPreprocessor/lambda$0$Type`,1562),q(1563,1,$P,Cke),Q.Cd=function(e){Vbe(this.a,this.b,this.c,P(e,10))},Q.a=0,Q.b=0,Q.c=!1,L(PR,`EndLabelPreprocessor/lambda$1$Type`,1563),q(1564,1,vF,Yee),Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),c8))},L(PR,`EndLabelPreprocessor/lambda$2$Type`,1564),q(1565,1,$P,gpe),Q.Cd=function(e){up(this.a,P(e,72))},L(PR,`EndLabelPreprocessor/lambda$3$Type`,1565),q(1566,1,vF,Xee),Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),s8))},L(PR,`EndLabelPreprocessor/lambda$4$Type`,1566),q(1567,1,$P,_pe),Q.Cd=function(e){up(this.a,P(e,72))},L(PR,`EndLabelPreprocessor/lambda$5$Type`,1567),q(1615,1,DR,tue),Q.Kf=function(e,t){Z$e(P(e,36),t)};var OOt;L(PR,`EndLabelSorter`,1615),q(1616,1,GI,Zee),Q.Ne=function(e,t){return m2e(P(e,466),P(t,466))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`EndLabelSorter/1`,1616),q(466,1,{466:1},LIe),L(PR,`EndLabelSorter/LabelGroup`,466),q(1617,1,{},Qee),Q.Kb=function(e){return Fo(),new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelSorter/lambda$0$Type`,1617),q(1618,1,vF,$ee),Q.Mb=function(e){return Fo(),P(e,10).k==(DA(),JJ)},L(PR,`EndLabelSorter/lambda$1$Type`,1618),q(1619,1,$P,ete),Q.Cd=function(e){E9e(P(e,10))},L(PR,`EndLabelSorter/lambda$2$Type`,1619),q(1620,1,vF,tte),Q.Mb=function(e){return Fo(),A(K(P(e,72),(mP(),b1)))===A((Lx(),s8))},L(PR,`EndLabelSorter/lambda$3$Type`,1620),q(1621,1,vF,nte),Q.Mb=function(e){return Fo(),A(K(P(e,72),(mP(),b1)))===A((Lx(),c8))},L(PR,`EndLabelSorter/lambda$4$Type`,1621),q(1568,1,DR,rte),Q.Kf=function(e,t){xpt(this,P(e,36))},Q.b=0,Q.c=0,L(PR,`FinalSplineBendpointsCalculator`,1568),q(1569,1,{},ite),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`FinalSplineBendpointsCalculator/lambda$0$Type`,1569),q(1570,1,{},ate),Q.Kb=function(e){return new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(PR,`FinalSplineBendpointsCalculator/lambda$1$Type`,1570),q(1571,1,vF,ote),Q.Mb=function(e){return!gy(P(e,18))},L(PR,`FinalSplineBendpointsCalculator/lambda$2$Type`,1571),q(1572,1,vF,ste),Q.Mb=function(e){return yd(P(e,18),(Y(),l$))},L(PR,`FinalSplineBendpointsCalculator/lambda$3$Type`,1572),q(1573,1,$P,vpe),Q.Cd=function(e){hut(this.a,P(e,131))},L(PR,`FinalSplineBendpointsCalculator/lambda$4$Type`,1573),q(1574,1,$P,cte),Q.Cd=function(e){JA(P(e,18).a)},L(PR,`FinalSplineBendpointsCalculator/lambda$5$Type`,1574),q(803,1,DR,ype),Q.Kf=function(e,t){Dmt(this,P(e,36),t)},L(PR,`GraphTransformer`,803),q(517,22,{3:1,34:1,22:1,517:1},xxe);var iY,aY,kOt=aS(PR,`GraphTransformer/Mode`,517,eG,dLe,OAe),AOt;q(1575,1,DR,lte),Q.Kf=function(e,t){Fat(P(e,36),t)},L(PR,`HierarchicalNodeResizingProcessor`,1575),q(1576,1,DR,ute),Q.Kf=function(e,t){XJe(P(e,36),t)},L(PR,`HierarchicalPortConstraintProcessor`,1576),q(1577,1,GI,dte),Q.Ne=function(e,t){return Q2e(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortConstraintProcessor/NodeComparator`,1577),q(1578,1,DR,fte),Q.Kf=function(e,t){qdt(P(e,36),t)},L(PR,`HierarchicalPortDummySizeProcessor`,1578),q(1579,1,DR,pte),Q.Kf=function(e,t){Fct(this,P(e,36),t)},Q.a=0,L(PR,`HierarchicalPortOrthogonalEdgeRouter`,1579),q(1580,1,GI,mte),Q.Ne=function(e,t){return ZTe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortOrthogonalEdgeRouter/1`,1580),q(1581,1,GI,hte),Q.Ne=function(e,t){return wGe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortOrthogonalEdgeRouter/2`,1581),q(1582,1,DR,gte),Q.Kf=function(e,t){W7e(P(e,36),t)},L(PR,`HierarchicalPortPositionProcessor`,1582),q(1583,1,DR,uue),Q.Kf=function(e,t){T_t(this,P(e,36))},Q.a=0,Q.c=0;var oY,sY;L(PR,`HighDegreeNodeLayeringProcessor`,1583),q(580,1,{580:1},_te),Q.b=-1,Q.d=-1,L(PR,`HighDegreeNodeLayeringProcessor/HighDegreeNodeInformation`,580),q(1584,1,{},vte),Q.Kb=function(e){return Ff(),DE(P(e,10))},Q.Fb=function(e){return this===e},L(PR,`HighDegreeNodeLayeringProcessor/lambda$0$Type`,1584),q(1585,1,{},yte),Q.Kb=function(e){return Ff(),OE(P(e,10))},Q.Fb=function(e){return this===e},L(PR,`HighDegreeNodeLayeringProcessor/lambda$1$Type`,1585),q(1591,1,DR,bte),Q.Kf=function(e,t){jdt(this,P(e,36),t)},L(PR,`HyperedgeDummyMerger`,1591),q(804,1,{},jf),Q.a=!1,Q.b=!1,Q.c=!1,L(PR,`HyperedgeDummyMerger/MergeState`,804),q(1592,1,{},xte),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`HyperedgeDummyMerger/lambda$0$Type`,1592),q(1593,1,{},Ste),Q.Kb=function(e){return new Mp(null,new cv(P(e,10).j,16))},L(PR,`HyperedgeDummyMerger/lambda$1$Type`,1593),q(1594,1,$P,Cte),Q.Cd=function(e){P(e,12).p=-1},L(PR,`HyperedgeDummyMerger/lambda$2$Type`,1594),q(1595,1,DR,wte),Q.Kf=function(e,t){kdt(P(e,36),t)},L(PR,`HypernodesProcessor`,1595),q(1596,1,DR,Tte),Q.Kf=function(e,t){Kdt(P(e,36),t)},L(PR,`InLayerConstraintProcessor`,1596),q(1597,1,DR,Ete),Q.Kf=function(e,t){AYe(P(e,36),t)},L(PR,`InnermostNodeMarginCalculator`,1597),q(1598,1,DR,Dte),Q.Kf=function(e,t){xgt(this,P(e,36))},Q.a=lI,Q.b=lI,Q.c=cI,Q.d=cI;var jOt=L(PR,`InteractiveExternalPortPositioner`,1598);q(1599,1,{},Ote),Q.Kb=function(e){return P(e,18).d.i},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$0$Type`,1599),q(1600,1,{},bpe),Q.Kb=function(e){return QTe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$1$Type`,1600),q(1601,1,{},kte),Q.Kb=function(e){return P(e,18).c.i},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$2$Type`,1601),q(1602,1,{},xpe),Q.Kb=function(e){return $Te(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$3$Type`,1602),q(1603,1,{},Spe),Q.Kb=function(e){return dOe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$4$Type`,1603),q(1604,1,{},Cpe),Q.Kb=function(e){return fOe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$5$Type`,1604),q(81,22,{3:1,34:1,22:1,81:1,196:1},ks),Q.dg=function(){switch(this.g){case 15:return new qre;case 22:return new Jre;case 47:return new Zre;case 28:case 35:return new Bte;case 32:return new Iee;case 42:return new zee;case 1:return new Bee;case 41:return new Vee;case 56:return new ype((dC(),aY));case 0:return new ype((dC(),iY));case 2:return new Hee;case 54:return new Uee;case 33:return new qee;case 51:return new rte;case 55:return new lte;case 13:return new ute;case 38:return new fte;case 44:return new pte;case 40:return new gte;case 9:return new uue;case 49:return new oEe;case 37:return new bte;case 43:return new wte;case 27:return new Tte;case 30:return new Ete;case 3:return new Dte;case 18:return new jte;case 29:return new Mte;case 5:return new due;case 50:return new Ate;case 34:return new fue;case 36:return new Vte;case 52:return new tue;case 11:return new Hte;case 7:return new pue;case 39:return new Ute;case 45:return new Wte;case 16:return new Gte;case 10:return new Jxe;case 48:return new Yte;case 21:return new Xte;case 23:return new Ti((sS(),g2));case 8:return new Qte;case 12:return new ene;case 4:return new tne;case 19:return new yue;case 17:return new dne;case 53:return new fne;case 6:return new wne;case 25:return new Yge;case 46:return new _ne;case 31:return new oOe;case 14:return new Mne;case 26:return new iie;case 20:return new Lne;case 24:return new Ti((sS(),_2));default:throw E(new Fi(FR+(this.f==null?``+this.g:this.f)))}};var cY,lY,uY,dY,fY,pY,mY,hY,gY,_Y,vY,yY,bY,xY,SY,CY,wY,TY,EY,DY,OY,kY,AY,jY,MY,NY,PY,FY,IY,LY,RY,zY,BY,VY,HY,UY,WY,GY,KY,qY,JY,YY,XY,ZY,QY,$Y,eX,tX,nX,rX,iX,aX,oX,sX,cX,lX,uX,MOt=aS(PR,IR,81,eG,wot,Dke),NOt;q(1605,1,DR,jte),Q.Kf=function(e,t){ygt(P(e,36),t)},L(PR,`InvertedPortProcessor`,1605),q(1606,1,DR,Mte),Q.Kf=function(e,t){tut(P(e,36),t)},L(PR,`LabelAndNodeSizeProcessor`,1606),q(1607,1,vF,Nte),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`LabelAndNodeSizeProcessor/lambda$0$Type`,1607),q(1608,1,vF,Pte),Q.Mb=function(e){return P(e,10).k==(DA(),GJ)},L(PR,`LabelAndNodeSizeProcessor/lambda$1$Type`,1608),q(1609,1,$P,wke),Q.Cd=function(e){Hbe(this.b,this.a,this.c,P(e,10))},Q.a=!1,Q.c=!1,L(PR,`LabelAndNodeSizeProcessor/lambda$2$Type`,1609),q(1610,1,DR,due),Q.Kf=function(e,t){Lht(P(e,36),t)};var POt;L(PR,`LabelDummyInserter`,1610),q(1611,1,YI,Fte),Q.Lb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),o8))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),o8))},L(PR,`LabelDummyInserter/1`,1611),q(1612,1,DR,Ate),Q.Kf=function(e,t){ght(P(e,36),t)},L(PR,`LabelDummyRemover`,1612),q(1613,1,vF,Ite),Q.Mb=function(e){return ki(Od(K(P(e,72),(mP(),y1))))},L(PR,`LabelDummyRemover/lambda$0$Type`,1613),q(1378,1,DR,fue),Q.Kf=function(e,t){rht(this,P(e,36),t)},Q.a=null;var dX;L(PR,`LabelDummySwitcher`,1378),q(293,1,{293:1},Ilt),Q.c=0,Q.d=null,Q.f=0,L(PR,`LabelDummySwitcher/LabelDummyInfo`,293),q(1379,1,{},Lte),Q.Kb=function(e){return cC(),new Mp(null,new cv(P(e,30).a,16))},L(PR,`LabelDummySwitcher/lambda$0$Type`,1379),q(1380,1,vF,Rte),Q.Mb=function(e){return cC(),P(e,10).k==(DA(),KJ)},L(PR,`LabelDummySwitcher/lambda$1$Type`,1380),q(1381,1,{},wpe),Q.Kb=function(e){return bDe(this.a,P(e,10))},L(PR,`LabelDummySwitcher/lambda$2$Type`,1381),q(1382,1,$P,Tpe),Q.Cd=function(e){iFe(this.a,P(e,293))},L(PR,`LabelDummySwitcher/lambda$3$Type`,1382),q(1383,1,GI,zte),Q.Ne=function(e,t){return $Ne(P(e,293),P(t,293))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`LabelDummySwitcher/lambda$4$Type`,1383),q(802,1,DR,Bte),Q.Kf=function(e,t){YWe(P(e,36),t)},L(PR,`LabelManagementProcessor`,802),q(1614,1,DR,Vte),Q.Kf=function(e,t){Tst(P(e,36),t)},L(PR,`LabelSideSelector`,1614),q(1622,1,DR,Hte),Q.Kf=function(e,t){_ft(P(e,36),t)},L(PR,`LayerConstraintPostprocessor`,1622),q(1623,1,DR,pue),Q.Kf=function(e,t){tit(P(e,36),t)};var fX;L(PR,`LayerConstraintPreprocessor`,1623),q(371,22,{3:1,34:1,22:1,371:1},As);var pX,mX,hX,gX,FOt=aS(PR,`LayerConstraintPreprocessor/HiddenNodeConnections`,371,eG,_Ve,Oke),IOt;q(1624,1,DR,Ute),Q.Kf=function(e,t){pmt(P(e,36),t)},L(PR,`LayerSizeAndGraphHeightCalculator`,1624),q(1625,1,DR,Wte),Q.Kf=function(e,t){Iat(P(e,36),t)},L(PR,`LongEdgeJoiner`,1625),q(1626,1,DR,Gte),Q.Kf=function(e,t){Ipt(P(e,36),t)},L(PR,`LongEdgeSplitter`,1626),q(1627,1,DR,Jxe),Q.Kf=function(e,t){egt(this,P(e,36),t)},Q.e=0,Q.f=0,Q.j=0,Q.k=0,Q.n=0,Q.o=0;var LOt,ROt;L(PR,`NodePromotion`,1627),q(1628,1,GI,Kte),Q.Ne=function(e,t){return rQe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NodePromotion/1`,1628),q(1629,1,GI,qte),Q.Ne=function(e,t){return iQe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NodePromotion/2`,1629),q(1630,1,{},Jte),Q.Kb=function(e){return P(e,42),If(),rd(),!0},Q.Fb=function(e){return this===e},L(PR,`NodePromotion/lambda$0$Type`,1630),q(1631,1,{},kpe),Q.Kb=function(e){return sRe(this.a,P(e,42))},Q.Fb=function(e){return this===e},Q.a=0,L(PR,`NodePromotion/lambda$1$Type`,1631),q(1632,1,{},Ape),Q.Kb=function(e){return oRe(this.a,P(e,42))},Q.Fb=function(e){return this===e},Q.a=0,L(PR,`NodePromotion/lambda$2$Type`,1632),q(1633,1,DR,Yte),Q.Kf=function(e,t){m_t(P(e,36),t)},L(PR,`NorthSouthPortPostprocessor`,1633),q(1634,1,DR,Xte),Q.Kf=function(e,t){Hgt(P(e,36),t)},L(PR,`NorthSouthPortPreprocessor`,1634),q(1635,1,GI,Zte),Q.Ne=function(e,t){return vXe(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NorthSouthPortPreprocessor/lambda$0$Type`,1635),q(1636,1,DR,Qte),Q.Kf=function(e,t){edt(P(e,36),t)},L(PR,`PartitionMidprocessor`,1636),q(1637,1,vF,$te),Q.Mb=function(e){return yd(P(e,10),(mP(),Y1))},L(PR,`PartitionMidprocessor/lambda$0$Type`,1637),q(1638,1,$P,jpe),Q.Cd=function(e){TIe(this.a,P(e,10))},L(PR,`PartitionMidprocessor/lambda$1$Type`,1638),q(1639,1,DR,ene),Q.Kf=function(e,t){uot(P(e,36),t)},L(PR,`PartitionPostprocessor`,1639),q(1640,1,DR,tne),Q.Kf=function(e,t){prt(P(e,36),t)},L(PR,`PartitionPreprocessor`,1640),q(1641,1,vF,nne),Q.Mb=function(e){return yd(P(e,10),(mP(),Y1))},L(PR,`PartitionPreprocessor/lambda$0$Type`,1641),q(1642,1,{},rne),Q.Kb=function(e){return new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(PR,`PartitionPreprocessor/lambda$1$Type`,1642),q(1643,1,vF,ine),Q.Mb=function(e){return C2e(P(e,18))},L(PR,`PartitionPreprocessor/lambda$2$Type`,1643),q(1644,1,$P,ane),Q.Cd=function(e){tZe(P(e,18))},L(PR,`PartitionPreprocessor/lambda$3$Type`,1644),q(1645,1,DR,yue),Q.Kf=function(e,t){Out(P(e,36),t)};var _X,zOt,BOt,VOt,vX,yX;L(PR,`PortListSorter`,1645),q(1648,1,GI,one),Q.Ne=function(e,t){return fHe(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$0$Type`,1648),q(1650,1,GI,sne),Q.Ne=function(e,t){return ydt(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$1$Type`,1650),q(1646,1,{},cne),Q.Kb=function(e){return Fw(),P(e,12).e},L(PR,`PortListSorter/lambda$2$Type`,1646),q(1647,1,{},lne),Q.Kb=function(e){return Fw(),P(e,12).g},L(PR,`PortListSorter/lambda$3$Type`,1647),q(1649,1,GI,une),Q.Ne=function(e,t){return J3e(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$4$Type`,1649),q(1651,1,DR,dne),Q.Kf=function(e,t){xit(P(e,36),t)},L(PR,`PortSideProcessor`,1651),q(1652,1,DR,fne),Q.Kf=function(e,t){llt(P(e,36),t)},L(PR,`ReversedEdgeRestorer`,1652),q(1657,1,DR,Yge),Q.Kf=function(e,t){h3e(this,P(e,36),t)},L(PR,`SelfLoopPortRestorer`,1657),q(1658,1,{},pne),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopPortRestorer/lambda$0$Type`,1658),q(1659,1,vF,mne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopPortRestorer/lambda$1$Type`,1659),q(1660,1,vF,hne),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopPortRestorer/lambda$2$Type`,1660),q(1661,1,{},gne),Q.Kb=function(e){return P(K(P(e,10),(Y(),a$)),337)},L(PR,`SelfLoopPortRestorer/lambda$3$Type`,1661),q(1662,1,$P,Dpe),Q.Cd=function(e){W9e(this.a,P(e,337))},L(PR,`SelfLoopPortRestorer/lambda$4$Type`,1662),q(805,1,$P,Kt),Q.Cd=function(e){det(P(e,105))},L(PR,`SelfLoopPortRestorer/lambda$5$Type`,805),q(1663,1,DR,_ne),Q.Kf=function(e,t){K2e(P(e,36),t)},L(PR,`SelfLoopPostProcessor`,1663),q(1664,1,{},vne),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopPostProcessor/lambda$0$Type`,1664),q(1665,1,vF,yne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopPostProcessor/lambda$1$Type`,1665),q(1666,1,vF,bne),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopPostProcessor/lambda$2$Type`,1666),q(1667,1,$P,xne),Q.Cd=function(e){M8e(P(e,10))},L(PR,`SelfLoopPostProcessor/lambda$3$Type`,1667),q(1668,1,{},Sne),Q.Kb=function(e){return new Mp(null,new cv(P(e,105).f,1))},L(PR,`SelfLoopPostProcessor/lambda$4$Type`,1668),q(1669,1,$P,Epe),Q.Cd=function(e){xVe(this.a,P(e,340))},L(PR,`SelfLoopPostProcessor/lambda$5$Type`,1669),q(1670,1,vF,Cne),Q.Mb=function(e){return!!P(e,105).i},L(PR,`SelfLoopPostProcessor/lambda$6$Type`,1670),q(1671,1,$P,Ope),Q.Cd=function(e){Z_e(this.a,P(e,105))},L(PR,`SelfLoopPostProcessor/lambda$7$Type`,1671),q(1653,1,DR,wne),Q.Kf=function(e,t){fat(P(e,36),t)},L(PR,`SelfLoopPreProcessor`,1653),q(1654,1,{},Tne),Q.Kb=function(e){return new Mp(null,new cv(P(e,105).f,1))},L(PR,`SelfLoopPreProcessor/lambda$0$Type`,1654),q(1655,1,{},Ene),Q.Kb=function(e){return P(e,340).a},L(PR,`SelfLoopPreProcessor/lambda$1$Type`,1655),q(1656,1,$P,Dne),Q.Cd=function(e){xwe(P(e,18))},L(PR,`SelfLoopPreProcessor/lambda$2$Type`,1656),q(1672,1,DR,oOe),Q.Kf=function(e,t){_9e(this,P(e,36),t)},L(PR,`SelfLoopRouter`,1672),q(1673,1,{},One),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopRouter/lambda$0$Type`,1673),q(1674,1,vF,kne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopRouter/lambda$1$Type`,1674),q(1675,1,vF,Ane),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopRouter/lambda$2$Type`,1675),q(1676,1,{},jne),Q.Kb=function(e){return P(K(P(e,10),(Y(),a$)),337)},L(PR,`SelfLoopRouter/lambda$3$Type`,1676),q(1677,1,$P,Sxe),Q.Cd=function(e){aIe(this.a,this.b,P(e,337))},L(PR,`SelfLoopRouter/lambda$4$Type`,1677),q(1678,1,DR,Mne),Q.Kf=function(e,t){ist(P(e,36),t)},L(PR,`SemiInteractiveCrossMinProcessor`,1678),q(1679,1,vF,Nne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SemiInteractiveCrossMinProcessor/lambda$0$Type`,1679),q(1680,1,vF,Pne),Q.Mb=function(e){return iNe(P(e,10))._b((mP(),n0))},L(PR,`SemiInteractiveCrossMinProcessor/lambda$1$Type`,1680),q(1681,1,GI,Fne),Q.Ne=function(e,t){return $Je(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`SemiInteractiveCrossMinProcessor/lambda$2$Type`,1681),q(1682,1,{},Ine),Q.Ve=function(e,t){return EIe(P(e,10),P(t,10))},L(PR,`SemiInteractiveCrossMinProcessor/lambda$3$Type`,1682),q(1684,1,DR,Lne),Q.Kf=function(e,t){tpt(P(e,36),t)},L(PR,`SortByInputModelProcessor`,1684),q(1685,1,vF,Rne),Q.Mb=function(e){return P(e,12).g.c.length!=0},L(PR,`SortByInputModelProcessor/lambda$0$Type`,1685),q(1686,1,$P,Mpe),Q.Cd=function(e){xet(this.a,P(e,12))},L(PR,`SortByInputModelProcessor/lambda$1$Type`,1686),q(1759,817,{},oYe),Q.df=function(e){var t,n,r,i;switch(this.c=e,this.a.g){case 2:t=new T,To(hg(new Mp(null,new cv(this.c.a.b,16)),new Qne),new Mxe(this,t)),ZA(this,new Bne),Dx(t,new Vne),t.c.length=0,To(hg(new Mp(null,new cv(this.c.a.b,16)),new Hne),new Ppe(t)),ZA(this,new Une),Dx(t,new Wne),t.c.length=0,n=vwe(sC(_g(new Mp(null,new cv(this.c.a.b,16)),new Fpe(this))),new Gne),To(new Mp(null,new cv(this.c.a.a,16)),new Txe(n,t)),ZA(this,new qne),Dx(t,new Jne),t.c.length=0;break;case 3:r=new T,ZA(this,new zne),i=vwe(sC(_g(new Mp(null,new cv(this.c.a.b,16)),new Npe(this))),new Kne),To(hg(new Mp(null,new cv(this.c.a.b,16)),new Yne),new Dxe(i,r)),ZA(this,new Xne),Dx(r,new Zne),r.c.length=0;break;default:throw E(new Cge)}},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation`,1759),q(1760,1,YI,zne),Q.Lb=function(e){return j(P(e,60).g,154)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$0$Type`,1760),q(1761,1,{},Npe),Q.Ye=function(e){return Btt(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$1$Type`,1761),q(1769,1,yF,Cxe),Q.de=function(){zk(this.a,this.b,-1)},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$10$Type`,1769),q(1771,1,YI,Bne),Q.Lb=function(e){return j(P(e,60).g,154)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$11$Type`,1771),q(1772,1,$P,Vne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$12$Type`,1772),q(1773,1,vF,Hne),Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$13$Type`,1773),q(1775,1,$P,Ppe),Q.Cd=function(e){A1e(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$14$Type`,1775),q(1774,1,yF,Oxe),Q.de=function(){zk(this.b,this.a,-1)},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$15$Type`,1774),q(1776,1,YI,Une),Q.Lb=function(e){return j(P(e,60).g,10)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$16$Type`,1776),q(1777,1,$P,Wne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$17$Type`,1777),q(1778,1,{},Fpe),Q.Ye=function(e){return Vtt(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$18$Type`,1778),q(1779,1,{},Gne),Q.We=function(){return 0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$19$Type`,1779),q(1762,1,{},Kne),Q.We=function(){return 0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$2$Type`,1762),q(1781,1,$P,Txe),Q.Cd=function(e){TNe(this.a,this.b,P(e,316))},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$20$Type`,1781),q(1780,1,yF,Exe),Q.de=function(){wit(this.a,this.b,-1)},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$21$Type`,1780),q(1782,1,YI,qne),Q.Lb=function(e){return P(e,60),!0},Q.Fb=function(e){return this===e},Q.Mb=function(e){return P(e,60),!0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$22$Type`,1782),q(1783,1,$P,Jne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$23$Type`,1783),q(1763,1,vF,Yne),Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$3$Type`,1763),q(1765,1,$P,Dxe),Q.Cd=function(e){ENe(this.a,this.b,P(e,60))},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$4$Type`,1765),q(1764,1,yF,kxe),Q.de=function(){zk(this.b,this.a,-1)},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$5$Type`,1764),q(1766,1,YI,Xne),Q.Lb=function(e){return P(e,60),!0},Q.Fb=function(e){return this===e},Q.Mb=function(e){return P(e,60),!0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$6$Type`,1766),q(1767,1,$P,Zne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$7$Type`,1767),q(1768,1,vF,Qne),Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$8$Type`,1768),q(1770,1,$P,Mxe),Q.Cd=function(e){oqe(this.a,this.b,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$9$Type`,1770),q(1586,1,DR,oEe),Q.Kf=function(e,t){Upt(this,P(e,36),t)};var HOt;L(RR,`HorizontalGraphCompactor`,1586),q(1587,1,{},Ipe),Q.ff=function(e,t){var n,r,i;return zb(e,t)||(n=Ev(e),r=Ev(t),n&&n.k==(DA(),GJ)||r&&r.k==(DA(),GJ))?0:(i=P(K(this.a.a,(Y(),o$)),312),rEe(i,n?n.k:(DA(),qJ),r?r.k:(DA(),qJ)))},Q.gf=function(e,t){var n,r,i;return zb(e,t)?1:(n=Ev(e),r=Ev(t),i=P(K(this.a.a,(Y(),o$)),312),iEe(i,n?n.k:(DA(),qJ),r?r.k:(DA(),qJ)))},L(RR,`HorizontalGraphCompactor/1`,1587),q(1588,1,{},$ne),Q.ef=function(e,t){return Lo(),e.a.i==0},L(RR,`HorizontalGraphCompactor/lambda$0$Type`,1588),q(1589,1,{},Lpe),Q.ef=function(e,t){return AIe(this.a,e,t)},L(RR,`HorizontalGraphCompactor/lambda$1$Type`,1589),q(1730,1,{},iKe);var UOt,WOt;L(RR,`LGraphToCGraphTransformer`,1730),q(1738,1,vF,ere),Q.Mb=function(e){return e!=null},L(RR,`LGraphToCGraphTransformer/0methodref$nonNull$Type`,1738),q(1731,1,{},tre),Q.Kb=function(e){return Lf(),PE(K(P(P(e,60).g,10),(Y(),WQ)))},L(RR,`LGraphToCGraphTransformer/lambda$0$Type`,1731),q(1732,1,{},nre),Q.Kb=function(e){return Lf(),T$e(P(P(e,60).g,154))},L(RR,`LGraphToCGraphTransformer/lambda$1$Type`,1732),q(1741,1,vF,rre),Q.Mb=function(e){return Lf(),j(P(e,60).g,10)},L(RR,`LGraphToCGraphTransformer/lambda$10$Type`,1741),q(1742,1,$P,ire),Q.Cd=function(e){HIe(P(e,60))},L(RR,`LGraphToCGraphTransformer/lambda$11$Type`,1742),q(1743,1,vF,are),Q.Mb=function(e){return Lf(),j(P(e,60).g,154)},L(RR,`LGraphToCGraphTransformer/lambda$12$Type`,1743),q(1747,1,$P,ore),Q.Cd=function(e){w$e(P(e,60))},L(RR,`LGraphToCGraphTransformer/lambda$13$Type`,1747),q(1744,1,$P,Rpe),Q.Cd=function(e){ACe(this.a,P(e,8))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$14$Type`,1744),q(1745,1,$P,zpe),Q.Cd=function(e){MCe(this.a,P(e,116))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$15$Type`,1745),q(1746,1,$P,Bpe),Q.Cd=function(e){jCe(this.a,P(e,8))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$16$Type`,1746),q(1748,1,{},sre),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$17$Type`,1748),q(1749,1,vF,cre),Q.Mb=function(e){return Lf(),gy(P(e,18))},L(RR,`LGraphToCGraphTransformer/lambda$18$Type`,1749),q(1750,1,$P,Vpe),Q.Cd=function(e){mKe(this.a,P(e,18))},L(RR,`LGraphToCGraphTransformer/lambda$19$Type`,1750),q(1734,1,$P,Hpe),Q.Cd=function(e){qze(this.a,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$2$Type`,1734),q(1751,1,{},lre),Q.Kb=function(e){return Lf(),new Mp(null,new cv(P(e,30).a,16))},L(RR,`LGraphToCGraphTransformer/lambda$20$Type`,1751),q(1752,1,{},ure),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$21$Type`,1752),q(1753,1,{},dre),Q.Kb=function(e){return Lf(),P(K(P(e,18),(Y(),l$)),15)},L(RR,`LGraphToCGraphTransformer/lambda$22$Type`,1753),q(1754,1,vF,fre),Q.Mb=function(e){return aEe(P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$23$Type`,1754),q(1755,1,$P,Upe),Q.Cd=function(e){Ett(this.a,P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$24$Type`,1755),q(1733,1,$P,Nxe),Q.Cd=function(e){YVe(this.a,this.b,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$3$Type`,1733),q(1735,1,{},pre),Q.Kb=function(e){return Lf(),new Mp(null,new cv(P(e,30).a,16))},L(RR,`LGraphToCGraphTransformer/lambda$4$Type`,1735),q(1736,1,{},mre),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$5$Type`,1736),q(1737,1,{},hre),Q.Kb=function(e){return Lf(),P(K(P(e,18),(Y(),l$)),15)},L(RR,`LGraphToCGraphTransformer/lambda$6$Type`,1737),q(1739,1,$P,Wpe),Q.Cd=function(e){Htt(this.a,P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$8$Type`,1739),q(1740,1,$P,Pxe),Q.Cd=function(e){Swe(this.a,this.b,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$9$Type`,1740),q(1729,1,{},gre),Q.cf=function(e){var t,n,r,i,a;for(this.a=e,this.d=new Xr,this.c=V(YK,FP,125,this.a.a.a.c.length,0,1),this.b=0,n=new w(this.a.a.a);n.a=g&&(M(o,G(d)),y=r.Math.max(y,b[d-1]-f),c+=h,_+=b[d-1]-_,f=b[d-1],h=l[d]),h=r.Math.max(h,l[d]),++d;c+=h}m=r.Math.min(1/y,1/t.b/c),m>i&&(i=m,n=o)}return n},Q.pg=function(){return!1},L(KR,`MSDCutIndexHeuristic`,816),q(1683,1,DR,iie),Q.Kf=function(e,t){Cft(P(e,36),t)},L(KR,`SingleEdgeGraphWrapper`,1683),q(232,22,{3:1,34:1,22:1,232:1},Fs);var UX,WX,GX,KX,qX,JX,YX=aS(qR,`CenterEdgeLabelPlacementStrategy`,232,eG,iGe,Mke),nkt;q(431,22,{3:1,34:1,22:1,431:1},Lxe);var XX,ZX,QX=aS(qR,`ConstraintCalculationStrategy`,431,eG,mLe,Nke),rkt;q(322,22,{3:1,34:1,22:1,322:1,188:1,196:1},Is),Q.dg=function(){return int(this)},Q.qg=function(){return int(this)};var $X,eZ,tZ,nZ=aS(qR,`CrossingMinimizationStrategy`,322,eG,QRe,Pke),ikt;q(351,22,{3:1,34:1,22:1,351:1},Ls);var rZ,iZ,aZ,oZ=aS(qR,`CuttingStrategy`,351,eG,$Re,Fke),akt;q(348,22,{3:1,34:1,22:1,348:1,188:1,196:1},Rs),Q.dg=function(){return fit(this)},Q.qg=function(){return fit(this)};var sZ,cZ,lZ,uZ,dZ,fZ=aS(qR,`CycleBreakingStrategy`,348,eG,oUe,Ike),okt;q(428,22,{3:1,34:1,22:1,428:1},zs);var pZ,mZ,hZ=aS(qR,`DirectionCongruency`,428,eG,pLe,Lke),skt;q(460,22,{3:1,34:1,22:1,460:1},Bs);var gZ,_Z,vZ,ckt=aS(qR,`EdgeConstraint`,460,eG,eze,Wke),lkt;q(283,22,{3:1,34:1,22:1,283:1},Vs);var yZ,bZ,xZ,SZ,CZ,wZ,TZ=aS(qR,`EdgeLabelSideSelection`,283,eG,tGe,Gke),ukt;q(488,22,{3:1,34:1,22:1,488:1},Hs);var EZ,DZ,OZ=aS(qR,`EdgeStraighteningStrategy`,488,eG,xLe,Kke),dkt;q(281,22,{3:1,34:1,22:1,281:1},Us);var kZ,AZ,jZ,MZ,NZ,PZ,FZ=aS(qR,`FixedAlignment`,281,eG,nGe,Uke),fkt;q(282,22,{3:1,34:1,22:1,282:1},Ws);var IZ,LZ,RZ,zZ,BZ,VZ,HZ=aS(qR,`GraphCompactionStrategy`,282,eG,rGe,Rke),pkt;q(259,22,{3:1,34:1,22:1,259:1},Gs);var UZ,WZ,GZ,KZ,qZ,JZ,YZ,XZ,ZZ,QZ,$Z=aS(qR,`GraphProperties`,259,eG,_Ye,zke),mkt;q(299,22,{3:1,34:1,22:1,299:1},Ks);var eQ,tQ,nQ,rQ=aS(qR,`GreedySwitchType`,299,eG,tze,Bke),hkt;q(311,22,{3:1,34:1,22:1,311:1},qs);var iQ,aQ,oQ,gkt=aS(qR,`InLayerConstraint`,311,eG,nze,Vke),_kt;q(429,22,{3:1,34:1,22:1,429:1},Js);var sQ,cQ,lQ=aS(qR,`InteractiveReferencePoint`,429,eG,fLe,Hke),vkt,uQ,dQ,fQ,pQ,mQ,hQ,gQ,_Q,vQ,yQ,bQ,xQ,SQ,CQ,wQ,TQ,EQ,DQ,OQ,kQ,AQ,jQ,MQ,NQ,PQ,FQ,IQ,LQ,RQ,zQ,BQ,VQ,HQ,UQ,WQ,GQ,KQ,qQ,JQ,YQ,XQ,ZQ,QQ,$Q,e$,t$,n$,r$,i$,a$,o$,s$,c$,l$,u$,d$,f$,p$;q(171,22,{3:1,34:1,22:1,171:1},Ys);var m$,h$,g$,_$,v$,y$=aS(qR,`LayerConstraint`,171,eG,cUe,qke),ykt;q(859,1,nL,Eue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,XR),``),`Direction Congruency`),`Specifies how drawings of the same graph with different layout directions compare to each other: either a natural reading direction is preserved or the drawings are rotated versions of each other.`),k$),(VA(),B3)),hZ),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZR),``),`Feedback Edges`),`Whether feedback edges should be highlighted by routing around the nodes.`),(rd(),!1)),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QR),``),`Interactive Reference Point`),`Determines which point of a node is considered by interactive layout phases.`),F$),B3),lQ),sE(F3)))),wv(e,QR,oz,pAt),wv(e,QR,gz,fAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,$R),``),`Merge Edges`),`Edges that have no ports are merged so they touch the connected nodes at the same points. When this option is disabled, one port is created for each edge directly connected to a node. When it is enabled, all such incoming edges share an input port, and all outgoing edges share an output port.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ez),``),`Merge Hierarchy-Crossing Edges`),`If hierarchical layout is active, hierarchy-crossing edges use as few hierarchical ports as possible. They are broken by the algorithm, with hierarchical ports inserted as required. Usually, one such port is created for each edge at each hierarchy crossing point. With this option set to true, we try to create as few hierarchical ports as possible in the process. In particular, all edges that form a hyperedge can share a port.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Hve(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tz),``),`Allow Non-Flow Ports To Switch Sides`),`Specifies whether non-flow ports may switch sides if their node's port constraints are either FIXED_SIDE or FIXED_ORDER. A non-flow port is a port on a side that is not part of the currently configured layout flow. For instance, given a left-to-right layout direction, north and south ports would be considered non-flow ports. Further note that the underlying criterium whether to switch sides or not solely relies on the minimization of edge crossings. Hence, edge length and other aesthetics criteria are not addressed.`),!1),R3),bG),sE(I3)),U(O(LG,1),X,2,6,[`org.eclipse.elk.layered.northOrSouthPort`])))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,nz),``),`Port Sorting Strategy`),`Only relevant for nodes with FIXED_SIDE port constraints. Determines the way a node's ports are distributed on the sides of a node if their order is not prescribed. The option is set on parent nodes.`),U$),B3),YMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rz),``),`Thoroughness`),`How much effort should be spent to produce a nice layout.`),G(7)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iz),``),`Add Unnecessary Bendpoints`),`Adds bend points even if an edge does not change direction. If true, each long edge dummy will contribute a bend point to its edges and hierarchy-crossing edges will always get a bend point where they cross hierarchy boundaries. By default, bend points are only added where an edge changes direction.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,az),``),`Generate Position and Layer IDs`),`If enabled position id and layer id are generated, which are usually only used internally when setting the interactiveLayout option. This option should be specified on the root node.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oz),`cycleBreaking`),`Cycle Breaking Strategy`),`Strategy for cycle breaking. Cycle breaking looks for cycles in the graph and determines which edges to reverse to break the cycles. Reversed edges will end up pointing to the opposite direction of regular edges (that is, reversed edges will point left if edges usually point right).`),O$),B3),fZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sz),vB),`Node Layering Strategy`),`Strategy for node layering.`),R$),B3),jMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cz),vB),`Layer Constraint`),`Determines a constraint on the placement of the node regarding the layering.`),I$),B3),y$),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lz),vB),`Layer Choice Constraint`),"Allows to set a constraint regarding the layer placement of a node. Let i be the value of teh constraint. Assumed the drawing has n layers and i < n. If set to i, it expresses that the node should be placed in i-th layer. Should i>=n be true then the node is placed in the last layer of the drawing. Note that this option is not part of any of ELK Layered's default configurations but is only evaluated as part of the `InteractiveLayeredGraphVisitor`, which must be applied manually or used via the `DiagramLayoutEngine."),null),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uz),vB),`Layer ID`),`Layer identifier that was calculated by ELK Layered for a node. This is only generated if interactiveLayot or generatePositionAndLayerIds is set.`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dz),Hbt),`Upper Bound On Width [MinWidth Layerer]`),`Defines a loose upper bound on the width of the MinWidth layerer. If set to '-1' multiple values are tested and the best result is selected.`),G(4)),H3),DG),sE(F3)))),wv(e,dz,sz,bAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fz),Hbt),`Upper Layer Estimation Scaling Factor [MinWidth Layerer]`),`Multiplied with Upper Bound On Width for defining an upper bound on the width of layers which haven't been determined yet, but whose maximum width had been (roughly) estimated by the MinWidth algorithm. Compensates for too high estimations. If set to '-1' multiple values are tested and the best result is selected.`),G(2)),H3),DG),sE(F3)))),wv(e,fz,sz,SAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pz),Ubt),`Node Promotion Strategy`),`Reduces number of dummy nodes after layering phase (if possible).`),L$),B3),WMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mz),Ubt),`Max Node Promotion Iterations`),`Limits the number of iterations for node promotion.`),G(0)),H3),DG),sE(F3)))),wv(e,mz,pz,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hz),`layering.coffmanGraham`),`Layer Bound`),`The maximum number of nodes allowed per layer.`),G(AP)),H3),DG),sE(F3)))),wv(e,hz,sz,hAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gz),yB),`Crossing Minimization Strategy`),`Strategy for crossing minimization.`),D$),B3),nZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_z),yB),`Force Node Model Order`),`The node order given by the model does not change to produce a better layout. E.g. if node A is before node B in the model this is not changed during crossing minimization. This assumes that the node model order is already respected before crossing minimization. This can be achieved by setting considerModelOrder.strategy to NODES_AND_EDGES.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,vz),yB),`Hierarchical Sweepiness`),`How likely it is to use cross-hierarchy (1) vs bottom-up (-1).`),.1),z3),TG),sE(F3)))),wv(e,vz,bB,zkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,yz),yB),`Semi-Interactive Crossing Minimization`),`Preserves the order of nodes within a layer but still minimizes crossings between edges connecting long edge dummies. Derives the desired order from positions specified by the 'org.eclipse.elk.position' layout option. Requires a crossing minimization strategy that is able to process 'in-layer' constraints.`),!1),R3),bG),sE(F3)))),wv(e,yz,gz,Gkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bz),yB),`In Layer Predecessor of`),`Allows to set a constraint which specifies of which node the current node is the predecessor. If set to 's' then the node is the predecessor of 's' and is in the same layer`),null),W3),LG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xz),yB),`In Layer Successor of`),`Allows to set a constraint which specifies of which node the current node is the successor. If set to 's' then the node is the successor of 's' and is in the same layer`),null),W3),LG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Sz),yB),`Position Choice Constraint`),"Allows to set a constraint regarding the position placement of a node in a layer. Assumed the layer in which the node placed includes n other nodes and i < n. If set to i, it expresses that the node should be placed at the i-th position. Should i>=n be true then the node is placed at the last position in the layer. Note that this option is not part of any of ELK Layered's default configurations but is only evaluated as part of the `InteractiveLayeredGraphVisitor`, which must be applied manually or used via the `DiagramLayoutEngine."),null),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Cz),yB),`Position ID`),`Position within a layer that was determined by ELK Layered for a node. This is only generated if interactiveLayot or generatePositionAndLayerIds is set.`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,wz),Wbt),`Greedy Switch Activation Threshold`),`By default it is decided automatically if the greedy switch is activated or not. The decision is based on whether the size of the input graph (without dummy nodes) is smaller than the value of this option. A '0' enforces the activation.`),G(40)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Tz),Wbt),`Greedy Switch Crossing Minimization`),`Greedy Switch strategy for crossing minimization. The greedy switch heuristic is executed after the regular crossing minimization as a post-processor. Note that if 'hierarchyHandling' is set to 'INCLUDE_CHILDREN', the 'greedySwitchHierarchical.type' option must be used.`),E$),B3),rQ),sE(F3)))),wv(e,Tz,gz,Lkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Ez),`crossingMinimization.greedySwitchHierarchical`),`Greedy Switch Crossing Minimization (hierarchical)`),`Activates the greedy switch heuristic in case hierarchical layout is used. The differences to the non-hierarchical case (see 'greedySwitch.type') are: 1) greedy switch is inactive by default, 3) only the option value set on the node at which hierarchical layout starts is relevant, and 2) if it's activated by the user, it properly addresses hierarchy-crossing edges.`),T$),B3),rQ),sE(F3)))),wv(e,Ez,gz,Pkt),wv(e,Ez,bB,Fkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Dz),Gbt),`Node Placement Strategy`),`Strategy for node placement.`),H$),B3),RMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,Oz),Gbt),`Favor Straight Edges Over Balancing`),`Favor straight edges over a balanced node placement. The default behavior is determined automatically based on the used 'edgeRouting'. For an orthogonal style it is set to true, for all other styles to false.`),R3),bG),sE(F3)))),wv(e,Oz,Dz,NAt),wv(e,Oz,Dz,PAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,kz),Kbt),`BK Edge Straightening`),`Specifies whether the Brandes Koepf node placer tries to increase the number of straight edges at the expense of diagram size. There is a subtle difference to the 'favorStraightEdges' option, which decides whether a balanced placement of the nodes is desired, or not. In bk terms this means combining the four alignments into a single balanced one, or not. This option on the other hand tries to straighten additional edges during the creation of each of the four alignments.`),z$),B3),OZ),sE(F3)))),wv(e,kz,Dz,kAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Az),Kbt),`BK Fixed Alignment`),`Tells the BK node placer to use a certain alignment (out of its four) instead of the one producing the smallest height, or the combination of all four.`),B$),B3),FZ),sE(F3)))),wv(e,Az,Dz,jAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jz),`nodePlacement.linearSegments`),`Linear Segments Deflection Dampening`),`Dampens the movement of nodes to keep the diagram from getting too large.`),.3),z3),TG),sE(F3)))),wv(e,jz,Dz,IAt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,Mz),`nodePlacement.networkSimplex`),`Node Flexibility`),`Aims at shorter and straighter edges. Two configurations are possible: (a) allow ports to move freely on the side they are assigned to (the order is always defined beforehand), (b) additionally allow to enlarge a node wherever it helps. If this option is not configured for a node, the 'nodeFlexibility.default' value is used, which is specified for the node's parent.`),B3),B0),sE(P3)))),wv(e,Mz,Dz,BAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Nz),`nodePlacement.networkSimplex.nodeFlexibility`),`Node Flexibility Default`),`Default value of the 'nodeFlexibility' option for the children of a hierarchical node.`),V$),B3),B0),sE(F3)))),wv(e,Nz,Dz,zAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Pz),qbt),`Self-Loop Distribution`),`Alter the distribution of the loops around the node. It only takes effect for PortConstraints.FREE.`),M$),B3),tNt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Fz),qbt),`Self-Loop Ordering`),`Alter the ordering of the loops they can either be stacked or sequenced. It only takes effect for PortConstraints.FREE.`),N$),B3),rNt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Iz),`edgeRouting.splines`),`Spline Routing Mode`),`Specifies the way control points are assembled for each individual edge. CONSERVATIVE ensures that edges are properly routed around the nodes but feels rather orthogonal at times. SLOPPY uses fewer control points to obtain curvier edge routes but may result in edges overlapping nodes.`),P$),B3),oNt),sE(F3)))),wv(e,Iz,xB,nAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Lz),`edgeRouting.splines.sloppy`),`Sloppy Spline Layer Spacing Factor`),`Spacing factor for routing area between layers when using sloppy spline routing.`),.2),z3),TG),sE(F3)))),wv(e,Lz,xB,iAt),wv(e,Lz,Iz,aAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Rz),`edgeRouting.polyline`),`Sloped Edge Zone Width`),`Width of the strip to the left and to the right of each layer where the polyline edge router is allowed to refrain from ensuring that edges are routed horizontally. This prevents awkward bend points for nodes that extent almost to the edge of their layer.`),2),z3),TG),sE(F3)))),wv(e,Rz,xB,Qkt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,zz),SB),`Spacing Base Value`),`An optional base value for all other layout options of the 'spacing' group. It can be used to conveniently alter the overall 'spaciousness' of the drawing. Whenever an explicit value is set for the other layout options, this base value will have no effect. The base value is not inherited, i.e. it must be set for each hierarchical node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Bz),SB),`Edge Node Between Layers Spacing`),`The spacing to be preserved between nodes and edges that are routed next to the node's layer. For the spacing between nodes and edges that cross the node's layer 'spacing.edgeNode' is used.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Vz),SB),`Edge Edge Between Layer Spacing`),`Spacing to be preserved between pairs of edges that are routed between the same pair of layers. Note that 'spacing.edgeEdge' is used for the spacing between pairs of edges crossing the same layer.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Hz),SB),`Node Node Between Layers Spacing`),`The spacing to be preserved between any pair of nodes of two adjacent layers. Note that 'spacing.nodeNode' is used for the spacing between nodes within the layer itself.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Uz),CB),`Direction Priority`),`Defines how important it is to have a certain edge point into the direction of the overall layout. This option is evaluated during the cycle breaking phase.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Wz),CB),`Shortness Priority`),`Defines how important it is to keep an edge as short as possible. This option is evaluated during the layering phase.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Gz),CB),`Straightness Priority`),`Defines how important it is to keep an edge straight, i.e. aligned with one of the two axes. This option is evaluated during node placement.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Kz),wB),Gyt),`Tries to further compact components (disconnected sub-graphs).`),!1),R3),bG),sE(F3)))),wv(e,Kz,eR,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,qz),Jbt),`Post Compaction Strategy`),Ybt),x$),B3),HZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Jz),Jbt),`Post Compaction Constraint Calculation`),Ybt),b$),B3),QX),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Yz),TB),`High Degree Node Treatment`),`Makes room around high degree nodes to place leafs and trees.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Xz),TB),`High Degree Node Threshold`),`Whether a node is considered to have a high degree.`),G(16)),H3),DG),sE(F3)))),wv(e,Xz,Yz,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Zz),TB),`High Degree Node Maximum Tree Height`),`Maximum height of a subtree connected to a high degree node to be moved to separate layers.`),G(5)),H3),DG),sE(F3)))),wv(e,Zz,Yz,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Qz),EB),`Graph Wrapping Strategy`),`For certain graphs and certain prescribed drawing areas it may be desirable to split the laid out graph into chunks that are placed side by side. The edges that connect different chunks are 'wrapped' around from the end of one chunk to the start of the other chunk. The points between the chunks are referred to as 'cuts'.`),K$),B3),fNt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,$z),EB),`Additional Wrapped Edges Spacing`),`To visually separate edges that are wrapped from regularly routed edges an additional spacing value can be specified in form of this layout option. The spacing is added to the regular edgeNode spacing.`),10),z3),TG),sE(F3)))),wv(e,$z,Qz,$At),wv(e,$z,Qz,ejt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,eB),EB),`Correction Factor for Wrapping`),`At times and for certain types of graphs the executed wrapping may produce results that are consistently biased in the same fashion: either wrapping to often or to rarely. This factor can be used to correct the bias. Internally, it is simply multiplied with the 'aspect ratio' layout option.`),1),z3),TG),sE(F3)))),wv(e,eB,Qz,njt),wv(e,eB,Qz,rjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tB),Xbt),`Cutting Strategy`),`The strategy by which the layer indexes are determined at which the layering crumbles into chunks.`),G$),B3),oZ),sE(F3)))),wv(e,tB,Qz,ljt),wv(e,tB,Qz,ujt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,nB),Xbt),`Manually Specified Cuts`),`Allows the user to specify her own cuts for a certain graph.`),U3),JW),sE(F3)))),wv(e,nB,tB,ajt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rB),`wrapping.cutting.msd`),`MSD Freedom`),`The MSD cutting strategy starts with an initial guess on the number of chunks the graph should be split into. The freedom specifies how much the strategy may deviate from this guess. E.g. if an initial number of 3 is computed, a freedom of 1 allows 2, 3, and 4 cuts.`),W$),H3),DG),sE(F3)))),wv(e,rB,tB,sjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iB),Zbt),`Validification Strategy`),`When wrapping graphs, one can specify indices that are not allowed as split points. The validification strategy makes sure every computed split point is allowed.`),q$),B3),uNt),sE(F3)))),wv(e,iB,Qz,Sjt),wv(e,iB,Qz,Cjt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,aB),Zbt),`Valid Indices for Wrapping`),null),U3),JW),sE(F3)))),wv(e,aB,Qz,yjt),wv(e,aB,Qz,bjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oB),DB),`Improve Cuts`),`For general graphs it is important that not too many edges wrap backwards. Thus a compromise between evenly-distributed cuts and the total number of cut edges is sought.`),!0),R3),bG),sE(F3)))),wv(e,oB,Qz,mjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sB),DB),`Distance Penalty When Improving Cuts`),null),2),z3),TG),sE(F3)))),wv(e,sB,Qz,fjt),wv(e,sB,oB,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cB),DB),`Improve Wrapped Edges`),`The initial wrapping is performed in a very simple way. As a consequence, edges that wrap from one chunk to another may be unnecessarily long. Activating this option tries to shorten such edges.`),!0),R3),bG),sE(F3)))),wv(e,cB,Qz,gjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lB),OB),`Edge Label Side Selection`),`Method to decide on edge label sides.`),j$),B3),TZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uB),OB),`Edge Center Label Placement Strategy`),`Determines in which layer center labels of long edges should be placed.`),A$),B3),YX),Zp(F3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dB),kB),`Consider Model Order`),`Preserves the order of nodes and edges in the model file if this does not lead to additional edge crossings. Depending on the strategy this is not always possible since the node and edge order might be conflicting.`),w$),B3),qMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fB),kB),`Consider Port Order`),`If disabled the port order of output ports is derived from the edge order and input ports are ordered by their incoming connections. If enabled all ports are ordered by the port model order.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pB),kB),`No Model Order`),`Set on a node to not set a model order for this node even though it is a real node.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mB),kB),`Consider Model Order for Components`),`If set to NONE the usual ordering strategy (by cumulative node priority and size of nodes) is used. INSIDE_PORT_SIDES orders the components with external ports only inside the groups with the same port side. FORCE_MODEL_ORDER enforces the mode order on components. This option might produce bad alignments and sub optimal drawings in terms of used area since the ordering should be respected.`),S$),B3),zJ),sE(F3)))),wv(e,mB,eR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hB),kB),`Long Edge Ordering Strategy`),`Indicates whether long edges are sorted under, over, or equal to nodes that have no connection to a previous layer in a left-to-right or right-to-left layout. Under and over changes to right and left in a vertical layout.`),C$),B3),PMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gB),kB),`Crossing Counter Node Order Influence`),`Indicates with what percentage (1 for 100%) violations of the node model order are weighted against the crossings e.g. a value of 0.5 means two model order violations are as important as on edge crossing. This allows some edge crossings in favor of preserving the model order. It is advised to set this value to a very small positive value (e.g. 0.001) to have minimal crossing and a optimal node order. Defaults to no influence (0).`),0),z3),TG),sE(F3)))),wv(e,gB,dB,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_B),kB),`Crossing Counter Port Order Influence`),`Indicates with what percentage (1 for 100%) violations of the port model order are weighted against the crossings e.g. a value of 0.5 means two model order violations are as important as on edge crossing. This allows some edge crossings in favor of preserving the model order. It is advised to set this value to a very small positive value (e.g. 0.001) to have minimal crossing and a optimal port order. Defaults to no influence (0).`),0),z3),TG),sE(F3)))),wv(e,_B,dB,null),Ivt((new Due,e))};var bkt,xkt,Skt,b$,Ckt,x$,wkt,S$,Tkt,Ekt,Dkt,C$,Okt,kkt,Akt,w$,jkt,Mkt,Nkt,T$,Pkt,Fkt,Ikt,E$,Lkt,Rkt,zkt,Bkt,Vkt,Hkt,Ukt,Wkt,Gkt,Kkt,D$,qkt,O$,Jkt,k$,Ykt,A$,Xkt,j$,Zkt,Qkt,$kt,M$,eAt,N$,tAt,P$,nAt,rAt,iAt,aAt,oAt,sAt,cAt,lAt,uAt,dAt,F$,fAt,pAt,mAt,hAt,gAt,_At,I$,vAt,yAt,bAt,xAt,SAt,CAt,wAt,L$,TAt,R$,EAt,DAt,OAt,z$,kAt,AAt,B$,jAt,MAt,NAt,PAt,FAt,IAt,LAt,RAt,V$,zAt,BAt,VAt,H$,HAt,U$,UAt,WAt,GAt,KAt,qAt,JAt,YAt,XAt,ZAt,QAt,$At,ejt,tjt,njt,rjt,ijt,ajt,ojt,W$,sjt,cjt,G$,ljt,ujt,djt,fjt,pjt,mjt,hjt,gjt,_jt,K$,vjt,yjt,bjt,xjt,q$,Sjt,Cjt;L(qR,`LayeredMetaDataProvider`,859),q(998,1,nL,Due),Q.hf=function(e){Ivt(e)};var J$,Y$,X$,Z$,Q$,$$,e1,t1,n1,r1,i1,a1,o1,s1,c1,l1,u1,d1,f1,wjt,Tjt,Ejt,Djt,p1,m1,h1,g1,Ojt,_1,kjt,Ajt,v1,y1,b1,x1,S1,jjt,Mjt,Njt,C1,w1,Pjt,T1,E1,Fjt,D1,Ijt,Ljt,Rjt,O1,k1,A1,zjt,Bjt,j1,Vjt,Hjt,M1,N1,Ujt,Wjt,Gjt,P1,F1,I1,Kjt,qjt,L1,R1,Jjt,z1,B1,Yjt,V1,H1,U1,W1,G1,K1,q1,J1,Xjt,Zjt,Qjt,Y1,$jt,eMt,tMt,nMt,rMt,X1,Z1,Q1,$1,iMt,e0,aMt,t0,oMt,n0,sMt,r0,cMt,i0,lMt,uMt,a0,o0,dMt,s0,c0,l0,u0,d0,f0,p0,m0,h0,g0,_0,v0,y0,b0,x0,S0,C0,fMt,pMt,mMt,hMt,gMt,w0,_Mt,vMt,yMt,bMt,T0,xMt,SMt,CMt,wMt,E0,D0;L(qR,`LayeredOptions`,998),q(999,1,{},aie),Q.sf=function(){var e;return e=new Uge,e},Q.tf=function(e){},L(qR,`LayeredOptions/LayeredFactory`,999),q(1391,1,{}),Q.a=0;var TMt;L(gV,`ElkSpacings/AbstractSpacingsBuilder`,1391),q(792,1391,{},rD);var O0,EMt;L(qR,`LayeredSpacings/LayeredSpacingsBuilder`,792),q(265,22,{3:1,34:1,22:1,265:1,188:1,196:1},Xs),Q.dg=function(){return Rct(this)},Q.qg=function(){return Rct(this)};var k0,A0,j0,DMt,OMt,kMt,M0,N0,AMt,jMt=aS(qR,`LayeringStrategy`,265,eG,iJe,Jke),MMt;q(390,22,{3:1,34:1,22:1,390:1},Zs);var P0,NMt,F0,PMt=aS(qR,`LongEdgeOrderingStrategy`,390,eG,rze,Yke),FMt;q(203,22,{3:1,34:1,22:1,203:1},Qs);var I0,L0,R0,z0,B0=aS(qR,`NodeFlexibility`,203,eG,vVe,Xke),IMt;q(323,22,{3:1,34:1,22:1,323:1,188:1,196:1},$s),Q.dg=function(){return dit(this)},Q.qg=function(){return dit(this)};var V0,H0,U0,W0,LMt,RMt=aS(qR,`NodePlacementStrategy`,323,eG,sUe,Zke),zMt;q(243,22,{3:1,34:1,22:1,243:1},ec);var BMt,G0,K0,q0,VMt,HMt,J0,UMt,Y0,X0,WMt=aS(qR,`NodePromotionStrategy`,243,eG,vYe,Qke),GMt;q(284,22,{3:1,34:1,22:1,284:1},tc);var KMt,Z0,Q0,$0,qMt=aS(qR,`OrderingStrategy`,284,eG,yVe,$ke),JMt;q(430,22,{3:1,34:1,22:1,430:1},nc);var e2,t2,YMt=aS(qR,`PortSortingStrategy`,430,eG,hLe,eAe),XMt;q(463,22,{3:1,34:1,22:1,463:1},rc);var n2,r2,i2,ZMt=aS(qR,`PortType`,463,eG,ize,tAe),QMt;q(387,22,{3:1,34:1,22:1,387:1},ic);var $Mt,a2,eNt,tNt=aS(qR,`SelfLoopDistributionStrategy`,387,eG,aze,nAe),nNt;q(349,22,{3:1,34:1,22:1,349:1},ac);var o2,s2,c2,rNt=aS(qR,`SelfLoopOrderingStrategy`,349,eG,oze,rAe),iNt;q(312,1,{312:1},Hmt),L(qR,`Spacings`,312),q(350,22,{3:1,34:1,22:1,350:1},oc);var l2,aNt,u2,oNt=aS(qR,`SplineRoutingMode`,350,eG,sze,iAe),sNt;q(352,22,{3:1,34:1,22:1,352:1},sc);var d2,cNt,lNt,uNt=aS(qR,`ValidifyStrategy`,352,eG,cze,aAe),dNt;q(388,22,{3:1,34:1,22:1,388:1},cc);var f2,p2,m2,fNt=aS(qR,`WrappingStrategy`,388,eG,lze,oAe),pNt;q(1398,1,yV,vue),Q.rg=function(e){return P(e,36),mNt},Q.Kf=function(e,t){Bpt(this,P(e,36),t)};var mNt;L(bV,`DepthFirstCycleBreaker`,1398),q(793,1,yV,bNe),Q.rg=function(e){return P(e,36),hNt},Q.Kf=function(e,t){cvt(this,P(e,36),t)},Q.sg=function(e){return P(Ep(e,VO(this.d,e.c.length)),10)};var hNt;L(bV,`GreedyCycleBreaker`,793),q(1401,793,yV,iCe),Q.sg=function(e){var t,n,r,i=null;for(t=AP,r=new w(e);r.a1&&(ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),(mP(),l1))))?iat(e,this.d,P(this,669)):(Vg(),hu(e,this.d)),uXe(this.e,e))},Q.lg=function(e,t,n,r){var i,a,o,s,c,l,u;for(t!=nNe(n,e.length)&&(a=e[t-(n?1:-1)],XUe(this.f,a,n?(uS(),r2):(uS(),n2))),i=e[t][0],u=!r||i.k==(DA(),GJ),l=Oy(e[t]),this.vg(l,u,!1,n),o=0,c=new w(l);c.a`),e0?M_(this.a,e[t-1],e[t]):!n&&t1&&(ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),(mP(),l1))))?iat(e,this.d,this):(Vg(),hu(e,this.d)),ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),l1)))||uXe(this.e,e))},L(CV,`ModelOrderBarycenterHeuristic`,669),q(1866,1,GI,ume),Q.Ne=function(e,t){return Y9e(this.a,P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(CV,`ModelOrderBarycenterHeuristic/lambda$0$Type`,1866),q(1423,1,yV,kue),Q.rg=function(e){var t;return P(e,36),t=Wl(NNt),vp(t,(vA(),bJ),(yP(),eX)),t},Q.Kf=function(e,t){dIe((P(e,36),t))};var NNt;L(CV,`NoCrossingMinimizer`,1423),q(809,413,SV,Na),Q.tg=function(e,t,n){var r,i,a,o,s,c,l,u,d=this.g,f,p;switch(n.g){case 1:for(i=0,a=0,u=new w(e.j);u.a1&&(i.j==(nP(),X8)?this.b[e]=!0:i.j==g5&&e>0&&(this.b[e-1]=!0))},Q.f=0,L(BR,`AllCrossingsCounter`,1861),q(595,1,{},VS),Q.b=0,Q.d=0,L(BR,`BinaryIndexedTree`,595),q(532,1,{},hf);var PNt,v2;L(BR,`CrossingsCounter`,532),q(1950,1,GI,dme),Q.Ne=function(e,t){return QMe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$0$Type`,1950),q(1951,1,GI,fme),Q.Ne=function(e,t){return $Me(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$1$Type`,1951),q(1952,1,GI,pme),Q.Ne=function(e,t){return eNe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$2$Type`,1952),q(1953,1,GI,mme),Q.Ne=function(e,t){return tNe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$3$Type`,1953),q(1954,1,$P,hme),Q.Cd=function(e){GGe(this.a,P(e,12))},L(BR,`CrossingsCounter/lambda$4$Type`,1954),q(1955,1,vF,gme),Q.Mb=function(e){return Kxe(this.a,P(e,12))},L(BR,`CrossingsCounter/lambda$5$Type`,1955),q(1956,1,$P,_me),Q.Cd=function(e){qSe(this,e)},L(BR,`CrossingsCounter/lambda$6$Type`,1956),q(1957,1,$P,Rxe),Q.Cd=function(e){var t;Rf(),Rv(this.b,(t=this.a,P(e,12),t))},L(BR,`CrossingsCounter/lambda$7$Type`,1957),q(839,1,YI,hie),Q.Lb=function(e){return Rf(),yd(P(e,12),(Y(),QQ))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return Rf(),yd(P(e,12),(Y(),QQ))},L(BR,`CrossingsCounter/lambda$8$Type`,839),q(1949,1,{},vme),L(BR,`HyperedgeCrossingsCounter`,1949),q(478,1,{34:1,478:1},sOe),Q.Fd=function(e){return e2e(this,P(e,478))},Q.b=0,Q.c=0,Q.e=0,Q.f=0;var FNt=L(BR,`HyperedgeCrossingsCounter/Hyperedge`,478);q(374,1,{34:1,374:1},Sg),Q.Fd=function(e){return Fit(this,P(e,374))},Q.b=0,Q.c=0;var INt=L(BR,`HyperedgeCrossingsCounter/HyperedgeCorner`,374);q(531,22,{3:1,34:1,22:1,531:1},zxe);var y2,b2,LNt=aS(BR,`HyperedgeCrossingsCounter/HyperedgeCorner/Type`,531,eG,gLe,cAe),RNt;q(1425,1,yV,Aue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?zNt:null},Q.Kf=function(e,t){s8e(this,P(e,36),t)};var zNt;L(wV,`InteractiveNodePlacer`,1425),q(1426,1,yV,jue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?BNt:null},Q.Kf=function(e,t){K4e(this,P(e,36),t)};var BNt,x2,S2;L(wV,`LinearSegmentsNodePlacer`,1426),q(261,1,{34:1,261:1},Jge),Q.Fd=function(e){return Fve(this,P(e,261))},Q.Fb=function(e){var t;return j(e,261)?(t=P(e,261),this.b==t.b):!1},Q.Hb=function(){return this.b},Q.Ib=function(){return`ls`+CA(this.e)},Q.a=0,Q.b=0,Q.c=-1,Q.d=-1,Q.g=0;var VNt=L(wV,`LinearSegmentsNodePlacer/LinearSegment`,261);q(1428,1,yV,xNe),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?HNt:null},Q.Kf=function(e,t){K_t(this,P(e,36),t)},Q.b=0,Q.g=0;var HNt;L(wV,`NetworkSimplexPlacer`,1428),q(1447,1,GI,gie),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(wV,`NetworkSimplexPlacer/0methodref$compare$Type`,1447),q(1449,1,GI,_ie),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(wV,`NetworkSimplexPlacer/1methodref$compare$Type`,1449),q(655,1,{655:1},Bxe);var UNt=L(wV,`NetworkSimplexPlacer/EdgeRep`,655);q(412,1,{412:1},Cg),Q.b=!1;var WNt=L(wV,`NetworkSimplexPlacer/NodeRep`,412);q(515,13,{3:1,4:1,20:1,31:1,56:1,13:1,16:1,15:1,59:1,515:1},$ge),L(wV,`NetworkSimplexPlacer/Path`,515),q(1429,1,{},vie),Q.Kb=function(e){return P(e,18).d.i.k},L(wV,`NetworkSimplexPlacer/Path/lambda$0$Type`,1429),q(1430,1,vF,yie),Q.Mb=function(e){return P(e,273)==(DA(),qJ)},L(wV,`NetworkSimplexPlacer/Path/lambda$1$Type`,1430),q(1431,1,{},bie),Q.Kb=function(e){return P(e,18).d.i},L(wV,`NetworkSimplexPlacer/Path/lambda$2$Type`,1431),q(1432,1,vF,yme),Q.Mb=function(e){return DDe(b0e(P(e,10)))},L(wV,`NetworkSimplexPlacer/Path/lambda$3$Type`,1432),q(1433,1,vF,xie),Q.Mb=function(e){return SMe(P(e,12))},L(wV,`NetworkSimplexPlacer/lambda$0$Type`,1433),q(1434,1,$P,Vxe),Q.Cd=function(e){Cwe(this.a,this.b,P(e,12))},L(wV,`NetworkSimplexPlacer/lambda$1$Type`,1434),q(1443,1,$P,bme),Q.Cd=function(e){Gtt(this.a,P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$10$Type`,1443),q(1444,1,{},Sie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$11$Type`,1444),q(1445,1,$P,xme),Q.Cd=function(e){wct(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$12$Type`,1445),q(1446,1,{},Cie),Q.Kb=function(e){return z_(),G(P(e,125).e)},L(wV,`NetworkSimplexPlacer/lambda$13$Type`,1446),q(1448,1,{},wie),Q.Kb=function(e){return z_(),G(P(e,125).e)},L(wV,`NetworkSimplexPlacer/lambda$15$Type`,1448),q(1450,1,vF,Tie),Q.Mb=function(e){return z_(),P(e,412).c.k==(DA(),JJ)},L(wV,`NetworkSimplexPlacer/lambda$17$Type`,1450),q(1451,1,vF,Eie),Q.Mb=function(e){return z_(),P(e,412).c.j.c.length>1},L(wV,`NetworkSimplexPlacer/lambda$18$Type`,1451),q(1452,1,$P,oIe),Q.Cd=function(e){J1e(this.c,this.b,this.d,this.a,P(e,412))},Q.c=0,Q.d=0,L(wV,`NetworkSimplexPlacer/lambda$19$Type`,1452),q(1435,1,{},Die),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$2$Type`,1435),q(1453,1,$P,Sme),Q.Cd=function(e){Twe(this.a,P(e,12))},Q.a=0,L(wV,`NetworkSimplexPlacer/lambda$20$Type`,1453),q(1454,1,{},Oie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$21$Type`,1454),q(1455,1,$P,Cme),Q.Cd=function(e){tTe(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$22$Type`,1455),q(1456,1,vF,kie),Q.Mb=function(e){return DDe(e)},L(wV,`NetworkSimplexPlacer/lambda$23$Type`,1456),q(1457,1,{},Aie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$24$Type`,1457),q(1458,1,vF,wme),Q.Mb=function(e){return wCe(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$25$Type`,1458),q(1459,1,$P,Hxe),Q.Cd=function(e){ret(this.a,this.b,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$26$Type`,1459),q(1460,1,vF,jie),Q.Mb=function(e){return z_(),!gy(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$27$Type`,1460),q(1461,1,vF,Mie),Q.Mb=function(e){return z_(),!gy(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$28$Type`,1461),q(1462,1,{},Tme),Q.Ve=function(e,t){return wwe(this.a,P(e,30),P(t,30))},L(wV,`NetworkSimplexPlacer/lambda$29$Type`,1462),q(1436,1,{},Nie),Q.Kb=function(e){return z_(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(wV,`NetworkSimplexPlacer/lambda$3$Type`,1436),q(1437,1,vF,Pie),Q.Mb=function(e){return z_(),KBe(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$4$Type`,1437),q(1438,1,$P,Eme),Q.Cd=function(e){hft(this.a,P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$5$Type`,1438),q(1439,1,{},Fie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$6$Type`,1439),q(1440,1,vF,Iie),Q.Mb=function(e){return z_(),P(e,10).k==(DA(),JJ)},L(wV,`NetworkSimplexPlacer/lambda$7$Type`,1440),q(1441,1,{},Lie),Q.Kb=function(e){return z_(),new Mp(null,new ih(new pm(Vu(EE(P(e,10)).a.Kc(),new d))))},L(wV,`NetworkSimplexPlacer/lambda$8$Type`,1441),q(1442,1,vF,Rie),Q.Mb=function(e){return z_(),xMe(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$9$Type`,1442),q(1424,1,yV,Mue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?GNt:null},Q.Kf=function(e,t){hpt(P(e,36),t)};var GNt;L(wV,`SimpleNodePlacer`,1424),q(185,1,{185:1},VM),Q.Ib=function(){var e=``;return this.c==(O_(),w2)?e+=lL:this.c==C2&&(e+=cL),this.o==(k_(),T2)?e+=hL:this.o==E2?e+=`UP`:e+=`BALANCED`,e},L(EV,`BKAlignedLayout`,185),q(523,22,{3:1,34:1,22:1,523:1},Uxe);var C2,w2,KNt=aS(EV,`BKAlignedLayout/HDirection`,523,eG,vLe,lAe),qNt;q(522,22,{3:1,34:1,22:1,522:1},Wxe);var T2,E2,JNt=aS(EV,`BKAlignedLayout/VDirection`,522,eG,yLe,uAe),YNt;q(1699,1,{},Gxe),L(EV,`BKAligner`,1699),q(1702,1,{},f6e),L(EV,`BKCompactor`,1702),q(663,1,{663:1},zie),Q.a=0,L(EV,`BKCompactor/ClassEdge`,663),q(467,1,{467:1},Xge),Q.a=null,Q.b=0,L(EV,`BKCompactor/ClassNode`,467),q(1427,1,yV,Xxe),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?XNt:null},Q.Kf=function(e,t){wvt(this,P(e,36),t)},Q.d=!1;var XNt;L(EV,`BKNodePlacer`,1427),q(1700,1,{},Bie),Q.d=0,L(EV,`NeighborhoodInformation`,1700),q(1701,1,GI,Dme),Q.Ne=function(e,t){return sqe(this,P(e,42),P(t,42))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(EV,`NeighborhoodInformation/NeighborComparator`,1701),q(823,1,{}),L(EV,`ThresholdStrategy`,823),q(1825,823,{},Zge),Q.wg=function(e,t,n){return this.a.o==(k_(),E2)?cI:lI},Q.xg=function(){},L(EV,`ThresholdStrategy/NullThresholdStrategy`,1825),q(587,1,{587:1},Zxe),Q.c=!1,Q.d=!1,L(EV,`ThresholdStrategy/Postprocessable`,587),q(1826,823,{},Qge),Q.wg=function(e,t,n){var r,i=t==n,a;return r=this.a.a[n.p]==t,i||r?(a=e,this.a.c,O_(),i&&(a=_pt(this,t,!0)),!isNaN(a)&&!isFinite(a)&&r&&(a=_pt(this,n,!1)),a):e},Q.xg=function(){for(var e,t,n,r,i;this.d.b!=0;)i=P(RLe(this.d),587),r=Cdt(this,i),r.a&&(e=r.a,n=ki(this.a.f[this.a.g[i.b.p].p]),!(!n&&!gy(e)&&e.c.i.c==e.d.i.c)&&(t=Iit(this,i),t||kCe(this.e,i)));for(;this.e.a.c.length!=0;)Iit(this,P(wQe(this.e),587))},L(EV,`ThresholdStrategy/SimpleThresholdStrategy`,1826),q(645,1,{645:1,188:1,196:1},Vie),Q.dg=function(){return fXe(this)},Q.qg=function(){return fXe(this)};var D2;L(DV,`EdgeRouterFactory`,645),q(1485,1,yV,Nue),Q.rg=function(e){return Lst(P(e,36))},Q.Kf=function(e,t){wpt(P(e,36),t)};var ZNt,QNt,$Nt,ePt,tPt,nPt,rPt,iPt;L(DV,`OrthogonalEdgeRouter`,1485),q(1478,1,yV,Yxe),Q.rg=function(e){return T8e(P(e,36))},Q.Kf=function(e,t){Ygt(this,P(e,36),t)};var aPt,oPt,sPt,cPt,O2,lPt;L(DV,`PolylineEdgeRouter`,1478),q(1479,1,YI,Uie),Q.Lb=function(e){return wXe(P(e,10))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return wXe(P(e,10))},L(DV,`PolylineEdgeRouter/1`,1479),q(1872,1,vF,Wie),Q.Mb=function(e){return P(e,132).c==(Wy(),k2)},L(OV,`HyperEdgeCycleDetector/lambda$0$Type`,1872),q(1873,1,{},Gie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$1$Type`,1873),q(1874,1,vF,Kie),Q.Mb=function(e){return P(e,132).c==(Wy(),k2)},L(OV,`HyperEdgeCycleDetector/lambda$2$Type`,1874),q(1875,1,{},qie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$3$Type`,1875),q(1876,1,{},Jie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$4$Type`,1876),q(1877,1,{},Hie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$5$Type`,1877),q(118,1,{34:1,118:1},GC),Q.Fd=function(e){return Ive(this,P(e,118))},Q.Fb=function(e){var t;return j(e,118)?(t=P(e,118),this.g==t.g):!1},Q.Hb=function(){return this.g},Q.Ib=function(){for(var e=new Gu(`{`),t,n,r=new w(this.n);r.a`+this.b+` (`+bEe(this.c)+`)`},Q.d=0,L(OV,`HyperEdgeSegmentDependency`,132),q(528,22,{3:1,34:1,22:1,528:1},nSe);var k2,A2,uPt=aS(OV,`HyperEdgeSegmentDependency/DependencyType`,528,eG,bLe,dAe),dPt;q(1878,1,{},Ome),L(OV,`HyperEdgeSegmentSplitter`,1878),q(1879,1,{},Xve),Q.a=0,Q.b=0,L(OV,`HyperEdgeSegmentSplitter/AreaRating`,1879),q(339,1,{339:1},Bf),Q.a=0,Q.b=0,Q.c=0,L(OV,`HyperEdgeSegmentSplitter/FreeArea`,339),q(1880,1,GI,Yie),Q.Ne=function(e,t){return NOe(P(e,118),P(t,118))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(OV,`HyperEdgeSegmentSplitter/lambda$0$Type`,1880),q(1881,1,$P,sIe),Q.Cd=function(e){ZVe(this.a,this.d,this.c,this.b,P(e,118))},Q.b=0,L(OV,`HyperEdgeSegmentSplitter/lambda$1$Type`,1881),q(1882,1,{},Xie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).e,16))},L(OV,`HyperEdgeSegmentSplitter/lambda$2$Type`,1882),q(1883,1,{},Zie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).j,16))},L(OV,`HyperEdgeSegmentSplitter/lambda$3$Type`,1883),q(1884,1,{},Qie),Q.Ye=function(e){return D(N(e))},L(OV,`HyperEdgeSegmentSplitter/lambda$4$Type`,1884),q(664,1,{},ah),Q.a=0,Q.b=0,Q.c=0,L(OV,`OrthogonalRoutingGenerator`,664),q(1703,1,{},$ie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).e,16))},L(OV,`OrthogonalRoutingGenerator/lambda$0$Type`,1703),q(1704,1,{},eae),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).j,16))},L(OV,`OrthogonalRoutingGenerator/lambda$1$Type`,1704),q(670,1,{}),L(kV,`BaseRoutingDirectionStrategy`,670),q(1870,670,{},r_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t+e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(f,o),up(s.a,i),YM(this,s,a,i,!1),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1),o=t+p.o*n,a=p,i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1)),i=new k(g,o),up(s.a,i),YM(this,s,a,i,!1)))},Q.zg=function(e){return e.i.n.a+e.n.a+e.a.a},Q.Ag=function(){return nP(),m5},Q.Bg=function(){return nP(),Z8},L(kV,`NorthToSouthRoutingStrategy`,1870),q(1871,670,{},i_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t-e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(f,o),up(s.a,i),YM(this,s,a,i,!1),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1),o=t-p.o*n,a=p,i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1)),i=new k(g,o),up(s.a,i),YM(this,s,a,i,!1)))},Q.zg=function(e){return e.i.n.a+e.n.a+e.a.a},Q.Ag=function(){return nP(),Z8},Q.Bg=function(){return nP(),m5},L(kV,`SouthToNorthRoutingStrategy`,1871),q(1869,670,{},a_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t+e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(o,f),up(s.a,i),YM(this,s,a,i,!0),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(o,m),up(s.a,i),YM(this,s,a,i,!0),o=t+p.o*n,a=p,i=new k(o,m),up(s.a,i),YM(this,s,a,i,!0)),i=new k(o,g),up(s.a,i),YM(this,s,a,i,!0)))},Q.zg=function(e){return e.i.n.b+e.n.b+e.a.b},Q.Ag=function(){return nP(),X8},Q.Bg=function(){return nP(),g5},L(kV,`WestToEastRoutingStrategy`,1869),q(828,1,{},yft),Q.Ib=function(){return CA(this.a)},Q.b=0,Q.c=!1,Q.d=!1,Q.f=0,L(jV,`NubSpline`,828),q(418,1,{418:1},vst,FLe),L(jV,`NubSpline/PolarCP`,418),q(1480,1,yV,P3e),Q.rg=function(e){return G5e(P(e,36))},Q.Kf=function(e,t){w_t(this,P(e,36),t)};var fPt,pPt,mPt,hPt,gPt;L(jV,`SplineEdgeRouter`,1480),q(274,1,{274:1},Ly),Q.Ib=function(){return this.a+` ->(`+this.c+`) `+this.b},Q.c=0,L(jV,`SplineEdgeRouter/Dependency`,274),q(465,22,{3:1,34:1,22:1,465:1},rSe);var j2,M2,_Pt=aS(jV,`SplineEdgeRouter/SideToProcess`,465,eG,ELe,fAe),vPt;q(1481,1,vF,tae),Q.Mb=function(e){return iM(),!P(e,131).o},L(jV,`SplineEdgeRouter/lambda$0$Type`,1481),q(1482,1,{},nae),Q.Ze=function(e){return iM(),P(e,131).v+1},L(jV,`SplineEdgeRouter/lambda$1$Type`,1482),q(1483,1,$P,Qxe),Q.Cd=function(e){TMe(this.a,this.b,P(e,42))},L(jV,`SplineEdgeRouter/lambda$2$Type`,1483),q(1484,1,$P,$xe),Q.Cd=function(e){EMe(this.a,this.b,P(e,42))},L(jV,`SplineEdgeRouter/lambda$3$Type`,1484),q(131,1,{34:1,131:1},ttt,Xpt),Q.Fd=function(e){return Bve(this,P(e,131))},Q.b=0,Q.e=!1,Q.f=0,Q.g=0,Q.j=!1,Q.k=!1,Q.n=0,Q.o=!1,Q.p=!1,Q.q=!1,Q.s=0,Q.u=0,Q.v=0,Q.F=0,L(jV,`SplineSegment`,131),q(468,1,{468:1},rae),Q.a=0,Q.b=!1,Q.c=!1,Q.d=!1,Q.e=!1,Q.f=0,L(jV,`SplineSegment/EdgeInformation`,468),q(1198,1,{},iae),L(FV,ebt,1198),q(1199,1,GI,aae),Q.Ne=function(e,t){return Snt(P(e,121),P(t,121))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(FV,tbt,1199),q(1197,1,{},_ye),L(FV,`MrTree`,1197),q(405,22,{3:1,34:1,22:1,405:1,188:1,196:1},fc),Q.dg=function(){return wnt(this)},Q.qg=function(){return wnt(this)};var N2,P2,F2,I2,yPt=aS(FV,`TreeLayoutPhases`,405,eG,DVe,pAe),bPt;q(1112,205,OL,aOe),Q.rf=function(e,t){var n,r,i,a,o,s,c,l;for(ki(Od(J(e,(rN(),dFt))))||S_((n=new ir((Ko(),new Ei(e))),n)),o=t.eh(IV),o.Ug(`build tGraph`,1),s=(c=new zy,VC(c,e),W(c,(tP(),t4),e),l=new Dr,Lut(e,c,l),fdt(e,c,l),c),o.Vg(),o=t.eh(IV),o.Ug(`Split graph`,1),a=Wut(this.a,s),o.Vg(),i=new w(a);i.a`+hv(this.c):`e_`+US(this)},L(RV,`TEdge`,65),q(121,137,{3:1,121:1,96:1,137:1},zy),Q.Ib=function(){var e,t,n,r,i=null;for(r=dO(this.b,0);r.b!=r.d.c;)n=P(Lv(r),40),i+=(n.c==null||n.c.length==0?`n_`+n.g:`n_`+n.c)+` +`;for(t=dO(this.a,0);t.b!=t.d.c;)e=P(Lv(t),65),i+=(e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))+` +`;return i};var xPt=L(RV,`TGraph`,121);q(643,508,{3:1,508:1,643:1,96:1,137:1}),L(RV,`TShape`,643),q(40,643,{3:1,508:1,40:1,643:1,96:1,137:1},Ow),Q.Ib=function(){return hv(this)};var L2=L(RV,`TNode`,40);q(236,1,rF,hr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){var e;return e=dO(this.a.d,0),new gr(e)},L(RV,`TNode/2`,236),q(329,1,VP,gr),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(Lv(this.a),65).c},Q.Ob=function(){return Za(this.a)},Q.Qb=function(){wx(this.a)},L(RV,`TNode/2/1`,329),q(1923,1,DR,fae),Q.Kf=function(e,t){gvt(this,P(e,121),t)},L(BV,`CompactionProcessor`,1923),q(1924,1,GI,Nme),Q.Ne=function(e,t){return eXe(this.a,P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$0$Type`,1924),q(1925,1,vF,tSe),Q.Mb=function(e){return qIe(this.b,this.a,P(e,42))},Q.a=0,Q.b=0,L(BV,`CompactionProcessor/lambda$1$Type`,1925),q(1934,1,GI,pae),Q.Ne=function(e,t){return FPe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$10$Type`,1934),q(1935,1,GI,mae),Q.Ne=function(e,t){return tEe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$11$Type`,1935),q(1936,1,GI,hae),Q.Ne=function(e,t){return IPe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$12$Type`,1936),q(1926,1,vF,Pme),Q.Mb=function(e){return nTe(this.a,P(e,42))},Q.a=0,L(BV,`CompactionProcessor/lambda$2$Type`,1926),q(1927,1,vF,Fme),Q.Mb=function(e){return rTe(this.a,P(e,42))},Q.a=0,L(BV,`CompactionProcessor/lambda$3$Type`,1927),q(1928,1,vF,gae),Q.Mb=function(e){return P(e,40).c.indexOf(LV)==-1},L(BV,`CompactionProcessor/lambda$4$Type`,1928),q(1929,1,{},Ime),Q.Kb=function(e){return UBe(this.a,P(e,40))},Q.a=0,L(BV,`CompactionProcessor/lambda$5$Type`,1929),q(1930,1,{},Lme),Q.Kb=function(e){return WGe(this.a,P(e,40))},Q.a=0,L(BV,`CompactionProcessor/lambda$6$Type`,1930),q(1931,1,GI,Rme),Q.Ne=function(e,t){return jUe(this.a,P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$7$Type`,1931),q(1932,1,GI,zme),Q.Ne=function(e,t){return MUe(this.a,P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$8$Type`,1932),q(1933,1,GI,_ae),Q.Ne=function(e,t){return nEe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$9$Type`,1933),q(1921,1,DR,vae),Q.Kf=function(e,t){Gct(P(e,121),t)},L(BV,`DirectionProcessor`,1921),q(1913,1,DR,iOe),Q.Kf=function(e,t){sdt(this,P(e,121),t)},L(BV,`FanProcessor`,1913),q(1937,1,DR,yae),Q.Kf=function(e,t){Sct(P(e,121),t)},L(BV,`GraphBoundsProcessor`,1937),q(1938,1,{},bae),Q.Ye=function(e){return P(e,40).e.a},L(BV,`GraphBoundsProcessor/lambda$0$Type`,1938),q(1939,1,{},xae),Q.Ye=function(e){return P(e,40).e.b},L(BV,`GraphBoundsProcessor/lambda$1$Type`,1939),q(1940,1,{},Sae),Q.Ye=function(e){return Wbe(P(e,40))},L(BV,`GraphBoundsProcessor/lambda$2$Type`,1940),q(1941,1,{},Cae),Q.Ye=function(e){return Ube(P(e,40))},L(BV,`GraphBoundsProcessor/lambda$3$Type`,1941),q(262,22,{3:1,34:1,22:1,262:1,196:1},pc),Q.dg=function(){switch(this.g){case 0:return new S_e;case 1:return new iOe;case 2:return new x_e;case 3:return new Oae;case 4:return new Tae;case 8:return new wae;case 5:return new vae;case 6:return new Aae;case 7:return new fae;case 9:return new yae;case 10:return new jae;default:throw E(new Fi(FR+(this.f==null?``+this.g:this.f)))}};var SPt,CPt,wPt,TPt,EPt,DPt,OPt,kPt,APt,jPt,R2,MPt=aS(BV,IR,262,eG,qYe,mAe),NPt;q(1920,1,DR,wae),Q.Kf=function(e,t){Bgt(P(e,121),t)},L(BV,`LevelCoordinatesProcessor`,1920),q(1918,1,DR,Tae),Q.Kf=function(e,t){fot(this,P(e,121),t)},Q.a=0,L(BV,`LevelHeightProcessor`,1918),q(1919,1,rF,Eae),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return Vg(),bo(),tK},L(BV,`LevelHeightProcessor/1`,1919),q(1914,1,DR,x_e),Q.Kf=function(e,t){cct(this,P(e,121),t)},L(BV,`LevelProcessor`,1914),q(1915,1,vF,Dae),Q.Mb=function(e){return ki(Od(K(P(e,40),(tP(),a4))))},L(BV,`LevelProcessor/lambda$0$Type`,1915),q(1916,1,DR,Oae),Q.Kf=function(e,t){Xet(this,P(e,121),t)},Q.a=0,L(BV,`NeighborsProcessor`,1916),q(1917,1,rF,kae),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return Vg(),bo(),tK},L(BV,`NeighborsProcessor/1`,1917),q(1922,1,DR,Aae),Q.Kf=function(e,t){odt(this,P(e,121),t)},Q.a=0,L(BV,`NodePositionProcessor`,1922),q(1912,1,DR,S_e),Q.Kf=function(e,t){qpt(this,P(e,121),t)},L(BV,`RootProcessor`,1912),q(1942,1,DR,jae),Q.Kf=function(e,t){b4e(P(e,121),t)},L(BV,`Untreeifyer`,1942),q(392,22,{3:1,34:1,22:1,392:1},mc);var z2,B2,PPt,FPt=aS(HV,`EdgeRoutingMode`,392,eG,dze,hAe),IPt,V2,H2,U2,LPt,RPt,W2,G2,zPt,K2,BPt,q2,J2,Y2,X2,Z2,Q2,$2,e4,t4,n4,r4,VPt,HPt,i4,a4,o4,s4;q(862,1,nL,Pue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UV),``),uxt),`Turns on Tree compaction which decreases the size of the whole tree by placing nodes of multiple levels in one large level`),(rd(),!1)),(VA(),R3)),bG),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WV),``),`Edge End Texture Length`),`Should be set to the length of the texture at the end of an edge. This value can be used to improve the Edge Routing.`),7),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,axt),``),`Tree Level`),`The index for the tree level the node is in`),G(0)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oxt),``),uxt),`When set to a positive number this option will force the algorithm to place the node to the specified position within the trees layer if weighting is set to constraint`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sxt),``),`Weighting of Nodes`),`Which weighting to use when computing a node order.`),QPt),B3),wFt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cxt),``),`Edge Routing Mode`),`Chooses an Edge Routing algorithm.`),KPt),B3),FPt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lxt),``),`Search Order`),`Which search order to use when computing a spanning tree.`),YPt),B3),DFt),sE(F3)))),b_t((new Lue,e))};var UPt,WPt,GPt,KPt,qPt,JPt,YPt,XPt,ZPt,QPt;L(HV,`MrTreeMetaDataProvider`,862),q(1006,1,nL,Lue),Q.hf=function(e){b_t(e)};var $Pt,eFt,tFt,c4,nFt,rFt,l4,iFt,aFt,oFt,sFt,cFt,lFt,uFt,dFt,fFt,pFt,mFt,u4,d4,hFt,gFt,_Ft,f4,vFt,yFt,bFt,xFt,SFt,p4,CFt;L(HV,`MrTreeOptions`,1006),q(1007,1,{},Mae),Q.sf=function(){var e;return e=new aOe,e},Q.tf=function(e){},L(HV,`MrTreeOptions/MrtreeFactory`,1007),q(353,22,{3:1,34:1,22:1,353:1},hc);var m4,h4,g4,_4,wFt=aS(HV,`OrderWeighting`,353,eG,OVe,gAe),TFt;q(433,22,{3:1,34:1,22:1,433:1},iSe);var EFt,v4,DFt=aS(HV,`TreeifyingOrder`,433,eG,wLe,_Ae),OFt;q(1486,1,yV,Rue),Q.rg=function(e){return P(e,121),kFt},Q.Kf=function(e,t){jYe(this,P(e,121),t)};var kFt;L(`org.eclipse.elk.alg.mrtree.p1treeify`,`DFSTreeifyer`,1486),q(1487,1,yV,zue),Q.rg=function(e){return P(e,121),AFt},Q.Kf=function(e,t){hct(this,P(e,121),t)};var AFt;L(KV,`NodeOrderer`,1487),q(1494,1,{},Jae),Q.td=function(e){return MMe(e)},L(KV,`NodeOrderer/0methodref$lambda$6$Type`,1494),q(1488,1,vF,Yae),Q.Mb=function(e){return Rx(),ki(Od(K(P(e,40),(tP(),a4))))},L(KV,`NodeOrderer/lambda$0$Type`,1488),q(1489,1,vF,Xae),Q.Mb=function(e){return Rx(),P(K(P(e,40),(rN(),u4)),17).a<0},L(KV,`NodeOrderer/lambda$1$Type`,1489),q(1490,1,vF,Vme),Q.Mb=function(e){return OJe(this.a,P(e,40))},L(KV,`NodeOrderer/lambda$2$Type`,1490),q(1491,1,vF,Bme),Q.Mb=function(e){return qBe(this.a,P(e,40))},L(KV,`NodeOrderer/lambda$3$Type`,1491),q(1492,1,GI,Zae),Q.Ne=function(e,t){return eqe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(KV,`NodeOrderer/lambda$4$Type`,1492),q(1493,1,vF,Qae),Q.Mb=function(e){return Rx(),P(K(P(e,40),(tP(),G2)),17).a!=0},L(KV,`NodeOrderer/lambda$5$Type`,1493),q(1495,1,yV,Iue),Q.rg=function(e){return P(e,121),jFt},Q.Kf=function(e,t){Sut(this,P(e,121),t)},Q.b=0;var jFt;L(`org.eclipse.elk.alg.mrtree.p3place`,`NodePlacer`,1495),q(1496,1,yV,Fue),Q.rg=function(e){return P(e,121),MFt},Q.Kf=function(e,t){Hlt(P(e,121),t)};var MFt;L(qV,`EdgeRouter`,1496),q(1498,1,GI,qae),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/0methodref$compare$Type`,1498),q(1503,1,{},Pae),Q.Ye=function(e){return D(N(e))},L(qV,`EdgeRouter/1methodref$doubleValue$Type`,1503),q(1505,1,GI,Fae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/2methodref$compare$Type`,1505),q(1507,1,GI,Iae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/3methodref$compare$Type`,1507),q(1509,1,{},Nae),Q.Ye=function(e){return D(N(e))},L(qV,`EdgeRouter/4methodref$doubleValue$Type`,1509),q(1511,1,GI,Lae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/5methodref$compare$Type`,1511),q(1513,1,GI,Rae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/6methodref$compare$Type`,1513),q(1497,1,{},zae),Q.Kb=function(e){return zx(),P(K(P(e,40),(rN(),p4)),17)},L(qV,`EdgeRouter/lambda$0$Type`,1497),q(1508,1,{},Bae),Q.Kb=function(e){return TEe(P(e,40))},L(qV,`EdgeRouter/lambda$11$Type`,1508),q(1510,1,{},dSe),Q.Kb=function(e){return CMe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$13$Type`,1510),q(1512,1,{},fSe),Q.Kb=function(e){return EEe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$15$Type`,1512),q(1514,1,GI,Vae),Q.Ne=function(e,t){return R2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$17$Type`,1514),q(1515,1,GI,Hae),Q.Ne=function(e,t){return z2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$18$Type`,1515),q(1516,1,GI,Uae),Q.Ne=function(e,t){return V2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$19$Type`,1516),q(1499,1,vF,Hme),Q.Mb=function(e){return GLe(this.a,P(e,40))},Q.a=0,L(qV,`EdgeRouter/lambda$2$Type`,1499),q(1517,1,GI,Wae),Q.Ne=function(e,t){return B2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$20$Type`,1517),q(1500,1,GI,Gae),Q.Ne=function(e,t){return Bje(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$3$Type`,1500),q(1501,1,GI,Kae),Q.Ne=function(e,t){return Vje(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$4$Type`,1501),q(1502,1,{},$ae),Q.Kb=function(e){return DEe(P(e,40))},L(qV,`EdgeRouter/lambda$5$Type`,1502),q(1504,1,{},pSe),Q.Kb=function(e){return wMe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$7$Type`,1504),q(1506,1,{},mSe),Q.Kb=function(e){return OEe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$9$Type`,1506),q(675,1,{675:1},d3e),Q.e=0,Q.f=!1,Q.g=!1,L(qV,`MultiLevelEdgeNodeNodeGap`,675),q(1943,1,GI,eoe),Q.Ne=function(e,t){return jRe(P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`MultiLevelEdgeNodeNodeGap/lambda$0$Type`,1943),q(1944,1,GI,toe),Q.Ne=function(e,t){return MRe(P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`MultiLevelEdgeNodeNodeGap/lambda$1$Type`,1944);var y4;q(501,22,{3:1,34:1,22:1,501:1,188:1,196:1},aSe),Q.dg=function(){return Z1e(this)},Q.qg=function(){return Z1e(this)};var b4,x4,NFt=aS(pxt,`RadialLayoutPhases`,501,eG,_Le,vAe),PFt;q(1113,205,OL,gye),Q.rf=function(e,t){var n=Wot(this,e),r,i,a,o,s;if(t.Ug(`Radial layout`,n.c.length),ki(Od(J(e,(PA(),dIt))))||S_((r=new ir((Ko(),new Ei(e))),r)),s=Y5e(e),OO(e,(Pd(),y4),s),!s)throw E(new Fi(`The given graph is not a tree!`));for(i=D(N(J(e,M4))),i==0&&(i=ont(e)),OO(e,M4,i),o=new w(Wot(this,e));o.a=3)for(S=P(H(b,0),27),ee=P(H(b,1),27),o=0;o+2=S.f+ee.f+d||ee.f>=x.f+S.f+d){ne=!0;break}++o}else ne=!0;if(!ne){for(p=b.i,c=new Lu(b);c.e!=c.i.gc();)s=P(gO(c),27),OO(s,(vP(),H6),G(p)),--p;Xdt(e,new di),t.Vg();return}for(n=(cg(this.a),Um(this.a,(ED(),L4),P(J(e,_Lt),188)),Um(this.a,R4,P(J(e,uLt),188)),Um(this.a,z4,P(J(e,mLt),188)),Bl(this.a,(re=new Zh,vp(re,L4,(LO(),H4)),vp(re,R4,V4),ki(Od(J(e,nLt)))&&vp(re,L4,B4),re)),BN(this.a,e)),u=1/n.c.length,te=0,h=new w(n);h.a0&&ZQe((sv(t-1,e.length),e.charCodeAt(t-1)),wbt);)--t;if(r>=t)throw E(new Fi(`The given string does not contain any numbers.`));if(i=nN((Zy(r,t,e.length),e.substr(r,t-r)),`,|;|\r| +`),i.length!=2)throw E(new Fi(`Exactly two numbers are expected, `+i.length+` were found.`));try{this.a=OA(qA(i[0])),this.b=OA(qA(i[1]))}catch(e){throw e=ew(e),j(e,130)?(n=e,E(new Fi(Tbt+n))):E(e)}},Q.Ib=function(){return`(`+this.a+`,`+this.b+`)`},Q.a=0,Q.b=0;var K3=L(MR,`KVector`,8);q(75,67,{3:1,4:1,20:1,31:1,56:1,16:1,67:1,15:1,75:1,423:1},ai,Ma,LEe),Q.Pc=function(){return xQe(this)},Q.cg=function(e){var t,n,r=nN(e,`,|;|\\(|\\)|\\[|\\]|\\{|\\}| | | +`),i,a,o;Fg(this);try{for(n=0,a=0,i=0,o=0;n0&&(a%2==0?i=OA(r[n]):o=OA(r[n]),a>0&&a%2!=0&&up(this,new k(i,o)),++a),++n}catch(e){throw e=ew(e),j(e,130)?(t=e,E(new Fi(`The given string does not match the expected format for vectors.`+t))):E(e)}},Q.Ib=function(){for(var e=new Gu(`(`),t=dO(this,0),n;t.b!=t.d.c;)n=P(Lv(t),8),gl(e,n.a+`,`+n.b),t.b!=t.d.c&&(e.a+=`; `);return(e.a+=`)`,e).a};var BRt=L(MR,`KVectorChain`,75);q(255,22,{3:1,34:1,22:1,255:1},Dc);var q3,J3,Y3,X3,Z3,Q3,VRt=aS(AH,`Alignment`,255,eG,lGe,HAe),HRt;q(991,1,nL,Jue),Q.hf=function(e){cdt(e)};var URt,$3,WRt,GRt,KRt,qRt,JRt,YRt,XRt,ZRt,QRt,$Rt;L(AH,`BoxLayouterOptions`,991),q(992,1,{},fse),Q.sf=function(){var e;return e=new hse,e},Q.tf=function(e){},L(AH,`BoxLayouterOptions/BoxFactory`,992),q(298,22,{3:1,34:1,22:1,298:1},Ac);var e6,t6,n6,r6,i6,a6,o6=aS(AH,`ContentAlignment`,298,eG,uGe,UAe),ezt;q(699,1,nL,Yue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,pSt),``),`Layout Algorithm`),`Select a specific layout algorithm.`),(VA(),W3)),LG),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,mSt),``),`Resolved Layout Algorithm`),`Meta data associated with the selected algorithm.`),U3),PRt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,GB),``),`Alignment`),`Alignment of the selected node relative to other nodes; the exact meaning depends on the used algorithm.`),nzt),B3),VRt),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,FL),``),`Aspect Ratio`),`The desired aspect ratio of the drawing, that is the quotient of width by height.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,hSt),``),`Bend Points`),`A fixed list of bend points for the edge. This is used by the 'Fixed Layout' algorithm to specify a pre-defined routing for an edge. The vector chain must include the source point, any bend points, and the target point, so it must have at least two points.`),U3),BRt),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rV),``),`Content Alignment`),`Specifies how the content of a node are aligned. Each node can individually control the alignment of its contents. I.e. if a node should be aligned top left in its parent node, the parent node should specify that option.`),szt),V3),o6),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WB),``),`Debug Mode`),`Whether additional debug information shall be generated.`),(rd(),!1)),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,JB),``),Vyt),`Overall direction of edges: horizontal (right / left) or vertical (down / up).`),czt),B3),a8),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xB),``),`Edge Routing`),`What kind of edge routing style should be applied for the content of a parent node. Algorithms may also set this option to single edges in order to mark them as splines. The bend point list of edges with this option set to SPLINES must be interpreted as control points for a piecewise cubic spline.`),dzt),B3),p8),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dSt),``),`Expand Nodes`),`If active, nodes are expanded to fill the area of their parent.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bB),``),`Hierarchy Handling`),"Determines whether separate layout runs are triggered for different compound nodes in a hierarchical graph. Setting a node's hierarchy handling to `INCLUDE_CHILDREN` will lay out that node and all of its descendants in a single layout run, until a descendant is encountered which has its hierarchy handling set to `SEPARATE_CHILDREN`. In general, `SEPARATE_CHILDREN` will ensure that a new layout run is triggered for a node with that setting. Including multiple levels of hierarchy in a single layout run may allow cross-hierarchical edges to be laid out properly. If the root node is set to `INHERIT` (or not set at all), the default behavior is `SEPARATE_CHILDREN`."),hzt),B3),yBt),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,IL),``),`Padding`),`The padding to be left to a parent element's border when placing child elements. This can also serve as an output option of a layout algorithm if node size calculation is setup appropriately.`),Tzt),U3),ZJ),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tR),``),`Interactive`),`Whether the algorithm should be run in interactive mode for the content of a parent node. What this means exactly depends on how the specific algorithm interprets this option. Usually in the interactive mode algorithms try to modify the current layout as little as possible.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hV),``),`interactive Layout`),`Whether the graph should be changeable interactively and by setting constraints`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iR),``),`Omit Node Micro Layout`),`Node micro layout comprises the computation of node dimensions (if requested), the placement of ports and their labels, and the placement of node labels. The functionality is implemented independent of any specific layout algorithm and shouldn't have any negative impact on the layout algorithm's performance itself. Yet, if any unforeseen behavior occurs, this option allows to deactivate the micro layout.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,nR),``),`Port Constraints`),`Defines constraints of the position of the ports of a node.`),Nzt),B3),DBt),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,fV),``),`Position`),`The position of a node, port, or label. This is used by the 'Fixed Layout' algorithm to specify a pre-defined position.`),U3),K3),Zp(P3,U(O(L3,1),Z,170,0,[I3,N3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,XL),``),`Priority`),`Defines the priority of an object; its meaning depends on the specific layout algorithm and the context where it is used.`),H3),DG),Zp(P3,U(O(L3,1),Z,170,0,[M3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,$L),``),`Randomization Seed`),`Seed used for pseudo-random number generators to control the layout algorithm. If the value is 0, the seed shall be determined pseudo-randomly (e.g. from the system time).`),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,eR),``),`Separate Connected Components`),`Whether each connected component should be processed separately.`),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iV),``),`Junction Points`),`This option is not used as option, but as output of the layout algorithms. It is attached to edges and determines the points where junction symbols should be drawn in order to represent hyperedges with orthogonal routing. Whether such points are computed depends on the chosen layout algorithm and edge routing style. The points are put into the vector chain with no specific order.`),_zt),U3),BRt),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sV),``),`Comment Box`),`Whether the node should be regarded as a comment box instead of a regular node. In that case its placement should be similar to how labels are handled. Any edges incident to a comment box specify to which graph elements the comment is related.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cV),``),`Hypernode`),`Whether the node should be handled as a hypernode.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,gSt),``),`Label Manager`),`Label managers can shorten labels upon a layout algorithm's request.`),U3),uUt),Zp(F3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pV),``),`Margins`),`Margins define additional space around the actual bounds of a graph element. For instance, ports or labels being placed on the outside of a node's border might introduce such a margin. The margin is used to guarantee non-overlap of other graph elements with those ports or labels.`),vzt),U3),HJ),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,HB),``),`No Layout`),`No layout is done for the associated element. This is used to mark parts of a diagram to avoid their inclusion in the layout graph, or to mark parts of the layout graph to prevent layout engines from processing them. If you wish to exclude the contents of a compound node from automatic layout, while the node itself is still considered on its own layer, use the 'Fixed Layout' algorithm for that node.`),!1),R3),bG),Zp(P3,U(O(L3,1),Z,170,0,[M3,I3,N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_St),``),`Scale Factor`),`The scaling factor to be applied to the corresponding node in recursive layout. It causes the corresponding node's size to be adjusted, and its ports and labels to be sized and placed accordingly after the layout of that node has been determined (and before the node itself and its siblings are arranged). The scaling is not reverted afterwards, so the resulting layout graph contains the adjusted size and position data. This option is currently not supported if 'Layout Hierarchy' is set.`),1),z3),TG),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,vSt),``),`Child Area Width`),`The width of the area occupied by the laid out children of a node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,ySt),``),`Child Area Height`),`The height of the area occupied by the laid out children of a node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uR),``),aSt),`Turns topdown layout on and off. If this option is enabled, hierarchical layout will be computed first for the root node and then for its children recursively. Layouts are then scaled down to fit the area provided by their parents. Graphs must follow a certain structure for topdown layout to work properly. {@link TopdownNodeTypes.PARALLEL_NODE} nodes must have children of type {@link TopdownNodeTypes.HIERARCHICAL_NODE} and must define {@link topdown.hierarchicalNodeWidth} and {@link topdown.hierarchicalNodeAspectRatio} for their children. Furthermore they need to be laid out using an algorithm that is a {@link TopdownLayoutProvider}. Hierarchical nodes can also be parents of other hierarchical nodes and can optionally use a {@link TopdownSizeApproximator} to dynamically set sizes during topdown layout. In this case {@link topdown.hierarchicalNodeWidth} and {@link topdown.hierarchicalNodeAspectRatio} should be set on the node itself rather than the parent. The values are then used by the size approximator as base values. Hierarchical nodes require the layout option {@link nodeSize.fixedGraphSize} to be true to prevent the algorithm used there from resizing the hierarchical node. This option is not supported if 'Hierarchy Handling' is set to 'INCLUDE_CHILDREN'`),!1),R3),bG),sE(F3)))),wv(e,uR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bSt),``),`Animate`),`Whether the shift from the old layout to the new computed layout shall be animated.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xSt),``),`Animation Time Factor`),`Factor for computation of animation time. The higher the value, the longer the animation time. If the value is 0, the resulting time is always equal to the minimum defined by 'Minimal Animation Time'.`),G(100)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,SSt),``),`Layout Ancestors`),`Whether the hierarchy levels on the path from the selected element to the root of the diagram shall be included in the layout process.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,CSt),``),`Maximal Animation Time`),`The maximal time for animations, in milliseconds.`),G(4e3)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,wSt),``),`Minimal Animation Time`),`The minimal time for animations, in milliseconds.`),G(400)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,TSt),``),`Progress Bar`),`Whether a progress bar shall be displayed during layout computations.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ESt),``),`Validate Graph`),`Whether the graph shall be validated before any layout algorithm is applied. If this option is enabled and at least one error is found, the layout process is aborted and a message is shown to the user.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,DSt),``),`Validate Options`),`Whether layout options shall be validated before any layout algorithm is applied. If this option is enabled and at least one error is found, the layout process is aborted and a message is shown to the user.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,OSt),``),`Zoom to Fit`),`Whether the zoom level shall be set to view the whole diagram after layout.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fSt),`box`),`Box Layout Mode`),`Configures the packing mode used by the {@link BoxLayoutProvider}. If SIMPLE is not required (neither priorities are used nor the interactive mode), GROUP_DEC can improve the packing and decrease the area. GROUP_MIXED and GROUP_INC may, in very specific scenarios, work better.`),azt),B3),JBt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,AB),SB),`Comment Comment Spacing`),`Spacing to be preserved between a comment box and other comment boxes connected to the same node. The space left between comment boxes of different nodes is controlled by the node-node spacing.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jB),SB),`Comment Node Spacing`),`Spacing to be preserved between a node and its connected comment boxes. The space left between a node and the comments of another node is controlled by the node-node spacing.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NL),SB),`Components Spacing`),`Spacing to be preserved between pairs of connected components. This option is only relevant if 'separateConnectedComponents' is activated.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,MB),SB),`Edge Spacing`),`Spacing to be preserved between any two edges. Note that while this can somewhat easily be satisfied for the segments of orthogonally drawn edges, it is harder for general polylines or splines.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QL),SB),`Edge Label Spacing`),`The minimal distance to be preserved between a label and the edge it is associated with. Note that the placement of a label is influenced by the 'edgelabels.placement' option.`),2),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NB),SB),`Edge Node Spacing`),`Spacing to be preserved between nodes and edges.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,PB),SB),`Label Spacing`),`Determines the amount of space to be left between two labels of the same graph element.`),0),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,LB),SB),`Label Node Spacing`),`Spacing to be preserved between labels and the border of node they are associated with. Note that the placement of a label is influenced by the 'nodelabels.placement' option.`),5),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,FB),SB),`Horizontal spacing between Label and Port`),`Horizontal spacing to be preserved between labels and the ports they are associated with. Note that the placement of a label is influenced by the 'portlabels.placement' option.`),1),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,IB),SB),`Vertical spacing between Label and Port`),`Vertical spacing to be preserved between labels and the ports they are associated with. Note that the placement of a label is influenced by the 'portlabels.placement' option.`),1),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZL),SB),`Node Spacing`),`The minimal distance to be preserved between each two nodes.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,RB),SB),`Node Self Loop Spacing`),`Spacing to be preserved between a node and its self loops.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,zB),SB),`Port Spacing`),`Spacing between pairs of ports of the same node.`),10),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,BB),SB),`Individual Spacing`),`Allows to specify individual spacing values for graph elements that shall be different from the value specified for the element's parent.`),U3),XBt),Zp(P3,U(O(L3,1),Z,170,0,[M3,I3,N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mV),SB),`Additional Port Space`),`Additional space around the sets of ports on each node side. For each side of a node, this option can reserve additional space before and after the ports on each side. For example, a top spacing of 20 makes sure that the first port on the western and eastern side is 20 units away from the northern border.`),Yzt),U3),HJ),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,dV),PSt),`Layout Partition`),`Partition to which the node belongs. This requires Layout Partitioning to be active. Nodes with lower partition IDs will appear to the left of nodes with higher partition IDs (assuming a left-to-right layout direction).`),H3),DG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,dV,uV,kzt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uV),PSt),`Layout Partitioning`),`Whether to activate partitioned layout. This will allow to group nodes through the Layout Partition option. a pair of nodes with different partition indices is then placed such that the node with lower index is placed to the left of the other node (with left-to-right layout direction). Depending on the layout algorithm, this may only be guaranteed to work if all nodes have a layout partition configured, or at least if edges that cross partitions are not part of a partition-crossing cycle.`),Dzt),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,YB),FSt),`Node Label Padding`),`Define padding for node labels that are placed inside of a node.`),bzt),U3),ZJ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cR),FSt),`Node Label Placement`),`Hints for where node labels are to be placed; if empty, the node label's position is not modified.`),xzt),V3),M8),Zp(P3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QB),MH),`Port Alignment`),`Defines the default port distribution for a node. May be overridden for each side individually.`),jzt),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,$B),MH),`Port Alignment (North)`),`Defines how ports on the northern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,eV),MH),`Port Alignment (South)`),`Defines how ports on the southern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,tV),MH),`Port Alignment (West)`),`Defines how ports on the western side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,nV),MH),`Port Alignment (East)`),`Defines how ports on the eastern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sR),NH),`Node Size Constraints`),`What should be taken into account when calculating a node's size. Empty size constraints specify that a node's size is already fixed and should not be changed.`),Szt),V3),S5),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oR),NH),`Node Size Options`),`Options modifying the behavior of the size constraints set on a node. Each member of the set specifies something that should be taken into account when calculating node sizes. The empty set corresponds to no further modifications.`),wzt),V3),LBt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gR),NH),`Node Size Minimum`),`The minimal size to which a node can be reduced.`),Czt),U3),K3),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,aR),NH),`Fixed Graph Size`),`By default, the fixed layout provider will enlarge a graph until it is large enough to contain its children. If this option is set, it won't do so.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,aV),OB),`Edge Label Placement`),`Gives a hint on where to put edge labels.`),lzt),B3),rBt),sE(N3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rR),OB),`Inline Edge Labels`),`If true, an edge label is placed directly on its edge. May only apply to center edge labels. This kind of label placement is only advisable if the label's rendering is such that it is not crossed by its edge and thus stays legible.`),!1),R3),bG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,kSt),`font`),`Font Name`),`Font name used for a label.`),W3),LG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,ASt),`font`),`Font Size`),`Font size used for a label.`),H3),DG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,lV),PH),`Port Anchor Offset`),`The offset to the port position where connections shall be attached.`),U3),K3),sE(I3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,oV),PH),`Port Index`),`The index of a port in the fixed order around a node. The order is assumed as clockwise, starting with the leftmost port on the top side. This option must be set if 'Port Constraints' is set to FIXED_ORDER and no specific positions are given for the ports. Additionally, the option 'Port Side' must be defined in this case.`),H3),DG),sE(I3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UB),PH),`Port Side`),`The side of a node on which a port is situated. This option must be set if 'Port Constraints' is set to FIXED_SIDE or FIXED_ORDER and no specific positions are given for the ports.`),Izt),B3),_5),sE(I3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,VB),PH),`Port Border Offset`),`The offset of ports on the node border. With a positive offset the port is moved outside of the node, while with a negative offset the port is moved towards the inside. An offset of 0 means that the port is placed directly on the node border, i.e. if the port side is north, the port's south border touches the nodes's north border; if the port side is east, the port's west border touches the nodes's east border; if the port side is south, the port's north border touches the node's south border; if the port side is west, the port's east border touches the node's west border.`),z3),TG),sE(I3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lR),ISt),`Port Label Placement`),`Decides on a placement method for port labels; if empty, the node label's position is not modified.`),Pzt),V3),Y8),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,XB),ISt),`Port Labels Next to Port`),`Use 'portLabels.placement': NEXT_TO_PORT_OF_POSSIBLE.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZB),ISt),`Treat Port Labels as Group`),`If this option is true (default), the labels of a port will be treated as a group when it comes to centering them next to their port. If this option is false, only the first label will be centered next to the port, with the others being placed below. This only applies to labels of eastern and western ports and will have no effect if labels are not placed next to their port.`),!0),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dR),FH),`Topdown Scale Factor`),`The scaling factor to be applied to the nodes laid out within the node in recursive topdown layout. The difference to 'Scale Factor' is that the node itself is not scaled. This value has to be set on hierarchical nodes.`),1),z3),TG),sE(F3)))),wv(e,dR,mR,$zt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jSt),FH),`Topdown Size Approximator`),`The size approximator to be used to set sizes of hierarchical nodes during topdown layout. The default value is null, which results in nodes keeping whatever size is defined for them e.g. through parent parallel node or by manually setting the size.`),null),B3),P5),sE(P3)))),wv(e,jSt,mR,tBt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fR),FH),`Topdown Hierarchical Node Width`),`The fixed size of a hierarchical node when using topdown layout. If this value is set on a parallel node it applies to its children, when set on a hierarchical node it applies to the node itself.`),150),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,fR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pR),FH),`Topdown Hierarchical Node Aspect Ratio`),`The fixed aspect ratio of a hierarchical node when using topdown layout. Default is 1/sqrt(2). If this value is set on a parallel node it applies to its children, when set on a hierarchical node it applies to the node itself.`),1.414),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,pR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mR),FH),`Topdown Node Type`),`The different node types used for topdown layout. If the node type is set to {@link TopdownNodeTypes.PARALLEL_NODE} the algorithm must be set to a {@link TopdownLayoutProvider} such as {@link TopdownPacking}. The {@link nodeSize.fixedGraphSize} option is technically only required for hierarchical nodes.`),null),B3),BBt),sE(P3)))),wv(e,mR,aR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,MSt),FH),`Topdown Scale Cap`),`Determines the upper limit for the topdown scale factor. The default value is 1.0 which ensures that nested children never end up appearing larger than their parents in terms of unit sizes such as the font size. If the limit is larger, nodes will fully utilize the available space, but it is counteriniuitive for inner nodes to have a larger scale than outer nodes.`),1),z3),TG),sE(F3)))),wv(e,MSt,mR,Qzt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,KB),LSt),`Activate Inside Self Loops`),`Whether this node allows to route self loops inside of it instead of around it. If set to true, this will make the node a compound node if it isn't already, and will require the layout algorithm to support compound nodes with hierarchical ports.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,qB),LSt),`Inside Self Loop`),`Whether a self loop should be routed inside a node instead of around that node.`),!1),R3),bG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,PL),`edge`),`Edge Thickness`),`The thickness of an edge. This is a hint on the line width used to draw an edge, possibly requiring more space to be reserved for it.`),1),z3),TG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NSt),`edge`),`Edge Type`),`The type of an edge. This is usually used for UML class diagrams, where associations must be handled differently from generalizations.`),pzt),B3),dBt),sE(M3)))),Uo(e,new ev(xa(Ca(Sa(new Qt,fI),`Layered`),`The layer-based method was introduced by Sugiyama, Tagawa and Toda in 1981. It emphasizes the direction of edges by pointing as many edges as possible into the same direction. The nodes are arranged in layers, which are sometimes called "hierarchies", and then reordered such that the number of edge crossings is minimized. Afterwards, concrete coordinates are computed for the nodes and edge bend points.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.orthogonal`),`Orthogonal`),`Orthogonal methods that follow the "topology-shape-metrics" approach by Batini, Nardelli and Tamassia '86. The first phase determines the topology of the drawing by applying a planarization technique, which results in a planar representation of the graph. The orthogonal shape is computed in the second phase, which aims at minimizing the number of edge bends, and is called orthogonalization. The third phase leads to concrete coordinates for nodes and edge bend points by applying a compaction method, thus defining the metrics.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,YL),`Force`),`Layout algorithms that follow physical analogies by simulating a system of attractive and repulsive forces. The first successful method of this kind was proposed by Eades in 1984.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.circle`),`Circle`),`Circular layout algorithms emphasize cycles or biconnected components of a graph by arranging them in circles. This is useful if a drawing is desired where such components are clearly grouped, or where cycles are shown as prominent OPTIONS of the graph.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,dxt),`Tree`),`Specialized layout methods for trees, i.e. acyclic graphs. The regular structure of graphs that have no undirected cycles can be emphasized using an algorithm of this type.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.planar`),`Planar`),`Algorithms that require a planar or upward planar graph. Most of these algorithms are theoretically interesting, but not practically usable.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,iH),`Radial`),`Radial layout algorithms usually position the nodes of the graph on concentric circles.`))),Klt((new Xue,e)),cdt((new Jue,e)),bct((new Zue,e))};var s6,tzt,nzt,c6,rzt,izt,azt,l6,u6,ozt,d6,szt,f6,p6,czt,m6,h6,lzt,uzt,dzt,fzt,pzt,mzt,g6,hzt,gzt,_6,v6,y6,b6,x6,_zt,S6,vzt,yzt,bzt,C6,xzt,w6,Szt,T6,E6,Czt,D6,wzt,O6,k6,A6,Tzt,Ezt,Dzt,Ozt,kzt,Azt,jzt,j6,M6,N6,P6,Mzt,F6,I6,Nzt,L6,R6,z6,Pzt,Fzt,B6,Izt,V6,H6,U6,W6,Lzt,G6,Rzt,zzt,Bzt,Vzt,Hzt,Uzt,K6,Wzt,q6,Gzt,Kzt,J6,qzt,Jzt,Yzt,Xzt,Y6,X6,Z6,Q6,Zzt,Qzt,$6,$zt,eBt,tBt;L(AH,`CoreOptions`,699),q(88,22,{3:1,34:1,22:1,88:1},jc);var e8,t8,n8,r8,i8,a8=aS(AH,Vyt,88,eG,KHe,WAe),nBt;q(278,22,{3:1,34:1,22:1,278:1},Mc);var o8,s8,c8,rBt=aS(AH,`EdgeLabelPlacement`,278,eG,Eze,GAe),iBt;q(223,22,{3:1,34:1,22:1,223:1},Nc);var l8,u8,d8,f8,p8=aS(AH,`EdgeRouting`,223,eG,MVe,KAe),aBt;q(321,22,{3:1,34:1,22:1,321:1},Pc);var oBt,sBt,cBt,lBt,m8,uBt,dBt=aS(AH,`EdgeType`,321,eG,cGe,qAe),fBt;q(989,1,nL,Xue),Q.hf=function(e){Klt(e)};var pBt,mBt,hBt,gBt,_Bt,vBt,h8;L(AH,`FixedLayouterOptions`,989),q(990,1,{},pse),Q.sf=function(){var e;return e=new wse,e},Q.tf=function(e){},L(AH,`FixedLayouterOptions/FixedFactory`,990),q(346,22,{3:1,34:1,22:1,346:1},Fc);var g8,_8,v8,yBt=aS(AH,`HierarchyHandling`,346,eG,wze,JAe),bBt;q(291,22,{3:1,34:1,22:1,291:1},Ic);var y8,b8,x8,S8,xBt=aS(AH,`LabelSide`,291,eG,jVe,YAe),SBt;q(95,22,{3:1,34:1,22:1,95:1},Lc);var C8,w8,T8,E8,D8,O8,k8,A8,j8,M8=aS(AH,`NodeLabelPlacement`,95,eG,Lqe,XAe),CBt;q(256,22,{3:1,34:1,22:1,256:1},Rc);var wBt,N8,P8,TBt,F8,I8=aS(AH,`PortAlignment`,256,eG,pUe,ZAe),EBt;q(101,22,{3:1,34:1,22:1,101:1},zc);var L8,R8,z8,B8,V8,H8,DBt=aS(AH,`PortConstraints`,101,eG,sGe,QAe),OBt;q(279,22,{3:1,34:1,22:1,279:1},Bc);var U8,W8,G8,K8,q8,J8,Y8=aS(AH,`PortLabelPlacement`,279,eG,oGe,$Ae),kBt;q(64,22,{3:1,34:1,22:1,64:1},Vc);var X8,Z8,Q8,$8,e5,t5,n5,r5,i5,a5,o5,s5,c5,l5,u5,d5,f5,p5,m5,h5,g5,_5=aS(AH,`PortSide`,64,eG,qHe,eje),ABt;q(993,1,nL,Zue),Q.hf=function(e){bct(e)};var jBt,MBt,NBt,PBt,FBt;L(AH,`RandomLayouterOptions`,993),q(994,1,{},mse),Q.sf=function(){var e;return e=new xse,e},Q.tf=function(e){},L(AH,`RandomLayouterOptions/RandomFactory`,994),q(386,22,{3:1,34:1,22:1,386:1},Hc);var v5,y5,b5,x5,S5=aS(AH,`SizeConstraint`,386,eG,AVe,tje),IBt;q(264,22,{3:1,34:1,22:1,264:1},Uc);var C5,w5,T5,E5,D5,O5,k5,A5,j5,LBt=aS(AH,`SizeOptions`,264,eG,fJe,nje),RBt;q(280,22,{3:1,34:1,22:1,280:1},Wc);var M5,zBt,N5,BBt=aS(AH,`TopdownNodeTypes`,280,eG,Dze,rje),VBt;q(347,22,RSt);var HBt,UBt,P5=aS(AH,`TopdownSizeApproximator`,347,eG,kLe,aje);q(987,347,RSt,AMe),Q.Tg=function(e){return T4e(e)},aS(AH,`TopdownSizeApproximator/1`,987,P5,null,null),q(988,347,RSt,cPe),Q.Tg=function(e){var t=P(J(e,(vP(),W6)),143),n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee=(Ia(),m=new ii,m),te,ne,C;for(qj(ee,e),te=new Dr,o=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));o.e!=o.i.gc();)i=P(gO(o),27),y=(p=new ii,p),Gj(y,ee),qj(y,i),C=T4e(i),Ql(y,r.Math.max(i.g,C.a),r.Math.max(i.f,C.b)),XA(te.f,i,y);for(a=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));a.e!=a.i.gc();)for(i=P(gO(a),27),d=new Lu((!i.e&&(i.e=new cf(U5,i,7,4)),i.e));d.e!=d.i.gc();)u=P(gO(d),74),x=P(nl(Kp(te.f,i)),27),S=P(xh(te,H((!u.c&&(u.c=new cf(H5,u,5,8)),u.c),0)),27),b=(f=new nn,f),tb((!b.b&&(b.b=new cf(H5,b,4,7)),b.b),x),tb((!b.c&&(b.c=new cf(H5,b,5,8)),b.c),S),Hj(b,I_(x)),qj(b,u);g=P(h_(t.f),205);try{g.rf(ee,new Dse),bFe(t.f,g)}catch(e){throw e=ew(e),j(e,103)?(h=e,E(h)):E(e)}return qy(ee,u6)||qy(ee,l6)||G_t(ee),l=D(N(J(ee,u6))),c=D(N(J(ee,l6))),s=l/c,n=D(N(J(ee,X6)))*r.Math.sqrt((!ee.a&&(ee.a=new F($5,ee,10,11)),ee.a).i),ne=P(J(ee,A6),107),v=ne.b+ne.c+1,_=ne.d+ne.a+1,new k(r.Math.max(v,n),r.Math.max(_,n/s))},aS(AH,`TopdownSizeApproximator/2`,988,P5,null,null);var WBt;q(344,1,{871:1},di),Q.Ug=function(e,t){return p7e(this,e,t)},Q.Vg=function(){Q9e(this)},Q.Wg=function(){return this.q},Q.Xg=function(){return this.f?Zg(this.f):null},Q.Yg=function(){return Zg(this.a)},Q.Zg=function(){return this.p},Q.$g=function(){return!1},Q._g=function(){return this.n},Q.ah=function(){return this.p!=null&&!this.b},Q.bh=function(e){var t;this.n&&(t=e,M(this.f,t))},Q.dh=function(e,t){var n,r;this.n&&e&&Xze(this,(n=new GPe,r=WM(n,e),Yht(n),r),(Mw(),I5))},Q.eh=function(e){var t;return this.b?null:(t=XKe(this,this.g),up(this.a,t),t.i=this,this.d=e,t)},Q.fh=function(e){e>0&&!this.b&&kJe(this,e)},Q.b=!1,Q.c=0,Q.d=-1,Q.e=null,Q.f=null,Q.g=-1,Q.j=!1,Q.k=!1,Q.n=!1,Q.o=0,Q.q=0,Q.r=0,L(gV,`BasicProgressMonitor`,344),q(717,205,OL,hse),Q.rf=function(e,t){Xdt(e,t)},L(gV,`BoxLayoutProvider`,717),q(983,1,GI,ehe),Q.Ne=function(e,t){return mot(this,P(e,27),P(t,27))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},Q.a=!1,L(gV,`BoxLayoutProvider/1`,983),q(163,1,{163:1},Fx,qEe),Q.Ib=function(){return this.c?Elt(this.c):CA(this.b)},L(gV,`BoxLayoutProvider/Group`,163),q(320,22,{3:1,34:1,22:1,320:1},Gc);var GBt,KBt,qBt,F5,JBt=aS(gV,`BoxLayoutProvider/PackingMode`,320,eG,NVe,oje),YBt;q(984,1,GI,gse),Q.Ne=function(e,t){return PIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$0$Type`,984),q(985,1,GI,_se),Q.Ne=function(e,t){return SIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$1$Type`,985),q(986,1,GI,vse),Q.Ne=function(e,t){return CIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$2$Type`,986),q(1384,1,{845:1},yse),Q.Mg=function(e,t){return zo(),!j(t,167)||Cye((lw(),P(e,167)),t)},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$0$Type`,1384),q(1385,1,$P,the),Q.Cd=function(e){EQe(this.a,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$1$Type`,1385),q(1386,1,$P,Sse),Q.Cd=function(e){P(e,96),zo()},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$2$Type`,1386),q(1390,1,$P,nhe),Q.Cd=function(e){sYe(this.a,P(e,96))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$3$Type`,1390),q(1388,1,vF,ySe),Q.Mb=function(e){return WZe(this.a,this.b,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$4$Type`,1388),q(1387,1,vF,bSe),Q.Mb=function(e){return wEe(this.a,this.b,P(e,845))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$5$Type`,1387),q(1389,1,$P,xSe),Q.Cd=function(e){nPe(this.a,this.b,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$6$Type`,1389),q(947,1,{},Cse),Q.Kb=function(e){return LCe(e)},Q.Fb=function(e){return this===e},L(gV,`ElkUtil/lambda$0$Type`,947),q(948,1,$P,SSe),Q.Cd=function(e){Gnt(this.a,this.b,P(e,74))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$1$Type`,948),q(949,1,$P,CSe),Q.Cd=function(e){X_e(this.a,this.b,P(e,166))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$2$Type`,949),q(950,1,$P,wSe),Q.Cd=function(e){rwe(this.a,this.b,P(e,135))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$3$Type`,950),q(951,1,$P,rhe),Q.Cd=function(e){jMe(this.a,P(e,377))},L(gV,`ElkUtil/lambda$4$Type`,951),q(325,1,{34:1,325:1},Er),Q.Fd=function(e){return aTe(this,P(e,242))},Q.Fb=function(e){var t;return j(e,325)?(t=P(e,325),this.a==t.a):!1},Q.Hb=function(){return C_(this.a)},Q.Ib=function(){return this.a+` (exclusive)`},Q.a=0,L(gV,`ExclusiveBounds/ExclusiveLowerBound`,325),q(1119,205,OL,wse),Q.rf=function(e,t){var n,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C;for(t.Ug(`Fixed Layout`,1),o=P(J(e,(vP(),uzt)),223),p=0,m=0,b=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));b.e!=b.i.gc();){for(v=P(gO(b),27),C=P(J(v,(Iw(),h8)),8),C&&($l(v,C.a,C.b),P(J(v,mBt),181).Hc((TD(),v5))&&(h=P(J(v,gBt),8),h.a>0&&h.b>0&&iP(v,h.a,h.b,!0,!0))),p=r.Math.max(p,v.i+v.g),m=r.Math.max(m,v.j+v.f),u=new Lu((!v.n&&(v.n=new F(Q5,v,1,7)),v.n));u.e!=u.i.gc();)c=P(gO(u),135),C=P(J(c,h8),8),C&&$l(c,C.a,C.b),p=r.Math.max(p,v.i+c.i+c.g),m=r.Math.max(m,v.j+c.j+c.f);for(ee=new Lu((!v.c&&(v.c=new F(e7,v,9,9)),v.c));ee.e!=ee.i.gc();)for(S=P(gO(ee),123),C=P(J(S,h8),8),C&&$l(S,C.a,C.b),te=v.i+S.i,ne=v.j+S.j,p=r.Math.max(p,te+S.g),m=r.Math.max(m,ne+S.f),l=new Lu((!S.n&&(S.n=new F(Q5,S,1,7)),S.n));l.e!=l.i.gc();)c=P(gO(l),135),C=P(J(c,h8),8),C&&$l(c,C.a,C.b),p=r.Math.max(p,te+c.i+c.g),m=r.Math.max(m,ne+c.j+c.f);for(a=new pm(Vu(Ij(v).a.Kc(),new d));Cj(a);)n=P(by(a),74),f=r_t(n),p=r.Math.max(p,f.a),m=r.Math.max(m,f.b);for(i=new pm(Vu(Fj(v).a.Kc(),new d));Cj(i);)n=P(by(i),74),I_(xA(n))!=e&&(f=r_t(n),p=r.Math.max(p,f.a),m=r.Math.max(m,f.b))}if(o==(wE(),l8))for(y=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));y.e!=y.i.gc();)for(v=P(gO(y),27),i=new pm(Vu(Ij(v).a.Kc(),new d));Cj(i);)n=P(by(i),74),s=Sdt(n),s.b==0?OO(n,x6,null):OO(n,x6,s);ki(Od(J(e,(Iw(),hBt))))||(x=P(J(e,_Bt),107),_=p+x.b+x.c,g=m+x.d+x.a,iP(e,_,g,!0,!0)),t.Vg()},L(gV,`FixedLayoutProvider`,1119),q(385,137,{3:1,423:1,385:1,96:1,137:1},en,uKe),Q.cg=function(e){var t,n,r,i,a,o,s,c,l;if(e)try{for(c=nN(e,`;,;`),a=c,o=0,s=a.length;o>16&OF|t^r<<16},Q.Kc=function(){return new ihe(this)},Q.Ib=function(){return this.a==null&&this.b==null?`pair(null,null)`:this.a==null?`pair(null,`+PE(this.b)+`)`:this.b==null?`pair(`+PE(this.a)+`,null)`:`pair(`+PE(this.a)+`,`+PE(this.b)+`)`},L(gV,`Pair`,42),q(995,1,VP,ihe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return!this.c&&(!this.b&&this.a.a!=null||this.a.b!=null)},Q.Pb=function(){if(!this.c&&!this.b&&this.a.a!=null)return this.b=!0,this.a.a;if(!this.c&&this.a.b!=null)return this.c=!0,this.a.b;throw E(new Hr)},Q.Qb=function(){throw this.c&&this.a.b!=null?this.a.b=null:this.b&&this.a.a!=null&&(this.a.a=null),E(new Rr)},Q.b=!1,Q.c=!1,L(gV,`Pair/1`,995),q(455,1,{455:1},cIe),Q.Fb=function(e){return rg(this.a,P(e,455).a)&&rg(this.c,P(e,455).c)&&rg(this.d,P(e,455).d)&&rg(this.b,P(e,455).b)},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.a,this.c,this.d,this.b]))},Q.Ib=function(){return`(`+this.a+PP+this.c+PP+this.d+PP+this.b+`)`},L(gV,`Quadruple`,455),q(1108,205,OL,xse),Q.rf=function(e,t){var n,r,i,a,o;if(t.Ug(`Random Layout`,1),(!e.a&&(e.a=new F($5,e,10,11)),e.a).i==0){t.Vg();return}a=P(J(e,(wD(),PBt)),17),i=a&&a.a!=0?new sy(a.a):new YE,n=Ai(N(J(e,jBt))),o=Ai(N(J(e,FBt))),r=P(J(e,MBt),107),wgt(e,i,n,o,r),t.Vg()},L(gV,`RandomLayoutProvider`,1108),q(240,1,{240:1},Vf),Q.Fb=function(e){return rg(this.a,P(e,240).a)&&rg(this.b,P(e,240).b)&&rg(this.c,P(e,240).c)},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.a,this.b,this.c]))},Q.Ib=function(){return`(`+this.a+PP+this.b+PP+this.c+`)`},L(gV,`Triple`,240);var nVt;q(562,1,{}),Q.Lf=function(){return new k(this.f.i,this.f.j)},Q.of=function(e){return nLe(e,(vP(),F6))?J(this.f,rVt):J(this.f,e)},Q.Mf=function(){return new k(this.f.g,this.f.f)},Q.Nf=function(){return this.g},Q.pf=function(e){return qy(this.f,e)},Q.Of=function(e){Gx(this.f,e.a),Kx(this.f,e.b)},Q.Pf=function(e){Wx(this.f,e.a),Ux(this.f,e.b)},Q.Qf=function(e){this.g=e},Q.g=0;var rVt;L(RH,`ElkGraphAdapters/AbstractElkGraphElementAdapter`,562),q(563,1,{853:1},_r),Q.Rf=function(){var e,t;if(!this.b)for(this.b=kv(ag(this.a).i),t=new Lu(ag(this.a));t.e!=t.i.gc();)e=P(gO(t),135),M(this.b,new Di(e));return this.b},Q.b=null,L(RH,`ElkGraphAdapters/ElkEdgeAdapter`,563),q(289,562,{},Ei),Q.Sf=function(){return k3e(this)},Q.a=null,L(RH,`ElkGraphAdapters/ElkGraphAdapter`,289),q(640,562,{187:1},Di),L(RH,`ElkGraphAdapters/ElkLabelAdapter`,640),q(639,562,{695:1},sd),Q.Rf=function(){return D3e(this)},Q.Vf=function(){var e;return e=P(J(this.f,(vP(),S6)),140),!e&&(e=new ei),e},Q.Xf=function(){return O3e(this)},Q.Zf=function(e){var t=new Kf(e);OO(this.f,(vP(),S6),t)},Q.$f=function(e){OO(this.f,(vP(),A6),new bje(e))},Q.Tf=function(){return this.d},Q.Uf=function(){var e,t;if(!this.a)for(this.a=new T,t=new pm(Vu(Fj(P(this.f,27)).a.Kc(),new d));Cj(t);)e=P(by(t),74),M(this.a,new _r(e));return this.a},Q.Wf=function(){var e,t;if(!this.c)for(this.c=new T,t=new pm(Vu(Ij(P(this.f,27)).a.Kc(),new d));Cj(t);)e=P(by(t),74),M(this.c,new _r(e));return this.c},Q.Yf=function(){return Gg(P(this.f,27)).i!=0||ki(Od(P(this.f,27).of((vP(),_6))))},Q._f=function(){dKe(this,(Ko(),nVt))},Q.a=null,Q.b=null,Q.c=null,Q.d=null,Q.e=null,L(RH,`ElkGraphAdapters/ElkNodeAdapter`,639),q(1284,562,{852:1},ahe),Q.Rf=function(){return H3e(this)},Q.Uf=function(){var e,t;if(!this.a)for(this.a=dd(P(this.f,123).hh().i),t=new Lu(P(this.f,123).hh());t.e!=t.i.gc();)e=P(gO(t),74),M(this.a,new _r(e));return this.a},Q.Wf=function(){var e,t;if(!this.c)for(this.c=dd(P(this.f,123).ih().i),t=new Lu(P(this.f,123).ih());t.e!=t.i.gc();)e=P(gO(t),74),M(this.c,new _r(e));return this.c},Q.ag=function(){return P(P(this.f,123).of((vP(),B6)),64)},Q.bg=function(){var e,t,n,r=E_(P(this.f,123)),i,a,o,s;for(n=new Lu(P(this.f,123).ih());n.e!=n.i.gc();)for(e=P(gO(n),74),s=new Lu((!e.c&&(e.c=new cf(H5,e,5,8)),e.c));s.e!=s.i.gc();)if(o=P(gO(s),84),Ex(cA(o),r)||cA(o)==r&&ki(Od(J(e,(vP(),v6)))))return!0;for(t=new Lu(P(this.f,123).hh());t.e!=t.i.gc();)for(e=P(gO(t),74),a=new Lu((!e.b&&(e.b=new cf(H5,e,4,7)),e.b));a.e!=a.i.gc();)if(i=P(gO(a),84),Ex(cA(i),r))return!0;return!1},Q.a=null,Q.b=null,Q.c=null,L(RH,`ElkGraphAdapters/ElkPortAdapter`,1284),q(1285,1,GI,bse),Q.Ne=function(e,t){return Tlt(P(e,123),P(t,123))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(RH,`ElkGraphAdapters/PortComparator`,1285);var L5=gp(zH,`EObject`),R5=gp(BH,VSt),z5=gp(BH,HSt),B5=gp(BH,USt),V5=gp(BH,`ElkShape`),H5=gp(BH,WSt),U5=gp(BH,GSt),W5=gp(BH,KSt),G5=gp(zH,qSt),K5=gp(zH,`EFactory`),iVt,q5=gp(zH,JSt),J5=gp(zH,`EPackage`),Y5,aVt,oVt,sVt,X5,cVt,lVt,uVt,dVt,Z5,fVt,pVt,Q5=gp(BH,YSt),$5=gp(BH,XSt),e7=gp(BH,ZSt);q(93,1,QSt),Q.th=function(){return this.uh(),null},Q.uh=function(){return null},Q.vh=function(){return this.uh(),!1},Q.wh=function(){return!1},Q.xh=function(e){AC(this,e)},L(VH,`BasicNotifierImpl`,93),q(99,93,nCt),Q.Yh=function(){return Gl(this)},Q.yh=function(e,t){return e},Q.zh=function(){throw E(new Br)},Q.Ah=function(e){var t;return t=qO(P(_x(this.Dh(),this.Fh()),19)),this.Ph().Th(this,t.n,t.f,e)},Q.Bh=function(e,t){throw E(new Br)},Q.Ch=function(e,t,n){return qM(this,e,t,n)},Q.Dh=function(){var e;return this.zh()&&(e=this.zh().Nk(),e)?e:this.ii()},Q.Eh=function(){return xj(this)},Q.Fh=function(){throw E(new Br)},Q.Gh=function(){var e,t=this.$h().Ok();return!t&&this.zh().Tk(t=(Yo(),e=MLe(aN(this.Dh())),e==null?i9:new ad(this,e))),t},Q.Hh=function(e,t){return e},Q.Ih=function(e){return e.pk()?e.Lj():eD(this.Dh(),e)},Q.Jh=function(){var e=this.zh();return e?e.Qk():null},Q.Kh=function(){return this.zh()?this.zh().Nk():null},Q.Lh=function(e,t,n){return jO(this,e,t,n)},Q.Mh=function(e){return mb(this,e)},Q.Nh=function(e,t){return wy(this,e,t)},Q.Oh=function(){var e=this.zh();return!!e&&e.Rk()},Q.Ph=function(){throw E(new Br)},Q.Qh=function(){return KD(this)},Q.Rh=function(e,t,n,r){return EO(this,e,t,r)},Q.Sh=function(e,t,n){var r;return r=P(_x(this.Dh(),t),69),r.wk().zk(this,this.hi(),t-this.ji(),e,n)},Q.Th=function(e,t,n,r){return m_(this,e,t,r)},Q.Uh=function(e,t,n){var r;return r=P(_x(this.Dh(),t),69),r.wk().Ak(this,this.hi(),t-this.ji(),e,n)},Q.Vh=function(){return!!this.zh()&&!!this.zh().Pk()},Q.Wh=function(e){return mO(this,e)},Q.Xh=function(e){return iRe(this,e)},Q.Zh=function(e){return Iht(this,e)},Q.$h=function(){throw E(new Br)},Q._h=function(){return this.zh()?this.zh().Pk():null},Q.ai=function(){return KD(this)},Q.bi=function(e,t){QA(this,e,t)},Q.ci=function(e){this.$h().Sk(e)},Q.di=function(e){this.$h().Vk(e)},Q.ei=function(e){this.$h().Uk(e)},Q.fi=function(e,t){var n,r,i,a=this.Jh();return a&&e&&(t=AO(a.El(),this,t),a.Il(this)),r=this.Ph(),r&&((IM(this,this.Ph(),this.Fh()).Bb&pI)==0?(t=(n=this.Fh(),n>=0?this.Ah(t):this.Ph().Th(this,-1-n,null,t)),t=this.Ch(null,-1,t)):(i=r.Qh(),i&&(e?!a&&i.Il(this):i.Hl(this)))),this.di(e),t},Q.gi=function(e){var t,n=this.Dh(),r,i,a=eD(n,e),o,s,c;if(t=this.ji(),a>=t)return P(e,69).wk().Dk(this,this.hi(),a-t);if(a<=-1){if(o=HN((UA(),l9),n,e),o){if(Qo(),P(o,69).xk()||(o=mv(Rb(l9,o))),i=(r=this.Ih(o),P(r>=0?this.Lh(r,!0,!0):mj(this,o,!0),160)),c=o.Ik(),c>1||c==-1)return P(P(i,220).Sl(e,!1),79)}else throw E(new Fi(HH+e.xe()+WH))}else if(e.Jk())return r=this.Ih(e),P(r>=0?this.Lh(r,!1,!0):mj(this,e,!1),79);return s=new JSe(this,e),s},Q.hi=function(){return Jb(this)},Q.ii=function(){return(vh(),z7).S},Q.ji=function(){return bh(this.ii())},Q.ki=function(e){BA(this,e)},Q.Ib=function(){return Aj(this)},L(KH,`BasicEObjectImpl`,99);var mVt;q(119,99,{110:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1}),Q.li=function(e){return qb(this)[e]},Q.mi=function(e,t){Sh(qb(this),e,t)},Q.ni=function(e){Sh(qb(this),e,null)},Q.th=function(){return P(NC(this,4),129)},Q.uh=function(){throw E(new Br)},Q.vh=function(){return!!(this.Db&4)},Q.zh=function(){throw E(new Br)},Q.oi=function(e){GD(this,2,e)},Q.Bh=function(e,t){this.Db=t<<16|this.Db&255,this.oi(e)},Q.Dh=function(){return d_(this)},Q.Fh=function(){return this.Db>>16},Q.Gh=function(){var e,t;return Yo(),t=MLe(aN((e=P(NC(this,16),29),e||this.ii()))),t==null?i9:new ad(this,t)},Q.wh=function(){return!(this.Db&1)},Q.Jh=function(){return P(NC(this,128),2034)},Q.Kh=function(){return P(NC(this,16),29)},Q.Oh=function(){return!!(this.Db&32)},Q.Ph=function(){return P(NC(this,2),54)},Q.Vh=function(){return!!(this.Db&64)},Q.$h=function(){throw E(new Br)},Q._h=function(){return P(NC(this,64),288)},Q.ci=function(e){GD(this,16,e)},Q.di=function(e){GD(this,128,e)},Q.ei=function(e){GD(this,64,e)},Q.hi=function(){return WD(this)},Q.Db=0,L(KH,`MinimalEObjectImpl`,119),q(120,119,{110:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.oi=function(e){this.Cb=e},Q.Ph=function(){return this.Cb},L(KH,`MinimalEObjectImpl/Container`,120),q(2083,120,{110:1,342:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return W3e(this,e,t,n)},Q.Uh=function(e,t,n){return x9e(this,e,t,n)},Q.Wh=function(e){return yBe(this,e)},Q.bi=function(e,t){qZe(this,e,t)},Q.ii=function(){return lP(),pVt},Q.ki=function(e){sZe(this,e)},Q.nf=function(){return H2e(this)},Q.gh=function(){return!this.o&&(this.o=new lb((lP(),Z5),n7,this,0)),this.o},Q.of=function(e){return J(this,e)},Q.pf=function(e){return qy(this,e)},Q.qf=function(e,t){return OO(this,e,t)},L(qH,`EMapPropertyHolderImpl`,2083),q(572,120,{110:1,377:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},tn),Q.Lh=function(e,t,n){switch(e){case 0:return this.a;case 1:return this.b}return jO(this,e,t,n)},Q.Wh=function(e){switch(e){case 0:return this.a!=0;case 1:return this.b!=0}return mO(this,e)},Q.bi=function(e,t){switch(e){case 0:Xx(this,D(N(t)));return;case 1:Vx(this,D(N(t)));return}QA(this,e,t)},Q.ii=function(){return lP(),aVt},Q.ki=function(e){switch(e){case 0:Xx(this,0);return;case 1:Vx(this,0);return}BA(this,e)},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new Wu(Aj(this)),e.a+=` (x: `,Ua(e,this.a),e.a+=`, y: `,Ua(e,this.b),e.a+=`)`,e.a)},Q.a=0,Q.b=0,L(qH,`ElkBendPointImpl`,572),q(739,2083,{110:1,342:1,167:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return ZT(this,e,t,n)},Q.Sh=function(e,t,n){return uA(this,e,t,n)},Q.Uh=function(e,t,n){return XC(this,e,t,n)},Q.Wh=function(e){return pXe(this,e)},Q.bi=function(e,t){V8e(this,e,t)},Q.ii=function(){return lP(),cVt},Q.ki=function(e){vT(this,e)},Q.jh=function(){return this.k},Q.kh=function(){return ag(this)},Q.Ib=function(){return pE(this)},Q.k=null,L(qH,`ElkGraphElementImpl`,739),q(740,739,{110:1,342:1,167:1,422:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return FE(this,e,t,n)},Q.Wh=function(e){return JE(this,e)},Q.bi=function(e,t){H8e(this,e,t)},Q.ii=function(){return lP(),fVt},Q.ki=function(e){dD(this,e)},Q.lh=function(){return this.f},Q.mh=function(){return this.g},Q.nh=function(){return this.i},Q.oh=function(){return this.j},Q.ph=function(e,t){Ql(this,e,t)},Q.qh=function(e,t){$l(this,e,t)},Q.rh=function(e){Gx(this,e)},Q.sh=function(e){Kx(this,e)},Q.Ib=function(){return AA(this)},Q.f=0,Q.g=0,Q.i=0,Q.j=0,L(qH,`ElkShapeImpl`,740),q(741,740,{110:1,342:1,84:1,167:1,422:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return tk(this,e,t,n)},Q.Sh=function(e,t,n){return b8e(this,e,t,n)},Q.Uh=function(e,t,n){return x8e(this,e,t,n)},Q.Wh=function(e){return BZe(this,e)},Q.bi=function(e,t){cit(this,e,t)},Q.ii=function(){return lP(),oVt},Q.ki=function(e){DO(this,e)},Q.hh=function(){return!this.d&&(this.d=new cf(U5,this,8,5)),this.d},Q.ih=function(){return!this.e&&(this.e=new cf(U5,this,7,4)),this.e},L(qH,`ElkConnectableShapeImpl`,741),q(326,739,{110:1,342:1,74:1,167:1,326:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},nn),Q.Ah=function(e){return P6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 3:return T_(this);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),this.b;case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),this.c;case 6:return!this.a&&(this.a=new F(W5,this,6,6)),this.a;case 7:return rd(),!this.b&&(this.b=new cf(H5,this,4,7)),!(this.b.i<=1&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i<=1));case 8:return rd(),!!yj(this);case 9:return rd(),!!uj(this);case 10:return rd(),!this.b&&(this.b=new cf(H5,this,4,7)),this.b.i!=0&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i!=0)}return ZT(this,e,t,n)},Q.Sh=function(e,t,n){var r;switch(t){case 3:return this.Cb&&(n=(r=this.Db>>16,r>=0?P6e(this,n):this.Cb.Th(this,-1-r,null,n))),Bd(this,P(e,27),n);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),vD(this.b,e,n);case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),vD(this.c,e,n);case 6:return!this.a&&(this.a=new F(W5,this,6,6)),vD(this.a,e,n)}return uA(this,e,t,n)},Q.Uh=function(e,t,n){switch(t){case 3:return Bd(this,null,n);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),AO(this.b,e,n);case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),AO(this.c,e,n);case 6:return!this.a&&(this.a=new F(W5,this,6,6)),AO(this.a,e,n)}return XC(this,e,t,n)},Q.Wh=function(e){switch(e){case 3:return!!T_(this);case 4:return!!this.b&&this.b.i!=0;case 5:return!!this.c&&this.c.i!=0;case 6:return!!this.a&&this.a.i!=0;case 7:return!this.b&&(this.b=new cf(H5,this,4,7)),!(this.b.i<=1&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i<=1));case 8:return yj(this);case 9:return uj(this);case 10:return!this.b&&(this.b=new cf(H5,this,4,7)),this.b.i!=0&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i!=0)}return pXe(this,e)},Q.bi=function(e,t){switch(e){case 3:Hj(this,P(t,27));return;case 4:!this.b&&(this.b=new cf(H5,this,4,7)),RN(this.b),!this.b&&(this.b=new cf(H5,this,4,7)),th(this.b,P(t,16));return;case 5:!this.c&&(this.c=new cf(H5,this,5,8)),RN(this.c),!this.c&&(this.c=new cf(H5,this,5,8)),th(this.c,P(t,16));return;case 6:!this.a&&(this.a=new F(W5,this,6,6)),RN(this.a),!this.a&&(this.a=new F(W5,this,6,6)),th(this.a,P(t,16));return}V8e(this,e,t)},Q.ii=function(){return lP(),sVt},Q.ki=function(e){switch(e){case 3:Hj(this,null);return;case 4:!this.b&&(this.b=new cf(H5,this,4,7)),RN(this.b);return;case 5:!this.c&&(this.c=new cf(H5,this,5,8)),RN(this.c);return;case 6:!this.a&&(this.a=new F(W5,this,6,6)),RN(this.a);return}vT(this,e)},Q.Ib=function(){return ipt(this)},L(qH,`ElkEdgeImpl`,326),q(452,2083,{110:1,342:1,166:1,452:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},rn),Q.Ah=function(e){return b6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 1:return this.j;case 2:return this.k;case 3:return this.b;case 4:return this.c;case 5:return!this.a&&(this.a=new ju(z5,this,5)),this.a;case 6:return QLe(this);case 7:return t?KO(this):this.i;case 8:return t?GO(this):this.f;case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),this.g;case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),this.e;case 11:return this.d}return W3e(this,e,t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?b6e(this,n):this.Cb.Th(this,-1-i,null,n))),jDe(this,P(e,74),n);case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),vD(this.g,e,n);case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),vD(this.e,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(lP(),X5)),t),69),a.wk().zk(this,WD(this),t-bh((lP(),X5)),e,n)},Q.Uh=function(e,t,n){switch(t){case 5:return!this.a&&(this.a=new ju(z5,this,5)),AO(this.a,e,n);case 6:return jDe(this,null,n);case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),AO(this.g,e,n);case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),AO(this.e,e,n)}return x9e(this,e,t,n)},Q.Wh=function(e){switch(e){case 1:return this.j!=0;case 2:return this.k!=0;case 3:return this.b!=0;case 4:return this.c!=0;case 5:return!!this.a&&this.a.i!=0;case 6:return!!QLe(this);case 7:return!!this.i;case 8:return!!this.f;case 9:return!!this.g&&this.g.i!=0;case 10:return!!this.e&&this.e.i!=0;case 11:return this.d!=null}return yBe(this,e)},Q.bi=function(e,t){switch(e){case 1:qx(this,D(N(t)));return;case 2:Yx(this,D(N(t)));return;case 3:Hx(this,D(N(t)));return;case 4:Jx(this,D(N(t)));return;case 5:!this.a&&(this.a=new ju(z5,this,5)),RN(this.a),!this.a&&(this.a=new ju(z5,this,5)),th(this.a,P(t,16));return;case 6:Jat(this,P(t,74));return;case 7:ES(this,P(t,84));return;case 8:TS(this,P(t,84));return;case 9:!this.g&&(this.g=new cf(W5,this,9,10)),RN(this.g),!this.g&&(this.g=new cf(W5,this,9,10)),th(this.g,P(t,16));return;case 10:!this.e&&(this.e=new cf(W5,this,10,9)),RN(this.e),!this.e&&(this.e=new cf(W5,this,10,9)),th(this.e,P(t,16));return;case 11:qJe(this,kd(t));return}qZe(this,e,t)},Q.ii=function(){return lP(),X5},Q.ki=function(e){switch(e){case 1:qx(this,0);return;case 2:Yx(this,0);return;case 3:Hx(this,0);return;case 4:Jx(this,0);return;case 5:!this.a&&(this.a=new ju(z5,this,5)),RN(this.a);return;case 6:Jat(this,null);return;case 7:ES(this,null);return;case 8:TS(this,null);return;case 9:!this.g&&(this.g=new cf(W5,this,9,10)),RN(this.g);return;case 10:!this.e&&(this.e=new cf(W5,this,10,9)),RN(this.e);return;case 11:qJe(this,null);return}sZe(this,e)},Q.Ib=function(){return xrt(this)},Q.b=0,Q.c=0,Q.d=null,Q.j=0,Q.k=0,L(qH,`ElkEdgeSectionImpl`,452),q(158,120,{110:1,94:1,93:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1}),Q.Lh=function(e,t,n){var r;return e==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab):xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i;return t==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n)):(i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().zk(this,WD(this),t-bh(this.ii()),e,n))},Q.Uh=function(e,t,n){var r,i;return t==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n)):(i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n))},Q.Wh=function(e){var t;return e==0?!!this.Ab&&this.Ab.i!=0:Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.Zh=function(e){return rP(this,e)},Q.bi=function(e,t){var n;if(e===0){!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.di=function(e){GD(this,128,e)},Q.ii=function(){return CP(),qVt},Q.ki=function(e){var t;if(e===0){!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){this.Bb|=1},Q.qi=function(e){return JM(this,e)},Q.Bb=0,L(KH,`EModelElementImpl`,158),q(720,158,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1},$ue),Q.ri=function(e,t){return yht(this,e,t)},Q.si=function(e){var t,n,r,i,a;if(this.a!=Mx(e)||e.Bb&256)throw E(new Fi($H+e.zb+XH));for(r=l_(e);Jv(r.a).i!=0;){if(n=P(GN(r,0,(t=P(H(Jv(r.a),0),89),a=t.c,j(a,90)?P(a,29):(CP(),J7))),29),_k(n))return i=Mx(n).wi().si(n),P(i,54).ci(e),i;r=l_(n)}return(e.D==null?e.B:e.D)==`java.util.Map$Entry`?new OMe(e):new eMe(e)},Q.ti=function(e,t){return uP(this,e,t)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.a}return xb(this,e-bh((CP(),G7)),_x((r=P(NC(this,16),29),r||G7),e),t,n)},Q.Sh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 1:return this.a&&(n=P(this.a,54).Th(this,4,J5,n)),mT(this,P(e,241),n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),G7)),t),69),i.wk().zk(this,WD(this),t-bh((CP(),G7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 1:return mT(this,null,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),G7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),G7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return!!this.a}return Hv(this,e-bh((CP(),G7)),_x((t=P(NC(this,16),29),t||G7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:r9e(this,P(t,241));return}LE(this,e-bh((CP(),G7)),_x((n=P(NC(this,16),29),n||G7),e),t)},Q.ii=function(){return CP(),G7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:r9e(this,null);return}PT(this,e-bh((CP(),G7)),_x((t=P(NC(this,16),29),t||G7),e))};var t7,hVt,gVt;L(KH,`EFactoryImpl`,720),q(1037,720,{110:1,2113:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1},kse),Q.ri=function(e,t){switch(e.hk()){case 12:return P(t,149).Pg();case 13:return PE(t);default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a,o,s,c;switch(e.G==-1&&(e.G=(t=Mx(e),t?NO(t.vi(),e):-1)),e.G){case 4:return a=new Ase,a;case 6:return o=new ii,o;case 7:return s=new s_e,s;case 8:return r=new nn,r;case 9:return n=new tn,n;case 10:return i=new rn,i;case 11:return c=new jse,c;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){switch(e.hk()){case 13:case 12:return null;default:throw E(new Fi(YH+e.xe()+XH))}},L(qH,`ElkGraphFactoryImpl`,1037),q(448,158,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1}),Q.Gh=function(){var e,t=(e=P(NC(this,16),29),MLe(aN(e||this.ii())));return t==null?(Yo(),Yo(),i9):new VEe(this,t)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.xe()}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:this.ui(kd(t));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),JVt},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:this.ui(null);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.xe=function(){return this.zb},Q.ui=function(e){GS(this,e)},Q.Ib=function(){return DT(this)},Q.zb=null,L(KH,`ENamedElementImpl`,448),q(184,448,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1},IIe),Q.Ah=function(e){return w6e(this,e)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.yb;case 3:return this.xb;case 4:return this.sb;case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),this.rb;case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),this.vb;case 7:return t?this.Db>>16==7?P(this.Cb,241):null:pRe(this)}return xb(this,e-bh((CP(),X7)),_x((r=P(NC(this,16),29),r||X7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 4:return this.sb&&(n=P(this.sb,54).Th(this,1,K5,n)),OT(this,P(e,480),n);case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),vD(this.rb,e,n);case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),vD(this.vb,e,n);case 7:return this.Cb&&(n=(i=this.Db>>16,i>=0?w6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,7,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),X7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),X7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 4:return OT(this,null,n);case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),AO(this.rb,e,n);case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),AO(this.vb,e,n);case 7:return qM(this,null,7,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),X7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),X7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.yb!=null;case 3:return this.xb!=null;case 4:return!!this.sb;case 5:return!!this.rb&&this.rb.i!=0;case 6:return!!this.vb&&this.vb.i!=0;case 7:return!!pRe(this)}return Hv(this,e-bh((CP(),X7)),_x((t=P(NC(this,16),29),t||X7),e))},Q.Zh=function(e){return Mot(this,e)||rP(this,e)},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:qS(this,kd(t));return;case 3:KS(this,kd(t));return;case 4:EA(this,P(t,480));return;case 5:!this.rb&&(this.rb=new Tm(this,E7,this)),RN(this.rb),!this.rb&&(this.rb=new Tm(this,E7,this)),th(this.rb,P(t,16));return;case 6:!this.vb&&(this.vb=new nf(J5,this,6,7)),RN(this.vb),!this.vb&&(this.vb=new nf(J5,this,6,7)),th(this.vb,P(t,16));return}LE(this,e-bh((CP(),X7)),_x((n=P(NC(this,16),29),n||X7),e),t)},Q.ei=function(e){var t,n;if(e&&this.rb)for(n=new Lu(this.rb);n.e!=n.i.gc();)t=gO(n),j(t,364)&&(P(t,364).w=null);GD(this,64,e)},Q.ii=function(){return CP(),X7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:qS(this,null);return;case 3:KS(this,null);return;case 4:EA(this,null);return;case 5:!this.rb&&(this.rb=new Tm(this,E7,this)),RN(this.rb);return;case 6:!this.vb&&(this.vb=new nf(J5,this,6,7)),RN(this.vb);return}PT(this,e-bh((CP(),X7)),_x((t=P(NC(this,16),29),t||X7),e))},Q.pi=function(){Ck(this)},Q.vi=function(){return!this.rb&&(this.rb=new Tm(this,E7,this)),this.rb},Q.wi=function(){return this.sb},Q.xi=function(){return this.ub},Q.yi=function(){return this.xb},Q.zi=function(){return this.yb},Q.Ai=function(e){this.ub=e},Q.Ib=function(){var e;return this.Db&64?DT(this):(e=new Wu(DT(this)),e.a+=` (nsURI: `,pl(e,this.yb),e.a+=`, nsPrefix: `,pl(e,this.xb),e.a+=`)`,e.a)},Q.xb=null,Q.yb=null;var _Vt;L(KH,`EPackageImpl`,184),q(569,184,{110:1,2115:1,569:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1},Urt),Q.q=!1,Q.r=!1;var vVt=!1;L(qH,`ElkGraphPackageImpl`,569),q(366,740,{110:1,342:1,167:1,135:1,422:1,366:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},Ase),Q.Ah=function(e){return x6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 7:return mRe(this);case 8:return this.a}return FE(this,e,t,n)},Q.Sh=function(e,t,n){var r;return t===7?(this.Cb&&(n=(r=this.Db>>16,r>=0?x6e(this,n):this.Cb.Th(this,-1-r,null,n))),jNe(this,P(e,167),n)):uA(this,e,t,n)},Q.Uh=function(e,t,n){return t==7?jNe(this,null,n):XC(this,e,t,n)},Q.Wh=function(e){switch(e){case 7:return!!mRe(this);case 8:return!ff(``,this.a)}return JE(this,e)},Q.bi=function(e,t){switch(e){case 7:kot(this,P(t,167));return;case 8:jJe(this,kd(t));return}H8e(this,e,t)},Q.ii=function(){return lP(),lVt},Q.ki=function(e){switch(e){case 7:kot(this,null);return;case 8:jJe(this,``);return}dD(this,e)},Q.Ib=function(){return get(this)},Q.a=``,L(qH,`ElkLabelImpl`,366),q(207,741,{110:1,342:1,84:1,167:1,27:1,422:1,207:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},ii),Q.Ah=function(e){return F6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),this.c;case 10:return!this.a&&(this.a=new F($5,this,10,11)),this.a;case 11:return I_(this);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),this.b;case 13:return rd(),!this.a&&(this.a=new F($5,this,10,11)),this.a.i>0}return tk(this,e,t,n)},Q.Sh=function(e,t,n){var r;switch(t){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),vD(this.c,e,n);case 10:return!this.a&&(this.a=new F($5,this,10,11)),vD(this.a,e,n);case 11:return this.Cb&&(n=(r=this.Db>>16,r>=0?F6e(this,n):this.Cb.Th(this,-1-r,null,n))),tf(this,P(e,27),n);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),vD(this.b,e,n)}return b8e(this,e,t,n)},Q.Uh=function(e,t,n){switch(t){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),AO(this.c,e,n);case 10:return!this.a&&(this.a=new F($5,this,10,11)),AO(this.a,e,n);case 11:return tf(this,null,n);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),AO(this.b,e,n)}return x8e(this,e,t,n)},Q.Wh=function(e){switch(e){case 9:return!!this.c&&this.c.i!=0;case 10:return!!this.a&&this.a.i!=0;case 11:return!!I_(this);case 12:return!!this.b&&this.b.i!=0;case 13:return!this.a&&(this.a=new F($5,this,10,11)),this.a.i>0}return BZe(this,e)},Q.bi=function(e,t){switch(e){case 9:!this.c&&(this.c=new F(e7,this,9,9)),RN(this.c),!this.c&&(this.c=new F(e7,this,9,9)),th(this.c,P(t,16));return;case 10:!this.a&&(this.a=new F($5,this,10,11)),RN(this.a),!this.a&&(this.a=new F($5,this,10,11)),th(this.a,P(t,16));return;case 11:Gj(this,P(t,27));return;case 12:!this.b&&(this.b=new F(U5,this,12,3)),RN(this.b),!this.b&&(this.b=new F(U5,this,12,3)),th(this.b,P(t,16));return}cit(this,e,t)},Q.ii=function(){return lP(),uVt},Q.ki=function(e){switch(e){case 9:!this.c&&(this.c=new F(e7,this,9,9)),RN(this.c);return;case 10:!this.a&&(this.a=new F($5,this,10,11)),RN(this.a);return;case 11:Gj(this,null);return;case 12:!this.b&&(this.b=new F(U5,this,12,3)),RN(this.b);return}DO(this,e)},Q.Ib=function(){return Elt(this)},L(qH,`ElkNodeImpl`,207),q(193,741,{110:1,342:1,84:1,167:1,123:1,422:1,193:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},s_e),Q.Ah=function(e){return S6e(this,e)},Q.Lh=function(e,t,n){return e==9?E_(this):tk(this,e,t,n)},Q.Sh=function(e,t,n){var r;return t===9?(this.Cb&&(n=(r=this.Db>>16,r>=0?S6e(this,n):this.Cb.Th(this,-1-r,null,n))),Vd(this,P(e,27),n)):b8e(this,e,t,n)},Q.Uh=function(e,t,n){return t==9?Vd(this,null,n):x8e(this,e,t,n)},Q.Wh=function(e){return e==9?!!E_(this):BZe(this,e)},Q.bi=function(e,t){if(e===9){Yat(this,P(t,27));return}cit(this,e,t)},Q.ii=function(){return lP(),dVt},Q.ki=function(e){if(e===9){Yat(this,null);return}DO(this,e)},Q.Ib=function(){return Dlt(this)},L(qH,`ElkPortImpl`,193);var yVt=gp(uU,`BasicEMap/Entry`);q(1122,120,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1,119:1,120:1},jse),Q.Fb=function(e){return this===e},Q.ld=function(){return this.b},Q.Hb=function(){return td(this)},Q.Di=function(e){MJe(this,P(e,149))},Q.Lh=function(e,t,n){switch(e){case 0:return this.b;case 1:return this.c}return jO(this,e,t,n)},Q.Wh=function(e){switch(e){case 0:return!!this.b;case 1:return this.c!=null}return mO(this,e)},Q.bi=function(e,t){switch(e){case 0:MJe(this,P(t,149));return;case 1:AJe(this,t);return}QA(this,e,t)},Q.ii=function(){return lP(),Z5},Q.ki=function(e){switch(e){case 0:MJe(this,null);return;case 1:AJe(this,null);return}BA(this,e)},Q.Bi=function(){var e;return this.a==-1&&(e=this.b,this.a=e?US(e):0),this.a},Q.md=function(){return this.c},Q.Ci=function(e){this.a=e},Q.nd=function(e){var t=this.c;return AJe(this,e),t},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new ta,gl(gl(gl(e,this.b?this.b.Pg():IP),kR),Uu(this.c)),e.a)},Q.a=-1,Q.c=null;var n7=L(qH,`ElkPropertyToValueMapEntryImpl`,1122);q(996,1,{},Pse),L(fU,`JsonAdapter`,996),q(216,63,SF,Vi),L(fU,`JsonImportException`,216),q(868,1,{},E6e),L(fU,`JsonImporter`,868),q(903,1,{},TSe),L(fU,`JsonImporter/lambda$0$Type`,903),q(904,1,{},ESe),L(fU,`JsonImporter/lambda$1$Type`,904),q(912,1,{},ohe),L(fU,`JsonImporter/lambda$10$Type`,912),q(914,1,{},DSe),L(fU,`JsonImporter/lambda$11$Type`,914),q(915,1,{},OSe),L(fU,`JsonImporter/lambda$12$Type`,915),q(921,1,{},pIe),L(fU,`JsonImporter/lambda$13$Type`,921),q(920,1,{},mIe),L(fU,`JsonImporter/lambda$14$Type`,920),q(916,1,{},kSe),L(fU,`JsonImporter/lambda$15$Type`,916),q(917,1,{},ASe),L(fU,`JsonImporter/lambda$16$Type`,917),q(918,1,{},jSe),L(fU,`JsonImporter/lambda$17$Type`,918),q(919,1,{},MSe),L(fU,`JsonImporter/lambda$18$Type`,919),q(924,1,{},she),L(fU,`JsonImporter/lambda$19$Type`,924),q(905,1,{},che),L(fU,`JsonImporter/lambda$2$Type`,905),q(922,1,{},lhe),L(fU,`JsonImporter/lambda$20$Type`,922),q(923,1,{},uhe),L(fU,`JsonImporter/lambda$21$Type`,923),q(927,1,{},dhe),L(fU,`JsonImporter/lambda$22$Type`,927),q(925,1,{},fhe),L(fU,`JsonImporter/lambda$23$Type`,925),q(926,1,{},phe),L(fU,`JsonImporter/lambda$24$Type`,926),q(929,1,{},mhe),L(fU,`JsonImporter/lambda$25$Type`,929),q(928,1,{},hhe),L(fU,`JsonImporter/lambda$26$Type`,928),q(930,1,$P,NSe),Q.Cd=function(e){mGe(this.b,this.a,kd(e))},L(fU,`JsonImporter/lambda$27$Type`,930),q(931,1,$P,PSe),Q.Cd=function(e){hGe(this.b,this.a,kd(e))},L(fU,`JsonImporter/lambda$28$Type`,931),q(932,1,{},FSe),L(fU,`JsonImporter/lambda$29$Type`,932),q(908,1,{},ghe),L(fU,`JsonImporter/lambda$3$Type`,908),q(933,1,{},ISe),L(fU,`JsonImporter/lambda$30$Type`,933),q(934,1,{},_he),L(fU,`JsonImporter/lambda$31$Type`,934),q(935,1,{},vhe),L(fU,`JsonImporter/lambda$32$Type`,935),q(936,1,{},yhe),L(fU,`JsonImporter/lambda$33$Type`,936),q(937,1,{},bhe),L(fU,`JsonImporter/lambda$34$Type`,937),q(870,1,{},xhe),L(fU,`JsonImporter/lambda$35$Type`,870),q(941,1,{},uje),L(fU,`JsonImporter/lambda$36$Type`,941),q(938,1,$P,She),Q.Cd=function(e){XHe(this.a,P(e,377))},L(fU,`JsonImporter/lambda$37$Type`,938),q(939,1,$P,LSe),Q.Cd=function(e){WSe(this.a,this.b,P(e,166))},L(fU,`JsonImporter/lambda$38$Type`,939),q(940,1,$P,RSe),Q.Cd=function(e){GSe(this.a,this.b,P(e,166))},L(fU,`JsonImporter/lambda$39$Type`,940),q(906,1,{},Che),L(fU,`JsonImporter/lambda$4$Type`,906),q(942,1,$P,whe),Q.Cd=function(e){ZHe(this.a,P(e,8))},L(fU,`JsonImporter/lambda$40$Type`,942),q(907,1,{},The),L(fU,`JsonImporter/lambda$5$Type`,907),q(911,1,{},Ehe),L(fU,`JsonImporter/lambda$6$Type`,911),q(909,1,{},Dhe),L(fU,`JsonImporter/lambda$7$Type`,909),q(910,1,{},Ohe),L(fU,`JsonImporter/lambda$8$Type`,910),q(913,1,{},khe),L(fU,`JsonImporter/lambda$9$Type`,913),q(961,1,$P,Ahe),Q.Cd=function(e){Dh(this.a,new mh(kd(e)))},L(fU,`JsonMetaDataConverter/lambda$0$Type`,961),q(962,1,$P,jhe),Q.Cd=function(e){VPe(this.a,P(e,245))},L(fU,`JsonMetaDataConverter/lambda$1$Type`,962),q(963,1,$P,Mhe),Q.Cd=function(e){FRe(this.a,P(e,143))},L(fU,`JsonMetaDataConverter/lambda$2$Type`,963),q(964,1,$P,Nhe),Q.Cd=function(e){HPe(this.a,P(e,170))},L(fU,`JsonMetaDataConverter/lambda$3$Type`,964),q(245,22,{3:1,34:1,22:1,245:1},Jc);var r7,i7,a7,o7,s7,c7,l7,u7,d7=aS(EL,`GraphFeature`,245,eG,nqe,Sje),bVt;q(11,1,{34:1,149:1},yr,Wd,Tl,ou),Q.Fd=function(e){return oTe(this,P(e,149))},Q.Fb=function(e){return nLe(this,e)},Q.Sg=function(){return hO(this)},Q.Pg=function(){return this.b},Q.Hb=function(){return jw(this.b)},Q.Ib=function(){return this.b},L(EL,`Property`,11),q(671,1,GI,vr),Q.Ne=function(e,t){return h1e(this,P(e,96),P(t,96))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(EL,`PropertyHolderComparator`,671),q(709,1,VP,Phe),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return vGe(this)},Q.Qb=function(){uye()},Q.Ob=function(){return!!this.a},L(_U,`ElkGraphUtil/AncestorIterator`,709);var xVt=gp(uU,`EList`);q(70,56,{20:1,31:1,56:1,16:1,15:1,70:1,61:1}),Q.bd=function(e,t){WT(this,e,t)},Q.Fc=function(e){return tb(this,e)},Q.cd=function(e,t){return lZe(this,e,t)},Q.Gc=function(e){return th(this,e)},Q.Ii=function(){return new ld(this)},Q.Ji=function(){return new ud(this)},Q.Ki=function(e){return mS(this,e)},Q.Li=function(){return!0},Q.Mi=function(e,t){},Q.Ni=function(){},Q.Oi=function(e,t){Xy(this,e,t)},Q.Pi=function(e,t,n){},Q.Qi=function(e,t){},Q.Ri=function(e,t,n){},Q.Fb=function(e){return Mct(this,e)},Q.Hb=function(){return qXe(this)},Q.Si=function(){return!1},Q.Kc=function(){return new Lu(this)},Q.ed=function(){return new cd(this)},Q.fd=function(e){var t=this.gc();if(e<0||e>t)throw E(new lf(e,t));return new Hm(this,e)},Q.Ui=function(e,t){this.Ti(e,this.dd(t))},Q.Mc=function(e){return nx(this,e)},Q.Wi=function(e,t){return t},Q.hd=function(e,t){return PO(this,e,t)},Q.Ib=function(){return HE(this)},Q.Yi=function(){return!0},Q.Zi=function(e,t){return Aw(this,t)},L(uU,`AbstractEList`,70),q(66,70,SU,an,kx,hC),Q.Ei=function(e,t){return dA(this,e,t)},Q.Fi=function(e){return X4e(this,e)},Q.Gi=function(e,t){jT(this,e,t)},Q.Hi=function(e){Ty(this,e)},Q.$i=function(e){return SGe(this,e)},Q.$b=function(){Ey(this)},Q.Hc=function(e){return Uk(this,e)},Q.Xb=function(e){return H(this,e)},Q._i=function(e){var t,n,r;++this.j,n=this.g==null?0:this.g.length,e>n&&(r=this.g,t=n+(n/2|0)+4,t=0&&(this.gd(t),!0)},Q.Xi=function(e,t){return this.Dj(e,this.Zi(e,t))},Q.gc=function(){return this.Ej()},Q.Pc=function(){return this.Fj()},Q.Qc=function(e){return this.Gj(e)},Q.Ib=function(){return this.Hj()},L(uU,`DelegatingEList`,2093),q(2094,2093,rwt),Q.Ei=function(e,t){return wdt(this,e,t)},Q.Fi=function(e){return this.Ei(this.Ej(),e)},Q.Gi=function(e,t){Wrt(this,e,t)},Q.Hi=function(e){_rt(this,e)},Q.Li=function(){return!this.Mj()},Q.$b=function(){zN(this)},Q.Ij=function(e,t,n,r,i){return new eLe(this,e,t,n,r,i)},Q.Jj=function(e){AC(this.jj(),e)},Q.Kj=function(){return null},Q.Lj=function(){return-1},Q.jj=function(){return null},Q.Mj=function(){return!1},Q.Nj=function(e,t){return t},Q.Oj=function(e,t){return t},Q.Pj=function(){return!1},Q.Qj=function(){return!this.Aj()},Q.Ti=function(e,t){var n,r;return this.Pj()?(r=this.Qj(),n=e9e(this,e,t),this.Jj(this.Ij(7,G(t),n,e,r)),n):e9e(this,e,t)},Q.gd=function(e){var t,n,r,i;return this.Pj()?(n=null,r=this.Qj(),t=this.Ij(4,i=_p(this,e),null,e,r),this.Mj()&&i&&(n=this.Oj(i,n)),n?(n.nj(t),n.oj()):this.Jj(t),i):(i=_p(this,e),this.Mj()&&i&&(n=this.Oj(i,null),n&&n.oj()),i)},Q.Xi=function(e,t){return Tdt(this,e,t)},L(VH,`DelegatingNotifyingListImpl`,2094),q(152,1,NU),Q.nj=function(e){return T5e(this,e)},Q.oj=function(){Pb(this)},Q.gj=function(){return this.d},Q.Kj=function(){return null},Q.Rj=function(){return null},Q.hj=function(e){return-1},Q.ij=function(){return Ast(this)},Q.jj=function(){return null},Q.kj=function(){return jst(this)},Q.lj=function(){return this.o<0?this.o<-2?-2-this.o-1:-1:this.o},Q.Sj=function(){return!1},Q.mj=function(e){var t,n,r,i,a,o,s,c,l,u,d;switch(this.d){case 1:case 2:switch(i=e.gj(),i){case 1:case 2:if(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null))return this.g=e.ij(),e.gj()==1&&(this.d=1),!0}case 4:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null)))return l=Fmt(this),c=this.o<0?this.o<-2?-2-this.o-1:-1:this.o,o=e.lj(),this.d=6,d=new kx(2),c<=o?(tb(d,this.n),tb(d,e.kj()),this.g=U(O(q9,1),HF,28,15,[this.o=c,o+1])):(tb(d,e.kj()),tb(d,this.n),this.g=U(O(q9,1),HF,28,15,[this.o=o,c])),this.n=d,l||(this.o=-2-this.o-1),!0;break;case 6:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null))){for(l=Fmt(this),o=e.lj(),u=P(this.g,53),r=V(q9,HF,28,u.length+1,15,1),t=0;t>>0,t.toString(16)));switch(r.a+=` (eventType: `,this.d){case 1:r.a+=`SET`;break;case 2:r.a+=`UNSET`;break;case 3:r.a+=`ADD`;break;case 5:r.a+=`ADD_MANY`;break;case 4:r.a+=`REMOVE`;break;case 6:r.a+=`REMOVE_MANY`;break;case 7:r.a+=`MOVE`;break;case 8:r.a+=`REMOVING_ADAPTER`;break;case 9:r.a+=`RESOLVE`;break;default:Wa(r,this.d)}if(Ult(this)&&(r.a+=`, touch: true`),r.a+=`, position: `,Wa(r,this.o<0?this.o<-2?-2-this.o-1:-1:this.o),r.a+=`, notifier: `,fl(r,this.jj()),r.a+=`, feature: `,fl(r,this.Kj()),r.a+=`, oldValue: `,fl(r,jst(this)),r.a+=`, newValue: `,this.d==6&&j(this.g,53)){for(n=P(this.g,53),r.a+=`[`,e=0;e10?((!this.b||this.c.j!=this.a)&&(this.b=new jp(this),this.a=this.j),mo(this.b,e)):Uk(this,e)},Q.Yi=function(){return!0},Q.a=0,L(uU,`AbstractEList/1`,966),q(302,77,oI,lf),L(uU,`AbstractEList/BasicIndexOutOfBoundsException`,302),q(37,1,VP,Lu),Q.Nb=function(e){Om(this,e)},Q.Xj=function(){if(this.i.j!=this.f)throw E(new Vr)},Q.Yj=function(){return gO(this)},Q.Ob=function(){return this.e!=this.i.gc()},Q.Pb=function(){return this.Yj()},Q.Qb=function(){Yk(this)},Q.e=0,Q.f=0,Q.g=-1,L(uU,`AbstractEList/EIterator`,37),q(286,37,YP,cd,Hm),Q.Qb=function(){Yk(this)},Q.Rb=function(e){y0e(this,e)},Q.Zj=function(){var e;try{return e=this.d.Xb(--this.e),this.Xj(),this.g=this.e,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.$j=function(e){i3e(this,e)},Q.Sb=function(){return this.e!=0},Q.Tb=function(){return this.e},Q.Ub=function(){return this.Zj()},Q.Vb=function(){return this.e-1},Q.Wb=function(e){this.$j(e)},L(uU,`AbstractEList/EListIterator`,286),q(355,37,VP,ld),Q.Yj=function(){return _O(this)},Q.Qb=function(){throw E(new Br)},L(uU,`AbstractEList/NonResolvingEIterator`,355),q(398,286,YP,ud,LOe),Q.Rb=function(e){throw E(new Br)},Q.Yj=function(){var e;try{return e=this.c.Vi(this.e),this.Xj(),this.g=this.e++,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.Zj=function(){var e;try{return e=this.c.Vi(--this.e),this.Xj(),this.g=this.e,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.Qb=function(){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(uU,`AbstractEList/NonResolvingEListIterator`,398),q(2080,70,iwt),Q.Ei=function(e,t){var n,r,i=t.gc(),a,o,s,c,l,u,d,f;if(i!=0){for(l=P(NC(this.a,4),129),u=l==null?0:l.length,f=u+i,r=Hw(this,f),d=u-e,d>0&&tN(l,e,r,e+i,d),c=t.Kc(),o=0;on)throw E(new lf(e,n));return new JFe(this,e)},Q.$b=function(){var e,t;++this.j,e=P(NC(this.a,4),129),t=e==null?0:e.length,iO(this,null),Xy(this,t,e)},Q.Hc=function(e){var t=P(NC(this.a,4),129),n,r,i,a;if(t!=null){if(e!=null){for(r=t,i=0,a=r.length;i=n)throw E(new lf(e,n));return t[e]},Q.dd=function(e){var t=P(NC(this.a,4),129),n,r;if(t!=null){if(e!=null){for(n=0,r=t.length;nn)throw E(new lf(e,n));return new qFe(this,e)},Q.Ti=function(e,t){var n=B0e(this),r,i=n==null?0:n.length;if(e>=i)throw E(new Mi(yU+e+bU+i));if(t>=i)throw E(new Mi(xU+t+bU+i));return r=n[t],e!=t&&(e0&&tN(e,0,t,0,n),t},Q.Qc=function(e){var t=P(NC(this.a,4),129),n,r=t==null?0:t.length;return r>0&&(e.lengthr&&Sh(e,r,null),e};var TVt;L(uU,`ArrayDelegatingEList`,2080),q(1051,37,VP,gUe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},Q.Qb=function(){Yk(this),this.a=P(NC(this.b.a,4),129)},L(uU,`ArrayDelegatingEList/EIterator`,1051),q(722,286,YP,lPe,qFe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},Q.$j=function(e){i3e(this,e),this.a=P(NC(this.b.a,4),129)},Q.Qb=function(){Yk(this),this.a=P(NC(this.b.a,4),129)},L(uU,`ArrayDelegatingEList/EListIterator`,722),q(1052,355,VP,_Ue),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},L(uU,`ArrayDelegatingEList/NonResolvingEIterator`,1052),q(723,398,YP,uPe,JFe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},L(uU,`ArrayDelegatingEList/NonResolvingEListIterator`,723),q(615,302,oI,wl),L(uU,`BasicEList/BasicIndexOutOfBoundsException`,615),q(710,66,SU,$c),Q.bd=function(e,t){throw E(new Br)},Q.Fc=function(e){throw E(new Br)},Q.cd=function(e,t){throw E(new Br)},Q.Gc=function(e){throw E(new Br)},Q.$b=function(){throw E(new Br)},Q._i=function(e){throw E(new Br)},Q.Kc=function(){return this.Ii()},Q.ed=function(){return this.Ji()},Q.fd=function(e){return this.Ki(e)},Q.Ti=function(e,t){throw E(new Br)},Q.Ui=function(e,t){throw E(new Br)},Q.gd=function(e){throw E(new Br)},Q.Mc=function(e){throw E(new Br)},Q.hd=function(e,t){throw E(new Br)},L(uU,`BasicEList/UnmodifiableEList`,710),q(721,1,{3:1,20:1,16:1,15:1,61:1,597:1}),Q.bd=function(e,t){qwe(this,e,P(t,44))},Q.Fc=function(e){return GEe(this,P(e,44))},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return P(H(this.c,e),136)},Q.Ti=function(e,t){return P(this.c.Ti(e,t),44)},Q.Ui=function(e,t){Jwe(this,e,P(t,44))},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return P(this.c.gd(e),44)},Q.hd=function(e,t){return BPe(this,e,P(t,44))},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.cd=function(e,t){return this.c.cd(e,t)},Q.Gc=function(e){return this.c.Gc(e)},Q.$b=function(){this.c.$b()},Q.Hc=function(e){return this.c.Hc(e)},Q.Ic=function(e){return $C(this.c,e)},Q._j=function(){var e,t,n;if(this.d==null){for(this.d=V(SVt,awt,66,2*this.f+1,0,1),n=this.e,this.f=0,t=this.c.Kc();t.e!=t.i.gc();)e=P(t.Yj(),136),JO(this,e);this.e=n}},Q.Fb=function(e){return GOe(this,e)},Q.Hb=function(){return qXe(this.c)},Q.dd=function(e){return this.c.dd(e)},Q.ak=function(){this.c=new Fhe(this)},Q.dc=function(){return this.f==0},Q.Kc=function(){return this.c.Kc()},Q.ed=function(){return this.c.ed()},Q.fd=function(e){return this.c.fd(e)},Q.bk=function(){return Jy(this)},Q.ck=function(e,t,n){return new dje(e,t,n)},Q.dk=function(){return new Rse},Q.Mc=function(e){return aJe(this,e)},Q.gc=function(){return this.f},Q.kd=function(e,t){return new $_(this.c,e,t)},Q.Pc=function(){return this.c.Pc()},Q.Qc=function(e){return this.c.Qc(e)},Q.Ib=function(){return HE(this.c)},Q.e=0,Q.f=0,L(uU,`BasicEMap`,721),q(1046,66,SU,Fhe),Q.Mi=function(e,t){Oge(this,P(t,136))},Q.Pi=function(e,t,n){var r;++(r=this,P(t,136),r).a.e},Q.Qi=function(e,t){kge(this,P(t,136))},Q.Ri=function(e,t,n){hEe(this,P(t,136),P(n,136))},Q.Oi=function(e,t){sXe(this.a)},L(uU,`BasicEMap/1`,1046),q(1047,66,SU,Rse),Q.aj=function(e){return V(EVt,owt,621,e,0,1)},L(uU,`BasicEMap/2`,1047),q(1048,GP,KP,Ihe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){return uD(this.a,e)},Q.Kc=function(){return this.a.f==0?(Nd(),_7.a):new qve(this.a)},Q.Mc=function(e){var t=this.a.f;return BD(this.a,e),this.a.f!=t},Q.gc=function(){return this.a.f},L(uU,`BasicEMap/3`,1048),q(1049,31,WP,Lhe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){return Nct(this.a,e)},Q.Kc=function(){return this.a.f==0?(Nd(),_7.a):new Jve(this.a)},Q.gc=function(){return this.a.f},L(uU,`BasicEMap/4`,1049),q(1050,GP,KP,Rhe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){var t,n,r,i,a,o,s,c,l;if(this.a.f>0&&j(e,44)&&(this.a._j(),c=P(e,44),s=c.ld(),i=s==null?0:US(s),a=MDe(this.a,i),t=this.a.d[a],t)){for(n=P(t.g,379),l=t.i,o=0;o`+this.c},Q.a=0;var EVt=L(uU,`BasicEMap/EntryImpl`,621);q(546,1,{},on),L(uU,`BasicEMap/View`,546);var _7;q(783,1,{}),Q.Fb=function(e){return lit((Vg(),QG),e)},Q.Hb=function(){return IZe((Vg(),QG))},Q.Ib=function(){return CA((Vg(),QG))},L(uU,`ECollections/BasicEmptyUnmodifiableEList`,783),q(1348,1,YP,zse),Q.Nb=function(e){Om(this,e)},Q.Rb=function(e){throw E(new Br)},Q.Ob=function(){return!1},Q.Sb=function(){return!1},Q.Pb=function(){throw E(new Hr)},Q.Tb=function(){return 0},Q.Ub=function(){throw E(new Hr)},Q.Vb=function(){return-1},Q.Qb=function(){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(uU,`ECollections/BasicEmptyUnmodifiableEList/1`,1348),q(1346,783,{20:1,16:1,15:1,61:1},c_e),Q.bd=function(e,t){Eye()},Q.Fc=function(e){return Dye()},Q.cd=function(e,t){return Oye()},Q.Gc=function(e){return kye()},Q.$b=function(){Aye()},Q.Hc=function(e){return!1},Q.Ic=function(e){return!1},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return xl((Vg(),e)),null},Q.dd=function(e){return-1},Q.dc=function(){return!0},Q.Kc=function(){return this.a},Q.ed=function(){return this.a},Q.fd=function(e){return this.a},Q.Ti=function(e,t){return jye()},Q.Ui=function(e,t){Mye()},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return Nye()},Q.Mc=function(e){return Pye()},Q.hd=function(e,t){return Fye()},Q.gc=function(){return 0},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.kd=function(e,t){return Vg(),new $_(QG,e,t)},Q.Pc=function(){return INe((Vg(),QG))},Q.Qc=function(e){return Vg(),ck(QG,e)},L(uU,`ECollections/EmptyUnmodifiableEList`,1346),q(1347,783,{20:1,16:1,15:1,61:1,597:1},l_e),Q.bd=function(e,t){Eye()},Q.Fc=function(e){return Dye()},Q.cd=function(e,t){return Oye()},Q.Gc=function(e){return kye()},Q.$b=function(){Aye()},Q.Hc=function(e){return!1},Q.Ic=function(e){return!1},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return xl((Vg(),e)),null},Q.dd=function(e){return-1},Q.dc=function(){return!0},Q.Kc=function(){return this.a},Q.ed=function(){return this.a},Q.fd=function(e){return this.a},Q.Ti=function(e,t){return jye()},Q.Ui=function(e,t){Mye()},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return Nye()},Q.Mc=function(e){return Pye()},Q.hd=function(e,t){return Fye()},Q.gc=function(){return 0},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.kd=function(e,t){return Vg(),new $_(QG,e,t)},Q.Pc=function(){return INe((Vg(),QG))},Q.Qc=function(e){return Vg(),ck(QG,e)},Q.bk=function(){return Vg(),Vg(),$G},L(uU,`ECollections/EmptyUnmodifiableEMap`,1347);var DVt=gp(uU,`Enumerator`),v7;q(288,1,{288:1},yM),Q.Fb=function(e){var t;return this===e?!0:j(e,288)?(t=P(e,288),this.f==t.f&&rNe(this.i,t.i)&&Fp(this.a,this.f&256?t.f&256?t.a:null:t.f&256?null:t.a)&&Fp(this.d,t.d)&&Fp(this.g,t.g)&&Fp(this.e,t.e)&&U2e(this,t)):!1},Q.Hb=function(){return this.f},Q.Ib=function(){return qut(this)},Q.f=0;var OVt=0,kVt=0,AVt=0,jVt=0,MVt=0,NVt=0,PVt=0,FVt=0,IVt=0,LVt,y7=0,b7=0,RVt=0,zVt=0,x7,BVt;L(uU,`URI`,288),q(1121,45,CI,u_e),Q.zc=function(e,t){return P(H_(this,kd(e),P(t,288)),288)},L(uU,`URI/URICache`,1121),q(506,66,SU,Nse,Hp),Q.Si=function(){return!0},L(uU,`UniqueEList`,506),q(590,63,SF,Nb),L(uU,`WrappedException`,590);var S7=gp(zH,lwt),C7=gp(zH,uwt),w7=gp(zH,dwt),T7=gp(zH,fwt),E7=gp(zH,pwt),D7=gp(zH,`EClass`),O7=gp(zH,`EDataType`),VVt;q(1233,45,CI,d_e),Q.xc=function(e){return rl(e)?v_(this,e):nl(Kp(this.f,e))},L(zH,`EDataType/Internal/ConversionDelegate/Factory/Registry/Impl`,1233);var k7=gp(zH,`EEnum`),A7=gp(zH,mwt),j7=gp(zH,hwt),M7=gp(zH,gwt),N7,P7=gp(zH,_wt),F7=gp(zH,vwt);q(1042,1,{},Mse),Q.Ib=function(){return`NIL`},L(zH,`EStructuralFeature/Internal/DynamicValueHolder/1`,1042);var HVt;q(1041,45,CI,f_e),Q.xc=function(e){return rl(e)?v_(this,e):nl(Kp(this.f,e))},L(zH,`EStructuralFeature/Internal/SettingDelegate/Factory/Registry/Impl`,1041);var I7=gp(zH,ywt),L7=gp(zH,`EValidator/PatternMatcher`),UVt,R7,z7,B7,V7,H7,WVt,GVt,KVt,U7,W7,G7,K7,q7,qVt,JVt,J7,Y7,YVt,X7,Z7,Q7,$7,XVt,ZVt,e9,t9=gp(IU,`FeatureMap/Entry`);q(545,1,{76:1},Zc),Q.Lk=function(){return this.a},Q.md=function(){return this.b},L(KH,`BasicEObjectImpl/1`,545),q(1040,1,LU,JSe),Q.Fk=function(e){return wy(this.a,this.b,e)},Q.Qj=function(){return iRe(this.a,this.b)},Q.Wb=function(e){rRe(this.a,this.b,e)},Q.Gk=function(){yFe(this.a,this.b)},L(KH,`BasicEObjectImpl/4`,1040),q(2081,1,{114:1}),Q.Mk=function(e){this.e=e==0?QVt:V(WW,FP,1,e,5,1)},Q.li=function(e){return this.e[e]},Q.mi=function(e,t){this.e[e]=t},Q.ni=function(e){this.e[e]=null},Q.Nk=function(){return this.c},Q.Ok=function(){throw E(new Br)},Q.Pk=function(){throw E(new Br)},Q.Qk=function(){return this.d},Q.Rk=function(){return this.e!=null},Q.Sk=function(e){this.c=e},Q.Tk=function(e){throw E(new Br)},Q.Uk=function(e){throw E(new Br)},Q.Vk=function(e){this.d=e};var QVt;L(KH,`BasicEObjectImpl/EPropertiesHolderBaseImpl`,2081),q(192,2081,{114:1},fn),Q.Ok=function(){return this.a},Q.Pk=function(){return this.b},Q.Tk=function(e){this.a=e},Q.Uk=function(e){this.b=e},L(KH,`BasicEObjectImpl/EPropertiesHolderImpl`,192),q(516,99,nCt,sn),Q.uh=function(){return this.f},Q.zh=function(){return this.k},Q.Bh=function(e,t){this.g=e,this.i=t},Q.Dh=function(){return this.j&2?this.$h().Nk():this.ii()},Q.Fh=function(){return this.i},Q.wh=function(){return!!(this.j&1)},Q.Ph=function(){return this.g},Q.Vh=function(){return!!(this.j&4)},Q.$h=function(){return!this.k&&(this.k=new fn),this.k},Q.ci=function(e){this.$h().Sk(e),e?this.j|=2:this.j&=-3},Q.ei=function(e){this.$h().Uk(e),e?this.j|=4:this.j&=-5},Q.ii=function(){return(vh(),z7).S},Q.i=0,Q.j=1,L(KH,`EObjectImpl`,516),q(798,516,{110:1,94:1,93:1,58:1,114:1,54:1,99:1},eMe),Q.li=function(e){return this.e[e]},Q.mi=function(e,t){this.e[e]=t},Q.ni=function(e){this.e[e]=null},Q.Dh=function(){return this.d},Q.Ih=function(e){return eD(this.d,e)},Q.Kh=function(){return this.d},Q.Oh=function(){return this.e!=null},Q.$h=function(){return!this.k&&(this.k=new Bse),this.k},Q.ci=function(e){this.d=e},Q.hi=function(){var e;return this.e??=(e=bh(this.d),e==0?$Vt:V(WW,FP,1,e,5,1)),this},Q.ji=function(){return 0};var $Vt;L(KH,`DynamicEObjectImpl`,798),q(1522,798,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1},OMe),Q.Fb=function(e){return this===e},Q.Hb=function(){return td(this)},Q.ci=function(e){this.d=e,this.b=Qj(e,`key`),this.c=Qj(e,tU)},Q.Bi=function(){var e;return this.a==-1&&(e=Kb(this,this.b),this.a=e==null?0:US(e)),this.a},Q.ld=function(){return Kb(this,this.b)},Q.md=function(){return Kb(this,this.c)},Q.Ci=function(e){this.a=e},Q.Di=function(e){rRe(this,this.b,e)},Q.nd=function(e){var t=Kb(this,this.c);return rRe(this,this.c,e),t},Q.a=0,L(KH,`DynamicEObjectImpl/BasicEMapEntry`,1522),q(1523,1,{114:1},Bse),Q.Mk=function(e){throw E(new Br)},Q.li=function(e){throw E(new Br)},Q.mi=function(e,t){throw E(new Br)},Q.ni=function(e){throw E(new Br)},Q.Nk=function(){throw E(new Br)},Q.Ok=function(){return this.a},Q.Pk=function(){return this.b},Q.Qk=function(){return this.c},Q.Rk=function(){throw E(new Br)},Q.Sk=function(e){throw E(new Br)},Q.Tk=function(e){this.a=e},Q.Uk=function(e){this.b=e},Q.Vk=function(e){this.c=e},L(KH,`DynamicEObjectImpl/DynamicEPropertiesHolderImpl`,1523),q(519,158,{110:1,94:1,93:1,598:1,155:1,58:1,114:1,54:1,99:1,519:1,158:1,119:1,120:1},Vse),Q.Ah=function(e){return T6e(this,e)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.d;case 2:return n?(!this.b&&(this.b=new Td((CP(),$7),o9,this)),this.b):(!this.b&&(this.b=new Td((CP(),$7),o9,this)),Jy(this.b));case 3:return hRe(this);case 4:return!this.a&&(this.a=new ju(L5,this,4)),this.a;case 5:return!this.c&&(this.c=new Pu(L5,this,5)),this.c}return xb(this,e-bh((CP(),B7)),_x((r=P(NC(this,16),29),r||B7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 3:return this.Cb&&(n=(i=this.Db>>16,i>=0?T6e(this,n):this.Cb.Th(this,-1-i,null,n))),MNe(this,P(e,155),n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),B7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),B7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 2:return!this.b&&(this.b=new Td((CP(),$7),o9,this)),gf(this.b,e,n);case 3:return MNe(this,null,n);case 4:return!this.a&&(this.a=new ju(L5,this,4)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),B7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),B7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.d!=null;case 2:return!!this.b&&this.b.f!=0;case 3:return!!hRe(this);case 4:return!!this.a&&this.a.i!=0;case 5:return!!this.c&&this.c.i!=0}return Hv(this,e-bh((CP(),B7)),_x((t=P(NC(this,16),29),t||B7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:PMe(this,kd(t));return;case 2:!this.b&&(this.b=new Td((CP(),$7),o9,this)),bC(this.b,t);return;case 3:Aot(this,P(t,155));return;case 4:!this.a&&(this.a=new ju(L5,this,4)),RN(this.a),!this.a&&(this.a=new ju(L5,this,4)),th(this.a,P(t,16));return;case 5:!this.c&&(this.c=new Pu(L5,this,5)),RN(this.c),!this.c&&(this.c=new Pu(L5,this,5)),th(this.c,P(t,16));return}LE(this,e-bh((CP(),B7)),_x((n=P(NC(this,16),29),n||B7),e),t)},Q.ii=function(){return CP(),B7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:FJe(this,null);return;case 2:!this.b&&(this.b=new Td((CP(),$7),o9,this)),this.b.c.$b();return;case 3:Aot(this,null);return;case 4:!this.a&&(this.a=new ju(L5,this,4)),RN(this.a);return;case 5:!this.c&&(this.c=new Pu(L5,this,5)),RN(this.c);return}PT(this,e-bh((CP(),B7)),_x((t=P(NC(this,16),29),t||B7),e))},Q.Ib=function(){return L$e(this)},Q.d=null,L(KH,`EAnnotationImpl`,519),q(141,721,bwt,lb),Q.Gi=function(e,t){awe(this,e,P(t,44))},Q.Wk=function(e,t){return KOe(this,P(e,44),t)},Q.$i=function(e){return P(P(this.c,71).$i(e),136)},Q.Ii=function(){return P(this.c,71).Ii()},Q.Ji=function(){return P(this.c,71).Ji()},Q.Ki=function(e){return P(this.c,71).Ki(e)},Q.Xk=function(e,t){return gf(this,e,t)},Q.Fk=function(e){return P(this.c,79).Fk(e)},Q.ak=function(){},Q.Qj=function(){return P(this.c,79).Qj()},Q.ck=function(e,t,n){var r=P(Mx(this.b).wi().si(this.b),136);return r.Ci(e),r.Di(t),r.nd(n),r},Q.dk=function(){return new Yhe(this)},Q.Wb=function(e){bC(this,e)},Q.Gk=function(){P(this.c,79).Gk()},L(IU,`EcoreEMap`,141),q(165,141,bwt,Td),Q._j=function(){var e,t,n,r,i,a;if(this.d==null){for(a=V(SVt,awt,66,2*this.f+1,0,1),n=this.c.Kc();n.e!=n.i.gc();)t=P(n.Yj(),136),r=t.Bi(),i=(r&AP)%a.length,e=a[i],!e&&(e=a[i]=new Yhe(this)),e.Fc(t);this.d=a}},L(KH,`EAnnotationImpl/1`,165),q(292,448,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,481:1,54:1,99:1,158:1,292:1,119:1,120:1}),Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!this.Jk();case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return this.Jk();case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0)}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:this.ui(kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:this.Zk(P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),ZVt},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:this.ui(null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.Zk(1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){Ik(this),this.Bb|=1},Q.Hk=function(){return Ik(this)},Q.Ik=function(){return this.t},Q.Jk=function(){var e;return e=this.t,e>1||e==-1},Q.Si=function(){return!!(this.Bb&512)},Q.Yk=function(e,t){return kT(this,e,t)},Q.Zk=function(e){Qx(this,e)},Q.Ib=function(){return Srt(this)},Q.s=0,Q.t=1,L(KH,`ETypedElementImpl`,292),q(462,292,{110:1,94:1,93:1,155:1,197:1,58:1,179:1,69:1,114:1,481:1,54:1,99:1,158:1,462:1,292:1,119:1,120:1,692:1}),Q.Ah=function(e){return X3e(this,e)},Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!this.Jk();case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this)}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 17:return this.Cb&&(n=(i=this.Db>>16,i>=0?X3e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,17,n)}return a=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),a.wk().zk(this,WD(this),t-bh(this.ii()),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 17:return qM(this,null,17,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return this.Jk();case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this)}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:this.Zk(P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),XVt},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.Zk(1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.pk=function(){return this.f},Q.ik=function(){return Uj(this)},Q.qk=function(){return L_(this)},Q.uk=function(){return null},Q.$k=function(){return this.k},Q.Lj=function(){return this.n},Q.vk=function(){return $k(this)},Q.wk=function(){var e,t,n,r,i,a,o,s,c;return this.p||(n=L_(this),(n.i??aN(n),n.i).length,r=this.uk(),r&&bh(L_(r)),i=Ik(this),o=i.kk(),e=o?o.i&1?o==J9?bG:o==q9?DG:o==Q9?EG:o==Z9?TG:o==Y9?kG:o==$9?PG:o==X9?xG:CG:o:null,t=Uj(this),s=i.ik(),E1e(this),(this.Bb&ZP)!=0&&((a=C8e((UA(),l9),n))&&a!=this||(a=mv(Rb(l9,this))))?this.p=new XSe(this,a):this.Jk()?this.al()?this.p=r?(this.Bb&RU)==0?e?this.bl()?new Og(49,e,this,r):new Og(7,e,this,r):this.bl()?new ty(48,this,r):new ty(6,this,r):e?this.bl()?new Og(47,e,this,r):new Og(5,e,this,r):this.bl()?new ty(46,this,r):new ty(4,this,r):(this.Bb&RU)==0?e?e==YW?new Wf(41,yVt,this):this.bl()?new Wf(45,e,this):new Wf(3,e,this):this.bl()?new a_(44,this):new a_(2,this):e?e==YW?new Wf(50,yVt,this):this.bl()?new Wf(43,e,this):new Wf(1,e,this):this.bl()?new a_(42,this):new a_(0,this):j(i,156)?this.p=e==t9?new a_(40,this):this.Bb&512?(this.Bb&RU)==0?e?new Wf(11,e,this):new a_(10,this):e?new Wf(9,e,this):new a_(8,this):(this.Bb&RU)==0?e?new Wf(15,e,this):new a_(14,this):e?new Wf(13,e,this):new a_(12,this):r?(c=r.t,this.p=c>1||c==-1?this.bl()?(this.Bb&RU)==0?e?new Og(27,e,this,r):new ty(26,this,r):e?new Og(25,e,this,r):new ty(24,this,r):(this.Bb&RU)==0?e?new Og(31,e,this,r):new ty(30,this,r):e?new Og(29,e,this,r):new ty(28,this,r):this.bl()?(this.Bb&RU)==0?e?new Og(35,e,this,r):new ty(34,this,r):e?new Og(33,e,this,r):new ty(32,this,r):(this.Bb&RU)==0?e?new Og(39,e,this,r):new ty(38,this,r):e?new Og(37,e,this,r):new ty(36,this,r)):this.p=this.bl()?(this.Bb&RU)==0?e?new Wf(19,e,this):new a_(18,this):e?new Wf(17,e,this):new a_(16,this):(this.Bb&RU)==0?e?new Wf(23,e,this):new a_(22,this):e?new Wf(21,e,this):new a_(20,this):this.p=this._k()?this.bl()?new fje(P(i,29),this,r):new ILe(P(i,29),this,r):j(i,156)?e==t9?new a_(40,this):(this.Bb&RU)==0?e?new kNe(t,s,this,(mD(),o==q9?lHt:o==J9?iHt:o==Y9?uHt:o==Q9?cHt:o==Z9?sHt:o==$9?dHt:o==X9?aHt:o==K9?oHt:c9)):new gIe(P(i,156),t,s,this):e?new ANe(t,s,this,(mD(),o==q9?lHt:o==J9?iHt:o==Y9?uHt:o==Q9?cHt:o==Z9?sHt:o==$9?dHt:o==X9?aHt:o==K9?oHt:c9)):new _Ie(P(i,156),t,s,this):this.al()?r?(this.Bb&RU)==0?this.bl()?new hje(P(i,29),this,r):new Gf(P(i,29),this,r):this.bl()?new _je(P(i,29),this,r):new gje(P(i,29),this,r):(this.Bb&RU)==0?this.bl()?new JEe(P(i,29),this):new Ed(P(i,29),this):this.bl()?new ZEe(P(i,29),this):new YEe(P(i,29),this):this.bl()?r?(this.Bb&RU)==0?new pje(P(i,29),this,r):new vje(P(i,29),this,r):(this.Bb&RU)==0?new XEe(P(i,29),this):new QEe(P(i,29),this):r?(this.Bb&RU)==0?new mje(P(i,29),this,r):new yje(P(i,29),this,r):(this.Bb&RU)==0?new Bp(P(i,29),this):new $Ee(P(i,29),this)),this.p},Q.rk=function(){return(this.Bb&pF)!=0},Q._k=function(){return!1},Q.al=function(){return!1},Q.sk=function(){return(this.Bb&ZP)!=0},Q.xk=function(){return ex(this)},Q.bl=function(){return!1},Q.tk=function(){return(this.Bb&RU)!=0},Q.cl=function(e){this.k=e},Q.ui=function(e){X_(this,e)},Q.Ib=function(){return SM(this)},Q.e=!1,Q.n=0,L(KH,`EStructuralFeatureImpl`,462),q(331,462,{110:1,94:1,93:1,35:1,155:1,197:1,58:1,179:1,69:1,114:1,481:1,54:1,99:1,331:1,158:1,462:1,292:1,119:1,120:1,692:1},oi),Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!Dnt(this);case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this);case 18:return rd(),(this.Bb&GH)!=0;case 19:return t?QC(this):tWe(this)}return xb(this,e-bh((CP(),V7)),_x((r=P(NC(this,16),29),r||V7),e),t,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return Dnt(this);case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this);case 18:return(this.Bb&GH)!=0;case 19:return!!tWe(this)}return Hv(this,e-bh((CP(),V7)),_x((t=P(NC(this,16),29),t||V7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Zve(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return;case 18:mE(this,ki(Od(t)));return}LE(this,e-bh((CP(),V7)),_x((n=P(NC(this,16),29),n||V7),e),t)},Q.ii=function(){return CP(),V7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.b=0,Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return;case 18:mE(this,!1);return}PT(this,e-bh((CP(),V7)),_x((t=P(NC(this,16),29),t||V7),e))},Q.pi=function(){QC(this),lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.Jk=function(){return Dnt(this)},Q.Yk=function(e,t){return this.b=0,this.a=null,kT(this,e,t)},Q.Zk=function(e){Zve(this,e)},Q.Ib=function(){var e;return this.Db&64?SM(this):(e=new Wu(SM(this)),e.a+=` (iD: `,Ga(e,(this.Bb&GH)!=0),e.a+=`)`,e.a)},Q.b=0,L(KH,`EAttributeImpl`,331),q(364,448,{110:1,94:1,93:1,142:1,155:1,197:1,58:1,114:1,54:1,99:1,364:1,158:1,119:1,120:1,691:1}),Q.dl=function(e){return e.Dh()==this},Q.Ah=function(e){return bk(this,e)},Q.Bh=function(e,t){this.w=null,this.Db=t<<16|this.Db&255,this.Cb=e},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.D==null?this.B:this.D;case 3:return _k(this);case 4:return this.ik();case 5:return this.F;case 6:return t?Mx(this):F_(this);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),this.A}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n)}return a=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),a.wk().zk(this,WD(this),t-bh(this.ii()),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return this.ik()!=null;case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),WVt},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.hk=function(){var e;return this.G==-1&&(this.G=(e=Mx(this),e?NO(e.vi(),this):-1)),this.G},Q.ik=function(){return null},Q.jk=function(){return Mx(this)},Q.el=function(){return this.v},Q.kk=function(){return _k(this)},Q.lk=function(){return this.D==null?this.B:this.D},Q.mk=function(){return this.F},Q.fk=function(e){return QM(this,e)},Q.fl=function(e){this.v=e},Q.gl=function(e){fYe(this,e)},Q.hl=function(e){this.C=e},Q.ui=function(e){Y_(this,e)},Q.Ib=function(){return sD(this)},Q.C=null,Q.D=null,Q.G=-1,L(KH,`EClassifierImpl`,364),q(90,364,{110:1,94:1,93:1,29:1,142:1,155:1,197:1,58:1,114:1,54:1,99:1,90:1,364:1,158:1,482:1,119:1,120:1,691:1},Que),Q.dl=function(e){return pOe(this,e.Dh())},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.D==null?this.B:this.D;case 3:return _k(this);case 4:return null;case 5:return this.F;case 6:return t?Mx(this):F_(this);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),this.A;case 8:return rd(),!!(this.Bb&256);case 9:return rd(),!!(this.Bb&512);case 10:return l_(this);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),this.q;case 12:return bN(this);case 13:return gN(this);case 14:return gN(this),this.r;case 15:return bN(this),this.k;case 16:return Qet(this);case 17:return fN(this);case 18:return aN(this);case 19:return zj(this);case 20:return bN(this),this.o;case 21:return!this.s&&(this.s=new F(w7,this,21,17)),this.s;case 22:return Jv(this);case 23:return _M(this)}return xb(this,e-bh((CP(),H7)),_x((r=P(NC(this,16),29),r||H7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),vD(this.q,e,n);case 21:return!this.s&&(this.s=new F(w7,this,21,17)),vD(this.s,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),H7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),H7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),AO(this.q,e,n);case 21:return!this.s&&(this.s=new F(w7,this,21,17)),AO(this.s,e,n);case 22:return AO(Jv(this),e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),H7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),H7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return!1;case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0;case 8:return!!(this.Bb&256);case 9:return!!(this.Bb&512);case 10:return!!this.u&&Jv(this.u.a).i!=0&&!(this.n&&QO(this.n));case 11:return!!this.q&&this.q.i!=0;case 12:return bN(this).i!=0;case 13:return gN(this).i!=0;case 14:return gN(this),this.r.i!=0;case 15:return bN(this),this.k.i!=0;case 16:return Qet(this).i!=0;case 17:return fN(this).i!=0;case 18:return aN(this).i!=0;case 19:return zj(this).i!=0;case 20:return bN(this),!!this.o;case 21:return!!this.s&&this.s.i!=0;case 22:return!!this.n&&QO(this.n);case 23:return _M(this).i!=0}return Hv(this,e-bh((CP(),H7)),_x((t=P(NC(this,16),29),t||H7),e))},Q.Zh=function(e){return(this.i==null||this.q&&this.q.i!=0?null:Qj(this,e))||rP(this,e)},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return;case 8:IT(this,ki(Od(t)));return;case 9:zT(this,ki(Od(t)));return;case 10:zN(l_(this)),th(l_(this),P(t,16));return;case 11:!this.q&&(this.q=new F(M7,this,11,10)),RN(this.q),!this.q&&(this.q=new F(M7,this,11,10)),th(this.q,P(t,16));return;case 21:!this.s&&(this.s=new F(w7,this,21,17)),RN(this.s),!this.s&&(this.s=new F(w7,this,21,17)),th(this.s,P(t,16));return;case 22:RN(Jv(this)),th(Jv(this),P(t,16));return}LE(this,e-bh((CP(),H7)),_x((n=P(NC(this,16),29),n||H7),e),t)},Q.ii=function(){return CP(),H7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return;case 8:IT(this,!1);return;case 9:zT(this,!1);return;case 10:this.u&&zN(this.u);return;case 11:!this.q&&(this.q=new F(M7,this,11,10)),RN(this.q);return;case 21:!this.s&&(this.s=new F(w7,this,21,17)),RN(this.s);return;case 22:this.n&&RN(this.n);return}PT(this,e-bh((CP(),H7)),_x((t=P(NC(this,16),29),t||H7),e))},Q.pi=function(){var e,t;if(bN(this),gN(this),Qet(this),fN(this),aN(this),zj(this),_M(this),Ey(Eje(_y(this))),this.s)for(e=0,t=this.s.i;e=0;--t)H(this,t);return oD(this,e)},Q.Gk=function(){RN(this)},Q.Zi=function(e,t){return Hqe(this,e,t)},L(IU,`EcoreEList`,632),q(505,632,JU,rp),Q.Li=function(){return!1},Q.Lj=function(){return this.c},Q.Mj=function(){return!1},Q.ol=function(){return!0},Q.Si=function(){return!0},Q.Wi=function(e,t){return t},Q.Yi=function(){return!1},Q.c=0,L(IU,`EObjectEList`,505),q(83,505,JU,ju),Q.Mj=function(){return!0},Q.ml=function(){return!1},Q.al=function(){return!0},L(IU,`EObjectContainmentEList`,83),q(555,83,JU,Mu),Q.Ni=function(){this.b=!0},Q.Qj=function(){return this.b},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.b,this.b=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.b=!1},Q.b=!1,L(IU,`EObjectContainmentEList/Unsettable`,555),q(1161,555,JU,DNe),Q.Ti=function(e,t){var n,r;return n=P(QT(this,e,t),89),Gl(this.e)&&Kr(this,new db(this.a,7,(CP(),GVt),G(t),(r=n.c,j(r,90)?P(r,29):J7),e)),n},Q.Uj=function(e,t){return C0e(this,P(e,89),t)},Q.Vj=function(e,t){return S0e(this,P(e,89),t)},Q.Wj=function(e,t,n){return L8e(this,P(e,89),P(t,89),n)},Q.Ij=function(e,t,n,r,i){switch(e){case 3:return V_(this,e,t,n,r,this.i>1);case 5:return V_(this,e,t,n,r,this.i-P(n,15).gc()>0);default:return new Hb(this.e,e,this.c,t,n,r,!0)}},Q.Tj=function(){return!0},Q.Qj=function(){return QO(this)},Q.Gk=function(){RN(this)},L(KH,`EClassImpl/1`,1161),q(1175,1174,nwt),Q.dj=function(e){var t,n=e.gj(),r,i,a,o,s;if(n!=8){if(r=N2e(e),r==0)switch(n){case 1:case 9:s=e.kj(),s!=null&&(t=_y(P(s,482)),!t.c&&(t.c=new ln),nx(t.c,e.jj())),o=e.ij(),o!=null&&(i=P(o,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29))));break;case 3:o=e.ij(),o!=null&&(i=P(o,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29))));break;case 5:if(o=e.ij(),o!=null)for(a=P(o,16).Kc();a.Ob();)i=P(a.Pb(),482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29)));break;case 4:s=e.kj(),s!=null&&(i=P(s,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),nx(t.c,e.jj())));break;case 6:if(s=e.kj(),s!=null)for(a=P(s,16).Kc();a.Ob();)i=P(a.Pb(),482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),nx(t.c,e.jj()))}this.ql(r)}},Q.ql=function(e){Zct(this,e)},Q.b=63,L(KH,`ESuperAdapter`,1175),q(1176,1175,nwt,Bhe),Q.ql=function(e){$A(this,e)},L(KH,`EClassImpl/10`,1176),q(1165,710,JU),Q.Ei=function(e,t){return dA(this,e,t)},Q.Fi=function(e){return X4e(this,e)},Q.Gi=function(e,t){jT(this,e,t)},Q.Hi=function(e){Ty(this,e)},Q.$i=function(e){return SGe(this,e)},Q.Xi=function(e,t){return tx(this,e,t)},Q.Wk=function(e,t){throw E(new Br)},Q.Ii=function(){return new ld(this)},Q.Ji=function(){return new ud(this)},Q.Ki=function(e){return mS(this,e)},Q.Xk=function(e,t){throw E(new Br)},Q.Fk=function(e){return this},Q.Qj=function(){return this.i!=0},Q.Wb=function(e){throw E(new Br)},Q.Gk=function(){throw E(new Br)},L(IU,`EcoreEList/UnmodifiableEList`,1165),q(328,1165,JU,El),Q.Yi=function(){return!1},L(IU,`EcoreEList/UnmodifiableEList/FastCompare`,328),q(1168,328,JU,bZe),Q.dd=function(e){var t,n,r;if(j(e,179)&&(t=P(e,179),n=t.Lj(),n!=-1)){for(r=this.i;n4){if(this.fk(e)){if(this.al()){if(r=P(e,54),n=r.Eh(),s=n==this.b&&(this.ml()?r.yh(r.Fh(),P(_x(d_(this.b),this.Lj()).Hk(),29).kk())==qO(P(_x(d_(this.b),this.Lj()),19)).n:-1-r.Fh()==this.Lj()),this.nl()&&!s&&!n&&r.Jh()){for(i=0;i1||r==-1)):!1},Q.ml=function(){var e,t=_x(d_(this.b),this.Lj()),n;return j(t,102)?(e=P(t,19),n=qO(e),!!n):!1},Q.nl=function(){var e,t=_x(d_(this.b),this.Lj());return j(t,102)?(e=P(t,19),(e.Bb&pI)!=0):!1},Q.dd=function(e){var t,n,r=this.zj(e),i;if(r>=0)return r;if(this.ol()){for(n=0,i=this.Ej();n=0;--e)GN(this,e,this.xj(e));return this.Fj()},Q.Qc=function(e){var t;if(this.nl())for(t=this.Ej()-1;t>=0;--t)GN(this,t,this.xj(t));return this.Gj(e)},Q.Gk=function(){zN(this)},Q.Zi=function(e,t){return CGe(this,e,t)},L(IU,`DelegatingEcoreEList`,756),q(1171,756,Ewt,FDe),Q.qj=function(e,t){BEe(this,e,P(t,29))},Q.rj=function(e){twe(this,P(e,29))},Q.xj=function(e){var t,n;return t=P(H(Jv(this.a),e),89),n=t.c,j(n,90)?P(n,29):(CP(),J7)},Q.Cj=function(e){var t,n;return t=P(lM(Jv(this.a),e),89),n=t.c,j(n,90)?P(n,29):(CP(),J7)},Q.Dj=function(e,t){return Q4e(this,e,P(t,29))},Q.Li=function(){return!1},Q.Ij=function(e,t,n,r,i){return null},Q.sj=function(){return new Uhe(this)},Q.tj=function(){RN(Jv(this.a))},Q.uj=function(e){return H$e(this,e)},Q.vj=function(e){var t,n;for(n=e.Kc();n.Ob();)if(t=n.Pb(),!H$e(this,t))return!1;return!0},Q.wj=function(e){var t,n,r;if(j(e,15)&&(r=P(e,15),r.gc()==Jv(this.a).i)){for(t=r.Kc(),n=new Lu(this);t.Ob();)if(A(t.Pb())!==A(gO(n)))return!1;return!0}return!1},Q.yj=function(){var e,t,n=1,r,i;for(t=new Lu(Jv(this.a));t.e!=t.i.gc();)e=P(gO(t),89),r=(i=e.c,j(i,90)?P(i,29):(CP(),J7)),n=31*n+(r?td(r):0);return n},Q.zj=function(e){var t,n,r=0,i;for(n=new Lu(Jv(this.a));n.e!=n.i.gc();){if(t=P(gO(n),89),A(e)===A((i=t.c,j(i,90)?P(i,29):(CP(),J7))))return r;++r}return-1},Q.Aj=function(){return Jv(this.a).i==0},Q.Bj=function(){return null},Q.Ej=function(){return Jv(this.a).i},Q.Fj=function(){var e,t,n,r,i,a=Jv(this.a).i;for(i=V(WW,FP,1,a,5,1),n=0,t=new Lu(Jv(this.a));t.e!=t.i.gc();)e=P(gO(t),89),i[n++]=(r=e.c,j(r,90)?P(r,29):(CP(),J7));return i},Q.Gj=function(e){var t,n,r,i,a,o,s=Jv(this.a).i;for(e.lengths&&Sh(e,s,null),r=0,n=new Lu(Jv(this.a));n.e!=n.i.gc();)t=P(gO(n),89),a=(o=t.c,j(o,90)?P(o,29):(CP(),J7)),Sh(e,r++,a);return e},Q.Hj=function(){var e,t,n,r,i=new $i;for(i.a+=`[`,e=Jv(this.a),t=0,r=Jv(this.a).i;t>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n);case 9:return!this.a&&(this.a=new F(A7,this,9,5)),vD(this.a,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),U7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),U7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n);case 9:return!this.a&&(this.a=new F(A7,this,9,5)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),U7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),U7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return!!AQe(this);case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0;case 8:return!(this.Bb&256);case 9:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),U7)),_x((t=P(NC(this,16),29),t||U7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return;case 8:LT(this,ki(Od(t)));return;case 9:!this.a&&(this.a=new F(A7,this,9,5)),RN(this.a),!this.a&&(this.a=new F(A7,this,9,5)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),U7)),_x((n=P(NC(this,16),29),n||U7),e),t)},Q.ii=function(){return CP(),U7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return;case 8:LT(this,!0);return;case 9:!this.a&&(this.a=new F(A7,this,9,5)),RN(this.a);return}PT(this,e-bh((CP(),U7)),_x((t=P(NC(this,16),29),t||U7),e))},Q.pi=function(){var e,t;if(this.a)for(e=0,t=this.a.i;e>16==5?P(this.Cb,685):null}return xb(this,e-bh((CP(),W7)),_x((r=P(NC(this,16),29),r||W7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 5:return this.Cb&&(n=(i=this.Db>>16,i>=0?C6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,5,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),W7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),W7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 5:return qM(this,null,5,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),W7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),W7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.d!=0;case 3:return!!this.b;case 4:return this.c!=null;case 5:return!!(this.Db>>16==5&&P(this.Cb,685))}return Hv(this,e-bh((CP(),W7)),_x((t=P(NC(this,16),29),t||W7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:$x(this,P(t,17).a);return;case 3:nrt(this,P(t,2039));return;case 4:SS(this,kd(t));return}LE(this,e-bh((CP(),W7)),_x((n=P(NC(this,16),29),n||W7),e),t)},Q.ii=function(){return CP(),W7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:$x(this,0);return;case 3:nrt(this,null);return;case 4:SS(this,null);return}PT(this,e-bh((CP(),W7)),_x((t=P(NC(this,16),29),t||W7),e))},Q.Ib=function(){var e;return e=this.c,e??this.zb},Q.b=null,Q.c=null,Q.d=0,L(KH,`EEnumLiteralImpl`,582);var tHt=gp(KH,`EFactoryImpl/InternalEDateTimeFormat`);q(499,1,{2114:1},br),L(KH,`EFactoryImpl/1ClientInternalEDateTimeFormat`,499),q(248,120,{110:1,94:1,93:1,89:1,58:1,114:1,54:1,99:1,248:1,119:1,120:1},kr),Q.Ch=function(e,t,n){var r;return n=qM(this,e,t,n),this.e&&j(e,179)&&(r=Rj(this,this.e),r!=this.c&&(n=JN(this,r,n))),n},Q.Lh=function(e,t,n){var r;switch(e){case 0:return this.f;case 1:return!this.d&&(this.d=new ju(j7,this,1)),this.d;case 2:return t?ZM(this):this.c;case 3:return this.b;case 4:return this.e;case 5:return t?nk(this):this.a}return xb(this,e-bh((CP(),K7)),_x((r=P(NC(this,16),29),r||K7),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return p$e(this,null,n);case 1:return!this.d&&(this.d=new ju(j7,this,1)),AO(this.d,e,n);case 3:return m$e(this,null,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),K7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),K7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.f;case 1:return!!this.d&&this.d.i!=0;case 2:return!!this.c;case 3:return!!this.b;case 4:return!!this.e;case 5:return!!this.a}return Hv(this,e-bh((CP(),K7)),_x((t=P(NC(this,16),29),t||K7),e))},Q.bi=function(e,t){var n;switch(e){case 0:d5e(this,P(t,89));return;case 1:!this.d&&(this.d=new ju(j7,this,1)),RN(this.d),!this.d&&(this.d=new ju(j7,this,1)),th(this.d,P(t,16));return;case 3:u5e(this,P(t,89));return;case 4:i9e(this,P(t,850));return;case 5:Nx(this,P(t,142));return}LE(this,e-bh((CP(),K7)),_x((n=P(NC(this,16),29),n||K7),e),t)},Q.ii=function(){return CP(),K7},Q.ki=function(e){var t;switch(e){case 0:d5e(this,null);return;case 1:!this.d&&(this.d=new ju(j7,this,1)),RN(this.d);return;case 3:u5e(this,null);return;case 4:i9e(this,null);return;case 5:Nx(this,null);return}PT(this,e-bh((CP(),K7)),_x((t=P(NC(this,16),29),t||K7),e))},Q.Ib=function(){var e=new Gu(Aj(this));return e.a+=` (expression: `,kN(this,e),e.a+=`)`,e.a};var nHt;L(KH,`EGenericTypeImpl`,248),q(2067,2062,QU),Q.Gi=function(e,t){ADe(this,e,t)},Q.Wk=function(e,t){return ADe(this,this.gc(),e),t},Q.$i=function(e){return SO(this.pj(),e)},Q.Ii=function(){return this.Ji()},Q.pj=function(){return new Jhe(this)},Q.Ji=function(){return this.Ki(0)},Q.Ki=function(e){return this.pj().fd(e)},Q.Xk=function(e,t){return QE(this,e,!0),t},Q.Ti=function(e,t){var n,r=Mk(this,t);return n=this.fd(e),n.Rb(r),r},Q.Ui=function(e,t){var n;QE(this,t,!0),n=this.fd(e),n.Rb(t)},L(IU,`AbstractSequentialInternalEList`,2067),q(496,2067,QU,ad),Q.$i=function(e){return SO(this.pj(),e)},Q.Ii=function(){return this.b==null?(Xo(),Xo(),a9):this.sl()},Q.pj=function(){return new mCe(this.a,this.b)},Q.Ji=function(){return this.b==null?(Xo(),Xo(),a9):this.sl()},Q.Ki=function(e){var t,n;if(this.b==null){if(e<0||e>1)throw E(new Mi(PU+e+`, size=0`));return Xo(),Xo(),a9}for(n=this.sl(),t=0;t0;)if(t=this.c[--this.d],(!this.e||t.pk()!=R5||t.Lj()!=0)&&(!this.vl()||this.b.Xh(t))){if(a=this.b.Nh(t,this.ul()),this.f=(Qo(),P(t,69).xk()),this.f||t.Jk()){if(this.ul()?(r=P(a,15),this.k=r):(r=P(a,71),this.k=this.j=r),j(this.k,59)?(this.o=this.k.gc(),this.n=this.o):this.p=this.j?this.j.Ki(this.k.gc()):this.k.fd(this.k.gc()),this.p?Pet(this,this.p):ytt(this))return i=this.p?this.p.Ub():this.j?this.j.$i(--this.n):this.k.Xb(--this.n),this.f?(e=P(i,76),e.Lk(),n=e.md(),this.i=n):(n=i,this.i=n),this.g=-3,!0}else if(a!=null)return this.k=null,this.p=null,n=a,this.i=n,this.g=-2,!0}return this.k=null,this.p=null,this.g=-1,!1}return i=this.p?this.p.Ub():this.j?this.j.$i(--this.n):this.k.Xb(--this.n),this.f?(e=P(i,76),e.Lk(),n=e.md(),this.i=n):(n=i,this.i=n),this.g=-3,!0}},Q.Pb=function(){return IC(this)},Q.Tb=function(){return this.a},Q.Ub=function(){var e;if(this.g<-1||this.Sb())return--this.a,this.g=0,e=this.i,this.Sb(),e;throw E(new Hr)},Q.Vb=function(){return this.a-1},Q.Qb=function(){throw E(new Br)},Q.ul=function(){return!1},Q.Wb=function(e){throw E(new Br)},Q.vl=function(){return!0},Q.a=0,Q.d=0,Q.f=!1,Q.g=0,Q.n=0,Q.o=0;var a9;L(IU,`EContentsEList/FeatureIteratorImpl`,287),q(711,287,$U,HEe),Q.ul=function(){return!0},L(IU,`EContentsEList/ResolvingFeatureIteratorImpl`,711),q(1178,711,$U,UEe),Q.vl=function(){return!1},L(KH,`ENamedElementImpl/1/1`,1178),q(1179,287,$U,WEe),Q.vl=function(){return!1},L(KH,`ENamedElementImpl/1/2`,1179),q(39,152,NU,Qv,$v,Sm,ub,Hb,vy,Gqe,nBe,Kqe,rBe,vUe,iBe,Yqe,aBe,yUe,oBe,qqe,sBe,Cm,db,Jg,Jqe,cBe,bUe,lBe),Q.Kj=function(){return eb(this)},Q.Rj=function(){var e=eb(this);return e?e.ik():null},Q.hj=function(e){return this.b==-1&&this.a&&(this.b=this.c.Hh(this.a.Lj(),this.a.pk())),this.c.yh(this.b,e)},Q.jj=function(){return this.c},Q.Sj=function(){var e=eb(this);return e?e.tk():!1},Q.b=-1,L(KH,`ENotificationImpl`,39),q(411,292,{110:1,94:1,93:1,155:1,197:1,58:1,62:1,114:1,481:1,54:1,99:1,158:1,411:1,292:1,119:1,120:1},si),Q.Ah=function(e){return I6e(this,e)},Q.Lh=function(e,t,n){var r,i,a;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),a=this.t,a>1||a==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return this.Db>>16==10?P(this.Cb,29):null;case 11:return!this.d&&(this.d=new Nu(I7,this,11)),this.d;case 12:return!this.c&&(this.c=new F(P7,this,12,10)),this.c;case 13:return!this.a&&(this.a=new Ud(this,this)),this.a;case 14:return Ib(this)}return xb(this,e-bh((CP(),Y7)),_x((r=P(NC(this,16),29),r||Y7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 10:return this.Cb&&(n=(i=this.Db>>16,i>=0?I6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,10,n);case 12:return!this.c&&(this.c=new F(P7,this,12,10)),vD(this.c,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),Y7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),Y7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 10:return qM(this,null,10,n);case 11:return!this.d&&(this.d=new Nu(I7,this,11)),AO(this.d,e,n);case 12:return!this.c&&(this.c=new F(P7,this,12,10)),AO(this.c,e,n);case 14:return AO(Ib(this),e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),Y7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),Y7)),e,n)},Q.Wh=function(e){var t,n,r;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return r=this.t,r>1||r==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return!!(this.Db>>16==10&&P(this.Cb,29));case 11:return!!this.d&&this.d.i!=0;case 12:return!!this.c&&this.c.i!=0;case 13:return!!this.a&&Ib(this.a.a).i!=0&&!(this.b&&$O(this.b));case 14:return!!this.b&&$O(this.b)}return Hv(this,e-bh((CP(),Y7)),_x((t=P(NC(this,16),29),t||Y7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Qx(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 11:!this.d&&(this.d=new Nu(I7,this,11)),RN(this.d),!this.d&&(this.d=new Nu(I7,this,11)),th(this.d,P(t,16));return;case 12:!this.c&&(this.c=new F(P7,this,12,10)),RN(this.c),!this.c&&(this.c=new F(P7,this,12,10)),th(this.c,P(t,16));return;case 13:!this.a&&(this.a=new Ud(this,this)),zN(this.a),!this.a&&(this.a=new Ud(this,this)),th(this.a,P(t,16));return;case 14:RN(Ib(this)),th(Ib(this),P(t,16));return}LE(this,e-bh((CP(),Y7)),_x((n=P(NC(this,16),29),n||Y7),e),t)},Q.ii=function(){return CP(),Y7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 11:!this.d&&(this.d=new Nu(I7,this,11)),RN(this.d);return;case 12:!this.c&&(this.c=new F(P7,this,12,10)),RN(this.c);return;case 13:this.a&&zN(this.a);return;case 14:this.b&&RN(this.b);return}PT(this,e-bh((CP(),Y7)),_x((t=P(NC(this,16),29),t||Y7),e))},Q.pi=function(){var e,t;if(this.c)for(e=0,t=this.c.i;es&&Sh(e,s,null),r=0,n=new Lu(Ib(this.a));n.e!=n.i.gc();)t=P(gO(n),89),a=(o=t.c,o||(CP(),q7)),Sh(e,r++,a);return e},Q.Hj=function(){var e,t,n,r,i=new $i;for(i.a+=`[`,e=Ib(this.a),t=0,r=Ib(this.a).i;t1);case 5:return V_(this,e,t,n,r,this.i-P(n,15).gc()>0);default:return new Hb(this.e,e,this.c,t,n,r,!0)}},Q.Tj=function(){return!0},Q.Qj=function(){return $O(this)},Q.Gk=function(){RN(this)},L(KH,`EOperationImpl/2`,1377),q(507,1,{2037:1,507:1},YSe),L(KH,`EPackageImpl/1`,507),q(14,83,JU,F),Q.il=function(){return this.d},Q.jl=function(){return this.b},Q.ml=function(){return!0},Q.b=0,L(IU,`EObjectContainmentWithInverseEList`,14),q(365,14,JU,nf),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentWithInverseEList/Resolving`,365),q(308,365,JU,Tm),Q.Ni=function(){this.a.tb=null},L(KH,`EPackageImpl/2`,308),q(1278,1,{},Jse),L(KH,`EPackageImpl/3`,1278),q(733,45,CI,ci),Q._b=function(e){return rl(e)?e_(this,e):!!Kp(this.f,e)},L(KH,`EPackageRegistryImpl`,733),q(518,292,{110:1,94:1,93:1,155:1,197:1,58:1,2116:1,114:1,481:1,54:1,99:1,158:1,518:1,292:1,119:1,120:1},li),Q.Ah=function(e){return L6e(this,e)},Q.Lh=function(e,t,n){var r,i,a;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),a=this.t,a>1||a==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return this.Db>>16==10?P(this.Cb,62):null}return xb(this,e-bh((CP(),Z7)),_x((r=P(NC(this,16),29),r||Z7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 10:return this.Cb&&(n=(i=this.Db>>16,i>=0?L6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,10,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),Z7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),Z7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 10:return qM(this,null,10,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),Z7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),Z7)),e,n)},Q.Wh=function(e){var t,n,r;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return r=this.t,r>1||r==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return!!(this.Db>>16==10&&P(this.Cb,62))}return Hv(this,e-bh((CP(),Z7)),_x((t=P(NC(this,16),29),t||Z7),e))},Q.ii=function(){return CP(),Z7},L(KH,`EParameterImpl`,518),q(102,462,{110:1,94:1,93:1,155:1,197:1,58:1,19:1,179:1,69:1,114:1,481:1,54:1,99:1,158:1,102:1,462:1,292:1,119:1,120:1,692:1},uDe),Q.Lh=function(e,t,n){var r,i,a,o;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),o=this.t,o>1||o==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this);case 18:return rd(),(this.Bb&GH)!=0;case 19:return rd(),a=qO(this),!!(a&&(a.Bb&GH)!=0);case 20:return rd(),(this.Bb&pI)!=0;case 21:return t?qO(this):this.b;case 22:return t?DZe(this):DUe(this);case 23:return!this.a&&(this.a=new Pu(T7,this,23)),this.a}return xb(this,e-bh((CP(),Q7)),_x((r=P(NC(this,16),29),r||Q7),e),t,n)},Q.Wh=function(e){var t,n,r,i;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return i=this.t,i>1||i==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this);case 18:return(this.Bb&GH)!=0;case 19:return r=qO(this),!!r&&(r.Bb&GH)!=0;case 20:return(this.Bb&pI)==0;case 21:return!!this.b;case 22:return!!DUe(this);case 23:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),Q7)),_x((t=P(NC(this,16),29),t||Q7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Qx(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return;case 18:PRe(this,ki(Od(t)));return;case 20:_E(this,ki(Od(t)));return;case 21:JJe(this,P(t,19));return;case 23:!this.a&&(this.a=new Pu(T7,this,23)),RN(this.a),!this.a&&(this.a=new Pu(T7,this,23)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),Q7)),_x((n=P(NC(this,16),29),n||Q7),e),t)},Q.ii=function(){return CP(),Q7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return;case 18:hE(this,!1),j(this.Cb,90)&&$A(_y(P(this.Cb,90)),2);return;case 20:_E(this,!0);return;case 21:JJe(this,null);return;case 23:!this.a&&(this.a=new Pu(T7,this,23)),RN(this.a);return}PT(this,e-bh((CP(),Q7)),_x((t=P(NC(this,16),29),t||Q7),e))},Q.pi=function(){DZe(this),lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.uk=function(){return qO(this)},Q._k=function(){var e;return e=qO(this),!!e&&(e.Bb&GH)!=0},Q.al=function(){return(this.Bb&GH)!=0},Q.bl=function(){return(this.Bb&pI)!=0},Q.Yk=function(e,t){return this.c=null,kT(this,e,t)},Q.Ib=function(){var e;return this.Db&64?SM(this):(e=new Wu(SM(this)),e.a+=` (containment: `,Ga(e,(this.Bb&GH)!=0),e.a+=`, resolveProxies: `,Ga(e,(this.Bb&pI)!=0),e.a+=`)`,e.a)},L(KH,`EReferenceImpl`,102),q(561,120,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1,561:1,119:1,120:1},Yse),Q.Fb=function(e){return this===e},Q.ld=function(){return this.b},Q.md=function(){return this.c},Q.Hb=function(){return td(this)},Q.Di=function(e){FMe(this,kd(e))},Q.nd=function(e){return Zje(this,kd(e))},Q.Lh=function(e,t,n){var r;switch(e){case 0:return this.b;case 1:return this.c}return xb(this,e-bh((CP(),$7)),_x((r=P(NC(this,16),29),r||$7),e),t,n)},Q.Wh=function(e){var t;switch(e){case 0:return this.b!=null;case 1:return this.c!=null}return Hv(this,e-bh((CP(),$7)),_x((t=P(NC(this,16),29),t||$7),e))},Q.bi=function(e,t){var n;switch(e){case 0:IMe(this,kd(t));return;case 1:PJe(this,kd(t));return}LE(this,e-bh((CP(),$7)),_x((n=P(NC(this,16),29),n||$7),e),t)},Q.ii=function(){return CP(),$7},Q.ki=function(e){var t;switch(e){case 0:NJe(this,null);return;case 1:PJe(this,null);return}PT(this,e-bh((CP(),$7)),_x((t=P(NC(this,16),29),t||$7),e))},Q.Bi=function(){var e;return this.a==-1&&(e=this.b,this.a=e==null?0:jw(e)),this.a},Q.Ci=function(e){this.a=e},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new Wu(Aj(this)),e.a+=` (key: `,pl(e,this.b),e.a+=`, value: `,pl(e,this.c),e.a+=`)`,e.a)},Q.a=-1,Q.b=null,Q.c=null;var o9=L(KH,`EStringToStringMapEntryImpl`,561),rHt=gp(IU,`FeatureMap/Entry/Internal`);q(576,1,eW),Q.xl=function(e){return this.yl(P(e,54))},Q.yl=function(e){return this.xl(e)},Q.Fb=function(e){var t,n;return this===e?!0:j(e,76)?(t=P(e,76),t.Lk()==this.c&&(n=this.md(),n==null?t.md()==null:NT(n,t.md()))):!1},Q.Lk=function(){return this.c},Q.Hb=function(){var e=this.md();return US(this.c)^(e==null?0:US(e))},Q.Ib=function(){var e=this.c,t=Mx(e.qk()).yi();return e.xe(),(t!=null&&t.length!=0?t+`:`+e.xe():e.xe())+`=`+this.md()},L(KH,`EStructuralFeatureImpl/BasicFeatureMapEntry`,576),q(791,576,eW,IDe),Q.yl=function(e){return new IDe(this.c,e)},Q.md=function(){return this.a},Q.zl=function(e,t,n){return NYe(this,e,this.a,t,n)},Q.Al=function(e,t,n){return PYe(this,e,this.a,t,n)},L(KH,`EStructuralFeatureImpl/ContainmentUpdatingFeatureMapEntry`,791),q(1350,1,{},XSe),Q.yk=function(e,t,n,r,i){return P(mb(e,this.b),220).Yl(this.a).Fk(r)},Q.zk=function(e,t,n,r,i){return P(mb(e,this.b),220).Pl(this.a,r,i)},Q.Ak=function(e,t,n,r,i){return P(mb(e,this.b),220).Ql(this.a,r,i)},Q.Bk=function(e,t,n){return P(mb(e,this.b),220).Yl(this.a).Qj()},Q.Ck=function(e,t,n,r){P(mb(e,this.b),220).Yl(this.a).Wb(r)},Q.Dk=function(e,t,n){return P(mb(e,this.b),220).Yl(this.a)},Q.Ek=function(e,t,n){P(mb(e,this.b),220).Yl(this.a).Gk()},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateFeatureMapDelegator`,1350),q(91,1,{},Wf,Og,a_,ty),Q.yk=function(e,t,n,r,i){var a=t.li(n);if(a??t.mi(n,a=gP(this,e)),!i)switch(this.e){case 50:case 41:return P(a,597).bk();case 40:return P(a,220).Vl()}return a},Q.zk=function(e,t,n,r,i){var a,o=t.li(n);return o??t.mi(n,o=gP(this,e)),a=P(o,71).Wk(r,i),a},Q.Ak=function(e,t,n,r,i){var a=t.li(n);return a!=null&&(i=P(a,71).Xk(r,i)),i},Q.Bk=function(e,t,n){var r=t.li(n);return r!=null&&P(r,79).Qj()},Q.Ck=function(e,t,n,r){var i=P(t.li(n),79);!i&&t.mi(n,i=gP(this,e)),i.Wb(r)},Q.Dk=function(e,t,n){var r,i=t.li(n);return i??t.mi(n,i=gP(this,e)),j(i,79)?P(i,79):(r=P(t.li(n),15),new Ghe(r))},Q.Ek=function(e,t,n){var r=P(t.li(n),79);!r&&t.mi(n,r=gP(this,e)),r.Gk()},Q.b=0,Q.e=0,L(KH,`EStructuralFeatureImpl/InternalSettingDelegateMany`,91),q(512,1,{}),Q.zk=function(e,t,n,r,i){throw E(new Br)},Q.Ak=function(e,t,n,r,i){throw E(new Br)},Q.Dk=function(e,t,n){return new hIe(this,e,t,n)};var s9;L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingle`,512),q(1367,1,LU,hIe),Q.Fk=function(e){return this.a.yk(this.c,this.d,this.b,e,!0)},Q.Qj=function(){return this.a.Bk(this.c,this.d,this.b)},Q.Wb=function(e){this.a.Ck(this.c,this.d,this.b,e)},Q.Gk=function(){this.a.Ek(this.c,this.d,this.b)},Q.b=0,L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingle/1`,1367),q(784,512,{},ILe),Q.yk=function(e,t,n,r,i){return IM(e,e.Ph(),e.Fh())==this.b?this.bl()&&r?xj(e):e.Ph():null},Q.zk=function(e,t,n,r,i){var a,o;return e.Ph()&&(i=(a=e.Fh(),a>=0?e.Ah(i):e.Ph().Th(e,-1-a,null,i))),o=eD(e.Dh(),this.e),e.Ch(r,o,i)},Q.Ak=function(e,t,n,r,i){var a=eD(e.Dh(),this.e);return e.Ch(null,a,i)},Q.Bk=function(e,t,n){var r=eD(e.Dh(),this.e);return!!e.Ph()&&e.Fh()==r},Q.Ck=function(e,t,n,r){var i,a,o,s,c;if(r!=null&&!QM(this.a,r))throw E(new Pi(tW+(j(r,58)?o5e(P(r,58).Dh()):yx($w(r)))+nW+this.a+`'`));if(i=e.Ph(),o=eD(e.Dh(),this.e),A(r)!==A(i)||e.Fh()!=o&&r!=null){if(Pk(e,P(r,58)))throw E(new Fi(JH+e.Ib()));c=null,i&&(c=(a=e.Fh(),a>=0?e.Ah(c):e.Ph().Th(e,-1-a,null,c))),s=P(r,54),s&&(c=s.Rh(e,eD(s.Dh(),this.b),null,c)),c=e.Ch(s,o,c),c&&c.oj()}else e.vh()&&e.wh()&&AC(e,new Sm(e,1,o,r,r))},Q.Ek=function(e,t,n){var r=e.Ph(),i,a,o;r?(o=(i=e.Fh(),i>=0?e.Ah(null):e.Ph().Th(e,-1-i,null,null)),a=eD(e.Dh(),this.e),o=e.Ch(null,a,o),o&&o.oj()):e.vh()&&e.wh()&&AC(e,new Cm(e,1,this.e,null,null))},Q.bl=function(){return!1},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleContainer`,784),q(1351,784,{},fje),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleContainerResolving`,1351),q(574,512,{}),Q.yk=function(e,t,n,r,i){var a;return a=t.li(n),a==null?this.b:A(a)===A(s9)?null:a},Q.Bk=function(e,t,n){var r=t.li(n);return r!=null&&(A(r)===A(s9)||!NT(r,this.b))},Q.Ck=function(e,t,n,r){var i,a;e.vh()&&e.wh()?(i=(a=t.li(n),a==null?this.b:A(a)===A(s9)?null:a),r==null?this.c==null?this.b==null?t.mi(n,null):t.mi(n,s9):(t.mi(n,null),r=this.b):(this.Bl(r),t.mi(n,r)),AC(e,this.d.Cl(e,1,this.e,i,r))):r==null?this.c==null?this.b==null?t.mi(n,null):t.mi(n,s9):t.mi(n,null):(this.Bl(r),t.mi(n,r))},Q.Ek=function(e,t,n){var r,i;e.vh()&&e.wh()?(r=(i=t.li(n),i==null?this.b:A(i)===A(s9)?null:i),t.ni(n),AC(e,this.d.Cl(e,1,this.e,r,this.b))):t.ni(n)},Q.Bl=function(e){throw E(new xge)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData`,574),q(rW,1,{},Xse),Q.Cl=function(e,t,n,r,i){return new Cm(e,t,n,r,i)},Q.Dl=function(e,t,n,r,i,a){return new Jg(e,t,n,r,i,a)};var iHt,aHt,oHt,sHt,cHt,lHt,uHt,c9,dHt;L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator`,rW),q(1368,rW,{},Zse),Q.Cl=function(e,t,n,r,i){return new bUe(e,t,n,ki(Od(r)),ki(Od(i)))},Q.Dl=function(e,t,n,r,i,a){return new lBe(e,t,n,ki(Od(r)),ki(Od(i)),a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/1`,1368),q(1369,rW,{},Qse),Q.Cl=function(e,t,n,r,i){return new Gqe(e,t,n,P(r,222).a,P(i,222).a)},Q.Dl=function(e,t,n,r,i,a){return new nBe(e,t,n,P(r,222).a,P(i,222).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/2`,1369),q(1370,rW,{},$se),Q.Cl=function(e,t,n,r,i){return new Kqe(e,t,n,P(r,180).a,P(i,180).a)},Q.Dl=function(e,t,n,r,i,a){return new rBe(e,t,n,P(r,180).a,P(i,180).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/3`,1370),q(1371,rW,{},ece),Q.Cl=function(e,t,n,r,i){return new vUe(e,t,n,D(N(r)),D(N(i)))},Q.Dl=function(e,t,n,r,i,a){return new iBe(e,t,n,D(N(r)),D(N(i)),a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/4`,1371),q(1372,rW,{},tce),Q.Cl=function(e,t,n,r,i){return new Yqe(e,t,n,P(r,161).a,P(i,161).a)},Q.Dl=function(e,t,n,r,i,a){return new aBe(e,t,n,P(r,161).a,P(i,161).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/5`,1372),q(1373,rW,{},nce),Q.Cl=function(e,t,n,r,i){return new yUe(e,t,n,P(r,17).a,P(i,17).a)},Q.Dl=function(e,t,n,r,i,a){return new oBe(e,t,n,P(r,17).a,P(i,17).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/6`,1373),q(1374,rW,{},rce),Q.Cl=function(e,t,n,r,i){return new qqe(e,t,n,P(r,168).a,P(i,168).a)},Q.Dl=function(e,t,n,r,i,a){return new sBe(e,t,n,P(r,168).a,P(i,168).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/7`,1374),q(1375,rW,{},ice),Q.Cl=function(e,t,n,r,i){return new Jqe(e,t,n,P(r,191).a,P(i,191).a)},Q.Dl=function(e,t,n,r,i,a){return new cBe(e,t,n,P(r,191).a,P(i,191).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/8`,1375),q(1353,574,{},gIe),Q.Bl=function(e){if(!this.a.fk(e))throw E(new Pi(tW+$w(e)+nW+this.a+`'`))},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataDynamic`,1353),q(1354,574,{},kNe),Q.Bl=function(e){},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataStatic`,1354),q(785,574,{}),Q.Bk=function(e,t,n){return t.li(n)!=null},Q.Ck=function(e,t,n,r){var i,a;e.vh()&&e.wh()?(i=!0,a=t.li(n),a==null?(i=!1,a=this.b):A(a)===A(s9)&&(a=null),r==null?this.c==null?t.mi(n,s9):(t.mi(n,null),r=this.b):(this.Bl(r),t.mi(n,r)),AC(e,this.d.Dl(e,1,this.e,a,r,!i))):r==null?this.c==null?t.mi(n,s9):t.mi(n,null):(this.Bl(r),t.mi(n,r))},Q.Ek=function(e,t,n){var r,i;e.vh()&&e.wh()?(r=!0,i=t.li(n),i==null?(r=!1,i=this.b):A(i)===A(s9)&&(i=null),t.ni(n),AC(e,this.d.Dl(e,2,this.e,i,this.b,r))):t.ni(n)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettable`,785),q(1355,785,{},_Ie),Q.Bl=function(e){if(!this.a.fk(e))throw E(new Pi(tW+$w(e)+nW+this.a+`'`))},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettableDynamic`,1355),q(1356,785,{},ANe),Q.Bl=function(e){},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettableStatic`,1356),q(410,512,{},Bp),Q.yk=function(e,t,n,r,i){var a,o,s,c,l=t.li(n);if(this.tk()&&A(l)===A(s9))return null;if(this.bl()&&r&&l!=null){if(s=P(l,54),s.Vh()&&(c=pT(e,s),s!=c)){if(!QM(this.a,c))throw E(new Pi(tW+$w(c)+nW+this.a+`'`));t.mi(n,l=c),this.al()&&(a=P(c,54),o=s.Th(e,this.b?eD(s.Dh(),this.b):-1-eD(e.Dh(),this.e),null,null),!a.Ph()&&(o=a.Rh(e,this.b?eD(a.Dh(),this.b):-1-eD(e.Dh(),this.e),null,o)),o&&o.oj()),e.vh()&&e.wh()&&AC(e,new Cm(e,9,this.e,s,c))}return l}return l},Q.zk=function(e,t,n,r,i){var a,o=t.li(n);return A(o)===A(s9)&&(o=null),t.mi(n,r),this.Mj()?A(o)!==A(r)&&o!=null&&(a=P(o,54),i=a.Th(e,eD(a.Dh(),this.b),null,i)):this.al()&&o!=null&&(i=P(o,54).Th(e,-1-eD(e.Dh(),this.e),null,i)),e.vh()&&e.wh()&&(!i&&(i=new Pa(4)),i.nj(new Cm(e,1,this.e,o,r))),i},Q.Ak=function(e,t,n,r,i){var a=t.li(n);return A(a)===A(s9)&&(a=null),t.ni(n),e.vh()&&e.wh()&&(!i&&(i=new Pa(4)),this.tk()?i.nj(new Cm(e,2,this.e,a,null)):i.nj(new Cm(e,1,this.e,a,null))),i},Q.Bk=function(e,t,n){return t.li(n)!=null},Q.Ck=function(e,t,n,r){var i,a,o,s,c;if(r!=null&&!QM(this.a,r))throw E(new Pi(tW+(j(r,58)?o5e(P(r,58).Dh()):yx($w(r)))+nW+this.a+`'`));c=t.li(n),s=c!=null,this.tk()&&A(c)===A(s9)&&(c=null),o=null,this.Mj()?A(c)!==A(r)&&(c!=null&&(i=P(c,54),o=i.Th(e,eD(i.Dh(),this.b),null,o)),r!=null&&(i=P(r,54),o=i.Rh(e,eD(i.Dh(),this.b),null,o))):this.al()&&A(c)!==A(r)&&(c!=null&&(o=P(c,54).Th(e,-1-eD(e.Dh(),this.e),null,o)),r!=null&&(o=P(r,54).Rh(e,-1-eD(e.Dh(),this.e),null,o))),r==null&&this.tk()?t.mi(n,s9):t.mi(n,r),e.vh()&&e.wh()?(a=new Jg(e,1,this.e,c,r,this.tk()&&!s),o?(o.nj(a),o.oj()):AC(e,a)):o&&o.oj()},Q.Ek=function(e,t,n){var r,i,a,o,s=t.li(n);o=s!=null,this.tk()&&A(s)===A(s9)&&(s=null),a=null,s!=null&&(this.Mj()?(r=P(s,54),a=r.Th(e,eD(r.Dh(),this.b),null,a)):this.al()&&(a=P(s,54).Th(e,-1-eD(e.Dh(),this.e),null,a))),t.ni(n),e.vh()&&e.wh()?(i=new Jg(e,this.tk()?2:1,this.e,s,null,o),a?(a.nj(i),a.oj()):AC(e,i)):a&&a.oj()},Q.Mj=function(){return!1},Q.al=function(){return!1},Q.bl=function(){return!1},Q.tk=function(){return!1},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObject`,410),q(575,410,{},Ed),Q.al=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainment`,575),q(1359,575,{},JEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentResolving`,1359),q(787,575,{},YEe),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentUnsettable`,787),q(1361,787,{},ZEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentUnsettableResolving`,1361),q(650,575,{},Gf),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverse`,650),q(1360,650,{},hje),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseResolving`,1360),q(788,650,{},gje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseUnsettable`,788),q(1362,788,{},_je),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseUnsettableResolving`,1362),q(651,410,{},XEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolving`,651),q(1363,651,{},QEe),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingUnsettable`,1363),q(789,651,{},pje),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingWithInverse`,789),q(1364,789,{},vje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingWithInverseUnsettable`,1364),q(1357,410,{},$Ee),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectUnsettable`,1357),q(786,410,{},mje),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectWithInverse`,786),q(1358,786,{},yje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectWithInverseUnsettable`,1358),q(790,576,eW,Mh),Q.yl=function(e){return new Mh(this.a,this.c,e)},Q.md=function(){return this.b},Q.zl=function(e,t,n){return UWe(this,e,this.b,n)},Q.Al=function(e,t,n){return WWe(this,e,this.b,n)},L(KH,`EStructuralFeatureImpl/InverseUpdatingFeatureMapEntry`,790),q(1365,1,LU,Ghe),Q.Fk=function(e){return this.a},Q.Qj=function(){return j(this.a,97)?P(this.a,97).Qj():!this.a.dc()},Q.Wb=function(e){this.a.$b(),this.a.Gc(P(e,15))},Q.Gk=function(){j(this.a,97)?P(this.a,97).Gk():this.a.$b()},L(KH,`EStructuralFeatureImpl/SettingMany`,1365),q(1366,576,eW,gHe),Q.xl=function(e){return new Gd((UN(),k9),this.b.ri(this.a,e))},Q.md=function(){return null},Q.zl=function(e,t,n){return n},Q.Al=function(e,t,n){return n},L(KH,`EStructuralFeatureImpl/SimpleContentFeatureMapEntry`,1366),q(652,576,eW,Gd),Q.xl=function(e){return new Gd(this.c,e)},Q.md=function(){return this.a},Q.zl=function(e,t,n){return n},Q.Al=function(e,t,n){return n},L(KH,`EStructuralFeatureImpl/SimpleFeatureMapEntry`,652),q(403,506,SU,ln),Q.aj=function(e){return V(D7,FP,29,e,0,1)},Q.Yi=function(){return!1},L(KH,`ESuperAdapter/1`,403),q(457,448,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,850:1,54:1,99:1,158:1,457:1,119:1,120:1},un),Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return!this.a&&(this.a=new Vp(this,j7,this)),this.a}return xb(this,e-bh((CP(),e9)),_x((r=P(NC(this,16),29),r||e9),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 2:return!this.a&&(this.a=new Vp(this,j7,this)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),e9)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),e9)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),e9)),_x((t=P(NC(this,16),29),t||e9),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:!this.a&&(this.a=new Vp(this,j7,this)),RN(this.a),!this.a&&(this.a=new Vp(this,j7,this)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),e9)),_x((n=P(NC(this,16),29),n||e9),e),t)},Q.ii=function(){return CP(),e9},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:!this.a&&(this.a=new Vp(this,j7,this)),RN(this.a);return}PT(this,e-bh((CP(),e9)),_x((t=P(NC(this,16),29),t||e9),e))},L(KH,`ETypeParameterImpl`,457),q(458,83,JU,Vp),Q.Nj=function(e,t){return g7e(this,P(e,89),t)},Q.Oj=function(e,t){return _7e(this,P(e,89),t)},L(KH,`ETypeParameterImpl/1`,458),q(647,45,CI,ui),Q.ec=function(){return new Sr(this)},L(KH,`ETypeParameterImpl/2`,647),q(570,GP,KP,Sr),Q.Fc=function(e){return mOe(this,P(e,89))},Q.Gc=function(e){var t,n,r=!1;for(n=e.Kc();n.Ob();)t=P(n.Pb(),89),Qh(this.a,t,``)??(r=!0);return r},Q.$b=function(){Pm(this.a)},Q.Hc=function(e){return km(this.a,e)},Q.Kc=function(){var e;return e=new EC(new Fn(this.a).a),new Cr(e)},Q.Mc=function(e){return iWe(this,e)},Q.gc=function(){return ho(this.a)},L(KH,`ETypeParameterImpl/2/1`,570),q(571,1,VP,Cr),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(MS(this.a).ld(),89)},Q.Ob=function(){return this.a.b},Q.Qb=function(){aKe(this.a)},L(KH,`ETypeParameterImpl/2/1/1`,571),q(1329,45,CI,h_e),Q._b=function(e){return rl(e)?e_(this,e):!!Kp(this.f,e)},Q.xc=function(e){var t=rl(e)?v_(this,e):nl(Kp(this.f,e)),n;return j(t,851)?(n=P(t,851),t=n.Kk(),Qh(this,P(e,241),t),t):t??(e==null?(Zo(),yHt):null)},L(KH,`EValidatorRegistryImpl`,1329),q(1349,720,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,2040:1,54:1,99:1,158:1,119:1,120:1},ace),Q.ri=function(e,t){switch(e.hk()){case 21:case 22:case 23:case 24:case 26:case 31:case 32:case 37:case 38:case 39:case 40:case 43:case 44:case 48:case 49:case 20:return t==null?null:PE(t);case 25:return Cqe(t);case 27:return BGe(t);case 28:return VGe(t);case 29:return t==null?null:Nwe(t7[0],P(t,206));case 41:return t==null?``:Ha(P(t,297));case 42:return PE(t);case 50:return kd(t);default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;switch(e.G==-1&&(e.G=(f=Mx(e),f?NO(f.vi(),e):-1)),e.G){case 0:return n=new oi,n;case 1:return t=new Vse,t;case 2:return r=new Que,r;case 4:return i=new Ur,i;case 5:return a=new m_e,a;case 6:return o=new wge,o;case 7:return s=new $ue,s;case 10:return l=new sn,l;case 11:return u=new si,u;case 12:return d=new IIe,d;case 13:return p=new li,p;case 14:return m=new uDe,m;case 17:return h=new Yse,h;case 18:return c=new kr,c;case 19:return g=new un,g;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){switch(e.hk()){case 20:return t==null?null:new xye(t);case 21:return t==null?null:new ru(t);case 23:case 22:return t==null?null:X0e(t);case 26:case 24:return t==null?null:Gb(GM(t,-128,127)<<24>>24);case 25:return Rit(t);case 27:return G3e(t);case 28:return K3e(t);case 29:return q7e(t);case 32:case 31:return t==null?null:OA(t);case 38:case 37:return t==null?null:new jge(t);case 40:case 39:return t==null?null:G(GM(t,xF,AP));case 41:return null;case 42:return null;case 44:case 43:return t==null?null:JD(aP(t));case 49:case 48:return t==null?null:xT(GM(t,aW,32767)<<16>>16);case 50:return t;default:throw E(new Fi(YH+e.xe()+XH))}},L(KH,`EcoreFactoryImpl`,1349),q(560,184,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,2038:1,54:1,99:1,158:1,184:1,560:1,119:1,120:1,690:1},MFe),Q.gb=!1,Q.hb=!1;var fHt,pHt=!1;L(KH,`EcorePackageImpl`,560),q(1234,1,{851:1},oce),Q.Kk=function(){return xTe(),bHt},L(KH,`EcorePackageImpl/1`,1234),q(1243,1,lW,sce),Q.fk=function(e){return j(e,155)},Q.gk=function(e){return V(G5,FP,155,e,0,1)},L(KH,`EcorePackageImpl/10`,1243),q(1244,1,lW,cce),Q.fk=function(e){return j(e,197)},Q.gk=function(e){return V(q5,FP,197,e,0,1)},L(KH,`EcorePackageImpl/11`,1244),q(1245,1,lW,lce),Q.fk=function(e){return j(e,58)},Q.gk=function(e){return V(L5,FP,58,e,0,1)},L(KH,`EcorePackageImpl/12`,1245),q(1246,1,lW,uce),Q.fk=function(e){return j(e,411)},Q.gk=function(e){return V(M7,Cwt,62,e,0,1)},L(KH,`EcorePackageImpl/13`,1246),q(1247,1,lW,dce),Q.fk=function(e){return j(e,241)},Q.gk=function(e){return V(J5,FP,241,e,0,1)},L(KH,`EcorePackageImpl/14`,1247),q(1248,1,lW,fce),Q.fk=function(e){return j(e,518)},Q.gk=function(e){return V(P7,FP,2116,e,0,1)},L(KH,`EcorePackageImpl/15`,1248),q(1249,1,lW,pce),Q.fk=function(e){return j(e,102)},Q.gk=function(e){return V(F7,qU,19,e,0,1)},L(KH,`EcorePackageImpl/16`,1249),q(1250,1,lW,mce),Q.fk=function(e){return j(e,179)},Q.gk=function(e){return V(w7,qU,179,e,0,1)},L(KH,`EcorePackageImpl/17`,1250),q(1251,1,lW,hce),Q.fk=function(e){return j(e,481)},Q.gk=function(e){return V(C7,FP,481,e,0,1)},L(KH,`EcorePackageImpl/18`,1251),q(1252,1,lW,gce),Q.fk=function(e){return j(e,561)},Q.gk=function(e){return V(o9,owt,561,e,0,1)},L(KH,`EcorePackageImpl/19`,1252),q(1235,1,lW,_ce),Q.fk=function(e){return j(e,331)},Q.gk=function(e){return V(T7,qU,35,e,0,1)},L(KH,`EcorePackageImpl/2`,1235),q(1253,1,lW,vce),Q.fk=function(e){return j(e,248)},Q.gk=function(e){return V(j7,Twt,89,e,0,1)},L(KH,`EcorePackageImpl/20`,1253),q(1254,1,lW,yce),Q.fk=function(e){return j(e,457)},Q.gk=function(e){return V(I7,FP,850,e,0,1)},L(KH,`EcorePackageImpl/21`,1254),q(1255,1,lW,bce),Q.fk=function(e){return il(e)},Q.gk=function(e){return V(bG,X,485,e,8,1)},L(KH,`EcorePackageImpl/22`,1255),q(1256,1,lW,xce),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(KH,`EcorePackageImpl/23`,1256),q(1257,1,lW,Sce),Q.fk=function(e){return j(e,222)},Q.gk=function(e){return V(xG,X,222,e,0,1)},L(KH,`EcorePackageImpl/24`,1257),q(1258,1,lW,Cce),Q.fk=function(e){return j(e,180)},Q.gk=function(e){return V(CG,X,180,e,0,1)},L(KH,`EcorePackageImpl/25`,1258),q(1259,1,lW,wce),Q.fk=function(e){return j(e,206)},Q.gk=function(e){return V(fG,X,206,e,0,1)},L(KH,`EcorePackageImpl/26`,1259),q(1260,1,lW,Tce),Q.fk=function(e){return!1},Q.gk=function(e){return V(dUt,FP,2215,e,0,1)},L(KH,`EcorePackageImpl/27`,1260),q(1261,1,lW,Ece),Q.fk=function(e){return al(e)},Q.gk=function(e){return V(TG,X,345,e,7,1)},L(KH,`EcorePackageImpl/28`,1261),q(1262,1,lW,Dce),Q.fk=function(e){return j(e,61)},Q.gk=function(e){return V(xVt,BL,61,e,0,1)},L(KH,`EcorePackageImpl/29`,1262),q(1236,1,lW,Oce),Q.fk=function(e){return j(e,519)},Q.gk=function(e){return V(S7,{3:1,4:1,5:1,2033:1},598,e,0,1)},L(KH,`EcorePackageImpl/3`,1236),q(1263,1,lW,kce),Q.fk=function(e){return j(e,582)},Q.gk=function(e){return V(DVt,FP,2039,e,0,1)},L(KH,`EcorePackageImpl/30`,1263),q(1264,1,lW,Ace),Q.fk=function(e){return j(e,160)},Q.gk=function(e){return V(vHt,BL,160,e,0,1)},L(KH,`EcorePackageImpl/31`,1264),q(1265,1,lW,jce),Q.fk=function(e){return j(e,76)},Q.gk=function(e){return V(t9,Iwt,76,e,0,1)},L(KH,`EcorePackageImpl/32`,1265),q(1266,1,lW,Mce),Q.fk=function(e){return j(e,161)},Q.gk=function(e){return V(EG,X,161,e,0,1)},L(KH,`EcorePackageImpl/33`,1266),q(1267,1,lW,Nce),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(KH,`EcorePackageImpl/34`,1267),q(1268,1,lW,Pce),Q.fk=function(e){return j(e,297)},Q.gk=function(e){return V(DTt,FP,297,e,0,1)},L(KH,`EcorePackageImpl/35`,1268),q(1269,1,lW,Fce),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(KH,`EcorePackageImpl/36`,1269),q(1270,1,lW,Ice),Q.fk=function(e){return j(e,85)},Q.gk=function(e){return V(kTt,FP,85,e,0,1)},L(KH,`EcorePackageImpl/37`,1270),q(1271,1,lW,Lce),Q.fk=function(e){return j(e,599)},Q.gk=function(e){return V(mHt,FP,599,e,0,1)},L(KH,`EcorePackageImpl/38`,1271),q(1272,1,lW,Rce),Q.fk=function(e){return!1},Q.gk=function(e){return V(fUt,FP,2216,e,0,1)},L(KH,`EcorePackageImpl/39`,1272),q(1237,1,lW,zce),Q.fk=function(e){return j(e,90)},Q.gk=function(e){return V(D7,FP,29,e,0,1)},L(KH,`EcorePackageImpl/4`,1237),q(1273,1,lW,Bce),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(KH,`EcorePackageImpl/40`,1273),q(1274,1,lW,Vce),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(KH,`EcorePackageImpl/41`,1274),q(1275,1,lW,Hce),Q.fk=function(e){return j(e,596)},Q.gk=function(e){return V(CVt,FP,596,e,0,1)},L(KH,`EcorePackageImpl/42`,1275),q(1276,1,lW,Uce),Q.fk=function(e){return!1},Q.gk=function(e){return V(pUt,X,2217,e,0,1)},L(KH,`EcorePackageImpl/43`,1276),q(1277,1,lW,Wce),Q.fk=function(e){return j(e,44)},Q.gk=function(e){return V(YW,oF,44,e,0,1)},L(KH,`EcorePackageImpl/44`,1277),q(1238,1,lW,Gce),Q.fk=function(e){return j(e,142)},Q.gk=function(e){return V(E7,FP,142,e,0,1)},L(KH,`EcorePackageImpl/5`,1238),q(1239,1,lW,Kce),Q.fk=function(e){return j(e,156)},Q.gk=function(e){return V(O7,FP,156,e,0,1)},L(KH,`EcorePackageImpl/6`,1239),q(1240,1,lW,qce),Q.fk=function(e){return j(e,469)},Q.gk=function(e){return V(k7,FP,685,e,0,1)},L(KH,`EcorePackageImpl/7`,1240),q(1241,1,lW,Jce),Q.fk=function(e){return j(e,582)},Q.gk=function(e){return V(A7,FP,694,e,0,1)},L(KH,`EcorePackageImpl/8`,1241),q(1242,1,lW,Yce),Q.fk=function(e){return j(e,480)},Q.gk=function(e){return V(K5,FP,480,e,0,1)},L(KH,`EcorePackageImpl/9`,1242),q(1038,2080,iwt,K_e),Q.Mi=function(e,t){B$e(this,P(t,424))},Q.Qi=function(e,t){ntt(this,e,P(t,424))},L(KH,`MinimalEObjectImpl/1ArrayDelegatingAdapterList`,1038),q(1039,152,NU,cFe),Q.jj=function(){return this.a.a},L(KH,`MinimalEObjectImpl/1ArrayDelegatingAdapterList/1`,1039),q(1067,1066,{},uwe),L(`org.eclipse.emf.ecore.plugin`,`EcorePlugin`,1067);var mHt=gp(Lwt,`Resource`);q(799,1524,Rwt),Q.Hl=function(e){},Q.Il=function(e){},Q.El=function(){return!this.a&&(this.a=new wr(this)),this.a},Q.Fl=function(e){var t,n,r=e.length,i,a;if(r>0){if(sv(0,e.length),e.charCodeAt(0)==47){for(a=new Hy(4),i=1,t=1;t0&&(e=(Zy(0,n,e.length),e.substr(0,n))))}return hnt(this,e)},Q.Gl=function(){return this.c},Q.Ib=function(){var e;return Ha(this.Rm)+`@`+(e=US(this)>>>0,e.toString(16))+` uri='`+this.d+`'`},Q.b=!1,L(uW,`ResourceImpl`,799),q(1525,799,Rwt,qhe),L(uW,`BinaryResourceImpl`,1525),q(1190,708,CU),Q.bj=function(e){return j(e,58)?rLe(this,P(e,58)):j(e,599)?new Lu(P(e,599).El()):A(e)===A(this.f)?P(e,16).Kc():(Nd(),_7.a)},Q.Ob=function(){return ert(this)},Q.a=!1,L(IU,`EcoreUtil/ContentTreeIterator`,1190),q(1526,1190,CU,sPe),Q.bj=function(e){return A(e)===A(this.f)?P(e,15).Kc():new aVe(P(e,58))},L(uW,`ResourceImpl/5`,1526),q(658,2092,wwt,wr),Q.Hc=function(e){return this.i<=4?Uk(this,e):j(e,54)&&P(e,54).Jh()==this.a},Q.Mi=function(e,t){e==this.i-1&&(this.a.b||(this.a.b=!0))},Q.Oi=function(e,t){e==0?this.a.b||(this.a.b=!0):Xy(this,e,t)},Q.Qi=function(e,t){},Q.Ri=function(e,t,n){},Q.Lj=function(){return 2},Q.jj=function(){return this.a},Q.Mj=function(){return!0},Q.Nj=function(e,t){return t=P(e,54).fi(this.a,t),t},Q.Oj=function(e,t){return P(e,54).fi(null,t)},Q.Pj=function(){return!1},Q.Si=function(){return!0},Q.aj=function(e){return V(L5,FP,58,e,0,1)},Q.Yi=function(){return!1},L(uW,`ResourceImpl/ContentsEList`,658),q(970,2062,gF,Jhe),Q.fd=function(e){return this.a.Ki(e)},Q.gc=function(){return this.a.gc()},L(IU,`AbstractSequentialInternalEList/1`,970);var hHt,gHt,l9,_Ht;q(634,1,{},tMe);var u9,d9;L(IU,`BasicExtendedMetaData`,634),q(1181,1,{},QSe),Q.Jl=function(){return null},Q.Kl=function(){return this.a==-2&&sfe(this,F7e(this.d,this.b)),this.a},Q.Ll=function(){return null},Q.Ml=function(){return Vg(),Vg(),QG},Q.xe=function(){return this.c==SW&&cfe(this,f2e(this.d,this.b)),this.c},Q.Nl=function(){return 0},Q.a=-2,Q.c=SW,L(IU,`BasicExtendedMetaData/EClassExtendedMetaDataImpl`,1181),q(1182,1,{},dBe),Q.Jl=function(){return this.a==(By(),u9)&&dfe(this,olt(this.f,this.b)),this.a},Q.Kl=function(){return 0},Q.Ll=function(){return this.c==(By(),u9)&&lfe(this,slt(this.f,this.b)),this.c},Q.Ml=function(){return!this.d&&pfe(this,rft(this.f,this.b)),this.d},Q.xe=function(){return this.e==SW&&hfe(this,f2e(this.f,this.b)),this.e},Q.Nl=function(){return this.g==-2&&_fe(this,R5e(this.f,this.b)),this.g},Q.e=SW,Q.g=-2,L(IU,`BasicExtendedMetaData/EDataTypeExtendedMetaDataImpl`,1182),q(1180,1,{},$Se),Q.b=!1,Q.c=!1,L(IU,`BasicExtendedMetaData/EPackageExtendedMetaDataImpl`,1180),q(1183,1,{},fBe),Q.c=-2,Q.e=SW,Q.f=SW,L(IU,`BasicExtendedMetaData/EStructuralFeatureExtendedMetaDataImpl`,1183),q(593,632,JU,ip),Q.Lj=function(){return this.c},Q.ol=function(){return!1},Q.Wi=function(e,t){return t},Q.c=0,L(IU,`EDataTypeEList`,593);var vHt=gp(IU,`FeatureMap`);q(78,593,{3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,79:1,160:1,220:1,2036:1,71:1,97:1},DC),Q.bd=function(e,t){got(this,e,P(t,76))},Q.Fc=function(e){return xat(this,P(e,76))},Q.Hi=function(e){UPe(this,P(e,76))},Q.Nj=function(e,t){return qOe(this,P(e,76),t)},Q.Oj=function(e,t){return JOe(this,P(e,76),t)},Q.Ti=function(e,t){return Dut(this,e,t)},Q.Wi=function(e,t){return Umt(this,e,P(t,76))},Q.hd=function(e,t){return xst(this,e,P(t,76))},Q.Uj=function(e,t){return YOe(this,P(e,76),t)},Q.Vj=function(e,t){return XOe(this,P(e,76),t)},Q.Wj=function(e,t,n){return f5e(this,P(e,76),P(t,76),n)},Q.Zi=function(e,t){return aA(this,e,P(t,76))},Q.Ol=function(e,t){return cut(this,e,t)},Q.cd=function(e,t){var n,r,i,a,o,s,c,l=new kx(t.gc()),u;for(i=t.Kc();i.Ob();)if(r=P(i.Pb(),76),a=r.Lk(),aM(this.e,a))(!a.Si()||!Kv(this,a,r.md())&&!Uk(l,r))&&tb(l,r);else{for(u=nM(this.e.Dh(),a),n=P(this.g,124),o=!0,s=0;s=0;)if(t=e[this.c],this.k.am(t.Lk()))return this.j=this.f?t:t.md(),this.i=-2,!0;return this.i=-1,this.g=-1,!1},L(IU,`BasicFeatureMap/FeatureEIterator`,420),q(676,420,YP,Dl),Q.ul=function(){return!0},L(IU,`BasicFeatureMap/ResolvingFeatureEIterator`,676),q(968,496,QU,zwe),Q.pj=function(){return this},L(IU,`EContentsEList/1`,968),q(969,496,QU,mCe),Q.ul=function(){return!1},L(IU,`EContentsEList/2`,969),q(967,287,$U,Bwe),Q.wl=function(e){},Q.Ob=function(){return!1},Q.Sb=function(){return!1},L(IU,`EContentsEList/FeatureIteratorImpl/1`,967),q(840,593,JU,uTe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EDataTypeEList/Unsettable`,840),q(1958,593,JU,dTe),Q.Si=function(){return!0},L(IU,`EDataTypeUniqueEList`,1958),q(1959,840,JU,fTe),Q.Si=function(){return!0},L(IU,`EDataTypeUniqueEList/Unsettable`,1959),q(147,83,JU,Nu),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentEList/Resolving`,147),q(1184,555,JU,pTe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentEList/Unsettable/Resolving`,1184),q(766,14,JU,rf),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectContainmentWithInverseEList/Unsettable`,766),q(1222,766,JU,yOe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentWithInverseEList/Unsettable/Resolving`,1222),q(757,505,JU,mTe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectEList/Unsettable`,757),q(338,505,JU,Pu),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectResolvingEList`,338),q(1844,757,JU,hTe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectResolvingEList/Unsettable`,1844),q(1527,1,{},Xce);var yHt;L(IU,`EObjectValidator`,1527),q(559,505,JU,wm),Q.il=function(){return this.d},Q.jl=function(){return this.b},Q.Mj=function(){return!0},Q.ml=function(){return!0},Q.b=0,L(IU,`EObjectWithInverseEList`,559),q(1225,559,JU,bOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseEList/ManyInverse`,1225),q(635,559,JU,af),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectWithInverseEList/Unsettable`,635),q(1224,635,JU,xOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseEList/Unsettable/ManyInverse`,1224),q(767,559,JU,of),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectWithInverseResolvingEList`,767),q(32,767,JU,cf),Q.ll=function(){return!0},L(IU,`EObjectWithInverseResolvingEList/ManyInverse`,32),q(768,635,JU,sf),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectWithInverseResolvingEList/Unsettable`,768),q(1223,768,JU,SOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseResolvingEList/Unsettable/ManyInverse`,1223),q(1185,632,JU),Q.Li=function(){return!(this.b&1792)},Q.Ni=function(){this.b|=1},Q.kl=function(){return!!(this.b&4)},Q.Mj=function(){return!!(this.b&40)},Q.ll=function(){return!!(this.b&16)},Q.ml=function(){return!!(this.b&8)},Q.nl=function(){return(this.b&zU)!=0},Q.al=function(){return!!(this.b&32)},Q.ol=function(){return(this.b&pF)!=0},Q.fk=function(e){return this.d?HVe(this.d,e):this.Lk().Hk().fk(e)},Q.Qj=function(){return this.b&2?!!(this.b&1):this.i!=0},Q.Si=function(){return!!(this.b&128)},Q.Gk=function(){var e;RN(this),this.b&2&&(Gl(this.e)?(e=!!(this.b&1),this.b&=-2,Kr(this,new vy(this.e,2,eD(this.e.Dh(),this.Lk()),e,!1))):this.b&=-2)},Q.Yi=function(){return!(this.b&1536)},Q.b=0,L(IU,`EcoreEList/Generic`,1185),q(1186,1185,JU,BIe),Q.Lk=function(){return this.a},L(IU,`EcoreEList/Dynamic`,1186),q(765,66,SU,Yhe),Q.aj=function(e){return tS(this.a.a,e)},L(IU,`EcoreEMap/1`,765),q(764,83,JU,dPe),Q.Mi=function(e,t){JO(this.b,P(t,136))},Q.Oi=function(e,t){sXe(this.b)},Q.Pi=function(e,t,n){var r;++(r=this.b,P(t,136),r).e},Q.Qi=function(e,t){$T(this.b,P(t,136))},Q.Ri=function(e,t,n){$T(this.b,P(n,136)),A(n)===A(t)&&P(n,136).Ci(swe(P(t,136).ld())),JO(this.b,P(t,136))},L(IU,`EcoreEMap/DelegateEObjectContainmentEList`,764),q(1220,141,bwt,TJe),L(IU,`EcoreEMap/Unsettable`,1220),q(1221,764,JU,COe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EcoreEMap/Unsettable/UnsettableDelegateEObjectContainmentEList`,1221),q(1189,215,CI,GPe),Q.a=!1,Q.b=!1,L(IU,`EcoreUtil/Copier`,1189),q(759,1,VP,aVe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return M0e(this)},Q.Pb=function(){var e;return M0e(this),e=this.b,this.b=null,e},Q.Qb=function(){this.a.Qb()},L(IU,`EcoreUtil/ProperContentIterator`,759),q(1528,1527,{},ede);var bHt;L(IU,`EcoreValidator`,1528);var xHt;gp(IU,`FeatureMapUtil/Validator`),q(1295,1,{2041:1},Zce),Q.am=function(e){return!0},L(IU,`FeatureMapUtil/1`,1295),q(773,1,{2041:1},Egt),Q.am=function(e){var t;return this.c==e||(t=Od(xh(this.a,e)),t==null?_lt(this,e)?(PUe(this.a,e,(rd(),yG)),!0):(PUe(this.a,e,(rd(),vG)),!1):t==(rd(),yG))},Q.e=!1;var f9;L(IU,`FeatureMapUtil/BasicValidator`,773),q(774,45,CI,Rwe),L(IU,`FeatureMapUtil/BasicValidator/Cache`,774),q(509,56,{20:1,31:1,56:1,16:1,15:1,61:1,79:1,71:1,97:1},Qc),Q.bd=function(e,t){Mst(this.c,this.b,e,t)},Q.Fc=function(e){return cut(this.c,this.b,e)},Q.cd=function(e,t){return vpt(this.c,this.b,e,t)},Q.Gc=function(e){return Su(this,e)},Q.Gi=function(e,t){$Ke(this.c,this.b,e,t)},Q.Wk=function(e,t){return plt(this.c,this.b,e,t)},Q.$i=function(e){return CN(this.c,this.b,e,!1)},Q.Ii=function(){return BCe(this.c,this.b)},Q.Ji=function(){return VCe(this.c,this.b)},Q.Ki=function(e){return GWe(this.c,this.b,e)},Q.Xk=function(e,t){return NDe(this,e,t)},Q.$b=function(){qr(this)},Q.Hc=function(e){return Kv(this.c,this.b,e)},Q.Ic=function(e){return MYe(this.c,this.b,e)},Q.Xb=function(e){return CN(this.c,this.b,e,!0)},Q.Fk=function(e){return this},Q.dd=function(e){return cHe(this.c,this.b,e)},Q.dc=function(){return tl(this)},Q.Qj=function(){return!lD(this.c,this.b)},Q.Kc=function(){return SKe(this.c,this.b)},Q.ed=function(){return CKe(this.c,this.b)},Q.fd=function(e){return p1e(this.c,this.b,e)},Q.Ti=function(e,t){return Ndt(this.c,this.b,e,t)},Q.Ui=function(e,t){XWe(this.c,this.b,e,t)},Q.gd=function(e){return _et(this.c,this.b,e)},Q.Mc=function(e){return eut(this.c,this.b,e)},Q.hd=function(e,t){return sft(this.c,this.b,e,t)},Q.Wb=function(e){_j(this.c,this.b),Su(this,P(e,15))},Q.gc=function(){return f1e(this.c,this.b)},Q.Pc=function(){return mBe(this.c,this.b)},Q.Qc=function(e){return lHe(this.c,this.b,e)},Q.Ib=function(){var e,t=new $i;for(t.a+=`[`,e=BCe(this.c,this.b);Uw(e);)pl(t,Uu(MO(e))),Uw(e)&&(t.a+=PP);return t.a+=`]`,t.a},Q.Gk=function(){_j(this.c,this.b)},L(IU,`FeatureMapUtil/FeatureEList`,509),q(644,39,NU,ey),Q.hj=function(e){return BT(this,e)},Q.mj=function(e){var t,n,r,i,a,o,s;switch(this.d){case 1:case 2:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.g=e.ij(),e.gj()==1&&(this.d=1),!0;break;case 3:if(i=e.gj(),i===3&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return this.d=5,t=new kx(2),tb(t,this.g),tb(t,e.ij()),this.g=t,!0;break;case 5:if(i=e.gj(),i===3&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return n=P(this.g,16),n.Fc(e.ij()),!0;break;case 4:switch(i=e.gj(),i){case 3:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.d=1,this.g=e.ij(),!0;break;case 4:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.d=6,s=new kx(2),tb(s,this.n),tb(s,e.kj()),this.n=s,o=U(O(q9,1),HF,28,15,[this.o,e.lj()]),this.g=o,!0}break;case 6:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return n=P(this.n,16),n.Fc(e.kj()),o=P(this.g,53),r=V(q9,HF,28,o.length+1,15,1),tN(o,0,r,0,o.length),r[o.length]=e.lj(),this.g=r,!0}return!1},L(IU,`FeatureMapUtil/FeatureENotificationImpl`,644),q(564,509,{20:1,31:1,56:1,16:1,15:1,61:1,79:1,160:1,220:1,2036:1,71:1,97:1},hp),Q.Ol=function(e,t){return cut(this.c,e,t)},Q.Pl=function(e,t,n){return plt(this.c,e,t,n)},Q.Ql=function(e,t,n){return Xft(this.c,e,t,n)},Q.Rl=function(){return this},Q.Sl=function(e,t){return SN(this.c,e,t)},Q.Tl=function(e){return P(CN(this.c,this.b,e,!1),76).Lk()},Q.Ul=function(e){return P(CN(this.c,this.b,e,!1),76).md()},Q.Vl=function(){return this.a},Q.Wl=function(e){return!lD(this.c,e)},Q.Xl=function(e,t){ON(this.c,e,t)},Q.Yl=function(e){return LJe(this.c,e)},Q.Zl=function(e){v3e(this.c,e)},L(IU,`FeatureMapUtil/FeatureFeatureMap`,564),q(1294,1,LU,ZSe),Q.Fk=function(e){return CN(this.b,this.a,-1,e)},Q.Qj=function(){return!lD(this.b,this.a)},Q.Wb=function(e){ON(this.b,this.a,e)},Q.Gk=function(){_j(this.b,this.a)},L(IU,`FeatureMapUtil/FeatureValue`,1294);var p9,m9,h9,g9,SHt,_9=gp(wW,`AnyType`);q(680,63,SF,Hi),L(wW,`InvalidDatatypeValueException`,680);var v9=gp(wW,Hwt),y9=gp(wW,Uwt),CHt=gp(wW,Wwt),wHt,b9,THt,x9,EHt,DHt,OHt,kHt,AHt,jHt,MHt,NHt,PHt,FHt,IHt,S9,LHt,C9,w9,RHt,T9,E9,D9,zHt,O9,k9;q(844,516,{110:1,94:1,93:1,58:1,54:1,99:1,857:1},g_e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.c&&(this.c=new DC(this,0)),this.c):(!this.c&&(this.c=new DC(this,0)),this.c.b);case 1:return n?(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)):(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Vl();case 2:return n?(!this.b&&(this.b=new DC(this,2)),this.b):(!this.b&&(this.b=new DC(this,2)),this.b.b)}return xb(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e),t,n)},Q.Uh=function(e,t,n){var r;switch(t){case 0:return!this.c&&(this.c=new DC(this,0)),zM(this.c,e,n);case 1:return(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),71)).Xk(e,n);case 2:return!this.b&&(this.b=new DC(this,2)),zM(this.b,e,n)}return r=P(_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),t),69),r.wk().Ak(this,Jb(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){switch(e){case 0:return!!this.c&&this.c.i!=0;case 1:return!(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).dc();case 2:return!!this.b&&this.b.i!=0}return Hv(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e))},Q.bi=function(e,t){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),qm(this.c,t);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Wb(t);return;case 2:!this.b&&(this.b=new DC(this,2)),qm(this.b,t);return}LE(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e),t)},Q.ii=function(){return UN(),THt},Q.ki=function(e){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),RN(this.c);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).$b();return;case 2:!this.b&&(this.b=new DC(this,2)),RN(this.b);return}PT(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (mixed: `,fl(e,this.c),e.a+=`, anyAttribute: `,fl(e,this.b),e.a+=`)`,e.a)},L(TW,`AnyTypeImpl`,844),q(681,516,{110:1,94:1,93:1,58:1,54:1,99:1,2119:1,681:1},cle),Q.Lh=function(e,t,n){switch(e){case 0:return this.a;case 1:return this.b}return xb(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e),t,n)},Q.Wh=function(e){switch(e){case 0:return this.a!=null;case 1:return this.b!=null}return Hv(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e))},Q.bi=function(e,t){switch(e){case 0:bfe(this,kd(t));return;case 1:Sfe(this,kd(t));return}LE(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e),t)},Q.ii=function(){return UN(),S9},Q.ki=function(e){switch(e){case 0:this.a=null;return;case 1:this.b=null;return}PT(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (data: `,pl(e,this.a),e.a+=`, target: `,pl(e,this.b),e.a+=`)`,e.a)},Q.a=null,Q.b=null,L(TW,`ProcessingInstructionImpl`,681),q(682,844,{110:1,94:1,93:1,58:1,54:1,99:1,857:1,2120:1,682:1},__e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.c&&(this.c=new DC(this,0)),this.c):(!this.c&&(this.c=new DC(this,0)),this.c.b);case 1:return n?(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)):(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Vl();case 2:return n?(!this.b&&(this.b=new DC(this,2)),this.b):(!this.b&&(this.b=new DC(this,2)),this.b.b);case 3:return!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0));case 4:return df(this.a,(!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))));case 5:return this.a}return xb(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e),t,n)},Q.Wh=function(e){switch(e){case 0:return!!this.c&&this.c.i!=0;case 1:return!(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).dc();case 2:return!!this.b&&this.b.i!=0;case 3:return!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))!=null;case 4:return df(this.a,(!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))))!=null;case 5:return!!this.a}return Hv(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e))},Q.bi=function(e,t){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),qm(this.c,t);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Wb(t);return;case 2:!this.b&&(this.b=new DC(this,2)),qm(this.b,t);return;case 3:pBe(this,kd(t));return;case 4:pBe(this,uf(this.a,t));return;case 5:xfe(this,P(t,156));return}LE(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e),t)},Q.ii=function(){return UN(),C9},Q.ki=function(e){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),RN(this.c);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).$b();return;case 2:!this.b&&(this.b=new DC(this,2)),RN(this.b);return;case 3:!this.c&&(this.c=new DC(this,0)),ON(this.c,(UN(),w9),null);return;case 4:pBe(this,uf(this.a,null));return;case 5:this.a=null;return}PT(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e))},L(TW,`SimpleAnyTypeImpl`,682),q(683,516,{110:1,94:1,93:1,58:1,54:1,99:1,2121:1,683:1},v_e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.a&&(this.a=new DC(this,0)),this.a):(!this.a&&(this.a=new DC(this,0)),this.a.b);case 1:return n?(!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),this.b):(!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),Jy(this.b));case 2:return n?(!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),this.c):(!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),Jy(this.c));case 3:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),E9));case 4:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),D9));case 5:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),O9));case 6:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),k9))}return xb(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e),t,n)},Q.Uh=function(e,t,n){var r;switch(t){case 0:return!this.a&&(this.a=new DC(this,0)),zM(this.a,e,n);case 1:return!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),gf(this.b,e,n);case 2:return!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),gf(this.c,e,n);case 5:return!this.a&&(this.a=new DC(this,0)),NDe(Z_(this.a,(UN(),O9)),e,n)}return r=P(_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():(UN(),T9),t),69),r.wk().Ak(this,Jb(this),t-bh((UN(),T9)),e,n)},Q.Wh=function(e){switch(e){case 0:return!!this.a&&this.a.i!=0;case 1:return!!this.b&&this.b.f!=0;case 2:return!!this.c&&this.c.f!=0;case 3:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),E9)));case 4:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),D9)));case 5:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),O9)));case 6:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),k9)))}return Hv(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e))},Q.bi=function(e,t){switch(e){case 0:!this.a&&(this.a=new DC(this,0)),qm(this.a,t);return;case 1:!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),bC(this.b,t);return;case 2:!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),bC(this.c,t);return;case 3:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),E9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,E9),P(t,16));return;case 4:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),D9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,D9),P(t,16));return;case 5:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),O9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,O9),P(t,16));return;case 6:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),k9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,k9),P(t,16));return}LE(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e),t)},Q.ii=function(){return UN(),T9},Q.ki=function(e){switch(e){case 0:!this.a&&(this.a=new DC(this,0)),RN(this.a);return;case 1:!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),this.b.c.$b();return;case 2:!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),this.c.c.$b();return;case 3:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),E9)));return;case 4:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),D9)));return;case 5:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),O9)));return;case 6:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),k9)));return}PT(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (mixed: `,fl(e,this.a),e.a+=`)`,e.a)},L(TW,`XMLTypeDocumentRootImpl`,683),q(2028,720,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1,2122:1},Qce),Q.ri=function(e,t){switch(e.hk()){case 7:case 8:case 9:case 10:case 16:case 22:case 23:case 24:case 25:case 26:case 32:case 33:case 34:case 36:case 37:case 44:case 45:case 50:case 51:case 53:case 55:case 56:case 57:case 58:case 60:case 61:case 4:return t==null?null:PE(t);case 19:case 28:case 29:case 35:case 38:case 39:case 41:case 46:case 52:case 54:case 5:return kd(t);case 6:return rDe(P(t,195));case 12:case 47:case 49:case 11:return yht(this,e,t);case 13:return t==null?null:Cpt(P(t,247));case 15:case 14:return t==null?null:LPe(D(N(t)));case 17:return p5e((UN(),t));case 18:return p5e(t);case 21:case 20:return t==null?null:RPe(P(t,161).a);case 27:return iDe(P(t,195));case 30:return y3e((UN(),P(t,15)));case 31:return y3e(P(t,15));case 40:return oDe((UN(),t));case 42:return m5e((UN(),t));case 43:return m5e(t);case 59:case 48:return aDe((UN(),t));default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a;switch(e.G==-1&&(e.G=(n=Mx(e),n?NO(n.vi(),e):-1)),e.G){case 0:return t=new g_e,t;case 1:return r=new cle,r;case 2:return i=new __e,i;case 3:return a=new v_e,a;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_;switch(e.hk()){case 5:case 52:case 4:return t;case 6:return J2e(t);case 8:case 7:return t==null?null:D5e(t);case 9:return t==null?null:Gb(GM((r=EN(t,!0),r.length>0&&(sv(0,r.length),r.charCodeAt(0)==43)?(sv(1,r.length+1),r.substr(1)):r),-128,127)<<24>>24);case 10:return t==null?null:Gb(GM((i=EN(t,!0),i.length>0&&(sv(0,i.length),i.charCodeAt(0)==43)?(sv(1,i.length+1),i.substr(1)):i),-128,127)<<24>>24);case 11:return kd(uP(this,(UN(),OHt),t));case 12:return kd(uP(this,(UN(),kHt),t));case 13:return t==null?null:new xye(EN(t,!0));case 15:case 14:return Eat(t);case 16:return kd(uP(this,(UN(),AHt),t));case 17:return V0e((UN(),t));case 18:return V0e(t);case 28:case 29:case 35:case 38:case 39:case 41:case 54:case 19:return EN(t,!0);case 21:case 20:return zat(t);case 22:return kd(uP(this,(UN(),jHt),t));case 23:return kd(uP(this,(UN(),MHt),t));case 24:return kd(uP(this,(UN(),NHt),t));case 25:return kd(uP(this,(UN(),PHt),t));case 26:return kd(uP(this,(UN(),FHt),t));case 27:return A2e(t);case 30:return H0e((UN(),t));case 31:return H0e(t);case 32:return t==null?null:G(GM((u=EN(t,!0),u.length>0&&(sv(0,u.length),u.charCodeAt(0)==43)?(sv(1,u.length+1),u.substr(1)):u),xF,AP));case 33:return t==null?null:new ru((d=EN(t,!0),d.length>0&&(sv(0,d.length),d.charCodeAt(0)==43)?(sv(1,d.length+1),d.substr(1)):d));case 34:return t==null?null:G(GM((f=EN(t,!0),f.length>0&&(sv(0,f.length),f.charCodeAt(0)==43)?(sv(1,f.length+1),f.substr(1)):f),xF,AP));case 36:return t==null?null:JD(aP((p=EN(t,!0),p.length>0&&(sv(0,p.length),p.charCodeAt(0)==43)?(sv(1,p.length+1),p.substr(1)):p)));case 37:return t==null?null:JD(aP((m=EN(t,!0),m.length>0&&(sv(0,m.length),m.charCodeAt(0)==43)?(sv(1,m.length+1),m.substr(1)):m)));case 40:return e3e((UN(),t));case 42:return U0e((UN(),t));case 43:return U0e(t);case 44:return t==null?null:new ru((h=EN(t,!0),h.length>0&&(sv(0,h.length),h.charCodeAt(0)==43)?(sv(1,h.length+1),h.substr(1)):h));case 45:return t==null?null:new ru((g=EN(t,!0),g.length>0&&(sv(0,g.length),g.charCodeAt(0)==43)?(sv(1,g.length+1),g.substr(1)):g));case 46:return EN(t,!1);case 47:return kd(uP(this,(UN(),IHt),t));case 59:case 48:return $4e((UN(),t));case 49:return kd(uP(this,(UN(),LHt),t));case 50:return t==null?null:xT(GM((_=EN(t,!0),_.length>0&&(sv(0,_.length),_.charCodeAt(0)==43)?(sv(1,_.length+1),_.substr(1)):_),aW,32767)<<16>>16);case 51:return t==null?null:xT(GM((a=EN(t,!0),a.length>0&&(sv(0,a.length),a.charCodeAt(0)==43)?(sv(1,a.length+1),a.substr(1)):a),aW,32767)<<16>>16);case 53:return kd(uP(this,(UN(),RHt),t));case 55:return t==null?null:xT(GM((o=EN(t,!0),o.length>0&&(sv(0,o.length),o.charCodeAt(0)==43)?(sv(1,o.length+1),o.substr(1)):o),aW,32767)<<16>>16);case 56:return t==null?null:xT(GM((s=EN(t,!0),s.length>0&&(sv(0,s.length),s.charCodeAt(0)==43)?(sv(1,s.length+1),s.substr(1)):s),aW,32767)<<16>>16);case 57:return t==null?null:JD(aP((c=EN(t,!0),c.length>0&&(sv(0,c.length),c.charCodeAt(0)==43)?(sv(1,c.length+1),c.substr(1)):c)));case 58:return t==null?null:JD(aP((l=EN(t,!0),l.length>0&&(sv(0,l.length),l.charCodeAt(0)==43)?(sv(1,l.length+1),l.substr(1)):l)));case 60:return t==null?null:G(GM((n=EN(t,!0),n.length>0&&(sv(0,n.length),n.charCodeAt(0)==43)?(sv(1,n.length+1),n.substr(1)):n),xF,AP));case 61:return t==null?null:G(GM(EN(t,!0),xF,AP));default:throw E(new Fi(YH+e.xe()+XH))}};var BHt,VHt,HHt,UHt;L(TW,`XMLTypeFactoryImpl`,2028),q(594,184,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1,2044:1,594:1},NFe),Q.N=!1,Q.O=!1;var WHt=!1;L(TW,`XMLTypePackageImpl`,594),q(1961,1,{851:1},$ce),Q.Kk=function(){return Odt(),lUt},L(TW,`XMLTypePackageImpl/1`,1961),q(1970,1,lW,ele),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/10`,1970),q(1971,1,lW,tle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/11`,1971),q(1972,1,lW,nle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/12`,1972),q(1973,1,lW,rle),Q.fk=function(e){return al(e)},Q.gk=function(e){return V(TG,X,345,e,7,1)},L(TW,`XMLTypePackageImpl/13`,1973),q(1974,1,lW,ile),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/14`,1974),q(1975,1,lW,ale),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/15`,1975),q(1976,1,lW,ole),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/16`,1976),q(1977,1,lW,sle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/17`,1977),q(1978,1,lW,lle),Q.fk=function(e){return j(e,161)},Q.gk=function(e){return V(EG,X,161,e,0,1)},L(TW,`XMLTypePackageImpl/18`,1978),q(1979,1,lW,ule),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/19`,1979),q(1962,1,lW,dle),Q.fk=function(e){return j(e,857)},Q.gk=function(e){return V(_9,FP,857,e,0,1)},L(TW,`XMLTypePackageImpl/2`,1962),q(1980,1,lW,fle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/20`,1980),q(1981,1,lW,ple),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/21`,1981),q(1982,1,lW,mle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/22`,1982),q(1983,1,lW,hle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/23`,1983),q(1984,1,lW,gle),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(TW,`XMLTypePackageImpl/24`,1984),q(1985,1,lW,_le),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/25`,1985),q(1986,1,lW,vle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/26`,1986),q(1987,1,lW,yle),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/27`,1987),q(1988,1,lW,ble),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/28`,1988),q(1989,1,lW,xle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/29`,1989),q(1963,1,lW,Sle),Q.fk=function(e){return j(e,681)},Q.gk=function(e){return V(v9,FP,2119,e,0,1)},L(TW,`XMLTypePackageImpl/3`,1963),q(1990,1,lW,Cle),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(TW,`XMLTypePackageImpl/30`,1990),q(1991,1,lW,wle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/31`,1991),q(1992,1,lW,Tle),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(TW,`XMLTypePackageImpl/32`,1992),q(1993,1,lW,Ele),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/33`,1993),q(1994,1,lW,Dle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/34`,1994),q(1995,1,lW,Ole),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/35`,1995),q(1996,1,lW,kle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/36`,1996),q(1997,1,lW,Ale),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/37`,1997),q(1998,1,lW,jle),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/38`,1998),q(1999,1,lW,Mle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/39`,1999),q(1964,1,lW,Nle),Q.fk=function(e){return j(e,682)},Q.gk=function(e){return V(y9,FP,2120,e,0,1)},L(TW,`XMLTypePackageImpl/4`,1964),q(2e3,1,lW,Ple),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/40`,2e3),q(2001,1,lW,Fle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/41`,2001),q(2002,1,lW,Ile),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/42`,2002),q(2003,1,lW,Lle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/43`,2003),q(2004,1,lW,Rle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/44`,2004),q(2005,1,lW,zle),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(TW,`XMLTypePackageImpl/45`,2005),q(2006,1,lW,Ble),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/46`,2006),q(2007,1,lW,Vle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/47`,2007),q(2008,1,lW,Hle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/48`,2008),q(2009,1,lW,Ule),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(TW,`XMLTypePackageImpl/49`,2009),q(1965,1,lW,Wle),Q.fk=function(e){return j(e,683)},Q.gk=function(e){return V(CHt,FP,2121,e,0,1)},L(TW,`XMLTypePackageImpl/5`,1965),q(2010,1,lW,Gle),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(TW,`XMLTypePackageImpl/50`,2010),q(2011,1,lW,Kle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/51`,2011),q(2012,1,lW,qle),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(TW,`XMLTypePackageImpl/52`,2012),q(1966,1,lW,Jle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/6`,1966),q(1967,1,lW,Yle),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(TW,`XMLTypePackageImpl/7`,1967),q(1968,1,lW,Xle),Q.fk=function(e){return il(e)},Q.gk=function(e){return V(bG,X,485,e,8,1)},L(TW,`XMLTypePackageImpl/8`,1968),q(1969,1,lW,Zle),Q.fk=function(e){return j(e,222)},Q.gk=function(e){return V(xG,X,222,e,0,1)},L(TW,`XMLTypePackageImpl/9`,1969);var A9,j9,M9,N9,$;q(55,63,SF,Ui),L(MW,`RegEx/ParseException`,55),q(836,1,{},Qle),Q.bm=function(e){return en*16)throw E(new Ui(TP((fu(),KCt))));n=n*16+i}while(!0);if(this.a!=125)throw E(new Ui(TP((fu(),qCt))));if(n>NW)throw E(new Ui(TP((fu(),JCt))));e=n}else{if(i=0,this.c!=0||(i=rk(this.a))<0||(n=i,hP(this),this.c!=0||(i=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));n=n*16+i,e=n}break;case 117:if(r=0,hP(this),this.c!=0||(r=rk(this.a))<0||(t=r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));t=t*16+r,e=t;break;case 118:if(hP(this),this.c!=0||(r=rk(this.a))<0||(t=r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));if(t=t*16+r,t>NW)throw E(new Ui(TP((fu(),`parser.descappe.4`))));e=t;break;case 65:case 90:case 122:throw E(new Ui(TP((fu(),YCt))))}return e},Q.dm=function(e){var t,n;switch(e){case 100:n=(this.e&32)==32?oP(`Nd`,!0):(xP(),z9);break;case 68:n=(this.e&32)==32?oP(`Nd`,!1):(xP(),QHt);break;case 119:n=(this.e&32)==32?oP(`IsWord`,!0):(xP(),U9);break;case 87:n=(this.e&32)==32?oP(`IsWord`,!1):(xP(),eUt);break;case 115:n=(this.e&32)==32?oP(`IsSpace`,!0):(xP(),H9);break;case 83:n=(this.e&32)==32?oP(`IsSpace`,!1):(xP(),$Ht);break;default:throw E(new yi((t=e,uTt+t.toString(16))))}return n},Q.em=function(e){var t,n,r,i,a,o,s,c,l,u,d,f;for(this.b=1,hP(this),t=null,this.c==0&&this.a==94?(hP(this),e?u=(xP(),xP(),++W9,new pv(5)):(t=(xP(),xP(),++W9,new pv(4)),oM(t,0,NW),u=(++W9,new pv(4)))):u=(xP(),xP(),++W9,new pv(4)),i=!0;(f=this.c)!=1&&!(f==0&&this.a==93&&!i);){if(i=!1,n=this.a,r=!1,f==10)switch(n){case 100:case 68:case 119:case 87:case 115:case 83:DN(u,this.dm(n)),r=!0;break;case 105:case 73:case 99:case 67:n=this.um(u,n),n<0&&(r=!0);break;case 112:case 80:if(d=Ont(this,n),!d)throw E(new Ui(TP((fu(),OU))));DN(u,d),r=!0;break;default:n=this.cm()}else if(f==20){if(o=fd(this.i,58,this.d),o<0)throw E(new Ui(TP((fu(),RCt))));if(s=!0,mg(this.i,this.d)==94&&(++this.d,s=!1),a=p_(this.i,this.d,o),c=dGe(a,s,(this.e&512)==512),!c)throw E(new Ui(TP((fu(),zCt))));if(DN(u,c),r=!0,o+1>=this.j||mg(this.i,o+1)!=93)throw E(new Ui(TP((fu(),RCt))));this.d=o+2}if(hP(this),!r){if(this.c!=0||this.a!=45)oM(u,n,n);else{if(hP(this),(f=this.c)==1)throw E(new Ui(TP((fu(),kU))));f==0&&this.a==93?(oM(u,n,n),oM(u,45,45)):(l=this.a,f==10&&(l=this.cm()),hP(this),oM(u,n,l))}}(this.e&pF)==pF&&this.c==0&&this.a==44&&hP(this)}if(this.c==1)throw E(new Ui(TP((fu(),kU))));return t&&(KN(t,u),u=t),kj(u),FN(u),this.b=0,hP(this),u},Q.fm=function(){for(var e,t,n=this.em(!1),r;(r=this.c)!=7;)if(e=this.a,r==0&&(e==45||e==38)||r==4){if(hP(this),this.c!=9)throw E(new Ui(TP((fu(),UCt))));if(t=this.em(!1),r==4)DN(n,t);else if(e==45)KN(n,t);else if(e==38)iht(n,t);else throw E(new yi(`ASSERT`))}else throw E(new Ui(TP((fu(),WCt))));return hP(this),n},Q.gm=function(){var e=this.a-48,t=(xP(),xP(),++W9,new __(12,null,e));return!this.g&&(this.g=new Yr),Gr(this.g,new Xhe(e)),hP(this),t},Q.hm=function(){return hP(this),xP(),nUt},Q.im=function(){return hP(this),xP(),tUt},Q.jm=function(){throw E(new Ui(TP((fu(),MU))))},Q.km=function(){throw E(new Ui(TP((fu(),MU))))},Q.lm=function(){return hP(this),eQe()},Q.mm=function(){return hP(this),xP(),iUt},Q.nm=function(){return hP(this),xP(),oUt},Q.om=function(){var e;if(this.d>=this.j||((e=mg(this.i,this.d++))&65504)!=64)throw E(new Ui(TP((fu(),PCt))));return hP(this),xP(),xP(),++W9,new zp(0,e-64)},Q.pm=function(){return hP(this),Qdt()},Q.qm=function(){return hP(this),xP(),sUt},Q.rm=function(){var e=(xP(),xP(),++W9,new zp(0,105));return hP(this),e},Q.sm=function(){return hP(this),xP(),aUt},Q.tm=function(){return hP(this),xP(),rUt},Q.um=function(e,t){return this.cm()},Q.vm=function(){return hP(this),xP(),XHt},Q.wm=function(){var e,t,n,r,i;if(this.d+1>=this.j)throw E(new Ui(TP((fu(),jCt))));if(r=-1,t=null,e=mg(this.i,this.d),49<=e&&e<=57){if(r=e-48,!this.g&&(this.g=new Yr),Gr(this.g,new Xhe(r)),++this.d,mg(this.i,this.d)!=41)throw E(new Ui(TP((fu(),DU))));++this.d}else switch(e==63&&--this.d,hP(this),t=Q_t(this),t.e){case 20:case 21:case 22:case 23:break;case 8:if(this.c!=7)throw E(new Ui(TP((fu(),DU))));break;default:throw E(new Ui(TP((fu(),MCt))))}if(hP(this),i=zD(this),n=null,i.e==2){if(i.Pm()!=2)throw E(new Ui(TP((fu(),NCt))));n=i.Lm(1),i=i.Lm(0)}if(this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),xP(),xP(),++W9,new hKe(r,t,i,n)},Q.xm=function(){return hP(this),xP(),ZHt},Q.ym=function(){var e;if(hP(this),e=Em(24,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.zm=function(){var e;if(hP(this),e=Em(20,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Am=function(){var e;if(hP(this),e=Em(22,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Bm=function(){var e=0,t,n=0,r,i;for(t=-1;this.d=this.j)throw E(new Ui(TP((fu(),kCt))));if(t==45){for(++this.d;this.d=this.j)throw E(new Ui(TP((fu(),kCt))))}if(t==58){if(++this.d,hP(this),r=YPe(zD(this),e,n),this.c!=7)throw E(new Ui(TP((fu(),DU))));hP(this)}else if(t==41)++this.d,hP(this),r=YPe(zD(this),e,n);else throw E(new Ui(TP((fu(),ACt))));return r},Q.Cm=function(){var e;if(hP(this),e=Em(21,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Dm=function(){var e;if(hP(this),e=Em(23,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Em=function(){var e,t;if(hP(this),e=this.f++,t=Dm(zD(this),e),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),t},Q.Fm=function(){var e;if(hP(this),e=Dm(zD(this),0),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Gm=function(e){return hP(this),this.c==5?(hP(this),Rp(e,(xP(),xP(),++W9,new Zv(9,e)))):Rp(e,(xP(),xP(),++W9,new Zv(3,e)))},Q.Hm=function(e){var t;return hP(this),t=(xP(),xP(),++W9,new lu(2)),this.c==5?(hP(this),LN(t,B9),LN(t,e)):(LN(t,e),LN(t,B9)),t},Q.Im=function(e){return hP(this),this.c==5?(hP(this),xP(),xP(),++W9,new Zv(9,e)):(xP(),xP(),++W9,new Zv(3,e))},Q.a=0,Q.b=0,Q.c=0,Q.d=0,Q.e=0,Q.f=1,Q.g=null,Q.j=0,L(MW,`RegEx/RegexParser`,836),q(1947,836,{},y_e),Q.bm=function(e){return!1},Q.cm=function(){return Tct(this)},Q.dm=function(e){return KM(e)},Q.em=function(e){return _vt(this)},Q.fm=function(){throw E(new Ui(TP((fu(),MU))))},Q.gm=function(){throw E(new Ui(TP((fu(),MU))))},Q.hm=function(){throw E(new Ui(TP((fu(),MU))))},Q.im=function(){throw E(new Ui(TP((fu(),MU))))},Q.jm=function(){return hP(this),KM(67)},Q.km=function(){return hP(this),KM(73)},Q.lm=function(){throw E(new Ui(TP((fu(),MU))))},Q.mm=function(){throw E(new Ui(TP((fu(),MU))))},Q.nm=function(){throw E(new Ui(TP((fu(),MU))))},Q.om=function(){return hP(this),KM(99)},Q.pm=function(){throw E(new Ui(TP((fu(),MU))))},Q.qm=function(){throw E(new Ui(TP((fu(),MU))))},Q.rm=function(){return hP(this),KM(105)},Q.sm=function(){throw E(new Ui(TP((fu(),MU))))},Q.tm=function(){throw E(new Ui(TP((fu(),MU))))},Q.um=function(e,t){return DN(e,KM(t)),-1},Q.vm=function(){return hP(this),xP(),xP(),++W9,new zp(0,94)},Q.wm=function(){throw E(new Ui(TP((fu(),MU))))},Q.xm=function(){return hP(this),xP(),xP(),++W9,new zp(0,36)},Q.ym=function(){throw E(new Ui(TP((fu(),MU))))},Q.zm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Am=function(){throw E(new Ui(TP((fu(),MU))))},Q.Bm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Cm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Dm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Em=function(){var e;if(hP(this),e=Dm(zD(this),0),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Fm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Gm=function(e){return hP(this),Rp(e,(xP(),xP(),++W9,new Zv(3,e)))},Q.Hm=function(e){var t;return hP(this),t=(xP(),xP(),++W9,new lu(2)),LN(t,e),LN(t,B9),t},Q.Im=function(e){return hP(this),xP(),xP(),++W9,new Zv(3,e)};var P9=null,F9=null;L(MW,`RegEx/ParserForXMLSchema`,1947),q(122,1,VW,Tr),Q.Jm=function(e){throw E(new yi(`Not supported.`))},Q.Km=function(){return-1},Q.Lm=function(e){return null},Q.Mm=function(){return null},Q.Nm=function(e){},Q.Om=function(e){},Q.Pm=function(){return 0},Q.Ib=function(){return this.Qm(0)},Q.Qm=function(e){return this.e==11?`.`:``},Q.e=0;var GHt,I9,L9,KHt,qHt,R9=null,z9,JHt=null,YHt,B9,V9=null,XHt,ZHt,QHt,$Ht,eUt,tUt,H9,nUt,rUt,iUt,aUt,U9,oUt,sUt,W9=0,cUt=L(MW,`RegEx/Token`,122);q(138,122,{3:1,138:1,122:1},pv),Q.Qm=function(e){var t,n,r;if(this.e==4){if(this==YHt)n=`.`;else if(this==z9)n=`\\d`;else if(this==U9)n=`\\w`;else if(this==H9)n=`\\s`;else{for(r=new $i,r.a+=`[`,t=0;t0&&(r.a+=`,`),this.b[t]===this.b[t+1]?pl(r,uN(this.b[t])):(pl(r,uN(this.b[t])),r.a+=`-`,pl(r,uN(this.b[t+1])));r.a+=`]`,n=r.a}}else if(this==QHt)n=`\\D`;else if(this==eUt)n=`\\W`;else if(this==$Ht)n=`\\S`;else{for(r=new $i,r.a+=`[^`,t=0;t0&&(r.a+=`,`),this.b[t]===this.b[t+1]?pl(r,uN(this.b[t])):(pl(r,uN(this.b[t])),r.a+=`-`,pl(r,uN(this.b[t+1])));r.a+=`]`,n=r.a}return n},Q.a=!1,Q.c=!1,L(MW,`RegEx/RangeToken`,138),q(592,1,{592:1},Xhe),Q.a=0,L(MW,`RegEx/RegexParser/ReferencePosition`,592),q(591,1,{3:1,591:1},Rye),Q.Fb=function(e){var t;return e==null||!j(e,591)?!1:(t=P(e,591),ff(this.b,t.b)&&this.a==t.a)},Q.Hb=function(){return jw(this.b+`/`+Xot(this.a))},Q.Ib=function(){return this.c.Qm(this.a)},Q.a=0,L(MW,`RegEx/RegularExpression`,591),q(228,122,VW,zp),Q.Km=function(){return this.a},Q.Qm=function(e){var t,n,r;switch(this.e){case 0:switch(this.a){case 124:case 42:case 43:case 63:case 40:case 41:case 46:case 91:case 123:case 92:r=`\\`+Xd(this.a&OF);break;case 12:r=`\\f`;break;case 10:r=`\\n`;break;case 13:r=`\\r`;break;case 9:r=`\\t`;break;case 27:r=`\\e`;break;default:this.a>=pI?(n=(t=this.a>>>0,`0`+t.toString(16)),r=`\\v`+p_(n,n.length-6,n.length)):r=``+Xd(this.a&OF)}break;case 8:r=this==XHt||this==ZHt?``+Xd(this.a&OF):`\\`+Xd(this.a&OF);break;default:r=null}return r},Q.a=0,L(MW,`RegEx/Token/CharToken`,228),q(318,122,VW,Zv),Q.Lm=function(e){return this.a},Q.Nm=function(e){this.b=e},Q.Om=function(e){this.c=e},Q.Pm=function(){return 1},Q.Qm=function(e){var t;if(this.e==3){if(this.c<0&&this.b<0)t=this.a.Qm(e)+`*`;else if(this.c==this.b)t=this.a.Qm(e)+`{`+this.c+`}`;else if(this.c>=0&&this.b>=0)t=this.a.Qm(e)+`{`+this.c+`,`+this.b+`}`;else if(this.c>=0&&this.b<0)t=this.a.Qm(e)+`{`+this.c+`,}`;else throw E(new yi(`Token#toString(): CLOSURE `+this.c+PP+this.b))}else if(this.c<0&&this.b<0)t=this.a.Qm(e)+`*?`;else if(this.c==this.b)t=this.a.Qm(e)+`{`+this.c+`}?`;else if(this.c>=0&&this.b>=0)t=this.a.Qm(e)+`{`+this.c+`,`+this.b+`}?`;else if(this.c>=0&&this.b<0)t=this.a.Qm(e)+`{`+this.c+`,}?`;else throw E(new yi(`Token#toString(): NONGREEDYCLOSURE `+this.c+PP+this.b));return t},Q.b=0,Q.c=0,L(MW,`RegEx/Token/ClosureToken`,318),q(837,122,VW,Km),Q.Lm=function(e){return e==0?this.a:this.b},Q.Pm=function(){return 2},Q.Qm=function(e){return this.b.e==3&&this.b.Lm(0)==this.a?this.a.Qm(e)+`+`:this.b.e==9&&this.b.Lm(0)==this.a?this.a.Qm(e)+`+?`:this.a.Qm(e)+(``+this.b.Qm(e))},L(MW,`RegEx/Token/ConcatToken`,837),q(1945,122,VW,hKe),Q.Lm=function(e){if(e==0)return this.d;if(e==1)return this.b;throw E(new yi(`Internal Error: `+e))},Q.Pm=function(){return this.b?2:1},Q.Qm=function(e){var t=this.c>0?`(?(`+this.c+`)`:this.a.e==8?`(?(`+this.a+`)`:`(?`+this.a;return this.b?t+=this.d+`|`+this.b+`)`:t+=this.d+`)`,t},Q.c=0,L(MW,`RegEx/Token/ConditionToken`,1945),q(1946,122,VW,Lze),Q.Lm=function(e){return this.b},Q.Pm=function(){return 1},Q.Qm=function(e){return`(?`+(this.a==0?``:Xot(this.a))+(this.c==0?``:Xot(this.c))+`:`+this.b.Qm(e)+`)`},Q.a=0,Q.c=0,L(MW,`RegEx/Token/ModifierToken`,1946),q(838,122,VW,Nh),Q.Lm=function(e){return this.a},Q.Pm=function(){return 1},Q.Qm=function(e){var t=null;switch(this.e){case 6:t=this.b==0?`(?:`+this.a.Qm(e)+`)`:`(`+this.a.Qm(e)+`)`;break;case 20:t=`(?=`+this.a.Qm(e)+`)`;break;case 21:t=`(?!`+this.a.Qm(e)+`)`;break;case 22:t=`(?<=`+this.a.Qm(e)+`)`;break;case 23:t=`(?`+this.a.Qm(e)+`)`}return t},Q.b=0,L(MW,`RegEx/Token/ParenToken`,838),q(530,122,{3:1,122:1,530:1},__),Q.Mm=function(){return this.b},Q.Qm=function(e){return this.e==12?`\\`+this.a:oat(this.b)},Q.a=0,L(MW,`RegEx/Token/StringToken`,530),q(477,122,VW,lu),Q.Jm=function(e){LN(this,e)},Q.Lm=function(e){return P(Rh(this.a,e),122)},Q.Pm=function(){return this.a?this.a.a.c.length:0},Q.Qm=function(e){var t,n,r,i,a;if(this.e==1){if(this.a.a.c.length==2)t=P(Rh(this.a,0),122),n=P(Rh(this.a,1),122),i=n.e==3&&n.Lm(0)==t?t.Qm(e)+`+`:n.e==9&&n.Lm(0)==t?t.Qm(e)+`+?`:t.Qm(e)+(``+n.Qm(e));else{for(a=new $i,r=0;r=this.c.b:this.a<=this.c.b},Q.Sb=function(){return this.b>0},Q.Tb=function(){return this.b},Q.Vb=function(){return this.b-1},Q.Qb=function(){throw E(new Ri(yTt))},Q.a=0,Q.b=0,L(gTt,`ExclusiveRange/RangeIterator`,258);var K9=Jh(VU,`C`),q9=Jh(WU,`I`),J9=Jh(DP,`Z`),Y9=Jh(GU,`J`),X9=Jh(BU,`B`),Z9=Jh(HU,`D`),Q9=Jh(UU,`F`),$9=Jh(KU,`S`),uUt=gp(`org.eclipse.elk.core.labels`,`ILabelManager`),dUt=gp(uU,`DiagnosticChain`),fUt=gp(Lwt,`ResourceSet`),pUt=L(uU,`InvocationTargetException`,null),mUt=(Qi(),mUe),hUt=hUt=e5e;SJe(sge),uJe(`permProps`,[[[`locale`,`default`],[bTt,`gecko1_8`]],[[`locale`,`default`],[bTt,`safari`]]]),hUt(null,`elk`,null)}).call(this)}).call(this,typeof global<`u`?global:typeof self<`u`?self:typeof window<`u`?window:{})},{}],3:[function(e,t,n){function r(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function i(e,t){if(!e)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return t&&(typeof t==`object`||typeof t==`function`)?t:e}function a(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function, not `+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var o=function(t){a(n,t);function n(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};r(this,n);var a=Object.assign({},t),o=!1;try{e.resolve(`web-worker`),o=!0}catch{}if(t.workerUrl){if(o){var s=e("web-worker");a.workerFactory=function(e){return new s(e)}}else console.warn(`Web worker requested but 'web-worker' package not installed. +Consider installing the package or pass your own 'workerFactory' to ELK's constructor. +... Falling back to non-web worker version.`)}if(!a.workerFactory){var c=e("./elk-worker.min.js").Worker;a.workerFactory=function(e){return new c(e)}}return i(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,a))}return n}(e("./elk-api.js").default);Object.defineProperty(t.exports,"__esModule",{value:!0}),t.exports=o,o.default=o},{"./elk-api.js":1,"./elk-worker.min.js":2,"web-worker":4}],4:[function(e,t,n){t.exports=Worker},{}]},{},[3])(3)})}))(),1),p=r((e,t,{parentById:n})=>{let r=new Set,i=e;if(e===t)return n[e]||`root`;for(;i;){if(r.add(i),i===t)return i;i=n[i]}for(i=t;i;){if(r.has(i))return i;i=n[i]}return`root`},`findCommonAncestor`),m=6;function h(e,{measure:t}){let n=e.config?.elk?.lineHops;if(n===!1)return;let r=e.edges.filter(e=>Array.isArray(e.points)&&e.points.length>=2).map(e=>({id:e.id,points:e.points,curve:e.curve,arrowTypeStart:e.arrowTypeStart,arrowTypeEnd:e.arrowTypeEnd}));d(t.groups.edgePaths,r,{enabled:!0,jumpRadius:m,jumpStyle:n===`gap`?`gap`:`arc`})}r(h,`applyElkLineJumps`);var g={},_={},v={},y={},b=1,x=10,S=r((e,t,n=.5)=>{let r=e.width/2,i=e.height/2,a=e.x-r,o=e.x+r,s=e.y-i,c=e.y+i,l=Math.abs(t.x-a)<=n&&t.y>=s-n&&t.y<=c+n,u=Math.abs(t.x-o)<=n&&t.y>=s-n&&t.y<=c+n,d=Math.abs(t.y-s)<=n&&t.x>=a-n&&t.x<=o+n,f=Math.abs(t.y-c)<=n&&t.x>=a-n&&t.x<=o+n;return l||u||d||f},`onBorder`),ee=r((e,t,n)=>{let r=e.x,i=e.y,a=Math.abs(r-n.x),o=e.width/2,s=n.xMath.abs(r-t.x)*c){let e=n.y{let n=e.x,r=e.y,i=Math.abs(t.x-n),a=Math.abs(t.y-r),o=e.width/2,s=e.height/2;return i>=o||a>=s},`outsideNode`),ne=r((e,t,n=x)=>{let r=Math.abs(t.x-e.x),i=Math.abs(t.y-e.y),a=e.width/2,o=e.height/2;if(Math.abs(r-a)0)return{x:e.x+r/a*(a+n),y:e.y+i/a*(a+n)}}return t},`ensureTrulyOutside`),C=r((e,t,n)=>{let r=Math.abs(t.x-e.x){if(!e?.intersect)return null;let r=e.intersect(n);return!r||n.xt.x||n.x>t.x&&r.xee(e,t,C(e,t,n)),`fallbackIntersection`),ae=20,oe=1e-6,se=r((e,t,n)=>{let r=e.intersect?.(n);return r?Math.hypot(n.x-t.x,n.y-t.y)<=Math.hypot(r.x-t.x,r.y-t.y)+1e-9:!1},`insideOutline`),ce=r((e,t,n,i)=>{if(!e?.intersect)return null;let a=i.x-n.x,o=i.y-n.y;if(a===0&&o===0||Math.abs(a)>oe&&Math.abs(o)>oe)return null;let s={x:t.x,y:t.y},c=Math.abs(a)>Math.abs(o),l=r(e=>c?{x:e,y:n.y}:{x:n.x,y:e},`along`),u=c?s.x:s.y,d=c?n.x:n.y;if(!se(e,s,l(u)))return null;if(se(e,s,l(d)))return{...n};for(let t=0;t{let i=ne(t,n);return re(e,t,i)??ie(t,i,r)},`computeNodeIntersection`),ue=r((e,t,n,r=.1)=>{if(!(!n||e.length===0)){if(t===`start`)e.length>0&&Math.abs(e[0].x-n.x)0&&Math.abs(e[t].x-n.x)typeof e==`string`?Math.max(o[e]??0,s[e]??0):0,`markerPathOffset`),pe={arrow_open:[`none`,`none`],arrow_cross:[`none`,`arrow_cross`],double_arrow_cross:[`arrow_cross`,`arrow_cross`],arrow_point:[`none`,`arrow_point`],double_arrow_point:[`arrow_point`,`arrow_point`],arrow_circle:[`none`,`arrow_circle`],double_arrow_circle:[`arrow_circle`,`arrow_circle`]},me=12,he=`[top=${me},left=${me},bottom=${me},right=${me}]`,ge=24,_e=24,ve=50,ye=15,be=10,xe={"spacing.baseValue":15,"spacing.nodeNode":15,"elk.aspectRatio":`1.6`,"elk.expandNodes":`true`,"elk.rectpacking.trybox":`true`,"elk.rectpacking.packing.compaction.rowHeightReevaluation":`true`,"elk.rectpacking.packing.compaction.iterations":10,"elk.rectpacking.whiteSpaceElimination.strategy":`EQUAL_BETWEEN_STRUCTURES`,"elk.rectpacking.widthApproximation.strategy":`SCANLINE`},Se=[`nodeSize.constraints`,`nodeSize.minimum`,`elk.algorithm`,`elk.aspectRatio`,`elk.contentAlignment`,`elk.expandNodes`,`elk.padding`,...Object.keys(xe)];function Ce(e){for(let t of Se)delete e[t];e[`spacing.baseValue`]=_e,e[`spacing.nodeNode`]=ve}r(Ce,`clearContainerAlgorithmOptions`);var we=new Set([`elk.layered`,`elk.box`,`elk.rectpacking`,`elk.stress`,`elk.force`,`elk.mrtree`,`elk.radial`,`elk.sporeOverlap`]);function Te(e,t){if(typeof e==`string`){if(!we.has(e)){t?.warn(`Unknown container layout algorithm "${e}". Supported values: ${[...we].join(`, `)}. Falling back to the diagram's layout algorithm.`);return}return e}}r(Te,`resolveContainerAlgorithm`);function Ee(e){switch(e){case`LR`:return`RIGHT`;case`RL`:return`LEFT`;case`TB`:case`TD`:return`DOWN`;case`BT`:return`UP`;default:return`DOWN`}}r(Ee,`dir2ElkDirection`);function De(e){return c(e.shape)?(e.labelData?.width??e.labels?.[0]?.width??0)+(e.padding??0):0}r(De,`groupTitleWidth`);function Oe(e){return c(e.shape)?{"nodeSize.constraints":`[MINIMUM_SIZE, NODE_LABELS]`,"nodeSize.minimum":`(${De(e)}, 0)`}:{}}r(Oe,`groupTitleSizeOptions`);function ke(e,t,n,r){let i=(e.labelData?.width??0)+2*(e.padding??0),a=e.labelData?.height??0,o=Ve(t?.preset),s={...Oe(e),"spacing.baseValue":_e,"elk.layered.spacing.edgeNodeBetweenLayers":30,"elk.spacing.edgeEdge":20,"spacing.nodeNode":ve,"elk.padding":`[top=${ge},left=${ge},bottom=${ge},right=${ge}]`,"nodeLabels.placement":`[H_CENTER V_TOP, INSIDE]`,"elk.layered.mergeEdges":t?.mergeEdges,"elk.layered.nodePlacement.bk.fixedAlignment":t?.nodePlacementAlignment??o.alignment,"elk.layered.nodePlacement.strategy":t?.nodePlacementStrategy??o.containerPlacement,"elk.layered.cycleBreaking.strategy":t?.cycleBreakingStrategy??o.cycleBreaking,"elk.layered.nodePlacement.networkSimplex.nodeFlexibility":`PORT_POSITION`,"elk.spacing.portsSurrounding":he},c=Te(e.metadata?.algorithm,r);if(c){let e=a+ye;if(s[`nodeSize.constraints`]=`[MINIMUM_SIZE, NODE_LABELS]`,s[`nodeSize.minimum`]=`(${i}, ${e+ye})`,s[`elk.algorithm`]=c,s[`elk.hierarchyHandling`]=`SEPARATE_CHILDREN`,s[`elk.aspectRatio`]=`2.0`,s[`elk.contentAlignment`]=`H_CENTER V_TOP`,s[`elk.expandNodes`]=`true`,s[`elk.padding`]=`[top=${e},left=${ye},bottom=${ye},right=${ye}]`,c===`elk.rectpacking`){let e=a+be;Object.assign(s,xe,{"elk.padding":`[top=${e},left=${be},bottom=${be},right=${be}]`,"nodeSize.minimum":`(${i}, ${e+be})`})}}else e.dir&&(s[`elk.algorithm`]=n,s[`elk.direction`]=Ee(e.dir),s[`elk.hierarchyHandling`]=`SEPARATE_CHILDREN`);return Object.assign(s,y),s}r(ke,`buildSubgraphLayoutOptions`);function Ae(e,t){let n=new Set,i=new Map;for(let{id:t,parentId:n}of e){let e=i.get(n);e?e.push(t):i.set(n,[t])}for(let e of i.values()){let i=new Set(e),a=new Map(e.map(e=>[e,0])),o=new Map(e.map(e=>[e,[]])),s=[];for(let e of t){let t=e.source==null?void 0:String(e.source),n=e.target==null?void 0:String(e.target);!t||!n||t===n||!i.has(t)||!i.has(n)||(a.set(n,(a.get(n)??0)+1),o.get(t).push(n),o.get(n).push(t),s.push([t,n]))}let c=new Map,l=0;for(let t of e){if(c.has(t))continue;let e=[t];for(c.set(t,l);e.length>0;){let t=e.pop();for(let n of o.get(t))c.has(n)||(c.set(n,l),e.push(n))}l++}let u=Array(l).fill(!1);for(let t of e)(a.get(t)??0)===0&&(u[c.get(t)]=!0);if(!u.includes(!1))continue;let d=new Map(e.map(e=>[e,[]])),f=new Map(e.map(e=>[e,0])),p=r((e,t)=>{let n=new Set([e]),r=[e];for(;r.length>0;){let e=r.pop();if(e===t)return!0;for(let t of d.get(e))n.has(t)||(n.add(t),r.push(t))}return!1},`reaches`);for(let[e,t]of s)p(t,e)||(d.get(e).push(t),f.set(t,(f.get(t)??0)+1));let m=Array(l).fill(!1);for(let t of e){let e=c.get(t);!u[e]&&!m[e]&&f.get(t)===0&&(n.add(t),m[e]=!0)}}return n}r(Ae,`findCyclicEntryNodes`);function je(e,t){if(!e.config.elk?.keepEntryNodeOnTop)return;let n=Ae(e.nodes,e.edges.map(e=>({source:e.start,target:e.end})));for(let e of n){let n=t[e];n&&(n.layoutOptions={...n.layoutOptions,"elk.layered.layering.layerConstraint":`FIRST`})}}r(je,`applyCyclicEntryConstraint`);function Me(e,t){let n=ze(t);return Ie(n),Tt(e,n),{algorithm:n.algorithm}}r(Me,`prepareLayoutForElk`);async function Ne(e,t){let n=ze(t),r=Pe(e,n),i=new f.default;n.log.info(`Drawing flowchart using v4 renderer`,i);let a=await $e(i,r.elkGraph,n.log);return et(e,a,r,n.log),Le(e.nodes),a}r(Ne,`runElkLayoutCore`);function Pe(e,t){let n={},r=He(e,t.algorithm,t.rootLayoutOptions),i=e.direction??`DOWN`;r.layoutOptions[`elk.direction`]=Ee(i);let a=Ue(e.nodes,t.log);return We(e.nodes,r,n,t),Je(e,r,n,t),Xe(e,n,a,t),Ze(r,n,a,t.log),je(e,n),{elkGraph:r,nodeDb:n,parentLookupDb:a}}r(Pe,`buildElkGraphFromLayoutData`);var Fe=u({afterPaint:h,prepareLayout:Me,measureLayout:r((e,t)=>l(e,t,{unwrapGroupLabels:!0}),`measureLayout`),runLayoutCore:Ne,paintOptions:{skipIntersect:!0}});function Ie(e){i(e.getConfig())}r(Ie,`syncHostConfig`);function Le(e){let t=new Map(e.map(e=>[e.id,e]));e.sort((e,n)=>e.isGroup===n.isGroup?e.isGroup&&n.isGroup?Re(e,t)-Re(n,t):0:e.isGroup?-1:1)}r(Le,`orderNodesForElkPaint`);function Re(e,t){let n=0,r=new Set,i=e.parentId;for(;i&&!r.has(i);){r.add(i);let e=t.get(i);if(!e?.isGroup)break;n++,i=e.parentId}return n}r(Re,`getGroupDepth`);function ze(e){let t=e.helpers;if(!t)throw Error(`ELK layout requires Mermaid internal helpers`);return{algorithm:e.preparedLayout?.algorithm??e.options?.algorithm,rootLayoutOptions:e.options?.rootLayoutOptions,common:t.common,getConfig:t.getConfig,interpolateToCurve:t.interpolateToCurve,log:t.log}}r(ze,`getElkLayoutContext`);var Be={default:{layering:`NETWORK_SIMPLEX`,placement:`BRANDES_KOEPF`,containerPlacement:`BRANDES_KOEPF`,alignment:`BALANCED`,cycleBreaking:`DEPTH_FIRST`},legacy:{layering:`NETWORK_SIMPLEX`,placement:`BRANDES_KOEPF`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`GREEDY`},modelOrder:{layering:`NETWORK_SIMPLEX`,placement:`NETWORK_SIMPLEX`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`GREEDY_MODEL_ORDER`},depthFirst:{layering:`NETWORK_SIMPLEX`,placement:`NETWORK_SIMPLEX`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`DEPTH_FIRST`}};function Ve(e){return e!==void 0&&Object.hasOwn(Be,e)?Be[e]:Be.default}r(Ve,`resolveElkPreset`);function He(e,t,n){let r=Ve(e.config.elk?.preset),i={id:`root`,layoutOptions:{"elk.hierarchyHandling":`INCLUDE_CHILDREN`,"elk.algorithm":t,"elk.layered.nodePlacement.strategy":e.config.elk?.nodePlacementStrategy??r.placement,"elk.layered.nodePlacement.bk.fixedAlignment":e.config.elk?.nodePlacementAlignment??r.alignment,"elk.layered.mergeEdges":e.config.elk?.mergeEdges,"elk.direction":`DOWN`,"spacing.baseValue":40,"elk.layered.crossingMinimization.forceNodeModelOrder":e.config.elk?.forceNodeModelOrder,"elk.layered.considerModelOrder.strategy":e.config.elk?.considerModelOrder,"elk.layered.unnecessaryBendpoints":!0,"elk.layered.cycleBreaking.strategy":e.config.elk?.cycleBreakingStrategy??r.cycleBreaking,"elk.layered.layering.strategy":e.config.elk?.layeringStrategy??r.layering,"elk.layered.layering.coffmanGraham.layerBound":e.config.elk?.layeringLayerBound,"elk.layered.wrapping.multiEdge.improveCuts":!0,"elk.layered.wrapping.multiEdge.improveWrappedEdges":!0,"elk.layered.edgeRouting.selfLoopDistribution":`EQUALLY`,"elk.layered.mergeHierarchyEdges":!0,"elk.spacing.portsSurrounding":he},children:[],edges:[]};return t===`elk.rectpacking`&&Object.assign(i.layoutOptions,xe,{"elk.contentAlignment":`H_CENTER V_TOP`,"elk.padding":`[top=15,left=15,bottom=15,right=15]`}),n&&Object.assign(i.layoutOptions,n),Object.assign(i.layoutOptions,g,_,v),i}r(He,`createRootElkGraph`);function Ue(e,t){let n={parentById:{},childrenById:{}},r=e.filter(e=>e.isGroup);return t.info(`Subgraphs - `,r),r.forEach(t=>{e.filter(e=>e.parentId===t.id).forEach(e=>{n.parentById[e.id]=t.id,n.childrenById[t.id]??=[],n.childrenById[t.id].push(e.id)})}),n}r(Ue,`addSubGraphs`);function We(e,t,n,r,i){let a=e.filter(e=>e?.parentId===i);return r.log.info(`addVertices APA12`,a,i),a.forEach(i=>{Ge(t,e,i,n,r)}),t}r(We,`addVertices`);function Ge(e,t,n,r,i){let a=Ke(n);e.children.push(a),r[n.id]=a,n.isGroup&&(a.children=[],We(t,a,r,i,n.id),a.labelData=qe(n,i.getConfig()))}r(Ge,`addVertex`);function Ke(e){let t={...e};return delete t.domId,e.isGroup?t.children=[]:(t.width=e.width??0,t.height=e.height??0,e.spreadPorts&&(t.layoutOptions={...t.layoutOptions,"elk.portAlignment.default":`CENTER`})),t}r(Ke,`createElkNode`);function qe(e,t){return e.labelData||(e.labelBBox?{width:e.labelBBox.width,height:Math.max(0,e.labelBBox.height-2),wrappingWidth:e.wrappingWidth??t.flowchart?.wrappingWidth}:{width:0,height:0,wrappingWidth:e.wrappingWidth??t.flowchart?.wrappingWidth})}r(qe,`getMeasuredLabelData`);function Je(e,t,n,r){r.log.info(`abc78 DAGA edges = `,e);let i={};return e.edges.forEach(e=>{let a=e.id;i[a]=(i[a]??-1)+1;let o=a;e.id=o,r.log.info(`abc78 new link id to be used is`,a,o,i[a]);let{source:s,target:c,sourceId:l,targetId:u}=Ye(e,n);r.log.debug(`abc78 source and target`,s,c),t.edges.push({...e,sources:[s],targets:[c],sourceId:l,targetId:u,labels:[{width:e.width??0,height:e.height??0,orgWidth:e.width??0,orgHeight:e.height??0,text:e.label??``,layoutOptions:{"edgeLabels.inline":`true`,"edgeLabels.placement":`CENTER`}}]})}),t}r(Je,`addEdgesToElkGraph`);function Ye(e,t){let n=e.start,r=e.end,i=n,a=r,o=n?t[n]:void 0,s=r?t[r]:void 0;return!o||!s?{source:i,target:a}:{source:i,target:a,sourceId:n,targetId:r}}r(Ye,`getEdgeStartEndPoint`);function Xe(e,t,n,r){e.nodes.forEach(i=>{let a=t[i.id];!a||n.childrenById[a.id]===void 0||(a.labels=[{text:a.label,width:a?.labelData?.width??50,height:a?.labelData?.height??50}],r.log.debug(`UIO node label`,a?.labelData?.width,a.padding),a.layoutOptions=ke(a,e.config.elk,r.algorithm,r.log),delete a.x,delete a.y,delete a.width,delete a.height)})}r(Xe,`configureSubgraphNodes`);function Ze(e,t,n,r){r.debug(`APA01 processing edges, count:`,e.edges.length),e.edges.forEach((e,i)=>{r.debug(`APA01 processing edge`,i,`:`,e);let a=e.sources[0],o=e.targets[0];if(r.debug(`APA01 source:`,a,`target:`,o),r.debug(`APA01 nodeDb[source]:`,t[a]),r.debug(`APA01 nodeDb[target]:`,t[o]),t[a]&&t[o]&&t[a].parentId!==t[o].parentId){let e=p(a,o,n);Qe(t,a,e,r),Qe(t,o,e,r)}})}r(Ze,`configureCrossHierarchyEdges`);function Qe(e,t,n,r){let i=e[t];i&&(i.layoutOptions??={},i.layoutOptions[`elk.hierarchyHandling`]===`SEPARATE_CHILDREN`&&Te(i.metadata?.algorithm)&&(r.debug(`Dropping explicit algorithm for node`,i.id,`due to cross-boundary edges`),Ce(i.layoutOptions),Object.assign(i.layoutOptions,Oe(i))),i.layoutOptions[`elk.hierarchyHandling`]=`INCLUDE_CHILDREN`,i.id!==n&&i.parentId&&Qe(e,i.parentId,n,r))}r(Qe,`setIncludeChildrenPolicy`);async function $e(e,t,n){let r=globalThis.__mermaidProfiler;try{r?.begin(`layoutCore`);let i;try{i=await e.layout(t)}finally{r?.end()}return n.debug(`APA01 after - success`),n.debug(`APA01 layout result:`,i),i}catch(e){throw n.error(`ELK layout error:`,e),e}}r($e,`runElkLayout`);function et(e,t,n,r){let i=new Map(e.nodes.map(e=>[e.id,e]));it(t.children??[],n,i,0,0,0,r),rt(t.children??[],n,i,t),mt(e,t,n,r)}r(et,`applyElkLayoutResult`);function tt(e,t=new Set){for(let n of e.children??[])t.add(n.id),tt(n,t);return t}r(tt,`collectDescendantIds`);function nt(e,t,n,r){let i=[];for(let a of e.edges??[]){let e=a.sources?.[0]??a.start,o=a.targets?.[0]??a.end,s=t.has(e)&&t.has(o),c=e===r,l=o===r;if(!s&&!c&&!l)continue;let u=_t(e,o,n.parentLookupDb,n.nodeDb);for(let e of a.sections??[]){let t=s?[e.startPoint,...e.bendPoints??[],e.endPoint]:[c?e.startPoint:null,l?e.endPoint:null];for(let e of t)e&&i.push({x:e.x+u.x,y:e.y+u.y})}}return i}r(nt,`internalEdgePoints`);function rt(e,t,n,r={}){for(let i of e){if(!i?.isGroup)continue;let e=i.children??[];rt(e,t,n,r);let a=t.nodeDb[i.id],o=e.map(e=>t.nodeDb[e.id]).filter(e=>e?.offset&&e.width&&e.height);if(!a?.offset||o.length===0)continue;let s=nt(r,tt(i),t,i.id),c=[...o.map(e=>e.offset.posX),...o.map(e=>e.offset.posX+e.width),...s.map(e=>e.x)],l=[...o.map(e=>e.offset.posY),...o.map(e=>e.offset.posY+e.height),...s.map(e=>e.y)],u=a.offset,d=Math.max(u.posX,Math.min(...c)-ge),f=Math.min(u.posX+a.width,Math.max(...c)+ge),p=Math.min(u.posY+a.height,Math.max(...l)+ge),m=u.posY,h=De(i),g=d,_=f-d;if(_{if(!e)return;let s=t.nodeDb[e.id]??e,c=Math.max(e.width,e.labels&&e.labels[0]?.width||0),l={posX:e.x+r,posY:e.y+i,x:r,y:i,depth:a,width:c,height:e.height};s.offset=l,s.x=l.posX+e.width/2,s.y=l.posY+e.height/2,s.width=e.width,s.height=e.height;let u=n.get(e.id);if(u){u.x=s.x,u.y=s.y,u.width=e.isGroup?Math.max(e.width,e.labelData?.width??0):e.width,u.height=e.height;let t=u;t.labelData=e.labelData,t.labels=e.labels}e.isGroup?(o.debug(`Id abc88 subgraph = `,e.id,e.x,e.y,e.labelData),it(e.children??[],t,n,l.posX,l.posY,a+1,o)):o.info(`Id NODE = `,e.id,e.x,e.y,r,i,`translate(${s.x}, ${s.y})`)})}r(it,`applyElkNodePositions`);var at=16,ot=30,st=.01;function ct(e,t){let n=Math.abs(t.x-e.x),r=Math.abs(t.y-e.y);if(n>st&&r<=st)return`h`;if(r>st&&n<=st)return`v`}r(ct,`axisOf`);function lt(e){let t=ut(e)??e,n=ut([...t].reverse());return n&&(t=n.reverse()),t}r(lt,`straightenTerminalJogs`);function ut(e){if(e.length<5)return null;let[t,n,r,i]=e,a=ct(t,n);if(!a||ct(r,i)!==a||ct(n,r)!==(a===`h`?`v`:`h`)||Math.hypot(n.x-t.x,n.y-t.y)>ot)return null;let o=Math.abs(a===`h`?r.y-n.y:r.x-n.x);if(oat||!(a===`h`?Math.sign(n.x-t.x)===Math.sign(i.x-r.x):Math.sign(n.y-t.y)===Math.sign(i.y-r.y)))return null;let s=3;for(;s+1(t.x-e.x)*(n.y-e.y)-(t.y-e.y)*(n.x-e.x),`side`),o=a(n,i,e),s=a(n,i,t),c=a(e,t,n),l=a(e,t,i);return(o>0&&s<0||o<0&&s>0)&&(c>0&&l<0||c<0&&l>0)}r(dt,`segmentsCrossStrict`);function ft(e,t){let n=0;for(let r=0;re.points??[]);for(let[n,r]of e.entries()){let e=t[n];if(e.length<5)continue;let i=lt(e);if(i===e)continue;let a=0,o=0;for(let[r,s]of t.entries())r===n||s.length<2||(a+=ft(e,s),o+=ft(i,s));o>a||(r.points=i,t[n]=i)}}r(pt,`straightenEdgeTerminals`);function mt(e,t,n,i){let a=new Map(e.edges.map(e=>[e.id,e])),o=e.config.elk?.straightenEdges!==!1,s=new Map(e.nodes.map(e=>[e.id,e])),c=new Set;t.edges?.forEach(e=>{if(!e.sections?.length)return;let t=n.nodeDb[e.sources?.[0]??e.start],r=n.nodeDb[e.targets?.[0]??e.end];if(!t||!r)return;let i=_t(e.start??e.sourceId??e.sources?.[0],e.end??e.targetId??e.targets?.[0],n.parentLookupDb,n.nodeDb),a=e.sections[0];t.shape!==`rect33`&&ht(t,{x:a.startPoint.x+i.x,y:a.startPoint.y+i.y},s,c),r.shape!==`rect33`&&ht(r,{x:a.endPoint.x+i.x,y:a.endPoint.y+i.y},s,c)}),t.edges?.forEach(e=>{let t=a.get(e.id);if(!t)return;let o=e.sources?.[0]??e.start,s=e.targets?.[0]??e.end,c=n.nodeDb[o],l=n.nodeDb[s];if(!c||!l)return;if(!e.sections?.length){let n=r(e=>({x:(e.offset?.posX??e.x??0)+(e.width??0)/2,y:(e.offset?.posY??e.y??0)+(e.height??0)/2}),`centre`),a=n(c),o=n(l);c.x=a.x,c.y=a.y,l.x=o.x,l.y=o.y;let s=vt([a,o],c,l,i);t.points=s,t.curve=`linear`;let u=s[0],d=s[s.length-1];t.x=(u.x+d.x)/2,t.y=(u.y+d.y)/2,i.debug(`APA18 no edge sections, using a straight line`,e.id,t.points);return}let u=e.start??e.sourceId??o,d=e.end??e.targetId??s,f=_t(u,d,n.parentLookupDb,n.nodeDb);i.debug(`APA18 offset`,f,u,` ==> `,d,`edge:`,e,c);let p=e.sections[0],m=gt(p,f);c.x=c.offset.posX+c.width/2,c.y=c.offset.posY+c.height/2,l.x=l.offset.posX+l.width/2,l.y=l.offset.posY+l.height/2,c.shape!==`rect33`&&m.unshift({x:c.x,y:c.y}),l.shape!==`rect33`&&m.push({x:l.x,y:l.y}),t.points=Ct(wt(vt(m,c,l,i),jt(l),xt(t),i),jt(c),St(t),i),t.curve=`rounded`;let h=e.labels?.[0];h&&(t.x=h.x+f.x+h.width/2,t.y=h.y+f.y+h.height/2)}),o&&pt(e.edges)}r(mt,`applyElkEdgeLayout`);function ht(e,t,n,r){let i=e.width??0,a=e.height??0,o=e.offset.posY,s=o+a,c=.5,l=Math.abs(t.y-o)<=c||Math.abs(t.y-s)<=c;if((l?i:a)>=2*me||r.has(e.id))return;r.add(e.id);let u=l?t.x-(e.offset.posX+i/2):t.y-(e.offset.posY+a/2);if(Math.abs(u)<.01)return;l?(e.offset.posX+=u,e.x=e.offset.posX+i/2):(e.offset.posY+=u,e.y=e.offset.posY+a/2);let d=n.get(e.id);d&&(d.x=e.offset.posX+i/2,d.y=e.offset.posY+a/2)}r(ht,`alignDegenerateNodeToAnchor`);function gt(e,t){let n=e.startPoint,r=e.endPoint,i=(e.bendPoints?e.bendPoints:[]).map(e=>({x:e.x+t.x,y:e.y+t.y}));return[{x:n.x+t.x,y:n.y+t.y},...i,{x:r.x+t.x,y:r.y+t.y}]}r(gt,`createEdgePointsFromSection`);function _t(e,t,n,r){let i=p(e,t,n);if(i===void 0||i===`root`)return{x:0,y:0};let a=r[i],o=a?.elkOrigin??a?.offset;return{x:o?.posX??0,y:o?.posY??0}}r(_t,`calcOffset`);function vt(e,t,n,r){let i=Array.isArray(e)?[...e]:[],a=jt(n);r.debug(`PPP cutter2: Points before cutter2:`,JSON.stringify(e),`endBounds:`,a,S(a,e[e.length-1]));let o;{let e=jt(t),a=jt(n),s=!!t?.isGroup,c=!!n?.isGroup,{candidate:l,centerApprox:u}=Pt(i,t,`start`),{candidate:d,centerApprox:f}=Pt(i,n,`end`),p=s&&S(e,l),m=c&&S(a,d);Ft(i,`start`,p&&u),Ft(i,`end`,m&&f),s&&!p&&(p=It(i,e,`start`)),c&&!m&&(m=It(i,a,`end`)),p||m?(p||Lt(i,t,e,r),m||Rt(i,n,a,r),r.debug(`PPP cutter2: skipping cutter2 due to on-border group endpoint(s)`,{skipStart:p,skipEnd:m,startCenterApprox:u,endCenterApprox:f,startCandidate:l,endCandidate:d}),o=i):o=Bt(t,n,i,r)}if(r.debug(`PPP cutter2: Points after cutter2:`,JSON.stringify(o)),!Array.isArray(o)||o.length<2||yt(o)){r.warn(`POI cutter2: Invalid points from cutter2, falling back to prevPoints`,o);let e=i.filter(e=>Number.isFinite(e?.x)&&Number.isFinite(e?.y));o=e.length>=2?e:i}return r.debug(`UIO cutter2: Points after cutter2 (sanitized):`,o),bt(o,r)}r(vt,`sanitizeElkEdgePoints`);function yt(e){return e?.some(e=>!Number.isFinite(e?.x)||!Number.isFinite(e?.y))}r(yt,`hasInvalidPoint`);function bt(e,t){let n=e.filter((e,t,n)=>{if(t===0)return!0;let r=n[t-1];return Math.abs(e.x-r.x)>1e-6||Math.abs(e.y-r.y)>1e-6});return n.length!==e.length&&t.debug(`UIO cutter2: removed consecutive duplicate points`,{before:e,after:n}),n}r(bt,`dedupeConsecutivePoints`);function xt(e){return fe(e.arrowTypeEnd)}r(xt,`getEndMarkerPathOffset`);function St(e){return fe(e.arrowTypeStart)}r(St,`getStartMarkerPathOffset`);function Ct(e,t,n,r){if(n<=0||e.length<3)return e;let i=e[0],a=e[1],o=Math.hypot(a.x-i.x,a.y-i.y);if(o>=Math.max(de,n*2)||!S(t,a,1))return e;let s=[i,...e.slice(2)];return r.debug(`UIO cutter2: removed short start marker segment`,{before:e,after:s,markerOffset:n,segmentLength:o}),s}r(Ct,`ensureStartMarkerSegmentLength`);function wt(e,t,n,r){if(n<=0||e.length<3)return e;let i=e[e.length-1],a=e[e.length-2],o=Math.hypot(i.x-a.x,i.y-a.y);if(o>=Math.max(de,n*2)||!S(t,a,1))return e;let s=[...e.slice(0,-2),i];return r.debug(`UIO cutter2: removed short end marker segment`,{before:e,after:s,markerOffset:n,segmentLength:o}),s}r(wt,`ensureEndMarkerSegmentLength`);function Tt(e,t){let n=e.edges.defaultInterpolate,r=e.edges.defaultStyle,i=t.getConfig();e.edges.forEach(e=>{let a=kt(e,{defaultStyle:r,defaultInterpolate:n,confCurve:i.curve},t);Object.assign(e,a)})}r(Tt,`applyElkEdgeRenderData`);function Et(e){if(e.classes!==void 0)return e.classes;if(e.start&&e.end)return`flowchart-link LS_${e.start} LE_${e.end}`}r(Et,`buildFallbackEdgeClasses`);function Dt(e,t,n){let r=`normal`,i=`solid`,a=[],o=[];return e===`dotted`?(i=`dotted`,a=[`fill:none`,`stroke-width:2px`,`stroke-dasharray:3`]):e===`thick`?(r=`thick`,a=[`stroke-width: 3.5px`,`fill:none`]):(a=t??[`fill:none`],n!==void 0&&(o=n)),{thickness:r,pattern:i,style:a,labelStyle:o}}r(Dt,`computeStroke`);function Ot(e,t,n){return e===void 0?t===void 0?n:t:e}r(Ot,`getCurve`);function kt(e,t,n){let r={};r.minlen=e.minlen??e.length??1,r.text=e.text??e.label,r.arrowhead=e.arrowhead??(e.type===`arrow_open`?`none`:`normal`);let i=pe[e.type??`arrow_open`]??pe.arrow_open;r.arrowTypeStart=e.arrowTypeStart??i[0],r.arrowTypeEnd=e.arrowTypeEnd??i[1],r.startLabelRight=e.startLabelRight,r.endLabelLeft=e.endLabelLeft;let o=Dt(e.stroke,t.defaultStyle,t.defaultLabelStyle);r.thickness=e.thickness??o.thickness,r.pattern=e.pattern??o.pattern,r.style=e.style??o.style,r.labelStyle=e.labelStyle??o.labelStyle,r.classes=Et(e),r.curve=n.interpolateToCurve(Ot(e.curve??e.interpolate,t.defaultInterpolate,t.confCurve),a);let s=(r.text??``)!==``;return e.arrowheadStyle===void 0?(s||e.style!==void 0)&&(r.arrowheadStyle=`fill: #333`):r.arrowheadStyle=e.arrowheadStyle,r.labelpos=e.labelpos??(s?`c`:void 0),r.labelType=e.labelType,r.label=(e.label??r.text??``).replace(n.common.lineBreakRegex,` +`),r}r(kt,`buildEdgeData`);function At(e){return Math.max(e.width??0,De(e))}r(At,`getEffectiveGroupWidth`);function jt(e){let t=e?.isGroup?At(e):e.width;return{x:e.offset.posX+e.width/2,y:e.offset.posY+e.height/2,width:t??0,height:e.height??0,padding:e.padding}}r(jt,`boundsFor`);function Mt(e,t,n=1e-6){return Math.abs(e-t)1?e[1]:n,centerApprox:r}}{let n=e[e.length-1],r=Nt(n,t);return{candidate:r&&e.length>1?e[e.length-2]:n,centerApprox:r}}}r(Pt,`getCandidateBorderPoint`);function Ft(e,t,n){n&&(t===`start`?e.length>0&&e.shift():e.length>0&&e.pop())}r(Ft,`dropAutoCenterPoint`);function It(e,t,n){let r=n===`start`?1:-1,i=n===`start`?0:e.length-1,a=i;for(;i>=0&&i=e.length)return!1;let o=e[i],s=e[i-r],c=o.x-s.x,l=o.y-s.y,u=c===0?1/0:(t.x+Math.sign(c)*t.width/2-s.x)/c,d=l===0?1/0:(t.y+Math.sign(l)*t.height/2-s.y)/l,f=Math.min(u,d),p={x:s.x+f*c,y:s.y+f*l};return n===`start`?e.splice(0,i,p):e.splice(i+1,e.length-i-1,p),!0}r(It,`clipGroupEndpoint`);function Lt(e,t,n,r){let i=-1;for(let[t,r]of e.entries())if(te(n,r)){i=t;break}if(i!==-1){let a=e[i],o=e[0],s=le(t,n,a,o);ue(e,`start`,s),r.debug(`UIO cutter2: start-only intersection applied`,{startIntersection:s})}}r(Lt,`applyStartIntersectionIfNeeded`);function Rt(e,t,n,r){let i=-1;for(let t=e.length-1;t>=0;t--)if(te(n,e[t])){i=t;break}if(i!==-1){let a=e[i],o=e[e.length-1],s=le(t,n,a,o);ue(e,`end`,s),r.debug(`UIO cutter2: end-only intersection applied`,{endIntersection:s})}}r(Rt,`applyEndIntersectionIfNeeded`);function zt(e,t,n,r,i){if(e?.isGroup)return null;let a=n[r],o=n[r+i];return!a||!o?null:ce(e,t,a,o)}r(zt,`attachAlongDepartureAxis`);function Bt(e,t,n,r){let i=jt(e),a=jt(t);if(n.length===0)return[];let o=[...n],s=o[0],c=o[o.length-1];r.debug(`PPP cutter2: bounds`,{startBounds:i,endBounds:a}),r.debug(`PPP cutter2: original points`,n);let l=-1;for(let[e,t]of o.entries())l===-1&&te(i,t)&&(l=e);if(l!==-1){let t=o[l],n=zt(e,i,o,l,1)??le(e,i,t,s);r.debug(`UIO cutter2: start intersection`,n),ue(o,`start`,n)}let u=null,d=-1;for(let e=o.length-1;e>=0;e--)if(te(a,o[e])){u=o[e],d=e;break}if(!u&&o.length>1&&(u=o[o.length-2],d=o.length-2),u){let e=zt(t,a,o,d,-1)??le(t,a,u,c);r.debug(`UIO cutter2: end intersection`,{endIntersection:e,outsideIndexForEnd:d}),ue(o,`end`,e)}if(o.length>1){let e=o[o.length-1],t=o[o.length-2],n=Math.sqrt((e.x-t.x)**2+(e.y-t.y)**2);n<2&&(r.debug(`UIO cutter2: trimming tail point (too close)`,{distance:n,lastPoint:e,secondLastPoint:t}),o.pop())}return r.debug(`UIO cutter2: final points`,o),o}r(Bt,`cutter2`);export{Fe as render}; \ No newline at end of file diff --git a/frontend/dist/assets/erDiagram-OPXOYQCR-YD8i2JM4.js b/frontend/dist/assets/erDiagram-OPXOYQCR-YD8i2JM4.js new file mode 100644 index 0000000..9314ec0 --- /dev/null +++ b/frontend/dist/assets/erDiagram-OPXOYQCR-YD8i2JM4.js @@ -0,0 +1,99 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as i,U as a,a as o,ot as s,q as c,s as l,v as u,w as d,x as f,y as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./channel-_oCHZhRo.js";import{c as h,g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{a as _,i as v,o as y,r as b,t as x}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as S,t as C}from"./index-DoQkmpth.js";import{t as w}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as T}from"./chunk-WEXAMYUT-I3m-hOmT.js";var E=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],r=[2,2],i=[1,7],a=[1,9],o=[1,10],s=[1,11],c=[1,12],l=[1,30],u=[1,23],d=[1,24],f=[1,25],p=[1,26],m=[1,27],h=[1,19],g=[1,28],_=[1,29],v=[1,20],y=[1,18],b=[1,21],x=[1,22],S=[2,6],C=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],w=[1,36],T=[1,37],E=[1,38],D=[1,39],O=[1,40],k=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],A=[1,46],j=[1,47],M=[1,57],N=[43,51,53,54,55,74,75],P=[1,70],F=[1,68],I=[1,65],L=[1,69],R=[1,71],z=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],B=[1,78],V=[1,77],H=[1,76],U=[69,70,71,72,73],W=[1,91],G=[6,9,45,50],K=[6,9,12,44,45,50,51,52],q=[1,101],J=[1,100],Y=[1,99],X=[18,61],ee=[1,110],te=[1,109],ne=[20,43,51,53,54,55],Z=[18,61,64,66],Q={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:`error`,4:`ER_DIAGRAM`,6:`EOF`,9:`NEWLINE`,12:`COLON`,14:`STYLE_SEPARATOR`,16:`BLOCK_START`,18:`BLOCK_STOP`,19:`SQS`,20:`SQE`,21:`title`,22:`title_value`,23:`acc_title`,24:`acc_title_value`,25:`acc_descr`,26:`acc_descr_value`,27:`acc_descr_multiline_value`,33:`END`,34:`SUBGRAPH`,37:`direction_tb`,38:`direction_bt`,39:`direction_rl`,40:`direction_lr`,41:`CLASSDEF`,43:`UNICODE_TEXT`,44:`STYLE_TEXT`,45:`COMMA`,46:`CLASS`,47:`STYLE`,50:`SEMI`,51:`NUM`,52:`BRKT`,53:`ENTITY_NAME`,54:`DECIMAL_NUM`,55:`ENTITY_ONE`,61:`ATTRIBUTE_WORD`,62:`?`,64:`,`,65:`ATTRIBUTE_KEY`,66:`COMMENT`,69:`ZERO_OR_ONE`,70:`ZERO_OR_MORE`,71:`ONE_OR_MORE`,72:`ONLY_ONE`,73:`MD_PARENT`,74:`NON_IDENTIFYING`,75:`IDENTIFYING`,76:`WORD`},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:break;case 2:this.$=[];break;case 3:this.$=a[s-1].concat(a[s]);break;case 4:this.$=a[s];break;case 5:case 6:this.$=[];break;case 7:r.addEntity(a[s-4]),r.addEntity(a[s-2]),r.addRelationship(a[s-4],a[s],a[s-2],a[s-3]),this.$=[a[s-4],a[s-2]];break;case 8:r.addEntity(a[s-8]),r.addEntity(a[s-4]),r.addRelationship(a[s-8],a[s],a[s-4],a[s-5]),r.setClass([a[s-8]],a[s-6]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-8],a[s-4]];break;case 9:r.addEntity(a[s-6]),r.addEntity(a[s-2]),r.addRelationship(a[s-6],a[s],a[s-2],a[s-3]),r.setClass([a[s-6]],a[s-4]),this.$=[a[s-6],a[s-2]];break;case 10:r.addEntity(a[s-6]),r.addEntity(a[s-4]),r.addRelationship(a[s-6],a[s],a[s-4],a[s-5]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-6],a[s-4]];break;case 11:r.addEntity(a[s-3]),r.addAttributes(a[s-3],a[s-1]),this.$=[a[s-3]];break;case 12:r.addEntity(a[s-5]),r.addAttributes(a[s-5],a[s-1]),r.setClass([a[s-5]],a[s-3]),this.$=[a[s-5]];break;case 13:r.addEntity(a[s-2]),this.$=[a[s-2]];break;case 14:r.addEntity(a[s-4]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-4]];break;case 15:r.addEntity(a[s]),this.$=[a[s]];break;case 16:r.addEntity(a[s-2]),r.setClass([a[s-2]],a[s]),this.$=[a[s-2]];break;case 17:r.addEntity(a[s-6],a[s-4]),r.addAttributes(a[s-6],a[s-1]),this.$=[a[s-6]];break;case 18:r.addEntity(a[s-8],a[s-6]),r.addAttributes(a[s-8],a[s-1]),r.setClass([a[s-8]],a[s-3]),this.$=[a[s-8]];break;case 19:r.addEntity(a[s-5],a[s-3]),this.$=[a[s-5]];break;case 20:r.addEntity(a[s-7],a[s-5]),r.setClass([a[s-7]],a[s-2]),this.$=[a[s-7]];break;case 21:r.addEntity(a[s-3],a[s-1]);break;case 22:r.addEntity(a[s-5],a[s-3]),r.setClass([a[s-5]],a[s]);break;case 23:case 24:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 25:case 26:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 27:r.subgraphDepth?this.$=a[s]:(r.setDirection(a[s].value),this.$=[]);break;case 31:r.subgraphDepth=(r.subgraphDepth||1)-1,this.$=r.addSubGraph({text:a[s-2].id},a[s-1],{text:a[s-2].text});break;case 32:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:a[s-1],text:a[s-1]};break;case 33:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:a[s-4],text:a[s-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=a[s];break;case 35:this.$=a[s-1]+` `+a[s];break;case 36:this.$={stmt:`dir`,value:`TB`};break;case 37:this.$={stmt:`dir`,value:`BT`};break;case 38:this.$={stmt:`dir`,value:`RL`};break;case 39:this.$={stmt:`dir`,value:`LR`};break;case 40:this.$=a[s-3],r.addClass(a[s-2],a[s-1]);break;case 41:case 42:case 63:case 72:this.$=[a[s]];break;case 43:case 44:this.$=a[s-2].concat([a[s]]);break;case 45:this.$=a[s-2],r.setClass(a[s-1],a[s]);break;case 46:this.$=a[s-3],r.addCssStyles(a[s-2],a[s-1]);break;case 47:this.$=[a[s]];break;case 48:a[s-2].push(a[s]),this.$=a[s-2];break;case 50:this.$=a[s-1]+a[s];break;case 58:case 84:case 85:this.$=a[s].replace(/"/g,``);break;case 64:a[s].push(a[s-1]),this.$=a[s];break;case 65:this.$={type:a[s-1],name:a[s]};break;case 66:this.$={type:a[s-2],name:a[s-1],keys:a[s]};break;case 67:this.$={type:a[s-2],name:a[s-1],comment:a[s]};break;case 68:this.$={type:a[s-3],name:a[s-2],keys:a[s-1],comment:a[s]};break;case 69:case 71:case 74:this.$=a[s];break;case 70:this.$=a[s-1]+a[s];break;case 73:a[s-2].push(a[s]),this.$=a[s-2];break;case 75:this.$=a[s].replace(/"/g,``);break;case 76:this.$={cardA:a[s],relType:a[s-1],cardB:a[s-2]};break;case 77:this.$=r.Cardinality.ZERO_OR_ONE;break;case 78:this.$=r.Cardinality.ZERO_OR_MORE;break;case 79:this.$=r.Cardinality.ONE_OR_MORE;break;case 80:this.$=r.Cardinality.ONLY_ONE;break;case 81:this.$=r.Cardinality.MD_PARENT;break;case 82:this.$=r.Identification.NON_IDENTIFYING;break;case 83:this.$=r.Identification.IDENTIFYING}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(t,r,{5:3}),{6:[1,4],7:5,8:6,9:i,10:8,21:a,23:o,25:s,27:c,28:13,29:14,30:15,31:16,32:17,34:l,37:u,38:d,39:f,40:p,41:m,43:h,46:g,47:_,51:v,53:y,54:b,55:x},e(t,S,{1:[2,1]}),e(C,[2,3]),e(C,[2,4]),e(C,[2,5]),e(C,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:w,70:T,71:E,72:D,73:O}),{22:[1,41]},{24:[1,42]},{26:[1,43]},e(C,[2,26]),e(C,[2,27]),e(C,[2,28]),e(C,[2,29]),e(C,[2,30]),e(C,r,{5:44}),e(k,[2,58]),e(k,[2,59]),e(k,[2,60]),e(k,[2,61]),e(k,[2,62]),e(C,[2,36]),e(C,[2,37]),e(C,[2,38]),e(C,[2,39]),{15:45,43:A,44:j},{15:48,43:A,44:j},{15:49,43:A,44:j},{10:50,43:h,51:v,53:y,54:b,55:x},{10:51,43:h,51:v,53:y,54:b,55:x},{15:52,43:A,44:j},{17:53,18:[1,54],56:55,57:56,61:M},{10:58,43:h,51:v,53:y,54:b,55:x},{68:59,74:[1,60],75:[1,61]},e(N,[2,77]),e(N,[2,78]),e(N,[2,79]),e(N,[2,80]),e(N,[2,81]),e(C,[2,23]),e(C,[2,24]),e(C,[2,25]),{6:[1,63],7:5,8:6,9:i,10:8,21:a,23:o,25:s,27:c,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:l,37:u,38:d,39:f,40:p,41:m,43:h,46:g,47:_,51:v,53:y,54:b,55:x},{12:P,42:64,44:F,45:I,48:66,49:67,51:L,52:R},e(z,[2,41]),e(z,[2,42]),{15:72,43:A,44:j,45:I},{12:P,42:73,44:F,45:I,48:66,49:67,51:L,52:R},{6:B,9:V,19:[1,75],35:74,50:H},{12:[1,79],14:[1,80]},e(C,[2,16],{67:35,11:81,16:[1,82],45:I,69:w,70:T,71:E,72:D,73:O}),{18:[1,83]},e(C,[2,13]),{17:84,18:[2,63],56:55,57:56,61:M},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:w,70:T,71:E,72:D,73:O},e(U,[2,82]),e(U,[2,83]),e(C,[2,31]),e(C,S),{6:B,9:V,35:90,45:W,50:H},{43:[1,92],44:[1,93]},e(G,[2,47],{49:94,12:P,44:F,51:L,52:R}),e(K,[2,49]),e(K,[2,54]),e(K,[2,55]),e(K,[2,56]),e(K,[2,57]),e(C,[2,45],{45:I}),{6:B,9:V,35:95,45:W,50:H},e(C,[2,32]),{10:97,36:96,43:h,51:v,53:y,54:b,55:x},e(C,[2,51]),e(C,[2,52]),e(C,[2,53]),{13:98,43:q,53:J,76:Y},{15:102,43:A,44:j},{10:103,43:h,51:v,53:y,54:b,55:x},{17:104,18:[1,105],56:55,57:56,61:M},e(C,[2,11]),{18:[2,64]},e(X,[2,65],{59:106,60:107,63:108,65:ee,66:te}),e([18,61,65,66],[2,71]),{61:[2,70]},e(C,[2,21],{14:[1,112],16:[1,111]}),e([43,51,53,54,55],[2,76]),e(C,[2,40]),{12:P,44:F,48:113,49:67,51:L,52:R},e(z,[2,43]),e(z,[2,44]),e(K,[2,50]),e(C,[2,46]),{10:115,20:[1,114],43:h,51:v,53:y,54:b,55:x},e(ne,[2,34]),e(C,[2,7]),e(C,[2,84]),e(C,[2,85]),e(C,[2,86]),{12:[1,116],45:I},{12:[1,118],14:[1,117]},{18:[1,119]},e(C,[2,14]),e(X,[2,66],{60:120,64:[1,121],66:te}),e(X,[2,67]),e(Z,[2,72]),e(X,[2,75]),e(Z,[2,74]),{17:122,18:[1,123],56:55,57:56,61:M},{15:124,43:A,44:j},e(G,[2,48],{49:94,12:P,44:F,51:L,52:R}),{6:B,9:V,35:125,50:H},e(ne,[2,35]),{13:126,43:q,53:J,76:Y},{15:127,43:A,44:j},{13:128,43:q,53:J,76:Y},e(C,[2,12]),e(X,[2,68]),{63:129,65:ee},{18:[1,130]},e(C,[2,19]),e(C,[2,22],{16:[1,131],45:I}),e(C,[2,33]),e(C,[2,10]),{12:[1,132],45:I},e(C,[2,9]),e(Z,[2,73]),e(C,[2,17]),{17:133,18:[1,134],56:55,57:56,61:M},{13:135,43:q,53:J,76:Y},{18:[1,136]},e(C,[2,20]),e(C,[2,8]),e(C,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};Q.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),23;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),25;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return 37;case 8:return 38;case 9:return 39;case 10:return 40;case 11:break;case 12:return 9;case 13:return 53;case 14:return 76;case 15:return 4;case 16:return this.begin(`block`),16;case 17:return 52;case 18:return 52;case 19:return 45;case 20:return 14;case 21:return 12;case 22:break;case 23:return 65;case 24:return 61;case 25:return 61;case 26:this.begin(`block_bq`);break;case 27:return 61;case 28:this.popState();break;case 29:return 66;case 30:break;case 31:return this.popState(),18;case 32:return t.yytext[0];case 33:return 19;case 34:return 20;case 35:return this.begin(`style`),47;case 36:return this.popState(),9;case 37:break;case 38:return 12;case 39:return 45;case 40:return 52;case 41:return this.begin(`style`),41;case 42:return 46;case 43:return 34;case 44:return 33;case 45:return 69;case 46:return 71;case 47:return 71;case 48:return 71;case 49:return 69;case 50:return 69;case 51:return 70;case 52:return 70;case 53:return 70;case 54:return 70;case 55:return 70;case 56:return 71;case 57:return 70;case 58:return 71;case 59:return 72;case 60:return 72;case 61:return 54;case 62:return 72;case 63:return 72;case 64:return 72;case 65:return 55;case 66:return 51;case 67:return 72;case 68:return 69;case 69:return 70;case 70:return 71;case 71:return 73;case 72:return 74;case 73:return 75;case 74:return 75;case 75:return 74;case 76:return 74;case 77:return 74;case 78:return 44;case 79:return 50;case 80:return 43;case 81:return t.yytext[0];case 82:return 6}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[ \t\r]+)/i,/^(?:[\n]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:subgraph\b)/i,/^(?:end\b\s*)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[36,37,38,39,40,78,79],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[27,28],inclusive:!1},block:{rules:[22,23,24,25,26,29,30,31,32],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,33,34,35,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,80,81,82],inclusive:!0}}}})();function $(){this.yy={}}return n($,`Parser`),$.prototype=Q,Q.Parser=$,new $})();E.parser=E;var D=E,O=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.subgraphDepth=0,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.direction=`TB`,this.Cardinality={ZERO_OR_ONE:`ZERO_OR_ONE`,ZERO_OR_MORE:`ZERO_OR_MORE`,ONE_OR_MORE:`ONE_OR_MORE`,ONLY_ONE:`ONLY_ONE`,MD_PARENT:`MD_PARENT`},this.Identification={NON_IDENTIFYING:`NON_IDENTIFYING`,IDENTIFYING:`IDENTIFYING`},this.setAccTitle=a,this.getAccTitle=p,this.setAccDescription=i,this.getAccDescription=u,this.setDiagramTitle=c,this.getDiagramTitle=d,this.getConfig=n(()=>f().er,`getConfig`),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this),this.addSubGraph=this.addSubGraph.bind(this)}static{n(this,`ErDB`)}addEntity(t,n=``){return this.entities.has(t)?!this.entities.get(t)?.alias&&n&&(this.entities.get(t).alias=n,e.info(`Add alias '${n}' to entity '${t}'`)):(this.entities.set(t,{id:`entity-${t}-${this.entities.size}`,label:t,attributes:[],alias:n,shape:`erBox`,look:f().look??`default`,cssClasses:`default`,cssStyles:[],labelType:`markdown`}),e.info(`Added new entity :`,t)),this.entities.get(t)}getEntity(e){return this.entities.get(e)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(t,n){let r=this.addEntity(t),i;for(i=n.length-1;i>=0;i--)n[i].keys||(n[i].keys=[]),n[i].comment||(n[i].comment=``),r.attributes.push(n[i]),e.debug(`Added attribute `,n[i].name)}addRelationship(t,n,r,i){let a;if(this.subGraphLookup.has(t))a=t;else{let e=this.addEntity(t);if(!e)return;a=e.id}let o;if(this.subGraphLookup.has(r))o=r;else{let e=this.addEntity(r);if(!e)return;o=e.id}let s={entityA:a,roleA:n,entityB:o,relSpec:i};this.relationships.push(s),e.debug(`Added new relationship :`,s)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(e){this.direction=e}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}addCssStyles(e,t){for(let n of e){let e=this.entities.get(n),r=this.subGraphLookup.get(n);if(t){if(e)for(let n of t)e.cssStyles.push(n);if(r){r.cssStyles||=[];for(let e of t)r.cssStyles.push(e)}}}}addClass(e,t){e.forEach(e=>{let n=this.classes.get(e);n===void 0&&(n={id:e,styles:[],textStyles:[]},this.classes.set(e,n)),t&&t.forEach(function(e){if(/color/.exec(e)){let t=e.replace(`fill`,`bgFill`);n.textStyles.push(t)}n.styles.push(e)})})}addSubGraph(t,r,i){let a=t.text.trim(),o=i.text,s=n(e=>{let t=new Set,n;return{nodeList:e.filter(e=>{if(e?.stmt)return e.stmt===`dir`&&(n=e.value),!1;if(typeof e!=`string`)return!1;let r=e.trim();return!r||t.has(r)?!1:(t.add(r),!0)}),dir:n}},`uniq`)(r.flat()),c=s.nodeList,l=s.dir;a??=`subGraph`+this.subCount,o||=``,o=this.sanitizeText(o),this.subCount+=1;let u={id:a,nodes:c,title:o.trim(),classes:[],cssStyles:[],dir:l,labelType:this.sanitizeNodeLabelType(i?.type)};return e.info(`Adding`,u.id,u.nodes,u.dir),u.nodes=this.makeUniq(u,this.subGraphs).nodes,this.subGraphs.push(u),this.subGraphLookup.set(a,u),a}getSubGraphs(){return this.subGraphs}setClass(e,t){for(let n of e){let e=this.entities.get(n);if(e)for(let n of t)e.cssClasses+=` `+n;let r=this.subGraphLookup.get(n);if(r)for(let e of t)r.classes.push(e)}}subgraphNodeCache(e){let t=new Set;for(let n of e)for(let e of n.nodes)t.add(e);return t}makeUniq(t,n){let r=this.subgraphNodeCache(n),i=[];return t.nodes.forEach((n,a)=>{r.has(n)?e.warn(`Entity '${n}' already belongs to another subgraph and will be ignored`):i.push(t.nodes[a])}),{nodes:i}}sanitizeText(e){return l.sanitizeText(e,f())}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.subgraphDepth=0,o()}getData(){let e=[],t=[],n=f(),r=this.getSubGraphs(),i=new Map,a=new Map;for(let e=r.length-1;e>=0;e--){let t=r[e];t.nodes.length>0&&a.set(t.id,!0);for(let e of t.nodes)i.set(e,t.id)}for(let t=r.length-1;t>=0;t--){let a=r[t];e.push({id:a.id,label:a.title,labelStyle:``,labelType:a.labelType,parentId:i.get(a.id),padding:8,cssCompiledStyles:this.getCompiledStyles(a.classes),cssStyles:a.cssStyles,cssClasses:a.classes.join(` `),shape:`rect`,dir:a.dir,isGroup:!0,look:n.look})}let o=new Set(r.map(e=>e.id)),s=0;for(let t of this.entities.keys()){if(o.has(t))continue;let n=this.entities.get(t);n&&(n.cssCompiledStyles=this.getCompiledStyles(n.cssClasses.split(` `)),n.colorIndex=s++,e.push({...n,parentId:i.get(t),isGroup:!1}))}let c=0;for(let e of this.relationships){let r={id:h(e.entityA,e.entityB,{prefix:`id`,counter:c++}),type:`normal`,curve:`basis`,start:e.entityA,end:e.entityB,label:e.roleA,labelpos:`c`,thickness:`normal`,classes:`relationshipLine`,arrowTypeStart:e.relSpec.cardB.toLowerCase(),arrowTypeEnd:e.relSpec.cardA.toLowerCase(),pattern:e.relSpec.relType==`IDENTIFYING`?`solid`:`dashed`,look:n.look,labelType:`markdown`};t.push(r)}return{nodes:e,edges:t,other:{},config:n,direction:this.direction}}},k={};r(k,{draw:()=>A});var A=n(async function(n,r,i,a){e.info(`REF0:`),e.info(`Drawing er diagram (unified)`,r);let{securityLevel:o,er:s,layout:c}=f(),l=a.db.getData(),u=w(r,o);l.type=a.type,l.layoutAlgorithm=C(c),l.config.flowchart.nodeSpacing=s?.nodeSpacing||140,l.config.flowchart.rankSpacing=s?.rankSpacing||80,l.direction=a.db.getDirection();let{config:d}=l,{look:p}=d;l.markers=p===`neo`?[`only_one_neo`,`zero_or_one_neo`,`one_or_more_neo`,`zero_or_more_neo`]:[`only_one`,`zero_or_one`,`one_or_more`,`zero_or_more`],l.diagramId=r,await S(l,u);let m=u.selectAll(`[id*="-background"]`);Array.from(m).length>0&&m.each(function(){let e=t(this),n=e.attr(`id`).replace(`-background`,``),r=u.select(`#${CSS.escape(n)}`);if(!r.empty()){let t=r.attr(`transform`);e.attr(`transform`,t)}}),g.insertTitle(u,`erDiagramTitleText`,s?.titleTopMargin??25,a.db.getDiagramTitle()),T(u,8,`erDiagram`,s?.useMaxWidth??!0)},`draw`),j=n((e,t)=>{let n=m,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return s(r,i,a,t)},`fade`),M=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!v(t,r))return``;let i=y(e.look),a=b(n),o=``;for(let e=0;e<_(r);e++){let t=r[e],s=a?`fill: ${n[e%n.length]};`:``;o+=` + + [data-look="${i}"][data-color-id="color-${e}"].node path { + stroke: ${t}; + ${s} + } + + [data-look="${i}"][data-color-id="color-${e}"].node rect { + stroke: ${t}; + ${s} + } + `}return o},`genColor`),N={parser:D,get db(){return new O},renderer:k,styles:n(e=>{let{look:t,theme:n,erEdgeLabelBackground:r,strokeWidth:i}=e;return` + ${M(e)} + .entityBox { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + } + + .relationshipLabelBox { + fill: ${e.tertiaryColor}; + opacity: 0.7; + background-color: ${e.tertiaryColor}; + rect { + opacity: 0.5; + } + } + + .labelBkg { + background-color: ${x.has(n)&&r?r:j(e.tertiaryColor,.5)}; + } + + .edgeLabel { + background-color: ${x.has(n)&&r?r:e.edgeLabelBackground}; + } + .edgeLabel .label rect { + fill: ${x.has(n)&&r?r:e.edgeLabelBackground}; + } + .edgeLabel .label text { + fill: ${e.textColor}; + } + + .edgeLabel .label { + fill: ${e.nodeBorder}; + font-size: 14px; + } + + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + + .edge-pattern-dashed { + stroke-dasharray: 8,8; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon + { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${t===`neo`?i:`1px`}; + } + + .relationshipLine { + stroke: ${e.lineColor}; + stroke-width: ${t===`neo`?i:`1px`}; + fill: none; + } + + .marker { + fill: none !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; + } + [data-look=neo].labelBkg { + background-color: ${j(e.tertiaryColor,.5)}; + } + + .cluster rect { + fill: ${e.clusterBkg??e.mainBkg}; + stroke: ${e.clusterBorder??e.nodeBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor??e.textColor}; + } + + .cluster-label text { + fill: ${e.titleColor??e.textColor}; + } +`},`getStyles`)};export{N as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/eventmodeling-NTZA5JFV-CetGhGTA.js b/frontend/dist/assets/eventmodeling-NTZA5JFV-CetGhGTA.js new file mode 100644 index 0000000..8d0a5c9 --- /dev/null +++ b/frontend/dist/assets/eventmodeling-NTZA5JFV-CetGhGTA.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{O as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createEventModelingServices}; \ No newline at end of file diff --git a/frontend/dist/assets/flowDiagram-KWPJA3E3-BO7njBlM.js b/frontend/dist/assets/flowDiagram-KWPJA3E3-BO7njBlM.js new file mode 100644 index 0000000..65689a0 --- /dev/null +++ b/frontend/dist/assets/flowDiagram-KWPJA3E3-BO7njBlM.js @@ -0,0 +1 @@ +import"./src-D_iIdUkB.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import"./chunk-GWA4HPMP-C1P4FmAY.js";import"./chunk-XXDRQBXY-C1_eEj17.js";import"./chunk-WEXAMYUT-I3m-hOmT.js";import{n as e}from"./chunk-7M6MHVWA-ZnPgs1Wx.js";export{e as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js b/frontend/dist/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js new file mode 100644 index 0000000..b28dee7 --- /dev/null +++ b/frontend/dist/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js @@ -0,0 +1,292 @@ +import{_ as e,a as t,c as n,d as r,f as i,g as a,i as o,m as s,p as c,s as l,u,y as d}from"./src-D_iIdUkB.js";import{n as f}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as p,U as m,a as h,c as g,q as _,s as v,v as y,w as b,x,y as S}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as C,i as w,n as T,r as E,t as D}from"./linear-CZ6dxGrP.js";import{t as O}from"./init-C-OQMol4.js";import{t as k}from"./dist-Bfr8PhAA.js";import{g as ee}from"./chunk-ZIGJFQKS-BJ6myxnF.js";function A(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function te(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function ne(e){return e}var j=1,re=2,ie=3,ae=4,oe=1e-6;function se(e){return`translate(`+e+`,0)`}function ce(e){return`translate(0,`+e+`)`}function le(e){return t=>+e(t)}function ue(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function de(){return!this.__axis}function fe(e,t){var n=[],r=null,i=null,a=6,o=6,s=3,c=typeof window<`u`&&window.devicePixelRatio>1?0:.5,l=e===j||e===ae?-1:1,u=e===ae||e===re?`x`:`y`,d=e===j||e===ie?se:ce;function f(f){var p=r??(t.ticks?t.ticks.apply(t,n):t.domain()),m=i??(t.tickFormat?t.tickFormat.apply(t,n):ne),h=Math.max(a,0)+s,g=t.range(),_=+g[0]+c,v=+g[g.length-1]+c,y=(t.bandwidth?ue:le)(t.copy(),c),b=f.selection?f.selection():f,x=b.selectAll(`.domain`).data([null]),S=b.selectAll(`.tick`).data(p,t).order(),C=S.exit(),w=S.enter().append(`g`).attr(`class`,`tick`),T=S.select(`line`),E=S.select(`text`);x=x.merge(x.enter().insert(`path`,`.tick`).attr(`class`,`domain`).attr(`stroke`,`currentColor`)),S=S.merge(w),T=T.merge(w.append(`line`).attr(`stroke`,`currentColor`).attr(u+`2`,l*a)),E=E.merge(w.append(`text`).attr(`fill`,`currentColor`).attr(u,l*h).attr(`dy`,e===j?`0em`:e===ie?`0.71em`:`0.32em`)),f!==b&&(x=x.transition(f),S=S.transition(f),T=T.transition(f),E=E.transition(f),C=C.transition(f).attr(`opacity`,oe).attr(`transform`,function(e){return isFinite(e=y(e))?d(e+c):this.getAttribute(`transform`)}),w.attr(`opacity`,oe).attr(`transform`,function(e){var t=this.parentNode.__axis;return d((t&&isFinite(t=t(e))?t:y(e))+c)})),C.remove(),x.attr(`d`,e===ae||e===re?o?`M`+l*o+`,`+_+`H`+c+`V`+v+`H`+l*o:`M`+c+`,`+_+`V`+v:o?`M`+_+`,`+l*o+`V`+c+`H`+v+`V`+l*o:`M`+_+`,`+c+`H`+v),S.attr(`opacity`,1).attr(`transform`,function(e){return d(y(e)+c)}),T.attr(u+`2`,l*a),E.attr(u,l*h).text(m),b.filter(de).attr(`fill`,`none`).attr(`font-size`,10).attr(`font-family`,`sans-serif`).attr(`text-anchor`,e===re?`start`:e===ae?`end`:`middle`),b.each(function(){this.__axis=y})}return f.scale=function(e){return arguments.length?(t=e,f):t},f.ticks=function(){return n=Array.from(arguments),f},f.tickArguments=function(e){return arguments.length?(n=e==null?[]:Array.from(e),f):n.slice()},f.tickValues=function(e){return arguments.length?(r=e==null?null:Array.from(e),f):r&&r.slice()},f.tickFormat=function(e){return arguments.length?(i=e,f):i},f.tickSize=function(e){return arguments.length?(a=o=+e,f):a},f.tickSizeInner=function(e){return arguments.length?(a=+e,f):a},f.tickSizeOuter=function(e){return arguments.length?(o=+e,f):o},f.tickPadding=function(e){return arguments.length?(s=+e,f):s},f.offset=function(e){return arguments.length?(c=+e,f):c},f}function pe(e){return fe(j,e)}function me(e){return fe(ie,e)}var he=Math.PI/180,ge=180/Math.PI,_e=18,ve=.96422,ye=1,be=.82521,xe=4/29,Se=6/29,Ce=3*Se*Se,we=Se*Se*Se;function Te(e){if(e instanceof M)return new M(e.l,e.a,e.b,e.opacity);if(e instanceof N)return Ne(e);e instanceof n||(e=u(e));var t=Ae(e.r),r=Ae(e.g),i=Ae(e.b),a=De((.2225045*t+.7168786*r+.0606169*i)/ye),o,s;return t===r&&r===i?o=s=a:(o=De((.4360747*t+.3850649*r+.1430804*i)/ve),s=De((.0139322*t+.0971045*r+.7141733*i)/be)),new M(116*a-16,500*(o-a),200*(a-s),e.opacity)}function Ee(e,t,n,r){return arguments.length===1?Te(e):new M(e,t,n,r??1)}function M(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}r(M,Ee,i(l,{brighter(e){return new M(this.l+_e*(e??1),this.a,this.b,this.opacity)},darker(e){return new M(this.l-_e*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,r=isNaN(this.b)?e:e-this.b/200;return t=ve*Oe(t),e=ye*Oe(e),r=be*Oe(r),new n(ke(3.1338561*t-1.6168667*e-.4906146*r),ke(-.9787684*t+1.9161415*e+.033454*r),ke(.0719453*t-.2289914*e+1.4052427*r),this.opacity)}}));function De(e){return e>we?e**(1/3):e/Ce+xe}function Oe(e){return e>Se?e*e*e:Ce*(e-xe)}function ke(e){return 255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055)}function Ae(e){return(e/=255)<=.04045?e/12.92:((e+.055)/1.055)**2.4}function je(e){if(e instanceof N)return new N(e.h,e.c,e.l,e.opacity);if(e instanceof M||(e=Te(e)),e.a===0&&e.b===0)return new N(NaN,0(e(t=new Date(+t)),t),i.ceil=n=>(e(n=new Date(n-1)),t(n,1),e(n),n),i.round=e=>{let t=i(e),n=i.ceil(e);return e-t(t(e=new Date(+e),n==null?1:Math.floor(n)),e),i.range=(n,r,a)=>{let o=[];if(n=i.ceil(n),a=a==null?1:Math.floor(a),!(n0))return o;let s;do o.push(s=new Date(+n)),t(n,a),e(n);while(sP(t=>{if(t>=t)for(;e(t),!n(t);)t.setTime(t-1)},(e,r)=>{if(e>=e){if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}}),n&&(i.count=(t,r)=>(Le.setTime(+t),Re.setTime(+r),e(Le),e(Re),Math.floor(n(Le,Re))),i.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?i.filter(r?t=>r(t)%e===0:t=>i.count(0,t)%e===0):i)),i}var ze=P(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);ze.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?P(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):ze),ze.range;var F=1e3,I=F*60,L=I*60,R=L*24,Be=R*7,Ve=R*30,He=R*365,z=P(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*F)},(e,t)=>(t-e)/F,e=>e.getUTCSeconds());z.range;var Ue=P(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*F)},(e,t)=>{e.setTime(+e+t*I)},(e,t)=>(t-e)/I,e=>e.getMinutes());Ue.range;var We=P(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*I)},(e,t)=>(t-e)/I,e=>e.getUTCMinutes());We.range;var Ge=P(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*F-e.getMinutes()*I)},(e,t)=>{e.setTime(+e+t*L)},(e,t)=>(t-e)/L,e=>e.getHours());Ge.range;var Ke=P(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*L)},(e,t)=>(t-e)/L,e=>e.getUTCHours());Ke.range;var B=P(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*I)/R,e=>e.getDate()-1);B.range;var qe=P(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/R,e=>e.getUTCDate()-1);qe.range;var Je=P(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/R,e=>Math.floor(e/R));Je.range;function V(e){return P(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(e,t)=>{e.setDate(e.getDate()+t*7)},(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*I)/Be)}var Ye=V(0),Xe=V(1),Ze=V(2),Qe=V(3),H=V(4),$e=V(5),et=V(6);Ye.range,Xe.range,Ze.range,Qe.range,H.range,$e.range,et.range;function U(e){return P(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t*7)},(e,t)=>(t-e)/Be)}var tt=U(0),nt=U(1),rt=U(2),it=U(3),at=U(4),ot=U(5),st=U(6);tt.range,nt.range,rt.range,it.range,at.range,ot.range,st.range;var ct=P(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());ct.range;var lt=P(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());lt.range;var W=P(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());W.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:P(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),W.range;var G=P(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());G.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:P(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),G.range;function ut(e,t,n,r,i,a){let o=[[z,1,F],[z,5,5*F],[z,15,15*F],[z,30,30*F],[a,1,I],[a,5,5*I],[a,15,15*I],[a,30,30*I],[i,1,L],[i,3,3*L],[i,6,6*L],[i,12,12*L],[r,1,R],[r,2,2*R],[n,1,Be],[t,1,Ve],[t,3,3*Ve],[e,1,He]];function s(e,t,n){let r=te).right(o,i);if(a===o.length)return e.every(w(t/He,n/He,r));if(a===0)return ze.every(Math.max(w(t,n,r),1));let[s,c]=o[i/o[a-1][2]53)return null;`w`in r||(r.w=1),`Z`in r?(a=gt(_t(r.y,0,1)),o=a.getUTCDay(),a=o>4||o===0?nt.ceil(a):nt(a),a=qe.offset(a,(r.V-1)*7),r.y=a.getUTCFullYear(),r.m=a.getUTCMonth(),r.d=a.getUTCDate()+(r.w+6)%7):(a=ht(_t(r.y,0,1)),o=a.getDay(),a=o>4||o===0?Xe.ceil(a):Xe(a),a=B.offset(a,(r.V-1)*7),r.y=a.getFullYear(),r.m=a.getMonth(),r.d=a.getDate()+(r.w+6)%7)}else(`W`in r||`U`in r)&&(`w`in r||(r.w=`u`in r?r.u%7:+(`W`in r)),o=`Z`in r?gt(_t(r.y,0,1)).getUTCDay():ht(_t(r.y,0,1)).getDay(),r.m=0,r.d=`W`in r?(r.w+6)%7+r.W*7-(o+5)%7:r.w+r.U*7-(o+6)%7);return`Z`in r?(r.H+=r.Z/100|0,r.M+=r.Z%100,gt(r)):ht(r)}}function w(e,t,n,r){for(var i=0,a=t.length,o=n.length,s,c;i=o)return-1;if(s=t.charCodeAt(i++),s===37){if(s=t.charAt(i++),c=x[s in yt?t.charAt(i++):s],!c||(r=c(e,n,r))<0)return-1}else if(s!=n.charCodeAt(r++))return-1}return r}function T(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1}function E(e,t,n){var r=p.exec(t.slice(n));return r?(e.w=m.get(r[0].toLowerCase()),n+r[0].length):-1}function D(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f.get(r[0].toLowerCase()),n+r[0].length):-1}function O(e,t,n){var r=_.exec(t.slice(n));return r?(e.m=v.get(r[0].toLowerCase()),n+r[0].length):-1}function k(e,t,n){var r=h.exec(t.slice(n));return r?(e.m=g.get(r[0].toLowerCase()),n+r[0].length):-1}function ee(e,n,r){return w(e,t,n,r)}function A(e,t,r){return w(e,n,t,r)}function te(e,t,n){return w(e,r,t,n)}function ne(e){return o[e.getDay()]}function j(e){return a[e.getDay()]}function re(e){return c[e.getMonth()]}function ie(e){return s[e.getMonth()]}function ae(e){return i[+(e.getHours()>=12)]}function oe(e){return 1+~~(e.getMonth()/3)}function se(e){return o[e.getUTCDay()]}function ce(e){return a[e.getUTCDay()]}function le(e){return c[e.getUTCMonth()]}function ue(e){return s[e.getUTCMonth()]}function de(e){return i[+(e.getUTCHours()>=12)]}function fe(e){return 1+~~(e.getUTCMonth()/3)}return{format:function(e){var t=S(e+=``,y);return t.toString=function(){return e},t},parse:function(e){var t=C(e+=``,!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=S(e+=``,b);return t.toString=function(){return e},t},utcParse:function(e){var t=C(e+=``,!0);return t.toString=function(){return e},t}}}var yt={"-":``,_:` `,0:`0`},K=/^\s*\d+/,bt=/^%/,xt=/[\\^$*+?|[\]().{}]/g;function q(e,t,n){var r=e<0?`-`:``,i=(r?-e:e)+``,a=i.length;return r+(a[e.toLowerCase(),t]))}function Tt(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Et(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function Dt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function Ot(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function kt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function At(e,t,n){var r=K.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function jt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Mt(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||`00`)),n+r[0].length):-1}function Nt(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function Pt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Ft(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function It(e,t,n){var r=K.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Lt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Rt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function zt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Bt(e,t,n){var r=K.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Vt(e,t,n){var r=K.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ht(e,t,n){var r=bt.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Ut(e,t,n){var r=K.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function Wt(e,t,n){var r=K.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Gt(e,t){return q(e.getDate(),t,2)}function Kt(e,t){return q(e.getHours(),t,2)}function qt(e,t){return q(e.getHours()%12||12,t,2)}function Jt(e,t){return q(1+B.count(W(e),e),t,3)}function Yt(e,t){return q(e.getMilliseconds(),t,3)}function Xt(e,t){return Yt(e,t)+`000`}function Zt(e,t){return q(e.getMonth()+1,t,2)}function Qt(e,t){return q(e.getMinutes(),t,2)}function $t(e,t){return q(e.getSeconds(),t,2)}function en(e){var t=e.getDay();return t===0?7:t}function tn(e,t){return q(Ye.count(W(e)-1,e),t,2)}function nn(e){var t=e.getDay();return t>=4||t===0?H(e):H.ceil(e)}function rn(e,t){return e=nn(e),q(H.count(W(e),e)+(W(e).getDay()===4),t,2)}function an(e){return e.getDay()}function on(e,t){return q(Xe.count(W(e)-1,e),t,2)}function sn(e,t){return q(e.getFullYear()%100,t,2)}function cn(e,t){return e=nn(e),q(e.getFullYear()%100,t,2)}function ln(e,t){return q(e.getFullYear()%1e4,t,4)}function un(e,t){var n=e.getDay();return e=n>=4||n===0?H(e):H.ceil(e),q(e.getFullYear()%1e4,t,4)}function dn(e){var t=e.getTimezoneOffset();return(t>0?`-`:(t*=-1,`+`))+q(t/60|0,`0`,2)+q(t%60,`0`,2)}function fn(e,t){return q(e.getUTCDate(),t,2)}function pn(e,t){return q(e.getUTCHours(),t,2)}function mn(e,t){return q(e.getUTCHours()%12||12,t,2)}function hn(e,t){return q(1+qe.count(G(e),e),t,3)}function gn(e,t){return q(e.getUTCMilliseconds(),t,3)}function _n(e,t){return gn(e,t)+`000`}function vn(e,t){return q(e.getUTCMonth()+1,t,2)}function yn(e,t){return q(e.getUTCMinutes(),t,2)}function bn(e,t){return q(e.getUTCSeconds(),t,2)}function xn(e){var t=e.getUTCDay();return t===0?7:t}function Sn(e,t){return q(tt.count(G(e)-1,e),t,2)}function Cn(e){var t=e.getUTCDay();return t>=4||t===0?at(e):at.ceil(e)}function wn(e,t){return e=Cn(e),q(at.count(G(e),e)+(G(e).getUTCDay()===4),t,2)}function Tn(e){return e.getUTCDay()}function En(e,t){return q(nt.count(G(e)-1,e),t,2)}function Dn(e,t){return q(e.getUTCFullYear()%100,t,2)}function On(e,t){return e=Cn(e),q(e.getUTCFullYear()%100,t,2)}function kn(e,t){return q(e.getUTCFullYear()%1e4,t,4)}function An(e,t){var n=e.getUTCDay();return e=n>=4||n===0?at(e):at.ceil(e),q(e.getUTCFullYear()%1e4,t,4)}function jn(){return`+0000`}function Mn(){return`%`}function Nn(e){return+e}function Pn(e){return Math.floor(e/1e3)}var Fn,In;Ln({dateTime:`%x, %X`,date:`%-m/%-d/%Y`,time:`%-I:%M:%S %p`,periods:[`AM`,`PM`],days:[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`],shortDays:[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],months:[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`],shortMonths:[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]});function Ln(e){return Fn=vt(e),In=Fn.format,Fn.parse,Fn.utcFormat,Fn.utcParse,Fn}function Rn(e){return new Date(e)}function zn(e){return e instanceof Date?+e:+new Date(+e)}function Bn(e,t,n,r,i,a,o,s,c,l){var u=T(),d=u.invert,f=u.domain,p=l(`.%L`),m=l(`:%S`),h=l(`%I:%M`),g=l(`%I %p`),_=l(`%a %d`),v=l(`%b %d`),y=l(`%B`),b=l(`%Y`);function x(e){return(c(e){(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_isoWeek=r()})(e,(function(){return function(e,t,n){var r=function(e){return e.add(4-e.isoWeekday(),`day`)},i=t.prototype;i.isoWeekYear=function(){return r(this).year()},i.isoWeek=function(e){if(!this.$utils().u(e))return this.add(7*(e-this.isoWeek()),`day`);var t,i,a,o,s=r(this),c=(t=this.isoWeekYear(),i=this.$u,a=(i?n.utc:n)().year(t).startOf(`year`),o=4-a.isoWeekday(),a.isoWeekday()>4&&(o+=7),a.add(o,`day`));return s.diff(c,`week`)+1},i.isoWeekday=function(e){return this.$utils().u(e)?this.day()||7:this.day(this.day()%7?e:e-7)};var a=i.startOf;i.startOf=function(e,t){var n=this.$utils(),r=!!n.u(t)||t;return n.p(e)===`isoweek`?r?this.date(this.date()-(this.isoWeekday()-1)).startOf(`day`):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf(`day`):a.bind(this)(e,t)}}}))})),Un=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_customParseFormat=r()})(e,(function(){var e={LTS:`h:mm:ss A`,LT:`h:mm A`,L:`MM/DD/YYYY`,LL:`MMMM D, YYYY`,LLL:`MMMM D, YYYY h:mm A`,LLLL:`dddd, MMMM D, YYYY h:mm A`},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n=/\d/,r=/\d\d/,i=/\d\d?/,a=/\d*[^-_:/,()\s\d]+/,o={},s=function(e){return(e=+e)+(e>68?1900:2e3)},c=function(e){return function(t){this[e]=+t}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||={}).offset=function(e){if(!e||e===`Z`)return 0;var t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return n===0?0:t[0]===`+`?-n:n}(e)}],u=function(e){var t=o[e];return t&&(t.indexOf?t:t.s.concat(t.f))},d=function(e,t){var n,r=o.meridiem;if(r){for(var i=1;i<=24;i+=1)if(e.indexOf(r(i,0,t))>-1){n=i>12;break}}else n=e===(t?`pm`:`PM`);return n},f={A:[a,function(e){this.afternoon=d(e,!1)}],a:[a,function(e){this.afternoon=d(e,!0)}],Q:[n,function(e){this.month=3*(e-1)+1}],S:[n,function(e){this.milliseconds=100*e}],SS:[r,function(e){this.milliseconds=10*e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[i,c(`seconds`)],ss:[i,c(`seconds`)],m:[i,c(`minutes`)],mm:[i,c(`minutes`)],H:[i,c(`hours`)],h:[i,c(`hours`)],HH:[i,c(`hours`)],hh:[i,c(`hours`)],D:[i,c(`day`)],DD:[r,c(`day`)],Do:[a,function(e){var t=o.ordinal,n=e.match(/\d+/);if(this.day=n[0],t)for(var r=1;r<=31;r+=1)t(r).replace(/\[|\]/g,``)===e&&(this.day=r)}],w:[i,c(`week`)],ww:[r,c(`week`)],M:[i,c(`month`)],MM:[r,c(`month`)],MMM:[a,function(e){var t=u(`months`),n=(u(`monthsShort`)||t.map((function(e){return e.slice(0,3)}))).indexOf(e)+1;if(n<1)throw Error();this.month=n%12||n}],MMMM:[a,function(e){var t=u(`months`).indexOf(e)+1;if(t<1)throw Error();this.month=t%12||t}],Y:[/[+-]?\d+/,c(`year`)],YY:[r,function(e){this.year=s(e)}],YYYY:[/\d{4}/,c(`year`)],Z:l,ZZ:l};function p(n){for(var r=n,i=o&&o.formats,a=(n=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(t,n,r){var a=r&&r.toUpperCase();return n||i[r]||e[r]||i[a].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(e,t,n){return t||n.slice(1)}))}))).match(t),s=a.length,c=0;c-1)return new Date((t===`X`?1e3:1)*e);var i=p(t)(e),a=i.year,o=i.month,s=i.day,c=i.hours,l=i.minutes,u=i.seconds,d=i.milliseconds,f=i.zone,m=i.week,h=new Date,g=s||(a||o?1:h.getDate()),_=a||h.getFullYear(),v=0;a&&!o||(v=o>0?o-1:h.getMonth());var y,b=c||0,x=l||0,S=u||0,C=d||0;return f?new Date(Date.UTC(_,v,g,b,x,S,C+60*f.offset*1e3)):n?new Date(Date.UTC(_,v,g,b,x,S,C)):(y=new Date(_,v,g,b,x,S,C),m&&(y=r(y).week(m).toDate()),y)}catch{return new Date(``)}}(t,s,r,n),this.init(),d&&!0!==d&&(this.$L=this.locale(d).$L),u&&t!=this.format(s)&&(this.$d=new Date(``)),o={}}else if(s instanceof Array)for(var f=s.length,m=1;m<=f;m+=1){a[1]=s[m-1];var h=n.apply(this,a);if(h.isValid()){this.$d=h.$d,this.$L=h.$L,this.init();break}m===f&&(this.$d=new Date(``))}else i.call(this,e)}}}))})),Wn=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_advancedFormat=r()})(e,(function(){return function(e,t){var n=t.prototype,r=n.format;n.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return r.bind(this)(e);var i=this.$utils(),a=(e||`YYYY-MM-DDTHH:mm:ssZ`).replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(e){switch(e){case`Q`:return Math.ceil((t.$M+1)/3);case`Do`:return n.ordinal(t.$D);case`gggg`:return t.weekYear();case`GGGG`:return t.isoWeekYear();case`wo`:return n.ordinal(t.week(),`W`);case`w`:case`ww`:return i.s(t.week(),e===`w`?1:2,`0`);case`W`:case`WW`:return i.s(t.isoWeek(),e===`W`?1:2,`0`);case`k`:case`kk`:return i.s(String(t.$H===0?24:t.$H),e===`k`?1:2,`0`);case`X`:return Math.floor(t.$d.getTime()/1e3);case`x`:return t.$d.getTime();case`z`:return`[`+t.offsetName()+`]`;case`zzz`:return`[`+t.offsetName(`long`)+`]`;default:return e}}));return r.bind(this)(a)}}}))})),Gn=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_duration=r()})(e,(function(){var e,t,n=1e3,r=6e4,i=36e5,a=864e5,o=31536e6,s=2628e6,c=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,l=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,u={years:o,months:s,days:a,hours:i,minutes:r,seconds:n,milliseconds:1,weeks:6048e5},d=function(e){return e instanceof v},f=function(e,t,n){return new v(e,n,t.$l)},p=function(e){return t.p(e)+`s`},m=function(e){return e<0},h=function(e){return m(e)?Math.ceil(e):Math.floor(e)},g=function(e){return Math.abs(e)},_=function(e,t){return e?m(e)?{negative:!0,format:``+g(e)+t}:{negative:!1,format:``+e+t}:{negative:!1,format:``}},v=function(){function m(e,t,n){var r=this;if(this.$d={},this.$l=n,e===void 0&&(this.$ms=0,this.parseFromMilliseconds()),t)return f(e*u[p(t)],this);if(typeof e==`number`)return this.$ms=e,this.parseFromMilliseconds(),this;if(typeof e==`object`)return Object.keys(e).forEach((function(t){r.$d[p(t)]=e[t]})),this.calMilliseconds(),this;if(typeof e==`string`){var i=e.match(c);if(i){var a=i.slice(2).map((function(e){return e==null?0:Number(e)}));return this.$d.years=a[0],this.$d.months=a[1],this.$d.weeks=a[2],this.$d.days=a[3],this.$d.hours=a[4],this.$d.minutes=a[5],this.$d.seconds=a[6],this.calMilliseconds(),this}}return this}var g=m.prototype;return g.calMilliseconds=function(){var e=this;this.$ms=Object.keys(this.$d).reduce((function(t,n){return t+(e.$d[n]||0)*u[n]}),0)},g.parseFromMilliseconds=function(){var e=this.$ms;this.$d.years=h(e/o),e%=o,this.$d.months=h(e/s),e%=s,this.$d.days=h(e/a),e%=a,this.$d.hours=h(e/i),e%=i,this.$d.minutes=h(e/r),e%=r,this.$d.seconds=h(e/n),e%=n,this.$d.milliseconds=e},g.toISOString=function(){var e=_(this.$d.years,`Y`),t=_(this.$d.months,`M`),n=+this.$d.days||0;this.$d.weeks&&(n+=7*this.$d.weeks);var r=_(n,`D`),i=_(this.$d.hours,`H`),a=_(this.$d.minutes,`M`),o=this.$d.seconds||0;this.$d.milliseconds&&(o+=this.$d.milliseconds/1e3,o=Math.round(1e3*o)/1e3);var s=_(o,`S`),c=e.negative||t.negative||r.negative||i.negative||a.negative||s.negative,l=i.format||a.format||s.format?`T`:``,u=(c?`-`:``)+`P`+e.format+t.format+r.format+l+i.format+a.format+s.format;return u===`P`||u===`-P`?`P0D`:u},g.toJSON=function(){return this.toISOString()},g.format=function(e){var n=e||`YYYY-MM-DDTHH:mm:ss`,r={Y:this.$d.years,YY:t.s(this.$d.years,2,`0`),YYYY:t.s(this.$d.years,4,`0`),M:this.$d.months,MM:t.s(this.$d.months,2,`0`),D:this.$d.days,DD:t.s(this.$d.days,2,`0`),H:this.$d.hours,HH:t.s(this.$d.hours,2,`0`),m:this.$d.minutes,mm:t.s(this.$d.minutes,2,`0`),s:this.$d.seconds,ss:t.s(this.$d.seconds,2,`0`),SSS:t.s(this.$d.milliseconds,3,`0`)};return n.replace(l,(function(e,t){return t||String(r[e])}))},g.as=function(e){return this.$ms/u[p(e)]},g.get=function(e){var t=this.$ms,n=p(e);return n===`milliseconds`?t%=1e3:t=n===`weeks`?h(t/u[n]):this.$d[n],t||0},g.add=function(e,t,n){var r;return r=t?e*u[p(t)]:d(e)?e.$ms:f(e,this).$ms,f(this.$ms+r*(n?-1:1),this)},g.subtract=function(e,t){return this.add(e,t,!0)},g.locale=function(e){var t=this.clone();return t.$l=e,t},g.clone=function(){return f(this.$ms,this)},g.humanize=function(t){return e().add(this.$ms,`ms`).locale(this.$l).fromNow(!t)},g.valueOf=function(){return this.asMilliseconds()},g.milliseconds=function(){return this.get(`milliseconds`)},g.asMilliseconds=function(){return this.as(`milliseconds`)},g.seconds=function(){return this.get(`seconds`)},g.asSeconds=function(){return this.as(`seconds`)},g.minutes=function(){return this.get(`minutes`)},g.asMinutes=function(){return this.as(`minutes`)},g.hours=function(){return this.get(`hours`)},g.asHours=function(){return this.as(`hours`)},g.days=function(){return this.get(`days`)},g.asDays=function(){return this.as(`days`)},g.weeks=function(){return this.get(`weeks`)},g.asWeeks=function(){return this.as(`weeks`)},g.months=function(){return this.get(`months`)},g.asMonths=function(){return this.as(`months`)},g.years=function(){return this.get(`years`)},g.asYears=function(){return this.as(`years`)},m}(),y=function(e,t,n){return e.add(t.years()*n,`y`).add(t.months()*n,`M`).add(t.days()*n,`d`).add(t.hours()*n,`h`).add(t.minutes()*n,`m`).add(t.seconds()*n,`s`).add(t.milliseconds()*n,`ms`)};return function(n,r,i){e=i,t=i().$utils(),i.duration=function(e,t){return f(e,{$l:i.locale()},t)},i.isDuration=d;var a=r.prototype.add,o=r.prototype.subtract;r.prototype.add=function(e,t){return d(e)?y(this,e,1):a.bind(this)(e,t)},r.prototype.subtract=function(e,t){return d(e)?y(this,e,-1):o.bind(this)(e,t)}}}))})),Kn=k(),J=d(a(),1),qn=d(Hn(),1),Jn=d(Un(),1),Yn=d(Wn(),1),Xn=d(Gn(),1),Zn=(function(){var e=f(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],n=[1,26],r=[1,27],i=[1,28],a=[1,29],o=[1,30],s=[1,31],c=[1,32],l=[1,33],u=[1,34],d=[1,9],p=[1,10],m=[1,11],h=[1,12],g=[1,13],_=[1,14],v=[1,15],y=[1,16],b=[1,19],x=[1,20],S=[1,21],C=[1,22],w=[1,23],T=[1,25],E=[1,35],D={trace:f(function(){},`trace`),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:`error`,4:`gantt`,6:`EOF`,8:`SPACE`,10:`NL`,12:`weekday_monday`,13:`weekday_tuesday`,14:`weekday_wednesday`,15:`weekday_thursday`,16:`weekday_friday`,17:`weekday_saturday`,18:`weekday_sunday`,20:`weekend_friday`,21:`weekend_saturday`,22:`dateFormat`,23:`inclusiveEndDates`,24:`topAxis`,25:`axisFormat`,26:`tickInterval`,27:`excludes`,28:`includes`,29:`todayMarker`,30:`title`,31:`acc_title`,32:`acc_title_value`,33:`acc_descr`,34:`acc_descr_value`,35:`acc_descr_multiline_value`,36:`section`,38:`taskTxt`,39:`taskData`,40:`click`,41:`callbackname`,42:`callbackargs`,43:`href`},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:f(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:case 7:this.$=[];break;case 8:r.setWeekday(`monday`);break;case 9:r.setWeekday(`tuesday`);break;case 10:r.setWeekday(`wednesday`);break;case 11:r.setWeekday(`thursday`);break;case 12:r.setWeekday(`friday`);break;case 13:r.setWeekday(`saturday`);break;case 14:r.setWeekday(`sunday`);break;case 15:r.setWeekend(`friday`);break;case 16:r.setWeekend(`saturday`);break;case 17:r.setDateFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 18:r.enableInclusiveEndDates(),this.$=a[s].substr(18);break;case 19:r.TopAxis(),this.$=a[s].substr(8);break;case 20:r.setAxisFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 21:r.setTickInterval(a[s].substr(13)),this.$=a[s].substr(13);break;case 22:r.setExcludes(a[s].substr(9)),this.$=a[s].substr(9);break;case 23:r.setIncludes(a[s].substr(9)),this.$=a[s].substr(9);break;case 24:r.setTodayMarker(a[s].substr(12)),this.$=a[s].substr(12);break;case 27:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 28:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 29:case 30:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 31:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 33:r.addTask(a[s-1],a[s]),this.$=`task`;break;case 34:this.$=a[s-1],r.setClickEvent(a[s-1],a[s],null);break;case 35:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 36:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],null),r.setLink(a[s-2],a[s]);break;case 37:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setLink(a[s-3],a[s]);break;case 38:this.$=a[s-2],r.setClickEvent(a[s-2],a[s],null),r.setLink(a[s-2],a[s-1]);break;case 39:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-1],a[s]),r.setLink(a[s-3],a[s-2]);break;case 40:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 41:case 47:this.$=a[s-1]+` `+a[s];break;case 42:case 43:case 45:this.$=a[s-2]+` `+a[s-1]+` `+a[s];break;case 44:case 46:this.$=a[s-3]+` `+a[s-2]+` `+a[s-1]+` `+a[s]}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(t,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:i,15:a,16:o,17:s,18:c,19:18,20:l,21:u,22:d,23:p,24:m,25:h,26:g,27:_,28:v,29:y,30:b,31:x,33:S,35:C,36:w,37:24,38:T,40:E},e(t,[2,7],{1:[2,1]}),e(t,[2,3]),{9:36,11:17,12:n,13:r,14:i,15:a,16:o,17:s,18:c,19:18,20:l,21:u,22:d,23:p,24:m,25:h,26:g,27:_,28:v,29:y,30:b,31:x,33:S,35:C,36:w,37:24,38:T,40:E},e(t,[2,5]),e(t,[2,6]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,20]),e(t,[2,21]),e(t,[2,22]),e(t,[2,23]),e(t,[2,24]),e(t,[2,25]),e(t,[2,26]),e(t,[2,27]),{32:[1,37]},{34:[1,38]},e(t,[2,30]),e(t,[2,31]),e(t,[2,32]),{39:[1,39]},e(t,[2,8]),e(t,[2,9]),e(t,[2,10]),e(t,[2,11]),e(t,[2,12]),e(t,[2,13]),e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),{41:[1,40],43:[1,41]},e(t,[2,4]),e(t,[2,28]),e(t,[2,29]),e(t,[2,33]),e(t,[2,34],{42:[1,42],43:[1,43]}),e(t,[2,40],{41:[1,44]}),e(t,[2,35],{43:[1,45]}),e(t,[2,36]),e(t,[2,38],{42:[1,46]}),e(t,[2,37]),e(t,[2,39])],defaultActions:{},parseError:f(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:f(function(e){var t=this,n=[0],r=[],i=[null],a=[],o=this.table,s=``,c=0,l=0,u=0,d=2,p=1,m=a.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;a.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){n.length-=2*e,i.length-=e,a.length-=e}f(b,`popStack`);function x(){var e=r.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(r=e,e=r.pop()),e=t.symbols_[e]||e),e}f(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=n[n.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=o[w]&&o[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],o[w])this.terminals_[O]&&O>d&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(c+1)+`: +`+h.showPosition()+` +Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(c+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:n.push(S),i.push(h.yytext),a.push(h.yylloc),n.push(T[1]),S=null,C?(S=C,C=null):(l=h.yyleng,s=h.yytext,c=h.yylineno,v=h.yylloc,u>0&&u--);break;case 2:if(k=this.productions_[T[1]][1],D.$=i[i.length-k],D._$={first_line:a[a.length-(k||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(k||1)].first_column,last_column:a[a.length-1].last_column},y&&(D._$.range=[a[a.length-(k||1)].range[0],a[a.length-1].range[1]]),E=this.performAction.apply(D,[s,l,c,g.yy,T[1],i,a].concat(m)),E!==void 0)return E;k&&(n=n.slice(0,-1*k*2),i=i.slice(0,-1*k),a=a.slice(0,-1*k)),n.push(this.productions_[T[1]][0]),i.push(D.$),a.push(D._$),ee=o[n[n.length-2]][n[n.length-1]],n.push(ee);break;case 3:return!0}}return!0},`parse`)};D.lexer=(function(){return{EOF:1,parseError:f(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:f(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:f(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:f(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:f(function(){return this._more=!0,this},`more`),reject:f(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:f(function(e){this.unput(this.match.slice(e))},`less`),pastInput:f(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:f(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:f(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:f(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:f(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:f(function(){return this.next()||this.lex()},`lex`),begin:f(function(e){this.conditionStack.push(e)},`begin`),popState:f(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:f(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:f(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:f(function(e){this.begin(e)},`pushState`),stateStackSize:f(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:f(function(e,t,n,r){switch(n){case 0:return this.begin(`open_directive`),`open_directive`;case 1:return this.begin(`acc_title`),31;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),33;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:break;case 9:break;case 10:break;case 11:return 10;case 12:break;case 13:break;case 14:this.begin(`href`);break;case 15:this.popState();break;case 16:return 43;case 17:this.begin(`callbackname`);break;case 18:this.popState();break;case 19:this.popState(),this.begin(`callbackargs`);break;case 20:return 41;case 21:this.popState();break;case 22:return 42;case 23:this.begin(`click`);break;case 24:this.popState();break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return`date`;case 45:return 30;case 46:return`accDescription`;case 47:return 36;case 48:return 38;case 49:return 39;case 50:return`:`;case 51:return 6;case 52:return`INVALID`}},`anonymous`),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}})();function O(){this.yy={}}return f(O,`Parser`),O.prototype=D,D.Parser=O,new O})();Zn.parser=Zn;var Qn=Zn;J.default.extend(qn.default),J.default.extend(Jn.default),J.default.extend(Yn.default);var $n={friday:5,saturday:6},Y=``,er=``,tr=void 0,nr=``,rr=[],ir=[],ar=new Map,or=[],sr=[],X=``,cr=``,lr=[`active`,`done`,`crit`,`milestone`,`vert`],ur=[],dr=``,fr=!1,pr=!1,mr=`sunday`,hr=`saturday`,gr=0,_r=f(function(){or=[],sr=[],X=``,ur=[],Zr=0,ti=void 0,ni=void 0,Z=[],Y=``,er=``,cr=``,tr=void 0,nr=``,rr=[],ir=[],fr=!1,pr=!1,gr=0,ar=new Map,dr=``,h(),mr=`sunday`,hr=`saturday`},`clear`),vr=f(function(e){dr=e},`setDiagramId`),yr=f(function(e){er=e},`setAxisFormat`),br=f(function(){return er},`getAxisFormat`),xr=f(function(e){tr=e},`setTickInterval`),Sr=f(function(){return tr},`getTickInterval`),Cr=f(function(e){nr=e},`setTodayMarker`),wr=f(function(){return nr},`getTodayMarker`),Tr=f(function(e){Y=e},`setDateFormat`),Er=f(function(){fr=!0},`enableInclusiveEndDates`),Dr=f(function(){return fr},`endDatesAreInclusive`),Or=f(function(){pr=!0},`enableTopAxis`),kr=f(function(){return pr},`topAxisEnabled`),Ar=f(function(e){cr=e},`setDisplayMode`),jr=f(function(){return cr},`getDisplayMode`),Mr=f(function(){return Y},`getDateFormat`),Nr=f((e,t)=>{let n=t.toLowerCase().split(/[\s,]+/).filter(e=>e!==``);return[...new Set([...e,...n])]},`mergeTokens`),Pr=f(function(e){rr=Nr(rr,e)},`setIncludes`),Fr=f(function(){return rr},`getIncludes`),Ir=f(function(e){ir=Nr(ir,e)},`setExcludes`),Lr=f(function(){return ir},`getExcludes`),Rr=f(function(){return ar},`getLinks`),zr=f(function(e){X=e,or.push(e)},`addSection`),Br=f(function(){return or},`getSections`),Vr=f(function(){let e=oi(),t=0;for(;!e&&t<10;)e=oi(),t++;return sr=Z,sr},`getTasks`),Hr=f(function(e,t,n,r){let i=e.format(t.trim()),a=e.format(`YYYY-MM-DD`);return r.includes(i)||r.includes(a)?!1:n.includes(`weekends`)&&(e.isoWeekday()===$n[hr]||e.isoWeekday()===$n[hr]+1)||n.includes(e.format(`dddd`).toLowerCase())?!0:n.includes(i)||n.includes(a)},`isInvalidDate`),Ur=f(function(e){mr=e},`setWeekday`),Wr=f(function(){return mr},`getWeekday`),Gr=f(function(e){hr=e},`setWeekend`),Kr=f(function(e,t,n,r){if(!n.length||e.manualEndTime)return;let i;i=e.startTime instanceof Date?(0,J.default)(e.startTime):(0,J.default)(e.startTime,t,!0),i=i.add(1,`d`);let a;a=e.endTime instanceof Date?(0,J.default)(e.endTime):(0,J.default)(e.endTime,t,!0);let[o,s]=qr(i,a,t,n,r);e.endTime=o.toDate(),e.renderEndTime=s},`checkTaskDates`),qr=f(function(e,t,n,r,i){let a=!1,o=null,s=t.add(1e4,`d`);for(;e<=t;){if(a||(o=t.toDate()),a=Hr(e,n,r,i),a&&(t=t.add(1,`d`),t>s))throw Error("Failed to find a valid date that was not excluded by `excludes` after 10,000 iterations.");e=e.add(1,`d`)}return[t,o]},`fixTaskDates`),Jr=f(function(e,t,n){if(n=n.trim(),f(e=>{let t=e.trim();return t===`x`||t===`X`},`isTimestampFormat`)(t)&&/^\d+$/.test(n))return new Date(Number(n));let r=/^after\s+(?[\d\w- ]+)/.exec(n);if(r!==null){let e=null;for(let t of r.groups.ids.split(` `)){let n=Q(t);n!==void 0&&(!e||n.endTime>e.endTime)&&(e=n)}if(e)return e.endTime;let t=new Date;return t.setHours(0,0,0,0),t}let i=(0,J.default)(n,t.trim(),!0);if(i.isValid())return i.toDate();{s.debug(`Invalid date:`+n),s.debug(`With date format:`+t.trim());let e=new Date(n);if(e===void 0||isNaN(e.getTime())||e.getFullYear()<-1e4||e.getFullYear()>1e4)throw Error(`Invalid date:`+n);return e}},`getStartDate`),Yr=f(function(e){let t=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(e.trim());return t===null?[NaN,`ms`]:[Number.parseFloat(t[1]),t[2]]},`parseDuration`),Xr=f(function(e,t,n,r=!1){n=n.trim();let i=/^until\s+(?[\d\w- ]+)/.exec(n);if(i!==null){let e=null;for(let t of i.groups.ids.split(` `)){let n=Q(t);n!==void 0&&(!e||n.startTime{window.open(n,`_self`)}),ar.set(e,n))}),ci(e,`clickable`)},`setLink`),ci=f(function(e,t){e.split(`,`).forEach(function(e){let n=Q(e);n!==void 0&&n.classes.push(t)})},`setClass`),li=f(function(e,t,n){if(x().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{ee.runFunc(t,...r)})},`setClickFun`),ui=f(function(e,t){ur.push(function(){let n=dr?`${dr}-${e}`:e,r=document.querySelector(`[id="${n}"]`);r!==null&&r.addEventListener(`click`,function(){t()})},function(){let n=dr?`${dr}-${e}`:e,r=document.querySelector(`[id="${n}-text"]`);r!==null&&r.addEventListener(`click`,function(){t()})})},`pushFun`),di={getConfig:f(()=>x().gantt,`getConfig`),clear:_r,setDateFormat:Tr,getDateFormat:Mr,enableInclusiveEndDates:Er,endDatesAreInclusive:Dr,enableTopAxis:Or,topAxisEnabled:kr,setAxisFormat:yr,getAxisFormat:br,setTickInterval:xr,getTickInterval:Sr,setTodayMarker:Cr,getTodayMarker:wr,setAccTitle:m,getAccTitle:S,setDiagramTitle:_,getDiagramTitle:b,setDiagramId:vr,setDisplayMode:Ar,getDisplayMode:jr,setAccDescription:p,getAccDescription:y,addSection:zr,getSections:Br,getTasks:Vr,addTask:ii,findTaskById:Q,addTaskOrg:ai,setIncludes:Pr,getIncludes:Fr,setExcludes:Ir,getExcludes:Lr,setClickEvent:f(function(e,t,n){e.split(`,`).forEach(function(e){li(e,t,n)}),ci(e,`clickable`)},`setClickEvent`),setLink:si,getLinks:Rr,bindFunctions:f(function(e){ur.forEach(function(t){t(e)})},`bindFunctions`),parseDuration:Yr,isInvalidDate:Hr,setWeekday:Ur,getWeekday:Wr,setWeekend:Gr};function fi(e,t,n){let r=!0;for(;r;)r=!1,n.forEach(function(n){let i=`^\\s*`+n+`\\s*$`,a=new RegExp(i);e[0].match(a)&&(t[n]=!0,e.shift(1),r=!0)})}f(fi,`getTaskTags`),J.default.extend(Xn.default);var pi=f(function(){s.debug(`Something is calling, setConf, remove the call`)},`setConf`),mi={monday:Xe,tuesday:Ze,wednesday:Qe,thursday:H,friday:$e,saturday:et,sunday:Ye},hi=f((e,t)=>{let n=[...e].map(()=>-1/0),r=[...e].sort((e,t)=>e.startTime-t.startTime||e.order-t.order),i=0;for(let e of r)for(let r=0;r=n[r]){n[r]=e.endTime,e.order=r+t,r>i&&(i=r);break}return i},`getMaxIntersections`),$,gi=1e4,_i={parser:Qn,db:di,renderer:{setConf:pi,draw:f(function(e,t,n,r){let i=x().gantt;r.db.setDiagramId(t);let a=x().securityLevel,o;a===`sandbox`&&(o=c(`#i`+t));let l=c(a===`sandbox`?o.nodes()[0].contentDocument.body:`body`),u=a===`sandbox`?o.nodes()[0].contentDocument:document,d=u.getElementById(t);$=d.parentElement.offsetWidth,$===void 0&&($=1200),i.useWidth!==void 0&&($=i.useWidth);let p=r.db.getTasks(),m=p.filter(e=>!e.vert),h=[];for(let e of m)h.push(e.type);h=j(h);let _={},y=2*i.topPadding;if(r.db.getDisplayMode()===`compact`||i.displayMode===`compact`){let e={};for(let t of m)e[t.section]===void 0?e[t.section]=[t]:e[t.section].push(t);let t=0;for(let n of Object.keys(e)){let r=hi(e[n],t)+1;t+=r,y+=r*(i.barHeight+i.barGap),_[n]=r}}else{y+=m.length*(i.barHeight+i.barGap);for(let e of h)_[e]=m.filter(t=>t.type===e).length}d.setAttribute(`viewBox`,`0 0 `+$+` `+y);let b=l.select(`[id="${t}"]`),S=Vn().domain([te(p,function(e){return e.startTime}),A(p,function(e){return e.endTime})]).rangeRound([0,$-i.leftPadding-i.rightPadding]);function C(e,t){let n=e.startTime,r=t.startTime,i=0;return n>r?i=1:ne.vert===t.vert?0:e.vert?1:-1);let d=e.filter(e=>!e.vert),f=[...new Set(d.map(e=>e.order))].map(e=>d.find(t=>t.order===e));b.append(`g`).selectAll(`rect`).data(f).enter().append(`rect`).attr(`x`,0).attr(`y`,function(e,t){return t=e.order,t*n+a-2}).attr(`width`,function(){return u-i.rightPadding/2}).attr(`height`,n).attr(`class`,function(e){for(let[t,n]of h.entries())if(e.type===n)return`section section`+t%i.numberSectionStyles;return`section section0`}).enter();let p=b.append(`g`).selectAll(`rect`).data(e).enter(),m=r.db.getLinks();if(p.append(`rect`).attr(`id`,function(e){return t+`-`+e.id}).attr(`rx`,3).attr(`ry`,3).attr(`x`,function(e){return e.milestone?S(e.startTime)+o+.5*(S(e.endTime)-S(e.startTime))-.5*s:S(e.startTime)+o}).attr(`y`,function(e,t){return t=e.order,e.vert?i.gridLineStartPadding:t*n+a}).attr(`width`,function(e){return e.milestone?s:e.vert?.08*s:S(e.renderEndTime||e.endTime)-S(e.startTime)}).attr(`height`,function(e){return e.vert?d.length*(i.barHeight+i.barGap)+i.barHeight*2:s}).attr(`transform-origin`,function(e,t){return t=e.order,(S(e.startTime)+o+.5*(S(e.endTime)-S(e.startTime))).toString()+`px `+(t*n+a+.5*s).toString()+`px`}).attr(`class`,function(e){let t=``;e.classes.length>0&&(t=e.classes.join(` `));let n=0;for(let[t,r]of h.entries())e.type===r&&(n=t%i.numberSectionStyles);let r=``;return e.active?e.crit?r+=` activeCrit`:r=` active`:e.done?r=e.crit?` doneCrit`:` done`:e.crit&&(r+=` crit`),r.length===0&&(r=` task`),e.milestone&&(r=` milestone `+r),e.vert&&(r=` vert `+r),r+=n,r+=` `+t,`task`+r}),p.append(`text`).attr(`id`,function(e){return t+`-`+e.id+`-text`}).text(function(e){return e.task}).attr(`font-size`,i.fontSize).attr(`x`,function(e){let t=S(e.startTime),n=S(e.renderEndTime||e.endTime);if(e.milestone&&(t+=.5*(S(e.endTime)-S(e.startTime))-.5*s,n=t+s),e.vert)return S(e.startTime)+o;let r=this.getBBox().width;return r>n-t?n+r+1.5*i.leftPadding>u?t+o-5:n+o+5:(n-t)/2+t+o}).attr(`y`,function(e,t){return e.vert?i.gridLineStartPadding+d.length*(i.barHeight+i.barGap)+60:(t=e.order,t*n+i.barHeight/2+(i.fontSize/2-2)+a)}).attr(`text-height`,s).attr(`class`,function(e){let t=S(e.startTime),n=S(e.endTime);e.milestone&&(n=t+s);let r=this.getBBox().width,a=``;e.classes.length>0&&(a=e.classes.join(` `));let o=0;for(let[t,n]of h.entries())e.type===n&&(o=t%i.numberSectionStyles);let c=``;return e.active&&(c=e.crit?`activeCritText`+o:`activeText`+o),e.done?c=e.crit?c+` doneCritText`+o:c+` doneText`+o:e.crit&&(c=c+` critText`+o),e.milestone&&(c+=` milestoneText`),e.vert&&(c+=` vertText`),r>n-t?n+r+1.5*i.leftPadding>u?a+` taskTextOutsideLeft taskTextOutside`+o+` `+c:a+` taskTextOutsideRight taskTextOutside`+o+` `+c+` width-`+r:a+` taskText taskText`+o+` `+c+` width-`+r}),x().securityLevel===`sandbox`){let e;e=c(`#i`+t);let n=e.nodes()[0].contentDocument;p.filter(function(e){return m.has(e.id)}).each(function(e){var r=n.querySelector(`#`+CSS.escape(t+`-`+e.id)),i=n.querySelector(`#`+CSS.escape(t+`-`+e.id+`-text`));let a=r.parentNode;var o=n.createElement(`a`);o.setAttribute(`xlink:href`,m.get(e.id)),o.setAttribute(`target`,`_top`),a.appendChild(o),o.appendChild(r),o.appendChild(i)})}}f(T,`drawRects`);function E(e,n,a,o,c,l,u,d){if(u.length===0&&d.length===0)return;let f,p;for(let{startTime:e,endTime:t}of l)(f===void 0||ep)&&(p=t);if(!f||!p)return;if((0,J.default)(p).diff((0,J.default)(f),`year`)>5){s.warn(`The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.`);return}let m=r.db.getDateFormat(),h=[],g=null,_=(0,J.default)(f);for(;_.valueOf()<=p;)r.db.isInvalidDate(_,m,u,d)?g?g.end=_:g={start:_,end:_}:g&&=(h.push(g),null),_=_.add(1,`d`);b.append(`g`).selectAll(`rect`).data(h).enter().append(`rect`).attr(`id`,e=>t+`-exclude-`+e.start.format(`YYYY-MM-DD`)).attr(`x`,e=>S(e.start.startOf(`day`))+a).attr(`y`,i.gridLineStartPadding).attr(`width`,e=>S(e.end.endOf(`day`))-S(e.start.startOf(`day`))).attr(`height`,c-n-i.gridLineStartPadding).attr(`transform-origin`,function(t,n){return(S(t.start)+a+.5*(S(t.end)-S(t.start))).toString()+`px `+(n*e+.5*c).toString()+`px`}).attr(`class`,`exclude-range`)}f(E,`drawExcludeDays`);function O(e,t,n,r){if(n<=0||e>t)return 1/0;let i=t-e,a=J.default.duration({[r??`day`]:n}).asMilliseconds();return a<=0?1/0:Math.ceil(i/a)}f(O,`getEstimatedTickCount`);function k(e,t,n,a){let o=r.db.getDateFormat(),c=r.db.getAxisFormat(),l;l=c||(o===`D`?`%d`:i.axisFormat??`%Y-%m-%d`);let u=me(S).tickSize(-a+t+i.gridLineStartPadding).tickFormat(In(l)),d=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||i.tickInterval);if(d!==null){let e=parseInt(d[1],10);if(isNaN(e)||e<=0)s.warn(`Invalid tick interval value: "${d[1]}". Skipping custom tick interval.`);else{let t=d[2],n=r.db.getWeekday()||i.weekday,a=S.domain(),o=a[0],c=a[1],l=O(o,c,e,t);if(l>gi)s.warn(`The tick interval "${e}${t}" would generate ${l} ticks, which exceeds the maximum allowed (${gi}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(t){case`millisecond`:u.ticks(ze.every(e));break;case`second`:u.ticks(z.every(e));break;case`minute`:u.ticks(Ue.every(e));break;case`hour`:u.ticks(Ge.every(e));break;case`day`:u.ticks(B.every(e));break;case`week`:u.ticks(mi[n].every(e));break;case`month`:u.ticks(ct.every(e))}}}if(b.append(`g`).attr(`class`,`grid`).attr(`transform`,`translate(`+e+`, `+(a-50)+`)`).call(u).selectAll(`text`).style(`text-anchor`,`middle`).attr(`fill`,`#000`).attr(`stroke`,`none`).attr(`font-size`,10).attr(`dy`,`1em`),r.db.topAxisEnabled()||i.topAxis){let n=pe(S).tickSize(-a+t+i.gridLineStartPadding).tickFormat(In(l));if(d!==null){let e=parseInt(d[1],10);if(isNaN(e)||e<=0)s.warn(`Invalid tick interval value: "${d[1]}". Skipping custom tick interval.`);else{let t=d[2],a=r.db.getWeekday()||i.weekday,o=S.domain(),s=o[0],c=o[1];if(O(s,c,e,t)<=gi)switch(t){case`millisecond`:n.ticks(ze.every(e));break;case`second`:n.ticks(z.every(e));break;case`minute`:n.ticks(Ue.every(e));break;case`hour`:n.ticks(Ge.every(e));break;case`day`:n.ticks(B.every(e));break;case`week`:n.ticks(mi[a].every(e));break;case`month`:n.ticks(ct.every(e))}}}b.append(`g`).attr(`class`,`grid`).attr(`transform`,`translate(`+e+`, `+t+`)`).call(n).selectAll(`text`).style(`text-anchor`,`middle`).attr(`fill`,`#000`).attr(`stroke`,`none`).attr(`font-size`,10)}}f(k,`makeGrid`);function ee(e,t){let n=0,r=Object.keys(_).map(e=>[e,_[e]]);b.append(`g`).selectAll(`text`).data(r).enter().append(function(e){let t=e[0].split(v.lineBreakRegex),n=-(t.length-1)/2,r=u.createElementNS(`http://www.w3.org/2000/svg`,`text`);r.setAttribute(`dy`,n+`em`);for(let[e,n]of t.entries()){let t=u.createElementNS(`http://www.w3.org/2000/svg`,`tspan`);t.setAttribute(`alignment-baseline`,`central`),t.setAttribute(`x`,`10`),e>0&&t.setAttribute(`dy`,`1em`),t.textContent=n,r.appendChild(t)}return r}).attr(`x`,10).attr(`y`,function(i,a){if(a>0)for(let o=0;o` + .mermaid-main-font { + font-family: ${e.fontFamily}; + } + + .exclude-range { + fill: ${e.excludeBkgColor}; + } + + .section { + stroke: none; + opacity: 0.2; + } + + .section0 { + fill: ${e.sectionBkgColor}; + } + + .section2 { + fill: ${e.sectionBkgColor2}; + } + + .section1, + .section3 { + fill: ${e.altSectionBkgColor}; + opacity: 0.2; + } + + .sectionTitle0 { + fill: ${e.titleColor}; + } + + .sectionTitle1 { + fill: ${e.titleColor}; + } + + .sectionTitle2 { + fill: ${e.titleColor}; + } + + .sectionTitle3 { + fill: ${e.titleColor}; + } + + .sectionTitle { + text-anchor: start; + font-family: ${e.fontFamily}; + } + + + /* Grid and axis */ + + .grid .tick { + stroke: ${e.gridColor}; + opacity: 0.8; + shape-rendering: crispEdges; + } + + .grid .tick text { + font-family: ${e.fontFamily}; + fill: ${e.textColor}; + } + + .grid path { + stroke-width: 0; + } + + + /* Today line */ + + .today { + fill: none; + stroke: ${e.todayLineColor}; + stroke-width: 2px; + } + + + /* Task styling */ + + /* Default task */ + + .task { + stroke-width: 2; + } + + .taskText { + text-anchor: middle; + font-family: ${e.fontFamily}; + } + + .taskTextOutsideRight { + fill: ${e.taskTextDarkColor}; + text-anchor: start; + font-family: ${e.fontFamily}; + } + + .taskTextOutsideLeft { + fill: ${e.taskTextDarkColor}; + text-anchor: end; + } + + + /* Special case clickable */ + + .task.clickable { + cursor: pointer; + } + + .taskText.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + .taskTextOutsideLeft.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + .taskTextOutsideRight.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + + /* Specific task settings for the sections*/ + + .taskText0, + .taskText1, + .taskText2, + .taskText3 { + fill: ${e.taskTextColor}; + } + + .task0, + .task1, + .task2, + .task3 { + fill: ${e.taskBkgColor}; + stroke: ${e.taskBorderColor}; + } + + .taskTextOutside0, + .taskTextOutside2 + { + fill: ${e.taskTextOutsideColor}; + } + + .taskTextOutside1, + .taskTextOutside3 { + fill: ${e.taskTextOutsideColor}; + } + + + /* Active task */ + + .active0, + .active1, + .active2, + .active3 { + fill: ${e.activeTaskBkgColor}; + stroke: ${e.activeTaskBorderColor}; + } + + .activeText0, + .activeText1, + .activeText2, + .activeText3 { + fill: ${e.taskTextDarkColor} !important; + } + + + /* Completed task */ + + .done0, + .done1, + .done2, + .done3 { + stroke: ${e.doneTaskBorderColor}; + fill: ${e.doneTaskBkgColor}; + stroke-width: 2; + } + + .doneText0, + .doneText1, + .doneText2, + .doneText3 { + fill: ${e.taskTextDarkColor} !important; + } + + /* Done task text displayed outside the bar sits against the diagram background, + not against the done-task bar, so it must use the outside/contrast color. */ + .doneText0.taskTextOutsideLeft, + .doneText0.taskTextOutsideRight, + .doneText1.taskTextOutsideLeft, + .doneText1.taskTextOutsideRight, + .doneText2.taskTextOutsideLeft, + .doneText2.taskTextOutsideRight, + .doneText3.taskTextOutsideLeft, + .doneText3.taskTextOutsideRight { + fill: ${e.taskTextOutsideColor} !important; + } + + + /* Tasks on the critical line */ + + .crit0, + .crit1, + .crit2, + .crit3 { + stroke: ${e.critBorderColor}; + fill: ${e.critBkgColor}; + stroke-width: 2; + } + + .activeCrit0, + .activeCrit1, + .activeCrit2, + .activeCrit3 { + stroke: ${e.critBorderColor}; + fill: ${e.activeTaskBkgColor}; + stroke-width: 2; + } + + .doneCrit0, + .doneCrit1, + .doneCrit2, + .doneCrit3 { + stroke: ${e.critBorderColor}; + fill: ${e.doneTaskBkgColor}; + stroke-width: 2; + cursor: pointer; + shape-rendering: crispEdges; + } + + .milestone { + transform: rotate(45deg) scale(0.8,0.8); + } + + .milestoneText { + font-style: italic; + } + .doneCritText0, + .doneCritText1, + .doneCritText2, + .doneCritText3 { + fill: ${e.taskTextDarkColor} !important; + } + + /* Done-crit task text outside the bar \u2014 same reasoning as doneText above. */ + .doneCritText0.taskTextOutsideLeft, + .doneCritText0.taskTextOutsideRight, + .doneCritText1.taskTextOutsideLeft, + .doneCritText1.taskTextOutsideRight, + .doneCritText2.taskTextOutsideLeft, + .doneCritText2.taskTextOutsideRight, + .doneCritText3.taskTextOutsideLeft, + .doneCritText3.taskTextOutsideRight { + fill: ${e.taskTextOutsideColor} !important; + } + + .vert { + stroke: ${e.vertLineColor}; + } + + .vertText { + font-size: 15px; + text-anchor: middle; + fill: ${e.vertLineColor} !important; + } + + .activeCritText0, + .activeCritText1, + .activeCritText2, + .activeCritText3 { + fill: ${e.taskTextDarkColor} !important; + } + + .titleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.titleColor||e.textColor}; + font-family: ${e.fontFamily}; + } +`,`getStyles`)};export{_i as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/gitGraph-4MIJSDKK-DroQcAWn.js b/frontend/dist/assets/gitGraph-4MIJSDKK-DroQcAWn.js new file mode 100644 index 0000000..e66b602 --- /dev/null +++ b/frontend/dist/assets/gitGraph-4MIJSDKK-DroQcAWn.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{E as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createGitGraphServices}; \ No newline at end of file diff --git a/frontend/dist/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js b/frontend/dist/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js new file mode 100644 index 0000000..ce6e6d6 --- /dev/null +++ b/frontend/dist/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js @@ -0,0 +1,106 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,X as a,a as o,b as s,f as c,q as l,s as u,v as d,w as f,x as p,y as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as h,i as g,m as _}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{n as v}from"./mermaid-parser.core-CUrDj5TF.js";import{t as y}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as b}from"./chunk-2Q5K7J3B-C1jixKkw.js";var x={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},ee=c.gitGraph,S=n(()=>g({...ee,...s().gitGraph}),`getConfig`),C=new b(()=>{let e=S(),t=e.mainBranchName,n=e.mainBranchOrder;return{mainBranchName:t,commits:new Map,head:null,branchConfig:new Map([[t,{name:t,order:n}]]),branches:new Map([[t,null]]),currBranch:t,direction:`LR`,seq:0,options:{}}});function w(){return _({length:7})}n(w,`getID`);function T(e,t){let n=Object.create(null);return e.reduce((e,r)=>{let i=t(r);return n[i]||(n[i]=!0,e.push(r)),e},[])}n(T,`uniqBy`);var te=n(function(e){C.records.direction=e},`setDirection`),ne=n(function(t){e.debug(`options str`,t),t=t?.trim(),t||=`{}`;try{C.records.options=JSON.parse(t)}catch(t){e.error(`error while parsing gitGraph options`,t.message)}},`setOptions`),re=n(function(){return C.records.options},`getOptions`),ie=n(function(t){let n=t.msg,r=t.id,i=t.type,a=t.tags;e.info(`commit`,n,r,i,a),e.debug(`Entering commit:`,n,r,i,a);let o=S();r=u.sanitizeText(r,o),n=u.sanitizeText(n,o),a=a?.map(e=>u.sanitizeText(e,o));let s={id:r||C.records.seq+`-`+w(),message:n,seq:C.records.seq++,type:i??x.NORMAL,tags:a??[],parents:C.records.head==null?[]:[C.records.head.id],branch:C.records.currBranch};C.records.head=s,e.info(`main branch`,o.mainBranchName),C.records.commits.has(s.id)&&e.warn(`Commit ID ${s.id} already exists`),C.records.commits.set(s.id,s),C.records.branches.set(C.records.currBranch,s.id),e.debug(`in pushCommit `+s.id)},`commit`),ae=n(function(t){let n=t.name,r=t.order;if(n=u.sanitizeText(n,S()),C.records.branches.has(n))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${n}")`);C.records.branches.set(n,C.records.head==null?null:C.records.head.id),C.records.branchConfig.set(n,{name:n,order:r}),E(n),e.debug(`in createBranch`)},`branch`),oe=n(t=>{let n=t.branch,r=t.id,i=t.type,a=t.tags,o=S();n=u.sanitizeText(n,o),r&&=u.sanitizeText(r,o);let s=C.records.branches.get(C.records.currBranch),c=C.records.branches.get(n),l=s?C.records.commits.get(s):void 0,d=c?C.records.commits.get(c):void 0;if(l&&d&&l.branch===n)throw Error(`Cannot merge branch '${n}' into itself.`);if(C.records.currBranch===n){let e=Error(`Incorrect usage of "merge". Cannot merge a branch to itself`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch abc`]},e}if(l===void 0||!l){let e=Error(`Incorrect usage of "merge". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`commit`]},e}if(!C.records.branches.has(n)){let e=Error(`Incorrect usage of "merge". Branch to be merged (`+n+`) does not exist`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch ${n}`]},e}if(d===void 0||!d){let e=Error(`Incorrect usage of "merge". Branch to be merged (`+n+`) has no commits`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`"commit"`]},e}if(l===d){let e=Error(`Incorrect usage of "merge". Both branches have same head`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch abc`]},e}if(r&&C.records.commits.has(r)){let e=Error(`Incorrect usage of "merge". Commit with id:`+r+` already exists, use different custom id`);throw e.hash={text:`merge ${n} ${r} ${i} ${a?.join(` `)}`,token:`merge ${n} ${r} ${i} ${a?.join(` `)}`,expected:[`merge ${n} ${r}_UNIQUE ${i} ${a?.join(` `)}`]},e}let f=c||``,p={id:r||`${C.records.seq}-${w()}`,message:`merged branch ${n} into ${C.records.currBranch}`,seq:C.records.seq++,parents:C.records.head==null?[]:[C.records.head.id,f],branch:C.records.currBranch,type:x.MERGE,customType:i,customId:!!r,tags:a??[]};C.records.head=p,C.records.commits.set(p.id,p),C.records.branches.set(C.records.currBranch,p.id),e.debug(C.records.branches),e.debug(`in mergeBranch`)},`merge`),se=n(function(t){let n=t.id,r=t.targetId,i=t.tags,a=t.parent;e.debug(`Entering cherryPick:`,n,r,i);let o=S();if(n=u.sanitizeText(n,o),r=u.sanitizeText(r,o),i=i?.map(e=>u.sanitizeText(e,o)),a=u.sanitizeText(a,o),!n||!C.records.commits.has(n)){let e=Error(`Incorrect usage of "cherryPick". Source commit id should exist and provided`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let s=C.records.commits.get(n);if(s===void 0||!s)throw Error(`Incorrect usage of "cherryPick". Source commit id should exist and provided`);if(a&&!(Array.isArray(s.parents)&&s.parents.includes(a)))throw Error(`Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.`);let c=s.branch;if(s.type===x.MERGE&&!a)throw Error(`Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.`);if(!r||!C.records.commits.has(r)){if(c===C.records.currBranch){let e=Error(`Incorrect usage of "cherryPick". Source commit is already on current branch`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let t=C.records.branches.get(C.records.currBranch);if(t===void 0||!t){let e=Error(`Incorrect usage of "cherry-pick". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let o=C.records.commits.get(t);if(o===void 0||!o){let e=Error(`Incorrect usage of "cherry-pick". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let l={id:C.records.seq+`-`+w(),message:`cherry-picked ${s?.message} into ${C.records.currBranch}`,seq:C.records.seq++,parents:C.records.head==null?[]:[C.records.head.id,s.id],branch:C.records.currBranch,type:x.CHERRY_PICK,tags:i?i.filter(Boolean):[`cherry-pick:${s.id}${s.type===x.MERGE?`|parent:${a}`:``}`]};C.records.head=l,C.records.commits.set(l.id,l),C.records.branches.set(C.records.currBranch,l.id),e.debug(C.records.branches),e.debug(`in cherryPick`)}},`cherryPick`),E=n(function(e){if(e=u.sanitizeText(e,S()),C.records.branches.has(e)){C.records.currBranch=e;let t=C.records.branches.get(C.records.currBranch);t===void 0||!t?C.records.head=null:C.records.head=C.records.commits.get(t)??null}else{let t=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw t.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},t}},`checkout`);function D(e,t,n){let r=e.indexOf(t);r===-1?e.push(n):e.splice(r,1,n)}n(D,`upsert`);function O(t){let n=t.reduce((e,t)=>e.seq>t.seq?e:t,t[0]),r=``;t.forEach(function(e){r+=e===n?` *`:` |`});let i=[r,n.id,n.seq];for(let e in C.records.branches)C.records.branches.get(e)===n.id&&i.push(e);if(e.debug(i.join(` `)),n.parents&&n.parents.length==2&&n.parents[0]&&n.parents[1]){let e=C.records.commits.get(n.parents[0]);D(t,n,e),n.parents[1]&&t.push(C.records.commits.get(n.parents[1]))}else if(n.parents.length==0)return;else if(n.parents[0]){let e=C.records.commits.get(n.parents[0]);D(t,n,e)}t=T(t,e=>e.id),O(t)}n(O,`prettyPrintCommitHistory`);var ce=n(function(){e.debug(C.records.commits);let t=k()[0];O([t])},`prettyPrint`),le=n(function(){C.reset(),o()},`clear`),ue=n(function(){return[...C.records.branchConfig.values()].map((e,t)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${t}`)}).sort((e,t)=>(e.order??0)-(t.order??0)).map(({name:e})=>({name:e}))},`getBranchesAsObjArray`),de=n(function(){return C.records.branches},`getBranches`),fe=n(function(){return C.records.commits},`getCommits`),k=n(function(){let t=[...C.records.commits.values()];return t.forEach(function(t){e.debug(t.id)}),t.sort((e,t)=>e.seq-t.seq),t},`getCommitsArray`),A={commitType:x,getConfig:S,setDirection:te,setOptions:ne,getOptions:re,commit:ie,branch:ae,merge:oe,cherryPick:se,checkout:E,prettyPrint:ce,clear:le,getBranchesAsObjArray:ue,getBranches:de,getCommits:fe,getCommitsArray:k,getCurrentBranch:n(function(){return C.records.currBranch},`getCurrentBranch`),getDirection:n(function(){return C.records.direction},`getDirection`),getHead:n(function(){return C.records.head},`getHead`),setAccTitle:i,getAccTitle:m,getAccDescription:d,setAccDescription:r,setDiagramTitle:l,getDiagramTitle:f},pe=n((e,t)=>{y(e,t),e.dir&&t.setDirection(e.dir);for(let n of e.statements)me(n,t)},`populate`),me=n((t,r)=>{let i={Commit:n(e=>r.commit(he(e)),`Commit`),Branch:n(e=>r.branch(ge(e)),`Branch`),Merge:n(e=>r.merge(_e(e)),`Merge`),Checkout:n(e=>r.checkout(ve(e)),`Checkout`),CherryPicking:n(e=>r.cherryPick(ye(e)),`CherryPicking`)}[t.$type];i?i(t):e.error(`Unknown statement type: ${t.$type}`)},`parseStatement`),he=n(e=>({id:e.id,msg:e.message??``,type:e.type===void 0?x.NORMAL:x[e.type],tags:e.tags??void 0}),`parseCommit`),ge=n(e=>({name:e.name,order:e.order??0}),`parseBranch`),_e=n(e=>({branch:e.branch,id:e.id??``,type:e.type===void 0?void 0:x[e.type],tags:e.tags??void 0}),`parseMerge`),ve=n(e=>e.branch,`parseCheckout`),ye=n(e=>({id:e.id,targetId:``,tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),`parseCherryPicking`),be={parse:n(async t=>{let n=await v(`gitGraph`,t);e.debug(n),pe(n,A)},`parse`)},j=10,M=40,N=4,P=2,F=8,I=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]),L=12,R=new Set([`redux-color`,`redux-dark-color`]),xe=new Set([`dark`,`redux-dark`,`redux-dark-color`,`neo-dark`]),z=n((e,t,n=!1)=>n&&e>0?(e-1)%(t-1)+1:e%t,`calcColorIndex`),B=new Map,V=new Map,H=30,U=new Map,W=[],G=0,K=`LR`,q=n(()=>{B.clear(),V.clear(),U.clear(),G=0,W=[],K=`LR`},`clear`),J=n(e=>{let t=document.createElementNS(`http://www.w3.org/2000/svg`,`text`);return(typeof e==`string`?e.split(/\\n|\n|/gi):e).forEach(e=>{let n=document.createElementNS(`http://www.w3.org/2000/svg`,`tspan`);n.setAttributeNS(`http://www.w3.org/XML/1998/namespace`,`xml:space`,`preserve`),n.setAttribute(`dy`,`1em`),n.setAttribute(`x`,`0`),n.setAttribute(`class`,`row`),n.textContent=e.trim(),t.appendChild(n)}),t},`drawText`),Y=n(e=>{let t,r,i;return K===`BT`?(r=n((e,t)=>e<=t,`comparisonFunc`),i=1/0):(r=n((e,t)=>e>=t,`comparisonFunc`),i=0),e.forEach(e=>{let n=K===`TB`||K==`BT`?V.get(e)?.y:V.get(e)?.x;n!==void 0&&r(n,i)&&(t=e,i=n)}),t},`findClosestParent`),Se=n(e=>{let t=``,n=1/0;return e.forEach(e=>{let r=V.get(e).y;r<=n&&(t=e,n=r)}),t||void 0},`findClosestParentBT`),Ce=n((e,t,n)=>{let r=n,i=n,a=[];e.forEach(e=>{let n=t.get(e);if(!n)throw Error(`Commit not found for key ${e}`);n.parents.length?(r=Te(n),i=Math.max(r,i)):a.push(n),Ee(n,r)}),r=i,a.forEach(e=>{De(e,r,n)}),e.forEach(e=>{let n=t.get(e);if(n?.parents.length){let e=Se(n.parents);r=V.get(e).y-M,r<=i&&(i=r);let t=B.get(n.branch).pos,a=r-j;V.set(n.id,{x:t,y:a})}})},`setParallelBTPos`),we=n(e=>{let t=Y(e.parents.filter(e=>e!==null));if(!t)throw Error(`Closest parent not found for commit ${e.id}`);let n=V.get(t)?.y;if(n===void 0)throw Error(`Closest parent position not found for commit ${e.id}`);return n},`findClosestParentPos`),Te=n(e=>we(e)+M,`calculateCommitPosition`),Ee=n((e,t)=>{let n=B.get(e.branch);if(!n)throw Error(`Branch not found for commit ${e.id}`);let r=n.pos,i=t+j;return V.set(e.id,{x:r,y:i}),{x:r,y:i}},`setCommitPosition`),De=n((e,t,n)=>{let r=B.get(e.branch);if(!r)throw Error(`Branch not found for commit ${e.id}`);let i=t+n,a=r.pos;V.set(e.id,{x:a,y:i})},`setRootPosition`),Oe=n((e,t,n,r,i,a)=>{let{theme:o}=p(),s=I.has(o??``),c=R.has(o??``),l=xe.has(o??``);if(a===x.HIGHLIGHT)e.append(`rect`).attr(`x`,n.x-10+(s?3:0)).attr(`y`,n.y-10+(s?3:0)).attr(`width`,s?14:20).attr(`height`,s?14:20).attr(`class`,`commit ${t.id} commit-highlight${z(i,F,c)} ${r}-outer`),e.append(`rect`).attr(`x`,n.x-6+(s?2:0)).attr(`y`,n.y-6+(s?2:0)).attr(`width`,s?8:12).attr(`height`,s?8:12).attr(`class`,`commit ${t.id} commit${z(i,F,c)} ${r}-inner`);else if(a===x.CHERRY_PICK)e.append(`circle`).attr(`cx`,n.x).attr(`cy`,n.y).attr(`r`,s?7:10).attr(`class`,`commit ${t.id} ${r}`),e.append(`circle`).attr(`cx`,n.x-3).attr(`cy`,n.y+2).attr(`r`,s?2.5:2.75).attr(`fill`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`circle`).attr(`cx`,n.x+3).attr(`cy`,n.y+2).attr(`r`,s?2.5:2.75).attr(`fill`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`line`).attr(`x1`,n.x+3).attr(`y1`,n.y+1).attr(`x2`,n.x).attr(`y2`,n.y-5).attr(`stroke`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`line`).attr(`x1`,n.x-3).attr(`y1`,n.y+1).attr(`x2`,n.x).attr(`y2`,n.y-5).attr(`stroke`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`);else{let o=e.append(`circle`);if(o.attr(`cx`,n.x),o.attr(`cy`,n.y),o.attr(`r`,s?7:10),o.attr(`class`,`commit ${t.id} commit${z(i,F,c)}`),a===x.MERGE){let a=e.append(`circle`);a.attr(`cx`,n.x),a.attr(`cy`,n.y),a.attr(`r`,s?5:6),a.attr(`class`,`commit ${r} ${t.id} commit${z(i,F,c)}`)}if(a===x.REVERSE){let a=e.append(`path`),o=s?4:5;a.attr(`d`,`M ${n.x-o},${n.y-o}L${n.x+o},${n.y+o}M${n.x-o},${n.y+o}L${n.x+o},${n.y-o}`).attr(`class`,`commit ${r} ${t.id} commit${z(i,F,c)}`)}}},`drawCommitBullet`),ke=n((e,t,n,r,i)=>{if(t.type!==x.CHERRY_PICK&&(t.customId&&t.type===x.MERGE||t.type!==x.MERGE)&&i.showCommitLabel){let a=e.append(`g`),o=a.insert(`rect`).attr(`class`,`commit-label-bkg`),s=a.append(`text`).attr(`x`,r).attr(`y`,n.y+25).attr(`class`,`commit-label`).text(t.id),c=s.node()?.getBBox();if(c&&(o.attr(`x`,n.posWithOffset-c.width/2-P).attr(`y`,n.y+13.5).attr(`width`,c.width+2*P).attr(`height`,c.height+2*P),K===`TB`||K===`BT`?(o.attr(`x`,n.x-(c.width+4*N+5)).attr(`y`,n.y-12),s.attr(`x`,n.x-(c.width+4*N)).attr(`y`,n.y+c.height-12)):s.attr(`x`,n.posWithOffset-c.width/2),i.rotateCommitLabel)){if(K===`TB`||K===`BT`)s.attr(`transform`,`rotate(-45, `+n.x+`, `+n.y+`)`),o.attr(`transform`,`rotate(-45, `+n.x+`, `+n.y+`)`);else{let e=-7.5-(c.width+10)/25*9.5,t=10+c.width/25*8.5;a.attr(`transform`,`translate(`+e+`, `+t+`) rotate(-45, `+r+`, `+n.y+`)`)}}}},`drawCommitLabel`),Ae=n((e,t,n,r)=>{if(t.tags.length>0){let i=0,a=0,o=0,s=[];for(let r of t.tags.reverse()){let t=e.insert(`polygon`),c=e.append(`circle`),l=e.append(`text`).attr(`y`,n.y-16-i).attr(`class`,`tag-label`).text(r),u=l.node()?.getBBox();if(!u)throw Error(`Tag bbox not found`);a=Math.max(a,u.width),o=Math.max(o,u.height),l.attr(`x`,n.posWithOffset-u.width/2),s.push({tag:l,hole:c,rect:t,yOffset:i}),i+=20}for(let{tag:e,hole:t,rect:i,yOffset:c}of s){let s=o/2,l=n.y-19.2-c;if(i.attr(`class`,`tag-label-bkg`).attr(`points`,` + ${r-a/2-N/2},${l+P} + ${r-a/2-N/2},${l-P} + ${n.posWithOffset-a/2-N},${l-s-P} + ${n.posWithOffset+a/2+N},${l-s-P} + ${n.posWithOffset+a/2+N},${l+s+P} + ${n.posWithOffset-a/2-N},${l+s+P}`),t.attr(`cy`,l).attr(`cx`,r-a/2+N/2).attr(`r`,1.5).attr(`class`,`tag-hole`),K===`TB`||K===`BT`){let o=r+c;i.attr(`class`,`tag-label-bkg`).attr(`points`,` + ${n.x},${o+2} + ${n.x},${o-2} + ${n.x+j},${o-s-2} + ${n.x+j+a+4},${o-s-2} + ${n.x+j+a+4},${o+s+2} + ${n.x+j},${o+s+2}`).attr(`transform`,`translate(12,12) rotate(45, `+n.x+`,`+r+`)`),t.attr(`cx`,n.x+N/2).attr(`cy`,o).attr(`transform`,`translate(12,12) rotate(45, `+n.x+`,`+r+`)`),e.attr(`x`,n.x+5).attr(`y`,o+3).attr(`transform`,`translate(14,14) rotate(45, `+n.x+`,`+r+`)`)}}}},`drawCommitTags`),je=n(e=>{switch(e.customType??e.type){case x.NORMAL:return`commit-normal`;case x.REVERSE:return`commit-reverse`;case x.HIGHLIGHT:return`commit-highlight`;case x.MERGE:return`commit-merge`;case x.CHERRY_PICK:return`commit-cherry-pick`;default:return`commit-normal`}},`getCommitClassType`),Me=n((e,t,n,r)=>{let i={x:0,y:0};if(e.parents.length>0){let n=Y(e.parents);if(n){let a=r.get(n)??i;return t===`TB`?a.y+M:t===`BT`?(r.get(e.id)??i).y-M:a.x+M}}else if(t===`TB`)return H;else if(t===`BT`)return(r.get(e.id)??i).y-M;else return 0;return 0},`calculatePosition`),Ne=n((e,t,n)=>{let r=K===`BT`&&n?t:t+j,i=B.get(e.branch)?.pos,a=K===`TB`||K===`BT`?B.get(e.branch)?.pos:r;if(a===void 0||i===void 0)throw Error(`Position were undefined for commit ${e.id}`);let o=I.has(p().theme??``);return{x:a,y:K===`TB`||K===`BT`?r:i+(o?L/2+1:-2),posWithOffset:r}},`getCommitPosition`),X=n((e,t,r,i)=>{let a=e.append(`g`).attr(`class`,`commit-bullets`),o=e.append(`g`).attr(`class`,`commit-labels`),s=K===`TB`||K===`BT`?H:0,c=[...t.keys()],l=i.parallelCommits??!1,u=n((e,n)=>{let r=t.get(e)?.seq,i=t.get(n)?.seq;return r!==void 0&&i!==void 0?r-i:0},`sortKeys`),d=c.sort(u);K===`BT`&&(l&&Ce(d,t,s),d=d.reverse()),d.forEach(e=>{let n=t.get(e);if(!n)throw Error(`Commit not found for key ${e}`);l&&(s=Me(n,K,s,V));let c=Ne(n,s,l);if(r){let e=je(n),t=n.customType??n.type,r=B.get(n.branch)?.index??0;Oe(a,n,c,e,r,t),ke(o,n,c,s,i),Ae(o,n,c,s)}K===`TB`||K===`BT`?V.set(n.id,{x:c.x,y:c.posWithOffset}):V.set(n.id,{x:c.posWithOffset,y:c.y}),s=K===`BT`&&l?s+M:s+M+j,s>G&&(G=s)})},`drawCommits`),Pe=n((e,t,r,i,a)=>{let o=(K===`TB`||K===`BT`?r.xe.branch===o,`isOnBranchToGetCurve`),c=n(n=>n.seq>e.seq&&n.seqc(e)&&s(e))},`shouldRerouteArrow`),Z=n((e,t,n=0)=>{let r=e+Math.abs(e-t)/2;return n>5?r:W.every(e=>Math.abs(e-r)>=10)?(W.push(r),r):Z(e,t-Math.abs(e-t)/5,n+1)},`findLane`),Fe=n((e,t,n,r)=>{let{theme:i}=p(),a=R.has(i??``),o=V.get(t.id),s=V.get(n.id);if(o===void 0||s===void 0)throw Error(`Commit positions not found for commits ${t.id} and ${n.id}`);let c=Pe(t,n,o,s,r),l=``,u=``,d=0,f=0,m=B.get(n.branch)?.index;n.type===x.MERGE&&t.id!==n.parents[0]&&(m=B.get(t.branch)?.index);let h;if(c){l=`A 10 10, 0, 0, 0,`,u=`A 10 10, 0, 0, 1,`,d=10,f=10;let e=o.ys.x&&(l=`A 20 20, 0, 0, 0,`,u=`A 20 20, 0, 0, 1,`,d=20,f=20,h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${o.x} ${s.y-d} ${u} ${o.x-f} ${s.y} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${s.x+d} ${o.y} ${l} ${s.x} ${o.y+f} L ${s.x} ${s.y}`),o.x===s.x&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`)):K===`BT`?(o.xs.x&&(l=`A 20 20, 0, 0, 0,`,u=`A 20 20, 0, 0, 1,`,d=20,f=20,h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${o.x} ${s.y+d} ${l} ${o.x-f} ${s.y} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${s.x+d} ${o.y} ${u} ${s.x} ${o.y-f} L ${s.x} ${s.y}`),o.x===s.x&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`)):(o.ys.y&&(h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${s.x-d} ${o.y} ${l} ${s.x} ${o.y-f} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${o.x} ${s.y+d} ${u} ${o.x+f} ${s.y} L ${s.x} ${s.y}`),o.y===s.y&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`));if(h===void 0)throw Error(`Line definition not found`);e.append(`path`).attr(`d`,h).attr(`class`,`arrow arrow`+z(m,F,a))},`drawArrow`),Ie=n((e,t)=>{let n=e.append(`g`).attr(`class`,`commit-arrows`);[...t.keys()].forEach(e=>{let r=t.get(e);r.parents&&r.parents.length>0&&r.parents.forEach(e=>{Fe(n,t.get(e),r,t)})})},`drawArrows`),Le=n((e,t,n,r)=>{let{look:i,theme:a,themeVariables:o}=p(),{dropShadow:s,THEME_COLOR_LIMIT:c}=o,l=I.has(a??``),u=R.has(a??``),d=e.append(`g`);t.forEach((e,t)=>{let a=z(t,l?c:F,u),o=B.get(e.name)?.pos;if(o===void 0)throw Error(`Position not found for branch ${e.name}`);let f=K===`TB`||K===`BT`?o:l?o+L/2+1:o-2,p=d.append(`line`);p.attr(`x1`,0),p.attr(`y1`,f),p.attr(`x2`,G),p.attr(`y2`,f),p.attr(`class`,`branch branch`+a),K===`TB`?(p.attr(`y1`,H),p.attr(`x1`,o),p.attr(`y2`,G),p.attr(`x2`,o)):K===`BT`&&(p.attr(`y1`,G),p.attr(`x1`,o),p.attr(`y2`,H),p.attr(`x2`,o)),W.push(f);let m=e.name,h=J(m),g=d.insert(`rect`),_=d.insert(`g`).attr(`class`,`branchLabel`).insert(`g`).attr(`class`,`label branch-label`+a);_.node().appendChild(h);let v=h.getBBox(),y=l?0:4,b=l?16:0,x=l?L:0;i===`neo`&&g.attr(`data-look`,`neo`),g.attr(`class`,`branchLabelBkg label`+a).attr(`style`,i===`neo`?`filter:${l?`url(#${r}-drop-shadow)`:s}`:``).attr(`rx`,y).attr(`ry`,y).attr(`x`,-v.width-4-(n.rotateCommitLabel===!0?30:0)).attr(`y`,-v.height/2+10).attr(`width`,v.width+18+b).attr(`height`,v.height+4+x),_.attr(`transform`,`translate(`+(-v.width-14-(n.rotateCommitLabel===!0?30:0)+b/2)+`, `+(f-v.height/2-2)+`)`),K===`TB`?(g.attr(`x`,o-v.width/2-10).attr(`y`,0),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, 0)`),l&&(g.attr(`transform`,`translate(${-b/2-3}, ${-x-10})`),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+(-x*2+7)+`)`))):K===`BT`?(g.attr(`x`,o-v.width/2-10).attr(`y`,G),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+G+`)`),l&&(g.attr(`transform`,`translate(${-b/2-3}, ${x+10})`),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+(G+x*2+4)+`)`))):g.attr(`transform`,`translate(-19, `+(f-12-x/2)+`)`)})},`drawBranches`),Re=n(function(e,t,n,r,i){return B.set(e,{pos:t,index:n}),t+=50+(i?40:0)+(K===`TB`||K===`BT`?r.width/2:0),t},`setBranchPosition`),ze={draw:n(function(n,r,i,o){q(),e.debug(`in gitgraph renderer`,n+` +`,`id:`,r,i);let s=o.db;if(!s.getConfig){e.error(`getConfig method is not available on db`);return}let c=s.getConfig(),l=c.rotateCommitLabel??!1;U=s.getCommits();let u=s.getBranchesAsObjArray();K=s.getDirection();let d=t(`[id="${r}"]`),{look:f,theme:m,themeVariables:g}=p(),{useGradient:_,gradientStart:v,gradientStop:y,filterColor:b}=g;if(_){let e=d.append(`defs`).append(`linearGradient`).attr(`id`,r+`-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);e.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,v).attr(`stop-opacity`,1),e.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,y).attr(`stop-opacity`,1)}f===`neo`&&I.has(m??``)&&d.append(`defs`).append(`filter`).attr(`id`,r+`-drop-shadow`).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,b);let x=0;u.forEach((e,t)=>{let n=J(e.name),r=d.append(`g`),i=r.insert(`g`).attr(`class`,`branchLabel`),a=i.insert(`g`).attr(`class`,`label branch-label`);a.node()?.appendChild(n);let o=n.getBBox();x=Re(e.name,x,t,o,l),a.remove(),i.remove(),r.remove()}),X(d,U,!1,c),c.showBranches&&Le(d,u,c,r),Ie(d,U),X(d,U,!0,c),h.insertTitle(d,`gitTitleText`,c.titleTopMargin??0,s.getDiagramTitle()),a(void 0,d,c.diagramPadding,c.useMaxWidth)},`draw`)},Q=8,$=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]),Be=new Set([`redux-color`,`redux-dark-color`]),Ve=new Set([`neo`,`neo-dark`]),He=new Set([`dark`,`redux-dark`,`redux-dark-color`,`neo-dark`]),Ue=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`,`neo`,`neo-dark`]),We=n(e=>{let{svgId:t}=e,n=``;if(e.useGradient&&t)for(let r=0;r{let{theme:t,themeVariables:n}=s(),{borderColorArray:r}=n,i=$.has(t);if(Ve.has(t)){let t=``;for(let n=0;n`${Array.from({length:e.THEME_COLOR_LIMIT},(e,t)=>t).map(t=>{let n=t%Q;return` + .branch-label${t} { fill: ${e[`gitBranchLabel`+n]}; } + .commit${t} { stroke: ${e[`git`+n]}; fill: ${e[`git`+n]}; } + .commit-highlight${t} { stroke: ${e[`gitInv`+n]}; fill: ${e[`gitInv`+n]}; } + .label${t} { fill: ${e[`git`+n]}; } + .arrow${t} { stroke: ${e[`git`+n]}; } + `}).join(` +`)}`,`normalTheme`),qe={parser:be,db:A,renderer:ze,styles:n(e=>{let{theme:t}=s(),n=Ue.has(t);return` + .commit-id, + .commit-msg, + .branch-label { + fill: lightgrey; + color: lightgrey; + font-family: 'trebuchet ms', verdana, arial, sans-serif; + font-family: var(--mermaid-font-family); + } + + ${n?Ge(e):Ke(e)} + + .branch { + stroke-width: ${e.strokeWidth}; + stroke: ${e.commitLineColor??e.lineColor}; + stroke-dasharray: ${n?`4 2`:`2`}; + } + .commit-label { font-size: ${e.commitLabelFontSize}; fill: ${n?e.nodeBorder:e.commitLabelColor}; ${n?`font-weight:${e.noteFontWeight};`:``}} + .commit-label-bkg { font-size: ${e.commitLabelFontSize}; fill: ${n?`transparent`:e.commitLabelBackground}; opacity: ${n?``:.5}; } + .tag-label { font-size: ${e.tagLabelFontSize}; fill: ${e.tagLabelColor};} + .tag-label-bkg { fill: ${n?e.mainBkg:e.tagLabelBackground}; stroke: ${n?e.nodeBorder:e.tagLabelBorder}; ${n?`filter:${e.dropShadow}`:``} } + .tag-hole { fill: ${e.textColor}; } + + .commit-merge { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + } + .commit-reverse { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + stroke-width: ${n?e.strokeWidth:3}; + } + .commit-highlight-outer { + } + .commit-highlight-inner { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + } + + .arrow { + /* Intentional: neo themes keep the bold 8px arrow (like classic themes); only redux-geometry themes use the thinner options.strokeWidth. */ + stroke-width: ${$.has(t)?e.strokeWidth:8}; + stroke-linecap: round; + fill: none + } + .gitTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } +`},`getStyles`)};export{qe as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/graphlib-C9Tl7QrK.js b/frontend/dist/assets/graphlib-C9Tl7QrK.js new file mode 100644 index 0000000..dbe1de2 --- /dev/null +++ b/frontend/dist/assets/graphlib-C9Tl7QrK.js @@ -0,0 +1 @@ +import{A as e,I as t,a as n,at as r,c as i,d as a,i as o,n as s,o as c,q as l,r as u,rt as d,t as f}from"./_baseUniq-DR4vVjyC.js";var p=l(function(t){return f(e(t,1,a,!0))}),m=`\0`,h=`\0`,g=``,_=class{constructor(e={}){this._isDirected=!Object.prototype.hasOwnProperty.call(e,`directed`)||e.directed,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,`multigraph`)?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=d(void 0),this._defaultEdgeLabelFn=d(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[h]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return r(e)||(e=d(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return t(this._nodes)}sources(){var e=this;return c(this.nodes(),function(t){return o(e._in[t])})}sinks(){var e=this;return c(this.nodes(),function(t){return o(e._out[t])})}setNodes(e,t){var n=arguments,r=this;return i(e,function(e){n.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=h,this._children[e]={},this._children[h][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var n=e=>this.removeEdge(this._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],i(this.children(e),e=>{this.setParent(e)}),delete this._children[e]),i(t(this._in[e]),n),delete this._in[e],delete this._preds[e],i(t(this._out[e]),n),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(u(t))t=h;else{t+=``;for(var n=t;!u(n);n=this.parent(n))if(n===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==h)return t}}children(e){if(u(e)&&(e=h),this._isCompound){var n=this._children[e];if(n)return t(n)}else if(e===h)return this.nodes();else if(this.hasNode(e))return[]}predecessors(e){var n=this._preds[e];if(n)return t(n)}successors(e){var n=this._sucs[e];if(n)return t(n)}neighbors(e){var t=this.predecessors(e);if(t)return p(t,this.successors(e))}isLeaf(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;i(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),i(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))});var r={};function a(e){var i=n.parent(e);return i===void 0||t.hasNode(i)?(r[e]=i,i):i in r?r[i]:a(i)}return this._isCompound&&i(t.nodes(),function(e){t.setParent(e,a(e))}),t}setDefaultEdgeLabel(e){return r(e)||(e=d(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return n(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return s(e,function(e,i){return r.length>1?n.setEdge(e,i,t):n.setEdge(e,i),i}),this}setEdge(){var e,t,n,r,i=!1,a=arguments[0];typeof a==`object`&&a&&`v`in a?(e=a.v,t=a.w,n=a.name,arguments.length===2&&(r=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),e=``+e,t=``+t,u(n)||(n=``+n);var o=b(this._isDirected,e,t,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!u(n)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(e,t,n);var s=x(this._isDirected,e,t,n);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[o]=s,v(this._preds[t],e),v(this._sucs[e],t),this._in[t][o]=s,this._out[e][o]=s,this._edgeCount++,this}edge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n);return this._edgeLabels[r]}hasEdge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],y(this._preds[t],e),y(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var r=this._in[e];if(r){var i=n(r);return t?c(i,function(e){return e.v===t}):i}}outEdges(e,t){var r=this._out[e];if(r){var i=n(r);return t?c(i,function(e){return e.w===t}):i}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}};_.prototype._nodeCount=0,_.prototype._edgeCount=0;function v(e,t){e[t]?e[t]++:e[t]=1}function y(e,t){--e[t]||delete e[t]}function b(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}return i+g+a+g+(u(r)?m:r)}function x(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function S(e,t){return b(e,t.v,t.w,t.name)}export{_ as t}; \ No newline at end of file diff --git a/frontend/dist/assets/index-0i5Xvc5h.css b/frontend/dist/assets/index-0i5Xvc5h.css new file mode 100644 index 0000000..00e08a2 --- /dev/null +++ b/frontend/dist/assets/index-0i5Xvc5h.css @@ -0,0 +1 @@ +:root,[data-theme=deep-ocean]{--bg-base:#07181b;--bg-card:#0d2c2f;--border-card:#15474d;--primary:#0891b2;--primary-hover:#0e7490;--accent:#14b8a6;--accent-light:#2dd4bf;--danger:#ef4444;--danger-hover:#dc2626;--text:#f8fafc;--text-muted:#94a3b8;--code-bg:#00000059;--radius:10px;--font-family-base:"Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-family-heading:"Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-family-mono:"JetBrains Mono", monospace;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--font-weight-extrabold:800;--font-size-xs:.75rem;--font-size-sm:.85rem;--font-size-base:1rem;--font-size-lg:1.15rem;--font-size-xl:1.35rem;--font-size-2xl:1.65rem}[data-theme=midnight-blue]{--bg-base:#0a0f1d;--bg-card:#121a2fa6;--border-card:#ffffff14;--primary:#3b82f6;--primary-hover:#2563eb;--accent:#14b8a6;--accent-light:#2dd4bf;--danger:#ef4444;--danger-hover:#dc2626;--text:#f8fafc;--text-muted:#94a3b8;--code-bg:#00000059;--radius:12px}[data-theme=lavender-haze],[data-theme=aqua-breeze],[data-theme=arctic-frost]{--bg-base:#f5f3ff;--bg-card:#faf8ff;--border-card:#ddd6fe;--primary:#7c3aed;--primary-hover:#6d28d9;--accent:#ec4899;--accent-light:#f472b6;--danger:#dc2626;--danger-hover:#b91c1c;--text:#1e1035;--text-muted:#6b5b82;--code-bg:#7c3aed14;--radius:10px}[data-theme=amber-warmth],[data-theme=azure-daylight],[data-theme=solar-daybreak]{--bg-base:#fdf8f4;--bg-card:#fff;--border-card:#fed7aa;--primary:#ea580c;--primary-hover:#c2410c;--accent:#d97706;--accent-light:#f59e0b;--danger:#dc2626;--danger-hover:#b91c1c;--text:#291508;--text-muted:#7c5e4a;--code-bg:#ea580c14;--radius:12px}*{box-sizing:border-box;margin:0;padding:0}h1,h2,h3,h4,h5,h6{font-family:var(--font-family-heading)}body{font-family:var(--font-family-base);background-color:var(--bg-base);color:var(--text);min-height:100vh;display:block;position:relative;overflow:hidden scroll}.dashboard-container{z-index:1;flex-direction:column;gap:16px;width:100%;min-width:0;max-width:1720px;margin:0 auto;padding:16px 20px;display:flex}.dashboard-header{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);box-sizing:border-box;justify-content:space-between;align-items:center;gap:16px;min-height:52px;padding:10px 18px;display:flex}.header-brand{flex-shrink:0;align-items:center;gap:12px;display:flex}.menu-toggle-btn{border:1px solid var(--border-card);color:var(--text);cursor:pointer;background:#ffffff14;border-radius:6px;padding:6px 10px;font-size:1.1rem;transition:all .2s;display:none}.menu-toggle-btn:hover{background:#ffffff26}.header-logo{align-items:center;gap:8px;display:flex}.logo-icon{color:var(--accent-light);font-size:1.3rem}.header-title{align-items:center;gap:8px;display:flex}.header-title h1{letter-spacing:-.4px;white-space:nowrap;margin:0;font-size:1.15rem;font-weight:700}.dashboard-nav{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);scrollbar-width:none;white-space:nowrap;box-sizing:border-box;flex-direction:row;align-items:center;gap:6px;width:100%;padding:6px 10px;display:flex;overflow:auto}.dashboard-nav::-webkit-scrollbar{display:none}.nav-tab{color:var(--text-muted);box-sizing:border-box;cursor:pointer;white-space:nowrap;background:0 0;border:1px solid #0000;border-radius:6px;flex:1 0;justify-content:center;align-items:center;gap:7px;min-height:36px;padding:8px 10px;font-family:inherit;font-size:.86rem;font-weight:600;transition:all .15s;display:inline-flex}.nav-tab:hover{color:var(--text);background:#ffffff0f}.nav-tab.active{color:#fff;background:color-mix(in srgb, var(--primary) 22%, transparent);border-color:color-mix(in srgb, var(--primary) 45%, transparent)}.header-status{flex-shrink:0;align-items:center;gap:8px;display:flex}.status-item{background:#00000040;border:1px solid #ffffff0d;border-radius:6px;flex-direction:row;align-items:center;gap:6px;padding:4px 10px;display:flex}.status-item .label{color:var(--text-muted);font-size:.72rem;font-weight:500;display:inline-block}.status-item .value{white-space:nowrap;align-items:center;gap:4px;font-size:.78rem;font-weight:600;display:flex}.indicator{border-radius:50%;width:8px;height:8px;display:inline-block}.indicator.online{background:#10b981;box-shadow:0 0 10px #10b981}.indicator.indexing{background:#f59e0b;animation:1.5s infinite pulse;box-shadow:0 0 10px #f59e0b}@keyframes pulse{0%{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(1.2)}to{opacity:1;transform:scale(1)}}.glass-card{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);width:100%;min-width:0;padding:16px 20px}.glass-card h2{align-items:center;gap:8px;margin-bottom:12px;font-size:1.05rem;font-weight:600;display:flex}.tab-content{width:100%;min-width:0;display:none}.tab-content.active{flex-direction:column;gap:16px;width:100%;min-width:0;display:flex}.overview-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,200px),1fr));gap:12px;display:grid}.stat-metric{align-items:center;gap:12px;padding:14px 16px;display:flex}.metric-icon{color:var(--accent-light);background:#14b8a626;border-radius:10px;justify-content:center;align-items:center;width:40px;height:40px;font-size:1.4rem;display:flex}.metric-info{flex-direction:column;gap:4px;display:flex}.metric-info .stat-number{font-size:var(--font-size-xl);font-weight:var(--font-weight-extrabold);font-family:var(--font-family-mono);color:var(--text);line-height:1.1}.metric-info .stat-label{color:var(--text-muted);font-size:.85rem}.two-col-layout{grid-template-columns:1fr 1fr;gap:20px;display:grid}@media (width<=900px){.two-col-layout{grid-template-columns:1fr}}.specs-list{flex-direction:column;gap:12px;margin-top:12px;display:flex}.spec-row{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;gap:12px;padding:10px 0;font-size:.9rem;display:flex}.spec-row span:first-child{color:var(--text-muted);flex-shrink:0;font-weight:500}code,.code{background:var(--code-bg);vertical-align:baseline;word-break:break-word;overflow-wrap:break-word;border-radius:4px;max-width:100%;padding:1px 5px;font-family:JetBrains Mono,Fira Code,monospace;font-size:.85em;line-height:1.25;display:inline-block}.spec-row span:last-child,.spec-row code{text-align:right;word-break:break-word;max-width:100%}@media (width<=576px){.spec-row{flex-direction:column;align-items:flex-start;gap:6px}.spec-row span:last-child,.spec-row code{text-align:left}.stat-metric{padding:16px}.path-input-row{flex-direction:column}.browser-breadcrumbs{word-break:break-all}}.tag-cloud{flex-wrap:wrap;gap:8px;max-height:250px;margin-top:12px;display:flex;overflow-y:auto}.topic-tag{background:color-mix(in srgb, var(--accent) 12%, transparent);border:1px solid color-mix(in srgb, var(--accent) 25%, transparent);color:var(--accent);font-size:var(--font-size-xs);font-family:var(--font-family-mono);border-radius:6px;padding:4px 10px}.badge{white-space:nowrap;border-radius:6px;align-items:center;gap:6px;max-width:100%;padding:3px 8px;font-size:.75rem;font-weight:600;display:inline-flex}.badge-primary{background:color-mix(in srgb, var(--primary) 15%, transparent);color:var(--primary);border:1px solid color-mix(in srgb, var(--primary) 30%, transparent)}.badge-accent{background:color-mix(in srgb, var(--accent) 15%, transparent);color:var(--accent);border:1px solid color-mix(in srgb, var(--accent) 30%, transparent)}.badge-success{color:#6ee7b7;background:#10b98133;border:1px solid #10b9814d}.badge-danger{color:#fca5a5;background:#ef444433;border:1px solid #ef44444d}code,.code{font-family:var(--font-family-mono);background:var(--code-bg);border-radius:4px;padding:2px 6px;font-size:.85rem}.desktop-table-view{display:block}.mobile-card-list{flex-direction:column;gap:14px;display:none}.data-mobile-card{border:1px solid var(--border-card);background:#ffffff06;border-radius:10px;flex-direction:column;gap:12px;padding:16px;display:flex}.data-mobile-card-header{justify-content:space-between;align-items:center;gap:10px;display:flex}.data-mobile-card-body{flex-direction:column;gap:8px;font-size:.85rem;display:flex}.data-mobile-card-actions{border-top:1px solid #ffffff0f;flex-wrap:wrap;gap:8px;margin-top:4px;padding-top:10px;display:flex}.data-mobile-card-actions .btn{flex:calc(50% - 8px);justify-content:center;min-width:0}.card-header-btn{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;margin-bottom:16px;display:flex}.card-header-btn>div{flex:1 1 0;min-width:0;max-width:100%}.card-header-btn p{overflow-wrap:anywhere;word-break:break-word;margin:0}.table-container{-webkit-overflow-scrolling:touch;max-width:100%;margin-top:10px;overflow-x:auto}table{border-collapse:collapse;table-layout:auto;width:100%;font-size:.9rem}th{text-align:left;color:var(--text-muted);border-bottom:1px solid var(--border-card);white-space:nowrap;padding:12px 14px;font-weight:600}td{border-bottom:1px solid var(--border-card);color:var(--text);padding:14px}td a.repo-url-link,td a[href*=http]{text-overflow:ellipsis;white-space:nowrap;vertical-align:middle;max-width:220px;display:inline-block;overflow:hidden}tr:hover td{background:color-mix(in srgb, var(--text) 3%, transparent)}.empty-state{text-align:center;color:var(--text-muted);padding:40px!important}.btn{cursor:pointer;border:none;border-radius:8px;align-items:center;gap:8px;padding:8px 16px;font-family:inherit;font-size:.9rem;font-weight:600;transition:all .2s;display:inline-flex}.btn-primary{background:var(--primary);color:#fff}.btn-primary:hover{background:var(--primary-hover)}.btn-secondary{background:color-mix(in srgb, var(--text) 10%, transparent);color:var(--text);border:1px solid var(--border-card)}.btn-secondary:hover{background:color-mix(in srgb, var(--text) 16%, transparent)}.btn-icon{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;padding:6px;font-size:.9rem;transition:all .2s}.btn-icon:hover{color:var(--text);background:color-mix(in srgb, var(--text) 10%, transparent)}.btn-delete:hover{color:var(--danger)}.form-group{flex-direction:column;gap:6px;margin-bottom:14px;display:flex}.form-group label{color:var(--text-muted);font-size:.85rem;font-weight:600}.form-row{box-sizing:border-box;gap:14px;width:100%;display:flex}.form-row>.form-group{flex:1;min-width:0}.form-row-3col{box-sizing:border-box;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:12px;width:100%;display:grid}.form-row-3col>.form-group{min-width:0}input[type=text],input[type=url],input[type=password],input[type=number],select,textarea{background:var(--code-bg);border:1px solid var(--border-card);color:var(--text);box-sizing:border-box;border-radius:8px;outline:none;width:100%;min-width:0;max-width:100%;padding:10px 14px;font-family:inherit;font-size:.9rem;transition:border-color .2s}input:focus,select:focus,textarea:focus{border-color:var(--primary)}.path-input-row{gap:8px;display:flex}.path-input-row input{flex:1}.modal-backdrop{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);z-index:10000;box-sizing:border-box;background:#000000bf;justify-content:center;align-items:center;width:100vw;max-width:100vw;height:100vh;padding:24px 16px;display:flex;position:fixed;inset:0;overflow-y:auto}.modal-card{background:var(--bg-card);border:1px solid var(--border-card);box-sizing:border-box;width:90%;max-width:550px;max-height:calc(100vh - 48px);margin:auto;overflow-y:auto}.modal-header{justify-content:space-between;align-items:center;margin-bottom:20px;display:flex}.modal-header h2{margin-bottom:0}.btn-close{color:var(--text-muted);cursor:pointer;background:0 0;border:none;font-size:1.5rem}.modal-footer{justify-content:flex-end;gap:10px;margin-top:20px;display:flex}.browser-body{margin:16px 0}.browser-breadcrumbs{background:#0000004d;border-radius:6px;margin-bottom:12px;padding:8px 12px;font-size:.85rem}.browser-list-container{background:#0003;border:1px solid #ffffff14;border-radius:6px;max-height:300px;overflow-y:auto}.browser-list{list-style:none}.browser-item{cursor:pointer;border-bottom:1px solid #ffffff0a;align-items:center;gap:10px;padding:8px 12px;font-size:.9rem;display:flex}.browser-item:hover{background:#ffffff0f}.search-hit-card{background:#0000004d;border:1px solid #ffffff14;border-radius:8px;margin-bottom:14px;padding:16px}.search-hit-header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;margin-bottom:10px;display:flex}.search-hit-code{background:var(--code-bg);border:1px solid var(--border-card);font-family:var(--font-family-mono);white-space:pre-wrap;word-break:break-all;color:var(--text);border-radius:6px;margin-top:8px;padding:12px;font-size:.85rem;overflow-x:auto}.search-mode-segmented{border:1px solid var(--border-card);background:#ffffff0d;border-radius:8px;gap:4px;margin-bottom:14px;padding:3px;display:inline-flex}.search-mode-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;align-items:center;gap:6px;padding:6px 14px;font-size:.85rem;transition:all .15s ease-in-out;display:flex}.search-mode-btn:hover{color:var(--text);background:#ffffff0f}.search-mode-btn.active{background:var(--primary);color:#fff;font-weight:600;box-shadow:0 2px 6px #0003}.hybrid-slider-container{border:1px solid var(--border-card);background:#ffffff05;border-radius:8px;margin-bottom:16px;padding:12px 16px}.hybrid-slider-header{justify-content:space-between;align-items:center;margin-bottom:8px;font-size:.85rem;display:flex}.hybrid-split-value{font-family:var(--font-family-mono);color:var(--accent);font-weight:600}.hybrid-range-input{width:100%;accent-color:var(--primary);cursor:pointer}.hybrid-presets{flex-wrap:wrap;gap:6px;margin-top:10px;display:flex}.btn-preset{border:1px solid var(--border-card);color:var(--text-muted);cursor:pointer;background:#ffffff0a;border-radius:4px;padding:3px 8px;font-size:.75rem;transition:all .15s}.btn-preset:hover{color:var(--text);border-color:var(--primary);background:rgba(var(--primary-rgb), .1)}.btn-preset.active{background:rgba(var(--primary-rgb), .25);border-color:var(--primary);color:var(--primary);font-weight:600}.search-hit-signature{border-left:3px solid var(--primary);font-family:var(--font-family-mono);color:var(--accent);background:#ffffff08;border-radius:0 4px 4px 0;margin-bottom:6px;padding:6px 10px;font-size:.82rem;overflow-x:auto}.search-hit-actions{align-items:center;gap:8px;display:flex}.badge-info{color:#38bdf8;background:#38bdf826;border:1px solid #38bdf84d}.badge-warning{color:#fbbf24;background:#fbbf2426;border:1px solid #fbbf244d}.dashboard-footer{text-align:center;color:var(--text-muted);padding:20px 0;font-size:.8rem}@media (width<=768px){.menu-toggle-btn{justify-content:center;align-items:center;display:inline-flex}.dashboard-header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px;min-height:auto;max-height:none;padding:12px 14px;display:flex}.header-brand{order:1;align-items:center;display:flex}.menu-toggle-btn{order:2;justify-content:center;align-items:center;display:inline-flex}.header-status{border-top:1px solid #ffffff0f;flex-wrap:wrap;order:3;justify-content:space-between;gap:8px 12px;width:100%;padding-top:8px;display:flex}.status-item{align-items:center}.dashboard-nav{border:1px solid var(--border-card);border-radius:var(--radius);background:#00000059;flex-direction:column;gap:6px;max-height:60vh;margin:4px 0 0;padding:10px;display:none;overflow:auto}.dashboard-nav.drawer-open{animation:.25s ease-out forwards drawer-slide-down;display:flex}.nav-tab{justify-content:flex-start;width:100%;padding:10px 14px;font-size:.92rem}.dashboard-container{box-sizing:border-box;max-width:100vw;padding:16px 12px}.vs-box{box-sizing:border-box;max-width:100%;padding:16px 12px}.glass-card{box-sizing:border-box;max-width:100%;padding:18px 14px}.desktop-table-view{display:none}.mobile-card-list{display:flex}.card-header-btn{flex-direction:column;align-items:stretch;gap:14px}.form-row,.form-row-3col{flex-direction:column;gap:12px;display:flex!important}.search-hit-header{flex-direction:column;align-items:flex-start;gap:8px}.search-form-btn-group{align-self:stretch!important}.search-form-btn-group .btn{justify-content:center;width:100%}.log-viewer-header{flex-direction:column;align-items:stretch;gap:12px}.log-viewer-actions{justify-content:space-between;width:100%}.log-toolbar{flex-direction:column;align-items:stretch;gap:12px}.log-filter-pills{-webkit-overflow-scrolling:touch;padding-bottom:4px;overflow-x:auto}.log-search-wrapper{width:100%;min-width:0;max-width:100%}.log-entry-main{flex-direction:column;align-items:flex-start;gap:4px}.sync-progress-container{min-width:unset;width:100%;max-width:100%}.sync-file-caption{max-width:100%}}@keyframes drawer-slide-down{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toast-container{z-index:9999;pointer-events:none;flex-direction:column;gap:10px;display:flex;position:fixed;bottom:24px;right:24px}.toast{color:#fff;pointer-events:auto;background:#1e293b;border-left:4px solid #0000;border-radius:8px;align-items:center;gap:12px;max-width:400px;padding:14px 20px;font-size:.95rem;font-weight:500;animation:.3s ease-out forwards toast-slide-in;display:flex;box-shadow:0 10px 25px #00000080}@keyframes toast-slide-in{0%{opacity:0;transform:translate(50px)}to{opacity:1;transform:translate(0)}}.toast-success{border-left-color:#10b981}.toast-success i{color:#10b981}.toast-error{border-left-color:#ef4444}.toast-error i{color:#ef4444}.toast-info{border-left-color:#3b82f6}.toast-info i{color:#3b82f6}.toast-warning{border-left-color:#f59e0b}.toast-warning i{color:#f59e0b}.toast-message{flex:1;line-height:1.4}.toast-dismiss-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:4px;justify-content:center;align-items:center;margin-left:6px;padding:4px;font-size:.85rem;transition:all .2s;display:inline-flex}.toast-dismiss-btn:hover{color:#fff;background:#ffffff1f}.log-viewer-container{flex-direction:column;gap:16px;display:flex}.log-viewer-header{flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:16px;display:flex}.log-viewer-actions{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.log-autoscroll-label{color:var(--text-muted);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:6px;font-size:.85rem;font-weight:500;display:inline-flex}.log-autoscroll-label input[type=checkbox]{cursor:pointer;accent-color:var(--primary)}.log-toolbar{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:16px;display:flex}.log-filter-pills{flex-wrap:wrap;gap:8px;display:flex}.log-filter-btn{color:var(--text-muted);cursor:pointer;background:#ffffff0d;border:1px solid #ffffff1a;border-radius:20px;align-items:center;gap:6px;padding:5px 12px;font-family:inherit;font-size:.8rem;font-weight:600;transition:all .2s;display:inline-flex}.log-filter-btn:hover{color:var(--text);background:#ffffff1a}.log-filter-btn.active{color:#93c5fd;background:#3b82f633;border-color:#3b82f666}.log-filter-btn.warning.active{color:#fcd34d;background:#f59e0b33;border-color:#f59e0b66}.log-filter-btn.error.active{color:#fca5a5;background:#ef444433;border-color:#ef444466}.log-filter-btn.debug.active{color:#cbd5e1;background:#94a3b833;border-color:#94a3b866}.pill-count{background:#0000004d;border-radius:10px;padding:1px 6px;font-size:.72rem}.log-search-wrapper{flex:1;align-items:center;min-width:280px;max-width:480px;display:flex;position:relative}.log-search-wrapper .search-icon{color:var(--text-muted);pointer-events:none;font-size:.85rem;position:absolute;left:12px}.log-search-input{background:var(--code-bg);border:1px solid var(--border-card);width:100%;color:var(--text);border-radius:8px;outline:none;padding:8px 32px 8px 34px;font-family:inherit;font-size:.85rem;transition:border-color .2s}.log-search-input:focus{border-color:var(--primary)}.clear-search-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;padding:4px;font-size:.8rem;position:absolute;right:8px}.clear-search-btn:hover{color:var(--text)}.log-stream-container{background:var(--code-bg);border:1px solid var(--border-card);min-height:320px;max-height:580px;font-family:var(--font-family-mono);border-radius:8px;padding:12px;overflow-y:auto}.log-stream-list{flex-direction:column;gap:4px;display:flex}.log-entry{background:#ffffff04;border-left:3px solid #0000;border-radius:6px;padding:8px 12px;font-size:.82rem;line-height:1.5;transition:background .15s}.log-entry:hover{background:#ffffff09}.log-entry.log-level-info{border-left-color:#3b82f6}.log-entry.log-level-warning{background:#f59e0b08;border-left-color:#f59e0b}.log-entry.log-level-error{background:#ef44440f;border-left-color:#ef4444}.log-entry.log-level-debug{opacity:.85;border-left-color:#64748b}.log-entry-main{flex-wrap:wrap;align-items:baseline;gap:10px;display:flex}.log-timestamp{color:var(--text-muted);white-space:nowrap;font-size:.78rem}.log-logger{color:var(--accent-light);font-size:.78rem}.log-message{color:#e2e8f0;word-break:break-word;flex:1}.btn-traceback-toggle{color:#fca5a5;cursor:pointer;background:#ef44441f;border:1px solid #ef44444d;border-radius:4px;align-items:center;gap:5px;padding:2px 8px;font-family:inherit;font-size:.75rem;transition:all .2s;display:inline-flex}.btn-traceback-toggle:hover{background:#ef444438}.log-traceback-wrapper{margin-top:8px;padding-left:8px}.traceback-box{background:color-mix(in srgb, var(--danger) 10%, transparent);border:1px solid color-mix(in srgb, var(--danger) 30%, transparent);color:var(--danger);font-family:var(--font-family-mono);white-space:pre-wrap;border-radius:6px;padding:10px 14px;font-size:.78rem;line-height:1.45;overflow-x:auto}.settings-dashboard-layout{align-items:flex-start;gap:20px;width:100%;min-height:520px;display:flex}.settings-category-sidebar{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);box-sizing:border-box;flex-direction:column;gap:4px;width:240px;min-width:240px;padding:10px;display:flex}.settings-category-btn{width:100%;color:var(--text-muted);cursor:pointer;text-align:left;background:0 0;border:none;border-radius:6px;align-items:center;gap:10px;padding:10px 14px;font-size:.84rem;font-weight:500;transition:all .2s;display:flex}.settings-category-btn svg,.settings-category-btn i{text-align:center;flex-shrink:0;width:16px}.settings-category-btn:hover{color:var(--text);background:#ffffff0d}.settings-category-btn.active{color:var(--text);border-left:3px solid var(--primary);background:#0891b22e;font-weight:600}.settings-active-panel{flex-direction:column;flex:1;min-width:0;display:flex}@media (width<=840px){.settings-dashboard-layout{flex-direction:column}.settings-category-sidebar{flex-direction:row;width:100%;min-width:100%;padding:6px;overflow-x:auto}.settings-category-btn{white-space:nowrap;padding:8px 12px}.settings-category-btn.active{border-left:none;border-bottom:2px solid var(--primary)}}.vs-config-layout{box-sizing:border-box;grid-template-columns:1fr 1fr;gap:20px;width:100%;min-width:0;margin-top:16px;display:grid}@media (width<=960px){.vs-config-layout{grid-template-columns:1fr}}.vs-box{border:1px solid var(--border-card);box-sizing:border-box;overflow-wrap:break-word;background:#ffffff05;border-radius:10px;width:100%;min-width:0;padding:20px}.vs-box h3{color:var(--text);align-items:center;gap:8px;margin-bottom:14px;font-size:1rem;font-weight:600;display:flex}.vs-feedback-banner{border-radius:8px;align-items:center;gap:10px;margin-bottom:16px;padding:10px 14px;font-size:.85rem;line-height:1.4;display:flex}.feedback-success{color:#6ee7b7;background:#10b9811f;border:1px solid #10b9814d}.feedback-error{color:#fca5a5;background:#ef44441f;border:1px solid #ef44444d}.theme-options-grid{grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px;margin-top:12px;display:grid}.theme-card{background:var(--bg-card);border:1.5px solid var(--border-card);border-radius:var(--radius);cursor:pointer;text-align:left;flex-direction:column;gap:8px;padding:12px 14px;transition:all .2s;display:flex;position:relative}.theme-card:hover{border-color:color-mix(in srgb, var(--primary) 60%, transparent);transform:translateY(-2px)}.theme-card.active{border-color:var(--primary);box-shadow:0 0 0 1px var(--primary), 0 4px 14px #00000040}.theme-card-header{justify-content:space-between;align-items:center;display:flex}.theme-card-title{color:var(--text);align-items:center;gap:6px;font-size:.92rem;font-weight:600;display:flex}.theme-card-desc{color:var(--text-muted);font-size:.76rem;line-height:1.35}.theme-swatches{align-items:center;gap:6px;padding-top:2px;display:flex}.theme-swatch{border:1px solid #fff3;border-radius:50%;width:18px;height:18px;box-shadow:0 1px 3px #00000040}.sync-drawer-backdrop{-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);z-index:1100;background:#000000a6;justify-content:flex-end;width:100vw;height:100vh;display:flex;position:fixed;top:0;left:0}.sync-drawer{background:var(--bg-card,#111827);border-left:1px solid var(--border-card);flex-direction:column;width:620px;max-width:95vw;height:100vh;animation:.25s cubic-bezier(.16,1,.3,1) slideInRight;display:flex;box-shadow:-10px 0 35px #0000008c}.sync-drawer-header{border-bottom:1px solid var(--border-card);background:#0003;justify-content:space-between;align-items:flex-start;gap:14px;padding:18px 22px;display:flex}.sync-drawer-title-group{flex-direction:column;flex:1;gap:4px;display:flex}.sync-drawer-body{flex-direction:column;flex:1;gap:18px;padding:20px 22px;display:flex;overflow-y:auto}.sync-progress-section{border:1px solid var(--border-card);background:#0003;border-radius:8px;padding:12px 14px}.sync-progress-bar-container{background:#ffffff14;border-radius:4px;width:100%;height:8px;overflow:hidden}.sync-progress-bar-fill{border-radius:4px;height:100%;transition:width .3s,background .3s}.sync-progress-bar-fill.fill-active{background:var(--primary)}.sync-progress-bar-fill.fill-success{background:#10b981}.sync-progress-bar-fill.fill-error{background:#ef4444}.sync-progress-container{box-sizing:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;flex-direction:column;gap:5px;width:100%;min-width:140px;max-width:100%;transition:opacity .2s,transform .15s;display:flex}.sync-progress-container:hover{opacity:.92}.sync-progress-container:focus-visible{outline:2px solid var(--primary);border-radius:6px}.progress-pill{white-space:nowrap;box-sizing:border-box;border-radius:12px;align-items:center;gap:6px;min-width:0;max-width:100%;padding:3px 8px;font-size:.76rem;font-weight:600;display:inline-flex}.progress-pill>span{text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;overflow:hidden}.sync-progress-bar-wrapper{background:#ffffff14;border-radius:3px;width:100%;height:6px;overflow:hidden}.sync-file-caption{color:var(--text-muted);font-size:.72rem;font-family:var(--font-family-mono);text-overflow:ellipsis;white-space:nowrap;align-items:center;min-width:0;max-width:100%;display:flex;overflow:hidden}.sync-file-caption code{text-overflow:ellipsis;white-space:nowrap;max-width:100%;padding:1px 4px;font-size:.72rem;overflow:hidden}.sync-stepper-container{border:1px solid var(--border-card);background:#0003;border-radius:8px;padding:14px 16px}.sync-stepper-list{flex-direction:column;gap:10px;display:flex}.sync-stepper-item{border-radius:6px;align-items:flex-start;gap:12px;padding:8px 10px;transition:background .15s;display:flex}.sync-stepper-item.item-active{background:#f59e0b1a;border:1px solid #f59e0b40}.sync-stepper-item.item-completed{background:#10b9810d}.sync-stepper-item.item-error{background:#ef44441a;border:1px solid #ef444440}.sync-stepper-icon{justify-content:center;align-items:center;min-width:18px;margin-top:1px;font-size:1rem;display:flex}.sync-stepper-content{color:var(--text);flex-direction:column;flex:1;gap:2px;font-size:.88rem;display:flex}.sync-stepper-details{margin-top:4px;font-size:.8rem}.sync-current-file{font-family:var(--font-family-mono);color:var(--accent,#60a5fa);word-break:break-all;font-size:.78rem}.sync-terminal-section{background:#0d1117;border:1px solid #ffffff1f;border-radius:8px;flex-direction:column;flex:1;min-height:260px;display:flex;overflow:hidden}.sync-terminal-header{background:#161b22;border-bottom:1px solid #ffffff1a;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;padding:10px 14px;display:flex}.sync-terminal-actions{align-items:center;gap:12px;display:flex}.sync-autoscroll-toggle{color:var(--text-muted);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:6px;font-size:.78rem;display:flex}.sync-terminal-search{background:#11161d;border-bottom:1px solid #ffffff14;align-items:center;gap:8px;padding:6px 14px;display:flex}.sync-terminal-body{font-family:var(--font-family-mono,monospace);color:#e6edf3;flex:1;min-height:180px;max-height:380px;padding:12px 14px;font-size:.8rem;overflow-y:auto}.sync-terminal-empty{color:#8b949e;flex-direction:column;justify-content:center;align-items:center;height:160px;font-size:.85rem;display:flex}.sync-terminal-lines{flex-direction:column;gap:4px;display:flex}.sync-terminal-line{word-break:break-all;align-items:flex-start;gap:8px;line-height:1.45;display:flex}.log-time{color:#8b949e;flex-shrink:0;font-size:.75rem}.log-badge{border-radius:3px;flex-shrink:0;padding:0 4px;font-size:.7rem;font-weight:700}.log-badge.level-info{color:#38bdf8;background:#38bdf833}.log-badge.level-warn{color:#fbbf24;background:#fbbf2433}.log-badge.level-error{color:#f87171;background:#f8717133}.log-msg{color:#e6edf3;flex:1}theme-editor-overlay{pointer-events:none!important}theme-editor-overlay button,theme-editor-overlay [role=button],theme-editor-overlay a{pointer-events:auto!important}.stats-grid{grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px;margin-bottom:24px;display:grid}.stat-card{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);border-radius:8px;align-items:center;gap:12px;min-width:0;padding:12px 14px;transition:border-color .2s,box-shadow .2s;display:flex;box-shadow:0 2px 8px #00000026}.stat-card:hover{border-color:var(--primary,#00bd7e)}.stat-icon{width:40px;height:40px;color:var(--primary,#00bd7e);background:#00bd7e1f;border-radius:8px;flex-shrink:0;justify-content:center;align-items:center;display:flex}.stat-icon svg{width:20px;height:20px}.stat-info{flex-direction:column;gap:2px;min-width:0;display:flex;overflow:hidden}.stat-label{color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.04em;white-space:nowrap;text-overflow:ellipsis;font-size:.76rem;font-weight:500;overflow:hidden}.stat-value{color:var(--text-color,#e2e8f0);white-space:nowrap;text-overflow:ellipsis;min-width:0;font-size:1.25rem;font-weight:700;line-height:1.2;overflow:hidden}.catalog-filter-bar{border:1px solid var(--border-card,#15474d);background:#0003;border-radius:10px;margin-bottom:24px;padding:16px}.catalog-filter-inputs{grid-template-columns:repeat(auto-fit,minmax(200px,1fr));align-items:flex-end;gap:14px;display:grid}.catalog-filter-inputs .form-group input{box-sizing:border-box;height:36px}.files-storage-page{flex-direction:column;gap:0;height:100%;display:flex}.files-storage-header{border-bottom:1px solid var(--border-card,#15474d);flex-wrap:wrap;flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:16px 20px 12px;display:flex}.files-storage-header .page-title{color:var(--text);margin:0;font-size:1.1rem;font-weight:600}.files-storage-section-tabs{background:var(--bg-card);border:1px solid var(--border-card,#15474d);border-radius:8px;gap:6px;padding:4px;display:flex}.section-tab{color:var(--text-muted);cursor:pointer;white-space:nowrap;background:0 0;border:none;border-radius:6px;align-items:center;gap:6px;padding:6px 14px;font-size:.85rem;transition:background .15s,color .15s;display:flex}.section-tab:hover{color:var(--text);background:#ffffff0f}.section-tab.active{background:var(--primary,#0d9488);color:#fff;font-weight:500}.files-storage-content{flex:1;min-height:0;overflow:auto}.topology-container{flex-direction:column;gap:16px;display:flex;position:relative}.topology-toolbar{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:14px 18px;display:flex}.topology-toolbar-group{flex-wrap:wrap;align-items:center;gap:10px;display:flex}.topology-select,.topology-input{border:1px solid var(--border-card);color:var(--text);background:#00000059;border-radius:8px;outline:none;padding:7px 12px;font-family:inherit;font-size:.85rem;transition:all .2s}.topology-select:focus,.topology-input:focus{border-color:var(--primary);box-shadow:0 0 0 2px #3b82f633}.topology-view-btn-group{border:1px solid var(--border-card);background:#00000059;border-radius:8px;display:inline-flex;overflow:hidden}.topology-view-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;padding:6px 12px;font-size:.82rem;transition:all .15s}.topology-view-btn:hover{color:var(--text)}.topology-view-btn.active{background:var(--primary);color:#fff;font-weight:500}.topology-filter-chip{cursor:pointer;-webkit-user-select:none;user-select:none;border:1px solid #0000;border-radius:6px;align-items:center;gap:6px;padding:4px 10px;font-size:.78rem;font-weight:500;transition:all .15s;display:inline-flex}.topology-filter-chip.chip-file{color:#38bdf8;background:#0ea5e926;border-color:#0ea5e94d}.topology-filter-chip.chip-class{color:#c084fc;background:#a855f726;border-color:#a855f74d}.topology-filter-chip.chip-function{color:#34d399;background:#10b98126;border-color:#10b9814d}.topology-filter-chip.chip-route{color:#fbbf24;background:#f59e0b26;border-color:#f59e0b4d}.topology-filter-chip.chip-orphan{color:#fb7185;background:#f43f5e26;border-color:#f43f5e4d}.topology-filter-chip.inactive{opacity:.4;filter:grayscale(80%);color:var(--text-muted);border-color:var(--border-card);background:#ffffff0d}.topology-canvas-wrapper{border:1px solid var(--border-card);border-radius:var(--radius);cursor:grab;background:radial-gradient(circle,#121a2fbf 0%,#0a0f1df2 100%);width:100%;height:640px;position:relative;overflow:hidden}.topology-canvas-wrapper:active{cursor:grabbing}.topology-canvas-wrapper svg{width:100%;height:100%;display:block}.topology-node{cursor:pointer;transition:filter .15s,transform .15s}.topology-node:hover{filter:drop-shadow(0 0 8px #3b82f6cc)}.topology-node.selected{filter:drop-shadow(0 0 12px #14b8a6f2)}.topology-node.highlighted{filter:drop-shadow(0 0 14px #f59e0b)}.topology-edge{transition:stroke-opacity .2s,stroke-width .2s}.topology-controls-panel{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);z-index:10;background:#121a2fd9;border-radius:10px;align-items:center;gap:6px;padding:6px 10px;display:flex;position:absolute;bottom:20px;left:20px}.topology-btn-ctrl{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;padding:6px 8px;font-size:.85rem;transition:all .15s}.topology-btn-ctrl:hover{color:var(--text);background:#ffffff1a}.topology-legend{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);z-index:10;background:#121a2fd9;border-radius:10px;flex-wrap:wrap;gap:8px;padding:8px 12px;display:flex;position:absolute;top:20px;left:20px}.topology-minimap{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);z-index:10;pointer-events:none;background:#0a0f1dd9;border-radius:8px;width:140px;height:95px;position:absolute;bottom:20px;right:20px;overflow:hidden}.topology-minimap svg{width:100%;height:100%}.topology-drawer{border-left:1px solid var(--border-card);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);z-index:50;background:#0f172af2;flex-direction:column;width:440px;max-width:90%;height:100%;animation:.25s cubic-bezier(.16,1,.3,1) slideInRight;display:flex;position:absolute;top:0;right:0;box-shadow:-10px 0 30px #00000080}@keyframes slideInRight{0%{transform:translate(100%)}to{transform:translate(0)}}.topology-drawer-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;padding:16px 20px;display:flex}.topology-drawer-body{flex-direction:column;flex:1;gap:16px;padding:20px;display:flex;overflow-y:auto}.topology-drawer-section{flex-direction:column;gap:8px;display:flex}.topology-drawer-section-title{text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);font-size:.8rem;font-weight:600}.topology-code-snippet{background:var(--code-bg);border:1px solid var(--border-card);font-family:var(--font-family-mono);color:var(--text);white-space:pre-wrap;border-radius:8px;max-height:220px;padding:12px;font-size:.78rem;line-height:1.45;overflow-x:auto}.topology-neighbor-list{flex-direction:column;gap:6px;display:flex}.topology-neighbor-item{border:1px solid var(--border-card);cursor:pointer;background:#ffffff08;border-radius:6px;justify-content:space-between;align-items:center;padding:8px 12px;font-size:.82rem;transition:all .15s;display:flex}.topology-neighbor-item:hover{border-color:var(--primary);background:#ffffff12}.topology-badge-type{text-transform:uppercase;border-radius:4px;align-items:center;gap:4px;padding:2px 8px;font-size:.72rem;font-weight:600;display:inline-flex}.badge-file{color:#38bdf8;background:#0ea5e933}.badge-class{color:#c084fc;background:#a855f733}.badge-function{color:#34d399;background:#10b98133}.badge-route{color:#fbbf24;background:#f59e0b33}.badge-module{color:#818cf8;background:#6366f133}.badge-edge-imports{color:#38bdf8;background:#0ea5e926}.badge-edge-calls{color:#34d399;background:#10b98126}.badge-edge-defines{color:#c084fc;background:#a855f726}.badge-edge-handles{color:#fbbf24;background:#f59e0b26}.badge-edge-routes-to{color:#fb7185;background:#f43f5e26}.badge-edge-doc-links-to{color:#a78bfa;background:#a78bfa26}.topology-search-results{border:1px solid var(--border-card);z-index:60;background:#0f172afa;border-radius:8px;max-height:240px;margin-top:4px;position:absolute;top:100%;left:0;right:0;overflow-y:auto;box-shadow:0 10px 25px #00000080}.topology-search-item{cursor:pointer;border-bottom:1px solid #ffffff0d;justify-content:space-between;align-items:center;padding:8px 12px;font-size:.82rem;display:flex}.topology-search-item:hover{background:#3b82f626}.topology-empty-state{height:100%;color:var(--text-muted);flex-direction:column;justify-content:center;align-items:center;gap:12px;display:flex}.neighborhood-view{flex-direction:column;gap:14px;width:100%;display:flex;position:relative}.neighborhood-breadcrumbs{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;display:flex}.neighborhood-breadcrumbs-left{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.neighborhood-breadcrumbs-right{flex-wrap:wrap;align-items:center;gap:14px;display:flex}.neighborhood-focal-selector-wrap{align-items:center;gap:6px;display:inline-flex}.neighborhood-focal-label{color:var(--text-muted);white-space:nowrap;font-size:.78rem;font-weight:600}.neighborhood-focal-select{max-width:260px;padding:4px 10px;font-size:.82rem}.neighborhood-back-btn{align-items:center;gap:6px;padding:5px 10px;font-size:.8rem;display:inline-flex}.neighborhood-breadcrumb-trail{flex-wrap:wrap;align-items:center;gap:6px;display:inline-flex}.neighborhood-breadcrumb-sep{color:var(--text-muted);-webkit-user-select:none;user-select:none;margin:0 2px;font-size:.9rem}.neighborhood-breadcrumb-item{cursor:pointer;color:var(--text-muted);background:0 0;border:1px solid #0000;border-radius:6px;align-items:center;gap:6px;padding:3px 8px;font-size:.82rem;transition:all .15s;display:inline-flex}.neighborhood-breadcrumb-item:hover{color:var(--text);background:#ffffff0f}.neighborhood-breadcrumb-item.active{color:var(--text);background:#3b82f626;border-color:#3b82f64d;font-weight:600}.neighborhood-breadcrumb-badge{padding:1px 5px;font-size:.65rem}.neighborhood-breadcrumb-text{font-family:var(--font-family-mono,monospace)}.neighborhood-hop-selector{align-items:center;gap:8px;display:inline-flex}.neighborhood-hop-label{color:var(--text-muted);font-size:.8rem;font-weight:500}.neighborhood-panels{grid-template-columns:280px 1fr 280px;gap:14px;min-height:640px;display:grid}@media (width<=1100px){.neighborhood-panels{grid-template-columns:1fr}}.neighborhood-panel{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-direction:column;max-height:640px;padding:14px;display:flex;overflow:hidden}.neighborhood-panel-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;margin-bottom:10px;padding-bottom:10px;display:flex}.neighborhood-panel-title{color:var(--text);align-items:center;gap:8px;font-size:.85rem;font-weight:600;display:flex}.neighborhood-panel-count{color:var(--text-muted);background:#ffffff14;border-radius:12px;padding:2px 8px;font-size:.75rem;font-weight:600}.neighborhood-panel-list{flex-direction:column;flex:1;gap:8px;padding-right:2px;display:flex;overflow-y:auto}.neighborhood-panel-item{border:1px solid var(--border-card);background:#ffffff05;border-radius:8px;flex-direction:column;gap:6px;padding:10px;transition:all .15s;display:flex}.neighborhood-panel-item:hover{background:#ffffff0d;border-color:#3b82f666}.neighborhood-panel-item-header{justify-content:space-between;align-items:center;gap:6px;display:flex}.neighborhood-panel-item-name{font-family:var(--font-family-mono,monospace);color:var(--text);word-break:break-all;font-size:.8rem}.neighborhood-panel-item-actions{gap:6px;margin-top:4px;display:flex}.neighborhood-panel-empty{text-align:center;color:var(--text-muted);padding:24px 8px;font-size:.8rem}.neighborhood-center{flex-direction:column;min-height:640px;display:flex;position:relative}.neighborhood-canvas-wrapper{border:1px solid var(--border-card);border-radius:var(--radius);background:radial-gradient(circle,#121a2fbf 0%,#0a0f1df2 100%);width:100%;height:100%;min-height:640px;position:relative;overflow:hidden}.neighborhood-svg{width:100%;height:100%;display:block}.neighborhood-orbital-ring{fill:none;stroke:#94a3b82e;stroke-dasharray:4 4;stroke-width:1.5px}.neighborhood-orbital-ring.ring-2{stroke:#94a3b81f}.neighborhood-orbital-label{fill:var(--text-muted);letter-spacing:.04em;pointer-events:none;text-transform:uppercase;font-size:10px}.neighborhood-edge-path{transition:stroke-opacity .2s,stroke-width .2s}.neighborhood-edge-path:hover{stroke-opacity:1;stroke-width:2.5px}.neighborhood-node-item{transition:transform .15s,filter .15s}.neighborhood-node-item:hover{filter:drop-shadow(0 0 10px #3b82f6d9)}.neighborhood-node-circle{transition:filter .15s,stroke-width .15s}.neighborhood-node-name{font-family:var(--font-family-mono,monospace);font-weight:500}.focal-pulse-ring{transform-origin:50%;animation:2.5s cubic-bezier(.4,0,.6,1) infinite pulse-ring}@keyframes pulse-ring{0%{opacity:.8;transform:scale(.95)}50%{opacity:.2;transform:scale(1.15)}to{opacity:.8;transform:scale(.95)}}.neighborhood-focal-node:hover .focal-body{filter:drop-shadow(0 0 12px #3b82f6e6)}.neighborhood-empty-state{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);height:480px}.topology-physics-panel,.topology-physics-popover{z-index:100;border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);background:#0f172af2;flex-direction:column;gap:14px;width:calc(100% - 40px);min-width:320px;max-width:380px;padding:16px;animation:.2s cubic-bezier(.16,1,.3,1) fadeInPhysics;display:flex;position:absolute;top:70px;right:20px;box-shadow:0 12px 32px #0000008c}@keyframes fadeInPhysics{0%{opacity:0;transform:translateY(-8px)scale(.98)}to{opacity:1;transform:translateY(0)scale(1)}}.topology-physics-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;gap:8px;padding-bottom:10px;display:flex}.topology-physics-title-wrap{align-items:center;gap:8px;display:flex}.topology-physics-title{color:var(--text);margin:0;font-size:.9rem;font-weight:600}.topology-physics-body{flex-direction:column;gap:14px;display:flex}.topology-physics-section{flex-direction:column;gap:8px;display:flex}.topology-physics-section-title{text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);font-size:.75rem;font-weight:600}.topology-physics-presets-grid{grid-template-columns:repeat(2,1fr);gap:6px;display:grid}.topology-physics-preset-btn{border:1px solid var(--border-card);color:var(--text-muted);cursor:pointer;background:#ffffff0a;border-radius:6px;align-items:center;gap:6px;padding:6px 10px;font-size:.78rem;font-weight:500;transition:all .15s;display:flex}.topology-physics-preset-btn:hover{color:var(--text);border-color:var(--primary);background:#ffffff14}.topology-physics-preset-btn.active{color:#60a5fa;background:#3b82f633;border-color:#3b82f680;font-weight:600}.topology-physics-sliders-list{flex-direction:column;gap:10px;display:flex}.topology-physics-slider-row{flex-direction:column;gap:4px;display:flex}.topology-physics-slider-header{justify-content:space-between;align-items:center;font-size:.8rem;display:flex}.topology-physics-slider-label{color:var(--text);cursor:pointer;align-items:center;gap:4px;font-weight:500;display:inline-flex}.topology-physics-symbol{color:var(--text-muted);font-size:.72rem;font-family:var(--font-family-mono,monospace)}.topology-physics-value-chip{font-family:var(--font-family-mono,monospace);color:var(--primary,#38bdf8);background:#ffffff0f;border-radius:4px;padding:2px 6px;font-size:.75rem;font-weight:600}.topology-physics-range-input{appearance:none;cursor:pointer;background:#ffffff1f;border-radius:3px;outline:none;width:100%;height:6px;transition:background .15s}.topology-physics-range-input:hover{background:#ffffff2e}.topology-physics-range-input::-webkit-slider-thumb{appearance:none;background:var(--primary,#3b82f6);cursor:pointer;border-radius:50%;width:14px;height:14px;transition:transform .1s;box-shadow:0 0 6px #3b82f699}.topology-physics-range-input::-webkit-slider-thumb:hover{transform:scale(1.2)}.topology-physics-range-input::-moz-range-thumb{background:var(--primary,#3b82f6);cursor:pointer;border:none;border-radius:50%;width:14px;height:14px}.topology-physics-actions{gap:8px;margin-top:4px;display:flex}.topology-physics-action-btn{flex:1;justify-content:center;align-items:center;gap:6px;font-size:.8rem;display:inline-flex}.code-navigator-container,.code-navigator-container.density-balanced{--nav-item-height:28px;--nav-font-size:.84rem;--nav-item-padding:5px 10px;--nav-icon-size:15px;--nav-badge-font-size:.72rem;--nav-card-padding:12px 14px;--nav-header-padding:10px 14px}.code-navigator-container.density-compact{--nav-item-height:22px;--nav-font-size:.76rem;--nav-item-padding:2px 8px;--nav-icon-size:13px;--nav-badge-font-size:.66rem;--nav-card-padding:8px 10px;--nav-header-padding:6px 10px}.code-navigator-container.density-spacious{--nav-item-height:36px;--nav-font-size:.9rem;--nav-item-padding:8px 14px;--nav-icon-size:17px;--nav-badge-font-size:.78rem;--nav-card-padding:16px 18px;--nav-header-padding:14px 18px}.code-navigator-container{background-color:var(--bg-base,#07181b);height:100%;min-height:calc(100vh - 80px);color:var(--text,#f8fafc);font-family:var(--font-family-base,"Outfit", sans-serif);box-sizing:border-box;flex-direction:column;display:flex;overflow:hidden}.nav-breadcrumbs-bar{border-bottom:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#0d2c2fb3;justify-content:space-between;align-items:center;max-width:100%;min-height:38px;padding:6px 16px;font-size:.8rem;display:flex;overflow:hidden}.nav-breadcrumbs-left{flex:1;align-items:center;gap:10px;min-width:0;max-width:100%;display:flex;overflow:hidden}.nav-sidebar-toggle-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border-radius:4px;flex-shrink:0;justify-content:center;align-items:center;padding:4px 6px;transition:all .2s;display:flex}.nav-sidebar-toggle-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-history-controls{flex-shrink:0;align-items:center;gap:2px;display:flex}.nav-history-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border-radius:4px;justify-content:center;align-items:center;padding:4px 6px;transition:all .2s;display:flex}.nav-history-btn:disabled{opacity:.35;cursor:not-allowed}.nav-history-btn:not(:disabled):hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-breadcrumb-trail{white-space:nowrap;scrollbar-width:none;align-items:center;gap:6px;min-width:0;display:flex;overflow-x:auto}.nav-breadcrumb-trail::-webkit-scrollbar{display:none}.breadcrumb-repo-badge{color:var(--accent,#14b8a6);background:#0891b233;border:1px solid #0891b266;border-radius:4px;flex-shrink:0;align-items:center;gap:4px;padding:2px 7px;font-size:.76rem;font-weight:600;display:inline-flex}.breadcrumb-separator{color:var(--text-muted,#64748b);-webkit-user-select:none;user-select:none}.breadcrumb-segment{color:var(--text-muted,#94a3b8);cursor:pointer;font-size:.8rem;font-family:var(--font-mono,monospace);background:0 0;border:none;border-radius:3px;padding:2px 4px;transition:all .15s}.breadcrumb-segment:hover{color:var(--text,#f8fafc);background:#ffffff14}.breadcrumb-segment.active{color:var(--text,#f8fafc);font-weight:600}.breadcrumb-symbol-badge{color:var(--accent,#14b8a6);font-family:var(--font-mono,monospace);background:#14b8a626;border:1px solid #14b8a64d;border-radius:4px;align-items:center;padding:2px 6px;font-size:.78rem;font-weight:600;display:inline-flex}.nav-breadcrumbs-right{flex-shrink:0;align-items:center;gap:8px;display:flex}.nav-permalink-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:#0000004d;border-radius:5px;align-items:center;gap:6px;padding:4px 10px;font-size:.76rem;transition:all .2s;display:inline-flex}.nav-permalink-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-permalink-btn.copied{color:#6ee7b7;background:#10b9811a;border-color:#10b98180}.nav-hero-layout{flex:1;min-height:0;display:flex;position:relative;overflow:hidden}.nav-sidebar-column{border-right:1px solid var(--border-card,#15474d);background:#0003;flex-direction:column;width:340px;min-width:300px;max-width:480px;transition:width .2s,min-width .2s,opacity .2s;display:flex;overflow:hidden}.nav-sidebar-column.collapsed{opacity:0;pointer-events:none;border-right:none;width:0!important;min-width:0!important}.nav-sidebar-tabs{border-bottom:1px solid var(--border-card,#15474d);background:#0000004d;display:flex}.nav-sidebar-tab-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-bottom:2px solid #0000;flex:1;justify-content:center;align-items:center;gap:6px;padding:8px 12px;font-size:.78rem;font-weight:500;transition:all .2s;display:flex}.nav-sidebar-tab-btn:hover{color:var(--text,#f8fafc);background:#ffffff08}.nav-sidebar-tab-btn.active{color:var(--primary,#0891b2);border-bottom-color:var(--primary,#0891b2);background:#0891b214}.nav-hero-viewer{background:var(--bg-card,#0d2c2f);flex-direction:column;flex:1;min-width:0;display:flex;overflow:hidden}.nav-sliding-impact-drawer{border-left:1px solid var(--border-card,#15474d);z-index:20;background:#0d2c2ff2;flex-direction:column;width:360px;min-width:360px;display:flex;overflow-y:auto;box-shadow:-4px 0 16px #0006}.nav-toolbar{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);box-sizing:border-box;z-index:10;flex-wrap:nowrap;justify-content:space-between;align-items:center;gap:12px;height:44px;min-height:44px;max-height:44px;padding:0 16px;display:flex;overflow:visible}.nav-toolbar-single-row{flex-wrap:nowrap!important}.nav-toolbar-left{flex-shrink:0;align-items:center;gap:12px;display:flex}.nav-repo-selector-wrapper{align-items:center;gap:8px;display:flex}.nav-repo-label{color:var(--text-muted,#94a3b8);font-size:.82rem;font-weight:500}.nav-repo-select{border:1px solid var(--border-card,#15474d);color:var(--text,#f8fafc);cursor:pointer;background:#0006;border-radius:6px;outline:none;padding:5px 12px;font-size:.84rem;transition:border-color .2s,box-shadow .2s}.nav-repo-select:focus{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-stats-badges{align-items:center;gap:8px;display:flex}.nav-stat-badge{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);background:#15474d80;border-radius:12px;padding:3px 8px;font-size:.76rem}.nav-stat-badge .stat-num{color:var(--accent,#14b8a6);font-weight:600}.nav-toolbar-center{flex:1;min-width:200px;max-width:580px}.nav-global-search{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;width:100%;padding:0 10px;transition:all .2s;display:flex;position:relative}.nav-global-search:focus-within{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-global-search .search-icon-wrapper{width:16px;height:16px;color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;justify-content:center;align-items:center;margin-right:8px;display:flex}.nav-search-input{color:var(--text,#f8fafc);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:6px 0;font-size:.82rem}.nav-search-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;padding:2px 4px;font-size:.75rem}.nav-search-clear-btn:hover{color:var(--text,#f8fafc)}.nav-omni-container{width:100%;position:relative}.nav-omni-input-wrapper{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;width:100%;padding:0 10px;transition:all .2s;display:flex;position:relative}.nav-omni-input-wrapper:focus-within{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-omni-search-icon{color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;margin-right:8px}.nav-omni-input{color:var(--text,#f8fafc);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:6px 0;font-size:.82rem}.nav-omni-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;padding:2px 4px;font-size:.75rem}.nav-omni-clear-btn:hover{color:var(--text,#f8fafc)}.nav-omni-spinner{flex-shrink:0;width:14px;height:14px;margin-left:6px;animation:.8s linear infinite nav-spin;display:block}.nav-svg-spinner{animation:.8s linear infinite nav-spin;display:inline-block}@keyframes nav-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.nav-omni-kbd{font-size:.65rem;font-family:var(--font-mono,monospace);color:var(--text-muted,#94a3b8);letter-spacing:.05em;-webkit-user-select:none;user-select:none;background:#ffffff14;border:1px solid #ffffff1f;border-radius:4px;flex-shrink:0;margin-left:6px;padding:2px 6px}.nav-omni-dropdown{z-index:100;background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);border-radius:8px;flex-direction:column;width:max(100%,640px);max-width:min(92vw,760px);max-height:480px;display:flex;position:absolute;top:calc(100% + 6px);left:50%;overflow:hidden;transform:translate(-50%);box-shadow:0 20px 45px #000000bf,0 8px 20px #00000080}@media (width<=768px){.nav-omni-dropdown{width:100%;max-width:100%;left:0;transform:none}}.nav-omni-dropdown-header{border-bottom:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.05em;background:#00000059;justify-content:space-between;align-items:center;padding:8px 14px;font-size:.72rem;font-weight:600;display:flex}.nav-omni-hint{color:var(--text-muted,#64748b);text-transform:none;font-size:.68rem}.nav-omni-empty{text-align:center;color:var(--text-muted,#94a3b8);padding:20px 16px;font-size:.82rem}.nav-omni-list{padding:6px;overflow-y:auto}.nav-omni-item{cursor:pointer;border:1px solid #0000;border-radius:6px;flex-direction:column;gap:5px;margin-bottom:3px;padding:9px 12px;transition:all .15s;display:flex}.nav-omni-item:hover,.nav-omni-item.active{background:#0ea5e91f;border-color:#38bdf859}.nav-omni-item-top{justify-content:space-between;align-items:center;gap:12px;display:flex}.nav-omni-item-title-group{flex:1;align-items:center;gap:8px;min-width:0;display:flex;overflow:hidden}.nav-omni-badge{text-transform:uppercase;letter-spacing:.04em;font-size:.65rem;font-weight:700;font-family:var(--font-mono,monospace);border-radius:4px;flex-shrink:0;padding:2px 6px}.badge-symbol{color:#38bdf8;background:#0ea5e933;border:1px solid #38bdf859}.badge-code{color:#c084fc;background:#a855f733;border:1px solid #c084fc59}.badge-file{color:#2dd4bf;background:#14b8a633;border:1px solid #2dd4bf59}.badge-route{color:#4ade80;background:#22c55e33;border:1px solid #4ade8059}.badge-doc{color:#fbbf24;background:#f59e0b33;border:1px solid #fbbf2459}.badge-default{color:#cbd5e1;background:#94a3b833}.nav-omni-item-container{color:#94a3b8;font-size:.82rem;font-family:var(--font-mono,monospace);white-space:nowrap;flex-shrink:0}.nav-omni-item-name{color:#f8fafc;font-size:.85rem;font-weight:600;font-family:var(--font-mono,monospace);white-space:nowrap;text-overflow:ellipsis;min-width:0;overflow:hidden}.nav-omni-item-kind{color:#94a3b8;text-transform:lowercase;background:#ffffff0f;border:1px solid #ffffff17;border-radius:4px;flex-shrink:0;padding:1px 5px;font-size:.65rem;font-weight:500}.nav-omni-score-pill{color:#34d399;white-space:nowrap;background:#10b9811f;border:1px solid #34d39940;border-radius:6px;flex-shrink:0;padding:2px 7px;font-size:.65rem;font-weight:600}.nav-omni-match{color:#38bdf8;background:#38bdf840;border-radius:2px;padding:0 1px;font-weight:700}.nav-omni-item-bottom{color:#94a3b8;font-size:.73rem;font-family:var(--font-mono,monospace);align-items:center;gap:8px;line-height:1.3;display:flex;overflow:hidden}.nav-omni-item-path{color:#38bdf8;text-overflow:ellipsis;white-space:nowrap;flex-shrink:0;max-width:48%;overflow:hidden}.nav-omni-line-badge{color:#64748b;font-weight:600}.nav-omni-sep{color:#475569;flex-shrink:0;font-size:.65rem}.nav-omni-item-preview{color:#cbd5e1;white-space:nowrap;text-overflow:ellipsis;flex:1;min-width:0;overflow:hidden}.nav-code-viewer-container{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);border-radius:8px;flex-direction:column;max-width:100%;height:100%;display:flex;position:relative;overflow:hidden}.nav-code-viewer-header{border-bottom:1px solid var(--border-card,#15474d);background:#0006;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;max-width:100%;padding:8px 14px;display:flex}.nav-code-viewer-meta{align-items:center;gap:8px;max-width:100%;display:flex;overflow:hidden}.nav-code-file-icon{color:var(--primary,#38bdf8);flex-shrink:0}.nav-code-filename{color:var(--text,#f8fafc);font-size:.84rem;font-weight:700;font-family:var(--font-mono,monospace);white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.nav-code-stat-chip{color:var(--text-muted,#94a3b8);font-size:.72rem;font-family:var(--font-mono,monospace);background:#ffffff14;border-radius:4px;flex-shrink:0;padding:1px 6px}.nav-code-viewer-actions{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.nav-code-action-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#cbd5e1);cursor:pointer;background:#ffffff0f;border-radius:4px;padding:3px 8px;font-size:.74rem;transition:all .15s}.nav-code-action-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#ffffff1f}.nav-code-impact-toggle-btn{color:#c084fc;cursor:pointer;background:#a855f726;border:1px solid #a855f759;border-radius:4px;align-items:center;gap:5px;padding:3px 9px;font-size:.74rem;font-weight:600;transition:all .15s;display:flex}.nav-code-impact-toggle-btn:hover,.nav-code-impact-toggle-btn.active{color:#f3e8ff;background:#a855f747;border-color:#a855f7}.nav-code-body{background:#061113;outline:none;flex:1;max-width:100%;padding:8px 0;position:relative;overflow:hidden auto}.nav-code-lines-wrapper{flex-direction:column;width:100%;max-width:100%;display:flex}.nav-code-line-row{box-sizing:border-box;border-left:3px solid #0000;max-width:100%;min-height:20px;padding:0 4px;line-height:20px;transition:background-color .1s;display:flex}.nav-code-line-row:hover{background:#ffffff08}.nav-code-line-number{text-align:right;width:44px;min-width:44px;font-size:.72rem;font-family:var(--font-mono,monospace);color:#475569;-webkit-user-select:none;user-select:none;flex-shrink:0;padding-right:12px}.nav-code-line-content{font-size:.78rem;font-family:var(--font-mono,monospace);color:#cbd5e1;white-space:pre-wrap;word-break:break-all;overflow-wrap:anywhere;tab-size:4;flex:1;min-width:0}.nav-code-line-target{background:#0ea5e90a!important;border-left:3px solid #38bdf838!important}.nav-code-line-target .nav-code-line-number{color:#64748b}.nav-code-line-primary{background:#0ea5e929!important;border-left:3px solid #38bdf8!important}.nav-code-line-primary .nav-code-line-number{font-weight:700;color:#38bdf8!important}.nav-code-line-primary .nav-code-line-content{font-weight:500}.nav-code-impact-drawer{border-top:1px solid var(--border-card,#15474d);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);background:#091d20f2;flex-direction:column;max-height:260px;animation:.18s ease-out slide-up;display:flex}@keyframes slide-up{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}.nav-impact-drawer-header{border-bottom:1px solid var(--border-card,#15474d);background:#00000059;justify-content:space-between;align-items:center;padding:6px 12px;display:flex}.nav-impact-drawer-title{align-items:center;gap:8px;font-size:.76rem;display:flex}.nav-impact-symbol-name{color:var(--text,#f8fafc);font-family:var(--font-mono,monospace)}.nav-impact-symbol-lines{color:var(--text-muted,#94a3b8);font-size:.7rem}.nav-impact-close-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;padding:2px 6px;font-size:.8rem}.nav-impact-close-btn:hover{color:var(--text,#f8fafc)}.nav-impact-drawer-body{grid-template-columns:1fr 1fr;gap:12px;padding:10px 14px;display:grid;overflow-y:auto}.nav-impact-column-title{text-transform:uppercase;color:var(--text-muted,#94a3b8);margin-bottom:6px;font-size:.72rem;font-weight:600}.nav-impact-empty{color:var(--text-muted,#64748b);font-size:.72rem;font-style:italic}.nav-impact-chips-list{flex-direction:column;gap:4px;display:flex}.nav-impact-chip{border:1px solid var(--border-card,#15474d);cursor:pointer;text-align:left;color:var(--text,#f8fafc);background:#0000004d;border-radius:4px;align-items:center;gap:6px;padding:3px 8px;font-size:.72rem;transition:all .12s;display:flex}.nav-impact-chip:hover{border-color:var(--primary,#0891b2);background:#0891b233}.nav-impact-chip.caller .chip-name{color:#38bdf8;font-weight:600;font-family:var(--font-mono,monospace)}.nav-impact-chip.callee .chip-name{color:#a7f3d0;font-weight:600;font-family:var(--font-mono,monospace)}.nav-impact-chip .chip-path{color:var(--text-muted,#94a3b8);font-size:.68rem;font-family:var(--font-mono,monospace)}.nav-impact-chip .chip-line{color:#facc15;font-size:.68rem}.nav-toolbar-right{flex-shrink:0;align-items:center;gap:12px;display:flex}.nav-density-switcher{border:1px solid var(--border-card,#15474d);background:#0000004d;border-radius:6px;align-items:center;gap:2px;padding:2px;display:flex}.nav-density-switcher .density-label{color:var(--text-muted,#94a3b8);padding:0 6px;font-size:.76rem}.density-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;padding:3px 8px;font-size:.76rem;font-weight:500;transition:all .15s}.density-btn:hover{color:var(--text,#f8fafc);background:#ffffff0d}.density-btn.active{background:var(--primary,#0891b2);color:#fff}.nav-refresh-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:#0000004d;border-radius:6px;justify-content:center;align-items:center;padding:6px;transition:all .2s;display:flex}.nav-refresh-btn:hover:not(:disabled){color:var(--accent,#14b8a6);border-color:var(--accent,#14b8a6)}.nav-refresh-btn.spinning svg{animation:1s linear infinite spin}.nav-error-banner{border-bottom:1px solid var(--danger,#ef4444);color:#fca5a5;background:#ef444426;align-items:center;gap:10px;padding:8px 16px;font-size:.84rem;display:flex}.nav-error-banner span{flex:1}.error-close-btn{color:#fca5a5;cursor:pointer;background:0 0;border:none;font-size:.9rem}.nav-panes-layout{background:var(--bg-base,#07181b);flex:1;display:flex;position:relative;overflow:hidden}.nav-pane-column{border-right:1px solid var(--border-card,#15474d);flex-direction:column;height:100%;display:flex;overflow:hidden}.nav-pane-column:last-child{border-right:none}.nav-pane-tree{background:#07181bf2;flex:0 0 320px;min-width:250px;max-width:420px}.nav-pane-outline{background:#0a2024f2;flex:0 0 360px;min-width:280px;max-width:480px}.nav-pane-inspector{background:var(--bg-base,#07181b);flex:400px;min-width:320px}.nav-tree-header,.nav-outline-header,.nav-inspector-header{padding:var(--nav-header-padding);background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);flex-direction:column;flex-shrink:0;gap:8px;display:flex}.nav-inspector-header{box-sizing:border-box;flex-flow:wrap;justify-content:space-between;align-items:center;gap:8px;min-width:0;max-width:100%}.nav-tree-title-row,.nav-outline-title-row{justify-content:space-between;align-items:center;gap:8px;display:flex}.nav-tree-title,.nav-outline-title,.nav-inspector-title{color:var(--text,#f8fafc);text-transform:uppercase;letter-spacing:.04em;align-items:center;gap:8px;font-size:.86rem;font-weight:600;display:flex}.nav-tree-actions{align-items:center;gap:4px;display:flex}.nav-icon-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:1px solid #0000;border-radius:4px;justify-content:center;align-items:center;padding:4px;display:flex}.nav-icon-btn:hover{color:var(--text,#f8fafc);border-color:var(--border-card,#15474d);background:#ffffff0d}.nav-file-badge{color:var(--accent-light,#2dd4bf);text-overflow:ellipsis;white-space:nowrap;background:#14b8a626;border:1px solid #14b8a64d;border-radius:12px;max-width:180px;padding:2px 8px;font-size:.74rem;overflow:hidden}.nav-tree-search-bar,.nav-outline-search-bar{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#0000004d;border-radius:5px;align-items:center;width:100%;padding:0 8px;display:flex;position:relative}.nav-tree-search-bar:focus-within,.nav-outline-search-bar:focus-within{border-color:var(--primary,#0891b2)}.nav-tree-search-bar .search-icon-wrapper,.nav-outline-search-bar .search-icon-wrapper{width:14px;height:14px;color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;justify-content:center;align-items:center;margin-right:6px;display:flex}.nav-tree-search-input,.nav-outline-search-input{color:var(--text,#f8fafc);font-size:var(--nav-font-size);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:4px 0}.nav-tree-clear-btn,.nav-outline-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;font-size:.72rem}.nav-category-chips{scrollbar-width:none;flex-wrap:wrap;align-items:center;gap:4px;padding-bottom:2px;display:flex;overflow-x:hidden}.nav-category-chips::-webkit-scrollbar{display:none}.category-chip{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;white-space:nowrap;background:#0000004d;border-radius:12px;align-items:center;gap:4px;padding:2px 8px;font-size:.72rem;transition:all .15s;display:flex}.category-chip:hover{color:var(--text,#f8fafc);border-color:#14b8a666}.category-chip.active{border-color:var(--primary,#0891b2);color:var(--accent-light,#2dd4bf);background:#0891b240;font-weight:600}.chip-count{opacity:.8;font-size:.68rem}.nav-tree-content,.nav-outline-content,.nav-inspector-content{flex:1;padding:6px 0;overflow:hidden auto}.nav-inspector-content{padding:14px}.nav-tree-pane{outline:none;flex-direction:column;height:100%;display:flex}.nav-tree-list{flex-direction:column;display:flex}.nav-tree-item{min-height:var(--nav-item-height);padding:var(--nav-item-padding);font-size:var(--nav-font-size);color:var(--text,#f8fafc);cursor:pointer;-webkit-user-select:none;user-select:none;border-left:2px solid #0000;align-items:center;gap:6px;transition:background-color .1s,border-color .1s;display:flex}.nav-tree-item:hover{background:#ffffff0a}.nav-tree-item.selected{border-left-color:var(--accent,#14b8a6);color:#fff;background:#0891b233;font-weight:500}.nav-tree-item.focused{outline:1px dotted var(--accent,#14b8a6);outline-offset:-1px}.tree-chevron{width:14px;color:var(--text-muted,#94a3b8);justify-content:center;align-items:center;font-size:.64rem;display:inline-flex}.chevron-arrow{transition:transform .15s;display:inline-block}.chevron-arrow.open{transform:rotate(90deg)}.chevron-spacer{width:14px}.tree-icon{font-size:var(--nav-icon-size);justify-content:center;align-items:center;width:16px;display:inline-flex}.tree-label{text-overflow:ellipsis;white-space:nowrap;flex:1;overflow:hidden}.tree-badges{align-items:center;gap:4px;margin-left:auto;padding-right:6px;display:flex}.badge-symbols{font-size:var(--nav-badge-font-size);color:#67e8f9;font-family:var(--font-family-mono,monospace);background:#0891b226;border:1px solid #0891b24d;border-radius:8px;padding:1px 5px}.badge-routes{font-size:var(--nav-badge-font-size);color:#5eead4;font-family:var(--font-family-mono,monospace);background:#14b8a62e;border:1px solid #14b8a659;border-radius:8px;padding:1px 5px;font-weight:600}.nav-outline-pane{flex-direction:column;height:100%;display:flex}.nav-symbol-list{flex-direction:column;gap:4px;padding:6px 8px;display:flex}.nav-symbol-item{border:1px solid var(--border-card,#15474d);padding:var(--nav-card-padding);cursor:pointer;background:#0d2c2f66;border-radius:6px;flex-direction:column;gap:6px;transition:all .15s;display:flex}.nav-symbol-item:hover{background:#15474d66;border-color:#14b8a666}.nav-symbol-item.active{border-color:var(--accent,#14b8a6);background:#0891b238;box-shadow:0 0 10px #14b8a626}.symbol-header-row{justify-content:space-between;align-items:center;gap:8px;display:flex}.symbol-name-col{align-items:center;gap:6px;display:flex;overflow:hidden}.symbol-name-text{font-weight:600;font-size:var(--nav-font-size);color:var(--text,#f8fafc);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.symbol-meta-col{flex-shrink:0}.symbol-line-badge{font-size:var(--nav-badge-font-size);color:var(--text-muted,#94a3b8);font-family:var(--font-family-mono,monospace);background:#00000040;border-radius:4px;padding:1px 6px}.symbol-kind-badge{text-transform:uppercase;letter-spacing:.03em;border-radius:4px;flex-shrink:0;padding:1px 5px;font-size:.65rem;font-weight:700}.kind-class{color:#c084fc;background:#a855f733;border:1px solid #a855f766}.kind-function{color:#60a5fa;background:#3b82f633;border:1px solid #3b82f666}.kind-variable{color:#fbbf24;background:#f59e0b33;border:1px solid #f59e0b66}.kind-type{color:#2dd4bf;background:#14b8a633;border:1px solid #14b8a666}.kind-default{color:#cbd5e1;background:#94a3b833;border:1px solid #94a3b84d}.symbol-route-row{background:#0000004d;border-radius:4px;align-items:center;gap:6px;padding:3px 6px;font-size:.74rem;display:flex;overflow:hidden}.route-method-badge{text-transform:uppercase;border-radius:3px;flex-shrink:0;padding:1px 5px;font-size:.64rem;font-weight:700}.method-get{color:#a7f3d0;background:#065f46}.method-post{color:#bfdbfe;background:#1e40af}.method-put{color:#fde68a;background:#92400e}.method-delete{color:#fecaca;background:#991b1b}.method-patch{color:#ddd6fe;background:#5b21b6}.method-other{color:#e5e7eb;background:#374151}.route-path-text{font-family:var(--font-family-mono,monospace);color:#67e8f9;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.route-framework-tag{color:var(--text-muted,#94a3b8);margin-left:auto;padding-left:4px;font-size:.62rem}.symbol-signature-snippet{background:var(--code-bg,#00000059);font-family:var(--font-family-mono,monospace);color:#cbd5e1;text-overflow:ellipsis;white-space:nowrap;border-radius:4px;padding:4px 6px;font-size:.72rem;overflow-x:hidden}.nav-inspector-pane{box-sizing:border-box;flex-direction:column;min-width:0;max-width:100%;height:100%;display:flex;overflow-x:hidden}.nav-copy-permalink-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;gap:6px;max-width:100%;padding:4px 10px;font-size:.76rem;transition:all .15s;display:flex}.nav-copy-permalink-btn:hover{color:var(--accent,#14b8a6);border-color:var(--accent,#14b8a6)}.nav-inspector-body{box-sizing:border-box;flex-direction:column;gap:12px;min-width:0;max-width:100%;display:flex}.inspector-card{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);padding:var(--nav-card-padding);box-sizing:border-box;border-radius:8px;min-width:0;max-width:100%;overflow-x:hidden}.card-section-title{color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.04em;align-items:center;gap:6px;margin-bottom:8px;font-size:.8rem;font-weight:600;display:flex}.symbol-summary-card{flex-direction:column;gap:6px;display:flex}.summary-title-row{flex-wrap:wrap;align-items:center;gap:8px;min-width:0;max-width:100%;display:flex}.summary-name{color:#fff;overflow-wrap:anywhere;word-break:break-word;min-width:0;font-size:1.15rem;font-weight:700}.summary-location-row{color:var(--text-muted,#94a3b8);align-items:center;gap:12px;font-size:.8rem;display:flex}.summary-file-path{color:var(--accent-light,#2dd4bf);font-family:var(--font-family-mono,monospace);align-items:center;gap:4px;display:flex}.summary-line-range{font-family:var(--font-family-mono,monospace);background:#0000004d;border-radius:4px;padding:1px 6px}.inspector-metrics-grid{grid-template-columns:repeat(4,1fr);gap:10px;display:grid}.metric-box{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);text-align:center;border-radius:8px;flex-direction:column;align-items:center;padding:10px;display:flex}.metric-label{color:var(--text-muted,#94a3b8);margin-bottom:4px;font-size:.72rem}.metric-value{color:var(--accent,#14b8a6);font-size:1.25rem;font-weight:700}.metric-lang{text-transform:uppercase;font-size:.95rem}.route-detail-row{align-items:center;gap:8px;display:flex}.route-path-code{font-family:var(--font-family-mono,monospace);color:#67e8f9;font-size:.88rem;font-weight:600}.signature-code-block{background:var(--code-bg,#00000059);font-family:var(--font-family-mono,monospace);color:#f1f5f9;white-space:pre-wrap;word-break:break-all;border:1px solid #ffffff0d;border-radius:6px;padding:10px;font-size:.82rem;overflow-x:auto}.docstring-text{color:#cbd5e1;white-space:pre-wrap;font-size:.84rem;line-height:1.5}.relation-list{flex-direction:column;gap:6px;display:flex}.relation-item{border:1px solid var(--border-card,#15474d);background:#00000040;border-radius:6px;flex-direction:column;gap:4px;padding:8px 10px;transition:all .15s;display:flex}.relation-item.caller-item,.relation-item.callee-item.is-clickable{cursor:pointer}.relation-item.caller-item:hover,.relation-item.callee-item.is-clickable:hover{border-color:var(--accent,#14b8a6);background:#0891b22e;transform:translate(2px)}.relation-top{justify-content:space-between;align-items:center;display:flex}.rel-top-right{align-items:center;gap:6px;display:flex}.rel-symbol-name{color:var(--text,#f8fafc);font-size:.82rem;font-weight:600}.rel-jump-hint{color:var(--accent-light,#2dd4bf);font-size:.72rem;font-weight:500}.relation-bottom{color:var(--text-muted,#94a3b8);align-items:center;gap:8px;font-size:.74rem;display:flex}.rel-filepath{font-family:var(--font-family-mono,monospace);color:#93c5fd}.rel-line{font-family:var(--font-family-mono,monospace)}.rel-type-tag,.rel-type-badge{text-transform:uppercase;background:#ffffff14;border-radius:4px;padding:1px 5px;font-size:.64rem}.import-badge{color:#c084fc;background:#a855f726}.rel-count-badge{color:var(--accent-light,#2dd4bf);font-size:.65rem;font-weight:500;font-family:var(--font-family-mono,monospace);background:#14b8a626;border-radius:4px;padding:1px 5px}.nav-no-items-text{color:var(--text-muted,#94a3b8);font-size:.8rem;font-style:italic}.nav-empty-state{text-align:center;color:var(--text-muted,#94a3b8);flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:32px 16px;display:flex}.nav-empty-state .empty-icon{opacity:.5;margin-bottom:4px;font-size:2rem}.nav-empty-state h4{color:var(--text,#f8fafc);font-size:.95rem}.nav-empty-state p{max-width:280px;font-size:.8rem}.nav-clear-filter-btn{background:var(--primary,#0891b2);color:#fff;cursor:pointer;border:none;border-radius:4px;margin-top:6px;padding:4px 10px;font-size:.76rem}.nav-loading-wrapper{color:var(--text-muted,#94a3b8);flex-direction:column;justify-content:center;align-items:center;gap:12px;padding:40px 16px;font-size:.84rem;display:flex}.nav-spinner{border:2px solid var(--border-card,#15474d);border-top-color:var(--accent,#14b8a6);border-radius:50%;width:24px;height:24px;animation:.8s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.nav-outline-skeleton,.nav-inspector-skeleton{flex-direction:column;gap:10px;padding:12px;display:flex}.skeleton-item,.skeleton-header,.skeleton-metrics,.skeleton-block{background:#ffffff0d;border-radius:6px}.skeleton-item{height:48px}.skeleton-header{height:70px}.skeleton-metrics{height:60px}.skeleton-block{height:90px}.shimmer{position:relative;overflow:hidden}.shimmer:after{content:"";background:linear-gradient(90deg,#0000 0%,#ffffff0a 50%,#0000 100%);width:100%;height:100%;animation:1.5s infinite shimmer;position:absolute;top:0;left:0;transform:translate(-100%)}@keyframes shimmer{to{transform:translate(100%)}}.nav-inspector-header-actions{flex-wrap:wrap;align-items:center;gap:8px;min-width:0;max-width:100%;display:flex}.nav-inspector-tabs{border:1px solid var(--border-card,#15474d);background:#0006;border-radius:6px;gap:2px;padding:2px;display:flex}.inspector-tab-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;align-items:center;gap:5px;padding:4px 10px;font-size:.74rem;font-weight:500;transition:all .15s;display:inline-flex}.inspector-tab-btn:hover:not(:disabled){color:var(--text,#f8fafc)}.inspector-tab-btn.active{background:var(--primary,#0891b2);color:#fff}.inspector-tab-btn.dimmed,.inspector-tab-btn:disabled{opacity:.4;cursor:default}.nav-doc-reader{background:var(--bg-base,#07181b);flex-direction:column;height:100%;display:flex;overflow:hidden}.doc-reader-header{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;display:flex}.doc-reader-meta{flex:1;align-items:center;gap:10px;min-width:0;display:flex}.doc-icon{flex-shrink:0;font-size:1.3rem}.doc-title-wrapper{flex-direction:column;gap:2px;min-width:0;display:flex}.doc-filename{color:var(--text,#f8fafc);white-space:nowrap;text-overflow:ellipsis;margin:0;font-size:.92rem;font-weight:600;overflow:hidden}.doc-meta-badges{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.doc-badge{color:var(--text-muted,#94a3b8);background:#ffffff0f;border:1px solid #ffffff14;border-radius:4px;padding:1px 6px;font-size:.7rem}.badge-path{color:var(--accent,#14b8a6);white-space:nowrap;text-overflow:ellipsis;max-width:250px;overflow:hidden}.doc-reader-actions{flex-shrink:0;align-items:center;gap:8px;display:flex}.doc-view-toggle{border:1px solid var(--border-card,#15474d);background:#0006;border-radius:5px;padding:2px;display:flex}.doc-view-toggle .toggle-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;padding:3px 8px;font-size:.72rem;transition:all .15s}.doc-view-toggle .toggle-btn.active{background:var(--primary,#0891b2);color:#fff}.doc-copy-btn{border:1px solid var(--border-card,#15474d);color:var(--text,#f8fafc);cursor:pointer;background:#ffffff0f;border-radius:5px;padding:4px 10px;font-size:.74rem;transition:all .2s}.doc-copy-btn:hover{background:var(--primary,#0891b2);color:#fff;border-color:var(--primary,#0891b2)}.doc-reader-body{background:var(--bg-base,#07181b);color:var(--text,#f8fafc);flex:1;padding:16px 20px;font-size:.88rem;line-height:1.6;overflow-y:auto}.doc-rendered-content{max-width:960px;margin:0 auto;line-height:1.65}.doc-rendered-content h1{color:var(--text,#f8fafc);border-bottom:1px solid var(--border-card,#15474d);margin:20px 0 14px;padding-bottom:8px;font-size:1.55rem;font-weight:700}.doc-rendered-content h2{color:var(--text,#f8fafc);border-bottom:1px solid #ffffff14;margin:18px 0 12px;padding-bottom:6px;font-size:1.3rem;font-weight:600}.doc-rendered-content h3{color:var(--accent-light,#2dd4bf);margin:14px 0 8px;font-size:1.1rem;font-weight:600}.doc-rendered-content h4{color:var(--text,#f8fafc);margin:12px 0 6px;font-size:.98rem;font-weight:600}.doc-rendered-content p{color:#cbd5e1;margin:0 0 12px}.doc-rendered-content table{border-collapse:collapse;border:1px solid var(--border-card,#15474d);background:#00000040;border-radius:6px;width:100%;margin:18px 0;font-size:.85rem;overflow:hidden}.doc-rendered-content thead{background:#0891b22e}.doc-rendered-content th{color:#f8fafc;border-bottom:2px solid var(--border-card,#15474d);text-align:left;border-right:1px solid #ffffff0f;padding:10px 14px;font-weight:600}.doc-rendered-content td{color:#cbd5e1;border-bottom:1px solid #ffffff0d;border-right:1px solid #ffffff0f;padding:9px 14px}.doc-rendered-content th:last-child,.doc-rendered-content td:last-child{border-right:none}.doc-rendered-content tr:last-child td{border-bottom:none}.doc-rendered-content tbody tr:hover{background:#ffffff08}.mermaid-container{border:1px solid var(--border-card,#15474d);background:#00000059;border-radius:8px;justify-content:center;align-items:center;margin:18px 0;padding:24px 16px;display:flex;overflow-x:auto}.mermaid-container .mermaid{justify-content:center;width:100%;display:flex}.mermaid-container svg{max-width:100%!important;height:auto!important}.doc-rendered-content code{font-family:var(--font-family-mono,monospace);color:var(--accent-light,#2dd4bf);background:#00000073;border:1px solid #ffffff1a;border-radius:4px;padding:2px 6px;font-size:.82rem}.doc-rendered-content pre{border:1px solid var(--border-card,#15474d);font-family:var(--font-family-mono,monospace);color:#e2e8f0;background:#0000008c;border-radius:6px;margin:14px 0;padding:12px 14px;font-size:.82rem;line-height:1.5;overflow-x:auto}.doc-rendered-content pre code{color:inherit;background:0 0;border:none;padding:0}.doc-rendered-content blockquote{border-left:3px solid var(--primary,#0891b2);color:var(--text-muted,#94a3b8);background:#0891b214;border-radius:0 6px 6px 0;margin:12px 0;padding:6px 14px;font-style:italic}.doc-rendered-content ul,.doc-rendered-content ol{color:#cbd5e1;margin:8px 0 14px 24px;padding:0}.doc-rendered-content li{margin-bottom:4px}.doc-rendered-content a{color:var(--accent-light,#2dd4bf);text-underline-offset:2px;text-decoration:underline}.doc-rendered-content a:hover{color:#5eead4}.doc-rendered-content hr{border:none;border-top:1px solid var(--border-card,#15474d);margin:20px 0}.doc-raw-container{font-family:var(--font-family-mono,monospace);font-size:.82rem;overflow-x:auto}.doc-raw-pre{margin:0}.doc-lines-table{border-collapse:collapse;width:100%}.doc-line-row:hover{background:#ffffff08}.doc-line-num{text-align:right;color:#94a3b880;-webkit-user-select:none;user-select:none;vertical-align:top;border-right:1px solid #ffffff0f;width:45px;padding:2px 10px 2px 4px}.doc-line-code{white-space:pre-wrap;word-break:break-all;color:#e2e8f0;padding:2px 12px}.doc-reader-loading{flex-direction:column;gap:12px;padding:20px;display:flex}.doc-reader-error{color:var(--danger,#ef4444);flex-direction:column;align-items:flex-start;gap:10px;padding:20px;display:flex}.nav-mobile-pane-switcher{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);z-index:5;gap:6px;padding:6px 12px;display:none}.mobile-pane-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;text-align:center;background:#0000004d;border-radius:5px;flex:1;padding:6px 8px;font-size:.78rem;font-weight:500;transition:all .15s}.mobile-pane-btn.active{background:var(--primary,#0891b2);color:#fff;border-color:var(--primary,#0891b2)}@media (width<=899px){.nav-mobile-pane-switcher{display:none}.nav-panes-layout,.nav-hero-layout{flex-direction:column;flex:1;gap:16px;height:auto;overflow:hidden auto}.nav-pane-column,.nav-sidebar-column{border-right:none;border-bottom:1px solid var(--border,#334155);height:auto;min-height:320px;flex:none!important;width:100%!important;min-width:0!important;max-width:100%!important;display:flex!important}.nav-hero-viewer{height:auto;min-height:360px;flex:none!important;width:100%!important;min-width:0!important;max-width:100%!important;display:flex!important}.nav-toolbar{flex-direction:column;align-items:stretch;gap:10px;height:auto;min-height:auto;max-height:none;padding:10px 12px}.nav-toolbar-left{justify-content:space-between;width:100%}.nav-toolbar-center{width:100%;max-width:100%}.nav-toolbar-right{justify-content:space-between;width:100%}.nav-breadcrumbs-bar{height:auto;min-height:auto;padding:8px 12px}.nav-breadcrumbs-left{flex-wrap:wrap;width:100%}.nav-breadcrumb-trail{white-space:normal;flex-wrap:wrap;max-width:100%}}@media (width>=900px){.nav-mobile-pane-switcher{display:none}.nav-pane-column{display:flex!important}} diff --git a/frontend/dist/assets/index-DoQkmpth.js b/frontend/dist/assets/index-DoQkmpth.js new file mode 100644 index 0000000..2eb59ca --- /dev/null +++ b/frontend/dist/assets/index-DoQkmpth.js @@ -0,0 +1,135 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/elk-276RUBZZ-On_DNuCd.js","assets/src-D_iIdUkB.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js","assets/chunk-O7XYJQB3-Bce2lzyF.js","assets/chunk-ZIGJFQKS-BJ6myxnF.js","assets/dist-Bfr8PhAA.js","assets/chunk-7PRAP22T-DSs4vaIy.js","assets/chunk-742MDFTN-5mFByRwZ.js","assets/chunk-MBY4JIJT-CGQ6Fu8G.js","assets/chunk-7INBJB4K-BkZ96Hf7.js","assets/chunk-J5ZVWO5B-oDCd-gWO.js","assets/rough.esm-Dy-Kn_BL.js","assets/chunk-5DYCD2WN-WToj2Jza.js","assets/chunk-3FUC2YCW-CmoZ3fbX.js","assets/graphlib-C9Tl7QrK.js","assets/_baseUniq-DR4vVjyC.js","assets/chunk-NETBCI7D-Br7cqgBT.js","assets/dagre-6A5THRUB-Bmed3uZj.js","assets/_basePickBy-Cj4iqGU4.js","assets/swimlanes-2SLR337P-BKvviDHP.js","assets/cose-bilkent-JH36ORCC-BtJFQFL9.js","assets/cytoscape.esm-CECbKnxF.js","assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js","assets/chunk-GWA4HPMP-C1P4FmAY.js","assets/flowDiagram-KWPJA3E3-BO7njBlM.js","assets/chunk-XXDRQBXY-C1_eEj17.js","assets/chunk-WEXAMYUT-I3m-hOmT.js","assets/chunk-7M6MHVWA-ZnPgs1Wx.js","assets/channel-_oCHZhRo.js","assets/chunk-5VM5RSS4-ZNzvKenW.js","assets/diagram-22UHCM2B-B4G_FQZz.js","assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js","assets/erDiagram-OPXOYQCR-YD8i2JM4.js","assets/gitGraphDiagram-X574FWY7-BEOc0w88.js","assets/mermaid-parser.core-CUrDj5TF.js","assets/chunk-FOHPRMQF-DHwB1DNv.js","assets/chunk-JWPE2WC7-DVXcaiue.js","assets/chunk-2Q5K7J3B-C1jixKkw.js","assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js","assets/linear-CZ6dxGrP.js","assets/defaultLocale-BFoDCU3G.js","assets/init-C-OQMol4.js","assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js","assets/pieDiagram-5QR66LMP-0Fjx8Dye.js","assets/ordinal-BDEzSJ7C.js","assets/path-fybaL0A-.js","assets/arc-BJA87daU.js","assets/array-BifhSqXX.js","assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js","assets/xychartDiagram-PMCCYNJV-BE8PLguK.js","assets/line-gOgo9JIs.js","assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js","assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js","assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js","assets/stateDiagram-v2-GCMORJYK-CepxBhD6.js","assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js","assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js","assets/mindmap-definition-NLK3R4M7-BCTxemjG.js","assets/kanban-definition-PNTS6WVX-BAMaaT6d.js","assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js","assets/diagram-MLGK6HIB-DILal1CA.js","assets/diagram-MPIPVDR6-8w_EEv4v.js","assets/blockDiagram-BEXU5L5S-LcLXSRjx.js","assets/diagram-CDSNMT55-DcWw9GHj.js","assets/architectureDiagram-NJMV4G6O-CQM7JOeV.js","assets/diagram-ATOU4E4O-BNgT_lbL.js","assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js","assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js","assets/diagram-3UASUU5V-Dv_f5rjj.js","assets/usecaseDiagram-POWQR4AR-1e9d35eQ.js","assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js","assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js","assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js","assets/chunk-GTNCS2PH-CoZ--rjp.js","assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js","assets/abnfDiagram-O67JEVCF-CQJZpKdi.js","assets/pegDiagram-GJSIUBJH-B0Gktij4.js"])))=>i.map(i=>d[i]); +import{_ as e,h as t,m as n,p as r,y as i}from"./src-D_iIdUkB.js";import{n as a}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{$ as o,C as s,E as c,I as l,J as u,K as d,L as f,N as p,P as m,Q as h,S as g,T as _,V as v,W as y,Z as b,_ as x,b as S,c as C,et as w,f as T,g as E,l as D,m as O,n as k,p as A,r as j,s as M,t as N,tt as P,u as F,x as I}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{$ as L,J as R,K as z,Q as B,S as ee,X as te,Y as ne,Z as re,a as ie,d as ae,et as oe,f as se,g as ce,h as le,i as ue,nt as de,o as fe,q as pe,rt as me,tt as he,u as ge,v as _e,x as ve,y as ye}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as be}from"./line-gOgo9JIs.js";import{a as xe,i as Se,n as Ce,t as we}from"./chunk-7PRAP22T-DSs4vaIy.js";import{r as Te}from"./chunk-742MDFTN-5mFByRwZ.js";import{a as Ee,n as De,r as Oe}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{s as ke}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{t as Ae}from"./rough.esm-Dy-Kn_BL.js";import{i as je,n as Me,o as Ne,t as Pe}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{n as Fe,r as Ie}from"./chunk-5DYCD2WN-WToj2Jza.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var Le=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function M(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function N(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,N(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),N(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u{t.exports=Le()})),ze=e((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0>>1,a=e[r];if(0>>1;ri(c,n))li(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(li(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-Tt&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Be=e(((e,t)=>{t.exports=ze()})),Ve=e((e=>{var t=Re();function n(e){var t=`https://react.dev/errors/`+e;if(1{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Ve()})),Ue=e((e=>{var t=Be(),n=Re(),r=He();function i(e){var t=`https://react.dev/errors/`+e;if(1L||(e.current=I[L],I[L]=null,L--)}function B(e,t){L++,I[L]=e.current,e.current=t}var ee=R(null),te=R(null),ne=R(null),re=R(null);function ie(e,t){switch(B(ne,t),B(te,e),B(ee,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}z(ee),B(ee,e)}function ae(){z(ee),z(te),z(ne)}function oe(e){e.memoizedState!==null&&B(re,e);var t=ee.current,n=Hd(t,e.type);t!==n&&(B(te,e),B(ee,n))}function se(e){te.current===e&&(z(ee),z(te)),re.current===e&&(z(re),Qf._currentValue=F)}var ce,le;function ue(e){if(ce===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ce=t&&t[1]||``,le=-1)`:-1i||c[r]!==l[i]){var u=` +`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(``)&&(u=u.replace(``,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{de=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ue(n):``}function pe(e,t){switch(e.tag){case 26:case 27:case 5:return ue(e.type);case 16:return ue(`Lazy`);case 13:return e.child!==t&&t!==null?ue(`Suspense Fallback`):ue(`Suspense`);case 19:return ue(`SuspenseList`);case 0:case 15:return fe(e.type,!1);case 11:return fe(e.type.render,!1);case 1:return fe(e.type,!0);case 31:return ue(`Activity`);default:return``}}function me(e){try{var t=``,n=null;do t+=pe(e,n),n=e,e=e.return;while(e);return t}catch(e){return` +Error generating stack: `+e.message+` +`+e.stack}}var he=Object.prototype.hasOwnProperty,ge=t.unstable_scheduleCallback,_e=t.unstable_cancelCallback,ve=t.unstable_shouldYield,ye=t.unstable_requestPaint,be=t.unstable_now,xe=t.unstable_getCurrentPriorityLevel,Se=t.unstable_ImmediatePriority,Ce=t.unstable_UserBlockingPriority,we=t.unstable_NormalPriority,Te=t.unstable_LowPriority,Ee=t.unstable_IdlePriority,De=t.log,Oe=t.unstable_setDisableYieldValue,ke=null,Ae=null;function je(e){if(typeof De==`function`&&Oe(e),Ae&&typeof Ae.setStrictMode==`function`)try{Ae.setStrictMode(ke,e)}catch{}}var Me=Math.clz32?Math.clz32:Fe,Ne=Math.log,Pe=Math.LN2;function Fe(e){return e>>>=0,e===0?32:31-(Ne(e)/Pe|0)|0}var Ie=256,Le=262144,ze=4194304;function Ve(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ue(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Ve(n))):i=Ve(o):i=Ve(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ve(n))):i=Ve(o)):i=Ve(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function V(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ge(){var e=ze;return ze<<=1,!(ze&62914560)&&(ze=4194304),e}function Ke(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function H(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function qe(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0`u`||window.document===void 0||window.document.createElement===void 0),rn=!1;if(nn)try{var an={};Object.defineProperty(an,"passive",{get:function(){rn=!0}}),window.addEventListener(`test`,an,an),window.removeEventListener(`test`,an,an)}catch{rn=!1}var on=null,sn=null,cn=null;function ln(){if(cn)return cn;var e,t=sn,n=t.length,r,i=`value`in on?on.value:on.textContent,a=i.length;for(e=0;e=Vn),Wn=` `,Gn=!1;function Kn(e,t){switch(e){case`keyup`:return zn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function qn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Jn=!1;function Yn(e,t){switch(e){case`compositionend`:return qn(t);case`keypress`:return t.which===32?(Gn=!0,Wn):null;case`textInput`:return e=t.data,e===Wn&&Gn?null:e;default:return null}}function Xn(e,t){if(Jn)return e===`compositionend`||!Bn&&Kn(e,t)?(e=ln(),cn=sn=on=null,Jn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=vr(n)}}function br(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?br(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function xr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=jt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=jt(e.document)}return t}function Sr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Cr=nn&&`documentMode`in document&&11>=document.documentMode,wr=null,Tr=null,Er=null,Dr=!1;function Or(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Dr||wr==null||wr!==jt(r)||(r=wr,`selectionStart`in r&&Sr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Er&&_r(Er,r)||(Er=r,r=Td(Tr,`onSelect`),0>=o,i-=o,bi=1<<32-Me(t)+i|n<m?(h=d,d=null):h=d.sibling;var g=p(i,d,s[m],c);if(g===null){d===null&&(d=h);break}e&&d&&g.alternate===null&&t(i,d),a=o(g,a,m),u===null?l=g:u.sibling=g,u=g,d=h}if(m===s.length)return n(i,d),G&&Si(i,m),l;if(d===null){for(;mh?(g=m,m=null):g=m.sibling;var y=p(a,m,v.value,l);if(y===null){m===null&&(m=g);break}e&&m&&y.alternate===null&&t(a,m),s=o(y,s,h),d===null?u=y:d.sibling=y,d=y,m=g}if(v.done)return n(a,m),G&&Si(a,h),u;if(m===null){for(;!v.done;h++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return G&&Si(a,h),u}for(m=r(m);!v.done;h++,v=c.next())v=_(m,a,h,v.value,l),v!==null&&(e&&v.alternate!==null&&m.delete(v.key===null?h:v.key),s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return e&&m.forEach(function(e){return t(a,e)}),G&&Si(a,h),u}function x(e,r,o,c){if(typeof o==`object`&&o&&o.type===g&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case m:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===g){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===T&&Sa(l)===r.type){n(e,r.sibling),c=a(r,o.props),ka(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===g?(c=si(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=oi(o.type,o.key,o.props,null,e.mode,c),ka(c,o),c.return=e,e=c)}return s(e);case h:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=ui(o,e.mode,c),c.return=e,e=c}return s(e);case T:return o=Sa(o),x(e,r,o,c)}if(M(o))return v(e,r,o,c);if(k(o)){if(l=k(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return x(e,r,Oa(o),c);if(o.$$typeof===b)return x(e,r,Xi(e,o),c);Aa(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=ci(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Da=0;var i=x(e,t,n,r);return Ea=null,i}catch(t){if(t===ga||t===va)throw t;var a=ni(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ma=ja(!0),Na=ja(!1),K=!1;function Pa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Fa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ia(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function La(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=$r(e),Qr(e,null,n),t}return Yr(e,r,t,n),$r(e)}function Ra(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ye(e,n)}}function za(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ba=!1;function Va(){if(Ba){var e=sa;if(e!==null)throw e}}function Ha(e,t,n,r){Ba=!1;var i=e.updateQueue;K=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var p=s.lane&-536870913,m=p!==s.lane;if(m?(X&p)===p:(r&p)===p){p!==0&&p===oa&&(Ba=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;p=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,p);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,p=typeof h==`function`?h.call(_,d,p):h,p==null)break a;d=f({},d,p);break a;case 2:K=!0}}p=s.callback,p!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[p]:m.push(p))}else m={lane:p,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=p;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Wl|=o,e.lanes=o,e.memoizedState=d}}function Ua(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function Wa(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;ea?a:8;var o=N.T,s={};N.T=s,As(e,!1,t,n);try{var c=i(),l=N.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?ks(e,t,ua(c,r),du(e)):ks(e,t,r,du(e))}catch(n){ks(e,t,{then:function(){},status:`rejected`,reason:n},du())}finally{P.p=a,o!==null&&s.types!==null&&(o.types=s.types),N.T=o}}function ys(){}function bs(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=xs(e).queue;vs(e,a,t,F,n===null?ys:function(){return Ss(e),n(r)})}function xs(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:F,baseState:F,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jo,lastRenderedState:F},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ss(e){var t=xs(e);t.next===null&&(t=e.alternate.memoizedState),ks(e,t.next.queue,{},du())}function Cs(){return Yi(Qf)}function ws(){return Eo().memoizedState}function Ts(){return Eo().memoizedState}function Es(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=du();e=Ia(n);var r=La(t,e,n);r!==null&&(pu(r,t,n),Ra(r,t,n)),t={cache:na()},e.payload=t;return}t=t.return}}function Ds(e,t,n){var r=du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},js(e)?Ms(t,n):(n=Xr(e,t,n,r),n!==null&&(pu(n,e,r),Ns(n,t,r)))}function Os(e,t,n){ks(e,t,n,du())}function ks(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(js(e))Ms(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,gr(s,o))return Yr(e,t,i,0),Ll===null&&Jr(),!1}catch{}if(n=Xr(e,t,i,r),n!==null)return pu(n,e,r),Ns(n,t,r),!0}return!1}function As(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},js(e)){if(t)throw Error(i(479))}else t=Xr(e,n,r,2),t!==null&&pu(t,e,2)}function js(e){var t=e.alternate;return e===q||t!==null&&t===q}function Ms(e,t){lo=co=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ns(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ye(e,n)}}var Ps={readContext:Yi,use:ko,useCallback:go,useContext:go,useEffect:go,useImperativeHandle:go,useLayoutEffect:go,useInsertionEffect:go,useMemo:go,useReducer:go,useRef:go,useState:go,useDebugValue:go,useDeferredValue:go,useTransition:go,useSyncExternalStore:go,useId:go,useHostTransitionStatus:go,useFormState:go,useActionState:go,useOptimistic:go,useMemoCache:go,useCacheRefresh:go};Ps.useEffectEvent=go;var Fs={readContext:Yi,use:ko,useCallback:function(e,t){return To().memoizedState=[e,t===void 0?null:t],e},useContext:Yi,useEffect:as,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),rs(4194308,4,ds.bind(null,t,e),n)},useLayoutEffect:function(e,t){return rs(4194308,4,e,t)},useInsertionEffect:function(e,t){rs(4,2,e,t)},useMemo:function(e,t){var n=To();t=t===void 0?null:t;var r=e();if(uo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=To();if(n!==void 0){var i=n(t);if(uo){je(!0);try{n(t)}finally{je(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ds.bind(null,q,e),[r.memoizedState,e]},useRef:function(e){var t=To();return e={current:e},t.memoizedState=e},useState:function(e){e=Vo(e);var t=e.queue,n=Os.bind(null,q,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ps,useDeferredValue:function(e,t){return gs(To(),e,t)},useTransition:function(){var e=Vo(!1);return e=vs.bind(null,q,e.queue,!0,!1),To().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=q,a=To();if(G){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Ll===null)throw Error(i(349));X&127||Io(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,as(Ro.bind(null,r,o,e),[e]),r.flags|=2048,ts(9,{destroy:void 0},Lo.bind(null,r,o,n,t),null),n},useId:function(){var e=To(),t=Ll.identifierPrefix;if(G){var n=xi,r=bi;n=(r&~(1<<32-Me(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=fo++,0<\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[tt]=t,o[nt]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&kc(t)}}return Pc(t),Ac(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&kc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=ne.current,Fi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Di,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[tt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Mi(t,!0)}else e=Bd(e).createTextNode(r),e[tt]=t,t.stateNode=e}return Pc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Fi(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[tt]=t}else Ii(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Pc(t),e=!1}else n=Li(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(no(t),t):(no(t),null);if(t.flags&128)throw Error(i(558))}return Pc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Fi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[tt]=t}else Ii(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Pc(t),a=!1}else a=Li(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(no(t),t):(no(t),null)}return no(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Mc(t,t.updateQueue),Pc(t),null);case 4:return ae(),e===null&&xd(t.stateNode.containerInfo),Pc(t),null;case 10:return Ui(t.type),Pc(t),null;case 19:if(z(ro),r=t.memoizedState,r===null)return Pc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Nc(r,!1);else{if(Ul!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=io(e),o!==null){for(t.flags|=128,Nc(r,!1),e=o.updateQueue,t.updateQueue=e,Mc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ai(n,e),n=n.sibling;return B(ro,ro.current&1|2),G&&Si(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&be()>eu&&(t.flags|=128,a=!0,Nc(r,!1),t.lanes=4194304)}}else{if(!a){if(e=io(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Mc(t,e),Nc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!G)return Pc(t),null}else 2*be()-r.renderingStartTime>eu&&n!==536870912&&(t.flags|=128,a=!0,Nc(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Pc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=be(),e.sibling=null,n=ro.current,B(ro,a?n&1|2:n&1),G&&Si(t,r.treeForkCount),e);case 22:case 23:return no(t),Ya(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Pc(t),t.subtreeFlags&6&&(t.flags|=8192)):Pc(t),n=t.updateQueue,n!==null&&Mc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&z(fa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Ui(ta),Pc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Ic(e,t){switch(Ti(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ui(ta),ae(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return se(t),null;case 31:if(t.memoizedState!==null){if(no(t),t.alternate===null)throw Error(i(340));Ii()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(no(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Ii()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return z(ro),null;case 4:return ae(),null;case 10:return Ui(t.type),null;case 22:case 23:return no(t),Ya(),e!==null&&z(fa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Ui(ta),null;case 25:return null;default:return null}}function Lc(e,t){switch(Ti(t),t.tag){case 3:Ui(ta),ae();break;case 26:case 27:case 5:se(t);break;case 4:ae();break;case 31:t.memoizedState!==null&&no(t);break;case 13:no(t);break;case 19:z(ro);break;case 10:Ui(t.type);break;case 22:case 23:no(t),Ya(),e!==null&&z(fa);break;case 24:Ui(ta)}}function Rc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Uu(t,t.return,e)}}function zc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Uu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Uu(t,t.return,e)}}function Bc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Wa(t,n)}catch(t){Uu(e,e.return,t)}}}function Vc(e,t,n){n.props=Hs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Uu(e,t,n)}}function Hc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Uu(e,t,n)}}function Uc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Uu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Uu(e,t,n)}else n.current=null}}function Wc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Uu(e,e.return,t)}}function Gc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[nt]=t}catch(t){Uu(e,e.return,t)}}function Kc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function qc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Kc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Jc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=qt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Jc(e,t,n),e=e.sibling;e!==null;)Jc(e,t,n),e=e.sibling}function Yc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Yc(e,t,n),e=e.sibling;e!==null;)Yc(e,t,n),e=e.sibling}function Xc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[tt]=e,t[nt]=n}catch(t){Uu(e,e.return,t)}}var Zc=!1,Qc=!1,$c=!1,el=typeof WeakSet==`function`?WeakSet:Set,tl=null;function nl(e,t){if(e=e.containerInfo,Rd=sp,e=xr(e),Sr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,tl=t;tl!==null;)if(t=tl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,tl=e;else for(;tl!==null;){switch(t=tl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n title`))),Pd(o,r,n),o[tt]=e,mt(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;cg&&(o=g,g=h,h=o);var _=yr(s,h),v=yr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;sn?32:n,N.T=null,n=su,su=null;var o=iu,s=au;if(ru=0,Q=iu=null,au=0,J&6)throw Error(i(331));var c=J;if(J|=4,Ml(o.current),wl(o,o.current,s,n),J=c,rd(0,!1),Ae&&typeof Ae.onPostCommitFiberRoot==`function`)try{Ae.onPostCommitFiberRoot(ke,o)}catch{}return!0}finally{P.p=a,N.T=r,zu(e,t)}}function Hu(e,t,n){t=fi(n,t),t=Js(e.stateNode,t,2),e=La(e,t,2),e!==null&&(H(e,2),nd(e))}function Uu(e,t,n){if(e.tag===3)Hu(e,e,n);else for(;t!==null;){if(t.tag===3){Hu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(nu===null||!nu.has(r))){e=fi(n,e),n=Ys(2),r=La(t,n,2),r!==null&&(Xs(n,r,t,e),H(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Il;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Vl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Ll===e&&(X&n)===n&&(Ul===4||Ul===3&&(X&62914560)===X&&300>be()-Ql?!(J&2)&&bu(e,0):Kl|=n,Jl===X&&(Jl=0)),nd(e)}function Ku(e,t){t===0&&(t=Ge()),e=Zr(e,t),e!==null&&(H(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return ge(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Me(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=X,a=Ue(r,r===Ll?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,cd(r,a))}r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Gd()&&(e=td);for(var t=be(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}ru!==0&&ru!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Nt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Nt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Nt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Nt(n.imageSizes)+`"]`)):i+=`[href="`+Nt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=f({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Nt(r)+`"][href="`+Nt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=f({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),mt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=pt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=f({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);mt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=f({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=f({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var a=(a=ne.current)?gf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=pt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=pt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=pt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Af(e){return`href="`+Nt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return f({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),mt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Nt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Nt(n.href)+`"]`);if(r)return t.instance=r,mt(r),r;var a=f({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),mt(r),Pd(r,`style`,a),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Af(n.href);var o=e.querySelector(jf(a));if(o)return t.state.loading|=4,t.instance=o,mt(o),o;r=Mf(n),(a=mf.get(a))&&Rf(r,a),o=(e.ownerDocument||e).createElement(`link`),mt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(a=e.querySelector(Ff(o)))?(t.instance=a,mt(a),a):(r=n,(a=mf.get(o))&&(r=f({},n),zf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),mt(a),Pd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,mt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),mt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Ue()})),V=i(Re(),1),Ge=We(),Ke=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),H=e(((e,t)=>{t.exports=Ke()}))(),qe=(0,V.createContext)(void 0);function Je(){let e=(0,V.useContext)(qe);if(!e)throw Error(`useToast must be used within a ToastProvider`);return e.toast}var Ye=0;function Xe({children:e}){let[t,n]=(0,V.useState)([]),r=(0,V.useState)(()=>new Map)[0];(0,V.useEffect)(()=>()=>{r.forEach(e=>clearTimeout(e)),r.clear()},[r]);let i=(0,V.useCallback)(e=>{let t=r.get(e);t&&(clearTimeout(t),r.delete(e)),n(t=>t.filter(t=>t.id!==e))},[r]),a=(0,V.useCallback)((e,t=`info`)=>{let i=++Ye;n(n=>[...n,{id:i,message:e,type:t}]);let a=setTimeout(()=>{r.delete(i),n(e=>e.filter(e=>e.id!==i))},4e3);r.set(i,a)},[r]),o=(0,V.useMemo)(()=>({success:e=>a(e,`success`),error:e=>a(e,`error`),info:e=>a(e,`info`),warning:e=>a(e,`warning`),showToast:(e,t)=>a(e,t||`info`),dismiss:i}),[a,i]);return(0,H.jsxs)(qe.Provider,{value:{toast:o},children:[e,(0,H.jsx)(`div`,{className:`toast-container`,"aria-live":`polite`,"aria-atomic":`true`,children:t.map(e=>(0,H.jsxs)(`div`,{className:`toast toast-${e.type}`,role:`status`,children:[e.type===`error`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`,"aria-hidden":`true`}),e.type===`success`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,"aria-hidden":`true`}),e.type===`info`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-info`,"aria-hidden":`true`}),e.type===`warning`&&(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,"aria-hidden":`true`}),(0,H.jsx)(`span`,{className:`toast-message`,children:e.message}),(0,H.jsx)(`button`,{type:`button`,className:`toast-dismiss-btn`,onClick:()=>i(e.id),"aria-label":`Dismiss notification`,title:`Dismiss`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-xmark`,"aria-hidden":`true`})})]},e.id))})]})}function Ze({stats:e,refreshStats:t}){let n=Je();return e?(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`overview-grid`,children:[(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-brands fa-github`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.repos_count??e.git_repos??0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`Git Repositories`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-code`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.symbols_count||0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`AST Code Symbols`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.files_count||0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`Indexed Files`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-network-wired`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.points_count||0).toLocaleString()}),(0,H.jsxs)(`span`,{className:`stat-label`,children:[(e.vector_store_provider||`Qdrant`).toUpperCase(),` (`,(e.vector_store_mode||`embedded`)===`embedded`?`Embedded`:`Remote`,`) Vectors`]})]})]})]}),(0,H.jsxs)(`div`,{className:`two-col-layout`,style:{marginTop:`20px`},children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-server`}),` System & Embedding Specs`]}),(0,H.jsxs)(`div`,{className:`specs-list`,children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Vector Database:`}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsxs)(`span`,{className:`badge badge-accent`,children:[e.vector_store_provider===`chroma`?`ChromaDB`:`Qdrant`,` (`,(e.vector_store_mode||`embedded`)===`embedded`?`Embedded Disk`:`Remote Server`,`)`]}),e.vector_db_status&&(0,H.jsx)(`span`,{className:`badge ${e.vector_db_status===`Healthy`?`badge-success`:`badge-danger`}`,"data-testid":`overview-vector-db-status`,children:e.vector_db_status})]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Dense Embedding Model:`}),(0,H.jsx)(`code`,{children:e.dense_model||`bge-small-en-v1.5 (384d)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Sparse BM25 Model:`}),(0,H.jsx)(`code`,{children:e.sparse_model?`${e.sparse_model} (FastEmbed)`:`Qdrant/bm25 (FastEmbed)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Retrieval Strategy:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.vector_store_provider===`chroma`?`Dense Vector Cosine Similarity`:`Dense + BM25 Normalized Weighted Fusion`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`AST Chunker:`}),(0,H.jsx)(`span`,{children:`Tree-sitter AST (Classes, Functions, Methods)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Last Global Index:`}),(0,H.jsx)(`span`,{className:`code`,children:e.last_indexed||`Never`})]})]}),(0,H.jsx)(`div`,{style:{marginTop:`20px`},children:(0,H.jsx)(`button`,{className:`btn btn-primary`,onClick:async()=>{try{let e=await fetch(`/admin/api/reindex`,{method:`POST`});if(!e.ok){let t=await e.json().catch(()=>({}));throw Error(t.error||`Failed to trigger reindex`)}n.success(`Re-indexing triggered successfully`),t()}catch(e){n.error(`Reindex error: `+e.message)}},disabled:e.is_indexing,children:e.is_indexing?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Reindex All Sources`]})})})]}),(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-tags`}),` Top Extracted Topics & Symbols`]}),(0,H.jsx)(`div`,{className:`tag-cloud`,children:!e.top_keywords||e.top_keywords.length===0?(0,H.jsx)(`span`,{className:`text-muted`,children:`No topics extracted yet. Sync repositories to populate.`}):e.top_keywords.map(e=>(0,H.jsx)(`span`,{className:`topic-tag`,children:e},e))})]})]})]}):(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsx)(`p`,{children:`Loading...`})})}var Qe=He();function $e({isOpen:e,onClose:t,onSave:n,alias:r,setAlias:i,url:a,setUrl:o,branch:s,setBranch:c,provider:l,setProvider:u,authUser:d,setAuthUser:f,token:p,setToken:m,keepShallow:h=!1,setKeepShallow:g,isSaving:_}){if(!e)return null;let v=(0,H.jsx)(`div`,{className:`modal-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`}),` Register Git Repository`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:n,children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-alias`,children:`Repository Alias / Identifier`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-alias`,required:!0,placeholder:`e.g. backend-api or contextcortex`,value:r,onChange:e=>i(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-provider`,children:`Git Provider`}),(0,H.jsxs)(`select`,{id:`repo-provider`,value:l,onChange:e=>u(e.target.value),children:[(0,H.jsx)(`option`,{value:`auto`,children:`Auto-Detect`}),(0,H.jsx)(`option`,{value:`github`,children:`GitHub / GitHub Enterprise`}),(0,H.jsx)(`option`,{value:`gitlab`,children:`GitLab (Cloud / Self-Hosted)`}),(0,H.jsx)(`option`,{value:`gitea`,children:`Gitea / Forgejo`}),(0,H.jsx)(`option`,{value:`bitbucket`,children:`Bitbucket`}),(0,H.jsx)(`option`,{value:`generic`,children:`Generic Git (HTTP / HTTPS)`})]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-url`,children:`Git Clone URL (HTTP / HTTPS)`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-url`,required:!0,placeholder:`https://github.com/owner/repo.git or http://git.lan:3000/repo.git`,value:a,onChange:e=>o(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-row form-row-3col`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-branch`,children:`Branch / Tag`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-branch`,placeholder:`main`,value:s,onChange:e=>c(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-user`,children:`Auth User (Optional)`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-user`,placeholder:`e.g. oauth2`,value:d,onChange:e=>f(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-token`,children:`Auth Token (Optional)`}),(0,H.jsx)(`input`,{type:`password`,id:`repo-token`,placeholder:`Token override`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginTop:`12px`},children:[(0,H.jsxs)(`label`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,cursor:`pointer`,fontWeight:600,color:`var(--text)`},children:[(0,H.jsx)(`input`,{type:`checkbox`,id:`repo-keep-shallow`,checked:h,onChange:e=>g?.(e.target.checked),style:{width:`16px`,height:`16px`,accentColor:`var(--primary)`,cursor:`pointer`}}),(0,H.jsx)(`span`,{children:`Keep shallow copy on disk`})]}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{fontSize:`0.82rem`,marginTop:`4px`,marginLeft:`24px`,lineHeight:`1.4`},children:[`When enabled, retains a shallow clone (`,(0,H.jsx)(`code`,{children:`--depth 1`}),`) in persistent storage on disk after indexing, enabling instant full-file inspection in Code Navigator and faster delta updates.`]})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:t,children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:_,children:_?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Adding & Syncing...`]}):`Add & Start Sync`})]})]})]})});return typeof document<`u`?(0,Qe.createPortal)(v,document.body):v}function et({repo:e,onClose:t,onCopyUrl:n,copiedUrl:r}){if(!e)return null;let i=`${typeof window<`u`?window.location.origin:``}/api/webhooks/git`,a=(0,H.jsx)(`div`,{className:`modal-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},"data-testid":`webhook-modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`650px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook Setup: `,e.name]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,"aria-label":`Close webhook modal`,children:`×`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`16px`,fontSize:`0.9rem`},children:[(0,H.jsx)(`p`,{className:`text-muted`,children:`Configure a webhook in your Git repository provider to automatically trigger synchronization on every push event.`}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Webhook URL (Payload URL)`}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:i,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`},"aria-label":`Webhook Payload URL`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>n(i),style:{minWidth:`95px`},"aria-label":`Copy Webhook URL`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-check`:`fa-copy`}`}),` `,r?`Copied!`:`Copy`]})]})]}),e.webhook_secret&&(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Repository Secret Token (HMAC)`}),(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:e.webhook_secret,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`},"aria-label":`Repository Secret Token`})]}),(0,H.jsxs)(`div`,{style:{background:`rgba(0, 0, 0, 0.25)`,border:`1px solid var(--border-card)`,borderRadius:`8px`,padding:`14px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`0.95rem`,marginBottom:`10px`,color:`var(--text)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-list-check`}),` Provider Setup Instructions`]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`10px`,fontSize:`0.85rem`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{marginRight:`6px`}}),` GitHub:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks > Add webhook`}),` → set `,(0,H.jsx)(`em`,{children:`Payload URL`}),` to the URL above → set `,(0,H.jsx)(`em`,{children:`Content type`}),` to `,(0,H.jsx)(`code`,{children:`application/json`}),` → select `,(0,H.jsx)(`em`,{children:`Push events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add webhook`}),`.`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab`,style:{color:`#fc6d26`,marginRight:`6px`}}),` GitLab:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks`}),` (or `,(0,H.jsx)(`code`,{children:`Settings > Integrations`}),`) → set `,(0,H.jsx)(`em`,{children:`URL`}),` → select `,(0,H.jsx)(`em`,{children:`Push events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add webhook`}),`.`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot`,style:{color:`#609926`,marginRight:`6px`}}),` Gitea / Forgejo:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks > Add Webhook > Gitea`}),` → set `,(0,H.jsx)(`em`,{children:`Target URL`}),` → set `,(0,H.jsx)(`em`,{children:`HTTP Method`}),` to `,(0,H.jsx)(`code`,{children:`POST`}),` → select `,(0,H.jsx)(`em`,{children:`Push Events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add Webhook`}),`.`]})]})]})]}),(0,H.jsx)(`div`,{className:`modal-footer`,style:{marginTop:`8px`,padding:0},children:(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:t,children:`Close`})})]})]})});return typeof document<`u`?(0,Qe.createPortal)(a,document.body):a}function U({repos:e,isLoading:t,syncStates:n,onSync:r,onToggleAutoSync:i,onToggleKeepShallow:a,onOpenWebhook:o,onDelete:s,onOpenSyncDrawer:c}){let l=e=>{let t=(e||`github`).toLowerCase();return t===`gitlab`?(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab`,style:{color:`#fc6d26`,marginRight:`6px`},title:`GitLab`}):t===`gitea`||t===`forgejo`?(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot`,style:{color:`#609926`,marginRight:`6px`},title:`Gitea / Forgejo`}):t===`bitbucket`?(0,H.jsx)(`i`,{className:`fa-brands fa-bitbucket`,style:{color:`#2684ff`,marginRight:`6px`},title:`Bitbucket`}):t===`generic`?(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`,style:{color:`var(--accent)`,marginRight:`6px`},title:`Generic Git`}):(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{marginRight:`6px`},title:`GitHub`})},u=(e,t)=>{let n=t?.step||1,r=t?.total_steps||5,i=t?.step_name||`Syncing...`,a=t?.percent??0,o=t?.current_file;return(0,H.jsxs)(`div`,{className:`sync-progress-container`,onClick:()=>c?.(e.id),role:`button`,tabIndex:0,style:{cursor:`pointer`},title:`Click to view live ingestion progress & logs`,onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&c?.(e.id)},children:[(0,H.jsxs)(`div`,{className:`progress-pill badge badge-warning`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),(0,H.jsxs)(`span`,{children:[`Step `,n,`/`,r,`: `,i,` (`,a,`%)`]})]}),(0,H.jsx)(`div`,{className:`sync-progress-bar-wrapper`,children:(0,H.jsx)(`div`,{className:`sync-progress-bar-fill fill-active`,style:{width:`${a}%`}})}),o&&(0,H.jsxs)(`div`,{className:`sync-file-caption`,title:o,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{marginRight:`4px`}}),(0,H.jsx)(`code`,{children:o})]})]})};return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Git URL`}),(0,H.jsx)(`th`,{children:`Branch`}),(0,H.jsx)(`th`,{children:`Commit SHA`}),(0,H.jsx)(`th`,{children:`Status`}),(0,H.jsx)(`th`,{children:`Auto-Sync`}),(0,H.jsx)(`th`,{children:`Shallow Copy`}),(0,H.jsx)(`th`,{children:`Files`}),(0,H.jsx)(`th`,{children:`Last Synced`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:t&&e.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsxs)(`td`,{colSpan:10,className:`empty-state`,"data-testid":`repo-loading-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading repositories...`]})}):e.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:10,className:`empty-state`,children:`No Git repositories registered. Click "Add Repository" to index a remote repo.`})}):e.map(e=>{let t=e.auto_sync!==!1&&e.auto_sync!==0,d=e.keep_shallow===!0||e.keep_shallow===1,f=n?.[e.id],p=e.status===`syncing`||f?.status===`syncing`;return(0,H.jsxs)(`tr`,{children:[(0,H.jsxs)(`td`,{children:[l(e.provider),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`a`,{href:e.url,target:`_blank`,rel:`noreferrer`,className:`repo-url-link`,style:{color:`var(--primary)`,textDecoration:`none`,fontSize:`0.85rem`},title:e.url,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrow-up-right-from-square`}),` `,e.url]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.branch})}),(0,H.jsx)(`td`,{children:e.commit_sha?(0,H.jsx)(`code`,{children:e.commit_sha.substring(0,8)}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:p?u(e,f):e.status===`error`||f?.status===`error`?(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.last_error||f?.error||`Sync failed`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}),(e.last_error||f?.error)&&(0,H.jsx)(`div`,{style:{fontSize:`0.75rem`,color:`var(--danger)`,marginTop:`4px`,maxWidth:`180px`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},title:e.last_error||f?.error||``,children:e.last_error||f?.error})]}):e.status===`pending`||f?.status===`pending`?(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]}):(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]})}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{type:`button`,className:`badge ${t?`badge-success`:`badge-danger`}`,style:{cursor:`pointer`,background:t?`rgba(16, 185, 129, 0.2)`:`rgba(239, 68, 68, 0.2)`,border:t?`1px solid rgba(16, 185, 129, 0.4)`:`1px solid rgba(239, 68, 68, 0.4)`,color:t?`#6ee7b7`:`#fca5a5`,padding:`4px 8px`,display:`inline-flex`,alignItems:`center`,gap:`6px`},onClick:()=>i(e.id,t),title:`Auto-Sync: ${t?`ON`:`OFF`} (Click to toggle)`,"aria-label":`Toggle auto-sync for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${t?`fa-toggle-on`:`fa-toggle-off`}`}),`Auto-Sync: `,t?`ON`:`OFF`]})}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{type:`button`,className:`badge ${d?`badge-primary`:`badge-secondary`}`,style:{cursor:`pointer`,background:d?`rgba(8, 145, 178, 0.2)`:`rgba(100, 116, 139, 0.2)`,border:d?`1px solid rgba(8, 145, 178, 0.4)`:`1px solid rgba(100, 116, 139, 0.4)`,color:d?`#38bdf8`:`#94a3b8`,padding:`4px 8px`,display:`inline-flex`,alignItems:`center`,gap:`6px`},onClick:()=>a?.(e.id,d),title:`Shallow Copy: ${d?`Retained on disk (persistent)`:`Ephemeral (pruned)`} (Click to toggle)`,"aria-label":`Toggle shallow copy retention for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${d?`fa-hard-drive`:`fa-trash-can`}`}),d?`Kept on Disk`:`Ephemeral`]})}),(0,H.jsxs)(`td`,{children:[(e.file_count||0).toLocaleString(),` files`]}),(0,H.jsx)(`td`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`},children:e.last_synced||`Never`}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>c?.(e.id),title:`View Ingestion Logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Logs`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>r(e.id),title:`Trigger Sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Sync`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>o(e),title:`Webhook Setup`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook`]}),(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>s(e.id,e.name),title:`Delete Repo`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})]})})]},e.id)})})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:t&&e.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,"data-testid":`repo-loading-state-mobile`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading repositories...`]}):e.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No Git repositories registered. Click "Add Repository" to index a remote repo.`}):e.map(e=>{let t=e.auto_sync!==!1&&e.auto_sync!==0,d=e.keep_shallow===!0||e.keep_shallow===1,f=n?.[e.id],p=e.status===`syncing`||f?.status===`syncing`;return(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:[l(e.provider),(0,H.jsx)(`strong`,{style:{fontSize:`1rem`},children:e.name})]}),!p&&(e.status===`error`||f?.status===`error`?(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.last_error||f?.error||`Sync failed`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}):e.status===`pending`||f?.status===`pending`?(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]}):(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]}))]}),p&&(0,H.jsx)(`div`,{style:{margin:`4px 0 2px 0`},children:u(e,f)}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`,alignItems:`baseline`},children:[(0,H.jsx)(`span`,{className:`data-label`,style:{flexShrink:0},children:`URL:`}),(0,H.jsx)(`a`,{href:e.url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,textDecoration:`none`,wordBreak:`break-all`,minWidth:0},children:e.url})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Branch:`}),(0,H.jsx)(`code`,{children:e.branch})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Commit:`}),e.commit_sha?(0,H.jsx)(`code`,{children:e.commit_sha.substring(0,8)}):`-`]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Auto-Sync:`}),(0,H.jsx)(`button`,{type:`button`,className:`badge ${t?`badge-success`:`badge-danger`}`,style:{cursor:`pointer`,padding:`4px 8px`,fontSize:`0.75rem`,minHeight:`24px`,minWidth:`24px`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},onClick:()=>i(e.id,t),title:`Auto-Sync: ${t?`ON`:`OFF`} (Click to toggle)`,"aria-label":`Toggle auto-sync for ${e.name}`,children:t?`ON`:`OFF`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Shallow Copy:`}),(0,H.jsxs)(`button`,{type:`button`,className:`badge ${d?`badge-primary`:`badge-secondary`}`,style:{cursor:`pointer`,padding:`4px 8px`,fontSize:`0.75rem`,minHeight:`24px`,display:`inline-flex`,alignItems:`center`,gap:`4px`},onClick:()=>a?.(e.id,d),title:`Shallow Copy: ${d?`Retained on disk`:`Ephemeral`} (Click to toggle)`,"aria-label":`Toggle shallow copy retention for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${d?`fa-hard-drive`:`fa-trash-can`}`}),d?`Kept on Disk`:`Ephemeral`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Files:`}),(e.file_count||0).toLocaleString(),` files`]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Last Synced:`}),e.last_synced||`Never`]}),!p&&(e.last_error||f?.error)&&(0,H.jsxs)(`div`,{style:{color:`var(--danger)`,fontSize:`0.75rem`},children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Error:`}),e.last_error||f?.error]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-actions`,children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>c?.(e.id),title:`View Ingestion Logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Logs`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>r(e.id),title:`Trigger Sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Sync`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>o(e),title:`Webhook Setup`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>s(e.id,e.name),title:`Delete Repo`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})]})]},`card-${e.id}`)})})]})}var tt=[{step:1,title:`1. Connecting & Remote Check`},{step:2,title:`2. Shallow Cloning Repository`},{step:3,title:`3. Computing File Delta & Scanning`},{step:4,title:`4. Parsing AST Symbols & API Routes`},{step:5,title:`5. Upserting Embeddings & Finalizing`}];function nt({isOpen:e,onClose:t,repoId:n,repoName:r,job:i,onCancelSync:a}){let[o,s]=(0,V.useState)(``),[c,l]=(0,V.useState)(!0),[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)(0),[m,h]=(0,V.useState)(!1),g=(0,V.useRef)(null),_=(0,V.useRef)(null),v=n??i?.repo_id??null,y=r||i?.repo_name||`Repository`;(0,V.useEffect)(()=>{if(!e||!i?.started_at){p(0);return}let t=()=>{let e=i.started_at>1e11?i.started_at:i.started_at*1e3;return Math.max(0,Math.floor((Date.now()-e)/1e3))};if(p(t()),i.status===`syncing`||i.status===`pending`){let e=setInterval(()=>{p(t())},1e3);return()=>clearInterval(e)}},[e,i?.started_at,i?.status]);let b=e=>{let t=Math.floor(e/60),n=e%60;return`${t.toString().padStart(2,`0`)}:${n.toString().padStart(2,`0`)}`},x=i?.logs,S=(0,V.useMemo)(()=>{let e=x||[];if(!o.trim())return e;let t=o.toLowerCase();return e.filter(e=>e.message.toLowerCase().includes(t)||e.level.toLowerCase().includes(t)||e.timestamp.toLowerCase().includes(t))},[x,o]);(0,V.useEffect)(()=>{c&&g.current&&typeof g.current.scrollIntoView==`function`&&g.current.scrollIntoView({behavior:`smooth`})},[S,c]);let C=async()=>{let e=(i?.logs||[]).map(e=>`[${e.timestamp}] [${e.level.toUpperCase()}] ${e.message}`).join(` +`);try{await navigator.clipboard.writeText(e),d(!0),setTimeout(()=>d(!1),2e3)}catch(e){console.error(`Failed to copy logs:`,e)}},w=async()=>{if(!(!v||!a))try{h(!0),await a(v)}catch(e){console.error(`Failed to cancel sync:`,e)}finally{h(!1)}};if(!e)return null;let T=i?.status||`pending`,E=i?.percent??(T===`synced`?100:0),D=i?.step??(T===`synced`?5:1),O=(0,H.jsx)(`div`,{className:`sync-drawer-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},"data-testid":`sync-drawer-backdrop`,children:(0,H.jsxs)(`div`,{className:`sync-drawer`,children:[(0,H.jsxs)(`div`,{className:`sync-drawer-header`,children:[(0,H.jsxs)(`div`,{className:`sync-drawer-title-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:[(0,H.jsxs)(`h2`,{style:{fontSize:`1.1rem`,margin:0,fontWeight:700,color:`var(--text)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`,style:{marginRight:`8px`,color:`var(--primary)`}}),y,` Ingestion Progress & Live Logs`]}),T===`syncing`?(0,H.jsxs)(`span`,{className:`badge badge-warning`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing`]}):T===`synced`?(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]}):T===`error`?(0,H.jsxs)(`span`,{className:`badge badge-danger`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}):(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]})]}),(0,H.jsxs)(`div`,{className:`sync-drawer-meta`,style:{display:`flex`,alignItems:`center`,gap:`12px`,marginTop:`6px`,fontSize:`0.82rem`,color:`var(--text-muted)`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`i`,{className:`fa-regular fa-clock`,style:{marginRight:`4px`}}),`Elapsed: `,(0,H.jsx)(`strong`,{children:b(f)})]}),i?.step_name&&(0,H.jsxs)(`span`,{children:[`• Current: `,(0,H.jsx)(`strong`,{children:i.step_name})]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[T===`syncing`&&a&&v!=null&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-cancel-sync`,onClick:w,disabled:m,style:{fontSize:`0.8rem`,padding:`6px 12px`,color:`var(--danger)`,borderColor:`rgba(239, 68, 68, 0.4)`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${m?`fa-spinner fa-spin`:`fa-stop`}`}),m?`Cancelling...`:`Cancel Sync`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,"aria-label":`Close sync drawer`,style:{fontSize:`1.4rem`,lineHeight:1},children:`×`})]})]}),(0,H.jsxs)(`div`,{className:`sync-drawer-body`,children:[(0,H.jsxs)(`div`,{className:`sync-progress-section`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`span`,{style:{fontWeight:600,color:`var(--text)`},children:`Overall Ingestion`}),(0,H.jsxs)(`span`,{style:{fontWeight:700,color:T===`error`?`var(--danger)`:`var(--primary)`},children:[E,`%`]})]}),(0,H.jsx)(`div`,{className:`sync-progress-bar-container`,children:(0,H.jsx)(`div`,{className:`sync-progress-bar-fill ${T===`error`?`fill-error`:T===`synced`?`fill-success`:`fill-active`}`,style:{width:`${E}%`}})})]}),(0,H.jsxs)(`div`,{className:`sync-stepper-container`,children:[(0,H.jsx)(`h4`,{style:{fontSize:`0.82rem`,textTransform:`uppercase`,letterSpacing:`0.05em`,color:`var(--text-muted)`,marginBottom:`10px`},children:`Ingestion Stages`}),(0,H.jsx)(`div`,{className:`sync-stepper-list`,children:tt.map(e=>{let t=T===`synced`||T!==`error`&&D>e.step||T===`error`&&D>e.step,n=T===`syncing`&&D===e.step,r=T===`error`&&D===e.step;return(0,H.jsxs)(`div`,{className:`sync-stepper-item ${t?`item-completed`:n?`item-active`:r?`item-error`:`item-pending`}`,children:[(0,H.jsxs)(`div`,{className:`sync-stepper-icon`,children:[t&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,style:{color:`#10b981`}}),n&&(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{color:`#f59e0b`}}),r&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-xmark`,style:{color:`#ef4444`}}),!t&&!n&&!r&&(0,H.jsx)(`i`,{className:`fa-regular fa-circle`,style:{color:`var(--text-muted)`}})]}),(0,H.jsxs)(`div`,{className:`sync-stepper-content`,children:[(0,H.jsx)(`div`,{className:`sync-stepper-title`,style:{fontWeight:n?600:500},children:e.title}),n&&(0,H.jsxs)(`div`,{className:`sync-stepper-details`,children:[i?.current_file&&(0,H.jsxs)(`div`,{className:`sync-current-file`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{marginRight:`4px`}}),(0,H.jsx)(`code`,{children:i.current_file})]}),i?.total_files!=null&&i.total_files>0&&(0,H.jsxs)(`div`,{className:`sync-file-count`,style:{marginTop:`2px`,color:`var(--text-muted)`},children:[i.processed_files,` / `,i.total_files,` files (`,E,`%)`]})]}),r&&i?.error&&(0,H.jsxs)(`div`,{className:`sync-stepper-error-msg`,style:{marginTop:`4px`,color:`var(--danger)`,fontSize:`0.82rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{marginRight:`4px`}}),i.error]})]})]},e.step)})})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-section`,children:[(0,H.jsxs)(`div`,{className:`sync-terminal-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`,style:{color:`var(--accent)`}}),(0,H.jsx)(`span`,{style:{fontSize:`0.85rem`,fontWeight:600,color:`var(--text)`},children:`Live Terminal Output`}),(0,H.jsxs)(`span`,{className:`badge badge-secondary`,style:{fontSize:`0.75rem`,padding:`1px 6px`},children:[S.length,` `,S.length===1?`event`:`events`]})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-actions`,children:[(0,H.jsxs)(`label`,{className:`sync-autoscroll-toggle`,children:[(0,H.jsx)(`input`,{type:`checkbox`,checked:c,onChange:e=>l(e.target.checked),"aria-label":`Autoscroll`}),(0,H.jsx)(`span`,{children:`Autoscroll`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-sm`,onClick:C,"aria-label":`Copy logs`,style:{fontSize:`0.75rem`,padding:`3px 8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${u?`fa-check`:`fa-copy`}`}),` `,u?`Copied!`:`Copy Logs`]})]})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-search`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`,style:{color:`var(--text-muted)`,fontSize:`0.8rem`}}),(0,H.jsx)(`input`,{type:`text`,placeholder:`Filter logs by keyword or level...`,value:o,onChange:e=>s(e.target.value),style:{width:`100%`,background:`transparent`,border:`none`,outline:`none`,color:`var(--text)`,fontSize:`0.82rem`,padding:`4px 0`}}),o&&(0,H.jsx)(`button`,{type:`button`,onClick:()=>s(``),style:{background:`transparent`,border:`none`,color:`var(--text-muted)`,cursor:`pointer`,fontSize:`0.8rem`},children:`×`})]}),(0,H.jsx)(`div`,{className:`sync-terminal-body`,ref:_,children:S.length===0?(0,H.jsxs)(`div`,{className:`sync-terminal-empty`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock-rotate-left`,style:{marginBottom:`6px`,fontSize:`1.2rem`,opacity:.5}}),(0,H.jsx)(`div`,{children:(x?.length||0)===0?`Waiting for sync activity...`:`No logs matching filter`})]}):(0,H.jsxs)(`div`,{className:`sync-terminal-lines`,children:[S.map((e,t)=>{let n=(e.level||`INFO`).toUpperCase(),r=`level-info`;return(n===`WARN`||n===`WARNING`)&&(r=`level-warn`),(n===`ERROR`||n===`FATAL`)&&(r=`level-error`),(0,H.jsxs)(`div`,{className:`sync-terminal-line`,children:[(0,H.jsxs)(`span`,{className:`log-time`,children:[`[`,e.timestamp,`]`]}),(0,H.jsx)(`span`,{className:`log-badge ${r}`,children:n}),(0,H.jsx)(`span`,{className:`log-msg`,children:e.message})]},t)}),(0,H.jsx)(`div`,{ref:g})]})})]})]})]})});return typeof document<`u`?(0,Qe.createPortal)(O,document.body):O}function rt(){let[e,t]=(0,V.useState)({}),[n,r]=(0,V.useState)(!1),i=(0,V.useRef)(null),a=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/repos/sync-status`);if(e&&e.ok){let n=await e.json();if(n&&typeof n==`object`&&!Array.isArray(n)){let e={};Object.entries(n).forEach(([t,n])=>{let r=n;r&&(r.repo_id!=null||r.step!=null||r.status!=null)&&(e[Number(t)]=r)}),t(t=>({...t,...e}))}else if(Array.isArray(n)){let e={};n.forEach(t=>{t&&t.repo_id!=null&&(t.step!=null||t.status===`syncing`)&&(e[t.repo_id]=t)}),Object.keys(e).length>0&&t(t=>({...t,...e}))}}}catch(e){console.error(`Failed to fetch initial sync status snapshot:`,e)}},[]);return(0,V.useEffect)(()=>{if(a(),typeof EventSource>`u`)return;let e=null;try{e=new EventSource(`/admin/api/repos/sync/stream`),i.current=e,e.onopen=()=>{r(!0)},e.onerror=()=>{r(!1)},e.addEventListener(`init`,e=>{try{let n=JSON.parse(e.data);if(n&&typeof n==`object`){let e={};Object.entries(n).forEach(([t,n])=>{e[Number(t)]=n}),t(e),r(!0)}}catch(e){console.error(`Failed to parse init sync stream event:`,e)}}),e.addEventListener(`progress`,e=>{try{let n=JSON.parse(e.data),i=n.data||n;i&&i.repo_id!=null&&(t(e=>{let t=e[i.repo_id];return{...e,[i.repo_id]:{...t||{},...i,logs:i.logs??t?.logs??[]}}}),r(!0))}catch(e){console.error(`Failed to parse progress event:`,e)}}),e.addEventListener(`log`,e=>{try{let n=JSON.parse(e.data),r=n.repo_id??n.data?.repo_id,i=n.data&&!n.data.repo_id?n.data:n.log||n.data;r!=null&&i&&t(e=>{let t=e[r];if(!t)return e;let n=t.logs||[];return{...e,[r]:{...t,logs:[...n,i]}}})}catch(e){console.error(`Failed to parse log event:`,e)}})}catch(e){console.error(`Failed to initialize EventSource:`,e),r(!1)}return()=>{e&&(e.close(),i.current=null)}},[a]),{syncStates:e,isConnected:n,cancelSync:(0,V.useCallback)(async e=>{try{let t=await fetch(`/admin/api/repos/${e}/cancel-sync`,{method:`POST`});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||`Failed to cancel sync: ${t.statusText}`)}return await t.json()}catch(t){throw console.error(`Error cancelling sync for repo ${e}:`,t),t}},[])}}function it({refreshStats:e}){let[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!0),[a,o]=(0,V.useState)(!1),[s,c]=(0,V.useState)(null),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(null),p=Je(),m=(0,V.useRef)(null);(0,V.useEffect)(()=>()=>{m.current&&clearTimeout(m.current)},[]);let{syncStates:h,cancelSync:g}=rt(),[_,v]=(0,V.useState)(``),[y,b]=(0,V.useState)(``),[x,S]=(0,V.useState)(`main`),[C,w]=(0,V.useState)(`auto`),[T,E]=(0,V.useState)(``),[D,O]=(0,V.useState)(``),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),N=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/repos`);if(!e.ok){p.error(`Failed to load repositories`);return}let t=await e.json();n(Array.isArray(t)?t:[])}catch(e){p.error(`Error loading repos: `+e.message),console.error(`Error loading repos:`,e)}finally{i(!1)}},[p]);(0,V.useEffect)(()=>{N();let e=setInterval(N,8e3);return()=>clearInterval(e)},[N]);let P=async t=>{t.preventDefault(),M(!0);try{let t=await fetch(`/admin/api/repos`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({name:_.trim(),url:y.trim(),branch:x.trim()||`main`,provider:C===`auto`?void 0:C,auth_user:T.trim()||null,auth_token:D.trim()||null,keep_shallow:k})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add repository`);o(!1),v(``),b(``),S(`main`),w(`auto`),E(``),O(``),A(!1),N(),e(),p.success(`Repository '${_.trim()}' added successfully`)}catch(e){p.error(`Error: ${e.message}`)}finally{M(!1)}},F=async t=>{n(e=>e.map(e=>e.id===t?{...e,status:`syncing`}:e));try{let n=await fetch(`/admin/api/repos/sync/${t}`,{method:`POST`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to trigger sync`)}N(),e(),p.info(`Sync triggered successfully`)}catch(e){N(),p.error(`Failed to trigger sync: `+e.message)}},I=async(e,t)=>{let r=!t;n(t=>t.map(t=>t.id===e?{...t,auto_sync:r}:t));try{let t=await fetch(`/admin/api/repos/${e}/auto-sync`,{method:`PATCH`,headers:{"Content-Type":`application/json`},body:JSON.stringify({auto_sync:r})});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||e.detail||`Failed to update auto-sync`)}p.info(`Auto-sync ${r?`enabled`:`disabled`}`),N()}catch(e){N(),p.error(`Failed to update auto-sync: `+e.message)}},L=async(e,t)=>{let r=!t;n(t=>t.map(t=>t.id===e?{...t,keep_shallow:r}:t));try{let t=await fetch(`/admin/api/repos/${e}/keep-shallow`,{method:`PATCH`,headers:{"Content-Type":`application/json`},body:JSON.stringify({keep_shallow:r})});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||e.detail||`Failed to update shallow copy retention`)}p.info(`Shallow copy retention ${r?`enabled (retained on disk)`:`disabled (ephemeral)`}`),N()}catch(e){N(),p.error(`Failed to update shallow copy setting: `+e.message)}},R=async e=>{try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(e),u(!0),p.info(`Webhook URL copied to clipboard`),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{typeof window<`u`&&u(!1)},2e3)}catch(e){p.error(`Failed to copy: `+e.message)}},z=async(t,r)=>{if(window.confirm(`Are you sure you want to delete repository '${r}'? All vectors and indexed symbols for this repo will be permanently purged.`)){n(e=>e.filter(e=>e.id!==t));try{let n=await fetch(`/admin/api/repos/${t}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete repo`)}N(),e(),p.success(`Repository '${r}' deleted successfully`)}catch(e){N(),p.error(`Failed to delete repo: `+e.message)}}},B=d===null?null:h[d],ee=t.find(e=>e.id===d)?.name||B?.repo_name||``;return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`}),` Registered Git Repositories`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Supports GitHub, GitLab, Gitea, Bitbucket, and custom self-hosted Git repositories over HTTP/HTTPS.`})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>o(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Repository`]})]}),(0,H.jsx)(U,{repos:t,isLoading:r,syncStates:h,onSync:F,onToggleAutoSync:I,onToggleKeepShallow:L,onOpenWebhook:e=>c(e),onDelete:z,onOpenSyncDrawer:e=>f(e)})]}),(0,H.jsx)($e,{isOpen:a,onClose:()=>o(!1),onSave:P,alias:_,setAlias:v,url:y,setUrl:b,branch:x,setBranch:S,provider:C,setProvider:w,authUser:T,setAuthUser:E,token:D,setToken:O,keepShallow:k,setKeepShallow:A,isSaving:j}),(0,H.jsx)(et,{repo:s,onClose:()=>c(null),onCopyUrl:R,copiedUrl:l}),(0,H.jsx)(nt,{isOpen:d!==null,onClose:()=>f(null),repoId:d,repoName:ee,job:B,onCancelSync:g})]})}function at({refreshStats:e}){let[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!0),a=Je(),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(``),[f,p]=(0,V.useState)(`local`),[m,h]=(0,V.useState)(``),[g,_]=(0,V.useState)(`directory`),[v,y]=(0,V.useState)(1),[b,x]=(0,V.useState)(null),S=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/paths`);if(!e.ok){a.error(`Failed to load local paths`);return}let t=await e.json();n(t)}catch(e){a.error(`Error loading paths: `+e.message),console.error(`Error loading paths:`,e)}finally{i(!1)}},[a]);(0,V.useEffect)(()=>{S();let e=setInterval(S,8e3);return()=>clearInterval(e)},[S]);let C=async t=>{t.preventDefault();try{let t=await fetch(`/admin/api/paths`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:u.trim(),repo:f.trim()||`local`,category:m.trim()||null,type:g,recursive:v,enabled:1})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add path`);s(!1),d(``),p(`local`),h(``),_(`directory`),y(1),S(),e(),a.success(`Path added successfully`)}catch(e){a.error(`Error: ${e.message}`)}},w=async t=>{if(window.confirm(`Are you sure you want to delete this local search path?`)){n(e=>e.filter(e=>e.id!==t));try{let n=await fetch(`/admin/api/paths/${t}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete path`)}a.success(`Path deleted successfully`),S(),e()}catch(e){S(),a.error(`Failed to delete path: `+e.message)}}},T=(e=`/`)=>{l(!0),E(e)},E=async e=>{try{let t=await fetch(`/admin/api/browse?path=${encodeURIComponent(e)}`),n=await t.json();if(!t.ok){a.error(n.error||`Failed to browse directory`);return}x(n)}catch(e){a.error(`Browse error: `+e.message),console.error(`Browse error:`,e)}};return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Monitored Local Paths`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Mounted documentation vaults and local workspaces scanned for changes.`})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>s(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Local Path`]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Type`}),(0,H.jsx)(`th`,{children:`Recursive`}),(0,H.jsx)(`th`,{children:`Category`}),(0,H.jsx)(`th`,{children:`Enabled`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:r&&t.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsxs)(`td`,{colSpan:7,className:`empty-state`,"data-testid":`path-loading-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading local paths...`]})}):t.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:7,className:`empty-state`,children:`No local search paths configured.`})}):t.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo||`local`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.type})}),(0,H.jsx)(`td`,{children:e.recursive?`Yes`:`No`}),(0,H.jsx)(`td`,{children:e.category?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:e.enabled?(0,H.jsx)(`span`,{className:`badge badge-success`,children:`Enabled`}):(0,H.jsx)(`span`,{className:`badge badge-danger`,children:`Disabled`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>w(e.id),title:`Delete Path`,"aria-label":`Delete Path`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:r&&t.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,"data-testid":`path-loading-state-mobile`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading local paths...`]}):t.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No local search paths configured.`}):t.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,minWidth:0},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{color:`var(--accent)`}}),(0,H.jsx)(`strong`,{style:{fontSize:`1rem`},children:e.repo||`local`})]}),e.enabled?(0,H.jsx)(`span`,{className:`badge badge-success`,children:`Enabled`}):(0,H.jsx)(`span`,{className:`badge badge-danger`,children:`Disabled`})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.path})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,flexWrap:`wrap`,alignItems:`center`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Type: `}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.type})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Recursive: `}),(0,H.jsx)(`span`,{children:e.recursive?`Yes`:`No`})]})]}),e.category&&(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Category: `}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category})]})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>w(e.id),title:`Delete Path`,"aria-label":`Delete Path`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})})]},`card-${e.id}`))})]}),o&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Add Monitored Local Path`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>s(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:C,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Selected Directory / File`}),(0,H.jsxs)(`div`,{className:`path-input-row`,children:[(0,H.jsx)(`input`,{type:`text`,readOnly:!0,required:!0,placeholder:`Browse workspace directories...`,value:u}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>T(b?.current_path||`/`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Browse`]})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-repo-alias`,children:`Repo / Vault Alias`}),(0,H.jsx)(`input`,{type:`text`,id:`path-repo-alias`,placeholder:`local`,value:f,onChange:e=>p(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-category`,children:`Category Override`}),(0,H.jsx)(`input`,{type:`text`,id:`path-category`,placeholder:`Optional category`,value:m,onChange:e=>h(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-type`,children:`Path Type`}),(0,H.jsxs)(`select`,{id:`path-type`,value:g,onChange:e=>_(e.target.value),children:[(0,H.jsx)(`option`,{value:`directory`,children:`Directory`}),(0,H.jsx)(`option`,{value:`file`,children:`Single File`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-recursive`,children:`Scan Subfolders`}),(0,H.jsxs)(`select`,{id:`path-recursive`,value:v,onChange:e=>y(parseInt(e.target.value)),children:[(0,H.jsx)(`option`,{value:1,children:`Yes (Recursive)`}),(0,H.jsx)(`option`,{value:0,children:`No (Top-level only)`})]})]})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>s(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,children:`Save Path`})]})]})]})}),c&&b&&(0,H.jsx)(`div`,{className:`modal-backdrop`,style:{zIndex:1100},children:(0,H.jsxs)(`div`,{className:`glass-card modal-card browser-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-search`}),` Browse Workspace Files`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>l(!1),children:`×`})]}),(0,H.jsxs)(`div`,{className:`browser-body`,children:[(0,H.jsxs)(`div`,{className:`browser-breadcrumbs`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Current: `}),(0,H.jsx)(`span`,{className:`code`,style:{wordBreak:`break-all`},children:b.current_path})]}),(0,H.jsx)(`div`,{className:`browser-list-container`,children:(0,H.jsxs)(`ul`,{className:`browser-list`,children:[b.parent_path&&(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>E(b.parent_path),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-level-up-alt`,style:{color:`var(--accent)`}}),` `,(0,H.jsx)(`span`,{children:`.. (Parent Directory)`})]}),b.directories.map(e=>(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>E(e.path),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`}}),` `,(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.name})]},e.path)),b.files.map(e=>(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>{d(e.path),_(`file`),l(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{color:`var(--text-muted)`}}),` `,(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.name})]},e.path))]})})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>l(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-primary`,onClick:()=>{b&&(d(b.current_path),_(`directory`),l(!1))},children:`Select Current Folder`})]})]})})]})}function ot({data:e,onConfirm:t,onCancel:n,isIngesting:r=!1}){let[i,a]=(0,V.useState)(`pages`),[o,s]=(0,V.useState)(0),c=e.total_pages||e.pages.length||1,l=e.pages[o]||{page_number:1,text:``,char_count:0,ocr_applied:!1};return(0,H.jsx)(`div`,{className:`modal-backdrop`,"data-testid":`pdf-preview-modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`850px`,width:`95%`,maxHeight:`90vh`,display:`flex`,flexDirection:`column`},"data-testid":`pdf-preview-modal`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,style:{marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,margin:0,fontSize:`1.25rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`}}),(0,H.jsx)(`span`,{children:`PDF Extraction Preview`})]}),(0,H.jsx)(`div`,{style:{fontSize:`0.85rem`,color:`var(--text-muted)`,marginTop:`4px`},children:(0,H.jsx)(`code`,{children:e.filename})})]}),(0,H.jsx)(`button`,{type:`button`,className:`btn-close`,onClick:n,"aria-label":`Close modal`,children:`×`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`10px`,padding:`10px 14px`,background:`rgba(255, 255, 255, 0.04)`,borderRadius:`6px`,marginBottom:`14px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`14px`,flexWrap:`wrap`,alignItems:`center`,fontSize:`0.85rem`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`Total Pages:`}),` `,(0,H.jsx)(`span`,{className:`badge badge-primary`,"data-testid":`total-pages-badge`,children:e.total_pages})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`Total Characters:`}),` `,(0,H.jsx)(`span`,{className:`badge badge-primary`,"data-testid":`total-chars-badge`,children:e.total_characters.toLocaleString()})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`OCR Applied:`}),` `,(0,H.jsxs)(`span`,{className:`badge ${e.ocr_pages_count>0?`badge-warning`:`badge-secondary`}`,"data-testid":`ocr-count-badge`,children:[e.ocr_pages_count,` `,e.ocr_pages_count===1?`page`:`pages`]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},children:[(0,H.jsxs)(`button`,{type:`button`,className:`btn ${i===`pages`?`btn-primary`:`btn-secondary`}`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:()=>a(`pages`),"data-testid":`tab-pages-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{marginRight:`5px`}}),` Page Text`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn ${i===`chunks`?`btn-primary`:`btn-secondary`}`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:()=>a(`chunks`),"data-testid":`tab-chunks-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group`,style:{marginRight:`5px`}}),` Sample Chunks (`,e.sample_chunks?.length||0,`)`]})]})]}),(0,H.jsx)(`div`,{style:{flex:1,overflowY:`auto`,minHeight:`320px`,display:`flex`,flexDirection:`column`},children:i===`pages`?(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,height:`100%`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`8px`,marginBottom:`10px`,padding:`6px 10px`,background:`rgba(0, 0, 0, 0.2)`,borderRadius:`6px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>{o>0&&s(e=>e-1)},disabled:o<=0,"aria-label":`Previous Page`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-chevron-left`}),` Prev`]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`span`,{children:`Page`}),(0,H.jsx)(`select`,{value:o,onChange:t=>{let n=parseInt(t.target.value,10);!isNaN(n)&&n>=0&&n(0,H.jsxs)(`option`,{value:t,children:[e.page_number,` `,e.ocr_applied?`(OCR)`:``]},e.page_number))}),(0,H.jsxs)(`span`,{children:[`of `,c]})]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>{oe+1)},disabled:o>=e.pages.length-1,"aria-label":`Next Page`,children:[`Next `,(0,H.jsx)(`i`,{className:`fa-solid fa-chevron-right`})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[l.ocr_applied?(0,H.jsxs)(`span`,{className:`badge badge-warning`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`},"data-testid":`page-ocr-applied-badge`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-eye`}),` OCR Fallback`]}):(0,H.jsxs)(`span`,{className:`badge badge-secondary`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`},"data-testid":`page-digital-badge`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-font`}),` Digital`]}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[l.char_count.toLocaleString(),` chars`]})]})]}),(0,H.jsx)(`div`,{style:{flex:1,minHeight:`260px`,position:`relative`},children:l.text?(0,H.jsx)(`pre`,{className:`search-hit-code`,style:{maxHeight:`400px`,overflowY:`auto`,margin:0,whiteSpace:`pre-wrap`,wordBreak:`break-word`,fontSize:`0.85rem`,lineHeight:`1.5`,padding:`12px`,background:`rgba(0, 0, 0, 0.3)`,borderRadius:`6px`},"data-testid":`page-text-content`,children:l.text}):(0,H.jsxs)(`div`,{className:`empty-state`,style:{padding:`30px`,textAlign:`center`,color:`var(--text-muted)`},"data-testid":`page-empty-text`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-circle-question`,style:{fontSize:`1.5rem`,marginBottom:`8px`,display:`block`}}),`No text extracted from Page `,l.page_number,`.`]})})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`10px`},"data-testid":`chunks-container`,children:[(0,H.jsx)(`div`,{style:{fontSize:`0.82rem`,color:`var(--text-muted)`,marginBottom:`4px`},children:`Simulated chunking for vector ingestion (approx. 1000 chars / chunk with 200 char overlap):`}),!e.sample_chunks||e.sample_chunks.length===0?(0,H.jsx)(`div`,{className:`empty-state`,style:{padding:`24px`},children:`No vector chunks generated for this document.`}):e.sample_chunks.map(e=>(0,H.jsxs)(`div`,{style:{border:`1px solid var(--border-card)`,borderRadius:`6px`,background:`rgba(0, 0, 0, 0.25)`,padding:`10px 12px`},"data-testid":`chunk-card-${e.chunk_index}`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,fontSize:`0.8rem`,marginBottom:`6px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`center`},children:[(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[`Chunk #`,e.chunk_index+1]}),(0,H.jsxs)(`span`,{className:`text-muted`,children:[e.heading,` (Page `,e.page_number,`)`]})]}),(0,H.jsxs)(`span`,{className:`badge badge-secondary`,children:[e.char_count,` chars`]})]}),(0,H.jsx)(`pre`,{style:{margin:0,whiteSpace:`pre-wrap`,wordBreak:`break-word`,fontFamily:`var(--font-family-mono)`,fontSize:`0.8rem`,color:`var(--text)`,lineHeight:`1.4`,background:`rgba(0, 0, 0, 0.2)`,padding:`8px`,borderRadius:`4px`},children:e.preview})]},e.chunk_index))]})}),(0,H.jsxs)(`div`,{className:`modal-footer`,style:{marginTop:`16px`,paddingTop:`12px`,borderTop:`1px solid var(--border-card)`,display:`flex`,justifyContent:`flex-end`,gap:`10px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:n,disabled:r,children:`Cancel`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-primary`,onClick:t,disabled:r,"data-testid":`confirm-ingest-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-spinner fa-spin`:`fa-database`}`,style:{marginRight:`6px`}}),r?`Ingesting...`:`Confirm & Ingest to Vector DB`]})]})]})})}function st({refreshStats:e}){let t=Je(),[n,r]=(0,V.useState)(null),[i,a]=(0,V.useState)(``),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(``),[f,p]=(0,V.useState)(``),[m,h]=(0,V.useState)(`local_storage`),[g,_]=(0,V.useState)(``),[v,y]=(0,V.useState)(null),[b,x]=(0,V.useState)(!1),[S,C]=(0,V.useState)(!1),[w,T]=(0,V.useState)(!1),[E,D]=(0,V.useState)(null),[O,k]=(0,V.useState)(!1),[A,j]=(0,V.useState)(!1),[M,N]=(0,V.useState)(null),[P,F]=(0,V.useState)(``),[I,L]=(0,V.useState)(``),[R,z]=(0,V.useState)(!1),[B,ee]=(0,V.useState)(!1),[te,ne]=(0,V.useState)(!1),[re,ie]=(0,V.useState)(null),[ae,oe]=(0,V.useState)(null),[se,ce]=(0,V.useState)(``),[le,ue]=(0,V.useState)(`local_storage`),[de,fe]=(0,V.useState)(``),[pe,me]=(0,V.useState)(!1),he=e=>{if(!e||e===0)return`0 B`;let t=1024,n=[`B`,`KB`,`MB`,`GB`],r=Math.floor(Math.log(e)/Math.log(t));return parseFloat((e/t**r).toFixed(1))+` `+n[r]},ge=e=>{if(!e)return`-`;let t=e<1e11?e*1e3:e;return new Date(t).toLocaleString()},_e=(0,V.useCallback)(async(e=i)=>{s(!0);try{let t=e?`/admin/api/storage/tree?folder=${encodeURIComponent(e)}`:`/admin/api/storage/tree`,n=await fetch(t);if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to load storage tree`)}let i=await n.json();r(i),a(i.current_folder||``)}catch(e){t.error(`Error loading storage: `+e.message),console.error(`Error loading storage tree:`,e)}finally{s(!1)}},[i,t]);(0,V.useEffect)(()=>{_e(``)},[]);let ve=e=>{_e(e)},ye=()=>{if(!i)return;let e=i.split(`/`).filter(Boolean);e.pop(),ve(e.join(`/`))},be=e=>{let t=e===void 0?i:e;d(t?`${t}/`:``),p(``),h(`local_storage`),_(``),y(null),l(!0)},xe=e=>{if(e.preventDefault(),x(!1),e.dataTransfer.files&&e.dataTransfer.files.length>0){let t=e.dataTransfer.files[0];Ee(t)}},Se=e=>{e.target.files&&e.target.files.length>0&&Ee(e.target.files[0])},Ce=async(e,n,r,a)=>{ne(!0);try{let t=new FormData;t.append(`file`,e),t.append(`ocr_fallback`,`true`);let o=await fetch(`/admin/api/storage/pdf/preview`,{method:`POST`,body:t}),s=await o.json();if(!o.ok)throw Error(s.error||`Failed to generate PDF preview`);oe(e),ce(n||(i?`${i}/${e.name}`:e.name)),ue(r||m||`local_storage`),fe(a||f||``),ie(s),l(!1),ee(!0)}catch(e){t.error(`PDF preview error: ${e.message}`)}finally{ne(!1)}},we=async()=>{if(ae){me(!0);try{let n=new FormData;n.append(`file`,ae),n.append(`path`,se||ae.name),n.append(`repo`,le||`local_storage`),de&&n.append(`category`,de);let r=await fetch(`/admin/api/storage/upload`,{method:`POST`,body:n}),a=await r.json();if(!r.ok)throw Error(a.error||`Failed to ingest PDF`);ee(!1),oe(null),ie(null);let o=a.chunks_indexed??0;t.success(`PDF uploaded and indexed (${o} chunks)`),_e(i),e&&e()}catch(e){t.error(`PDF ingestion error: ${e.message}`)}finally{me(!1)}}},Te=()=>{ee(!1),oe(null),ie(null)},Ee=e=>{y(e);let t=i?`${i}/${e.name}`:e.name;if(d(t),e.name.toLowerCase().endsWith(`.pdf`)||e.type===`application/pdf`){_(``),Ce(e,t,m,f);return}let n=new FileReader;n.onload=e=>{typeof e.target?.result==`string`&&_(e.target.result)},n.readAsText(e)},De=async n=>{if(n.preventDefault(),!u.trim()){t.error(`File path is required`);return}if(v&&v.name.toLowerCase().endsWith(`.pdf`)){await Ce(v,u.trim(),m.trim(),f.trim());return}C(!0);try{let n;if(v&&!g){let e=new FormData;e.append(`file`,v),e.append(`path`,u.trim()),e.append(`repo`,m.trim()||`local_storage`),f.trim()&&e.append(`category`,f.trim()),n=await fetch(`/admin/api/storage/upload`,{method:`POST`,body:e})}else n=await fetch(`/admin/api/storage/upload`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:u.trim(),content:g,repo:m.trim()||`local_storage`,category:f.trim()||null})});let r=await n.json();if(!n.ok)throw Error(r.error||`Failed to upload file`);l(!1);let a=r.chunks_indexed??0;t.success(`File uploaded and indexed (${a} chunks)`),_e(i),e&&e()}catch(e){t.error(`Upload error: ${e.message}`)}finally{C(!1)}},Oe=async e=>{k(!0),T(!0);try{let t=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(e.rel_path)}`),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to read file`);D(n)}catch(e){t.error(`Preview error: ${e.message}`),T(!1)}finally{k(!1)}},ke=async e=>{if(N(e),L(``),j(!0),e.rel_path.toLowerCase().endsWith(`.pdf`)){F(``);return}try{let t=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(e.rel_path)}`),n=await t.json();t.ok&&n.content!==void 0?F(n.content):F(``)}catch{F(``)}},Ae=async n=>{if(n.preventDefault(),M){if(M.rel_path.toLowerCase().endsWith(`.pdf`)){t.error(`PDF files cannot be edited directly via text editor. Upload a new PDF file instead.`);return}z(!0);try{let n=await fetch(`/admin/api/storage/file`,{method:`PUT`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:M.rel_path,content:P,repo:`local_storage`,category:I.trim()||``})}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to update file`);j(!1);let a=r.chunks_indexed??0;t.success(`File updated and indexed (${a} chunks)`),_e(i),e&&e()}catch(e){t.error(`Replace error: ${e.message}`)}finally{z(!1)}}},je=async n=>{if(window.confirm(`Are you sure you want to delete '${n.name}' from local storage and purge its vector embeddings?`))try{let r=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(n.rel_path)}`,{method:`DELETE`}),a=await r.json();if(!r.ok)throw Error(a.error||`Failed to delete file`);t.success(`File deleted successfully: ${n.name}`),_e(i),e&&e()}catch(e){t.error(`Delete error: ${e.message}`)}},Me=i?i.split(`/`).filter(Boolean):[];return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),` Local Storage Explorer`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Upload, browse, inspect, replace, and delete managed documents in ContextCortex local storage with real-time vector indexing.`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`10px`},children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>_e(i),title:`Refresh directory`,disabled:o,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate ${o?`fa-spin`:``}`}),` Refresh`]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>be(),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-upload`}),` Upload File`]})]})]}),(0,H.jsxs)(`div`,{className:`browser-breadcrumbs`,style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`10px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,flexWrap:`wrap`},children:[(0,H.jsx)(`span`,{className:`label`,style:{fontWeight:600},children:`Location:`}),(0,H.jsxs)(`button`,{className:`btn-icon`,style:{padding:`2px 6px`,fontSize:`0.85rem`,color:i===``?`var(--primary)`:`var(--text)`},onClick:()=>ve(``),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-house`}),` root`]}),Me.map((e,t)=>{let n=Me.slice(0,t+1).join(`/`),r=t===Me.length-1;return(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`/`}),(0,H.jsx)(`button`,{className:`btn-icon`,style:{padding:`2px 6px`,fontSize:`0.85rem`,fontWeight:r?`bold`:`normal`,color:r?`var(--primary)`:`var(--text)`},onClick:()=>ve(n),children:e})]},n)})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,fontSize:`0.8rem`,color:`var(--text-muted)`},children:[(0,H.jsxs)(`span`,{children:[`Directories: `,(0,H.jsx)(`strong`,{children:n?.directories.length||0})]}),(0,H.jsx)(`span`,{children:`•`}),(0,H.jsxs)(`span`,{children:[`Files: `,(0,H.jsx)(`strong`,{children:n?.files.length||0})]})]})]}),i!==``&&(0,H.jsx)(`div`,{style:{marginTop:`8px`,marginBottom:`8px`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:ye,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-level-up-alt`}),` .. (Parent Directory)`]})}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{style:{width:`40%`},children:`Name`}),(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Size`}),(0,H.jsx)(`th`,{children:`Modified`}),(0,H.jsx)(`th`,{style:{textAlign:`right`},children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:!n||n.directories.length===0&&n.files.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:5,className:`empty-state`,children:`No files or subdirectories found in this storage directory. Click "Upload File" to add documents.`})}):(0,H.jsxs)(H.Fragment,{children:[n.directories.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{className:`btn-icon`,style:{display:`inline-flex`,alignItems:`center`,gap:`8px`,textAlign:`left`,color:`var(--text)`},onClick:()=>ve(e.rel_path),"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`,fontSize:`1.05rem`}}),(0,H.jsx)(`strong`,{children:e.name})]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.rel_path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{style:{textAlign:`right`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>ve(e.rel_path),title:`Open ${e.name}`,"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Open`]})})]},e.rel_path)),n.files.map(e=>{let t=e.name.toLowerCase().endsWith(`.pdf`);return(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[t?(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`,fontSize:`1.05rem`}}):(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{color:`var(--primary)`,fontSize:`1.05rem`}}),(0,H.jsx)(`span`,{children:e.name})]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.rel_path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:he(e.size_bytes)})}),(0,H.jsx)(`td`,{style:{fontSize:`0.85rem`},children:ge(e.mtime)}),(0,H.jsx)(`td`,{style:{textAlign:`right`},children:(0,H.jsxs)(`div`,{style:{display:`inline-flex`,gap:`6px`},children:[(0,H.jsx)(`button`,{className:`btn-icon`,onClick:()=>Oe(e),title:`Preview File`,"aria-label":`Preview File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-eye`})}),(0,H.jsx)(`button`,{className:`btn-icon`,onClick:()=>ke(e),title:`Replace File`,"aria-label":`Replace File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`})}),(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>je(e),title:`Delete File`,"aria-label":`Delete File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})]})})]},e.rel_path)})]})})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:!n||n.directories.length===0&&n.files.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No files or subdirectories found.`}):(0,H.jsxs)(H.Fragment,{children:[n.directories.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`}}),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`span`,{className:`badge badge-warning`,children:`Directory`})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-body`,children:(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.rel_path})]})}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>ve(e.rel_path),"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Open Folder`]})})]},`m-${e.rel_path}`)),n.files.map(e=>{let t=e.name.toLowerCase().endsWith(`.pdf`);return(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[t?(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`}}):(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{color:`var(--primary)`}}),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:he(e.size_bytes)})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.rel_path})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Modified: `}),(0,H.jsx)(`span`,{children:ge(e.mtime)})]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-actions`,children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>Oe(e),title:`Preview File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-eye`}),` Preview`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>ke(e),title:`Replace File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`}),` Replace`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>je(e),title:`Delete File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})]})]},`m-${e.rel_path}`)})]})})]}),c&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`640px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-cloud-arrow-up`}),` Upload to Local Storage`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>l(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:De,children:[(0,H.jsxs)(`div`,{style:{border:b?`2px dashed var(--primary)`:`2px dashed rgba(255, 255, 255, 0.15)`,borderRadius:`8px`,padding:`20px`,textAlign:`center`,background:b?`rgba(59, 130, 246, 0.08)`:`rgba(0, 0, 0, 0.15)`,marginBottom:`16px`,cursor:`pointer`,transition:`all 0.2s ease`},onDragOver:e=>{e.preventDefault(),x(!0)},onDragLeave:()=>x(!1),onDrop:xe,onClick:()=>document.getElementById(`storage-file-input`)?.click(),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-arrow-up`,style:{fontSize:`2rem`,color:`var(--primary)`,marginBottom:`8px`}}),(0,H.jsx)(`p`,{style:{margin:`4px 0`,fontSize:`0.9rem`},children:v?`Selected: ${v.name} (${he(v.size)})`:`Drag & drop a file here, or click to browse`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`},children:`Supports Markdown, code, JSON, YAML, plain text, PDF (up to 50MB)`}),te&&(0,H.jsxs)(`div`,{style:{marginTop:`8px`,fontSize:`0.85rem`,color:`var(--primary)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`6px`}}),`Extracting and analyzing PDF preview...`]}),(0,H.jsx)(`input`,{id:`storage-file-input`,type:`file`,accept:`.md,.markdown,.txt,.json,.yaml,.yml,.sql,.html,.css,.pdf`,style:{display:`none`},onChange:Se})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:2},children:[(0,H.jsx)(`label`,{htmlFor:`upload-path`,children:`Relative File Path (e.g. docs/guide.md)`}),(0,H.jsx)(`input`,{id:`upload-path`,type:`text`,required:!0,placeholder:`folder/document.md`,value:u,onChange:e=>d(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsx)(`label`,{htmlFor:`upload-category`,children:`Category Override`}),(0,H.jsx)(`input`,{id:`upload-category`,type:`text`,placeholder:`Optional category`,value:f,onChange:e=>p(e.target.value)})]})]}),v?.name.toLowerCase().endsWith(`.pdf`)||v?.type===`application/pdf`||u.trim().toLowerCase().endsWith(`.pdf`)?(0,H.jsxs)(`div`,{className:`alert alert-info`,style:{margin:`12px 0`,padding:`12px`,background:`rgba(59, 130, 246, 0.1)`,border:`1px solid var(--primary)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf`,style:{color:`#ef4444`,marginRight:`8px`}}),(0,H.jsx)(`strong`,{children:`PDF Document Selected:`}),` Binary PDF content cannot be edited manually as text. Extracted text, page segmentation, and vector chunks will be previewed in the extraction modal before ingestion.`]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`upload-content`,children:`File Content (Optional if file uploaded directly)`}),(0,H.jsx)(`textarea`,{id:`upload-content`,rows:8,placeholder:`# Enter or paste text content here...`,value:g,onChange:e=>_(e.target.value),style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`}})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>l(!1),children:`Cancel`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:S,children:[(0,H.jsx)(`i`,{className:`fa-solid ${S?`fa-spinner fa-spin`:`fa-upload`}`}),` Upload & Index`]})]})]})]})}),w&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`750px`,maxHeight:`90vh`,display:`flex`,flexDirection:`column`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`}),` File Preview: `,E?.rel_path||`Loading...`]}),E&&(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[`Size: `,he(E.size_bytes),` • Modified: `,ge(E.mtime)]})]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>T(!1),children:`×`})]}),(0,H.jsx)(`div`,{style:{flex:1,overflowY:`auto`,margin:`10px 0`},children:O?(0,H.jsxs)(`div`,{className:`empty-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Loading content...`]}):(0,H.jsx)(`pre`,{className:`search-hit-code`,style:{maxHeight:`420px`,overflowY:`auto`,margin:0,whiteSpace:`pre-wrap`},children:E?.content||`Empty file.`})}),(0,H.jsx)(`div`,{className:`modal-footer`,children:(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>T(!1),children:`Close`})})]})}),A&&M&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`680px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`}),` Replace File: `,M.name]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>j(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:Ae,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Target File Path`}),(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:M.rel_path})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`replace-category`,children:`Category Override`}),(0,H.jsx)(`input`,{id:`replace-category`,type:`text`,placeholder:`Optional category`,value:I,onChange:e=>L(e.target.value)})]}),M.rel_path.toLowerCase().endsWith(`.pdf`)?(0,H.jsxs)(`div`,{className:`alert alert-warning`,style:{margin:`14px 0`,padding:`12px`,background:`rgba(245, 158, 11, 0.1)`,border:`1px solid rgba(245, 158, 11, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{marginRight:`8px`,color:`#f59e0b`}}),(0,H.jsx)(`strong`,{children:`PDF Replacement:`}),` PDF documents contain binary page streams and cannot be edited as plain text. To replace this document, please upload a new `,(0,H.jsx)(`code`,{children:`.pdf`}),` file using the "Upload File" tool.`]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`replace-content`,children:`File Content`}),(0,H.jsx)(`textarea`,{id:`replace-content`,rows:10,required:!0,placeholder:`Updated file text...`,value:P,onChange:e=>F(e.target.value),style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`}})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>j(!1),children:`Cancel`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:R||M.rel_path.toLowerCase().endsWith(`.pdf`),children:[(0,H.jsx)(`i`,{className:`fa-solid ${R?`fa-spinner fa-spin`:`fa-save`}`}),` Save & Re-Index`]})]})]})]})}),B&&re&&(0,H.jsx)(ot,{data:re,onConfirm:we,onCancel:Te,isIngesting:pe})]})}function ct({refreshStats:e}){let[t,n]=(0,V.useState)(`local-paths`);return(0,H.jsxs)(`div`,{className:`files-storage-page`,children:[(0,H.jsxs)(`div`,{className:`files-storage-header`,children:[(0,H.jsxs)(`h2`,{className:`page-title`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{marginRight:`10px`}}),`Files & Storage`]}),(0,H.jsxs)(`div`,{className:`files-storage-section-tabs`,children:[(0,H.jsxs)(`button`,{className:`section-tab ${t===`local-paths`?`active`:``}`,onClick:()=>n(`local-paths`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),(0,H.jsx)(`span`,{children:`Local Paths`})]}),(0,H.jsxs)(`button`,{className:`section-tab ${t===`local-storage`?`active`:``}`,onClick:()=>n(`local-storage`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),(0,H.jsx)(`span`,{children:`Local Storage`})]})]})]}),(0,H.jsxs)(`div`,{className:`files-storage-content`,children:[t===`local-paths`&&(0,H.jsx)(at,{refreshStats:e}),t===`local-storage`&&(0,H.jsx)(st,{refreshStats:e})]})]})}function lt(e){switch(e.toUpperCase()){case`GET`:return`method-get`;case`POST`:return`method-post`;case`PUT`:return`method-put`;case`DELETE`:return`method-delete`;case`PATCH`:return`method-patch`;default:return`method-other`}}function ut(e){switch(e.toLowerCase()){case`class`:return`kind-class`;case`function`:case`method`:case`async function`:return`kind-function`;case`variable`:case`constant`:return`kind-variable`;case`interface`:case`type`:return`kind-type`;default:return`kind-default`}}var dt=({outline:e,selectedSymbolId:t,onSelectSymbol:n,onReadDoc:r,density:i=`balanced`,loading:a=!1})=>{let[o,s]=(0,V.useState)(`all`),[c,l]=(0,V.useState)(``),u=(0,V.useMemo)(()=>e?.symbols||[],[e?.symbols]),d=(0,V.useMemo)(()=>{let e=0,t=0,n=0;for(let r of u){r.route&&e++;let i=r.kind.toLowerCase();i===`class`||i===`interface`?t++:(i.includes(`func`)||i===`method`)&&(r.route||n++)}return{all:u.length,routes:e,classes:t,functions:n}},[u]),f=(0,V.useMemo)(()=>u.filter(e=>{if(o===`routes`){if(!e.route)return!1}else if(o===`classes`){let t=e.kind.toLowerCase();if(t!==`class`&&t!==`interface`)return!1}else if(o===`functions`){let t=e.kind.toLowerCase();if(!t.includes(`func`)&&t!==`method`||e.route)return!1}if(c.trim()){let t=c.toLowerCase(),n=e.name.toLowerCase().includes(t),r=(e.signature||``).toLowerCase().includes(t),i=e.route?e.route.path_pattern.toLowerCase().includes(t)||e.route.http_method.toLowerCase().includes(t):!1;if(!n&&!r&&!i)return!1}return!0}),[u,o,c]),p=e?.filepath?e.filepath.split(`/`).pop():``;return(0,H.jsxs)(`div`,{className:`nav-outline-pane density-${i}`,"data-testid":`navigator-outline-container`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-header`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-title-row`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-title`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`8`,y1:`6`,x2:`21`,y2:`6`}),(0,H.jsx)(`line`,{x1:`8`,y1:`12`,x2:`21`,y2:`12`}),(0,H.jsx)(`line`,{x1:`8`,y1:`18`,x2:`21`,y2:`18`}),(0,H.jsx)(`line`,{x1:`3`,y1:`6`,x2:`3.01`,y2:`6`}),(0,H.jsx)(`line`,{x1:`3`,y1:`12`,x2:`3.01`,y2:`12`}),(0,H.jsx)(`line`,{x1:`3`,y1:`18`,x2:`3.01`,y2:`18`})]}),(0,H.jsx)(`span`,{children:`Symbols & Routes`})]}),e&&(0,H.jsx)(`div`,{className:`nav-file-badge`,title:e.filepath,children:(0,H.jsx)(`span`,{className:`file-name`,children:p})})]}),e&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`nav-outline-search-bar`,children:[(0,H.jsx)(`span`,{className:`search-icon-wrapper`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{className:`search-icon`,width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]})}),(0,H.jsx)(`input`,{type:`text`,className:`nav-outline-search-input`,placeholder:`Filter symbols...`,value:c,onChange:e=>l(e.target.value)}),c&&(0,H.jsx)(`button`,{type:`button`,className:`nav-outline-clear-btn`,onClick:()=>l(``),"aria-label":`Clear symbol search`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-category-chips`,role:`tablist`,"aria-label":`Symbol Category Filter`,children:[(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`all`?`active`:``}`,onClick:()=>s(`all`),children:[`All `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.all})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`routes`?`active`:``}`,onClick:()=>s(`routes`),children:[`Routes `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.routes})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`classes`?`active`:``}`,onClick:()=>s(`classes`),children:[`Classes `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.classes})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`functions`?`active`:``}`,onClick:()=>s(`functions`),children:[`Functions `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.functions})]})]})]})]}),(0,H.jsx)(`div`,{className:`nav-outline-content`,children:a?(0,H.jsxs)(`div`,{className:`nav-outline-skeleton`,"data-testid":`outline-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`})]}):e?u.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state doc-file-state`,"data-testid":`outline-doc-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsxs)(`svg`,{width:`28`,height:`28`,viewBox:`0 0 24 24`,fill:`none`,stroke:`var(--primary)`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`}),(0,H.jsx)(`polyline`,{points:`10 9 9 9 8 9`})]})}),(0,H.jsx)(`h4`,{children:`Document File Active`}),(0,H.jsx)(`p`,{style:{fontSize:`0.82rem`,color:`var(--text-muted)`,margin:`6px 0 14px`},children:`Full document is loaded in the main viewer.`}),r&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-sm btn-primary read-doc-action-btn`,onClick:r,style:{padding:`6px 14px`,fontSize:`0.8rem`,display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z`}),(0,H.jsx)(`path`,{d:`M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z`})]}),(0,H.jsx)(`span`,{children:`Read Full Document`})]})]}):f.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`h4`,{children:`No Matching Symbols`}),(0,H.jsx)(`p`,{children:`No symbols match the current category and search filters.`}),(0,H.jsx)(`button`,{type:`button`,className:`nav-clear-filter-btn`,onClick:()=>{s(`all`),l(``)},children:`Reset Filters`})]}):(0,H.jsx)(`div`,{className:`nav-symbol-list`,role:`list`,children:f.map(e=>{let r=e.id===t,i=ut(e.kind);return(0,H.jsxs)(`div`,{"data-testid":`symbol-item-${e.id}`,className:`nav-symbol-item ${r?`active`:``}`,onClick:()=>n(e),role:`listitem`,tabIndex:0,onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),n(e))},children:[(0,H.jsxs)(`div`,{className:`symbol-header-row`,children:[(0,H.jsxs)(`div`,{className:`symbol-name-col`,children:[(0,H.jsx)(`span`,{className:`symbol-kind-badge ${i}`,children:e.kind}),(0,H.jsx)(`span`,{className:`symbol-name-text`,title:e.full_symbol||e.name,children:e.name})]}),(0,H.jsx)(`div`,{className:`symbol-meta-col`,children:(0,H.jsxs)(`span`,{className:`symbol-line-badge`,children:[`L`,e.start_line,e.end_line&&e.end_line!==e.start_line?` - L${e.end_line}`:``]})})]}),e.route&&(0,H.jsxs)(`div`,{className:`symbol-route-row`,children:[(0,H.jsx)(`span`,{className:`route-method-badge ${lt(e.route.http_method)}`,children:e.route.http_method}),(0,H.jsx)(`span`,{className:`route-path-text`,title:e.route.path_pattern,children:e.route.path_pattern}),e.route.framework&&(0,H.jsx)(`span`,{className:`route-framework-tag`,children:e.route.framework})]}),e.signature&&(0,H.jsx)(`div`,{className:`symbol-signature-snippet`,children:(0,H.jsx)(`code`,{children:e.signature})})]},e.id)})}):(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`svg`,{width:`28`,height:`28`,viewBox:`0 0 24 24`,fill:`none`,stroke:`var(--text-muted)`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`})})}),(0,H.jsx)(`h4`,{children:`No File Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to inspect its symbols and routes.`})]})})]})};function ft(e){if(!e)return``;let t=e.toLowerCase();return t.includes(`class`)?`class`:t.includes(`method`)?`method`:t.includes(`func`)?`func`:t.includes(`interface`)?`interface`:t.includes(`struct`)?`struct`:t.includes(`enum`)?`enum`:t.includes(`module`)?`module`:e.replace(/_declaration|_item/g,``)}function pt({onOpenInNavigator:e}={}){let t=Je(),[n,r]=(0,V.useState)(``),[i,a]=(0,V.useState)(`code`),[o,s]=(0,V.useState)(``),[c,l]=(0,V.useState)(5),[u,d]=(0,V.useState)(`hybrid`),[f,p]=(0,V.useState)(.5),[m,h]=(0,V.useState)([]),[g,_]=(0,V.useState)(!1),[v,y]=(0,V.useState)(null),[b,x]=(0,V.useState)(null),[S,C]=(0,V.useState)(null);(0,V.useEffect)(()=>{(async()=>{try{let e=await fetch(`/admin/api/repos`);if(e.ok){let t=await e.json();Array.isArray(t)&&h(t.map(e=>typeof e==`string`?e:e.name).filter(Boolean))}}catch(e){console.error(`Failed to load repositories list:`,e)}})()},[]);let w=async e=>{if(e&&e.preventDefault(),n.trim()){_(!0),x(null),y(null);try{let e={query:n.trim(),type:i,repo:o.trim()||null,limit:c,search_mode:u,dense_weight:u===`hybrid`?f:+(u===`semantic`)},t=await fetch(`/admin/api/search/test`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await t.json();if(!t.ok)throw Error(r.error||`Search failed`);y(r.results||[])}catch(e){x(e.message),t.error(`Search failed: `+e.message)}finally{_(!1)}}},T=async(e,n)=>{try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(n),C(e),setTimeout(()=>C(null),2e3))}catch{t.error(`Failed to copy to clipboard`)}};return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Live Hybrid Search Inspector`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Test hybrid, semantic, and lexical search results with configurable scoring calibration and AST context.`}),(0,H.jsx)(`div`,{style:{marginTop:`16px`},children:(0,H.jsxs)(`div`,{className:`search-mode-segmented`,role:`group`,"aria-label":`Search Mode`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`hybrid`?`active`:``}`,onClick:()=>d(`hybrid`),"data-testid":`mode-hybrid-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-merge`}),` Hybrid Fusion`]}),(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`semantic`?`active`:``}`,onClick:()=>d(`semantic`),"data-testid":`mode-semantic-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-brain`}),` Semantic (Dense)`]}),(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`lexical`?`active`:``}`,onClick:()=>d(`lexical`),"data-testid":`mode-lexical-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-font`}),` Lexical (BM25)`]})]})}),u===`hybrid`&&(0,H.jsxs)(`div`,{className:`hybrid-slider-container`,children:[(0,H.jsxs)(`div`,{className:`hybrid-slider-header`,children:[(0,H.jsx)(`span`,{children:(0,H.jsx)(`strong`,{children:`Hybrid Scoring Split:`})}),(0,H.jsxs)(`span`,{className:`hybrid-split-value`,children:[`Semantic: `,Math.round(f*100),`% / Lexical: `,Math.round((1-f)*100),`%`]})]}),(0,H.jsx)(`input`,{type:`range`,min:`0`,max:`1`,step:`0.05`,value:f,onChange:e=>p(parseFloat(e.target.value)),className:`hybrid-range-input`,"aria-label":`Hybrid dense weight slider`}),(0,H.jsxs)(`div`,{className:`hybrid-presets`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.5?`active`:``}`,onClick:()=>p(.5),children:`Balanced (50/50)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.7?`active`:``}`,onClick:()=>p(.7),children:`Semantic Bias (70/30)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.3?`active`:``}`,onClick:()=>p(.3),children:`Keyword Bias (30/70)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===1?`active`:``}`,onClick:()=>p(1),children:`Pure Semantic (100/0)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===0?`active`:``}`,onClick:()=>p(0),children:`Pure Keyword (0/100)`})]})]}),(0,H.jsx)(`form`,{onSubmit:w,style:{marginTop:`14px`},children:(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:2},children:[(0,H.jsx)(`label`,{children:`Search Query`}),(0,H.jsx)(`input`,{type:`text`,required:!0,placeholder:`e.g. JWT token authentication or chunk_markdown`,value:n,onChange:e=>r(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Target Type`}),(0,H.jsxs)(`select`,{"aria-label":`Target Type`,value:i,onChange:e=>a(e.target.value),children:[(0,H.jsx)(`option`,{value:`code`,children:`Code Snippets & Symbols`}),(0,H.jsx)(`option`,{value:`doc`,children:`Documentation & Notes`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Repo Filter`}),(0,H.jsx)(`input`,{type:`text`,list:`search-inspector-repos`,placeholder:`All Repos`,value:o,onChange:e=>s(e.target.value)}),(0,H.jsxs)(`datalist`,{id:`search-inspector-repos`,children:[(0,H.jsx)(`option`,{value:``,children:`All Repos`}),m.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e))]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{maxWidth:`110px`},children:[(0,H.jsx)(`label`,{children:`Limit`}),(0,H.jsxs)(`select`,{"aria-label":`Result Limit`,value:c,onChange:e=>l(Number(e.target.value)),children:[(0,H.jsx)(`option`,{value:5,children:`Top 5`}),(0,H.jsx)(`option`,{value:10,children:`Top 10`}),(0,H.jsx)(`option`,{value:25,children:`Top 25`})]})]}),(0,H.jsx)(`div`,{className:`form-group search-form-btn-group`,style:{alignSelf:`flex-end`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:g,children:g?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{className:`nav-svg-spinner animate-spin`,"data-testid":`search-inspector-spinner`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,style:{marginRight:`6px`,verticalAlign:`middle`,display:`inline-block`},children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(255,255,255,0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`currentColor`,strokeWidth:`3`,strokeLinecap:`round`})]}),`Searching...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`currentColor`,style:{marginRight:`6px`,verticalAlign:`middle`},children:(0,H.jsx)(`polygon`,{points:`5 3 19 12 5 21 5 3`})}),`Search`]})})})]})}),(0,H.jsxs)(`div`,{style:{marginTop:`20px`},children:[g&&(0,H.jsx)(`div`,{className:`empty-state`,children:`Running hybrid retrieval with Normalized Weighted Fusion...`}),b&&(0,H.jsxs)(`div`,{className:`empty-state`,style:{color:`var(--danger)`},children:[`Search error: `,b]}),!g&&!b&&v===null&&(0,H.jsx)(`div`,{className:`empty-state`,children:`Enter a query above to test hybrid retrieval.`}),!g&&!b&&v!==null&&v.length===0&&(0,H.jsx)(`div`,{className:`empty-state`,children:`No matching results found in index.`}),!g&&!b&&v!==null&&v.length>0&&v.map((t,n)=>{let r=t.payload,i=t.dense_score!==void 0&&t.dense_score!==null,a=t.sparse_score!==void 0&&t.sparse_score!==null,o=ft(r.kind);return(0,H.jsxs)(`div`,{className:`search-hit-card`,children:[(0,H.jsxs)(`div`,{className:`search-hit-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:`6px`},children:[(0,H.jsx)(`span`,{className:`badge badge-primary`,children:r.repo}),(0,H.jsx)(`strong`,{children:r.rel_path}),o&&(0,H.jsx)(`span`,{className:`badge ${ut(o)}`,children:o}),r.symbol&&(0,H.jsx)(`span`,{className:`badge badge-accent`,children:r.full_symbol||r.symbol}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[`(Lines `,r.start_line,`-`,r.end_line,`)`]}),r.github_url&&(()=>{let e=``;try{e=new URL(r.github_url).hostname.toLowerCase()}catch{}let t=r.github_url.toLowerCase(),n=`View Source`,i=`fa-solid fa-code-branch`;return e===`gitlab.com`||e.endsWith(`.gitlab.com`)||t.includes(`/-/blob/`)?(n=`View on GitLab`,i=`fa-brands fa-gitlab`):e.includes(`gitea`)||e.includes(`forgejo`)?(n=`View on Gitea`,i=`fa-solid fa-mug-hot`):e===`bitbucket.org`||e.endsWith(`.bitbucket.org`)?(n=`View on Bitbucket`,i=`fa-brands fa-bitbucket`):(e===`github.com`||e.endsWith(`.github.com`))&&(n=`View on GitHub`,i=`fa-brands fa-github`),(0,H.jsxs)(`a`,{href:r.github_url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,fontSize:`0.8rem`},children:[(0,H.jsx)(`i`,{className:i,style:{marginRight:`4px`}}),n]})})()]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:`8px`},children:[(0,H.jsxs)(`span`,{className:`badge badge-success`,title:`Overall relevance score`,children:[`Score: `,(t.score*100).toFixed(1),`% (`,t.score.toFixed(4),`)`]}),i&&(0,H.jsxs)(`span`,{className:`badge badge-info`,title:`Dense semantic vector similarity`,children:[`Semantic: `,((t.dense_score||0)*100).toFixed(1),`%`]}),a&&(0,H.jsxs)(`span`,{className:`badge badge-warning`,title:`Sparse lexical BM25 similarity`,children:[`Lexical: `,((t.sparse_score||0)*100).toFixed(1),`%`]}),(0,H.jsxs)(`div`,{className:`search-hit-actions`,children:[e&&r.rel_path&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-xs`,onClick:()=>e(r.repo,r.rel_path,r.ast_symbol_id,r.start_line,r.end_line),title:`Open in Code Navigator`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`,fontSize:`0.75rem`,padding:`2px 8px`},children:[(0,H.jsxs)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`}),(0,H.jsx)(`polyline`,{points:`15 3 21 3 21 9`}),(0,H.jsx)(`line`,{x1:`10`,y1:`14`,x2:`21`,y2:`3`})]}),`Open in Navigator`]}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary btn-xs`,onClick:()=>T(n,r.content),title:`Copy snippet`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`,fontSize:`0.75rem`,padding:`2px 8px`},children:S===n?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2.5`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),`Copied`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`rect`,{x:`9`,y:`9`,width:`13`,height:`13`,rx:`2`,ry:`2`}),(0,H.jsx)(`path`,{d:`M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1`})]}),`Copy`]})})]})]})]}),r.signature&&(0,H.jsxs)(`div`,{className:`search-hit-signature`,children:[(0,H.jsx)(`span`,{style:{opacity:.7,marginRight:`6px`},children:`Signature:`}),(0,H.jsx)(`code`,{children:r.signature})]}),(0,H.jsx)(`pre`,{className:`search-hit-code`,children:r.content})]},n)})]})]})})}function mt({vectorStore:e,isLoadingVs:t,testFeedback:n,vsProvider:r,vsMode:i,vsStoragePath:a,setVsStoragePath:o,vsUrl:s,setVsUrl:c,vsCollection:l,setVsCollection:u,isTestingVs:d,isSwitchingVs:f,onProviderChange:p,onModeChange:m,onTestConnection:h,onSwitchBackend:g}){return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`}),` Vector Database Engine`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure and switch between vector database backends (Qdrant & ChromaDB). Switching backends updates system metadata and triggers full re-indexing.`}),(0,H.jsxs)(`div`,{className:`vs-config-layout`,children:[(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-nodes`}),` Active Vector Backend`]}),t&&!e?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading vector store configuration...`}):e?(0,H.jsxs)(`div`,{className:`specs-list`,style:{marginTop:0},children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Provider:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider===`chroma`?`ChromaDB`:`Qdrant`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Operating Mode:`}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.mode===`embedded`?`Embedded Disk`:`Remote Server`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:e.mode===`embedded`?`Storage Path:`:`Server URL:`}),(0,H.jsx)(`code`,{children:e.mode===`embedded`?e.storage_path||`data/qdrant_db`:e.url||`http://localhost:6333`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Collection Name:`}),(0,H.jsx)(`code`,{children:e.collection||`knowledge_rag_v1`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Points Count:`}),(0,H.jsx)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:(e.points_count||0).toLocaleString()})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Health Status:`}),e.healthy?(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`}),` Healthy`]}):(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.health_message||`Unhealthy`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`}),` `,e.health_message?e.health_message.length>35?e.health_message.slice(0,35)+`...`:e.health_message:`Unhealthy`]})]})]}):(0,H.jsx)(`p`,{className:`text-muted`,children:`No vector store configuration found.`})]}),(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-sliders`}),` Configure & Switch Backend`]}),n&&(0,H.jsxs)(`div`,{className:`vs-feedback-banner ${n.success?`feedback-success`:`feedback-error`}`,children:[(0,H.jsx)(`i`,{className:n.success?`fa-solid fa-circle-check`:`fa-solid fa-circle-exclamation`}),(0,H.jsx)(`span`,{children:n.message})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),g()},children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-provider`,children:`Vector Store Provider`}),(0,H.jsxs)(`select`,{id:`vs-provider`,value:r,onChange:e=>p(e.target.value),children:[(0,H.jsx)(`option`,{value:`qdrant`,children:`Qdrant (Hybrid Dense + BM25)`}),(0,H.jsx)(`option`,{value:`chroma`,children:`ChromaDB (Dense Vectors)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-mode`,children:`Operating Mode`}),(0,H.jsxs)(`select`,{id:`vs-mode`,value:i,onChange:e=>m(e.target.value),children:[(0,H.jsx)(`option`,{value:`embedded`,children:`Embedded Disk Storage`}),(0,H.jsx)(`option`,{value:`remote`,children:`Remote Server URL`})]})]})]}),i===`embedded`?(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-storage-path`,children:`Storage Directory Path`}),(0,H.jsx)(`input`,{id:`vs-storage-path`,type:`text`,value:a,onChange:e=>o(e.target.value),placeholder:r===`chroma`?`data/chroma_db`:`data/qdrant_db`})]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-url`,children:`Remote Server URL`}),(0,H.jsx)(`input`,{id:`vs-url`,type:`text`,value:s,onChange:e=>c(e.target.value),placeholder:r===`chroma`?`http://localhost:8000`:`http://localhost:6333`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-collection`,children:`Collection Name`}),(0,H.jsx)(`input`,{id:`vs-collection`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`knowledge_rag_v1`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`16px`,flexWrap:`wrap`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:h,disabled:d||f,children:d?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Testing Connection...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plug`}),` Test Connection`]})}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-primary`,onClick:g,disabled:d||f,children:f?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Switching Backend...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Save & Switch Backend`]})})]})]})]})]})]})}function ht({embeddingConfig:e,isLoadingEmb:t,isSavingEmb:n,embProvider:r,setEmbProvider:i,embThreads:a,setEmbThreads:o,embBatchSize:s,setEmbBatchSize:c,embDenseModel:l,setEmbDenseModel:u,embSparseModel:d,setEmbSparseModel:f,embLitellmUrl:p,setEmbLitellmUrl:m,embLitellmApiKey:h=``,setEmbLitellmApiKey:g,embVisionOcrModel:_=`gemini-2.5-flash`,setEmbVisionOcrModel:v,embChatModel:y=`gemini-2.5-flash`,setEmbChatModel:b,discoveryResult:x=null,isDiscovering:S=!1,onDiscoverModels:C,onSaveEmbeddingSettings:w}){let T=e?.system_cpus||2,E=e?.system_memory_gb||4,[D,O]=(0,V.useState)(!1),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),N=x?.embedding_models||[],P=x?.vision_models||[],F=x?.chat_models||[];return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-microchip`}),` Embedding Engine & Resource Limits`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure local FastEmbed (ONNX) resource limits, CPU thread concurrency, or remote LiteLLM endpoints with dynamic model discovery for embeddings, Vision AI OCR, and chat synthesis.`}),(0,H.jsxs)(`div`,{className:`vs-config-layout`,children:[(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-gauge-high`}),` Active Embedding Engine`]}),t&&!e?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading embedding configuration...`}):e?(0,H.jsxs)(`div`,{className:`specs-list`,style:{marginTop:0},children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Execution Provider:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider===`api`?`Remote API (LiteLLM)`:`Local FastEmbed (ONNX)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`CPU Threads Allocation:`}),(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[e.threads,` `,e.threads===1?`Core`:`Cores`,` (of `,T,` detected)`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Batch Processing Size:`}),(0,H.jsxs)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:[e.batch_size,` chunks/batch`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`System RAM Capacity:`}),(0,H.jsxs)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:[E,` GB`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Dense Model:`}),(0,H.jsx)(`code`,{children:e.dense_model||`BAAI/bge-small-en-v1.5`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Sparse Model (BM25):`}),(0,H.jsx)(`code`,{children:e.sparse_model||`Qdrant/bm25`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Vision AI OCR Model:`}),(0,H.jsx)(`code`,{children:e.vision_ocr_model||`gemini-2.5-flash`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Chat Completion Model:`}),(0,H.jsx)(`code`,{children:e.chat_model||`gemini-2.5-flash`})]}),e.provider===`api`&&(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`API Endpoint URL:`}),(0,H.jsx)(`code`,{children:e.litellm_url||`http://litellm:4000/v1`})]})]}):(0,H.jsx)(`p`,{className:`text-muted`,children:`No embedding configuration found.`})]}),(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-sliders`}),` Configure Models & Resources`]}),(0,H.jsxs)(`form`,{onSubmit:w,children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-provider`,children:`Embedding Provider`}),(0,H.jsxs)(`select`,{id:`emb-provider`,value:r,onChange:e=>i(e.target.value),children:[(0,H.jsx)(`option`,{value:`local`,children:`Local Model (FastEmbed / ONNX Runtime)`}),(0,H.jsx)(`option`,{value:`api`,children:`API Endpoint (LiteLLM / OpenAI Compatible)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-threads`,children:`CPU Thread Cap`}),(0,H.jsx)(`input`,{id:`emb-threads`,type:`number`,min:`1`,max:Math.max(T,128),value:a,onChange:e=>o(Math.max(1,parseInt(e.target.value)||1)),placeholder:`2`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`2px`,display:`block`},children:`Recommended: 2 cores. Prevents container CPU spikes.`})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-batch-size`,children:`Embedding Batch Size`}),(0,H.jsxs)(`select`,{id:`emb-batch-size`,value:s,onChange:e=>c(parseInt(e.target.value)||32),children:[(0,H.jsx)(`option`,{value:`16`,children:`16 chunks (Lowest RAM footprint)`}),(0,H.jsx)(`option`,{value:`32`,children:`32 chunks (Balanced Default)`}),(0,H.jsx)(`option`,{value:`64`,children:`64 chunks (High throughput)`}),(0,H.jsx)(`option`,{value:`128`,children:`128 chunks (Large RAM environments)`}),(0,H.jsx)(`option`,{value:`256`,children:`256 chunks (FastEmbed default)`})]})]}),r===`api`?(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-litellm-url`,children:`API Endpoint URL (LiteLLM)`}),(0,H.jsx)(`input`,{id:`emb-litellm-url`,type:`text`,value:p,onChange:e=>m(e.target.value),placeholder:`http://litellm:4000/v1`})]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-dense-model`,children:`Dense Model Name`}),(0,H.jsx)(`input`,{id:`emb-dense-model`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`BAAI/bge-small-en-v1.5`})]})]}),r===`api`&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-litellm-api-key`,children:`LiteLLM API Key (Optional / Bearer)`}),(0,H.jsx)(`input`,{id:`emb-litellm-api-key`,type:`password`,value:h,onChange:e=>g?.(e.target.value),placeholder:`sk-...`,autoComplete:`off`})]}),(0,H.jsx)(`div`,{className:`form-group`,style:{display:`flex`,flexDirection:`column`,justifyContent:`flex-end`},children:(0,H.jsx)(`button`,{type:`button`,id:`btn-discover-models`,className:`btn btn-secondary`,onClick:C,disabled:S,style:{height:`38px`,whiteSpace:`nowrap`},children:S?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Discovering...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Discover Models`]})})})]}),x&&(0,H.jsx)(`div`,{style:{marginBottom:`16px`},children:x.status===`success`?(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,padding:`8px 12px`,background:`rgba(16, 185, 129, 0.1)`,border:`1px solid rgba(16, 185, 129, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,style:{color:`#10b981`}}),(0,H.jsxs)(`span`,{children:[`Connected to LiteLLM — `,(0,H.jsxs)(`strong`,{children:[x.total_models,` models available`]}),` (`,N.length,` embedding, `,P.length,` vision, `,F.length,` chat)`]})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,padding:`8px 12px`,background:`rgba(239, 68, 68, 0.1)`,border:`1px solid rgba(239, 68, 68, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{color:`#ef4444`}}),(0,H.jsx)(`span`,{children:x.message||`Could not connect to LiteLLM endpoint`})]})}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{htmlFor:`emb-dense-model`,style:{marginBottom:0},children:`Dense Embedding Model`}),N.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>O(!D),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:D?`← Select from discovered`:`Enter custom model →`})]}),!D&&N.length>0?(0,H.jsxs)(`select`,{id:`emb-dense-model`,value:l,onChange:e=>{e.target.value===`__custom__`?O(!0):u(e.target.value)},children:[N.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-dense-model`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`gemini-embedding-2`})]})]}),r===`local`&&(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-sparse-model`,children:`Sparse BM25 Model`}),(0,H.jsx)(`input`,{id:`emb-sparse-model`,type:`text`,value:d,onChange:e=>f(e.target.value),placeholder:`Qdrant/bm25`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsxs)(`label`,{htmlFor:`emb-vision-ocr-model`,style:{marginBottom:0},children:[`Vision AI OCR Model `,(0,H.jsx)(`span`,{className:`text-muted`,style:{fontWeight:400,fontSize:`0.8rem`},children:`(PDF Ingestion Fallback)`})]}),P.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>A(!k),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:k?`← Select from discovered`:`Enter custom model →`})]}),!k&&P.length>0?(0,H.jsxs)(`select`,{id:`emb-vision-ocr-model`,value:_,onChange:e=>{e.target.value===`__custom__`?A(!0):v?.(e.target.value)},children:[P.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-vision-ocr-model`,type:`text`,value:_,onChange:e=>v?.(e.target.value),placeholder:`gemini-2.5-flash`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{htmlFor:`emb-chat-model`,style:{marginBottom:0},children:`General Chat & Synthesis Model`}),F.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>M(!j),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:j?`← Select from discovered`:`Enter custom model →`})]}),!j&&F.length>0?(0,H.jsxs)(`select`,{id:`emb-chat-model`,value:y,onChange:e=>{e.target.value===`__custom__`?M(!0):b?.(e.target.value)},children:[F.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-chat-model`,type:`text`,value:y,onChange:e=>b?.(e.target.value),placeholder:`gemini-2.5-flash`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`16px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:n||t,children:n?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving & Applying...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save & Apply Embedding Limits & Model Settings`]})})})]})]})]})]})}function gt({isLoadingAutoSync:e,intervalMins:t,setIntervalMins:n,hasGlobalSecret:r,showWebhookSecret:i,setShowWebhookSecret:a,webhookSecret:o,setWebhookSecret:s,fullWebhookUrl:c,copiedWebhookUrl:l,isSavingAutoSync:u,onSaveAutoSync:d,onClearWebhookSecret:f,onCopyWebhookUrl:p}){return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Auto-Sync & Webhooks`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure scheduled background repository polling interval and global incoming webhook triggers.`}),e&&!t?(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`12px`},children:`Loading auto-sync settings...`}):(0,H.jsxs)(`form`,{onSubmit:d,style:{marginTop:`16px`},children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-interval`,children:`Repository Polling Interval`}),(0,H.jsxs)(`select`,{id:`auto-sync-interval`,value:t,onChange:e=>n(Number(e.target.value)),style:{width:`100%`},children:[(0,H.jsx)(`option`,{value:0,children:`Disabled (0m)`}),(0,H.jsx)(`option`,{value:5,children:`5 minutes`}),(0,H.jsx)(`option`,{value:15,children:`15 minutes (Default)`}),(0,H.jsx)(`option`,{value:30,children:`30 minutes`}),(0,H.jsx)(`option`,{value:60,children:`1 hour`}),(0,H.jsx)(`option`,{value:360,children:`6 hours`}),![0,5,15,30,60,360].includes(t)&&(0,H.jsxs)(`option`,{value:t,children:[t,` minutes (Custom)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`6px`},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-secret`,style:{marginBottom:0},children:`Global Webhook Secret (HMAC / Token)`}),r?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:`Secret Active`}):(0,H.jsx)(`span`,{className:`badge badge-secondary`,style:{color:`var(--text-muted)`},children:`None`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`input`,{id:`auto-sync-secret`,type:i?`text`:`password`,value:o,onChange:e=>s(e.target.value),placeholder:r?`Secret configured (enter new to change)`:`Enter webhook secret (optional)`,style:{flex:1}}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>a(!i),title:i?`Hide secret`:`Reveal secret`,"aria-label":i?`Hide secret`:`Reveal secret`,style:{minWidth:`42px`,padding:`0 12px`},children:(0,H.jsx)(`i`,{className:`fa-solid ${i?`fa-eye-slash`:`fa-eye`}`})}),(r||o)&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:f,title:`Clear secret`,"aria-label":`Clear secret`,disabled:u,style:{padding:`0 12px`},children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginTop:`14px`,minWidth:0,width:`100%`},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-webhook-url`,children:`Incoming Webhook Payload URL`}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,minWidth:0,width:`100%`},children:[(0,H.jsx)(`input`,{id:`auto-sync-webhook-url`,type:`text`,readOnly:!0,value:c,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`,flex:1,minWidth:0,width:`100%`},"aria-label":`Webhook Payload URL`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:p,style:{minWidth:`95px`},"aria-label":`Copy Webhook URL`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${l?`fa-check`:`fa-copy`}`}),` `,l?`Copied!`:`Copy`]})]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{fontSize:`0.8rem`,marginTop:`6px`},children:`Payload URL for repository push webhooks. Webhooks trigger immediate background synchronization for registered repositories.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`18px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:u,children:u?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save Auto-Sync Settings`]})})})]})]})}function _t({stats:e,ghAuth:t,glAuth:n,gtAuth:r,ghToken:i,setGhToken:a,glToken:o,setGlToken:s,gtToken:c,setGtToken:l,hostCredentials:u,isHostModalOpen:d,setIsHostModalOpen:f,newHost:p,setNewHost:m,newHostProvider:h,setNewHostProvider:g,newHostUser:_,setNewHostUser:v,newHostToken:y,setNewHostToken:b,isSavingHost:x,onSaveToken:S,onClearToken:C,onSaveHostCredential:w,onDeleteHostCredential:T}){return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-key`}),` Global Git Provider Authentication`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Default tokens are automatically applied to repositories matching these providers when no per-repo or host-specific override exists.`}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 300px), 1fr))`,gap:`20px`,marginTop:`20px`},children:[(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github fa-lg`}),` GitHub`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:t.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`8px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:t.masked_token})]}),e?.rate_limit&&(0,H.jsxs)(`div`,{style:{fontSize:`0.78rem`,color:`var(--text-muted)`,marginBottom:`12px`},children:[`Rate Limit: `,e.rate_limit.remaining,` / `,e.rate_limit.limit,` requests`]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`github_token`,i,`GitHub`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`ghp_xxxxxxxxxxxx`,value:i,onChange:e=>a(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`github_token`,`GitHub`),children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab fa-lg`,style:{color:`#fc6d26`}}),` GitLab (Global)`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:n.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`16px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:n.masked_token})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`gitlab_token`,o,`GitLab`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`glpat-xxxxxxxxxxxx`,value:o,onChange:e=>s(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`gitlab_token`,`GitLab`),children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot fa-lg`,style:{color:`#609926`}}),` Gitea / Forgejo`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:r.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`16px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:r.masked_token})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`gitea_token`,c,`Gitea`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`Token / Personal Token`,value:c,onChange:e=>l(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`gitea_token`,`Gitea`),children:`Clear`})]})]})]})]})]}),(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-shield-halved`}),` Custom & Self-Hosted Git Host Vault`]}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:[`Define credentials for self-hosted GitLab Enterprise, Gitea, or custom servers (e.g. `,(0,H.jsx)(`code`,{children:`gitlab.mycorp.com`}),` or `,(0,H.jsx)(`code`,{children:`git.lan:3000`}),`).`]})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>f(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Host Credential`]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,style:{marginTop:`16px`},children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Host Domain / Address`}),(0,H.jsx)(`th`,{children:`Provider Type`}),(0,H.jsx)(`th`,{children:`Auth User`}),(0,H.jsx)(`th`,{children:`Masked Token`}),(0,H.jsx)(`th`,{children:`Added At`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:u.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:6,className:`empty-state`,children:`No custom host credentials configured. Add a host domain to authenticate self-hosted instances.`})}):u.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.host})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider.toUpperCase()})}),(0,H.jsx)(`td`,{children:e.auth_user?(0,H.jsx)(`code`,{children:e.auth_user}):(0,H.jsx)(`span`,{className:`text-muted`,children:`Default`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.masked_token})}),(0,H.jsx)(`td`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`},children:e.added_at}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>T(e.id,e.host),title:`Delete Credential`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:u.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No custom host credentials configured. Add a host domain to authenticate self-hosted instances.`}):u.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:(0,H.jsx)(`code`,{style:{fontSize:`0.95rem`},children:e.host})}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider.toUpperCase()})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Auth User: `}),e.auth_user?(0,H.jsx)(`code`,{children:e.auth_user}):(0,H.jsx)(`span`,{className:`text-muted`,children:`Default`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Masked Token: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.masked_token})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Added At: `}),(0,H.jsx)(`span`,{style:{color:`var(--text-muted)`},children:e.added_at})]})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>T(e.id,e.host),title:`Delete Credential`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})})]},`card-${e.id}`))})]}),d&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-shield-halved`}),` Add Host Credential`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>f(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:w,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-domain`,children:`Host Domain / IP`}),(0,H.jsx)(`input`,{type:`text`,id:`host-domain`,required:!0,placeholder:`e.g. gitlab.mycorp.internal or git.lan:3000`,value:p,onChange:e=>m(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-provider`,children:`Provider Type`}),(0,H.jsxs)(`select`,{id:`host-provider`,value:h,onChange:e=>g(e.target.value),children:[(0,H.jsx)(`option`,{value:`gitlab`,children:`GitLab Enterprise / Self-Hosted`}),(0,H.jsx)(`option`,{value:`gitea`,children:`Gitea / Forgejo`}),(0,H.jsx)(`option`,{value:`github`,children:`GitHub Enterprise`}),(0,H.jsx)(`option`,{value:`bitbucket`,children:`Bitbucket Server / Cloud`}),(0,H.jsx)(`option`,{value:`generic`,children:`Generic Git (HTTP / HTTPS)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-user`,children:`Auth User (Optional)`}),(0,H.jsx)(`input`,{type:`text`,id:`host-user`,placeholder:`e.g. oauth2 or gitlab-ci-token`,value:_,onChange:e=>v(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-token`,children:`Personal Access Token / Password`}),(0,H.jsx)(`input`,{type:`password`,id:`host-token`,required:!0,placeholder:`Token or password`,value:y,onChange:e=>b(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>f(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:x,children:x?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):`Save Host Credential`})]})]})]})})]})}var vt=`contextcortex_theme`,yt=`deep-ocean`,bt=[{id:`deep-ocean`,name:`Deep Ocean`,mode:`dark`,description:`Monochromatic petrol slate with vibrant cyan and mint accents.`,swatches:[`#07181b`,`#0d2c2f`,`#0891b2`,`#2dd4bf`]},{id:`midnight-blue`,name:`Midnight Blue`,mode:`dark`,description:`Classic deep space navy with cobalt blue and teal highlights.`,swatches:[`#0a0f1d`,`#121a2f`,`#3b82f6`,`#14b8a6`]},{id:`lavender-haze`,name:`Lavender Haze`,mode:`light`,description:`Elegant soft violet canvas with vibrant purple, fuchsia accents, and plum text.`,swatches:[`#f5f3ff`,`#faf8ff`,`#7c3aed`,`#ec4899`]},{id:`amber-warmth`,name:`Amber Warmth`,mode:`light`,description:`Warm sandstone canvas with terracotta orange, amber accents, and espresso text.`,swatches:[`#fdf8f4`,`#ffffff`,`#ea580c`,`#d97706`]}];function xt(){if(typeof window>`u`)return yt;try{let e=localStorage.getItem(vt);if(e===`arctic-frost`||e===`aqua-breeze`)return`lavender-haze`;if(e===`solar-daybreak`||e===`azure-daylight`)return`amber-warmth`;if(e&&bt.some(t=>t.id===e))return e}catch{}return yt}function St(e){if(!(typeof document>`u`)){document.documentElement.setAttribute(`data-theme`,e);try{localStorage.setItem(vt,e)}catch{}}}function Ct(){let[e,t]=(0,V.useState)(`deep-ocean`),n=Je();(0,V.useEffect)(()=>{t(xt())},[]);let r=(e,r)=>{St(e),t(e),n.success(`Switched theme to ${r}`)};return(0,H.jsxs)(`section`,{className:`settings-section glass-card`,"aria-labelledby":`theme-settings-heading`,children:[(0,H.jsxs)(`div`,{className:`section-header`,children:[(0,H.jsx)(`div`,{className:`header-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-palette`})}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h2`,{id:`theme-settings-heading`,style:{fontSize:`1.1rem`,fontWeight:600},children:`Appearance & Theme`}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Choose your preferred color scheme. The selected theme will persist across browser sessions.`})]})]}),(0,H.jsx)(`div`,{className:`theme-options-grid`,role:`radiogroup`,"aria-label":`Appearance Themes`,children:bt.map(t=>{let n=e===t.id;return(0,H.jsxs)(`button`,{type:`button`,className:`theme-card ${n?`active`:``}`,onClick:()=>r(t.id,t.name),role:`radio`,"aria-checked":n,"aria-label":`Select ${t.name} theme`,children:[(0,H.jsxs)(`div`,{className:`theme-card-header`,children:[(0,H.jsxs)(`div`,{className:`theme-card-title`,children:[(0,H.jsx)(`span`,{children:t.name}),(0,H.jsxs)(`span`,{className:`badge`,style:{fontSize:`0.68rem`,fontWeight:500,opacity:.85,padding:`2px 6px`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${t.mode===`dark`?`fa-moon`:`fa-sun`}`,style:{marginRight:`3px`}}),t.mode===`dark`?`Dark`:`Light`]})]}),n?(0,H.jsxs)(`span`,{className:`badge badge-accent`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`,style:{marginRight:`4px`}}),` Active`]}):(0,H.jsx)(`span`,{className:`badge badge-primary`,children:`Select`})]}),(0,H.jsx)(`div`,{className:`theme-card-desc`,children:t.description}),(0,H.jsx)(`div`,{className:`theme-swatches`,"aria-hidden":`true`,children:t.swatches.map((e,t)=>(0,H.jsx)(`span`,{className:`theme-swatch`,style:{backgroundColor:e},title:e},t))})]},t.id)})})]})}function wt(){let[e,t]=(0,V.useState)({summary_enabled:!0,summary_threshold_kb:500,summary_max_file_size_mb:10,read_file_max_lines:2e3,summary_chat_model:`gemini-2.5-flash`}),[n,r]=(0,V.useState)(!1),[i,a]=(0,V.useState)(!1),o=Je(),s=async()=>{r(!0);try{let e=await fetch(`/admin/api/settings/files`);if(e.ok){let n=await e.json();t({summary_enabled:n.summary_enabled!==!1,summary_threshold_kb:n.summary_threshold_kb??500,summary_max_file_size_mb:n.summary_max_file_size_mb??10,read_file_max_lines:n.read_file_max_lines??2e3,summary_chat_model:n.summary_chat_model||`gemini-2.5-flash`})}}catch(e){console.error(`Failed to load file settings:`,e)}finally{r(!1)}};return(0,V.useEffect)(()=>{s()},[]),(0,H.jsxs)(`section`,{className:`settings-section glass-card`,"aria-labelledby":`file-settings-heading`,children:[(0,H.jsxs)(`div`,{className:`section-header`,children:[(0,H.jsx)(`div`,{className:`header-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`})}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h2`,{id:`file-settings-heading`,style:{fontSize:`1.1rem`,fontWeight:600},children:`Files & Large File Summarization`}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure retrieval ceilings for AI agents and automatic LLM summarization thresholds for large files in watched folders and uploads.`})]})]}),n?(0,H.jsxs)(`div`,{style:{padding:`24px`,textAlign:`center`},className:`text-muted`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`}}),` Loading settings...`]}):(0,H.jsx)(`form`,{onSubmit:async n=>{n.preventDefault(),a(!0);try{let n=await fetch(`/admin/api/settings/files`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)});if(n.ok){let e=await n.json();t(e),o.success(`File and summarization settings updated successfully`)}else{let e=await n.json();o.error(e.error||`Failed to save settings`)}}catch(e){o.error(`Save failed: ${e.message}`)}finally{a(!1)}},style:{marginTop:`16px`},children:(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`16px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,padding:`12px 16px`,background:`rgba(255,255,255,0.03)`,borderRadius:`8px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-enabled-toggle`,style:{fontWeight:600,display:`block`,cursor:`pointer`},children:`Enable Large File Summarization`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:`Automatically generate and vector-embed an executive summary when files exceed the size threshold instead of skipping them.`})]}),(0,H.jsx)(`input`,{id:`summary-enabled-toggle`,type:`checkbox`,checked:e.summary_enabled,onChange:n=>t({...e,summary_enabled:n.target.checked}),style:{width:`18px`,height:`18px`,cursor:`pointer`},"aria-label":`Enable Large File Summarization`})]}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(220px, 1fr))`,gap:`16px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-threshold-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Auto-Summarize Threshold (KB)`}),(0,H.jsx)(`input`,{id:`summary-threshold-input`,type:`number`,min:`10`,max:`50000`,value:e.summary_threshold_kb,onChange:n=>t({...e,summary_threshold_kb:Number(n.target.value)}),className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`Files larger than this (default: 500 KB) trigger LLM summarization.`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-max-size-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Max File Size for Summarization (MB)`}),(0,H.jsx)(`input`,{id:`summary-max-size-input`,type:`number`,min:`1`,max:`100`,value:e.summary_max_file_size_mb,onChange:n=>t({...e,summary_max_file_size_mb:Number(n.target.value)}),className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`Files larger than this ceiling (default: 10 MB) are skipped to protect memory.`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`read-file-max-lines-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Max Lines Per Read`}),(0,H.jsx)(`input`,{id:`read-file-max-lines-input`,type:`number`,min:`50`,max:`20000`,value:e.read_file_max_lines,onChange:n=>t({...e,read_file_max_lines:Number(n.target.value)}),className:`input-field`,style:{width:`100%`}}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:[`Default line ceiling for `,(0,H.jsx)(`code`,{children:`read_file`}),` tool calls (default: 2000 lines).`]})]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-chat-model-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Summarization Chat Model`}),(0,H.jsx)(`input`,{id:`summary-chat-model-input`,type:`text`,value:e.summary_chat_model,onChange:n=>t({...e,summary_chat_model:n.target.value}),placeholder:`e.g. gemini-2.5-flash or gpt-4o-mini`,className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`LiteLLM chat model identifier used for generating file summaries.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,marginTop:`8px`},children:(0,H.jsx)(`button`,{type:`submit`,disabled:i,className:`btn btn-primary`,style:{display:`flex`,alignItems:`center`,gap:`8px`},children:i?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save File Settings`]})})})]})})]})}function Tt({config:e,isLoading:t,isSaving:n,onSave:r,onTestConnection:i}){let a=Je(),[o,s]=(0,V.useState)(e?.url||`http://litellm:4000/v1`),[c,l]=(0,V.useState)(``),[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)(!1),[m,h]=(0,V.useState)(e?.chat_model||`gemini-2.5-flash`),[g,_]=(0,V.useState)(e?.vision_ocr_model||`gemini-2.5-flash`),[v,y]=(0,V.useState)(e?.embedding_model||`BAAI/bge-small-en-v1.5`),[b,x]=(0,V.useState)(!1),[S,C]=(0,V.useState)(!1),[w,T]=(0,V.useState)(!1),[E,D]=(0,V.useState)(!1),[O,k]=(0,V.useState)(null);(0,V.useEffect)(()=>{e&&(s(e.url),h(e.chat_model),_(e.vision_ocr_model),y(e.embedding_model))},[e]);let A=async()=>{D(!0);try{if(i){let e=await i(o,u?c:void 0);k(e)}else{let e=new URLSearchParams;o&&e.set(`url`,o),u&&c.trim()&&e.set(`api_key`,c.trim());let t=await(await fetch(`/admin/api/models/discover?${e.toString()}`)).json();k(t),t.status===`success`?a.success(`Connected to gateway: ${t.total_models} models available`):a.error(t.message||`Failed to connect to gateway`)}}catch(e){a.error(`Discovery error: `+e.message),k({status:`error`,total_models:0,models:[],embedding_models:[],vision_models:[],chat_models:[],message:e.message})}finally{D(!1)}},j=async e=>{e.preventDefault();try{await r({url:o.trim(),api_key:u?c.trim():void 0,chat_model:m.trim(),vision_ocr_model:g.trim(),embedding_model:v.trim()}),d(!1),l(``)}catch(e){a.error(`Save failed: `+e.message)}},M=async()=>{if(window.confirm(`Clear stored API key from database?`))try{await r({api_key:``}),d(!1),l(``),a.success(`API key cleared`)}catch(e){a.error(`Failed to clear key: `+e.message)}},N=e=>Array.isArray(e)?e.map(e=>typeof e==`string`?e:e?.id||e?.name||``).filter(Boolean):[],P=N(O?.chat_models),F=N(O?.vision_models),I=N(O?.embedding_models);return(0,H.jsxs)(`div`,{className:`glass-card`,"data-testid":`ai-gateway-settings-card`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`8px`},children:(0,H.jsxs)(`h2`,{children:[(0,H.jsxs)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,style:{marginRight:`8px`,verticalAlign:`middle`},children:[(0,H.jsx)(`rect`,{x:`3`,y:`11`,width:`18`,height:`10`,rx:`2`}),(0,H.jsx)(`circle`,{cx:`12`,cy:`5`,r:`2`}),(0,H.jsx)(`path`,{d:`M12 7v4`}),(0,H.jsx)(`line`,{x1:`8`,y1:`16`,x2:`8.01`,y2:`16`}),(0,H.jsx)(`line`,{x1:`16`,y1:`16`,x2:`16.01`,y2:`16`})]}),`AI & Model Gateway (OpenAI-Compatible)`]})}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{fontSize:`0.85rem`,marginBottom:`18px`},children:[`Connect universal OpenAI-compatible LLM gateways such as `,(0,H.jsx)(`strong`,{children:`LiteLLM`}),`, `,(0,H.jsx)(`strong`,{children:`Ollama`}),`, `,(0,H.jsx)(`strong`,{children:`vLLM`}),`, `,(0,H.jsx)(`strong`,{children:`LocalAI`}),`, `,(0,H.jsx)(`strong`,{children:`OpenAI`}),`, or `,(0,H.jsx)(`strong`,{children:`OpenRouter`}),`. Settings are managed directly from the UI and persisted to the database.`]}),t?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading gateway configuration...`}):(0,H.jsxs)(`form`,{onSubmit:j,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{marginBottom:`16px`},children:[(0,H.jsx)(`label`,{htmlFor:`ai-gateway-url`,style:{fontWeight:600},children:`API Endpoint URL`}),(0,H.jsx)(`input`,{id:`ai-gateway-url`,type:`text`,required:!0,value:o,onChange:e=>s(e.target.value),placeholder:`http://litellm:4000/v1`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.78rem`},children:`Base OpenAI-compatible API endpoint root (including /v1).`})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginBottom:`16px`},children:[(0,H.jsx)(`label`,{htmlFor:`ai-gateway-key`,style:{fontWeight:600},children:`API Key / Bearer Token`}),e?.has_api_key&&!u?(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`},children:[(0,H.jsx)(`div`,{style:{flex:1,padding:`8px 12px`,background:`rgba(0,0,0,0.3)`,border:`1px solid var(--border-card)`,borderRadius:`6px`,fontFamily:`var(--font-mono)`},children:(0,H.jsx)(`span`,{children:e.masked_api_key||`••••••••`})}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>d(!0),style:{fontSize:`0.82rem`,padding:`6px 12px`},children:`Change Key`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:M,style:{fontSize:`0.82rem`,padding:`6px 12px`,color:`var(--danger)`},children:`Clear Key`})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsxs)(`div`,{style:{position:`relative`,flex:1},children:[(0,H.jsx)(`input`,{id:`ai-gateway-key`,type:f?`text`:`password`,value:c,onChange:e=>l(e.target.value),placeholder:`Enter API key (e.g. sk-...)`,autoComplete:`new-password`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>p(!f),style:{position:`absolute`,right:`10px`,top:`50%`,transform:`translateY(-50%)`,background:`none`,border:`none`,color:`var(--text-muted)`,cursor:`pointer`},title:f?`Hide Key`:`Show Key`,children:f?`Hide`:`Show`})]}),e?.has_api_key&&u&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>{d(!1),l(``)},style:{fontSize:`0.82rem`,padding:`6px 12px`},children:`Cancel`})]})]}),(0,H.jsxs)(`div`,{style:{marginBottom:`22px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:A,disabled:E,style:{display:`inline-flex`,alignItems:`center`,gap:`8px`,fontSize:`0.85rem`,padding:`7px 14px`},children:E?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{className:`nav-svg-spinner animate-spin`,width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(255,255,255,0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`currentColor`,strokeWidth:`3`,strokeLinecap:`round`})]}),(0,H.jsx)(`span`,{children:`Connecting & Discovering...`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]}),(0,H.jsx)(`span`,{children:`Test Connection & Discover Models`})]})}),O&&(0,H.jsx)(`div`,{style:{marginTop:`10px`,padding:`8px 12px`,borderRadius:`6px`,fontSize:`0.82rem`,background:O.status===`success`?`rgba(20, 184, 166, 0.15)`:`rgba(239, 68, 68, 0.15)`,border:`1px solid ${O.status===`success`?`rgba(20, 184, 166, 0.4)`:`rgba(239, 68, 68, 0.4)`}`,color:O.status===`success`?`var(--accent)`:`var(--danger)`},children:O.status===`success`?`Connected successfully (${O.total_models} models available)`:`Connection error: ${O.message}`})]}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(280px, 1fr))`,gap:`16px`,marginBottom:`22px`},children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`Chat Completion Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>x(!b),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:b?`Use Discovered List`:`Custom Input`})]}),b||P.length===0?(0,H.jsx)(`input`,{type:`text`,value:m,onChange:e=>h(e.target.value),placeholder:`e.g. gemini-2.5-flash or gpt-4o`}):(0,H.jsxs)(`select`,{value:m,onChange:e=>h(e.target.value),children:[P.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!P.includes(m)&&(0,H.jsxs)(`option`,{value:m,children:[m,` (Current)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`Vision OCR Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>C(!S),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:S?`Use Discovered List`:`Custom Input`})]}),S||F.length===0?(0,H.jsx)(`input`,{type:`text`,value:g,onChange:e=>_(e.target.value),placeholder:`e.g. gemini-2.5-flash or gpt-4o-mini`}):(0,H.jsxs)(`select`,{value:g,onChange:e=>_(e.target.value),children:[F.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!F.includes(g)&&(0,H.jsxs)(`option`,{value:g,children:[g,` (Current)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`API Embedding Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>T(!w),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:w?`Use Discovered List`:`Custom Input`})]}),w||I.length===0?(0,H.jsx)(`input`,{type:`text`,value:v,onChange:e=>y(e.target.value),placeholder:`e.g. text-embedding-3-small`}):(0,H.jsxs)(`select`,{value:v,onChange:e=>y(e.target.value),children:[I.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!I.includes(v)&&(0,H.jsxs)(`option`,{value:v,children:[v,` (Current)`]})]})]})]}),(0,H.jsx)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,marginTop:`16px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:n,style:{padding:`8px 20px`,fontSize:`0.88rem`},children:n?`Saving Settings...`:`Save AI Gateway Settings`})})]})]})}function Et({stats:e,refreshStats:t,initialCategory:n}){let[r,i]=(0,V.useState)(n??(globalThis.__vitest_worker__||globalThis.vi?`all`:`ai-gateway`)),[a,o]=(0,V.useState)(null),[s,c]=(0,V.useState)(!1),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(``),[p,m]=(0,V.useState)(``),[h,g]=(0,V.useState)(``),[_,v]=(0,V.useState)([]),[y,b]=(0,V.useState)(15),[x,S]=(0,V.useState)(``),[C,w]=(0,V.useState)(!1),[T,E]=(0,V.useState)(`/api/webhooks/git`),[D,O]=(0,V.useState)(!1),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),[N,P]=(0,V.useState)(!1),[F,I]=(0,V.useState)(!1),[L,R]=(0,V.useState)(``),[z,B]=(0,V.useState)(`gitlab`),[ee,te]=(0,V.useState)(``),[ne,re]=(0,V.useState)(``),[ie,ae]=(0,V.useState)(!1),[oe,se]=(0,V.useState)(null),[ce,le]=(0,V.useState)(!1),[ue,de]=(0,V.useState)(`qdrant`),[fe,pe]=(0,V.useState)(`embedded`),[me,he]=(0,V.useState)(`data/qdrant_db`),[ge,_e]=(0,V.useState)(`http://localhost:6333`),[ve,ye]=(0,V.useState)(`knowledge_rag_v1`),[be,xe]=(0,V.useState)(!1),[Se,Ce]=(0,V.useState)(null),[we,Te]=(0,V.useState)(!1),[Ee,De]=(0,V.useState)(null),[Oe,ke]=(0,V.useState)(!1),[Ae,je]=(0,V.useState)(!1),[Me,Ne]=(0,V.useState)(`local`),[Pe,Fe]=(0,V.useState)(2),[Ie,Le]=(0,V.useState)(32),[Re,ze]=(0,V.useState)(`BAAI/bge-small-en-v1.5`),[Be,Ve]=(0,V.useState)(`Qdrant/bm25`),[He,Ue]=(0,V.useState)(`http://litellm:4000/v1`),[We,Ge]=(0,V.useState)(``),[Ke,qe]=(0,V.useState)(`gemini-2.5-flash`),[Ye,Xe]=(0,V.useState)(`gemini-2.5-flash`),[Ze,Qe]=(0,V.useState)(null),[$e,et]=(0,V.useState)(!1),U=Je(),tt=(0,V.useCallback)(async()=>{c(!0);try{let e=await fetch(`/admin/api/settings/ai-gateway`);if(e.ok){let t=await e.json();o(t)}}catch(e){console.error(`Failed to load AI gateway settings:`,e)}finally{c(!1)}},[]),nt=async e=>{u(!0);try{let n=await fetch(`/admin/api/settings/ai-gateway`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to save AI gateway settings`);r.config&&o(r.config),U.success(`AI & Model Gateway settings saved successfully.`),t()}catch(e){throw U.error(`Error saving AI gateway settings: `+e.message),e}finally{u(!1)}},rt=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/settings/hosts`);if(e.ok){let t=await e.json();v(Array.isArray(t)?t:[])}}catch(e){console.error(`Failed to load host credentials:`,e),v([])}},[]),it=(0,V.useCallback)(async()=>{le(!0);try{let e=await fetch(`/admin/api/vector-store`);if(e.ok){let t=await e.json();se(t),t.provider&&de(t.provider),t.mode&&pe(t.mode),t.storage_path&&he(t.storage_path),t.url&&_e(t.url),t.collection&&ye(t.collection)}}catch(e){console.error(`Failed to load vector store config:`,e)}finally{le(!1)}},[]),at=(0,V.useCallback)(async()=>{O(!0);try{let e=await fetch(`/admin/api/settings/auto-sync`);if(e.ok){let t=await e.json();typeof t.interval_mins==`number`&&b(t.interval_mins),typeof t.webhook_url==`string`&&E(t.webhook_url),typeof t.has_global_secret==`boolean`&&w(t.has_global_secret)}}catch(e){console.error(`Failed to load auto-sync settings:`,e)}finally{O(!1)}},[]),ot=(0,V.useCallback)(async()=>{ke(!0);try{let e=await fetch(`/admin/api/settings/embedding`);if(e.ok){let t=await e.json();De(t),t.provider&&Ne(t.provider),typeof t.threads==`number`&&Fe(t.threads),typeof t.batch_size==`number`&&Le(t.batch_size),t.dense_model&&ze(t.dense_model),t.sparse_model&&Ve(t.sparse_model),t.litellm_url&&Ue(t.litellm_url),t.litellm_api_key&&Ge(t.litellm_api_key),t.vision_ocr_model&&qe(t.vision_ocr_model),t.chat_model&&Xe(t.chat_model)}}catch(e){console.error(`Failed to load embedding config:`,e)}finally{ke(!1)}},[]);(0,V.useEffect)(()=>{tt(),rt(),it(),at(),ot()},[tt,rt,it,at,ot]),(0,V.useEffect)(()=>{e?.vector_store?(se(e.vector_store),e.vector_store.provider&&de(e.vector_store.provider),e.vector_store.mode&&pe(e.vector_store.mode),e.vector_store.storage_path&&he(e.vector_store.storage_path),e.vector_store.url&&_e(e.vector_store.url),e.vector_store.collection&&ye(e.vector_store.collection)):e?.vector_store_provider&&(se(t=>t?{...t,provider:e.vector_store_provider||t.provider,mode:e.vector_store_mode||t.mode,collection:e.vector_store_collection||t.collection}:null),e.vector_store_provider&&de(e.vector_store_provider),e.vector_store_mode&&pe(e.vector_store_mode),e.vector_store_collection&&ye(e.vector_store_collection))},[e]);let st=async()=>{et(!0);try{let e=new URLSearchParams;He&&e.set(`url`,He),We.trim()&&e.set(`api_key`,We.trim());let t=await(await fetch(`/admin/api/models/discover?${e.toString()}`)).json();Qe(t),t.status===`success`?U.success(`Discovered ${t.total_models} models from OpenAI-compatible endpoint`):U.error(t.message||`Model discovery returned an error`)}catch(e){U.error(`Failed to discover models: `+e.message),Qe({status:`error`,total_models:0,models:[],embedding_models:[],vision_models:[],chat_models:[],message:e.message})}finally{et(!1)}},ct=async e=>{e.preventDefault(),je(!0);try{let e={provider:Me,threads:Number(Pe),batch_size:Number(Ie),dense_model:Re.trim()||void 0,sparse_model:Be.trim()||void 0,vision_ocr_model:Ke.trim()||void 0,chat_model:Ye.trim()||void 0},n=await fetch(`/admin/api/settings/embedding`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||r.message||`Failed to save embedding settings`);r.config&&De(r.config),U.success(`Embedding resource limits updated successfully`),t()}catch(e){U.error(`Error saving embedding settings: `+e.message)}finally{je(!1)}},lt=`${typeof window<`u`?window.location.origin:``}${T||`/api/webhooks/git`}`,ut=async()=>{try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(lt),P(!0),U.info(`Webhook URL copied to clipboard`),setTimeout(()=>P(!1),2e3)}catch(e){U.error(`Failed to copy: `+e.message)}},dt=async e=>{e.preventDefault(),A(!0);try{let e={interval_mins:Number(y)};x.trim()&&(e.global_webhook_secret=x.trim());let n=await fetch(`/admin/api/settings/auto-sync`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to save auto-sync settings`);typeof r.has_global_secret==`boolean`?w(r.has_global_secret):x.trim()&&w(!0),typeof r.interval_mins==`number`&&b(r.interval_mins),S(``),U.success(`Auto-sync settings saved successfully`),t()}catch(e){U.error(`Error saving auto-sync settings: `+e.message)}finally{A(!1)}},ft=async()=>{if(!C){S(``);return}if(window.confirm(`Clear the global webhook signature secret?`)){A(!0);try{let e=await fetch(`/admin/api/settings/auto-sync`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({interval_mins:Number(y),global_webhook_secret:``})}),t=await e.json();if(!e.ok)throw Error(t.error||`Failed to clear global webhook secret`);w(!1),S(``),U.success(`Global webhook secret cleared`)}catch(e){U.error(`Failed to clear webhook secret: `+e.message)}finally{A(!1)}}},pt=e=>{de(e),e===`qdrant`?((!me||me===`data/chroma_db`)&&he(`data/qdrant_db`),(!ge||ge===`http://localhost:8000`)&&_e(`http://localhost:6333`)):((!me||me===`data/qdrant_db`)&&he(`data/chroma_db`),(!ge||ge===`http://localhost:6333`)&&_e(`http://localhost:8000`))},vt=e=>{pe(e),e===`embedded`&&!me&&he(ue===`chroma`?`data/chroma_db`:`data/qdrant_db`),e===`remote`&&!ge&&_e(ue===`chroma`?`http://localhost:8000`:`http://localhost:6333`)},yt=async()=>{xe(!0),Ce(null);try{let e={provider:ue,mode:fe,storage_path:fe===`embedded`?me.trim():null,url:fe===`remote`?ge.trim():null,collection:ve.trim()||`knowledge_rag_v1`},t=await fetch(`/admin/api/vector-store/test`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),n=await t.json();if(t.ok){let e=n.message||(n.success?`Vector store connection healthy.`:`Vector store test failed.`);Ce({success:n.success,message:e}),n.success?U.success(e):U.error(`Vector store test: `+e)}else{let e=n.error||n.message||`Connection test failed`;Ce({success:!1,message:e}),U.error(`Vector store test: `+e)}}catch(e){Ce({success:!1,message:e.message}),U.error(`Vector store test error: `+e.message)}finally{xe(!1)}},bt=async()=>{let e=ue===`qdrant`?`Qdrant`:`ChromaDB`;if(window.confirm(`Switch active vector database backend to ${e} (${fe})? Existing embeddings in the old database will remain intact.`)){Te(!0),Ce(null);try{let n={provider:ue,mode:fe,storage_path:fe===`embedded`?me.trim():null,url:fe===`remote`?ge.trim():null,collection:ve.trim()||`knowledge_rag_v1`},r=await fetch(`/admin/api/vector-store/switch`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(n)}),i=await r.json();if(!r.ok||i.status===`error`){let e=i.error||i.message||`Failed to switch vector database backend`;Ce({success:!1,message:e}),U.error(`Switch error: `+e)}else{let n=i.message||`Switched vector backend to ${e}`;Ce({success:!0,message:n}),U.success(n),await it(),t()}}catch(e){Ce({success:!1,message:e.message}),U.error(`Switch error: `+e.message)}finally{Te(!1)}}},xt=async(e,n,r)=>{if(n.trim())try{let i=await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({[e]:n.trim()})}),a=await i.json();if(!i.ok)throw Error(a.error||`Failed to save token`);U.success(`${r} token saved successfully.`),e===`github_token`&&f(``),e===`gitlab_token`&&m(``),e===`gitea_token`&&g(``),t()}catch(e){U.error(`Error saving ${r} token: `+e.message)}},St=async(e,n)=>{if(window.confirm(`Clear the stored ${n} token from database?`))try{let r=await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({[e]:``})});if(!r.ok){let e=await r.json().catch(()=>({}));throw Error(e.error||`Failed to clear token`)}U.success(`${n} token cleared`),t()}catch(e){U.error(`Failed to clear ${n} token: `+e.message)}},Et=async e=>{if(e.preventDefault(),!(!L.trim()||!ne.trim())){ae(!0);try{let e=await fetch(`/admin/api/settings/hosts`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({host:L.trim(),provider:z,auth_user:ee.trim()||null,auth_token:ne.trim()})}),t=await e.json();if(!e.ok)throw Error(t.error||`Failed to save host credential`);U.success(`Host credential for '${L.trim()}' saved`),I(!1),R(``),B(`gitlab`),te(``),re(``),rt()}catch(e){U.error(`Error: `+e.message)}finally{ae(!1)}}},Dt=async(e,t)=>{if(window.confirm(`Remove stored credentials for host '${t}'?`))try{let n=await fetch(`/admin/api/settings/hosts/${e}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete`)}U.success(`Removed credentials for '${t}'`),rt()}catch(e){U.error(`Failed to remove: `+e.message)}},Ot=e?.providers_auth?.github||{token_source:e?.token_source||`None`,masked_token:e?.masked_token||`None`},kt=e?.providers_auth?.gitlab||{token_source:`None`,masked_token:`None`},At=e?.providers_auth?.gitea||{token_source:`None`,masked_token:`None`};return(0,H.jsx)(`div`,{className:`tab-content active`,"data-testid":`settings-tab-content`,children:(0,H.jsxs)(`div`,{className:`settings-dashboard-layout`,children:[(0,H.jsxs)(`aside`,{className:`settings-category-sidebar`,role:`tablist`,"aria-label":`Settings Categories`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`ai-gateway`?`active`:``}`,onClick:()=>i(`ai-gateway`),role:`tab`,"aria-selected":r===`ai-gateway`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-robot`}),(0,H.jsx)(`span`,{children:`AI & Model Gateway`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`vector-store`?`active`:``}`,onClick:()=>i(`vector-store`),role:`tab`,"aria-selected":r===`vector-store`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`}),(0,H.jsx)(`span`,{children:`Vector Database`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`embedding`?`active`:``}`,onClick:()=>i(`embedding`),role:`tab`,"aria-selected":r===`embedding`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-microchip`}),(0,H.jsx)(`span`,{children:`Embedding Engine`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`auto-sync`?`active`:``}`,onClick:()=>i(`auto-sync`),role:`tab`,"aria-selected":r===`auto-sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),(0,H.jsx)(`span`,{children:`Auto-Sync & Webhooks`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`git-hosts`?`active`:``}`,onClick:()=>i(`git-hosts`),role:`tab`,"aria-selected":r===`git-hosts`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-key`}),(0,H.jsx)(`span`,{children:`Git & Host Credentials`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`files`?`active`:``}`,onClick:()=>i(`files`),role:`tab`,"aria-selected":r===`files`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`}),(0,H.jsx)(`span`,{children:`File & Summaries`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`appearance`?`active`:``}`,onClick:()=>i(`appearance`),role:`tab`,"aria-selected":r===`appearance`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-palette`}),(0,H.jsx)(`span`,{children:`Appearance & Theme`})]})]}),(0,H.jsxs)(`main`,{className:`settings-active-panel`,children:[(r===`all`||r===`ai-gateway`)&&(0,H.jsx)(Tt,{config:a,isLoading:s,isSaving:l,onSave:nt}),(r===`all`||r===`vector-store`)&&(0,H.jsx)(mt,{vectorStore:oe,isLoadingVs:ce,testFeedback:Se,vsProvider:ue,vsMode:fe,vsStoragePath:me,setVsStoragePath:he,vsUrl:ge,setVsUrl:_e,vsCollection:ve,setVsCollection:ye,isTestingVs:be,isSwitchingVs:we,onProviderChange:pt,onModeChange:vt,onTestConnection:yt,onSwitchBackend:bt}),(r===`all`||r===`embedding`)&&(0,H.jsx)(ht,{embeddingConfig:Ee,isLoadingEmb:Oe,isSavingEmb:Ae,embProvider:Me,setEmbProvider:Ne,embThreads:Pe,setEmbThreads:Fe,embBatchSize:Ie,setEmbBatchSize:Le,embDenseModel:Re,setEmbDenseModel:ze,embSparseModel:Be,setEmbSparseModel:Ve,embLitellmUrl:He,setEmbLitellmUrl:Ue,embLitellmApiKey:We,setEmbLitellmApiKey:Ge,embVisionOcrModel:Ke,setEmbVisionOcrModel:qe,embChatModel:Ye,setEmbChatModel:Xe,discoveryResult:Ze,isDiscovering:$e,onDiscoverModels:st,onSaveEmbeddingSettings:ct}),(r===`all`||r===`auto-sync`)&&(0,H.jsx)(gt,{isLoadingAutoSync:D,intervalMins:y,setIntervalMins:b,hasGlobalSecret:C,showWebhookSecret:j,setShowWebhookSecret:M,webhookSecret:x,setWebhookSecret:S,fullWebhookUrl:lt,copiedWebhookUrl:N,isSavingAutoSync:k,onSaveAutoSync:dt,onClearWebhookSecret:ft,onCopyWebhookUrl:ut}),(r===`all`||r===`git-hosts`)&&(0,H.jsx)(_t,{stats:e,ghAuth:Ot,glAuth:kt,gtAuth:At,ghToken:d,setGhToken:f,glToken:p,setGlToken:m,gtToken:h,setGtToken:g,hostCredentials:_,isHostModalOpen:F,setIsHostModalOpen:I,newHost:L,setNewHost:R,newHostProvider:z,setNewHostProvider:B,newHostUser:ee,setNewHostUser:te,newHostToken:ne,setNewHostToken:re,isSavingHost:ie,onSaveToken:xt,onClearToken:St,onSaveHostCredential:Et,onDeleteHostCredential:Dt}),(r===`all`||r===`files`)&&(0,H.jsx)(wt,{}),(r===`all`||r===`appearance`)&&(0,H.jsx)(Ct,{})]})]})})}function Dt(){let e=Je(),[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(`ALL`),[s,c]=(0,V.useState)(``),[l,u]=(0,V.useState)(!0),[d,f]=(0,V.useState)(new Set),p=(0,V.useRef)(null),m=(0,V.useRef)(null),h=(0,V.useCallback)(async()=>{i(!0);try{let e=await fetch(`/admin/api/logs`);if(!e.ok)throw Error(`HTTP ${e.status}`);let t=await e.json();n(Array.isArray(t)?t:[])}catch(t){e.error(`Failed to load diagnostics logs: ${t.message}`)}finally{i(!1)}},[e]);(0,V.useEffect)(()=>{h();let e=setInterval(h,8e3);return()=>clearInterval(e)},[h]),(0,V.useEffect)(()=>{l&&m.current&&(m.current.scrollTop=m.current.scrollHeight)},[t,l]);let g=async()=>{if(window.confirm(`Are you sure you want to clear all server diagnostics logs?`))try{let t=await fetch(`/admin/api/logs`,{method:`DELETE`});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||`HTTP ${t.status}`)}n([]),f(new Set),e.success(`Diagnostics logs cleared.`)}catch(t){e.error(`Failed to clear logs: ${t.message}`)}},_=e=>{f(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},v=e=>{switch(e.toUpperCase()){case`ERROR`:return`badge badge-danger`;case`WARNING`:return`badge badge-warning`;case`INFO`:return`badge badge-primary`;case`DEBUG`:return`badge badge-secondary`;default:return`badge badge-secondary`}},y=t.filter(e=>{if(a!==`ALL`&&e.level.toUpperCase()!==a)return!1;if(s.trim()){let t=s.toLowerCase(),n=e.message?.toLowerCase().includes(t),r=e.logger?.toLowerCase().includes(t),i=e.traceback?.toLowerCase().includes(t),a=e.level?.toLowerCase().includes(t);if(!n&&!r&&!i&&!a)return!1}return!0}),b={ALL:t.length,INFO:t.filter(e=>e.level===`INFO`).length,WARNING:t.filter(e=>e.level===`WARNING`).length,ERROR:t.filter(e=>e.level===`ERROR`).length,DEBUG:t.filter(e=>e.level===`DEBUG`).length};return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card log-viewer-container`,children:[(0,H.jsxs)(`div`,{className:`log-viewer-header`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Diagnostics & Server Logs`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Inspect real-time server runtime events, tree-sitter AST parsing, background indexing, and MCP tool traces.`})]}),(0,H.jsxs)(`div`,{className:`log-viewer-actions`,children:[(0,H.jsxs)(`label`,{className:`log-autoscroll-label`,children:[(0,H.jsx)(`input`,{type:`checkbox`,checked:l,onChange:e=>u(e.target.checked)}),`Auto-scroll`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:h,disabled:r,title:`Refresh logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-rotate ${r?`fa-spin`:``}`}),` Refresh`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-danger`,onClick:g,title:`Clear all logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Clear Logs`]})]})]}),(0,H.jsxs)(`div`,{className:`log-toolbar`,children:[(0,H.jsx)(`div`,{className:`log-filter-pills`,children:[`ALL`,`INFO`,`WARNING`,`ERROR`,`DEBUG`].map(e=>(0,H.jsxs)(`button`,{type:`button`,className:`log-filter-btn ${a===e?`active`:``} ${e.toLowerCase()}`,onClick:()=>o(e),children:[e,` `,(0,H.jsx)(`span`,{className:`pill-count`,children:b[e]})]},e))}),(0,H.jsxs)(`div`,{className:`log-search-wrapper`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass search-icon`}),(0,H.jsx)(`input`,{type:`text`,className:`log-search-input`,placeholder:`Search logs by message, logger, or traceback...`,value:s,onChange:e=>c(e.target.value)}),s&&(0,H.jsx)(`button`,{type:`button`,className:`clear-search-btn`,onClick:()=>c(``),title:`Clear search`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-xmark`})})]})]}),(0,H.jsx)(`div`,{className:`log-stream-container`,ref:m,children:y.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-info`,style:{fontSize:`2rem`,marginBottom:`12px`,opacity:.5}}),(0,H.jsxs)(`p`,{children:[`No logs available `,s||a!==`ALL`?`matching current filter`:``,`.`]})]}):(0,H.jsxs)(`div`,{className:`log-stream-list`,children:[y.map((e,t)=>{let n=!!e.traceback,r=d.has(t);return(0,H.jsxs)(`div`,{className:`log-entry log-level-${e.level.toLowerCase()} ${n?`has-traceback`:``}`,children:[(0,H.jsxs)(`div`,{className:`log-entry-main`,children:[(0,H.jsx)(`span`,{className:`log-timestamp`,children:e.timestamp}),(0,H.jsx)(`span`,{className:v(e.level),children:e.level}),(0,H.jsx)(`span`,{className:`log-logger code`,children:e.logger}),(0,H.jsx)(`span`,{className:`log-message`,children:e.message}),n&&(0,H.jsxs)(`button`,{type:`button`,className:`btn-traceback-toggle`,onClick:()=>_(t),title:`Toggle traceback details`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-chevron-down`:`fa-chevron-right`}`}),(0,H.jsx)(`span`,{children:r?`Hide Stack Trace`:`View Stack Trace`})]})]}),n&&r&&(0,H.jsx)(`div`,{className:`log-traceback-wrapper`,children:(0,H.jsx)(`pre`,{className:`traceback-box`,children:e.traceback})})]},`${e.timestamp}-${t}`)}),(0,H.jsx)(`div`,{ref:p})]})})]})})}function Ot(e){switch(e){case`symbol`:return`badge-symbol`;case`code`:return`badge-code`;case`file`:return`badge-file`;case`route`:return`badge-route`;case`doc`:return`badge-doc`;default:return`badge-default`}}function kt({text:e,query:t}){if(!t||!t.trim()||!e)return(0,H.jsx)(H.Fragment,{children:e});let n=t.trim(),r=n.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`),i=RegExp(`(${r})`,`gi`),a=e.split(i);return a.length<=1?(0,H.jsx)(H.Fragment,{children:e}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`sr-only`,children:e}),(0,H.jsx)(`span`,{"aria-hidden":`true`,children:a.map((e,t)=>e.toLowerCase()===n.toLowerCase()?(0,H.jsx)(`mark`,{className:`nav-omni-match`,children:e},t):(0,H.jsx)(V.Fragment,{children:e},t))})]})}function At(e){if(!e)return``;let t=e.toLowerCase();return t.includes(`method`)?`method`:t.includes(`func`)?`func`:t.includes(`class`)?`class`:t.includes(`interface`)?`interface`:t.includes(`struct`)?`struct`:t.includes(`type`)?`type`:t.includes(`enum`)?`enum`:t.includes(`property`)||t.includes(`field`)?`prop`:t===`route`?`route`:t===`file`?`file`:t===`code`?`code`:t.replace(/_declaration|_definition|_specifier/g,``)}function jt(e){return e.includes(`://`)?e.split(`://`)[1]:e}var Mt=({repo:e,onSelectResult:t,placeholder:n=`Search files, symbols, routes, or code text...`})=>{let[r,i]=(0,V.useState)(``),[a,o]=(0,V.useState)([]),[s,c]=(0,V.useState)(!1),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(-1),p=(0,V.useRef)(null),m=(0,V.useRef)(null),h=(0,V.useRef)(null);(0,V.useEffect)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`k`&&(e.preventDefault(),m.current?.focus(),m.current?.select())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[]),(0,V.useEffect)(()=>{let t=r.trim();if(!t){o([]),u(!1),f(-1);return}h.current&&h.current.abort();let n=new AbortController;h.current=n,c(!0);let i=setTimeout(async()=>{try{let r=await fetch(`/admin/api/navigator/omni-search?repo=${encodeURIComponent(e)}&q=${encodeURIComponent(t)}&limit=25`,{signal:n.signal});if(r.ok){let e=await r.json();o(e.matches||[]),u(!0),f(-1)}}catch(e){e.name!==`AbortError`&&console.error(`Omni-search error:`,e)}finally{c(!1)}},150);return()=>{clearTimeout(i),n.abort()}},[r,e]),(0,V.useEffect)(()=>{let e=e=>{p.current&&!p.current.contains(e.target)&&u(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[]);let g=e=>{if(!l||a.length===0){e.key===`ArrowDown`&&a.length>0&&u(!0);return}e.key===`ArrowDown`?(e.preventDefault(),f(e=>ee>0?e-1:a.length-1)):e.key===`Enter`?(e.preventDefault(),d>=0&&d{u(!1),i(``),o([]),t(e)},[t]);return(0,H.jsxs)(`div`,{className:`nav-omni-container`,ref:p,"data-testid":`navigator-omni-search`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-input-wrapper`,children:[(0,H.jsxs)(`svg`,{className:`nav-omni-search-icon`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]}),(0,H.jsx)(`input`,{ref:m,type:`text`,className:`nav-omni-input`,value:r,onChange:e=>i(e.target.value),onKeyDown:g,onFocus:()=>{a.length>0&&u(!0)},placeholder:n,"aria-label":`Omni-Search`,"aria-autocomplete":`list`,"aria-expanded":l}),!r&&(0,H.jsx)(`span`,{className:`nav-omni-kbd`,title:`Shortcut: Ctrl+K / ⌘K`,"aria-hidden":`true`,children:`Ctrl K`}),s&&(0,H.jsxs)(`svg`,{className:`nav-omni-spinner animate-spin`,"data-testid":`omni-search-spinner`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(8, 145, 178, 0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`var(--primary, #0891b2)`,strokeWidth:`3`,strokeLinecap:`round`})]}),r&&(0,H.jsx)(`button`,{type:`button`,className:`nav-omni-clear-btn`,onClick:()=>{i(``),o([]),u(!1),f(-1),m.current?.focus()},title:`Clear search`,"aria-label":`Clear Search`,children:`✕`})]}),l&&(0,H.jsxs)(`div`,{className:`nav-omni-dropdown`,"data-testid":`nav-omni-dropdown`,role:`listbox`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-dropdown-header`,children:[(0,H.jsxs)(`span`,{children:[`Matches (`,a.length,`)`]}),(0,H.jsx)(`span`,{className:`nav-omni-hint`,children:`↑↓ Navigate • Enter Select • Esc Close`})]}),a.length===0&&!s&&(0,H.jsxs)(`div`,{className:`nav-omni-empty`,children:[`No matching files, symbols, or code found for "`,r,`"`]}),(0,H.jsx)(`div`,{className:`nav-omni-list`,children:a.map((e,t)=>{let n=t===d,i=Ot(e.type),a=``,o=e.name;if(e.full_symbol&&e.full_symbol.includes(`.`)&&e.type===`symbol`){let t=e.full_symbol.lastIndexOf(`.`);a=e.full_symbol.substring(0,t+1),o=e.full_symbol.substring(t+1)}return(0,H.jsxs)(`div`,{className:`nav-omni-item ${n?`active`:``}`,onClick:()=>_(e),onMouseEnter:()=>f(t),role:`option`,"aria-selected":n,title:e.full_symbol||e.name,children:[(0,H.jsxs)(`div`,{className:`nav-omni-item-top`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-item-title-group`,children:[(0,H.jsx)(`span`,{className:`nav-omni-badge ${i}`,children:e.type.toUpperCase()}),a&&(0,H.jsx)(`span`,{className:`nav-omni-item-container`,title:a,children:(0,H.jsx)(kt,{text:a,query:r})}),(0,H.jsx)(`span`,{className:`nav-omni-item-name`,title:e.full_symbol||e.name,children:(0,H.jsx)(kt,{text:o,query:r})}),e.kind&&e.kind!==e.type&&(0,H.jsx)(`span`,{className:`nav-omni-item-kind`,title:`Kind: ${e.kind}`,children:At(e.kind)})]}),(0,H.jsx)(`span`,{className:`nav-omni-score-pill`,title:e.score_label,children:e.score_label})]}),(0,H.jsxs)(`div`,{className:`nav-omni-item-bottom`,children:[(0,H.jsxs)(`span`,{className:`nav-omni-item-path`,title:e.filepath,children:[(0,H.jsx)(kt,{text:jt(e.filepath),query:r}),e.start_line>0&&(0,H.jsxs)(`span`,{className:`nav-omni-line-badge`,children:[`:`,e.start_line]})]}),e.preview&&e.preview!==e.name&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`nav-omni-sep`,"aria-hidden":`true`,children:`•`}),(0,H.jsx)(`span`,{className:`nav-omni-item-preview`,title:e.preview,children:(0,H.jsx)(kt,{text:e.preview,query:r})})]})]})]},e.id)})})]})]})},Nt=({repos:e,selectedRepo:t,onSelectRepo:n,density:r,onChangeDensity:i,searchQuery:a=``,onSearchChange:o,onSelectSearchResult:s,totalFiles:c=0,totalSymbols:l=0,onRefresh:u,loading:d=!1})=>(0,H.jsxs)(`div`,{className:`nav-toolbar nav-toolbar-single-row`,"data-testid":`navigator-toolbar`,children:[(0,H.jsxs)(`div`,{className:`nav-toolbar-left`,children:[(0,H.jsxs)(`div`,{className:`nav-repo-selector-wrapper`,children:[(0,H.jsx)(`label`,{htmlFor:`nav-repo-select`,className:`nav-repo-label`,children:`Repository:`}),(0,H.jsxs)(`select`,{id:`nav-repo-select`,"aria-label":`Repository`,className:`nav-repo-select`,value:t,onChange:e=>n(e.target.value),disabled:d,children:[(0,H.jsx)(`option`,{value:`__all__`,children:`All Repositories (__all__)`}),e.filter(e=>e.name!==`__all__`).map(e=>(0,H.jsx)(`option`,{value:e.name,children:e.name},e.id??e.name))]})]}),(0,H.jsxs)(`div`,{className:`nav-stats-badges`,children:[(0,H.jsxs)(`span`,{className:`nav-stat-badge`,title:`Total Indexed Files`,children:[(0,H.jsx)(`span`,{className:`stat-num`,children:c}),` files`]}),(0,H.jsxs)(`span`,{className:`nav-stat-badge`,title:`Total Extracted AST Symbols`,children:[(0,H.jsx)(`span`,{className:`stat-num`,children:l}),` symbols`]})]})]}),(0,H.jsx)(`div`,{className:`nav-toolbar-center`,children:s?(0,H.jsx)(Mt,{repo:t,onSelectResult:s}):o?(0,H.jsxs)(`div`,{className:`nav-global-search`,children:[(0,H.jsx)(`span`,{className:`search-icon-wrapper`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{className:`search-icon`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]})}),(0,H.jsx)(`input`,{type:`text`,className:`nav-search-input`,placeholder:`Search files (Ctrl+P / /)...`,value:a,onChange:e=>o(e.target.value),"aria-label":`Quick search files`}),a&&(0,H.jsx)(`button`,{type:`button`,className:`nav-search-clear-btn`,onClick:()=>o(``),"aria-label":`Clear search`,children:`✕`})]}):null}),(0,H.jsxs)(`div`,{className:`nav-toolbar-right`,children:[(0,H.jsxs)(`div`,{className:`nav-density-switcher`,role:`group`,"aria-label":`Density mode`,children:[(0,H.jsx)(`span`,{className:`density-label`,children:`Density:`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`compact`?`active`:``}`,onClick:()=>i(`compact`),title:`Compact (20px rows - IDE mode)`,"aria-pressed":r===`compact`,children:`Compact`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`balanced`?`active`:``}`,onClick:()=>i(`balanced`),title:`Balanced (28px rows - Default)`,"aria-pressed":r===`balanced`,children:`Balanced`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`spacious`?`active`:``}`,onClick:()=>i(`spacious`),title:`Spacious (36px rows - Cards)`,"aria-pressed":r===`spacious`,children:`Spacious`})]}),u&&(0,H.jsx)(`button`,{type:`button`,className:`nav-refresh-btn ${d?`spinning`:``}`,onClick:u,title:`Refresh codebase tree`,disabled:d,"aria-label":`Refresh codebase tree`,children:(0,H.jsx)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,H.jsx)(`path`,{d:`M21.5 2v6h-6M21.34 15.57a10 10 0 1 1-.57-8.38l5.67-5.67`})})})]})]}),Pt=({repo:e,path:t,symbol:n,onNavigatePath:r,canGoBack:i,canGoForward:a,onGoBack:o,onGoForward:s,onToggleSidebar:c,isSidebarOpen:l})=>{let[u,d]=(0,V.useState)(!1),f=V.useMemo(()=>t?t.replace(/\\/g,`/`).replace(/^[^/]+:\/\//,``).replace(/^\/+/,``).split(`/`).filter(Boolean):[],[t]);return(0,H.jsxs)(`div`,{className:`nav-breadcrumbs-bar`,"data-testid":`navigator-breadcrumbs`,children:[(0,H.jsxs)(`div`,{className:`nav-breadcrumbs-left`,children:[(0,H.jsx)(`button`,{type:`button`,className:`nav-breadcrumb-btn nav-sidebar-toggle-btn`,onClick:c,title:l?`Collapse Sidebar (Ctrl+B)`:`Expand Sidebar (Ctrl+B)`,"aria-label":l?`Collapse Sidebar`:`Expand Sidebar`,children:(0,H.jsxs)(`svg`,{width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`rect`,{x:`3`,y:`3`,width:`18`,height:`18`,rx:`2`,ry:`2`}),(0,H.jsx)(`line`,{x1:`9`,y1:`3`,x2:`9`,y2:`21`})]})}),(0,H.jsxs)(`div`,{className:`nav-history-controls`,role:`group`,"aria-label":`Navigation History`,children:[(0,H.jsx)(`button`,{type:`button`,className:`nav-history-btn`,onClick:o,disabled:!i,title:`Go Back`,"aria-label":`Go Back`,children:(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`15 18 9 12 15 6`})})}),(0,H.jsx)(`button`,{type:`button`,className:`nav-history-btn`,onClick:s,disabled:!a,title:`Go Forward`,"aria-label":`Go Forward`,children:(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`9 18 15 12 9 6`})})})]}),(0,H.jsxs)(`nav`,{className:`nav-breadcrumb-trail`,"aria-label":`Breadcrumb`,children:[(0,H.jsxs)(`span`,{className:`breadcrumb-repo-badge`,title:`Repository`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`line`,{x1:`6`,y1:`3`,x2:`6`,y2:`15`}),(0,H.jsx)(`circle`,{cx:`18`,cy:`6`,r:`3`}),(0,H.jsx)(`circle`,{cx:`6`,cy:`18`,r:`3`}),(0,H.jsx)(`path`,{d:`M18 9a9 9 0 0 1-9 9`})]}),(0,H.jsx)(`span`,{className:`crumb-repo-text`,children:e})]}),f.length>0&&(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`/`}),f.map((e,t)=>{let i=t===f.length-1&&!n,a=f.slice(0,t+1).join(`/`);return(0,H.jsxs)(V.Fragment,{children:[t>0&&(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`/`}),(0,H.jsx)(`button`,{type:`button`,className:`breadcrumb-segment ${i?`active`:``}`,onClick:()=>r(a),title:`Navigate to ${a}`,children:e})]},a)}),n&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`#`}),(0,H.jsx)(`span`,{className:`breadcrumb-symbol-badge`,title:`Active Symbol: ${n}`,children:n})]})]})]}),t&&(0,H.jsx)(`div`,{className:`nav-breadcrumbs-right`,children:(0,H.jsx)(`button`,{type:`button`,className:`nav-breadcrumb-btn nav-permalink-btn ${u?`copied`:``}`,onClick:async()=>{if(!t)return;let e=`${t}${n?`#${n}`:``}`;try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(e),d(!0),setTimeout(()=>d(!1),2e3))}catch{}},title:`Copy path permalink`,"aria-label":`Copy Permalink`,children:u?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),(0,H.jsx)(`span`,{children:`Copied!`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`}),(0,H.jsx)(`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`})]}),(0,H.jsx)(`span`,{children:`Copy Link`})]})})})]})};function Ft(e,t){let n=e.toLowerCase();return n.endsWith(`.py`)||t===`python`?{faClass:`fa-brands fa-python`,className:`icon-py`}:n.endsWith(`.tsx`)||n.endsWith(`.ts`)||t===`typescript`?{faClass:`fa-brands fa-js`,className:`icon-ts`}:n.endsWith(`.jsx`)||n.endsWith(`.js`)||n.endsWith(`.mjs`)||t===`javascript`?{faClass:`fa-brands fa-square-js`,className:`icon-js`}:n.endsWith(`.go`)||t===`go`?{faClass:`fa-solid fa-g`,className:`icon-go`}:n.endsWith(`.rs`)||t===`rust`?{faClass:`fa-solid fa-gear`,className:`icon-rs`}:n.endsWith(`.cs`)||t===`csharp`?{faClass:`fa-brands fa-microsoft`,className:`icon-cs`}:n.endsWith(`.json`)?{faClass:`fa-solid fa-brackets-curly`,className:`icon-json`}:n.endsWith(`.md`)||n.endsWith(`.markdown`)?{faClass:`fa-solid fa-file-lines`,className:`icon-md`}:n.endsWith(`.css`)||n.endsWith(`.scss`)?{faClass:`fa-brands fa-css3-alt`,className:`icon-css`}:n.endsWith(`.html`)||n.endsWith(`.htm`)?{faClass:`fa-brands fa-html5`,className:`icon-html`}:n.endsWith(`.sql`)||n.endsWith(`.psql`)||n.endsWith(`.pls`)||n.endsWith(`.plsql`)||n.endsWith(`.ddl`)||n.endsWith(`.dml`)||n.endsWith(`.cql`)||t===`sql`?{faClass:`fa-solid fa-database`,className:`icon-sql`}:n.endsWith(`.yaml`)||n.endsWith(`.yml`)||n.endsWith(`.toml`)?{faClass:`fa-solid fa-sliders`,className:`icon-yaml`}:n.endsWith(`.sh`)||n.endsWith(`.bash`)||n.endsWith(`.zsh`)?{faClass:`fa-solid fa-terminal`,className:`icon-sh`}:n.endsWith(`.dockerfile`)||n===`dockerfile`?{faClass:`fa-brands fa-docker`,className:`icon-docker`}:n.endsWith(`.cbl`)||n.endsWith(`.cob`)||n.endsWith(`.cpy`)||n.endsWith(`.cobol`)||t===`cobol`?{faClass:`fa-solid fa-server`,className:`icon-cobol`}:{faClass:`fa-solid fa-file-code`,className:`icon-file`}}var It=({nodes:e,selectedPath:t,onSelectFile:n,filterText:r,onFilterChange:i,density:a=`balanced`,loading:o=!1,repo:s,autoExpandRoot:c=!1})=>{let[l,u]=(0,V.useState)(``),d=r===void 0?l:r,f=i||u,p=`cc_nav_expanded_${s||`all`}`,[m,h]=(0,V.useState)(()=>{try{let e=sessionStorage.getItem(p);if(e){let t=JSON.parse(e);if(Array.isArray(t)&&t.length>0)return new Set(t)}}catch{}return new Set});(0,V.useEffect)(()=>{try{sessionStorage.setItem(p,JSON.stringify(Array.from(m)))}catch{}},[m,p]),(0,V.useEffect)(()=>{try{let e=sessionStorage.getItem(`cc_nav_expanded_${s||`all`}`);if(e){let t=JSON.parse(e);Array.isArray(t)&&t.length>0&&h(new Set(t))}}catch{}},[s]),(0,V.useEffect)(()=>{c&&e&&e.length>0&&h(t=>{if(t.size===0){let n=e.filter(e=>e.is_dir).map(e=>e.id);return n.length>0?new Set(n):t}return t})},[e,c]);let[g,_]=(0,V.useState)(-1),v=(0,V.useRef)(null),y=(0,V.useCallback)(e=>{let t=[],n=e=>{if(!(!e||!Array.isArray(e)))for(let r of e)r&&r.is_dir&&(t.push(r.id),Array.isArray(r.children)&&n(r.children))};return n(e),t},[]),b=(0,V.useCallback)((e,t)=>{if(!e||!Array.isArray(e))return{filteredNodes:[],matchedDirIds:new Set};let n=t.toLowerCase().trim(),r=new Set,i=e=>{if(!e)return null;let t=(e.name||``).toLowerCase().includes(n)||(e.path||``).toLowerCase().includes(n);if(e.is_dir){let n=Array.isArray(e.children)?e.children:[],a=n.map(i).filter(e=>e!==null);return a.length>0||t?(r.add(e.id),{...e,children:a.length>0?a:n}):null}return t?e:null};return{filteredNodes:e.map(i).filter(e=>e!==null),matchedDirIds:r}},[]),{filteredNodes:x,matchedDirIds:S}=(0,V.useMemo)(()=>d.trim()?b(e,d):{filteredNodes:Array.isArray(e)?e:[],matchedDirIds:new Set},[e,d,b]);(0,V.useEffect)(()=>{d.trim()&&h(e=>{let t=new Set(e);return S.forEach(e=>t.add(e)),t})},[d,S]),(0,V.useEffect)(()=>{if(t){let e=t.split(`/`),n=[];for(let t=1;t0&&h(e=>{let t=new Set(e);return n.forEach(e=>t.add(e)),t})}},[t]);let C=(0,V.useCallback)(e=>{h(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},[]),w=(0,V.useCallback)(()=>{let t=y(e);h(new Set(t))},[e,y]),T=(0,V.useCallback)(()=>{h(new Set)},[]),E=(0,V.useMemo)(()=>{let e=[],t=!!d.trim(),n=(r,i)=>{if(!(!r||!Array.isArray(r)))for(let a of r){if(!a)continue;let r=!!(a.is_dir&&Array.isArray(a.children)&&a.children.length>0),o=m.has(a.id)||t&&S.has(a.id);e.push({node:a,depth:i,isExpanded:o,hasChildren:r}),a.is_dir&&o&&Array.isArray(a.children)&&n(a.children,i+1)}};return n(x,0),e},[x,m,d,S]);return(0,H.jsxs)(`div`,{className:`nav-tree-pane density-${a}`,"data-testid":`navigator-tree-container`,tabIndex:0,ref:v,onKeyDown:e=>{if(E.length!==0){if(e.key===`ArrowDown`)e.preventDefault(),_(e=>ee>0?e-1:E.length-1);else if(e.key===`ArrowRight`){if(e.preventDefault(),g>=0&&g=0&&g=0&&gf(e.target.value)}),d&&(0,H.jsx)(`button`,{type:`button`,className:`nav-tree-clear-btn`,onClick:()=>f(``),"aria-label":`Clear filter`,children:`✕`})]})]}),(0,H.jsx)(`div`,{className:`nav-tree-content`,children:o?(0,H.jsxs)(`div`,{className:`nav-loading-wrapper`,"data-testid":`tree-loading-spinner`,children:[(0,H.jsx)(`div`,{className:`nav-spinner`}),(0,H.jsx)(`span`,{children:`Loading codebase tree...`})]}):E.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`p`,{children:`No matching files found`}),d&&(0,H.jsx)(`button`,{type:`button`,className:`nav-clear-filter-btn`,onClick:()=>f(``),children:`Clear filter`})]}):(0,H.jsx)(`div`,{className:`nav-tree-list`,role:`tree`,children:E.map((e,r)=>{let{node:i,depth:a,isExpanded:o}=e,s=!i.is_dir&&i.path===t,c=r===g,l=o?`fa-solid fa-folder-open`:`fa-solid fa-folder`,{faClass:u,className:d}=i.is_dir?{faClass:l,className:`icon-dir`}:Ft(i.name,i.language);return(0,H.jsxs)(`div`,{role:`treeitem`,"aria-expanded":i.is_dir?o:void 0,"aria-selected":s,className:`nav-tree-item ${i.is_dir?`dir-item`:`file-item`} ${s?`selected`:``} ${c?`focused`:``}`,style:{paddingLeft:`${a*14+10}px`},onClick:()=>{_(r),i.is_dir?C(i.id):n(i)},children:[(0,H.jsx)(`span`,{className:`tree-chevron`,children:i.is_dir?(0,H.jsx)(`span`,{className:`chevron-arrow ${o?`open`:``}`,children:`▶`}):(0,H.jsx)(`span`,{className:`chevron-spacer`})}),(0,H.jsx)(`span`,{className:`tree-icon ${d}`,"aria-hidden":`true`,children:(0,H.jsx)(`i`,{className:u})}),(0,H.jsx)(`span`,{className:`tree-label`,title:i.path,children:i.name}),(0,H.jsxs)(`div`,{className:`tree-badges`,children:[i.symbol_count>0&&(0,H.jsxs)(`span`,{className:`badge-symbols`,title:`${i.symbol_count} AST Symbols`,children:[i.symbol_count,` sym`]}),i.route_count>0&&(0,H.jsxs)(`span`,{className:`badge-routes`,title:`${i.route_count} API Routes`,children:[i.route_count,` rts`]})]})]},i.id)})})})]})};function Lt(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Rt=Lt();function zt(e){Rt=e}var Bt={exec:()=>null};function Vt(e){let t=[];return n=>{let r=Math.max(0,Math.min(3,n-1)),i=t[r];return i||(i=e(r),t[r]=i),i}}function W(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(Ut.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var Ht=((e=``)=>{try{return!!RegExp(`(?<=1)(?/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:Vt(e=>RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:Vt(e=>RegExp(`^ {0,${e}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:Vt(e=>RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),headingBeginRegex:Vt(e=>RegExp(`^ {0,${e}}#`)),htmlBeginRegex:Vt(e=>RegExp(`^ {0,${e}}(?:)|<(?:script|pre|style|textarea|!--))`,`i`)),blockquoteBeginRegex:Vt(e=>RegExp(`^ {0,${e}}>`))},Wt=/^(?:[ \t]*(?:\n|$))+/,Gt=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,Kt=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,qt=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Jt=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Yt=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,Xt=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Zt=W(Xt).replace(/bull/g,Yt).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),Qt=W(Xt).replace(/bull/g,Yt).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),$t=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,en=/^[^\n]+/,tn=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,nn=W(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,tn).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),rn=W(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,Yt).getRegex(),an=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,on=/|$))/,sn=W(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|[^\\n]*\\n*|$)|[^\\n]*\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][a-z0-9-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,on).replace(`tag`,an).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),cn=e=>W($t).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,e).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex(),ln=cn(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),un=cn(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),dn={blockquote:W(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,un).getRegex(),code:Gt,def:nn,fences:Kt,heading:Jt,hr:qt,html:sn,lheading:Zt,list:rn,newline:Wt,paragraph:ln,table:Bt,text:en},fn=W(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex(),pn={...dn,lheading:Qt,table:fn,paragraph:W($t).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,fn).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]`).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex()},mn={...dn,html:W(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,on).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Bt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:W($t).replace(`hr`,qt).replace(`heading`,` *#{1,6} *[^ +]`).replace(`lheading`,Zt).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},hn=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,gn=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,_n=/^( {2,}|\\)\n(?!\s*$)[ \t]*/,vn=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,Ht?"(?`+)[^`]+\k(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),On=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,kn=W(On,`u`).replace(/punct/g,yn).getRegex(),An=W(On,`u`).replace(/punct/g,wn).getRegex(),jn=W(/^(?:\*+(?:((?!\*)(?!openQuote)punct)|([^\s*]))?)|^_+(?:((?!_)(?!openQuote)punct)|([^\s_]))?/,`u`).replace(/openQuote/g,Cn).replace(/punct/g,yn).getRegex(),Mn=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,Nn=W(Mn,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Pn=W(Mn,`gu`).replace(/notPunctSpace/g,En).replace(/punctSpace/g,Tn).replace(/punct/g,wn).getRegex(),Fn=W(`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)[\\s](\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|(?:(?!\\*)punct|notPunctSpace)(\\*+)(?!\\*)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),In=W(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Ln=W(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)[\\s](_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)|(?:(?!_)punct|notPunctSpace)(_+)(?!_)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Rn=W(/^~~?(?:((?!~)punct)|[^\s~])/,`u`).replace(/punct/g,yn).getRegex(),zn=W(`^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Bn=W(/\\(punct)/,`gu`).replace(/punct/g,yn).getRegex(),Vn=W(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Hn=W(on).replace(`(?:-->|$)`,`-->`).getRegex(),Un=W(`^comment|^|^<[a-zA-Z][a-zA-Z0-9-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^`).replace(`comment`,Hn).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Wn=/\[(?:\\[\s\S]|[^\[\]\\])*\]/,Gn=W(/(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/).replace(`brackets`,Wn).getRegex(),Kn=W(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace(`label`,Gn).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]+|(?=\))/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),qn=W(/^!?\[(label)\]\[(ref)\]/).replace(`label`,Gn).replace(`ref`,tn).getRegex(),Jn=W(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,tn).getRegex(),Yn=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\]){1,999}/,Xn=W(/(?:[^\[\]\\`]*(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\]))){0,999}?[^\[\]\\`]*?/).replace(`brackets`,Wn).getRegex(),Zn=W(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,W(/^!?\[(label)\]\[(ref)\]/).replace(`label`,Xn).replace(`ref`,Yn).getRegex()).replace(`nolink`,W(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,Yn).getRegex()).getRegex(),Qn=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,$n=W(/(?:mailto:email|xmpp:email(?:\/[A-Za-z0-9@.]+)?)/).replace(/email/g,/[A-Za-z0-9._+-]+@[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),er={_backpedal:Bt,anyPunctuation:Bn,autolink:Vn,blockSkip:Dn,br:_n,code:gn,del:Bt,delLDelim:Bt,delRDelim:Bt,emStrongLDelim:kn,emStrongRDelimAst:Nn,emStrongRDelimUnd:In,escape:hn,link:Kn,nolink:Jn,punctuation:Sn,reflink:qn,reflinkSearch:Zn,tag:Un,text:vn,url:Bt},tr={...er,emStrongLDelim:jn,emStrongRDelimAst:Fn,emStrongRDelimUnd:Ln,link:W(/^!?\[(label)\]\((.*?)\)/).replace(`label`,Gn).getRegex(),reflink:W(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,Gn).getRegex()},nr={...er,emStrongRDelimAst:Pn,emStrongLDelim:An,delLDelim:Rn,delRDelim:zn,url:W(/^emailProtocol|^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`emailProtocol`,$n).replace(`protocol`,Qn).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:W(/^(?:[^a-zA-Z0-9](?=emailProtocol)|(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":`>`,'"':`"`,"'":`'`},sr=e=>or[e];function cr(e,t){if(t){if(Ut.escapeTest.test(e))return e.replace(Ut.escapeReplace,sr)}else if(Ut.escapeTestNoEncode.test(e))return e.replace(Ut.escapeReplaceNoEncode,sr);return e}function lr(e){return e.replace(Ut.numericCharacterReference,(e,t,n)=>{let r=t===void 0?Number.parseInt(n,16):Number.parseInt(t,10);return r===0||r>1114111||r>=55296&&r<=57343?`�`:String.fromCodePoint(r)})}function ur(e){try{e=encodeURI(e).replace(Ut.percentDecode,`%`)}catch{return null}return e}function dr(e,t){let n=e.replace(Ut.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(Ut.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t){if(n.length>t)n.splice(t);else for(;n.length=0&&Ut.blankLine.test(t[n]);)n--;return t.length-n<=2?e:t.slice(0,n+1).join(` +`)}function mr(e){return e.trim().toLowerCase().toUpperCase().toLowerCase()}function hr(e,t){if(e.indexOf(t[1])===-1)return-1;let n=0;for(let r=0;r0?-2:-1}function gr(e,t=0){let n=t,r=``;for(let t of e)if(t===` `){let e=4-n%4;r+=` `.repeat(e),n+=e}else r+=t,n++;return r}function _r(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`),c=e[0].charAt(0)===`!`;r.state.inLink=!0;let l=r.state.linkEmitted,u=r.state.inRawBlock;r.state.linkEmitted=!1;let d=r.inlineTokens(s),f=r.state.linkEmitted;if(r.state.linkEmitted=l,r.state.inLink=!1,!c){if(f){r.state.inRawBlock=u;return}r.state.linkEmitted=!0}return{type:c?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:d}}function vr(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(` +`).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return e.slice(Math.min(r.length,i.length))}).join(` +`)}function yr(e,t,n,r){if(!t.includes(`<`))return!1;for(let i=0;it.length-i)return!0;i+=o[0].length-1}}return!1}var br=class{options;rules;lexer;constructor(e){this.options=e||Rt}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=this.options.pedantic?t[0]:pr(t[0]);return{type:`code`,raw:e,codeBlockStyle:`indented`,text:e.replace(this.rules.other.codeRemoveIndent,``)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=vr(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=fr(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceTabChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:fr(t[0],` +`),depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:fr(t[0],` +`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=fr(t[0],` +`).split(` +`),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o;for(o=0;o0&&(n=`${n} +${d.join(` +`)}`),r=r.substring(0,r.length-t.text.length)+s.text;break}if(u?.type===`list`){let t=u,a=t.raw+` +`+e.join(` +`),o=this.list(a);i[i.length-1]=o,n=n.substring(0,n.length-u.raw.length)+o.raw,r=r.substring(0,r.length-t.raw.length)+o.raw,e=a.substring(i.at(-1).raw.length).split(` +`);continue}}return{type:`blockquote`,raw:n,tokens:i,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=t[2].split(` +`,1)[0],l=t[1].length,u=this.options.pedantic?gr(c,l):c.replace(this.rules.other.leadingSpaceTab,e=>gr(e,l)),d=e.split(` +`,1)[0],f=!u.trim(),p=0;if(this.options.pedantic?(p=2,s=u.trimStart()):f?p=l+1:(p=u.search(this.rules.other.nonSpaceChar),p=p>4?1:p,s=u.slice(p),p+=l),f&&this.rules.other.blankLine.test(d)&&(r+=d+` +`,e=e.substring(d.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(p),n=this.rules.other.hrRegex(p),i=this.rules.other.fencesBeginRegex(p),a=this.rules.other.headingBeginRegex(p),o=this.rules.other.htmlBeginRegex(p),c=this.rules.other.blockquoteBeginRegex(p);for(;e;){let l=e.split(` +`,1)[0],m;if(d=l,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting,` `),m=d):m=d.replace(this.rules.other.leadingSpaceTab,e=>e.replace(this.rules.other.tabCharGlobal,` `)),i.test(d)||a.test(d)||o.test(d)||c.test(d)||t.test(d)||n.test(d))break;if(m.search(this.rules.other.nonSpaceChar)>=p||!d.trim())s+=` +`+m.slice(p);else{if(f||u.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(u)||a.test(u)||n.test(u))break;s+=` +`+d}f=!d.trim(),r+=l+` +`,e=e.substring(l.length+1),u=m.slice(p)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0)),i.items.push({type:`list_item`,raw:r,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e of i.items)if(this.lexer.state.top=!1,e.tokens=this.lexer.blockTokens(e.text,[]),!i.loose){let t=e.tokens.filter(e=>e.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}for(let e of i.items){let t=e.tokens[0];if(e.task&&(t?.type===`text`||t?.type===`paragraph`)){e.text=e.text.replace(this.rules.other.listReplaceTask,``),t.raw=t.raw.replace(this.rules.other.listReplaceTask,``),t.text=t.text.replace(this.rules.other.listReplaceTask,``);for(let e=this.lexer.inlineQueue.length-1;e>=0;e--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)){this.lexer.inlineQueue[e].src=this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask,``);break}let n=this.rules.other.listTaskCheckbox.exec(e.raw);if(n){let t={type:`checkbox`,raw:n[0]+` `,checked:n[0]!==`[ ]`};e.checked=t.checked,i.loose?e.tokens[0]&&[`paragraph`,`text`].includes(e.tokens[0].type)&&`tokens`in e.tokens[0]&&e.tokens[0].tokens?(e.tokens[0].raw=t.raw+e.tokens[0].raw,e.tokens[0].text=t.raw+e.tokens[0].text,e.tokens[0].tokens.unshift(t)):e.tokens.unshift({type:`paragraph`,raw:t.raw,text:t.raw,tokens:[t]}):e.tokens.unshift(t)}}else e.task&&=!1}if(i.loose)for(let e of i.items){e.loose=!0;for(let t of e.tokens)t.type===`text`&&(t.type=`paragraph`)}return i}}html(e){let t=this.rules.block.html.exec(e);if(t){let e=pr(t[0]);return{type:`html`,block:!0,raw:e,pre:t[1]===`pre`||t[1]===`script`||t[1]===`style`,text:e}}}def(e){let t=this.rules.block.def.exec(e);if(t){let e=mr(t[1]).replace(this.rules.other.multipleSpaceGlobal,` `),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,`$1`).replace(this.rules.inline.anyPunctuation,`$1`):``,r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,`$1`):t[3];return{type:`def`,tag:e,raw:fr(t[0],` +`),href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=dr(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,``).split(`|`),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,``).split(` +`):[],a={type:`table`,raw:fr(t[0],` +`),header:[],align:[],rows:[]};if(n.length===r.length){for(let e of r)this.rules.other.tableAlignRight.test(e)?a.align.push(`right`):this.rules.other.tableAlignCenter.test(e)?a.align.push(`center`):this.rules.other.tableAlignLeft.test(e)?a.align.push(`left`):a.align.push(null);for(let e=0;e({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t){let e=t[1].trim();return{type:`heading`,raw:fr(t[0],` +`),depth:t[2].charAt(0)===`=`?1:2,text:e,tokens:this.lexer.inline(e)}}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&yr(e,t[1],n,this.rules))return;let r=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let e=fr(r.slice(0,-1),`\\`);if((r.length-e.length)%2==0)return}else{let e=hr(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let i=t[2],a=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(i);e&&(i=e[1],a=e[3])}else a=t[3]?t[3].slice(1,-1):``;return i=i.trim(),this.rules.other.startAngleBracket.test(i)&&(i=this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?i.slice(1):i.slice(1,-1)),_r(t,{href:i&&i.replace(this.rules.inline.anyPunctuation,`$1`),title:a&&a.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let r=n[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&yr(e,n[1],r,this.rules))return;let i=t[mr((n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `))];if(!i){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return _r(n,i,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||!r[1]&&!r[2]&&!r[3]&&!r[4]||r[4]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[3])||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,a,o,s=i,c=0,l=r[0][0],u=n===l,d=l===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(d.lastIndex=0,t=t.slice(-1*e.length+i);(r=d.exec(t))!==null;){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(o=[...a].length,r[3]||r[4]){s+=o;continue}if(r[5]||r[6]){if(i%3&&!((i+o)%3)){c+=o;continue}if(u)break}if(s-=o,s>0)continue;o=Math.min(o,o+s+c);let t=[...r[0]][0].length,n=e.slice(0,i+r.index+t+o);if(Math.min(i,o)%2){let e=n.slice(1,-1);return{type:`em`,raw:n,text:e,tokens:this.lexer.inlineTokens(e)}}let l=n.slice(2,-2);return{type:`strong`,raw:n,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e,t,n=``){let r=this.rules.inline.delLDelim.exec(e);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=this.rules.inline.delRDelim;for(s.lastIndex=0,t=t.slice(-1*e.length+n);(r=s.exec(t))!==null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i||(a=[...i].length,a!==n))continue;if(r[3]||r[4]){o+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o);let t=[...r[0]][0].length,s=e.slice(0,n+r.index+t+a),c=s.slice(n,-n);return{type:`del`,raw:s,text:c,tokens:this.lexer.inlineTokens(c)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:e?t[0]:lr(t[0]),escaped:e}}}},xr=class e{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Rt,this.options.tokenizer=this.options.tokenizer||new br,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,linkEmitted:!1,top:!0};let t={other:Ut,block:ir.normal,inline:ar.normal};this.options.pedantic?(t.block=ir.pedantic,t.inline=ar.pedantic):this.options.gfm&&(t.block=ir.gfm,t.inline=this.options.breaks?ar.breaks:ar.gfm),this.tokenizer.rules=t}static get rules(){return{block:ir,inline:ar}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(Ut.carriageReturn,` +`),this.blockTokens(e,this.tokens);for(let e=0;e(i=n.call({lexer:this},e,t))?(e=e.substring(i.raw.length),t.push(i),!0):!1))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);let n=t.at(-1);i.raw.length===1&&n!==void 0?n.raw+=` +`:t.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.text,this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title},t.push(i));continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),t.push(i);continue}let a=e;if(this.options.extensions?.startBlock){let t=1/0,n=e.slice(1),r;this.options.extensions.startBlock.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(a=e.substring(0,t+1))}if(this.state.top&&(i=this.tokenizer.paragraph(a))){let r=t.at(-1);n&&r?.type===`paragraph`?(r.raw+=(r.raw.endsWith(` +`)?``:` +`)+i.raw,r.text+=` +`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(i),n=a.length!==e.length,e=e.substring(i.raw.length);continue}if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}linkInText(e){if(!e.includes(`[`))return!1;let t=this.tokenizer.rules.inline.link;for(let n of e.matchAll(this.tokenizer.rules.inline.blockSkip))if(t.test(n[0])&&e.charAt(n.index-1)!==`!`)return!0;for(let t of e.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let e=t[0],n=e.lastIndexOf(`[`);if(!(e.charAt(0)===`!`||!Object.hasOwn(this.tokens.links,mr(e.slice(n+1,-1))))&&!(n>1&&this.linkInText(e.slice(1,n-1))))return!0}return!1}inlineTokens(e,t=[]){this.tokenizer.lexer=this;let n=e;if(this.tokens.links&&e.includes(`[`)){let e=this.tokenizer.rules.inline.reflinkSearch,t=n=>{let r=n.lastIndexOf(`[`);if(!Object.hasOwn(this.tokens.links,mr(n.slice(r+1,-1))))return n;if(r>1&&n.charAt(0)!==`!`){let i=n.slice(1,r-1);if(this.linkInText(i))return`[`+i.replace(e,t)+`][`+`a`.repeat(n.length-r-2)+`]`}return`[`+`a`.repeat(n.length-2)+`]`};n=n.replace(e,t)}n=n.replace(this.tokenizer.rules.inline.anyPunctuation,e=>`+`.repeat(e.length)),n=n.replace(this.tokenizer.rules.inline.blockSkip,(e,t,n)=>{let r=n?n.length:0;return e.slice(0,r)+`[`+`a`.repeat(e.length-r-2)+`]`}),n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let r=!1,i=``,a=1/0;for(;e;){if(e.length(o=n.call({lexer:this},e,t))?(e=e.substring(o.raw.length),t.push(o),!0):!1))continue;if(o=this.tokenizer.escape(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.tag(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.link(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(o.raw.length);let n=t.at(-1);o.type===`text`&&n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(o=this.tokenizer.emStrong(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.codespan(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.br(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.del(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.autolink(e)){e=e.substring(o.raw.length),t.push(o);continue}if(!this.state.inLink&&(o=this.tokenizer.url(e))){e=e.substring(o.raw.length),t.push(o);continue}let s=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(o=this.tokenizer.inlineText(s)){e=e.substring(o.raw.length),o.raw.slice(-1)!==`_`&&(i=o.raw.slice(-1)),r=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return t}infiniteLoopError(e){let t=`Infinite loop on byte: `+e;if(this.options.silent)console.error(t);else throw Error(t)}},Sr=class{options;parser;constructor(e){this.options=e||Rt}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(Ut.notSpaceStart)?.[0],i=e?e.replace(Ut.endingNewline,``)+` +`:``;return r?`
    `+(n?i:cr(i,!0))+`
    +`:`
    `+(n?i:cr(i,!0))+`
    +`}blockquote({tokens:e}){return`
    +${this.parser.parse(e)}
    +`}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`${this.parser.parseInline(e)} +`}hr(e){return`
    +`}list(e){let t=e.ordered,n=e.start,r=``;for(let t=0;t +`+r+` +`}listitem(e){return`
  • ${this.parser.parse(e.tokens)}
  • +`}checkbox({checked:e}){return` `}paragraph({tokens:e}){return`

    ${this.parser.parseInline(e)}

    +`}table(e){let t=``,n=``;for(let t=0;t${r}`,` + +`+t+` +`+r+`
    +`}tablerow({text:e}){return` +${e} +`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+` +`}strong({tokens:e}){return`${this.parser.parseInline(e)}`}em({tokens:e}){return`${this.parser.parseInline(e)}`}codespan({text:e}){return`${cr(e,!0)}`}br(e){return`
    `}del({tokens:e}){return`${this.parser.parseInline(e)}`}link({href:e,title:t,text:n,tokens:r,autolink:i}){let a=i?cr(n,!0):this.parser.parseInline(r),o=ur(e);if(o===null)return a;e=cr(o,i);let s=`
    `+a+``,s}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=ur(e);if(i===null)return cr(n);e=i;let a=`${cr(n)}`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:cr(e.text)}},Cr=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}checkbox({raw:e}){return e}},wr=class e{options;renderer;textRenderer;constructor(e){this.options=e||Rt,this.options.renderer=this.options.renderer||new Sr,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Cr}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e){this.renderer.parser=this;let t=``;for(let n=0;n{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new Sr(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new br(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new Tr;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];t[r]=Tr.passThroughHooks.has(n)?e=>{if(this.defaults.async&&Tr.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return xr.lex(e,t??this.defaults)}parser(e,t){return wr.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer(e):e?xr.lex:xr.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser(e):e?wr.parse:wr.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer(e):e?xr.lex:xr.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser(e):e?wr.parse:wr.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=` +Please report this to https://github.com/markedjs/marked.`,e){let e=`

    An error occurred:

    `+cr(n.message+``,!0)+`
    `;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}},Dr=new Er;function Or(e,t){return Dr.parse(e,t)}Or.options=Or.setOptions=function(e){return Dr.setOptions(e),Or.defaults=Dr.defaults,zt(Or.defaults),Or},Or.getDefaults=Lt,Or.defaults=Rt;function kr(...e){return Dr.use(...e),Or.defaults=Dr.defaults,zt(Or.defaults),Or}Or.use=kr,Or.walkTokens=function(e,t){return Dr.walkTokens(e,t)},Or.parseInline=Dr.parseInline,Or.Parser=wr,Or.parser=wr.parse,Or.Renderer=Sr,Or.TextRenderer=Cr,Or.Lexer=xr,Or.lexer=xr.lex,Or.Tokenizer=br,Or.Hooks=Tr,Or.parse=Or,Or.options,Or.setOptions,Or.walkTokens,Or.parseInline,wr.parse,xr.lex;var Ar=a(e=>{let{securityLevel:t}=I(),n=r(`body`);if(t===`sandbox`){let t=r(`#i${e}`).node()?.contentDocument??document;n=r(t.body)}return n.select(`#${e}`)},`selectSvgElement`);function jr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,`default`)?e.default:e}a(jr,`getDefaultExportFromCjs`);var Mr={},Nr={},Pr={},Fr;function Ir(){if(Fr)return Pr;Fr=1;function e(e){return e==null}a(e,`isNothing`);function t(e){return typeof e==`object`&&!!e}a(t,`isObject`);function n(t){return Array.isArray(t)?t:e(t)?[]:[t]}a(n,`toArray`);function r(e,t){if(t){let n=Object.keys(t);for(let r=0,i=n.length;rs&&(a=` ... `,t=r-s+a.length),n-r>s&&(o=` ...`,n=r+s-o.length),{str:a+e.slice(t,n).replace(/\t/g,`→`)+o,pos:r-t+a.length}}a(t,`getLine`);function n(t,n){return e.repeat(` `,n-t.length)+t}a(n,`padStart`);function r(r,i){if(i=Object.create(i||null),!r.buffer)return null;i.maxLength||(i.maxLength=79),typeof i.indent!=`number`&&(i.indent=1),typeof i.linesBefore!=`number`&&(i.linesBefore=3),typeof i.linesAfter!=`number`&&(i.linesAfter=2);let a=/\r?\n|\r|\0/g,o=[0],s=[],c,l=-1;for(;c=a.exec(r.buffer);)s.push(c.index),o.push(c.index+c[0].length),r.position<=c.index&&l<0&&(l=o.length-2);l<0&&(l=o.length-1);let u=``,d=Math.min(r.line+i.linesAfter,s.length).toString().length,f=i.maxLength-(i.indent+d+3);for(let a=1;a<=i.linesBefore&&!(l-a<0);a++){let c=t(r.buffer,o[l-a],s[l-a],r.position-(o[l]-o[l-a]),f);u=e.repeat(` `,i.indent)+n((r.line-a+1).toString(),d)+` | `+c.str+` +`+u}let p=t(r.buffer,o[l],s[l],r.position,f);u+=e.repeat(` `,i.indent)+n((r.line+1).toString(),d)+` | `+p.str+` +`,u+=e.repeat(`-`,i.indent+d+3+p.pos)+`^ +`;for(let a=1;a<=i.linesAfter&&!(l+a>=s.length);a++){let c=t(r.buffer,o[l+a],s[l+a],r.position-(o[l]-o[l+a]),f);u+=e.repeat(` `,i.indent)+n((r.line+a+1).toString(),d)+` | `+c.str+` +`}return u.replace(/\n$/,``)}return a(r,`makeSnippet`),Br=r,Br}a(Hr,`requireSnippet`);var Ur,Wr;function Gr(){if(Wr)return Ur;Wr=1;let e=zr(),t=[`kind`,`multi`,`resolve`,`construct`,`instanceOf`,`predicate`,`represent`,`representName`,`defaultStyle`,`styleAliases`],n=[`scalar`,`sequence`,`mapping`];function r(e){let t={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(e){t[String(e)]=n})}),t}a(r,`compileStyleAliases`);function i(i,a){if(a||={},Object.keys(a).forEach(function(n){if(t.indexOf(n)===-1)throw new e(`Unknown option "`+n+`" is met in definition of "`+i+`" YAML type.`)}),this.options=a,this.tag=i,this.kind=a.kind||null,this.resolve=a.resolve||function(){return!0},this.construct=a.construct||function(e){return e},this.instanceOf=a.instanceOf||null,this.predicate=a.predicate||null,this.represent=a.represent||null,this.representName=a.representName||null,this.defaultStyle=a.defaultStyle||null,this.multi=a.multi||!1,this.styleAliases=r(a.styleAliases||null),n.indexOf(this.kind)===-1)throw new e(`Unknown kind "`+this.kind+`" is specified for "`+i+`" YAML type.`)}return a(i,`Type2`),Ur=i,Ur}a(Gr,`requireType`);var Kr,qr;function Jr(){if(qr)return Kr;qr=1;let e=zr(),t=Gr();function n(e,t){let n=[];return e[t].forEach(function(e){let t=n.length;n.forEach(function(n,r){n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=r)}),n[t]=e}),n}a(n,`compileList`);function r(){let e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function t(t){t.multi?(e.multi[t.kind].push(t),e.multi.fallback.push(t)):e[t.kind][t.tag]=e.fallback[t.tag]=t}a(t,`collectType`);for(let e=0,n=arguments.length;e=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}a(n,`isHexCode`);function r(e){return e>=48&&e<=55}a(r,`isOctCode`);function i(e){return e>=48&&e<=57}a(i,`isDecCode`);function o(e){if(e===null)return!1;let t=e.length,a=0,o=!1;if(!t)return!1;let c=e[a];if((c===`-`||c===`+`)&&(c=e[++a]),c===`0`){if(a+1===t)return!0;if(c=e[++a],c===`b`){for(a++;a=0?`0b`+e.toString(2):`-0b`+e.toString(2).slice(1)},`binary`),octal:a(function(e){return e>=0?`0o`+e.toString(8):`-0o`+e.toString(8).slice(1)},`octal`),decimal:a(function(e){return e.toString(10)},`decimal`),hexadecimal:a(function(e){return e>=0?`0x`+e.toString(16).toUpperCase():`-0x`+e.toString(16).toUpperCase().slice(1)},`hexadecimal`)},defaultStyle:`decimal`,styleAliases:{binary:[2,`bin`],octal:[8,`oct`],decimal:[10,`dec`],hexadecimal:[16,`hex`]}}),pi}a(hi,`requireInt`);var gi,_i;function vi(){if(_i)return gi;_i=1;let e=Ir(),t=Gr(),n=RegExp(`^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$`),r=RegExp(`^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$`);function i(e){return e===null||!n.test(e)?!1:isFinite(parseFloat(e,10))?!0:r.test(e)}a(i,`resolveYamlFloat`);function o(e){let t=e.toLowerCase(),n=t[0]===`-`?-1:1;return`+-`.indexOf(t[0])>=0&&(t=t.slice(1)),t===`.inf`?n===1?1/0:-1/0:t===`.nan`?NaN:n*parseFloat(t,10)}a(o,`constructYamlFloat`);let s=/^[-+]?[0-9]+e/;function c(t,n){if(isNaN(t))switch(n){case`lowercase`:return`.nan`;case`uppercase`:return`.NAN`;case`camelcase`:return`.NaN`}else if(t===1/0)switch(n){case`lowercase`:return`.inf`;case`uppercase`:return`.INF`;case`camelcase`:return`.Inf`}else if(t===-1/0)switch(n){case`lowercase`:return`-.inf`;case`uppercase`:return`-.INF`;case`camelcase`:return`-.Inf`}else if(e.isNegativeZero(t))return`-0.0`;let r=t.toString(10);return s.test(r)?r.replace(`e`,`.e`):r}a(c,`representYamlFloat`);function l(t){return Object.prototype.toString.call(t)===`[object Number]`&&(t%1!=0||e.isNegativeZero(t))}return a(l,`isFloat`),gi=new t(`tag:yaml.org,2002:float`,{kind:`scalar`,resolve:i,construct:o,predicate:l,represent:c,defaultStyle:`lowercase`}),gi}a(vi,`requireFloat`);var yi,bi;function xi(){return bi?yi:(bi=1,yi=oi().extend({implicit:[li(),fi(),hi(),vi()]}),yi)}a(xi,`requireJson`);var Si,Ci;function wi(){return Ci?Si:(Ci=1,Si=xi(),Si)}a(wi,`requireCore`);var Ti,Ei;function Di(){if(Ei)return Ti;Ei=1;let e=Gr(),t=RegExp(`^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$`),n=RegExp(`^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$`);function r(e){return e===null?!1:t.exec(e)!==null||n.exec(e)!==null}a(r,`resolveYamlTimestamp`);function i(e){let r=0,i=null,a=t.exec(e);if(a===null&&(a=n.exec(e)),a===null)throw Error(`Date resolve error`);let o=+a[1],s=a[2]-1,c=+a[3];if(!a[4])return new Date(Date.UTC(o,s,c));let l=+a[4],u=+a[5],d=+a[6];if(a[7]){for(r=a[7].slice(0,3);r.length<3;)r+=`0`;r=+r}if(a[9]){let e=+a[10],t=+(a[11]||0);i=(e*60+t)*6e4,a[9]===`-`&&(i=-i)}let f=new Date(Date.UTC(o,s,c,l,u,d,r));return i&&f.setTime(f.getTime()-i),f}a(i,`constructYamlTimestamp`);function o(e){return e.toISOString()}return a(o,`representYamlTimestamp`),Ti=new e(`tag:yaml.org,2002:timestamp`,{kind:`scalar`,resolve:r,construct:i,instanceOf:Date,represent:o}),Ti}a(Di,`requireTimestamp`);var Oi,G;function ki(){if(G)return Oi;G=1;let e=Gr();function t(e){return e===`<<`||e===null}return a(t,`resolveYamlMerge`),Oi=new e(`tag:yaml.org,2002:merge`,{kind:`scalar`,resolve:t}),Oi}a(ki,`requireMerge`);var Ai,ji;function Mi(){if(ji)return Ai;ji=1;let e=Gr();function t(e){if(e===null)return!1;let t=0,n=e.length;for(let r=0;r64)){if(n<0)return!1;t+=6}}return t%8==0}a(t,`resolveYamlBinary`);function n(e){let t=e.replace(/[\r\n=]/g,``),n=t.length,r=0,i=[];for(let e=0;e>16&255),i.push(r>>8&255),i.push(r&255)),r=r<<6|`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`.indexOf(t.charAt(e));let a=n%4*6;return a===0?(i.push(r>>16&255),i.push(r>>8&255),i.push(r&255)):a===18?(i.push(r>>10&255),i.push(r>>2&255)):a===12&&i.push(r>>4&255),new Uint8Array(i)}a(n,`constructYamlBinary`);function r(e){let t=``,n=0,r=e.length,i=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`;for(let a=0;a>18&63],t+=i[n>>12&63],t+=i[n>>6&63],t+=i[n&63]),n=(n<<8)+e[a];let a=r%3;return a===0?(t+=i[n>>18&63],t+=i[n>>12&63],t+=i[n>>6&63],t+=i[n&63]):a===2?(t+=i[n>>10&63],t+=i[n>>4&63],t+=i[n<<2&63],t+=i[64]):a===1&&(t+=i[n>>2&63],t+=i[n<<4&63],t+=i[64],t+=i[64]),t}a(r,`representYamlBinary`);function i(e){return Object.prototype.toString.call(e)===`[object Uint8Array]`}return a(i,`isBinary`),Ai=new e(`tag:yaml.org,2002:binary`,{kind:`scalar`,resolve:t,construct:n,predicate:i,represent:r}),Ai}a(Mi,`requireBinary`);var Ni,Pi;function Fi(){if(Pi)return Ni;Pi=1;let e=Gr(),t=Object.prototype.hasOwnProperty,n=Object.prototype.toString;function r(e){if(e===null)return!0;let r=[],i=e;for(let e=0,a=i.length;e=48&&e<=57)return e-48;let t=e|32;return t>=97&&t<=102?t-97+10:-1}a(g,`fromHexCode`);function _(e){return e===120?2:e===117?4:e===85?8:0}a(_,`escapedHexLen`);function v(e){return e>=48&&e<=57?e-48:-1}a(v,`fromDecimalCode`);function y(e){switch(e){case 48:return`\0`;case 97:return`\x07`;case 98:return`\b`;case 116:return` `;case 9:return` `;case 110:return` +`;case 118:return`\v`;case 102:return`\f`;case 114:return`\r`;case 101:return`\x1B`;case 32:return` `;case 34:return`"`;case 47:return`/`;case 92:return`\\`;case 78:return`…`;case 95:return`\xA0`;case 76:return`\u2028`;case 80:return`\u2029`;default:return``}}a(y,`simpleEscapeSequence`);function b(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}a(b,`charFromCodepoint`);function x(e,t,n){t===`__proto__`?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n}a(x,`setProperty`);let S=Array(256),C=Array(256);for(let e=0;e<256;e++)S[e]=+!!y(e),C[e]=y(e);function w(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||r,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.maxDepth=typeof t.maxDepth==`number`?t.maxDepth:100,this.maxTotalMergeKeys=typeof t.maxTotalMergeKeys==`number`?t.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}a(w,`State`);function T(e,r){let i={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return i.snippet=n(i),new t(r,i)}a(T,`generateError`);function E(e,t){throw T(e,t)}a(E,`throwError`);function D(e,t){e.onWarning&&e.onWarning.call(null,T(e,t))}a(D,`throwWarning`);function O(e,t,n){let r=e.anchorMapTransactions;if(r.length!==0){let n=r[r.length-1];i.call(n,t)||(n[t]={existed:i.call(e.anchorMap,t),value:e.anchorMap[t]})}e.anchorMap[t]=n}a(O,`storeAnchor`);function k(e){e.anchorMapTransactions.push(Object.create(null))}a(k,`beginAnchorTransaction`);function A(e){let t=e.anchorMapTransactions.pop(),n=e.anchorMapTransactions;if(n.length===0)return;let r=n[n.length-1],a=Object.keys(t);for(let e=0,n=a.length;e=0;--r){let i=t[n[r]];i.existed?e.anchorMap[n[r]]=i.value:delete e.anchorMap[n[r]]}}a(j,`rollbackAnchorTransaction`);function M(e){return{position:e.position,line:e.line,lineStart:e.lineStart,lineIndent:e.lineIndent,firstTabInLine:e.firstTabInLine,tag:e.tag,anchor:e.anchor,kind:e.kind,result:e.result}}a(M,`snapshotState`);function N(e,t){e.position=t.position,e.line=t.line,e.lineStart=t.lineStart,e.lineIndent=t.lineIndent,e.firstTabInLine=t.firstTabInLine,e.tag=t.tag,e.anchor=t.anchor,e.kind=t.kind,e.result=t.result}a(N,`restoreState`);let P={YAML:a(function(e,t,n){e.version!==null&&E(e,`duplication of %YAML directive`),n.length!==1&&E(e,`YAML directive accepts exactly one argument`);let r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]);r===null&&E(e,`ill-formed argument of the YAML directive`);let i=parseInt(r[1],10),a=parseInt(r[2],10);i!==1&&E(e,`unacceptable YAML version of the document`),e.version=n[0],e.checkLineBreaks=a<2,a!==1&&a!==2&&D(e,`unsupported YAML version of the document`)},`handleYamlDirective`),TAG:a(function(e,t,n){let r;n.length!==2&&E(e,`TAG directive accepts exactly two arguments`);let a=n[0];r=n[1],l.test(a)||E(e,`ill-formed tag handle (first argument) of the TAG directive`),i.call(e.tagMap,a)&&E(e,`there is a previously declared suffix for "`+a+`" tag handle`),u.test(r)||E(e,`ill-formed tag prefix (second argument) of the TAG directive`);try{r=decodeURIComponent(r)}catch{E(e,`tag prefix is malformed: `+r)}e.tagMap[a]=r},`handleTagDirective`)};function F(e,t,n,r){if(t=32&&n<=1114111||E(e,`expected valid JSON character`)}else o.test(i)&&E(e,`the stream contains non-printable characters`);e.result+=i}}a(F,`captureSegment`);function I(t,n,r,a){e.isObject(r)||E(t,`cannot merge mappings; the provided source object is unacceptable`);let o=Object.keys(r);for(let e=0,s=o.length;et.maxTotalMergeKeys&&E(t,`merge keys exceeded maxTotalMergeKeys (`+t.maxTotalMergeKeys+`)`),i.call(n,s)||(x(n,s,r[s]),a[s]=!0)}}a(I,`mergeMappings`);function L(e,t,n,r,a,o,s,c,l){if(Array.isArray(a)){a=Array.prototype.slice.call(a);for(let t=0,n=a.length;t1&&(t.result+=e.repeat(` +`,n-1))}a(ee,`writeFoldedLines`);function te(e,t,n){let r,i,a,o,s,c,l=e.kind,u=e.result,d=e.input.charCodeAt(e.position);if(m(d)||h(d)||d===35||d===38||d===42||d===33||d===124||d===62||d===39||d===34||d===37||d===64||d===96)return!1;if(d===63||d===45){let t=e.input.charCodeAt(e.position+1);if(m(t)||n&&h(t))return!1}for(e.kind=`scalar`,e.result=``,r=i=e.position,a=!1;d!==0;){if(d===58){let t=e.input.charCodeAt(e.position+1);if(m(t)||n&&h(t))break}else if(d===35){if(m(e.input.charCodeAt(e.position-1)))break}else if(e.position===e.lineStart&&B(e)||n&&h(d))break;else if(f(d)){if(o=e.line,s=e.lineStart,c=e.lineIndent,z(e,!1,-1),e.lineIndent>=t){a=!0,d=e.input.charCodeAt(e.position);continue}e.position=i,e.line=o,e.lineStart=s,e.lineIndent=c;break}a&&=(F(e,r,i,!1),ee(e,e.line-o),r=i=e.position,!1),p(d)||(i=e.position+1),d=e.input.charCodeAt(++e.position)}return F(e,r,i,!1),e.result?!0:(e.kind=l,e.result=u,!1)}a(te,`readPlainScalar`);function ne(e,t){let n,r,i=e.input.charCodeAt(e.position);if(i!==39)return!1;for(e.kind=`scalar`,e.result=``,e.position++,n=r=e.position;(i=e.input.charCodeAt(e.position))!==0;)if(i===39){if(F(e,n,e.position,!0),i=e.input.charCodeAt(++e.position),i===39)n=e.position,e.position++,r=e.position;else return!0}else f(i)?(F(e,n,r,!0),ee(e,z(e,!1,t)),n=r=e.position):e.position===e.lineStart&&B(e)?E(e,`unexpected end of the document within a single quoted scalar`):(e.position++,p(i)||(r=e.position));E(e,`unexpected end of the stream within a single quoted scalar`)}a(ne,`readSingleQuotedScalar`);function re(e,t){let n,r,i,a=e.input.charCodeAt(e.position);if(a!==34)return!1;for(e.kind=`scalar`,e.result=``,e.position++,n=r=e.position;(a=e.input.charCodeAt(e.position))!==0;)if(a===34)return F(e,n,e.position,!0),e.position++,!0;else if(a===92){if(F(e,n,e.position,!0),a=e.input.charCodeAt(++e.position),f(a))z(e,!1,t);else if(a<256&&S[a])e.result+=C[a],e.position++;else if((i=_(a))>0){let t=i,n=0;for(;t>0;t--)a=e.input.charCodeAt(++e.position),(i=g(a))>=0?n=(n<<4)+i:E(e,`expected hexadecimal character`);e.result+=b(n),e.position++}else E(e,`unknown escape sequence`);n=r=e.position}else f(a)?(F(e,n,r,!0),ee(e,z(e,!1,t)),n=r=e.position):e.position===e.lineStart&&B(e)?E(e,`unexpected end of the document within a double quoted scalar`):(e.position++,p(a)||(r=e.position));E(e,`unexpected end of the stream within a double quoted scalar`)}a(re,`readDoubleQuotedScalar`);function ie(e,t){let n=!0,r,i,a,o=e.tag,s,c=e.anchor,l,u,d,f,p=Object.create(null),h,g,_,v=e.input.charCodeAt(e.position);if(v===91)l=93,f=!1,s=[];else if(v===123)l=125,f=!0,s={};else return!1;for(e.anchor!==null&&O(e,e.anchor,s),v=e.input.charCodeAt(++e.position);v!==0;){if(z(e,!0,t),v=e.input.charCodeAt(e.position),v===l)return e.position++,e.tag=o,e.anchor=c,e.kind=f?`mapping`:`sequence`,e.result=s,!0;n?v===44&&E(e,`expected the node content, but found ','`):E(e,`missed comma between flow collection entries`),g=h=_=null,u=d=!1,v===63&&m(e.input.charCodeAt(e.position+1))&&(u=d=!0,e.position++,z(e,!0,t)),r=e.line,i=e.lineStart,a=e.position,fe(e,t,1,!1,!0),g=e.tag,h=e.result,z(e,!0,t),v=e.input.charCodeAt(e.position),(d||e.line===r)&&v===58&&(u=!0,v=e.input.charCodeAt(++e.position),z(e,!0,t),fe(e,t,1,!1,!0),_=e.result),f?L(e,s,p,g,h,_,r,i,a):u?s.push(L(e,null,p,g,h,_,r,i,a)):s.push(h),z(e,!0,t),v=e.input.charCodeAt(e.position),v===44?(n=!0,v=e.input.charCodeAt(++e.position)):n=!1}E(e,`unexpected end of the stream within a flow collection`)}a(ie,`readFlowCollection`);function ae(t,n){let r,i=1,a=!1,o=!1,s=n,c=0,l=!1,u,d=t.input.charCodeAt(t.position);if(d===124)r=!1;else if(d===62)r=!0;else return!1;for(t.kind=`scalar`,t.result=``;d!==0;)if(d=t.input.charCodeAt(++t.position),d===43||d===45)i===1?i=d===43?3:2:E(t,`repeat of a chomping mode identifier`);else if((u=v(d))>=0)u===0?E(t,`bad explicit indentation width of a block scalar; it cannot be less than one`):o?E(t,`repeat of an indentation width identifier`):(s=n+u-1,o=!0);else break;if(p(d)){do d=t.input.charCodeAt(++t.position);while(p(d));if(d===35)do d=t.input.charCodeAt(++t.position);while(!f(d)&&d!==0)}for(;d!==0;){for(R(t),t.lineIndent=0,d=t.input.charCodeAt(t.position);(!o||t.lineIndents&&(s=t.lineIndent),f(d)){c++;continue}if(!o&&s===0&&E(t,`missing indentation for block scalar`),t.lineIndentt)&&o!==0)E(e,`bad indentation of a sequence entry`);else if(e.lineIndentt)&&(g&&(i=e.line,a=e.lineStart,o=e.position),fe(e,t,4,!0,r)&&(g?f=e.result:h=e.result),g||(L(e,l,u,d,f,h,i,a,o),d=f=h=null),z(e,!0,-1),v=e.input.charCodeAt(e.position)),(e.line===b||e.lineIndent>t)&&v!==0)E(e,`bad indentation of a mapping entry`);else if(e.lineIndent=e.maxDepth&&E(e,`nesting exceeded maxDepth (`+e.maxDepth+`)`),e.depth+=1,e.listener!==null&&e.listener(`open`,e),e.tag=null,e.anchor=null,e.kind=null,e.result=null;let h=o=s=n===4||n===3;if(r&&z(e,!0,-1)&&(l=!0,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndentt?c=1:e.lineIndent===t?c=0:e.lineIndent tag; it should be "scalar", not "`+e.kind+`"`);for(let t=0,n=e.implicitTypes.length;t`),e.result!==null&&f.kind!==e.kind&&E(e,`unacceptable node kind for !<`+e.tag+`> tag; it should be "`+f.kind+`", not "`+e.kind+`"`),f.resolve(e.result,e.tag)?(e.result=f.construct(e.result,e.tag),e.anchor!==null&&O(e,e.anchor,e.result)):E(e,`cannot resolve a node with !<`+e.tag+`> explicit tag`)}return e.listener!==null&&e.listener(`close`,e),--e.depth,e.tag!==null||e.anchor!==null||u}a(fe,`composeNode`);function pe(e){let t=e.position,n=!1,r;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(r=e.input.charCodeAt(e.position))!==0&&(z(e,!0,-1),r=e.input.charCodeAt(e.position),!(e.lineIndent>0||r!==37));){n=!0,r=e.input.charCodeAt(++e.position);let t=e.position;for(;r!==0&&!m(r);)r=e.input.charCodeAt(++e.position);let a=e.input.slice(t,e.position),o=[];for(a.length<1&&E(e,`directive name must not be less than one character in length`);r!==0;){for(;p(r);)r=e.input.charCodeAt(++e.position);if(r===35){do r=e.input.charCodeAt(++e.position);while(r!==0&&!f(r));break}if(f(r))break;for(t=e.position;r!==0&&!m(r);)r=e.input.charCodeAt(++e.position);o.push(e.input.slice(t,e.position))}r!==0&&R(e),i.call(P,a)?P[a](e,a,o):D(e,`unknown document directive "`+a+`"`)}if(z(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,z(e,!0,-1)):n&&E(e,`directives end mark is expected`),fe(e,e.lineIndent-1,4,!1,!0),z(e,!0,-1),e.checkLineBreaks&&s.test(e.input.slice(t,e.position))&&D(e,`non-ASCII line breaks are interpreted as content`),e.documents.push(e.result),e.position===e.lineStart&&B(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,z(e,!0,-1));return}e.position=32&&e<=126||e>=161&&e<=55295&&e!==8232&&e!==8233||e>=57344&&e<=65533&&e!==o||e>=65536&&e<=1114111}a(_,`isPrintable`);function v(e){return _(e)&&e!==o&&e!==13&&e!==10}a(v,`isNsCharOrWhitespace`);function y(e,t,n){let r=v(e),i=r&&!g(e);return(n?r:r&&e!==44&&e!==91&&e!==93&&e!==123&&e!==125)&&e!==35&&!(t===58&&!i)||v(t)&&!g(t)&&e===35||t===58&&i}a(y,`isPlainSafe`);function b(e){return _(e)&&e!==o&&!g(e)&&e!==45&&e!==63&&e!==58&&e!==44&&e!==91&&e!==93&&e!==123&&e!==125&&e!==35&&e!==38&&e!==42&&e!==33&&e!==124&&e!==61&&e!==62&&e!==39&&e!==34&&e!==37&&e!==64&&e!==96}a(b,`isPlainSafeFirst`);function x(e){return!g(e)&&e!==58}a(x,`isPlainSafeLast`);function S(e,t){let n=e.charCodeAt(t),r;return n>=55296&&n<=56319&&t+1=56320&&r<=57343)?(n-55296)*1024+r-56320+65536:n}a(S,`codePointAt`);function C(e){return/^\n* /.test(e)}a(C,`needIndentIndicator`);function w(e,t,n,r,i,a,o,s){let c,l=0,u=null,d=!1,f=!1,p=r!==-1,m=-1,h=b(S(e,0))&&x(S(e,e.length-1));if(t||o)for(c=0;c=65536?c+=2:c++){if(l=S(e,c),!_(l))return 5;h&&=y(l,u,s),u=l}else{for(c=0;c=65536?c+=2:c++){if(l=S(e,c),l===10)d=!0,p&&(f||=c-m-1>r&&e[m+1]!==` `,m=c);else if(!_(l))return 5;h&&=y(l,u,s),u=l}f||=p&&c-m-1>r&&e[m+1]!==` `}return!d&&!f?h&&!o&&!i(e)?1:a===2?5:2:n>9&&C(e)?5:o?a===2?5:2:f?4:3}a(w,`chooseScalarStyle`);function T(e,n,r,i,o){e.dump=(function(){if(n.length===0)return e.quotingType===2?`""`:`''`;if(!e.noCompatMode&&(c.indexOf(n)!==-1||l.test(n)))return e.quotingType===2?`"`+n+`"`:`'`+n+`'`;let s=e.indent*Math.max(1,r),u=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-s),d=i||e.flowLevel>-1&&r>=e.flowLevel;function f(t){return h(e,t)}switch(a(f,`testAmbiguity`),w(n,d,e.indent,u,f,e.quotingType,e.forceQuotes&&!i,o)){case 1:return n;case 2:return`'`+n.replace(/'/g,`''`)+`'`;case 3:return`|`+E(n,e.indent)+D(p(n,s));case 4:return`>`+E(n,e.indent)+D(p(O(n,u),s));case 5:return`"`+A(n)+`"`;default:throw new t(`impossible error: invalid scalar style`)}})()}a(T,`writeScalar`);function E(e,t){let n=C(e)?String(t):``,r=e[e.length-1]===` +`;return n+(r&&(e[e.length-2]===` +`||e===` +`)?`+`:r?``:`-`)+` +`}a(E,`blockHeader`);function D(e){return e[e.length-1]===` +`?e.slice(0,-1):e}a(D,`dropEndingNewline`);function O(e,t){let n=/(\n+)([^\n]*)/g,r=(function(){let r=e.indexOf(` +`);return r=r===-1?e.length:r,n.lastIndex=r,k(e.slice(0,r),t)})(),i=e[0]===` +`||e[0]===` `,a,o;for(;o=n.exec(e);){let e=o[1],n=o[2];a=n[0]===` `,r+=e+(!i&&!a&&n!==``?` +`:``)+k(n,t),i=a}return r}a(O,`foldString`);function k(e,t){if(e===``||e[0]===` `)return e;let n=/ [^ ]/g,r,i=0,a,o=0,s=0,c=``;for(;r=n.exec(e);)s=r.index,s-i>t&&(a=o>i?o:s,c+=` +`+e.slice(i,a),i=a+1),o=s;return c+=` +`,e.length-i>t&&o>i?c+=e.slice(i,o)+` +`+e.slice(o+1):c+=e.slice(i),c.slice(1)}a(k,`foldLine`);function A(e){let t=``,n=0;for(let r=0;r=65536?r+=2:r++){n=S(e,r);let i=s[n];!i&&_(n)?(t+=e[r],n>=65536&&(t+=e[r+1])):t+=i||d(n)}return t}a(A,`escapeString`);function j(e,t,n){let r=``,i=e.tag;for(let i=0,a=n.length;i1024&&(o+=`? `),o+=e.dump+(e.condenseFlow?`"`:``)+`:`+(e.condenseFlow?``:` `),I(e,t,c,!1,!1)&&(o+=e.dump,r+=o))}e.tag=i,e.dump=`{`+r+`}`}a(N,`writeFlowMapping`);function P(e,n,r,i){let a=``,o=e.tag,s=Object.keys(r);if(e.sortKeys===!0)s.sort();else if(typeof e.sortKeys==`function`)s.sort(e.sortKeys);else if(e.sortKeys)throw new t(`sortKeys must be a boolean or a function`);for(let t=0,o=s.length;t1024;u&&(e.dump&&e.dump.charCodeAt(0)===10?o+=`?`:o+=`? `),o+=e.dump,u&&(o+=m(e,n)),I(e,n+1,l,!0,u)&&(e.dump&&e.dump.charCodeAt(0)===10?o+=`:`:o+=`: `,o+=e.dump,a+=o)}e.tag=o,e.dump=a||`{}`}a(P,`writeBlockMapping`);function F(e,n,a){let o=a?e.explicitTypes:e.implicitTypes;for(let s=0,c=o.length;s tag resolver accepts not "`+a+`" style`);e.dump=o}return!0}}return!1}a(F,`detectType`);function I(e,n,i,a,o,s,c){e.tag=null,e.dump=i,F(e,i,!1)||F(e,i,!0);let l=r.call(e.dump),u=a;a&&=e.flowLevel<0||e.flowLevel>n;let d=l===`[object Object]`||l===`[object Array]`,f,p;if(d&&(f=e.duplicates.indexOf(i),p=f!==-1),(e.tag!==null&&e.tag!==`?`||p||e.indent!==2&&n>0)&&(o=!1),p&&e.usedDuplicates[f])e.dump=`*ref_`+f;else{if(d&&p&&!e.usedDuplicates[f]&&(e.usedDuplicates[f]=!0),l===`[object Object]`)a&&Object.keys(e.dump).length!==0?(P(e,n,e.dump,o),p&&(e.dump=`&ref_`+f+e.dump)):(N(e,n,e.dump),p&&(e.dump=`&ref_`+f+` `+e.dump));else if(l===`[object Array]`)a&&e.dump.length!==0?(e.noArrayIndent&&!c&&n>0?M(e,n-1,e.dump,o):M(e,n,e.dump,o),p&&(e.dump=`&ref_`+f+e.dump)):(j(e,n,e.dump),p&&(e.dump=`&ref_`+f+` `+e.dump));else if(l===`[object String]`)e.tag!==`?`&&T(e,e.dump,n,s,u);else if(l===`[object Undefined]`)return!1;else{if(e.skipInvalid)return!1;throw new t(`unacceptable kind of an object to dump `+l)}if(e.tag!==null&&e.tag!==`?`){let t=encodeURI(e.tag[0]===`!`?e.tag.slice(1):e.tag).replace(/!/g,`%21`);t=e.tag[0]===`!`?`!`+t:t.slice(0,18)===`tag:yaml.org,2002:`?`!!`+t.slice(18):`!<`+t+`>`,e.dump=t+` `+e.dump}}return!0}a(I,`writeNode`);function L(e,t){let n=[],r=[];R(e,n,r);let i=r.length;for(let e=0;e{let{theme:n,themeVariables:r}=t,{useGradient:i,gradientStart:o,gradientStop:s}=r??{},c=e.attr(`id`),l=n?.includes(`dark`)?`#FFFFFF`:`#000000`,u=a((t,n,r)=>e.append(`defs`).append(`filter`).attr(`id`,t).attr(`height`,n).attr(`width`,n).append(`feDropShadow`).attr(`dx`,r).attr(`dy`,r).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,l),`dropShadow`);if(u(`${c}-drop-shadow`,`130%`,`4`),u(`${c}-drop-shadow-small`,`150%`,`2`),!i)return;let d=e.append(`linearGradient`).attr(`id`,`${c}-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);d.append(`svg:stop`).attr(`offset`,`0%`).attr(`stop-color`,o).attr(`stop-opacity`,1),d.append(`svg:stop`).attr(`offset`,`100%`).attr(`stop-color`,s).attr(`stop-opacity`,1)},`insertLookDefs`);function pa(e){let t=e?.constructor;return e===(typeof t==`function`?t.prototype:Object.prototype)}function ma(e){if(e==null)return!0;if(ve(e))return typeof e.splice!=`function`&&typeof e!=`string`&&!ee(e)&&!_e(e)&&!ye(e)?!1:e.length===0;if(typeof e==`object`||typeof e==`function`){if(e instanceof Map||e instanceof Set)return e.size===0;let t=Object.keys(e);return pa(e)?t.filter(e=>e!==`constructor`).length===0:t.length===0}return!0}var ha=a(async(e,t)=>{let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,d=l,{labelStyles:f,nodeStyles:p,borderStyles:m,backgroundStyles:h}=Se(t),g=e.insert(`g`).attr(`class`,`cluster swimlane `+(t.cssClasses||``)).attr(`id`,t.id).attr(`data-id`,t.id).attr(`data-et`,`cluster`).attr(`data-look`,t.look);ke(g,t.colorIndex,a,u);let _=E(i.flowchart.htmlLabels),v=t.direction===`LR`,y=g.insert(`g`).attr(`class`,`cluster-label swimlane-label`),b=await De(y,t.label,{style:t.labelStyle,useHtmlLabels:_,isNode:!0,width:t.width}),x=b.getBBox();if(_){let e=b.children[0],t=r(b);x=e.getBoundingClientRect(),t.attr(`width`,x.width),t.attr(`height`,x.height)}let S=t.padding??0,C=t.width<=x.width+S?x.width+S:t.width;t.diff=t.width<=x.width+S?(C-t.width)/2-S:-S;let w=t.height,T=t.y-w/2,D=t.y+w/2,O=t.x-C/2,k=t.swimlaneContentTop===void 0?T+w/3:t.swimlaneContentTop,A=v?4:0,j=x.height+2*A,M,N;if(v){let e=Math.max(j,x.height+2*A),n=O+e,r=Math.max(0,C-e);if(t.look===`handDrawn`){let i=Ae.svg(g),a=xe(t,{roughness:.7,fill:c,stroke:d,seed:s}),o=xe(t,{roughness:.7,fill:`none`,stroke:d,seed:s}),l=i.rectangle(O,T,e,w,a);M=g.insert(()=>l,`:first-child`).attr(`class`,`swimlane-title`);let u=i.rectangle(n,T,r,w,o);N=g.insert(()=>u,`:first-child`).attr(`class`,`swimlane-body`),M.select(`path:nth-child(2)`).attr(`style`,m.join(`;`)),M.select(`path`).attr(`style`,h.join(`;`).replace(`fill`,`stroke`))}else M=g.insert(`rect`,`:first-child`),N=g.insert(`rect`,`:first-child`),M.attr(`class`,`swimlane-title`).attr(`style`,p).attr(`x`,O).attr(`y`,T).attr(`width`,e).attr(`height`,w).attr(`fill`,c).attr(`stroke`,d),N.attr(`class`,`swimlane-body`).attr(`style`,p).attr(`x`,n).attr(`y`,T).attr(`width`,r).attr(`height`,w).attr(`fill`,`none`).attr(`stroke`,d);let i=O+e/2,a=t.y;y.attr(`transform`,`translate(${i}, ${a}) rotate(-90) translate(${-x.width/2}, ${-x.height/2})`)}else{let e=Math.max(0,k-T),n=Math.min(j,e),r=T+n,i=Math.max(0,D-r),a=t.x-C/2;if(t.look===`handDrawn`){let e=Ae.svg(g),o=xe(t,{roughness:.7,fill:c,stroke:d,fillWeight:3,seed:s}),l=xe(t,{roughness:.7,fill:`none`,stroke:d,seed:s}),u=e.rectangle(a,T,C,n,o);M=g.insert(()=>u,`:first-child`).attr(`class`,`swimlane-title`);let f=e.rectangle(a,r,C,i,l);N=g.insert(()=>f,`:first-child`).attr(`class`,`swimlane-body`),M.select(`path:nth-child(2)`).attr(`style`,m.join(`;`)),M.select(`path`).attr(`style`,h.join(`;`).replace(`fill`,`stroke`))}else M=g.insert(`rect`,`:first-child`),N=g.insert(`rect`,`:first-child`),M.attr(`class`,`swimlane-title`).attr(`style`,p).attr(`x`,a).attr(`y`,T).attr(`width`,C).attr(`height`,n).attr(`fill`,c).attr(`stroke`,d),N.attr(`class`,`swimlane-body`).attr(`style`,p).attr(`x`,a).attr(`y`,r).attr(`width`,C).attr(`height`,i).attr(`fill`,`none`).attr(`stroke`,d);let o=t.x-x.width/2,l=T+(n-x.height)/2;y.attr(`transform`,`translate(${o}, ${l})`)}if(n.trace(`Swimlane data `,t,JSON.stringify(t)),f){let e=y.select(`span`);e&&e.attr(`style`,f)}return t.offsetX=0,t.width=C,t.height=w,t.offsetY=x.height-S/2,t.intersect=function(e){return je(t,e)},{cluster:g,labelBBox:x}},`swimlane`),ga=a(async(e,t)=>{n.info(`Creating subgraph rect for `,t.id,t);let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,{labelStyles:d,nodeStyles:f,borderStyles:p,backgroundStyles:m}=Se(t),h=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look);ke(h,t.colorIndex,a,u);let g=_(i),v=h.insert(`g`).attr(`class`,`cluster-label `),y;y=t.labelType===`markdown`?await De(v,t.label,{style:t.labelStyle,useHtmlLabels:g,isNode:!0,width:t.width}):await Pe(v,t.label,t.labelStyle||``,!1,!0);let b=y.getBBox();if(_(i)){let e=y.children[0],t=r(y);b=e.getBoundingClientRect(),t.attr(`width`,b.width),t.attr(`height`,b.height)}let x=t.width<=b.width+t.padding?b.width+t.padding:t.width;t.diff=t.width<=b.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let S=t.height,C=t.x-x/2,w=t.y-S/2;n.trace(`Data `,t,JSON.stringify(t));let T;if(t.look===`handDrawn`){let e=Ae.svg(h),r=xe(t,{roughness:.7,fill:c,stroke:l,fillWeight:3,seed:s}),i=e.path(Me(C,w,x,S,0),r);T=h.insert(()=>(n.debug(`Rough node insert CXC`,i),i),`:first-child`),T.select(`path:nth-child(2)`).attr(`style`,p.join(`;`)),T.select(`path`).attr(`style`,m.join(`;`).replace(`fill`,`stroke`))}else T=h.insert(`rect`,`:first-child`),T.attr(`style`,f).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,C).attr(`y`,w).attr(`width`,x).attr(`height`,S);let{subGraphTitleTopMargin:E}=Fe(i);if(v.attr(`transform`,`translate(${t.x-b.width/2}, ${t.y-t.height/2+E})`),d){let e=v.select(`span`);e&&e.attr(`style`,d)}let D=T.node().getBBox();return t.offsetX=0,t.width=D.width,t.height=D.height,t.offsetY=b.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:h,labelBBox:b}},`rect`),_a=a((e,t)=>{let n=e.insert(`g`).attr(`class`,`note-cluster`).attr(`id`,t.domId),r=n.insert(`rect`,`:first-child`),i=0*t.padding,a=i/2;r.attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,t.x-t.width/2-a).attr(`y`,t.y-t.height/2-a).attr(`width`,t.width+i).attr(`height`,t.height+i).attr(`fill`,`none`);let o=r.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(e){return je(t,e)},{cluster:n,labelBBox:{width:0,height:0}}},`noteGroup`),va=a(async(e,t)=>{let n=I(),{theme:i,themeVariables:a,handDrawnSeed:o}=n,{altBackground:s,borderColorArray:c,compositeBackground:l,compositeTitleBackground:u,nodeBorder:d}=a,f=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-id`,t.id).attr(`data-look`,t.look);ke(f,t.colorIndex,i,c);let p=f.insert(`g`,`:first-child`),m=f.insert(`g`).attr(`class`,`cluster-label`),h=f.append(`rect`),g=await Pe(m,t.label,t.labelStyle,void 0,!0),v=g.getBBox();if(_(n)){let e=g.children[0],t=r(g);v=e.getBoundingClientRect(),t.attr(`width`,v.width),t.attr(`height`,v.height)}let y=0*t.padding,b=y/2,x=(t.width<=v.width+t.padding?v.width+t.padding:t.width)+y;t.diff=t.width<=v.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let S=t.height+y,C=t.height+y-v.height-6,w=t.x-x/2,T=t.y-S/2;t.width=x;let E=t.y-t.height/2-b+v.height+2,D;if(t.look===`handDrawn`){let e=t.cssClasses.includes(`statediagram-cluster-alt`),n=Ae.svg(f),r=t.rx||t.ry?n.path(Me(w,T,x,S,10),{roughness:.7,fill:u,fillStyle:`solid`,stroke:d,seed:o}):n.rectangle(w,T,x,S,{seed:o});D=f.insert(()=>r,`:first-child`);let i=n.rectangle(w,E,x,C,{fill:e?s:l,fillStyle:e?`hachure`:`solid`,stroke:d,seed:o});D=f.insert(()=>r,`:first-child`),h=f.insert(()=>i),D.attr(`class`,`outer`),h.attr(`class`,`inner`)}else D=p.insert(`rect`,`:first-child`),D.attr(`class`,`outer`).attr(`x`,w).attr(`y`,T).attr(`width`,x).attr(`height`,S).attr(`data-look`,t.look),h.attr(`class`,`inner`).attr(`x`,w).attr(`y`,E).attr(`width`,x).attr(`height`,C);return m.attr(`transform`,`translate(${t.x-v.width/2}, ${T+1-(_(n)?0:3)})`),t.height=D.node().getBBox().height,t.offsetX=0,t.offsetY=v.height-t.padding/2,t.labelBBox=v,t.intersect=function(e){return je(t,e)},{cluster:f,labelBBox:v}},`roundedWithTitle`),ya=a(async(e,t)=>{n.info(`Creating subgraph rect for `,t.id,t);let i=I(),{themeVariables:a,handDrawnSeed:o}=i,{clusterBkg:s,clusterBorder:c}=a,{labelStyles:l,nodeStyles:u,borderStyles:d,backgroundStyles:f}=Se(t),p=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),m=_(i),h=p.insert(`g`).attr(`class`,`cluster-label `),g=await De(h,t.label,{style:t.labelStyle,useHtmlLabels:m,isNode:!0,width:t.width}),v=g.getBBox();if(_(i)){let e=g.children[0],t=r(g);v=e.getBoundingClientRect(),t.attr(`width`,v.width),t.attr(`height`,v.height)}let y=t.width<=v.width+t.padding?v.width+t.padding:t.width;t.diff=t.width<=v.width+t.padding?(y-t.width)/2-t.padding:-t.padding;let b=t.height,x=t.x-y/2,S=t.y-b/2;n.trace(`Data `,t,JSON.stringify(t));let C;if(t.look===`handDrawn`){let e=Ae.svg(p),r=xe(t,{roughness:.7,fill:s,stroke:c,fillWeight:4,seed:o}),i=e.path(Me(x,S,y,b,t.rx),r);C=p.insert(()=>(n.debug(`Rough node insert CXC`,i),i),`:first-child`),C.select(`path:nth-child(2)`).attr(`style`,d.join(`;`)),C.select(`path`).attr(`style`,f.join(`;`).replace(`fill`,`stroke`))}else C=p.insert(`rect`,`:first-child`),C.attr(`style`,u).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,x).attr(`y`,S).attr(`width`,y).attr(`height`,b);let{subGraphTitleTopMargin:w}=Fe(i);if(h.attr(`transform`,`translate(${t.x-v.width/2}, ${t.y-t.height/2+w})`),l){let e=h.select(`span`);e&&e.attr(`style`,l)}let T=C.node().getBBox();return t.offsetX=0,t.width=T.width,t.height=T.height,t.offsetY=v.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:p,labelBBox:v}},`kanbanSection`),ba=a((e,t)=>{let{theme:n,themeVariables:r,handDrawnSeed:i}=I(),{altBackground:a,nodeBorder:o,borderColorArray:s}=r,c=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look);ke(c,t.colorIndex,n,s);let l=c.insert(`g`,`:first-child`),u=0*t.padding,d=t.width+u;t.diff=-t.padding;let f=t.height+u,p=t.x-d/2,m=t.y-f/2;t.width=d;let h;if(t.look===`handDrawn`){let e=Ae.svg(c).rectangle(p,m,d,f,{fill:a??`#efefef`,fillStyle:`solid`,roughness:.5,strokeLineDash:[5],stroke:o,seed:i});h=c.insert(()=>e,`:first-child`).attr(`class`,`divider`)}else{h=l.insert(`rect`,`:first-child`);let e=`outer`;e=(t.look,`divider`),h.attr(`class`,e).attr(`x`,p).attr(`y`,m).attr(`width`,d).attr(`height`,f).attr(`data-look`,t.look)}return t.height=h.node().getBBox().height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return je(t,e)},{cluster:c,labelBBox:{}}},`divider`),xa=a(async(e,t,i)=>{n.info(`Creating ${i.cssClass} for `,t.id,t);let a=I(),{theme:o,themeVariables:s,handDrawnSeed:c}=a,{borderColorArray:l}=s,{labelStyles:u,borderStyles:d}=Se(t),f=e.insert(`g`).attr(`class`,`cluster `+i.cssClass+` `+t.cssClasses).attr(`id`,t.domId??t.id).attr(`data-look`,t.look);ke(f,t.colorIndex,o,l);let p=_(a),m=f.insert(`g`).attr(`class`,`cluster-label`),h={width:0,height:0},g=t.label?.trim();if(g){let e;if(e=t.labelType===`markdown`?await De(m,t.label,{style:t.labelStyle,useHtmlLabels:p,isNode:!0,width:t.width}):await Pe(m,t.label,t.labelStyle||``,!1,!0),h=e.getBBox(),p){let t=e.children[0],n=r(e);h=t.getBoundingClientRect(),n.attr(`width`,h.width),n.attr(`height`,h.height)}}let v=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(v-t.width)/2-t.padding:-t.padding;let y=t.height,b=t.x-v/2,x=t.y-y/2,S;if(t.look===`handDrawn`){let e=Ae.svg(f),n=xe(t,{roughness:i.roughness,fill:i.fill,stroke:i.stroke,strokeWidth:i.strokeWidth,seed:c,...i.fill===`none`?{fillWeight:0}:{fillStyle:`solid`},...i.strokeDash?{strokeLineDash:i.strokeDash}:{}}),r=e.path(Me(b,x,v,y,i.rx),n);S=f.insert(()=>r,`:first-child`),S.select(`path:nth-child(2)`).attr(`style`,d.join(`;`))}else S=f.insert(`rect`,`:first-child`),S.attr(`rx`,i.rx).attr(`ry`,i.rx).attr(`x`,b).attr(`y`,x).attr(`width`,v).attr(`height`,y).attr(`fill`,i.fill).attr(`stroke`,i.stroke).attr(`stroke-width`,i.strokeWidth+`px`),i.strokeDash&&S.attr(`stroke-dasharray`,i.strokeDash.join(`, `));if(g){let{subGraphTitleTopMargin:e}=Fe(a);if(m.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+e})`),u){let e=m.select(`span`);e&&e.attr(`style`,u)}}let C=S.node().getBBox();return t.offsetX=0,t.width=C.width,t.height=C.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:f,labelBBox:h}},`createContainerGroup`),Sa=a(async(e,t)=>{let{themeVariables:n}=I();return xa(e,t,{cssClass:`flow-cluster`,rx:10,fill:`none`,stroke:n.flowContainerStroke||n.secondaryBorderColor,strokeWidth:.75,roughness:.7})},`flowGroup`),Ca=a((e,t)=>{let n=e.boundaryType||`rect`,r=n===`package`?20:e.padding,i=n===`package`?t.height+10:0,a=Math.max(e.width,t.width+r),o=n===`package`?Math.max(e.height,i+e.padding*2):e.height,s=e.x-a/2,c=e.y-o/2;return{boundaryType:n,width:a,height:o,x:s,y:c,bodyY:c+i,bodyHeight:o-i,tabHeight:i,tabWidth:n===`package`?Math.min(a,Math.max(80,t.width+20)):0}},`getUsecaseSystemBoundaryGeometry`),wa={rect:ga,squareRect:ga,roundedWithTitle:va,noteGroup:_a,divider:ba,kanbanSection:ya,flowGroup:Sa,usecaseSystemBoundary:a(async(e,t)=>{n.info(`Creating usecase system boundary for `,t.id,t);let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,{labelStyles:d,nodeStyles:f}=Se(t),{stylesMap:p}=we(t),m=t.boundaryType||`rect`,h=e.insert(`g`).attr(`class`,`cluster usecase-system-boundary usecase-system-boundary-${m} ${t.cssClasses}`).attr(`id`,typeof t.domId==`string`?t.domId:t.id).attr(`data-boundary-type`,m).attr(`data-look`,t.look);ke(h,t.colorIndex,a,u);let g=_(i),v=h.insert(`g`).attr(`class`,`cluster-label system-boundary-title`),y=await De(v,t.label,{style:d,useHtmlLabels:g,isNode:!0}),b=y.getBBox();if(g){let e=y.children[0],t=r(y);b=e.getBoundingClientRect(),t.attr(`width`,b.width),t.attr(`height`,b.height)}let{width:x,height:S,x:C,y:w,bodyY:T,bodyHeight:E,tabHeight:D,tabWidth:O}=Ca(t,b);t.diff=t.width<=b.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let k=xe(t,{fill:p.get(`fill`)||c,stroke:p.get(`stroke`)||l,strokeWidth:p.get(`stroke-width`)?.replace(`px`,``)||1,seed:s});if(t.look===`handDrawn`){let e=Ae.svg(h),t=e.rectangle(C,T,x,E,k);if(h.insert(()=>t,`:first-child`).attr(`class`,`boundary-body label-container`),m===`package`){let t=e.rectangle(C,w,O,D,k);h.insert(()=>t,`:first-child`).attr(`class`,`boundary-tab system-boundary-package-tab label-container`)}}else h.insert(`rect`,`:first-child`).attr(`class`,`boundary-body label-container`).attr(`style`,f).attr(`x`,C).attr(`y`,T).attr(`width`,x).attr(`height`,E),m===`package`&&h.insert(`rect`,`:first-child`).attr(`class`,`boundary-tab system-boundary-package-tab label-container`).attr(`style`,f).attr(`x`,C).attr(`y`,w).attr(`width`,O).attr(`height`,D);let{subGraphTitleTopMargin:A}=Fe(i);return m===`package`?v.attr(`transform`,`translate(${C+(O-b.width)/2}, ${w+(D-b.height)/2})`):v.attr(`transform`,`translate(${t.x-b.width/2}, ${w+A})`),d&&(v.attr(`style`,d),v.select(`span`).attr(`style`,d)),t.offsetX=0,t.width=x,t.height=S,t.offsetY=b.height-t.padding/2,t.labelBBox=b,t.intersect=function(e){return je(t,e)},{cluster:h,labelBBox:b}},`usecaseSystemBoundary`),swimlane:ha},Ta=new Set([`noteGroup`,`divider`]),Ea=a(e=>!Ta.has(e??`rect`),`clusterPaintsTitle`),Da=new Map,Oa=a(async(e,t)=>{let n=await wa[t.shape||`rect`](e,t);return Da.set(t.id,n),n},`insertCluster`),ka=a(()=>{Da=new Map},`clear`),Aa=a((e,t)=>{if(t)return`translate(`+-e.width/2+`, `+-e.height/2+`)`;let n=e.x??0,r=e.y??0;return`translate(`+-(n+e.width/2)+`, `+-(r+e.height/2)+`)`},`computeLabelTransform`),ja={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},Ma={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function Na(e,t){if(e===void 0||t===void 0)return{angle:0,deltaX:0,deltaY:0};e=K(e),t=K(t);let[n,r]=[e.x,e.y],[i,a]=[t.x,t.y],o=i-n,s=a-r;return{angle:Math.atan(s/o),deltaX:o,deltaY:s}}a(Na,`calculateDeltaAndAngle`);var K=a(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,`pointTransformer`),Pa=a(e=>({x:a(function(t,n,r){let i=0,a=K(r[0]).x=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(ja,e.arrowTypeEnd)){let{angle:t,deltaX:n}=Na(r[r.length-1],r[r.length-2]);i=ja[e.arrowTypeEnd]*Math.cos(t)*(n>=0?1:-1)}let o=Math.abs(K(t).x-K(r[r.length-1]).x),s=Math.abs(K(t).y-K(r[r.length-1]).y),c=Math.abs(K(t).x-K(r[0]).x),l=Math.abs(K(t).y-K(r[0]).y),u=ja[e.arrowTypeStart],d=ja[e.arrowTypeEnd];if(o0&&s0&&l=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(ja,e.arrowTypeEnd)){let{angle:t,deltaY:n}=Na(r[r.length-1],r[r.length-2]);i=ja[e.arrowTypeEnd]*Math.abs(Math.sin(t))*(n>=0?1:-1)}let o=Math.abs(K(t).y-K(r[r.length-1]).y),s=Math.abs(K(t).x-K(r[r.length-1]).x),c=Math.abs(K(t).y-K(r[0]).y),l=Math.abs(K(t).x-K(r[0]).x),u=ja[e.arrowTypeStart],d=ja[e.arrowTypeEnd];if(o0&&s0&&l{t.arrowTypeStart&&Ra(e,`start`,t.arrowTypeStart,n,r,i,a,o),t.arrowTypeEnd&&Ra(e,`end`,t.arrowTypeEnd,n,r,i,a,o)},`addEdgeMarkers`),Ia={arrow_cross:{type:`cross`,fill:!1},arrow_point:{type:`point`,fill:!0},arrow_barb:{type:`barb`,fill:!0},arrow_barb_neo:{type:`barb`,fill:!0},arrow_circle:{type:`circle`,fill:!1},arrow_hierarchy:{type:`hierarchy`,fill:!1},aggregation:{type:`aggregation`,fill:!1},extension:{type:`extension`,fill:!1},composition:{type:`composition`,fill:!0},dependency:{type:`dependency`,fill:!0},lollipop:{type:`lollipop`,fill:!1},only_one:{type:`onlyOne`,fill:!1},zero_or_one:{type:`zeroOrOne`,fill:!1},one_or_more:{type:`oneOrMore`,fill:!1},zero_or_more:{type:`zeroOrMore`,fill:!1},requirement_arrow:{type:`requirement_arrow`,fill:!1},requirement_contains:{type:`requirement_contains`,fill:!1}},La=[`cross`,`point`,`circle`,`lollipop`,`aggregation`,`extension`,`composition`,`dependency`,`barb`],Ra=a((e,t,r,i,a,o,s=!1,c)=>{if(!r||r===`none`)return;let l=Ia[r],u=l&&La.includes(l.type);if(!l){n.warn(`Unknown arrow type: ${r}`);return}let d=`${a}_${o}-${l.type}${t===`start`?`Start`:`End`}${s&&u?`-margin`:``}`;if(c&&c.trim()!==``){let n=`${d}_${c.replace(/[^\dA-Za-z]/g,`_`)}`;if(!document.getElementById(n)){let e=document.getElementById(d);if(e){let t=e.cloneNode(!0);t.id=n,t.querySelectorAll(`path, circle, line`).forEach(e=>{e.setAttribute(`stroke`,c),l.fill&&e.setAttribute(`fill`,c)}),e.parentNode?.appendChild(t)}}e.attr(`marker-${t}`,`url(${i}#${n})`)}else e.attr(`marker-${t}`,`url(${i}#${d})`)},`addEdgeMarker`),za=a(e=>typeof e==`string`?e:I()?.flowchart?.curve,`resolveEdgeCurveType`),Ba=new Map,Va=new Map,Ha=a(()=>{Ba.clear(),Va.clear()},`clear`),Ua=a(e=>!!(e.label||e.startLabelLeft||e.startLabelRight||e.endLabelLeft||e.endLabelRight),`hasEdgeLabel`),Wa=a(e=>e?typeof e==`string`?e:e.reduce((e,t)=>e+`;`+t,``):``,`getLabelStyles`),Ga=a(async(e,t)=>{let i=I(),a=_(i),{labelStyles:o}=Se(t);t.labelStyle=o;let s=e.insert(`g`).attr(`class`,`edgeLabel`),c=s.insert(`g`).attr(`class`,`label`).attr(`data-id`,t.id),l=t.labelType===`markdown`,u=await De(e,t.label,{style:Wa(t.labelStyle),useHtmlLabels:a,addSvgBackground:!0,isNode:!1,markdown:l,width:void 0},i);c.node().appendChild(u),n.info(`abc82`,t,t.labelType);let d,f;if(a){let e=u.children[0],t=r(u);d=await Oe.measure(()=>e.getBoundingClientRect()),f=d,t.attr(`width`,d.width),t.attr(`height`,d.height)}else{let e=r(u).select(`text`).node();await Oe.measure(()=>{d=u.getBBox(),f=e&&typeof e.getBBox==`function`?e.getBBox():d})}c.attr(`transform`,Aa(f,a)),Ba.set(t.id,s),t.width=d.width,t.height=d.height;let p;if(t.startLabelLeft){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(i,t.startLabelLeft,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).startLeft=n,Ka(p,t.startLabelLeft)}if(t.startLabelRight){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(i,t.startLabelRight,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).startRight=n,Ka(p,t.startLabelRight)}if(t.endLabelLeft){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(n,t.endLabelLeft,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).endLeft=n,Ka(p,t.endLabelLeft)}if(t.endLabelRight){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(n,t.endLabelRight,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).endRight=n,Ka(p,t.endLabelRight)}return u},`insertEdgeLabel`);function Ka(e,t){_(I())&&e&&(e.style.width=t.length*9+`px`,e.style.height=`12px`)}a(Ka,`setTerminalWidth`);var qa=a((e,t)=>{n.debug(`Moving label abc88 `,e.id,e.label,Ba.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath,i=I(),{subGraphTitleTotalMargin:a}=Fe(i);if(e.label){let i=Ba.get(e.id),o=e.x,s=e.y;if(r){let i=ce.calcLabelPosition(r);n.debug(`Moving label `+e.label+` from (`,o,`,`,s,`) to (`,i.x,`,`,i.y,`) abc88`),t.updatedPath&&(o=i.x,s=i.y)}i.attr(`transform`,`translate(${o}, ${s+a/2})`)}if(e.startLabelLeft){let t=Va.get(e.id).startLeft,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_left`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.startLabelRight){let t=Va.get(e.id).startRight,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_right`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.endLabelLeft){let t=Va.get(e.id).endLeft,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_left`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.endLabelRight){let t=Va.get(e.id).endRight,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_right`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}},`positionEdgeLabel`),Ja=a((e,t)=>{if(!e?.isLabelEdge||!e?.id?.endsWith(`-to-label`)||!Array.isArray(t)||t.length!==2)return t;let[n,r]=t,i=Math.abs(r.x-n.x),a=Math.abs(r.y-n.y);return i<.001||a<.001?t:a>=i?[n,{x:n.x,y:r.y},r]:[n,{x:r.x,y:n.y},r]},`orthogonalizeToLabelClippedPoints`),Ya=a((e,t)=>{let n=e.x,r=e.y,i=Math.abs(t.x-n),a=Math.abs(t.y-r),o=e.width/2,s=e.height/2;return i>=o||a>=s},`outsideNode`),Xa=a((e,t,r)=>{n.debug(`intersection calc abc89: + outsidePoint: ${JSON.stringify(t)} + insidePoint : ${JSON.stringify(r)} + node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);let i=e.x,a=e.y,o=Math.abs(i-r.x),s=e.width/2,c=r.xMath.abs(i-t.x)*l){let e=r.y{n.warn(`abc88 cutPathAtIntersect`,e,t);let r=[],i=e[0],a=!1;return e.forEach(e=>{if(n.info(`abc88 checking point`,e,t),!Ya(t,e)&&!a){let o=Xa(t,i,e);n.debug(`abc88 inside`,e,i,o),n.debug(`abc88 intersection`,o,t);let s=!1;r.forEach(e=>{s||=e.x===o.x&&e.y===o.y}),r.some(e=>e.x===o.x&&e.y===o.y)?n.warn(`abc88 no intersect`,o,r):r.push(o),a=!0}else n.warn(`abc88 outside`,e,i),i=e,a||r.push(e)}),n.debug(`returning points`,r),r},`cutPathAtIntersect`);function Qa(e){let t=[],n=[];for(let r=1;r5&&Math.abs(a.y-i.y)>5||i.y===a.y&&a.x===o.x&&Math.abs(a.x-i.x)>5&&Math.abs(a.y-o.y)>5)&&(t.push(a),n.push(r))}return{cornerPoints:t,cornerPointPositions:n}}a(Qa,`extractCornerPoints`);var $a=a(function(e,t,n){let r=t.x-e.x,i=t.y-e.y,a=n/Math.sqrt(r*r+i*i);return{x:t.x-a*r,y:t.y-a*i}},`findAdjacentPoint`),eo=a(function(e){let{cornerPointPositions:t}=Qa(e),r=[];for(let i=0;i10&&Math.abs(a.y-t.y)>=10?(n.debug(`Corner point fixing`,Math.abs(a.x-t.x),Math.abs(a.y-t.y)),f=o.x===s.x?{x:l<0?s.x-5+d:s.x+5-d,y:u<0?s.y-d:s.y+d}:{x:l<0?s.x-d:s.x+d,y:u<0?s.y-5+d:s.y+5-d}):n.debug(`Corner point skipping fixing`,Math.abs(a.x-t.x),Math.abs(a.y-t.y)),r.push(f,c)}else r.push(e[i]);return r},`fixCorners`),to=a((e,t,n)=>{let r=e-t-n,i=Math.floor(r/4);return`0 ${t} ${Array(Number.isFinite(i)?Math.max(0,i):0).fill(`2 2`).join(` `)} ${n}`},`generateDashArray`),no=a(function(e,t,i,a,o,s,c,l=!1){if(!c)throw Error(`insertEdge: missing diagramId for edge "${t.id}" \u2014 edge IDs require a diagram prefix for uniqueness`);let{handDrawnSeed:u,layout:d}=I(),f=t.points,p=!1,m=o;var h=s;let g=[];for(let e in t.cssCompiledStyles)Ce(e)||g.push(t.cssCompiledStyles[e]);if(d===`swimlane`){if(h.intersect&&m.intersect&&Array.isArray(f)&&f.length>=2){if(f.length===2)f=[m.intersect(f[0]),h.intersect(f[1])];else{let e=f.slice(1,-1),t=e[0],n=e[e.length-1],r=.5,i=Math.abs(f[f.length-1].x-n.x)!Number.isNaN(e.y)),y=za(t.curve);y!==`rounded`&&(v=eo(v));let b=me;switch(y){case`linear`:b=me;break;case`basis`:b=oe;break;case`cardinal`:b=L;break;case`bumpX`:b=he;break;case`bumpY`:b=de;break;case`catmullRom`:b=B;break;case`monotoneX`:b=te;break;case`monotoneY`:b=re;break;case`natural`:b=ne;break;case`step`:b=R;break;case`stepAfter`:b=z;break;case`stepBefore`:b=pe;break;case`rounded`:b=me;break;default:b=oe}let{x,y:S}=Pa(t),C=be().x(x).y(S).curve(b),w;switch(t.thickness){case`normal`:w=`edge-thickness-normal`;break;case`thick`:w=`edge-thickness-thick`;break;case`invisible`:w=`edge-thickness-invisible`;break;default:w=`edge-thickness-normal`}switch(t.pattern){case`solid`:w+=` edge-pattern-solid`;break;case`dotted`:w+=` edge-pattern-dotted`;break;case`dashed`:w+=` edge-pattern-dashed`;break;default:w+=` edge-pattern-solid`}let T,E=y===`rounded`?ro(ao(v,t),5):C(v),D=Array.isArray(t.style)?t.style:[t.style],O=D.find(e=>e?.startsWith(`stroke:`)),k=``;t.animate&&(k=`edge-animation-fast`),t.animation&&(k=`edge-animation-`+t.animation);let A=!1;if(t.look===`handDrawn`){let n=Ae.svg(e);Object.assign([],v);let i=n.path(E,{roughness:.3,seed:u});w+=` transition`,T=r(i).select(`path`).attr(`id`,`${c}-${t.id}`).attr(`class`,` `+w+(t.classes?` `+t.classes:``)+(k?` `+k:``)).attr(`style`,D?D.reduce((e,t)=>e+`;`+t,``):``);let a=T.attr(`d`);T.attr(`d`,a),e.node().appendChild(T.node())}else{let n=g.join(`;`),r=D?D.reduce((e,t)=>e+t+`;`,``):``,i=(n?n+`;`+r+`;`:r)+`;`+(D?D.reduce((e,t)=>e+`;`+t,``):``);T=e.append(`path`).attr(`d`,E).attr(`id`,`${c}-${t.id}`).attr(`class`,` `+w+(t.classes?` `+t.classes:``)+(k?` `+k:``)).attr(`style`,i),O=i.match(/stroke:([^;]+)/)?.[1],A=t.animate===!0||!!t.animation||n.includes(`animation`);let a=T.node(),o=typeof a.getTotalLength==`function`?a.getTotalLength():0,s=Ma[t.arrowTypeStart]||0,l=Ma[t.arrowTypeEnd]||0;if(t.look===`neo`&&!A){let e=`stroke-dasharray: ${t.pattern===`dotted`||t.pattern===`dashed`?to(o,s,l):`0 ${s} ${o-s-l} ${l}`}; stroke-dashoffset: 0;`;T.attr(`style`,e+T.attr(`style`))}}T.attr(`data-edge`,!0),T.attr(`data-et`,`edge`),T.attr(`data-id`,t.id),T.attr(`data-points`,_),T.attr(`data-look`,ge(t.look)),t.showPoints&&v.forEach(t=>{e.append(`circle`).style(`stroke`,`red`).style(`fill`,`red`).attr(`r`,1).attr(`cx`,t.x).attr(`cy`,t.y)});let j=``;(I().flowchart.arrowMarkerAbsolute||I().state.arrowMarkerAbsolute)&&(j=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,j=j.replace(/\(/g,`\\(`).replace(/\)/g,`\\)`)),n.info(`arrowTypeStart`,t.arrowTypeStart),n.info(`arrowTypeEnd`,t.arrowTypeEnd);let M=!A&&t?.look===`neo`;Fa(T,t,j,c,a,M,O);let N=Math.floor(f.length/2),P=f[N];ce.isLabelCoordinateInPath(P,T.attr(`d`))||(p=!0);let F={};return p&&(F.updatedPath=f),F.originalPath=t.points,F},`insertEdge`);function ro(e,t){if(e.length<2)return``;let n=``,r=e.length,i=1e-5;for(let a=0;a({...e}));if(e.length>=2&&ja[t.arrowTypeStart]){let r=ja[t.arrowTypeStart],i=e[0],a=e[1],{angle:o}=io(i,a),s=r*Math.cos(o),c=r*Math.sin(o);n[0].x=i.x+s,n[0].y=i.y+c}let r=e.length;if(r>=2&&ja[t.arrowTypeEnd]){let i=ja[t.arrowTypeEnd],a=e[r-1],o=e[r-2],{angle:s}=io(o,a),c=i*Math.cos(s),l=i*Math.sin(s);n[r-1].x=a.x-c,n[r-1].y=a.y-l}return n}a(ao,`applyMarkerOffsetsToPoints`);var q=a((e,t,n,r)=>{t.forEach(t=>{oo[t](e,n,r)})},`insertMarkers`),oo={extension:a((e,t,r)=>{n.trace(`Making markers for `,r),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionStart`).attr(`class`,`marker extension `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 1,7 L18,13 V 1 Z`),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionEnd`).attr(`class`,`marker extension `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 1,1 V 13 L18,7 Z`),e.append(`marker`).attr(`id`,r+`_`+t+`-extensionStart-margin`).attr(`class`,`marker extension `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`viewBox`,`0 0 20 14`).append(`polygon`).attr(`points`,`10,7 18,13 18,1`).style(`stroke-width`,2).style(`stroke-dasharray`,`0`),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionEnd-margin`).attr(`class`,`marker extension `+t).attr(`refX`,9).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`viewBox`,`0 0 20 14`).append(`polygon`).attr(`points`,`10,1 10,13 18,7`).style(`stroke-width`,2).style(`stroke-dasharray`,`0`)},`extension`),composition:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionStart`).attr(`class`,`marker composition `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionEnd`).attr(`class`,`marker composition `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionStart-margin`).attr(`class`,`marker composition `+t).attr(`refX`,15).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`viewBox`,`0 0 15 15`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionEnd-margin`).attr(`class`,`marker composition `+t).attr(`refX`,3.5).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`)},`composition`),aggregation:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationStart`).attr(`class`,`marker aggregation `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationEnd`).attr(`class`,`marker aggregation `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationStart-margin`).attr(`class`,`marker aggregation `+t).attr(`refX`,15).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,2).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationEnd-margin`).attr(`class`,`marker aggregation `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,2).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`)},`aggregation`),dependency:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyStart`).attr(`class`,`marker dependency `+t).attr(`refX`,6).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 5,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyEnd`).attr(`class`,`marker dependency `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyStart-margin`).attr(`class`,`marker dependency `+t).attr(`refX`,4).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 5,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyEnd-margin`).attr(`class`,`marker dependency `+t).attr(`refX`,16).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`dependency`),lollipop:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopStart`).attr(`class`,`marker lollipop `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopEnd`).attr(`class`,`marker lollipop `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopStart-margin`).attr(`class`,`marker lollipop `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6).attr(`stroke-width`,2),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopEnd-margin`).attr(`class`,`marker lollipop `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6).attr(`stroke-width`,2)},`lollipop`),point:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-pointEnd`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,5).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,8).attr(`markerHeight`,8).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointStart`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,4.5).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,8).attr(`markerHeight`,8).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 5 L 10 10 L 10 0 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointEnd-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 11.5 14`).attr(`refX`,11.5).attr(`refY`,7).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,10.5).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 11.5 7 L 0 14 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointStart-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 11.5 14`).attr(`refX`,1).attr(`refY`,7).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11.5).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`polygon`).attr(`points`,`0,7 11.5,14 11.5,0`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`)},`point`),circle:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-circleEnd`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,11).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleStart`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,-1).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleEnd-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refY`,5).attr(`refX`,12.25).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,14).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleStart-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,-2).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,14).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`)},`circle`),cross:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-crossEnd`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 11 11`).attr(`refX`,12).attr(`refY`,5.2).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 l 9,9 M 10,1 l -9,9`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-crossStart`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 11 11`).attr(`refX`,-1).attr(`refY`,5.2).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 l 9,9 M 10,1 l -9,9`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-crossEnd-margin`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 15 15`).attr(`refX`,17.7).attr(`refY`,7.5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 L 14,14 M 1,14 L 14,1`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2.5),e.append(`marker`).attr(`id`,n+`_`+t+`-crossStart-margin`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 15 15`).attr(`refX`,-3.5).attr(`refY`,7.5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 L 14,14 M 1,14 L 14,1`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2.5).style(`stroke-dasharray`,`1,0`)},`cross`),barb:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd`).attr(`refX`,19).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L9,13 L14,7 L9,1 Z`)},`barb`),barbNeo:a((e,t,n)=>{let{themeVariables:r}=S(),{transitionColor:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd`).attr(`refX`,19).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`strokeWidth`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L11,14 L13,7 L11,0 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd-margin`).attr(`refX`,17).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L11,14 L13,7 L11,0 Z`).attr(`fill`,`${i}`)},`barbNeo`),hierarchy:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-hierarchyEnd`).attr(`class`,`marker hierarchy `+t).attr(`viewBox`,`0 0 12 10`).attr(`refX`,10).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,10).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 6 5 L 0 10 M 4 0 L 10 5 L 4 10`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`).style(`fill`,`none`),e.append(`marker`).attr(`id`,n+`_`+t+`-hierarchyStart`).attr(`class`,`marker hierarchy `+t).attr(`viewBox`,`0 0 12 10`).attr(`refX`,2).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,10).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 12 0 L 6 5 L 12 10 M 8 0 L 2 5 L 8 10`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`).style(`fill`,`none`)},`hierarchy`),only_one:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneStart`).attr(`class`,`marker onlyOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).append(`path`).attr(`d`,`M9,0 L9,18 M15,0 L15,18`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneEnd`).attr(`class`,`marker onlyOne `+t).attr(`refX`,18).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,0 L3,18 M9,0 L9,18`)},`only_one`),zero_or_one:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneStart`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`);r.append(`circle`).attr(`fill`,`white`).attr(`cx`,21).attr(`cy`,9).attr(`r`,6),r.append(`path`).attr(`d`,`M9,0 L9,18`);let i=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneEnd`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,30).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`);i.append(`circle`).attr(`fill`,`white`).attr(`cx`,9).attr(`cy`,9).attr(`r`,6),i.append(`path`).attr(`d`,`M21,0 L21,18`)},`zero_or_one`),one_or_more:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreStart`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).append(`path`).attr(`d`,`M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreEnd`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,27).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18`)},`one_or_more`),zero_or_more:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreStart`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`);r.append(`circle`).attr(`fill`,`white`).attr(`cx`,48).attr(`cy`,18).attr(`r`,6),r.append(`path`).attr(`d`,`M0,18 Q18,0 36,18 Q18,36 0,18`);let i=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreEnd`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,39).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`);i.append(`circle`).attr(`fill`,`white`).attr(`cx`,9).attr(`cy`,18).attr(`r`,6),i.append(`path`).attr(`d`,`M21,18 Q39,0 57,18 Q39,36 21,18`)},`zero_or_more`),only_one_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneStart`).attr(`class`,`marker onlyOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M9,0 L9,18 M15,0 L15,18`).attr(`stroke-width`,`${i}`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneEnd`).attr(`class`,`marker onlyOne `+t).attr(`refX`,18).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M3,0 L3,18 M9,0 L9,18`).attr(`stroke-width`,`${i}`)},`only_one_neo`),zero_or_one_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i,mainBkg:a}=r,o=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneStart`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`);o.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,21).attr(`cy`,9).attr(`stroke-width`,`${i}`).attr(`r`,6),o.append(`path`).attr(`d`,`M9,0 L9,18`).attr(`stroke-width`,`${i}`);let s=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneEnd`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,30).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`);s.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,9).attr(`cy`,9).attr(`stroke-width`,`${i}`).attr(`r`,6),s.append(`path`).attr(`d`,`M21,0 L21,18`).attr(`stroke-width`,`${i}`)},`zero_or_one_neo`),one_or_more_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreStart`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27`).attr(`stroke-width`,`${i}`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreEnd`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,27).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18`).attr(`stroke-width`,`${i}`)},`one_or_more_neo`),zero_or_more_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i,mainBkg:a}=r,o=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreStart`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`);o.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,45.5).attr(`cy`,18).attr(`r`,6).attr(`stroke-width`,`${i}`),o.append(`path`).attr(`d`,`M0,18 Q18,0 36,18 Q18,36 0,18`).attr(`stroke-width`,`${i}`);let s=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreEnd`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,39).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`);s.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,11).attr(`cy`,18).attr(`r`,6).attr(`stroke-width`,`${i}`),s.append(`path`).attr(`d`,`M21,18 Q39,0 57,18 Q39,36 21,18`).attr(`stroke-width`,`${i}`)},`zero_or_more_neo`),requirement_arrow:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_arrowEnd`).attr(`refX`,20).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).append(`path`).attr(`d`,`M0,0 + L20,10 + M20,10 + L0,20`)},`requirement_arrow`),requirement_contains:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).append(`g`);r.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),r.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),r.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10)},`requirement_contains`),requirement_arrow_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_arrowEnd`).attr(`refX`,20).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`stroke-width`,`${i}`).attr(`viewBox`,`0 0 25 20`).append(`path`).attr(`d`,`M0,0 + L20,10 + M20,10 + L0,20`).attr(`stroke-linejoin`,`miter`)},`requirement_arrow_neo`),requirement_contains_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r,a=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`g`);a.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),a.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),a.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10),a.selectAll(`*`).attr(`stroke-width`,`${i}`)},`requirement_contains_neo`)},so=q,co={common:M,getConfig:S,insertCluster:Oa,insertEdge:no,insertEdgeLabel:Ga,insertMarkers:so,insertNode:Ie,interpolateToCurve:ae,labelHelper:Ne,log:n,positionEdgeLabel:qa},lo=[`elk.stress`,`elk.force`,`elk.mrtree`,`elk.sporeOverlap`,`elk.box`,`elk.rectpacking`],uo=Object.create(null),fo=a(e=>{for(let t of e)uo[t.name]=t},`registerLayoutLoaders`),po=a(()=>{let e=a(async()=>await w(()=>import(`./elk-276RUBZZ-On_DNuCd.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16])),`loader`);return[{name:`elk`,loader:e,algorithm:`elk.layered`},...lo.map(t=>({name:t,loader:e,algorithm:t}))]},`elkLayoutLoaders`);a(()=>{fo([{name:`dagre`,loader:a(async()=>await w(()=>import(`./dagre-6A5THRUB-Bmed3uZj.js`),__vite__mapDeps([17,1,2,3,4,5,6,7,8,9,10,11,12,15,18,14,13])),`loader`)},{name:`swimlane`,loader:a(async()=>await w(()=>import(`./swimlanes-2SLR337P-BKvviDHP.js`),__vite__mapDeps([19,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16])),`loader`)},{name:`cose-bilkent`,loader:a(async()=>await w(()=>import(`./cose-bilkent-JH36ORCC-BtJFQFL9.js`),__vite__mapDeps([20,1,2,21])),`loader`)},...po()])},`registerDefaultLayoutLoaders`)();var mo=a(async(e,t)=>{if(!Object.hasOwn(uo,e.layoutAlgorithm))throw Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);if(e.diagramId)for(let t of e.nodes){let n=t.domId||t.id;t.domId=`${e.diagramId}-${n}`}let n=uo[e.layoutAlgorithm],r=await n.loader();return fa(t,e.config),r.render(e,t,co,{algorithm:n.algorithm})},`render`),ho=`dagre`,go=a((e=``,{fallback:t=ho}={})=>{if(Object.hasOwn(uo,e))return e;for(let r of[t,ho])if(Object.hasOwn(uo,r))return n.warn(`Layout algorithm ${e} is not registered. Using ${r} as fallback.`),r;throw Error(`Neither layout algorithm ${e}, ${t}, nor ${ho} is registered.`)},`getRegisteredLayoutAlgorithm`),_o=`comm`,vo=`rule`,yo=`decl`,bo=`@import`,xo=`@namespace`,So=`@keyframes`,Co=`@layer`,wo=Math.abs,To=String.fromCharCode;function Eo(e){return e.trim()}function Do(e,t,n){return e.replace(t,n)}function Oo(e,t){return e.charCodeAt(t)|0}function ko(e,t,n){return e.slice(t,n)}function Ao(e){return e.length}function jo(e){return e.length}function Mo(e,t){return t.push(e),e}var No=1,Po=1,Fo=0,Io=0,Lo=0,Ro=``;function zo(e,t,n,r,i,a,o,s){return{value:e,root:t,parent:n,type:r,props:i,children:a,line:No,column:Po,length:o,return:``,siblings:s}}function Bo(){return Lo}function Vo(){return Lo=Io>0?Oo(Ro,--Io):0,Po--,Lo===10&&(Po=1,No--),Lo}function Ho(){return Lo=Io2||Ko(Lo)>3?``:` `}function Zo(e,t){for(;--t&&Ho()&&!(Lo<48||Lo>102||Lo>57&&Lo<65||Lo>70&&Lo<97););return Go(e,Wo()+(t<6&&Uo()==32&&Ho()==32))}function Qo(e){for(;Ho();)switch(Lo){case e:return Io;case 34:case 39:e!==34&&e!==39&&Qo(Lo);break;case 40:e===41&&Qo(e);break;case 92:Ho();break}return Io}function $o(e,t){for(;Ho()&&e+Lo!==57&&(e+Lo!==84||Uo()!==47););return`/*`+Go(t,Io-1)+`*`+To(e===47?e:Ho())}function es(e){for(;!Ko(Uo());)Ho();return Go(e,Io)}function ts(e){return Jo(ns(``,null,null,null,[``],e=qo(e),0,[0],e))}function ns(e,t,n,r,i,a,o,s,c){for(var l=0,u=0,d=o,f=0,p=0,m=0,h=1,g=1,_=1,v=0,y=0,b=``,x=i,S=a,C=r,w=b;g;)switch(m=y,y=Ho()){case 40:m!=108&&Oo(w,d-1)==58?(v++,w+=`(`):w+=Yo(y);break;case 41:v--,w+=`)`;break;case 34:case 39:case 91:w+=Yo(y);break;case 9:case 10:case 13:case 32:if(v>0){w+=To(y);break}w+=Xo(m);break;case 92:w+=Zo(Wo()-1,7);continue;case 47:switch(Uo()){case 42:case 47:Mo(is($o(Ho(),Wo()),t,n,c),c),(Ko(m||1)==5||Ko(Uo()||1)==5)&&Ao(w)&&ko(w,-1,void 0)!==` `&&(w+=` `);break;default:w+=`/`}break;case 123*h:s[l++]=Ao(w)*_;case 125*h:case 59:case 0:if(v>0&&y){w+=To(y);break}switch(y){case 0:case 125:g=0;case 59+u:_==-1&&(w=Do(w,/\f/g,``)),p>0&&(Ao(w)-d||h===0)&&Mo(p>32?as(w+`;`,r,n,d-1,c):as(Do(w,` `,``)+`;`,r,n,d-2,c),c);break;case 59:w+=`;`;default:if(Mo(C=rs(w,t,n,l,u,i,s,b,x=[],S=[],d,a),a),y===123){if(u===0)ns(w,t,C,C,x,a,d,s,S);else{switch(f){case 99:if(Oo(w,3)===110)break;case 108:if(Oo(w,2)===97)break;default:u=0;case 100:case 109:case 115:}u?ns(e,C,C,r&&Mo(rs(e,C,C,0,0,i,s,b,i,x=[],d,S),S),i,S,d,s,r?x:S):ns(w,C,C,C,[``],S,0,s,S)}}}l=u=p=0,h=_=1,b=w=``,d=o;break;case 58:d=1+Ao(w),p=m;default:if(h<1){if(y==123)--h;else if(y==125&&h++==0&&Vo()==125)continue}switch(w+=To(y),y*h){case 38:_=u>0?1:(w+=`\f`,-1);break;case 44:if(v>0)break;s[l++]=(Ao(w)-1)*_,_=1;break;case 64:Uo()===45&&(w+=Yo(Ho())),f=Uo(),u=d=Ao(b=w+=es(Wo())),y++;break;case 45:m===45&&Ao(w)==2&&(h=0)}}return a}function rs(e,t,n,r,i,a,o,s,c,l,u,d){for(var f=i-1,p=i===0?a:[``],m=jo(p),h=0,g=0,_=0;h0?p[v]+` `+y:Do(y,/&\f/g,p[v])))&&(c[_++]=b);return zo(e,t,n,i===0?vo:s,c,l,u,d)}function is(e,t,n,r){return zo(e,t,n,_o,To(Bo()),ko(e,2,-2),0,r)}function as(e,t,n,r,i){return zo(e,t,n,yo,ko(e,0,r),ko(e,r+1,-1),r,i)}function os(e,t){for(var n=``,r=0;r/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./c4Diagram-YGBWAQC7-Dp1I9kRE.js`);return{diagram:e}},__vite__mapDeps([22,1,2,3,4,5,6,7,8,9,10,11,23]));return{id:ls,diagram:e}},`loader`)},ds=`flowchart-v2`,fs={id:ds,detector:a(e=>/^\s*(graph|flowchart)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./flowDiagram-KWPJA3E3-BO7njBlM.js`);return{diagram:e}},__vite__mapDeps([24,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:ds,diagram:e}},`loader`)},ps=`agentflow`,ms={id:ps,detector:a(e=>/^\s*agentflow-beta\b/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-22UHCM2B-B4G_FQZz.js`);return{diagram:e}},__vite__mapDeps([30,1,2,3,28,4,5,6,7,8,10,9,11,12,29,23,25,26]));return{id:ps,diagram:e}},`loader`)},hs=`swimlane`,gs={id:hs,detector:a(e=>/^\s*swimlane-beta\b/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./swimlanesDiagram-TC7HE7FX-D2_PSbBF.js`);return{diagram:e}},__vite__mapDeps([31,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:hs,diagram:e}},`loader`)},_s=`er`,vs={id:_s,detector:a(e=>/^\s*erDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./erDiagram-OPXOYQCR-YD8i2JM4.js`);return{diagram:e}},__vite__mapDeps([32,1,2,3,28,4,5,6,7,8,10,9,11,12,25,26]));return{id:_s,diagram:e}},`loader`)},ys=`gitGraph`,bs={id:ys,detector:a(e=>/^\s*gitGraph/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./gitGraphDiagram-X574FWY7-BEOc0w88.js`);return{diagram:e}},__vite__mapDeps([33,1,2,3,4,5,34,35,36,37]));return{id:ys,diagram:e}},`loader`)},xs=`gantt`,Ss={id:xs,detector:a(e=>/^\s*gantt/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ganttDiagram-FUAMR5RP-DWE1bJiy.js`);return{diagram:e}},__vite__mapDeps([38,1,2,3,39,40,41,5,4]));return{id:xs,diagram:e}},`loader`)},Cs=`info`,ws={id:Cs,detector:a(e=>/^\s*info/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./infoDiagram-VRGFBTTK-B6TQ-HH9.js`);return{diagram:e}},__vite__mapDeps([42,1,2,3,34,35]));return{id:Cs,diagram:e}},`loader`)},Ts=`pie`,Es={id:Ts,detector:a(e=>/^\s*pie/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./pieDiagram-5QR66LMP-0Fjx8Dye.js`);return{diagram:e}},__vite__mapDeps([43,1,2,3,44,41,45,5,46,47,4,34,35,36]));return{id:Ts,diagram:e}},`loader`)},Ds=`quadrantChart`,Os={id:Ds,detector:a(e=>/^\s*quadrantChart/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./quadrantDiagram-O4NWA36T-Crj0r6Xm.js`);return{diagram:e}},__vite__mapDeps([48,1,2,3,39,40,41]));return{id:Ds,diagram:e}},`loader`)},ks=`xychart`,As={id:ks,detector:a(e=>/^\s*xychart(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./xychartDiagram-PMCCYNJV-BE8PLguK.js`);return{diagram:e}},__vite__mapDeps([49,1,2,3,39,40,41,44,4,5,50,45,47,7,8]));return{id:ks,diagram:e}},`loader`)},js=`requirement`,Ms={id:js,detector:a(e=>/^\s*requirement(Diagram)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./requirementDiagram-PLB6GJNP-C2fhrVbm.js`);return{diagram:e}},__vite__mapDeps([51,1,2,3,4,5,6,7,8,10,9,11,12,25,26]));return{id:js,diagram:e}},`loader`)},Ns=`sequence`,Ps={id:Ns,detector:a(e=>/^\s*sequenceDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./sequenceDiagram-PO4LG4MO-BKPSlgwc.js`);return{diagram:e}},__vite__mapDeps([52,1,2,3,5,4,23,37]));return{id:Ns,diagram:e}},`loader`)},Fs=`classDiagram`,Is={id:Fs,detector:a(e=>/^\s*classDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./classDiagram-v2-NBCMYWYE-DLd33yZL.js`);return{diagram:e}},__vite__mapDeps([53,1,2,3,4,5,6,7,8,10,9,11,12,29,23,25,26]));return{id:Fs,diagram:e}},`loader`)},Ls=`stateDiagram`,Rs={id:Ls,detector:a(e=>/^\s*stateDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./stateDiagram-v2-GCMORJYK-CepxBhD6.js`);return{diagram:e}},__vite__mapDeps([54,1,2,3,4,5,6,7,8,10,9,11,12,23,25,26]));return{id:Ls,diagram:e}},`loader`)},zs=`journey`,Bs={id:zs,detector:a(e=>/^\s*journey/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./journeyDiagram-ZHPQQLJL-Bik9qTx9.js`);return{diagram:e}},__vite__mapDeps([55,1,2,3,46,45,5,29,23]));return{id:zs,diagram:e}},`loader`)},Vs={draw:a((e,t,r)=>{n.debug(`rendering svg for syntax error +`);let i=Ar(t),a=i.append(`g`);i.attr(`viewBox`,`0 0 2412 512`),C(i,100,512,!0),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z`),a.append(`text`).attr(`class`,`error-text`).attr(`x`,1440).attr(`y`,250).attr(`font-size`,`150px`).style(`text-anchor`,`middle`).text(`Syntax error in text`),a.append(`text`).attr(`class`,`error-text`).attr(`x`,1250).attr(`y`,400).attr(`font-size`,`100px`).style(`text-anchor`,`middle`).text(`mermaid version ${r}`)},`draw`)},Hs=Vs,Us={db:{},renderer:Vs,parser:{parse:a(()=>{},`parse`)}},Ws=`flowchart-elk`,Gs={id:Ws,detector:a((e,t={})=>/^\s*flowchart-elk/.test(e)?(t.layout=`elk`,!0):!1,`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./flowDiagram-KWPJA3E3-BO7njBlM.js`);return{diagram:e}},__vite__mapDeps([24,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:Ws,diagram:e}},`loader`)},Ks=`timeline`,qs={id:Ks,detector:a(e=>/^\s*timeline/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./timeline-definition-EJHVYXUP-Cj4l_LOm.js`);return{diagram:e}},__vite__mapDeps([56,1,2,3,46,45,5,4,10]));return{id:Ks,diagram:e}},`loader`)},Js=`mindmap`,Ys={id:Js,detector:a(e=>/^\s*mindmap/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./mindmap-definition-NLK3R4M7-BCTxemjG.js`);return{diagram:e}},__vite__mapDeps([57,1,2,3,4,5,6,7,8,9,10,11,12,25,26]));return{id:Js,diagram:e}},`loader`)},Xs=`kanban`,Zs={id:Xs,detector:a(e=>/^\s*kanban/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./kanban-definition-PNTS6WVX-BAMaaT6d.js`);return{diagram:e}},__vite__mapDeps([58,1,2,3,4,5,6,7,8,9,10,11,12,29]));return{id:Xs,diagram:e}},`loader`)},Qs=`sankey`,$s={id:Qs,detector:a(e=>/^\s*sankey(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js`);return{diagram:e}},__vite__mapDeps([59,1,2,3,44,41]));return{id:Qs,diagram:e}},`loader`)},ec=`packet`,tc={id:ec,detector:a(e=>/^\s*packet(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-MLGK6HIB-DILal1CA.js`);return{diagram:e}},__vite__mapDeps([60,1,2,3,4,5,34,35,36]));return{id:ec,diagram:e}},`loader`)},nc=`radar`,rc={id:nc,detector:a(e=>/^\s*radar-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-MPIPVDR6-8w_EEv4v.js`);return{diagram:e}},__vite__mapDeps([61,1,2,3,4,5,34,35,36]));return{id:nc,diagram:e}},`loader`)},ic=`block`,ac={id:ic,detector:a(e=>/^\s*block(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./blockDiagram-BEXU5L5S-LcLXSRjx.js`);return{diagram:e}},__vite__mapDeps([62,1,2,3,28,4,5,6,7,8,10,9,11,12,29,14,15]));return{id:ic,diagram:e}},`loader`)},oc=`treeView`,sc={id:oc,detector:a(e=>/^\s*treeView-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-CDSNMT55-DcWw9GHj.js`);return{diagram:e}},__vite__mapDeps([63,1,2,3,4,5,7,34,35,36,37]));return{id:oc,diagram:e}},`loader`)},cc=`architecture`,lc={id:cc,detector:a(e=>/^\s*architecture/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./architectureDiagram-NJMV4G6O-CQM7JOeV.js`);return{diagram:e}},__vite__mapDeps([64,1,2,3,4,5,7,8,34,35,36,21]));return{id:cc,diagram:e}},`loader`)},uc=`eventmodeling`,dc={id:uc,detector:a(e=>/^\s*eventmodeling/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-ATOU4E4O-BNgT_lbL.js`);return{diagram:e}},__vite__mapDeps([65,1,2,3,4,5,35,34,36]));return{id:uc,diagram:e}},`loader`)},fc=`ishikawa`,pc={id:fc,detector:a(e=>/^\s*ishikawa(-beta)?\b/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ishikawaDiagram-OU5B5YK6-BuTYOHFo.js`);return{diagram:e}},__vite__mapDeps([66,1,2,3,4,5,11]));return{id:fc,diagram:e}},`loader`)},mc=`venn`,hc={id:mc,detector:a(e=>/^\s*venn-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./vennDiagram-UO4OBE2U-Bq0yqgVW.js`);return{diagram:e}},__vite__mapDeps([67,1,2,3,4,5,11]));return{id:mc,diagram:e}},`loader`)},gc=`treemap`,_c={id:gc,detector:a(e=>/^\s*treemap/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-3UASUU5V-Dv_f5rjj.js`);return{diagram:e}},__vite__mapDeps([68,1,2,3,44,41,40,4,5,6,34,35,36,26]));return{id:gc,diagram:e}},`loader`)},vc=`usecase`,yc={id:vc,detector:a(e=>/^\s*usecase-beta(?:\s|$)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./usecaseDiagram-POWQR4AR-1e9d35eQ.js`);return{diagram:e}},__vite__mapDeps([69,1,2,3,4,5,6,7,8,10,9,11,12,15,18,25,26]));return{id:vc,diagram:e}},`loader`)},bc=`wardley`,xc={id:bc,detector:a(e=>/^\s*wardley-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./wardleyDiagram-VNRHLVJA-DPtbrmxX.js`);return{diagram:e}},__vite__mapDeps([70,1,2,3,4,5,34,35,36]));return{id:bc,diagram:e}},`loader`)},Sc=`cynefin`,Cc={id:Sc,detector:a(e=>/^\s*cynefin-beta(?:[\s:]|$)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./cynefinDiagram-VND7K2PF-9xRwA2wI.js`);return{diagram:e}},__vite__mapDeps([71,1,2,3,4,5,34,35,36]));return{id:Sc,diagram:e}},`loader`)},wc=`railroad`,Tc={id:wc,detector:a(e=>/^\s*railroad-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./railroadDiagram-XR7U4H2S-BHZ1Lx2I.js`);return{diagram:e}},__vite__mapDeps([72,1,2,3,34,35,73,36]));return{id:wc,diagram:e}},`loader`)},Ec=`railroadEbnf`,Dc={id:Ec,detector:a(e=>/^\s*railroad-ebnf-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ebnfDiagram-ZINNZB2B-CGBBBydS.js`);return{diagram:e}},__vite__mapDeps([74,1,2,3,34,35,73,36]));return{id:Ec,diagram:e}},`loader`)},Oc=`railroadAbnf`,kc={id:Oc,detector:a(e=>/^\s*railroad-abnf-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./abnfDiagram-O67JEVCF-CQJZpKdi.js`);return{diagram:e}},__vite__mapDeps([75,1,2,3,34,35,73,36]));return{id:Oc,diagram:e}},`loader`)},Ac=`railroadPeg`,jc={id:Ac,detector:a(e=>/^\s*railroad-peg-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./pegDiagram-GJSIUBJH-B0Gktij4.js`);return{diagram:e}},__vite__mapDeps([76,1,2,3,34,35,73,36]));return{id:Ac,diagram:e}},`loader`)},Mc=!1,Nc=a(()=>{Mc||(Mc=!0,p(`error`,Us,e=>e.toLowerCase().trim()===`error`),p(`---`,{db:{clear:a(()=>{},`clear`)},styles:{},renderer:{draw:a(()=>{},`draw`)},parser:{parse:a(()=>{throw Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},`parse`)},init:a(()=>null,`init`)},e=>e.toLowerCase().trimStart().startsWith(`---`)),m(Gs,Ys,lc),m(ms,us,Zs,Is,vs,Ss,ws,Es,Ms,Ps,gs,fs,qs,bs,Rs,Bs,Os,$s,tc,As,ac,dc,sc,rc,pc,_c,Tc,Dc,kc,jc,hc,xc,Cc,yc))},`addDiagrams`),Pc=a(async()=>{n.debug(`Loading registered diagrams`);let e=(await Promise.allSettled(Object.entries(O).map(async([e,{detector:t,loader:r}])=>{if(r)try{g(e)}catch{try{let{diagram:e,id:n}=await r();p(n,e,t)}catch(t){throw n.error(`Failed to load external diagram with key ${e}. Removing from detectors.`),delete O[e],t}}}))).filter(e=>e.status===`rejected`);if(e.length>0){n.error(`Failed to load ${e.length} external diagrams`);for(let t of e)n.error(t);throw Error(`Failed to load ${e.length} external diagrams`)}},`loadRegisteredDiagrams`),Fc=`graphics-document document`;function Ic(e,t){e.attr(`role`,Fc),t!==``&&e.attr(`aria-roledescription`,t)}a(Ic,`setA11yDiagramInfo`);function Lc(e,t,n,r){if(e.insert!==void 0){if(n){let t=`chart-desc-${r}`;e.attr(`aria-describedby`,t),e.insert(`desc`,`:first-child`).attr(`id`,t).text(n)}if(t){let n=`chart-title-${r}`;e.attr(`aria-labelledby`,n),e.insert(`title`,`:first-child`).attr(`id`,n).text(t)}}}a(Lc,`addSVGa11yTitleDescription`);var Rc=class e{constructor(e,t,n,r,i){this.type=e,this.text=t,this.db=n,this.parser=r,this.renderer=i}static{a(this,`Diagram`)}static async fromText(t,r={}){let i=typeof t==`string`?{raw:t,cleaned:t}:t,a=S(),o=A(i.cleaned,a);try{g(o)}catch{let e=s(o);if(!e)throw new N(`Diagram ${o} not found.`);let{id:t,diagram:n}=await e();p(t,n)}let{db:c,parser:l,renderer:u,init:d}=g(o);l.parser&&(l.parser.yy=c),c.clear?.(),d?.(a),r.title&&c.setDiagramTitle?.(r.title);let f=i.cleaned;if(c.preserveCommentsWhenParsing&&i.withComments){let e=a.maxTextSize??T.maxTextSize;i.withComments.length>e?n.warn(`Comment-preserving source exceeds maxTextSize (${i.withComments.length} > ${e}); parsing the comment-stripped text instead. Reported source positions will not account for comment lines.`):f=i.withComments}let m=fe(f)+` +`;return i.frontmatterLineOffset&&c.setFrontmatterLineOffset?.(i.frontmatterLineOffset),await l.parse(m),new e(o,m,c,l,u)}async render(e,t){await this.renderer.draw(this.text,e,t,this)}getParser(){return this.parser}getType(){return this.type}},zc=[],Bc=a(()=>{zc.forEach(e=>{e()}),zc=[]},`attachFunctions`),Vc=a(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,``).trimStart(),`cleanupComments`);function Hc(e){let t=e.match(x);if(!t)return{text:e,metadata:{}};let n=t[1],r=ia(n?t[2].split(` +`).map(e=>e.startsWith(n)?e.slice(n.length):e).join(` +`):t[2],{schema:ta})??{};r=typeof r==`object`&&!Array.isArray(r)?r:{};let i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:e.slice(t[0].length),metadata:i}}a(Hc,`extractFrontMatter`);var Uc=a(e=>e.replace(/\r\n?/g,` +`).replace(/<(\w+)([^>]*)>/g,(e,t,n)=>`<`+t+n.replace(/="([^"]*)"/g,`='$1'`)+`>`),`cleanupText`),Wc=a(e=>{let{text:t,metadata:n}=Hc(e),{displayMode:r,title:i,config:a={}}=n;return r&&(a.gantt||={},a.gantt.displayMode=r),{title:i,config:a,text:t}},`processFrontmatter`),Gc=a(e=>{let t=ce.detectInit(e)??{},n=ce.detectDirective(e,`wrap`);return Array.isArray(n)?t.wrap=n.some(({type:e})=>e===`wrap`):n?.type===`wrap`&&(t.wrap=!0),{text:le(e),directive:t}},`processDirectives`);function Kc(e){let t=e,n=Uc(e),r=Wc(n),i=Gc(r.text),a=ue(r.config,i.directive),o=i.text;return{code:{raw:t,cleaned:Vc(o),withComments:o,frontmatterLineOffset:n.length>r.text.length?(n.substring(0,n.length-r.text.length).match(/\n/g)??[]).length:0},title:r.title,config:a}}a(Kc,`preprocessDiagram`);function qc(e){let t=new TextEncoder().encode(e),n=Array.from(t,e=>String.fromCodePoint(e)).join(``);return btoa(n)}a(qc,`toBase64`);var Jc=5e4,Yc=`graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa`,Xc=`sandbox`,Zc=`loose`,Qc=`http://www.w3.org/2000/svg`,$c=`http://www.w3.org/1999/xlink`,el=`http://www.w3.org/1999/xhtml`,tl=`100%`,nl=`100%`,rl=`border:0;margin:0;`,il=`margin:0`,al=`allow-top-navigation-by-user-activation allow-popups`,ol=`The "iframe" tag is not supported by your browser.`,sl=[`foreignobject`],cl=[`dominant-baseline`];function ll(e){let t=Kc(e);l();let n;try{n=A(t.code.cleaned,S())}catch{n=void 0}return d(n),k(t.config??{}),t}a(ll,`processAndSetConfigs`);async function ul(e,t){Nc();try{let{code:t,config:n}=ll(e);return{diagramType:(await Rc.fromText(t)).type,config:n}}catch(e){if(t?.suppressErrors)return!1;throw e}finally{d(void 0)}}a(ul,`parse`);var dl=a((e,t,n=[])=>`.${e} ${t} ${f(`{ ${n.join(` !important; `)} !important; }`)}`,`cssImportantStyles`),fl=a((e,t=new Map)=>{let n=new CSSStyleSheet;if(e.fontFamily!==void 0&&n.insertRule(`:root { --mermaid-font-family: ${e.fontFamily}}`,n.cssRules.length),e.altFontFamily!==void 0&&n.insertRule(`:root { --mermaid-alt-font-family: ${e.altFontFamily}}`,n.cssRules.length),t instanceof Map){let r=_(e)?[`> *`,`span`]:[`rect`,`polygon`,`ellipse`,`circle`,`path`];t.forEach(e=>{ma(e.styles)||r.forEach(t=>{n.insertRule(dl(e.id,t,e.styles),n.cssRules.length)}),ma(e.textStyles)||n.insertRule(dl(e.id,`tspan`,(e?.textStyles||[]).map(e=>e.replace(`color`,`fill`))),n.cssRules.length)})}let r=``;if(e.themeCSS!==void 0){if(typeof n.replaceSync==`function`){let t=new CSSStyleSheet;t.replaceSync(e.themeCSS),r=D(t)+` +`}else r+=`${e.themeCSS} +`}return r+D(n)},`createCssStyles`),pl=a((e,t)=>os(ts(`${e}{${t}}`),cs([a(function(t,r,i,a){if(t.type===`rule`&&Array.isArray(t.props)){if(t.parent&&t.parent.type===`@keyframes`)return;t.props=t.props.map(n=>n===e&&Array.isArray(t.children)&&t.children.every(e=>e.type===`decl`&&new Set([`font-family`,`font-size`,`fill`]).has(e.props))||(n.startsWith(`${e} `)||n.startsWith(`${e}>`))&&!n.startsWith(`${e} ||`)?n:`${e} ${n}`)}else t.type.startsWith(`@`)&&([`@media`,`@supports`,`@layer`,`@scope`,`@container`,`@starting-style`,`@keyframes`].includes(t.type)||(n.warn(`Removing unsupported at-rule ${t.type} from CSS`),t.type=_o))},`addNamespace`),ss])),`compileCSS`),ml=a((e,t,n,r)=>{let i=fl(e,n);return pl(r,b(t,i,{...e.themeVariables,theme:e.theme,look:e.look},r))},`createUserStyles`),hl=a((e=``,t,n)=>{let r=e;return!n&&!t&&(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,`marker-end="url(#`)),r=ie(r),r=r.replace(/
    /g,`
    `),r},`cleanUpSvgCode`),gl=a((e=``,t)=>``,`putIntoIFrame`),_l=a((e,t,n,r,i)=>{let a=e.append(`div`);a.attr(`id`,n),r&&a.attr(`style`,r);let o=a.append(`svg`).attr(`id`,t).attr(`width`,`100%`).attr(`xmlns`,Qc);return i&&o.attr(`xmlns:xlink`,i),o.append(`g`),e},`appendDivSvgG`);function vl(e,t){return e.append(`iframe`).attr(`id`,t).attr(`style`,`width: 100%; height: 100%;`).attr(`sandbox`,``)}a(vl,`sandboxedIframe`);var yl=a((e,t,n,r)=>{e.getElementById(t)?.remove(),e.getElementById(n)?.remove(),e.getElementById(r)?.remove()},`removeExistingElements`),bl=a(async function(e,t,i){Nc();let o=ll(t),s=o.code;t=s.cleaned;let c=S();n.debug(c),t.length>(c?.maxTextSize??Jc)&&(t=Yc,s={raw:t,cleaned:t});let l=`#${e}`,u=`i`+e,d=`#`+u,f=`d`+e,p=`#`+f,m=a(()=>{let e=r(g?d:p).node();e&&`remove`in e&&e.remove()},`removeTempElements`),h=r(document.body),g=c.securityLevel===Xc,_=c.securityLevel===Zc,v=c.fontFamily;if(i!==void 0){if(i&&(i.innerHTML=``),g){let e=vl(r(i),u);h=r(e.nodes()[0].contentDocument.body),h.node().style.margin=`0`}else h=r(i);_l(h,e,f,`font-family: ${v}`,$c)}else{if(yl(document,e,f,u),g){let e=vl(r(document.body),u);h=r(e.nodes()[0].contentDocument.body),h.node().style.margin=`0`}else h=r(`body`);_l(h,e,f)}let y,b;try{y=await Rc.fromText(s,{title:o.title})}catch(e){if(c.suppressErrorRendering)throw m(),e;y=await Rc.fromText(`error`),b=e}let x=h.select(p).node(),C=y.type,w=x.firstChild,T=w.firstChild,D=y.renderer.getClasses?.(t,y),O=ml(c,C,D,l),k=document.createElement(`style`);k.innerHTML=O,w.insertBefore(k,T);try{await y.renderer.draw(t,e,`12.0.0`,y)}catch(n){throw c.suppressErrorRendering?m():Hs.draw(t,e,`12.0.0`),n}let A=h.select(`${p} svg`),j=y.db.getAccTitle?.(),M=y.db.getAccDescription?.();wl(C,A,j,M);let N=a(()=>{h.select(`[id="${e}"]`).selectAll(`foreignobject > *`).attr(`xmlns`,el);let t=h.select(p).node().innerHTML;if(n.debug(`config.arrowMarkerAbsolute`,c.arrowMarkerAbsolute),t=hl(t,g,E(c.arrowMarkerAbsolute)),g){let e=h.select(p+` svg`).node();t=gl(t,e)}else _||(t=P.sanitize(t,{ADD_TAGS:sl,ADD_ATTR:cl,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));return Bc(),t},`serializeSvg`)();if(b)throw b;return m(),{diagramType:C,svg:N,bindFunctions:y.db.bindFunctions}},`renderDiagram`),xl=a(async function(e,t,n){try{return await bl(e,t,n)}finally{d(void 0)}},`render`);function Sl(e={}){let n=j({},e);n?.fontFamily&&!n.themeVariables?.fontFamily&&(n.themeVariables||={},n.themeVariables.fontFamily=n.fontFamily),v(n);let r=F.theme;n?.theme&&Object.hasOwn(h,n.theme)?n.themeVariables=h[n.theme].getThemeVariables(n.themeVariables):n&&(n.theme!=null&&n.theme!==`null`&&(n.theme=r),n.themeVariables=h[r].getThemeVariables(n.themeVariables));let i=typeof n==`object`?u(n):c();t(i.logLevel),Nc()}a(Sl,`initialize`);var Cl=a((e,t={})=>{let{code:n}=Kc(e);return Rc.fromText(n,t)},`getDiagramFromText`);function wl(e,t,n,r){Ic(t,e),Lc(t,n,r,t.attr(`id`))}a(wl,`addA11yInfo`);var Tl=Object.freeze({render:xl,parse:ul,getDiagramFromText:Cl,initialize:Sl,getConfig:S,setConfig:y,getSiteConfig:c,updateSiteConfig:o,reset:a(()=>{l()},`reset`),globalReset:a(()=>{l(F)},`globalReset`),defaultConfig:F});t(S().logLevel),l(S());var El=a((e,t,r)=>{n.warn(e),se(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},`handleError`),Dl=a(async function(e={querySelector:`.mermaid`}){try{await Ol(e)}catch(t){if(se(t)&&n.error(t.str),Y.parseError&&Y.parseError(t),!e.suppressErrors)throw n.error(`Use the suppressErrors option to suppress these errors`),t}},`run`),Ol=a(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:`.mermaid`}){let i=Tl.getConfig();n.debug(`${e?``:`No `}Callback function found`);let a;if(r)a=r;else if(t)a=document.querySelectorAll(t);else throw Error(`Nodes and querySelector are both undefined`);n.debug(`Found ${a.length} diagrams`),i?.startOnLoad!==void 0&&(n.debug(`Start On Load: `+i?.startOnLoad),Tl.updateSiteConfig({startOnLoad:i?.startOnLoad}));let o=new ce.InitIDGenerator(i.deterministicIds,i.deterministicIDSeed),s,c=[];for(let t of Array.from(a)){if(n.info(`Rendering diagram: `+t.id),t.getAttribute(`data-processed`))continue;t.setAttribute(`data-processed`,`true`);let r=`mermaid-${o.next()}`;s=t.innerHTML,s=Ee(ce.entityDecode(s)).trim().replace(//gi,`
    `);let i=ce.detectInit(s);i&&n.debug(`Detected early reinit: `,i);try{let{svg:n,bindFunctions:i}=await Ll(r,s,t);t.innerHTML=n,e&&await e(r),i&&i(t)}catch(e){El(e,c,Y.parseError)}}if(c.length>0)throw c[0]},`runThrowsErrors`),kl=a(function(e){Tl.initialize(e)},`initialize`),Al=a(async function(e,t,r){n.warn(`mermaid.init is deprecated. Please use run instead.`),e&&kl(e);let i={postRenderCallback:r,querySelector:`.mermaid`};typeof t==`string`?i.querySelector=t:t&&(i.nodes=t instanceof HTMLElement?[t]:t),await Dl(i)},`init`),jl=a(async(e,{lazyLoad:t=!0}={})=>{Nc(),m(...e),t===!1&&await Pc()},`registerExternalDiagrams`),Ml=a(function(){if(Y.startOnLoad){let{startOnLoad:e}=Tl.getConfig();e&&Y.run().catch(e=>n.error(`Mermaid failed to initialize`,e))}},`contentLoaded`);typeof document<`u`&&window.addEventListener(`load`,Ml,!1);var Nl=a(function(e){Y.parseError=e},`setParseErrorHandler`),Pl=[],Fl=!1,Il=a(async()=>{if(!Fl){for(Fl=!0;Pl.length>0;){let e=Pl.shift();if(e)try{await e()}catch(e){n.error(`Error executing queue`,e)}}Fl=!1}},`executeQueue`),J=a(async(e,t)=>new Promise((r,i)=>{let o=a(()=>new Promise((a,o)=>{Tl.parse(e,t).then(e=>{a(e),r(e)},e=>{n.error(`Error parsing`,e),Y.parseError?.(e),o(e),i(e)})}),`performCall`);Pl.push(o),Il().catch(i)}),`parse`),Ll=a((e,t,r)=>new Promise((i,o)=>{let s=a(()=>new Promise((a,s)=>{Tl.render(e,t,r).then(e=>{a(e),i(e)},e=>{n.error(`Error parsing`,e),Y.parseError?.(e),s(e),o(e)})}),`performCall`);Pl.push(s),Il().catch(o)}),`render`),Y={startOnLoad:!0,mermaidAPI:Tl,parse:J,render:Ll,init:Al,run:Dl,registerExternalDiagrams:jl,registerLayoutLoaders:fo,initialize:kl,parseError:void 0,contentLoaded:Ml,setParseErrorHandler:Nl,detectType:A,registerIconPacks:Te,getRegisteredDiagramsMetadata:a(()=>Object.keys(O).map(e=>({id:e})),`getRegisteredDiagramsMetadata`)},X=Y,Z=new Er({gfm:!0,breaks:!0,renderer:{code({text:e,lang:t}){return t===`mermaid`&&`
    ${e}
    \n`}}});function Rl(e){let t=e.split(` +`),n=[],r=!1,i=!1,a=0;for(let e=0;e{let s=e.toLowerCase().endsWith(`.md`)||e.toLowerCase().endsWith(`.markdown`),[c,l]=(0,V.useState)(s?`rendered`:`raw`),[u,d]=(0,V.useState)(!1),f=(0,V.useRef)(null),p=async()=>{if(t)try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(t),d(!0),setTimeout(()=>d(!1),2e3)}catch{}},m=e=>e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(1)} MB`,h=e?e.split(`/`).pop()||e:``,g=(0,V.useMemo)(()=>{if(!t)return``;try{let e=Rl(t);return Z.parse(e)}catch(e){return console.error(`Failed to parse markdown:`,e),`
    ${t}
    `}},[t]);return(0,V.useEffect)(()=>{if(c!==`rendered`||!f.current)return;let e=f.current.querySelectorAll(`.mermaid`);if(e.length!==0)try{X.initialize({startOnLoad:!1,theme:`dark`,securityLevel:`loose`,fontFamily:`monospace, sans-serif`,themeVariables:{darkMode:!0,background:`#07181b`,primaryColor:`#0891b2`,primaryTextColor:`#f8fafc`,primaryBorderColor:`#15474d`,lineColor:`#2dd4bf`,secondaryColor:`#164e63`,tertiaryColor:`#0d2c2f`}});let t=Array.from(e).filter(e=>!e.getAttribute(`data-processed`));t.length>0&&X.run({nodes:t}).catch(e=>{console.warn(`Mermaid rendering warning:`,e)})}catch(e){console.warn(`Failed to initialize mermaid:`,e)}},[g,c]),(0,H.jsxs)(`div`,{className:`nav-doc-reader`,"data-testid":`nav-doc-reader`,children:[(0,H.jsxs)(`div`,{className:`doc-reader-header`,children:[(0,H.jsxs)(`div`,{className:`doc-header-meta`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`})]}),(0,H.jsx)(`span`,{className:`doc-filename`,title:e,children:h}),(0,H.jsxs)(`span`,{className:`doc-badge-chip`,children:[n,` lines`]}),r>0&&(0,H.jsx)(`span`,{className:`doc-badge-chip`,children:m(r)})]}),(0,H.jsxs)(`div`,{className:`doc-header-actions`,children:[s&&(0,H.jsxs)(`div`,{className:`doc-view-toggle`,role:`group`,"aria-label":`Document View Mode`,children:[(0,H.jsx)(`button`,{type:`button`,className:`toggle-btn ${c===`rendered`?`active`:``}`,onClick:()=>l(`rendered`),"aria-pressed":c===`rendered`,children:`Rendered`}),(0,H.jsx)(`button`,{type:`button`,className:`toggle-btn ${c===`raw`?`active`:``}`,onClick:()=>l(`raw`),"aria-pressed":c===`raw`,children:`Raw Source`})]}),(0,H.jsx)(`button`,{type:`button`,className:`doc-copy-btn`,onClick:p,title:`Copy document content`,"aria-label":`Copy Document Content`,children:u?`✓ Copied!`:`Copy Content`})]})]}),(0,H.jsx)(`div`,{className:`doc-reader-body`,children:i?(0,H.jsxs)(`div`,{className:`doc-reader-loading`,"data-testid":`doc-loading`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):a?(0,H.jsxs)(`div`,{className:`doc-reader-error`,role:`alert`,children:[(0,H.jsxs)(`p`,{children:[`Failed to load file content: `,a]}),o&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-sm btn-primary`,onClick:o,children:`Retry`})]}):c===`rendered`&&s?(0,H.jsx)(`div`,{ref:f,className:`doc-rendered-content`,"data-testid":`doc-rendered-content`,dangerouslySetInnerHTML:{__html:g}}):(0,H.jsx)(`div`,{className:`doc-raw-container`,"data-testid":`doc-raw-content`,children:(0,H.jsx)(`pre`,{className:`doc-raw-pre`,children:(0,H.jsx)(`table`,{className:`doc-lines-table`,children:(0,H.jsx)(`tbody`,{children:t.split(` +`).map((e,t)=>(0,H.jsxs)(`tr`,{className:`doc-line-row`,children:[(0,H.jsx)(`td`,{className:`doc-line-num`,"data-line-number":t+1,children:t+1}),(0,H.jsx)(`td`,{className:`doc-line-code`,children:(0,H.jsx)(`code`,{children:e||` `})})]},t))})})})})})]})};function Bl(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`){if(Array.isArray(e)){var i=e.length;for(t=0;tt in e?Ul(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$l=(e,t)=>{for(var n in t||={})Xl.call(t,n)&&Ql(e,n,t[n]);if(Jl)for(var n of Jl(t))Zl.call(t,n)&&Ql(e,n,t[n]);return e},eu=(e,t)=>Wl(e,Kl(t)),tu=(e,t)=>{var n={};for(var r in e)Xl.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Jl)for(var r of Jl(e))t.indexOf(r)<0&&Zl.call(e,r)&&(n[r]=e[r]);return n},nu=(e,t)=>function(){return t||(0,e[ql(e)[0]])((t={exports:{}}).exports,t),t.exports},ru=(e,t)=>{for(var n in t)Ul(e,n,{get:t[n],enumerable:!0})},iu=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of ql(t))!Xl.call(e,i)&&i!==n&&Ul(e,i,{get:()=>t[i],enumerable:!(r=Gl(t,i))||r.enumerable});return e},Q=((e,t,n)=>(n=e==null?{}:Hl(Yl(e)),iu(t||!e||!e.__esModule?Ul(n,`default`,{value:e,enumerable:!0}):n,e)))(nu({"../../node_modules/.pnpm/prismjs@1.29.0_patch_hash=vrxx3pzkik6jpmgpayxfjunetu/node_modules/prismjs/prism.js"(e,t){var n=function(){var e=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,t=0,n={},r={util:{encode:function e(t){return t instanceof i?new i(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,`&`).replace(/`+a.content+``};function a(e,t,n,r){e.lastIndex=t;var i=e.exec(n);if(i&&r&&i[1]){var a=i[1].length;i.index+=a,i[0]=i[0].slice(a)}return i}function o(e,t,n,s,u,d){for(var f in n)if(!(!n.hasOwnProperty(f)||!n[f])){var p=n[f];p=Array.isArray(p)?p:[p];for(var m=0;m=d.reach);C+=S.value.length,S=S.next){var w=S.value;if(t.length>e.length)return;if(!(w instanceof i)){var T=1,E;if(v){if(E=a(x,C,e,_),!E||E.index>=e.length)break;var D=E.index,O=E.index+E[0].length,k=C;for(k+=S.value.length;D>=k;)S=S.next,k+=S.value.length;if(k-=S.value.length,C=k,S.value instanceof i)continue;for(var A=S;A!==t.tail&&(kd.reach&&(d.reach=P);var F=S.prev;M&&(F=c(t,F,M),C+=M.length),l(t,F,T);var I=new i(f,g?r.tokenize(j,g):j,y,j);if(S=c(t,F,I),N&&c(t,S,N),T>1){var L={cause:f+`,`+m,reach:P};o(e,t,n,S.prev,C,L),d&&L.reach>d.reach&&(d.reach=L.reach)}}}}}}function s(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function c(e,t,n){var r=t.next,i={value:n,prev:t,next:r};return t.next=i,r.prev=i,e.length++,i}function l(e,t,n){for(var r=t.next,i=0;i/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:`attr-equals`},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:`named-entity`},/&#x?[\da-f]{1,8};/i]},Q.languages.markup.tag.inside[`attr-value`].inside.entity=Q.languages.markup.entity,Q.languages.markup.doctype.inside[`internal-subset`].inside=Q.languages.markup,Q.hooks.add(`wrap`,function(e){e.type===`entity`&&(e.attributes.title=e.content.replace(/&/,`&`))}),Object.defineProperty(Q.languages.markup.tag,"addInlined",{value:function(e,t){var n={},n=(n[`language-`+t]={pattern:/(^$)/i,lookbehind:!0,inside:Q.languages[t]},n.cdata=/^$/i,{"included-cdata":{pattern://i,inside:n}}),t=(n[`language-`+t]={pattern:/[\s\S]+/,inside:Q.languages[t]},{});t[e]={pattern:RegExp(`(<__[^>]*>)(?:))*\\]\\]>|(?!)`.replace(/__/g,function(){return e}),`i`),lookbehind:!0,greedy:!0,inside:n},Q.languages.insertBefore(`markup`,`cdata`,t)}}),Object.defineProperty(Q.languages.markup.tag,"addAttribute",{value:function(e,t){Q.languages.markup.tag.inside[`special-attr`].push({pattern:RegExp(`(^|["'\\s])(?:`+e+`)\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s'">=]+(?=[\\s>]))`,`i`),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,`language-`+t],inside:Q.languages[t]},punctuation:[{pattern:/^=/,alias:`attr-equals`},/"|'/]}}}})}}),Q.languages.html=Q.languages.markup,Q.languages.mathml=Q.languages.markup,Q.languages.svg=Q.languages.markup,Q.languages.xml=Q.languages.extend(`markup`,{}),Q.languages.ssml=Q.languages.xml,Q.languages.atom=Q.languages.xml,Q.languages.rss=Q.languages.xml,function(e){var t={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:`escape`},n=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,r=`(?:[^\\\\-]|`+n.source+`)`,r=RegExp(r+`-`+r),i={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:`variable`};e.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:`operator`},"char-class-punctuation":{pattern:/^\[|\]$/,alias:`punctuation`},range:{pattern:r,inside:{escape:n,"range-punctuation":{pattern:/-/,alias:`operator`}}},"special-escape":t,"char-set":{pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:`class-name`},escape:n}},"special-escape":t,"char-set":{pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:`class-name`},backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:`keyword`},{pattern:/\\k<[^<>']+>/,alias:`keyword`,inside:{"group-name":i}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:`function`},escape:n,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},Q.languages.javascript=Q.languages.extend(`clike`,{"class-name":[Q.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Q.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Q.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:Q.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Q.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Q.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Q.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Q.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Q.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:Q.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),Q.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),Q.languages.markup&&(Q.languages.markup.tag.addInlined(`script`,`javascript`),Q.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),Q.languages.js=Q.languages.javascript,Q.languages.actionscript=Q.languages.extend(`javascript`,{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<>?>?|[!=]=?)=?|[~?@]/}),Q.languages.actionscript[`class-name`].alias=`function`,delete Q.languages.actionscript.parameter,delete Q.languages.actionscript[`literal-property`],Q.languages.markup&&Q.languages.insertBefore(`actionscript`,`string`,{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:Q.languages.markup}}),function(e){var t=/#(?!\{).+/,n={pattern:/#\{[^}]+\}/,alias:`variable`};e.languages.coffeescript=e.languages.extend(`javascript`,{comment:t,string:[{pattern:/'(?:\\[\s\S]|[^\\'])*'/,greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0,inside:{interpolation:n}}],keyword:/\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,"class-member":{pattern:/@(?!\d)\w+/,alias:`variable`}}),e.languages.insertBefore(`coffeescript`,`comment`,{"multiline-comment":{pattern:/###[\s\S]+?###/,alias:`comment`},"block-regex":{pattern:/\/{3}[\s\S]*?\/{3}/,alias:`regex`,inside:{comment:t,interpolation:n}}}),e.languages.insertBefore(`coffeescript`,`string`,{"inline-javascript":{pattern:/`(?:\\[\s\S]|[^\\`])*`/,inside:{delimiter:{pattern:/^`|`$/,alias:`punctuation`},script:{pattern:/[\s\S]+/,alias:`language-javascript`,inside:e.languages.javascript}}},"multiline-string":[{pattern:/'''[\s\S]*?'''/,greedy:!0,alias:`string`},{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:`string`,inside:{interpolation:n}}]}),e.languages.insertBefore(`coffeescript`,`keyword`,{property:/(?!\d)\w+(?=\s*:(?!:))/}),delete e.languages.coffeescript[`template-string`],e.languages.coffee=e.languages.coffeescript}(Q),function(e){var t=e.languages.javadoclike={parameter:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m,lookbehind:!0},keyword:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m,lookbehind:!0},punctuation:/[{}]/};Object.defineProperty(t,"addSupport",{value:function(t,n){(t=typeof t==`string`?[t]:t).forEach(function(t){var r=function(e){e.inside||={},e.inside.rest=n},i=`doc-comment`;if(a=e.languages[t]){var a,o=a[i];if((o||=(a=e.languages.insertBefore(t,`comment`,{"doc-comment":{pattern:/(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/,lookbehind:!0,alias:`comment`}}))[i])instanceof RegExp&&(o=a[i]={pattern:o}),Array.isArray(o))for(var s=0,c=o.length;s|\+|~|\|\|/,punctuation:/[(),]/}},e.languages.css.atrule.inside[`selector-function-argument`].inside=t,e.languages.insertBefore(`css`,`property`,{variable:{pattern:/(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,lookbehind:!0}}),{pattern:/(\b\d+)(?:%|[a-z]+(?![\w-]))/,lookbehind:!0}),n={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0};e.languages.insertBefore(`css`,`function`,{operator:{pattern:/(\s)[+\-*\/](?=\s)/,lookbehind:!0},hexcode:{pattern:/\B#[\da-f]{3,8}\b/i,alias:`color`},color:[{pattern:/(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|RebeccaPurple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,lookbehind:!0},{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:t,number:n,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:t,number:n})}(Q),function(e){var t=/[*&][^\s[\]{},]+/,n=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,r=`(?:`+n.source+`(?:[ ]+`+t.source+`)?|`+t.source+`(?:[ ]+`+n.source+`)?)`,i=`(?:[^\\s\\x00-\\x08\\x0e-\\x1f!"#%&'*,\\-:>?@[\\]\`{|}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]|[?:-])(?:[ \\t]*(?:(?![#:])|:))*`.replace(//g,function(){return`[^\\s\\x00-\\x08\\x0e-\\x1f,[\\]{}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]`}),a=`"(?:[^"\\\\\\r\\n]|\\\\.)*"|'(?:[^'\\\\\\r\\n]|\\\\.)*'`;function o(e,t){t=(t||``).replace(/m/g,``)+`m`;var n=`([:\\-,[{]\\s*(?:\\s<>[ \\t]+)?)(?:<>)(?=[ \\t]*(?:$|,|\\]|\\}|(?:[\\r\\n]\\s*)?#))`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return e});return RegExp(n,t)}e.languages.yaml={scalar:{pattern:RegExp(`([\\-:]\\s*(?:\\s<>[ \\t]+)?[|>])[ \\t]*(?:((?:\\r?\\n|\\r)[ \\t]+)\\S[^\\r\\n]*(?:\\2[^\\r\\n]+)*)`.replace(/<>/g,function(){return r})),lookbehind:!0,alias:`string`},comment:/#.*/,key:{pattern:RegExp(`((?:^|[:\\-,[{\\r\\n?])[ \\t]*(?:<>[ \\t]+)?)<>(?=\\s*:\\s)`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return`(?:`+i+`|`+a+`)`})),lookbehind:!0,greedy:!0,alias:`atrule`},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:`important`},datetime:{pattern:o(`\\d{4}-\\d\\d?-\\d\\d?(?:[tT]|[ \\t]+)\\d\\d?:\\d{2}:\\d{2}(?:\\.\\d*)?(?:[ \\t]*(?:Z|[-+]\\d\\d?(?::\\d{2})?))?|\\d{4}-\\d{2}-\\d{2}|\\d\\d?:\\d{2}(?::\\d{2}(?:\\.\\d*)?)?`),lookbehind:!0,alias:`number`},boolean:{pattern:o(`false|true`,`i`),lookbehind:!0,alias:`important`},null:{pattern:o(`null|~`,`i`),lookbehind:!0,alias:`important`},string:{pattern:o(a),lookbehind:!0,greedy:!0},number:{pattern:o(`[+-]?(?:0x[\\da-f]+|0o[0-7]+|(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:e[+-]?\\d+)?|\\.inf|\\.nan)`,`i`),lookbehind:!0},tag:n,important:t,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml}(Q),function(e){function t(e){return e=e.replace(//g,function(){return`(?:\\\\.|[^\\\\\\n\\r]|(?:\\n|\\r\\n?)(?![\\r\\n]))`}),RegExp(`((?:^|[^\\\\])(?:\\\\{2})*)(?:`+e+`)`)}var n="(?:\\\\.|``(?:[^`\\r\\n]|`(?!`))+``|`[^`\\r\\n]+`|[^\\\\|\\r\\n`])+",r=`\\|?__(?:\\|__)+\\|?(?:(?:\\n|\\r\\n?)|(?![\\s\\S]))`.replace(/__/g,function(){return n}),i=`\\|?[ \\t]*:?-{3,}:?[ \\t]*(?:\\|[ \\t]*:?-{3,}:?[ \\t]*)+\\|?(?:\\n|\\r\\n?)`,a=(e.languages.markdown=e.languages.extend(`markup`,{}),e.languages.insertBefore(`markdown`,`prolog`,{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:[`yaml`,`language-yaml`],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:`punctuation`},table:{pattern:RegExp(`^`+r+i+`(?:`+r+`)*`,`m`),inside:{"table-data-rows":{pattern:RegExp(`^(`+r+i+`)(?:`+r+`)*$`),lookbehind:!0,inside:{"table-data":{pattern:RegExp(n),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp(`^(`+r+`)`+i+`$`),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp(`^`+r+`$`),inside:{"table-header":{pattern:RegExp(n),alias:`important`,inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:`keyword`},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:`important`,inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:`important`,inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:`punctuation`},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:`punctuation`},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:`url`},bold:{pattern:t(`\\b__(?:(?!_)|_(?:(?!_))+_)+__\\b|\\*\\*(?:(?!\\*)|\\*(?:(?!\\*))+\\*)+\\*\\*`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:t(`\\b_(?:(?!_)|__(?:(?!_))+__)+_\\b|\\*(?:(?!\\*)|\\*\\*(?:(?!\\*))+\\*\\*)+\\*`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:t(`(~~?)(?:(?!~))+\\2`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:[`code`,`keyword`]},url:{pattern:t(`!?\\[(?:(?!\\]))+\\](?:\\([^\\s)]+(?:[\\t ]+"(?:\\\\.|[^"\\\\])*")?\\)|[ \\t]?\\[(?:(?!\\]))+\\])`),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),[`url`,`bold`,`italic`,`strike`].forEach(function(t){[`url`,`bold`,`italic`,`strike`,`code-snippet`].forEach(function(n){t!==n&&(e.languages.markdown[t].inside.content.inside[n]=e.languages.markdown[n])})}),e.hooks.add(`after-tokenize`,function(e){e.language!==`markdown`&&e.language!==`md`||function e(t){if(t&&typeof t!=`string`)for(var n=0,r=t.length;n`,quot:`"`},s=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown}(Q),Q.languages.graphql={comment:/#.*/,description:{pattern:/(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i,greedy:!0,alias:`string`,inside:{"language-markdown":{pattern:/(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/,lookbehind:!0,inside:Q.languages.markdown}}},string:{pattern:/"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},number:/(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,boolean:/\b(?:false|true)\b/,variable:/\$[a-z_]\w*/i,directive:{pattern:/@[a-z_]\w*/i,alias:`function`},"attr-name":{pattern:/\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,greedy:!0},"atom-input":{pattern:/\b[A-Z]\w*Input\b/,alias:`class-name`},scalar:/\b(?:Boolean|Float|ID|Int|String)\b/,constant:/\b[A-Z][A-Z_\d]*\b/,"class-name":{pattern:/(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/,lookbehind:!0},fragment:{pattern:/(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},"definition-mutation":{pattern:/(\bmutation\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},"definition-query":{pattern:/(\bquery\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},keyword:/\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/,operator:/[!=|&]|\.{3}/,"property-query":/\w+(?=\s*\()/,object:/\w+(?=\s*\{)/,punctuation:/[!(){}\[\]:=,]/,property:/\w+/},Q.hooks.add(`after-tokenize`,function(e){if(e.language===`graphql`)for(var t=e.tokens.filter(function(e){return typeof e!=`string`&&e.type!==`comment`&&e.type!==`scalar`}),n=0;n?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},function(e){var t=e.languages.javascript[`template-string`],n=t.pattern.source,r=t.inside.interpolation,i=r.inside[`interpolation-punctuation`],a=r.pattern.source;function o(t,r){if(e.languages[t])return{pattern:RegExp(`((?:`+r+`)\\s*)`+n),lookbehind:!0,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},"embedded-code":{pattern:/[\s\S]+/,alias:t}}}}function s(t,n,r){return t={code:t,grammar:n,language:r},e.hooks.run(`before-tokenize`,t),t.tokens=e.tokenize(t.code,t.grammar),e.hooks.run(`after-tokenize`,t),t.tokens}function c(t,n,o){var c=e.tokenize(t,{interpolation:{pattern:RegExp(a),lookbehind:!0}}),l=0,u={},c=s(c.map(function(e){if(typeof e==`string`)return e;for(var n,r,e=e.content;t.indexOf((r=l++,n=`___`+o.toUpperCase()+`_`+r+`___`))!==-1;);return u[n]=e,n}).join(``),n,o),d=Object.keys(u);return l=0,function t(n){for(var a=0;a=d.length)return;var o,c,f,p,m,h,g,_=n[a];typeof _==`string`||typeof _.content==`string`?(o=d[l],(g=(h=typeof _==`string`?_:_.content).indexOf(o))!==-1&&(++l,c=h.substring(0,g),m=u[o],f=void 0,(p={})[`interpolation-punctuation`]=i,(p=e.tokenize(m,p)).length===3&&((f=[1,1]).push.apply(f,s(p[1],e.languages.javascript,`javascript`)),p.splice.apply(p,f)),f=new e.Token(`interpolation`,p,r.alias,m),p=h.substring(g+o.length),m=[],c&&m.push(c),m.push(f),p&&(t(h=[p]),m.push.apply(m,h)),typeof _==`string`?(n.splice.apply(n,[a,1].concat(m)),a+=m.length-1):_.content=m)):(g=_.content,t(Array.isArray(g)?g:[g]))}}(c),new e.Token(o,c,`language-`+o,t)}e.languages.javascript[`template-string`]=[o(`css`,`\\b(?:styled(?:\\([^)]*\\))?(?:\\s*\\.\\s*\\w+(?:\\([^)]*\\))*)*|css(?:\\s*\\.\\s*(?:global|resolve))?|createGlobalStyle|keyframes)`),o(`html`,`\\bhtml|\\.\\s*(?:inner|outer)HTML\\s*\\+?=`),o(`svg`,`\\bsvg`),o(`markdown`,`\\b(?:markdown|md)`),o(`graphql`,`\\b(?:gql|graphql(?:\\s*\\.\\s*experimental)?)`),o(`sql`,`\\bsql`),t].filter(Boolean);var l={javascript:!0,js:!0,typescript:!0,ts:!0,jsx:!0,tsx:!0};function u(e){return typeof e==`string`?e:Array.isArray(e)?e.map(u).join(``):u(e.content)}e.hooks.add(`after-tokenize`,function(t){t.language in l&&function t(n){for(var r=0,i=n.length;r]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript[`literal-property`];var t=e.languages.extend(`typescript`,{});delete t[`class-name`],e.languages.typescript[`class-name`].inside=t,e.languages.insertBefore(`typescript`,`function`,{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:`operator`},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:t}}}}),e.languages.ts=e.languages.typescript}(Q),function(e){var t=e.languages.javascript,n=`\\{(?:[^{}]|\\{(?:[^{}]|\\{[^{}]*\\})*\\})+\\}`,r=`(@(?:arg|argument|param|property)\\s+(?:`+n+`\\s+)?)`;e.languages.jsdoc=e.languages.extend(`javadoclike`,{parameter:{pattern:RegExp(r+`(?:(?!\\s)[$\\w\\xA0-\\uFFFF.])+(?=\\s|$)`),lookbehind:!0,inside:{punctuation:/\./}}}),e.languages.insertBefore(`jsdoc`,`keyword`,{"optional-parameter":{pattern:RegExp(r+`\\[(?:(?!\\s)[$\\w\\xA0-\\uFFFF.])+(?:=[^[\\]]+)?\\](?=\\s|$)`),lookbehind:!0,inside:{parameter:{pattern:/(^\[)[$\w\xA0-\uFFFF\.]+/,lookbehind:!0,inside:{punctuation:/\./}},code:{pattern:/(=)[\s\S]*(?=\]$)/,lookbehind:!0,inside:t,alias:`language-javascript`},punctuation:/[=[\]]/}},"class-name":[{pattern:RegExp(`(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\\s+(?:\\s+)?)[A-Z]\\w*(?:\\.[A-Z]\\w*)*`.replace(//g,function(){return n})),lookbehind:!0,inside:{punctuation:/\./}},{pattern:RegExp(`(@[a-z]+\\s+)`+n),lookbehind:!0,inside:{string:t.string,number:t.number,boolean:t.boolean,keyword:e.languages.typescript.keyword,operator:/=>|\.\.\.|[&|?:*]/,punctuation:/[.,;=<>{}()[\]]/}}],example:{pattern:/(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/,lookbehind:!0,inside:{code:{pattern:/^([\t ]*(?:\*\s*)?)\S.*$/m,lookbehind:!0,inside:t,alias:`language-javascript`}}}}),e.languages.javadoclike.addSupport(`javascript`,e.languages.jsdoc)}(Q),function(e){e.languages.flow=e.languages.extend(`javascript`,{}),e.languages.insertBefore(`flow`,`keyword`,{type:[{pattern:/\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|[Ss]ymbol|any|mixed|null|void)\b/,alias:`class-name`}]}),e.languages.flow[`function-variable`].pattern=/(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i,delete e.languages.flow.parameter,e.languages.insertBefore(`flow`,`operator`,{"flow-punctuation":{pattern:/\{\||\|\}/,alias:`punctuation`}}),Array.isArray(e.languages.flow.keyword)||(e.languages.flow.keyword=[e.languages.flow.keyword]),e.languages.flow.keyword.unshift({pattern:/(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,lookbehind:!0},{pattern:/(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,lookbehind:!0})}(Q),Q.languages.n4js=Q.languages.extend(`javascript`,{keyword:/\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/}),Q.languages.insertBefore(`n4js`,`constant`,{annotation:{pattern:/@+\w+/,alias:`operator`}}),Q.languages.n4jsd=Q.languages.n4js,function(e){function t(e,t){return RegExp(e.replace(//g,function(){return`(?!\\s)[_$a-zA-Z\\xA0-\\uFFFF](?:(?!\\s)[$\\w\\xA0-\\uFFFF])*`}),t)}e.languages.insertBefore(`javascript`,`function-variable`,{"method-variable":{pattern:RegExp(`(\\.\\s*)`+e.languages.javascript[`function-variable`].pattern.source),lookbehind:!0,alias:[`function-variable`,`method`,`function`,`property-access`]}}),e.languages.insertBefore(`javascript`,`function`,{method:{pattern:RegExp(`(\\.\\s*)`+e.languages.javascript.function.source),lookbehind:!0,alias:[`function`,`property-access`]}}),e.languages.insertBefore(`javascript`,`constant`,{"known-class-name":[{pattern:/\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/,alias:`class-name`},{pattern:/\b(?:[A-Z]\w*)Error\b/,alias:`class-name`}]}),e.languages.insertBefore(`javascript`,`keyword`,{imports:{pattern:t(`(\\bimport\\b\\s*)(?:(?:\\s*,\\s*(?:\\*\\s*as\\s+|\\{[^{}]*\\}))?|\\*\\s*as\\s+|\\{[^{}]*\\})(?=\\s*\\bfrom\\b)`),lookbehind:!0,inside:e.languages.javascript},exports:{pattern:t(`(\\bexport\\b\\s*)(?:\\*(?:\\s*as\\s+)?(?=\\s*\\bfrom\\b)|\\{[^{}]*\\})`),lookbehind:!0,inside:e.languages.javascript}}),e.languages.javascript.keyword.unshift({pattern:/\b(?:as|default|export|from|import)\b/,alias:`module`},{pattern:/\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/,alias:`control-flow`},{pattern:/\bnull\b/,alias:[`null`,`nil`]},{pattern:/\bundefined\b/,alias:`nil`}),e.languages.insertBefore(`javascript`,`operator`,{spread:{pattern:/\.{3}/,alias:`operator`},arrow:{pattern:/=>/,alias:`operator`}}),e.languages.insertBefore(`javascript`,`punctuation`,{"property-access":{pattern:t(`(\\.\\s*)#?`),lookbehind:!0},"maybe-class-name":{pattern:/(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/,lookbehind:!0},dom:{pattern:/\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/,alias:`variable`},console:{pattern:/\bconsole(?=\s*\.)/,alias:`class-name`}});for(var n=[`function`,`function-variable`,`method`,`method-variable`,`property-access`],r=0;r*\\.{3}(?:[^{}]|)*\\})`;function a(e,t){return e=e.replace(//g,function(){return n}).replace(//g,function(){return r}).replace(//g,function(){return i}),RegExp(e,t)}i=a(i).source,e.languages.jsx=e.languages.extend(`markup`,t),e.languages.jsx.tag.pattern=a(`<\\/?(?:[\\w.:-]+(?:+(?:[\\w.:$-]+(?:=(?:"(?:\\\\[\\s\\S]|[^\\\\"])*"|'(?:\\\\[\\s\\S]|[^\\\\'])*'|[^\\s{'"/>=]+|))?|))**\\/?)?>`),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside[`attr-value`].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside[`class-name`]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore(`inside`,`attr-name`,{spread:{pattern:a(``),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore(`inside`,`special-attr`,{script:{pattern:a(`=`),alias:`language-javascript`,inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:`punctuation`},rest:e.languages.jsx}}},e.languages.jsx.tag);function o(t){for(var n=[],r=0;r`&&n.push({tagName:s(i.content[0].content[1]),openedBraces:0}):0]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:`constant`},"other-directive":{pattern:/#\w+\b/,alias:`property`},attribute:{pattern:/@\w+/,alias:`atrule`},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:`function`},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:`important`},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:`constant`},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:`keyword`},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},Q.languages.swift[`string-literal`].forEach(function(e){e.inside.interpolation.inside=Q.languages.swift}),function(e){e.languages.kotlin=e.languages.extend(`clike`,{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete e.languages.kotlin[`class-name`];var t={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:`punctuation`},expression:{pattern:/[\s\S]+/,inside:e.languages.kotlin}};e.languages.insertBefore(`kotlin`,`string`,{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:`multiline`,inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:t},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:`singleline`,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:t},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete e.languages.kotlin.string,e.languages.insertBefore(`kotlin`,`keyword`,{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:`builtin`}}),e.languages.insertBefore(`kotlin`,`function`,{label:{pattern:/\b\w+@|@\w+\b/,alias:`symbol`}}),e.languages.kt=e.languages.kotlin,e.languages.kts=e.languages.kotlin}(Q),Q.languages.c=Q.languages.extend(`clike`,{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Q.languages.insertBefore(`c`,`string`,{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Q.languages.insertBefore(`c`,`string`,{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:`property`,inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Q.languages.c.string],char:Q.languages.c.char,comment:Q.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:`function`}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:`keyword`},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Q.languages.c}}}}),Q.languages.insertBefore(`c`,`function`,{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Q.languages.c.boolean,Q.languages.objectivec=Q.languages.extend(`c`,{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete Q.languages.objectivec[`class-name`],Q.languages.objc=Q.languages.objectivec,Q.languages.reason=Q.languages.extend(`clike`,{string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},"class-name":/\b[A-Z]\w*/,keyword:/\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|or|private|rec|sig|struct|switch|then|to|try|type|val|virtual|when|while|with)\b/,operator:/\.{3}|:[:=]|\|>|->|=(?:==?|>)?|<=?|>=?|[|^?'#!~`]|[+\-*\/]\.?|\b(?:asr|land|lor|lsl|lsr|lxor|mod)\b/}),Q.languages.insertBefore(`reason`,`class-name`,{char:{pattern:/'(?:\\x[\da-f]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^'\\\r\n])'/,greedy:!0},constructor:/\b[A-Z]\w*\b(?!\s*\.)/,label:{pattern:/\b[a-z]\w*(?=::)/,alias:`symbol`}}),delete Q.languages.reason.function,function(e){for(var t=`\\/\\*(?:[^*/]|\\*(?!\\/)|\\/(?!\\*)|)*\\*\\/`,n=0;n<2;n++)t=t.replace(//g,function(){return t});t=t.replace(//g,function(){return`[^\\s\\S]`}),e.languages.rust={comment:[{pattern:RegExp(`(^|[^\\\\])`+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:`attr-name`,inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:`punctuation`},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:`symbol`},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:`punctuation`},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:`function`},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:`class-name`},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:`namespace`},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:`namespace`,inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:`property`},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<>?=?|[@?]/},e.languages.rust[`closure-params`].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string}(Q),Q.languages.go=Q.languages.extend(`clike`,{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Q.languages.insertBefore(`go`,`string`,{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Q.languages.go[`class-name`],function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=`\\b(?!)\\w+(?:\\s*\\.\\s*\\w+)*\\b`.replace(//g,function(){return t.source});e.languages.cpp=e.languages.extend(`c`,{"class-name":[{pattern:RegExp(`(\\b(?:class|concept|enum|struct|typename)\\s+)(?!)\\w+`.replace(//g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore(`cpp`,`string`,{module:{pattern:RegExp(`(\\b(?:import|module)\\s+)(?:"(?:\\\\(?:\\r\\n|[\\s\\S])|[^"\\\\\\r\\n])*"|<[^<>\\r\\n]*>|`+`(?:\\s*:\\s*)?|:\\s*`.replace(//g,function(){return n})+`)`),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:`string`,greedy:!0}}),e.languages.insertBefore(`cpp`,`keyword`,{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:e.languages.cpp}}}}),e.languages.insertBefore(`cpp`,`operator`,{"double-colon":{pattern:/::/,alias:`punctuation`}}),e.languages.insertBefore(`cpp`,`class-name`,{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend(`cpp`,{})}}),e.languages.insertBefore(`inside`,`double-colon`,{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp[`base-clause`])}(Q),Q.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:`punctuation`},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:`string`},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:[`annotation`,`punctuation`],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Q.languages.python[`string-interpolation`].inside.interpolation.inside.rest=Q.languages.python,Q.languages.py=Q.languages.python,Q.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:`keyword`}},Q.languages.webmanifest=Q.languages.json,ru({},{dracula:()=>au,duotoneDark:()=>ou,duotoneLight:()=>su,github:()=>cu,gruvboxMaterialDark:()=>wu,gruvboxMaterialLight:()=>Tu,jettwaveDark:()=>bu,jettwaveLight:()=>xu,nightOwl:()=>lu,nightOwlLight:()=>uu,oceanicNext:()=>fu,okaidia:()=>pu,oneDark:()=>Su,oneLight:()=>Cu,palenight:()=>mu,shadesOfPurple:()=>hu,synthwave84:()=>gu,ultramin:()=>_u,vsDark:()=>vu,vsLight:()=>yu});var au={plain:{color:`#F8F8F2`,backgroundColor:`#282A36`},styles:[{types:[`prolog`,`constant`,`builtin`],style:{color:`rgb(189, 147, 249)`}},{types:[`inserted`,`function`],style:{color:`rgb(80, 250, 123)`}},{types:[`deleted`],style:{color:`rgb(255, 85, 85)`}},{types:[`changed`],style:{color:`rgb(255, 184, 108)`}},{types:[`punctuation`,`symbol`],style:{color:`rgb(248, 248, 242)`}},{types:[`string`,`char`,`tag`,`selector`],style:{color:`rgb(255, 121, 198)`}},{types:[`keyword`,`variable`],style:{color:`rgb(189, 147, 249)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(98, 114, 164)`}},{types:[`attr-name`],style:{color:`rgb(241, 250, 140)`}}]},ou={plain:{backgroundColor:`#2a2734`,color:`#9a86fd`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`,`punctuation`],style:{color:`#6c6783`}},{types:[`namespace`],style:{opacity:.7}},{types:[`tag`,`operator`,`number`],style:{color:`#e09142`}},{types:[`property`,`function`],style:{color:`#9a86fd`}},{types:[`tag-id`,`selector`,`atrule-id`],style:{color:`#eeebff`}},{types:[`attr-name`],style:{color:`#c4b9fe`}},{types:[`boolean`,`string`,`entity`,`url`,`attr-value`,`keyword`,`control`,`directive`,`unit`,`statement`,`regex`,`atrule`,`placeholder`,`variable`],style:{color:`#ffcc99`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`#c4b9fe`}}]},su={plain:{backgroundColor:`#faf8f5`,color:`#728fcb`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`,`punctuation`],style:{color:`#b6ad9a`}},{types:[`namespace`],style:{opacity:.7}},{types:[`tag`,`operator`,`number`],style:{color:`#063289`}},{types:[`property`,`function`],style:{color:`#b29762`}},{types:[`tag-id`,`selector`,`atrule-id`],style:{color:`#2d2006`}},{types:[`attr-name`],style:{color:`#896724`}},{types:[`boolean`,`string`,`entity`,`url`,`attr-value`,`keyword`,`control`,`directive`,`unit`,`statement`,`regex`,`atrule`],style:{color:`#728fcb`}},{types:[`placeholder`,`variable`],style:{color:`#93abdc`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`#896724`}}]},cu={plain:{color:`#393A34`,backgroundColor:`#f6f8fa`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`],style:{color:`#999988`,fontStyle:`italic`}},{types:[`namespace`],style:{opacity:.7}},{types:[`string`,`attr-value`],style:{color:`#e3116c`}},{types:[`punctuation`,`operator`],style:{color:`#393A34`}},{types:[`entity`,`url`,`symbol`,`number`,`boolean`,`variable`,`constant`,`property`,`regex`,`inserted`],style:{color:`#36acaa`}},{types:[`atrule`,`keyword`,`attr-name`,`selector`],style:{color:`#00a4db`}},{types:[`function`,`deleted`,`tag`],style:{color:`#d73a49`}},{types:[`function-variable`],style:{color:`#6f42c1`}},{types:[`tag`,`selector`,`keyword`],style:{color:`#00009f`}}]},lu={plain:{color:`#d6deeb`,backgroundColor:`#011627`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`,fontStyle:`italic`}},{types:[`inserted`,`attr-name`],style:{color:`rgb(173, 219, 103)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(99, 119, 119)`,fontStyle:`italic`}},{types:[`string`,`url`],style:{color:`rgb(173, 219, 103)`}},{types:[`variable`],style:{color:`rgb(214, 222, 235)`}},{types:[`number`],style:{color:`rgb(247, 140, 108)`}},{types:[`builtin`,`char`,`constant`,`function`],style:{color:`rgb(130, 170, 255)`}},{types:[`punctuation`],style:{color:`rgb(199, 146, 234)`}},{types:[`selector`,`doctype`],style:{color:`rgb(199, 146, 234)`,fontStyle:`italic`}},{types:[`class-name`],style:{color:`rgb(255, 203, 139)`}},{types:[`tag`,`operator`,`keyword`],style:{color:`rgb(127, 219, 202)`}},{types:[`boolean`],style:{color:`rgb(255, 88, 116)`}},{types:[`property`],style:{color:`rgb(128, 203, 196)`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`}}]},uu={plain:{color:`#403f53`,backgroundColor:`#FBFBFB`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`,fontStyle:`italic`}},{types:[`inserted`,`attr-name`],style:{color:`rgb(72, 118, 214)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(152, 159, 177)`,fontStyle:`italic`}},{types:[`string`,`builtin`,`char`,`constant`,`url`],style:{color:`rgb(72, 118, 214)`}},{types:[`variable`],style:{color:`rgb(201, 103, 101)`}},{types:[`number`],style:{color:`rgb(170, 9, 130)`}},{types:[`punctuation`],style:{color:`rgb(153, 76, 195)`}},{types:[`function`,`selector`,`doctype`],style:{color:`rgb(153, 76, 195)`,fontStyle:`italic`}},{types:[`class-name`],style:{color:`rgb(17, 17, 17)`}},{types:[`tag`],style:{color:`rgb(153, 76, 195)`}},{types:[`operator`,`property`,`keyword`,`namespace`],style:{color:`rgb(12, 150, 155)`}},{types:[`boolean`],style:{color:`rgb(188, 84, 84)`}}]},du={char:`#D8DEE9`,comment:`#999999`,keyword:`#c5a5c5`,primitive:`#5a9bcf`,string:`#8dc891`,variable:`#d7deea`,boolean:`#ff8b50`,punctuation:`#5FB3B3`,tag:`#fc929e`,function:`#79b6f2`,className:`#FAC863`,method:`#6699CC`,operator:`#fc929e`},fu={plain:{backgroundColor:`#282c34`,color:`#ffffff`},styles:[{types:[`attr-name`],style:{color:du.keyword}},{types:[`attr-value`],style:{color:du.string}},{types:[`comment`,`block-comment`,`prolog`,`doctype`,`cdata`,`shebang`],style:{color:du.comment}},{types:[`property`,`number`,`function-name`,`constant`,`symbol`,`deleted`],style:{color:du.primitive}},{types:[`boolean`],style:{color:du.boolean}},{types:[`tag`],style:{color:du.tag}},{types:[`string`],style:{color:du.string}},{types:[`punctuation`],style:{color:du.string}},{types:[`selector`,`char`,`builtin`,`inserted`],style:{color:du.char}},{types:[`function`],style:{color:du.function}},{types:[`operator`,`entity`,`url`,`variable`],style:{color:du.variable}},{types:[`keyword`],style:{color:du.keyword}},{types:[`atrule`,`class-name`],style:{color:du.className}},{types:[`important`],style:{fontWeight:`400`}},{types:[`bold`],style:{fontWeight:`bold`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`namespace`],style:{opacity:.7}}]},pu={plain:{color:`#f8f8f2`,backgroundColor:`#272822`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`#f92672`,fontStyle:`italic`}},{types:[`inserted`],style:{color:`rgb(173, 219, 103)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`#8292a2`,fontStyle:`italic`}},{types:[`string`,`url`],style:{color:`#a6e22e`}},{types:[`variable`],style:{color:`#f8f8f2`}},{types:[`number`],style:{color:`#ae81ff`}},{types:[`builtin`,`char`,`constant`,`function`,`class-name`],style:{color:`#e6db74`}},{types:[`punctuation`],style:{color:`#f8f8f2`}},{types:[`selector`,`doctype`],style:{color:`#a6e22e`,fontStyle:`italic`}},{types:[`tag`,`operator`,`keyword`],style:{color:`#66d9ef`}},{types:[`boolean`],style:{color:`#ae81ff`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`,opacity:.7}},{types:[`tag`,`property`],style:{color:`#f92672`}},{types:[`attr-name`],style:{color:`#a6e22e !important`}},{types:[`doctype`],style:{color:`#8292a2`}},{types:[`rule`],style:{color:`#e6db74`}}]},mu={plain:{color:`#bfc7d5`,backgroundColor:`#292d3e`},styles:[{types:[`comment`],style:{color:`rgb(105, 112, 152)`,fontStyle:`italic`}},{types:[`string`,`inserted`],style:{color:`rgb(195, 232, 141)`}},{types:[`number`],style:{color:`rgb(247, 140, 108)`}},{types:[`builtin`,`char`,`constant`,`function`],style:{color:`rgb(130, 170, 255)`}},{types:[`punctuation`,`selector`],style:{color:`rgb(199, 146, 234)`}},{types:[`variable`],style:{color:`rgb(191, 199, 213)`}},{types:[`class-name`,`attr-name`],style:{color:`rgb(255, 203, 107)`}},{types:[`tag`,`deleted`],style:{color:`rgb(255, 85, 114)`}},{types:[`operator`],style:{color:`rgb(137, 221, 255)`}},{types:[`boolean`],style:{color:`rgb(255, 88, 116)`}},{types:[`keyword`],style:{fontStyle:`italic`}},{types:[`doctype`],style:{color:`rgb(199, 146, 234)`,fontStyle:`italic`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`}},{types:[`url`],style:{color:`rgb(221, 221, 221)`}}]},hu={plain:{color:`#9EFEFF`,backgroundColor:`#2D2A55`},styles:[{types:[`changed`],style:{color:`rgb(255, 238, 128)`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`}},{types:[`inserted`],style:{color:`rgb(173, 219, 103)`}},{types:[`comment`],style:{color:`rgb(179, 98, 255)`,fontStyle:`italic`}},{types:[`punctuation`],style:{color:`rgb(255, 255, 255)`}},{types:[`constant`],style:{color:`rgb(255, 98, 140)`}},{types:[`string`,`url`],style:{color:`rgb(165, 255, 144)`}},{types:[`variable`],style:{color:`rgb(255, 238, 128)`}},{types:[`number`,`boolean`],style:{color:`rgb(255, 98, 140)`}},{types:[`attr-name`],style:{color:`rgb(255, 180, 84)`}},{types:[`keyword`,`operator`,`property`,`namespace`,`tag`,`selector`,`doctype`],style:{color:`rgb(255, 157, 0)`}},{types:[`builtin`,`char`,`constant`,`function`,`class-name`],style:{color:`rgb(250, 208, 0)`}}]},gu={plain:{backgroundColor:`linear-gradient(to bottom, #2a2139 75%, #34294f)`,backgroundImage:`#34294f`,color:`#f92aad`,textShadow:`0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3`},styles:[{types:[`comment`,`block-comment`,`prolog`,`doctype`,`cdata`],style:{color:`#495495`,fontStyle:`italic`}},{types:[`punctuation`],style:{color:`#ccc`}},{types:[`tag`,`attr-name`,`namespace`,`number`,`unit`,`hexcode`,`deleted`],style:{color:`#e2777a`}},{types:[`property`,`selector`],style:{color:`#72f1b8`,textShadow:`0 0 2px #100c0f, 0 0 10px #257c5575, 0 0 35px #21272475`}},{types:[`function-name`],style:{color:`#6196cc`}},{types:[`boolean`,`selector-id`,`function`],style:{color:`#fdfdfd`,textShadow:`0 0 2px #001716, 0 0 3px #03edf975, 0 0 5px #03edf975, 0 0 8px #03edf975`}},{types:[`class-name`,`maybe-class-name`,`builtin`],style:{color:`#fff5f6`,textShadow:`0 0 2px #000, 0 0 10px #fc1f2c75, 0 0 5px #fc1f2c75, 0 0 25px #fc1f2c75`}},{types:[`constant`,`symbol`],style:{color:`#f92aad`,textShadow:`0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3`}},{types:[`important`,`atrule`,`keyword`,`selector-class`],style:{color:`#f4eee4`,textShadow:`0 0 2px #393a33, 0 0 8px #f39f0575, 0 0 2px #f39f0575`}},{types:[`string`,`char`,`attr-value`,`regex`,`variable`],style:{color:`#f87c32`}},{types:[`parameter`],style:{fontStyle:`italic`}},{types:[`entity`,`url`],style:{color:`#67cdcc`}},{types:[`operator`],style:{color:`ffffffee`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`entity`],style:{cursor:`help`}},{types:[`inserted`],style:{color:`green`}}]},_u={plain:{color:`#282a2e`,backgroundColor:`#ffffff`},styles:[{types:[`comment`],style:{color:`rgb(197, 200, 198)`}},{types:[`string`,`number`,`builtin`,`variable`],style:{color:`rgb(150, 152, 150)`}},{types:[`class-name`,`function`,`tag`,`attr-name`],style:{color:`rgb(40, 42, 46)`}}]},vu={plain:{color:`#9CDCFE`,backgroundColor:`#1E1E1E`},styles:[{types:[`prolog`],style:{color:`rgb(0, 0, 128)`}},{types:[`comment`],style:{color:`rgb(106, 153, 85)`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`rgb(86, 156, 214)`}},{types:[`number`,`inserted`],style:{color:`rgb(181, 206, 168)`}},{types:[`constant`],style:{color:`rgb(100, 102, 149)`}},{types:[`attr-name`,`variable`],style:{color:`rgb(156, 220, 254)`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`rgb(206, 145, 120)`}},{types:[`selector`],style:{color:`rgb(215, 186, 125)`}},{types:[`tag`],style:{color:`rgb(78, 201, 176)`}},{types:[`tag`],languages:[`markup`],style:{color:`rgb(86, 156, 214)`}},{types:[`punctuation`,`operator`],style:{color:`rgb(212, 212, 212)`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`rgb(220, 220, 170)`}},{types:[`class-name`],style:{color:`rgb(78, 201, 176)`}},{types:[`char`],style:{color:`rgb(209, 105, 105)`}}]},yu={plain:{color:`#000000`,backgroundColor:`#ffffff`},styles:[{types:[`comment`],style:{color:`rgb(0, 128, 0)`}},{types:[`builtin`],style:{color:`rgb(0, 112, 193)`}},{types:[`number`,`variable`,`inserted`],style:{color:`rgb(9, 134, 88)`}},{types:[`operator`],style:{color:`rgb(0, 0, 0)`}},{types:[`constant`,`char`],style:{color:`rgb(129, 31, 63)`}},{types:[`tag`],style:{color:`rgb(128, 0, 0)`}},{types:[`attr-name`],style:{color:`rgb(255, 0, 0)`}},{types:[`deleted`,`string`],style:{color:`rgb(163, 21, 21)`}},{types:[`changed`,`punctuation`],style:{color:`rgb(4, 81, 165)`}},{types:[`function`,`keyword`],style:{color:`rgb(0, 0, 255)`}},{types:[`class-name`],style:{color:`rgb(38, 127, 153)`}}]},bu={plain:{color:`#f8fafc`,backgroundColor:`#011627`},styles:[{types:[`prolog`],style:{color:`#000080`}},{types:[`comment`],style:{color:`#6A9955`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`#569CD6`}},{types:[`number`,`inserted`],style:{color:`#B5CEA8`}},{types:[`constant`],style:{color:`#f8fafc`}},{types:[`attr-name`,`variable`],style:{color:`#9CDCFE`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`#cbd5e1`}},{types:[`selector`],style:{color:`#D7BA7D`}},{types:[`tag`],style:{color:`#0ea5e9`}},{types:[`tag`],languages:[`markup`],style:{color:`#0ea5e9`}},{types:[`punctuation`,`operator`],style:{color:`#D4D4D4`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`#7dd3fc`}},{types:[`class-name`],style:{color:`#0ea5e9`}},{types:[`char`],style:{color:`#D16969`}}]},xu={plain:{color:`#0f172a`,backgroundColor:`#f1f5f9`},styles:[{types:[`prolog`],style:{color:`#000080`}},{types:[`comment`],style:{color:`#6A9955`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`#0c4a6e`}},{types:[`number`,`inserted`],style:{color:`#B5CEA8`}},{types:[`constant`],style:{color:`#0f172a`}},{types:[`attr-name`,`variable`],style:{color:`#0c4a6e`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`#64748b`}},{types:[`selector`],style:{color:`#D7BA7D`}},{types:[`tag`],style:{color:`#0ea5e9`}},{types:[`tag`],languages:[`markup`],style:{color:`#0ea5e9`}},{types:[`punctuation`,`operator`],style:{color:`#475569`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`#0e7490`}},{types:[`class-name`],style:{color:`#0ea5e9`}},{types:[`char`],style:{color:`#D16969`}}]},Su={plain:{backgroundColor:`hsl(220, 13%, 18%)`,color:`hsl(220, 14%, 71%)`,textShadow:`0 1px rgba(0, 0, 0, 0.3)`},styles:[{types:[`comment`,`prolog`,`cdata`],style:{color:`hsl(220, 10%, 40%)`}},{types:[`doctype`,`punctuation`,`entity`],style:{color:`hsl(220, 14%, 71%)`}},{types:[`attr-name`,`class-name`,`maybe-class-name`,`boolean`,`constant`,`number`,`atrule`],style:{color:`hsl(29, 54%, 61%)`}},{types:[`keyword`],style:{color:`hsl(286, 60%, 67%)`}},{types:[`property`,`tag`,`symbol`,`deleted`,`important`],style:{color:`hsl(355, 65%, 65%)`}},{types:[`selector`,`string`,`char`,`builtin`,`inserted`,`regex`,`attr-value`],style:{color:`hsl(95, 38%, 62%)`}},{types:[`variable`,`operator`,`function`],style:{color:`hsl(207, 82%, 66%)`}},{types:[`url`],style:{color:`hsl(187, 47%, 55%)`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`hsl(220, 14%, 71%)`}}]},Cu={plain:{backgroundColor:`hsl(230, 1%, 98%)`,color:`hsl(230, 8%, 24%)`},styles:[{types:[`comment`,`prolog`,`cdata`],style:{color:`hsl(230, 4%, 64%)`}},{types:[`doctype`,`punctuation`,`entity`],style:{color:`hsl(230, 8%, 24%)`}},{types:[`attr-name`,`class-name`,`boolean`,`constant`,`number`,`atrule`],style:{color:`hsl(35, 99%, 36%)`}},{types:[`keyword`],style:{color:`hsl(301, 63%, 40%)`}},{types:[`property`,`tag`,`symbol`,`deleted`,`important`],style:{color:`hsl(5, 74%, 59%)`}},{types:[`selector`,`string`,`char`,`builtin`,`inserted`,`regex`,`attr-value`,`punctuation`],style:{color:`hsl(119, 34%, 47%)`}},{types:[`variable`,`operator`,`function`],style:{color:`hsl(221, 87%, 60%)`}},{types:[`url`],style:{color:`hsl(198, 99%, 37%)`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`hsl(230, 8%, 24%)`}}]},wu={plain:{color:`#ebdbb2`,backgroundColor:`#292828`},styles:[{types:[`imports`,`class-name`,`maybe-class-name`,`constant`,`doctype`,`builtin`,`function`],style:{color:`#d8a657`}},{types:[`property-access`],style:{color:`#7daea3`}},{types:[`tag`],style:{color:`#e78a4e`}},{types:[`attr-name`,`char`,`url`,`regex`],style:{color:`#a9b665`}},{types:[`attr-value`,`string`],style:{color:`#89b482`}},{types:[`comment`,`prolog`,`cdata`,`operator`,`inserted`],style:{color:`#a89984`}},{types:[`delimiter`,`boolean`,`keyword`,`selector`,`important`,`atrule`,`property`,`variable`,`deleted`],style:{color:`#ea6962`}},{types:[`entity`,`number`,`symbol`],style:{color:`#d3869b`}}]},Tu={plain:{color:`#654735`,backgroundColor:`#f9f5d7`},styles:[{types:[`delimiter`,`boolean`,`keyword`,`selector`,`important`,`atrule`,`property`,`variable`,`deleted`],style:{color:`#af2528`}},{types:[`imports`,`class-name`,`maybe-class-name`,`constant`,`doctype`,`builtin`],style:{color:`#b4730e`}},{types:[`string`,`attr-value`],style:{color:`#477a5b`}},{types:[`property-access`],style:{color:`#266b79`}},{types:[`function`,`attr-name`,`char`,`url`],style:{color:`#72761e`}},{types:[`tag`],style:{color:`#b94c07`}},{types:[`comment`,`prolog`,`cdata`,`operator`,`inserted`],style:{color:`#a89984`}},{types:[`entity`,`number`,`symbol`],style:{color:`#924f79`}}]},Eu=e=>(0,V.useCallback)(t=>{var n=t,{className:r,style:i,line:a}=n;let o=eu($l({},tu(n,[`className`,`style`,`line`])),{className:Vl(`token-line`,r)});return typeof e==`object`&&`plain`in e&&(o.style=e.plain),typeof i==`object`&&(o.style=$l($l({},o.style||{}),i)),o},[e]),Du=e=>{let t=(0,V.useCallback)(({types:t,empty:n})=>{if(e!=null)return t.length===1&&t[0]===`plain`?n==null?void 0:{display:`inline-block`}:t.length===1&&n!=null?e[t[0]]:Object.assign(n==null?{}:{display:`inline-block`},...t.map(t=>e[t]))},[e]);return(0,V.useCallback)(e=>{var n=e,{token:r,className:i,style:a}=n;let o=eu($l({},tu(n,[`token`,`className`,`style`])),{className:Vl(`token`,...r.types,i),children:r.content,style:t(r)});return a!=null&&(o.style=$l($l({},o.style||{}),a)),o},[t])},Ou=/\r\n|\r|\n/,ku=e=>{e.length===0?e.push({types:[`plain`],content:` +`,empty:!0}):e.length===1&&e[0].content===``&&(e[0].content=` +`,e[0].empty=!0)},Au=(e,t)=>{let n=e.length;return n>0&&e[n-1]===t?e:e.concat(t)},ju=e=>{let t=[[]],n=[e],r=[0],i=[e.length],a=0,o=0,s=[],c=[s];for(;o>-1;){for(;(a=r[o]++)0?l:[`plain`],e=u):(l=Au(l,u.type),u.alias&&(l=Au(l,u.alias)),e=u.content),typeof e!=`string`){o++,t.push(l),n.push(e),r.push(0),i.push(e.length);continue}let d=e.split(Ou),f=d.length;s.push({types:l,content:d[0]});for(let e=1;e(0,V.useMemo)(()=>{if(n==null)return ju([t]);let i={code:t,grammar:n,language:r,tokens:[]};return e.hooks.run(`before-tokenize`,i),i.tokens=e.tokenize(t,n),e.hooks.run(`after-tokenize`,i),ju(i.tokens)},[t,n,r,e]),Nu=(e,t)=>{let{plain:n}=e,r=e.styles.reduce((e,n)=>{let{languages:r,style:i}=n;return r&&!r.includes(t)||n.types.forEach(t=>{e[t]=$l($l({},e[t]),i)}),e},{});return r.root=n,r.plain=eu($l({},n),{backgroundColor:void 0}),r},Pu=({children:e,language:t,code:n,theme:r,prism:i})=>{let a=t.toLowerCase(),o=Nu(r,a),s=Eu(o),c=Du(o),l=i.languages[a];return e({tokens:Mu({prism:i,language:a,code:n,grammar:l}),className:`prism-code language-${a}`,style:o==null?{}:o.root,getLineProps:s,getTokenProps:c})},Fu=e=>(0,V.createElement)(Pu,eu($l({},e),{prism:e.prism||Q,theme:e.theme||vu,code:e.code,language:e.language})),Iu=i(e(((e,t)=>{var n=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,r={},i={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof a?new a(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,`&`).replace(/`u`)return null;if(document.currentScript&&document.currentScript.tagName===`SCRIPT`)return document.currentScript;try{throw Error()}catch(r){var e=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(r.stack)||[])[1];if(e){var t=document.getElementsByTagName(`script`);for(var n in t)if(t[n].src==e)return t[n]}return null}},isActive:function(e,t,n){for(var r=`no-`+t;e;){var i=e.classList;if(i.contains(t))return!0;if(i.contains(r))return!1;e=e.parentElement}return!!n}},languages:{plain:r,plaintext:r,text:r,txt:r,extend:function(e,t){var n=i.util.clone(i.languages[e]);for(var r in t)n[r]=t[r];return n},insertBefore:function(e,t,n,r){r||=i.languages;var a=r[e],o={};for(var s in a)if(a.hasOwnProperty(s)){if(s==t)for(var c in n)n.hasOwnProperty(c)&&(o[c]=n[c]);n.hasOwnProperty(s)||(o[s]=a[s])}var l=r[e];return r[e]=o,i.languages.DFS(i.languages,function(t,n){n===l&&t!=e&&(this[t]=o)}),o},DFS:function e(t,n,r,a){a||={};var o=i.util.objId;for(var s in t)if(t.hasOwnProperty(s)){n.call(t,s,t[s],r||s);var c=t[s],l=i.util.type(c);l===`Object`&&!a[o(c)]?(a[o(c)]=!0,e(c,n,null,a)):l===`Array`&&!a[o(c)]&&(a[o(c)]=!0,e(c,n,s,a))}}},plugins:{},highlightAll:function(e,t){i.highlightAllUnder(document,e,t)},highlightAllUnder:function(e,t,n){var r={callback:n,container:e,selector:`code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code`};i.hooks.run(`before-highlightall`,r),r.elements=Array.prototype.slice.apply(r.container.querySelectorAll(r.selector)),i.hooks.run(`before-all-elements-highlight`,r);for(var a=0,o;o=r.elements[a++];)i.highlightElement(o,t===!0,r.callback)},highlightElement:function(t,n,r){var a=i.util.getLanguage(t),o=i.languages[a];i.util.setLanguage(t,a);var s=t.parentElement;s&&s.nodeName.toLowerCase()===`pre`&&i.util.setLanguage(s,a);var c={element:t,language:a,grammar:o,code:t.textContent};function l(e){c.highlightedCode=e,i.hooks.run(`before-insert`,c),c.element.innerHTML=c.highlightedCode,i.hooks.run(`after-highlight`,c),i.hooks.run(`complete`,c),r&&r.call(c.element)}if(i.hooks.run(`before-sanity-check`,c),s=c.element.parentElement,s&&s.nodeName.toLowerCase()===`pre`&&!s.hasAttribute(`tabindex`)&&s.setAttribute(`tabindex`,`0`),!c.code){i.hooks.run(`complete`,c),r&&r.call(c.element);return}if(i.hooks.run(`before-highlight`,c),!c.grammar){l(i.util.encode(c.code));return}if(n&&e.Worker){var u=new Worker(i.filename);u.onmessage=function(e){l(e.data)},u.postMessage(JSON.stringify({language:c.language,code:c.code,immediateClose:!0}))}else l(i.highlight(c.code,c.grammar,c.language))},highlight:function(e,t,n){var r={code:e,grammar:t,language:n};if(i.hooks.run(`before-tokenize`,r),!r.grammar)throw Error(`The language "`+r.language+`" has no grammar.`);return r.tokens=i.tokenize(r.code,r.grammar),i.hooks.run(`after-tokenize`,r),a.stringify(i.util.encode(r.tokens),r.language)},tokenize:function(e,t){var n=t.rest;if(n){for(var r in n)t[r]=n[r];delete t.rest}var i=new c;return l(i,i.head,e),s(e,i,t,i.head,0),d(i)},hooks:{all:{},add:function(e,t){var n=i.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=i.hooks.all[e];if(!(!n||!n.length))for(var r=0,a;a=n[r++];)a(t)}},Token:a};e.Prism=i;function a(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.length=(r||``).length|0}a.stringify=function e(t,n){if(typeof t==`string`)return t;if(Array.isArray(t)){var r=``;return t.forEach(function(t){r+=e(t,n)}),r}var a={type:t.type,content:e(t.content,n),tag:`span`,classes:[`token`,t.type],attributes:{},language:n},o=t.alias;o&&(Array.isArray(o)?Array.prototype.push.apply(a.classes,o):a.classes.push(o)),i.hooks.run(`wrap`,a);var s=``;for(var c in a.attributes)s+=` `+c+`="`+(a.attributes[c]||``).replace(/"/g,`"`)+`"`;return`<`+a.tag+` class="`+a.classes.join(` `)+`"`+s+`>`+a.content+``};function o(e,t,n,r){e.lastIndex=t;var i=e.exec(n);if(i&&r&&i[1]){var a=i[1].length;i.index+=a,i[0]=i[0].slice(a)}return i}function s(e,t,n,r,c,d){for(var f in n)if(!(!n.hasOwnProperty(f)||!n[f])){var p=n[f];p=Array.isArray(p)?p:[p];for(var m=0;m=d.reach);C+=S.value.length,S=S.next){var w=S.value;if(t.length>e.length)return;if(!(w instanceof a)){var T=1,E;if(v){if(E=o(x,C,e,_),!E||E.index>=e.length)break;var D=E.index,O=E.index+E[0].length,k=C;for(k+=S.value.length;D>=k;)S=S.next,k+=S.value.length;if(k-=S.value.length,C=k,S.value instanceof a)continue;for(var A=S;A!==t.tail&&(kd.reach&&(d.reach=P);var F=S.prev;M&&(F=l(t,F,M),C+=M.length),u(t,F,T);var I=new a(f,g?i.tokenize(j,g):j,y,j);if(S=l(t,F,I),N&&l(t,S,N),T>1){var L={cause:f+`,`+m,reach:P};s(e,t,n,S.prev,C,L),d&&L.reach>d.reach&&(d.reach=L.reach)}}}}}}function c(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function l(e,t,n){var r=t.next,i={value:n,prev:t,next:r};return t.next=i,r.prev=i,e.length++,i}function u(e,t,n){for(var r=t.next,i=0;i/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:`attr-equals`},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:`named-entity`},/&#x?[\da-f]{1,8};/i]},n.languages.markup.tag.inside[`attr-value`].inside.entity=n.languages.markup.entity,n.languages.markup.doctype.inside[`internal-subset`].inside=n.languages.markup,n.hooks.add(`wrap`,function(e){e.type===`entity`&&(e.attributes.title=e.content.replace(/&/,`&`))}),Object.defineProperty(n.languages.markup.tag,"addInlined",{value:function(e,t){var r={};r[`language-`+t]={pattern:/(^$)/i,lookbehind:!0,inside:n.languages[t]},r.cdata=/^$/i;var i={"included-cdata":{pattern://i,inside:r}};i[`language-`+t]={pattern:/[\s\S]+/,inside:n.languages[t]};var a={};a[e]={pattern:RegExp(`(<__[^>]*>)(?:))*\\]\\]>|(?!)`.replace(/__/g,function(){return e}),`i`),lookbehind:!0,greedy:!0,inside:i},n.languages.insertBefore(`markup`,`cdata`,a)}}),Object.defineProperty(n.languages.markup.tag,"addAttribute",{value:function(e,t){n.languages.markup.tag.inside[`special-attr`].push({pattern:RegExp(`(^|["'\\s])(?:`+e+`)\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s'">=]+(?=[\\s>]))`,`i`),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,`language-`+t],inside:n.languages[t]},punctuation:[{pattern:/^=/,alias:`attr-equals`},/"|'/]}}}})}}),n.languages.html=n.languages.markup,n.languages.mathml=n.languages.markup,n.languages.svg=n.languages.markup,n.languages.xml=n.languages.extend(`markup`,{}),n.languages.ssml=n.languages.xml,n.languages.atom=n.languages.xml,n.languages.rss=n.languages.xml,(function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp(`@[\\w-](?:[^;{\\s"']|\\s+(?!\\s)|`+t.source+`)*?(?:;|(?=\\s*\\{))`),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:`selector`},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp(`\\burl\\((?:`+t.source+`|(?:[^\\\\\\r\\n()"']|\\\\[\\s\\S])*)\\)`,`i`),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp(`^`+t.source+`$`),alias:`url`}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+t.source+`)*(?=\\s*\\{)`),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined(`style`,`css`),n.tag.addAttribute(`style`,`css`))})(n),n.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},n.languages.javascript=n.languages.extend(`clike`,{"class-name":[n.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),n.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,n.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:n.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:n.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:n.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:n.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:n.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),n.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:n.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),n.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),n.languages.markup&&(n.languages.markup.tag.addInlined(`script`,`javascript`),n.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),n.languages.js=n.languages.javascript,(function(){if(n===void 0||typeof document>`u`)return;Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e=`Loading…`,t=function(e,t){return`✖ Error `+e+` while fetching file: `+t},r=`✖ Error: File does not exist or is empty`,i={js:`javascript`,py:`python`,rb:`ruby`,ps1:`powershell`,psm1:`powershell`,sh:`bash`,bat:`batch`,h:`c`,tex:`latex`},a=`data-src-status`,o=`loading`,s=`loaded`,c=`failed`,l=`pre[data-src]:not([`+a+`="`+s+`"]):not([`+a+`="`+o+`"])`;function u(e,n,i){var a=new XMLHttpRequest;a.open(`GET`,e,!0),a.onreadystatechange=function(){a.readyState==4&&(a.status<400&&a.responseText?n(a.responseText):a.status>=400?i(t(a.status,a.statusText)):i(r))},a.send(null)}function d(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||``);if(t){var n=Number(t[1]),r=t[2],i=t[3];return r?i?[n,Number(i)]:[n,void 0]:[n,n]}}n.hooks.add(`before-highlightall`,function(e){e.selector+=`, `+l}),n.hooks.add(`before-sanity-check`,function(t){var r=t.element;if(r.matches(l)){t.code=``,r.setAttribute(a,o);var f=r.appendChild(document.createElement(`CODE`));f.textContent=e;var p=r.getAttribute(`data-src`),m=t.language;if(m===`none`){var h=(/\.(\w+)$/.exec(p)||[,`none`])[1];m=i[h]||h}n.util.setLanguage(f,m),n.util.setLanguage(r,m);var g=n.plugins.autoloader;g&&g.loadLanguages(m),u(p,function(e){r.setAttribute(a,s);var t=d(r.getAttribute(`data-range`));if(t){var i=e.split(/\r\n?|\n/g),o=t[0],c=t[1]==null?i.length:t[1];o<0&&(o+=i.length),o=Math.max(0,Math.min(o-1,i.length)),c<0&&(c+=i.length),c=Math.max(0,Math.min(c,i.length)),e=i.slice(o,c).join(` +`),r.hasAttribute(`data-start`)||r.setAttribute(`data-start`,String(o+1))}f.textContent=e,n.highlightElement(f)},function(e){r.setAttribute(a,c),f.textContent=e})}}),n.plugins.fileHighlight={highlight:function(e){for(var t=(e||document).querySelectorAll(l),r=0,i;i=t[r++];)n.highlightElement(i)}};var f=!1;n.fileHighlight=function(){f||=(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),!0),n.plugins.fileHighlight.highlight.apply(this,arguments)}})()}))(),1);(function(e){function t(e,t){return e.replace(/<<(\d+)>>/g,function(e,n){return`(?:`+t[+n]+`)`})}function n(e,n,r){return RegExp(t(e,n),r||``)}function r(e,t){for(var n=0;n>/g,function(){return`(?:`+e+`)`});return e.replace(/<>/g,`[^\\s\\S]`)}var i={type:`bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void`,typeDeclaration:`class enum interface record struct`,contextual:`add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)`,other:`abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield`};function a(e){return`\\b(?:`+e.trim().replace(/ /g,`|`)+`)\\b`}var o=a(i.typeDeclaration),s=RegExp(a(i.type+` `+i.typeDeclaration+` `+i.contextual+` `+i.other)),c=a(i.typeDeclaration+` `+i.contextual+` `+i.other),l=a(i.type+` `+i.typeDeclaration+` `+i.other),u=r(`<(?:[^<>;=+\\-*/%&|^]|<>)*>`,2),d=r(`\\((?:[^()]|<>)*\\)`,2),f=`@?\\b[A-Za-z_]\\w*\\b`,p=t(`<<0>>(?:\\s*<<1>>)?`,[f,u]),m=t(`(?!<<0>>)<<1>>(?:\\s*\\.\\s*<<1>>)*`,[c,p]),h=`\\[\\s*(?:,\\s*)*\\]`,g=t(`<<0>>(?:\\s*(?:\\?\\s*)?<<1>>)*(?:\\s*\\?)?`,[m,h]),_=t(`(?:<<0>>|<<1>>)(?:\\s*(?:\\?\\s*)?<<2>>)*(?:\\s*\\?)?`,[t(`\\(<<0>>+(?:,<<0>>+)+\\)`,[t(`[^,()<>[\\];=+\\-*/%&|^]|<<0>>|<<1>>|<<2>>`,[u,d,h])]),m,h]),v={keyword:s,punctuation:/[<>()?,.:[\]]/},y=`'(?:[^\\r\\n'\\\\]|\\\\.|\\\\[Uux][\\da-fA-F]{1,8})'`,b=`"(?:\\\\.|[^\\\\"\\r\\n])*"`,x=`@"(?:""|\\\\[\\s\\S]|[^\\\\"])*"(?!")`;e.languages.csharp=e.languages.extend(`clike`,{string:[{pattern:n(`(^|[^$\\\\])<<0>>`,[x]),lookbehind:!0,greedy:!0},{pattern:n(`(^|[^@$\\\\])<<0>>`,[b]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:n(`(\\busing\\s+static\\s+)<<0>>(?=\\s*;)`,[m]),lookbehind:!0,inside:v},{pattern:n(`(\\busing\\s+<<0>>\\s*=\\s*)<<1>>(?=\\s*;)`,[f,_]),lookbehind:!0,inside:v},{pattern:n(`(\\busing\\s+)<<0>>(?=\\s*=)`,[f]),lookbehind:!0},{pattern:n(`(\\b<<0>>\\s+)<<1>>`,[o,p]),lookbehind:!0,inside:v},{pattern:n(`(\\bcatch\\s*\\(\\s*)<<0>>`,[m]),lookbehind:!0,inside:v},{pattern:n(`(\\bwhere\\s+)<<0>>`,[f]),lookbehind:!0},{pattern:n(`(\\b(?:is(?:\\s+not)?|as)\\s+)<<0>>`,[g]),lookbehind:!0,inside:v},{pattern:n(`\\b<<0>>(?=\\s+(?!<<1>>|with\\s*\\{)<<2>>(?:\\s*[=,;:{)\\]]|\\s+(?:in|when)\\b))`,[_,l,f]),inside:v}],keyword:s,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),e.languages.insertBefore(`csharp`,`number`,{range:{pattern:/\.\./,alias:`operator`}}),e.languages.insertBefore(`csharp`,`punctuation`,{"named-parameter":{pattern:n(`([(,]\\s*)<<0>>(?=\\s*:)`,[f]),lookbehind:!0,alias:`punctuation`}}),e.languages.insertBefore(`csharp`,`class-name`,{namespace:{pattern:n(`(\\b(?:namespace|using)\\s+)<<0>>(?:\\s*\\.\\s*<<0>>)*(?=\\s*[;{])`,[f]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:n(`(\\b(?:default|sizeof|typeof)\\s*\\(\\s*(?!\\s))(?:[^()\\s]|\\s(?!\\s)|<<0>>)*(?=\\s*\\))`,[d]),lookbehind:!0,alias:`class-name`,inside:v},"return-type":{pattern:n(`<<0>>(?=\\s+(?:<<1>>\\s*(?:=>|[({]|\\.\\s*this\\s*\\[)|this\\s*\\[))`,[_,m]),inside:v,alias:`class-name`},"constructor-invocation":{pattern:n(`(\\bnew\\s+)<<0>>(?=\\s*[[({])`,[_]),lookbehind:!0,inside:v,alias:`class-name`},"generic-method":{pattern:n(`<<0>>\\s*<<1>>(?=\\s*\\()`,[f,u]),inside:{function:n(`^<<0>>`,[f]),generic:{pattern:RegExp(u),alias:`class-name`,inside:v}}},"type-list":{pattern:n(`\\b((?:<<0>>\\s+<<1>>|record\\s+<<1>>\\s*<<5>>|where\\s+<<2>>)\\s*:\\s*)(?:<<3>>|<<4>>|<<1>>\\s*<<5>>|<<6>>)(?:\\s*,\\s*(?:<<3>>|<<4>>|<<6>>))*(?=\\s*(?:where|[{;]|=>|$))`,[o,p,f,_,s.source,d,`\\bnew\\s*\\(\\s*\\)`]),lookbehind:!0,inside:{"record-arguments":{pattern:n(`(^(?!new\\s*\\()<<0>>\\s*)<<1>>`,[p,d]),lookbehind:!0,greedy:!0,inside:e.languages.csharp},keyword:s,"class-name":{pattern:RegExp(_),greedy:!0,inside:v},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:`property`,inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:`keyword`}}}});var S=b+`|`+y,C=t(`\\/(?![*/])|\\/\\/[^\\r\\n]*[\\r\\n]|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/|<<0>>`,[S]),w=r(t(`[^"'/()]|<<0>>|\\(<>*\\)`,[C]),2),T=`\\b(?:assembly|event|field|method|module|param|property|return|type)\\b`,E=t(`<<0>>(?:\\s*\\(<<1>>*\\))?`,[m,w]);e.languages.insertBefore(`csharp`,`class-name`,{attribute:{pattern:n(`((?:^|[^\\s\\w>)?])\\s*\\[\\s*)(?:<<0>>\\s*:\\s*)?<<1>>(?:\\s*,\\s*<<1>>)*(?=\\s*\\])`,[T,E]),lookbehind:!0,greedy:!0,inside:{target:{pattern:n(`^<<0>>(?=\\s*:)`,[T]),alias:`keyword`},"attribute-arguments":{pattern:n(`\\(<<0>>*\\)`,[w]),inside:e.languages.csharp},"class-name":{pattern:RegExp(m),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var D=`:[^}\\r\\n]+`,O=r(t(`[^"'/()]|<<0>>|\\(<>*\\)`,[C]),2),k=t(`\\{(?!\\{)(?:(?![}:])<<0>>)*<<1>>?\\}`,[O,D]),A=r(t(`[^"'/()]|\\/(?!\\*)|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/|<<0>>|\\(<>*\\)`,[S]),2),j=t(`\\{(?!\\{)(?:(?![}:])<<0>>)*<<1>>?\\}`,[A,D]);function M(t,r){return{interpolation:{pattern:n(`((?:^|[^{])(?:\\{\\{)*)<<0>>`,[t]),lookbehind:!0,inside:{"format-string":{pattern:n(`(^\\{(?:(?![}:])<<0>>)*)<<1>>(?=\\}$)`,[r,D]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:`language-csharp`,inside:e.languages.csharp}}},string:/[\s\S]+/}}e.languages.insertBefore(`csharp`,`string`,{"interpolation-string":[{pattern:n(`(^|[^\\\\])(?:\\$@|@\\$)"(?:""|\\\\[\\s\\S]|\\{\\{|<<0>>|[^\\\\{"])*"`,[k]),lookbehind:!0,greedy:!0,inside:M(k,O)},{pattern:n(`(^|[^@\\\\])\\$"(?:\\\\.|\\{\\{|<<0>>|[^\\\\"{])*"`,[j]),lookbehind:!0,greedy:!0,inside:M(j,A)}],char:{pattern:RegExp(y),greedy:!0}}),e.languages.dotnet=e.languages.cs=e.languages.csharp})(Prism),Prism.languages.c=Prism.languages.extend(`clike`,{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore(`c`,`string`,{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore(`c`,`string`,{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:`property`,inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:`function`}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:`keyword`},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore(`c`,`function`,{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean,(function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=`\\b(?!)\\w+(?:\\s*\\.\\s*\\w+)*\\b`.replace(//g,function(){return t.source});e.languages.cpp=e.languages.extend(`c`,{"class-name":[{pattern:RegExp(`(\\b(?:class|concept|enum|struct|typename)\\s+)(?!)\\w+`.replace(//g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore(`cpp`,`string`,{module:{pattern:RegExp(`(\\b(?:import|module)\\s+)(?:"(?:\\\\(?:\\r\\n|[\\s\\S])|[^"\\\\\\r\\n])*"|<[^<>\\r\\n]*>|`+`(?:\\s*:\\s*)?|:\\s*`.replace(//g,function(){return n})+`)`),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:`string`,greedy:!0}}),e.languages.insertBefore(`cpp`,`keyword`,{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:e.languages.cpp}}}}),e.languages.insertBefore(`cpp`,`operator`,{"double-colon":{pattern:/::/,alias:`punctuation`}}),e.languages.insertBefore(`cpp`,`class-name`,{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend(`cpp`,{})}}),e.languages.insertBefore(`inside`,`double-colon`,{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp[`base-clause`])})(Prism),Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:`punctuation`},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:`string`},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:[`annotation`,`punctuation`],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python[`string-interpolation`].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python,Prism.languages.javascript=Prism.languages.extend(`clike`,{"class-name":[Prism.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Prism.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Prism.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Prism.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),Prism.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),Prism.languages.markup&&(Prism.languages.markup.tag.addInlined(`script`,`javascript`),Prism.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),Prism.languages.js=Prism.languages.javascript,(function(e){var t=e.util.clone(e.languages.javascript),n=`(?:\\s|\\/\\/.*(?!.)|\\/\\*(?:[^*]|\\*(?!\\/))\\*\\/)`,r=`(?:\\{(?:\\{(?:\\{[^{}]*\\}|[^{}])*\\}|[^{}])*\\})`,i=`(?:\\{*\\.{3}(?:[^{}]|)*\\})`;function a(e,t){return e=e.replace(//g,function(){return n}).replace(//g,function(){return r}).replace(//g,function(){return i}),RegExp(e,t)}i=a(i).source,e.languages.jsx=e.languages.extend(`markup`,t),e.languages.jsx.tag.pattern=a(`<\\/?(?:[\\w.:-]+(?:+(?:[\\w.:$-]+(?:=(?:"(?:\\\\[\\s\\S]|[^\\\\"])*"|'(?:\\\\[\\s\\S]|[^\\\\'])*'|[^\\s{'"/>=]+|))?|))**\\/?)?>`),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside[`attr-value`].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside[`class-name`]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore(`inside`,`attr-name`,{spread:{pattern:a(``),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore(`inside`,`special-attr`,{script:{pattern:a(`=`),alias:`language-javascript`,inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:`punctuation`},rest:e.languages.jsx}}},e.languages.jsx.tag);var o=function(e){return e?typeof e==`string`?e:typeof e.content==`string`?e.content:e.content.map(o).join(``):``},s=function(t){for(var n=[],r=0;r0&&n[n.length-1].tagName===o(i.content[0].content[1])&&n.pop():i.content[i.content.length-1].content===`/>`||n.push({tagName:o(i.content[0].content[1]),openedBraces:0}):n.length>0&&i.type===`punctuation`&&i.content===`{`?n[n.length-1].openedBraces++:n.length>0&&n[n.length-1].openedBraces>0&&i.type===`punctuation`&&i.content===`}`?n[n.length-1].openedBraces--:a=!0),(a||typeof i==`string`)&&n.length>0&&n[n.length-1].openedBraces===0){var c=o(i);r0&&(typeof t[r-1]==`string`||t[r-1].type===`plain-text`)&&(c=o(t[r-1])+c,t.splice(r-1,1),r--),t[r]=new e.Token(`plain-text`,c,null,c)}i.content&&typeof i.content!=`string`&&s(i.content)}};e.hooks.add(`after-tokenize`,function(e){(e.language===`jsx`||e.language===`tsx`)&&s(e.tokens)})})(Prism),(function(e){e.languages.typescript=e.languages.extend(`javascript`,{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript[`literal-property`];var t=e.languages.extend(`typescript`,{});delete t[`class-name`],e.languages.typescript[`class-name`].inside=t,e.languages.insertBefore(`typescript`,`function`,{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:`operator`},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:t}}}}),e.languages.ts=e.languages.typescript})(Prism),(function(e){var t=e.util.clone(e.languages.typescript);e.languages.tsx=e.languages.extend(`jsx`,t),delete e.languages.tsx.parameter,delete e.languages.tsx[`literal-property`];var n=e.languages.tsx.tag;n.pattern=RegExp(`(^|[^\\w$]|(?=<\\/))(?:`+n.pattern.source+`)`,n.pattern.flags),n.lookbehind=!0})(Prism),Prism.languages.go=Prism.languages.extend(`clike`,{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore(`go`,`string`,{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go[`class-name`],(function(e){for(var t=`\\/\\*(?:[^*/]|\\*(?!\\/)|\\/(?!\\*)|)*\\*\\/`,n=0;n<2;n++)t=t.replace(//g,function(){return t});t=t.replace(//g,function(){return`[^\\s\\S]`}),e.languages.rust={comment:[{pattern:RegExp(`(^|[^\\\\])`+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:`attr-name`,inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:`punctuation`},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:`symbol`},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:`punctuation`},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:`function`},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:`class-name`},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:`namespace`},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:`namespace`,inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:`property`},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<>?=?|[@?]/},e.languages.rust[`closure-params`].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string})(Prism),(function(e){var t=`\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b`,n={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:`punctuation`,inside:null},r={bash:n,environment:{pattern:RegExp(`\\$`+t),alias:`constant`},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp(`(\\{)`+t),lookbehind:!0,alias:`constant`}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:`important`},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:`function`},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:`function`}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:`variable`,lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp(`(^|[\\s;|&]|[<>]\\()`+t),lookbehind:!0,alias:`constant`}},alias:`variable`,lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:`variable`,lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:r},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:n}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:r},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:r.entity}}],environment:{pattern:RegExp(`\\$?`+t),alias:`constant`},variable:r.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:`class-name`},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:`important`},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:`important`}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},n.inside=e.languages.bash;for(var i=[`comment`,`function-name`,`for-or-select`,`assign-left`,`parameter`,`string`,`environment`,`function`,`keyword`,`builtin`,`boolean`,`file-descriptor`,`operator`,`punctuation`,`number`],a=r.variable[1].inside,o=0;o)?|)`.replace(//g,function(){return`\\\\[\\r\\n](?:\\s|\\\\[\\r\\n]|#.*(?!.))*(?![\\s#]|\\\\[\\r\\n])`}),n=`"(?:[^"\\\\\\r\\n]|\\\\(?:\\r\\n|[\\s\\S]))*"|'(?:[^'\\\\\\r\\n]|\\\\(?:\\r\\n|[\\s\\S]))*'`,r=`--[\\w-]+=(?:|(?!["'])(?:[^\\s\\\\]|\\\\.)+)`.replace(//g,function(){return n}),i={pattern:RegExp(n),greedy:!0},a={pattern:/(^[ \t]*)#.*/m,lookbehind:!0,greedy:!0};function o(e,n){return e=e.replace(//g,function(){return r}).replace(//g,function(){return t}),RegExp(e,n)}e.languages.docker={instruction:{pattern:/(^[ \t]*)(?:ADD|ARG|CMD|COPY|ENTRYPOINT|ENV|EXPOSE|FROM|HEALTHCHECK|LABEL|MAINTAINER|ONBUILD|RUN|SHELL|STOPSIGNAL|USER|VOLUME|WORKDIR)(?=\s)(?:\\.|[^\r\n\\])*(?:\\$(?:\s|#.*$)*(?![\s#])(?:\\.|[^\r\n\\])*)*/im,lookbehind:!0,greedy:!0,inside:{options:{pattern:o(`(^(?:ONBUILD)?\\w+)(?:)*`,`i`),lookbehind:!0,greedy:!0,inside:{property:{pattern:/(^|\s)--[\w-]+/,lookbehind:!0},string:[i,{pattern:/(=)(?!["'])(?:[^\s\\]|\\.)+/,lookbehind:!0}],operator:/\\$/m,punctuation:/=/}},keyword:[{pattern:o(`(^(?:ONBUILD)?HEALTHCHECK(?:)*)(?:CMD|NONE)\\b`,`i`),lookbehind:!0,greedy:!0},{pattern:o(`(^(?:ONBUILD)?FROM(?:)*(?!--)[^ \\t\\\\]+)AS`,`i`),lookbehind:!0,greedy:!0},{pattern:o(`(^ONBUILD)\\w+`,`i`),lookbehind:!0,greedy:!0},{pattern:/^\w+/,greedy:!0}],comment:a,string:i,variable:/\$(?:\w+|\{[^{}"'\\]*\})/,operator:/\\$/m}},comment:a},e.languages.dockerfile=e.languages.docker})(Prism),Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},Prism.languages.plsql=Prism.languages.extend(`sql`,{comment:{pattern:/\/\*[\s\S]*?\*\/|--.*/,greedy:!0},keyword:/\b(?:A|ACCESSIBLE|ADD|AGENT|AGGREGATE|ALL|ALTER|AND|ANY|ARRAY|AS|ASC|AT|ATTRIBUTE|AUTHID|AVG|BEGIN|BETWEEN|BFILE_BASE|BINARY|BLOB_BASE|BLOCK|BODY|BOTH|BOUND|BULK|BY|BYTE|C|CALL|CALLING|CASCADE|CASE|CHAR|CHARACTER|CHARSET|CHARSETFORM|CHARSETID|CHAR_BASE|CHECK|CLOB_BASE|CLONE|CLOSE|CLUSTER|CLUSTERS|COLAUTH|COLLECT|COLUMNS|COMMENT|COMMIT|COMMITTED|COMPILED|COMPRESS|CONNECT|CONSTANT|CONSTRUCTOR|CONTEXT|CONTINUE|CONVERT|COUNT|CRASH|CREATE|CREDENTIAL|CURRENT|CURSOR|CUSTOMDATUM|DANGLING|DATA|DATE|DATE_BASE|DAY|DECLARE|DEFAULT|DEFINE|DELETE|DESC|DETERMINISTIC|DIRECTORY|DISTINCT|DOUBLE|DROP|DURATION|ELEMENT|ELSE|ELSIF|EMPTY|END|ESCAPE|EXCEPT|EXCEPTION|EXCEPTIONS|EXCLUSIVE|EXECUTE|EXISTS|EXIT|EXTERNAL|FETCH|FINAL|FIRST|FIXED|FLOAT|FOR|FORALL|FORCE|FROM|FUNCTION|GENERAL|GOTO|GRANT|GROUP|HASH|HAVING|HEAP|HIDDEN|HOUR|IDENTIFIED|IF|IMMEDIATE|IMMUTABLE|IN|INCLUDING|INDEX|INDEXES|INDICATOR|INDICES|INFINITE|INSERT|INSTANTIABLE|INT|INTERFACE|INTERSECT|INTERVAL|INTO|INVALIDATE|IS|ISOLATION|JAVA|LANGUAGE|LARGE|LEADING|LENGTH|LEVEL|LIBRARY|LIKE|LIKE2|LIKE4|LIKEC|LIMIT|LIMITED|LOCAL|LOCK|LONG|LOOP|MAP|MAX|MAXLEN|MEMBER|MERGE|MIN|MINUS|MINUTE|MOD|MODE|MODIFY|MONTH|MULTISET|MUTABLE|NAME|NAN|NATIONAL|NATIVE|NCHAR|NEW|NOCOMPRESS|NOCOPY|NOT|NOWAIT|NULL|NUMBER_BASE|OBJECT|OCICOLL|OCIDATE|OCIDATETIME|OCIDURATION|OCIINTERVAL|OCILOBLOCATOR|OCINUMBER|OCIRAW|OCIREF|OCIREFCURSOR|OCIROWID|OCISTRING|OCITYPE|OF|OLD|ON|ONLY|OPAQUE|OPEN|OPERATOR|OPTION|OR|ORACLE|ORADATA|ORDER|ORGANIZATION|ORLANY|ORLVARY|OTHERS|OUT|OVERLAPS|OVERRIDING|PACKAGE|PARALLEL_ENABLE|PARAMETER|PARAMETERS|PARENT|PARTITION|PASCAL|PERSISTABLE|PIPE|PIPELINED|PLUGGABLE|POLYMORPHIC|PRAGMA|PRECISION|PRIOR|PRIVATE|PROCEDURE|PUBLIC|RAISE|RANGE|RAW|READ|RECORD|REF|REFERENCE|RELIES_ON|REM|REMAINDER|RENAME|RESOURCE|RESULT|RESULT_CACHE|RETURN|RETURNING|REVERSE|REVOKE|ROLLBACK|ROW|SAMPLE|SAVE|SAVEPOINT|SB1|SB2|SB4|SECOND|SEGMENT|SELECT|SELF|SEPARATE|SEQUENCE|SERIALIZABLE|SET|SHARE|SHORT|SIZE|SIZE_T|SOME|SPARSE|SQL|SQLCODE|SQLDATA|SQLNAME|SQLSTATE|STANDARD|START|STATIC|STDDEV|STORED|STRING|STRUCT|STYLE|SUBMULTISET|SUBPARTITION|SUBSTITUTABLE|SUBTYPE|SUM|SYNONYM|TABAUTH|TABLE|TDO|THE|THEN|TIME|TIMESTAMP|TIMEZONE_ABBR|TIMEZONE_HOUR|TIMEZONE_MINUTE|TIMEZONE_REGION|TO|TRAILING|TRANSACTION|TRANSACTIONAL|TRUSTED|TYPE|UB1|UB2|UB4|UNDER|UNION|UNIQUE|UNPLUG|UNSIGNED|UNTRUSTED|UPDATE|USE|USING|VALIST|VALUE|VALUES|VARIABLE|VARIANCE|VARRAY|VARYING|VIEW|VIEWS|VOID|WHEN|WHERE|WHILE|WITH|WORK|WRAPPED|WRITE|YEAR|ZONE)\b/i,operator:/:=?|=>|[<>^~!]=|\.\.|\|\||\*\*|[-+*/%<>=@]/}),Prism.languages.insertBefore(`plsql`,`operator`,{label:{pattern:/<<\s*\w+\s*>>/,alias:`symbol`}}),Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:`keyword`}},Prism.languages.webmanifest=Prism.languages.json,(function(e){var t=/[*&][^\s[\]{},]+/,n=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,r=`(?:`+n.source+`(?:[ ]+`+t.source+`)?|`+t.source+`(?:[ ]+`+n.source+`)?)`,i=`(?:[^\\s\\x00-\\x08\\x0e-\\x1f!"#%&'*,\\-:>?@[\\]\`{|}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]|[?:-])(?:[ \\t]*(?:(?![#:])|:))*`.replace(//g,function(){return`[^\\s\\x00-\\x08\\x0e-\\x1f,[\\]{}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]`}),a=`"(?:[^"\\\\\\r\\n]|\\\\.)*"|'(?:[^'\\\\\\r\\n]|\\\\.)*'`;function o(e,t){t=(t||``).replace(/m/g,``)+`m`;var n=`([:\\-,[{]\\s*(?:\\s<>[ \\t]+)?)(?:<>)(?=[ \\t]*(?:$|,|\\]|\\}|(?:[\\r\\n]\\s*)?#))`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return e});return RegExp(n,t)}e.languages.yaml={scalar:{pattern:RegExp(`([\\-:]\\s*(?:\\s<>[ \\t]+)?[|>])[ \\t]*(?:((?:\\r?\\n|\\r)[ \\t]+)\\S[^\\r\\n]*(?:\\2[^\\r\\n]+)*)`.replace(/<>/g,function(){return r})),lookbehind:!0,alias:`string`},comment:/#.*/,key:{pattern:RegExp(`((?:^|[:\\-,[{\\r\\n?])[ \\t]*(?:<>[ \\t]+)?)<>(?=\\s*:\\s)`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return`(?:`+i+`|`+a+`)`})),lookbehind:!0,greedy:!0,alias:`atrule`},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:`important`},datetime:{pattern:o(`\\d{4}-\\d\\d?-\\d\\d?(?:[tT]|[ \\t]+)\\d\\d?:\\d{2}:\\d{2}(?:\\.\\d*)?(?:[ \\t]*(?:Z|[-+]\\d\\d?(?::\\d{2})?))?|\\d{4}-\\d{2}-\\d{2}|\\d\\d?:\\d{2}(?::\\d{2}(?:\\.\\d*)?)?`),lookbehind:!0,alias:`number`},boolean:{pattern:o(`false|true`,`i`),lookbehind:!0,alias:`important`},null:{pattern:o(`null|~`,`i`),lookbehind:!0,alias:`important`},string:{pattern:o(a),lookbehind:!0,greedy:!0},number:{pattern:o(`[+-]?(?:0x[\\da-f]+|0o[0-7]+|(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:e[+-]?\\d+)?|\\.inf|\\.nan)`,`i`),lookbehind:!0},tag:n,important:t,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml})(Prism),Prism.languages.cobol={comment:{pattern:/\*>.*|(^[ \t]*)\*.*/m,lookbehind:!0,greedy:!0},string:{pattern:/[xzgn]?(?:"(?:[^\r\n"]|"")*"(?!")|'(?:[^\r\n']|'')*'(?!'))/i,greedy:!0},level:{pattern:/(^[ \t]*)\d+\b/m,lookbehind:!0,greedy:!0,alias:`number`},"class-name":{pattern:/(\bpic(?:ture)?\s+)(?:(?:[-\w$/,:*+<>]|\.(?!\s|$))(?:\(\d+\))?)+/i,lookbehind:!0,inside:{number:{pattern:/(\()\d+/,lookbehind:!0},punctuation:/[()]/}},keyword:{pattern:/(^|[^\w-])(?:ABORT|ACCEPT|ACCESS|ADD|ADDRESS|ADVANCING|AFTER|ALIGNED|ALL|ALPHABET|ALPHABETIC|ALPHABETIC-LOWER|ALPHABETIC-UPPER|ALPHANUMERIC|ALPHANUMERIC-EDITED|ALSO|ALTER|ALTERNATE|ANY|ARE|AREA|AREAS|AS|ASCENDING|ASCII|ASSIGN|ASSOCIATED-DATA|ASSOCIATED-DATA-LENGTH|AT|ATTRIBUTE|AUTHOR|AUTO|AUTO-SKIP|BACKGROUND-COLOR|BACKGROUND-COLOUR|BASIS|BEEP|BEFORE|BEGINNING|BELL|BINARY|BIT|BLANK|BLINK|BLOCK|BOTTOM|BOUNDS|BY|BYFUNCTION|BYTITLE|CALL|CANCEL|CAPABLE|CCSVERSION|CD|CF|CH|CHAINING|CHANGED|CHANNEL|CHARACTER|CHARACTERS|CLASS|CLASS-ID|CLOCK-UNITS|CLOSE|CLOSE-DISPOSITION|COBOL|CODE|CODE-SET|COL|COLLATING|COLUMN|COM-REG|COMMA|COMMITMENT|COMMON|COMMUNICATION|COMP|COMP-1|COMP-2|COMP-3|COMP-4|COMP-5|COMPUTATIONAL|COMPUTATIONAL-1|COMPUTATIONAL-2|COMPUTATIONAL-3|COMPUTATIONAL-4|COMPUTATIONAL-5|COMPUTE|CONFIGURATION|CONTAINS|CONTENT|CONTINUE|CONTROL|CONTROL-POINT|CONTROLS|CONVENTION|CONVERTING|COPY|CORR|CORRESPONDING|COUNT|CRUNCH|CURRENCY|CURSOR|DATA|DATA-BASE|DATE|DATE-COMPILED|DATE-WRITTEN|DAY|DAY-OF-WEEK|DBCS|DE|DEBUG-CONTENTS|DEBUG-ITEM|DEBUG-LINE|DEBUG-NAME|DEBUG-SUB-1|DEBUG-SUB-2|DEBUG-SUB-3|DEBUGGING|DECIMAL-POINT|DECLARATIVES|DEFAULT|DEFAULT-DISPLAY|DEFINITION|DELETE|DELIMITED|DELIMITER|DEPENDING|DESCENDING|DESTINATION|DETAIL|DFHRESP|DFHVALUE|DISABLE|DISK|DISPLAY|DISPLAY-1|DIVIDE|DIVISION|DONTCARE|DOUBLE|DOWN|DUPLICATES|DYNAMIC|EBCDIC|EGCS|EGI|ELSE|EMI|EMPTY-CHECK|ENABLE|END|END-ACCEPT|END-ADD|END-CALL|END-COMPUTE|END-DELETE|END-DIVIDE|END-EVALUATE|END-IF|END-MULTIPLY|END-OF-PAGE|END-PERFORM|END-READ|END-RECEIVE|END-RETURN|END-REWRITE|END-SEARCH|END-START|END-STRING|END-SUBTRACT|END-UNSTRING|END-WRITE|ENDING|ENTER|ENTRY|ENTRY-PROCEDURE|ENVIRONMENT|EOL|EOP|EOS|ERASE|ERROR|ESCAPE|ESI|EVALUATE|EVENT|EVERY|EXCEPTION|EXCLUSIVE|EXHIBIT|EXIT|EXPORT|EXTEND|EXTENDED|EXTERNAL|FD|FILE|FILE-CONTROL|FILLER|FINAL|FIRST|FOOTING|FOR|FOREGROUND-COLOR|FOREGROUND-COLOUR|FROM|FULL|FUNCTION|FUNCTION-POINTER|FUNCTIONNAME|GENERATE|GIVING|GLOBAL|GO|GOBACK|GRID|GROUP|HEADING|HIGH-VALUE|HIGH-VALUES|HIGHLIGHT|I-O|I-O-CONTROL|ID|IDENTIFICATION|IF|IMPLICIT|IMPORT|IN|INDEX|INDEXED|INDICATE|INITIAL|INITIALIZE|INITIATE|INPUT|INPUT-OUTPUT|INSPECT|INSTALLATION|INTEGER|INTO|INVALID|INVOKE|IS|JUST|JUSTIFIED|KANJI|KEPT|KEY|KEYBOARD|LABEL|LANGUAGE|LAST|LB|LD|LEADING|LEFT|LEFTLINE|LENGTH|LENGTH-CHECK|LIBACCESS|LIBPARAMETER|LIBRARY|LIMIT|LIMITS|LINAGE|LINAGE-COUNTER|LINE|LINE-COUNTER|LINES|LINKAGE|LIST|LOCAL|LOCAL-STORAGE|LOCK|LONG-DATE|LONG-TIME|LOW-VALUE|LOW-VALUES|LOWER|LOWLIGHT|MEMORY|MERGE|MESSAGE|MMDDYYYY|MODE|MODULES|MORE-LABELS|MOVE|MULTIPLE|MULTIPLY|NAMED|NATIONAL|NATIONAL-EDITED|NATIVE|NEGATIVE|NETWORK|NEXT|NO|NO-ECHO|NULL|NULLS|NUMBER|NUMERIC|NUMERIC-DATE|NUMERIC-EDITED|NUMERIC-TIME|OBJECT-COMPUTER|OCCURS|ODT|OF|OFF|OMITTED|ON|OPEN|OPTIONAL|ORDER|ORDERLY|ORGANIZATION|OTHER|OUTPUT|OVERFLOW|OVERLINE|OWN|PACKED-DECIMAL|PADDING|PAGE|PAGE-COUNTER|PASSWORD|PERFORM|PF|PH|PIC|PICTURE|PLUS|POINTER|PORT|POSITION|POSITIVE|PRINTER|PRINTING|PRIVATE|PROCEDURE|PROCEDURE-POINTER|PROCEDURES|PROCEED|PROCESS|PROGRAM|PROGRAM-ID|PROGRAM-LIBRARY|PROMPT|PURGE|QUEUE|QUOTE|QUOTES|RANDOM|RD|READ|READER|REAL|RECEIVE|RECEIVED|RECORD|RECORDING|RECORDS|RECURSIVE|REDEFINES|REEL|REF|REFERENCE|REFERENCES|RELATIVE|RELEASE|REMAINDER|REMARKS|REMOTE|REMOVAL|REMOVE|RENAMES|REPLACE|REPLACING|REPORT|REPORTING|REPORTS|REQUIRED|RERUN|RESERVE|RESET|RETURN|RETURN-CODE|RETURNING|REVERSE-VIDEO|REVERSED|REWIND|REWRITE|RF|RH|RIGHT|ROUNDED|RUN|SAME|SAVE|SCREEN|SD|SEARCH|SECTION|SECURE|SECURITY|SEGMENT|SEGMENT-LIMIT|SELECT|SEND|SENTENCE|SEPARATE|SEQUENCE|SEQUENTIAL|SET|SHARED|SHAREDBYALL|SHAREDBYRUNUNIT|SHARING|SHIFT-IN|SHIFT-OUT|SHORT-DATE|SIGN|SIZE|SORT|SORT-CONTROL|SORT-CORE-SIZE|SORT-FILE-SIZE|SORT-MERGE|SORT-MESSAGE|SORT-MODE-SIZE|SORT-RETURN|SOURCE|SOURCE-COMPUTER|SPACE|SPACES|SPECIAL-NAMES|STANDARD|STANDARD-1|STANDARD-2|START|STATUS|STOP|STRING|SUB-QUEUE-1|SUB-QUEUE-2|SUB-QUEUE-3|SUBTRACT|SUM|SUPPRESS|SYMBOL|SYMBOLIC|SYNC|SYNCHRONIZED|TABLE|TALLY|TALLYING|TAPE|TASK|TERMINAL|TERMINATE|TEST|TEXT|THEN|THREAD|THREAD-LOCAL|THROUGH|THRU|TIME|TIMER|TIMES|TITLE|TO|TODAYS-DATE|TODAYS-NAME|TOP|TRAILING|TRUNCATED|TYPE|TYPEDEF|UNDERLINE|UNIT|UNSTRING|UNTIL|UP|UPON|USAGE|USE|USING|VALUE|VALUES|VARYING|VIRTUAL|WAIT|WHEN|WHEN-COMPILED|WITH|WORDS|WORKING-STORAGE|WRITE|YEAR|YYYYDDD|YYYYMMDD|ZERO-FILL|ZEROES|ZEROS)(?![\w-])/i,lookbehind:!0},boolean:{pattern:/(^|[^\w-])(?:false|true)(?![\w-])/i,lookbehind:!0},number:{pattern:/(^|[^\w-])(?:[+-]?(?:(?:\d+(?:[.,]\d+)?|[.,]\d+)(?:e[+-]?\d+)?|zero))(?![\w-])/i,lookbehind:!0},operator:[/<>|[<>]=?|[=+*/&]/,{pattern:/(^|[^\w-])(?:-|and|equal|greater|less|not|or|than)(?![\w-])/i,lookbehind:!0}],punctuation:/[.:,()]/};var Lu={plain:{color:`#d4d4d4`,backgroundColor:`#1e1e1e`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`],style:{color:`#6a9955`,fontStyle:`italic`}},{types:[`level`],style:{color:`#38bdf8`,fontWeight:`bold`}},{types:[`keyword`,`builtin-keyword`],style:{color:`#569cd6`}},{types:[`class-name`,`return-type`,`type-list`,`namespace`,`base-clause`,`builtin`],style:{color:`#4ec9b0`}},{types:[`interface`],style:{color:`#b8d7a3`}},{types:[`function`,`generic-function`,`function-variable`,`generic-method`],style:{color:`#dcdcaa`}},{types:[`decorator`,`attribute`],style:{color:`#dcdcaa`}},{types:[`string`,`char`,`attr-value`,`triple-quoted-string`,`raw-string`,`template-string`,`interpolation-string`,`string-interpolation`],style:{color:`#ce9178`}},{types:[`number`,`boolean`],style:{color:`#b5cea8`}},{types:[`variable`,`parameter`,`named-parameter`,`property`,`string-property`,`attr-name`,`identifier`],style:{color:`#9cdcfe`}},{types:[`constant`,`symbol`],style:{color:`#4fc1ff`}},{types:[`macro`,`directive`,`preprocessor`,`preprocessor-directive`],style:{color:`#c586c0`}},{types:[`directive-hash`],style:{color:`#9b9b9b`}},{types:[`tag`],style:{color:`#569cd6`}},{types:[`regex`],style:{color:`#d16969`}},{types:[`punctuation`,`operator`,`double-colon`],style:{color:`#d4d4d4`}}]};function Ru(e){let t={cs:`csharp`,csharp:`csharp`,py:`python`,pyw:`python`,python:`python`,ts:`typescript`,tsx:`tsx`,js:`javascript`,jsx:`jsx`,mjs:`javascript`,cjs:`javascript`,c:`c`,h:`cpp`,cpp:`cpp`,cc:`cpp`,cxx:`cpp`,hpp:`cpp`,hh:`cpp`,hxx:`cpp`,go:`go`,rs:`rust`,rust:`rust`,json:`json`,yml:`yaml`,yaml:`yaml`,md:`markdown`,markdown:`markdown`,css:`css`,scss:`css`,html:`markup`,xml:`markup`,svg:`markup`,sql:`sql`,psql:`sql`,pls:`plsql`,plsql:`plsql`,pkb:`plsql`,pks:`plsql`,ddl:`sql`,dml:`sql`,cql:`sql`,hql:`sql`,sh:`bash`,bash:`bash`,zsh:`bash`,dockerfile:`docker`,cbl:`cobol`,cob:`cobol`,cpy:`cobol`,cobol:`cobol`,pco:`cobol`}[(e.split(`?`)[0].split(`#`)[0].split(`.`).pop()||``).toLowerCase()]||`plain`;return Iu.default.languages[t]?t:`plain`}var zu=({filepath:e,content:t,totalLines:n,sizeBytes:r,targetStartLine:i,targetEndLine:a,impact:o,loading:s=!1,error:c=null,onRefresh:l,onSelectCaller:u,onSelectCallee:d,density:f=`balanced`})=>{let[p,m]=(0,V.useState)(!1),[h,g]=(0,V.useState)(!1),[_,v]=(0,V.useState)(!1),y=(0,V.useRef)(null),b=(0,V.useMemo)(()=>t?t.split(` +`):[],[t]);(0,V.useEffect)(()=>{i&&y.current&&y.current.scrollIntoView({behavior:`smooth`,block:`center`})},[i,e]);let x=async()=>{if(t)try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(t),m(!0),setTimeout(()=>m(!1),2e3))}catch{}},S=async()=>{if(!e)return;let t=`${e}${i?`#L${i}${a&&a!==i?`-L${a}`:``}`:``}`;try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(t),g(!0),setTimeout(()=>g(!1),2e3))}catch{}},C=e=>e==null?``:e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(1)} MB`,w=o?.callers||[],T=o?.callees||[],E=w.length+T.length;return(0,H.jsxs)(`div`,{className:`nav-code-viewer-container density-${f}`,"data-testid":`navigator-code-viewer`,children:[(0,H.jsxs)(`div`,{className:`nav-code-viewer-header`,children:[(0,H.jsxs)(`div`,{className:`nav-code-viewer-meta`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,className:`nav-code-file-icon`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`})]}),(0,H.jsx)(`span`,{className:`nav-code-filename`,title:e,children:e}),(0,H.jsxs)(`span`,{className:`nav-code-stat-chip`,children:[n||b.length,` lines`]}),r!==void 0&&r>0&&(0,H.jsx)(`span`,{className:`nav-code-stat-chip`,children:C(r)})]}),(0,H.jsxs)(`div`,{className:`nav-code-viewer-actions`,children:[o?.symbol&&(0,H.jsxs)(`button`,{type:`button`,className:`nav-code-impact-toggle-btn nav-code-drawer-toggle ${_?`active`:``}`,onClick:()=>v(e=>!e),"aria-label":`Callers & Impact`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`path`,{d:`M12 16v-4M12 8h.01`})]}),(0,H.jsxs)(`span`,{children:[`Callers & Impact (`,E,`)`]})]}),(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:S,title:`Copy path and line permalink`,"aria-label":`Copy Permalink`,children:h?`Link Copied!`:`Copy Link`}),(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:x,title:`Copy entire file contents`,"aria-label":`Copy File Code`,children:p?`Copied!`:`Copy Code`}),l&&(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:l,title:`Refresh file`,"aria-label":`Refresh File`,children:`↻`})]})]}),c&&(0,H.jsx)(`div`,{className:`nav-code-error-banner`,role:`alert`,children:(0,H.jsxs)(`span`,{children:[`Failed to load file: `,c]})}),s&&(0,H.jsxs)(`div`,{className:`nav-code-loading-overlay`,children:[(0,H.jsx)(`div`,{className:`nav-omni-spinner`}),(0,H.jsx)(`span`,{children:`Loading source code...`})]}),(0,H.jsx)(`div`,{className:`nav-code-body`,tabIndex:0,children:b.length===0&&!s&&!c?(0,H.jsx)(`div`,{className:`nav-code-empty-state`,style:{padding:`24px`,color:`#64748b`,textAlign:`center`},children:`File is empty.`}):(0,H.jsx)(Fu,{prism:Iu.default,theme:Lu,code:t||``,language:Ru(e),children:({tokens:e,getTokenProps:t})=>(0,H.jsx)(`div`,{className:`nav-code-lines-wrapper`,children:e.map((e,n)=>{let r=n+1,o=i!==void 0&&r>=i&&r<=(a||i),s=i!==void 0&&r===i;return(0,H.jsxs)(`div`,{ref:s?y:void 0,className:`nav-code-line-row ${o?`nav-code-line-target`:``} ${s?`nav-code-line-primary`:``}`,"data-testid":`code-line-${r}`,children:[(0,H.jsx)(`div`,{className:`nav-code-line-number select-none`,children:r}),(0,H.jsx)(`div`,{className:`nav-code-line-content font-mono`,children:e.length===0||e.length===1&&e[0].content===``?` `:e.map((e,n)=>(0,H.jsx)(`span`,{...t({token:e})},n))})]},r)})})})}),_&&o?.symbol&&(0,H.jsxs)(`div`,{className:`nav-code-impact-drawer`,"data-testid":`code-impact-drawer`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-drawer-header`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-drawer-title`,children:[(0,H.jsx)(`span`,{className:`outline-kind-badge ${ut(o.symbol.kind)}`,children:o.symbol.kind}),(0,H.jsx)(`strong`,{className:`nav-impact-symbol-name`,children:o.symbol.name}),(0,H.jsxs)(`span`,{className:`nav-impact-symbol-lines`,children:[`Lines `,o.symbol.start_line,`–`,o.symbol.end_line]}),o.route&&(0,H.jsxs)(`span`,{className:`outline-method-badge ${lt(o.route.http_method)}`,children:[o.route.http_method,` `,o.route.path_pattern]})]}),(0,H.jsx)(`button`,{type:`button`,className:`nav-impact-close-btn`,onClick:()=>v(!1),"aria-label":`Close Impact Drawer`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-impact-drawer-body`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column-title`,children:[`Incoming Callers (`,w.length,`)`]}),w.length===0?(0,H.jsx)(`div`,{className:`nav-impact-empty`,children:`No incoming callers detected`}):(0,H.jsx)(`div`,{className:`nav-impact-chips-list`,children:w.map((t,n)=>(0,H.jsxs)(`button`,{type:`button`,className:`nav-impact-chip caller`,onClick:()=>u&&u(t.source_filepath||e,t.source_symbol,t.source_symbol_id||void 0),children:[(0,H.jsx)(`span`,{className:`chip-name`,children:t.source_symbol||`anonymous`}),(0,H.jsx)(`span`,{className:`chip-path`,children:t.source_filepath}),t.line_number&&(0,H.jsxs)(`span`,{className:`chip-line`,children:[`:`,t.line_number]})]},t.id||n))})]}),(0,H.jsxs)(`div`,{className:`nav-impact-column`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column-title`,children:[`Outgoing Callees (`,T.length,`)`]}),T.length===0?(0,H.jsx)(`div`,{className:`nav-impact-empty`,children:`No outgoing callees detected`}):(0,H.jsx)(`div`,{className:`nav-impact-chips-list`,children:T.map((e,t)=>(0,H.jsxs)(`button`,{type:`button`,className:`nav-impact-chip callee`,onClick:()=>d&&d(e.target_filepath,e.target_symbol),children:[(0,H.jsx)(`span`,{className:`chip-name`,children:e.target_symbol}),e.target_filepath&&(0,H.jsx)(`span`,{className:`chip-path`,children:e.target_filepath}),e.line_number&&(0,H.jsxs)(`span`,{className:`chip-line`,children:[`:`,e.line_number]})]},e.id||t))})]})]})]})]})},Bu=({impact:e,fileContent:t,loadingContent:n=!1,contentError:r=null,targetStartLine:i,targetEndLine:a,activeInspectorTab:o,onChangeInspectorTab:s,onSelectCaller:c,onSelectCallee:l,density:u=`balanced`,loading:d=!1,onRefreshContent:f})=>{let[p,m]=(0,V.useState)(e?.symbol||d?`intelligence`:t?`reader`:`intelligence`),[h,g]=(0,V.useState)(!1),_=o===void 0?p:o,v=s||m,y=e?.symbol,b=e?.route,x=e?.callers||[],S=e?.callees||[],C=e?.imports||[],w=!!(t||n||r),T=_===`reader`;return(0,H.jsxs)(`div`,{className:`nav-inspector-pane density-${u}`,"data-testid":`navigator-inspector-container`,children:[(0,H.jsxs)(`div`,{className:`nav-inspector-header`,children:[(0,H.jsxs)(`div`,{className:`nav-inspector-title`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`})]}),(0,H.jsx)(`span`,{children:`Inspector`})]}),(0,H.jsxs)(`div`,{className:`nav-inspector-header-actions`,children:[(w||y)&&(0,H.jsxs)(`div`,{className:`nav-inspector-tabs`,role:`tablist`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`inspector-tab-btn ${_===`reader`?`active`:``}`,onClick:()=>v(`reader`),role:`tab`,"aria-selected":_===`reader`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`})]}),`File`]}),(0,H.jsxs)(`button`,{type:`button`,className:`inspector-tab-btn ${_===`intelligence`?`active`:``}`,onClick:()=>v(`intelligence`),title:`View symbol callers, callees & impact`,role:`tab`,"aria-selected":_===`intelligence`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`12`,y1:`16`,x2:`12`,y2:`12`}),(0,H.jsx)(`line`,{x1:`12`,y1:`8`,x2:`12.01`,y2:`8`})]}),`Intelligence`]})]}),y&&_===`intelligence`&&(0,H.jsx)(`button`,{type:`button`,className:`nav-copy-permalink-btn`,onClick:async()=>{if(!e?.symbol)return;let{filepath:t,start_line:n,end_line:r}=e.symbol,i=`${window.location.origin}${window.location.pathname}?repo=${encodeURIComponent(e.symbol.repo||``)}&file=${t}#L${n}-L${r}`;try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(i),g(!0),setTimeout(()=>g(!1),2e3)}catch{}},title:`Copy file path & line range permalink`,"aria-label":`Copy Permalink`,children:h?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),(0,H.jsx)(`span`,{children:`Copied!`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`}),(0,H.jsx)(`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`})]}),(0,H.jsx)(`span`,{children:`Copy Permalink`})]})})]})]}),(0,H.jsx)(`div`,{className:`nav-inspector-content`,children:T&&t?t.filepath.toLowerCase().endsWith(`.md`)||t.filepath.toLowerCase().endsWith(`.markdown`)?(0,H.jsx)(zl,{filepath:t.filepath,content:t.content,totalLines:t.total_lines,sizeBytes:t.size_bytes,loading:n,error:r,onRefresh:f}):(0,H.jsx)(zu,{filepath:t.filepath,content:t.content,totalLines:t.total_lines,sizeBytes:t.size_bytes,targetStartLine:i||y?.start_line,targetEndLine:a||y?.end_line,impact:e,loading:n,error:r,onRefresh:f,onSelectCaller:c,onSelectCallee:l,density:u}):T&&n?(0,H.jsxs)(`div`,{className:`nav-inspector-skeleton`,"data-testid":`inspector-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-metrics shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):T?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{fontSize:`2rem`,opacity:.3}})}),(0,H.jsx)(`h4`,{children:`No File or Symbol Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to read its documentation or select a symbol to inspect callers and dependencies.`})]}):d?(0,H.jsxs)(`div`,{className:`nav-inspector-skeleton`,"data-testid":`inspector-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-metrics shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):y?(0,H.jsxs)(`div`,{className:`nav-inspector-body`,children:[(0,H.jsxs)(`div`,{className:`inspector-card symbol-summary-card`,children:[(0,H.jsxs)(`div`,{className:`summary-title-row`,children:[(0,H.jsx)(`span`,{className:`symbol-kind-badge ${ut(y.kind)}`,children:y.kind}),(0,H.jsx)(`h3`,{className:`summary-name`,title:y.full_symbol||y.name,children:y.name})]}),(0,H.jsxs)(`div`,{className:`summary-location-row`,children:[(0,H.jsxs)(`span`,{className:`summary-file-path`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z`}),(0,H.jsx)(`polyline`,{points:`13 2 13 9 20 9`})]}),y.filepath]}),(0,H.jsxs)(`span`,{className:`summary-line-range`,children:[`L`,y.start_line,` - L`,y.end_line]})]})]}),(0,H.jsxs)(`div`,{className:`inspector-metrics-grid`,children:[(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Incoming Callers`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-callers`,children:x.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Outgoing Callees`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-callees`,children:S.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Total Imports`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-imports`,children:C.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Language`}),(0,H.jsx)(`span`,{className:`metric-value metric-lang`,"data-testid":`metric-scope`,children:y.language||`code`})]})]}),b&&(0,H.jsxs)(`div`,{className:`inspector-card route-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`2`,y1:`12`,x2:`22`,y2:`12`}),(0,H.jsx)(`path`,{d:`M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z`})]}),(0,H.jsx)(`span`,{children:`API Route Mapping`})]}),(0,H.jsxs)(`div`,{className:`route-detail-row`,children:[(0,H.jsx)(`span`,{className:`route-method-badge ${lt(b.http_method)}`,children:b.http_method}),(0,H.jsx)(`span`,{className:`route-path-code`,children:b.path_pattern}),b.framework&&(0,H.jsx)(`span`,{className:`route-framework-tag`,children:b.framework})]})]}),y.signature&&(0,H.jsxs)(`div`,{className:`inspector-card code-preview-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`polyline`,{points:`16 18 22 12 16 6`}),(0,H.jsx)(`polyline`,{points:`8 6 2 12 8 18`})]}),(0,H.jsx)(`span`,{children:`Signature`})]}),(0,H.jsx)(`pre`,{className:`signature-code-block`,children:(0,H.jsx)(`code`,{children:y.signature})})]}),y.docstring&&(0,H.jsxs)(`div`,{className:`inspector-card docstring-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`}),(0,H.jsx)(`polyline`,{points:`10 9 9 9 8 9`})]}),(0,H.jsx)(`span`,{children:`Documentation`})]}),(0,H.jsx)(`p`,{className:`docstring-text`,children:y.docstring})]}),(0,H.jsxs)(`div`,{className:`inspector-card relations-card callers-section`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M12 19V5M5 12l7-7 7 7`})}),(0,H.jsxs)(`span`,{children:[`Incoming Callers (`,x.length,`)`]})]}),x.length===0?(0,H.jsx)(`div`,{className:`nav-no-items-text`,children:`No incoming callers found in this repository.`}):(0,H.jsx)(`div`,{className:`relation-list`,children:x.map((e,t)=>(0,H.jsxs)(`div`,{"data-testid":`caller-item-${e.id??t}`,className:`relation-item caller-item`,onClick:()=>{e.source_filepath&&c&&c(e.source_filepath,e.source_symbol,e.source_symbol_id??void 0)},role:`button`,tabIndex:0,title:`Jump to ${e.source_symbol||`caller`} in ${e.source_filepath||``}`,children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.source_symbol||`Unknown Caller`}),(0,H.jsx)(`span`,{className:`rel-jump-hint`,"aria-hidden":`true`,children:`Jump ↗`})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.source_filepath&&(0,H.jsx)(`span`,{className:`rel-filepath`,children:e.source_filepath}),e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.call_count&&e.call_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.call_count,` calls`]}):null,e.relationship_type&&(0,H.jsx)(`span`,{className:`rel-type-tag`,children:e.relationship_type})]})]},e.id??t))})]}),(0,H.jsxs)(`div`,{className:`inspector-card relations-card dependencies-section`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M12 5v14M5 12l7 7 7-7`})}),(0,H.jsxs)(`span`,{children:[`Outgoing Dependencies (`,S.length+C.length,`)`]})]}),S.length===0&&C.length===0?(0,H.jsx)(`div`,{className:`nav-no-items-text`,children:`No outgoing calls or imports.`}):(0,H.jsxs)(`div`,{className:`relation-list`,children:[S.map((e,t)=>(0,H.jsxs)(`div`,{"data-testid":`callee-item-${e.id??t}`,className:`relation-item callee-item ${e.target_filepath?`is-clickable`:``}`,onClick:()=>{e.target_filepath&&l&&l(e.target_filepath,e.target_symbol)},role:e.target_filepath?`button`:void 0,tabIndex:e.target_filepath?0:void 0,title:e.target_filepath?`Jump to ${e.target_symbol} in ${e.target_filepath}`:void 0,onKeyDown:t=>{e.target_filepath&&l&&(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),l(e.target_filepath,e.target_symbol))},children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.target_symbol}),(0,H.jsxs)(`div`,{className:`rel-top-right`,children:[(0,H.jsx)(`span`,{className:`rel-type-badge`,children:e.relationship_type||`CALLS`}),e.target_filepath&&(0,H.jsx)(`span`,{className:`rel-jump-hint`,"aria-hidden":`true`,children:`Jump ↗`})]})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.target_filepath&&(0,H.jsx)(`span`,{className:`rel-filepath`,children:e.target_filepath}),e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.call_count&&e.call_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.call_count,` calls`]}):null]})]},e.id??`callee-${t}`)),C.map((e,t)=>(0,H.jsxs)(`div`,{className:`relation-item import-item`,children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.target_symbol}),(0,H.jsx)(`span`,{className:`rel-type-badge import-badge`,children:`IMPORTS`})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.import_count&&e.import_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.import_count,` imports`]}):null]})]},e.id??`import-${t}`))]})]})]}):(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-circle-nodes`,style:{fontSize:`2rem`,opacity:.3}})}),(0,H.jsx)(`h4`,{children:`No File or Symbol Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to read its documentation or select a symbol to inspect callers and dependencies.`})]})})]})},Vu=`contextcortex_navigator_density`,Hu=({initialRepo:e=`__all__`,initialPath:t,initialSymbolId:n,initialStartLine:r,initialEndLine:i,onNavigationConsumed:a})=>{let[o,s]=(0,V.useState)(()=>{let e=localStorage.getItem(Vu);return e===`compact`||e===`balanced`||e===`spacious`?e:`balanced`}),c=e=>{s(e),localStorage.setItem(Vu,e)},[l,u]=(0,V.useState)([]),[d,f]=(0,V.useState)(e),[p,m]=(0,V.useState)(null),[h,g]=(0,V.useState)(!1),[_,v]=(0,V.useState)(``),[y,b]=(0,V.useState)(t||null),[x,S]=(0,V.useState)(null),[C,w]=(0,V.useState)(!1),[T,E]=(0,V.useState)(n||null),[D,O]=(0,V.useState)(null),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(null),[N,P]=(0,V.useState)(!1),[F,I]=(0,V.useState)(null),[L,R]=(0,V.useState)(`reader`),[z,B]=(0,V.useState)(void 0),[ee,te]=(0,V.useState)(void 0),[ne,re]=(0,V.useState)(!0),[ie,ae]=(0,V.useState)(`files`),[oe,se]=(0,V.useState)([]),[ce,le]=(0,V.useState)(-1),[ue,de]=(0,V.useState)(null);(0,V.useEffect)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`b`&&(e.preventDefault(),re(e=>!e))};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[]),(0,V.useEffect)(()=>{(async()=>{try{let e=await fetch(`/admin/api/repos`);if(e.ok){let t=await e.json();u(Array.isArray(t)?t:[])}}catch(e){console.error(`Error fetching repositories:`,e)}})()},[]);let fe=(0,V.useCallback)(async e=>{g(!0),de(null);try{let t=await fetch(`/admin/api/navigator/tree?repo=${encodeURIComponent(e)}`);if(!t.ok)throw Error(`Failed to load tree: ${t.status} ${t.statusText}`);let n=await t.json();m(n)}catch(e){console.error(`Error fetching codebase tree:`,e),de(e.message||`Failed to load codebase tree`)}finally{g(!1)}},[]);(0,V.useEffect)(()=>{fe(d)},[d,fe]);let pe=(0,V.useCallback)(async(e,t)=>{A(!0);try{let n=await fetch(`/admin/api/navigator/symbol-impact?repo=${encodeURIComponent(e)}&symbol_id=${t}`);if(!n.ok)throw Error(`Failed to load symbol impact: ${n.status}`);let r=await n.json();O(r)}catch(e){console.error(`Error fetching symbol impact:`,e),O(null)}finally{A(!1)}},[]),me=(0,V.useCallback)(async(e,t)=>{P(!0),I(null);try{let n=await fetch(`/admin/api/files/read?path=${encodeURIComponent(t)}&repo=${encodeURIComponent(e)}`);if(!n.ok)throw Error(`Failed to read file: ${n.statusText}`);let r=await n.json();M(r)}catch(e){console.error(`Error fetching file content:`,e),I(e.message||`Failed to read file content`),M(null)}finally{P(!1)}},[]),he=(0,V.useCallback)(async(e,t,n,r)=>{w(!0);try{let i=await fetch(`/admin/api/navigator/file-outline?repo=${encodeURIComponent(e)}&filepath=${encodeURIComponent(t)}`);if(!i.ok)throw Error(`Failed to load file outline: ${i.status}`);let a=await i.json();if(S(a),a.symbols&&a.symbols.length>0){let t;typeof n==`number`?t=a.symbols.find(e=>e.id===n):typeof n==`string`&&(t=a.symbols.find(e=>e.name===n||e.full_symbol===n)),t||=a.symbols[0],t&&(E(t.id),(r===`intelligence`||n!==void 0)&&(B(t.start_line),te(t.end_line)),await pe(e,t.id))}else E(null),O(null);R(r||`reader`)}catch(e){console.error(`Error fetching outline:`,e),S(null),E(null),O(null),R(`reader`)}finally{w(!1)}},[pe]),ge=(0,V.useRef)(null);(0,V.useEffect)(()=>{if(!t&&!n&&(!e||e===`__all__`))return;let o=`${e||``}:${t||``}:${n||``}:${r||``}:${i||``}`;if(ge.current===o)return;ge.current=o;let s=e&&e!==`__all__`?e:d;e&&e!==`__all__`&&e!==d&&f(e),t&&(b(t),me(s,t),he(s,t),r!==void 0&&B(r),i!==void 0&&te(i),R(`reader`)),n&&(E(n),pe(s,n),R(`intelligence`)),a?.()},[e,t,n,r,i,me,he,pe,a]);let _e=(0,V.useCallback)(e=>{se(t=>[...t.slice(0,ce+1),e]),le(e=>e+1)},[ce]),ve=()=>{if(ce>0){let e=oe[ce-1];le(ce-1),f(e.repo),b(e.path),E(e.symbolId??null),B(e.startLine),te(e.endLine),he(e.repo,e.path,e.symbolId??void 0),me(e.repo,e.path),e.symbolId&&pe(e.repo,e.symbolId)}},ye=()=>{if(ce{f(e),b(null),S(null),E(null),O(null),M(null),B(void 0),te(void 0)},xe=e=>{let t=e.repo&&e.repo!==`__all__`?e.repo:d;e.repo&&e.repo!==d&&d!==`__all__`&&f(e.repo),b(e.filepath),B(e.start_line),te(e.end_line),_e({repo:t,path:e.filepath,symbolId:e.symbol_id,startLine:e.start_line,endLine:e.end_line}),me(t,e.filepath),e.type===`symbol`&&e.symbol_id?(E(e.symbol_id),he(t,e.filepath,e.symbol_id,`reader`),pe(t,e.symbol_id)):he(t,e.filepath,void 0,`reader`),R(`reader`)},Se=e=>{if(e.is_dir)return;let t=e.abs_path||e.path;b(t),B(void 0),te(void 0),_e({repo:d,path:t}),he(d,t,void 0,`reader`),me(d,t),R(`reader`),ae(`outline`)},Ce=e=>{if(R(e),e===`intelligence`){if(!T&&x?.symbols&&x.symbols.length>0){let e=x.symbols[0];E(e.id),B(e.start_line),te(e.end_line),d&&pe(d,e.id)}else T&&!D&&d&&pe(d,T)}},we=e=>{E(e.id),B(e.start_line),te(e.end_line),R(`intelligence`),pe(d,e.id),y&&_e({repo:d,path:y,symbolId:e.id,startLine:e.start_line,endLine:e.end_line})},Te=(e,t,n)=>{b(e),B(void 0),te(void 0),_e({repo:d,path:e,symbolId:n});let r=n?`intelligence`:`reader`;he(d,e,n??t,r),me(d,e),R(r),ae(`outline`),n&&(E(n),pe(d,n))},Ee=(e,t)=>{e&&(b(e),B(void 0),te(void 0),_e({repo:d,path:e}),he(d,e,t,`reader`),me(d,e),R(`reader`))},De=x?.symbols?.find(e=>e.id===T)?.name||null;return(0,H.jsxs)(`div`,{className:`code-navigator-container density-${o}`,"data-testid":`code-navigator-container`,children:[(0,H.jsx)(Nt,{repos:l,selectedRepo:d,onSelectRepo:be,density:o,onChangeDensity:c,searchQuery:_,onSearchChange:v,onSelectSearchResult:xe,totalFiles:p?.total_files??0,totalSymbols:p?.total_symbols??0,onRefresh:()=>fe(d),loading:h}),(0,H.jsx)(Pt,{repo:d,path:y,symbol:De,onNavigatePath:e=>{b(e),/\.[a-zA-Z0-9]+$/.test(e)?(me(d,e),he(d,e)):ae(`files`)},canGoBack:ce>0,canGoForward:cere(!ne),isSidebarOpen:ne}),ue&&(0,H.jsxs)(`div`,{className:`nav-error-banner`,role:`alert`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`12`,y1:`8`,x2:`12`,y2:`12`}),(0,H.jsx)(`line`,{x1:`12`,y1:`16`,x2:`12.01`,y2:`16`})]}),(0,H.jsx)(`span`,{children:ue}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>de(null),className:`error-close-btn`,"aria-label":`Dismiss error`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-hero-layout`,"data-testid":`nav-hero-layout`,children:[(0,H.jsxs)(`aside`,{className:`nav-sidebar-column ${ne?``:`collapsed`}`,"aria-label":`Codebase Navigator Sidebar`,children:[(0,H.jsxs)(`div`,{className:`nav-sidebar-tabs`,role:`tablist`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`nav-sidebar-tab-btn ${ie===`files`?`active`:``}`,onClick:()=>ae(`files`),role:`tab`,"aria-selected":ie===`files`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`})}),(0,H.jsx)(`span`,{children:`Files`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`nav-sidebar-tab-btn ${ie===`outline`?`active`:``}`,onClick:()=>ae(`outline`),role:`tab`,"aria-selected":ie===`outline`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`line`,{x1:`8`,y1:`6`,x2:`21`,y2:`6`}),(0,H.jsx)(`line`,{x1:`8`,y1:`12`,x2:`21`,y2:`12`}),(0,H.jsx)(`line`,{x1:`8`,y1:`18`,x2:`21`,y2:`18`}),(0,H.jsx)(`line`,{x1:`3`,y1:`6`,x2:`3.01`,y2:`6`}),(0,H.jsx)(`line`,{x1:`3`,y1:`12`,x2:`3.01`,y2:`12`}),(0,H.jsx)(`line`,{x1:`3`,y1:`18`,x2:`3.01`,y2:`18`})]}),(0,H.jsx)(`span`,{children:`Symbols`})]})]}),(0,H.jsxs)(`div`,{style:{flex:1,minHeight:0,display:`flex`,flexDirection:`column`,position:`relative`},children:[(0,H.jsx)(`div`,{style:{flex:1,minHeight:0,display:ie===`files`?`flex`:`none`,flexDirection:`column`,height:`100%`},children:(0,H.jsx)(It,{nodes:p?.tree??[],selectedPath:y,onSelectFile:Se,filterText:_,onFilterChange:v,density:o,loading:h,repo:d,autoExpandRoot:!0})}),(0,H.jsx)(`div`,{style:{flex:1,minHeight:0,display:ie===`outline`?`flex`:`none`,flexDirection:`column`,height:`100%`},children:(0,H.jsx)(dt,{outline:x,selectedSymbolId:T,onSelectSymbol:we,onReadDoc:()=>{R(`reader`)},density:o,loading:C})})]})]}),(0,H.jsx)(`main`,{className:`nav-hero-viewer`,"aria-label":`Code and Document Hero Viewport`,children:(0,H.jsx)(Bu,{impact:D,fileContent:j,loadingContent:N,contentError:F,targetStartLine:z,targetEndLine:ee,activeInspectorTab:L,onChangeInspectorTab:Ce,onSelectCaller:Te,onSelectCallee:Ee,density:o,loading:k,onRefreshContent:()=>y&&me(d,y)})})]})]})};function Uu(){let e=Je(),[t,n]=(0,V.useState)(null),[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(`all`),[s,c]=(0,V.useState)(`summary`),[l,u]=(0,V.useState)(``),[d,f]=(0,V.useState)(``),[p,m]=(0,V.useState)(``),[h,g]=(0,V.useState)(``),_=(0,V.useCallback)(async(t=a,r=s,o=l,c=d,u=p)=>{i(!0);try{let e=new URLSearchParams;e.set(`source_type`,t),e.set(`detail_level`,r),o.trim()&&e.set(`repo_name`,o.trim()),c.trim()&&e.set(`path_prefix`,c.trim()),u.trim()&&e.set(`file_extension`,u.trim());let i=await fetch(`/admin/api/ingestion/catalog?${e.toString()}`);if(!i.ok){let e=await i.json().catch(()=>({}));throw Error(e.error||`Failed to load ingestion catalog`)}let a=await i.json();n(a)}catch(t){e.error(`Error loading catalog: `+t.message),console.error(`Error loading ingestion catalog:`,t)}finally{i(!1)}},[a,s,l,d,p,e]);(0,V.useEffect)(()=>{_(a,s,l,d,p)},[a,s]);let v=e=>{e&&e.preventDefault(),_(a,s,l,d,p)},y=()=>{u(``),f(``),m(``),g(``),_(a,s,``,``,``)},b=e=>{o(e)},x=e=>{c(e)},S=e=>{if(!e)return`-`;if(typeof e==`string`)try{return new Date(e).toLocaleString()}catch{return e}let t=e<1e11?e*1e3:e;return new Date(t).toLocaleString()},C=t?.git_repositories||[],w=t?.monitored_paths||[],T=t?.local_storage,E=(t?.files||[]).filter(e=>{if(!h.trim())return!0;let t=h.toLowerCase();return e.filepath.toLowerCase().includes(t)||e.repo.toLowerCase().includes(t)||e.language&&e.language.toLowerCase().includes(t)}),D=C.reduce((e,t)=>e+(t.file_count||0),0),O=w.reduce((e,t)=>e+(t.file_count||0),0),k=T?.file_count||0,A=D+O+k;return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-book-bookmark`}),` Unified Ingestion Catalog`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Inspect all indexed Git repositories, monitored local workspaces, and uploaded local storage documents.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>v(),disabled:r,title:`Refresh catalog`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate ${r?`fa-spin`:``}`}),` Refresh`]})})]}),(0,H.jsxs)(`div`,{className:`stats-grid`,children:[(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`6`,y1:`3`,x2:`6`,y2:`15`}),(0,H.jsx)(`circle`,{cx:`18`,cy:`6`,r:`3`}),(0,H.jsx)(`circle`,{cx:`6`,cy:`18`,r:`3`}),(0,H.jsx)(`path`,{d:`M18 9a9 9 0 0 1-9 9`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Git Repositories`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[C.length,` `,(0,H.jsxs)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:[`(`,D,` files)`]})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(251, 191, 36, 0.12)`,color:`#fbbf24`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`}),(0,H.jsx)(`line`,{x1:`12`,y1:`11`,x2:`12`,y2:`17`}),(0,H.jsx)(`line`,{x1:`9`,y1:`14`,x2:`15`,y2:`14`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Monitored Paths`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[w.length,` `,(0,H.jsxs)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:[`(`,O,` files)`]})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(56, 189, 248, 0.12)`,color:`#38bdf8`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`22`,y1:`12`,x2:`2`,y2:`12`}),(0,H.jsx)(`path`,{d:`M5.45 5.11L2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`}),(0,H.jsx)(`line`,{x1:`6`,y1:`16`,x2:`6.01`,y2:`16`}),(0,H.jsx)(`line`,{x1:`10`,y1:`16`,x2:`10.01`,y2:`16`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Local Storage`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[k,` `,(0,H.jsx)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:`files`})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(168, 85, 247, 0.12)`,color:`#a855f7`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`}),(0,H.jsx)(`path`,{d:`M21 12c0 1.66-4 3-9 3s-9-1.34-9-3`}),(0,H.jsx)(`path`,{d:`M3 5v14c0 1.66 4 3 9 3s9-1.34 9-3V5`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Total Cataloged Files`}),(0,H.jsx)(`span`,{className:`stat-value`,children:A})]})]})]}),(0,H.jsxs)(`div`,{className:`catalog-filter-bar`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,flexWrap:`wrap`,gap:`12px`,marginBottom:`14px`},children:[(0,H.jsxs)(`div`,{className:`log-filter-pills`,role:`group`,"aria-label":`Source Type Filters`,children:[(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`all`?`active`:``}`,onClick:()=>b(`all`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group`}),` All Sources`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`git`?`active`:``}`,onClick:()=>b(`git`),children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`}),` Git Repositories`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`monitored_path`?`active`:``}`,onClick:()=>b(`monitored_path`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Monitored Paths`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`local_storage`?`active`:``}`,onClick:()=>b(`local_storage`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),` Local Storage`]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},role:`group`,"aria-label":`Detail Level Switch`,children:[(0,H.jsxs)(`button`,{className:`btn ${s===`summary`?`btn-primary`:`btn-secondary`}`,style:{padding:`5px 12px`,fontSize:`0.8rem`},onClick:()=>x(`summary`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-list`}),` Summary`]}),(0,H.jsxs)(`button`,{className:`btn ${s===`detailed`?`btn-primary`:`btn-secondary`}`,style:{padding:`5px 12px`,fontSize:`0.8rem`},onClick:()=>x(`detailed`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-network-wired`}),` Detailed File Tree`]})]})]}),(0,H.jsxs)(`form`,{onSubmit:v,children:[(0,H.jsxs)(`div`,{className:`catalog-filter-inputs`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-repo-filter`,style:{fontSize:`0.8rem`},children:`Repository / Alias`}),(0,H.jsx)(`input`,{id:`catalog-repo-filter`,type:`text`,placeholder:`Filter by repo name...`,value:l,onChange:e=>u(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-prefix-filter`,style:{fontSize:`0.8rem`},children:`Path Prefix`}),(0,H.jsx)(`input`,{id:`catalog-prefix-filter`,type:`text`,placeholder:`e.g. app/api or docs/`,value:d,onChange:e=>f(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-ext-filter`,style:{fontSize:`0.8rem`},children:`File Extension`}),(0,H.jsx)(`input`,{id:`catalog-ext-filter`,type:`text`,placeholder:`e.g. .md, .py, .ts`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,gap:`8px`,marginTop:`12px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`6px 12px`,fontSize:`0.85rem`},onClick:y,children:`Clear`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`6px 14px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-filter`}),` Apply`]})]})]})]}),(a===`all`||a===`git`)&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{color:`var(--primary)`}}),` Git Repositories`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:C.length})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Name`}),(0,H.jsx)(`th`,{children:`Branch / Commit`}),(0,H.jsx)(`th`,{children:`Status`}),(0,H.jsx)(`th`,{children:`Files`}),(0,H.jsx)(`th`,{children:`Provider`}),(0,H.jsx)(`th`,{children:`URL`})]})}),(0,H.jsx)(`tbody`,{children:C.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:6,className:`empty-state`,children:`No Git repositories match criteria.`})}):C.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.name})}),(0,H.jsxs)(`td`,{children:[(0,H.jsx)(`code`,{children:e.branch}),e.commit_sha&&(0,H.jsxs)(`span`,{className:`text-muted`,style:{marginLeft:`6px`,fontSize:`0.8rem`},children:[`@`,e.commit_sha.substring(0,7)]})]}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge ${e.status===`synced`?`badge-success`:e.status===`syncing`?`badge-warning`:`badge-danger`}`,children:e.status})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.file_count??0})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.provider||`git`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.82rem`,wordBreak:`break-all`},children:e.url})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:C.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No Git repositories match criteria.`}):C.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.name}),(0,H.jsx)(`span`,{className:`badge ${e.status===`synced`?`badge-success`:`badge-warning`}`,children:e.status})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Branch: `}),(0,H.jsx)(`code`,{children:e.branch})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Files: `}),(0,H.jsx)(`strong`,{children:e.file_count??0})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`URL: `}),(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.url})]})]})]},`gm-${e.id}`))})]}),(a===`all`||a===`monitored_path`)&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{color:`#fbbf24`}}),` Monitored Local Paths`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:w.length})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Category`}),(0,H.jsx)(`th`,{children:`Files Indexed`})]})}),(0,H.jsx)(`tbody`,{children:w.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:4,className:`empty-state`,children:`No monitored paths match criteria.`})}):w.map((e,t)=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo})}),(0,H.jsx)(`td`,{children:e.category?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.file_count??0})})]},`${e.path}-${t}`))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:w.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No monitored paths match criteria.`}):w.map((e,t)=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.repo}),(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[e.file_count??0,` files`]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.path})]}),e.category&&(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Category: `}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category})]})]})]},`mpm-${t}`))})]}),(a===`all`||a===`local_storage`)&&T&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`,style:{color:`var(--accent)`}}),` Local Storage`,(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[T.file_count,` files`]})]}),(0,H.jsxs)(`div`,{style:{background:`rgba(255, 255, 255, 0.02)`,padding:`16px`,borderRadius:`8px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`20px`,flexWrap:`wrap`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.85rem`},children:`Storage Root: `}),(0,H.jsx)(`code`,{children:T.root_path})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.85rem`},children:`Total Files: `}),(0,H.jsx)(`strong`,{children:T.file_count})]})]}),T.tree&&(0,H.jsxs)(`div`,{style:{fontSize:`0.85rem`,color:`var(--text-muted)`},children:[`Top-level Subfolders: `,(0,H.jsx)(`strong`,{children:T.tree.directories?.length||0}),` • Top-level Files: `,(0,H.jsx)(`strong`,{children:T.tree.files?.length||0})]})]})]}),s===`detailed`&&(0,H.jsxs)(`div`,{style:{marginTop:`20px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,flexWrap:`wrap`,gap:`10px`,marginBottom:`12px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,margin:0,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{color:`var(--primary)`}}),` Ingested Files Details`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:E.length})]}),(0,H.jsxs)(`div`,{className:`log-search-wrapper`,style:{maxWidth:`320px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass search-icon`}),(0,H.jsx)(`input`,{type:`text`,className:`log-search-input`,placeholder:`Search in loaded files...`,value:h,onChange:e=>g(e.target.value)}),h&&(0,H.jsx)(`button`,{className:`clear-search-btn`,onClick:()=>g(``),children:`×`})]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Filepath`}),(0,H.jsx)(`th`,{children:`Repository`}),(0,H.jsx)(`th`,{children:`Type`}),(0,H.jsx)(`th`,{children:`Language`}),(0,H.jsx)(`th`,{children:`Last Modified`})]})}),(0,H.jsx)(`tbody`,{children:E.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:5,className:`empty-state`,children:`No detailed files match current search or filters.`})}):E.map((e,t)=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.filepath})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.doc_type})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.language||`text`})}),(0,H.jsx)(`td`,{style:{fontSize:`0.85rem`},children:S(e.mtime)})]},`${e.filepath}-${t}`))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:E.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No detailed files match current search or filters.`}):E.map((e,t)=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.repo}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.language||`text`})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.filepath})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Type: `}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.doc_type})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Modified: `}),(0,H.jsx)(`span`,{children:S(e.mtime)})]})]})]},`dfm-${t}`))})]})]})})}function Wu(){let[e,t]=(0,V.useState)(`overview`),[n,r]=(0,V.useState)(!1),[i,a]=(0,V.useState)(null),[o,s]=(0,V.useState)(null),c=async()=>{try{let e=await fetch(`/admin/api/stats`);if(!e.ok)return;let t=await e.json();a(t)}catch(e){console.error(`Error loading stats:`,e)}};return(0,V.useEffect)(()=>{c();let e=setInterval(c,8e3);return()=>clearInterval(e)},[]),(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(`div`,{className:`dashboard-container`,children:[(0,H.jsxs)(`header`,{className:`dashboard-header`,children:[(0,H.jsx)(`div`,{className:`header-brand`,children:(0,H.jsxs)(`div`,{className:`header-logo`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group logo-icon`}),(0,H.jsxs)(`div`,{className:`header-title`,children:[(0,H.jsx)(`h1`,{children:`ContextCortex`}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:`v2.17.1`})]})]})}),(0,H.jsxs)(`div`,{className:`header-status`,children:[(0,H.jsxs)(`div`,{className:`status-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Engine State`}),(0,H.jsx)(`span`,{className:`value`,children:i?.is_indexing?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`indicator indexing`}),` Syncing...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`indicator online`}),` Idle`]})})]}),(0,H.jsxs)(`div`,{className:`status-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Vector Backend`}),(0,H.jsxs)(`span`,{className:`value`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`,style:{marginRight:`5px`}}),(0,H.jsxs)(`span`,{children:[i?.vector_store_provider===`chroma`?`ChromaDB`:`Qdrant`,` (`,(i?.vector_store_mode||`embedded`)===`embedded`?`Embedded`:`Remote`,`)`]}),i?.vector_db_status&&(0,H.jsx)(`span`,{className:`badge ${i.vector_db_status===`Healthy`?`badge-success`:`badge-danger`}`,style:{marginLeft:`6px`,fontSize:`0.75rem`,padding:`2px 6px`},"data-testid":`vector-db-status-badge`,children:i.vector_db_status})]})]}),(0,H.jsxs)(`div`,{className:`status-item header-collection-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Collection`}),(0,H.jsx)(`span`,{className:`value code`,children:i?.vector_store_collection||`knowledge_rag_v1`})]})]}),(0,H.jsx)(`button`,{className:`menu-toggle-btn`,"aria-label":`Toggle navigation`,onClick:()=>r(!n),children:(0,H.jsx)(`i`,{className:`fa-solid ${n?`fa-xmark`:`fa-bars`}`})})]}),(0,H.jsxs)(`nav`,{className:`dashboard-nav ${n?`drawer-open`:``}`,"aria-label":`Main Navigation`,children:[(0,H.jsxs)(`button`,{className:`nav-tab ${e===`overview`?`active`:``}`,onClick:()=>{t(`overview`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-chart-pie`}),(0,H.jsx)(`span`,{children:`Overview`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`navigator`||e===`topology`?`active`:``}`,onClick:()=>{t(`navigator`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-fork`}),(0,H.jsx)(`span`,{children:`Navigator`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`git-repos`?`active`:``}`,onClick:()=>{t(`git-repos`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`}),(0,H.jsx)(`span`,{children:`Git Repositories`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`files-storage`?`active`:``}`,onClick:()=>{t(`files-storage`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),(0,H.jsx)(`span`,{children:`Files & Storage`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`ingestion-catalog`?`active`:``}`,onClick:()=>{t(`ingestion-catalog`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-book-bookmark`}),(0,H.jsx)(`span`,{children:`Ingestion Catalog`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`search-inspector`?`active`:``}`,onClick:()=>{t(`search-inspector`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),(0,H.jsx)(`span`,{children:`Search & Inspector`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`settings`?`active`:``}`,onClick:()=>{t(`settings`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-gear`}),(0,H.jsx)(`span`,{children:`Settings`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`diagnostics`?`active`:``}`,onClick:()=>{t(`diagnostics`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),(0,H.jsx)(`span`,{children:`Diagnostics & Logs`})]})]}),(0,H.jsxs)(`main`,{className:`dashboard-main`,children:[e===`overview`&&(0,H.jsx)(Ze,{stats:i,refreshStats:c}),(e===`navigator`||e===`topology`)&&(0,H.jsx)(Hu,{initialRepo:o?.repo,initialPath:o?.path,initialSymbolId:o?.symbolId,initialStartLine:o?.startLine,initialEndLine:o?.endLine,onNavigationConsumed:()=>s(null)}),e===`git-repos`&&(0,H.jsx)(it,{refreshStats:c}),e===`files-storage`&&(0,H.jsx)(ct,{refreshStats:c}),e===`ingestion-catalog`&&(0,H.jsx)(Uu,{}),e===`search-inspector`&&(0,H.jsx)(pt,{onOpenInNavigator:(e,n,r,i,a)=>{s({repo:e,path:n,symbolId:r,startLine:i,endLine:a}),t(`navigator`)}}),e===`settings`&&(0,H.jsx)(Et,{stats:i,refreshStats:c}),e===`diagnostics`&&(0,H.jsx)(Dt,{})]}),(0,H.jsx)(`footer`,{className:`dashboard-footer`,children:(0,H.jsx)(`p`,{children:`ContextCortex MCP • Universal Code & Knowledge RAG • 2026`})})]})})}(0,Ge.createRoot)(document.getElementById(`root`)).render((0,H.jsx)(V.StrictMode,{children:(0,H.jsx)(Xe,{children:(0,H.jsx)(Wu,{})})}));export{ta as _,Ua as a,ja as c,qa as d,Va as f,fa as g,Oa as h,Ba as i,Ma as l,Ea as m,mo as n,no as o,ka as p,Ha as r,Ga as s,go as t,so as u,ia as v,Ar as y}; \ No newline at end of file diff --git a/frontend/dist/assets/info-A6RAGUB7-CjXYSfue.js b/frontend/dist/assets/info-A6RAGUB7-CjXYSfue.js new file mode 100644 index 0000000..6288cd6 --- /dev/null +++ b/frontend/dist/assets/info-A6RAGUB7-CjXYSfue.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{w as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createInfoServices}; \ No newline at end of file diff --git a/frontend/dist/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js b/frontend/dist/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js new file mode 100644 index 0000000..deda7c9 --- /dev/null +++ b/frontend/dist/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js @@ -0,0 +1,2 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{y as r}from"./index-DoQkmpth.js";import{n as i}from"./mermaid-parser.core-CUrDj5TF.js";var a={parse:t(async t=>{let n=await i(`info`,t);e.debug(n)},`parse`)},o={version:`12.0.0`},s={parser:a,db:{getVersion:t(()=>o.version,`getVersion`)},renderer:{draw:t((t,i,a)=>{e.debug(`rendering info diagram +`+t);let o=r(i);n(o,100,400,!0),o.append(`g`).append(`text`).attr(`x`,100).attr(`y`,40).attr(`class`,`version`).attr(`font-size`,32).style(`text-anchor`,`middle`).text(`v${a}`)},`draw`)}};export{s as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/init-C-OQMol4.js b/frontend/dist/assets/init-C-OQMol4.js new file mode 100644 index 0000000..8aff9b3 --- /dev/null +++ b/frontend/dist/assets/init-C-OQMol4.js @@ -0,0 +1 @@ +function e(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}export{e as t}; \ No newline at end of file diff --git a/frontend/dist/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js b/frontend/dist/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js new file mode 100644 index 0000000..7266900 --- /dev/null +++ b/frontend/dist/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js @@ -0,0 +1,70 @@ +import"./src-D_iIdUkB.js";import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as t,U as n,a as r,c as i,q as a,s as o,v as s,w as c,x as l,y as u}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{p as d}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as f}from"./rough.esm-Dy-Kn_BL.js";import{y as p}from"./index-DoQkmpth.js";var m=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,14],i=[1,12],a=[1,13],o=[6,7,8],s=[1,20],c=[1,18],l=[1,19],u=[6,7,11],d=[1,6,13,14],f=[1,23],p=[1,24],m=[1,6,7,11,13,14],h={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,ishikawa:4,spaceLines:5,SPACELINE:6,NL:7,ISHIKAWA:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,TEXT:14,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`ISHIKAWA`,11:`EOF`,13:`SPACELIST`,14:`TEXT`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,1],[12,1],[12,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 15:r.addNode(a[s-1].length,a[s].trim());break;case 16:r.addNode(0,a[s].trim())}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:a},t(o,[2,3]),{1:[2,2]},t(o,[2,4]),t(o,[2,5]),{1:[2,6],6:r,12:15,13:i,14:a},{6:r,9:16,12:11,13:i,14:a},{6:s,7:c,10:17,11:l},t(u,[2,18],{14:[1,21]}),t(u,[2,16]),t(u,[2,17]),{6:s,7:c,10:22,11:l},{1:[2,7],6:r,12:15,13:i,14:a},t(d,[2,14],{7:f,11:p}),t(m,[2,8]),t(m,[2,9]),t(m,[2,10]),t(u,[2,15]),t(d,[2,13],{7:f,11:p}),t(m,[2,11]),t(m,[2,12])],defaultActions:{2:[2,1],6:[2,2]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};h.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return 6;case 1:return 8;case 2:return 8;case 3:return 6;case 4:return 7;case 5:return 13;case 6:return 14;case 7:return 11}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:ishikawa-beta\b)/i,/^(?:ishikawa\b)/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:[^\n]+)/i,/^(?:$)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7],inclusive:!0}}}})();function g(){this.yy={}}return e(g,`Parser`),g.prototype=h,h.Parser=g,new g})();m.parser=m;var h=m,g=class{constructor(){this.stack=[],this.clear=this.clear.bind(this),this.addNode=this.addNode.bind(this),this.getRoot=this.getRoot.bind(this)}static{e(this,`IshikawaDB`)}clear(){this.root=void 0,this.stack=[],this.baseLevel=void 0,r()}getRoot(){return this.root}addNode(e,t){let n=o.sanitizeText(t,l());if(!this.root){this.root={text:n,children:[]},this.stack=[{level:0,node:this.root}],a(n);return}this.baseLevel??=e;let r=e-this.baseLevel+1;for(r<=0&&(r=1);this.stack.length>1&&this.stack[this.stack.length-1].level>=r;)this.stack.pop();let i=this.stack[this.stack.length-1].node,s={text:n,children:[]};i.children.push(s),this.stack.push({level:r,node:s})}getAccTitle(){return u()}setAccTitle(e){n(e)}getAccDescription(){return s()}setAccDescription(e){t(e)}getDiagramTitle(){return c()}setDiagramTitle(e){a(e)}},_=14,v=250,y=30,b=60,x=5,S=82*Math.PI/180,C=Math.cos(S),w=Math.sin(S),T=e((e,t,n)=>{let r=e.node().getBBox(),a=r.width+t*2,o=r.height+t*2;i(e,o,a,n),e.attr(`viewBox`,`${r.x-t} ${r.y-t} ${a} ${o}`)},`applyPaddedViewBox`),E=e((e,t,n,r)=>{let i=r.db.getRoot();if(!i)return;let a=l(),{look:o,handDrawnSeed:s,themeVariables:c}=a,u=d(a.fontSize)[0]??_,m=o===`handDrawn`,h=i.children??[],g=a.ishikawa?.diagramPadding??20,y=a.ishikawa?.useMaxWidth??!1,b=p(t),x=b.append(`g`).attr(`class`,`ishikawa`),S=m?f.svg(b.node()):void 0,C=S?{roughSvg:S,seed:s??0,lineColor:c?.lineColor??`#333`,fillColor:c?.mainBkg??`#fff`}:void 0,w=`ishikawa-arrow-${t}`;m||x.append(`defs`).append(`marker`).attr(`id`,w).attr(`viewBox`,`0 0 10 10`).attr(`refX`,0).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 Z`).attr(`class`,`ishikawa-arrow`);let E=0,k=v,A=m?void 0:L(x,E,k,E,k,`ishikawa-spine`);if(O(x,E,k,i.text,u,C),!h.length){m&&L(x,E,k,E,k,`ishikawa-spine`,C),T(b,g,y);return}E-=20;let j=h.filter((e,t)=>t%2==0),N=h.filter((e,t)=>t%2==1),P=D(j),F=D(N),I=P.total+F.total,R=v,z=v;if(I>0){let e=v*2,t=v*.3;R=Math.max(t,e*(P.total/I)),z=Math.max(t,e*(F.total/I))}let B=u*2;R=Math.max(R,P.max*B),z=Math.max(z,F.max*B),k=Math.max(R,v),A&&A.attr(`y1`,k).attr(`y2`,k),x.select(`.ishikawa-head-group`).attr(`transform`,`translate(0,${k})`);let V=Math.ceil(h.length/2);for(let e=0;eMath.min(e,t.getBBox().x),1/0)}if(m)L(x,E,k,0,k,`ishikawa-spine`,C);else{A.attr(`x1`,E);let e=`url(#${w})`;x.selectAll(`line.ishikawa-branch, line.ishikawa-sub-branch`).attr(`marker-start`,e)}T(b,g,y)},`draw`),D=e(t=>{let n=e(e=>e.children.reduce((e,t)=>e+1+n(t),0),`countDescendants`);return t.reduce((e,t)=>{let r=n(t);return e.total+=r,e.max=Math.max(e.max,r),e},{total:0,max:0})},`sideStats`),O=e((e,t,n,r,i,a)=>{let o=Math.max(6,Math.floor(110/(i*.6))),s=e.append(`g`).attr(`class`,`ishikawa-head-group`).attr(`transform`,`translate(${t},${n})`),c=F(s,P(r,o),0,0,`ishikawa-head-label`,`start`,i),l=c.node().getBBox(),u=Math.max(60,l.width+6),d=Math.max(40,l.height*2+40),f=`M 0 ${-d/2} L 0 ${d/2} Q ${u*2.4} 0 0 ${-d/2} Z`;if(a){let e=a.roughSvg.path(f,{roughness:1.5,seed:a.seed,fill:a.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:a.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-head`)}else s.insert(`path`,`:first-child`).attr(`class`,`ishikawa-head`).attr(`d`,f);c.attr(`transform`,`translate(${(u-l.width)/2-l.x+3},${-l.y-l.height/2})`)},`drawHead`),k=e((t,n)=>{let r=[],i=[],a=e((e,t,o)=>{let s=n===-1?[...e].reverse():e;for(let e of s){let n=r.length,s=e.children??[];r.push({depth:o,text:P(e.text,15),parentIndex:t,childCount:s.length}),o%2==0?(i.push(n),s.length&&a(s,n,o+1)):(s.length&&a(s,n,o+1),i.push(n))}},`walk`);return a(t,-1,2),{entries:r,yOrder:i}},`flattenTree`),A=e((e,t,n,r,i,a,o)=>{let s=e.append(`g`).attr(`class`,`ishikawa-label-group`),c=F(s,t,n,r+11*i,`ishikawa-label cause`,`middle`,a).node().getBBox();if(o){let e=o.roughSvg.rectangle(c.x-20,c.y-2,c.width+40,c.height+4,{roughness:1.5,seed:o.seed,fill:o.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:o.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-label-box`)}else s.insert(`rect`,`:first-child`).attr(`class`,`ishikawa-label-box`).attr(`x`,c.x-20).attr(`y`,c.y-2).attr(`width`,c.width+40).attr(`height`,c.height+4)},`drawCauseLabel`),j=e((e,t,n,r,i,a)=>{let o=Math.sqrt(r*r+i*i);if(o===0)return;let s=r/o,c=i/o,l=-c*6,u=s*6,d=t,f=n,p=`M ${d} ${f} L ${d-s*6*2+l} ${f-c*6*2+u} L ${d-s*6*2-l} ${f-c*6*2-u} Z`,m=a.roughSvg.path(p,{roughness:1,seed:a.seed,fill:a.lineColor,fillStyle:`solid`,stroke:a.lineColor,strokeWidth:1});e.append(()=>m)},`drawArrowMarker`),M=e((e,t,n,r,i,a,o,s)=>{let c=t.children??[],l=a*(c.length?1:.2),u=-C*l,d=w*l*i,f=n+u,p=r+d;if(L(e,n,r,f,p,`ishikawa-branch`,s),s&&j(e,n,r,n-f,r-p,s),A(e,t.text,f,p,i,o,s),!c.length)return;let{entries:m,yOrder:h}=k(c,i),g=m.length,_=Array(g);for(let[e,t]of h.entries())_[t]=r+d*((e+1)/(g+1));let v=new Map;v.set(-1,{x0:n,y0:r,x1:f,y1:p,childCount:c.length,childrenDrawn:0});let S=-C,T=w*i,E=i<0?`ishikawa-label up`:`ishikawa-label down`;for(let[t,n]of m.entries()){let r=_[t],i=v.get(n.parentIndex),a=e.append(`g`).attr(`class`,`ishikawa-sub-group`),c=0,l=0,u=0;if(n.depth%2==0){let e=i.y1-i.y0;c=I(i.x0,i.x1,e?(r-i.y0)/e:.5),l=r,u=c-(n.childCount>0?b+n.childCount*x:y),L(a,c,r,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,r,1,0,s),F(a,n.text,u,r,`ishikawa-label align`,`end`,o)}else{let e=i.childrenDrawn++;c=I(i.x0,i.x1,(i.childCount-e)/(i.childCount+1)),l=i.y0,u=c+S*((r-l)/T),L(a,c,l,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,l,c-u,l-r,s),F(a,n.text,u,r,E,`end`,o)}n.childCount>0&&v.set(t,{x0:c,y0:l,x1:u,y1:r,childCount:n.childCount,childrenDrawn:0})}},`drawBranch`),N=e(e=>e.split(/|\n/),`splitLines`),P=e((e,t)=>{if(e.length<=t)return e;let n=[];for(let r of e.split(/\s+/)){let e=n.length-1;e>=0&&n[e].length+1+r.length<=t?n[e]+=` `+r:n.push(r)}return n.join(` +`)},`wrapText`),F=e((e,t,n,r,i,a,o)=>{let s=N(t),c=o*1.05,l=e.append(`text`).attr(`class`,i).attr(`text-anchor`,a).attr(`x`,n).attr(`y`,r-(s.length-1)*c/2);for(let[e,t]of s.entries())l.append(`tspan`).attr(`x`,n).attr(`dy`,e===0?0:c).text(t);return l},`drawMultilineText`),I=e((e,t,n)=>e+(t-e)*n,`lerp`),L=e((e,t,n,r,i,a,o)=>{if(o){let s=o.roughSvg.line(t,n,r,i,{roughness:1.5,seed:o.seed,stroke:o.lineColor,strokeWidth:2});e.append(()=>s).attr(`class`,a);return}return e.append(`line`).attr(`class`,a).attr(`x1`,t).attr(`y1`,n).attr(`x2`,r).attr(`y2`,i)},`drawLine`),R={parser:h,get db(){return new g},renderer:{draw:E},styles:e(e=>` +.ishikawa .ishikawa-spine, +.ishikawa .ishikawa-branch, +.ishikawa .ishikawa-sub-branch { + stroke: ${e.lineColor}; + stroke-width: 2; + fill: none; +} + +.ishikawa .ishikawa-sub-branch { + stroke-width: 1; +} + +.ishikawa .ishikawa-arrow { + fill: ${e.lineColor}; +} + +.ishikawa .ishikawa-head { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + stroke-width: 2; +} + +.ishikawa .ishikawa-label-box { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + stroke-width: 2; +} + +.ishikawa text { + font-family: ${e.fontFamily}; + font-size: ${e.fontSize}; + fill: ${e.textColor}; +} + +.ishikawa .ishikawa-head-label { + font-weight: 600; + text-anchor: middle; + dominant-baseline: middle; + font-size: 14px; +} + +.ishikawa .ishikawa-label { + text-anchor: end; +} + +.ishikawa .ishikawa-label.cause { + text-anchor: middle; + dominant-baseline: middle; +} + +.ishikawa .ishikawa-label.align { + text-anchor: end; + dominant-baseline: middle; +} + +.ishikawa .ishikawa-label.up { + dominant-baseline: baseline; +} + +.ishikawa .ishikawa-label.down { + dominant-baseline: hanging; +} +`,`getStyles`)};export{R as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js b/frontend/dist/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js new file mode 100644 index 0000000..212ca98 --- /dev/null +++ b/frontend/dist/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js @@ -0,0 +1,139 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,c as a,q as o,v as s,w as c,x as l,y as u}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as d}from"./arc-BJA87daU.js";import{t as f}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{a as p,n as m,o as h,s as g}from"./chunk-GWA4HPMP-C1P4FmAY.js";var _=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[6,8,10,11,12,14,16,17,18],r=[1,9],i=[1,10],a=[1,11],o=[1,12],s=[1,13],c=[1,14],l={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,journey:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,title:11,acc_title:12,acc_title_value:13,acc_descr:14,acc_descr_value:15,acc_descr_multiline_value:16,section:17,taskName:18,taskData:19,$accept:0,$end:1},terminals_:{2:`error`,4:`journey`,6:`EOF`,8:`SPACE`,10:`NEWLINE`,11:`title`,12:`acc_title`,13:`acc_title_value`,14:`acc_descr`,15:`acc_descr_value`,16:`acc_descr_multiline_value`,17:`section`,18:`taskName`,19:`taskData`},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,2]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:case 7:this.$=[];break;case 8:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 9:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 10:case 11:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 12:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 13:r.addTask(a[s-1],a[s]),this.$=`task`}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,7],{1:[2,1]}),e(n,[2,3]),{9:15,11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,5]),e(n,[2,6]),e(n,[2,8]),{13:[1,16]},{15:[1,17]},e(n,[2,11]),e(n,[2,12]),{19:[1,18]},e(n,[2,4]),e(n,[2,9]),e(n,[2,10]),e(n,[2,13])],defaultActions:{},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};l.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 10;case 3:break;case 4:break;case 5:return 4;case 6:return 11;case 7:return this.begin(`acc_title`),12;case 8:return this.popState(),`acc_title_value`;case 9:return this.begin(`acc_descr`),14;case 10:return this.popState(),`acc_descr_value`;case 11:this.begin(`acc_descr_multiline`);break;case 12:this.popState();break;case 13:return`acc_descr_multiline_value`;case 14:return 17;case 15:return 18;case 16:return 19;case 17:return`:`;case 18:return 6;case 19:return`INVALID`}},`anonymous`),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:journey\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,9,11,14,15,16,17,18,19],inclusive:!0}}}})();function u(){this.yy={}}return t(u,`Parser`),u.prototype=l,l.Parser=u,new u})();_.parser=_;var v=_,y=``,b=[],x=[],S=[],C=t(function(){b.length=0,x.length=0,y=``,S.length=0,i()},`clear`),w=t(function(e){y=e,b.push(e)},`addSection`),T=t(function(){return b},`getSections`),E=t(function(){let e=A(),t=0;for(;!e&&t<100;)e=A(),t++;return x.push(...S),x},`getTasks`),D=t(function(){let e=[];return x.forEach(t=>{t.people&&e.push(...t.people)}),[...new Set(e)].sort()},`updateActors`),O=t(function(e,t){let n=t.substr(1).split(`:`),r=0,i=[];n.length===1?(r=Number(n[0]),i=[]):(r=Number(n[0]),i=n[1].split(`,`));let a=i.map(e=>e.trim()),o={section:y,type:y,people:a,task:e,score:r};S.push(o)},`addTask`),k=t(function(e){let t={section:y,type:y,description:e,task:e,classes:[]};x.push(t)},`addTaskOrg`),A=t(function(){let e=t(function(e){return S[e].processed},`compileTask`),n=!0;for(let[t,r]of S.entries())e(t),n&&=r.processed;return n},`compileTasks`),j={getConfig:t(()=>l().journey,`getConfig`),clear:C,setDiagramTitle:o,getDiagramTitle:c,setAccTitle:r,getAccTitle:u,setAccDescription:n,getAccDescription:s,addSection:w,getSections:T,getTasks:E,addTask:O,addTaskOrg:k,getActors:t(function(){return D()},`getActors`)},M=t(e=>`.label { + font-family: ${e.fontFamily}; + color: ${e.textColor}; + } + .mouth { + stroke: #666; + } + + line { + stroke: ${e.textColor} + } + + .legend { + fill: ${e.textColor}; + font-family: ${e.fontFamily}; + } + + .label text { + fill: #333; + } + .label { + color: ${e.textColor} + } + + .face { + ${e.faceColor?`fill: ${e.faceColor}`:`fill: #FFF8DC`}; + stroke: #999; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: 1px; + } + + .node .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: 1.5px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + rect { + opacity: 0.5; + } + text-align: center; + } + + .cluster rect { + } + + .cluster text { + fill: ${e.titleColor}; + } + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .task-type-0, .section-type-0 { + ${e.fillType0?`fill: ${e.fillType0}`:``}; + } + .task-type-1, .section-type-1 { + ${e.fillType0?`fill: ${e.fillType1}`:``}; + } + .task-type-2, .section-type-2 { + ${e.fillType0?`fill: ${e.fillType2}`:``}; + } + .task-type-3, .section-type-3 { + ${e.fillType0?`fill: ${e.fillType3}`:``}; + } + .task-type-4, .section-type-4 { + ${e.fillType0?`fill: ${e.fillType4}`:``}; + } + .task-type-5, .section-type-5 { + ${e.fillType0?`fill: ${e.fillType5}`:``}; + } + .task-type-6, .section-type-6 { + ${e.fillType0?`fill: ${e.fillType6}`:``}; + } + .task-type-7, .section-type-7 { + ${e.fillType0?`fill: ${e.fillType7}`:``}; + } + + .actor-0 { + ${e.actor0?`fill: ${e.actor0}`:``}; + } + .actor-1 { + ${e.actor1?`fill: ${e.actor1}`:``}; + } + .actor-2 { + ${e.actor2?`fill: ${e.actor2}`:``}; + } + .actor-3 { + ${e.actor3?`fill: ${e.actor3}`:``}; + } + .actor-4 { + ${e.actor4?`fill: ${e.actor4}`:``}; + } + .actor-5 { + ${e.actor5?`fill: ${e.actor5}`:``}; + } + ${f()} +`,`getStyles`),N=t(function(e,t){return p(e,t)},`drawRect`),P=t(function(e,n){let r=e.append(`circle`).attr(`cx`,n.cx).attr(`cy`,n.cy).attr(`class`,`face`).attr(`r`,15).attr(`stroke-width`,2).attr(`overflow`,`visible`),i=e.append(`g`);i.append(`circle`).attr(`cx`,n.cx-5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`),i.append(`circle`).attr(`cx`,n.cx+5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`);function a(e){let t=d().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+2)+`)`)}t(a,`smile`);function o(e){let t=d().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+7)+`)`)}t(o,`sad`);function s(e){e.append(`line`).attr(`class`,`mouth`).attr(`stroke`,2).attr(`x1`,n.cx-5).attr(`y1`,n.cy+7).attr(`x2`,n.cx+5).attr(`y2`,n.cy+7).attr(`class`,`mouth`).attr(`stroke-width`,`1px`).attr(`stroke`,`#666`)}return t(s,`ambivalent`),n.score>3?a(i):n.score<3?o(i):s(i),r},`drawFace`),F=t(function(e,t){let n=e.append(`circle`);return n.attr(`cx`,t.cx),n.attr(`cy`,t.cy),n.attr(`class`,`actor-`+t.pos),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`r`,t.r),n.class!==void 0&&n.attr(`class`,n.class),t.title!==void 0&&n.append(`title`).text(t.title),n},`drawCircle`),I=t(function(e,t){return h(e,t)},`drawText`),L=t(function(e,n){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}t(r,`genPoints`);let i=e.append(`polygon`);i.attr(`points`,r(n.x,n.y,50,20,7)),i.attr(`class`,`labelBox`),n.y+=n.labelMargin,n.x+=.5*n.labelMargin,I(e,n)},`drawLabel`),R=t(function(e,t,n){let r=e.append(`g`),i=g();i.x=t.x,i.y=t.y,i.fill=t.fill,i.width=n.width*t.taskCount+n.diagramMarginX*(t.taskCount-1),i.height=n.height,i.class=`journey-section section-type-`+t.num,i.rx=3,i.ry=3,N(r,i),H(n)(t.text,r,i.x,i.y,i.width,i.height,{class:`journey-section section-type-`+t.num},n,t.colour)},`drawSection`),z=-1,B=t(function(e,t,n,r){let i=t.x+n.width/2,a=e.append(`g`);z++,a.append(`line`).attr(`id`,r+`-task`+z).attr(`x1`,i).attr(`y1`,t.y).attr(`x2`,i).attr(`y2`,450).attr(`class`,`task-line`).attr(`stroke-width`,`1px`).attr(`stroke-dasharray`,`4 2`).attr(`stroke`,`#666`),P(a,{cx:i,cy:300+(5-t.score)*30,score:t.score});let o=g();o.x=t.x,o.y=t.y,o.fill=t.fill,o.width=n.width,o.height=n.height,o.class=`task task-type-`+t.num,o.rx=3,o.ry=3,N(a,o);let s=t.x+14;t.people.forEach(e=>{let n=t.actors[e].color,r={cx:s,cy:t.y,r:7,fill:n,stroke:`#000`,title:e,pos:t.actors[e].position};F(a,r),s+=10}),H(n)(t.task,a,o.x,o.y,o.width,o.height,{class:`task`},n,t.colour)},`drawTask`),V=t(function(e,t){m(e,t)},`drawBackgroundRect`),H=(function(){function e(e,t,n,r,a,o,s,c){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`font-color`,c).style(`text-anchor`,`middle`).text(e),s)}t(e,`byText`);function n(e,t,n,r,a,o,s,c,l){let{taskFontSize:u,taskFontFamily:d}=c,f=e.split(//gi);for(let e=0;e{let a=G[i].color,o={cx:20,cy:r,r:7,fill:a,stroke:`#000`,pos:G[i].position};U.drawCircle(e,o);let s=e.append(`text`).attr(`visibility`,`hidden`).text(i),c=s.node().getBoundingClientRect().width;s.remove();let l=[];if(c<=n)l=[i];else{let t=i.split(` `),r=``;s=e.append(`text`).attr(`visibility`,`hidden`),t.forEach(e=>{let t=r?`${r} ${e}`:e;if(s.text(t),s.node().getBoundingClientRect().width>n){if(r&&l.push(r),r=e,s.text(e),s.node().getBoundingClientRect().width>n){let t=``;for(let r of e)t+=r,s.text(t+`-`),s.node().getBoundingClientRect().width>n&&(l.push(t.slice(0,-1)+`-`),t=r);r=t}}else r=t}),r&&l.push(r),s.remove()}l.forEach((n,i)=>{let a={x:40,y:r+7+i*20,fill:`#666`,text:n,textMargin:t.boxTextMargin??5},o=U.drawText(e,a).node().getBoundingClientRect().width;o>K&&o>t.leftMargin-o&&(K=o)}),r+=Math.max(20,l.length*20)})}t(q,`drawActorLegend`);var J=l().journey,Y=0,ee=t(function(t,n,r,i){let o=l(),s=o.journey.titleColor,c=o.journey.titleFontSize,u=o.journey.titleFontFamily,d=o.securityLevel,f;d===`sandbox`&&(f=e(`#i`+n));let p=e(d===`sandbox`?f.nodes()[0].contentDocument.body:`body`);X.init();let m=p.select(`#`+n);U.initGraphics(m,n);let h=i.db.getTasks(),g=i.db.getDiagramTitle(),_=i.db.getActors();for(let e in G)delete G[e];let v=0;_.forEach(e=>{G[e]={color:J.actorColours[v%J.actorColours.length],position:v},v++}),q(m),Y=J.leftMargin+K,X.insert(0,0,Y,Object.keys(G).length*50),te(m,h,0,n);let y=X.getBounds();g&&m.append(`text`).text(g).attr(`x`,Y).attr(`font-size`,c).attr(`font-weight`,`bold`).attr(`y`,25).attr(`fill`,s).attr(`font-family`,u);let b=y.stopy-y.starty+2*J.diagramMarginY,x=Y+y.stopx+2*J.diagramMarginX;a(m,b,x,J.useMaxWidth),m.append(`line`).attr(`x1`,Y).attr(`y1`,J.height*4).attr(`x2`,x-Y-4).attr(`y2`,J.height*4).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#`+n+`-arrowhead)`);let S=g?70:0;m.attr(`viewBox`,`${y.startx} -25 ${x} ${b+S}`),m.attr(`preserveAspectRatio`,`xMinYMin meet`),m.attr(`height`,b+S+25)},`draw`),X={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],init:t(function(){this.sequenceItems=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0},`init`),updateVal:t(function(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])},`updateVal`),updateBounds:t(function(e,n,r,i){let a=l().journey,o=this,s=0;function c(c){return t(function(t){s++;let l=o.sequenceItems.length-s+1;o.updateVal(t,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(t,`stopy`,i+l*a.boxMargin,Math.max),o.updateVal(X.data,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopx`,r+l*a.boxMargin,Math.max),c!==`activation`&&(o.updateVal(t,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(t,`stopx`,r+l*a.boxMargin,Math.max),o.updateVal(X.data,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopy`,i+l*a.boxMargin,Math.max))},`updateItemBounds`)}t(c,`updateFn`),this.sequenceItems.forEach(c())},`updateBounds`),insert:t(function(e,t,n,r){let i=Math.min(e,n),a=Math.max(e,n),o=Math.min(t,r),s=Math.max(t,r);this.updateVal(X.data,`startx`,i,Math.min),this.updateVal(X.data,`starty`,o,Math.min),this.updateVal(X.data,`stopx`,a,Math.max),this.updateVal(X.data,`stopy`,s,Math.max),this.updateBounds(i,o,a,s)},`insert`),bumpVerticalPos:t(function(e){this.verticalPos+=e,this.data.stopy=this.verticalPos},`bumpVerticalPos`),getVerticalPos:t(function(){return this.verticalPos},`getVerticalPos`),getBounds:t(function(){return this.data},`getBounds`)},Z=J.sectionFills,Q=J.sectionColours,te=t(function(e,t,n,r){let i=l().journey,a=``,o=n+(i.height*2+i.diagramMarginY),s=0,c=`#CCC`,u=`black`,d=0;for(let[n,l]of t.entries()){if(a!==l.section){c=Z[s%Z.length],d=s%Z.length,u=Q[s%Q.length];let r=0,o=l.section;for(let e=n;e(G[t]&&(e[t]=G[t]),e),{});l.x=n*i.taskMargin+n*i.width+Y,l.y=o,l.width=i.diagramMarginX,l.height=i.diagramMarginY,l.colour=u,l.fill=c,l.num=d,l.actors=f,U.drawTask(e,l,i,r),X.insert(l.x,l.y,l.x+l.width+i.taskMargin,450)}},`drawTasks`),$={setConf:W,draw:ee},ne={parser:v,db:j,renderer:$,styles:M,init:t(e=>{$.setConf(e.journey),j.clear()},`init`)};export{ne as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js b/frontend/dist/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js new file mode 100644 index 0000000..73d999c --- /dev/null +++ b/frontend/dist/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js @@ -0,0 +1,89 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{Y as n,at as r,f as i,nt as a,rt as o,x as s,z as c}from"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as l,r as u}from"./chunk-5DYCD2WN-WToj2Jza.js";import{_ as d,h as f,v as p,y as m}from"./index-DoQkmpth.js";import{t as h}from"./chunk-5VM5RSS4-ZNzvKenW.js";var g=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,13],i=[1,12],a=[1,15],o=[1,16],s=[1,20],c=[1,19],l=[6,7,8],u=[1,26],d=[1,24],f=[1,25],p=[6,7,11],m=[1,31],h=[6,7,11,24],g=[1,6,13,16,17,20,23],_=[1,35],v=[1,36],y=[1,6,7,11,13,16,17,20,23],b=[1,38],x={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`KANBAN`,11:`EOF`,13:`SPACELIST`,16:`ICON`,17:`CLASS`,20:`NODE_DSTART`,21:`NODE_DESCR`,22:`NODE_DEND`,23:`NODE_ID`,24:`SHAPE_DATA`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace(`Stop NL `);break;case 9:r.getLogger().trace(`Stop EOF `);break;case 11:r.getLogger().trace(`Stop NL2 `);break;case 12:r.getLogger().trace(`Stop EOF2 `);break;case 15:r.getLogger().info(`Node: `,a[s-1].id),r.addNode(a[s-2].length,a[s-1].id,a[s-1].descr,a[s-1].type,a[s]);break;case 16:r.getLogger().info(`Node: `,a[s].id),r.addNode(a[s-1].length,a[s].id,a[s].descr,a[s].type);break;case 17:r.getLogger().trace(`Icon: `,a[s]),r.decorateNode({icon:a[s]});break;case 18:case 23:r.decorateNode({class:a[s]});break;case 19:r.getLogger().trace(`SPACELIST`);break;case 20:r.getLogger().trace(`Node: `,a[s-1].id),r.addNode(0,a[s-1].id,a[s-1].descr,a[s-1].type,a[s]);break;case 21:r.getLogger().trace(`Node: `,a[s].id),r.addNode(0,a[s].id,a[s].descr,a[s].type);break;case 22:r.decorateNode({icon:a[s]});break;case 27:r.getLogger().trace(`node found ..`,a[s-2]),this.$={id:a[s-1],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 28:this.$={id:a[s],descr:a[s],type:0};break;case 29:r.getLogger().trace(`node found ..`,a[s-3]),this.$={id:a[s-3],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 30:this.$=a[s-1]+a[s];break;case 31:this.$=a[s]}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},e(l,[2,3]),{1:[2,2]},e(l,[2,4]),e(l,[2,5]),{1:[2,6],6:r,12:21,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},{6:r,9:22,12:11,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},{6:u,7:d,10:23,11:f},e(p,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:s,23:c}),e(p,[2,19]),e(p,[2,21],{15:30,24:m}),e(p,[2,22]),e(p,[2,23]),e(h,[2,25]),e(h,[2,26]),e(h,[2,28],{20:[1,32]}),{21:[1,33]},{6:u,7:d,10:34,11:f},{1:[2,7],6:r,12:21,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},e(g,[2,14],{7:_,11:v}),e(y,[2,8]),e(y,[2,9]),e(y,[2,10]),e(p,[2,16],{15:37,24:m}),e(p,[2,17]),e(p,[2,18]),e(p,[2,20],{24:b}),e(h,[2,31]),{21:[1,39]},{22:[1,40]},e(g,[2,13],{7:_,11:v}),e(y,[2,11]),e(y,[2,12]),e(p,[2,15],{24:b}),e(h,[2,30]),{22:[1,41]},e(h,[2,27]),e(h,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};x.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return this.pushState(`shapeData`),t.yytext=``,24;case 1:return this.pushState(`shapeDataStr`),24;case 2:return this.popState(),24;case 3:return t.yytext=t.yytext.replace(/\n\s*/g,`
    `),24;case 4:return 24;case 5:this.popState();break;case 6:return e.getLogger().trace(`Found comment`,t.yytext),6;case 7:return 8;case 8:this.begin(`CLASS`);break;case 9:return this.popState(),17;case 10:this.popState();break;case 11:e.getLogger().trace(`Begin icon`),this.begin(`ICON`);break;case 12:return e.getLogger().trace(`SPACELINE`),6;case 13:return 7;case 14:return 16;case 15:e.getLogger().trace(`end icon`),this.popState();break;case 16:return e.getLogger().trace(`Exploding node`),this.begin(`NODE`),20;case 17:return e.getLogger().trace(`Cloud`),this.begin(`NODE`),20;case 18:return e.getLogger().trace(`Explosion Bang`),this.begin(`NODE`),20;case 19:return e.getLogger().trace(`Cloud Bang`),this.begin(`NODE`),20;case 20:return this.begin(`NODE`),20;case 21:return this.begin(`NODE`),20;case 22:return this.begin(`NODE`),20;case 23:return this.begin(`NODE`),20;case 24:return 13;case 25:return 23;case 26:return 11;case 27:this.begin(`NSTR2`);break;case 28:return`NODE_DESCR`;case 29:this.popState();break;case 30:e.getLogger().trace(`Starting NSTR`),this.begin(`NSTR`);break;case 31:return e.getLogger().trace(`description:`,t.yytext),`NODE_DESCR`;case 32:this.popState();break;case 33:return this.popState(),e.getLogger().trace(`node end ))`),`NODE_DEND`;case 34:return this.popState(),e.getLogger().trace(`node end )`),`NODE_DEND`;case 35:return this.popState(),e.getLogger().trace(`node end ...`,t.yytext),`NODE_DEND`;case 36:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 37:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 38:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 39:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 40:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 41:return e.getLogger().trace(`Long description:`,t.yytext),21;case 42:return e.getLogger().trace(`Long description:`,t.yytext),21}},`anonymous`),rules:[/^(?:@\{)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^\"]+)/i,/^(?:[^}^"]+)/i,/^(?:\})/i,/^(?:\s*%%.*)/i,/^(?:kanban\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}@]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{shapeDataEndBracket:{rules:[],inclusive:!1},shapeDataStr:{rules:[2,3],inclusive:!1},shapeData:{rules:[1,4,5],inclusive:!1},CLASS:{rules:[9,10],inclusive:!1},ICON:{rules:[14,15],inclusive:!1},NSTR2:{rules:[28,29],inclusive:!1},NSTR:{rules:[31,32],inclusive:!1},NODE:{rules:[27,30,33,34,35,36,37,38,39,40,41,42],inclusive:!1},INITIAL:{rules:[0,6,7,8,11,12,13,16,17,18,19,20,21,22,23,24,25,26],inclusive:!0}}}})();function S(){this.yy={}}return t(S,`Parser`),S.prototype=x,x.Parser=S,new S})();g.parser=g;var _=g,v=[],y=[],b=0,x={},S=t(()=>{v=[],y=[],b=0,x={}},`clear`),C=t(e=>{if(v.length===0)return null;let t=v[0].level,n=null;for(let e=v.length-1;e>=0;e--)if(v[e].level===t&&!n&&(n=v[e]),v[e].levelt.parentId===e.id);for(let n of i){let i={id:n.id,parentId:e.id,label:c(n.label??``,r),labelType:`markdown`,isGroup:!1,ticket:n?.ticket,priority:n?.priority,assigned:n?.assigned,icon:n?.icon,shape:`kanbanItem`,level:n.level,rx:5,ry:5,cssStyles:[`text-align: left`]};t.push(i)}}return{nodes:t,edges:e,other:{},config:s()}},`getData`),E=t((e,t,n,r,a)=>{let o=s(),l=o.mindmap?.padding??i.mindmap.padding;switch(r){case D.ROUNDED_RECT:case D.RECT:case D.HEXAGON:l*=2}let u={id:c(t,o)||`kbn`+b++,level:e,label:c(n,o),width:o.mindmap?.maxNodeWidth??i.mindmap.maxNodeWidth,padding:l,isGroup:!1};if(a!==void 0){let e;e=a.includes(` +`)?a+` +`:`{ +`+a+` +}`;let t=p(e,{schema:d});if(t.shape&&(t.shape!==t.shape.toLowerCase()||t.shape.includes(`_`)))throw Error(`No such shape: ${t.shape}. Shape names should be lowercase.`);t?.shape&&t.shape===`kanbanItem`&&(u.shape=t?.shape),t?.label&&(u.label=t?.label),t?.icon&&(u.icon=t?.icon.toString()),t?.assigned&&(u.assigned=t?.assigned.toString()),t?.ticket&&(u.ticket=t?.ticket.toString()),t?.priority&&(u.priority=t?.priority)}let f=C(e);f?u.parentId=f.id||`kbn`+b++:y.push(u),v.push(u)},`addNode`),D={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},O={clear:S,addNode:E,getSections:w,getData:T,nodeType:D,getType:t((t,n)=>{switch(e.debug(`In get type`,t,n),t){case`[`:return D.RECT;case`(`:return n===`)`?D.ROUNDED_RECT:D.CLOUD;case`((`:return D.CIRCLE;case`)`:return D.CLOUD;case`))`:return D.BANG;case`{{`:return D.HEXAGON;default:return D.DEFAULT}},`getType`),setElementForId:t((e,t)=>{x[e]=t},`setElementForId`),decorateNode:t(e=>{if(!e)return;let t=s(),n=v[v.length-1];e.icon&&(n.icon=c(e.icon,t)),e.class&&(n.cssClasses=c(e.class,t))},`decorateNode`),type2Str:t(e=>{switch(e){case D.DEFAULT:return`no-border`;case D.RECT:return`rect`;case D.ROUNDED_RECT:return`rounded-rect`;case D.CIRCLE:return`circle`;case D.CLOUD:return`cloud`;case D.BANG:return`bang`;case D.HEXAGON:return`hexgon`;default:return`no-border`}},`type2Str`),getLogger:t(()=>e,`getLogger`),getElementById:t(e=>x[e],`getElementById`)},k={draw:t(async(t,r,a,o)=>{e.debug(`Rendering kanban diagram +`+t);let c=o.db.getData(),d=s();d.htmlLabels=!1;let p=m(r);for(let e of c.nodes)e.domId=`${r}-${e.id}`;let h=p.append(`g`);h.attr(`class`,`sections`);let g=p.append(`g`);g.attr(`class`,`items`);let _=c.nodes.filter(e=>e.isGroup),v=0,y=[],b=25;for(let e of _){let t=d?.kanban?.sectionWidth||200;v+=1,e.x=t*v+(v-1)*10/2,e.width=t,e.y=0,e.height=t*3,e.rx=5,e.ry=5,e.cssClasses=e.cssClasses+` section-`+v;let n=await f(h,e);b=Math.max(b,n?.labelBBox?.height),y.push(n)}let x=0;for(let e of _){let t=y[x];x+=1;let n=d?.kanban?.sectionWidth||200,r=-n*3/2+b,i=r,a=c.nodes.filter(t=>t.parentId===e.id);for(let t of a){if(t.isGroup)throw Error(`Groups within groups are not allowed in Kanban diagrams`);t.x=e.x,t.width=n-15;let r=(await u(g,t,{config:d})).node().getBBox();t.y=i+r.height/2,await l(t),i=t.y+r.height/2+5}let o=t.cluster.select(`rect`),s=Math.max(i-r+30,50)+(b-25);o.attr(`height`,s)}n(void 0,p,d.mindmap?.padding??i.kanban.padding,d.mindmap?.useMaxWidth??i.kanban.useMaxWidth)},`draw`)},A=t(e=>{let n=``;for(let t=0;te.darkMode?a(t,n):o(t,n),`adjuster`);for(let t=0;t` + .edge { + stroke-width: 3; + } + ${A(e)} + .section-root rect, .section-root path, .section-root circle, .section-root polygon { + fill: ${e.git0}; + } + .section-root text { + fill: ${e.gitBranchLabel0}; + } + .icon-container { + height:100%; + display: flex; + justify-content: center; + align-items: center; + } + .edge { + fill: none; + } + .cluster-label, .label { + color: ${e.textColor}; + fill: ${e.textColor}; + } + .kanban-label { + dy: 1em; + alignment-baseline: middle; + text-anchor: middle; + dominant-baseline: middle; + text-align: center; + } + ${h()} +`,`getStyles`)};export{j as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/katex-CXMH3UgJ.js b/frontend/dist/assets/katex-CXMH3UgJ.js new file mode 100644 index 0000000..bd95525 --- /dev/null +++ b/frontend/dist/assets/katex-CXMH3UgJ.js @@ -0,0 +1,257 @@ +var e=class e extends Error{constructor(t,n){var r=`KaTeX parse error: `+t,i,a,o=n&&n.loc;if(o&&o.start<=o.end){var s=o.lexer.input;i=o.start,a=o.end,i===s.length?r+=` at end of input: `:r+=` at position `+(i+1)+`: `;var c=s.slice(i,a).replace(/[^]/g,`$&̲`),l=i>15?`…`+s.slice(i-15,i):s.slice(0,i),u=a+15e.replace(t,`-$1`).toLowerCase(),r={"&":`&`,">":`>`,"<":`<`,'"':`"`,"'":`'`},i=/[&><"']/g,a=e=>String(e).replace(i,e=>r[e]),o=e=>e.type===`ordgroup`||e.type===`color`?e.body.length===1?o(e.body[0]):e:e.type===`font`?o(e.body):e,s=new Set([`mathord`,`textord`,`atom`]),c=e=>s.has(o(e).type),l=e=>{var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return t?t[2]!==`:`||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?null:t[1].toLowerCase():`_relative`},u={displayMode:{type:`boolean`,description:`Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.`,cli:`-d, --display-mode`},output:{type:{enum:[`htmlAndMathml`,`html`,`mathml`]},description:`Determines the markup language of the output.`,cli:`-F, --format `},leqno:{type:`boolean`,description:`Render display math in leqno style (left-justified tags).`},fleqn:{type:`boolean`,description:`Render display math flush left.`},throwOnError:{type:`boolean`,default:!0,cli:`-t, --no-throw-on-error`,cliDescription:`Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error.`},errorColor:{type:`string`,default:`#cc0000`,cli:`-c, --error-color `,cliDescription:`A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.`,cliProcessor:e=>`#`+e},macros:{type:`object`,cli:`-m, --macro `,cliDescription:`Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).`,cliDefault:[],cliProcessor:(e,t)=>(t.push(e),t)},minRuleThickness:{type:`number`,description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:`--min-rule-thickness `,cliProcessor:parseFloat},colorIsTextColor:{type:`boolean`,description:`Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.`,cli:`-b, --color-is-text-color`},strict:{type:[{enum:[`warn`,`ignore`,`error`]},`boolean`,`function`],description:`Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.`,cli:`-S, --strict`,cliDefault:!1},trust:{type:[`boolean`,`function`],description:`Trust the input, enabling all HTML features such as \\url.`,cli:`-T, --trust`},maxSize:{type:`number`,default:1/0,description:`If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large`,processor:e=>Math.max(0,e),cli:`-s, --max-size `,cliProcessor:parseInt},maxExpand:{type:`number`,default:1e3,description:`Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.`,processor:e=>Math.max(0,e),cli:`-e, --max-expand `,cliProcessor:e=>e===`Infinity`?1/0:parseInt(e)},globalGroup:{type:`boolean`,cli:!1}};function d(e){if(typeof e!=`string`)return e.enum[0];switch(e){case`boolean`:return!1;case`string`:return``;case`number`:return 0;case`object`:return{};default:throw Error(`Unexpected schema type; settings must declare an explicit default.`)}}function f(e){return e.default===void 0?d(Array.isArray(e.type)?e.type[0]:e.type):e.default}function p(e,t,n,r){var i=n[t];e[t]=i===void 0?f(r):r.processor?r.processor(i):i}var m=class{constructor(e){e===void 0&&(e={}),this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e||={};for(var t of Object.keys(u)){var n=u[t];n&&p(this,t,e,n)}}reportNonstrict(t,n,r){var i=this.strict;if(typeof i==`function`&&(i=i(t,n,r)),!(!i||i===`ignore`)){if(i===!0||i===`error`)throw new e(`LaTeX-incompatible input and strict mode is set to 'error': `+(n+` [`+t+`]`),r);i===`warn`?typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(n+` [`+t+`]`)):typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+i+`': `+n+` [`+t+`]`))}}useStrictBehavior(e,t,n){var r=this.strict;if(typeof r==`function`)try{r=r(e,t,n)}catch{r=`error`}return!r||r===`ignore`?!1:r===!0||r===`error`?!0:r===`warn`?(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)),!1):(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`)),!1)}isTrusted(e){if(`url`in e&&e.url&&!e.protocol){var t=l(e.url);if(t==null)return!1;e.protocol=t}return!!(typeof this.trust==`function`?this.trust(e):this.trust)}},h=class{constructor(e,t,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=t,this.cramped=n}sup(){return w[ee[this.id]]}sub(){return w[T[this.id]]}fracNum(){return w[te[this.id]]}fracDen(){return w[ne[this.id]]}cramp(){return w[re[this.id]]}text(){return w[ie[this.id]]}isTight(){return this.size>=2}},g=0,_=1,v=2,y=3,b=4,x=5,S=6,C=7,w=[new h(g,0,!1),new h(_,0,!0),new h(v,1,!1),new h(y,1,!0),new h(b,2,!1),new h(x,2,!0),new h(S,3,!1),new h(C,3,!0)],ee=[b,x,b,x,S,C,S,C],T=[x,x,x,x,C,C,C,C],te=[v,y,b,x,S,C,S,C],ne=[y,y,x,x,C,C,C,C],re=[_,_,y,y,x,x,C,C],ie=[g,_,v,y,v,y,v,y],E={DISPLAY:w[g],TEXT:w[v],SCRIPT:w[b],SCRIPTSCRIPT:w[S]},ae=[{name:`latin`,blocks:[[256,591],[768,879]]},{name:`cyrillic`,blocks:[[1024,1279]]},{name:`armenian`,blocks:[[1328,1423]]},{name:`brahmic`,blocks:[[2304,4255]]},{name:`georgian`,blocks:[[4256,4351]]},{name:`cjk`,blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:`hangul`,blocks:[[44032,55215]]}];function oe(e){for(var t=0;t=i[0]&&e<=i[1])return n.name}return null}var se=[];ae.forEach(e=>e.blocks.forEach(e=>se.push(...e)));function ce(e){for(var t=0;t=se[t]&&e<=se[t+1])return!0;return!1}var D=e=>e+` `+e,le=80,ue=function(e,t){return`M95,`+(622+e+t)+` +c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14 +c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54 +c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10 +s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429 +c69,-144,104.5,-217.7,106.5,-221 +l`+e/2.075+` -`+e+` +c5.3,-9.3,12,-14,20,-14 +H400000v`+(40+e)+`H845.2724 +s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7 +c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z +M`+(834+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},de=function(e,t){return`M263,`+(601+e+t)+`c0.7,0,18,39.7,52,119 +c34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120 +c340,-704.7,510.7,-1060.3,512,-1067 +l`+e/2.084+` -`+e+` +c4.7,-7.3,11,-11,19,-11 +H40000v`+(40+e)+`H1012.3 +s-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232 +c-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1 +s-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26 +c-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z +M`+(1001+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},fe=function(e,t){return`M983 `+(10+e+t)+` +l`+e/3.13+` -`+e+` +c4,-6.7,10,-10,18,-10 H400000v`+(40+e)+` +H1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7 +s-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744 +c-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30 +c26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722 +c56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5 +c53.7,-170.3,84.5,-266.8,92.5,-289.5z +M`+(1001+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},pe=function(e,t){return`M424,`+(2398+e+t)+` +c-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514 +c0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20 +s-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121 +s209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081 +l`+e/4.223+` -`+e+`c4,-6.7,10,-10,18,-10 H400000 +v`+(40+e)+`H1014.6 +s-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185 +c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2z M`+(1001+e)+` `+t+` +h400000v`+(40+e)+`h-400000z`},me=function(e,t){return`M473,`+(2713+e+t)+` +c339.3,-1799.3,509.3,-2700,510,-2702 l`+e/5.298+` -`+e+` +c3.3,-7.3,9.3,-11,18,-11 H400000v`+(40+e)+`H1017.7 +s-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200 +c0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26 +s76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104, +606zM`+(1001+e)+` `+t+`h400000v`+(40+e)+`H1017.7z`},he=function(e){var t=e/2;return`M400000 `+e+` H0 L`+t+` 0 l65 45 L145 `+(e-80)+` H400000z`},ge=function(e,t,n){var r=n-54-t-e;return`M702 `+(e+t)+`H400000`+(40+e)+` +H742v`+r+`l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1 +h-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170 +c-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667 +219 661 l218 661zM702 `+t+`H400000v`+(40+e)+`H742z`},_e=function(e,t,n){t=1e3*t;var r=``;switch(e){case`sqrtMain`:r=ue(t,le);break;case`sqrtSize1`:r=de(t,le);break;case`sqrtSize2`:r=fe(t,le);break;case`sqrtSize3`:r=pe(t,le);break;case`sqrtSize4`:r=me(t,le);break;case`sqrtTall`:r=ge(t,le,n)}return r},ve=function(e,t){switch(e){case`⎜`:return D(`M291 0 H417 V`+t+` H291z`);case`∣`:return D(`M145 0 H188 V`+t+` H145z`);case`∥`:return D(`M145 0 H188 V`+t+` H145z`)+D(`M367 0 H410 V`+t+` H367z`);case`⎟`:return D(`M457 0 H583 V`+t+` H457z`);case`⎢`:return D(`M319 0 H403 V`+t+` H319z`);case`⎥`:return D(`M263 0 H347 V`+t+` H263z`);case`⎪`:return D(`M384 0 H504 V`+t+` H384z`);case`⏐`:return D(`M312 0 H355 V`+t+` H312z`);case`‖`:return D(`M257 0 H300 V`+t+` H257z`)+D(`M478 0 H521 V`+t+` H478z`);default:return``}},ye={doubleleftarrow:`M262 157 +l10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3 + 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28 + 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5 +c2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5 + 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87 +-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7 +-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z +m8 0v40h399730v-40zm0 194v40h399730v-40z`,doublerightarrow:`M399738 392l +-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5 + 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88 +-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68 +-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18 +-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782 +c-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3 +-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z`,leftarrow:`M400000 241H110l3-3c68.7-52.7 113.7-120 + 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8 +-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247 +c-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208 + 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3 + 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202 + l-3-3h399890zM100 241v40h399900v-40z`,leftbrace:`M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117 +-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7 + 5-6 9-10 13-.7 1-7.3 1-20 1H6z`,leftbraceunder:`M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13 + 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688 + 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7 +-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z`,leftgroup:`M400000 80 +H435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0 + 435 0h399565z`,leftgroupunder:`M400000 262 +H435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219 + 435 219h399565z`,leftharpoon:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3 +-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5 +-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7 +-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z`,leftharpoonplus:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5 + 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3 +-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7 +-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z +m0 0v40h400000v-40z`,leftharpoondown:`M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333 + 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5 + 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667 +-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z`,leftharpoondownplus:`M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12 + 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7 +-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0 +v40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z`,lefthook:`M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5 +-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3 +-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21 + 71.5 23h399859zM103 281v-40h399897v40z`,leftlinesegment:D(`M40 281 V428 H0 V94 H40 V241 H400000 v40z`),leftbracketunder:D(`M0 0 h120 V290 H399995 v120 H0z`),leftbracketover:D(`M0 440 h120 V150 H399995 v-120 H0z`),leftmapsto:D(`M40 281 V448H0V74H40V241H400000v40z`),leftToFrom:`M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23 +-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8 +c28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3 + 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z`,longequal:D(`M0 50 h400000 v40H0z m0 194h40000v40H0z`),midbrace:`M200428 334 +c-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14 +-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7 + 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11 + 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z`,midbraceunder:`M199572 214 +c100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14 + 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3 + 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0 +-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z`,oiintSize1:`M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6 +-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z +m368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8 +60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z`,oiintSize2:`M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8 +-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z +m502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2 +c0 110 84 276 504 276s502.4-166 502.4-276z`,oiiintSize1:`M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6 +-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z +m525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0 +85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z`,oiiintSize2:`M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8 +-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z +m770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1 +c0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z`,rightarrow:`M0 241v40h399891c-47.3 35.3-84 78-110 128 +-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 + 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 + 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85 +-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 + 151.7 139 205zm0 0v40h399900v-40z`,rightbrace:`M400000 542l +-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5 +s-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1 +c124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z`,rightbraceunder:`M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3 + 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237 +-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z`,rightgroup:`M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0 + 3-1 3-3v-38c-76-158-257-219-435-219H0z`,rightgroupunder:`M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18 + 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z`,rightharpoon:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3 +-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2 +-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 + 69.2 92 94.5zm0 0v40h399900v-40z`,rightharpoonplus:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11 +-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7 + 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z +m0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z`,rightharpoondown:`M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8 + 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5 +-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95 +-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z`,rightharpoondownplus:`M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8 + 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 + 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3 +-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z +m0-194v40h400000v-40zm0 0v40h400000v-40z`,righthook:`M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3 + 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0 +-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21 + 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z`,rightlinesegment:D(`M399960 241 V94 h40 V428 h-40 V281 H0 v-40z`),rightbracketunder:D(`M399995 0 h-120 V290 H0 v120 H400000z`),rightbracketover:D(`M399995 440 h-120 V150 H0 v-120 H399995z`),rightToFrom:`M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23 + 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32 +-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142 +-167z M100 147v40h399900v-40zM0 341v40h399900v-40z`,twoheadleftarrow:`M0 167c68 40 + 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69 +-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3 +-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19 +-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101 + 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z`,twoheadrightarrow:`M400000 167 +c-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3 + 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42 + 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333 +-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70 + 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z`,tilde1:`M200 55.538c-77 0-168 73.953-177 73.953-3 0-7 +-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0 + 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0 + 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128 +-68.267.847-113-73.952-191-73.952z`,tilde2:`M344 55.266c-142 0-300.638 81.316-311.5 86.418 +-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9 + 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114 +c1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751 + 181.476 676 181.476c-149 0-189-126.21-332-126.21z`,tilde3:`M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457 +-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0 + 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697 + 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696 + -338 0-409-156.573-744-156.573z`,tilde4:`M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345 +-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409 + 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9 + 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409 + -175.236-744-175.236z`,vec:`M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5 +3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11 +10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63 +-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1 +-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59 +H213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359 +c-16-25.333-24-45-24-59z`,widehat1:`M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22 +c-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z`,widehat2:`M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat3:`M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat4:`M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widecheck1:`M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1, +-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z`,widecheck2:`M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck3:`M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck4:`M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,baraboveleftarrow:`M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202 +c4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5 +c-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130 +s-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47 +121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6 +s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11 +c0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z +M100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z`,rightarrowabovebar:`M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32 +-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0 +13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39 +-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5 +-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 +151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z`,baraboveshortleftharpoon:`M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17 +c2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21 +c-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40 +c-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z +M0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z`,rightharpoonaboveshortbar:`M0,241 l0,40c399126,0,399993,0,399993,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z`,shortbaraboveleftharpoon:`M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9, +1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7, +-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z +M93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z`,shortrightharpoonabovebar:`M53,241l0,40c398570,0,399437,0,399437,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z`},be=function(e,t){switch(e){case`lbrack`:return`M403 1759 V84 H666 V0 H319 V1759 v`+t+` v1759 v84 h347 v-84 +H403z M403 1759 V0 H319 V1759 v`+t+` v1759 v84 h84z`;case`rbrack`:return`M347 1759 V0 H0 V84 H263 V1759 v`+t+` v1759 H0 v84 H347z +M347 1759 V0 H263 V1759 v`+t+` v1759 h84z`;case`vert`:return`M145 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+` v585 h43z`;case`doublevert`:return`M145 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+` v585 h43z +M367 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M410 15 H367 v585 v`+t+` v585 h43z`;case`lfloor`:return`M319 602 V0 H403 V602 v`+t+` v1715 h263 v84 H319z +MM319 602 V0 H403 V602 v`+t+` v1715 H319z`;case`rfloor`:return`M319 602 V0 H403 V602 v`+t+` v1799 H0 v-84 H319z +MM319 602 V0 H403 V602 v`+t+` v1715 H319z`;case`lceil`:return`M403 1759 V84 H666 V0 H319 V1759 v`+t+` v602 h84z +M403 1759 V0 H319 V1759 v`+t+` v602 h84z`;case`rceil`:return`M347 1759 V0 H0 V84 H263 V1759 v`+t+` v602 h84z +M347 1759 V0 h-84 V1759 v`+t+` v602 h84z`;case`lparen`:return`M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1 +c-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349, +-36,557 l0,`+(t+84)+`c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210, +949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9 +c0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5, +-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189 +l0,-`+(t+92)+`c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3, +-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z`;case`rparen`:return`M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3, +63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5 +c11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,`+(t+9)+` +c-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664 +c-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11 +c0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17 +c242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558 +l0,-`+(t+144)+`c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7, +-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z`;default:throw Error(`Unknown stretchy delimiter.`)}};function xe(e){return`toText`in e}var Se=class{constructor(e){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=e,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(e){return this.classes.includes(e)}toNode(){for(var e=document.createDocumentFragment(),t=0;t{if(xe(e))return e.toText();throw Error(`Expected MathDomNode with toText, got `+e.constructor.name)}).join(``)}},Ce={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:803/800,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:803/800},we={ex:!0,em:!0,mu:!0},Te=function(e){return typeof e!=`string`&&(e=e.unit),e in Ce||e in we||e===`ex`},O=function(t,n){var r;if(t.unit in Ce)r=Ce[t.unit]/n.fontMetrics().ptPerEm/n.sizeMultiplier;else if(t.unit===`mu`)r=n.fontMetrics().cssEmPerMu;else{var i=n.style.isTight()?n.havingStyle(n.style.text()):n;if(t.unit===`ex`)r=i.fontMetrics().xHeight;else if(t.unit===`em`)r=i.fontMetrics().quad;else throw new e(`Invalid unit: '`+t.unit+`'`);i!==n&&(r*=i.sizeMultiplier/n.sizeMultiplier)}return Math.min(t.number*r,n.maxSize)},k=function(e){return+e.toFixed(4)+`em`},Ee=function(e){return e.filter(e=>e).join(` `)},De=function(e){var t=``;for(var r of Object.keys(e)){var i=e[r];i!==void 0&&(t+=n(r)+`:`+i+`;`)}return t},Oe=function(e,t,n){if(this.classes=e||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=n||{},t){t.style.isTight()&&this.classes.push(`mtight`);var r=t.getColor();r&&(this.style.color=r)}},ke=function(e){var t=document.createElement(e);t.className=Ee(this.classes),Object.assign(t.style,this.style);for(var n of Object.keys(this.attributes))t.setAttribute(n,this.attributes[n]);for(var r=0;r/=\x00-\x1f]/,je=function(t){var n=`<`+t;this.classes.length&&(n+=` class="`+a(Ee(this.classes))+`"`);var r=De(this.style);r&&(n+=` style="`+a(r)+`"`);for(var i of Object.keys(this.attributes)){if(Ae.test(i))throw new e(`Invalid attribute name '`+i+`'`);n+=` `+i+`="`+a(this.attributes[i])+`"`}n+=`>`;for(var o=0;o`,n},Me=class{constructor(e,t,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,this.italic=void 0,Oe.call(this,e,n,r),this.children=t||[]}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return this.classes.includes(e)}toNode(){return ke.call(this,`span`)}toMarkup(){return je.call(this,`span`)}},Ne=class{constructor(e,t,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,Oe.call(this,t,r),this.children=n||[],this.setAttribute(`href`,e)}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return this.classes.includes(e)}toNode(){return ke.call(this,`a`)}toMarkup(){return je.call(this,`a`)}},Pe=class{constructor(e,t,n){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=t,this.src=e,this.classes=[`mord`],this.height=0,this.depth=0,this.maxFontSize=0,this.style=n}hasClass(e){return this.classes.includes(e)}toNode(){var e=document.createElement(`img`);return e.src=this.src,e.alt=this.alt,e.className=`mord`,Object.assign(e.style,this.style),e}toMarkup(){var e=``+a(this.alt)+``,e}},Fe={î:`ı̂`,ï:`ı̈`,í:`ı́`,ì:`ı̀`},Ie=class{constructor(e,t,n,r,i,a,o,s){this.text=void 0,this.height=void 0,this.depth=void 0,this.italic=void 0,this.skew=void 0,this.width=void 0,this.maxFontSize=void 0,this.classes=void 0,this.style=void 0,this.text=e,this.height=t||0,this.depth=n||0,this.italic=r||0,this.skew=i||0,this.width=a||0,this.classes=o||[],this.style=s||{},this.maxFontSize=0;var c=oe(this.text.charCodeAt(0));c&&this.classes.push(c+`_fallback`),/[îïíì]/.test(this.text)&&(this.text=Fe[this.text])}hasClass(e){return this.classes.includes(e)}toNode(){var e=document.createTextNode(this.text),t=null;return this.italic>0&&(t=document.createElement(`span`),t.style.marginRight=k(this.italic)),this.classes.length>0&&(t||=document.createElement(`span`),t.className=Ee(this.classes)),Object.keys(this.style).length>0&&(t||=document.createElement(`span`),Object.assign(t.style,this.style)),t?(t.appendChild(e),t):e}toMarkup(){var e=!1,t=`0&&(n+=`margin-right:`+k(this.italic)+`;`),n+=De(this.style),n&&(e=!0,t+=` style="`+a(n)+`"`);var r=a(this.text);return e?(t+=`>`,t+=r,t+=``,t):r}},Le=class{constructor(e,t){this.children=void 0,this.attributes=void 0,this.children=e||[],this.attributes=t||{}}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`svg`);for(var t of Object.keys(this.attributes))e.setAttribute(t,this.attributes[t]);for(var n=0;n`;for(var n=0;n`,e}},Re=class{constructor(e,t){this.pathName=void 0,this.alternate=void 0,this.pathName=e,this.alternate=t}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`path`);return this.alternate?e.setAttribute(`d`,this.alternate):e.setAttribute(`d`,ye[this.pathName]),e}toMarkup(){return this.alternate?``:``}},ze=class{constructor(e){this.attributes=void 0,this.attributes=e||{}}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`line`);for(var t of Object.keys(this.attributes))e.setAttribute(t,this.attributes[t]);return e}toMarkup(){var e=``,e}};function Be(e){if(e instanceof Ie)return e;throw Error(`Expected symbolNode but got `+String(e)+`.`)}function Ve(e){if(e instanceof Me)return e;throw Error(`Expected span but got `+String(e)+`.`)}var He=e=>e instanceof Me||e instanceof Ne||e instanceof Se,Ue={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},We={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},Ge={Å:`A`,Ð:`D`,Þ:`o`,å:`a`,ð:`d`,þ:`o`,А:`A`,Б:`B`,В:`B`,Г:`F`,Д:`A`,Е:`E`,Ж:`K`,З:`3`,И:`N`,Й:`N`,К:`K`,Л:`N`,М:`M`,Н:`H`,О:`O`,П:`N`,Р:`P`,С:`C`,Т:`T`,У:`y`,Ф:`O`,Х:`X`,Ц:`U`,Ч:`h`,Ш:`W`,Щ:`W`,Ъ:`B`,Ы:`X`,Ь:`B`,Э:`3`,Ю:`X`,Я:`R`,а:`a`,б:`b`,в:`a`,г:`r`,д:`y`,е:`e`,ж:`m`,з:`e`,и:`n`,й:`n`,к:`n`,л:`n`,м:`m`,н:`n`,о:`o`,п:`n`,р:`p`,с:`c`,т:`o`,у:`y`,ф:`b`,х:`x`,ц:`n`,ч:`n`,ш:`w`,щ:`w`,ъ:`a`,ы:`m`,ь:`a`,э:`e`,ю:`m`,я:`r`};function Ke(e,t){Ue[e]=t}function qe(e,t,n){if(!Ue[t])throw Error(`Font metrics not found for font: `+t+`.`);var r=e.charCodeAt(0),i=Ue[t][r];if(!i&&e[0]in Ge&&(r=Ge[e[0]].charCodeAt(0),i=Ue[t][r]),!i&&n===`text`&&ce(r)&&(i=Ue[t][77]),i)return{depth:i[0],height:i[1],italic:i[2],skew:i[3],width:i[4]}}var Je={};function Ye(e){var t=e>=5?0:e>=3?1:2;if(!Je[t]){var n=Je[t]={cssEmPerMu:We.quad[t]/18};for(var r in We)We.hasOwnProperty(r)&&(n[r]=We[r][t])}return Je[t]}var A={math:{},text:{}};function j(e,t,n,r,i,a){A[e][i]={font:t,group:n,replace:r},a&&r&&(A[e][r]=A[e][i])}var M=`math`,N=`text`,P=`main`,F=`ams`,I=`accent-token`,L=`bin`,Xe=`close`,Ze=`inner`,R=`mathord`,z=`op-token`,Qe=`open`,$e=`punct`,B=`rel`,et=`spacing`,V=`textord`;j(M,P,B,`≡`,`\\equiv`,!0),j(M,P,B,`≺`,`\\prec`,!0),j(M,P,B,`≻`,`\\succ`,!0),j(M,P,B,`∼`,`\\sim`,!0),j(M,P,B,`⊥`,`\\perp`),j(M,P,B,`⪯`,`\\preceq`,!0),j(M,P,B,`⪰`,`\\succeq`,!0),j(M,P,B,`≃`,`\\simeq`,!0),j(M,P,B,`∣`,`\\mid`,!0),j(M,P,B,`≪`,`\\ll`,!0),j(M,P,B,`≫`,`\\gg`,!0),j(M,P,B,`≍`,`\\asymp`,!0),j(M,P,B,`∥`,`\\parallel`),j(M,P,B,`⋈`,`\\bowtie`,!0),j(M,P,B,`⌣`,`\\smile`,!0),j(M,P,B,`⊑`,`\\sqsubseteq`,!0),j(M,P,B,`⊒`,`\\sqsupseteq`,!0),j(M,P,B,`≐`,`\\doteq`,!0),j(M,P,B,`⌢`,`\\frown`,!0),j(M,P,B,`∋`,`\\ni`,!0),j(M,P,B,`∝`,`\\propto`,!0),j(M,P,B,`⊢`,`\\vdash`,!0),j(M,P,B,`⊣`,`\\dashv`,!0),j(M,P,B,`∋`,`\\owns`),j(M,P,$e,`.`,`\\ldotp`),j(M,P,$e,`⋅`,`\\cdotp`),j(M,P,$e,`⋅`,`·`),j(N,P,V,`⋅`,`·`),j(M,P,V,`#`,`\\#`),j(N,P,V,`#`,`\\#`),j(M,P,V,`&`,`\\&`),j(N,P,V,`&`,`\\&`),j(M,P,V,`ℵ`,`\\aleph`,!0),j(M,P,V,`∀`,`\\forall`,!0),j(M,P,V,`ℏ`,`\\hbar`,!0),j(M,P,V,`∃`,`\\exists`,!0),j(M,P,V,`∇`,`\\nabla`,!0),j(M,P,V,`♭`,`\\flat`,!0),j(M,P,V,`ℓ`,`\\ell`,!0),j(M,P,V,`♮`,`\\natural`,!0),j(M,P,V,`♣`,`\\clubsuit`,!0),j(M,P,V,`℘`,`\\wp`,!0),j(M,P,V,`♯`,`\\sharp`,!0),j(M,P,V,`♢`,`\\diamondsuit`,!0),j(M,P,V,`ℜ`,`\\Re`,!0),j(M,P,V,`♡`,`\\heartsuit`,!0),j(M,P,V,`ℑ`,`\\Im`,!0),j(M,P,V,`♠`,`\\spadesuit`,!0),j(M,P,V,`§`,`\\S`,!0),j(N,P,V,`§`,`\\S`),j(M,P,V,`¶`,`\\P`,!0),j(N,P,V,`¶`,`\\P`),j(M,P,V,`†`,`\\dag`),j(N,P,V,`†`,`\\dag`),j(N,P,V,`†`,`\\textdagger`),j(M,P,V,`‡`,`\\ddag`),j(N,P,V,`‡`,`\\ddag`),j(N,P,V,`‡`,`\\textdaggerdbl`),j(M,P,Xe,`⎱`,`\\rmoustache`,!0),j(M,P,Qe,`⎰`,`\\lmoustache`,!0),j(M,P,Xe,`⟯`,`\\rgroup`,!0),j(M,P,Qe,`⟮`,`\\lgroup`,!0),j(M,P,L,`∓`,`\\mp`,!0),j(M,P,L,`⊖`,`\\ominus`,!0),j(M,P,L,`⊎`,`\\uplus`,!0),j(M,P,L,`⊓`,`\\sqcap`,!0),j(M,P,L,`∗`,`\\ast`),j(M,P,L,`⊔`,`\\sqcup`,!0),j(M,P,L,`◯`,`\\bigcirc`,!0),j(M,P,L,`∙`,`\\bullet`,!0),j(M,P,L,`‡`,`\\ddagger`),j(M,P,L,`≀`,`\\wr`,!0),j(M,P,L,`⨿`,`\\amalg`),j(M,P,L,`&`,`\\And`),j(M,P,B,`⟵`,`\\longleftarrow`,!0),j(M,P,B,`⇐`,`\\Leftarrow`,!0),j(M,P,B,`⟸`,`\\Longleftarrow`,!0),j(M,P,B,`⟶`,`\\longrightarrow`,!0),j(M,P,B,`⇒`,`\\Rightarrow`,!0),j(M,P,B,`⟹`,`\\Longrightarrow`,!0),j(M,P,B,`↔`,`\\leftrightarrow`,!0),j(M,P,B,`⟷`,`\\longleftrightarrow`,!0),j(M,P,B,`⇔`,`\\Leftrightarrow`,!0),j(M,P,B,`⟺`,`\\Longleftrightarrow`,!0),j(M,P,B,`↦`,`\\mapsto`,!0),j(M,P,B,`⟼`,`\\longmapsto`,!0),j(M,P,B,`↗`,`\\nearrow`,!0),j(M,P,B,`↩`,`\\hookleftarrow`,!0),j(M,P,B,`↪`,`\\hookrightarrow`,!0),j(M,P,B,`↘`,`\\searrow`,!0),j(M,P,B,`↼`,`\\leftharpoonup`,!0),j(M,P,B,`⇀`,`\\rightharpoonup`,!0),j(M,P,B,`↙`,`\\swarrow`,!0),j(M,P,B,`↽`,`\\leftharpoondown`,!0),j(M,P,B,`⇁`,`\\rightharpoondown`,!0),j(M,P,B,`↖`,`\\nwarrow`,!0),j(M,P,B,`⇌`,`\\rightleftharpoons`,!0),j(M,F,B,`≮`,`\\nless`,!0),j(M,F,B,``,`\\@nleqslant`),j(M,F,B,``,`\\@nleqq`),j(M,F,B,`⪇`,`\\lneq`,!0),j(M,F,B,`≨`,`\\lneqq`,!0),j(M,F,B,``,`\\@lvertneqq`),j(M,F,B,`⋦`,`\\lnsim`,!0),j(M,F,B,`⪉`,`\\lnapprox`,!0),j(M,F,B,`⊀`,`\\nprec`,!0),j(M,F,B,`⋠`,`\\npreceq`,!0),j(M,F,B,`⋨`,`\\precnsim`,!0),j(M,F,B,`⪹`,`\\precnapprox`,!0),j(M,F,B,`≁`,`\\nsim`,!0),j(M,F,B,``,`\\@nshortmid`),j(M,F,B,`∤`,`\\nmid`,!0),j(M,F,B,`⊬`,`\\nvdash`,!0),j(M,F,B,`⊭`,`\\nvDash`,!0),j(M,F,B,`⋪`,`\\ntriangleleft`),j(M,F,B,`⋬`,`\\ntrianglelefteq`,!0),j(M,F,B,`⊊`,`\\subsetneq`,!0),j(M,F,B,``,`\\@varsubsetneq`),j(M,F,B,`⫋`,`\\subsetneqq`,!0),j(M,F,B,``,`\\@varsubsetneqq`),j(M,F,B,`≯`,`\\ngtr`,!0),j(M,F,B,``,`\\@ngeqslant`),j(M,F,B,``,`\\@ngeqq`),j(M,F,B,`⪈`,`\\gneq`,!0),j(M,F,B,`≩`,`\\gneqq`,!0),j(M,F,B,``,`\\@gvertneqq`),j(M,F,B,`⋧`,`\\gnsim`,!0),j(M,F,B,`⪊`,`\\gnapprox`,!0),j(M,F,B,`⊁`,`\\nsucc`,!0),j(M,F,B,`⋡`,`\\nsucceq`,!0),j(M,F,B,`⋩`,`\\succnsim`,!0),j(M,F,B,`⪺`,`\\succnapprox`,!0),j(M,F,B,`≆`,`\\ncong`,!0),j(M,F,B,``,`\\@nshortparallel`),j(M,F,B,`∦`,`\\nparallel`,!0),j(M,F,B,`⊯`,`\\nVDash`,!0),j(M,F,B,`⋫`,`\\ntriangleright`),j(M,F,B,`⋭`,`\\ntrianglerighteq`,!0),j(M,F,B,``,`\\@nsupseteqq`),j(M,F,B,`⊋`,`\\supsetneq`,!0),j(M,F,B,``,`\\@varsupsetneq`),j(M,F,B,`⫌`,`\\supsetneqq`,!0),j(M,F,B,``,`\\@varsupsetneqq`),j(M,F,B,`⊮`,`\\nVdash`,!0),j(M,F,B,`⪵`,`\\precneqq`,!0),j(M,F,B,`⪶`,`\\succneqq`,!0),j(M,F,B,``,`\\@nsubseteqq`),j(M,F,L,`⊴`,`\\unlhd`),j(M,F,L,`⊵`,`\\unrhd`),j(M,F,B,`↚`,`\\nleftarrow`,!0),j(M,F,B,`↛`,`\\nrightarrow`,!0),j(M,F,B,`⇍`,`\\nLeftarrow`,!0),j(M,F,B,`⇏`,`\\nRightarrow`,!0),j(M,F,B,`↮`,`\\nleftrightarrow`,!0),j(M,F,B,`⇎`,`\\nLeftrightarrow`,!0),j(M,F,B,`△`,`\\vartriangle`),j(M,F,V,`ℏ`,`\\hslash`),j(M,F,V,`▽`,`\\triangledown`),j(M,F,V,`◊`,`\\lozenge`),j(M,F,V,`Ⓢ`,`\\circledS`),j(M,F,V,`®`,`\\circledR`),j(N,F,V,`®`,`\\circledR`),j(M,F,V,`∡`,`\\measuredangle`,!0),j(M,F,V,`∄`,`\\nexists`),j(M,F,V,`℧`,`\\mho`),j(M,F,V,`Ⅎ`,`\\Finv`,!0),j(M,F,V,`⅁`,`\\Game`,!0),j(M,F,V,`‵`,`\\backprime`),j(M,F,V,`▲`,`\\blacktriangle`),j(M,F,V,`▼`,`\\blacktriangledown`),j(M,F,V,`■`,`\\blacksquare`),j(M,F,V,`⧫`,`\\blacklozenge`),j(M,F,V,`★`,`\\bigstar`),j(M,F,V,`∢`,`\\sphericalangle`,!0),j(M,F,V,`∁`,`\\complement`,!0),j(M,F,V,`ð`,`\\eth`,!0),j(N,P,V,`ð`,`ð`),j(M,F,V,`╱`,`\\diagup`),j(M,F,V,`╲`,`\\diagdown`),j(M,F,V,`□`,`\\square`),j(M,F,V,`□`,`\\Box`),j(M,F,V,`◊`,`\\Diamond`),j(M,F,V,`¥`,`\\yen`,!0),j(N,F,V,`¥`,`\\yen`,!0),j(M,F,V,`✓`,`\\checkmark`,!0),j(N,F,V,`✓`,`\\checkmark`),j(M,F,V,`ℶ`,`\\beth`,!0),j(M,F,V,`ℸ`,`\\daleth`,!0),j(M,F,V,`ℷ`,`\\gimel`,!0),j(M,F,V,`ϝ`,`\\digamma`,!0),j(M,F,V,`ϰ`,`\\varkappa`),j(M,F,Qe,`┌`,`\\@ulcorner`,!0),j(M,F,Xe,`┐`,`\\@urcorner`,!0),j(M,F,Qe,`└`,`\\@llcorner`,!0),j(M,F,Xe,`┘`,`\\@lrcorner`,!0),j(M,F,B,`≦`,`\\leqq`,!0),j(M,F,B,`⩽`,`\\leqslant`,!0),j(M,F,B,`⪕`,`\\eqslantless`,!0),j(M,F,B,`≲`,`\\lesssim`,!0),j(M,F,B,`⪅`,`\\lessapprox`,!0),j(M,F,B,`≊`,`\\approxeq`,!0),j(M,F,L,`⋖`,`\\lessdot`),j(M,F,B,`⋘`,`\\lll`,!0),j(M,F,B,`≶`,`\\lessgtr`,!0),j(M,F,B,`⋚`,`\\lesseqgtr`,!0),j(M,F,B,`⪋`,`\\lesseqqgtr`,!0),j(M,F,B,`≑`,`\\doteqdot`),j(M,F,B,`≓`,`\\risingdotseq`,!0),j(M,F,B,`≒`,`\\fallingdotseq`,!0),j(M,F,B,`∽`,`\\backsim`,!0),j(M,F,B,`⋍`,`\\backsimeq`,!0),j(M,F,B,`⫅`,`\\subseteqq`,!0),j(M,F,B,`⋐`,`\\Subset`,!0),j(M,F,B,`⊏`,`\\sqsubset`,!0),j(M,F,B,`≼`,`\\preccurlyeq`,!0),j(M,F,B,`⋞`,`\\curlyeqprec`,!0),j(M,F,B,`≾`,`\\precsim`,!0),j(M,F,B,`⪷`,`\\precapprox`,!0),j(M,F,B,`⊲`,`\\vartriangleleft`),j(M,F,B,`⊴`,`\\trianglelefteq`),j(M,F,B,`⊨`,`\\vDash`,!0),j(M,F,B,`⊪`,`\\Vvdash`,!0),j(M,F,B,`⌣`,`\\smallsmile`),j(M,F,B,`⌢`,`\\smallfrown`),j(M,F,B,`≏`,`\\bumpeq`,!0),j(M,F,B,`≎`,`\\Bumpeq`,!0),j(M,F,B,`≧`,`\\geqq`,!0),j(M,F,B,`⩾`,`\\geqslant`,!0),j(M,F,B,`⪖`,`\\eqslantgtr`,!0),j(M,F,B,`≳`,`\\gtrsim`,!0),j(M,F,B,`⪆`,`\\gtrapprox`,!0),j(M,F,L,`⋗`,`\\gtrdot`),j(M,F,B,`⋙`,`\\ggg`,!0),j(M,F,B,`≷`,`\\gtrless`,!0),j(M,F,B,`⋛`,`\\gtreqless`,!0),j(M,F,B,`⪌`,`\\gtreqqless`,!0),j(M,F,B,`≖`,`\\eqcirc`,!0),j(M,F,B,`≗`,`\\circeq`,!0),j(M,F,B,`≜`,`\\triangleq`,!0),j(M,F,B,`∼`,`\\thicksim`),j(M,F,B,`≈`,`\\thickapprox`),j(M,F,B,`⫆`,`\\supseteqq`,!0),j(M,F,B,`⋑`,`\\Supset`,!0),j(M,F,B,`⊐`,`\\sqsupset`,!0),j(M,F,B,`≽`,`\\succcurlyeq`,!0),j(M,F,B,`⋟`,`\\curlyeqsucc`,!0),j(M,F,B,`≿`,`\\succsim`,!0),j(M,F,B,`⪸`,`\\succapprox`,!0),j(M,F,B,`⊳`,`\\vartriangleright`),j(M,F,B,`⊵`,`\\trianglerighteq`),j(M,F,B,`⊩`,`\\Vdash`,!0),j(M,F,B,`∣`,`\\shortmid`),j(M,F,B,`∥`,`\\shortparallel`),j(M,F,B,`≬`,`\\between`,!0),j(M,F,B,`⋔`,`\\pitchfork`,!0),j(M,F,B,`∝`,`\\varpropto`),j(M,F,B,`◀`,`\\blacktriangleleft`),j(M,F,B,`∴`,`\\therefore`,!0),j(M,F,B,`∍`,`\\backepsilon`),j(M,F,B,`▶`,`\\blacktriangleright`),j(M,F,B,`∵`,`\\because`,!0),j(M,F,B,`⋘`,`\\llless`),j(M,F,B,`⋙`,`\\gggtr`),j(M,F,L,`⊲`,`\\lhd`),j(M,F,L,`⊳`,`\\rhd`),j(M,F,B,`≂`,`\\eqsim`,!0),j(M,P,B,`⋈`,`\\Join`),j(M,F,B,`≑`,`\\Doteq`,!0),j(M,F,L,`∔`,`\\dotplus`,!0),j(M,F,L,`∖`,`\\smallsetminus`),j(M,F,L,`⋒`,`\\Cap`,!0),j(M,F,L,`⋓`,`\\Cup`,!0),j(M,F,L,`⩞`,`\\doublebarwedge`,!0),j(M,F,L,`⊟`,`\\boxminus`,!0),j(M,F,L,`⊞`,`\\boxplus`,!0),j(M,F,L,`⋇`,`\\divideontimes`,!0),j(M,F,L,`⋉`,`\\ltimes`,!0),j(M,F,L,`⋊`,`\\rtimes`,!0),j(M,F,L,`⋋`,`\\leftthreetimes`,!0),j(M,F,L,`⋌`,`\\rightthreetimes`,!0),j(M,F,L,`⋏`,`\\curlywedge`,!0),j(M,F,L,`⋎`,`\\curlyvee`,!0),j(M,F,L,`⊝`,`\\circleddash`,!0),j(M,F,L,`⊛`,`\\circledast`,!0),j(M,F,L,`⋅`,`\\centerdot`),j(M,F,L,`⊺`,`\\intercal`,!0),j(M,F,L,`⋒`,`\\doublecap`),j(M,F,L,`⋓`,`\\doublecup`),j(M,F,L,`⊠`,`\\boxtimes`,!0),j(M,F,B,`⇢`,`\\dashrightarrow`,!0),j(M,F,B,`⇠`,`\\dashleftarrow`,!0),j(M,F,B,`⇇`,`\\leftleftarrows`,!0),j(M,F,B,`⇆`,`\\leftrightarrows`,!0),j(M,F,B,`⇚`,`\\Lleftarrow`,!0),j(M,F,B,`↞`,`\\twoheadleftarrow`,!0),j(M,F,B,`↢`,`\\leftarrowtail`,!0),j(M,F,B,`↫`,`\\looparrowleft`,!0),j(M,F,B,`⇋`,`\\leftrightharpoons`,!0),j(M,F,B,`↶`,`\\curvearrowleft`,!0),j(M,F,B,`↺`,`\\circlearrowleft`,!0),j(M,F,B,`↰`,`\\Lsh`,!0),j(M,F,B,`⇈`,`\\upuparrows`,!0),j(M,F,B,`↿`,`\\upharpoonleft`,!0),j(M,F,B,`⇃`,`\\downharpoonleft`,!0),j(M,P,B,`⊶`,`\\origof`,!0),j(M,P,B,`⊷`,`\\imageof`,!0),j(M,F,B,`⊸`,`\\multimap`,!0),j(M,F,B,`↭`,`\\leftrightsquigarrow`,!0),j(M,F,B,`⇉`,`\\rightrightarrows`,!0),j(M,F,B,`⇄`,`\\rightleftarrows`,!0),j(M,F,B,`↠`,`\\twoheadrightarrow`,!0),j(M,F,B,`↣`,`\\rightarrowtail`,!0),j(M,F,B,`↬`,`\\looparrowright`,!0),j(M,F,B,`↷`,`\\curvearrowright`,!0),j(M,F,B,`↻`,`\\circlearrowright`,!0),j(M,F,B,`↱`,`\\Rsh`,!0),j(M,F,B,`⇊`,`\\downdownarrows`,!0),j(M,F,B,`↾`,`\\upharpoonright`,!0),j(M,F,B,`⇂`,`\\downharpoonright`,!0),j(M,F,B,`⇝`,`\\rightsquigarrow`,!0),j(M,F,B,`⇝`,`\\leadsto`),j(M,F,B,`⇛`,`\\Rrightarrow`,!0),j(M,F,B,`↾`,`\\restriction`),j(M,P,V,`‘`,"`"),j(M,P,V,`$`,`\\$`),j(N,P,V,`$`,`\\$`),j(N,P,V,`$`,`\\textdollar`),j(M,P,V,`%`,`\\%`),j(N,P,V,`%`,`\\%`),j(M,P,V,`_`,`\\_`),j(N,P,V,`_`,`\\_`),j(N,P,V,`_`,`\\textunderscore`),j(M,P,V,`∠`,`\\angle`,!0),j(M,P,V,`∞`,`\\infty`,!0),j(M,P,V,`′`,`\\prime`),j(M,P,V,`△`,`\\triangle`),j(M,P,V,`Γ`,`\\Gamma`,!0),j(M,P,V,`Δ`,`\\Delta`,!0),j(M,P,V,`Θ`,`\\Theta`,!0),j(M,P,V,`Λ`,`\\Lambda`,!0),j(M,P,V,`Ξ`,`\\Xi`,!0),j(M,P,V,`Π`,`\\Pi`,!0),j(M,P,V,`Σ`,`\\Sigma`,!0),j(M,P,V,`Υ`,`\\Upsilon`,!0),j(M,P,V,`Φ`,`\\Phi`,!0),j(M,P,V,`Ψ`,`\\Psi`,!0),j(M,P,V,`Ω`,`\\Omega`,!0),j(M,P,V,`A`,`Α`),j(M,P,V,`B`,`Β`),j(M,P,V,`E`,`Ε`),j(M,P,V,`Z`,`Ζ`),j(M,P,V,`H`,`Η`),j(M,P,V,`I`,`Ι`),j(M,P,V,`K`,`Κ`),j(M,P,V,`M`,`Μ`),j(M,P,V,`N`,`Ν`),j(M,P,V,`O`,`Ο`),j(M,P,V,`P`,`Ρ`),j(M,P,V,`T`,`Τ`),j(M,P,V,`X`,`Χ`),j(M,P,V,`¬`,`\\neg`,!0),j(M,P,V,`¬`,`\\lnot`),j(M,P,V,`⊤`,`\\top`),j(M,P,V,`⊥`,`\\bot`),j(M,P,V,`∅`,`\\emptyset`),j(M,F,V,`∅`,`\\varnothing`),j(M,P,R,`α`,`\\alpha`,!0),j(M,P,R,`β`,`\\beta`,!0),j(M,P,R,`γ`,`\\gamma`,!0),j(M,P,R,`δ`,`\\delta`,!0),j(M,P,R,`ϵ`,`\\epsilon`,!0),j(M,P,R,`ζ`,`\\zeta`,!0),j(M,P,R,`η`,`\\eta`,!0),j(M,P,R,`θ`,`\\theta`,!0),j(M,P,R,`ι`,`\\iota`,!0),j(M,P,R,`κ`,`\\kappa`,!0),j(M,P,R,`λ`,`\\lambda`,!0),j(M,P,R,`μ`,`\\mu`,!0),j(M,P,R,`ν`,`\\nu`,!0),j(M,P,R,`ξ`,`\\xi`,!0),j(M,P,R,`ο`,`\\omicron`,!0),j(M,P,R,`π`,`\\pi`,!0),j(M,P,R,`ρ`,`\\rho`,!0),j(M,P,R,`σ`,`\\sigma`,!0),j(M,P,R,`τ`,`\\tau`,!0),j(M,P,R,`υ`,`\\upsilon`,!0),j(M,P,R,`ϕ`,`\\phi`,!0),j(M,P,R,`χ`,`\\chi`,!0),j(M,P,R,`ψ`,`\\psi`,!0),j(M,P,R,`ω`,`\\omega`,!0),j(M,P,R,`ε`,`\\varepsilon`,!0),j(M,P,R,`ϑ`,`\\vartheta`,!0),j(M,P,R,`ϖ`,`\\varpi`,!0),j(M,P,R,`ϱ`,`\\varrho`,!0),j(M,P,R,`ς`,`\\varsigma`,!0),j(M,P,R,`φ`,`\\varphi`,!0),j(M,P,L,`∗`,`*`,!0),j(M,P,L,`+`,`+`),j(M,P,L,`−`,`-`,!0),j(M,P,L,`⋅`,`\\cdot`,!0),j(M,P,L,`∘`,`\\circ`,!0),j(M,P,L,`÷`,`\\div`,!0),j(M,P,L,`±`,`\\pm`,!0),j(M,P,L,`×`,`\\times`,!0),j(M,P,L,`∩`,`\\cap`,!0),j(M,P,L,`∪`,`\\cup`,!0),j(M,P,L,`∖`,`\\setminus`,!0),j(M,P,L,`∧`,`\\land`),j(M,P,L,`∨`,`\\lor`),j(M,P,L,`∧`,`\\wedge`,!0),j(M,P,L,`∨`,`\\vee`,!0),j(M,P,V,`√`,`\\surd`),j(M,P,Qe,`⟨`,`\\langle`,!0),j(M,P,Qe,`∣`,`\\lvert`),j(M,P,Qe,`∥`,`\\lVert`),j(M,P,Xe,`?`,`?`),j(M,P,Xe,`!`,`!`),j(M,P,Xe,`⟩`,`\\rangle`,!0),j(M,P,Xe,`∣`,`\\rvert`),j(M,P,Xe,`∥`,`\\rVert`),j(M,P,B,`=`,`=`),j(M,P,B,`:`,`:`),j(M,P,B,`≈`,`\\approx`,!0),j(M,P,B,`≅`,`\\cong`,!0),j(M,P,B,`≥`,`\\ge`),j(M,P,B,`≥`,`\\geq`,!0),j(M,P,B,`←`,`\\gets`),j(M,P,B,`>`,`\\gt`,!0),j(M,P,B,`∈`,`\\in`,!0),j(M,P,B,``,`\\@not`),j(M,P,B,`⊂`,`\\subset`,!0),j(M,P,B,`⊃`,`\\supset`,!0),j(M,P,B,`⊆`,`\\subseteq`,!0),j(M,P,B,`⊇`,`\\supseteq`,!0),j(M,F,B,`⊈`,`\\nsubseteq`,!0),j(M,F,B,`⊉`,`\\nsupseteq`,!0),j(M,P,B,`⊨`,`\\models`),j(M,P,B,`←`,`\\leftarrow`,!0),j(M,P,B,`≤`,`\\le`),j(M,P,B,`≤`,`\\leq`,!0),j(M,P,B,`<`,`\\lt`,!0),j(M,P,B,`→`,`\\rightarrow`,!0),j(M,P,B,`→`,`\\to`),j(M,F,B,`≱`,`\\ngeq`,!0),j(M,F,B,`≰`,`\\nleq`,!0),j(M,P,et,`\xA0`,`\\ `),j(M,P,et,`\xA0`,`\\space`),j(M,P,et,`\xA0`,`\\nobreakspace`),j(N,P,et,`\xA0`,`\\ `),j(N,P,et,`\xA0`,` `),j(N,P,et,`\xA0`,`\\space`),j(N,P,et,`\xA0`,`\\nobreakspace`),j(M,P,et,``,`\\nobreak`),j(M,P,et,``,`\\allowbreak`),j(M,P,$e,`,`,`,`),j(M,P,$e,`;`,`;`),j(M,F,L,`⊼`,`\\barwedge`,!0),j(M,F,L,`⊻`,`\\veebar`,!0),j(M,P,L,`⊙`,`\\odot`,!0),j(M,P,L,`⊕`,`\\oplus`,!0),j(M,P,L,`⊗`,`\\otimes`,!0),j(M,P,V,`∂`,`\\partial`,!0),j(M,P,L,`⊘`,`\\oslash`,!0),j(M,F,L,`⊚`,`\\circledcirc`,!0),j(M,F,L,`⊡`,`\\boxdot`,!0),j(M,P,L,`△`,`\\bigtriangleup`),j(M,P,L,`▽`,`\\bigtriangledown`),j(M,P,L,`†`,`\\dagger`),j(M,P,L,`⋄`,`\\diamond`),j(M,P,L,`⋆`,`\\star`),j(M,P,L,`◃`,`\\triangleleft`),j(M,P,L,`▹`,`\\triangleright`),j(M,P,Qe,`{`,`\\{`),j(N,P,V,`{`,`\\{`),j(N,P,V,`{`,`\\textbraceleft`),j(M,P,Xe,`}`,`\\}`),j(N,P,V,`}`,`\\}`),j(N,P,V,`}`,`\\textbraceright`),j(M,P,Qe,`{`,`\\lbrace`),j(M,P,Xe,`}`,`\\rbrace`),j(M,P,Qe,`[`,`\\lbrack`,!0),j(N,P,V,`[`,`\\lbrack`,!0),j(M,P,Xe,`]`,`\\rbrack`,!0),j(N,P,V,`]`,`\\rbrack`,!0),j(M,P,Qe,`(`,`\\lparen`,!0),j(M,P,Xe,`)`,`\\rparen`,!0),j(N,P,V,`<`,`\\textless`,!0),j(N,P,V,`>`,`\\textgreater`,!0),j(M,P,Qe,`⌊`,`\\lfloor`,!0),j(M,P,Xe,`⌋`,`\\rfloor`,!0),j(M,P,Qe,`⌈`,`\\lceil`,!0),j(M,P,Xe,`⌉`,`\\rceil`,!0),j(M,P,V,`\\`,`\\backslash`),j(M,P,V,`∣`,`|`),j(M,P,V,`∣`,`\\vert`),j(N,P,V,`|`,`\\textbar`,!0),j(M,P,V,`∥`,`\\|`),j(M,P,V,`∥`,`\\Vert`),j(N,P,V,`∥`,`\\textbardbl`),j(N,P,V,`~`,`\\textasciitilde`),j(N,P,V,`\\`,`\\textbackslash`),j(N,P,V,`^`,`\\textasciicircum`),j(M,P,B,`↑`,`\\uparrow`,!0),j(M,P,B,`⇑`,`\\Uparrow`,!0),j(M,P,B,`↓`,`\\downarrow`,!0),j(M,P,B,`⇓`,`\\Downarrow`,!0),j(M,P,B,`↕`,`\\updownarrow`,!0),j(M,P,B,`⇕`,`\\Updownarrow`,!0),j(M,P,z,`∐`,`\\coprod`),j(M,P,z,`⋁`,`\\bigvee`),j(M,P,z,`⋀`,`\\bigwedge`),j(M,P,z,`⨄`,`\\biguplus`),j(M,P,z,`⋂`,`\\bigcap`),j(M,P,z,`⋃`,`\\bigcup`),j(M,P,z,`∫`,`\\int`),j(M,P,z,`∫`,`\\intop`),j(M,P,z,`∬`,`\\iint`),j(M,P,z,`∭`,`\\iiint`),j(M,P,z,`∏`,`\\prod`),j(M,P,z,`∑`,`\\sum`),j(M,P,z,`⨂`,`\\bigotimes`),j(M,P,z,`⨁`,`\\bigoplus`),j(M,P,z,`⨀`,`\\bigodot`),j(M,P,z,`∮`,`\\oint`),j(M,P,z,`∯`,`\\oiint`),j(M,P,z,`∰`,`\\oiiint`),j(M,P,z,`⨆`,`\\bigsqcup`),j(M,P,z,`∫`,`\\smallint`),j(N,P,Ze,`…`,`\\textellipsis`),j(M,P,Ze,`…`,`\\mathellipsis`),j(N,P,Ze,`…`,`\\ldots`,!0),j(M,P,Ze,`…`,`\\ldots`,!0),j(M,P,Ze,`⋯`,`\\@cdots`,!0),j(M,P,Ze,`⋱`,`\\ddots`,!0),j(M,P,V,`⋮`,`\\varvdots`),j(N,P,V,`⋮`,`\\varvdots`),j(M,P,I,`ˊ`,`\\acute`),j(M,P,I,`ˋ`,`\\grave`),j(M,P,I,`¨`,`\\ddot`),j(M,P,I,`~`,`\\tilde`),j(M,P,I,`ˉ`,`\\bar`),j(M,P,I,`˘`,`\\breve`),j(M,P,I,`ˇ`,`\\check`),j(M,P,I,`^`,`\\hat`),j(M,P,I,`⃗`,`\\vec`),j(M,P,I,`˙`,`\\dot`),j(M,P,I,`˚`,`\\mathring`),j(M,P,R,``,`\\@imath`),j(M,P,R,``,`\\@jmath`),j(M,P,V,`ı`,`ı`),j(M,P,V,`ȷ`,`ȷ`),j(N,P,V,`ı`,`\\i`,!0),j(N,P,V,`ȷ`,`\\j`,!0),j(N,P,V,`ß`,`\\ss`,!0),j(N,P,V,`æ`,`\\ae`,!0),j(N,P,V,`œ`,`\\oe`,!0),j(N,P,V,`ø`,`\\o`,!0),j(N,P,V,`Æ`,`\\AE`,!0),j(N,P,V,`Œ`,`\\OE`,!0),j(N,P,V,`Ø`,`\\O`,!0),j(N,P,I,`ˊ`,`\\'`),j(N,P,I,`ˋ`,"\\`"),j(N,P,I,`ˆ`,`\\^`),j(N,P,I,`˜`,`\\~`),j(N,P,I,`ˉ`,`\\=`),j(N,P,I,`˘`,`\\u`),j(N,P,I,`˙`,`\\.`),j(N,P,I,`¸`,`\\c`),j(N,P,I,`˚`,`\\r`),j(N,P,I,`ˇ`,`\\v`),j(N,P,I,`¨`,`\\"`),j(N,P,I,`˝`,`\\H`),j(N,P,I,`◯`,`\\textcircled`);var tt={"--":!0,"---":!0,"``":!0,"''":!0};j(N,P,V,`–`,`--`,!0),j(N,P,V,`–`,`\\textendash`),j(N,P,V,`—`,`---`,!0),j(N,P,V,`—`,`\\textemdash`),j(N,P,V,`‘`,"`",!0),j(N,P,V,`‘`,`\\textquoteleft`),j(N,P,V,`’`,`'`,!0),j(N,P,V,`’`,`\\textquoteright`),j(N,P,V,`“`,"``",!0),j(N,P,V,`“`,`\\textquotedblleft`),j(N,P,V,`”`,`''`,!0),j(N,P,V,`”`,`\\textquotedblright`),j(M,P,V,`°`,`\\degree`,!0),j(N,P,V,`°`,`\\degree`),j(N,P,V,`°`,`\\textdegree`,!0),j(M,P,V,`£`,`\\pounds`),j(M,P,V,`£`,`\\mathsterling`,!0),j(N,P,V,`£`,`\\pounds`),j(N,P,V,`£`,`\\textsterling`,!0),j(M,F,V,`✠`,`\\maltese`),j(N,F,V,`✠`,`\\maltese`);for(var nt=`0123456789/@."`,rt=0;rt{var n=t.charCodeAt(0),r=t.charCodeAt(1),i=(n-55296)*1024+(r-56320)+65536;if(119808<=i&&i<120484)return kt[Math.floor((i-119808)/26)];if(120782<=i&&i<=120831)return At[Math.floor((i-120782)/10)];if(i===120485||i===120486)return kt[0];if(120486{if(Ee(e.classes)!==Ee(t.classes)||e.skew!==t.skew||e.maxFontSize!==t.maxFontSize||e.italic!==0&&e.hasClass(`mathnormal`))return!1;if(e.classes.length===1){var n=e.classes[0];if(n===`mbin`||n===`mord`)return!1}for(var r of Object.keys(e.style))if(e.style[r]!==t.style[r])return!1;for(var i of Object.keys(t.style))if(e.style[i]!==t.style[i])return!1;return!0},Rt=e=>{for(var t=0;tt&&(t=a.height),a.depth>n&&(n=a.depth),a.maxFontSize>r&&(r=a.maxFontSize)}e.height=t,e.depth=n,e.maxFontSize=r},W=function(e,t,n,r){var i=new Me(e,t,n,r);return zt(i),i},Bt=(e,t,n,r)=>new Me(e,t,n,r),Vt=function(e,t,n){var r=W([e],[],t);return r.height=Math.max(n||t.fontMetrics().defaultRuleThickness,t.minRuleThickness),r.style.borderBottomWidth=k(r.height),r.maxFontSize=1,r},Ht=function(e,t,n,r){var i=new Ne(e,t,n,r);return zt(i),i},Ut=function(e){var t=new Se(e);return zt(t),t},Wt=function(e,t){return e instanceof Se?W([],[e],t):e},Gt=function(e){if(e.positionType===`individualShift`){for(var t=e.children,n=[t[0]],r=-t[0].shift-t[0].elem.depth,i=r,a=1;a{var n=W([`mspace`],[],t),r=O(e,t);return n.style.marginRight=k(r),n},qt=(e,t,n)=>{var r,i;switch(e){case`amsrm`:r=`AMS`;break;case`textrm`:r=`Main`;break;case`textsf`:r=`SansSerif`;break;case`texttt`:r=`Typewriter`;break;default:r=e}return i=t===`textbf`&&n===`textit`?`BoldItalic`:t===`textbf`?`Bold`:n===`textit`?`Italic`:`Regular`,r+`-`+i},Jt={mathbf:{variant:`bold`,fontName:`Main-Bold`},mathrm:{variant:`normal`,fontName:`Main-Regular`},textit:{variant:`italic`,fontName:`Main-Italic`},mathit:{variant:`italic`,fontName:`Main-Italic`},mathnormal:{variant:`italic`,fontName:`Math-Italic`},mathsfit:{variant:`sans-serif-italic`,fontName:`SansSerif-Italic`},mathbb:{variant:`double-struck`,fontName:`AMS-Regular`},mathcal:{variant:`script`,fontName:`Caligraphic-Regular`},mathfrak:{variant:`fraktur`,fontName:`Fraktur-Regular`},mathscr:{variant:`script`,fontName:`Script-Regular`},mathsf:{variant:`sans-serif`,fontName:`SansSerif-Regular`},mathtt:{variant:`monospace`,fontName:`Typewriter-Regular`}},Yt={vec:[`vec`,.471,.714],oiintSize1:[`oiintSize1`,.957,.499],oiintSize2:[`oiintSize2`,1.472,.659],oiiintSize1:[`oiiintSize1`,1.304,.499],oiiintSize2:[`oiiintSize2`,1.98,.659]},Xt=function(e,t){var[n,r,i]=Yt[e],a=Bt([`overlay`],[new Le([new Re(n)],{width:k(r),height:k(i),style:`width:`+k(r),viewBox:`0 0 `+1e3*r+` `+1e3*i,preserveAspectRatio:`xMinYMin`})],t);return a.height=i,a.style.height=k(i),a.style.width=k(r),a},K={number:3,unit:`mu`},Zt={number:4,unit:`mu`},Qt={number:5,unit:`mu`},$t={mord:{mop:K,mbin:Zt,mrel:Qt,minner:K},mop:{mord:K,mop:K,mrel:Qt,minner:K},mbin:{mord:Zt,mop:Zt,mopen:Zt,minner:Zt},mrel:{mord:Qt,mop:Qt,mopen:Qt,minner:Qt},mopen:{},mclose:{mop:K,mbin:Zt,mrel:Qt,minner:K},mpunct:{mord:K,mop:K,mrel:Qt,mopen:K,mclose:K,mpunct:K,minner:K},minner:{mord:K,mop:K,mbin:Zt,mrel:Qt,mopen:K,mpunct:K,minner:K}},en={mord:{mop:K},mop:{mord:K,mop:K},mbin:{},mrel:{},mopen:{},mclose:{mop:K},mpunct:{},minner:{mop:K}},tn={},nn={},rn={};function q(e){for(var{type:t,names:n,props:r,handler:i,htmlBuilder:a,mathmlBuilder:o}=e,s={type:t,numArgs:r.numArgs,argTypes:r.argTypes,allowedInArgument:!!r.allowedInArgument,allowedInText:!!r.allowedInText,allowedInMath:r.allowedInMath===void 0||r.allowedInMath,numOptionalArgs:r.numOptionalArgs||0,infix:!!r.infix,primitive:!!r.primitive,handler:i},c=0;c{var n=t.classes[0],r=e.classes[0];n===`mbin`&&cn.has(r)?t.classes[0]=`mord`:r===`mbin`&&sn.has(n)&&(e.classes[0]=`mord`)},{node:u},d,f),fn(i,(e,t)=>{var n=hn(t),r=hn(e),i=n&&r?e.hasClass(`mtight`)?en[n]?.[r]:$t[n]?.[r]:null;if(i)return Kt(i,c)},{node:u},d,f),i},fn=function(e,t,n,r,i){r&&e.push(r);for(var a=0;an=>{e.splice(t+1,0,n),a++})(a)}r&&e.pop()},pn=function(e){return e instanceof Se||e instanceof Ne||e instanceof Me&&e.hasClass(`enclosing`)?e:null},mn=function(e,t){var n=pn(e);if(n){var r=n.children;if(r.length){if(t===`right`)return mn(r[r.length-1],`right`);if(t===`left`)return mn(r[0],`left`)}}return e},hn=function(e,t){return e?(t&&(e=mn(e,t)),un[e.classes[0]]||null):null},gn=function(e,t){var n=[`nulldelimiter`].concat(e.baseSizingClasses());return W(t.concat(n))},Y=function(t,n,r){if(!t)return W();if(nn[t.type]){var i=nn[t.type](t,n);if(r&&n.size!==r.size){i=W(n.sizingClasses(r),[i],n);var a=n.sizeMultiplier/r.sizeMultiplier;i.height*=a,i.depth*=a}return i}throw new e(`Got group of unknown type: '`+t.type+`'`)};function _n(e,t){var n=W([`base`],e,t),r=W([`strut`]);return r.style.height=k(n.height+n.depth),n.depth&&(r.style.verticalAlign=k(-n.depth)),n.children.unshift(r),n}function vn(e,t){var n=null;e.length===1&&e[0].type===`tag`&&(n=e[0].tag,e=e[0].body);var r=dn(e,t,`root`),i;r.length===2&&r[1].hasClass(`tag`)&&(i=r.pop());for(var a=[],o=[],s=0;s0&&(a.push(_n(o,t)),o=[]),a.push(r[s]));o.length>0&&a.push(_n(o,t));var l;n?(l=_n(dn(n,t,!0),t),l.classes=[`tag`],a.push(l)):i&&a.push(i);var u=W([`katex-html`],a);if(u.setAttribute(`aria-hidden`,`true`),l){var d=l.children[0];d.style.height=k(u.height+u.depth),u.depth&&(d.style.verticalAlign=k(-u.depth))}return u}function yn(e){return new Se(e)}var X=class{constructor(e,t,n){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=e,this.attributes={},this.children=t||[],this.classes=n||[]}setAttribute(e,t){this.attributes[e]=t}getAttribute(e){return this.attributes[e]}toNode(){var e=document.createElementNS(`http://www.w3.org/1998/Math/MathML`,this.type);for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&e.setAttribute(t,this.attributes[t]);this.classes.length>0&&(e.className=Ee(this.classes));for(var n=0;n0&&(e+=` class ="`+a(Ee(this.classes))+`"`),e+=`>`;for(var n=0;n`,e}toText(){return this.children.map(e=>e.toText()).join(``)}},bn=class{constructor(e){this.text=void 0,this.text=e}toNode(){return document.createTextNode(this.text)}toMarkup(){return a(this.toText())}toText(){return this.text}},xn=class{constructor(e){this.width=void 0,this.character=void 0,this.width=e,this.character=e>=.05555&&e<=.05556?` `:e>=.1666&&e<=.1667?` `:e>=.2222&&e<=.2223?` `:e>=.2777&&e<=.2778?`  `:e>=-.05556&&e<=-.05555?` ⁣`:e>=-.1667&&e<=-.1666?` ⁣`:e>=-.2223&&e<=-.2222?` ⁣`:e>=-.2778&&e<=-.2777?` ⁣`:null}toNode(){if(this.character)return document.createTextNode(this.character);var e=document.createElementNS(`http://www.w3.org/1998/Math/MathML`,`mspace`);return e.setAttribute(`width`,k(this.width)),e}toMarkup(){return this.character?``+this.character+``:``}toText(){return this.character?this.character:` `}},Sn=new Set([`\\imath`,`\\jmath`]),Cn=new Set([`mrow`,`mtable`]),wn=function(e,t,n){return A[t][e]&&A[t][e].replace&&e.charCodeAt(0)!==55349&&!(tt.hasOwnProperty(e)&&n&&(n.fontFamily&&n.fontFamily.slice(4,6)===`tt`||n.font&&n.font.slice(4,6)===`tt`))&&(e=A[t][e].replace),new bn(e)},Tn=function(e){return e.length===1?e[0]:new X(`mrow`,e)},En={mathit:`italic`,boldsymbol:e=>e.type===`textord`?`bold`:`bold-italic`,mathbf:`bold`,mathbb:`double-struck`,mathsfit:`sans-serif-italic`,mathfrak:`fraktur`,mathscr:`script`,mathcal:`script`,mathsf:`sans-serif`,mathtt:`monospace`},Dn=(e,t)=>{if(e.mode===`text`){if(t.fontFamily===`texttt`)return`monospace`;if(t.fontFamily===`textsf`)return t.fontShape===`textit`&&t.fontWeight===`textbf`?`sans-serif-bold-italic`:t.fontShape===`textit`?`sans-serif-italic`:t.fontWeight===`textbf`?`bold-sans-serif`:`sans-serif`;if(t.fontShape===`textit`&&t.fontWeight===`textbf`)return`bold-italic`;if(t.fontShape===`textit`)return`italic`;if(t.fontWeight===`textbf`)return`bold`}var n=t.font;if(!n||n===`mathnormal`)return null;var r=e.mode,i=En[n];if(i)return typeof i==`function`?i(e):i;var a=e.text;if(Sn.has(a))return null;if(A[r][a]){var o=A[r][a].replace;o&&(a=o)}var s=Jt[n].fontName;return qe(a,s,r)?Jt[n].variant:null};function On(e){if(!e)return!1;if(e.type===`mi`&&e.children.length===1){var t=e.children[0];return t instanceof bn&&t.text===`.`}if(e.type===`mo`&&e.children.length===1&&e.getAttribute(`separator`)===`true`&&e.getAttribute(`lspace`)===`0em`&&e.getAttribute(`rspace`)===`0em`){var n=e.children[0];return n instanceof bn&&n.text===`,`}return!1}var kn=function(e,t,n){if(e.length===1){var r=Z(e[0],t);return n&&r instanceof X&&r.type===`mo`&&(r.setAttribute(`lspace`,`0em`),r.setAttribute(`rspace`,`0em`)),[r]}for(var i=[],a,o=0;o=1&&(a.type===`mn`||On(a))){var c=s.children[0];c instanceof X&&c.type===`mn`&&(c.children=[...a.children,...c.children],i.pop())}else if(a.type===`mi`&&a.children.length===1){var l=a.children[0];if(l instanceof bn&&l.text===`̸`&&(s.type===`mo`||s.type===`mi`||s.type===`mn`)){var u=s.children[0];u instanceof bn&&u.text.length>0&&(u.text=u.text.slice(0,1)+`̸`+u.text.slice(1),i.pop())}}}i.push(s),a=s}return i},An=function(e,t,n){return Tn(kn(e,t,n))},Z=function(t,n){if(!t)return new X(`mrow`);if(rn[t.type])return rn[t.type](t,n);throw new e(`Got group of unknown type: '`+t.type+`'`)};function jn(e,t,n,r,i){var a=kn(e,n),o=a.length===1&&a[0]instanceof X&&Cn.has(a[0].type)?a[0]:new X(`mrow`,a),s=new X(`annotation`,[new bn(t)]);s.setAttribute(`encoding`,`application/x-tex`);var c=new X(`math`,[new X(`semantics`,[o,s])]);return c.setAttribute(`xmlns`,`http://www.w3.org/1998/Math/MathML`),r&&c.setAttribute(`display`,`block`),W([i?`katex`:`katex-mathml`],[c])}var Mn=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],Nn=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],Pn=function(e,t){return t.size<2?e:Mn[e-1][t.size-1]},Fn=class e{constructor(t){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=t.style,this.color=t.color,this.size=t.size||e.BASESIZE,this.textSize=t.textSize||this.size,this.phantom=!!t.phantom,this.font=t.font||``,this.fontFamily=t.fontFamily||``,this.fontWeight=t.fontWeight||``,this.fontShape=t.fontShape||``,this.sizeMultiplier=Nn[this.size-1],this.maxSize=t.maxSize,this.minRuleThickness=t.minRuleThickness,this._fontMetrics=void 0}extend(t){var n={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};return Object.assign(n,t),new e(n)}havingStyle(e){return this.style===e?this:this.extend({style:e,size:Pn(this.textSize,e)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(e){return this.size===e&&this.textSize===e?this:this.extend({style:this.style.text(),size:e,textSize:e,sizeMultiplier:Nn[e-1]})}havingBaseStyle(t){t||=this.style.text();var n=Pn(e.BASESIZE,t);return this.size===n&&this.textSize===e.BASESIZE&&this.style===t?this:this.extend({style:t,size:n})}havingBaseSizing(){var e;switch(this.style.id){case 4:case 5:e=3;break;case 6:case 7:e=1;break;default:e=6}return this.extend({style:this.style.text(),size:e})}withColor(e){return this.extend({color:e})}withPhantom(){return this.extend({phantom:!0})}withFont(e){return this.extend({font:e})}withTextFontFamily(e){return this.extend({fontFamily:e,font:``})}withTextFontWeight(e){return this.extend({fontWeight:e,font:``})}withTextFontShape(e){return this.extend({fontShape:e,font:``})}sizingClasses(e){return e.size===this.size?[]:[`sizing`,`reset-size`+e.size,`size`+this.size]}baseSizingClasses(){return this.size===e.BASESIZE?[]:[`sizing`,`reset-size`+this.size,`size`+e.BASESIZE]}fontMetrics(){return this._fontMetrics||=Ye(this.size),this._fontMetrics}getColor(){return this.phantom?`transparent`:this.color}};Fn.BASESIZE=6;var In=function(e){return new Fn({style:e.displayMode?E.DISPLAY:E.TEXT,maxSize:e.maxSize,minRuleThickness:e.minRuleThickness})},Ln=function(e,t){if(t.displayMode){var n=[`katex-display`];t.leqno&&n.push(`leqno`),t.fleqn&&n.push(`fleqn`),e=W(n,[e])}return e},Rn=function(e,t,n){var r=In(n),i;return n.output===`mathml`?jn(e,t,r,n.displayMode,!0):(i=n.output===`html`?W([`katex`],[vn(e,r)]):W([`katex`],[jn(e,t,r,n.displayMode,!1),vn(e,r)]),Ln(i,n))},zn=function(e,t,n){return Ln(W([`katex`],[vn(e,In(n))]),n)},Bn={widehat:`^`,widecheck:`ˇ`,widetilde:`~`,utilde:`~`,overleftarrow:`←`,underleftarrow:`←`,xleftarrow:`←`,overrightarrow:`→`,underrightarrow:`→`,xrightarrow:`→`,underbrace:`⏟`,overbrace:`⏞`,underbracket:`⎵`,overbracket:`⎴`,overgroup:`⏠`,undergroup:`⏡`,overleftrightarrow:`↔`,underleftrightarrow:`↔`,xleftrightarrow:`↔`,Overrightarrow:`⇒`,xRightarrow:`⇒`,overleftharpoon:`↼`,xleftharpoonup:`↼`,overrightharpoon:`⇀`,xrightharpoonup:`⇀`,xLeftarrow:`⇐`,xLeftrightarrow:`⇔`,xhookleftarrow:`↩`,xhookrightarrow:`↪`,xmapsto:`↦`,xrightharpoondown:`⇁`,xleftharpoondown:`↽`,xrightleftharpoons:`⇌`,xleftrightharpoons:`⇋`,xtwoheadleftarrow:`↞`,xtwoheadrightarrow:`↠`,xlongequal:`=`,xtofrom:`⇄`,xrightleftarrows:`⇄`,xrightequilibrium:`⇌`,xleftequilibrium:`⇋`,"\\cdrightarrow":`→`,"\\cdleftarrow":`←`,"\\cdlongequal":`=`},Vn=function(e){var t=new X(`mo`,[new bn(Bn[e.replace(/^\\/,``)])]);return t.setAttribute(`stretchy`,`true`),t},Hn={overrightarrow:[[`rightarrow`],.888,522,`xMaxYMin`],overleftarrow:[[`leftarrow`],.888,522,`xMinYMin`],underrightarrow:[[`rightarrow`],.888,522,`xMaxYMin`],underleftarrow:[[`leftarrow`],.888,522,`xMinYMin`],xrightarrow:[[`rightarrow`],1.469,522,`xMaxYMin`],"\\cdrightarrow":[[`rightarrow`],3,522,`xMaxYMin`],xleftarrow:[[`leftarrow`],1.469,522,`xMinYMin`],"\\cdleftarrow":[[`leftarrow`],3,522,`xMinYMin`],Overrightarrow:[[`doublerightarrow`],.888,560,`xMaxYMin`],xRightarrow:[[`doublerightarrow`],1.526,560,`xMaxYMin`],xLeftarrow:[[`doubleleftarrow`],1.526,560,`xMinYMin`],overleftharpoon:[[`leftharpoon`],.888,522,`xMinYMin`],xleftharpoonup:[[`leftharpoon`],.888,522,`xMinYMin`],xleftharpoondown:[[`leftharpoondown`],.888,522,`xMinYMin`],overrightharpoon:[[`rightharpoon`],.888,522,`xMaxYMin`],xrightharpoonup:[[`rightharpoon`],.888,522,`xMaxYMin`],xrightharpoondown:[[`rightharpoondown`],.888,522,`xMaxYMin`],xlongequal:[[`longequal`],.888,334,`xMinYMin`],"\\cdlongequal":[[`longequal`],3,334,`xMinYMin`],xtwoheadleftarrow:[[`twoheadleftarrow`],.888,334,`xMinYMin`],xtwoheadrightarrow:[[`twoheadrightarrow`],.888,334,`xMaxYMin`],overleftrightarrow:[[`leftarrow`,`rightarrow`],.888,522],overbrace:[[`leftbrace`,`midbrace`,`rightbrace`],1.6,548],underbrace:[[`leftbraceunder`,`midbraceunder`,`rightbraceunder`],1.6,548],underleftrightarrow:[[`leftarrow`,`rightarrow`],.888,522],xleftrightarrow:[[`leftarrow`,`rightarrow`],1.75,522],xLeftrightarrow:[[`doubleleftarrow`,`doublerightarrow`],1.75,560],xrightleftharpoons:[[`leftharpoondownplus`,`rightharpoonplus`],1.75,716],xleftrightharpoons:[[`leftharpoonplus`,`rightharpoondownplus`],1.75,716],xhookleftarrow:[[`leftarrow`,`righthook`],1.08,522],xhookrightarrow:[[`lefthook`,`rightarrow`],1.08,522],overlinesegment:[[`leftlinesegment`,`rightlinesegment`],.888,522],underlinesegment:[[`leftlinesegment`,`rightlinesegment`],.888,522],overbracket:[[`leftbracketover`,`rightbracketover`],1.6,440],underbracket:[[`leftbracketunder`,`rightbracketunder`],1.6,410],overgroup:[[`leftgroup`,`rightgroup`],.888,342],undergroup:[[`leftgroupunder`,`rightgroupunder`],.888,342],xmapsto:[[`leftmapsto`,`rightarrow`],1.5,522],xtofrom:[[`leftToFrom`,`rightToFrom`],1.75,528],xrightleftarrows:[[`baraboveleftarrow`,`rightarrowabovebar`],1.75,901],xrightequilibrium:[[`baraboveshortleftharpoon`,`rightharpoonaboveshortbar`],1.75,716],xleftequilibrium:[[`shortbaraboveleftharpoon`,`shortrightharpoonabovebar`],1.75,716]},Un=new Set([`widehat`,`widecheck`,`widetilde`,`utilde`]),Wn=function(e,t){function n(){var n=4e5,r=e.label.slice(1);if(Un.has(r)&&`base`in e){var i=e.base.type===`ordgroup`?e.base.body.length:1,a,o,s;if(i>5)r===`widehat`||r===`widecheck`?(a=420,n=2364,s=.42,o=r+`4`):(a=312,n=2340,s=.34,o=`tilde4`);else{var c=[1,1,2,2,3,3][i];r===`widehat`||r===`widecheck`?(n=[0,1062,2364,2364,2364][c],a=[0,239,300,360,420][c],s=[0,.24,.3,.3,.36,.42][c],o=r+c):(n=[0,600,1033,2339,2340][c],a=[0,260,286,306,312][c],s=[0,.26,.286,.3,.306,.34][c],o=`tilde`+c)}return{span:Bt([],[new Le([new Re(o)],{width:`100%`,height:k(s),viewBox:`0 0 `+n+` `+a,preserveAspectRatio:`none`})],t),minWidth:0,height:s}}var l=[],u=Hn[r];if(!u)throw Error(`No SVG data for "`+r+`".`);var[d,f,p]=u,m=p/1e3,h=d.length,g,_;if(h===1){if(u.length!==4)throw Error(`Expected 4-tuple for single-path SVG data "`+r+`".`);g=[`hide-tail`],_=[u[3]]}else if(h===2)g=[`halfarrow-left`,`halfarrow-right`],_=[`xMinYMin`,`xMaxYMin`];else if(h===3)g=[`brace-left`,`brace-center`,`brace-right`],_=[`xMinYMin`,`xMidYMin`,`xMaxYMin`];else throw Error(`Correct katexImagesData or update code here to support + `+h+` children.`);for(var v=0;v0&&(r.style.minWidth=k(i)),r},Gn=function(e,t,n,r,i){var a,o=e.height+e.depth+n+r;if(/fbox|color|angl/.test(t)){if(a=W([`stretchy`,t],[],i),t===`fbox`){var s=i.color&&i.getColor();s&&(a.style.borderColor=s)}}else{var c=[];/^[bx]cancel$/.test(t)&&c.push(new ze({x1:`0`,y1:`0`,x2:`100%`,y2:`100%`,"stroke-width":`0.046em`})),/^x?cancel$/.test(t)&&c.push(new ze({x1:`0`,y1:`100%`,x2:`100%`,y2:`0`,"stroke-width":`0.046em`})),a=Bt([],[new Le(c,{width:`100%`,height:k(o)})],i)}return a.height=o,a.style.height=k(o),a},Kn={bin:1,close:1,inner:1,open:1,punct:1,rel:1},qn={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1};function Jn(e){return e in Kn}function Q(e,t){if(!e||e.type!==t)throw Error(`Expected node of type `+t+`, but got `+(e?`node of type `+e.type:String(e)));return e}function Yn(e){var t=Xn(e);if(!t)throw Error(`Expected node of symbol group type, but got `+(e?`node of type `+e.type:String(e)));return t}function Xn(e){return e&&(e.type===`atom`||qn.hasOwnProperty(e.type))?e:null}var Zn=e=>{if(e instanceof Ie)return e;if(He(e)&&e.children.length===1)return Zn(e.children[0])},Qn=(e,t)=>{var n,r,i;e&&e.type===`supsub`?(r=Q(e.base,`accent`),n=r.base,e.base=n,i=Ve(Y(e,t)),e.base=r):(r=Q(e,`accent`),n=r.base);var a=Y(n,t.havingCrampedStyle()),o=r.isShifty&&c(n),s=0;o&&(s=Zn(a)?.skew??0);var l=r.label===`\\c`,u=l?a.height+a.depth:Math.min(a.height,t.fontMetrics().xHeight),d;if(r.isStretchy)d=Wn(r,t),d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`elem`,elem:d,wrapperClasses:[`svg-align`],wrapperStyle:s>0?{width:`calc(100% - `+k(2*s)+`)`,marginLeft:k(2*s)}:void 0}]});else{var f,p;r.label===`\\vec`?(f=Xt(`vec`,t),p=Yt.vec[1]):(f=It({type:`textord`,mode:r.mode,text:r.label},t,`textord`),f=Be(f),f.italic=0,p=f.width,l&&(u+=f.depth)),d=W([`accent-body`],[f]);var m=r.label===`\\textcircled`;m&&(d.classes.push(`accent-full`),u=a.height);var h=s;m||(h-=p/2),d.style.left=k(h),r.label===`\\textcircled`&&(d.style.top=`.2em`),d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`kern`,size:-u},{type:`elem`,elem:d}]})}var g=W([`mord`,`accent`],[d],t);return i?(i.children[0]=g,i.height=Math.max(g.height,i.height),i.classes[0]=`mord`,i):g},$n=(e,t)=>{var n=e.isStretchy?Vn(e.label):new X(`mo`,[wn(e.label,e.mode)]),r=new X(`mover`,[Z(e.base,t),n]);return r.setAttribute(`accent`,`true`),r},er=new RegExp([`\\acute`,`\\grave`,`\\ddot`,`\\tilde`,`\\bar`,`\\breve`,`\\check`,`\\hat`,`\\vec`,`\\dot`,`\\mathring`].map(e=>`\\`+e).join(`|`));q({type:`accent`,names:[`\\acute`,`\\grave`,`\\ddot`,`\\tilde`,`\\bar`,`\\breve`,`\\check`,`\\hat`,`\\vec`,`\\dot`,`\\mathring`,`\\widecheck`,`\\widehat`,`\\widetilde`,`\\overrightarrow`,`\\overleftarrow`,`\\Overrightarrow`,`\\overleftrightarrow`,`\\overgroup`,`\\overlinesegment`,`\\overleftharpoon`,`\\overrightharpoon`],props:{numArgs:1},handler:(e,t)=>{var n=on(t[0]),r=!er.test(e.funcName),i=!r||e.funcName===`\\widehat`||e.funcName===`\\widetilde`||e.funcName===`\\widecheck`;return{type:`accent`,mode:e.parser.mode,label:e.funcName,isStretchy:r,isShifty:i,base:n}},htmlBuilder:Qn,mathmlBuilder:$n}),q({type:`accent`,names:[`\\'`,"\\`",`\\^`,`\\~`,`\\=`,`\\u`,`\\.`,`\\"`,`\\c`,`\\r`,`\\H`,`\\v`,`\\textcircled`],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:[`primitive`]},handler:(e,t)=>{var n=t[0],r=e.parser.mode;return r===`math`&&(e.parser.settings.reportNonstrict(`mathVsTextAccents`,`LaTeX's accent `+e.funcName+` works only in text mode`),r=`text`),{type:`accent`,mode:r,label:e.funcName,isStretchy:!1,isShifty:!0,base:n}},htmlBuilder:Qn,mathmlBuilder:$n}),q({type:`accentUnder`,names:[`\\underleftarrow`,`\\underrightarrow`,`\\underleftrightarrow`,`\\undergroup`,`\\underlinesegment`,`\\utilde`],props:{numArgs:1},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0];return{type:`accentUnder`,mode:n.mode,label:r,base:i}},htmlBuilder:(e,t)=>{var n=Y(e.base,t),r=Wn(e,t),i=e.label===`\\utilde`?.12:0;return W([`mord`,`accentunder`],[G({positionType:`top`,positionData:n.height,children:[{type:`elem`,elem:r,wrapperClasses:[`svg-align`]},{type:`kern`,size:i},{type:`elem`,elem:n}]})],t)},mathmlBuilder:(e,t)=>{var n=Vn(e.label),r=new X(`munder`,[Z(e.base,t),n]);return r.setAttribute(`accentunder`,`true`),r}});var tr=e=>{var t=new X(`mpadded`,e?[e]:[]);return t.setAttribute(`width`,`+0.6em`),t.setAttribute(`lspace`,`0.3em`),t};q({type:`xArrow`,names:[`\\xleftarrow`,`\\xrightarrow`,`\\xLeftarrow`,`\\xRightarrow`,`\\xleftrightarrow`,`\\xLeftrightarrow`,`\\xhookleftarrow`,`\\xhookrightarrow`,`\\xmapsto`,`\\xrightharpoondown`,`\\xrightharpoonup`,`\\xleftharpoondown`,`\\xleftharpoonup`,`\\xrightleftharpoons`,`\\xleftrightharpoons`,`\\xlongequal`,`\\xtwoheadrightarrow`,`\\xtwoheadleftarrow`,`\\xtofrom`,`\\xrightleftarrows`,`\\xrightequilibrium`,`\\xleftequilibrium`,`\\\\cdrightarrow`,`\\\\cdleftarrow`,`\\\\cdlongequal`],props:{numArgs:1,numOptionalArgs:1},handler(e,t,n){var{parser:r,funcName:i}=e;return{type:`xArrow`,mode:r.mode,label:i,body:t[0],below:n[0]}},htmlBuilder(e,t){var n=t.style,r=t.havingStyle(n.sup()),i=Wt(Y(e.body,r,t),t),a=e.label.slice(0,2)===`\\x`?`x`:`cd`;i.classes.push(a+`-arrow-pad`);var o;e.below&&(r=t.havingStyle(n.sub()),o=Wt(Y(e.below,r,t),t),o.classes.push(a+`-arrow-pad`));var s=Wn(e,t),c=-t.fontMetrics().axisHeight+.5*s.height,l=-t.fontMetrics().axisHeight-.5*s.height-.111;(i.depth>.25||e.label===`\\xleftequilibrium`)&&(l-=i.depth);var u;if(o){var d=-t.fontMetrics().axisHeight+o.height+.5*s.height+.111;u=G({positionType:`individualShift`,children:[{type:`elem`,elem:i,shift:l},{type:`elem`,elem:s,shift:c,wrapperClasses:[`svg-align`]},{type:`elem`,elem:o,shift:d}]})}else u=G({positionType:`individualShift`,children:[{type:`elem`,elem:i,shift:l},{type:`elem`,elem:s,shift:c,wrapperClasses:[`svg-align`]}]});return W([`mrel`,`x-arrow`],[u],t)},mathmlBuilder(e,t){var n=Vn(e.label);n.setAttribute(`minsize`,e.label.charAt(0)===`x`?`1.75em`:`3.0em`);var r;if(e.body){var i=tr(Z(e.body,t));r=e.below?new X(`munderover`,[n,tr(Z(e.below,t)),i]):new X(`mover`,[n,i])}else e.below?r=new X(`munder`,[n,tr(Z(e.below,t))]):(r=tr(),r=new X(`mover`,[n,r]));return r}});function nr(e,t){var n=dn(e.body,t,!0);return W([e.mclass],n,t)}function rr(e,t){var n,r=kn(e.body,t);return e.mclass===`minner`?n=new X(`mpadded`,r):e.mclass===`mord`?e.isCharacterBox?(n=r[0],n.type=`mi`):n=new X(`mi`,r):(e.isCharacterBox?(n=r[0],n.type=`mo`):n=new X(`mo`,r),e.mclass===`mbin`?(n.attributes.lspace=`0.22em`,n.attributes.rspace=`0.22em`):e.mclass===`mpunct`?(n.attributes.lspace=`0em`,n.attributes.rspace=`0.17em`):e.mclass===`mopen`||e.mclass===`mclose`?(n.attributes.lspace=`0em`,n.attributes.rspace=`0em`):e.mclass===`minner`&&(n.attributes.lspace=`0.0556em`,n.attributes.width=`+0.1111em`)),n}q({type:`mclass`,names:[`\\mathord`,`\\mathbin`,`\\mathrel`,`\\mathopen`,`\\mathclose`,`\\mathpunct`,`\\mathinner`],props:{numArgs:1,primitive:!0},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`mclass`,mode:n.mode,mclass:`m`+r.slice(5),body:J(i),isCharacterBox:c(i)}},htmlBuilder:nr,mathmlBuilder:rr});var ir=e=>{var t=e.type===`ordgroup`&&e.body.length?e.body[0]:e;return t.type===`atom`&&(t.family===`bin`||t.family===`rel`)?`m`+t.family:`mord`};q({type:`mclass`,names:[`\\@binrel`],props:{numArgs:2},handler(e,t){var{parser:n}=e;return{type:`mclass`,mode:n.mode,mclass:ir(t[0]),body:J(t[1]),isCharacterBox:c(t[1])}}}),q({type:`mclass`,names:[`\\stackrel`,`\\overset`,`\\underset`],props:{numArgs:2},handler(e,t){var{parser:n,funcName:r}=e,i=t[1],a=t[0],o=r===`\\stackrel`?`mrel`:ir(i),s={type:`op`,mode:i.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:r!==`\\stackrel`,body:J(i)},l={type:`supsub`,mode:a.mode,base:s,sup:r===`\\underset`?null:a,sub:r===`\\underset`?a:null};return{type:`mclass`,mode:n.mode,mclass:o,body:[l],isCharacterBox:c(l)}},htmlBuilder:nr,mathmlBuilder:rr}),q({type:`pmb`,names:[`\\pmb`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`pmb`,mode:n.mode,mclass:ir(t[0]),body:J(t[0])}},htmlBuilder(e,t){var n=dn(e.body,t,!0),r=W([e.mclass],n,t);return r.style.textShadow=`0.02em 0.01em 0.04px`,r},mathmlBuilder(e,t){var n=new X(`mstyle`,kn(e.body,t));return n.setAttribute(`style`,`text-shadow: 0.02em 0.01em 0.04px`),n}});var ar={">":`\\\\cdrightarrow`,"<":`\\\\cdleftarrow`,"=":`\\\\cdlongequal`,A:`\\uparrow`,V:`\\downarrow`,"|":`\\Vert`,".":`no arrow`},or=()=>({type:`styling`,body:[],mode:`math`,style:`display`,resetFont:!0}),sr=e=>e.type===`textord`&&e.text===`@`,cr=(e,t)=>(e.type===`mathord`||e.type===`atom`)&&e.text===t;function lr(e,t,n){var r=ar[e];switch(r){case`\\\\cdrightarrow`:case`\\\\cdleftarrow`:return n.callFunction(r,[t[0]],[t[1]]);case`\\uparrow`:case`\\downarrow`:var i=n.callFunction(`\\\\cdleft`,[t[0]],[]),a={type:`atom`,text:r,mode:`math`,family:`rel`},o={type:`ordgroup`,mode:`math`,body:[i,n.callFunction(`\\Big`,[a],[]),n.callFunction(`\\\\cdright`,[t[1]],[])]};return n.callFunction(`\\\\cdparent`,[o],[]);case`\\\\cdlongequal`:return n.callFunction(`\\\\cdlongequal`,[],[]);case`\\Vert`:return n.callFunction(`\\Big`,[{type:`textord`,text:`\\Vert`,mode:`math`}],[]);default:return{type:`textord`,text:` `,mode:`math`}}}function ur(t){var n=[];for(t.gullet.beginGroup(),t.gullet.macros.set(`\\cr`,`\\\\\\relax`),t.gullet.beginGroup();;){n.push(t.parseExpression(!1,`\\\\`)),t.gullet.endGroup(),t.gullet.beginGroup();var r=t.fetch().text;if(r===`&`||r===`\\\\`)t.consume();else if(r===`\\end`){n[n.length-1].length===0&&n.pop();break}else throw new e(`Expected \\\\ or \\cr or \\end`,t.nextToken)}for(var i=[],a=[i],o=0;oAV`.includes(u))for(var f=0;f<2;f++){for(var p=!0,m=l+1;mAV=|." after @`,s[l])}var h={type:`styling`,body:[lr(u,d,t)],mode:`math`,style:`display`,resetFont:!0};i.push(h),c=or()}o%2==0?i.push(c):i.shift(),i=[],a.push(i)}return t.gullet.endGroup(),t.gullet.endGroup(),{type:`array`,mode:`math`,body:a,arraystretch:1,addJot:!0,rowGaps:[null],cols:Array(a[0].length).fill({type:`align`,align:`c`,pregap:.25,postgap:.25}),colSeparationType:`CD`,hLinesBeforeRow:Array(a.length+1).fill([])}}q({type:`cdlabel`,names:[`\\\\cdleft`,`\\\\cdright`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e;return{type:`cdlabel`,mode:n.mode,side:r.slice(4),label:t[0]}},htmlBuilder(e,t){var n=t.havingStyle(t.style.sup()),r=Wt(Y(e.label,n,t),t);return r.classes.push(`cd-label-`+e.side),r.style.bottom=k(.8-r.depth),r.height=0,r.depth=0,r},mathmlBuilder(e,t){var n=new X(`mrow`,[Z(e.label,t)]);return n=new X(`mpadded`,[n]),n.setAttribute(`width`,`0`),e.side===`left`&&n.setAttribute(`lspace`,`-1width`),n.setAttribute(`voffset`,`0.7em`),n=new X(`mstyle`,[n]),n.setAttribute(`displaystyle`,`false`),n.setAttribute(`scriptlevel`,`1`),n}}),q({type:`cdlabelparent`,names:[`\\\\cdparent`],props:{numArgs:1},handler(e,t){var{parser:n}=e;return{type:`cdlabelparent`,mode:n.mode,fragment:t[0]}},htmlBuilder(e,t){var n=Wt(Y(e.fragment,t),t);return n.classes.push(`cd-vert-arrow`),n},mathmlBuilder(e,t){return new X(`mrow`,[Z(e.fragment,t)])}}),q({type:`textord`,names:[`\\@char`],props:{numArgs:1,allowedInText:!0},handler(t,n){for(var{parser:r}=t,i=Q(n[0],`ordgroup`).body,a=``,o=0;o=1114111)throw new e(`\\@char with invalid code point `+a);return c<=65535?l=String.fromCharCode(c):(c-=65536,l=String.fromCharCode((c>>10)+55296,(c&1023)+56320)),{type:`textord`,mode:r.mode,text:l}}});var dr=(e,t)=>Ut(dn(e.body,t.withColor(e.color),!1)),fr=(e,t)=>{var n=new X(`mstyle`,kn(e.body,t.withColor(e.color)));return n.setAttribute(`mathcolor`,e.color),n};q({type:`color`,names:[`\\textcolor`],props:{numArgs:2,allowedInText:!0,argTypes:[`color`,`original`]},handler(e,t){var{parser:n}=e,r=Q(t[0],`color-token`).color,i=t[1];return{type:`color`,mode:n.mode,color:r,body:J(i)}},htmlBuilder:dr,mathmlBuilder:fr}),q({type:`color`,names:[`\\color`],props:{numArgs:1,allowedInText:!0,argTypes:[`color`]},handler(e,t){var{parser:n,breakOnTokenText:r}=e,i=Q(t[0],`color-token`).color;n.gullet.macros.set(`\\current@color`,i);var a=n.parseExpression(!0,r);return{type:`color`,mode:n.mode,color:i,body:a}},htmlBuilder:dr,mathmlBuilder:fr}),q({type:`cr`,names:[`\\\\`],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(e,t,n){var{parser:r}=e,i=r.gullet.future().text===`[`?r.parseSizeGroup(!0):null,a=!r.settings.displayMode||!r.settings.useStrictBehavior(`newLineInDisplayMode`,`In LaTeX, \\\\ or \\newline does nothing in display mode`);return{type:`cr`,mode:r.mode,newLine:a,size:i&&Q(i,`size`).value}},htmlBuilder(e,t){var n=W([`mspace`],[],t);return e.newLine&&(n.classes.push(`newline`),e.size&&(n.style.marginTop=k(O(e.size,t)))),n},mathmlBuilder(e,t){var n=new X(`mspace`);return e.newLine&&(n.setAttribute(`linebreak`,`newline`),e.size&&n.setAttribute(`height`,k(O(e.size,t)))),n}});var pr={"\\global":`\\global`,"\\long":`\\\\globallong`,"\\\\globallong":`\\\\globallong`,"\\def":`\\gdef`,"\\gdef":`\\gdef`,"\\edef":`\\xdef`,"\\xdef":`\\xdef`,"\\let":`\\\\globallet`,"\\futurelet":`\\\\globalfuture`},mr=t=>{var n=t.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(n))throw new e(`Expected a control sequence`,t);return n},hr=e=>{var t=e.gullet.popToken();return t.text===`=`&&(t=e.gullet.popToken(),t.text===` `&&(t=e.gullet.popToken())),t},gr=(e,t,n,r)=>{var i=e.gullet.macros.get(n.text);i??=(n.noexpand=!0,{tokens:[n],numArgs:0,unexpandable:!e.gullet.isExpandable(n.text)}),e.gullet.macros.set(t,i,r)};q({type:`internal`,names:[`\\global`,`\\long`,`\\\\globallong`],props:{numArgs:0,allowedInText:!0},handler(t){var{parser:n,funcName:r}=t;n.consumeSpaces();var i=n.fetch();if(pr[i.text])return(r===`\\global`||r===`\\\\globallong`)&&(i.text=pr[i.text]),Q(n.parseFunction(),`internal`);throw new e(`Invalid token after macro prefix`,i)}}),q({type:`internal`,names:[`\\def`,`\\gdef`,`\\edef`,`\\xdef`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:n,funcName:r}=t,i=n.gullet.popToken(),a=i.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(a))throw new e(`Expected a control sequence`,i);for(var o=0,s,c=[[]];n.gullet.future().text!==`{`;)if(i=n.gullet.popToken(),i.text===`#`){if(n.gullet.future().text===`{`){s=n.gullet.future(),c[o].push(`{`);break}if(i=n.gullet.popToken(),!/^[1-9]$/.test(i.text))throw new e(`Invalid argument number "`+i.text+`"`);if(parseInt(i.text)!==o+1)throw new e(`Argument number "`+i.text+`" out of order`);o++,c.push([])}else if(i.text===`EOF`)throw new e(`Expected a macro definition`);else c[o].push(i.text);var{tokens:l}=n.gullet.consumeArg();return s&&l.unshift(s),(r===`\\edef`||r===`\\xdef`)&&(l=n.gullet.expandTokens(l),l.reverse()),n.gullet.macros.set(a,{tokens:l,numArgs:o,delimiters:c},r===pr[r]),{type:`internal`,mode:n.mode}}}),q({type:`internal`,names:[`\\let`,`\\\\globallet`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:n}=e,r=mr(t.gullet.popToken());return t.gullet.consumeSpaces(),gr(t,r,hr(t),n===`\\\\globallet`),{type:`internal`,mode:t.mode}}}),q({type:`internal`,names:[`\\futurelet`,`\\\\globalfuture`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:n}=e,r=mr(t.gullet.popToken()),i=t.gullet.popToken(),a=t.gullet.popToken();return gr(t,r,a,n===`\\\\globalfuture`),t.gullet.pushToken(a),t.gullet.pushToken(i),{type:`internal`,mode:t.mode}}});var _r=function(e,t,n){var r=qe(A.math[e]&&A.math[e].replace||e,t,n);if(!r)throw Error(`Unsupported symbol `+e+` and font size `+t+`.`);return r},vr=function(e,t,n,r){var i=n.havingBaseStyle(t),a=W(r.concat(i.sizingClasses(n)),[e],n),o=i.sizeMultiplier/n.sizeMultiplier;return a.height*=o,a.depth*=o,a.maxFontSize=i.sizeMultiplier,a},yr=function(e,t,n){var r=t.havingBaseStyle(n),i=(1-t.sizeMultiplier/r.sizeMultiplier)*t.fontMetrics().axisHeight;e.classes.push(`delimcenter`),e.style.top=k(i),e.height-=i,e.depth+=i},br=function(e,t,n,r,i,a){var o=vr(Nt(e,`Main-Regular`,i,r),t,r,a);return n&&yr(o,r,t),o},xr=function(e,t,n,r){return Nt(e,`Size`+t+`-Regular`,n,r)},Sr=function(e,t,n,r,i,a){var o=xr(e,t,i,r),s=vr(W([`delimsizing`,`size`+t],[o],r),E.TEXT,r,a);return n&&yr(s,r,E.TEXT),s},Cr=function(e,t,n){return{type:`elem`,elem:W([`delimsizinginner`,t===`Size1-Regular`?`delim-size1`:`delim-size4`],[W([],[Nt(e,t,n)])])}},wr=function(e,t,n){var r=Ue[`Size4-Regular`][e.charCodeAt(0)]?Ue[`Size4-Regular`][e.charCodeAt(0)][4]:Ue[`Size1-Regular`][e.charCodeAt(0)][4],i=Bt([],[new Le([new Re(`inner`,ve(e,Math.round(1e3*t)))],{width:k(r),height:k(t),style:`width:`+k(r),viewBox:`0 0 `+1e3*r+` `+Math.round(1e3*t),preserveAspectRatio:`xMinYMin`})],n);return i.height=t,i.style.height=k(t),i.style.width=k(r),{type:`elem`,elem:i}},Tr=.008,Er={type:`kern`,size:-1*Tr},Dr=new Set([`|`,`\\lvert`,`\\rvert`,`\\vert`]),Or=new Set([`\\|`,`\\lVert`,`\\rVert`,`\\Vert`]),kr=function(e,t,n,r,i,a){var o,s,c,l,u=``,d=0;o=c=l=e,s=null;var f=`Size1-Regular`;e===`\\uparrow`?c=l=`⏐`:e===`\\Uparrow`?c=l=`‖`:e===`\\downarrow`?o=c=`⏐`:e===`\\Downarrow`?o=c=`‖`:e===`\\updownarrow`?(o=`\\uparrow`,c=`⏐`,l=`\\downarrow`):e===`\\Updownarrow`?(o=`\\Uparrow`,c=`‖`,l=`\\Downarrow`):Dr.has(e)?(c=`∣`,u=`vert`,d=333):Or.has(e)?(c=`∥`,u=`doublevert`,d=556):e===`[`||e===`\\lbrack`?(o=`⎡`,c=`⎢`,l=`⎣`,f=`Size4-Regular`,u=`lbrack`,d=667):e===`]`||e===`\\rbrack`?(o=`⎤`,c=`⎥`,l=`⎦`,f=`Size4-Regular`,u=`rbrack`,d=667):e===`\\lfloor`||e===`⌊`?(c=o=`⎢`,l=`⎣`,f=`Size4-Regular`,u=`lfloor`,d=667):e===`\\lceil`||e===`⌈`?(o=`⎡`,c=l=`⎢`,f=`Size4-Regular`,u=`lceil`,d=667):e===`\\rfloor`||e===`⌋`?(c=o=`⎥`,l=`⎦`,f=`Size4-Regular`,u=`rfloor`,d=667):e===`\\rceil`||e===`⌉`?(o=`⎤`,c=l=`⎥`,f=`Size4-Regular`,u=`rceil`,d=667):e===`(`||e===`\\lparen`?(o=`⎛`,c=`⎜`,l=`⎝`,f=`Size4-Regular`,u=`lparen`,d=875):e===`)`||e===`\\rparen`?(o=`⎞`,c=`⎟`,l=`⎠`,f=`Size4-Regular`,u=`rparen`,d=875):e===`\\{`||e===`\\lbrace`?(o=`⎧`,s=`⎨`,l=`⎩`,c=`⎪`,f=`Size4-Regular`):e===`\\}`||e===`\\rbrace`?(o=`⎫`,s=`⎬`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):e===`\\lgroup`||e===`⟮`?(o=`⎧`,l=`⎩`,c=`⎪`,f=`Size4-Regular`):e===`\\rgroup`||e===`⟯`?(o=`⎫`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):e===`\\lmoustache`||e===`⎰`?(o=`⎧`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):(e===`\\rmoustache`||e===`⎱`)&&(o=`⎫`,l=`⎩`,c=`⎪`,f=`Size4-Regular`);var p=_r(o,f,i),m=p.height+p.depth,h=_r(c,f,i),g=h.height+h.depth,_=_r(l,f,i),v=_.height+_.depth,y=0,b=1;if(s!==null){var x=_r(s,f,i);y=x.height+x.depth,b=2}var S=m+v+y,C=S+Math.max(0,Math.ceil((t-S)/(b*g)))*b*g,w=r.fontMetrics().axisHeight;n&&(w*=r.sizeMultiplier);var ee=C/2-w,T=[];if(u.length>0){var te=C-m-v,ne=Math.round(C*1e3),re=be(u,Math.round(te*1e3)),ie=new Re(u,re),ae=k(d/1e3),oe=k(ne/1e3),se=Bt([],[new Le([ie],{width:ae,height:oe,viewBox:`0 0 `+d+` `+ne})],r);se.height=ne/1e3,se.style.width=ae,se.style.height=oe,T.push({type:`elem`,elem:se})}else{if(T.push(Cr(l,f,i)),T.push(Er),s===null){var ce=C-m-v+2*Tr;T.push(wr(c,ce,r))}else{var D=(C-m-v-y)/2+2*Tr;T.push(wr(c,D,r)),T.push(Er),T.push(Cr(s,f,i)),T.push(Er),T.push(wr(c,D,r))}T.push(Er),T.push(Cr(o,f,i))}var le=r.havingBaseStyle(E.TEXT);return vr(W([`delimsizing`,`mult`],[G({positionType:`bottom`,positionData:ee,children:T})],le),E.TEXT,r,a)},Ar=80,jr=.08,Mr=function(e,t,n,r,i){return Bt([`hide-tail`],[new Le([new Re(e,_e(e,r,n))],{width:`400em`,height:k(t),viewBox:`0 0 400000 `+n,preserveAspectRatio:`xMinYMin slice`})],i)},Nr=function(e,t){var n=t.havingBaseSizing(),r=Ur(`\\surd`,e*n.sizeMultiplier,Vr,n),i=n.sizeMultiplier,a=Math.max(0,t.minRuleThickness-t.fontMetrics().sqrtRuleThickness),o,s,c,l,u;return r.type===`small`?(l=1e3+1e3*a+Ar,e<1?i=1:e<1.4&&(i=.7),s=(1+a+jr)/i,c=(1+a)/i,o=Mr(`sqrtMain`,s,l,a,t),o.style.minWidth=`0.853em`,u=.833/i):r.type===`large`?(l=(1e3+Ar)*Lr[r.size],c=(Lr[r.size]+a)/i,s=(Lr[r.size]+a+jr)/i,o=Mr(`sqrtSize`+r.size,s,l,a,t),o.style.minWidth=`1.02em`,u=1/i):(s=e+a+jr,c=e+a,l=Math.floor(1e3*e+a)+Ar,o=Mr(`sqrtTall`,s,l,a,t),o.style.minWidth=`0.742em`,u=1.056),o.height=c,o.style.height=k(s),{span:o,advanceWidth:u,ruleWidth:(t.fontMetrics().sqrtRuleThickness+a)*i}},Pr=new Set([`(`,`\\lparen`,`)`,`\\rparen`,`[`,`\\lbrack`,`]`,`\\rbrack`,`\\{`,`\\lbrace`,`\\}`,`\\rbrace`,`\\lfloor`,`\\rfloor`,`⌊`,`⌋`,`\\lceil`,`\\rceil`,`⌈`,`⌉`,`\\surd`]),Fr=new Set([`\\uparrow`,`\\downarrow`,`\\updownarrow`,`\\Uparrow`,`\\Downarrow`,`\\Updownarrow`,`|`,`\\|`,`\\vert`,`\\Vert`,`\\lvert`,`\\rvert`,`\\lVert`,`\\rVert`,`\\lgroup`,`\\rgroup`,`⟮`,`⟯`,`\\lmoustache`,`\\rmoustache`,`⎰`,`⎱`]),Ir=new Set([`<`,`>`,`\\langle`,`\\rangle`,`/`,`\\backslash`,`\\lt`,`\\gt`]),Lr=[0,1.2,1.8,2.4,3],Rr=function(t,n,r,i,a){if(t===`<`||t===`\\lt`||t===`⟨`?t=`\\langle`:(t===`>`||t===`\\gt`||t===`⟩`)&&(t=`\\rangle`),Pr.has(t)||Ir.has(t))return Sr(t,n,!1,r,i,a);if(Fr.has(t))return kr(t,Lr[n],!1,r,i,a);throw new e(`Illegal delimiter: '`+t+`'`)},zr=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`large`,size:1},{type:`large`,size:2},{type:`large`,size:3},{type:`large`,size:4}],Br=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`stack`}],Vr=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`large`,size:1},{type:`large`,size:2},{type:`large`,size:3},{type:`large`,size:4},{type:`stack`}],Hr=function(e){if(e.type===`small`)return`Main-Regular`;if(e.type===`large`)return`Size`+e.size+`-Regular`;if(e.type===`stack`)return`Size4-Regular`;var t=e.type;throw Error(`Add support for delim type '`+t+`' here.`)},Ur=function(e,t,n,r){for(var i=Math.min(2,3-r.style.size);it)return a}return n[n.length-1]},Wr=function(e,t,n,r,i,a){e===`<`||e===`\\lt`||e===`⟨`?e=`\\langle`:(e===`>`||e===`\\gt`||e===`⟩`)&&(e=`\\rangle`);var o=Ir.has(e)?zr:Pr.has(e)?Vr:Br,s=Ur(e,t,o,r);return s.type===`small`?br(e,s.style,n,r,i,a):s.type===`large`?Sr(e,s.size,n,r,i,a):kr(e,t,n,r,i,a)},Gr=function(e,t,n,r,i,a){var o=r.fontMetrics().axisHeight*r.sizeMultiplier,s=901,c=5/r.fontMetrics().ptPerEm,l=Math.max(t-o,n+o);return Wr(e,Math.max(l/500*s,2*l-c),!0,r,i,a)},Kr={"\\bigl":{mclass:`mopen`,size:1},"\\Bigl":{mclass:`mopen`,size:2},"\\biggl":{mclass:`mopen`,size:3},"\\Biggl":{mclass:`mopen`,size:4},"\\bigr":{mclass:`mclose`,size:1},"\\Bigr":{mclass:`mclose`,size:2},"\\biggr":{mclass:`mclose`,size:3},"\\Biggr":{mclass:`mclose`,size:4},"\\bigm":{mclass:`mrel`,size:1},"\\Bigm":{mclass:`mrel`,size:2},"\\biggm":{mclass:`mrel`,size:3},"\\Biggm":{mclass:`mrel`,size:4},"\\big":{mclass:`mord`,size:1},"\\Big":{mclass:`mord`,size:2},"\\bigg":{mclass:`mord`,size:3},"\\Bigg":{mclass:`mord`,size:4}},qr=new Set(`(,\\lparen,),\\rparen,[,\\lbrack,],\\rbrack,\\{,\\lbrace,\\},\\rbrace,\\lfloor,\\rfloor,⌊,⌋,\\lceil,\\rceil,⌈,⌉,<,>,\\langle,⟨,\\rangle,⟩,\\lt,\\gt,\\lvert,\\rvert,\\lVert,\\rVert,\\lgroup,\\rgroup,⟮,⟯,\\lmoustache,\\rmoustache,⎰,⎱,/,\\backslash,|,\\vert,\\|,\\Vert,\\uparrow,\\Uparrow,\\downarrow,\\Downarrow,\\updownarrow,\\Updownarrow,.`.split(`,`));function Jr(e){return`isMiddle`in e}function Yr(t,n){var r=Xn(t);if(r&&qr.has(r.text))return r;throw r?new e(`Invalid delimiter '`+r.text+`' after '`+n.funcName+`'`,t):new e(`Invalid delimiter type '`+t.type+`'`,t)}q({type:`delimsizing`,names:[`\\bigl`,`\\Bigl`,`\\biggl`,`\\Biggl`,`\\bigr`,`\\Bigr`,`\\biggr`,`\\Biggr`,`\\bigm`,`\\Bigm`,`\\biggm`,`\\Biggm`,`\\big`,`\\Big`,`\\bigg`,`\\Bigg`],props:{numArgs:1,argTypes:[`primitive`]},handler:(e,t)=>{var n=Yr(t[0],e);return{type:`delimsizing`,mode:e.parser.mode,size:Kr[e.funcName].size,mclass:Kr[e.funcName].mclass,delim:n.text}},htmlBuilder:(e,t)=>e.delim===`.`?W([e.mclass]):Rr(e.delim,e.size,t,e.mode,[e.mclass]),mathmlBuilder:e=>{var t=[];e.delim!==`.`&&t.push(wn(e.delim,e.mode));var n=new X(`mo`,t);e.mclass===`mopen`||e.mclass===`mclose`?n.setAttribute(`fence`,`true`):n.setAttribute(`fence`,`false`),n.setAttribute(`stretchy`,`true`);var r=k(Lr[e.size]);return n.setAttribute(`minsize`,r),n.setAttribute(`maxsize`,r),n}});function Xr(e){if(!e.body)throw Error(`Bug: The leftright ParseNode wasn't fully parsed.`)}q({type:`leftright-right`,names:[`\\right`],props:{numArgs:1,primitive:!0},handler:(t,n)=>{var r=t.parser.gullet.macros.get(`\\current@color`);if(r&&typeof r!=`string`)throw new e(`\\current@color set to non-string in \\right`);return{type:`leftright-right`,mode:t.parser.mode,delim:Yr(n[0],t).text,color:r}}}),q({type:`leftright`,names:[`\\left`],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var n=Yr(t[0],e),r=e.parser;++r.leftrightDepth;var i=r.parseExpression(!1);--r.leftrightDepth,r.expect(`\\right`,!1);var a=Q(r.parseFunction(),`leftright-right`);return{type:`leftright`,mode:r.mode,body:i,left:n.text,right:a.delim,rightColor:a.color}},htmlBuilder:(e,t)=>{Xr(e);for(var n=dn(e.body,t,!0,[`mopen`,`mclose`]),r=0,i=0,a=!1,o=0;o{Xr(e);var n=kn(e.body,t);if(e.left!==`.`){var r=new X(`mo`,[wn(e.left,e.mode)]);r.setAttribute(`fence`,`true`),n.unshift(r)}if(e.right!==`.`){var i=new X(`mo`,[wn(e.right,e.mode)]);i.setAttribute(`fence`,`true`),e.rightColor&&i.setAttribute(`mathcolor`,e.rightColor),n.push(i)}return Tn(n)}}),q({type:`middle`,names:[`\\middle`],props:{numArgs:1,primitive:!0},handler:(t,n)=>{var r=Yr(n[0],t);if(!t.parser.leftrightDepth)throw new e(`\\middle without preceding \\left`,r);return{type:`middle`,mode:t.parser.mode,delim:r.text}},htmlBuilder:(e,t)=>{var n;return e.delim===`.`?n=gn(t,[]):(n=Rr(e.delim,1,t,e.mode,[]),n.isMiddle={delim:e.delim,options:t}),n},mathmlBuilder:(e,t)=>{var n=new X(`mo`,[e.delim===`\\vert`||e.delim===`|`?wn(`|`,`text`):wn(e.delim,e.mode)]);return n.setAttribute(`fence`,`true`),n.setAttribute(`lspace`,`0.05em`),n.setAttribute(`rspace`,`0.05em`),n}});var Zr=(e,t)=>{var n=Wt(Y(e.body,t),t),r=e.label.slice(1),i=t.sizeMultiplier,a,o,s=c(e.body);if(r===`sout`)a=W([`stretchy`,`sout`]),a.height=t.fontMetrics().defaultRuleThickness/i,o=-.5*t.fontMetrics().xHeight;else if(r===`phase`){var l=O({number:.6,unit:`pt`},t),u=O({number:.35,unit:`ex`},t),d=t.havingBaseSizing();i/=d.sizeMultiplier;var f=n.height+n.depth+l+u;n.style.paddingLeft=k(f/2+l);var p=Math.floor(1e3*f*i);a=Bt([`hide-tail`],[new Le([new Re(`phase`,he(p))],{width:`400em`,height:k(p/1e3),viewBox:`0 0 400000 `+p,preserveAspectRatio:`xMinYMin slice`})],t),a.style.height=k(f),o=n.depth+l+u}else{/cancel/.test(r)?s||n.classes.push(`cancel-pad`):r===`angl`?n.classes.push(`anglpad`):n.classes.push(`boxpad`);var m,h,g=0;/box/.test(r)?(g=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness),m=t.fontMetrics().fboxsep+(r===`colorbox`?0:g),h=m):r===`angl`?(g=Math.max(t.fontMetrics().defaultRuleThickness,t.minRuleThickness),m=4*g,h=Math.max(0,.25-n.depth)):(m=s?.2:0,h=m),a=Gn(n,r,m,h,t),/fbox|boxed|fcolorbox/.test(r)?(a.style.borderStyle=`solid`,a.style.borderWidth=k(g)):r===`angl`&&g!==.049&&(a.style.borderTopWidth=k(g),a.style.borderRightWidth=k(g)),o=n.depth+h,e.backgroundColor&&(a.style.backgroundColor=e.backgroundColor,e.borderColor&&(a.style.borderColor=e.borderColor))}var _;if(e.backgroundColor)_=G({positionType:`individualShift`,children:[{type:`elem`,elem:a,shift:o},{type:`elem`,elem:n,shift:0}]});else{var v=/cancel|phase/.test(r)?[`svg-align`]:[];_=G({positionType:`individualShift`,children:[{type:`elem`,elem:n,shift:0},{type:`elem`,elem:a,shift:o,wrapperClasses:v}]})}return/cancel/.test(r)&&(_.height=n.height,_.depth=n.depth),/cancel/.test(r)&&!s?W([`mord`,`cancel-lap`],[_],t):W([`mord`],[_],t)},Qr=(e,t)=>{var n,r=new X(e.label.includes(`colorbox`)?`mpadded`:`menclose`,[Z(e.body,t)]);switch(e.label){case`\\cancel`:r.setAttribute(`notation`,`updiagonalstrike`);break;case`\\bcancel`:r.setAttribute(`notation`,`downdiagonalstrike`);break;case`\\phase`:r.setAttribute(`notation`,`phasorangle`);break;case`\\sout`:r.setAttribute(`notation`,`horizontalstrike`);break;case`\\fbox`:r.setAttribute(`notation`,`box`);break;case`\\angl`:r.setAttribute(`notation`,`actuarial`);break;case`\\fcolorbox`:case`\\colorbox`:if(n=t.fontMetrics().fboxsep*t.fontMetrics().ptPerEm,r.setAttribute(`width`,`+`+2*n+`pt`),r.setAttribute(`height`,`+`+2*n+`pt`),r.setAttribute(`lspace`,n+`pt`),r.setAttribute(`voffset`,n+`pt`),e.label===`\\fcolorbox`){var i=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness);r.setAttribute(`style`,`border: `+k(i)+` solid `+e.borderColor)}break;case`\\xcancel`:r.setAttribute(`notation`,`updiagonalstrike downdiagonalstrike`)}return e.backgroundColor&&r.setAttribute(`mathbackground`,e.backgroundColor),r};q({type:`enclose`,names:[`\\colorbox`],props:{numArgs:2,allowedInText:!0,argTypes:[`color`,`hbox`]},handler(e,t,n){var{parser:r,funcName:i}=e,a=Q(t[0],`color-token`).color,o=t[1];return{type:`enclose`,mode:r.mode,label:i,backgroundColor:a,body:o}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\fcolorbox`],props:{numArgs:3,allowedInText:!0,argTypes:[`color`,`color`,`hbox`]},handler(e,t,n){var{parser:r,funcName:i}=e,a=Q(t[0],`color-token`).color,o=Q(t[1],`color-token`).color,s=t[2];return{type:`enclose`,mode:r.mode,label:i,backgroundColor:o,borderColor:a,body:s}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\fbox`],props:{numArgs:1,argTypes:[`hbox`],allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`enclose`,mode:n.mode,label:`\\fbox`,body:t[0]}}}),q({type:`enclose`,names:[`\\cancel`,`\\bcancel`,`\\xcancel`,`\\phase`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`enclose`,mode:n.mode,label:r,body:i}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\sout`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e;n.mode===`math`&&n.settings.reportNonstrict(`mathVsSout`,`LaTeX's \\sout works only in text mode`);var i=t[0];return{type:`enclose`,mode:n.mode,label:r,body:i}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\angl`],props:{numArgs:1,argTypes:[`hbox`],allowedInText:!1},handler(e,t){var{parser:n}=e;return{type:`enclose`,mode:n.mode,label:`\\angl`,body:t[0]}}});var $r={};function ei(e){for(var{type:t,names:n,props:r,handler:i,htmlBuilder:a,mathmlBuilder:o}=e,s={type:t,numArgs:r.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:i},c=0;c{if(!t.parser.settings.displayMode)throw new e(`{`+t.envName+`} can be used only in display mode.`)},oi=new Set([`gather`,`gather*`]);function si(e){if(!e.includes(`ed`))return!e.includes(`*`)}function ci(t,n,r){var{hskipBeforeAndAfter:i,addJot:a,cols:o,arraystretch:s,colSeparationType:c,autoTag:l,singleRow:u,emptySingleRow:d,maxNumCols:f,leqno:p}=n;if(t.gullet.beginGroup(),u||t.gullet.macros.set(`\\cr`,`\\\\\\relax`),!s){var m=t.gullet.expandMacroAsText(`\\arraystretch`);if(m==null)s=1;else if(s=parseFloat(m),!s||s<0)throw new e(`Invalid \\arraystretch: `+m)}t.gullet.beginGroup();var h=[],g=[h],_=[],v=[],y=l==null?void 0:[];function b(){l&&t.gullet.macros.set(`\\@eqnsw`,`1`,!0)}function x(){y&&(t.gullet.macros.get(`\\df@tag`)?(y.push(t.subparse([new ri(`\\df@tag`)])),t.gullet.macros.set(`\\df@tag`,void 0,!0)):y.push(!!l&&t.gullet.macros.get(`\\@eqnsw`)===`1`))}for(b(),v.push(ii(t));;){var S=t.parseExpression(!1,u?`\\end`:`\\\\`);t.gullet.endGroup(),t.gullet.beginGroup();var C={type:`ordgroup`,mode:t.mode,body:S};r&&(C={type:`styling`,mode:t.mode,style:r,resetFont:!0,body:[C]}),h.push(C);var w=t.fetch().text;if(w===`&`){if(f&&h.length===f){if(u||c)throw new e(`Too many tab characters: &`,t.nextToken);t.settings.reportNonstrict(`textEnv`,`Too few columns specified in the {array} column argument.`)}t.consume()}else if(w===`\\end`){x(),h.length===1&&C.type===`styling`&&C.body.length===1&&C.body[0].type===`ordgroup`&&C.body[0].body.length===0&&(g.length>1||!d)&&g.pop(),v.length0&&(v+=.25),l.push({pos:v,isDashed:e[t]})}for(y(o[0]),r=0;r0&&(T+=_,Se))for(r=0;r=s)){var ge=void 0;(i>0||t.hskipBeforeAndAfter)&&(ge=ue?.pregap??f,ge!==0&&(ie=W([`arraycolsep`],[]),ie.style.width=k(ge),re.push(ie)));var _e=[];for(r=0;r0){for(var we=Vt(`hline`,n,u),Te=Vt(`hdashline`,n,u),Ee=[{type:`elem`,elem:Ce,shift:0}];l.length>0;){var De=l.pop(),Oe=De.pos-te;De.isDashed?Ee.push({type:`elem`,elem:Te,shift:Oe}):Ee.push({type:`elem`,elem:we,shift:Oe})}Ce=G({positionType:`individualShift`,children:Ee})}if(oe.length===0)return W([`mord`],[Ce],n);var ke=W([`tag`],[G({positionType:`individualShift`,children:oe})],n);return Ut([Ce,ke])},di={c:`center `,l:`left `,r:`right `},fi=function(e,t){for(var n=[],r=new X(`mtd`,[],[`mtr-glue`]),i=new X(`mtd`,[],[`mml-eqn-num`]),a=0;a0){var p=e.cols,m=``,h=!1,g=0,_=p.length;p[0].type===`separator`&&(d+=`top `,g=1),p[p.length-1].type===`separator`&&(d+=`bottom `,--_);for(var v=g;v<_;v++){var y=p[v];y.type===`align`?(f+=di[y.align],h&&(m+=`none `),h=!0):y.type===`separator`&&(h&&=(m+=y.separator===`|`?`solid `:`dashed `,!1))}l.setAttribute(`columnalign`,f.trim()),/[sd]/.test(m)&&l.setAttribute(`columnlines`,m.trim())}if(e.colSeparationType===`align`){for(var b=e.cols||[],x=``,S=1;S0?`left `:``,d+=w[w.length-1].length>0?`right `:``;for(var ee=1;ee0&&p&&(g=1),r[m]={type:`align`,align:h,pregap:g,postgap:0}}return o.colSeparationType=p?`align`:`alignat`,o};ei({type:`array`,names:[`array`,`darray`],props:{numArgs:1},handler(t,n){var r=(Xn(n[0])?[n[0]]:Q(n[0],`ordgroup`).body).map(function(t){var n=Yn(t).text;if(`lcr`.includes(n))return{type:`align`,align:n};if(n===`|`)return{type:`separator`,separator:`|`};if(n===`:`)return{type:`separator`,separator:`:`};throw new e(`Unknown column alignment: `+n,t)}),i={cols:r,hskipBeforeAndAfter:!0,maxNumCols:r.length};return ci(t.parser,i,li(t.envName))},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`matrix`,`pmatrix`,`bmatrix`,`Bmatrix`,`vmatrix`,`Vmatrix`,`matrix*`,`pmatrix*`,`bmatrix*`,`Bmatrix*`,`vmatrix*`,`Vmatrix*`],props:{numArgs:0},handler(t){var n={matrix:null,pmatrix:[`(`,`)`],bmatrix:[`[`,`]`],Bmatrix:[`\\{`,`\\}`],vmatrix:[`|`,`|`],Vmatrix:[`\\Vert`,`\\Vert`]}[t.envName.replace(`*`,``)],r=`c`,i={hskipBeforeAndAfter:!1,cols:[{type:`align`,align:r}]};if(t.envName.charAt(t.envName.length-1)===`*`){var a=t.parser;if(a.consumeSpaces(),a.fetch().text===`[`){if(a.consume(),a.consumeSpaces(),r=a.fetch().text,!`lcr`.includes(r))throw new e(`Expected l or c or r`,a.nextToken);a.consume(),a.consumeSpaces(),a.expect(`]`),a.consume(),i.cols=[{type:`align`,align:r}]}}var o=ci(t.parser,i,li(t.envName)),s=Math.max(0,...o.body.map(e=>e.length));return o.cols=Array(s).fill({type:`align`,align:r}),n?{type:`leftright`,mode:t.mode,body:[o],left:n[0],right:n[1],rightColor:void 0}:o},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`smallmatrix`],props:{numArgs:0},handler(e){var t=ci(e.parser,{arraystretch:.5},`script`);return t.colSeparationType=`small`,t},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`subarray`],props:{numArgs:1},handler(t,n){var r=(Xn(n[0])?[n[0]]:Q(n[0],`ordgroup`).body).map(function(t){var n=Yn(t).text;if(`lc`.includes(n))return{type:`align`,align:n};throw new e(`Unknown column alignment: `+n,t)});if(r.length>1)throw new e(`{subarray} can contain only one column`);var i={cols:r,hskipBeforeAndAfter:!1,arraystretch:.5},a=ci(t.parser,i,`script`);if(a.body.length>0&&a.body[0].length>1)throw new e(`{subarray} can contain only one column`);return a},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`cases`,`dcases`,`rcases`,`drcases`],props:{numArgs:0},handler(e){var t=ci(e.parser,{arraystretch:1.2,cols:[{type:`align`,align:`l`,pregap:0,postgap:1},{type:`align`,align:`l`,pregap:0,postgap:0}]},li(e.envName));return{type:`leftright`,mode:e.mode,body:[t],left:e.envName.includes(`r`)?`.`:`\\{`,right:e.envName.includes(`r`)?`\\}`:`.`,rightColor:void 0}},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`align`,`align*`,`aligned`,`split`],props:{numArgs:0},handler:pi,htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`gathered`,`gather`,`gather*`],props:{numArgs:0},handler(e){oi.has(e.envName)&&ai(e);var t={cols:[{type:`align`,align:`c`}],addJot:!0,colSeparationType:`gather`,autoTag:si(e.envName),emptySingleRow:!0,leqno:e.parser.settings.leqno};return ci(e.parser,t,`display`)},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`alignat`,`alignat*`,`alignedat`],props:{numArgs:1},handler:pi,htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`equation`,`equation*`],props:{numArgs:0},handler(e){ai(e);var t={autoTag:si(e.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:e.parser.settings.leqno};return ci(e.parser,t,`display`)},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`CD`],props:{numArgs:0},handler(e){return ai(e),ur(e.parser)},htmlBuilder:ui,mathmlBuilder:fi}),$(`\\nonumber`,`\\gdef\\@eqnsw{0}`),$(`\\notag`,`\\nonumber`),q({type:`text`,names:[`\\hline`,`\\hdashline`],props:{numArgs:0,allowedInText:!0,allowedInMath:!0},handler(t,n){throw new e(t.funcName+` valid only within array environment`)}});var mi=$r;q({type:`environment`,names:[`\\begin`,`\\end`],props:{numArgs:1,argTypes:[`text`]},handler(t,n){var{parser:r,funcName:i}=t,a=n[0];if(a.type!==`ordgroup`)throw new e(`Invalid environment name`,a);for(var o=``,s=0;s{var n=e.font,r=t.withFont(n);return Y(e.body,r)},gi=(e,t)=>{var n=e.font,r=t.withFont(n);return Z(e.body,r)},_i={"\\Bbb":`\\mathbb`,"\\bold":`\\mathbf`,"\\frak":`\\mathfrak`};q({type:`font`,names:[`\\mathrm`,`\\mathit`,`\\mathbf`,`\\mathnormal`,`\\mathsfit`,`\\mathbb`,`\\mathcal`,`\\mathfrak`,`\\mathscr`,`\\mathsf`,`\\mathtt`,`\\Bbb`,`\\bold`,`\\frak`],props:{numArgs:1,allowedInArgument:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=on(t[0]),a=r;return a in _i&&(a=_i[a]),{type:`font`,mode:n.mode,font:a.slice(1),body:i}},htmlBuilder:hi,mathmlBuilder:gi}),q({type:`mclass`,names:[`\\boldsymbol`,`\\bm`],props:{numArgs:1},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`mclass`,mode:n.mode,mclass:ir(r),body:[{type:`font`,mode:n.mode,font:`boldsymbol`,body:r}],isCharacterBox:c(r)}}}),q({type:`font`,names:[`\\rm`,`\\sf`,`\\tt`,`\\bf`,`\\it`,`\\cal`],props:{numArgs:0,allowedInText:!0},handler:(e,t)=>{var{parser:n,funcName:r,breakOnTokenText:i}=e,{mode:a}=n,o=n.parseExpression(!0,i);return{type:`font`,mode:a,font:`math`+r.slice(1),body:{type:`ordgroup`,mode:n.mode,body:o}}},htmlBuilder:hi,mathmlBuilder:gi});var vi=(e,t)=>{var n=t.style,r=n.fracNum(),i=n.fracDen(),a=t.havingStyle(r),o=Y(e.numer,a,t);if(e.continued){var s=8.5/t.fontMetrics().ptPerEm,c=3.5/t.fontMetrics().ptPerEm;o.height=o.height0?3*f:7*f,h=t.fontMetrics().denom1):(d>0?(p=t.fontMetrics().num2,m=f):(p=t.fontMetrics().num3,m=3*f),h=t.fontMetrics().denom2);var g;if(u){var _=t.fontMetrics().axisHeight;p-o.depth-(_+.5*d){var n=new X(`mfrac`,[Z(e.numer,t),Z(e.denom,t)]);if(!e.hasBarLine)n.setAttribute(`linethickness`,`0px`);else if(e.barSize){var r=O(e.barSize,t);n.setAttribute(`linethickness`,k(r))}if(e.leftDelim!=null||e.rightDelim!=null){var i=[];if(e.leftDelim!=null){var a=new X(`mo`,[new bn(e.leftDelim.replace(`\\`,``))]);a.setAttribute(`fence`,`true`),i.push(a)}if(i.push(n),e.rightDelim!=null){var o=new X(`mo`,[new bn(e.rightDelim.replace(`\\`,``))]);o.setAttribute(`fence`,`true`),i.push(o)}return Tn(i)}return n},bi=(e,t)=>t?{type:`styling`,mode:e.mode,style:t,body:[e]}:e;q({type:`genfrac`,names:[`\\cfrac`,`\\dfrac`,`\\frac`,`\\tfrac`,`\\dbinom`,`\\binom`,`\\tbinom`,`\\\\atopfrac`,`\\\\bracefrac`,`\\\\brackfrac`],props:{numArgs:2,allowedInArgument:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0],a=t[1],o,s=null,c=null;switch(r){case`\\cfrac`:case`\\dfrac`:case`\\frac`:case`\\tfrac`:o=!0;break;case`\\\\atopfrac`:o=!1;break;case`\\dbinom`:case`\\binom`:case`\\tbinom`:o=!1,s=`(`,c=`)`;break;case`\\\\bracefrac`:o=!1,s=`\\{`,c=`\\}`;break;case`\\\\brackfrac`:o=!1,s=`[`,c=`]`;break;default:throw Error(`Unrecognized genfrac command`)}var l=r===`\\cfrac`,u=null;return l||r.startsWith(`\\d`)?u=`display`:r.startsWith(`\\t`)&&(u=`text`),bi({type:`genfrac`,mode:n.mode,numer:i,denom:a,continued:l,hasBarLine:o,leftDelim:s,rightDelim:c,barSize:null},u)},htmlBuilder:vi,mathmlBuilder:yi}),q({type:`infix`,names:[`\\over`,`\\choose`,`\\atop`,`\\brace`,`\\brack`],props:{numArgs:0,infix:!0},handler(e){var{parser:t,funcName:n,token:r}=e,i;switch(n){case`\\over`:i=`\\frac`;break;case`\\choose`:i=`\\binom`;break;case`\\atop`:i=`\\\\atopfrac`;break;case`\\brace`:i=`\\\\bracefrac`;break;case`\\brack`:i=`\\\\brackfrac`;break;default:throw Error(`Unrecognized infix genfrac command`)}return{type:`infix`,mode:t.mode,replaceWith:i,token:r}}});var xi=[`display`,`text`,`script`,`scriptscript`],Si=function(e){var t=null;return e.length>0&&(t=e,t=t===`.`?null:t),t};q({type:`genfrac`,names:[`\\genfrac`],props:{numArgs:6,allowedInArgument:!0,argTypes:[`math`,`math`,`size`,`text`,`math`,`math`]},handler(e,t){var{parser:n}=e,r=t[4],i=t[5],a=on(t[0]),o=a.type===`atom`&&a.family===`open`?Si(a.text):null,s=on(t[1]),c=s.type===`atom`&&s.family===`close`?Si(s.text):null,l=Q(t[2],`size`),u,d=null;l.isBlank?u=!0:(d=l.value,u=d.number>0);var f=null,p=t[3];if(p.type===`ordgroup`){if(p.body.length>0){var m=Q(p.body[0],`textord`);f=xi[Number(m.text)]}}else p=Q(p,`textord`),f=xi[Number(p.text)];return bi({type:`genfrac`,mode:n.mode,numer:r,denom:i,continued:!1,hasBarLine:u,barSize:d,leftDelim:o,rightDelim:c},f)}}),q({type:`infix`,names:[`\\above`],props:{numArgs:1,argTypes:[`size`],infix:!0},handler(e,t){var{parser:n,funcName:r,token:i}=e;return{type:`infix`,mode:n.mode,replaceWith:`\\\\abovefrac`,size:Q(t[0],`size`).value,token:i}}}),q({type:`genfrac`,names:[`\\\\abovefrac`],props:{numArgs:3,argTypes:[`math`,`size`,`math`]},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0],a=Q(t[1],`infix`).size;if(!a)throw Error(`\\\\abovefrac expected size, but got `+String(a));var o=t[2],s=a.number>0;return{type:`genfrac`,mode:n.mode,numer:i,denom:o,continued:!1,hasBarLine:s,barSize:a,leftDelim:null,rightDelim:null}}});var Ci=(e,t)=>{var n=t.style,r,i;e.type===`supsub`?(r=e.sup?Y(e.sup,t.havingStyle(n.sup()),t):Y(e.sub,t.havingStyle(n.sub()),t),i=Q(e.base,`horizBrace`)):i=Q(e,`horizBrace`);var a=Y(i.base,t.havingBaseStyle(E.DISPLAY)),o=Wn(i,t),s=i.isOver?G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`kern`,size:.1},{type:`elem`,elem:o,wrapperClasses:[`svg-align`]}]}):G({positionType:`bottom`,positionData:a.depth+.1+o.height,children:[{type:`elem`,elem:o,wrapperClasses:[`svg-align`]},{type:`kern`,size:.1},{type:`elem`,elem:a}]});if(r){var c=W([`minner`,i.isOver?`mover`:`munder`],[s],t);s=i.isOver?G({positionType:`firstBaseline`,children:[{type:`elem`,elem:c},{type:`kern`,size:.2},{type:`elem`,elem:r}]}):G({positionType:`bottom`,positionData:c.depth+.2+r.height+r.depth,children:[{type:`elem`,elem:r},{type:`kern`,size:.2},{type:`elem`,elem:c}]})}return W([`minner`,i.isOver?`mover`:`munder`],[s],t)};q({type:`horizBrace`,names:[`\\overbrace`,`\\underbrace`,`\\overbracket`,`\\underbracket`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e;return{type:`horizBrace`,mode:n.mode,label:r,isOver:r.includes(`\\over`),base:t[0]}},htmlBuilder:Ci,mathmlBuilder:(e,t)=>{var n=Vn(e.label);return new X(e.isOver?`mover`:`munder`,[Z(e.base,t),n])}}),q({type:`href`,names:[`\\href`],props:{numArgs:2,argTypes:[`url`,`original`],allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[1],i=Q(t[0],`url`).url;return n.settings.isTrusted({command:`\\href`,url:i})?{type:`href`,mode:n.mode,href:i,body:J(r)}:n.formatUnsupportedCmd(`\\href`)},htmlBuilder:(e,t)=>{var n=dn(e.body,t,!1);return Ht(e.href,[],n,t)},mathmlBuilder:(e,t)=>{var n=An(e.body,t);return n instanceof X||(n=new X(`mrow`,[n])),n.setAttribute(`href`,e.href),n}}),q({type:`href`,names:[`\\url`],props:{numArgs:1,argTypes:[`url`],allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=Q(t[0],`url`).url;if(!n.settings.isTrusted({command:`\\url`,url:r}))return n.formatUnsupportedCmd(`\\url`);for(var i=[],a=0;a{var{parser:r,funcName:i,token:a}=t,o=Q(n[0],`raw`).string,s=n[1];r.settings.strict&&r.settings.reportNonstrict(`htmlExtension`,`HTML extension is disabled on strict mode`);var c,l={};switch(i){case`\\htmlClass`:l.class=o,c={command:`\\htmlClass`,class:o};break;case`\\htmlId`:l.id=o,c={command:`\\htmlId`,id:o};break;case`\\htmlStyle`:l.style=o,c={command:`\\htmlStyle`,style:o};break;case`\\htmlData`:for(var u=o.split(`,`),d=0;d{var n=dn(e.body,t,!1),r=[`enclosing`];e.attributes.class&&r.push(...e.attributes.class.trim().split(/\s+/));var i=W(r,n,t);for(var a in e.attributes)a!==`class`&&e.attributes.hasOwnProperty(a)&&i.setAttribute(a,e.attributes[a]);return i},mathmlBuilder:(e,t)=>An(e.body,t)}),q({type:`htmlmathml`,names:[`\\html@mathml`],props:{numArgs:2,allowedInArgument:!0,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e;return{type:`htmlmathml`,mode:n.mode,html:J(t[0]),mathml:J(t[1])}},htmlBuilder:(e,t)=>Ut(dn(e.html,t,!1)),mathmlBuilder:(e,t)=>An(e.mathml,t)});var wi=function(t){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(t))return{number:+t,unit:`bp`};var n=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(t);if(!n)throw new e(`Invalid size: '`+t+`' in \\includegraphics`);var r={number:+(n[1]+n[2]),unit:n[3]};if(!Te(r))throw new e(`Invalid unit: '`+r.unit+`' in \\includegraphics.`);return r};q({type:`includegraphics`,names:[`\\includegraphics`],props:{numArgs:1,numOptionalArgs:1,argTypes:[`raw`,`url`],allowedInText:!1},handler:(t,n,r)=>{var{parser:i}=t,a={number:0,unit:`em`},o={number:.9,unit:`em`},s={number:0,unit:`em`},c=``;if(r[0])for(var l=Q(r[0],`raw`).string.split(`,`),u=0;u{var n=O(e.height,t),r=0;e.totalheight.number>0&&(r=O(e.totalheight,t)-n);var i=0;e.width.number>0&&(i=O(e.width,t));var a={height:k(n+r)};i>0&&(a.width=k(i)),r>0&&(a.verticalAlign=k(-r));var o=new Pe(e.src,e.alt,a);return o.height=n,o.depth=r,o},mathmlBuilder:(e,t)=>{var n=new X(`mglyph`,[]);n.setAttribute(`alt`,e.alt);var r=O(e.height,t),i=0;if(e.totalheight.number>0&&(i=O(e.totalheight,t)-r,n.setAttribute(`valign`,k(-i))),n.setAttribute(`height`,k(r+i)),e.width.number>0){var a=O(e.width,t);n.setAttribute(`width`,k(a))}return n.setAttribute(`src`,e.src),n}}),q({type:`kern`,names:[`\\kern`,`\\mkern`,`\\hskip`,`\\mskip`],props:{numArgs:1,argTypes:[`size`],primitive:!0,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e,i=Q(t[0],`size`);if(n.settings.strict){var a=r[1]===`m`,o=i.value.unit===`mu`;a?(o||n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` supports only mu units, `+(`not `+i.value.unit+` units`)),n.mode!==`math`&&n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` works only in math mode`)):o&&n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` doesn't support mu units`)}return{type:`kern`,mode:n.mode,dimension:i.value}},htmlBuilder(e,t){return Kt(e.dimension,t)},mathmlBuilder(e,t){return new xn(O(e.dimension,t))}}),q({type:`lap`,names:[`\\mathllap`,`\\mathrlap`,`\\mathclap`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0];return{type:`lap`,mode:n.mode,alignment:r.slice(5),body:i}},htmlBuilder:(e,t)=>{var n;e.alignment===`clap`?(n=W([],[Y(e.body,t)]),n=W([`inner`],[n],t)):n=W([`inner`],[Y(e.body,t)]);var r=W([`fix`],[]),i=W([e.alignment],[n,r],t),a=W([`strut`]);return a.style.height=k(i.height+i.depth),i.depth&&(a.style.verticalAlign=k(-i.depth)),i.children.unshift(a),i=W([`thinbox`],[i],t),W([`mord`,`vbox`],[i],t)},mathmlBuilder:(e,t)=>{var n=new X(`mpadded`,[Z(e.body,t)]);if(e.alignment!==`rlap`){var r=e.alignment===`llap`?`-1`:`-0.5`;n.setAttribute(`lspace`,r+`width`)}return n.setAttribute(`width`,`0px`),n}}),q({type:`styling`,names:[`\\(`,`$`],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,t){var{funcName:n,parser:r}=e,i=r.mode;r.switchMode(`math`);var a=n===`\\(`?`\\)`:`$`,o=r.parseExpression(!1,a);return r.expect(a),r.switchMode(i),{type:`styling`,mode:r.mode,style:`text`,resetFont:!0,body:o}}}),q({type:`text`,names:[`\\)`,`\\]`],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,n){throw new e(`Mismatched `+t.funcName)}});var Ti=(e,t)=>{switch(t.style.size){case E.DISPLAY.size:return e.display;case E.TEXT.size:return e.text;case E.SCRIPT.size:return e.script;case E.SCRIPTSCRIPT.size:return e.scriptscript;default:return e.text}};q({type:`mathchoice`,names:[`\\mathchoice`],props:{numArgs:4,primitive:!0},handler:(e,t)=>{var{parser:n}=e;return{type:`mathchoice`,mode:n.mode,display:J(t[0]),text:J(t[1]),script:J(t[2]),scriptscript:J(t[3])}},htmlBuilder:(e,t)=>Ut(dn(Ti(e,t),t,!1)),mathmlBuilder:(e,t)=>An(Ti(e,t),t)});var Ei=(e,t,n,r,i,a,o)=>{e=W([],[e]);var s=n&&c(n),l,u;if(t){var d=Y(t,r.havingStyle(i.sup()),r);u={elem:d,kern:Math.max(r.fontMetrics().bigOpSpacing1,r.fontMetrics().bigOpSpacing3-d.depth)}}if(n){var f=Y(n,r.havingStyle(i.sub()),r);l={elem:f,kern:Math.max(r.fontMetrics().bigOpSpacing2,r.fontMetrics().bigOpSpacing4-f.height)}}var p;if(u&&l)p=G({positionType:`bottom`,positionData:r.fontMetrics().bigOpSpacing5+l.elem.height+l.elem.depth+l.kern+e.depth+o,children:[{type:`kern`,size:r.fontMetrics().bigOpSpacing5},{type:`elem`,elem:l.elem,marginLeft:k(-a)},{type:`kern`,size:l.kern},{type:`elem`,elem:e},{type:`kern`,size:u.kern},{type:`elem`,elem:u.elem,marginLeft:k(a)},{type:`kern`,size:r.fontMetrics().bigOpSpacing5}]});else if(l)p=G({positionType:`top`,positionData:e.height-o,children:[{type:`kern`,size:r.fontMetrics().bigOpSpacing5},{type:`elem`,elem:l.elem,marginLeft:k(-a)},{type:`kern`,size:l.kern},{type:`elem`,elem:e}]});else if(u)p=G({positionType:`bottom`,positionData:e.depth+o,children:[{type:`elem`,elem:e},{type:`kern`,size:u.kern},{type:`elem`,elem:u.elem,marginLeft:k(a)},{type:`kern`,size:r.fontMetrics().bigOpSpacing5}]});else return e;var m=[p];if(l&&a!==0&&!s){var h=W([`mspace`],[],r);h.style.marginRight=k(a),m.unshift(h)}return W([`mop`,`op-limits`],m,r)},Di=new Set([`\\smallint`]),Oi=(e,t)=>{var n,r,i=!1,a;e.type===`supsub`?(n=e.sup,r=e.sub,a=Q(e.base,`op`),i=!0):a=Q(e,`op`);var o=t.style,s=!1;o.size===E.DISPLAY.size&&a.symbol&&!Di.has(a.name)&&(s=!0);var c,l;if(a.symbol){var u=s?`Size2-Regular`:`Size1-Regular`,d=``;if((a.name===`\\oiint`||a.name===`\\oiiint`)&&(d=a.name.slice(1),a.name=d===`oiint`?`\\iint`:`\\iiint`),c=Nt(a.name,u,`math`,t,[`mop`,`op-symbol`,s?`large-op`:`small-op`]),l=c.italic,d.length>0){var f=Xt(d+`Size`+(s?`2`:`1`),t);c=G({positionType:`individualShift`,children:[{type:`elem`,elem:c,shift:0},{type:`elem`,elem:f,shift:s?.08:0}]}),a.name=`\\`+d,c.classes.unshift(`mop`),c.italic=l}}else if(a.body){var p=dn(a.body,t,!0);p.length===1&&p[0]instanceof Ie?(c=p[0],c.classes[0]=`mop`):c=W([`mop`],p,t)}else{for(var m=[],h=1;h{var n;if(e.symbol)n=new X(`mo`,[wn(e.name,e.mode)]),Di.has(e.name)&&n.setAttribute(`largeop`,`false`);else if(e.body)n=new X(`mo`,kn(e.body,t));else{n=new X(`mi`,[new bn(e.name.slice(1))]);var r=new X(`mo`,[wn(`⁡`,`text`)]);n=e.parentIsSupSub?new X(`mrow`,[n,r]):yn([n,r])}return n},Ai={"∏":`\\prod`,"∐":`\\coprod`,"∑":`\\sum`,"⋀":`\\bigwedge`,"⋁":`\\bigvee`,"⋂":`\\bigcap`,"⋃":`\\bigcup`,"⨀":`\\bigodot`,"⨁":`\\bigoplus`,"⨂":`\\bigotimes`,"⨄":`\\biguplus`,"⨆":`\\bigsqcup`};q({type:`op`,names:`\\coprod.\\bigvee.\\bigwedge.\\biguplus.\\bigcap.\\bigcup.\\intop.\\prod.\\sum.\\bigotimes.\\bigoplus.\\bigodot.\\bigsqcup.\\smallint.∏.∐.∑.⋀.⋁.⋂.⋃.⨀.⨁.⨂.⨄.⨆`.split(`.`),props:{numArgs:0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=r;return i.length===1&&(i=Ai[i]),{type:`op`,mode:n.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:i}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\mathop`],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`op`,mode:n.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:J(r)}},htmlBuilder:Oi,mathmlBuilder:ki});var ji={"∫":`\\int`,"∬":`\\iint`,"∭":`\\iiint`,"∮":`\\oint`,"∯":`\\oiint`,"∰":`\\oiiint`};q({type:`op`,names:`\\arcsin.\\arccos.\\arctan.\\arctg.\\arcctg.\\arg.\\ch.\\cos.\\cosec.\\cosh.\\cot.\\cotg.\\coth.\\csc.\\ctg.\\cth.\\deg.\\dim.\\exp.\\hom.\\ker.\\lg.\\ln.\\log.\\sec.\\sin.\\sinh.\\sh.\\tan.\\tanh.\\tg.\\th`.split(`.`),props:{numArgs:0},handler(e){var{parser:t,funcName:n}=e;return{type:`op`,mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\det`,`\\gcd`,`\\inf`,`\\lim`,`\\max`,`\\min`,`\\Pr`,`\\sup`],props:{numArgs:0},handler(e){var{parser:t,funcName:n}=e;return{type:`op`,mode:t.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\int`,`\\iint`,`\\iiint`,`\\oint`,`\\oiint`,`\\oiiint`,`∫`,`∬`,`∭`,`∮`,`∯`,`∰`],props:{numArgs:0,allowedInArgument:!0},handler(e){var{parser:t,funcName:n}=e,r=n;return r.length===1&&(r=ji[r]),{type:`op`,mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:r}},htmlBuilder:Oi,mathmlBuilder:ki});var Mi=(e,t)=>{var n,r,i=!1,a;e.type===`supsub`?(n=e.sup,r=e.sub,a=Q(e.base,`operatorname`),i=!0):a=Q(e,`operatorname`);var o;if(a.body.length>0){for(var s=dn(a.body.map(e=>{var t=`text`in e?e.text:void 0;return typeof t==`string`?{type:`textord`,mode:e.mode,text:t}:e}),t.withFont(`mathrm`),!0),c=0;c{var{parser:n,funcName:r}=e,i=t[0];return{type:`operatorname`,mode:n.mode,body:J(i),alwaysHandleSupSub:r===`\\operatornamewithlimits`,limits:!1,parentIsSupSub:!1}},htmlBuilder:Mi,mathmlBuilder:(e,t)=>{for(var n=kn(e.body,t.withFont(`mathrm`)),r=!0,i=0;ie.toText()).join(``))]);var s=new X(`mi`,n);s.setAttribute(`mathvariant`,`normal`);var c=new X(`mo`,[wn(`⁡`,`text`)]);return e.parentIsSupSub?new X(`mrow`,[s,c]):yn([s,c])}}),$(`\\operatorname`,`\\@ifstar\\operatornamewithlimits\\operatorname@`),an({type:`ordgroup`,htmlBuilder(e,t){return e.semisimple?Ut(dn(e.body,t,!1)):W([`mord`],dn(e.body,t,!0),t)},mathmlBuilder(e,t){return An(e.body,t,!0)}}),q({type:`overline`,names:[`\\overline`],props:{numArgs:1},handler(e,t){var{parser:n}=e,r=t[0];return{type:`overline`,mode:n.mode,body:r}},htmlBuilder(e,t){var n=Y(e.body,t.havingCrampedStyle()),r=Vt(`overline-line`,t),i=t.fontMetrics().defaultRuleThickness;return W([`mord`,`overline`],[G({positionType:`firstBaseline`,children:[{type:`elem`,elem:n},{type:`kern`,size:3*i},{type:`elem`,elem:r},{type:`kern`,size:i}]})],t)},mathmlBuilder(e,t){var n=new X(`mo`,[new bn(`‾`)]);n.setAttribute(`stretchy`,`true`);var r=new X(`mover`,[Z(e.body,t),n]);return r.setAttribute(`accent`,`true`),r}}),q({type:`phantom`,names:[`\\phantom`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`phantom`,mode:n.mode,body:J(r)}},htmlBuilder:(e,t)=>Ut(dn(e.body,t.withPhantom(),!1)),mathmlBuilder:(e,t)=>new X(`mphantom`,kn(e.body,t))}),$(`\\hphantom`,`\\smash{\\phantom{#1}}`),q({type:`vphantom`,names:[`\\vphantom`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`vphantom`,mode:n.mode,body:r}},htmlBuilder:(e,t)=>W([`mord`,`rlap`],[W([`inner`],[Y(e.body,t.withPhantom())]),W([`fix`],[])],t),mathmlBuilder:(e,t)=>{var n=new X(`mpadded`,[new X(`mphantom`,kn(J(e.body),t))]);return n.setAttribute(`width`,`0px`),n}}),q({type:`raisebox`,names:[`\\raisebox`],props:{numArgs:2,argTypes:[`size`,`hbox`],allowedInText:!0},handler(e,t){var{parser:n}=e,r=Q(t[0],`size`).value,i=t[1];return{type:`raisebox`,mode:n.mode,dy:r,body:i}},htmlBuilder(e,t){var n=Y(e.body,t);return G({positionType:`shift`,positionData:-O(e.dy,t),children:[{type:`elem`,elem:n}]})},mathmlBuilder(e,t){var n=new X(`mpadded`,[Z(e.body,t)]),r=e.dy.number+e.dy.unit;return n.setAttribute(`voffset`,r),n}}),q({type:`internal`,names:[`\\relax`],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(e){var{parser:t}=e;return{type:`internal`,mode:t.mode}}}),q({type:`rule`,names:[`\\rule`],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:[`size`,`size`,`size`]},handler(e,t,n){var{parser:r}=e,i=n[0],a=Q(t[0],`size`),o=Q(t[1],`size`);return{type:`rule`,mode:r.mode,shift:i&&Q(i,`size`).value,width:a.value,height:o.value}},htmlBuilder(e,t){var n=W([`mord`,`rule`],[],t),r=O(e.width,t),i=O(e.height,t),a=e.shift?O(e.shift,t):0;return n.style.borderRightWidth=k(r),n.style.borderTopWidth=k(i),n.style.bottom=k(a),n.width=r,n.height=i+a,n.depth=-a,n.maxFontSize=i*1.125*t.sizeMultiplier,n},mathmlBuilder(e,t){var n=O(e.width,t),r=O(e.height,t),i=e.shift?O(e.shift,t):0,a=t.color&&t.getColor()||`black`,o=new X(`mspace`);o.setAttribute(`mathbackground`,a),o.setAttribute(`width`,k(n)),o.setAttribute(`height`,k(r));var s=new X(`mpadded`,[o]);return i>=0?s.setAttribute(`height`,k(i)):(s.setAttribute(`height`,k(i)),s.setAttribute(`depth`,k(-i))),s.setAttribute(`voffset`,k(i)),s}});function Ni(e,t,n){for(var r=dn(e,t,!1),i=t.sizeMultiplier/n.sizeMultiplier,a=0;a{var{breakOnTokenText:n,funcName:r,parser:i}=e,a=i.parseExpression(!1,n);return{type:`sizing`,mode:i.mode,size:Pi.indexOf(r)+1,body:a}},htmlBuilder:(e,t)=>{var n=t.havingSize(e.size);return Ni(e.body,n,t)},mathmlBuilder:(e,t)=>{var n=t.havingSize(e.size),r=new X(`mstyle`,kn(e.body,n));return r.setAttribute(`mathsize`,k(n.sizeMultiplier)),r}}),q({type:`smash`,names:[`\\smash`],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(e,t,n)=>{var{parser:r}=e,i=!1,a=!1,o=n[0]&&Q(n[0],`ordgroup`);if(o)for(var s,c=0;c{var n=W([],[Y(e.body,t)]);if(!e.smashHeight&&!e.smashDepth)return n;if(e.smashHeight&&(n.height=0),e.smashDepth&&(n.depth=0),e.smashHeight&&e.smashDepth)return W([`mord`,`smash`],[n],t);if(n.children)for(var r=0;r{var n=new X(`mpadded`,[Z(e.body,t)]);return e.smashHeight&&n.setAttribute(`height`,`0px`),e.smashDepth&&n.setAttribute(`depth`,`0px`),n}}),q({type:`sqrt`,names:[`\\sqrt`],props:{numArgs:1,numOptionalArgs:1},handler(e,t,n){var{parser:r}=e,i=n[0],a=t[0];return{type:`sqrt`,mode:r.mode,body:a,index:i}},htmlBuilder(e,t){var n=Y(e.body,t.havingCrampedStyle());n.height===0&&(n.height=t.fontMetrics().xHeight),n=Wt(n,t);var r=t.fontMetrics().defaultRuleThickness,i=r;t.style.idn.height+n.depth+a&&(a=(a+l-n.height-n.depth)/2);var u=o.height-n.height-a-s;n.style.paddingLeft=k(c);var d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:n,wrapperClasses:[`svg-align`]},{type:`kern`,size:-(n.height+u)},{type:`elem`,elem:o},{type:`kern`,size:s}]});if(e.index){var f=t.havingStyle(E.SCRIPTSCRIPT),p=Y(e.index,f,t);return W([`mord`,`sqrt`],[W([`root`],[G({positionType:`shift`,positionData:-(.6*(d.height-d.depth)),children:[{type:`elem`,elem:p}]})]),d],t)}return W([`mord`,`sqrt`],[d],t)},mathmlBuilder(e,t){var{body:n,index:r}=e;return r?new X(`mroot`,[Z(n,t),Z(r,t)]):new X(`msqrt`,[Z(n,t)])}});var Fi={display:E.DISPLAY,text:E.TEXT,script:E.SCRIPT,scriptscript:E.SCRIPTSCRIPT};function Ii(e){return e in Fi}q({type:`styling`,names:[`\\displaystyle`,`\\textstyle`,`\\scriptstyle`,`\\scriptscriptstyle`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e,t){var{breakOnTokenText:n,funcName:r,parser:i}=e,a=i.parseExpression(!0,n),o=r.slice(1,r.length-5);if(!Ii(o))throw Error(`Unknown style: `+o);return{type:`styling`,mode:i.mode,style:o,body:a}},htmlBuilder(e,t){var n=Fi[e.style],r=t.havingStyle(n);return e.resetFont&&(r=r.withFont(``)),Ni(e.body,r,t)},mathmlBuilder(e,t){var n=Fi[e.style],r=t.havingStyle(n);e.resetFont&&(r=r.withFont(``));var i=new X(`mstyle`,kn(e.body,r)),a={display:[`0`,`true`],text:[`0`,`false`],script:[`1`,`false`],scriptscript:[`2`,`false`]}[e.style];return i.setAttribute(`scriptlevel`,a[0]),i.setAttribute(`displaystyle`,a[1]),i}});var Li=function(e,t){var n=e.base;return n?n.type===`op`?n.limits&&(t.style.size===E.DISPLAY.size||n.alwaysHandleSupSub)?Oi:null:n.type===`operatorname`?n.alwaysHandleSupSub&&(t.style.size===E.DISPLAY.size||n.limits)?Mi:null:n.type===`accent`?c(n.base)?Qn:null:n.type===`horizBrace`&&!e.sub===n.isOver?Ci:null:null};an({type:`supsub`,htmlBuilder(e,t){var n=Li(e,t);if(n)return n(e,t);var{base:r,sup:i,sub:a}=e,o=Y(r,t),s,l,u=t.fontMetrics(),d=0,f=0,p=r&&c(r);if(i){var m=t.havingStyle(t.style.sup());s=Y(i,m,t),p||(d=o.height-m.fontMetrics().supDrop*m.sizeMultiplier/t.sizeMultiplier)}if(a){var h=t.havingStyle(t.style.sub());l=Y(a,h,t),p||(f=o.depth+h.fontMetrics().subDrop*h.sizeMultiplier/t.sizeMultiplier)}var g=t.style===E.DISPLAY?u.sup1:t.style.cramped?u.sup3:u.sup2,_=t.sizeMultiplier,v=k(.5/u.ptPerEm/_),y=null;if(l){var b=e.base&&e.base.type===`op`&&e.base.name&&(e.base.name===`\\oiint`||e.base.name===`\\oiiint`);(o instanceof Ie||b)&&(y=k(-(o.italic??0)))}var x;if(s&&l){d=Math.max(d,g,s.depth+.25*u.xHeight),f=Math.max(f,u.sub2);var S=4*u.defaultRuleThickness;if(d-s.depth-(l.height-f)0&&(d+=C,f-=C)}x=G({positionType:`individualShift`,children:[{type:`elem`,elem:l,shift:f,marginRight:v,marginLeft:y},{type:`elem`,elem:s,shift:-d,marginRight:v}]})}else if(l)f=Math.max(f,u.sub1,l.height-.8*u.xHeight),x=G({positionType:`shift`,positionData:f,children:[{type:`elem`,elem:l,marginLeft:y,marginRight:v}]});else if(s)d=Math.max(d,g,s.depth+.25*u.xHeight),x=G({positionType:`shift`,positionData:-d,children:[{type:`elem`,elem:s,marginRight:v}]});else throw Error(`supsub must have either sup or sub.`);return W([hn(o,`right`)||`mord`],[o,W([`msupsub`],[x])],t)},mathmlBuilder(e,t){var n=!1,r,i;e.base&&e.base.type===`horizBrace`&&(i=!!e.sup,i===e.base.isOver&&(n=!0,r=e.base.isOver)),e.base&&(e.base.type===`op`||e.base.type===`operatorname`)&&(e.base.parentIsSupSub=!0);var a=[Z(e.base,t)];e.sub&&a.push(Z(e.sub,t)),e.sup&&a.push(Z(e.sup,t));var o;if(n)o=r?`mover`:`munder`;else if(!e.sub){var s=e.base;o=s&&s.type===`op`&&s.limits&&(t.style===E.DISPLAY||s.alwaysHandleSupSub)||s&&s.type===`operatorname`&&s.alwaysHandleSupSub&&(s.limits||t.style===E.DISPLAY)?`mover`:`msup`}else if(e.sup){var c=e.base;o=c&&c.type===`op`&&c.limits&&t.style===E.DISPLAY||c&&c.type===`operatorname`&&c.alwaysHandleSupSub&&(t.style===E.DISPLAY||c.limits)?`munderover`:`msubsup`}else{var l=e.base;o=l&&l.type===`op`&&l.limits&&(t.style===E.DISPLAY||l.alwaysHandleSupSub)||l&&l.type===`operatorname`&&l.alwaysHandleSupSub&&(l.limits||t.style===E.DISPLAY)?`munder`:`msub`}return new X(o,a)}}),an({type:`atom`,htmlBuilder(e,t){return Pt(e.text,e.mode,t,[`m`+e.family])},mathmlBuilder(e,t){var n=new X(`mo`,[wn(e.text,e.mode)]);if(e.family===`bin`){var r=Dn(e,t);r===`bold-italic`&&n.setAttribute(`mathvariant`,r)}else e.family===`punct`?n.setAttribute(`separator`,`true`):(e.family===`open`||e.family===`close`)&&n.setAttribute(`stretchy`,`false`);return n}});var Ri={mi:`italic`,mn:`normal`,mtext:`normal`};an({type:`mathord`,htmlBuilder(e,t){return It(e,t,`mathord`)},mathmlBuilder(e,t){var n=new X(`mi`,[wn(e.text,e.mode,t)]),r=Dn(e,t)||`italic`;return r!==Ri[n.type]&&n.setAttribute(`mathvariant`,r),n}}),an({type:`textord`,htmlBuilder(e,t){return It(e,t,`textord`)},mathmlBuilder(e,t){var n=wn(e.text,e.mode,t),r=Dn(e,t)||`normal`,i=e.mode===`text`?new X(`mtext`,[n]):/[0-9]/.test(e.text)?new X(`mn`,[n]):e.text===`\\prime`?new X(`mo`,[n]):new X(`mi`,[n]);return r!==Ri[i.type]&&i.setAttribute(`mathvariant`,r),i}});var zi={"\\nobreak":`nobreak`,"\\allowbreak":`allowbreak`},Bi={" ":{},"\\ ":{},"~":{className:`nobreak`},"\\space":{},"\\nobreakspace":{className:`nobreak`}};an({type:`spacing`,htmlBuilder(t,n){if(Bi.hasOwnProperty(t.text)){var r=Bi[t.text].className||``;if(t.mode===`text`){var i=It(t,n,`textord`);return i.classes.push(r),i}return W([`mspace`,r],[Pt(t.text,t.mode,n)],n)}if(zi.hasOwnProperty(t.text))return W([`mspace`,zi[t.text]],[],n);throw new e(`Unknown type of space "`+t.text+`"`)},mathmlBuilder(t,n){var r;if(Bi.hasOwnProperty(t.text))r=new X(`mtext`,[new bn(`\xA0`)]);else if(zi.hasOwnProperty(t.text))return new X(`mspace`);else throw new e(`Unknown type of space "`+t.text+`"`);return r}});var Vi=()=>{var e=new X(`mtd`,[]);return e.setAttribute(`width`,`50%`),e};an({type:`tag`,mathmlBuilder(e,t){var n=new X(`mtable`,[new X(`mtr`,[Vi(),new X(`mtd`,[An(e.body,t)]),Vi(),new X(`mtd`,[An(e.tag,t)])])]);return n.setAttribute(`width`,`100%`),n}});var Hi={"\\text":void 0,"\\textrm":`textrm`,"\\textsf":`textsf`,"\\texttt":`texttt`,"\\textnormal":`textrm`},Ui={"\\textbf":`textbf`,"\\textmd":`textmd`},Wi={"\\textit":`textit`,"\\textup":`textup`},Gi=(e,t)=>{var n=e.font;return n?Hi[n]?t.withTextFontFamily(Hi[n]):Ui[n]?t.withTextFontWeight(Ui[n]):n===`\\emph`?t.fontShape===`textit`?t.withTextFontShape(`textup`):t.withTextFontShape(`textit`):t.withTextFontShape(Wi[n]):t};q({type:`text`,names:[`\\text`,`\\textrm`,`\\textsf`,`\\texttt`,`\\textnormal`,`\\textbf`,`\\textmd`,`\\textit`,`\\textup`,`\\emph`],props:{numArgs:1,argTypes:[`text`],allowedInArgument:!0,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`text`,mode:n.mode,body:J(i),font:r}},htmlBuilder(e,t){var n=Gi(e,t);return W([`mord`,`text`],dn(e.body,n,!0),n)},mathmlBuilder(e,t){var n=Gi(e,t);return An(e.body,n)}}),q({type:`underline`,names:[`\\underline`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`underline`,mode:n.mode,body:t[0]}},htmlBuilder(e,t){var n=Y(e.body,t),r=Vt(`underline-line`,t),i=t.fontMetrics().defaultRuleThickness;return W([`mord`,`underline`],[G({positionType:`top`,positionData:n.height,children:[{type:`kern`,size:i},{type:`elem`,elem:r},{type:`kern`,size:3*i},{type:`elem`,elem:n}]})],t)},mathmlBuilder(e,t){var n=new X(`mo`,[new bn(`‾`)]);n.setAttribute(`stretchy`,`true`);var r=new X(`munder`,[Z(e.body,t),n]);return r.setAttribute(`accentunder`,`true`),r}}),q({type:`vcenter`,names:[`\\vcenter`],props:{numArgs:1,argTypes:[`original`],allowedInText:!1},handler(e,t){var{parser:n}=e;return{type:`vcenter`,mode:n.mode,body:t[0]}},htmlBuilder(e,t){var n=Y(e.body,t),r=t.fontMetrics().axisHeight;return G({positionType:`shift`,positionData:.5*(n.height-r-(n.depth+r)),children:[{type:`elem`,elem:n}]})},mathmlBuilder(e,t){return new X(`mrow`,[new X(`mpadded`,[Z(e.body,t)],[`vcenter`])])}}),q({type:`verb`,names:[`\\verb`],props:{numArgs:0,allowedInText:!0},handler(t,n,r){throw new e(`\\verb ended by end of line instead of matching delimiter`)},htmlBuilder(e,t){for(var n=Ki(e),r=[],i=t.havingStyle(t.style.text()),a=0;ae.body.replace(/ /g,e.star?`␣`:`\xA0`),qi=tn,Ji=`[ \r + ]`,Yi=`\\\\[a-zA-Z@]+`,Xi=`\\\\[^\ud800-\udfff]`,Zi=`(`+Yi+`)`+Ji+`*`,Qi=`\\\\( +|[ \r ]+ +?)[ \r ]*`,$i=`[̀-ͯ]`,ea=RegExp($i+`+$`),ta=`(`+Ji+`+)|`+(Qi+`|`)+`([!-\\[\\]-‧‪-퟿豈-￿]`+($i+`*`)+`|[\ud800-\udbff][\udc00-\udfff]`+($i+`*`)+`|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5`+(`|`+Zi)+(`|`+Xi+`)`),na=class{constructor(e,t){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=e,this.settings=t,this.tokenRegex=new RegExp(ta,`g`),this.catcodes={"%":14,"~":13}}setCatcode(e,t){this.catcodes[e]=t}lex(){var t=this.input,n=this.tokenRegex.lastIndex;if(n===t.length)return new ri(`EOF`,new ni(this,n,n));var r=this.tokenRegex.exec(t);if(r===null||r.index!==n)throw new e(`Unexpected character: '`+t[n]+`'`,new ri(t[n],new ni(this,n,n+1)));var i=r[6]||r[3]||(r[2]?`\\ `:` `);if(this.catcodes[i]===14){var a=t.indexOf(` +`,this.tokenRegex.lastIndex);return a===-1?(this.tokenRegex.lastIndex=t.length,this.settings.reportNonstrict(`commentAtEnd`,`% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)`)):this.tokenRegex.lastIndex=a+1,this.lex()}return new ri(i,new ni(this,n,this.tokenRegex.lastIndex))}},ra=class{constructor(e,t){e===void 0&&(e={}),t===void 0&&(t={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=t,this.builtins=e,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(this.undefStack.length===0)throw new e(`Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug`);var t=this.undefStack.pop();for(var n in t)t.hasOwnProperty(n)&&(t[n]==null?delete this.current[n]:this.current[n]=t[n])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(e){return this.current.hasOwnProperty(e)||this.builtins.hasOwnProperty(e)}get(e){return this.current.hasOwnProperty(e)?this.current[e]:this.builtins[e]}set(e,t,n){if(n===void 0&&(n=!1),n){for(var r=0;r0&&(this.undefStack[this.undefStack.length-1][e]=t)}else{var i=this.undefStack[this.undefStack.length-1];i&&!i.hasOwnProperty(e)&&(i[e]=this.current[e])}t==null?delete this.current[e]:this.current[e]=t}},ia=ti;$(`\\noexpand`,function(e){var t=e.popToken();return e.isExpandable(t.text)&&(t.noexpand=!0,t.treatAsRelax=!0),{tokens:[t],numArgs:0}}),$(`\\expandafter`,function(e){var t=e.popToken();return e.expandOnce(!0),{tokens:[t],numArgs:0}}),$(`\\@firstoftwo`,function(e){return{tokens:e.consumeArgs(2)[0],numArgs:0}}),$(`\\@secondoftwo`,function(e){return{tokens:e.consumeArgs(2)[1],numArgs:0}}),$(`\\@ifnextchar`,function(e){var t=e.consumeArgs(3);e.consumeSpaces();var n=e.future();return t[0].length===1&&t[0][0].text===n.text?{tokens:t[1],numArgs:0}:{tokens:t[2],numArgs:0}}),$(`\\@ifstar`,`\\@ifnextchar *{\\@firstoftwo{#1}}`),$(`\\TextOrMath`,function(e){var t=e.consumeArgs(2);return e.mode===`text`?{tokens:t[0],numArgs:0}:{tokens:t[1],numArgs:0}});var aa={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};$(`\\char`,function(t){var n=t.popToken(),r,i=0;if(n.text===`'`)r=8,n=t.popToken();else if(n.text===`"`)r=16,n=t.popToken();else if(n.text==="`"){if(n=t.popToken(),n.text[0]===`\\`)i=n.text.charCodeAt(1);else if(n.text===`EOF`)throw new e("\\char` missing argument");else i=n.text.charCodeAt(0)}else r=10;if(r){if(i=aa[n.text],i==null||i>=r)throw new e(`Invalid base-`+r+` digit `+n.text);for(var a;(a=aa[t.future().text])!=null&&a{var a=t.consumeArg().tokens;if(a.length!==1)throw new e(`\\newcommand's first argument must be a macro name`);var o=a[0].text,s=t.isDefined(o);if(s&&!n)throw new e(`\\newcommand{`+o+`} attempting to redefine `+(o+`; use \\renewcommand`));if(!s&&!r)throw new e(`\\renewcommand{`+o+`} when command `+o+` does not yet exist; use \\newcommand`);var c=0;if(a=t.consumeArg().tokens,a.length===1&&a[0].text===`[`){for(var l=``,u=t.expandNextToken();u.text!==`]`&&u.text!==`EOF`;)l+=u.text,u=t.expandNextToken();if(!l.match(/^\s*[0-9]+\s*$/))throw new e(`Invalid number of arguments: `+l);c=parseInt(l),a=t.consumeArg().tokens}return s&&i||t.macros.set(o,{tokens:a,numArgs:c}),``};$(`\\newcommand`,e=>oa(e,!1,!0,!1)),$(`\\renewcommand`,e=>oa(e,!0,!1,!1)),$(`\\providecommand`,e=>oa(e,!0,!0,!0)),$(`\\message`,e=>{var t=e.consumeArgs(1)[0];return console.log(t.reverse().map(e=>e.text).join(``)),``}),$(`\\errmessage`,e=>{var t=e.consumeArgs(1)[0];return console.error(t.reverse().map(e=>e.text).join(``)),``}),$(`\\show`,e=>{var t=e.popToken(),n=t.text;return console.log(t,e.macros.get(n),qi[n],A.math[n],A.text[n]),``}),$(`\\bgroup`,`{`),$(`\\egroup`,`}`),$(`~`,`\\nobreakspace`),$(`\\lq`,"`"),$(`\\rq`,`'`),$(`\\aa`,`\\r a`),$(`\\AA`,`\\r A`),$(`\\textcopyright`,"\\html@mathml{\\textcircled{c}}{\\char`©}"),$(`\\copyright`,`\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}`),$(`\\textregistered`,"\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}"),$(`ℬ`,`\\mathscr{B}`),$(`ℰ`,`\\mathscr{E}`),$(`ℱ`,`\\mathscr{F}`),$(`ℋ`,`\\mathscr{H}`),$(`ℐ`,`\\mathscr{I}`),$(`ℒ`,`\\mathscr{L}`),$(`ℳ`,`\\mathscr{M}`),$(`ℛ`,`\\mathscr{R}`),$(`ℭ`,`\\mathfrak{C}`),$(`ℌ`,`\\mathfrak{H}`),$(`ℨ`,`\\mathfrak{Z}`),$(`\\Bbbk`,`\\Bbb{k}`),$(`\\llap`,`\\mathllap{\\textrm{#1}}`),$(`\\rlap`,`\\mathrlap{\\textrm{#1}}`),$(`\\clap`,`\\mathclap{\\textrm{#1}}`),$(`\\mathstrut`,`\\vphantom{(}`),$(`\\underbar`,`\\underline{\\text{#1}}`),$(`\\not`,`\\html@mathml{\\mathrel{\\mathrlap\\@not}\\nobreak}{\\char"338}`),$(`\\neq`,"\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}"),$(`\\ne`,`\\neq`),$(`≠`,`\\neq`),$(`\\notin`,"\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}"),$(`∉`,`\\notin`),$(`≘`,"\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}"),$(`≙`,"\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}"),$(`≚`,"\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}"),$(`≛`,"\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}"),$(`≝`,"\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}"),$(`≞`,"\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}"),$(`≟`,"\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}"),$(`⟂`,`\\perp`),$(`‼`,`\\mathclose{!\\mkern-0.8mu!}`),$(`∌`,`\\notni`),$(`⌜`,`\\ulcorner`),$(`⌝`,`\\urcorner`),$(`⌞`,`\\llcorner`),$(`⌟`,`\\lrcorner`),$(`©`,`\\copyright`),$(`®`,`\\textregistered`),$(`\\ulcorner`,`\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}`),$(`\\urcorner`,`\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}`),$(`\\llcorner`,`\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}`),$(`\\lrcorner`,`\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}`),$(`\\vdots`,`{\\varvdots\\rule{0pt}{15pt}}`),$(`⋮`,`\\vdots`),$(`\\varGamma`,`\\mathit{\\Gamma}`),$(`\\varDelta`,`\\mathit{\\Delta}`),$(`\\varTheta`,`\\mathit{\\Theta}`),$(`\\varLambda`,`\\mathit{\\Lambda}`),$(`\\varXi`,`\\mathit{\\Xi}`),$(`\\varPi`,`\\mathit{\\Pi}`),$(`\\varSigma`,`\\mathit{\\Sigma}`),$(`\\varUpsilon`,`\\mathit{\\Upsilon}`),$(`\\varPhi`,`\\mathit{\\Phi}`),$(`\\varPsi`,`\\mathit{\\Psi}`),$(`\\varOmega`,`\\mathit{\\Omega}`),$(`\\substack`,`\\begin{subarray}{c}#1\\end{subarray}`),$(`\\colon`,`\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax`),$(`\\boxed`,`\\fbox{$\\displaystyle{#1}$}`),$(`\\iff`,`\\DOTSB\\;\\Longleftrightarrow\\;`),$(`\\implies`,`\\DOTSB\\;\\Longrightarrow\\;`),$(`\\impliedby`,`\\DOTSB\\;\\Longleftarrow\\;`),$(`\\dddot`,`{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}`),$(`\\ddddot`,`{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}`);var sa={",":`\\dotsc`,"\\not":`\\dotsb`,"+":`\\dotsb`,"=":`\\dotsb`,"<":`\\dotsb`,">":`\\dotsb`,"-":`\\dotsb`,"*":`\\dotsb`,":":`\\dotsb`,"\\DOTSB":`\\dotsb`,"\\coprod":`\\dotsb`,"\\bigvee":`\\dotsb`,"\\bigwedge":`\\dotsb`,"\\biguplus":`\\dotsb`,"\\bigcap":`\\dotsb`,"\\bigcup":`\\dotsb`,"\\prod":`\\dotsb`,"\\sum":`\\dotsb`,"\\bigotimes":`\\dotsb`,"\\bigoplus":`\\dotsb`,"\\bigodot":`\\dotsb`,"\\bigsqcup":`\\dotsb`,"\\And":`\\dotsb`,"\\longrightarrow":`\\dotsb`,"\\Longrightarrow":`\\dotsb`,"\\longleftarrow":`\\dotsb`,"\\Longleftarrow":`\\dotsb`,"\\longleftrightarrow":`\\dotsb`,"\\Longleftrightarrow":`\\dotsb`,"\\mapsto":`\\dotsb`,"\\longmapsto":`\\dotsb`,"\\hookrightarrow":`\\dotsb`,"\\doteq":`\\dotsb`,"\\mathbin":`\\dotsb`,"\\mathrel":`\\dotsb`,"\\relbar":`\\dotsb`,"\\Relbar":`\\dotsb`,"\\xrightarrow":`\\dotsb`,"\\xleftarrow":`\\dotsb`,"\\DOTSI":`\\dotsi`,"\\int":`\\dotsi`,"\\oint":`\\dotsi`,"\\iint":`\\dotsi`,"\\iiint":`\\dotsi`,"\\iiiint":`\\dotsi`,"\\idotsint":`\\dotsi`,"\\DOTSX":`\\dotsx`},ca=new Set([`bin`,`rel`]);$(`\\dots`,function(e){var t=`\\dotso`,n=e.expandAfterFuture().text;return n in sa?t=sa[n]:(n.slice(0,4)===`\\not`||n in A.math&&ca.has(A.math[n].group))&&(t=`\\dotsb`),t});var la={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};$(`\\dotso`,function(e){return e.future().text in la?`\\ldots\\,`:`\\ldots`}),$(`\\dotsc`,function(e){var t=e.future().text;return t in la&&t!==`,`?`\\ldots\\,`:`\\ldots`}),$(`\\cdots`,function(e){return e.future().text in la?`\\@cdots\\,`:`\\@cdots`}),$(`\\dotsb`,`\\cdots`),$(`\\dotsm`,`\\cdots`),$(`\\dotsi`,`\\!\\cdots`),$(`\\dotsx`,`\\ldots\\,`),$(`\\DOTSI`,`\\relax`),$(`\\DOTSB`,`\\relax`),$(`\\DOTSX`,`\\relax`),$(`\\tmspace`,`\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax`),$(`\\,`,`\\tmspace+{3mu}{.1667em}`),$(`\\thinspace`,`\\,`),$(`\\>`,`\\mskip{4mu}`),$(`\\:`,`\\tmspace+{4mu}{.2222em}`),$(`\\medspace`,`\\:`),$(`\\;`,`\\tmspace+{5mu}{.2777em}`),$(`\\thickspace`,`\\;`),$(`\\!`,`\\tmspace-{3mu}{.1667em}`),$(`\\negthinspace`,`\\!`),$(`\\negmedspace`,`\\tmspace-{4mu}{.2222em}`),$(`\\negthickspace`,`\\tmspace-{5mu}{.277em}`),$(`\\enspace`,`\\kern.5em `),$(`\\enskip`,`\\hskip.5em\\relax`),$(`\\quad`,`\\hskip1em\\relax`),$(`\\qquad`,`\\hskip2em\\relax`),$(`\\tag`,`\\@ifstar\\tag@literal\\tag@paren`),$(`\\tag@paren`,`\\tag@literal{({#1})}`),$(`\\tag@literal`,t=>{if(t.macros.get(`\\df@tag`))throw new e(`Multiple \\tag`);return`\\gdef\\df@tag{\\text{#1}}`}),$(`\\bmod`,`\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}`),$(`\\pod`,`\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)`),$(`\\pmod`,`\\pod{{\\rm mod}\\mkern6mu#1}`),$(`\\mod`,`\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1`),$(`\\newline`,`\\\\\\relax`),$(`\\TeX`,`\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}`);var ua=k(Ue[`Main-Regular`][84][1]-.7*Ue[`Main-Regular`][65][1]);$(`\\LaTeX`,`\\textrm{\\html@mathml{`+(`L\\kern-.36em\\raisebox{`+ua+`}{\\scriptstyle A}`)+`\\kern-.15em\\TeX}{LaTeX}}`),$(`\\KaTeX`,`\\textrm{\\html@mathml{`+(`K\\kern-.17em\\raisebox{`+ua+`}{\\scriptstyle A}`)+`\\kern-.15em\\TeX}{KaTeX}}`),$(`\\hspace`,`\\@ifstar\\@hspacer\\@hspace`),$(`\\@hspace`,`\\hskip #1\\relax`),$(`\\@hspacer`,`\\rule{0pt}{0pt}\\hskip #1\\relax`),$(`\\ordinarycolon`,`:`),$(`\\vcentcolon`,`\\mathrel{\\mathop\\ordinarycolon}`),$(`\\dblcolon`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}`),$(`\\coloneqq`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}`),$(`\\Coloneqq`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}`),$(`\\coloneq`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}`),$(`\\Coloneq`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}`),$(`\\eqqcolon`,`\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}`),$(`\\Eqqcolon`,`\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}`),$(`\\eqcolon`,`\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}`),$(`\\Eqcolon`,`\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}`),$(`\\colonapprox`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}`),$(`\\Colonapprox`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}`),$(`\\colonsim`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}`),$(`\\Colonsim`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}`),$(`∷`,`\\dblcolon`),$(`∹`,`\\eqcolon`),$(`≔`,`\\coloneqq`),$(`≕`,`\\eqqcolon`),$(`⩴`,`\\Coloneqq`),$(`\\ratio`,`\\vcentcolon`),$(`\\coloncolon`,`\\dblcolon`),$(`\\colonequals`,`\\coloneqq`),$(`\\coloncolonequals`,`\\Coloneqq`),$(`\\equalscolon`,`\\eqqcolon`),$(`\\equalscoloncolon`,`\\Eqqcolon`),$(`\\colonminus`,`\\coloneq`),$(`\\coloncolonminus`,`\\Coloneq`),$(`\\minuscolon`,`\\eqcolon`),$(`\\minuscoloncolon`,`\\Eqcolon`),$(`\\coloncolonapprox`,`\\Colonapprox`),$(`\\coloncolonsim`,`\\Colonsim`),$(`\\simcolon`,`\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}`),$(`\\simcoloncolon`,`\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}`),$(`\\approxcolon`,`\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}`),$(`\\approxcoloncolon`,`\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}`),$(`\\notni`,"\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}"),$(`\\limsup`,`\\DOTSB\\operatorname*{lim\\,sup}`),$(`\\liminf`,`\\DOTSB\\operatorname*{lim\\,inf}`),$(`\\injlim`,`\\DOTSB\\operatorname*{inj\\,lim}`),$(`\\projlim`,`\\DOTSB\\operatorname*{proj\\,lim}`),$(`\\varlimsup`,`\\DOTSB\\operatorname*{\\overline{lim}}`),$(`\\varliminf`,`\\DOTSB\\operatorname*{\\underline{lim}}`),$(`\\varinjlim`,`\\DOTSB\\operatorname*{\\underrightarrow{lim}}`),$(`\\varprojlim`,`\\DOTSB\\operatorname*{\\underleftarrow{lim}}`),$(`\\gvertneqq`,`\\html@mathml{\\@gvertneqq}{≩}`),$(`\\lvertneqq`,`\\html@mathml{\\@lvertneqq}{≨}`),$(`\\ngeqq`,`\\html@mathml{\\@ngeqq}{≱}`),$(`\\ngeqslant`,`\\html@mathml{\\@ngeqslant}{≱}`),$(`\\nleqq`,`\\html@mathml{\\@nleqq}{≰}`),$(`\\nleqslant`,`\\html@mathml{\\@nleqslant}{≰}`),$(`\\nshortmid`,`\\html@mathml{\\@nshortmid}{∤}`),$(`\\nshortparallel`,`\\html@mathml{\\@nshortparallel}{∦}`),$(`\\nsubseteqq`,`\\html@mathml{\\@nsubseteqq}{⊈}`),$(`\\nsupseteqq`,`\\html@mathml{\\@nsupseteqq}{⊉}`),$(`\\varsubsetneq`,`\\html@mathml{\\@varsubsetneq}{⊊}`),$(`\\varsubsetneqq`,`\\html@mathml{\\@varsubsetneqq}{⫋}`),$(`\\varsupsetneq`,`\\html@mathml{\\@varsupsetneq}{⊋}`),$(`\\varsupsetneqq`,`\\html@mathml{\\@varsupsetneqq}{⫌}`),$(`\\imath`,`\\html@mathml{\\@imath}{ı}`),$(`\\jmath`,`\\html@mathml{\\@jmath}{ȷ}`),$(`\\llbracket`,"\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}"),$(`\\rrbracket`,"\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}"),$(`⟦`,`\\llbracket`),$(`⟧`,`\\rrbracket`),$(`\\lBrace`,"\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}"),$(`\\rBrace`,"\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}"),$(`⦃`,`\\lBrace`),$(`⦄`,`\\rBrace`),$(`\\minuso`,"\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}"),$(`⦵`,`\\minuso`),$(`\\darr`,`\\downarrow`),$(`\\dArr`,`\\Downarrow`),$(`\\Darr`,`\\Downarrow`),$(`\\lang`,`\\langle`),$(`\\rang`,`\\rangle`),$(`\\uarr`,`\\uparrow`),$(`\\uArr`,`\\Uparrow`),$(`\\Uarr`,`\\Uparrow`),$(`\\N`,`\\mathbb{N}`),$(`\\R`,`\\mathbb{R}`),$(`\\Z`,`\\mathbb{Z}`),$(`\\alef`,`\\aleph`),$(`\\alefsym`,`\\aleph`),$(`\\Alpha`,`\\mathrm{A}`),$(`\\Beta`,`\\mathrm{B}`),$(`\\bull`,`\\bullet`),$(`\\Chi`,`\\mathrm{X}`),$(`\\clubs`,`\\clubsuit`),$(`\\cnums`,`\\mathbb{C}`),$(`\\Complex`,`\\mathbb{C}`),$(`\\Dagger`,`\\ddagger`),$(`\\diamonds`,`\\diamondsuit`),$(`\\empty`,`\\emptyset`),$(`\\Epsilon`,`\\mathrm{E}`),$(`\\Eta`,`\\mathrm{H}`),$(`\\exist`,`\\exists`),$(`\\harr`,`\\leftrightarrow`),$(`\\hArr`,`\\Leftrightarrow`),$(`\\Harr`,`\\Leftrightarrow`),$(`\\hearts`,`\\heartsuit`),$(`\\image`,`\\Im`),$(`\\infin`,`\\infty`),$(`\\Iota`,`\\mathrm{I}`),$(`\\isin`,`\\in`),$(`\\Kappa`,`\\mathrm{K}`),$(`\\larr`,`\\leftarrow`),$(`\\lArr`,`\\Leftarrow`),$(`\\Larr`,`\\Leftarrow`),$(`\\lrarr`,`\\leftrightarrow`),$(`\\lrArr`,`\\Leftrightarrow`),$(`\\Lrarr`,`\\Leftrightarrow`),$(`\\Mu`,`\\mathrm{M}`),$(`\\natnums`,`\\mathbb{N}`),$(`\\Nu`,`\\mathrm{N}`),$(`\\Omicron`,`\\mathrm{O}`),$(`\\plusmn`,`\\pm`),$(`\\rarr`,`\\rightarrow`),$(`\\rArr`,`\\Rightarrow`),$(`\\Rarr`,`\\Rightarrow`),$(`\\real`,`\\Re`),$(`\\reals`,`\\mathbb{R}`),$(`\\Reals`,`\\mathbb{R}`),$(`\\Rho`,`\\mathrm{P}`),$(`\\sdot`,`\\cdot`),$(`\\sect`,`\\S`),$(`\\spades`,`\\spadesuit`),$(`\\sub`,`\\subset`),$(`\\sube`,`\\subseteq`),$(`\\supe`,`\\supseteq`),$(`\\Tau`,`\\mathrm{T}`),$(`\\thetasym`,`\\vartheta`),$(`\\weierp`,`\\wp`),$(`\\Zeta`,`\\mathrm{Z}`),$(`\\argmin`,`\\DOTSB\\operatorname*{arg\\,min}`),$(`\\argmax`,`\\DOTSB\\operatorname*{arg\\,max}`),$(`\\plim`,`\\DOTSB\\mathop{\\operatorname{plim}}\\limits`),$(`\\bra`,`\\mathinner{\\langle{#1}|}`),$(`\\ket`,`\\mathinner{|{#1}\\rangle}`),$(`\\braket`,`\\mathinner{\\langle{#1}\\rangle}`),$(`\\Bra`,`\\left\\langle#1\\right|`),$(`\\Ket`,`\\left|#1\\right\\rangle`);var da=e=>t=>{var n=t.consumeArg().tokens,r=t.consumeArg().tokens,i=t.consumeArg().tokens,a=t.consumeArg().tokens,o=t.macros.get(`|`),s=t.macros.get(`\\|`);t.macros.beginGroup();var c=t=>n=>{e&&(n.macros.set(`|`,o),i.length&&n.macros.set(`\\|`,s));var a=t;return!t&&i.length&&n.future().text===`|`&&(n.popToken(),a=!0),{tokens:a?i:r,numArgs:0}};t.macros.set(`|`,c(!1)),i.length&&t.macros.set(`\\|`,c(!0));var l=t.consumeArg().tokens,u=t.expandTokens([...a,...l,...n]);return t.macros.endGroup(),{tokens:u.reverse(),numArgs:0}};$(`\\bra@ket`,da(!1)),$(`\\bra@set`,da(!0)),$(`\\Braket`,`\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}`),$(`\\Set`,`\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}`),$(`\\set`,`\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}`),$(`\\angln`,`{\\angl n}`),$(`\\blue`,`\\textcolor{##6495ed}{#1}`),$(`\\orange`,`\\textcolor{##ffa500}{#1}`),$(`\\pink`,`\\textcolor{##ff00af}{#1}`),$(`\\red`,`\\textcolor{##df0030}{#1}`),$(`\\green`,`\\textcolor{##28ae7b}{#1}`),$(`\\gray`,`\\textcolor{gray}{#1}`),$(`\\purple`,`\\textcolor{##9d38bd}{#1}`),$(`\\blueA`,`\\textcolor{##ccfaff}{#1}`),$(`\\blueB`,`\\textcolor{##80f6ff}{#1}`),$(`\\blueC`,`\\textcolor{##63d9ea}{#1}`),$(`\\blueD`,`\\textcolor{##11accd}{#1}`),$(`\\blueE`,`\\textcolor{##0c7f99}{#1}`),$(`\\tealA`,`\\textcolor{##94fff5}{#1}`),$(`\\tealB`,`\\textcolor{##26edd5}{#1}`),$(`\\tealC`,`\\textcolor{##01d1c1}{#1}`),$(`\\tealD`,`\\textcolor{##01a995}{#1}`),$(`\\tealE`,`\\textcolor{##208170}{#1}`),$(`\\greenA`,`\\textcolor{##b6ffb0}{#1}`),$(`\\greenB`,`\\textcolor{##8af281}{#1}`),$(`\\greenC`,`\\textcolor{##74cf70}{#1}`),$(`\\greenD`,`\\textcolor{##1fab54}{#1}`),$(`\\greenE`,`\\textcolor{##0d923f}{#1}`),$(`\\goldA`,`\\textcolor{##ffd0a9}{#1}`),$(`\\goldB`,`\\textcolor{##ffbb71}{#1}`),$(`\\goldC`,`\\textcolor{##ff9c39}{#1}`),$(`\\goldD`,`\\textcolor{##e07d10}{#1}`),$(`\\goldE`,`\\textcolor{##a75a05}{#1}`),$(`\\redA`,`\\textcolor{##fca9a9}{#1}`),$(`\\redB`,`\\textcolor{##ff8482}{#1}`),$(`\\redC`,`\\textcolor{##f9685d}{#1}`),$(`\\redD`,`\\textcolor{##e84d39}{#1}`),$(`\\redE`,`\\textcolor{##bc2612}{#1}`),$(`\\maroonA`,`\\textcolor{##ffbde0}{#1}`),$(`\\maroonB`,`\\textcolor{##ff92c6}{#1}`),$(`\\maroonC`,`\\textcolor{##ed5fa6}{#1}`),$(`\\maroonD`,`\\textcolor{##ca337c}{#1}`),$(`\\maroonE`,`\\textcolor{##9e034e}{#1}`),$(`\\purpleA`,`\\textcolor{##ddd7ff}{#1}`),$(`\\purpleB`,`\\textcolor{##c6b9fc}{#1}`),$(`\\purpleC`,`\\textcolor{##aa87ff}{#1}`),$(`\\purpleD`,`\\textcolor{##7854ab}{#1}`),$(`\\purpleE`,`\\textcolor{##543b78}{#1}`),$(`\\mintA`,`\\textcolor{##f5f9e8}{#1}`),$(`\\mintB`,`\\textcolor{##edf2df}{#1}`),$(`\\mintC`,`\\textcolor{##e0e5cc}{#1}`),$(`\\grayA`,`\\textcolor{##f6f7f7}{#1}`),$(`\\grayB`,`\\textcolor{##f0f1f2}{#1}`),$(`\\grayC`,`\\textcolor{##e3e5e6}{#1}`),$(`\\grayD`,`\\textcolor{##d6d8da}{#1}`),$(`\\grayE`,`\\textcolor{##babec2}{#1}`),$(`\\grayF`,`\\textcolor{##888d93}{#1}`),$(`\\grayG`,`\\textcolor{##626569}{#1}`),$(`\\grayH`,`\\textcolor{##3b3e40}{#1}`),$(`\\grayI`,`\\textcolor{##21242c}{#1}`),$(`\\kaBlue`,`\\textcolor{##314453}{#1}`),$(`\\kaGreen`,`\\textcolor{##71B307}{#1}`);var fa={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0},pa=class{constructor(e,t,n){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=t,this.expansionCount=0,this.feed(e),this.macros=new ra(ia,t.macros),this.mode=n,this.stack=[]}feed(e){this.lexer=new na(e,this.settings)}switchMode(e){this.mode=e}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return this.stack.length===0&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(e){this.stack.push(e)}pushTokens(e){this.stack.push(...e)}scanArgument(e){var t,n,r;if(e){if(this.consumeSpaces(),this.future().text!==`[`)return null;t=this.popToken(),{tokens:r,end:n}=this.consumeArg([`]`])}else({tokens:r,start:t,end:n}=this.consumeArg());return this.pushToken(new ri(`EOF`,n.loc)),this.pushTokens(r),new ri(``,ni.range(t,n))}consumeSpaces(){for(;this.future().text===` `;)this.stack.pop()}consumeArg(t){var n=[],r=t&&t.length>0;r||this.consumeSpaces();var i=this.future(),a,o=0,s=0;do{if(a=this.popToken(),n.push(a),a.text===`{`)++o;else if(a.text===`}`){if(--o,o===-1)throw new e(`Extra }`,a)}else if(a.text===`EOF`)throw new e(`Unexpected end of input in a macro argument, expected '`+(t&&r?t[s]:`}`)+`'`,a);if(t&&r){if((o===0||o===1&&t[s]===`{`)&&a.text===t[s]){if(++s,s===t.length){n.splice(-s,s);break}}else s=0}}while(o!==0||r);return i.text===`{`&&n[n.length-1].text===`}`&&(n.pop(),n.shift()),n.reverse(),{tokens:n,start:i,end:a}}consumeArgs(t,n){if(n){if(n.length!==t+1)throw new e(`The length of delimiters doesn't match the number of args!`);for(var r=n[0],i=0;ithis.settings.maxExpand)throw new e(`Too many expansions: infinite loop or need to increase maxExpand setting`)}expandOnce(t){var n=this.popToken(),r=n.text,i=n.noexpand?null:this._getExpansion(r);if(i==null||t&&i.unexpandable){if(t&&i==null&&r[0]===`\\`&&!this.isDefined(r))throw new e(`Undefined control sequence: `+r);return this.pushToken(n),!1}this.countExpansion(1);var a=i.tokens,o=this.consumeArgs(i.numArgs,i.delimiters);if(i.numArgs){a=a.slice();for(var s=a.length-1;s>=0;--s){var c=a[s];if(c.text===`#`){if(s===0)throw new e(`Incomplete placeholder at end of macro body`,c);if(c=a[--s],c.text===`#`)a.splice(s+1,1);else if(/^[1-9]$/.test(c.text))a.splice(s,2,...o[c.text-1]);else throw new e(`Not a valid argument number`,c)}}}return this.pushTokens(a),a.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(this.expandOnce()===!1){var e=this.stack.pop();return e.treatAsRelax&&(e.text=`\\relax`),e}}expandMacro(e){return this.macros.has(e)?this.expandTokens([new ri(e)]):void 0}expandTokens(e){var t=[],n=this.stack.length;for(this.pushTokens(e);this.stack.length>n;)if(this.expandOnce(!0)===!1){var r=this.stack.pop();r.treatAsRelax&&=(r.noexpand=!1,!1),t.push(r)}return this.countExpansion(t.length),t}expandMacroAsText(e){var t=this.expandMacro(e);return t&&t.map(e=>e.text).join(``)}_getExpansion(e){var t=this.macros.get(e);if(t==null)return t;if(e.length===1){var n=this.lexer.catcodes[e];if(n!=null&&n!==13)return}var r=typeof t==`function`?t(this):t;if(typeof r==`string`){var i=0;if(r.includes(`#`))for(var a=r.replace(/##/g,``);a.includes(`#`+(i+1));)++i;for(var o=new na(r,this.settings),s=[],c=o.lex();c.text!==`EOF`;)s.push(c),c=o.lex();return s.reverse(),{tokens:s,numArgs:i}}return r}isDefined(e){return this.macros.has(e)||qi.hasOwnProperty(e)||A.math.hasOwnProperty(e)||A.text.hasOwnProperty(e)||fa.hasOwnProperty(e)}isExpandable(e){var t=this.macros.get(e);return t==null?qi.hasOwnProperty(e)&&!qi[e].primitive:typeof t==`string`||typeof t==`function`||!t.unexpandable}},ma=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,ha=Object.freeze({"₊":`+`,"₋":`-`,"₌":`=`,"₍":`(`,"₎":`)`,"₀":`0`,"₁":`1`,"₂":`2`,"₃":`3`,"₄":`4`,"₅":`5`,"₆":`6`,"₇":`7`,"₈":`8`,"₉":`9`,ₐ:`a`,ₑ:`e`,ₕ:`h`,ᵢ:`i`,ⱼ:`j`,ₖ:`k`,ₗ:`l`,ₘ:`m`,ₙ:`n`,ₒ:`o`,ₚ:`p`,ᵣ:`r`,ₛ:`s`,ₜ:`t`,ᵤ:`u`,ᵥ:`v`,ₓ:`x`,ᵦ:`β`,ᵧ:`γ`,ᵨ:`ρ`,ᵩ:`ϕ`,ᵪ:`χ`,"⁺":`+`,"⁻":`-`,"⁼":`=`,"⁽":`(`,"⁾":`)`,"⁰":`0`,"¹":`1`,"²":`2`,"³":`3`,"⁴":`4`,"⁵":`5`,"⁶":`6`,"⁷":`7`,"⁸":`8`,"⁹":`9`,ᴬ:`A`,ᴮ:`B`,ᴰ:`D`,ᴱ:`E`,ᴳ:`G`,ᴴ:`H`,ᴵ:`I`,ᴶ:`J`,ᴷ:`K`,ᴸ:`L`,ᴹ:`M`,ᴺ:`N`,ᴼ:`O`,ᴾ:`P`,ᴿ:`R`,ᵀ:`T`,ᵁ:`U`,ⱽ:`V`,ᵂ:`W`,ᵃ:`a`,ᵇ:`b`,ᶜ:`c`,ᵈ:`d`,ᵉ:`e`,ᶠ:`f`,ᵍ:`g`,ʰ:`h`,ⁱ:`i`,ʲ:`j`,ᵏ:`k`,ˡ:`l`,ᵐ:`m`,ⁿ:`n`,ᵒ:`o`,ᵖ:`p`,ʳ:`r`,ˢ:`s`,ᵗ:`t`,ᵘ:`u`,ᵛ:`v`,ʷ:`w`,ˣ:`x`,ʸ:`y`,ᶻ:`z`,ᵝ:`β`,ᵞ:`γ`,ᵟ:`δ`,ᵠ:`ϕ`,ᵡ:`χ`,ᶿ:`θ`}),ga={"́":{text:`\\'`,math:`\\acute`},"̀":{text:"\\`",math:`\\grave`},"̈":{text:`\\"`,math:`\\ddot`},"̃":{text:`\\~`,math:`\\tilde`},"̄":{text:`\\=`,math:`\\bar`},"̆":{text:`\\u`,math:`\\breve`},"̌":{text:`\\v`,math:`\\check`},"̂":{text:`\\^`,math:`\\hat`},"̇":{text:`\\.`,math:`\\dot`},"̊":{text:`\\r`,math:`\\mathring`},"̋":{text:`\\H`},"̧":{text:`\\c`}},_a={á:`á`,à:`à`,ä:`ä`,ǟ:`ǟ`,ã:`ã`,ā:`ā`,ă:`ă`,ắ:`ắ`,ằ:`ằ`,ẵ:`ẵ`,ǎ:`ǎ`,â:`â`,ấ:`ấ`,ầ:`ầ`,ẫ:`ẫ`,ȧ:`ȧ`,ǡ:`ǡ`,å:`å`,ǻ:`ǻ`,ḃ:`ḃ`,ć:`ć`,ḉ:`ḉ`,č:`č`,ĉ:`ĉ`,ċ:`ċ`,ç:`ç`,ď:`ď`,ḋ:`ḋ`,ḑ:`ḑ`,é:`é`,è:`è`,ë:`ë`,ẽ:`ẽ`,ē:`ē`,ḗ:`ḗ`,ḕ:`ḕ`,ĕ:`ĕ`,ḝ:`ḝ`,ě:`ě`,ê:`ê`,ế:`ế`,ề:`ề`,ễ:`ễ`,ė:`ė`,ȩ:`ȩ`,ḟ:`ḟ`,ǵ:`ǵ`,ḡ:`ḡ`,ğ:`ğ`,ǧ:`ǧ`,ĝ:`ĝ`,ġ:`ġ`,ģ:`ģ`,ḧ:`ḧ`,ȟ:`ȟ`,ĥ:`ĥ`,ḣ:`ḣ`,ḩ:`ḩ`,í:`í`,ì:`ì`,ï:`ï`,ḯ:`ḯ`,ĩ:`ĩ`,ī:`ī`,ĭ:`ĭ`,ǐ:`ǐ`,î:`î`,ǰ:`ǰ`,ĵ:`ĵ`,ḱ:`ḱ`,ǩ:`ǩ`,ķ:`ķ`,ĺ:`ĺ`,ľ:`ľ`,ļ:`ļ`,ḿ:`ḿ`,ṁ:`ṁ`,ń:`ń`,ǹ:`ǹ`,ñ:`ñ`,ň:`ň`,ṅ:`ṅ`,ņ:`ņ`,ó:`ó`,ò:`ò`,ö:`ö`,ȫ:`ȫ`,õ:`õ`,ṍ:`ṍ`,ṏ:`ṏ`,ȭ:`ȭ`,ō:`ō`,ṓ:`ṓ`,ṑ:`ṑ`,ŏ:`ŏ`,ǒ:`ǒ`,ô:`ô`,ố:`ố`,ồ:`ồ`,ỗ:`ỗ`,ȯ:`ȯ`,ȱ:`ȱ`,ő:`ő`,ṕ:`ṕ`,ṗ:`ṗ`,ŕ:`ŕ`,ř:`ř`,ṙ:`ṙ`,ŗ:`ŗ`,ś:`ś`,ṥ:`ṥ`,š:`š`,ṧ:`ṧ`,ŝ:`ŝ`,ṡ:`ṡ`,ş:`ş`,ẗ:`ẗ`,ť:`ť`,ṫ:`ṫ`,ţ:`ţ`,ú:`ú`,ù:`ù`,ü:`ü`,ǘ:`ǘ`,ǜ:`ǜ`,ǖ:`ǖ`,ǚ:`ǚ`,ũ:`ũ`,ṹ:`ṹ`,ū:`ū`,ṻ:`ṻ`,ŭ:`ŭ`,ǔ:`ǔ`,û:`û`,ů:`ů`,ű:`ű`,ṽ:`ṽ`,ẃ:`ẃ`,ẁ:`ẁ`,ẅ:`ẅ`,ŵ:`ŵ`,ẇ:`ẇ`,ẘ:`ẘ`,ẍ:`ẍ`,ẋ:`ẋ`,ý:`ý`,ỳ:`ỳ`,ÿ:`ÿ`,ỹ:`ỹ`,ȳ:`ȳ`,ŷ:`ŷ`,ẏ:`ẏ`,ẙ:`ẙ`,ź:`ź`,ž:`ž`,ẑ:`ẑ`,ż:`ż`,Á:`Á`,À:`À`,Ä:`Ä`,Ǟ:`Ǟ`,Ã:`Ã`,Ā:`Ā`,Ă:`Ă`,Ắ:`Ắ`,Ằ:`Ằ`,Ẵ:`Ẵ`,Ǎ:`Ǎ`,Â:`Â`,Ấ:`Ấ`,Ầ:`Ầ`,Ẫ:`Ẫ`,Ȧ:`Ȧ`,Ǡ:`Ǡ`,Å:`Å`,Ǻ:`Ǻ`,Ḃ:`Ḃ`,Ć:`Ć`,Ḉ:`Ḉ`,Č:`Č`,Ĉ:`Ĉ`,Ċ:`Ċ`,Ç:`Ç`,Ď:`Ď`,Ḋ:`Ḋ`,Ḑ:`Ḑ`,É:`É`,È:`È`,Ë:`Ë`,Ẽ:`Ẽ`,Ē:`Ē`,Ḗ:`Ḗ`,Ḕ:`Ḕ`,Ĕ:`Ĕ`,Ḝ:`Ḝ`,Ě:`Ě`,Ê:`Ê`,Ế:`Ế`,Ề:`Ề`,Ễ:`Ễ`,Ė:`Ė`,Ȩ:`Ȩ`,Ḟ:`Ḟ`,Ǵ:`Ǵ`,Ḡ:`Ḡ`,Ğ:`Ğ`,Ǧ:`Ǧ`,Ĝ:`Ĝ`,Ġ:`Ġ`,Ģ:`Ģ`,Ḧ:`Ḧ`,Ȟ:`Ȟ`,Ĥ:`Ĥ`,Ḣ:`Ḣ`,Ḩ:`Ḩ`,Í:`Í`,Ì:`Ì`,Ï:`Ï`,Ḯ:`Ḯ`,Ĩ:`Ĩ`,Ī:`Ī`,Ĭ:`Ĭ`,Ǐ:`Ǐ`,Î:`Î`,İ:`İ`,Ĵ:`Ĵ`,Ḱ:`Ḱ`,Ǩ:`Ǩ`,Ķ:`Ķ`,Ĺ:`Ĺ`,Ľ:`Ľ`,Ļ:`Ļ`,Ḿ:`Ḿ`,Ṁ:`Ṁ`,Ń:`Ń`,Ǹ:`Ǹ`,Ñ:`Ñ`,Ň:`Ň`,Ṅ:`Ṅ`,Ņ:`Ņ`,Ó:`Ó`,Ò:`Ò`,Ö:`Ö`,Ȫ:`Ȫ`,Õ:`Õ`,Ṍ:`Ṍ`,Ṏ:`Ṏ`,Ȭ:`Ȭ`,Ō:`Ō`,Ṓ:`Ṓ`,Ṑ:`Ṑ`,Ŏ:`Ŏ`,Ǒ:`Ǒ`,Ô:`Ô`,Ố:`Ố`,Ồ:`Ồ`,Ỗ:`Ỗ`,Ȯ:`Ȯ`,Ȱ:`Ȱ`,Ő:`Ő`,Ṕ:`Ṕ`,Ṗ:`Ṗ`,Ŕ:`Ŕ`,Ř:`Ř`,Ṙ:`Ṙ`,Ŗ:`Ŗ`,Ś:`Ś`,Ṥ:`Ṥ`,Š:`Š`,Ṧ:`Ṧ`,Ŝ:`Ŝ`,Ṡ:`Ṡ`,Ş:`Ş`,Ť:`Ť`,Ṫ:`Ṫ`,Ţ:`Ţ`,Ú:`Ú`,Ù:`Ù`,Ü:`Ü`,Ǘ:`Ǘ`,Ǜ:`Ǜ`,Ǖ:`Ǖ`,Ǚ:`Ǚ`,Ũ:`Ũ`,Ṹ:`Ṹ`,Ū:`Ū`,Ṻ:`Ṻ`,Ŭ:`Ŭ`,Ǔ:`Ǔ`,Û:`Û`,Ů:`Ů`,Ű:`Ű`,Ṽ:`Ṽ`,Ẃ:`Ẃ`,Ẁ:`Ẁ`,Ẅ:`Ẅ`,Ŵ:`Ŵ`,Ẇ:`Ẇ`,Ẍ:`Ẍ`,Ẋ:`Ẋ`,Ý:`Ý`,Ỳ:`Ỳ`,Ÿ:`Ÿ`,Ỹ:`Ỹ`,Ȳ:`Ȳ`,Ŷ:`Ŷ`,Ẏ:`Ẏ`,Ź:`Ź`,Ž:`Ž`,Ẑ:`Ẑ`,Ż:`Ż`,ά:`ά`,ὰ:`ὰ`,ᾱ:`ᾱ`,ᾰ:`ᾰ`,έ:`έ`,ὲ:`ὲ`,ή:`ή`,ὴ:`ὴ`,ί:`ί`,ὶ:`ὶ`,ϊ:`ϊ`,ΐ:`ΐ`,ῒ:`ῒ`,ῑ:`ῑ`,ῐ:`ῐ`,ό:`ό`,ὸ:`ὸ`,ύ:`ύ`,ὺ:`ὺ`,ϋ:`ϋ`,ΰ:`ΰ`,ῢ:`ῢ`,ῡ:`ῡ`,ῠ:`ῠ`,ώ:`ώ`,ὼ:`ὼ`,Ύ:`Ύ`,Ὺ:`Ὺ`,Ϋ:`Ϋ`,Ῡ:`Ῡ`,Ῠ:`Ῠ`,Ώ:`Ώ`,Ὼ:`Ὼ`},va=class t{constructor(e,t){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode=`math`,this.gullet=new pa(e,t,this.mode),this.settings=t,this.leftrightDepth=0,this.nextToken=null}expect(t,n){if(n===void 0&&(n=!0),this.fetch().text!==t)throw new e(`Expected '`+t+`', got '`+this.fetch().text+`'`,this.fetch());n&&this.consume()}consume(){this.nextToken=null}fetch(){return this.nextToken??=this.gullet.expandNextToken(),this.nextToken}switchMode(e){this.mode=e,this.gullet.switchMode(e)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set(`\\color`,`\\textcolor`);try{var e=this.parseExpression(!1);return this.expect(`EOF`),this.settings.globalGroup||this.gullet.endGroup(),e}finally{this.gullet.endGroups()}}subparse(e){var t=this.nextToken;this.consume(),this.gullet.pushToken(new ri(`}`)),this.gullet.pushTokens(e);var n=this.parseExpression(!1);return this.expect(`}`),this.nextToken=t,n}parseExpression(e,n){for(var r=[];;){this.mode===`math`&&this.consumeSpaces();var i=this.fetch();if(t.endOfExpression.has(i.text)||n&&i.text===n||e&&qi[i.text]&&qi[i.text].infix)break;var a=this.parseAtom(n);if(!a)break;a.type!==`internal`&&r.push(a)}return this.mode===`text`&&this.formLigatures(r),this.handleInfixNodes(r)}handleInfixNodes(t){for(var n=-1,r,i=0;i=128)this.settings.strict&&(ce(n.charCodeAt(0))?this.mode===`math`&&this.settings.reportNonstrict(`unicodeTextInMathMode`,`Unicode text character "`+n[0]+`" used in math mode`,t):this.settings.reportNonstrict(`unknownSymbol`,`Unrecognized Unicode character "`+n[0]+`"`+(` (`+n.charCodeAt(0)+`)`),t)),o={type:`textord`,mode:`text`,loc:ni.range(t),text:n};else return null;if(this.consume(),a)for(var l=0;lt?1:e>=t?0:NaN}function d(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function f(e){let t,n,r;e.length===2?(t=e===u||e===d?e:p,n=e,r=e):(t=u,n=(t,n)=>u(e(t),n),r=(t,n)=>e(t)-n);function i(e,r,i=0,a=e.length){if(i>>1;n(e[t],r)<0?i=t+1:a=t}while(i>>1;n(e[t],r)<=0?i=t+1:a=t}while(in&&r(e[o-1],t)>-r(e[o],t)?o-1:o}return{left:i,center:o,right:a}}function p(){return 0}function m(e){return e===null?NaN:+e}var h=f(u),g=h.right;h.left,f(m).center;var _=Math.sqrt(50),v=Math.sqrt(10),y=Math.sqrt(2);function b(e,t,n){let r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/10**i,o=a>=_?10:a>=v?5:a>=y?2:1,s,c,l;return i<0?(l=10**-i/o,s=Math.round(e*l),c=Math.round(t*l),s/lt&&--c,l=-l):(l=10**i*o,s=Math.round(e/l),c=Math.round(t/l),s*lt&&--c),c0))return[];if(e===t)return[e];let r=t=i))return[];let s=a-i+1,c=Array(s);if(r){if(o<0)for(let e=0;et&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}function B(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i2?V:B,l=u=null,f}function f(t){return t==null||isNaN(t=+t)?o:(l||=c(e.map(i),n,r))(i(s(t)))}return f.invert=function(r){return s(a((u||=c(n,e.map(i),t))(r)))},f.domain=function(t){return arguments.length?(e=Array.from(t,F),d()):e.slice()},f.range=function(e){return arguments.length?(n=Array.from(e),d()):n.slice()},f.rangeRound=function(e){return n=Array.from(e),r=A,d()},f.clamp=function(e){return arguments.length?(s=e?!0:L,d()):s!==L},f.interpolate=function(e){return arguments.length?(r=e,d()):r},f.unknown=function(e){return arguments.length?(o=e,f):o},function(e,t){return i=e,a=t,d()}}function W(){return U()(L,L)}function G(e,t,n,r){var i=C(e,t,n),a;switch(r=s(r??`,f`),r.type){case`s`:var l=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=M(i,l))&&(r.precision=a),o(r,l);case``:case`e`:case`g`:case`p`:case`r`:r.precision==null&&!isNaN(a=N(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type===`e`));break;case`f`:case`%`:r.precision==null&&!isNaN(a=j(i))&&(r.precision=a-(r.type===`%`)*2)}return c(r)}function K(e){var t=e.domain;return e.ticks=function(e){var n=t();return x(n[0],n[n.length-1],e??10)},e.tickFormat=function(e,n){var r=t();return G(r[0],r[r.length-1],e??10,n)},e.nice=function(n){n??=10;var r=t(),i=0,a=r.length-1,o=r[i],s=r[a],c,l,u=10;for(s0;){if(l=S(o,s,n),l===c)return r[i]=o,r[a]=s,t(r);if(l>0)o=Math.floor(o/l)*l,s=Math.ceil(s/l)*l;else if(l<0)o=Math.ceil(o*l)/l,s=Math.floor(s*l)/l;else break;c=l}return e},e}function q(){var e=W();return e.copy=function(){return H(e,q())},l.apply(e,arguments),K(e)}export{f as a,C as i,W as n,H as r,q as t}; \ No newline at end of file diff --git a/frontend/dist/assets/mermaid-parser.core-CUrDj5TF.js b/frontend/dist/assets/mermaid-parser.core-CUrDj5TF.js new file mode 100644 index 0000000..1ff5673 --- /dev/null +++ b/frontend/dist/assets/mermaid-parser.core-CUrDj5TF.js @@ -0,0 +1,7 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/info-A6RAGUB7-CjXYSfue.js","assets/chunk-FOHPRMQF-DHwB1DNv.js","assets/packet-AYTQ26CC-f7lhlK2y.js","assets/pie-WAS4IAKB-BbyREufe.js","assets/treeView-Q6P3EWNA-Bck3TsQB.js","assets/architecture-7GRP2DOG-B7cjyaKW.js","assets/gitGraph-4MIJSDKK-DroQcAWn.js","assets/eventmodeling-NTZA5JFV-CetGhGTA.js","assets/radar-RG4KPBEZ-BsN_WAuk.js","assets/railroad-74A4TZTK-CYJJ-7AP.js","assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js","assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js","assets/railroad-peg-WCYAUIDC-CNjo3yz4.js","assets/treemap-WGGIJYW6-BVec3Jfs.js","assets/wardley-WFR3VGLG-kIjJw24i.js","assets/cynefin-OW5HDTMX-DebjIew_.js"])))=>i.map(i=>d[i]); +import{et as e}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{C as t,S as n,_ as r,a as i,b as a,c as o,d as ee,f as te,g as ne,h as re,i as s,l as ie,m as ae,n as c,o as l,p as oe,r as se,s as ce,t as u,u as d,v as le,w as f,x as p,y as ue}from"./chunk-FOHPRMQF-DHwB1DNv.js";var de=class extends u{static{p(this,`ArchitectureTokenBuilder`)}constructor(){super([`architecture`])}},fe=class extends c{static{p(this,`ArchitectureValueConverter`)}runCustomConverter(e,t,n){if(e.name===`ARCH_ICON`)return t.replace(/[()]/g,``).trim();if(e.name===`ARCH_TEXT_ICON`)return t.replace(/["()]/g,``);if(e.name===`ARCH_TITLE`){let e=t.replace(/^\[|]$/g,``).trim();return(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))&&(e=e.slice(1,-1),e=e.replace(/\\"/g,`"`).replace(/\\'/g,`'`)),e.trim()}}},m={parser:{TokenBuilder:p(()=>new de,`TokenBuilder`),ValueConverter:p(()=>new fe,`ValueConverter`)}};function h(e=l){let r=f(t(e),d),i=f(n({shared:r}),se,m);return r.ServiceRegistry.register(i),{shared:r,Architecture:i}}p(h,`createArchitectureServices`);var pe=class extends u{static{p(this,`CynefinTokenBuilder`)}constructor(){super([`cynefin-beta`])}},g={parser:{TokenBuilder:p(()=>new pe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function _(e=l){let r=f(t(e),d),a=f(n({shared:r}),i,g);return r.ServiceRegistry.register(a),{shared:r,Cynefin:a}}p(_,`createCynefinServices`);var me=class extends u{static{p(this,`EventModelingTokenBuilder`)}constructor(){super([`eventmodeling`])}},v=new Set([`cmd`,`command`]),y=new Set([`evt`,`event`]),b=new Set([`rmo`,`readmodel`]),x=new Set([`pcr`,`processor`]),S=new Set([`ui`]);function C(e){let t=e.validation.EventModelingValidator,n=e.validation.ValidationRegistry;if(n){let e={EmTimeFrame:t.checkSourceFrameTypes.bind(t),EmResetFrame:t.checkSourceFrameTypes.bind(t)};n.register(e,t)}}p(C,`registerValidationChecks`);var he=class{static{p(this,`EventModelingValidator`)}checkSourceFrameTypes(e,t){e.sourceFrames.length!==0&&(v.has(e.modelEntityType)?this.validateSources(e,new Set([...S,...x]),`command`,`ui or processor`,t):y.has(e.modelEntityType)?this.validateSources(e,v,`event`,`command`,t):b.has(e.modelEntityType)?this.validateSources(e,y,`read model`,`event`,t):x.has(e.modelEntityType)?this.validateSources(e,b,`processor`,`read model`,t):S.has(e.modelEntityType)&&this.validateSources(e,b,`ui`,`read model`,t))}validateSources(e,t,n,r,i){for(let a of e.sourceFrames){let o=a.ref;o!==void 0&&!t.has(o.modelEntityType)&&i(`error`,`A ${n} can only receive input from a ${r}, not from '${o.modelEntityType}'.`,{node:e,property:`sourceFrames`})}}},w={parser:{TokenBuilder:p(()=>new me,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)},validation:{EventModelingValidator:p(()=>new he,`EventModelingValidator`)}};function T(e=l){let r=f(t(e),d),i=f(n({shared:r}),ce,w);return r.ServiceRegistry.register(i),C(i),{shared:r,EventModel:i}}p(T,`createEventModelingServices`);var ge=class extends u{static{p(this,`GitGraphTokenBuilder`)}constructor(){super([`gitGraph`])}},E={parser:{TokenBuilder:p(()=>new ge,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function D(e=l){let r=f(t(e),d),i=f(n({shared:r}),o,E);return r.ServiceRegistry.register(i),{shared:r,GitGraph:i}}p(D,`createGitGraphServices`);var _e=class extends u{static{p(this,`InfoTokenBuilder`)}constructor(){super([`info`,`showInfo`])}},O={parser:{TokenBuilder:p(()=>new _e,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function k(e=l){let r=f(t(e),d),i=f(n({shared:r}),ie,O);return r.ServiceRegistry.register(i),{shared:r,Info:i}}p(k,`createInfoServices`);var ve=class extends u{static{p(this,`PacketTokenBuilder`)}constructor(){super([`packet`])}},A={parser:{TokenBuilder:p(()=>new ve,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function j(e=l){let r=f(t(e),d),i=f(n({shared:r}),ee,A);return r.ServiceRegistry.register(i),{shared:r,Packet:i}}p(j,`createPacketServices`);var ye=class extends u{static{p(this,`PieTokenBuilder`)}constructor(){super([`pie`,`showData`])}},be=class extends c{static{p(this,`PieValueConverter`)}runCustomConverter(e,t,n){if(e.name===`PIE_SECTION_LABEL`)return t.replace(/"/g,``).trim()}},M={parser:{TokenBuilder:p(()=>new ye,`TokenBuilder`),ValueConverter:p(()=>new be,`ValueConverter`)}};function N(e=l){let r=f(t(e),d),i=f(n({shared:r}),te,M);return r.ServiceRegistry.register(i),{shared:r,Pie:i}}p(N,`createPieServices`);var xe=class extends u{static{p(this,`RadarTokenBuilder`)}constructor(){super([`radar-beta`])}},P={parser:{TokenBuilder:p(()=>new xe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function F(e=l){let r=f(t(e),d),i=f(n({shared:r}),oe,P);return r.ServiceRegistry.register(i),{shared:r,Radar:i}}p(F,`createRadarServices`);var Se=class extends u{static{p(this,`RailroadTokenBuilder`)}constructor(){super([`railroad-beta`])}},I=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew Se,`TokenBuilder`),ValueConverter:p(()=>new Ce,`ValueConverter`)}};function we(e=l){let r=f(t(e),d),i=f(n({shared:r}),ne,L);return r.ServiceRegistry.register(i),{shared:r,Railroad:i}}p(we,`createRailroadServices`);var Te=class extends u{static{p(this,`RailroadAbnfTokenBuilder`)}constructor(){super([`railroad-abnf-beta`])}},Ee=class extends c{static{p(this,`RailroadAbnfValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return e.slice(1,-1)}return r}runCustomConverter(e,t,n){if(e.name===`ABNF_STRING`)return t.slice(1,-1)}},R={parser:{TokenBuilder:p(()=>new Te,`TokenBuilder`),ValueConverter:p(()=>new Ee,`ValueConverter`)}};function z(e=l){let r=f(t(e),d),i=f(n({shared:r}),ae,R);return r.ServiceRegistry.register(i),{shared:r,RailroadAbnf:i}}p(z,`createRailroadAbnfServices`);var De=class extends u{static{p(this,`RailroadEbnfTokenBuilder`)}constructor(){super([`railroad-ebnf-beta`])}},B=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew De,`TokenBuilder`),ValueConverter:p(()=>new Oe,`ValueConverter`)}};function H(e=l){let r=f(t(e),d),i=f(n({shared:r}),re,V);return r.ServiceRegistry.register(i),{shared:r,RailroadEbnf:i}}p(H,`createRailroadEbnfServices`);var ke=class extends u{static{p(this,`RailroadPegTokenBuilder`)}constructor(){super([`railroad-peg-beta`])}},U=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew ke,`TokenBuilder`),ValueConverter:p(()=>new Ae,`ValueConverter`)}};function G(e=l){let i=f(t(e),d),a=f(n({shared:i}),r,W);return i.ServiceRegistry.register(a),{shared:i,RailroadPeg:a}}p(G,`createRailroadPegServices`);var je=class extends c{static{p(this,`TreeViewValueConverter`)}runCustomConverter(e,t,n){if(e.name===`INDENTATION`)return t?.length||0;if(e.name===`QUOTED_NAME`)return t.substring(1,t.length-1);if(e.name===`BARE_NAME`)return t.replace(/[\t ]+$/,``);if(e.name===`CLASS_ANNOTATION`)return t.trim().substring(3).trim();if(e.name===`ICON_ANNOTATION`){let e=t.trim();return e.substring(5,e.length-1)}if(e.name===`DESC_ANNOTATION`)return t.trim().substring(2).trim()}},Me=class extends u{static{p(this,`TreeViewTokenBuilder`)}constructor(){super([`treeView-beta`])}},K={parser:{TokenBuilder:p(()=>new Me,`TokenBuilder`),ValueConverter:p(()=>new je,`ValueConverter`)}};function q(e=l){let r=f(t(e),d),i=f(n({shared:r}),le,K);return r.ServiceRegistry.register(i),{shared:r,TreeView:i}}p(q,`createTreeViewServices`);var Ne=class extends u{static{p(this,`TreemapTokenBuilder`)}constructor(){super([`treemap`])}},Pe=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,Fe=class extends c{static{p(this,`TreemapValueConverter`)}runCustomConverter(e,t,n){if(e.name===`NUMBER2`)return parseFloat(t.replace(/,/g,``));if(e.name===`SEPARATOR`||e.name===`STRING2`)return t.substring(1,t.length-1);if(e.name===`INDENTATION`)return t.length;if(e.name===`ClassDef`){if(typeof t!=`string`)return t;let e=Pe.exec(t);if(e)return{$type:`ClassDefStatement`,className:e[1],styleText:e[2]||void 0}}}};function J(e){let t=e.validation.TreemapValidator,n=e.validation.ValidationRegistry;if(n){let e={Treemap:t.checkSingleRoot.bind(t)};n.register(e,t)}}p(J,`registerValidationChecks`);var Ie=class{static{p(this,`TreemapValidator`)}checkSingleRoot(e,t){let n;for(let r of e.TreemapRows)r.item&&(n===void 0&&r.indent===void 0?n=0:(r.indent===void 0||n!==void 0&&n>=parseInt(r.indent,10))&&t(`error`,`Multiple root nodes are not allowed in a treemap.`,{node:r,property:`item`}))}},Y={parser:{TokenBuilder:p(()=>new Ne,`TokenBuilder`),ValueConverter:p(()=>new Fe,`ValueConverter`)},validation:{TreemapValidator:p(()=>new Ie,`TreemapValidator`)}};function X(e=l){let r=f(t(e),d),i=f(n({shared:r}),ue,Y);return r.ServiceRegistry.register(i),J(i),{shared:r,Treemap:i}}p(X,`createTreemapServices`);var Le=class extends c{static{p(this,`WardleyValueConverter`)}runCustomConverter(e,t,n){switch(e.name.toUpperCase()){case`LINK_LABEL`:return t.substring(1).trim();default:return}}},Z={parser:{ValueConverter:p(()=>new Le,`ValueConverter`)}};function Q(e=l){let r=f(t(e),d),i=f(n({shared:r}),a,Z);return r.ServiceRegistry.register(i),{shared:r,Wardley:i}}p(Q,`createWardleyServices`);var $={},Re={info:p(async()=>{let{createInfoServices:t}=await e(async()=>{let{createInfoServices:e}=await import(`./info-A6RAGUB7-CjXYSfue.js`);return{createInfoServices:e}},__vite__mapDeps([0,1]));$.info=t().Info.parser.LangiumParser},`info`),packet:p(async()=>{let{createPacketServices:t}=await e(async()=>{let{createPacketServices:e}=await import(`./packet-AYTQ26CC-f7lhlK2y.js`);return{createPacketServices:e}},__vite__mapDeps([2,1]));$.packet=t().Packet.parser.LangiumParser},`packet`),pie:p(async()=>{let{createPieServices:t}=await e(async()=>{let{createPieServices:e}=await import(`./pie-WAS4IAKB-BbyREufe.js`);return{createPieServices:e}},__vite__mapDeps([3,1]));$.pie=t().Pie.parser.LangiumParser},`pie`),treeView:p(async()=>{let{createTreeViewServices:t}=await e(async()=>{let{createTreeViewServices:e}=await import(`./treeView-Q6P3EWNA-Bck3TsQB.js`);return{createTreeViewServices:e}},__vite__mapDeps([4,1]));$.treeView=t().TreeView.parser.LangiumParser},`treeView`),architecture:p(async()=>{let{createArchitectureServices:t}=await e(async()=>{let{createArchitectureServices:e}=await import(`./architecture-7GRP2DOG-B7cjyaKW.js`);return{createArchitectureServices:e}},__vite__mapDeps([5,1]));$.architecture=t().Architecture.parser.LangiumParser},`architecture`),gitGraph:p(async()=>{let{createGitGraphServices:t}=await e(async()=>{let{createGitGraphServices:e}=await import(`./gitGraph-4MIJSDKK-DroQcAWn.js`);return{createGitGraphServices:e}},__vite__mapDeps([6,1]));$.gitGraph=t().GitGraph.parser.LangiumParser},`gitGraph`),eventmodeling:p(async()=>{let{createEventModelingServices:t}=await e(async()=>{let{createEventModelingServices:e}=await import(`./eventmodeling-NTZA5JFV-CetGhGTA.js`);return{createEventModelingServices:e}},__vite__mapDeps([7,1]));$.eventmodeling=t().EventModel.parser.LangiumParser},`eventmodeling`),radar:p(async()=>{let{createRadarServices:t}=await e(async()=>{let{createRadarServices:e}=await import(`./radar-RG4KPBEZ-BsN_WAuk.js`);return{createRadarServices:e}},__vite__mapDeps([8,1]));$.radar=t().Radar.parser.LangiumParser},`radar`),railroad:p(async()=>{let{createRailroadServices:t}=await e(async()=>{let{createRailroadServices:e}=await import(`./railroad-74A4TZTK-CYJJ-7AP.js`);return{createRailroadServices:e}},__vite__mapDeps([9,1]));$.railroad=t().Railroad.parser.LangiumParser},`railroad`),railroadEbnf:p(async()=>{let{createRailroadEbnfServices:t}=await e(async()=>{let{createRailroadEbnfServices:e}=await import(`./railroad-ebnf-LZEXJU2U-BuSvGFsc.js`);return{createRailroadEbnfServices:e}},__vite__mapDeps([10,1]));$.railroadEbnf=t().RailroadEbnf.parser.LangiumParser},`railroadEbnf`),railroadAbnf:p(async()=>{let{createRailroadAbnfServices:t}=await e(async()=>{let{createRailroadAbnfServices:e}=await import(`./railroad-abnf-HS5TGJTU-XdDFvlUB.js`);return{createRailroadAbnfServices:e}},__vite__mapDeps([11,1]));$.railroadAbnf=t().RailroadAbnf.parser.LangiumParser},`railroadAbnf`),railroadPeg:p(async()=>{let{createRailroadPegServices:t}=await e(async()=>{let{createRailroadPegServices:e}=await import(`./railroad-peg-WCYAUIDC-CNjo3yz4.js`);return{createRailroadPegServices:e}},__vite__mapDeps([12,1]));$.railroadPeg=t().RailroadPeg.parser.LangiumParser},`railroadPeg`),treemap:p(async()=>{let{createTreemapServices:t}=await e(async()=>{let{createTreemapServices:e}=await import(`./treemap-WGGIJYW6-BVec3Jfs.js`);return{createTreemapServices:e}},__vite__mapDeps([13,1]));$.treemap=t().Treemap.parser.LangiumParser},`treemap`),wardley:p(async()=>{let{createWardleyServices:t}=await e(async()=>{let{createWardleyServices:e}=await import(`./wardley-WFR3VGLG-kIjJw24i.js`);return{createWardleyServices:e}},__vite__mapDeps([14,1]));$.wardley=t().Wardley.parser.LangiumParser},`wardley`),cynefin:p(async()=>{let{createCynefinServices:t}=await e(async()=>{let{createCynefinServices:e}=await import(`./cynefin-OW5HDTMX-DebjIew_.js`);return{createCynefinServices:e}},__vite__mapDeps([15,1]));$.cynefin=t().Cynefin.parser.LangiumParser},`cynefin`)};async function ze(e,t){let n=Re[e];if(!n)throw Error(`Unknown diagram type: ${e}`);$[e]||await n();let r=$[e].parse(t);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new Be(r);return r.value}p(ze,`parse`);var Be=class extends Error{constructor(e){let t=e.lexerErrors.map(e=>`Lexer error on line ${e.line!==void 0&&!isNaN(e.line)?e.line:`?`}, column ${e.column!==void 0&&!isNaN(e.column)?e.column:`?`}: ${e.message}`).join(` +`),n=e.parserErrors.map(e=>`Parse error on line ${e.token.startLine!==void 0&&!isNaN(e.token.startLine)?e.token.startLine:`?`}, column ${e.token.startColumn!==void 0&&!isNaN(e.token.startColumn)?e.token.startColumn:`?`}: ${e.message}`).join(` +`);super(`Parsing failed: ${t} ${n}`),this.result=e}static{p(this,`MermaidParseError`)}};export{_ as A,O as C,w as D,D as E,h as M,T as O,j as S,E as T,P as _,Y as a,N as b,q as c,V as d,H as f,we as g,L as h,Q as i,m as j,g as k,W as l,z as m,ze as n,X as o,R as p,Z as r,K as s,Be as t,G as u,F as v,k as w,A as x,M as y}; \ No newline at end of file diff --git a/frontend/dist/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js b/frontend/dist/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js new file mode 100644 index 0000000..8fb267b --- /dev/null +++ b/frontend/dist/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js @@ -0,0 +1,96 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{at as n,b as r,f as i,k as a,nt as o,rt as s,x as c,z as l}from"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as u,t as d}from"./index-DoQkmpth.js";import{t as f}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as p}from"./chunk-WEXAMYUT-I3m-hOmT.js";var m=[];for(let e=0;e<256;++e)m.push((e+256).toString(16).slice(1));function h(e,t=0){return(m[e[t+0]]+m[e[t+1]]+m[e[t+2]]+m[e[t+3]]+`-`+m[e[t+4]]+m[e[t+5]]+`-`+m[e[t+6]]+m[e[t+7]]+`-`+m[e[t+8]]+m[e[t+9]]+`-`+m[e[t+10]]+m[e[t+11]]+m[e[t+12]]+m[e[t+13]]+m[e[t+14]]+m[e[t+15]]).toLowerCase()}var g=new Uint8Array(16);function _(){return crypto.getRandomValues(g)}function v(e,t,n){return!t&&!e&&crypto.randomUUID?crypto.randomUUID():y(e,t,n)}function y(e,t,n){e||={};let r=e.random??e.rng?.()??_();if(r.length<16)throw Error(`Random bytes length must be >= 16`);if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){if(n||=0,n<0||n+16>t.length)throw RangeError(`UUID byte range ${n}:${n+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[n+e]=r[e];return t}return h(r)}var b=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,13],i=[1,12],a=[1,15],o=[1,16],s=[1,20],c=[1,19],l=[6,7,8],u=[1,26],d=[1,24],f=[1,25],p=[6,7,11],m=[1,6,13,15,16,19,22],h=[1,33],g=[1,34],_=[1,6,7,11,13,15,16,19,22],v={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`MINDMAP`,11:`EOF`,13:`SPACELIST`,15:`ICON`,16:`CLASS`,19:`NODE_DSTART`,20:`NODE_DESCR`,21:`NODE_DEND`,22:`NODE_ID`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace(`Stop NL `);break;case 9:r.getLogger().trace(`Stop EOF `);break;case 11:r.getLogger().trace(`Stop NL2 `);break;case 12:r.getLogger().trace(`Stop EOF2 `);break;case 15:r.getLogger().info(`Node: `,a[s].id),r.addNode(a[s-1].length,a[s].id,a[s].descr,a[s].type);break;case 16:r.getLogger().trace(`Icon: `,a[s]),r.decorateNode({icon:a[s]});break;case 17:case 21:r.decorateNode({class:a[s]});break;case 18:r.getLogger().trace(`SPACELIST`);break;case 19:r.getLogger().trace(`Node: `,a[s].id),r.addNode(0,a[s].id,a[s].descr,a[s].type);break;case 20:r.decorateNode({icon:a[s]});break;case 25:r.getLogger().trace(`node found ..`,a[s-2]),this.$={id:a[s-1],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 26:this.$={id:a[s],descr:a[s],type:r.nodeType.DEFAULT};break;case 27:r.getLogger().trace(`node found ..`,a[s-3]),this.$={id:a[s-3],descr:a[s-1],type:r.getType(a[s-2],a[s])}}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},e(l,[2,3]),{1:[2,2]},e(l,[2,4]),e(l,[2,5]),{1:[2,6],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:r,9:22,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:u,7:d,10:23,11:f},e(p,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:s,22:c}),e(p,[2,18]),e(p,[2,19]),e(p,[2,20]),e(p,[2,21]),e(p,[2,23]),e(p,[2,24]),e(p,[2,26],{19:[1,30]}),{20:[1,31]},{6:u,7:d,10:32,11:f},{1:[2,7],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},e(m,[2,14],{7:h,11:g}),e(_,[2,8]),e(_,[2,9]),e(_,[2,10]),e(p,[2,15]),e(p,[2,16]),e(p,[2,17]),{20:[1,35]},{21:[1,36]},e(m,[2,13],{7:h,11:g}),e(_,[2,11]),e(_,[2,12]),{21:[1,37]},e(p,[2,25]),e(p,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};v.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return e.getLogger().trace(`Found comment`,t.yytext),6;case 1:return 8;case 2:this.begin(`CLASS`);break;case 3:return this.popState(),16;case 4:this.popState();break;case 5:e.getLogger().trace(`Begin icon`),this.begin(`ICON`);break;case 6:return e.getLogger().trace(`SPACELINE`),6;case 7:return 7;case 8:return 15;case 9:e.getLogger().trace(`end icon`),this.popState();break;case 10:return e.getLogger().trace(`Exploding node`),this.begin(`NODE`),19;case 11:return e.getLogger().trace(`Cloud`),this.begin(`NODE`),19;case 12:return e.getLogger().trace(`Explosion Bang`),this.begin(`NODE`),19;case 13:return e.getLogger().trace(`Cloud Bang`),this.begin(`NODE`),19;case 14:return this.begin(`NODE`),19;case 15:return this.begin(`NODE`),19;case 16:return this.begin(`NODE`),19;case 17:return this.begin(`NODE`),19;case 18:return 13;case 19:return 22;case 20:return 11;case 21:this.begin(`NSTR2`);break;case 22:return`NODE_DESCR`;case 23:this.popState();break;case 24:e.getLogger().trace(`Starting NSTR`),this.begin(`NSTR`);break;case 25:return e.getLogger().trace(`description:`,t.yytext),`NODE_DESCR`;case 26:this.popState();break;case 27:return this.popState(),e.getLogger().trace(`node end ))`),`NODE_DEND`;case 28:return this.popState(),e.getLogger().trace(`node end )`),`NODE_DEND`;case 29:return this.popState(),e.getLogger().trace(`node end ...`,t.yytext),`NODE_DEND`;case 30:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 31:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 32:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 33:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 34:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 35:return e.getLogger().trace(`Long description:`,t.yytext),20;case 36:return e.getLogger().trace(`Long description:`,t.yytext),20}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:mindmap\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{CLASS:{rules:[3,4],inclusive:!1},ICON:{rules:[8,9],inclusive:!1},NSTR2:{rules:[22,23],inclusive:!1},NSTR:{rules:[25,26],inclusive:!1},NODE:{rules:[21,24,27,28,29,30,31,32,33,34,35,36],inclusive:!1},INITIAL:{rules:[0,1,2,5,6,7,10,11,12,13,14,15,16,17,18,19,20],inclusive:!0}}}})();function y(){this.yy={}}return t(y,`Parser`),y.prototype=v,v.Parser=y,new y})();b.parser=b;var x=b,S=12,C={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},w=class{constructor(){this.nodes=[],this.count=0,this.elements={},this.getLogger=this.getLogger.bind(this),this.nodeType=C,this.clear(),this.getType=this.getType.bind(this),this.getElementById=this.getElementById.bind(this),this.getParent=this.getParent.bind(this),this.getMindmap=this.getMindmap.bind(this),this.addNode=this.addNode.bind(this),this.decorateNode=this.decorateNode.bind(this)}static{t(this,`MindmapDB`)}clear(){this.nodes=[],this.count=0,this.elements={},this.baseLevel=void 0}getParent(e){for(let t=this.nodes.length-1;t>=0;t--)if(this.nodes[t].level0?this.nodes[0]:null}addNode(t,n,r,a){e.info(`addNode`,t,n,r,a);let o=!1;this.nodes.length===0?(this.baseLevel=t,t=0,o=!0):this.baseLevel!==void 0&&(t-=this.baseLevel,o=!1);let s=c(),u=s.mindmap?.padding??i.mindmap.padding;switch(a){case this.nodeType.ROUNDED_RECT:case this.nodeType.RECT:case this.nodeType.HEXAGON:u*=2}let d={id:this.count++,nodeId:l(n,s),level:t,descr:l(r,s),type:a,children:[],width:s.mindmap?.maxNodeWidth??i.mindmap.maxNodeWidth,padding:u,isRoot:o},f=this.getParent(t);if(f)f.children.push(d),this.nodes.push(d);else if(o)this.nodes.push(d);else throw Error(`There can be only one root. No parent could be found for ("${d.descr}")`)}getType(t,n){switch(e.debug(`In get type`,t,n),t){case`[`:return this.nodeType.RECT;case`(`:return n===`)`?this.nodeType.ROUNDED_RECT:this.nodeType.CLOUD;case`((`:return this.nodeType.CIRCLE;case`)`:return this.nodeType.CLOUD;case`))`:return this.nodeType.BANG;case`{{`:return this.nodeType.HEXAGON;default:return this.nodeType.DEFAULT}}setElementForId(e,t){this.elements[e]=t}getElementById(e){return this.elements[e]}decorateNode(e){if(!e)return;let t=c(),n=this.nodes[this.nodes.length-1];e.icon&&(n.icon=l(e.icon,t)),e.class&&(n.class=l(e.class,t))}type2Str(e){switch(e){case this.nodeType.DEFAULT:return`no-border`;case this.nodeType.RECT:return`rect`;case this.nodeType.ROUNDED_RECT:return`rounded-rect`;case this.nodeType.CIRCLE:return`circle`;case this.nodeType.CLOUD:return`cloud`;case this.nodeType.BANG:return`bang`;case this.nodeType.HEXAGON:return`hexgon`;default:return`no-border`}}assignSections(e,t){if(e.section=e.level===0?void 0:t,e.children)for(let[n,r]of e.children.entries()){let i=e.level===0?n%(S-1):t;this.assignSections(r,i)}}flattenNodes(e,n){let r=c(),i=[`mindmap-node`];e.isRoot===!0?i.push(`section-root`,`section--1`):e.section!==void 0&&i.push(`section-${e.section}`),e.class&&i.push(e.class);let a=i.join(` `),o=t(e=>{let t=(r.theme?.toLowerCase()??``).includes(`redux`);switch(e){case C.CIRCLE:return`mindmapCircle`;case C.RECT:return`rect`;case C.ROUNDED_RECT:return`rounded`;case C.CLOUD:return`cloud`;case C.BANG:return`bang`;case C.HEXAGON:return`hexagon`;case C.DEFAULT:return t?`rounded`:`defaultMindmapNode`;case C.NO_BORDER:default:return`rect`}},`getShapeFromType`),s={id:e.id.toString(),domId:`node_`+e.id.toString(),label:e.descr,labelType:`markdown`,isGroup:!1,shape:o(e.type),width:e.width,height:e.height??0,padding:e.padding,cssClasses:a,cssStyles:[],look:r.look,icon:e.icon,x:e.x,y:e.y,level:e.level,nodeId:e.nodeId,type:e.type,section:e.section};if(n.push(s),e.children)for(let t of e.children)this.flattenNodes(t,n)}generateEdges(e,t){if(!e.children)return;let n=c();for(let r of e.children){let i=`edge`;r.section!==void 0&&(i+=` section-edge-${r.section}`);let a=e.level+1;i+=` edge-depth-${a}`;let o={id:`edge_${e.id}_${r.id}`,start:e.id.toString(),end:r.id.toString(),type:`normal`,curve:`basis`,thickness:`normal`,look:n.look,classes:i,depth:e.level,section:r.section};t.push(o),this.generateEdges(r,t)}}getData(){let t=this.getMindmap(),n=c(),r=a().layout!==void 0,i=n;if(r||(i.layout=`cose-bilkent`),!t)return{nodes:[],edges:[],config:i};e.debug(`getData: mindmapRoot`,t,n),this.assignSections(t);let o=[],s=[];this.flattenNodes(t,o),this.generateEdges(t,s),e.debug(`getData: processed ${o.length} nodes and ${s.length} edges`);let l=new Map;for(let e of o)l.set(e.id,{shape:e.shape,width:e.width,height:e.height,padding:e.padding});return{nodes:o,edges:s,config:i,rootNode:t,markers:[`point`],direction:`TB`,nodeSpacing:50,rankSpacing:50,shapes:Object.fromEntries(l),type:`mindmap`,diagramId:`mindmap-`+v()}}getLogger(){return e}},T={draw:t(async(t,n,a,o)=>{e.debug(`Rendering mindmap diagram +`+t);let s=o.db,c=s.getData(),l=f(n,c.config.securityLevel);if(c.type=o.type,c.layoutAlgorithm=d(c.config.layout,{fallback:`cose-bilkent`}),c.diagramId=n,!s.getMindmap())return;c.nodes.forEach(e=>{e.shape===`rounded`?(e.radius=15,e.taper=15,e.stroke=`none`,e.width=0,e.padding=15):e.shape===`circle`?e.padding=10:e.shape===`rect`?(e.width=0,e.padding=10):e.shape===`hexagon`&&(e.width=0,e.height=0)}),await u(c,l);let{themeVariables:m}=r(),{useGradient:h,gradientStart:g,gradientStop:_}=m;if(h&&g&&_){let e=l.attr(`id`),t=l.append(`defs`).append(`linearGradient`).attr(`id`,`${e}-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);t.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,g).attr(`stop-opacity`,1),t.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,_).attr(`stop-opacity`,1)}p(l,c.config.mindmap?.padding??i.mindmap.padding,`mindmapDiagram`,c.config.mindmap?.useMaxWidth??i.mindmap.useMaxWidth)},`draw`)},E=t(e=>{let{theme:t,look:r}=e,i=``;for(let t=0;t{let r=``;for(let i=0;i{let{theme:t}=e,n=e.svgId,r=e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${n}-drop-shadow)`):`none`;return` + .edge { + stroke-width: 3; + } + ${E(e)} + .section-root rect, .section-root path, .section-root circle, .section-root polygon { + fill: ${e.git0}; + } + .section-root text { + fill: ${e.gitBranchLabel0}; + } + .section-root span { + color: ${t?.includes(`redux`)?e.nodeBorder:e.gitBranchLabel0}; + } + .icon-container { + height:100%; + display: flex; + justify-content: center; + align-items: center; + } + .edge { + fill: none; + } + .mindmap-node-label { + dy: 1em; + alignment-baseline: middle; + text-anchor: middle; + dominant-baseline: middle; + text-align: center; + } + [data-look="neo"].mindmap-node { + filter: ${r}; + } + [data-look="neo"].mindmap-node.section-root rect, [data-look="neo"].mindmap-node.section-root path, [data-look="neo"].mindmap-node.section-root circle, [data-look="neo"].mindmap-node.section-root polygon { + fill: ${t?.includes(`redux`)?e.mainBkg:e.git0}; + } + [data-look="neo"].mindmap-node.section-root .text-inner-tspan { + fill: ${t?.includes(`redux`)?e.nodeBorder:e[`cScaleLabel`+ +(t===`neutral`)]}; + } + ${e.useGradient&&n&&e.mainBkg?D(e.THEME_COLOR_LIMIT,n,e.mainBkg):``} +`},`getStyles`)};export{O as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/ordinal-BDEzSJ7C.js b/frontend/dist/assets/ordinal-BDEzSJ7C.js new file mode 100644 index 0000000..200c228 --- /dev/null +++ b/frontend/dist/assets/ordinal-BDEzSJ7C.js @@ -0,0 +1 @@ +import{t as e}from"./init-C-OQMol4.js";var t=class extends Map{constructor(e,t=a){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),e!=null)for(let[t,n]of e)this.set(t,n)}get(e){return super.get(n(this,e))}has(e){return super.has(n(this,e))}set(e,t){return super.set(r(this,e),t)}delete(e){return super.delete(i(this,e))}};function n({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):n}function r({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function i({_intern:e,_key:t},n){let r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function a(e){return typeof e==`object`&&e?e.valueOf():e}var o=Symbol(`implicit`);function s(){var n=new t,r=[],i=[],a=o;function c(e){let t=n.get(e);if(t===void 0){if(a!==o)return a;n.set(e,t=r.push(e)-1)}return i[t%i.length]}return c.domain=function(e){if(!arguments.length)return r.slice();r=[],n=new t;for(let t of e)n.has(t)||n.set(t,r.push(t)-1);return c},c.range=function(e){return arguments.length?(i=Array.from(e),c):i.slice()},c.unknown=function(e){return arguments.length?(a=e,c):a},c.copy=function(){return s(r,i).unknown(a)},e.apply(c,arguments),c}export{s as t}; \ No newline at end of file diff --git a/frontend/dist/assets/packet-AYTQ26CC-f7lhlK2y.js b/frontend/dist/assets/packet-AYTQ26CC-f7lhlK2y.js new file mode 100644 index 0000000..92a9f52 --- /dev/null +++ b/frontend/dist/assets/packet-AYTQ26CC-f7lhlK2y.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{S as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createPacketServices}; \ No newline at end of file diff --git a/frontend/dist/assets/path-fybaL0A-.js b/frontend/dist/assets/path-fybaL0A-.js new file mode 100644 index 0000000..5d78fd7 --- /dev/null +++ b/frontend/dist/assets/path-fybaL0A-.js @@ -0,0 +1 @@ +var e=Math.PI,t=2*e,n=1e-6,r=t-n;function i(e){this._+=e[0];for(let t=1,n=e.length;t=0))throw Error(`invalid digits: ${e}`);if(t>15)return i;let n=10**t;return function(e){this._+=e[0];for(let t=1,r=e.length;tn){if(!(Math.abs(f*l-u*d)>n)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let m=i-s,h=a-c,g=l*l+u*u,_=m*m+h*h,v=Math.sqrt(g),y=Math.sqrt(p),b=o*Math.tan((e-Math.acos((g+p-_)/(2*v*y)))/2),x=b/y,S=b/v;Math.abs(x-1)>n&&this._append`L${t+x*d},${r+x*f}`,this._append`A${o},${o},0,0,${+(f*m>d*h)},${this._x1=t+S*l},${this._y1=r+S*u}`}}}arc(i,a,o,s,c,l){if(i=+i,a=+a,o=+o,l=!!l,o<0)throw Error(`negative radius: ${o}`);let u=o*Math.cos(s),d=o*Math.sin(s),f=i+u,p=a+d,m=1^l,h=l?s-c:c-s;this._x1===null?this._append`M${f},${p}`:(Math.abs(this._x1-f)>n||Math.abs(this._y1-p)>n)&&this._append`L${f},${p}`,o&&(h<0&&(h=h%t+t),h>r?this._append`A${o},${o},0,1,${m},${i-u},${a-d}A${o},${o},0,1,${m},${this._x1=f},${this._y1=p}`:h>n&&this._append`A${o},${o},0,${+(h>=e)},${m},${this._x1=i+o*Math.cos(c)},${this._y1=a+o*Math.sin(c)}`)}rect(e,t,n,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}};o.prototype;function s(e){return function(){return e}}function c(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{let e=Math.floor(n);if(!(e>=0))throw RangeError(`invalid digits: ${n}`);t=e}return e},()=>new o(t)}export{s as n,c as t}; \ No newline at end of file diff --git a/frontend/dist/assets/pegDiagram-GJSIUBJH-B0Gktij4.js b/frontend/dist/assets/pegDiagram-GJSIUBJH-B0Gktij4.js new file mode 100644 index 0000000..271e971 --- /dev/null +++ b/frontend/dist/assets/pegDiagram-GJSIUBJH-B0Gktij4.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{t as n,u as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=r().RailroadPeg.parser.LangiumParser,l=t(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformOrderedChoice`),u=t(e=>{let t=e.elements.map(d);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformSequence`),d=t(e=>{let t=p(e.suffix);return e.operator?{type:`special`,text:e.operator===`&`?`&${f(t)}`:`!${f(t)}`}:t},`transformPrefix`),f=t(e=>{switch(e.type){case`terminal`:return`"${e.value}"`;case`nonterminal`:return e.name;case`special`:return e.text;default:return`(...)`}},`nodeToLabel`),p=t(e=>{let t=m(e.primary);if(!e.operator)return t;switch(e.operator){case`?`:return{type:`optional`,element:t};case`*`:return{type:`repetition`,element:t,min:0,max:1/0};case`+`:return{type:`repetition`,element:t,min:1,max:1/0};default:throw Error(`Unsupported PEG suffix operator: ${e.operator}`)}},`transformSuffix`),m=t(e=>{switch(e.$type){case`PegLiteral`:return{type:`terminal`,value:e.value};case`PegIdentifier`:return{type:`nonterminal`,name:e.name};case`PegGroup`:return l(e.element);case`PegAny`:return{type:`special`,text:e.dot};default:throw Error(`Unsupported PEG primary node: ${e.$type}`)}},`transformPrimary`),h=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),g=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(h(e)))},`populateDb`),_={parser:{parse:t(t=>{o.clear(),e.debug(`[PEG Parser] Starting Langium parse`);let r=c.parse(t);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new n(r);let i=r.value;e.debug(`[PEG Parser] Parsed rules:`,i.rules.length),g(i),e.debug(`[PEG Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{_ as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/pie-WAS4IAKB-BbyREufe.js b/frontend/dist/assets/pie-WAS4IAKB-BbyREufe.js new file mode 100644 index 0000000..36377d2 --- /dev/null +++ b/frontend/dist/assets/pie-WAS4IAKB-BbyREufe.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{b as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createPieServices}; \ No newline at end of file diff --git a/frontend/dist/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js b/frontend/dist/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js new file mode 100644 index 0000000..8ea3af4 --- /dev/null +++ b/frontend/dist/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js @@ -0,0 +1,39 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,c as a,f as o,q as s,v as c,w as l,x as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as f}from"./ordinal-BDEzSJ7C.js";import{n as p}from"./path-fybaL0A-.js";import{m}from"./dist-Bfr8PhAA.js";import{t as h}from"./arc-BJA87daU.js";import{t as g}from"./array-BifhSqXX.js";import{i as _,p as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y}from"./index-DoQkmpth.js";import{n as b}from"./mermaid-parser.core-CUrDj5TF.js";import{t as x}from"./chunk-JWPE2WC7-DVXcaiue.js";function S(e,t){return te?1:t>=e?0:NaN}function C(e){return e}function w(){var e=C,t=S,n=null,r=p(0),i=p(m),a=p(0);function o(o){var s,c=(o=g(o)).length,l,u,d=0,f=Array(c),p=Array(c),h=+r.apply(this,arguments),_=Math.min(m,Math.max(-m,i.apply(this,arguments)-h)),v,y=Math.min(Math.abs(_)/c,a.apply(this,arguments)),b=y*(_<0?-1:1),x;for(s=0;s0&&(d+=x);for(t==null?n!=null&&f.sort(function(e,t){return n(o[e],o[t])}):f.sort(function(e,n){return t(p[e],p[n])}),s=0,u=d?(_-c*b)/d:0;s0?x*u:0)+b,p[l]={data:o[l],index:s,value:x,startAngle:h,endAngle:v,padAngle:y};return p}return o.value=function(t){return arguments.length?(e=typeof t==`function`?t:p(+t),o):e},o.sortValues=function(e){return arguments.length?(t=e,n=null,o):t},o.sort=function(e){return arguments.length?(n=e,t=null,o):n},o.startAngle=function(e){return arguments.length?(r=typeof e==`function`?e:p(+e),o):r},o.endAngle=function(e){return arguments.length?(i=typeof e==`function`?e:p(+e),o):i},o.padAngle=function(e){return arguments.length?(a=typeof e==`function`?e:p(+e),o):a},o}var T=o.pie,E={sections:new Map,showData:!1,config:T},D=E.sections,O=E.showData,k=structuredClone(T),A={getConfig:t(()=>structuredClone(k),`getConfig`),clear:t(()=>{D=new Map,O=E.showData,i()},`clear`),setDiagramTitle:s,getDiagramTitle:l,setAccTitle:r,getAccTitle:d,setAccDescription:n,getAccDescription:c,addSection:t(({label:t,value:n})=>{if(n<0)throw Error(`"${t}" has invalid value: ${n}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);D.has(t)||(D.set(t,n),e.debug(`added new section: ${t}, with value: ${n}`))},`addSection`),getSections:t(()=>D,`getSections`),setShowData:t(e=>{O=e},`setShowData`),getShowData:t(()=>O,`getShowData`)},j=t((e,t)=>{x(e,t),t.setShowData(e.showData),e.sections.map(t.addSection)},`populateDb`),M={parse:t(async t=>{let n=await b(`pie`,t);e.debug(n),j(n,A)},`parse`)},N=t(e=>` + .pieCircle{ + stroke: ${e.pieStrokeColor}; + stroke-width : ${e.pieStrokeWidth}; + opacity : ${e.pieOpacity}; + } + .pieCircle.highlighted{ + scale: 1.05; + opacity: 1; + } + .pieCircle.highlightedOnHover:hover{ + transition-duration: 250ms; + scale: 1.05; + opacity: 1; + } + .pieOuterCircle{ + stroke: ${e.pieOuterStrokeColor}; + stroke-width: ${e.pieOuterStrokeWidth}; + fill: none; + } + .pieTitleText { + text-anchor: middle; + font-size: ${e.pieTitleTextSize}; + fill: ${e.pieTitleTextColor}; + font-family: ${e.fontFamily}; + } + .slice { + font-family: ${e.fontFamily}; + fill: ${e.pieSectionTextColor}; + font-size:${e.pieSectionTextSize}; + // fill: white; + } + .legend text { + fill: ${e.pieLegendTextColor}; + font-family: ${e.fontFamily}; + font-size: ${e.pieLegendTextSize}; + } +`,`getStyles`),P=t(e=>{let t=[...e.values()].reduce((e,t)=>e+t,0),n=[...e.entries()].map(([e,t])=>({label:e,value:t})).filter(e=>e.value/t*100>=1);return w().value(e=>e.value).sort(null)(n)},`createPieArcs`),F={parser:M,db:A,renderer:{draw:t((t,n,r,i)=>{e.debug(`rendering pie chart +`+t);let o=i.db,s=u(),c=_(o.getConfig(),s.pie),l=y(n),d=l.append(`g`);d.attr(`transform`,`translate(225,225)`);let{themeVariables:p}=s,[m]=v(p.pieOuterStrokeWidth);m??=2;let g=c.legendPosition,b=c.textPosition,x=c.donutHole>0&&c.donutHole<=.9?c.donutHole:0,S=h().innerRadius(x*185).outerRadius(185),C=h().innerRadius(185*b).outerRadius(185*b),w=d.append(`g`);w.append(`circle`).attr(`cx`,0).attr(`cy`,0).attr(`r`,185+m/2).attr(`class`,`pieOuterCircle`);let T=o.getSections(),E=P(T),D=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],O=0;T.forEach(e=>{O+=e});let k=E.filter(e=>(e.data.value/O*100).toFixed(0)!==`0`),A=f(D).domain([...T.keys()]);w.selectAll(`mySlices`).data(k).enter().append(`path`).attr(`d`,S).attr(`fill`,e=>A(e.data.label)).attr(`class`,e=>{let t=`pieCircle`;return c.highlightSlice===`hover`?t+=` highlightedOnHover`:c.highlightSlice===e.data.label&&(t+=` highlighted`),t}),w.selectAll(`mySlices`).data(k).enter().append(`text`).text(e=>(e.data.value/O*100).toFixed(0)+`%`).attr(`transform`,e=>`translate(`+C.centroid(e)+`)`).style(`text-anchor`,`middle`).attr(`class`,`slice`);let j=d.append(`text`).text(o.getDiagramTitle()).attr(`x`,0).attr(`y`,-200).attr(`class`,`pieTitleText`),M=[...T.entries()].map(([e,t])=>({label:e,value:t})),N=d.selectAll(`.legend`).data(M).enter().append(`g`).attr(`class`,`legend`);N.append(`rect`).attr(`width`,18).attr(`height`,18).style(`fill`,e=>A(e.label)).style(`stroke`,e=>A(e.label)),N.append(`text`).attr(`x`,22).attr(`y`,14).text(e=>o.getShowData()?`${e.label} [${e.value}]`:e.label);let F=Math.max(...N.selectAll(`text`).nodes().map(e=>e?.getBoundingClientRect().width??0)),I=450,L=490,R=M.length*22;switch(g){case`center`:N.attr(`transform`,(e,t)=>{let n=22*M.length/2,r=-F/2-22,i=t*22-n;return`translate(`+r+`,`+i+`)`});break;case`top`:I+=R,N.attr(`transform`,(e,t)=>`translate(${-F/2-22}, ${t*22-185})`),w.attr(`transform`,()=>`translate(0, ${R+22})`);break;case`bottom`:I+=R,N.attr(`transform`,(e,t)=>{let n=-F/2-22,r=t*22- -207;return`translate(`+n+`,`+r+`)`});break;case`left`:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(-207,`+(t*22-n)+`)`}),w.attr(`transform`,()=>`translate(${F+18+4}, 0)`);break;default:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(216,`+(t*22-n)+`)`})}let z=j.node()?.getBoundingClientRect().width??0,B=225-z/2,V=225+z/2,H=Math.min(0,B),U=Math.max(L,V)-H;l.attr(`viewBox`,`${H} 0 ${U} ${I}`),a(l,I,U,c.useMaxWidth)},`draw`)},styles:N};export{F as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js b/frontend/dist/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js new file mode 100644 index 0000000..e8f48f7 --- /dev/null +++ b/frontend/dist/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js @@ -0,0 +1,7 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as r,H as i,U as a,a as o,c as s,f as c,q as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as h}from"./linear-CZ6dxGrP.js";var g=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[1,7],s=[1,4,5,10,12,13,14,15,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],c=[1,4,5,10,12,13,14,15,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],l=[55,56,57],u=[2,36],d=[1,37],f=[1,36],p=[1,38],m=[1,35],h=[1,43],g=[1,41],_=[1,45],v=[1,14],y=[1,23],b=[1,18],x=[1,19],S=[1,20],C=[1,21],w=[1,22],T=[1,24],E=[1,25],D=[1,26],O=[1,27],k=[1,28],A=[1,29],j=[1,32],M=[1,33],N=[1,34],P=[1,39],F=[1,40],I=[1,42],L=[1,44],R=[1,63],z=[1,62],B=[4,5,8,10,12,13,14,15,18,44,47,49,55,56,57,63,64,65,66,67],ee=[1,66],te=[1,67],ne=[1,68],re=[1,69],ie=[1,70],ae=[1,71],oe=[1,72],se=[1,73],ce=[1,74],le=[1,75],ue=[1,76],de=[1,77],V=[4,5,6,7,8,9,10,11,12,13,14,15,18],H=[1,91],U=[1,92],W=[1,93],G=[1,100],K=[1,94],q=[1,97],J=[1,95],Y=[1,96],X=[1,98],Z=[1,99],fe=[1,103],pe=[10,55,56,57],Q=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],me={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:`error`,4:`ALPHA`,5:`NUM`,6:`NODE_STRING`,7:`DOWN`,8:`MINUS`,9:`DEFAULT`,10:`COMMA`,11:`COLON`,12:`AMP`,13:`BRKT`,14:`MULT`,15:`UNICODE_TEXT`,17:`UNIT`,18:`SPACE`,19:`STYLE`,20:`PCT`,25:`CLASSDEF`,28:`QUADRANT`,35:`title`,36:`title_value`,37:`acc_title`,38:`acc_title_value`,39:`acc_descr`,40:`acc_descr_value`,41:`acc_descr_multiline_value`,42:`section`,44:`point_start`,45:`point_x`,46:`point_y`,47:`class_name`,48:`X-AXIS`,49:`AXIS-TEXT-DELIMITER`,50:`Y-AXIS`,51:`QUADRANT_1`,52:`QUADRANT_2`,53:`QUADRANT_3`,54:`QUADRANT_4`,55:`NEWLINE`,56:`SEMI`,57:`EOF`,60:`STR`,61:`MD_STR`,63:`PUNCTUATION`,64:`PLUS`,65:`EQUALS`,66:`DOT`,67:`UNDERSCORE`},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 23:this.$=a[s];break;case 24:this.$=a[s-1]+``+a[s];break;case 26:this.$=a[s-1]+a[s];break;case 27:this.$=[a[s].trim()];break;case 28:a[s-2].push(a[s].trim()),this.$=a[s-2];break;case 29:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 37:this.$=[];break;case 42:this.$=a[s].trim(),r.setDiagramTitle(this.$);break;case 43:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 44:case 45:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 46:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 47:r.addPoint(a[s-3],``,a[s-1],a[s],[]);break;case 48:r.addPoint(a[s-4],a[s-3],a[s-1],a[s],[]);break;case 49:r.addPoint(a[s-4],``,a[s-2],a[s-1],a[s]);break;case 50:r.addPoint(a[s-5],a[s-4],a[s-2],a[s-1],a[s]);break;case 51:r.setXAxisLeftText(a[s-2]),r.setXAxisRightText(a[s]);break;case 52:a[s-1].text+=` ⟶ `,r.setXAxisLeftText(a[s-1]);break;case 53:r.setXAxisLeftText(a[s]);break;case 54:r.setYAxisBottomText(a[s-2]),r.setYAxisTopText(a[s]);break;case 55:a[s-1].text+=` ⟶ `,r.setYAxisBottomText(a[s-1]);break;case 56:r.setYAxisBottomText(a[s]);break;case 57:r.setQuadrant1Text(a[s]);break;case 58:r.setQuadrant2Text(a[s]);break;case 59:r.setQuadrant3Text(a[s]);break;case 60:r.setQuadrant4Text(a[s]);break;case 64:this.$={text:a[s],type:`text`};break;case 65:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 66:this.$={text:a[s],type:`text`};break;case 67:this.$={text:a[s],type:`markdown`};break;case 68:this.$=a[s];break;case 69:this.$=a[s-1]+``+a[s]}},`anonymous`),table:[{18:t,26:1,27:2,28:r,55:i,56:a,57:o},{1:[3]},{18:t,26:8,27:2,28:r,55:i,56:a,57:o},{18:t,26:9,27:2,28:r,55:i,56:a,57:o},e(s,[2,33],{29:10}),e(c,[2,61]),e(c,[2,62]),e(c,[2,63]),{1:[2,30]},{1:[2,31]},e(l,u,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(s,[2,34]),{27:46,55:i,56:a,57:o},e(l,[2,37]),e(l,u,{24:13,32:15,33:16,34:17,43:30,58:31,31:47,4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(l,[2,39]),e(l,[2,40]),e(l,[2,41]),{36:[1,48]},{38:[1,49]},{40:[1,50]},e(l,[2,45]),e(l,[2,46]),{18:[1,51]},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:52,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:53,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:54,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:55,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:56,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:57,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,44:[1,58],47:[1,59],58:61,59:60,63:N,64:P,65:F,66:I,67:L},e(B,[2,64]),e(B,[2,66]),e(B,[2,67]),e(B,[2,70]),e(B,[2,71]),e(B,[2,72]),e(B,[2,73]),e(B,[2,74]),e(B,[2,75]),e(B,[2,76]),e(B,[2,77]),e(B,[2,78]),e(B,[2,79]),e(B,[2,80]),e(B,[2,81]),e(s,[2,35]),e(l,[2,38]),e(l,[2,42]),e(l,[2,43]),e(l,[2,44]),{3:65,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,21:64},e(l,[2,53],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,78],63:N,64:P,65:F,66:I,67:L}),e(l,[2,56],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,79],63:N,64:P,65:F,66:I,67:L}),e(l,[2,57],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,58],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,59],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,60],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),{45:[1,80]},{44:[1,81]},e(B,[2,65]),e(B,[2,82]),e(B,[2,83]),e(B,[2,84]),{3:83,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,18:[1,82]},e(V,[2,23]),e(V,[2,1]),e(V,[2,2]),e(V,[2,3]),e(V,[2,4]),e(V,[2,5]),e(V,[2,6]),e(V,[2,7]),e(V,[2,8]),e(V,[2,9]),e(V,[2,10]),e(V,[2,11]),e(V,[2,12]),e(l,[2,52],{58:31,43:84,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(l,[2,55],{58:31,43:85,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),{46:[1,86]},{45:[1,87]},{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:89,23:88},e(V,[2,24]),e(l,[2,51],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,54],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,47],{22:89,16:90,23:101,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{46:[1,102]},e(l,[2,29],{10:fe}),e(pe,[2,27],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),e(Q,[2,25]),e(Q,[2,13]),e(Q,[2,14]),e(Q,[2,15]),e(Q,[2,16]),e(Q,[2,17]),e(Q,[2,18]),e(Q,[2,19]),e(Q,[2,20]),e(Q,[2,21]),e(Q,[2,22]),e(l,[2,49],{10:fe}),e(l,[2,48],{22:89,16:90,23:105,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:106},e(Q,[2,26]),e(l,[2,50],{10:fe}),e(pe,[2,28],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z})],defaultActions:{8:[2,30],9:[2,31]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};me.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 55;case 3:break;case 4:return this.begin(`title`),35;case 5:return this.popState(),`title_value`;case 6:return this.begin(`acc_title`),37;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),39;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin(`md_string`);break;case 22:return`MD_STR`;case 23:this.popState();break;case 24:this.begin(`string`);break;case 25:this.popState();break;case 26:return`STR`;case 27:this.begin(`class_name`);break;case 28:return this.popState(),47;case 29:return this.begin(`point_start`),44;case 30:return this.begin(`point_x`),45;case 31:this.popState();break;case 32:this.popState(),this.begin(`point_y`);break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 15;case 37:return 11;case 38:return 64;case 39:return 10;case 40:return 65;case 41:return 65;case 42:return 14;case 43:return 13;case 44:return 67;case 45:return 66;case 46:return 12;case 47:return 8;case 48:return 5;case 49:return 18;case 50:return 56;case 51:return 63;case 52:return 57}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?:[^\x00-\x7F]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}})();function $(){this.yy={}}return n($,`Parser`),$.prototype=me,me.Parser=$,new $})();g.parser=g;var _=g,v=r(),y=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{n(this,`QuadrantBuilder`)}getDefaultData(){return{titleText:``,quadrant1Text:``,quadrant2Text:``,quadrant3Text:``,quadrant4Text:``,xAxisLeftText:``,xAxisRightText:``,yAxisBottomText:``,yAxisTopText:``,points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:c.quadrantChart?.chartWidth||500,chartWidth:c.quadrantChart?.chartHeight||500,titlePadding:c.quadrantChart?.titlePadding||10,titleFontSize:c.quadrantChart?.titleFontSize||20,quadrantPadding:c.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:c.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:c.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:c.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:c.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:c.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:c.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:c.quadrantChart?.pointTextPadding||5,pointLabelFontSize:c.quadrantChart?.pointLabelFontSize||12,pointRadius:c.quadrantChart?.pointRadius||5,xAxisPosition:c.quadrantChart?.xAxisPosition||`top`,yAxisPosition:c.quadrantChart?.yAxisPosition||`left`,quadrantInternalBorderStrokeWidth:c.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:c.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:v.quadrant1Fill,quadrant2Fill:v.quadrant2Fill,quadrant3Fill:v.quadrant3Fill,quadrant4Fill:v.quadrant4Fill,quadrant1TextFill:v.quadrant1TextFill,quadrant2TextFill:v.quadrant2TextFill,quadrant3TextFill:v.quadrant3TextFill,quadrant4TextFill:v.quadrant4TextFill,quadrantPointFill:v.quadrantPointFill,quadrantPointTextFill:v.quadrantPointTextFill,quadrantXAxisTextFill:v.quadrantXAxisTextFill,quadrantYAxisTextFill:v.quadrantYAxisTextFill,quadrantTitleFill:v.quadrantTitleFill,quadrantInternalBorderStrokeFill:v.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:v.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,e.info(`clear called`)}setData(e){this.data={...this.data,...e}}addPoints(e){this.data.points=[...e,...this.data.points]}addClass(e,t){this.classes.set(e,t)}setConfig(t){e.trace(`setConfig called with: `,t),this.config={...this.config,...t}}setThemeConfig(t){e.trace(`setThemeConfig called with: `,t),this.themeConfig={...this.themeConfig,...t}}calculateSpace(e,t,n,r){let i=this.config.xAxisLabelPadding*2+this.config.xAxisLabelFontSize,a={top:e===`top`&&t?i:0,bottom:e===`bottom`&&t?i:0},o=this.config.yAxisLabelPadding*2+this.config.yAxisLabelFontSize,s={left:this.config.yAxisPosition===`left`&&n?o:0,right:this.config.yAxisPosition===`right`&&n?o:0},c=this.config.titleFontSize+this.config.titlePadding*2,l={top:r?c:0},u=this.config.quadrantPadding+s.left,d=this.config.quadrantPadding+a.top+l.top,f=this.config.chartWidth-this.config.quadrantPadding*2-s.left-s.right,p=this.config.chartHeight-this.config.quadrantPadding*2-a.top-a.bottom-l.top;return{xAxisSpace:a,yAxisSpace:s,titleSpace:l,quadrantSpace:{quadrantLeft:u,quadrantTop:d,quadrantWidth:f,quadrantHalfWidth:f/2,quadrantHeight:p,quadrantHalfHeight:p/2}}}getAxisLabels(e,t,n,r){let{quadrantSpace:i,titleSpace:a}=r,{quadrantHalfHeight:o,quadrantHeight:s,quadrantLeft:c,quadrantHalfWidth:l,quadrantTop:u,quadrantWidth:d}=i,f=!!this.data.xAxisRightText,p=!!this.data.yAxisTopText,m=[];return this.data.xAxisLeftText&&t&&m.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.xAxisRightText&&t&&m.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+l+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.yAxisBottomText&&n&&m.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+s-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),this.data.yAxisTopText&&n&&m.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+o-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),m}getQuadrants(e){let{quadrantSpace:t}=e,{quadrantHalfHeight:n,quadrantLeft:r,quadrantHalfWidth:i,quadrantTop:a}=t,o=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a,width:i,height:n,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a,width:i,height:n,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant4Fill}];for(let e of o)e.text.x=e.x+e.width/2,this.data.points.length===0?(e.text.y=e.y+e.height/2,e.text.horizontalPos=`middle`):(e.text.y=e.y+this.config.quadrantTextTopPadding,e.text.horizontalPos=`top`);return o}getQuadrantPoints(e){let{quadrantSpace:t}=e,{quadrantHeight:n,quadrantLeft:r,quadrantTop:i,quadrantWidth:a}=t,o=h().domain([0,1]).range([r,a+r]),s=h().domain([0,1]).range([n+i,i]);return this.data.points.map(e=>{let t=this.classes.get(e.className);return t&&(e={...t,...e}),{x:o(e.x),y:s(e.y),fill:e.color??this.themeConfig.quadrantPointFill,radius:e.radius??this.config.pointRadius,text:{text:e.text,fill:this.themeConfig.quadrantPointTextFill,x:o(e.x),y:s(e.y)+this.config.pointTextPadding,verticalPos:`center`,horizontalPos:`top`,fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:e.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:e.strokeWidth??`0px`}})}getBorders(e){let t=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:n}=e,{quadrantHalfHeight:r,quadrantHeight:i,quadrantLeft:a,quadrantHalfWidth:o,quadrantTop:s,quadrantWidth:c}=n;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s,x2:a+c+t,y2:s},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a+c,y1:s+t,x2:a+c,y2:s+i-t},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s+i,x2:a+c+t,y2:s+i},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a,y1:s+t,x2:a,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+o,y1:s+t,x2:a+o,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+t,y1:s+r,x2:a+c-t,y2:s+r}]}getTitle(e){if(e)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:`top`,verticalPos:`center`,rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){let e=this.config.showXAxis&&!!(this.data.xAxisLeftText||this.data.xAxisRightText),t=this.config.showYAxis&&!!(this.data.yAxisTopText||this.data.yAxisBottomText),n=this.config.showTitle&&!!this.data.titleText,r=this.data.points.length>0?`bottom`:this.config.xAxisPosition,i=this.calculateSpace(r,e,t,n);return{points:this.getQuadrantPoints(i),quadrants:this.getQuadrants(i),axisLabels:this.getAxisLabels(r,e,t,i),borderLines:this.getBorders(i),title:this.getTitle(n)}}},b=class extends Error{static{n(this,`InvalidStyleError`)}constructor(e,t,n){super(`value for ${e} ${t} is invalid, please use a valid ${n}`),this.name=`InvalidStyleError`}};function x(e){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(e)}n(x,`validateHexCode`);function S(e){return!/^\d+$/.test(e)}n(S,`validateNumber`);function C(e){return!/^\d+px$/.test(e)}n(C,`validateSizeInPixels`);function w(e){return m(e.trim(),f())}n(w,`textSanitizer`);var T=new y;function E(e){T.setData({quadrant1Text:w(e.text)})}n(E,`setQuadrant1Text`);function D(e){T.setData({quadrant2Text:w(e.text)})}n(D,`setQuadrant2Text`);function O(e){T.setData({quadrant3Text:w(e.text)})}n(O,`setQuadrant3Text`);function k(e){T.setData({quadrant4Text:w(e.text)})}n(k,`setQuadrant4Text`);function A(e){T.setData({xAxisLeftText:w(e.text)})}n(A,`setXAxisLeftText`);function j(e){T.setData({xAxisRightText:w(e.text)})}n(j,`setXAxisRightText`);function M(e){T.setData({yAxisTopText:w(e.text)})}n(M,`setYAxisTopText`);function N(e){T.setData({yAxisBottomText:w(e.text)})}n(N,`setYAxisBottomText`);function P(e){let t={};for(let n of e){let[e,r]=n.trim().split(/\s*:\s*/);if(e===`radius`){if(S(r))throw new b(e,r,`number`);t.radius=parseInt(r)}else if(e===`color`){if(x(r))throw new b(e,r,`hex code`);t.color=r}else if(e===`stroke-color`){if(x(r))throw new b(e,r,`hex code`);t.strokeColor=r}else if(e===`stroke-width`){if(C(r))throw new b(e,r,`number of pixels (eg. 10px)`);t.strokeWidth=r}else throw Error(`style named ${e} is not supported.`)}return t}n(P,`parseStyles`);function F(e,t,n,r,i){let a=P(i);T.addPoints([{x:n,y:r,text:w(e.text),className:t,...a}])}n(F,`addPoint`);function I(e,t){T.addClass(e,P(t))}n(I,`addClass`);function L(e){T.setConfig({chartWidth:e})}n(L,`setWidth`);function R(e){T.setConfig({chartHeight:e})}n(R,`setHeight`);function z(){let{themeVariables:e,quadrantChart:t}=f();return t&&T.setConfig(t),T.setThemeConfig({quadrant1Fill:e.quadrant1Fill,quadrant2Fill:e.quadrant2Fill,quadrant3Fill:e.quadrant3Fill,quadrant4Fill:e.quadrant4Fill,quadrant1TextFill:e.quadrant1TextFill,quadrant2TextFill:e.quadrant2TextFill,quadrant3TextFill:e.quadrant3TextFill,quadrant4TextFill:e.quadrant4TextFill,quadrantPointFill:e.quadrantPointFill,quadrantPointTextFill:e.quadrantPointTextFill,quadrantXAxisTextFill:e.quadrantXAxisTextFill,quadrantYAxisTextFill:e.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:e.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:e.quadrantInternalBorderStrokeFill,quadrantTitleFill:e.quadrantTitleFill}),T.setData({titleText:d()}),T.build()}n(z,`getQuadrantData`);var B={parser:_,db:{setWidth:L,setHeight:R,setQuadrant1Text:E,setQuadrant2Text:D,setQuadrant3Text:O,setQuadrant4Text:k,setXAxisLeftText:A,setXAxisRightText:j,setYAxisTopText:M,setYAxisBottomText:N,parseStyles:P,addPoint:F,addClass:I,getQuadrantData:z,clear:n(function(){T.clear(),o()},`clear`),setAccTitle:a,getAccTitle:p,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:i},renderer:{draw:n((r,i,a,o)=>{function c(e){return e===`top`?`hanging`:`middle`}n(c,`getDominantBaseLine`);function l(e){return e===`left`?`start`:`middle`}n(l,`getTextAnchor`);function u(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}n(u,`getTransformation`);let d=f();e.debug(`Rendering quadrant chart +`+r);let p=d.securityLevel,m;p===`sandbox`&&(m=t(`#i`+i));let h=t(p===`sandbox`?m.nodes()[0].contentDocument.body:`body`).select(`[id="${i}"]`),g=h.append(`g`).attr(`class`,`main`),_=d.quadrantChart?.chartWidth??500,v=d.quadrantChart?.chartHeight??500;s(h,v,_,d.quadrantChart?.useMaxWidth??!0),h.attr(`viewBox`,`0 0 `+_+` `+v),o.db.setHeight(v),o.db.setWidth(_);let y=o.db.getQuadrantData(),b=g.append(`g`).attr(`class`,`quadrants`),x=g.append(`g`).attr(`class`,`border`),S=g.append(`g`).attr(`class`,`data-points`),C=g.append(`g`).attr(`class`,`labels`),w=g.append(`g`).attr(`class`,`title`);y.title&&w.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,y.title.fill).attr(`font-size`,y.title.fontSize).attr(`dominant-baseline`,c(y.title.horizontalPos)).attr(`text-anchor`,l(y.title.verticalPos)).attr(`transform`,u(y.title)).text(y.title.text),y.borderLines&&x.selectAll(`line`).data(y.borderLines).enter().append(`line`).attr(`x1`,e=>e.x1).attr(`y1`,e=>e.y1).attr(`x2`,e=>e.x2).attr(`y2`,e=>e.y2).style(`stroke`,e=>e.strokeFill).style(`stroke-width`,e=>e.strokeWidth);let T=b.selectAll(`g.quadrant`).data(y.quadrants).enter().append(`g`).attr(`class`,`quadrant`);T.append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill),T.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>c(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text)).text(e=>e.text.text),C.selectAll(`g.label`).data(y.axisLabels).enter().append(`g`).attr(`class`,`label`).append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>c(e.horizontalPos)).attr(`text-anchor`,e=>l(e.verticalPos)).attr(`transform`,e=>u(e));let E=S.selectAll(`g.data-point`).data(y.points).enter().append(`g`).attr(`class`,`data-point`);E.append(`circle`).attr(`cx`,e=>e.x).attr(`cy`,e=>e.y).attr(`r`,e=>e.radius).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeColor).attr(`stroke-width`,e=>e.strokeWidth),E.append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text.text).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>c(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text))},`draw`)},styles:n(()=>``,`styles`)};export{B as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/radar-RG4KPBEZ-BsN_WAuk.js b/frontend/dist/assets/radar-RG4KPBEZ-BsN_WAuk.js new file mode 100644 index 0000000..7a9497e --- /dev/null +++ b/frontend/dist/assets/radar-RG4KPBEZ-BsN_WAuk.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{v as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRadarServices}; \ No newline at end of file diff --git a/frontend/dist/assets/railroad-74A4TZTK-CYJJ-7AP.js b/frontend/dist/assets/railroad-74A4TZTK-CYJJ-7AP.js new file mode 100644 index 0000000..4a2773f --- /dev/null +++ b/frontend/dist/assets/railroad-74A4TZTK-CYJJ-7AP.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{g as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadServices}; \ No newline at end of file diff --git a/frontend/dist/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js b/frontend/dist/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js new file mode 100644 index 0000000..ac16143 --- /dev/null +++ b/frontend/dist/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{m as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadAbnfServices}; \ No newline at end of file diff --git a/frontend/dist/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js b/frontend/dist/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js new file mode 100644 index 0000000..a333b8f --- /dev/null +++ b/frontend/dist/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{f as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadEbnfServices}; \ No newline at end of file diff --git a/frontend/dist/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js b/frontend/dist/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js new file mode 100644 index 0000000..df71386 --- /dev/null +++ b/frontend/dist/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{u as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadPegServices}; \ No newline at end of file diff --git a/frontend/dist/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js b/frontend/dist/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js new file mode 100644 index 0000000..71dbe67 --- /dev/null +++ b/frontend/dist/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{g as n,t as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=n().Railroad.parser.LangiumParser,l=t(e=>{switch(e.$type){case`RailroadTerminalExpr`:return{type:`terminal`,value:e.value};case`RailroadNonTerminalExpr`:return{type:`nonterminal`,name:e.name};case`RailroadSpecialExpr`:return{type:`special`,text:e.text};case`RailroadSequenceExpr`:{let t=e.elements.map(l);return t.length===1?t[0]:{type:`sequence`,elements:t}}case`RailroadChoiceExpr`:{let t=e.alternatives.map(l);return t.length===1?t[0]:{type:`choice`,alternatives:t}}case`RailroadOptionalExpr`:return{type:`optional`,element:l(e.element)};case`RailroadOneOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:1,max:1/0};case`RailroadZeroOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:0,max:1/0};default:throw Error(`Unsupported railroad expression: ${e.$type}`)}},`transformExpression`),u=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),d=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(u(e)))},`populateDb`),f={parser:{parse:t(t=>{o.clear(),e.debug(`[Railroad Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[Railroad Parser] Parsed rules:`,i.rules.length),d(i),e.debug(`[Railroad Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{f as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js b/frontend/dist/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js new file mode 100644 index 0000000..1acf46a --- /dev/null +++ b/frontend/dist/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js @@ -0,0 +1,84 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t,t as n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,a,b as o,q as s,v as c,w as l,x as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as f}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{a as p,i as m,o as h,r as g}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as _,t as v}from"./index-DoQkmpth.js";import{t as y}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as b}from"./chunk-WEXAMYUT-I3m-hOmT.js";var x=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],s=[1,22],c=[2,7],l=[1,26],u=[1,27],d=[1,28],f=[1,29],p=[1,33],m=[1,34],h=[1,35],g=[1,36],_=[1,37],v=[1,38],y=[1,24],b=[1,31],x=[1,32],S=[1,30],C=[1,39],w=[1,40],T=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],E=[1,61],D=[89,90],O=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],k=[27,29],ee=[1,70],A=[1,71],te=[1,72],ne=[1,73],re=[1,74],ie=[1,75],ae=[1,76],j=[1,83],M=[1,80],N=[1,84],P=[1,85],F=[1,86],I=[1,87],L=[1,88],R=[1,89],z=[1,90],B=[1,91],V=[1,92],oe=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],H=[63,64],se=[1,101],ce=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],U=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],W=[1,110],G=[1,106],K=[1,107],q=[1,108],J=[1,109],Y=[1,111],X=[1,116],Z=[1,117],Q=[1,114],$=[1,115],le={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:`error`,5:`NEWLINE`,6:`RD`,8:`EOF`,9:`acc_title`,10:`acc_title_value`,11:`acc_descr`,12:`acc_descr_value`,13:`acc_descr_multiline_value`,21:`direction_tb`,22:`direction_bt`,23:`direction_rl`,24:`direction_lr`,27:`STRUCT_START`,29:`STYLE_SEPARATOR`,31:`ID`,32:`COLONSEP`,34:`TEXT`,36:`RISK`,38:`VERIFYMTHD`,40:`STRUCT_STOP`,41:`REQUIREMENT`,42:`FUNCTIONAL_REQUIREMENT`,43:`INTERFACE_REQUIREMENT`,44:`PERFORMANCE_REQUIREMENT`,45:`PHYSICAL_REQUIREMENT`,46:`DESIGN_CONSTRAINT`,47:`LOW_RISK`,48:`MED_RISK`,49:`HIGH_RISK`,50:`VERIFY_ANALYSIS`,51:`VERIFY_DEMONSTRATION`,52:`VERIFY_INSPECTION`,53:`VERIFY_TEST`,54:`ELEMENT`,57:`TYPE`,59:`DOCREF`,61:`END_ARROW_L`,63:`LINE`,64:`END_ARROW_R`,65:`CONTAINS`,66:`COPIES`,67:`DERIVES`,68:`SATISFIES`,69:`VERIFIES`,70:`REFINES`,71:`TRACES`,72:`CLASSDEF`,74:`CLASS`,75:`ALPHA`,76:`COMMA`,77:`STYLE`,80:`NUM`,81:`COLON`,82:`UNIT`,83:`SPACE`,84:`BRKT`,85:`PCT`,86:`MINUS`,87:`LABEL`,88:`SEMICOLON`,89:`unqString`,90:`qString`},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 5:case 6:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:r.setDirection(`TB`);break;case 18:r.setDirection(`BT`);break;case 19:r.setDirection(`RL`);break;case 20:r.setDirection(`LR`);break;case 21:r.addRequirement(a[s-3],a[s-4]);break;case 22:r.addRequirement(a[s-5],a[s-6]),r.setClass([a[s-5]],a[s-3]);break;case 23:r.setNewReqId(a[s-2]);break;case 24:r.setNewReqText(a[s-2]);break;case 25:r.setNewReqRisk(a[s-2]);break;case 26:r.setNewReqVerifyMethod(a[s-2]);break;case 29:this.$=r.RequirementType.REQUIREMENT;break;case 30:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=r.RiskLevel.LOW_RISK;break;case 36:this.$=r.RiskLevel.MED_RISK;break;case 37:this.$=r.RiskLevel.HIGH_RISK;break;case 38:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=r.VerifyType.VERIFY_TEST;break;case 42:r.addElement(a[s-3]);break;case 43:r.addElement(a[s-5]),r.setClass([a[s-5]],a[s-3]);break;case 44:r.setNewElementType(a[s-2]);break;case 45:r.setNewElementDocRef(a[s-2]);break;case 48:r.addRelationship(a[s-2],a[s],a[s-4]);break;case 49:r.addRelationship(a[s-2],a[s-4],a[s]);break;case 50:this.$=r.Relationships.CONTAINS;break;case 51:this.$=r.Relationships.COPIES;break;case 52:this.$=r.Relationships.DERIVES;break;case 53:this.$=r.Relationships.SATISFIES;break;case 54:this.$=r.Relationships.VERIFIES;break;case 55:this.$=r.Relationships.REFINES;break;case 56:this.$=r.Relationships.TRACES;break;case 57:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 58:r.setClass(a[s-1],a[s]);break;case 59:r.setClass([a[s-2]],a[s]);break;case 60:case 62:this.$=[a[s]];break;case 61:case 63:this.$=a[s-2].concat([a[s]]);break;case 64:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 65:this.$=[a[s]];break;case 66:a[s-2].push(a[s]),this.$=a[s-2];break;case 68:this.$=a[s-1]+a[s]}},`anonymous`),table:[{3:1,4:2,6:n,9:r,11:i,13:a},{1:[3]},{3:8,4:2,5:[1,7],6:n,9:r,11:i,13:a},{5:[1,9]},{10:[1,10]},{12:[1,11]},e(o,[2,6]),{3:12,4:2,6:n,9:r,11:i,13:a},{1:[2,2]},{4:17,5:s,7:13,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},e(o,[2,4]),e(o,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:s,7:42,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:43,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:44,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:45,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:46,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:47,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:48,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:49,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:50,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},e(T,[2,17]),e(T,[2,18]),e(T,[2,19]),e(T,[2,20]),{30:60,33:62,75:E,89:C,90:w},{30:63,33:62,75:E,89:C,90:w},{30:64,33:62,75:E,89:C,90:w},e(D,[2,29]),e(D,[2,30]),e(D,[2,31]),e(D,[2,32]),e(D,[2,33]),e(D,[2,34]),e(O,[2,81]),e(O,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},e(k,[2,79]),e(k,[2,80]),{27:[1,67],29:[1,68]},e(k,[2,85]),e(k,[2,86]),{62:69,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{62:77,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{30:78,33:62,75:E,89:C,90:w},{73:79,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,60]),e(oe,[2,62]),{73:93,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},{30:94,33:62,75:E,76:M,89:C,90:w},{5:[1,95]},{30:96,33:62,75:E,89:C,90:w},{5:[1,97]},{30:98,33:62,75:E,89:C,90:w},{63:[1,99]},e(H,[2,50]),e(H,[2,51]),e(H,[2,52]),e(H,[2,53]),e(H,[2,54]),e(H,[2,55]),e(H,[2,56]),{64:[1,100]},e(T,[2,59],{76:M}),e(T,[2,64],{76:se}),{33:103,75:[1,102],89:C,90:w},e(ce,[2,65],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),e(U,[2,67]),e(U,[2,69]),e(U,[2,70]),e(U,[2,71]),e(U,[2,72]),e(U,[2,73]),e(U,[2,74]),e(U,[2,75]),e(U,[2,76]),e(U,[2,77]),e(U,[2,78]),e(T,[2,57],{76:se}),e(T,[2,58],{76:M}),{5:W,28:105,31:G,34:K,36:q,38:J,40:Y},{27:[1,112],76:M},{5:X,40:Z,56:113,57:Q,59:$},{27:[1,118],76:M},{33:119,89:C,90:w},{33:120,89:C,90:w},{75:j,78:121,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,61]),e(oe,[2,63]),e(U,[2,68]),e(T,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:W,28:126,31:G,34:K,36:q,38:J,40:Y},e(T,[2,28]),{5:[1,127]},e(T,[2,42]),{32:[1,128]},{32:[1,129]},{5:X,40:Z,56:130,57:Q,59:$},e(T,[2,47]),{5:[1,131]},e(T,[2,48]),e(T,[2,49]),e(ce,[2,66],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),{33:132,89:C,90:w},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},e(T,[2,27]),{5:W,28:145,31:G,34:K,36:q,38:J,40:Y},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},e(T,[2,46]),{5:X,40:Z,56:152,57:Q,59:$},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},e(T,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},e(T,[2,43]),{5:W,28:159,31:G,34:K,36:q,38:J,40:Y},{5:W,28:160,31:G,34:K,36:q,38:J,40:Y},{5:W,28:161,31:G,34:K,36:q,38:J,40:Y},{5:W,28:162,31:G,34:K,36:q,38:J,40:Y},{5:X,40:Z,56:163,57:Q,59:$},{5:X,40:Z,56:164,57:Q,59:$},e(T,[2,23]),e(T,[2,24]),e(T,[2,25]),e(T,[2,26]),e(T,[2,44]),e(T,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],s[w])this.terminals_[O]&&O>f&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),ee=s[r[r.length-2]][r[r.length-1]],r.push(ee);break;case 3:return!0}}return!0},`parse`)};le.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return`title`;case 1:return this.begin(`acc_title`),9;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),11;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:break;case 14:break;case 15:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin(`style`),77;case 50:return 75;case 51:return 81;case 52:return 88;case 53:return`PERCENT`;case 54:return 86;case 55:return 84;case 56:break;case 57:this.begin(`string`);break;case 58:this.popState();break;case 59:return this.begin(`style`),72;case 60:return this.begin(`style`),74;case 61:return 61;case 62:return 64;case 63:return 63;case 64:this.begin(`string`);break;case 65:this.popState();break;case 66:return`qString`;case 67:return t.yytext=t.yytext.trim(),89;case 68:return 75;case 69:return 80;case 70:return 76}},`anonymous`),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}}})();function ue(){this.yy={}}return t(ue,`Parser`),ue.prototype=le,le.Parser=ue,new ue})();x.parser=x;var S=x,C=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction=`TB`,this.RequirementType={REQUIREMENT:`Requirement`,FUNCTIONAL_REQUIREMENT:`Functional Requirement`,INTERFACE_REQUIREMENT:`Interface Requirement`,PERFORMANCE_REQUIREMENT:`Performance Requirement`,PHYSICAL_REQUIREMENT:`Physical Requirement`,DESIGN_CONSTRAINT:`Design Constraint`},this.RiskLevel={LOW_RISK:`Low`,MED_RISK:`Medium`,HIGH_RISK:`High`},this.VerifyType={VERIFY_ANALYSIS:`Analysis`,VERIFY_DEMONSTRATION:`Demonstration`,VERIFY_INSPECTION:`Inspection`,VERIFY_TEST:`Test`},this.Relationships={CONTAINS:`contains`,COPIES:`copies`,DERIVES:`derives`,SATISFIES:`satisfies`,VERIFIES:`verifies`,REFINES:`refines`,TRACES:`traces`},this.setAccTitle=i,this.getAccTitle=d,this.setAccDescription=r,this.getAccDescription=c,this.setDiagramTitle=s,this.getDiagramTitle=l,this.getConfig=t(()=>u().requirement,`getConfig`),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{t(this,`RequirementDB`)}getDirection(){return this.direction}setDirection(e){this.direction=e}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:``,text:``,risk:``,verifyMethod:``,name:``,type:``,cssStyles:[],classes:[`default`]}}getInitialElement(){return{name:``,type:``,docRef:``,cssStyles:[],classes:[`default`]}}addRequirement(e,t){return this.requirements.has(e)||this.requirements.set(e,{name:e,type:t,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:[`default`]}),this.resetLatestRequirement(),this.requirements.get(e)}getRequirements(){return this.requirements}setNewReqId(e){this.latestRequirement!==void 0&&(this.latestRequirement.requirementId=e)}setNewReqText(e){this.latestRequirement!==void 0&&(this.latestRequirement.text=e)}setNewReqRisk(e){this.latestRequirement!==void 0&&(this.latestRequirement.risk=e)}setNewReqVerifyMethod(e){this.latestRequirement!==void 0&&(this.latestRequirement.verifyMethod=e)}addElement(t){return this.elements.has(t)||(this.elements.set(t,{name:t,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:[`default`]}),e.info(`Added new element: `,t)),this.resetLatestElement(),this.elements.get(t)}getElements(){return this.elements}setNewElementType(e){this.latestElement!==void 0&&(this.latestElement.type=e)}setNewElementDocRef(e){this.latestElement!==void 0&&(this.latestElement.docRef=e)}addRelationship(e,t,n){this.relations.push({type:e,src:t,dst:n})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,a()}setCssStyle(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(!t||!e)return;for(let n of t)n.includes(`,`)?e.cssStyles.push(...n.split(`,`)):e.cssStyles.push(n)}}setClass(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(e)for(let n of t){e.classes.push(n);let t=this.classes.get(n)?.styles;t&&e.cssStyles.push(...t)}}}defineClass(e,t){for(let n of e){let e=this.classes.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.classes.set(n,e)),t&&t.forEach(function(t){if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.requirements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))}),this.elements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))})}}getClasses(){return this.classes}getData(){let e=u(),t=[],n=[];for(let n of this.requirements.values()){let r=n;r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.shape=`requirementBox`,r.look=e.look,r.colorIndex=t.length,t.push(r)}for(let n of this.elements.values()){let r=n;r.shape=`requirementBox`,r.look=e.look,r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.colorIndex=t.length,t.push(r)}let r=0;for(let t of this.relations){let i=t.type===this.Relationships.CONTAINS,a={id:`${t.src}-${t.dst}-${r++}`,start:this.requirements.get(t.src)?.name??this.elements.get(t.src)?.name,end:this.requirements.get(t.dst)?.name??this.elements.get(t.dst)?.name,label:`<<${t.type}>>`,classes:`relationshipLine`,style:[`fill:none`,i?``:`stroke-dasharray: 10,7`],labelpos:`c`,thickness:`normal`,type:`normal`,pattern:i?`normal`:`dashed`,arrowTypeStart:i?`requirement_contains`:``,arrowTypeEnd:i?``:`requirement_arrow`,look:e.look,labelType:`markdown`};n.push(a)}return{nodes:t,edges:n,other:{},config:e,direction:this.getDirection()}}},w=t(()=>{let e=o(),{theme:t,themeVariables:n}=e,{bkgColorArray:r,borderColorArray:i}=n;if(!m(t,i))return``;let a=h(e.look),s=``,c=g(r);for(let e=0;e{let{look:t,themeVariables:n}=o(),{requirementEdgeLabelBackground:r}=n;return` + ${w()} + marker { + fill: ${e.relationColor}; + stroke: ${e.relationColor}; + } + + marker.cross { + stroke: ${e.lineColor}; + } + + svg { + font-family: ${e.fontFamily}; + font-size: ${e.fontSize}; + } + + .reqBox { + fill: ${e.requirementBackground}; + fill-opacity: 1.0; + stroke: ${e.requirementBorderColor}; + stroke-width: ${e.requirementBorderSize}; + } + + .reqTitle, .reqLabel{ + fill: ${e.requirementTextColor}; + } + .reqLabelBox { + fill: ${e.relationLabelBackground}; + fill-opacity: 1.0; + } + + .req-title-line { + stroke: ${e.requirementBorderColor}; + stroke-width: ${e.requirementBorderSize}; + } + .relationshipLine { + stroke: ${e.relationColor}; + stroke-width: ${t===`neo`?e.strokeWidth:`1px`}; + } + .relationshipLabel { + fill: ${e.relationLabelColor}; + } + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + } + .edgeLabel .label rect { + fill: ${e.edgeLabelBackground}; + } + .edgeLabel .label text { + fill: ${e.relationLabelColor}; + } + .divider { + stroke: ${e.nodeBorder}; + stroke-width: 1; + } + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + .labelBkg { + background-color: ${r??e.edgeLabelBackground}; + } + +`},`getStyles`),E={};n(E,{draw:()=>D});var D=t(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing requirement diagram (unified)`,n);let{securityLevel:a,state:o,layout:s,look:c}=u(),l=i.db.getData(),d=y(n,a);l.type=i.type,l.layoutAlgorithm=v(s),l.nodeSpacing=o?.nodeSpacing??50,l.rankSpacing=o?.rankSpacing??50,l.markers=c===`neo`?[`requirement_contains_neo`,`requirement_arrow_neo`]:[`requirement_contains`,`requirement_arrow`],l.diagramId=n,await _(l,d),f.insertTitle(d,`requirementDiagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),b(d,8,`requirementDiagram`,o?.useMaxWidth??!0)},`draw`),O={parser:S,get db(){return new C},renderer:E,styles:T};export{O as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/rough.esm-Dy-Kn_BL.js b/frontend/dist/assets/rough.esm-Dy-Kn_BL.js new file mode 100644 index 0000000..e503ecf --- /dev/null +++ b/frontend/dist/assets/rough.esm-Dy-Kn_BL.js @@ -0,0 +1 @@ +function e(e,t,n){if(e&&e.length){let[r,i]=t,a=Math.PI/180*n,o=Math.cos(a),s=Math.sin(a);for(let t of e){let[e,n]=t;t[0]=(e-r)*o-(n-i)*s+r,t[1]=(e-r)*s+(n-i)*o+i}}}function t(e,t){return e[0]===t[0]&&e[1]===t[1]}function n(n,r,i,a=1){let o=i,s=Math.max(r,.1),c=n[0]&&n[0][0]&&typeof n[0][0]==`number`?[n]:n,l=[0,0];if(o)for(let t of c)e(t,l,o);let u=function(e,n,r){let i=[];for(let n of e){let e=[...n];t(e[0],e[e.length-1])||e.push([e[0][0],e[0][1]]),e.length>2&&i.push(e)}let a=[];n=Math.max(n,.1);let o=[];for(let e of i)for(let t=0;te.ymint.ymin?1:e.xt.x?1:e.ymax===t.ymax?0:(e.ymax-t.ymax)/Math.abs(e.ymax-t.ymax))),!o.length)return a;let s=[],c=o[0].ymin,l=0;for(;s.length||o.length;){if(o.length){let e=-1;for(let t=0;tc);t++)e=t;o.splice(0,e+1).forEach((e=>{s.push({s:c,edge:e})}))}if(s=s.filter((e=>!(e.edge.ymax<=c))),s.sort(((e,t)=>e.edge.x===t.edge.x?0:(e.edge.x-t.edge.x)/Math.abs(e.edge.x-t.edge.x))),(r!==1||l%n==0)&&s.length>1)for(let e=0;e=s.length)break;let n=s[e].edge,r=s[t].edge;a.push([[Math.round(n.x),c],[Math.round(r.x),c]])}c+=r,s.forEach((e=>{e.edge.x=e.edge.x+r*e.edge.islope})),l++}return a}(c,s,a);if(o){for(let t of c)e(t,l,-o);(function(t,n,r){let i=[];t.forEach((e=>i.push(...e))),e(i,n,r)})(u,l,-o)}return u}function r(e,t){let r=t.hachureAngle+90,i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let a=1;return t.roughness>=1&&(t.randomizer?.next()||Math.random())>.7&&(a=i),n(e,i,r,a||1)}var i=class{constructor(e){this.helper=e}fillPolygons(e,t){return this._fillPolygons(e,t)}_fillPolygons(e,t){let n=r(e,t);return{type:`fillSketch`,ops:this.renderLines(n,t)}}renderLines(e,t){let n=[];for(let r of e)n.push(...this.helper.doubleLineOps(r[0][0],r[0][1],r[1][0],r[1][1],t));return n}};function a(e){let t=e[0],n=e[1];return Math.sqrt((t[0]-n[0])**2+(t[1]-n[1])**2)}var o=class extends i{fillPolygons(e,t){let n=t.hachureGap;n<0&&(n=4*t.strokeWidth),n=Math.max(n,.1);let i=r(e,Object.assign({},t,{hachureGap:n})),o=Math.PI/180*t.hachureAngle,s=[],c=.5*n*Math.cos(o),l=.5*n*Math.sin(o);for(let[e,t]of i)a([e,t])&&s.push([[e[0]-c,e[1]+l],[...t]],[[e[0]+c,e[1]-l],[...t]]);return{type:`fillSketch`,ops:this.renderLines(s,t)}}},s=class extends i{fillPolygons(e,t){let n=this._fillPolygons(e,t),r=Object.assign({},t,{hachureAngle:t.hachureAngle+90}),i=this._fillPolygons(e,r);return n.ops=n.ops.concat(i.ops),n}},c=class{constructor(e){this.helper=e}fillPolygons(e,t){let n=r(e,t=Object.assign({},t,{hachureAngle:0}));return this.dotsOnLines(n,t)}dotsOnLines(e,t){let n=[],r=t.hachureGap;r<0&&(r=4*t.strokeWidth),r=Math.max(r,.1);let i=t.fillWeight;i<0&&(i=t.strokeWidth/2);let o=r/4;for(let s of e){let e=a(s),c=e/r,l=Math.ceil(c)-1,u=e-l*r,d=(s[0][0]+s[1][0])/2-r/4,f=Math.min(s[0][1],s[1][1]);for(let e=0;e{let o=a(e),s=Math.floor(o/(n+r)),c=(o+r-s*(n+r))/2,l=e[0],u=e[1];l[0]>u[0]&&(l=e[1],u=e[0]);let d=Math.atan((u[1]-l[1])/(u[0]-l[0]));for(let e=0;e{let i=a(e),o=Math.round(i/(2*t)),s=e[0],c=e[1];s[0]>c[0]&&(s=e[1],c=e[0]);let l=Math.atan((c[1]-s[1])/(c[0]-s[0]));for(let e=0;er%2?e+n:e+t));a.push({key:`C`,data:e}),t=e[4],n=e[5];break}case`Q`:a.push({key:`Q`,data:[...s]}),t=s[2],n=s[3];break;case`q`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`Q`,data:e}),t=e[2],n=e[3];break}case`A`:a.push({key:`A`,data:[...s]}),t=s[5],n=s[6];break;case`a`:t+=s[5],n+=s[6],a.push({key:`A`,data:[s[0],s[1],s[2],s[3],s[4],t,n]});break;case`H`:a.push({key:`H`,data:[...s]}),t=s[0];break;case`h`:t+=s[0],a.push({key:`H`,data:[t]});break;case`V`:a.push({key:`V`,data:[...s]}),n=s[0];break;case`v`:n+=s[0],a.push({key:`V`,data:[n]});break;case`S`:a.push({key:`S`,data:[...s]}),t=s[2],n=s[3];break;case`s`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`S`,data:e}),t=e[2],n=e[3];break}case`T`:a.push({key:`T`,data:[...s]}),t=s[0],n=s[1];break;case`t`:t+=s[0],n+=s[1],a.push({key:`T`,data:[t,n]});break;case`Z`:case`z`:a.push({key:`Z`,data:[]}),t=r,n=i}return a}function b(e){let t=[],n=``,r=0,i=0,a=0,o=0,s=0,c=0;for(let{key:l,data:u}of e){switch(l){case`M`:t.push({key:`M`,data:[...u]}),[r,i]=u,[a,o]=u;break;case`C`:t.push({key:`C`,data:[...u]}),r=u[4],i=u[5],s=u[2],c=u[3];break;case`L`:t.push({key:`L`,data:[...u]}),[r,i]=u;break;case`H`:r=u[0],t.push({key:`L`,data:[r,i]});break;case`V`:i=u[0],t.push({key:`L`,data:[r,i]});break;case`S`:{let e=0,a=0;n===`C`||n===`S`?(e=r+(r-s),a=i+(i-c)):(e=r,a=i),t.push({key:`C`,data:[e,a,...u]}),s=u[0],c=u[1],r=u[2],i=u[3];break}case`T`:{let[e,a]=u,o=0,l=0;n===`Q`||n===`T`?(o=r+(r-s),l=i+(i-c)):(o=r,l=i);let d=r+2*(o-r)/3,f=i+2*(l-i)/3,p=e+2*(o-e)/3,m=a+2*(l-a)/3;t.push({key:`C`,data:[d,f,p,m,e,a]}),s=o,c=l,r=e,i=a;break}case`Q`:{let[e,n,a,o]=u,l=r+2*(e-r)/3,d=i+2*(n-i)/3,f=a+2*(e-a)/3,p=o+2*(n-o)/3;t.push({key:`C`,data:[l,d,f,p,a,o]}),s=e,c=n,r=a,i=o;break}case`A`:{let e=Math.abs(u[0]),n=Math.abs(u[1]),a=u[2],o=u[3],s=u[4],c=u[5],l=u[6];e===0||n===0?(t.push({key:`C`,data:[r,i,c,l,c,l]}),r=c,i=l):(r!==c||i!==l)&&(S(r,i,c,l,e,n,a,o,s).forEach((function(e){t.push({key:`C`,data:e})})),r=c,i=l);break}case`Z`:t.push({key:`Z`,data:[]}),r=a,i=o}n=l}return t}function x(e,t,n){return[e*Math.cos(n)-t*Math.sin(n),e*Math.sin(n)+t*Math.cos(n)]}function S(e,t,n,r,i,a,o,s,c,l){let u=(d=o,Math.PI*d/180);var d;let f=[],p=0,m=0,h=0,g=0;if(l)[p,m,h,g]=l;else{[e,t]=x(e,t,-u),[n,r]=x(n,r,-u);let o=(e-n)/2,l=(t-r)/2,d=o*o/(i*i)+l*l/(a*a);d>1&&(d=Math.sqrt(d),i*=d,a*=d);let f=i*i,_=a*a,v=f*_-f*l*l-_*o*o,y=f*l*l+_*o*o,b=(s===c?-1:1)*Math.sqrt(Math.abs(v/y));h=b*i*l/a+(e+n)/2,g=b*-a*o/i+(t+r)/2,p=Math.asin(parseFloat(((t-g)/a).toFixed(9))),m=Math.asin(parseFloat(((r-g)/a).toFixed(9))),em&&(p-=2*Math.PI),!c&&m>p&&(m-=2*Math.PI)}let _=m-p;if(Math.abs(_)>120*Math.PI/180){let e=m,t=n,s=r;m=c&&m>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,f=S(n=h+i*Math.cos(m),r=g+a*Math.sin(m),t,s,i,a,o,0,c,[m,e,h,g])}_=m-p;let v=Math.cos(p),y=Math.sin(p),b=Math.cos(m),C=Math.sin(m),w=Math.tan(_/4),T=4/3*i*w,E=4/3*a*w,D=[e,t],O=[e+T*y,t-E*v],k=[n+T*C,r-E*b],A=[n,r];if(O[0]=2*D[0]-O[0],O[1]=2*D[1]-O[1],l)return[O,k,A].concat(f);{f=[O,k,A].concat(f);let e=[];for(let t=0;t2){let i=[];for(let t=0;t2*Math.PI&&(p=0,m=2*Math.PI);let h=2*Math.PI/c.curveStepCount,g=Math.min(h/2,(m-p)/2),_=U(g,l,u,d,f,p,m,1,c);if(!c.disableMultiStroke){let e=U(g,l,u,d,f,p,m,1.5,c);_.push(...e)}return o&&(s?_.push(...R(l,u,l+d*Math.cos(p),u+f*Math.sin(p),c),...R(l,u,l+d*Math.cos(m),u+f*Math.sin(m),c)):_.push({op:`lineTo`,data:[l,u]},{op:`lineTo`,data:[l+d*Math.cos(p),u+f*Math.sin(p)]})),{type:`path`,ops:_}}function j(e,t){let n=b(y(v(e))),r=[],i=[0,0],a=[0,0];for(let{key:e,data:o}of n)switch(e){case`M`:a=[o[0],o[1]],i=[o[0],o[1]];break;case`L`:r.push(...R(a[0],a[1],o[0],o[1],t)),a=[o[0],o[1]];break;case`C`:{let[e,n,i,s,c,l]=o;r.push(...ee(e,n,i,s,c,l,a,t)),a=[c,l];break}case`Z`:r.push(...R(a[0],a[1],i[0],i[1],t)),a=[i[0],i[1]]}return{type:`path`,ops:r}}function M(e,t){let n=[];for(let r of e)if(r.length){let e=t.maxRandomnessOffset||0,i=r.length;if(i>2){n.push({op:`move`,data:[r[0][0]+L(e,t),r[0][1]+L(e,t)]});for(let a=1;a500?.4:-.0016668*c+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>s&&(u=c/10);let d=u/2,f=.2+.2*F(i),p=i.bowing*i.maxRandomnessOffset*(r-t)/200,m=i.bowing*i.maxRandomnessOffset*(e-n)/200;p=L(p,i,l),m=L(m,i,l);let h=[],g=()=>L(d,i,l),_=()=>L(u,i,l),v=i.preserveVertices;return a&&(o?h.push({op:`move`,data:[e+(v?0:g()),t+(v?0:g())]}):h.push({op:`move`,data:[e+(v?0:L(u,i,l)),t+(v?0:L(u,i,l))]})),o?h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+g(),m+t+(r-t)*f+g(),p+e+2*(n-e)*f+g(),m+t+2*(r-t)*f+g(),n+(v?0:g()),r+(v?0:g())]}):h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+_(),m+t+(r-t)*f+_(),p+e+2*(n-e)*f+_(),m+t+2*(r-t)*f+_(),n+(v?0:_()),r+(v?0:_())]}),h}function B(e,t,n){if(!e.length)return[];let r=[];r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]),r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]);for(let i=1;i3){let a=[],o=1-n.curveTightness;i.push({op:`move`,data:[e[1][0],e[1][1]]});for(let t=1;t+21&&i.push(n)):i.push(n),i.push(e[t+3])}else{let r=.5,a=e[t+0],o=e[t+1],s=e[t+2],c=e[t+3],l=q(a,o,r),u=q(o,s,r),d=q(s,c,r),f=q(l,u,r),p=q(u,d,r),m=q(f,p,r);J([a,l,f,m],0,n,i),J([m,p,d,c],0,n,i)}var a,o;return i}function ne(e,t){return Y(e,0,e.length,t)}function Y(e,t,n,r,i){let a=i||[],o=e[t],s=e[n-1],c=0,l=1;for(let r=t+1;rc&&(c=t,l=r)}return Math.sqrt(c)>r?(Y(e,t,l+1,r,a),Y(e,l,n,r,a)):(a.length||a.push(o),a.push(s)),a}function X(e,t=.15,n){let r=[],i=(e.length-1)/3;for(let n=0;n0?Y(r,0,r.length,n):r}var Z=`none`,Q=class{constructor(e){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:`#000`,strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:`hachure`,fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=e||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(e){return e?Object.assign({},this.defaultOptions,e):this.defaultOptions}_d(e,t,n){return{shape:e,sets:t||[],options:n||this.defaultOptions}}line(e,t,n,r,i){let a=this._o(i);return this._d(`line`,[w(e,t,n,r,a)],a)}rectangle(e,t,n,r,i){let a=this._o(i),o=[],s=E(e,t,n,r,a);if(a.fill){let i=[[e,t],[e+n,t],[e+n,t+r],[e,t+r]];a.fillStyle===`solid`?o.push(M([i],a)):o.push(N([i],a))}return a.stroke!==Z&&o.push(s),this._d(`rectangle`,o,a)}ellipse(e,t,n,r,i){let a=this._o(i),o=[],s=O(n,r,a),c=k(e,t,a,s);if(a.fill){if(a.fillStyle===`solid`){let n=k(e,t,a,s).opset;n.type=`fillPath`,o.push(n)}else o.push(N([c.estimatedPoints],a))}return a.stroke!==Z&&o.push(c.opset),this._d(`ellipse`,o,a)}circle(e,t,n,r){let i=this.ellipse(e,t,n,n,r);return i.shape=`circle`,i}linearPath(e,t){let n=this._o(t);return this._d(`linearPath`,[T(e,!1,n)],n)}arc(e,t,n,r,i,a,o=!1,s){let c=this._o(s),l=[],u=A(e,t,n,r,i,a,o,!0,c);if(o&&c.fill){if(c.fillStyle===`solid`){let o=Object.assign({},c);o.disableMultiStroke=!0;let s=A(e,t,n,r,i,a,!0,!1,o);s.type=`fillPath`,l.push(s)}else l.push(function(e,t,n,r,i,a,o){let s=e,c=t,l=Math.abs(n/2),u=Math.abs(r/2);l+=L(.01*l,o),u+=L(.01*u,o);let d=i,f=a;for(;d<0;)d+=2*Math.PI,f+=2*Math.PI;f-d>2*Math.PI&&(d=0,f=2*Math.PI);let p=(f-d)/o.curveStepCount,m=[];for(let e=d;e<=f;e+=p)m.push([s+l*Math.cos(e),c+u*Math.sin(e)]);return m.push([s+l*Math.cos(f),c+u*Math.sin(f)]),m.push([s,c]),N([m],o)}(e,t,n,r,i,a,c))}return c.stroke!==Z&&l.push(u),this._d(`arc`,l,c)}curve(e,t){let n=this._o(t),r=[],i=D(e,n);if(n.fill&&n.fill!==Z){if(n.fillStyle===`solid`){let t=D(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else{let t=[],i=e;if(i.length){let e=typeof i[0][0]==`number`?[i]:i;for(let r of e)r.length<3?t.push(...r):r.length===3?t.push(...X(G([r[0],r[0],r[1],r[2]]),10,(1+n.roughness)/2)):t.push(...X(G(r),10,(1+n.roughness)/2))}t.length&&r.push(N([t],n))}}return n.stroke!==Z&&r.push(i),this._d(`curve`,r,n)}polygon(e,t){let n=this._o(t),r=[],i=T(e,!0,n);return n.fill&&(n.fillStyle===`solid`?r.push(M([e],n)):r.push(N([e],n))),n.stroke!==Z&&r.push(i),this._d(`polygon`,r,n)}path(e,t){let n=this._o(t),r=[];if(!e)return this._d(`path`,r,n);e=(e||``).replace(/\n/g,` `).replace(/(-\s)/g,`-`).replace(`/(ss)/g`,` `);let i=n.fill&&n.fill!==`transparent`&&n.fill!==Z,a=n.stroke!==Z,o=!!(n.simplification&&n.simplification<1),s=function(e,t,n){let r=b(y(v(e))),i=[],a=[],o=[0,0],s=[],c=()=>{s.length>=4&&a.push(...X(s,t)),s=[]},l=()=>{c(),a.length&&(i.push(a),a=[])};for(let{key:e,data:t}of r)switch(e){case`M`:l(),o=[t[0],t[1]],a.push(o);break;case`L`:c(),a.push([t[0],t[1]]);break;case`C`:if(!s.length){let e=a.length?a[a.length-1]:o;s.push([e[0],e[1]])}s.push([t[0],t[1]]),s.push([t[2],t[3]]),s.push([t[4],t[5]]);break;case`Z`:c(),a.push([o[0],o[1]])}if(l(),!n)return i;let u=[];for(let e of i){let t=ne(e,n);t.length&&u.push(t)}return u}(e,1,o?4-4*(n.simplification||1):(1+n.roughness)/2),c=j(e,n);if(i){if(n.fillStyle===`solid`){if(s.length===1){let t=j(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else r.push(M(s,n))}else r.push(N(s,n))}return a&&(o?s.forEach((e=>{r.push(T(e,!1,n))})):r.push(c)),this._d(`path`,r,n)}opsToPath(e,t){let n=``;for(let r of e.ops){let e=typeof t==`number`&&t>=0?r.data.map((e=>+e.toFixed(t))):r.data;switch(r.op){case`move`:n+=`M${e[0]} ${e[1]} `;break;case`bcurveTo`:n+=`C${e[0]} ${e[1]}, ${e[2]} ${e[3]}, ${e[4]} ${e[5]} `;break;case`lineTo`:n+=`L${e[0]} ${e[1]} `}}return n.trim()}toPaths(e){let t=e.sets||[],n=e.options||this.defaultOptions,r=[];for(let e of t){let t=null;switch(e.type){case`path`:t={d:this.opsToPath(e),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:Z};break;case`fillPath`:t={d:this.opsToPath(e),stroke:Z,strokeWidth:0,fill:n.fill||Z};break;case`fillSketch`:t=this.fillSketch(e,n)}t&&r.push(t)}return r}fillSketch(e,t){let n=t.fillWeight;return n<0&&(n=t.strokeWidth/2),{d:this.opsToPath(e),stroke:t.fill||Z,strokeWidth:n,fill:Z}}_mergedShape(e){return e.filter(((e,t)=>t===0||e.op!==`move`))}},re=class{constructor(e,t){this.canvas=e,this.ctx=this.canvas.getContext(`2d`),this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.ctx,i=e.options.fixedDecimalPlaceDigits;for(let a of t)switch(a.type){case`path`:r.save(),r.strokeStyle=n.stroke===`none`?`transparent`:n.stroke,r.lineWidth=n.strokeWidth,n.strokeLineDash&&r.setLineDash(n.strokeLineDash),n.strokeLineDashOffset&&(r.lineDashOffset=n.strokeLineDashOffset),this._drawToContext(r,a,i),r.restore();break;case`fillPath`:{r.save(),r.fillStyle=n.fill||``;let t=e.shape===`curve`||e.shape===`polygon`||e.shape===`path`?`evenodd`:`nonzero`;this._drawToContext(r,a,i,t),r.restore();break}case`fillSketch`:this.fillSketch(r,a,n)}}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2),e.save(),n.fillLineDash&&e.setLineDash(n.fillLineDash),n.fillLineDashOffset&&(e.lineDashOffset=n.fillLineDashOffset),e.strokeStyle=n.fill||``,e.lineWidth=r,this._drawToContext(e,t,n.fixedDecimalPlaceDigits),e.restore()}_drawToContext(e,t,n,r=`nonzero`){e.beginPath();for(let r of t.ops){let t=typeof n==`number`&&n>=0?r.data.map((e=>+e.toFixed(n))):r.data;switch(r.op){case`move`:e.moveTo(t[0],t[1]);break;case`bcurveTo`:e.bezierCurveTo(t[0],t[1],t[2],t[3],t[4],t[5]);break;case`lineTo`:e.lineTo(t[0],t[1])}}t.type===`fillPath`?e.fill(r):e.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a),a}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a),a}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a),a}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i),i}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n),n}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n),n}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c),c}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n),n}path(e,t){let n=this.gen.path(e,t);return this.draw(n),n}},$=`http://www.w3.org/2000/svg`,ie=class{constructor(e,t){this.svg=e,this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.svg.ownerDocument||window.document,i=r.createElementNS($,`g`),a=e.options.fixedDecimalPlaceDigits;for(let o of t){let t=null;switch(o.type){case`path`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,n.stroke),t.setAttribute(`stroke-width`,n.strokeWidth+``),t.setAttribute(`fill`,`none`),n.strokeLineDash&&t.setAttribute(`stroke-dasharray`,n.strokeLineDash.join(` `).trim()),n.strokeLineDashOffset&&t.setAttribute(`stroke-dashoffset`,`${n.strokeLineDashOffset}`);break;case`fillPath`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,`none`),t.setAttribute(`stroke-width`,`0`),t.setAttribute(`fill`,n.fill||``),e.shape!==`curve`&&e.shape!==`polygon`||t.setAttribute(`fill-rule`,`evenodd`);break;case`fillSketch`:t=this.fillSketch(r,o,n)}t&&i.appendChild(t)}return i}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2);let i=e.createElementNS($,`path`);return i.setAttribute(`d`,this.opsToPath(t,n.fixedDecimalPlaceDigits)),i.setAttribute(`stroke`,n.fill||``),i.setAttribute(`stroke-width`,r+``),i.setAttribute(`fill`,`none`),n.fillLineDash&&i.setAttribute(`stroke-dasharray`,n.fillLineDash.join(` `).trim()),n.fillLineDashOffset&&i.setAttribute(`stroke-dashoffset`,`${n.fillLineDashOffset}`),i}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(e,t){return this.gen.opsToPath(e,t)}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a)}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a)}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a)}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i)}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n)}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n)}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c)}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n)}path(e,t){let n=this.gen.path(e,t);return this.draw(n)}},ae={canvas:(e,t)=>new re(e,t),svg:(e,t)=>new ie(e,t),generator:e=>new Q(e),newSeed:()=>Q.newSeed()};export{ae as t}; \ No newline at end of file diff --git a/frontend/dist/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js b/frontend/dist/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js new file mode 100644 index 0000000..c314c67 --- /dev/null +++ b/frontend/dist/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js @@ -0,0 +1,40 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,Y as i,a,d as o,q as s,s as c,v as l,w as u,x as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as p}from"./ordinal-BDEzSJ7C.js";function m(e){for(var t=e.length/6|0,n=Array(t),r=0;r=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function _(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function v(e,t){let n=0;if(t===void 0)for(let t of e)(t=+t)&&(n+=t);else{let r=-1;for(let i of e)(i=+t(i,++r,e))&&(n+=i)}return n}function y(e){return e.target.depth}function b(e){return e.depth}function x(e,t){return t-1-e.height}function S(e,t){return e.sourceLinks.length?e.depth:t-1}function C(e){return e.targetLinks.length?e.depth:e.sourceLinks.length?_(e.sourceLinks,y)-1:0}function w(e){return function(){return e}}function T(e,t){return D(e.source,t.source)||e.index-t.index}function E(e,t){return D(e.target,t.target)||e.index-t.index}function D(e,t){return e.y0-t.y0}function O(e){return e.value}function k(e){return e.index}function A(e){return e.nodes}function j(e){return e.links}function M(e,t){let n=e.get(t);if(!n)throw Error(`missing: `+t);return n}function N({nodes:e}){for(let t of e){let e=t.y0,n=e;for(let n of t.sourceLinks)n.y0=e+n.width/2,e+=n.width;for(let e of t.targetLinks)e.y1=n+e.width/2,n+=e.width}}function P(){let e=0,t=0,n=1,r=1,i=24,a=8,o,s=k,c=S,l,u,d=A,f=j,p=6;function m(){let e={nodes:d.apply(null,arguments),links:f.apply(null,arguments)};return h(e),y(e),b(e),x(e),F(e),N(e),e}m.update=function(e){return N(e),e},m.nodeId=function(e){return arguments.length?(s=typeof e==`function`?e:w(e),m):s},m.nodeAlign=function(e){return arguments.length?(c=typeof e==`function`?e:w(e),m):c},m.nodeSort=function(e){return arguments.length?(l=e,m):l},m.nodeWidth=function(e){return arguments.length?(i=+e,m):i},m.nodePadding=function(e){return arguments.length?(a=o=+e,m):a},m.nodes=function(e){return arguments.length?(d=typeof e==`function`?e:w(e),m):d},m.links=function(e){return arguments.length?(f=typeof e==`function`?e:w(e),m):f},m.linkSort=function(e){return arguments.length?(u=e,m):u},m.size=function(i){return arguments.length?(e=t=0,n=+i[0],r=+i[1],m):[n-e,r-t]},m.extent=function(i){return arguments.length?(e=+i[0][0],n=+i[1][0],t=+i[0][1],r=+i[1][1],m):[[e,t],[n,r]]},m.iterations=function(e){return arguments.length?(p=+e,m):p};function h({nodes:e,links:t}){for(let[t,n]of e.entries())n.index=t,n.sourceLinks=[],n.targetLinks=[];let n=new Map(e.map((t,n)=>[s(t,n,e),t]));for(let[e,r]of t.entries()){r.index=e;let{source:t,target:i}=r;typeof t!=`object`&&(t=r.source=M(n,t)),typeof i!=`object`&&(i=r.target=M(n,i)),t.sourceLinks.push(r),i.targetLinks.push(r)}if(u!=null)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(u),n.sort(u)}function y({nodes:e}){for(let t of e)t.value=t.fixedValue===void 0?Math.max(v(t.sourceLinks,O),v(t.targetLinks,O)):t.fixedValue}function b({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.depth=i;for(let{target:t}of e.sourceLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function x({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.height=i;for(let{source:t}of e.targetLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function C({nodes:t}){let r=g(t,e=>e.depth)+1,a=(n-e-i)/(r-1),o=Array(r);for(let n of t){let t=Math.max(0,Math.min(r-1,Math.floor(c.call(null,n,r))));n.layer=t,n.x0=e+t*a,n.x1=n.x0+i,o[t]?o[t].push(n):o[t]=[n]}if(l)for(let e of o)e.sort(l);return o}function P(e){let n=_(e,e=>(r-t-(e.length-1)*o)/v(e,O));for(let i of e){let e=t;for(let t of i){t.y0=e,t.y1=e+t.value*n,e=t.y1+o;for(let e of t.sourceLinks)e.width=e.value*n}e=(r-e+o)/(i.length+1);for(let t=0;te.length)-1)),P(n);for(let e=0;e0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function L(e,t,n){for(let r=e.length-2;r>=0;--r){let i=e[r];for(let e of i){let n=0,r=0;for(let{target:t,value:i}of e.sourceLinks){let a=i*(t.layer-e.layer);n+=W(e,t)*a,r+=a}if(!(r>0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function R(e,n){let i=e.length>>1,a=e[i];B(e,a.y0-o,i-1,n),z(e,a.y1+o,i+1,n),B(e,r,e.length-1,n),z(e,t,0,n)}function z(e,t,n,r){for(;n1e-6&&(i.y0+=a,i.y1+=a),t=i.y1+o}}function B(e,t,n,r){for(;n>=0;--n){let i=e[n],a=(i.y1-t)*r;a>1e-6&&(i.y0-=a,i.y1-=a),t=i.y0-o}}function V({sourceLinks:e,targetLinks:t}){if(u===void 0){for(let{source:{sourceLinks:e}}of t)e.sort(E);for(let{target:{targetLinks:t}}of e)t.sort(T)}}function H(e){if(u===void 0)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(E),n.sort(T)}function U(e,t){let n=e.y0-(e.sourceLinks.length-1)*o/2;for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n+=i+o}for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n-=i}return n}function W(e,t){let n=t.y0-(t.targetLinks.length-1)*o/2;for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n+=i+o}for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n-=i}return n}return m}var F=Math.PI,I=2*F,L=1e-6,R=I-L;function z(){this._x0=this._y0=this._x1=this._y1=null,this._=``}function B(){return new z}z.prototype=B.prototype={constructor:z,moveTo:function(e,t){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+=`Z`)},lineTo:function(e,t){this._+=`L`+(this._x1=+e)+`,`+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+=`Q`+ +e+`,`+ +t+`,`+(this._x1=+n)+`,`+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,i,a){this._+=`C`+ +e+`,`+ +t+`,`+ +n+`,`+ +r+`,`+(this._x1=+i)+`,`+(this._y1=+a)},arcTo:function(e,t,n,r,i){e=+e,t=+t,n=+n,r=+r,i=+i;var a=this._x1,o=this._y1,s=n-e,c=r-t,l=a-e,u=o-t,d=l*l+u*u;if(i<0)throw Error(`negative radius: `+i);if(this._x1===null)this._+=`M`+(this._x1=e)+`,`+(this._y1=t);else if(d>L){if(!(Math.abs(u*s-c*l)>L)||!i)this._+=`L`+(this._x1=e)+`,`+(this._y1=t);else{var f=n-a,p=r-o,m=s*s+c*c,h=f*f+p*p,g=Math.sqrt(m),_=Math.sqrt(d),v=i*Math.tan((F-Math.acos((m+d-h)/(2*g*_)))/2),y=v/_,b=v/g;Math.abs(y-1)>L&&(this._+=`L`+(e+y*l)+`,`+(t+y*u)),this._+=`A`+i+`,`+i+`,0,0,`+ +(u*f>l*p)+`,`+(this._x1=e+b*s)+`,`+(this._y1=t+b*c)}}},arc:function(e,t,n,r,i,a){e=+e,t=+t,n=+n,a=!!a;var o=n*Math.cos(r),s=n*Math.sin(r),c=e+o,l=t+s,u=1^a,d=a?r-i:i-r;if(n<0)throw Error(`negative radius: `+n);this._x1===null?this._+=`M`+c+`,`+l:(Math.abs(this._x1-c)>L||Math.abs(this._y1-l)>L)&&(this._+=`L`+c+`,`+l),n&&(d<0&&(d=d%I+I),d>R?this._+=`A`+n+`,`+n+`,0,1,`+u+`,`+(e-o)+`,`+(t-s)+`A`+n+`,`+n+`,0,1,`+u+`,`+(this._x1=c)+`,`+(this._y1=l):d>L&&(this._+=`A`+n+`,`+n+`,0,`+ +(d>=F)+`,`+u+`,`+(this._x1=e+n*Math.cos(i))+`,`+(this._y1=t+n*Math.sin(i))))},rect:function(e,t,n,r){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)+`h`+ +n+`v`+ +r+`h`+-n+`Z`},toString:function(){return this._}};function V(e){return function(){return e}}function H(e){return e[0]}function U(e){return e[1]}var W=Array.prototype.slice;function G(e){return e.source}function ee(e){return e.target}function te(e){var t=G,n=ee,r=H,i=U,a=null;function o(){var o,s=W.call(arguments),c=t.apply(this,s),l=n.apply(this,s);if(a||=o=B(),e(a,+r.apply(this,(s[0]=c,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),o)return a=null,o+``||null}return o.source=function(e){return arguments.length?(t=e,o):t},o.target=function(e){return arguments.length?(n=e,o):n},o.x=function(e){return arguments.length?(r=typeof e==`function`?e:V(+e),o):r},o.y=function(e){return arguments.length?(i=typeof e==`function`?e:V(+e),o):i},o.context=function(e){return arguments.length?(a=e??null,o):a},o}function ne(e,t,n,r,i){e.moveTo(t,n),e.bezierCurveTo(t=(t+r)/2,n,t,i,r,i)}function re(){return te(ne)}function ie(e){return[e.source.x1,e.y0]}function ae(e){return[e.target.x0,e.y1]}function K(){return re().source(ie).target(ae)}var q=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,9],r=[1,10],i=[1,5,10,12],a={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SANKEY:4,NEWLINE:5,csv:6,opt_eof:7,record:8,csv_tail:9,EOF:10,"field[source]":11,COMMA:12,"field[target]":13,"field[value]":14,field:15,escaped:16,non_escaped:17,DQUOTE:18,ESCAPED_TEXT:19,NON_ESCAPED_TEXT:20,$accept:0,$end:1},terminals_:{2:`error`,4:`SANKEY`,5:`NEWLINE`,10:`EOF`,11:`field[source]`,12:`COMMA`,13:`field[target]`,14:`field[value]`,18:`DQUOTE`,19:`ESCAPED_TEXT`,20:`NON_ESCAPED_TEXT`},productions_:[0,[3,4],[6,2],[9,2],[9,0],[7,1],[7,0],[8,5],[15,1],[15,1],[16,3],[17,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 7:let e=r.findOrCreateNode(a[s-4].trim().replaceAll(`""`,`"`)),t=r.findOrCreateNode(a[s-2].trim().replaceAll(`""`,`"`)),n=parseFloat(a[s].trim());r.addLink(e,t,n);break;case 8:case 9:case 11:this.$=a[s];break;case 10:this.$=a[s-1]}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3]},{6:4,8:5,15:6,16:7,17:8,18:n,20:r},{1:[2,6],7:11,10:[1,12]},e(r,[2,4],{9:13,5:[1,14]}),{12:[1,15]},e(i,[2,8]),e(i,[2,9]),{19:[1,16]},e(i,[2,11]),{1:[2,1]},{1:[2,5]},e(r,[2,2]),{6:17,8:5,15:6,16:7,17:8,18:n,20:r},{15:18,16:7,17:8,18:n,20:r},{18:[1,19]},e(r,[2,3]),{12:[1,20]},e(i,[2,10]),{15:21,16:7,17:8,18:n,20:r},e([1,5,10],[2,7])],defaultActions:{11:[2,1],12:[2,5]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};a.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return this.pushState(`csv`),4;case 1:return this.pushState(`csv`),4;case 2:return 10;case 3:return 5;case 4:return 12;case 5:return this.pushState(`escaped_text`),18;case 6:return 20;case 7:return this.popState(`escaped_text`),18;case 8:return 19}},`anonymous`),rules:[/^(?:sankey-beta\b)/i,/^(?:sankey\b)/i,/^(?:$)/i,/^(?:((\u000D\u000A)|(\u000A)))/i,/^(?:(\u002C))/i,/^(?:(\u0022))/i,/^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,/^(?:(\u0022)(?!(\u0022)))/i,/^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i],conditions:{csv:{rules:[2,3,4,5,6,7,8],inclusive:!1},escaped_text:{rules:[7,8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8],inclusive:!0}}}})();function o(){this.yy={}}return t(o,`Parser`),o.prototype=a,a.Parser=o,new o})();q.parser=q;var J=q,Y=[],X=[],Z=new Map,oe=t(()=>{Y=[],X=[],Z=new Map,a()},`clear`),se=class{constructor(e,t,n=0){this.source=e,this.target=t,this.value=n}static{t(this,`SankeyLink`)}},ce=t((e,t,n)=>{Y.push(new se(e,t,n))},`addLink`),le=class{constructor(e){this.ID=e}static{t(this,`SankeyNode`)}},ue={nodesMap:Z,getConfig:t(()=>d().sankey,`getConfig`),getNodes:t(()=>X,`getNodes`),getLinks:t(()=>Y,`getLinks`),getGraph:t(()=>({nodes:X.map(e=>({id:e.ID})),links:Y.map(e=>({source:e.source.ID,target:e.target.ID,value:e.value}))}),`getGraph`),addLink:ce,findOrCreateNode:t(e=>{e=c.sanitizeText(e,d());let t=Z.get(e);return t===void 0&&(t=new le(e),Z.set(e,t),X.push(t)),t},`findOrCreateNode`),getAccTitle:f,setAccTitle:r,getAccDescription:l,setAccDescription:n,getDiagramTitle:u,setDiagramTitle:s,clear:oe},Q=class e{static{t(this,`Uid`)}static{this.count=0}static next(t){return new e(t+ ++e.count)}constructor(e){this.id=e,this.href=`#${e}`}toString(){return`url(`+this.href+`)`}},$={left:b,right:x,center:C,justify:S},de=t(e=>{let t=0,n=0;for(let r of e){let e=r.value??0;e>t&&(t=e,n=r.layer??0)}return n},`findCentralNodeLayer`),fe={draw:t(function(n,r,a,s){let{securityLevel:c,sankey:l}=d(),u=o.sankey,f;c===`sandbox`&&(f=e(`#i`+r));let m=e(c===`sandbox`?f.nodes()[0].contentDocument.body:`body`),g=c===`sandbox`?m.select(`[id="${r}"]`):e(`[id="${r}"]`),_=l?.width??u.width,v=l?.height??u.width,y=l?.useMaxWidth??u.useMaxWidth,b=l?.nodeAlignment??u.nodeAlignment,x=l?.prefix??u.prefix,S=l?.suffix??u.suffix,C=l?.showValues??u.showValues,w=l?.nodeWidth??u.nodeWidth??10,T=l?.nodePadding??u.nodePadding??12,E=l?.labelStyle??u.labelStyle??`legacy`,D=l?.nodeColors??{},O=s.db.getGraph(),k=$[b];P().nodeId(e=>e.id).nodeWidth(w).nodePadding(T+(C?15:0)).nodeAlign(k).extent([[0,0],[_,v]])(O);let A=de(O.nodes),j=p(h),M=t(e=>D[e]??j(e),`getNodeColor`);g.append(`g`).attr(`class`,`nodes`).selectAll(`.node`).data(O.nodes).join(`g`).attr(`class`,`node`).attr(`id`,e=>(e.uid=Q.next(`node-`)).id).attr(`transform`,function(e){return`translate(`+e.x0+`,`+e.y0+`)`}).attr(`x`,e=>e.x0).attr(`y`,e=>e.y0).append(`rect`).attr(`height`,e=>e.y1-e.y0).attr(`width`,e=>e.x1-e.x0).attr(`fill`,e=>M(e.id));let N=t(({id:e,value:t})=>C?`${e} +${x}${Math.round(t*100)/100}${S}`:e,`getText`),F=t(e=>E===`outlined`?(e.layer??0)I.selectAll(e?`.${e}`:`text`).data(O.nodes).join(`text`).attr(`class`,e??null).attr(`x`,e=>F(e).x).attr(`y`,e=>(e.y1+e.y0)/2).attr(`dy`,`${C?`0`:`0.35`}em`).attr(`text-anchor`,e=>F(e).anchor).text(N),`appendLabel`);E===`outlined`?(L(`sankey-label-bg`),L(`sankey-label-fg`)):L();let R=g.append(`g`).attr(`class`,`links`).attr(`fill`,`none`).attr(`stroke-opacity`,.5).selectAll(`.link`).data(O.links).join(`g`).attr(`class`,`link`).style(`mix-blend-mode`,`multiply`),z=l?.linkColor??`gradient`;if(z===`gradient`){let e=R.append(`linearGradient`).attr(`id`,e=>(e.uid=Q.next(`linearGradient-`)).id).attr(`gradientUnits`,`userSpaceOnUse`).attr(`x1`,e=>e.source.x1).attr(`x2`,e=>e.target.x0);e.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,e=>M(e.source.id)),e.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,e=>M(e.target.id))}let B;switch(z){case`gradient`:B=t(e=>e.uid,`coloring`);break;case`source`:B=t(e=>M(e.source.id),`coloring`);break;case`target`:B=t(e=>M(e.target.id),`coloring`);break;default:B=z}R.append(`path`).attr(`d`,K()).attr(`stroke`,B).attr(`stroke-width`,e=>Math.max(1,e.width)),i(void 0,g,0,y)},`draw`)},pe=t(e=>e.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g,``).replaceAll(/([\n\r])+/g,` +`).trim(),`prepareTextForParsing`),me=t(e=>`.label { + font-family: ${e.fontFamily}; + } + + .node-labels { + font-family: ${e.fontFamily}; + } + + /* Outlined label style - background stroke for better readability */ + .sankey-label-bg { + stroke: ${e.mainBkg||e.background||`#fff`}; + stroke-width: 4px; + stroke-linejoin: round; + paint-order: stroke; + } + + /* Foreground label text */ + .sankey-label-fg { + fill: ${e.textColor}; + } + + /* Node styling */ + .node rect { + shape-rendering: crispEdges; + } + + /* Link styling */ + .link { + fill: none; + stroke-opacity: 0.5; + mix-blend-mode: multiply; + } +`,`getStyles`),he=J.parse.bind(J);J.parse=e=>he(pe(e));var ge={styles:me,parser:J,db:ue,renderer:fe};export{ge as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js b/frontend/dist/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js new file mode 100644 index 0000000..acae799 --- /dev/null +++ b/frontend/dist/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js @@ -0,0 +1,169 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,F as i,G as a,H as o,O as s,U as c,a as l,b as u,c as d,i as f,q as p,r as m,s as h,v as g,w as _,x as v,y,z as b}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as x}from"./dist-Bfr8PhAA.js";import{g as S,p as C}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{_ as w,v as T}from"./index-DoQkmpth.js";import{a as E,c as D,i as O,n as k,r as A,s as j}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as M}from"./chunk-2Q5K7J3B-C1jixKkw.js";var N=x(),P=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,2],r=[1,3],i=[1,4],a=[2,4],o=[1,9],s=[1,11],c=[1,12],l=[1,14],u=[1,15],d=[1,17],f=[1,18],p=[1,19],m=[1,25],h=[1,26],g=[1,27],_=[1,28],v=[1,29],y=[1,30],b=[1,31],x=[1,32],S=[1,33],C=[1,34],w=[1,35],T=[1,36],E=[1,37],D=[1,38],O=[1,39],k=[1,40],A=[1,42],j=[1,43],M=[1,44],N=[1,45],P=[1,46],F=[1,47],I=[1,4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,48,49,50,51,53,54,56,61,62,63,64,73],ee=[1,74],te=[1,80],L=[1,81],ne=[1,82],re=[1,83],ie=[1,84],ae=[1,85],oe=[1,86],se=[1,87],ce=[1,88],le=[1,89],ue=[1,90],R=[1,91],de=[1,92],fe=[1,93],pe=[1,94],me=[1,95],z=[1,96],B=[1,97],he=[1,98],V=[1,99],H=[1,100],U=[1,101],ge=[1,102],_e=[1,103],ve=[1,104],ye=[1,105],W=[2,78],be=[4,5,17,51,53,54],G=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,51,53,54,56,61,62,63,64,73],xe=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,50,51,53,54,56,61,62,63,64,73],Se=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,49,51,53,54,56,61,62,63,64,73],Ce=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,48,51,53,54,56,61,62,63,64,73],we=[5,52],K=[70,71,72,73],q=[1,151],Te={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SPACE:4,NEWLINE:5,SD:6,document:7,line:8,statement:9,INVALID:10,box_section:11,box_line:12,participant_statement:13,create:14,box:15,restOfLine:16,end:17,signal:18,autonumber:19,NUM:20,off:21,activate:22,actor:23,deactivate:24,note_statement:25,links_statement:26,link_statement:27,properties_statement:28,details_statement:29,title:30,legacy_title:31,acc_title:32,acc_title_value:33,acc_descr:34,acc_descr_value:35,acc_descr_multiline_value:36,loop:37,rect:38,opt:39,alt:40,else_sections:41,par:42,par_sections:43,par_over:44,critical:45,option_sections:46,break:47,option:48,and:49,else:50,participant:51,AS:52,participant_actor:53,destroy:54,actor_with_config:55,note:56,placement:57,text2:58,over:59,actor_pair:60,links:61,link:62,properties:63,details:64,spaceList:65,",":66,left_of:67,right_of:68,signaltype:69,"+":70,"-":71,"()":72,ACTOR:73,config_object:74,CONFIG_START:75,CONFIG_CONTENT:76,CONFIG_END:77,SOLID_OPEN_ARROW:78,DOTTED_OPEN_ARROW:79,SOLID_ARROW:80,SOLID_ARROW_TOP:81,SOLID_ARROW_BOTTOM:82,STICK_ARROW_TOP:83,STICK_ARROW_BOTTOM:84,SOLID_ARROW_TOP_DOTTED:85,SOLID_ARROW_BOTTOM_DOTTED:86,STICK_ARROW_TOP_DOTTED:87,STICK_ARROW_BOTTOM_DOTTED:88,SOLID_ARROW_TOP_REVERSE:89,SOLID_ARROW_BOTTOM_REVERSE:90,STICK_ARROW_TOP_REVERSE:91,STICK_ARROW_BOTTOM_REVERSE:92,SOLID_ARROW_TOP_REVERSE_DOTTED:93,SOLID_ARROW_BOTTOM_REVERSE_DOTTED:94,STICK_ARROW_TOP_REVERSE_DOTTED:95,STICK_ARROW_BOTTOM_REVERSE_DOTTED:96,BIDIRECTIONAL_SOLID_ARROW:97,DOTTED_ARROW:98,BIDIRECTIONAL_DOTTED_ARROW:99,SOLID_CROSS:100,DOTTED_CROSS:101,SOLID_POINT:102,DOTTED_POINT:103,TXT:104,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACE`,5:`NEWLINE`,6:`SD`,10:`INVALID`,14:`create`,15:`box`,16:`restOfLine`,17:`end`,19:`autonumber`,20:`NUM`,21:`off`,22:`activate`,24:`deactivate`,30:`title`,31:`legacy_title`,32:`acc_title`,33:`acc_title_value`,34:`acc_descr`,35:`acc_descr_value`,36:`acc_descr_multiline_value`,37:`loop`,38:`rect`,39:`opt`,40:`alt`,42:`par`,44:`par_over`,45:`critical`,47:`break`,48:`option`,49:`and`,50:`else`,51:`participant`,52:`AS`,53:`participant_actor`,54:`destroy`,56:`note`,59:`over`,61:`links`,62:`link`,63:`properties`,64:`details`,66:`,`,67:`left_of`,68:`right_of`,70:`+`,71:`-`,72:`()`,73:`ACTOR`,75:`CONFIG_START`,76:`CONFIG_CONTENT`,77:`CONFIG_END`,78:`SOLID_OPEN_ARROW`,79:`DOTTED_OPEN_ARROW`,80:`SOLID_ARROW`,81:`SOLID_ARROW_TOP`,82:`SOLID_ARROW_BOTTOM`,83:`STICK_ARROW_TOP`,84:`STICK_ARROW_BOTTOM`,85:`SOLID_ARROW_TOP_DOTTED`,86:`SOLID_ARROW_BOTTOM_DOTTED`,87:`STICK_ARROW_TOP_DOTTED`,88:`STICK_ARROW_BOTTOM_DOTTED`,89:`SOLID_ARROW_TOP_REVERSE`,90:`SOLID_ARROW_BOTTOM_REVERSE`,91:`STICK_ARROW_TOP_REVERSE`,92:`STICK_ARROW_BOTTOM_REVERSE`,93:`SOLID_ARROW_TOP_REVERSE_DOTTED`,94:`SOLID_ARROW_BOTTOM_REVERSE_DOTTED`,95:`STICK_ARROW_TOP_REVERSE_DOTTED`,96:`STICK_ARROW_BOTTOM_REVERSE_DOTTED`,97:`BIDIRECTIONAL_SOLID_ARROW`,98:`DOTTED_ARROW`,99:`BIDIRECTIONAL_DOTTED_ARROW`,100:`SOLID_CROSS`,101:`DOTTED_CROSS`,102:`SOLID_POINT`,103:`DOTTED_POINT`,104:`TXT`},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[8,1],[11,0],[11,2],[12,2],[12,1],[12,1],[9,1],[9,2],[9,4],[9,2],[9,4],[9,3],[9,3],[9,2],[9,3],[9,3],[9,2],[9,2],[9,2],[9,2],[9,2],[9,1],[9,1],[9,2],[9,2],[9,1],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[46,1],[46,4],[43,1],[43,4],[41,1],[41,4],[13,5],[13,3],[13,5],[13,3],[13,3],[13,5],[13,3],[13,5],[13,3],[25,4],[25,4],[26,3],[27,3],[28,3],[29,3],[65,2],[65,1],[60,3],[60,1],[57,1],[57,1],[18,5],[18,5],[18,5],[18,5],[18,6],[18,4],[55,2],[74,3],[23,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[58,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:return r.apply(a[s]),a[s];case 4:case 10:this.$=[];break;case 5:case 11:a[s-1].push(a[s]),this.$=a[s-1];break;case 6:case 7:case 12:case 13:this.$=a[s];break;case 8:case 9:case 14:this.$=[];break;case 16:a[s].type=`createParticipant`,this.$=a[s];break;case 17:a[s-1].unshift({type:`boxStart`,boxData:r.parseBoxData(a[s-2])}),a[s-1].push({type:`boxEnd`,boxText:a[s-2]}),this.$=a[s-1];break;case 19:this.$={type:`sequenceIndex`,sequenceIndex:Number(a[s-2]),sequenceIndexStep:Number(a[s-1]),sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 20:this.$={type:`sequenceIndex`,sequenceIndex:Number(a[s-1]),sequenceIndexStep:1,sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 21:this.$={type:`sequenceIndex`,sequenceVisible:!1,signalType:r.LINETYPE.AUTONUMBER};break;case 22:this.$={type:`sequenceIndex`,sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 23:this.$={type:`activeStart`,signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1].actor};break;case 24:this.$={type:`activeEnd`,signalType:r.LINETYPE.ACTIVE_END,actor:a[s-1].actor};break;case 30:r.setDiagramTitle(a[s].substring(6)),this.$=a[s].substring(6);break;case 31:r.setDiagramTitle(a[s].substring(7)),this.$=a[s].substring(7);break;case 32:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 33:case 34:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 35:a[s-1].unshift({type:`loopStart`,loopText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.LOOP_START}),a[s-1].push({type:`loopEnd`,loopText:a[s-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[s-1];break;case 36:a[s-1].unshift({type:`rectStart`,color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_START}),a[s-1].push({type:`rectEnd`,color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_END}),this.$=a[s-1];break;case 37:a[s-1].unshift({type:`optStart`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_START}),a[s-1].push({type:`optEnd`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_END}),this.$=a[s-1];break;case 38:a[s-1].unshift({type:`altStart`,altText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.ALT_START}),a[s-1].push({type:`altEnd`,signalType:r.LINETYPE.ALT_END}),this.$=a[s-1];break;case 39:a[s-1].unshift({type:`parStart`,parText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.PAR_START}),a[s-1].push({type:`parEnd`,signalType:r.LINETYPE.PAR_END}),this.$=a[s-1];break;case 40:a[s-1].unshift({type:`parStart`,parText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.PAR_OVER_START}),a[s-1].push({type:`parEnd`,signalType:r.LINETYPE.PAR_END}),this.$=a[s-1];break;case 41:a[s-1].unshift({type:`criticalStart`,criticalText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.CRITICAL_START}),a[s-1].push({type:`criticalEnd`,signalType:r.LINETYPE.CRITICAL_END}),this.$=a[s-1];break;case 42:a[s-1].unshift({type:`breakStart`,breakText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.BREAK_START}),a[s-1].push({type:`breakEnd`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.BREAK_END}),this.$=a[s-1];break;case 44:this.$=a[s-3].concat([{type:`option`,optionText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.CRITICAL_OPTION},a[s]]);break;case 46:this.$=a[s-3].concat([{type:`and`,parText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.PAR_AND},a[s]]);break;case 48:this.$=a[s-3].concat([{type:`else`,altText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.ALT_ELSE},a[s]]);break;case 49:a[s-3].draw=`participant`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 50:a[s-1].draw=`participant`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 51:a[s-3].draw=`actor`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 52:case 57:a[s-1].draw=`actor`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 53:a[s-1].type=`destroyParticipant`,this.$=a[s-1];break;case 54:a[s-3].draw=`participant`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 55:a[s-1].draw=`participant`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 56:a[s-3].draw=`actor`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 58:this.$=[a[s-1],{type:`addNote`,placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 59:a[s-2]=[].concat(a[s-1],a[s-1]).slice(0,2),a[s-2][0]=a[s-2][0].actor,a[s-2][1]=a[s-2][1].actor,this.$=[a[s-1],{type:`addNote`,placement:r.PLACEMENT.OVER,actor:a[s-2].slice(0,2),text:a[s]}];break;case 60:this.$=[a[s-1],{type:`addLinks`,actor:a[s-1].actor,text:a[s]}];break;case 61:this.$=[a[s-1],{type:`addALink`,actor:a[s-1].actor,text:a[s]}];break;case 62:this.$=[a[s-1],{type:`addProperties`,actor:a[s-1].actor,text:a[s]}];break;case 63:this.$=[a[s-1],{type:`addDetails`,actor:a[s-1].actor,text:a[s]}];break;case 66:this.$=[a[s-2],a[s]];break;case 67:this.$=a[s];break;case 68:this.$=r.PLACEMENT.LEFTOF;break;case 69:this.$=r.PLACEMENT.RIGHTOF;break;case 70:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0},{type:`activeStart`,signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1].actor}];break;case 71:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s]},{type:`activeEnd`,signalType:r.LINETYPE.ACTIVE_END,actor:a[s-4].actor}];break;case 72:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0,centralConnection:r.LINETYPE.CENTRAL_CONNECTION},{type:`centralConnection`,signalType:r.LINETYPE.CENTRAL_CONNECTION,actor:a[s-1].actor}];break;case 73:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-2],msg:a[s],activate:!1,centralConnection:r.LINETYPE.CENTRAL_CONNECTION_REVERSE},{type:`centralConnectionReverse`,signalType:r.LINETYPE.CENTRAL_CONNECTION_REVERSE,actor:a[s-4].actor}];break;case 74:this.$=[a[s-5],a[s-1],{type:`addMessage`,from:a[s-5].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0,centralConnection:r.LINETYPE.CENTRAL_CONNECTION_DUAL},{type:`centralConnection`,signalType:r.LINETYPE.CENTRAL_CONNECTION,actor:a[s-1].actor},{type:`centralConnectionReverse`,signalType:r.LINETYPE.CENTRAL_CONNECTION_REVERSE,actor:a[s-5].actor}];break;case 75:this.$=[a[s-3],a[s-1],{type:`addMessage`,from:a[s-3].actor,to:a[s-1].actor,signalType:a[s-2],msg:a[s]}];break;case 76:this.$={type:`addParticipant`,actor:a[s-1],config:a[s]};break;case 77:this.$=a[s-1].trim();break;case 78:this.$={type:`addParticipant`,actor:a[s]};break;case 79:this.$=r.LINETYPE.SOLID_OPEN;break;case 80:this.$=r.LINETYPE.DOTTED_OPEN;break;case 81:this.$=r.LINETYPE.SOLID;break;case 82:this.$=r.LINETYPE.SOLID_TOP;break;case 83:this.$=r.LINETYPE.SOLID_BOTTOM;break;case 84:this.$=r.LINETYPE.STICK_TOP;break;case 85:this.$=r.LINETYPE.STICK_BOTTOM;break;case 86:this.$=r.LINETYPE.SOLID_TOP_DOTTED;break;case 87:this.$=r.LINETYPE.SOLID_BOTTOM_DOTTED;break;case 88:this.$=r.LINETYPE.STICK_TOP_DOTTED;break;case 89:this.$=r.LINETYPE.STICK_BOTTOM_DOTTED;break;case 90:this.$=r.LINETYPE.SOLID_ARROW_TOP_REVERSE;break;case 91:this.$=r.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE;break;case 92:this.$=r.LINETYPE.STICK_ARROW_TOP_REVERSE;break;case 93:this.$=r.LINETYPE.STICK_ARROW_BOTTOM_REVERSE;break;case 94:this.$=r.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED;break;case 95:this.$=r.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED;break;case 96:this.$=r.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED;break;case 97:this.$=r.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED;break;case 98:this.$=r.LINETYPE.BIDIRECTIONAL_SOLID;break;case 99:this.$=r.LINETYPE.DOTTED;break;case 100:this.$=r.LINETYPE.BIDIRECTIONAL_DOTTED;break;case 101:this.$=r.LINETYPE.SOLID_CROSS;break;case 102:this.$=r.LINETYPE.DOTTED_CROSS;break;case 103:this.$=r.LINETYPE.SOLID_POINT;break;case 104:this.$=r.LINETYPE.DOTTED_POINT;break;case 105:this.$=r.parseMessage(a[s].trim().substring(1))}},`anonymous`),table:[{3:1,4:t,5:r,6:i},{1:[3]},{3:5,4:t,5:r,6:i},{3:6,4:t,5:r,6:i},e([1,4,5,10,14,15,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,51,53,54,56,61,62,63,64,73],a,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},e(I,[2,5]),{9:48,13:13,14:l,15:u,18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},e(I,[2,7]),e(I,[2,8]),e(I,[2,9]),e(I,[2,15]),{13:49,51:D,53:O,54:k},{16:[1,50]},{5:[1,51]},{5:[1,54],20:[1,52],21:[1,53]},{23:55,73:F},{23:56,73:F},{5:[1,57]},{5:[1,58]},{5:[1,59]},{5:[1,60]},{5:[1,61]},e(I,[2,30]),e(I,[2,31]),{33:[1,62]},{35:[1,63]},e(I,[2,34]),{16:[1,64]},{16:[1,65]},{16:[1,66]},{16:[1,67]},{16:[1,68]},{16:[1,69]},{16:[1,70]},{16:[1,71]},{23:72,55:73,73:ee},{23:75,55:76,73:ee},{23:77,73:F},{69:78,72:[1,79],78:te,79:L,80:ne,81:re,82:ie,83:ae,84:oe,85:se,86:ce,87:le,88:ue,89:R,90:de,91:fe,92:pe,93:me,94:z,95:B,96:he,97:V,98:H,99:U,100:ge,101:_e,102:ve,103:ye},{57:106,59:[1,107],67:[1,108],68:[1,109]},{23:110,73:F},{23:111,73:F},{23:112,73:F},{23:113,73:F},e([5,66,72,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104],W),e(I,[2,6]),e(I,[2,16]),e(be,[2,10],{11:114}),e(I,[2,18]),{5:[1,116],20:[1,115]},{5:[1,117]},e(I,[2,22]),{5:[1,118]},{5:[1,119]},e(I,[2,25]),e(I,[2,26]),e(I,[2,27]),e(I,[2,28]),e(I,[2,29]),e(I,[2,32]),e(I,[2,33]),e(G,a,{7:120}),e(G,a,{7:121}),e(G,a,{7:122}),e(xe,a,{41:123,7:124}),e(Se,a,{43:125,7:126}),e(Se,a,{7:126,43:127}),e(Ce,a,{46:128,7:129}),e(G,a,{7:130}),{5:[1,132],52:[1,131]},{5:[1,134],52:[1,133]},e(we,W,{74:135,75:[1,136]}),{5:[1,138],52:[1,137]},{5:[1,140],52:[1,139]},{5:[1,141]},{23:145,70:[1,142],71:[1,143],72:[1,144],73:F},{69:146,78:te,79:L,80:ne,81:re,82:ie,83:ae,84:oe,85:se,86:ce,87:le,88:ue,89:R,90:de,91:fe,92:pe,93:me,94:z,95:B,96:he,97:V,98:H,99:U,100:ge,101:_e,102:ve,103:ye},e(K,[2,79]),e(K,[2,80]),e(K,[2,81]),e(K,[2,82]),e(K,[2,83]),e(K,[2,84]),e(K,[2,85]),e(K,[2,86]),e(K,[2,87]),e(K,[2,88]),e(K,[2,89]),e(K,[2,90]),e(K,[2,91]),e(K,[2,92]),e(K,[2,93]),e(K,[2,94]),e(K,[2,95]),e(K,[2,96]),e(K,[2,97]),e(K,[2,98]),e(K,[2,99]),e(K,[2,100]),e(K,[2,101]),e(K,[2,102]),e(K,[2,103]),e(K,[2,104]),{23:147,73:F},{23:149,60:148,73:F},{73:[2,68]},{73:[2,69]},{58:150,104:q},{58:152,104:q},{58:153,104:q},{58:154,104:q},{4:[1,157],5:[1,159],12:156,13:158,17:[1,155],51:D,53:O,54:k},{5:[1,160]},e(I,[2,20]),e(I,[2,21]),e(I,[2,23]),e(I,[2,24]),{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,161],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,162],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,163],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,164]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,47],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,50:[1,165],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,166]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,45],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,49:[1,167],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,168]},{17:[1,169]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,43],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,48:[1,170],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,171],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{16:[1,172]},e(I,[2,50]),{16:[1,173]},e(I,[2,55]),e(we,[2,76]),{76:[1,174]},{16:[1,175]},e(I,[2,52]),{16:[1,176]},e(I,[2,57]),e(I,[2,53]),{23:177,73:F},{23:178,73:F},{23:179,73:F},{58:180,104:q},{23:181,72:[1,182],73:F},{58:183,104:q},{58:184,104:q},{66:[1,185],104:[2,67]},{5:[2,60]},{5:[2,105]},{5:[2,61]},{5:[2,62]},{5:[2,63]},e(I,[2,17]),e(be,[2,11]),{13:186,51:D,53:O,54:k},e(be,[2,13]),e(be,[2,14]),e(I,[2,19]),e(I,[2,35]),e(I,[2,36]),e(I,[2,37]),e(I,[2,38]),{16:[1,187]},e(I,[2,39]),{16:[1,188]},e(I,[2,40]),e(I,[2,41]),{16:[1,189]},e(I,[2,42]),{5:[1,190]},{5:[1,191]},{77:[1,192]},{5:[1,193]},{5:[1,194]},{58:195,104:q},{58:196,104:q},{58:197,104:q},{5:[2,75]},{58:198,104:q},{23:199,73:F},{5:[2,58]},{5:[2,59]},{23:200,73:F},e(be,[2,12]),e(xe,a,{7:124,41:201}),e(Se,a,{7:126,43:202}),e(Ce,a,{7:129,46:203}),e(I,[2,49]),e(I,[2,54]),e(we,[2,77]),e(I,[2,51]),e(I,[2,56]),{5:[2,70]},{5:[2,71]},{5:[2,72]},{5:[2,73]},{58:204,104:q},{104:[2,66]},{17:[2,48]},{17:[2,46]},{17:[2,44]},{5:[2,74]}],defaultActions:{5:[2,1],6:[2,2],108:[2,68],109:[2,69],150:[2,60],151:[2,105],152:[2,61],153:[2,62],154:[2,63],180:[2,75],183:[2,58],184:[2,59],195:[2,70],196:[2,71],197:[2,72],198:[2,73],200:[2,66],201:[2,48],202:[2,46],203:[2,44],204:[2,74]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};Te.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:return 5;case 1:break;case 2:break;case 3:break;case 4:break;case 5:break;case 6:return 20;case 7:return this.begin(`CONFIG`),75;case 8:return 76;case 9:return this.popState(),this.begin(`ALIAS`),77;case 10:return this.popState(),this.popState(),77;case 11:return t.yytext=t.yytext.trim(),73;case 12:return t.yytext=t.yytext.trim(),this.begin(`ALIAS`),73;case 13:return t.yytext=t.yytext.trim(),this.popState(),73;case 14:return this.popState(),10;case 15:return t.yytext=t.yytext.trim(),this.popState(),10;case 16:return this.begin(`LINE`),15;case 17:return this.begin(`ID`),51;case 18:return this.begin(`ID`),53;case 19:return 14;case 20:return this.begin(`ID`),54;case 21:return this.popState(),this.popState(),this.begin(`LINE`),52;case 22:return this.popState(),this.popState(),5;case 23:return this.begin(`LINE`),37;case 24:return this.begin(`LINE`),38;case 25:return this.begin(`LINE`),39;case 26:return this.begin(`LINE`),40;case 27:return this.begin(`LINE`),50;case 28:return this.begin(`LINE`),42;case 29:return this.begin(`LINE`),44;case 30:return this.begin(`LINE`),49;case 31:return this.begin(`LINE`),45;case 32:return this.begin(`LINE`),48;case 33:return this.begin(`LINE`),47;case 34:return this.popState(),16;case 35:return 17;case 36:return 67;case 37:return 68;case 38:return 61;case 39:return 62;case 40:return 63;case 41:return 64;case 42:return 59;case 43:return 56;case 44:return this.begin(`ID`),22;case 45:return this.begin(`ID`),24;case 46:return 30;case 47:return 31;case 48:return this.begin(`acc_title`),32;case 49:return this.popState(),`acc_title_value`;case 50:return this.begin(`acc_descr`),34;case 51:return this.popState(),`acc_descr_value`;case 52:this.begin(`acc_descr_multiline`);break;case 53:this.popState();break;case 54:return`acc_descr_multiline_value`;case 55:return 6;case 56:return 19;case 57:return 21;case 58:return 66;case 59:return 5;case 60:return t.yytext=t.yytext.trim(),73;case 61:return 80;case 62:return 97;case 63:return 98;case 64:return 99;case 65:return 78;case 66:return 79;case 67:return 100;case 68:return 101;case 69:return 102;case 70:return 103;case 71:return 85;case 72:return 86;case 73:return 87;case 74:return 88;case 75:return 93;case 76:return 94;case 77:return 95;case 78:return 96;case 79:return 81;case 80:return 82;case 81:return 83;case 82:return 84;case 83:return 89;case 84:return 90;case 85:return 91;case 86:return 92;case 87:return 104;case 88:return 104;case 89:return 70;case 90:return 71;case 91:return 72;case 92:return 5;case 93:return 10}},`anonymous`),rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:([0-9]+(\.[0-9]{1,2})?|\.[0-9]{1,2})(?=[ \n]+))/i,/^(?:@\{)/i,/^(?:[^\}]+)/i,/^(?:\}(?=\s+as\s))/i,/^(?:\})/i,/^(?:[^\<->\->:\n,;@\s]+(?=@\{))/i,/^(?:[^<>:\n,;@\s]+(?=\s+as\s))/i,/^(?:[^<>:\n,;@]+(?=\s*[\n;#]|$))/i,/^(?:[^<>:\n,;@]*<[^\n]*)/i,/^(?:[^\n]+)/i,/^(?:box\b)/i,/^(?:participant\b)/i,/^(?:actor\b)/i,/^(?:create\b)/i,/^(?:destroy\b)/i,/^(?:as\b)/i,/^(?:(?:))/i,/^(?:loop\b)/i,/^(?:rect\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:par\b)/i,/^(?:par_over\b)/i,/^(?:and\b)/i,/^(?:critical\b)/i,/^(?:option\b)/i,/^(?:break\b)/i,/^(?:(?:[:]?(?:no)?wrap)?[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:links\b)/i,/^(?:link\b)/i,/^(?:properties\b)/i,/^(?:details\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:activate\b)/i,/^(?:deactivate\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:title:\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:sequenceDiagram\b)/i,/^(?:autonumber\b)/i,/^(?:off\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\/\\\+\()\+<\->\->:\n,;]+((?!(-x|--x|-\)|--\)|-\|\\|-\\|-\/|-\/\/|-\|\/|\/\|-|\\\|-|\/\/-|\\\\-|\/\|-|--\|\\|--|\(\)))[\-]*[^\+<\->\->:\n,;]+)*)/i,/^(?:->>)/i,/^(?:<<->>)/i,/^(?:-->>)/i,/^(?:<<-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?:-[\)])/i,/^(?:--[\)])/i,/^(?:--\|\\)/i,/^(?:--\|\/)/i,/^(?:--\\\\)/i,/^(?:--\/\/)/i,/^(?:\/\|--)/i,/^(?:\\\|--)/i,/^(?:\/\/--)/i,/^(?:\\\\--)/i,/^(?:-\|\\)/i,/^(?:-\|\/)/i,/^(?:-\\\\)/i,/^(?:-\/\/)/i,/^(?:\/\|-)/i,/^(?:\\\|-)/i,/^(?:\/\/-)/i,/^(?:\\\\-)/i,/^(?::(?:(?:no)?wrap)?[^#\n;]*)/i,/^(?::)/i,/^(?:\+)/i,/^(?:-)/i,/^(?:\(\))/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[53,54],inclusive:!1},acc_descr:{rules:[51],inclusive:!1},acc_title:{rules:[49],inclusive:!1},ID:{rules:[2,3,7,11,12,13,14,15],inclusive:!1},ALIAS:{rules:[2,3,21,22],inclusive:!1},LINE:{rules:[2,3,34],inclusive:!1},CONFIG:{rules:[8,9,10],inclusive:!1},CONFIG_DATA:{rules:[],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,16,17,18,19,20,23,24,25,26,27,28,29,30,31,32,33,35,36,37,38,39,40,41,42,43,44,45,46,47,48,50,52,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93],inclusive:!0}}}})();function Ee(){this.yy={}}return n(Ee,`Parser`),Ee.prototype=Te,Te.Parser=Ee,new Ee})();P.parser=P;var F=P,I={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25,AUTONUMBER:26,CRITICAL_START:27,CRITICAL_OPTION:28,CRITICAL_END:29,BREAK_START:30,BREAK_END:31,PAR_OVER_START:32,BIDIRECTIONAL_SOLID:33,BIDIRECTIONAL_DOTTED:34,SOLID_TOP:41,SOLID_BOTTOM:42,STICK_TOP:43,STICK_BOTTOM:44,SOLID_ARROW_TOP_REVERSE:45,SOLID_ARROW_BOTTOM_REVERSE:46,STICK_ARROW_TOP_REVERSE:47,STICK_ARROW_BOTTOM_REVERSE:48,SOLID_TOP_DOTTED:51,SOLID_BOTTOM_DOTTED:52,STICK_TOP_DOTTED:53,STICK_BOTTOM_DOTTED:54,SOLID_ARROW_TOP_REVERSE_DOTTED:55,SOLID_ARROW_BOTTOM_REVERSE_DOTTED:56,STICK_ARROW_TOP_REVERSE_DOTTED:57,STICK_ARROW_BOTTOM_REVERSE_DOTTED:58,CENTRAL_CONNECTION:59,CENTRAL_CONNECTION_REVERSE:60,CENTRAL_CONNECTION_DUAL:61},ee={FILLED:0,OPEN:1},te={LEFTOF:0,RIGHTOF:1,OVER:2},L={ACTOR:`actor`,BOUNDARY:`boundary`,COLLECTIONS:`collections`,CONTROL:`control`,DATABASE:`database`,ENTITY:`entity`,PARTICIPANT:`participant`,QUEUE:`queue`},ne=class{constructor(){this.state=new M(()=>({prevActor:void 0,actors:new Map,createdActors:new Map,destroyedActors:new Map,boxes:[],messages:[],notes:[],sequenceNumbersEnabled:!1,wrapEnabled:void 0,currentBox:void 0,lastCreated:void 0,lastDestroyed:void 0})),this.setAccTitle=c,this.setAccDescription=o,this.setDiagramTitle=p,this.getAccTitle=y,this.getAccDescription=g,this.getDiagramTitle=_,this.apply=this.apply.bind(this),this.parseBoxData=this.parseBoxData.bind(this),this.parseMessage=this.parseMessage.bind(this),this.clear(),this.setWrap(v().wrap),this.LINETYPE=I,this.ARROWTYPE=ee,this.PLACEMENT=te}static{n(this,`SequenceDB`)}addBox(e){this.state.records.boxes.push({name:e.text,wrap:e.wrap??this.autoWrap(),fill:e.color,actorKeys:[]}),this.state.records.currentBox=this.state.records.boxes.slice(-1)[0]}addActor(e,t,n,r,i){let a=this.state.records.currentBox,o;if(i!==void 0){let e;e=i.includes(` +`)?i+` +`:`{ +`+i+` +}`,o=T(e,{schema:w})}r=o?.type??r,o?.alias&&(!n||n.text===t)&&(n={text:o.alias,wrap:n?.wrap,type:r});let s=this.state.records.actors.get(e);if(s){if(this.state.records.currentBox&&s.box&&this.state.records.currentBox!==s.box)throw Error(`A same participant should only be defined in one Box: ${s.name} can't be in '${s.box.name}' and in '${this.state.records.currentBox.name}' at the same time.`);if(a=s.box?s.box:this.state.records.currentBox,s.box=a,s&&t===s.name&&n==null)return}if(n?.text??(n={text:t,type:r}),(r==null||n.text==null)&&(n={text:t,type:r}),this.state.records.actors.set(e,{box:a,name:t,description:n.text,wrap:n.wrap??this.autoWrap(),prevActor:this.state.records.prevActor,links:{},properties:{},actorCnt:null,rectData:null,type:r??`participant`}),this.state.records.prevActor){let t=this.state.records.actors.get(this.state.records.prevActor);t&&(t.nextActor=e)}this.state.records.currentBox&&this.state.records.currentBox.actorKeys.push(e),this.state.records.prevActor=e}activationCount(e){let t,n=0;if(!e)return 0;for(t=0;t>-`,token:`->>-`,line:`1`,loc:{first_line:1,last_line:1,first_column:1,last_column:1},expected:[`'ACTIVE_PARTICIPANT'`]},t}return this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:e,to:t,message:n?.text??``,wrap:n?.wrap??this.autoWrap(),type:r,activate:i,centralConnection:a??0}),!0}hasAtLeastOneBox(){return this.state.records.boxes.length>0}hasAtLeastOneBoxWithTitle(){return this.state.records.boxes.some(e=>e.name)}getMessages(){return this.state.records.messages}getBoxes(){return this.state.records.boxes}getActors(){return this.state.records.actors}getCreatedActors(){return this.state.records.createdActors}getDestroyedActors(){return this.state.records.destroyedActors}getActor(e){return this.state.records.actors.get(e)}getActorKeys(){return[...this.state.records.actors.keys()]}enableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!0}disableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!1}showSequenceNumbers(){return this.state.records.sequenceNumbersEnabled}setWrap(e){this.state.records.wrapEnabled=e}extractWrap(e){if(e===void 0)return{};e=e.trim();let t=/^:?wrap:/.exec(e)!==null||/^:?nowrap:/.exec(e)===null&&void 0;return{cleanedText:(t===void 0?e:e.replace(/^:?(?:no)?wrap:/,``)).trim(),wrap:t}}autoWrap(){return this.state.records.wrapEnabled===void 0?v().sequence?.wrap??!1:this.state.records.wrapEnabled}clear(){this.state.reset(),l()}parseMessage(t){let n=t.trim(),{wrap:r,cleanedText:i}=this.extractWrap(n),a={text:i,wrap:r};return e.debug(`parseMessage: ${JSON.stringify(a)}`),a}parseBoxData(e){let t=/^((?:rgba?|hsla?)\s*\(.*\)|\w*)(.*)$/.exec(e),n=t?.[1]?t[1].trim():`transparent`,r=t?.[2]?t[2].trim():void 0;if(window?.CSS)window.CSS.supports(`color`,n)||(n=`transparent`,r=e.trim());else{let t=new Option().style;t.color=n,t.color!==n&&(n=`transparent`,r=e.trim())}let{wrap:i,cleanedText:a}=this.extractWrap(r);return{text:a?b(a,v()):void 0,color:n,wrap:i}}addNote(e,t,n){let r={actor:e,placement:t,message:n.text,wrap:n.wrap??this.autoWrap()},i=[].concat(e,e);this.state.records.notes.push(r),this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:i[0],to:i[1],message:n.text,wrap:n.wrap??this.autoWrap(),type:this.LINETYPE.NOTE,placement:t})}addLinks(t,n){let r=this.getActor(t);try{let e=b(n.text,v());e=e.replace(/=/g,`=`),e=e.replace(/&/g,`&`);let t=JSON.parse(e);this.insertLinks(r,t)}catch(t){e.error(`error while parsing actor link text`,t)}}addALink(t,n){let r=this.getActor(t);try{let e={},t=b(n.text,v()),i=t.indexOf(`@`);t=t.replace(/=/g,`=`),t=t.replace(/&/g,`&`);let a=t.slice(0,i-1).trim();e[a]=t.slice(i+1).trim(),this.insertLinks(r,e)}catch(t){e.error(`error while parsing actor link text`,t)}}insertLinks(e,t){if(e.links==null)e.links=t;else for(let n in t)e.links[n]=t[n]}addProperties(t,n){let r=this.getActor(t);try{let e=b(n.text,v()),t=JSON.parse(e);this.insertProperties(r,t)}catch(t){e.error(`error while parsing actor properties text`,t)}}insertProperties(e,t){if(e.properties==null)e.properties=t;else for(let n in t)e.properties[n]=t[n]}boxEnd(){this.state.records.currentBox=void 0}addDetails(t,n){let r=this.getActor(t),i=document.getElementById(n.text);try{let e=i.innerHTML,t=JSON.parse(e);t.properties&&this.insertProperties(r,t.properties),t.links&&this.insertLinks(r,t.links)}catch(t){e.error(`error while parsing actor details text`,t)}}getActorProperty(e,t){if(e?.properties!==void 0)return e.properties[t]}apply(e){if(Array.isArray(e))e.forEach(e=>{this.apply(e)});else switch(e.type){case`sequenceIndex`:this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:void 0,to:void 0,message:{start:e.sequenceIndex,step:e.sequenceIndexStep,visible:e.sequenceVisible},wrap:!1,type:e.signalType});break;case`addParticipant`:this.addActor(e.actor,e.actor,e.description,e.draw,e.config);break;case`createParticipant`:if(this.state.records.actors.has(e.actor))throw Error(`It is not possible to have actors with the same id, even if one is destroyed before the next is created. Use 'AS' aliases to simulate the behavior`);this.state.records.lastCreated=e.actor,this.addActor(e.actor,e.actor,e.description,e.draw,e.config),this.state.records.createdActors.set(e.actor,this.state.records.messages.length);break;case`destroyParticipant`:this.state.records.lastDestroyed=e.actor,this.state.records.destroyedActors.set(e.actor,this.state.records.messages.length);break;case`activeStart`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`centralConnection`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`centralConnectionReverse`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`activeEnd`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`addNote`:this.addNote(e.actor,e.placement,e.text);break;case`addLinks`:this.addLinks(e.actor,e.text);break;case`addALink`:this.addALink(e.actor,e.text);break;case`addProperties`:this.addProperties(e.actor,e.text);break;case`addDetails`:this.addDetails(e.actor,e.text);break;case`addMessage`:if(this.state.records.lastCreated){if(e.to!==this.state.records.lastCreated)throw Error(`The created participant `+this.state.records.lastCreated.name+` does not have an associated creating message after its declaration. Please check the sequence diagram.`);this.state.records.lastCreated=void 0}else if(this.state.records.lastDestroyed){if(e.to!==this.state.records.lastDestroyed&&e.from!==this.state.records.lastDestroyed)throw Error(`The destroyed participant `+this.state.records.lastDestroyed.name+` does not have an associated destroying message after its declaration. Please check the sequence diagram.`);this.state.records.lastDestroyed=void 0}this.addSignal(e.from,e.to,e.msg,e.signalType,e.activate,e.centralConnection);break;case`boxStart`:this.addBox(e.boxData);break;case`boxEnd`:this.boxEnd();break;case`loopStart`:this.addSignal(void 0,void 0,e.loopText,e.signalType);break;case`loopEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`rectStart`:this.addSignal(void 0,void 0,e.color,e.signalType);break;case`rectEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`optStart`:this.addSignal(void 0,void 0,e.optText,e.signalType);break;case`optEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`altStart`:this.addSignal(void 0,void 0,e.altText,e.signalType);break;case`else`:this.addSignal(void 0,void 0,e.altText,e.signalType);break;case`altEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`setAccTitle`:c(e.text);break;case`parStart`:this.addSignal(void 0,void 0,e.parText,e.signalType);break;case`and`:this.addSignal(void 0,void 0,e.parText,e.signalType);break;case`parEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`criticalStart`:this.addSignal(void 0,void 0,e.criticalText,e.signalType);break;case`option`:this.addSignal(void 0,void 0,e.optionText,e.signalType);break;case`criticalEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`breakStart`:this.addSignal(void 0,void 0,e.breakText,e.signalType);break;case`breakEnd`:this.addSignal(void 0,void 0,void 0,e.signalType)}}getConfig(){return v().sequence}},re=n(e=>{let t=e.dropShadow??`none`,{look:n}=v();return`.actor { + stroke: ${e.actorBorder}; + fill: ${e.actorBkg}; + stroke-width: ${e.strokeWidth??1}; + } + + rect.actor.outer-path[data-look="neo"] { + filter: ${t}; + } + + rect.note[data-look="neo"] { + stroke:${e.noteBorderColor}; + fill:${e.noteBkgColor}; + filter: ${t}; + } + + text.actor > tspan { + fill: ${e.actorTextColor}; + stroke: none; + } + + .actor-line { + stroke: ${e.actorLineColor}; + } + + .innerArc { + stroke-width: 1.5; + stroke-dasharray: none; + } + + .messageLine0 { + stroke-width: 1.5; + stroke-dasharray: none; + stroke: ${e.signalColor}; + } + + .messageLine1 { + stroke-width: 1.5; + stroke-dasharray: 2, 2; + stroke: ${e.signalColor}; + } + + [id$="-arrowhead"] path { + fill: ${e.signalColor}; + stroke: ${e.signalColor}; + } + + .sequenceNumber { + fill: ${e.sequenceNumberColor}; + } + + [id$="-sequencenumber"] { + fill: ${e.signalColor}; + } + + [id$="-crosshead"] path { + fill: ${e.signalColor}; + stroke: ${e.signalColor}; + } + + .messageText { + fill: ${e.signalTextColor}; + stroke: none; + } + + .labelBox { + stroke: ${e.labelBoxBorderColor}; + fill: ${e.labelBoxBkgColor}; + filter: ${n===`neo`?t:`none`}; + } + + .labelText, .labelText > tspan { + fill: ${e.labelTextColor}; + stroke: none; + } + + .loopText, .loopText > tspan { + fill: ${e.loopTextColor}; + stroke: none; + } + + .sectionTitle, .sectionTitle > tspan { + fill: ${e.loopTextColor}; + stroke: none; + } + + .loopLine { + stroke-width: 2px; + stroke-dasharray: 2, 2; + stroke: ${e.labelBoxBorderColor}; + fill: ${e.labelBoxBorderColor}; + } + + .note { + //stroke: #decc93; + stroke: ${e.noteBorderColor}; + fill: ${e.noteBkgColor}; + } + + /* + * No font-weight here, deliberately. Note text renders inside tspan elements, and a weight emitted at + * tspan level outranks the inline style drawText puts on the parent text element from the + * sequence.noteFontWeight config key -- so that documented key would never reach the glyphs. + * The theme variable formerly emitted here is a different value from that config key, and + * git/styles.js reads it as its own bold-label weight under redux and neo, so it cannot be + * lowered there either. + */ + .noteText, .noteText > tspan { + fill: ${e.noteTextColor}; + stroke: none; + } + + .activation0 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .activation1 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .activation2 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .actorPopupMenu { + position: absolute; + } + + .actorPopupMenuPanel { + position: absolute; + fill: ${e.actorBkg}; + box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); + filter: drop-shadow(3px 5px 2px rgb(0 0 0 / 0.4)); +} + .actor-man circle, line { + fill: ${e.actorBkg}; + stroke-width: 2px; + } + + g rect.rect { + filter: ${t}; + stroke: ${e.nodeBorder}; + } +`},`getStyles`),ie=44,ae=6,oe=6,se=n((e,t)=>e.actorTextHeight??S.calculateTextDimensions(e.description??``,{fontFamily:t.actorFontFamily,fontSize:t.actorFontSize,fontWeight:t.actorFontWeight}).height,`actorLabelHeight`),ce=n(e=>ie+ae+e+oe,`actorStackHeight`),le=n((e,t,n)=>{let r=e+t,i=r-oe-n/2;return{lifelineStartY:r,glyphBottomY:r-oe-n-ae,labelCenterY:i}},`headerBands`),ue=n((e,t)=>{let n=e+oe,r=n+ie;return{glyphTopY:n,glyphBottomY:r,labelCenterY:r+ae+t/2,stackHeight:ce(t)}},`footerBands`),R=36,de=-5,fe=60,pe=fe-de,me=n((e,t,n,r)=>{if(t.look!==`neo`)return null;let i=se(e,t);return n?ue(r,i):le(r,e.height,i)},`neoBands`),z=`actor-top`,B=`actor-bottom`,he=`actor-box`,V=`actor-man`,H=new Set([`redux-color`,`redux-dark-color`]),U=n((e,t)=>e?.length?e[t%e.length]:void 0,`paletteColor`),ge=n(function(e,t){let n=E(e,t);return u().look===`neo`&&n.attr(`data-look`,`neo`),n},`drawRect`),_e=n(function(e,t,n,r,i){if(t.links===void 0||t.links===null||Object.keys(t.links).length===0)return{height:0,width:0};let a=t.links,o=t.actorCnt,s=t.rectData;var c=`none`;i&&(c=`block !important`);let l=e.append(`g`);l.attr(`id`,`actor`+o+`_popup`),l.attr(`class`,`actorPopupMenu`),l.attr(`display`,c);var u=``;s.class!==void 0&&(u=` `+s.class);let d=s.width>n?s.width:n,f=l.append(`rect`);if(f.attr(`class`,`actorPopupMenuPanel`+u),f.attr(`x`,s.x),f.attr(`y`,s.height),f.attr(`fill`,s.fill),f.attr(`stroke`,s.stroke),f.attr(`width`,d),f.attr(`height`,s.height),f.attr(`rx`,s.rx),f.attr(`ry`,s.ry),a!=null){var p=20;for(let e in a){var m=l.append(`a`),h=(0,N.sanitizeUrl)(a[e]);m.attr(`xlink:href`,h),m.attr(`target`,`_blank`),We(r)(e,m,s.x+10,s.height+p,d,20,{class:`actor`},r),p+=30}}return f.attr(`height`,p),{height:s.height+p,width:d}},`drawPopup`),ve=n(function(e){return`var pu = document.getElementById('`+e+`'); if (pu != null) { pu.style.display = pu.style.display == 'block' ? 'none' : 'block'; }`},`popupMenuToggle`),ye=n(async function(e,t,n=null){let r=e.append(`foreignObject`),a=await i(t.text,u()),o=r.append(`xhtml:div`).attr(`style`,`width: fit-content;`).attr(`xmlns`,`http://www.w3.org/1999/xhtml`).html(a).node().getBoundingClientRect();if(r.attr(`height`,Math.round(o.height)).attr(`width`,Math.round(o.width)),t.class===`noteText`){let n=e.node().firstChild;n.setAttribute(`height`,o.height+2*t.textMargin);let i=n.getBBox();r.attr(`x`,Math.round(i.x+i.width/2-o.width/2)).attr(`y`,Math.round(i.y+i.height/2-o.height/2))}else if(n){let{startx:e,stopx:i,starty:a}=n;if(e>i){let t=e;e=i,i=t}r.attr(`x`,Math.round(e+Math.abs(e-i)/2-o.width/2)),t.class===`loopText`?r.attr(`y`,Math.round(a)):r.attr(`y`,Math.round(a-o.height))}return[r]},`drawKatex`),W=n(function(e,t){let r=0,i=0,a=t.text.split(h.lineBreakRegex),[o,s]=C(t.fontSize),c=[],l=0,u=n(()=>t.y,`yfunc`);if(t.valign!==void 0&&t.textMargin!==void 0&&t.textMargin>0)switch(t.valign){case`top`:case`start`:u=n(()=>Math.round(t.y+t.textMargin),`yfunc`);break;case`middle`:case`center`:u=n(()=>Math.round(t.y+(r+i+t.textMargin)/2),`yfunc`);break;case`bottom`:case`end`:u=n(()=>Math.round(t.y+(r+i+2*t.textMargin)-t.textMargin),`yfunc`)}if(t.anchor!==void 0&&t.textMargin!==void 0&&t.width!==void 0)switch(t.anchor){case`left`:case`start`:t.x=Math.round(t.x+t.textMargin),t.anchor=`start`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`;break;case`middle`:case`center`:t.x=Math.round(t.x+t.width/2),t.anchor=`middle`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`;break;case`right`:case`end`:t.x=Math.round(t.x+t.width-t.textMargin),t.anchor=`end`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`}for(let[n,d]of a.entries()){t.textMargin!==void 0&&t.textMargin===0&&o!==void 0&&(l=n*o);let a=e.append(`text`);a.attr(`x`,t.x),a.attr(`y`,u()),t.anchor!==void 0&&a.attr(`text-anchor`,t.anchor).attr(`dominant-baseline`,t.dominantBaseline).attr(`alignment-baseline`,t.alignmentBaseline),t.fontFamily!==void 0&&a.style(`font-family`,t.fontFamily),s!==void 0&&a.style(`font-size`,s),t.fontWeight!==void 0&&a.style(`font-weight`,t.fontWeight),t.fill!==void 0&&a.attr(`fill`,t.fill),t.class!==void 0&&a.attr(`class`,t.class),t.dy===void 0?l!==0&&a.attr(`dy`,l):a.attr(`dy`,t.dy);let f=d||`​`;if(t.tspan){let e=a.append(`tspan`);e.attr(`x`,t.x),t.fill!==void 0&&e.attr(`fill`,t.fill),e.text(f)}else a.text(f);t.valign!==void 0&&t.textMargin!==void 0&&t.textMargin>0&&(i+=(a._groups||a)[0][0].getBBox().height,r=i),c.push(a)}return c},`drawText`),be=n(function(e,t){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}n(r,`genPoints`);let i=e.append(`polygon`);return i.attr(`points`,r(t.x,t.y,t.width,t.height,7)),i.attr(`class`,`labelBox`),t.y+=t.height/2,W(e,t),i},`drawLabel`),G=-1,xe=n((e,t,n,r)=>{e.select&&n.forEach(n=>{let i=t.get(n),a=e.select(`#actor`+i.actorCnt);!r.mirrorActors&&i.stopy?a.attr(`y2`,i.stopy+i.height/2):r.mirrorActors&&a.attr(`y2`,i.stopy)})},`fixLifeLineHeights`),Se=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower();var g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j();var v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.class=v,_.rx=3,_.ry=3,_.name=t.name,u===`neo`&&(_.rx=6,_.ry=6);let y=ge(g,_),b=o.get(t.name)??0;if(H.has(d)&&(y.style(`stroke`,U(m,b)),y.style(`fill`,U(p,b))),u===`neo`&&y.attr(`filter`,`url(#${J(a)})`),t.rectData=_,t.properties?.icon){let e=t.properties.icon.trim();e.charAt(0)===`@`?A(g,_.x+_.width-20,_.y+10,e.substr(1)):O(g,_.x+_.width-20,_.y+10,e)}i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`participant`),g.attr(`data-id`,t.name)),Y(n,r(t.description))(t.description,g,_.x,_.y,_.width,_.height,{class:`actor ${he}`},n);let x=t.height;if(y.node){let e=y.node().getBBox();n.look!==`neo`&&(t.height=e.height,x=e.height)}return x},`drawActorTypeParticipant`),Ce=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower();var g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j();var v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.class=v,_.name=t.name,n.look===`neo`&&(_.height=t.height-6);let y={..._,x:_.x+-6,y:_.y+6,class:`actor`},b=ge(g,_),x=ge(g,y);t.rectData=_,u===`neo`&&g.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;if(H.has(d)&&(b.style(`stroke`,U(m,S)),b.style(`fill`,U(p,S)),x.style(`stroke`,U(m,S)),x.style(`fill`,U(p,S))),t.properties?.icon){let e=t.properties.icon.trim();e.charAt(0)===`@`?A(g,_.x+_.width-20,_.y+10,e.substr(1)):O(g,_.x+_.width-20,_.y+10,e)}Y(n,r(t.description))(t.description,g,_.x-6,_.y+6,_.width,_.height,{class:`actor ${he}`},n);let C=t.height;if(b.node){let e=b.node().getBBox();n.look!==`neo`&&(t.height=e.height,C=e.height)}return i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`collections`),g.attr(`data-id`,t.name)),C},`drawActorTypeCollections`),we=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower(),g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j(),v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,g.attr(`class`,v),_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.name=t.name;let y=_.height/2,b=y/(2.5+_.height/50),x=g.append(`g`),S=g.append(`g`),C=`M ${_.x},${_.y+y} + a ${b},${y} 0 0 0 0,${_.height} + h ${_.width-2*b} + a ${b},${y} 0 0 0 0,-${_.height} + Z + `;x.append(`path`).attr(`d`,C),S.append(`path`).attr(`d`,`M ${_.x},${_.y+y} + a ${b},${y} 0 0 0 0,${_.height}`),x.attr(`transform`,`translate(${b}, ${-(_.height/2)})`),S.attr(`transform`,`translate(${_.width-b}, ${-_.height/2})`),t.rectData=_,u===`neo`&&x.attr(`filter`,`url(#${J(a)})`);let w=o.get(t.name)??0;if(H.has(d)&&(x.style(`stroke`,U(m,w)),x.style(`fill`,U(p,w)),S.style(`stroke`,U(m,w)),S.style(`fill`,U(p,w))),t.properties?.icon){let e=t.properties.icon.trim(),n=_.x+_.width-20,r=_.y+10;e.charAt(0)===`@`?A(g,n,r,e.substr(1)):O(g,n,r,e)}Y(n,r(t.description))(t.description,g,_.x,_.y,_.width,_.height,{class:`actor ${he}`},n);let T=t.height,E=x.select(`path:last-child`);if(E.node()){let e=E.node().getBBox();n.look!==`neo`&&(t.height=e.height,T=e.height)}return i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`queue`),g.attr(`data-id`,t.name)),T},`drawActorTypeQueue`),K=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+75,{look:d,theme:f,themeVariables:p}=n,{bkgColorArray:m,borderColorArray:h,actorBorder:g,actorBkg:_}=p,v=e.append(`g`).lower();i||(G++,v.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let y=e.append(`g`),b=V;b+=i?` ${B}`:` ${z}`,y.attr(`class`,b),y.attr(`name`,t.name);let x=j();x.x=t.x,x.y=s,x.fill=`#eaeaea`,x.width=t.width,x.height=t.height,x.class=`actor`;let S=t.x+t.width/2,C=l?l.glyphBottomY-22:s+32;y.append(`defs`).append(`marker`).attr(`id`,a+`-filled-head-control`).attr(`refX`,11).attr(`refY`,5.8).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`172.5`).attr(`stroke-width`,1.2).append(`path`).attr(`d`,`M 14.4 5.6 L 7.2 10.4 L 8.8 5.6 L 7.2 0.8 Z`),y.append(`circle`).attr(`cx`,S).attr(`cy`,C).attr(`r`,22).attr(`filter`,`${d===`neo`?`url(#${J(a)})`:``}`),y.append(`line`).attr(`marker-end`,`url(#`+a+`-filled-head-control)`).attr(`transform`,`translate(${S}, ${C-22})`);let w=o.get(t.name)??0;return H.has(f)?(y.style(`stroke`,U(h,w)),y.style(`fill`,U(m,w))):(y.style(`stroke`,g),y.style(`fill`,_)),l||(t.height=y.node().getBBox().height+2*(n?.sequence?.labelBoxHeight??0)),Y(n,r(t.description))(t.description,y,x.x,l?l.labelCenterY-x.height/2:x.y+22+(i?5:12),x.width,x.height,{class:`actor ${V}`},n),i||(y.attr(`data-et`,`participant`),y.attr(`data-type`,`control`),y.attr(`data-id`,t.name)),t.height},`drawActorTypeControl`),q=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+75,{look:d,theme:f,themeVariables:p}=n,{bkgColorArray:m,borderColorArray:h}=p,g=e.append(`g`).lower(),_=e.append(`g`),v=`actor`;v+=i?` ${B}`:` ${z}`,_.attr(`class`,v),_.attr(`name`,t.name);let y=j();y.x=t.x,y.y=s,y.fill=`#eaeaea`,y.width=t.width,y.height=t.height,y.class=`actor`;let b=t.x+t.width/2,x=l?l.glyphBottomY-22:s+(i?10:25);_.append(`circle`).attr(`cx`,b).attr(`cy`,x).attr(`r`,22).attr(`width`,t.width).attr(`height`,t.height),_.append(`line`).attr(`x1`,b-22).attr(`x2`,b+22).attr(`y1`,x+22).attr(`y2`,x+22).attr(`stroke-width`,2),d===`neo`&&_.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;return H.has(f)&&(_.style(`stroke`,U(h,S)),_.style(`fill`,U(m,S))),l||(t.height=_.node().getBBox().height+(n?.sequence?.labelBoxHeight??0)),i||(G++,g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G),Y(n,r(t.description))(t.description,_,y.x,l?l.labelCenterY-y.height/2:y.y+(i?15:30),y.width,y.height,{class:`actor ${V}`},n),l||_.attr(`transform`,`translate(0, ${i?22:6})`),i||(_.attr(`data-et`,`participant`),_.attr(`data-type`,`entity`),_.attr(`data-id`,t.name)),t.height},`drawActorTypeEntity`),Te=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+t.height+2*n.boxTextMargin,{theme:d,themeVariables:f,look:p}=n,{bkgColorArray:m,borderColorArray:h,actorBorder:g}=f,_=e.append(`g`).lower(),v=_;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&v.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),v.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),v=_.append(`g`),t.actorCnt=G,t.links!=null&&v.attr(`id`,`root-`+G),p===`neo`&&v.attr(`data-look`,`neo`));let y=j(),b=`actor`;t.properties?.class?b=t.properties.class:y.fill=`#eaeaea`,b+=i?` ${B}`:` ${z}`,y.x=t.x,y.y=s,y.width=t.width,y.height=t.height,y.class=b,y.name=t.name,y.x=t.x,y.y=s;let x=y.width/3,S=x/2,C=S/(2.5+x/50),w=l?ie:y.width/3,T=l?l.glyphBottomY-w-C:y.y,E=v.append(`g`);E.attr(`class`,b);let D=` + M ${y.x},${T+C} + a ${S},${C} 0 0 0 ${x},0 + a ${S},${C} 0 0 0 -${x},0 + l 0,${w-2*C} + a ${S},${C} 0 0 0 ${x},0 + l 0,-${w-2*C} +`;E.append(`path`).attr(`d`,D),p===`neo`&&E.attr(`filter`,`url(#${J(a)})`);let O=o.get(t.name)??0;if(H.has(d)?(E.style(`stroke`,U(h,O)),E.style(`fill`,U(m,O))):E.style(`stroke`,g),E.attr(`transform`,`translate(${x}, ${C})`),t.rectData=y,Y(n,r(t.description))(t.description,v,y.x,l?l.labelCenterY-y.height/2:y.y+35,y.width,y.height,{class:`actor ${he}`},n),!l){let e=E.select(`path:last-child`);e.node()&&(t.height=e.node().getBBox().height+(n.sequence.labelBoxHeight??0))}return i||(v.attr(`data-et`,`participant`),v.attr(`data-type`,`database`),v.attr(`data-id`,t.name)),t.height},`drawActorTypeDatabase`),Ee=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+80,d=l?l.glyphBottomY-22:s+12,f=e.append(`g`).lower(),{look:p,theme:m,themeVariables:h}=n,{bkgColorArray:g,borderColorArray:_,actorBorder:v}=h;i||(G++,f.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let y=e.append(`g`),b=V;b+=i?` ${B}`:` ${z}`,y.attr(`class`,b),y.attr(`name`,t.name);let x=j();x.x=t.x,x.y=s,x.fill=`#eaeaea`,x.width=t.width,x.height=t.height,x.class=`actor`,y.append(`line`).attr(`id`,`actor-man-torso`+G).attr(`x1`,t.x+t.width/2-55).attr(`y1`,d).attr(`x2`,t.x+t.width/2-15).attr(`y2`,d),y.append(`line`).attr(`id`,`actor-man-arms`+G).attr(`x1`,t.x+t.width/2-55).attr(`y1`,d-10).attr(`x2`,t.x+t.width/2-55).attr(`y2`,d+10),y.append(`circle`).attr(`cx`,t.x+t.width/2).attr(`cy`,d).attr(`r`,22),p===`neo`&&y.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;return H.has(m)?(y.style(`stroke`,U(_,S)),y.style(`fill`,U(g,S))):y.style(`stroke`,v),l||(t.height=y.node().getBBox().height+(n.sequence.labelBoxHeight??0)),Y(n,r(t.description))(t.description,y,x.x,l?l.labelCenterY-x.height/2:x.y+15,x.width,x.height,{class:`actor ${V}`},n),l||y.attr(`transform`,`translate(0,21)`),i||(y.attr(`data-et`,`participant`),y.attr(`data-type`,`boundary`),y.attr(`data-id`,t.name)),t.height},`drawActorTypeBoundary`),De=n(function(e,t,i,a,o){let s=a?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,i,a,s),u=l?l.lifelineStartY:s+80,{theme:d,themeVariables:f}=i,{bkgColorArray:p,borderColorArray:m,actorBorder:h}=f,g=e.append(`g`).lower();a||(G++,g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let _=e.append(`g`),v=V;v+=a?` ${B}`:` ${z}`,_.attr(`class`,v),_.attr(`name`,t.name),a||_.attr(`data-et`,`participant`).attr(`data-type`,`actor`).attr(`data-id`,t.name);let y=l?ie/pe:1,b=n(e=>l?l.glyphBottomY-(fe-e)*y:s+e,`gy`),x=n(e=>c+e*y,`gx`);_.append(`line`).attr(`id`,`actor-man-torso`+G).attr(`x1`,c).attr(`y1`,b(25)).attr(`x2`,c).attr(`y2`,b(45)),_.append(`line`).attr(`id`,`actor-man-arms`+G).attr(`x1`,x(-R/2)).attr(`y1`,b(33)).attr(`x2`,x(R/2)).attr(`y2`,b(33)),_.append(`line`).attr(`x1`,x(-R/2)).attr(`y1`,b(60)).attr(`x2`,c).attr(`y2`,b(45)),_.append(`line`).attr(`x1`,c).attr(`y1`,b(45)).attr(`x2`,x(R/2-2)).attr(`y2`,b(60));let S=_.append(`circle`);S.attr(`cx`,t.x+t.width/2),S.attr(`cy`,b(10)),S.attr(`r`,15*y),S.attr(`width`,t.width),S.attr(`height`,t.height),l||(t.height=pe);let C=j();C.x=t.x,C.y=s,C.fill=`#eaeaea`,C.width=t.width,C.height=t.height,C.class=`actor`,C.rx=3,C.ry=3;let w=o.get(t.name)??0;return H.has(d)?(_.style(`stroke`,U(m,w)),_.style(`fill`,U(p,w))):_.style(`stroke`,h),Y(i,r(t.description))(t.description,_,C.x,l?l.labelCenterY-C.height/2:s+35,C.width,C.height,{class:`actor ${V}`},i),t.height},`drawActorTypeActor`),Oe=n(async function(e,t,n,r,i,a,o){let s=o??new Map([...a.db.getActors().values()].map((e,t)=>[e.name,t]));switch(t.type){case`actor`:return await De(e,t,n,r,s);case`participant`:return await Se(e,t,n,r,i,s);case`boundary`:return await Ee(e,t,n,r,i,s);case`control`:return await K(e,t,n,r,i,s);case`entity`:return await q(e,t,n,r,i,s);case`database`:return await Te(e,t,n,r,i,s);case`collections`:return await Ce(e,t,n,r,i,s);case`queue`:return await we(e,t,n,r,i,s)}},`drawActor`),ke=n(function(e,t,n){let r=e.append(`g`);Ne(r,t),t.name&&Y(n)(t.name,r,t.x,t.y+n.boxTextMargin+(t.textMaxHeight||0)/2,t.width,0,{class:`text`},n),r.lower()},`drawBox`),Ae=n(function(e){return e.append(`g`)},`anchorElement`),je=n(function(e,t,n,r,i,a,o){let{theme:s,themeVariables:c}=r,{bkgColorArray:l,borderColorArray:u,mainBkg:d}=c,f=j(),p=t.anchored,m=t.actor;f.x=t.startx,f.y=t.starty,f.class=`activation`+i%3,f.width=t.stopx-t.startx,f.height=n-t.starty;let h=ge(p,f),g=(o??new Map([...a.db.getActors().values()].map((e,t)=>[e.name,t]))).get(m)??0;H.has(s)&&(h.style(`stroke`,U(u,g)),h.style(`fill`,U(l,g)??d))},`drawActivation`),Me=n(async function(e,t,i,a,o){let{boxMargin:s,boxTextMargin:c,labelBoxHeight:l,labelBoxWidth:u,messageFontFamily:d,messageFontSize:f,messageFontWeight:p}=a,m=e.append(`g`).attr(`data-et`,`control-structure`).attr(`data-id`,`i`+o.id),h=n(function(e,t,n,r){return m.append(`line`).attr(`x1`,e).attr(`y1`,t).attr(`x2`,n).attr(`y2`,r).attr(`class`,`loopLine`)},`drawLoopLine`);h(t.startx,t.starty,t.stopx,t.starty),h(t.stopx,t.starty,t.stopx,t.stopy),h(t.startx,t.stopy,t.stopx,t.stopy),h(t.startx,t.starty,t.startx,t.stopy),t.sections!==void 0&&t.sections.forEach(function(e){h(t.startx,e.y,t.stopx,e.y).style(`stroke-dasharray`,`3, 3`)});let g=D();g.text=i,g.x=t.startx,g.y=t.starty,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.anchor=`middle`,g.valign=`middle`,g.tspan=!1,g.width=Math.max(u??0,50),g.height=l+(a.look===`neo`?15:0)||20,g.textMargin=c,g.class=`labelText`,be(m,g),g=He(),g.text=t.title,g.x=t.startx+u/2+(t.stopx-t.startx)/2,g.y=t.starty+s+c,g.anchor=`middle`,g.valign=`middle`,g.textMargin=c,g.class=`loopText`,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.wrap=!0;let _=r(g.text)?await ye(m,g,t):W(m,g);if(t.sectionTitles!==void 0){for(let[e,n]of Object.entries(t.sectionTitles))if(n.message){g.text=n.message,g.x=t.startx+(t.stopx-t.startx)/2,g.y=t.sections[e].y+s+c,g.class=`sectionTitle`,g.anchor=`middle`,g.valign=`middle`,g.tspan=!1,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.wrap=t.wrap,r(g.text)?(t.starty=t.sections[e].y,await ye(m,g,t)):W(m,g);let i=Math.round(_.map(e=>(e._groups||e)[0][0].getBBox().height).reduce((e,t)=>e+t));t.sections[e].height+=i-(s+c)}}return t.height=Math.round(t.stopy-t.starty),m},`drawLoop`),Ne=n(function(e,t){k(e,t)},`drawBackgroundRect`),Pe=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-database`).attr(`fill-rule`,`evenodd`).attr(`clip-rule`,`evenodd`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z`)},`insertDatabaseIcon`),Fe=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-computer`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z`)},`insertComputerIcon`),Ie=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-clock`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z`)},`insertClockIcon`),Le=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowhead`).attr(`refX`,7.9).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M -1 0 L 10 5 L 0 10 z`)},`insertArrowHead`),Re=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-filled-head`).attr(`refX`,15.5).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`insertArrowFilledHead`),ze=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-sequencenumber`).attr(`refX`,15).attr(`refY`,15).attr(`markerWidth`,60).attr(`markerHeight`,40).attr(`orient`,`auto`).append(`circle`).attr(`cx`,15).attr(`cy`,15).attr(`r`,6)},`insertSequenceNumber`),Be=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-crosshead`).attr(`markerWidth`,15).attr(`markerHeight`,8).attr(`orient`,`auto`).attr(`refX`,4).attr(`refY`,4.5).append(`path`).attr(`fill`,`none`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1pt`).attr(`d`,`M 1,2 L 6,7 M 6,2 L 1,7`)},`insertArrowCrossHead`),J=n(e=>e?`${e}-drop-shadow`:`drop-shadow`,`dropShadowId`),Ve=n(function(e,t,n){let{theme:r}=t;e.append(`defs`).append(`filter`).attr(`id`,J(n)).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,`${r===`redux`||r===`redux-color`?`#000000`:`#FFFFFF`}`)},`insertDropShadow`),He=n(function(){return{x:0,y:0,fill:void 0,anchor:void 0,style:`#666`,width:void 0,height:void 0,textMargin:0,rx:0,ry:0,tspan:!0,valign:void 0}},`getTextObj`),Ue=n(function(){return{x:0,y:0,fill:`#EDF2AE`,stroke:`#666`,width:100,anchor:`start`,height:100,rx:0,ry:0}},`getNoteRect`),Y=(function(){function e(e,t,n,r,i,a,s){o(t.append(`text`).attr(`x`,n+i/2).attr(`y`,r+a/2+5).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,i,a,s,c){let{actorFontSize:l,actorFontFamily:u,actorFontWeight:d}=c,[f,p]=C(l),m=e.split(h.lineBreakRegex);for(let e=0;ee.height||0))+(this.loops.length===0?0:this.loops.map(e=>e.height||0).reduce((e,t)=>e+t))+(this.messages.length===0?0:this.messages.map(e=>e.height||0).reduce((e,t)=>e+t))+(this.notes.length===0?0:this.notes.map(e=>e.height||0).reduce((e,t)=>e+t))},`getHeight`),clear:n(function(){this.actors=[],this.boxes=[],this.loops=[],this.messages=[],this.notes=[]},`clear`),addBox:n(function(e){this.boxes.push(e)},`addBox`),addActor:n(function(e){this.actors.push(e)},`addActor`),addLoop:n(function(e){this.loops.push(e)},`addLoop`),addMessage:n(function(e){this.messages.push(e)},`addMessage`),addNote:n(function(e){this.notes.push(e)},`addNote`),lastActor:n(function(){return this.actors[this.actors.length-1]},`lastActor`),lastLoop:n(function(){return this.loops[this.loops.length-1]},`lastLoop`),lastMessage:n(function(){return this.messages[this.messages.length-1]},`lastMessage`),lastNote:n(function(){return this.notes[this.notes.length-1]},`lastNote`),actors:[],boxes:[],loops:[],messages:[],notes:[]},init:n(function(){this.sequenceItems=[],this.activations=[],this.models.clear(),this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0,tt(v())},`init`),updateVal:n(function(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])},`updateVal`),updateBounds:n(function(e,t,r,i){let a=this,o=0;function s(s){return n(function(n){o++;let c=a.sequenceItems.length-o+1;a.updateVal(n,`starty`,t-c*Z.boxMargin,Math.min),a.updateVal(n,`stopy`,i+c*Z.boxMargin,Math.max),a.updateVal(Q.data,`startx`,e-c*Z.boxMargin,Math.min),a.updateVal(Q.data,`stopx`,r+c*Z.boxMargin,Math.max),s!==`activation`&&(a.updateVal(n,`startx`,e-c*Z.boxMargin,Math.min),a.updateVal(n,`stopx`,r+c*Z.boxMargin,Math.max),a.updateVal(Q.data,`starty`,t-c*Z.boxMargin,Math.min),a.updateVal(Q.data,`stopy`,i+c*Z.boxMargin,Math.max))},`updateItemBounds`)}n(s,`updateFn`),this.sequenceItems.forEach(s()),this.activations.forEach(s(`activation`))},`updateBounds`),insert:n(function(e,t,n,r){let i=h.getMin(e,n),a=h.getMax(e,n),o=h.getMin(t,r),s=h.getMax(t,r);this.updateVal(Q.data,`startx`,i,Math.min),this.updateVal(Q.data,`starty`,o,Math.min),this.updateVal(Q.data,`stopx`,a,Math.max),this.updateVal(Q.data,`stopy`,s,Math.max),this.updateBounds(i,o,a,s)},`insert`),newActivation:n(function(e,t,n){let r=n.get(e.from),i=nt(e.from).length||0,a=r.x+r.width/2+(i-1)*Z.activationWidth/2;this.activations.push({startx:a,starty:this.verticalPos+2,stopx:a+Z.activationWidth,stopy:void 0,actor:e.from,anchored:X.anchorElement(t)})},`newActivation`),endActivation:n(function(e){let t=this.activations.map(function(e){return e.actor}).lastIndexOf(e.from);return this.activations.splice(t,1)[0]},`endActivation`),createLoop:n(function(e={message:void 0,wrap:!1,width:void 0},t){return{startx:void 0,starty:this.verticalPos,stopx:void 0,stopy:void 0,title:e.message,wrap:e.wrap,width:e.width,height:0,fill:t}},`createLoop`),newLoop:n(function(e={message:void 0,wrap:!1,width:void 0},t){this.sequenceItems.push(this.createLoop(e,t))},`newLoop`),endLoop:n(function(){return this.sequenceItems.pop()},`endLoop`),isLoopOverlap:n(function(){return this.sequenceItems.length?this.sequenceItems[this.sequenceItems.length-1].overlap:!1},`isLoopOverlap`),addSectionToLoop:n(function(e){let t=this.sequenceItems.pop();t.sections=t.sections||[],t.sectionTitles=t.sectionTitles||[],t.sections.push({y:Q.getVerticalPos(),height:0}),t.sectionTitles.push(e),this.sequenceItems.push(t)},`addSectionToLoop`),saveVerticalPos:n(function(){this.isLoopOverlap()&&(this.savedVerticalPos=this.verticalPos)},`saveVerticalPos`),resetVerticalPos:n(function(){this.isLoopOverlap()&&(this.verticalPos=this.savedVerticalPos)},`resetVerticalPos`),bumpVerticalPos:n(function(e){this.verticalPos+=e,this.data.stopy=h.getMax(this.data.stopy,this.verticalPos)},`bumpVerticalPos`),getVerticalPos:n(function(){return this.verticalPos},`getVerticalPos`),getBounds:n(function(){return{bounds:this.data,models:this.models}},`getBounds`)},Ge=n(async function(e,t,n){Q.bumpVerticalPos(Z.boxMargin),t.height=Z.boxMargin,t.starty=Q.getVerticalPos();let i=j();i.x=t.startx,i.y=t.starty,i.width=t.width||Z.width,i.class=`note`;let a=e.append(`g`);a.attr(`data-et`,`note`),a.attr(`data-id`,`i`+n);let o=X.drawRect(a,i),s=D();s.x=t.startx,s.y=t.starty,s.width=i.width,s.dy=`1em`,s.text=t.message,s.class=`noteText`,s.fontFamily=Z.noteFontFamily,s.fontSize=Z.noteFontSize,s.fontWeight=Z.noteFontWeight,s.anchor=Z.noteAlign,s.textMargin=Z.noteMargin,s.valign=`center`;let c=r(s.text)?await ye(a,s):W(a,s),l=Math.round(c.map(e=>(e._groups||e)[0][0].getBBox().height).reduce((e,t)=>e+t));o.attr(`height`,l+2*Z.noteMargin),t.height+=l+2*Z.noteMargin,Q.bumpVerticalPos(l+2*Z.noteMargin),t.stopy=t.starty+l+2*Z.noteMargin,t.stopx=t.startx+i.width,Q.insert(t.startx,t.starty,t.stopx,t.stopy),Q.models.addNote(t)},`drawNote`),Ke=n(function(e,t,r,i,a,o,s){let c=i.db.getActors(),l=c.get(t.from),u=c.get(t.to),d=r.sequenceVisible,f=l.x+l.width/2,p=u.x+u.width/2,m=f<=p,h=mt(t,i),g=e.append(`g`),_=n((e,t)=>{let n=e?16.5:-16.5;return t?-n:n},`getCircleOffset`),v=n(e=>{g.append(`circle`).attr(`cx`,e).attr(`cy`,s).attr(`r`,5).attr(`width`,10).attr(`height`,10)},`drawCircle`),{CENTRAL_CONNECTION:y,CENTRAL_CONNECTION_REVERSE:b,CENTRAL_CONNECTION_DUAL:x}=i.db.LINETYPE;if(d)switch(t.centralConnection){case y:h&&(p+=_(m,!0));break;case b:h||(f+=_(m,!1));break;case x:h?p+=_(m,!0):f+=_(m,!1)}switch(t.centralConnection){case y:v(p);break;case b:v(f);break;case x:v(f),v(p)}},`drawCentralConnection`),qe=n(e=>({fontFamily:e.messageFontFamily,fontSize:e.messageFontSize,fontWeight:e.messageFontWeight}),`messageFont`),Je=n(e=>({fontFamily:e.noteFontFamily,fontSize:e.noteFontSize,fontWeight:e.noteFontWeight}),`noteFont`),Ye=n(e=>({fontFamily:e.actorFontFamily,fontSize:e.actorFontSize,fontWeight:e.actorFontWeight}),`actorFont`);async function Xe(e,t){Q.bumpVerticalPos(10);let{startx:n,stopx:i,message:a}=t,o=h.splitBreaks(a).length,s=r(a),c=s?await f(a,v()):S.calculateTextDimensions(a,qe(Z));if(!s){let e=c.height/o;t.height+=e,Q.bumpVerticalPos(e)}let l,u=c.height-10,d=c.width;if(n===i){l=Q.getVerticalPos()+u,Z.rightAngles||(u+=Z.boxMargin,l=Q.getVerticalPos()+u),u+=30;let e=h.getMax(d/2,Z.width/2);Q.insert(n-e,Q.getVerticalPos()-10+u,i+e,Q.getVerticalPos()+30+u)}else u+=Z.boxMargin,l=Q.getVerticalPos()+u,Q.insert(n,l-10,i,l);return Q.bumpVerticalPos(u),t.height+=u,t.stopy=t.starty+t.height,Q.insert(t.fromBounds,t.starty,t.toBounds,t.stopy),l}n(Xe,`boundMessage`);var Ze=n(async function(e,t,n,i,a,o){let{startx:c,stopx:l,starty:u,message:d,type:f,sequenceIndex:p,sequenceVisible:m}=t,g=S.calculateTextDimensions(d,qe(Z)),_=D();_.x=Math.min(c,l),_.y=u+10,_.width=Math.abs(l-c),_.class=`messageText`,_.dy=`1em`,_.text=d,_.fontFamily=Z.messageFontFamily,_.fontSize=Z.messageFontSize,_.fontWeight=Z.messageFontWeight,_.anchor=Z.messageAlign,_.valign=`center`,_.textMargin=Z.wrapPadding,_.tspan=!1,r(_.text)?await ye(e,_,{startx:c,stopx:l,starty:n}):W(e,_);let v=g.width,y;if(c===l){let r=m||Z.showSequenceNumbers,o=mt(a,i),s=ht(a,i),u=c+(r&&(o||s)?10:0);y=Z.rightAngles?e.append(`path`).attr(`d`,`M ${u},${n} H ${c+h.getMax(Z.width/2,v/2)} V ${n+25} H ${c}`):e.append(`path`).attr(`d`,`M `+u+`,`+n+` C `+(u+60)+`,`+(n-10)+` `+(c+60)+`,`+(n+30)+` `+c+`,`+(n+20)),ft(a,i)&&Ke(e,a,t,i,c,l,n)}else y=e.append(`line`),y.attr(`x1`,c),y.attr(`y1`,n),y.attr(`x2`,l),y.attr(`y2`,n),ft(a,i)&&Ke(e,a,t,i,c,l,n);f===i.db.LINETYPE.DOTTED||f===i.db.LINETYPE.DOTTED_CROSS||f===i.db.LINETYPE.DOTTED_POINT||f===i.db.LINETYPE.DOTTED_OPEN||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED||f===i.db.LINETYPE.SOLID_TOP_DOTTED||f===i.db.LINETYPE.SOLID_BOTTOM_DOTTED||f===i.db.LINETYPE.STICK_TOP_DOTTED||f===i.db.LINETYPE.STICK_BOTTOM_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED?(y.style(`stroke-dasharray`,`3, 3`),y.attr(`class`,`messageLine1`)):y.attr(`class`,`messageLine0`),y.attr(`data-et`,`message`),y.attr(`data-id`,`i`+t.id),y.attr(`data-from`,t.from),y.attr(`data-to`,t.to);let b=``;if(Z.arrowMarkerAbsolute&&(b=s(!0)),y.attr(`stroke-width`,2),y.attr(`stroke`,`none`),y.style(`fill`,`none`),(f===i.db.LINETYPE.SOLID_TOP||f===i.db.LINETYPE.SOLID_TOP_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-solidTopArrowHead)`),(f===i.db.LINETYPE.SOLID_BOTTOM||f===i.db.LINETYPE.SOLID_BOTTOM_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-solidBottomArrowHead)`),(f===i.db.LINETYPE.STICK_TOP||f===i.db.LINETYPE.STICK_TOP_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-stickTopArrowHead)`),(f===i.db.LINETYPE.STICK_BOTTOM||f===i.db.LINETYPE.STICK_BOTTOM_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-stickBottomArrowHead)`),(f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-solidBottomArrowHead)`),(f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-solidTopArrowHead)`),(f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-stickBottomArrowHead)`),(f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-stickTopArrowHead)`),(f===i.db.LINETYPE.SOLID||f===i.db.LINETYPE.DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-arrowhead)`),(f===i.db.LINETYPE.BIDIRECTIONAL_SOLID||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED)&&(y.attr(`marker-start`,`url(`+b+`#`+o+`-arrowhead)`),y.attr(`marker-end`,`url(`+b+`#`+o+`-arrowhead)`)),(f===i.db.LINETYPE.SOLID_POINT||f===i.db.LINETYPE.DOTTED_POINT)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-filled-head)`),(f===i.db.LINETYPE.SOLID_CROSS||f===i.db.LINETYPE.DOTTED_CROSS)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-crosshead)`),m||Z.showSequenceNumbers){let r=f===i.db.LINETYPE.BIDIRECTIONAL_SOLID||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED,s=f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,u=ft(a,i),d=c,m=l;r?(cc?m=l-12:(m=l-6,d+=a?.centralConnection===i.db.LINETYPE.CENTRAL_CONNECTION_DUAL||a?.centralConnection===i.db.LINETYPE.CENTRAL_CONNECTION_REVERSE?-7.5:0),m+=u?15:0,y.attr(`x2`,m),y.attr(`x1`,d)):y.attr(`x1`,c+6);let h=0,g=c===l,_=c<=l;h=g?t.fromBounds+1:s?_?t.toBounds-1:t.fromBounds+1:_?t.fromBounds+1:t.toBounds-1;let v=`12px`,x=p.toString().length;x>5?v=`7px`:x>3&&(v=`9px`),e.append(`line`).attr(`x1`,h).attr(`y1`,n).attr(`x2`,h).attr(`y2`,n).attr(`stroke-width`,0).attr(`marker-start`,`url(`+b+`#`+o+`-sequencenumber)`),e.append(`text`).attr(`x`,h).attr(`y`,n+4).attr(`font-family`,`sans-serif`).attr(`font-size`,v).attr(`text-anchor`,`middle`).attr(`class`,`sequenceNumber`).text(p)}},`drawMessage`),Qe=n(function(e,t,n,r,i,a,o){let s=0,c=0,l,u=0;for(let e of r){let r=t.get(e),a=r.box;l&&l!=a&&(o||Q.models.addBox(l),c+=Z.boxMargin+l.margin),a&&a!=l&&(o||(a.x=s+c,a.y=i),c+=a.margin),r.width=h.getMax(r.width||Z.width,Z.width),r.height=h.getMax(r.height||Z.height,Z.height),r.margin=r.margin||Z.actorMargin,u=h.getMax(u,r.height),n.get(r.name)&&(c+=r.width/2),r.x=s+c,r.starty=Q.getVerticalPos(),Q.insert(r.x,i,r.x+r.width,r.height),s+=r.width+c,r.box&&(r.box.width=s+a.margin-r.box.x),c=r.margin,l=r.box,Q.models.addActor(r)}l&&!o&&Q.models.addBox(l),Q.bumpVerticalPos(u)},`addActorRenderingData`),$e=n(async function(e,t,n,r,i,a,o){if(r){let r=0;Q.bumpVerticalPos(Z.boxMargin*2);for(let s of n){let n=t.get(s);n.stopy||=Q.getVerticalPos();let c=await X.drawActor(e,n,Z,!0,i,a,o);r=h.getMax(r,c)}Q.bumpVerticalPos(r+Z.boxMargin)}else for(let r of n){let n=t.get(r);await X.drawActor(e,n,Z,!1,i,a,o)}},`drawActors`),et=n(function(e,t,n,r){let i=0,a=0;for(let o of n){let n=t.get(o),s=st(n),c=X.drawPopup(e,n,s,Z,Z.forceMenus,r);c.height>i&&(i=c.height),c.width+n.x>a&&(a=c.width+n.x)}return{maxHeight:i,maxWidth:a}},`drawActorsPopup`),tt=n(function(e){m(Z,e),e.fontFamily&&(Z.actorFontFamily=Z.noteFontFamily=Z.messageFontFamily=e.fontFamily),e.fontSize&&(Z.actorFontSize=Z.noteFontSize=Z.messageFontSize=e.fontSize),e.fontWeight&&(Z.actorFontWeight=Z.noteFontWeight=Z.messageFontWeight=e.fontWeight)},`setConf`),nt=n(function(e){return Q.activations.filter(function(t){return t.actor===e})},`actorActivations`),rt=n(function(e,t){let n=t.get(e),r=nt(e);return[r.reduce(function(e,t){return h.getMin(e,t.startx)},n.x+n.width/2-1),r.reduce(function(e,t){return h.getMax(e,t.stopx)},n.x+n.width/2+1)]},`activationBounds`);function $(t,n,r,i,a){Q.bumpVerticalPos(r);let o=i;if(n.id&&n.message&&t[n.id]){let r=t[n.id].width,a=qe(Z);n.message=S.wrapLabel(`[${n.message}]`,r-2*Z.wrapPadding,a),n.width=r,n.wrap=!0;let s=S.calculateTextDimensions(n.message,a),c=h.getMax(s.height,Z.labelBoxHeight);o=i+c,e.debug(`${c} - ${n.message}`)}a(n),Q.bumpVerticalPos(o)}n($,`adjustLoopHeightForWrap`);function it(e,t,r,i,a,o,s){function c(n,r){n.x{e.add(t.from),e.add(t.to)}),x=x.filter(t=>e.has(t))}let D=new Map(x.map((e,t)=>[g.get(e)?.name??e,t]));Qe(h,g,_,x,0,S,!1);let O=await _t(S,g,E,o);X.insertArrowHead(h,i),X.insertArrowCrossHead(h,i),X.insertArrowFilledHead(h,i),X.insertSequenceNumber(h,i),X.insertSolidTopArrowHead(h,i),X.insertSolidBottomArrowHead(h,i),X.insertStickTopArrowHead(h,i),X.insertStickBottomArrowHead(h,i),l===`neo`&&X.insertDropShadow(h,Z,i);function k(e,t){let n=Q.endActivation(e);n.starty+18>t&&(n.starty=t-6,t+=12),X.drawActivation(h,n,t,Z,nt(e.from).length,o,D),Q.insert(n.startx,t-10,n.stopx,t)}n(k,`activeEnd`);let A=1,j=1,M=[],N=[],P=0;for(let t of S){let n,r,i;switch(t.type){case o.db.LINETYPE.NOTE:Q.resetVerticalPos(),r=t.noteModel,await Ge(h,r,t.id);break;case o.db.LINETYPE.ACTIVE_START:Q.newActivation(t,h,g);break;case o.db.LINETYPE.CENTRAL_CONNECTION:Q.newActivation(t,h,g);break;case o.db.LINETYPE.CENTRAL_CONNECTION_REVERSE:Q.newActivation(t,h,g);break;case o.db.LINETYPE.ACTIVE_END:k(t,Q.getVerticalPos());break;case o.db.LINETYPE.LOOP_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.LOOP_END:n=Q.endLoop(),await X.drawLoop(h,n,`loop`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.RECT_START:$(O,t,Z.boxMargin,Z.boxMargin,e=>{let t=e.message;t||=u?.rectBkgColor||u?.actorBkg||`rgba(128, 128, 128, 0.5)`,Q.newLoop(void 0,t)});break;case o.db.LINETYPE.RECT_END:n=Q.endLoop(),N.push(n),Q.models.addLoop(n),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos());break;case o.db.LINETYPE.OPT_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.OPT_END:n=Q.endLoop(),await X.drawLoop(h,n,`opt`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.ALT_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.ALT_ELSE:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.ALT_END:n=Q.endLoop(),await X.drawLoop(h,n,`alt`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.PAR_START:case o.db.LINETYPE.PAR_OVER_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e)),Q.saveVerticalPos();break;case o.db.LINETYPE.PAR_AND:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.PAR_END:n=Q.endLoop(),await X.drawLoop(h,n,`par`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.AUTONUMBER:A=t.message.start||A,j=t.message.step||j,t.message.visible?o.db.enableSequenceNumbers():o.db.disableSequenceNumbers();break;case o.db.LINETYPE.CRITICAL_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.CRITICAL_OPTION:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.CRITICAL_END:n=Q.endLoop(),await X.drawLoop(h,n,`critical`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.BREAK_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.BREAK_END:n=Q.endLoop(),await X.drawLoop(h,n,`break`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;default:try{i=t.msgModel,i.starty=Q.getVerticalPos(),i.sequenceIndex=A,i.sequenceVisible=o.db.showSequenceNumbers(),i.id=t.id,i.from=t.from,i.to=t.to;let e=await Xe(h,i);it(t,i,e,P,g,_,y),M.push({messageModel:i,lineStartY:e,msg:t}),Q.models.addMessage(i)}catch(t){e.error(`error while drawing message`,t)}}[o.db.LINETYPE.SOLID_OPEN,o.db.LINETYPE.DOTTED_OPEN,o.db.LINETYPE.SOLID,o.db.LINETYPE.SOLID_TOP,o.db.LINETYPE.SOLID_BOTTOM,o.db.LINETYPE.STICK_TOP,o.db.LINETYPE.STICK_BOTTOM,o.db.LINETYPE.SOLID_TOP_DOTTED,o.db.LINETYPE.SOLID_BOTTOM_DOTTED,o.db.LINETYPE.STICK_TOP_DOTTED,o.db.LINETYPE.STICK_BOTTOM_DOTTED,o.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,o.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE,o.db.LINETYPE.STICK_ARROW_TOP_REVERSE,o.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE,o.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,o.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,o.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED,o.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,o.db.LINETYPE.DOTTED,o.db.LINETYPE.SOLID_CROSS,o.db.LINETYPE.DOTTED_CROSS,o.db.LINETYPE.SOLID_POINT,o.db.LINETYPE.DOTTED_POINT,o.db.LINETYPE.BIDIRECTIONAL_SOLID,o.db.LINETYPE.BIDIRECTIONAL_DOTTED].includes(t.type)&&(A=Math.round((A+j)*100)/100),P++}e.debug(`createdActors`,_),e.debug(`destroyedActors`,y),await $e(h,g,x,!1,i,o,D);for(let e of M)await Ze(h,e.messageModel,e.lineStartY,o,e.msg,i);Z.mirrorActors&&await $e(h,g,x,!0,i,o,D),N.forEach(e=>X.drawBackgroundRect(h,e)),xe(h,g,x,Z);for(let e of Q.models.boxes){e.height=Q.getVerticalPos()-e.y,Q.insert(e.x,e.y,e.x+e.width,e.height);let t=Z.boxMargin*2;e.startx=e.x-t,e.starty=e.y-t*.25,e.stopx=e.startx+e.width+2*t,e.stopy=e.starty+e.height+t*.75,e.stroke=`rgb(0,0,0, 0.5)`,X.drawBox(h,e,Z)}w&&Q.bumpVerticalPos(Z.boxMargin);let F=et(h,g,x,m),{bounds:I}=Q.getBounds();I.startx===void 0&&(I.startx=0),I.starty===void 0&&(I.starty=0),I.stopx===void 0&&(I.stopx=0),I.stopy===void 0&&(I.stopy=0);let ee=I.stopy-I.starty;ee{let n=qe(Z),r=t.actorKeys.reduce((t,n)=>t+=e.get(n).width+(e.get(n).margin||0),0),i=Z.boxMargin*8;r+=i,r-=2*Z.boxTextMargin,t.wrap&&(t.name=S.wrapLabel(t.name,r-2*Z.wrapPadding,n));let o=S.calculateTextDimensions(t.name,n);a=h.getMax(o.height,a);let s=h.getMax(r,o.width+2*Z.wrapPadding);if(t.margin=Z.boxTextMargin,re.textMaxHeight=a),h.getMax(i,Z.height)}n(ct,`calculateActorMargins`);var lt=n(async function(t,n,i){let a=n.get(t.from),o=n.get(t.to),s=a.x,c=o.x,l=t.wrap&&t.message,u=r(t.message)?await f(t.message,v()):S.calculateTextDimensions(l?S.wrapLabel(t.message,Z.width,Je(Z)):t.message,Je(Z)),d={width:l?Z.width:h.getMax(Z.width,u.width+2*Z.noteMargin),height:0,startx:a.x,stopx:0,starty:0,stopy:0,message:t.message};return t.placement===i.db.PLACEMENT.RIGHTOF?(d.width=l?h.getMax(Z.width,u.width):h.getMax(a.width/2+o.width/2,u.width+2*Z.noteMargin),d.startx=s+(a.width+Z.actorMargin)/2):t.placement===i.db.PLACEMENT.LEFTOF?(d.width=l?h.getMax(Z.width,u.width+2*Z.noteMargin):h.getMax(a.width/2+o.width/2,u.width+2*Z.noteMargin),d.startx=s-d.width+(a.width-Z.actorMargin)/2):t.to===t.from?(u=S.calculateTextDimensions(l?S.wrapLabel(t.message,h.getMax(Z.width,a.width),Je(Z)):t.message,Je(Z)),d.width=l?h.getMax(Z.width,a.width):h.getMax(a.width,Z.width,u.width+2*Z.noteMargin),d.startx=s+(a.width-d.width)/2):(d.width=Math.abs(s+a.width/2-(c+o.width/2))+Z.actorMargin,d.startx=s2,p=n(e=>l?-e:e,`adjustValue`);e.from===e.to?d=u:(e.activate&&!f&&(d+=p(Z.activationWidth/2-1)),[r.db.LINETYPE.SOLID_OPEN,r.db.LINETYPE.DOTTED_OPEN,r.db.LINETYPE.STICK_TOP,r.db.LINETYPE.STICK_BOTTOM,r.db.LINETYPE.STICK_TOP_DOTTED,r.db.LINETYPE.STICK_BOTTOM_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.STICK_ARROW_TOP_REVERSE,r.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE,r.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE].includes(e.type)||(d+=p(3)),[r.db.LINETYPE.BIDIRECTIONAL_SOLID,r.db.LINETYPE.BIDIRECTIONAL_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE].includes(e.type)&&(u-=p(3)));let m=[a,o,s,c],g=Math.abs(u-d);e.wrap&&e.message&&(e.message=S.wrapLabel(e.message,h.getMax(g+2*Z.wrapPadding,Z.width),qe(Z)));let _=S.calculateTextDimensions(e.message,qe(Z));return{width:h.getMax(e.wrap?0:_.width+2*Z.wrapPadding,g+2*Z.wrapPadding,Z.width),height:0,startx:u,stopx:d,starty:0,stopy:0,message:e.message,type:e.type,wrap:e.wrap,fromBounds:Math.min.apply(null,m),toBounds:Math.max.apply(null,m)}},`buildMessageModel`),_t=n(async function(t,n,r,i){let a={},o=[],s,c,l;for(let e of t){switch(e.type){case i.db.LINETYPE.LOOP_START:case i.db.LINETYPE.ALT_START:case i.db.LINETYPE.OPT_START:case i.db.LINETYPE.PAR_START:case i.db.LINETYPE.PAR_OVER_START:case i.db.LINETYPE.CRITICAL_START:case i.db.LINETYPE.BREAK_START:o.push({id:e.id,msg:e.message,from:2**53-1,to:-(2**53-1),width:0});break;case i.db.LINETYPE.ALT_ELSE:case i.db.LINETYPE.PAR_AND:case i.db.LINETYPE.CRITICAL_OPTION:e.message&&(s=o.pop(),a[s.id]=s,a[e.id]=s,o.push(s));break;case i.db.LINETYPE.LOOP_END:case i.db.LINETYPE.ALT_END:case i.db.LINETYPE.OPT_END:case i.db.LINETYPE.PAR_END:case i.db.LINETYPE.CRITICAL_END:case i.db.LINETYPE.BREAK_END:s=o.pop(),a[s.id]=s;break;case i.db.LINETYPE.ACTIVE_START:{let t=n.get(e.from?e.from:e.to.actor),r=nt(e.from?e.from:e.to.actor).length,i=t.x+t.width/2+(r-1)*Z.activationWidth/2,a={startx:i,stopx:i+Z.activationWidth,actor:e.from,enabled:!0};Q.activations.push(a)}break;case i.db.LINETYPE.ACTIVE_END:{let t=Q.activations.map(e=>e.actor).lastIndexOf(e.from);Q.activations.splice(t,1).splice(0,1)}}e.placement===void 0?(l=gt(e,n,i),e.msgModel=l,l.startx&&l.stopx&&o.length>0&&o.forEach(t=>{if(s=t,l.startx===l.stopx){let t=n.get(e.from),r=n.get(e.to);s.from=h.getMin(t.x-l.width/2,t.x-t.width/2,s.from),s.to=h.getMax(r.x+l.width/2,r.x+t.width/2,s.to),s.width=h.getMax(s.width,Math.abs(s.to-s.from))-Z.labelBoxWidth}else s.from=h.getMin(l.startx,s.from),s.to=h.getMax(l.stopx,s.to),s.width=h.getMax(s.width,l.width)-Z.labelBoxWidth})):(c=await lt(e,n,i),e.noteModel=c,o.forEach(e=>{s=e,s.from=h.getMin(s.from,c.startx),s.to=h.getMax(s.to,c.startx+c.width),s.width=h.getMax(s.width,Math.abs(s.from-s.to))-Z.labelBoxWidth}))}return Q.activations=[],e.debug(`Loop type widths:`,a),a},`calculateLoopBounds`),vt={parser:F,get db(){return new ne},renderer:{bounds:Q,drawActors:$e,drawActorsPopup:et,setConf:tt,draw:at},styles:re,init:n(e=>{e.sequence||={},e.wrap&&(e.sequence.wrap=e.wrap,a({sequence:{wrap:e.wrap}}))},`init`)};export{vt as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/sizeCapture-INFHLROL-B0uUizjq.js b/frontend/dist/assets/sizeCapture-INFHLROL-B0uUizjq.js new file mode 100644 index 0000000..ea2efbd --- /dev/null +++ b/frontend/dist/assets/sizeCapture-INFHLROL-B0uUizjq.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=1;function n(){if(!(typeof globalThis>`u`))return globalThis}e(n,`getCaptureGlobal`);function r(){return!!n()?.mermaidCaptureSizes}e(r,`shouldCaptureSizes`);function i(){return typeof location>`u`?`browser-dev`:`${location.pathname}${location.search}`}e(i,`capturedFromLocation`);function a(e,t){let r=n();if(!r)return;let i=t.node(),a=((i&&`ownerSVGElement`in i?i.ownerSVGElement:null)??i)?.id??`(unknown)`;r.mermaidCapturedSizes??=[];let o={svgId:a,sizes:e};r.mermaidCapturedSizes.push(o),r.mermaidLastCapturedSizes=o}e(a,`emitCapturedSizes`);function o(e,n){let r=[];for(let e of n.nodes)e.isGroup||r.push({id:e.id,width:e.width??0,height:e.height??0});r.length!==0&&a({metadata:{captureVersion:t,capturedAt:new Date().toISOString(),capturedFrom:i()},nodes:r},e)}e(o,`captureNodeSizes`);export{o as captureNodeSizes}; \ No newline at end of file diff --git a/frontend/dist/assets/src-D_iIdUkB.js b/frontend/dist/assets/src-D_iIdUkB.js new file mode 100644 index 0000000..9535405 --- /dev/null +++ b/frontend/dist/assets/src-D_iIdUkB.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=Object.create,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.getPrototypeOf,o=Object.prototype.hasOwnProperty,s=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),c=(e,t,a,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=i(t),l=0,u=c.length,d;lt[e]).bind(null,d),enumerable:!(s=r(t,d))||s.enumerable});return e},l=(e,r,i)=>(i=e==null?{}:t(a(e)),c(r||!e||!e.__esModule||!o.call(e,`default`)?n(i,`default`,{value:e,enumerable:!0}):i,e)),u=(e=>typeof require<`u`?require:typeof Proxy<`u`?new Proxy(e,{get:(e,t)=>(typeof require<`u`?require:e)[t]}):e)(function(e){if(typeof require<`u`)return require.apply(this,arguments);throw Error('Calling `require` for "'+e+"\" in an environment that doesn't expose the `require` function. See https://rolldown.rs/in-depth/bundling-cjs#require-external-modules for more details.")}),d=s(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs=r()})(e,(function(){var e=1e3,t=6e4,n=36e5,r=`millisecond`,i=`second`,a=`minute`,o=`hour`,s=`day`,c=`week`,l=`month`,u=`quarter`,d=`year`,f=`date`,p=`Invalid Date`,m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}},_=function(e,t,n){var r=String(e);return!r||r.length>=t?e:``+Array(t+1-r.length).join(n)+e},v={s:_,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?`+`:`-`)+_(r,2,`0`)+`:`+_(i,2,`0`)},m:function e(t,n){if(t.date()1)return e(o[0])}else{var s=t.name;b[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},C=function(e,t){if(x(e))return e.clone();var n=typeof t==`object`?t:{};return n.date=e,n.args=arguments,new T(n)},w=v;w.l=S,w.i=x,w.w=function(e,t){return C(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var T=function(){function g(e){this.$L=S(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[ee]=!0}var _=g.prototype;return _.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(t===null)return new Date(NaN);if(w.u(t))return new Date;if(t instanceof Date)return new Date(t);if(typeof t==`string`&&!/Z$/i.test(t)){var r=t.match(m);if(r){var i=r[2]-1||0,a=(r[7]||`0`).substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(t)}(e),this.init()},_.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},_.$utils=function(){return w},_.isValid=function(){return this.$d.toString()!==p},_.isSame=function(e,t){var n=C(e);return this.startOf(t)<=n&&n<=this.endOf(t)},_.isAfter=function(e,t){return C(e){},`trace`),debug:e((...e)=>{},`debug`),info:e((...e)=>{},`info`),warn:e((...e)=>{},`warn`),error:e((...e)=>{},`error`),fatal:e((...e)=>{},`fatal`)},h=e(function(e=`fatal`){let t=p.fatal;typeof e==`string`?e.toLowerCase()in p&&(t=p[e]):typeof e==`number`&&(t=e),m.trace=()=>{},m.debug=()=>{},m.info=()=>{},m.warn=()=>{},m.error=()=>{},m.fatal=()=>{},t<=p.fatal&&(m.fatal=console.error?console.error.bind(console,g(`FATAL`),`color: orange`):console.log.bind(console,`\x1B[35m`,g(`FATAL`))),t<=p.error&&(m.error=console.error?console.error.bind(console,g(`ERROR`),`color: orange`):console.log.bind(console,`\x1B[31m`,g(`ERROR`))),t<=p.warn&&(m.warn=console.warn?console.warn.bind(console,g(`WARN`),`color: orange`):console.log.bind(console,`\x1B[33m`,g(`WARN`))),t<=p.info&&(m.info=console.info?console.info.bind(console,g(`INFO`),`color: lightblue`):console.log.bind(console,`\x1B[34m`,g(`INFO`))),t<=p.debug&&(m.debug=console.debug?console.debug.bind(console,g(`DEBUG`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,g(`DEBUG`))),t<=p.trace&&(m.trace=console.debug?console.debug.bind(console,g(`TRACE`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,g(`TRACE`)))},`setLogLevel`),g=e(e=>`%c${(0,f.default)().format(`ss.SSS`)} : ${e} : `,`format`),_={value:()=>{}};function v(){for(var e=0,t=arguments.length,n={},r;e=0&&(n=e.slice(r+1),e=e.slice(0,r)),e&&!t.hasOwnProperty(e))throw Error(`unknown type: `+e);return{type:e,name:n}})}y.prototype=v.prototype={constructor:y,on:function(e,t){var n=this._,r=b(e+``,n),i,a=-1,o=r.length;if(arguments.length<2){for(;++a0)for(var n=Array(i),r=0,i,a;r=0&&(t=e.slice(0,n))!==`xmlns`&&(e=e.slice(n+1)),S.hasOwnProperty(t)?{space:S[t],local:e}:e}function w(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===`http://www.w3.org/1999/xhtml`&&t.documentElement.namespaceURI===`http://www.w3.org/1999/xhtml`?t.createElement(e):t.createElementNS(n,e)}}function T(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function te(e){var t=C(e);return(t.local?T:w)(t)}function ne(){}function re(e){return e==null?ne:function(){return this.querySelector(e)}}function ie(e){typeof e!=`function`&&(e=re(e));for(var t=this._groups,n=t.length,r=Array(n),i=0;i=v&&(v=_+1);!(b=g[v])&&++v=0;)(o=r[i])&&(a&&o.compareDocumentPosition(a)^4&&a.parentNode.insertBefore(o,a),a=o);return this}function Ne(e){e||=Pe;function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}for(var n=this._groups,r=n.length,i=Array(r),a=0;at?1:e>=t?0:NaN}function Fe(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function Ie(){return Array.from(this)}function Le(){for(var e=this._groups,t=0,n=e.length;t1?this.each((t==null?Ye:typeof t==`function`?Ze:Xe)(e,t,n??``)):D(this.node(),e)}function D(e,t){return e.style.getPropertyValue(t)||Je(e).getComputedStyle(e,null).getPropertyValue(t)}function $e(e){return function(){delete this[e]}}function et(e,t){return function(){this[e]=t}}function tt(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function nt(e,t){return arguments.length>1?this.each((t==null?$e:typeof t==`function`?tt:et)(e,t)):this.node()[e]}function rt(e){return e.trim().split(/^|\s+/)}function it(e){return e.classList||new at(e)}function at(e){this._node=e,this._names=rt(e.getAttribute(`class`)||``)}at.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute(`class`,this._names.join(` `)))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute(`class`,this._names.join(` `)))},contains:function(e){return this._names.indexOf(e)>=0}};function ot(e,t){for(var n=it(e),r=-1,i=t.length;++r=0&&(t=e.slice(n+1),e=e.slice(0,n)),{type:e,name:t}})}function Ft(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,a;n>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?I(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?I(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=Xt.exec(e))?new L(t[1],t[2],t[3],1):(t=Zt.exec(e))?new L(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Qt.exec(e))?I(t[1],t[2],t[3],t[4]):(t=$t.exec(e))?I(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=en.exec(e))?mn(t[1],t[2]/100,t[3]/100,1):(t=tn.exec(e))?mn(t[1],t[2]/100,t[3]/100,t[4]):nn.hasOwnProperty(e)?cn(nn[e]):e===`transparent`?new L(NaN,NaN,NaN,0):null}function cn(e){return new L(e>>16&255,e>>8&255,e&255,1)}function I(e,t,n,r){return r<=0&&(e=t=n=NaN),new L(e,t,n,r)}function ln(e){return e instanceof A||(e=F(e)),e?(e=e.rgb(),new L(e.r,e.g,e.b,e.opacity)):new L}function un(e,t,n,r){return arguments.length===1?ln(e):new L(e,t,n,r??1)}function L(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Kt(L,un,qt(A,{brighter(e){return e=e==null?Jt:Jt**+e,new L(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?j:j**+e,new L(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new L(z(this.r),z(this.g),z(this.b),R(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:dn,formatHex:dn,formatHex8:fn,formatRgb:pn,toString:pn}));function dn(){return`#${B(this.r)}${B(this.g)}${B(this.b)}`}function fn(){return`#${B(this.r)}${B(this.g)}${B(this.b)}${B((isNaN(this.opacity)?1:this.opacity)*255)}`}function pn(){let e=R(this.opacity);return`${e===1?`rgb(`:`rgba(`}${z(this.r)}, ${z(this.g)}, ${z(this.b)}${e===1?`)`:`, ${e})`}`}function R(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function z(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function B(e){return e=z(e),(e<16?`0`:``)+e.toString(16)}function mn(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new V(e,t,n,r)}function hn(e){if(e instanceof V)return new V(e.h,e.s,e.l,e.opacity);if(e instanceof A||(e=F(e)),!e)return new V;if(e instanceof V)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=NaN,s=a-i,c=(a+i)/2;return s?(o=t===a?(n-r)/s+(n0&&c<1?0:o,new V(o,s,c,e.opacity)}function gn(e,t,n,r){return arguments.length===1?hn(e):new V(e,t,n,r??1)}function V(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Kt(V,gn,qt(A,{brighter(e){return e=e==null?Jt:Jt**+e,new V(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?j:j**+e,new V(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new L(vn(e>=240?e-240:e+120,i,r),vn(e,i,r),vn(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new V(_n(this.h),H(this.s),H(this.l),R(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let e=R(this.opacity);return`${e===1?`hsl(`:`hsla(`}${_n(this.h)}, ${H(this.s)*100}%, ${H(this.l)*100}%${e===1?`)`:`, ${e})`}`}}));function _n(e){return e=(e||0)%360,e<0?e+360:e}function H(e){return Math.max(0,Math.min(1,e||0))}function vn(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}var yn=e=>()=>e;function bn(e,t){return function(n){return e+n*t}}function xn(e,t,n){return e**=+n,t=t**+n-e,n=1/n,function(r){return(e+r*t)**+n}}function Sn(e,t){var n=t-e;return n?bn(e,n>180||n<-180?n-360*Math.round(n/360):n):yn(isNaN(e)?t:e)}function Cn(e){return(e=+e)==1?wn:function(t,n){return n-t?xn(t,n,e):yn(isNaN(t)?n:t)}}function wn(e,t){var n=t-e;return n?bn(e,n):yn(isNaN(e)?t:e)}var Tn=(function e(t){var n=Cn(t);function r(e,t){var r=n((e=un(e)).r,(t=un(t)).r),i=n(e.g,t.g),a=n(e.b,t.b),o=wn(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=i(t),e.b=a(t),e.opacity=o(t),e+``}}return r.gamma=e,r})(1);function U(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}var En=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Dn=new RegExp(En.source,`g`);function On(e){return function(){return e}}function kn(e){return function(t){return e(t)+``}}function An(e,t){var n=En.lastIndex=Dn.lastIndex=0,r,i,a,o=-1,s=[],c=[];for(e+=``,t+=``;(r=En.exec(e))&&(i=Dn.exec(t));)(a=i.index)>n&&(a=t.slice(n,a),s[o]?s[o]+=a:s[++o]=a),(r=r[0])===(i=i[0])?s[o]?s[o]+=i:s[++o]=i:(s[++o]=null,c.push({i:o,x:U(r,i)})),n=Dn.lastIndex;return n180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(i(n)+`rotate(`,null,r)-2,x:U(e,t)}))}function s(e,t,n,a){e===t?t&&n.push(i(n)+`skewX(`+t+r):a.push({i:n.push(i(n)+`skewX(`,null,r)-2,x:U(e,t)})}function c(e,t,n,r,a,o){if(e!==n||t!==r){var s=a.push(i(a)+`scale(`,null,`,`,null,`)`);o.push({i:s-4,x:U(e,n)},{i:s-2,x:U(t,r)})}else(n!==1||r!==1)&&a.push(i(a)+`scale(`+n+`,`+r+`)`)}return function(t,n){var r=[],i=[];return t=e(t),n=e(n),a(t.translateX,t.translateY,n.translateX,n.translateY,r,i),o(t.rotate,n.rotate,r,i),s(t.skewX,n.skewX,r,i),c(t.scaleX,t.scaleY,n.scaleX,n.scaleY,r,i),t=n=null,function(e){for(var t=-1,n=i.length,a;++t=0&&e._call.call(void 0,t),e=e._next;--W}function Qn(){K=(Wn=q.now())+Gn,W=Bn=0;try{Zn()}finally{W=0,er(),K=0}}function $n(){var e=q.now(),t=e-Wn;t>Hn&&(Gn-=t,Wn=e)}function er(){for(var e,t=Un,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Un=n);G=e,tr(r)}function tr(e){W||(Bn&&=clearTimeout(Bn),e-K>24?(e<1/0&&(Bn=setTimeout(Qn,e-q.now()-Gn)),Vn&&=clearInterval(Vn)):(Vn||=(Wn=q.now(),setInterval($n,Hn)),W=1,Kn(Qn)))}function nr(e,t,n){var r=new Yn;return t=t==null?0:+t,r.restart(n=>{r.stop(),e(n+t)},t,n),r}var rr=v(`start`,`end`,`cancel`,`interrupt`),ir=[];function J(e,t,n,r,i,a){var o=e.__transition;if(!o)e.__transition={};else if(n in o)return;or(e,n,{name:t,index:r,group:i,on:rr,tween:ir,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:0})}function ar(e,t){var n=X(e,t);if(n.state>0)throw Error(`too late; already scheduled`);return n}function Y(e,t){var n=X(e,t);if(n.state>3)throw Error(`too late; already running`);return n}function X(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw Error(`transition not found`);return n}function or(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=Xn(a,0,n.time);function a(e){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=e&&o(e-n.delay)}function o(a){var l,u,d,f;if(n.state!==1)return c();for(l in r)if(f=r[l],f.name===n.name){if(f.state===3)return nr(o);f.state===4?(f.state=6,f.timer.stop(),f.on.call(`interrupt`,e,e.__data__,f.index,f.group),delete r[l]):+l2&&r.state<5,r.state=6,r.timer.stop(),r.on.call(i?`interrupt`:`cancel`,e,e.__data__,r.index,r.group),delete n[o]}a&&delete e.__transition}}function cr(e){return this.each(function(){sr(this,e)})}function lr(e,t){var n,r;return function(){var i=Y(this,e),a=i.tween;if(a!==n){r=n=a;for(var o=0,s=r.length;o=0&&(e=e.slice(0,t)),!e||e===`start`})}function zr(e,t,n){var r,i,a=Rr(t)?ar:Y;return function(){var o=a(this,e),s=o.on;s!==r&&(i=(r=s).copy()).on(t,n),o.on=i}}function Br(e,t){var n=this._id;return arguments.length<2?X(this.node(),n).on.on(e):this.each(zr(n,e,t))}function Vr(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function Hr(){return this.on(`end.remove`,Vr(this._id))}function Ur(e){var t=this._name,n=this._id;typeof e!=`function`&&(e=re(e));for(var r=this._groups,i=r.length,a=Array(i),o=0;o":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACE`,5:`NL`,6:`SD`,14:`DESCR`,15:`-->`,16:`HIDE_EMPTY`,17:`scale`,18:`WIDTH`,19:`COMPOSIT_STATE`,20:`STRUCT_START`,21:`STRUCT_STOP`,22:`STATE_DESCR`,23:`AS`,24:`ID`,25:`FORK`,26:`JOIN`,27:`CHOICE`,28:`CONCURRENT`,29:`note`,31:`NOTE_TEXT`,33:`acc_title`,34:`acc_title_value`,35:`acc_descr`,36:`acc_descr_value`,37:`acc_descr_multiline_value`,38:`CLICK`,39:`STRING`,40:`HREF`,41:`classDef`,42:`CLASSDEF_ID`,43:`CLASSDEF_STYLEOPTS`,44:`DEFAULT`,45:`style`,46:`STYLE_IDS`,47:`STYLEDEF_STYLEOPTS`,48:`class`,49:`CLASSENTITY_IDS`,50:`STYLECLASS`,51:`direction_tb`,52:`direction_bt`,53:`direction_rl`,54:`direction_lr`,56:`;`,57:`EDGE_STATE`,58:`STYLE_SEPARATOR`,59:`left_of`,60:`right_of`},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:return r.setRootDoc(a[s]),a[s];case 4:this.$=[];break;case 5:a[s]!=`nl`&&(a[s-1].push(a[s]),this.$=a[s-1]);break;case 6:case 7:this.$=a[s];break;case 8:this.$=`nl`;break;case 12:this.$=a[s];break;case 13:let e=a[s-1];e.description=r.trimColon(a[s]),this.$=e;break;case 14:this.$={stmt:`relation`,state1:a[s-2],state2:a[s]};break;case 15:let t=r.trimColon(a[s]);this.$={stmt:`relation`,state1:a[s-3],state2:a[s-1],description:t};break;case 19:this.$={stmt:`state`,id:a[s-3],type:`default`,description:``,doc:a[s-1]};break;case 20:var c=a[s],l=a[s-2].trim();if(a[s].match(`:`)){var u=a[s].split(`:`);c=u[0],l=[l,u[1]]}this.$={stmt:`state`,id:c,type:`default`,description:l};break;case 21:this.$={stmt:`state`,id:a[s-3],type:`default`,description:a[s-5],doc:a[s-1]};break;case 22:this.$={stmt:`state`,id:a[s],type:`fork`};break;case 23:this.$={stmt:`state`,id:a[s],type:`join`};break;case 24:this.$={stmt:`state`,id:a[s],type:`choice`};break;case 25:this.$={stmt:`state`,id:r.getDividerId(),type:`divider`};break;case 26:this.$={stmt:`state`,id:a[s-1].trim(),note:{position:a[s-2].trim(),text:a[s].trim()}};break;case 29:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 30:case 31:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 32:this.$={stmt:`click`,id:a[s-3],url:a[s-2],tooltip:a[s-1]};break;case 33:this.$={stmt:`click`,id:a[s-3],url:a[s-1],tooltip:``};break;case 34:case 35:this.$={stmt:`classDef`,id:a[s-1].trim(),classes:a[s].trim()};break;case 36:this.$={stmt:`style`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 37:this.$={stmt:`applyClass`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 38:r.setDirection(`TB`),this.$={stmt:`dir`,value:`TB`};break;case 39:r.setDirection(`BT`),this.$={stmt:`dir`,value:`BT`};break;case 40:r.setDirection(`RL`),this.$={stmt:`dir`,value:`RL`};break;case 41:r.setDirection(`LR`),this.$={stmt:`dir`,value:`LR`};break;case 44:case 45:this.$={stmt:`state`,id:a[s].trim(),type:`default`,description:``};break;case 46:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``};break;case 47:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``}}},`anonymous`),table:[{3:1,4:t,5:r,6:i},{1:[3]},{3:5,4:t,5:r,6:i},{3:6,4:t,5:r,6:i},e([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],a,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,7]),e(A,[2,8]),e(A,[2,9]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12],{14:[1,40],15:[1,41]}),e(A,[2,16]),{18:[1,42]},e(A,[2,18],{20:[1,43]}),{23:[1,44]},e(A,[2,22]),e(A,[2,23]),e(A,[2,24]),e(A,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},e(A,[2,28]),{34:[1,49]},{36:[1,50]},e(A,[2,31]),{13:51,24:f,57:k},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},e(j,[2,44],{58:[1,56]}),e(j,[2,45],{58:[1,57]}),e(A,[2,38]),e(A,[2,39]),e(A,[2,40]),e(A,[2,41]),e(A,[2,6]),e(A,[2,13]),{13:58,24:f,57:k},e(A,[2,17]),e(M,a,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},e(A,[2,29]),e(A,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},e(A,[2,14],{14:[1,71]}),{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,72],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},e(A,[2,34]),e(A,[2,35]),e(A,[2,36]),e(A,[2,37]),e(j,[2,46]),e(j,[2,47]),e(A,[2,15]),e(A,[2,19]),e(M,a,{7:78}),e(A,[2,26]),e(A,[2,27]),{5:[1,79]},{5:[1,80]},{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,81],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,32]),e(A,[2,33]),e(A,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};N.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,r,i){function a(){let n=t.yytext.indexOf(`%%`);if(n===0)return!1;if(n>0){let r=t.yytext.slice(0,n),i=t.yytext.slice(n);i&&e.lexer.unput(i),t.yytext=r}return!0}switch(n(a,`processId`),r){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState(`SCALE`),17;case 14:return 18;case 15:this.popState();break;case 16:return this.begin(`acc_title`),33;case 17:return this.popState(),`acc_title_value`;case 18:return this.begin(`acc_descr`),35;case 19:return this.popState(),`acc_descr_value`;case 20:this.begin(`acc_descr_multiline`);break;case 21:this.popState();break;case 22:return`acc_descr_multiline_value`;case 23:return this.pushState(`CLASSDEF`),41;case 24:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 25:return this.popState(),this.pushState(`CLASSDEFID`),42;case 26:return this.popState(),43;case 27:return this.pushState(`CLASS`),48;case 28:return this.popState(),this.pushState(`CLASS_STYLE`),49;case 29:return this.popState(),50;case 30:return this.pushState(`STYLE`),45;case 31:return this.popState(),this.pushState(`STYLEDEF_STYLES`),46;case 32:return this.popState(),47;case 33:return this.pushState(`SCALE`),17;case 34:return 18;case 35:this.popState();break;case 36:this.pushState(`STATE`);break;case 37:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),25;case 38:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),26;case 39:return this.popState(),t.yytext=t.yytext.slice(0,-10).trim(),27;case 40:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),25;case 41:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),26;case 42:return this.popState(),t.yytext=t.yytext.slice(0,-10).trim(),27;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState(`STATE_STRING`);break;case 48:return this.pushState(`STATE_ID`),`AS`;case 49:return a()?(this.popState(),`ID`):void 0;case 50:this.popState();break;case 51:return`STATE_DESCR`;case 52:throw Error(`Error: State name must be a single word. Found: "`+t.yytext.trim()+`"`);case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState(`struct`),20;case 56:return this.popState(),21;case 57:break;case 58:return this.begin(`NOTE`),29;case 59:return this.popState(),this.pushState(`NOTE_ID`),59;case 60:return this.popState(),this.pushState(`NOTE_ID`),60;case 61:this.popState(),this.pushState(`FLOATING_NOTE`);break;case 62:return this.popState(),this.pushState(`FLOATING_NOTE_ID`),`AS`;case 63:break;case 64:return`NOTE_TEXT`;case 65:return a()?(this.popState(),`ID`):void 0;case 66:return a()?(this.popState(),this.pushState(`NOTE_TEXT`),24):void 0;case 67:return this.popState(),t.yytext=t.yytext.substr(2).trim(),31;case 68:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),31;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:return a()?24:void 0;case 74:return t.yytext=t.yytext.trim(),14;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return`INVALID`}},`anonymous`),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}}})();function P(){this.yy={}}return n(P,`Parser`),P.prototype=N,N.Parser=P,new P})();w.parser=w;var T=w,E=`TB`,D=`TB`,O=`dir`,k=`state`,A=`root`,j=`relation`,M=`classDef`,N=`style`,P=`applyClass`,F=`default`,ee=`divider`,te=`fill:none`,ne=`fill: #333`,re=`c`,ie=`markdown`,ae=`normal`,I=`rect`,L=`rectWithTitle`,oe=`stateStart`,se=`stateEnd`,R=`divider`,ce=`roundedWithTitle`,le=`note`,ue=`noteGroup`,z=`statediagram`,de=`${z}-state`,B=`transition`,fe=`note`,pe=`${B} note-edge`,me=`${z}-${fe}`,he=`${z}-cluster`,ge=`${z}-cluster-alt`,V=`parent`,H=`note`,_e=`state`,U=`----`,ve=`${U}${H}`,ye=`${U}${V}`,W=new Map,G=0,be=0,K=new Map,xe=n((e,t,n,r)=>{if(e===R&&n?.id!==void 0&&K.has(n.id)){let e=K.get(n.id);return K.set(t,e),e}let i=be++,a=r?void 0:i;return K.set(t,a),a},`colorSlotFor`);function q(e=``,t=0,n=``,r=U){return`${_e}-${e}${n!==null&&n.length>0?`${r}${n}`:``}-${t}`}n(q,`stateDomId`);var Se=n((t,n,r,i,a,o,c,l)=>{e.trace(`items`,n),n.forEach(e=>{switch(e.stmt){case k:X(t,e,r,i,a,o,c,l);break;case F:X(t,e,r,i,a,o,c,l);break;case j:{X(t,e.state1,r,i,a,o,c,l),X(t,e.state2,r,i,a,o,c,l);let n=c===`neo`,u={id:`edge`+G,start:e.state1.id,end:e.state2.id,arrowhead:`normal`,arrowTypeEnd:n?`arrow_barb_neo`:`arrow_barb`,style:te,labelStyle:``,label:s.sanitizeText(e.description??``,d()),arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,classes:B,look:c};a.push(u),G++}}})},`setupDoc`),Ce=n((e,t=D)=>{let n=t;if(e.doc)for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`);function J(e,t,n){if(!t.id||t.id===``||t.id===``)return;t.cssClasses&&(Array.isArray(t.cssCompiledStyles)||(t.cssCompiledStyles=[]),t.cssClasses.split(` `).forEach(e=>{let r=n.get(e);r&&(t.cssCompiledStyles=[...t.cssCompiledStyles??[],...r.styles])}));let r=e.find(e=>e.id===t.id);r?Object.assign(r,t):e.push(t)}n(J,`insertOrUpdateNode`);function we(e){return e?.classes?.join(` `)??``}n(we,`getClassesFromDbInfo`);function Y(e){return e?.styles??[]}n(Y,`getStylesFromDbInfo`);var X=n((t,n,r,i,a,o,c,l)=>{let u=n.id,f=r.get(u),p=we(f),m=Y(f),h=d(),g=p.trim()!==``||m.length>0;if(e.info(`dataFetcher parsedItem`,n,f,m),u!==`root`){let r=I;n.start===!0?r=oe:n.start===!1&&(r=se),n.type!==F&&(r=n.type),W.get(u)||W.set(u,{id:u,shape:r,description:s.sanitizeText(u,h),cssClasses:`${p} ${de}`,cssStyles:m});let d=W.get(u);n.description&&(Array.isArray(d.description)?(d.shape=L,d.description.push(n.description)):d.description?.length&&d.description.length>0?(d.shape=L,d.description=d.description===u?[n.description]:[d.description,n.description]):(d.shape=I,d.description=n.description),d.description=s.sanitizeTextOrArray(d.description,h)),d.description?.length===1&&d.shape===L&&(d.shape=d.type===`group`?ce:I),!d.type&&n.doc&&(e.info(`Setting cluster for XCX`,u,Ce(n)),d.type=`group`,d.isGroup=!0,d.dir=Ce(n),d.shape=n.type===ee?R:ce,d.colorIndex=xe(d.shape,u,t,g),d.cssClasses=`${d.cssClasses} ${he} ${o?ge:``}`);let f={labelStyle:``,shape:d.shape,label:d.description,cssClasses:d.cssClasses,cssCompiledStyles:[],cssStyles:d.cssStyles,id:u,dir:d.dir,domId:q(u,G),type:d.type,isGroup:d.type===`group`,colorIndex:d.colorIndex,padding:8,rx:10,ry:10,look:c,labelType:`markdown`};if(f.shape===R&&(f.label=``),t&&t.id!==`root`&&(e.trace(`Setting node `,u,` to be child of its parent `,t.id),f.parentId=t.id),f.centerLabel=!0,n.note){let e={labelStyle:``,shape:le,label:n.note.text,labelType:`markdown`,cssClasses:me,cssStyles:[],cssCompiledStyles:[],id:u+ve+`-`+G,domId:q(u,G,H),type:`node`,isGroup:!1,padding:h.flowchart?.padding,look:c,position:n.note.position},t=u+ye,r={labelStyle:``,shape:ue,label:n.note.text,cssClasses:d.cssClasses,cssStyles:[],id:u+ye,domId:q(u,G,V),type:`group`,isGroup:!0,padding:16,look:c,position:n.note.position};G++,r.id=t,e.parentId=t,J(i,r,l),J(i,e,l),J(i,f,l);let o=u,s=e.id;n.note.position===`left of`&&(o=e.id,s=u),a.push({id:o+`-`+s,start:o,end:s,arrowhead:`none`,arrowTypeEnd:``,style:te,labelStyle:``,classes:pe,pattern:`dashed`,arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,look:c})}else J(i,f,l)}n.doc&&(e.trace(`Adding nodes children `),Se(n,n.doc,r,i,a,!o,c,l))},`dataFetcher`),Te=n(()=>{W.clear(),G=0,be=0,K.clear()},`reset`),Ee=n((e,t=D)=>{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`),De={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing state diagram (v2)`,n);let{securityLevel:a,state:o,layout:s}=d();i.db.extract(i.db.getRootDocV2());let c=i.db.getData(),l=S(n,a);c.type=i.type,c.layoutAlgorithm=b(s),c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=d().look===`neo`?[`barbNeo`]:[`barb`],c.diagramId=n,await y(c,l);try{(typeof i.db.getLinks==`function`?i.db.getLinks():new Map).forEach((t,n)=>{let r=typeof n==`string`?n:typeof n?.id==`string`?n.id:``,i=c.nodes.find(e=>e.id===r);if(!r){e.warn(`⚠️ Invalid or missing stateId from key:`,JSON.stringify(n));return}let a=l.node()?.querySelectorAll(`g.node, g.rough-node`),o;if(a?.forEach(e=>{let t=e.textContent?.trim();(e.id===i?.domId||t===r)&&(o=e)}),!o){e.warn(`⚠️ Could not find node matching text:`,r);return}let s=o.parentNode;if(!s){e.warn(`⚠️ Node has no parent, cannot wrap:`,r);return}let u=document.createElementNS(`http://www.w3.org/2000/svg`,`a`),d=t.url.replace(/^"+|"+$/g,``);if(u.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,d),u.setAttribute(`target`,`_blank`),t.tooltip){let e=t.tooltip.replace(/^"+|"+$/g,``);u.setAttribute(`title`,e),o.setAttribute(`title`,e)}s.replaceChild(u,o),u.appendChild(o),e.info(`🔗 Wrapped node in tag for:`,r,t.url)})}catch(t){e.error(`❌ Error injecting clickable links:`,t)}p.insertTitle(l,`statediagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),C(l,8,z,o?.useMaxWidth??!0)},`draw`),getDir:Ee},Z={START_NODE:`[*]`,START_TYPE:`start`,END_NODE:`[*]`,END_TYPE:`end`,COLOR_KEYWORD:`color`,FILL_KEYWORD:`fill`,BG_FILL:`bgFill`,STYLECLASS_SEP:`,`},Oe=n(()=>new Map,`newClassesList`),Q=n(()=>({relations:[],states:new Map,documents:{}}),`newDoc`),$=n(e=>JSON.parse(JSON.stringify(e)),`clone`),ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=Oe(),this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=f,this.setAccTitle=i,this.getAccDescription=l,this.setAccDescription=r,this.setDiagramTitle=o,this.getDiagramTitle=u,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{n(this,`StateDB`)}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let t of Array.isArray(e)?e:e.doc)switch(t.stmt){case k:this.addState(t.id.trim(),t.type,t.doc,t.description,t.note);break;case j:this.addRelation(t.state1,t.state2,t.description);break;case M:this.addStyleClass(t.id.trim(),t.classes);break;case N:this.handleStyleDef(t);break;case P:this.setCssClass(t.id.trim(),t.styleClass);break;case`click`:this.addLink(t.id,t.url,t.tooltip)}let t=this.getStates(),n=d();Te(),X(void 0,this.getRootDocV2(),t,this.nodes,this.edges,!0,n.look,this.classes);for(let e of this.nodes)if(Array.isArray(e.label)){if(e.description=e.label.slice(1),e.isGroup&&e.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${e.id}]`);e.label=e.label[0]}}handleStyleDef(e){let t=e.id.trim().split(`,`),n=e.styleClass.split(`,`);for(let e of t){let t=this.getState(e);if(!t){let n=e.trim();this.addState(n),t=this.getState(n)}t&&(t.styles=n.map(e=>e.replace(/;/g,``)?.trim()))}}setRootDoc(t){e.info(`Setting root doc`,t),this.rootDoc=t,this.version===1?this.extract(t):this.extract(this.getRootDocV2())}docTranslator(e,t,n){if(t.stmt===j){this.docTranslator(e,t.state1,!0),this.docTranslator(e,t.state2,!1);return}if(t.stmt===k&&(t.id===Z.START_NODE?(t.id=e.id+(n?`_start`:`_end`),t.start=n):t.id=t.id.trim()),t.stmt!==A&&t.stmt!==k||!t.doc)return;let r=[],i=[];for(let e of t.doc)if(e.type===ee){let t=$(e);t.doc=$(i),r.push(t),i=[]}else i.push(e);if(r.length>0&&i.length>0){let e={stmt:k,id:m(),type:`divider`,doc:$(i)};r.push($(e)),t.doc=r}t.doc.forEach(e=>this.docTranslator(t,e,!0))}getRootDocV2(){return this.docTranslator({id:A,stmt:A},{id:A,stmt:A,doc:this.rootDoc},!0),{id:A,doc:this.rootDoc}}addState(t,n=F,r=void 0,i=void 0,a=void 0,o=void 0,c=void 0,l=void 0){let u=t?.trim();if(!this.currentDocument.states.has(u))e.info(`Adding state `,u,i),this.currentDocument.states.set(u,{stmt:k,id:u,descriptions:[],type:n,doc:r,note:a,classes:[],styles:[],textStyles:[]});else{let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.doc||=r,e.type||=n}if(i&&(e.info(`Setting state description`,u,i),(Array.isArray(i)?i:[i]).forEach(e=>this.addDescription(u,e.trim()))),a){let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.note=a,e.note.text=s.sanitizeText(e.note.text,d())}o&&(e.info(`Setting state classes`,u,o),(Array.isArray(o)?o:[o]).forEach(e=>this.setCssClass(u,e.trim()))),c&&(e.info(`Setting state styles`,u,c),(Array.isArray(c)?c:[c]).forEach(e=>this.setStyle(u,e.trim()))),l&&(e.info(`Setting state styles`,u,c),(Array.isArray(l)?l:[l]).forEach(e=>this.setTextStyle(u,e.trim())))}clear(e){this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=Oe(),e||(this.links=new Map,a())}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){e.info(`Documents = `,this.documents)}getRelations(){return this.currentDocument.relations}addLink(t,n,r){this.links.set(t,{url:n,tooltip:r}),e.warn(`Adding link`,t,n,r)}getLinks(){return this.links}startIdIfNeeded(e=``){return e===Z.START_NODE?(this.startEndCount++,`${Z.START_TYPE}${this.startEndCount}`):e}startTypeIfNeeded(e=``,t=F){return e===Z.START_NODE?Z.START_TYPE:t}endIdIfNeeded(e=``){return e===Z.END_NODE?(this.startEndCount++,`${Z.END_TYPE}${this.startEndCount}`):e}endTypeIfNeeded(e=``,t=F){return e===Z.END_NODE?Z.END_TYPE:t}addRelationObjs(e,t,n=``){let r=this.startIdIfNeeded(e.id.trim()),i=this.startTypeIfNeeded(e.id.trim(),e.type),a=this.startIdIfNeeded(t.id.trim()),o=this.startTypeIfNeeded(t.id.trim(),t.type);this.addState(r,i,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(a,o,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:s.sanitizeText(n,d())})}addRelation(e,t,n){if(typeof e==`object`&&typeof t==`object`)this.addRelationObjs(e,t,n);else if(typeof e==`string`&&typeof t==`string`){let r=this.startIdIfNeeded(e.trim()),i=this.startTypeIfNeeded(e),a=this.endIdIfNeeded(t.trim()),o=this.endTypeIfNeeded(t);this.addState(r,i),this.addState(a,o),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:n?s.sanitizeText(n,d()):void 0})}}addDescription(e,t){let n=this.currentDocument.states.get(e),r=t.startsWith(`:`)?t.replace(`:`,``).trim():t;n?.descriptions?.push(s.sanitizeText(r,d()))}cleanupLabel(e){return e.startsWith(`:`)?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,t=``){this.classes.has(e)||this.classes.set(e,{id:e,styles:[],textStyles:[]});let n=this.classes.get(e);t&&n&&t.split(Z.STYLECLASS_SEP).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(Z.COLOR_KEYWORD).exec(e)){let e=t.replace(Z.FILL_KEYWORD,Z.BG_FILL).replace(Z.COLOR_KEYWORD,Z.FILL_KEYWORD);n.textStyles.push(e)}n.styles.push(t)})}getClasses(){return this.classes}setupToolTips(e){let n=x();t(e).select(`svg`).selectAll(`g.node, g.rough-node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(c.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=this.getState(e);if(!n){let t=e.trim();this.addState(t),n=this.getState(t)}n?.classes?.push(t)})}setStyle(e,t){this.getState(e)?.styles?.push(t)}setTextStyle(e,t){this.getState(e)?.textStyles?.push(t)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirectionStatement(){return this.rootDoc.find(e=>e.stmt===O)}getDirection(){return this.getDirectionStatement()?.value??E}setDirection(e){let t=this.getDirectionStatement();t?t.value=e:this.rootDoc.unshift({stmt:O,value:e})}trimColon(e){return e.startsWith(`:`)?e.slice(1).trim():e.trim()}getData(){let e=d();for(let t of this.nodes)t.wrappingWidth??=e.state?.wrappingWidth,t.isGroup||(t.minWidth??=e.state?.minNodeWidth);return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:Ee(this.getRootDocV2())}}getConfig(){return d().state}},Ae=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!g(t,r))return``;let i=_(e.look),a=v(n),o=``;for(let e=0;e` +${Ae(e)} +defs [id$="-barbEnd"] { + fill: ${e.transitionColor}; + stroke: ${e.transitionColor}; + } +g.stateGroup text { + fill: ${e.nodeBorder}; + stroke: none; + font-size: 10px; +} +g.stateGroup text { + fill: ${e.textColor}; + stroke: none; + font-size: 10px; + +} +g.stateGroup .state-title { + font-weight: bolder; + fill: ${e.stateLabelColor}; +} + +g.stateGroup rect { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; +} + +g.stateGroup line { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth||1}; +} + +.transition { + stroke: ${e.transitionColor}; + stroke-width: ${e.strokeWidth||1}; + fill: none; +} + +.stateGroup .composit { + fill: ${e.background}; + border-bottom: 1px +} + +.stateGroup .alt-composit { + fill: #e0e0e0; + border-bottom: 1px +} + +.state-note { + stroke: ${e.noteBorderColor}; + fill: ${e.noteBkgColor}; + + text { + fill: ${e.noteTextColor}; + stroke: none; + font-size: 10px; + } +} + +.stateLabel .box { + stroke: none; + stroke-width: 0; + fill: ${e.mainBkg}; + opacity: 0.5; +} + +.edgeLabel .label rect { + fill: ${e.labelBackgroundColor}; + opacity: 0.5; +} +.edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; +} +.edgeLabel .label text { + fill: ${e.transitionLabelColor||e.tertiaryTextColor}; +} +.label div .edgeLabel { + color: ${e.transitionLabelColor||e.tertiaryTextColor}; +} + +.stateLabel text { + fill: ${e.stateLabelColor}; + font-size: 10px; + font-weight: bold; +} + +.node circle.state-start { + fill: ${e.specialStateColor}; + stroke: ${e.specialStateColor}; +} + +.node .fork-join { + fill: ${e.specialStateColor}; + stroke: ${e.specialStateColor}; +} + +.node circle.state-end { + fill: ${e.innerEndBackground}; + stroke: ${e.background}; + stroke-width: 1.5 +} +.end-state-inner { + fill: ${e.compositeBackground||e.background}; + // stroke: ${e.background}; + stroke-width: 1.5 +} + +.node rect { + fill: ${e.stateBkg||e.mainBkg}; + stroke: ${e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth||1}px; +} +.node polygon { + fill: ${e.mainBkg}; + stroke: ${e.stateBorder||e.nodeBorder};; + stroke-width: ${e.strokeWidth||1}px; +} +[id$="-barbEnd"] { + fill: ${e.lineColor}; +} + +.statediagram-cluster rect { + fill: ${e.compositeTitleBackground}; + stroke: ${e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth||1}px; +} + +.cluster-label, .nodeLabel { + color: ${e.stateLabelColor}; + // line-height: 1; +} + +.statediagram-cluster rect.outer { + rx: 5px; + ry: 5px; +} +.statediagram-state .divider { + stroke: ${e.stateBorder||e.nodeBorder}; +} + +.statediagram-state .title-state { + rx: 5px; + ry: 5px; +} +.statediagram-cluster.statediagram-cluster .inner { + fill: ${e.compositeBackground||e.background}; +} +.statediagram-cluster.statediagram-cluster-alt .inner { + fill: ${e.altBackground?e.altBackground:`#efefef`}; +} + +.statediagram-cluster .inner { + rx:0; + ry:0; +} + +.statediagram-state rect.basic { + rx: 5px; + ry: 5px; +} +.statediagram-state rect.divider { + stroke-dasharray: 10,10; + fill: ${e.altBackground?e.altBackground:`#efefef`}; +} + +.note-edge { + stroke-dasharray: 5; +} + +.statediagram-note rect { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + stroke-width: 1px; + rx: 0; + ry: 0; +} +.statediagram-note rect { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + stroke-width: 1px; + rx: 0; + ry: 0; +} + +.statediagram-note text { + fill: ${e.noteTextColor}; +} + +.statediagram-note .nodeLabel { + color: ${e.noteTextColor}; +} +.statediagram .edgeLabel { + color: red; // ${e.noteTextColor}; +} + +[id$="-dependencyStart"], [id$="-dependencyEnd"] { + fill: ${e.lineColor}; + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth||1}; +} + +.statediagramTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; +} + +[data-look="neo"].statediagram-cluster rect { + fill: ${e.mainBkg}; + stroke: ${e.useGradient?`url(`+e.svgId+`-gradient)`:e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}; +} +[data-look="neo"].statediagram-cluster rect.outer { + rx: ${e.radius}px; + ry: ${e.radius}px; + filter: ${e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${e.svgId}-drop-shadow)`):`none`} +} +`,`getStyles`),init:n(e=>{e.state||={},e.state.arrowMarkerAbsolute=e.arrowMarkerAbsolute},`init`)};export{je as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/swimlanes-2SLR337P-BKvviDHP.js b/frontend/dist/assets/swimlanes-2SLR337P-BKvviDHP.js new file mode 100644 index 0000000..af51a89 --- /dev/null +++ b/frontend/dist/assets/swimlanes-2SLR337P-BKvviDHP.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import{r as n}from"./chunk-3FUC2YCW-CmoZ3fbX.js";import{t as r}from"./chunk-NETBCI7D-Br7cqgBT.js";function i(e,{measure:t}){let n=e.config?.swimlane?.lineHops;if(n===!1)return;let i=n===`gap`?`gap`:`arc`,a=e.edges.filter(e=>Array.isArray(e.points)&&e.points.length>=2).map(e=>({id:e.id,points:e.points,curve:e.curve,arrowTypeStart:e.arrowTypeStart,arrowTypeEnd:e.arrowTypeEnd}));r(t.groups.edgePaths,a,{enabled:!0,jumpRadius:6,jumpStyle:i})}t(i,`applySwimlaneLineJumps`);var a=`__swimlane_default__`,o=21,s=20;function c(e){return Math.max(e.padding??s,s)}t(c,`topLaneHorizontalPadding`);function l(e){let{x:t,y:n,width:r,height:i}=e,a=e.swimlaneContentTop;if(typeof t!=`number`||typeof n!=`number`||typeof r!=`number`||typeof i!=`number`||typeof a!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||!Number.isFinite(r)||!Number.isFinite(i)||!Number.isFinite(a)||r<=0||i<=0){delete e.groupTitleRect;return}let s=n-i/2,c=Math.min(a,n+i/2),l=s+Math.min(o,Math.max(0,c-s));if(l<=s){delete e.groupTitleRect;return}e.groupTitleRect={left:t-r/2,right:t+r/2,top:s,bottom:l}}t(l,`assignTopLaneTitleRect`);function u(e){let t=e.direction,n=e.nodes??=[];for(let n of e.nodes??[])n.isGroup&&!n.parentId&&(n.shape=`swimlane`,t&&(n.direction=t));let r=n.filter(e=>!e.isGroup&&!e.parentId);if(r.length===0)return;let i=n.find(e=>e.id===a);i?i.isGroup&&(i.shape=`swimlane`,t&&(i.direction=t)):(i={id:a,label:``,isGroup:!0,shape:`swimlane`,padding:20,look:e.config?.look,colorIndex:n.reduce((e,t)=>Math.max(e,t.colorIndex??-1),-1)+1,...t?{direction:t}:{}},n.push(i));for(let e of r)e.parentId=a}t(u,`prepareLayoutForSwimlanes`);function d(e){let t=new Map;for(let n of e.nodes??[])t.set(n.id,n);let n=[];for(let t of e.edges??[]){let e=typeof t.start==`string`?t.start:void 0,r=typeof t.end==`string`?t.end:void 0;!e||!r||t.labelNodeId||n.push({id:t.id,src:e,dst:r,ref:t})}let r=e.nodes??[],i=r.filter(e=>e.isGroup),a=r.filter(e=>!e.isGroup);return{nodes:[...[...i].reverse(),...a].map(e=>e.id),edges:n,layout:e,nodeById:t}}t(d,`toGraphView`);function f(e,t,n,r){let{layout:i}=e,a=e.nodeById,o=r?.layerGap??100,s=r?.nodeGap??40,u=0;for(let e of t.layers){let t=0;for(let r of e){let e=a.get(r);if(!e){t++;continue}e.layer=u,e.order=t;let i=n.x[r]??t*s,c=n.y[r]??u*o;e.x=i,e.y=c,t++}u++}let d=i.nodes??[],f=new Map,p=[];for(let e of d){if(!e?.isGroup)continue;e.parentId||p.push(e);let t=d.filter(t=>t.parentId===e.id),r=1/0,i=-1/0,a=1/0,o=-1/0;for(let e of t){let t=e.x??n.x[e.id],s=e.y??n.y[e.id],c=e.width??0,l=e.height??0;t!=null&&s!=null&&(r=Math.min(r,t-c/2),i=Math.max(i,t+c/2),a=Math.min(a,s-l/2),o=Math.max(o,s+l/2))}if(r===1/0||a===1/0)e.x=e.x??0,e.y=e.y??0,e.width=e.width??0,e.height=e.height??0;else{let t=e.padding??20,n=e.parentId?t:2*c(e),s=t,l=Math.max(0,i-r)+n,u=Math.max(0,o-a)+s,d=(r+i)/2,p=(a+o)/2;e.x=d,e.y=p,e.width=l,e.height=u,f.set(e.id,{minX:r,maxX:i,minY:a,maxY:o})}}if(p.length>0&&f.size>0){let e=1/0,t=-1/0,n=0;for(let r of p){let i=r.padding??20;i>n&&(n=i);let a=f.get(r.id);a&&(e=Math.min(e,a.minY),t=Math.max(t,a.maxY))}if(e!==1/0&&t!==-1/0){let r=Math.max(0,t-e)+2*Math.max(n,36),i=(e+t)/2;for(let t of p)t.y=i,t.height=r,t.swimlaneContentTop=e;let a=[...p].sort((e,t)=>(e.x??0)-(t.x??0)),o=[],s=[],u=[];for(let e of a){let t=f.get(e.id);if(!t)continue;let n=Math.max(0,t.maxX-t.minX)+2*c(e),r=(t.minX+t.maxX)/2;o.push(e.id),s.push(r),u.push(n)}let d=o.length;if(d>0){let e=new Map;if(d===1)e.set(o[0],u[0]);else{let t=[];for(let e=0;e0&&i>0?{cx:t,cy:n,rect:P(t,n,r,i)}:void 0}t(g,`measuredNodeRect`);function _(e){if(e.isGroup)return;let t=g(e);if(t)return{id:String(e.id??``),cx:t.cx,cy:t.cy,rect:t.rect}}t(_,`nodeBoundsInfoFor`);function v(e,t,n=h){return Math.abs(e.x-t.x)n}t(x,`isHorizontalSegment`);function S(e,t,n=h){return y(e,t,n)&&Math.abs(e.y-t.y)>n}t(S,`isVerticalSegment`);function C(e,t,n,r){return Math.max(0,Math.min(Math.max(e,t),Math.max(n,r))-Math.max(Math.min(e,t),Math.min(n,r)))}t(C,`overlapLength`);function w(e,t,n=h){return e.horizontal&&t.horizontal&&b(e.a,t.a,n)?C(e.a.x,e.b.x,t.a.x,t.b.x):e.vertical&&t.vertical&&y(e.a,t.a,n)?C(e.a.y,e.b.y,t.a.y,t.b.y):0}t(w,`sameAxisSegmentOverlapLength`);function T(e,t=h){let n=[];for(let r=0;r0?n[n.length-1]:void 0;(!e||!v(e,r,t))&&n.push({x:r.x,y:r.y})}return n}t(D,`dedupeConsecutivePoints`);function O(e,t=h){if(!e||e.length!==4)return;let[n,r,i,a]=e;return x(n,r,t)&&S(r,i,t)&&x(i,a,t)?{kind:`HVH`,p0:n,p1:r,p2:i,p3:a}:S(n,r,t)&&x(r,i,t)&&S(i,a,t)?{kind:`VHV`,p0:n,p1:r,p2:i,p3:a}:void 0}t(O,`classifyThreeSegmentRoute`);function k(e,t,n,r=0){let i=Math.min(e.x,t.x),a=Math.max(e.x,t.x),o=Math.min(e.y,t.y),s=Math.max(e.y,t.y);return a>n.left-r&&in.top-r&&ot.left+n&&e.xt.top+n&&e.y=t.right&&e.top<=t.top&&e.bottom>=t.bottom}t(j,`rectContainsRect`);function M(e,t){return e.leftt.left&&e.topt.top}t(M,`rectsOverlap`);function N(e,t){return{left:e.left-t,right:e.right+t,top:e.top-t,bottom:e.bottom+t}}t(N,`inflateRect`);function P(e,t,n,r){return{left:e-n/2,right:e+n/2,top:t-r/2,bottom:t+r/2}}t(P,`rectFromCenterSize`);function F(e){return g(e)?.rect}t(F,`rectOfNodeBounds`);function I(e,t){switch(t){case`top`:return{x:e.cx,y:e.rect.top};case`bottom`:return{x:e.cx,y:e.rect.bottom};case`left`:return{x:e.rect.left,y:e.cy};case`right`:return{x:e.rect.right,y:e.cy}}}t(I,`portForRectSide`);function ee(e,t,n,r,i,a=h){let o=t===`left`||t===`right`,s=r===`left`||r===`right`;if(o&&s){if(t===`right`&&r===`left`&&e.xn.x){if(b(e,n,a))return[e,n];let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}if(t===r){if(b(e,n,a))return;let r=t===`left`?Math.min(e.x,n.x)-i:Math.max(e.x,n.x)+i;return[e,{x:r,y:e.y},{x:r,y:n.y},n]}return}if(!o&&!s){if(t===r){if(y(e,n,a))return;let r=t===`top`?Math.min(e.y,n.y)-i:Math.max(e.y,n.y)+i;return[e,{x:e.x,y:r},{x:n.x,y:r},n]}if(!(t===`bottom`&&r===`top`&&e.yn.y))return;if(y(e,n,a))return[e,n];let o=(e.y+n.y)/2;return[e,{x:e.x,y:o},{x:n.x,y:o},n]}if(o&&!s){let i=t===`right`&&n.x>e.x||t===`left`&&n.xn.y;return i&&a?[e,{x:n.x,y:e.y},n]:void 0}let c=t===`bottom`&&n.y>e.y||t===`top`&&n.yn.x;return c&&l?[e,{x:e.x,y:n.y},n]:void 0}t(ee,`buildOrthogonalPortPath`);function L(e,t,n,r){return t===`left`||t===`right`?[e,{x:r,y:e.y},{x:r,y:n.y},n]:[e,{x:e.x,y:r},{x:n.x,y:r},n]}t(L,`buildSameSideTrackPath`);function R(e){let t=new Map,n=[];for(let r of e){if(r.isEdgeLabel)continue;let e=_(r);e&&(t.set(e.id,e),n.push({id:e.id,rect:e.rect}))}return{nodeInfoById:t,realNodeRects:n}}t(R,`collectRealNodeBounds`);function z(e){let t=[],n=[];for(let r of e){let e=_(r);if(!e)continue;let i={id:e.id,rect:e.rect};r.isEdgeLabel?n.push(i):t.push(i)}return{realNodeRects:t,labelNodeRects:n}}t(z,`collectNodeRectEntries`);function te(e,{includeEdgeLabels:t=!0}={}){let n=[];for(let r of e){if(r.isGroup||!t&&r.isEdgeLabel)continue;let e=r.x??0,i=r.y??0,a=r.width??0,o=r.height??0;n.push({nodeId:r.id,...P(e,i,a,o)})}return n}t(te,`collectLayoutNodeRects`);function ne(e,t,n=h){let r=e.start,i=e.end;if(!r||!i)return;let a=t.get(r),o=t.get(i);if(!(!a||!o))return{srcId:r,dstId:i,srcInfo:a,dstInfo:o,collinearX:Math.abs(a.cx-o.cx)m||f<_||f>v)return!1;let x=Math.abs(g-u.a.x)i:a&&s&&b(e,n,i)?C(e.x,t.x,n.x,r.x)>i:!1}t(ie,`sameAxisSegmentsOverlap`);function ae(e,t,n,r,{epsilon:i=h,skipDegenerateOther:a=!1}={}){for(let o of n){if(o===r||o.isLayoutOnly)continue;let n=o.points;if(!(!n||n.length<2))for(let r=0;rf+i&&mg+i&&d<_-i}t(V,`orthogonalSegmentsStrictlyCross`);function oe(e,t,n){let r=Math.min(t,n),i=Math.max(t,n);return e>r+h&&e=2?t[t.length-2]:void 0,n=e&&y(e,r)?{x:r.x,y:i.y}:{x:i.x,y:r.y};t.push(n)}t.push(i)}let n=[];for(let e of t){let t=n[n.length-1];(!t||!v(t,e))&&n.push(e)}return n}t(W,`orthogonalizePolyline`);function G(e){if(e.length<3)return e;let t=[...e];for(let e=0;e<32;e++){let e=U(t);if(t=e.points,!e.changed)break}return t}t(G,`simplifyPolyline`);var K=.001,se=.5,ce=4;function le(e,t,n){let r=e;if(r.isLayoutOnly||!r.points||r.points.length=0&&i=e.length)return e;let a=i-r;if(a<0||a>=e.length)return e;let o=ue(e[i],e[a],t);return n?[o,...e.slice(i)]:[...e.slice(0,i+1),o]}t(de,`clipEndpoint`);function q(e,t){for(let n of e){let e=le(n,t,2);if(!e)continue;let r=[...e.points];e.srcRect&&(r=de(r,e.srcRect,!0)),e.dstRect&&(r=de(r,e.dstRect,!1)),r=G(W(r)),r=xe(r,e.srcRect,e.dstRect),e.edge.points=G(W(r))}}t(q,`clipEdgeEndpointsToNodeBoundaries`);function J(e,t,n,r=!1){if(b(e,t,K)){if(t.yn.bottom+K)return t;if(r){if(e.xn.right+K)return{x:n.right,y:e.y}}return{x:Math.abs(t.x-n.left)<=Math.abs(t.x-n.right)?n.left:n.right,y:e.y}}if(y(e,t,K)){if(t.xn.right+K)return t;if(r){if(e.yn.bottom+K)return{x:e.x,y:n.bottom}}let i=Math.abs(t.y-n.top)<=Math.abs(t.y-n.bottom);return{x:e.x,y:i?n.top:n.bottom}}return t}t(J,`snapEndpointToBoundary`);function fe(e,t,n){let r=e[t];for(let i=t+n;i>=0&&ie.lo)),n=Math.min(...e.map(e=>e.hi));if(!(t>n))return{lo:t,hi:n}}t(he,`intersectRanges`);function ge(e,t){return t===`left`||t===`right`?pe(e.top,e.bottom):pe(e.left,e.right)}t(ge,`clearanceRangeForSide`);function _e(e,t,n){let r=e.y>=n.top-K&&e.y<=n.bottom+K,i=e.x>=n.left-K&&e.x<=n.right+K;if(b(e,t,K)&&r){if(Math.abs(e.x-n.left)0?he(a):void 0}t(ye,`straightClearanceRange`);function be(e,t,n,r,i){let a=ye(e,t,n,r,i);if(!a)return;let o=i?e.y:e.x,s=Math.min(a.hi,Math.max(a.lo,o));if(!(Math.abs(s-o)({...e}));for(let s=t;s>=0&&s=n.left-K&&Math.max(e.x,t.x)<=n.right+K,i=Math.min(e.y,t.y)>=n.top-K&&Math.max(e.y,t.y)<=n.bottom+K;if(Math.abs(e.y-n.top)r.bottom+K;case`left`:return b(t,n,K)&&n.xr.right+K}}t(Ee,`leavesOutward`);function De(e,t,n){if(e.length<3)return e;if(n){let n=Te(e[0],e[1],t);return n&&Ee(n,e[1],e[2],t)?e.slice(1):e}let r=e.length-1,i=Te(e[r-1],e[r],t);return i&&Ee(i,e[r-1],e[r-2],t)?e.slice(0,r):e}t(De,`collapseOwnBorderStub`);function Oe(e,t,n){let r=e;if(t){let e=fe(r,0,1);if(e){let n=J(e,r[0],t);n!==r[0]&&(r=[n,...r.slice(1)])}r=De(r,t,!0)}if(n){let e=r.length-1,t=fe(r,e,-1);if(t){let i=J(t,r[e],n,!0);i!==r[e]&&(r=[...r.slice(0,e),i])}r=De(r,n,!1)}let i=xe(r,t,n);return i!==r||r.length===2?i:(t&&(r=we(r,t,!0)),n&&(r=we(r,n,!1)),r)}t(Oe,`snapAndCollapseEndpoints`);function ke(e,t){for(let n of e){let e=le(n,t,2);if(!e)continue;let r=Oe(D(e.points,K),e.srcRect,e.dstRect);if(r.length<3){e.edge.points=r;continue}let i=[r[0],{...r[0]},...r.slice(1,-1),r[r.length-1],{...r[r.length-1]}];e.edge.points=i}}t(ke,`prepareEdgeEndpointsForRenderer`);function Ae(e){return new Map(e.map(e=>[e.id,e]))}t(Ae,`buildNodeMap`);function je(e,t){let n=e.parentId,r=null;for(;n;){let e=t.get(n);if(!e?.isGroup)break;r=e.id,n=e.parentId}return r}t(je,`resolveTopLevelGroupId`);function Me(e,t){let n=0,r=e.parentId;for(;r;){let e=t.get(r);if(!e?.isGroup)break;n++,r=e.parentId}return n}t(Me,`groupDepth`);function Ne(e){let t=1/0,n=-1/0,r=1/0,i=-1/0;for(let a of e){let e=a.x,o=a.y;if(typeof e!=`number`||typeof o!=`number`)continue;let s=a.width??0,c=a.height??0;t=Math.min(t,e-s/2),n=Math.max(n,e+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}return t===1/0||r===1/0?null:{minX:t,maxX:n,minY:r,maxY:i}}t(Ne,`boundsForChildren`);function Pe(e,t){let n=e.padding??20;e.x=(t.minX+t.maxX)/2,e.y=(t.minY+t.maxY)/2,e.width=Math.max(0,t.maxX-t.minX)+n,e.height=Math.max(0,t.maxY-t.minY)+n}t(Pe,`applyGroupBounds`);function Fe(e){let t=Ae(e),n=e.filter(e=>e.isGroup&&e.parentId).sort((e,n)=>Me(n,t)-Me(e,t));for(let t of n){let n=Ne(e.filter(e=>e.parentId===t.id));n&&Pe(t,n)}}t(Fe,`recomputeNestedGroupBounds`);function Ie(e,n){let r=e.nodes??[],i=e.edges??[],a=r.filter(e=>!e.isGroup),o=1/0,s=-1/0;for(let e of a){let t=e[n];typeof t==`number`&&(o=Math.min(o,t),s=Math.max(s,t))}if(!Number.isFinite(o)||!Number.isFinite(s))return!1;let c=t(e=>o+s-e,`mirror`);for(let e of r){let t=e[n];typeof t==`number`&&(e[n]=c(t));let r=e.groupTitleRect;r&&(e.groupTitleRect=n===`x`?{...r,left:c(r.right),right:c(r.left)}:{...r,top:c(r.bottom),bottom:c(r.top)})}for(let e of i)for(let t of e.points??[])t[n]=c(t[n]);return!0}t(Ie,`mirrorAxis`);function Le(e){return!(e.nodes??[]).some(e=>!e.isGroup)||Ie(e,`y`)}t(Le,`applyBtDirectionTransform`);function Re(e,t=`LR`){let n=e.nodes??[],r=e.edges??[],i=n.filter(e=>!e.isGroup),a=1/0,o=1/0;for(let e of i){let t=e.x??0,n=e.y??0;t0?Math.max(1,l/u):1;for(let e of i){let t=e.x??0,n=((e.y??0)-o)*d+36,r=t-a;e.x=n,e.y=r}for(let e of r)if(e.points)for(let t of e.points){let e=t.x,n=(t.y-o)*d+36,r=e-a;t.x=n,t.y=r}Fe(n);let f=n.filter(e=>e.isGroup&&!e.parentId);if(f.length===0)return t===`RL`&&Ie(e,`x`),!0;let p=Ae(n),m=new Map;for(let e of n){if(e.isGroup)continue;let t=je(e,p);if(!t)continue;let n=m.get(t)??[];n.push(e),m.set(t,n)}let h=0;for(let e of f){let t=e.padding??0;t>h&&(h=t)}let g=[],_=1/0,v=-1/0;for(let e of f){let t=Ne(m.get(e.id)??[]);t&&(_=Math.min(_,t.minX),v=Math.max(v,t.maxX),g.push({lane:e,contentTop:t.minY,contentBottom:t.maxY,centerY:(t.minY+t.maxY)/2}))}if(_===1/0||v===-1/0)return!0;let y=Math.max(0,v-_)+2*Math.max(h,10),b=36+y,x=(_+v)/2-y/2-36,S=x+b/2,C=Math.max(h,36);g.sort((e,t)=>e.centerY-t.centerY);for(let e=0;ed.cy?g.bottom:g.top,t=d.cx+n;if(t<=g.left+ze||t>=g.right-ze)continue;i={x:t,y:e},a={x:t,y:o.y},c={x:o.x,y:o.y}}else{let e=f.cx>d.cx?g.right:g.left,t=d.cy+n;if(t<=g.top+ze||t>=g.bottom-ze)continue;i={x:e,y:t},a={x:o.x,y:t},c={x:o.x,y:o.y}}let p=v(i,a,ze),m=v(a,c,ze);if(p&&m||!p&&B(i,a,r,[l],1)||!m&&B(a,c,r,[u],1))continue;let _=!p&&ae(i,a,e,t,{epsilon:ze,skipDegenerateOther:!0}),y=!m&&ae(a,c,e,t,{epsilon:ze,skipDegenerateOther:!0});if(!(_||y)){h=p?[a,c]:m?[i,a]:[i,a,c];break}}h&&(t.points=h)}}t(He,`portSwapToLShape`);function Ue(e,n){let r=.001,{realNodeRects:i,labelNodeRects:a}=z(n.values());for(let o of e){if(o.isLayoutOnly)continue;let s=o.points;if(!s||s.length<4)continue;let c=D(s,r);if(c.length<4)continue;let l=c.length-1,u=c[l],d=c[l-1],f=c[l-2],p=u.x-d.x,m=u.y-d.y,h=Math.hypot(p,m);if(h>=10||h0;P={x:f.x,y:M},I={x:e?N.right:N.left,y:M}}if(B(P,I,i,E?[E]:[],-2)||B(P,I,a,[],-2))continue;if(O){let e=n.get(O),t=e?F(e):void 0;if(t&&A(P,t,2))continue}let ee=t((e,t)=>`${e.x.toFixed(3)},${e.y.toFixed(3)}|${t.x.toFixed(3)},${t.y.toFixed(3)}`,`ownSegmentKey`),L=new Set;for(let e=0;e{for(let i of e){if(i===o||i.isLayoutOnly)continue;let e=i.points;if(!(!e||e.length<2))for(let i=0;i=0){let e=c[l-3],t=[O,E].filter(e=>!!e);if(B(e,P,i,t,-2)||R(e,P))continue}let z=[...c.slice(0,l-2),P,I];o.points=z;let te=o.labelNodeId;if(te){let e=n.get(te);if(e){let t=e.width??0,n=e.height??0;if(t>0&&n>0){let i,a,o=-1;for(let e=0;e=t+2||d&&l>=n+2)&&l>o&&(o=l,i=(s.x+c.x)/2,a=(s.y+c.y)/2)}i!==void 0&&a!==void 0&&(e.x=i,e.y=a)}}}}}t(Ue,`collapseShortTerminalStub`);var Y=.001,X=8,Z=T,We=t((e,t)=>y(e,t,Y)||b(e,t,Y),`orthogonallyAligned`);function Ge(e,n){let r=t((e,t)=>{let n=e.x??0,r=e.y??0,i=t.x-n,a=t.y-r,o=(e.width??0)/2,s=(e.height??0)/2;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),{x:n+(a===0?0:s*i/a),y:r+s}):(i<0&&(o=-o),{x:n+o,y:r+(i===0?0:o*a/i)})},`rectIntersect`),i=t((e,t)=>{let i=D(e.points??[]);if(i.length<2)return;let a=t?e.start:e.end,o=a?n.get(a):void 0,s=o?F(o):void 0;if(!o||!a||!s)return;let c=t?i[0]:i[i.length-1],l=t?i[1]:i[i.length-2],u=r(o,c),d=c;if(We(l,u)&&(d=l),y(u,d,Y))return{edge:e,edgeId:String(e.id??``),nodeId:a,atStart:t,orientation:`V`,coord:u.x,min:Math.min(u.y,d.y),max:Math.max(u.y,d.y),boundary:u,railEnd:d,rect:s};if(b(u,d,Y))return{edge:e,edgeId:String(e.id??``),nodeId:a,atStart:t,orientation:`H`,coord:u.y,min:Math.min(u.x,d.x),max:Math.max(u.x,d.x),boundary:u,railEnd:d,rect:s}},`terminalLaneFor`),a=t((e,t)=>Math.max(0,Math.min(e.max,t.max)-Math.max(e.min,t.min)),`projectedOverlapLength`),o=t((e,t)=>e.nodeId!==t.nodeId||e.orientation!==t.orientation?!1:e.orientation===`H`?(Math.abs(e.boundary.x-e.rect.left)<1||Math.abs(e.boundary.x-e.rect.right)<1)&&y(e.boundary,t.boundary,1):(Math.abs(e.boundary.y-e.rect.top)<1||Math.abs(e.boundary.y-e.rect.bottom)<1)&&b(e.boundary,t.boundary,1),`sameTerminalFace`),s=t((e,t)=>e.nodeId!==t.nodeId||e.orientation!==t.orientation?!1:a(e,t)>=X&&Math.abs(e.coord-t.coord)<.5,`exactTerminalLaneConflict`),c=t((e,t)=>{if(e.nodeId!==t.nodeId||e.orientation!==t.orientation||e.orientation!==`H`||e.atStart===t.atStart)return!1;let n=a(e,t);if(n2*r?!1:o(e,t)&&Math.abs(e.coord-t.coord)<16},`nearTerminalLaneConflict`),l=t((e,n)=>{let r=D(e.edge.points??[]);if(r.length<2)return;let i=e.orientation===`V`?{x:e.boundary.x+n,y:e.boundary.y}:{x:e.boundary.x,y:e.boundary.y+n},a=e.orientation===`V`?{x:e.railEnd.x+n,y:e.railEnd.y}:{x:e.railEnd.x,y:e.railEnd.y+n};if(!t(()=>Math.abs(e.boundary.y-e.rect.top)<1||Math.abs(e.boundary.y-e.rect.bottom)<1?b(i,e.boundary,Y)&&i.x>=e.rect.left+1&&i.x<=e.rect.right-1:Math.abs(e.boundary.x-e.rect.left)<1||Math.abs(e.boundary.x-e.rect.right)<1?y(i,e.boundary,Y)&&i.y>=e.rect.top+1&&i.y<=e.rect.bottom-1:!1,`boundaryStaysOnSameFace`)())return;if(e.atStart){let t=r.length>1&&v(r[1],e.railEnd,Y),n=r.slice(t?2:1),o=n[0];return o&&!We(o,a)?void 0:[i,a,...n]}let o=r.length>1&&v(r[r.length-2],e.railEnd,Y),s=r.slice(0,o?-2:-1),c=s[s.length-1];if(!(c&&!We(c,a)))return[...s,a,i]},`shiftedCandidate`),u=t(e=>{let t=e.edge,r=D(t.points??[]);if(r.length!==2)return!1;let i=t.start,a=t.end,o=i?n.get(i):void 0,s=a?n.get(a):void 0;if(!o||!s)return!1;let c=o.x??0,l=o.y??0,u=s.x??0,d=s.y??0,[f,p]=r;return b(f,p,Y)&&Math.abs(l-d)<1&&Math.abs(c-u)>1||y(f,p,Y)&&Math.abs(c-u)<1&&Math.abs(l-d)>1},`laneIsStraightCollinearConnector`),d=[-7,7,-14,14,-21,21];for(let t=0;t<8;t++){let t=e.filter(e=>!e.isLayoutOnly).flatMap(e=>[i(e,!0),i(e,!1)]).filter(e=>!!e),n=!1;for(let e=0;e{let n=u(e),r=u(t);return n===r?Number(!t.atStart)-Number(!e.atStart):Number(n)-Number(r)});for(let e of p){for(let r of d){let a=l(e,r);if(!a)continue;let o=i({...e.edge,points:a},e.atStart);if(!(!o||t.some(t=>t.edge!==e.edge&&(s(o,t)||f&&c(o,t))))){e.edge.points=a,n=!0;break}}if(n)break}}if(!n)return}}t(Ge,`separateSharedRenderedTerminalLanes`);function Ke(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=t((t,n)=>{let a=t.start,o=t.end,s=Z(n);if(s.length!==n.length-1)return!1;let c=[a,o].filter(e=>!!e);for(let e of s)if(B(e.a,e.b,r,c,-2)||B(e.a,e.b,i,[],-2))return!1;for(let n of e){if(n===t||n.isLayoutOnly)continue;let e=n.points;if(!(!e||e.length<2)){for(let t of s)for(let n of Z(D(e)))if(w(t,n,.5)>=X||V(t.a,t.b,n.a,n.b,Y))return!1}}return!0},`candidateIsSafe`),o=t((e,t)=>{if(t+4>=e.length)return;let n=e[t],r=e[t+1],i=e[t+2],a=e[t+3],o=e[t+4],s=x(n,r)&&S(r,i)&&x(i,a)&&S(a,o)&&y(n,a,Y)&&y(n,o,Y)&&y(r,i,Y)&&(r.x-n.x)*(a.x-i.x)<0,c=S(n,r)&&x(r,i)&&S(i,a)&&x(a,o)&&b(n,a,Y)&&b(n,o,Y)&&b(r,i,Y)&&(r.y-n.y)*(a.y-i.y)<0;if(s||c)return D([...e.slice(0,t+1),o,...e.slice(t+5)]);if(t+5>=e.length)return;let l=e[t+5],u=S(n,r)&&x(r,i)&&S(i,a)&&x(a,o)&&S(o,l)&&y(n,o,Y)&&y(n,l,Y)&&y(i,a,Y)&&(i.x-r.x)*(o.x-a.x)<0,d=x(n,r)&&S(r,i)&&x(i,a)&&S(a,o)&&x(o,l)&&b(n,o,Y)&&b(n,l,Y)&&b(i,a,Y)&&(i.y-r.y)*(o.y-a.y)<0;if(!(!u&&!d))return D([...e.slice(0,t+1),l,...e.slice(t+6)])},`withoutDogleg`);for(let t=0;t<8;t++){let t=!1;for(let n of e){if(n.isLayoutOnly)continue;let e=D(n.points??[]);for(let r=0;r<=e.length-5;r++){let i=o(e,r);if(!(!i||!a(n,i))){n.points=i,t=!0;break}}if(t)break}if(!t)return}}t(Ke,`collapseRedundantRectangularDoglegs`);function qe(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t,n)=>D(e===t?n??[]:e.points??[]),`pointsFor`),s=t((e,t)=>{let n=0;for(let r=0;r{let t=Z(e);if(t.length!==3)return;let n=t[1];if(t[0].horizontal!==n.horizontal&&t[2].horizontal!==n.horizontal)return{index:n.index,horizontal:n.horizontal,vertical:n.vertical,segment:n}},`middleRail`),l=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);return r.filter(e=>{if(n.includes(e.id))return!1;let r=e.rect;return t.horizontal?C(t.a.x,t.b.x,r.left,r.right)>=X&&t.a.y>=r.top-2&&t.a.y<=r.bottom+2:C(t.a.y,t.b.y,r.top,r.bottom)>=X&&t.a.x>=r.left-2&&t.a.x<=r.right+2})},`blockingRectsFor`),u=t((e,t,n)=>{let r=e.map(e=>({...e}));if(t.horizontal)r[t.index].y=n,r[t.index+1].y=n;else if(t.vertical)r[t.index].x=n,r[t.index+1].x=n;else return;let i=G(D(r));return Z(i).length===i.length-1?i:void 0},`candidateByMovingRail`),d=t((e,t,n)=>{let c=[e.start,e.end].filter(e=>!!e),l=Z(t);if(l.length!==t.length-1)return!1;for(let e of l)if(B(e.a,e.b,r,c,-2)||B(e.a,e.b,i,[],-2))return!1;for(let t of a)if(t!==e){for(let e of l)for(let n of Z(o(t)))if(w(e,n,.5)>=X)return!1}return s(e,t)<=n},`candidateIsSafe`);for(let e=0;e<8;e++){let e=s(),t=!1;for(let n of a){let r=o(n),i=c(r);if(!i)continue;let a=l(n,i.segment);if(a.length===0)continue;let s=i.horizontal?[Math.min(...a.map(e=>e.rect.top))-20,Math.max(...a.map(e=>e.rect.bottom))+20]:[Math.min(...a.map(e=>e.rect.left))-20,Math.max(...a.map(e=>e.rect.right))+20];for(let a of s){let o=u(r,i.segment,a);if(!(!o||!d(n,o,e))){n.points=o,t=!0;break}}if(t)break}if(!t)return}}t(qe,`liftObstacleHuggingSameSideRails`);function Je(e,n){let r=t(e=>{let t=e.groupTitleRect;if(!(!t||typeof t.left!=`number`||typeof t.right!=`number`||typeof t.top!=`number`||typeof t.bottom!=`number`||!Number.isFinite(t.left)||!Number.isFinite(t.right)||!Number.isFinite(t.top)||!Number.isFinite(t.bottom)||t.right<=t.left||t.bottom<=t.top))return{left:t.left,right:t.right,top:t.top,bottom:t.bottom}},`validTitleRect`),i=t(e=>{if(!e.isGroup||e.parentId)return;let t=e.direction,n=typeof t==`string`?t.toUpperCase():``;if(n===`LR`||n===`RL`||n===`BT`)return;let i=r(e),a=e.y,o=e.height;if(!i||typeof a!=`number`||typeof o!=`number`||!Number.isFinite(a)||!Number.isFinite(o)||o<=0)return;let s=i.right-i.left,c=i.bottom-i.top;if(!(c<=0||s{if(!e.horizontal)return!1;let n=e.a.y;return n<=t.top+Y||n>=t.bottom-Y?!1:C(e.a.x,e.b.x,t.left,t.right)>=X},`horizontalSegmentIntersectsTitle`),o=[...n.values()].map(i).filter(e=>!!e);if(o.length===0)return;let s=0;for(let t of e){if(t.isLayoutOnly)continue;let e=D(t.points??[]);for(let t of Z(e))for(let e of o)a(t,e.rect)&&(s=Math.max(s,e.rect.bottom-t.a.y+4))}if(!(s<=Y))for(let e of o){let t=e.node.y,n=e.node.height;typeof t!=`number`||typeof n!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||n<=0||(e.node.y=t-s/2,e.node.height=n+s,e.node.groupTitleRect={...e.rect,top:e.rect.top-s,bottom:e.rect.bottom-s})}}t(Je,`liftTopLaneTitleBandsAboveRails`);function Ye(e,n){let r=t(e=>{let t=e.groupTitleRect;if(!(!t||typeof t.left!=`number`||typeof t.right!=`number`||typeof t.top!=`number`||typeof t.bottom!=`number`||!Number.isFinite(t.left)||!Number.isFinite(t.right)||!Number.isFinite(t.top)||!Number.isFinite(t.bottom)||t.right<=t.left||t.bottom<=t.top))return{left:t.left,right:t.right,top:t.top,bottom:t.bottom}},`validTitleRect`),i=t(e=>{if(!e.isGroup||e.parentId||e.direction!==`LR`)return;let t=r(e),n=e.x,i=e.width;if(!t||typeof n!=`number`||typeof i!=`number`||!Number.isFinite(n)||!Number.isFinite(i)||i<=0)return;let a=t.right-t.left,o=t.bottom-t.top;if(!(a<=0||o{if(!e.vertical)return!1;let n=e.a.x;return n<=t.left+Y||n>=t.right-Y?!1:C(e.a.y,e.b.y,t.top,t.bottom)>=X},`verticalSegmentIntersectsTitle`),o=t((e,t)=>{if(!e.horizontal)return!1;let n=e.a.y;return n<=t.top+Y||n>=t.bottom-Y?!1:C(e.a.x,e.b.x,t.left,t.right)>=X},`horizontalSegmentIntersectsTitle`),s=[...n.values()].map(i).filter(e=>!!e);if(s.length===0)return;let c=0;for(let t of e){if(t.isLayoutOnly)continue;let e=D(t.points??[]);for(let t of Z(e))for(let e of s)if(a(t,e.rect))c=Math.max(c,e.rect.right-t.a.x+4);else if(o(t,e.rect)){let n=Math.min(t.a.x,t.b.x);c=Math.max(c,e.rect.right-n+4)}}if(!(c<=Y))for(let e of s){let t=e.node.x,n=e.node.width;typeof t!=`number`||typeof n!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||n<=0||(e.node.x=t-c/2,e.node.width=n+c,e.node.groupTitleRect={...e.rect,left:e.rect.left-c,right:e.rect.right-c})}}t(Ye,`shiftLeftLaneTitleBandsLeftOfRails`);function Xe(e,n){let{realNodeRects:r}=z(n.values()),i=e.filter(e=>!e.isLayoutOnly),a=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),o=t((e=new Map)=>{let t=0;for(let n=0;ni.reduce((t,n)=>t+E(a(n,e)),0),`totalBends`),c=t(e=>{let t=a(e);if(t.length<4)return;let n=t[t.length-2],r=t[t.length-1];if(!(!x(n,r,Y)&&!S(n,r,Y)))return{tailStart:n,terminal:r}},`terminalTailFor`),l=t((e,t)=>{let n=a(e);if(n.length<3)return;let r=n[0],i=n[1],o;if(x(r,i,Y))o={x:i.x,y:t.tailStart.y};else if(S(r,i,Y))o={x:t.tailStart.x,y:i.y};else return;let s=G(D([r,i,o,t.tailStart,t.terminal]));return Z(s).length===s.length-1?s:void 0},`candidateWithDestinationTail`),u=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);for(let e of Z(t))if(B(e.a,e.b,r,n,-2))return!0;return!1},`pathHasNodeHit`),d=t((e,t,n)=>{for(let r of i)if(r!==e){for(let e of Z(t))for(let t of Z(a(r,n)))if(w(e,t,.5)>=X)return!0}return!1},`pathHasSharedTrack`),f=t((e,t,n)=>!u(e,t)&&!d(e,t,n),`candidateIsSafe`),p=t(()=>{let e=new Map;for(let t of i){let r=t.end;if(!r||!n.has(r)||a(t).length<4)continue;let i=e.get(r)??[];i.push(t),e.set(r,i)}return e},`edgesByDestination`);for(let e=0;e<4;e++){let e=o();if(e===0)return;let t=s(),n,r=e,i=t;for(let t of p().values())for(let a=0;a=e||y>r||y===r&&b>=i||(n=v,r=y,i=b)}if(!n)return;for(let[e,t]of n)e.points=t}}t(Xe,`swapDestinationTerminalTailsToReduceCrossings`);function Ze(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),s=t((e=new Map)=>{let t=0;for(let n=0;na.reduce((t,n)=>t+E(o(n,e)),0),`totalBends`),l=t(e=>{let t=e.start,r=e.end,i=t?n.get(t):void 0,a=r?n.get(r):void 0,o=i?F(i):void 0,s=a?F(a):void 0;return o&&s?{src:o,dst:s}:void 0},`endpointRectsFor`),u=t((e,t,n)=>{if(n.index<=0||n.index+1>=t.length-1)return;let r=l(e);if(r){if(n.vertical){let i=n.a.x,a=Math.min(r.src.left,r.dst.left),o=Math.max(r.src.right,r.dst.right),s=io+Y?`right`:void 0;return s?{edge:e,points:t,segmentIndex:n.index,axis:`vertical`,side:s,coord:i,min:Math.min(n.a.y,n.b.y),max:Math.max(n.a.y,n.b.y)}:void 0}if(n.horizontal){let i=n.a.y,a=Math.min(r.src.top,r.dst.top),o=Math.max(r.src.bottom,r.dst.bottom),s=io+Y?`bottom`:void 0;return s?{edge:e,points:t,segmentIndex:n.index,axis:`horizontal`,side:s,coord:i,min:Math.min(n.a.x,n.b.x),max:Math.max(n.a.x,n.b.x)}:void 0}}},`externalRailForSegment`),d=t(()=>{let e=[];for(let t of a){let n=o(t);for(let r of Z(n)){let i=u(t,n,r);i&&e.push(i)}}return e},`collectExternalRails`),f=t((e,t)=>e.edge!==t.edge&&e.axis===t.axis&&e.side===t.side&&C(e.min,e.max,t.min,t.max)>=X,`railsInteract`),p=t(e=>{let t=[],n=new Set;for(let r of e){if(n.has(r))continue;let i=[r],a=[];for(n.add(r);i.length>0;){let t=i.pop();a.push(t);for(let r of e)!n.has(r)&&f(t,r)&&(n.add(r),i.push(r))}a.length>1&&t.push(a)}return t},`connectedComponents`),m=t(e=>{let t=[];for(let n of e)t.some(e=>Math.abs(e-n.coord){let n=e.map(e=>e.coord),r=m(e),i=[];if(e.length<=6){let a=Array(r.length).fill(!1),o=[],s=t(()=>{if(o.length===e.length){o.some((e,t)=>Math.abs(e-n[t])>=Y)&&i.push([...o]);return}for(let[e,t]of r.entries())a[e]||(a[e]=!0,o.push(t),s(),o.pop(),a[e]=!1)},`visit`);return s(),i}for(let e=0;e{let n=new Map;for(let[r,i]of e.entries()){let e=t[r],a=n.get(i.edge)??i.points.map(e=>({x:e.x,y:e.y}));i.axis===`vertical`?(a[i.segmentIndex].x=e,a[i.segmentIndex+1].x=e):(a[i.segmentIndex].y=e,a[i.segmentIndex+1].y=e),n.set(i.edge,a)}let r=new Map;for(let[e,t]of n){let n=G(D(t));if(Z(n).length!==n.length-1)return;r.set(e,n)}return r},`replacementsForAssignment`),_=t(e=>{for(let[t,n]of e){let e=[t.start,t.end].filter(e=>!!e);for(let t of Z(n))if(B(t.a,t.b,r,e,-2)||B(t.a,t.b,i,[],-2))return!1}for(let t=0;t=X)return!1}}return!0},`candidateIsSafe`);for(let e=0;e<4;e++){let e=s();if(e===0)return;let t,n=e,r=c(),i=1/0;for(let a of p(d()))for(let o of h(a)){let l=g(a,o);if(!l||!_(l))continue;let u=s(l);if(u>=e)continue;let d=c(l),f=a.reduce((e,t,n)=>e+Math.abs(o[n]-t.coord),0);u>n||u===n&&(d>r||d===r&&f>=i)||(t=l,n=u,r=d,i=f)}if(!t)return;for(let[e,n]of t)e.points=n}}t(Ze,`reassignCrossingExternalRailChannels`);function Qe(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t,n)=>D(e===t?n??[]:e.points??[]),`pointsFor`),s=t(e=>Z(e).reduce((e,t)=>{let n=t.a.x-t.b.x,r=t.a.y-t.b.y;return e+Math.hypot(n,r)},0),`pathLength`),c=t((e,t)=>{let n=0;for(let r=0;r{if(e.horizontal){let n=e.a.y;return(Math.abs(n-t.top)<1||Math.abs(n-t.bottom)<1)&&C(e.a.x,e.b.x,t.left,t.right)>=X}if(e.vertical){let n=e.a.x;return(Math.abs(n-t.left)<1||Math.abs(n-t.right)<1)&&C(e.a.y,e.b.y,t.top,t.bottom)>=X}return!1},`segmentRunsAlongRectBorder`),u=t(e=>{let t=[e.start,e.end].filter(e=>!!e),r=[];for(let e of t){let t=n.get(e),i=t?F(t):void 0;i&&r.push(i)}return r},`endpointRectsFor`),d=t((e,t)=>{if(t+3>=e.length)return[];let n=e[t],r=e[t+1],i=e[t+2],a=e[t+3],o=x(n,r,Y)&&S(r,i,Y)&&x(i,a,Y),s=S(n,r,Y)&&x(r,i,Y)&&S(i,a,Y);if(!o&&!s||!(o?Math.sign(r.x-n.x)!==Math.sign(a.x-i.x):Math.sign(r.y-n.y)!==Math.sign(a.y-i.y)))return[];let c=y(n,a,Y)||b(n,a,Y)?[]:[{x:n.x,y:a.y},{x:a.x,y:n.y}],l=c.length===0?[[...e.slice(0,t+1),...e.slice(t+3)]]:c.map(n=>[...e.slice(0,t+1),n,...e.slice(t+3)]),u=new Set;return l.map(e=>G(D(e))).filter(e=>{if(Z(e).length!==e.length-1||!e.some(e=>v(e,a,Y)))return!1;let t=e.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return!u.has(t)&&(u.add(t),!0)})},`shortcutCandidatesAt`),f=t((e,t,n)=>{let s=[e.start,e.end].filter(e=>!!e),d=u(e);for(let e of Z(t))if(B(e.a,e.b,r,s,-2)||B(e.a,e.b,i,[],-2)||d.some(t=>l(e,t)))return!1;for(let n of a)if(n!==e){for(let e of Z(t))for(let t of Z(o(n)))if(w(e,t,.5)>=X)return!1}return c(e,t)<=n},`candidateIsSafe`);for(let e=0;e<8;e++){let e=c(),t,n,r=e,i=1/0,l=1/0;for(let u of a){let a=o(u),p=E(a,Y),m=s(a);for(let o=0;o<=a.length-4;o++)for(let h of d(a,o)){let a=E(h,Y),o=s(h);if(!(ar||d===r&&(a>i||a===i&&o>=l)||(t=u,n=h,r=d,i=a,l=o)}}if(!t||!n)return;t.points=n}}t(Qe,`shortcutRedundantOrthogonalJogs`);function $e(e,n){let r=[];for(let e of n.values()){if(e.isGroup||e.isEdgeLabel)continue;let t=e.x??0,n=e.y??0,i=F(e);i&&r.push({id:String(e.id??``),cx:t,cy:n,rect:i})}if(r.length===0)return;let i=new Map(r.map(e=>[e.id,e])),a=r.map(e=>({id:e.id,rect:e.rect})),o=[`top`,`bottom`,`left`,`right`],s={top:Math.min(...r.map(e=>e.rect.top))-20,bottom:Math.max(...r.map(e=>e.rect.bottom))+20,left:Math.min(...r.map(e=>e.rect.left))-20,right:Math.max(...r.map(e=>e.rect.right))+20},c=e.filter(e=>!e.isLayoutOnly),l=new Map(c.map((e,t)=>[e,t])),u=t(e=>{let t=e===`left`||e===`top`?-1:1,n=[];for(let r=0;r<=2;r++)n.push(s[e]+t*20*r);return n},`outwardTracksForSide`),d=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),f=t((e,t)=>{let n=0;for(let r of e)for(let e of t)V(r.a,r.b,e.a,e.b,Y)&&n++;return n},`crossingCountBetweenSegments`),p=t((e,t)=>f(Z(e),Z(t)),`crossingCountBetweenPaths`),m=t((e=new Map)=>{let n=0,r=[],i=new Set,a=[],o=t(e=>{i.has(e)||(i.add(e),a.push(e))},`addEdge`);for(let t=0;t0&&(n+=l,r.push({first:i,second:t,count:l}),o(i),o(t))}}return a.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),{count:n,pairs:r,edgeSet:i,edges:a}},`crossingSnapshot`),h=t((e,t)=>{let n=new Set(t.keys());if(n.size===0)return e.count;let r=0;for(let t of e.pairs)(n.has(t.first)||n.has(t.second))&&(r+=t.count);let i=0;for(let e=0;e{let t=new Map;for(let n of e.pairs){let e=t.get(n.first)??new Set;e.add(n.second),t.set(n.first,e);let r=t.get(n.second)??new Set;r.add(n.first),t.set(n.second,r)}let n=[],r=new Set;for(let i of e.edges){if(r.has(i))continue;let e=[i],a=[];for(r.add(i);e.length>0;){let n=e.pop();a.push(n);for(let i of t.get(n)??[])r.has(i)||(r.add(i),e.push(i))}a.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),a.length>1&&n.push(a)}return n},`crossingComponents`),_=t(e=>[e.start,e.end].filter(e=>!!e),`endpointIdsFor`),v=t(e=>{let t=[];for(let n of g(e)){let e=new Set(n),r=new Set(n.flatMap(e=>_(e))),i=[...n];for(let t of c)e.has(t)||_(t).some(e=>r.has(e))&&i.push(t);i.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),t.push(i)}return t},`pairSearchGroups`),y=t((e,t,n)=>h(e,new Map([[t,n]])),`crossingCountWithSingleReplacement`),b=t(e=>{let t=new Map;for(let n of e.pairs)t.set(n.first,(t.get(n.first)??0)+n.count),t.set(n.second,(t.get(n.second)??0)+n.count);return t},`currentCrossingsByEdge`),C=t(e=>e.slice(1).reduce((t,n,r)=>{let i=e[r];return t+Math.abs(n.x-i.x)+Math.abs(n.y-i.y)},0),`pathLength`),T=t((e=new Map)=>c.reduce((t,n)=>t+E(d(n,e)),0),`totalBends`),O=t((e=new Map)=>c.reduce((t,n)=>t+C(d(n,e)),0),`totalLength`),k=t((e,t,n=new Map)=>{let r=Z(t);for(let t of c)if(t!==e){for(let e of r)for(let r of Z(d(t,n)))if(w(e,r,.5)>=X)return!0}return!1},`pathHasSegmentConflict`),A=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);for(let e of Z(t))if(B(e.a,e.b,a,n,-2))return!0;return!1},`pathHitsNode`),j=t((e,t)=>{let n=G(D(t));Z(n).length===n.length-1&&e.push(n)},`pushOrthogonalCandidate`),M=t(e=>e===`left`||e===`right`,`sideIsHorizontal`),N=t((e,t,n)=>{switch(t){case`left`:return Math.min(e.x,n.x)-20;case`right`:return Math.max(e.x,n.x)+20;case`top`:return Math.min(e.y,n.y)-20;case`bottom`:return Math.max(e.y,n.y)+20}},`localTrackForSameSide`),P=t((e,t,n,r)=>{let i=n===`left`||n===`top`?-1:1,a=[N(t,n,r),s[n]];for(let o of a)for(let a=0;a<=2;a++)j(e,L(t,n,r,o+i*20*a))},`addSameSideCandidates`),R=t((e,t,n,r,i)=>{for(let a of u(n))for(let n of u(i))j(e,[t,{x:a,y:t.y},{x:a,y:n},{x:r.x,y:n},r])},`addHorizontalToVerticalCandidates`),z=t((e,t,n,r,i)=>{for(let a of u(n))for(let n of u(i))j(e,[t,{x:t.x,y:a},{x:n,y:a},{x:n,y:r.y},r])},`addVerticalToHorizontalCandidates`),te=t((e,t,n,r,i)=>{let a=[...u(`top`),...u(`bottom`)];for(let o of u(n))for(let n of u(i))for(let i of a)j(e,[t,{x:o,y:t.y},{x:o,y:i},{x:n,y:i},{x:n,y:r.y},r])},`addHorizontalPairCandidates`),ne=t((e,t,n,r,i)=>{let a=[...u(`left`),...u(`right`)];for(let o of u(n))for(let n of u(i))for(let i of a)j(e,[t,{x:t.x,y:o},{x:i,y:o},{x:i,y:n},{x:r.x,y:n},r])},`addVerticalPairCandidates`),re=t(e=>{let t=new Set;return e.map(e=>D(e)).filter(e=>{let n=e.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return t.has(n)||e.length<2?!1:(t.add(n),!0)})},`dedupeCandidatePaths`),ie=t((e,t,n,r)=>{let i=[],a=ee(e,t,n,r,20,Y);a&&j(i,a),t===r&&P(i,e,t,n);let o=M(t),s=M(r);return o&&!s?R(i,e,t,n,r):!o&&s?z(i,e,t,n,r):o?te(i,e,t,n,r):ne(i,e,t,n,r),re(i)},`buildCandidatesForSides`),ae=t((e,t,n,r)=>{let i=[...u(`left`),...u(`right`)],a=[...u(`top`),...u(`bottom`)];for(let s of o){let o=I(r,s),c=s===`top`||s===`bottom`?u(s):a;for(let r of i){j(e,[t,n,{x:r,y:n.y},{x:r,y:o.y},o]);for(let i of c)j(e,[t,n,{x:r,y:n.y},{x:r,y:i},{x:o.x,y:i},o])}}},`addVerticalDepartureOuterTrackCandidates`),oe=t((e,t,n,r)=>{let i=[...u(`left`),...u(`right`)],a=[...u(`top`),...u(`bottom`)];for(let s of o){let o=I(r,s),c=s===`left`||s===`right`?u(s):i;for(let r of a){j(e,[t,n,{x:n.x,y:r},{x:o.x,y:r},o]);for(let i of c)j(e,[t,n,{x:n.x,y:r},{x:i,y:r},{x:i,y:o.y},o])}}},`addHorizontalDepartureOuterTrackCandidates`),H=t(e=>{let t=e.start,n=e.end,r=n?i.get(n):void 0;if(!t||!r)return[];let a=D(e.points??[]);if(a.length<4)return[];let o=a[0],s=a[1],c=[];return S(o,s,Y)?ae(c,o,s,r):x(o,s,Y)&&oe(c,o,s,r),c},`terminalPreservingOuterTrackCandidates`),U=t(e=>{let t=e.start,n=e.end,r=t?i.get(t):void 0,a=n?i.get(n):void 0;if(!r||!a)return[];let s=[];for(let e of o){let t=I(r,e);for(let n of o)s.push(...ie(t,e,I(a,n),n))}return s.push(...H(e)),s},`candidatePathsFor`),W=t(()=>new Map(c.map(e=>[e,Z(d(e))])),`currentSegmentsByEdge`),K=t((e,t,n)=>{let r=new Set;for(let i of c){if(i===e)continue;let a=n.get(i)??Z(d(i));t.some(e=>a.some(t=>w(e,t,.5)>=X))&&r.add(i)}return r},`sharedTrackConflictsFor`),se=t((e,t,n,r)=>{let i=new Set;return U(e).map(e=>G(D(e))).filter(t=>{if(A(e,t))return!1;let n=t.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return i.has(n)||t.length<2?!1:(i.add(n),!0)}).map(i=>{let a=Z(i),o=0;for(let t of c)t!==e&&(o+=f(a,n.get(t)??Z(d(t))));return{candidate:i,candidateSegments:a,crossings:t.count-(r.get(e)??0)+o,bends:E(i,Y),totalBends:E(i),length:C(i)}}).filter(({crossings:e})=>e<=t.count).sort((e,t)=>e.crossings-t.crossings||e.bends-t.bends||e.length-t.length).slice(0,48).map(t=>({path:t.candidate,segments:t.candidateSegments,sharedTrackConflicts:K(e,t.candidateSegments,n),totalBends:t.totalBends,length:t.length}))},`pairCandidatesFor`),ce=t((e,t,n,r,i,a)=>{let o=0;for(let n of e.pairs)(n.first===t||n.second===t||n.first===r||n.second===r)&&(o+=n.count);let s=f(n.segments,i.segments);for(let e of c){if(e===t||e===r)continue;let o=a.get(e)??Z(d(e));s+=f(n.segments,o)+f(i.segments,o)}return e.count-o+s},`pairCrossingCount`),le=t((e,t)=>{for(let n of e.sharedTrackConflicts)if(n!==t)return!1;return!0},`conflictsOnlyWith`),ue=t((e,t)=>e.segments.some(e=>t.segments.some(t=>w(e,t,.5)>=X)),`candidatesShareTrack`),de=t((e,t,n,r)=>le(t,n.edge)&&le(r,e.edge)&&!ue(t,r),`pairCandidatesAreCompatible`),q=t((e,t,n,r,i)=>{let a=ce(e.current,t.edge,n,r.edge,i,e.baseSegments);if(!(a>=e.current.count))return{replacements:new Map([[t.edge,n.path],[r.edge,i.path]]),crossings:a,bends:e.currentBends-(e.baseBendsByEdge.get(t.edge)??0)-(e.baseBendsByEdge.get(r.edge)??0)+n.totalBends+i.totalBends,length:e.currentLength-(e.baseLengthByEdge.get(t.edge)??0)-(e.baseLengthByEdge.get(r.edge)??0)+n.length+i.length}},`scorePairReplacement`),J=t((e,t)=>e.crossings{let i=r;for(let r of t.candidates)for(let a of n.candidates){if(!de(t,r,n,a))continue;let o=q(e,t,r,n,a);o&&J(o,i)&&(i=o)}return i},`bestScoreForOptionPair`),pe=t(e=>{let t=T(),n=O(),r=W(),i=b(e),a=new Map(c.map(e=>[e,E(d(e))])),o=new Map(c.map(e=>[e,C(d(e))])),s=new Map,l=v(e);for(let t of l)for(let n of t){if(s.has(n))continue;let t=se(n,e,r,i);t.length>0&&s.set(n,{edge:n,candidates:t})}let u={replacements:new Map,crossings:e.count,bends:t,length:n},f={current:e,currentBends:t,currentLength:n,baseBendsByEdge:a,baseLengthByEdge:o,baseSegments:r};for(let t of l){let n=new Set(t.filter(t=>e.edgeSet.has(t))),r=t.map(e=>s.get(e)).filter(e=>!!e);for(let e=0;e0?u.replacements:void 0},`bestPairedReplacement`);for(let e=0;e<4;e++){let e=m(),t=e.count;if(t===0)return;let n,r,i=t,a=1/0;for(let o of e.edges){let s=E(d(o),Y);for(let c of U(o)){let l=A(o,c),u=!l&&k(o,c),d=y(e,o,c),f=E(c,Y);l||u||(di||d===i&&f>=a||(n=o,r=c,i=d,a=f))}}if(n&&r){n.points=r;continue}let o=pe(e);if(!o)return;for(let[e,t]of o)e.points=t}}t($e,`resolveRenderedOrthogonalCrossings`);var et=.001,tt=8;function nt(e,n){let{nodeInfoById:r,realNodeRects:i}=R(n),a=[`top`,`bottom`,`left`,`right`],o={top:Math.min(...i.map(e=>e.rect.top))-20,bottom:Math.max(...i.map(e=>e.rect.bottom))+20,left:Math.min(...i.map(e=>e.rect.left))-20,right:Math.max(...i.map(e=>e.rect.right))+20},s=t((e,t,n,r)=>{let i=[],a=ee(e,t,n,r,20,et);return a&&i.push(a),t===r&&i.push(L(e,t,n,o[t])),i},`buildOrthogonalPathCandidates`),c=t((e,t)=>{for(let n=0;n{let i=0,a=T(t,et),o=n.start,s=n.end;for(let t of e){if(t===n||t.isLayoutOnly)continue;let e=t.start,c=t.end;if(!r&&o&&s&&(e===o||e===s||c===o||c===s))continue;let l=t.points;if(!(!l||l.length<2))for(let e of a)for(let t of T(l,et)){if(re(e.a,e.b,t.a,t.b,et,et)){i++;continue}w(e,t,et)>=tt&&i++}}return i},`pathConflictCount`),u=t((e,t)=>{let n=Math.abs(e.y-t.rect.top),r=Math.abs(e.y-t.rect.bottom),i=Math.abs(e.x-t.rect.left),a=Math.abs(e.x-t.rect.right),o=`top`,s=n;return r{let r=d.get(e)??[];r.push({side:t,edgeId:n}),d.set(e,r)},`addFaceClaim`);for(let t of e){if(t.isLayoutOnly)continue;let e=t.points??[];if(e.length<1)continue;let n=t.id??``,i=t.start,a=t.end;if(i){let t=r.get(i);t&&f(i,u(e[0],t),n)}if(a){let t=r.get(a);t&&f(a,u(e[e.length-1],t),n)}}let p=t((e,t,n)=>d.get(e)?.some(e=>e.edgeId!==n&&e.side===t)??!1,`faceIsClaimed`);for(let t of e){if(t.isLayoutOnly)continue;let e=t.points;if(!e||e.length<2)continue;let n=E(e,et);if(n<4)continue;let i=t.start,o=t.end;if(!i||!o)continue;let m=r.get(i),h=r.get(o);if(!m||!h)continue;let g=t.id??``,_=l(e,t,!0),v=l(e,t),y,b=_,x=n;for(let e of a){if(p(i,e,g))continue;let n=I(m,e);for(let r of a){if(p(o,r,g))continue;let a=I(h,r);for(let u of s(n,e,a,r)){if(c(u,[i,o]))continue;let e=E(u,et);if(_>0){let n=l(u,t,!0);if(n>b||n===b&&e>=x)continue;b=n,x=e,y=u;continue}l(u,t)>v||ee.edgeId!==g));let n=d.get(o);n&&d.set(o,n.filter(e=>e.edgeId!==g)),f(i,u(y[0],m),g),f(o,u(y[y.length-1],h),g)}}}t(nt,`simplifyDetouredEdges`);var Q=.001,rt=10,it=7;function at(e,t){let n=t?0:e.length-1,r=t?1:-1,i=e[n],a=e[n+r];if(!i||!a)return;let o=a.x-i.x,s=a.y-i.y;if(!(Math.abs(o)+Math.abs(s)t&&M(e,ot(t)))}t(st,`labelOverlapsOwnMarker`);function ct(e,n){let r=[];for(let t of e){if(t.isLayoutOnly)continue;let e=t.points;if(!(!e||e.length<2))for(let n=0;n{let n=N(t,3);for(let{nodeId:t,rect:r}of i)if(t!==e&&M(n,r))return!0;return!1},`labelOverlapsForeignNode`),s=t((e,t)=>{let n=N(t,3);for(let t of r)if(t.edgeId!==e&&k(t.p1,t.p2,n))return!0;return!1},`labelOverlapsForeignEdge`),c=t((e,t,n)=>o(e,n)||s(t,n),`labelOverlapsAnything`),l=[],u=t(e=>{for(let{id:t,rect:n}of a)if(j(n,e))return t},`findContainingLane`),d=t((e,t)=>l.some(n=>n.labelId!==e&&M(t,n.rect)),`overlapsPlacedLabel`);for(let r of e){if(r.isLayoutOnly)continue;let e=r.labelNodeId;if(!e)continue;let i=n.get(e);if(!i)continue;let f=r.points;if(!f||f.length<2)continue;let p=i.width??0,m=i.height??0;if(p<=0||m<=0)continue;let h=[];for(let e=0;e=Q&&i>=Q||h.push({idx:e,length:r+i,orientation:r>=Q?`horizontal`:`vertical`,midX:(t.x+n.x)/2,midY:(t.y+n.y)/2})}if(h.length===0)continue;let g=h.length>=3?h.filter(e=>e.idx>0&&e.idx0?g:h,v=p>=m?`horizontal`:`vertical`,y=t(e=>[...e].sort((e,t)=>{let n=e.orientation===v;if(n!==(t.orientation===v))return n?-1:1;let r=e.length>=(e.orientation===`horizontal`?p:m)+2;return r===t.length>=(t.orientation===`horizontal`?p:m)+2?t.length-e.length:r?-1:1}),`rankSegments`),b=h[0],x=h[h.length-1],S=[.5,.25,.75,.05,.95,.15,.85,.1,.9],C=t((e,t)=>{let n=f[e.idx],r=f[e.idx+1];return{midX:n.x+(r.x-n.x)*t,midY:n.y+(r.y-n.y)*t}},`anchorAtT`),w=t((e,t,n)=>Math.min(n,Math.max(t,e)),`clamp`),T=t((e,t)=>e.midX>=t.left-Q&&e.midX<=t.right+Q&&e.midY>=t.top-Q&&e.midY<=t.bottom+Q,`pointInsideRectInclusive`),E=t(e=>{let t=P(e.midX,e.midY,p,m),n=u(t);if(n)return{laneId:n,anchor:e,rect:t};let r=a.find(({rect:t})=>T(e,t));if(!r)return;let i=r.rect.left+p/2+1,o=r.rect.right-p/2-1,s=r.rect.top+m/2+1,c=r.rect.bottom-m/2-1;if(i>o||s>c)return;let l={midX:w(e.midX,i,o),midY:w(e.midY,s,c)},d=P(l.midX,l.midY,p,m);return T(e,d)?{laneId:r.id,anchor:l,rect:d}:void 0},`placementForAnchor`),D=t((e,t,n)=>e.orientation===`horizontal`?Math.abs(t.midX-n.x):Math.abs(t.midY-n.y),`distanceAlongSegment`),O=t((e,t)=>{let n=(e.orientation===`horizontal`?p/2:m/2)+12;if(e===b){let r=f[e.idx];if(D(e,t,r)+Q{let n=y(t);for(let t of n)for(let n of S){let i=C(t,n);if(!O(t,i))continue;let a=E(i);if(a&&!st(a.rect,f)&&!d(e,a.rect)&&!c(e,r.id,a.rect))return{laneId:a.laneId,anchor:a.anchor}}},`tryPool`),A=t((t,n,i=!1)=>{let a=y(t);for(let t of a){let a={midX:t.midX,midY:t.midY};if(n&&!O(t,a))continue;let c=E(a);if(c&&!st(c.rect,f)&&!d(e,c.rect)&&!o(e,c.rect)&&(i||!s(r.id,c.rect)))return{laneId:c.laneId,anchor:c.anchor}}},`findLaneContainingFallback`),j=k(_)??(_.lengtht.labelId===e);n>=0?l[n]={labelId:e,rect:t}:l.push({labelId:e,rect:t})}}}t(ct,`anchorLabelsToPolyline`);var lt=1e-6,ut=4,dt=3;function ft(e,t){return e{let s=ft(r,i),c=0,l=t(e=>{if(!e)return;let t=a.get(e);if(!t)return;let n=o===`x`?t.w/2:t.h/2;n>c&&(c=n)},`consider`);l(n.labelNodeId);for(let t of e){if(t===n||t.isLayoutOnly)continue;let e=t.start,r=t.end;!e||!r||ft(e,r)===s&&l(t.labelNodeId)}return c>0?c+dt:0},`labelClearanceFor`);for(let t of e){if(t.isLayoutOnly)continue;let n=t.points;if(!O(n,lt))continue;let a=ne(t,r,lt);if(!a)continue;let{srcId:s,dstId:c,srcInfo:l,dstInfo:u,collinearX:d,collinearY:f}=a;if(d===f)continue;let p,m;if(d){let e=u.cy>l.cy;p={x:l.cx,y:e?l.rect.bottom:l.rect.top},m={x:u.cx,y:e?u.rect.top:u.rect.bottom}}else{let e=u.cx>l.cx;p={x:e?l.rect.right:l.rect.left,y:l.cy},m={x:e?u.rect.left:u.rect.right,y:u.cy}}if(B(p,m,i,[s,c],1))continue;let h=o(t,s,c,d?`x`:`y`),g=h>ut?h:ut,_=[0,g,-g];for(let n of _){let r={...p},a={...m};if(d){if(r.x+=n,a.x+=n,r.x<=l.rect.left||r.x>=l.rect.right||a.x<=u.rect.left||a.x>=u.rect.right)continue}else if(r.y+=n,a.y+=n,r.y<=l.rect.top||r.y>=l.rect.bottom||a.y<=u.rect.top||a.y>=u.rect.bottom)continue;if(!B(r,a,i,[s,c],1)&&!ae(r,a,e,t,{epsilon:lt})){t.points=[r,a];break}}}}t(pt,`straightenCollinearSiblingDetours`);function mt(e,n){let r=.001,{realNodeRects:i,labelNodeRects:a}=z(n.values()),o=t((e,t)=>T(t,r).map(n=>({...n,edge:e,interior:n.index>=1&&n.index<=t.length-3})),`segmentsFor`),s=t(()=>{let t=[];for(let n of e){if(n.isLayoutOnly)continue;let e=n.points;!e||e.length<2||t.push(...o(n,D(e)))}return t},`allSegments`),c=t((e,t)=>e.horizontal&&t.horizontal?C(e.a.x,e.b.x,t.a.x,t.b.x)>=8&&Math.abs(e.a.y-t.a.y)<7:e.vertical&&t.vertical?C(e.a.y,e.b.y,t.a.y,t.b.y)>=8&&Math.abs(e.a.x-t.a.x)<7:!1,`hasCrowdedParallelTrack`),l=t((t,n)=>{let s=t.start,l=t.end,u=o(t,n);if(u.length!==n.length-1)return!1;let d=[s,l].filter(e=>!!e),f=t.labelNodeId?[t.labelNodeId]:[];for(let e of u)if(B(e.a,e.b,i,d,-2)||B(e.a,e.b,a,f,-2))return!1;for(let n of e){if(n===t||n.isLayoutOnly)continue;let e=n.points;if(!(!e||e.length<2)){for(let t of u)for(let i of o(n,D(e)))if(c(t,i)||V(t.a,t.b,i.a,i.b,r))return!1}}return!0},`candidateIsSafe`),u=t((e,t)=>{let n=D(e.edge.points??[]);if(n.length<4||e.index>=n.length-1)return;let r=n.map(e=>({...e}));if(e.horizontal)r[e.index].y+=t,r[e.index+1].y+=t;else if(e.vertical)r[e.index].x+=t,r[e.index+1].x+=t;else return;return o(e.edge,r).length===r.length-1?r:void 0},`shiftedCandidate`),d=t((e,t)=>({x:e.x??(t.left+t.right)/2,y:e.y??(t.top+t.bottom)/2}),`nodeCenter`),f=t(e=>{let t=e.edge,r=D(t.points??[]);if(r.length!==4||e.index!==1)return;let i=t.start?n.get(t.start):void 0,a=t.end?n.get(t.end):void 0,o=i?F(i):void 0,s=a?F(a):void 0,c=r.slice(e.index+2);if(!(!i||!a||!o||!s||c.length===0))return{sourceCenter:d(i,o),targetCenter:d(a,s),sourceRect:o,tail:c}},`sourceDetourContextFor`),p=t((e,t,n,i,a,o)=>{let s=i.y>=n.y,c=s?a.bottom:a.top,l=c+(s?20:-20);if(s&&e.b.y<=l+r||!s&&e.b.y>=l-r)return;let u=e.a.x+t;return D([{x:n.x,y:c},{x:n.x,y:l},{x:u,y:l},{x:u,y:e.b.y},...o],r)},`verticalSourceDetour`),m=t((e,t,n,i,a,o)=>{let s=i.x>=n.x,c=s?a.right:a.left,l=c+(s?20:-20);if(s&&e.b.x<=l+r||!s&&e.b.x>=l-r)return;let u=e.a.y+t;return D([{x:c,y:n.y},{x:l,y:n.y},{x:l,y:u},{x:e.b.x,y:u},...o],r)},`horizontalSourceDetour`),h=t((e,t)=>{let n=f(e);if(n){if(e.vertical)return p(e,t,n.sourceCenter,n.targetCenter,n.sourceRect,n.tail);if(e.horizontal)return m(e,t,n.sourceCenter,n.targetCenter,n.sourceRect,n.tail)}},`sourceDetourCandidate`),g=[-7,7,-14,14,-21,21];for(let e=0;e<12;e++){let e=s(),t=!1;for(let n=0;ne.interior);for(let e of o){for(let n of g){let r=u(e,n);if(r&&l(e.edge,r)){e.edge.points=r,t=!0;break}let i=h(e,n);if(i&&l(e.edge,i)){e.edge.points=i,t=!0;break}}if(t)break}}if(!t)return}}t(mt,`nudgeSharedInteriorSubpaths`);function ht(e,t,n,r){let i=t.x-e.x,a=t.y-e.y,o=r.x-n.x,s=r.y-n.y,c=i*s-a*o;if(Math.abs(c)<1e-10)return!1;let l=n.x-e.x,u=n.y-e.y,d=(l*s-u*o)/c,f=(l*a-u*i)/c,p=.01;return d>p&&d<.99&&f>p&&f<.99}t(ht,`segmentsIntersect`);function gt(t){let n=t.nodes??[],r=t.edges??[],i=[];if(!r.length||!n.length)return i;let a=te(n),o=[];for(let e of r){if(e.isLayoutOnly)continue;let t=e.points;if(!t||t.length<2)continue;let n=e.start,r=e.end,s=e.labelNodeId,c=e.id??`${n}->${r}`;for(let e of a)if(e.nodeId!==n&&e.nodeId!==r&&!(s&&e.nodeId===s)){for(let n=0;n0){let t=i.filter(e=>e.type===`edge-node-overlap`).length,n=i.filter(e=>e.type===`edge-edge-crossing`).length;e.warn(`[SWIMLANE_VALIDATE] ${i.length} issue(s) detected: ${t} edge-node overlap(s), ${n} edge crossing(s)`);for(let t of i)e.warn(`[SWIMLANE_VALIDATE] ${t.type}: ${t.detail}`)}return i}t(gt,`validateSwimlanesLayout`);function _t(e,n){let r=e.nodes??[],i=e.edges??[],a=r.filter(e=>!e.isGroup);if((n===`LR`||n===`RL`)&&a.length>0&&!Re(e,n)||n===`BT`&&a.length>0&&!Le(e))return;for(let e of i){if(e.isLayoutOnly)continue;let t=e.points;!t||t.length<2||(e.points=G(W(t)))}nt(i,r),pt(i,r),He(i,r);let o=new Map;for(let e of r)o.set(String(e.id),e);ct(i,o),q(i,o),Ue(i,o),mt(i,o),Ge(i,o),Ke(i,o),qe(i,o),Xe(i,o);let s=t(()=>{$e(i,o),Ze(i,o),Qe(i,o),ct(i,o),ke(i,o),qe(i,o),ct(i,o),ke(i,o)},`finalizeRenderedEdges`);s(),mt(i,o),s(),Je(i,o),Ye(i,o),Je(i,o),Ye(i,o)}t(_t,`postProcessSwimlaneLayout`);function vt(e){let t=new Map(e.nodeById),n=new Set,r=[];for(let i of e.edges){if(!t.has(i.src)||!t.has(i.dst))continue;let e=`${i.id}:${i.src}->${i.dst}`;n.has(e)||(n.add(e),r.push(i))}return{nodes:[...t.keys()],edges:r,layout:e.layout,nodeById:t}}t(vt,`normalizeGraph`);function yt(e,t){return e.edges.filter(e=>e.dst===t)}t(yt,`incoming`);function bt(e){let t=new Map;for(let n of e.nodes)t.set(n,[]);for(let n of e.edges)t.get(n.src).push(n.dst);return t}t(bt,`buildSuccessorMap`);function xt(e){let t=bt(e);for(let e of t.values())e.sort((e,t)=>e.localeCompare(t));return t}t(xt,`buildSortedSuccessorMap`);function St(e){let t=new Map;for(let n of e.nodes)t.set(n,0);for(let n of e.edges)t.set(n.dst,(t.get(n.dst)??0)+1);return t}t(St,`buildInDegreeMap`);function Ct(e){return[...e.entries()].filter(([,e])=>e===0).map(([e])=>e).sort((e,t)=>e.localeCompare(t))}t(Ct,`sortedZeroInDegreeNodes`);function wt(e,t=()=>!0){let n=new Map,r=new Map;for(let t of e.nodes)n.set(t,[]),r.set(t,[]);for(let i of e.edges)t(i)&&(r.get(i.src).push(i.dst),n.get(i.dst).push(i.src));return{preds:n,succs:r}}t(wt,`buildPredecessorSuccessorMaps`);function Tt(e,t,n,r){let i=0;for(let t of e.nodes)r?.skipGroups&&e.nodeById.get(t)?.isGroup||(i=Math.max(i,n[t]??0));let a=Array.from({length:i+1},()=>[]);for(let i of t)r?.skipGroups&&e.nodeById.get(i)?.isGroup||a[Math.max(0,n[i]??0)].push(i);return a}t(Tt,`buildLayersFromRanks`);function Et(e){let t=St(e),n=Ct(t),r=[],i=xt(e);for(;n.length;){let e=n.shift();r.push(e);for(let r of i.get(e)??[])if(t.set(r,(t.get(r)??0)-1),(t.get(r)??0)===0){let e=0;for(;e{if(i-t<=1)return 0;let a=t+i>>1,o=r(t,a)+r(a,i),s=t,c=a,l=t;for(;s=i||se.dst===t.dst?e.id.localeCompare(t.id):e.dst.localeCompare(t.dst));let i=Object.create(null);for(let e of n.nodes)i[e]=0;let a=[],o=t(e=>{i[e]=1;for(let t of r.get(e)??[]){let e=t.dst;i[e]===0?o(e):i[e]===1&&a.push(t)}i[e]=2},`dfs`),s=St(n),c=[...n.nodes.filter(e=>(s.get(e)??0)===0),...n.nodes.filter(e=>(s.get(e)??0)!==0)];for(let e of c)i[e]===0&&o(e);let l=new Set(a.map(e=>`${e.id}:${e.src}->${e.dst}`)),u=n.edges.map(e=>l.has(`${e.id}:${e.src}->${e.dst}`)?{id:e.id,src:e.dst,dst:e.src,weight:e.weight,ref:e.ref}:e);return{acyclic:{nodes:[...n.nodes],edges:u,layout:n.layout,nodeById:new Map(n.nodeById)},reversed:a}}t(kt,`removeCycles_DFS`);function At(e){let n=new Map,r=t(t=>{if(n.has(t))return n.get(t);let i=e.nodeById.get(t);if(!i)return n.set(t,null),null;let a=i.parentId;if(!a)return n.set(t,null),null;let o=r(a)??a;return n.set(t,o),o},`resolve`);for(let t of e.nodes)r(t);return n}t(At,`buildTopLaneMap`);function jt(e){let t=At(e);return e=>t.get(e)??null}t(jt,`createTopLaneResolver`);function Mt(e){let t=[];for(let n of e.layout.nodes??[])n.isGroup&&!n.parentId&&t.push(n.id);return[...new Set(t)].reverse()}t(Mt,`buildTopLaneOrder`);function Nt(e,t){let n=Mt(e);if(!t||t.length===0)return n;let r=new Set(n),i=new Set,a=[];for(let e of t)!r.has(e)||i.has(e)||(i.add(e),a.push(e));for(let e of n)i.has(e)||a.push(e);return a}t(Nt,`resolveTopLaneOrder`);var Pt={EPSILON:1e-6},Ft={GRAVITY_ITERATIONS:8,MAX_CROSSING_OPTIMIZATION_PASSES:4,DEFAULT_COMPACT_SINGLE_INPUT:!0},It={DEFAULT_LAYER_GAP:100,DEFAULT_NODE_GAP:40};function Lt(e,n){let r=vt(e),i=n?.laneOf??(()=>null),a=n?.rankHint,{preds:o}=wt(r);for(let e of o.values())e.sort((e,t)=>e.localeCompare(t));let s=Et(r)??[...r.nodes].sort((e,t)=>e.localeCompare(t)),c=new Map;for(let[e,t]of s.entries())c.set(t,e);let l=new Map,u=new Map;for(let e of r.nodes)u.set(e,[]);for(let e of s){let t=(o.get(e)??[]).filter(e=>l.has(e));if(t.length>0){let n=Rt(e,t,{laneOf:i,rankHint:a,topoIndex:c});l.set(e,n),u.get(n).push(e)}else l.has(e)||l.set(e,null)}for(let e of r.nodes)l.has(e)||l.set(e,null);let d=new Set;for(let e of r.nodes)(l.get(e)??null)===null&&d.add(e);let f=[...d].sort((e,t)=>{let n=c.get(e)??0,r=c.get(t)??0;return n===r?e.localeCompare(t):n-r}),p=zt(r),m=new Map;for(let[e,t]of p.entries())m.set(e,[...t].sort((e,t)=>e.localeCompare(t)));let h=Bt(m),g=Vt(m),_=new Map;for(let e of r.nodes)_.set(e,[]);for(let e of g)for(let t of e.nodes){let n=_.get(t);n?n.push(e.id):_.set(t,[e.id])}let v=[],y=[],b=new Set,x=t(e=>{if(!b.has(e)){b.add(e),v.push(e);for(let t of u.get(e)??[])x(t);y.push(e)}},`walk`);for(let e of f)x(e);for(let e of s)x(e);return{parent:l,children:u,roots:f,componentOf:h,blocks:g,nodeBlocks:_,adjacency:m,preorder:v,postorder:y,topologicalOrder:s}}t(Lt,`buildDrivingTree`);function Rt(e,t,n){let r=n.laneOf(e);return[...t].sort((e,t)=>{let i=n.laneOf(e),a=n.laneOf(t),o=i!=null&&i===r;if(o!==(a!=null&&a===r))return o?-1:1;let s=n.rankHint?.[e],c=n.rankHint?.[t];if(s!=null&&c!=null&&s!==c)return c-s;let l=n.topoIndex.get(e)??0,u=n.topoIndex.get(t)??0;return l===u?e.localeCompare(t):l-u})[0]}t(Rt,`chooseParent`);function zt(e){let t=new Map;for(let n of e.nodes)t.set(n,new Set);for(let n of e.edges)t.get(n.src).add(n.dst),t.get(n.dst).add(n.src);return t}t(zt,`buildAdjacency`);function Bt(e){let t=new Map,n=0;for(let r of e.keys()){if(t.has(r))continue;let i=[r];for(;i.length>0;){let r=i.pop();if(!t.has(r)){t.set(r,n);for(let n of e.get(r)??[])t.has(n)||i.push(n)}}n++}return t}t(Bt,`assignComponents`);function Vt(e){let n=new Map,r=new Map,i=[],a=[],o=0,s=t((t,c)=>{n.set(t,++o),r.set(t,o);for(let l of e.get(t)??[])l!==c&&(n.has(l)?(n.get(l)??0)<(n.get(t)??0)&&(i.push([t,l]),r.set(t,Math.min(r.get(t)??o,n.get(l)??o))):(i.push([t,l]),s(l,t),r.set(t,Math.min(r.get(t)??o,r.get(l)??o)),(r.get(l)??0)>=(n.get(t)??0)&&a.push(Ht(t,l,i,a.length))))},`visit`);for(let t of e.keys())n.has(t)||s(t,null);return a}t(Vt,`computeBlocks`);function Ht(e,t,n,r){let i=[],a=new Set;for(;n.length>0;){let r=n.pop();if(i.push(r),a.add(r[0]),a.add(r[1]),r[0]===e&&r[1]===t||r[0]===t&&r[1]===e)break}return{id:r,edges:i,nodes:[...a]}}t(Ht,`popBlock`);function Ut(e,n,r){let i=[...e.nodes],a=new Map;for(let[e,t]of i.entries())a.set(t,e);let o=i.length,s=Array(o).fill(-1),c=Array(o).fill(0),l=[],u=new Set;for(let e of i){let t=r.parent.get(e)??null,n=a.get(e);n!=null&&(t??(s[n]=-1,c[n]=0,u.has(e)||(u.add(e),l.push(e))))}for(;l.length>0;){let e=l.shift(),t=a.get(e);if(t==null)continue;let n=r.children.get(e)??[];for(let e of n){if(u.has(e))continue;let n=a.get(e);n!=null&&(s[n]=t,c[n]=c[t]+1,u.add(e),l.push(e))}}for(let e of i){if(u.has(e))continue;let t=a.get(e);t!=null&&(s[t]=-1,c[t]=0,u.add(e))}let d=Math.max(1,Math.ceil(Math.log2(Math.max(1,o)))+1),f=Array.from({length:d},()=>Array(o).fill(-1));for(let e=0;e{if(e===-1||t===-1)return-1;c[e]>t&1&&(e=f[t][e],e===-1))return-1;if(e===t)return e;for(let n=d-1;n>=0;n--){let r=f[n][e],i=f[n][t];r!==-1&&i!==-1&&r!==i&&(e=r,t=i)}return f[0][e]},`lcaIndex`),m=Array.from({length:o},()=>new Map);for(let t of e.edges){let e=t.src,r=t.dst,i=n[e],o=n[r];if(i==null||o==null||(i>o&&([e,r]=[r,e],[i,o]=[o,i]),i==null||o==null||i===o))continue;let s=a.get(e),c=a.get(r);if(s==null||c==null)continue;let l=p(s,c);if(l===-1)continue;let u=m[l];for(let e=i;e{if(t.size!==0)for(let[n,r]of t)e.set(n,(e.get(n)??0)+r)},`mergeInto`),_=new Set,v=t(e=>{let t=a.get(e);_.add(e);let i=t==null?void 0:m[t],o=i?new Map(i):new Map,s=r.children.get(e)??[];for(let t of s){let r=v(t),i=n[e];if(i!=null){let a=h.get(e);a||(a=new Map,h.set(e,a));let o=r.get(i)??0,s=n[t];s!=null&&s>i&&(o+=1),a.set(t,o)}g(o,r)}return o},`dfs`);for(let e of r.roots)_.has(e)||v(e);for(let e of i)_.has(e)||v(e);return h}t(Ut,`computeSubtreeCrossCounts`);function Wt(e,n,r){let i=new Map,a=t(e=>{let t=r[e]??0,o=[...n.get(e)??[]];o.sort(Gt(r));for(let e of o){a(e);let n=i.get(e);n!=null&&(t=Math.min(t,n))}i.set(e,t)},`annotate`);for(let t of e)a(t);return i}t(Wt,`annotateMinimumLayers`);function Gt(e){return(t,n)=>{let r=e[t]??0,i=e[n]??0;return r===i?t.localeCompare(n):r-i}}t(Gt,`compareByRankThenId`);function Kt(e,n,r,i){let a=0;for(let e of n){let t=r[e]??0;t>a&&(a=t)}let o=Array.from({length:a+1},()=>[]),s=new Set,c=t(e=>{if(s.has(e))return;s.add(e);let t=r[e]??0;o[t]||(o[t]=[]),o[t].push(e);for(let t of i(e))c(t)},`emit`);for(let t of e)c(t);for(let e of n)if(!s.has(e)){let t=r[e]??0;o[t]||(o[t]=[]),o[t].push(e),s.add(e)}return o}t(Kt,`emitNodesInTreeOrder`);function qt(e){let t=[];for(let n of e){let e=new Set,r=[];for(let t of n)e.has(t)||(e.add(t),r.push(t));t.push(r)}return t}t(qt,`deduplicateLayers`);function Jt(e,t,n,r){return i=>{let a=e.get(i)??[];if(a.length===0)return[];let o=t[i]??0,s=[],c=[],l=n.get(i);for(let e of a){let t=r.get(e)??o;t>o?s.push({child:e,min:t}):c.push(e)}return s.sort((e,t)=>e.min===t.min?e.child.localeCompare(t.child):e.min-t.min),c.sort((e,t)=>{let n=l?.get(e)??0,i=l?.get(t)??0;if(n!==i)return n-i;let a=r.get(e)??o,s=r.get(t)??o;return a===s?e.localeCompare(t):a-s}),[...s.map(e=>e.child),...c]}}t(Jt,`createChildOrderer`);function Yt(e,t,n){let r=Lt(e,{rankHint:t,laneOf:n}),{children:i,roots:a}=r;for(let t of e.nodes)i.has(t)||i.set(t,[]);let o=Ut(e,t,r),s=[...a].sort(Gt(t)),c=Jt(i,t,o,Wt(s,i,t)),l=Kt(s,e.nodes,t,c);return l=qt(l),l}t(Yt,`buildMultitreeLayerOrder`);function Xt(e,t,n){let r=new Set(e),i=new Set(t),a=Dt(t),o=[];for(let e of n)r.has(e.src)&&i.has(e.dst)&&o.push(a.get(e.dst));return Ot(o)}t(Xt,`countCrossingsBetweenAdjacent`);function Zt(e,t,n){let r=[];for(let e of t){let t=n[e.src],i=n[e.dst];if(t==null||i==null||t===i)continue;let a=e.src,o=e.dst,s=t,c=i;t>i&&(a=e.dst,o=e.src,s=i,c=t);for(let t=s;t(n[t]??0)-(n[e]??0));for(let s of o){let o=n[s]??0;if(o===0)continue;let c=0;for(let e of r.get(s)??[])c=Math.max(c,(n[e]??0)+1);if(c>=o)continue;let l=o;n[s]=c;let u=Zt(Yt(e,n,i),e.edges,n);u(t[e]??0)-(t[n]??0)||e.localeCompare(n));for(let i of r){let r=n(i);if(!r)continue;let a=e.edges.filter(e=>e.src===i);if(a.length===0)continue;let o=!1,s=0;for(let e of a){let t=n(e.dst);t==null||t===r?o=!0:s++}if(s===0||o)continue;let c=0,l=!1;for(let t of e.edges){if(t.dst!==i)continue;let e=n(t.src);e&&(e===r?l=!0:c++)}if(c>0||!l)continue;let u=t[i]??0,d=u+s,f=0;for(let n of e.edges)n.dst===i&&(f=Math.max(f,(t[n.src]??0)+1));let p=Math.max(u,f,d);p!==u&&(t[i]=p)}}t($t,`adjustCrossLaneSources`);function en(e,t){let n=vt(e),r=Et(n)??[...n.nodes].sort(),i=t?.compactSingleInput??!1,a=jt(n),o=Object.create(null);for(let e of r){let r=yt(n,e),s=t?.ignoreCrossLaneEdges?r.filter(t=>{let n=a(t.src),r=a(e);return!n||!r||n===r}):r;if(s.length===0)o[e]=0;else if(i&&s.length===1){let t=s[0].src;a(t)===a(e)?o[e]=(o[t]??0)+1:o[e]=o[t]??0}else{let t=-1/0;for(let e of s)t=Math.max(t,(o[e.src]??0)+1);o[e]=t===-1/0?0:t}}return(t?.optimizeRanksByCrossings??!1)&&(o=Qt(n,o)),t?.ignoreCrossLaneEdges&&$t(n,o),{layers:Yt(n,o,a),rankOf:o,dummy:new Set}}t(en,`assignLayers_LongestPath`);function tn(e,n){let r=vt(e),i={...en(r,{compactSingleInput:n?.compactSingleInput,ignoreCrossLaneEdges:n?.ignoreCrossLaneEdges,optimizeRanksByCrossings:n?.optimizeRanksByCrossings}).rankOf},a=jt(r),{preds:o,succs:s}=wt(r,e=>{if(n?.ignoreCrossLaneEdges){let t=a(e.src),n=a(e.dst);if(t&&n&&t!==n)return!1}return!0}),c=Et(r)??[...r.nodes],l=[...c].reverse(),u=t((e,t)=>{let n=0;for(let t of o.get(e)??[])n=Math.max(n,(i[t]??0)+1);let r=1/0,a=s.get(e)??[];return a.length>0&&(r=Math.min(...a.map(e=>(i[e]??0)-1))),Number.isFinite(r)||(r=Math.max(n,t)),Math.min(Math.max(t,n),r)},`clampFeasible`),d=Ft.GRAVITY_ITERATIONS,f=t(e=>{let t=!1;for(let n of e){let e=o.get(n)??[],r=s.get(n)??[];if(e.length===0&&r.length===0)continue;let a=e.length>0?e.reduce((e,t)=>e+(i[t]??0)+1,0)/e.length:i[n]??0,c=r.length>0?r.reduce((e,t)=>e+(i[t]??0)-1,0)/r.length:i[n]??0,l=Math.round((a+c)/2),d=u(n,l);d!==i[n]&&(i[n]=d,t=!0)}return t},`relaxOrder`);for(let e=0;e0){let n=Math.min(...t.map(e=>(i[e]??0)-1));(i[e]??0)>n&&(i[e]=n)}}return{layers:Tt(r,c,i),rankOf:i,dummy:new Set}}t(tn,`assignLayers_Gravity`);function nn(e){let t=St(e),n=xt(e),r=Ct(t),i=[];for(;r.length>0;){let e=[];for(let a of r){i.push(a);for(let r of n.get(a)??[])t.set(r,(t.get(r)??0)-1),(t.get(r)??0)===0&&e.push(r)}r=e.sort((e,t)=>e.localeCompare(t))}return i.length===e.nodes.length?i:null}t(nn,`topoSortByGenerationIfAcyclic`);function rn(e,n){let r=vt(e),i=n?.direction===`LR`?nn(r)??[...r.nodes].sort():Et(r)??[...r.nodes].sort(),a=jt(r),o=t(e=>a(e)??e,`laneOf`),s=Object.create(null),c=new Map,l=t((e,t)=>n?.ignoreCrossLaneEdges??!0?+(o(e)===o(t)):1,`edgeWeight`);for(let e of i){if(r.nodeById.get(e)?.isGroup)continue;let t=yt(r,e),n=0;if(t.length>0)for(let r of t){let t=r.src,i=s[t]??0;n=Math.max(n,i+l(t,e))}let i=o(e),a=c.get(i)??0,u=Math.max(n,a);s[e]=u,c.set(i,u+1)}return{layers:Tt(r,i,s,{skipGroups:!0}),rankOf:s,dummy:new Set}}t(rn,`assignLayers_LaneAwareCompact`);function an(e,n){let r=vt(n),{rankOf:i}=e,a=e.layers.map(e=>[...e]),o=new Set(e.dummy?[...e.dummy]:[]),s=0,c=new Map(r.nodeById),l=t(e=>{let t=`placeholder-${s++}`,n={id:t,isGroup:!1,isDummy:!0,width:0,height:0};for(c.set(t,n),o.add(t);a.length<=e;)a.push([]);return a[e].push(t),i[t]=e,t},`addDummyAt`),u=[...r.edges].sort((e,t)=>e.id===t.id?e.src===t.src?e.dst.localeCompare(t.dst):e.src.localeCompare(t.src):e.id.localeCompare(t.id)),d=[];for(let e of u){let t=i[e.src]??0,n=i[e.dst]??0;if(n-t<=1){d.push(e);continue}let r=e.src;for(let i=t+1,a=0;i!r.nodes.includes(e))],edges:d,layout:r.layout,nodeById:c};return{layering:{layers:a,rankOf:i,dummy:o},graphWithDummies:f}}t(an,`makeProperLayering`);function on(e){let t=e.length;if(t===0)return 1/0;let n=[...e].sort((e,t)=>e-t);return t%2==1?n[(t-1)/2]:.5*(n[t/2-1]+n[t/2])}t(on,`median`);function sn(e){return e.length===0?1/0:e.reduce((e,t)=>e+t,0)/e.length}t(sn,`barycenter`);function cn(e,t,n,r){let i=new Map;for(let t of e)i.set(t,[]);for(let e of n)r===`down`?t.has(e.src)&&i.has(e.dst)&&i.get(e.dst).push(t.get(e.src)):t.has(e.dst)&&i.has(e.src)&&i.get(e.src).push(t.get(e.dst));return i}t(cn,`neighborPositionsFor`);function ln(e,t,n){let r=n.get(e)??0,i=n.get(t)??0;return r===i?e.localeCompare(t):r-i}t(ln,`currentOrderTieBreak`);function un(e,t,n){let r=new Set(e),i=new Set(t),a=Dt(e),o=Dt(t),s=[];for(let e of n)r.has(e.src)&&i.has(e.dst)&&s.push({u:a.get(e.src),v:o.get(e.dst)});return s.sort((e,t)=>e.u===t.u?e.v-t.v:e.u-t.u),Ot(s.map(e=>e.v))}t(un,`countCrossingsBetweenAdjacent`);function dn(e,t,n){return[...e].sort((e,r)=>{let i=on(t.get(e)??[]),a=on(t.get(r)??[]);return i===a?ln(e,r,n):isFinite(i)?isFinite(a)?i-a:-1:1})}t(dn,`sortByHeuristic`);function fn(e,t,n,r,i,a){let o=Dt(e),s=Dt(t),c=cn(t,o,n,r);if(!i||!a||a.length===0)return dn(t,c,s);let l=new Map;for(let e of t){let t=i(e),n=l.get(t)??[];n.push(e),l.set(t,n)}let u=[];for(let e of a){let t=l.get(e);if(!t||t.length===0)continue;let n=dn(t,c,s);u.push(...n)}let d=l.get(null);if(d&&d.length>0){let e=dn(d,c,s);for(let t of e){let e=sn(c.get(t)??[]),n=u.length;if(isFinite(e)){for(let[t,r]of u.entries())if(es.has(e.src)&&c.has(e.dst)),d=l?r.filter(e=>c.has(e.src)&&l.has(e.dst)):void 0,f=t(t=>{let n=un(e,t,u);return d&&i&&(n+=un(t,i,d)),n},`crossingScore`),p=a?new Map:null;if(a&&p)for(let e of n)p.set(e,a(e));let m=!0,h=f(o);for(;m;){m=!1;for(let e=0;e+1[...e]),i=t.edges,a=jt(t),o=Nt(t,n?.laneOrder);for(let e=0;e<3;e++){for(let e=1;e=0;e--)r[e]=fn(r[e+1],r[e],i,`up`,a,o),r[e]=pn(r[e+1],r[e],i,r[e-1],a)}return{layers:r}}t(mn,`orderLayers`);function hn(e,n,r){let i=r?.layerGap??It.DEFAULT_LAYER_GAP,a=r?.nodeGap??It.DEFAULT_NODE_GAP,o=r?.laneGap??a*2,s=r?.direction??`TB`,c=s===`LR`||s===`RL`,l=e.layers,u=Object.create(null),d=Object.create(null),f=t(e=>n.nodeById.get(e),`getNode`),p=t(e=>f(e)?.width??0,`getWidth`),m=t(e=>f(e)?.height??0,`getHeight`),h=jt(n),g=Nt(n,r?.laneOrder),_=l.map(e=>e.reduce((e,t)=>Math.max(e,m(t)),0)),v=[];if(c)for(let e=0;e+1Math.max(e,p(t)),0),n=l[e+1].reduce((e,t)=>Math.max(e,p(t)),0),r=_[e],a=_[e+1],o=r/2+a/2,s=(t+n)/2,c=Math.max(0,s-o-i);v.push(c)}let y=new Set;for(let e of l)for(let t of e)y.add(h(t));let b=y.has(null),x=g.filter(e=>y.has(e)),S=[...b?[null]:[],...x],C=Object.create(null);for(let e of x)C[e]=0;b&&(C.null=0);for(let e of l){let t=Object.create(null),n=[];for(let r of e){let e=h(r);e===null?n.push(r):(t[e]||=[]).push(r)}for(let[e,n]of Object.entries(t)){let t=n.reduce((e,t)=>e+p(t),0)+a*Math.max(0,n.length-1);C[e]=Math.max(C[e]??0,t)}if(b&&n.length){let e=n.reduce((e,t)=>e+p(t),0)+a*Math.max(0,n.length-1);C.null=Math.max(C.null??0,e)}}let w=new Map;{let e=S.map(e=>(e===null?C.null:C[e])??0),t=-(e.reduce((e,t)=>e+t,0)+o*Math.max(0,S.length-1))/2;for(let n=0;np(e)),r=i-(e.reduce((e,t)=>e+t,0)+a*(t.length-1))/2;for(let[i,o]of t.entries()){let t=e[i];u[o]=r+t/2,d[o]=T+n/2,r+=t+a}}}let o=v[e]??0;T+=n+i+o}let E=new Map;for(let e of n.edges){let t=e.ref.id;E.has(t)||E.set(t,[]),E.get(t).push(e)}for(let[,e]of E){if(e.length===0)continue;let t=e[0].ref,r=t.start,i=t.end;if(r==null||i==null)continue;let a=Math.round(((u[r]??0)+(u[i]??0))/2),o=new Set;for(let t of e)o.add(t.src),o.add(t.dst);for(let e of o)e!==r&&e!==i&&n.nodeById.get(e)?.isDummy&&(u[e]=a)}return{x:u,y:d}}t(hn,`assignCoordinates`);var gn=8;function _n(e){let t=2166136261;for(let n=0;n>>0}t(_n,`hashString`);function vn(e){let t=e>>>0;return()=>{t+=1831565813;let e=t;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296}}t(vn,`mulberry32`);function yn(e,t){let n=[...e],r=vn(t);for(let e=n.length-1;e>0;e--){let t=Math.floor(r()*(e+1));[n[e],n[t]]=[n[t],n[e]]}return n}t(yn,`deterministicShuffle`);function bn(e,t){let n=0;for(let[r,i]of e.entries())n+=Math.abs(r-(t.get(i)??r));return n}t(bn,`sourceDistance`);function xn(e,t){let n=new Map;for(let[t,r]of e.entries())n.set(r,t);let r=0;for(let{a:e,b:i,weight:a}of t){let t=n.get(e),o=n.get(i);t!=null&&o!=null&&(r+=a*Math.abs(t-o))}return r}t(xn,`laneArrangementCost`);function Sn(e){let t=Mt(e);if(t.length<2)return[];let n=new Map(t.map((e,t)=>[e,t])),r=jt(e),i=new Map;for(let t of e.layout.edges??[]){if(t.isLayoutOnly)continue;let a=typeof t.start==`string`?t.start:void 0,o=typeof t.end==`string`?t.end:void 0;if(!a||!o||!e.nodeById.has(a)||!e.nodeById.has(o))continue;let s=r(a),c=r(o);if(!s||!c||s===c)continue;let l=n.get(s),u=n.get(c);if(l==null||u==null)continue;let[d,f]=l<=u?[s,c]:[c,s],p=`${d}\0${f}`,m=i.get(p);m?m.weight++:i.set(p,{a:d,b:f,weight:1})}return[...i.values()]}t(Sn,`buildWeightedLaneEdges`);function Cn(e,t,n){let r=[...e],i=xn(r,t),a=!0,o=0,s=Math.max(1,r.length);for(;a&&oe.a===t.a?e.b.localeCompare(t.b):e.a.localeCompare(t.a)).map(({a:e,b:t,weight:n})=>`${e}:${t}:${n}`).join(`|`);return _n(`${e.join(`|`)}#${r}#${n}`)}t(Tn,`seedForRestart`);function En(e,t={}){let n=Mt(e);if(n.length<2)return n;let r=Sn(e);if(r.length===0)return n;let i=new Map(n.map((e,t)=>[e,t])),a=Cn(n,r,i),o=Math.max(0,t.restarts??gn);for(let e=0;e$&&c*3>=s?o>0?`bottom`:`top`:s>$?a>0?`right`:`left`:n}t(Pn,`chooseOrthogonalSide`);function Fn(e,t){return Math.abs(e.to-t.from)<$||Math.abs(e.to-t.to)<$?e.to:e.from}t(Fn,`sharedLineEndpointCoord`);function In(e,t){return e.orient===`vertical`?{x:e.coord,y:t}:{x:t,y:e.coord}}t(In,`pointOnLine`);function Ln(e,n){let r=e.nodes??[],i=e.edges??[],a=[];for(let e of i)e.isLayoutOnly||a.push({...e,__originalEdge:e});let o=new Map,s=new Map,c=[],l=n===`LR`;for(let e of r)o.set(e.id,e);let u=r.filter(e=>e.isGroup&&!e.parentId);for(let e of u){let n={id:e.id},i=t(e=>{s.set(e.id,n),r.filter(t=>t.parentId===e.id).forEach(i)},`assignLane`);i(e)}let d=r.filter(e=>!e.isGroup&&!e.isEdgeLabel).map(e=>{let t=e.width??10,n=e.height??10,r=e.x??0,i=e.y??0,a=On;return{nodeId:e.id,minX:r-t/2-a,maxX:r+t/2+a,minY:i-n/2-a,maxY:i+n/2+a,visualXHalfExtent:l?n/2+a:t/2+a}}),f=t((e,t,n,r)=>{let i=c.find(n=>n.orientation===e&&Math.abs(n.coord-t)<1);return i||(i={id:`pipe-${e}-${t.toFixed(0)}`,orientation:e,coord:t,spanMin:n,spanMax:r,tracks:[]},c.push(i)),i.spanMin=Math.min(i.spanMin,n),i.spanMax=Math.max(i.spanMax,r),i},`getOrAddPipe`),p=t((e,t)=>{let n=e.width??10,r=e.height??10,i=e.x??0,a=e.y??0;switch(t){case`top`:return{x:i,y:a-r/2};case`bottom`:return{x:i,y:a+r/2};case`left`:return{x:i-n/2,y:a};case`right`:return{x:i+n/2,y:a}}},`portForSide`),m=t((e,t,n)=>p(e,Pn(e,t,n?`bottom`:`top`)),`getOrthogonalPort`),h=[],g=[],_=new Set,v=1e3,y=t((e,t,n)=>{if(h.length===0)return 0;let r=Math.abs(t.y-n.y)<$,i=Math.abs(t.x-n.x)<$;if(!r&&!i)return 0;let a=0;if(r){let r=t.y,i=Math.min(t.x,n.x)-$,o=Math.max(t.x,n.x)+$;if(o<=i)return 0;for(let t of h)t.edgeIndex!==e&&t.orientation===`vertical`&&(t.pipe.coordo||t.from-$<=r&&t.to+$>=r&&(a+=v))}else if(i){let r=t.x,i=Math.min(t.y,n.y)-$,o=Math.max(t.y,n.y)+$;if(o<=i)return 0;for(let t of h)t.edgeIndex!==e&&t.orientation===`horizontal`&&(t.pipe.coordo||t.from-$<=r&&t.to+$>=r&&(a+=v))}return a},`crossingPenalty`),b=a.map((e,t)=>{if(!e.start||!e.end)return{idx:t,crossLane:0,dx:0,dy:0};let n=o.get(e.start),r=o.get(e.end),i=s.get(e.start),a=s.get(e.end);return{idx:t,crossLane:i&&a&&i.id!==a.id?1:0,dx:n&&r?Math.abs((r.x??0)-(n.x??0)):0,dy:n&&r?Math.abs((r.y??0)-(n.y??0)):0}}).sort((e,t)=>{if(e.crossLane!==t.crossLane)return t.crossLane-e.crossLane;let n=e.dx+e.dy,r=t.dx+t.dy;return Math.abs(n-r)>1?n-r:e.idx-t.idx}).map(e=>e.idx),x=t((e,t,n,r)=>{let i=Math.min(e.x,t.x),a=Math.max(e.x,t.x),o=Math.min(e.y,t.y),s=Math.max(e.y,t.y);return!!d.find(c=>n&&c.nodeId===n||r&&c.nodeId===r?!1:Math.abs(e.x-t.x)>$?c.minYe.y&&c.maxX>i&&c.minXe.x&&c.maxY>o&&c.minYPn(e,t,`bottom`),`determineSide`),T=new Map;for(let[e,t]of a.entries()){if(!t.start||!t.end||t.start===t.end||t.points&&t.points.length>0)continue;let n=o.get(t.start),r=o.get(t.end);if(!n||!r)continue;let i=(r.x??0)-(n.x??0),a=(r.y??0)-(n.y??0);T.set(e,{edgeIdx:e,srcId:t.start,dstId:t.end,srcSide:w(n,{x:r.x??0,y:r.y??0}),dstSide:w(r,{x:n.x??0,y:n.y??0}),absDx:Math.abs(i),absDy:Math.abs(a),dxSign:Math.sign(i),dySign:Math.sign(a)})}let E=t(e=>e.srcSide===`top`||e.srcSide===`bottom`?e.absDx===0?1/0:e.absDy/e.absDx:e.absDy===0?1/0:e.absDx/e.absDy,`preferenceStrength`),D=t(e=>e.srcSide===`top`||e.srcSide===`bottom`?e.dxSign>=0?`right`:`left`:e.dySign>=0?`bottom`:`top`,`secondarySide`),O=new Map;for(let e of T.values()){let t=`${e.srcId}:${e.srcSide}`;O.has(t)||O.set(t,[]),O.get(t).push(e)}let k=new Map,A=t((e,t)=>`${e}:${t}`,`loadKey`);for(let e of T.values())k.set(A(e.srcId,e.srcSide),(k.get(A(e.srcId,e.srcSide))??0)+1),k.set(A(e.dstId,e.dstSide),(k.get(A(e.dstId,e.dstSide))??0)+1);for(let e of O.values())if(!(e.length<2)){e.sort((e,t)=>{let n=E(e),r=E(t);return Math.abs(n-r)>1e-9?r-n:e.edgeIdx-t.edgeIdx});for(let t=1;t=i||(k.set(A(n.srcId,n.srcSide),i-1),k.set(A(n.srcId,r),a+1),n.srcSide=r)}}let j=t(e=>{let t=e?.shape;return t===`question`||t===`diamond`},`isDiamondNode`),M=new Map;for(let e of T.values())M.has(e.dstId)||M.set(e.dstId,new Set),M.get(e.dstId).add(e.dstSide);for(let e of T.values()){if(!j(o.get(e.srcId)))continue;let t=M.get(e.srcId);if(!t?.has(e.srcSide))continue;let n=D(e);if(t.has(n)||(k.get(A(e.srcId,n))??0)>0)continue;let r=k.get(A(e.srcId,e.srcSide))??0;k.set(A(e.srcId,e.srcSide),Math.max(0,r-1)),k.set(A(e.srcId,n),1),e.srcSide=n}for(let e of T.values()){let{edgeIdx:t,srcId:n,dstId:r,srcSide:i,dstSide:a}=e,s=o.get(n),c=o.get(r),l=`${n}:${i}:src`,u=i===`top`||i===`bottom`?c.x??0:c.y??0;S.has(l)||S.set(l,[]),S.get(l).push({edgeIdx:t,oppositeCoord:u});let d=`${r}:${a}:dst`,f=a===`top`||a===`bottom`?s.x??0:s.y??0;S.has(d)||S.set(d,[]),S.get(d).push({edgeIdx:t,oppositeCoord:f})}let N=new Map;for(let[e,t]of S){if(t.length<2)continue;t.sort((e,t)=>e.oppositeCoord-t.oppositeCoord);let n=e.split(`:`),r=n.slice(0,-2).join(`:`),i=n[n.length-2],a=n[n.length-1],s=o.get(r);if(!s)continue;let c=i===`left`||i===`right`?s.height??10:s.width??10,l=s.shape,u=l===`question`||l===`diamond`?c*.3:c,d=Math.min(20,Math.max(8,u/(t.length+1))),f=-(d*(t.length-1))/2;for(let[e,n]of t.entries()){let t=f+e*d,r=`${n.edgeIdx}:${a}`;N.set(r,t)}}let P=t(e=>!!a[e]?.labelNodeId,`edgeHasLabelNode`),F=t((e,t)=>e?(S.get(`${e}:${t}:src`)??[]).some(({edgeIdx:e})=>P(e))||(S.get(`${e}:${t}:dst`)??[]).some(({edgeIdx:e})=>P(e)):!1,`faceHasLabelNode`),I=t((e,t,n)=>t===`top`||t===`bottom`?{x:e.x+n,y:e.y}:{x:e.x,y:e.y+n},`applyPortOffset`),ee=t((e,t,n)=>{let r=T.get(e),i={x:n.x??0,y:n.y??0},a={x:t.x??0,y:t.y??0},o=r?.srcSide??w(t,i),s=r?.dstSide??w(n,a),c=r?p(t,r.srcSide):m(t,i,!0),l=r?p(n,r.dstSide):m(n,a,!1),u=N.get(`${e}:src`),d=N.get(`${e}:dst`);return u!==void 0&&(c=I(c,o,u)),d!==void 0&&(l=I(l,s,d)),{pSrcPort:c,pDstPort:l,srcSide:o,dstSide:s}},`portsForEdge`);for(let e of b){let n=a[e];if(g[e]=[],!n.start||!n.end||n.points&&n.points.length>0||n.start===n.end)continue;let r=o.get(n.start),i=o.get(n.end);if(!r||!i)continue;let{pSrcPort:s,pDstPort:u,srcSide:p,dstSide:m}=ee(e,r,i),v={...s},b={...u},w=p===`top`||p===`bottom`,T=m===`top`||m===`bottom`;w?v.y=s.y>(r.y??0)?s.y+Mn:s.y-Mn:v.x=s.x>(r.x??0)?s.x+Mn:s.x-Mn,T?b.y=u.y>(i.y??0)?u.y+Mn:u.y-Mn:b.x=u.x>(i.x??0)?u.x+Mn:u.x-Mn;let E=t((e,t)=>{for(let n of d)if(!t.includes(n.nodeId)&&e.x>n.minX&&e.xn.minY&&e.y{if(i){let i=e.y>(t.y??0);return{x:(n.x??0)>=e.x?r.maxX+kn:r.minX-kn,y:i?r.maxY+An:r.minY-An,leavesPositiveSide:i}}let a=e.x>(t.x??0),o=(n.y??0)>=e.y;return{x:a?r.maxX+kn:r.minX-kn,y:o?r.maxY+An:r.minY-An,leavesPositiveSide:a}},`obstacleDetour`),O=[],k=[n.start,n.end],A=E(v,k);if(A.inside&&A.obstacle){let e=A.obstacle;if(w){let t=D(s,r,i,e,!0);v.x=t.x,v.y=t.y;let n=t.leavesPositiveSide?Math.min(e.minY-2,s.y+Mn):Math.max(e.maxY+2,s.y-Mn);O=[{x:s.x,y:n},{x:t.x,y:n},{x:t.x,y:t.y}]}else{let t=D(s,r,i,e,!1),n=t.leavesPositiveSide?Math.min(e.minX-2,s.x+Mn):Math.max(e.maxX+2,s.x-Mn);v.x=t.x,v.y=t.y,O=[{x:n,y:s.y},{x:n,y:t.y},{x:t.x,y:t.y}]}}let j=[],M=E(b,k);if(M.inside&&M.obstacle){let e=M.obstacle;if(T){let t=D(u,i,r,e,!0);b.x=t.x,b.y=t.y,j=[{x:t.x,y:t.y},{x:u.x,y:t.y}]}else{let t=D(u,i,r,e,!1);b.x=t.x,b.y=t.y,j=[{x:t.x,y:t.y},{x:t.x,y:u.y}]}}if(O.length===0&&j.length===0){let t=kn,r=Math.abs(v.x-b.x)1||c>1,d=C.get(n.start??``)??0,f=C.get(n.end??``)??0,g=o>1&&F(n.start,p)||c>1&&F(n.end,m);if((r||i)&&!a&&(!l||l&&!g&&(o<=1||d<=2)&&(c<=1||f<=2))&&!x(s,u,n.start,n.end)){n.points=[{...s},{...v},{...b},{...u}],_.add(e);let t=i?`horizontal`:`vertical`,r=i?s.y:s.x,a=i?Math.min(s.x,u.x):Math.min(s.y,u.y),o=i?Math.max(s.x,u.x):Math.max(s.y,u.y),c={id:`fast-path-${t}-${r.toFixed(0)}-${e}`,orientation:t,coord:r,spanMin:a,spanMax:o,tracks:[]};h.push({edgeIndex:e,segmentIndex:0,orientation:t,pipe:c,trackIndex:0,from:a,to:o});continue}}v.x=f(`vertical`,v.x,v.y,v.y).coord,b.x=f(`vertical`,b.x,b.y,b.y).coord;let P=Math.min(v.x,b.x)-50,I=Math.max(v.x,b.x)+50,L=Math.min(v.y,b.y)-50,R=Math.max(v.y,b.y)+50;for(let e of d){let t=Math.min(v.x,b.x),n=Math.max(v.x,b.x),r=Math.min(v.y,b.y),i=Math.max(v.y,b.y);e.minXt&&e.minYr&&(P=Math.min(P,e.minX-jn),I=Math.max(I,e.maxX+jn),L=Math.min(L,e.minY-jn),R=Math.max(R,e.maxY+jn))}for(let e of d){if(e.maxXI||e.maxYR)continue;let t=kn;f(`horizontal`,e.minY-t,P,I),f(`horizontal`,e.maxY+t,P,I);let n=An;f(`vertical`,e.minX-n,L,R),f(`vertical`,e.maxX+n,L,R)}f(`horizontal`,v.y,P,I),f(`horizontal`,b.y,P,I);let z=c.filter(e=>e.orientation===`horizontal`&&e.coord>=L&&e.coord<=R),te=c.filter(e=>e.orientation===`vertical`&&e.coord>=P&&e.coord<=I),ne=t((e,t)=>`${e.toFixed(1)},${t.toFixed(1)}`,`getKey`),B=ne(v.x,v.y),re=ne(b.x,b.y),ie=new Map,ae=new Map,V=new Map,oe=new Set,H=[];ie.set(B,0),V.set(B,`n`),H.push({key:B,f:Math.hypot(b.x-v.x,b.y-v.y),pt:v}),oe.add(B);let U=[],W=t((e,t)=>x(e,t,n.start,n.end),`checkSegmentBlocked`),G={x:b.x,y:v.y},K=W(v,G),se=W(G,b),ce=K||se,le={x:v.x,y:b.y},ue=W(v,le),de=W(le,b);if(ce?ue||de||(U=Math.abs(v.x-b.x)<$?[v,b]:[v,le,b]):U=Math.abs(v.y-b.y)<$||Math.abs(v.x-b.x)<$?[v,b]:[v,G,b],U.length===0)for(;H.length>0;){H.sort((e,t)=>e.f-t.f);let t=H.shift();if(oe.delete(t.key),t.key===re){let e=re,t=b;for(U=[t];ae.has(e);){let n=ae.get(e);U.unshift(n),t=n,e=ne(n.x,n.y)}break}let r=t.pt.x,i=t.pt.y,a=te.sort((e,t)=>e.coord-t.coord),o=a.findIndex(e=>Math.abs(e.coord-r)<1),s=z.sort((e,t)=>e.coord-t.coord),c=s.findIndex(e=>Math.abs(e.coord-i)<1),l=[];o>0&&l.push({x:a[o-1].coord,y:i}),o>=0&&o0&&l.push({x:r,y:s[c-1].coord}),c>=0&&ce.nodeId===n.start||e.nodeId===n.end?!1:o===s?e.minXr&&e.maxY>c&&e.minYi&&e.maxX>o&&e.minX10&&x<-5||g<-10&&x>5)&&(m=Math.abs(x)*100),(h>10&&_<-5||h<-10&&_>5)&&(m+=Math.abs(_)*50);let S=0,C=V.get(t.key)??`n`,w=Math.abs(_)>$?`h`:`v`;C!==`n`&&C!==w&&(S=50);let T=f+p+m+S,E=(ie.get(t.key)??1/0)+T,D=Math.abs(b.x-a.x)+Math.abs(b.y-a.y);if(E<(ie.get(u)??1/0)){if(ae.set(u,t.pt),ie.set(u,E),V.set(u,w),!oe.has(u))H.push({key:u,f:E+D,pt:a}),oe.add(u);else{let e=H.findIndex(e=>e.key===u);e!==-1&&(H[e].f=E+D)}}}}if(U.length===0&&(U=[v,{x:v.x,y:b.y},b]),U.length>4){let e=U[0],n=U[U.length-1],r=Math.min(e.x,n.x),i=Math.max(e.x,n.x),a=Math.min(e.y,n.y),o=Math.max(e.y,n.y);for(let e of U)r=Math.min(r,e.x),i=Math.max(i,e.x),a=Math.min(a,e.y),o=Math.max(o,e.y);let s=i>Math.max(e.x,n.x),c=re.minXr&&e.minYa);if(s.length>0){let r=Math.max(e.x,n.x);for(let e of s){let n=(e.minX+e.maxX)/2;if(e.visualXHalfExtent===void 0||isNaN(e.visualXHalfExtent))continue;let i=n+e.visualXHalfExtent+t;r=Math.max(r,i)}isNaN(r)||(i=r)}}if(c){let i=d.filter(r=>r.minXMath.min(e.y,n.y));if(i.length>0){let a=Math.min(e.x,n.x);for(let e of i){let n=(e.minX+e.maxX)/2-e.visualXHalfExtent-t;a=Math.min(a,n)}r=a}}}let u=t(t=>{let r=n.y>e.y,i=d.filter(t=>{let r=Math.min(e.x,n.x)t.minX,i=Math.min(e.y,n.y)t.minY;return r&&i}),a=i;if(l&&i.length>0){let e=i.filter(e=>e.minXt);e.length>0&&(a=e)}if(a.length===0)return n.y;let o=kn;if(r){let e=Math.max(...a.map(e=>e.maxY))+o;if(ee.minY))-o;if(e>n.y+$)return e}return n.y},`findBestReturnY`),f=t(t=>{let r=u(t),i={x:t,y:e.y},a={x:t,y:r},o={x:n.x,y:r},s=W(e,i),c=W(i,a),l=W(a,o),d=r!==n.y&&W(o,n);return!s&&!c&&!l&&!d?Math.abs(r-n.y)<$?[e,i,a,n]:[e,i,a,o,n]:null},`trySimplifyWithDetourX`),p=s&&!c?f(i):c&&!s?f(r):null;p&&(U=p)}let q=[s,...O,...U,...j.reverse(),u];if(q.length>=3){let e=q[q.length-1],t=q[q.length-2],n=q[q.length-3],r=Math.abs(n.y-t.y)<$&&Math.abs(t.y-e.y)<$,i=Math.abs(n.x-t.x)<$&&Math.abs(t.x-e.x)<$;if(r){let r=Math.sign(t.x-n.x),i=Math.sign(e.x-n.x);r!==0&&r===i&&Math.abs(t.x-n.x)>Math.abs(e.x-n.x)&&q.splice(-2,1)}else if(i){let r=Math.sign(t.y-n.y),i=Math.sign(e.y-n.y);r!==0&&r===i&&Math.abs(t.y-n.y)>Math.abs(e.y-n.y)&&q.splice(-2,1)}}let J=[q[0]];for(let e=1;et.x!=r.x>n.x){J.push(n);continue}continue}if(Math.abs(t.x-n.x)<$&&Math.abs(n.x-r.x)<$){if(n.y>t.y!=r.y>n.y){J.push(n);continue}continue}J.push(n)}J.push(q[q.length-1]);for(let t=0;te.from{let i=!r.segments.some(n=>(n.edgeIndex!==t.edgeIndex||n.segmentIndex!==t.segmentIndex)&&L(n,e)),a=!n.segments.some(n=>(n.edgeIndex!==e.edgeIndex||n.segmentIndex!==e.segmentIndex)&&L(n,t));return i&&a?(e.trackIndex=r.index,t.trackIndex=n.index,n.segments=[...n.segments.filter(t=>t.edgeIndex!==e.edgeIndex||t.segmentIndex!==e.segmentIndex),{edgeIndex:t.edgeIndex,segmentIndex:t.segmentIndex,from:t.from,to:t.to}],r.segments=[...r.segments.filter(e=>e.edgeIndex!==t.edgeIndex||e.segmentIndex!==t.segmentIndex),{edgeIndex:e.edgeIndex,segmentIndex:e.segmentIndex,from:e.from,to:e.to}],!0):!1},`trySwapSegmentsAcrossTracks`),z=t(e=>{let t=e.tracks.length;return e.tracks[t]={index:t,coord:e.coord,segments:[]},t},`createNewTrack`),te=t((e,t)=>{let n=e.pipe.tracks[e.trackIndex];n.segments=n.segments.filter(t=>t.edgeIndex!==e.edgeIndex||t.segmentIndex!==e.segmentIndex),e.trackIndex=t,e.pipe.tracks[t].segments.push({edgeIndex:e.edgeIndex,segmentIndex:e.segmentIndex,from:e.from,to:e.to})},`moveSegmentToTrack`),ne=t((e,t)=>{let n=g[e.edgeIndex];for(let r of n){let n=h[r];n.pipe===e.pipe&&te(n,t)}},`moveSegmentChainToTrack`),B=t(e=>{let t=g[e.edgeIndex],n=t.indexOf(h.indexOf(e)),r=[];return n>0&&r.push(h[t[n-1]]),n{if(e.orientation===t.orientation)return!1;let n=e.orientation===`horizontal`?e:t,r=e.orientation===`horizontal`?t:e;return r.pipe.coord>n.from&&r.pipe.coordr.from&&n.pipe.coord{for(let n of e.tracks)if(!n.segments.some(e=>(e.edgeIndex!==t.edgeIndex||e.segmentIndex!==t.segmentIndex)&&L(e,t)))return n.index;return-1},`findAvailableTrack`),ae=t((e,t)=>{if(e.trackIndex===t.trackIndex)return L(e,t);let n=B(e),r=B(t);return n.some(e=>r.some(t=>re(e,t)))},`segmentsConflict`),V=t((e,t,n)=>{if(R(e,t,e.pipe.tracks[e.trackIndex],t.pipe.tracks[t.trackIndex]))return;let r=ie(e.pipe,t);n(t,r===-1?z(e.pipe):r)},`resolveTrackConflict`),oe=t(e=>{let t=0;for(let n=0;n{if(H.has(e))return H.get(e);let t=g[e];if(t.length===0){let t={dest:0,deviation:0,base:0,delta:0};return H.set(e,t),t}let n=h[t[0]].pipe.coord,r=n;for(let e=1;eMath.abs(t-n)?e:t;break}}let i=Math.abs(r-n),a={dest:r,deviation:i,base:n,delta:r-n};return H.set(e,a),a},`getDestInfo`),W=t(()=>{let e=0,n=new Map;for(let[e,t]of a.entries())g[e].length!==0&&t.start&&(n.has(t.start)||n.set(t.start,[]),n.get(t.start).push(e));let r=t(e=>{let t=a[e];if(!t.start||!t.end)return 0;let n=o.get(t.start),r=o.get(t.end);if(!n||!r)return 0;let i=(r.x??0)-(n.x??0),s=(r.y??0)-(n.y??0);return Math.abs(i)+Math.abs(s)},`getEdgeDistance`);for(let t of n.values()){t.sort((e,t)=>{let n=U(e),i=U(t);if(Math.abs(n.deviation-i.deviation)>1)return n.deviation-i.deviation;if(Math.abs(n.dest-i.dest)>1)return n.dest-i.dest;let a=r(e),o=r(t);if(Math.abs(a-o)>1)return o-a;let s=g[e].length,c=g[t].length;if(s!==c)return s-c;if(s===1){let n=g[e][0],r=g[t][0];if(h[n]&&h[r]){let e=h[n],t=h[r],i=Math.abs(e.to-e.from),a=Math.abs(t.to-t.from);if(Math.abs(i-a)>1)return i-a}}return 0});let n=t.map(e=>h[g[e][0]]);e+=oe(n)}return e},`fixSourceHandleCrossings`),G=t(()=>{let e=0,n=new Map;for(let[e,t]of a.entries())g[e].length!==0&&t.end&&(n.has(t.end)||n.set(t.end,[]),n.get(t.end).push(e));for(let r of n.values()){r.sort((e,n)=>{let r=t(e=>{let t=g[e];if(t.length<2)return 0;let n=h[t[t.length-2]];return Math.abs(n.to-n.from)},`getDist`),i=r(e),a=r(n);return Math.abs(i-a)>.1?i-a:e-n});let n=r.map(e=>h[g[e][g[e].length-1]]);e+=oe(n)}return e},`fixTargetHandleCrossings`),K=t(()=>{let e=0;for(let t of c){let n=[];for(let e of t.tracks)for(let t of e.segments){let e=g[t.edgeIndex].find(e=>h[e].segmentIndex===t.segmentIndex);e!==void 0&&n.push(h[e])}n.sort((e,t)=>e.edgeIndex-t.edgeIndex||e.segmentIndex-t.segmentIndex);for(let t=0;t{e.segments.forEach(t=>{n.push({edgeIndex:t.edgeIndex,segmentIndex:t.segmentIndex,trackIndex:e.index,from:t.from,to:t.to})})}),n.sort((e,t)=>e.from-t.from);let r=[];if(n.length>0){let e=[n[0]],t=n[0].to;for(let i=1;ir.add(e.trackIndex));let i=new Map;n.forEach(e=>{let t=U(e.edgeIndex);i.set(e.trackIndex,(i.get(e.trackIndex)??0)+t.delta)});let a=[...r].filter(e=>(i.get(e)??0)<-1),o=[...r].filter(e=>(i.get(e)??0)>1),s=[...r].filter(e=>Math.abs(i.get(e)??0)<=1);a.sort((e,t)=>(i.get(t)??0)-(i.get(e)??0)),o.sort((e,t)=>(i.get(e)??0)-(i.get(t)??0));let c=t((t,r)=>{n.filter(e=>e.trackIndex===t).forEach(t=>{let n=_.has(t.edgeIndex)?e.coord:r;ce.set(`${t.edgeIndex}-${t.segmentIndex}`,n)})},`assignCoord`),l=0;for(let t of a)l++,c(t,e.coord-l*Nn);if(s.length===0&&r.size>0){let e=[...r].sort((e,t)=>Math.abs(i.get(e)??0)-Math.abs(i.get(t)??0))[0],t=a.indexOf(e);t!==-1&&a.splice(t,1);let n=o.indexOf(e);n!==-1&&o.splice(n,1),s.push(e)}let u=0;for(let t of s){if(u===0)c(t,e.coord);else{let n=u%2==1?1:-1,r=Math.ceil(u/2);c(t,e.coord+n*r*Nn*.5)}u++}let d=0;for(let t of o)d++,c(t,e.coord+d*Nn)}}for(let[e,t]of a.entries()){let n=g[e]??[];if(n.length===0)continue;let r=[],{pSrcPort:i,pDstPort:a}=ee(e,o.get(t.start),o.get(t.end)),s=n.map(e=>{let t=h[e],n=ce.get(`${t.edgeIndex}-${t.segmentIndex}`)??t.pipe.coord;return{orient:t.orientation,coord:n,from:t.from,to:t.to}});r.push(i);for(let e=0;e$&&r.push(In(t,i)),c&&o.orient===t.orient){if(Math.abs(t.coord-o.coord)>$){let e=t.orient===`vertical`?(i+o.from)/2:Fn(t,o);r.push(In(t,e),In(o,e))}else(e===0||e===s.length-2)&&r.push(In(t,Fn(t,o)))}else if(c)r.push(In(t,o.coord));else{let e=Math.abs(t.from-i)$||Math.abs(c.y-a.y)>$)&&r.push(a);let l=[];r.length>0&&l.push(r[0]);for(let e=1;e$||Math.abs(t.y-n.y)>$)&&l.push(t)}t.points=l}for(let e of a){let t=e.__originalEdge;t&&e.points&&(t.points=e.points)}e.edges=(e.edges??[]).filter(e=>!e.isLayoutOnly);let le=t((e,t)=>{let n=t.x??0,r=t.y??0,i=t.width??0,a=t.height??0;if(i<=0||a<=0)return e;let o=n-i/2,s=n+i/2,c=r-a/2,l=r+a/2;if(e.xs||e.yl)return e;let u=e.x-o,d=s-e.x,f=e.y-c,p=l-e.y,m=Math.min(u,d,f,p);return m===u?{x:o,y:e.y}:m===d?{x:s,y:e.y}:m===f?{x:e.x,y:c}:{x:e.x,y:l}},`nodeBoundaryClamp`);for(let t of e.edges){let e=t.points;if(!e||e.length<2)continue;let n=t.start,r=t.end,i=n?o.get(n):void 0,a=r?o.get(r):void 0;i&&(e[0]=le(e[0],i)),a&&(e[e.length-1]=le(e[e.length-1],a))}return e}t(Ln,`routeEdgesOrthogonal`);function Rn(e){return e.direction??`TB`}t(Rn,`getSwimlaneDirection`);function zn(e){let t=d(e),n=e.config.flowchart?.nodeSpacing??40,r=e.config.flowchart?.rankSpacing??100,i=e.config.swimlane?.ignoreCrossLaneEdges??!0,a=e.config.swimlane?.optimizeRanksByCrossings??!0,o=e.config.swimlane?.automaticLaneOrdering??!1,s=Rn(e),{ordered:c,coordinates:l}=Dn(t,{nodeGap:n,layerGap:r,ignoreCrossLaneEdges:i,optimizeRanksByCrossings:a,automaticLaneOrdering:o,direction:s});f(t,c,l,{nodeGap:n,layerGap:r});for(let t of e.edges??[])delete t.points;Ln(e,s);for(let t of e.edges??[])(!t.curve||t.curve===`basis`)&&(t.curve=`rounded`);return _t(e,s),gt(e),s}t(zn,`runSwimlaneLayoutCore`);function Bn(e){u(e);let t=m(e);e.nodes=t.nodes,e.edges=t.edges}t(Bn,`prepareSwimlaneLayout`);var Vn=n({prepareLayout:Bn,runLayoutCore:zn,afterPaint:i});export{Vn as render}; \ No newline at end of file diff --git a/frontend/dist/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js b/frontend/dist/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js new file mode 100644 index 0000000..710ec65 --- /dev/null +++ b/frontend/dist/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js @@ -0,0 +1,8 @@ +import"./src-D_iIdUkB.js";import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import"./chunk-GWA4HPMP-C1P4FmAY.js";import"./chunk-XXDRQBXY-C1_eEj17.js";import"./chunk-WEXAMYUT-I3m-hOmT.js";import{r as t,t as n}from"./chunk-7M6MHVWA-ZnPgs1Wx.js";var r=n({styles:e(e=>`${t(e)} + .swimlane.cluster:not([data-color-id]) rect { + stroke: ${e.clusterBorder} !important; + } + [data-look="neo"].cluster rect { + filter: none; + } +`,`getStyles`)});export{r as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js b/frontend/dist/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js new file mode 100644 index 0000000..2ceaaf2 --- /dev/null +++ b/frontend/dist/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js @@ -0,0 +1,120 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{Y as i,a,at as o,b as s,nt as c,o as l,rt as u,x as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as f}from"./arc-BJA87daU.js";import{p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as m,n as h}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{y as g}from"./index-DoQkmpth.js";var _=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,11,13,14,15,17,19,20,23,24],r=[1,12],i=[1,13],a=[1,14],o=[1,15],s=[1,16],c=[1,19],l=[1,20],u={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:`error`,6:`EOF`,7:`timeline`,8:`timeline_lr`,9:`timeline_td`,11:`SPACE`,13:`NEWLINE`,14:`title`,15:`acc_title`,16:`acc_title_value`,17:`acc_descr`,18:`acc_descr_value`,19:`acc_descr_multiline_value`,20:`section`,23:`period`,24:`event`},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 3:r.setDirection(`LR`);break;case 4:r.setDirection(`TD`);break;case 5:this.$=[];break;case 6:a[s-1].push(a[s]),this.$=a[s-1];break;case 7:case 8:this.$=a[s];break;case 9:case 10:this.$=[];break;case 11:r.getCommonDb().setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 12:this.$=a[s].trim(),r.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=a[s].trim(),r.getCommonDb().setAccDescription(this.$);break;case 15:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 18:r.addTask(a[s],0,``),this.$=a[s];break;case 19:r.addEvent(a[s].substr(2)),this.$=a[s]}},`anonymous`),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:r,15:i,17:a,19:o,20:s,21:17,22:18,23:c,24:l},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:r,15:i,17:a,19:o,20:s,21:17,22:18,23:c,24:l},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};u.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 13;case 3:break;case 4:break;case 5:return 8;case 6:return 9;case 7:return 7;case 8:return 14;case 9:return this.begin(`acc_title`),15;case 10:return this.popState(),`acc_title_value`;case 11:return this.begin(`acc_descr`),17;case 12:return this.popState(),`acc_descr_value`;case 13:this.begin(`acc_descr_multiline`);break;case 14:this.popState();break;case 15:return`acc_descr_multiline_value`;case 16:return 20;case 17:return 24;case 18:return 23;case 19:return 6;case 20:return`INVALID`}},`anonymous`),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:timeline[ \t]+LR\b)/i,/^(?:timeline[ \t]+TD\b)/i,/^(?:timeline\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^:\n]+)/i,/^(?::\s(?:[^:\n]|:(?!\s))+)/i,/^(?:[^#:\n]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[14,15],inclusive:!1},acc_descr:{rules:[12],inclusive:!1},acc_title:{rules:[10],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,13,16,17,18,19,20],inclusive:!0}}}})();function d(){this.yy={}}return n(d,`Parser`),d.prototype=u,u.Parser=d,new d})();_.parser=_;var v=_,y={};r(y,{addEvent:()=>P,addSection:()=>A,addTask:()=>N,addTaskOrg:()=>F,clear:()=>D,default:()=>ee,getCommonDb:()=>E,getDirection:()=>k,getSections:()=>j,getTasks:()=>M,setDirection:()=>O});var b=``,x=0,S=`LR`,C=[],w=[],T=[],E=n(()=>l,`getCommonDb`),D=n(function(){C.length=0,w.length=0,b=``,T.length=0,S=`LR`,a()},`clear`),O=n(function(e){S=e},`setDirection`),k=n(function(){return S},`getDirection`),A=n(function(e){b=e,C.push(e)},`addSection`),j=n(function(){return C},`getSections`),M=n(function(){let e=I(),t=0;for(;!e&&t<100;)e=I(),t++;return w.push(...T),w},`getTasks`),N=n(function(e,t,n){let r={id:x++,section:b,type:b,task:e,score:t||0,events:n?[n]:[]};T.push(r)},`addTask`),P=n(function(e){T.find(e=>e.id===x-1).events.push(e)},`addEvent`),F=n(function(e){let t={section:b,type:b,description:e,task:e,classes:[]};w.push(t)},`addTaskOrg`),I=n(function(){let e=n(function(e){return T[e].processed},`compileTask`),t=!0;for(let[n,r]of T.entries())e(n),t&&=r.processed;return t},`compileTasks`),ee={clear:D,getCommonDb:E,getDirection:k,setDirection:O,addSection:A,getSections:j,getTasks:M,addTask:N,addTaskOrg:F,addEvent:P},L=0,R=n(function(e,t){let n=e.append(`rect`);return n.attr(`x`,t.x),n.attr(`y`,t.y),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`width`,t.width),n.attr(`height`,t.height),n.attr(`rx`,t.rx),n.attr(`ry`,t.ry),t.class!==void 0&&n.attr(`class`,t.class),n},`drawRect`),te=n(function(e,t){let r=e.append(`circle`).attr(`cx`,t.cx).attr(`cy`,t.cy).attr(`class`,`face`).attr(`r`,15).attr(`stroke-width`,2).attr(`overflow`,`visible`),i=e.append(`g`);i.append(`circle`).attr(`cx`,t.cx-5).attr(`cy`,t.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`),i.append(`circle`).attr(`cx`,t.cx+5).attr(`cy`,t.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`);function a(e){let n=f().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,n).attr(`transform`,`translate(`+t.cx+`,`+(t.cy+2)+`)`)}n(a,`smile`);function o(e){let n=f().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,n).attr(`transform`,`translate(`+t.cx+`,`+(t.cy+7)+`)`)}n(o,`sad`);function s(e){e.append(`line`).attr(`class`,`mouth`).attr(`stroke`,2).attr(`x1`,t.cx-5).attr(`y1`,t.cy+7).attr(`x2`,t.cx+5).attr(`y2`,t.cy+7).attr(`class`,`mouth`).attr(`stroke-width`,`1px`).attr(`stroke`,`#666`)}return n(s,`ambivalent`),t.score>3?a(i):t.score<3?o(i):s(i),r},`drawFace`),ne=n(function(e,t){let n=e.append(`circle`);return n.attr(`cx`,t.cx),n.attr(`cy`,t.cy),n.attr(`class`,`actor-`+t.pos),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`r`,t.r),n.class!==void 0&&n.attr(`class`,n.class),t.title!==void 0&&n.append(`title`).text(t.title),n},`drawCircle`),z=n(function(e,t){let n=t.text.replace(//gi,` `),r=e.append(`text`);r.attr(`x`,t.x),r.attr(`y`,t.y),r.attr(`class`,`legend`),r.style(`text-anchor`,t.anchor),t.class!==void 0&&r.attr(`class`,t.class);let i=r.append(`tspan`);return i.attr(`x`,t.x+t.textMargin*2),i.text(n),r},`drawText`),re=n(function(e,t){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}n(r,`genPoints`);let i=e.append(`polygon`);i.attr(`points`,r(t.x,t.y,50,20,7)),i.attr(`class`,`labelBox`),t.y+=t.labelMargin,t.x+=.5*t.labelMargin,z(e,t)},`drawLabel`),ie=n(function(e,t,n){let r=e.append(`g`),i=V();i.x=t.x,i.y=t.y,i.fill=t.fill,i.width=n.width,i.height=n.height,i.class=`journey-section section-type-`+t.num,i.rx=3,i.ry=3,R(r,i),H(n)(t.text,r,i.x,i.y,i.width,i.height,{class:`journey-section section-type-`+t.num},n,t.colour)},`drawSection`),B=-1,ae=n(function(e,t,n,r){let i=t.x+n.width/2,a=e.append(`g`);B++,a.append(`line`).attr(`id`,r+`-task`+B).attr(`x1`,i).attr(`y1`,t.y).attr(`x2`,i).attr(`y2`,450).attr(`class`,`task-line`).attr(`stroke-width`,`1px`).attr(`stroke-dasharray`,`4 2`).attr(`stroke`,`#666`),te(a,{cx:i,cy:300+(5-t.score)*30,score:t.score});let o=V();o.x=t.x,o.y=t.y,o.fill=t.fill,o.width=n.width,o.height=n.height,o.class=`task task-type-`+t.num,o.rx=3,o.ry=3,R(a,o),H(n)(t.task,a,o.x,o.y,o.width,o.height,{class:`task`},n,t.colour)},`drawTask`),oe=n(function(e,t){R(e,{x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,class:`rect`}).lower()},`drawBackgroundRect`),se=n(function(){return{x:0,y:0,fill:void 0,"text-anchor":`start`,width:100,height:100,textMargin:0,rx:0,ry:0}},`getTextObj`),V=n(function(){return{x:0,y:0,width:100,anchor:`start`,height:100,rx:0,ry:0}},`getNoteRect`),H=(function(){function e(e,t,n,r,a,o,s,c){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`font-color`,c).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,a,o,s,c,l){let{taskFontSize:u,taskFontFamily:d}=c,f=e.split(//gi);for(let e=0;e)/).reverse(),i,a=[],o=1.1,s=e.attr(`y`),c=parseFloat(e.attr(`dy`)),l=e.text(null).append(`tspan`).attr(`x`,0).attr(`y`,s).attr(`dy`,c+`em`);for(let t=0;tn||i===`
    `)&&(a.pop(),l.text(a.join(` `).trim()),a=i===`
    `?[``]:[i],l=e.append(`tspan`).attr(`x`,0).attr(`y`,s).attr(`dy`,o+`em`).text(i))})}n(U,`wrap`);var le=n(function(e,n,r,i,a,o=!1){let{theme:s,look:c}=i,l=s?.includes(`redux`),u=r%(i?.themeVariables?.THEME_COLOR_LIMIT??12)-1,d=e.append(`g`);n.section=u,d.attr(`class`,(n.class?n.class+` `:``)+`timeline-node `+(`section-`+u));let f=d.append(`g`),p=d.append(`g`),m=p.append(`text`).text(n.descr).attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).call(U,n.width).node().getBBox(),h=i.fontSize?.replace?i.fontSize.replace(`px`,``):i.fontSize;if(n.height=m.height+h*1.1*.5+n.padding,n.height=Math.max(n.height,n.maxHeight),n.width+=2*n.padding,p.attr(`transform`,`translate(`+n.width/2+`, `+n.padding/2+`)`),l&&p.attr(`transform`,`translate(${n.width/2}, ${o?n.padding/2+3:n.padding})`),de(f,n,u,a,i),c===`neo`&&(d.attr(`data-look`,`neo`),l)){let n=s.includes(`dark`),r=e.node()?.ownerSVGElement??e.node(),i=t(r),a=i.attr(`id`)??``,o=a?`${a}-drop-shadow`:`drop-shadow`;if(i.select(`#${o}`).empty()){let e=i.select(`defs`);(e.empty()?i.append(`defs`):e).append(`filter`).attr(`id`,o).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,n?`0.2`:`0.06`).attr(`flood-color`,n?`#FFFFFF`:`#000000`)}}return n},`drawNode`),ue=n(function(e,t,n){let r=e.append(`g`),i=r.append(`text`).text(t.descr).attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).call(U,t.width).node().getBBox(),a=n.fontSize?.replace?n.fontSize.replace(`px`,``):n.fontSize;return r.remove(),i.height+a*1.1*.5+t.padding},`getVirtualNodeHeight`),de=n(function(e,t,n,r,i){let{theme:a}=i,o=a?.includes(`redux`)?0:5,s=o>0?`M0 ${t.height-5} v${-t.height+10} q0,-${o},${o},-${o} h${t.width-10} q${o},0,${o},${o} v${t.height-5} H0 Z`:`M0 ${t.height-5} v${-(t.height-5)} h${t.width} v${t.height} H0 Z`;e.append(`path`).attr(`id`,r+`-node-`+L++).attr(`class`,`node-bkg node-`+t.type).attr(`d`,s),a?.includes(`redux`)||e.append(`line`).attr(`class`,`node-line-`+n).attr(`x1`,0).attr(`y1`,t.height).attr(`x2`,t.width).attr(`y2`,t.height)},`defaultBkg`),W={drawRect:R,drawCircle:ne,drawSection:ie,drawText:z,drawLabel:re,drawTask:ae,drawBackgroundRect:oe,getTextObj:se,getNoteRect:V,initGraphics:ce,drawNode:le,getVirtualNodeHeight:ue},fe=n(function(n,r,a,o){let s=d(),{look:c,theme:l,themeVariables:u}=s,{useGradient:f,gradientStart:p,gradientStop:m}=u,h=s.timeline?.leftMargin??50;e.debug(`timeline`,o.db);let g=s.securityLevel,_;g===`sandbox`&&(_=t(`#i`+r));let v=t(g===`sandbox`?_.nodes()[0].contentDocument.body:`body`).select(`#`+r);v.append(`g`);let y=o.db.getTasks(),b=o.db.getCommonDb().getDiagramTitle();e.debug(`task`,y),W.initGraphics(v,r);let x=o.db.getSections();e.debug(`sections`,x);let S=0,C=0,w=0,T=0,E=50+h,D=50;T=50;let O=0,k=!0;x.forEach(function(t){let n={number:O,descr:t,section:O,width:150,padding:20,maxHeight:S},r=W.getVirtualNodeHeight(v,n,s);e.debug(`sectionHeight before draw`,r),S=Math.max(S,r+20)});let A=0,j=0;e.debug(`tasks.length`,y.length);for(let[t,n]of y.entries()){let r={number:t,descr:n,section:n.section,width:150,padding:20,maxHeight:C},i=W.getVirtualNodeHeight(v,r,s);e.debug(`taskHeight before draw`,i),C=Math.max(C,i+20),A=Math.max(A,n.events.length);let a=0;for(let e of n.events){let t={descr:e,section:n.section,number:n.section,width:150,padding:20,maxHeight:50};a+=W.getVirtualNodeHeight(v,t,s)}n.events.length>0&&(a+=(n.events.length-1)*10),j=Math.max(j,a)}e.debug(`maxSectionHeight before draw`,S),e.debug(`maxTaskHeight before draw`,C),x&&x.length>0?x.forEach(t=>{let n=y.filter(e=>e.section===t),i={number:O,descr:t,section:O,width:200*Math.max(n.length,1)-50,padding:20,maxHeight:S};e.debug(`sectionNode`,i);let a=v.append(`g`),o=W.drawNode(a,i,O,s,r);e.debug(`sectionNode output`,o),a.attr(`transform`,`translate(${E}, ${T})`),D+=S+50,n.length>0&&G(v,n,O,E,D,C,s,A,j,S,!1,r),E+=200*Math.max(n.length,1),D=T,O++}):(k=!1,G(v,y,O,E,D,C,s,A,j,S,!0,r));let M=v.node().getBBox();if(e.debug(`bounds`,M),b&&v.append(`text`).text(b).attr(`x`,c===`neo`?M.x*2+h:M.width/2-h).attr(`font-size`,`4ex`).attr(`font-weight`,`bold`).attr(`y`,20),w=k?S+C+150:C+100,v.append(`g`).attr(`class`,`lineWrapper`).append(`line`).attr(`x1`,h).attr(`y1`,w).attr(`x2`,M.width+3*h).attr(`y2`,w).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#${r}-arrowhead)`),c===`neo`&&f&&l!==`neutral`){let e=v.select(`defs`),t=(e.empty()?v.append(`defs`):e).append(`linearGradient`).attr(`id`,v.attr(`id`)+`-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);t.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,p).attr(`stop-opacity`,1),t.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,m).attr(`stop-opacity`,1)}i(void 0,v,s.timeline?.padding??50,s.timeline?.useMaxWidth??!1)},`draw`),G=n(function(t,n,r,i,a,o,s,c,l,u,d,f){for(let c of n){let n={descr:c.task,section:r,number:r,width:150,padding:20,maxHeight:o};e.debug(`taskNode`,n);let u=t.append(`g`).attr(`class`,`taskWrapper`),p=W.drawNode(u,n,r,s,f).height;if(e.debug(`taskHeight after draw`,p),u.attr(`transform`,`translate(${i}, ${a})`),o=Math.max(o,p),c.events){let e=t.append(`g`).attr(`class`,`lineWrapper`),n=o;a+=100,n+=pe(t,c.events,r,i,a,s,f),a-=100,e.append(`line`).attr(`x1`,i+95).attr(`y1`,a+o).attr(`x2`,i+95).attr(`y2`,a+o+100+l+100).attr(`stroke-width`,2).attr(`stroke`,`black`).attr(`marker-end`,`url(#${f}-arrowhead)`).attr(`stroke-dasharray`,`5,5`)}i+=200,d&&!s.timeline?.disableMulticolor&&r++}a-=10},`drawTasks`),pe=n(function(t,n,r,i,a,o,s){let c=0,l=a;a+=100;for(let l of n){let n={descr:l,section:r,number:r,width:150,padding:20,maxHeight:50};e.debug(`eventNode`,n);let u=t.append(`g`).attr(`class`,`eventWrapper`),d=W.drawNode(u,n,r,o,s,!0).height;c+=d,u.attr(`transform`,`translate(${i}, ${a})`),a=a+10+d}return a=l,c},`drawEvents`),me={setConf:n(()=>{},`setConf`),draw:fe},K=200,q=5,he=K+q*2,J=K+100,ge=J+q*2,Y=10,_e=0,X=20,Z=20,Q=30,$=50,ve=n(function(t,n,r,a){let o=d(),s=o.timeline?.leftMargin??50;e.debug(`timeline`,a.db);let c=g(n);c.append(`g`);let l=a.db.getTasks(),u=a.db.getCommonDb().getDiagramTitle();e.debug(`task`,l),W.initGraphics(c);let f=a.db.getSections();e.debug(`sections`,f);let m=0,h=0,_=50+s,v=50,y=v,b=_,x=he+Z,S=ge+$,C=b+x,w=0,T=f&&f.length>0,E=T?C:_+x,D=Math.max(50,x+S-q*2);f.forEach(function(t){let n={number:w,descr:t,section:w,width:D,padding:q,maxHeight:m},r=W.getVirtualNodeHeight(c,n,o);e.debug(`sectionHeight before draw`,r),m=Math.max(m,r)});let O=0;e.debug(`tasks.length`,l.length);for(let[t,n]of l.entries()){let r={number:t,descr:n,section:n.section,width:K,padding:q,maxHeight:h},i=W.getVirtualNodeHeight(c,r,o);e.debug(`taskHeight before draw`,i),h=Math.max(h,i);let a=0;for(let e of n.events){let t={descr:e,section:n.section,number:n.section,width:J,padding:q,maxHeight:50};a+=W.getVirtualNodeHeight(c,t,o)}n.events.length>0&&(a+=(n.events.length-1)*Y),O=Math.max(O,a)+_e}e.debug(`maxSectionHeight before draw`,m),e.debug(`maxTaskHeight before draw`,h);let k=Math.max(h,O)+Q;T?f.forEach(t=>{let n=l.filter(e=>e.section===t),r={number:w,descr:t,section:w,width:D,padding:q,maxHeight:m};e.debug(`sectionNode`,r);let i=c.append(`g`),a=W.drawNode(i,r,w,o);e.debug(`sectionNode output`,a);let s=E-x;i.attr(`transform`,`translate(${s}, ${v})`);let u=v+a.height+X;n.length>0&&ye(c,n,w,E,u,h,o,k,!1);let d=n.length,f=a.height+X+k*Math.max(d,1)-(d>0?Q*2:0);v+=f,w++}):ye(c,l,w,E,v,h,o,k,!0);let A=c.node()?.getBBox();if(!A)throw Error(`bbox not found`);if(e.debug(`bounds`,A),u){if(c.append(`text`).text(u).attr(`x`,A.width/2-s).attr(`font-size`,`4ex`).attr(`font-weight`,`bold`).attr(`y`,20),A=c.node()?.getBBox(),!A)throw Error(`bbox not found`);e.debug(`bounds after title`,A)}let[j]=p(o.fontSize),M=(j??16)*2,N=(j??16)*.5+20,P=c.append(`g`).attr(`class`,`lineWrapper`);P.append(`line`).attr(`x1`,E).attr(`y1`,y-M).attr(`x2`,E).attr(`y2`,A.y+A.height+N).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#arrowhead)`),P.lower(),i(void 0,c,o.timeline?.padding??50,o.timeline?.useMaxWidth??!1)},`draw`),ye=n(function(t,n,r,i,a,o,s,c,l){for(let u of n){let n={descr:u.task,section:r,number:r,width:K,padding:q,maxHeight:o};e.debug(`taskNode`,n);let d=t.append(`g`).attr(`class`,`taskWrapper`),f=W.drawNode(d,n,r,s),p=f.height;e.debug(`taskHeight after draw`,p);let m=i-Z-f.width;if(d.attr(`transform`,`translate(${m}, ${a})`),o=Math.max(o,p),u.events&&u.events.length>0){let e=a,n=i+$;be(t,u.events,r,i,n,e,s)}a+=c,l&&!s.timeline?.disableMulticolor&&r++}},`drawTasks`),be=n(function(t,n,r,i,a,o,s){let c=o;for(let o of n){let n={descr:o,section:r,number:r,width:J,padding:q,maxHeight:0};e.debug(`eventNode`,n);let l=t.append(`g`).attr(`class`,`eventWrapper`),u=W.drawNode(l,n,r,s).height;l.attr(`transform`,`translate(${a}, ${c})`);let d=t.append(`g`).attr(`class`,`lineWrapper`),f=c+u/2;d.append(`line`).attr(`x1`,i).attr(`y1`,f).attr(`x2`,a).attr(`y2`,f).attr(`stroke-width`,2).attr(`stroke`,`black`).attr(`marker-end`,`url(#arrowhead)`).attr(`stroke-dasharray`,`5,5`),c=c+u+Y}return c-o},`drawEvents`),xe={setConf:n(()=>{},`setConf`),draw:ve},Se=n(e=>{let{theme:t}=s(),n=t?.includes(`dark`),r=m(t,e.borderColorArray),i=e.svgId?.replace(/^#/,``)??``,a=i?`url(#${i}-drop-shadow)`:e.dropShadow??`none`,o=``;for(let t=0;t{let t=``,n=h(e.THEME_COLOR_LIMIT);for(let t=0;t{},`setConf`),draw:n((e,t,n,r)=>(r?.db?.getDirection?.()??`LR`)===`TD`?xe.draw(e,t,n,r):me.draw(e,t,n,r),`draw`)},parser:v,styles:n(e=>{let{theme:t}=s(),n=t?.includes(`redux`),r=t===`neutral`,i=e.svgId?.replace(/^#/,``)??``,a=``;if(e.useGradient&&i&&e.THEME_COLOR_LIMIT&&!r){let t=h(e.THEME_COLOR_LIMIT);for(let n=0;ni?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r=Xe&&(a=De,o=!1,t=new Ee(t));outer:for(;++i-1:!!i&&le(e,t,n)>-1}var st=Math.max;function ct(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:Oe(n);return i<0&&(i=st(r+i,0)),le(e,t,i)}var lt=`[object RegExp]`;function ut(e){return me(e)&&ge(e)==lt}var dt=ue&&ue.isRegExp,ft=dt?oe(dt):ut,pt=`Expected a function`;function mt(e){if(typeof e!=`function`)throw TypeError(pt);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function ht(e,t){if(e==null)return{};var n=ve(Me(e),function(e){return[e]});return t=_e(t),Le(e,n,function(e,n){return t(e,n[0])})}function gt(e,t){return(S(e)?ce:Se)(e,mt(_e(t,3)))}function _t(e,t){var n;return he(e,function(e,r,i){return n=t(e,r,i),!n}),!!n}function vt(e,t,n){var r=S(e)?fe:_t;return n&&Re(e,t,n)&&(t=void 0),r(e,_e(t,3))}function yt(e){return e&&e.length?we(e):[]}function bt(e){console&&console.error&&console.error(`Error: ${e}`)}function xt(e){console&&console.warn&&console.warn(`Warning: ${e}`)}function St(e){let t=new Date().getTime(),n=e();return{time:new Date().getTime()-t,value:n}}function Ct(e){function t(){}t.prototype=e;let n=new t;function r(){return typeof n.bar}return r(),r(),e}function wt(e){return Tt(e)?e.LABEL:e.name}function Tt(e){return O(e.LABEL)&&e.LABEL!==``}var Et=class{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),x(this.definition,t=>{t.accept(e)})}},F=class extends Et{constructor(e){super([]),this.idx=1,A(this,ht(e,e=>e!==void 0))}set definition(e){}get definition(){return this.referencedRule===void 0?[]:this.referencedRule.definition}accept(e){e.visit(this)}},Dt=class extends Et{constructor(e){super(e.definition),this.orgText=``,A(this,ht(e,e=>e!==void 0))}},I=class extends Et{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,A(this,ht(e,e=>e!==void 0))}},L=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},Ot=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},kt=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},R=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},At=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},jt=class extends Et{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,A(this,ht(e,e=>e!==void 0))}},z=class{constructor(e){this.idx=1,A(this,ht(e,e=>e!==void 0))}accept(e){e.visit(this)}};function Mt(e){return D(e,Nt)}function Nt(e){function t(e){return D(e,Nt)}if(e instanceof F){let t={type:`NonTerminal`,name:e.nonTerminalName,idx:e.idx};return O(e.label)&&(t.label=e.label),t}if(e instanceof I)return{type:`Alternative`,definition:t(e.definition)};if(e instanceof L)return{type:`Option`,idx:e.idx,definition:t(e.definition)};if(e instanceof Ot)return{type:`RepetitionMandatory`,idx:e.idx,definition:t(e.definition)};if(e instanceof kt)return{type:`RepetitionMandatoryWithSeparator`,idx:e.idx,separator:Nt(new z({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof At)return{type:`RepetitionWithSeparator`,idx:e.idx,separator:Nt(new z({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof R)return{type:`Repetition`,idx:e.idx,definition:t(e.definition)};if(e instanceof jt)return{type:`Alternation`,idx:e.idx,definition:t(e.definition)};if(e instanceof z){let t={type:`Terminal`,name:e.terminalType.name,label:wt(e.terminalType),idx:e.idx};O(e.label)&&(t.terminalLabel=e.label);let n=e.terminalType.PATTERN;return e.terminalType.PATTERN&&(t.pattern=ft(n)?n.source:n),t}if(e instanceof Dt)return{type:`Rule`,name:e.name,orgText:e.orgText,definition:t(e.definition)};throw Error(`non exhaustive match`)}var Pt=class{visit(e){let t=e;switch(t.constructor){case F:return this.visitNonTerminal(t);case I:return this.visitAlternative(t);case L:return this.visitOption(t);case Ot:return this.visitRepetitionMandatory(t);case kt:return this.visitRepetitionMandatoryWithSeparator(t);case At:return this.visitRepetitionWithSeparator(t);case R:return this.visitRepetition(t);case jt:return this.visitAlternation(t);case z:return this.visitTerminal(t);case Dt:return this.visitRule(t);default:throw Error(`non exhaustive match`)}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}};function Ft(e){return e instanceof I||e instanceof L||e instanceof R||e instanceof Ot||e instanceof kt||e instanceof At||e instanceof z||e instanceof Dt}function It(e,t=[]){return e instanceof L||e instanceof R||e instanceof At?!0:e instanceof jt?vt(e.definition,e=>It(e,t)):e instanceof F&&P(t,e)?!1:e instanceof Et&&(e instanceof F&&t.push(e),nt(e.definition,e=>It(e,t)))}function Lt(e){return e instanceof jt}function Rt(e){if(e instanceof F)return`SUBRULE`;if(e instanceof L)return`OPTION`;if(e instanceof jt)return`OR`;if(e instanceof Ot)return`AT_LEAST_ONE`;if(e instanceof kt)return`AT_LEAST_ONE_SEP`;if(e instanceof At)return`MANY_SEP`;if(e instanceof R)return`MANY`;if(e instanceof z)return`CONSUME`;throw Error(`non exhaustive match`)}var zt=class{walk(e,t=[]){x(e.definition,(n,r)=>{let i=M(e.definition,r+1);if(n instanceof F)this.walkProdRef(n,i,t);else if(n instanceof z)this.walkTerminal(n,i,t);else if(n instanceof I)this.walkFlat(n,i,t);else if(n instanceof L)this.walkOption(n,i,t);else if(n instanceof Ot)this.walkAtLeastOne(n,i,t);else if(n instanceof kt)this.walkAtLeastOneSep(n,i,t);else if(n instanceof At)this.walkManySep(n,i,t);else if(n instanceof R)this.walkMany(n,i,t);else if(n instanceof jt)this.walkOr(n,i,t);else throw Error(`non exhaustive match`)})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){let r=t.concat(n);this.walk(e,r)}walkOption(e,t,n){let r=t.concat(n);this.walk(e,r)}walkAtLeastOne(e,t,n){let r=[new L({definition:e.definition})].concat(t,n);this.walk(e,r)}walkAtLeastOneSep(e,t,n){let r=Bt(e,t,n);this.walk(e,r)}walkMany(e,t,n){let r=[new L({definition:e.definition})].concat(t,n);this.walk(e,r)}walkManySep(e,t,n){let r=Bt(e,t,n);this.walk(e,r)}walkOr(e,t,n){let r=t.concat(n);x(e.definition,e=>{let t=new I({definition:[e]});this.walk(t,r)})}};function Bt(e,t,n){return[new L({definition:[new z({terminalType:e.separator})].concat(e.definition)})].concat(t,n)}function Vt(e){if(e instanceof F)return Vt(e.referencedRule);if(e instanceof z)return Wt(e);if(Ft(e))return Ht(e);if(Lt(e))return Ut(e);throw Error(`non exhaustive match`)}function Ht(e){let t=[],n=e.definition,r=0,i=n.length>r,a,o=!0;for(;i&&o;)a=n[r],o=It(a),t=t.concat(Vt(a)),r+=1,i=n.length>r;return yt(t)}function Ut(e){let t=D(e.definition,e=>Vt(e));return yt(Ne(t))}function Wt(e){return[e.terminalType]}var Gt=`_~IN~_`,Kt=class extends zt{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){let r=Jt(e.referencedRule,e.idx)+this.topProd.name,i=Vt(new I({definition:t.concat(n)}));this.follows[r]=i}};function qt(e){let t={};return x(e,e=>{let n=new Kt(e).startWalking();A(t,n)}),t}function Jt(e,t){return e.name+t+Gt}function B(e){return e.charCodeAt(0)}function Yt(e,t){Array.isArray(e)?e.forEach(function(e){t.push(e)}):t.push(e)}function Xt(e,t){if(e[t]===!0)throw`duplicate flag `+t;e[t],e[t]=!0}function Zt(e){if(e===void 0)throw Error(`Internal Error - Should never get here!`);return!0}function Qt(){throw Error(`Internal Error - Should never get here!`)}function $t(e){return e.type===`Character`}var en=[];for(let e=B(`0`);e<=B(`9`);e++)en.push(e);var tn=[B(`_`)].concat(en);for(let e=B(`a`);e<=B(`z`);e++)tn.push(e);for(let e=B(`A`);e<=B(`Z`);e++)tn.push(e);var nn=[B(` `),B(`\f`),B(` +`),B(`\r`),B(` `),B(`\v`),B(` `),B(`\xA0`),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(`\u2028`),B(`\u2029`),B(` `),B(` `),B(` `),B(``)],rn=/[0-9a-fA-F]/,an=/[0-9]/,on=/[1-9]/,sn=class{constructor(){this.idx=0,this.input=``,this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar(`/`);let t=this.disjunction();this.consumeChar(`/`);let n={type:`Flags`,loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case`g`:Xt(n,`global`);break;case`i`:Xt(n,`ignoreCase`);break;case`m`:Xt(n,`multiLine`);break;case`u`:Xt(n,`unicode`);break;case`y`:Xt(n,`sticky`)}if(this.idx!==this.input.length)throw Error(`Redundant input: `+this.input.substring(this.idx));return{type:`Pattern`,flags:n,value:t,loc:this.loc(0)}}disjunction(){let e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()===`|`;)this.consumeChar(`|`),e.push(this.alternative());return{type:`Disjunction`,value:e,loc:this.loc(t)}}alternative(){let e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:`Alternative`,value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let e=this.idx;switch(this.popChar()){case`^`:return{type:`StartAnchor`,loc:this.loc(e)};case`$`:return{type:`EndAnchor`,loc:this.loc(e)};case`\\`:switch(this.popChar()){case`b`:return{type:`WordBoundary`,loc:this.loc(e)};case`B`:return{type:`NonWordBoundary`,loc:this.loc(e)}}throw Error(`Invalid Assertion Escape`);case`(`:this.consumeChar(`?`);let t;switch(this.popChar()){case`=`:t=`Lookahead`;break;case`!`:t=`NegativeLookahead`;break;case`<`:switch(this.popChar()){case`=`:t=`Lookbehind`;break;case`!`:t=`NegativeLookbehind`}}Zt(t);let n=this.disjunction();return this.consumeChar(`)`),{type:t,value:n,loc:this.loc(e)}}return Qt()}quantifier(e=!1){let t,n=this.idx;switch(this.popChar()){case`*`:t={atLeast:0,atMost:1/0};break;case`+`:t={atLeast:1,atMost:1/0};break;case`?`:t={atLeast:0,atMost:1};break;case`{`:let n=this.integerIncludingZero();switch(this.popChar()){case`}`:t={atLeast:n,atMost:n};break;case`,`:let e;this.isDigit()?(e=this.integerIncludingZero(),t={atLeast:n,atMost:e}):t={atLeast:n,atMost:1/0},this.consumeChar(`}`)}if(e===!0&&t===void 0)return;Zt(t)}if((e!==!0||t!==void 0)&&Zt(t))return this.peekChar(0)===`?`?(this.consumeChar(`?`),t.greedy=!1):t.greedy=!0,t.type=`Quantifier`,t.loc=this.loc(n),t}atom(){let e,t=this.idx;switch(this.peekChar()){case`.`:e=this.dotAll();break;case`\\`:e=this.atomEscape();break;case`[`:e=this.characterClass();break;case`(`:e=this.group()}return e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),Zt(e)?(e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e):Qt()}dotAll(){return this.consumeChar(`.`),{type:`Set`,complement:!0,value:[B(` +`),B(`\r`),B(`\u2028`),B(`\u2029`)]}}atomEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`1`:case`2`:case`3`:case`4`:case`5`:case`6`:case`7`:case`8`:case`9`:return this.decimalEscapeAtom();case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:`GroupBackReference`,value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case`d`:e=en;break;case`D`:e=en,t=!0;break;case`s`:e=nn;break;case`S`:e=nn,t=!0;break;case`w`:e=tn;break;case`W`:e=tn,t=!0}return Zt(e)?{type:`Set`,value:e,complement:t}:Qt()}controlEscapeAtom(){let e;switch(this.popChar()){case`f`:e=B(`\f`);break;case`n`:e=B(` +`);break;case`r`:e=B(`\r`);break;case`t`:e=B(` `);break;case`v`:e=B(`\v`)}return Zt(e)?{type:`Character`,value:e}:Qt()}controlLetterEscapeAtom(){this.consumeChar(`c`);let e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error(`Invalid `);return{type:`Character`,value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar(`0`),{type:`Character`,value:B(`\0`)}}hexEscapeSequenceAtom(){return this.consumeChar(`x`),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar(`u`),this.parseHexDigits(4)}identityEscapeAtom(){return{type:`Character`,value:B(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case` +`:case`\r`:case`\u2028`:case`\u2029`:case`\\`:case`]`:throw Error(`TBD`);default:return{type:`Character`,value:B(this.popChar())}}}characterClass(){let e=[],t=!1;for(this.consumeChar(`[`),this.peekChar(0)===`^`&&(this.consumeChar(`^`),t=!0);this.isClassAtom();){let t=this.classAtom();if(t.type,$t(t)&&this.isRangeDash()){this.consumeChar(`-`);let n=this.classAtom();if(n.type,$t(n)){if(n.value=this.input.length)throw Error(`Unexpected end of input`);this.idx++}loc(e){return{begin:e,end:this.idx}}},cn=class{visitChildren(e){for(let t in e){let n=e[t];e.hasOwnProperty(t)&&(n.type===void 0?Array.isArray(n)&&n.forEach(e=>{this.visit(e)},this):this.visit(n))}}visit(e){switch(e.type){case`Pattern`:this.visitPattern(e);break;case`Flags`:this.visitFlags(e);break;case`Disjunction`:this.visitDisjunction(e);break;case`Alternative`:this.visitAlternative(e);break;case`StartAnchor`:this.visitStartAnchor(e);break;case`EndAnchor`:this.visitEndAnchor(e);break;case`WordBoundary`:this.visitWordBoundary(e);break;case`NonWordBoundary`:this.visitNonWordBoundary(e);break;case`Lookahead`:this.visitLookahead(e);break;case`NegativeLookahead`:this.visitNegativeLookahead(e);break;case`Lookbehind`:this.visitLookbehind(e);break;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);break;case`Character`:this.visitCharacter(e);break;case`Set`:this.visitSet(e);break;case`Group`:this.visitGroup(e);break;case`GroupBackReference`:this.visitGroupBackReference(e);break;case`Quantifier`:this.visitQuantifier(e)}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},ln={},un=new sn;function dn(e){let t=e.toString();if(ln.hasOwnProperty(t))return ln[t];{let e=un.pattern(t);return ln[t]=e,e}}function fn(){ln={}}var pn=`Complement Sets are not supported for first char optimization`,mn=`Unable to use "first char" lexer optimizations: +`;function hn(e,t=!1){try{let t=dn(e);return gn(t.value,{},t.flags.ignoreCase)}catch(n){if(n.message===pn)t&&xt(`${mn}\tUnable to optimize: < ${e.toString()} >\n Complement Sets cannot be automatically optimized. + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n=``;t&&(n=` + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),bt(`${mn}\n\tFailed parsing: < ${e.toString()} >\n\tUsing the @chevrotain/regexp-to-ast library\n Please open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}function gn(e,t,n){switch(e.type){case`Disjunction`:for(let r=0;r{if(typeof e==`number`)_n(e,t,n);else{let r=e;if(n===!0)for(let e=r.from;e<=r.to;e++)_n(e,t,n);else{for(let e=r.from;e<=r.to&&e<256;e++)_n(e,t,n);if(r.to>=256){let e=r.from>=256?r.from:256,n=r.to,i=tr(e),a=tr(n);for(let e=i;e<=a;e++)t[e]=e}}}});break;case`Group`:gn(a.value,t,n);break;default:throw Error(`Non Exhaustive Match`)}let o=a.quantifier!==void 0&&a.quantifier.atLeast===0;if(a.type===`Group`&&bn(a)===!1||a.type!==`Group`&&o===!1)break}break;default:throw Error(`non exhaustive match!`)}return y(t)}function _n(e,t,n){let r=tr(e);t[r]=r,n===!0&&vn(e,t)}function vn(e,t){let n=String.fromCharCode(e),r=n.toUpperCase();if(r!==n){let e=tr(r.charCodeAt(0));t[e]=e}else{let e=n.toLowerCase();if(e!==n){let n=tr(e.charCodeAt(0));t[n]=n}}}function yn(e,t){return Fe(e.value,e=>{if(typeof e==`number`)return P(t,e);{let n=e;return Fe(t,e=>n.from<=e&&e<=n.to)!==void 0}})}function bn(e){let t=e.quantifier;return t&&t.atLeast===0?!0:e.value?S(e.value)?nt(e.value,bn):bn(e.value):!1}var xn=class extends cn{constructor(e){super(),this.targetCharCodes=e,this.found=!1}visitChildren(e){if(this.found!==!0){switch(e.type){case`Lookahead`:this.visitLookahead(e);return;case`NegativeLookahead`:this.visitNegativeLookahead(e);return;case`Lookbehind`:this.visitLookbehind(e);return;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);return}super.visitChildren(e)}}visitCharacter(e){P(this.targetCharCodes,e.value)&&(this.found=!0)}visitSet(e){e.complement?yn(e,this.targetCharCodes)===void 0&&(this.found=!0):yn(e,this.targetCharCodes)!==void 0&&(this.found=!0)}};function Sn(e,t){if(t instanceof RegExp){let n=dn(t),r=new xn(e);return r.visit(n),r.found}return Fe(t,t=>P(e,t.charCodeAt(0)))!==void 0}var Cn=`PATTERN`,wn=`defaultMode`;function Tn(e,t){t=je(t,{debug:!1,safeMode:!1,positionTracking:`full`,lineTerminatorCharacters:[`\r`,` +`],tracer:(e,t)=>t()});let n=t.tracer;n(`initCharCodeToOptimizedIndexMap`,()=>{nr()});let r;n(`Reject Lexer.NA`,()=>{r=gt(e,e=>e[Cn]===H.NA)});let i=!1,a;n(`Transform Patterns`,()=>{i=!1,a=D(r,e=>{let t=e[Cn];if(ft(t)){let e=t.source;return e.length===1&&e!==`^`&&e!==`$`&&e!==`.`&&!t.ignoreCase?e:e.length===2&&e[0]===`\\`&&!P([`d`,`D`,`s`,`S`,`t`,`r`,`n`,`t`,`0`,`c`,`b`,`B`,`f`,`v`,`w`,`W`],e[1])?e[1]:Un(t)}if(b(t))return i=!0,{exec:t};if(typeof t==`object`)return i=!0,t;if(typeof t==`string`){if(t.length===1)return t;{let e=t.replace(/[\\^$.*+?()[\]{}|]/g,`\\$&`);return Un(new RegExp(e))}}throw Error(`non exhaustive match`)})});let o,s,c,l,u;n(`misc mapping`,()=>{o=D(r,e=>e.tokenTypeIdx),s=D(r,e=>{let t=e.GROUP;if(t!==H.SKIPPED){if(O(t))return t;if(xe(t))return!1;throw Error(`non exhaustive match`)}}),c=D(r,e=>{let t=e.LONGER_ALT;if(t)return S(t)?D(t,e=>ct(r,e)):[ct(r,t)]}),l=D(r,e=>e.PUSH_MODE),u=D(r,e=>k(e,`POP_MODE`))});let d;n(`Line Terminator Handling`,()=>{let e=Qn(t.lineTerminatorCharacters);d=D(r,e=>!1),t.positionTracking!==`onlyOffset`&&(d=D(r,t=>k(t,`LINE_BREAKS`)?!!t.LINE_BREAKS:Xn(t,e)===!1&&Sn(e,t.PATTERN)))});let f,p,m,h;n(`Misc Mapping #2`,()=>{f=D(r,qn),p=D(a,Jn),m=T(r,(e,t)=>{let n=t.GROUP;return O(n)&&n!==H.SKIPPED&&(e[n]=[]),e},{}),h=D(a,(e,t)=>({pattern:a[t],longerAlt:c[t],canLineTerminator:d[t],isCustom:f[t],short:p[t],group:s[t],push:l[t],pop:u[t],tokenTypeIdx:o[t],tokenType:r[t]}))});let g=!0,ee=[];return t.safeMode||n(`First Char Optimization`,()=>{ee=T(r,(e,n,r)=>{if(typeof n.PATTERN==`string`)$n(e,tr(n.PATTERN.charCodeAt(0)),h[r]);else if(S(n.START_CHARS_HINT)){let t;x(n.START_CHARS_HINT,n=>{let i=tr(typeof n==`string`?n.charCodeAt(0):n);t!==i&&(t=i,$n(e,i,h[r]))})}else if(ft(n.PATTERN)){if(n.PATTERN.unicode)g=!1,t.ensureOptimizations&&bt(`${mn}\tUnable to analyze < ${n.PATTERN.toString()} > pattern.\n The regexp unicode flag is not currently supported by the regexp-to-ast library. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{let i=hn(n.PATTERN,t.ensureOptimizations);C(i)&&(g=!1),x(i,t=>{$n(e,t,h[r])})}}else t.ensureOptimizations&&bt(`${mn}\tTokenType: <${n.name}> is using a custom token pattern without providing parameter.\n This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),g=!1;return e},[])}),{emptyGroups:m,patternIdxToConfig:h,charCodeToPatternIdxToConfig:ee,hasCustom:i,canBeOptimized:g}}function En(e,t){let n=[],r=On(e);n=n.concat(r.errors);let i=kn(r.valid),a=i.valid;return n=n.concat(i.errors),n=n.concat(Dn(a)),n=n.concat(Ln(a)),n=n.concat(Rn(a,t)),n=n.concat(zn(a)),n}function Dn(e){let t=[],n=E(e,e=>ft(e[Cn]));return t=t.concat(jn(n)),t=t.concat(Pn(n)),t=t.concat(Fn(n)),t=t.concat(In(n)),t=t.concat(Mn(n)),t}function On(e){let t=E(e,e=>!k(e,Cn));return{errors:D(t,e=>({message:`Token Type: ->`+e.name+`<- missing static 'PATTERN' property`,type:V.MISSING_PATTERN,tokenTypes:[e]})),valid:Qe(e,t)}}function kn(e){let t=E(e,e=>{let t=e[Cn];return!ft(t)&&!b(t)&&!k(t,`exec`)&&!O(t)});return{errors:D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.`,type:V.INVALID_PATTERN,tokenTypes:[e]})),valid:Qe(e,t)}}var An=/[^\\][$]/;function jn(e){class t extends cn{constructor(){super(...arguments),this.found=!1}visitEndAnchor(e){this.found=!0}}let n=E(e,e=>{let n=e.PATTERN;try{let e=dn(n),r=new t;return r.visit(e),r.found}catch{return An.test(n.source)}});return D(n,e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain end of input anchor '$' + See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:V.EOI_ANCHOR_FOUND,tokenTypes:[e]}))}function Mn(e){let t=E(e,e=>e.PATTERN.test(``));return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' must not match an empty string`,type:V.EMPTY_MATCH_PATTERN,tokenTypes:[e]}))}var Nn=/[^\\[][\^]|^\^/;function Pn(e){class t extends cn{constructor(){super(...arguments),this.found=!1}visitStartAnchor(e){this.found=!0}}let n=E(e,e=>{let n=e.PATTERN;try{let e=dn(n),r=new t;return r.visit(e),r.found}catch{return Nn.test(n.source)}});return D(n,e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain start of input anchor '^' + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:V.SOI_ANCHOR_FOUND,tokenTypes:[e]}))}function Fn(e){let t=E(e,e=>{let t=e[Cn];return t instanceof RegExp&&(t.multiline||t.global)});return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' may NOT contain global('g') or multiline('m')`,type:V.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}))}function In(e){let t=[],n=D(e,n=>T(e,(e,r)=>n.PATTERN.source===r.PATTERN.source&&!P(t,r)&&r.PATTERN!==H.NA?(t.push(r),e.push(r),e):e,[]));n=Ke(n);let r=E(n,e=>e.length>1);return D(r,e=>{let t=D(e,e=>e.name);return{message:`The same RegExp pattern ->${rt(e).PATTERN}<-has been used in all of the following Token Types: ${t.join(`, `)} <-`,type:V.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}})}function Ln(e){let t=E(e,e=>{if(!k(e,`GROUP`))return!1;let t=e.GROUP;return t!==H.SKIPPED&&t!==H.NA&&!O(t)});return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String`,type:V.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}))}function Rn(e,t){let n=E(e,e=>e.PUSH_MODE!==void 0&&!P(t,e.PUSH_MODE));return D(n,e=>({message:`Token Type: ->${e.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${e.PUSH_MODE}<-which does not exist`,type:V.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}))}function zn(e){let t=[],n=T(e,(e,t,n)=>{let r=t.PATTERN;return r===H.NA||(O(r)?e.push({str:r,idx:n,tokenType:t}):ft(r)&&Vn(r)&&e.push({str:r.source,idx:n,tokenType:t})),e},[]);return x(e,(e,r)=>{x(n,({str:n,idx:i,tokenType:a})=>{if(r${a.name}<- can never be matched.\nBecause it appears AFTER the Token Type ->${e.name}<-in the lexer's definition.\nSee https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;t.push({message:n,type:V.UNREACHABLE_PATTERN,tokenTypes:[e,a]})}})}),t}function Bn(e,t){if(ft(t)){if(Hn(t))return!1;let n=t.exec(e);return n!==null&&n.index===0}if(b(t))return t(e,0,[],{});if(k(t,`exec`))return t.exec(e,0,[],{});if(typeof t==`string`)return t===e;throw Error(`non exhaustive match`)}function Vn(e){return Fe([`.`,`\\`,`[`,`]`,`|`,`^`,`$`,`(`,`)`,`?`,`*`,`+`,`{`],t=>e.source.indexOf(t)!==-1)===void 0}function Hn(e){return/(\(\?=)|(\(\?!)|(\(\?<=)|(\(\? property in its definition +`,type:V.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),k(e,`modes`)||r.push({message:`A MultiMode Lexer cannot be initialized without a property in its definition +`,type:V.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),k(e,`modes`)&&k(e,`defaultMode`)&&!k(e.modes,e.defaultMode)&&r.push({message:`A MultiMode Lexer cannot be initialized with a ${wn}: <${e.defaultMode}>which does not exist\n`,type:V.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),k(e,`modes`)&&x(e.modes,(e,t)=>{x(e,(n,i)=>{if(xe(n))r.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${t}> at index: <${i}>\n`,type:V.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED});else if(k(n,`LONGER_ALT`)){let i=S(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT];x(i,i=>{!xe(i)&&!P(e,i)&&r.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${i.name}> on token <${n.name}> outside of mode <${t}>\n`,type:V.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})})}})}),r}function Gn(e,t,n){let r=[],i=!1,a=gt(Ke(Ne(y(e.modes))),e=>e[Cn]===H.NA),o=Qn(n);return t&&x(a,e=>{let t=Xn(e,o);if(t!==!1){let n={message:Zn(e,t),type:t.issue,tokenType:e};r.push(n)}else k(e,`LINE_BREAKS`)?e.LINE_BREAKS===!0&&(i=!0):Sn(o,e.PATTERN)&&(i=!0)}),t&&!i&&r.push({message:`Warning: No LINE_BREAKS Found. + This Lexer has been defined to track line and column information, + But none of the Token Types can be identified as matching a line terminator. + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS + for details.`,type:V.NO_LINE_BREAKS_FLAGS}),r}function Kn(e){let t={},n=v(e);return x(n,n=>{let r=e[n];if(S(r))t[n]=[];else throw Error(`non exhaustive match`)}),t}function qn(e){let t=e.PATTERN;if(ft(t))return!1;if(b(t)||k(t,`exec`))return!0;if(O(t))return!1;throw Error(`non exhaustive match`)}function Jn(e){return O(e)&&e.length===1?e.charCodeAt(0):!1}var Yn={test:function(e){let t=e.length;for(let n=this.lastIndex;n Token Type\n\t Root cause: ${t.errMsg}.\n For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(t.issue===V.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. +\tThe problem is in the <${e.name}> Token Type\n For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error(`non exhaustive match`)}function Qn(e){return D(e,e=>O(e)?e.charCodeAt(0):e)}function $n(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}var er=[];function tr(e){return e<256?e:er[e]}function nr(){if(C(er)){er=Array(65536);for(let e=0;e<65536;e++)er[e]=e>255?255+~~(e/255):e}}function rr(e,t){let n=e.tokenTypeIdx;return n===t.tokenTypeIdx||t.isParent===!0&&t.categoryMatchesMap[n]===!0}function ir(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}var ar=1,or={};function sr(e){let t=cr(e);lr(t),dr(t),ur(t),x(t,e=>{e.isParent=e.categoryMatches.length>0})}function cr(e){let t=j(e),n=e,r=!0;for(;r;){n=Ke(Ne(D(n,e=>e.CATEGORIES)));let e=Qe(n,t);t=t.concat(e),C(e)?r=!1:n=e}return t}function lr(e){x(e,e=>{pr(e)||(or[ar]=e,e.tokenTypeIdx=ar++),mr(e)&&!S(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),mr(e)||(e.CATEGORIES=[]),hr(e)||(e.categoryMatches=[]),gr(e)||(e.categoryMatchesMap={})})}function ur(e){x(e,e=>{e.categoryMatches=[],x(e.categoryMatchesMap,(t,n)=>{e.categoryMatches.push(or[n].tokenTypeIdx)})})}function dr(e){x(e,e=>{fr([],e)})}function fr(e,t){x(e,e=>{t.categoryMatchesMap[e.tokenTypeIdx]=!0}),x(t.CATEGORIES,n=>{let r=e.concat(t);P(r,n)||fr(r,n)})}function pr(e){return k(e,`tokenTypeIdx`)}function mr(e){return k(e,`CATEGORIES`)}function hr(e){return k(e,`categoryMatches`)}function gr(e){return k(e,`categoryMatchesMap`)}function _r(e){return k(e,`tokenTypeIdx`)}var vr={buildUnableToPopLexerModeMessage(e){return`Unable to pop Lexer Mode after encountering Token ->${e.image}<- The Mode Stack is empty`},buildUnexpectedCharactersMessage(e,t,n,r,i,a){return`unexpected character: ->${e.charAt(t)}<- at offset: ${t}, skipped ${n} characters.`}},V;(function(e){e[e.MISSING_PATTERN=0]=`MISSING_PATTERN`,e[e.INVALID_PATTERN=1]=`INVALID_PATTERN`,e[e.EOI_ANCHOR_FOUND=2]=`EOI_ANCHOR_FOUND`,e[e.UNSUPPORTED_FLAGS_FOUND=3]=`UNSUPPORTED_FLAGS_FOUND`,e[e.DUPLICATE_PATTERNS_FOUND=4]=`DUPLICATE_PATTERNS_FOUND`,e[e.INVALID_GROUP_TYPE_FOUND=5]=`INVALID_GROUP_TYPE_FOUND`,e[e.PUSH_MODE_DOES_NOT_EXIST=6]=`PUSH_MODE_DOES_NOT_EXIST`,e[e.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]=`MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE`,e[e.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]=`MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY`,e[e.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]=`MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST`,e[e.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]=`LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED`,e[e.SOI_ANCHOR_FOUND=11]=`SOI_ANCHOR_FOUND`,e[e.EMPTY_MATCH_PATTERN=12]=`EMPTY_MATCH_PATTERN`,e[e.NO_LINE_BREAKS_FLAGS=13]=`NO_LINE_BREAKS_FLAGS`,e[e.UNREACHABLE_PATTERN=14]=`UNREACHABLE_PATTERN`,e[e.IDENTIFY_TERMINATOR=15]=`IDENTIFY_TERMINATOR`,e[e.CUSTOM_LINE_BREAK=16]=`CUSTOM_LINE_BREAK`,e[e.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]=`MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE`})(V||={});var yr={deferDefinitionErrorsHandling:!1,positionTracking:`full`,lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` +`,`\r`],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:vr,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(yr);var H=class{constructor(e,t=yr){if(this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(e,t)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=St(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()},typeof t==`boolean`)throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. +a boolean 2nd argument is no longer supported`);this.config=A({},yr,t);let n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof n==`number`&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT(`Lexer Constructor`,()=>{let n,r=!0;this.TRACE_INIT(`Lexer Config handling`,()=>{if(this.config.lineTerminatorsPattern===yr.lineTerminatorsPattern)this.config.lineTerminatorsPattern=Yn;else if(this.config.lineTerminatorCharacters===yr.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error(`"safeMode" and "ensureOptimizations" flags are mutually exclusive.`);this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),S(e)?n={modes:{defaultMode:j(e)},defaultMode:wn}:(r=!1,n=j(e))}),this.config.skipValidations===!1&&(this.TRACE_INIT(`performRuntimeChecks`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(Wn(n,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT(`performWarningRuntimeChecks`,()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(Gn(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),n.modes=n.modes?n.modes:{},x(n.modes,(e,t)=>{n.modes[t]=gt(e,e=>xe(e))});let i=v(n.modes);if(x(n.modes,(e,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,()=>{if(this.modes.push(n),this.config.skipValidations===!1&&this.TRACE_INIT(`validatePatterns`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(En(e,i))}),C(this.lexerDefinitionErrors)){sr(e);let r;this.TRACE_INIT(`analyzeTokenTypes`,()=>{r=Tn(e,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[n]=r.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=r.charCodeToPatternIdxToConfig,this.emptyGroups=A({},this.emptyGroups,r.emptyGroups),this.hasCustom=r.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=r.canBeOptimized}})}),this.defaultMode=n.defaultMode,!C(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){let e=D(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Errors detected in definition of Lexer: +`+e)}x(this.lexerDefinitionWarning,e=>{xt(e.message)}),this.TRACE_INIT(`Choosing sub-methods implementations`,()=>{if(r&&(this.handleModes=w),this.trackStartLines===!1&&(this.computeNewColumn=ye),this.trackEndLines===!1&&(this.updateTokenEndLineColumnLocation=w),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else if(/onlyOffset/i.test(this.config.positionTracking))this.createTokenInstance=this.createOffsetOnlyToken;else throw Error(`Invalid config option: "${this.config.positionTracking}"`);this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)}),this.TRACE_INIT(`Failed Optimization Warnings`,()=>{let e=T(this.canModeBeOptimized,(e,t,n)=>(t===!1&&e.push(n),e),[]);if(t.ensureOptimizations&&!C(e))throw Error(`Lexer Modes: < ${e.join(`, `)} > cannot be optimized.\n Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. + Or inspect the console log for details on how to resolve these issues.`)}),this.TRACE_INIT(`clearRegExpParserCache`,()=>{fn()}),this.TRACE_INIT(`toFastProperties`,()=>{Ct(this)})})}tokenize(e,t=this.defaultMode){if(!C(this.lexerDefinitionErrors)){let e=D(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Unable to Tokenize because Errors detected in definition of Lexer: +`+e)}return this.tokenizeInternal(e,t)}tokenizeInternal(e,t){let n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,ee=e,te=ee.length,_=0,ne=0,re=this.hasCustom?0:Math.floor(e.length/10),ie=Array(re),ae=[],oe=this.trackStartLines?1:void 0,v=this.trackStartLines?1:void 0,se=Kn(this.emptyGroups),ce=this.trackStartLines,le=this.config.lineTerminatorsPattern,ue=0,de=[],y=[],b=[],fe=[];Object.freeze(fe);let x=!1,S=e=>{if(b.length===1&&e.tokenType.PUSH_MODE===void 0){let t=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);ae.push({offset:e.startOffset,line:e.startLine,column:e.startColumn,length:e.image.length,message:t})}else{b.pop();let e=Ie(b);de=this.patternIdxToConfig[e],y=this.charCodeToPatternIdxToConfig[e],ue=de.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;x=!!(y&&t)}};function pe(e){b.push(e),y=this.charCodeToPatternIdxToConfig[e],de=this.patternIdxToConfig[e],ue=de.length,ue=de.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;x=!!(y&&t)}pe.call(this,t);let me,he=this.config.recoveryEnabled;for(;_s.length){s=a,u=a.length,c=l,me=t;break}}}break}}if(u!==-1){if(d=me.group,d!==void 0&&(s=s===null?e.substring(_,_+u):s,f=me.tokenTypeIdx,p=this.createTokenInstance(s,_,f,me.tokenType,oe,v,u),this.handlePayload(p,c),d===!1?ne=this.addToken(ie,ne,p):se[d].push(p)),ce===!0&&me.canLineTerminator===!0){let t=0,n,r;le.lastIndex=0;do s=s===null?e.substring(_,_+u):s,n=le.test(s),n===!0&&(r=le.lastIndex-1,t++);while(n===!0);t===0?v=this.computeNewColumn(v,u):(oe+=t,v=u-r,this.updateTokenEndLineColumnLocation(p,d,r,t,oe,v,u))}else v=this.computeNewColumn(v,u);_+=u,this.handleModes(me,S,pe,p)}else{let t=_,n=oe,i=v,a=he===!1;for(;a===!1&&_ ${br(e)} <--`:`token of type --> ${e.name} <--`} but found --> '${t.image}' <--`},buildNotAllInputParsedMessage({firstRedundant:e,ruleName:t}){return`Redundant input, expecting EOF but found: `+e.image},buildNoViableAltMessage({expectedPathsPerAlt:e,actual:t,previous:n,customUserDescription:r,ruleName:i}){let a=` +but found: '`+rt(t).image+`'`;if(r)return`Expecting: `+r+a;{let t=T(e,(e,t)=>e.concat(t),[]),n=D(t,e=>`[${D(e,e=>br(e)).join(`, `)}]`);return`Expecting: one of these possible Token sequences:\n${D(n,(e,t)=>` ${t+1}. ${e}`).join(` +`)}`+a}},buildEarlyExitMessage({expectedIterationPaths:e,actual:t,customUserDescription:n,ruleName:r}){let i=` +but found: '`+rt(t).image+`'`;return n?`Expecting: `+n+i:`Expecting: expecting at least one iteration which starts with one of these possible Token sequences::\n <${D(e,e=>`[${D(e,e=>br(e)).join(`,`)}]`).join(` ,`)}>`+i}};Object.freeze(Fr);var Ir={buildRuleNotFoundError(e,t){return`Invalid grammar, reference to a rule which is not defined: ->`+t.nonTerminalName+`<- +inside top level rule: ->`+e.name+`<-`}},Lr={buildDuplicateFoundError(e,t){function n(e){return e instanceof z?e.terminalType.name:e instanceof F?e.nonTerminalName:``}let r=e.name,i=rt(t),a=i.idx,o=Rt(i),s=n(i),c=`->${o}${a>0?a:``}<- ${s?`with argument: ->${s}<-`:``} + appears more than once (${t.length} times) in the top level rule: ->${r}<-. + For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES + `;return c=c.replace(/[ \t]+/g,` `),c=c.replace(/\s\s+/g,` +`),c},buildNamespaceConflictError(e){return`Namespace conflict found in grammar.\nThe grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${e.name}>.\nTo resolve this make sure each Terminal and Non-Terminal names are unique\nThis is easy to accomplish by using the convention that Terminal names start with an uppercase letter\nand Non-Terminal names start with a lower case letter.`},buildAlternationPrefixAmbiguityError(e){let t=D(e.prefixPath,e=>br(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx;return`Ambiguous alternatives: <${e.ambiguityIndices.join(` ,`)}> due to common lookahead prefix\nin inside <${e.topLevelRule.name}> Rule,\n<${t}> may appears as a prefix path in all these alternatives.\nSee: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX\nFor Further details.`},buildAlternationAmbiguityError(e){let t=e.alternation.idx===0?``:e.alternation.idx,n=e.prefixPath.length===0,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(` ,`)}> in inside <${e.topLevelRule.name}> Rule,\n`;if(n)r+=`These alternatives are all empty (match no tokens), making them indistinguishable. +Only the last alternative may be empty. +`;else{let t=D(e.prefixPath,e=>br(e)).join(`, `);r+=`<${t}> may appears as a prefix path in all these alternatives.\n`}return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r},buildEmptyRepetitionError(e){let t=Rt(e.repetition);return e.repetition.idx!==0&&(t+=e.repetition.idx),`The repetition <${t}> within Rule <${e.topLevelRule.name}> can never consume any tokens.\nThis could lead to an infinite loop.`},buildTokenNameError(e){return`deprecated`},buildEmptyAlternationError(e){return`Ambiguous empty alternative: <${e.emptyChoiceIdx+1}> in inside <${e.topLevelRule.name}> Rule.\nOnly the last alternative may be an empty alternative.`},buildTooManyAlternativesError(e){return`An Alternation cannot have more than 256 alternatives:\n inside <${e.topLevelRule.name}> Rule.\n has ${e.alternation.definition.length+1} alternatives.`},buildLeftRecursionError(e){let t=e.topLevelRule.name;return`Left Recursion found in grammar.\nrule: <${t}> can be invoked from itself (directly or indirectly)\nwithout consuming any Tokens. The grammar path that causes this is: \n ${`${t} --> ${D(e.leftRecursionPath,e=>e.name).concat([t]).join(` --> `)}`}\n To fix this refactor your grammar to remove the left recursion.\nsee: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError(e){return`deprecated`},buildDuplicateRuleNameError(e){let t;return t=e.topLevelRule instanceof Dt?e.topLevelRule.name:e.topLevelRule,`Duplicate definition, rule: ->${t}<- is already defined in the grammar: ->${e.grammarName}<-`}};function Rr(e,t){let n=new zr(e,t);return n.resolveRefs(),n.errors}var zr=class extends Pt{constructor(e,t){super(),this.nameToTopRule=e,this.errMsgProvider=t,this.errors=[]}resolveRefs(){x(y(this.nameToTopRule),e=>{this.currTopLevel=e,e.accept(this)})}visitNonTerminal(e){let t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{let t=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:t,type:G.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}}},Br=class extends zt{constructor(e,t){super(),this.topProd=e,this.path=t,this.possibleTokTypes=[],this.nextProductionName=``,this.nextProductionOccurrence=0,this.found=!1,this.isAtEndOfPath=!1}startWalking(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error(`The path does not start with the walker's top Rule!`);return this.ruleStack=j(this.path.ruleStack).reverse(),this.occurrenceStack=j(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes}walk(e,t=[]){this.found||super.walk(e,t)}walkProdRef(e,t,n){if(e.referencedRule.name===this.nextProductionName&&e.idx===this.nextProductionOccurrence){let r=t.concat(n);this.updateExpectedNext(),this.walk(e.referencedRule,r)}}updateExpectedNext(){C(this.ruleStack)?(this.nextProductionName=``,this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())}},Vr=class extends Br{constructor(e,t){super(e,t),this.path=t,this.nextTerminalName=``,this.nextTerminalOccurrence=0,this.nextTerminalName=this.path.lastTok.name,this.nextTerminalOccurrence=this.path.lastTokOccurrence}walkTerminal(e,t,n){if(this.isAtEndOfPath&&e.terminalType.name===this.nextTerminalName&&e.idx===this.nextTerminalOccurrence&&!this.found){let e=new I({definition:t.concat(n)});this.possibleTokTypes=Vt(e),this.found=!0}}},Hr=class extends zt{constructor(e,t){super(),this.topRule=e,this.occurrence=t,this.result={token:void 0,occurrence:void 0,isEndOfRule:void 0}}startWalking(){return this.walk(this.topRule),this.result}},Ur=class extends Hr{walkMany(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkMany(e,t,n)}},Wr=class extends Hr{walkManySep(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkManySep(e,t,n)}},Gr=class extends Hr{walkAtLeastOne(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOne(e,t,n)}},Kr=class extends Hr{walkAtLeastOneSep(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOneSep(e,t,n)}};function qr(e,t,n=[]){n=j(n);let r=[],i=0;function a(t){return t.concat(M(e,i+1))}function o(e){let i=qr(a(e),t,n);return r.concat(i)}for(;n.length{C(e.definition)===!1&&(r=o(e.definition))}),r;else if(t instanceof z)n.push(t.terminalType);else throw Error(`non exhaustive match`);i++}return r.push({partialPath:n,suffixDef:M(e,i)}),r}function Jr(e,t,n,r){let i=`EXIT_NONE_TERMINAL`,a=[i],o=`EXIT_ALTERNATIVE`,s=!1,c=t.length,l=c-r-1,u=[],d=[];for(d.push({idx:-1,def:e,ruleStack:[],occurrenceStack:[]});!C(d);){let e=d.pop();if(e===o){s&&Ie(d).idx<=l&&d.pop();continue}let r=e.def,f=e.idx,p=e.ruleStack,m=e.occurrenceStack;if(C(r))continue;let h=r[0];if(h===i){let e={idx:f,def:M(r),ruleStack:$e(p),occurrenceStack:$e(m)};d.push(e)}else if(h instanceof z){if(f=0;e--){let t={idx:f,def:h.definition[e].definition.concat(M(r)),ruleStack:p,occurrenceStack:m};d.push(t),d.push(o)}else if(h instanceof I)d.push({idx:f,def:h.definition.concat(M(r)),ruleStack:p,occurrenceStack:m});else if(h instanceof Dt)d.push(Yr(h,f,p,m));else throw Error(`non exhaustive match`)}return u}function Yr(e,t,n,r){let i=j(n);i.push(e.name);let a=j(r);return a.push(1),{idx:t,def:e.definition,ruleStack:i,occurrenceStack:a}}var W;(function(e){e[e.OPTION=0]=`OPTION`,e[e.REPETITION=1]=`REPETITION`,e[e.REPETITION_MANDATORY=2]=`REPETITION_MANDATORY`,e[e.REPETITION_MANDATORY_WITH_SEPARATOR=3]=`REPETITION_MANDATORY_WITH_SEPARATOR`,e[e.REPETITION_WITH_SEPARATOR=4]=`REPETITION_WITH_SEPARATOR`,e[e.ALTERNATION=5]=`ALTERNATION`})(W||={});function Xr(e){if(e instanceof L||e===`Option`)return W.OPTION;if(e instanceof R||e===`Repetition`)return W.REPETITION;if(e instanceof Ot||e===`RepetitionMandatory`)return W.REPETITION_MANDATORY;if(e instanceof kt||e===`RepetitionMandatoryWithSeparator`)return W.REPETITION_MANDATORY_WITH_SEPARATOR;if(e instanceof At||e===`RepetitionWithSeparator`)return W.REPETITION_WITH_SEPARATOR;if(e instanceof jt||e===`Alternation`)return W.ALTERNATION;throw Error(`non exhaustive match`)}function Zr(e,t,n,r,i,a){let o=si(e,t,n);return a(o,r,di(o)?ir:rr,i)}function Qr(e,t,n,r,i,a){let o=ci(e,t,i,n),s=di(o)?ir:rr;return a(o[0],s,r)}function $r(e,t,n,r){let i=e.length,a=nt(e,e=>nt(e,e=>e.length===1));if(t)return function(t){let r=D(t,e=>e.GATE);for(let t=0;tNe(e)),n=T(t,(e,t,n)=>(x(t,t=>{k(e,t.tokenTypeIdx)||(e[t.tokenTypeIdx]=n),x(t.categoryMatches,t=>{k(e,t)||(e[t]=n)})}),e),{});return function(){let e=this.LA(1);return n[e.tokenTypeIdx]}}return function(){for(let t=0;te.length===1),i=e.length;if(r&&!n){let t=Ne(e);if(t.length===1&&C(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=T(t,(e,t,n)=>(e[t.tokenTypeIdx]=!0,x(t.categoryMatches,t=>{e[t]=!0}),e),[]);return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){nextPath:for(let n=0;nqr([e],1)),r=ri(n.length),i=D(n,e=>{let t={};return x(e,e=>{let n=ii(e.partialPath);x(n,e=>{t[e]=!0})}),t}),a=n;for(let e=1;e<=t;e++){let n=a;a=ri(n.length);for(let o=0;o{let t=ii(e.partialPath);x(t,e=>{i[o][e]=!0})})}}}}return r}function si(e,t,n,r){let i=new ni(e,W.ALTERNATION,r);return t.accept(i),oi(i.result,n)}function ci(e,t,n,r){let i=new ni(e,n);t.accept(i);let a=i.result,o=new ti(t,e,n).startWalking();return oi([new I({definition:a}),new I({definition:o})],r)}function li(e,t){compareOtherPath:for(let n=0;n{let r=t[n];return e===r||r.categoryMatchesMap[e.tokenTypeIdx]})}function di(e){return nt(e,e=>nt(e,e=>nt(e,e=>C(e.categoryMatches))))}function fi(e){let t=e.lookaheadStrategy.validate({rules:e.rules,tokenTypes:e.tokenTypes,grammarName:e.grammarName});return D(t,e=>Object.assign({type:G.CUSTOM_LOOKAHEAD_VALIDATION},e))}function pi(e,t,n,r){let i=N(e,e=>mi(e,n)),a=Ai(e,t,n),o=N(e,e=>Ei(e,n)),s=N(e,t=>vi(t,e,r,n));return i.concat(a,o,s)}function mi(e,t){let n=new _i;e.accept(n);let r=n.allProductions,i=ht(at(r,hi),e=>e.length>1);return D(y(i),n=>{let r=rt(n),i=t.buildDuplicateFoundError(e,n),a=Rt(r),o={message:i,type:G.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:a,occurrence:r.idx},s=gi(r);return s&&(o.parameter=s),o})}function hi(e){return`${Rt(e)}_#_${e.idx}_#_${gi(e)}`}function gi(e){return e instanceof z?e.terminalType.name:e instanceof F?e.nonTerminalName:``}var _i=class extends Pt{constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(e){this.allProductions.push(e)}visitOption(e){this.allProductions.push(e)}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}visitAlternation(e){this.allProductions.push(e)}visitTerminal(e){this.allProductions.push(e)}};function vi(e,t,n,r){let i=[];if(T(t,(t,n)=>n.name===e.name?t+1:t,0)>1){let t=r.buildDuplicateRuleNameError({topLevelRule:e,grammarName:n});i.push({message:t,type:G.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}function yi(e,t,n){let r=[],i;return P(t,e)||(i=`Invalid rule override, rule: ->${e}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:G.INVALID_RULE_OVERRIDE,ruleName:e})),r}function bi(e,t,n,r=[]){let i=[],a=xi(t.definition);if(C(a))return[];{let t=e.name;P(a,e)&&i.push({message:n.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:r}),type:G.LEFT_RECURSION,ruleName:t});let o=N(Qe(a,r.concat([e])),t=>{let i=j(r);return i.push(t),bi(e,t,n,i)});return i.concat(o)}}function xi(e){let t=[];if(C(e))return t;let n=rt(e);if(n instanceof F)t.push(n.referencedRule);else if(n instanceof I||n instanceof L||n instanceof Ot||n instanceof kt||n instanceof At||n instanceof R)t=t.concat(xi(n.definition));else if(n instanceof jt)t=Ne(D(n.definition,e=>xi(e.definition)));else if(!(n instanceof z))throw Error(`non exhaustive match`);let r=It(n),i=e.length>1;if(r&&i){let n=M(e);return t.concat(xi(n))}return t}var Si=class extends Pt{constructor(){super(...arguments),this.alternations=[]}visitAlternation(e){this.alternations.push(e)}};function Ci(e,t){let n=new Si;e.accept(n);let r=n.alternations;return N(r,n=>N($e(n.definition),(r,i)=>{let a=Jr([r],[],rr,1);return C(a)?[{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:G.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}]:[]}))}function wi(e,t,n){let r=new Si;e.accept(r);let i=r.alternations;return i=gt(i,e=>e.ignoreAmbiguities===!0),N(i,r=>{let i=r.idx,a=si(i,e,r.maxLookahead||t,r),o=Oi(a,r,e,n),s=ki(a,r,e,n);return o.concat(s)})}var Ti=class extends Pt{constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}};function Ei(e,t){let n=new Si;e.accept(n);let r=n.alternations;return N(r,n=>n.definition.length>255?[{message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:G.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}]:[])}function Di(e,t,n){let r=[];return x(e,e=>{let i=new Ti;e.accept(i);let a=i.allProductions;x(a,i=>{let a=Xr(i),o=i.maxLookahead||t,s=i.idx,c=ci(s,e,a,o)[0];if(C(Ne(c))){let t=n.buildEmptyRepetitionError({topLevelRule:e,repetition:i});r.push({message:t,type:G.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}})}),r}function Oi(e,t,n,r){let i=[],a=T(e,(n,r,a)=>(t.definition[a].ignoreAmbiguities===!0||x(r,r=>{let o=[a];x(e,(e,n)=>{a!==n&&li(e,r)&&t.definition[n].ignoreAmbiguities!==!0&&o.push(n)}),o.length>1&&!li(i,r)&&(i.push(r),n.push({alts:o,path:r}))}),n),[]);return D(a,e=>{let i=D(e.alts,e=>e+1);return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:G.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:t.idx,alternatives:e.alts}})}function ki(e,t,n,r){let i=T(e,(e,t,n)=>{let r=D(t,e=>({idx:n,path:e}));return e.concat(r)},[]);return Ke(N(i,e=>{if(t.definition[e.idx].ignoreAmbiguities===!0)return[];let a=e.idx,o=e.path,s=E(i,e=>t.definition[e.idx].ignoreAmbiguities!==!0&&e.idx{let i=[e.idx+1,a+1],o=t.idx===0?``:t.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:G.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}})}))}function Ai(e,t,n){let r=[],i=D(t,e=>e.name);return x(e,e=>{let t=e.name;if(P(i,t)){let i=n.buildNamespaceConflictError(e);r.push({message:i,type:G.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}}),r}function ji(e){let t=je(e,{errMsgProvider:Ir}),n={};return x(e.rules,e=>{n[e.name]=e}),Rr(n,t.errMsgProvider)}function Mi(e){return e=je(e,{errMsgProvider:Lr}),pi(e.rules,e.tokenTypes,e.errMsgProvider,e.grammarName)}var Ni=`MismatchedTokenException`,Pi=`NoViableAltException`,Fi=`EarlyExitException`,Ii=`NotAllInputParsedException`,Li=[Ni,Pi,Fi,Ii];Object.freeze(Li);function Ri(e){return P(Li,e.name)}var zi=class extends Error{constructor(e,t){super(e),this.token=t,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}},Bi=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Ni}},Vi=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Pi}},Hi=class extends zi{constructor(e,t){super(e,t),this.name=Ii}},Ui=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Fi}},Wi={},Gi=`InRuleRecoveryException`,Ki=class extends Error{constructor(e){super(e),this.name=Gi}},qi=class{initRecoverable(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=k(e,`recoveryEnabled`)?e.recoveryEnabled:Fa.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Ji)}getTokenToInsert(e){let t=Nr(e,``,NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t}canTokenTypeBeInsertedInRecovery(e){return!0}canTokenTypeBeDeletedInRecovery(e){return!0}tryInRepetitionRecovery(e,t,n,r){let i=this.findReSyncTokenType(),a=this.exportLexerState(),o=[],s=!1,c=this.LA(1),l=this.LA(1),u=()=>{let e=this.LA(0),t=new Bi(this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:c,previous:e,ruleName:this.getCurrRuleFullName()}),c,this.LA(0));t.resyncedTokens=$e(o),this.SAVE_ERROR(t)};for(;!s;)if(this.tokenMatcher(l,r)){u();return}else if(n.call(this)){u(),e.apply(this,t);return}else this.tokenMatcher(l,i)?s=!0:(l=this.SKIP_TOKEN(),this.addToResyncTokens(l,o));this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(e,t,n){return!(n===!1||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t)))}getFollowsForInRuleRecovery(e,t){let n=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){let e=this.SKIP_TOKEN();return this.consumeToken(),e}throw new Ki(`sad sad panda`)}canPerformInRuleRecovery(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)}canRecoverWithSingleTokenInsertion(e,t){if(!this.canTokenTypeBeInsertedInRecovery(e)||C(t))return!1;let n=this.LA(1);return Fe(t,e=>this.tokenMatcher(n,e))!==void 0}canRecoverWithSingleTokenDeletion(e){return this.canTokenTypeBeDeletedInRecovery(e)?this.tokenMatcher(this.LA(2),e):!1}isInCurrentRuleReSyncSet(e){let t=this.getCurrFollowKey();return P(this.getFollowSetFromFollowKey(t),e)}findReSyncTokenType(){let e=this.flattenFollowSet(),t=this.LA(1),n=2;for(;;){let r=Fe(e,e=>Pr(t,e));if(r!==void 0)return r;t=this.LA(n),n++}}getCurrFollowKey(){if(this.RULE_STACK.length===1)return Wi;let e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){let e=this.RULE_STACK,t=this.RULE_OCCURRENCE_STACK;return D(e,(n,r)=>r===0?Wi:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:t[r],inRule:this.shortRuleNameToFullName(e[r-1])})}flattenFollowSet(){let e=D(this.buildFullFollowKeyStack(),e=>this.getFollowSetFromFollowKey(e));return Ne(e)}getFollowSetFromFollowKey(e){if(e===Wi)return[Mr];let t=e.ruleName+e.idxInCallingRule+Gt+e.inRule;return this.resyncFollows[t]}addToResyncTokens(e,t){return this.tokenMatcher(e,Mr)||t.push(e),t}reSyncTo(e){let t=[],n=this.LA(1);for(;this.tokenMatcher(n,e)===!1;)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,t);return $e(t)}attemptInRepetitionRecovery(e,t,n,r,i,a,o){}getCurrentGrammarPath(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:j(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}}getHumanReadableRuleStack(){return D(this.RULE_STACK,e=>this.shortRuleNameToFullName(e))}};function Ji(e,t,n,r,i,a,o){let s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(c===void 0){let e=this.getCurrRuleFullName(),t=this.getGAstProductions()[e];c=new a(t,i).startWalking(),this.firstAfterRepMap[s]=c}let l=c.token,u=c.occurrence,d=c.isEndOfRule;this.RULE_STACK.length===1&&d&&l===void 0&&(l=Mr,u=1),l!==void 0&&u!==void 0&&this.shouldInRepetitionRecoveryBeTried(l,u,o)&&this.tryInRepetitionRecovery(e,t,n,l)}var Yi=1024,Xi=1280,Zi=1536;function Qi(e,t,n){return n|t|e}var $i=class{constructor(e){this.maxLookahead=e?.maxLookahead??Fa.maxLookahead}validate(e){let t=this.validateNoLeftRecursion(e.rules);if(C(t)){let n=this.validateEmptyOrAlternatives(e.rules),r=this.validateAmbiguousAlternationAlternatives(e.rules,this.maxLookahead),i=this.validateSomeNonEmptyLookaheadPath(e.rules,this.maxLookahead);return[...t,...n,...r,...i]}return t}validateNoLeftRecursion(e){return N(e,e=>bi(e,e,Lr))}validateEmptyOrAlternatives(e){return N(e,e=>Ci(e,Lr))}validateAmbiguousAlternationAlternatives(e,t){return N(e,e=>wi(e,t,Lr))}validateSomeNonEmptyLookaheadPath(e,t){return Di(e,t,Lr)}buildLookaheadForAlternation(e){return Zr(e.prodOccurrence,e.rule,e.maxLookahead,e.hasPredicates,e.dynamicTokensEnabled,$r)}buildLookaheadForOptional(e){return Qr(e.prodOccurrence,e.rule,e.maxLookahead,e.dynamicTokensEnabled,Xr(e.prodType),ei)}},ea=class{initLooksAhead(e){this.dynamicTokensEnabled=k(e,`dynamicTokensEnabled`)?e.dynamicTokensEnabled:Fa.dynamicTokensEnabled,this.maxLookahead=k(e,`maxLookahead`)?e.maxLookahead:Fa.maxLookahead,this.lookaheadStrategy=k(e,`lookaheadStrategy`)?e.lookaheadStrategy:new $i({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(e){x(e,e=>{this.TRACE_INIT(`${e.name} Rule Lookahead`,()=>{let{alternation:t,repetition:n,option:r,repetitionMandatory:i,repetitionMandatoryWithSeparator:a,repetitionWithSeparator:o}=na(e);x(t,t=>{let n=t.idx===0?``:t.idx;this.TRACE_INIT(`${Rt(t)}${n}`,()=>{let n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:t.idx,rule:e,maxLookahead:t.maxLookahead||this.maxLookahead,hasPredicates:t.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=Qi(this.fullRuleNameToShort[e.name],256,t.idx);this.setLaFuncCache(r,n)})}),x(n,t=>{this.computeLookaheadFunc(e,t.idx,768,`Repetition`,t.maxLookahead,Rt(t))}),x(r,t=>{this.computeLookaheadFunc(e,t.idx,512,`Option`,t.maxLookahead,Rt(t))}),x(i,t=>{this.computeLookaheadFunc(e,t.idx,Yi,`RepetitionMandatory`,t.maxLookahead,Rt(t))}),x(a,t=>{this.computeLookaheadFunc(e,t.idx,Zi,`RepetitionMandatoryWithSeparator`,t.maxLookahead,Rt(t))}),x(o,t=>{this.computeLookaheadFunc(e,t.idx,Xi,`RepetitionWithSeparator`,t.maxLookahead,Rt(t))})})})}computeLookaheadFunc(e,t,n,r,i,a){this.TRACE_INIT(`${a}${t===0?``:t}`,()=>{let a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:t,rule:e,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),o=Qi(this.fullRuleNameToShort[e.name],n,t);this.setLaFuncCache(o,a)})}getKeyForAutomaticLookahead(e,t){return Qi(this.getLastExplicitRuleShortName(),e,t)}getLaFuncFromCache(e){return this.lookAheadFuncsCache.get(e)}setLaFuncCache(e,t){this.lookAheadFuncsCache.set(e,t)}},ta=new class extends Pt{constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(e){this.dslMethods.option.push(e)}visitRepetitionWithSeparator(e){this.dslMethods.repetitionWithSeparator.push(e)}visitRepetitionMandatory(e){this.dslMethods.repetitionMandatory.push(e)}visitRepetitionMandatoryWithSeparator(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)}visitRepetition(e){this.dslMethods.repetition.push(e)}visitAlternation(e){this.dslMethods.alternation.push(e)}};function na(e){ta.reset(),e.accept(ta);let t=ta.dslMethods;return ta.reset(),t}function ra(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffsete.msg);throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>:\n\t${t.join(` + +`).replace(/\n/g,` + `)}`)}}},n.prototype.constructor=n,n._RULE_NAMES=t,n}function da(e,t,n){let r=function(){};ca(r,e+`BaseSemanticsWithDefaults`);let i=Object.create(n.prototype);return x(t,e=>{i[e]=la}),r.prototype=i,r.prototype.constructor=r,r}var fa;(function(e){e[e.REDUNDANT_METHOD=0]=`REDUNDANT_METHOD`,e[e.MISSING_METHOD=1]=`MISSING_METHOD`})(fa||={});function pa(e,t){return ma(e,t)}function ma(e,t){let n=E(t,t=>b(e[t])===!1);return Ke(D(n,t=>({msg:`Missing visitor method: <${t}> on ${e.constructor.name} CST Visitor.`,type:fa.MISSING_METHOD,methodName:t})))}var ha=class{initTreeBuilder(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=k(e,`nodeLocationTracking`)?e.nodeLocationTracking:Fa.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=w,this.cstFinallyStateUpdate=w,this.cstPostTerminal=w,this.cstPostNonTerminal=w,this.cstPostRule=w;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ia,this.setNodeLocationFromNode=ia,this.cstPostRule=w,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ra,this.setNodeLocationFromNode=ra,this.cstPostRule=w,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=w,this.setInitialNodeLocation=w;else throw Error(`Invalid config option: "${e.nodeLocationTracking}"`)}setInitialNodeLocationOnlyOffsetRecovery(e){e.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(e){let t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(e){let t={name:e,children:Object.create(null)};this.setInitialNodeLocation(t),this.CST_STACK.push(t)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?(n.endOffset=t.endOffset,n.endLine=t.endLine,n.endColumn=t.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?n.endOffset=t.endOffset:n.startOffset=NaN}cstPostTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];aa(n,t,e),this.setNodeLocationFromToken(n.location,t)}cstPostNonTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];oa(n,t,e),this.setNodeLocationFromNode(n.location,e.location)}getBaseCstVisitorConstructor(){if(xe(this.baseCstVisitorConstructor)){let e=ua(this.className,v(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if(xe(this.baseCstVisitorWithDefaultsConstructor)){let e=da(this.className,v(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-1]}getPreviousExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-2]}getLastExplicitRuleOccurrenceIndex(){let e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]}},ga=class{initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(e){if(this.selfAnalysisDone!==!0)throw Error(`Missing invocation at the end of the Parser's constructor.`);this.reset(),this.tokVector=e,this.tokVectorLength=e.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):Pa}LA(e){let t=this.currIdx+e;return t<0||this.tokVectorLength<=t?Pa:this.tokVector[t]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(e){this.currIdx=e}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},_a=class{ACTION(e){return e.call(this)}consume(e,t,n){return this.consumeInternal(t,e,n)}subrule(e,t,n){return this.subruleInternal(t,e,n)}option(e,t){return this.optionInternal(t,e)}or(e,t){return this.orInternal(t,e)}many(e,t){return this.manyInternal(e,t)}atLeastOne(e,t){return this.atLeastOneInternal(e,t)}CONSUME(e,t){return this.consumeInternal(e,0,t)}CONSUME1(e,t){return this.consumeInternal(e,1,t)}CONSUME2(e,t){return this.consumeInternal(e,2,t)}CONSUME3(e,t){return this.consumeInternal(e,3,t)}CONSUME4(e,t){return this.consumeInternal(e,4,t)}CONSUME5(e,t){return this.consumeInternal(e,5,t)}CONSUME6(e,t){return this.consumeInternal(e,6,t)}CONSUME7(e,t){return this.consumeInternal(e,7,t)}CONSUME8(e,t){return this.consumeInternal(e,8,t)}CONSUME9(e,t){return this.consumeInternal(e,9,t)}SUBRULE(e,t){return this.subruleInternal(e,0,t)}SUBRULE1(e,t){return this.subruleInternal(e,1,t)}SUBRULE2(e,t){return this.subruleInternal(e,2,t)}SUBRULE3(e,t){return this.subruleInternal(e,3,t)}SUBRULE4(e,t){return this.subruleInternal(e,4,t)}SUBRULE5(e,t){return this.subruleInternal(e,5,t)}SUBRULE6(e,t){return this.subruleInternal(e,6,t)}SUBRULE7(e,t){return this.subruleInternal(e,7,t)}SUBRULE8(e,t){return this.subruleInternal(e,8,t)}SUBRULE9(e,t){return this.subruleInternal(e,9,t)}OPTION(e){return this.optionInternal(e,0)}OPTION1(e){return this.optionInternal(e,1)}OPTION2(e){return this.optionInternal(e,2)}OPTION3(e){return this.optionInternal(e,3)}OPTION4(e){return this.optionInternal(e,4)}OPTION5(e){return this.optionInternal(e,5)}OPTION6(e){return this.optionInternal(e,6)}OPTION7(e){return this.optionInternal(e,7)}OPTION8(e){return this.optionInternal(e,8)}OPTION9(e){return this.optionInternal(e,9)}OR(e){return this.orInternal(e,0)}OR1(e){return this.orInternal(e,1)}OR2(e){return this.orInternal(e,2)}OR3(e){return this.orInternal(e,3)}OR4(e){return this.orInternal(e,4)}OR5(e){return this.orInternal(e,5)}OR6(e){return this.orInternal(e,6)}OR7(e){return this.orInternal(e,7)}OR8(e){return this.orInternal(e,8)}OR9(e){return this.orInternal(e,9)}MANY(e){this.manyInternal(0,e)}MANY1(e){this.manyInternal(1,e)}MANY2(e){this.manyInternal(2,e)}MANY3(e){this.manyInternal(3,e)}MANY4(e){this.manyInternal(4,e)}MANY5(e){this.manyInternal(5,e)}MANY6(e){this.manyInternal(6,e)}MANY7(e){this.manyInternal(7,e)}MANY8(e){this.manyInternal(8,e)}MANY9(e){this.manyInternal(9,e)}MANY_SEP(e){this.manySepFirstInternal(0,e)}MANY_SEP1(e){this.manySepFirstInternal(1,e)}MANY_SEP2(e){this.manySepFirstInternal(2,e)}MANY_SEP3(e){this.manySepFirstInternal(3,e)}MANY_SEP4(e){this.manySepFirstInternal(4,e)}MANY_SEP5(e){this.manySepFirstInternal(5,e)}MANY_SEP6(e){this.manySepFirstInternal(6,e)}MANY_SEP7(e){this.manySepFirstInternal(7,e)}MANY_SEP8(e){this.manySepFirstInternal(8,e)}MANY_SEP9(e){this.manySepFirstInternal(9,e)}AT_LEAST_ONE(e){this.atLeastOneInternal(0,e)}AT_LEAST_ONE1(e){return this.atLeastOneInternal(1,e)}AT_LEAST_ONE2(e){this.atLeastOneInternal(2,e)}AT_LEAST_ONE3(e){this.atLeastOneInternal(3,e)}AT_LEAST_ONE4(e){this.atLeastOneInternal(4,e)}AT_LEAST_ONE5(e){this.atLeastOneInternal(5,e)}AT_LEAST_ONE6(e){this.atLeastOneInternal(6,e)}AT_LEAST_ONE7(e){this.atLeastOneInternal(7,e)}AT_LEAST_ONE8(e){this.atLeastOneInternal(8,e)}AT_LEAST_ONE9(e){this.atLeastOneInternal(9,e)}AT_LEAST_ONE_SEP(e){this.atLeastOneSepFirstInternal(0,e)}AT_LEAST_ONE_SEP1(e){this.atLeastOneSepFirstInternal(1,e)}AT_LEAST_ONE_SEP2(e){this.atLeastOneSepFirstInternal(2,e)}AT_LEAST_ONE_SEP3(e){this.atLeastOneSepFirstInternal(3,e)}AT_LEAST_ONE_SEP4(e){this.atLeastOneSepFirstInternal(4,e)}AT_LEAST_ONE_SEP5(e){this.atLeastOneSepFirstInternal(5,e)}AT_LEAST_ONE_SEP6(e){this.atLeastOneSepFirstInternal(6,e)}AT_LEAST_ONE_SEP7(e){this.atLeastOneSepFirstInternal(7,e)}AT_LEAST_ONE_SEP8(e){this.atLeastOneSepFirstInternal(8,e)}AT_LEAST_ONE_SEP9(e){this.atLeastOneSepFirstInternal(9,e)}RULE(e,t,n=Ia){if(P(this.definedRulesNames,e)){let t={message:Lr.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:G.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(t)}this.definedRulesNames.push(e);let r=this.defineRule(e,t,n);return this[e]=r,r}OVERRIDE_RULE(e,t,n=Ia){let r=yi(e,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);let i=this.defineRule(e,t,n);return this[e]=i,i}BACKTRACK(e,t){return function(){this.isBackTrackingStack.push(1);let n=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(Ri(e))return!1;throw e}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return Mt(y(this.gastProductionsCache))}},va=class{initRecognizerEngine(e,t){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=ir,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},k(t,`serializedGrammar`))throw Error(`The Parser's configuration can no longer contain a property. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 + For Further details.`);if(S(e)){if(C(e))throw Error(`A Token Vocabulary cannot be empty. + Note that the first argument for the parser constructor + is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset==`number`)throw Error(`The Parser constructor no longer accepts a token vector as the first argument. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 + For Further details.`)}if(S(e))this.tokensMap=T(e,(e,t)=>(e[t.name]=t,e),{});else if(k(e,`modes`)&&nt(Ne(y(e.modes)),_r)){let t=yt(Ne(y(e.modes)));this.tokensMap=T(t,(e,t)=>(e[t.name]=t,e),{})}else if(Ce(e))this.tokensMap=j(e);else throw Error(` argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition`);this.tokensMap.EOF=Mr;let n=nt(k(e,`modes`)?Ne(y(e.modes)):y(e),e=>C(e.categoryMatches));this.tokenMatcher=n?ir:rr,sr(y(this.tokensMap))}defineRule(e,t,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${e}> may not be defined after the 'performSelfAnalysis' method has been called'\nMake sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);let r=k(n,`resyncEnabled`)?n.resyncEnabled:Ia.resyncEnabled,i=k(n,`recoveryValueFunc`)?n.recoveryValueFunc:Ia.recoveryValueFunc,a=this.ruleShortNameIdx<<12;this.ruleShortNameIdx++,this.shortRuleNameToFull[a]=e,this.fullRuleNameToShort[e]=a;let o;return o=this.outputCst===!0?function(...n){try{this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n);let r=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(r),r}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}}:function(...n){try{return this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n)}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}},Object.assign(o,{ruleName:e,originalGrammarAction:t})}invokeRuleCatch(e,t,n){let r=this.RULE_STACK.length===1,i=t&&!this.isBackTracking()&&this.recoveryEnabled;if(Ri(e)){let t=e;if(i){let r=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(r)){if(t.resyncedTokens=this.reSyncTo(r),this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];return e.recoveredNode=!0,e}return n(e)}if(this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];e.recoveredNode=!0,t.partialCstResult=e}throw t}if(r)return this.moveToTerminatedState(),n(e);throw t}throw e}optionInternal(e,t){let n=this.getKeyForAutomaticLookahead(512,t);return this.optionInternalLogic(e,t,n)}optionInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof e!=`function`){i=e.DEF;let t=e.GATE;if(t!==void 0){let e=r;r=()=>t.call(this)&&e.call(this)}}else i=e;if(r.call(this)===!0)return i.call(this)}atLeastOneInternal(e,t){let n=this.getKeyForAutomaticLookahead(Yi,e);return this.atLeastOneInternalLogic(e,t,n)}atLeastOneInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=()=>e.call(this)&&t.call(this)}}else i=t;if(r.call(this)===!0){let e=this.doSingleRepetition(i);for(;r.call(this)===!0&&e===!0;)e=this.doSingleRepetition(i)}else throw this.raiseEarlyExitException(e,W.REPETITION_MANDATORY,t.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,t],r,Yi,e,Gr)}atLeastOneSepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Zi,e);this.atLeastOneSepFirstInternalLogic(e,t,n)}atLeastOneSepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=()=>this.tokenMatcher(this.LA(1),i);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,Kr],t,Zi,e,Kr)}else throw this.raiseEarlyExitException(e,W.REPETITION_MANDATORY_WITH_SEPARATOR,t.ERR_MSG)}manyInternal(e,t){let n=this.getKeyForAutomaticLookahead(768,e);return this.manyInternalLogic(e,t,n)}manyInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=()=>e.call(this)&&t.call(this)}}else i=t;let a=!0;for(;r.call(this)===!0&&a===!0;)a=this.doSingleRepetition(i);this.attemptInRepetitionRecovery(this.manyInternal,[e,t],r,768,e,Ur,a)}manySepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Xi,e);this.manySepFirstInternalLogic(e,t,n)}manySepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=()=>this.tokenMatcher(this.LA(1),i);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,Wr],t,Xi,e,Wr)}}repetitionSepSecondInternal(e,t,n,r,i){for(;n();)this.CONSUME(t),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,t,n,r,i],n,Zi,e,i)}doSingleRepetition(e){let t=this.getLexerPosition();return e.call(this),this.getLexerPosition()>t}orInternal(e,t){let n=this.getKeyForAutomaticLookahead(256,t),r=S(e)?e:e.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(i!==void 0)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){let e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new Hi(t,e))}}subruleInternal(e,t,n){let r;try{let i=n===void 0?void 0:n.ARGS;return this.subruleIdx=t,r=e.apply(this,i),this.cstPostNonTerminal(r,n!==void 0&&n.LABEL!==void 0?n.LABEL:e.ruleName),r}catch(t){throw this.subruleInternalError(t,n,e.ruleName)}}subruleInternalError(e,t,n){throw Ri(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,t!==void 0&&t.LABEL!==void 0?t.LABEL:n),delete e.partialCstResult),e}consumeInternal(e,t,n){let r;try{let t=this.LA(1);this.tokenMatcher(t,e)===!0?(this.consumeToken(),r=t):this.consumeInternalError(e,t,n)}catch(n){r=this.consumeInternalRecovery(e,t,n)}return this.cstPostTerminal(n!==void 0&&n.LABEL!==void 0?n.LABEL:e.name,r),r}consumeInternalError(e,t,n){let r,i=this.LA(0);throw r=n!==void 0&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new Bi(r,t,i))}consumeInternalRecovery(e,t,n){if(this.recoveryEnabled&&n.name===`MismatchedTokenException`&&!this.isBackTracking()){let r=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,r)}catch(e){throw e.name===`InRuleRecoveryException`?n:e}}throw n}saveRecogState(){let e=this.errors,t=j(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK}}reloadRecogState(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK}ruleInvocationStateUpdate(e,t,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t)}isBackTracking(){return this.isBackTrackingStack.length!==0}getCurrRuleFullName(){let e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]}shortRuleNameToFullName(e){return this.shortRuleNameToFull[e]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),Mr)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},ya=class{initErrorHandler(e){this._errors=[],this.errorMessageProvider=k(e,`errorMessageProvider`)?e.errorMessageProvider:Fa.errorMessageProvider}SAVE_ERROR(e){if(Ri(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:j(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error(`Trying to save an Error which is not a RecognitionException`)}get errors(){return j(this._errors)}set errors(e){this._errors=e}raiseEarlyExitException(e,t,n){let r=this.getCurrRuleFullName(),i=this.getGAstProductions()[r],a=ci(e,i,t,this.maxLookahead)[0],o=[];for(let e=1;e<=this.maxLookahead;e++)o.push(this.LA(e));let s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new Ui(s,this.LA(1),this.LA(0)))}raiseNoAltException(e,t){let n=this.getCurrRuleFullName(),r=this.getGAstProductions()[n],i=si(e,r,this.maxLookahead),a=[];for(let e=1;e<=this.maxLookahead;e++)a.push(this.LA(e));let o=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:o,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new Vi(s,this.LA(1),o))}},ba=class{initContentAssist(){}computeContentAssist(e,t){let n=this.gastProductionsCache[e];if(xe(n))throw Error(`Rule ->${e}<- does not exist in this grammar.`);return Jr([n],t,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(e){let t=rt(e.ruleStack),n=this.getGAstProductions()[t];return new Vr(n,e).startWalking()}},xa={description:`This Object indicates the Parser is during Recording Phase`};Object.freeze(xa);var Sa=!0,Ca=255,wa=U({name:`RECORDING_PHASE_TOKEN`,pattern:H.NA});sr([wa]);var Ta=Nr(wa,`This IToken indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(Ta);var Ea={name:`This CSTNode indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},Da=class{initGastRecorder(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT(`Enable Recording`,()=>{for(let e=0;e<10;e++){let t=e>0?e:``;this[`CONSUME${t}`]=function(t,n){return this.consumeInternalRecord(t,e,n)},this[`SUBRULE${t}`]=function(t,n){return this.subruleInternalRecord(t,e,n)},this[`OPTION${t}`]=function(t){return this.optionInternalRecord(t,e)},this[`OR${t}`]=function(t){return this.orInternalRecord(t,e)},this[`MANY${t}`]=function(t){this.manyInternalRecord(e,t)},this[`MANY_SEP${t}`]=function(t){this.manySepFirstInternalRecord(e,t)},this[`AT_LEAST_ONE${t}`]=function(t){this.atLeastOneInternalRecord(e,t)},this[`AT_LEAST_ONE_SEP${t}`]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}}this.consume=function(e,t,n){return this.consumeInternalRecord(t,e,n)},this.subrule=function(e,t,n){return this.subruleInternalRecord(t,e,n)},this.option=function(e,t){return this.optionInternalRecord(t,e)},this.or=function(e,t){return this.orInternalRecord(t,e)},this.many=function(e,t){this.manyInternalRecord(e,t)},this.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD})}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT(`Deleting Recording methods`,()=>{let e=this;for(let t=0;t<10;t++){let n=t>0?t:``;delete e[`CONSUME${n}`],delete e[`SUBRULE${n}`],delete e[`OPTION${n}`],delete e[`OR${n}`],delete e[`MANY${n}`],delete e[`MANY_SEP${n}`],delete e[`AT_LEAST_ONE${n}`],delete e[`AT_LEAST_ONE_SEP${n}`]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})}ACTION_RECORD(e){}BACKTRACK_RECORD(e,t){return()=>!0}LA_RECORD(e){return Pa}topLevelRuleRecord(e,t){try{let n=new Dt({definition:[],name:e});return n.name=e,this.recordingProdStack.push(n),t.call(this),this.recordingProdStack.pop(),n}catch(e){if(e.KNOWN_RECORDER_ERROR!==!0)try{e.message+=` + This error was thrown during the "grammar recording phase" For more info see: + https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch{throw e}throw e}}optionInternalRecord(e,t){return Oa.call(this,L,e,t)}atLeastOneInternalRecord(e,t){Oa.call(this,Ot,t,e)}atLeastOneSepFirstInternalRecord(e,t){Oa.call(this,kt,t,e,Sa)}manyInternalRecord(e,t){Oa.call(this,R,t,e)}manySepFirstInternalRecord(e,t){Oa.call(this,At,t,e,Sa)}orInternalRecord(e,t){return ka.call(this,e,t)}subruleInternalRecord(e,t,n){if(ja(t),!e||k(e,`ruleName`)===!1){let n=Error(` argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=Ie(this.recordingProdStack),i=e.ruleName,a=new F({idx:t,nonTerminalName:i,label:n?.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?Ea:xa}consumeInternalRecord(e,t,n){if(ja(t),!pr(e)){let n=Error(` argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=Ie(this.recordingProdStack),i=new z({idx:t,terminalType:e,label:n?.LABEL});return r.definition.push(i),Ta}};function Oa(e,t,n,r=!1){ja(n);let i=Ie(this.recordingProdStack),a=b(t)?t:t.DEF,o=new e({definition:[],idx:n});return r&&(o.separator=t.SEP),k(t,`MAX_LOOKAHEAD`)&&(o.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(o),a.call(this),i.definition.push(o),this.recordingProdStack.pop(),xa}function ka(e,t){ja(t);let n=Ie(this.recordingProdStack),r=S(e)===!1,i=r===!1?e:e.DEF,a=new jt({definition:[],idx:t,ignoreAmbiguities:r&&e.IGNORE_AMBIGUITIES===!0});return k(e,`MAX_LOOKAHEAD`)&&(a.maxLookahead=e.MAX_LOOKAHEAD),a.hasPredicates=vt(i,e=>b(e.GATE)),n.definition.push(a),x(i,e=>{let t=new I({definition:[]});a.definition.push(t),k(e,`IGNORE_AMBIGUITIES`)?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:k(e,`GATE`)&&(t.ignoreAmbiguities=!0),this.recordingProdStack.push(t),e.ALT.call(this),this.recordingProdStack.pop()}),xa}function Aa(e){return e===0?``:`${e}`}function ja(e){if(e<0||e>Ca){let t=Error(`Invalid DSL Method idx value: <${e}>\n\tIdx value must be a none negative value smaller than ${Ca+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}var Ma=class{initPerformanceTracer(e){if(k(e,`traceInitPerf`)){let t=e.traceInitPerf,n=typeof t==`number`;this.traceInitMaxIdent=n?t:1/0,this.traceInitPerf=n?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=Fa.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(e,t){if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=St(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()}};function Na(e,t){t.forEach(t=>{let n=t.prototype;Object.getOwnPropertyNames(n).forEach(r=>{if(r===`constructor`)return;let i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(e.prototype,r,i):e.prototype[r]=t.prototype[r]})})}var Pa=Nr(Mr,``,NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(Pa);var Fa=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:Fr,nodeLocationTracking:`none`,traceInitPerf:!1,skipValidations:!1}),Ia=Object.freeze({recoveryValueFunc:()=>void 0,resyncEnabled:!0}),G;(function(e){e[e.INVALID_RULE_NAME=0]=`INVALID_RULE_NAME`,e[e.DUPLICATE_RULE_NAME=1]=`DUPLICATE_RULE_NAME`,e[e.INVALID_RULE_OVERRIDE=2]=`INVALID_RULE_OVERRIDE`,e[e.DUPLICATE_PRODUCTIONS=3]=`DUPLICATE_PRODUCTIONS`,e[e.UNRESOLVED_SUBRULE_REF=4]=`UNRESOLVED_SUBRULE_REF`,e[e.LEFT_RECURSION=5]=`LEFT_RECURSION`,e[e.NONE_LAST_EMPTY_ALT=6]=`NONE_LAST_EMPTY_ALT`,e[e.AMBIGUOUS_ALTS=7]=`AMBIGUOUS_ALTS`,e[e.CONFLICT_TOKENS_RULES_NAMESPACE=8]=`CONFLICT_TOKENS_RULES_NAMESPACE`,e[e.INVALID_TOKEN_NAME=9]=`INVALID_TOKEN_NAME`,e[e.NO_NON_EMPTY_LOOKAHEAD=10]=`NO_NON_EMPTY_LOOKAHEAD`,e[e.AMBIGUOUS_PREFIX_ALTS=11]=`AMBIGUOUS_PREFIX_ALTS`,e[e.TOO_MANY_ALTS=12]=`TOO_MANY_ALTS`,e[e.CUSTOM_LOOKAHEAD_VALIDATION=13]=`CUSTOM_LOOKAHEAD_VALIDATION`})(G||={});var La=class e{static performSelfAnalysis(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT(`performSelfAnalysis`,()=>{let t;this.selfAnalysisDone=!0;let n=this.className;this.TRACE_INIT(`toFastProps`,()=>{Ct(this)}),this.TRACE_INIT(`Grammar Recording`,()=>{try{this.enableRecording(),x(this.definedRulesNames,e=>{let t=this[e].originalGrammarAction,n;this.TRACE_INIT(`${e} Rule`,()=>{n=this.topLevelRuleRecord(e,t)}),this.gastProductionsCache[e]=n})}finally{this.disableRecording()}});let r=[];if(this.TRACE_INIT(`Grammar Resolving`,()=>{r=ji({rules:y(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(r)}),this.TRACE_INIT(`Grammar Validations`,()=>{if(C(r)&&this.skipValidations===!1){let e=Mi({rules:y(this.gastProductionsCache),tokenTypes:y(this.tokensMap),errMsgProvider:Lr,grammarName:n}),t=fi({lookaheadStrategy:this.lookaheadStrategy,rules:y(this.gastProductionsCache),tokenTypes:y(this.tokensMap),grammarName:n});this.definitionErrors=this.definitionErrors.concat(e,t)}}),C(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT(`computeAllProdsFollows`,()=>{let e=qt(y(this.gastProductionsCache));this.resyncFollows=e}),this.TRACE_INIT(`ComputeLookaheadFunctions`,()=>{var e,t;(t=(e=this.lookaheadStrategy).initialize)==null||t.call(e,{rules:y(this.gastProductionsCache)}),this.preComputeLookaheadFunctions(y(this.gastProductionsCache))})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!C(this.definitionErrors))throw t=D(this.definitionErrors,e=>e.message),Error(`Parser Definition Errors detected:\n ${t.join(` +------------------------------- +`)}`)})}constructor(e,t){this.definitionErrors=[],this.selfAnalysisDone=!1;let n=this;if(n.initErrorHandler(t),n.initLexerAdapter(),n.initLooksAhead(t),n.initRecognizerEngine(e,t),n.initRecoverable(t),n.initTreeBuilder(t),n.initContentAssist(),n.initGastRecorder(t),n.initPerformanceTracer(t),k(t,`ignoredIssues`))throw Error(`The IParserConfig property has been deprecated. + Please use the flag on the relevant DSL method instead. + See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES + For further details.`);this.skipValidations=k(t,`skipValidations`)?t.skipValidations:Fa.skipValidations}};La.DEFER_DEFINITION_ERRORS_HANDLING=!1,Na(La,[qi,ea,ha,ga,va,_a,ya,ba,Da,Ma]);var Ra=class extends La{constructor(e,t=Fa){let n=j(t);n.outputCst=!0,super(e,n)}};function za(e,t){let n=e.lexer.tokenize(t);if(n.errors.length>0){let r=n.errors[0],i=Number.isFinite(r.offset)?r.offset:t.length,a=i+(Number.isFinite(r.length)?r.length:0);throw Error(`Error lexing ${e.diagramType} diagram: ${r.message} at line ${r.line??1}, column ${r.column??1} [${i},${a})`)}e.parser.input=n.tokens;let r=e.entry();if(e.parser.errors.length>0)throw Error(`Error parsing ${e.diagramType} diagram: ${e.parser.errors[0].message}`);e.visit(r)}n(za,`runChevrotainParse`);var K={SOLID_ARROW:0,BACK_ARROW:1,LINE_SOLID:2,CIRCLE_ARROW:3,CROSS_ARROW:4,CIRCLE_ARROW_REVERSED:5,CROSS_ARROW_REVERSED:6},Ba=`LR`,Va=s.usecase,Ha=n(()=>({actors:new Map,useCases:new Map,systemBoundaries:new Map,relationships:[],notes:new Map,jsonNodes:new Map,classDefs:new Map,symbols:new Map,direction:Ba,relationshipCounter:0,noteCounter:0,accTitle:``,accDescription:``,ast:void 0,config:structuredClone(Va)}),`createModel`),Ua=n(e=>{if(!(e.actors instanceof Map)||!(e.useCases instanceof Map)||!(e.systemBoundaries instanceof Map)||!Array.isArray(e.relationships)||!(e.notes instanceof Map)||!(e.jsonNodes instanceof Map)||!(e.classDefs instanceof Map)||!(e.symbols instanceof Map)||![`TB`,`TD`,`BT`,`RL`,`LR`].includes(e.direction)||!Number.isSafeInteger(e.relationshipCounter)||e.relationshipCounter<0||!Number.isSafeInteger(e.noteCounter)||e.noteCounter<0||typeof e.accTitle!=`string`||typeof e.accDescription!=`string`||!e.config)throw Error(`Cannot commit an incomplete usecase model`)},`assertCompleteModel`),q=Ha(),Wa=n(()=>structuredClone(q.config),`getConfig`),Ga=n(()=>q.ast,`getAST`),Ka=n(e=>{let t=structuredClone(e);Ua(t);let n=f(),a=l();try{i(t.accTitle),r(t.accDescription),q=t}catch(e){throw i(n),r(a),e}},`commit`),qa=n(()=>{q=Ha(),a()},`clear`),Ja=n(()=>q.actors,`getActors`),Ya=n(e=>q.actors.get(e),`getActor`),Xa=n(()=>q.useCases,`getUseCases`),Za=n(e=>q.useCases.get(e),`getUseCase`),Qa=n(()=>q.systemBoundaries,`getSystemBoundaries`),$a=n(e=>q.systemBoundaries.get(e),`getSystemBoundary`),eo=n(()=>q.relationships,`getRelationships`),to=n(()=>q.notes,`getNotes`),no=n(e=>q.notes.get(e),`getNote`),ro=n(()=>q.jsonNodes,`getJsonNodes`),io=n(e=>q.jsonNodes.get(e),`getJsonNode`),ao=n(()=>q.classDefs,`getClassDefs`),oo=n(e=>q.classDefs.get(e),`getClassDef`),so=n(()=>q.direction,`getDirection`),co=n(e=>{let t=new Map;for(let n of[`default`,...e]){let e=q.classDefs.get(n);if(e)for(let n of e.styles){let e=n.trim(),r=e.indexOf(`:`),i=(r===-1?e:e.slice(0,r)).trim();i&&t.set(i,e)}}return[...t.values()]},`getCompiledStyles`),lo=n(e=>e.replaceAll(`~`,`~0`).replaceAll(`/`,`~1`),`escapeJsonPointerPart`),uo=n(e=>typeof e==`string`?e:e===null?`null`:String(e),`displayJsonScalar`),fo=n((e,t,r=e=>e)=>{let i=[],a=n((e,t,n)=>{i.push({key:r(e),accessibleKey:r(t),value:r(n)})},`append`),o=n((e,n,r)=>{if(Array.isArray(e)){if(e.length===0){a(n,n,`[]`);return}if(e.every(e=>e===null||[`string`,`number`,`boolean`].includes(typeof e))){for(let[t,r]of e.entries())a(t===0?n:``,n,uo(r));return}for(let[t,i]of e.entries())o(i,`${n}[${t}]`,`${r}/${t}`);return}if(typeof e==`object`&&e){let i=e,s=t[r]??Object.keys(i);if(s.length===0){a(n,n,`{}`);return}for(let e of s){let t=n?`${n}.${e}`:e;o(i[e],t,`${r}/${lo(e)}`)}return}a(n,n,uo(e))},`visit`);return o(e,``,``),i},`flattenJsonRows`),po=n(e=>{switch(e.type){case`hollow`:return`usecaseActorHollow`;case`awesome`:return`usecaseActorAwesome`;case`icon`:return`usecaseActorIcon`;case`normal`:return`usecaseActor`}},`actorShape`),mo=n(e=>e.shape===`ellipse`?e.business?`usecaseBusiness`:`usecaseEllipse`:e.shape,`useCaseShape`),ho=n(e=>{switch(e){case K.SOLID_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_point`};case K.BACK_ARROW:return{arrowTypeStart:`arrow_point`,arrowTypeEnd:`none`};case K.CIRCLE_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_circle`};case K.CROSS_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_cross`};case K.CIRCLE_ARROW_REVERSED:return{arrowTypeStart:`arrow_circle`,arrowTypeEnd:`none`};case K.CROSS_ARROW_REVERSED:return{arrowTypeStart:`arrow_cross`,arrowTypeEnd:`none`};case K.LINE_SOLID:return{arrowTypeStart:`none`,arrowTypeEnd:`none`}}},`associationMarkers`),go=n(e=>{switch(e.type){case`include`:case`extend`:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_point`,pattern:`dotted`,label:e.type,labelType:`text`};case`generalization`:return{arrowTypeStart:`none`,arrowTypeEnd:`extension`,pattern:`solid`};case`association`:return{...ho(e.arrowType),pattern:`solid`,...e.label?{label:e.label}:{},...e.labelType?{labelType:e.labelType}:{}}}},`relationshipVisuals`),_o=n(e=>e.animate||e.animation?[`edge-animation-${e.animation??`fast`}`]:[],`animationClasses`),vo=n((...e)=>e.filter(e=>!!e).join(` `),`classNames`),yo={getConfig:Wa,createModel:Ha,commit:Ka,getAST:Ga,clear:qa,setDiagramTitle:c,getDiagramTitle:u,setAccTitle:i,getAccTitle:f,setAccDescription:r,getAccDescription:l,getActors:Ja,getActor:Ya,getUseCases:Xa,getUseCase:Za,getSystemBoundaries:Qa,getSystemBoundary:$a,getRelationships:eo,getNotes:to,getNote:no,getJsonNodes:ro,getJsonNode:io,getClassDefs:ao,getClassDef:oo,getDirection:so,getData:n(()=>{let e=d(),t={...q.config,...e.usecase},r=n(t=>p(t,e),`sanitize`),i=n(e=>r(q.actors.get(e)?.label??q.useCases.get(e)?.label??q.jsonNodes.get(e)?.id??q.notes.get(e)?.label??e),`endpointLabel`),a=[],o=[],s=0,c=0;for(let t of q.actors.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:po(t),isGroup:!1,padding:10,look:e.look,colorIndex:s++,cssClasses:vo(`default`,`usecase-actor`,`usecase-actor-${t.type}`,t.business&&`usecase-business`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),actorType:t.type,business:t.business,...t.icon?{icon:t.icon}:{},...t.stereotype?{stereotype:r(t.stereotype)}:{},...t.parentId?{parentId:t.parentId}:{}});for(let t of q.useCases.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:mo(t),isGroup:!1,padding:t.shape===`ellipse`?20:10,look:e.look,colorIndex:s++,cssClasses:vo(`default`,`usecase-element`,`usecase-${t.shape}`,t.business&&`usecase-business`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),business:t.business,...t.stereotype?{stereotype:r(t.stereotype)}:{},...t.parentId?{parentId:t.parentId}:{}});for(let t of q.notes.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:`note`,isGroup:!1,padding:10,look:e.look,cssClasses:`default usecase-note`,cssStyles:[],cssCompiledStyles:co([]),noteTarget:t.target,noteTargetLabel:r(q.actors.get(t.target)?.label??q.useCases.get(t.target)?.label??q.jsonNodes.get(t.target)?.id??t.target)});for(let t of q.jsonNodes.values())a.push({id:t.id,label:r(t.id),labelType:`text`,shape:`usecaseJsonTable`,isGroup:!1,padding:10,look:e.look,cssClasses:vo(`default`,`usecase-json-table`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),jsonRows:fo(t.value,t.propertyOrder,r)});for(let t of q.systemBoundaries.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:`usecaseSystemBoundary`,isGroup:!0,padding:20,look:e.look,colorIndex:c++,cssClasses:vo(`default`,`system-boundary`,`system-boundary-${t.type}`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),boundaryType:t.type});for(let t of q.relationships){let{label:n,...a}=go(t);o.push({id:t.id,start:t.source,end:t.target,source:t.source,target:t.target,sourceLabel:i(t.source),targetLabel:i(t.target),type:`edge`,relationshipType:t.type,internal:!1,...a,...n===void 0?{}:{label:r(n)},labelpos:`c`,classes:vo(`default`,`relationship`,`relationship-${t.type}`,...t.classes,..._o(t)),style:[...t.styles],cssCompiledStyles:co(t.classes),animate:t.animate,...t.animation?{animation:t.animation}:{},look:e.look,thickness:`normal`,minlen:t.minlen,isUserDefinedId:t.explicitId})}for(let t of q.notes.values())o.push({id:`${t.id}-edge`,start:t.id,end:t.target,source:t.id,target:t.target,type:`edge`,relationshipType:`note`,sourceLabel:i(t.id),targetLabel:i(t.target),internal:!0,pattern:`dotted`,arrowTypeStart:`none`,arrowTypeEnd:`none`,labelpos:`c`,classes:`default relationship relationship-note`,style:[],cssCompiledStyles:co([]),animate:!1,look:e.look,thickness:`normal`,minlen:1,isUserDefinedId:!1});for(let e of a)e.wrappingWidth??=t.wrappingWidth,!e.isGroup&&!e.shape.startsWith(`usecaseActor`)&&(e.minWidth??=t.minNodeWidth),(e.shape===`usecaseEllipse`||e.shape===`usecaseBusiness`)&&(e.spreadPorts=!0);return{nodes:a,edges:o,config:e,type:`usecase`,layoutAlgorithm:`dagre`,direction:so(),nodeSpacing:t.nodeSpacing,rankSpacing:t.rankSpacing,actorFontSize:t.actorFontSize,actorFontFamily:t.actorFontFamily,actorFontWeight:t.actorFontWeight,usecaseFontSize:t.usecaseFontSize,usecaseFontFamily:t.usecaseFontFamily,usecaseFontWeight:t.usecaseFontWeight,diagramPadding:t.diagramPadding,useMaxWidth:t.useMaxWidth,markers:[`point`,`circle`,`cross`,`extension`]}},`getData`)};function bo(e,t,n){let r=[n];return r.index=t,r.input=e,r}n(bo,`customMatch`);var xo=n((e,t)=>{if(e[t]!==`"`||e[t+1]!=="`")return null;for(let n=t+2;n{if(e[t]!==`%`||e[t+1]!==`%`)return null;for(let n=t-1;n>=0;n--){let t=e[n];if(t===` +`||t===`\r`)break;if(t!==` `&&t!==` `)return null}let n=t+2;for(;n{for(let n=t-1;n>=0;n--){let t=e[n];if(t===` +`||t===`\r`)return!0;if(t!==` `&&t!==` `)return!1}return!0},`isIndentedLineStart`),wo=n((e,t,n)=>{if(!Co(e,t))return null;let r=n.exec(e.slice(t));return r?bo(e,t,r[0]):null},`matchAccessibilityLine`),To=n((e,t)=>{if(!Co(e,t))return null;let n=/^accDescr[\t ]*{/.exec(e.slice(t));if(!n)return null;let r=e.indexOf(`}`,t+n[0].length);return r===-1?null:bo(e,t,e.slice(t,r+1))},`matchAccDescrBlock`),Eo=n((e,t)=>{if(e[t]!==`{`)return null;let n=0,r=!1,i=!1;for(let a=t;a{let n=e.indexOf(`>>`,t);if(n===-1||/[\n\r]/.test(e.slice(t,n)))return null;let r=e.slice(t,n);return r.trim()?bo(e,t,r):null},`matchStereotypeText`),J=U({name:`LABEL_TEXT`,pattern:H.NA}),Oo=U({name:`WORD`,pattern:H.NA,categories:J}),ko=U({name:`NUMBER`,pattern:/(?:\d+\.\d+|\d+|\.\d+)(?:[A-Za-z]+)?/,categories:J}),Y=U({name:`IDENTIFIER`,pattern:/\w+/,longer_alt:ko,categories:Oo}),Ao=U({name:`HWS`,pattern:/[\t ]+/,group:H.SKIPPED}),jo=U({name:`MARKDOWN_STRING`,pattern:xo,start_chars_hint:[`"`],line_breaks:!0}),Mo=U({name:`UNCLOSED_MARKDOWN_STRING`,pattern:/"`[^]*/,line_breaks:!0}),No=U({name:`COMMENT`,pattern:So,start_chars_hint:[`%`],line_breaks:!1}),Po=U({name:`NEWLINE`,pattern:/\r\n|\n|\r/,line_breaks:!0}),Fo=U({name:`ACC_DESCR_BLOCK`,pattern:To,start_chars_hint:[`a`],line_breaks:!0}),Io=/^accTitle[\t ]*:[^\n\r]*/,Lo=/^accDescr[\t ]*:[^\n\r]*/,Ro=U({name:`ACC_TITLE_LINE`,pattern:n((e,t)=>wo(e,t,Io),`pattern`),start_chars_hint:[`a`],line_breaks:!1}),zo=U({name:`ACC_DESCR_LINE`,pattern:n((e,t)=>wo(e,t,Lo),`pattern`),start_chars_hint:[`a`],line_breaks:!1}),Bo=U({name:`JSON_DECLARATION_START`,pattern:/json[\t ]+\w+[\t ]*@[\t ]*(?={)/,push_mode:`jsonBody`}),Vo=U({name:`JSON_OBJECT_LITERAL`,pattern:Eo,start_chars_hint:[`{`],line_breaks:!0,pop_mode:!0}),Ho=U({name:`UNCLOSED_JSON_OBJECT_LITERAL`,pattern:/{[^]*/,line_breaks:!0,pop_mode:!0}),X=n((e,t)=>U({name:e,pattern:t,longer_alt:Y,categories:Oo}),`keyword`),Uo=X(`USECASE`,/usecase-beta/),Wo=X(`ACTOR`,/actor/),Go=X(`SYSTEM_BOUNDARY`,/systemBoundary/),Ko=X(`END`,/end/),qo=X(`DIRECTION`,/direction/),Jo=X(`TD`,/TD/),Yo=X(`TB`,/TB/),Xo=X(`BT`,/BT/),Zo=X(`LR`,/LR/),Qo=X(`RL`,/RL/),$o=X(`NOTE`,/note/),es=X(`FOR`,/for/),ts=X(`JSON`,/json/),ns=X(`CLASS_DEF`,/classDef/),rs=X(`CLASS`,/class/),is=X(`STYLE`,/style/),as=X(`INCLUDE`,/include/i),os=X(`EXTEND`,/extend/i),ss=X(`TRUE`,/true/),cs=X(`FALSE`,/false/),ls=U({name:`GENERALIZATION`,pattern:/--\|>/}),us=U({name:`DEPENDENCY_ARROW`,pattern:/\.\.>/}),ds=U({name:`STEREOTYPE_START`,pattern:/<>/,pop_mode:!0}),ps=U({name:`STEREOTYPE_TEXT`,pattern:Do,line_breaks:!1}),ms=U({name:`UNCLOSED_STEREOTYPE_TEXT`,pattern:/[^\n\r]+/,line_breaks:!1,pop_mode:!0}),hs=U({name:`CLASS_SEPARATOR`,pattern:/:::/}),gs=U({name:`FORWARD_SOLID`,pattern:/--+>/}),_s=U({name:`BACKWARD_SOLID`,pattern:/<--+/}),vs=U({name:`FORWARD_CIRCLE`,pattern:/--o/}),ys=U({name:`BACKWARD_CIRCLE`,pattern:/o--/}),bs=U({name:`FORWARD_CROSS`,pattern:/--x/}),xs=U({name:`BACKWARD_CROSS`,pattern:/x--/}),Z=U({name:`MARKERLESS_SOLID`,pattern:/--+/}),Ss=U({name:`METADATA_START`,pattern:/@{/}),Cs=U({name:`AT`,pattern:/@/,categories:J}),ws=U({name:`LBRACE`,pattern:/{/}),Ts=U({name:`RBRACE`,pattern:/}/}),Es=U({name:`LBRACKET`,pattern:/\[/}),Ds=U({name:`RBRACKET`,pattern:/]/}),Os=U({name:`LPAREN`,pattern:/\(/}),ks=U({name:`RPAREN`,pattern:/\)/}),As=U({name:`COMMA`,pattern:/,/,categories:J}),js=U({name:`COLON`,pattern:/:/,categories:J}),Ms=U({name:`HASH_COLOR`,pattern:/#[\dA-Fa-f]+/,categories:J}),Ns=U({name:`PLAIN_STRING`,pattern:/"[^\n\r"]*"|'[^\n\r']*'/}),Ps=U({name:`CSS_IDENTIFIER`,pattern:/--[A-Z_a-z][\w-]*|[A-Z_a-z]\w*(?:-\w+)+/,categories:J}),Fs=U({name:`CSS_ESCAPED_COMMA`,pattern:/\\,/,categories:J}),Is=U({name:`DASH`,pattern:/-/,categories:J}),Ls=U({name:`DOT`,pattern:/\./,categories:J}),Rs=U({name:`PERCENT`,pattern:/%/,categories:J}),zs=U({name:`CSS_PUNCTUATION`,pattern:/[!#$&*+/=?^_|~]/,categories:J}),Bs=[J,Oo,Ao,jo,Mo,No,Po,Fo,Ro,zo,Bo,Uo,Wo,Go,Ko,qo,Jo,Yo,Xo,Zo,Qo,$o,es,ts,ns,rs,is,as,os,ss,cs,ls,us,ds,hs,gs,_s,vs,ys,bs,xs,Z,Ss,Cs,ws,Ts,Es,Ds,Os,ks,As,js,Ms,Ns,Ps,Y,ko,Fs,Is,Ls,Rs,zs,U({name:`LABEL_PUNCTUATION`,pattern:/[;<>\\`]/,categories:J}),U({name:`LABEL_SYMBOL`,pattern:/[^\t\n\r !-~]+/,categories:J})],Vs={defaultMode:`defaultMode`,modes:{defaultMode:[...Bs],jsonBody:[Vo,Ho],stereotype:[fs,ps,ms]}},Hs=[...Bs,Vo,Ho,fs,ps,ms],Us=new H(Vs),Ws=n(e=>Pr(e,J)||e.tokenType===Ns||e.tokenType===jo,`isLabelToken`),Gs={allowmixing:!0,newpage:!0,package:!0,rectangle:!0,skinparam:!0},Ks=new class extends Ra{static{n(this,`UsecaseParser`)}constructor(){super(Hs,{nodeLocationTracking:`full`}),this.RULE(`start`,()=>{this.CONSUME(Uo),this.SUBRULE(this.lineEnd),this.MANY(()=>this.SUBRULE(this.line))}),this.RULE(`line`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.blankLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.commentLine),`ALT`)},{GATE:n(()=>this.isStatementStart(),`GATE`),ALT:n(()=>this.SUBRULE(this.statement),`ALT`)}])}),this.RULE(`statement`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.accTitleStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.accDescrStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.directionStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.actorStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.systemBoundaryStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.noteStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.jsonStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.classDefStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.classStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.styleStatement),`ALT`)},{GATE:n(()=>this.isMetadataAssignment(),`GATE`),ALT:n(()=>this.SUBRULE(this.metadataAssignmentStatement),`ALT`)},{GATE:n(()=>!this.isForbiddenPlantUmlStatement(),`GATE`),ALT:n(()=>this.SUBRULE(this.entityStatement),`ALT`)}])}),this.RULE(`lineEnd`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Po),`ALT`)},{ALT:n(()=>this.CONSUME(Mr),`ALT`)}])}),this.RULE(`blankLine`,()=>{this.CONSUME(Po)}),this.RULE(`commentLine`,()=>{this.CONSUME(No),this.SUBRULE(this.lineEnd)}),this.RULE(`accTitleStatement`,()=>{this.CONSUME(Ro),this.SUBRULE(this.lineEnd)}),this.RULE(`accDescrStatement`,()=>{this.OR([{ALT:n(()=>this.CONSUME(zo),`ALT`)},{ALT:n(()=>this.CONSUME(Fo),`ALT`)}]),this.SUBRULE(this.lineEnd)}),this.RULE(`actorStatement`,()=>{this.CONSUME(Wo),this.SUBRULE(this.actorItem),this.OPTION(()=>{this.OR([{ALT:n(()=>this.AT_LEAST_ONE(()=>{this.CONSUME(As),this.SUBRULE2(this.actorItem)}),`ALT`)},{ALT:n(()=>this.SUBRULE(this.relationTail),`ALT`)}])}),this.SUBRULE(this.lineEnd)}),this.RULE(`actorItem`,()=>{this.SUBRULE(this.actorName),this.OPTION(()=>this.SUBRULE(this.metadata)),this.OPTION2(()=>this.SUBRULE(this.stereotype)),this.OPTION3(()=>this.SUBRULE(this.classSuffix))}),this.RULE(`actorName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`actorDeclarationOnly`,()=>{this.CONSUME(Wo),this.SUBRULE(this.actorItem),this.MANY(()=>{this.CONSUME(As),this.SUBRULE2(this.actorItem)}),this.SUBRULE(this.lineEnd)}),this.RULE(`entityStatement`,()=>{this.SUBRULE(this.entityName),this.OPTION(()=>this.SUBRULE(this.relationTail)),this.SUBRULE(this.lineEnd)}),this.RULE(`entityName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.OR2([{ALT:n(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)},`ALT`)},{ALT:n(()=>{this.CONSUME(Es),this.SUBRULE2(this.nodeLabel),this.CONSUME(Ds)},`ALT`)}])})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}]),this.OPTION2(()=>this.SUBRULE(this.useCaseMetadata)),this.OPTION3(()=>this.SUBRULE(this.stereotype)),this.OPTION4(()=>this.SUBRULE(this.classSuffix))}),this.RULE(`nodeLabel`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)},{ALT:n(()=>this.AT_LEAST_ONE(()=>this.CONSUME(J)),`ALT`)}])}),this.RULE(`useCaseMetadata`,()=>{this.SUBRULE(this.metadata)}),this.RULE(`relationTail`,()=>{this.OPTION({GATE:n(()=>this.LA(1).tokenType===Y&&this.LA(2).tokenType===Cs,`GATE`),DEF:n(()=>{this.CONSUME(Y),this.CONSUME(Cs)},`DEF`)}),this.SUBRULE(this.arrow),this.SUBRULE(this.entityName)}),this.RULE(`arrow`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.semanticRelation),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.markerlessSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardCircleOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardCircleOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardCrossOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardCrossOperator),`ALT`)}])}),this.RULE(`forwardSolidOperator`,()=>{this.CONSUME(gs)}),this.RULE(`backwardSolidOperator`,()=>{this.CONSUME(_s),this.OPTION({GATE:n(()=>this.LA(0).image===`<--`&&this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`markerlessSolidOperator`,()=>{this.CONSUME(Z),this.OPTION({GATE:n(()=>this.LA(0).image===`--`&&this.hasLabeledRight([gs,Z,vs,bs]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.OR([{ALT:n(()=>this.CONSUME(gs),`ALT`)},{ALT:n(()=>this.CONSUME2(Z),`ALT`)},{ALT:n(()=>this.CONSUME(vs),`ALT`)},{ALT:n(()=>this.CONSUME(bs),`ALT`)}])},`DEF`)})}),this.RULE(`forwardCircleOperator`,()=>{this.CONSUME(vs)}),this.RULE(`backwardCircleOperator`,()=>{this.CONSUME(ys),this.OPTION({GATE:n(()=>this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`forwardCrossOperator`,()=>{this.CONSUME(bs)}),this.RULE(`backwardCrossOperator`,()=>{this.CONSUME(xs),this.OPTION({GATE:n(()=>this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`edgeLabel`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)},{ALT:n(()=>this.AT_LEAST_ONE(()=>this.CONSUME(J)),`ALT`)}])}),this.RULE(`semanticRelation`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(us),this.CONSUME(js),this.OR2([{ALT:n(()=>this.CONSUME(as),`ALT`)},{ALT:n(()=>this.CONSUME(os),`ALT`)}])},`ALT`)},{ALT:n(()=>this.CONSUME(ls),`ALT`)}])}),this.RULE(`metadata`,()=>{this.CONSUME(Ss),this.MANY(()=>this.CONSUME(Po)),this.OPTION(()=>{this.SUBRULE(this.metadataProperty),this.MANY2(()=>{this.SUBRULE(this.metadataSeparator),this.SUBRULE2(this.metadataProperty)}),this.OPTION2(()=>this.CONSUME(As)),this.MANY3(()=>this.CONSUME2(Po))}),this.CONSUME(Ts)}),this.RULE(`metadataProperty`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Y),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)}]),this.CONSUME(js),this.OR2([{ALT:n(()=>this.CONSUME2(Y),`ALT`)},{ALT:n(()=>this.CONSUME2(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(ss),`ALT`)},{ALT:n(()=>this.CONSUME(cs),`ALT`)}])}),this.RULE(`metadataSeparator`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(As),this.MANY(()=>this.CONSUME(Po))},`ALT`)},{ALT:n(()=>{this.AT_LEAST_ONE(()=>this.CONSUME2(Po)),this.OPTION(()=>this.CONSUME2(As)),this.MANY2(()=>this.CONSUME3(Po))},`ALT`)}])}),this.RULE(`systemBoundaryStatement`,()=>{this.CONSUME(Go),this.SUBRULE(this.systemBoundaryName),this.OPTION(()=>this.SUBRULE(this.metadata)),this.OPTION2(()=>this.SUBRULE(this.classSuffix)),this.SUBRULE(this.lineEnd),this.SUBRULE(this.systemBoundaryContent),this.CONSUME(Ko),this.SUBRULE2(this.lineEnd)}),this.RULE(`systemBoundaryName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.OR2([{ALT:n(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)},`ALT`)},{ALT:n(()=>{this.CONSUME(Es),this.SUBRULE2(this.nodeLabel),this.CONSUME(Ds)},`ALT`)}])})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`systemBoundaryContent`,()=>{this.MANY(()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.blankLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.commentLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.boundaryElement),`ALT`)}])})}),this.RULE(`boundaryElement`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.actorDeclarationOnly),`ALT`)},{ALT:n(()=>{this.SUBRULE(this.entityName),this.SUBRULE(this.lineEnd)},`ALT`)}])}),this.RULE(`metadataAssignmentStatement`,()=>{this.SUBRULE(this.metadataAssignmentTarget),this.SUBRULE(this.metadata),this.SUBRULE(this.lineEnd)}),this.RULE(`metadataAssignmentTarget`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Y),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`noteStatement`,()=>{this.CONSUME($o),this.CONSUME(es),this.CONSUME(Y),this.SUBRULE(this.nodeLabel),this.SUBRULE(this.lineEnd)}),this.RULE(`stereotype`,()=>{this.CONSUME(ds),this.CONSUME(ps),this.CONSUME(fs)}),this.RULE(`classSuffix`,()=>{this.CONSUME(hs),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)})}),this.RULE(`jsonStatement`,()=>{this.CONSUME(Bo),this.CONSUME(Vo),this.OPTION(()=>this.SUBRULE(this.classSuffix)),this.SUBRULE(this.lineEnd)}),this.RULE(`directionStatement`,()=>{this.CONSUME(qo),this.OR([{ALT:n(()=>this.CONSUME(Jo),`ALT`)},{ALT:n(()=>this.CONSUME(Yo),`ALT`)},{ALT:n(()=>this.CONSUME(Xo),`ALT`)},{ALT:n(()=>this.CONSUME(Zo),`ALT`)},{ALT:n(()=>this.CONSUME(Qo),`ALT`)}]),this.SUBRULE(this.lineEnd)}),this.RULE(`classDefStatement`,()=>{this.CONSUME(ns),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)}),this.SUBRULE(this.styles),this.SUBRULE(this.lineEnd)}),this.RULE(`classStatement`,()=>{this.CONSUME(rs),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)}),this.CONSUME3(Y),this.MANY2(()=>{this.CONSUME2(As),this.CONSUME4(Y)}),this.SUBRULE(this.lineEnd)}),this.RULE(`styleStatement`,()=>{this.CONSUME(is),this.CONSUME(Y),this.SUBRULE(this.styles),this.SUBRULE(this.lineEnd)}),this.RULE(`styles`,()=>{this.SUBRULE(this.styleValue),this.MANY(()=>{this.CONSUME(As),this.SUBRULE2(this.styleValue)})}),this.RULE(`styleValue`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Oo),`ALT`)},{ALT:n(()=>this.CONSUME(Ps),`ALT`)},{ALT:n(()=>{this.CONSUME(Z),this.CONSUME2(Oo)},`ALT`)}]),this.CONSUME(js),this.AT_LEAST_ONE(()=>this.SUBRULE(this.styleComponent))}),this.RULE(`styleComponent`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Oo),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(ko),`ALT`)},{ALT:n(()=>this.CONSUME(Ms),`ALT`)},{ALT:n(()=>this.CONSUME(Ps),`ALT`)},{ALT:n(()=>this.CONSUME(Fs),`ALT`)},{ALT:n(()=>this.CONSUME(Is),`ALT`)},{ALT:n(()=>this.CONSUME(Ls),`ALT`)},{ALT:n(()=>this.CONSUME(Rs),`ALT`)},{ALT:n(()=>this.CONSUME(zs),`ALT`)},{ALT:n(()=>this.CONSUME(js),`ALT`)},{ALT:n(()=>this.CONSUME(Os),`ALT`)},{ALT:n(()=>this.CONSUME(ks),`ALT`)},{ALT:n(()=>this.CONSUME(Es),`ALT`)},{ALT:n(()=>this.CONSUME(Ds),`ALT`)},{ALT:n(()=>this.CONSUME(ws),`ALT`)},{ALT:n(()=>this.CONSUME(Ts),`ALT`)},{ALT:n(()=>this.CONSUME(Cs),`ALT`)},{ALT:n(()=>this.CONSUME(Z),`ALT`)}])}),this.performSelfAnalysis()}isMetadataAssignment(){let e=this.LA(1).tokenType;return(e===Y||e===Ns||e===jo)&&this.LA(2).tokenType===Ss}isStatementStart(){let e=this.LA(1).tokenType;return e!==Mr&&e!==Po&&e!==No}isForbiddenPlantUmlStatement(){return this.LA(1).tokenType===Y&&Gs[this.LA(1).image.toLowerCase()]===!0}hasLabeledRight(e){if(!Ws(this.LA(1)))return!1;for(let t=2;;t++){let n=this.LA(t);if(e.includes(n.tokenType))return!0;if(!Ws(n))return!1}}},qs=class extends Error{constructor(e,t,n){super(`${e} (line ${t}, column ${n})`),this.line=t,this.column=n,this.name=`UsecaseJsonError`}static{n(this,`UsecaseJsonError`)}},Js=n((e,t,n,r)=>{let i=n,a=r,o=Math.min(Math.max(t,0),e.length);for(let t=0;t{let i=/\bposition (\d+)\b/u.exec(e);if(i)return Js(t,Number.parseInt(i[1],10),n,r);let a=/\bline (\d+) column (\d+)\b/u.exec(e);if(a){let e=Number.parseInt(a[1],10),t=Number.parseInt(a[2],10);return{line:n+e-1,column:e===1?r+t-1:t}}if(/unexpected end|end of json input/iu.test(e))return Js(t,t.length,n,r)},`locationFromErrorMessage`),Q=class extends Error{constructor(e){super(`Invalid JSON token`),this.offset=e}static{n(this,`JsonWalkError`)}},Xs=class{constructor(e){this.text=e,this.offset=0,this.propertyOrder={}}static{n(this,`PropertyOrderCollector`)}collect(){if(this.skipWhitespace(),this.collectValue(``),this.skipWhitespace(),this.offset!==this.text.length)throw new Q(this.offset);return this.propertyOrder}collectValue(e){this.skipWhitespace();let t=this.text[this.offset];if(t===`{`)this.collectObject(e);else if(t===`[`)this.collectArray(e);else if(t===`"`)this.readString(!1);else if(t===`t`)this.consumeLiteral(`true`);else if(t===`f`)this.consumeLiteral(`false`);else if(t===`n`)this.consumeLiteral(`null`);else if(t===`-`||t>=`0`&&t<=`9`)this.consumeNumber();else throw new Q(this.offset)}collectObject(e){this.offset++;let t=[],n=new Set;if(this.propertyOrder[e]=t,this.skipWhitespace(),this.text[this.offset]===`}`){this.offset++;return}for(;this.offset=`1`&&this.text[this.offset]<=`9`)for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++;else throw new Q(this.offset);if(this.text[this.offset]===`.`){if(this.offset++,this.text[this.offset]<`0`||this.text[this.offset]>`9`)throw new Q(this.offset);for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++}if(this.text[this.offset]===`e`||this.text[this.offset]===`E`){if(this.offset++,(this.text[this.offset]===`+`||this.text[this.offset]===`-`)&&this.offset++,this.text[this.offset]<`0`||this.text[this.offset]>`9`)throw new Q(this.offset);for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++}}skipWhitespace(){for(;this.offset({shape:e.type===`normal`?`actor`:e.type===`hollow`?`actor-hollow`:e.type===`awesome`?`actor-awesome`:`actor-icon`,...e.label===e.id?{}:{label:e.label},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`actor`,actorType:e.type,business:e.business,labelType:e.labelType,...e.icon?{icon:e.icon}:{},...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{}}}),`actorNode`),$s=n(e=>({shape:e.shape,...e.label===e.id?{}:{label:e.label},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`usecase`,useCaseShape:e.shape,business:e.business,labelType:e.labelType,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{}}}),`useCaseNode`),ec=n(e=>({label:e.label,shape:`note`,attrs:{kind:`note`,target:e.target,labelType:e.labelType}}),`noteNode`),tc=n(e=>({label:e.id,shape:`json-table`,...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`json`,value:e.value,propertyOrder:e.propertyOrder,labelType:`text`}}),`jsonNode`),nc=n(e=>({id:e.id,source:e.source,target:e.target,...e.label?{label:e.label}:{},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{relationshipType:e.type,arrowType:e.arrowType,minlen:e.minlen,explicitId:e.explicitId,animate:e.animate,...e.animation?{animation:e.animation}:{},...e.labelType?{labelType:e.labelType}:{}}}),`relationshipEdge`),rc=n(e=>({id:`${e.id}-edge`,source:e.id,target:e.target,attrs:{relationshipType:`note`,arrowType:K.LINE_SOLID,pattern:`dotted`,minlen:1,explicitId:!1,animate:!1,internal:!0}}),`noteEdge`),ic=n((e,t,n,r)=>{let i={};for(let t of e.getActors().values())i[t.id]=Qs(t);for(let t of e.getUseCases().values())i[t.id]=$s(t);for(let t of e.getNotes().values())i[t.id]=ec(t);for(let t of e.getJsonNodes().values())i[t.id]=tc(t);let a={};for(let t of e.getSystemBoundaries().values())a[t.id]={...t.label===t.id?{}:{title:t.label},nodes:[...t.members],...t.classes.length?{classes:[...t.classes]}:{},...t.styles.length?{styles:[...t.styles]}:{},attrs:{kind:`systemBoundary`,boundaryType:t.type,labelType:t.labelType}};let o={};for(let t of e.getClassDefs().values())o[t.id]={styles:[...t.styles]};let s=e.getDirection();return{version:1,diagramType:`usecase`,source:t,header:{keyword:`usecase`,direction:s===`TD`?`TB`:s,span:n},...e.getAccTitle()?{accTitle:e.getAccTitle()}:{},...e.getAccDescription()?{accDescr:e.getAccDescription()}:{},nodes:i,edges:[...e.getRelationships().map(nc),...[...e.getNotes().values()].map(rc)],groups:a,classDefs:o,statements:r}},`buildUsecaseGraphAST`),$=n(e=>`line ${e.line}, column ${e.column} [${e.span[0]},${e.span[1]})`,`locationText`),ac=n(e=>e===void 0?``:` (label "${e}")`,`labelSuffix`),oc=n(e=>e.generated?e.label:void 0,`generatedFrom`),sc=n((e,t)=>{for(let n of t)e.includes(n)||e.push(n)},`pushUnique`),cc=class{constructor(e){this.db=e,this.source=``,this.statements=[],this.elements=[],this.boundaries=[],this.jsonDrafts=[],this.relationshipDrafts=[],this.noteDrafts=[],this.metadataAssignments=[],this.classAssignments=[],this.styleAssignments=[],this.classDefinitions=[],this.directions=[],this.model=e.createModel()}static{n(this,`UsecaseModelBuilder`)}reset(e){this.model=this.db.createModel(),this.source=e,this.statements=[],this.elements.length=0,this.boundaries.length=0,this.jsonDrafts.length=0,this.relationshipDrafts.length=0,this.noteDrafts.length=0,this.metadataAssignments.length=0,this.classAssignments.length=0,this.styleAssignments.length=0,this.classDefinitions.length=0,this.directions.length=0}addElement(e){this.elements.push(e)}addBoundary(e){this.boundaries.push(e)}addJson(e){this.jsonDrafts.push(e)}addRelationship(e){this.relationshipDrafts.push(e)}addNote(e){this.noteDrafts.push(e)}addMetadataAssignment(e,t,n,r){this.metadataAssignments.push({target:e,targetLocation:t,metadata:n,statement:r})}addClassDef(e,t){this.classDefinitions.push({ids:e,styles:t})}addClassAssignment(e,t){this.classAssignments.push({targets:e,classes:t})}addStyleAssignment(e,t,n){this.styleAssignments.push({target:e,location:t,styles:n})}setDirection(e){this.directions.push(e===`TD`?`TB`:e)}setAccTitle(e){this.model.accTitle=e}setAccDescription(e){this.model.accDescription=e}setStatements(e){this.statements=e}getActors(){return this.model.actors}getUseCases(){return this.model.useCases}getSystemBoundaries(){return this.model.systemBoundaries}getRelationships(){return this.model.relationships}getNotes(){return this.model.notes}getJsonNodes(){return this.model.jsonNodes}getClassDefs(){return this.model.classDefs}getDirection(){return this.model.direction}getAccTitle(){return this.model.accTitle}getAccDescription(){return this.model.accDescription}finalize(e){let t=new Map,n=new Map,r=new Map,i=new Map;for(let e of this.relationshipDrafts)this.recordFirst(i,e.source.id,e.source.location.span[0]),this.recordFirst(i,e.target.id,e.target.location.span[0]);for(let e of this.elements)this.recordFirst(i,e.id,e.location.span[0]);for(let e of this.boundaries)this.recordFirst(i,e.id,e.location.span[0]);for(let e of this.jsonDrafts)this.recordFirst(i,e.id,e.location.span[0]);let a=[...this.elements.map(e=>({offset:e.location.span[0],type:`element`,value:e})),...this.boundaries.map(e=>({offset:e.location.span[0],type:`boundary`,value:e})),...this.jsonDrafts.map(e=>({offset:e.location.span[0],type:`json`,value:e})),...this.relationshipDrafts.filter(e=>e.explicitId).map(e=>({offset:e.explicitIdLocation.span[0],type:`edge`,value:e}))].sort((e,t)=>e.offset-t.offset);for(let e of a)e.type===`element`?this.collectElement(e.value,t,n):e.type===`boundary`?this.collectBoundary(e.value,t,r):e.type===`json`?this.registerUnique(t,e.value.id,`json`,e.value.location,!1):this.registerUnique(t,e.value.explicitId,`edge`,e.value.explicitIdLocation,!1);this.materializeElements(n,i),this.materializeBoundaries(r,i),this.materializeJson(i);let o=this.materializeRelationships(t,n,i);this.reorderElements(n,i),this.applyMetadataAssignments(t,n,r,o),this.validateAndRefreshElements(n),this.refreshBoundaries(r,n),this.materializeNotes(t),this.applyClassDefinitions(),this.applyClassesAndStyles(t,o),this.model.direction=this.directions.at(-1)??this.model.direction,this.model.symbols=new Map([...t].map(([e,t])=>[e,t.kind]));let s=ic(this,this.source,e,this.statements);return this.model.ast=s,this.db.commit(this.model),s}collectElement(e,t,n){let r=t.get(e.id),i=oc({generated:e.generated,label:e.label.text});r&&r.kind!==e.kind&&this.conflict(`ID '${e.id}' is declared as both ${r.kind} and ${e.kind}`,e.location,r.location,i,oc(r)),r&&(r.generated||e.generated)&&this.conflict(`Generated ID '${e.id}' collides with another declaration`,e.location,r.location,i,oc(r));let a=n.get(e.id);if(!a){let r={kind:e.kind,id:e.id,label:e.label,location:e.location,generated:e.generated,classes:[...e.classes],...e.parentId?{parentId:e.parentId,parentLocation:e.parentLocation}:{},...e.shape?{shape:e.shape}:{},...e.stereotype?{stereotype:e.stereotype,stereotypeLocation:e.location}:{}};this.applyDeclarationMetadata(r,e.metadata),n.set(e.id,r),t.set(e.id,{kind:e.kind,location:e.location,generated:e.generated,label:e.label.text});return}(a.label.text!==e.label.text||a.label.type!==e.label.type)&&this.conflict(`ID '${e.id}' has conflicting labels`,e.location,a.location),e.shape&&a.shape&&e.shape!==a.shape&&this.conflict(`Use case '${e.id}' has conflicting shapes`,e.location,a.location),e.parentId&&a.parentId&&e.parentId!==a.parentId&&this.conflict(`Element '${e.id}' belongs to more than one system boundary`,e.parentLocation??e.location,a.parentLocation??a.location),e.stereotype&&a.stereotype&&e.stereotype!==a.stereotype&&this.conflict(`Element '${e.id}' has conflicting stereotypes`,e.location,a.stereotypeLocation??a.location),a.shape??=e.shape,a.parentId??=e.parentId,a.parentLocation??=e.parentLocation,a.stereotype??=e.stereotype,a.stereotypeLocation??=e.stereotype?e.location:void 0,sc(a.classes,e.classes),this.applyDeclarationMetadata(a,e.metadata)}collectBoundary(e,t,n){let r=t.get(e.id),i=oc({generated:e.generated,label:e.label.text});r&&r.kind!==`boundary`&&this.conflict(`ID '${e.id}' is declared as both ${r.kind} and boundary`,e.location,r.location,i,oc(r)),r&&(r.generated||e.generated)&&this.conflict(`Generated ID '${e.id}' collides with another declaration`,e.location,r.location,i,oc(r));let a=n.get(e.id);if(a){(a.label.text!==e.label.text||a.label.type!==e.label.type)&&this.conflict(`Boundary '${e.id}' has conflicting titles`,e.location,a.location),sc(a.classes,e.classes);return}n.set(e.id,{id:e.id,label:e.label,location:e.location,generated:e.generated,classes:[...e.classes],styles:[],members:[]}),t.set(e.id,{kind:`boundary`,location:e.location,generated:e.generated,label:e.label.text})}materializeElements(e,t){for(let n of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0)))this.setElementModel(n)}materializeBoundaries(e,t){for(let n of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0)))this.model.systemBoundaries.set(n.id,{id:n.id,label:n.label.text,labelType:n.label.type,type:n.type??`rect`,members:[],classes:[...n.classes],styles:[...n.styles]})}materializeJson(e){for(let t of[...this.jsonDrafts].sort((t,n)=>(e.get(t.id)??0)-(e.get(n.id)??0)))this.model.jsonNodes.set(t.id,{id:t.id,value:t.value,propertyOrder:t.propertyOrder,classes:[...t.classes],styles:[]})}materializeRelationships(e,t,n){let r=new Map,i=0;for(let a of this.relationshipDrafts){let o=this.resolveEndpoint(a.source,e,t,n),s=this.resolveEndpoint(a.target,e,t,n);this.validateRelationship(a,o,s,e);let c=a.explicitId??`edge-${i++}`,l={id:c,explicitId:!!a.explicitId,source:a.source.id,target:a.target.id,type:a.type,arrowType:a.arrowType,...a.label?{label:a.label.text,labelType:a.label.type}:{},minlen:a.minlen,classes:[],styles:[],animate:!1};this.model.relationships.push(l),r.set(c,{draft:a,relationship:l})}return this.model.relationshipCounter=i,r}resolveEndpoint(e,t,n,r){if(e.classesOnReference&&!e.declaration)throw Error(`Relationship endpoint '${e.id}' uses ::: without declaring the node at ${$(e.location)}`);let i=t.get(e.id);return i?i.kind:(n.set(e.id,{kind:`usecase`,id:e.id,label:e.label,location:e.location,generated:e.generated,shape:`ellipse`,classes:[]}),t.set(e.id,{kind:`usecase`,location:e.location,generated:e.generated,label:e.label.text}),this.recordFirst(r,e.id,e.location.span[0]),`usecase`)}reorderElements(e,t){let n=new Map(this.model.actors),r=new Map(this.model.useCases);this.model.actors.clear(),this.model.useCases.clear();for(let i of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0))){!n.has(i.id)&&!r.has(i.id)&&this.setElementModel(i);let e=n.get(i.id)??this.model.actors.get(i.id),t=r.get(i.id)??this.model.useCases.get(i.id);e?this.model.actors.set(i.id,e):t&&this.model.useCases.set(i.id,t)}}applyMetadataAssignments(e,t,n,r){for(let i of this.metadataAssignments){let a=e.get(i.target);if(!a){let e=this.inferMetadataKind(i.metadata);throw Error(`Metadata target '${i.target}' is unresolved${e?` (metadata implies ${e})`:``} at ${$(i.targetLocation)}`)}if(a.kind===`actor`||a.kind===`usecase`)this.applyStandaloneElementMetadata(t.get(i.target),i.metadata);else if(a.kind===`boundary`){let e=n.get(i.target);for(let t of i.metadata.properties)(t.key!==`type`||t.value!==`rect`&&t.value!==`package`)&&this.invalidMetadata(i.target,a.kind,t),e.type=t.value}else if(a.kind===`edge`){let e=r.get(i.target);if(!e)throw Error(`Metadata target '${i.target}' is not an explicit edge at ${$(i.targetLocation)}`);i.statement.kind=`edgeMetadata`,i.statement.edges=[{id:i.target,span:i.statement.span,idSpan:i.targetLocation.span,...i.statement.metadata?{metadata:i.statement.metadata}:{}}],delete i.statement.nodes;for(let t of i.metadata.properties)t.key===`animate`&&typeof t.value==`boolean`?e.relationship.animate=t.value:t.key===`animation`&&(t.value===`fast`||t.value===`slow`)?(e.relationship.animation=t.value,e.relationship.animate=!0):this.invalidMetadata(i.target,a.kind,t)}else for(let e of i.metadata.properties)this.invalidMetadata(i.target,a.kind,e)}for(let{relationship:e}of r.values())e.animation&&(e.animate=!0)}applyStandaloneElementMetadata(e,t){for(let n of t.properties)e.kind===`actor`?this.applyActorProperty(e,n,!0):n.key===`business`&&typeof n.value==`boolean`?e.business=n.value:this.invalidMetadata(e.id,e.kind,n)}applyDeclarationMetadata(e,t){if(t)for(let n of t.properties)e.kind===`actor`?this.applyActorProperty(e,n,!1):n.key===`business`&&typeof n.value==`boolean`?(e.business!==void 0&&e.business!==n.value&&this.conflict(`Use case '${e.id}' has conflicting business metadata`,n.location,e.location),e.business=n.value):this.invalidMetadata(e.id,e.kind,n)}applyActorProperty(e,t,n){t.key===`type`&&(t.value===`normal`||t.value===`hollow`||t.value===`awesome`)?(!n&&e.actorType!==void 0&&e.actorType!==t.value&&this.conflict(`Actor '${e.id}' has conflicting type metadata`,t.location,e.location),e.actorType=t.value):t.key===`icon`&&typeof t.value==`string`?(!n&&e.icon!==void 0&&e.icon!==t.value&&this.conflict(`Actor '${e.id}' has conflicting icon metadata`,t.location,e.location),e.icon=t.value):t.key===`business`&&typeof t.value==`boolean`?(!n&&e.business!==void 0&&e.business!==t.value&&this.conflict(`Actor '${e.id}' has conflicting business metadata`,t.location,e.location),e.business=t.value):this.invalidMetadata(e.id,e.kind,t)}validateAndRefreshElements(e){for(let t of e.values()){let e=t.icon?`icon`:t.actorType??`normal`;if(t.kind===`actor`){if(t.icon&&t.actorType&&t.actorType!==`normal`)throw Error(`Actor '${t.id}' cannot combine icon with type '${t.actorType}' at ${$(t.location)}`);if(t.business&&(e===`icon`||e===`awesome`))throw Error(`Business actor '${t.id}' must use normal or hollow geometry at ${$(t.location)}`)}else if((t.shape??`ellipse`)===`rect`&&t.business)throw Error(`Rectangular use case '${t.id}' cannot be a business use case at ${$(t.location)}`);this.setElementModel(t)}}refreshBoundaries(e,t){for(let t of e.values())t.members.length=0;for(let t of[...this.elements].sort((e,t)=>e.location.span[0]-t.location.span[0])){if(!t.parentId)continue;let n=e.get(t.parentId);if(!n)throw Error(`Parent boundary '${t.parentId}' for '${t.id}' is unresolved at ${$(t.parentLocation??t.location)}`);n.members.includes(t.id)||n.members.push(t.id)}for(let n of t.values())if(n.parentId&&!e.has(n.parentId))throw Error(`Parent boundary '${n.parentId}' for '${n.id}' is unresolved at ${$(n.parentLocation??n.location)}`);for(let t of e.values()){let e=this.model.systemBoundaries.get(t.id);e.type=t.type??`rect`,e.members=[...t.members],e.classes=[...t.classes],e.styles=[...t.styles]}}materializeNotes(e){let t=0;for(let n of this.noteDrafts){let r=e.get(n.target);if(!r)throw Error(`Note target '${n.target}' is unresolved at ${$(n.targetLocation)}`);r.kind!==`actor`&&r.kind!==`usecase`&&this.conflict(`Note target '${n.target}' must be an actor or use case, not ${r.kind}`,n.targetLocation,r.location);let i=`note-${t++}`;this.model.notes.set(i,{id:i,target:n.target,label:n.label.text,labelType:n.label.type})}this.model.noteCounter=t}applyClassDefinitions(){for(let e of this.classDefinitions)for(let t of e.ids)this.model.classDefs.set(t,{id:t,styles:[...e.styles]})}applyClassesAndStyles(e,t){for(let n of this.classAssignments)for(let r of n.targets)sc(this.getStylable(r.id,e,t,r.location).classes,n.classes);for(let n of this.styleAssignments)this.getStylable(n.target,e,t,n.location).styles.push(...n.styles)}getStylable(e,t,n,r){let i=t.get(e)?.kind,a=i===`actor`?this.model.actors.get(e):i===`usecase`?this.model.useCases.get(e):i===`boundary`?this.model.systemBoundaries.get(e):i===`json`?this.model.jsonNodes.get(e):i===`edge`?n.get(e)?.relationship:void 0;if(!a)throw Error(`Class/style target '${e}' is unresolved or anonymous at ${$(r)}`);return a}validateRelationship(e,t,r,i){let a=n(e=>e===`actor`||e===`usecase`||e===`json`,`allowed`);if(a(t)||this.conflict(`Relationship source '${e.source.id}' cannot be ${t}`,e.source.location,i.get(e.source.id).location),a(r)||this.conflict(`Relationship target '${e.target.id}' cannot be ${r}`,e.target.location,i.get(e.target.id).location),(e.type===`include`||e.type===`extend`)&&(t!==`usecase`||r!==`usecase`))throw Error(`${e.type} relationship requires use-case endpoints at ${$(e.location)}`);if(e.type===`generalization`&&(t!==`actor`&&t!==`usecase`||t!==r))throw Error(`Generalization requires actor-to-actor or use-case-to-use-case endpoints at ${$(e.location)}`);if(e.type===`association`&&(t===`json`||r===`json`)&&![0,1,2].includes(e.arrowType))throw Error(`JSON relationship '${e.source.id}' to '${e.target.id}' permits only point, reversed-point, or markerless solid association at ${$(e.location)}`)}setElementModel(e){if(e.kind===`actor`){let t=e.icon?`icon`:e.actorType??`normal`;this.model.useCases.delete(e.id),this.model.actors.set(e.id,{id:e.id,label:e.label.text,labelType:e.label.type,type:t,...e.icon?{icon:e.icon}:{},business:e.business??!1,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{},classes:[...e.classes],styles:this.model.actors.get(e.id)?.styles??[]})}else this.model.actors.delete(e.id),this.model.useCases.set(e.id,{id:e.id,label:e.label.text,labelType:e.label.type,shape:e.shape??`ellipse`,business:e.business??!1,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{},classes:[...e.classes],styles:this.model.useCases.get(e.id)?.styles??[]})}inferMetadataKind(e){let t=new Set([`actor`,`usecase`,`boundary`,`edge`]);for(let n of e.properties)if(n.key===`icon`)t.clear(),t.add(`actor`);else if(n.key===`animate`||n.key===`animation`)t.clear(),t.add(`edge`);else if(n.key===`type`)t.clear(),n.value===`rect`||n.value===`package`?t.add(`boundary`):(n.value===`normal`||n.value===`hollow`||n.value===`awesome`)&&t.add(`actor`);else if(n.key===`business`)t.delete(`boundary`),t.delete(`edge`);else return;return t.size===1?[...t][0]:void 0}invalidMetadata(e,t,n){throw Error(`Metadata property '${n.key}' is invalid for ${t} '${e}' at ${$(n.location)}`)}registerUnique(e,t,n,r,i){let a=e.get(t);a&&this.conflict(`ID '${t}' is declared more than once (${a.kind} and ${n})`,r,a.location,void 0,oc(a)),e.set(t,{kind:n,location:r,generated:i})}recordFirst(e,t,n){let r=e.get(t);(r===void 0||nthis.visit(e)),r=this.nodes(e,`relationTail`)[0],i=n.map((e,n)=>this.actorOccurrence(t[n],e,!0));for(let e of n)this.builder.addElement(this.actorDraft(e));if(!r)return{kind:`node`,span:[0,0],nodes:i};let a=this.visit(r);a.target.explicitDeclaration&&this.builder.addElement(this.entityDraft(a.target));let o=this.relationshipDraft(n[0],a,this.nodeLocation(r));this.builder.addRelationship(o);let s=o.explicitId??`edge-${this.anonymousEdge++}`;return i.push(this.entityOccurrence(this.nodes(r.children,`entityName`)[0],a.target,a.target.explicitDeclaration)),{kind:`edge`,span:[0,0],nodes:i,edges:[{id:s,span:[0,0],...o.explicitIdLocation?{idSpan:o.explicitIdLocation.span}:{},...o.label?{labelSpan:o.label.span}:{}}]}}actorItem(e){let t=this.visit(this.nodes(e,`actorName`)[0]),n=this.nodes(e,`metadata`)[0],r=this.nodes(e,`stereotype`)[0],i=this.nodes(e,`classSuffix`)[0],a=i?this.visit(i):{classes:[],spans:[]};return{...t,...n?{metadata:this.visit(n)}:{},...r?{stereotype:this.visit(r)}:{},classes:a.classes,classSpans:a.spans}}actorName(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0];if(t){let n=this.nodes(e,`nodeLabel`)[0],r=n?this.visit(n):this.tokenLabel(t);return{id:t.image,label:r,location:this.tokenLocation(t),generated:!1,classes:[],classSpans:[]}}let r=this.tokenLabel(n);return{id:this.generateId(r.text),label:r,location:this.tokenLocation(n),generated:!0,classes:[],classSpans:[]}}actorDeclarationOnly(e){let t=this.nodes(e,`actorItem`),n=t.map(e=>this.visit(e));for(let e of n)this.builder.addElement(this.actorDraft(e));return{kind:`node`,span:[0,0],nodes:n.map((e,n)=>this.actorOccurrence(t[n],e,!0))}}entityStatement(e){let t=this.nodes(e,`entityName`),n=this.visit(t[0]),r=this.nodes(e,`relationTail`)[0];if(!r)return n.explicitDeclaration=!0,n.shape??=`ellipse`,this.builder.addElement(this.entityDraft(n)),{kind:`node`,span:[0,0],nodes:[this.entityOccurrence(t[0],n,!0)]};n.explicitDeclaration&&this.builder.addElement(this.entityDraft(n));let i=this.visit(r);i.target.explicitDeclaration&&this.builder.addElement(this.entityDraft(i.target));let a={source:this.endpoint(n),target:this.endpoint(i.target),location:this.nodeLocation(r),...i.explicitId?{explicitId:i.explicitId,explicitIdLocation:i.explicitIdLocation}:{},...i.arrow};this.builder.addRelationship(a);let o=a.explicitId??`edge-${this.anonymousEdge++}`;return{kind:`edge`,span:[0,0],nodes:[this.entityOccurrence(t[0],n,n.explicitDeclaration),this.entityOccurrence(this.nodes(r.children,`entityName`)[0],i.target,i.target.explicitDeclaration)],edges:[{id:o,span:[0,0],...a.explicitIdLocation?{idSpan:a.explicitIdLocation.span}:{},...a.label?{labelSpan:a.label.span}:{}}]}}entityName(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0],r=this.nodes(e,`nodeLabel`)[0],i=this.nodes(e,`useCaseMetadata`)[0],a=this.nodes(e,`stereotype`)[0],o=this.nodes(e,`classSuffix`)[0],s=o?this.visit(o):{classes:[],spans:[]};if(t){let n=r?this.visit(r):this.tokenLabel(t),o=r?this.tokens(e,`LBRACKET`).length?`rect`:`ellipse`:void 0;return{id:t.image,label:n,location:this.tokenLocation(t),generated:!1,...o?{shape:o}:{},...i?{metadata:this.visit(i)}:{},...a?{stereotype:this.visit(a)}:{},classes:s.classes,classSpans:s.spans,explicitDeclaration:!!(o||i||a)}}let c=this.tokenLabel(n);return{id:this.generateId(c.text),label:c,location:this.tokenLocation(n),generated:!0,...i?{metadata:this.visit(i)}:{},...a?{stereotype:this.visit(a)}:{},classes:s.classes,classSpans:s.spans,explicitDeclaration:!!(i||a)}}nodeLabel(e){let t=this.allTokens(e);if(t.length===1&&(t[0].tokenType.name===`PLAIN_STRING`||t[0].tokenType.name===`MARKDOWN_STRING`))return this.tokenLabel(t[0]);let n=[t[0].startOffset,(t.at(-1).endOffset??t.at(-1).startOffset)+1];return{text:this.source.slice(n[0],n[1]),type:`text`,span:n}}useCaseMetadata(e){return this.visit(this.nodes(e,`metadata`)[0])}relationTail(e){let t=this.tokens(e,`IDENTIFIER`)[0];return{...t?{explicitId:t.image,explicitIdLocation:this.tokenLocation(t)}:{},arrow:this.visit(this.nodes(e,`arrow`)[0]),target:this.visit(this.nodes(e,`entityName`)[0])}}arrow(e){return this.visit(this.firstNode(e,`semanticRelation`,`forwardSolidOperator`,`backwardSolidOperator`,`markerlessSolidOperator`,`forwardCircleOperator`,`backwardCircleOperator`,`forwardCrossOperator`,`backwardCrossOperator`))}edgeLabel(e){return this.nodeLabel(e)}semanticRelation(e){if(this.tokens(e,`GENERALIZATION`).length)return{type:`generalization`,arrowType:K.SOLID_ARROW,minlen:1};let t=this.tokens(e,`INCLUDE`).length?`include`:`extend`,n=this.tokens(e,t===`include`?`INCLUDE`:`EXTEND`)[0];return{type:t,arrowType:K.SOLID_ARROW,label:{text:t,type:`text`,span:this.tokenSpan(n)},minlen:1}}metadata(e){return{properties:this.nodes(e,`metadataProperty`).map(e=>this.visit(e)),location:this.ctxLocation(e)}}metadataProperty(e){let t=this.allTokens(e).filter(e=>e.tokenType.name!==`COLON`),n=t[0],r=t[1],i=r.tokenType.name===`TRUE`||r.tokenType.name!==`FALSE`&&this.decodePlain(r),a=[n.startOffset,(r.endOffset??r.startOffset)+1];return{key:this.decodePlain(n),value:i,span:a,keySpan:this.contentSpan(n),valueSpan:this.contentSpan(r),location:this.tokenLocation(n)}}metadataSeparator(e){}systemBoundaryStatement(e){let t=this.visit(this.nodes(e,`systemBoundaryName`)[0]),n=this.nodes(e,`classSuffix`)[0],r=n?this.visit(n):{classes:[],spans:[]};t.classes=r.classes,this.builder.addBoundary(t);let i=this.parentBoundary;this.parentBoundary={id:t.id,location:t.location};let a=this.nodes(e,`systemBoundaryContent`)[0],o=a?this.visit(a):[];this.parentBoundary=i;let s=this.tokens(e,`END`)[0],c=this.nodes(e,`metadata`)[0],l=c?this.visit(c):void 0,u={kind:`group`,span:[0,0],group:t.id,idSpan:t.location.span,titleSpan:t.label.span,endSpan:this.tokenSpan(s),classSpans:r.spans,...l?{metadata:l.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))}:{},...o.length?{children:o}:{}};return l&&this.builder.addMetadataAssignment(t.id,t.location,l,u),u}systemBoundaryName(e){let t=this.tokens(e,`IDENTIFIER`)[0];if(t){let n=this.nodes(e,`nodeLabel`)[0];return{id:t.image,label:n?this.visit(n):this.tokenLabel(t),location:this.tokenLocation(t),generated:!1,classes:[]}}let n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0],r=this.tokenLabel(n);return{id:this.generateId(r.text),label:r,location:this.tokenLocation(n),generated:!0,classes:[]}}systemBoundaryContent(e){return[...this.nodes(e,`blankLine`),...this.nodes(e,`commentLine`),...this.nodes(e,`boundaryElement`)].sort((e,t)=>(e.location?.startOffset??0)-(t.location?.startOffset??0)).map(e=>this.wrap(e,this.visit(e)))}boundaryElement(e){let t=this.nodes(e,`actorDeclarationOnly`)[0];if(t)return this.visit(t);let n=this.nodes(e,`entityName`)[0],r=this.visit(n);return r.explicitDeclaration=!0,r.shape??=`ellipse`,this.builder.addElement(this.entityDraft(r)),{kind:`node`,span:[0,0],nodes:[this.entityOccurrence(n,r,!0)]}}metadataAssignmentStatement(e){let t=this.visit(this.nodes(e,`metadataAssignmentTarget`)[0]),n=this.visit(this.nodes(e,`metadata`)[0]),r={kind:`metadata`,span:[0,0],nodes:[{id:t.id,span:t.location.span,idSpan:t.location.span}],metadata:n.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))};return this.builder.addMetadataAssignment(t.id,t.location,n,r),r}metadataAssignmentTarget(e){let t=this.allTokens(e)[0],n=this.tokenLabel(t);return{id:t.tokenType.name===`IDENTIFIER`?t.image:this.generateId(n.text),location:this.tokenLocation(t)}}noteStatement(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.visit(this.nodes(e,`nodeLabel`)[0]);return this.builder.addNote({target:t.image,targetLocation:this.tokenLocation(t),label:n,location:this.ctxLocation(e)}),{kind:`note`,span:[0,0],ref:`note-${this.anonymousNote++}`,refSpan:n.span,nodes:[{id:t.image,span:this.tokenSpan(t),idSpan:this.tokenSpan(t)}]}}stereotype(e){let t=this.tokens(e,`STEREOTYPE_TEXT`)[0];return{value:t.image.trim(),span:this.tokenSpan(t)}}classSuffix(e){let t=this.tokens(e,`IDENTIFIER`);return{classes:t.map(e=>e.image),spans:t.map(e=>this.tokenSpan(e))}}jsonStatement(e){let t=this.tokens(e,`JSON_DECLARATION_START`)[0],n=this.tokens(e,`JSON_OBJECT_LITERAL`)[0],r=/^json[\t ]+(\w+)/.exec(t.image),i=r[1],a=r[0].length-i.length,o={span:[t.startOffset+a,t.startOffset+a+i.length],line:t.startLine??1,column:(t.startColumn??1)+a},s=Zs(n.image,n.startLine??1,n.startColumn??1),c=this.nodes(e,`classSuffix`)[0],l=c?this.visit(c):{classes:[],spans:[]},u={id:i,value:s.value,propertyOrder:s.propertyOrder,location:o,classes:l.classes};return this.builder.addJson(u),{kind:`json`,span:[0,0],nodes:[{id:i,span:o.span,idSpan:o.span,defines:!0,classSpans:l.spans}],classSpans:l.spans}}directionStatement(e){let t=this.allTokens(e).find(e=>[`TD`,`TB`,`BT`,`RL`,`LR`].includes(e.tokenType.name));return this.builder.setDirection(t.image),{kind:`direction`,span:[0,0]}}classDefStatement(e){let t=this.tokens(e,`IDENTIFIER`),n=this.visit(this.nodes(e,`styles`)[0]);return this.builder.addClassDef(t.map(e=>e.image),n),{kind:`classDef`,span:[0,0],ref:t[0].image,refSpan:this.tokenSpan(t[0])}}classStatement(e){let t=this.tokens(e,`IDENTIFIER`),n=1;for(;n({id:e.image,location:this.tokenLocation(e)})),i=t.slice(n).map(e=>e.image);return this.builder.addClassAssignment(r,i),{kind:`classAssign`,span:[0,0],ref:i[0],refSpan:this.tokenSpan(t[n]),nodes:r.map(({id:e,location:t})=>({id:e,span:t.span,idSpan:t.span}))}}styleStatement(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.visit(this.nodes(e,`styles`)[0]);return this.builder.addStyleAssignment(t.image,this.tokenLocation(t),n),{kind:`style`,span:[0,0],nodes:[{id:t.image,span:this.tokenSpan(t),idSpan:this.tokenSpan(t)}]}}styles(e){return this.nodes(e,`styleValue`).map(e=>this.visit(e))}styleValue(e){let t=this.allTokens(e),n=[t[0].startOffset,(t.at(-1).endOffset??t.at(-1).startOffset)+1];return this.source.slice(n[0],n[1]).replaceAll(`\\,`,`,`)}styleComponent(e){return this.allTokens(e).map(e=>e.image).join(``)}forwardSolidOperator(e){let t=this.tokens(e,`FORWARD_SOLID`)[0];return{type:`association`,arrowType:K.SOLID_ARROW,minlen:this.solidMinlen(t)}}backwardSolidOperator(e){let t=this.tokens(e,`BACKWARD_SOLID`)[0],n=this.nodes(e,`edgeLabel`)[0],r=n?this.tokens(e,`MARKERLESS_SOLID`).at(-1):t;return{type:`association`,arrowType:K.BACK_ARROW,minlen:this.solidMinlen(r),...n?{label:this.visit(n)}:{}}}markerlessSolidOperator(e){let t=this.nodes(e,`edgeLabel`)[0],n=this.allTokens(e);if(!t)return{type:`association`,arrowType:K.LINE_SOLID,minlen:this.solidMinlen(this.tokens(e,`MARKERLESS_SOLID`)[0])};let r=n.at(-1),i=r.tokenType.name===`FORWARD_SOLID`?K.SOLID_ARROW:r.tokenType.name===`FORWARD_CIRCLE`?K.CIRCLE_ARROW:r.tokenType.name===`FORWARD_CROSS`?K.CROSS_ARROW:K.LINE_SOLID;return{type:`association`,arrowType:i,label:this.visit(t),minlen:i===K.SOLID_ARROW||i===K.LINE_SOLID?this.solidMinlen(r):1}}forwardCircleOperator(e){return{type:`association`,arrowType:K.CIRCLE_ARROW,minlen:1}}backwardCircleOperator(e){let t=this.nodes(e,`edgeLabel`)[0];return{type:`association`,arrowType:K.CIRCLE_ARROW_REVERSED,minlen:1,...t?{label:this.visit(t)}:{}}}forwardCrossOperator(e){return{type:`association`,arrowType:K.CROSS_ARROW,minlen:1}}backwardCrossOperator(e){let t=this.nodes(e,`edgeLabel`)[0];return{type:`association`,arrowType:K.CROSS_ARROW_REVERSED,minlen:1,...t?{label:this.visit(t)}:{}}}actorDraft(e){return{id:e.id,kind:`actor`,label:e.label,location:e.location,generated:e.generated,...this.parentBoundary?{parentId:this.parentBoundary.id,parentLocation:this.parentBoundary.location}:{},...e.metadata?{metadata:e.metadata}:{},...e.stereotype?{stereotype:e.stereotype.value,stereotypeSpan:e.stereotype.span}:{},classes:e.classes}}entityDraft(e){return{id:e.id,kind:`usecase`,label:e.label,location:e.location,generated:e.generated,...this.parentBoundary?{parentId:this.parentBoundary.id,parentLocation:this.parentBoundary.location}:{},...e.shape?{shape:e.shape}:{},...e.metadata?{metadata:e.metadata}:{},...e.stereotype?{stereotype:e.stereotype.value,stereotypeSpan:e.stereotype.span}:{},classes:e.classes}}endpoint(e,t=e.explicitDeclaration??!0){return{id:e.id,label:e.label,location:e.location,generated:e.generated,declaration:t,classesOnReference:e.classes.length>0}}relationshipDraft(e,t,n){return{source:this.endpoint(e,!0),target:this.endpoint(t.target),location:n,...t.explicitId?{explicitId:t.explicitId,explicitIdLocation:t.explicitIdLocation}:{},...t.arrow}}actorOccurrence(e,t,n){return{id:t.id,span:this.nodeSpan(e),idSpan:t.location.span,labelSpan:t.label.span,...n?{defines:!0}:{},...t.stereotype?{stereotypeSpan:t.stereotype.span}:{},...t.metadata?{metadata:t.metadata.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))}:{},...t.classSpans.length?{classSpans:t.classSpans}:{}}}entityOccurrence(e,t,n){return this.actorOccurrence(e,t,n)}wrap(e,t){if(t.kind===`blank`||t.kind===`comment`)return t;t.span=this.nodeSpan(e);for(let e of t.edges??[])e.span=t.span;return t}tokenLabel(e){let t=e.tokenType.name===`MARKDOWN_STRING`?`markdown`:`text`,n=t===`markdown`?2:+(e.tokenType.name===`PLAIN_STRING`),r=this.tokenSpan(e,n);return{text:this.source.slice(r[0],r[1]),type:t,span:r}}decodePlain(e){return e.tokenType.name===`PLAIN_STRING`?e.image.slice(1,-1):e.image}contentSpan(e){return this.tokenSpan(e,e.tokenType.name===`PLAIN_STRING`?1:e.tokenType.name===`MARKDOWN_STRING`?2:0)}generateId(e){return e.replace(/\W/g,`_`)}solidMinlen(e){return Math.max(1,(e.image.match(/-/g)?.length??2)-1)}nodeLocation(e){let t=this.allTokens(e.children)[0];return{span:this.nodeSpan(e),line:t.startLine??1,column:t.startColumn??1}}ctxLocation(e){let t=this.allTokens(e).filter(e=>e.tokenType.name!==`NEWLINE`&&e.tokenType.name!==`EOF`),n=t[0],r=t.at(-1);return{span:[n.startOffset,Math.min(this.source.length,(r.endOffset??r.startOffset+r.image.length-1)+1)],line:n.startLine??1,column:n.startColumn??1}}tokenLocation(e){let t=e.tokenType.name===`PLAIN_STRING`?1:e.tokenType.name===`MARKDOWN_STRING`?2:0;return{span:this.tokenSpan(e,t),line:e.startLine??1,column:(e.startColumn??1)+t}}nodeSpan(e){let t=this.allTokens(e.children).filter(e=>e.tokenType.name!==`NEWLINE`&&e.tokenType.name!==`EOF`),n=t[0],r=t.at(-1);if(!n||!r)throw Error(`Usecase CST node has no source token`);return[n.startOffset,Math.min(this.source.length,(r.endOffset??r.startOffset+r.image.length-1)+1)]}tokenSpan(e,t=0){return[e.startOffset+t,Math.min(this.source.length,(e.endOffset??e.startOffset+e.image.length-1)+1-t)]}nodes(e,t){return(e[t]??[]).filter(e=>`children`in e)}tokens(e,t){return(e[t]??[]).filter(e=>`tokenTypeIdx`in e)}firstNode(e,...t){for(let n of t){let t=this.nodes(e,n)[0];if(t)return t}throw Error(`Usecase CST is missing one of: ${t.join(`, `)}`)}allTokens(e){let t=[];for(let n of Object.values(e))for(let e of n)`tokenTypeIdx`in e?t.push(e):t.push(...this.allTokens(e.children));return t.sort((e,t)=>e.startOffset-t.startOffset)}},dc={parse:n(async e=>{yo.clear(),Ks.input=[];try{za({diagramType:`usecase`,lexer:Us,parser:Ks,entry:n(()=>Ks.start(),`entry`),visit:n(t=>uc.build(t,e),`visit`)},e)}catch(t){yo.clear();let n=Ks.errors[0];if(n){let{token:r}=n,i=Number.isFinite(r.startOffset)?r.startOffset:e.length,a=typeof r.endOffset==`number`&&Number.isFinite(r.endOffset)?r.endOffset+1:i,o=r.startLine??e.slice(0,i).split(/\r\n|\r|\n/).length,s=Math.max(e.lastIndexOf(` +`,i-1),e.lastIndexOf(`\r`,i-1)),c=r.startColumn??i-s,l=t instanceof Error?t.message:String(t);throw Error(`${l} at line ${o}, column ${c} [${i},${a})`)}throw t}},`parse`)},fc=[`point`,`circle`,`cross`,`extension`],pc={usecaseActor:!0,usecaseActorHollow:!0,usecaseActorAwesome:!0,usecaseActorIcon:!0},mc=n((e,t)=>{let[n,r]=[e,t].map(e=>e.replace(/[^\w-]+/g,`_`).replace(/^_+|_+$/g,``)||`element`);return`usecase-${n}-${r}`},`usecaseDomId`),hc=n(e=>`usecase-${e.replace(/[^\w-]+/g,`_`).replace(/^_+|_+$/g,``)||`element`}`,`usecaseNodeDomId`),gc=n((e,t)=>t===`markdown`?h(e).map(e=>e.map(e=>e.content).join(` `)).join(` +`):e,`getAccessibleLabel`),_c=n(e=>{let t=gc(e.label??e.id,e.labelType);if(pc[e.shape]){let n=e.actorType&&e.actorType!==`normal`?`${e.actorType} `:``;return`${e.business?`business `:``}${n}actor ${t}${e.stereotype?`, stereotype ${e.stereotype}`:``}`}if(e.shape===`note`)return`Note for ${e.noteTargetLabel??e.noteTarget??``}: ${t}`;if(e.shape===`usecaseJsonTable`){let n=(e.jsonRows??[]).map(e=>`${e.accessibleKey}: ${e.value}`).join(`; `);return n?`${t}: ${n}`:t}let n=e.stereotype?`, stereotype ${e.stereotype}`:``;return`${e.business?`business `:``}use case ${t}${n}`},`getUsecaseNodeAccessibleName`),vc=n(e=>`${e.boundaryType} system boundary ${gc(e.label??e.id,e.labelType)}`,`getUsecaseBoundaryAccessibleName`),yc=n(e=>e.relationshipType===`note`?``:`${e.relationshipType===`association`&&e.label?`association ${gc(e.label,e.labelType)}`:e.relationshipType} from ${e.sourceLabel} to ${e.targetLabel}`,`getUsecaseEdgeAccessibleName`),bc=n(e=>e.replace(/&/g,`&`).replace(//g,`>`),`escapePlainLabel`),xc=n(e=>e.replace(/([*[\\\]_`])/g,`\\$1`),`escapeMarkdownMarkers`),Sc=n((e,t)=>{e.diagramId=t,e.markers=[...fc];for(let t of e.nodes){let e=t;if(e.domId=hc(t.id),t.label!==void 0&&t.labelType===`text`&&(t.label=bc(t.label)),t.stereotype&&=bc(t.stereotype),!t.isGroup&&t.shape===`usecaseJsonTable`&&(t.jsonRows=t.jsonRows?.map(e=>({...e,key:bc(e.key),value:bc(e.value)}))),!t.isGroup&&(t.shape===`usecaseEllipse`||t.shape===`rect`)&&t.stereotype){let n=t.label??bc(t.id);t.label=`\xAB${xc(t.stereotype)}\xBB
    ${t.labelType===`text`?xc(n):n}`,t.labelType=`markdown`,e.hasFoldedStereotype=!0,delete t.stereotype}}for(let t of e.edges)t.label!==void 0&&t.labelType===`text`&&(t.label=bc(t.label));return e},`prepareUsecaseLayoutData`),Cc=n((e,n,r)=>{for(let t of n.nodes){let i=typeof t.domId==`string`?t.domId:mc(n.diagramId,t.id),a=e.select(`#${i}`),o=t.isGroup?`boundary`:pc[t.shape]?`actor`:t.shape===`note`?`note`:t.shape===`usecaseJsonTable`?`json`:`usecase`,s=r.nodes.get(t.id)??t.id;if(a.attr(`data-usecase-id`,t.id).attr(`data-usecase-kind`,o).attr(`role`,`img`).attr(`aria-label`,s),!t.isGroup&&(t.shape===`usecaseEllipse`||t.shape===`rect`)&&`hasFoldedStereotype`in t&&t.hasFoldedStereotype===!0){let e=a.node(),t=e?.querySelector(`.nodeLabel`),n=t?.querySelector(`p`)??t,r=n?.firstChild;if(n&&r?.nodeType===3){let e=n.ownerDocument.createElement(`span`);e.className=`usecase-stereotype`,n.insertBefore(e,r),e.appendChild(r)}else e?.querySelector(`.label tspan tspan, .label tspan`)?.classList.add(`usecase-stereotype`)}}let i=new Map(n.edges.map(e=>[e.id,e]));e.selectAll(`path[data-et="edge"]`).each(function(){let e=i.get(this.getAttribute(`data-id`)??``);if(!e)return;let a=t(this);a.attr(`id`,mc(n.diagramId,e.id)).attr(`data-usecase-id`,e.id).attr(`data-usecase-kind`,e.internal?`note-connector`:`relationship`),e.internal?a.attr(`aria-hidden`,`true`):a.attr(`role`,`img`).attr(`aria-label`,r.edges.get(e.id)??e.id)})},`annotateUsecaseElements`),wc=n((e,t)=>{e.style(`--mermaid-usecase-actor-font-size`,`${t.actorFontSize}px`).style(`--mermaid-usecase-actor-font-family`,t.actorFontFamily).style(`--mermaid-usecase-actor-font-weight`,t.actorFontWeight).style(`--mermaid-usecase-font-size`,`${t.usecaseFontSize}px`).style(`--mermaid-usecase-font-family`,t.usecaseFontFamily).style(`--mermaid-usecase-font-weight`,t.usecaseFontWeight)},`applyUsecaseFonts`),Tc={draw:n(async(t,n,r,i)=>{e.info(`Drawing usecase diagram (unified)`,n);let{layout:a}=d(),o=i.db,s=o.getData(),c=new Map(s.nodes.map(e=>[e.id,gc(e.label??e.id,e.labelType)])),l={nodes:new Map(s.nodes.map(e=>[e.id,e.isGroup?vc(e):_c(e.shape===`note`?{...e,noteTargetLabel:c.get(e.noteTarget??``)}:e)])),edges:new Map(s.edges.map(e=>[e.id,yc({...e,sourceLabel:c.get(e.source)??e.sourceLabel,targetLabel:c.get(e.target)??e.targetLabel})]))},u=Ve(n,s.config.securityLevel);s.layoutAlgorithm=re(a),Sc(s,n),wc(u,s),await ne(s,u),Cc(u,s,l);let f=s.diagramPadding;m.insertTitle(u,`usecaseDiagramTitleText`,0,o.getDiagramTitle?.()??``),He(u,f,`usecaseDiagram`,s.useMaxWidth),wc(u,s)},`draw`)},Ec=n(e=>({actorBkg:e.usecaseActorBkg??e.actorBkg??e.mainBkg,actorBorder:e.usecaseActorBorder??e.actorBorder??e.primaryColor,bkg:e.usecaseBkg??e.mainBkg,border:e.usecaseBorder??e.nodeBorder??e.primaryColor,boundaryBkg:e.usecaseBoundaryBkg??e.clusterBkg,boundaryBorder:e.usecaseBoundaryBorder??e.clusterBorder,includeLine:e.usecaseIncludeLine??e.lineColor,extendLine:e.usecaseExtendLine??e.lineColor}),`roleColors`),Dc=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!ee(t,r))return``;let i=o().usecase?.colorScheme===`rotate`,a=te(e.look),s=a===`handDrawn`,c=_(n),l=``;for(let e=0;e{let t=Ec(e),n=te(e.look)===`handDrawn`;return` + ${Dc(e)} + & .usecase-actor { + color: ${e.actorTextColor??e.primaryTextColor}; + } + + & .usecase-actor-shape, + & .usecase-actor-hollow, + & .usecase-actor-awesome, + & .usecase-actor-icon { + fill: ${t.actorBkg}; + stroke: ${t.actorBorder}; + stroke-width: 2px; + } +${n?``:` + /* The rule above colours the glyph group and lets its children inherit, which the neo + look breaks: it ships a \`[data-look="neo"].node path { stroke }\` rule that lands on + the glyph's own paths, and a value set directly on a child always beats one inherited + from its parent, whatever the parent rule's specificity. Since neo is the default look, + without this every actor renders in the node border colour rather than the actor + colour the rule above asks for. + + \`.node\` is in the selector to outrank that neo rule rather than tie with it: both + would otherwise be one attribute plus one class plus one element, leaving the winner to + depend on which stylesheet is concatenated last. + + Stroke only: the hollow variant's own \`fill="none"\` has to keep winning. */ + & .node.usecase-actor .usecase-actor-glyph path, + & .node.usecase-actor .usecase-actor-glyph circle { + stroke: ${t.actorBorder}; + } +`} + & .usecase-actor .nodeLabel, + & .actor-label { + color: ${e.actorTextColor??e.primaryTextColor}; + fill: ${e.actorTextColor??e.primaryTextColor}; + font-family: var(--mermaid-usecase-actor-font-family, ${e.fontFamily}); + font-size: var(--mermaid-usecase-actor-font-size, 14px); + font-weight: var(--mermaid-usecase-actor-font-weight, normal); + } + + & .usecase-element ellipse, + & .usecase-element rect, + & .usecase-business ellipse, + & .usecase-business rect { + fill: ${t.bkg}; + stroke: ${t.border}; + stroke-width: 2px; + } +${n?``:` + /* The same interception the actor glyph hits, one element down: neo ships + \`[data-look="neo"].node rect { stroke: nodeBorder }\`, which outranks the plain + \`.usecase-element rect\` above, so a use case written in the \`[Rect]\` form kept the node + border colour while its ellipse siblings took the role colour. An \`\` has no + equivalent neo rule and is already correct; restating it here costs nothing and means + the two forms cannot drift apart again. + + Qualified with \`[data-look]\` *and* \`.node\` to land strictly above that rule rather than + tie with it -- on a tie the later stylesheet would win, which is how neo took this in + the first place. Skipped under handDrawn, where roughjs draws paths and neither element + exists. */ + & [data-look="${te(e.look)}"].node.usecase-element ellipse, + & [data-look="${te(e.look)}"].node.usecase-element rect { + fill: ${t.bkg}; + stroke: ${t.border}; + } + + /* The business marker is a \`\`, so it loses to \`[data-look="neo"].node path\` the same + way. No \`fill\`: the marker is drawn with \`fill="none"\` and has to stay that way. */ + & [data-look="${te(e.look)}"].node.usecase-element .usecase-business-marker { + stroke: ${t.border}; + } +`} + & .usecase-element .nodeLabel, + & .usecase-label { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + font-family: var(--mermaid-usecase-font-family, ${e.fontFamily}); + font-size: var(--mermaid-usecase-font-size, 12px); + font-weight: var(--mermaid-usecase-font-weight, normal); + } + + & .usecase-stereotype, + & .usecase-business-marker { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + stroke: ${t.border}; + } + + & .system-boundary rect.boundary-body, + & .system-boundary rect.boundary-tab, + & .system-boundary-package-tab { + fill: ${t.boundaryBkg}; + stroke: ${t.boundaryBorder}; + stroke-width: 1px; + } + + & .system-boundary-title text { + fill: ${e.titleColor??e.primaryTextColor}; + } + + /* Only the span, never the

    inside it: the renderer puts a user-supplied + 'color' on the span, and that has to stay inheritable by its children. */ + & .system-boundary-title span { + color: ${e.titleColor??e.primaryTextColor}; + } + + & .usecase-note { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + color: ${e.noteTextColor}; + } + + & .usecase-note .nodeLabel { + color: ${e.noteTextColor}; + fill: ${e.noteTextColor}; + } + + & .usecase-json-table, + & .usecase-json-table rect, + & .usecase-json-cell { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder??e.primaryColor}; + } + + & .usecase-json-title, + & .usecase-json-key, + & .usecase-json-value { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + } + + & .relationship { + fill: none; + stroke: ${e.lineColor}; + } + + & .relationship-include, + & .relationship-extend, + & .relationship-note { + stroke-dasharray: 3; + } + + /* Include and extend are both dashed, which is a weak distinction at small sizes. The + tokens default to \`lineColor\`, so a theme that does not set them is unchanged. */ + & .relationship-include { + stroke: ${t.includeLine}; + } + + & .relationship-extend { + stroke: ${t.extendLine}; + } + + & .relationship.edge-animation-fast, + & .relationship.edge-animation-slow { + stroke-linecap: round; + } + + & .edgeLabel, + & .edgeLabel p { + background-color: ${e.edgeLabelBackground}; + } + + & .labelBkg { + background-color: ${e.edgeLabelBackground}; + padding: 0 2px; + } + + & .edgeLabel .label rect { + fill: ${e.edgeLabelBackground}; + } + + & .relationship-label, + & .edgeLabel { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + font-family: ${e.fontFamily}; + font-size: 10px; + font-weight: normal; + } + + & .marker, + & .marker.point, + & .marker.circle, + & .marker.cross { + fill: ${e.lineColor}; + stroke: ${e.lineColor}; + } + + & .marker.extension { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + } +`},`getStyles`)};export{Oc as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js b/frontend/dist/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js new file mode 100644 index 0000000..90453fc --- /dev/null +++ b/frontend/dist/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js @@ -0,0 +1,34 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,at as a,b as o,c as s,f as c,it as l,nt as u,q as d,rt as f,v as p,w as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as _}from"./rough.esm-Dy-Kn_BL.js";import{y as v}from"./index-DoQkmpth.js";var y=(e,t)=>l(e,`a`,-t),b=1e-10;function x(e,t){let n=C(e),r=n.filter(t=>S(t,e)),i=0,a=0,o=[];if(r.length>1){let t=O(r);for(let e=0;et.angle-e.angle);let n=r[r.length-1];for(let t=0;tr.radius*2&&(d=r.radius*2),(l==null||l.width>d)&&(l={circle:r,width:d,p1:s,p2:n,large:d>r.radius,sweep:!0})}l!=null&&(o.push(l),i+=w(l.circle.radius,l.width),n=s)}}else{let t=e[0];for(let n=1;nMath.abs(t.radius-e[r].radius)){n=!0;break}n?i=a=0:(i=t.radius*t.radius*Math.PI,o.push({circle:t,p1:{x:t.x,y:t.y+t.radius},p2:{x:t.x-b,y:t.y+t.radius},width:t.radius*2,large:!0,sweep:!0}))}return a/=2,t&&(t.area=i+a,t.arcArea=i,t.polygonArea=a,t.arcs=o,t.innerPoints=r,t.intersectionPoints=n),i+a}function S(e,t){return t.every(t=>T(e,t)=e+t)return 0;if(n<=Math.abs(e-t))return Math.PI*Math.min(e,t)*Math.min(e,t);let r=e-(n*n-t*t+e*e)/(2*n),i=t-(n*n-e*e+t*t)/(2*n);return w(e,r)+w(t,i)}function D(e,t){let n=T(e,t),r=e.radius,i=t.radius;if(n>=r+i||n<=Math.abs(r-i))return[];let a=(r*r-i*i+n*n)/(2*n),o=Math.sqrt(r*r-a*a),s=e.x+a*(t.x-e.x)/n,c=e.y+a*(t.y-e.y)/n,l=-(t.y-e.y)*(o/n),u=-(t.x-e.x)*(o/n);return[{x:s+l,y:c-u},{x:s-l,y:c+u}]}function O(e){let t={x:0,y:0};for(let n of e)t.x+=n.x,t.y+=n.y;return t.x/=e.length,t.y/=e.length,t}function k(e,t,n,r){r||={};let i=r.maxIterations||100,a=r.tolerance||1e-10,o=e(t),s=e(n),c=n-t;if(o*s>0)throw`Initial bisect points must have opposite signs`;if(o===0)return t;if(s===0)return n;for(let n=0;n=0&&(t=n),Math.abs(c)A(t))}function M(e,t){let n=0;for(let r=0;re.fx-t.fx,_=t.slice(),v=t.slice(),y=t.slice(),b=t.slice();for(let t=0;t{let t=e.slice();return t.fx=e.fx,t.id=e.id,t});e.sort((e,t)=>e.id-t.id),n.history.push({x:m[0].slice(),fx:m[0].fx,simplex:e})}f=0;for(let e=0;e=m[p-1].fx){let n=!1;if(v.fx>t.fx?(F(y,1+u,_,-u,t),y.fx=e(y),y.fx=1)break;for(let t=1;ts+a*i*c||l>=p)f=i;else{if(Math.abs(d)<=-o*c)return i;d*(f-u)>=0&&(f=u),u=i,p=l}return 0}for(let m=0;m<10;++m){if(F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||m&&l>=u)return p(f,i,u);if(Math.abs(d)<=-o*c)return i;if(d>=0)return p(i,f,l);u=l,f=i,i*=2}return i}function R(e,t,n){let r={x:t.slice(),fx:0,fxprime:t.slice()},i={x:t.slice(),fx:0,fxprime:t.slice()},a=t.slice(),o,s,c=1,l;n||={},l=n.maxIterations||t.length*20,r.fx=e(r.x,r.fxprime),o=r.fxprime.slice(),P(o,r.fxprime,-1);for(let t=0;t{let t={};for(let n=0;nE(e,t,r)-n,0,e+t)}function ne(e,t={}){let n=t.distinct,r=e.map(e=>Object.assign({},e));function i(e){return e.join(`;`)}if(n){let e=new Map;for(let t of r)for(let n=0;ne===t?0:ee.sets.length===2).forEach(e=>{let a=n[e.sets[0]],o=n[e.sets[1]],s=z(Math.sqrt(t[a].size/Math.PI),Math.sqrt(t[o].size/Math.PI),e.size);r[a][o]=r[o][a]=s;let c=0;e.size+1e-10>=Math.min(t[a].size,t[o].size)?c=1:e.size<=1e-10&&(c=-1),i[a][o]=i[o][a]=c}),{distances:r,constraints:i}}function ie(e,t,n,r){for(let e=0;e0&&m<=d||f<0&&m>=d||(i+=2*h*h,t[2*a]+=4*h*(o-l),t[2*a+1]+=4*h*(s-u),t[2*c]+=4*h*(l-o),t[2*c+1]+=4*h*(u-s))}}return i}function ae(e,t={}){let n=se(e,t),r=t.lossFunction||B;if(e.length>=8){let i=oe(e,t),a=r(i,e),o=r(n,e);a+1e-8e.map(e=>e/s));let c=(e,t)=>ie(e,t,a,o),l=null;for(let e=0;ee.sets.length===2);for(let t of e){let e=t.weight==null?1:t.weight,n=t.sets[0],a=t.sets[1];t.size+te>=Math.min(r[n].size,r[a].size)&&(e=0),i[n].push({set:a,size:t.size,weight:e}),i[a].push({set:n,size:t.size,weight:e})}let a=[];Object.keys(i).forEach(e=>{let t=0;for(let n=0;ne[t]));let i=r.weight==null?1:r.weight;n+=i*(t-r.size)*(t-r.size)}return n}function ce(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight,a=Math.log((t+1)/(r.size+1));n+=i*a*a}return n}function le(e,t,n){if(n==null?e.sort((e,t)=>t.radius-e.radius):e.sort(n),e.length>0){let t=e[0].x,n=e[0].y;for(let r of e)r.x-=t,r.y-=n}if(e.length===2&&T(e[0],e[1])1){let n=Math.atan2(e[1].x,e[1].y)-t,r=Math.cos(n),i=Math.sin(n);for(let t of e){let e=t.x,n=t.y;t.x=r*e-i*n,t.y=i*e+r*n}}if(e.length>2){let n=Math.atan2(e[2].x,e[2].y)-t;for(;n<0;)n+=2*Math.PI;for(;n>2*Math.PI;)n-=2*Math.PI;if(n>Math.PI){let t=e[1].y/(1e-10+e[1].x);for(let n of e){var r=(n.x+t*n.y)/(1+t*t);n.x=2*r-n.x,n.y=2*r*t-n.y}}}}function ue(e){e.forEach(e=>{e.parent=e});function t(e){return e.parent!==e&&(e.parent=t(e.parent)),e.parent}function n(e,n){let r=t(e);r.parent=t(n)}for(let t=0;t{delete e.parent}),Array.from(r.values())}function V(e){let t=t=>({max:e.reduce((e,n)=>Math.max(e,n[t]+n.radius),-1/0),min:e.reduce((e,n)=>Math.min(e,n[t]-n.radius),1/0)});return{xRange:t(`x`),yRange:t(`y`)}}function de(e,t,n){t??=Math.PI/2;let r=me(e).map(e=>Object.assign({},e)),i=ue(r);for(let e of i){le(e,t,n);let r=V(e);e.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),e.bounds=r}i.sort((e,t)=>t.size-e.size),r=i[0];let a=r.bounds,o=(a.xRange.max-a.xRange.min)/50;function s(e,t,n){if(!e)return;let i=e.bounds,s,c;if(t)s=a.xRange.max-i.xRange.min+o;else{s=a.xRange.max-i.xRange.max;let e=(i.xRange.max-i.xRange.min)/2-(a.xRange.max-a.xRange.min)/2;e<0&&(s+=e)}if(n)c=a.yRange.max-i.yRange.min+o;else{c=a.yRange.max-i.yRange.max;let e=(i.yRange.max-i.yRange.min)/2-(a.yRange.max-a.yRange.min)/2;e<0&&(c+=e)}for(let t of e)t.x+=s,t.y+=c,r.push(t)}let c=1;for(;c({radius:u*e.radius,x:r+d+(e.x-o.min)*u,y:r+f+(e.y-s.min)*u,setid:e.setid})))}function pe(e){let t={};for(let n of e)t[n.setid]=n;return t}function me(e){return Object.keys(e).map(t=>Object.assign(e[t],{setid:t}))}function he(e={}){let t=!1,n=600,r=350,i=15,a=1e3,o=Math.PI/2,s=!0,c=null,l=!0,u=!0,d=null,f=null,p=!1,m=null,h=e&&e.symmetricalTextCentre?e.symmetricalTextCentre:!1,g={},_=e&&e.colourScheme?e.colourScheme:e&&e.colorScheme?e.colorScheme:[`#1f77b4`,`#ff7f0e`,`#2ca02c`,`#d62728`,`#9467bd`,`#8c564b`,`#e377c2`,`#7f7f7f`,`#bcbd22`,`#17becf`],v=0,y=function(e){if(e in g)return g[e];var t=g[e]=_[v];return v+=1,v>=_.length&&(v=0),t},b=ee,x=B;function S(g){let _=g.datum(),v=new Set;_.forEach(e=>{e.size==0&&e.sets.length==1&&v.add(e.sets[0])}),_=_.filter(e=>!e.sets.some(e=>v.has(e)));let S={},C={};if(_.length>0){let e=b(_,{lossFunction:x,distinct:p});s&&(e=de(e,o,f)),S=fe(e,n,r,i,c),C=ve(S,_,h)}let w={};_.forEach(e=>{e.label&&(w[e.sets]=e.label)});function T(e){if(e.sets in w)return w[e.sets];if(e.sets.length==1)return``+e.sets[0]}g.selectAll(`svg`).data([S]).enter().append(`svg`);let E=g.select(`svg`);t?E.attr(`viewBox`,`0 0 ${n} ${r}`):E.attr(`width`,n).attr(`height`,r);let D={},O=!1;E.selectAll(`.venn-area path`).each(function(e){let t=this.getAttribute(`d`);e.sets.length==1&&t&&!p&&(O=!0,D[e.sets[0]]=be(t))});function k(e){return t=>Ce(e.sets.map(e=>{let i=D[e],a=S[e];return i||={x:n/2,y:r/2,radius:1},a||={x:n/2,y:r/2,radius:1},{x:i.x*(1-t)+a.x*t,y:i.y*(1-t)+a.y*t,radius:i.radius*(1-t)+a.radius*t}}),m)}let A=E.selectAll(`.venn-area`).data(_,e=>e.sets),j=A.enter().append(`g`).attr(`class`,e=>`venn-area venn-${e.sets.length==1?`circle`:`intersection`}${e.colour||e.color?` venn-coloured`:``}`).attr(`data-venn-sets`,e=>e.sets.join(`_`)),M=j.append(`path`),N=j.append(`text`).attr(`class`,`label`).text(e=>T(e)).attr(`text-anchor`,`middle`).attr(`dy`,`.35em`).attr(`x`,n/2).attr(`y`,r/2);u&&(M.style(`fill-opacity`,`0`).filter(e=>e.sets.length==1).style(`fill`,e=>e.colour?e.colour:e.color?e.color:y(e.sets)).style(`fill-opacity`,`.25`),N.style(`fill`,t=>t.colour||t.color?`#FFF`:e.textFill?e.textFill:t.sets.length==1?y(t.sets):`#444`));function P(e){return typeof e.transition==`function`?e.transition(`venn`).duration(a):e}let F=g;O&&typeof F.transition==`function`?(F=P(g),F.selectAll(`path`).attrTween(`d`,k)):F.selectAll(`path`).attr(`d`,e=>Ce(e.sets.map(e=>S[e])),m);let I=F.selectAll(`text`).filter(e=>e.sets in C).text(e=>T(e)).attr(`x`,e=>Math.floor(C[e.sets].x)).attr(`y`,e=>Math.floor(C[e.sets].y));l&&(O?`on`in I?I.on(`end`,H(S,T)):I.each(`end`,H(S,T)):I.each(H(S,T)));let L=P(A.exit()).remove();typeof A.transition==`function`&&L.selectAll(`path`).attrTween(`d`,k);let R=L.selectAll(`text`).attr(`x`,n/2).attr(`y`,r/2);return d!==null&&(N.style(`font-size`,`0px`),I.style(`font-size`,d),R.style(`font-size`,`0px`)),{circles:S,textCentres:C,nodes:A,enter:j,update:F,exit:L}}return S.wrap=function(e){return arguments.length?(l=e,S):l},S.useViewBox=function(){return t=!0,S},S.width=function(e){return arguments.length?(n=e,S):n},S.height=function(e){return arguments.length?(r=e,S):r},S.padding=function(e){return arguments.length?(i=e,S):i},S.distinct=function(e){return arguments.length?(p=e,S):p},S.colours=function(e){return arguments.length?(y=e,S):y},S.colors=function(e){return arguments.length?(y=e,S):y},S.fontSize=function(e){return arguments.length?(d=e,S):d},S.round=function(e){return arguments.length?(m=e,S):m},S.duration=function(e){return arguments.length?(a=e,S):a},S.layoutFunction=function(e){return arguments.length?(b=e,S):b},S.normalize=function(e){return arguments.length?(s=e,S):s},S.scaleToFit=function(e){return arguments.length?(c=e,S):c},S.styled=function(e){return arguments.length?(u=e,S):u},S.orientation=function(e){return arguments.length?(o=e,S):o},S.orientationOrder=function(e){return arguments.length?(f=e,S):f},S.lossFunction=function(e){return arguments.length?(x=e==="default"?B:e===`logRatio`?ce:e,S):x},S}function H(e,t){return function(n){let r=this,i=e[n.sets[0]].radius||50,a=t(n)||``,o=a.split(/\s+/).reverse(),s=(a.length+o.length)/3,c=o.pop(),l=[c],u=0,d=1.1;r.textContent=null;let f=[];function p(e){let t=r.ownerDocument.createElementNS(r.namespaceURI,`tspan`);return t.textContent=e,f.push(t),r.append(t),t}let m=p(c);for(;c=o.pop(),c;){l.push(c);let e=l.join(` `);m.textContent=e,e.length>s&&m.getComputedTextLength()>i&&(l.pop(),m.textContent=l.join(` `),l=[c],m=p(c),u++)}let h=.35-u*d/2,g=r.getAttribute(`x`),_=r.getAttribute(`y`);f.forEach((e,t)=>{e.setAttribute(`x`,g),e.setAttribute(`y`,_),e.setAttribute(`dy`,`${h+t*d}em`)})}}function U(e,t,n){let r=t[0].radius-T(t[0],e);for(let n=1;n=a&&(i=r[n],a=o)}let o=I(n=>-1*U({x:n[0],y:n[1]},e,t),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,s={x:n?0:o[0],y:o[1]},c=!0;for(let t of e)if(T(s,t)>t.radius){c=!1;break}for(let e of t)if(T(s,e)e.p1))}function _e(e){let t={},n=Object.keys(e);for(let e of n)t[e]=[];for(let r=0;r0&&console.log(`WARNING: area `+o+` not represented on screen`)}return r}function ye(e,t,n){let r=[];return r.push(` +M`,e,t),r.push(` +m`,-n,0),r.push(` +a`,n,n,0,1,0,n*2,0),r.push(` +a`,n,n,0,1,0,-n*2,0),r.join(` `)}function be(e){let t=e.split(` `);return{x:Number.parseFloat(t[1]),y:Number.parseFloat(t[2]),radius:-Number.parseFloat(t[4])}}function xe(e){if(e.length===0)return[];let t={};return x(e,t),t.arcs}function Se(e,t){if(e.length===0)return`M 0 0`;let n=10**(t||0),r=t==null?e=>e:e=>Math.round(e*n)/n;if(e.length==1){let t=e[0].circle;return ye(r(t.x),r(t.y),r(t.radius))}let i=[` +M`,r(e[0].p2.x),r(e[0].p2.y)];for(let t of e){let e=r(t.circle.radius);i.push(` +A`,e,e,0,+!!t.large,+!!t.sweep,r(t.p1.x),r(t.p1.y))}return i.join(` `)}function Ce(e,t){return Se(xe(e),t)}function we(e,t={}){let{lossFunction:n,layoutFunction:r=ee,normalize:i=!0,orientation:a=Math.PI/2,orientationOrder:o,width:s=600,height:c=350,padding:l=15,scaleToFit:u=!1,symmetricalTextCentre:d=!1,distinct:f,round:p=2}=t,m=r(e,{lossFunction:n==="default"||!n?B:n===`logRatio`?ce:n,distinct:f});i&&(m=de(m,a,o));let h=fe(m,s,c,l,u),g=ve(h,e,d),_=new Map(Object.keys(h).map(e=>[e,{set:e,x:h[e].x,y:h[e].y,radius:h[e].radius}])),v=e.map(e=>{let t=e.sets.map(e=>_.get(e)),n=xe(t);return{circles:t,arcs:n,path:Se(n,p),area:e,has:new Set(e.sets)}});function y(e){let t=``;for(let n of v)n.has.size>e.length&&e.every(e=>n.has.has(e))&&(t+=` `+n.path);return t}return v.map(({circles:e,arcs:t,path:n,area:r})=>({data:r,text:g[r.sets],circles:e,arcs:t,path:n,distinctPath:n+y(r.sets)}))}var W=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[5,8],r=[7,8,11,12,17,19,22,24],i=[1,17],a=[1,18],o=[7,8,11,12,14,15,16,17,19,20,21,22,24,27],s=[1,31],c=[1,39],l=[7,8,11,12,17,19,22,24,27],u=[1,57],d=[1,56],f=[1,58],p=[1,59],m=[1,60],h=[7,8,11,12,16,17,19,20,22,24,27,31,32,33],g={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,optNewlines:4,VENN:5,document:6,EOF:7,NEWLINE:8,line:9,statement:10,TITLE:11,SET:12,identifier:13,BRACKET_LABEL:14,COLON:15,NUMERIC:16,UNION:17,identifierList:18,TEXT:19,IDENTIFIER:20,STRING:21,INDENT_TEXT:22,indentedTextTail:23,STYLE:24,stylesOpt:25,styleField:26,COMMA:27,styleValue:28,valueTokens:29,valueToken:30,HEXCOLOR:31,RGBCOLOR:32,RGBACOLOR:33,$accept:0,$end:1},terminals_:{2:`error`,5:`VENN`,7:`EOF`,8:`NEWLINE`,11:`TITLE`,12:`SET`,14:`BRACKET_LABEL`,15:`COLON`,16:`NUMERIC`,17:`UNION`,19:`TEXT`,20:`IDENTIFIER`,21:`STRING`,22:`INDENT_TEXT`,24:`STYLE`,27:`COMMA`,31:`HEXCOLOR`,32:`RGBCOLOR`,33:`RGBACOLOR`},productions_:[0,[3,4],[4,0],[4,2],[6,0],[6,2],[9,1],[9,1],[10,1],[10,2],[10,3],[10,4],[10,5],[10,2],[10,3],[10,4],[10,5],[10,3],[10,3],[10,3],[10,4],[10,4],[10,2],[10,3],[23,1],[23,1],[23,1],[23,2],[23,2],[25,1],[25,3],[26,3],[28,1],[28,1],[29,1],[29,2],[30,1],[30,1],[30,1],[30,1],[30,1],[18,1],[18,3],[13,1],[13,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:case 3:case 4:this.$=[];break;case 5:a[s-1].push(a[s]),this.$=a[s-1];break;case 6:this.$=[];break;case 7:case 22:case 32:case 36:case 37:case 38:case 39:case 40:this.$=a[s];break;case 8:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 9:r.addSubsetData([a[s]],void 0,void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 10:r.addSubsetData([a[s-1]],a[s],void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 11:r.addSubsetData([a[s-2]],void 0,parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 12:r.addSubsetData([a[s-3]],a[s-2],parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 13:if(a[s].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s]),r.addSubsetData(a[s],void 0,void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 14:if(a[s-1].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-1]),r.addSubsetData(a[s-1],a[s],void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 15:if(a[s-2].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-2]),r.addSubsetData(a[s-2],void 0,parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 16:if(a[s-3].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-3]),r.addSubsetData(a[s-3],a[s-2],parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 17:case 18:case 19:r.addTextData(a[s-1],a[s],void 0);break;case 20:case 21:r.addTextData(a[s-2],a[s-1],a[s]);break;case 23:r.addStyleData(a[s-1],a[s]);break;case 24:case 25:case 26:var c=r.getCurrentSets();if(!c)throw Error(`text requires set`);r.addTextData(c,a[s],void 0);break;case 27:case 28:var c=r.getCurrentSets();if(!c)throw Error(`text requires set`);r.addTextData(c,a[s-1],a[s]);break;case 29:case 41:this.$=[a[s]];break;case 30:case 42:this.$=[...a[s-2],a[s]];break;case 31:this.$=[a[s-2],a[s]];break;case 33:this.$=a[s].join(` `);break;case 34:this.$=[a[s]];break;case 35:a[s-1].push(a[s]),this.$=a[s-1];break;case 43:case 44:this.$=a[s]}},`anonymous`),table:[e(n,[2,2],{3:1,4:2}),{1:[3]},{5:[1,3],8:[1,4]},e(r,[2,4],{6:5}),e(n,[2,3]),{7:[1,6],8:[1,8],9:7,10:9,11:[1,10],12:[1,11],17:[1,12],19:[1,13],22:[1,14],24:[1,15]},{1:[2,1]},e(r,[2,5]),e(r,[2,6]),e(r,[2,7]),e(r,[2,8]),{13:16,20:i,21:a},{13:20,18:19,20:i,21:a},{13:20,18:21,20:i,21:a},{16:[1,25],20:[1,23],21:[1,24],23:22},{13:20,18:26,20:i,21:a},e(r,[2,9],{14:[1,27],15:[1,28]}),e(o,[2,43]),e(o,[2,44]),e(r,[2,13],{14:[1,29],15:[1,30],27:s}),e(o,[2,41]),{16:[1,34],20:[1,32],21:[1,33],27:s},e(r,[2,22]),e(r,[2,24],{14:[1,35]}),e(r,[2,25],{14:[1,36]}),e(r,[2,26]),{20:c,25:37,26:38,27:s},e(r,[2,10],{15:[1,40]}),{16:[1,41]},e(r,[2,14],{15:[1,42]}),{16:[1,43]},{13:44,20:i,21:a},e(r,[2,17],{14:[1,45]}),e(r,[2,18],{14:[1,46]}),e(r,[2,19]),e(r,[2,27]),e(r,[2,28]),e(r,[2,23],{27:[1,47]}),e(l,[2,29]),{15:[1,48]},{16:[1,49]},e(r,[2,11]),{16:[1,50]},e(r,[2,15]),e(o,[2,42]),e(r,[2,20]),e(r,[2,21]),{20:c,26:51},{16:u,20:d,21:[1,53],28:52,29:54,30:55,31:f,32:p,33:m},e(r,[2,12]),e(r,[2,16]),e(l,[2,30]),e(l,[2,31]),e(l,[2,32]),e(l,[2,33],{30:61,16:u,20:d,31:f,32:p,33:m}),e(h,[2,34]),e(h,[2,36]),e(h,[2,37]),e(h,[2,38]),e(h,[2,39]),e(h,[2,40]),e(h,[2,35])],defaultActions:{6:[2,1]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};g.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:break;case 3:if(e.getIndentMode&&e.getIndentMode())return e.consumeIndentText=!0,this.begin(`INITIAL`),22;break;case 4:break;case 5:e.setIndentMode&&e.setIndentMode(!1),this.begin(`INITIAL`),this.unput(t.yytext);break;case 6:return this.begin(`bol`),8;case 7:break;case 8:break;case 9:return 7;case 10:return 11;case 11:return 5;case 12:return 12;case 13:return 17;case 14:if(e.consumeIndentText)e.consumeIndentText=!1;else return 19;break;case 15:return 24;case 16:return t.yytext=t.yytext.slice(2,-2),14;case 17:return t.yytext=t.yytext.slice(1,-1).trim(),14;case 18:return 16;case 19:return 31;case 20:return 33;case 21:return 32;case 22:return 20;case 23:return 21;case 24:return 27;case 25:return 15}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[ \t]+(?=[\n\r]))/i,/^(?:[ \t]+(?=text\b))/i,/^(?:[ \t]+)/i,/^(?:[^ \t\n\r])/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:[ \t]+)/i,/^(?:$)/i,/^(?:title\s[^#\n;]+)/i,/^(?:venn-beta\b)/i,/^(?:set\b)/i,/^(?:union\b)/i,/^(?:text\b)/i,/^(?:style\b)/i,/^(?:\["[^\"]*"\])/i,/^(?:\[[^\]\"]+\])/i,/^(?:[+-]?(\d+(\.\d+)?|\.\d+))/i,/^(?:#[0-9a-fA-F]{3,8})/i,/^(?:rgba\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:rgb\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:[A-Za-z_][A-Za-z0-9\-_]*)/i,/^(?:"[^\"]*")/i,/^(?:,)/i,/^(?::)/i],conditions:{bol:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0},INITIAL:{rules:[0,1,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0}}}})();function _(){this.yy={}}return t(_,`Parser`),_.prototype=g,g.Parser=_,new _})();W.parser=W;var Te=W,G=[],K=[],q=[],J=new Set,Y,X=!1,Ee=t((e,t,n)=>{let r=Q(e).sort(),i=n??10/e.length**2;Y=r,r.length===1&&J.add(r[0]),G.push({sets:r,size:i,label:t?Z(t):void 0})},`addSubsetData`),De=t(()=>G,`getSubsetData`),Z=t(e=>{let t=e.trim();return t.length>=2&&t.startsWith(`"`)&&t.endsWith(`"`)?t.slice(1,-1):t},`normalizeText`),Oe=t(e=>e&&Z(e),`normalizeStyleValue`),ke=t((e,t,n)=>{let r=Z(t);K.push({sets:Q(e).sort(),id:r,label:n?Z(n):void 0})},`addTextData`),Ae=t((e,t)=>{let n=Q(e).sort(),r={};for(let[e,n]of t)r[e]=Oe(n)??n;q.push({targets:n,styles:r})},`addStyleData`),je=t(()=>q,`getStyleData`),Q=t(e=>e.map(e=>Z(e)),`normalizeIdentifierList`),Me=t(e=>{let t=Q(e).filter(e=>!J.has(e));if(t.length>0)throw Error(`unknown set identifier: ${t.join(`, `)}`)},`validateUnionIdentifiers`),Ne=t(()=>K,`getTextData`),Pe=t(()=>Y,`getCurrentSets`),Fe=t(()=>X,`getIndentMode`),Ie=t(e=>{X=e},`setIndentMode`),Le=c.venn;function Re(){return g(Le,o().venn)}t(Re,`getConfig`);var ze={getConfig:Re,clear:t(()=>{i(),G.length=0,K.length=0,q.length=0,J.clear(),Y=void 0,X=!1},`customClear`),setAccTitle:r,getAccTitle:h,setDiagramTitle:d,getDiagramTitle:m,getAccDescription:p,setAccDescription:n,addSubsetData:Ee,getSubsetData:De,addTextData:ke,addStyleData:Ae,validateUnionIdentifiers:Me,getTextData:Ne,getStyleData:je,getCurrentSets:Pe,getIndentMode:Fe,setIndentMode:Ie},Be=t(e=>` + .venn-title { + font-size: 32px; + fill: ${e.vennTitleTextColor}; + font-family: ${e.fontFamily}; + } + + .venn-circle text { + font-size: 48px; + font-family: ${e.fontFamily}; + } + + .venn-intersection text { + font-size: 48px; + fill: ${e.vennSetTextColor}; + font-family: ${e.fontFamily}; + } + + .venn-text-node { + font-family: ${e.fontFamily}; + color: ${e.vennSetTextColor}; + } +`,`getStyles`);function Ve(e){let t=new Map;for(let n of e){let e=n.targets.join(`|`),r=t.get(e);r?Object.assign(r,n.styles):t.set(e,{...n.styles})}return t}t(Ve,`buildStyleByKey`);var He=t((t,n,r,i)=>{let c=i.db,l=c.getConfig?.(),{themeVariables:d,look:p,handDrawnSeed:m}=o(),h=p===`handDrawn`,g=[d.venn1,d.venn2,d.venn3,d.venn4,d.venn5,d.venn6,d.venn7,d.venn8].filter(Boolean),b=c.getDiagramTitle?.(),x=c.getSubsetData(),S=c.getTextData(),C=Ve(c.getStyleData()),w=We(x),T=l?.width??800,E=l?.height??450,D=T/1600,O=b?48*D:0,k=d.primaryTextColor??d.textColor,A=v(n);A.attr(`viewBox`,`0 0 ${T} ${E}`),b&&A.append(`text`).text(b).attr(`class`,`venn-title`).attr(`font-size`,`${32*D}px`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).attr(`x`,`50%`).attr(`y`,32*D).style(`fill`,d.vennTitleTextColor||d.titleColor);let j=e(document.createElement(`div`)),M=he().width(T).height(E-O);j.datum(w).call(M);let N=h?_.svg(j.select(`svg`).node()):void 0,P=we(w,{width:T,height:E-O,padding:l?.padding??15}),F=new Map;for(let e of P){let t=$([...e.data.sets].sort());F.set(t,e)}S.length>0&&Ue(l,F,j,S,D,C);let I=a(d.background||`#f4f4f4`);j.selectAll(`.venn-circle`).each(function(t,n){let r=e(this),i=$([...t.sets].sort()),a=C.get(i),o=g.length>0?g[n%g.length]:void 0,s=a?.fill||o||d.primaryColor;r.classed(`venn-set-${n%8}`,!0);let c=a?.[`fill-opacity`]??.1,l=a?.stroke||s,p=a?.[`stroke-width`]||`${5*D}`;if(h&&N){let e=F.get(i);if(e&&e.circles.length>0){let t=e.circles[0],i=N.circle(t.x,t.y,t.radius*2,{roughness:.7,seed:m,fill:y(s,.7),fillStyle:`hachure`,fillWeight:2,hachureGap:8,hachureAngle:-41+n*60,stroke:l,strokeWidth:parseFloat(String(p))});r.select(`path`).remove(),r.node()?.insertBefore(i,r.select(`text`).node())}}else r.select(`path`).style(`fill`,s).style(`fill-opacity`,c).style(`stroke`,l).style(`stroke-width`,p).style(`stroke-opacity`,.95);let _=a?.color||(I?f(s,30):u(s,30));r.select(`text`).style(`font-size`,`${48*D}px`).style(`fill`,_)}),h&&N?j.selectAll(`.venn-intersection`).each(function(t){let n=e(this),r=$([...t.sets].sort()),i=C.get(r),a=i?.fill;if(a){let e=n.select(`path`),t=e.attr(`d`);if(t){let n=N.path(t,{roughness:.7,seed:m,fill:y(a,.3),fillStyle:`cross-hatch`,fillWeight:2,hachureGap:6,hachureAngle:60,stroke:`none`}),r=e.node();r?.parentNode?.insertBefore(n,r),e.remove()}}else n.select(`path`).style(`fill-opacity`,0);n.select(`text`).style(`font-size`,`${48*D}px`).style(`fill`,i?.color??d.vennSetTextColor??k)}):(j.selectAll(`.venn-intersection text`).style(`font-size`,`${48*D}px`).style(`fill`,e=>{let t=$([...e.sets].sort());return C.get(t)?.color??d.vennSetTextColor??k}),j.selectAll(`.venn-intersection path`).style(`fill-opacity`,e=>{let t=$([...e.sets].sort());return+!!C.get(t)?.fill}).style(`fill`,e=>{let t=$([...e.sets].sort());return C.get(t)?.fill??`transparent`}));let L=A.append(`g`).attr(`transform`,`translate(0, ${O})`),R=j.select(`svg`).node();if(R&&`childNodes`in R)for(let e of[...R.childNodes])L.node()?.appendChild(e);s(A,E,T,l?.useMaxWidth??!0)},`draw`);function $(e){return e.join(`|`)}t($,`stableSetsKey`);function Ue(e,t,n,r,i,a){let o=e?.useDebugLayout??!1,s=n.select(`svg`).append(`g`).attr(`class`,`venn-text-nodes`),c=new Map;for(let e of r){let t=$(e.sets),n=c.get(t);n?n.push(e):c.set(t,[e])}for(let[e,n]of c.entries()){let r=t.get(e);if(!r?.text)continue;let c=r.text.x,l=r.text.y,u=Math.min(...r.circles.map(e=>e.radius)),d=Math.min(...r.circles.map(e=>e.radius-Math.hypot(c-e.x,l-e.y))),f=Number.isFinite(d)?Math.max(0,d):0;f===0&&Number.isFinite(u)&&(f=u*.6);let p=s.append(`g`).attr(`class`,`venn-text-area`).attr(`font-size`,`${40*i}px`);o&&p.append(`circle`).attr(`class`,`venn-text-debug-circle`).attr(`cx`,c).attr(`cy`,l).attr(`r`,f).attr(`fill`,`none`).attr(`stroke`,`purple`).attr(`stroke-width`,1.5*i).attr(`stroke-dasharray`,`${6*i} ${4*i}`);let m=Math.max(80*i,f*2*.95),h=Math.max(60*i,f*2*.95),g=(r.data.label&&r.data.label.length>0?Math.min(32*i,f*.25):0)+(n.length<=2?30*i:0),_=c-m/2,v=l-h/2+g,y=Math.max(1,Math.ceil(Math.sqrt(n.length))),b=Math.max(1,Math.ceil(n.length/y)),x=m/y,S=h/b;for(let[e,t]of n.entries()){let n=e%y,r=Math.floor(e/y),s=_+x*(n+.5),c=v+S*(r+.5);o&&p.append(`rect`).attr(`class`,`venn-text-debug-cell`).attr(`x`,_+x*n).attr(`y`,v+S*r).attr(`width`,x).attr(`height`,S).attr(`fill`,`none`).attr(`stroke`,`teal`).attr(`stroke-width`,1*i).attr(`stroke-dasharray`,`${4*i} ${3*i}`);let l=x*.9,u=S*.9,d=p.append(`foreignObject`).attr(`class`,`venn-text-node-fo`).attr(`width`,l).attr(`height`,u).attr(`x`,s-l/2).attr(`y`,c-u/2).attr(`overflow`,`visible`),f=a.get(t.id)?.color,m=d.append(`xhtml:span`).attr(`class`,`venn-text-node`).style(`display`,`flex`).style(`width`,`100%`).style(`height`,`100%`).style(`white-space`,`normal`).style(`align-items`,`center`).style(`justify-content`,`center`).style(`text-align`,`center`).style(`overflow-wrap`,`normal`).style(`word-break`,`normal`).text(t.label??t.id);f&&m.style(`color`,f)}}}t(Ue,`renderTextNodes`);function We(e){let t=new Set(e.map(e=>[...e.sets].sort().join(`|`))),n=new Map(e.filter(e=>e.sets.length===1&&e.size!==void 0).map(e=>[e.sets[0],e.size])),r=[];for(let i of e){if(i.sets.length<3)continue;let e=[...i.sets].sort();for(let i=0;i0?[...e,...r]:e}t(We,`ensurePairwiseSubsets`);var Ge={parser:Te,db:ze,renderer:{draw:He},styles:Be};export{Ge as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/wardley-WFR3VGLG-kIjJw24i.js b/frontend/dist/assets/wardley-WFR3VGLG-kIjJw24i.js new file mode 100644 index 0000000..55593b0 --- /dev/null +++ b/frontend/dist/assets/wardley-WFR3VGLG-kIjJw24i.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{i as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createWardleyServices}; \ No newline at end of file diff --git a/frontend/dist/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js b/frontend/dist/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js new file mode 100644 index 0000000..2678b0a --- /dev/null +++ b/frontend/dist/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js @@ -0,0 +1,78 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,q as c,v as l,w as u,x as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=t((e,t)=>{let n=e<=1?e*100:e;if(n<0||n>100)throw Error(`${t} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${e}`);return n},`toPercent`),v=t((e,t,n)=>({x:_(t,`${n} evolution`),y:_(e,`${n} visibility`)}),`toCoordinates`),y=t(e=>{if(e){if(e===`+<>`)return`bidirectional`;if(e===`+<`)return`backward`;if(e===`+>`)return`forward`}},`getFlowFromPort`),b=t(e=>{if(!e?.startsWith(`+`))return{};let t=/^\+'([^']*)'/.exec(e)?.[1];return e.includes(`<>`)?{flow:`bidirectional`,label:t}:e.includes(`<`)?{flow:`backward`,label:t}:e.includes(`>`)?{flow:`forward`,label:t}:{label:t}},`extractFlowFromArrow`),x=t((e,t)=>{if(g(e,t),e.size&&t.setSize(e.size.width,e.size.height),e.evolution){let n=e.evolution.stages.map(e=>e.secondName?`${e.name.trim()} / ${e.secondName.trim()}`:e.name.trim()),r=e.evolution.stages.filter(e=>e.boundary!==void 0).map(e=>e.boundary);t.updateAxes({stages:n,stageBoundaries:r})}if(e.anchors.forEach(e=>{let n=v(e.visibility,e.evolution,`Anchor "${e.name}"`);t.addNode(e.name,e.name,n.x,n.y,`anchor`)}),e.components.forEach(e=>{let n=v(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,i=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,a=e.decorator?.strategy;t.addNode(e.name,e.name,n.x,n.y,`component`,r,i,e.inertia,a)}),e.notes.forEach(e=>{let n=v(e.visibility,e.evolution,`Note "${e.text}"`);t.addNote(e.text,n.x,n.y)}),e.pipelines.forEach(e=>{let n=t.getNode(e.parent);if(!n||typeof n.y!=`number`)throw Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);let r=n.y;t.startPipeline(e.parent),e.components.forEach(n=>{let i=`${e.parent}_${n.name}`,a=n.label?(n.label.negX?-1:1)*n.label.offsetX:void 0,o=n.label?(n.label.negY?-1:1)*n.label.offsetY:void 0,s=_(n.evolution,`Pipeline component "${n.name}" evolution`);t.addNode(i,n.name,s,r,`pipeline-component`,a,o),t.addPipelineComponent(e.parent,i)})}),e.links.forEach(e=>{let n=!!e.arrow&&(e.arrow.includes(`-.->`)||e.arrow.includes(`.-.`)),r=y(e.fromPort)??y(e.toPort),{flow:i,label:a}=b(e.arrow);!r&&i&&(r=i);let o=e.linkLabel,s=a??o;t.addLink(t.resolveNodeId(e.from),t.resolveNodeId(e.to),n,s,r)}),e.evolves.forEach(e=>{let n=t.getNode(e.component);if(n?.y!==void 0){let r=_(e.target,`Evolve target for "${e.component}"`);t.addTrend(e.component,r,n.y)}}),e.annotations.length>0){let n=e.annotations[0],r=v(n.x,n.y,`Annotations box`);t.setAnnotationsBox(r.x,r.y)}e.annotation.forEach(e=>{let n=v(e.x,e.y,`Annotation ${e.number}`);t.addAnnotation(e.number,[{x:n.x,y:n.y}],e.text)}),e.accelerators.forEach(e=>{let n=v(e.x,e.y,`Accelerator "${e.name}"`);t.addAccelerator(e.name,n.x,n.y)}),e.deaccelerators.forEach(e=>{let n=v(e.x,e.y,`Deaccelerator "${e.name}"`);t.addDeaccelerator(e.name,n.x,n.y)})},`populateDb`),S={parser:{yy:void 0},parse:t(async t=>{let n=await h(`wardley`,t);e.debug(n);let r=S.parser?.yy;if(!r||typeof r.addNode!=`function`)throw Error(`parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);x(n,r)},`parse`)},C=new class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}static{t(this,`WardleyBuilder`)}addNode(e){let t=this.nodes.get(e.id)??{id:e.id,label:e.label},n={...t,...e,className:e.className??t.className,labelOffsetX:e.labelOffsetX??t.labelOffsetX,labelOffsetY:e.labelOffsetY??t.labelOffsetY};this.nodes.set(e.id,n)}addLink(e){this.links.push(e)}addTrend(e){this.trends.set(e.nodeId,e)}startPipeline(e){this.pipelines.set(e,{nodeId:e,componentIds:[]});let t=this.nodes.get(e);t&&(t.isPipelineParent=!0)}addPipelineComponent(e,t){let n=this.pipelines.get(e);n&&n.componentIds.push(t);let r=this.nodes.get(t);r&&(r.inPipeline=!0)}addAnnotation(e){this.annotations.push(e)}addNote(e){this.notes.push(e)}addAccelerator(e){this.accelerators.push(e)}addDeaccelerator(e){this.deaccelerators.push(e)}setAnnotationsBox(e,t){this.annotationsBox={x:e,y:t}}setAxes(e){this.axes={...this.axes,...e}}setSize(e,t){this.size={width:e,height:t}}getNode(e){return this.nodes.get(e)}resolveNodeId(e){if(this.nodes.has(e))return e;for(let[t,n]of this.nodes)if(n.label===e)return t;return e}build(){let e=[];for(let t of this.nodes.values()){if(typeof t.x!=`number`||typeof t.y!=`number`)throw Error(`Node "${t.label}" is missing coordinates`);e.push(t)}return{nodes:e,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}};function w(){return d()[`wardley-beta`]}t(w,`getConfig`);function T(e,t,n,r,i,a,o,s,c){C.addNode({id:e,label:t,x:n,y:r,className:i,labelOffsetX:a,labelOffsetY:o,inertia:s,sourceStrategy:c})}t(T,`addNode`);function E(e,t,n=!1,r,i){C.addLink({source:e,target:t,dashed:n,label:r,flow:i})}t(E,`addLink`);function D(e,t,n){C.addTrend({nodeId:e,targetX:t,targetY:n})}t(D,`addTrend`);function O(e,t,n){C.addAnnotation({number:e,coordinates:t,text:n})}t(O,`addAnnotation`);function k(e,t,n){C.addNote({text:e,x:t,y:n})}t(k,`addNote`);function A(e,t,n){C.addAccelerator({name:e,x:t,y:n})}t(A,`addAccelerator`);function j(e,t,n){C.addDeaccelerator({name:e,x:t,y:n})}t(j,`addDeaccelerator`);function M(e,t){C.setAnnotationsBox(e,t)}t(M,`setAnnotationsBox`);function N(e,t){C.setSize(e,t)}t(N,`setSize`);function P(e){C.startPipeline(e)}t(P,`startPipeline`);function F(e,t){C.addPipelineComponent(e,t)}t(F,`addPipelineComponent`);function I(e){C.setAxes(e)}t(I,`updateAxes`);function L(e){return C.getNode(e)}t(L,`getNode`);function R(e){return C.resolveNodeId(e)}t(R,`resolveNodeId`);function z(){return C.build()}t(z,`getWardleyData`);function B(){C.clear(),a()}t(B,`clear`);var V={getConfig:w,addNode:T,addLink:E,addTrend:D,addAnnotation:O,addNote:k,addAccelerator:A,addDeaccelerator:j,setAnnotationsBox:M,setSize:N,startPipeline:P,addPipelineComponent:F,updateAxes:I,getNode:L,resolveNodeId:R,getWardleyData:z,clear:B,setAccTitle:i,getAccTitle:f,setDiagramTitle:c,getDiagramTitle:u,getAccDescription:l,setAccDescription:r},H=[`Genesis`,`Custom Built`,`Product`,`Commodity`],U=t(()=>{let{themeVariables:e}=d();return{backgroundColor:e.wardley?.backgroundColor??e.background??`#fff`,axisColor:e.wardley?.axisColor??`#000`,axisTextColor:e.wardley?.axisTextColor??e.primaryTextColor??`#222`,gridColor:e.wardley?.gridColor??`rgba(100, 100, 100, 0.2)`,componentFill:e.wardley?.componentFill??`#fff`,componentStroke:e.wardley?.componentStroke??`#000`,componentLabelColor:e.wardley?.componentLabelColor??e.primaryTextColor??`#222`,linkStroke:e.wardley?.linkStroke??`#000`,evolutionStroke:e.wardley?.evolutionStroke??`#dc3545`,annotationStroke:e.wardley?.annotationStroke??`#000`,annotationTextColor:e.wardley?.annotationTextColor??e.primaryTextColor??`#222`,annotationFill:e.wardley?.annotationFill??e.background??`#fff`}},`getTheme`),W=t(()=>{let e=d()[`wardley-beta`];return{width:e?.width??900,height:e?.height??600,padding:e?.padding??48,nodeRadius:e?.nodeRadius??6,nodeLabelOffset:e?.nodeLabelOffset??8,axisFontSize:e?.axisFontSize??12,labelFontSize:e?.labelFontSize??10,showGrid:e?.showGrid??!1,useMaxWidth:e?.useMaxWidth??!0}},`getConfigValues`),G={parser:S,db:V,renderer:{draw:t((n,r,i,a)=>{e.debug(`Rendering Wardley map +`+n);let o=W(),c=U(),l=o.nodeRadius*1.6,u=a.db,d=u.getWardleyData(),f=u.getDiagramTitle(),p=d.size?.width??o.width,h=d.size?.height??o.height,g=m(r);g.selectAll(`*`).remove(),s(g,h,p,o.useMaxWidth),g.attr(`viewBox`,`0 0 ${p} ${h}`);let _=g.append(`g`).attr(`class`,`wardley-map`),v=g.append(`defs`);v.append(`marker`).attr(`id`,`arrow-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,c.evolutionStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-end-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,c.linkStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-start-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,1).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 z`).attr(`fill`,c.linkStroke).attr(`stroke`,`none`),_.append(`rect`).attr(`class`,`wardley-background`).attr(`width`,p).attr(`height`,h).attr(`fill`,c.backgroundColor);let y=p-o.padding*2,b=h-o.padding*2;f&&_.append(`text`).attr(`class`,`wardley-title`).attr(`x`,p/2).attr(`y`,o.padding/2).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize*1.05).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(f);let x=t(e=>o.padding+e/100*y,`projectX`),S=t(e=>h-o.padding-e/100*b,`projectY`),C=_.append(`g`).attr(`class`,`wardley-axes`);C.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.axisColor).attr(`stroke-width`,1),C.append(`line`).attr(`x1`,o.padding).attr(`x2`,o.padding).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.axisColor).attr(`stroke-width`,1);let w=d.axes.xLabel??`Evolution`,T=d.axes.yLabel??`Visibility`;C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-x`).attr(`x`,o.padding+y/2).attr(`y`,h-o.padding/4).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).text(w),C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-y`).attr(`x`,o.padding/3).attr(`y`,o.padding+b/2).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`transform`,`rotate(-90 ${o.padding/3} ${o.padding+b/2})`).text(T);let E=d.axes.stages&&d.axes.stages.length>0?d.axes.stages:H;if(E.length>0){let e=_.append(`g`).attr(`class`,`wardley-stages`),t=d.axes.stageBoundaries,n=[];if(t&&t.length===E.length){let e=0;t.forEach(t=>{n.push({start:e,end:t}),e=t})}else{let e=1/E.length;E.forEach((t,r)=>{n.push({start:r*e,end:(r+1)*e})})}E.forEach((t,r)=>{let i=n[r],a=o.padding+i.start*y,s=(a+(o.padding+i.end*y))/2;r>0&&e.append(`line`).attr(`x1`,a).attr(`x2`,a).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,`#000`).attr(`stroke-width`,1).attr(`stroke-dasharray`,`5 5`).attr(`opacity`,.8),e.append(`text`).attr(`class`,`wardley-stage-label`).attr(`x`,s).attr(`y`,h-o.padding/1.5).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize-2).attr(`text-anchor`,`middle`).text(t)})}if(o.showGrid){let e=_.append(`g`).attr(`class`,`wardley-grid`);for(let t=1;t<4;t++){let n=t/4,r=o.padding+y*n;e.append(`line`).attr(`x1`,r).attr(`x2`,r).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.gridColor).attr(`stroke-dasharray`,`2 6`),e.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding-b*n).attr(`y2`,h-o.padding-b*n).attr(`stroke`,c.gridColor).attr(`stroke-dasharray`,`2 6`)}}let D=new Map;if(d.nodes.forEach(e=>{D.set(e.id,{x:x(e.x),y:S(e.y),node:e})}),d.pipelines.length>0){let e=_.append(`g`).attr(`class`,`wardley-pipelines`),t=_.append(`g`).attr(`class`,`wardley-pipeline-links`);d.pipelines.forEach(n=>{if(n.componentIds.length===0)return;let r=n.componentIds.map(e=>({id:e,pos:D.get(e),node:d.nodes.find(t=>t.id===e)})).filter(e=>e.pos&&e.node).sort((e,t)=>e.node.x-t.node.x);for(let e=0;e{let t=D.get(e);t&&(i=Math.min(i,t.x),a=Math.max(a,t.x),s=t.y)}),i!==1/0&&a!==-1/0){let t=o.nodeRadius*4,r=s-t/2,u=D.get(n.nodeId);u&&(u.x=(i+a)/2,u.y=r-l/6),e.append(`rect`).attr(`class`,`wardley-pipeline-box`).attr(`x`,i-15).attr(`y`,r).attr(`width`,a-i+30).attr(`height`,t).attr(`fill`,`none`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}})}let O=_.append(`g`).attr(`class`,`wardley-links`),k=new Map;d.pipelines.forEach(e=>{k.set(e.nodeId,new Set(e.componentIds))});let A=d.links.filter(e=>!(!D.has(e.source)||!D.has(e.target)||k.get(e.target)?.has(e.source)));O.selectAll(`line`).data(A).enter().append(`line`).attr(`class`,e=>`wardley-link${e.dashed?` wardley-link--dashed`:``}`).attr(`x1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.x+i/s*r}).attr(`y1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.y+a/s*r}).attr(`x2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.x+i/s*r}).attr(`y2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.y+a/s*r}).attr(`stroke`,c.linkStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,e=>e.dashed?`6 6`:null).attr(`marker-end`,e=>e.flow===`forward`||e.flow===`bidirectional`?`url(#link-arrow-end-${r})`:null).attr(`marker-start`,e=>e.flow===`backward`||e.flow===`bidirectional`?`url(#link-arrow-start-${r})`:null),O.selectAll(`text`).data(A.filter(e=>e.label)).enter().append(`text`).attr(`class`,`wardley-link-label`).attr(`x`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=n.y-t.y,a=n.x-t.x;return r+i/Math.sqrt(a*a+i*i)*8}).attr(`y`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.y+n.y)/2,i=n.x-t.x,a=n.y-t.y,o=Math.sqrt(i*i+a*a);return r+-i/o*8}).attr(`fill`,c.axisTextColor).attr(`font-size`,o.labelFontSize).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).attr(`transform`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=(t.y+n.y)/2,a=n.x-t.x,o=n.y-t.y,s=Math.sqrt(a*a+o*o),c=o/s,l=-a/s,u=r+c*8,d=i+l*8,f=Math.atan2(o,a)*180/Math.PI;return(f>90||f<-90)&&(f+=180),`rotate(${f} ${u} ${d})`}).text(e=>e.label);let j=_.append(`g`).attr(`class`,`wardley-trends`),M=d.trends.map(e=>{let t=D.get(e.nodeId);if(!t)return null;let n=x(e.targetX),r=S(e.targetY),i=n-t.x,a=r-t.y,s=Math.sqrt(i*i+a*a),c=o.nodeRadius+2;return{origin:t,targetX:n,targetY:r,adjustedX2:s>c?n-i/s*c:n,adjustedY2:s>c?r-a/s*c:r}}).filter(e=>e!==null);j.selectAll(`line`).data(M).enter().append(`line`).attr(`class`,`wardley-trend`).attr(`x1`,e=>e.origin.x).attr(`y1`,e=>e.origin.y).attr(`x2`,e=>e.adjustedX2).attr(`y2`,e=>e.adjustedY2).attr(`stroke`,c.evolutionStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,`4 4`).attr(`marker-end`,`url(#arrow-${r})`);let N=_.append(`g`).attr(`class`,`wardley-nodes`).selectAll(`g`).data(d.nodes).enter().append(`g`).attr(`class`,e=>[`wardley-node`,e.className?`wardley-node--${e.className}`:``].filter(Boolean).join(` `));N.filter(e=>e.sourceStrategy===`outsource`).append(`circle`).attr(`class`,`wardley-outsource-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#666`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`buy`).append(`circle`).attr(`class`,`wardley-buy-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#ccc`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`build`).append(`circle`).attr(`class`,`wardley-build-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#eee`).attr(`stroke`,`#000`).attr(`stroke-width`,1);let P=N.filter(e=>e.sourceStrategy===`market`);P.append(`circle`).attr(`class`,`wardley-market-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>!e.isPipelineParent&&e.sourceStrategy!==`market`&&e.className!==`anchor`).append(`circle`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius).attr(`fill`,c.componentFill).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1);let F=o.nodeRadius*.7,I=o.nodeRadius*1.2;if(P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x).attr(`y1`,e=>D.get(e.id).y-I).attr(`x2`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x).attr(`y2`,e=>D.get(e.id).y-I).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y-I).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),N.filter(e=>e.isPipelineParent===!0).append(`rect`).attr(`x`,e=>D.get(e.id).x-l/2).attr(`y`,e=>D.get(e.id).y-l/2).attr(`width`,l).attr(`height`,l).attr(`fill`,c.componentFill).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.inertia===!0).append(`line`).attr(`class`,`wardley-inertia`).attr(`x1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y-n/2}).attr(`x2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y+n/2}).attr(`stroke`,c.componentStroke).attr(`stroke-width`,6),N.append(`text`).attr(`x`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetX===void 0?t.x:t.x+e.labelOffsetX;let n=o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetX===void 0&&(n+=10);let r=e.labelOffsetX??n;return t.x+r}).attr(`y`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetY===void 0?t.y-3:t.y+e.labelOffsetY;let n=-o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetY===void 0&&(n-=10);let r=e.labelOffsetY??n;return t.y+r}).attr(`class`,`wardley-node-label`).attr(`fill`,e=>e.className===`evolved`?c.evolutionStroke:e.className===`anchor`?`#000`:c.componentLabelColor).attr(`font-size`,o.labelFontSize).attr(`font-weight`,e=>e.className===`anchor`?`bold`:`normal`).attr(`text-anchor`,e=>e.className===`anchor`?`middle`:`start`).attr(`dominant-baseline`,e=>e.className===`anchor`?`middle`:`auto`).text(e=>e.label),d.annotations.length>0){let e=_.append(`g`).attr(`class`,`wardley-annotations`);if(d.annotations.forEach(t=>{let n=t.coordinates.map(e=>({x:x(e.x),y:S(e.y)}));if(n.length>1)for(let t=0;t{let r=e.append(`g`).attr(`class`,`wardley-annotation`);r.append(`circle`).attr(`cx`,n.x).attr(`cy`,n.y).attr(`r`,10).attr(`fill`,`white`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5),r.append(`text`).attr(`x`,n.x).attr(`y`,n.y).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.number)})}),d.annotationsBox){let t=x(d.annotationsBox.x),n=S(d.annotationsBox.y),r=e.append(`g`).attr(`class`,`wardley-annotations-box`),i=[...d.annotations].filter(e=>e.text).sort((e,t)=>e.number-t.number),a=[];if(i.forEach((e,i)=>{let o=r.append(`text`).attr(`x`,t+10).attr(`y`,n+10+(i+1)*16).attr(`font-size`,11).attr(`fill`,c.axisTextColor).attr(`text-anchor`,`start`).attr(`dominant-baseline`,`middle`).text(`${e.number}. ${e.text}`);a.push(o)}),a.length>0){let e=0,s=0;a.forEach(t=>{let n=t.node(),r=n.getComputedTextLength();e=Math.max(e,r);let i=n.getBBox();s=Math.max(s,i.height)});let l=e+20+105,u=i.length*16+20+s/2,d=o.padding,f=p-o.padding-l,m=o.padding,g=h-o.padding-u;t=Math.max(d,Math.min(t,f)),n=Math.max(m,Math.min(n,g)),a.forEach((e,r)=>{e.attr(`x`,t+10).attr(`y`,n+10+(r+1)*16)}),r.insert(`rect`,`text`).attr(`x`,t).attr(`y`,n).attr(`width`,l).attr(`height`,u).attr(`fill`,`white`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}}}if(d.notes.length>0){let e=_.append(`g`).attr(`class`,`wardley-notes`);d.notes.forEach(t=>{let n=x(t.x),r=S(t.y);e.append(`text`).attr(`x`,n).attr(`y`,r).attr(`text-anchor`,`start`).attr(`font-size`,11).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.text)})}if(d.accelerators.length>0){let e=_.append(`g`).attr(`class`,`wardley-accelerators`);d.accelerators.forEach(t=>{let n=x(t.x),r=S(t.y),i=` + M ${n} ${r-15} + L ${n+60-20} ${r-15} + L ${n+60-20} ${r-15-8} + L ${n+60} ${r} + L ${n+60-20} ${r+15+8} + L ${n+60-20} ${r+15} + L ${n} ${r+15} + Z + `;e.append(`path`).attr(`d`,i).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),e.append(`text`).attr(`x`,n+30).attr(`y`,r+15+15).attr(`text-anchor`,`middle`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.name)})}if(d.deaccelerators.length>0){let e=_.append(`g`).attr(`class`,`wardley-deaccelerators`);d.deaccelerators.forEach(t=>{let n=x(t.x),r=S(t.y),i=` + M ${n+60} ${r-15} + L ${n+20} ${r-15} + L ${n+20} ${r-15-8} + L ${n} ${r} + L ${n+20} ${r+15+8} + L ${n+20} ${r+15} + L ${n+60} ${r+15} + Z + `;e.append(`path`).attr(`d`,i).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),e.append(`text`).attr(`x`,n+30).attr(`y`,r+15+15).attr(`text-anchor`,`middle`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.name)})}},`draw`)},styles:t(({wardley:e}={})=>{let t=n(),r=o(),i=p(t,r.themeVariables),a=p(i.wardley,e);return` + .wardley-background { + fill: ${a.backgroundColor}; + } + .wardley-axes line, .wardley-axes path { + stroke: ${a.axisColor}; + } + .wardley-axis-label { + fill: ${a.axisTextColor}; + } + .wardley-stage-label { + fill: ${a.axisTextColor}; + } + .wardley-grid line { + stroke: ${a.gridColor}; + } + .wardley-node circle { + fill: ${a.componentFill}; + stroke: ${a.componentStroke}; + } + .wardley-node-label { + fill: ${a.componentLabelColor}; + } + .wardley-link { + stroke: ${a.linkStroke}; + } + .wardley-link--dashed { + stroke-dasharray: 4 4; + } + .wardley-link-label { + fill: ${a.axisTextColor}; + } + .wardley-trend line { + stroke: ${a.evolutionStroke}; + } + .wardley-annotation-line { + stroke: ${a.annotationStroke}; + } + .wardley-annotation circle { + fill: ${a.annotationFill}; + stroke: ${a.annotationStroke}; + } + .wardley-annotation text { + fill: ${a.annotationTextColor}; + } + .wardley-annotations-box rect { + fill: ${a.annotationFill}; + stroke: ${a.annotationStroke}; + } + .wardley-annotations-box text { + fill: ${a.annotationTextColor}; + } + .wardley-pipeline-box { + stroke: ${a.componentStroke}; + } + .wardley-notes text { + fill: ${a.axisTextColor}; + } + `},`styles`)};export{G as diagram}; \ No newline at end of file diff --git a/frontend/dist/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js b/frontend/dist/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js new file mode 100644 index 0000000..30a667f --- /dev/null +++ b/frontend/dist/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js @@ -0,0 +1,7 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f,z as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./linear-CZ6dxGrP.js";import{t as h}from"./ordinal-BDEzSJ7C.js";import{t as g}from"./init-C-OQMol4.js";import{i as _}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as v}from"./line-gOgo9JIs.js";import"./chunk-742MDFTN-5mFByRwZ.js";import{t as y}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{y as b}from"./index-DoQkmpth.js";function x(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,a=Array(i);++rf&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};A.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return this.popState(),36;case 3:return this.popState(),36;case 4:return 36;case 5:break;case 6:return 10;case 7:return this.pushState(`acc_title`),19;case 8:return this.popState(),`acc_title_value`;case 9:return this.pushState(`acc_descr`),21;case 10:return this.popState(),`acc_descr_value`;case 11:this.pushState(`acc_descr_multiline`);break;case 12:this.popState();break;case 13:return`acc_descr_multiline_value`;case 14:return 5;case 15:return 5;case 16:return 8;case 17:return this.pushState(`axis_data`),`X_AXIS`;case 18:return this.pushState(`axis_data`),`Y_AXIS`;case 19:return this.pushState(`axis_band_data`),24;case 20:return 33;case 21:return this.pushState(`data`),16;case 22:return this.pushState(`data`),18;case 23:return this.pushState(`data_inner`),24;case 24:return 29;case 25:return this.popState(),26;case 26:this.popState();break;case 27:this.pushState(`string`);break;case 28:this.popState();break;case 29:return`STR`;case 30:return 24;case 31:return 26;case 32:return 44;case 33:return`COLON`;case 34:return 45;case 35:return 28;case 36:return 46;case 37:return 47;case 38:return 49;case 39:return 51;case 40:return 48;case 41:return 42;case 42:return 50;case 43:return 43;case 44:break;case 45:return 37;case 46:return 38}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}}})();function j(){this.yy={}}return t(j,`Parser`),j.prototype=A,A.Parser=j,new j})();C.parser=C;var w=C;function T(e){return e.type===`bar`}t(T,`isBarPlot`);function E(e){return e.type===`band`}t(E,`isBandAxisData`);function D(e){return e.type===`linear`}t(D,`isLinearAxisData`);var O=class{constructor(e){this.parentGroup=e}static{t(this,`TextDimensionCalculatorWithFont`)}getMaxDimension(e,t){if(!this.parentGroup)return{width:e.reduce((e,t)=>Math.max(t.length,e),0)*t,height:t};let n={width:0,height:0},r=this.parentGroup.append(`g`).attr(`visibility`,`hidden`).attr(`font-size`,t);for(let i of e){let e=y(r,1,i),a=e?e.width:i.length*t,o=e?e.height:t;n.width=Math.max(n.width,a),n.height=Math.max(n.height,o)}return r.remove(),n}},k=.7,A=.2,j=class{constructor(e,t,n,r){this.axisConfig=e,this.title=t,this.textDimensionCalculator=n,this.axisThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition=`left`,this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.normalizedLabelRotationInRad=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition=`left`,this.normalizedLabelRotationInRad=this.axisConfig.labelRotation>=-90&&this.axisConfig.labelRotation<=90?this.axisConfig.labelRotation*Math.PI/180:0}static{t(this,`BaseAxis`)}setRange(e){this.range=e,this.axisPosition===`left`||this.axisPosition===`right`?this.boundingRect.height=e[1]-e[0]:this.boundingRect.width=e[1]-e[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(e){this.axisPosition=e,this.setRange(this.range)}getTickDistance(){let e=this.getRange();return Math.abs(e[0]-e[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(e=>e.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){k*this.getTickDistance()>this.outerPadding*2&&(this.outerPadding=Math.floor(k*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(e){let t=e.height;if(this.axisConfig.showAxisLine&&t>this.axisConfig.axisLineWidth&&(t-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let n=this.getLabelDimension(),r=A*e.width;this.outerPadding=Math.min(n.width/2,r);let i=n.height;this.axisPosition===`bottom`&&this.normalizedLabelRotationInRad!==0&&(i=Math.max(i,Math.abs(Math.sin(this.normalizedLabelRotationInRad)*n.width)+Math.abs(Math.cos(this.normalizedLabelRotationInRad)*n.height))),i+=this.axisConfig.labelPadding*2,this.labelTextHeight=n.height,i<=t&&(t-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&t>=this.axisConfig.tickLength&&(this.showTick=!0,t-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let e=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=e.height+this.axisConfig.titlePadding*2;this.titleTextHeight=e.height,n<=t&&(t-=n,this.showTitle=!0)}this.boundingRect.width=e.width,this.boundingRect.height=e.height-t}calculateSpaceIfDrawnVertical(e){let t=e.width;if(this.axisConfig.showAxisLine&&t>this.axisConfig.axisLineWidth&&(t-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let n=this.getLabelDimension(),r=A*e.height;this.outerPadding=Math.min(n.height/2,r);let i=n.width+this.axisConfig.labelPadding*2;i<=t&&(t-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&t>=this.axisConfig.tickLength&&(this.showTick=!0,t-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let e=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=e.height+this.axisConfig.titlePadding*2;this.titleTextHeight=e.height,n<=t&&(t-=n,this.showTitle=!0)}this.boundingRect.width=e.width-t,this.boundingRect.height=e.height}calculateSpace(e){return this.axisPosition===`left`||this.axisPosition===`right`?this.calculateSpaceIfDrawnVertical(e):this.calculateSpaceIfDrawnHorizontally(e),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateOffsetByRotation(e){let t=this.normalizedLabelRotationInRad;return t===0?0:Math.sin(t)*this.getLabelDimension()[e]/2}getDrawableElementsForLeftAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`left-axis`,`axisl-line`],data:[{path:`M ${t},${this.boundingRect.y} L ${t},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`left-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(e),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:`middle`,horizontalPos:`right`}))}),this.showTick){let t=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);e.push({type:`path`,groupTexts:[`left-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${t},${this.getScaleValue(e)} L ${t-this.axisConfig.tickLength},${this.getScaleValue(e)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`left-axis`,`title`],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElementsForBottomAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.y+this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`bottom-axis`,`axis-line`],data:[{path:`M ${this.boundingRect.x},${t} L ${this.boundingRect.x+this.boundingRect.width},${t}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`bottom-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e)+this.calculateOffsetByRotation(`height`),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0)+Math.abs(this.calculateOffsetByRotation(`width`)),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:this.normalizedLabelRotationInRad*180/Math.PI,verticalPos:`top`,horizontalPos:`center`}))}),this.showTick){let t=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);e.push({type:`path`,groupTexts:[`bottom-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${this.getScaleValue(e)},${t} L ${this.getScaleValue(e)},${t+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`bottom-axis`,`title`],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElementsForTopAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`top-axis`,`axis-line`],data:[{path:`M ${this.boundingRect.x},${t} L ${this.boundingRect.x+this.boundingRect.width},${t}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`top-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+this.axisConfig.titlePadding*2:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}))}),this.showTick){let t=this.boundingRect.y;e.push({type:`path`,groupTexts:[`top-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${this.getScaleValue(e)},${t+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(e)},${t+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`top-axis`,`title`],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElements(){if(this.axisPosition===`left`)return this.getDrawableElementsForLeftAxis();if(this.axisPosition===`right`)throw Error(`Drawing of right axis is not implemented`);return this.axisPosition===`bottom`?this.getDrawableElementsForBottomAxis():this.axisPosition===`top`?this.getDrawableElementsForTopAxis():[]}},M=class extends j{static{t(this,`BandAxis`)}constructor(e,t,n,r,i){super(e,r,i,t),this.categories=n,this.scale=S().domain(this.categories).range(this.getRange())}setRange(e){super.setRange(e)}recalculateScale(){this.scale=S().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),e.trace(`BandAxis axis final categories, range: `,this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(e){return this.scale(e)??this.getRange()[0]}},ee=class extends j{static{t(this,`LinearAxis`)}constructor(e,t,n,r,i){super(e,r,i,t),this.domain=n,this.scale=m().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){let e=[...this.domain];this.axisPosition===`left`&&e.reverse(),this.scale=m().domain(e).range(this.getRange())}getScaleValue(e){return this.scale(e)}};function N(e,t,n,r){let i=new O(r);return E(e)?new M(t,n,e.categories,e.title,i):new ee(t,n,[e.min,e.max],e.title,i)}t(N,`getAxis`);var te=class{constructor(e,t,n,r){this.textDimensionCalculator=e,this.chartConfig=t,this.chartData=n,this.chartThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{t(this,`ChartTitle`)}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){let t=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),n=Math.max(t.width,e.width),r=t.height+2*this.chartConfig.titlePadding;return t.width<=n&&t.height<=r&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=n,this.boundingRect.height=r,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){let e=[];return this.showChartTitle&&e.push({groupTexts:[`chart-title`],type:`text`,data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:`middle`,horizontalPos:`center`,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),e}};function P(e,t,n,r){return new te(new O(r),e,t,n)}t(P,`getChartTitleComponent`);var ne=.75,re=.5,ie=.35;function F(e){return{fontSize:e,markerSize:e*ne,markerSpacing:e*ie,itemSpacing:e*re}}t(F,`getLegendLayout`);var ae=class{constructor(e,t,n,r){this.textDimensionCalculator=e,this.chartConfig=t,this.chartData=n,this.chartThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.visiblePlots=[]}static{t(this,`ChartLegend`)}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){if(this.visiblePlots=this.chartConfig.showLegend?this.chartData.plots.filter(e=>e.title):[],this.visiblePlots.length===0)return this.boundingRect.width=0,this.boundingRect.height=0,{width:0,height:0};let{fontSize:t,markerSize:n,markerSpacing:r,itemSpacing:i}=F(this.chartConfig.legendFontSize),a=this.textDimensionCalculator.getMaxDimension(this.visiblePlots.map(e=>e.title),t),o=this.chartConfig.legendPadding*2+n+r+a.width,s=this.chartConfig.legendPadding*2+this.visiblePlots.length*t+(this.visiblePlots.length-1)*i;return o<=e.width&&s<=e.height?(this.boundingRect.width=o,this.boundingRect.height=s):(this.visiblePlots=[],this.boundingRect.width=0,this.boundingRect.height=0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(this.visiblePlots.length===0)return[];let{fontSize:e,markerSize:t,markerSpacing:n,itemSpacing:r}=F(this.chartConfig.legendFontSize),i=e+r,a=this.boundingRect.x+this.chartConfig.legendPadding,o=this.boundingRect.y+this.chartConfig.legendPadding,s=[],c=[];for(let[e,n]of this.visiblePlots.entries())if(T(n))s.push({x:a,y:o+e*i,width:t,height:t,fill:n.fill,strokeFill:n.fill,strokeWidth:0});else{let r=o+e*i+t/2;c.push({path:`M ${a},${r} L ${a+t},${r}`,strokeFill:n.strokeFill,strokeWidth:n.strokeWidth})}return[{groupTexts:[`legend`,`markers`],type:`rect`,data:s},{groupTexts:[`legend`,`markers`],type:`path`,data:c},{groupTexts:[`legend`,`label`],type:`text`,data:this.visiblePlots.map((r,s)=>({text:r.title,x:a+t+n,y:o+s*i+t/2,fill:this.chartThemeConfig.legendTextColor,fontSize:e,rotation:0,verticalPos:`middle`,horizontalPos:`left`}))}]}};function I(e,t,n,r){return new ae(new O(r),e,t,n)}t(I,`getChartLegendComponent`);var oe=class{constructor(e,t,n,r,i){this.plotData=e,this.xAxis=t,this.yAxis=n,this.orientation=r,this.plotIndex=i}static{t(this,`LinePlot`)}getDrawableElement(){let e=this.plotData.data.map(e=>[this.xAxis.getScaleValue(e[0]),this.yAxis.getScaleValue(e[1])]),t;if(t=this.orientation===`horizontal`?v().y(e=>e[0]).x(e=>e[1])(e):v().x(e=>e[0]).y(e=>e[1])(e),!t)return[];let n=[{groupTexts:[`plot`,`line-plot-${this.plotIndex}`],type:`path`,data:[{path:t,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}];if(this.plotData.pointLabels&&this.plotData.pointLabels.length>0){let t=[];for(let[n,[r,i]]of e.entries()){let e=this.plotData.pointLabels[n];e&&(this.orientation===`horizontal`?t.push({x:i+10,y:r,text:e,fill:this.plotData.strokeFill,verticalPos:`middle`,horizontalPos:`left`,fontSize:12,rotation:0}):t.push({x:r,y:i-10,text:e,fill:this.plotData.strokeFill,verticalPos:`middle`,horizontalPos:`center`,fontSize:12,rotation:0}))}t.length>0&&n.push({groupTexts:[`plot`,`line-plot-${this.plotIndex}`,`labels`],type:`text`,data:t})}return n}},se=class{constructor(e,t,n,r,i,a){this.barData=e,this.boundingRect=t,this.xAxis=n,this.yAxis=r,this.orientation=i,this.plotIndex=a}static{t(this,`BarPlot`)}getDrawableElement(){let e=this.barData.data.map(e=>[this.xAxis.getScaleValue(e[0]),this.yAxis.getScaleValue(e[1])]),t=Math.min(this.xAxis.getAxisOuterPadding()*2,this.xAxis.getTickDistance())*.95,n=t/2;return this.orientation===`horizontal`?[{groupTexts:[`plot`,`bar-plot-${this.plotIndex}`],type:`rect`,data:e.map(e=>({x:this.boundingRect.x,y:e[0]-n,height:t,width:e[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:[`plot`,`bar-plot-${this.plotIndex}`],type:`rect`,data:e.map(e=>({x:e[0]-n,y:e[1],width:t,height:this.boundingRect.y+this.boundingRect.height-e[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},ce=class{constructor(e,t,n){this.chartConfig=e,this.chartData=t,this.chartThemeConfig=n,this.boundingRect={x:0,y:0,width:0,height:0}}static{t(this,`BasePlot`)}setAxes(e,t){this.xAxis=e,this.yAxis=t}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){return this.boundingRect.width=e.width,this.boundingRect.height=e.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error(`Axes must be passed to render Plots`);let e=[];for(let[t,n]of this.chartData.plots.entries())switch(n.type){case`line`:{let r=new oe(n,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,t);e.push(...r.getDrawableElement())}break;case`bar`:{let r=new se(n,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,t);e.push(...r.getDrawableElement())}}return e}};function le(e,t,n){return new ce(e,t,n)}t(le,`getPlotComponent`);var ue=class{constructor(e,t,n,r){this.chartConfig=e,this.chartData=t,this.componentStore={title:P(e,t,n,r),plot:le(e,t,n),legend:I(e,t,n,r),xAxis:N(t.xAxis,e.xAxis,{titleColor:n.xAxisTitleColor,labelColor:n.xAxisLabelColor,tickColor:n.xAxisTickColor,axisLineColor:n.xAxisLineColor},r),yAxis:N(t.yAxis,e.yAxis,{titleColor:n.yAxisTitleColor,labelColor:n.yAxisLabelColor,tickColor:n.yAxisTickColor,axisLineColor:n.yAxisLineColor},r)}}static{t(this,`Orchestrator`)}calculateVerticalSpace(){let e=this.chartConfig.width,t=this.chartConfig.height,n=0,r=0,i={width:0,height:0},a=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),o=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),s=this.componentStore.plot.calculateSpace({width:a,height:o});e-=s.width,t-=s.height,s=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:t}),r=s.height,t-=s.height,this.componentStore.xAxis.setAxisPosition(`bottom`),s=this.componentStore.xAxis.calculateSpace({width:e,height:t}),t-=s.height,this.componentStore.yAxis.setAxisPosition(`left`),s=this.componentStore.yAxis.calculateSpace({width:e,height:t}),n=s.width,e-=s.width,i=this.componentStore.legend.calculateSpace({width:e,height:o}),e-=i.width,e>0&&(a+=e,e=0),t>0&&(o+=t,t=0),this.componentStore.plot.calculateSpace({width:a,height:o}),this.componentStore.plot.setBoundingBoxXY({x:n,y:r}),this.componentStore.legend.setBoundingBoxXY({x:n+a,y:r+Math.max((o-i.height)/2,0)}),this.componentStore.xAxis.setRange([n,n+a]),this.componentStore.xAxis.setBoundingBoxXY({x:n,y:r+o}),this.componentStore.yAxis.setRange([r,r+o]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:r}),this.chartData.plots.some(e=>T(e))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let e=this.chartConfig.width,t=this.chartConfig.height,n=0,r=0,i=0,a={width:0,height:0},o=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),s=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),c=this.componentStore.plot.calculateSpace({width:o,height:s});e-=c.width,t-=c.height,c=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:t}),n=c.height,t-=c.height,this.componentStore.xAxis.setAxisPosition(`left`),c=this.componentStore.xAxis.calculateSpace({width:e,height:t}),e-=c.width,r=c.width,this.componentStore.yAxis.setAxisPosition(`top`),c=this.componentStore.yAxis.calculateSpace({width:e,height:t}),t-=c.height,i=n+c.height,a=this.componentStore.legend.calculateSpace({width:e,height:s}),e-=a.width,e>0&&(o+=e,e=0),t>0&&(s+=t,t=0),this.componentStore.plot.calculateSpace({width:o,height:s}),this.componentStore.plot.setBoundingBoxXY({x:r,y:i}),this.componentStore.legend.setBoundingBoxXY({x:r+o,y:i+Math.max((s-a.height)/2,0)}),this.componentStore.yAxis.setRange([r,r+o]),this.componentStore.yAxis.setBoundingBoxXY({x:r,y:n}),this.componentStore.xAxis.setRange([i,i+s]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:i}),this.chartData.plots.some(e=>T(e))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){this.chartConfig.chartOrientation===`horizontal`?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();let e=[];this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis);for(let t of Object.values(this.componentStore))e.push(...t.getDrawableElements());return e}},de=class{static{t(this,`XYChartBuilder`)}static build(e,t,n,r){return new ue(e,t,n,r).getDrawableElement()}},L=0,R,z=K(),B=G(),V=q(),H=B.plotColorPalette.split(`,`).map(e=>e.trim()),U=!1,W=!1;function G(){let e=n(),t=o();return _(e.xyChart,t.themeVariables.xyChart)}t(G,`getChartDefaultThemeConfig`);function K(){let e=o();return _(c.xyChart,e.xyChart)}t(K,`getChartDefaultConfig`);function q(){return{yAxis:{type:`linear`,title:``,min:1/0,max:-1/0},xAxis:{type:`band`,title:``,categories:[]},title:``,plots:[]}}t(q,`getChartDefaultData`);function J(e){let t=o();return p(e.trim(),t)}t(J,`textSanitizer`);function Y(e){R=e}t(Y,`setTmpSVGG`);function fe(e){e===`horizontal`?z.chartOrientation=`horizontal`:z.chartOrientation=`vertical`}t(fe,`setOrientation`);function pe(e){V.xAxis.title=J(e.text)}t(pe,`setXAxisTitle`);function X(e,t){V.xAxis={type:`linear`,title:V.xAxis.title,min:e,max:t},U=!0}t(X,`setXAxisRangeData`);function me(e){V.xAxis={type:`band`,title:V.xAxis.title,categories:e.map(e=>J(e.text))},U=!0}t(me,`setXAxisBand`);function he(e){V.yAxis.title=J(e.text)}t(he,`setYAxisTitle`);function Z(e,t){V.yAxis={type:`linear`,title:V.yAxis.title,min:e,max:t},W=!0}t(Z,`setYAxisRangeData`);function ge(e){let t=Math.min(...e),n=Math.max(...e),r=D(V.yAxis)?V.yAxis.min:1/0,i=D(V.yAxis)?V.yAxis.max:-1/0;V.yAxis={type:`linear`,title:V.yAxis.title,min:Math.min(r,t),max:Math.max(i,n)}}t(ge,`setYAxisRangeFromPlotData`);function Q(e){let t=[];if(e.length===0)return t;if(!U){let t=D(V.xAxis)?V.xAxis.min:1/0,n=D(V.xAxis)?V.xAxis.max:-1/0;X(Math.min(t,1),Math.max(n,e.length))}if(E(V.xAxis)&&e.length>V.xAxis.categories.length&&(e=e.slice(0,V.xAxis.categories.length)),W||ge(e),E(V.xAxis)&&(t=V.xAxis.categories.map((t,n)=>[t,e[n]])),D(V.xAxis)){let n=V.xAxis.min,r=V.xAxis.max;if(e.length===1)t=[[`${n}`,e[0]]];else{let i=(r-n)/(e.length-1);t=e.map((e,t)=>[`${n+t*i}`,e])}}return t}t(Q,`transformDataWithoutCategory`);function $(e){return H[e===0?0:e%H.length]}t($,`getPlotColorFromPalette`);function _e(e,t){let n=t.map(e=>e.value),r=t.map(e=>e.label?J(e.label):``),i=Q(n),a=r.some(e=>e!==``);V.plots.push({type:`line`,title:J(e.text),strokeFill:$(L),strokeWidth:2,data:i,...a?{pointLabels:r}:{}}),L++}t(_e,`setLineData`);function ve(e,t){let n=Q(t.map(e=>e.value));V.plots.push({type:`bar`,title:J(e.text),fill:$(L),data:n}),L++}t(ve,`setBarData`);function ye(){if(V.plots.length===0)throw Error(`No Plot to render, please provide a plot with some data`);return V.title=d(),de.build(z,V,B,R)}t(ye,`getDrawableElem`);function be(){return B}t(be,`getChartThemeConfig`);function xe(){return z}t(xe,`getChartConfig`);function Se(){return V}t(Se,`getXYChartData`);var Ce={parser:w,db:{getDrawableElem:ye,clear:t(function(){a(),L=0,z=K(),V=q(),B=G(),H=B.plotColorPalette.split(`,`).map(e=>e.trim()),U=!1,W=!1},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r,setOrientation:fe,setXAxisTitle:pe,setXAxisRangeData:X,setXAxisBand:me,setYAxisTitle:he,setYAxisRangeData:Z,setLineData:_e,setBarData:ve,setTmpSVGG:Y,getChartThemeConfig:be,getChartConfig:xe,getXYChartData:Se},renderer:{draw:t((n,r,i,a)=>{let o=a.db,c=o.getChartThemeConfig(),l=o.getChartConfig(),u=o.getXYChartData().plots[0].data.map(e=>e[1]);function d(e){return e===`top`?`text-before-edge`:`middle`}t(d,`getDominantBaseLine`);function f(e){return e===`left`?`start`:e===`right`?`end`:`middle`}t(f,`getTextAnchor`);function p(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}t(p,`getTextTransformation`),e.debug(`Rendering xychart chart +`+n);let m=b(r),h=m.append(`g`).attr(`class`,`main`),g=h.append(`rect`).attr(`width`,l.width).attr(`height`,l.height).attr(`class`,`background`);s(m,l.height,l.width,!0),m.attr(`viewBox`,`0 0 ${l.width} ${l.height}`),g.attr(`fill`,c.backgroundColor),o.setTmpSVGG(m.append(`g`).attr(`class`,`mermaid-tmp-group`));let _=o.getDrawableElem(),v={};function y(e){let t=h,n=``;for(let[r]of e.entries()){let i=h;r>0&&v[n]&&(i=v[n]),n+=e[r],t=v[n],t||=v[n]=i.append(`g`).attr(`class`,e[r])}return t}t(y,`getGroup`);for(let e of _){if(e.data.length===0)continue;let n=y(e.groupTexts);switch(e.type){case`rect`:if(n.selectAll(`rect`).data(e.data).enter().append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeFill).attr(`stroke-width`,e=>e.strokeWidth),l.showDataLabel){let r=l.showDataLabelOutsideBar;if(l.chartOrientation===`horizontal`){let i=function(e,t){let{data:n,label:r}=e;return t*r.length*a<=n.width-o};t(i,`fitsHorizontally`);let a=.7,o=10,s=e.data.map((e,t)=>({data:e,label:u[t].toString()})).filter(e=>e.data.width>0&&e.data.height>0),l=s.map(e=>{let{data:t}=e,n=t.height*.7;for(;!i(e,n)&&n>0;)--n;return n}),d=Math.floor(Math.min(...l)),f=t(e=>r?e.data.x+e.data.width+10:e.data.x+e.data.width-10,`determineLabelXPosition`);n.selectAll(`text`).data(s).enter().append(`text`).attr(`x`,f).attr(`y`,e=>e.data.y+e.data.height/2).attr(`text-anchor`,r?`start`:`end`).attr(`dominant-baseline`,`middle`).attr(`fill`,c.dataLabelColor).attr(`font-size`,`${d}px`).text(e=>e.label)}else{let i=function(e,t,n){let{data:r,label:i}=e,a=t*i.length*.7,o=r.x+r.width/2,s=o-a/2,c=o+a/2,l=s>=r.x&&c<=r.x+r.width,u=r.y+n+t<=r.y+r.height;return l&&u};t(i,`fitsInBar`);let a=e.data.map((e,t)=>({data:e,label:u[t].toString()})).filter(e=>e.data.width>0&&e.data.height>0),o=a.map(e=>{let{data:t,label:n}=e,r=t.width/(n.length*.7);for(;!i(e,r,10)&&r>0;)--r;return r}),s=Math.floor(Math.min(...o)),l=t(e=>r?e.data.y-10:e.data.y+10,`determineLabelYPosition`);n.selectAll(`text`).data(a).enter().append(`text`).attr(`x`,e=>e.data.x+e.data.width/2).attr(`y`,l).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,r?`auto`:`hanging`).attr(`fill`,c.dataLabelColor).attr(`font-size`,`${s}px`).text(e=>e.label)}}break;case`text`:n.selectAll(`text`).data(e.data).enter().append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>d(e.verticalPos)).attr(`text-anchor`,e=>f(e.horizontalPos)).attr(`transform`,e=>p(e)).text(e=>e.text);break;case`path`:n.selectAll(`path`).data(e.data).enter().append(`path`).attr(`d`,e=>e.path).attr(`fill`,e=>e.fill?e.fill:`none`).attr(`stroke`,e=>e.strokeFill).attr(`stroke-width`,e=>e.strokeWidth)}}},`draw`)}};export{Ce as diagram}; \ No newline at end of file diff --git a/frontend/dist/index.html b/frontend/dist/index.html index 98ac8a0..fa04683 100644 --- a/frontend/dist/index.html +++ b/frontend/dist/index.html @@ -17,7 +17,7 @@ } catch (e) {} })(); - + diff --git a/frontend/package-lock.json b/frontend/package-lock.json index d8258e3..33a6075 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -1,12 +1,12 @@ { "name": "contextcortex-frontend", - "version": "2.17.0", + "version": "2.17.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "contextcortex-frontend", - "version": "2.17.0", + "version": "2.17.1", "dependencies": { "@tanstack/react-virtual": "^3.14.13", "@types/marked": "^5.0.2", diff --git a/frontend/package.json b/frontend/package.json index cfb77e2..614aad0 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,7 +1,7 @@ { "name": "contextcortex-frontend", "private": true, - "version": "2.17.0", + "version": "2.17.1", "type": "module", "scripts": { "dev": "vite --configLoader native", diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index bc9d81b..f55268d 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -48,7 +48,7 @@ function App() {

    ContextCortex

    - v2.17.0 + v2.17.1
    diff --git a/frontend/src/tests/App.test.tsx b/frontend/src/tests/App.test.tsx index b25407f..78575c9 100644 --- a/frontend/src/tests/App.test.tsx +++ b/frontend/src/tests/App.test.tsx @@ -91,7 +91,7 @@ describe('App Component', () => { ); expect(screen.getByText('ContextCortex')).toBeInTheDocument(); - expect(screen.getByText('v2.17.0')).toBeInTheDocument(); + expect(screen.getByText('v2.17.1')).toBeInTheDocument(); await waitFor(() => { diff --git a/main.py b/main.py index d97152d..b54ca08 100644 --- a/main.py +++ b/main.py @@ -12,7 +12,7 @@ import threading from fastapi import FastAPI -from fastapi.responses import JSONResponse, RedirectResponse +from fastapi.responses import FileResponse, JSONResponse, RedirectResponse from fastapi.staticfiles import StaticFiles import uvicorn @@ -132,6 +132,8 @@ async def __call__(self, scope, receive, send): or path == "/health" or path == "/healthz" or path == "/" + or path == "/favicon.svg" + or path == "/favicon.ico" or path.startswith("/assets") or (path.startswith("/admin") and not path.startswith("/admin/api")) or path.startswith("/api/webhooks") @@ -193,7 +195,7 @@ async def __call__(self, scope, receive, send): }) -app = FastAPI(title="ContextCortex", version="2.17.0", lifespan=lifespan) +app = FastAPI(title="ContextCortex", version="2.17.1", lifespan=lifespan) app.add_middleware(AuthMiddleware) # Include API routes @@ -205,12 +207,40 @@ async def root_redirect(): return RedirectResponse(url="/admin/") -www_dir = "frontend/dist" if os.path.exists("frontend/dist/index.html") else "www" -assets_dir = os.path.join(www_dir, "assets") if os.path.exists(os.path.join(www_dir, "assets")) else "www/assets" +if os.path.exists("frontend/dist/index.html") and os.path.exists("frontend/dist/assets"): + www_dir = "frontend/dist" +elif os.path.exists("www/index.html") and os.path.exists("www/assets"): + www_dir = "www" +elif os.path.exists("frontend/dist/index.html"): + www_dir = "frontend/dist" +else: + www_dir = "www" + +assets_dir = os.path.join(www_dir, "assets") app.mount("/admin", StaticFiles(directory=www_dir, html=True), name="admin") app.mount("/assets", StaticFiles(directory=assets_dir), name="assets") + +@app.get("/favicon.svg") +async def favicon_svg(): + svg_path = os.path.join(www_dir, "favicon.svg") + if os.path.exists(svg_path): + return FileResponse(svg_path, media_type="image/svg+xml") + return JSONResponse(status_code=404, content={"detail": "Favicon not found"}) + + +@app.get("/favicon.ico") +async def favicon_ico(): + ico_path = os.path.join(www_dir, "favicon.ico") + if os.path.exists(ico_path): + return FileResponse(ico_path) + svg_path = os.path.join(www_dir, "favicon.svg") + if os.path.exists(svg_path): + return FileResponse(svg_path, media_type="image/svg+xml") + return JSONResponse(status_code=404, content={"detail": "Favicon not found"}) + + # Mount FastMCP SSE and Streamable HTTP endpoints for route in mcp_server.sse_app().routes: app.routes.append(route) diff --git a/package.json b/package.json index 94818e0..d8e7a10 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "contextcortex", - "version": "2.17.0", + "version": "2.17.1", "description": "High-performance Model Context Protocol (MCP) server for syntax-aware code RAG and codebase navigation", "type": "module", "scripts": { diff --git a/scripts/generate_requirements.py b/scripts/generate_requirements.py index b993c4a..764bb6e 100644 --- a/scripts/generate_requirements.py +++ b/scripts/generate_requirements.py @@ -110,7 +110,7 @@ def generate_markdown() -> str: total_all_tests = total_py_tests + total_fe_tests + total_e2e_tests lines = [ - "# Software Requirements Specification: ContextCortex (v2.17.0)", + "# Software Requirements Specification: ContextCortex (v2.17.1)", "", "> **Note:** This document is automatically generated and verified against the live test suite by `scripts/generate_requirements.py` and `tests/backend/test_requirements_sync.py`.", "", diff --git a/tests/backend/test_health_check_status.py b/tests/backend/test_health_check_status.py index 8105f61..95beee6 100644 --- a/tests/backend/test_health_check_status.py +++ b/tests/backend/test_health_check_status.py @@ -82,3 +82,21 @@ def test_api_stats_reports_healthy_with_real_embedded_store(tmp_path): assert data["vector_db_status"] == "Healthy" assert data["vector_store_provider"] == "qdrant" assert data["vector_store_mode"] == "embedded" + + +def test_main_app_favicon_and_root_redirect(): + """Verify root app redirect, favicon routes, and static asset handling.""" + from main import app as main_app + main_client = TestClient(main_app) + + res_root = main_client.get("/", follow_redirects=False) + assert res_root.status_code == 307 + assert res_root.headers["location"] == "/admin/" + + res_favicon = main_client.get("/favicon.svg") + assert res_favicon.status_code == 200 + assert "image/svg+xml" in res_favicon.headers.get("content-type", "") + + res_ico = main_client.get("/favicon.ico") + assert res_ico.status_code == 200 + diff --git a/tests/test_database_engine.py b/tests/test_database_engine.py index 71b34da..7a8ec69 100644 --- a/tests/test_database_engine.py +++ b/tests/test_database_engine.py @@ -72,7 +72,7 @@ def test_sqlite_engine_initialization_and_crud(tmp_path): with get_connection(engine) as conn: conn.execute( - TABLES["system_metadata"].insert().values(key="version", value="2.17.0") + TABLES["system_metadata"].insert().values(key="version", value="2.17.1") ) conn.commit() @@ -81,7 +81,7 @@ def test_sqlite_engine_initialization_and_crud(tmp_path): ).mappings().fetchone() assert row is not None - assert row["value"] == "2.17.0" + assert row["value"] == "2.17.1" def test_sqlite_engine_seeds_default_prompts_and_configs(tmp_path): diff --git a/www/assets/_basePickBy-Cj4iqGU4.js b/www/assets/_basePickBy-Cj4iqGU4.js new file mode 100644 index 0000000..f0d82ee --- /dev/null +++ b/www/assets/_basePickBy-Cj4iqGU4.js @@ -0,0 +1 @@ +import{$ as e,A as t,C as n,D as r,E as i,G as a,H as o,I as s,K as c,M as l,N as u,P as d,R as f,S as p,T as m,U as ee,V as h,X as g,Y as _,ct as v,dt as y,et as te,f as ne,ft as re,h as b,j as ie,k as ae,lt as oe,mt as se,nt as x,pt as ce,q as le,st as S,ut as ue,v as de,w as fe,z as pe}from"./_baseUniq-DR4vVjyC.js";var me=/\s/;function he(e){for(var t=e.length;t--&&me.test(e.charAt(t)););return t}var ge=/^\s+/;function _e(e){return e&&e.slice(0,he(e)+1).replace(ge,``)}var C=NaN,ve=/^[-+]0x[0-9a-f]+$/i,ye=/^0b[01]+$/i,be=/^0o[0-7]+$/i,xe=parseInt;function Se(e){if(typeof e==`number`)return e;if(ue(e))return C;if(S(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=S(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=_e(e);var n=ye.test(e);return n||be.test(e)?xe(e.slice(2),n?2:8):ve.test(e)?C:+e}var w=1/0,Ce=17976931348623157e292;function T(e){return e?(e=Se(e),e===w||e===-w?(e<0?-1:1)*Ce:e===e?e:0):e===0?e:0}function E(e){var t=T(e),n=t%1;return t===t?n?t-n:t:0}var D=Object.create,we=function(){function e(){}return function(t){if(!S(t))return{};if(D)return D(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function O(e,t){var n=-1,r=e.length;for(t||=Array(r);++n1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&M(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r2?t[2]:void 0;for(i&&M(t[0],t[1],i)&&(r=1);++n-1?i[a?t[o]:o]:void 0}}var Wt=Math.max;function Gt(t,n,r){var i=t==null?0:t.length;if(!i)return-1;var a=r==null?0:E(r);return a<0&&(a=Wt(i+a,0)),e(t,b(n,3),a)}var Kt=Ut(Gt);function qt(e,t){var n=-1,r=c(e)?Array(e.length):[];return ne(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function Jt(e,t){return(v(e)?oe:qt)(e,b(t,3))}var Yt=Object.prototype.hasOwnProperty;function Xt(e,t){return e!=null&&Yt.call(e,t)}function Zt(e,t){return e!=null&&de(e,t,Xt)}var Qt=`[object String]`;function $t(e){return typeof e==`string`||!v(e)&&y(e)&&re(e)==Qt}function en(e,t,n,r){if(!S(e))return e;t=d(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i0){if(++t>=we)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Oe(e){return function(){return e}}var T=function(){try{var e=C(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),ke=De(T?function(e,t){return T(e,`toString`,{configurable:!0,enumerable:!1,value:Oe(t),writable:!0})}:x);function Ae(e,t){for(var n=-1,r=e==null?0:e.length;++n-1}var Ie=9007199254740991,Le=/^(?:0|[1-9]\d*)$/;function E(e,t){var n=typeof e;return t??=Ie,!!t&&(n==`number`||n!=`symbol`&&Le.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=Ve}function k(e){return e!=null&&O(e.length)&&!ce(e)}var He=Object.prototype;function A(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||He)}function Ue(e,t){for(var n=-1,r=Array(e);++n-1}function Zt(e,t){var n=this.__data__,r=B(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function V(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t0&&n(s)?t>1?yn(s,t-1,n,r,i):gn(i,s):r||(i[i.length]=s)}return i}function bn(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++is))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&er?new Z:void 0;for(a.set(e,t),a.set(t,e);++d=fi){var l=t?null:di(e);if(l)return rr(l);o=!1,i=Qn,c=new Z}else c=t?[]:s;outer:for(;++r{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformAlternation`),u=t(e=>{let t=e.elements.map(f);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformConcatenation`),d=t(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{min:t?parseInt(t,10):0,max:n?parseInt(n,10):1/0}}let t=parseInt(e,10);return{min:t,max:t}},`parseRepeat`),f=t(e=>{let t=p(e.primary);if(!e.repeat)return t;let{min:n,max:r}=d(e.repeat);return n===0&&r===1?{type:`optional`,element:t}:{type:`repetition`,element:t,min:n,max:r}},`transformElement`),p=t(e=>{switch(e.$type){case`AbnfStringLiteral`:return{type:`terminal`,value:e.value};case`AbnfNumVal`:return{type:`terminal`,value:e.value};case`AbnfRuleName`:return{type:`nonterminal`,name:e.name};case`AbnfGroup`:return l(e.element);case`AbnfOptionalGroup`:return{type:`optional`,element:l(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},`transformPrimary`),m=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:t(t=>{o.clear(),e.debug(`[ABNF Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[ABNF Parser] Parsed rules:`,i.rules.length),h(i),e.debug(`[ABNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram}; \ No newline at end of file diff --git a/www/assets/arc-BJA87daU.js b/www/assets/arc-BJA87daU.js new file mode 100644 index 0000000..7ed8f9f --- /dev/null +++ b/www/assets/arc-BJA87daU.js @@ -0,0 +1 @@ +import{n as e,t}from"./path-fybaL0A-.js";import{a as n,c as r,d as i,f as a,i as o,l as s,m as c,n as l,o as u,p as d,r as f,u as p}from"./dist-Bfr8PhAA.js";function m(e){return e.innerRadius}function h(e){return e.outerRadius}function g(e){return e.startAngle}function _(e){return e.endAngle}function v(e){return e&&e.padAngle}function y(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<1e-12))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function b(e,t,n,r,i,a,o){var c=e-n,l=t-r,u=(o?a:-a)/d(c*c+l*l),f=u*l,p=-u*c,m=e+f,h=t+p,g=n+f,_=r+p,v=(m+g)/2,y=(h+_)/2,b=g-m,x=_-h,S=b*b+x*x,C=i-a,w=m*_-g*h,T=(x<0?-1:1)*d(s(0,C*C*S-w*w)),E=(w*x-b*T)/S,D=(-w*b-x*T)/S,O=(w*x+b*T)/S,k=(-w*b+x*T)/S,A=E-v,j=D-y,M=O-v,N=k-y;return A*A+j*j>M*M+N*N&&(E=O,D=k),{cx:E,cy:D,x01:-f,y01:-p,x11:E*(i/C-1),y11:D*(i/C-1)}}function x(){var s=m,x=h,S=e(0),C=null,w=g,T=_,E=v,D=null,O=t(k);function k(){var e,t,m=+s.apply(this,arguments),h=+x.apply(this,arguments),g=w.apply(this,arguments)-r,_=T.apply(this,arguments)-r,v=l(_-g),k=_>g;if(D||=e=O(),h1e-12))D.moveTo(0,0);else if(v>c-1e-12)D.moveTo(h*u(g),h*a(g)),D.arc(0,0,h,g,_,!k),m>1e-12&&(D.moveTo(m*u(_),m*a(_)),D.arc(0,0,m,_,g,k));else{var A=g,j=_,M=g,N=_,P=v,F=v,I=E.apply(this,arguments)/2,L=I>1e-12&&(C?+C.apply(this,arguments):d(m*m+h*h)),R=p(l(h-m)/2,+S.apply(this,arguments)),z=R,B=R,V,H;if(L>1e-12){var U=o(L/m*a(I)),W=o(L/h*a(I));(P-=U*2)>1e-12?(U*=k?1:-1,M+=U,N-=U):(P=0,M=N=(g+_)/2),(F-=W*2)>1e-12?(W*=k?1:-1,A+=W,j-=W):(F=0,A=j=(g+_)/2)}var G=h*u(A),K=h*a(A),q=m*u(N),J=m*a(N);if(R>1e-12){var Y=h*u(j),X=h*a(j),Z=m*u(M),Q=m*a(M),$;if(v1e-12?B>1e-12?(V=b(Z,Q,G,K,h,B,k),H=b(Y,X,q,J,h,B,k),D.moveTo(V.cx+V.x01,V.cy+V.y01),B1e-12)||!(P>1e-12)?D.lineTo(q,J):z>1e-12?(V=b(q,J,Y,X,m,-z,k),H=b(G,K,Z,Q,m,-z,k),D.lineTo(V.cx+V.x01,V.cy+V.y01),z{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r():typeof define==`function`&&define.amd?define([],r):typeof e==`object`?e.layoutBase=r():n.layoutBase=r()})(e,function(){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=28)})([(function(e,t,n){function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,e.exports=r}),(function(e,t,n){var r=n(2),i=n(8),a=n(9);function o(e,t,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=e,this.target=t}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];o.prototype.getSource=function(){return this.source},o.prototype.getTarget=function(){return this.target},o.prototype.isInterGraph=function(){return this.isInterGraph},o.prototype.getLength=function(){return this.length},o.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},o.prototype.getBendpoints=function(){return this.bendpoints},o.prototype.getLca=function(){return this.lca},o.prototype.getSourceInLca=function(){return this.sourceInLca},o.prototype.getTargetInLca=function(){return this.targetInLca},o.prototype.getOtherEnd=function(e){if(this.source===e)return this.target;if(this.target===e)return this.source;throw`Node is not incident with this edge`},o.prototype.getOtherEndInGraph=function(e,t){for(var n=this.getOtherEnd(e),r=t.getGraphManager().getRoot();;){if(n.getOwner()==t)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},o.prototype.updateLength=function(){var e=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),e),this.isOverlapingSourceAndTarget||(this.lengthX=e[0]-e[2],this.lengthY=e[1]-e[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},o.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},e.exports=o}),(function(e,t,n){function r(e){this.vGraphObject=e}e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(13),o=n(0),s=n(16),c=n(5);function l(e,t,n,o){n==null&&o==null&&(o=t),r.call(this,o),e.graphManager!=null&&(e=e.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=o,this.edges=[],this.graphManager=e,this.rect=n!=null&&t!=null?new a(t.x,t.y,n.width,n.height):new a}for(var u in l.prototype=Object.create(r.prototype),r)l[u]=r[u];l.prototype.getEdges=function(){return this.edges},l.prototype.getChild=function(){return this.child},l.prototype.getOwner=function(){return this.owner},l.prototype.getWidth=function(){return this.rect.width},l.prototype.setWidth=function(e){this.rect.width=e},l.prototype.getHeight=function(){return this.rect.height},l.prototype.setHeight=function(e){this.rect.height=e},l.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},l.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},l.prototype.getCenter=function(){return new c(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},l.prototype.getLocation=function(){return new c(this.rect.x,this.rect.y)},l.prototype.getRect=function(){return this.rect},l.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},l.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},l.prototype.setRect=function(e,t){this.rect.x=e.x,this.rect.y=e.y,this.rect.width=t.width,this.rect.height=t.height},l.prototype.setCenter=function(e,t){this.rect.x=e-this.rect.width/2,this.rect.y=t-this.rect.height/2},l.prototype.setLocation=function(e,t){this.rect.x=e,this.rect.y=t},l.prototype.moveBy=function(e,t){this.rect.x+=e,this.rect.y+=t},l.prototype.getEdgeListToNode=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.target==e){if(r.source!=n)throw`Incorrect edge source!`;t.push(r)}}),t},l.prototype.getEdgesBetween=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.source!=n&&r.target!=n)throw`Incorrect edge source and/or target`;(r.target==e||r.source==e)&&t.push(r)}),t},l.prototype.getNeighborsList=function(){var e=new Set,t=this;return t.edges.forEach(function(n){if(n.source==t)e.add(n.target);else{if(n.target!=t)throw`Incorrect incidency!`;e.add(n.source)}}),e},l.prototype.withChildren=function(){var e=new Set,t,n;if(e.add(this),this.child!=null)for(var r=this.child.getNodes(),i=0;it?(this.rect.x-=(this.labelWidth-t)/2,this.setWidth(this.labelWidth)):this.labelPosHorizontal==`right`&&this.setWidth(t+this.labelWidth)),this.labelHeight&&(this.labelPosVertical==`top`?(this.rect.y-=this.labelHeight,this.setHeight(n+this.labelHeight)):this.labelPosVertical==`center`&&this.labelHeight>n?(this.rect.y-=(this.labelHeight-n)/2,this.setHeight(this.labelHeight)):this.labelPosVertical==`bottom`&&this.setHeight(n+this.labelHeight))}}},l.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw`assert failed`;return this.inclusionTreeDepth},l.prototype.transform=function(e){var t=this.rect.x;t>o.WORLD_BOUNDARY?t=o.WORLD_BOUNDARY:t<-o.WORLD_BOUNDARY&&(t=-o.WORLD_BOUNDARY);var n=this.rect.y;n>o.WORLD_BOUNDARY?n=o.WORLD_BOUNDARY:n<-o.WORLD_BOUNDARY&&(n=-o.WORLD_BOUNDARY);var r=new c(t,n),i=e.inverseTransformPoint(r);this.setLocation(i.x,i.y)},l.prototype.getLeft=function(){return this.rect.x},l.prototype.getRight=function(){return this.rect.x+this.rect.width},l.prototype.getTop=function(){return this.rect.y},l.prototype.getBottom=function(){return this.rect.y+this.rect.height},l.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},e.exports=l}),(function(e,t,n){var r=n(0);function i(){}for(var a in r)i[a]=r[a];i.MAX_ITERATIONS=2500,i.DEFAULT_EDGE_LENGTH=50,i.DEFAULT_SPRING_STRENGTH=.45,i.DEFAULT_REPULSION_STRENGTH=4500,i.DEFAULT_GRAVITY_STRENGTH=.4,i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,i.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,i.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,i.COOLING_ADAPTATION_FACTOR=.33,i.ADAPTATION_LOWER_NODE_LIMIT=1e3,i.ADAPTATION_UPPER_NODE_LIMIT=5e3,i.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,i.MAX_NODE_DISPLACEMENT=i.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,i.MIN_REPULSION_DIST=i.DEFAULT_EDGE_LENGTH/10,i.CONVERGENCE_CHECK_PERIOD=100,i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,i.MIN_EDGE_LENGTH=1,i.GRID_CALCULATION_CHECK_PERIOD=10,e.exports=i}),(function(e,t,n){function r(e,t){e==null&&t==null?(this.x=0,this.y=0):(this.x=e,this.y=t)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(e){this.x=e},r.prototype.setY=function(e){this.y=e},r.prototype.getDifference=function(e){return new DimensionD(this.x-e.x,this.y-e.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(e){return this.x+=e.width,this.y+=e.height,this},e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(0),o=n(7),s=n(3),c=n(1),l=n(13),u=n(12),d=n(11);function f(e,t,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=e,t!=null&&t instanceof o?this.graphManager=t:t!=null&&t instanceof Layout&&(this.graphManager=t.graphManager)}for(var p in f.prototype=Object.create(r.prototype),r)f[p]=r[p];f.prototype.getNodes=function(){return this.nodes},f.prototype.getEdges=function(){return this.edges},f.prototype.getGraphManager=function(){return this.graphManager},f.prototype.getParent=function(){return this.parent},f.prototype.getLeft=function(){return this.left},f.prototype.getRight=function(){return this.right},f.prototype.getTop=function(){return this.top},f.prototype.getBottom=function(){return this.bottom},f.prototype.isConnected=function(){return this.isConnected},f.prototype.add=function(e,t,n){if(t==null&&n==null){var r=e;if(this.graphManager==null)throw`Graph has no graph mgr!`;if(this.getNodes().indexOf(r)>-1)throw`Node already in graph!`;return r.owner=this,this.getNodes().push(r),r}var i=e;if(!(this.getNodes().indexOf(t)>-1&&this.getNodes().indexOf(n)>-1))throw`Source or target not in graph!`;if(t.owner!=n.owner||t.owner!=this)throw`Both owners must be this graph!`;return t.owner==n.owner?(i.source=t,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),t.edges.push(i),n!=t&&n.edges.push(i),i):null},f.prototype.remove=function(e){var t=e;if(e instanceof s){if(t==null)throw`Node is null!`;if(t.owner==null||t.owner!=this)throw`Owner graph is invalid!`;if(this.graphManager==null)throw`Owner graph manager is invalid!`;for(var n=t.edges.slice(),r,i=n.length,a=0;a-1&&u>-1))throw`Source and/or target doesn't know this edge!`;r.source.edges.splice(l,1),r.target!=r.source&&r.target.edges.splice(u,1);var o=r.source.owner.getEdges().indexOf(r);if(o==-1)throw`Not in owner's edge list!`;r.source.owner.getEdges().splice(o,1)}},f.prototype.updateLeftTop=function(){for(var e=i.MAX_VALUE,t=i.MAX_VALUE,n,r,a,o=this.getNodes(),s=o.length,c=0;cn&&(e=n),t>r&&(t=r)}return e==i.MAX_VALUE?null:(a=o[0].getParent().paddingLeft==null?this.margin:o[0].getParent().paddingLeft,this.left=t-a,this.top=e-a,new u(this.left,this.top))},f.prototype.updateBounds=function(e){for(var t=i.MAX_VALUE,n=-i.MAX_VALUE,r=i.MAX_VALUE,a=-i.MAX_VALUE,o,s,c,u,d,f=this.nodes,p=f.length,m=0;mo&&(t=o),nc&&(r=c),ao&&(t=o),nc&&(r=c),a=this.nodes.length){var c=0;n.forEach(function(t){t.owner==e&&c++}),c==this.nodes.length&&(this.isConnected=!0)}},e.exports=f}),(function(e,t,n){var r,i=n(1);function a(e){r=n(6),this.layout=e,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var e=this.layout.newGraph(),t=this.layout.newNode(null),n=this.add(e,t);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(e,t,n,r,i){if(n==null&&r==null&&i==null){if(e==null)throw`Graph is null!`;if(t==null)throw`Parent node is null!`;if(this.graphs.indexOf(e)>-1)throw`Graph already in this graph mgr!`;if(this.graphs.push(e),e.parent!=null)throw`Already has a parent!`;if(t.child!=null)throw`Already has a child!`;return e.parent=t,t.child=e,e}i=n,r=t,n=e;var a=r.getOwner(),o=i.getOwner();if(a==null||a.getGraphManager()!=this)throw`Source not in this graph mgr!`;if(o==null||o.getGraphManager()!=this)throw`Target not in this graph mgr!`;if(a==o)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw`Edge already in inter-graph edge list!`;if(this.edges.push(n),n.source==null||n.target==null)throw`Edge source and/or target is null!`;if(n.source.edges.indexOf(n)!=-1||n.target.edges.indexOf(n)!=-1)throw`Edge already in source and/or target incidency list!`;return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(e){if(e instanceof r){var t=e;if(t.getGraphManager()!=this)throw`Graph not in this graph mgr`;if(!(t==this.rootGraph||t.parent!=null&&t.parent.graphManager==this))throw`Invalid parent node!`;var n=[];n=n.concat(t.getEdges());for(var a,o=n.length,s=0;s=t.getRight()?n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight()):t.getX()<=e.getX()&&t.getRight()>=e.getRight()&&(n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight())),e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()?n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()):t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()&&(n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()));var a=Math.abs((t.getCenterY()-e.getCenterY())/(t.getCenterX()-e.getCenterX()));t.getCenterY()===e.getCenterY()&&t.getCenterX()===e.getCenterX()&&(a=1);var o=a*n[0],s=n[1]/a;n[0]o)return n[0]=r,n[1]=c,n[2]=a,n[3]=y,!1;if(ia)return n[0]=s,n[1]=i,n[2]=_,n[3]=o,!1;if(ra?(n[0]=u,n[1]=d,C=!0):(n[0]=l,n[1]=c,C=!0):T===D&&(r>a?(n[0]=s,n[1]=c,C=!0):(n[0]=f,n[1]=d,C=!0)),-E===D?a>r?(n[2]=v,n[3]=y,w=!0):(n[2]=_,n[3]=g,w=!0):E===D&&(a>r?(n[2]=h,n[3]=g,w=!0):(n[2]=b,n[3]=y,w=!0)),C&&w)return!1;if(r>a?i>o?(O=this.getCardinalDirection(T,D,4),k=this.getCardinalDirection(E,D,2)):(O=this.getCardinalDirection(-T,D,3),k=this.getCardinalDirection(-E,D,1)):i>o?(O=this.getCardinalDirection(-T,D,1),k=this.getCardinalDirection(-E,D,3)):(O=this.getCardinalDirection(T,D,2),k=this.getCardinalDirection(E,D,4)),!C)switch(O){case 1:j=c,A=r+-m/D,n[0]=A,n[1]=j;break;case 2:A=f,j=i+p*D,n[0]=A,n[1]=j;break;case 3:j=d,A=r+m/D,n[0]=A,n[1]=j;break;case 4:A=u,j=i+-p*D,n[0]=A,n[1]=j}if(!w)switch(k){case 1:N=g,M=a+-S/D,n[2]=M,n[3]=N;break;case 2:M=b,N=o+x*D,n[2]=M,n[3]=N;break;case 3:N=y,M=a+S/D,n[2]=M,n[3]=N;break;case 4:M=v,N=o+-x*D,n[2]=M,n[3]=N}}return!1},i.getCardinalDirection=function(e,t,n){return e>t?n:1+n%4},i.getIntersection=function(e,t,n,i){if(i==null)return this.getIntersection2(e,t,n);var a=e.x,o=e.y,s=t.x,c=t.y,l=n.x,u=n.y,d=i.x,f=i.y,p=void 0,m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0;return h=c-o,_=a-s,y=s*o-a*c,g=f-u,v=l-d,b=d*u-l*f,x=h*v-g*_,x===0?null:(p=(_*b-v*y)/x,m=(g*y-h*b)/x,new r(p,m))},i.angleOfVector=function(e,t,n,r){var i=void 0;return e===n?i=r=0){var u=(-c+Math.sqrt(c*c-4*s*l))/(2*s),d=(-c-Math.sqrt(c*c-4*s*l))/(2*s);return u>=0&&u<=1?[u]:d>=0&&d<=1?[d]:null}return null},i.HALF_PI=.5*Math.PI,i.ONE_AND_HALF_PI=1.5*Math.PI,i.TWO_PI=2*Math.PI,i.THREE_PI=3*Math.PI,e.exports=i}),(function(e,t,n){function r(){}r.sign=function(e){return e>0?1:e<0?-1:0},r.floor=function(e){return e<0?Math.ceil(e):Math.floor(e)},r.ceil=function(e){return e<0?Math.floor(e):Math.ceil(e)},e.exports=r}),(function(e,t,n){function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n0&&t;){for(s.push(l[0]);s.length>0&&t;){var u=s[0];s.splice(0,1),o.add(u);for(var d=u.getEdges(),a=0;a-1&&l.splice(h,1)}o=new Set,c=new Map}}return e},f.prototype.createDummyNodesForBendpoints=function(e){for(var t=[],n=e.source,r=this.graphManager.calcLowestCommonAncestor(e.source,e.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&t.splice(d,1),s.getNeighborsList().forEach(function(e){if(n.indexOf(e)<0){var t=r.get(e)-1;t==1&&l.push(e),r.set(e,t)}})}n=n.concat(l),(t.length==1||t.length==2)&&(i=!0,a=t[0])}return a},f.prototype.setGraphManager=function(e){this.graphManager=e},e.exports=f}),(function(e,t,n){function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=Math.sin(r.seed++)*1e4,r.x-Math.floor(r.x)},e.exports=r}),(function(e,t,n){var r=n(5);function i(e,t){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(e){this.lworldExtX=e},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(e){this.lworldExtY=e},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},i.prototype.transformX=function(e){var t=0,n=this.lworldExtX;return n!=0&&(t=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/n),t},i.prototype.transformY=function(e){var t=0,n=this.lworldExtY;return n!=0&&(t=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/n),t},i.prototype.inverseTransformX=function(e){var t=0,n=this.ldeviceExtX;return n!=0&&(t=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/n),t},i.prototype.inverseTransformY=function(e){var t=0,n=this.ldeviceExtY;return n!=0&&(t=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/n),t},i.prototype.inverseTransformPoint=function(e){return new r(this.inverseTransformX(e.x),this.inverseTransformY(e.y))},e.exports=i}),(function(e,t,n){function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);ta.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*a.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-a.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT_INCREMENTAL):(this.coolingFactor=e>a.ADAPTATION_LOWER_NODE_LIMIT?Math.max(a.COOLING_ADAPTATION_FACTOR,1-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*(1-a.COOLING_ADAPTATION_FACTOR)):1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.displacementThresholdPerNode=3*a.DEFAULT_EDGE_LENGTH/100,this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var e=this.getAllEdges(),t,n=0;n0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n,r,i,o,s=this.getAllNodes(),c;if(this.useFRGridVariant)for(this.totalIterations%a.GRID_CALCULATION_CHECK_PERIOD==1&&e&&this.updateGrid(),c=new Set,n=0;nc||s>c)&&(e.gravitationForceX=-this.gravityConstant*i,e.gravitationForceY=-this.gravityConstant*a)):(c=t.getEstimatedSize()*this.compoundGravityRangeFactor,(o>c||s>c)&&(e.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,e.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant))},l.prototype.isConverged=function(){var e,t=!1;return this.totalIterations>this.maxIterations/3&&(t=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),e=this.totalDisplacement=c.length||u>=c[0].length)){for(var d=0;de}}]),e}()}),(function(e,t,n){function r(){}r.svd=function(e){this.U=null,this.V=null,this.s=null,this.m=0,this.n=0,this.m=e.length,this.n=e[0].length;var t=Math.min(this.m,this.n);this.s=function(e){for(var t=[];e-->0;)t.push(0);return t}(Math.min(this.m+1,this.n)),this.U=function(e){return function e(t){if(t.length==0)return 0;for(var n=[],r=0;r0;)t.push(0);return t}(this.n),i=function(e){for(var t=[];e-->0;)t.push(0);return t}(this.m),a=!0,o=!0,s=Math.min(this.m-1,this.n),c=Math.max(0,Math.min(this.n-2,this.m)),l=0;l=0;k--)if(this.s[k]!==0){for(var A=k+1;A=0;L--){if(function(e,t){return e&&t}(L0;){var U=void 0,W=void 0;for(U=E-2;U>=-1&&U!==-1;U--)if(Math.abs(n[U])<=re+ne*(Math.abs(this.s[U])+Math.abs(this.s[U+1]))){n[U]=0;break}if(U===E-2)W=4;else{var G=void 0;for(G=E-1;G>=U&&G!==U;G--){var ie=(G===E?0:Math.abs(n[G]))+(G===U+1?0:Math.abs(n[G-1]));if(Math.abs(this.s[G])<=re+ne*ie){this.s[G]=0;break}}G===U?W=3:G===E-1?W=1:(W=2,U=G)}switch(U++,W){case 1:var K=n[E-2];n[E-2]=0;for(var q=E-2;q>=U;q--){var ae=r.hypot(this.s[q],K),J=this.s[q]/ae,Y=K/ae;if(this.s[q]=ae,q!==U&&(K=-Y*n[q-1],n[q-1]=J*n[q-1]),o)for(var X=0;X=this.s[U+1]);){var De=this.s[U];if(this.s[U]=this.s[U+1],this.s[U+1]=De,o&&UMath.abs(t)?(n=t/e,n=Math.abs(e)*Math.sqrt(1+n*n)):t==0?n=0:(n=e/t,n=Math.abs(t)*Math.sqrt(1+n*n)),n},e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:1,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,e),this.sequence1=t,this.sequence2=n,this.match_score=r,this.mismatch_penalty=a,this.gap_penalty=o,this.iMax=t.length+1,this.jMax=n.length+1,this.grid=Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===e&&r.callback===t&&this.listeners.splice(n,1)}},i.emit=function(e,t){for(var n=0;n{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(D()):typeof define==`function`&&define.amd?define([`layout-base`],r):typeof e==`object`?e.coseBase=r(D()):n.coseBase=r(n.layoutBase)})(e,function(e){return(()=>{var t={45:((e,t,n)=>{var r={};r.layoutBase=n(551),r.CoSEConstants=n(806),r.CoSEEdge=n(767),r.CoSEGraph=n(880),r.CoSEGraphManager=n(578),r.CoSELayout=n(765),r.CoSENode=n(991),r.ConstraintHandler=n(902),e.exports=r}),806:((e,t,n)=>{var r=n(551).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,i.ENFORCE_CONSTRAINTS=!0,i.APPLY_LAYOUT=!0,i.RELAX_MOVEMENT_ON_CONSTRAINTS=!0,i.TREE_REDUCTION_ON_INCREMENTAL=!0,i.PURE_INCREMENTAL=i.DEFAULT_INCREMENTAL,e.exports=i}),767:((e,t,n)=>{var r=n(551).FDLayoutEdge;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),880:((e,t,n)=>{var r=n(551).LGraph;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),578:((e,t,n)=>{var r=n(551).LGraphManager;function i(e){r.call(this,e)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),765:((e,t,n)=>{var r=n(551).FDLayout,i=n(578),a=n(880),o=n(991),s=n(767),c=n(806),l=n(902),u=n(551).FDLayoutConstants,d=n(551).LayoutConstants,f=n(551).Point,p=n(551).PointD,m=n(551).DimensionD,h=n(551).Layout,g=n(551).Integer,_=n(551).IGeometry,v=n(551).LGraph,y=n(551).Transform,b=n(551).LinkedList;function x(){r.call(this),this.toBeTiled={},this.constraints={}}for(var S in x.prototype=Object.create(r.prototype),r)x[S]=r[S];x.prototype.newGraphManager=function(){var e=new i(this);return this.graphManager=e,e},x.prototype.newGraph=function(e){return new a(null,this.graphManager,e)},x.prototype.newNode=function(e){return new o(this.graphManager,e)},x.prototype.newEdge=function(e){return new s(null,null,e)},x.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.isSubLayout||(this.idealEdgeLength=c.DEFAULT_EDGE_LENGTH<10?10:c.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=c.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.gravityConstant=u.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=u.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=u.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=u.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1)},x.prototype.initSpringEmbedder=function(){r.prototype.initSpringEmbedder.call(this),this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/u.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=.04,this.coolingAdjuster=1},x.prototype.layout=function(){return d.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},x.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),!this.incremental){var e=this.getFlatForest();if(e.length>0)this.positionNodesRadially(e);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}else if(c.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n)}return Object.keys(this.constraints).length>0&&(l.handleConstraints(this),this.initConstraintVariables()),this.initSpringEmbedder(),c.APPLY_LAYOUT&&this.runSpringEmbedder(),!0},x.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}if(this.totalIterations%u.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0){if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),t=this.nodesWithGravity.filter(function(t){return e.has(t)});this.graphManager.setAllNodesToApplyGravitation(t),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=c.PURE_INCREMENTAL?u.DEFAULT_COOLING_FACTOR_INCREMENTAL/2:u.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0}this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=c.PURE_INCREMENTAL?u.DEFAULT_COOLING_FACTOR_INCREMENTAL/2*((100-this.afterGrowthIterations)/100):u.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},x.prototype.getPositionsData=function(){for(var e=this.graphManager.getAllNodes(),t={},n=0;n0&&this.updateDisplacements();for(var n=0;n0&&(r.fixedNodeWeight=a)}}if(this.constraints.relativePlacementConstraint){var o=new Map,s=new Map;if(this.dummyToNodeForVerticalAlignment=new Map,this.dummyToNodeForHorizontalAlignment=new Map,this.fixedNodesOnHorizontal=new Set,this.fixedNodesOnVertical=new Set,this.fixedNodeSet.forEach(function(t){e.fixedNodesOnHorizontal.add(t),e.fixedNodesOnVertical.add(t)}),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical)for(var l=this.constraints.alignmentConstraint.vertical,n=0;n=2*e.length/3;r--)t=Math.floor(Math.random()*(r+1)),n=e[r],e[r]=e[t],e[t]=n;return e},this.nodesInRelativeHorizontal=[],this.nodesInRelativeVertical=[],this.nodeToRelativeConstraintMapHorizontal=new Map,this.nodeToRelativeConstraintMapVertical=new Map,this.nodeToTempPositionMapHorizontal=new Map,this.nodeToTempPositionMapVertical=new Map,this.constraints.relativePlacementConstraint.forEach(function(t){if(t.left){var n=o.has(t.left)?o.get(t.left):t.left,r=o.has(t.right)?o.get(t.right):t.right;e.nodesInRelativeHorizontal.includes(n)||(e.nodesInRelativeHorizontal.push(n),e.nodeToRelativeConstraintMapHorizontal.set(n,[]),e.dummyToNodeForVerticalAlignment.has(n)?e.nodeToTempPositionMapHorizontal.set(n,e.idToNodeMap.get(e.dummyToNodeForVerticalAlignment.get(n)[0]).getCenterX()):e.nodeToTempPositionMapHorizontal.set(n,e.idToNodeMap.get(n).getCenterX())),e.nodesInRelativeHorizontal.includes(r)||(e.nodesInRelativeHorizontal.push(r),e.nodeToRelativeConstraintMapHorizontal.set(r,[]),e.dummyToNodeForVerticalAlignment.has(r)?e.nodeToTempPositionMapHorizontal.set(r,e.idToNodeMap.get(e.dummyToNodeForVerticalAlignment.get(r)[0]).getCenterX()):e.nodeToTempPositionMapHorizontal.set(r,e.idToNodeMap.get(r).getCenterX())),e.nodeToRelativeConstraintMapHorizontal.get(n).push({right:r,gap:t.gap}),e.nodeToRelativeConstraintMapHorizontal.get(r).push({left:n,gap:t.gap})}else{var i=s.has(t.top)?s.get(t.top):t.top,a=s.has(t.bottom)?s.get(t.bottom):t.bottom;e.nodesInRelativeVertical.includes(i)||(e.nodesInRelativeVertical.push(i),e.nodeToRelativeConstraintMapVertical.set(i,[]),e.dummyToNodeForHorizontalAlignment.has(i)?e.nodeToTempPositionMapVertical.set(i,e.idToNodeMap.get(e.dummyToNodeForHorizontalAlignment.get(i)[0]).getCenterY()):e.nodeToTempPositionMapVertical.set(i,e.idToNodeMap.get(i).getCenterY())),e.nodesInRelativeVertical.includes(a)||(e.nodesInRelativeVertical.push(a),e.nodeToRelativeConstraintMapVertical.set(a,[]),e.dummyToNodeForHorizontalAlignment.has(a)?e.nodeToTempPositionMapVertical.set(a,e.idToNodeMap.get(e.dummyToNodeForHorizontalAlignment.get(a)[0]).getCenterY()):e.nodeToTempPositionMapVertical.set(a,e.idToNodeMap.get(a).getCenterY())),e.nodeToRelativeConstraintMapVertical.get(i).push({bottom:a,gap:t.gap}),e.nodeToRelativeConstraintMapVertical.get(a).push({top:i,gap:t.gap})}});else{var d=new Map,f=new Map;this.constraints.relativePlacementConstraint.forEach(function(e){if(e.left){var t=o.has(e.left)?o.get(e.left):e.left,n=o.has(e.right)?o.get(e.right):e.right;d.has(t)?d.get(t).push(n):d.set(t,[n]),d.has(n)?d.get(n).push(t):d.set(n,[t])}else{var r=s.has(e.top)?s.get(e.top):e.top,i=s.has(e.bottom)?s.get(e.bottom):e.bottom;f.has(r)?f.get(r).push(i):f.set(r,[i]),f.has(i)?f.get(i).push(r):f.set(i,[r])}});var p=function(e,t){var n=[],r=[],i=new b,a=new Set,o=0;return e.forEach(function(s,c){if(!a.has(c)){n[o]=[],r[o]=!1;var l=c;for(i.push(l),a.add(l),n[o].push(l);i.length!=0;)l=i.shift(),t.has(l)&&(r[o]=!0),e.get(l).forEach(function(e){a.has(e)||(i.push(e),a.add(e),n[o].push(e))});o++}}),{components:n,isFixed:r}},m=p(d,e.fixedNodesOnHorizontal);this.componentsOnHorizontal=m.components,this.fixedComponentsOnHorizontal=m.isFixed;var h=p(f,e.fixedNodesOnVertical);this.componentsOnVertical=h.components,this.fixedComponentsOnVertical=h.isFixed}}},x.prototype.updateDisplacements=function(){var e=this;if(this.constraints.fixedNodeConstraint&&this.constraints.fixedNodeConstraint.forEach(function(t){var n=e.idToNodeMap.get(t.nodeId);n.displacementX=0,n.displacementY=0}),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical)for(var t=this.constraints.alignmentConstraint.vertical,n=0;n1){var s;for(s=0;sr&&(r=Math.floor(o.y)),a=Math.floor(o.x+c.DEFAULT_COMPONENT_SEPERATION)}this.transform(new p(d.WORLD_CENTER_X-o.x/2,d.WORLD_CENTER_Y-o.y/2))},x.radialLayout=function(e,t,n){var r=Math.max(this.maxDiagonalInTree(e),c.DEFAULT_RADIAL_SEPARATION);x.branchRadialLayout(t,null,0,359,0,r);var i=v.calculateBounds(e),a=new y;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var o=0;o1;){var g=h[0];h.splice(0,1);var v=u.indexOf(g);v>=0&&u.splice(v,1),p--,d--}m=t==null?0:(u.indexOf(h[0])+1)%p;for(var y=Math.abs(r-n)/d,b=m;f!=d;b=++b%p){var S=u[b].getOtherEnd(e);if(S!=t){var C=(n+f*y)%360,w=(C+y)%360;x.branchRadialLayout(S,e,C,w,i+a,a),f++}}},x.maxDiagonalInTree=function(e){for(var t=g.MIN_VALUE,n=0;nt&&(t=r)}return t},x.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},x.prototype.groupZeroDegreeMembers=function(){var e=this,t={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r=`DummyCompound_`+n;e.memberGroups[r]=t[n];var i=t[n][0].getParent(),a=new o(e.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,e.idToDummyNode[r]=a;var s=e.getGraphManager().add(e.newGraph(),a),c=i.getChild();c.add(a);for(var l=0;li?(r.rect.x-=(r.labelWidth-i)/2,r.setWidth(r.labelWidth),r.labelMarginLeft=(r.labelWidth-i)/2):r.labelPosHorizontal==`right`&&r.setWidth(i+r.labelWidth)),r.labelHeight&&(r.labelPosVertical==`top`?(r.rect.y-=r.labelHeight,r.setHeight(a+r.labelHeight),r.labelMarginTop=r.labelHeight):r.labelPosVertical==`center`&&r.labelHeight>a?(r.rect.y-=(r.labelHeight-a)/2,r.setHeight(r.labelHeight),r.labelMarginTop=(r.labelHeight-a)/2):r.labelPosVertical==`bottom`&&r.setHeight(a+r.labelHeight))}})},x.prototype.repopulateCompounds=function(){for(var e=this.compoundOrder.length-1;e>=0;e--){var t=this.compoundOrder[e],n=t.id,r=t.paddingLeft,i=t.paddingTop,a=t.labelMarginLeft,o=t.labelMarginTop;this.adjustLocations(this.tiledMemberPack[n],t.rect.x,t.rect.y,r,i,a,o)}},x.prototype.repopulateZeroDegreeMembers=function(){var e=this,t=this.tiledZeroDegreePack;Object.keys(t).forEach(function(n){var r=e.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop,o=r.labelMarginLeft,s=r.labelMarginTop;e.adjustLocations(t[n],r.rect.x,r.rect.y,i,a,o,s)})},x.prototype.getToBeTiled=function(e){var t=e.id;if(this.toBeTiled[t]!=null)return this.toBeTiled[t];var n=e.getChild();if(n==null)return this.toBeTiled[t]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[t]=!1,!1;if(a.getChild()==null){this.toBeTiled[a.id]=!1;continue}if(!this.getToBeTiled(a))return this.toBeTiled[t]=!1,!1}return this.toBeTiled[t]=!0,!0},x.prototype.getNodeDegree=function(e){e.id;for(var t=e.getEdges(),n=0,r=0;ru&&(u=f.rect.height)}n+=u+e.verticalPadding}},x.prototype.tileCompoundMembers=function(e,t){var n=this;this.tiledMemberPack=[],Object.keys(e).forEach(function(r){var i=t[r];if(n.tiledMemberPack[r]=n.tileNodes(e[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height,i.setCenter(n.tiledMemberPack[r].centerX,n.tiledMemberPack[r].centerY),i.labelMarginLeft=0,i.labelMarginTop=0,c.NODE_DIMENSIONS_INCLUDE_LABELS){var a=i.rect.width,o=i.rect.height;i.labelWidth&&(i.labelPosHorizontal==`left`?(i.rect.x-=i.labelWidth,i.setWidth(a+i.labelWidth),i.labelMarginLeft=i.labelWidth):i.labelPosHorizontal==`center`&&i.labelWidth>a?(i.rect.x-=(i.labelWidth-a)/2,i.setWidth(i.labelWidth),i.labelMarginLeft=(i.labelWidth-a)/2):i.labelPosHorizontal==`right`&&i.setWidth(a+i.labelWidth)),i.labelHeight&&(i.labelPosVertical==`top`?(i.rect.y-=i.labelHeight,i.setHeight(o+i.labelHeight),i.labelMarginTop=i.labelHeight):i.labelPosVertical==`center`&&i.labelHeight>o?(i.rect.y-=(i.labelHeight-o)/2,i.setHeight(i.labelHeight),i.labelMarginTop=(i.labelHeight-o)/2):i.labelPosVertical==`bottom`&&i.setHeight(o+i.labelHeight))}})},x.prototype.tileNodes=function(e,t){var n=this.tileNodesByFavoringDim(e,t,!0),r=this.tileNodesByFavoringDim(e,t,!1),i=this.getOrgRatio(n);return this.getOrgRatio(r)s&&(s=e.getWidth())});var l=a/i,u=o/i,d=(n-r)**2+4*(l+r)*(u+n)*i,f=(r-n+Math.sqrt(d))/(2*(l+r)),p;t?(p=Math.ceil(f),p==f&&p++):p=Math.floor(f);var m=p*(l+r)-r;return s>m&&(m=s),m+=r*2,m},x.prototype.tileNodesByFavoringDim=function(e,t,n){var r=c.TILING_PADDING_VERTICAL,i=c.TILING_PADDING_HORIZONTAL,a=c.TILING_COMPARE_BY,o={rows:[],rowWidth:[],rowHeight:[],width:0,height:t,verticalPadding:r,horizontalPadding:i,centerX:0,centerY:0};a&&(o.idealRowWidth=this.calcIdealRowWidth(e,n));var s=function(e){return e.rect.width*e.rect.height},l=function(e,t){return s(t)-s(e)};e.sort(function(e,t){var n=l;return o.idealRowWidth?(n=a,n(e.id,t.id)):n(e,t)});for(var u=0,d=0,f=0;f0&&(a+=e.horizontalPadding),e.rowWidth[n]=a,e.width0&&(o+=e.verticalPadding);var s=0;o>e.rowHeight[n]&&(s=e.rowHeight[n],e.rowHeight[n]=o,s=e.rowHeight[n]-s),e.height+=s,e.rows[n].push(t)},x.prototype.getShortestRowIndex=function(e){for(var t=-1,n=Number.MAX_VALUE,r=0;rn&&(t=r,n=e.rowWidth[r]);return t},x.prototype.canAddHorizontal=function(e,t,n){if(e.idealRowWidth){var r=e.rows.length-1;return e.rowWidth[r]+t+e.horizontalPadding<=e.idealRowWidth}var i=this.getShortestRowIndex(e);if(i<0)return!0;var a=e.rowWidth[i];if(a+e.horizontalPadding+t<=e.width)return!0;var o=0;e.rowHeight[i]0&&(o=n+e.verticalPadding-e.rowHeight[i]);var s=e.width-a>=t+e.horizontalPadding?(e.height+o)/(a+t+e.horizontalPadding):(e.height+o)/e.width;o=n+e.verticalPadding;var c=e.widtha&&t!=n){r.splice(-1,1),e.rows[n].push(i),e.rowWidth[t]=e.rowWidth[t]-a,e.rowWidth[n]=e.rowWidth[n]+a,e.width=e.rowWidth[instance.getLongestRowIndex(e)];for(var o=Number.MIN_VALUE,s=0;so&&(o=r[s].height);t>0&&(o+=e.verticalPadding);var c=e.rowHeight[t]+e.rowHeight[n];e.rowHeight[t]=o,e.rowHeight[n]0)for(var d=i;d<=a;d++)l[0]+=this.grid[d][o-1].length+this.grid[d][o].length-1;if(a0)for(var d=o;d<=s;d++)l[3]+=this.grid[i-1][d].length+this.grid[i][d].length-1;for(var f=g.MAX_VALUE,p,m,h=0;h{var r=n(551).FDLayoutNode,i=n(551).IMath;function a(e,t,n,i){r.call(this,e,t,n,i)}for(var o in a.prototype=Object.create(r.prototype),r)a[o]=r[o];a.prototype.calculateDisplacement=function(){var e=this.graphManager.getLayout();this.getChild()!=null&&this.fixedNodeWeight?(this.displacementX+=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.fixedNodeWeight,this.displacementY+=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.fixedNodeWeight):(this.displacementX+=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY+=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren),Math.abs(this.displacementX)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementX=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementY=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementY)),this.child&&this.child.getNodes().length>0&&this.propogateDisplacementToChildren(this.displacementX,this.displacementY)},a.prototype.propogateDisplacementToChildren=function(e,t){for(var n=this.getChild().getNodes(),r,i=0;i{function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t0){var a=0;r.forEach(function(e){t==`horizontal`?(f.set(e,c.has(e)?l[c.get(e)]:i.get(e)),a+=f.get(e)):(f.set(e,c.has(e)?u[c.get(e)]:i.get(e)),a+=f.get(e))}),a/=r.length,e.forEach(function(e){n.has(e)||f.set(e,a)})}else{var o=0;e.forEach(function(e){o+=t==`horizontal`?c.has(e)?l[c.get(e)]:i.get(e):c.has(e)?u[c.get(e)]:i.get(e)}),o/=e.length,e.forEach(function(e){f.set(e,o)})}});for(var h=function(){var r=m.shift();e.get(r).forEach(function(e){if(f.get(e.id)o&&(o=v),ys&&(s=y)}}catch(e){p=!0,m=e}finally{try{!d&&h.return&&h.return()}finally{if(p)throw m}}var b=(r+o)/2-(a+s)/2,x=!0,S=!1,C=void 0;try{for(var w=e[Symbol.iterator](),T;!(x=(T=w.next()).done);x=!0){var E=T.value;f.set(E,f.get(E)+b)}}catch(e){S=!0,C=e}finally{try{!x&&w.return&&w.return()}finally{if(S)throw C}}})}return f},v=function(e){var t=0,n=0,r=0,i=0;if(e.forEach(function(e){e.left?l[c.get(e.left)]-l[c.get(e.right)]>=0?t++:n++:u[c.get(e.top)]-u[c.get(e.bottom)]>=0?r++:i++}),t>n&&r>i)for(var a=0;an)for(var o=0;oi)for(var s=0;s1)t.fixedNodeConstraint.forEach(function(e,t){S[t]=[e.position.x,e.position.y],C[t]=[l[c.get(e.nodeId)],u[c.get(e.nodeId)]]}),w=!0;else if(t.alignmentConstraint)(function(){var e=0;if(t.alignmentConstraint.vertical){for(var n=t.alignmentConstraint.vertical,i=function(t){var i=new Set;n[t].forEach(function(e){i.add(e)});var a=new Set([].concat(r(i)).filter(function(e){return E.has(e)})),o=void 0;o=a.size>0?l[c.get(a.values().next().value)]:g(i).x,n[t].forEach(function(t){S[e]=[o,u[c.get(t)]],C[e]=[l[c.get(t)],u[c.get(t)]],e++})},a=0;a0?l[c.get(i.values().next().value)]:g(n).y,o[t].forEach(function(t){S[e]=[l[c.get(t)],a],C[e]=[l[c.get(t)],u[c.get(t)]],e++})},d=0;dA&&(A=k[M].length,j=M);if(A0){var W={x:0,y:0};t.fixedNodeConstraint.forEach(function(e,t){var n={x:l[c.get(e.nodeId)],y:u[c.get(e.nodeId)]},r=e.position,i=h(r,n);W.x+=i.x,W.y+=i.y}),W.x/=t.fixedNodeConstraint.length,W.y/=t.fixedNodeConstraint.length,l.forEach(function(e,t){l[t]+=W.x}),u.forEach(function(e,t){u[t]+=W.y}),t.fixedNodeConstraint.forEach(function(e){l[c.get(e.nodeId)]=e.position.x,u[c.get(e.nodeId)]=e.position.y})}if(t.alignmentConstraint){if(t.alignmentConstraint.vertical)for(var G=t.alignmentConstraint.vertical,ie=function(e){var t=new Set;G[e].forEach(function(e){t.add(e)});var n=new Set([].concat(r(t)).filter(function(e){return E.has(e)})),i=void 0;i=n.size>0?l[c.get(n.values().next().value)]:g(t).x,t.forEach(function(e){E.has(e)||(l[c.get(e)]=i)})},K=0;K0?u[c.get(n.values().next().value)]:g(t).y,t.forEach(function(e){E.has(e)||(u[c.get(e)]=i)})},J=0;J{t.exports=e})},n={};function r(e){var i=n[e];if(i!==void 0)return i.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}return r(45)})()})})),k=r(e(((e,t)=>{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(O()):typeof define==`function`&&define.amd?define([`cose-base`],r):typeof e==`object`?e.cytoscapeFcose=r(O()):n.cytoscapeFcose=r(n.coseBase)})(e,function(e){return(()=>{var t={658:(e=>{e.exports=Object.assign==null?function(e){return[...arguments].slice(1).forEach(function(t){Object.keys(t).forEach(function(n){return e[n]=t[n]})}),e}:Object.assign.bind(Object)}),548:((e,t,n)=>{var r=function(){function e(e,t){var n=[],r=!0,i=!1,a=void 0;try{for(var o=e[Symbol.iterator](),s;!(r=(s=o.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(e){i=!0,a=e}finally{try{!r&&o.return&&o.return()}finally{if(i)throw a}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw TypeError(`Invalid attempt to destructure non-iterable instance`)}}(),i=n(140).layoutBase.LinkedList,a={};a.getTopMostNodes=function(e){for(var t={},n=0;n0&&l.merge(e)});for(var u=0;u1){l=s[0],u=l.connectedEdges().length,s.forEach(function(e){e.connectedEdges().length0&&r.set(`dummy`+(r.size+1),p),m},a.relocateComponent=function(e,t,n){if(!n.fixedNodeConstraint){var i=1/0,a=-1/0,o=1/0,s=-1/0;if(n.quality==`draft`){var c=!0,l=!1,u=void 0;try{for(var d=t.nodeIndexes[Symbol.iterator](),f;!(c=(f=d.next()).done);c=!0){var p=f.value,m=r(p,2),h=m[0],g=m[1],_=n.cy.getElementById(h);if(_){var v=_.boundingBox(),y=t.xCoords[g]-v.w/2,b=t.xCoords[g]+v.w/2,x=t.yCoords[g]-v.h/2,S=t.yCoords[g]+v.h/2;ya&&(a=b),xs&&(s=S)}}}catch(e){l=!0,u=e}finally{try{!c&&d.return&&d.return()}finally{if(l)throw u}}var C=e.x-(a+i)/2,w=e.y-(s+o)/2;t.xCoords=t.xCoords.map(function(e){return e+C}),t.yCoords=t.yCoords.map(function(e){return e+w})}else{Object.keys(t).forEach(function(e){var n=t[e],r=n.getRect().x,c=n.getRect().x+n.getRect().width,l=n.getRect().y,u=n.getRect().y+n.getRect().height;ra&&(a=c),ls&&(s=u)});var T=e.x-(a+i)/2,E=e.y-(s+o)/2;Object.keys(t).forEach(function(e){var n=t[e];n.setCenter(n.getCenterX()+T,n.getCenterY()+E)})}}},a.calcBoundingBox=function(e,t,n,r){for(var i=2**53-1,a=-(2**53-1),o=2**53-1,s=-(2**53-1),c=void 0,l=void 0,u=void 0,d=void 0,f=e.descendants().not(`:parent`),p=f.length,m=0;mc&&(i=c),au&&(o=u),s{var r=n(548),i=n(140).CoSELayout,a=n(140).CoSENode,o=n(140).layoutBase.PointD,s=n(140).layoutBase.DimensionD,c=n(140).layoutBase.LayoutConstants,l=n(140).layoutBase.FDLayoutConstants,u=n(140).CoSEConstants;e.exports={coseLayout:function(e,t){var n=e.cy,d=e.eles,f=d.nodes(),p=d.edges(),m=void 0,h=void 0,g=void 0,_={};e.randomize&&(m=t.nodeIndexes,h=t.xCoords,g=t.yCoords);var v=function(e){return typeof e==`function`},y=function(e,t){return v(e)?e(t):e},b=r.calcParentsWithoutChildren(n,d),x=function e(t,n,i,c){for(var l=n.length,u=0;u0){var S=void 0;S=i.getGraphManager().add(i.newGraph(),p),e(S,f,i,c)}}},S=function(t,n,r){for(var i=0,a=0,o=0;o0?i/a:v(e.idealEdgeLength)?50:e.idealEdgeLength,u.MIN_REPULSION_DIST=l.MIN_REPULSION_DIST=l.DEFAULT_EDGE_LENGTH/10,u.DEFAULT_RADIAL_SEPARATION=l.DEFAULT_EDGE_LENGTH)},C=function(e,t){t.fixedNodeConstraint&&(e.constraints.fixedNodeConstraint=t.fixedNodeConstraint),t.alignmentConstraint&&(e.constraints.alignmentConstraint=t.alignmentConstraint),t.relativePlacementConstraint&&(e.constraints.relativePlacementConstraint=t.relativePlacementConstraint)};e.nestingFactor!=null&&(u.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=l.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=e.nestingFactor),e.gravity!=null&&(u.DEFAULT_GRAVITY_STRENGTH=l.DEFAULT_GRAVITY_STRENGTH=e.gravity),e.numIter!=null&&(u.MAX_ITERATIONS=l.MAX_ITERATIONS=e.numIter),e.gravityRange!=null&&(u.DEFAULT_GRAVITY_RANGE_FACTOR=l.DEFAULT_GRAVITY_RANGE_FACTOR=e.gravityRange),e.gravityCompound!=null&&(u.DEFAULT_COMPOUND_GRAVITY_STRENGTH=l.DEFAULT_COMPOUND_GRAVITY_STRENGTH=e.gravityCompound),e.gravityRangeCompound!=null&&(u.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=l.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=e.gravityRangeCompound),e.initialEnergyOnIncremental!=null&&(u.DEFAULT_COOLING_FACTOR_INCREMENTAL=l.DEFAULT_COOLING_FACTOR_INCREMENTAL=e.initialEnergyOnIncremental),e.tilingCompareBy!=null&&(u.TILING_COMPARE_BY=e.tilingCompareBy),c.QUALITY=e.quality==`proof`?2:0,u.NODE_DIMENSIONS_INCLUDE_LABELS=l.NODE_DIMENSIONS_INCLUDE_LABELS=c.NODE_DIMENSIONS_INCLUDE_LABELS=e.nodeDimensionsIncludeLabels,u.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=!e.randomize,u.ANIMATE=l.ANIMATE=c.ANIMATE=e.animate,u.TILE=e.tile,u.TILING_PADDING_VERTICAL=typeof e.tilingPaddingVertical==`function`?e.tilingPaddingVertical.call():e.tilingPaddingVertical,u.TILING_PADDING_HORIZONTAL=typeof e.tilingPaddingHorizontal==`function`?e.tilingPaddingHorizontal.call():e.tilingPaddingHorizontal,u.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=!0,u.PURE_INCREMENTAL=!e.randomize,c.DEFAULT_UNIFORM_LEAF_NODE_SIZES=e.uniformNodeDimensions,e.step==`transformed`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,u.ENFORCE_CONSTRAINTS=!1,u.APPLY_LAYOUT=!1),e.step==`enforced`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,u.ENFORCE_CONSTRAINTS=!0,u.APPLY_LAYOUT=!1),e.step==`cose`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,u.ENFORCE_CONSTRAINTS=!1,u.APPLY_LAYOUT=!0),e.step==`all`&&(u.TRANSFORM_ON_CONSTRAINT_HANDLING=!!e.randomize,u.ENFORCE_CONSTRAINTS=!0,u.APPLY_LAYOUT=!0),u.TREE_REDUCTION_ON_INCREMENTAL=!(e.fixedNodeConstraint||e.alignmentConstraint||e.relativePlacementConstraint);var w=new i,T=w.newGraphManager();return x(T.addRoot(),r.getTopMostNodes(f),w,e),S(w,T,p),C(w,e),w.runLayout(),_}}}),212:((e,t,n)=>{var r=function(){function e(e,t){for(var n=0;n0){if(f){var p=o.getTopMostNodes(t.eles.nodes());if(l=o.connectComponents(n,t.eles,p),l.forEach(function(e){var t=e.boundingBox();u.push({x:t.x1+t.w/2,y:t.y1+t.h/2})}),t.randomize&&l.forEach(function(e){t.eles=e,i.push(s(t))}),t.quality=="default"||t.quality==`proof`){var m=n.collection();if(t.tile){var h=new Map,g=[],_=[],v=0,y={nodeIndexes:h,xCoords:g,yCoords:_},b=[];if(l.forEach(function(e,t){e.edges().length==0&&(e.nodes().forEach(function(t,n){m.merge(e.nodes()[n]),t.isParent()||(y.nodeIndexes.set(e.nodes()[n].id(),v++),y.xCoords.push(e.nodes()[0].position().x),y.yCoords.push(e.nodes()[0].position().y))}),b.push(t))}),m.length>1){var x=m.boundingBox();u.push({x:x.x1+x.w/2,y:x.y1+x.h/2}),l.push(m),i.push(y);for(var S=b.length-1;S>=0;S--)l.splice(b[S],1),i.splice(b[S],1),u.splice(b[S],1)}}l.forEach(function(e,n){t.eles=e,a.push(c(t,i[n])),o.relocateComponent(u[n],a[n],t)})}else l.forEach(function(e,n){o.relocateComponent(u[n],i[n],t)});var C=new Set;if(l.length>1){var w=[],T=r.filter(function(e){return e.css(`display`)==`none`});l.forEach(function(e,n){var r=void 0;if(t.quality==`draft`&&(r=i[n].nodeIndexes),e.nodes().not(T).length>0){var s={};s.edges=[],s.nodes=[];var c=void 0;e.nodes().not(T).forEach(function(e){if(t.quality==`draft`){if(!e.isParent())c=r.get(e.id()),s.nodes.push({x:i[n].xCoords[c]-e.boundingbox().w/2,y:i[n].yCoords[c]-e.boundingbox().h/2,width:e.boundingbox().w,height:e.boundingbox().h});else{var l=o.calcBoundingBox(e,i[n].xCoords,i[n].yCoords,r);s.nodes.push({x:l.topLeftX,y:l.topLeftY,width:l.width,height:l.height})}}else a[n][e.id()]&&s.nodes.push({x:a[n][e.id()].getLeft(),y:a[n][e.id()].getTop(),width:a[n][e.id()].getWidth(),height:a[n][e.id()].getHeight()})}),e.edges().forEach(function(e){var c=e.source(),l=e.target();if(c.css(`display`)!=`none`&&l.css(`display`)!=`none`){if(t.quality==`draft`){var u=r.get(c.id()),d=r.get(l.id()),f=[],p=[];if(c.isParent()){var m=o.calcBoundingBox(c,i[n].xCoords,i[n].yCoords,r);f.push(m.topLeftX+m.width/2),f.push(m.topLeftY+m.height/2)}else f.push(i[n].xCoords[u]),f.push(i[n].yCoords[u]);if(l.isParent()){var h=o.calcBoundingBox(l,i[n].xCoords,i[n].yCoords,r);p.push(h.topLeftX+h.width/2),p.push(h.topLeftY+h.height/2)}else p.push(i[n].xCoords[d]),p.push(i[n].yCoords[d]);s.edges.push({startX:f[0],startY:f[1],endX:p[0],endY:p[1]})}else a[n][c.id()]&&a[n][l.id()]&&s.edges.push({startX:a[n][c.id()].getCenterX(),startY:a[n][c.id()].getCenterY(),endX:a[n][l.id()].getCenterX(),endY:a[n][l.id()].getCenterY()})}}),s.nodes.length>0&&(w.push(s),C.add(n))}});var E=d.packComponents(w,t.randomize).shifts;if(t.quality==`draft`)i.forEach(function(e,t){var n=e.xCoords.map(function(e){return e+E[t].dx}),r=e.yCoords.map(function(e){return e+E[t].dy});e.xCoords=n,e.yCoords=r});else{var D=0;C.forEach(function(e){Object.keys(a[e]).forEach(function(t){var n=a[e][t];n.setCenter(n.getCenterX()+E[D].dx,n.getCenterY()+E[D].dy)}),D++})}}}else{var O=t.eles.boundingBox();if(u.push({x:O.x1+O.w/2,y:O.y1+O.h/2}),t.randomize){var k=s(t);i.push(k)}t.quality=="default"||t.quality==`proof`?(a.push(c(t,i[0])),o.relocateComponent(u[0],a[0],t)):o.relocateComponent(u[0],i[0],t)}}var A=function(e,n){if(t.quality=="default"||t.quality==`proof`){typeof e==`number`&&(e=n);var r=void 0,o=void 0,s=e.data(`id`);return a.forEach(function(e){s in e&&(r={x:e[s].getRect().getCenterX(),y:e[s].getRect().getCenterY()},o=e[s])}),t.nodeDimensionsIncludeLabels&&(o.labelWidth&&(o.labelPosHorizontal==`left`?r.x+=o.labelWidth/2:o.labelPosHorizontal==`right`&&(r.x-=o.labelWidth/2)),o.labelHeight&&(o.labelPosVertical==`top`?r.y+=o.labelHeight/2:o.labelPosVertical==`bottom`&&(r.y-=o.labelHeight/2))),r??={x:e.position(`x`),y:e.position(`y`)},{x:r.x,y:r.y}}var c=void 0;return i.forEach(function(t){var n=t.nodeIndexes.get(e.id());n!=null&&(c={x:t.xCoords[n],y:t.yCoords[n]})}),c??={x:e.position(`x`),y:e.position(`y`)},{x:c.x,y:c.y}};if(t.quality=="default"||t.quality==`proof`||t.randomize){var j=o.calcParentsWithoutChildren(n,r),M=r.filter(function(e){return e.css(`display`)==`none`});t.eles=r.not(M),r.nodes().not(`:parent`).not(M).layoutPositions(e,t,A),j.length>0&&j.forEach(function(e){e.position(A(e))})}else console.log(`If randomize option is set to false, then quality option must be 'default' or 'proof'.`)}}]),e}()}),657:((e,t,n)=>{var r=n(548),i=n(140).layoutBase.Matrix,a=n(140).layoutBase.SVD;e.exports={spectralLayout:function(e){var t=e.cy,n=e.eles,o=n.nodes(),s=n.nodes(`:parent`),c=new Map,l=new Map,u=new Map,d=[],f=[],p=[],m=[],h=[],g=[],_=[],v=[],y=void 0,b=1e8,x=1e-9,S=e.piTol,C=e.samplingType,w=e.nodeSeparation,T=void 0,E=function(){for(var e=0,t=0,n=!1;t=i;){o=r[i++];for(var m=d[o],_=0;_u&&(u=h[x],f=x)}return f},O=function(e){var t=void 0;if(e){t=Math.floor(Math.random()*y);for(var n=0;n=1)break;u=l}for(var h=0;h=1)break;u=l}for(var b=0;b0&&(r.isParent()?d[t].push(u.get(r.id())):d[t].push(r.id()))})});var B=function(e){var n=l.get(e),r=void 0;c.get(e).forEach(function(i){r=t.getElementById(i).isParent()?u.get(i):i,d[n].push(r),d[l.get(r)].push(e)})},V=!0,ee=!1,te=void 0;try{for(var H=c.keys()[Symbol.iterator](),ne;!(V=(ne=H.next()).done);V=!0){var re=ne.value;B(re)}}catch(e){ee=!0,te=e}finally{try{!V&&H.return&&H.return()}finally{if(ee)throw te}}y=l.size;var U=void 0;if(y>2){T=y{var r=n(212),i=function(e){e&&e(`layout`,`fcose`,r)};typeof cytoscape<`u`&&i(cytoscape),e.exports=i}),140:(t=>{t.exports=e})},n={};function r(e){var i=n[e];if(i!==void 0)return i.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,r),a.exports}return r(579)})()})}))(),1),A={L:`left`,R:`right`,T:`top`,B:`bottom`},j={L:i(e=>`${e},${e/2} 0,${e} 0,0`,`L`),R:i(e=>`0,${e/2} ${e},0 ${e},${e}`,`R`),T:i(e=>`0,0 ${e},0 ${e/2},${e}`,`T`),B:i(e=>`${e/2},0 ${e},${e} 0,${e}`,`B`)},M={L:i((e,t)=>e-t+2,`L`),R:i((e,t)=>e-2,`R`),T:i((e,t)=>e-t+2,`T`),B:i((e,t)=>e-2,`B`)},N=i(function(e){return F(e)?e===`L`?`R`:`L`:e===`T`?`B`:`T`},`getOppositeArchitectureDirection`),P=i(function(e){let t=e;return t===`L`||t===`R`||t===`T`||t===`B`},`isArchitectureDirection`),F=i(function(e){let t=e;return t===`L`||t===`R`},`isArchitectureDirectionX`),I=i(function(e){let t=e;return t===`T`||t===`B`},`isArchitectureDirectionY`),L=i(function(e,t){let n=F(e)&&I(t),r=I(e)&&F(t);return n||r},`isArchitectureDirectionXY`),R=i(function(e){let t=e[0],n=e[1],r=F(t)&&I(n),i=I(t)&&F(n);return r||i},`isArchitecturePairXY`),z=i(function(e){return e!==`LL`&&e!==`RR`&&e!==`TT`&&e!==`BB`},`isValidArchitectureDirectionPair`),B=i(function(e,t){let n=`${e}${t}`;return z(n)?n:void 0},`getArchitectureDirectionPair`),V=i(function([e,t],n){let r=n[0],i=n[1];return F(r)?I(i)?[e+(r===`L`?-1:1),t+(i===`T`?1:-1)]:[e+(r===`L`?-1:1),t]:F(i)?[e+(i===`L`?1:-1),t+(r===`T`?1:-1)]:[e,t+(r===`T`?1:-1)]},`shiftPositionByArchitectureDirectionPair`),ee=i(function(e){return e===`LT`||e===`TL`?[1,1]:e===`BL`||e===`LB`?[1,-1]:e===`BR`||e===`RB`?[-1,-1]:[-1,1]},`getArchitectureDirectionXYFactors`),te=i(function(e,t){return L(e,t)?`bend`:F(e)?`horizontal`:`vertical`},`getArchitectureDirectionAlignment`),H=i(function(e){return e.type===`service`},`isArchitectureService`),ne=i(function(e){return e.type===`junction`},`isArchitectureJunction`),re=i((e,t)=>{let[n,r]=[e,t].sort();return`${JSON.stringify(n)}-${JSON.stringify(r)}`},`architectureGroupAlignmentKey`),U=i(e=>e.data(),`edgeData`),W=i(e=>e.data(),`nodeData`),G=u.architecture,ie=class{constructor(){this.nodes=new Map,this.groups=new Map,this.edges=[],this.layoutHints=[],this.registeredIds=new Map,this.elements=new Map,this.diagramId=``,this.setAccTitle=o,this.getAccTitle=h,this.setDiagramTitle=d,this.getDiagramTitle=p,this.getAccDescription=f,this.setAccDescription=a,this.clear()}static{i(this,`ArchitectureDB`)}setDiagramId(e){this.diagramId=e}getDiagramId(){return this.diagramId}clear(){this.nodes=new Map,this.groups=new Map,this.edges=[],this.layoutHints=[],this.registeredIds=new Map,this.dataStructures=void 0,this.elements=new Map,this.diagramId=``,c()}addService({id:e,icon:t,in:n,title:r,iconText:i}){if(this.registeredIds.has(e))throw Error(`The service id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(n!==void 0){if(e===n)throw Error(`The service [${e}] cannot be placed within itself`);if(!this.registeredIds.has(n))throw Error(`The service [${e}]'s parent does not exist. Please make sure the parent is created before this service`);if(this.registeredIds.get(n)===`node`)throw Error(`The service [${e}]'s parent is not a group`)}this.registeredIds.set(e,`node`),this.nodes.set(e,{id:e,type:`service`,icon:t,iconText:i,title:r,edges:[],in:n})}getServices(){return[...this.nodes.values()].filter(H)}addJunction({id:e,in:t}){if(this.registeredIds.has(e))throw Error(`The junction id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(t!==void 0){if(e===t)throw Error(`The junction [${e}] cannot be placed within itself`);if(!this.registeredIds.has(t))throw Error(`The junction [${e}]'s parent does not exist. Please make sure the parent is created before this junction`);if(this.registeredIds.get(t)===`node`)throw Error(`The junction [${e}]'s parent is not a group`)}this.registeredIds.set(e,`node`),this.nodes.set(e,{id:e,type:`junction`,edges:[],in:t})}getJunctions(){return[...this.nodes.values()].filter(ne)}getNodes(){return[...this.nodes.values()]}getNode(e){return this.nodes.get(e)??null}addGroup({id:e,icon:t,in:n,title:r}){if(this.registeredIds.has(e))throw Error(`The group id [${e}] is already in use by another ${this.registeredIds.get(e)}`);if(n!==void 0){if(e===n)throw Error(`The group [${e}] cannot be placed within itself`);if(!this.registeredIds.has(n))throw Error(`The group [${e}]'s parent does not exist. Please make sure the parent is created before this group`);if(this.registeredIds.get(n)===`node`)throw Error(`The group [${e}]'s parent is not a group`)}this.registeredIds.set(e,`group`),this.groups.set(e,{id:e,icon:t,title:r,in:n})}getGroups(){return[...this.groups.values()]}addEdge({lhsId:e,rhsId:t,lhsDir:n,rhsDir:r,lhsInto:i,rhsInto:a,lhsGroup:o,rhsGroup:s,title:c}){if(!P(n))throw Error(`Invalid direction given for left hand side of edge ${e}--${t}. Expected (L,R,T,B) got ${String(n)}`);if(!P(r))throw Error(`Invalid direction given for right hand side of edge ${e}--${t}. Expected (L,R,T,B) got ${String(r)}`);if(!this.nodes.has(e)&&!this.groups.has(e))throw Error(`The left-hand id [${e}] does not yet exist. Please create the service/group before declaring an edge to it.`);if(!this.nodes.has(t)&&!this.groups.has(t))throw Error(`The right-hand id [${t}] does not yet exist. Please create the service/group before declaring an edge to it.`);let l=this.nodes.get(e).in,u=this.nodes.get(t).in;if(o&&l&&u&&l==u)throw Error(`The left-hand id [${e}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);if(s&&l&&u&&l==u)throw Error(`The right-hand id [${t}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);let d={lhsId:e,lhsDir:n,lhsInto:i,lhsGroup:o,rhsId:t,rhsDir:r,rhsInto:a,rhsGroup:s,title:c};this.edges.push(d);let f=this.nodes.get(e),p=this.nodes.get(t);f&&p&&(f.edges.push(this.edges[this.edges.length-1]),p.edges.push(this.edges[this.edges.length-1]))}getEdges(){return this.edges}addLayoutHint(e){if(e.members.length<2)throw Error(`An align directive requires at least two members; got ${e.members.length}`);let t=new Set;e.members.forEach(n=>{if(this.registeredIds.get(n)!==`node`)throw Error(`align ${e.direction} references [${n}], which is not a service or junction`);if(t.has(n))throw Error(`align ${e.direction} lists [${n}] more than once`);t.add(n)}),this.layoutHints.push(e)}getLayoutHints(){return this.layoutHints}getDataStructures(){if(this.dataStructures===void 0){let e=new Map,t=new Map;for(let[n,r]of this.nodes.entries()){let i=new Map;for(let t of r.edges){let r=this.getNode(t.lhsId)?.in,a=this.getNode(t.rhsId)?.in;if(r&&a&&r!==a){let n=te(t.lhsDir,t.rhsDir);n!==`bend`&&e.set(re(r,a),n)}if(t.lhsId===n){let e=B(t.lhsDir,t.rhsDir);e&&i.set(e,t.rhsId)}else{let e=B(t.rhsDir,t.lhsDir);e&&i.set(e,t.lhsId)}}t.set(n,i)}let n=new Set,r=new Set(t.keys()),a=i(e=>{let i=new Map([[e,[0,0]]]),a=[e];for(;a.length>0;){let e=a.shift();if(e){n.add(e),r.delete(e);let o=t.get(e);if(!o)throw Error(`BFS error: adjacency list for id ${e} not found. Please report this as a bug.`);let s=i.get(e);if(!s)throw Error(`BFS error: position for id ${e} not found in spatial map. Please report this as a bug.`);let[c,l]=s;o.forEach((e,t)=>{n.has(e)||(i.set(e,V([c,l],t)),a.push(e))})}}return i},`BFS`),o=[];for(;r.size>0;){let e=r.values().next().value;o.push(a(e))}this.dataStructures={adjList:t,spatialMaps:o,groupAlignments:e}}return this.dataStructures}setElementForId(e,t){this.elements.set(e,t)}getElementById(e){return this.elements.get(e)}getConfig(){return v({...G,...l().architecture})}getConfigField(e){return this.getConfig()[e]}},K=i((e,t)=>{T(e,t),e.groups.map(e=>t.addGroup(e)),e.services.map(e=>t.addService({...e,type:`service`})),e.junctions.map(e=>t.addJunction({...e,type:`junction`})),e.edges.map(e=>t.addEdge(e)),e.alignments?.map(e=>t.addLayoutHint({direction:e.direction,members:[...e.members]}))},`populateDb`),q={parser:{yy:void 0},parse:i(async e=>{let n=await w(`architecture`,e);t.debug(n);let r=q.parser?.yy;if(!(r instanceof ie))throw Error(`parser.parser?.yy was not a ArchitectureDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);K(n,r)},`parse`)},ae=i(e=>` + .edge { + stroke-width: ${e.archEdgeWidth}; + stroke: ${e.archEdgeColor}; + fill: none; + } + + .arrow { + fill: ${e.archEdgeArrowColor}; + } + + .node-bkg { + fill: none; + stroke: ${e.archGroupBorderColor}; + stroke-width: ${e.archGroupBorderWidth}; + stroke-dasharray: 8; + } + .node-icon-text { + display: flex; + align-items: center; + } + + .node-icon-text > div { + color: #fff; + margin: 1px; + height: fit-content; + text-align: center; + overflow: hidden; + display: -webkit-box; + -webkit-box-orient: vertical; + } +`,`getStyles`);function J(e,t){if(e===0)return t();let n=Math.random,r=e>>>0;Math.random=function(){r=r+1831565813>>>0;let e=r;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296};try{return t()}finally{Math.random=n}}i(J,`withSeededRandom`);var Y=i(e=>`${e}`,`wrapIcon`),X={prefix:`mermaid-architecture`,height:80,width:80,icons:{database:{body:Y(``)},server:{body:Y(``)},disk:{body:Y(``)},internet:{body:Y(``)},cloud:{body:Y(``)},unknown:y,blank:{body:Y(``)}}},oe=i(async function(e,t,n,r){let i=n.getConfigField(`padding`),a=n.getConfigField(`iconSize`),o=a/2,s=a/6,c=s/2;await Promise.all(t.edges().map(async t=>{let{source:a,sourceDir:l,sourceArrow:u,sourceGroup:d,target:f,targetDir:p,targetArrow:h,targetGroup:g,label:v}=U(t),{x:y,y:b}=t[0].sourceEndpoint(),{x,y:C}=t[0].midpoint(),{x:w,y:T}=t[0].targetEndpoint(),E=i+4;if(d&&(F(l)?y+=l===`L`?-E:E:b+=l===`T`?-E:E+18),g&&(F(p)?w+=p===`L`?-E:E:T+=p===`T`?-E:E+18),!d&&n.getNode(a)?.type===`junction`&&(F(l)?y+=l===`L`?o:-o:b+=l===`T`?o:-o),!g&&n.getNode(f)?.type===`junction`&&(F(p)?w+=p===`L`?o:-o:T+=p===`T`?o:-o),t[0]._private.rscratch){let t=e.insert(`g`);if(t.insert(`path`).attr(`d`,`M ${y},${b} L ${x},${C} L${w},${T} `).attr(`class`,`edge`).attr(`id`,`${r}-${_(a,f,{prefix:`L`})}`),u){let e=F(l)?M[l](y,s):y-c,n=I(l)?M[l](b,s):b-c;t.insert(`polygon`).attr(`points`,j[l](s)).attr(`transform`,`translate(${e},${n})`).attr(`class`,`arrow`)}if(h){let e=F(p)?M[p](w,s):w-c,n=I(p)?M[p](T,s):T-c;t.insert(`polygon`).attr(`points`,j[p](s)).attr(`transform`,`translate(${e},${n})`).attr(`class`,`arrow`)}if(v){let e=L(l,p)?`XY`:F(l)?`X`:`Y`,n=0;n=e===`X`?Math.abs(y-w):e===`Y`?Math.abs(b-T)/1.5:Math.abs(y-w)/2;let r=t.append(`g`);if(await S(r,v,{useHtmlLabels:!1,width:n,classes:`architecture-service-label`},m()),r.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`),e===`X`)r.attr(`transform`,`translate(`+x+`, `+C+`)`);else if(e===`Y`)r.attr(`transform`,`translate(`+x+`, `+C+`) rotate(-90)`);else if(e===`XY`){let e=B(l,p);if(e&&R(e)){let t=r.node().getBoundingClientRect(),[n,i]=ee(e);r.attr(`dominant-baseline`,`auto`).attr(`transform`,`rotate(${-1*n*i*45})`);let a=r.node().getBoundingClientRect();r.attr(`transform`,` + translate(${x}, ${C-t.height/2}) + translate(${n*a.width/2}, ${i*a.height/2}) + rotate(${-1*n*i*45}, 0, ${t.height/2}) + `)}}}}}))},`drawEdges`),Z=i(async function(e,t,n,r){let i=n.getConfigField(`padding`)*.75,a=n.getConfigField(`fontSize`),o=n.getConfigField(`iconSize`)/2;await Promise.all(t.nodes().map(async t=>{let s=W(t);if(s.type===`group`){let{h:c,w:l,x1:u,y1:d}=t.boundingBox(),f=e.append(`rect`);f.attr(`id`,`${r}-group-${s.id}`).attr(`x`,u+o).attr(`y`,d+o).attr(`width`,l).attr(`height`,c).attr(`class`,`node-bkg`);let p=e.append(`g`),h=u,g=d;if(s.icon){let e=p.append(`g`);e.html(`${await x(s.icon,{height:i,width:i,fallbackPrefix:X.prefix})}`),e.attr(`transform`,`translate(`+(h+o+1)+`, `+(g+o+1)+`)`),h+=i,g+=a/2-1-2}if(s.label){let e=p.append(`g`);await S(e,s.label,{useHtmlLabels:!1,width:l,classes:`architecture-service-label`},m()),e.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`start`).attr(`text-anchor`,`start`),e.attr(`transform`,`translate(`+(h+o+4)+`, `+(g+o+2)+`)`)}n.setElementForId(s.id,f)}}))},`drawGroups`),se=i(async function(e,t,n,r){let i=m();for(let a of n){let n=t.append(`g`),o=e.getConfigField(`iconSize`);if(a.title){let e=n.append(`g`);await S(e,a.title,{useHtmlLabels:!1,width:o*1.5,classes:`architecture-service-label`},i),e.attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`),e.attr(`transform`,`translate(`+o/2+`, `+o+`)`)}let s=n.append(`g`);if(a.icon)s.html(`${await x(a.icon,{height:o,width:o,fallbackPrefix:X.prefix})}`);else if(a.iconText){s.html(`${await x(`blank`,{height:o,width:o,fallbackPrefix:X.prefix})}`);let e=s.append(`g`).append(`foreignObject`).attr(`width`,o).attr(`height`,o).append(`div`).attr(`class`,`node-icon-text`).attr(`style`,`height: ${o}px;`).append(`div`).html(g(a.iconText,i)),t=parseInt(window.getComputedStyle(e.node(),null).getPropertyValue(`font-size`).replace(/\D/g,``))??16;e.attr(`style`,`-webkit-line-clamp: ${Math.floor((o-2)/t)};`)}else s.append(`path`).attr(`class`,`node-bkg`).attr(`id`,`${r}-node-${a.id}`).attr(`d`,`M0,${o} V5 Q0,0 5,0 H${o-5} Q${o},0 ${o},5 V${o} Z`);n.attr(`id`,`${r}-service-${a.id}`).attr(`class`,`architecture-service`);let{width:c,height:l}=n.node().getBBox();a.width=c,a.height=l,e.setElementForId(a.id,n)}return 0},`drawServices`),ce=i(function(e,t,n,r){n.forEach(n=>{let i=t.append(`g`),a=e.getConfigField(`iconSize`);i.append(`g`).append(`rect`).attr(`id`,`${r}-node-${n.id}`).attr(`fill-opacity`,`0`).attr(`width`,a).attr(`height`,a),i.attr(`class`,`architecture-junction`);let{width:o,height:s}=i._groups[0][0].getBBox();i.width=o,i.height=s,e.setElementForId(n.id,i)})},`drawJunctions`);b([{name:X.prefix,icons:X}]),E.use(k.default);function le(e,t,n){e.forEach(e=>{t.add({group:`nodes`,data:{type:`service`,id:e.id,icon:e.icon,label:e.title,parent:e.in,width:n.getConfigField(`iconSize`),height:n.getConfigField(`iconSize`)},classes:`node-service`})})}i(le,`addServices`);function ue(e,t,n){e.forEach(e=>{t.add({group:`nodes`,data:{type:`junction`,id:e.id,parent:e.in,width:n.getConfigField(`iconSize`),height:n.getConfigField(`iconSize`)},classes:`node-junction`})})}i(ue,`addJunctions`);function de(e,t){t.nodes().map(t=>{let n=W(t);n.type!==`group`&&(n.x=t.position().x,n.y=t.position().y,e.getElementById(n.id).attr(`transform`,`translate(`+(n.x||0)+`,`+(n.y||0)+`)`))})}i(de,`positionNodes`);function fe(e,t){e.forEach(e=>{t.add({group:`nodes`,data:{type:`group`,id:e.id,icon:e.icon,label:e.title,parent:e.in},classes:`node-group`})})}i(fe,`addGroups`);function pe(e,t){e.forEach(e=>{let{lhsId:n,rhsId:r,lhsInto:i,lhsGroup:a,rhsInto:o,lhsDir:s,rhsDir:c,rhsGroup:l,title:u}=e,d=L(e.lhsDir,e.rhsDir)?`segments`:`straight`,f={id:`${n}-${r}`,label:u,source:n,sourceDir:s,sourceArrow:i,sourceGroup:a,sourceEndpoint:s===`L`?`0 50%`:s===`R`?`100% 50%`:s===`T`?`50% 0`:`50% 100%`,target:r,targetDir:c,targetArrow:o,targetGroup:l,targetEndpoint:c===`L`?`0 50%`:c===`R`?`100% 50%`:c===`T`?`50% 0`:`50% 100%`};t.add({group:`edges`,data:f,classes:d})})}i(pe,`addEdges`);function me(e,t,n,r=[]){let a=i((e,t)=>{let r=new Map;for(let[i,a]of e.entries()){let e=`${i}`,o=0,s=[...a.entries()];if(s.length===1){r.set(e,s[0][1]);continue}for(let i=0;i{let n=new Map,r=new Map;return t.forEach(([t,i],a)=>{let o=e.getNode(a)?.in??`default`,s=n.get(i)??new Map;n.has(i)||n.set(i,s);let c=r.get(t)??new Map;r.has(t)||r.set(t,c);for(let e of[s,c]){let t=e.get(o)??[];e.has(o)||e.set(o,t),t.push(a)}}),{horiz:[...a(n,`horizontal`).values()].filter(e=>e.length>1),vert:[...a(r,`vertical`).values()].filter(e=>e.length>1)}}).reduce(([e,t],{horiz:n,vert:r})=>[[...e,...n],[...t,...r]],[[],[]]),c=new Set;r.forEach(e=>e.members.forEach(e=>c.add(e)));let l=i(e=>e.filter(e=>!e.some(e=>c.has(e))),`dropOverlapping`),u=l(o),d=l(s);return r.forEach(e=>{e.members.length<2||(e.direction===`row`?u.push([...e.members]):d.push([...e.members]))}),{horizontal:u,vertical:d}}i(me,`getAlignments`);function he(e,t,n=[]){let r=[],a=t.getConfigField(`iconSize`),o=t.getConfigField(`idealEdgeLengthMultiplier`),s=o*a,c=new Set;n.forEach(e=>{for(let t=0;t`${e[0]},${e[1]}`,`posToStr`),u=i(e=>e.split(`,`).map(e=>parseInt(e)),`strToPos`);return e.forEach(e=>{let t=new Map([...e.entries()].map(([e,t])=>[l(t),e])),n=[l([0,0])],i={},s={L:[-1,0],R:[1,0],T:[0,1],B:[0,-1]};for(;n.length>0;){let e=n.shift();if(e){i[e]=1;let d=t.get(e);if(d){let f=u(e);Object.entries(s).forEach(([e,s])=>{let u=l([f[0]+s[0],f[1]+s[1]]),p=t.get(u);if(p&&!i[u]){if(n.push(u),c.has(`${d}|${p}`))return;r.push({[A[e]]:p,[A[N(e)]]:d,gap:o*a})}})}}}}),r}i(he,`getRelativeConstraints`);function ge(e,r,a,o,s,{spatialMaps:c,groupAlignments:l}){return new Promise(u=>{let d=n(`body`).append(`div`).attr(`id`,`cy`).attr(`style`,`display:none`),f=E({container:document.getElementById(`cy`),style:[{selector:`edge`,style:{"curve-style":`straight`,"source-endpoint":`data(sourceEndpoint)`,"target-endpoint":`data(targetEndpoint)`}},{selector:`edge[label]`,style:{label:`data(label)`}},{selector:`edge.segments`,style:{"curve-style":`segments`,"segment-weights":`0`,"segment-distances":[.5],"edge-distances":`endpoints`,"source-endpoint":`data(sourceEndpoint)`,"target-endpoint":`data(targetEndpoint)`}},{selector:`node`,style:{"compound-sizing-wrt-labels":`include`}},{selector:`node[label]`,style:{"text-valign":`bottom`,"text-halign":`center`,"font-size":`${s.getConfigField(`fontSize`)}px`}},{selector:`.node-service`,style:{label:`data(label)`,width:`data(width)`,height:`data(height)`}},{selector:`.node-junction`,style:{width:`data(width)`,height:`data(height)`}},{selector:`.node-group`,style:{padding:`${s.getConfigField(`padding`)}px`}}],layout:{name:`grid`,boundingBox:{x1:0,x2:100,y1:0,y2:100}}});d.remove(),fe(a,f),le(e,f,s),ue(r,f,s),pe(o,f);let p=s.getLayoutHints(),m=me(s,c,l,p),h=he(c,s,p),g=s.getConfigField(`iconSize`),_=s.getConfigField(`idealEdgeLengthMultiplier`)*g,v=.5*g,y=s.getConfigField(`edgeElasticity`),b=s.getConfigField(`seed`),x=f.layout({name:`fcose`,quality:`proof`,randomize:s.getConfigField(`randomize`),nodeSeparation:s.getConfigField(`nodeSeparation`),numIter:s.getConfigField(`numIter`),styleEnabled:!1,animate:!1,nodeDimensionsIncludeLabels:!1,idealEdgeLength(e){let[t,n]=e.connectedNodes(),{parent:r}=W(t),{parent:i}=W(n);return r===i?_:v},edgeElasticity(e){let[t,n]=e.connectedNodes(),{parent:r}=W(t),{parent:i}=W(n);return r===i?y:.001},alignmentConstraint:m,relativePlacementConstraint:h});x.one(`layoutstop`,()=>{function e(e,t,n,r){let i,a,{x:o,y:s}=e,{x:c,y:l}=t;a=(r-s+(o-n)*(s-l)/(o-c))/Math.sqrt(1+((s-l)/(o-c))**2),i=Math.sqrt((r-s)**2+(n-o)**2-a**2);let u=Math.sqrt((c-o)**2+(l-s)**2);i/=u;let d=(c-o)*(r-s)-(l-s)*(n-o);switch(!0){case d>=0:d=1;break;case d<0:d=-1}let f=(c-o)*(n-o)+(l-s)*(r-s);switch(!0){case f>=0:f=1;break;case f<0:f=-1}return a=Math.abs(a)*d,i*=f,{distances:a,weights:i}}i(e,`getSegmentWeights`),f.startBatch();for(let t of Object.values(f.edges()))if(t.data?.()){let{x:n,y:r}=t.source().position(),{x:i,y:a}=t.target().position();if(n!==i&&r!==a){let n=t.sourceEndpoint(),r=t.targetEndpoint(),{sourceDir:i}=U(t),[a,o]=I(i)?[n.x,r.y]:[r.x,n.y],{weights:s,distances:c}=e(n,r,a,o);t.style(`segment-distances`,c),t.style(`segment-weights`,s)}}f.endBatch(),J(b,()=>x.run())});try{J(b,()=>x.run())}catch(e){throw e instanceof RangeError&&e.message.includes(`Invalid array length`)?Error("Architecture layout failed: a declared `align row|column` directive likely contradicts the edge directions, or two declared alignments overlap on a shared node. Check that the order of members in each `align` chain is consistent with the edges between them, and that no node appears in two `align` directives along the same axis."):e}f.ready(e=>{t.info(`Ready`,e),u(f)})})}i(ge,`layoutArchitecture`);var _e={parser:q,get db(){return new ie},renderer:{draw:i(async(e,t,n,r)=>{let i=r.db;i.setDiagramId(t);let a=i.getServices(),o=i.getJunctions(),c=i.getGroups(),l=i.getEdges(),u=i.getDataStructures(),d=C(t),f=d.append(`g`);f.attr(`class`,`architecture-edges`);let p=d.append(`g`);p.attr(`class`,`architecture-services`);let m=d.append(`g`);m.attr(`class`,`architecture-groups`),await se(i,p,a,t),ce(i,p,o,t);let h=await ge(a,o,c,l,i,u);await oe(f,h,i,t),await Z(m,h,i,t),de(i,h),s(void 0,d,i.getConfigField(`padding`),i.getConfigField(`useMaxWidth`))},`draw`)},styles:ae};export{_e as diagram}; \ No newline at end of file diff --git a/www/assets/array-BifhSqXX.js b/www/assets/array-BifhSqXX.js new file mode 100644 index 0000000..b0a084a --- /dev/null +++ b/www/assets/array-BifhSqXX.js @@ -0,0 +1 @@ +Array.prototype.slice;function e(e){return typeof e==`object`&&`length`in e?e:Array.from(e)}export{e as t}; \ No newline at end of file diff --git a/www/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js b/www/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js new file mode 100644 index 0000000..90e752b --- /dev/null +++ b/www/assets/blockDiagram-BEXU5L5S-LcLXSRjx.js @@ -0,0 +1,140 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{a as r,b as i,c as a,ot as o,s,x as c}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as l}from"./channel-_oCHZhRo.js";import{A as u,B as d,C as f,D as p,E as m,F as h,G as g,H as _,I as v,L as y,M as b,N as x,O as S,P as C,R as w,T,U as E,V as D,W as O,b as k,j as A,k as j,l as M,v as ee,w as te,z as ne}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as re,n as ie,o as ae,r as oe,s as se}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as ce,r as N}from"./chunk-5DYCD2WN-WToj2Jza.js";import{d as le,g as ue,o as de,s as fe,u as pe}from"./index-DoQkmpth.js";import{t as me}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as he}from"./graphlib-C9Tl7QrK.js";function ge(e){return Array.isArray(e)}function _e(e){if(k(e))return e;let t=g(e);if(!ve(e))return{};if(ge(e)){let t=Array.from(e);return e.length>0&&typeof e[0]==`string`&&Object.hasOwn(e,`index`)&&(t.index=e.index,t.input=e.input),t}if(ee(e)){let t=e,n=t.constructor;return new n(t.buffer,t.byteOffset,t.length)}if(t===`[object ArrayBuffer]`)return new ArrayBuffer(e.byteLength);if(t===`[object DataView]`){let t=e,n=t.buffer,r=t.byteOffset,i=t.byteLength,a=new ArrayBuffer(i),o=new Uint8Array(n,r,i);return new Uint8Array(a).set(o),new DataView(a)}if(t===`[object Boolean]`||t===`[object Number]`||t===`[object String]`){let n=e.constructor,r=new n(e.valueOf());return t===`[object String]`?be(r,e):P(r,e),r}if(t===`[object Date]`)return new Date(Number(e));if(t===`[object RegExp]`){let t=e,n=new RegExp(t.source,t.flags);return n.lastIndex=t.lastIndex,n}if(t===`[object Symbol]`)return Object(Symbol.prototype.valueOf.call(e));if(t===`[object Map]`){let t=e,n=new Map;return t.forEach((e,t)=>{n.set(t,e)}),n}if(t===`[object Set]`){let t=e,n=new Set;return t.forEach(e=>{n.add(e)}),n}if(t===`[object Arguments]`){let t=e,n={};return P(n,t),n.length=t.length,n[Symbol.iterator]=t[Symbol.iterator],n}let n={};return xe(n,e),P(n,e),ye(n,e),n}function ve(e){switch(g(e)){case f:case T:case te:case p:case m:case S:case j:case u:case x:case A:case b:case C:case h:case v:case y:case w:case ne:case d:case E:case O:case D:case _:return!0;default:return!1}}function P(e,t){for(let n in t)Object.hasOwn(t,n)&&(e[n]=t[n])}function ye(e,t){let n=Object.getOwnPropertySymbols(t);for(let r=0;r=n)&&(e[r]=t[r])}function xe(e,t){let n=Object.getPrototypeOf(t);n!==null&&typeof t.constructor==`function`&&Object.setPrototypeOf(e,n)}var F=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,15],r=[1,7],i=[1,13],a=[1,14],o=[1,19],s=[1,16],c=[1,17],l=[1,18],u=[8,30],d=[8,10,21,28,29,30,31,39,43,46],f=[1,23],p=[1,24],m=[8,10,15,16,21,28,29,30,31,39,43,46],h=[8,10,15,16,21,27,28,29,30,31,39,43,46],g=[1,49],_={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACELINE`,5:`NL`,7:`SPACE`,8:`EOF`,10:`BLOCK_DIAGRAM_KEY`,15:`LINK`,16:`START_LINK`,17:`LINK_LABEL`,18:`STR`,21:`SPACE_BLOCK`,27:`SIZE`,28:`COLUMNS`,29:`id-block`,30:`end`,31:`NODE_ID`,34:`DIR`,35:`NODE_DSTART`,36:`NODE_DEND`,37:`BLOCK_ARROW_START`,38:`BLOCK_ARROW_END`,39:`classDef`,40:`CLASSDEF_ID`,41:`CLASSDEF_STYLEOPTS`,42:`DEFAULT`,43:`class`,44:`CLASSENTITY_IDS`,45:`STYLECLASS`,46:`style`,47:`STYLE_ENTITY_IDS`,48:`STYLE_DEFINITION_DATA`},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:r.getLogger().debug(`Rule: separator (NL) `);break;case 5:r.getLogger().debug(`Rule: separator (Space) `);break;case 6:r.getLogger().debug(`Rule: separator (EOF) `);break;case 7:r.getLogger().debug(`Rule: hierarchy: `,a[s-1]),r.setHierarchy(a[s-1]);break;case 8:r.getLogger().debug(`Stop NL `);break;case 9:r.getLogger().debug(`Stop EOF `);break;case 10:r.getLogger().debug(`Stop NL2 `);break;case 11:r.getLogger().debug(`Stop EOF2 `);break;case 12:r.getLogger().debug(`Rule: statement: `,a[s]),this.$=typeof a[s].length==`number`?a[s]:[a[s]];break;case 13:r.getLogger().debug(`Rule: statement #2: `,a[s-1]),this.$=[a[s-1]].concat(a[s]);break;case 14:r.getLogger().debug(`Rule: link: `,a[s],e),this.$={edgeTypeStr:a[s],label:``};break;case 15:r.getLogger().debug(`Rule: LABEL link: `,a[s-3],a[s-1],a[s]),this.$={edgeTypeStr:a[s],label:a[s-1]};break;case 18:let t=parseInt(a[s]),n=r.generateId();this.$={id:n,type:`space`,label:``,width:t,children:[]};break;case 23:r.getLogger().debug(`Rule: (nodeStatement link node) `,a[s-2],a[s-1],a[s],` typestr: `,a[s-1].edgeTypeStr);let i=r.edgeStrToEdgeData(a[s-1].edgeTypeStr),o=r.edgeStrToEdgeStartData(a[s-1].edgeTypeStr),c=r.edgeStrToThickness(a[s-1].edgeTypeStr),l=r.edgeStrToPattern(a[s-1].edgeTypeStr);this.$=[{id:a[s-2].id,label:a[s-2].label,type:a[s-2].type,directions:a[s-2].directions},{id:a[s-2].id+`-`+a[s].id,start:a[s-2].id,end:a[s].id,label:a[s-1].label,type:`edge`,thickness:c,pattern:l,directions:a[s].directions,arrowTypeEnd:i,arrowTypeStart:o},{id:a[s].id,label:a[s].label,type:r.typeStr2Type(a[s].typeStr),directions:a[s].directions}];break;case 24:r.getLogger().debug(`Rule: nodeStatement (abc88 node size) `,a[s-1],a[s]),this.$={id:a[s-1].id,label:a[s-1].label,type:r.typeStr2Type(a[s-1].typeStr),directions:a[s-1].directions,widthInColumns:parseInt(a[s],10)};break;case 25:r.getLogger().debug(`Rule: nodeStatement (node) `,a[s]),this.$={id:a[s].id,label:a[s].label,type:r.typeStr2Type(a[s].typeStr),directions:a[s].directions,widthInColumns:1};break;case 26:r.getLogger().debug(`APA123`,this?this:`na`),r.getLogger().debug(`COLUMNS: `,a[s]),this.$={type:`column-setting`,columns:a[s]===`auto`?-1:parseInt(a[s])};break;case 27:r.getLogger().debug(`Rule: id-block statement : `,a[s-2],a[s-1]),r.generateId(),this.$={...a[s-2],type:`composite`,children:a[s-1]};break;case 28:r.getLogger().debug(`Rule: blockStatement : `,a[s-2],a[s-1],a[s]);let u=r.generateId();this.$={id:u,type:`composite`,label:``,children:a[s-1]};break;case 29:r.getLogger().debug(`Rule: node (NODE_ID separator): `,a[s]),this.$={id:a[s]};break;case 30:r.getLogger().debug(`Rule: node (NODE_ID nodeShapeNLabel separator): `,a[s-1],a[s]),this.$={id:a[s-1],label:a[s].label,typeStr:a[s].typeStr,directions:a[s].directions};break;case 31:r.getLogger().debug(`Rule: dirList: `,a[s]),this.$=[a[s]];break;case 32:r.getLogger().debug(`Rule: dirList: `,a[s-1],a[s]),this.$=[a[s-1]].concat(a[s]);break;case 33:r.getLogger().debug(`Rule: nodeShapeNLabel: `,a[s-2],a[s-1],a[s]),this.$={typeStr:a[s-2]+a[s],label:a[s-1]};break;case 34:r.getLogger().debug(`Rule: BLOCK_ARROW nodeShapeNLabel: `,a[s-3],a[s-2],` #3:`,a[s-1],a[s]),this.$={typeStr:a[s-3]+a[s],label:a[s-2],directions:a[s-1]};break;case 35:case 36:this.$={type:`classDef`,id:a[s-1].trim(),css:a[s].trim()};break;case 37:this.$={type:`applyClass`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 38:this.$={type:`applyStyles`,id:a[s-1].trim(),stylesStr:a[s].trim()}}},`anonymous`),table:[{9:1,10:[1,2]},{1:[3]},{10:t,11:3,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{8:[1,20]},e(u,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:t,21:r,28:i,29:a,31:o,39:s,43:c,46:l}),e(d,[2,16],{14:22,15:f,16:p}),e(d,[2,17]),e(d,[2,18]),e(d,[2,19]),e(d,[2,20]),e(d,[2,21]),e(d,[2,22]),e(m,[2,25],{27:[1,25]}),e(d,[2,26]),{19:26,26:12,31:o},{10:t,11:27,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(h,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(u,[2,13]),{26:35,31:o},{31:[2,14]},{17:[1,36]},e(m,[2,24]),{10:t,11:37,13:4,14:22,15:f,16:p,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:i,29:a,31:o,39:s,43:c,46:l},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(h,[2,30]),{18:[1,43]},{18:[1,44]},e(m,[2,23]),{18:[1,45]},{30:[1,46]},e(d,[2,28]),e(d,[2,35]),e(d,[2,36]),e(d,[2,37]),e(d,[2,38]),{36:[1,47]},{33:48,34:g},{15:[1,50]},e(d,[2,27]),e(h,[2,33]),{38:[1,51]},{33:52,34:g,38:[2,31]},{31:[2,15]},e(h,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};_.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return e.getLogger().debug(`Found block-beta`),10;case 1:return e.getLogger().debug(`Found id-block`),29;case 2:return e.getLogger().debug(`Found block`),10;case 3:e.getLogger().debug(`.`,t.yytext);break;case 4:e.getLogger().debug(`_`,t.yytext);break;case 5:return 5;case 6:return t.yytext=-1,28;case 7:return t.yytext=t.yytext.replace(/columns\s+/,``),e.getLogger().debug(`COLUMNS (LEX)`,t.yytext),28;case 8:this.pushState(`md_string`);break;case 9:return`MD_STR`;case 10:this.popState();break;case 11:this.pushState(`string`);break;case 12:e.getLogger().debug(`LEX: POPPING STR:`,t.yytext),this.popState();break;case 13:return e.getLogger().debug(`LEX: STR end:`,t.yytext),`STR`;case 14:return t.yytext=t.yytext.replace(/space\:/,``),e.getLogger().debug(`SPACE NUM (LEX)`,t.yytext),21;case 15:return t.yytext=`1`,e.getLogger().debug(`COLUMNS (LEX)`,t.yytext),21;case 16:return 42;case 17:return`LINKSTYLE`;case 18:return`INTERPOLATE`;case 19:return this.pushState(`CLASSDEF`),39;case 20:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 21:return this.popState(),this.pushState(`CLASSDEFID`),40;case 22:return this.popState(),41;case 23:return this.pushState(`CLASS`),43;case 24:return this.popState(),this.pushState(`CLASS_STYLE`),44;case 25:return this.popState(),45;case 26:return this.pushState(`STYLE_STMNT`),46;case 27:return this.popState(),this.pushState(`STYLE_DEFINITION`),47;case 28:return this.popState(),48;case 29:return this.pushState(`acc_title`),`acc_title`;case 30:return this.popState(),`acc_title_value`;case 31:return this.pushState(`acc_descr`),`acc_descr`;case 32:return this.popState(),`acc_descr_value`;case 33:this.pushState(`acc_descr_multiline`);break;case 34:this.popState();break;case 35:return`acc_descr_multiline_value`;case 36:return 30;case 37:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 38:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 39:return this.popState(),e.getLogger().debug(`Lex: ))`),`NODE_DEND`;case 40:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 41:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 42:return this.popState(),e.getLogger().debug(`Lex: (-`),`NODE_DEND`;case 43:return this.popState(),e.getLogger().debug(`Lex: -)`),`NODE_DEND`;case 44:return this.popState(),e.getLogger().debug(`Lex: ((`),`NODE_DEND`;case 45:return this.popState(),e.getLogger().debug(`Lex: ]]`),`NODE_DEND`;case 46:return this.popState(),e.getLogger().debug(`Lex: (`),`NODE_DEND`;case 47:return this.popState(),e.getLogger().debug(`Lex: ])`),`NODE_DEND`;case 48:return this.popState(),e.getLogger().debug(`Lex: /]`),`NODE_DEND`;case 49:return this.popState(),e.getLogger().debug(`Lex: /]`),`NODE_DEND`;case 50:return this.popState(),e.getLogger().debug(`Lex: )]`),`NODE_DEND`;case 51:return this.popState(),e.getLogger().debug(`Lex: )`),`NODE_DEND`;case 52:return this.popState(),e.getLogger().debug(`Lex: ]>`),`NODE_DEND`;case 53:return this.popState(),e.getLogger().debug(`Lex: ]`),`NODE_DEND`;case 54:return e.getLogger().debug(`Lexa: -)`),this.pushState(`NODE`),35;case 55:return e.getLogger().debug(`Lexa: (-`),this.pushState(`NODE`),35;case 56:return e.getLogger().debug(`Lexa: ))`),this.pushState(`NODE`),35;case 57:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 58:return e.getLogger().debug(`Lex: (((`),this.pushState(`NODE`),35;case 59:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 60:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 61:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 62:return e.getLogger().debug(`Lexc: >`),this.pushState(`NODE`),35;case 63:return e.getLogger().debug(`Lexa: ([`),this.pushState(`NODE`),35;case 64:return e.getLogger().debug(`Lexa: )`),this.pushState(`NODE`),35;case 65:return this.pushState(`NODE`),35;case 66:return this.pushState(`NODE`),35;case 67:return this.pushState(`NODE`),35;case 68:return this.pushState(`NODE`),35;case 69:return this.pushState(`NODE`),35;case 70:return this.pushState(`NODE`),35;case 71:return this.pushState(`NODE`),35;case 72:return e.getLogger().debug(`Lexa: [`),this.pushState(`NODE`),35;case 73:return this.pushState(`BLOCK_ARROW`),e.getLogger().debug(`LEX ARR START`),37;case 74:return e.getLogger().debug(`Lex: NODE_ID`,t.yytext),31;case 75:return e.getLogger().debug(`Lex: EOF`,t.yytext),8;case 76:this.pushState(`md_string`);break;case 77:this.pushState(`md_string`);break;case 78:return`NODE_DESCR`;case 79:this.popState();break;case 80:e.getLogger().debug(`Lex: Starting string`),this.pushState(`string`);break;case 81:e.getLogger().debug(`LEX ARR: Starting string`),this.pushState(`string`);break;case 82:return e.getLogger().debug(`LEX: NODE_DESCR:`,t.yytext),`NODE_DESCR`;case 83:e.getLogger().debug(`LEX POPPING`),this.popState();break;case 84:e.getLogger().debug(`Lex: =>BAE`),this.pushState(`ARROW_DIR`);break;case 85:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (right): dir:`,t.yytext),`DIR`;case 86:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (left):`,t.yytext),`DIR`;case 87:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (x):`,t.yytext),`DIR`;case 88:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (y):`,t.yytext),`DIR`;case 89:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (up):`,t.yytext),`DIR`;case 90:return t.yytext=t.yytext.replace(/^,\s*/,``),e.getLogger().debug(`Lex (down):`,t.yytext),`DIR`;case 91:return t.yytext=`]>`,e.getLogger().debug(`Lex (ARROW_DIR end):`,t.yytext),this.popState(),this.popState(),`BLOCK_ARROW_END`;case 92:return e.getLogger().debug(`Lex: LINK`,`#`+t.yytext+`#`),15;case 93:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 94:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 95:return e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 96:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 97:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 98:return e.getLogger().debug(`Lex: START_LINK`,t.yytext),this.pushState(`LLABEL`),16;case 99:this.pushState(`md_string`);break;case 100:return e.getLogger().debug(`Lex: Starting string`),this.pushState(`string`),`LINK_LABEL`;case 101:return this.popState(),e.getLogger().debug(`Lex: LINK`,`#`+t.yytext+`#`),15;case 102:return this.popState(),e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 103:return this.popState(),e.getLogger().debug(`Lex: LINK`,t.yytext),15;case 104:return e.getLogger().debug(`Lex: COLON`,t.yytext),t.yytext=t.yytext.slice(1),27}},`anonymous`),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}}})();function v(){this.yy={}}return n(v,`Parser`),v.prototype=_,_.Parser=v,new v})();F.parser=F;var Se=F,I=new Map,L=[],R=new Map,z=`color`,B=`fill`,Ce=`bgFill`,we=`,`,V=new Map,H=``,Te=n(e=>s.sanitizeText(e,c()),`sanitizeText`),Ee=n(function(e,t=``){let n=V.get(e);n||(n={id:e,styles:[],textStyles:[]},V.set(e,n)),t?.split(we).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(z).exec(e)){let e=t.replace(B,Ce).replace(z,B);n.textStyles.push(e)}n.styles.push(t)})},`addStyleClass`),De=n(function(e,t=``){let n=I.get(e);t!=null&&(n.styles=t.split(we))},`addStyle2Node`),Oe=n(function(e,t){e.split(`,`).forEach(function(e){let n=I.get(e);if(n===void 0){let t=e.trim();n={id:t,type:`na`,children:[]},I.set(t,n)}n.classes||(n.classes=[]),n.classes.push(t)})},`setCssClass`),U=0,ke=n((t,n)=>{let r=t.flat(),i=[],a=r.find(e=>e?.type===`column-setting`)?.columns??-1;for(let t of r){if(typeof a==`number`&&a>0&&t.type!==`column-setting`&&typeof t.widthInColumns==`number`&&t.widthInColumns>a&&e.warn(`Block ${t.id} width ${t.widthInColumns} exceeds configured column width ${a}`),t.label&&=Te(t.label),t.type===`classDef`){Ee(t.id,t.css);continue}if(t.type===`applyClass`){Oe(t.id,t?.styleClass??``);continue}if(t.type===`applyStyles`){t?.stylesStr&&De(t.id,t?.stylesStr);continue}if(t.type===`column-setting`)n.columns=t.columns??-1;else if(t.type===`edge`){let e=(R.get(t.id)??0)+1;R.set(t.id,e),t.id=e+`-`+t.id,L.push(t)}else{t.label||=t.type===`composite`?``:t.id;let e=I.get(t.id);if(e===void 0?(t.type===`composite`&&(t.colorIndex=U++),I.set(t.id,t)):(t.type!==`na`&&(e.type=t.type),t.label!==t.id&&(e.label=t.label)),t.children&&ke(t.children,t),t.type===`space`){let e=t.width??1;for(let n=0;n{e.debug(`Clear called`),r(),G={id:`root`,type:`composite`,children:[],columns:-1},I=new Map([[`root`,G]]),W=[],V=new Map,L=[],R=new Map,H=``,U=0},`clear`);function je(t){switch(e.debug(`typeStr2Type`,t),t){case`[]`:return`square`;case`()`:return e.debug(`we have a round`),`round`;case`(())`:return`circle`;case`>]`:return`rect_left_inv_arrow`;case`{}`:return`diamond`;case`{{}}`:return`hexagon`;case`([])`:return`stadium`;case`[[]]`:return`subroutine`;case`[()]`:return`cylinder`;case`((()))`:return`doublecircle`;case`[//]`:return`lean_right`;case`[\\\\]`:return`lean_left`;case`[/\\]`:return`trapezoid`;case`[\\/]`:return`inv_trapezoid`;case`<[]>`:return`block_arrow`;default:return`na`}}n(je,`typeStr2Type`);function Me(t){switch(e.debug(`typeStr2Type`,t),t){case`==`:return`thick`;default:return`normal`}}n(Me,`edgeTypeStr2Type`);function Ne(e){switch(e.trim().slice(-1)){case`x`:return`arrow_cross`;case`o`:return`arrow_circle`;case`>`:return`arrow_point`;default:return``}}n(Ne,`edgeStrToEdgeData`);function Pe(e){switch(e.trim().charAt(0)){case`x`:return`arrow_cross`;case`o`:return`arrow_circle`;case`<`:return`arrow_point`;default:return`arrow_open`}}n(Pe,`edgeStrToEdgeStartData`);function Fe(e){return e.includes(`==`)?`thick`:`normal`}n(Fe,`edgeStrToThickness`);function Ie(e){return e.includes(`.-`)?`dotted`:`solid`}n(Ie,`edgeStrToPattern`);var Le=0,Re={getConfig:n(()=>i().block,`getConfig`),typeStr2Type:je,edgeTypeStr2Type:Me,edgeStrToEdgeData:Ne,edgeStrToEdgeStartData:Pe,edgeStrToThickness:Fe,edgeStrToPattern:Ie,getLogger:n(()=>e,`getLogger`),getBlocksFlat:n(()=>[...I.values()],`getBlocksFlat`),getBlocks:n(()=>W||[],`getBlocks`),getEdges:n(()=>L,`getEdges`),setHierarchy:n(e=>{G.children=e,ke(e,G),W=G.children},`setHierarchy`),getBlock:n(e=>I.get(e),`getBlock`),setBlock:n(e=>{I.set(e.id,e)},`setBlock`),getColumns:n(e=>{let t=I.get(e);return t?t.columns?t.columns:t.children?t.children.length:-1:-1},`getColumns`),getClasses:n(function(){return V},`getClasses`),clear:Ae,generateId:n(()=>(Le++,`id-`+Math.random().toString(36).substr(2,12)+`-`+Le),`generateId`),setDiagramId:n(e=>{H=e},`setDiagramId`),getDiagramId:n(()=>H,`getDiagramId`)},ze=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!re(t,r))return``;let i=ae(e.look),a=oe(n),o=``;for(let t=0;t{let n=l,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return o(r,i,a,t)},`fade`),Be=n(e=>`${ze(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + + + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + /* From the theme, as every other diagram does. Pinned at 1px here, so block drew a + thinner border than an identical flowchart node under any theme asking for more -- + the neo theme asks for 2. Nothing downstream corrected it: the neo rules set stroke + and filter, never stroke-width. */ + stroke-width: ${e.strokeWidth??1}px; + } + .flowchart-label text { + text-anchor: middle; + } + // .flowchart-label .text-outer-tspan { + // text-anchor: middle; + // } + // .flowchart-label .text-inner-tspan { + // text-anchor: start; + // } + + .node .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: 2.0px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + /* + * This is for backward compatibility with existing code that didn't + * add a \`

    \` around edge labels. + * + * TODO: We should probably remove this in a future release. + */ + p { + margin: 0; + padding: 0; + display: inline; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${e.edgeLabelBackground}; + } + + .node .cluster { + // fill: ${K(e.mainBkg,.5)}; + fill: ${K(e.clusterBkg,.5)}; + stroke: ${K(e.clusterBorder,.2)}; + box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .flowchartTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + ${me()} +`,`getStyles`);function q(e,t){if(e===0||!Number.isInteger(e))throw Error(`Columns must be an integer !== 0.`);if(t<0||!Number.isInteger(t))throw Error(`Position must be a non-negative integer.`+t);return e<0?{px:t,py:0}:e===1?{px:0,py:t}:{px:t%e,py:Math.floor(t/e)}}n(q,`calculateBlockPosition`);var Ve=n(t=>{let n=0,r=0;for(let i of t.children){let{width:t,height:a,x:o,y:s}=i.size??{width:0,height:0,x:0,y:0};if(e.debug(`getMaxChildSize abc95 child:`,i.id,`width:`,t,`height:`,a,`x:`,o,`y:`,s,i.type),i.type===`space`)continue;let c=t/(i.widthInColumns??1);c>n&&(n=c),a>r&&(r=a)}return{width:n,height:r}},`getMaxChildSize`);function J(t,n,r=0,i=0,a=8){e.debug(`setBlockSizes abc95 (start)`,t.id,t?.size?.x,`block width =`,t?.size,`siblingWidth`,r),t?.size?.width||(t.size={width:r,height:i,x:0,y:0});let o=0,s=0;if(t.children?.length>0){for(let e of t.children)J(e,n,0,0,a);let c=Ve(t);o=c.width,s=c.height,e.debug(`setBlockSizes abc95 maxWidth of`,t.id,`:s children is `,o,s);for(let n of t.children)n.size&&(e.debug(`abc95 Setting size of children of ${t.id} id=${n.id} ${o} ${s} ${JSON.stringify(n.size)}`),n.size.width=o*(n.widthInColumns??1)+a*((n.widthInColumns??1)-1),n.size.height=s,n.size.x=0,n.size.y=0,e.debug(`abc95 updating size of ${t.id} children child:${n.id} maxWidth:${o} maxHeight:${s}`));for(let e of t.children)J(e,n,o,s,a);let l=t.columns??-1,u=0;for(let e of t.children)u+=e.widthInColumns??1;let d=t.children.length;l>0&&l0?Math.min(t.children.length,l):t.children.length;if(n>0){let r=(p-n*a-a)/n;e.debug(`abc95 (growing to fit) width`,t.id,p,t.size?.width,r);for(let e of t.children)e.size&&(e.size.width=r)}}t.size={width:p,height:m,x:0,y:0}}e.debug(`setBlockSizes abc94 (done)`,t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}n(J,`setBlockSizes`);function Y(t,n,r=8){e.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);let i=t.columns??-1;if(e.debug(`layoutBlocks columns abc95`,t.id,`=>`,i,t),t.children&&t.children.length>0){let a=t?.children[0]?.size?.width??0,o=t.children.length*a+(t.children.length-1)*r;e.debug(`widthOfChildren 88`,o,`posX`);let s=new Map;{let e=0;for(let n of t.children){if(!n.size)continue;let{py:t}=q(i,e),r=s.get(t)??0;n.size.height>r&&s.set(t,n.size.height);let a=n?.widthInColumns??1;i>0&&(a=Math.min(a,i-e%i)),e+=a}}let c=new Map;{let e=0,t=[...s.keys()].sort((e,t)=>e-t);for(let n of t)c.set(n,e),e+=(s.get(n)??0)+r}let l=0;e.debug(`abc91 block?.size?.x`,t.id,t?.size?.x);let u=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-r,d=0;for(let a of t.children){let o=t;if(!a.size)continue;let{width:f,height:p}=a.size,{px:m,py:h}=q(i,l);if(h!=d&&(d=h,u=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-r,e.debug(`New row in layout for block`,t.id,` and child `,a.id,d)),e.debug(`abc89 layout blocks (child) id: ${a.id} Pos: ${l} (px, py) ${m},${h} (${o?.size?.x},${o?.size?.y}) parent: ${o.id} width: ${f}${r}`),o.size){let t=f/2;a.size.x=u+r+t,e.debug(`abc91 layout blocks (calc) px, pyid:${a.id} startingPos=X${u} new startingPosX${a.size.x} ${t} padding=${r} width=${f} halfWidth=${t} => x:${a.size.x} y:${a.size.y} ${a.widthInColumns} (width * (child?.w || 1)) / 2 ${f*(a?.widthInColumns??1)/2}`),u=a.size.x+t;let n=c.get(h)??0,i=s.get(h)??p;a.size.y=o.size.y-o.size.height/2+n+i/2+r,e.debug(`abc88 layout blocks (calc) px, pyid:${a.id}startingPosX${u}${r}${t}=>x:${a.size.x}y:${a.size.y}${a.widthInColumns}(width * (child?.w || 1)) / 2${f*(a?.widthInColumns??1)/2}`)}a.children&&Y(a,n,r);let g=a?.widthInColumns??1;i>0&&(g=Math.min(g,i-l%i)),l+=g,e.debug(`abc88 columnsPos`,a,l)}}e.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}n(Y,`layoutBlocks`);function X(e,{minX:t,minY:n,maxX:r,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(e.size&&e.id!==`root`){let{x:a,y:o,width:s,height:c}=e.size;a-s/2r&&(r=a+s/2),o+c/2>i&&(i=o+c/2)}if(e.children)for(let a of e.children)({minX:t,minY:n,maxX:r,maxY:i}=X(a,{minX:t,minY:n,maxX:r,maxY:i}));return{minX:t,minY:n,maxX:r,maxY:i}}n(X,`findBounds`);function He(t){let n=t.getBlock(`root`);if(!n)return;let r=c()?.block?.padding??8;J(n,t,0,0,r),Y(n,t,r),e.debug(`getBlocks`,JSON.stringify(n,null,2));let{minX:i,minY:a,maxX:o,maxY:s}=X(n),l=s-a;return{x:i,y:a,width:o-i,height:l}}n(He,`layout`);function Z(e,t,n=!1){let r=e,a=`default`;(r?.classes?.length||0)>0&&(a=(r?.classes??[]).join(` `)),a+=` flowchart-label`;let o=(r?.classes??[]).flatMap(e=>t.getClasses().get(e)?.styles??[]),s=0,c=`rect`,l;switch(r.type){case`round`:s=5,c=`rect`;break;case`composite`:s=0,c=`composite`,l=0;break;case`square`:c=`rect`;break;case`diamond`:c=`question`;break;case`hexagon`:c=`hexagon`;break;case`block_arrow`:c=`block_arrow`;break;case`odd`:c=`rect_left_inv_arrow`;break;case`lean_right`:c=`lean_right`;break;case`lean_left`:c=`lean_left`;break;case`trapezoid`:c=`trapezoid`;break;case`inv_trapezoid`:c=`inv_trapezoid`;break;case`rect_left_inv_arrow`:c=`rect_left_inv_arrow`;break;case`circle`:c=`circle`;break;case`ellipse`:c=`ellipse`;break;case`stadium`:c=`stadium`;break;case`subroutine`:c=`subroutine`;break;case`cylinder`:c=`cylinder`;break;case`group`:c=`rect`;break;case`doublecircle`:c=`doublecircle`;break;default:c=`rect`}let u=M(r?.styles??[]),d=r.label,f=r.size??{width:0,height:0,x:0,y:0},p=t.getDiagramId();return{labelStyle:u.labelStyle,shape:c,label:d,labelText:d,rx:s,ry:s,class:a,cssClasses:a,cssStyles:r?.styles??[],cssCompiledStyles:o,style:u.style,id:r.id,domId:p?`${p}-${r.id}`:r.id,isGroup:!1,directions:r.directions,width:f.width||void 0,height:f.height||void 0,wrappingWidth:f.width||1/0,x:f.x,y:f.y,positioned:n,intersect:void 0,padding:l??i()?.block?.padding??0,widthInColumns:r.widthInColumns??1,colorIndex:r.colorIndex,look:i().look}}n(Z,`getNodeFromBlock`);async function Ue(e,t,n){let r=Z(t,n,!1);if(t.type===`group`)return;let a=i(),o=await N(e,r,{config:a}),s=o.node()?.getBBox()??{width:0,height:0},c=n.getBlock(r.id);c.size={width:s.width,height:s.height,x:0,y:0,node:o},n.setBlock(c),o.remove()}n(Ue,`calculateBlockSize`);async function We(e,t,n){let r=Z(t,n,!0);if(n.getBlock(r.id).type!==`space`){let n=i(),a=await N(e,r,{config:n});r.colorIndex!==void 0&&se(a,r.colorIndex,n.theme,n.themeVariables?.borderColorArray),t.intersect=r?.intersect,ce(r)}}n(We,`insertBlockPositioned`);async function Q(e,t,n,r){for(let i of t)await r(e,i,n),i.children&&await Q(e,i.children,n,r)}n(Q,`performOperations`);async function Ge(e,t,n){await Q(e,t,n,Ue)}n(Ge,`calculateBlockSizes`);async function Ke(e,t,n){await Q(e,t,n,We)}n(Ke,`insertBlocks`);async function $(e,t,n,r,i){let a=new he({multigraph:!0,compound:!0});a.setGraph({rankdir:`TB`,nodesep:10,ranksep:10,marginx:8,marginy:8});for(let e of n)e.size&&a.setNode(e.id,{width:e.size.width,height:e.size.height,intersect:e.intersect});for(let n of t)if(n.start&&n.end){let t=r.getBlock(n.start),o=r.getBlock(n.end);if(t?.size&&o?.size){let r=t.size,s=o.size,c=[{x:r.x,y:r.y},{x:r.x+(s.x-r.x)/2,y:r.y+(s.y-r.y)/2},{x:s.x,y:s.y}],l=i?`${i}-${n.id}`:n.id,u=`${n.thickness===`thick`?`edge-thickness-thick`:`edge-thickness-normal`} ${n.pattern===`dotted`?`edge-pattern-dotted`:`edge-pattern-solid`} flowchart-link LS-a1 LE-b1`;de(e,{...n,id:l,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:c,classes:u},{},`block`,a.node(n.start),a.node(n.end),i),n.label&&(await fe(e,{...n,label:n.label,labelStyle:`stroke: #333; stroke-width: 1.5px;fill:none;`,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:c,classes:u}),le({...n,x:c[1].x,y:c[1].y},{originalPath:c}))}}}n($,`insertEdges`);var qe={parser:Se,db:Re,renderer:{draw:n(async function(n,r,o,s){let{securityLevel:c,block:l}=i(),u=s.db;u.setDiagramId(r);let d;c===`sandbox`&&(d=t(`#i`+r));let f=t(c===`sandbox`?d.nodes()[0].contentDocument.body:`body`),p=c===`sandbox`?f.select(`[id="${r}"]`):t(`[id="${r}"]`);ue(p,i()),pe(p,[`point`,`circle`,`cross`],s.type,r);let m=u.getBlocks(),h=u.getBlocksFlat(),g=u.getEdges(),_=p.insert(`g`).attr(`class`,`block`);await Ge(_,m,u);let v=He(u);await Ke(_,m,u),await $(_,g,h,u,r);let y=_.node()?.getBBox(),b=y&&Number.isFinite(y.width)&&Number.isFinite(y.height)?y:v;if(b){let t=Math.max(1,Math.round(.125*(b.width/b.height))),n=b.height+t+10,r=b.width+10,{useMaxWidth:i}=l;a(p,n,r,!!i),e.debug(`Here Bounds`,v,b),p.attr(`viewBox`,`${b.x-5} ${b.y-5} ${b.width+10} ${b.height+10}`)}},`draw`),getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`)},styles:Be};export{qe as diagram}; \ No newline at end of file diff --git a/www/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js b/www/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js new file mode 100644 index 0000000..dd8eef1 --- /dev/null +++ b/www/assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js @@ -0,0 +1,38 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,c as a,r as o,s,v as l,x as u,y as d,z as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{_ as p,n as m,r as h}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{r as g,s as _}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{a as v}from"./chunk-GWA4HPMP-C1P4FmAY.js";var y=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,24],r=[1,25],i=[1,26],a=[1,27],o=[1,28],s=[1,63],l=[1,64],u=[1,65],d=[1,66],f=[1,67],p=[1,68],m=[1,69],h=[1,29],g=[1,30],_=[1,31],v=[1,32],y=[1,33],b=[1,34],x=[1,35],S=[1,36],C=[1,37],w=[1,38],T=[1,39],E=[1,40],D=[1,41],O=[1,42],k=[1,43],A=[1,44],j=[1,45],M=[1,46],N=[1,47],P=[1,48],F=[1,50],I=[1,51],L=[1,52],R=[1,53],z=[1,54],B=[1,55],V=[1,56],H=[1,57],U=[1,58],W=[1,59],G=[1,60],ee=[14,42],te=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],ne=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],K=[1,82],q=[1,83],J=[1,84],Y=[1,85],X=[12,14,42],re=[12,14,33,42],ie=[12,14,33,42,76,77,79,80],Z=[12,33],ae=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],oe={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:`error`,6:`direction_tb`,7:`direction_bt`,8:`direction_rl`,9:`direction_lr`,11:`C4_CONTEXT`,12:`NEWLINE`,14:`EOF`,15:`C4_CONTAINER`,16:`C4_COMPONENT`,17:`C4_DYNAMIC`,18:`C4_DEPLOYMENT`,22:`title`,23:`accDescription`,24:`acc_title`,25:`acc_title_value`,26:`acc_descr`,27:`acc_descr_value`,28:`acc_descr_multiline_value`,33:`LBRACE`,34:`ENTERPRISE_BOUNDARY`,36:`SYSTEM_BOUNDARY`,37:`BOUNDARY`,38:`CONTAINER_BOUNDARY`,39:`NODE`,40:`NODE_L`,41:`NODE_R`,42:`RBRACE`,44:`PERSON`,45:`PERSON_EXT`,46:`SYSTEM`,47:`SYSTEM_DB`,48:`SYSTEM_QUEUE`,49:`SYSTEM_EXT`,50:`SYSTEM_EXT_DB`,51:`SYSTEM_EXT_QUEUE`,52:`CONTAINER`,53:`CONTAINER_DB`,54:`CONTAINER_QUEUE`,55:`CONTAINER_EXT`,56:`CONTAINER_EXT_DB`,57:`CONTAINER_EXT_QUEUE`,58:`COMPONENT`,59:`COMPONENT_DB`,60:`COMPONENT_QUEUE`,61:`COMPONENT_EXT`,62:`COMPONENT_EXT_DB`,63:`COMPONENT_EXT_QUEUE`,64:`REL`,65:`BIREL`,66:`REL_U`,67:`REL_D`,68:`REL_L`,69:`REL_R`,70:`REL_B`,71:`REL_INDEX`,72:`UPDATE_EL_STYLE`,73:`UPDATE_REL_STYLE`,74:`UPDATE_LAYOUT_CONFIG`,76:`STR`,77:`STR_KEY`,78:`STR_VALUE`,79:`ATTRIBUTE`,80:`ATTRIBUTE_EMPTY`},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:r.setDirection(`TB`);break;case 4:r.setDirection(`BT`);break;case 5:r.setDirection(`RL`);break;case 6:r.setDirection(`LR`);break;case 8:case 9:case 10:case 11:case 12:r.setC4Type(a[s-3]);break;case 19:r.setTitle(a[s].substring(6)),this.$=a[s].substring(6);break;case 20:r.setAccDescription(a[s].substring(15)),this.$=a[s].substring(15);break;case 21:this.$=a[s].trim(),r.setTitle(this.$);break;case 22:case 23:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 28:a[s].splice(2,0,`ENTERPRISE`),r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 29:a[s].splice(2,0,`SYSTEM`),r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 30:r.addPersonOrSystemBoundary(...a[s]),this.$=a[s];break;case 31:a[s].splice(2,0,`CONTAINER`),r.addContainerBoundary(...a[s]),this.$=a[s];break;case 32:r.addDeploymentNode(`node`,...a[s]),this.$=a[s];break;case 33:r.addDeploymentNode(`nodeL`,...a[s]),this.$=a[s];break;case 34:r.addDeploymentNode(`nodeR`,...a[s]),this.$=a[s];break;case 35:r.popBoundaryParseStack();break;case 39:r.addPersonOrSystem(`person`,...a[s]),this.$=a[s];break;case 40:r.addPersonOrSystem(`external_person`,...a[s]),this.$=a[s];break;case 41:r.addPersonOrSystem(`system`,...a[s]),this.$=a[s];break;case 42:r.addPersonOrSystem(`system_db`,...a[s]),this.$=a[s];break;case 43:r.addPersonOrSystem(`system_queue`,...a[s]),this.$=a[s];break;case 44:r.addPersonOrSystem(`external_system`,...a[s]),this.$=a[s];break;case 45:r.addPersonOrSystem(`external_system_db`,...a[s]),this.$=a[s];break;case 46:r.addPersonOrSystem(`external_system_queue`,...a[s]),this.$=a[s];break;case 47:r.addContainer(`container`,...a[s]),this.$=a[s];break;case 48:r.addContainer(`container_db`,...a[s]),this.$=a[s];break;case 49:r.addContainer(`container_queue`,...a[s]),this.$=a[s];break;case 50:r.addContainer(`external_container`,...a[s]),this.$=a[s];break;case 51:r.addContainer(`external_container_db`,...a[s]),this.$=a[s];break;case 52:r.addContainer(`external_container_queue`,...a[s]),this.$=a[s];break;case 53:r.addComponent(`component`,...a[s]),this.$=a[s];break;case 54:r.addComponent(`component_db`,...a[s]),this.$=a[s];break;case 55:r.addComponent(`component_queue`,...a[s]),this.$=a[s];break;case 56:r.addComponent(`external_component`,...a[s]),this.$=a[s];break;case 57:r.addComponent(`external_component_db`,...a[s]),this.$=a[s];break;case 58:r.addComponent(`external_component_queue`,...a[s]),this.$=a[s];break;case 60:r.addRel(`rel`,...a[s]),this.$=a[s];break;case 61:r.addRel(`birel`,...a[s]),this.$=a[s];break;case 62:r.addRel(`rel_u`,...a[s]),this.$=a[s];break;case 63:r.addRel(`rel_d`,...a[s]),this.$=a[s];break;case 64:r.addRel(`rel_l`,...a[s]),this.$=a[s];break;case 65:r.addRel(`rel_r`,...a[s]),this.$=a[s];break;case 66:r.addRel(`rel_b`,...a[s]),this.$=a[s];break;case 67:a[s].splice(0,1),r.addRel(`rel`,...a[s]),this.$=a[s];break;case 68:r.updateElStyle(`update_el_style`,...a[s]),this.$=a[s];break;case 69:r.updateRelStyle(`update_rel_style`,...a[s]),this.$=a[s];break;case 70:r.updateLayoutConfig(`update_layout_config`,...a[s]),this.$=a[s];break;case 71:this.$=[a[s]];break;case 72:a[s].unshift(a[s-1]),this.$=a[s];break;case 73:case 75:this.$=a[s].trim();break;case 74:let e={};e[a[s-1].trim()]=a[s].trim(),this.$=e;break;case 76:this.$=``}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:70,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:71,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:72,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{13:73,19:20,20:21,21:22,22:t,23:r,24:i,26:a,28:o,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{14:[1,74]},e(ee,[2,13],{43:23,29:49,30:61,32:62,20:75,34:s,36:l,37:u,38:d,39:f,40:p,41:m,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G}),e(ee,[2,14]),e(te,[2,16],{12:[1,76]}),e(ee,[2,36],{12:[1,77]}),e(ne,[2,19]),e(ne,[2,20]),{25:[1,78]},{27:[1,79]},e(ne,[2,23]),{35:80,75:81,76:K,77:q,79:J,80:Y},{35:86,75:81,76:K,77:q,79:J,80:Y},{35:87,75:81,76:K,77:q,79:J,80:Y},{35:88,75:81,76:K,77:q,79:J,80:Y},{35:89,75:81,76:K,77:q,79:J,80:Y},{35:90,75:81,76:K,77:q,79:J,80:Y},{35:91,75:81,76:K,77:q,79:J,80:Y},{35:92,75:81,76:K,77:q,79:J,80:Y},{35:93,75:81,76:K,77:q,79:J,80:Y},{35:94,75:81,76:K,77:q,79:J,80:Y},{35:95,75:81,76:K,77:q,79:J,80:Y},{35:96,75:81,76:K,77:q,79:J,80:Y},{35:97,75:81,76:K,77:q,79:J,80:Y},{35:98,75:81,76:K,77:q,79:J,80:Y},{35:99,75:81,76:K,77:q,79:J,80:Y},{35:100,75:81,76:K,77:q,79:J,80:Y},{35:101,75:81,76:K,77:q,79:J,80:Y},{35:102,75:81,76:K,77:q,79:J,80:Y},{35:103,75:81,76:K,77:q,79:J,80:Y},{35:104,75:81,76:K,77:q,79:J,80:Y},e(X,[2,59]),{35:105,75:81,76:K,77:q,79:J,80:Y},{35:106,75:81,76:K,77:q,79:J,80:Y},{35:107,75:81,76:K,77:q,79:J,80:Y},{35:108,75:81,76:K,77:q,79:J,80:Y},{35:109,75:81,76:K,77:q,79:J,80:Y},{35:110,75:81,76:K,77:q,79:J,80:Y},{35:111,75:81,76:K,77:q,79:J,80:Y},{35:112,75:81,76:K,77:q,79:J,80:Y},{35:113,75:81,76:K,77:q,79:J,80:Y},{35:114,75:81,76:K,77:q,79:J,80:Y},{35:115,75:81,76:K,77:q,79:J,80:Y},{20:116,29:49,30:61,32:62,34:s,36:l,37:u,38:d,39:f,40:p,41:m,43:23,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G},{12:[1,118],33:[1,117]},{35:119,75:81,76:K,77:q,79:J,80:Y},{35:120,75:81,76:K,77:q,79:J,80:Y},{35:121,75:81,76:K,77:q,79:J,80:Y},{35:122,75:81,76:K,77:q,79:J,80:Y},{35:123,75:81,76:K,77:q,79:J,80:Y},{35:124,75:81,76:K,77:q,79:J,80:Y},{35:125,75:81,76:K,77:q,79:J,80:Y},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},e(ee,[2,15]),e(te,[2,17],{21:22,19:130,22:t,23:r,24:i,26:a,28:o}),e(ee,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:t,23:r,24:i,26:a,28:o,34:s,36:l,37:u,38:d,39:f,40:p,41:m,44:h,45:g,46:_,47:v,48:y,49:b,50:x,51:S,52:C,53:w,54:T,55:E,56:D,57:O,58:k,59:A,60:j,61:M,62:N,63:P,64:F,65:I,66:L,67:R,68:z,69:B,70:V,71:H,72:U,73:W,74:G}),e(ne,[2,21]),e(ne,[2,22]),e(X,[2,39]),e(re,[2,71],{75:81,35:132,76:K,77:q,79:J,80:Y}),e(ie,[2,73]),{78:[1,133]},e(ie,[2,75]),e(ie,[2,76]),e(X,[2,40]),e(X,[2,41]),e(X,[2,42]),e(X,[2,43]),e(X,[2,44]),e(X,[2,45]),e(X,[2,46]),e(X,[2,47]),e(X,[2,48]),e(X,[2,49]),e(X,[2,50]),e(X,[2,51]),e(X,[2,52]),e(X,[2,53]),e(X,[2,54]),e(X,[2,55]),e(X,[2,56]),e(X,[2,57]),e(X,[2,58]),e(X,[2,60]),e(X,[2,61]),e(X,[2,62]),e(X,[2,63]),e(X,[2,64]),e(X,[2,65]),e(X,[2,66]),e(X,[2,67]),e(X,[2,68]),e(X,[2,69]),e(X,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},e(Z,[2,28]),e(Z,[2,29]),e(Z,[2,30]),e(Z,[2,31]),e(Z,[2,32]),e(Z,[2,33]),e(Z,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},e(te,[2,18]),e(ee,[2,38]),e(re,[2,72]),e(ie,[2,74]),e(X,[2,24]),e(X,[2,35]),e(ae,[2,25]),e(ae,[2,26],{12:[1,138]}),e(ae,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,l=``,u=0,d=0,f=0,p=2,m=1,h=o.slice.call(arguments,1),g=Object.create(this.lexer),_={yy:{}};for(var v in this.yy)Object.prototype.hasOwnProperty.call(this.yy,v)&&(_.yy[v]=this.yy[v]);g.setInput(e,_.yy),_.yy.lexer=g,_.yy.parser=this,g.yylloc===void 0&&(g.yylloc={});var y=g.yylloc;o.push(y);var b=g.options&&g.options.ranges;this.parseError=typeof _.yy.parseError==`function`?_.yy.parseError:Object.getPrototypeOf(this).parseError;function x(e){r.length-=2*e,a.length-=e,o.length-=e}n(x,`popStack`);function S(){var e=i.pop()||g.lex()||m;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(S,`lex`);for(var C,w,T,E,D,O={},k,A,j,M;;){if(T=r[r.length-1],this.defaultActions[T]?E=this.defaultActions[T]:(C??=S(),E=s[T]&&s[T][C]),E===void 0||!E.length||!E[0]){var N=``;for(k in M=[],s[T])this.terminals_[k]&&k>p&&M.push(`'`+this.terminals_[k]+`'`);N=g.showPosition?`Parse error on line `+(u+1)+`: +`+g.showPosition()+` +Expecting `+M.join(`, `)+`, got '`+(this.terminals_[C]||C)+`'`:`Parse error on line `+(u+1)+`: Unexpected `+(C==m?`end of input`:`'`+(this.terminals_[C]||C)+`'`),this.parseError(N,{text:g.match,token:this.terminals_[C]||C,line:g.yylineno,loc:y,expected:M})}if(E[0]instanceof Array&&E.length>1)throw Error(`Parse Error: multiple actions possible at state: `+T+`, token: `+C);switch(E[0]){case 1:r.push(C),a.push(g.yytext),o.push(g.yylloc),r.push(E[1]),C=null,w?(C=w,w=null):(d=g.yyleng,l=g.yytext,u=g.yylineno,y=g.yylloc,f>0&&f--);break;case 2:if(A=this.productions_[E[1]][1],O.$=a[a.length-A],O._$={first_line:o[o.length-(A||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(A||1)].first_column,last_column:o[o.length-1].last_column},b&&(O._$.range=[o[o.length-(A||1)].range[0],o[o.length-1].range[1]]),D=this.performAction.apply(O,[l,d,u,_.yy,E[1],a,o].concat(h)),D!==void 0)return D;A&&(r=r.slice(0,-1*A*2),a=a.slice(0,-1*A),o=o.slice(0,-1*A)),r.push(this.productions_[E[1]][0]),a.push(O.$),o.push(O._$),j=s[r[r.length-2]][r[r.length-1]],r.push(j);break;case 3:return!0}}return!0},`parse`)};oe.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return 6;case 1:return 7;case 2:return 8;case 3:return 9;case 4:return 22;case 5:return 23;case 6:return this.begin(`acc_title`),24;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),26;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:break;case 14:c;break;case 15:return 12;case 16:break;case 17:return 11;case 18:return 15;case 19:return 16;case 20:return 17;case 21:return 18;case 22:return this.begin(`person_ext`),45;case 23:return this.begin(`person`),44;case 24:return this.begin(`system_ext_queue`),51;case 25:return this.begin(`system_ext_db`),50;case 26:return this.begin(`system_ext`),49;case 27:return this.begin(`system_queue`),48;case 28:return this.begin(`system_db`),47;case 29:return this.begin(`system`),46;case 30:return this.begin(`boundary`),37;case 31:return this.begin(`enterprise_boundary`),34;case 32:return this.begin(`system_boundary`),36;case 33:return this.begin(`container_ext_queue`),57;case 34:return this.begin(`container_ext_db`),56;case 35:return this.begin(`container_ext`),55;case 36:return this.begin(`container_queue`),54;case 37:return this.begin(`container_db`),53;case 38:return this.begin(`container`),52;case 39:return this.begin(`container_boundary`),38;case 40:return this.begin(`component_ext_queue`),63;case 41:return this.begin(`component_ext_db`),62;case 42:return this.begin(`component_ext`),61;case 43:return this.begin(`component_queue`),60;case 44:return this.begin(`component_db`),59;case 45:return this.begin(`component`),58;case 46:return this.begin(`node`),39;case 47:return this.begin(`node`),39;case 48:return this.begin(`node_l`),40;case 49:return this.begin(`node_r`),41;case 50:return this.begin(`rel`),64;case 51:return this.begin(`birel`),65;case 52:return this.begin(`rel_u`),66;case 53:return this.begin(`rel_u`),66;case 54:return this.begin(`rel_d`),67;case 55:return this.begin(`rel_d`),67;case 56:return this.begin(`rel_l`),68;case 57:return this.begin(`rel_l`),68;case 58:return this.begin(`rel_r`),69;case 59:return this.begin(`rel_r`),69;case 60:return this.begin(`rel_b`),70;case 61:return this.begin(`rel_index`),71;case 62:return this.begin(`update_el_style`),72;case 63:return this.begin(`update_rel_style`),73;case 64:return this.begin(`update_layout_config`),74;case 65:return`EOF_IN_STRUCT`;case 66:return this.begin(`attribute`),`ATTRIBUTE_EMPTY`;case 67:this.begin(`attribute`);break;case 68:this.popState(),this.popState();break;case 69:return 80;case 70:break;case 71:return 80;case 72:this.begin(`string`);break;case 73:this.popState();break;case 74:return`STR`;case 75:this.begin(`string_kv`);break;case 76:return this.begin(`string_kv_key`),`STR_KEY`;case 77:this.popState(),this.begin(`string_kv_value`);break;case 78:return`STR_VALUE`;case 79:this.popState(),this.popState();break;case 80:return`STR`;case 81:return`LBRACE`;case 82:return`RBRACE`;case 83:return`SPACE`;case 84:return`EOL`;case 85:return 14}},`anonymous`),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:title\s[^#\n;]+)/,/^(?:accDescription\s[^#\n;]+)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:C4Context\b)/,/^(?:C4Container\b)/,/^(?:C4Component\b)/,/^(?:C4Dynamic\b)/,/^(?:C4Deployment\b)/,/^(?:Person_Ext\b)/,/^(?:Person\b)/,/^(?:SystemQueue_Ext\b)/,/^(?:SystemDb_Ext\b)/,/^(?:System_Ext\b)/,/^(?:SystemQueue\b)/,/^(?:SystemDb\b)/,/^(?:System\b)/,/^(?:Boundary\b)/,/^(?:Enterprise_Boundary\b)/,/^(?:System_Boundary\b)/,/^(?:ContainerQueue_Ext\b)/,/^(?:ContainerDb_Ext\b)/,/^(?:Container_Ext\b)/,/^(?:ContainerQueue\b)/,/^(?:ContainerDb\b)/,/^(?:Container\b)/,/^(?:Container_Boundary\b)/,/^(?:ComponentQueue_Ext\b)/,/^(?:ComponentDb_Ext\b)/,/^(?:Component_Ext\b)/,/^(?:ComponentQueue\b)/,/^(?:ComponentDb\b)/,/^(?:Component\b)/,/^(?:Deployment_Node\b)/,/^(?:Node\b)/,/^(?:Node_L\b)/,/^(?:Node_R\b)/,/^(?:Rel\b)/,/^(?:BiRel\b)/,/^(?:Rel_Up\b)/,/^(?:Rel_U\b)/,/^(?:Rel_Down\b)/,/^(?:Rel_D\b)/,/^(?:Rel_Left\b)/,/^(?:Rel_L\b)/,/^(?:Rel_Right\b)/,/^(?:Rel_R\b)/,/^(?:Rel_Back\b)/,/^(?:RelIndex\b)/,/^(?:UpdateElementStyle\b)/,/^(?:UpdateRelStyle\b)/,/^(?:UpdateLayoutConfig\b)/,/^(?:$)/,/^(?:[(][ ]*[,])/,/^(?:[(])/,/^(?:[)])/,/^(?:,,)/,/^(?:,)/,/^(?:[ ]*["]["])/,/^(?:[ ]*["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[ ]*[\$])/,/^(?:[^=]*)/,/^(?:[=][ ]*["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:[^,]+)/,/^(?:\{)/,/^(?:\})/,/^(?:[\s]+)/,/^(?:[\n\r]+)/,/^(?:$)/],conditions:{acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},string_kv_value:{rules:[78,79],inclusive:!1},string_kv_key:{rules:[77],inclusive:!1},string_kv:{rules:[76],inclusive:!1},string:{rules:[73,74],inclusive:!1},attribute:{rules:[68,69,70,71,72,75,80],inclusive:!1},update_layout_config:{rules:[65,66,67,68],inclusive:!1},update_rel_style:{rules:[65,66,67,68],inclusive:!1},update_el_style:{rules:[65,66,67,68],inclusive:!1},rel_b:{rules:[65,66,67,68],inclusive:!1},rel_r:{rules:[65,66,67,68],inclusive:!1},rel_l:{rules:[65,66,67,68],inclusive:!1},rel_d:{rules:[65,66,67,68],inclusive:!1},rel_u:{rules:[65,66,67,68],inclusive:!1},rel_bi:{rules:[],inclusive:!1},rel:{rules:[65,66,67,68],inclusive:!1},node_r:{rules:[65,66,67,68],inclusive:!1},node_l:{rules:[65,66,67,68],inclusive:!1},node:{rules:[65,66,67,68],inclusive:!1},index:{rules:[],inclusive:!1},rel_index:{rules:[65,66,67,68],inclusive:!1},component_ext_queue:{rules:[65,66,67,68],inclusive:!1},component_ext_db:{rules:[65,66,67,68],inclusive:!1},component_ext:{rules:[65,66,67,68],inclusive:!1},component_queue:{rules:[65,66,67,68],inclusive:!1},component_db:{rules:[65,66,67,68],inclusive:!1},component:{rules:[65,66,67,68],inclusive:!1},container_boundary:{rules:[65,66,67,68],inclusive:!1},container_ext_queue:{rules:[65,66,67,68],inclusive:!1},container_ext_db:{rules:[65,66,67,68],inclusive:!1},container_ext:{rules:[65,66,67,68],inclusive:!1},container_queue:{rules:[65,66,67,68],inclusive:!1},container_db:{rules:[65,66,67,68],inclusive:!1},container:{rules:[65,66,67,68],inclusive:!1},birel:{rules:[65,66,67,68],inclusive:!1},system_boundary:{rules:[65,66,67,68],inclusive:!1},enterprise_boundary:{rules:[65,66,67,68],inclusive:!1},boundary:{rules:[65,66,67,68],inclusive:!1},system_ext_queue:{rules:[65,66,67,68],inclusive:!1},system_ext_db:{rules:[65,66,67,68],inclusive:!1},system_ext:{rules:[65,66,67,68],inclusive:!1},system_queue:{rules:[65,66,67,68],inclusive:!1},system_db:{rules:[65,66,67,68],inclusive:!1},system:{rules:[65,66,67,68],inclusive:!1},person_ext:{rules:[65,66,67,68],inclusive:!1},person:{rules:[65,66,67,68],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,82,83,84,85],inclusive:!0}}}})();function se(){this.yy={}}return n(se,`Parser`),se.prototype=oe,oe.Parser=se,new se})();y.parser=y;var b=y,x=n(e=>u()[e],`getRequiredConfig`),S=new Set([`label`,`descr`,`techn`,`type`]),C=n((e,t)=>{for(let[n,r]of Object.entries(t))if(r!==void 0){if(typeof r==`object`){let[t,n]=Object.entries(r)[0];e[t]=S.has(t)?{text:n}:n}else e[n]=r}},`assignAttributes`),w=n(()=>({alias:`global`,label:{text:`global`},type:{text:`global`},tags:null,link:null,parentBoundary:``}),`createGlobalBoundary`),T=[],E=[``],D=`global`,O=``,k=[w()],A=[],j=``,M=!1,N=4,P=2,F,I=n(function(){return F},`getC4Type`),L=n(function(e){F=f(e,u())},`setC4Type`),R=n(function(e,t,n,r,i,a,o,s,l){if(e==null||t==null||n==null||r==null)return;let u={},d=A.find(e=>e.from===t&&e.to===n);if(d?u=d:A.push(u),u.type=e,u.from=t,u.to=n,u.label={text:r},i==null)u.techn??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];u[e]=S.has(e)?{text:t}:t}else u.techn={text:i};if(a==null)u.descr??={text:``};else if(typeof a==`object`){let[e,t]=Object.entries(a)[0];u[e]=S.has(e)?{text:t}:t}else u.descr={text:a};C(u,{sprite:o,tags:s,link:l}),u.wrap=le()},`addRel`),z=n(function(e,t,n,r,i,a,o){if(t===null||n===null)return;let s={},l=T.find(e=>e.alias===t);if(l&&t===l.alias?s=l:(s.alias=t,T.push(s)),n==null?s.label={text:``}:s.label={text:n},r==null)s.descr??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];s[e]=S.has(e)?{text:t}:t}else s.descr={text:r};C(s,{sprite:i,tags:a,link:o}),s.typeC4Shape={text:e},s.parentBoundary=D,s.wrap=le()},`addPersonOrSystem`),B=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=T.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,T.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.techn??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.techn={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{sprite:a,tags:o,link:s}),l.wrap=le(),l.typeC4Shape={text:e},l.parentBoundary=D},`addContainer`),V=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=T.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,T.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.techn??={text:``};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.techn={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{sprite:a,tags:o,link:s}),l.wrap=le(),l.typeC4Shape={text:e},l.parentBoundary=D},`addComponent`),H=n(function(e,t,n,r,i){if(e===null||t===null)return;let a={},o=k.find(t=>t.alias===e);if(o&&e===o.alias?a=o:(a.alias=e,k.push(a)),t==null?a.label={text:``}:a.label={text:t},n==null)a.type={text:`system`};else if(typeof n==`object`){let[e,t]=Object.entries(n)[0];a[e]=S.has(e)?{text:t}:t}else a.type={text:n};C(a,{tags:r,link:i}),a.parentBoundary=D,a.wrap=le(),O=D,D=e,E.push(O)},`addPersonOrSystemBoundary`),U=n(function(e,t,n,r,i){if(e===null||t===null)return;let a={},o=k.find(t=>t.alias===e);if(o&&e===o.alias?a=o:(a.alias=e,k.push(a)),t==null?a.label={text:``}:a.label={text:t},n==null)a.type={text:`container`};else if(typeof n==`object`){let[e,t]=Object.entries(n)[0];a[e]=S.has(e)?{text:t}:t}else a.type={text:n};C(a,{tags:r,link:i}),a.parentBoundary=D,a.wrap=le(),O=D,D=e,E.push(O)},`addContainerBoundary`),W=n(function(e,t,n,r,i,a,o,s){if(t===null||n===null)return;let l={},u=k.find(e=>e.alias===t);if(u&&t===u.alias?l=u:(l.alias=t,k.push(l)),n==null?l.label={text:``}:l.label={text:n},r==null)l.type={text:`node`};else if(typeof r==`object`){let[e,t]=Object.entries(r)[0];l[e]=S.has(e)?{text:t}:t}else l.type={text:r};if(i==null)l.descr??={text:``};else if(typeof i==`object`){let[e,t]=Object.entries(i)[0];l[e]=S.has(e)?{text:t}:t}else l.descr={text:i};C(l,{tags:o,link:s}),l.nodeType=e,l.parentBoundary=D,l.wrap=le(),O=D,D=t,E.push(O)},`addDeploymentNode`),G=n(function(){D=O,E.pop(),O=E.pop(),E.push(O)},`popBoundaryParseStack`),ee=n(function(e,t,n,r,i,a,o,s,l,u,d){let f=T.find(e=>e.alias===t);if(!(f===void 0&&(f=k.find(e=>e.alias===t),f===void 0))){if(n!=null){if(typeof n==`object`){let[e,t]=Object.entries(n)[0];f[e]=t}else f.bgColor=n}if(r!=null){if(typeof r==`object`){let[e,t]=Object.entries(r)[0];f[e]=t}else f.fontColor=r}if(i!=null){if(typeof i==`object`){let[e,t]=Object.entries(i)[0];f[e]=t}else f.borderColor=i}if(a!=null){if(typeof a==`object`){let[e,t]=Object.entries(a)[0];f[e]=t}else f.shadowing=a}if(o!=null){if(typeof o==`object`){let[e,t]=Object.entries(o)[0];f[e]=t}else f.shape=o}if(s!=null){if(typeof s==`object`){let[e,t]=Object.entries(s)[0];f[e]=t}else f.sprite=s}if(l!=null){if(typeof l==`object`){let[e,t]=Object.entries(l)[0];f[e]=t}else f.techn=l}if(u!=null){if(typeof u==`object`){let[e,t]=Object.entries(u)[0];f[e]=t}else f.legendText=u}if(d!=null){if(typeof d==`object`){let[e,t]=Object.entries(d)[0];f[e]=t}else f.legendSprite=d}}},`updateElStyle`),te=n(function(e,t,n,r,i,a,o){let s=A.find(e=>e.from===t&&e.to===n);if(s!==void 0){if(r!=null){if(typeof r==`object`){let[e,t]=Object.entries(r)[0];s[e]=t}else s.textColor=r}if(i!=null){if(typeof i==`object`){let[e,t]=Object.entries(i)[0];s[e]=t}else s.lineColor=i}if(a!=null){if(typeof a==`object`){let[e,t]=Object.entries(a)[0];s[e]=parseInt(t)}else s.offsetX=parseInt(a)}if(o!=null){if(typeof o==`object`){let[e,t]=Object.entries(o)[0];s[e]=parseInt(t)}else s.offsetY=parseInt(o)}}},`updateRelStyle`),ne=n(function(e,t,n){let r=N,i=P;if(typeof t==`object`){let e=Object.values(t)[0];r=parseInt(e)}else r=parseInt(t);if(typeof n==`object`){let e=Object.values(n)[0];i=parseInt(e)}else i=parseInt(n);r>=1&&(N=r),i>=1&&(P=i)},`updateLayoutConfig`),K=n(function(){return N},`getC4ShapeInRow`),q=n(function(){return P},`getC4BoundaryInRow`),J=n(function(){return D},`getCurrentBoundaryParse`),Y=n(function(){return O},`getParentBoundaryParse`),X=n(function(e){return e==null?T:T.filter(t=>t.parentBoundary===e)},`getC4ShapeArray`),re=n(function(e){return T.find(t=>t.alias===e)??k.find(t=>t.alias===e)},`getC4Shape`),ie=n(function(e){return Object.keys(X(e))},`getC4ShapeKeys`),Z=n(function(e){return e==null?k:k.filter(t=>t.parentBoundary===e)},`getBoundaries`),ae=Z,oe=n(function(){return A},`getRels`),se=n(function(){return j},`getTitle`),ce=n(function(e){M=e},`setWrap`),le=n(function(){return M},`autoWrap`),ue={addPersonOrSystem:z,addPersonOrSystemBoundary:H,addContainer:B,addContainerBoundary:U,addComponent:V,addDeploymentNode:W,popBoundaryParseStack:G,addRel:R,updateElStyle:ee,updateRelStyle:te,updateLayoutConfig:ne,autoWrap:le,setWrap:ce,getC4ShapeArray:X,getC4Shape:re,getC4ShapeKeys:ie,getBoundaries:Z,getBoundarys:ae,getCurrentBoundaryParse:J,getParentBoundaryParse:Y,getRels:oe,getTitle:se,getC4Type:I,getC4ShapeInRow:K,getC4BoundaryInRow:q,setAccTitle:i,getAccTitle:d,getAccDescription:l,setAccDescription:r,getConfig:n(()=>x(`c4`),`getConfig`),clear:n(function(){T=[],k=[w()],O=``,D=`global`,E=[``],A=[],E=[``],j=``,M=!1,N=4,P=2},`clear`),LINETYPE:{SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},ARROWTYPE:{FILLED:0,OPEN:1},PLACEMENT:{LEFTOF:0,RIGHTOF:1,OVER:2},setTitle:n(function(e){j=f(e,u())},`setTitle`),setC4Type:L},de=n(function(e,t){return v(e,t)},`drawRect`),fe=n((e,t,n,r)=>{let i=e.append(`g`),a=0;for(let e of t){let t=e.textColor?e.textColor:`#444444`,o=e.lineColor?e.lineColor:`#444444`,s=e.offsetX?parseInt(String(e.offsetX)):0,l=e.offsetY?parseInt(String(e.offsetY)):0;if(a===0){let t=i.append(`line`);t.attr(`x1`,e.startPoint.x),t.attr(`y1`,e.startPoint.y),t.attr(`x2`,e.endPoint.x),t.attr(`y2`,e.endPoint.y),t.attr(`stroke-width`,`1`),t.attr(`stroke`,o),t.style(`fill`,`none`),e.type!==`rel_b`&&t.attr(`marker-end`,`url(#`+r+`-arrowhead)`),(e.type===`birel`||e.type===`rel_b`)&&t.attr(`marker-start`,`url(#`+r+`-arrowend)`),a=-1}else{let t=i.append(`path`);t.attr(`fill`,`none`).attr(`stroke-width`,`1`).attr(`stroke`,o).attr(`d`,`Mstartx,starty Qcontrolx,controly stopx,stopy `.replaceAll(`startx`,e.startPoint.x).replaceAll(`starty`,e.startPoint.y).replaceAll(`controlx`,e.startPoint.x+(e.endPoint.x-e.startPoint.x)/2-(e.endPoint.x-e.startPoint.x)/4).replaceAll(`controly`,e.startPoint.y+(e.endPoint.y-e.startPoint.y)/2).replaceAll(`stopx`,e.endPoint.x).replaceAll(`stopy`,e.endPoint.y)),e.type!==`rel_b`&&t.attr(`marker-end`,`url(#`+r+`-arrowhead)`),(e.type===`birel`||e.type===`rel_b`)&&t.attr(`marker-start`,`url(#`+r+`-arrowend)`)}let u=e.label.width,d=n.messageFont();xe(n)(e.label.text,i,Math.min(e.startPoint.x,e.endPoint.x)+Math.abs(e.endPoint.x-e.startPoint.x)/2+s,Math.min(e.startPoint.y,e.endPoint.y)+Math.abs(e.endPoint.y-e.startPoint.y)/2+l,u,e.label.height,{fill:t},d),e.techn&&e.techn.text!==``&&(d=n.messageFont(),xe(n)(`[`+e.techn.text+`]`,i,Math.min(e.startPoint.x,e.endPoint.x)+Math.abs(e.endPoint.x-e.startPoint.x)/2+s,Math.min(e.startPoint.y,e.endPoint.y)+Math.abs(e.endPoint.y-e.startPoint.y)/2+n.messageFontSize+5+l,Math.max(u,e.techn.width),e.techn.height,{fill:t,"font-style":`italic`},d))}},`drawRels`),pe=n(function(e,t,n){let r=e.append(`g`),i=t.bgColor?t.bgColor:`none`,a=t.borderColor?t.borderColor:`#444444`,o=t.fontColor?t.fontColor:`black`,s={"stroke-width":1,"stroke-dasharray":`7.0,7.0`};t.nodeType&&(s={"stroke-width":1}),de(r,{x:t.x,y:t.y,fill:i,stroke:a,width:t.width,height:t.height,rx:2.5,ry:2.5,attrs:s});let l=n.boundaryFont();l.fontWeight=`bold`,l.fontSize+=2,l.fontColor=o,xe(n)(t.label.text,r,t.x,t.y+t.label.Y,t.width,t.height,{fill:`#444444`},l),t.type&&t.type.text!==``&&(l=n.boundaryFont(),l.fontColor=o,xe(n)(t.type.text,r,t.x,t.y+t.type.Y,t.width,t.height,{fill:`#444444`},l)),t.descr&&t.descr.text!==``&&(l=n.boundaryFont(),l.fontSize-=2,l.fontColor=o,xe(n)(t.descr.text,r,t.x,t.y+t.descr.Y,t.width,t.height,{fill:`#444444`},l))},`drawBoundary`),me=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-database`).attr(`fill-rule`,`evenodd`).attr(`clip-rule`,`evenodd`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z`)},`insertDatabaseIcon`),he=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-computer`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z`)},`insertComputerIcon`),ge=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-clock`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z`)},`insertClockIcon`),_e=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowhead`).attr(`refX`,9).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`)},`insertArrowHead`),ve=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowend`).attr(`refX`,1).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 z`)},`insertArrowEnd`),ye=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-filled-head`).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`insertArrowFilledHead`),be=n(function(e,t){let n=e.append(`defs`).append(`marker`).attr(`id`,t+`-crosshead`).attr(`markerWidth`,15).attr(`markerHeight`,8).attr(`orient`,`auto`).attr(`refX`,16).attr(`refY`,4);n.append(`path`).attr(`fill`,`black`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1px`).attr(`d`,`M 9,2 V 6 L16,4 Z`),n.append(`path`).attr(`fill`,`none`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1px`).attr(`d`,`M 0,1 L 6,7 M 6,1 L 0,7`)},`insertArrowCrossHead`),xe=(function(){function e(e,t,n,r,a,o,s){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,a,o,l,u){let{fontSize:d,fontFamily:f,fontWeight:p}=u,m=e.split(s.lineBreakRegex);for(let e=0;e{if(n===`sandbox`){let n=t(`#i`+e).node()?.contentDocument;if(!n)throw Error(`Sandbox iframe #i${e} is missing its content document`);return{root:t(n.body),doc:n}}return{root:t(`body`),doc:document}},`getDiagramRoot`),Ce=new Set([`system_queue`,`external_system_queue`,`container_queue`,`external_container_queue`,`component_queue`,`external_component_queue`]),we=new Set([`system_db`,`external_system_db`,`container_db`,`external_container_db`,`component_db`,`external_component_db`]),Te={person:`person`,box:`rounded`,rounded:`rounded`,cylinder:`cylinder`,database:`cylinder`,db:`cylinder`,queue:`h-cyl`,pipe:`h-cyl`,component:`fr-rect`},Ee=n(e=>e?Te[e.toLowerCase()]:void 0,`keywordShape`),De=n(e=>{let t=Ee(e.shape)??Ee(e.sprite);if(t)return t;if(e.tags)for(let t of e.tags.split(`,`)){let e=Ee(t.trim());if(e)return e}let n=e.typeC4Shape.text;return n===`person`||n===`external_person`?`person`:we.has(n)?`cylinder`:Ce.has(n)?`h-cyl`:`rounded`},`resolveNodeShape`),Oe={person:`Person`,system:`Software System`,container:`Container`,component:`Component`},ke=n(e=>{let t=e.replace(/^external_/,``).replace(/_(db|queue)$/,``);return Oe[t]??t.replace(/_/g,` `)},`stereotypeLabel`),Ae=n(e=>e.startsWith(`external_`),`isExternal`),je=n(e=>{let t=ke(e.typeC4Shape.text);return e.techn?.text?`[${t}: ${e.techn.text}]`:`[${t}]`},`stereotypeText`),Me=[`person`,`system`,`system_db`,`system_queue`,`container`,`container_db`,`container_queue`,`component`,`component_db`,`component_queue`].flatMap(e=>[e,`external_${e}`]),Ne=new Set(Me),Pe=n(e=>Ne.has(e),`isC4ElementType`),Fe=n((e,t)=>{let n=e.typeC4Shape.text,r=e.bgColor??(Pe(n)&&t[`${n}_bg_color`]),i=e.borderColor??(Pe(n)&&t[`${n}_border_color`]),a=[];return r&&a.push(`fill:${r}`),i&&a.push(`stroke:${i}`),a.push(`color:${e.fontColor??`#FFFFFF`}`),a},`elementCssStyles`),Ie=n((e,t,n,r,i)=>{let a=e.typeC4Shape.text,o=[`c4-shape`,`c4-${a}`];Ae(a)&&o.push(`c4-external`);let s=De(e),l=Fe(e,t);return(s===`rounded`||s===`fr-rect`)&&l.push(`rx:12px`,`ry:12px`),{id:e.alias,label:e.label.text,stereotype:je(e),description:e.descr?.text?[e.descr.text]:void 0,labelType:`string`,isGroup:!1,shape:s,cssClasses:o.join(` `),cssStyles:l,padding:n,look:r,useHtmlLabels:!1,width:i}},`buildC4Node`),Le=0,Re=0,ze=4,Be=2;y.yy=ue;var $={},Ve=class{static{n(this,`Bounds`)}constructor(e){this.name=``,this.data={},this.data.startx=void 0,this.data.stopx=void 0,this.data.starty=void 0,this.data.stopy=void 0,this.data.widthLimit=void 0,this.nextData={},this.nextData.startx=void 0,this.nextData.stopx=void 0,this.nextData.starty=void 0,this.nextData.stopy=void 0,this.nextData.cnt=0,He(e.db.getConfig())}setData(e,t,n,r){this.nextData.startx=this.data.startx=e,this.nextData.stopx=this.data.stopx=t,this.nextData.starty=this.data.starty=n,this.nextData.stopy=this.data.stopy=r}updateVal(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])}insert(e){this.nextData.cnt=this.nextData.cnt+1;let t=this.nextData.stopx,n=this.data.widthLimit,r=this.nextData.startx===this.nextData.stopx?t+e.margin:t+e.margin*2,i=r+e.width,a=this.nextData.starty+e.margin*2,o=a+e.height;(r>=n||i>=n||this.nextData.cnt>ze)&&(r=this.nextData.startx+e.margin+$.nextLinePaddingX,a=this.nextData.stopy+e.margin*2,this.nextData.stopx=i=r+e.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=o=a+e.height,this.nextData.cnt=1),e.x=r,e.y=a,this.updateVal(this.data,`startx`,r,Math.min),this.updateVal(this.data,`starty`,a,Math.min),this.updateVal(this.data,`stopx`,i,Math.max),this.updateVal(this.data,`stopy`,o,Math.max),this.updateVal(this.nextData,`startx`,r,Math.min),this.updateVal(this.nextData,`starty`,a,Math.min),this.updateVal(this.nextData,`stopx`,i,Math.max),this.updateVal(this.nextData,`stopy`,o,Math.max)}init(e){this.name=``,this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,widthLimit:void 0},this.nextData={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,cnt:0},He(e.db.getConfig())}bumpLastMargin(e){this.data.stopx+=e,this.data.stopy+=e}},He=n(function(e){o($,e),e?.fontFamily&&($.personFontFamily=$.systemFontFamily=$.messageFontFamily=e.fontFamily),e?.fontSize&&($.personFontSize=$.systemFontSize=$.messageFontSize=e.fontSize),e?.fontWeight&&($.personFontWeight=$.systemFontWeight=$.messageFontWeight=e.fontWeight)},`setConf`),Ue=n(e=>({fontFamily:e.boundaryFontFamily,fontSize:e.boundaryFontSize,fontWeight:e.boundaryFontWeight}),`boundaryFont`),We=n(e=>({fontFamily:e.messageFontFamily,fontSize:e.messageFontSize,fontWeight:e.messageFontWeight}),`messageFont`);function Ge(e,t,n,r,i){let a=t[e];if(!a.width){if(n)a.text=p(a.text,i,r),a.textLines=a.text.split(s.lineBreakRegex).length,a.width=i,a.height=m(a.text,r);else{let e=a.text.split(s.lineBreakRegex);a.textLines=e.length;let t=0;a.height=0,a.width=0;for(let n of e)a.width=Math.max(h(n,r),a.width),t=m(n,r),a.height+=t}}return a}n(Ge,`calcC4ShapeTextWH`);var Ke=n(function(e,t,n){let r=n.data.startx,i=n.data.starty;t.x=r,t.y=i,t.width=n.data.stopx-r,t.height=n.data.stopy-i,t.intersect=e=>g.rect({x:t.x+t.width/2,y:t.y+t.height/2,width:t.width,height:t.height},e),t.label.y=$.c4ShapeMargin-35;let a=t.wrap&&$.wrap,o=Ue($);o.fontSize+=2,o.fontWeight=`bold`,Ge(`label`,t,a,o,h(t.label.text,o)),Q.drawBoundary(e,t,$)},`drawBoundary`),qe=n(async function(e,t,r,i){let a=u(),o=a.look??`classic`,s={config:a},l=t.attr(`id`)??``,d=i.map(e=>r[Number(e)]),f=n(e=>{let t=e.shape?_[e.shape]:void 0;if(!t)throw Error(`C4: no shape handler for "${e.shape}"`);return t},`shapeHandlerFor`);await Promise.all(d.map(async e=>{let n=Ie(e,$,$.c4ShapePadding,o,$.width);n.domId=`${l}-${n.id}`;let r=await f(n)(t,n,s);e.width=n.width??$.width,e.height=n.height??$.height,e.margin=$.c4ShapeMargin,r.remove()}));for(let t of d)e.insert(t);await Promise.all(d.map(async e=>{let n=Ie(e,$,$.c4ShapePadding,o,$.width);n.domId=`${l}-${n.id}`,n.x=e.x+e.width/2,n.y=e.y+e.height/2;let r=t.append(`g`).attr(`transform`,`translate(${e.x+e.width/2}, ${e.y+e.height/2})`);await f(n)(r,n,s),e.intersect=n.intersect})),e.bumpLastMargin($.c4ShapeMargin)},`drawC4ShapeArray`),Je=class{static{n(this,`Point`)}constructor(e,t){this.x=e,this.y=t}},Ye=n(function(e,t){if(!e.intersect)throw Error(`C4 element "${e.alias}" has no intersect function. Please report this to https://github.com/mermaid-js/mermaid/issues`);let{x:n,y:r}=e.intersect(t);return new Je(n,r)},`getIntersectPoint`),Xe=n(function(e,t){let n={x:0,y:0};n.x=t.x+t.width/2,n.y=t.y+t.height/2;let r=Ye(e,n);return n.x=e.x+e.width/2,n.y=e.y+e.height/2,{startPoint:r,endPoint:Ye(t,n)}},`getIntersectPoints`),Ze=n(function(e,t,n,r,i){let a=r.db.getC4Type(),o=0;for(let e of t){o+=1;let t=e.wrap&&$.wrap,r=We($);a===`C4Dynamic`&&(e.label.text=o+`: `+e.label.text);let i=h(e.label.text,r);Ge(`label`,e,t,r,i),e.techn&&e.techn.text!==``&&(i=h(e.techn.text,r),Ge(`techn`,e,t,r,i)),e.descr&&e.descr.text!==``&&(i=h(e.descr.text,r),Ge(`descr`,e,t,r,i));let s=n(e.from),l=n(e.to);if(!s||!l)throw Error(`C4 rel "${e.from}" -> "${e.to}" references an unknown shape or boundary`);let u=Xe(s,l);if(!u.startPoint||!u.endPoint)throw Error(`Could not calculate intersection points for rel "${e.from}" -> "${e.to}"`);e.startPoint=u.startPoint,e.endPoint=u.endPoint}Q.drawRels(e,t,$,i)},`drawRels`);async function Qe(e,t,n,r,i){let a=i.db,o=new Ve(i);o.data.widthLimit=n.data.widthLimit/Math.min(Be,r.length);for(let[s,l]of r.entries()){let r=0;l.image={width:0,height:0,Y:0},l.sprite&&(l.image.width=48,l.image.height=48,l.image.Y=r,r=l.image.Y+l.image.height);let u=l.wrap&&$.wrap,d=Ue($);d.fontSize+=2,d.fontWeight=`bold`;let f=Ge(`label`,l,u,d,o.data.widthLimit);if(f.Y=r+8,r=f.Y+f.height,l.type&&l.type.text!==``){l.type.text=`[`+l.type.text+`]`;let e=Ge(`type`,l,u,Ue($),o.data.widthLimit);e.Y=r+5,r=e.Y+e.height}if(l.descr&&l.descr.text!==``){let e=Ue($);e.fontSize-=2;let t=Ge(`descr`,l,u,e,o.data.widthLimit);t.Y=r+20,r=t.Y+t.height}if(s==0||s%Be===0){let e=n.data.startx+$.diagramMarginX,t=n.data.stopy+$.diagramMarginY+r;o.setData(e,e,t,t)}else{let e=o.data.stopx===o.data.startx?o.data.startx:o.data.stopx+$.diagramMarginX,t=o.data.starty;o.setData(e,e,t,t)}o.name=l.alias;let p=a.getC4ShapeArray(l.alias),m=a.getC4ShapeKeys(l.alias);m.length>0&&await qe(o,e,p,m),t=l.alias;let h=a.getBoundaries(t);h.length>0&&await Qe(e,t,o,h,i),l.alias!==`global`&&Ke(e,l,o),n.data.stopy=Math.max(o.data.stopy+$.c4ShapeMargin,n.data.stopy),n.data.stopx=Math.max(o.data.stopx+$.c4ShapeMargin,n.data.stopx),Le=Math.max(Le,n.data.stopx),Re=Math.max(Re,n.data.stopy)}}n(Qe,`drawInsideBoundary`);var $e={drawPersonOrSystemArray:qe,drawBoundary:Ke,setConf:He,draw:n(async function(t,n,r,i){$=x(`c4`);let o=u().securityLevel,{root:s}=Se(n,o),l=i.db;l.setWrap($.wrap),ze=l.getC4ShapeInRow(),Be=l.getC4BoundaryInRow(),e.debug(`C:${JSON.stringify($,null,2)}`);let d=s.select(`[id="${n}"]`);Q.insertComputerIcon(d,n),Q.insertDatabaseIcon(d,n),Q.insertClockIcon(d,n);let f=new Ve(i);f.setData($.diagramMarginX,$.diagramMarginX,$.diagramMarginY,$.diagramMarginY),f.data.widthLimit=screen.availWidth,Le=$.diagramMarginX,Re=$.diagramMarginY;let p=l.getTitle();await Qe(d,``,f,l.getBoundaries(``),i),Q.insertArrowHead(d,n),Q.insertArrowEnd(d,n),Q.insertArrowCrossHead(d,n),Q.insertArrowFilledHead(d,n),Ze(d,l.getRels(),l.getC4Shape,i,n),f.data.stopx=Le,f.data.stopy=Re;let m=f.data,h=m.startx,g=m.starty,_=Re-g+2*$.diagramMarginY,v=Le-h,y=v+2*$.diagramMarginX;p&&d.append(`text`).text(p).attr(`x`,v/2-4*$.diagramMarginX).attr(`y`,g+$.diagramMarginY),a(d,_,y,$.useMaxWidth);let b=p?60:0;d.attr(`viewBox`,h-$.diagramMarginX+` -`+($.diagramMarginY+b)+` `+y+` `+(_+b)),e.debug(`models:`,m)},`draw`)},et=n(()=>{let e=u().c4??{},t=new CSSStyleSheet;for(let n of Me){let r=t.cssRules[t.insertRule(`.c4-shape.c4-${n} .label {}`,t.cssRules.length)],i=e[`${n}FontFamily`],a=e[`${n}FontSize`],o=e[`${n}FontWeight`];i&&r.style.setProperty(`font-family`,i),a&&r.style.setProperty(`font-size`,typeof a==`number`?`${a}px`:a),o&&r.style.setProperty(`font-weight`,String(o))}return[...t.cssRules].filter(e=>e.style.length>0).map(e=>` ${e.cssText}`).join(` +`)},`elementFontStyles`),tt={parser:b,db:ue,renderer:$e,styles:n(e=>`.person { + stroke: ${e.personBorder}; + fill: ${e.personBkg}; + } +${et()} + + /* The element font colour is set inline per element (default white); the + label text takes it via currentColor. */ + .c4-shape .label, + .c4-shape .label text { + color: inherit; + fill: currentColor; + } + /* Structurizr typography: bold name, smaller stereotype/type and description lines. */ + .c4-shape .label .c4-name { + font-weight: bold; + } + .c4-shape .label .c4-type { + font-size: 0.75em; + } + .c4-shape .label .c4-descr { + font-size: 0.82em; + } + .c4-shape .basic, + .c4-shape rect, + .c4-shape path, + .c4-shape circle, + .c4-shape ellipse, + .c4-shape line { + stroke-width: 2px; + } +`,`getStyles`),init:n(({c4:e,wrap:t})=>{$e.setConf(e),ue.setWrap(t)},`init`)};export{tt as diagram}; \ No newline at end of file diff --git a/www/assets/channel-_oCHZhRo.js b/www/assets/channel-_oCHZhRo.js new file mode 100644 index 0000000..e3f17de --- /dev/null +++ b/www/assets/channel-_oCHZhRo.js @@ -0,0 +1 @@ +import{ct as e,st as t}from"./chunk-O7XYJQB3-Bce2lzyF.js";var n=(n,r)=>e.lang.round(t.parse(n)[r]);export{n as t}; \ No newline at end of file diff --git a/www/assets/chunk-2Q5K7J3B-C1jixKkw.js b/www/assets/chunk-2Q5K7J3B-C1jixKkw.js new file mode 100644 index 0000000..4c6fa39 --- /dev/null +++ b/www/assets/chunk-2Q5K7J3B-C1jixKkw.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=class{constructor(e){this.init=e,this.records=this.init()}static{e(this,`ImperativeState`)}reset(){this.records=this.init()}};export{t}; \ No newline at end of file diff --git a/www/assets/chunk-3FUC2YCW-CmoZ3fbX.js b/www/assets/chunk-3FUC2YCW-CmoZ3fbX.js new file mode 100644 index 0000000..087c84b --- /dev/null +++ b/www/assets/chunk-3FUC2YCW-CmoZ3fbX.js @@ -0,0 +1,2 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/sizeCapture-INFHLROL-B0uUizjq.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js"])))=>i.map(i=>d[i]); +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{b as n,et as r,x as i}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as a}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{o}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as s,n as c,r as l,t as u}from"./chunk-5DYCD2WN-WToj2Jza.js";import{a as d,f,h as p,i as m,o as h,p as g,r as ee,s as _,u as v}from"./index-DoQkmpth.js";import{t as y}from"./graphlib-C9Tl7QrK.js";function b(e,{edgePathsClass:t=`edges edgePaths`}={}){let n=e.insert(`g`).attr(`class`,`root`);return{clusters:n.insert(`g`).attr(`class`,`clusters`),edgePaths:n.insert(`g`).attr(`class`,t),edgeLabels:n.insert(`g`).attr(`class`,`edgeLabels`),nodes:n.insert(`g`).attr(`class`,`nodes`),rootGroups:n}}t(b,`createLayoutElementGroups`);async function x(e,t,n){if(t.label){let{shapeSvg:r,bbox:i}=await o(e,n===void 0?t:{...t,width:n});t.labelBBox={width:i.width,height:i.height},r.remove()}else t.labelBBox={width:0,height:0}}t(x,`measureGroupLabel`);async function S(e,t,n){let r=await l(e,t,n),i=r.node()?.getBBox()??{width:0,height:0};return t.width=i.width,t.height=i.height,r}t(S,`insertMeasuredNode`);function C(e,t,n){let r=e,i=new Set;for(;r;){if(r.dir)return r.dir;if(!r.parentId||i.has(r.parentId))break;i.add(r.parentId),r=t.get(r.parentId)}return n}t(C,`resolveNodeDir`);async function w(e,t,n={}){let a=new y({multigraph:!0,compound:!0}),o=[...t.edges],s=i(),c=b(e),{edgeLabels:l,nodes:u}=c,f=new Map,p=new Map(t.nodes.map(e=>[e.id,e])),m=t.direction,h=e.node()!=null;await Promise.all(t.nodes.map(async e=>{if(e.isGroup){if(h){let t=n.unwrapGroupLabels&&e.labelType!==`markdown`;await x(u,e,t?1/0:void 0)}a.setNode(e.id,{...e})}else{if(h){let t=await S(u,e,{config:s,dir:C(e,p,m)});f.set(e.id,t)}a.setNode(e.id,{...e})}}));for(let e of o)h&&d(e)&&await _(l,e),a.setEdge(e.start,e.end,{...e},e.id),t.edges.some(t=>t.id===e.id)||t.edges.push(e);if(globalThis.mermaidCaptureSizes){let{captureNodeSizes:n}=await r(async()=>{let{captureNodeSizes:e}=await import(`./sizeCapture-INFHLROL-B0uUizjq.js`);return{captureNodeSizes:e}},__vite__mapDeps([0,1]));n(e,t)}return{graph:a,groups:c,nodeElements:f}}t(w,`createGraphWithElements`);var T=new Map,E=new Map,D=new Map,O=t(()=>{E.clear(),D.clear(),T.clear()},`clear`),k=t((t,n)=>{let r=E.get(n)||[];return e.trace(`In isDescendant`,n,` `,t,` = `,r.includes(t)),r.includes(t)},`isDescendant`),A=t((t,n)=>{let r=E.get(n)||[];return e.info(`Descendants of `,n,` is `,r),e.info(`Edge is `,t),t.v===n||t.w===n?!1:r?r.includes(t.v)||k(t.v,n)||k(t.w,n)||r.includes(t.w):(e.debug(`Tilt, `,n,`,not in descendants`),!1)},`edgeInCluster`),j=t((t,n,r,i)=>{e.debug(`Copying children of `,t,`root`,i,`data`,n.node(t),i);let a=n.children(t)||[];t!==i&&a.push(t),e.debug(`Copying (nodes) clusterId`,t,`nodes`,a),a.forEach(a=>{if(n.children(a).length>0)j(a,n,r,i);else{let o=n.node(a);e.info(`cp `,a,` to `,i,` with parent `,t),r.setNode(a,o),i!==n.parent(a)&&(e.debug(`Setting parent`,a,n.parent(a)),r.setParent(a,n.parent(a))),t!==i&&a!==t?(e.debug(`Setting parent`,a,t),r.setParent(a,t)):(e.info(`In copy `,t,`root`,i,`data`,n.node(t),i),e.debug(`Not Setting parent for node=`,a,`cluster!==rootId`,t!==i,`node!==clusterId`,a!==t));let s=n.edges(a);e.debug(`Copying Edges`,s),s.forEach(a=>{e.info(`Edge`,a);let o=n.edge(a.v,a.w,a.name);e.info(`Edge data`,o,i);try{A(a,i)?(e.info(`Copying as `,a.v,a.w,o,a.name),r.setEdge(a.v,a.w,o,a.name),e.info(`newGraph edges `,r.edges(),r.edge(r.edges()[0]))):e.info(`Skipping copy of edge `,a.v,`-->`,a.w,` rootId: `,i,` clusterId:`,t)}catch(t){e.error(t)}})}e.debug(`Removing node`,a),n.removeNode(a)})},`copy`),M=t((e,t)=>{let n=t.children(e),r=[...n];for(let i of n)D.set(i,e),r=[...r,...M(i,t)];return r},`extractDescendants`),N=t((e,t,n)=>{let r=e.edges().filter(e=>e.v===t||e.w===t),i=e.edges().filter(e=>e.v===n||e.w===n),a=r.map(e=>({v:e.v===t?n:e.v,w:e.w===t?t:e.w})),o=i.map(e=>({v:e.v,w:e.w}));return a.filter(e=>o.some(t=>e.v===t.v&&e.w===t.w))},`findCommonEdges`),P=t((t,n,r)=>{let i=n.children(t);if(e.trace(`Searching children of id `,t,i),i.length<1)return t;let a;for(let e of i){let t=P(e,n,r),i=N(n,r,t);if(t){if(i.length>0)a=t;else return t}}return a},`findNonClusterChild`),F=t(e=>!T.has(e)||!T.get(e).externalConnections?e:T.has(e)?T.get(e).id:e,`getAnchorId`),I=t((t,n)=>{if(!t||n>10){e.debug(`Opting out, no graph `);return}e.debug(`Opting in, graph `),t.nodes().forEach(function(n){t.children(n).length>0&&(e.debug(`Cluster identified`,n,` Replacement id in edges: `,P(n,t,n)),E.set(n,M(n,t)),T.set(n,{id:P(n,t,n),clusterData:t.node(n)}))}),t.nodes().forEach(function(n){let r=t.children(n),i=t.edges();r.length>0?(e.debug(`Cluster identified`,n,E),i.forEach(t=>{k(t.v,n)^k(t.w,n)&&(e.debug(`Edge: `,t,` leaves cluster `,n),e.debug(`Descendants of XXX `,n,`: `,E.get(n)),T.get(n).externalConnections=!0)})):e.debug(`Not a cluster `,n,E)});for(let e of T.keys()){let n=T.get(e).id,r=t.parent(n);r!==e&&T.has(r)&&!T.get(r).externalConnections&&(T.get(e).id=r);let i=t.edges().some(t=>t.v===e);if(n&&T.get(e)?.externalConnections&&i&&B(t,n,e)){let r=V(t,e,t.parent(n));r&&(T.get(e).id=r)}}t.edges().forEach(function(n){let r=t.edge(n);e.debug(`Edge `+n.v+` -> `+n.w+`: `+JSON.stringify(n)),e.debug(`Edge `+n.v+` -> `+n.w+`: `+JSON.stringify(t.edge(n)));let i=n.v,a=n.w;if(e.debug(`Fix XXX`,T,`ids:`,n.v,n.w,`Translating: `,T.get(n.v),` --- `,T.get(n.w)),T.get(n.v)||T.get(n.w)){if(e.debug(`Fixing and trying - removing XXX`,n.v,n.w,n.name),i=F(n.v),a=F(n.w),t.removeEdge(n.v,n.w,n.name),i!==n.v){let e=t.parent(i);T.get(e).externalConnections=!0,r.fromCluster=n.v}if(a!==n.w){let e=t.parent(a);T.get(e).externalConnections=!0,r.toCluster=n.w}e.debug(`Fix Replacing with XXX`,i,a,n.name),t.setEdge(i,a,r,n.name)}}),L(t,0),e.trace(T)},`adjustClustersAndEdges`),L=t((t,n)=>{if(n>10){e.error(`Bailing out`);return}let r=t.nodes(),i=!1;for(let e of r){let n=t.children(e);i||=n.length>0}if(!i){e.debug(`Done, no node has children`,t.nodes());return}e.debug(`Nodes = `,r,n);for(let i of r)if(e.debug(`Extracting node`,i,T,T.has(i)&&!T.get(i).externalConnections,!t.parent(i),t.node(i),t.children(`D`),` Depth `,n),!T.has(i))e.debug(`Not a cluster`,i,n);else if(!T.get(i).externalConnections&&t.children(i)&&t.children(i).length>0){e.debug(`Cluster without external connections, without a parent and with children`,i,n);let r=t.graph().rankdir===`TB`?`LR`:`TB`;T.get(i)?.clusterData?.dir&&(r=T.get(i).clusterData.dir,e.debug(`Fixing dir`,T.get(i).clusterData.dir,r));let a=new y({multigraph:!0,compound:!0}).setGraph({rankdir:r,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});j(i,t,a,i),t.setNode(i,{clusterNode:!0,id:i,clusterData:T.get(i).clusterData,label:T.get(i).label,graph:a})}else e.debug(`Cluster ** `,i,` **not meeting the criteria !externalConnections:`,!T.get(i).externalConnections,` no parent: `,!t.parent(i),` children `,t.children(i)&&t.children(i).length>0,t.children(`D`),n),e.debug(T);r=t.nodes(),e.debug(`New list of nodes`,r);for(let i of r){let r=t.node(i);e.debug(` Now next level`,i,r),r?.clusterNode&&L(r.graph,n+1)}},`extractor`),R=t((e,t)=>{if(t.length===0)return[];let n=Object.assign([],t);return t.forEach(t=>{let r=R(e,e.children(t));n=[...n,...r]}),n},`sorter`),z=t(e=>R(e,e.children()),`sortNodesByHierarchy`),B=t((e,t,n)=>{let r=e.parent(t);for(;r&&r!==n;){let t=T.get(r);if(t&&!t.externalConnections)return!0;r=e.parent(r)}return!1},`isNodeInExtractableCluster`),V=t((e,t,n)=>{let r=e.children(t)??[];for(let i of r){if(i===n||k(i,n))continue;let r=P(i,e,t);if(r&&!B(e,r,t))return r}return null},`findSafeAnchorNode`);function H({prepareLayout:e,measureLayout:n,runLayoutCore:r,paintLayout:i,afterPaint:a,paintOptions:o}){let s=n??W;return t(async function(t,n,c,l){let u=n.select(`g`);(c?.insertMarkers??v)(u,t.markers,t.type,t.diagramId),U();let d={element:u,helpers:c,options:l};d.preparedLayout=await e?.(t,d);let f=await s(t,d),p=await r(t,d),m={...d,measure:f};i?await i(t,m,p):await G(t,m,o),await a?.(t,m,p)},`render`)}t(H,`createCommonLayoutRenderer`);function U(){u(),ee(),g(),O()}t(U,`clearLayoutRenderState`);async function W(e,{element:t},n){return await w(t,e,n)}t(W,`defaultMeasureLayout`);async function G(e,t,n={}){let{measure:r}=t,{groups:i}=r;for(let r of n.getNodes?.(e,t)??e.nodes)n.skipNode?.(r,t)||await K(i,r,t,n);let a=J(e.nodes);for(let r of e.edges)Y(r,n)||await X(i,r,a,e,n,t)}t(G,`paintLayoutData`);async function K(e,t,n,r){t.clusterNode?s(t):q(t,n,r)?await p(e.clusters,t):s(t)}t(K,`paintLayoutNode`);function q(e,t,n){return e.isGroup===!0&&(n.isCluster?.(e,t)??!0)}t(q,`shouldPaintAsCluster`);function J(e){let t=new Map;for(let n of e)n?.id&&t.set(n.id,n);return t}t(J,`buildNodeLookup`);function Y(e,t){return e.isLayoutOnly||!!t.skipEdge?.(e)}t(Y,`shouldSkipPaintEdge`);async function X(e,t,n,r,i,a){let o=h(e.edgePaths,{...t},i.clusterDb??new Map,r.type,Z(t.start,t,n,a,i),Z(t.end,t,n,a,i),r.diagramId,Q(t,i));d(t)&&(m.has(t.id)||await _(e.edgeLabels,t),$(t,o))}t(X,`paintLayoutEdge`);function Z(e,t,n,r,i){return i.getEdgeNode?.(e,t,r)??(e?n.get(e)??{}:{})}t(Z,`getRenderedNode`);function Q(e,t){return typeof t.skipIntersect==`function`?t.skipIntersect(e):t.skipIntersect??!1}t(Q,`shouldSkipIntersect`);function $(t,r){let i=r?.updatedPath??r?.originalPath,o=n(),{subGraphTitleTotalMargin:s}=c({flowchart:o.flowchart??{}});if(t.label){let n=m.get(t.id),o=t.x,c=t.y;if(i){let n=a.calcLabelPosition(i);e.debug(`Moving label `+t.label+` from (`,o,`,`,c,`) to (`,n.x,`,`,n.y,`) abc88`),r?.updatedPath&&(o=n.x,c=n.y)}n.attr(`transform`,`translate(${o}, ${c+s/2})`)}if(t?.startLabelLeft){let e=f.get(t.id).startLeft,n=t?.x,r=t?.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeStart?10:0,`start_left`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.startLabelRight){let e=f.get(t.id).startRight,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeStart?10:0,`start_right`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.endLabelLeft){let e=f.get(t.id).endLeft,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,`end_left`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}if(t.endLabelRight){let e=f.get(t.id).endRight,n=t.x,r=t.y;if(i){let e=a.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,`end_right`,i);n=e.x,r=e.y}e.attr(`transform`,`translate(${n}, ${r})`)}}t($,`positionRenderedEdgeLabel`);export{W as a,z as c,b as i,T as n,P as o,H as r,S as s,I as t}; \ No newline at end of file diff --git a/www/assets/chunk-5DYCD2WN-WToj2Jza.js b/www/assets/chunk-5DYCD2WN-WToj2Jza.js new file mode 100644 index 0000000..824607e --- /dev/null +++ b/www/assets/chunk-5DYCD2WN-WToj2Jza.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{u as n}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{s as r}from"./chunk-7INBJB4K-BkZ96Hf7.js";var i=t(({flowchart:e})=>{let t=e?.subGraphTitleMargin?.top??0,n=e?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:n,subGraphTitleTotalMargin:t+n}},`getSubGraphTitleMargins`),a=new Map;async function o(e,t,i){let o,s;t.shape===`rect`&&(t.shape=t.rx&&t.ry?`roundedRect`:`squareRect`);let c=t.shape?r[t.shape]:void 0;if(!c)throw Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let n;i.config.securityLevel===`sandbox`?n=`_top`:t.linkTarget&&(n=t.linkTarget||`_blank`),o=e.insert(`svg:a`).attr(`xlink:href`,t.link).attr(`target`,n??null),s=await c(o,t,i)}else s=await c(e,t,i),o=s;return o.attr(`data-look`,n(t.look)),t.tooltip&&s.attr(`title`,t.tooltip),a.set(t.id,o),t.haveCallback&&o.attr(`class`,o.attr(`class`)+` clickable`),o}t(o,`insertNode`);var s=t((e,t)=>{a.set(t.id,e)},`setNodeElem`),c=t(()=>{a.clear()},`clear`),l=t(t=>{let n=a.get(t.id);e.trace(`Transforming node`,t.diff,t,`translate(`+(t.x-t.width/2-5)+`, `+t.width/2+`)`);let r=t.diff||0;return t.clusterNode?n.attr(`transform`,`translate(`+(t.x+r-t.width/2)+`, `+(t.y-t.height/2-8)+`)`):n.attr(`transform`,`translate(`+t.x+`, `+t.y+`)`),r},`positionNode`);export{s as a,l as i,i as n,o as r,c as t}; \ No newline at end of file diff --git a/www/assets/chunk-5VM5RSS4-ZNzvKenW.js b/www/assets/chunk-5VM5RSS4-ZNzvKenW.js new file mode 100644 index 0000000..31131d3 --- /dev/null +++ b/www/assets/chunk-5VM5RSS4-ZNzvKenW.js @@ -0,0 +1,15 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=e(()=>` + /* Font Awesome icon styling - consolidated */ + .label-icon { + display: inline-block; + height: 1em; + overflow: visible; + vertical-align: -0.125em; + } + + .node .label-icon path { + fill: currentColor; + stroke: revert; + stroke-width: revert; + } +`,`getIconStyles`);export{t}; \ No newline at end of file diff --git a/www/assets/chunk-742MDFTN-5mFByRwZ.js b/www/assets/chunk-742MDFTN-5mFByRwZ.js new file mode 100644 index 0000000..04ac6bd --- /dev/null +++ b/www/assets/chunk-742MDFTN-5mFByRwZ.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{b as n,z as r}from"./chunk-O7XYJQB3-Bce2lzyF.js";var i=Object.freeze({left:0,top:0,width:16,height:16}),a=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),o=Object.freeze({...i,...a}),s=Object.freeze({...o,body:``,hidden:!1}),c=Object.freeze({width:null,height:null}),l=Object.freeze({...c,...a}),u=(e,t,n,r=``)=>{let i=e.split(`:`);if(e.slice(0,1)===`@`){if(i.length<2||i.length>3)return null;r=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){let e=i.pop(),n=i.pop(),a={provider:i.length>0?i[0]:r,prefix:n,name:e};return t&&!d(a)?null:a}let a=i[0],o=a.split(`-`);if(o.length>1){let e={provider:r,prefix:o.shift(),name:o.join(`-`)};return t&&!d(e)?null:e}if(n&&r===``){let e={provider:r,prefix:``,name:a};return t&&!d(e,n)?null:e}return null},d=(e,t)=>e?!!((t&&e.prefix===``||e.prefix)&&e.name):!1;function f(e,t){let n={};!e.hFlip!=!t.hFlip&&(n.hFlip=!0),!e.vFlip!=!t.vFlip&&(n.vFlip=!0);let r=((e.rotate||0)+(t.rotate||0))%4;return r&&(n.rotate=r),n}function p(e,t){let n=f(e,t);for(let r in s)r in a?r in e&&!(r in n)&&(n[r]=a[r]):r in t?n[r]=t[r]:r in e&&(n[r]=e[r]);return n}function m(e,t){let n=e.icons,r=e.aliases||Object.create(null),i=Object.create(null);function a(e){if(n[e])return i[e]=[];if(!(e in i)){i[e]=null;let t=r[e]&&r[e].parent,n=t&&a(t);n&&(i[e]=[t].concat(n))}return i[e]}return(t||Object.keys(n).concat(Object.keys(r))).forEach(a),i}function h(e,t,n){let r=e.icons,i=e.aliases||Object.create(null),a={};function o(e){a=p(r[e]||i[e],a)}return o(t),n.forEach(o),p(e,a)}function g(e,t){if(e.icons[t])return h(e,t,[]);let n=m(e,[t])[t];return n?h(e,t,n):null}var _=/(-?[0-9.]*[0-9]+[0-9.]*)/g,v=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function y(e,t,n){if(t===1)return e;if(n||=100,typeof e==`number`)return Math.ceil(e*t*n)/n;if(typeof e!=`string`)return e;let r=e.split(_);if(r===null||!r.length)return e;let i=[],a=r.shift(),o=v.test(a);for(;;){if(o){let e=parseFloat(a);isNaN(e)?i.push(a):i.push(Math.ceil(e*t*n)/n)}else i.push(a);if(a=r.shift(),a===void 0)return i.join(``);o=!o}}function b(e,t=`defs`){let n=``,r=e.indexOf(`<`+t);for(;r>=0;){let i=e.indexOf(`>`,r),a=e.indexOf(``,a);if(o===-1)break;n+=e.slice(i+1,a).trim(),e=e.slice(0,r).trim()+e.slice(o+1)}return{defs:n,content:e}}function x(e,t){return e?``+e+``+t:t}function S(e,t,n){let r=b(e);return x(r.defs,t+r.content+n)}var C=e=>e===`unset`||e===`undefined`||e===`none`;function w(e,t){let n={...o,...e},r={...l,...t},i={left:n.left,top:n.top,width:n.width,height:n.height},a=n.body;[n,r].forEach(e=>{let t=[],n=e.hFlip,r=e.vFlip,o=e.rotate;n?r?o+=2:(t.push(`translate(`+(i.width+i.left).toString()+` `+(0-i.top).toString()+`)`),t.push(`scale(-1 1)`),i.top=i.left=0):r&&(t.push(`translate(`+(0-i.left).toString()+` `+(i.height+i.top).toString()+`)`),t.push(`scale(1 -1)`),i.top=i.left=0);let s;switch(o<0&&(o-=Math.floor(o/4)*4),o%=4,o){case 1:s=i.height/2+i.top,t.unshift(`rotate(90 `+s.toString()+` `+s.toString()+`)`);break;case 2:t.unshift(`rotate(180 `+(i.width/2+i.left).toString()+` `+(i.height/2+i.top).toString()+`)`);break;case 3:s=i.width/2+i.left,t.unshift(`rotate(-90 `+s.toString()+` `+s.toString()+`)`)}o%2==1&&(i.left!==i.top&&(s=i.left,i.left=i.top,i.top=s),i.width!==i.height&&(s=i.width,i.width=i.height,i.height=s)),t.length&&(a=S(a,``,``))});let s=r.width,c=r.height,u=i.width,d=i.height,f,p;s===null?(p=c===null?`1em`:c===`auto`?d:c,f=y(p,u/d)):(f=s===`auto`?u:s,p=c===null?y(f,d/u):c===`auto`?d:c);let m={},h=(e,t)=>{C(t)||(m[e]=t.toString())};h(`width`,f),h(`height`,p);let g=[i.left,i.top,u,d];return m.viewBox=g.join(` `),{attributes:m,viewBox:g,body:a}}var T=/\sid="(\S+)"/g,E=new Map;function D(e){e=e.replace(/[0-9]+$/,``)||`a`;let t=E.get(e)||0;return E.set(e,t+1),t?`${e}${t}`:e}function O(e){let t=[],n;for(;n=T.exec(e);)t.push(n[1]);if(!t.length)return e;let r=`suffix`+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(t=>{let n=D(t),i=t.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);e=e.replace(RegExp(`([#;"])(`+i+`)([")]|\\.[a-z])`,`g`),`$1`+n+r+`$3`)}),e=e.replace(new RegExp(r,`g`),``),e}function k(e,t){let n=e.indexOf(`xlink:`)===-1?``:` xmlns:xlink="http://www.w3.org/1999/xlink"`;for(let e in t)n+=` `+e+`="`+t[e]+`"`;return``+e+``}var A={body:`?`,height:80,width:80},j=new Map,M=new Map,N=t(t=>{for(let n of t){if(!n.name)throw Error(`Invalid icon loader. Must have a "name" property with non-empty string value.`);if(e.debug(`Registering icon pack:`,n.name),`loader`in n)M.set(n.name,n.loader);else if(`icons`in n)j.set(n.name,n.icons);else throw e.error(`Invalid icon loader:`,n),Error(`Invalid icon loader. Must have either "icons" or "loader" property.`)}},`registerIconPacks`),P=t(async(t,n)=>{let r=u(t,!0,n!==void 0);if(!r)throw Error(`Invalid icon name: ${t}`);let i=r.prefix||n;if(!i)throw Error(`Icon name must contain a prefix: ${t}`);let a=j.get(i);if(!a){let t=M.get(i);if(!t)throw Error(`Icon set not found: ${r.prefix}`);try{a={...await t(),prefix:i},j.set(i,a)}catch(t){throw e.error(t),Error(`Failed to load icon set: ${r.prefix}`)}}let o=g(a,r.name);if(!o)throw Error(`Icon not found: ${t}`);return o},`getRegisteredIconData`),F=t(async e=>{try{return await P(e),!0}catch{return!1}},`isIconAvailable`),I=t(async(t,i,a)=>{let o;try{o=await P(t,i?.fallbackPrefix)}catch(t){e.error(t),o=A}let s=w(o,i),c=k(O(s.body),{...s.attributes,...a});return r(c,n())},`getIconSVG`);export{A as i,F as n,N as r,I as t}; \ No newline at end of file diff --git a/www/assets/chunk-7INBJB4K-BkZ96Hf7.js b/www/assets/chunk-7INBJB4K-BkZ96Hf7.js new file mode 100644 index 0000000..fd4f019 --- /dev/null +++ b/www/assets/chunk-7INBJB4K-BkZ96Hf7.js @@ -0,0 +1,62 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,B as i,M as a,T as o,b as s,f as c,g as l,x as u,z as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as f,p,r as m,u as h}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{a as g,i as _,r as v,t as y}from"./chunk-7PRAP22T-DSs4vaIy.js";import{n as b,t as x}from"./chunk-742MDFTN-5mFByRwZ.js";import{n as S,r as C}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{s as w}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{t as T}from"./rough.esm-Dy-Kn_BL.js";var E=1,D=3;async function O(e){let t=e.getElementsByTagName(`img`);if(!t||t.length===0)return;let r=!k(e);await Promise.all([...t].map(e=>new Promise(t=>{function i(){if(e.style.display=`flex`,e.style.flexDirection=`column`,r){let t=u().fontSize?u().fontSize:window.getComputedStyle(document.body).fontSize,[n=c.fontSize]=p(t),r=n*5+`px`;e.style.minWidth=r,e.style.maxWidth=r}else e.style.width=`100%`;t(e)}n(i,`setupImage`),setTimeout(()=>{e.complete&&i()}),e.addEventListener(`error`,i),e.addEventListener(`load`,i)})))}n(O,`configureLabelImages`);function k(e){return e.nodeType===D?e.textContent?.trim()!==``:e.nodeType!==E||e.tagName.toLowerCase()===`img`?!1:[...e.childNodes].some(k)}n(k,`hasTextBesidesImages`);var A=3,j=32,M=n(async(e,n,r)=>{let i=u(),a=e.insert(`g`).attr(`class`,r??`node default`).attr(`id`,n.domId||n.id),o=a.insert(`g`).attr(`class`,`label`).attr(`style`,h(n.labelStyle)),s=[{text:typeof n.label==`string`?n.label:n.label?.[0]??``,cssClass:`c4-name`},{text:n.stereotype,cssClass:`c4-type`},...(n.description??[]).map(e=>({text:e,cssClass:`c4-descr`}))].filter(e=>e.text),c=n.width?Math.max(n.width-2*(n.padding??0),j):u().flowchart?.wrappingWidth??200,l=i.c4?.wrap??!0?c:1/0,p=await Promise.all(s.map(async e=>{let r=o.append(`g`).attr(`class`,e.cssClass),a=await S(r,d(f(e.text??``),i),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:l,style:n.labelStyle},i);return t(a).selectAll(`tspan.text-outer-tspan`).attr(`text-anchor`,`middle`),t(a).selectAll(`tspan.text-inner-tspan`).attr(`font-weight`,null).attr(`font-style`,null),{el:r,box:r.node().getBBox()}})),m=Math.max(...p.map(({box:e})=>e.width),0),g=0;for(let{el:e,box:t}of p)e.attr(`transform`,`translate(${m/2-t.x-t.width/2}, ${g-t.y})`),g+=t.height+A;let _=p.length>0?g-A:0;return o.insert(`rect`,`:first-child`),o.attr(`transform`,`translate(${-m/2}, ${-_/2})`),{shapeSvg:a,bbox:o.node().getBBox(),halfPadding:(n.padding??0)/2,label:o}},`c4LabelHelper`),N=n((e,t)=>{let{x:r,y:i,width:a,height:o}=e;return a>=t?e:`left`in e?{x:r,y:i,width:t,height:o,top:i,left:r,bottom:i+o,right:r+t,toJSON:n(()=>({}),`toJSON`)}:{x:r-(t-a)/2,y:i,width:t,height:o}},`withMinWidth`),P=n(async(e,n,r)=>{if(n.stereotype!==void 0)return M(e,n,r);let i,a=n.useHtmlLabels||l(u()?.htmlLabels);i=r||`node default`;let o=e.insert(`g`).attr(`class`,i).attr(`id`,n.domId||n.id),s=o.insert(`g`).attr(`class`,`label`).attr(`style`,h(n.labelStyle)),c;c=n.label===void 0?``:typeof n.label==`string`?n.label:n.label[0];let p=!!n.icon||!!n.img,m=n.labelType===`markdown`,g=c&&!n.width?n.minWidth??0:0,_=await S(s,d(f(c),u()),{useHtmlLabels:a,width:n.width||n.wrappingWidth||u().flowchart?.wrappingWidth,minWidth:g,classes:m?`markdown-node-label`:``,style:n.labelStyle,addSvgBackground:p,markdown:m},u()),v=(n?.padding??0)/2,y;if(a){let e=_.children[0],n=t(_);await O(e),y=await C.measure(()=>e.getBoundingClientRect()),y=N(y,g),n.attr(`width`,y.width),n.attr(`height`,y.height)}else y=await C.measure(()=>_.getBBox()),y=N(y,g);return a?s.attr(`transform`,`translate(`+-y.width/2+`, `+-y.height/2+`)`):s.attr(`transform`,`translate(0, `+-y.height/2+`)`),n.centerLabel&&s.attr(`transform`,`translate(`+-y.width/2+`, `+-y.height/2+`)`),s.insert(`rect`,`:first-child`),{shapeSvg:o,bbox:y,halfPadding:v,label:s}},`labelHelper`),F=n(async(e,n,r)=>{let i=r.useHtmlLabels??o(u()),a=e.insert(`g`).attr(`class`,`label`).attr(`style`,r.labelStyle||``),s=await S(a,d(f(n),u()),{useHtmlLabels:i,width:r.width||u()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),c=r.padding/2,l;if(o(u())){let e=s.children[0],n=t(s);l=await C.measure(()=>e.getBoundingClientRect()),n.attr(`width`,l.width),n.attr(`height`,l.height)}else l=await C.measure(()=>s.getBBox());return i?a.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`):a.attr(`transform`,`translate(0, `+-l.height/2+`)`),r.centerLabel&&a.attr(`transform`,`translate(`+-l.width/2+`, `+-l.height/2+`)`),a.insert(`rect`,`:first-child`),{shapeSvg:e,bbox:l,halfPadding:c,label:a}},`insertLabel`),I=n((e,t,n)=>{if(n){e.width=n.width,e.height=n.height;return}let r=t.node().getBBox();e.width=r.width,e.height=r.height},`updateNodeBounds`),L=n((e,t)=>(e.look===`handDrawn`?`rough-node`:`node`)+` `+e.cssClasses+` `+(t||``),`getNodeClasses`);function R(e){let t=e.map((e,t)=>`${t===0?`M`:`L`}${e.x},${e.y}`);return t.push(`Z`),t.join(` `)}n(R,`createPathFromPoints`);function z(e,t,n,r,i,a){let o=[],s=n-e,c=r-t,l=s/a,u=2*Math.PI/l,d=t+c/2;for(let t=0;t<=50;t++){let n=e+t/50*s,r=d+i*Math.sin(u*(n-e));o.push({x:n,y:r})}return o}n(z,`generateFullSineWavePoints`);function B(e,t,n,r,i,a){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;ie.tagName===`path`),r=document.createElementNS(`http://www.w3.org/2000/svg`,`path`),i=t.map(e=>e.getAttribute(`d`)).filter(e=>e!==null).join(` `);r.setAttribute(`d`,i);let a=t.find(e=>e.getAttribute(`fill`)!==`none`),o=t.find(e=>e.getAttribute(`stroke`)!==`none`),s=n((e,t)=>e?.getAttribute(t)??void 0,`getAttr`);if(a){let e={fill:s(a,`fill`),"fill-opacity":s(a,`fill-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&r.setAttribute(e,t)})}if(o){let e={stroke:s(o,`stroke`),"stroke-width":s(o,`stroke-width`)??`1`,"stroke-opacity":s(o,`stroke-opacity`)??`1`};Object.entries(e).forEach(([e,t])=>{t&&r.setAttribute(e,t)})}let c=document.createElementNS(`http://www.w3.org/2000/svg`,`g`);return c.appendChild(r),c}n(ee,`mergePaths`);var V=n((e,t)=>{var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2,c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=a===0?0:s*i/a,l=s):(i<0&&(o=-o),c=o,l=i===0?0:o*a/i),{x:n+c,y:r+l}},`intersectRect`);function te(e,t){return e.intersect(t)}n(te,`intersectNode`);var H=te;function U(e,t,n,r){var i=e.x,a=e.y,o=i-r.x,s=a-r.y,c=Math.sqrt(t*t*s*s+n*n*o*o),l=Math.abs(t*n*o/c);r.x0}n(G,`sameSign`);var ae=W;function oe(e,t,n){let r=e.x,i=e.y,a=[],o=1/0,s=1/0;typeof t.forEach==`function`?t.forEach(function(e){o=Math.min(o,e.x),s=Math.min(s,e.y)}):(o=Math.min(o,t.x),s=Math.min(s,t.y));let c=r-e.width/2-o,l=i-e.height/2-s;for(let r=0;r1&&a.sort(function(e,t){let r=e.x-n.x,i=e.y-n.y,a=Math.sqrt(r*r+i*i),o=t.x-n.x,s=t.y-n.y,c=Math.sqrt(o*o+s*s);return a[`M`,e+i,t,`H`,e+n-i,`A`,i,i,0,0,1,e+n,t+i,`V`,t+r-i,`A`,i,i,0,0,1,e+n-i,t+r,`H`,e+i,`A`,i,i,0,0,1,e,t+r-i,`V`,t+i,`A`,i,i,0,0,1,e+i,t,`Z`].join(` `),`createRoundedRectPathD`),se=n(async(e,t,n,r=!1,i=!1)=>{let a=t||``;typeof a==`object`&&(a=a[0]);let s=u(),c=o(s);return await S(e,a,{style:n,isTitle:r,useHtmlLabels:c,markdown:!1,isNode:i,width:1/0},s)},`createLabel`);function ce(t,n){let{labelStyles:r}=_(n);n.labelStyle=r;let i=L(n),a=i;i||(a=`anchor`);let o=t.insert(`g`).attr(`class`,a).attr(`id`,n.domId||n.id),{cssStyles:s}=n,c=T.svg(o),l=g(n,{fill:`black`,stroke:`none`,fillStyle:`solid`});n.look!==`handDrawn`&&(l.roughness=0);let u=c.circle(0,0,2,l),d=o.insert(()=>u,`:first-child`);return d.attr(`class`,`anchor`).attr(`style`,h(s)),I(n,d),n.intersect=function(t){return e.info(`Circle intersect`,n,1,t),K.circle(n,1,t)},o}n(ce,`anchor`);function le(e,t,n,r,i,a,o){let s=(e+n)/2,c=(t+r)/2,l=Math.atan2(r-t,n-e),u=(n-e)/2,d=(r-t)/2,f=u/i,p=d/a,m=Math.sqrt(f**2+p**2);if(m>1)throw Error(`The given radii are too small to create an arc between the points.`);let h=Math.sqrt(1-m**2),g=s+h*a*Math.sin(l)*(o?-1:1),_=c-h*i*Math.cos(l)*(o?-1:1),v=Math.atan2((t-_)/a,(e-g)/i),y=Math.atan2((r-_)/a,(n-g)/i)-v;o&&y<0&&(y+=2*Math.PI),!o&&y>0&&(y-=2*Math.PI);let b=[];for(let e=0;e<20;e++){let t=v+e/19*y,n=g+i*Math.cos(t),r=_+a*Math.sin(t);b.push({x:n,y:r})}return b}n(le,`generateArcPoints`);function ue(e,t,n){let[r,i]=[t,n].sort((e,t)=>t-e);return i*(1-Math.sqrt(1-(e/r/2)**2))}n(ue,`calculateArcSagitta`);async function de(e,t){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let a=t.padding??0,o=t.look===`neo`?16:a,s=t.look===`neo`?12:a,c=n(e=>e+s,`calcTotalHeight`),l=n(e=>{let t=e/2;return[t/(2.5+e/50),t]},`calcEllipseRadius`),{shapeSvg:u,bbox:d}=await P(e,t,L(t)),f=c(t?.height?t?.height:d.height),[p,m]=l(f),h=ue(f,p,m),v=(t?.width?t?.width:d.width)+o*2+h-h,y=f,{cssStyles:b}=t,x=[{x:v/2,y:-y/2},{x:-v/2,y:-y/2},...le(-v/2,-y/2,-v/2,y/2,p,m,!1),{x:v/2,y:y/2},...le(v/2,y/2,v/2,-y/2,p,m,!0)],S=T.svg(u),C=g(t,{});t.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`);let w=R(x),E=S.path(w,C),D=u.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),b&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,b),i&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,i),D.attr(`transform`,`translate(${p/2}, 0)`),I(t,D),t.intersect=function(e){return K.polygon(t,x,e)},u}n(de,`bowTieRect`);async function fe(e,t,{config:{themeVariables:r}}){let{labelStyles:i,nodeStyles:a}=_(t);t.labelStyle=i;let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=r?.nodeBorder??r?.lineColor??`currentColor`,u=t.padding??12,d=Math.max(s.width+u*2,t.width??0,80),f=Math.max(Math.min(d*.08,12),5),p=Math.max(s.height+u*2+f,t.height??0),m=-p/2+f,h=p/2,v=d*.72,y=[`M${-d/2},${m}`,`L${-v/2},${h}`,`A${v/2},${f} 0 0 0 ${v/2},${h}`,`L${d/2},${m}`,`A${d/2},${f} 0 0 0 ${-d/2},${m}`,`Z`].join(` `),{cssStyles:b}=t,x=o.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(o).path(y,g(t,{}));x.node()?.appendChild(e),b&&x.attr(`style`,b)}else x.append(`path`).attr(`d`,y).attr(`style`,a);x.append(`ellipse`).attr(`cx`,0).attr(`cy`,m).attr(`rx`,d/2).attr(`ry`,f).attr(`style`,`fill:none;stroke:${l};stroke-width:1px`),I(t,x);let S=m+(h-m)/2;c.attr(`transform`,`translate(${-(s.width/2)-(s.x-(s.left??0))}, ${S-s.height/2-(s.y-(s.top??0))})`);let C=n((e,t,n)=>Array.from({length:13},(r,i)=>{let a=Math.PI-i*Math.PI/12;return{x:e*Math.cos(a),y:t+n*f*Math.sin(a)}}),`arc`),w=[...C(d/2,m,-1),...C(v/2,h,1).reverse()];return t.intersect=function(e){return K.polygon(t,w,e)},o}n(fe,`bucket`);var pe=20,me=8,he=80,ge=8;function _e(e){let{themeVariables:t}=u(),n=t.clusterBkg,r=t.clusterBorder;switch(e){case`flow`:return{rx:10,fill:`none`,stroke:t.flowContainerStroke||t.secondaryBorderColor,strokeWidth:.75,cssClass:`flow-collapsed`};default:return{rx:ge,fill:n,stroke:r,cssClass:`collapsed-group`}}}n(_e,`getCollapsedStyle`);async function ve(e,t){let n=_e(t.metadata?.containerType),{fill:r,stroke:i}=n,{nodeStyles:a}=_(t),{shapeSvg:s,bbox:c}=await P(e,t,L(t)),{theme:l,themeVariables:d}=u();w(s,t.colorIndex,l,d.borderColorArray);let f=t.padding??8,p=c.height,m=Math.max(c.width+f*2,he,t?.width??0),v=Math.max(p+me+pe+f*2,t?.height??0),y=-m/2,b=-v/2,x=-(me+pe)/2,S=s.select(`.label`);S&&(t.useHtmlLabels??o(u())?S.attr(`transform`,`translate(${-c.width/2}, ${-c.height/2+x})`):S.attr(`transform`,`translate(0, ${-c.height/2+x})`));let C;if(t.look===`handDrawn`){let e=T.svg(s),a=g(t,{fill:r,stroke:i,...n.strokeWidth===void 0?{}:{strokeWidth:n.strokeWidth},...r===`none`?{fillWeight:0}:{fillStyle:`solid`}}),o=e.path(q(y,b,m,v,n.rx),a);C=s.insert(()=>o,`:first-child`),C.attr(`class`,`basic label-container `+n.cssClass).attr(`style`,h(t.cssStyles))}else C=s.insert(`rect`,`:first-child`),C.attr(`class`,`basic label-container `+n.cssClass).attr(`style`,a).attr(`rx`,n.rx).attr(`ry`,n.rx).attr(`x`,y).attr(`y`,b).attr(`width`,m).attr(`height`,v).attr(`fill`,r).attr(`stroke`,i),n.strokeWidth!==void 0&&C.attr(`stroke-width`,n.strokeWidth+`px`);let E=b+f+p+me;s.append(`line`).attr(`class`,`collapsed-separator`).attr(`x1`,y+8).attr(`y1`,E).attr(`x2`,y+m-8).attr(`y2`,E).attr(`stroke`,i).attr(`stroke-dasharray`,`3, 3`);let D=E+pe/2;for(let e=-1;e<=1;e++)s.append(`circle`).attr(`class`,`collapsed-indicator`).attr(`cx`,e*10).attr(`cy`,D).attr(`r`,2.5).attr(`fill`,i);return I(t,C),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},s}n(ve,`collapsedGroup`);function J(e,t,n,r){return e.insert(`polygon`,`:first-child`).attr(`points`,r.map(function(e){return e.x+`,`+e.y}).join(` `)).attr(`class`,`label-container`).attr(`transform`,`translate(`+-t/2+`,`+n/2+`)`)}n(J,`insertPolygonShape`);var ye=[`right`,`left`,`up`,`down`],be=`point`,xe=n(e=>{let t=new Set;for(let n of e)switch(n){case`x`:t.add(`right`),t.add(`left`);break;case`y`:t.add(`up`),t.add(`down`);break;default:t.add(n)}return t},`expandAndDeduplicateDirections`),Se=n(e=>ye.filter(t=>e.has(t)).join(`|`)||be,`getDirectionKey`),Ce={"right|left|up|down":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:0,y:0},{x:t,y:0},{x:r/2,y:2*n},{x:r-t,y:0},{x:r,y:0},{x:r,y:-e/3},{x:r+2*n,y:-e/2},{x:r,y:-2*e/3},{x:r,y:-e},{x:r-t,y:-e},{x:r/2,y:-e-2*n},{x:t,y:-e},{x:0,y:-e},{x:0,y:-2*e/3},{x:-2*n,y:-e/2},{x:0,y:-e/3}],`right|left|up|down`),"right|left|up":n(({height:e,midpoint:t,width:n})=>[{x:t,y:0},{x:n-t,y:0},{x:n,y:-e/2},{x:n-t,y:-e},{x:t,y:-e},{x:0,y:-e/2}],`right|left|up`),"right|left|down":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:t,y:-e},{x:n-t,y:-e},{x:n,y:0}],`right|left|down`),"right|up|down":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:n,y:-e+t},{x:0,y:-e}],`right|up|down`),"left|up|down":n(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:0,y:-e+t},{x:n,y:-e}],`left|up|down`),"right|left":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`right|left`),"up|down":n(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`up|down`),"right|up":n(({height:e,midpoint:t,width:n})=>[{x:0,y:0},{x:n,y:-t},{x:0,y:-e}],`right|up`),"right|down":n(({height:e,width:t})=>[{x:0,y:0},{x:t,y:0},{x:0,y:-e}],`right|down`),"left|up":n(({height:e,midpoint:t,width:n})=>[{x:n,y:0},{x:0,y:-t},{x:n,y:-e}],`left|up`),"left|down":n(({height:e,width:t})=>[{x:t,y:0},{x:0,y:0},{x:t,y:-e}],`left|down`),right:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:0},{x:r,y:-e/2},{x:r-t,y:-e},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e+n}],`right`),left:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:0},{x:t,y:-n},{x:r-t,y:-n},{x:r-t,y:-e+n},{x:t,y:-e+n},{x:t,y:-e},{x:0,y:-e/2}],`left`),up:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:t,y:-n},{x:t,y:-e+n},{x:0,y:-e+n},{x:r/2,y:-e},{x:r,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n}],`up`),down:n(({height:e,midpoint:t,padding:n,width:r})=>[{x:r/2,y:0},{x:0,y:-n},{x:t,y:-n},{x:t,y:-e+n},{x:r-t,y:-e+n},{x:r-t,y:-n},{x:r,y:-n}],`down`),[be]:()=>[{x:0,y:0}]},we=n((e,t,n,r)=>{let i=xe(e),a=(n.padding??0)/2,o=t.height+4*a,s=o/2,c=r??t.width+2*s+2*a;return(Ce[Se(i)]??Ce[be])({height:o,midpoint:s,padding:a,width:c})},`getArrowPoints`);async function Te(e,t){let n=t,{shapeSvg:r,bbox:i}=await P(e,n,L(n)),a=n.padding??0,o=i.height+2*a,s=o/2,c=i.width+2*s+a,l=n.width??0,u=n.positioned&&(n.widthInColumns??1)>1&&l>c?l:c,d=we(n.directions??[],i,n,u),f=J(r,u,o,d);return f.attr(`style`,n.style??null),I(n,f),n.intersect=function(e){return K.polygon(n,d,e)},r}n(Te,`block_arrow`);async function Ee(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await P(e,t,L(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+18,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(a).path(q(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`line`).attr(`x1`,-u/2).attr(`y1`,f+18).attr(`x2`,u/2).attr(`y2`,f+18).attr(`style`,`stroke:${c};stroke-width:1px`);for(let e=0;e<3;e++)m.append(`circle`).attr(`cx`,-u/2+12+e*9).attr(`cy`,f+9).attr(`r`,2.5).attr(`style`,`fill:${c};stroke:none`);m.append(`rect`).attr(`class`,`browser-address-bar`).attr(`x`,-u/2+44).attr(`y`,f+4).attr(`width`,Math.max(u-56,10)).attr(`height`,10).attr(`rx`,3).attr(`ry`,3).attr(`style`,`fill:none;stroke:${c};stroke-width:1px;opacity:0.6`),I(t,m);let h=f+18+(d-18)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}n(Ee,`browser`);var De=12;async function Oe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?28:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width??c.width)+(t.look===`neo`?a*2:a+De),u=(t?.height??c.height)+(t.look===`neo`?o*2:o),d=l,f=-u,p=[{x:0+De,y:f},{x:d,y:f},{x:d,y:0},{x:0,y:0},{x:0,y:f+De},{x:0+De,y:f}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(p),i=e.path(r,n);m=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-l/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=J(s,l,u,p);return r&&m.attr(`style`,r),I(t,m),t.intersect=function(e){return K.polygon(t,p,e)},s}n(Oe,`card`);function ke(e,t){let{nodeStyles:n}=_(t);t.label=``;let r=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId??t.id),{cssStyles:i}=t,a=Math.max(28,t.width??0),o=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],s=T.svg(r),c=g(t,{});t.look!==`handDrawn`&&(c.roughness=0,c.fillStyle=`solid`);let l=R(o),u=s.path(l,c),d=r.insert(()=>u,`:first-child`);return i&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,i),n&&t.look!==`handDrawn`&&d.selectAll(`path`).attr(`style`,n),t.width=28,t.height=28,t.intersect=function(e){return K.polygon(t,o,e)},r}n(ke,`choice`);async function Ae(t,n,r){let{labelStyles:i,nodeStyles:a}=_(n);n.labelStyle=i;let{shapeSvg:o,bbox:s,halfPadding:c}=await P(t,n,L(n)),l=r?.padding??c,u=Math.sqrt(s.width**2+s.height**2)/2,d=n.look===`neo`?u+32:u+l,f,{cssStyles:p}=n;if(n.look===`handDrawn`){let e=T.svg(o),t=g(n,{}),r=e.circle(0,0,d*2,t);f=o.insert(()=>r,`:first-child`),f.attr(`class`,`basic label-container`).attr(`style`,h(p))}else f=o.insert(`circle`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,a).attr(`r`,d).attr(`cx`,0).attr(`cy`,0);return I(n,f),n.calcIntersect=function(e,t){let n=e.width/2;return K.circle(e,n,t)},n.intersect=function(t){return e.info(`Circle intersect`,n,d,t),K.circle(n,d,t)},o}n(Ae,`circle`);async function je(e,t){let n=t,{shapeSvg:r,bbox:i,halfPadding:a}=await P(e,n,[`node`,n.cssClasses,n.class].filter(Boolean).join(` `)),o=r.insert(`rect`,`:first-child`),s=n.padding??0,c=n.positioned?n.width??0:i.width+s,l=n.positioned?n.height??0:i.height+s,u=n.positioned?-c/2:-i.width/2-a,d=n.positioned?-l/2:-i.height/2-a;return o.attr(`class`,`basic cluster composite label-container`).attr(`style`,n.style??null).attr(`rx`,n.rx??null).attr(`ry`,n.ry??null).attr(`x`,u).attr(`y`,d).attr(`width`,c).attr(`height`,l),I(n,o),n.intersect=function(e){return K.rect(n,e)},r}n(je,`composite`);async function Me(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,label:s}=await P(e,t,L(t)),c=n?.nodeBorder??n?.lineColor??`currentColor`,l=t.padding??12,u=Math.max(o.width+l*2,t.width??0,90),d=Math.max(o.height+l*2+20,t.height??0),f=-d/2,{cssStyles:p}=t,m=a.insert(`g`,`:first-child`).attr(`class`,`basic label-container`);if(t.look===`handDrawn`){let e=T.svg(a).path(q(-u/2,f,u,d,12),g(t,{}));m.node()?.appendChild(e),p&&m.attr(`style`,p)}else m.append(`rect`).attr(`x`,-u/2).attr(`y`,f).attr(`width`,u).attr(`height`,d).attr(`rx`,12).attr(`ry`,12).attr(`style`,i);m.append(`text`).attr(`x`,-u/2+12).attr(`y`,f+16).attr(`class`,`console-glyph`).attr(`style`,`font-family:monospace;font-weight:bold;font-size:14px;fill:${c}`).text(`>_`),I(t,m);let h=f+20+(d-20)/2;return s.attr(`transform`,`translate(${-(o.width/2)-(o.x-(o.left??0))}, ${h-o.height/2-(o.y-(o.top??0))})`),t.intersect=function(e){return K.rect(t,e)},a}n(Me,`consoleWindow`);function Ne(e){let t=Math.cos(Math.PI/4),n=Math.sin(Math.PI/4),r=e*2,i={x:r/2*t,y:r/2*n},a={x:-(r/2)*t,y:r/2*n},o={x:-(r/2)*t,y:-(r/2)*n},s={x:r/2*t,y:-(r/2)*n};return`M ${a.x},${a.y} L ${s.x},${s.y} + M ${i.x},${i.y} L ${o.x},${o.y}`}n(Ne,`createLine`);function Pe(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r,n.label=``;let a=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),o=Math.max(30,n?.width??0),{cssStyles:s}=n,c=T.svg(a),l=g(n,{});n.look!==`handDrawn`&&(l.roughness=0,l.fillStyle=`solid`);let u=c.circle(0,0,o*2,l),d=Ne(o),f=c.path(d,l),p=a.insert(()=>u,`:first-child`);return p.insert(()=>f),p.attr(`class`,`outer-path`),s&&n.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,s),i&&n.look!==`handDrawn`&&p.selectAll(`path`).attr(`style`,i),I(n,p),n.intersect=function(t){return e.info(`crossedCircle intersect`,n,{radius:o,point:t}),K.circle(n,o,t)},a}n(Pe,`crossedCircle`);function Y(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iS,`:first-child`).attr(`stroke-opacity`,0),C.insert(()=>b,`:first-child`),C.attr(`class`,`text`),f&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),C.attr(`transform`,`translate(${d}, 0)`),o.attr(`transform`,`translate(${-l/2+d-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,m,e)},i}n(Fe,`curlyBraceLeft`);function X(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iS,`:first-child`).attr(`stroke-opacity`,0),C.insert(()=>b,`:first-child`),C.attr(`class`,`text`),f&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),C.attr(`transform`,`translate(${-d}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,m,e)},i}n(Ie,`curlyBraceRight`);function Z(e,t,n,r=100,i=0,a=180){let o=[],s=i*Math.PI/180,c=(a*Math.PI/180-s)/(r-1);for(let i=0;iE,`:first-child`).attr(`stroke-opacity`,0),D.insert(()=>x,`:first-child`),D.insert(()=>C,`:first-child`),D.attr(`class`,`text`),f&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(${d-d/4}, 0)`),o.attr(`transform`,`translate(${-l/2+(t.padding??0)/2-(a.x-(a.left??0))},${-u/2+(t.padding??0)/2-(a.y-(a.top??0))})`),I(t,D),t.intersect=function(e){return K.polygon(t,h,e)},i}n(Le,`curlyBraces`);async function Re(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(5,c.height+o*2,t?.height??0),u=l/2,d=u-Math.sqrt(Math.max(0,u**2-(c.height/2)**2)),f=Math.max(l/4,d),p=Math.max(20,c.width+a*2+f*2,(c.width+a*2)*1.25,t?.width??0),{cssStyles:m}=t,h=T.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=p,b=l,x=y-u,S=b/4,C=[{x,y:0},{x:S,y:0},{x:0,y:b/2},{x:S,y:b},{x,y:b},...B(-x,-b/2,u,50,270,90)],w=R(C),E=h.path(w,v),D=s.insert(()=>E,`:first-child`);return D.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&D.selectChildren(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&D.selectChildren(`path`).attr(`style`,r),D.attr(`transform`,`translate(${-p/2}, ${-l/2})`),I(t,D),t.intersect=function(e){return K.polygon(t,C,e)},s}n(Re,`curvedTrapezoid`);async function ze(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??20,c=Math.max(a.width+s*2,t.width??0,100),l=Math.min(Math.max(c*.23,16),56),u=l*.27,d=Math.max(a.height+s*2,t.height?t.height-(2*l-u):0),f=Math.min(c*.177,d*.45),p=d+2*l-u,m=-p/2,h=m+2*l-u,v=i.insert(`g`,`:first-child`).attr(`class`,`basic label-container`),{cssStyles:y}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=e.path(q(-c/2,h,c,d,f),n),a=e.circle(0,m+l,l*2,n);v.insert(()=>a,`:first-child`),v.insert(()=>r,`:first-child`),y&&v.attr(`style`,y)}else v.append(`rect`).attr(`x`,-c/2).attr(`y`,h).attr(`width`,c).attr(`height`,d).attr(`rx`,f).attr(`ry`,f).attr(`style`,r),v.append(`circle`).attr(`cx`,0).attr(`cy`,m+l).attr(`r`,l).attr(`style`,r);I(t,v);let b=h+d/2;o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${b-a.height/2-(a.y-(a.top??0))})`);let x=m+l,S=Math.asin(Math.min(1,(h-x)/l))*180/Math.PI,C=[...B(0,-x,l,24,180+S,-S),...B(-(-c/2+f),-(h+f),f,12,90,0),...B(-(-c/2+f),-(p/2-f),f,12,360,270),...B(-(c/2-f),-(p/2-f),f,12,270,180),...B(-(c/2-f),-(h+f),f,12,180,90)];return t.intersect=function(e){return K.polygon(t,C,e)},i}n(ze,`person`);var Be=n((e,t,n,r,i,a)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createCylinderPathD`),Ve=n((e,t,n,r,i,a)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`].join(` `),`createOuterCylinderPathD`),He=n((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),Ue=8,We=8;async function Ge(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?24:i,o=t.look===`neo`?24:i,s=t.width??0;if(t.width&&(t.width-=o,t.widtho,`:first-child`),v=c.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=Be(0,0,d,m,f,p);v=c.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,h(y)).attr(`style`,r)}return v.attr(`label-offset-y`,p),v.attr(`transform`,`translate(${-d/2}, ${-(m/2+p)})`),I(t,v),u.attr(`transform`,`translate(${-(l.width/2)-(l.x-(l.left??0))}, ${-(l.height/2)+(t.padding??0)/1.5-(l.y-(l.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(f!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-p)){let i=p*p*(1-r*r/(f*f));i>0&&(i=Math.sqrt(i)),i=p-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},c}n(Ge,`cylinder`);async function Ke(e,t,n){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o}=await P(e,t,L(t)),s=Math.max(o.width+n.labelPaddingX*2,t?.width||0),c=Math.max(o.height+n.labelPaddingY*2,t?.height||0),l=-s/2,u=-c/2,d,{rx:f,ry:p}=t,{cssStyles:m}=t;if(n?.rx&&n.ry&&(f=n.rx,p=n.ry),t.look===`handDrawn`){let e=T.svg(a),n=g(t,{}),r=f||p?e.path(q(l,u,s,c,f||0),n):e.rectangle(l,u,s,c,n);d=a.insert(()=>r,`:first-child`),d.attr(`class`,`basic label-container`).attr(`style`,h(m))}else d=a.insert(`rect`,`:first-child`),d.attr(`class`,`basic label-container`).attr(`style`,i).attr(`rx`,h(f)).attr(`ry`,h(p)).attr(`x`,l).attr(`y`,u).attr(`width`,s).attr(`height`,c);return I(t,d,t.look===`handDrawn`?void 0:{width:s,height:c}),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},a}n(Ke,`drawRect`);async function qe(e,t){let{cssClasses:n,labelPaddingX:r,labelPaddingY:i,padding:a,width:o,height:s}=t,c=await Ke(e,t,{rx:0,ry:0,classes:n??``,labelPaddingX:r??(a??0)*2,labelPaddingY:i??a??0});if(t.look===`handDrawn`){let e=T.svg(c),n=g(t,{}),r=c.select(`.basic.label-container > path:nth-child(2)`),i=r.node();if(!i)return c;let a=null;if(i instanceof SVGGraphicsElement)a=i.getBBox();else return c;return c.insert(()=>e.line(a.x,a.y,a.x+a.width,a.y,n),`.basic.label-container g.label`),c.insert(()=>e.line(a.x,a.y+a.height,a.x+a.width,a.y+a.height,n),`.basic.label-container g.label`),r.remove(),c}let l=c.select(`.basic.label-container`),u=(Number(l.attr(`width`))||o)??0,d=(Number(l.attr(`height`))||s)??0;return u>0&&d>0&&l.attr(`stroke-dasharray`,`${u} ${d}`),c}n(qe,`datastore`);async function Je(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?16:t.padding??0,{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=s.width+i,u=s.height+a,d=u*.2,f=-l/2,p=-u/2-d/2,{cssStyles:m}=t,h=T.svg(o),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:f,y:p+d},{x:-f,y:p+d},{x:-f,y:-p},{x:f,y:-p},{x:f,y:p},{x:-f,y:p},{x:-f,y:p+d}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=o.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${f+(t.padding??0)/2-(s.x-(s.left??0))}, ${p+d+(t.padding??0)/2-(s.y-(s.top??0))})`),I(t,x),t.intersect=function(e){return K.rect(t,e)},o}n(Je,`dividedRectangle`);async function Ye(t,n){let{labelStyles:r,nodeStyles:i}=_(n),a=n.look===`neo`?12:5;n.labelStyle=r;let o=n.padding??0,s=n.look===`neo`?16:o,{shapeSvg:c,bbox:l}=await P(t,n,L(n)),u=Math.sqrt(l.width**2+l.height**2)/2,d=(n?.width?n?.width/2:u)+(s??0),f=d+a,p,{cssStyles:m}=n;if(n.look===`handDrawn`){let e=T.svg(c),t=g(n,{roughness:.2,strokeWidth:2.5}),r=g(n,{roughness:.2,strokeWidth:1.5}),i=e.circle(0,0,f*2,t),a=e.circle(0,0,d*2,r);p=c.insert(`g`,`:first-child`),p.attr(`class`,h(n.cssClasses)).attr(`style`,h(m)),p.node()?.appendChild(i),p.node()?.appendChild(a)}else{p=c.insert(`g`,`:first-child`);let e=p.insert(`circle`,`:first-child`),t=p.insert(`circle`);p.attr(`class`,`basic label-container`).attr(`style`,i),e.attr(`class`,`outer-circle`).attr(`style`,i).attr(`r`,f).attr(`cx`,0).attr(`cy`,0),t.attr(`class`,`inner-circle`).attr(`style`,i).attr(`r`,d).attr(`cx`,0).attr(`cy`,0)}return I(n,p),n.intersect=function(t){return e.info(`DoubleCircle intersect`,n,f,t),K.circle(n,f,t)},c}n(Ye,`doublecircle`);async function Xe(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,halfPadding:o}=await P(e,t,L(t)),{theme:s,themeVariables:c}=u();w(i,t.colorIndex,s,c.borderColorArray);let l=o??10,d=a.width/2+l*2,f=a.height/2+l*2,p,{cssStyles:m}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=e.ellipse(0,0,d*2,f*2,n);p=i.insert(()=>r,`:first-child`),p.attr(`class`,`basic label-container`),m&&p.attr(`style`,m)}else p=i.insert(`ellipse`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,r).attr(`rx`,d).attr(`ry`,f).attr(`cx`,0).attr(`cy`,0);return t.width=d*2,t.height=f*2,I(t,p),t.calcIntersect=function(e,t){let n=e.width/2,r=e.height/2;return K.ellipse(e,n,r,t)},t.intersect=function(e){return K.ellipse(t,d,f,e)},i}n(Xe,`usecaseEllipse`);function Ze(t,n,{config:{themeVariables:r}}){let{labelStyles:i,nodeStyles:a}=_(n);n.label=``,n.labelStyle=i;let o=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),{cssStyles:s}=n,c=T.svg(o),{nodeBorder:l}=r,u=g(n,{fillStyle:`solid`});n.look!==`handDrawn`&&(u.roughness=0);let d=c.circle(0,0,14,u),f=o.insert(()=>d,`:first-child`);return f.selectAll(`path`).attr(`style`,`fill: ${l} !important;`),s&&s.length>0&&n.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,s),a&&n.look!==`handDrawn`&&f.selectAll(`path`).attr(`style`,a),I(n,f),n.intersect=function(t){return e.info(`filledCircle intersect`,n,{radius:7,point:t}),K.circle(n,7,t)},o}n(Ze,`filledCircle`);var Qe=10,$e=10;async function et(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.padding??0,o=n.look===`neo`?a*2:a;(n.width||n.height)&&(n.height=n?.height??0,n.heightb,`:first-child`).attr(`transform`,`translate(${-d/2}, ${d/2})`).attr(`class`,`outer-path`);return m&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,m),i&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,i),n.width=u,n.height=d,I(n,x),l.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${-d/2+(n.padding??0)/2+(c.y-(c.top??0))})`),n.intersect=function(t){return e.info(`Triangle intersect`,n,p,t),K.polygon(n,p,t)},s}n(et,`flippedTriangle`);async function tt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??12,c=Math.max(a.width+s*2,t.width??0,90),l=a.height+s*2,u=Math.max(Math.min(l*.16,14),8),d=Math.max(l+u,t.height??0),f=d-u,p=Math.max(c*.38,28),m=-d/2,h=[{x:-c/2,y:m},{x:-c/2+p,y:m},{x:-c/2+p,y:m+u},{x:c/2,y:m+u},{x:c/2,y:d/2},{x:-c/2,y:d/2}],v=[`M${h[0].x},${h[0].y}`,...h.slice(1).map(e=>`L${e.x},${e.y}`),`Z`].join(` `),{cssStyles:y}=t,b;if(t.look===`handDrawn`){let e=T.svg(i).path(v,g(t,{}));b=i.insert(()=>e,`:first-child`).attr(`class`,`basic label-container`),y&&b.attr(`style`,y)}else b=i.insert(`path`,`:first-child`).attr(`d`,v).attr(`class`,`basic label-container`).attr(`style`,r);t.look===`handDrawn`?I(t,b):I(t,b,{width:c,height:d});let x=m+u+f/2;return o.attr(`transform`,`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${x-a.height/2-(a.y-(a.top??0))})`),t.intersect=function(e){return K.polygon(t,h,e)},i}n(tt,`folder`);function nt(e,t,{dir:n,config:{state:r,themeVariables:i}}){let{nodeStyles:a}=_(t);t.label=``;let o=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId??t.id),{cssStyles:s}=t,c=Math.max(70,t?.width??0),l=Math.max(10,t?.height??0);(n===`LR`||n===`RL`)&&(c=Math.max(10,t?.width??0),l=Math.max(70,t?.height??0));let u=-1*c/2,d=-1*l/2,f=T.svg(o),p=g(t,{stroke:i.lineColor,fill:i.lineColor});t.look!==`handDrawn`&&(p.roughness=0,p.fillStyle=`solid`);let m=f.rectangle(u,d,c,l,p),h=o.insert(()=>m,`:first-child`);s&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,s),a&&t.look!==`handDrawn`&&h.selectAll(`path`).attr(`style`,a),I(t,h);let v=r?.padding??0;return t.width&&t.height&&(t.width+=v/2||0,t.height+=v/2||0),t.intersect=function(e){return K.rect(t,e)},o}n(nt,`forkJoin`);async function rt(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.look===`neo`?16:n.padding??0,o=n.look===`neo`?12:n.padding??0;(n.width||n.height)&&(n.height=(n?.height??0)-o*2,n.height<10&&(n.height=10),n.width=(n?.width??0)-a*2,n.width<15&&(n.width=15));let{shapeSvg:s,bbox:c}=await P(t,n,L(n)),l=(n?.height?n?.height:Math.max(10,c.height))+o*2,u=l/2,d=u-Math.sqrt(Math.max(0,u**2-(c.height/2)**2)),f=(n?.width?n?.width:Math.max(15,c.width)+d*2)+a*2,{cssStyles:p}=n,m=T.svg(s),h=g(n,{});n.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-f/2,y:-l/2},{x:f/2-u,y:-l/2},...B(-f/2+u,0,u,50,90,270),{x:f/2-u,y:l/2},{x:-f/2,y:l/2}],y=R(v),b=m.path(y,h),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),p&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,p),i&&n.look!==`handDrawn`&&x.selectChildren(`path`).attr(`style`,i),I(n,x),n.intersect=function(t){return e.info(`Pill intersect`,n,{radius:u,point:t}),K.polygon(n,v,t)},s}n(rt,`halfRoundedRectangle`);var it=n((e,t,n,r,i)=>[`M${e+i},${t}`,`L${e+n-i},${t}`,`L${e+n},${t-r/2}`,`L${e+n-i},${t-r}`,`L${e+i},${t-r}`,`L${e},${t-r/2}`,`Z`].join(` `),`createHexagonPathD`);async function at(e,t){let{labelStyles:n,nodeStyles:r}=_(t),i=t.look===`neo`?3.5:4;t.labelStyle=n;let a=t.padding??0,o=t.look===`neo`?70:a,s=t.look===`neo`?32:a;if(t.width||t.height){let e=(t.height??0)/i;t.width=(t?.width??0)-2*e-s,t.height=(t.height??0)-o}let{shapeSvg:c,bbox:l}=await P(e,t,L(t)),u=(t?.height?t?.height:l.height)+o,d=u/i,f=(t?.width?t?.width:l.width)+2*d+s,p=[{x:d,y:0},{x:f-d,y:0},{x:f,y:-u/2},{x:f-d,y:-u},{x:d,y:-u},{x:0,y:-u/2}],m,{cssStyles:h}=t;if(t.look===`handDrawn`){let e=T.svg(c),n=g(t,{}),r=it(0,0,f,u,d),i=e.path(r,n);m=c.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-f/2}, ${u/2})`),h&&m.attr(`style`,h)}else m=J(c,f,u,p);return r&&m.attr(`style`,r),t.width=f,t.height=u,I(t,m),t.intersect=function(e){return K.polygon(t,p,e)},c}n(at,`hexagon`);async function ot(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.label=``,n.labelStyle=r;let{shapeSvg:a}=await P(t,n,L(n)),o=Math.max(30,n?.width??0),s=Math.max(30,n?.height??0),{cssStyles:c}=n,l=T.svg(a),u=g(n,{});n.look!==`handDrawn`&&(u.roughness=0,u.fillStyle=`solid`);let d=[{x:0,y:0},{x:o,y:0},{x:0,y:s},{x:o,y:s}],f=R(d),p=l.path(f,u),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`basic label-container outer-path`),c&&n.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,c),i&&n.look!==`handDrawn`&&m.selectChildren(`path`).attr(`style`,i),m.attr(`transform`,`translate(${-o/2}, ${-s/2})`),I(n,m),n.intersect=function(t){return e.info(`Pill intersect`,n,{points:d}),K.polygon(n,d,t)},a}n(ot,`hourglass`);async function st(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await P(t,n,`icon-shape default`),p=n.pos===`t`,m=c,h=c,{nodeBorder:v}=r,{stylesMap:b}=y(n),S=-h/2,C=-m/2,w=n.label?8:0,E=T.svg(u),D=g(n,{stroke:`none`,fill:`none`});n.look!==`handDrawn`&&(D.roughness=0,D.fillStyle=`solid`);let O=E.rectangle(S,C,h,m,D),k=Math.max(h,d.width),A=m+d.height+w,j=E.rectangle(-k/2,-A/2,k,A,{...D,fill:`transparent`,stroke:`none`}),M=u.insert(()=>O,`:first-child`),N=u.insert(()=>j);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${p?d.height/2+w/2-i/2-o:-d.height/2-w/2-i/2-o})`),e.attr(`style`,`color: ${b.get(`stroke`)??v};`)}return f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${p?-A/2:A/2-d.height})`),M.attr(`transform`,`translate(0,${p?d.height/2+w/2:-d.height/2-w/2})`),I(n,N),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=p?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+w},{x:r+h/2,y:i-a/2+d.height+w},{x:r+h/2,y:i+a/2},{x:r-h/2,y:i+a/2},{x:r-h/2,y:i-a/2+d.height+w},{x:r-d.width/2,y:i-a/2+d.height+w}]:[{x:r-h/2,y:i-a/2},{x:r+h/2,y:i-a/2},{x:r+h/2,y:i-a/2+m},{x:r+d.width/2,y:i-a/2+m},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+m},{x:r-h/2,y:i-a/2+m}],K.polygon(n,o,t)},u}n(st,`icon`);async function ct(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,label:f}=await P(t,n,`icon-shape default`),p=n.label?8:0,m=n.pos===`t`,{nodeBorder:h,mainBkg:v}=r,{stylesMap:b}=y(n),S=T.svg(u),C=g(n,{});n.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`),C.stroke=b.get(`fill`)??v;let w=u.append(`g`);n.icon&&w.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let E=w.node().getBBox(),D=E.width,O=E.height,k=E.x,A=E.y,j=Math.max(D,O)*Math.SQRT2+40,M=S.circle(0,0,j,C),N=Math.max(j,d.width),F=j+d.height+p,L=S.rectangle(-N/2,-F/2,N,F,{...C,fill:`transparent`,stroke:`none`}),R=u.insert(()=>M,`:first-child`),z=u.insert(()=>L);return w.attr(`transform`,`translate(${-D/2-k},${m?d.height/2+p/2-O/2-A:-d.height/2-p/2-O/2-A})`),w.attr(`style`,`color: ${b.get(`stroke`)??h};`),f.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-F/2:F/2-d.height})`),R.attr(`transform`,`translate(0,${m?d.height/2+p/2:-d.height/2-p/2})`),I(n,z),n.intersect=function(t){return e.info(`iconSquare intersect`,n,t),K.rect(n,t)},u}n(ct,`iconCircle`);async function lt(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await P(t,n,`icon-shape default`),m=n.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:b,mainBkg:S}=r,{stylesMap:C}=y(n),w=-v/2,E=-h/2,D=n.label?8:0,O=T.svg(u),k=g(n,{});n.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=C.get(`fill`)??S;let A=O.path(q(w,E,v,h,5),k),j=Math.max(v,d.width),M=h+d.height+D,N=O.rectangle(-j/2,-M/2,j,M,{...k,fill:`transparent`,stroke:`none`}),F=u.insert(()=>A,`:first-child`).attr(`class`,`icon-shape2`),L=u.insert(()=>N);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${C.get(`stroke`)??b};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-M/2:M/2-d.height})`),F.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),I(n,L),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=m?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+D},{x:r+v/2,y:i-a/2+d.height+D},{x:r+v/2,y:i+a/2},{x:r-v/2,y:i+a/2},{x:r-v/2,y:i-a/2+d.height+D},{x:r-d.width/2,y:i-a/2+d.height+D}]:[{x:r-v/2,y:i-a/2},{x:r+v/2,y:i-a/2},{x:r+v/2,y:i-a/2+h},{x:r+d.width/2,y:i-a/2+h},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+h},{x:r-v/2,y:i-a/2+h}],K.polygon(n,o,t)},u}n(lt,`iconRounded`);async function ut(t,n,{config:{themeVariables:r,flowchart:i}}){let{labelStyles:a}=_(n);n.labelStyle=a;let o=n.assetHeight??48,s=n.assetWidth??48,c=Math.max(o,s),l=i?.wrappingWidth;n.width=Math.max(c,l??0);let{shapeSvg:u,bbox:d,halfPadding:f,label:p}=await P(t,n,`icon-shape default`),m=n.pos===`t`,h=c+f*2,v=c+f*2,{nodeBorder:b,mainBkg:S}=r,{stylesMap:C}=y(n),w=-v/2,E=-h/2,D=n.label?8:0,O=T.svg(u),k=g(n,{});n.look!==`handDrawn`&&(k.roughness=0,k.fillStyle=`solid`),k.stroke=C.get(`fill`)??S;let A=O.path(q(w,E,v,h,.1),k),j=Math.max(v,d.width),M=h+d.height+D,N=O.rectangle(-j/2,-M/2,j,M,{...k,fill:`transparent`,stroke:`none`}),F=u.insert(()=>A,`:first-child`),L=u.insert(()=>N);if(n.icon){let e=u.append(`g`);e.html(`${await x(n.icon,{height:c,width:c,fallbackPrefix:``})}`);let t=e.node().getBBox(),r=t.width,i=t.height,a=t.x,o=t.y;e.attr(`transform`,`translate(${-r/2-a},${m?d.height/2+D/2-i/2-o:-d.height/2-D/2-i/2-o})`),e.attr(`style`,`color: ${C.get(`stroke`)??b};`)}return p.attr(`transform`,`translate(${-d.width/2-(d.x-(d.left??0))},${m?-M/2:M/2-d.height})`),F.attr(`transform`,`translate(0,${m?d.height/2+D/2:-d.height/2-D/2})`),I(n,L),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=m?[{x:r-d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2},{x:r+d.width/2,y:i-a/2+d.height+D},{x:r+v/2,y:i-a/2+d.height+D},{x:r+v/2,y:i+a/2},{x:r-v/2,y:i+a/2},{x:r-v/2,y:i-a/2+d.height+D},{x:r-d.width/2,y:i-a/2+d.height+D}]:[{x:r-v/2,y:i-a/2},{x:r+v/2,y:i-a/2},{x:r+v/2,y:i-a/2+h},{x:r+d.width/2,y:i-a/2+h},{x:r+d.width/2/2,y:i+a/2},{x:r-d.width/2,y:i+a/2},{x:r-d.width/2,y:i-a/2+h},{x:r-v/2,y:i-a/2+h}],K.polygon(n,o,t)},u}n(ut,`iconSquare`);async function dt(t,n,{config:{flowchart:r}}){let i=new Image;i.src=n?.img??``,await i.decode();let a=Number(i.naturalWidth.toString().replace(`px`,``)),o=Number(i.naturalHeight.toString().replace(`px`,``));n.imageAspectRatio=a/o;let{labelStyles:s}=_(n);n.labelStyle=s;let c=r?.wrappingWidth;n.defaultWidth=r?.wrappingWidth;let l=Math.max(n.label?c??0:0,n?.assetWidth??a),u=n.constraint===`on`&&n?.assetHeight?n.assetHeight*n.imageAspectRatio:l,d=n.constraint===`on`?u/n.imageAspectRatio:n?.assetHeight??o;n.width=Math.max(u,c??0);let{shapeSvg:f,bbox:p,label:m}=await P(t,n,`image-shape default`),h=n.pos===`t`,v=-u/2,y=-d/2,b=n.label?8:0,x=T.svg(f),S=g(n,{});n.look!==`handDrawn`&&(S.roughness=0,S.fillStyle=`solid`);let C=x.rectangle(v,y,u,d,S),w=Math.max(u,p.width),E=d+p.height+b,D=x.rectangle(-w/2,-E/2,w,E,{...S,fill:`none`,stroke:`none`}),O=f.insert(()=>C,`:first-child`),k=f.insert(()=>D);if(n.img){let e=f.append(`image`);e.attr(`href`,n.img),e.attr(`width`,u),e.attr(`height`,d),e.attr(`preserveAspectRatio`,`none`),e.attr(`transform`,`translate(${-u/2},${h?E/2-d:-E/2})`)}return m.attr(`transform`,`translate(${-p.width/2-(p.x-(p.left??0))},${h?-d/2-p.height/2-b/2:d/2-p.height/2+b/2})`),O.attr(`transform`,`translate(0,${h?p.height/2+b/2:-p.height/2-b/2})`),I(n,k),n.intersect=function(t){if(e.info(`iconSquare intersect`,n,t),!n.label)return K.rect(n,t);let r=n.x??0,i=n.y??0,a=n.height??0,o=[];return o=h?[{x:r-p.width/2,y:i-a/2},{x:r+p.width/2,y:i-a/2},{x:r+p.width/2,y:i-a/2+p.height+b},{x:r+u/2,y:i-a/2+p.height+b},{x:r+u/2,y:i+a/2},{x:r-u/2,y:i+a/2},{x:r-u/2,y:i-a/2+p.height+b},{x:r-p.width/2,y:i-a/2+p.height+b}]:[{x:r-u/2,y:i-a/2},{x:r+u/2,y:i-a/2},{x:r+u/2,y:i-a/2+d},{x:r+p.width/2,y:i-a/2+d},{x:r+p.width/2/2,y:i+a/2},{x:r-p.width/2,y:i+a/2},{x:r-p.width/2,y:i-a/2+d},{x:r-u/2,y:i-a/2+d}],K.polygon(n,o,t)},f}n(dt,`imageSquare`);async function ft(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a*2,t.height??0),u=Math.max(c.width+o*2,(t.width??0)-l),d=[{x:0,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:-3*l/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(ft,`inv_trapezoid`);async function pt(e,t){let{shapeSvg:n,bbox:r,label:i}=await P(e,t,`label`),a=n.insert(`rect`,`:first-child`);return a.attr(`width`,.1).attr(`height`,.1),n.attr(`class`,`label edgeLabel`),i.attr(`transform`,`translate(${-(r.width/2)-(r.x-(r.left??0))}, ${-(r.height/2)-(r.y-(r.top??0))})`),I(t,a),t.intersect=function(e){return K.rect(t,e)},n}n(pt,`labelRect`);async function mt(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:0,y:0},{x:u+3*l/6,y:0},{x:u,y:-l},{x:-(3*l)/6,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(mt,`lean_left`);async function ht(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=i,o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:-3*l/6,y:0},{x:u,y:0},{x:u+3*l/6,y:-l},{x:0,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(ht,`lean_right`);function gt(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.label=``,n.labelStyle=r;let a=t.insert(`g`).attr(`class`,L(n)).attr(`id`,n.domId??n.id),{cssStyles:o}=n,s=Math.max(35,n?.width??0),c=Math.max(35,n?.height??0),l=[{x:s,y:0},{x:0,y:c+7/2},{x:s-14,y:c+7/2},{x:0,y:2*c},{x:s,y:c-7/2},{x:14,y:c-7/2}],u=T.svg(a),d=g(n,{});n.look!==`handDrawn`&&(d.roughness=0,d.fillStyle=`solid`);let f=R(l),p=u.path(f,d),m=a.insert(()=>p,`:first-child`);return m.attr(`class`,`outer-path`),o&&n.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,o),i&&n.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,i),m.attr(`transform`,`translate(-${s/2},${-c})`),I(n,m),n.intersect=function(t){return e.info(`lightningBolt intersect`,n,t),K.polygon(n,l,t)},a}n(gt,`lightningBolt`);var _t=n((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createCylinderPathD`),vt=n((e,t,n,r,i,a,o)=>[`M${e},${t+a}`,`M${e+n},${t+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,`l0,${-r}`,`M${e},${t+a+o}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createOuterCylinderPathD`),yt=n((e,t,n,r,i,a)=>[`M${e-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(` `),`createInnerCylinderPathD`),bt=10,xt=10;async function St(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?24:i;if(t.width||t.height){let e=t.width??0;t.width=(t.width??0)-a,t.widtho,`:first-child`).attr(`class`,`line`),v=s.insert(()=>a,`:first-child`),v.attr(`class`,`basic label-container`),y&&v.attr(`style`,y)}else{let e=_t(0,0,u,p,d,f,m);v=s.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container outer-path`).attr(`style`,h(y)).attr(`style`,r)}return v.attr(`label-offset-y`,f),v.attr(`transform`,`translate(${-u/2}, ${-(p/2+f)})`),I(t,v),l.attr(`transform`,`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${-(c.height/2)+f-(c.y-(c.top??0))})`),t.intersect=function(e){let n=K.rect(t,e),r=n.x-(t.x??0);if(d!=0&&(Math.abs(r)<(t.width??0)/2||Math.abs(r)==(t.width??0)/2&&Math.abs(n.y-(t.y??0))>(t.height??0)/2-f)){let i=f*f*(1-r*r/(d*d));i>0&&(i=Math.sqrt(i)),i=f-i,e.y-(t.y??0)>0&&(i=-i),n.y+=i}return n},s}n(St,`linedCylinder`);async function Ct(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=(t.width??0)*10/11-a*2,t.width<10&&(t.width=10),t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10));let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=(t?.width?t?.width:c.width)+(a??0)*2,d=(t?.height?t?.height:c.height)+(o??0)*2,f=t.look===`neo`?d/4:d/8,p=d+f,{cssStyles:m}=t,h=T.svg(s),v=g(t,{});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=[{x:-u/2-u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:p/2},...z(-u/2-u/2*.1,p/2,u/2+u/2*.1,p/2,f,.8),{x:u/2+u/2*.1,y:-p/2},{x:-u/2-u/2*.1,y:-p/2},{x:-u/2,y:-p/2},{x:-u/2,y:p/2*1.1},{x:-u/2,y:-p/2}],b=h.polygon(y.map(e=>[e.x,e.y]),v),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container outer-path`),m&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,m),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),x.attr(`transform`,`translate(0,${-f/2})`),l.attr(`transform`,`translate(${-u/2+(t.padding??0)+u/2*.1/2-(c.x-(c.left??0))},${-d/2+(t.padding??0)-f-(c.y-(c.top??0))})`),I(t,x),t.intersect=function(e){return K.polygon(t,y,e)},s}n(Ct,`linedWaveEdgedRect`);var wt=56,Tt=72,Et=8,Dt=2,Ot=8,kt={normal:`usecase-actor-shape usecase-actor-normal`,hollow:`usecase-actor-hollow`,awesome:`usecase-actor-awesome`,icon:`usecase-actor-icon`},At=Math.PI/3,jt=.6,Mt=n((e,t)=>{let n=t*jt,r=t*Math.sqrt(1-jt**2),i=Math.cos(At),a=-Math.sin(At),o=n*-a,s=e+n*i,c=r*i,l=r*a;return`M ${o-c} ${s-l} L ${o+c} ${s+l}`},`businessMarkerPathForCircle`),Nt={normal:Mt(-24,12),hollow:Mt(-23,9),awesome:Mt(-21,13),icon:`M 12 -8 L 26 -26`},Pt=n((e,t,n)=>{let r=(t.x??0)-(t.left??0),i=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${-t.width/2-r},${n-t.height/2-i})`)},`positionLabel`),Ft=n((e,t,n,r,i=!1)=>{if(t.look===`handDrawn`){let a=T.svg(e).path(n,g(t,i?{fill:`none`}:{}));return e.insert(()=>a,`:first-child`).attr(`class`,r)}let a=e.append(`path`).attr(`class`,r).attr(`d`,n);return i&&a.attr(`fill`,`none`),a},`appendActorPath`),It=n((e,t,n,r,i,a,o=!1)=>{if(t.look===`handDrawn`){let s=T.svg(e).circle(n,r,i*2,g(t,o?{fill:`none`}:{}));return e.insert(()=>s,`:first-child`).attr(`class`,a)}let s=e.append(`circle`).attr(`class`,a).attr(`cx`,n).attr(`cy`,r).attr(`r`,i);return o&&s.attr(`fill`,`none`),s},`appendActorCircle`),Lt=n((e,t,n)=>{t.business&&e.append(`path`).attr(`class`,`usecase-business-marker usecase-actor-business-marker`).attr(`d`,Nt[n]).attr(`fill`,`none`).attr(`style`,`stroke: inherit !important; stroke-width: inherit !important`)},`appendBusinessActorMarker`);async function Rt(e,t,n,r){let{labelStyles:i,nodeStyles:a}=_(t);t.labelStyle=i;let{shapeSvg:o,bbox:s,label:c}=await P(e,n===`icon`||t.stereotype!==void 0?{...t,icon:n===`icon`?void 0:t.icon,stereotype:void 0}:t,L(t,`usecase-actor-variant usecase-actor-${n}`)),l=t.accessibleName??t.label;l&&o.attr(`role`,`img`).attr(`aria-label`,l),c.attr(`class`,`label actor-label usecase-actor-label`);let{theme:d,themeVariables:f}=u();w(o,t.colorIndex,d,f.borderColorArray);let p,m;if(t.stereotype){let e=await F(o,`\xAB${t.stereotype}\xBB`,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0,width:t.wrappingWidth});p=e.label.attr(`class`,`label usecase-stereotype`),m=e.bbox}let h=o.append(`g`).attr(`class`,`usecase-actor-glyph ${kt[n]}`).attr(`style`,a||null);await r(h,t),Lt(h,t,n);let g=t.padding??Ot,v=m?.height??0,y=Tt+Et+s.height+(m?v+Dt:0),b=Math.max(wt,s.width,m?.width??0)+g*2,x=y+g*2,S=-y/2;h.attr(`transform`,`translate(0,${S+Tt/2})`);let C=S+Tt+Et;return p&&m&&(C+=v/2,Pt(p,m,C),C+=v/2+Dt),Pt(c,s,C+s.height/2),I(t,o.insert(`rect`,`:first-child`).attr(`class`,`usecase-actor-outline`).attr(`x`,-b/2).attr(`y`,-x/2).attr(`width`,b).attr(`height`,x).attr(`opacity`,0).attr(`aria-hidden`,`true`)),t.intersect=e=>K.rect(t,e),o}n(Rt,`renderUsecaseActor`);var zt=[`M 0 -12`,`C 6.627 -12 12 -17.373 12 -24`,`C 12 -30.627 6.627 -36 0 -36`,`C -6.627 -36 -12 -30.627 -12 -24`,`C -12 -17.373 -6.627 -12 0 -12 Z`,`M 0 -12 V 8`,`M -17 -5 H 17`,`M 0 8 L -15 28`,`M 0 8 L 15 28`].join(` `);async function Bt(e,t){return Rt(e,t,`normal`,(e,t)=>{Ft(e,t,zt,`usecase-actor-stick`)})}n(Bt,`usecaseActor`);var Vt=[`M 0 -34`,`C 7.18 -34 13 -28.18 13 -21`,`C 13 -13.82 7.18 -8 0 -8`,`C -7.18 -8 -13 -13.82 -13 -21`,`C -13 -28.18 -7.18 -34 0 -34 Z`,`M -24 25`,`C -24 7 -14 -3 0 -3`,`C 14 -3 24 7 24 25`,`C 24 28 21 30 18 30`,`H -18`,`C -21 30 -24 28 -24 25 Z`].join(` `);async function Ht(e,t){return Rt(e,t,`awesome`,(e,t)=>{Ft(e,t,Vt,`usecase-actor-awesome-silhouette`)})}n(Ht,`usecaseActorAwesome`);var Ut=[`M -22 -10`,`H 22`,`V 0`,`H 6`,`L 22 17`,`L 13 28`,`L 0 13`,`L -13 28`,`L -22 17`,`L -6 0`,`H -22`,`Z`].join(` `);async function Wt(e,t){return Rt(e,t,`hollow`,(e,t)=>{It(e,t,0,-23,9,`usecase-actor-hollow-head`,!0),Ft(e,t,Ut,`usecase-actor-hollow-body`,!0)})}n(Wt,`usecaseActorHollow`);var Gt=52,Kt=42,qt=-2,Jt=n(async(e,t)=>{let n=-Gt/2,r=qt-Gt/2;if(t.look===`handDrawn`){let i=T.svg(e).rectangle(n,r,Gt,Gt,g(t,{}));e.insert(()=>i,`:first-child`).attr(`class`,`usecase-actor-icon-frame`)}else e.append(`rect`).attr(`class`,`usecase-actor-icon-frame`).attr(`x`,n).attr(`y`,r).attr(`width`,Gt).attr(`height`,Gt).attr(`rx`,4).attr(`ry`,4);let i=t.icon??``,a=await b(i.includes(`:`)?i:`fa:${i}`),o=await x(i,{height:Kt,width:Kt,fallbackPrefix:`fa`}),s=e.append(`g`).attr(`class`,`usecase-actor-icon-symbol${a?``:` usecase-actor-icon-fallback`}`).attr(`aria-hidden`,`true`).html(`${o}`),c=s.node()?.getBBox();c&&s.attr(`transform`,`translate(${-c.width/2-c.x},${qt-c.height/2-c.y})`)},`drawIconActor`);async function Yt(e,t){return Rt(e,t,`icon`,Jt)}n(Yt,`usecaseActorIcon`);var Xt=n((e,t,n)=>{let r=(t.x??0)-(t.left??0),i=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${-t.width/2-r},${n-t.height/2-i})`)},`positionLabel`);async function Zt(e,t){let n=t,{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(e,n.stereotype?{...t,stereotype:void 0}:t,L(t,`usecase-business-shape`));c.attr(`class`,`label usecase-label`);let{theme:l,themeVariables:d}=u();w(a,t.colorIndex,l,d.borderColorArray);let f,p;if(n.stereotype){let e=await F(a,`\xAB${n.stereotype}\xBB`,{labelStyle:r,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0,width:t.wrappingWidth});f=e.label.attr(`class`,`label usecase-stereotype`),p=e.bbox}let m=p?2:0,h=o.height+(p?.height??0)+m,v=Math.max(o.width,p?.width??0),y=s??10,b=v/2+y*2,x=h/2+y*2,S=Math.min(Math.max(y/5,1),y/2),C=v/2+S,E=b-S,D=C/b,O=E/b,k=x*Math.sqrt(Math.max(0,1-D*D)),A=-x*Math.sqrt(Math.max(0,1-O*O));f&&p&&Xt(f,p,-h/2+p.height/2),Xt(c,o,h/2-o.height/2);let j;if(t.look===`handDrawn`){let e=T.svg(a).ellipse(0,0,b*2,x*2,g(t,{}));j=a.insert(()=>e,`:first-child`).attr(`class`,`basic label-container usecase-business-ellipse`)}else j=a.insert(`ellipse`,`:first-child`).attr(`class`,`basic label-container usecase-business-ellipse`).attr(`style`,i).attr(`rx`,b).attr(`ry`,x).attr(`cx`,0).attr(`cy`,0);a.append(`path`).attr(`class`,`usecase-business-marker`).attr(`d`,`M ${C} ${k} L ${E} ${A}`).attr(`fill`,`none`).attr(`style`,i||null);let M=n.accessibleName??n.label;return M&&a.attr(`role`,`img`).attr(`aria-label`,M),I(t,j),t.calcIntersect=(e,t)=>K.ellipse(e,e.width/2,e.height/2,t),t.intersect=e=>K.ellipse(t,b,x,e),a}n(Zt,`usecaseBusiness`);var Qt=8,$t=4,en=1,tn=n((e,t,n,r)=>{let i=(t.x??0)-(t.left??0),a=(t.y??0)-(t.top??0);e.attr(`transform`,`translate(${n-t.width/2-i},${r-t.height/2-a})`)},`positionLabel`),nn=n(e=>{let t=Number.parseFloat(e??``);return Number.isFinite(t)&&t>=0?t:en},`numericStrokeWidth`);async function rn(e,t){let r=t,{labelStyles:i,nodeStyles:a}=_(t),{stylesMap:o}=y(t);t.labelStyle=i;let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t,`usecase-json-table`));s.attr(`role`,`img`),r.accessibleName&&s.attr(`aria-label`,r.accessibleName),l.attr(`class`,`label usecase-json-title`);let u=s.append(`g`).attr(`class`,`usecase-json-table-grid`),d=[];for(let e of r.jsonRows??[]){let n=await F(u,e.key,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0}),r=await F(u,e.value,{labelStyle:i,useHtmlLabels:t.useHtmlLabels,padding:0,centerLabel:!0});d.push({key:{label:n.label.attr(`class`,`label usecase-json-key`),bbox:n.bbox},value:{label:r.label.attr(`class`,`label usecase-json-value`),bbox:r.bbox}})}let f=Math.max(0,...d.map(({key:e})=>e.bbox.width))+Qt*2,p=Math.max(0,...d.map(({value:e})=>e.bbox.width))+Qt*2,m=c.width+Qt*2,h=Math.max(m,f+p),v=p+Math.max(0,h-f-p),b=c.height+$t*2,x=d.map(({key:e,value:t})=>Math.max(e.bbox.height,t.bbox.height)+$t*2),S=b+x.reduce((e,t)=>e+t,0),C=nn(o.get(`stroke-width`)),w=h+C*2,E=S+C*2,D=-h/2,O=-S/2,k=t.look===`handDrawn`?T.svg(s):void 0,A=k?g(t,{}):void 0,j=n((e,t,n,r,i,o)=>{if(k&&A){let a=k.rectangle(n,r,i,o,A);return e.insert(()=>a,`:first-child`).attr(`class`,t)}return e.insert(`rect`,`:first-child`).attr(`class`,t).attr(`x`,n).attr(`y`,r).attr(`width`,i).attr(`height`,o).attr(`style`,a)},`insertCell`),M=j(s,`label-container usecase-json-border`,-w/2,-E/2,w,E);j(u,`usecase-json-cell usecase-json-title-cell`,D,O,h,b),u.node()?.append(l.node()),tn(l,c,0,O+b/2);let N=O+b;return d.forEach(({key:e,value:t},n)=>{let r=x[n],i=u.append(`g`).attr(`class`,`usecase-json-row`).attr(`data-row-index`,n).attr(`transform`,`translate(0,${N})`);j(i,`usecase-json-cell usecase-json-key-cell`,D,0,f,r),j(i,`usecase-json-cell usecase-json-value-cell`,D+f,0,v,r),i.node()?.append(e.label.node(),t.label.node()),tn(e.label,e.bbox,D+f/2,r/2),tn(t.label,t.bbox,D+f+v/2,r/2),N+=r}),I(t,M),t.intersect=e=>K.rect(t,e),s}n(rn,`usecaseJsonTable`);async function an(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,s=t.look===`neo`?10:5;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2-2*s,10),t.height=Math.max((t?.height??0)-o*2-2*s,10));let{shapeSvg:c,bbox:l,label:u}=await P(e,t,L(t)),d=(t?.width?t?.width:l.width)+a*2+2*s,f=(t?.height?t?.height:l.height)+o*2+2*s,p=d-2*s,m=f-2*s,h=-p/2,v=-m/2,{cssStyles:y}=t,b=T.svg(c),x=g(t,{}),S=[{x:h-s,y:v+s},{x:h-s,y:v+m+s},{x:h+p-s,y:v+m+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v+m-s},{x:h+p+s,y:v+m-s},{x:h+p+s,y:v-s},{x:h+s,y:v-s},{x:h+s,y:v},{x:h,y:v},{x:h,y:v+s}],C=[{x:h,y:v+s},{x:h+p-s,y:v+s},{x:h+p-s,y:v+m},{x:h+p,y:v+m},{x:h+p,y:v},{x:h,y:v}];t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let w=R(S),E=b.path(w,x),D=R(C),O=b.path(D,x);t.look!==`handDrawn`&&(E=ee(E),O=ee(O));let k=c.insert(`g`,`:first-child`);return k.insert(()=>E),k.insert(()=>O),k.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&k.selectAll(`path`).attr(`style`,r),u.attr(`transform`,`translate(${-(l.width/2)-s-(l.x-(l.left??0))}, ${-(l.height/2)+s-(l.y-(l.top??0))})`),I(t,k),t.intersect=function(e){return K.polygon(t,S,e)},c}n(an,`multiRect`);async function on(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=t.padding??0,c=t.look===`neo`?16:s,l=t.look===`neo`?12:s,u=!0;(t.width||t.height)&&(u=!1,t.width=(t?.width??0)-c*2,t.height=(t?.height??0)-l*3);let d=Math.max(a.width,t?.width??0)+c*2,f=Math.max(a.height,t?.height??0)+l*3,p=t.look===`neo`?f/4:f/8,m=f+(u?p/2:-p/2),h=-d/2,v=-m/2,{cssStyles:y}=t,b=z(h-10,v+m+10,h+d-10,v+m+10,p,.8),x=b?.[b.length-1],S=[{x:h-10,y:v+10},{x:h-10,y:v+m+10},...b,{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:x.y-20},{x:h+d+10,y:x.y-20},{x:h+d+10,y:v-10},{x:h+10,y:v-10},{x:h+10,y:v},{x:h,y:v},{x:h,y:v+10}],C=[{x:h,y:v+10},{x:h+d-10,y:v+10},{x:h+d-10,y:x.y-10},{x:h+d,y:x.y-10},{x:h+d,y:v},{x:h,y:v}],w=T.svg(i),E=g(t,{});t.look!==`handDrawn`&&(E.roughness=0,E.fillStyle=`solid`);let D=R(S),O=w.path(D,E),k=R(C),A=w.path(k,E),j=i.insert(()=>O,`:first-child`);return j.insert(()=>A),j.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&j.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&j.selectAll(`path`).attr(`style`,r),j.attr(`transform`,`translate(0,${-p/2})`),o.attr(`transform`,`translate(${-(a.width/2)-10-(a.x-(a.left??0))}, ${-(a.height/2)+10-p-(a.y-(a.top??0))})`),I(t,j),t.intersect=function(e){return K.polygon(t,S,e)},i}n(on,`multiWaveEdgedRectangle`);async function sn(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r,t.useHtmlLabels||o(s())||(t.centerLabel=!0);let{shapeSvg:a,bbox:c,label:l}=await P(e,t,L(t)),u=Math.max(c.width+(t.padding??0)*2,t?.width??0),d=Math.max(c.height+(t.padding??0)*2,t?.height??0),f=-u/2,p=-d/2,{cssStyles:m}=t,h=T.svg(a),v=g(t,{fill:n.noteBkgColor,stroke:n.noteBorderColor});t.look!==`handDrawn`&&(v.roughness=0,v.fillStyle=`solid`);let y=h.rectangle(f,p,u,d,v),b=a.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),l.attr(`class`,`label noteLabel`),m&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,m),i&&t.look!==`handDrawn`&&b.selectAll(`path`).attr(`style`,i),l.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,b),t.intersect=function(e){return K.rect(t,e)},a}n(sn,`note`);var cn=n((e,t,n)=>[`M${e+n/2},${t}`,`L${e+n},${t-n/2}`,`L${e+n/2},${t-n}`,`L${e},${t-n/2}`,`Z`].join(` `),`createDecisionBoxPathD`);async function ln(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await P(e,t,L(t)),o=a.width+(t.padding??0)+(a.height+(t.padding??0)),s=.5,c=[{x:o/2,y:0},{x:o,y:-o/2},{x:o/2,y:-o},{x:0,y:-o/2}],l,{cssStyles:u}=t;if(t.look===`handDrawn`){let e=T.svg(i),n=g(t,{}),r=cn(0,0,o),a=e.path(r,n);l=i.insert(()=>a,`:first-child`).attr(`transform`,`translate(${-o/2+s}, ${o/2})`),u&&l.attr(`style`,u)}else l=J(i,o,o,c),l.attr(`transform`,`translate(${-o/2+s}, ${o/2})`);return r&&l.attr(`style`,r),I(t,l),t.calcIntersect=function(e,t){let n=e.width,r=[{x:n/2,y:0},{x:n,y:-n/2},{x:n/2,y:-n},{x:0,y:-n/2}];return K.polygon(e,r,t)},t.intersect=function(e){return this.calcIntersect(t,e)},i}n(ln,`question`);async function un(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?21:i??0,o=t.look===`neo`?12:i??0,{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=c.width+(t.look===`neo`?a*2:a),d=Math.max(c.height+(t.look===`neo`?o*2:o),t.height??0),f=d/4,p=-Math.max(u,(t.width??0)-f)/2,m=-d/2,h=m/2,v=[{x:p+h,y:m},{x:p,y:0},{x:p+h,y:-m},{x:-p,y:-m},{x:-p,y:m}],{cssStyles:y}=t,b=T.svg(s),x=g(t,{});t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let S=R(v),C=b.path(S,x),w=s.insert(()=>C,`:first-child`);return w.attr(`class`,`basic label-container outer-path`),y&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,y),r&&t.look!==`handDrawn`&&w.selectAll(`path`).attr(`style`,r),w.attr(`transform`,`translate(${-h/2},0)`),l.attr(`transform`,`translate(${-h/2-c.width/2-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,w),t.intersect=function(e){return K.polygon(t,v,e)},s}n(un,`rect_left_inv_arrow`);async function dn(n,r){let{labelStyles:i,nodeStyles:a}=_(r);r.labelStyle=i;let s;s=r.cssClasses?`node `+r.cssClasses:`node default`;let c=n.insert(`g`).attr(`class`,s).attr(`id`,r.domId||r.id),l=c.insert(`g`),d=c.insert(`g`).attr(`class`,`label`).attr(`style`,a),f=r.description,p=r.label,m=await se(d,p,r.labelStyle,!0,!0),h={width:0,height:0};if(o(u())){let e=m.children[0],n=t(m);h=e.getBoundingClientRect(),n.attr(`width`,h.width),n.attr(`height`,h.height)}e.info(`Text 2`,f);let v=f||[],y=m.getBBox(),b=await se(d,Array.isArray(v)?v.join(`
    `):v,r.labelStyle,!0,!0),x=b.children[0],S=t(b);h=x.getBoundingClientRect(),S.attr(`width`,h.width),S.attr(`height`,h.height);let C=(r.padding||0)/2;t(b).attr(`transform`,`translate( `+(h.width>y.width?0:(y.width-h.width)/2)+`, `+(y.height+C+5)+`)`),t(m).attr(`transform`,`translate( `+(h.width(e.debug(`Rough node insert CXC`,i),a),`:first-child`),k=c.insert(()=>(e.debug(`Rough node insert CXC`,i),i),`:first-child`)}else k=l.insert(`rect`,`:first-child`),A=l.insert(`line`),k.attr(`class`,`outer title-state`).attr(`style`,a).attr(`x`,-h.width/2-C).attr(`y`,-h.height/2-C).attr(`width`,h.width+(r.padding||0)).attr(`height`,h.height+(r.padding||0)),A.attr(`class`,`divider`).attr(`x1`,-h.width/2-C).attr(`x2`,h.width/2+C).attr(`y1`,-h.height/2-C+y.height+C).attr(`y2`,-h.height/2-C+y.height+C);return I(r,k),r.intersect=function(e){return K.rect(r,e)},c}n(dn,`rectWithTitle`);async function fn(e,t,{config:{themeVariables:n}}){let r=n?.radius??5;return Ke(e,t,{rx:r,ry:r,classes:``,labelPaddingX:(t?.padding??0)*1,labelPaddingY:(t?.padding??0)*1})}n(fn,`roundedRect`);var pn=8;async function mn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?12:t.padding??0,{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=(t?.width??s.width)+i*2+(t.look===`neo`?pn:pn*2),u=(t?.height??s.height)+a*2,d=l-pn,f=u,p=pn-l/2,m=-u/2,{cssStyles:v}=t,y=T.svg(o),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:p,y:m},{x:p+d,y:m},{x:p+d,y:m+f},{x:p-pn,y:m+f},{x:p-pn,y:m},{x:p,y:m},{x:p,y:m+f}],S=y.polygon(x.map(e=>[e.x,e.y]),b),C=o.insert(()=>S,`:first-child`);return C.attr(`class`,`basic label-container outer-path`).attr(`style`,h(v)),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),v&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${pn/2-s.width/2-(s.x-(s.left??0))}, ${-(s.height/2)-(s.y-(s.top??0))})`),I(t,C),t.intersect=function(e){return K.rect(t,e)},o}n(mn,`shadedProcess`);async function hn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-a*2,10),t.height=Math.max((t?.height??0)/1.5-o*2,10));let{shapeSvg:s,bbox:c,label:l}=await P(e,t,L(t)),u=(t?.width?t?.width:c.width)+a*2,d=((t?.height?t?.height:c.height)+o*2)*1.5,f=u,p=d/1.5,m=-f/2,h=-p/2,{cssStyles:v}=t,y=T.svg(s),b=g(t,{});t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let x=[{x:m,y:h},{x:m,y:h+p},{x:m+f,y:h+p},{x:m+f,y:h-p/2}],S=R(x),C=y.path(S,b),w=s.insert(()=>C,`:first-child`);return w.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,r),w.attr(`transform`,`translate(0, ${p/4})`),l.attr(`transform`,`translate(${-f/2+(t.padding??0)-(c.x-(c.left??0))}, ${-p/4+(t.padding??0)-(c.y-(c.top??0))})`),I(t,w),t.intersect=function(e){return K.polygon(t,x,e)},s}n(hn,`slopedRect`);async function gn(e,t){let n=t.padding??0,r=t.look===`neo`?16:n*2,i=t.look===`neo`?12:n,a=await Ke(e,t,{rx:0,ry:0,classes:``,labelPaddingX:t.labelPaddingX??r,labelPaddingY:i});if(t.colorIndex!==void 0){let{theme:e,themeVariables:n}=u();w(a,t.colorIndex,e,n.borderColorArray)}return a}n(gn,`squareRect`);var _n=50,vn=n((e,t,n)=>{let r=e.height+n,i=r*Math.cos(Math.PI/(2*(_n-1))),a=Math.sqrt(Math.max(0,i**2-e.height**2));return{w:Math.max(e.width+r/4+t,1.5*r+(r-i),e.width+t+r-a),h:r}},`stadiumDimensions`);async function yn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?40:i,o=t.look===`neo`?24:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),{w:l,h:u}=vn(c,a,o),d=u/2,{cssStyles:f}=t,p=T.svg(s),m=g(t,{});t.look!==`handDrawn`&&(m.roughness=0,m.fillStyle=`solid`);let h=[{x:-l/2+d,y:-u/2},{x:l/2-d,y:-u/2},...B(-l/2+d,0,d,_n,90,270),{x:l/2-d,y:u/2},...B(l/2-d,0,d,_n,270,450)],v=R(h),y=p.path(v,m),b=s.insert(()=>y,`:first-child`);return b.attr(`class`,`basic label-container outer-path`),f&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,f),r&&t.look!==`handDrawn`&&b.selectChildren(`path`).attr(`style`,r),I(t,b),t.intersect=function(e){return K.polygon(t,h,e)},s}n(yn,`stadium`);async function bn(e,t){return Ke(e,t,{rx:t.look===`neo`?3:5,ry:t.look===`neo`?3:5,classes:`flowchart-node`})}n(bn,`state`);function xn(e,t,{config:{themeVariables:n}}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r;let{cssStyles:a}=t,{lineColor:o,stateBorder:s,nodeBorder:c,nodeShadow:l}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let u=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId??t.id),d=T.svg(u),f=g(t,{});t.look!==`handDrawn`&&(f.roughness=0,f.fillStyle=`solid`);let p=d.circle(0,0,t.width,{...f,stroke:o,strokeWidth:2}),m=s??c,h=(t.width??0)*5/14,v=d.circle(0,0,h,{...f,fill:m,stroke:m,strokeWidth:2,fillStyle:`solid`}),y=u.insert(()=>p,`:first-child`);if(y.insert(()=>v),t.look!==`handDrawn`&&y.attr(`class`,`outer-path`),a&&y.selectAll(`path`).attr(`style`,a),i&&y.selectAll(`path`).attr(`style`,i),t.width<25&&l&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;y.attr(`style`,`filter:url(#${n})`)}return I(t,y),t.intersect=function(e){return K.circle(t,(t.width??0)/2,e)},u}n(xn,`stateEnd`);function Sn(e,t,{config:{themeVariables:n}}){let{lineColor:r,nodeShadow:i}=n;(t.width||t.height)&&((t.width??0)<14&&(t.width=14),(t.height??0)<14&&(t.height=14)),t.width||=14,t.height||=14;let a=e.insert(`g`).attr(`class`,`node default`).attr(`id`,t.domId||t.id),o;if(t.look===`handDrawn`){let e=T.svg(a).circle(0,0,t.width,v(r));o=a.insert(()=>e),o.attr(`class`,`state-start`).attr(`r`,(t.width??7)/2).attr(`width`,t.width??14).attr(`height`,t.height??14)}else o=a.insert(`circle`,`:first-child`),o.attr(`class`,`state-start`).attr(`r`,(t.width??7)/2).attr(`width`,t.width??14).attr(`height`,t.height??14);if(t.width<25&&i&&t.look!==`handDrawn`){let t=e.node()?.ownerSVGElement?.id??``,n=t?`${t}-drop-shadow-small`:`drop-shadow-small`;o.attr(`style`,`filter:url(#${n})`)}return I(t,o),t.intersect=function(e){return K.circle(t,(t.width??7)/2,e)},a}n(Sn,`stateStart`);var Cn=8;async function wn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t?.padding??8,a=t.look===`neo`?28:i,o=t.look===`neo`?12:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.width+2*Cn+a,t.width??0),u=Math.max(c.height+o,t.height??0),d=l-2*Cn,f=u,p=-l/2,m=-u/2,v=[{x:0,y:0},{x:d,y:0},{x:d,y:-f},{x:0,y:-f},{x:0,y:0},{x:-8,y:0},{x:d+8,y:0},{x:d+8,y:-f},{x:-8,y:-f},{x:-8,y:0}];if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=e.rectangle(p,m,d+16,f,n),i=e.line(p+Cn,m,p+Cn,m+f,n),a=e.line(p+Cn+d,m,p+Cn+d,m+f,n);s.insert(()=>i,`:first-child`),s.insert(()=>a,`:first-child`);let o=s.insert(()=>r,`:first-child`),{cssStyles:c}=t;o.attr(`class`,`basic label-container`).attr(`style`,h(c)),I(t,o)}else{let e=J(s,d,f,v);r&&e.attr(`style`,r),I(t,e)}return t.intersect=function(e){return K.polygon(t,v,e)},s}n(wn,`subroutine`);var Tn=.2;async function En(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.height=Math.max((t?.height??0)-o*2,10),t.width=Math.max((t?.width??0)-a*2-Tn*(t.height+o*2),10));let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.height?t?.height:c.height)+o*2,u=Tn*l,d=Tn*l,f=(t?.width?t?.width:c.width)+a*2+u-u,p=l,m=-f/2,h=-p/2,{cssStyles:v}=t,y=T.svg(s),b=g(t,{}),x=[{x:m-u/2,y:h},{x:m+f+u/2,y:h},{x:m+f+u/2,y:h+p},{x:m-u/2,y:h+p}],S=[{x:m+f-u/2,y:h+p},{x:m+f+u/2,y:h+p},{x:m+f+u/2,y:h+p-d}];t.look!==`handDrawn`&&(b.roughness=0,b.fillStyle=`solid`);let C=R(x),w=y.path(C,b),E=R(S),D=y.path(E,{...b,fillStyle:`solid`}),O=s.insert(()=>D,`:first-child`);return O.insert(()=>w,`:first-child`),O.attr(`class`,`basic label-container outer-path`),v&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,v),r&&t.look!==`handDrawn`&&O.selectAll(`path`).attr(`style`,r),I(t,O),t.intersect=function(e){return K.polygon(t,x,e)},s}n(En,`taggedRect`);async function Dn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,label:o}=await P(e,t,L(t)),s=Math.max(a.width+(t.padding??0)*2,t?.width??0),c=Math.max(a.height+(t.padding??0)*2,t?.height??0),l=c/8,u=.2*s,d=.2*c,f=c+l,{cssStyles:p}=t,m=T.svg(i),h=g(t,{});t.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-s/2-s/2*.1,y:f/2},...z(-s/2-s/2*.1,f/2,s/2+s/2*.1,f/2,l,.8),{x:s/2+s/2*.1,y:-f/2},{x:-s/2-s/2*.1,y:-f/2}],y=-s/2+s/2*.1,b=-f/2-d*.4,x=[{x:y+s-u,y:(b+c)*1.3},{x:y+s,y:b+c-d},{x:y+s,y:(b+c)*.9},...z(y+s,(b+c)*1.25,y+s-u,(b+c)*1.3,-c*.02,.5)],S=R(v),C=m.path(S,h),w=R(x),E=m.path(w,{...h,fillStyle:`solid`}),D=i.insert(()=>E,`:first-child`);return D.insert(()=>C,`:first-child`),D.attr(`class`,`basic label-container outer-path`),p&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,p),r&&t.look!==`handDrawn`&&D.selectAll(`path`).attr(`style`,r),D.attr(`transform`,`translate(0,${-l/2})`),o.attr(`transform`,`translate(${-s/2+(t.padding??0)-(a.x-(a.left??0))},${-c/2+(t.padding??0)-l/2-(a.y-(a.top??0))})`),I(t,D),t.intersect=function(e){return K.polygon(t,v,e)},i}n(Dn,`taggedWaveEdgedRectangle`);async function On(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a}=await P(e,t,L(t)),o=Math.max(a.width+(t.padding??0),t?.width||0),s=Math.max(a.height+(t.padding??0),t?.height||0),c=-o/2,l=-s/2,u=i.insert(`rect`,`:first-child`);return u.attr(`class`,`text`).attr(`style`,r).attr(`rx`,0).attr(`ry`,0).attr(`x`,c).attr(`y`,l).attr(`width`,o).attr(`height`,s),I(t,u),t.intersect=function(e){return K.rect(t,e)},i}n(On,`text`);var kn=n((e,t,n,r,i,a)=>`M${e},${t} + a${i},${a} 0,0,1 0,${-r} + l${n},0 + a${i},${a} 0,0,1 0,${r} + M${n},${-r} + a${i},${a} 0,0,0 0,${r} + l${-n},0`,`createCylinderPathD`),An=n((e,t,n,r,i,a)=>[`M${e},${t}`,`M${e+n},${t}`,`a${i},${a} 0,0,0 0,${-r}`,`l${-n},0`,`a${i},${a} 0,0,0 0,${r}`,`l${n},0`].join(` `),`createOuterCylinderPathD`),jn=n((e,t,n,r,i,a)=>[`M${e+n/2},${-r/2}`,`a${i},${a} 0,0,0 0,${r}`].join(` `),`createInnerCylinderPathD`),Mn=5,Nn=10;async function Pn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?12:i/2,o=t.height??0;if(t.height&&(t.height-=a,t.heighta,`:first-child`),v=s.insert(()=>i,`:first-child`),v.attr(`class`,`basic label-container`),m&&v.attr(`style`,m)}else{let e=kn(0,0,p,u,f,d);v=s.insert(`path`,`:first-child`).attr(`d`,e).attr(`class`,`basic label-container`).attr(`style`,h(m)).attr(`style`,r),v.attr(`class`,`basic label-container outer-path`),m&&v.selectAll(`path`).attr(`style`,m),r&&v.selectAll(`path`).attr(`style`,r)}return v.attr(`label-offset-x`,f),v.attr(`transform`,`translate(${-p/2}, ${u/2} )`),l.attr(`transform`,`translate(${-(c.width/2)-f-(c.x-(c.left??0))}, ${-(c.height/2)-(c.y-(c.top??0))})`),I(t,v),t.intersect=function(e){let n=K.rect(t,e),r=n.y-(t.y??0);if(d!=0&&(Math.abs(r)<(t.height??0)/2||Math.abs(r)==(t.height??0)/2&&Math.abs(n.x-(t.x??0))>(t.width??0)/2-f)){let i=f*f*(1-r*r/(d*d));i!=0&&(i=Math.sqrt(Math.abs(i))),i=f-i,e.x-(t.x??0)>0&&(i=-i),n.x+=i}return n},s}n(Pn,`tiltedCylinder`);async function Fn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=(t.look,i),o=t.look===`neo`?i*2:i,{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=Math.max(c.height+a,t.height??0),u=Math.max(c.width+o,(t.width??0)-l),d=[{x:-3*l/6,y:0},{x:u+3*l/6,y:0},{x:u,y:-l},{x:0,y:-l}],f,{cssStyles:p}=t;if(t.look===`handDrawn`){let e=T.svg(s),n=g(t,{}),r=R(d),i=e.path(r,n);f=s.insert(()=>i,`:first-child`).attr(`transform`,`translate(${-u/2}, ${l/2})`),p&&f.attr(`style`,p)}else f=J(s,u,l,d);return r&&f.attr(`style`,r),t.width=u,t.height=l,I(t,f),t.intersect=function(e){return K.polygon(t,d,e)},s}n(Fn,`trapezoid`);async function In(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i;(t.width||t.height)&&(t.height=(t.height??0)-o*2,t.height<5&&(t.height=5),t.width=(t.width??0)-a*2,t.width<15&&(t.width=15));let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width?t?.width:c.width)+a*2,u=(t?.height?t?.height:c.height)+o*2,{cssStyles:d}=t,f=T.svg(s),p=g(t,{});t.look!==`handDrawn`&&(p.roughness=0,p.fillStyle=`solid`);let m=[{x:-l/2*.8,y:-u/2},{x:l/2*.8,y:-u/2},{x:l/2,y:-u/2*.6},{x:l/2,y:u/2},{x:-l/2,y:u/2},{x:-l/2,y:-u/2*.6}],h=R(m),v=f.path(h,p),y=s.insert(()=>v,`:first-child`);return y.attr(`class`,`basic label-container outer-path`),d&&t.look!==`handDrawn`&&y.selectChildren(`path`).attr(`style`,d),r&&t.look!==`handDrawn`&&y.selectChildren(`path`).attr(`style`,r),I(t,y),t.intersect=function(e){return K.polygon(t,m,e)},s}n(In,`trapezoidalPentagon`);var Ln=10,Rn=10;async function zn(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n.padding??0,o=n.look===`neo`?a*2:a;(n.width||n.height)&&(n.width=((n?.width??0)-o)/2,n.widthC,`:first-child`).attr(`transform`,`translate(${-m/2}, ${m/2})`).attr(`class`,`outer-path`);return y&&n.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,y),i&&n.look!==`handDrawn`&&w.selectChildren(`path`).attr(`style`,i),n.width=p,n.height=m,I(n,w),d.attr(`transform`,`translate(${-c.width/2-(c.x-(c.left??0))}, ${m/2-(c.height+(n.padding??0)/(f?2:1)-(c.y-(c.top??0)))})`),n.intersect=function(t){return e.info(`Triangle intersect`,n,v,t),K.polygon(n,v,t)},s}n(zn,`triangle`);async function Bn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?12:i,s=!0;(t.width||t.height)&&(s=!1,t.width=(t?.width??0)-a*2,t.width<10&&(t.width=10),t.height=(t?.height??0)-o*2,t.height<10&&(t.height=10));let{shapeSvg:c,bbox:l,label:u}=await P(e,t,L(t)),d=(t?.width?t?.width:l.width)+(a??0)*2,f=(t?.height?t?.height:l.height)+(o??0)*2,p=t.look===`neo`?f/4:f/8,m=f+(s?p:-p),{cssStyles:h}=t,v=14-d,y=v>0?v/2:0,b=T.svg(c),x=g(t,{});t.look!==`handDrawn`&&(x.roughness=0,x.fillStyle=`solid`);let S=[{x:-d/2-y,y:m/2},...z(-d/2-y,m/2,d/2+y,m/2,p,.8),{x:d/2+y,y:-m/2},{x:-d/2-y,y:-m/2}],C=R(S),w=b.path(C,x),E=c.insert(()=>w,`:first-child`);return E.attr(`class`,`basic label-container outer-path`),h&&t.look!==`handDrawn`&&E.selectAll(`path`).attr(`style`,h),r&&t.look!==`handDrawn`&&E.selectAll(`path`).attr(`style`,r),E.attr(`transform`,`translate(0,${-p/2})`),u.attr(`transform`,`translate(${-d/2+(t.padding??0)-(l.x-(l.left??0))},${-f/2+(t.padding??0)-p-(l.y-(l.top??0))})`),I(t,E),t.intersect=function(e){return K.polygon(t,S,e)},c}n(Bn,`waveEdgedRectangle`);async function Vn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.padding??0,a=t.look===`neo`?16:i,o=t.look===`neo`?20:i;if(t.width||t.height){t.width=t?.width??0,t.width<20&&(t.width=20),t.height=t?.height??0,t.height<10&&(t.height=10);let e=Math.min(t.height*.2,t.height/4);t.height=Math.ceil(t.height-o-20/9*e),t.width-=a*2}let{shapeSvg:s,bbox:c}=await P(e,t,L(t)),l=(t?.width?t?.width:c.width)+a*2,u=(t?.height?t?.height:c.height)+o,d=u/8,f=u+d*2,{cssStyles:p}=t,m=T.svg(s),h=g(t,{});t.look!==`handDrawn`&&(h.roughness=0,h.fillStyle=`solid`);let v=[{x:-l/2,y:f/2},...z(-l/2,f/2,l/2,f/2,d,1),{x:l/2,y:-f/2},...z(l/2,-f/2,-l/2,-f/2,d,-1)],y=R(v),b=m.path(y,h),x=s.insert(()=>b,`:first-child`);return x.attr(`class`,`basic label-container`),p&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,p),r&&t.look!==`handDrawn`&&x.selectAll(`path`).attr(`style`,r),I(t,x),t.intersect=function(e){return K.polygon(t,v,e)},s}n(Vn,`waveRectangle`);var Q=10;async function Hn(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let i=t.look===`neo`?16:t.padding??0,a=t.look===`neo`?12:t.padding??0;(t.width||t.height)&&(t.width=Math.max((t?.width??0)-i*2-Q,10),t.height=Math.max((t?.height??0)-a*2-Q,10));let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=(t?.width?t?.width:s.width)+i*2+Q,u=(t?.height?t?.height:s.height)+a*2+Q,d=l-Q,f=u-Q,p=-d/2,m=-f/2,{cssStyles:h}=t,v=T.svg(o),y=g(t,{}),b=[{x:p-Q,y:m-Q},{x:p-Q,y:m+f},{x:p+d,y:m+f},{x:p+d,y:m-Q}],x=`M${p-Q},${m-Q} L${p+d},${m-Q} L${p+d},${m+f} L${p-Q},${m+f} L${p-Q},${m-Q} + M${p-Q},${m} L${p+d},${m} + M${p},${m-Q} L${p},${m+f}`;t.look!==`handDrawn`&&(y.roughness=0,y.fillStyle=`solid`);let S=v.path(x,y),C=o.insert(()=>S,`:first-child`);return C.attr(`transform`,`translate(${Q/2}, ${Q/2})`),C.attr(`class`,`basic label-container outer-path`),h&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,h),r&&t.look!==`handDrawn`&&C.selectAll(`path`).attr(`style`,r),c.attr(`transform`,`translate(${-(s.width/2)+Q/2-(s.x-(s.left??0))}, ${-(s.height/2)+Q/2-(s.y-(s.top??0))})`),I(t,C),t.intersect=function(e){return K.polygon(t,b,e)},o}n(Hn,`windowPane`);var Un=new Set([`redux-color`,`redux-dark-color`]),Wn=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]);async function Gn(e,n){let r=n;r.alias&&(n.label=r.alias);let{theme:i,themeVariables:a}=s(),{rowEven:o,rowOdd:c,nodeBorder:u,borderColorArray:d}=a;if(n.look===`handDrawn`){let{themeVariables:t}=s(),{background:r}=t;await Gn(e,{...n,id:n.id+`-background`,domId:(n.domId||n.id)+`-background`,look:`default`,cssStyles:[`stroke: none`,`fill: ${r}`]})}let f=s();n.useHtmlLabels=f.htmlLabels;let p=f.er?.diagramPadding??10,h=f.er?.entityPadding??6,{cssStyles:v}=n,{labelStyles:y,nodeStyles:b}=_(n);if(r.attributes.length===0&&n.label){let t={rx:0,ry:0,labelPaddingX:p,labelPaddingY:p*1.5,classes:``};m(n.label,f)+t.labelPaddingX*20){let e=C.width+p*2-(O+k+A+j);O+=e/P,k+=e/P,A>0&&(A+=e/P),j>0&&(j+=e/P)}let R=O+k+A+j,z=T.svg(S),B=g(n,{});n.look!==`handDrawn`&&(B.roughness=0,B.fillStyle=`solid`);let ee=0;D.length>0&&(ee=D.reduce((e,t)=>e+(t?.rowHeight??0),0));let V=Math.max(F.width+p*2,n?.width||0,R),te=Math.max((ee??0)+C.height,n?.height||0),H=-V/2,U=-te/2;if(S.selectAll(`g:not(:first-child)`).each((e,n,r)=>{let i=t(r[n]),a=i.attr(`transform`),o=0,s=0;if(a){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(a);e&&(o=parseFloat(e[1]),s=parseFloat(e[2]),i.attr(`class`).includes(`attribute-name`)?o+=O:i.attr(`class`).includes(`attribute-keys`)?o+=O+k:i.attr(`class`).includes(`attribute-comment`)&&(o+=O+k+A))}i.attr(`transform`,`translate(${H+p/2+o}, ${s+U+C.height+h/2})`)}),S.select(`.name`).attr(`transform`,`translate(`+-C.width/2+`, `+(U+h/2)+`)`),i!=null&&Un.has(i)){let e=r.colorIndex??0;S.attr(`data-color-id`,`color-${e%d.length}`)}let ne=z.rectangle(H,U,V,te,B),re=S.insert(()=>ne,`:first-child`).attr(`class`,`outer-path`).attr(`style`,v.join(``));E.push(0);for(let[e,t]of D.entries()){let n=(e+1)%2==0&&t.yOffset!==0,r=z.rectangle(H,C.height+U+t?.yOffset,V,t?.rowHeight,{...B,fill:n?o:c,stroke:u});S.insert(()=>r,`g.label`).attr(`style`,v.join(``)).attr(`class`,`row-rect-${n?`even`:`odd`}`)}let ie=1e-4,W=qn(H,C.height+U,V+H,C.height+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B);if(S.insert(()=>G).attr(`class`,`divider`),W=qn(O+H,C.height+U,O+H,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`),M){let e=O+k+H;W=qn(e,C.height+U,e,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}if(N){let e=O+k+A+H;W=qn(e,C.height+U,e,te+U,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}for(let e of E){let t=C.height+U+e;W=qn(H,t,V+H,t,ie),G=z.polygon(W.map(e=>[e.x,e.y]),B),S.insert(()=>G).attr(`class`,`divider`)}if(I(n,re),b&&n.look!==`handDrawn`){if(i!=null&&Wn.has(i))S.selectAll(`path`).attr(`style`,b);else{let e=b.split(`;`)?.filter(e=>e.includes(`stroke`))?.map(e=>`${e}`).join(`; `);S.selectAll(`path`).attr(`style`,e??``),S.selectAll(`.row-rect-even path`).attr(`style`,b)}}return n.intersect=function(e){return K.rect(n,e)},S}n(Gn,`erBox`);async function Kn(e,n,r,i=0,o=0,s=[],c=``){let u=e.insert(`g`).attr(`class`,`label ${s.join(` `)}`).attr(`transform`,`translate(${i}, ${o})`).attr(`style`,c);n!==a(n)&&(n=a(n),n=n.replaceAll(`<`,`<`).replaceAll(`>`,`>`));let d=u.node().appendChild(await S(u,n,{width:m(n,r)+100,style:c,useHtmlLabels:r.htmlLabels},r));if(n.includes(`<`)||n.includes(`>`)){let e=d.children[0];for(e.textContent=e.textContent.replaceAll(`<`,`<`).replaceAll(`>`,`>`);e.childNodes[0];)e=e.childNodes[0],e.textContent=e.textContent.replaceAll(`<`,`<`).replaceAll(`>`,`>`)}let f=d.getBBox();if(l(r.htmlLabels)){let e=d.children[0];e.style.textAlign=`start`;let n=t(d);f=e.getBoundingClientRect(),n.attr(`width`,f.width),n.attr(`height`,f.height)}return f}n(Kn,`addText`);function qn(e,t,n,r,i){return e===n?[{x:e-i/2,y:t},{x:e+i/2,y:t},{x:n+i/2,y:r},{x:n-i/2,y:r}]:[{x:e,y:t-i/2},{x:e,y:t+i/2},{x:n,y:r+i/2},{x:n,y:r-i/2}]}n(qn,`lineToPolygon`);async function Jn(e,t,n,r,i=n.class.padding??12){let a=r?0:3,o=e.insert(`g`).attr(`class`,L(t)).attr(`id`,t.domId||t.id),s=null,c=null,l=null,u=null,d=0,f=0,p=0;if(s=o.insert(`g`).attr(`class`,`annotation-group text`),t.annotations.length>0){let e=t.annotations[0];await Yn(s,{text:`\xAB${e}\xBB`},0),d=s.node().getBBox().height}c=o.insert(`g`).attr(`class`,`label-group text`),await Yn(c,t,0,[`font-weight: bolder`]);let m=c.node().getBBox();f=m.height,l=o.insert(`g`).attr(`class`,`members-group text`);let h=0;for(let e of t.members){let t=await Yn(l,e,h,[e.parseClassifier()]);h+=t+a}p=l.node().getBBox().height,p<=0&&(p=i/2),u=o.insert(`g`).attr(`class`,`methods-group text`);let g=0;for(let e of t.methods){let t=await Yn(u,e,g,[e.parseClassifier()]);g+=t+a}let _=o.node().getBBox();if(s!==null){let e=s.node().getBBox();s.attr(`transform`,`translate(${-e.width/2})`)}return c.attr(`transform`,`translate(${-m.width/2}, ${d})`),_=o.node().getBBox(),l.attr(`transform`,`translate(0, ${d+f+i*2})`),_=o.node().getBBox(),u.attr(`transform`,`translate(0, ${d+f+(p?p+i*4:i*2)})`),_=o.node().getBBox(),{shapeSvg:o,bbox:_}}n(Jn,`textHelper`);async function Yn(e,n,a,o=[]){let c=e.insert(`g`).attr(`class`,`label`).attr(`style`,o.join(`; `)),u=s(),d=`useHtmlLabels`in n?n.useHtmlLabels:l(u.htmlLabels)??!0,p=``;p=`text`in n?n.text:n.label,!d&&p.startsWith(`\\`)&&(p=p.substring(1)),r(p)&&(d=!0);let h=await S(c,i(f(p)),{width:m(p,u)+50,classes:`markdown-node-label`,useHtmlLabels:d},u),g,_=1;if(d){let e=h.children[0],n=t(h);_=e.innerHTML.split(`
    `).length,e.innerHTML.includes(``)&&(_+=e.innerHTML.split(``).length-1),await O(e),g=e.getBoundingClientRect(),n.attr(`width`,g.width),n.attr(`height`,g.height)}else{o.includes(`font-weight: bolder`)&&t(h).selectAll(`tspan`).attr(`font-weight`,``),_=h.children.length;let e=h.children[0];(h.textContent===``||h.textContent.includes(`>`))&&(e.textContent=p[0]+p.substring(1).replaceAll(`>`,`>`).replaceAll(`<`,`<`).trim(),p[1]===` `&&(e.textContent=e.textContent[0]+` `+e.textContent.substring(1))),e.textContent===`undefined`&&(e.textContent=``),g=h.getBBox()}return c.attr(`transform`,`translate(0,`+(-g.height/(2*_)+a)+`)`),g.height}n(Yn,`addText`);async function Xn(e,n){let r=u(),{theme:i,themeVariables:a}=r,{useGradient:o,borderColorArray:s}=a,c=r.class.padding??12,d=c,f=n.useHtmlLabels??l(r.htmlLabels)??!0,p=n;p.annotations=p.annotations??[],p.members=p.members??[],p.methods=p.methods??[];let{shapeSvg:m,bbox:h}=await Jn(e,n,r,f,d);w(m,n.colorIndex,i,s);let{labelStyles:v,nodeStyles:y}=_(n);n.labelStyle=v,n.cssStyles=p.styles||``;let b=p.styles?.join(`;`)||y||``;n.cssStyles||=b.replaceAll(`!important`,``).split(`;`);let x=p.members.length===0&&p.methods.length===0&&!r.class?.hideEmptyMembersBox,S=T.svg(m),C=g(n,{});n.look!==`handDrawn`&&(C.roughness=0,C.fillStyle=`solid`);let E=Math.max(n.width??0,h.width),D=Math.max(n.height??0,h.height),O=(n.height??0)>h.height;p.members.length===0&&p.methods.length===0?D+=d:p.members.length>0&&p.methods.length===0&&(D+=d*2);let k=-E/2,A=-D/2,j=x?c*2:p.members.length===0&&p.methods.length===0?-c:0;O&&(j=c*2);let M=S.rectangle(k-c,A-c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0),E+2*c,D+2*c+j,C),N=m.insert(()=>M,`:first-child`);N.attr(`class`,`basic label-container outer-path`);let P=N.node().getBBox(),F=m.select(`.annotation-group`).node().getBBox().height-(x?c/2:0)||0,L=m.select(`.label-group`).node().getBBox().height-(x?c/2:0)||0,R=m.select(`.members-group`).node().getBBox().height-(x?c/2:0)||0,z=(F+L+A+c-(A-c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0)))/2;if(m.selectAll(`.text`).each((e,n,i)=>{let a=t(i[n]),o=a.attr(`transform`),s=0;if(o){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(o);e&&(s=parseFloat(e[2]))}let l=s+A+c-(x?c:p.members.length===0&&p.methods.length===0?-c/2:0);if(a.attr(`class`).includes(`methods-group`)){let e=Math.max(R,d/2);l=O?Math.max(z,F+L+e+A+d*2+c)+d*2:F+L+e+A+d*4+c}p.members.length===0&&p.methods.length===0&&r.class?.hideEmptyMembersBox&&(l=p.annotations.length>0?s-d:s),f||(l-=4);let u=k;(a.attr(`class`).includes(`label-group`)||a.attr(`class`).includes(`annotation-group`))&&(u=-a.node()?.getBBox().width/2||0,m.selectAll(`text`).each(function(e,t,n){window.getComputedStyle(n[t]).textAnchor===`middle`&&(u=0)})),a.attr(`transform`,`translate(${u}, ${l})`)}),p.members.length>0||p.methods.length>0||x){let e=F+L+A+c,t=S.line(P.x,e,P.x+P.width,e+.001,C);m.insert(()=>t).attr(`class`,`divider${n.look===`neo`&&!o?` neo-line`:``}`).attr(`style`,b)}if(x||p.members.length>0||p.methods.length>0){let e=F+L+R+A+d*2+c,t=S.line(P.x,O?Math.max(z,e):e,P.x+P.width,(O?Math.max(z,e):e)+.001,C);m.insert(()=>t).attr(`class`,`divider${n.look===`neo`&&!o?` neo-line`:``}`).attr(`style`,b)}if(p.look!==`handDrawn`&&m.selectAll(`path`).attr(`style`,b),N.select(`:nth-child(2)`).attr(`style`,b),m.selectAll(`.divider`).select(`path`).attr(`style`,b),n.labelStyle?m.selectAll(`span`).attr(`style`,n.labelStyle):m.selectAll(`span`).attr(`style`,b),!f){let e=RegExp(/color\s*:\s*([^;]*)/),t=e.exec(b);if(t){let e=t[0].replace(`color`,`fill`);m.selectAll(`tspan`).attr(`style`,e)}else if(v){let t=e.exec(v);if(t){let e=t[0].replace(`color`,`fill`);m.selectAll(`tspan`).attr(`style`,e)}}}return I(n,N),n.intersect=function(e){return K.rect(n,e)},m}n(Xn,`classBox`);async function Zn(e,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let a=n,o=n,s=`verifyMethod`in n,c=L(n),l=u(),{themeVariables:d}=l,{borderColorArray:f,requirementEdgeLabelBackground:p}=d,m=l.layout===`elk`?`start`:`center`,h=e.insert(`g`).attr(`class`,c).attr(`id`,n.domId??n.id),v;v=s?await $(h,`<<${a.type}>>`,0,n.labelStyle):await $(h,`<<Element>>`,0,n.labelStyle);let y=v,b=await $(h,a.name,y,n.labelStyle+`; font-weight: bold;`);if(y+=b+20,s){let e=await $(h,`${a.requirementId?`ID: ${a.requirementId}`:``}`,y,n.labelStyle,m);y+=e;let t=await $(h,`${a.text?`Text: ${a.text}`:``}`,y,n.labelStyle,m);y+=t;let r=await $(h,`${a.risk?`Risk: ${a.risk}`:``}`,y,n.labelStyle,m);y+=r,await $(h,`${a.verifyMethod?`Verification: ${a.verifyMethod}`:``}`,y,n.labelStyle,m)}else{let e=await $(h,`${o.type?`Type: ${o.type}`:``}`,y,n.labelStyle,m);y+=e,await $(h,`${o.docRef?`Doc Ref: ${o.docRef}`:``}`,y,n.labelStyle,m)}let x=(h.node()?.getBBox().width??200)+20,S=(h.node()?.getBBox().height??200)+20,C=-x/2,w=-S/2,E=T.svg(h),D=g(n,{});n.look!==`handDrawn`&&(D.roughness=0,D.fillStyle=`solid`);let O=E.rectangle(C,w,x,S,D),k=h.insert(()=>O,`:first-child`);if(k.attr(`class`,`basic label-container outer-path`).attr(`style`,i),f?.length){let e=n.colorIndex??0;h.attr(`data-color-id`,`color-${e%f.length}`)}if(h.selectAll(`.label`).each((e,n,r)=>{let i=t(r[n]),a=i.attr(`transform`),o=0,s=0;if(a){let e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(a);e&&(o=parseFloat(e[1]),s=parseFloat(e[2]))}let c=s-S/2,l=C+10;(n===0||n===1)&&(l=o),i.attr(`transform`,`translate(${l}, ${c+20})`)}),y>v+b+20){let e=w+v+b+20,t;if(n.look===`neo`){let n=.001,r=[[C,e],[C+x,e],[C+x,e+n],[C,e+n]];t=E.polygon(r,D)}else t=E.line(C,e,C+x,e,D);h.insert(()=>t).attr(`class`,`divider`)}return I(n,k),n.intersect=function(e){return K.rect(n,e)},i&&n.look!==`handDrawn`&&(p||f?.length)&&h.selectAll(`path`).attr(`style`,i),h}n(Zn,`requirementBox`);async function $(e,n,r,a=``,o=`center`){if(n===``)return 0;let s=e.insert(`g`).attr(`class`,`label`).attr(`style`,a),c=u(),l=c.htmlLabels??!0,d=await S(s,i(f(n)),{width:m(n,c)+50,classes:`markdown-node-label`,useHtmlLabels:l,style:a},c),p;if(l){let e=d.children[0],n=t(d);o===`start`&&t(e).style(`text-align`,`left`),p=e.getBoundingClientRect(),n.attr(`width`,p.width),n.attr(`height`,p.height)}else{let e=d.children[0];for(let t of e.children)a&&t.setAttribute(`style`,a);if(o===`start`){e.setAttribute(`text-anchor`,`start`);for(let t of e.children)t.setAttribute(`text-anchor`,`start`)}p=d.getBBox(),p.height+=6}return s.attr(`transform`,`translate(${-p.width/2},${-p.height/2+r})`),p.height}n($,`addText`);var Qn=n(e=>{switch(e){case`Very High`:return`red`;case`High`:return`orange`;case`Medium`:return null;case`Low`:return`blue`;case`Very Low`:return`lightblue`}},`colorFromPriority`);async function $n(e,t,{config:n}){let{labelStyles:r,nodeStyles:i}=_(t);t.labelStyle=r||``;let a=t.width;t.width=(t.width??200)-10;let{shapeSvg:o,bbox:s,label:c}=await P(e,t,L(t)),l=t.padding||10,u=``,d;`ticket`in t&&t.ticket&&n?.kanban?.ticketBaseUrl&&(u=n?.kanban?.ticketBaseUrl.replace(`#TICKET#`,t.ticket),d=o.insert(`svg:a`,`:first-child`).attr(`class`,`kanban-ticket-link`).attr(`xlink:href`,u).attr(`target`,`_blank`));let f={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||``,width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1},p,m;d?{label:p,bbox:m}=await F(d,`ticket`in t&&t.ticket||``,f):{label:p,bbox:m}=await F(o,`ticket`in t&&t.ticket||``,f);let{label:h,bbox:v}=await F(o,`assigned`in t&&t.assigned||``,f);t.width=a;let y=t?.width||0,b=Math.max(m.height,v.height)/2,x=Math.max(s.height+20,t?.height||0)+b,S=-y/2,C=-x/2;c.attr(`transform`,`translate(`+(l-y/2)+`, `+(-b-s.height/2)+`)`),p.attr(`transform`,`translate(`+(l-y/2)+`, `+(-b+s.height/2)+`)`),h.attr(`transform`,`translate(`+(l+y/2-v.width-20)+`, `+(-b+s.height/2)+`)`);let w,{rx:E,ry:D}=t,{cssStyles:O}=t;if(t.look===`handDrawn`){let e=T.svg(o),n=g(t,{}),r=E||D?e.path(q(S,C,y,x,E||0),n):e.rectangle(S,C,y,x,n);w=o.insert(()=>r,`:first-child`),w.attr(`class`,`basic label-container`).attr(`style`,O||null)}else{w=o.insert(`rect`,`:first-child`),w.attr(`class`,`basic label-container __APA__`).attr(`style`,i).attr(`rx`,E??5).attr(`ry`,D??5).attr(`x`,S).attr(`y`,C).attr(`width`,y).attr(`height`,x);let e=`priority`in t&&t.priority;if(e){let t=o.append(`line`),n=S+2,r=C+Math.floor((E??0)/2),i=C+x-Math.floor((E??0)/2);t.attr(`x1`,n).attr(`y1`,r).attr(`x2`,n).attr(`y2`,i).attr(`stroke-width`,`4`).attr(`stroke`,Qn(e))}}return I(t,w),t.height=x,t.intersect=function(e){return K.rect(t,e)},o}n($n,`kanbanItem`);async function er(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(t,n,L(n)),l=o.width+10*s,u=o.height+8*s,d=.15*l,{cssStyles:f}=n,p=o.width+20,m=o.height+20,v=Math.max(l,p),y=Math.max(u,m);c.attr(`transform`,`translate(${-o.width/2}, ${-o.height/2})`);let b,x=`M0 0 + a${d},${d} 1 0,0 ${v*.25},${-1*y*.1} + a${d},${d} 1 0,0 ${v*.25},0 + a${d},${d} 1 0,0 ${v*.25},0 + a${d},${d} 1 0,0 ${v*.25},${y*.1} + + a${d},${d} 1 0,0 ${v*.15},${y*.33} + a${d*.8},${d*.8} 1 0,0 0,${y*.34} + a${d},${d} 1 0,0 ${-1*v*.15},${y*.33} + + a${d},${d} 1 0,0 ${-1*v*.25},${y*.15} + a${d},${d} 1 0,0 ${-1*v*.25},0 + a${d},${d} 1 0,0 ${-1*v*.25},0 + a${d},${d} 1 0,0 ${-1*v*.25},${-1*y*.15} + + a${d},${d} 1 0,0 ${-1*v*.1},${-1*y*.33} + a${d*.8},${d*.8} 1 0,0 0,${-1*y*.34} + a${d},${d} 1 0,0 ${v*.1},${-1*y*.33} + H0 V0 Z`;if(n.look===`handDrawn`){let e=T.svg(a),t=g(n,{}),r=e.path(x,t);b=a.insert(()=>r,`:first-child`),b.attr(`class`,`basic label-container`).attr(`style`,h(f))}else b=a.insert(`path`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,i).attr(`d`,x);return b.attr(`transform`,`translate(${-v/2}, ${-y/2})`),I(n,b),n.calcIntersect=function(e,t){return K.rect(e,t)},n.intersect=function(t){return e.info(`Bang intersect`,n,t),K.rect(n,t)},a}n(er,`bang`);async function tr(t,n){let{labelStyles:r,nodeStyles:i}=_(n);n.labelStyle=r;let{shapeSvg:a,bbox:o,halfPadding:s,label:c}=await P(t,n,L(n)),l=o.width+2*s,u=o.height+2*s,d=.15*l,f=.25*l,p=.35*l,m=.2*l,{cssStyles:v}=n,y,b=`M0 0 + a${d},${d} 0 0,1 ${l*.25},${-1*l*.1} + a${p},${p} 1 0,1 ${l*.4},${-1*l*.1} + a${f},${f} 1 0,1 ${l*.35},${l*.2} + + a${d},${d} 1 0,1 ${l*.15},${u*.35} + a${m},${m} 1 0,1 ${-1*l*.15},${u*.65} + + a${f},${d} 1 0,1 ${-1*l*.25},${l*.15} + a${p},${p} 1 0,1 ${-1*l*.5},0 + a${d},${d} 1 0,1 ${-1*l*.25},${-1*l*.15} + + a${d},${d} 1 0,1 ${-1*l*.1},${-1*u*.35} + a${m},${m} 1 0,1 ${l*.1},${-1*u*.65} + H0 V0 Z`;if(n.look===`handDrawn`){let e=T.svg(a),t=g(n,{}),r=e.path(b,t);y=a.insert(()=>r,`:first-child`),y.attr(`class`,`basic label-container`).attr(`style`,h(v))}else y=a.insert(`path`,`:first-child`).attr(`class`,`basic label-container`).attr(`style`,i).attr(`d`,b);return c.attr(`transform`,`translate(${-o.width/2}, ${-o.height/2})`),y.attr(`transform`,`translate(${-l/2}, ${-u/2})`),I(n,y),n.calcIntersect=function(e,t){return K.rect(e,t)},n.intersect=function(t){return e.info(`Cloud intersect`,n,t),K.rect(n,t)},a}n(tr,`cloud`);async function nr(e,t){let{labelStyles:n,nodeStyles:r}=_(t);t.labelStyle=n;let{shapeSvg:i,bbox:a,halfPadding:o,label:s}=await P(e,t,L(t)),c=a.width+8*o,l=a.height+2*o,u=t.look===`neo`?` + M${-c/2} ${l/2-5} + v${-l+10} + q0,-5 5,-5 + h${c-10} + q5,0 5,5 + v${l-5} + H${-c/2} + Z + `:` + M${-c/2} ${l/2-5} + v${-l+10} + q0,-5 5,-5 + h${c-10} + q5,0 5,5 + v${l-10} + q0,5 -5,5 + h${-(c-10)} + q-5,0 -5,-5 + Z + `;if(!t.domId)throw Error(`defaultMindmapNode: node "${t.id}" is missing a domId \u2014 was render.ts domId prefixing skipped?`);let d=i.append(`path`).attr(`id`,t.domId).attr(`class`,`node-bkg node-`+t.type).attr(`style`,r).attr(`d`,u);return i.append(`line`).attr(`class`,`node-line-`).attr(`x1`,-c/2).attr(`y1`,l/2).attr(`x2`,c/2).attr(`y2`,l/2),s.attr(`transform`,`translate(${-a.width/2}, ${-a.height/2})`),i.append(()=>s.node()),I(t,d),t.calcIntersect=function(e,t){return K.rect(e,t)},t.intersect=function(e){return K.rect(t,e)},i}n(nr,`defaultMindmapNode`);async function rr(e,t){return Ae(e,t,{padding:t.padding??0})}n(rr,`mindmapCircle`);var ir=[{semanticName:`Process`,name:`Rectangle`,shortName:`rect`,description:`Standard process shape`,aliases:[`proc`,`process`,`rectangle`],internalAliases:[`squareRect`],handler:gn},{semanticName:`Event`,name:`Rounded Rectangle`,shortName:`rounded`,description:`Represents an event`,aliases:[`event`],internalAliases:[`roundedRect`],handler:fn},{semanticName:`Terminal Point`,name:`Stadium`,shortName:`stadium`,description:`Terminal point`,aliases:[`terminal`,`pill`],handler:yn},{semanticName:`Subprocess`,name:`Framed Rectangle`,shortName:`fr-rect`,description:`Subprocess`,aliases:[`subprocess`,`subproc`,`framed-rectangle`,`subroutine`],handler:wn},{semanticName:`Database`,name:`Cylinder`,shortName:`cyl`,description:`Database storage`,aliases:[`db`,`database`,`cylinder`],handler:Ge},{semanticName:`Data Store`,name:`Data Store`,shortName:`datastore`,description:`Data flow diagram data store`,aliases:[`data-store`],handler:qe},{semanticName:`Folder`,name:`Folder`,shortName:`folder`,description:`Folder or directory`,aliases:[`directory`],handler:tt},{semanticName:`Bucket`,name:`Bucket`,shortName:`bucket`,description:`Object storage bucket`,handler:fe},{semanticName:`Console`,name:`Console (terminal window)`,shortName:`console`,description:`Terminal or console window`,handler:Me},{semanticName:`Browser`,name:`Browser`,shortName:`browser`,description:`Browser window`,handler:Ee},{semanticName:`Person`,name:`Person`,shortName:`person`,description:`Person (circular head above a rounded body)`,handler:ze},{semanticName:`Start`,name:`Circle`,shortName:`circle`,description:`Starting point`,aliases:[`circ`],handler:Ae},{semanticName:`Bang`,name:`Bang`,shortName:`bang`,description:`Bang`,aliases:[`bang`],handler:er},{semanticName:`Cloud`,name:`Cloud`,shortName:`cloud`,description:`cloud`,aliases:[`cloud`],handler:tr},{semanticName:`Decision`,name:`Diamond`,shortName:`diam`,description:`Decision-making step`,aliases:[`decision`,`diamond`,`question`],handler:ln},{semanticName:`Prepare Conditional`,name:`Hexagon`,shortName:`hex`,description:`Preparation or condition step`,aliases:[`hexagon`,`prepare`],handler:at},{semanticName:`Data Input/Output`,name:`Lean Right`,shortName:`lean-r`,description:`Represents input or output`,aliases:[`lean-right`,`in-out`],internalAliases:[`lean_right`],handler:ht},{semanticName:`Data Input/Output`,name:`Lean Left`,shortName:`lean-l`,description:`Represents output or input`,aliases:[`lean-left`,`out-in`],internalAliases:[`lean_left`],handler:mt},{semanticName:`Priority Action`,name:`Trapezoid Base Bottom`,shortName:`trap-b`,description:`Priority action`,aliases:[`priority`,`trapezoid-bottom`,`trapezoid`],handler:Fn},{semanticName:`Manual Operation`,name:`Trapezoid Base Top`,shortName:`trap-t`,description:`Represents a manual task`,aliases:[`manual`,`trapezoid-top`,`inv-trapezoid`],internalAliases:[`inv_trapezoid`],handler:ft},{semanticName:`Stop`,name:`Double Circle`,shortName:`dbl-circ`,description:`Represents a stop point`,aliases:[`double-circle`],internalAliases:[`doublecircle`],handler:Ye},{semanticName:`Text Block`,name:`Text Block`,shortName:`text`,description:`Text block`,handler:On},{semanticName:`Card`,name:`Notched Rectangle`,shortName:`notch-rect`,description:`Represents a card`,aliases:[`card`,`notched-rectangle`],handler:Oe},{semanticName:`Lined/Shaded Process`,name:`Lined Rectangle`,shortName:`lin-rect`,description:`Lined process shape`,aliases:[`lined-rectangle`,`lined-process`,`lin-proc`,`shaded-process`],handler:mn},{semanticName:`Start`,name:`Small Circle`,shortName:`sm-circ`,description:`Small starting point`,aliases:[`start`,`small-circle`],internalAliases:[`stateStart`],handler:Sn},{semanticName:`Stop`,name:`Framed Circle`,shortName:`fr-circ`,description:`Stop point`,aliases:[`stop`,`framed-circle`],internalAliases:[`stateEnd`],handler:xn},{semanticName:`Fork/Join`,name:`Filled Rectangle`,shortName:`fork`,description:`Fork or join in process flow`,aliases:[`join`],internalAliases:[`forkJoin`],handler:nt},{semanticName:`Collate`,name:`Hourglass`,shortName:`hourglass`,description:`Represents a collate operation`,aliases:[`hourglass`,`collate`],handler:ot},{semanticName:`Comment`,name:`Curly Brace`,shortName:`brace`,description:`Adds a comment`,aliases:[`comment`,`brace-l`],handler:Fe},{semanticName:`Comment Right`,name:`Curly Brace`,shortName:`brace-r`,description:`Adds a comment`,handler:Ie},{semanticName:`Comment with braces on both sides`,name:`Curly Braces`,shortName:`braces`,description:`Adds a comment`,handler:Le},{semanticName:`Com Link`,name:`Lightning Bolt`,shortName:`bolt`,description:`Communication link`,aliases:[`com-link`,`lightning-bolt`],handler:gt},{semanticName:`Document`,name:`Document`,shortName:`doc`,description:`Represents a document`,aliases:[`doc`,`document`],handler:Bn},{semanticName:`Delay`,name:`Half-Rounded Rectangle`,shortName:`delay`,description:`Represents a delay`,aliases:[`half-rounded-rectangle`],handler:rt},{semanticName:`Direct Access Storage`,name:`Horizontal Cylinder`,shortName:`h-cyl`,description:`Direct access storage`,aliases:[`das`,`horizontal-cylinder`],handler:Pn},{semanticName:`Disk Storage`,name:`Lined Cylinder`,shortName:`lin-cyl`,description:`Disk storage`,aliases:[`disk`,`lined-cylinder`],handler:St},{semanticName:`Display`,name:`Curved Trapezoid`,shortName:`curv-trap`,description:`Represents a display`,aliases:[`curved-trapezoid`,`display`],handler:Re},{semanticName:`Divided Process`,name:`Divided Rectangle`,shortName:`div-rect`,description:`Divided process shape`,aliases:[`div-proc`,`divided-rectangle`,`divided-process`],handler:Je},{semanticName:`Extract`,name:`Triangle`,shortName:`tri`,description:`Extraction process`,aliases:[`extract`,`triangle`],handler:zn},{semanticName:`Internal Storage`,name:`Window Pane`,shortName:`win-pane`,description:`Internal storage`,aliases:[`internal-storage`,`window-pane`],handler:Hn},{semanticName:`Junction`,name:`Filled Circle`,shortName:`f-circ`,description:`Junction point`,aliases:[`junction`,`filled-circle`],handler:Ze},{semanticName:`Loop Limit`,name:`Trapezoidal Pentagon`,shortName:`notch-pent`,description:`Loop limit step`,aliases:[`loop-limit`,`notched-pentagon`],handler:In},{semanticName:`Manual File`,name:`Flipped Triangle`,shortName:`flip-tri`,description:`Manual file operation`,aliases:[`manual-file`,`flipped-triangle`],handler:et},{semanticName:`Manual Input`,name:`Sloped Rectangle`,shortName:`sl-rect`,description:`Manual input step`,aliases:[`manual-input`,`sloped-rectangle`],handler:hn},{semanticName:`Multi-Document`,name:`Stacked Document`,shortName:`docs`,description:`Multiple documents`,aliases:[`documents`,`st-doc`,`stacked-document`],handler:on},{semanticName:`Multi-Process`,name:`Stacked Rectangle`,shortName:`st-rect`,description:`Multiple processes`,aliases:[`procs`,`processes`,`stacked-rectangle`],handler:an},{semanticName:`Stored Data`,name:`Bow Tie Rectangle`,shortName:`bow-rect`,description:`Stored data`,aliases:[`stored-data`,`bow-tie-rectangle`],handler:de},{semanticName:`Summary`,name:`Crossed Circle`,shortName:`cross-circ`,description:`Summary`,aliases:[`summary`,`crossed-circle`],handler:Pe},{semanticName:`Tagged Document`,name:`Tagged Document`,shortName:`tag-doc`,description:`Tagged document`,aliases:[`tag-doc`,`tagged-document`],handler:Dn},{semanticName:`Tagged Process`,name:`Tagged Rectangle`,shortName:`tag-rect`,description:`Tagged process`,aliases:[`tagged-rectangle`,`tag-proc`,`tagged-process`],handler:En},{semanticName:`Paper Tape`,name:`Flag`,shortName:`flag`,description:`Paper tape`,aliases:[`paper-tape`],handler:Vn},{semanticName:`Odd`,name:`Odd`,shortName:`odd`,description:`Odd shape`,internalAliases:[`rect_left_inv_arrow`],handler:un},{semanticName:`Lined Document`,name:`Lined Document`,shortName:`lin-doc`,description:`Lined document`,aliases:[`lined-document`],handler:Ct}],ar=n(()=>{let e=[...Object.entries({state:bn,choice:ke,note:sn,composite:je,rectWithTitle:dn,labelRect:pt,block_arrow:Te,collapsedGroup:ve,iconSquare:ut,iconCircle:ct,icon:st,iconRounded:lt,imageSquare:dt,anchor:ce,kanbanItem:$n,mindmapCircle:rr,defaultMindmapNode:nr,classBox:Xn,erBox:Gn,requirementBox:Zn,usecaseActor:Bt,usecaseActorHollow:Wt,usecaseActorAwesome:Ht,usecaseActorIcon:Yt,usecaseBusiness:Zt,usecaseEllipse:Xe,usecaseJsonTable:rn}),...ir.flatMap(e=>[e.shortName,...`aliases`in e?e.aliases:[],...`internalAliases`in e?e.internalAliases:[]].map(t=>[t,e.handler]))];return Object.fromEntries(e)},`generateShapeMap`)();function or(e){return e in ar}n(or,`isValidShape`);export{or as a,I as c,V as i,q as n,P as o,K as r,ar as s,se as t}; \ No newline at end of file diff --git a/www/assets/chunk-7M6MHVWA-ZnPgs1Wx.js b/www/assets/chunk-7M6MHVWA-ZnPgs1Wx.js new file mode 100644 index 0000000..d5b5886 --- /dev/null +++ b/www/assets/chunk-7M6MHVWA-ZnPgs1Wx.js @@ -0,0 +1,213 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as r,H as i,U as a,a as o,d as s,ot as c,q as l,s as u,tt as d,v as f,w as p,x as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as g}from"./channel-_oCHZhRo.js";import{c as _,g as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as ee,n as te,o as ne,r as y}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{a as b}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{_ as x,n as S,t as C,v as w}from"./index-DoQkmpth.js";import{t as T}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as E}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as D}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as O}from"./chunk-WEXAMYUT-I3m-hOmT.js";var re=`flowchart-`,ie=class{constructor(){this.vertexCounter=0,this.config=m(),this.diagramId=``,this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=a,this.setAccDescription=i,this.setDiagramTitle=l,this.getAccTitle=h,this.getAccDescription=f,this.getDiagramTitle=p,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen(`gen-2`)}static{n(this,`FlowDB`)}sanitizeText(e){return u.sanitizeText(e,this.config)}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}setDiagramId(e){this.diagramId=e}lookUpDomId(e){for(let t of this.vertices.values())if(t.id===e)return this.diagramId?`${this.diagramId}-${t.domId}`:t.domId;return this.diagramId?`${this.diagramId}-${e}`:e}addVertex(t,n,r,i,a,o,s={},c){if(!t||t.trim().length===0)return;let l;if(c!==void 0){let e;e=c.includes(` +`)?c+` +`:`{ +`+c+` +}`,l=w(e,{schema:x})}let u=this.subGraphLookup.get(t);if(u&&l){u.metadata={...u.metadata,...l};return}let d=this.edges.find(e=>e.id===t);if(d){let e=l;e?.animate!==void 0&&(d.animate=e.animate),e?.animation!==void 0&&(d.animation=e.animation),e?.curve!==void 0&&(d.interpolate=e.curve);return}let f,p=this.vertices.get(t);if(p===void 0&&(n===void 0&&r===void 0&&i!=null&&e.warn(`Style applied to unknown node "${t}". This may indicate a typo. The node will be created automatically.`),p={id:t,labelType:`text`,domId:re+t+`-`+this.vertexCounter,styles:[],classes:[]},this.vertices.set(t,p)),this.vertexCounter++,n===void 0?p.text===void 0&&(p.text=t):(this.config=m(),f=this.sanitizeText(n.text.trim()),p.labelType=n.type,f.startsWith(`"`)&&f.endsWith(`"`)&&(f=f.substring(1,f.length-1)),p.text=f),r!==void 0&&(p.type=r),i?.forEach(e=>{p.styles.push(e)}),a?.forEach(e=>{p.classes.push(e)}),o!==void 0&&(p.dir=o),p.props===void 0?p.props=s:s!==void 0&&Object.assign(p.props,s),l!==void 0){if(l.shape){if(l.shape!==l.shape.toLowerCase()||l.shape.includes(`_`))throw Error(`No such shape: ${l.shape}. Shape names should be lowercase.`);if(!b(l.shape))throw Error(`No such shape: ${l.shape}.`);p.type=l?.shape}l?.label&&(p.text=l?.label,p.labelType=this.sanitizeNodeLabelType(l?.labelType)),l?.icon&&(p.icon=l?.icon,!l.label?.trim()&&p.text===t&&(p.text=``)),l?.form&&(p.form=l?.form),l?.pos&&(p.pos=l?.pos),l?.img&&(p.img=l?.img,!l.label?.trim()&&p.text===t&&(p.text=``)),l?.constraint&&(p.constraint=l.constraint),l.w&&(p.assetWidth=Number(l.w)),l.h&&(p.assetHeight=Number(l.h))}}addSingleLink(t,n,r,i){let a={start:t,end:n,type:void 0,text:``,labelType:`text`,classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};e.info(`abc78 Got edge...`,a);let o=r.text;if(o!==void 0&&(a.text=this.sanitizeText(o.text.trim()),a.text.startsWith(`"`)&&a.text.endsWith(`"`)&&(a.text=a.text.substring(1,a.text.length-1)),a.labelType=this.sanitizeNodeLabelType(o.type)),r!==void 0&&(a.type=r.type,a.stroke=r.stroke,a.length=r.length>10?10:r.length),i&&!this.edges.some(e=>e.id===i))a.id=i,a.isUserDefinedId=!0;else{let e=this.edges.filter(e=>e.start===a.start&&e.end===a.end);a.id=e.length===0?_(a.start,a.end,{counter:0,prefix:`L`}):_(a.start,a.end,{counter:e.length+1,prefix:`L`})}if(this.edges.length<(this.config.maxEdges??500))e.info(`Pushing edge...`),this.edges.push(a);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}. + +Initialize mermaid with maxEdges set to a higher number to allow more edges. +You cannot set this config via configuration inside the diagram as it is a secure config. +You have to call mermaid.initialize.`)}isLinkData(e){return typeof e==`object`&&!!e&&`id`in e&&typeof e.id==`string`}addLink(t,n,r){let i=this.isLinkData(r)?r.id.replace(`@`,``):void 0;e.info(`addLink`,t,n,i);for(let e of t)for(let a of n){let o=e===t[t.length-1],s=a===n[0];o&&s?this.addSingleLink(e,a,r,i):this.addSingleLink(e,a,r,void 0)}}updateLinkInterpolate(e,t){e.forEach(e=>{e==="default"?this.edges.defaultInterpolate=t:this.edges[e].interpolate=t})}updateLink(e,t){e.forEach(e=>{if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);e==="default"?this.edges.defaultStyle=t:(this.edges[e].style=t,(this.edges[e]?.style?.length??0)>0&&!this.edges[e]?.style?.some(e=>e?.startsWith(`fill`))&&this.edges[e]?.style?.push(`fill:none`))})}addClass(e,t){let n=t.join().replace(/\\,/g,`§§§`).replace(/,/g,`;`).replace(/§§§/g,`,`).split(`;`);e.split(`,`).forEach(e=>{let t=this.classes.get(e);t===void 0&&(t={id:e,styles:[],textStyles:[]},this.classes.set(e,t)),n?.forEach(e=>{if(/color/.exec(e)){let n=e.replace(`fill`,`bgFill`);t.textStyles.push(n)}t.styles.push(e)})})}setDirection(e){this.direction=e.trim(),/.*/.exec(this.direction)&&(this.direction=`LR`),/.*v/.exec(this.direction)&&(this.direction=`TB`),this.direction===`TD`&&(this.direction=`TB`)}setClass(e,t){for(let n of e.split(`,`)){let e=this.vertices.get(n);e&&e.classes.push(t);let r=this.edges.find(e=>e.id===n);r&&r.classes.push(t);let i=this.subGraphLookup.get(n);i&&i.classes.push(t)}}setTooltip(e,t){if(t!==void 0){t=this.sanitizeText(t);for(let n of e.split(`,`))this.tooltips.set(this.version===`gen-1`?this.lookUpDomId(n):n,t)}}setClickFun(e,t,n){if(m().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{let n=this.lookUpDomId(e),i=document.querySelector(`[id="${n}"]`);i!==null&&i.addEventListener(`click`,()=>{v.runFunc(t,...r)},!1)}))}setLink(e,t,n){e.split(`,`).forEach(e=>{let r=this.vertices.get(e);r!==void 0&&(r.link=v.formatUrl(t,this.config),r.linkTarget=n)}),this.setClass(e,`clickable`)}getTooltip(e){return this.tooltips.get(e)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFun(e,t,n)}),this.setClass(e,`clickable`)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}getClasses(){return this.classes}setupToolTips(e){let n=E();t(e).select(`svg`).selectAll(`g.node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.text(r.attr(`title`)).style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(d.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}clear(e=`gen-2`){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.diagramId=``,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=e,this.config=m(),o()}setGen(e){this.version=e||`gen-2`}defaultStyle(){return`fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;`}addSubGraph(t,r,i){let a=t.text.trim(),o=i.text;t===i&&/\s/.exec(i.text)&&(a=void 0);let s=n(e=>{let t={boolean:{},number:{},string:{}},n=[],r;return{nodeList:e.filter(function(e){let i=typeof e;return e.stmt&&e.stmt===`dir`?(r=e.value,!1):e.trim()===``?!1:i in t?t[i].hasOwnProperty(e)?!1:t[i][e]=!0:!n.includes(e)&&n.push(e)}),dir:r}},`uniq`)(r.flat()),c=s.nodeList,l=s.dir,u=m().flowchart??{};if(l??=u.inheritDir?this.getDirection()??m().direction??void 0:void 0,this.version===`gen-1`)for(let e=0;e2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=t,this.subGraphs[t].id===e)return{result:!0,count:0};let r=0,i=1;for(;r=0){let n=this.indexNodes2(e,t);if(n.result)return{result:!0,count:i+n.count};i+=n.count}r+=1}return{result:!1,count:i}}getDepthFirstPos(e){return this.posCrossRef[e]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2(`none`,this.subGraphs.length-1)}getSubGraphs(){return this.subGraphs}firstGraph(){return this.firstGraphFlag?(this.firstGraphFlag=!1,!0):!1}destructStartLink(e){let t=e.trim(),n=`arrow_open`;switch(t[0]){case`<`:n=`arrow_point`,t=t.slice(1);break;case`x`:n=`arrow_cross`,t=t.slice(1);break;case`o`:n=`arrow_circle`,t=t.slice(1)}let r=`normal`;return t.includes(`=`)&&(r=`thick`),t.includes(`.`)&&(r=`dotted`),{type:n,stroke:r}}countChar(e,t){let n=t.length,r=0;for(let i=0;i`:r=`arrow_point`,t.startsWith(`<`)&&(r=`double_`+r,n=n.slice(1));break;case`o`:r=`arrow_circle`,t.startsWith(`o`)&&(r=`double_`+r,n=n.slice(1))}let i=`normal`,a=n.length-1;n.startsWith(`=`)&&(i=`thick`),n.startsWith(`~`)&&(i=`invisible`);let o=this.countChar(`.`,n);return o&&(i=`dotted`,a=o),{type:r,stroke:i,length:a}}destructLink(e,t){let n=this.destructEndLink(e),r;if(t){if(r=this.destructStartLink(t),r.stroke!==n.stroke)return{type:`INVALID`,stroke:`INVALID`};if(r.type===`arrow_open`)r.type=n.type;else{if(r.type!==n.type)return{type:`INVALID`,stroke:`INVALID`};r.type=`double_`+r.type}return r.type===`double_arrow`&&(r.type=`double_arrow_point`),r.length=n.length,r}return n}exists(e,t){for(let n of e)if(n.nodes.includes(t))return!0;return!1}makeUniq(e,t){let n=[];return e.nodes.forEach((r,i)=>{this.exists(t,r)||n.push(e.nodes[i])}),{nodes:n}}getTypeFromVertex(e){if(e.img)return`imageSquare`;if(e.icon)return e.form===`circle`?`iconCircle`:e.form===`square`?`iconSquare`:e.form===`rounded`?`iconRounded`:`icon`;switch(e.type){case`square`:case void 0:return`squareRect`;case`round`:return`roundedRect`;case`ellipse`:return`ellipse`;default:return e.type}}findNode(e,t){return e.find(e=>e.id===t)}destructEdgeType(e){let t=`none`,n=`arrow_point`;switch(e){case`arrow_point`:case`arrow_circle`:case`arrow_cross`:n=e;break;case`double_arrow_point`:case`double_arrow_circle`:case`double_arrow_cross`:t=e.replace(`double_`,``),n=t}return{arrowTypeStart:t,arrowTypeEnd:n}}addNodeFromVertex(e,t,n,r,i,a){let o=n.get(e.id),s=r.get(e.id)??!1,c=this.findNode(t,e.id);if(c)c.cssStyles=e.styles,c.cssCompiledStyles=this.getCompiledStyles(e.classes),c.cssClasses=e.classes.join(` `);else{let n={id:e.id,label:e.text,labelType:e.labelType,labelStyle:``,parentId:o,padding:i.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:this.getCompiledStyles([`default`,`node`,...e.classes]),cssClasses:`default `+e.classes.join(` `),dir:e.dir,domId:e.domId,look:a,link:e.link,linkTarget:e.linkTarget,tooltip:this.getTooltip(e.id),icon:e.icon,pos:e.pos,img:e.img,assetWidth:e.assetWidth,assetHeight:e.assetHeight,constraint:e.constraint};s?t.push({...n,isGroup:!0,shape:`rect`}):t.push({...n,isGroup:!1,shape:this.getTypeFromVertex(e),minWidth:i.flowchart?.minNodeWidth})}}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}getData(){let e=m(),t=[],r=[],i=this.getSubGraphs(),a=new Map,o=new Map,s=new Map;for(let e of i)for(let t of e.nodes)this.subGraphLookup.has(t)&&s.set(t,e.id);let c=new Map,l=new Map;for(let e of i){let t=s.get(e.id);t!==void 0&&l.set(t,[...l.get(t)??[],e.id])}let u=0,d=n(e=>{c.set(e,u++);for(let t of l.get(e)??[])d(t)},`walk`);for(let e of i)s.has(e.id)||d(e.id);let f=n(e=>this.subGraphLookup.get(e)?.metadata?.view===`collapsed`,`isCollapsed`),p=n(e=>{let t,n=new Set,r=e;for(;r!==void 0&&!n.has(r);)n.add(r),f(r)&&(t=r),r=s.get(r);return t},`outermostCollapsed`),h=new Set,g=new Map;for(let e of i){let t=p(e.id);if(t!==void 0){e.id!==t&&(h.add(e.id),g.set(e.id,t));for(let n of e.nodes)n!==t&&(h.add(n),g.set(n,t))}}for(let e=i.length-1;e>=0;e--){let t=i[e];if(!h.has(t.id)){t.nodes.length>0&&o.set(t.id,!0);for(let e of t.nodes)a.set(e,t.id)}}for(let n=i.length-1;n>=0;n--){let r=i[n];h.has(r.id)||(r.metadata?.view===`collapsed`?t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`collapsedGroup`,dir:r.dir,isGroup:!1,look:e.look,colorIndex:c.get(r.id)}):t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`rect`,dir:r.dir,isGroup:!0,look:e.look,colorIndex:c.get(r.id),metadata:r.metadata}))}this.getVertices().forEach(n=>{h.has(n.id)||this.addNodeFromVertex(n,t,a,o,e,e.look||`classic`)});let v=this.getEdges();return v.forEach((t,n)=>{let{arrowTypeStart:i,arrowTypeEnd:a}=this.destructEdgeType(t.type),o=[...v.defaultStyle??[]],s=g.get(t.start)??t.start,c=g.get(t.end)??t.end;if(s===c&&(g.has(t.start)||g.has(t.end)))return;t.style&&o.push(...t.style);let l={id:_(s,c,{counter:n,prefix:`L`},t.id),isUserDefinedId:t.isUserDefinedId,start:s,end:c,type:t.type??`normal`,label:t.text,labelType:t.labelType,labelpos:`c`,thickness:t.stroke,minlen:t.length,classes:t?.stroke===`invisible`?``:`edge-thickness-normal edge-pattern-solid flowchart-link`,arrowTypeStart:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:i,arrowTypeEnd:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:a,arrowheadStyle:`fill: #333`,cssCompiledStyles:this.getCompiledStyles(t.classes),labelStyle:o,style:o,pattern:t.stroke,look:e.look,animate:t.animate,animation:t.animation,curve:t.interpolate||this.edges.defaultInterpolate||e.flowchart?.curve};r.push(l)}),{nodes:t,edges:r,other:{},config:e}}defaultConfig(){return s.flowchart}},ae={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing state diagram (v2)`,n);let{securityLevel:a,flowchart:o,layout:s}=m();i.db.setDiagramId(n),e.debug(`Before getData: `);let c=i.db.getData();e.debug(`Data: `,c);let l=D(n,a),u=i.db.getDirection();c.type=i.type,c.layoutAlgorithm=C(s),c.direction=u,c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=[`point`,`circle`,`cross`],c.diagramId=n,e.debug(`REF1:`,c),await S(c,l);let d=c.config.flowchart?.diagramPadding??8;v.insertTitle(l,`flowchartTitleText`,o?.titleTopMargin||0,i.db.getDiagramTitle()),O(l,d,`flowchart`,o?.useMaxWidth||!1)},`draw`)},oe=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,4],r=[1,3],i=[1,5],a=[1,8,9,10,11,27,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],o=[2,2],s=[1,13],c=[1,14],l=[1,15],u=[1,16],d=[1,23],f=[1,25],p=[1,26],m=[1,27],h=[1,50],g=[1,49],_=[1,29],v=[1,30],ee=[1,31],te=[1,32],ne=[1,33],y=[1,45],b=[1,47],x=[1,43],S=[1,48],C=[1,44],w=[1,51],T=[1,46],E=[1,52],D=[1,53],O=[1,34],re=[1,35],ie=[1,36],ae=[1,37],oe=[1,38],k=[1,58],A=[1,8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],j=[1,62],M=[1,61],N=[1,63],se=[8,9,11,75,77,78],ce=[1,79],le=[1,92],ue=[1,97],de=[1,96],fe=[1,93],pe=[1,89],me=[1,95],he=[1,91],ge=[1,98],_e=[1,94],ve=[1,99],ye=[1,90],be=[8,9,10,11,40,75,77,78],P=[8,9,10,11,40,46,75,77,78],F=[8,9,10,11,29,40,44,46,48,50,52,54,56,58,60,63,65,67,68,70,75,77,78,89,102,105,106,109,111,114,115,116],xe=[8,9,11,44,60,75,77,78,89,102,105,106,109,111,114,115,116],Se=[44,60,89,102,105,106,109,111,114,115,116],Ce=[1,122],we=[1,123],Te=[1,125],Ee=[1,124],De=[44,60,62,74,89,102,105,106,109,111,114,115,116],Oe=[1,134],ke=[1,148],Ae=[1,149],je=[1,150],Me=[1,151],Ne=[1,136],Pe=[1,138],Fe=[1,142],Ie=[1,143],Le=[1,144],Re=[1,145],ze=[1,146],Be=[1,147],Ve=[1,152],He=[1,153],Ue=[1,132],We=[1,133],Ge=[1,140],Ke=[1,135],qe=[1,139],Je=[1,137],Ye=[8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],Xe=[1,155],Ze=[1,157],I=[8,9,11],L=[8,9,10,11,14,44,60,89,105,106,109,111,114,115,116],R=[1,177],z=[1,173],B=[1,174],V=[1,178],H=[1,175],U=[1,176],Qe=[77,116,119],W=[8,9,10,11,12,14,27,29,32,44,60,75,84,85,86,87,88,89,90,105,109,111,114,115,116],$e=[10,106],et=[31,49,51,53,55,57,62,64,66,67,69,71,116,117,118],G=[1,248],K=[1,246],q=[1,250],J=[1,244],Y=[1,245],X=[1,247],Z=[1,249],Q=[1,251],tt=[1,269],nt=[8,9,11,106],$=[8,9,10,11,60,84,105,106,109,110,111,112],rt={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeparator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,vertexStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,shapeData:39,SHAPE_DATA:40,link:41,node:42,styledVertex:43,AMP:44,vertex:45,STYLE_SEPARATOR:46,idString:47,DOUBLECIRCLESTART:48,DOUBLECIRCLEEND:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,VERTEX_WITH_PROPS_START:58,"NODE_STRING[field]":59,COLON:60,"NODE_STRING[value]":61,PIPE:62,CYLINDERSTART:63,CYLINDEREND:64,DIAMOND_START:65,DIAMOND_STOP:66,TAGEND:67,TRAPSTART:68,TRAPEND:69,INVTRAPSTART:70,INVTRAPEND:71,linkStatement:72,arrowText:73,TESTSTR:74,START_LINK:75,edgeText:76,LINK:77,LINK_ID:78,edgeTextToken:79,STR:80,MD_STR:81,textToken:82,keywords:83,STYLE:84,LINKSTYLE:85,CLASSDEF:86,CLASS:87,CLICK:88,DOWN:89,UP:90,textNoTagsToken:91,stylesOpt:92,"idString[vertex]":93,"idString[class]":94,CALLBACKNAME:95,CALLBACKARGS:96,HREF:97,LINK_TARGET:98,"STR[link]":99,"STR[tooltip]":100,alphaNum:101,DEFAULT:102,numList:103,INTERPOLATE:104,NUM:105,COMMA:106,style:107,styleComponent:108,NODE_STRING:109,UNIT:110,BRKT:111,PCT:112,idStringToken:113,MINUS:114,MULT:115,UNICODE_TEXT:116,TEXT:117,TAGSTART:118,EDGE_TEXT:119,alphaNumToken:120,direction_tb:121,direction_bt:122,direction_rl:123,direction_lr:124,direction_td:125,$accept:0,$end:1},terminals_:{2:`error`,8:`SEMI`,9:`NEWLINE`,10:`SPACE`,11:`EOF`,12:`GRAPH`,13:`NODIR`,14:`DIR`,27:`subgraph`,29:`SQS`,31:`SQE`,32:`end`,34:`acc_title`,35:`acc_title_value`,36:`acc_descr`,37:`acc_descr_value`,38:`acc_descr_multiline_value`,40:`SHAPE_DATA`,44:`AMP`,46:`STYLE_SEPARATOR`,48:`DOUBLECIRCLESTART`,49:`DOUBLECIRCLEEND`,50:`PS`,51:`PE`,52:`(-`,53:`-)`,54:`STADIUMSTART`,55:`STADIUMEND`,56:`SUBROUTINESTART`,57:`SUBROUTINEEND`,58:`VERTEX_WITH_PROPS_START`,59:`NODE_STRING[field]`,60:`COLON`,61:`NODE_STRING[value]`,62:`PIPE`,63:`CYLINDERSTART`,64:`CYLINDEREND`,65:`DIAMOND_START`,66:`DIAMOND_STOP`,67:`TAGEND`,68:`TRAPSTART`,69:`TRAPEND`,70:`INVTRAPSTART`,71:`INVTRAPEND`,74:`TESTSTR`,75:`START_LINK`,77:`LINK`,78:`LINK_ID`,80:`STR`,81:`MD_STR`,84:`STYLE`,85:`LINKSTYLE`,86:`CLASSDEF`,87:`CLASS`,88:`CLICK`,89:`DOWN`,90:`UP`,93:`idString[vertex]`,94:`idString[class]`,95:`CALLBACKNAME`,96:`CALLBACKARGS`,97:`HREF`,98:`LINK_TARGET`,99:`STR[link]`,100:`STR[tooltip]`,102:`DEFAULT`,104:`INTERPOLATE`,105:`NUM`,106:`COMMA`,109:`NODE_STRING`,110:`UNIT`,111:`BRKT`,112:`PCT`,114:`MINUS`,115:`MULT`,116:`UNICODE_TEXT`,117:`TEXT`,118:`TAGSTART`,119:`EDGE_TEXT`,121:`direction_tb`,122:`direction_bt`,123:`direction_rl`,124:`direction_lr`,125:`direction_td`},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[39,2],[39,1],[20,4],[20,3],[20,4],[20,2],[20,2],[20,1],[42,1],[42,6],[42,5],[43,1],[43,3],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,8],[45,4],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,4],[45,4],[45,1],[41,2],[41,3],[41,3],[41,1],[41,3],[41,4],[76,1],[76,2],[76,1],[76,1],[72,1],[72,2],[73,3],[30,1],[30,2],[30,1],[30,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[103,1],[103,3],[92,1],[92,3],[107,1],[107,2],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[82,1],[82,1],[82,1],[82,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[79,1],[79,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[47,1],[47,2],[101,1],[101,2],[33,1],[33,1],[33,1],[33,1],[33,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:(!Array.isArray(a[s])||a[s].length>0)&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 183:this.$=a[s];break;case 11:r.setDirection(`TB`),this.$=`TB`;break;case 12:r.setDirection(a[s-1]),this.$=a[s-1];break;case 27:this.$=a[s-1].nodes;break;case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 33:this.$=r.addSubGraph(a[s-6],a[s-1],a[s-4]);break;case 34:this.$=r.addSubGraph(a[s-3],a[s-1],a[s-3]);break;case 35:this.$=r.addSubGraph(void 0,a[s-1],void 0);break;case 37:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 38:case 39:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 43:this.$=a[s-1]+a[s];break;case 44:this.$=a[s];break;case 45:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s]),r.addLink(a[s-3].stmt,a[s-1],a[s-2]),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 46:r.addLink(a[s-2].stmt,a[s],a[s-1]),this.$={stmt:a[s],nodes:a[s].concat(a[s-2].nodes)};break;case 47:r.addLink(a[s-3].stmt,a[s-1],a[s-2]),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 48:this.$={stmt:a[s-1],nodes:a[s-1]};break;case 49:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s]),this.$={stmt:a[s-1],nodes:a[s-1],shapeData:a[s]};break;case 50:this.$={stmt:a[s],nodes:a[s]};break;case 51:this.$=[a[s]];break;case 52:r.addVertex(a[s-5][a[s-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s-4]),this.$=a[s-5].concat(a[s]);break;case 53:this.$=a[s-4].concat(a[s]);break;case 54:this.$=a[s];break;case 55:this.$=a[s-2],r.setClass(a[s-2],a[s]);break;case 56:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`square`);break;case 57:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`doublecircle`);break;case 58:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`circle`);break;case 59:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`ellipse`);break;case 60:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`stadium`);break;case 61:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`subroutine`);break;case 62:this.$=a[s-7],r.addVertex(a[s-7],a[s-1],`rect`,void 0,void 0,void 0,Object.fromEntries([[a[s-5],a[s-3]]]));break;case 63:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`cylinder`);break;case 64:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`round`);break;case 65:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`diamond`);break;case 66:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`hexagon`);break;case 67:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`odd`);break;case 68:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`trapezoid`);break;case 69:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`inv_trapezoid`);break;case 70:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_right`);break;case 71:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_left`);break;case 72:this.$=a[s],r.addVertex(a[s]);break;case 73:a[s-1].text=a[s],this.$=a[s-1];break;case 74:case 75:a[s-2].text=a[s-1],this.$=a[s-2];break;case 76:this.$=a[s];break;case 77:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,text:a[s-1]};break;case 78:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,text:a[s-1],id:a[s-3]};break;case 79:this.$={text:a[s],type:`text`};break;case 80:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 81:this.$={text:a[s],type:`string`};break;case 82:this.$={text:a[s],type:`markdown`};break;case 83:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length};break;case 84:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,id:a[s-1]};break;case 85:this.$=a[s-1];break;case 86:this.$={text:a[s],type:`text`};break;case 87:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 88:this.$={text:a[s],type:`string`};break;case 89:case 104:this.$={text:a[s],type:`markdown`};break;case 101:this.$={text:a[s],type:`text`};break;case 102:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 103:this.$={text:a[s],type:`text`};break;case 105:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 106:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 107:case 115:this.$=a[s-1],r.setClickEvent(a[s-1],a[s]);break;case 108:case 116:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 109:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 110:this.$=a[s-4],r.setClickEvent(a[s-4],a[s-3],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 111:this.$=a[s-2],r.setLink(a[s-2],a[s]);break;case 112:this.$=a[s-4],r.setLink(a[s-4],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 113:this.$=a[s-4],r.setLink(a[s-4],a[s-2],a[s]);break;case 114:this.$=a[s-6],r.setLink(a[s-6],a[s-4],a[s]),r.setTooltip(a[s-6],a[s-2]);break;case 117:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 118:this.$=a[s-3],r.setLink(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 119:this.$=a[s-3],r.setLink(a[s-3],a[s-2],a[s]);break;case 120:this.$=a[s-5],r.setLink(a[s-5],a[s-4],a[s]),r.setTooltip(a[s-5],a[s-2]);break;case 121:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 122:this.$=a[s-4],r.updateLink([a[s-2]],a[s]);break;case 123:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 124:this.$=a[s-8],r.updateLinkInterpolate([a[s-6]],a[s-2]),r.updateLink([a[s-6]],a[s]);break;case 125:this.$=a[s-8],r.updateLinkInterpolate(a[s-6],a[s-2]),r.updateLink(a[s-6],a[s]);break;case 126:this.$=a[s-6],r.updateLinkInterpolate([a[s-4]],a[s]);break;case 127:this.$=a[s-6],r.updateLinkInterpolate(a[s-4],a[s]);break;case 128:case 130:this.$=[a[s]];break;case 129:case 131:a[s-2].push(a[s]),this.$=a[s-2];break;case 133:this.$=a[s-1]+a[s];break;case 181:this.$=a[s];break;case 182:this.$=a[s-1]+``+a[s];break;case 184:this.$=a[s-1]+``+a[s];break;case 185:this.$={stmt:`dir`,value:`TB`};break;case 186:this.$={stmt:`dir`,value:`BT`};break;case 187:this.$={stmt:`dir`,value:`RL`};break;case 188:this.$={stmt:`dir`,value:`LR`};break;case 189:this.$={stmt:`dir`,value:`TD`}}},`anonymous`),table:[{3:1,4:2,9:t,10:r,12:i},{1:[3]},e(a,o,{5:6}),{4:7,9:t,10:r,12:i},{4:8,9:t,10:r,12:i},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},e(a,[2,9]),e(a,[2,10]),e(a,[2,11]),{8:[1,55],9:[1,56],10:k,15:54,18:57},e(A,[2,3]),e(A,[2,4]),e(A,[2,5]),e(A,[2,6]),e(A,[2,7]),e(A,[2,8]),{8:j,9:M,11:N,21:59,41:60,72:64,75:[1,65],77:[1,67],78:[1,66]},{8:j,9:M,11:N,21:68},{8:j,9:M,11:N,21:69},{8:j,9:M,11:N,21:70},{8:j,9:M,11:N,21:71},{8:j,9:M,11:N,21:72},{8:j,9:M,10:[1,73],11:N,21:74},e(A,[2,36]),{35:[1,75]},{37:[1,76]},e(A,[2,39]),e(se,[2,50],{18:77,39:78,10:k,40:ce}),{10:[1,80]},{10:[1,81]},{10:[1,82]},{10:[1,83]},{14:le,44:ue,60:de,80:[1,87],89:fe,95:[1,84],97:[1,85],101:86,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},e(A,[2,185]),e(A,[2,186]),e(A,[2,187]),e(A,[2,188]),e(A,[2,189]),e(be,[2,51]),e(be,[2,54],{46:[1,100]}),e(P,[2,72],{113:113,29:[1,101],44:h,48:[1,102],50:[1,103],52:[1,104],54:[1,105],56:[1,106],58:[1,107],60:g,63:[1,108],65:[1,109],67:[1,110],68:[1,111],70:[1,112],89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),e(F,[2,181]),e(F,[2,142]),e(F,[2,143]),e(F,[2,144]),e(F,[2,145]),e(F,[2,146]),e(F,[2,147]),e(F,[2,148]),e(F,[2,149]),e(F,[2,150]),e(F,[2,151]),e(F,[2,152]),e(a,[2,12]),e(a,[2,18]),e(a,[2,19]),{9:[1,114]},e(xe,[2,26],{18:115,10:k}),e(A,[2,27]),{42:116,43:39,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(A,[2,40]),e(A,[2,41]),e(A,[2,42]),e(Se,[2,76],{73:117,62:[1,119],74:[1,118]}),{76:120,79:121,80:Ce,81:we,116:Te,119:Ee},{75:[1,126],77:[1,127]},e(De,[2,83]),e(A,[2,28]),e(A,[2,29]),e(A,[2,30]),e(A,[2,31]),e(A,[2,32]),{10:Oe,12:ke,14:Ae,27:je,28:128,32:Me,44:Ne,60:Pe,75:Fe,80:[1,130],81:[1,131],83:141,84:Ie,85:Le,86:Re,87:ze,88:Be,89:Ve,90:He,91:129,105:Ue,109:We,111:Ge,114:Ke,115:qe,116:Je},e(Ye,o,{5:154}),e(A,[2,37]),e(A,[2,38]),e(se,[2,48],{44:Xe}),e(se,[2,49],{18:156,10:k,40:Ze}),e(be,[2,44]),{44:h,47:158,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{102:[1,159],103:160,105:[1,161]},{44:h,47:162,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{44:h,47:163,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,107],{10:[1,164],96:[1,165]}),{80:[1,166]},e(I,[2,115],{120:168,10:[1,167],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,117],{10:[1,169]}),e(L,[2,183]),e(L,[2,170]),e(L,[2,171]),e(L,[2,172]),e(L,[2,173]),e(L,[2,174]),e(L,[2,175]),e(L,[2,176]),e(L,[2,177]),e(L,[2,178]),e(L,[2,179]),e(L,[2,180]),{44:h,47:170,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{30:171,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:179,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:181,50:[1,180],67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:182,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:183,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:184,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{109:[1,185]},{30:186,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:187,65:[1,188],67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:189,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:190,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{30:191,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(F,[2,182]),e(a,[2,20]),e(xe,[2,25]),e(se,[2,46],{39:192,18:193,10:k,40:ce}),e(Se,[2,73],{10:[1,194]}),{10:[1,195]},{30:196,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{77:[1,197],79:198,116:Te,119:Ee},e(Qe,[2,79]),e(Qe,[2,81]),e(Qe,[2,82]),e(Qe,[2,168]),e(Qe,[2,169]),{76:199,79:121,80:Ce,81:we,116:Te,119:Ee},e(De,[2,84]),{8:j,9:M,10:Oe,11:N,12:ke,14:Ae,21:201,27:je,29:[1,200],32:Me,44:Ne,60:Pe,75:Fe,83:141,84:Ie,85:Le,86:Re,87:ze,88:Be,89:Ve,90:He,91:202,105:Ue,109:We,111:Ge,114:Ke,115:qe,116:Je},e(W,[2,101]),e(W,[2,103]),e(W,[2,104]),e(W,[2,157]),e(W,[2,158]),e(W,[2,159]),e(W,[2,160]),e(W,[2,161]),e(W,[2,162]),e(W,[2,163]),e(W,[2,164]),e(W,[2,165]),e(W,[2,166]),e(W,[2,167]),e(W,[2,90]),e(W,[2,91]),e(W,[2,92]),e(W,[2,93]),e(W,[2,94]),e(W,[2,95]),e(W,[2,96]),e(W,[2,97]),e(W,[2,98]),e(W,[2,99]),e(W,[2,100]),{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,203],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},{10:k,18:204},{44:[1,205]},e(be,[2,43]),{10:[1,206],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{10:[1,207]},{10:[1,208],106:[1,209]},e($e,[2,128]),{10:[1,210],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{10:[1,211],44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:113,114:T,115:E,116:D},{80:[1,212]},e(I,[2,109],{10:[1,213]}),e(I,[2,111],{10:[1,214]}),{80:[1,215]},e(L,[2,184]),{80:[1,216],98:[1,217]},e(be,[2,55],{113:113,44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),{31:[1,218],67:R,82:219,116:V,117:H,118:U},e(et,[2,86]),e(et,[2,88]),e(et,[2,89]),e(et,[2,153]),e(et,[2,154]),e(et,[2,155]),e(et,[2,156]),{49:[1,220],67:R,82:219,116:V,117:H,118:U},{30:221,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{51:[1,222],67:R,82:219,116:V,117:H,118:U},{53:[1,223],67:R,82:219,116:V,117:H,118:U},{55:[1,224],67:R,82:219,116:V,117:H,118:U},{57:[1,225],67:R,82:219,116:V,117:H,118:U},{60:[1,226]},{64:[1,227],67:R,82:219,116:V,117:H,118:U},{66:[1,228],67:R,82:219,116:V,117:H,118:U},{30:229,67:R,80:z,81:B,82:172,116:V,117:H,118:U},{31:[1,230],67:R,82:219,116:V,117:H,118:U},{67:R,69:[1,231],71:[1,232],82:219,116:V,117:H,118:U},{67:R,69:[1,234],71:[1,233],82:219,116:V,117:H,118:U},e(se,[2,45],{18:156,10:k,40:Ze}),e(se,[2,47],{44:Xe}),e(Se,[2,75]),e(Se,[2,74]),{62:[1,235],67:R,82:219,116:V,117:H,118:U},e(Se,[2,77]),e(Qe,[2,80]),{77:[1,236],79:198,116:Te,119:Ee},{30:237,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(Ye,o,{5:238}),e(W,[2,102]),e(A,[2,35]),{43:239,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},{10:k,18:240},{10:G,60:K,84:q,92:241,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:252,104:[1,253],105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:254,104:[1,255],105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{105:[1,256]},{10:G,60:K,84:q,92:257,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{44:h,47:258,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,108]),{80:[1,259]},{80:[1,260],98:[1,261]},e(I,[2,116]),e(I,[2,118],{10:[1,262]}),e(I,[2,119]),e(P,[2,56]),e(et,[2,87]),e(P,[2,57]),{51:[1,263],67:R,82:219,116:V,117:H,118:U},e(P,[2,64]),e(P,[2,59]),e(P,[2,60]),e(P,[2,61]),{109:[1,264]},e(P,[2,63]),e(P,[2,65]),{66:[1,265],67:R,82:219,116:V,117:H,118:U},e(P,[2,67]),e(P,[2,68]),e(P,[2,70]),e(P,[2,69]),e(P,[2,71]),e([10,44,60,89,102,105,106,109,111,114,115,116],[2,85]),e(Se,[2,78]),{31:[1,266],67:R,82:219,116:V,117:H,118:U},{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,267],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},e(be,[2,53]),{43:268,44:h,45:40,47:41,60:g,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D},e(I,[2,121],{106:tt}),e(nt,[2,130],{108:270,10:G,60:K,84:q,105:J,109:Y,110:X,111:Z,112:Q}),e($,[2,132]),e($,[2,134]),e($,[2,135]),e($,[2,136]),e($,[2,137]),e($,[2,138]),e($,[2,139]),e($,[2,140]),e($,[2,141]),e(I,[2,122],{106:tt}),{10:[1,271]},e(I,[2,123],{106:tt}),{10:[1,272]},e($e,[2,129]),e(I,[2,105],{106:tt}),e(I,[2,106],{113:113,44:h,60:g,89:y,102:b,105:x,106:S,109:C,111:w,114:T,115:E,116:D}),e(I,[2,110]),e(I,[2,112],{10:[1,273]}),e(I,[2,113]),{98:[1,274]},{51:[1,275]},{62:[1,276]},{66:[1,277]},{8:j,9:M,11:N,21:278},e(A,[2,34]),e(be,[2,52]),{10:G,60:K,84:q,105:J,107:279,108:243,109:Y,110:X,111:Z,112:Q},e($,[2,133]),{14:le,44:ue,60:de,89:fe,101:280,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},{14:le,44:ue,60:de,89:fe,101:281,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye,120:88},{98:[1,282]},e(I,[2,120]),e(P,[2,58]),{30:283,67:R,80:z,81:B,82:172,116:V,117:H,118:U},e(P,[2,66]),e(Ye,o,{5:284}),e(nt,[2,131],{108:270,10:G,60:K,84:q,105:J,109:Y,110:X,111:Z,112:Q}),e(I,[2,126],{120:168,10:[1,285],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,127],{120:168,10:[1,286],14:le,44:ue,60:de,89:fe,105:pe,106:me,109:he,111:ge,114:_e,115:ve,116:ye}),e(I,[2,114]),{31:[1,287],67:R,82:219,116:V,117:H,118:U},{6:11,7:12,8:s,9:c,10:l,11:u,20:17,22:18,23:19,24:20,25:21,26:22,27:d,32:[1,288],33:24,34:f,36:p,38:m,42:28,43:39,44:h,45:40,47:41,60:g,84:_,85:v,86:ee,87:te,88:ne,89:y,102:b,105:x,106:S,109:C,111:w,113:42,114:T,115:E,116:D,121:O,122:re,123:ie,124:ae,125:oe},{10:G,60:K,84:q,92:289,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},{10:G,60:K,84:q,92:290,105:J,107:242,108:243,109:Y,110:X,111:Z,112:Q},e(P,[2,62]),e(A,[2,33]),e(I,[2,124],{106:tt}),e(I,[2,125],{106:tt})],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var ee=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function te(e){r.length-=2*e,a.length-=e,o.length-=e}n(te,`popStack`);function ne(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(ne,`lex`);for(var y,b,x,S,C,w={},T,E,D,O;;){if(x=r[r.length-1],this.defaultActions[x]?S=this.defaultActions[x]:(y??=ne(),S=s[x]&&s[x][y]),S===void 0||!S.length||!S[0]){var re=``;for(T in O=[],s[x])this.terminals_[T]&&T>f&&O.push(`'`+this.terminals_[T]+`'`);re=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+O.join(`, `)+`, got '`+(this.terminals_[y]||y)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(y==p?`end of input`:`'`+(this.terminals_[y]||y)+`'`),this.parseError(re,{text:h.match,token:this.terminals_[y]||y,line:h.yylineno,loc:v,expected:O})}if(S[0]instanceof Array&&S.length>1)throw Error(`Parse Error: multiple actions possible at state: `+x+`, token: `+y);switch(S[0]){case 1:r.push(y),a.push(h.yytext),o.push(h.yylloc),r.push(S[1]),y=null,b?(y=b,b=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(E=this.productions_[S[1]][1],w.$=a[a.length-E],w._$={first_line:o[o.length-(E||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(E||1)].first_column,last_column:o[o.length-1].last_column},ee&&(w._$.range=[o[o.length-(E||1)].range[0],o[o.length-1].range[1]]),C=this.performAction.apply(w,[c,u,l,g.yy,S[1],a,o].concat(m)),C!==void 0)return C;E&&(r=r.slice(0,-1*E*2),a=a.slice(0,-1*E),o=o.slice(0,-1*E)),r.push(this.productions_[S[1]][0]),a.push(w.$),o.push(w._$),D=s[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0},`parse`)};rt.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),34;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),36;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return this.pushState(`shapeData`),t.yytext=``,40;case 8:return this.pushState(`shapeDataStr`),40;case 9:return this.popState(),40;case 10:return t.yytext=t.yytext.replace(/\n\s*/g,`
    `),40;case 11:return 40;case 12:this.popState();break;case 13:this.begin(`callbackname`);break;case 14:this.popState();break;case 15:this.popState(),this.begin(`callbackargs`);break;case 16:return 95;case 17:this.popState();break;case 18:return 96;case 19:return`MD_STR`;case 20:this.popState();break;case 21:this.begin(`md_string`);break;case 22:return`STR`;case 23:this.popState();break;case 24:this.pushState(`string`);break;case 25:return 84;case 26:return 102;case 27:return 85;case 28:return 104;case 29:return 86;case 30:return 87;case 31:return 97;case 32:this.begin(`click`);break;case 33:this.popState();break;case 34:return 88;case 35:return e.lex.firstGraph()&&this.begin(`dir`),12;case 36:return e.lex.firstGraph()&&this.begin(`dir`),12;case 37:return e.lex.firstGraph()&&this.begin(`dir`),12;case 38:return e.lex.firstGraph()&&this.begin(`dir`),12;case 39:return 27;case 40:return 32;case 41:return 98;case 42:return 98;case 43:return 98;case 44:return 98;case 45:return this.popState(),13;case 46:return this.popState(),14;case 47:return this.popState(),14;case 48:return this.popState(),14;case 49:return this.popState(),14;case 50:return this.popState(),14;case 51:return this.popState(),14;case 52:return this.popState(),14;case 53:return this.popState(),14;case 54:return this.popState(),14;case 55:return this.popState(),14;case 56:return 121;case 57:return 122;case 58:return 123;case 59:return 124;case 60:return 125;case 61:return 78;case 62:return 105;case 63:return 111;case 64:return 46;case 65:return 60;case 66:return 44;case 67:return 8;case 68:return 106;case 69:return 115;case 70:return this.popState(),77;case 71:return this.pushState(`edgeText`),75;case 72:return 119;case 73:return this.popState(),77;case 74:return this.pushState(`thickEdgeText`),75;case 75:return 119;case 76:return this.popState(),77;case 77:return this.pushState(`dottedEdgeText`),75;case 78:return 119;case 79:return 77;case 80:return this.popState(),53;case 81:return`TEXT`;case 82:return this.pushState(`ellipseText`),52;case 83:return this.popState(),55;case 84:return this.pushState(`text`),54;case 85:return this.popState(),57;case 86:return this.pushState(`text`),56;case 87:return 58;case 88:return this.pushState(`text`),67;case 89:return this.popState(),64;case 90:return this.pushState(`text`),63;case 91:return this.popState(),49;case 92:return this.pushState(`text`),48;case 93:return this.popState(),69;case 94:return this.popState(),71;case 95:return 117;case 96:return this.pushState(`trapText`),68;case 97:return this.pushState(`trapText`),70;case 98:return 118;case 99:return 67;case 100:return 90;case 101:return`SEP`;case 102:return 89;case 103:return 115;case 104:return 111;case 105:return 44;case 106:return 109;case 107:return 114;case 108:return 116;case 109:return this.popState(),62;case 110:return this.pushState(`text`),62;case 111:return this.popState(),51;case 112:return this.pushState(`text`),50;case 113:return this.popState(),31;case 114:return this.pushState(`text`),29;case 115:return this.popState(),66;case 116:return this.pushState(`text`),65;case 117:return`TEXT`;case 118:return`QUOTE`;case 119:return 9;case 120:return 10;case 121:return 11}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:swimlane-beta\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:[^\S\n\r]+)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},shapeData:{rules:[8,11,12,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},callbackargs:{rules:[17,18,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},callbackname:{rules:[14,15,16,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},href:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},click:{rules:[21,24,33,34,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},dottedEdgeText:{rules:[21,24,76,78,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},thickEdgeText:{rules:[21,24,73,75,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},edgeText:{rules:[21,24,70,72,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},trapText:{rules:[21,24,79,82,84,86,90,92,93,94,95,96,97,110,112,114,116],inclusive:!1},ellipseText:{rules:[21,24,79,80,81,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},text:{rules:[21,24,79,82,83,84,85,86,89,90,91,92,96,97,109,110,111,112,113,114,115,116,117],inclusive:!1},vertex:{rules:[21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},dir:{rules:[21,24,45,46,47,48,49,50,51,52,53,54,55,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_descr:{rules:[3,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},acc_title:{rules:[1,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},md_string:{rules:[19,20,21,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},string:{rules:[21,22,23,24,79,82,84,86,90,92,96,97,110,112,114,116],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,44,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,73,74,76,77,79,82,84,86,87,88,90,92,96,97,98,99,100,101,102,103,104,105,106,107,108,110,112,114,116,118,119,120,121],inclusive:!0}}}})();function it(){this.yy={}}return n(it,`Parser`),it.prototype=rt,rt.Parser=it,new it})();oe.parser=oe;var k=oe,A=Object.assign({},k);A.parse=e=>{let t=e.replace(/}\s*\n/g,`} +`);return k.parse(t)};var j=A,M=n(e=>{let{theme:t,bkgColorArray:r,borderColorArray:i}=e;if(!ee(t,i))return``;let a=ne(e.look),o=y(r),s=``;for(let t=0;t`${l}.node ${e}, ${l}.rough-node ${e}`,`collapsedRule`),d=n(e=>`${l}.swimlane.cluster .swimlane-title${e}, ${l}.swimlane.cluster .swimlane-body${e}`,`laneRule`);s+=` + + ${l}.cluster:not(.swimlane) rect { + stroke: ${e}; + ${c} + } + + ${l}.cluster:not(.swimlane) path { + stroke: ${e}; + ${c} + } + + /* Lane, classic and neo. */ + ${l}.swimlane.cluster rect.swimlane-title, + ${l}.swimlane.cluster rect.swimlane-body { + stroke: ${e}; + ${c} + } + + /* Lane, handDrawn: roughjs emits the hachure fill first, then the outline. */ + ${d(` path:nth-of-type(2)`)} { + stroke: ${e}; + } +${o?` + /* A roughjs fill is drawn as lines, so the lane fill is a stroke here. */ + ${d(` path:first-of-type`)} { + stroke: ${r[t%r.length]}; + } +`:``} + ${u(`.collapsed-group`)}, + ${u(`.collapsed-group path`)} { + stroke: ${e}; + ${c} + } + + /* The ellipsis dots and the separator take clusterBorder further down, so without + these the container is palette-coloured while its own markers are not. */ + ${u(`.collapsed-indicator`)} { + fill: ${e}; + } + + ${u(`.collapsed-separator`)} { + stroke: ${e}; + } + `}return s},`genColor`),N=n((e,t)=>{let n=g,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return c(r,i,a,t)},`fade`),se=n(e=>`${M(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}px; + } + .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label { + text-anchor: middle; + } + + .node .katex path { + fill: #000; + stroke: #000; + stroke-width: 1px; + } + + .rough-node .label,.node .label, .image-shape .label, .icon-shape .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + + .root .anchor path { + fill: ${e.lineColor} !important; + stroke-width: 0; + stroke: ${e.lineColor}; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth??2}px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${N(e.edgeLabelBackground,.5)}; + // background-color: + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + /* Collapsed subgraph node (@{ view: collapsed }) */ + .node .collapsed-indicator { + fill: ${e.clusterBorder}; + stroke: none; + opacity: 0.6; + } + + .node .collapsed-separator { + stroke: ${e.clusterBorder}; + stroke-width: 0.75px; + } + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .flowchartTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + + rect.text { + fill: none; + stroke-width: 0; + } + + .icon-shape, .image-shape { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + padding: 2px; + } + .label rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + ${T()} +`,`getStyles`),ce=n(({styles:e=se}={})=>({parser:j,get db(){return new ie},renderer:ae,styles:e,init:n(e=>{e.flowchart||={},e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,r({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}})},`init`)}),`createFlowDiagram`),le=ce();export{le as n,se as r,ce as t}; \ No newline at end of file diff --git a/www/assets/chunk-7PRAP22T-DSs4vaIy.js b/www/assets/chunk-7PRAP22T-DSs4vaIy.js new file mode 100644 index 0000000..9f10977 --- /dev/null +++ b/www/assets/chunk-7PRAP22T-DSs4vaIy.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{x as t}from"./chunk-O7XYJQB3-Bce2lzyF.js";var n=e(e=>{let{handDrawnSeed:n}=t();return{fill:e,hachureAngle:120,hachureGap:1.5,fillWeight:1.5,roughness:.7,stroke:e,seed:n}},`solidStateFill`),r=e(e=>Array.isArray(e)?e:e?e.split(`;`).map(e=>e.trim()).filter(Boolean):[],`normalizeStyleList`),i=e(e=>{let t=a([...e.cssCompiledStyles||[],...e.cssStyles||[],...r(e.labelStyle)]);return{stylesMap:t,stylesArray:[...t]}},`compileStyles`),a=e(e=>{let t=new Map;return e.forEach(e=>{let[n,r]=e.split(`:`);t.set(n.trim(),r?.trim())}),t},`styles2Map`),o=e(e=>e===`color`||e===`font-size`||e===`font-family`||e===`font-weight`||e===`font-style`||e===`text-decoration`||e===`text-align`||e===`text-transform`||e===`line-height`||e===`letter-spacing`||e===`word-spacing`||e===`text-shadow`||e===`text-overflow`||e===`white-space`||e===`word-wrap`||e===`word-break`||e===`overflow-wrap`||e===`hyphens`,`isLabelStyle`),s=e(e=>{let{stylesArray:t}=i(e),n=[],r=[],a=[],s=[];return t.forEach(e=>{let t=e[0];o(t)?n.push(e.join(`:`)+` !important`):(r.push(e.join(`:`)+` !important`),t.includes(`stroke`)&&a.push(e.join(`:`)+` !important`),t===`fill`&&s.push(e.join(`:`)+` !important`))}),{labelStyles:n.join(`;`),nodeStyles:r.join(`;`),stylesArray:t,borderStyles:a,backgroundStyles:s}},`styles2String`),c=e((e,n)=>{let{themeVariables:r,handDrawnSeed:a}=t(),{nodeBorder:o,mainBkg:s}=r,{stylesMap:c}=i(e);return Object.assign({roughness:.7,fill:c.get(`fill`)||s,fillStyle:`hachure`,fillWeight:1.5,hachureGap:1.5,stroke:c.get(`stroke`)||o,seed:a,strokeWidth:c.get(`stroke-width`)?.replace(`px`,``)||1.3,fillLineDash:[0,0],strokeLineDash:l(c.get(`stroke-dasharray`))},n)},`userNodeOverrides`),l=e(e=>{if(!e)return[0,0];let t=e.trim().split(/\s+/).map(Number);if(t.length===1){let e=isNaN(t[0])?0:t[0];return[e,e]}return[isNaN(t[0])?0:t[0],isNaN(t[1])?0:t[1]]},`getStrokeDashArray`);export{c as a,s as i,o as n,n as r,i as t}; \ No newline at end of file diff --git a/www/assets/chunk-FOHPRMQF-DHwB1DNv.js b/www/assets/chunk-FOHPRMQF-DHwB1DNv.js new file mode 100644 index 0000000..370929b --- /dev/null +++ b/www/assets/chunk-FOHPRMQF-DHwB1DNv.js @@ -0,0 +1,161 @@ +var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,n)=>t(e,`name`,{value:n,configurable:!0}),s=(e,t)=>function(){return e&&(t=(0,e[r(e)[0]])(e=0)),t},c=(e,t)=>function(){return t||(0,e[r(e)[0]])((t={exports:{}}).exports,t),t.exports},l=(e,n)=>{for(var r in n)t(e,r,{get:n[r],enumerable:!0})},u=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(let c of r(i))!a.call(e,c)&&c!==o&&t(e,c,{get:()=>i[c],enumerable:!(s=n(i,c))||s.enumerable});return e},d=(e,t,n)=>(u(e,t,`default`),n&&u(n,t,`default`)),f=(n,r,a)=>(a=n==null?{}:e(i(n)),u(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),p=e=>u(t({},`__esModule`,{value:!0}),e),m={};l(m,{AnnotatedTextEdit:()=>T,ChangeAnnotation:()=>de,ChangeAnnotationIdentifier:()=>w,CodeAction:()=>We,CodeActionContext:()=>Ue,CodeActionKind:()=>Ve,CodeActionTriggerKind:()=>He,CodeDescription:()=>se,CodeLens:()=>Ge,Color:()=>S,ColorInformation:()=>te,ColorPresentation:()=>ne,Command:()=>le,CompletionItem:()=>Oe,CompletionItemKind:()=>Se,CompletionItemLabelDetails:()=>De,CompletionItemTag:()=>we,CompletionList:()=>ke,CreateFile:()=>D,DeleteFile:()=>fe,Diagnostic:()=>ce,DiagnosticRelatedInformation:()=>ie,DiagnosticSeverity:()=>ae,DiagnosticTag:()=>oe,DocumentHighlight:()=>Fe,DocumentHighlightKind:()=>Pe,DocumentLink:()=>qe,DocumentSymbol:()=>Be,DocumentUri:()=>h,EOL:()=>ft,FoldingRange:()=>re,FoldingRangeKind:()=>C,FormattingOptions:()=>Ke,Hover:()=>je,InlayHint:()=>it,InlayHintKind:()=>nt,InlayHintLabelPart:()=>rt,InlineCompletionContext:()=>ut,InlineCompletionItem:()=>ot,InlineCompletionList:()=>st,InlineCompletionTriggerKind:()=>ct,InlineValueContext:()=>tt,InlineValueEvaluatableExpression:()=>et,InlineValueText:()=>Qe,InlineValueVariableLookup:()=>$e,InsertReplaceEdit:()=>Te,InsertTextFormat:()=>Ce,InsertTextMode:()=>Ee,Location:()=>x,LocationLink:()=>ee,MarkedString:()=>Ae,MarkupContent:()=>xe,MarkupKind:()=>be,OptionalVersionedTextDocumentIdentifier:()=>ve,ParameterInformation:()=>Me,Position:()=>y,Range:()=>b,RenameFile:()=>O,SelectedCompletionInfo:()=>lt,SelectionRange:()=>Je,SemanticTokenModifiers:()=>Xe,SemanticTokenTypes:()=>Ye,SemanticTokens:()=>Ze,SignatureInformation:()=>Ne,StringValue:()=>at,SymbolInformation:()=>Re,SymbolKind:()=>Ie,SymbolTag:()=>Le,TextDocument:()=>pt,TextDocumentEdit:()=>E,TextDocumentIdentifier:()=>ge,TextDocumentItem:()=>ye,TextEdit:()=>ue,URI:()=>g,VersionedTextDocumentIdentifier:()=>_e,WorkspaceChange:()=>he,WorkspaceEdit:()=>k,WorkspaceFolder:()=>dt,WorkspaceSymbol:()=>ze,integer:()=>_,uinteger:()=>v});var h,g,_,v,y,b,x,ee,S,te,ne,C,re,ie,ae,oe,se,ce,le,ue,de,w,T,E,D,O,fe,k,pe,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le,Re,ze,Be,Ve,He,Ue,We,Ge,Ke,qe,Je,Ye,Xe,Ze,Qe,$e,et,tt,nt,rt,it,at,ot,st,ct,lt,ut,dt,ft,pt,mt,A,ht=s({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(h||={}),(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(g||={}),(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(_||={}),(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(v||={}),(function(e){function t(e,t){return e===Number.MAX_VALUE&&(e=v.MAX_VALUE),t===Number.MAX_VALUE&&(t=v.MAX_VALUE),{line:e,character:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.uinteger(t.line)&&A.uinteger(t.character)}o(n,`is`),e.is=n})(y||={}),(function(e){function t(e,t,n,r){if(A.uinteger(e)&&A.uinteger(t)&&A.uinteger(n)&&A.uinteger(r))return{start:y.create(e,t),end:y.create(n,r)};if(y.is(e)&&y.is(t))return{start:e,end:t};throw Error(`Range#create called with invalid arguments[${e}, ${t}, ${n}, ${r}]`)}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&y.is(t.start)&&y.is(t.end)}o(n,`is`),e.is=n})(b||={}),(function(e){function t(e,t){return{uri:e,range:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.range)&&(A.string(t.uri)||A.undefined(t.uri))}o(n,`is`),e.is=n})(x||={}),(function(e){function t(e,t,n,r){return{targetUri:e,targetRange:t,targetSelectionRange:n,originSelectionRange:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.targetRange)&&A.string(t.targetUri)&&b.is(t.targetSelectionRange)&&(b.is(t.originSelectionRange)||A.undefined(t.originSelectionRange))}o(n,`is`),e.is=n})(ee||={}),(function(e){function t(e,t,n,r){return{red:e,green:t,blue:n,alpha:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.numberRange(t.red,0,1)&&A.numberRange(t.green,0,1)&&A.numberRange(t.blue,0,1)&&A.numberRange(t.alpha,0,1)}o(n,`is`),e.is=n})(S||={}),(function(e){function t(e,t){return{range:e,color:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&b.is(t.range)&&S.is(t.color)}o(n,`is`),e.is=n})(te||={}),(function(e){function t(e,t,n){return{label:e,textEdit:t,additionalTextEdits:n}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.string(t.label)&&(A.undefined(t.textEdit)||ue.is(t))&&(A.undefined(t.additionalTextEdits)||A.typedArray(t.additionalTextEdits,ue.is))}o(n,`is`),e.is=n})(ne||={}),(function(e){e.Comment=`comment`,e.Imports=`imports`,e.Region=`region`})(C||={}),(function(e){function t(e,t,n,r,i,a){let o={startLine:e,endLine:t};return A.defined(n)&&(o.startCharacter=n),A.defined(r)&&(o.endCharacter=r),A.defined(i)&&(o.kind=i),A.defined(a)&&(o.collapsedText=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.uinteger(t.startLine)&&A.uinteger(t.startLine)&&(A.undefined(t.startCharacter)||A.uinteger(t.startCharacter))&&(A.undefined(t.endCharacter)||A.uinteger(t.endCharacter))&&(A.undefined(t.kind)||A.string(t.kind))}o(n,`is`),e.is=n})(re||={}),(function(e){function t(e,t){return{location:e,message:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&x.is(t.location)&&A.string(t.message)}o(n,`is`),e.is=n})(ie||={}),(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(ae||={}),(function(e){e.Unnecessary=1,e.Deprecated=2})(oe||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&A.string(t.href)}o(t,`is`),e.is=t})(se||={}),(function(e){function t(e,t,n,r,i,a){let o={range:e,message:t};return A.defined(n)&&(o.severity=n),A.defined(r)&&(o.code=r),A.defined(i)&&(o.source=i),A.defined(a)&&(o.relatedInformation=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&A.string(t.message)&&(A.number(t.severity)||A.undefined(t.severity))&&(A.integer(t.code)||A.string(t.code)||A.undefined(t.code))&&(A.undefined(t.codeDescription)||A.string(t.codeDescription?.href))&&(A.string(t.source)||A.undefined(t.source))&&(A.undefined(t.relatedInformation)||A.typedArray(t.relatedInformation,ie.is))}o(n,`is`),e.is=n})(ce||={}),(function(e){function t(e,t,...n){let r={title:e,command:t};return A.defined(n)&&n.length>0&&(r.arguments=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.title)&&A.string(t.command)}o(n,`is`),e.is=n})(le||={}),(function(e){function t(e,t){return{range:e,newText:t}}o(t,`replace`),e.replace=t;function n(e,t){return{range:{start:e,end:e},newText:t}}o(n,`insert`),e.insert=n;function r(e){return{range:e,newText:``}}o(r,`del`),e.del=r;function i(e){let t=e;return A.objectLiteral(t)&&A.string(t.newText)&&b.is(t.range)}o(i,`is`),e.is=i})(ue||={}),(function(e){function t(e,t,n){let r={label:e};return t!==void 0&&(r.needsConfirmation=t),n!==void 0&&(r.description=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&A.string(t.label)&&(A.boolean(t.needsConfirmation)||t.needsConfirmation===void 0)&&(A.string(t.description)||t.description===void 0)}o(n,`is`),e.is=n})(de||={}),(function(e){function t(e){let t=e;return A.string(t)}o(t,`is`),e.is=t})(w||={}),(function(e){function t(e,t,n){return{range:e,newText:t,annotationId:n}}o(t,`replace`),e.replace=t;function n(e,t,n){return{range:{start:e,end:e},newText:t,annotationId:n}}o(n,`insert`),e.insert=n;function r(e,t){return{range:e,newText:``,annotationId:t}}o(r,`del`),e.del=r;function i(e){let t=e;return ue.is(t)&&(de.is(t.annotationId)||w.is(t.annotationId))}o(i,`is`),e.is=i})(T||={}),(function(e){function t(e,t){return{textDocument:e,edits:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&ve.is(t.textDocument)&&Array.isArray(t.edits)}o(n,`is`),e.is=n})(E||={}),(function(e){function t(e,t,n){let r={kind:`create`,uri:e};return t!==void 0&&(t.overwrite!==void 0||t.ignoreIfExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`create`&&A.string(t.uri)&&(t.options===void 0||(t.options.overwrite===void 0||A.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||A.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(D||={}),(function(e){function t(e,t,n,r){let i={kind:`rename`,oldUri:e,newUri:t};return n!==void 0&&(n.overwrite!==void 0||n.ignoreIfExists!==void 0)&&(i.options=n),r!==void 0&&(i.annotationId=r),i}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`rename`&&A.string(t.oldUri)&&A.string(t.newUri)&&(t.options===void 0||(t.options.overwrite===void 0||A.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||A.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(O||={}),(function(e){function t(e,t,n){let r={kind:`delete`,uri:e};return t!==void 0&&(t.recursive!==void 0||t.ignoreIfNotExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`delete`&&A.string(t.uri)&&(t.options===void 0||(t.options.recursive===void 0||A.boolean(t.options.recursive))&&(t.options.ignoreIfNotExists===void 0||A.boolean(t.options.ignoreIfNotExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(fe||={}),(function(e){function t(e){let t=e;return t&&(t.changes!==void 0||t.documentChanges!==void 0)&&(t.documentChanges===void 0||t.documentChanges.every(e=>A.string(e.kind)?D.is(e)||O.is(e)||fe.is(e):E.is(e)))}o(t,`is`),e.is=t})(k||={}),pe=class{static{o(this,`TextEditChangeImpl`)}constructor(e,t){this.edits=e,this.changeAnnotations=t}insert(e,t,n){let r,i;if(n===void 0?r=ue.insert(e,t):w.is(n)?(i=n,r=T.insert(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.insert(e,t,i)),this.edits.push(r),i!==void 0)return i}replace(e,t,n){let r,i;if(n===void 0?r=ue.replace(e,t):w.is(n)?(i=n,r=T.replace(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.replace(e,t,i)),this.edits.push(r),i!==void 0)return i}delete(e,t){let n,r;if(t===void 0?n=ue.del(e):w.is(t)?(r=t,n=T.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(t),n=T.del(e,r)),this.edits.push(n),r!==void 0)return r}add(e){this.edits.push(e)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(e){if(e===void 0)throw Error(`Text edit change is not configured to manage change annotations.`)}},me=class{static{o(this,`ChangeAnnotations`)}constructor(e){this._annotations=e===void 0?Object.create(null):e,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(e,t){let n;if(w.is(e)?n=e:(n=this.nextId(),t=e),this._annotations[n]!==void 0)throw Error(`Id ${n} is already in use.`);if(t===void 0)throw Error(`No annotation provided for id ${n}`);return this._annotations[n]=t,this._size++,n}nextId(){return this._counter++,this._counter.toString()}},he=class{static{o(this,`WorkspaceChange`)}constructor(e){this._textEditChanges=Object.create(null),e===void 0?this._workspaceEdit={}:(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new me(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach(e=>{if(E.is(e)){let t=new pe(e.edits,this._changeAnnotations);this._textEditChanges[e.textDocument.uri]=t}})):e.changes&&Object.keys(e.changes).forEach(t=>{let n=new pe(e.changes[t]);this._textEditChanges[t]=n}))}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(e){if(ve.is(e)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let t={uri:e.uri,version:e.version},n=this._textEditChanges[t.uri];if(!n){let e=[],r={textDocument:t,edits:e};this._workspaceEdit.documentChanges.push(r),n=new pe(e,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw Error(`Workspace edit is not configured for normal text edit changes.`);let t=this._textEditChanges[e];if(!t){let n=[];this._workspaceEdit.changes[e]=n,t=new pe(n),this._textEditChanges[e]=t}return t}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new me,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=D.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=D.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}renameFile(e,t,n,r){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let i;de.is(n)||w.is(n)?i=n:r=n;let a,o;if(i===void 0?a=O.create(e,t,r):(o=w.is(i)?i:this._changeAnnotations.manage(i),a=O.create(e,t,r,o)),this._workspaceEdit.documentChanges.push(a),o!==void 0)return o}deleteFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=fe.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=fe.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}},(function(e){function t(e){return{uri:e}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)}o(n,`is`),e.is=n})(ge||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&A.integer(t.version)}o(n,`is`),e.is=n})(_e||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&(t.version===null||A.integer(t.version))}o(n,`is`),e.is=n})(ve||={}),(function(e){function t(e,t,n,r){return{uri:e,languageId:t,version:n,text:r}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.string(t.uri)&&A.string(t.languageId)&&A.integer(t.version)&&A.string(t.text)}o(n,`is`),e.is=n})(ye||={}),(function(e){e.PlainText=`plaintext`,e.Markdown=`markdown`;function t(t){let n=t;return n===e.PlainText||n===e.Markdown}o(t,`is`),e.is=t})(be||={}),(function(e){function t(e){let t=e;return A.objectLiteral(e)&&be.is(t.kind)&&A.string(t.value)}o(t,`is`),e.is=t})(xe||={}),(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(Se||={}),(function(e){e.PlainText=1,e.Snippet=2})(Ce||={}),(function(e){e.Deprecated=1})(we||={}),(function(e){function t(e,t,n){return{newText:e,insert:t,replace:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.newText)&&b.is(t.insert)&&b.is(t.replace)}o(n,`is`),e.is=n})(Te||={}),(function(e){e.asIs=1,e.adjustIndentation=2})(Ee||={}),(function(e){function t(e){let t=e;return t&&(A.string(t.detail)||t.detail===void 0)&&(A.string(t.description)||t.description===void 0)}o(t,`is`),e.is=t})(De||={}),(function(e){function t(e){return{label:e}}o(t,`create`),e.create=t})(Oe||={}),(function(e){function t(e,t){return{items:e||[],isIncomplete:!!t}}o(t,`create`),e.create=t})(ke||={}),(function(e){function t(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,`\\$&`)}o(t,`fromPlainText`),e.fromPlainText=t;function n(e){let t=e;return A.string(t)||A.objectLiteral(t)&&A.string(t.language)&&A.string(t.value)}o(n,`is`),e.is=n})(Ae||={}),(function(e){function t(e){let t=e;return!!t&&A.objectLiteral(t)&&(xe.is(t.contents)||Ae.is(t.contents)||A.typedArray(t.contents,Ae.is))&&(e.range===void 0||b.is(e.range))}o(t,`is`),e.is=t})(je||={}),(function(e){function t(e,t){return t?{label:e,documentation:t}:{label:e}}o(t,`create`),e.create=t})(Me||={}),(function(e){function t(e,t,...n){let r={label:e};return A.defined(t)&&(r.documentation=t),r.parameters=A.defined(n)?n:[],r}o(t,`create`),e.create=t})(Ne||={}),(function(e){e.Text=1,e.Read=2,e.Write=3})(Pe||={}),(function(e){function t(e,t){let n={range:e};return A.number(t)&&(n.kind=t),n}o(t,`create`),e.create=t})(Fe||={}),(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(Ie||={}),(function(e){e.Deprecated=1})(Le||={}),(function(e){function t(e,t,n,r,i){let a={name:e,kind:t,location:{uri:r,range:n}};return i&&(a.containerName=i),a}o(t,`create`),e.create=t})(Re||={}),(function(e){function t(e,t,n,r){return r===void 0?{name:e,kind:t,location:{uri:n}}:{name:e,kind:t,location:{uri:n,range:r}}}o(t,`create`),e.create=t})(ze||={}),(function(e){function t(e,t,n,r,i,a){let o={name:e,detail:t,kind:n,range:r,selectionRange:i};return a!==void 0&&(o.children=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.name)&&A.number(t.kind)&&b.is(t.range)&&b.is(t.selectionRange)&&(t.detail===void 0||A.string(t.detail))&&(t.deprecated===void 0||A.boolean(t.deprecated))&&(t.children===void 0||Array.isArray(t.children))&&(t.tags===void 0||Array.isArray(t.tags))}o(n,`is`),e.is=n})(Be||={}),(function(e){e.Empty=``,e.QuickFix=`quickfix`,e.Refactor=`refactor`,e.RefactorExtract=`refactor.extract`,e.RefactorInline=`refactor.inline`,e.RefactorRewrite=`refactor.rewrite`,e.Source=`source`,e.SourceOrganizeImports=`source.organizeImports`,e.SourceFixAll=`source.fixAll`})(Ve||={}),(function(e){e.Invoked=1,e.Automatic=2})(He||={}),(function(e){function t(e,t,n){let r={diagnostics:e};return t!=null&&(r.only=t),n!=null&&(r.triggerKind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.typedArray(t.diagnostics,ce.is)&&(t.only===void 0||A.typedArray(t.only,A.string))&&(t.triggerKind===void 0||t.triggerKind===He.Invoked||t.triggerKind===He.Automatic)}o(n,`is`),e.is=n})(Ue||={}),(function(e){function t(e,t,n){let r={title:e},i=!0;return typeof t==`string`?(i=!1,r.kind=t):le.is(t)?r.command=t:r.edit=t,i&&n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&A.string(t.title)&&(t.diagnostics===void 0||A.typedArray(t.diagnostics,ce.is))&&(t.kind===void 0||A.string(t.kind))&&(t.edit!==void 0||t.command!==void 0)&&(t.command===void 0||le.is(t.command))&&(t.isPreferred===void 0||A.boolean(t.isPreferred))&&(t.edit===void 0||k.is(t.edit))}o(n,`is`),e.is=n})(We||={}),(function(e){function t(e,t){let n={range:e};return A.defined(t)&&(n.data=t),n}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&(A.undefined(t.command)||le.is(t.command))}o(n,`is`),e.is=n})(Ge||={}),(function(e){function t(e,t){return{tabSize:e,insertSpaces:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&A.uinteger(t.tabSize)&&A.boolean(t.insertSpaces)}o(n,`is`),e.is=n})(Ke||={}),(function(e){function t(e,t,n){return{range:e,target:t,data:n}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(t.range)&&(A.undefined(t.target)||A.string(t.target))}o(n,`is`),e.is=n})(qe||={}),(function(e){function t(e,t){return{range:e,parent:t}}o(t,`create`),e.create=t;function n(t){let n=t;return A.objectLiteral(n)&&b.is(n.range)&&(n.parent===void 0||e.is(n.parent))}o(n,`is`),e.is=n})(Je||={}),(function(e){e.namespace=`namespace`,e.type=`type`,e.class=`class`,e.enum=`enum`,e.interface=`interface`,e.struct=`struct`,e.typeParameter=`typeParameter`,e.parameter=`parameter`,e.variable=`variable`,e.property=`property`,e.enumMember=`enumMember`,e.event=`event`,e.function=`function`,e.method=`method`,e.macro=`macro`,e.keyword=`keyword`,e.modifier=`modifier`,e.comment=`comment`,e.string=`string`,e.number=`number`,e.regexp=`regexp`,e.operator=`operator`,e.decorator=`decorator`})(Ye||={}),(function(e){e.declaration=`declaration`,e.definition=`definition`,e.readonly=`readonly`,e.static=`static`,e.deprecated=`deprecated`,e.abstract=`abstract`,e.async=`async`,e.modification=`modification`,e.documentation=`documentation`,e.defaultLibrary=`defaultLibrary`})(Xe||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&(t.resultId===void 0||typeof t.resultId==`string`)&&Array.isArray(t.data)&&(t.data.length===0||typeof t.data[0]==`number`)}o(t,`is`),e.is=t})(Ze||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&A.string(t.text)}o(n,`is`),e.is=n})(Qe||={}),(function(e){function t(e,t,n){return{range:e,variableName:t,caseSensitiveLookup:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&A.boolean(t.caseSensitiveLookup)&&(A.string(t.variableName)||t.variableName===void 0)}o(n,`is`),e.is=n})($e||={}),(function(e){function t(e,t){return{range:e,expression:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&(A.string(t.expression)||t.expression===void 0)}o(n,`is`),e.is=n})(et||={}),(function(e){function t(e,t){return{frameId:e,stoppedLocation:t}}o(t,`create`),e.create=t;function n(e){let t=e;return A.defined(t)&&b.is(e.stoppedLocation)}o(n,`is`),e.is=n})(tt||={}),(function(e){e.Type=1,e.Parameter=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(nt||={}),(function(e){function t(e){return{value:e}}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&(t.tooltip===void 0||A.string(t.tooltip)||xe.is(t.tooltip))&&(t.location===void 0||x.is(t.location))&&(t.command===void 0||le.is(t.command))}o(n,`is`),e.is=n})(rt||={}),(function(e){function t(e,t,n){let r={position:e,label:t};return n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return A.objectLiteral(t)&&y.is(t.position)&&(A.string(t.label)||A.typedArray(t.label,rt.is))&&(t.kind===void 0||nt.is(t.kind))&&t.textEdits===void 0||A.typedArray(t.textEdits,ue.is)&&(t.tooltip===void 0||A.string(t.tooltip)||xe.is(t.tooltip))&&(t.paddingLeft===void 0||A.boolean(t.paddingLeft))&&(t.paddingRight===void 0||A.boolean(t.paddingRight))}o(n,`is`),e.is=n})(it||={}),(function(e){function t(e){return{kind:`snippet`,value:e}}o(t,`createSnippet`),e.createSnippet=t})(at||={}),(function(e){function t(e,t,n,r){return{insertText:e,filterText:t,range:n,command:r}}o(t,`create`),e.create=t})(ot||={}),(function(e){function t(e){return{items:e}}o(t,`create`),e.create=t})(st||={}),(function(e){e.Invoked=0,e.Automatic=1})(ct||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t})(lt||={}),(function(e){function t(e,t){return{triggerKind:e,selectedCompletionInfo:t}}o(t,`create`),e.create=t})(ut||={}),(function(e){function t(e){let t=e;return A.objectLiteral(t)&&g.is(t.uri)&&A.string(t.name)}o(t,`is`),e.is=t})(dt||={}),ft=[` +`,`\r +`,`\r`],(function(e){function t(e,t,n,r){return new mt(e,t,n,r)}o(t,`create`),e.create=t;function n(e){let t=e;return!!(A.defined(t)&&A.string(t.uri)&&(A.undefined(t.languageId)||A.string(t.languageId))&&A.uinteger(t.lineCount)&&A.func(t.getText)&&A.func(t.positionAt)&&A.func(t.offsetAt))}o(n,`is`),e.is=n;function r(e,t){let n=e.getText(),r=i(t,(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),a=n.length;for(let t=r.length-1;t>=0;t--){let i=r[t],o=e.offsetAt(i.range.start),s=e.offsetAt(i.range.end);if(s<=a)n=n.substring(0,o)+i.newText+n.substring(s,n.length);else throw Error(`Overlapping edit`);a=o}return n}o(r,`applyEdits`),e.applyEdits=r;function i(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),a=e.slice(n);i(r,t),i(a,t);let o=0,s=0,c=0;for(;o0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return y.create(0,e);for(;ne?r=i:n=i+1}let i=n-1;return y.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line],r=e.line+1n(e))}o(c,`stringArray`),e.stringArray=c}}),vt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/events.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Emitter=e.Event=void 0;var t=gt(),n;(function(e){let t={dispose(){}};e.None=function(){return t}})(n||(e.Event=n={}));var r=class{static{o(this,`CallbackList`)}add(e,t=null,n){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(n)&&n.push({dispose:o(()=>this.remove(e,t),`dispose`)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r{this._callbacks||=new r,this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,n);let a={dispose:o(()=>{this._callbacks&&(this._callbacks.remove(t,n),a.dispose=e._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))},`dispose`)};return Array.isArray(i)&&i.push(a),a},this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&=(this._callbacks.dispose(),void 0)}};e.Emitter=i,i._noop=function(){}}}),yt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/cancellation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CancellationTokenSource=e.CancellationToken=void 0;var t=gt(),n=_t(),r=vt(),i;(function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:r.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:r.Event.None});function t(t){let r=t;return r&&(r===e.None||r===e.Cancelled||n.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}o(t,`is`),e.is=t})(i||(e.CancellationToken=i={}));var a=Object.freeze(function(e,n){let r=(0,t.default)().timer.setTimeout(e.bind(n),0);return{dispose(){r.dispose()}}}),s=class{static{o(this,`MutableToken`)}constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?a:(this._emitter||=new r.Emitter,this._emitter.event)}dispose(){this._emitter&&=(this._emitter.dispose(),void 0)}};e.CancellationTokenSource=class{static{o(this,`CancellationTokenSource`)}get token(){return this._token||=new s,this._token}cancel(){this._token?this._token.cancel():this._token=i.Cancelled}dispose(){this._token?this._token instanceof s&&this._token.dispose():this._token=i.None}}}}),bt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messages.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Message=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType=e.RequestType0=e.AbstractMessageSignature=e.ParameterStructures=e.ResponseError=e.ErrorCodes=void 0;var t=_t(),n;(function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3})(n||(e.ErrorCodes=n={})),e.ResponseError=class e extends Error{static{o(this,`ResponseError`)}constructor(r,i,a){super(i),this.code=t.number(r)?r:n.UnknownErrorCode,this.data=a,Object.setPrototypeOf(this,e.prototype)}toJson(){let e={code:this.code,message:this.message};return this.data!==void 0&&(e.data=this.data),e}};var r=class e{static{o(this,`ParameterStructures`)}constructor(e){this.kind=e}static is(t){return t===e.auto||t===e.byName||t===e.byPosition}toString(){return this.kind}};e.ParameterStructures=r,r.auto=new r(`auto`),r.byPosition=new r(`byPosition`),r.byName=new r(`byName`);var i=class{static{o(this,`AbstractMessageSignature`)}constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return r.auto}};e.AbstractMessageSignature=i,e.RequestType0=class extends i{static{o(this,`RequestType0`)}constructor(e){super(e,0)}},e.RequestType=class extends i{static{o(this,`RequestType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType1=class extends i{static{o(this,`RequestType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType2=class extends i{static{o(this,`RequestType2`)}constructor(e){super(e,2)}},e.RequestType3=class extends i{static{o(this,`RequestType3`)}constructor(e){super(e,3)}},e.RequestType4=class extends i{static{o(this,`RequestType4`)}constructor(e){super(e,4)}},e.RequestType5=class extends i{static{o(this,`RequestType5`)}constructor(e){super(e,5)}},e.RequestType6=class extends i{static{o(this,`RequestType6`)}constructor(e){super(e,6)}},e.RequestType7=class extends i{static{o(this,`RequestType7`)}constructor(e){super(e,7)}},e.RequestType8=class extends i{static{o(this,`RequestType8`)}constructor(e){super(e,8)}},e.RequestType9=class extends i{static{o(this,`RequestType9`)}constructor(e){super(e,9)}},e.NotificationType=class extends i{static{o(this,`NotificationType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType0=class extends i{static{o(this,`NotificationType0`)}constructor(e){super(e,0)}},e.NotificationType1=class extends i{static{o(this,`NotificationType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType2=class extends i{static{o(this,`NotificationType2`)}constructor(e){super(e,2)}},e.NotificationType3=class extends i{static{o(this,`NotificationType3`)}constructor(e){super(e,3)}},e.NotificationType4=class extends i{static{o(this,`NotificationType4`)}constructor(e){super(e,4)}},e.NotificationType5=class extends i{static{o(this,`NotificationType5`)}constructor(e){super(e,5)}},e.NotificationType6=class extends i{static{o(this,`NotificationType6`)}constructor(e){super(e,6)}},e.NotificationType7=class extends i{static{o(this,`NotificationType7`)}constructor(e){super(e,7)}},e.NotificationType8=class extends i{static{o(this,`NotificationType8`)}constructor(e){super(e,8)}},e.NotificationType9=class extends i{static{o(this,`NotificationType9`)}constructor(e){super(e,9)}};var a;(function(e){function n(e){let n=e;return n&&t.string(n.method)&&(t.string(n.id)||t.number(n.id))}o(n,`isRequest`),e.isRequest=n;function r(e){let n=e;return n&&t.string(n.method)&&e.id===void 0}o(r,`isNotification`),e.isNotification=r;function i(e){let n=e;return n&&(n.result!==void 0||!!n.error)&&(t.string(n.id)||t.number(n.id)||n.id===null)}o(i,`isResponse`),e.isResponse=i})(a||(e.Message=a={}))}}),xt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/linkedMap.js"(e){var t;Object.defineProperty(e,"__esModule",{value:!0}),e.LRUCache=e.LinkedMap=e.Touch=void 0;var n;(function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last})(n||(e.Touch=n={}));var r=class{static{o(this,`LinkedMap`)}constructor(){this[t]=`LinkedMap`,this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=n.None){let r=this._map.get(e);if(r)return t!==n.None&&this.touch(r,t),r.value}set(e,t,r=n.None){let i=this._map.get(e);if(i)i.value=t,r!==n.None&&this.touch(i,r);else{switch(i={key:e,value:t,next:void 0,previous:void 0},r){case n.None:this.addItemLast(i);break;case n.First:this.addItemFirst(i);break;case n.Last:this.addItemLast(i);break;default:this.addItemLast(i)}this._map.set(e,i),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw Error(`Invalid list`);let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let n=this._state,r=this._head;for(;r;){if(t?e.bind(t)(r.value,r.key,this):e(r.value,r.key,this),this._state!==n)throw Error(`LinkedMap got modified during iteration.`);r=r.next}}keys(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.key,done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}values(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.value,done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}entries(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:[t.key,t.value],done:!1};return t=t.next,e}return{value:void 0,done:!0}},`next`)};return n}[(t=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,n=this.size;for(;t&&n>e;)this._map.delete(t.key),t=t.next,n--;this._head=t,this._size=n,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw Error(`Invalid list`);this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw Error(`Invalid list`);this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw Error(`Invalid list`);e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw Error(`Invalid list`);e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,n=e.previous;if(!t||!n)throw Error(`Invalid list`);t.previous=n,n.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw Error(`Invalid list`);if(t===n.First||t===n.Last){if(t===n.First){if(e===this._head)return;let t=e.next,n=e.previous;e===this._tail?(n.next=void 0,this._tail=n):(t.previous=n,n.next=t),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===n.Last){if(e===this._tail)return;let t=e.next,n=e.previous;e===this._head?(t.previous=void 0,this._head=t):(t.previous=n,n.next=t),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,n)=>{e.push([n,t])}),e}fromJSON(e){this.clear();for(let[t,n]of e)this.set(t,n)}};e.LinkedMap=r,e.LRUCache=class extends r{static{o(this,`LRUCache`)}constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=n.AsNew){return super.get(e,t)}peek(e){return super.get(e,n.None)}set(e,t){return super.set(e,t,n.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}}}),St=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/disposable.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Disposable=void 0;var t;(function(e){function t(e){return{dispose:e}}o(t,`create`),e.create=t})(t||(e.Disposable=t={}))}}),Ct=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=void 0;var t=yt(),n;(function(e){e.Continue=0,e.Cancelled=1})(n||={}),e.SharedArraySenderStrategy=class{static{o(this,`SharedArraySenderStrategy`)}constructor(){this.buffers=new Map}enableCancellation(e){if(e.id===null)return;let t=new SharedArrayBuffer(4),r=new Int32Array(t,0,1);r[0]=n.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){let r=this.buffers.get(t);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,n.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};var r=class{static{o(this,`SharedArrayBufferCancellationToken`)}constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===n.Cancelled}get onCancellationRequested(){throw Error(`Cancellation over SharedArrayBuffer doesn't support cancellation events`)}},i=class{static{o(this,`SharedArrayBufferCancellationTokenSource`)}constructor(e){this.token=new r(e)}cancel(){}dispose(){}};e.SharedArrayReceiverStrategy=class{static{o(this,`SharedArrayReceiverStrategy`)}constructor(){this.kind=`request`}createCancellationTokenSource(e){let n=e.$cancellationData;return n===void 0?new t.CancellationTokenSource:new i(n)}}}}),wt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/semaphore.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Semaphore=void 0;var t=gt();e.Semaphore=class{static{o(this,`Semaphore`)}constructor(e=1){if(e<=0)throw Error(`Capacity must be greater than 0`);this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise((t,n)=>{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length!==0&&this._active!==this._capacity&&(0,t.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw Error(`To many thunks active`);try{let t=e.thunk();t instanceof Promise?t.then(t=>{this._active--,e.resolve(t),this.runNext()},t=>{this._active--,e.reject(t),this.runNext()}):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}}}}),Tt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageReader.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=void 0;var t=gt(),n=_t(),r=vt(),i=wt(),a;(function(e){function t(e){let t=e;return t&&n.func(t.listen)&&n.func(t.dispose)&&n.func(t.onError)&&n.func(t.onClose)&&n.func(t.onPartialMessage)}o(t,`is`),e.is=t})(a||(e.MessageReader=a={}));var s=class{static{o(this,`AbstractMessageReader`)}constructor(){this.errorEmitter=new r.Emitter,this.closeEmitter=new r.Emitter,this.partialMessageEmitter=new r.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:Error(`Reader received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageReader=s;var c;(function(e){function n(e){let n,r,i=new Map,a,o=new Map;if(e===void 0||typeof e==`string`)n=e??`utf-8`;else{if(n=e.charset??`utf-8`,e.contentDecoder!==void 0&&(r=e.contentDecoder,i.set(r.name,r)),e.contentDecoders!==void 0)for(let t of e.contentDecoders)i.set(t.name,t);if(e.contentTypeDecoder!==void 0&&(a=e.contentTypeDecoder,o.set(a.name,a)),e.contentTypeDecoders!==void 0)for(let t of e.contentTypeDecoders)o.set(t.name,t)}return a===void 0&&(a=(0,t.default)().applicationJson.decoder,o.set(a.name,a)),{charset:n,contentDecoder:r,contentDecoders:i,contentTypeDecoder:a,contentTypeDecoders:o}}o(n,`fromOptions`),e.fromOptions=n})(c||={}),e.ReadableStreamMessageReader=class extends s{static{o(this,`ReadableStreamMessageReader`)}constructor(e,n){super(),this.readable=e,this.options=c.fromOptions(n),this.buffer=(0,t.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new i.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;let t=this.readable.onData(e=>{this.onData(e)});return this.readable.onError(e=>this.fireError(e)),this.readable.onClose(()=>this.fireClose()),t}onData(e){try{for(this.buffer.append(e);;){if(this.nextMessageLength===-1){let e=this.buffer.tryReadHeaders(!0);if(!e)return;let t=e.get(`content-length`);if(!t){this.fireError(Error(`Header must provide a Content-Length property. +${JSON.stringify(Object.fromEntries(e))}`));return}let n=parseInt(t);if(isNaN(n)){this.fireError(Error(`Content-Length value must be a number. Got ${t}`));return}this.nextMessageLength=n}let e=this.buffer.tryReadBody(this.nextMessageLength);if(e===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let t=this.options.contentDecoder===void 0?e:await this.options.contentDecoder.decode(e),n=await this.options.contentTypeDecoder.decode(t,this.options);this.callback(n)}).catch(e=>{this.fireError(e)})}}catch(e){this.fireError(e)}}clearPartialMessageTimer(){this.partialMessageTimer&&=(this.partialMessageTimer.dispose(),void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,t.default)().timer.setTimeout((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}}}}),Et=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageWriter.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=void 0;var t=gt(),n=_t(),r=wt(),i=vt(),a=`Content-Length: `,s=`\r +`,c;(function(e){function t(e){let t=e;return t&&n.func(t.dispose)&&n.func(t.onClose)&&n.func(t.onError)&&n.func(t.write)}o(t,`is`),e.is=t})(c||(e.MessageWriter=c={}));var l=class{static{o(this,`AbstractMessageWriter`)}constructor(){this.errorEmitter=new i.Emitter,this.closeEmitter=new i.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e,t,n){this.errorEmitter.fire([this.asError(e),t,n])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(e){return e instanceof Error?e:Error(`Writer received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageWriter=l;var u;(function(e){function n(e){return e===void 0||typeof e==`string`?{charset:e??`utf-8`,contentTypeEncoder:(0,t.default)().applicationJson.encoder}:{charset:e.charset??`utf-8`,contentEncoder:e.contentEncoder,contentTypeEncoder:e.contentTypeEncoder??(0,t.default)().applicationJson.encoder}}o(n,`fromOptions`),e.fromOptions=n})(u||={}),e.WriteableStreamMessageWriter=class extends l{static{o(this,`WriteableStreamMessageWriter`)}constructor(e,t){super(),this.writable=e,this.options=u.fromOptions(t),this.errorCount=0,this.writeSemaphore=new r.Semaphore(1),this.writable.onError(e=>this.fireError(e)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then(e=>this.options.contentEncoder===void 0?e:this.options.contentEncoder.encode(e)).then(t=>{let n=[];return n.push(a,t.byteLength.toString(),s),n.push(s),this.doWrite(e,n,t)},e=>{throw this.fireError(e),e}))}async doWrite(e,t,n){try{return await this.writable.write(t.join(``),`ascii`),this.writable.write(n)}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}}}),Dt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractMessageBuffer=void 0;var t=13,n=10,r=`\r +`;e.AbstractMessageBuffer=class{static{o(this,`AbstractMessageBuffer`)}constructor(e=`utf-8`){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e==`string`?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let i=0,a=0,o=0,s=0;row:for(;athis._totalLength)throw Error(`Cannot read so many bytes!`);if(this._chunks[0].byteLength===e){let t=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(t)}if(this._chunks[0].byteLength>e){let t=this._chunks[0],n=this.asNative(t,e);return this._chunks[0]=t.slice(e),this._totalLength-=e,n}let t=this.allocNative(e),n=0;for(;e>0;){let r=this._chunks[0];if(r.byteLength>e){let i=r.slice(0,e);t.set(i,n),n+=e,this._chunks[0]=r.slice(e),this._totalLength-=e,e-=e}else t.set(r,n),n+=r.byteLength,this._chunks.shift(),this._totalLength-=r.byteLength,e-=r.byteLength}return t}}}}),Ot=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/connection.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createMessageConnection=e.ConnectionOptions=e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.RequestCancellationReceiverStrategy=e.IdCancellationReceiverStrategy=e.ConnectionStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=e.NullLogger=e.ProgressType=e.ProgressToken=void 0;var t=gt(),n=_t(),r=bt(),i=xt(),a=vt(),s=yt(),c;(function(e){e.type=new r.NotificationType(`$/cancelRequest`)})(c||={});var l;(function(e){function t(e){return typeof e==`string`||typeof e==`number`}o(t,`is`),e.is=t})(l||(e.ProgressToken=l={}));var u;(function(e){e.type=new r.NotificationType(`$/progress`)})(u||={}),e.ProgressType=class{static{o(this,`ProgressType`)}constructor(){}};var d;(function(e){function t(e){return n.func(e)}o(t,`is`),e.is=t})(d||={}),e.NullLogger=Object.freeze({error:o(()=>{},`error`),warn:o(()=>{},`warn`),info:o(()=>{},`info`),log:o(()=>{},`log`)});var f;(function(e){e[e.Off=0]=`Off`,e[e.Messages=1]=`Messages`,e[e.Compact=2]=`Compact`,e[e.Verbose=3]=`Verbose`})(f||(e.Trace=f={}));var p;(function(e){e.Off=`off`,e.Messages=`messages`,e.Compact=`compact`,e.Verbose=`verbose`})(p||(e.TraceValues=p={})),(function(e){function t(t){if(!n.string(t))return e.Off;switch(t=t.toLowerCase(),t){case`off`:return e.Off;case`messages`:return e.Messages;case`compact`:return e.Compact;case`verbose`:return e.Verbose;default:return e.Off}}o(t,`fromString`),e.fromString=t;function r(t){switch(t){case e.Off:return`off`;case e.Messages:return`messages`;case e.Compact:return`compact`;case e.Verbose:return`verbose`;default:return`off`}}o(r,`toString`),e.toString=r})(f||(e.Trace=f={}));var m;(function(e){e.Text=`text`,e.JSON=`json`})(m||(e.TraceFormat=m={})),(function(e){function t(t){return n.string(t)?(t=t.toLowerCase(),t===`json`?e.JSON:e.Text):e.Text}o(t,`fromString`),e.fromString=t})(m||(e.TraceFormat=m={}));var h;(function(e){e.type=new r.NotificationType(`$/setTrace`)})(h||(e.SetTraceNotification=h={}));var g;(function(e){e.type=new r.NotificationType(`$/logTrace`)})(g||(e.LogTraceNotification=g={}));var _;(function(e){e[e.Closed=1]=`Closed`,e[e.Disposed=2]=`Disposed`,e[e.AlreadyListening=3]=`AlreadyListening`})(_||(e.ConnectionErrors=_={}));var v=class e extends Error{static{o(this,`ConnectionError`)}constructor(t,n){super(n),this.code=t,Object.setPrototypeOf(this,e.prototype)}};e.ConnectionError=v;var y;(function(e){function t(e){let t=e;return t&&n.func(t.cancelUndispatched)}o(t,`is`),e.is=t})(y||(e.ConnectionStrategy=y={}));var b;(function(e){function t(e){let t=e;return t&&(t.kind===void 0||t.kind===`id`)&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(b||(e.IdCancellationReceiverStrategy=b={}));var x;(function(e){function t(e){let t=e;return t&&t.kind===`request`&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(x||(e.RequestCancellationReceiverStrategy=x={}));var ee;(function(e){e.Message=Object.freeze({createCancellationTokenSource(e){return new s.CancellationTokenSource}});function t(e){return b.is(e)||x.is(e)}o(t,`is`),e.is=t})(ee||(e.CancellationReceiverStrategy=ee={}));var S;(function(e){e.Message=Object.freeze({sendCancellation(e,t){return e.sendNotification(c.type,{id:t})},cleanup(e){}});function t(e){let t=e;return t&&n.func(t.sendCancellation)&&n.func(t.cleanup)}o(t,`is`),e.is=t})(S||(e.CancellationSenderStrategy=S={}));var te;(function(e){e.Message=Object.freeze({receiver:ee.Message,sender:S.Message});function t(e){let t=e;return t&&ee.is(t.receiver)&&S.is(t.sender)}o(t,`is`),e.is=t})(te||(e.CancellationStrategy=te={}));var ne;(function(e){function t(e){let t=e;return t&&n.func(t.handleMessage)}o(t,`is`),e.is=t})(ne||(e.MessageStrategy=ne={}));var C;(function(e){function t(e){let t=e;return t&&(te.is(t.cancellationStrategy)||y.is(t.connectionStrategy)||ne.is(t.messageStrategy))}o(t,`is`),e.is=t})(C||(e.ConnectionOptions=C={}));var re;(function(e){e[e.New=1]=`New`,e[e.Listening=2]=`Listening`,e[e.Closed=3]=`Closed`,e[e.Disposed=4]=`Disposed`})(re||={});function ie(p,y,x,ee){let S=x===void 0?e.NullLogger:x,C=0,ie=0,ae=0,oe,se=new Map,ce,le=new Map,ue=new Map,de,w=new i.LinkedMap,T=new Map,E=new Set,D=new Map,O=f.Off,fe=m.Text,k,pe=re.New,me=new a.Emitter,he=new a.Emitter,ge=new a.Emitter,_e=new a.Emitter,ve=new a.Emitter,ye=ee&&ee.cancellationStrategy?ee.cancellationStrategy:te.Message;function be(e){if(e===null)throw Error(`Can't send requests with id null since the response can't be correlated.`);return`req-`+e.toString()}o(be,`createRequestQueueKey`);function xe(e){return e===null?`res-unknown-`+(++ae).toString():`res-`+e.toString()}o(xe,`createResponseQueueKey`);function Se(){return`not-`+(++ie).toString()}o(Se,`createNotificationQueueKey`);function Ce(e,t){r.Message.isRequest(t)?e.set(be(t.id),t):r.Message.isResponse(t)?e.set(xe(t.id),t):e.set(Se(),t)}o(Ce,`addMessageToQueue`);function we(e){}o(we,`cancelUndispatched`);function Te(){return pe===re.Listening}o(Te,`isListening`);function Ee(){return pe===re.Closed}o(Ee,`isClosed`);function De(){return pe===re.Disposed}o(De,`isDisposed`);function Oe(){(pe===re.New||pe===re.Listening)&&(pe=re.Closed,he.fire(void 0))}o(Oe,`closeHandler`);function ke(e){me.fire([e,void 0,void 0])}o(ke,`readErrorHandler`);function Ae(e){me.fire(e)}o(Ae,`writeErrorHandler`),p.onClose(Oe),p.onError(ke),y.onClose(Oe),y.onError(Ae);function je(){de||w.size===0||(de=(0,t.default)().timer.setImmediate(()=>{de=void 0,Ne()}))}o(je,`triggerMessageQueue`);function Me(e){r.Message.isRequest(e)?Fe(e):r.Message.isNotification(e)?Le(e):r.Message.isResponse(e)?Ie(e):Re(e)}o(Me,`handleMessage`);function Ne(){if(w.size===0)return;let e=w.shift();try{let t=ee?.messageStrategy;ne.is(t)?t.handleMessage(e,Me):Me(e)}finally{je()}}o(Ne,`processMessageQueue`);let Pe=o(e=>{try{if(r.Message.isNotification(e)&&e.method===c.type.method){let t=e.params.id,n=be(t),i=w.get(n);if(r.Message.isRequest(i)){let r=ee?.connectionStrategy,a=r&&r.cancelUndispatched?r.cancelUndispatched(i,we):void 0;if(a&&(a.error!==void 0||a.result!==void 0)){w.delete(n),D.delete(t),a.id=i.id,He(a,e.method,Date.now()),y.write(a).catch(()=>S.error(`Sending response for canceled message failed.`));return}}let a=D.get(t);if(a!==void 0){a.cancel(),We(e);return}E.add(t)}Ce(w,e)}finally{je()}},`callback`);function Fe(e){if(De())return;function t(t,n,i){let a={jsonrpc:`2.0`,id:e.id};t instanceof r.ResponseError?a.error=t.toJson():a.result=t===void 0?null:t,He(a,n,i),y.write(a).catch(()=>S.error(`Sending response failed.`))}o(t,`reply`);function i(t,n,r){let i={jsonrpc:`2.0`,id:e.id,error:t.toJson()};He(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(i,`replyError`);function a(t,n,r){t===void 0&&(t=null);let i={jsonrpc:`2.0`,id:e.id,result:t};He(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(a,`replySuccess`),Ue(e);let s=se.get(e.method),c,l;s&&(c=s.type,l=s.handler);let u=Date.now();if(l||oe){let o=e.id??String(Date.now()),s=b.is(ye.receiver)?ye.receiver.createCancellationTokenSource(o):ye.receiver.createCancellationTokenSource(e);e.id!==null&&E.has(e.id)&&s.cancel(),e.id!==null&&D.set(o,s);try{let d;if(l){if(e.params===void 0){if(c!==void 0&&c.numberOfParams!==0){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines ${c.numberOfParams} params but received none.`),e.method,u);return}d=l(s.token)}else if(Array.isArray(e.params)){if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byName){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by name but received parameters by position`),e.method,u);return}d=l(...e.params,s.token)}else{if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byPosition){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by position but received parameters by name`),e.method,u);return}d=l(e.params,s.token)}}else oe&&(d=oe(e.method,e.params,s.token));let f=d;d?f.then?f.then(n=>{D.delete(o),t(n,e.method,u)},t=>{D.delete(o),t instanceof r.ResponseError?i(t,e.method,u):t&&n.string(t.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${t.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}):(D.delete(o),t(d,e.method,u)):(D.delete(o),a(d,e.method,u))}catch(a){D.delete(o),a instanceof r.ResponseError?t(a,e.method,u):a&&n.string(a.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${a.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}}else i(new r.ResponseError(r.ErrorCodes.MethodNotFound,`Unhandled method ${e.method}`),e.method,u)}o(Fe,`handleRequest`);function Ie(e){if(!De()){if(e.id===null)e.error?S.error(`Received response message without id: Error is: +${JSON.stringify(e.error,void 0,4)}`):S.error(`Received response message without id. No further error information provided.`);else{let t=e.id,n=T.get(t);if(Ge(e,n),n!==void 0){T.delete(t);try{if(e.error){let t=e.error;n.reject(new r.ResponseError(t.code,t.message,t.data))}else if(e.result!==void 0)n.resolve(e.result);else throw Error(`Should never happen.`)}catch(e){e.message?S.error(`Response handler '${n.method}' failed with message: ${e.message}`):S.error(`Response handler '${n.method}' failed unexpectedly.`)}}}}}o(Ie,`handleResponse`);function Le(e){if(De())return;let t,n;if(e.method===c.type.method){let t=e.params.id;E.delete(t),We(e);return}{let r=le.get(e.method);r&&(n=r.handler,t=r.type)}if(n||ce)try{if(We(e),n){if(e.params===void 0)t!==void 0&&t.numberOfParams!==0&&t.parameterStructures!==r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received none.`),n();else if(Array.isArray(e.params)){let i=e.params;e.method===u.type.method&&i.length===2&&l.is(i[0])?n({token:i[0],value:i[1]}):(t!==void 0&&(t.parameterStructures===r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines parameters by name but received parameters by position`),t.numberOfParams!==e.params.length&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received ${i.length} arguments`)),n(...i))}else t!==void 0&&t.parameterStructures===r.ParameterStructures.byPosition&&S.error(`Notification ${e.method} defines parameters by position but received parameters by name`),n(e.params)}else ce&&ce(e.method,e.params)}catch(t){t.message?S.error(`Notification handler '${e.method}' failed with message: ${t.message}`):S.error(`Notification handler '${e.method}' failed unexpectedly.`)}else ge.fire(e)}o(Le,`handleNotification`);function Re(e){if(!e){S.error(`Received empty message.`);return}S.error(`Received message which is neither a response nor a notification message: +${JSON.stringify(e,null,4)}`);let t=e;if(n.string(t.id)||n.number(t.id)){let e=t.id,n=T.get(e);n&&n.reject(Error(`The received response has neither a result nor an error property.`))}}o(Re,`handleInvalidMessage`);function ze(e){if(e!=null)switch(O){case f.Verbose:return JSON.stringify(e,null,4);case f.Compact:return JSON.stringify(e);default:return}}o(ze,`stringifyTrace`);function Be(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&e.params&&(t=`Params: ${ze(e.params)} + +`),k.log(`Sending request '${e.method} - (${e.id})'.`,t)}else Ke(`send-request`,e)}}o(Be,`traceSendingRequest`);function Ve(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&(t=e.params?`Params: ${ze(e.params)} + +`:`No parameters provided. + +`),k.log(`Sending notification '${e.method}'.`,t)}else Ke(`send-notification`,e)}}o(Ve,`traceSendingNotification`);function He(e,t,n){if(!(O===f.Off||!k)){if(fe===m.Text){let r;(O===f.Verbose||O===f.Compact)&&(e.error&&e.error.data?r=`Error data: ${ze(e.error.data)} + +`:e.result?r=`Result: ${ze(e.result)} + +`:e.error===void 0&&(r=`No result returned. + +`)),k.log(`Sending response '${t} - (${e.id})'. Processing request took ${Date.now()-n}ms`,r)}else Ke(`send-response`,e)}}o(He,`traceSendingResponse`);function Ue(e){if(!(O===f.Off||!k)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&e.params&&(t=`Params: ${ze(e.params)} + +`),k.log(`Received request '${e.method} - (${e.id})'.`,t)}else Ke(`receive-request`,e)}}o(Ue,`traceReceivedRequest`);function We(e){if(!(O===f.Off||!k||e.method===g.type.method)){if(fe===m.Text){let t;(O===f.Verbose||O===f.Compact)&&(t=e.params?`Params: ${ze(e.params)} + +`:`No parameters provided. + +`),k.log(`Received notification '${e.method}'.`,t)}else Ke(`receive-notification`,e)}}o(We,`traceReceivedNotification`);function Ge(e,t){if(!(O===f.Off||!k)){if(fe===m.Text){let n;if((O===f.Verbose||O===f.Compact)&&(e.error&&e.error.data?n=`Error data: ${ze(e.error.data)} + +`:e.result?n=`Result: ${ze(e.result)} + +`:e.error===void 0&&(n=`No result returned. + +`)),t){let r=e.error?` Request failed: ${e.error.message} (${e.error.code}).`:``;k.log(`Received response '${t.method} - (${e.id})' in ${Date.now()-t.timerStart}ms.${r}`,n)}else k.log(`Received response ${e.id} without active response promise.`,n)}else Ke(`receive-response`,e)}}o(Ge,`traceReceivedResponse`);function Ke(e,t){if(!k||O===f.Off)return;let n={isLSPMessage:!0,type:e,message:t,timestamp:Date.now()};k.log(n)}o(Ke,`logLSPMessage`);function qe(){if(Ee())throw new v(_.Closed,`Connection is closed.`);if(De())throw new v(_.Disposed,`Connection is disposed.`)}o(qe,`throwIfClosedOrDisposed`);function Je(){if(Te())throw new v(_.AlreadyListening,`Connection is already listening`)}o(Je,`throwIfListening`);function Ye(){if(!Te())throw Error(`Call listen() first.`)}o(Ye,`throwIfNotListening`);function Xe(e){return e===void 0?null:e}o(Xe,`undefinedToNull`);function Ze(e){if(e!==null)return e}o(Ze,`nullToUndefined`);function Qe(e){return e!=null&&!Array.isArray(e)&&typeof e==`object`}o(Qe,`isNamedParam`);function $e(e,t){switch(e){case r.ParameterStructures.auto:return Qe(t)?Ze(t):[Xe(t)];case r.ParameterStructures.byName:if(!Qe(t))throw Error(`Received parameters by name but param is not an object literal.`);return Ze(t);case r.ParameterStructures.byPosition:return[Xe(t)];default:throw Error(`Unknown parameter structure ${e.toString()}`)}}o($e,`computeSingleParam`);function et(e,t){let n,r=e.numberOfParams;switch(r){case 0:n=void 0;break;case 1:n=$e(e.parameterStructures,t[0]);break;default:n=[];for(let e=0;e{qe();let i,a;if(n.string(e)){i=e;let n=t[0],o=0,s=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(o=1,s=n);let c=t.length,l=c-o;switch(l){case 0:a=void 0;break;case 1:a=$e(s,t[o]);break;default:if(s===r.ParameterStructures.byName)throw Error(`Received ${l} parameters for 'by Name' notification parameter structure.`);a=t.slice(o,c).map(e=>Xe(e))}}else{let n=t;i=e.method,a=et(e,n)}let o={jsonrpc:`2.0`,method:i,params:a};return Ve(o),y.write(o).catch(e=>{throw S.error(`Sending notification failed.`),e})},`sendNotification`),onNotification:o((e,t)=>{qe();let r;return n.func(e)?ce=e:t&&(n.string(e)?(r=e,le.set(e,{type:void 0,handler:t})):(r=e.method,le.set(e.method,{type:e,handler:t}))),{dispose:o(()=>{r===void 0?ce=void 0:le.delete(r)},`dispose`)}},`onNotification`),onProgress:o((e,t,n)=>{if(ue.has(t))throw Error(`Progress handler for token ${t} already registered`);return ue.set(t,n),{dispose:o(()=>{ue.delete(t)},`dispose`)}},`onProgress`),sendProgress:o((e,t,n)=>tt.sendNotification(u.type,{token:t,value:n}),`sendProgress`),onUnhandledProgress:_e.event,sendRequest:o((e,...t)=>{qe(),Ye();let i,a,c;if(n.string(e)){i=e;let n=t[0],o=t[t.length-1],l=0,u=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(l=1,u=n);let d=t.length;s.CancellationToken.is(o)&&(--d,c=o);let f=d-l;switch(f){case 0:a=void 0;break;case 1:a=$e(u,t[l]);break;default:if(u===r.ParameterStructures.byName)throw Error(`Received ${f} parameters for 'by Name' request parameter structure.`);a=t.slice(l,d).map(e=>Xe(e))}}else{let n=t;i=e.method,a=et(e,n);let r=e.numberOfParams;c=s.CancellationToken.is(n[r])?n[r]:void 0}let l=C++,u;c&&(u=c.onCancellationRequested(()=>{let e=ye.sender.sendCancellation(tt,l);return e===void 0?(S.log(`Received no promise from cancellation strategy when cancelling id ${l}`),Promise.resolve()):e.catch(()=>{S.log(`Sending cancellation messages for id ${l} failed`)})}));let d={jsonrpc:`2.0`,id:l,method:i,params:a};return Be(d),typeof ye.sender.enableCancellation==`function`&&ye.sender.enableCancellation(d),new Promise(async(e,t)=>{let n=o(t=>{e(t),ye.sender.cleanup(l),u?.dispose()},`resolveWithCleanup`),a=o(e=>{t(e),ye.sender.cleanup(l),u?.dispose()},`rejectWithCleanup`),s={method:i,timerStart:Date.now(),resolve:n,reject:a};try{await y.write(d),T.set(l,s)}catch(e){throw S.error(`Sending request failed.`),s.reject(new r.ResponseError(r.ErrorCodes.MessageWriteError,e.message?e.message:`Unknown reason`)),e}})},`sendRequest`),onRequest:o((e,t)=>{qe();let r=null;return d.is(e)?(r=void 0,oe=e):n.string(e)?(r=null,t!==void 0&&(r=e,se.set(e,{handler:t,type:void 0}))):t!==void 0&&(r=e.method,se.set(e.method,{type:e,handler:t})),{dispose:o(()=>{r!==null&&(r===void 0?oe=void 0:se.delete(r))},`dispose`)}},`onRequest`),hasPendingResponse:o(()=>T.size>0,`hasPendingResponse`),trace:o(async(e,t,r)=>{let i=!1,a=m.Text;r!==void 0&&(n.boolean(r)?i=r:(i=r.sendNotification||!1,a=r.traceFormat||m.Text)),O=e,fe=a,k=O===f.Off?void 0:t,i&&!Ee()&&!De()&&await tt.sendNotification(h.type,{value:f.toString(e)})},`trace`),onError:me.event,onClose:he.event,onUnhandledNotification:ge.event,onDispose:ve.event,end:o(()=>{y.end()},`end`),dispose:o(()=>{if(De())return;pe=re.Disposed,ve.fire(void 0);let e=new r.ResponseError(r.ErrorCodes.PendingResponseRejected,`Pending response rejected since connection got disposed`);for(let t of T.values())t.reject(e);T=new Map,D=new Map,E=new Set,w=new i.LinkedMap,n.func(y.dispose)&&y.dispose(),n.func(p.dispose)&&p.dispose()},`dispose`),listen:o(()=>{qe(),Je(),pe=re.Listening,p.listen(Pe)},`listen`),inspect:o(()=>{(0,t.default)().console.log(`inspect`)},`inspect`)};return tt.onNotification(g.type,e=>{if(O===f.Off||!k)return;let t=O===f.Verbose||O===f.Compact;k.log(e.message,t?e.verbose:void 0)}),tt.onNotification(u.type,e=>{let t=ue.get(e.token);t?t(e.value):_e.fire(e)}),tt}o(ie,`createMessageConnection`),e.createMessageConnection=ie}}),kt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/api.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProgressType=e.ProgressToken=e.createMessageConnection=e.NullLogger=e.ConnectionOptions=e.ConnectionStrategy=e.AbstractMessageBuffer=e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=e.CancellationToken=e.CancellationTokenSource=e.Emitter=e.Event=e.Disposable=e.LRUCache=e.Touch=e.LinkedMap=e.ParameterStructures=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.ErrorCodes=e.ResponseError=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType0=e.RequestType=e.Message=e.RAL=void 0,e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=void 0;var t=bt();Object.defineProperty(e,"Message",{enumerable:!0,get:o(function(){return t.Message},`get`)}),Object.defineProperty(e,"RequestType",{enumerable:!0,get:o(function(){return t.RequestType},`get`)}),Object.defineProperty(e,"RequestType0",{enumerable:!0,get:o(function(){return t.RequestType0},`get`)}),Object.defineProperty(e,"RequestType1",{enumerable:!0,get:o(function(){return t.RequestType1},`get`)}),Object.defineProperty(e,"RequestType2",{enumerable:!0,get:o(function(){return t.RequestType2},`get`)}),Object.defineProperty(e,"RequestType3",{enumerable:!0,get:o(function(){return t.RequestType3},`get`)}),Object.defineProperty(e,"RequestType4",{enumerable:!0,get:o(function(){return t.RequestType4},`get`)}),Object.defineProperty(e,"RequestType5",{enumerable:!0,get:o(function(){return t.RequestType5},`get`)}),Object.defineProperty(e,"RequestType6",{enumerable:!0,get:o(function(){return t.RequestType6},`get`)}),Object.defineProperty(e,"RequestType7",{enumerable:!0,get:o(function(){return t.RequestType7},`get`)}),Object.defineProperty(e,"RequestType8",{enumerable:!0,get:o(function(){return t.RequestType8},`get`)}),Object.defineProperty(e,"RequestType9",{enumerable:!0,get:o(function(){return t.RequestType9},`get`)}),Object.defineProperty(e,"ResponseError",{enumerable:!0,get:o(function(){return t.ResponseError},`get`)}),Object.defineProperty(e,"ErrorCodes",{enumerable:!0,get:o(function(){return t.ErrorCodes},`get`)}),Object.defineProperty(e,"NotificationType",{enumerable:!0,get:o(function(){return t.NotificationType},`get`)}),Object.defineProperty(e,"NotificationType0",{enumerable:!0,get:o(function(){return t.NotificationType0},`get`)}),Object.defineProperty(e,"NotificationType1",{enumerable:!0,get:o(function(){return t.NotificationType1},`get`)}),Object.defineProperty(e,"NotificationType2",{enumerable:!0,get:o(function(){return t.NotificationType2},`get`)}),Object.defineProperty(e,"NotificationType3",{enumerable:!0,get:o(function(){return t.NotificationType3},`get`)}),Object.defineProperty(e,"NotificationType4",{enumerable:!0,get:o(function(){return t.NotificationType4},`get`)}),Object.defineProperty(e,"NotificationType5",{enumerable:!0,get:o(function(){return t.NotificationType5},`get`)}),Object.defineProperty(e,"NotificationType6",{enumerable:!0,get:o(function(){return t.NotificationType6},`get`)}),Object.defineProperty(e,"NotificationType7",{enumerable:!0,get:o(function(){return t.NotificationType7},`get`)}),Object.defineProperty(e,"NotificationType8",{enumerable:!0,get:o(function(){return t.NotificationType8},`get`)}),Object.defineProperty(e,"NotificationType9",{enumerable:!0,get:o(function(){return t.NotificationType9},`get`)}),Object.defineProperty(e,"ParameterStructures",{enumerable:!0,get:o(function(){return t.ParameterStructures},`get`)});var n=xt();Object.defineProperty(e,"LinkedMap",{enumerable:!0,get:o(function(){return n.LinkedMap},`get`)}),Object.defineProperty(e,"LRUCache",{enumerable:!0,get:o(function(){return n.LRUCache},`get`)}),Object.defineProperty(e,"Touch",{enumerable:!0,get:o(function(){return n.Touch},`get`)});var r=St();Object.defineProperty(e,"Disposable",{enumerable:!0,get:o(function(){return r.Disposable},`get`)});var i=vt();Object.defineProperty(e,"Event",{enumerable:!0,get:o(function(){return i.Event},`get`)}),Object.defineProperty(e,"Emitter",{enumerable:!0,get:o(function(){return i.Emitter},`get`)});var a=yt();Object.defineProperty(e,"CancellationTokenSource",{enumerable:!0,get:o(function(){return a.CancellationTokenSource},`get`)}),Object.defineProperty(e,"CancellationToken",{enumerable:!0,get:o(function(){return a.CancellationToken},`get`)});var s=Ct();Object.defineProperty(e,"SharedArraySenderStrategy",{enumerable:!0,get:o(function(){return s.SharedArraySenderStrategy},`get`)}),Object.defineProperty(e,"SharedArrayReceiverStrategy",{enumerable:!0,get:o(function(){return s.SharedArrayReceiverStrategy},`get`)});var c=Tt();Object.defineProperty(e,"MessageReader",{enumerable:!0,get:o(function(){return c.MessageReader},`get`)}),Object.defineProperty(e,"AbstractMessageReader",{enumerable:!0,get:o(function(){return c.AbstractMessageReader},`get`)}),Object.defineProperty(e,"ReadableStreamMessageReader",{enumerable:!0,get:o(function(){return c.ReadableStreamMessageReader},`get`)});var l=Et();Object.defineProperty(e,"MessageWriter",{enumerable:!0,get:o(function(){return l.MessageWriter},`get`)}),Object.defineProperty(e,"AbstractMessageWriter",{enumerable:!0,get:o(function(){return l.AbstractMessageWriter},`get`)}),Object.defineProperty(e,"WriteableStreamMessageWriter",{enumerable:!0,get:o(function(){return l.WriteableStreamMessageWriter},`get`)});var u=Dt();Object.defineProperty(e,"AbstractMessageBuffer",{enumerable:!0,get:o(function(){return u.AbstractMessageBuffer},`get`)});var d=Ot();Object.defineProperty(e,"ConnectionStrategy",{enumerable:!0,get:o(function(){return d.ConnectionStrategy},`get`)}),Object.defineProperty(e,"ConnectionOptions",{enumerable:!0,get:o(function(){return d.ConnectionOptions},`get`)}),Object.defineProperty(e,"NullLogger",{enumerable:!0,get:o(function(){return d.NullLogger},`get`)}),Object.defineProperty(e,"createMessageConnection",{enumerable:!0,get:o(function(){return d.createMessageConnection},`get`)}),Object.defineProperty(e,"ProgressToken",{enumerable:!0,get:o(function(){return d.ProgressToken},`get`)}),Object.defineProperty(e,"ProgressType",{enumerable:!0,get:o(function(){return d.ProgressType},`get`)}),Object.defineProperty(e,"Trace",{enumerable:!0,get:o(function(){return d.Trace},`get`)}),Object.defineProperty(e,"TraceValues",{enumerable:!0,get:o(function(){return d.TraceValues},`get`)}),Object.defineProperty(e,"TraceFormat",{enumerable:!0,get:o(function(){return d.TraceFormat},`get`)}),Object.defineProperty(e,"SetTraceNotification",{enumerable:!0,get:o(function(){return d.SetTraceNotification},`get`)}),Object.defineProperty(e,"LogTraceNotification",{enumerable:!0,get:o(function(){return d.LogTraceNotification},`get`)}),Object.defineProperty(e,"ConnectionErrors",{enumerable:!0,get:o(function(){return d.ConnectionErrors},`get`)}),Object.defineProperty(e,"ConnectionError",{enumerable:!0,get:o(function(){return d.ConnectionError},`get`)}),Object.defineProperty(e,"CancellationReceiverStrategy",{enumerable:!0,get:o(function(){return d.CancellationReceiverStrategy},`get`)}),Object.defineProperty(e,"CancellationSenderStrategy",{enumerable:!0,get:o(function(){return d.CancellationSenderStrategy},`get`)}),Object.defineProperty(e,"CancellationStrategy",{enumerable:!0,get:o(function(){return d.CancellationStrategy},`get`)}),Object.defineProperty(e,"MessageStrategy",{enumerable:!0,get:o(function(){return d.MessageStrategy},`get`)}),e.RAL=gt().default}}),At=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/ril.js"(e){Object.defineProperty(e,"__esModule",{value:!0});var t=kt(),n=class e extends t.AbstractMessageBuffer{static{o(this,`MessageBuffer`)}constructor(e=`utf-8`){super(e),this.asciiDecoder=new TextDecoder(`ascii`)}emptyBuffer(){return e.emptyBuffer}fromString(e,t){return new TextEncoder().encode(e)}toString(e,t){return t===`ascii`?this.asciiDecoder.decode(e):new TextDecoder(t).decode(e)}asNative(e,t){return t===void 0?e:e.slice(0,t)}allocNative(e){return new Uint8Array(e)}};n.emptyBuffer=new Uint8Array;var r=class{static{o(this,`ReadableStreamWrapper`)}constructor(e){this.socket=e,this._onData=new t.Emitter,this._messageListener=e=>{e.data.arrayBuffer().then(e=>{this._onData.fire(new Uint8Array(e))},()=>{(0,t.RAL)().console.error(`Converting blob to array buffer failed.`)})},this.socket.addEventListener(`message`,this._messageListener)}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}onData(e){return this._onData.event(e)}},i=class{static{o(this,`WritableStreamWrapper`)}constructor(e){this.socket=e}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}write(e,t){if(typeof e==`string`){if(t!==void 0&&t!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t}`);this.socket.send(e)}else this.socket.send(e);return Promise.resolve()}end(){this.socket.close()}},a=new TextEncoder,s=Object.freeze({messageBuffer:Object.freeze({create:o(e=>new n(e),`create`)}),applicationJson:Object.freeze({encoder:Object.freeze({name:`application/json`,encode:o((e,t)=>{if(t.charset!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(a.encode(JSON.stringify(e,void 0,0)))},`encode`)}),decoder:Object.freeze({name:`application/json`,decode:o((e,t)=>{if(!(e instanceof Uint8Array))throw Error(`In a Browser environments only Uint8Arrays are supported.`);return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))},`decode`)})}),stream:Object.freeze({asReadableStream:o(e=>new r(e),`asReadableStream`),asWritableStream:o(e=>new i(e),`asWritableStream`)}),console,timer:Object.freeze({setTimeout(e,t,...n){let r=setTimeout(e,t,...n);return{dispose:o(()=>clearTimeout(r),`dispose`)}},setImmediate(e,...t){let n=setTimeout(e,0,...t);return{dispose:o(()=>clearTimeout(n),`dispose`)}},setInterval(e,t,...n){let r=setInterval(e,t,...n);return{dispose:o(()=>clearInterval(r),`dispose`)}}})});function c(){return s}o(c,`RIL`),(function(e){function n(){t.RAL.install(s)}o(n,`install`),e.install=n})(c||={}),e.default=c}}),jt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.createMessageConnection=e.BrowserMessageWriter=e.BrowserMessageReader=void 0,At().default.install();var r=kt();n(kt(),e),e.BrowserMessageReader=class extends r.AbstractMessageReader{static{o(this,`BrowserMessageReader`)}constructor(e){super(),this._onData=new r.Emitter,this._messageListener=e=>{this._onData.fire(e.data)},e.addEventListener(`error`,e=>this.fireError(e)),e.onmessage=this._messageListener}listen(e){return this._onData.event(e)}},e.BrowserMessageWriter=class extends r.AbstractMessageWriter{static{o(this,`BrowserMessageWriter`)}constructor(e){super(),this.port=e,this.errorCount=0,e.addEventListener(`error`,e=>this.fireError(e))}write(e){try{return this.port.postMessage(e),Promise.resolve()}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){}};function i(e,t,n,i){return n===void 0&&(n=r.NullLogger),r.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,r.createMessageConnection)(e,t,n,i)}o(i,`createMessageConnection`),e.createMessageConnection=i}}),Mt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/browser.js"(e,t){t.exports=jt()}}),j=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProtocolNotificationType=e.ProtocolNotificationType0=e.ProtocolRequestType=e.ProtocolRequestType0=e.RegistrationType=e.MessageDirection=void 0;var t=jt(),n;(function(e){e.clientToServer=`clientToServer`,e.serverToClient=`serverToClient`,e.both=`both`})(n||(e.MessageDirection=n={})),e.RegistrationType=class{static{o(this,`RegistrationType`)}constructor(e){this.method=e}},e.ProtocolRequestType0=class extends t.RequestType0{static{o(this,`ProtocolRequestType0`)}constructor(e){super(e)}},e.ProtocolRequestType=class extends t.RequestType{static{o(this,`ProtocolRequestType`)}constructor(e){super(e,t.ParameterStructures.byName)}},e.ProtocolNotificationType0=class extends t.NotificationType0{static{o(this,`ProtocolNotificationType0`)}constructor(e){super(e)}},e.ProtocolNotificationType=class extends t.NotificationType{static{o(this,`ProtocolNotificationType`)}constructor(e){super(e,t.ParameterStructures.byName)}}}}),Nt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.objectLiteral=e.typedArray=e.stringArray=e.array=e.func=e.error=e.number=e.string=e.boolean=void 0;function t(e){return e===!0||e===!1}o(t,`boolean`),e.boolean=t;function n(e){return typeof e==`string`||e instanceof String}o(n,`string`),e.string=n;function r(e){return typeof e==`number`||e instanceof Number}o(r,`number`),e.number=r;function i(e){return e instanceof Error}o(i,`error`),e.error=i;function a(e){return typeof e==`function`}o(a,`func`),e.func=a;function s(e){return Array.isArray(e)}o(s,`array`),e.array=s;function c(e){return s(e)&&e.every(e=>n(e))}o(c,`stringArray`),e.stringArray=c;function l(e,t){return Array.isArray(e)&&e.every(t)}o(l,`typedArray`),e.typedArray=l;function u(e){return typeof e==`object`&&!!e}o(u,`objectLiteral`),e.objectLiteral=u}}),Pt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ImplementationRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/implementation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ImplementationRequest=n={}))}}),Ft=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TypeDefinitionRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/typeDefinition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeDefinitionRequest=n={}))}}),It=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DidChangeWorkspaceFoldersNotification=e.WorkspaceFoldersRequest=void 0;var t=j(),n;(function(e){e.method=`workspace/workspaceFolders`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(n||(e.WorkspaceFoldersRequest=n={}));var r;(function(e){e.method=`workspace/didChangeWorkspaceFolders`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(r||(e.DidChangeWorkspaceFoldersNotification=r={}))}}),Lt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ConfigurationRequest=void 0;var t=j(),n;(function(e){e.method=`workspace/configuration`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ConfigurationRequest=n={}))}}),Rt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ColorPresentationRequest=e.DocumentColorRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/documentColor`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DocumentColorRequest=n={}));var r;(function(e){e.method=`textDocument/colorPresentation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.ColorPresentationRequest=r={}))}}),zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.FoldingRangeRefreshRequest=e.FoldingRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/foldingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.FoldingRangeRequest=n={}));var r;(function(e){e.method=`workspace/foldingRange/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.FoldingRangeRefreshRequest=r={}))}}),Bt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DeclarationRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/declaration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DeclarationRequest=n={}))}}),Vt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SelectionRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/selectionRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.SelectionRangeRequest=n={}))}}),Ht=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorkDoneProgressCancelNotification=e.WorkDoneProgressCreateRequest=e.WorkDoneProgress=void 0;var t=jt(),n=j(),r;(function(e){e.type=new t.ProgressType;function n(t){return t===e.type}o(n,`is`),e.is=n})(r||(e.WorkDoneProgress=r={}));var i;(function(e){e.method=`window/workDoneProgress/create`,e.messageDirection=n.MessageDirection.serverToClient,e.type=new n.ProtocolRequestType(e.method)})(i||(e.WorkDoneProgressCreateRequest=i={}));var a;(function(e){e.method=`window/workDoneProgress/cancel`,e.messageDirection=n.MessageDirection.clientToServer,e.type=new n.ProtocolNotificationType(e.method)})(a||(e.WorkDoneProgressCancelNotification=a={}))}}),Ut=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CallHierarchyOutgoingCallsRequest=e.CallHierarchyIncomingCallsRequest=e.CallHierarchyPrepareRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/prepareCallHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.CallHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`callHierarchy/incomingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.CallHierarchyIncomingCallsRequest=r={}));var i;(function(e){e.method=`callHierarchy/outgoingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.CallHierarchyOutgoingCallsRequest=i={}))}}),Wt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SemanticTokensRefreshRequest=e.SemanticTokensRangeRequest=e.SemanticTokensDeltaRequest=e.SemanticTokensRequest=e.SemanticTokensRegistrationType=e.TokenFormat=void 0;var t=j(),n;(function(e){e.Relative=`relative`})(n||(e.TokenFormat=n={}));var r;(function(e){e.method=`textDocument/semanticTokens`,e.type=new t.RegistrationType(e.method)})(r||(e.SemanticTokensRegistrationType=r={}));var i;(function(e){e.method=`textDocument/semanticTokens/full`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(i||(e.SemanticTokensRequest=i={}));var a;(function(e){e.method=`textDocument/semanticTokens/full/delta`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(a||(e.SemanticTokensDeltaRequest=a={}));var o;(function(e){e.method=`textDocument/semanticTokens/range`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(o||(e.SemanticTokensRangeRequest=o={}));var s;(function(e){e.method=`workspace/semanticTokens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(s||(e.SemanticTokensRefreshRequest=s={}))}}),Gt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ShowDocumentRequest=void 0;var t=j(),n;(function(e){e.method=`window/showDocument`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ShowDocumentRequest=n={}))}}),Kt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.LinkedEditingRangeRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/linkedEditingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.LinkedEditingRangeRequest=n={}))}}),qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WillDeleteFilesRequest=e.DidDeleteFilesNotification=e.DidRenameFilesNotification=e.WillRenameFilesRequest=e.DidCreateFilesNotification=e.WillCreateFilesRequest=e.FileOperationPatternKind=void 0;var t=j(),n;(function(e){e.file=`file`,e.folder=`folder`})(n||(e.FileOperationPatternKind=n={}));var r;(function(e){e.method=`workspace/willCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.WillCreateFilesRequest=r={}));var i;(function(e){e.method=`workspace/didCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(i||(e.DidCreateFilesNotification=i={}));var a;(function(e){e.method=`workspace/willRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(a||(e.WillRenameFilesRequest=a={}));var o;(function(e){e.method=`workspace/didRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(o||(e.DidRenameFilesNotification=o={}));var s;(function(e){e.method=`workspace/didDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(s||(e.DidDeleteFilesNotification=s={}));var c;(function(e){e.method=`workspace/willDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(c||(e.WillDeleteFilesRequest=c={}))}}),Jt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MonikerRequest=e.MonikerKind=e.UniquenessLevel=void 0;var t=j(),n;(function(e){e.document=`document`,e.project=`project`,e.group=`group`,e.scheme=`scheme`,e.global=`global`})(n||(e.UniquenessLevel=n={}));var r;(function(e){e.$import=`import`,e.$export=`export`,e.local=`local`})(r||(e.MonikerKind=r={}));var i;(function(e){e.method=`textDocument/moniker`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.MonikerRequest=i={}))}}),Yt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TypeHierarchySubtypesRequest=e.TypeHierarchySupertypesRequest=e.TypeHierarchyPrepareRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/prepareTypeHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`typeHierarchy/supertypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.TypeHierarchySupertypesRequest=r={}));var i;(function(e){e.method=`typeHierarchy/subtypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.TypeHierarchySubtypesRequest=i={}))}}),Xt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.InlineValueRefreshRequest=e.InlineValueRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/inlineValue`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlineValueRequest=n={}));var r;(function(e){e.method=`workspace/inlineValue/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.InlineValueRefreshRequest=r={}))}}),Zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.InlayHintRefreshRequest=e.InlayHintResolveRequest=e.InlayHintRequest=void 0;var t=j(),n;(function(e){e.method=`textDocument/inlayHint`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlayHintRequest=n={}));var r;(function(e){e.method=`inlayHint/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.InlayHintResolveRequest=r={}));var i;(function(e){e.method=`workspace/inlayHint/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(i||(e.InlayHintRefreshRequest=i={}))}}),Qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DiagnosticRefreshRequest=e.WorkspaceDiagnosticRequest=e.DocumentDiagnosticRequest=e.DocumentDiagnosticReportKind=e.DiagnosticServerCancellationData=void 0;var t=jt(),n=Nt(),r=j(),i;(function(e){function t(e){let t=e;return t&&n.boolean(t.retriggerRequest)}o(t,`is`),e.is=t})(i||(e.DiagnosticServerCancellationData=i={}));var a;(function(e){e.Full=`full`,e.Unchanged=`unchanged`})(a||(e.DocumentDiagnosticReportKind=a={}));var s;(function(e){e.method=`textDocument/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(s||(e.DocumentDiagnosticRequest=s={}));var c;(function(e){e.method=`workspace/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(c||(e.WorkspaceDiagnosticRequest=c={}));var l;(function(e){e.method=`workspace/diagnostic/refresh`,e.messageDirection=r.MessageDirection.serverToClient,e.type=new r.ProtocolRequestType0(e.method)})(l||(e.DiagnosticRefreshRequest=l={}))}}),$t=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DidCloseNotebookDocumentNotification=e.DidSaveNotebookDocumentNotification=e.DidChangeNotebookDocumentNotification=e.NotebookCellArrayChange=e.DidOpenNotebookDocumentNotification=e.NotebookDocumentSyncRegistrationType=e.NotebookDocument=e.NotebookCell=e.ExecutionSummary=e.NotebookCellKind=void 0;var t=(ht(),p(m)),n=Nt(),r=j(),i;(function(e){e.Markup=1,e.Code=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(i||(e.NotebookCellKind=i={}));var a;(function(e){function r(e,t){let n={executionOrder:e};return(t===!0||t===!1)&&(n.success=t),n}o(r,`create`),e.create=r;function i(e){let r=e;return n.objectLiteral(r)&&t.uinteger.is(r.executionOrder)&&(r.success===void 0||n.boolean(r.success))}o(i,`is`),e.is=i;function a(e,t){return e===t?!0:e==null||t==null?!1:e.executionOrder===t.executionOrder&&e.success===t.success}o(a,`equals`),e.equals=a})(a||(e.ExecutionSummary=a={}));var s;(function(e){function r(e,t){return{kind:e,document:t}}o(r,`create`),e.create=r;function s(e){let r=e;return n.objectLiteral(r)&&i.is(r.kind)&&t.DocumentUri.is(r.document)&&(r.metadata===void 0||n.objectLiteral(r.metadata))}o(s,`is`),e.is=s;function c(e,t){let n=new Set;return e.document!==t.document&&n.add(`document`),e.kind!==t.kind&&n.add(`kind`),e.executionSummary!==t.executionSummary&&n.add(`executionSummary`),(e.metadata!==void 0||t.metadata!==void 0)&&!l(e.metadata,t.metadata)&&n.add(`metadata`),(e.executionSummary!==void 0||t.executionSummary!==void 0)&&!a.equals(e.executionSummary,t.executionSummary)&&n.add(`executionSummary`),n}o(c,`diff`),e.diff=c;function l(e,t){if(e===t)return!0;if(e==null||t==null||typeof e!=typeof t||typeof e!=`object`)return!1;let r=Array.isArray(e),i=Array.isArray(t);if(r!==i)return!1;if(r&&i){if(e.length!==t.length)return!1;for(let n=0;n0}o(t,`hasId`),e.hasId=t})(T||(e.StaticRegistrationOptions=T={}));var E;(function(e){function t(e){let t=e;return t&&(t.documentSelector===null||se.is(t.documentSelector))}o(t,`is`),e.is=t})(E||(e.TextDocumentRegistrationOptions=E={}));var D;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(t.workDoneProgress===void 0||r.boolean(t.workDoneProgress))}o(t,`is`),e.is=t;function n(e){let t=e;return t&&r.boolean(t.workDoneProgress)}o(n,`hasWorkDoneProgress`),e.hasWorkDoneProgress=n})(D||(e.WorkDoneProgressOptions=D={}));var O;(function(e){e.method=`initialize`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(O||(e.InitializeRequest=O={}));var fe;(function(e){e.unknownProtocolVersion=1})(fe||(e.InitializeErrorCodes=fe={}));var k;(function(e){e.method=`initialized`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(k||(e.InitializedNotification=k={}));var pe;(function(e){e.method=`shutdown`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType0(e.method)})(pe||(e.ShutdownRequest=pe={}));var me;(function(e){e.method=`exit`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType0(e.method)})(me||(e.ExitNotification=me={}));var he;(function(e){e.method=`workspace/didChangeConfiguration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(he||(e.DidChangeConfigurationNotification=he={}));var ge;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4,e.Debug=5})(ge||(e.MessageType=ge={}));var _e;(function(e){e.method=`window/showMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(_e||(e.ShowMessageNotification=_e={}));var ve;(function(e){e.method=`window/showMessageRequest`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(ve||(e.ShowMessageRequest=ve={}));var ye;(function(e){e.method=`window/logMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(ye||(e.LogMessageNotification=ye={}));var be;(function(e){e.method=`telemetry/event`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(be||(e.TelemetryEventNotification=be={}));var xe;(function(e){e.None=0,e.Full=1,e.Incremental=2})(xe||(e.TextDocumentSyncKind=xe={}));var Se;(function(e){e.method=`textDocument/didOpen`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Se||(e.DidOpenTextDocumentNotification=Se={}));var Ce;(function(e){function t(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}o(t,`isIncremental`),e.isIncremental=t;function n(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}o(n,`isFull`),e.isFull=n})(Ce||(e.TextDocumentContentChangeEvent=Ce={}));var we;(function(e){e.method=`textDocument/didChange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(we||(e.DidChangeTextDocumentNotification=we={}));var Te;(function(e){e.method=`textDocument/didClose`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Te||(e.DidCloseTextDocumentNotification=Te={}));var Ee;(function(e){e.method=`textDocument/didSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ee||(e.DidSaveTextDocumentNotification=Ee={}));var De;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(De||(e.TextDocumentSaveReason=De={}));var Oe;(function(e){e.method=`textDocument/willSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Oe||(e.WillSaveTextDocumentNotification=Oe={}));var ke;(function(e){e.method=`textDocument/willSaveWaitUntil`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ke||(e.WillSaveTextDocumentWaitUntilRequest=ke={}));var Ae;(function(e){e.method=`workspace/didChangeWatchedFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ae||(e.DidChangeWatchedFilesNotification=Ae={}));var je;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(je||(e.FileChangeType=je={}));var Me;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(n.URI.is(t.baseUri)||n.WorkspaceFolder.is(t.baseUri))&&r.string(t.pattern)}o(t,`is`),e.is=t})(Me||(e.RelativePattern=Me={}));var Ne;(function(e){e.Create=1,e.Change=2,e.Delete=4})(Ne||(e.WatchKind=Ne={}));var Pe;(function(e){e.method=`textDocument/publishDiagnostics`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(Pe||(e.PublishDiagnosticsNotification=Pe={}));var Fe;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(Fe||(e.CompletionTriggerKind=Fe={}));var Ie;(function(e){e.method=`textDocument/completion`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ie||(e.CompletionRequest=Ie={}));var Le;(function(e){e.method=`completionItem/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Le||(e.CompletionResolveRequest=Le={}));var Re;(function(e){e.method=`textDocument/hover`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Re||(e.HoverRequest=Re={}));var ze;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(ze||(e.SignatureHelpTriggerKind=ze={}));var Be;(function(e){e.method=`textDocument/signatureHelp`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Be||(e.SignatureHelpRequest=Be={}));var Ve;(function(e){e.method=`textDocument/definition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ve||(e.DefinitionRequest=Ve={}));var He;(function(e){e.method=`textDocument/references`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(He||(e.ReferencesRequest=He={}));var Ue;(function(e){e.method=`textDocument/documentHighlight`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ue||(e.DocumentHighlightRequest=Ue={}));var We;(function(e){e.method=`textDocument/documentSymbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(We||(e.DocumentSymbolRequest=We={}));var Ge;(function(e){e.method=`textDocument/codeAction`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ge||(e.CodeActionRequest=Ge={}));var Ke;(function(e){e.method=`codeAction/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ke||(e.CodeActionResolveRequest=Ke={}));var qe;(function(e){e.method=`workspace/symbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(qe||(e.WorkspaceSymbolRequest=qe={}));var Je;(function(e){e.method=`workspaceSymbol/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Je||(e.WorkspaceSymbolResolveRequest=Je={}));var Ye;(function(e){e.method=`textDocument/codeLens`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ye||(e.CodeLensRequest=Ye={}));var Xe;(function(e){e.method=`codeLens/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Xe||(e.CodeLensResolveRequest=Xe={}));var Ze;(function(e){e.method=`workspace/codeLens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(Ze||(e.CodeLensRefreshRequest=Ze={}));var Qe;(function(e){e.method=`textDocument/documentLink`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Qe||(e.DocumentLinkRequest=Qe={}));var $e;(function(e){e.method=`documentLink/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})($e||(e.DocumentLinkResolveRequest=$e={}));var et;(function(e){e.method=`textDocument/formatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(et||(e.DocumentFormattingRequest=et={}));var tt;(function(e){e.method=`textDocument/rangeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(tt||(e.DocumentRangeFormattingRequest=tt={}));var nt;(function(e){e.method=`textDocument/rangesFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(nt||(e.DocumentRangesFormattingRequest=nt={}));var rt;(function(e){e.method=`textDocument/onTypeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(rt||(e.DocumentOnTypeFormattingRequest=rt={}));var it;(function(e){e.Identifier=1})(it||(e.PrepareSupportDefaultBehavior=it={}));var at;(function(e){e.method=`textDocument/rename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(at||(e.RenameRequest=at={}));var ot;(function(e){e.method=`textDocument/prepareRename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ot||(e.PrepareRenameRequest=ot={}));var st;(function(e){e.method=`workspace/executeCommand`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(st||(e.ExecuteCommandRequest=st={}));var ct;(function(e){e.method=`workspace/applyEdit`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(`workspace/applyEdit`)})(ct||(e.ApplyWorkspaceEditRequest=ct={}))}}),nn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/connection.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createProtocolConnection=void 0;var t=jt();function n(e,n,r,i){return t.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,t.createMessageConnection)(e,n,r,i)}o(n,`createProtocolConnection`),e.createProtocolConnection=n}}),rn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/api.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.LSPErrorCodes=e.createProtocolConnection=void 0,n(jt(),e),n((ht(),p(m)),e),n(j(),e),n(tn(),e);var r=nn();Object.defineProperty(e,"createProtocolConnection",{enumerable:!0,get:o(function(){return r.createProtocolConnection},`get`)});var i;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(i||(e.LSPErrorCodes=i={}))}}),an=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.createProtocolConnection=void 0;var r=Mt();n(Mt(),e),n(rn(),e);function i(e,t,n,i){return(0,r.createMessageConnection)(e,t,n,i)}o(i,`createProtocolConnection`),e.createProtocolConnection=i}}),on={};l(on,{AbstractAstReflection:()=>fn,AbstractCstNode:()=>ZA,AbstractLangiumParser:()=>oj,AbstractParserErrorMessageProvider:()=>cj,AbstractThreadedAsyncParser:()=>AN,AstUtils:()=>Cn,BiMap:()=>pM,Cancellation:()=>Z,CompositeCstNodeImpl:()=>$A,ContextCache:()=>xM,CstNodeBuilder:()=>XA,CstUtils:()=>sn,DEFAULT_TOKENIZE_OPTIONS:()=>YM,DONE_RESULT:()=>bn,DatatypeSymbol:()=>nj,DefaultAstNodeDescriptionProvider:()=>RM,DefaultAstNodeLocator:()=>BM,DefaultAsyncParser:()=>kN,DefaultCommentProvider:()=>ON,DefaultConfigurationProvider:()=>HM,DefaultDocumentBuilder:()=>GM,DefaultDocumentValidator:()=>NM,DefaultHydrator:()=>NN,DefaultIndexManager:()=>KM,DefaultJsonSerializer:()=>DM,DefaultLangiumDocumentFactory:()=>aM,DefaultLangiumDocuments:()=>oM,DefaultLangiumProfiler:()=>tP,DefaultLexer:()=>XM,DefaultLexerErrorMessageProvider:()=>JM,DefaultLinker:()=>cM,DefaultNameProvider:()=>uM,DefaultReferenceDescriptionProvider:()=>zM,DefaultReferences:()=>dM,DefaultScopeComputation:()=>mM,DefaultScopeProvider:()=>wM,DefaultServiceRegistry:()=>OM,DefaultTokenBuilder:()=>Fj,DefaultValueConverter:()=>Ij,DefaultWorkspaceLock:()=>MN,DefaultWorkspaceManager:()=>qM,Deferred:()=>Kj,Disposable:()=>WM,DisposableCache:()=>yM,DocumentCache:()=>SM,DocumentState:()=>Q,DocumentValidator:()=>LM,EMPTY_SCOPE:()=>vM,EMPTY_STREAM:()=>yn,EmptyFileSystem:()=>XN,EmptyFileSystemProvider:()=>YN,ErrorWithLocation:()=>ia,GrammarAST:()=>Rn,GrammarUtils:()=>ra,IndentationAwareLexer:()=>qN,IndentationAwareTokenBuilder:()=>KN,JSDocDocumentationProvider:()=>DN,LangiumCompletionParser:()=>uj,LangiumParser:()=>sj,LangiumParserErrorMessageProvider:()=>lj,LeafCstNodeImpl:()=>QA,LexingMode:()=>GN,MapScope:()=>gM,Module:()=>IN,MultiMap:()=>fM,MultiMapScope:()=>_M,OperationCancelled:()=>Uj,ParserWorker:()=>jN,ProfilingTask:()=>nP,Reduction:()=>Sn,RefResolving:()=>sM,RegExpUtils:()=>sa,RootCstNodeImpl:()=>tj,SimpleCache:()=>bM,StreamImpl:()=>gn,StreamScope:()=>hM,TextDocument:()=>Jj,TreeStreamImpl:()=>xn,URI:()=>tM,UriTrie:()=>iM,UriUtils:()=>rM,VALIDATE_EACH_NODE:()=>MM,ValidationCategory:()=>AM,ValidationRegistry:()=>jM,ValueConverter:()=>Lj,WorkspaceCache:()=>CM,assertCondition:()=>oa,assertUnreachable:()=>aa,createCompletionParser:()=>Mj,createDefaultCoreModule:()=>PN,createDefaultSharedCoreModule:()=>FN,createGrammarConfig:()=>_o,createLangiumParser:()=>Nj,createParser:()=>mj,delayNextTick:()=>Rj,diagnosticData:()=>kM,eagerLoad:()=>zN,getDiagnosticRange:()=>PM,indentationBuilderDefaultOptions:()=>WN,inject:()=>LN,interruptAndCheck:()=>Gj,isAstNode:()=>M,isAstNodeDescription:()=>un,isAstNodeWithComment:()=>TM,isCompositeCstNode:()=>pn,isIMultiModeLexerDefinition:()=>QM,isJSDoc:()=>tN,isLeafCstNode:()=>mn,isLinkingError:()=>dn,isMultiReference:()=>ln,isNamed:()=>lM,isOperationCancelled:()=>Wj,isReference:()=>cn,isRootCstNode:()=>hn,isTokenTypeArray:()=>ZM,isTokenTypeDictionary:()=>$M,loadGrammarFromJson:()=>eP,parseJSDoc:()=>eN,prepareLangiumParser:()=>Pj,setInterruptionPeriod:()=>Hj,startCancelableOperation:()=>Vj,stream:()=>N,toDiagnosticData:()=>IM,toDiagnosticSeverity:()=>FM});var sn={};l(sn,{DefaultNameRegexp:()=>Wi,RangeComparison:()=>Vi,compareRange:()=>Hi,findCommentNode:()=>Ki,findDeclarationNodeAtOffset:()=>Gi,findLeafNodeAtOffset:()=>Ji,findLeafNodeBeforeOffset:()=>Yi,flattenCst:()=>Li,getDatatypeNode:()=>Fi,getInteriorNodes:()=>ea,getNextNode:()=>Qi,getPreviousNode:()=>Zi,getStartlineNode:()=>$i,inRange:()=>Ui,isChildNode:()=>Ri,isCommentNode:()=>qi,streamCst:()=>Ii,toDocumentSegment:()=>Bi,tokenToRange:()=>zi});function M(e){return typeof e==`object`&&!!e&&typeof e.$type==`string`}o(M,`isAstNode`);function cn(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`ref`in e}o(cn,`isReference`);function ln(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`items`in e}o(ln,`isMultiReference`);function un(e){return typeof e==`object`&&!!e&&typeof e.name==`string`&&typeof e.type==`string`&&typeof e.path==`string`}o(un,`isAstNodeDescription`);function dn(e){return typeof e==`object`&&!!e&&typeof e.info==`object`&&typeof e.message==`string`}o(dn,`isLinkingError`);var fn=class{static{o(this,`AbstractAstReflection`)}constructor(){this.subtypes={},this.allSubtypes={}}getAllTypes(){return Object.keys(this.types)}getReferenceType(e){let t=this.types[e.container.$type];if(!t)throw Error(`Type ${e.container.$type||`undefined`} not found.`);let n=t.properties[e.property]?.referenceType;if(!n)throw Error(`Property ${e.property||`undefined`} of type ${e.container.$type} is not a reference.`);return n}getTypeMetaData(e){return this.types[e]||{name:e,properties:{},superTypes:[]}}isInstance(e,t){return M(e)&&this.isSubtype(e.$type,t)}isSubtype(e,t){if(e===t)return!0;let n=this.subtypes[e];n||=this.subtypes[e]={};let r=n[t];if(r!==void 0)return r;{let r=this.types[e],i=r?r.superTypes.some(e=>this.isSubtype(e,t)):!1;return n[t]=i,i}}getAllSubTypes(e){let t=this.allSubtypes[e];if(t)return t;{let t=this.getAllTypes(),n=[];for(let r of t)this.isSubtype(r,e)&&n.push(r);return this.allSubtypes[e]=n,n}}};function pn(e){return typeof e==`object`&&!!e&&Array.isArray(e.content)}o(pn,`isCompositeCstNode`);function mn(e){return typeof e==`object`&&!!e&&typeof e.tokenType==`object`}o(mn,`isLeafCstNode`);function hn(e){return pn(e)&&typeof e.fullText==`string`}o(hn,`isRootCstNode`);var gn=class e{static{o(this,`StreamImpl`)}constructor(e,t){this.startFn=e,this.nextFn=t}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),[Symbol.iterator]:()=>e};return e}[Symbol.iterator](){return this.iterator()}isEmpty(){return!!this.iterator().next().done}count(){let e=this.iterator(),t=0,n=e.next();for(;!n.done;)t++,n=e.next();return t}toArray(){let e=[],t=this.iterator(),n;do n=t.next(),n.value!==void 0&&e.push(n.value);while(!n.done);return e}toSet(){return new Set(this)}toMap(e,t){let n=this.map(n=>[e?e(n):n,t?t(n):n]);return new Map(n)}toString(){return this.join()}concat(t){return new e(()=>({first:this.startFn(),firstDone:!1,iterator:t[Symbol.iterator]()}),e=>{let t;if(!e.firstDone){do if(t=this.nextFn(e.first),!t.done)return t;while(!t.done);e.firstDone=!0}do if(t=e.iterator.next(),!t.done)return t;while(!t.done);return bn})}join(e=`,`){let t=this.iterator(),n=``,r,i=!1;do r=t.next(),r.done||(i&&(n+=e),n+=_n(r.value)),i=!0;while(!r.done);return n}indexOf(e,t=0){let n=this.iterator(),r=0,i=n.next();for(;!i.done;){if(r>=t&&i.value===e)return r;i=n.next(),r++}return-1}every(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(!e(n.value))return!1;n=t.next()}return!0}some(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return!0;n=t.next()}return!1}forEach(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;)e(r.value,n),r=t.next(),n++}map(t){return new e(this.startFn,e=>{let{done:n,value:r}=this.nextFn(e);return n?bn:{done:!1,value:t(r)}})}filter(t){return new e(this.startFn,e=>{let n;do if(n=this.nextFn(e),!n.done&&t(n.value))return n;while(!n.done);return bn})}nonNullable(){return this.filter(e=>e!=null)}reduce(e,t){let n=this.iterator(),r=t,i=n.next();for(;!i.done;)r=r===void 0?i.value:e(r,i.value),i=n.next();return r}reduceRight(e,t){return this.recursiveReduce(this.iterator(),e,t)}recursiveReduce(e,t,n){let r=e.next();if(r.done)return n;let i=this.recursiveReduce(e,t,n);return i===void 0?r.value:t(i,r.value)}find(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return n.value;n=t.next()}}findIndex(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;){if(e(r.value))return n;r=t.next(),n++}return-1}includes(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(n.value===e)return!0;n=t.next()}return!1}flatMap(t){return new e(()=>({this:this.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:n,value:r}=this.nextFn(e.this);if(!n){let n=t(r);if(vn(n))e.iterator=n[Symbol.iterator]();else return{done:!1,value:n}}}while(e.iterator);return bn})}flat(t){if(t===void 0&&(t=1),t<=0)return this;let n=t>1?this.flat(t-1):this;return new e(()=>({this:n.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:t,value:r}=n.nextFn(e.this);if(!t){if(vn(r))e.iterator=r[Symbol.iterator]();else return{done:!1,value:r}}}while(e.iterator);return bn})}head(){let e=this.iterator().next();if(!e.done)return e.value}tail(t=1){return new e(()=>{let e=this.startFn();for(let n=0;n({size:0,state:this.startFn()}),e=>(e.size++,e.size>t?bn:this.nextFn(e.state)))}distinct(t){return new e(()=>({set:new Set,internalState:this.startFn()}),e=>{let n;do if(n=this.nextFn(e.internalState),!n.done){let r=t?t(n.value):n.value;if(!e.set.has(r))return e.set.add(r),n}while(!n.done);return bn})}exclude(e,t){let n=new Set;for(let r of e){let e=t?t(r):r;n.add(e)}return this.filter(e=>{let r=t?t(e):e;return!n.has(r)})}};function _n(e){return typeof e==`string`?e:e===void 0?`undefined`:typeof e.toString==`function`?e.toString():Object.prototype.toString.call(e)}o(_n,`toString`);function vn(e){return!!e&&typeof e[Symbol.iterator]==`function`}o(vn,`isIterable`);var yn=new gn(()=>void 0,()=>bn),bn=Object.freeze({done:!0,value:void 0});function N(...e){if(e.length===1){let t=e[0];if(t instanceof gn)return t;if(vn(t))return new gn(()=>t[Symbol.iterator](),e=>e.next());if(typeof t.length==`number`)return new gn(()=>({index:0}),e=>e.index1?new gn(()=>({collIndex:0,arrIndex:0}),t=>{do{if(t.iterator){let e=t.iterator.next();if(!e.done)return e;t.iterator=void 0}if(t.array){if(t.arrIndex({iterators:n?.includeRoot?[[e][Symbol.iterator]()]:[t(e)[Symbol.iterator]()],pruned:!1}),e=>{for(e.pruned&&=(e.iterators.pop(),!1);e.iterators.length>0;){let n=e.iterators[e.iterators.length-1].next();if(n.done)e.iterators.pop();else return e.iterators.push(t(n.value)[Symbol.iterator]()),n}return bn})}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),prune:o(()=>{e.state.pruned=!0},`prune`),[Symbol.iterator]:()=>e};return e}},Sn;(function(e){function t(e){return e.reduce((e,t)=>e+t,0)}o(t,`sum`),e.sum=t;function n(e){return e.reduce((e,t)=>e*t,0)}o(n,`product`),e.product=n;function r(e){return e.reduce((e,t)=>Math.min(e,t))}o(r,`min`),e.min=r;function i(e){return e.reduce((e,t)=>Math.max(e,t))}o(i,`max`),e.max=i})(Sn||={});var Cn={};l(Cn,{assignMandatoryProperties:()=>Fn,copyAstNode:()=>Ln,findRootNode:()=>On,getContainerOfType:()=>Tn,getDocument:()=>Dn,getReferenceNodes:()=>kn,hasContainerOfType:()=>En,linkContentToContainer:()=>wn,streamAllContents:()=>jn,streamAst:()=>Mn,streamContents:()=>An,streamReferences:()=>Pn});function wn(e,t={}){for(let[n,r]of Object.entries(e))n.startsWith(`$`)||(Array.isArray(r)?r.forEach((r,i)=>{M(r)&&(r.$container=e,r.$containerProperty=n,r.$containerIndex=i,t.deep&&wn(r,t))}):M(r)&&(r.$container=e,r.$containerProperty=n,t.deep&&wn(r,t)))}o(wn,`linkContentToContainer`);function Tn(e,t){let n=e;for(;n;){if(t(n))return n;n=n.$container}}o(Tn,`getContainerOfType`);function En(e,t){let n=e;for(;n;){if(t(n))return!0;n=n.$container}return!1}o(En,`hasContainerOfType`);function Dn(e){let t=On(e).$document;if(!t)throw Error(`AST node has no document.`);return t}o(Dn,`getDocument`);function On(e){for(;e.$container;)e=e.$container;return e}o(On,`findRootNode`);function kn(e){return cn(e)?e.ref?[e.ref]:[]:ln(e)?e.items.map(e=>e.ref):[]}o(kn,`getReferenceNodes`);function An(e,t){if(!e)throw Error(`Node must be an AstNode.`);let n=t?.range;return new gn(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndexAn(e,t))}o(jn,`streamAllContents`);function Mn(e,t){if(!e)throw Error(`Root node must be an AstNode.`);return t?.range&&!Nn(e,t.range)?new xn(e,()=>[]):new xn(e,e=>An(e,t),{includeRoot:!0})}o(Mn,`streamAst`);function Nn(e,t){if(!t)return!0;let n=e.$cstNode?.range;return n?Ui(n,t):!1}o(Nn,`isAstNodeInRange`);function Pn(e){return new gn(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndexBn,AbstractParserRule:()=>Hn,AbstractRule:()=>Wn,AbstractType:()=>Kn,Action:()=>Jn,Alternatives:()=>Xn,ArrayLiteral:()=>Qn,ArrayType:()=>er,Assignment:()=>nr,BooleanLiteral:()=>ir,CharacterRange:()=>or,Condition:()=>cr,Conjunction:()=>ur,CrossReference:()=>fr,Disjunction:()=>mr,EndOfFile:()=>gr,Grammar:()=>vr,GrammarImport:()=>br,Group:()=>Sr,InferredType:()=>wr,InfixRule:()=>Er,InfixRuleOperatorList:()=>Or,InfixRuleOperators:()=>Ar,Interface:()=>Mr,Keyword:()=>Pr,LangiumGrammarAstReflection:()=>Pi,LangiumGrammarTerminals:()=>zn,NamedArgument:()=>Ir,NegatedToken:()=>Rr,Negation:()=>Br,NumberLiteral:()=>Hr,Parameter:()=>Wr,ParameterReference:()=>Kr,ParserRule:()=>Jr,ReferenceType:()=>Xr,RegexToken:()=>Qr,ReturnType:()=>ei,RuleCall:()=>ni,SimpleType:()=>ii,StringLiteral:()=>oi,TerminalAlternatives:()=>ci,TerminalElement:()=>ui,TerminalGroup:()=>fi,TerminalRule:()=>mi,TerminalRuleCall:()=>gi,Type:()=>vi,TypeAttribute:()=>bi,TypeDefinition:()=>Si,UnionType:()=>wi,UnorderedGroup:()=>Ei,UntilToken:()=>Oi,ValueLiteral:()=>Ai,Wildcard:()=>Mi,isAbstractElement:()=>Vn,isAbstractParserRule:()=>Un,isAbstractRule:()=>Gn,isAbstractType:()=>qn,isAction:()=>Yn,isAlternatives:()=>Zn,isArrayLiteral:()=>$n,isArrayType:()=>tr,isAssignment:()=>rr,isBooleanLiteral:()=>ar,isCharacterRange:()=>sr,isCondition:()=>lr,isConjunction:()=>dr,isCrossReference:()=>pr,isDisjunction:()=>hr,isEndOfFile:()=>_r,isGrammar:()=>yr,isGrammarImport:()=>xr,isGroup:()=>Cr,isInferredType:()=>Tr,isInfixRule:()=>Dr,isInfixRuleOperatorList:()=>kr,isInfixRuleOperators:()=>jr,isInterface:()=>Nr,isKeyword:()=>Fr,isNamedArgument:()=>Lr,isNegatedToken:()=>zr,isNegation:()=>Vr,isNumberLiteral:()=>Ur,isParameter:()=>Gr,isParameterReference:()=>qr,isParserRule:()=>Yr,isReferenceType:()=>Zr,isRegexToken:()=>$r,isReturnType:()=>ti,isRuleCall:()=>ri,isSimpleType:()=>ai,isStringLiteral:()=>si,isTerminalAlternatives:()=>li,isTerminalElement:()=>di,isTerminalGroup:()=>pi,isTerminalRule:()=>hi,isTerminalRuleCall:()=>_i,isType:()=>yi,isTypeAttribute:()=>xi,isTypeDefinition:()=>Ci,isUnionType:()=>Ti,isUnorderedGroup:()=>Di,isUntilToken:()=>ki,isValueLiteral:()=>ji,isWildcard:()=>Ni,reflection:()=>P});var zn={ID:/\^?[_a-zA-Z][\w_]*/,STRING:/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'/,NUMBER:/NaN|-?((\d*\.\d+|\d+)([Ee][+-]?\d+)?|Infinity)/,RegexLiteral:/\/(?![*+?])(?:[^\r\n\[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*\])+\/[a-z]*/,WS:/\s+/,ML_COMMENT:/\/\*[\s\S]*?\*\//,SL_COMMENT:/\/\/[^\n\r]*/},Bn={$type:`AbstractElement`,cardinality:`cardinality`};function Vn(e){return P.isInstance(e,Bn.$type)}o(Vn,`isAbstractElement`);var Hn={$type:`AbstractParserRule`};function Un(e){return P.isInstance(e,Hn.$type)}o(Un,`isAbstractParserRule`);var Wn={$type:`AbstractRule`};function Gn(e){return P.isInstance(e,Wn.$type)}o(Gn,`isAbstractRule`);var Kn={$type:`AbstractType`};function qn(e){return P.isInstance(e,Kn.$type)}o(qn,`isAbstractType`);var Jn={$type:`Action`,cardinality:`cardinality`,feature:`feature`,inferredType:`inferredType`,operator:`operator`,type:`type`};function Yn(e){return P.isInstance(e,Jn.$type)}o(Yn,`isAction`);var Xn={$type:`Alternatives`,cardinality:`cardinality`,elements:`elements`};function Zn(e){return P.isInstance(e,Xn.$type)}o(Zn,`isAlternatives`);var Qn={$type:`ArrayLiteral`,elements:`elements`};function $n(e){return P.isInstance(e,Qn.$type)}o($n,`isArrayLiteral`);var er={$type:`ArrayType`,elementType:`elementType`};function tr(e){return P.isInstance(e,er.$type)}o(tr,`isArrayType`);var nr={$type:`Assignment`,cardinality:`cardinality`,feature:`feature`,operator:`operator`,predicate:`predicate`,terminal:`terminal`};function rr(e){return P.isInstance(e,nr.$type)}o(rr,`isAssignment`);var ir={$type:`BooleanLiteral`,true:`true`};function ar(e){return P.isInstance(e,ir.$type)}o(ar,`isBooleanLiteral`);var or={$type:`CharacterRange`,cardinality:`cardinality`,left:`left`,lookahead:`lookahead`,parenthesized:`parenthesized`,right:`right`};function sr(e){return P.isInstance(e,or.$type)}o(sr,`isCharacterRange`);var cr={$type:`Condition`};function lr(e){return P.isInstance(e,cr.$type)}o(lr,`isCondition`);var ur={$type:`Conjunction`,left:`left`,right:`right`};function dr(e){return P.isInstance(e,ur.$type)}o(dr,`isConjunction`);var fr={$type:`CrossReference`,cardinality:`cardinality`,deprecatedSyntax:`deprecatedSyntax`,isMulti:`isMulti`,terminal:`terminal`,type:`type`};function pr(e){return P.isInstance(e,fr.$type)}o(pr,`isCrossReference`);var mr={$type:`Disjunction`,left:`left`,right:`right`};function hr(e){return P.isInstance(e,mr.$type)}o(hr,`isDisjunction`);var gr={$type:`EndOfFile`,cardinality:`cardinality`};function _r(e){return P.isInstance(e,gr.$type)}o(_r,`isEndOfFile`);var vr={$type:`Grammar`,imports:`imports`,interfaces:`interfaces`,isDeclared:`isDeclared`,name:`name`,rules:`rules`,types:`types`};function yr(e){return P.isInstance(e,vr.$type)}o(yr,`isGrammar`);var br={$type:`GrammarImport`,path:`path`};function xr(e){return P.isInstance(e,br.$type)}o(xr,`isGrammarImport`);var Sr={$type:`Group`,cardinality:`cardinality`,elements:`elements`,guardCondition:`guardCondition`,predicate:`predicate`};function Cr(e){return P.isInstance(e,Sr.$type)}o(Cr,`isGroup`);var wr={$type:`InferredType`,name:`name`};function Tr(e){return P.isInstance(e,wr.$type)}o(Tr,`isInferredType`);var Er={$type:`InfixRule`,call:`call`,dataType:`dataType`,inferredType:`inferredType`,name:`name`,operators:`operators`,parameters:`parameters`,returnType:`returnType`};function Dr(e){return P.isInstance(e,Er.$type)}o(Dr,`isInfixRule`);var Or={$type:`InfixRuleOperatorList`,associativity:`associativity`,operators:`operators`};function kr(e){return P.isInstance(e,Or.$type)}o(kr,`isInfixRuleOperatorList`);var Ar={$type:`InfixRuleOperators`,precedences:`precedences`};function jr(e){return P.isInstance(e,Ar.$type)}o(jr,`isInfixRuleOperators`);var Mr={$type:`Interface`,attributes:`attributes`,name:`name`,superTypes:`superTypes`};function Nr(e){return P.isInstance(e,Mr.$type)}o(Nr,`isInterface`);var Pr={$type:`Keyword`,cardinality:`cardinality`,predicate:`predicate`,value:`value`};function Fr(e){return P.isInstance(e,Pr.$type)}o(Fr,`isKeyword`);var Ir={$type:`NamedArgument`,calledByName:`calledByName`,parameter:`parameter`,value:`value`};function Lr(e){return P.isInstance(e,Ir.$type)}o(Lr,`isNamedArgument`);var Rr={$type:`NegatedToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function zr(e){return P.isInstance(e,Rr.$type)}o(zr,`isNegatedToken`);var Br={$type:`Negation`,value:`value`};function Vr(e){return P.isInstance(e,Br.$type)}o(Vr,`isNegation`);var Hr={$type:`NumberLiteral`,value:`value`};function Ur(e){return P.isInstance(e,Hr.$type)}o(Ur,`isNumberLiteral`);var Wr={$type:`Parameter`,name:`name`};function Gr(e){return P.isInstance(e,Wr.$type)}o(Gr,`isParameter`);var Kr={$type:`ParameterReference`,parameter:`parameter`};function qr(e){return P.isInstance(e,Kr.$type)}o(qr,`isParameterReference`);var Jr={$type:`ParserRule`,dataType:`dataType`,definition:`definition`,entry:`entry`,fragment:`fragment`,inferredType:`inferredType`,name:`name`,parameters:`parameters`,returnType:`returnType`};function Yr(e){return P.isInstance(e,Jr.$type)}o(Yr,`isParserRule`);var Xr={$type:`ReferenceType`,isMulti:`isMulti`,referenceType:`referenceType`};function Zr(e){return P.isInstance(e,Xr.$type)}o(Zr,`isReferenceType`);var Qr={$type:`RegexToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,regex:`regex`};function $r(e){return P.isInstance(e,Qr.$type)}o($r,`isRegexToken`);var ei={$type:`ReturnType`,name:`name`};function ti(e){return P.isInstance(e,ei.$type)}o(ti,`isReturnType`);var ni={$type:`RuleCall`,arguments:`arguments`,cardinality:`cardinality`,predicate:`predicate`,rule:`rule`};function ri(e){return P.isInstance(e,ni.$type)}o(ri,`isRuleCall`);var ii={$type:`SimpleType`,primitiveType:`primitiveType`,stringType:`stringType`,typeRef:`typeRef`};function ai(e){return P.isInstance(e,ii.$type)}o(ai,`isSimpleType`);var oi={$type:`StringLiteral`,value:`value`};function si(e){return P.isInstance(e,oi.$type)}o(si,`isStringLiteral`);var ci={$type:`TerminalAlternatives`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function li(e){return P.isInstance(e,ci.$type)}o(li,`isTerminalAlternatives`);var ui={$type:`TerminalElement`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function di(e){return P.isInstance(e,ui.$type)}o(di,`isTerminalElement`);var fi={$type:`TerminalGroup`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function pi(e){return P.isInstance(e,fi.$type)}o(pi,`isTerminalGroup`);var mi={$type:`TerminalRule`,definition:`definition`,fragment:`fragment`,hidden:`hidden`,name:`name`,type:`type`};function hi(e){return P.isInstance(e,mi.$type)}o(hi,`isTerminalRule`);var gi={$type:`TerminalRuleCall`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,rule:`rule`};function _i(e){return P.isInstance(e,gi.$type)}o(_i,`isTerminalRuleCall`);var vi={$type:`Type`,name:`name`,type:`type`};function yi(e){return P.isInstance(e,vi.$type)}o(yi,`isType`);var bi={$type:`TypeAttribute`,defaultValue:`defaultValue`,isOptional:`isOptional`,name:`name`,type:`type`};function xi(e){return P.isInstance(e,bi.$type)}o(xi,`isTypeAttribute`);var Si={$type:`TypeDefinition`};function Ci(e){return P.isInstance(e,Si.$type)}o(Ci,`isTypeDefinition`);var wi={$type:`UnionType`,types:`types`};function Ti(e){return P.isInstance(e,wi.$type)}o(Ti,`isUnionType`);var Ei={$type:`UnorderedGroup`,cardinality:`cardinality`,elements:`elements`};function Di(e){return P.isInstance(e,Ei.$type)}o(Di,`isUnorderedGroup`);var Oi={$type:`UntilToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function ki(e){return P.isInstance(e,Oi.$type)}o(ki,`isUntilToken`);var Ai={$type:`ValueLiteral`};function ji(e){return P.isInstance(e,Ai.$type)}o(ji,`isValueLiteral`);var Mi={$type:`Wildcard`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function Ni(e){return P.isInstance(e,Mi.$type)}o(Ni,`isWildcard`);var Pi=class extends fn{static{o(this,`LangiumGrammarAstReflection`)}constructor(){super(...arguments),this.types={AbstractElement:{name:Bn.$type,properties:{cardinality:{name:Bn.cardinality}},superTypes:[]},AbstractParserRule:{name:Hn.$type,properties:{},superTypes:[Wn.$type,Kn.$type]},AbstractRule:{name:Wn.$type,properties:{},superTypes:[]},AbstractType:{name:Kn.$type,properties:{},superTypes:[]},Action:{name:Jn.$type,properties:{cardinality:{name:Jn.cardinality},feature:{name:Jn.feature},inferredType:{name:Jn.inferredType},operator:{name:Jn.operator},type:{name:Jn.type,referenceType:Kn.$type}},superTypes:[Bn.$type]},Alternatives:{name:Xn.$type,properties:{cardinality:{name:Xn.cardinality},elements:{name:Xn.elements,defaultValue:[]}},superTypes:[Bn.$type]},ArrayLiteral:{name:Qn.$type,properties:{elements:{name:Qn.elements,defaultValue:[]}},superTypes:[Ai.$type]},ArrayType:{name:er.$type,properties:{elementType:{name:er.elementType}},superTypes:[Si.$type]},Assignment:{name:nr.$type,properties:{cardinality:{name:nr.cardinality},feature:{name:nr.feature},operator:{name:nr.operator},predicate:{name:nr.predicate},terminal:{name:nr.terminal}},superTypes:[Bn.$type]},BooleanLiteral:{name:ir.$type,properties:{true:{name:ir.true,defaultValue:!1}},superTypes:[cr.$type,Ai.$type]},CharacterRange:{name:or.$type,properties:{cardinality:{name:or.cardinality},left:{name:or.left},lookahead:{name:or.lookahead},parenthesized:{name:or.parenthesized,defaultValue:!1},right:{name:or.right}},superTypes:[ui.$type]},Condition:{name:cr.$type,properties:{},superTypes:[]},Conjunction:{name:ur.$type,properties:{left:{name:ur.left},right:{name:ur.right}},superTypes:[cr.$type]},CrossReference:{name:fr.$type,properties:{cardinality:{name:fr.cardinality},deprecatedSyntax:{name:fr.deprecatedSyntax,defaultValue:!1},isMulti:{name:fr.isMulti,defaultValue:!1},terminal:{name:fr.terminal},type:{name:fr.type,referenceType:Kn.$type}},superTypes:[Bn.$type]},Disjunction:{name:mr.$type,properties:{left:{name:mr.left},right:{name:mr.right}},superTypes:[cr.$type]},EndOfFile:{name:gr.$type,properties:{cardinality:{name:gr.cardinality}},superTypes:[Bn.$type]},Grammar:{name:vr.$type,properties:{imports:{name:vr.imports,defaultValue:[]},interfaces:{name:vr.interfaces,defaultValue:[]},isDeclared:{name:vr.isDeclared,defaultValue:!1},name:{name:vr.name},rules:{name:vr.rules,defaultValue:[]},types:{name:vr.types,defaultValue:[]}},superTypes:[]},GrammarImport:{name:br.$type,properties:{path:{name:br.path}},superTypes:[]},Group:{name:Sr.$type,properties:{cardinality:{name:Sr.cardinality},elements:{name:Sr.elements,defaultValue:[]},guardCondition:{name:Sr.guardCondition},predicate:{name:Sr.predicate}},superTypes:[Bn.$type]},InferredType:{name:wr.$type,properties:{name:{name:wr.name}},superTypes:[Kn.$type]},InfixRule:{name:Er.$type,properties:{call:{name:Er.call},dataType:{name:Er.dataType},inferredType:{name:Er.inferredType},name:{name:Er.name},operators:{name:Er.operators},parameters:{name:Er.parameters,defaultValue:[]},returnType:{name:Er.returnType,referenceType:Kn.$type}},superTypes:[Hn.$type]},InfixRuleOperatorList:{name:Or.$type,properties:{associativity:{name:Or.associativity},operators:{name:Or.operators,defaultValue:[]}},superTypes:[]},InfixRuleOperators:{name:Ar.$type,properties:{precedences:{name:Ar.precedences,defaultValue:[]}},superTypes:[]},Interface:{name:Mr.$type,properties:{attributes:{name:Mr.attributes,defaultValue:[]},name:{name:Mr.name},superTypes:{name:Mr.superTypes,defaultValue:[],referenceType:Kn.$type}},superTypes:[Kn.$type]},Keyword:{name:Pr.$type,properties:{cardinality:{name:Pr.cardinality},predicate:{name:Pr.predicate},value:{name:Pr.value}},superTypes:[Bn.$type]},NamedArgument:{name:Ir.$type,properties:{calledByName:{name:Ir.calledByName,defaultValue:!1},parameter:{name:Ir.parameter,referenceType:Wr.$type},value:{name:Ir.value}},superTypes:[]},NegatedToken:{name:Rr.$type,properties:{cardinality:{name:Rr.cardinality},lookahead:{name:Rr.lookahead},parenthesized:{name:Rr.parenthesized,defaultValue:!1},terminal:{name:Rr.terminal}},superTypes:[ui.$type]},Negation:{name:Br.$type,properties:{value:{name:Br.value}},superTypes:[cr.$type]},NumberLiteral:{name:Hr.$type,properties:{value:{name:Hr.value}},superTypes:[Ai.$type]},Parameter:{name:Wr.$type,properties:{name:{name:Wr.name}},superTypes:[]},ParameterReference:{name:Kr.$type,properties:{parameter:{name:Kr.parameter,referenceType:Wr.$type}},superTypes:[cr.$type]},ParserRule:{name:Jr.$type,properties:{dataType:{name:Jr.dataType},definition:{name:Jr.definition},entry:{name:Jr.entry,defaultValue:!1},fragment:{name:Jr.fragment,defaultValue:!1},inferredType:{name:Jr.inferredType},name:{name:Jr.name},parameters:{name:Jr.parameters,defaultValue:[]},returnType:{name:Jr.returnType,referenceType:Kn.$type}},superTypes:[Hn.$type]},ReferenceType:{name:Xr.$type,properties:{isMulti:{name:Xr.isMulti,defaultValue:!1},referenceType:{name:Xr.referenceType}},superTypes:[Si.$type]},RegexToken:{name:Qr.$type,properties:{cardinality:{name:Qr.cardinality},lookahead:{name:Qr.lookahead},parenthesized:{name:Qr.parenthesized,defaultValue:!1},regex:{name:Qr.regex}},superTypes:[ui.$type]},ReturnType:{name:ei.$type,properties:{name:{name:ei.name}},superTypes:[]},RuleCall:{name:ni.$type,properties:{arguments:{name:ni.arguments,defaultValue:[]},cardinality:{name:ni.cardinality},predicate:{name:ni.predicate},rule:{name:ni.rule,referenceType:Wn.$type}},superTypes:[Bn.$type]},SimpleType:{name:ii.$type,properties:{primitiveType:{name:ii.primitiveType},stringType:{name:ii.stringType},typeRef:{name:ii.typeRef,referenceType:Kn.$type}},superTypes:[Si.$type]},StringLiteral:{name:oi.$type,properties:{value:{name:oi.value}},superTypes:[Ai.$type]},TerminalAlternatives:{name:ci.$type,properties:{cardinality:{name:ci.cardinality},elements:{name:ci.elements,defaultValue:[]},lookahead:{name:ci.lookahead},parenthesized:{name:ci.parenthesized,defaultValue:!1}},superTypes:[ui.$type]},TerminalElement:{name:ui.$type,properties:{cardinality:{name:ui.cardinality},lookahead:{name:ui.lookahead},parenthesized:{name:ui.parenthesized,defaultValue:!1}},superTypes:[Bn.$type]},TerminalGroup:{name:fi.$type,properties:{cardinality:{name:fi.cardinality},elements:{name:fi.elements,defaultValue:[]},lookahead:{name:fi.lookahead},parenthesized:{name:fi.parenthesized,defaultValue:!1}},superTypes:[ui.$type]},TerminalRule:{name:mi.$type,properties:{definition:{name:mi.definition},fragment:{name:mi.fragment,defaultValue:!1},hidden:{name:mi.hidden,defaultValue:!1},name:{name:mi.name},type:{name:mi.type}},superTypes:[Wn.$type]},TerminalRuleCall:{name:gi.$type,properties:{cardinality:{name:gi.cardinality},lookahead:{name:gi.lookahead},parenthesized:{name:gi.parenthesized,defaultValue:!1},rule:{name:gi.rule,referenceType:mi.$type}},superTypes:[ui.$type]},Type:{name:vi.$type,properties:{name:{name:vi.name},type:{name:vi.type}},superTypes:[Kn.$type]},TypeAttribute:{name:bi.$type,properties:{defaultValue:{name:bi.defaultValue},isOptional:{name:bi.isOptional,defaultValue:!1},name:{name:bi.name},type:{name:bi.type}},superTypes:[]},TypeDefinition:{name:Si.$type,properties:{},superTypes:[]},UnionType:{name:wi.$type,properties:{types:{name:wi.types,defaultValue:[]}},superTypes:[Si.$type]},UnorderedGroup:{name:Ei.$type,properties:{cardinality:{name:Ei.cardinality},elements:{name:Ei.elements,defaultValue:[]}},superTypes:[Bn.$type]},UntilToken:{name:Oi.$type,properties:{cardinality:{name:Oi.cardinality},lookahead:{name:Oi.lookahead},parenthesized:{name:Oi.parenthesized,defaultValue:!1},terminal:{name:Oi.terminal}},superTypes:[ui.$type]},ValueLiteral:{name:Ai.$type,properties:{},superTypes:[]},Wildcard:{name:Mi.$type,properties:{cardinality:{name:Mi.cardinality},lookahead:{name:Mi.lookahead},parenthesized:{name:Mi.parenthesized,defaultValue:!1}},superTypes:[ui.$type]}}}},P=new Pi;function Fi(e){let t=e,n=!1;for(;t;){let e=Tn(t.grammarSource,Yr);if(e&&e.dataType)t=t.container,n=!0;else if(n)return t;else return}}o(Fi,`getDatatypeNode`);function Ii(e){return new xn(e,e=>pn(e)?e.content:[],{includeRoot:!0})}o(Ii,`streamCst`);function Li(e){return Ii(e).filter(mn)}o(Li,`flattenCst`);function Ri(e,t){for(;e.container;)if(e=e.container,e===t)return!0;return!1}o(Ri,`isChildNode`);function zi(e){return{start:{character:e.startColumn-1,line:e.startLine-1},end:{character:e.endColumn,line:e.endLine-1}}}o(zi,`tokenToRange`);function Bi(e){if(!e)return;let{offset:t,end:n,range:r}=e;return{range:r,offset:t,end:n,length:n-t}}o(Bi,`toDocumentSegment`);var Vi;(function(e){e[e.Before=0]=`Before`,e[e.After=1]=`After`,e[e.OverlapFront=2]=`OverlapFront`,e[e.OverlapBack=3]=`OverlapBack`,e[e.Inside=4]=`Inside`,e[e.Outside=5]=`Outside`})(Vi||={});function Hi(e,t){if(e.end.linet.end.line||e.start.line===t.end.line&&e.start.character>=t.end.character)return Vi.After;let n=e.start.line>t.start.line||e.start.line===t.start.line&&e.start.character>=t.start.character,r=e.end.lineVi.After}o(Ui,`inRange`);var Wi=/^[\w\p{L}]$/u;function Gi(e,t,n=Wi){if(e){if(t>0){let r=t-e.offset,i=e.text.charAt(r);n.test(i)||t--}return Ji(e,t)}}o(Gi,`findDeclarationNodeAtOffset`);function Ki(e,t){if(e){let n=Zi(e,!0);if(n&&qi(n,t))return n;if(hn(e)){let n=e.content.findIndex(e=>!e.hidden);for(let r=n-1;r>=0;r--){let n=e.content[r];if(qi(n,t))return n}}}}o(Ki,`findCommentNode`);function qi(e,t){return mn(e)&&t.includes(e.tokenType.name)}o(qi,`isCommentNode`);function Ji(e,t){if(mn(e))return e;if(pn(e)){let n=Xi(e,t,!1);if(n)return Ji(n,t)}}o(Ji,`findLeafNodeAtOffset`);function Yi(e,t){if(mn(e))return e;if(pn(e)){let n=Xi(e,t,!0);if(n)return Yi(n,t)}}o(Yi,`findLeafNodeBeforeOffset`);function Xi(e,t,n){let r=0,i=e.content.length-1,a;for(;r<=i;){let o=Math.floor((r+i)/2),s=e.content[o];if(s.offset<=t&&s.end>t)return s;s.end<=t?(a=n?s:void 0,r=o+1):i=o-1}return a}o(Xi,`binarySearch`);function Zi(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e);for(;r>0;){r--;let e=n.content[r];if(t||!e.hidden)return e}e=n}}o(Zi,`getPreviousNode`);function Qi(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e),i=n.content.length-1;for(;rWa,findNameAssignment:()=>Ga,findNodeForKeyword:()=>Ha,findNodeForProperty:()=>za,findNodesForKeyword:()=>Va,findNodesForKeywordInternal:()=>Ua,findNodesForProperty:()=>Ra,getActionAtElement:()=>qa,getActionType:()=>ro,getAllReachableRules:()=>Na,getAllRulesUsedForCrossReferences:()=>Fa,getCrossReferenceTerminal:()=>Ia,getEntryRule:()=>ja,getExplicitRuleType:()=>to,getHiddenRules:()=>Ma,getRuleType:()=>ao,getRuleTypeName:()=>io,getTypeName:()=>no,isArrayCardinality:()=>Ya,isArrayOperator:()=>Xa,isCommentTerminal:()=>La,isDataType:()=>$a,isDataTypeRule:()=>Za,isOptionalCardinality:()=>Ja,terminalRegex:()=>oo});var ia=class extends Error{static{o(this,`ErrorWithLocation`)}constructor(e,t){super(e?`${t} at ${e.range.start.line}:${e.range.start.character}`:t)}};function aa(e,t=`Error: Got unexpected value.`){throw Error(t)}o(aa,`assertUnreachable`);function oa(e,t=`Error: Condition is violated.`){if(!e)throw Error(t)}o(oa,`assertCondition`);var sa={};l(sa,{NEWLINE_REGEXP:()=>xa,escapeRegExp:()=>Oa,getTerminalParts:()=>wa,isMultilineComment:()=>Ta,isWhitespace:()=>Da,partialMatches:()=>ka,partialRegExp:()=>Aa,whitespaceCharacters:()=>Ea});function F(e){return e.charCodeAt(0)}o(F,`cc`);function ca(e,t){Array.isArray(e)?e.forEach(function(e){t.push(e)}):t.push(e)}o(ca,`insertToSet`);function la(e,t){if(e[t]===!0)throw`duplicate flag `+t;e[t],e[t]=!0}o(la,`addFlag`);function ua(e){if(e===void 0)throw Error(`Internal Error - Should never get here!`);return!0}o(ua,`ASSERT_EXISTS`);function da(){throw Error(`Internal Error - Should never get here!`)}o(da,`ASSERT_NEVER_REACH_HERE`);function fa(e){return e.type===`Character`}o(fa,`isCharacter`);var pa=[];for(let e=F(`0`);e<=F(`9`);e++)pa.push(e);var ma=[F(`_`)].concat(pa);for(let e=F(`a`);e<=F(`z`);e++)ma.push(e);for(let e=F(`A`);e<=F(`Z`);e++)ma.push(e);var ha=[F(` `),F(`\f`),F(` +`),F(`\r`),F(` `),F(`\v`),F(` `),F(`\xA0`),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(` `),F(`\u2028`),F(`\u2029`),F(` `),F(` `),F(` `),F(``)],ga=/[0-9a-fA-F]/,_a=/[0-9]/,va=/[1-9]/,ya=class{static{o(this,`RegExpParser`)}constructor(){this.idx=0,this.input=``,this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar(`/`);let t=this.disjunction();this.consumeChar(`/`);let n={type:`Flags`,loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case`g`:la(n,`global`);break;case`i`:la(n,`ignoreCase`);break;case`m`:la(n,`multiLine`);break;case`u`:la(n,`unicode`);break;case`y`:la(n,`sticky`)}if(this.idx!==this.input.length)throw Error(`Redundant input: `+this.input.substring(this.idx));return{type:`Pattern`,flags:n,value:t,loc:this.loc(0)}}disjunction(){let e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()===`|`;)this.consumeChar(`|`),e.push(this.alternative());return{type:`Disjunction`,value:e,loc:this.loc(t)}}alternative(){let e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:`Alternative`,value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let e=this.idx;switch(this.popChar()){case`^`:return{type:`StartAnchor`,loc:this.loc(e)};case`$`:return{type:`EndAnchor`,loc:this.loc(e)};case`\\`:switch(this.popChar()){case`b`:return{type:`WordBoundary`,loc:this.loc(e)};case`B`:return{type:`NonWordBoundary`,loc:this.loc(e)}}throw Error(`Invalid Assertion Escape`);case`(`:this.consumeChar(`?`);let t;switch(this.popChar()){case`=`:t=`Lookahead`;break;case`!`:t=`NegativeLookahead`;break;case`<`:switch(this.popChar()){case`=`:t=`Lookbehind`;break;case`!`:t=`NegativeLookbehind`}}ua(t);let n=this.disjunction();return this.consumeChar(`)`),{type:t,value:n,loc:this.loc(e)}}return da()}quantifier(e=!1){let t,n=this.idx;switch(this.popChar()){case`*`:t={atLeast:0,atMost:1/0};break;case`+`:t={atLeast:1,atMost:1/0};break;case`?`:t={atLeast:0,atMost:1};break;case`{`:let n=this.integerIncludingZero();switch(this.popChar()){case`}`:t={atLeast:n,atMost:n};break;case`,`:let e;this.isDigit()?(e=this.integerIncludingZero(),t={atLeast:n,atMost:e}):t={atLeast:n,atMost:1/0},this.consumeChar(`}`)}if(e===!0&&t===void 0)return;ua(t)}if((e!==!0||t!==void 0)&&ua(t))return this.peekChar(0)===`?`?(this.consumeChar(`?`),t.greedy=!1):t.greedy=!0,t.type=`Quantifier`,t.loc=this.loc(n),t}atom(){let e,t=this.idx;switch(this.peekChar()){case`.`:e=this.dotAll();break;case`\\`:e=this.atomEscape();break;case`[`:e=this.characterClass();break;case`(`:e=this.group()}return e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),ua(e)?(e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e):da()}dotAll(){return this.consumeChar(`.`),{type:`Set`,complement:!0,value:[F(` +`),F(`\r`),F(`\u2028`),F(`\u2029`)]}}atomEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`1`:case`2`:case`3`:case`4`:case`5`:case`6`:case`7`:case`8`:case`9`:return this.decimalEscapeAtom();case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:`GroupBackReference`,value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case`d`:e=pa;break;case`D`:e=pa,t=!0;break;case`s`:e=ha;break;case`S`:e=ha,t=!0;break;case`w`:e=ma;break;case`W`:e=ma,t=!0}return ua(e)?{type:`Set`,value:e,complement:t}:da()}controlEscapeAtom(){let e;switch(this.popChar()){case`f`:e=F(`\f`);break;case`n`:e=F(` +`);break;case`r`:e=F(`\r`);break;case`t`:e=F(` `);break;case`v`:e=F(`\v`)}return ua(e)?{type:`Character`,value:e}:da()}controlLetterEscapeAtom(){this.consumeChar(`c`);let e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error(`Invalid `);return{type:`Character`,value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar(`0`),{type:`Character`,value:F(`\0`)}}hexEscapeSequenceAtom(){return this.consumeChar(`x`),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar(`u`),this.parseHexDigits(4)}identityEscapeAtom(){return{type:`Character`,value:F(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case` +`:case`\r`:case`\u2028`:case`\u2029`:case`\\`:case`]`:throw Error(`TBD`);default:return{type:`Character`,value:F(this.popChar())}}}characterClass(){let e=[],t=!1;for(this.consumeChar(`[`),this.peekChar(0)===`^`&&(this.consumeChar(`^`),t=!0);this.isClassAtom();){let t=this.classAtom();if(t.type,fa(t)&&this.isRangeDash()){this.consumeChar(`-`);let n=this.classAtom();if(n.type,fa(n)){if(n.value=this.input.length)throw Error(`Unexpected end of input`);this.idx++}loc(e){return{begin:e,end:this.idx}}},ba=class{static{o(this,`BaseRegExpVisitor`)}visitChildren(e){for(let t in e){let n=e[t];e.hasOwnProperty(t)&&(n.type===void 0?Array.isArray(n)&&n.forEach(e=>{this.visit(e)},this):this.visit(n))}}visit(e){switch(e.type){case`Pattern`:this.visitPattern(e);break;case`Flags`:this.visitFlags(e);break;case`Disjunction`:this.visitDisjunction(e);break;case`Alternative`:this.visitAlternative(e);break;case`StartAnchor`:this.visitStartAnchor(e);break;case`EndAnchor`:this.visitEndAnchor(e);break;case`WordBoundary`:this.visitWordBoundary(e);break;case`NonWordBoundary`:this.visitNonWordBoundary(e);break;case`Lookahead`:this.visitLookahead(e);break;case`NegativeLookahead`:this.visitNegativeLookahead(e);break;case`Lookbehind`:this.visitLookbehind(e);break;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);break;case`Character`:this.visitCharacter(e);break;case`Set`:this.visitSet(e);break;case`Group`:this.visitGroup(e);break;case`GroupBackReference`:this.visitGroupBackReference(e);break;case`Quantifier`:this.visitQuantifier(e)}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},xa=/\r?\n/gm,Sa=new ya,Ca=new class extends ba{static{o(this,`TerminalRegExpVisitor`)}constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join(``)}reset(e){this.multiline=!1,this.regex=e,this.startRegexp=``,this.isStarting=!0,this.endRegexpStack=[]}visitGroup(e){e.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(e){let t=String.fromCharCode(e.value);if(!this.multiline&&t===` +`&&(this.multiline=!0),e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let e=Oa(t);this.endRegexpStack.push(e),this.isStarting&&(this.startRegexp+=e)}}visitSet(e){if(!this.multiline){let t=this.regex.substring(e.loc.begin,e.loc.end),n=new RegExp(t);this.multiline=!!` +`.match(n)}if(e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let t=this.regex.substring(e.loc.begin,e.loc.end);this.endRegexpStack.push(t),this.isStarting&&(this.startRegexp+=t)}}visitChildren(e){e.type===`Group`&&e.quantifier||super.visitChildren(e)}};function wa(e){try{typeof e!=`string`&&(e=e.source),e=`/${e}/`;let t=Sa.pattern(e),n=[];for(let r of t.value.value)Ca.reset(e),Ca.visit(r),n.push({start:Ca.startRegexp,end:Ca.endRegex});return n}catch{return[]}}o(wa,`getTerminalParts`);function Ta(e){try{return typeof e==`string`&&(e=new RegExp(e)),e=e.toString(),Ca.reset(e),Ca.visit(Sa.pattern(e)),Ca.multiline}catch{return!1}}o(Ta,`isMultilineComment`);var Ea=`\f +\r \v \xA0            \u2028\u2029   `.split(``);function Da(e){let t=typeof e==`string`?new RegExp(e):e;return Ea.some(e=>t.test(e))}o(Da,`isWhitespace`);function Oa(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}o(Oa,`escapeRegExp`);function ka(e,t){let n=Aa(e),r=t.match(n);return!!r&&r[0].length>0}o(ka,`partialMatches`);function Aa(e){typeof e==`string`&&(e=new RegExp(e));let t=e,n=e.source,r=0;function i(){let e=``,a;function s(t){e+=n.substr(r,t),r+=t}o(s,`appendRaw`);function c(t){e+=`(?:`+n.substr(r,t)+`|$)`,r+=t}for(o(c,`appendOptional`);r`,r)-r+1);break;default:c(2)}break;case`[`:a=/\[(?:\\.|.)*?\]/g,a.lastIndex=r,a=a.exec(n)||[],c(a[0].length);break;case`|`:case`^`:case`$`:case`*`:case`+`:case`?`:s(1);break;case`{`:a=/\{\d+,?\d*\}/g,a.lastIndex=r,a=a.exec(n),a?s(a[0].length):c(1);break;case`(`:if(n[r+1]===`?`)switch(n[r+2]){case`:`:e+=`(?:`,r+=3,e+=i()+`|$)`;break;case`=`:e+=`(?=`,r+=3,e+=i()+`)`;break;case`!`:a=r,r+=3,i(),e+=n.substr(a,r-a);break;case`<`:switch(n[r+3]){case`=`:case`!`:a=r,r+=4,i(),e+=n.substr(a,r-a);break;default:s(n.indexOf(`>`,r)-r+1),e+=i()+`|$)`}}else s(1),e+=i()+`|$)`;break;case`)`:return++r,e;default:c(1)}return e}return o(i,`process`),new RegExp(i(),e.flags)}o(Aa,`partialRegExp`);function ja(e){return e.rules.find(e=>Yr(e)&&e.entry)}o(ja,`getEntryRule`);function Ma(e){return e.rules.filter(e=>hi(e)&&e.hidden)}o(Ma,`getHiddenRules`);function Na(e,t){let n=new Set,r=ja(e);if(!r)return new Set(e.rules);let i=[r].concat(Ma(e));for(let e of i)Pa(e,n,t);let a=new Set;for(let t of e.rules)(n.has(t.name)||hi(t)&&t.hidden)&&a.add(t);return a}o(Na,`getAllReachableRules`);function Pa(e,t,n){t.add(e.name),jn(e).forEach(e=>{if(ri(e)||n&&_i(e)){let r=e.rule.ref;r&&!t.has(r.name)&&Pa(r,t,n)}})}o(Pa,`ruleDfs`);function Fa(e){let t=new Set;return jn(e).forEach(e=>{pr(e)&&(Yr(e.type.ref)&&t.add(e.type.ref),Tr(e.type.ref)&&Yr(e.type.ref.$container)&&t.add(e.type.ref.$container))}),t}o(Fa,`getAllRulesUsedForCrossReferences`);function Ia(e){if(e.terminal)return e.terminal;if(e.type.ref)return Ga(e.type.ref)?.terminal}o(Ia,`getCrossReferenceTerminal`);function La(e){return e.hidden&&!Da(oo(e))}o(La,`isCommentTerminal`);function Ra(e,t){return!e||!t?[]:Ba(e,t,e.astNode,!0)}o(Ra,`findNodesForProperty`);function za(e,t,n){if(!e||!t)return;let r=Ba(e,t,e.astNode,!0);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(za,`findNodeForProperty`);function Ba(e,t,n,r){if(!r){let n=Tn(e.grammarSource,rr);if(n&&n.feature===t)return[e]}return pn(e)&&e.astNode===n?e.content.flatMap(e=>Ba(e,t,n,!1)):[]}o(Ba,`findNodesForPropertyInternal`);function Va(e,t){return e?Ua(e,t,e?.astNode):[]}o(Va,`findNodesForKeyword`);function Ha(e,t,n){if(!e)return;let r=Ua(e,t,e?.astNode);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(Ha,`findNodeForKeyword`);function Ua(e,t,n){if(e.astNode!==n)return[];if(Fr(e.grammarSource)&&e.grammarSource.value===t)return[e];let r=Ii(e).iterator(),i,a=[];do if(i=r.next(),!i.done){let e=i.value;e.astNode===n?Fr(e.grammarSource)&&e.grammarSource.value===t&&a.push(e):r.prune()}while(!i.done);return a}o(Ua,`findNodesForKeywordInternal`);function Wa(e){let t=e.astNode;for(;t===e.container?.astNode;){let t=Tn(e.grammarSource,rr);if(t)return t;e=e.container}}o(Wa,`findAssignment`);function Ga(e){let t=e;return Tr(t)&&(Yn(t.$container)?t=t.$container.$container:Un(t.$container)?t=t.$container:aa(t.$container)),Ka(e,t,new Map)}o(Ga,`findNameAssignment`);function Ka(e,t,n){function r(t,r){let i;return Tn(t,rr)||(i=Ka(r,r,n)),n.set(e,i),i}if(o(r,`go`),n.has(e))return n.get(e);n.set(e,void 0);for(let i of jn(t))if(rr(i)&&i.feature.toLowerCase()===`name`)return n.set(e,i),i;else if(ri(i)&&Yr(i.rule.ref))return r(i,i.rule.ref);else if(ai(i)&&i.typeRef?.ref)return r(i,i.typeRef.ref)}o(Ka,`findNameAssignmentInternal`);function qa(e){let t=e.$container;if(Cr(t)){let n=t.elements,r=n.indexOf(e);for(let e=r-1;e>=0;e--){let t=n[e];if(Yn(t))return t;{let t=jn(n[e]).find(Yn);if(t)return t}}}if(Vn(t))return qa(t)}o(qa,`getActionAtElement`);function Ja(e,t){return e===`?`||e===`*`||Cr(t)&&!!t.guardCondition}o(Ja,`isOptionalCardinality`);function Ya(e){return e===`*`||e===`+`}o(Ya,`isArrayCardinality`);function Xa(e){return e===`+=`}o(Xa,`isArrayOperator`);function Za(e){return Qa(e,new Set)}o(Za,`isDataTypeRule`);function Qa(e,t){if(t.has(e))return!0;t.add(e);for(let n of jn(e))if(ri(n)){if(!n.rule.ref||Yr(n.rule.ref)&&!Qa(n.rule.ref,t)||Dr(n.rule.ref))return!1}else if(rr(n))return!1;else if(Yn(n))return!1;return!!e.definition}o(Qa,`isDataTypeRuleInternal`);function $a(e){return eo(e.type,new Set)}o($a,`isDataType`);function eo(e,t){if(t.has(e))return!0;if(t.add(e),tr(e)||Zr(e))return!1;if(Ti(e))return e.types.every(e=>eo(e,t));if(ai(e)){if(e.primitiveType!==void 0||e.stringType!==void 0)return!0;if(e.typeRef!==void 0){let n=e.typeRef.ref;return yi(n)?eo(n.type,t):!1}return!1}return!1}o(eo,`isDataTypeInternal`);function to(e){if(!hi(e)){if(e.inferredType)return e.inferredType.name;if(e.dataType)return e.dataType;if(e.returnType){let t=e.returnType.ref;if(t)return t.name}}}o(to,`getExplicitRuleType`);function no(e){if(Un(e))return Yr(e)&&Za(e)?e.name:to(e)??e.name;if(Nr(e)||yi(e)||ti(e))return e.name;if(Yn(e)){let t=ro(e);if(t)return t}else if(Tr(e))return e.name;throw Error(`Cannot get name of Unknown Type`)}o(no,`getTypeName`);function ro(e){if(e.inferredType)return e.inferredType.name;if(e.type?.ref)return no(e.type.ref)}o(ro,`getActionType`);function io(e){return hi(e)?e.type?.name??`string`:Yr(e)&&Za(e)?e.name:to(e)??e.name}o(io,`getRuleTypeName`);function ao(e){return hi(e)?e.type?.name??`string`:to(e)??e.name}o(ao,`getRuleType`);function oo(e){let t={s:!1,i:!1,u:!1},n=co(e.definition,t),r=Object.entries(t).filter(([,e])=>e).map(([e])=>e).join(``);return new RegExp(n,r)}o(oo,`terminalRegex`);var so=`[\\s\\S]`;function co(e,t){if(li(e))return lo(e);if(pi(e))return uo(e);if(sr(e))return mo(e);if(_i(e)){let t=e.rule.ref;if(!t)throw Error(`Missing rule reference.`);return go(co(t.definition),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}if(zr(e))return po(e);if(ki(e))return fo(e);if($r(e)){let n=e.regex.lastIndexOf(`/`),r=e.regex.substring(1,n),i=e.regex.substring(n+1);return t&&(t.i=i.includes(`i`),t.s=i.includes(`s`),t.u=i.includes(`u`)),go(r,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}if(Ni(e))return go(so,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized});throw Error(`Invalid terminal element: ${e?.$type}, ${e?.$cstNode?.text}`)}o(co,`abstractElementToRegex`);function lo(e){return go(e.elements.map(e=>co(e)).join(`|`),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(lo,`terminalAlternativesToRegex`);function uo(e){return go(e.elements.map(e=>co(e)).join(``),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(uo,`terminalGroupToRegex`);function fo(e){return go(`${so}*?${co(e.terminal)}`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(fo,`untilTokenToRegex`);function po(e){return go(`(?!${co(e.terminal)})${so}*?`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(po,`negateTokenToRegex`);function mo(e){return e.right?go(`[${ho(e.left)}-${ho(e.right)}]`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1}):go(ho(e.left),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(mo,`characterRangeToRegex`);function ho(e){return Oa(e.value)}o(ho,`keywordToRegex`);function go(e,t){return(t.parenthesized||t.lookahead||t.wrap!==!1)&&(e=`(${t.lookahead??(t.parenthesized?``:`?:`)}${e})`),t.cardinality?`${e}${t.cardinality}`:e}o(go,`withCardinality`);function _o(e){let t=[],n=e.Grammar;for(let e of n.rules)hi(e)&&La(e)&&Ta(oo(e))&&t.push(e.name);return{multilineCommentRules:t,nameRegexp:Wi}}o(_o,`createGrammarConfig`);var vo=typeof global==`object`&&global&&global.Object===Object&&global,yo=typeof self==`object`&&self&&self.Object===Object&&self,bo=vo||yo||Function(`return this`)(),xo=bo.Symbol,So=Object.prototype,Co=So.hasOwnProperty,wo=So.toString,To=xo?xo.toStringTag:void 0;function Eo(e){var t=Co.call(e,To),n=e[To];try{e[To]=void 0;var r=!0}catch{}var i=wo.call(e);return r&&(t?e[To]=n:delete e[To]),i}o(Eo,`getRawTag`);var Do=Eo,Oo=Object.prototype.toString;function ko(e){return Oo.call(e)}o(ko,`objectToString`);var Ao=ko,jo=`[object Null]`,Mo=`[object Undefined]`,No=xo?xo.toStringTag:void 0;function Po(e){return e==null?e===void 0?Mo:jo:No&&No in Object(e)?Do(e):Ao(e)}o(Po,`baseGetTag`);var Fo=Po;function Io(e){return typeof e==`object`&&!!e}o(Io,`isObjectLike`);var Lo=Io,Ro=`[object Symbol]`;function zo(e){return typeof e==`symbol`||Lo(e)&&Fo(e)==Ro}o(zo,`isSymbol`);var Bo=zo;function Vo(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n0){if(++t>=Qs)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}o(tc,`shortOut`);var nc=tc;function rc(e){return function(){return e}}o(rc,`constant`);var ic=rc,ac=(function(){try{var e=Hs(Object,`defineProperty`);return e({},``,{}),e}catch{}})(),oc=nc(ac?function(e,t){return ac(e,`toString`,{configurable:!0,enumerable:!1,value:ic(t),writable:!0})}:gs);function sc(e,t){for(var n=-1,r=e==null?0:e.length;++n-1}o(_c,`arrayIncludes`);var vc=_c,yc=9007199254740991,bc=/^(?:0|[1-9]\d*)$/;function xc(e,t){var n=typeof e;return t??=yc,!!t&&(n==`number`||n!=`symbol`&&bc.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=Lc}o(Rc,`isLength`);var zc=Rc;function Bc(e){return e!=null&&zc(e.length)&&!Ss(e)}o(Bc,`isArrayLike`);var Vc=Bc;function Hc(e,t,n){if(!ts(n))return!1;var r=typeof t;return(r==`number`?Vc(n)&&Sc(t,n.length):r==`string`&&t in n)?Ec(n[t],e):!1}o(Hc,`isIterateeCall`);var Uc=Hc;function Wc(e){return Ic(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&Uc(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r-1}o(Bu,`listCacheHas`);var Vu=Bu;function Hu(e,t){var n=this.__data__,r=Pu(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(Hu,`listCacheSet`);var Uu=Hu;function Wu(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t0&&n(s)?t>1?Pd(s,t-1,n,r,i):Ad(i,s):r||(i[i.length]=s)}return i}o(Pd,`baseFlatten`);var Fd=Pd;function Id(e){return e!=null&&e.length?Fd(e,1):[]}o(Id,`flatten`);var Ld=Id,Rd=Jl(Object.getPrototypeOf,Object);function zd(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++rs))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Lm?new jm:void 0;for(a.set(e,t),a.set(t,e);++d2?t[2]:void 0;for(i&&Uc(t[0],t[1],i)&&(r=1);++n=hg&&(a=Fm,o=!1,t=new jm(t));outer:for(;++i-1?i[a?t[s]:s]:void 0}}o(Rg,`createFind`);var zg=Rg,Bg=Math.max;function Vg(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:ms(n);return i<0&&(i=Bg(r+i,0)),uc(e,Yh(t,3),i)}o(Vg,`findIndex`);var Hg=zg(Vg);function Ug(e){return e&&e.length?e[0]:void 0}o(Ug,`head`);var Wg=Ug;function Gg(e,t){var n=-1,r=Vc(e)?Array(e.length):[];return rg(e,function(e,i,a){r[++n]=t(e,i,a)}),r}o(Gg,`baseMap`);var Kg=Gg;function qg(e,t){return(I(e)?Ho:Kg)(e,Yh(t,3))}o(qg,`map`);var B=qg;function Jg(e,t){return Fd(B(e,t),1)}o(Jg,`flatMap`);var Yg=Jg,Xg=Object.prototype.hasOwnProperty,Zg=sg(function(e,t,n){Xg.call(e,n)?e[n].push(t):wc(e,n,[t])}),Qg=Object.prototype.hasOwnProperty;function $g(e,t){return e!=null&&Qg.call(e,t)}o($g,`baseHas`);var e_=$g;function t_(e,t){return e!=null&&Fh(e,t,e_)}o(t_,`has`);var V=t_,n_=`[object String]`;function r_(e){return typeof e==`string`||!I(e)&&Lo(e)&&Fo(e)==n_}o(r_,`isString`);var i_=r_;function a_(e,t){return Ho(t,function(t){return e[t]})}o(a_,`baseValues`);var o_=a_;function s_(e){return e==null?[]:o_(e,eu(e))}o(s_,`values`);var H=s_,c_=Math.max;function l_(e,t,n,r){e=Vc(e)?e:H(e),n=n&&!r?ms(n):0;var i=e.length;return n<0&&(n=c_(i+n,0)),i_(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&gc(e,t,n)>-1}o(l_,`includes`);var u_=l_,d_=Math.max;function f_(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:ms(n);return i<0&&(i=d_(r+i,0)),gc(e,t,i)}o(f_,`indexOf`);var p_=f_,m_=`[object Map]`,h_=`[object Set]`,g_=Object.prototype.hasOwnProperty;function __(e){if(e==null)return!0;if(Vc(e)&&(I(e)||typeof e==`string`||typeof e.splice==`function`||ll(e)||Ul(e)||rl(e)))return!e.length;var t=Kf(e);if(t==m_||t==h_)return!e.size;if(Jc(e))return!Ql(e).length;for(var n in e)if(g_.call(e,n))return!1;return!0}o(__,`isEmpty`);var U=__,v_=`[object RegExp]`;function y_(e){return Lo(e)&&Fo(e)==v_}o(y_,`baseIsRegExp`);var b_=y_,x_=Vl&&Vl.isRegExp,S_=x_?Ll(x_):b_;function C_(e){return e===void 0}o(C_,`isUndefined`);var w_=C_,T_=`Expected a function`;function E_(e){if(typeof e!=`function`)throw TypeError(T_);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}o(E_,`negate`);var D_=E_;function O_(e,t,n,r){if(!ts(e))return e;t=xd(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i=G_){var l=t?null:W_(e);if(l)return Um(l);o=!1,i=Fm,c=new jm}else c=t?[]:s;outer:for(;++r{t.accept(e)})}},rv=class extends nv{static{o(this,`NonTerminal`)}constructor(e){super([]),this.idx=1,nu(this,N_(e,e=>e!==void 0))}set definition(e){}get definition(){return this.referencedRule===void 0?[]:this.referencedRule.definition}accept(e){e.visit(this)}},iv=class extends nv{static{o(this,`Rule`)}constructor(e){super(e.definition),this.orgText=``,nu(this,N_(e,e=>e!==void 0))}},av=class extends nv{static{o(this,`Alternative`)}constructor(e){super(e.definition),this.ignoreAmbiguities=!1,nu(this,N_(e,e=>e!==void 0))}},ov=class extends nv{static{o(this,`Option`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},sv=class extends nv{static{o(this,`RepetitionMandatory`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},cv=class extends nv{static{o(this,`RepetitionMandatoryWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},W=class extends nv{static{o(this,`Repetition`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},lv=class extends nv{static{o(this,`RepetitionWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},uv=class extends nv{static{o(this,`Alternation`)}get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,nu(this,N_(e,e=>e!==void 0))}},G=class{static{o(this,`Terminal`)}constructor(e){this.idx=1,nu(this,N_(e,e=>e!==void 0))}accept(e){e.visit(this)}};function dv(e){return B(e,fv)}o(dv,`serializeGrammar`);function fv(e){function t(e){return B(e,fv)}if(o(t,`convertDefinition`),e instanceof rv){let t={type:`NonTerminal`,name:e.nonTerminalName,idx:e.idx};return i_(e.label)&&(t.label=e.label),t}if(e instanceof av)return{type:`Alternative`,definition:t(e.definition)};if(e instanceof ov)return{type:`Option`,idx:e.idx,definition:t(e.definition)};if(e instanceof sv)return{type:`RepetitionMandatory`,idx:e.idx,definition:t(e.definition)};if(e instanceof cv)return{type:`RepetitionMandatoryWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof lv)return{type:`RepetitionWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof W)return{type:`Repetition`,idx:e.idx,definition:t(e.definition)};if(e instanceof uv)return{type:`Alternation`,idx:e.idx,definition:t(e.definition)};if(e instanceof G){let t={type:`Terminal`,name:e.terminalType.name,label:ev(e.terminalType),idx:e.idx};i_(e.label)&&(t.terminalLabel=e.label);let n=e.terminalType.PATTERN;return e.terminalType.PATTERN&&(t.pattern=S_(n)?n.source:n),t}if(e instanceof iv)return{type:`Rule`,name:e.name,orgText:e.orgText,definition:t(e.definition)};throw Error(`non exhaustive match`)}o(fv,`serializeProduction`);var pv=class{static{o(this,`GAstVisitor`)}visit(e){let t=e;switch(t.constructor){case rv:return this.visitNonTerminal(t);case av:return this.visitAlternative(t);case ov:return this.visitOption(t);case sv:return this.visitRepetitionMandatory(t);case cv:return this.visitRepetitionMandatoryWithSeparator(t);case lv:return this.visitRepetitionWithSeparator(t);case W:return this.visitRepetition(t);case uv:return this.visitAlternation(t);case G:return this.visitTerminal(t);case iv:return this.visitRule(t);default:throw Error(`non exhaustive match`)}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}};function mv(e){return e instanceof av||e instanceof ov||e instanceof W||e instanceof sv||e instanceof cv||e instanceof lv||e instanceof G||e instanceof iv}o(mv,`isSequenceProd`);function hv(e,t=[]){return e instanceof ov||e instanceof W||e instanceof lv?!0:e instanceof uv?U_(e.definition,e=>hv(e,t)):e instanceof rv&&u_(t,e)?!1:e instanceof nv&&(e instanceof rv&&t.push(e),Ng(e.definition,e=>hv(e,t)))}o(hv,`isOptionalProd`);function gv(e){return e instanceof uv}o(gv,`isBranchingProd`);function _v(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(_v,`getProductionDslName`);var vv=class{static{o(this,`RestWalker`)}walk(e,t=[]){z(e.definition,(n,r)=>{let i=Sg(e.definition,r+1);if(n instanceof rv)this.walkProdRef(n,i,t);else if(n instanceof G)this.walkTerminal(n,i,t);else if(n instanceof av)this.walkFlat(n,i,t);else if(n instanceof ov)this.walkOption(n,i,t);else if(n instanceof sv)this.walkAtLeastOne(n,i,t);else if(n instanceof cv)this.walkAtLeastOneSep(n,i,t);else if(n instanceof lv)this.walkManySep(n,i,t);else if(n instanceof W)this.walkMany(n,i,t);else if(n instanceof uv)this.walkOr(n,i,t);else throw Error(`non exhaustive match`)})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){let r=t.concat(n);this.walk(e,r)}walkOption(e,t,n){let r=t.concat(n);this.walk(e,r)}walkAtLeastOne(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkAtLeastOneSep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkMany(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkManySep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkOr(e,t,n){let r=t.concat(n);z(e.definition,e=>{let t=new av({definition:[e]});this.walk(t,r)})}};function yv(e,t,n){return[new ov({definition:[new G({terminalType:e.separator})].concat(e.definition)})].concat(t,n)}o(yv,`restForRepetitionWithSeparator`);function bv(e){if(e instanceof rv)return bv(e.referencedRule);if(e instanceof G)return Cv(e);if(mv(e))return xv(e);if(gv(e))return Sv(e);throw Error(`non exhaustive match`)}o(bv,`first`);function xv(e){let t=[],n=e.definition,r=0,i=n.length>r,a,o=!0;for(;i&&o;)a=n[r],o=hv(a),t=t.concat(bv(a)),r+=1,i=n.length>r;return Y_(t)}o(xv,`firstForSequence`);function Sv(e){return Y_(Ld(B(e.definition,e=>bv(e))))}o(Sv,`firstForBranching`);function Cv(e){return[e.terminalType]}o(Cv,`firstForTerminal`);var wv=`_~IN~_`,Tv=class extends vv{static{o(this,`ResyncFollowsWalker`)}constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){let r=Dv(e.referencedRule,e.idx)+this.topProd.name,i=bv(new av({definition:t.concat(n)}));this.follows[r]=i}};function Ev(e){let t={};return z(e,e=>{let n=new Tv(e).startWalking();nu(t,n)}),t}o(Ev,`computeAllProdsFollows`);function Dv(e,t){return e.name+t+wv}o(Dv,`buildBetweenProdsFollowPrefix`);var Ov={},kv=new ya;function Av(e){let t=e.toString();if(Ov.hasOwnProperty(t))return Ov[t];{let e=kv.pattern(t);return Ov[t]=e,e}}o(Av,`getRegExpAst`);function jv(){Ov={}}o(jv,`clearRegExpParserCache`);var Mv=`Complement Sets are not supported for first char optimization`,Nv=`Unable to use "first char" lexer optimizations: +`;function Pv(e,t=!1){try{let t=Av(e);return Fv(t.value,{},t.flags.ignoreCase)}catch(n){if(n.message===Mv)t&&Z_(`${Nv} Unable to optimize: < ${e.toString()} > + Complement Sets cannot be automatically optimized. + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n=``;t&&(n=` + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),X_(`${Nv} + Failed parsing: < ${e.toString()} > + Using the @chevrotain/regexp-to-ast library + Please open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}o(Pv,`getOptimizedStartCodesIndices`);function Fv(e,t,n){switch(e.type){case`Disjunction`:for(let r=0;r{if(typeof e==`number`)Iv(e,t,n);else{let r=e;if(n===!0)for(let e=r.from;e<=r.to;e++)Iv(e,t,n);else{for(let e=r.from;e<=r.to&&e=by){let e=r.from>=by?r.from:by,n=r.to,i=Sy(e),a=Sy(n);for(let e=i;e<=a;e++)t[e]=e}}}});break;case`Group`:Fv(a.value,t,n);break;default:throw Error(`Non Exhaustive Match`)}let o=a.quantifier!==void 0&&a.quantifier.atLeast===0;if(a.type===`Group`&&zv(a)===!1||a.type!==`Group`&&o===!1)break}break;default:throw Error(`non exhaustive match!`)}return H(t)}o(Fv,`firstCharOptimizedIndices`);function Iv(e,t,n){let r=Sy(e);t[r]=r,n===!0&&Lv(e,t)}o(Iv,`addOptimizedIdxToResult`);function Lv(e,t){let n=String.fromCharCode(e),r=n.toUpperCase();if(r!==n){let e=Sy(r.charCodeAt(0));t[e]=e}else{let e=n.toLowerCase();if(e!==n){let n=Sy(e.charCodeAt(0));t[n]=n}}}o(Lv,`handleIgnoreCase`);function Rv(e,t){return Hg(e.value,e=>{if(typeof e==`number`)return u_(t,e);{let n=e;return Hg(t,e=>n.from<=e&&e<=n.to)!==void 0}})}o(Rv,`findCode`);function zv(e){let t=e.quantifier;return t&&t.atLeast===0?!0:e.value?I(e.value)?Ng(e.value,zv):zv(e.value):!1}o(zv,`isWholeOptional`);var Bv=class extends ba{static{o(this,`CharCodeFinder`)}constructor(e){super(),this.targetCharCodes=e,this.found=!1}visitChildren(e){if(this.found!==!0){switch(e.type){case`Lookahead`:this.visitLookahead(e);return;case`NegativeLookahead`:this.visitNegativeLookahead(e);return;case`Lookbehind`:this.visitLookbehind(e);return;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);return}super.visitChildren(e)}}visitCharacter(e){u_(this.targetCharCodes,e.value)&&(this.found=!0)}visitSet(e){e.complement?Rv(e,this.targetCharCodes)===void 0&&(this.found=!0):Rv(e,this.targetCharCodes)!==void 0&&(this.found=!0)}};function Vv(e,t){if(t instanceof RegExp){let n=Av(t),r=new Bv(e);return r.visit(n),r.found}return Hg(t,t=>u_(e,t.charCodeAt(0)))!==void 0}o(Vv,`canMatchCharCode`);var Hv=`PATTERN`,Uv=`defaultMode`,Wv=`modes`;function Gv(e,t){t=ug(t,{debug:!1,safeMode:!1,positionTracking:`full`,lineTerminatorCharacters:[`\r`,` +`],tracer:o((e,t)=>t(),`tracer`)});let n=t.tracer;n(`initCharCodeToOptimizedIndexMap`,()=>{Cy()});let r;n(`Reject Lexer.NA`,()=>{r=z_(e,e=>e[Hv]===Vy.NA)});let i=!1,a;n(`Transform Patterns`,()=>{i=!1,a=B(r,e=>{let t=e[Hv];if(S_(t)){let e=t.source;return e.length===1&&e!==`^`&&e!==`$`&&e!==`.`&&!t.ignoreCase?e:e.length===2&&e[0]===`\\`&&!u_([`d`,`D`,`s`,`S`,`t`,`r`,`n`,`t`,`0`,`c`,`b`,`B`,`f`,`v`,`w`,`W`],e[1])?e[1]:ly(t)}if(Ss(t))return i=!0,{exec:t};if(typeof t==`object`)return i=!0,t;if(typeof t==`string`){if(t.length===1)return t;{let e=t.replace(/[\\^$.*+?()[\]{}|]/g,`\\$&`);return ly(new RegExp(e))}}throw Error(`non exhaustive match`)})});let s,c,l,u,d;n(`misc mapping`,()=>{s=B(r,e=>e.tokenTypeIdx),c=B(r,e=>{let t=e.GROUP;if(t!==Vy.SKIPPED){if(i_(t))return t;if(w_(t))return!1;throw Error(`non exhaustive match`)}}),l=B(r,e=>{let t=e.LONGER_ALT;if(t)return I(t)?B(t,e=>p_(r,e)):[p_(r,t)]}),u=B(r,e=>e.PUSH_MODE),d=B(r,e=>V(e,`POP_MODE`))});let f;n(`Line Terminator Handling`,()=>{let e=vy(t.lineTerminatorCharacters);f=B(r,e=>!1),t.positionTracking!==`onlyOffset`&&(f=B(r,t=>V(t,`LINE_BREAKS`)?!!t.LINE_BREAKS:gy(t,e)===!1&&Vv(e,t.PATTERN)))});let p,m,h,g;n(`Misc Mapping #2`,()=>{p=B(r,py),m=B(a,my),h=L_(r,(e,t)=>{let n=t.GROUP;return i_(n)&&n!==Vy.SKIPPED&&(e[n]=[]),e},{}),g=B(a,(e,t)=>({pattern:a[t],longerAlt:l[t],canLineTerminator:f[t],isCustom:p[t],short:m[t],group:c[t],push:u[t],pop:d[t],tokenTypeIdx:s[t],tokenType:r[t]}))});let _=!0,v=[];return t.safeMode||n(`First Char Optimization`,()=>{v=L_(r,(e,n,r)=>{if(typeof n.PATTERN==`string`)yy(e,Sy(n.PATTERN.charCodeAt(0)),g[r]);else if(I(n.START_CHARS_HINT)){let t;z(n.START_CHARS_HINT,n=>{let i=Sy(typeof n==`string`?n.charCodeAt(0):n);t!==i&&(t=i,yy(e,i,g[r]))})}else if(S_(n.PATTERN)){if(n.PATTERN.unicode)_=!1,t.ensureOptimizations&&X_(`${Nv} Unable to analyze < ${n.PATTERN.toString()} > pattern. + The regexp unicode flag is not currently supported by the regexp-to-ast library. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{let i=Pv(n.PATTERN,t.ensureOptimizations);U(i)&&(_=!1),z(i,t=>{yy(e,t,g[r])})}}else t.ensureOptimizations&&X_(`${Nv} TokenType: <${n.name}> is using a custom token pattern without providing parameter. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),_=!1;return e},[])}),{emptyGroups:h,patternIdxToConfig:g,charCodeToPatternIdxToConfig:v,hasCustom:i,canBeOptimized:_}}o(Gv,`analyzeTokenTypes`);function Kv(e,t){let n=[],r=Jv(e);n=n.concat(r.errors);let i=Yv(r.valid),a=i.valid;return n=n.concat(i.errors),n=n.concat(qv(a)),n=n.concat(ry(a)),n=n.concat(iy(a,t)),n=n.concat(ay(a)),n}o(Kv,`validatePatterns`);function qv(e){let t=[],n=Lg(e,e=>S_(e[Hv]));return t=t.concat(Zv(n)),t=t.concat(ey(n)),t=t.concat(ty(n)),t=t.concat(ny(n)),t=t.concat(Qv(n)),t}o(qv,`validateRegExpPattern`);function Jv(e){let t=Lg(e,e=>!V(e,Hv));return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- missing static 'PATTERN' property`,type:K.MISSING_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Jv,`findMissingPatterns`);function Yv(e){let t=Lg(e,e=>{let t=e[Hv];return!S_(t)&&!Ss(t)&&!V(t,`exec`)&&!i_(t)});return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.`,type:K.INVALID_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Yv,`findInvalidPatterns`);var Xv=/[^\\][$]/;function Zv(e){class t extends ba{static{o(this,`EndAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitEndAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return Xv.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain end of input anchor '$' + See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.EOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(Zv,`findEndOfInputAnchor`);function Qv(e){return B(Lg(e,e=>e.PATTERN.test(``)),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' must not match an empty string`,type:K.EMPTY_MATCH_PATTERN,tokenTypes:[e]}))}o(Qv,`findEmptyMatchRegExps`);var $v=/[^\\[][\^]|^\^/;function ey(e){class t extends ba{static{o(this,`StartAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitStartAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return $v.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain start of input anchor '^' + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.SOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(ey,`findStartOfInputAnchor`);function ty(e){return B(Lg(e,e=>{let t=e[Hv];return t instanceof RegExp&&(t.multiline||t.global)}),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' may NOT contain global('g') or multiline('m')`,type:K.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}))}o(ty,`findUnsupportedFlags`);function ny(e){let t=[],n=B(e,n=>L_(e,(e,r)=>n.PATTERN.source===r.PATTERN.source&&!u_(t,r)&&r.PATTERN!==Vy.NA?(t.push(r),e.push(r),e):e,[]));return n=wm(n),B(Lg(n,e=>e.length>1),e=>{let t=B(e,e=>e.name);return{message:`The same RegExp pattern ->${Wg(e).PATTERN}<-has been used in all of the following Token Types: ${t.join(`, `)} <-`,type:K.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}})}o(ny,`findDuplicatePatterns`);function ry(e){return B(Lg(e,e=>{if(!V(e,`GROUP`))return!1;let t=e.GROUP;return t!==Vy.SKIPPED&&t!==Vy.NA&&!i_(t)}),e=>({message:`Token Type: ->`+e.name+`<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String`,type:K.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}))}o(ry,`findInvalidGroupType`);function iy(e,t){return B(Lg(e,e=>e.PUSH_MODE!==void 0&&!u_(t,e.PUSH_MODE)),e=>({message:`Token Type: ->${e.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${e.PUSH_MODE}<-which does not exist`,type:K.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}))}o(iy,`findModesThatDoNotExist`);function ay(e){let t=[],n=L_(e,(e,t,n)=>{let r=t.PATTERN;return r===Vy.NA||(i_(r)?e.push({str:r,idx:n,tokenType:t}):S_(r)&&sy(r)&&e.push({str:r.source,idx:n,tokenType:t})),e},[]);return z(e,(e,r)=>{z(n,({str:n,idx:i,tokenType:a})=>{if(r${a.name}<- can never be matched. +Because it appears AFTER the Token Type ->${e.name}<-in the lexer's definition. +See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;t.push({message:n,type:K.UNREACHABLE_PATTERN,tokenTypes:[e,a]})}})}),t}o(ay,`findUnreachablePatterns`);function oy(e,t){if(S_(t)){if(cy(t))return!1;let n=t.exec(e);return n!==null&&n.index===0}if(Ss(t))return t(e,0,[],{});if(V(t,`exec`))return t.exec(e,0,[],{});if(typeof t==`string`)return t===e;throw Error(`non exhaustive match`)}o(oy,`tryToMatchStrToPattern`);function sy(e){return Hg([`.`,`\\`,`[`,`]`,`|`,`^`,`$`,`(`,`)`,`?`,`*`,`+`,`{`],t=>e.source.indexOf(t)!==-1)===void 0}o(sy,`noMetaChar`);function cy(e){return/(\(\?=)|(\(\?!)|(\(\?<=)|(\(\? property in its definition +`,type:K.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),V(e,Wv)||r.push({message:`A MultiMode Lexer cannot be initialized without a <`+Wv+`> property in its definition +`,type:K.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),V(e,Wv)&&V(e,Uv)&&!V(e.modes,e.defaultMode)&&r.push({message:`A MultiMode Lexer cannot be initialized with a ${Uv}: <${e.defaultMode}>which does not exist +`,type:K.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),V(e,Wv)&&z(e.modes,(e,t)=>{z(e,(n,i)=>{w_(n)?r.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${t}> at index: <${i}> +`,type:K.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED}):V(n,`LONGER_ALT`)&&z(I(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT],i=>{!w_(i)&&!u_(e,i)&&r.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${i.name}> on token <${n.name}> outside of mode <${t}> +`,type:K.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})})})}),r}o(uy,`performRuntimeChecks`);function dy(e,t,n){let r=[],i=!1,a=z_(wm(Ld(H(e.modes))),e=>e[Hv]===Vy.NA),o=vy(n);return t&&z(a,e=>{let t=gy(e,o);if(t!==!1){let n={message:_y(e,t),type:t.issue,tokenType:e};r.push(n)}else V(e,`LINE_BREAKS`)?e.LINE_BREAKS===!0&&(i=!0):Vv(o,e.PATTERN)&&(i=!0)}),t&&!i&&r.push({message:`Warning: No LINE_BREAKS Found. + This Lexer has been defined to track line and column information, + But none of the Token Types can be identified as matching a line terminator. + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS + for details.`,type:K.NO_LINE_BREAKS_FLAGS}),r}o(dy,`performWarningRuntimeChecks`);function fy(e){let t={};return z(eu(e),n=>{let r=e[n];if(I(r))t[n]=[];else throw Error(`non exhaustive match`)}),t}o(fy,`cloneEmptyGroups`);function py(e){let t=e.PATTERN;if(S_(t))return!1;if(Ss(t)||V(t,`exec`))return!0;if(i_(t))return!1;throw Error(`non exhaustive match`)}o(py,`isCustomPattern`);function my(e){return i_(e)&&e.length===1?e.charCodeAt(0):!1}o(my,`isShortPattern`);var hy={test:o(function(e){let t=e.length;for(let n=this.lastIndex;n Token Type + Root cause: ${t.errMsg}. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(t.issue===K.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. + The problem is in the <${e.name}> Token Type + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error(`non exhaustive match`)}o(_y,`buildLineBreakIssueMessage`);function vy(e){return B(e,e=>i_(e)?e.charCodeAt(0):e)}o(vy,`getCharCodes`);function yy(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}o(yy,`addToMapOfArrays`);var by=256,xy=[];function Sy(e){return e255?255+~~(e/255):e}}o(Cy,`initCharCodeToOptimizedIndexMap`);function wy(e,t){let n=e.tokenTypeIdx;return n===t.tokenTypeIdx||t.isParent===!0&&t.categoryMatchesMap[n]===!0}o(wy,`tokenStructuredMatcher`);function Ty(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}o(Ty,`tokenStructuredMatcherNoCategories`);var Ey=1,Dy={};function Oy(e){let t=ky(e);Ay(t),My(t),jy(t),z(t,e=>{e.isParent=e.categoryMatches.length>0})}o(Oy,`augmentTokenTypes`);function ky(e){let t=Sm(e),n=e,r=!0;for(;r;){n=wm(Ld(B(n,e=>e.CATEGORIES)));let e=vg(n,t);t=t.concat(e),U(e)?r=!1:n=e}return t}o(ky,`expandCategories`);function Ay(e){z(e,e=>{Py(e)||(Dy[Ey]=e,e.tokenTypeIdx=Ey++),Fy(e)&&!I(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),Fy(e)||(e.CATEGORIES=[]),Iy(e)||(e.categoryMatches=[]),Ly(e)||(e.categoryMatchesMap={})})}o(Ay,`assignTokenDefaultProps`);function jy(e){z(e,e=>{e.categoryMatches=[],z(e.categoryMatchesMap,(t,n)=>{e.categoryMatches.push(Dy[n].tokenTypeIdx)})})}o(jy,`assignCategoriesTokensProp`);function My(e){z(e,e=>{Ny([],e)})}o(My,`assignCategoriesMapProp`);function Ny(e,t){z(e,e=>{t.categoryMatchesMap[e.tokenTypeIdx]=!0}),z(t.CATEGORIES,n=>{let r=e.concat(t);u_(r,n)||Ny(r,n)})}o(Ny,`singleAssignCategoriesToksMap`);function Py(e){return V(e,`tokenTypeIdx`)}o(Py,`hasShortKeyProperty`);function Fy(e){return V(e,`CATEGORIES`)}o(Fy,`hasCategoriesProperty`);function Iy(e){return V(e,`categoryMatches`)}o(Iy,`hasExtendingTokensTypesProperty`);function Ly(e){return V(e,`categoryMatchesMap`)}o(Ly,`hasExtendingTokensTypesMapProperty`);function Ry(e){return V(e,`tokenTypeIdx`)}o(Ry,`isTokenType`);var zy={buildUnableToPopLexerModeMessage(e){return`Unable to pop Lexer Mode after encountering Token ->${e.image}<- The Mode Stack is empty`},buildUnexpectedCharactersMessage(e,t,n,r,i,a){return`unexpected character: ->${e.charAt(t)}<- at offset: ${t}, skipped ${n} characters.`}},K;(function(e){e[e.MISSING_PATTERN=0]=`MISSING_PATTERN`,e[e.INVALID_PATTERN=1]=`INVALID_PATTERN`,e[e.EOI_ANCHOR_FOUND=2]=`EOI_ANCHOR_FOUND`,e[e.UNSUPPORTED_FLAGS_FOUND=3]=`UNSUPPORTED_FLAGS_FOUND`,e[e.DUPLICATE_PATTERNS_FOUND=4]=`DUPLICATE_PATTERNS_FOUND`,e[e.INVALID_GROUP_TYPE_FOUND=5]=`INVALID_GROUP_TYPE_FOUND`,e[e.PUSH_MODE_DOES_NOT_EXIST=6]=`PUSH_MODE_DOES_NOT_EXIST`,e[e.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]=`MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE`,e[e.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]=`MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY`,e[e.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]=`MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST`,e[e.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]=`LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED`,e[e.SOI_ANCHOR_FOUND=11]=`SOI_ANCHOR_FOUND`,e[e.EMPTY_MATCH_PATTERN=12]=`EMPTY_MATCH_PATTERN`,e[e.NO_LINE_BREAKS_FLAGS=13]=`NO_LINE_BREAKS_FLAGS`,e[e.UNREACHABLE_PATTERN=14]=`UNREACHABLE_PATTERN`,e[e.IDENTIFY_TERMINATOR=15]=`IDENTIFY_TERMINATOR`,e[e.CUSTOM_LINE_BREAK=16]=`CUSTOM_LINE_BREAK`,e[e.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]=`MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE`})(K||={});var By={deferDefinitionErrorsHandling:!1,positionTracking:`full`,lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` +`,`\r`],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:zy,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(By);var Vy=class{static{o(this,`Lexer`)}constructor(e,t=By){if(this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(e,t)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()},typeof t==`boolean`)throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. +a boolean 2nd argument is no longer supported`);this.config=nu({},By,t);let n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof n==`number`&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT(`Lexer Constructor`,()=>{let n,r=!0;this.TRACE_INIT(`Lexer Config handling`,()=>{if(this.config.lineTerminatorsPattern===By.lineTerminatorsPattern)this.config.lineTerminatorsPattern=hy;else if(this.config.lineTerminatorCharacters===By.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error(`"safeMode" and "ensureOptimizations" flags are mutually exclusive.`);this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),I(e)?n={modes:{defaultMode:Sm(e)},defaultMode:Uv}:(r=!1,n=Sm(e))}),this.config.skipValidations===!1&&(this.TRACE_INIT(`performRuntimeChecks`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(uy(n,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT(`performWarningRuntimeChecks`,()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(dy(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),n.modes=n.modes?n.modes:{},z(n.modes,(e,t)=>{n.modes[t]=z_(e,e=>w_(e))});let i=eu(n.modes);if(z(n.modes,(e,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,()=>{if(this.modes.push(n),this.config.skipValidations===!1&&this.TRACE_INIT(`validatePatterns`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(Kv(e,i))}),U(this.lexerDefinitionErrors)){Oy(e);let r;this.TRACE_INIT(`analyzeTokenTypes`,()=>{r=Gv(e,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[n]=r.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=r.charCodeToPatternIdxToConfig,this.emptyGroups=nu({},this.emptyGroups,r.emptyGroups),this.hasCustom=r.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=r.canBeOptimized}})}),this.defaultMode=n.defaultMode,!U(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Errors detected in definition of Lexer: +`+e)}z(this.lexerDefinitionWarning,e=>{Z_(e.message)}),this.TRACE_INIT(`Choosing sub-methods implementations`,()=>{if(r&&(this.handleModes=Ys),this.trackStartLines===!1&&(this.computeNewColumn=gs),this.trackEndLines===!1&&(this.updateTokenEndLineColumnLocation=Ys),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else if(/onlyOffset/i.test(this.config.positionTracking))this.createTokenInstance=this.createOffsetOnlyToken;else throw Error(`Invalid config option: "${this.config.positionTracking}"`);this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)}),this.TRACE_INIT(`Failed Optimization Warnings`,()=>{let e=L_(this.canModeBeOptimized,(e,t,n)=>(t===!1&&e.push(n),e),[]);if(t.ensureOptimizations&&!U(e))throw Error(`Lexer Modes: < ${e.join(`, `)} > cannot be optimized. + Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. + Or inspect the console log for details on how to resolve these issues.`)}),this.TRACE_INIT(`clearRegExpParserCache`,()=>{jv()}),this.TRACE_INIT(`toFastProperties`,()=>{$_(this)})})}tokenize(e,t=this.defaultMode){if(!U(this.lexerDefinitionErrors)){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Unable to Tokenize because Errors detected in definition of Lexer: +`+e)}return this.tokenizeInternal(e,t)}tokenizeInternal(e,t){let n,r,i,a,s,c,l,u,d,f,p,m,h,g,_,v=e,y=v.length,b=0,x=0,ee=this.hasCustom?0:Math.floor(e.length/10),S=Array(ee),te=[],ne=this.trackStartLines?1:void 0,C=this.trackStartLines?1:void 0,re=fy(this.emptyGroups),ie=this.trackStartLines,ae=this.config.lineTerminatorsPattern,oe=0,se=[],ce=[],le=[],ue=[];Object.freeze(ue);let de=!1,w=o(e=>{if(le.length===1&&e.tokenType.PUSH_MODE===void 0){let t=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);te.push({offset:e.startOffset,line:e.startLine,column:e.startColumn,length:e.image.length,message:t})}else{le.pop();let e=bg(le);se=this.patternIdxToConfig[e],ce=this.charCodeToPatternIdxToConfig[e],oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=!!(ce&&t)}},`pop_mode`);function T(e){le.push(e),ce=this.charCodeToPatternIdxToConfig[e],se=this.patternIdxToConfig[e],oe=se.length,oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=!!(ce&&t)}o(T,`push_mode`),T.call(this,t);let E,D=this.config.recoveryEnabled;for(;bc.length){c=a,d=a.length,l=u,E=t;break}}}break}}if(d!==-1){if(f=E.group,f!==void 0&&(c=c===null?e.substring(b,b+d):c,p=E.tokenTypeIdx,m=this.createTokenInstance(c,b,p,E.tokenType,ne,C,d),this.handlePayload(m,l),f===!1?x=this.addToken(S,x,m):re[f].push(m)),ie===!0&&E.canLineTerminator===!0){let t=0,n,r;ae.lastIndex=0;do c=c===null?e.substring(b,b+d):c,n=ae.test(c),n===!0&&(r=ae.lastIndex-1,t++);while(n===!0);t===0?C=this.computeNewColumn(C,d):(ne+=t,C=d-r,this.updateTokenEndLineColumnLocation(m,f,r,t,ne,C,d))}else C=this.computeNewColumn(C,d);b+=d,this.handleModes(E,w,T,m)}else{let t=b,n=ne,i=C,a=D===!1;for(;a===!1&&b ${Hy(e)} <--`:`token of type --> ${e.name} <--`} but found --> '${t.image}' <--`},buildNotAllInputParsedMessage({firstRedundant:e,ruleName:t}){return`Redundant input, expecting EOF but found: `+e.image},buildNoViableAltMessage({expectedPathsPerAlt:e,actual:t,previous:n,customUserDescription:r,ruleName:i}){let a=` +but found: '`+Wg(t).image+`'`;return r?`Expecting: `+r+a:`Expecting: one of these possible Token sequences: +${B(B(L_(e,(e,t)=>e.concat(t),[]),e=>`[${B(e,e=>Hy(e)).join(`, `)}]`),(e,t)=>` ${t+1}. ${e}`).join(` +`)}`+a},buildEarlyExitMessage({expectedIterationPaths:e,actual:t,customUserDescription:n,ruleName:r}){let i=` +but found: '`+Wg(t).image+`'`;return n?`Expecting: `+n+i:`Expecting: expecting at least one iteration which starts with one of these possible Token sequences:: + <${B(e,e=>`[${B(e,e=>Hy(e)).join(`,`)}]`).join(` ,`)}>`+i}};Object.freeze(ib);var ab={buildRuleNotFoundError(e,t){return`Invalid grammar, reference to a rule which is not defined: ->`+t.nonTerminalName+`<- +inside top level rule: ->`+e.name+`<-`}},ob={buildDuplicateFoundError(e,t){function n(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(n,`getExtraProductionArgument`);let r=e.name,i=Wg(t),a=i.idx,s=_v(i),c=n(i),l=`->${s}${a>0?a:``}<- ${c?`with argument: ->${c}<-`:``} + appears more than once (${t.length} times) in the top level rule: ->${r}<-. + For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES + `;return l=l.replace(/[ \t]+/g,` `),l=l.replace(/\s\s+/g,` +`),l},buildNamespaceConflictError(e){return`Namespace conflict found in grammar. +The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${e.name}>. +To resolve this make sure each Terminal and Non-Terminal names are unique +This is easy to accomplish by using the convention that Terminal names start with an uppercase letter +and Non-Terminal names start with a lower case letter.`},buildAlternationPrefixAmbiguityError(e){let t=B(e.prefixPath,e=>Hy(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx;return`Ambiguous alternatives: <${e.ambiguityIndices.join(` ,`)}> due to common lookahead prefix +in inside <${e.topLevelRule.name}> Rule, +<${t}> may appears as a prefix path in all these alternatives. +See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX +For Further details.`},buildAlternationAmbiguityError(e){let t=e.alternation.idx===0?``:e.alternation.idx,n=e.prefixPath.length===0,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(` ,`)}> in inside <${e.topLevelRule.name}> Rule, +`;if(n)r+=`These alternatives are all empty (match no tokens), making them indistinguishable. +Only the last alternative may be empty. +`;else{let t=B(e.prefixPath,e=>Hy(e)).join(`, `);r+=`<${t}> may appears as a prefix path in all these alternatives. +`}return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r},buildEmptyRepetitionError(e){let t=_v(e.repetition);return e.repetition.idx!==0&&(t+=e.repetition.idx),`The repetition <${t}> within Rule <${e.topLevelRule.name}> can never consume any tokens. +This could lead to an infinite loop.`},buildTokenNameError(e){return`deprecated`},buildEmptyAlternationError(e){return`Ambiguous empty alternative: <${e.emptyChoiceIdx+1}> in inside <${e.topLevelRule.name}> Rule. +Only the last alternative may be an empty alternative.`},buildTooManyAlternativesError(e){return`An Alternation cannot have more than 256 alternatives: + inside <${e.topLevelRule.name}> Rule. + has ${e.alternation.definition.length+1} alternatives.`},buildLeftRecursionError(e){let t=e.topLevelRule.name;return`Left Recursion found in grammar. +rule: <${t}> can be invoked from itself (directly or indirectly) +without consuming any Tokens. The grammar path that causes this is: + ${`${t} --> ${B(e.leftRecursionPath,e=>e.name).concat([t]).join(` --> `)}`} + To fix this refactor your grammar to remove the left recursion. +see: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError(e){return`deprecated`},buildDuplicateRuleNameError(e){let t;return t=e.topLevelRule instanceof iv?e.topLevelRule.name:e.topLevelRule,`Duplicate definition, rule: ->${t}<- is already defined in the grammar: ->${e.grammarName}<-`}};function sb(e,t){let n=new cb(e,t);return n.resolveRefs(),n.errors}o(sb,`resolveGrammar`);var cb=class extends pv{static{o(this,`GastRefResolverVisitor`)}constructor(e,t){super(),this.nameToTopRule=e,this.errMsgProvider=t,this.errors=[]}resolveRefs(){z(H(this.nameToTopRule),e=>{this.currTopLevel=e,e.accept(this)})}visitNonTerminal(e){let t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{let t=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:t,type:pS.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}}},lb=class extends vv{static{o(this,`AbstractNextPossibleTokensWalker`)}constructor(e,t){super(),this.topProd=e,this.path=t,this.possibleTokTypes=[],this.nextProductionName=``,this.nextProductionOccurrence=0,this.found=!1,this.isAtEndOfPath=!1}startWalking(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error(`The path does not start with the walker's top Rule!`);return this.ruleStack=Sm(this.path.ruleStack).reverse(),this.occurrenceStack=Sm(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes}walk(e,t=[]){this.found||super.walk(e,t)}walkProdRef(e,t,n){if(e.referencedRule.name===this.nextProductionName&&e.idx===this.nextProductionOccurrence){let r=t.concat(n);this.updateExpectedNext(),this.walk(e.referencedRule,r)}}updateExpectedNext(){U(this.ruleStack)?(this.nextProductionName=``,this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())}},ub=class extends lb{static{o(this,`NextAfterTokenWalker`)}constructor(e,t){super(e,t),this.path=t,this.nextTerminalName=``,this.nextTerminalOccurrence=0,this.nextTerminalName=this.path.lastTok.name,this.nextTerminalOccurrence=this.path.lastTokOccurrence}walkTerminal(e,t,n){if(this.isAtEndOfPath&&e.terminalType.name===this.nextTerminalName&&e.idx===this.nextTerminalOccurrence&&!this.found){let e=new av({definition:t.concat(n)});this.possibleTokTypes=bv(e),this.found=!0}}},db=class extends vv{static{o(this,`AbstractNextTerminalAfterProductionWalker`)}constructor(e,t){super(),this.topRule=e,this.occurrence=t,this.result={token:void 0,occurrence:void 0,isEndOfRule:void 0}}startWalking(){return this.walk(this.topRule),this.result}},fb=class extends db{static{o(this,`NextTerminalAfterManyWalker`)}walkMany(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkMany(e,t,n)}},pb=class extends db{static{o(this,`NextTerminalAfterManySepWalker`)}walkManySep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkManySep(e,t,n)}},mb=class extends db{static{o(this,`NextTerminalAfterAtLeastOneWalker`)}walkAtLeastOne(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOne(e,t,n)}},hb=class extends db{static{o(this,`NextTerminalAfterAtLeastOneSepWalker`)}walkAtLeastOneSep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOneSep(e,t,n)}};function gb(e,t,n=[]){n=Sm(n);let r=[],i=0;function a(t){return t.concat(Sg(e,i+1))}o(a,`remainingPathWith`);function s(e){let i=gb(a(e),t,n);return r.concat(i)}for(o(s,`getAlternativesForProd`);n.length{U(e.definition)===!1&&(r=s(e.definition))}),r;else if(t instanceof G)n.push(t.terminalType);else throw Error(`non exhaustive match`);i++}return r.push({partialPath:n,suffixDef:Sg(e,i)}),r}o(gb,`possiblePathsFrom`);function _b(e,t,n,r){let i=`EXIT_NONE_TERMINAL`,a=[i],o=`EXIT_ALTERNATIVE`,s=!1,c=t.length,l=c-r-1,u=[],d=[];for(d.push({idx:-1,def:e,ruleStack:[],occurrenceStack:[]});!U(d);){let e=d.pop();if(e===o){s&&bg(d).idx<=l&&d.pop();continue}let r=e.def,f=e.idx,p=e.ruleStack,m=e.occurrenceStack;if(U(r))continue;let h=r[0];if(h===i){let e={idx:f,def:Sg(r),ruleStack:wg(p),occurrenceStack:wg(m)};d.push(e)}else if(h instanceof G){if(f=0;e--){let t={idx:f,def:h.definition[e].definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t),d.push(o)}else if(h instanceof av)d.push({idx:f,def:h.definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m});else if(h instanceof iv)d.push(vb(h,f,p,m));else throw Error(`non exhaustive match`)}return u}o(_b,`nextPossibleTokensAfter`);function vb(e,t,n,r){let i=Sm(n);i.push(e.name);let a=Sm(r);return a.push(1),{idx:t,def:e.definition,ruleStack:i,occurrenceStack:a}}o(vb,`expandTopLevelRule`);var q;(function(e){e[e.OPTION=0]=`OPTION`,e[e.REPETITION=1]=`REPETITION`,e[e.REPETITION_MANDATORY=2]=`REPETITION_MANDATORY`,e[e.REPETITION_MANDATORY_WITH_SEPARATOR=3]=`REPETITION_MANDATORY_WITH_SEPARATOR`,e[e.REPETITION_WITH_SEPARATOR=4]=`REPETITION_WITH_SEPARATOR`,e[e.ALTERNATION=5]=`ALTERNATION`})(q||={});function yb(e){if(e instanceof ov||e===`Option`)return q.OPTION;if(e instanceof W||e===`Repetition`)return q.REPETITION;if(e instanceof sv||e===`RepetitionMandatory`)return q.REPETITION_MANDATORY;if(e instanceof cv||e===`RepetitionMandatoryWithSeparator`)return q.REPETITION_MANDATORY_WITH_SEPARATOR;if(e instanceof lv||e===`RepetitionWithSeparator`)return q.REPETITION_WITH_SEPARATOR;if(e instanceof uv||e===`Alternation`)return q.ALTERNATION;throw Error(`non exhaustive match`)}o(yb,`getProdType`);function bb(e){let{occurrence:t,rule:n,prodType:r,maxLookahead:i}=e,a=yb(r);return a===q.ALTERNATION?jb(t,n,i):Mb(t,n,a,i)}o(bb,`getLookaheadPaths`);function xb(e,t,n,r,i,a){let o=jb(e,t,n);return a(o,r,Fb(o)?Ty:wy,i)}o(xb,`buildLookaheadFuncForOr`);function Sb(e,t,n,r,i,a){let o=Mb(e,t,i,n),s=Fb(o)?Ty:wy;return a(o[0],s,r)}o(Sb,`buildLookaheadFuncForOptionalProd`);function Cb(e,t,n,r){let i=e.length,a=Ng(e,e=>Ng(e,e=>e.length===1));if(t)return function(t){let r=B(t,e=>e.GATE);for(let t=0;tLd(e)),(e,t,n)=>(z(t,t=>{V(e,t.tokenTypeIdx)||(e[t.tokenTypeIdx]=n),z(t.categoryMatches,t=>{V(e,t)||(e[t]=n)})}),e),{});return function(){let e=this.LA(1);return t[e.tokenTypeIdx]}}return function(){for(let t=0;te.length===1),i=e.length;if(r&&!n){let t=Ld(e);if(t.length===1&&U(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=L_(t,(e,t,n)=>(e[t.tokenTypeIdx]=!0,z(t.categoryMatches,t=>{e[t]=!0}),e),[]);return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){nextPath:for(let n=0;ngb([e],1)),r=Db(n.length),i=B(n,e=>{let t={};return z(e,e=>{z(Ob(e.partialPath),e=>{t[e]=!0})}),t}),a=n;for(let e=1;e<=t;e++){let n=a;a=Db(n.length);for(let o=0;o{z(Ob(e.partialPath),e=>{i[o][e]=!0})})}}}}return r}o(Ab,`lookAheadSequenceFromAlternatives`);function jb(e,t,n,r){let i=new Eb(e,q.ALTERNATION,r);return t.accept(i),Ab(i.result,n)}o(jb,`getLookaheadPathsForOr`);function Mb(e,t,n,r){let i=new Eb(e,n);t.accept(i);let a=i.result,o=new Tb(t,e,n).startWalking();return Ab([new av({definition:a}),new av({definition:o})],r)}o(Mb,`getLookaheadPathsForOptionalProd`);function Nb(e,t){compareOtherPath:for(let n=0;n{let r=t[n];return e===r||r.categoryMatchesMap[e.tokenTypeIdx]})}o(Pb,`isStrictPrefixOfPath`);function Fb(e){return Ng(e,e=>Ng(e,e=>Ng(e,e=>U(e.categoryMatches))))}o(Fb,`areTokenCategoriesNotUsed`);function Ib(e){return B(e.lookaheadStrategy.validate({rules:e.rules,tokenTypes:e.tokenTypes,grammarName:e.grammarName}),e=>Object.assign({type:pS.CUSTOM_LOOKAHEAD_VALIDATION},e))}o(Ib,`validateLookahead`);function Lb(e,t,n,r){let i=Yg(e,e=>Rb(e,n)),a=ex(e,t,n),o=Yg(e,e=>Xb(e,n)),s=Yg(e,t=>Hb(t,e,r,n));return i.concat(a,o,s)}o(Lb,`validateGrammar`);function Rb(e,t){let n=new Vb;e.accept(n);let r=n.allProductions;return B(H(N_(Zg(r,zb),e=>e.length>1)),n=>{let r=Wg(n),i=t.buildDuplicateFoundError(e,n),a=_v(r),o={message:i,type:pS.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:a,occurrence:r.idx},s=Bb(r);return s&&(o.parameter=s),o})}o(Rb,`validateDuplicateProductions`);function zb(e){return`${_v(e)}_#_${e.idx}_#_${Bb(e)}`}o(zb,`identifyProductionForDuplicates`);function Bb(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(Bb,`getExtraProductionArgument`);var Vb=class extends pv{static{o(this,`OccurrenceValidationCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(e){this.allProductions.push(e)}visitOption(e){this.allProductions.push(e)}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}visitAlternation(e){this.allProductions.push(e)}visitTerminal(e){this.allProductions.push(e)}};function Hb(e,t,n,r){let i=[];if(L_(t,(t,n)=>n.name===e.name?t+1:t,0)>1){let t=r.buildDuplicateRuleNameError({topLevelRule:e,grammarName:n});i.push({message:t,type:pS.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}o(Hb,`validateRuleDoesNotAlreadyExist`);function Ub(e,t,n){let r=[],i;return u_(t,e)||(i=`Invalid rule override, rule: ->${e}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:pS.INVALID_RULE_OVERRIDE,ruleName:e})),r}o(Ub,`validateRuleIsOverridden`);function Wb(e,t,n,r=[]){let i=[],a=Gb(t.definition);if(U(a))return[];{let t=e.name;u_(a,e)&&i.push({message:n.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:r}),type:pS.LEFT_RECURSION,ruleName:t});let o=Yg(vg(a,r.concat([e])),t=>{let i=Sm(r);return i.push(t),Wb(e,t,n,i)});return i.concat(o)}}o(Wb,`validateNoLeftRecursion`);function Gb(e){let t=[];if(U(e))return t;let n=Wg(e);if(n instanceof rv)t.push(n.referencedRule);else if(n instanceof av||n instanceof ov||n instanceof sv||n instanceof cv||n instanceof lv||n instanceof W)t=t.concat(Gb(n.definition));else if(n instanceof uv)t=Ld(B(n.definition,e=>Gb(e.definition)));else if(!(n instanceof G))throw Error(`non exhaustive match`);let r=hv(n),i=e.length>1;if(r&&i){let n=Sg(e);return t.concat(Gb(n))}return t}o(Gb,`getFirstNoneTerminal`);var Kb=class extends pv{static{o(this,`OrCollector`)}constructor(){super(...arguments),this.alternations=[]}visitAlternation(e){this.alternations.push(e)}};function qb(e,t){let n=new Kb;e.accept(n);let r=n.alternations;return Yg(r,n=>Yg(wg(n.definition),(r,i)=>U(_b([r],[],wy,1))?[{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:pS.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}]:[]))}o(qb,`validateEmptyOrAlternative`);function Jb(e,t,n){let r=new Kb;e.accept(r);let i=r.alternations;return i=z_(i,e=>e.ignoreAmbiguities===!0),Yg(i,r=>{let i=r.idx,a=jb(i,e,r.maxLookahead||t,r),o=Qb(a,r,e,n),s=$b(a,r,e,n);return o.concat(s)})}o(Jb,`validateAmbiguousAlternationAlternatives`);var Yb=class extends pv{static{o(this,`RepetitionCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}};function Xb(e,t){let n=new Kb;e.accept(n);let r=n.alternations;return Yg(r,n=>n.definition.length>255?[{message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:pS.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}]:[])}o(Xb,`validateTooManyAlts`);function Zb(e,t,n){let r=[];return z(e,e=>{let i=new Yb;e.accept(i);let a=i.allProductions;z(a,i=>{let a=yb(i),o=i.maxLookahead||t,s=i.idx,c=Mb(s,e,a,o)[0];if(U(Ld(c))){let t=n.buildEmptyRepetitionError({topLevelRule:e,repetition:i});r.push({message:t,type:pS.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}})}),r}o(Zb,`validateSomeNonEmptyLookaheadPath`);function Qb(e,t,n,r){let i=[];return B(L_(e,(n,r,a)=>(t.definition[a].ignoreAmbiguities===!0||z(r,r=>{let o=[a];z(e,(e,n)=>{a!==n&&Nb(e,r)&&t.definition[n].ignoreAmbiguities!==!0&&o.push(n)}),o.length>1&&!Nb(i,r)&&(i.push(r),n.push({alts:o,path:r}))}),n),[]),e=>{let i=B(e.alts,e=>e+1);return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:pS.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:t.idx,alternatives:e.alts}})}o(Qb,`checkAlternativesAmbiguities`);function $b(e,t,n,r){let i=L_(e,(e,t,n)=>{let r=B(t,e=>({idx:n,path:e}));return e.concat(r)},[]);return wm(Yg(i,e=>{if(t.definition[e.idx].ignoreAmbiguities===!0)return[];let a=e.idx,o=e.path;return B(Lg(i,e=>t.definition[e.idx].ignoreAmbiguities!==!0&&e.idx{let i=[e.idx+1,a+1],o=t.idx===0?``:t.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:pS.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}})}))}o($b,`checkPrefixAlternativesAmbiguities`);function ex(e,t,n){let r=[],i=B(t,e=>e.name);return z(e,e=>{let t=e.name;if(u_(i,t)){let i=n.buildNamespaceConflictError(e);r.push({message:i,type:pS.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}}),r}o(ex,`checkTerminalAndNoneTerminalsNameSpace`);function tx(e){let t=ug(e,{errMsgProvider:ab}),n={};return z(e.rules,e=>{n[e.name]=e}),sb(n,t.errMsgProvider)}o(tx,`resolveGrammar`);function nx(e){return e=ug(e,{errMsgProvider:ob}),Lb(e.rules,e.tokenTypes,e.errMsgProvider,e.grammarName)}o(nx,`validateGrammar`);var rx=`MismatchedTokenException`,ix=`NoViableAltException`,ax=`EarlyExitException`,ox=`NotAllInputParsedException`,sx=[rx,ix,ax,ox];Object.freeze(sx);function cx(e){return u_(sx,e.name)}o(cx,`isRecognitionException`);var lx=class extends Error{static{o(this,`RecognitionException`)}constructor(e,t){super(e),this.token=t,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}},ux=class extends lx{static{o(this,`MismatchedTokenException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=rx}},dx=class extends lx{static{o(this,`NoViableAltException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ix}},fx=class extends lx{static{o(this,`NotAllInputParsedException`)}constructor(e,t){super(e,t),this.name=ox}},px=class extends lx{static{o(this,`EarlyExitException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ax}},mx={},hx=`InRuleRecoveryException`,gx=class extends Error{static{o(this,`InRuleRecoveryException`)}constructor(e){super(e),this.name=hx}},_x=class{static{o(this,`Recoverable`)}initRecoverable(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=V(e,`recoveryEnabled`)?e.recoveryEnabled:dS.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=vx)}getTokenToInsert(e){let t=nb(e,``,NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t}canTokenTypeBeInsertedInRecovery(e){return!0}canTokenTypeBeDeletedInRecovery(e){return!0}tryInRepetitionRecovery(e,t,n,r){let i=this.findReSyncTokenType(),a=this.exportLexerState(),s=[],c=!1,l=this.LA(1),u=this.LA(1),d=o(()=>{let e=this.LA(0),t=new ux(this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:l,previous:e,ruleName:this.getCurrRuleFullName()}),l,this.LA(0));t.resyncedTokens=wg(s),this.SAVE_ERROR(t)},`generateErrorMessage`);for(;!c;)if(this.tokenMatcher(u,r)){d();return}else if(n.call(this)){d(),e.apply(this,t);return}else this.tokenMatcher(u,i)?c=!0:(u=this.SKIP_TOKEN(),this.addToResyncTokens(u,s));this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(e,t,n){return!(n===!1||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t)))}getFollowsForInRuleRecovery(e,t){let n=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){let e=this.SKIP_TOKEN();return this.consumeToken(),e}throw new gx(`sad sad panda`)}canPerformInRuleRecovery(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)}canRecoverWithSingleTokenInsertion(e,t){if(!this.canTokenTypeBeInsertedInRecovery(e)||U(t))return!1;let n=this.LA(1);return Hg(t,e=>this.tokenMatcher(n,e))!==void 0}canRecoverWithSingleTokenDeletion(e){return this.canTokenTypeBeDeletedInRecovery(e)?this.tokenMatcher(this.LA(2),e):!1}isInCurrentRuleReSyncSet(e){let t=this.getCurrFollowKey();return u_(this.getFollowSetFromFollowKey(t),e)}findReSyncTokenType(){let e=this.flattenFollowSet(),t=this.LA(1),n=2;for(;;){let r=Hg(e,e=>rb(t,e));if(r!==void 0)return r;t=this.LA(n),n++}}getCurrFollowKey(){if(this.RULE_STACK.length===1)return mx;let e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){let e=this.RULE_STACK,t=this.RULE_OCCURRENCE_STACK;return B(e,(n,r)=>r===0?mx:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:t[r],inRule:this.shortRuleNameToFullName(e[r-1])})}flattenFollowSet(){return Ld(B(this.buildFullFollowKeyStack(),e=>this.getFollowSetFromFollowKey(e)))}getFollowSetFromFollowKey(e){if(e===mx)return[tb];let t=e.ruleName+e.idxInCallingRule+wv+e.inRule;return this.resyncFollows[t]}addToResyncTokens(e,t){return this.tokenMatcher(e,tb)||t.push(e),t}reSyncTo(e){let t=[],n=this.LA(1);for(;this.tokenMatcher(n,e)===!1;)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,t);return wg(t)}attemptInRepetitionRecovery(e,t,n,r,i,a,o){}getCurrentGrammarPath(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:Sm(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}}getHumanReadableRuleStack(){return B(this.RULE_STACK,e=>this.shortRuleNameToFullName(e))}};function vx(e,t,n,r,i,a,o){let s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(c===void 0){let e=this.getCurrRuleFullName(),t=this.getGAstProductions()[e];c=new a(t,i).startWalking(),this.firstAfterRepMap[s]=c}let l=c.token,u=c.occurrence,d=c.isEndOfRule;this.RULE_STACK.length===1&&d&&l===void 0&&(l=tb,u=1),l!==void 0&&u!==void 0&&this.shouldInRepetitionRecoveryBeTried(l,u,o)&&this.tryInRepetitionRecovery(e,t,n,l)}o(vx,`attemptInRepetitionRecovery`);var yx=4,bx=8,xx=8,Sx=1<Wb(e,e,ob))}validateEmptyOrAlternatives(e){return Yg(e,e=>qb(e,ob))}validateAmbiguousAlternationAlternatives(e,t){return Yg(e,e=>Jb(e,t,ob))}validateSomeNonEmptyLookaheadPath(e,t){return Zb(e,t,ob)}buildLookaheadForAlternation(e){return xb(e.prodOccurrence,e.rule,e.maxLookahead,e.hasPredicates,e.dynamicTokensEnabled,Cb)}buildLookaheadForOptional(e){return Sb(e.prodOccurrence,e.rule,e.maxLookahead,e.dynamicTokensEnabled,yb(e.prodType),wb)}},Ax=class{static{o(this,`LooksAhead`)}initLooksAhead(e){this.dynamicTokensEnabled=V(e,`dynamicTokensEnabled`)?e.dynamicTokensEnabled:dS.dynamicTokensEnabled,this.maxLookahead=V(e,`maxLookahead`)?e.maxLookahead:dS.maxLookahead,this.lookaheadStrategy=V(e,`lookaheadStrategy`)?e.lookaheadStrategy:new kx({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(e){z(e,e=>{this.TRACE_INIT(`${e.name} Rule Lookahead`,()=>{let{alternation:t,repetition:n,option:r,repetitionMandatory:i,repetitionMandatoryWithSeparator:a,repetitionWithSeparator:o}=Mx(e);z(t,t=>{let n=t.idx===0?``:t.idx;this.TRACE_INIT(`${_v(t)}${n}`,()=>{let n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:t.idx,rule:e,maxLookahead:t.maxLookahead||this.maxLookahead,hasPredicates:t.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=Ox(this.fullRuleNameToShort[e.name],Sx,t.idx);this.setLaFuncCache(r,n)})}),z(n,t=>{this.computeLookaheadFunc(e,t.idx,wx,`Repetition`,t.maxLookahead,_v(t))}),z(r,t=>{this.computeLookaheadFunc(e,t.idx,Cx,`Option`,t.maxLookahead,_v(t))}),z(i,t=>{this.computeLookaheadFunc(e,t.idx,Tx,`RepetitionMandatory`,t.maxLookahead,_v(t))}),z(a,t=>{this.computeLookaheadFunc(e,t.idx,Dx,`RepetitionMandatoryWithSeparator`,t.maxLookahead,_v(t))}),z(o,t=>{this.computeLookaheadFunc(e,t.idx,Ex,`RepetitionWithSeparator`,t.maxLookahead,_v(t))})})})}computeLookaheadFunc(e,t,n,r,i,a){this.TRACE_INIT(`${a}${t===0?``:t}`,()=>{let a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:t,rule:e,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),o=Ox(this.fullRuleNameToShort[e.name],n,t);this.setLaFuncCache(o,a)})}getKeyForAutomaticLookahead(e,t){return Ox(this.getLastExplicitRuleShortName(),e,t)}getLaFuncFromCache(e){return this.lookAheadFuncsCache.get(e)}setLaFuncCache(e,t){this.lookAheadFuncsCache.set(e,t)}},jx=new class extends pv{static{o(this,`DslMethodsCollectorVisitor`)}constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(e){this.dslMethods.option.push(e)}visitRepetitionWithSeparator(e){this.dslMethods.repetitionWithSeparator.push(e)}visitRepetitionMandatory(e){this.dslMethods.repetitionMandatory.push(e)}visitRepetitionMandatoryWithSeparator(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)}visitRepetition(e){this.dslMethods.repetition.push(e)}visitAlternation(e){this.dslMethods.alternation.push(e)}};function Mx(e){jx.reset(),e.accept(jx);let t=jx.dslMethods;return jx.reset(),t}o(Mx,`collectMethods`);function Nx(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffsete.msg);throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>: + ${t.join(` + +`).replace(/\n/g,` + `)}`)}},`validateVisitor`)},n.prototype.constructor=n,n._RULE_NAMES=t,n}o(Bx,`createBaseSemanticVisitorConstructor`);function Vx(e,t,n){let r=o(function(){},`derivedConstructor`);Rx(r,e+`BaseSemanticsWithDefaults`);let i=Object.create(n.prototype);return z(t,e=>{i[e]=zx}),r.prototype=i,r.prototype.constructor=r,r}o(Vx,`createBaseVisitorConstructorWithDefaults`);var Hx;(function(e){e[e.REDUNDANT_METHOD=0]=`REDUNDANT_METHOD`,e[e.MISSING_METHOD=1]=`MISSING_METHOD`})(Hx||={});function Ux(e,t){return Wx(e,t)}o(Ux,`validateVisitor`);function Wx(e,t){return wm(B(Lg(t,t=>Ss(e[t])===!1),t=>({msg:`Missing visitor method: <${t}> on ${e.constructor.name} CST Visitor.`,type:Hx.MISSING_METHOD,methodName:t})))}o(Wx,`validateMissingCstMethods`);var Gx=class{static{o(this,`TreeBuilder`)}initTreeBuilder(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=V(e,`nodeLocationTracking`)?e.nodeLocationTracking:dS.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=Ys,this.cstFinallyStateUpdate=Ys,this.cstPostTerminal=Ys,this.cstPostNonTerminal=Ys,this.cstPostRule=Ys;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Px,this.setNodeLocationFromNode=Px,this.cstPostRule=Ys,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Nx,this.setNodeLocationFromNode=Nx,this.cstPostRule=Ys,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=Ys,this.setNodeLocationFromNode=Ys,this.cstPostRule=Ys,this.setInitialNodeLocation=Ys;else throw Error(`Invalid config option: "${e.nodeLocationTracking}"`)}setInitialNodeLocationOnlyOffsetRecovery(e){e.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(e){let t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(e){let t={name:e,children:Object.create(null)};this.setInitialNodeLocation(t),this.CST_STACK.push(t)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?(n.endOffset=t.endOffset,n.endLine=t.endLine,n.endColumn=t.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?n.endOffset=t.endOffset:n.startOffset=NaN}cstPostTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Fx(n,t,e),this.setNodeLocationFromToken(n.location,t)}cstPostNonTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Ix(n,t,e),this.setNodeLocationFromNode(n.location,e.location)}getBaseCstVisitorConstructor(){if(w_(this.baseCstVisitorConstructor)){let e=Bx(this.className,eu(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if(w_(this.baseCstVisitorWithDefaultsConstructor)){let e=Vx(this.className,eu(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-1]}getPreviousExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-2]}getLastExplicitRuleOccurrenceIndex(){let e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]}},Kx=class{static{o(this,`LexerAdapter`)}initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(e){if(this.selfAnalysisDone!==!0)throw Error(`Missing invocation at the end of the Parser's constructor.`);this.reset(),this.tokVector=e,this.tokVectorLength=e.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):uS}LA(e){let t=this.currIdx+e;return t<0||this.tokVectorLength<=t?uS:this.tokVector[t]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(e){this.currIdx=e}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},qx=class{static{o(this,`RecognizerApi`)}ACTION(e){return e.call(this)}consume(e,t,n){return this.consumeInternal(t,e,n)}subrule(e,t,n){return this.subruleInternal(t,e,n)}option(e,t){return this.optionInternal(t,e)}or(e,t){return this.orInternal(t,e)}many(e,t){return this.manyInternal(e,t)}atLeastOne(e,t){return this.atLeastOneInternal(e,t)}CONSUME(e,t){return this.consumeInternal(e,0,t)}CONSUME1(e,t){return this.consumeInternal(e,1,t)}CONSUME2(e,t){return this.consumeInternal(e,2,t)}CONSUME3(e,t){return this.consumeInternal(e,3,t)}CONSUME4(e,t){return this.consumeInternal(e,4,t)}CONSUME5(e,t){return this.consumeInternal(e,5,t)}CONSUME6(e,t){return this.consumeInternal(e,6,t)}CONSUME7(e,t){return this.consumeInternal(e,7,t)}CONSUME8(e,t){return this.consumeInternal(e,8,t)}CONSUME9(e,t){return this.consumeInternal(e,9,t)}SUBRULE(e,t){return this.subruleInternal(e,0,t)}SUBRULE1(e,t){return this.subruleInternal(e,1,t)}SUBRULE2(e,t){return this.subruleInternal(e,2,t)}SUBRULE3(e,t){return this.subruleInternal(e,3,t)}SUBRULE4(e,t){return this.subruleInternal(e,4,t)}SUBRULE5(e,t){return this.subruleInternal(e,5,t)}SUBRULE6(e,t){return this.subruleInternal(e,6,t)}SUBRULE7(e,t){return this.subruleInternal(e,7,t)}SUBRULE8(e,t){return this.subruleInternal(e,8,t)}SUBRULE9(e,t){return this.subruleInternal(e,9,t)}OPTION(e){return this.optionInternal(e,0)}OPTION1(e){return this.optionInternal(e,1)}OPTION2(e){return this.optionInternal(e,2)}OPTION3(e){return this.optionInternal(e,3)}OPTION4(e){return this.optionInternal(e,4)}OPTION5(e){return this.optionInternal(e,5)}OPTION6(e){return this.optionInternal(e,6)}OPTION7(e){return this.optionInternal(e,7)}OPTION8(e){return this.optionInternal(e,8)}OPTION9(e){return this.optionInternal(e,9)}OR(e){return this.orInternal(e,0)}OR1(e){return this.orInternal(e,1)}OR2(e){return this.orInternal(e,2)}OR3(e){return this.orInternal(e,3)}OR4(e){return this.orInternal(e,4)}OR5(e){return this.orInternal(e,5)}OR6(e){return this.orInternal(e,6)}OR7(e){return this.orInternal(e,7)}OR8(e){return this.orInternal(e,8)}OR9(e){return this.orInternal(e,9)}MANY(e){this.manyInternal(0,e)}MANY1(e){this.manyInternal(1,e)}MANY2(e){this.manyInternal(2,e)}MANY3(e){this.manyInternal(3,e)}MANY4(e){this.manyInternal(4,e)}MANY5(e){this.manyInternal(5,e)}MANY6(e){this.manyInternal(6,e)}MANY7(e){this.manyInternal(7,e)}MANY8(e){this.manyInternal(8,e)}MANY9(e){this.manyInternal(9,e)}MANY_SEP(e){this.manySepFirstInternal(0,e)}MANY_SEP1(e){this.manySepFirstInternal(1,e)}MANY_SEP2(e){this.manySepFirstInternal(2,e)}MANY_SEP3(e){this.manySepFirstInternal(3,e)}MANY_SEP4(e){this.manySepFirstInternal(4,e)}MANY_SEP5(e){this.manySepFirstInternal(5,e)}MANY_SEP6(e){this.manySepFirstInternal(6,e)}MANY_SEP7(e){this.manySepFirstInternal(7,e)}MANY_SEP8(e){this.manySepFirstInternal(8,e)}MANY_SEP9(e){this.manySepFirstInternal(9,e)}AT_LEAST_ONE(e){this.atLeastOneInternal(0,e)}AT_LEAST_ONE1(e){return this.atLeastOneInternal(1,e)}AT_LEAST_ONE2(e){this.atLeastOneInternal(2,e)}AT_LEAST_ONE3(e){this.atLeastOneInternal(3,e)}AT_LEAST_ONE4(e){this.atLeastOneInternal(4,e)}AT_LEAST_ONE5(e){this.atLeastOneInternal(5,e)}AT_LEAST_ONE6(e){this.atLeastOneInternal(6,e)}AT_LEAST_ONE7(e){this.atLeastOneInternal(7,e)}AT_LEAST_ONE8(e){this.atLeastOneInternal(8,e)}AT_LEAST_ONE9(e){this.atLeastOneInternal(9,e)}AT_LEAST_ONE_SEP(e){this.atLeastOneSepFirstInternal(0,e)}AT_LEAST_ONE_SEP1(e){this.atLeastOneSepFirstInternal(1,e)}AT_LEAST_ONE_SEP2(e){this.atLeastOneSepFirstInternal(2,e)}AT_LEAST_ONE_SEP3(e){this.atLeastOneSepFirstInternal(3,e)}AT_LEAST_ONE_SEP4(e){this.atLeastOneSepFirstInternal(4,e)}AT_LEAST_ONE_SEP5(e){this.atLeastOneSepFirstInternal(5,e)}AT_LEAST_ONE_SEP6(e){this.atLeastOneSepFirstInternal(6,e)}AT_LEAST_ONE_SEP7(e){this.atLeastOneSepFirstInternal(7,e)}AT_LEAST_ONE_SEP8(e){this.atLeastOneSepFirstInternal(8,e)}AT_LEAST_ONE_SEP9(e){this.atLeastOneSepFirstInternal(9,e)}RULE(e,t,n=fS){if(u_(this.definedRulesNames,e)){let t={message:ob.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:pS.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(t)}this.definedRulesNames.push(e);let r=this.defineRule(e,t,n);return this[e]=r,r}OVERRIDE_RULE(e,t,n=fS){let r=Ub(e,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);let i=this.defineRule(e,t,n);return this[e]=i,i}BACKTRACK(e,t){return function(){this.isBackTrackingStack.push(1);let n=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(cx(e))return!1;throw e}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return dv(H(this.gastProductionsCache))}},Jx=class{static{o(this,`RecognizerEngine`)}initRecognizerEngine(e,t){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=Ty,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},V(t,`serializedGrammar`))throw Error(`The Parser's configuration can no longer contain a property. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 + For Further details.`);if(I(e)){if(U(e))throw Error(`A Token Vocabulary cannot be empty. + Note that the first argument for the parser constructor + is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset==`number`)throw Error(`The Parser constructor no longer accepts a token vector as the first argument. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 + For Further details.`)}if(I(e))this.tokensMap=L_(e,(e,t)=>(e[t.name]=t,e),{});else if(V(e,`modes`)&&Ng(Ld(H(e.modes)),Ry)){let t=Y_(Ld(H(e.modes)));this.tokensMap=L_(t,(e,t)=>(e[t.name]=t,e),{})}else if(ts(e))this.tokensMap=Sm(e);else throw Error(` argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition`);this.tokensMap.EOF=tb;let n=Ng(V(e,`modes`)?Ld(H(e.modes)):H(e),e=>U(e.categoryMatches));this.tokenMatcher=n?Ty:wy,Oy(H(this.tokensMap))}defineRule(e,t,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${e}> may not be defined after the 'performSelfAnalysis' method has been called' +Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);let r=V(n,`resyncEnabled`)?n.resyncEnabled:fS.resyncEnabled,i=V(n,`recoveryValueFunc`)?n.recoveryValueFunc:fS.recoveryValueFunc,a=this.ruleShortNameIdx<t.call(this)&&e.call(this),`lookAheadFunc`)}}else i=e;if(r.call(this)===!0)return i.call(this)}atLeastOneInternal(e,t){let n=this.getKeyForAutomaticLookahead(Tx,e);return this.atLeastOneInternalLogic(e,t,n)}atLeastOneInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookAheadFunc`)}}else i=t;if(r.call(this)===!0){let e=this.doSingleRepetition(i);for(;r.call(this)===!0&&e===!0;)e=this.doSingleRepetition(i)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY,t.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,t],r,Tx,e,mb)}atLeastOneSepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Dx,e);this.atLeastOneSepFirstInternalLogic(e,t,n)}atLeastOneSepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,hb],t,Dx,e,hb)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY_WITH_SEPARATOR,t.ERR_MSG)}manyInternal(e,t){let n=this.getKeyForAutomaticLookahead(wx,e);return this.manyInternalLogic(e,t,n)}manyInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookaheadFunction`)}}else i=t;let a=!0;for(;r.call(this)===!0&&a===!0;)a=this.doSingleRepetition(i);this.attemptInRepetitionRecovery(this.manyInternal,[e,t],r,wx,e,fb,a)}manySepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Ex,e);this.manySepFirstInternalLogic(e,t,n)}manySepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,pb],t,Ex,e,pb)}}repetitionSepSecondInternal(e,t,n,r,i){for(;n();)this.CONSUME(t),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,t,n,r,i],n,Dx,e,i)}doSingleRepetition(e){let t=this.getLexerPosition();return e.call(this),this.getLexerPosition()>t}orInternal(e,t){let n=this.getKeyForAutomaticLookahead(Sx,t),r=I(e)?e:e.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(i!==void 0)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){let e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new fx(t,e))}}subruleInternal(e,t,n){let r;try{let i=n===void 0?void 0:n.ARGS;return this.subruleIdx=t,r=e.apply(this,i),this.cstPostNonTerminal(r,n!==void 0&&n.LABEL!==void 0?n.LABEL:e.ruleName),r}catch(t){throw this.subruleInternalError(t,n,e.ruleName)}}subruleInternalError(e,t,n){throw cx(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,t!==void 0&&t.LABEL!==void 0?t.LABEL:n),delete e.partialCstResult),e}consumeInternal(e,t,n){let r;try{let t=this.LA(1);this.tokenMatcher(t,e)===!0?(this.consumeToken(),r=t):this.consumeInternalError(e,t,n)}catch(n){r=this.consumeInternalRecovery(e,t,n)}return this.cstPostTerminal(n!==void 0&&n.LABEL!==void 0?n.LABEL:e.name,r),r}consumeInternalError(e,t,n){let r,i=this.LA(0);throw r=n!==void 0&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new ux(r,t,i))}consumeInternalRecovery(e,t,n){if(this.recoveryEnabled&&n.name===`MismatchedTokenException`&&!this.isBackTracking()){let r=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,r)}catch(e){throw e.name===hx?n:e}}throw n}saveRecogState(){let e=this.errors,t=Sm(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK}}reloadRecogState(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK}ruleInvocationStateUpdate(e,t,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t)}isBackTracking(){return this.isBackTrackingStack.length!==0}getCurrRuleFullName(){let e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]}shortRuleNameToFullName(e){return this.shortRuleNameToFull[e]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),tb)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},Yx=class{static{o(this,`ErrorHandler`)}initErrorHandler(e){this._errors=[],this.errorMessageProvider=V(e,`errorMessageProvider`)?e.errorMessageProvider:dS.errorMessageProvider}SAVE_ERROR(e){if(cx(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:Sm(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error(`Trying to save an Error which is not a RecognitionException`)}get errors(){return Sm(this._errors)}set errors(e){this._errors=e}raiseEarlyExitException(e,t,n){let r=this.getCurrRuleFullName(),i=this.getGAstProductions()[r],a=Mb(e,i,t,this.maxLookahead)[0],o=[];for(let e=1;e<=this.maxLookahead;e++)o.push(this.LA(e));let s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new px(s,this.LA(1),this.LA(0)))}raiseNoAltException(e,t){let n=this.getCurrRuleFullName(),r=this.getGAstProductions()[n],i=jb(e,r,this.maxLookahead),a=[];for(let e=1;e<=this.maxLookahead;e++)a.push(this.LA(e));let o=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:o,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new dx(s,this.LA(1),o))}},Xx=class{static{o(this,`ContentAssist`)}initContentAssist(){}computeContentAssist(e,t){let n=this.gastProductionsCache[e];if(w_(n))throw Error(`Rule ->${e}<- does not exist in this grammar.`);return _b([n],t,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(e){let t=Wg(e.ruleStack),n=this.getGAstProductions()[t];return new ub(n,e).startWalking()}},Zx={description:`This Object indicates the Parser is during Recording Phase`};Object.freeze(Zx);var Qx=!0,$x=2**bx-1,eS=$y({name:`RECORDING_PHASE_TOKEN`,pattern:Vy.NA});Oy([eS]);var tS=nb(eS,`This IToken indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(tS);var nS={name:`This CSTNode indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},rS=class{static{o(this,`GastRecorder`)}initGastRecorder(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT(`Enable Recording`,()=>{for(let e=0;e<10;e++){let t=e>0?e:``;this[`CONSUME${t}`]=function(t,n){return this.consumeInternalRecord(t,e,n)},this[`SUBRULE${t}`]=function(t,n){return this.subruleInternalRecord(t,e,n)},this[`OPTION${t}`]=function(t){return this.optionInternalRecord(t,e)},this[`OR${t}`]=function(t){return this.orInternalRecord(t,e)},this[`MANY${t}`]=function(t){this.manyInternalRecord(e,t)},this[`MANY_SEP${t}`]=function(t){this.manySepFirstInternalRecord(e,t)},this[`AT_LEAST_ONE${t}`]=function(t){this.atLeastOneInternalRecord(e,t)},this[`AT_LEAST_ONE_SEP${t}`]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}}this.consume=function(e,t,n){return this.consumeInternalRecord(t,e,n)},this.subrule=function(e,t,n){return this.subruleInternalRecord(t,e,n)},this.option=function(e,t){return this.optionInternalRecord(t,e)},this.or=function(e,t){return this.orInternalRecord(t,e)},this.many=function(e,t){this.manyInternalRecord(e,t)},this.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD})}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT(`Deleting Recording methods`,()=>{let e=this;for(let t=0;t<10;t++){let n=t>0?t:``;delete e[`CONSUME${n}`],delete e[`SUBRULE${n}`],delete e[`OPTION${n}`],delete e[`OR${n}`],delete e[`MANY${n}`],delete e[`MANY_SEP${n}`],delete e[`AT_LEAST_ONE${n}`],delete e[`AT_LEAST_ONE_SEP${n}`]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})}ACTION_RECORD(e){}BACKTRACK_RECORD(e,t){return()=>!0}LA_RECORD(e){return uS}topLevelRuleRecord(e,t){try{let n=new iv({definition:[],name:e});return n.name=e,this.recordingProdStack.push(n),t.call(this),this.recordingProdStack.pop(),n}catch(e){if(e.KNOWN_RECORDER_ERROR!==!0)try{e.message+=` + This error was thrown during the "grammar recording phase" For more info see: + https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch{throw e}throw e}}optionInternalRecord(e,t){return iS.call(this,ov,e,t)}atLeastOneInternalRecord(e,t){iS.call(this,sv,t,e)}atLeastOneSepFirstInternalRecord(e,t){iS.call(this,cv,t,e,Qx)}manyInternalRecord(e,t){iS.call(this,W,t,e)}manySepFirstInternalRecord(e,t){iS.call(this,lv,t,e,Qx)}orInternalRecord(e,t){return aS.call(this,e,t)}subruleInternalRecord(e,t,n){if(sS(t),!e||V(e,`ruleName`)===!1){let n=Error(` argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}> + inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=e.ruleName,a=new rv({idx:t,nonTerminalName:i,label:n?.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?nS:Zx}consumeInternalRecord(e,t,n){if(sS(t),!Py(e)){let n=Error(` argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}> + inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=new G({idx:t,terminalType:e,label:n?.LABEL});return r.definition.push(i),tS}};function iS(e,t,n,r=!1){sS(n);let i=bg(this.recordingProdStack),a=Ss(t)?t:t.DEF,o=new e({definition:[],idx:n});return r&&(o.separator=t.SEP),V(t,`MAX_LOOKAHEAD`)&&(o.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(o),a.call(this),i.definition.push(o),this.recordingProdStack.pop(),Zx}o(iS,`recordProd`);function aS(e,t){sS(t);let n=bg(this.recordingProdStack),r=I(e)===!1,i=r===!1?e:e.DEF,a=new uv({definition:[],idx:t,ignoreAmbiguities:r&&e.IGNORE_AMBIGUITIES===!0});return V(e,`MAX_LOOKAHEAD`)&&(a.maxLookahead=e.MAX_LOOKAHEAD),a.hasPredicates=U_(i,e=>Ss(e.GATE)),n.definition.push(a),z(i,e=>{let t=new av({definition:[]});a.definition.push(t),V(e,`IGNORE_AMBIGUITIES`)?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:V(e,`GATE`)&&(t.ignoreAmbiguities=!0),this.recordingProdStack.push(t),e.ALT.call(this),this.recordingProdStack.pop()}),Zx}o(aS,`recordOrProd`);function oS(e){return e===0?``:`${e}`}o(oS,`getIdxSuffix`);function sS(e){if(e<0||e>$x){let t=Error(`Invalid DSL Method idx value: <${e}> + Idx value must be a none negative value smaller than ${$x+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}o(sS,`assertMethodIdxIsValid`);var cS=class{static{o(this,`PerformanceTracer`)}initPerformanceTracer(e){if(V(e,`traceInitPerf`)){let t=e.traceInitPerf,n=typeof t==`number`;this.traceInitMaxIdent=n?t:1/0,this.traceInitPerf=n?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=dS.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(e,t){if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()}};function lS(e,t){t.forEach(t=>{let n=t.prototype;Object.getOwnPropertyNames(n).forEach(r=>{if(r===`constructor`)return;let i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(e.prototype,r,i):e.prototype[r]=t.prototype[r]})})}o(lS,`applyMixins`);var uS=nb(tb,``,NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(uS);var dS=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:ib,nodeLocationTracking:`none`,traceInitPerf:!1,skipValidations:!1}),fS=Object.freeze({recoveryValueFunc:o(()=>void 0,`recoveryValueFunc`),resyncEnabled:!0}),pS;(function(e){e[e.INVALID_RULE_NAME=0]=`INVALID_RULE_NAME`,e[e.DUPLICATE_RULE_NAME=1]=`DUPLICATE_RULE_NAME`,e[e.INVALID_RULE_OVERRIDE=2]=`INVALID_RULE_OVERRIDE`,e[e.DUPLICATE_PRODUCTIONS=3]=`DUPLICATE_PRODUCTIONS`,e[e.UNRESOLVED_SUBRULE_REF=4]=`UNRESOLVED_SUBRULE_REF`,e[e.LEFT_RECURSION=5]=`LEFT_RECURSION`,e[e.NONE_LAST_EMPTY_ALT=6]=`NONE_LAST_EMPTY_ALT`,e[e.AMBIGUOUS_ALTS=7]=`AMBIGUOUS_ALTS`,e[e.CONFLICT_TOKENS_RULES_NAMESPACE=8]=`CONFLICT_TOKENS_RULES_NAMESPACE`,e[e.INVALID_TOKEN_NAME=9]=`INVALID_TOKEN_NAME`,e[e.NO_NON_EMPTY_LOOKAHEAD=10]=`NO_NON_EMPTY_LOOKAHEAD`,e[e.AMBIGUOUS_PREFIX_ALTS=11]=`AMBIGUOUS_PREFIX_ALTS`,e[e.TOO_MANY_ALTS=12]=`TOO_MANY_ALTS`,e[e.CUSTOM_LOOKAHEAD_VALIDATION=13]=`CUSTOM_LOOKAHEAD_VALIDATION`})(pS||={});function mS(e=void 0){return function(){return e}}o(mS,`EMPTY_ALT`);var hS=class e{static{o(this,`Parser`)}static performSelfAnalysis(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT(`performSelfAnalysis`,()=>{let t;this.selfAnalysisDone=!0;let n=this.className;this.TRACE_INIT(`toFastProps`,()=>{$_(this)}),this.TRACE_INIT(`Grammar Recording`,()=>{try{this.enableRecording(),z(this.definedRulesNames,e=>{let t=this[e].originalGrammarAction,n;this.TRACE_INIT(`${e} Rule`,()=>{n=this.topLevelRuleRecord(e,t)}),this.gastProductionsCache[e]=n})}finally{this.disableRecording()}});let r=[];if(this.TRACE_INIT(`Grammar Resolving`,()=>{r=tx({rules:H(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(r)}),this.TRACE_INIT(`Grammar Validations`,()=>{if(U(r)&&this.skipValidations===!1){let e=nx({rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),errMsgProvider:ob,grammarName:n}),t=Ib({lookaheadStrategy:this.lookaheadStrategy,rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),grammarName:n});this.definitionErrors=this.definitionErrors.concat(e,t)}}),U(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT(`computeAllProdsFollows`,()=>{let e=Ev(H(this.gastProductionsCache));this.resyncFollows=e}),this.TRACE_INIT(`ComputeLookaheadFunctions`,()=>{var e,t;(t=(e=this.lookaheadStrategy).initialize)==null||t.call(e,{rules:H(this.gastProductionsCache)}),this.preComputeLookaheadFunctions(H(this.gastProductionsCache))})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!U(this.definitionErrors))throw t=B(this.definitionErrors,e=>e.message),Error(`Parser Definition Errors detected: + ${t.join(` +------------------------------- +`)}`)})}constructor(e,t){this.definitionErrors=[],this.selfAnalysisDone=!1;let n=this;if(n.initErrorHandler(t),n.initLexerAdapter(),n.initLooksAhead(t),n.initRecognizerEngine(e,t),n.initRecoverable(t),n.initTreeBuilder(t),n.initContentAssist(),n.initGastRecorder(t),n.initPerformanceTracer(t),V(t,`ignoredIssues`))throw Error(`The IParserConfig property has been deprecated. + Please use the flag on the relevant DSL method instead. + See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES + For further details.`);this.skipValidations=V(t,`skipValidations`)?t.skipValidations:dS.skipValidations}};hS.DEFER_DEFINITION_ERRORS_HANDLING=!1,lS(hS,[_x,Ax,Gx,Kx,Jx,qx,Yx,Xx,rS,cS]);var gS=class extends hS{static{o(this,`EmbeddedActionsParser`)}constructor(e,t=dS){let n=Sm(t);n.outputCst=!1,super(e,n)}};function _S(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n-1}o(AS,`listCacheHas`);var jS=AS;function MS(e,t){var n=this.__data__,r=wS(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(MS,`listCacheSet`);var NS=MS;function PS(e){var t=-1,n=e==null?0:e.length;for(this.clear();++ts))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Nw?new Dw:void 0;for(a.set(e,t),a.set(t,e);++d-1&&e%1==0&&e-1&&e%1==0&&e<=LT}o(RT,`isLength`);var zT=RT,BT=`[object Arguments]`,VT=`[object Array]`,HT=`[object Boolean]`,UT=`[object Date]`,WT=`[object Error]`,GT=`[object Function]`,KT=`[object Map]`,qT=`[object Number]`,JT=`[object Object]`,YT=`[object RegExp]`,XT=`[object Set]`,ZT=`[object String]`,QT=`[object WeakMap]`,$T=`[object ArrayBuffer]`,eE=`[object DataView]`,tE=`[object Float32Array]`,nE=`[object Float64Array]`,rE=`[object Int8Array]`,iE=`[object Int16Array]`,aE=`[object Int32Array]`,oE=`[object Uint8Array]`,sE=`[object Uint8ClampedArray]`,cE=`[object Uint16Array]`,lE=`[object Uint32Array]`,J={};J[tE]=J[nE]=J[rE]=J[iE]=J[aE]=J[oE]=J[sE]=J[cE]=J[lE]=!0,J[BT]=J[VT]=J[$T]=J[HT]=J[eE]=J[UT]=J[WT]=J[GT]=J[KT]=J[qT]=J[JT]=J[YT]=J[XT]=J[ZT]=J[QT]=!1;function uE(e){return yT(e)&&zT(e.length)&&!!J[sC(e)]}o(uE,`baseIsTypedArray`);var dE=uE;function fE(e){return function(t){return e(t)}}o(fE,`baseUnary`);var pE=fE,mE=typeof exports==`object`&&exports&&!exports.nodeType&&exports,hE=mE&&typeof module==`object`&&module&&!module.nodeType&&module,gE=hE&&hE.exports===mE&&WS.process,_E=(function(){try{return hE&&hE.require&&hE.require(`util`).types||gE&&gE.binding&&gE.binding(`util`)}catch{}})(),vE=_E&&_E.isTypedArray,yE=vE?pE(vE):dE,bE=Object.prototype.hasOwnProperty;function xE(e,t){var n=oT(e),r=!n&&ET(e),i=!n&&!r&&MT(e),a=!n&&!r&&!i&&yE(e),o=n||r||i||a,s=o?_T(e.length,String):[],c=s.length;for(var l in e)(t||bE.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||IT(l,c)))&&s.push(l);return s}o(xE,`arrayLikeKeys`);var SE=xE,CE=Object.prototype;function wE(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||CE)}o(wE,`isPrototype`);var TE=wE;function EE(e,t){return function(n){return e(t(n))}}o(EE,`overArg`);var DE=EE(Object.keys,Object),OE=Object.prototype.hasOwnProperty;function kE(e){if(!TE(e))return DE(e);var t=[];for(var n in Object(e))OE.call(e,n)&&n!=`constructor`&&t.push(n);return t}o(kE,`baseKeys`);var AE=kE;function jE(e){return e!=null&&zT(e.length)&&!hC(e)}o(jE,`isArrayLike`);var ME=jE;function NE(e){return ME(e)?SE(e):AE(e)}o(NE,`keys`);var PE=NE;function FE(e){return cT(e,PE,hT)}o(FE,`getAllKeys`);var IE=FE,LE=1,RE=Object.prototype.hasOwnProperty;function zE(e,t,n,r,i,a){var o=n&LE,s=IE(e),c=s.length;if(c!=IE(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:RE.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++lek(e,t,n)))}o(ak,`alternation`);function ok(e,t,n){let r=X(e,t,n,{type:RO});return dk(e,r),uk(e,t,n,fk(e,t,r,n,sk(e,t,n)))}o(ok,`option`);function sk(e,t,n){let r=IO(MO(n.definition,n=>ek(e,t,n)),e=>e!==void 0);return r.length===1?r[0]:r.length===0?void 0:mk(e,r)}o(sk,`block`);function ck(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:KO});dk(e,s);let c=X(e,t,n,{type:qO});return a.loopback=s,c.loopback=s,e.decisionMap[LO(t,i?`RepetitionMandatoryWithSeparator`:`RepetitionMandatory`,n.idx)]=s,Y(o,s),i===void 0?(Y(s,a),Y(s,c)):(Y(s,c),Y(s,i.left),Y(i.right,a)),{left:a,right:c}}o(ck,`plus`);function lk(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:GO});dk(e,s);let c=X(e,t,n,{type:qO}),l=X(e,t,n,{type:WO});return s.loopback=l,c.loopback=l,Y(s,a),Y(s,c),Y(o,l),i===void 0?Y(l,s):(Y(l,c),Y(l,i.left),Y(i.right,a)),e.decisionMap[LO(t,i?`RepetitionWithSeparator`:`Repetition`,n.idx)]=s,{left:s,right:c}}o(lk,`star`);function uk(e,t,n,r){let i=r.left,a=r.right;return Y(i,a),e.decisionMap[LO(t,`Option`,n.idx)]=i,r}o(uk,`optional`);function dk(e,t){return e.decisionStates.push(t),t.decision=e.decisionStates.length-1,t.decision}o(dk,`defineDecisionState`);function fk(e,t,n,r,...i){let a=X(e,t,r,{type:UO,start:n});n.end=a;for(let e of i)e===void 0?Y(n,a):(Y(n,e.left),Y(e.right,a));let o={left:n,right:a};return e.decisionMap[LO(t,pk(r),r.idx)]=n,o}o(fk,`makeAlts`);function pk(e){if(e instanceof uv)return`Alternation`;if(e instanceof ov)return`Option`;if(e instanceof W)return`Repetition`;if(e instanceof lv)return`RepetitionWithSeparator`;if(e instanceof sv)return`RepetitionMandatory`;if(e instanceof cv)return`RepetitionMandatoryWithSeparator`;throw Error(`Invalid production type encountered`)}o(pk,`getProdType`);function mk(e,t){let n=t.length;for(let r=0;re.alt)}get key(){let e=``;for(let t in this.map)e+=t+`:`;return e}};function Sk(e,t=!0){return`${t?`a${e.alt}`:``}s${e.state.stateNumber}:${e.stack.map(e=>e.stateNumber.toString()).join(`_`)}`}o(Sk,`getATNConfigKey`);function Ck(e,t,n){for(var r=-1,i=e.length;++r0&&n(s)?t>1?Mk(s,t-1,n,r,i):aT(i,s):r||(i[i.length]=s)}return i}o(Mk,`baseFlatten`);var Nk=Mk;function Pk(e,t){return Nk(MO(e,t),1)}o(Pk,`flatMap`);var Fk=Pk;function Ik(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a-1}o(Wk,`arrayIncludes`);var Gk=Wk;function Kk(e,t,n){for(var r=-1,i=e==null?0:e.length;++r=Zk){var l=t?null:Xk(e);if(l)return Bw(l);o=!1,i=jw,c=new Dw}else c=t?[]:s;outer:for(;++r{let i=r.toString(),a=n[i];return a===void 0?(a={atnStartState:e,decision:t,states:{}},n[i]=a,a):a}}o(xA,`createDFACache`);var SA=class{static{o(this,`PredicateSet`)}constructor(){this.predicates=[]}is(e){return e>=this.predicates.length||this.predicates[e]}set(e,t){this.predicates[e]=t}toString(){let e=``,t=this.predicates.length;for(let n=0;nconsole.log(e))}initialize(e){this.atn=QO(e.rules),this.dfas=EA(this.atn)}validateAmbiguousAlternationAlternatives(){return[]}validateEmptyOrAlternatives(){return[]}buildLookaheadForAlternation(e){let{prodOccurrence:t,rule:n,hasPredicates:r,dynamicTokensEnabled:i}=e,a=this.dfas,o=this.logging,s=LO(n,`Alternation`,t),c=this.atn.decisionMap[s].decision,l=MO(bb({maxLookahead:1,occurrence:t,prodType:`Alternation`,rule:n}),e=>MO(e,e=>e[0]));if(TA(l,!1)&&!i){let e=bA(l,(e,t,n)=>(lA(t,t=>{t&&(e[t.tokenTypeIdx]=n,lA(t.categoryMatches,t=>{e[t]=n}))}),e),{});return r?function(t){let n=this.LA(1),r=e[n.tokenTypeIdx];if(t!==void 0&&r!==void 0){let e=t[r]?.GATE;if(e!==void 0&&e.call(this)===!1)return}return r}:function(){let t=this.LA(1);return e[t.tokenTypeIdx]}}return r?function(e){let t=new SA,n=e===void 0?0:e.length;for(let r=0;rMO(e,e=>e[0]));if(TA(l)&&l[0][0]&&!i){let e=l[0],t=rA(e);if(t.length===1&&mA(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=bA(t,(e,t)=>(t!==void 0&&(e[t.tokenTypeIdx]=!0,lA(t.categoryMatches,t=>{e[t]=!0})),e),{});return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){let e=DA.call(this,a,c,CA,o);return typeof e!=`object`&&e===0}}};function TA(e,t=!0){let n=new Set;for(let r of e){let e=new Set;for(let i of r){if(i===void 0){if(t)break;return!1}let r=[i.tokenTypeIdx].concat(i.categoryMatches);for(let t of r)if(n.has(t)){if(!e.has(t))return!1}else n.add(t),e.add(t)}}return!0}o(TA,`isLL1Sequence`);function EA(e){let t=e.decisionStates.length,n=Array(t);for(let r=0;rHy(e)).join(`, `),n=e.production.idx===0?``:e.production.idx,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(`, `)}> in <${MA(e.production)}${n}> inside <${e.topLevelRule.name}> Rule, +<${t}> may appears as a prefix path in all these alternatives. +`;return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r}o(jA,`buildAmbiguityError`);function MA(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(MA,`getProductionDslName`);function NA(e,t,n){return{actualToken:n,possibleTokenTypes:tA(Fk(t.configs.elements,e=>e.state.transitions).filter(e=>e instanceof YO).map(e=>e.tokenType),e=>e.tokenTypeIdx),tokenPath:e}}o(NA,`buildAdaptivePredictError`);function PA(e,t){return e.edges[t.tokenTypeIdx]}o(PA,`getExistingTargetState`);function FA(e,t,n){let r=new xk,i=[];for(let a of e.elements){if(n.is(a.alt)===!1)continue;if(a.state.type===HO){i.push(a);continue}let e=a.state.transitions.length;for(let n=0;n0&&!WA(a))for(let e of i)a.add(e);return a}o(FA,`computeReachSet`);function IA(e,t){if(e instanceof YO&&rb(t,e.tokenType))return e.target}o(IA,`getReachableTarget`);function LA(e,t){let n;for(let r of e.elements)if(t.is(r.alt)===!0){if(n===void 0)n=r.alt;else if(n!==r.alt)return}return n}o(LA,`getUniqueAlt`);function RA(e){return{configs:e,edges:{},isAcceptState:!1,prediction:-1}}o(RA,`newDFAState`);function zA(e,t,n,r){return r=BA(e,r),t.edges[n.tokenTypeIdx]=r,r}o(zA,`addDFAEdge`);function BA(e,t){if(t===bk)return t;let n=t.configs.key,r=e.states[n];return r===void 0?(t.configs.finalize(),e.states[n]=t,t):r}o(BA,`addDFAState`);function VA(e){let t=new xk,n=e.transitions.length;for(let r=0;r0){let n=[...e.stack];HA({state:n.pop(),alt:e.alt,stack:n},t)}else t.add(e);return}n.epsilonOnlyTransitions||t.add(e);let r=n.transitions.length;for(let i=0;i1)return!0;return!1}o(JA,`hasConflictingAltSet`);function YA(e){for(let t of Array.from(e.values()))if(Object.keys(t).length===1)return!0;return!1}o(YA,`hasStateAssociatedWithOneAlt`),ht();var XA=class{static{o(this,`CstNodeBuilder`)}constructor(){this.nodeStack=[]}get current(){return this.nodeStack[this.nodeStack.length-1]??this.rootNode}buildRootNode(e){return this.rootNode=new tj(e),this.rootNode.root=this.rootNode,this.nodeStack=[this.rootNode],this.rootNode}buildCompositeNode(e){let t=new $A;return t.grammarSource=e,t.root=this.rootNode,this.current.content.push(t),this.nodeStack.push(t),t}buildLeafNode(e,t){let n=new QA(e.startOffset,e.image.length,zi(e),e.tokenType,!t);return n.grammarSource=t,n.root=this.rootNode,this.current.content.push(n),n}removeNode(e){let t=e.container;if(t){let n=t.content.indexOf(e);n>=0&&t.content.splice(n,1)}}addHiddenNodes(e){let t=[];for(let n of e){let e=new QA(n.startOffset,n.image.length,zi(n),n.tokenType,!0);e.root=this.rootNode,t.push(e)}let n=this.current,r=!1;if(n.content.length>0){n.content.push(...t);return}for(;n.container;){let e=n.container.content.indexOf(n);if(e>0){n.container.content.splice(e,0,...t),r=!0;break}n=n.container}r||this.rootNode.content.unshift(...t)}construct(e){let t=this.current;typeof e.$type==`string`&&!e.$infixName&&(this.current.astNode=e),e.$cstNode=t;let n=this.nodeStack.pop();n?.content.length===0&&this.removeNode(n)}},ZA=class{static{o(this,`AbstractCstNode`)}get hidden(){return!1}get astNode(){let e=typeof this._astNode?.$type==`string`?this._astNode:this.container?.astNode;if(!e)throw Error(`This node has no associated AST element`);return e}set astNode(e){this._astNode=e}get text(){return this.root.fullText.substring(this.offset,this.end)}},QA=class extends ZA{static{o(this,`LeafCstNodeImpl`)}get offset(){return this._offset}get length(){return this._length}get end(){return this._offset+this._length}get hidden(){return this._hidden}get tokenType(){return this._tokenType}get range(){return this._range}constructor(e,t,n,r,i=!1){super(),this._hidden=i,this._offset=e,this._tokenType=r,this._length=t,this._range=n}},$A=class extends ZA{static{o(this,`CompositeCstNodeImpl`)}constructor(){super(...arguments),this.content=new ej(this)}get offset(){return this.firstNonHiddenNode?.offset??0}get length(){return this.end-this.offset}get end(){return this.lastNonHiddenNode?.end??0}get range(){let e=this.firstNonHiddenNode,t=this.lastNonHiddenNode;if(e&&t){if(this._rangeCache===void 0){let{range:n}=e,{range:r}=t;this._rangeCache={start:n.start,end:r.end.line=0;e--){let t=this.content[e];if(!t.hidden)return t}return this.content[this.content.length-1]}},ej=class e extends Array{static{o(this,`CstNodeContainer`)}constructor(t){super(),this.parent=t,Object.setPrototypeOf(this,e.prototype)}push(...e){return this.addParents(e),super.push(...e)}unshift(...e){return this.addParents(e),super.unshift(...e)}splice(e,t,...n){return this.addParents(n),super.splice(e,t,...n)}addParents(e){for(let t of e)t.container=this.parent}},tj=class extends $A{static{o(this,`RootCstNodeImpl`)}get text(){return this._text.substring(this.offset,this.end)}get fullText(){return this._text}constructor(e){super(),this._text=``,this._text=e??``}},nj=Symbol(`Datatype`);function rj(e){return e.$type===nj}o(rj,`isDataTypeNode`);var ij=`​`,aj=o(e=>e.endsWith(ij)?e:e+ij,`withRuleSuffix`),oj=class{static{o(this,`AbstractLangiumParser`)}constructor(e){this._unorderedGroups=new Map,this.allRules=new Map,this.lexer=e.parser.Lexer;let t=this.lexer.definition,n=e.LanguageMetaData.mode===`production`;this.wrapper=e.shared.profilers.LangiumProfiler?.isActive(`parsing`)?new pj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider},e.shared.profilers.LangiumProfiler.createTask(`parsing`,e.LanguageMetaData.languageId)):new fj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider})}alternatives(e,t){this.wrapper.wrapOr(e,t)}optional(e,t){this.wrapper.wrapOption(e,t)}many(e,t){this.wrapper.wrapMany(e,t)}atLeastOne(e,t){this.wrapper.wrapAtLeastOne(e,t)}getRule(e){return this.allRules.get(e)}isRecording(){return this.wrapper.IS_RECORDING}get unorderedGroups(){return this._unorderedGroups}getRuleStack(){return this.wrapper.RULE_STACK}finalize(){this.wrapper.wrapSelfAnalysis()}},sj=class extends oj{static{o(this,`LangiumParser`)}get current(){return this.stack[this.stack.length-1]}constructor(e){super(e),this.nodeBuilder=new XA,this.stack=[],this.assignmentMap=new Map,this.operatorPrecedence=new Map,this.linker=e.references.Linker,this.converter=e.parser.ValueConverter,this.astReflection=e.shared.AstReflection}rule(e,t){let n=this.computeRuleType(e),r;Dr(e)&&(r=e.name,this.registerPrecedenceMap(e));let i=this.wrapper.DEFINE_RULE(aj(e.name),this.startImplementation(n,r,t).bind(this));return this.allRules.set(e.name,i),Yr(e)&&e.entry&&(this.mainRule=i),i}registerPrecedenceMap(e){let t=e.name,n=new Map;for(let t=0;t0&&(t=this.construct()),t===void 0)throw Error(`No result from parser`);if(this.stack.length>0)throw Error(`Parser stack is not empty after parsing`);return t}startImplementation(e,t,n){return r=>{let i=!this.isRecording()&&e!==void 0;if(i){let n={$type:e};this.stack.push(n),e===nj?n.value=``:t!==void 0&&(n.$infixName=t)}return n(r),i?this.construct():void 0}}extractHiddenTokens(e){let t=this.lexerResult.hidden;if(!t.length)return[];let n=e.startOffset;for(let e=0;en)return t.splice(0,e);return t.splice(0,t.length)}consume(e,t,n){let r=this.wrapper.wrapConsume(e,t);if(!this.isRecording()&&this.isValidToken(r)){let e=this.extractHiddenTokens(r);this.nodeBuilder.addHiddenNodes(e);let t=this.nodeBuilder.buildLeafNode(r,n),{assignment:i,crossRef:a}=this.getAssignment(n),o=this.current;if(i){let e=Fr(n)?r.image:this.converter.convert(r.image,t);this.assign(i.operator,i.feature,e,t,a)}else if(rj(o)){let e=r.image;Fr(n)||(e=this.converter.convert(e,t).toString()),o.value+=e}}}isValidToken(e){return!e.isInsertedInRecovery&&!isNaN(e.startOffset)&&typeof e.endOffset==`number`&&!isNaN(e.endOffset)}subrule(e,t,n,r,i){let a;!this.isRecording()&&!n&&(a=this.nodeBuilder.buildCompositeNode(r));let o;try{o=this.wrapper.wrapSubrule(e,t,i)}finally{this.isRecording()||(o===void 0&&!n&&(o=this.construct()),o!==void 0&&a&&a.length>0&&this.performSubruleAssignment(o,r,a))}}performSubruleAssignment(e,t,n){let{assignment:r,crossRef:i}=this.getAssignment(t);if(r)this.assign(r.operator,r.feature,e,n,i);else if(!r){let t=this.current;if(rj(t))t.value+=e.toString();else if(typeof e==`object`&&e){let n=this.assignWithoutOverride(e,t);this.stack.pop(),this.stack.push(n)}}}action(e,t){if(!this.isRecording()){let n=this.current;if(t.feature&&t.operator){n=this.construct(),this.nodeBuilder.removeNode(n.$cstNode),this.nodeBuilder.buildCompositeNode(t).content.push(n.$cstNode);let r={$type:e};this.stack.push(r),this.assign(t.operator,t.feature,n,n.$cstNode)}else n.$type=e}}construct(){if(this.isRecording())return;let e=this.stack.pop();return this.nodeBuilder.construct(e),`$infixName`in e?this.constructInfix(e,this.operatorPrecedence.get(e.$infixName)):rj(e)?this.converter.convert(e.value,e.$cstNode):(Fn(this.astReflection,e),e)}constructInfix(e,t){let n=e.parts;if(!Array.isArray(n)||n.length===0)return;let r=e.operators;if(!Array.isArray(r)||n.length<2)return n[0];let i=0,a=-1;for(let e=0;ea?(a=o.precedence,i=e):o.precedence===a&&(o.rightAssoc||(i=e))}let o=r.slice(0,i),s=r.slice(i+1),c=n.slice(0,i+1),l=n.slice(i+1),u={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:c,operators:o},d={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:l,operators:s},f=this.constructInfix(u,t),p=this.constructInfix(d,t);return{$type:e.$type,$cstNode:e.$cstNode,left:f,operator:r[i],right:p}}getAssignment(e){if(!this.assignmentMap.has(e)){let t=Tn(e,rr);this.assignmentMap.set(e,{assignment:t,crossRef:t&&pr(t.terminal)?t.terminal.isMulti?`multi`:`single`:void 0})}return this.assignmentMap.get(e)}assign(e,t,n,r,i){let a=this.current,o;switch(o=i===`single`&&typeof n==`string`?this.linker.buildReference(a,t,r,n):i===`multi`&&typeof n==`string`?this.linker.buildMultiReference(a,t,r,n):n,e){case`=`:a[t]=o;break;case`?=`:a[t]=!0;break;case`+=`:Array.isArray(a[t])||(a[t]=[]),a[t].push(o)}}assignWithoutOverride(e,t){for(let[n,r]of Object.entries(t)){let t=e[n];t===void 0?e[n]=r:Array.isArray(t)&&Array.isArray(r)&&(r.push(...t),e[n]=r)}let n=e.$cstNode;return n&&(n.astNode=void 0,e.$cstNode=void 0),e}get definitionErrors(){return this.wrapper.definitionErrors}},cj=class{static{o(this,`AbstractParserErrorMessageProvider`)}buildMismatchTokenMessage(e){return ib.buildMismatchTokenMessage(e)}buildNotAllInputParsedMessage(e){return ib.buildNotAllInputParsedMessage(e)}buildNoViableAltMessage(e){return ib.buildNoViableAltMessage(e)}buildEarlyExitMessage(e){return ib.buildEarlyExitMessage(e)}},lj=class extends cj{static{o(this,`LangiumParserErrorMessageProvider`)}buildMismatchTokenMessage({expected:e,actual:t}){return`Expecting ${e.LABEL?"`"+e.LABEL+"`":e.name.endsWith(`:KW`)?`keyword '${e.name.substring(0,e.name.length-3)}'`:`token of type '${e.name}'`} but found \`${t.image}\`.`}buildNotAllInputParsedMessage({firstRedundant:e}){return`Expecting end of file but found \`${e.image}\`.`}},uj=class extends oj{static{o(this,`LangiumCompletionParser`)}constructor(){super(...arguments),this.tokens=[],this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}action(){}construct(){}parse(e){this.resetState();let t=this.lexer.tokenize(e,{mode:`partial`});return this.tokens=t.tokens,this.wrapper.input=[...this.tokens],this.mainRule.call(this.wrapper,{}),this.unorderedGroups.clear(),{tokens:this.tokens,elementStack:[...this.lastElementStack],tokenIndex:this.nextTokenIndex}}rule(e,t){let n=this.wrapper.DEFINE_RULE(aj(e.name),this.startImplementation(t).bind(this));return this.allRules.set(e.name,n),e.entry&&(this.mainRule=n),n}resetState(){this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}startImplementation(e){return t=>{let n=this.keepStackSize();try{e(t)}finally{this.resetStackSize(n)}}}removeUnexpectedElements(){this.elementStack.splice(this.stackSize)}keepStackSize(){let e=this.elementStack.length;return this.stackSize=e,e}resetStackSize(e){this.removeUnexpectedElements(),this.stackSize=e}consume(e,t,n){this.wrapper.wrapConsume(e,t),this.isRecording()||(this.lastElementStack=[...this.elementStack,n],this.nextTokenIndex=this.currIdx+1)}subrule(e,t,n,r,i){this.before(r),this.wrapper.wrapSubrule(e,t,i),this.after(r)}before(e){this.isRecording()||this.elementStack.push(e)}after(e){if(!this.isRecording()){let t=this.elementStack.lastIndexOf(e);t>=0&&this.elementStack.splice(t)}}get currIdx(){return this.wrapper.currIdx}},dj={recoveryEnabled:!0,nodeLocationTracking:`full`,skipValidations:!0,errorMessageProvider:new lj},fj=class extends gS{static{o(this,`ChevrotainWrapper`)}constructor(e,t){let n=t&&`maxLookahead`in t;super(e,{...dj,lookaheadStrategy:n?new kx({maxLookahead:t.maxLookahead}):new wA({logging:t.skipValidations?()=>{}:void 0}),...t})}get IS_RECORDING(){return this.RECORDING_PHASE}DEFINE_RULE(e,t,n){return this.RULE(e,t,n)}wrapSelfAnalysis(){this.performSelfAnalysis()}wrapConsume(e,t){return this.consume(e,t,void 0)}wrapSubrule(e,t,n){return this.subrule(e,t,{ARGS:[n]})}wrapOr(e,t){this.or(e,t)}wrapOption(e,t){this.option(e,t)}wrapMany(e,t){this.many(e,t)}wrapAtLeastOne(e,t){this.atLeastOne(e,t)}rule(e){return e.call(this,{})}},pj=class extends fj{static{o(this,`ProfilerWrapper`)}constructor(e,t,n){super(e,t),this.task=n}rule(e){this.task.start(),this.task.startSubTask(this.ruleName(e));try{return super.rule(e)}finally{this.task.stopSubTask(this.ruleName(e)),this.task.stop()}}ruleName(e){return e.ruleName}subrule(e,t,n){this.task.startSubTask(this.ruleName(t));try{return super.subrule(e,t,n)}finally{this.task.stopSubTask(this.ruleName(t))}}};function mj(e,t,n){return hj({parser:t,tokens:n,ruleNames:new Map},e),t}o(mj,`createParser`);function hj(e,t){let n=Na(t,!1),r=N(t.rules).filter(Yr).filter(e=>n.has(e));for(let t of r){let n={...e,consume:1,optional:1,subrule:1,many:1,or:1};e.parser.rule(t,_j(n,t.definition))}let i=N(t.rules).filter(Dr).filter(e=>n.has(e));for(let t of i)e.parser.rule(t,gj(e,t))}o(hj,`buildRules`);function gj(e,t){let n=t.call.rule.ref;if(!n)throw Error(`Could not resolve reference to infix operator rule: `+t.call.rule.$refText);if(hi(n))throw Error(`Cannot use terminal rule in infix expression`);let r=t.operators.precedences.flatMap(e=>e.operators),i={$type:`Group`,elements:[]},a={$container:i,$type:`Assignment`,feature:`parts`,operator:`+=`,terminal:t.call},s={$container:i,$type:`Group`,elements:[],cardinality:`*`};i.elements.push(a,s);let c={$container:s,$type:`Assignment`,feature:`operators`,operator:`+=`,terminal:{$type:`Alternatives`,elements:r}},l={...a,$container:s};s.elements.push(c,l);let u=r.map(t=>e.tokens[t.value]).map((t,n)=>({ALT:o(()=>e.parser.consume(n,t,c),`ALT`)})),d;return t=>{d??=kj(e,n),e.parser.subrule(0,d,!1,a,t),e.parser.many(0,{DEF:o(()=>{e.parser.alternatives(0,u),e.parser.subrule(1,d,!1,l,t)},`DEF`)})}}o(gj,`buildInfixRule`);function _j(e,t,n=!1){let r;if(Fr(t))r=Dj(e,t);else if(Yn(t))r=vj(e,t);else if(rr(t))r=_j(e,t.terminal);else if(pr(t))r=Ej(e,t);else if(ri(t))r=yj(e,t);else if(Zn(t))r=Sj(e,t);else if(Di(t))r=Cj(e,t);else if(Cr(t))r=wj(e,t);else if(_r(t)){let n=e.consume++;r=o(()=>e.parser.consume(n,tb,t),`method`)}else throw new ia(t.$cstNode,`Unexpected element type: ${t.$type}`);return Oj(e,n?void 0:Tj(t),r,t.cardinality)}o(_j,`buildElement`);function vj(e,t){let n=no(t);return()=>e.parser.action(n,t)}o(vj,`buildAction`);function yj(e,t){let n=t.rule.ref;if(Un(n)){let r=e.subrule++,i=Yr(n)&&n.fragment,a=t.arguments.length>0?bj(n,t.arguments):()=>({}),o;return s=>{o??=kj(e,n),e.parser.subrule(r,o,i,t,a(s))}}if(hi(n)){let r=e.consume++,i=jj(e,n.name);return()=>e.parser.consume(r,i,t)}if(n)aa(n);else throw new ia(t.$cstNode,`Undefined rule: ${t.rule.$refText}`)}o(yj,`buildRuleCall`);function bj(e,t){if(t.some(e=>e.calledByName)){let e=t.map(e=>({parameterName:e.parameter?.ref?.name,predicate:xj(e.value)}));return t=>{let n={};for(let{parameterName:r,predicate:i}of e)r&&(n[r]=i(t));return n}}{let n=t.map(e=>xj(e.value));return t=>{let r={};for(let i=0;it(e)||n(e)}if(dr(e)){let t=xj(e.left),n=xj(e.right);return e=>t(e)&&n(e)}if(Vr(e)){let t=xj(e.value);return e=>!t(e)}if(qr(e)){let t=e.parameter.ref.name;return e=>e!==void 0&&e[t]===!0}if(ar(e)){let t=!!e.true;return()=>t}aa(e)}o(xj,`buildPredicate`);function Sj(e,t){if(t.elements.length===1)return _j(e,t.elements[0]);{let n=[];for(let r of t.elements){let t={ALT:_j(e,r,!0)},i=Tj(r);i&&(t.GATE=xj(i)),n.push(t)}let r=e.or++;return t=>e.parser.alternatives(r,n.map(e=>{let n={ALT:o(()=>e.ALT(t),`ALT`)},r=e.GATE;return r&&(n.GATE=()=>r(t)),n}))}}o(Sj,`buildAlternatives`);function Cj(e,t){if(t.elements.length===1)return _j(e,t.elements[0]);let n=[];for(let r of t.elements){let t={ALT:_j(e,r,!0)},i=Tj(r);i&&(t.GATE=xj(i)),n.push(t)}let r=e.or++,i=o((e,t)=>`uGroup_${e}_${t.getRuleStack().join(`-`)}`,`idFunc`),a=o(t=>e.parser.alternatives(r,n.map((n,a)=>{let s={ALT:o(()=>!0,`ALT`)},c=e.parser;s.ALT=()=>{if(n.ALT(t),!c.isRecording()){let e=i(r,c);c.unorderedGroups.get(e)||c.unorderedGroups.set(e,[]);let t=c.unorderedGroups.get(e);t?.[a]===void 0&&(t[a]=!0)}};let l=n.GATE;return s.GATE=l?()=>l(t):()=>!c.unorderedGroups.get(i(r,c))?.[a],s})),`alternatives`),s=Oj(e,Tj(t),a,`*`);return t=>{s(t),e.parser.isRecording()||e.parser.unorderedGroups.delete(i(r,e.parser))}}o(Cj,`buildUnorderedGroup`);function wj(e,t){let n=t.elements.map(t=>_j(e,t));return e=>n.forEach(t=>t(e))}o(wj,`buildGroup`);function Tj(e){if(Cr(e))return e.guardCondition}o(Tj,`getGuardCondition`);function Ej(e,t,n=t.terminal){if(!n){if(!t.type.ref)throw Error(`Could not resolve reference to type: `+t.type.$refText);let n=Ga(t.type.ref)?.terminal;if(!n)throw Error(`Could not find name assignment for type: `+no(t.type.ref));return Ej(e,t,n)}if(ri(n)&&Yr(n.rule.ref)){let r=n.rule.ref,i=e.subrule++,a;return n=>{a??=kj(e,r),e.parser.subrule(i,a,!1,t,n)}}if(ri(n)&&hi(n.rule.ref)){let r=e.consume++,i=jj(e,n.rule.ref.name);return()=>e.parser.consume(r,i,t)}if(Fr(n)){let r=e.consume++,i=jj(e,n.value);return()=>e.parser.consume(r,i,t)}throw Error(`Could not build cross reference parser`)}o(Ej,`buildCrossReference`);function Dj(e,t){let n=e.consume++,r=e.tokens[t.value];if(!r)throw Error(`Could not find token for keyword: `+t.value);return()=>e.parser.consume(n,r,t)}o(Dj,`buildKeyword`);function Oj(e,t,n,r){let i=t&&xj(t);if(!r){if(i){let t=e.or++;return r=>e.parser.alternatives(t,[{ALT:o(()=>n(r),`ALT`),GATE:o(()=>i(r),`GATE`)},{ALT:mS(),GATE:o(()=>!i(r),`GATE`)}])}return n}if(r===`*`){let t=e.many++;return r=>e.parser.many(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}if(r===`+`){let t=e.many++;if(i){let r=e.or++;return a=>e.parser.alternatives(r,[{ALT:o(()=>e.parser.atLeastOne(t,{DEF:o(()=>n(a),`DEF`)}),`ALT`),GATE:o(()=>i(a),`GATE`)},{ALT:mS(),GATE:o(()=>!i(a),`GATE`)}])}return r=>e.parser.atLeastOne(t,{DEF:o(()=>n(r),`DEF`)})}if(r===`?`){let t=e.optional++;return r=>e.parser.optional(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}aa(r)}o(Oj,`wrap`);function kj(e,t){let n=Aj(e,t),r=e.parser.getRule(n);if(!r)throw Error(`Rule "${n}" not found."`);return r}o(kj,`getRule`);function Aj(e,t){if(Un(t))return t.name;if(e.ruleNames.has(t))return e.ruleNames.get(t);{let n=t,r=n.$container,i=t.$type;for(;!Yr(r);)(Cr(r)||Zn(r)||Di(r))&&(i=r.elements.indexOf(n).toString()+`:`+i),n=r,r=r.$container;return i=r.name+`:`+i,e.ruleNames.set(t,i),i}}o(Aj,`getRuleName`);function jj(e,t){let n=e.tokens[t];if(!n)throw Error(`Token "${t}" not found."`);return n}o(jj,`getToken`);function Mj(e){let t=e.Grammar,n=e.parser.Lexer,r=new uj(e);return mj(t,r,n.definition),r.finalize(),r}o(Mj,`createCompletionParser`);function Nj(e){let t=Pj(e);return t.finalize(),t}o(Nj,`createLangiumParser`);function Pj(e){let t=e.Grammar,n=e.parser.Lexer;return mj(t,new sj(e),n.definition)}o(Pj,`prepareLangiumParser`);var Fj=class{static{o(this,`DefaultTokenBuilder`)}constructor(){this.diagnostics=[]}buildTokens(e,t){let n=N(Na(e,!1)),r=this.buildTerminalTokens(n),i=this.buildKeywordTokens(n,r,t);return i.push(...r),i}flushLexingReport(e){return{diagnostics:this.popDiagnostics()}}popDiagnostics(){let e=[...this.diagnostics];return this.diagnostics=[],e}buildTerminalTokens(e){return e.filter(hi).filter(e=>!e.fragment).map(e=>this.buildTerminalToken(e)).toArray()}buildTerminalToken(e){let t=oo(e),n=this.requiresCustomPattern(t)?this.regexPatternFunction(t):t,r={name:e.name,PATTERN:n};return typeof n==`function`&&(r.LINE_BREAKS=!0),e.hidden&&(r.GROUP=Da(t)?Vy.SKIPPED:`hidden`),r}requiresCustomPattern(e){return!!(e.flags.includes(`u`)||e.flags.includes(`s`))}regexPatternFunction(e){let t=new RegExp(e,e.flags+`y`);return(e,n)=>(t.lastIndex=n,t.exec(e))}buildKeywordTokens(e,t,n){return e.filter(Un).flatMap(e=>jn(e).filter(Fr)).distinct(e=>e.value).toArray().sort((e,t)=>t.value.length-e.value.length).map(e=>this.buildKeywordToken(e,t,!!n?.caseInsensitive))}buildKeywordToken(e,t,n){let r=this.buildKeywordPattern(e,n),i={name:e.value,PATTERN:r,LONGER_ALT:this.findLongerAlt(e,t)};return typeof r==`function`&&(i.LINE_BREAKS=!0),i}buildKeywordPattern(e,t){return t?new RegExp(Oa(e.value),`i`):e.value}findLongerAlt(e,t){return t.reduce((t,n)=>{let r=n?.PATTERN;return r?.source&&ka(`^`+r.source+`$`,e.value)&&t.push(n),t},[])}},Ij=class{static{o(this,`DefaultValueConverter`)}convert(e,t){let n=t.grammarSource;if(pr(n)&&(n=Ia(n)),ri(n)){let r=n.rule.ref;if(!r)throw Error(`This cst node was not parsed by a rule.`);return this.runConverter(r,e,t)}return e}runConverter(e,t,n){switch(e.name.toUpperCase()){case`INT`:return Lj.convertInt(t);case`STRING`:return Lj.convertString(t);case`ID`:return Lj.convertID(t)}switch(ao(e)?.toLowerCase()){case`number`:return Lj.convertNumber(t);case`boolean`:return Lj.convertBoolean(t);case`bigint`:return Lj.convertBigint(t);case`date`:return Lj.convertDate(t);default:return t}}},Lj;(function(e){function t(e){let t=``;for(let r=1;r{typeof setImmediate>`u`?setTimeout(e,0):setImmediate(e)})}o(Rj,`delayNextTick`);var zj=0,Bj=10;function Vj(){return zj=performance.now(),new Z.CancellationTokenSource}o(Vj,`startCancelableOperation`);function Hj(e){Bj=e}o(Hj,`setInterruptionPeriod`);var Uj=Symbol(`OperationCancelled`);function Wj(e){return e===Uj}o(Wj,`isOperationCancelled`);async function Gj(e){if(e===Z.CancellationToken.None)return;let t=performance.now();if(t-zj>=Bj&&(zj=t,await Rj(),zj=performance.now()),e.isCancellationRequested)throw Uj}o(Gj,`interruptAndCheck`);var Kj=class{static{o(this,`Deferred`)}constructor(){this.promise=new Promise((e,t)=>{this.resolve=t=>(e(t),this),this.reject=e=>(t(e),this)})}},qj=class e{static{o(this,`FullTextDocument`)}constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(t,n){for(let n of t)if(e.isIncremental(n)){let e=Qj(n.range),t=this.offsetAt(e.start),r=this.offsetAt(e.end);this._content=this._content.substring(0,t)+n.text+this._content.substring(r,this._content.length);let i=Math.max(e.start.line,0),a=Math.max(e.end.line,0),o=this._lineOffsets,s=Xj(n.text,!1,t);if(a-i===s.length)for(let e=0,t=s.length;ee?r=i:n=i+1}let i=n-1;return e=this.ensureBeforeEOL(e,t[i]),{line:i,character:e-t[i]}}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line];if(e.character<=0)return n;let r=e.line+1t&&Zj(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}static isFull(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}},Jj;(function(e){function t(e,t,n,r){return new qj(e,t,n,r)}o(t,`create`),e.create=t;function n(e,t,n){if(e instanceof qj)return e.update(t,n),e;throw Error(`TextDocument.update: document must be created by TextDocument.create`)}o(n,`update`),e.update=n;function r(e,t){let n=e.getText(),r=Yj(t.map($j),(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),i=0,a=[];for(let t of r){let r=e.offsetAt(t.range.start);if(ri&&a.push(n.substring(i,r)),t.newText.length&&a.push(t.newText),i=e.offsetAt(t.range.end)}return a.push(n.substr(i)),a.join(``)}o(r,`applyEdits`),e.applyEdits=r})(Jj||={});function Yj(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),i=e.slice(n);Yj(r,t),Yj(i,t);let a=0,o=0,s=0;for(;an.line||t.line===n.line&&t.character>n.character?{start:n,end:t}:e}o(Qj,`getWellformedRange`);function $j(e){let t=Qj(e.range);return t===e.range?e:{newText:e.newText,range:t}}o($j,`getWellformedEdit`);var eM;(()=>{var e={975:e=>{function t(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}o(t,`e`);function n(e,t){for(var n,r=``,i=0,a=-1,o=0,s=0;s<=e.length;++s){if(s2){var c=r.lastIndexOf(`/`);if(c!==r.length-1){c===-1?(r=``,i=0):i=(r=r.slice(0,c)).length-1-r.lastIndexOf(`/`),a=s,o=0;continue}}else if(r.length===2||r.length===1){r=``,i=0,a=s,o=0;continue}}t&&(r.length>0?r+=`/..`:r=`..`,i=2)}else r.length>0?r+=`/`+e.slice(a+1,s):r=e.slice(a+1,s),i=s-a-1}a=s,o=0}else n===46&&o!==-1?++o:o=-1}return r}o(n,`r`);var r={resolve:o(function(){for(var e,r=``,i=!1,a=arguments.length-1;a>=-1&&!i;a--){var o;a>=0?o=arguments[a]:(e===void 0&&(e=process.cwd()),o=e),t(o),o.length!==0&&(r=o+`/`+r,i=o.charCodeAt(0)===47)}return r=n(r,!i),i?r.length>0?`/`+r:`/`:r.length>0?r:`.`},`resolve`),normalize:o(function(e){if(t(e),e.length===0)return`.`;var r=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return(e=n(e,!r)).length!==0||r||(e=`.`),e.length>0&&i&&(e+=`/`),r?`/`+e:e},`normalize`),isAbsolute:o(function(e){return t(e),e.length>0&&e.charCodeAt(0)===47},`isAbsolute`),join:o(function(){if(arguments.length===0)return`.`;for(var e,n=0;n0&&(e===void 0?e=i:e+=`/`+i)}return e===void 0?`.`:r.normalize(e)},`join`),relative:o(function(e,n){if(t(e),t(n),e===n||(e=r.resolve(e))===(n=r.resolve(n)))return``;for(var i=1;il){if(n.charCodeAt(s+d)===47)return n.slice(s+d+1);if(d===0)return n.slice(s+d)}else o>l&&(e.charCodeAt(i+d)===47?u=d:d===0&&(u=0));break}var f=e.charCodeAt(i+d);if(f!==n.charCodeAt(s+d))break;f===47&&(u=d)}var p=``;for(d=i+u+1;d<=a;++d)d!==a&&e.charCodeAt(d)!==47||(p.length===0?p+=`..`:p+=`/..`);return p.length>0?p+n.slice(s+u):(s+=u,n.charCodeAt(s)===47&&++s,n.slice(s))},`relative`),_makeLong:o(function(e){return e},`_makeLong`),dirname:o(function(e){if(t(e),e.length===0)return`.`;for(var n=e.charCodeAt(0),r=n===47,i=-1,a=!0,o=e.length-1;o>=1;--o)if((n=e.charCodeAt(o))===47){if(!a){i=o;break}}else a=!1;return i===-1?r?`/`:`.`:r&&i===1?`//`:e.slice(0,i)},`dirname`),basename:o(function(e,n){if(n!==void 0&&typeof n!=`string`)throw TypeError(`"ext" argument must be a string`);t(e);var r,i=0,a=-1,o=!0;if(n!==void 0&&n.length>0&&n.length<=e.length){if(n.length===e.length&&n===e)return``;var s=n.length-1,c=-1;for(r=e.length-1;r>=0;--r){var l=e.charCodeAt(r);if(l===47){if(!o){i=r+1;break}}else c===-1&&(o=!1,c=r+1),s>=0&&(l===n.charCodeAt(s)?--s==-1&&(a=r):(s=-1,a=c))}return i===a?a=c:a===-1&&(a=e.length),e.slice(i,a)}for(r=e.length-1;r>=0;--r)if(e.charCodeAt(r)===47){if(!o){i=r+1;break}}else a===-1&&(o=!1,a=r+1);return a===-1?``:e.slice(i,a)},`basename`),extname:o(function(e){t(e);for(var n=-1,r=0,i=-1,a=!0,o=0,s=e.length-1;s>=0;--s){var c=e.charCodeAt(s);if(c!==47)i===-1&&(a=!1,i=s+1),c===46?n===-1?n=s:o!==1&&(o=1):n!==-1&&(o=-1);else if(!a){r=s+1;break}}return n===-1||i===-1||o===0||o===1&&n===i-1&&n===r+1?``:e.slice(n,i)},`extname`),format:o(function(e){if(typeof e!=`object`||!e)throw TypeError(`The "pathObject" argument must be of type Object. Received type `+typeof e);return(function(e,t){var n=t.dir||t.root,r=t.base||(t.name||``)+(t.ext||``);return n?n===t.root?n+r:n+`/`+r:r})(0,e)},`format`),parse:o(function(e){t(e);var n={root:``,dir:``,base:``,ext:``,name:``};if(e.length===0)return n;var r,i=e.charCodeAt(0),a=i===47;a?(n.root=`/`,r=1):r=0;for(var o=-1,s=0,c=-1,l=!0,u=e.length-1,d=0;u>=r;--u)if((i=e.charCodeAt(u))!==47)c===-1&&(l=!1,c=u+1),i===46?o===-1?o=u:d!==1&&(d=1):o!==-1&&(d=-1);else if(!l){s=u+1;break}return o===-1||c===-1||d===0||d===1&&o===c-1&&o===s+1?c!==-1&&(n.base=n.name=s===0&&a?e.slice(1,c):e.slice(s,c)):(s===0&&a?(n.name=e.slice(1,o),n.base=e.slice(1,c)):(n.name=e.slice(s,o),n.base=e.slice(s,c)),n.ext=e.slice(o,c)),s>0?n.dir=e.slice(0,s-1):a&&(n.dir=`/`),n},`parse`),sep:`/`,delimiter:`:`,win32:null,posix:null};r.posix=r,e.exports=r}},t={};function n(r){var i=t[r];if(i!==void 0)return i.exports;var a=t[r]={exports:{}};return e[r](a,a.exports,n),a.exports}o(n,`r`),n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};let i;n.r(r),n.d(r,{URI:o(()=>d,`URI`),Utils:o(()=>te,`Utils`)}),typeof process==`object`?i=process.platform===`win32`:typeof navigator==`object`&&(i=navigator.userAgent.indexOf(`Windows`)>=0);let a=/^\w[\w\d+.-]*$/,s=/^\//,c=/^\/\//;function l(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!a.test(e.scheme))throw Error(`[UriError]: Scheme contains illegal characters.`);if(e.path){if(e.authority){if(!s.test(e.path))throw Error(`[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character`)}else if(c.test(e.path))throw Error(`[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")`)}}o(l,`a`);let u=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class d{static{o(this,`l`)}static isUri(e){return e instanceof d||!!e&&typeof e.authority==`string`&&typeof e.fragment==`string`&&typeof e.path==`string`&&typeof e.query==`string`&&typeof e.scheme==`string`&&typeof e.fsPath==`string`&&typeof e.with==`function`&&typeof e.toString==`function`}scheme;authority;path;query;fragment;constructor(e,t,n,r,i,a=!1){typeof e==`object`?(this.scheme=e.scheme||``,this.authority=e.authority||``,this.path=e.path||``,this.query=e.query||``,this.fragment=e.fragment||``):(this.scheme=(function(e,t){return e||t?e:`file`})(e,a),this.authority=t||``,this.path=(function(e,t){switch(e){case`https`:case`http`:case`file`:t?t[0]!==`/`&&(t=`/`+t):t=`/`}return t})(this.scheme,n||``),this.query=r||``,this.fragment=i||``,l(this,a))}get fsPath(){return _(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:n,path:r,query:i,fragment:a}=e;return t===void 0?t=this.scheme:t===null&&(t=``),n===void 0?n=this.authority:n===null&&(n=``),r===void 0?r=this.path:r===null&&(r=``),i===void 0?i=this.query:i===null&&(i=``),a===void 0?a=this.fragment:a===null&&(a=``),t===this.scheme&&n===this.authority&&r===this.path&&i===this.query&&a===this.fragment?this:new p(t,n,r,i,a)}static parse(e,t=!1){let n=u.exec(e);return n?new p(n[2]||``,x(n[4]||``),x(n[5]||``),x(n[7]||``),x(n[9]||``),t):new p(``,``,``,``,``)}static file(e){let t=``;if(i&&(e=e.replace(/\\/g,`/`)),e[0]===`/`&&e[1]===`/`){let n=e.indexOf(`/`,2);n===-1?(t=e.substring(2),e=`/`):(t=e.substring(2,n),e=e.substring(n)||`/`)}return new p(`file`,t,e,``,``)}static from(e){let t=new p(e.scheme,e.authority,e.path,e.query,e.fragment);return l(t,!0),t}toString(e=!1){return v(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof d)return e;{let t=new p(e);return t._formatted=e.external,t._fsPath=e._sep===f?e.fsPath:null,t}}return e}}let f=i?1:void 0;class p extends d{static{o(this,`d`)}_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||=_(this,!1),this._fsPath}toString(e=!1){return e?v(this,!0):(this._formatted||=v(this,!1),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=f),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let m={58:`%3A`,47:`%2F`,63:`%3F`,35:`%23`,91:`%5B`,93:`%5D`,64:`%40`,33:`%21`,36:`%24`,38:`%26`,39:`%27`,40:`%28`,41:`%29`,42:`%2A`,43:`%2B`,44:`%2C`,59:`%3B`,61:`%3D`,32:`%20`};function h(e,t,n){let r,i=-1;for(let a=0;a=97&&o<=122||o>=65&&o<=90||o>=48&&o<=57||o===45||o===46||o===95||o===126||t&&o===47||n&&o===91||n&&o===93||n&&o===58)i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r!==void 0&&(r+=e.charAt(a));else{r===void 0&&(r=e.substr(0,a));let t=m[o];t===void 0?i===-1&&(i=a):(i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r+=t)}}return i!==-1&&(r+=encodeURIComponent(e.substring(i))),r===void 0?e:r}o(h,`m`);function g(e){let t;for(let n=0;n1&&e.scheme===`file`?`//${e.authority}${e.path}`:e.path.charCodeAt(0)===47&&(e.path.charCodeAt(1)>=65&&e.path.charCodeAt(1)<=90||e.path.charCodeAt(1)>=97&&e.path.charCodeAt(1)<=122)&&e.path.charCodeAt(2)===58?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,i&&(n=n.replace(/\//g,`\\`)),n}o(_,`v`);function v(e,t){let n=t?g:h,r=``,{scheme:i,authority:a,path:o,query:s,fragment:c}=e;if(i&&(r+=i,r+=`:`),(a||i===`file`)&&(r+=`/`,r+=`/`),a){let e=a.indexOf(`@`);if(e!==-1){let t=a.substr(0,e);a=a.substr(e+1),e=t.lastIndexOf(`:`),e===-1?r+=n(t,!1,!1):(r+=n(t.substr(0,e),!1,!1),r+=`:`,r+=n(t.substr(e+1),!1,!0)),r+=`@`}a=a.toLowerCase(),e=a.lastIndexOf(`:`),e===-1?r+=n(a,!1,!0):(r+=n(a.substr(0,e),!1,!0),r+=a.substr(e))}if(o){if(o.length>=3&&o.charCodeAt(0)===47&&o.charCodeAt(2)===58){let e=o.charCodeAt(1);e>=65&&e<=90&&(o=`/${String.fromCharCode(e+32)}:${o.substr(3)}`)}else if(o.length>=2&&o.charCodeAt(1)===58){let e=o.charCodeAt(0);e>=65&&e<=90&&(o=`${String.fromCharCode(e+32)}:${o.substr(2)}`)}r+=n(o,!0,!1)}return s&&(r+=`?`,r+=n(s,!1,!1)),c&&(r+=`#`,r+=t?c:h(c,!1,!1)),r}o(v,`b`);function y(e){try{return decodeURIComponent(e)}catch{return e.length>3?e.substr(0,3)+y(e.substr(3)):e}}o(y,`C`);let b=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(e){return e.match(b)?e.replace(b,(e=>y(e))):e}o(x,`w`);var ee=n(975);let S=ee.posix||ee;var te;(function(e){e.joinPath=function(e,...t){return e.with({path:S.join(e.path,...t)})},e.resolvePath=function(e,...t){let n=e.path,r=!1;n[0]!==`/`&&(n=`/`+n,r=!0);let i=S.resolve(n,...t);return r&&i[0]===`/`&&!e.authority&&(i=i.substring(1)),e.with({path:i})},e.dirname=function(e){if(e.path.length===0||e.path===`/`)return e;let t=S.dirname(e.path);return t.length===1&&t.charCodeAt(0)===46&&(t=``),e.with({path:t})},e.basename=function(e){return S.basename(e.path)},e.extname=function(e){return S.extname(e.path)}})(te||={}),eM=r})();var{URI:tM,Utils:nM}=eM,rM;(function(e){e.basename=nM.basename,e.dirname=nM.dirname,e.extname=nM.extname,e.joinPath=nM.joinPath,e.resolvePath=nM.resolvePath;let t=typeof process==`object`&&process?.platform===`win32`;function n(e,t){return e?.toString()===t?.toString()}o(n,`equals`),e.equals=n;function r(e,n){let r=typeof e==`string`?tM.parse(e).path:e.path,i=typeof n==`string`?tM.parse(n).path:n.path,a=r.split(`/`).filter(e=>e.length>0),o=i.split(`/`).filter(e=>e.length>0);if(t){let e=/^[A-Z]:$/;if(a[0]&&e.test(a[0])&&(a[0]=a[0].toLowerCase()),o[0]&&e.test(o[0])&&(o[0]=o[0].toLowerCase()),a[0]!==o[0])return i.substring(1)}let s=0;for(;s({name:e.name,uri:rM.joinPath(tM.parse(t),e.name).toString(),element:e.element})):[]}all(){return this.collectValues(this.root)}findAll(e){let t=this.getNode(rM.normalize(e),!1);return t?this.collectValues(t):[]}getNode(e,t){let n=e.split(`/`);e.charAt(e.length-1)===`/`&&n.pop();let r=this.root;for(let e of n){let n=r.children.get(e);if(!n){if(t)n={name:e,children:new Map,parent:r},r.children.set(e,n);else return}r=n}return r}collectValues(e){let t=[];e.element&&t.push(e.element);for(let n of e.children.values())t.push(...this.collectValues(n));return t}},Q;(function(e){e[e.Changed=0]=`Changed`,e[e.Parsed=1]=`Parsed`,e[e.IndexedContent=2]=`IndexedContent`,e[e.ComputedScopes=3]=`ComputedScopes`,e[e.Linked=4]=`Linked`,e[e.IndexedReferences=5]=`IndexedReferences`,e[e.Validated=6]=`Validated`})(Q||={});var aM=class{static{o(this,`DefaultLangiumDocumentFactory`)}constructor(e){this.serviceRegistry=e.ServiceRegistry,this.textDocuments=e.workspace.TextDocuments,this.fileSystemProvider=e.workspace.FileSystemProvider}async fromUri(e,t=Z.CancellationToken.None){let n=await this.fileSystemProvider.readFile(e);return this.createAsync(e,n,t)}fromTextDocument(e,t,n){return t??=tM.parse(e.uri),Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromString(e,t,n){return Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromModel(e,t){return this.create(t,{$model:e})}create(e,t,n){if(typeof t==`string`){let r=this.parse(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}if(`$model`in t){let n={value:t.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(n,e)}{let r=this.parse(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}async createAsync(e,t,n){if(typeof t==`string`){let r=await this.parseAsync(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}{let r=await this.parseAsync(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}createLangiumDocument(e,t,n,r){let i;if(n)i={parseResult:e,uri:t,state:Q.Parsed,references:[],textDocument:n};else{let n=this.createTextDocumentGetter(t,r);i={parseResult:e,uri:t,state:Q.Parsed,references:[],get textDocument(){return n()}}}return e.value.$document=i,i}async update(e,t){let n=e.parseResult.value.$cstNode?.root.fullText,r=this.textDocuments?.get(e.uri.toString()),i=r?r.getText():await this.fileSystemProvider.readFile(e.uri);if(r)Object.defineProperty(e,"textDocument",{value:r});else{let t=this.createTextDocumentGetter(e.uri,i);Object.defineProperty(e,"textDocument",{get:t})}return n!==i&&(e.parseResult=await this.parseAsync(e.uri,i,t),e.parseResult.value.$document=e),e.state=Q.Parsed,e}parse(e,t,n){return this.serviceRegistry.getServices(e).parser.LangiumParser.parse(t,n)}parseAsync(e,t,n){return this.serviceRegistry.getServices(e).parser.AsyncParser.parse(t,n)}createTextDocumentGetter(e,t){let n=this.serviceRegistry,r;return()=>r??=Jj.create(e.toString(),n.getServices(e).LanguageMetaData.languageId,0,t??``)}},oM=class{static{o(this,`DefaultLangiumDocuments`)}constructor(e){this.documentTrie=new iM,this.services=e,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.documentBuilder=()=>e.workspace.DocumentBuilder}get all(){return N(this.documentTrie.all())}addDocument(e){let t=e.uri.toString();if(this.documentTrie.has(t))throw Error(`A document with the URI '${t}' is already present.`);this.documentTrie.insert(t,e)}getDocument(e){let t=e.toString();return this.documentTrie.find(t)}getDocuments(e){let t=e.toString();return this.documentTrie.findAll(t)}async getOrCreateDocument(e,t){let n=this.getDocument(e);return n||(n=await this.langiumDocumentFactory.fromUri(e,t),this.addDocument(n),n)}createDocument(e,t,n){if(n)return this.langiumDocumentFactory.fromString(t,e,n).then(e=>(this.addDocument(e),e));{let n=this.langiumDocumentFactory.fromString(t,e);return this.addDocument(n),n}}hasDocument(e){return this.documentTrie.has(e.toString())}invalidateDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&this.documentBuilder().resetToState(n,Q.Changed),n}deleteDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&(n.state=Q.Changed,this.documentTrie.delete(t)),n}deleteDocuments(e){let t=e.toString(),n=this.documentTrie.findAll(t);for(let e of n)e.state=Q.Changed;return this.documentTrie.delete(t),n}},sM=Symbol(`RefResolving`),cM=class{static{o(this,`DefaultLinker`)}constructor(e){this.reflection=e.shared.AstReflection,this.langiumDocuments=()=>e.shared.workspace.LangiumDocuments,this.scopeProvider=e.references.ScopeProvider,this.astNodeLocator=e.workspace.AstNodeLocator,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async link(e,t=Z.CancellationToken.None){if(this.profiler?.isActive(`linking`)){let n=this.profiler.createTask(`linking`,this.languageId);n.start();try{for(let r of Mn(e.parseResult.value))await Gj(t),Pn(r).forEach(t=>{let i=`${r.$type}:${t.property}`;n.startSubTask(i);try{this.doLink(t,e)}finally{n.stopSubTask(i)}})}finally{n.stop()}}else for(let n of Mn(e.parseResult.value))await Gj(t),Pn(n).forEach(t=>this.doLink(t,e))}doLink(e,t){let n=e.reference;if(`_ref`in n&&n._ref===void 0){n._ref=sM;try{let t=this.getCandidate(e);dn(t)?n._ref=t:(n._nodeDescription=t,n._ref=this.loadAstNode(t)??this.createLinkingError(e,t))}catch(t){console.error(`An error occurred while resolving reference to '${n.$refText}':`,t);let r=t.message??String(t);n._ref={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${r}`}}t.references.push(n)}else if(`_items`in n&&n._items===void 0){n._items=sM;try{let t=this.getCandidates(e),r=[];if(dn(t))n._linkingError=t;else for(let e of t){let t=this.loadAstNode(e);t&&r.push({ref:t,$nodeDescription:e})}n._items=r}catch(t){n._linkingError={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${t}`},n._items=[]}t.references.push(n)}}unlink(e){for(let t of e.references)`_ref`in t?(t._ref=void 0,delete t._nodeDescription):`_items`in t&&(t._items=void 0,delete t._linkingError);e.references=[]}getCandidate(e){return this.scopeProvider.getScope(e).getElement(e.reference.$refText)??this.createLinkingError(e)}getCandidates(e){let t=this.scopeProvider.getScope(e).getElements(e.reference.$refText).distinct(e=>`${e.documentUri}#${e.path}`).toArray();return t.length>0?t:this.createLinkingError(e)}buildReference(e,t,n,r){let i=this,a={$refNode:n,$refText:r,_ref:void 0,get ref(){if(M(this._ref))return this._ref;if(un(this._nodeDescription)){let n=i.loadAstNode(this._nodeDescription);this._ref=n??i.createLinkingError({reference:a,container:e,property:t},this._nodeDescription)}else if(this._ref===void 0){this._ref=sM;let n=On(e).$document,r=i.getLinkedNode({reference:a,container:e,property:t});if(r.error&&n&&n.state0))return this._linkingError=i.createLinkingError({reference:a,container:e,property:t})}};return a}throwCyclicReferenceError(e,t,n){throw Error(`Cyclic reference resolution detected: ${this.astNodeLocator.getAstNodePath(e)}/${t} (symbol '${n}')`)}getLinkedNode(e){try{let t=this.getCandidate(e);if(dn(t))return{error:t};let n=this.loadAstNode(t);return n?{node:n,descr:t}:{descr:t,error:this.createLinkingError(e,t)}}catch(t){console.error(`An error occurred while resolving reference to '${e.reference.$refText}':`,t);let n=t.message??String(t);return{error:{info:e,message:`An error occurred while resolving reference to '${e.reference.$refText}': ${n}`}}}}loadAstNode(e){if(e.node)return e.node;let t=this.langiumDocuments().getDocument(e.documentUri);if(t)return this.astNodeLocator.getAstNode(t.parseResult.value,e.path)}createLinkingError(e,t){let n=On(e.container).$document;return n&&n.statepr(e)&&e.isMulti)}findDeclarations(e){if(e){let t=Wa(e),n=e.astNode;if(t&&n){let r=n[t.feature];if(cn(r)||ln(r))return kn(r);if(Array.isArray(r)){for(let t of r)if((cn(t)||ln(t))&&t.$refNode&&t.$refNode.offset<=e.offset&&t.$refNode.end>=e.end)return kn(t)}}if(n){let t=this.nameProvider.getNameNode(n);if(t&&(t===e||Ri(e,t)))return this.getSelfNodes(n)}}return[]}getSelfNodes(e){if(this.hasMultiReference){let t=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e)),n=this.getNodeFromReferenceDescription(t.head());if(n){for(let t of Pn(n))if(ln(t.reference)&&t.reference.items.some(t=>t.ref===e))return t.reference.items.map(e=>e.ref)}return[e]}return[e]}getNodeFromReferenceDescription(e){if(!e)return;let t=this.documents.getDocument(e.sourceUri);if(t)return this.nodeLocator.getAstNode(t.parseResult.value,e.sourcePath)}findDeclarationNodes(e){let t=this.findDeclarations(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e)??e.$cstNode;t&&n.push(t)}return n}findReferences(e,t){let n=[];t.includeDeclaration&&n.push(...this.getSelfReferences(e));let r=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e));return t.documentUri&&(r=r.filter(e=>rM.equals(e.sourceUri,t.documentUri))),n.push(...r),N(n)}getSelfReferences(e){let t=this.getSelfNodes(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e);if(t){let r=Dn(e),i=this.nodeLocator.getAstNodePath(e);n.push({sourceUri:r.uri,sourcePath:i,targetUri:r.uri,targetPath:i,segment:Bi(t),local:!0})}}return n}},fM=class{static{o(this,`MultiMap`)}constructor(e){if(this.map=new Map,e)for(let[t,n]of e)this.add(t,n)}get size(){return Sn.sum(N(this.map.values()).map(e=>e.length))}clear(){this.map.clear()}delete(e,t){if(t===void 0)return this.map.delete(e);{let n=this.map.get(e);if(n){let r=n.indexOf(t);if(r>=0)return n.length===1?this.map.delete(e):n.splice(r,1),!0}return!1}}get(e){return this.map.get(e)??[]}getStream(e){let t=this.map.get(e);return t?N(t):yn}has(e,t){if(t===void 0)return this.map.has(e);{let n=this.map.get(e);return n?n.indexOf(t)>=0:!1}}add(e,t){return this.map.has(e)?this.map.get(e).push(t):this.map.set(e,[t]),this}addAll(e,t){return this.map.has(e)?this.map.get(e).push(...t):this.map.set(e,Array.from(t)),this}forEach(e){this.map.forEach((t,n)=>t.forEach(t=>e(t,n,this)))}[Symbol.iterator](){return this.entries().iterator()}entries(){return N(this.map.entries()).flatMap(([e,t])=>t.map(t=>[e,t]))}keys(){return N(this.map.keys())}values(){return N(this.map.values()).flat()}entriesGroupedByKey(){return N(this.map.entries())}},pM=class{static{o(this,`BiMap`)}get size(){return this.map.size}constructor(e){if(this.map=new Map,this.inverse=new Map,e)for(let[t,n]of e)this.set(t,n)}clear(){this.map.clear(),this.inverse.clear()}set(e,t){return this.map.set(e,t),this.inverse.set(t,e),this}get(e){return this.map.get(e)}getKey(e){return this.inverse.get(e)}delete(e){let t=this.map.get(e);return t!==void 0&&(this.map.delete(e),this.inverse.delete(t),!0)}},mM=class{static{o(this,`DefaultScopeComputation`)}constructor(e){this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider}async collectExportedSymbols(e,t=Z.CancellationToken.None){return this.collectExportedSymbolsForNode(e.parseResult.value,e,void 0,t)}async collectExportedSymbolsForNode(e,t,n=An,r=Z.CancellationToken.None){let i=[];this.addExportedSymbol(e,i,t);for(let a of n(e))await Gj(r),this.addExportedSymbol(a,i,t);return i}addExportedSymbol(e,t,n){let r=this.nameProvider.getName(e);r&&t.push(this.descriptions.createDescription(e,r,n))}async collectLocalSymbols(e,t=Z.CancellationToken.None){let n=e.parseResult.value,r=new fM;for(let i of jn(n))await Gj(t),this.addLocalSymbol(i,e,r);return r}addLocalSymbol(e,t,n){let r=e.$container;if(r){let i=this.nameProvider.getName(e);i&&n.add(r,this.descriptions.createDescription(e,i,t))}}},hM=class{static{o(this,`StreamScope`)}constructor(e,t,n){this.elements=e,this.outerScope=t,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.find(e=>e.name.toLowerCase()===t):this.elements.find(t=>t.name===e);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.filter(e=>e.name.toLowerCase()===t):this.elements.filter(t=>t.name===e);return(this.concatOuterScope||n.isEmpty())&&this.outerScope?n.concat(this.outerScope.getElements(e)):n}},gM=class{static{o(this,`MapScope`)}constructor(e,t,n){this.elements=new Map,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.set(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t),r=n?[n]:[];return(this.concatOuterScope||r.length>0)&&this.outerScope?N(r).concat(this.outerScope.getElements(e)):N(r)}getAllElements(){let e=N(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},_M=class{static{o(this,`MultiMapScope`)}constructor(e,t,n){this.elements=new fM,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.add(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t)[0];if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);return(this.concatOuterScope||n.length===0)&&this.outerScope?N(n).concat(this.outerScope.getElements(e)):N(n)}getAllElements(){let e=N(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},vM={getElement(){},getElements(){return yn},getAllElements(){return yn}},yM=class{static{o(this,`DisposableCache`)}constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(e){this.toDispose.push(e)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach(e=>e.dispose())}throwIfDisposed(){if(this.isDisposed)throw Error(`This cache has already been disposed`)}},bM=class extends yM{static{o(this,`SimpleCache`)}constructor(){super(...arguments),this.cache=new Map}has(e){return this.throwIfDisposed(),this.cache.has(e)}set(e,t){this.throwIfDisposed(),this.cache.set(e,t)}get(e,t){if(this.throwIfDisposed(),this.cache.has(e))return this.cache.get(e);if(t){let n=t();return this.cache.set(e,n),n}}delete(e){return this.throwIfDisposed(),this.cache.delete(e)}clear(){this.throwIfDisposed(),this.cache.clear()}},xM=class extends yM{static{o(this,`ContextCache`)}constructor(e){super(),this.cache=new Map,this.converter=e??(e=>e)}has(e,t){return this.throwIfDisposed(),this.cacheForContext(e).has(t)}set(e,t,n){this.throwIfDisposed(),this.cacheForContext(e).set(t,n)}get(e,t,n){this.throwIfDisposed();let r=this.cacheForContext(e);if(r.has(t))return r.get(t);if(n){let e=n();return r.set(t,e),e}}delete(e,t){return this.throwIfDisposed(),this.cacheForContext(e).delete(t)}clear(e){if(this.throwIfDisposed(),e){let t=this.converter(e);this.cache.delete(t)}else this.cache.clear()}cacheForContext(e){let t=this.converter(e),n=this.cache.get(t);return n||(n=new Map,this.cache.set(t,n)),n}},SM=class extends xM{static{o(this,`DocumentCache`)}constructor(e,t){super(e=>e.toString()),t?(this.toDispose.push(e.workspace.DocumentBuilder.onDocumentPhase(t,e=>{this.clear(e.uri.toString())})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{for(let e of t)this.clear(e)}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{let n=e.concat(t);for(let e of n)this.clear(e)}))}},CM=class extends bM{static{o(this,`WorkspaceCache`)}constructor(e,t){super(),t?(this.toDispose.push(e.workspace.DocumentBuilder.onBuildPhase(t,()=>{this.clear()})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{t.length>0&&this.clear()}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate(()=>{this.clear()}))}},wM=class{static{o(this,`DefaultScopeProvider`)}constructor(e){this.reflection=e.shared.AstReflection,this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider,this.indexManager=e.shared.workspace.IndexManager,this.globalScopeCache=new CM(e.shared)}getScope(e){let t=[],n=this.reflection.getReferenceType(e),r=Dn(e.container).localSymbols;if(r){let i=e.container;do r.has(i)&&t.push(r.getStream(i).filter(e=>this.reflection.isSubtype(e.type,n))),i=i.$container;while(i)}let i=this.getGlobalScope(n,e);for(let e=t.length-1;e>=0;e--)i=this.createScope(t[e],i);return i}createScope(e,t,n){return new hM(N(e),t,n)}createScopeForNodes(e,t,n){return new hM(N(e).map(e=>{let t=this.nameProvider.getName(e);if(t)return this.descriptions.createDescription(e,t)}).nonNullable(),t,n)}getGlobalScope(e,t){return this.globalScopeCache.get(e,()=>new _M(this.indexManager.allElements(e)))}};function TM(e){return typeof e.$comment==`string`}o(TM,`isAstNodeWithComment`);function EM(e){return typeof e==`object`&&!!e&&(`$ref`in e||`$error`in e)}o(EM,`isIntermediateReference`);var DM=class{static{o(this,`DefaultJsonSerializer`)}constructor(e){this.ignoreProperties=new Set([`$container`,`$containerProperty`,`$containerIndex`,`$document`,`$cstNode`]),this.langiumDocuments=e.shared.workspace.LangiumDocuments,this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider,this.commentProvider=e.documentation.CommentProvider}serialize(e,t){let n=t??{},r=t?.replacer,i=o((e,t)=>this.replacer(e,t,n),`defaultReplacer`),a=r?(e,t)=>r(e,t,i):i;try{return this.currentDocument=Dn(e),JSON.stringify(e,a,t?.space)}finally{this.currentDocument=void 0}}deserialize(e,t){let n=t??{},r=JSON.parse(e);return this.linkNode(r,r,n),r}replacer(e,t,{refText:n,sourceText:r,textRegions:i,comments:a,uriConverter:o}){if(!this.ignoreProperties.has(e)){if(cn(t)){let e=t.ref,r=n?t.$refText:void 0;if(e){let t=Dn(e),n=``;this.currentDocument&&this.currentDocument!==t&&(n=o?o(t.uri,e):t.uri.toString());let i=this.astNodeLocator.getAstNodePath(e);return{$ref:`${n}#${i}`,$refText:r}}return{$error:t.error?.message??`Could not resolve reference`,$refText:r}}if(ln(t)){let e=n?t.$refText:void 0,r=[];for(let e of t.items){let t=e.ref,n=Dn(e.ref),i=``;this.currentDocument&&this.currentDocument!==n&&(i=o?o(n.uri,t):n.uri.toString());let a=this.astNodeLocator.getAstNodePath(t);r.push(`${i}#${a}`)}return{$refs:r,$refText:e}}if(M(t)){let n;if(i&&(n=this.addAstNodeRegionWithAssignmentsTo({...t}),(!e||t.$document)&&n?.$textRegion&&(n.$textRegion.documentURI=this.currentDocument?.uri.toString())),r&&!e&&(n??={...t},n.$sourceText=t.$cstNode?.text),a){n??={...t};let e=this.commentProvider.getComment(t);e&&(n.$comment=e.replace(/\r/g,``))}return n??t}return t}}addAstNodeRegionWithAssignmentsTo(e){let t=o(e=>({offset:e.offset,end:e.end,length:e.length,range:e.range}),`createDocumentSegment`);if(e.$cstNode){let n=e.$textRegion=t(e.$cstNode),r=n.assignments={};return Object.keys(e).filter(e=>!e.startsWith(`$`)).forEach(n=>{let i=Ra(e.$cstNode,n).map(t);i.length!==0&&(r[n]=i)}),e}}linkNode(e,t,n,r,i,a){for(let[r,i]of Object.entries(e))if(Array.isArray(i))for(let a=0;a{await this.handleException(()=>e.call(t,n,r,i),`An error occurred during validation`,r,n)}}async handleException(e,t,n,r){try{await e()}catch(e){if(Wj(e))throw e;console.error(`${t}:`,e),e instanceof Error&&e.stack&&console.error(e.stack),n(`error`,`${t}: ${e instanceof Error?e.message:String(e)}`,{node:r})}}addEntry(e,t){if(e===`AstNode`){this.entries.add(`AstNode`,t);return}for(let n of this.reflection.getAllSubTypes(e))this.entries.add(n,t)}getChecks(e,t){let n=N(this.entries.get(e)).concat(this.entries.get(`AstNode`));return t&&(n=n.filter(e=>t.includes(e.category))),n.map(e=>e.check)}registerBeforeDocument(e,t=this){this.entriesBefore.push(this.wrapPreparationException(e,`An error occurred during set-up of the validation`,t))}registerAfterDocument(e,t=this){this.entriesAfter.push(this.wrapPreparationException(e,`An error occurred during tear-down of the validation`,t))}wrapPreparationException(e,t,n){return async(r,i,a,o)=>{await this.handleException(()=>e.call(n,r,i,a,o),t,i,r)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}getAllValidationCategories(e){return this.knownCategories}},MM=Object.freeze({validateNode:!0,validateChildren:!0}),NM=class{static{o(this,`DefaultDocumentValidator`)}constructor(e){this.validationRegistry=e.validation.ValidationRegistry,this.metadata=e.LanguageMetaData,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async validateDocument(e,t={},n=Z.CancellationToken.None){let r=e.parseResult,i=[];if(await Gj(n),(!t.categories||t.categories.includes(`built-in`))&&(this.processLexingErrors(r,i,t),t.stopAfterLexingErrors&&i.some(e=>e.data?.code===LM.LexingError)||(this.processParsingErrors(r,i,t),t.stopAfterParsingErrors&&i.some(e=>e.data?.code===LM.ParsingError))||(this.processLinkingErrors(e,i,t),t.stopAfterLinkingErrors&&i.some(e=>e.data?.code===LM.LinkingError))))return i;try{i.push(...await this.validateAst(r.value,t,n))}catch(e){if(Wj(e))throw e;console.error(`An error occurred during validation:`,e)}return await Gj(n),i}processLexingErrors(e,t,n){let r=[...e.lexerErrors,...e.lexerReport?.diagnostics??[]];for(let e of r){let n=e.severity??`error`,r={severity:FM(n),range:{start:{line:e.line-1,character:e.column-1},end:{line:e.line-1,character:e.column+e.length-1}},message:e.message,data:IM(n),source:this.getSource()};t.push(r)}}processParsingErrors(e,t,n){for(let n of e.parserErrors){let e;if(isNaN(n.token.startOffset)){if(`previousToken`in n){let t=n.previousToken;if(isNaN(t.startOffset)){let t={line:0,character:0};e={start:t,end:t}}else{let n={line:t.endLine-1,character:t.endColumn};e={start:n,end:n}}}}else e=zi(n.token);if(e){let r={severity:FM(`error`),range:e,message:n.message,data:kM(LM.ParsingError),source:this.getSource()};t.push(r)}}}processLinkingErrors(e,t,n){for(let n of e.references){let e=n.error;if(e){let r={node:e.info.container,range:n.$refNode?.range,property:e.info.property,index:e.info.index,data:{code:LM.LinkingError,containerType:e.info.container.$type,property:e.info.property,refText:e.info.reference.$refText}};t.push(this.toDiagnostic(`error`,e.message,r))}}}async validateAst(e,t,n=Z.CancellationToken.None){let r=[],i=o((e,t,n)=>{r.push(this.toDiagnostic(e,t,n))},`acceptor`);return await this.validateAstBefore(e,t,i,n),await this.validateAstNodes(e,t,i,n),await this.validateAstAfter(e,t,i,n),r}async validateAstBefore(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksBefore;for(let a of i)await Gj(r),await a(e,n,t.categories??[],r)}async validateAstNodes(e,t,n,r=Z.CancellationToken.None){if(this.profiler?.isActive(`validating`)){let i=this.profiler.createTask(`validating`,this.languageId);i.start();try{let a=Mn(e).iterator();for(let e of a){i.startSubTask(e.$type);let o=this.validateSingleNodeOptions(e,t);if(o.validateNode)try{let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}finally{i.stopSubTask(e.$type)}o.validateChildren||a.prune()}}finally{i.stop()}}else{let i=Mn(e).iterator();for(let e of i){await Gj(r);let a=this.validateSingleNodeOptions(e,t);if(a.validateNode){let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}a.validateChildren||i.prune()}}}validateSingleNodeOptions(e,t){return MM}async validateAstAfter(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksAfter;for(let a of i)await Gj(r),await a(e,n,t.categories??[],r)}toDiagnostic(e,t,n){return{message:t,range:PM(n),severity:FM(e),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}};function PM(e){if(e.range)return e.range;let t;return typeof e.property==`string`?t=za(e.node.$cstNode,e.property,e.index):typeof e.keyword==`string`&&(t=Ha(e.node.$cstNode,e.keyword,e.index)),t??=e.node.$cstNode,t?t.range:{start:{line:0,character:0},end:{line:0,character:0}}}o(PM,`getDiagnosticRange`);function FM(e){switch(e){case`error`:return 1;case`warning`:return 2;case`info`:return 3;case`hint`:return 4;default:throw Error(`Invalid diagnostic severity: `+e)}}o(FM,`toDiagnosticSeverity`);function IM(e){switch(e){case`error`:return kM(LM.LexingError);case`warning`:return kM(LM.LexingWarning);case`info`:return kM(LM.LexingInfo);case`hint`:return kM(LM.LexingHint);default:throw Error(`Invalid diagnostic severity: `+e)}}o(IM,`toDiagnosticData`);var LM;(function(e){e.LexingError=`lexing-error`,e.LexingWarning=`lexing-warning`,e.LexingInfo=`lexing-info`,e.LexingHint=`lexing-hint`,e.ParsingError=`parsing-error`,e.LinkingError=`linking-error`})(LM||={});var RM=class{static{o(this,`DefaultAstNodeDescriptionProvider`)}constructor(e){this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider}createDescription(e,t,n){let r=n??Dn(e);t??=this.nameProvider.getName(e);let i=this.astNodeLocator.getAstNodePath(e);if(!t)throw Error(`Node at path ${i} has no name.`);let a,s=o(()=>a??=Bi(this.nameProvider.getNameNode(e)??e.$cstNode),`nameSegmentGetter`);return{node:e,name:t,get nameSegment(){return s()},selectionSegment:Bi(e.$cstNode),type:e.$type,documentUri:r.uri,path:i}}},zM=class{static{o(this,`DefaultReferenceDescriptionProvider`)}constructor(e){this.nodeLocator=e.workspace.AstNodeLocator}async createDescriptions(e,t=Z.CancellationToken.None){let n=[],r=e.parseResult.value;for(let e of Mn(r))await Gj(t),Pn(e).forEach(e=>{e.reference.error||n.push(...this.createInfoDescriptions(e))});return n}createInfoDescriptions(e){let t=e.reference;if(t.error||!t.$refNode)return[];let n=[];cn(t)&&t.$nodeDescription?n=[t.$nodeDescription]:ln(t)&&(n=t.items.map(e=>e.$nodeDescription).filter(e=>e!==void 0));let r=Dn(e.container).uri,i=this.nodeLocator.getAstNodePath(e.container),a=[],o=Bi(t.$refNode);for(let e of n)a.push({sourceUri:r,sourcePath:i,targetUri:e.documentUri,targetPath:e.path,segment:o,local:rM.equals(e.documentUri,r)});return a}},BM=class{static{o(this,`DefaultAstNodeLocator`)}constructor(){this.segmentSeparator=`/`,this.indexSeparator=`@`}getAstNodePath(e){if(e.$container){let t=this.getAstNodePath(e.$container),n=this.getPathSegment(e);return t+this.segmentSeparator+n}return``}getPathSegment({$containerProperty:e,$containerIndex:t}){if(!e)throw Error(`Missing '$containerProperty' in AST node.`);return t===void 0?e:e+this.indexSeparator+t}getAstNode(e,t){return t.split(this.segmentSeparator).reduce((e,t)=>{if(!e||t.length===0)return e;let n=t.indexOf(this.indexSeparator);if(n>0){let r=t.substring(0,n),i=parseInt(t.substring(n+1));return e[r]?.[i]}return e[t]},e)}},VM={};d(VM,f(vt(),1));var HM=class{static{o(this,`DefaultConfigurationProvider`)}constructor(e){this._ready=new Kj,this.onConfigurationSectionUpdateEmitter=new VM.Emitter,this.settings={},this.workspaceConfig=!1,this.serviceRegistry=e.ServiceRegistry}get ready(){return this._ready.promise}initialize(e){this.workspaceConfig=e.capabilities.workspace?.configuration??!1}async initialized(e){if(this.workspaceConfig){if(e.register){let t=this.serviceRegistry.all;e.register({section:t.map(e=>this.toSectionName(e.LanguageMetaData.languageId))})}if(e.fetchConfiguration){let t=this.serviceRegistry.all.map(e=>({section:this.toSectionName(e.LanguageMetaData.languageId)})),n=await e.fetchConfiguration(t);t.forEach((e,t)=>{this.updateSectionConfiguration(e.section,n[t])})}}this._ready.resolve()}updateConfiguration(e){typeof e.settings==`object`&&e.settings!==null&&Object.entries(e.settings).forEach(([e,t])=>{this.updateSectionConfiguration(e,t),this.onConfigurationSectionUpdateEmitter.fire({section:e,configuration:t})})}updateSectionConfiguration(e,t){this.settings[e]=t}async getConfiguration(e,t){await this.ready;let n=this.toSectionName(e);if(this.settings[n])return this.settings[n][t]}toSectionName(e){return`${e}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}},UM=f(an(),1),WM;(function(e){function t(e){return{dispose:o(async()=>await e(),`dispose`)}}o(t,`create`),e.create=t})(WM||={});var GM=class{static{o(this,`DefaultDocumentBuilder`)}constructor(e){this.updateBuildOptions={validation:{categories:[`built-in`,`fast`]}},this.updateListeners=[],this.buildPhaseListeners=new fM,this.documentPhaseListeners=new fM,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=Q.Changed,this.langiumDocuments=e.workspace.LangiumDocuments,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.textDocuments=e.workspace.TextDocuments,this.indexManager=e.workspace.IndexManager,this.fileSystemProvider=e.workspace.FileSystemProvider,this.workspaceManager=()=>e.workspace.WorkspaceManager,this.serviceRegistry=e.ServiceRegistry}async build(e,t={},n=Z.CancellationToken.None){for(let n of e){let e=n.uri.toString();if(n.state===Q.Validated){if(typeof t.validation==`boolean`&&t.validation)this.resetToState(n,Q.IndexedReferences);else if(typeof t.validation==`object`){let r=this.findMissingValidationCategories(n,t);r.length>0&&(this.buildState.set(e,{completed:!1,options:{validation:{categories:r}},result:this.buildState.get(e)?.result}),n.state=Q.IndexedReferences)}}else this.buildState.delete(e)}this.currentState=Q.Changed,await this.emitUpdate(e.map(e=>e.uri),[]),await this.buildDocuments(e,t,n)}async update(e,t,n=Z.CancellationToken.None){this.currentState=Q.Changed;let r=[];for(let e of t){let t=this.langiumDocuments.deleteDocuments(e);for(let e of t)r.push(e.uri),this.cleanUpDeleted(e)}let i=(await Promise.all(e.map(e=>this.findChangedUris(e)))).flat();for(let e of i){let t=this.langiumDocuments.getDocument(e);t===void 0&&(t=this.langiumDocumentFactory.fromModel({$type:`INVALID`},e),t.state=Q.Changed,this.langiumDocuments.addDocument(t)),this.resetToState(t,Q.Changed)}let a=N(i).concat(r).map(e=>e.toString()).toSet();this.langiumDocuments.all.filter(e=>!a.has(e.uri.toString())&&this.shouldRelink(e,a)).forEach(e=>this.resetToState(e,Q.ComputedScopes)),await this.emitUpdate(i,r),await Gj(n);let o=this.sortDocuments(this.langiumDocuments.all.filter(e=>e.state=1}findMissingValidationCategories(e,t){let n=this.buildState.get(e.uri.toString()),r=this.serviceRegistry.getServices(e.uri).validation.ValidationRegistry.getAllValidationCategories(e),i=n?.result?.validationChecks?new Set(n?.result?.validationChecks):n?.completed?r:new Set;return N(t===void 0||t.validation===!0?r:typeof t.validation==`object`?t.validation.categories??r:[]).filter(e=>!i.has(e)).toArray()}async findChangedUris(e){if(this.langiumDocuments.getDocument(e)??this.textDocuments?.get(e))return[e];try{let t=await this.fileSystemProvider.stat(e);if(t.isDirectory)return await this.workspaceManager().searchFolder(e);if(this.workspaceManager().shouldIncludeEntry(t))return[e]}catch{}return[]}async emitUpdate(e,t){await Promise.all(this.updateListeners.map(n=>n(e,t)))}sortDocuments(e){let t=0,n=e.length-1;for(;t=0&&!this.hasTextDocument(e[n]);)n--;te.error!==void 0)?!0:this.indexManager.isAffected(e,t)}onUpdate(e){return this.updateListeners.push(e),WM.create(()=>{let t=this.updateListeners.indexOf(e);t>=0&&this.updateListeners.splice(t,1)})}resetToState(e,t){switch(t){case Q.Changed:case Q.Parsed:this.indexManager.removeContent(e.uri);case Q.IndexedContent:e.localSymbols=void 0;case Q.ComputedScopes:this.serviceRegistry.getServices(e.uri).references.Linker.unlink(e);case Q.Linked:this.indexManager.removeReferences(e.uri);case Q.IndexedReferences:e.diagnostics=void 0,this.buildState.delete(e.uri.toString());case Q.Validated:}e.state>t&&(e.state=t)}cleanUpDeleted(e){this.buildState.delete(e.uri.toString()),this.indexManager.remove(e.uri),e.state=Q.Changed}async buildDocuments(e,t,n){this.prepareBuild(e,t),await this.runCancelable(e,Q.Parsed,n,e=>this.langiumDocumentFactory.update(e,n)),await this.runCancelable(e,Q.IndexedContent,n,e=>this.indexManager.updateContent(e,n)),await this.runCancelable(e,Q.ComputedScopes,n,async e=>{e.localSymbols=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectLocalSymbols(e,n)});let r=e.filter(e=>this.shouldLink(e));await this.runCancelable(r,Q.Linked,n,e=>this.serviceRegistry.getServices(e.uri).references.Linker.link(e,n)),await this.runCancelable(r,Q.IndexedReferences,n,e=>this.indexManager.updateReferences(e,n));let i=e.filter(e=>this.shouldValidate(e)?!0:(this.markAsCompleted(e),!1));await this.runCancelable(i,Q.Validated,n,async e=>{await this.validate(e,n),this.markAsCompleted(e)})}markAsCompleted(e){let t=this.buildState.get(e.uri.toString());t&&(t.completed=!0)}prepareBuild(e,t){for(let n of e){let e=n.uri.toString(),r=this.buildState.get(e);(!r||r.completed)&&this.buildState.set(e,{completed:!1,options:t,result:r?.result})}}async runCancelable(e,t,n,r){for(let i of e)i.statee.state===t);await this.notifyBuildPhase(i,t,n),this.currentState=t}onBuildPhase(e,t){return this.buildPhaseListeners.add(e,t),WM.create(()=>{this.buildPhaseListeners.delete(e,t)})}onDocumentPhase(e,t){return this.documentPhaseListeners.add(e,t),WM.create(()=>{this.documentPhaseListeners.delete(e,t)})}waitUntil(e,t,n){let r;return t&&`path`in t?r=t:n=t,n??=Z.CancellationToken.None,r?this.awaitDocumentState(e,r,n):this.awaitBuilderState(e,n)}awaitDocumentState(e,t,n){let r=this.langiumDocuments.getDocument(t);return r?r.state>=e?Promise.resolve(t):n.isCancellationRequested?Promise.reject(Uj):this.currentState>=e&&e>r.state?Promise.reject(new UM.ResponseError(UM.LSPErrorCodes.RequestFailed,`Document state of ${t.toString()} is ${Q[r.state]}, requiring ${Q[e]}, but workspace state is already ${Q[this.currentState]}. Returning undefined.`)):new Promise((r,i)=>{let a=this.onDocumentPhase(e,e=>{rM.equals(e.uri,t)&&(a.dispose(),o.dispose(),r(e.uri))}),o=n.onCancellationRequested(()=>{a.dispose(),o.dispose(),i(Uj)})}):Promise.reject(new UM.ResponseError(UM.LSPErrorCodes.ServerCancelled,`No document found for URI: ${t.toString()}`))}awaitBuilderState(e,t){return this.currentState>=e?Promise.resolve():t.isCancellationRequested?Promise.reject(Uj):new Promise((n,r)=>{let i=this.onBuildPhase(e,()=>{i.dispose(),a.dispose(),n()}),a=t.onCancellationRequested(()=>{i.dispose(),a.dispose(),r(Uj)})})}async notifyDocumentPhase(e,t,n){let r=this.documentPhaseListeners.get(t).slice();for(let t of r)try{await Gj(n),await t(e,n)}catch(e){if(!Wj(e))throw e}}async notifyBuildPhase(e,t,n){if(e.length===0)return;let r=this.buildPhaseListeners.get(t).slice();for(let t of r)await Gj(n),await t(e,n)}shouldLink(e){return this.getBuildOptions(e).eagerLinking??!0}shouldValidate(e){return!!this.getBuildOptions(e).validation}async validate(e,t){let n=this.serviceRegistry.getServices(e.uri).validation.DocumentValidator,r=this.getBuildOptions(e),i=typeof r.validation==`object`?{...r.validation}:{};i.categories=this.findMissingValidationCategories(e,r);let a=await n.validateDocument(e,i,t);e.diagnostics?e.diagnostics.push(...a):e.diagnostics=a;let o=this.buildState.get(e.uri.toString());o&&(o.result??={},o.result.validationChecks?o.result.validationChecks=N(o.result.validationChecks).concat(i.categories).distinct().toArray():o.result.validationChecks=[...i.categories])}getBuildOptions(e){return this.buildState.get(e.uri.toString())?.options??{}}},KM=class{static{o(this,`DefaultIndexManager`)}constructor(e){this.symbolIndex=new Map,this.symbolByTypeIndex=new xM,this.referenceIndex=new Map,this.documents=e.workspace.LangiumDocuments,this.serviceRegistry=e.ServiceRegistry,this.astReflection=e.AstReflection}findAllReferences(e,t){let n=Dn(e).uri,r=[];return this.referenceIndex.forEach(e=>{e.forEach(e=>{rM.equals(e.targetUri,n)&&e.targetPath===t&&r.push(e)})}),N(r)}allElements(e,t){let n=N(this.symbolIndex.keys());return t&&(n=n.filter(e=>!t||t.has(e))),n.map(t=>this.getFileDescriptions(t,e)).flat()}getFileDescriptions(e,t){return t?this.symbolByTypeIndex.get(e,t,()=>(this.symbolIndex.get(e)??[]).filter(e=>this.astReflection.isSubtype(e.type,t))):this.symbolIndex.get(e)??[]}remove(e){this.removeContent(e),this.removeReferences(e)}removeContent(e){let t=e.toString();this.symbolIndex.delete(t),this.symbolByTypeIndex.clear(t)}removeReferences(e){let t=e.toString();this.referenceIndex.delete(t)}async updateContent(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectExportedSymbols(e,t),r=e.uri.toString();this.symbolIndex.set(r,n),this.symbolByTypeIndex.clear(r)}async updateReferences(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).workspace.ReferenceDescriptionProvider.createDescriptions(e,t);this.referenceIndex.set(e.uri.toString(),n)}isAffected(e,t){let n=this.referenceIndex.get(e.uri.toString());return n?n.some(e=>!e.local&&t.has(e.targetUri.toString())):!1}},qM=class{static{o(this,`DefaultWorkspaceManager`)}constructor(e){this.initialBuildOptions={},this._ready=new Kj,this.serviceRegistry=e.ServiceRegistry,this.langiumDocuments=e.workspace.LangiumDocuments,this.documentBuilder=e.workspace.DocumentBuilder,this.fileSystemProvider=e.workspace.FileSystemProvider,this.mutex=e.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(e){this.folders=e.workspaceFolders??void 0}initialized(e){return this.mutex.write(e=>this.initializeWorkspace(this.folders??[],e))}async initializeWorkspace(e,t=Z.CancellationToken.None){let n=await this.performStartup(e);await Gj(t),await this.documentBuilder.build(n,this.initialBuildOptions,t)}async performStartup(e){let t=[],n=o(e=>{t.push(e),this.langiumDocuments.hasDocument(e.uri)||this.langiumDocuments.addDocument(e)},`collector`);await this.loadAdditionalDocuments(e,n);let r=[];await Promise.all(e.map(e=>this.getRootFolder(e)).map(async e=>this.traverseFolder(e,r)));let i=N(r).distinct(e=>e.toString()).filter(e=>!this.langiumDocuments.hasDocument(e));return await this.loadWorkspaceDocuments(i,n),this._ready.resolve(),t}async loadWorkspaceDocuments(e,t){await Promise.all(e.map(async e=>{t(await this.langiumDocuments.getOrCreateDocument(e))}))}loadAdditionalDocuments(e,t){return Promise.resolve()}getRootFolder(e){return tM.parse(e.uri)}async traverseFolder(e,t){try{let n=await this.fileSystemProvider.readDirectory(e);await Promise.all(n.map(async e=>{this.shouldIncludeEntry(e)&&(e.isDirectory?await this.traverseFolder(e.uri,t):e.isFile&&t.push(e.uri))}))}catch(t){console.error(`Failure to read directory content of `+e.toString(!0),t)}}async searchFolder(e){let t=[];return await this.traverseFolder(e,t),t}shouldIncludeEntry(e){let t=rM.basename(e.uri);return t.startsWith(`.`)?!1:e.isDirectory?t!==`node_modules`&&t!==`out`:e.isFile?this.serviceRegistry.hasServices(e.uri):!1}},JM=class{static{o(this,`DefaultLexerErrorMessageProvider`)}buildUnexpectedCharactersMessage(e,t,n,r,i){return zy.buildUnexpectedCharactersMessage(e,t,n,r,i)}buildUnableToPopLexerModeMessage(e){return zy.buildUnableToPopLexerModeMessage(e)}},YM={mode:`full`},XM=class{static{o(this,`DefaultLexer`)}constructor(e){this.errorMessageProvider=e.parser.LexerErrorMessageProvider,this.tokenBuilder=e.parser.TokenBuilder;let t=this.tokenBuilder.buildTokens(e.Grammar,{caseInsensitive:e.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(t);let n=$M(t)?Object.values(t):t,r=e.LanguageMetaData.mode===`production`;this.chevrotainLexer=new Vy(n,{positionTracking:`full`,skipValidations:r,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(e,t=YM){let n=this.chevrotainLexer.tokenize(e);return{tokens:n.tokens,errors:n.errors,hidden:n.groups.hidden??[],report:this.tokenBuilder.flushLexingReport?.(e)}}toTokenTypeDictionary(e){if($M(e))return e;let t=QM(e)?Object.values(e.modes).flat():e,n={};return t.forEach(e=>n[e.name]=e),n}};function ZM(e){return Array.isArray(e)&&(e.length===0||`name`in e[0])}o(ZM,`isTokenTypeArray`);function QM(e){return e&&`modes`in e&&`defaultMode`in e}o(QM,`isIMultiModeLexerDefinition`);function $M(e){return!ZM(e)&&!QM(e)}o($M,`isTokenTypeDictionary`),ht();function eN(e,t,n){let r,i;typeof e==`string`?(i=t,r=n):(i=e.range.start,r=t),i||=y.create(0,0);let a=nN(e),o=vN(r);return dN({index:0,tokens:aN({lines:a,position:i,options:o}),position:i})}o(eN,`parseJSDoc`);function tN(e,t){let n=vN(t),r=nN(e);if(r.length===0)return!1;let i=r[0],a=r[r.length-1],o=n.start,s=n.end;return!!o?.exec(i)&&!!s?.exec(a)}o(tN,`isJSDoc`);function nN(e){let t=``;return t=typeof e==`string`?e:e.text,t.split(xa)}o(nN,`getLines`);var rN=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,iN=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function aN(e){let t=[],n=e.position.line,r=e.position.character;for(let i=0;i=s.length){if(t.length>0){let e=y.create(n,r);t.push({type:`break`,content:``,range:b.create(e,e)})}}else{rN.lastIndex=c;let e=rN.exec(s);if(e){let i=e[0],a=e[1],o=y.create(n,r+c),l=y.create(n,r+c+i.length);t.push({type:`tag`,content:a,range:b.create(o,l)}),c+=i.length,c=lN(s,c)}if(c0&&t[t.length-1].type===`break`?t.slice(0,-1):t}o(aN,`tokenize`);function oN(e,t,n,r){let i=[];if(e.length===0){let e=y.create(n,r),a=y.create(n,r+t.length);i.push({type:`text`,content:t,range:b.create(e,a)})}else{let a=0;for(let o of e){let e=o.index,s=t.substring(a,e);s.length>0&&i.push({type:`text`,content:t.substring(a,e),range:b.create(y.create(n,a+r),y.create(n,e+r))});let c=s.length+1,l=o[1];if(i.push({type:`inline-tag`,content:l,range:b.create(y.create(n,a+c+r),y.create(n,a+c+l.length+r))}),c+=l.length,o.length===4){c+=o[2].length;let e=o[3];i.push({type:`text`,content:e,range:b.create(y.create(n,a+c+r),y.create(n,a+c+e.length+r))})}else i.push({type:`text`,content:``,range:b.create(y.create(n,a+c+r),y.create(n,a+c+r))});a=e+o[0].length}let o=t.substring(a);o.length>0&&i.push({type:`text`,content:o,range:b.create(y.create(n,a+r),y.create(n,a+r+o.length))})}return i}o(oN,`buildInlineTokens`);var sN=/\S/,cN=/\s*$/;function lN(e,t){let n=e.substring(t).match(sN);return n?t+n.index:e.length}o(lN,`skipWhitespace`);function uN(e){let t=e.match(cN);if(t&&typeof t.index==`number`)return t.index}o(uN,`lastCharacter`);function dN(e){let t=y.create(e.position.line,e.position.character);if(e.tokens.length===0)return new bN([],b.create(t,t));let n=[];for(;e.indext.name===e)}getTags(e){return this.getAllTags().filter(t=>t.name===e)}getAllTags(){return this.elements.filter(e=>`name`in e)}toString(){let e=``;for(let t of this.elements)if(e.length===0)e=t.toString();else{let n=t.toString();e+=EN(e)+n}return e.trim()}toMarkdown(e){let t=``;for(let n of this.elements)if(t.length===0)t=n.toMarkdown(e);else{let r=n.toMarkdown(e);t+=EN(t)+r}return t.trim()}},xN=class{static{o(this,`JSDocTagImpl`)}constructor(e,t,n,r){this.name=e,this.content=t,this.inline=n,this.range=r}toString(){let e=`@${this.name}`,t=this.content.toString();return this.content.inlines.length===1?e=`${e} ${t}`:this.content.inlines.length>1&&(e=`${e} +${t}`),this.inline?`{${e}}`:e}toMarkdown(e){return e?.renderTag?.(this)??this.toMarkdownDefault(e)}toMarkdownDefault(e){let t=this.content.toMarkdown(e);if(this.inline){let n=SN(this.name,t,e??{});if(typeof n==`string`)return n}let n=``;e?.tag===`italic`||e?.tag===void 0?n=`*`:e?.tag===`bold`?n=`**`:e?.tag===`bold-italic`&&(n=`***`);let r=`${n}@${this.name}${n}`;return this.content.inlines.length===1?r=`${r} \u2014 ${t}`:this.content.inlines.length>1&&(r=`${r} +${t}`),this.inline?`{${r}}`:r}};function SN(e,t,n){if(e===`linkplain`||e===`linkcode`||e===`link`){let r=t.indexOf(` `),i=t;if(r>0){let e=lN(t,r);i=t.substring(e),t=t.substring(0,r)}return(e===`linkcode`||e===`link`&&n.link===`code`)&&(i=`\`${i}\``),n.renderLink?.(t,i)??CN(t,i)}}o(SN,`renderInlineTag`);function CN(e,t){try{return tM.parse(e,!0),`[${t}](${e})`}catch{return e}}o(CN,`renderLinkDefault`);var wN=class{static{o(this,`JSDocTextImpl`)}constructor(e,t){this.inlines=e,this.range=t}toString(){let e=``;for(let t=0;tn.range.start.line&&(e+=` +`)}return e}toMarkdown(e){let t=``;for(let n=0;nr.range.start.line&&(t+=` +`)}return t}},TN=class{static{o(this,`JSDocLineImpl`)}constructor(e,t){this.text=e,this.range=t}toString(){return this.text}toMarkdown(){return this.text}};function EN(e){return e.endsWith(` +`)?` +`:` + +`}o(EN,`fillNewlines`);var DN=class{static{o(this,`JSDocDocumentationProvider`)}constructor(e){this.indexManager=e.shared.workspace.IndexManager,this.commentProvider=e.documentation.CommentProvider}getDocumentation(e){let t=this.commentProvider.getComment(e);if(t&&tN(t))return eN(t).toMarkdown({renderLink:o((t,n)=>this.documentationLinkRenderer(e,t,n),`renderLink`),renderTag:o(t=>this.documentationTagRenderer(e,t),`renderTag`)})}documentationLinkRenderer(e,t,n){let r=this.findNameInLocalSymbols(e,t)??this.findNameInGlobalScope(e,t);if(r&&r.nameSegment){let e=r.nameSegment.range.start.line+1,t=r.nameSegment.range.start.character+1;return`[${n}](${r.documentUri.with({fragment:`L${e},${t}`}).toString()})`}}documentationTagRenderer(e,t){}findNameInLocalSymbols(e,t){let n=Dn(e).localSymbols;if(!n)return;let r=e;do{let e=n.getStream(r).find(e=>e.name===t);if(e)return e;r=r.$container}while(r)}findNameInGlobalScope(e,t){return this.indexManager.allElements().find(e=>e.name===t)}},ON=class{static{o(this,`DefaultCommentProvider`)}constructor(e){this.grammarConfig=()=>e.parser.GrammarConfig}getComment(e){return TM(e)?e.$comment:Ki(e.$cstNode,this.grammarConfig().multilineCommentRules)?.text}},kN=class{static{o(this,`DefaultAsyncParser`)}constructor(e){this.syncParser=e.parser.LangiumParser}parse(e,t){return Promise.resolve(this.syncParser.parse(e))}},AN=class{static{o(this,`AbstractThreadedAsyncParser`)}constructor(e){this.threadCount=8,this.terminationDelay=200,this.workerPool=[],this.queue=[],this.hydrator=e.serializer.Hydrator}initializeWorkers(){for(;this.workerPool.length{if(this.queue.length>0){let t=this.queue.shift();t&&(e.lock(),t.resolve(e))}}),this.workerPool.push(e)}}async parse(e,t){let n=await this.acquireParserWorker(t),r=new Kj,i,a=t.onCancellationRequested(()=>{i=setTimeout(()=>{this.terminateWorker(n)},this.terminationDelay)});return n.parse(e).then(e=>{let t=this.hydrator.hydrate(e);r.resolve(t)}).catch(e=>{r.reject(e)}).finally(()=>{a.dispose(),clearTimeout(i)}),r.promise}terminateWorker(e){e.terminate();let t=this.workerPool.indexOf(e);t>=0&&this.workerPool.splice(t,1)}async acquireParserWorker(e){this.initializeWorkers();for(let e of this.workerPool)if(e.ready)return e.lock(),e;let t=new Kj;return e.onCancellationRequested(()=>{let e=this.queue.indexOf(t);e>=0&&this.queue.splice(e,1),t.reject(Uj)}),this.queue.push(t),t.promise}},jN=class{static{o(this,`ParserWorker`)}get ready(){return this._ready}get onReady(){return this.onReadyEmitter.event}constructor(e,t,n,r){this.onReadyEmitter=new VM.Emitter,this.deferred=new Kj,this._ready=!0,this._parsing=!1,this.sendMessage=e,this._terminate=r,t(e=>{let t=e;this.deferred.resolve(t),this.unlock()}),n(e=>{this.deferred.reject(e),this.unlock()})}terminate(){this.deferred.reject(Uj),this._terminate()}lock(){this._ready=!1}unlock(){this._parsing=!1,this._ready=!0,this.onReadyEmitter.fire()}parse(e){if(this._parsing)throw Error(`Parser worker is busy`);return this._parsing=!0,this.deferred=new Kj,this.sendMessage(e),this.deferred.promise}},MN=class{static{o(this,`DefaultWorkspaceLock`)}constructor(){this.previousTokenSource=new Z.CancellationTokenSource,this.writeQueue=[],this.readQueue=[],this.done=!0}write(e){this.cancelWrite();let t=Vj();return this.previousTokenSource=t,this.enqueue(this.writeQueue,e,t.token)}read(e){return this.enqueue(this.readQueue,e)}enqueue(e,t,n=Z.CancellationToken.None){let r=new Kj,i={action:t,deferred:r,cancellationToken:n};return e.push(i),this.performNextOperation(),r.promise}async performNextOperation(){if(!this.done)return;let e=[];if(this.writeQueue.length>0)e.push(this.writeQueue.shift());else if(this.readQueue.length>0)e.push(...this.readQueue.splice(0,this.readQueue.length));else return;this.done=!1,await Promise.all(e.map(async({action:e,deferred:t,cancellationToken:n})=>{try{let r=await Promise.resolve().then(()=>e(n));t.resolve(r)}catch(e){Wj(e)?t.resolve(void 0):t.reject(e)}})),this.done=!0,this.performNextOperation()}cancelWrite(){this.previousTokenSource.cancel()}},NN=class{static{o(this,`DefaultHydrator`)}constructor(e){this.grammarElementIdMap=new pM,this.tokenTypeIdMap=new pM,this.grammar=e.Grammar,this.lexer=e.parser.Lexer,this.linker=e.references.Linker}dehydrate(e){return{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport?this.dehydrateLexerReport(e.lexerReport):void 0,parserErrors:e.parserErrors.map(e=>({...e,message:e.message})),value:this.dehydrateAstNode(e.value,this.createDehyrationContext(e.value))}}dehydrateLexerReport(e){return e}createDehyrationContext(e){let t=new Map,n=new Map;for(let n of Mn(e))t.set(n,{});if(e.$cstNode)for(let t of Ii(e.$cstNode))n.set(t,{});return{astNodes:t,cstNodes:n}}dehydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode!==void 0&&(n.$cstNode=this.dehydrateCstNode(e.$cstNode,t));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`)){if(Array.isArray(i)){let e=[];n[r]=e;for(let n of i)M(n)?e.push(this.dehydrateAstNode(n,t)):cn(n)?e.push(this.dehydrateReference(n,t)):e.push(n)}else M(i)?n[r]=this.dehydrateAstNode(i,t):cn(i)?n[r]=this.dehydrateReference(i,t):i!==void 0&&(n[r]=i)}return n}dehydrateReference(e,t){let n={};return n.$refText=e.$refText,e.$refNode&&(n.$refNode=t.cstNodes.get(e.$refNode)),n}dehydrateCstNode(e,t){let n=t.cstNodes.get(e);return hn(e)?n.fullText=e.fullText:n.grammarSource=this.getGrammarElementId(e.grammarSource),n.hidden=e.hidden,n.astNode=t.astNodes.get(e.astNode),pn(e)?n.content=e.content.map(e=>this.dehydrateCstNode(e,t)):mn(e)&&(n.tokenType=e.tokenType.name,n.offset=e.offset,n.length=e.length,n.startLine=e.range.start.line,n.startColumn=e.range.start.character,n.endLine=e.range.end.line,n.endColumn=e.range.end.character),n}hydrate(e){let t=e.value,n=this.createHydrationContext(t);return`$cstNode`in t&&this.hydrateCstNode(t.$cstNode,n),{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport,parserErrors:e.parserErrors,value:this.hydrateAstNode(t,n)}}createHydrationContext(e){let t=new Map,n=new Map;for(let n of Mn(e))t.set(n,{});let r;if(e.$cstNode)for(let t of Ii(e.$cstNode)){let e;`fullText`in t?(e=new tj(t.fullText),r=e):`content`in t?e=new $A:`tokenType`in t&&(e=this.hydrateCstLeafNode(t)),e&&(n.set(t,e),e.root=r)}return{astNodes:t,cstNodes:n}}hydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode&&(n.$cstNode=t.cstNodes.get(e.$cstNode));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`)){if(Array.isArray(i)){let e=[];n[r]=e;for(let a of i)M(a)?e.push(this.setParent(this.hydrateAstNode(a,t),n)):cn(a)?e.push(this.hydrateReference(a,n,r,t)):e.push(a)}else M(i)?n[r]=this.setParent(this.hydrateAstNode(i,t),n):cn(i)?n[r]=this.hydrateReference(i,n,r,t):i!==void 0&&(n[r]=i)}return n}setParent(e,t){return e.$container=t,e}hydrateReference(e,t,n,r){return this.linker.buildReference(t,n,r.cstNodes.get(e.$refNode),e.$refText)}hydrateCstNode(e,t,n=0){let r=t.cstNodes.get(e);if(typeof e.grammarSource==`number`&&(r.grammarSource=this.getGrammarElement(e.grammarSource)),r.astNode=t.astNodes.get(e.astNode),pn(r))for(let i of e.content){let e=this.hydrateCstNode(i,t,n++);r.content.push(e)}return r}hydrateCstLeafNode(e){let t=this.getTokenType(e.tokenType),n=e.offset,r=e.length,i=e.startLine,a=e.startColumn,o=e.endLine,s=e.endColumn,c=e.hidden;return new QA(n,r,{start:{line:i,character:a},end:{line:o,character:s}},t,c)}getTokenType(e){return this.lexer.definition[e]}getGrammarElementId(e){if(e)return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.get(e)}getGrammarElement(e){return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.getKey(e)}createGrammarElementIdMap(){let e=0;for(let t of Mn(this.grammar))Vn(t)&&this.grammarElementIdMap.set(t,e++)}};function PN(e){return{documentation:{CommentProvider:o(e=>new ON(e),`CommentProvider`),DocumentationProvider:o(e=>new DN(e),`DocumentationProvider`)},parser:{AsyncParser:o(e=>new kN(e),`AsyncParser`),GrammarConfig:o(e=>_o(e),`GrammarConfig`),LangiumParser:o(e=>Nj(e),`LangiumParser`),CompletionParser:o(e=>Mj(e),`CompletionParser`),ValueConverter:o(()=>new Ij,`ValueConverter`),TokenBuilder:o(()=>new Fj,`TokenBuilder`),Lexer:o(e=>new XM(e),`Lexer`),ParserErrorMessageProvider:o(()=>new lj,`ParserErrorMessageProvider`),LexerErrorMessageProvider:o(()=>new JM,`LexerErrorMessageProvider`)},workspace:{AstNodeLocator:o(()=>new BM,`AstNodeLocator`),AstNodeDescriptionProvider:o(e=>new RM(e),`AstNodeDescriptionProvider`),ReferenceDescriptionProvider:o(e=>new zM(e),`ReferenceDescriptionProvider`)},references:{Linker:o(e=>new cM(e),`Linker`),NameProvider:o(()=>new uM,`NameProvider`),ScopeProvider:o(e=>new wM(e),`ScopeProvider`),ScopeComputation:o(e=>new mM(e),`ScopeComputation`),References:o(e=>new dM(e),`References`)},serializer:{Hydrator:o(e=>new NN(e),`Hydrator`),JsonSerializer:o(e=>new DM(e),`JsonSerializer`)},validation:{DocumentValidator:o(e=>new NM(e),`DocumentValidator`),ValidationRegistry:o(e=>new jM(e),`ValidationRegistry`)},shared:o(()=>e.shared,`shared`)}}o(PN,`createDefaultCoreModule`);function FN(e){return{ServiceRegistry:o(e=>new OM(e),`ServiceRegistry`),workspace:{LangiumDocuments:o(e=>new oM(e),`LangiumDocuments`),LangiumDocumentFactory:o(e=>new aM(e),`LangiumDocumentFactory`),DocumentBuilder:o(e=>new GM(e),`DocumentBuilder`),IndexManager:o(e=>new KM(e),`IndexManager`),WorkspaceManager:o(e=>new qM(e),`WorkspaceManager`),FileSystemProvider:o(t=>e.fileSystemProvider(t),`FileSystemProvider`),WorkspaceLock:o(()=>new MN,`WorkspaceLock`),ConfigurationProvider:o(e=>new HM(e),`ConfigurationProvider`)},profilers:{}}}o(FN,`createDefaultSharedCoreModule`);var IN;(function(e){e.merge=(e,t)=>UN(UN({},e),t)})(IN||={});function LN(e,t,n,r,i,a,o,s,c){return BN([e,t,n,r,i,a,o,s,c].reduce(UN,{}))}o(LN,`inject`);var RN=Symbol(`isProxy`);function zN(e){if(e&&e[RN])for(let t of Object.values(e))zN(t);return e}o(zN,`eagerLoad`);function BN(e,t){let n=new Proxy({},{deleteProperty:o(()=>!1,`deleteProperty`),set:o(()=>{throw Error(`Cannot set property on injected service container`)},`set`),get:o((r,i)=>i===RN||HN(r,i,e,t||n),`get`),getOwnPropertyDescriptor:o((r,i)=>(HN(r,i,e,t||n),Object.getOwnPropertyDescriptor(r,i)),`getOwnPropertyDescriptor`),has:o((t,n)=>n in e,`has`),ownKeys:o(()=>[...Object.getOwnPropertyNames(e)],`ownKeys`)});return n}o(BN,`_inject`);var VN=Symbol();function HN(e,t,n,r){if(t in e){if(e[t]instanceof Error)throw Error(`Construction failure. Please make sure that your dependencies are constructable. Cause: `+e[t]);if(e[t]===VN)throw Error(`Cycle detected. Please make "`+String(t)+`" lazy. Visit https://langium.org/docs/reference/configuration-services/#resolving-cyclic-dependencies`);return e[t]}if(t in n){let i=n[t];e[t]=VN;try{e[t]=typeof i==`function`?i(r):BN(i,r)}catch(n){throw e[t]=n instanceof Error?n:void 0,n}return e[t]}}o(HN,`_resolve`);function UN(e,t){if(t){for(let[n,r]of Object.entries(t))if(r!=null){if(typeof r==`object`){let t=e[n];e[n]=UN(typeof t==`object`&&t?t:{},r)}else e[n]=r}}return e}o(UN,`_merge`);var WN={indentTokenName:`INDENT`,dedentTokenName:`DEDENT`,whitespaceTokenName:`WS`,ignoreIndentationDelimiters:[]},GN;(function(e){e.REGULAR=`indentation-sensitive`,e.IGNORE_INDENTATION=`ignore-indentation`})(GN||={});var KN=class extends Fj{static{o(this,`IndentationAwareTokenBuilder`)}constructor(e=WN){super(),this.indentationStack=[0],this.whitespaceRegExp=/[ \t]+/y,this.options={...WN,...e},this.indentTokenType=$y({name:this.options.indentTokenName,pattern:this.indentMatcher.bind(this),line_breaks:!1}),this.dedentTokenType=$y({name:this.options.dedentTokenName,pattern:this.dedentMatcher.bind(this),line_breaks:!1})}buildTokens(e,t){let n=super.buildTokens(e,t);if(!ZM(n))throw Error(`Invalid tokens built by default builder`);let{indentTokenName:r,dedentTokenName:i,whitespaceTokenName:a,ignoreIndentationDelimiters:o}=this.options,s,c,l,u=[];for(let e of n){for(let[t,n]of o)e.name===t?e.PUSH_MODE=GN.IGNORE_INDENTATION:e.name===n&&(e.POP_MODE=!0);e.name===i?s=e:e.name===r?c=e:e.name===a?l=e:u.push(e)}if(!s||!c||!l)throw Error(`Some indentation/whitespace tokens not found!`);return o.length>0?{modes:{[GN.REGULAR]:[s,c,...u,l],[GN.IGNORE_INDENTATION]:[...u,l]},defaultMode:GN.REGULAR}:[s,c,l,...u]}flushLexingReport(e){return{...super.flushLexingReport(e),remainingDedents:this.flushRemainingDedents(e)}}isStartOfLine(e,t){return t===0||`\r +`.includes(e[t-1])}matchWhitespace(e,t,n,r){this.whitespaceRegExp.lastIndex=t;let i=this.whitespaceRegExp.exec(e);return{currIndentLevel:i?.[0].length??0,prevIndentLevel:this.indentationStack.at(-1),match:i}}createIndentationTokenInstance(e,t,n,r){let i=this.getLineNumber(t,r);return nb(e,n,r,r+n.length,i,i,1,n.length)}getLineNumber(e,t){return e.substring(0,t).split(/\r\n|\r|\n/).length}indentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);return i<=a?null:(this.indentationStack.push(i),o)}dedentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);if(i>=a)return null;let s=this.indentationStack.lastIndexOf(i);if(s===-1)return this.diagnostics.push({severity:`error`,message:`Invalid dedent level ${i} at offset: ${t}. Current indentation stack: ${this.indentationStack}`,offset:t,length:o?.[0]?.length??0,line:this.getLineNumber(e,t),column:1}),null;let c=this.indentationStack.length-s-1,l=e.substring(0,t).match(/[\r\n]+$/)?.[0].length??1;for(let r=0;r1;)t.push(this.createIndentationTokenInstance(this.dedentTokenType,e,``,e.length)),this.indentationStack.pop();return this.indentationStack=[0],t}},qN=class extends XM{static{o(this,`IndentationAwareLexer`)}constructor(e){if(super(e),e.parser.TokenBuilder instanceof KN)this.indentationTokenBuilder=e.parser.TokenBuilder;else throw Error(`IndentationAwareLexer requires an accompanying IndentationAwareTokenBuilder`)}tokenize(e,t=YM){let n=super.tokenize(e),r=n.report;t?.mode===`full`&&n.tokens.push(...r.remainingDedents),r.remainingDedents=[];let{indentTokenType:i,dedentTokenType:a}=this.indentationTokenBuilder,o=i.tokenTypeIdx,s=a.tokenTypeIdx,c=[],l=n.tokens.length-1;for(let e=0;e=0&&c.push(n.tokens[l]),n.tokens=c,n}},JN={};l(JN,{AstUtils:()=>Cn,BiMap:()=>pM,Cancellation:()=>Z,ContextCache:()=>xM,CstUtils:()=>sn,DONE_RESULT:()=>bn,Deferred:()=>Kj,Disposable:()=>WM,DisposableCache:()=>yM,DocumentCache:()=>SM,EMPTY_STREAM:()=>yn,ErrorWithLocation:()=>ia,GrammarUtils:()=>ra,MultiMap:()=>fM,OperationCancelled:()=>Uj,Reduction:()=>Sn,RegExpUtils:()=>sa,SimpleCache:()=>bM,StreamImpl:()=>gn,TreeStreamImpl:()=>xn,URI:()=>tM,UriTrie:()=>iM,UriUtils:()=>rM,WorkspaceCache:()=>CM,assertCondition:()=>oa,assertUnreachable:()=>aa,delayNextTick:()=>Rj,interruptAndCheck:()=>Gj,isOperationCancelled:()=>Wj,loadGrammarFromJson:()=>eP,setInterruptionPeriod:()=>Hj,startCancelableOperation:()=>Vj,stream:()=>N}),d(JN,VM);var YN=class{static{o(this,`EmptyFileSystemProvider`)}stat(e){throw Error(`No file system is available.`)}statSync(e){throw Error(`No file system is available.`)}async exists(){return!1}existsSync(){return!1}readBinary(){throw Error(`No file system is available.`)}readBinarySync(){throw Error(`No file system is available.`)}readFile(){throw Error(`No file system is available.`)}readFileSync(){throw Error(`No file system is available.`)}async readDirectory(){return[]}readDirectorySync(){return[]}},XN={fileSystemProvider:o(()=>new YN,`fileSystemProvider`)},ZN={Grammar:o(()=>void 0,`Grammar`),LanguageMetaData:o(()=>({caseInsensitive:!1,fileExtensions:[`.langium`],languageId:`langium`}),`LanguageMetaData`)},QN={AstReflection:o(()=>new Pi,`AstReflection`)};function $N(){let e=LN(FN(XN),QN),t=LN(PN({shared:e}),ZN);return e.ServiceRegistry.register(t),t}o($N,`createMinimalGrammarServices`);function eP(e){let t=$N(),n=t.serializer.JsonSerializer.deserialize(e);return t.shared.workspace.LangiumDocumentFactory.fromModel(n,tM.parse(`memory:/${n.name??`grammar`}.langium`)),n}o(eP,`loadGrammarFromJson`),d(on,JN);var tP=class{static{o(this,`DefaultLangiumProfiler`)}constructor(e){this.activeCategories=new Set,this.allCategories=new Set([`validating`,`parsing`,`linking`]),this.activeCategories=e??new Set(this.allCategories),this.records=new fM}isActive(e){return this.activeCategories.has(e)}start(...e){e?e.forEach(e=>this.activeCategories.add(e)):this.activeCategories=new Set(this.allCategories)}stop(...e){e?e.forEach(e=>this.activeCategories.delete(e)):this.activeCategories.clear()}createTask(e,t){if(!this.isActive(e))throw Error(`Category "${e}" is not active.`);return console.log(`Creating profiling task for '${e}.${t}'.`),new nP(t=>this.records.add(e,this.dumpRecord(e,t)),t)}dumpRecord(e,t){console.info(`Task ${e}.${t.identifier} executed in ${t.duration.toFixed(2)}ms and ended at ${t.date.toISOString()}`);let n=[];for(let e of t.entries.keys()){let r=t.entries.get(e),i=r.reduce((e,t)=>e+t);n.push({name:`${t.identifier}.${e}`,count:r.length,duration:i})}let r=t.duration-n.map(e=>e.duration).reduce((e,t)=>e+t,0);n.push({name:t.identifier,count:1,duration:r}),n.sort((e,t)=>t.duration-e.duration);function i(e){return Math.round(100*e)/100}return o(i,`Round`),console.table(n.map(e=>({Element:e.name,Count:e.count,"Self %":i(100*e.duration/t.duration),"Time (ms)":i(e.duration)}))),t}getRecords(...e){return e.length===0?this.records.values():this.records.entries().filter(t=>e.some(e=>e===t[0])).flatMap(e=>e[1])}},nP=class{static{o(this,`ProfilingTask`)}constructor(e,t){this.stack=[],this.entries=new fM,this.addRecord=e,this.identifier=t}start(){if(this.startTime!==void 0)throw Error(`Task "${this.identifier}" is already started.`);this.startTime=performance.now()}stop(){if(this.startTime===void 0)throw Error(`Task "${this.identifier}" was not started.`);if(this.stack.length!==0)throw Error(`Task "${this.identifier}" cannot be stopped before sub-task(s): ${this.stack.map(e=>e.id).join(`, `)}.`);let e={identifier:this.identifier,date:new Date,duration:performance.now()-this.startTime,entries:this.entries};this.addRecord(e),this.startTime=void 0,this.entries.clear()}startSubTask(e){this.stack.push({id:e,start:performance.now(),content:0})}stopSubTask(e){let t=this.stack.pop();if(!t)throw Error(`Task "${this.identifier}.${e}" was not started.`);if(t.id!==e)throw Error(`Sub-Task "${t.id}" is not already stopped.`);let n=performance.now()-t.start;this.stack.at(-1)!==void 0&&(this.stack[this.stack.length-1].content+=n);let r=n-t.content;this.entries.add(e,r)}},rP;(e=>{e.Terminals={ARROW_DIRECTION:/L|R|T|B/,ARROW_GROUP:/\{group\}/,ARROW_INTO:/<|>/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,ARCH_ICON:/\([\w-:]+\)/,ARCH_TITLE:/\[(?:"([^"\\]|\\.)*"|'([^'\\]|\\.)*'|[^\[\]\r\n]+)\]/}})(rP||={});var iP;(e=>{e.Terminals={DOMAIN_NAME:/complex|complicated|clear|chaotic|confusion/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(iP||={});var aP;(e=>{e.Terminals={EM_ID:/[_a-zA-Z][\w_]*/,EM_FID:/\d{1,3}/,EM_DATA_INLINE:/\{(.*)\}|"(.*)"|'(.*)'/,EM_DATA_BLOCK:/\{[\t ]*\r?\n(?:[\S\s]*?\r?\n)?\}(?:\r?\n|(?!\S))/,EM_ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,EM_ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,EM_TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,EM_WS:/\s+/,EM_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,EM_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,EM_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,EM_ML_COMMENT:/\/\*[\s\S]*?\*\//,EM_SL_COMMENT:/\/\/[^\n\r]*/}})(aP||={});var oP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,REFERENCE:/\w([-\./\w]*[-\w])?/}})(oP||={});var sP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(sP||={});var cP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(cP||={});var lP;(e=>{e.Terminals={NUMBER_PIE:/(?:-?[0-9]+\.[0-9]+(?!\.))|(?:-?(0|[1-9][0-9]*)(?!\.))/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(lP||={});var uP;(e=>{e.Terminals={GRATICULE:/circle|polygon/,BOOLEAN:/true|false/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NUMBER:/(?:[0-9]+\.[0-9]+(?!\.))|(?:0|[1-9][0-9]*(?!\.))/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(uP||={});var dP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ABNF_RULENAME:/[A-Za-z][A-Za-z0-9-]*/,ABNF_STRING:/"[^"]*"/,ABNF_NUMVAL:/%[xXdDbB][0-9A-Fa-f]+(?:-[0-9A-Fa-f]+|\.[0-9A-Fa-f]+)*/,ABNF_REPEAT:/[0-9]*\*[0-9]*/,ABNF_EXACT_REPEAT:/[0-9]+/,ABNF_WHITESPACE:/[\t \r\n]+/,ABNF_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,ABNF_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,ABNF_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,ABNF_COMMENT:/;[^\n\r]*/}})(dP||={});var fP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,EBNF_ID:/[A-Z_a-z][\w-]*/,EBNF_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,EBNF_SPECIAL_SEQUENCE:/\?(?=[^?;]*[^?\s;][^?;]*\?)[^?;]*\?/,EBNF_WHITESPACE:/[\t \r\n]+/,EBNF_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,EBNF_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,EBNF_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,EBNF_BLOCK_COMMENT:/\/\*[\s\S]*?\*\//,EBNF_ISO_COMMENT:/\(\*[\s\S]*?\*\)/}})(fP||={});var pP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,RR_ID:/[A-Z_a-z][\w-]*/,RR_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,RR_WHITESPACE:/[\t \r\n]+/,RR_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,RR_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,RR_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,RR_BLOCK_COMMENT:/\/\*[\s\S]*?\*\//}})(pP||={});var mP;(e=>{e.Terminals={TITLE:/title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,ACC_TITLE:/accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,PEG_ID:/[A-Z_a-z][\w-]*/,PEG_STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,PEG_WHITESPACE:/[\t \r\n]+/,PEG_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,PEG_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,PEG_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,PEG_LINE_COMMENT:/#[^\n\r]*/}})(mP||={});var hP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,TREEMAP_KEYWORD:/treemap-beta|treemap/,CLASS_DEF:/classDef\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\s+([^;\r\n]*))?(?:;)?/,STYLE_SEPARATOR:/:::/,SEPARATOR:/:/,COMMA:/,/,INDENTATION:/[ \t]{1,}/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,ID2:/[a-zA-Z_][a-zA-Z0-9_]*/,NUMBER2:/[0-9_\.\,]+/,STRING2:/"[^"]*"|'[^']*'/}})(hP||={});var gP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,CLASS_ANNOTATION:/[ \t]+:::[ \t]*[A-Za-z_][\w-]*/,ICON_ANNOTATION:/[ \t]+icon\([\w-]*(?::[\w-]+)?\)/,DESC_ANNOTATION:/[ \t]+##[^\n\r]*/,INDENTATION:/[ \t]{1,}/,QUOTED_NAME:/"[^"]*"|'[^']*'/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,BARE_NAME:/(?!:::|icon\(|##)[^ \t\n\r"'](?:(?![ \t]+:::[ \t]*[A-Za-z_]|[ \t]+icon\(|[ \t]+##)[^\n\r])*/}})(gP||={});var _P;(e=>{e.Terminals={WARDLEY_NUMBER:/[0-9]+\.[0-9]+/,ARROW:/->/,LINK_PORT:/\+<>|\+>|\+|-\.->|>|\+'[^']*'<>|\+'[^']*'<|\+'[^']*'>/,LINK_LABEL:/;[^\n\r]+/,STRATEGY:/build|buy|outsource|market/,KW_WARDLEY:/wardley-beta/,KW_SIZE:/size/,KW_EVOLUTION:/evolution/,KW_ANCHOR:/anchor/,KW_COMPONENT:/component/,KW_LABEL:/label/,KW_INERTIA:/inertia/,KW_EVOLVE:/evolve/,KW_PIPELINE:/pipeline/,KW_NOTE:/note/,KW_ANNOTATIONS:/annotations/,KW_ANNOTATION:/annotation/,KW_ACCELERATOR:/accelerator/,KW_DEACCELERATOR:/deaccelerator/,NAME_WITH_SPACES:/(?!title\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/,WS:/[ \t]+/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(_P||={}),{...rP.Terminals,...iP.Terminals,...aP.Terminals,...oP.Terminals,...sP.Terminals,...cP.Terminals,...lP.Terminals,...uP.Terminals,...dP.Terminals,...fP.Terminals,...pP.Terminals,...mP.Terminals,...gP.Terminals,...hP.Terminals,..._P.Terminals};var vP={$type:`AbnfAlternation`,alternatives:`alternatives`},yP={$type:`AbnfConcatenation`,elements:`elements`},bP={$type:`AbnfElement`,primary:`primary`,repeat:`repeat`},xP={$type:`AbnfGroup`,element:`element`},SP={$type:`AbnfNumVal`,value:`value`},CP={$type:`AbnfOptionalGroup`,element:`element`},wP={$type:`AbnfPrimary`},TP={$type:`AbnfRule`,definition:`definition`,name:`name`},EP={$type:`AbnfRuleName`,name:`name`},DP={$type:`AbnfStringLiteral`,value:`value`},OP={$type:`Accelerator`,name:`name`,x:`x`,y:`y`},kP={$type:`Alignment`,direction:`direction`,members:`members`},AP={$type:`Anchor`,evolution:`evolution`,name:`name`,visibility:`visibility`},jP={$type:`Annotation`,number:`number`,text:`text`,x:`x`,y:`y`},MP={$type:`Annotations`,x:`x`,y:`y`},NP={$type:`Architecture`,accDescr:`accDescr`,accTitle:`accTitle`,alignments:`alignments`,edges:`edges`,groups:`groups`,junctions:`junctions`,services:`services`,title:`title`};function PP(e){return $.isInstance(e,NP.$type)}o(PP,`isArchitecture`);var FP={$type:`Axis`,label:`label`,name:`name`},IP={$type:`Branch`,name:`name`,order:`order`};function LP(e){return $.isInstance(e,IP.$type)}o(LP,`isBranch`);var RP={$type:`Checkout`,branch:`branch`},zP={$type:`CherryPicking`,id:`id`,parent:`parent`,tags:`tags`},BP={$type:`ClassDefStatement`,className:`className`,styleText:`styleText`},VP={$type:`Commit`,id:`id`,message:`message`,tags:`tags`,type:`type`};function HP(e){return $.isInstance(e,VP.$type)}o(HP,`isCommit`);var UP={$type:`Common`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`},WP={$type:`Component`,decorator:`decorator`,evolution:`evolution`,inertia:`inertia`,label:`label`,name:`name`,visibility:`visibility`},GP={$type:`Curve`,entries:`entries`,label:`label`,name:`name`},KP={$type:`Cynefin`,accDescr:`accDescr`,accTitle:`accTitle`,domains:`domains`,title:`title`,transitions:`transitions`};function qP(e){return $.isInstance(e,KP.$type)}o(qP,`isCynefin`);var JP={$type:`Deaccelerator`,name:`name`,x:`x`,y:`y`},YP={$type:`Decorator`,strategy:`strategy`},XP={$type:`Direction`,accDescr:`accDescr`,accTitle:`accTitle`,dir:`dir`,statements:`statements`,title:`title`},ZP={$type:`DomainBlock`,domain:`domain`,items:`items`};function QP(e){return $.isInstance(e,ZP.$type)}o(QP,`isDomainBlock`);var $P={$type:`DomainItem`,label:`label`};function eF(e){return $.isInstance(e,$P.$type)}o(eF,`isDomainItem`);var tF={$type:`EbnfChoice`,alternatives:`alternatives`},nF={$type:`EbnfExceptionPostfix`,except:`except`},rF={$type:`EbnfGroup`,element:`element`},iF={$type:`EbnfNonTerminal`,name:`name`},aF={$type:`EbnfOneOrMorePostfix`,operator:`operator`},oF={$type:`EbnfOptional`,element:`element`},sF={$type:`EbnfOptionalPostfix`,operator:`operator`},cF={$type:`EbnfPostfix`},lF={$type:`EbnfPrimary`},uF={$type:`EbnfRepetition`,element:`element`},dF={$type:`EbnfRule`,definition:`definition`,name:`name`},fF={$type:`EbnfSequence`,elements:`elements`},pF={$type:`EbnfSpecial`,text:`text`},mF={$type:`EbnfTerm`,base:`base`,postfixes:`postfixes`},hF={$type:`EbnfTerminal`,value:`value`},gF={$type:`EbnfZeroOrMorePostfix`,operator:`operator`},_F={$type:`Edge`,lhsDir:`lhsDir`,lhsGroup:`lhsGroup`,lhsId:`lhsId`,lhsInto:`lhsInto`,rhsDir:`rhsDir`,rhsGroup:`rhsGroup`,rhsId:`rhsId`,rhsInto:`rhsInto`,title:`title`},vF={$type:`EmDataEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,name:`name`},yF={$type:`EmFrame`},bF={$type:`EmGwt`,givenStatements:`givenStatements`,sourceFrame:`sourceFrame`,thenStatements:`thenStatements`,whenStatements:`whenStatements`},xF={$type:`EmGwtStatement`,entityIdentifier:`entityIdentifier`},SF={$type:`EmModelEntity`,name:`name`};function CF(e){return e===`rmo`||e===`readmodel`||e===`ui`||e===`cmd`||e===`command`||e===`evt`||e===`event`||e===`pcr`||e===`processor`}o(CF,`isEmModelEntityType`);var wF={$type:`EmNoteEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,sourceFrame:`sourceFrame`},TF={$type:`EmResetFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`};function EF(e){return $.isInstance(e,TF.$type)}o(EF,`isEmResetFrame`);var DF={$type:`EmTimeFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`},OF={$type:`Entry`,axis:`axis`,value:`value`},kF={$type:`EventModel`,accDescr:`accDescr`,accTitle:`accTitle`,dataEntities:`dataEntities`,frames:`frames`,gwtEntities:`gwtEntities`,modelEntities:`modelEntities`,noteEntities:`noteEntities`,title:`title`},AF={$type:`Evolution`,stages:`stages`},jF={$type:`EvolutionStage`,boundary:`boundary`,name:`name`,secondName:`secondName`},MF={$type:`Evolve`,component:`component`,target:`target`},NF={$type:`GitGraph`,accDescr:`accDescr`,accTitle:`accTitle`,statements:`statements`,title:`title`};function PF(e){return $.isInstance(e,NF.$type)}o(PF,`isGitGraph`);var FF={$type:`Group`,icon:`icon`,id:`id`,in:`in`,title:`title`},IF={$type:`Info`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`};function LF(e){return $.isInstance(e,IF.$type)}o(LF,`isInfo`);var RF={$type:`Item`,classSelector:`classSelector`,name:`name`},zF={$type:`Junction`,id:`id`,in:`in`},BF={$type:`Label`,negX:`negX`,negY:`negY`,offsetX:`offsetX`,offsetY:`offsetY`},VF={$type:`Leaf`,classSelector:`classSelector`,name:`name`,value:`value`},HF={$type:`Link`,arrow:`arrow`,from:`from`,fromPort:`fromPort`,linkLabel:`linkLabel`,to:`to`,toPort:`toPort`},UF={$type:`Merge`,branch:`branch`,id:`id`,tags:`tags`,type:`type`};function WF(e){return $.isInstance(e,UF.$type)}o(WF,`isMerge`);var GF={$type:`Note`,evolution:`evolution`,text:`text`,visibility:`visibility`},KF={$type:`Option`,name:`name`,value:`value`},qF={$type:`Packet`,accDescr:`accDescr`,accTitle:`accTitle`,blocks:`blocks`,title:`title`};function JF(e){return $.isInstance(e,qF.$type)}o(JF,`isPacket`);var YF={$type:`PacketBlock`,bits:`bits`,end:`end`,label:`label`,start:`start`};function XF(e){return $.isInstance(e,YF.$type)}o(XF,`isPacketBlock`);var ZF={$type:`PegAny`,dot:`dot`},QF={$type:`PegGroup`,element:`element`},$F={$type:`PegIdentifier`,name:`name`},eI={$type:`PegLiteral`,value:`value`},tI={$type:`PegOrderedChoice`,alternatives:`alternatives`},nI={$type:`PegPrefix`,operator:`operator`,suffix:`suffix`},rI={$type:`PegPrimary`},iI={$type:`PegRule`,definition:`definition`,name:`name`},aI={$type:`PegSequence`,elements:`elements`},oI={$type:`PegSuffix`,operator:`operator`,primary:`primary`},sI={$type:`Pie`,accDescr:`accDescr`,accTitle:`accTitle`,sections:`sections`,showData:`showData`,title:`title`};function cI(e){return $.isInstance(e,sI.$type)}o(cI,`isPie`);var lI={$type:`PieSection`,label:`label`,value:`value`};function uI(e){return $.isInstance(e,lI.$type)}o(uI,`isPieSection`);var dI={$type:`Pipeline`,components:`components`,parent:`parent`},fI={$type:`PipelineComponent`,evolution:`evolution`,label:`label`,name:`name`},pI={$type:`Radar`,accDescr:`accDescr`,accTitle:`accTitle`,axes:`axes`,curves:`curves`,options:`options`,title:`title`},mI={$type:`Railroad`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function hI(e){return $.isInstance(e,mI.$type)}o(hI,`isRailroad`);var gI={$type:`RailroadAbnf`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function _I(e){return $.isInstance(e,gI.$type)}o(_I,`isRailroadAbnf`);var vI={$type:`RailroadChoiceExpr`,alternatives:`alternatives`},yI={$type:`RailroadEbnf`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function bI(e){return $.isInstance(e,yI.$type)}o(bI,`isRailroadEbnf`);var xI={$type:`RailroadExpression`},SI={$type:`RailroadNonTerminalExpr`,name:`name`},CI={$type:`RailroadOneOrMoreExpr`,element:`element`},wI={$type:`RailroadOptionalExpr`,element:`element`},TI={$type:`RailroadPeg`,accDescr:`accDescr`,accTitle:`accTitle`,rules:`rules`,title:`title`};function EI(e){return $.isInstance(e,TI.$type)}o(EI,`isRailroadPeg`);var DI={$type:`RailroadRule`,definition:`definition`,name:`name`},OI={$type:`RailroadSequenceExpr`,elements:`elements`},kI={$type:`RailroadSpecialExpr`,text:`text`},AI={$type:`RailroadTerminalExpr`,value:`value`},jI={$type:`RailroadZeroOrMoreExpr`,element:`element`},MI={$type:`Section`,classSelector:`classSelector`,name:`name`},NI={$type:`Service`,icon:`icon`,iconText:`iconText`,id:`id`,in:`in`,title:`title`},PI={$type:`Size`,height:`height`,width:`width`},FI={$type:`Statement`},II={$type:`Transition`,from:`from`,label:`label`,to:`to`};function LI(e){return $.isInstance(e,II.$type)}o(LI,`isTransition`);var RI={$type:`Treemap`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`,TreemapRows:`TreemapRows`};function zI(e){return $.isInstance(e,RI.$type)}o(zI,`isTreemap`);var BI={$type:`TreemapRow`,indent:`indent`,item:`item`},VI={$type:`TreeNode`,classAnnotation:`classAnnotation`,descAnnotation:`descAnnotation`,iconAnnotation:`iconAnnotation`,indent:`indent`,name:`name`},HI={$type:`TreeView`,accDescr:`accDescr`,accTitle:`accTitle`,nodes:`nodes`,title:`title`},UI={$type:`Wardley`,accDescr:`accDescr`,accelerators:`accelerators`,accTitle:`accTitle`,anchors:`anchors`,annotation:`annotation`,annotations:`annotations`,components:`components`,deaccelerators:`deaccelerators`,evolution:`evolution`,evolves:`evolves`,links:`links`,notes:`notes`,pipelines:`pipelines`,size:`size`,title:`title`};function WI(e){return $.isInstance(e,UI.$type)}o(WI,`isWardley`);var GI=class extends fn{constructor(){super(...arguments),this.types={AbnfAlternation:{name:vP.$type,properties:{alternatives:{name:vP.alternatives,defaultValue:[]}},superTypes:[]},AbnfConcatenation:{name:yP.$type,properties:{elements:{name:yP.elements,defaultValue:[]}},superTypes:[]},AbnfElement:{name:bP.$type,properties:{primary:{name:bP.primary},repeat:{name:bP.repeat}},superTypes:[]},AbnfGroup:{name:xP.$type,properties:{element:{name:xP.element}},superTypes:[wP.$type]},AbnfNumVal:{name:SP.$type,properties:{value:{name:SP.value}},superTypes:[wP.$type]},AbnfOptionalGroup:{name:CP.$type,properties:{element:{name:CP.element}},superTypes:[wP.$type]},AbnfPrimary:{name:wP.$type,properties:{},superTypes:[]},AbnfRule:{name:TP.$type,properties:{definition:{name:TP.definition},name:{name:TP.name}},superTypes:[]},AbnfRuleName:{name:EP.$type,properties:{name:{name:EP.name}},superTypes:[wP.$type]},AbnfStringLiteral:{name:DP.$type,properties:{value:{name:DP.value}},superTypes:[wP.$type]},Accelerator:{name:OP.$type,properties:{name:{name:OP.name},x:{name:OP.x},y:{name:OP.y}},superTypes:[]},Alignment:{name:kP.$type,properties:{direction:{name:kP.direction},members:{name:kP.members,defaultValue:[]}},superTypes:[]},Anchor:{name:AP.$type,properties:{evolution:{name:AP.evolution},name:{name:AP.name},visibility:{name:AP.visibility}},superTypes:[]},Annotation:{name:jP.$type,properties:{number:{name:jP.number},text:{name:jP.text},x:{name:jP.x},y:{name:jP.y}},superTypes:[]},Annotations:{name:MP.$type,properties:{x:{name:MP.x},y:{name:MP.y}},superTypes:[]},Architecture:{name:NP.$type,properties:{accDescr:{name:NP.accDescr},accTitle:{name:NP.accTitle},alignments:{name:NP.alignments,defaultValue:[]},edges:{name:NP.edges,defaultValue:[]},groups:{name:NP.groups,defaultValue:[]},junctions:{name:NP.junctions,defaultValue:[]},services:{name:NP.services,defaultValue:[]},title:{name:NP.title}},superTypes:[]},Axis:{name:FP.$type,properties:{label:{name:FP.label},name:{name:FP.name}},superTypes:[]},Branch:{name:IP.$type,properties:{name:{name:IP.name},order:{name:IP.order}},superTypes:[FI.$type]},Checkout:{name:RP.$type,properties:{branch:{name:RP.branch}},superTypes:[FI.$type]},CherryPicking:{name:zP.$type,properties:{id:{name:zP.id},parent:{name:zP.parent},tags:{name:zP.tags,defaultValue:[]}},superTypes:[FI.$type]},ClassDefStatement:{name:BP.$type,properties:{className:{name:BP.className},styleText:{name:BP.styleText}},superTypes:[]},Commit:{name:VP.$type,properties:{id:{name:VP.id},message:{name:VP.message},tags:{name:VP.tags,defaultValue:[]},type:{name:VP.type}},superTypes:[FI.$type]},Common:{name:UP.$type,properties:{accDescr:{name:UP.accDescr},accTitle:{name:UP.accTitle},title:{name:UP.title}},superTypes:[]},Component:{name:WP.$type,properties:{decorator:{name:WP.decorator},evolution:{name:WP.evolution},inertia:{name:WP.inertia,defaultValue:!1},label:{name:WP.label},name:{name:WP.name},visibility:{name:WP.visibility}},superTypes:[]},Curve:{name:GP.$type,properties:{entries:{name:GP.entries,defaultValue:[]},label:{name:GP.label},name:{name:GP.name}},superTypes:[]},Cynefin:{name:KP.$type,properties:{accDescr:{name:KP.accDescr},accTitle:{name:KP.accTitle},domains:{name:KP.domains,defaultValue:[]},title:{name:KP.title},transitions:{name:KP.transitions,defaultValue:[]}},superTypes:[]},Deaccelerator:{name:JP.$type,properties:{name:{name:JP.name},x:{name:JP.x},y:{name:JP.y}},superTypes:[]},Decorator:{name:YP.$type,properties:{strategy:{name:YP.strategy}},superTypes:[]},Direction:{name:XP.$type,properties:{accDescr:{name:XP.accDescr},accTitle:{name:XP.accTitle},dir:{name:XP.dir},statements:{name:XP.statements,defaultValue:[]},title:{name:XP.title}},superTypes:[NF.$type]},DomainBlock:{name:ZP.$type,properties:{domain:{name:ZP.domain},items:{name:ZP.items,defaultValue:[]}},superTypes:[]},DomainItem:{name:$P.$type,properties:{label:{name:$P.label}},superTypes:[]},EbnfChoice:{name:tF.$type,properties:{alternatives:{name:tF.alternatives,defaultValue:[]}},superTypes:[]},EbnfExceptionPostfix:{name:nF.$type,properties:{except:{name:nF.except}},superTypes:[cF.$type]},EbnfGroup:{name:rF.$type,properties:{element:{name:rF.element}},superTypes:[lF.$type]},EbnfNonTerminal:{name:iF.$type,properties:{name:{name:iF.name}},superTypes:[lF.$type]},EbnfOneOrMorePostfix:{name:aF.$type,properties:{operator:{name:aF.operator}},superTypes:[cF.$type]},EbnfOptional:{name:oF.$type,properties:{element:{name:oF.element}},superTypes:[lF.$type]},EbnfOptionalPostfix:{name:sF.$type,properties:{operator:{name:sF.operator}},superTypes:[cF.$type]},EbnfPostfix:{name:cF.$type,properties:{},superTypes:[]},EbnfPrimary:{name:lF.$type,properties:{},superTypes:[]},EbnfRepetition:{name:uF.$type,properties:{element:{name:uF.element}},superTypes:[lF.$type]},EbnfRule:{name:dF.$type,properties:{definition:{name:dF.definition},name:{name:dF.name}},superTypes:[]},EbnfSequence:{name:fF.$type,properties:{elements:{name:fF.elements,defaultValue:[]}},superTypes:[]},EbnfSpecial:{name:pF.$type,properties:{text:{name:pF.text}},superTypes:[lF.$type]},EbnfTerm:{name:mF.$type,properties:{base:{name:mF.base},postfixes:{name:mF.postfixes,defaultValue:[]}},superTypes:[]},EbnfTerminal:{name:hF.$type,properties:{value:{name:hF.value}},superTypes:[lF.$type]},EbnfZeroOrMorePostfix:{name:gF.$type,properties:{operator:{name:gF.operator}},superTypes:[cF.$type]},Edge:{name:_F.$type,properties:{lhsDir:{name:_F.lhsDir},lhsGroup:{name:_F.lhsGroup,defaultValue:!1},lhsId:{name:_F.lhsId},lhsInto:{name:_F.lhsInto,defaultValue:!1},rhsDir:{name:_F.rhsDir},rhsGroup:{name:_F.rhsGroup,defaultValue:!1},rhsId:{name:_F.rhsId},rhsInto:{name:_F.rhsInto,defaultValue:!1},title:{name:_F.title}},superTypes:[]},EmDataEntity:{name:vF.$type,properties:{dataBlockValue:{name:vF.dataBlockValue},dataType:{name:vF.dataType},name:{name:vF.name}},superTypes:[]},EmFrame:{name:yF.$type,properties:{},superTypes:[]},EmGwt:{name:bF.$type,properties:{givenStatements:{name:bF.givenStatements,defaultValue:[]},sourceFrame:{name:bF.sourceFrame,referenceType:yF.$type},thenStatements:{name:bF.thenStatements,defaultValue:[]},whenStatements:{name:bF.whenStatements,defaultValue:[]}},superTypes:[]},EmGwtStatement:{name:xF.$type,properties:{entityIdentifier:{name:xF.entityIdentifier,referenceType:SF.$type}},superTypes:[]},EmModelEntity:{name:SF.$type,properties:{name:{name:SF.name}},superTypes:[]},EmNoteEntity:{name:wF.$type,properties:{dataBlockValue:{name:wF.dataBlockValue},dataType:{name:wF.dataType},sourceFrame:{name:wF.sourceFrame,referenceType:yF.$type}},superTypes:[]},EmResetFrame:{name:TF.$type,properties:{dataInlineValue:{name:TF.dataInlineValue},dataReference:{name:TF.dataReference,referenceType:vF.$type},dataType:{name:TF.dataType},entityIdentifier:{name:TF.entityIdentifier},modelEntityType:{name:TF.modelEntityType},name:{name:TF.name},sourceFrames:{name:TF.sourceFrames,defaultValue:[],referenceType:yF.$type}},superTypes:[yF.$type]},EmTimeFrame:{name:DF.$type,properties:{dataInlineValue:{name:DF.dataInlineValue},dataReference:{name:DF.dataReference,referenceType:vF.$type},dataType:{name:DF.dataType},entityIdentifier:{name:DF.entityIdentifier},modelEntityType:{name:DF.modelEntityType},name:{name:DF.name},sourceFrames:{name:DF.sourceFrames,defaultValue:[],referenceType:yF.$type}},superTypes:[yF.$type]},Entry:{name:OF.$type,properties:{axis:{name:OF.axis,referenceType:FP.$type},value:{name:OF.value}},superTypes:[]},EventModel:{name:kF.$type,properties:{accDescr:{name:kF.accDescr},accTitle:{name:kF.accTitle},dataEntities:{name:kF.dataEntities,defaultValue:[]},frames:{name:kF.frames,defaultValue:[]},gwtEntities:{name:kF.gwtEntities,defaultValue:[]},modelEntities:{name:kF.modelEntities,defaultValue:[]},noteEntities:{name:kF.noteEntities,defaultValue:[]},title:{name:kF.title}},superTypes:[]},Evolution:{name:AF.$type,properties:{stages:{name:AF.stages,defaultValue:[]}},superTypes:[]},EvolutionStage:{name:jF.$type,properties:{boundary:{name:jF.boundary},name:{name:jF.name},secondName:{name:jF.secondName}},superTypes:[]},Evolve:{name:MF.$type,properties:{component:{name:MF.component},target:{name:MF.target}},superTypes:[]},GitGraph:{name:NF.$type,properties:{accDescr:{name:NF.accDescr},accTitle:{name:NF.accTitle},statements:{name:NF.statements,defaultValue:[]},title:{name:NF.title}},superTypes:[]},Group:{name:FF.$type,properties:{icon:{name:FF.icon},id:{name:FF.id},in:{name:FF.in},title:{name:FF.title}},superTypes:[]},Info:{name:IF.$type,properties:{accDescr:{name:IF.accDescr},accTitle:{name:IF.accTitle},title:{name:IF.title}},superTypes:[]},Item:{name:RF.$type,properties:{classSelector:{name:RF.classSelector},name:{name:RF.name}},superTypes:[]},Junction:{name:zF.$type,properties:{id:{name:zF.id},in:{name:zF.in}},superTypes:[]},Label:{name:BF.$type,properties:{negX:{name:BF.negX,defaultValue:!1},negY:{name:BF.negY,defaultValue:!1},offsetX:{name:BF.offsetX},offsetY:{name:BF.offsetY}},superTypes:[]},Leaf:{name:VF.$type,properties:{classSelector:{name:VF.classSelector},name:{name:VF.name},value:{name:VF.value}},superTypes:[RF.$type]},Link:{name:HF.$type,properties:{arrow:{name:HF.arrow},from:{name:HF.from},fromPort:{name:HF.fromPort},linkLabel:{name:HF.linkLabel},to:{name:HF.to},toPort:{name:HF.toPort}},superTypes:[]},Merge:{name:UF.$type,properties:{branch:{name:UF.branch},id:{name:UF.id},tags:{name:UF.tags,defaultValue:[]},type:{name:UF.type}},superTypes:[FI.$type]},Note:{name:GF.$type,properties:{evolution:{name:GF.evolution},text:{name:GF.text},visibility:{name:GF.visibility}},superTypes:[]},Option:{name:KF.$type,properties:{name:{name:KF.name},value:{name:KF.value,defaultValue:!1}},superTypes:[]},Packet:{name:qF.$type,properties:{accDescr:{name:qF.accDescr},accTitle:{name:qF.accTitle},blocks:{name:qF.blocks,defaultValue:[]},title:{name:qF.title}},superTypes:[]},PacketBlock:{name:YF.$type,properties:{bits:{name:YF.bits},end:{name:YF.end},label:{name:YF.label},start:{name:YF.start}},superTypes:[]},PegAny:{name:ZF.$type,properties:{dot:{name:ZF.dot}},superTypes:[rI.$type]},PegGroup:{name:QF.$type,properties:{element:{name:QF.element}},superTypes:[rI.$type]},PegIdentifier:{name:$F.$type,properties:{name:{name:$F.name}},superTypes:[rI.$type]},PegLiteral:{name:eI.$type,properties:{value:{name:eI.value}},superTypes:[rI.$type]},PegOrderedChoice:{name:tI.$type,properties:{alternatives:{name:tI.alternatives,defaultValue:[]}},superTypes:[]},PegPrefix:{name:nI.$type,properties:{operator:{name:nI.operator},suffix:{name:nI.suffix}},superTypes:[]},PegPrimary:{name:rI.$type,properties:{},superTypes:[]},PegRule:{name:iI.$type,properties:{definition:{name:iI.definition},name:{name:iI.name}},superTypes:[]},PegSequence:{name:aI.$type,properties:{elements:{name:aI.elements,defaultValue:[]}},superTypes:[]},PegSuffix:{name:oI.$type,properties:{operator:{name:oI.operator},primary:{name:oI.primary}},superTypes:[]},Pie:{name:sI.$type,properties:{accDescr:{name:sI.accDescr},accTitle:{name:sI.accTitle},sections:{name:sI.sections,defaultValue:[]},showData:{name:sI.showData,defaultValue:!1},title:{name:sI.title}},superTypes:[]},PieSection:{name:lI.$type,properties:{label:{name:lI.label},value:{name:lI.value}},superTypes:[]},Pipeline:{name:dI.$type,properties:{components:{name:dI.components,defaultValue:[]},parent:{name:dI.parent}},superTypes:[]},PipelineComponent:{name:fI.$type,properties:{evolution:{name:fI.evolution},label:{name:fI.label},name:{name:fI.name}},superTypes:[]},Radar:{name:pI.$type,properties:{accDescr:{name:pI.accDescr},accTitle:{name:pI.accTitle},axes:{name:pI.axes,defaultValue:[]},curves:{name:pI.curves,defaultValue:[]},options:{name:pI.options,defaultValue:[]},title:{name:pI.title}},superTypes:[]},Railroad:{name:mI.$type,properties:{accDescr:{name:mI.accDescr},accTitle:{name:mI.accTitle},rules:{name:mI.rules,defaultValue:[]},title:{name:mI.title}},superTypes:[]},RailroadAbnf:{name:gI.$type,properties:{accDescr:{name:gI.accDescr},accTitle:{name:gI.accTitle},rules:{name:gI.rules,defaultValue:[]},title:{name:gI.title}},superTypes:[]},RailroadChoiceExpr:{name:vI.$type,properties:{alternatives:{name:vI.alternatives,defaultValue:[]}},superTypes:[xI.$type]},RailroadEbnf:{name:yI.$type,properties:{accDescr:{name:yI.accDescr},accTitle:{name:yI.accTitle},rules:{name:yI.rules,defaultValue:[]},title:{name:yI.title}},superTypes:[]},RailroadExpression:{name:xI.$type,properties:{},superTypes:[]},RailroadNonTerminalExpr:{name:SI.$type,properties:{name:{name:SI.name}},superTypes:[xI.$type]},RailroadOneOrMoreExpr:{name:CI.$type,properties:{element:{name:CI.element}},superTypes:[xI.$type]},RailroadOptionalExpr:{name:wI.$type,properties:{element:{name:wI.element}},superTypes:[xI.$type]},RailroadPeg:{name:TI.$type,properties:{accDescr:{name:TI.accDescr},accTitle:{name:TI.accTitle},rules:{name:TI.rules,defaultValue:[]},title:{name:TI.title}},superTypes:[]},RailroadRule:{name:DI.$type,properties:{definition:{name:DI.definition},name:{name:DI.name}},superTypes:[]},RailroadSequenceExpr:{name:OI.$type,properties:{elements:{name:OI.elements,defaultValue:[]}},superTypes:[xI.$type]},RailroadSpecialExpr:{name:kI.$type,properties:{text:{name:kI.text}},superTypes:[xI.$type]},RailroadTerminalExpr:{name:AI.$type,properties:{value:{name:AI.value}},superTypes:[xI.$type]},RailroadZeroOrMoreExpr:{name:jI.$type,properties:{element:{name:jI.element}},superTypes:[xI.$type]},Section:{name:MI.$type,properties:{classSelector:{name:MI.classSelector},name:{name:MI.name}},superTypes:[RF.$type]},Service:{name:NI.$type,properties:{icon:{name:NI.icon},iconText:{name:NI.iconText},id:{name:NI.id},in:{name:NI.in},title:{name:NI.title}},superTypes:[]},Size:{name:PI.$type,properties:{height:{name:PI.height},width:{name:PI.width}},superTypes:[]},Statement:{name:FI.$type,properties:{},superTypes:[]},Transition:{name:II.$type,properties:{from:{name:II.from},label:{name:II.label},to:{name:II.to}},superTypes:[]},TreeNode:{name:VI.$type,properties:{classAnnotation:{name:VI.classAnnotation},descAnnotation:{name:VI.descAnnotation},iconAnnotation:{name:VI.iconAnnotation},indent:{name:VI.indent},name:{name:VI.name}},superTypes:[]},TreeView:{name:HI.$type,properties:{accDescr:{name:HI.accDescr},accTitle:{name:HI.accTitle},nodes:{name:HI.nodes,defaultValue:[]},title:{name:HI.title}},superTypes:[]},Treemap:{name:RI.$type,properties:{accDescr:{name:RI.accDescr},accTitle:{name:RI.accTitle},title:{name:RI.title},TreemapRows:{name:RI.TreemapRows,defaultValue:[]}},superTypes:[]},TreemapRow:{name:BI.$type,properties:{indent:{name:BI.indent},item:{name:BI.item}},superTypes:[]},Wardley:{name:UI.$type,properties:{accDescr:{name:UI.accDescr},accelerators:{name:UI.accelerators,defaultValue:[]},accTitle:{name:UI.accTitle},anchors:{name:UI.anchors,defaultValue:[]},annotation:{name:UI.annotation,defaultValue:[]},annotations:{name:UI.annotations,defaultValue:[]},components:{name:UI.components,defaultValue:[]},deaccelerators:{name:UI.deaccelerators,defaultValue:[]},evolution:{name:UI.evolution},evolves:{name:UI.evolves,defaultValue:[]},links:{name:UI.links,defaultValue:[]},notes:{name:UI.notes,defaultValue:[]},pipelines:{name:UI.pipelines,defaultValue:[]},size:{name:UI.size},title:{name:UI.title}},superTypes:[]}}}static{o(this,`MermaidAstReflection`)}},$=new GI,KI,qI=o(()=>KI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"ArchitectureGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Architecture","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"architecture-beta"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"groups","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"services","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"junctions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"edges","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"alignments","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"LeftPort","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"lhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"RightPort","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"rhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Keyword","value":":"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Arrow","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Assignment","feature":"lhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"--"},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]}},{"$type":"Keyword","value":"-"}]}]},{"$type":"Assignment","feature":"rhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Group","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"group"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Service","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"service"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"iconText","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Junction","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"junction"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Edge","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"lhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"lhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"rhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"rhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Alignment","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"align"},{"$type":"Assignment","feature":"direction","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"row"},{"$type":"Keyword","value":"column"}]}},{"$type":"Assignment","feature":"members","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Assignment","feature":"members","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},"cardinality":"+"},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ARROW_DIRECTION","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"L"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"R"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"T"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"B"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_GROUP","definition":{"$type":"RegexToken","regex":"/\\\\{group\\\\}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_INTO","definition":{"$type":"RegexToken","regex":"/<|>/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@19"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@20"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"ARCH_ICON","definition":{"$type":"RegexToken","regex":"/\\\\([\\\\w-:]+\\\\)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_TITLE","definition":{"$type":"RegexToken","regex":"/\\\\[(?:\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'|[^\\\\[\\\\]\\\\r\\\\n]+)\\\\]/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`ArchitectureGrammarGrammar`),JI,YI=o(()=>JI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"CynefinGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Cynefin","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"cynefin-beta"},{"$type":"Keyword","value":"cynefin-beta:"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Assignment","feature":"domains","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"transitions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"DomainBlock","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"domain","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Assignment","feature":"items","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"DomainItem","definition":{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Transition","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"from","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":"-->"},{"$type":"Assignment","feature":"to","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"DOMAIN_NAME","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"complex"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"complicated"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"clear"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"chaotic"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"confusion"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@11"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@12"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`CynefinGrammarGrammar`),XI,ZI=o(()=>XI??=eP('{"$type":"Grammar","isDeclared":true,"name":"EventModeling","interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"rules":[{"$type":"ParserRule","entry":true,"name":"EventModel","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"eventmodeling"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"frames","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"dataEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"noteEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"gwtEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntityType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rmo"},{"$type":"Keyword","value":"readmodel"},{"$type":"Keyword","value":"ui"},{"$type":"Keyword","value":"cmd"},{"$type":"Keyword","value":"command"},{"$type":"Keyword","value":"evt"},{"$type":"Keyword","value":"event"},{"$type":"Keyword","value":"pcr"},{"$type":"Keyword","value":"processor"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"json"},{"$type":"Keyword","value":"jsobj"},{"$type":"Keyword","value":"figma"},{"$type":"Keyword","value":"salt"},{"$type":"Keyword","value":"uri"},{"$type":"Keyword","value":"md"},{"$type":"Keyword","value":"html"},{"$type":"Keyword","value":"text"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataInline","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataInlineValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataBlock","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataBlockValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"QualifiedName","dataType":"string","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"."},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmTimeFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"tf"},{"$type":"Keyword","value":"timeframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmResetFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rf"},{"$type":"Keyword","value":"resetframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmFrame","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"entity"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"data"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmNoteEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"note"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwt","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"gwt"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"given"},{"$type":"Assignment","feature":"givenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"},{"$type":"Group","elements":[{"$type":"Keyword","value":"when"},{"$type":"Assignment","feature":"whenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}],"cardinality":"?"},{"$type":"Keyword","value":"then"},{"$type":"Assignment","feature":"thenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwtStatement","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@9"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_EID","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_FI","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"EM_ID","definition":{"$type":"RegexToken","regex":"/[_a-zA-Z][\\\\w_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_FID","definition":{"$type":"RegexToken","regex":"/\\\\d{1,3}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_INLINE","definition":{"$type":"RegexToken","regex":"/\\\\{(.*)\\\\}|\\"(.*)\\"|\'(.*)\'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_BLOCK","definition":{"$type":"RegexToken","regex":"/\\\\{[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?\\\\}(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"EM_WS","definition":{"$type":"RegexToken","regex":"/\\\\s+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SL_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\/[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"imports":[],"types":[]}'),`EventModelingGrammar`),QI,$I=o(()=>QI??=eP(`{"$type":"Grammar","isDeclared":true,"name":"GitGraphGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"GitGraph","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Keyword","value":":"}]},{"$type":"Keyword","value":"gitGraph:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Keyword","value":":"}]}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"Assignment","feature":"statements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Direction","definition":{"$type":"Assignment","feature":"dir","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"LR"},{"$type":"Keyword","value":"TB"},{"$type":"Keyword","value":"BT"}]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Commit","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"commit"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"msg:","cardinality":"?"},{"$type":"Assignment","feature":"message","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Branch","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"branch"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"order:"},{"$type":"Assignment","feature":"order","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Merge","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"merge"},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Checkout","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"checkout"},{"$type":"Keyword","value":"switch"}]},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CherryPicking","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"cherry-pick"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"parent:"},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@14"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"REFERENCE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\w([-\\\\./\\\\w]*[-\\\\w])?/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`GitGraphGrammarGrammar`),eL,tL=o(()=>eL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"InfoGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Info","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"info"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"showInfo"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"?"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@7"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`InfoGrammarGrammar`),nL,rL=o(()=>nL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"PacketGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Packet","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"packet"},{"$type":"Keyword","value":"packet-beta"}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"Assignment","feature":"blocks","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PacketBlock","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"start","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"end","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}],"cardinality":"?"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"+"},{"$type":"Assignment","feature":"bits","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]}]},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@9"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PacketGrammarGrammar`),iL,aL=o(()=>iL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"PieGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Pie","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"pie"},{"$type":"Assignment","feature":"showData","operator":"?=","terminal":{"$type":"Keyword","value":"showData"},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Assignment","feature":"sections","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PieSection","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"FLOAT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?(0|[1-9][0-9]*)(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@2"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@3"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@11"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@12"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PieGrammarGrammar`),oL,sL=o(()=>oL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RadarGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Radar","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":"radar-beta:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":":"}]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"axis"},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"curve"},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Label","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Axis","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Curve","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Keyword","value":"}"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Entries","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"DetailedEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"axis","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@2"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":":","cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"NumberEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Option","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"showLegend"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"ticks"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"max"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"min"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"graticule"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"GRATICULE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"circle"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"polygon"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@16"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[{"$type":"Interface","name":"Entry","attributes":[{"$type":"TypeAttribute","name":"axis","isOptional":true,"type":{"$type":"ReferenceType","referenceType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@2"}},"isMulti":false}},{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}],"superTypes":[]}],"types":[]}`),`RadarGrammarGrammar`),cL,lL=o(()=>cL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadAbnfGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_RULENAME","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Za-z][A-Za-z0-9-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_NUMVAL","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/%[xXdDbB][0-9A-Fa-f]+(?:-[0-9A-Fa-f]+|\\\\.[0-9A-Fa-f]+)*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_REPEAT","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[0-9]*\\\\*[0-9]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ABNF_EXACT_REPEAT","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[0-9]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ABNF_COMMENT","definition":{"$type":"RegexToken","regex":"/;[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadAbnf","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-abnf-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"="},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfAlternation","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfConcatenation","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},"cardinality":"+"},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfElement","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"repeat","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"repeat","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"primary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfPrimary","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfStringLiteral","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfNumVal","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfRuleName","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfGroup","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"AbnfOptionalGroup","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadAbnf","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfAlternation","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfConcatenation","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfElement","attributes":[{"$type":"TypeAttribute","name":"repeat","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"primary","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"AbnfPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"AbnfStringLiteral","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfNumVal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfRuleName","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"AbnfGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"AbnfOptionalGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadAbnfGrammarGrammar`),uL,dL=o(()=>uL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadEbnfGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EBNF_SPECIAL_SEQUENCE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\?(?=[^?;]*[^?\\\\s;][^?;]*\\\\?)[^?;]*\\\\?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_BLOCK_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EBNF_ISO_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\(\\\\*[\\\\s\\\\S]*?\\\\*\\\\)/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadEbnf","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-ebnf-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"="},{"$type":"Keyword","value":"::="}]},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfChoice","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"|"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfSequence","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":",","cardinality":"?"},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfTerm","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"base","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"postfixes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfPrimary","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfTerminal","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfNonTerminal","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfSpecial","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfGroup","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOptional","returnType":{"$ref":"#/interfaces@11"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfRepetition","returnType":{"$ref":"#/interfaces@12"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"{"},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":"}"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfPostfix","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@25"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@26"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@27"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOptionalPostfix","returnType":{"$ref":"#/interfaces@13"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"?"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfZeroOrMorePostfix","returnType":{"$ref":"#/interfaces@14"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"*"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfOneOrMorePostfix","returnType":{"$ref":"#/interfaces@15"},"definition":{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"+"}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EbnfExceptionPostfix","returnType":{"$ref":"#/interfaces@16"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"except","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadEbnf","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfChoice","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfSequence","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfTerm","attributes":[{"$type":"TypeAttribute","name":"base","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false},{"$type":"TypeAttribute","name":"postfixes","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@6"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"EbnfPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"EbnfPostfix","attributes":[],"superTypes":[]},{"$type":"Interface","name":"EbnfTerminal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfNonTerminal","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfSpecial","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"text","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfGroup","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfOptional","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfRepetition","superTypes":[{"$ref":"#/interfaces@5"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"EbnfOptionalPostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfZeroOrMorePostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfOneOrMorePostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"operator","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"EbnfExceptionPostfix","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"except","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadEbnfGrammarGrammar`),fL,pL=o(()=>fL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"RR_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"RR_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"RR_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"RR_BLOCK_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"Railroad","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"="},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadExpression","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadSequenceExpr","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"sequence"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadChoiceExpr","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"choice"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadOptionalExpr","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"optional"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadOneOrMoreExpr","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"oneOrMore"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadZeroOrMoreExpr","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"zeroOrMore"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadTerminalExpr","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"terminal"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadNonTerminalExpr","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"nonterminal"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"RailroadSpecialExpr","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"special"},{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"Railroad","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"RailroadRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"RailroadExpression","attributes":[],"superTypes":[]},{"$type":"Interface","name":"RailroadSequenceExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}}},"isOptional":false}]},{"$type":"Interface","name":"RailroadChoiceExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}}},"isOptional":false}]},{"$type":"Interface","name":"RailroadOptionalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadOneOrMoreExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadZeroOrMoreExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"RailroadTerminalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"RailroadNonTerminalExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"RailroadSpecialExpr","superTypes":[{"$ref":"#/interfaces@2"}],"attributes":[{"$type":"TypeAttribute","name":"text","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadGrammarGrammar`),mL,hL=o(()=>mL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"RailroadPegGrammar","rules":[{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"PEG_ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[A-Z_a-z][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"PEG_STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t \\\\r\\\\n]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"PEG_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/#[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"ParserRule","entry":true,"name":"RailroadPeg","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"railroad-peg-beta"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"},{"$type":"Assignment","feature":"rules","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegRule","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Keyword","value":"<-"},{"$type":"Assignment","feature":"definition","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":";"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegOrderedChoice","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"alternatives","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegSequence","returnType":{"$ref":"#/interfaces@3"},"definition":{"$type":"Assignment","feature":"elements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"+"},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegPrefix","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"&"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"!"}}],"cardinality":"?"},{"$type":"Assignment","feature":"suffix","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegSuffix","returnType":{"$ref":"#/interfaces@5"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"primary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"?"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"*"}},{"$type":"Assignment","feature":"operator","operator":"=","terminal":{"$type":"Keyword","value":"+"}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegPrimary","returnType":{"$ref":"#/interfaces@6"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegLiteral","returnType":{"$ref":"#/interfaces@7"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegIdentifier","returnType":{"$ref":"#/interfaces@8"},"definition":{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegGroup","returnType":{"$ref":"#/interfaces@9"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"element","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PegAny","returnType":{"$ref":"#/interfaces@10"},"definition":{"$type":"Assignment","feature":"dot","operator":"=","terminal":{"$type":"Keyword","value":"."}},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"RailroadPeg","attributes":[{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"rules","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@1"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegRule","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"definition","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegOrderedChoice","attributes":[{"$type":"TypeAttribute","name":"alternatives","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@3"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegSequence","attributes":[{"$type":"TypeAttribute","name":"elements","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@4"}}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegPrefix","attributes":[{"$type":"TypeAttribute","name":"operator","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"suffix","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@5"}},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"PegSuffix","attributes":[{"$type":"TypeAttribute","name":"primary","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@6"}},"isOptional":false},{"$type":"TypeAttribute","name":"operator","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"PegPrimary","attributes":[],"superTypes":[]},{"$type":"Interface","name":"PegLiteral","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"PegIdentifier","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]},{"$type":"Interface","name":"PegGroup","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"element","type":{"$type":"SimpleType","typeRef":{"$ref":"#/interfaces@2"}},"isOptional":false}]},{"$type":"Interface","name":"PegAny","superTypes":[{"$ref":"#/interfaces@6"}],"attributes":[{"$type":"TypeAttribute","name":"dot","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}]}],"imports":[],"types":[]}`),`RailroadPegGrammarGrammar`),gL,_L=o(()=>gL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"TreemapGrammar","rules":[{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"Treemap","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]},{"$type":"Assignment","feature":"TreemapRows","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"TREEMAP_KEYWORD","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap-beta"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"CLASS_DEF","definition":{"$type":"RegexToken","regex":"/classDef\\\\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\\\\s+([^;\\\\r\\\\n]*))?(?:;)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STYLE_SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":::"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"COMMA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":","},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"TreemapRow","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"item","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"ClassDef","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Item","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Section","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Leaf","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ID2","definition":{"$type":"RegexToken","regex":"/[a-zA-Z_][a-zA-Z0-9_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER2","definition":{"$type":"RegexToken","regex":"/[0-9_\\\\.\\\\,]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"MyNumber","dataType":"number","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"STRING2","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[{"$type":"Interface","name":"Item","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"classSelector","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"Section","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[]},{"$type":"Interface","name":"Leaf","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}]},{"$type":"Interface","name":"ClassDefStatement","attributes":[{"$type":"TypeAttribute","name":"className","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"styleText","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"Treemap","attributes":[{"$type":"TypeAttribute","name":"TreemapRows","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@15"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * Treemap grammar for Langium\\n * Converted from mindmap grammar\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treemap keyword, allowing for empty lines and comments before the\\n * treemap declaration.\\n */"}`),`TreemapGrammarGrammar`),vL,yL=o(()=>vL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"TreeViewGrammar","rules":[{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"TreeView","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"treeView-beta"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"nodes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"CLASS_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+:::[ \\\\t]*[A-Za-z_][\\\\w-]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ICON_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+icon\\\\([\\\\w-]*(?::[\\\\w-]+)?\\\\)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"DESC_ANNOTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+##[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"QUOTED_NAME","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"BARE_NAME","definition":{"$type":"RegexToken","regex":"/(?!:::|icon\\\\(|##)[^ \\\\t\\\\n\\\\r\\"'](?:(?![ \\\\t]+:::[ \\\\t]*[A-Za-z_]|[ \\\\t]+icon\\\\(|[ \\\\t]+##)[^\\\\n\\\\r])*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"TreeNode","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}]},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"classAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"iconAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"descAnnotation","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]}],"interfaces":[{"$type":"Interface","name":"TreeView","attributes":[{"$type":"TypeAttribute","name":"nodes","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@14"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * TreeView grammar for Langium\\n *\\n * Supports both quoted labels (\\"my file\\") and bare labels (index.js).\\n * Annotations (:::class, icon(), ## description) are parsed directly into\\n * AST fields by the grammar. Value conversion for stripping quotes, extracting\\n * class names, icon names, and description text happens in valueConverter.ts.\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treeView keyword, allowing for empty lines and comments before the\\n * treeView declaration.\\n */"}`),`TreeViewGrammarGrammar`),bL,xL=o(()=>bL??=eP(`{"$type":"Grammar","isDeclared":true,"name":"WardleyGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Wardley","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@25"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@42"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"size","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"anchors","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"links","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"evolves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"pipelines","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"notes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"annotations","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Assignment","feature":"annotation","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"accelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"deaccelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Size","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@26"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"width","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"height","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolution","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@27"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EvolutionStage","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"@"},{"$type":"Assignment","feature":"boundary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}],"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"secondName","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Anchor","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Component","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"decorator","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Keyword","value":")"}]}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Label","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"negX","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetX","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"negY","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetY","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Decorator","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"strategy","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Link","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"from","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"fromPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"arrow","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"cardinality":"?"},{"$type":"Assignment","feature":"to","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"toPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"linkLabel","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolve","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@32"},"arguments":[]},{"$type":"Assignment","feature":"component","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"target","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Pipeline","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@33"},"arguments":[]},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"+"},{"$type":"Keyword","value":"}"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PipelineComponent","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Note","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@34"},"arguments":[]},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotations","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@35"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotation","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@36"},"arguments":[]},{"$type":"Assignment","feature":"number","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CoordinateValue","dataType":"number","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Accelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@37"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Deaccelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@38"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"WARDLEY_NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"->"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_PORT","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<>"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+>"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_ARROW","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-->"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-.->"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":">"},"parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'<>/","parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'/","parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_LABEL","definition":{"$type":"RegexToken","regex":"/;[^\\\\n\\\\r]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRATEGY","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"build"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"buy"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"outsource"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"market"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_WARDLEY","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"wardley-beta"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_SIZE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"size"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLUTION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolution"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANCHOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"anchor"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_COMPONENT","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"component"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_LABEL","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"label"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_INERTIA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"inertia"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLVE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolve"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_PIPELINE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"pipeline"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_NOTE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"note"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATIONS","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotations"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotation"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"accelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_DEACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"deaccelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NAME_WITH_SPACES","definition":{"$type":"RegexToken","regex":"/(?!title\\\\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \\\\t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@44"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@45"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@46"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@47"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@48"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`WardleyGrammarGrammar`),SL={languageId:`architecture`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},CL={languageId:`cynefin`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},wL={languageId:`eventmodeling`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},TL={languageId:`gitGraph`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},EL={languageId:`info`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},DL={languageId:`packet`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},OL={languageId:`pie`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},kL={languageId:`radar`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},AL={languageId:`railroadAbnf`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},jL={languageId:`railroadEbnf`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},ML={languageId:`railroad`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},NL={languageId:`railroadPeg`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},PL={languageId:`treemap`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},FL={languageId:`treeView`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},IL={languageId:`wardley`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},LL={AstReflection:o(()=>new GI,`AstReflection`)},RL={Grammar:o(()=>qI(),`Grammar`),LanguageMetaData:o(()=>SL,`LanguageMetaData`),parser:{}},zL={Grammar:o(()=>YI(),`Grammar`),LanguageMetaData:o(()=>CL,`LanguageMetaData`),parser:{}},BL={Grammar:o(()=>ZI(),`Grammar`),LanguageMetaData:o(()=>wL,`LanguageMetaData`),parser:{}},VL={Grammar:o(()=>$I(),`Grammar`),LanguageMetaData:o(()=>TL,`LanguageMetaData`),parser:{}},HL={Grammar:o(()=>tL(),`Grammar`),LanguageMetaData:o(()=>EL,`LanguageMetaData`),parser:{}},UL={Grammar:o(()=>rL(),`Grammar`),LanguageMetaData:o(()=>DL,`LanguageMetaData`),parser:{}},WL={Grammar:o(()=>aL(),`Grammar`),LanguageMetaData:o(()=>OL,`LanguageMetaData`),parser:{}},GL={Grammar:o(()=>sL(),`Grammar`),LanguageMetaData:o(()=>kL,`LanguageMetaData`),parser:{}},KL={Grammar:o(()=>lL(),`Grammar`),LanguageMetaData:o(()=>AL,`LanguageMetaData`),parser:{}},qL={Grammar:o(()=>dL(),`Grammar`),LanguageMetaData:o(()=>jL,`LanguageMetaData`),parser:{}},JL={Grammar:o(()=>pL(),`Grammar`),LanguageMetaData:o(()=>ML,`LanguageMetaData`),parser:{}},YL={Grammar:o(()=>hL(),`Grammar`),LanguageMetaData:o(()=>NL,`LanguageMetaData`),parser:{}},XL={Grammar:o(()=>_L(),`Grammar`),LanguageMetaData:o(()=>PL,`LanguageMetaData`),parser:{}},ZL={Grammar:o(()=>yL(),`Grammar`),LanguageMetaData:o(()=>FL,`LanguageMetaData`),parser:{}},QL={Grammar:o(()=>xL(),`Grammar`),LanguageMetaData:o(()=>IL,`LanguageMetaData`),parser:{}},$L={ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/accTitle[\t ]*:([^\n\r]*)/,TITLE:/title([\t ][^\n\r]*|)/},eR=class extends Ij{static{o(this,`AbstractMermaidValueConverter`)}runConverter(e,t,n){let r=this.runCommonConverter(e,t,n);return r===void 0&&(r=this.runCustomConverter(e,t,n)),r===void 0?super.runConverter(e,t,n):r}runCommonConverter(e,t,n){let r=$L[e.name];if(r===void 0)return;let i=r.exec(t);if(i!==null){if(i[1]!==void 0)return i[1].trim().replace(/[\t ]{2,}/gm,` `);if(i[2]!==void 0)return i[2].replace(/^\s*/gm,``).replace(/\s+$/gm,``).replace(/[\t ]{2,}/gm,` `).replace(/[\n\r]{2,}/gm,` +`)}}},tR=class extends eR{static{o(this,`CommonValueConverter`)}runCustomConverter(e,t,n){}},nR=class extends Fj{static{o(this,`AbstractMermaidTokenBuilder`)}constructor(e){super(),this.keywords=new Set(e)}buildKeywordTokens(e,t,n){let r=super.buildKeywordTokens(e,t,n);return r.forEach(e=>{this.keywords.has(e.name)&&e.PATTERN!==void 0&&(e.PATTERN=RegExp(e.PATTERN.toString()+`(?:(?=%%)|(?!\\S))`))}),r}};(class extends nR{static{o(this,`CommonTokenBuilder`)}});export{FN as C,PN as S,EF as T,YL as _,zL as a,QL as b,VL as c,UL as d,WL as f,JL as g,qL as h,tR as i,HL as l,KL as m,eR as n,XN as o,GL as p,RL as r,BL as s,nR as t,LL as u,ZL as v,LN as w,o as x,XL as y}; \ No newline at end of file diff --git a/www/assets/chunk-GTNCS2PH-CoZ--rjp.js b/www/assets/chunk-GTNCS2PH-CoZ--rjp.js new file mode 100644 index 0000000..61573c5 --- /dev/null +++ b/www/assets/chunk-GTNCS2PH-CoZ--rjp.js @@ -0,0 +1,88 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,a as r,b as i,c as a,x as o,z as s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{y as c}from"./index-DoQkmpth.js";var l=``,u=``,d=``,f=[],p=new Map,m=t(e=>s(e,o()),`sanitizeText`),h=t(e=>{switch(e.type){case`terminal`:return{...e,value:m(e.value)};case`nonterminal`:return{...e,name:m(e.name)};case`sequence`:return{...e,elements:e.elements.map(h)};case`choice`:return{...e,alternatives:e.alternatives.map(h)};case`optional`:return{...e,element:h(e.element)};case`repetition`:return{...e,element:h(e.element),separator:e.separator?h(e.separator):void 0};case`special`:return{...e,text:m(e.text)}}},`sanitizeAstNode`),g=t(()=>{l=``,u=``,d=``,f.length=0,p.clear(),r(),e.debug(`[Railroad] Database cleared`)},`clear`),_=t(t=>{l=m(t),e.debug(`[Railroad] Title set:`,t)},`setTitle`),v=t(()=>l,`getTitle`),y={clear:g,setTitle:_,getTitle:v,addRule:t(t=>{let n={...t,name:m(t.name),definition:h(t.definition),comment:t.comment?m(t.comment):void 0};e.debug(`[Railroad] Adding rule:`,n.name),p.has(n.name)&&e.warn(`[Railroad] Rule '${n.name}' is already defined. Overwriting.`),f.push(n),p.set(n.name,n)},`addRule`),getRules:t(()=>f,`getRules`),getRule:t(e=>p.get(e),`getRule`),setAccTitle:t(t=>{u=m(t).replace(/^\s+/g,``),e.debug(`[Railroad] Accessibility title set:`,t)},`setAccTitle`),getAccTitle:t(()=>u,`getAccTitle`),setAccDescription:t(t=>{d=m(t).replace(/\n\s+/g,` +`),e.debug(`[Railroad] Accessibility description set:`,t)},`setAccDescription`),getAccDescription:t(()=>d,`getAccDescription`),setDiagramTitle:_,getDiagramTitle:v},b={compactMode:!1,padding:10,verticalSeparation:8,horizontalSeparation:10,arcRadius:10,fontSize:14,fontFamily:`monospace`,terminalFill:`#FFFFC0`,terminalStroke:`#000000`,terminalTextColor:`#000000`,nonTerminalFill:`#FFFFFF`,nonTerminalStroke:`#000000`,nonTerminalTextColor:`#000000`,lineColor:`#000000`,strokeWidth:2,markerFill:`#000000`,commentFill:`#E8E8E8`,commentStroke:`#888888`,commentTextColor:`#666666`,specialFill:`#F0E0FF`,specialStroke:`#8800CC`,ruleNameColor:`#000066`,showMarkers:!0,markerRadius:5},x=/^#(?:[\da-f]{3,4}|[\da-f]{6}|[\da-f]{8})$|^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch)\([\d\s%+,./-]+\)$|^[a-z]+$/i,S=/^[\w "',.-]+$/,C=new Set([`compactMode`,`padding`,`verticalSeparation`,`horizontalSeparation`,`arcRadius`,`fontSize`,`fontFamily`,`terminalFill`,`terminalStroke`,`terminalTextColor`,`nonTerminalFill`,`nonTerminalStroke`,`nonTerminalTextColor`,`lineColor`,`strokeWidth`,`markerFill`,`commentFill`,`commentStroke`,`commentTextColor`,`specialFill`,`specialStroke`,`ruleNameColor`,`showMarkers`,`markerRadius`]),w=t(e=>e?Object.keys(e).every(e=>e===`railroad`||C.has(e)):!1,`isRailroadStyleOptions`),T=t(e=>e?`railroad`in e&&e.railroad?e.railroad:w(e)?e:{}:{},`extractRailroadOverrides`),E=t(e=>{if(!e||w(e))return{};let{railroad:t,svgId:n,theme:r,look:i,...a}=e;return a},`extractThemeOverrides`),D=t((e,t)=>{if(typeof e!=`string`)return t;let n=e.trim();return x.test(n)?n:t},`sanitizeColorValue`),O=t((e,t)=>{if(typeof e!=`string`)return t;let n=e.trim();return S.test(n)?n:t},`sanitizeFontFamilyValue`),k=t((e,t)=>{let n=typeof e==`number`?e:typeof e==`string`?Number.parseFloat(e):NaN;return Number.isFinite(n)&&n>=0?n:t},`sanitizeNumberValue`),A=t(e=>{let t=typeof e==`number`?e:typeof e==`string`?Number.parseFloat(e):NaN;return Number.isFinite(t)&&t>0?t:void 0},`parseThemeFontSize`),j=t(e=>{let t=O(e.fontFamily,b.fontFamily),n=A(e.fontSize)??b.fontSize;return{...b,fontFamily:t,fontSize:n,terminalFill:D(e.secondBkg??e.secondaryColor,b.terminalFill),terminalStroke:D(e.secondaryBorderColor??e.lineColor,b.terminalStroke),terminalTextColor:D(e.secondaryTextColor??e.textColor,b.terminalTextColor),nonTerminalFill:D(e.mainBkg??e.background,b.nonTerminalFill),nonTerminalStroke:D(e.primaryBorderColor??e.lineColor,b.nonTerminalStroke),nonTerminalTextColor:D(e.primaryTextColor??e.textColor,b.nonTerminalTextColor),lineColor:D(e.lineColor,b.lineColor),markerFill:D(e.lineColor,b.markerFill),commentFill:D(e.labelBackground??e.tertiaryColor,b.commentFill),commentStroke:D(e.tertiaryBorderColor??e.lineColor,b.commentStroke),commentTextColor:D(e.tertiaryTextColor??e.textColor,b.commentTextColor),specialFill:D(e.tertiaryColor??e.secondaryColor,b.specialFill),specialStroke:D(e.tertiaryBorderColor??e.secondaryBorderColor,b.specialStroke),ruleNameColor:D(e.titleColor??e.textColor,b.ruleNameColor)}},`buildThemeDefaults`),M=t(e=>{let t=i(),r=j({...n(),...t.themeVariables??{},...E(e)}),a={...t.railroad??{},...T(e)};return{compactMode:a.compactMode??r.compactMode,padding:k(a.padding,r.padding),verticalSeparation:k(a.verticalSeparation,r.verticalSeparation),horizontalSeparation:k(a.horizontalSeparation,r.horizontalSeparation),arcRadius:k(a.arcRadius,r.arcRadius),fontSize:k(a.fontSize,r.fontSize),fontFamily:O(a.fontFamily,r.fontFamily),terminalFill:D(a.terminalFill,r.terminalFill),terminalStroke:D(a.terminalStroke,r.terminalStroke),terminalTextColor:D(a.terminalTextColor,r.terminalTextColor),nonTerminalFill:D(a.nonTerminalFill,r.nonTerminalFill),nonTerminalStroke:D(a.nonTerminalStroke,r.nonTerminalStroke),nonTerminalTextColor:D(a.nonTerminalTextColor,r.nonTerminalTextColor),lineColor:D(a.lineColor,r.lineColor),strokeWidth:k(a.strokeWidth,r.strokeWidth),markerFill:D(a.markerFill,r.markerFill),commentFill:D(a.commentFill,r.commentFill),commentStroke:D(a.commentStroke,r.commentStroke),commentTextColor:D(a.commentTextColor,r.commentTextColor),specialFill:D(a.specialFill,r.specialFill),specialStroke:D(a.specialStroke,r.specialStroke),ruleNameColor:D(a.ruleNameColor,r.ruleNameColor),showMarkers:a.showMarkers??r.showMarkers,markerRadius:k(a.markerRadius,r.markerRadius)}},`buildRailroadStyleOptions`),N=t(e=>{let{fontFamily:t,fontSize:n,terminalFill:r,terminalStroke:i,terminalTextColor:a,nonTerminalFill:o,nonTerminalStroke:s,nonTerminalTextColor:c,lineColor:l,strokeWidth:u,markerFill:d,commentFill:f,commentStroke:p,commentTextColor:m,specialFill:h,specialStroke:g,ruleNameColor:_}=M(e);return` + .railroad-diagram { + font-family: ${t}; + font-size: ${n}px; + } + + .railroad-terminal rect { + fill: ${r}; + stroke: ${i}; + stroke-width: ${u}px; + } + + .railroad-terminal text { + fill: ${a}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-nonterminal rect { + fill: ${o}; + stroke: ${s}; + stroke-width: ${u}px; + } + + .railroad-nonterminal text { + fill: ${c}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-line { + stroke: ${l}; + stroke-width: ${u}px; + fill: none; + } + + .railroad-start circle, + .railroad-end circle { + fill: ${d}; + } + + .railroad-comment ellipse { + fill: ${f}; + stroke: ${p}; + stroke-width: ${u}px; + } + + .railroad-comment text { + fill: ${m}; + font-style: italic; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-special rect { + fill: ${h}; + stroke: ${g}; + stroke-width: ${u}px; + stroke-dasharray: 5,3; + } + + .railroad-special text { + fill: ${c}; + font-family: ${t}; + font-size: ${n}px; + text-anchor: middle; + dominant-baseline: middle; + } + + .railroad-rule-name { + font-weight: bold; + fill: ${_}; + font-family: ${t}; + font-size: ${n}px; + } + + .railroad-group { + /* Grouping container, no specific styles */ + } +`},`getStyles`),P=class{constructor(){this.d=``}static{t(this,`PathBuilder`)}moveTo(e,t){return this.d+=`M ${e} ${t} `,this}lineTo(e,t){return this.d+=`L ${e} ${t} `,this}horizontalTo(e){return this.d+=`H ${e} `,this}verticalTo(e){return this.d+=`V ${e} `,this}arcTo(e,t,n,r,i,a,o){return this.d+=`A ${e} ${t} ${n} ${+!!r} ${+!!i} ${a} ${o} `,this}build(){return this.d.trim()}},F=class{constructor(e,t=M()){this.textCache=new Map,this.svg=e,this.config=t}static{t(this,`RailroadRenderer`)}measureText(e){if(this.textCache.has(e))return this.textCache.get(e);let t=this.svg.append(`text`).attr(`font-family`,this.config.fontFamily).attr(`font-size`,this.config.fontSize).text(e),n=t.node().getBBox(),r={width:n.width,height:n.height};return t.remove(),this.textCache.set(e,r),r}renderTerminal(e,t){let n=this.measureText(t),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-terminal`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i).attr(`rx`,10).attr(`ry`,10),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(t),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderNonTerminal(e,t){let n=this.measureText(t),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-nonterminal`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(t),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderSequence(e,t){let n=t.map(t=>this.renderExpression(e,t)),r=0,i=0,a=0;for(let e of n)r+=e.dimensions.width,i=Math.max(i,e.dimensions.up),a=Math.max(a,e.dimensions.down);r+=(n.length-1)*this.config.horizontalSeparation;let o=e.append(`g`).attr(`class`,`railroad-sequence`),s=0;for(let e=0;ethis.renderExpression(e,t)),r=0,i=0;for(let e of n)r=Math.max(r,e.dimensions.width),i+=e.dimensions.height;i+=(n.length-1)*this.config.verticalSeparation;let a=this.config.arcRadius,o=a*4,s=r+o,c=e.append(`g`).attr(`class`,`railroad-choice`),l=0,u=i/2;for(let e of n){let t=l,n=t+e.dimensions.up,i=a*2+(r-e.dimensions.width)/2;c.node().appendChild(e.element).setAttribute(`transform`,`translate(${i}, ${t})`);let o=new P,d=n>u;n===u?o.moveTo(0,u).lineTo(i,n):o.moveTo(0,u).arcTo(a,a,0,!1,d,a,u+(d?a:-a)).lineTo(a,n-(d?a:-a)).arcTo(a,a,0,!1,!d,a*2,n).lineTo(i,n),c.append(`path`).attr(`class`,`railroad-line`).attr(`d`,o.build());let f=new P,p=i+e.dimensions.width,m=s-a*2;n===u?f.moveTo(p,n).lineTo(s,u):f.moveTo(p,n).lineTo(m,n).arcTo(a,a,0,!1,!d,s-a,n+(d?-a:a)).lineTo(s-a,u+(d?a:-a)).arcTo(a,a,0,!1,d,s,u),c.append(`path`).attr(`class`,`railroad-line`).attr(`d`,f.build()),l+=e.dimensions.height+this.config.verticalSeparation}return{element:c.node(),dimensions:{width:s,height:i,up:u,down:i-u}}}renderOptional(e,t){let n=this.renderExpression(e,t),r=this.config.arcRadius,i=r*2,a=n.dimensions.width+r*4,o=n.dimensions.height+i,s=e.append(`g`).attr(`class`,`railroad-optional`),c=r*2,l=i;s.node().appendChild(n.element).setAttribute(`transform`,`translate(${c}, ${l})`);let u=l+n.dimensions.up,d=new P().moveTo(0,u).lineTo(r*2,u);s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,d.build());let f=new P().moveTo(c+n.dimensions.width,u).lineTo(a,u);s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,f.build());let p=new P().moveTo(0,u).arcTo(r,r,0,!1,!1,r,u-r).lineTo(r,r).arcTo(r,r,0,!1,!0,r*2,0).lineTo(a-r*2,0).arcTo(r,r,0,!1,!0,a-r,r).lineTo(a-r,u-r).arcTo(r,r,0,!1,!1,a,u);return s.append(`path`).attr(`class`,`railroad-line`).attr(`d`,p.build()),{element:s.node(),dimensions:{width:a,height:o,up:u,down:o-u}}}renderRepetition(e,t,n){let r=this.renderExpression(e,t),i=this.config.arcRadius,a=i*2,o=r.dimensions.width+i*4,s=n===0,c=r.dimensions.height+a+(s?a:0),l=e.append(`g`).attr(`class`,`railroad-repetition`),u=i*2,d=s?a:0;l.node().appendChild(r.element).setAttribute(`transform`,`translate(${u}, ${d})`);let f=d+r.dimensions.up;l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(0,f).lineTo(i*2,f).build()),l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(u+r.dimensions.width,f).lineTo(o,f).build());let p=d+r.dimensions.height+i,m=new P().moveTo(u+r.dimensions.width,f).arcTo(i,i,0,!1,!0,u+r.dimensions.width+i,f+i).lineTo(u+r.dimensions.width+i,p).arcTo(i,i,0,!1,!0,u+r.dimensions.width,p+i).lineTo(i*2,p+i).arcTo(i,i,0,!1,!0,i,p).lineTo(i,f+i).arcTo(i,i,0,!1,!0,i*2,f);if(l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,m.build()),s){let e=new P().moveTo(0,f).arcTo(i,i,0,!1,!1,i,f-i).lineTo(i,i).arcTo(i,i,0,!1,!0,i*2,0).lineTo(o-i*2,0).arcTo(i,i,0,!1,!0,o-i,i).lineTo(o-i,f-i).arcTo(i,i,0,!1,!1,o,f);l.append(`path`).attr(`class`,`railroad-line`).attr(`d`,e.build())}return{element:l.node(),dimensions:{width:o,height:c,up:f,down:c-f}}}renderSpecial(e,t){let n=this.measureText(`? `+t+` ?`),r=n.width+this.config.padding*2,i=n.height+this.config.padding*2,a=e.append(`g`).attr(`class`,`railroad-special`);return a.append(`rect`).attr(`x`,0).attr(`y`,0).attr(`width`,r).attr(`height`,i),a.append(`text`).attr(`x`,r/2).attr(`y`,i/2).text(`? `+t+` ?`),{element:a.node(),dimensions:{width:r,height:i,up:i/2,down:i/2}}}renderExpression(e,t){switch(t.type){case`terminal`:return this.renderTerminal(e,t.value);case`nonterminal`:return this.renderNonTerminal(e,t.name);case`sequence`:return this.renderSequence(e,t.elements);case`choice`:return this.renderChoice(e,t.alternatives);case`optional`:return this.renderOptional(e,t.element);case`repetition`:return this.renderRepetition(e,t.element,t.min);case`special`:return this.renderSpecial(e,t.text);default:throw Error(`Unknown node type: ${t.type}`)}}renderRule(e,t){let n=this.svg.append(`g`).attr(`class`,`railroad-rule`).attr(`transform`,`translate(0, ${t})`),r=e.name+` =`,i=this.measureText(r).width+20,a=i+20,o=n.append(`g`),s=this.renderExpression(o,e.definition),c=Math.max(20,s.dimensions.up),l=c-s.dimensions.up;return o.attr(`transform`,`translate(${a}, ${l})`),n.append(`g`).attr(`class`,`railroad-rule-name-group`).append(`text`).attr(`class`,`railroad-rule-name`).attr(`x`,0).attr(`y`,c).text(r),n.append(`g`).attr(`class`,`railroad-start`).append(`circle`).attr(`cx`,i).attr(`cy`,c).attr(`r`,this.config.markerRadius),n.append(`g`).attr(`class`,`railroad-end`).append(`circle`).attr(`cx`,a+s.dimensions.width+10).attr(`cy`,c).attr(`r`,this.config.markerRadius),n.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(i+this.config.markerRadius,c).lineTo(a,c).build()),n.append(`path`).attr(`class`,`railroad-line`).attr(`d`,new P().moveTo(a+s.dimensions.width,c).lineTo(a+s.dimensions.width+10-this.config.markerRadius,c).build()),{height:Math.max(40,l+s.dimensions.height+this.config.padding*2),width:a+s.dimensions.width+10+this.config.markerRadius}}renderDiagram(e){let t=this.config.padding,n=0;for(let r of e){let e=this.renderRule(r,t);t+=e.height+this.config.verticalSeparation,n=Math.max(n,e.width)}return{width:n+this.config.padding*2,height:t+this.config.padding}}},I=t((e,t,n)=>{a(e,t.height,t.width,n),e.attr(`viewBox`,`0 0 ${t.width} ${t.height}`)},`configureRailroadSvgSize`),L={draw:t((t,n,r)=>{e.debug(`[Railroad] Rendering diagram +`+t);try{let t=c(n);t.attr(`class`,`railroad-diagram`);let r=i().railroad?.useMaxWidth??!0,a=y.getRules();if(e.debug(`[Railroad] Rendering ${a.length} rules`),a.length===0){e.warn(`[Railroad] No rules to render`),I(t,{height:100,width:200},r);return}I(t,new F(t,M()).renderDiagram(a),r),e.debug(`[Railroad] Render complete`)}catch(t){throw e.error(`[Railroad] Render error:`,t),t}},`draw`)};export{N as n,L as r,y as t}; \ No newline at end of file diff --git a/www/assets/chunk-GWA4HPMP-C1P4FmAY.js b/www/assets/chunk-GWA4HPMP-C1P4FmAY.js new file mode 100644 index 0000000..60e92fb --- /dev/null +++ b/www/assets/chunk-GWA4HPMP-C1P4FmAY.js @@ -0,0 +1 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{j as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as r}from"./dist-Bfr8PhAA.js";var i=r(),a=t((e,t)=>{let n=e.append(`rect`);if(n.attr(`x`,t.x),n.attr(`y`,t.y),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`width`,t.width),n.attr(`height`,t.height),t.name&&n.attr(`name`,t.name),t.rx&&n.attr(`rx`,t.rx),t.ry&&n.attr(`ry`,t.ry),t.attrs!==void 0)for(let e in t.attrs)n.attr(e,t.attrs[e]);return t.class&&n.attr(`class`,t.class),n},`drawRect`),o=t((e,t)=>{a(e,{x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,stroke:t.stroke,class:`rect`}).lower()},`drawBackgroundRect`),s=t((e,t)=>{let r=t.text.replace(n,` `),i=e.append(`text`);i.attr(`x`,t.x),i.attr(`y`,t.y),i.attr(`class`,`legend`),i.style(`text-anchor`,t.anchor),t.class&&i.attr(`class`,t.class);let a=i.append(`tspan`);return a.attr(`x`,t.x+t.textMargin*2),a.text(r),i},`drawText`),c=t((e,t,n,r)=>{let a=e.append(`image`);a.attr(`x`,t),a.attr(`y`,n);let o=(0,i.sanitizeUrl)(r);a.attr(`xlink:href`,o)},`drawImage`),l=t((e,t,n,r)=>{let a=e.append(`use`);a.attr(`x`,t),a.attr(`y`,n);let o=(0,i.sanitizeUrl)(r);a.attr(`xlink:href`,`#${o}`)},`drawEmbeddedImage`),u=t(()=>({x:0,y:0,width:100,height:100,fill:`#EDF2AE`,stroke:`#666`,anchor:`start`,rx:0,ry:0}),`getNoteRect`),d=t(()=>({x:0,y:0,width:100,height:100,"text-anchor":`start`,style:`#666`,textMargin:0,rx:0,ry:0,tspan:!0}),`getTextObj`),f=t(()=>{let t=e(`.mermaidTooltip`);return t.empty()&&(t=e(`body`).append(`div`).attr(`class`,`mermaidTooltip`).style(`opacity`,0).style(`position`,`absolute`).style(`text-align`,`center`).style(`max-width`,`200px`).style(`padding`,`2px`).style(`font-size`,`12px`).style(`background`,`#ffffde`).style(`border`,`1px solid #333`).style(`border-radius`,`2px`).style(`pointer-events`,`none`).style(`z-index`,`100`)),t},`createTooltip`);export{a,d as c,c as i,o as n,s as o,l as r,u as s,f as t}; \ No newline at end of file diff --git a/www/assets/chunk-J5ZVWO5B-oDCd-gWO.js b/www/assets/chunk-J5ZVWO5B-oDCd-gWO.js new file mode 100644 index 0000000..5dfe2fe --- /dev/null +++ b/www/assets/chunk-J5ZVWO5B-oDCd-gWO.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=new Set([`redux-color`,`redux-dark-color`]),n=12,r=64,i=e(e=>Array.isArray(e)&&e.length>0,`hasPalette`),a=e((e,n)=>e!=null&&t.has(e)&&i(n),`isColorTheme`),o=/^[\w-]+$/,s=e(e=>{let t=typeof e==`string`||typeof e==`number`?String(e):``;return o.test(t)?t:`classic`},`safeLook`),c=e(e=>i(e)?e.length:0,`paletteSlotCount`),l=e((e,t)=>i(t)?c(t):typeof e==`number`&&Number.isInteger(e)&&e>0&&e<=r?e:n,`colorSlotCount`),u=e((e,t,n,r)=>{if(t===void 0||!a(n,r))return;let i=t%c(r);e.attr(`data-color-id`,`color-${i}`)},`stampColorSlot`);export{c as a,a as i,l as n,s as o,i as r,u as s,t}; \ No newline at end of file diff --git a/www/assets/chunk-JWPE2WC7-DVXcaiue.js b/www/assets/chunk-JWPE2WC7-DVXcaiue.js new file mode 100644 index 0000000..89f16f4 --- /dev/null +++ b/www/assets/chunk-JWPE2WC7-DVXcaiue.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";function t(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}e(t,`populateCommonDb`);export{t}; \ No newline at end of file diff --git a/www/assets/chunk-MBY4JIJT-CGQ6Fu8G.js b/www/assets/chunk-MBY4JIJT-CGQ6Fu8G.js new file mode 100644 index 0000000..fc924e7 --- /dev/null +++ b/www/assets/chunk-MBY4JIJT-CGQ6Fu8G.js @@ -0,0 +1,72 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,F as i,b as a,s as o,z as s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as c}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{n as l,t as u}from"./chunk-742MDFTN-5mFByRwZ.js";function d(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var f=d();function p(e){f=e}var m={exec:()=>null};function h(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(_.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var g=(()=>{try{return!0}catch{return!1}})(),_={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^
    /i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,`i`)},ee=/^(?:[ \t]*(?:\n|$))+/,te=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,ne=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,v=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,re=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,y=/(?:[*+-]|\d{1,9}[.)])/,ie=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,ae=h(ie).replace(/bull/g,y).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),oe=h(ie).replace(/bull/g,y).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),b=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,se=/^[^\n]+/,x=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,ce=h(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,x).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),le=h(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,y).getRegex(),S=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,C=/|$))/,ue=h(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,C).replace(`tag`,S).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),de=h(b).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex(),w={blockquote:h(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,de).getRegex(),code:te,def:ce,fences:ne,heading:re,hr:v,html:ue,lheading:ae,list:le,newline:ee,paragraph:de,table:m,text:se},fe=h(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex(),pe={...w,lheading:oe,table:fe,paragraph:h(b).replace(`hr`,v).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,fe).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace(`list`,` {0,3}(?:[*+-]|1[.)]) `).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,S).getRegex()},me={...w,html:h(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,C).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:m,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:h(b).replace(`hr`,v).replace(`heading`,` *#{1,6} *[^ +]`).replace(`lheading`,ae).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},he=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,ge=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,_e=/^( {2,}|\\)\n(?!\s*$)/,ve=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,g?"(?`+)[^`]+\k(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),Te=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,Ee=h(Te,`u`).replace(/punct/g,T).getRegex(),De=h(Te,`u`).replace(/punct/g,xe).getRegex(),Oe=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,ke=h(Oe,`gu`).replace(/notPunctSpace/g,ye).replace(/punctSpace/g,E).replace(/punct/g,T).getRegex(),Ae=h(Oe,`gu`).replace(/notPunctSpace/g,Ce).replace(/punctSpace/g,Se).replace(/punct/g,xe).getRegex(),je=h(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,ye).replace(/punctSpace/g,E).replace(/punct/g,T).getRegex(),Me=h(/\\(punct)/,`gu`).replace(/punct/g,T).getRegex(),Ne=h(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Pe=h(C).replace(`(?:-->|$)`,`-->`).getRegex(),Fe=h(`^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^`).replace(`comment`,Pe).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),D=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,Ie=h(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace(`label`,D).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Le=h(/^!?\[(label)\]\[(ref)\]/).replace(`label`,D).replace(`ref`,x).getRegex(),Re=h(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,x).getRegex(),ze=h(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,Le).replace(`nolink`,Re).getRegex(),Be=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,O={_backpedal:m,anyPunctuation:Me,autolink:Ne,blockSkip:we,br:_e,code:ge,del:m,emStrongLDelim:Ee,emStrongRDelimAst:ke,emStrongRDelimUnd:je,escape:he,link:Ie,nolink:Re,punctuation:be,reflink:Le,reflinkSearch:ze,tag:Fe,text:ve,url:m},Ve={...O,link:h(/^!?\[(label)\]\((.*?)\)/).replace(`label`,D).getRegex(),reflink:h(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,D).getRegex()},k={...O,emStrongRDelimAst:Ae,emStrongLDelim:De,url:h(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`protocol`,Be).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:h(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":`>`,'"':`"`,"'":`'`},We=e=>Ue[e];function M(e,t){if(t){if(_.escapeTest.test(e))return e.replace(_.escapeReplace,We)}else if(_.escapeTestNoEncode.test(e))return e.replace(_.escapeReplaceNoEncode,We);return e}function Ge(e){try{e=encodeURI(e).replace(_.percentDecode,`%`)}catch{return null}return e}function Ke(e,t){let n=e.replace(_.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(_.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t){if(n.length>t)n.splice(t);else for(;n.length0?-2:-1}function Je(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`);r.state.inLink=!0;let c={type:e[0].charAt(0)===`!`?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:r.inlineTokens(s)};return r.state.inLink=!1,c}function Ye(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(` +`).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return r.length>=i.length?e.slice(i.length):e}).join(` +`)}var P=class{options;rules;lexer;constructor(e){this.options=e||f}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=t[0].replace(this.rules.other.codeRemoveIndent,``);return{type:`code`,raw:t[0],codeBlockStyle:`indented`,text:this.options.pedantic?e:N(e,` +`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=Ye(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=N(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:N(t[0],` +`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=N(t[0],` +`).split(` +`),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o;for(o=0;o1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=t[2].split(` +`,1)[0].replace(this.rules.other.listReplaceTabs,e=>` `.repeat(3*e.length)),l=e.split(` +`,1)[0],u=!c.trim(),d=0;if(this.options.pedantic?(d=2,s=c.trimStart()):u?d=t[1].length+1:(d=t[2].search(this.rules.other.nonSpaceChar),d=d>4?1:d,s=c.slice(d),d+=t[1].length),u&&this.rules.other.blankLine.test(l)&&(r+=l+` +`,e=e.substring(l.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(d),n=this.rules.other.hrRegex(d),i=this.rules.other.fencesBeginRegex(d),a=this.rules.other.headingBeginRegex(d),o=this.rules.other.htmlBeginRegex(d);for(;e;){let f=e.split(` +`,1)[0],p;if(l=f,this.options.pedantic?(l=l.replace(this.rules.other.listReplaceNesting,` `),p=l):p=l.replace(this.rules.other.tabCharGlobal,` `),i.test(l)||a.test(l)||o.test(l)||t.test(l)||n.test(l))break;if(p.search(this.rules.other.nonSpaceChar)>=d||!l.trim())s+=` +`+p.slice(d);else{if(u||c.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(c)||a.test(c)||n.test(c))break;s+=` +`+l}!u&&!l.trim()&&(u=!0),r+=f+` +`,e=e.substring(f.length+1),c=p.slice(d)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0));let f=null,p;this.options.gfm&&(f=this.rules.other.listIsTask.exec(s),f&&(p=f[0]!==`[ ] `,s=s.replace(this.rules.other.listReplaceTask,``))),i.items.push({type:`list_item`,raw:r,task:!!f,checked:p,loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e=0;ee.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}if(i.loose)for(let e=0;e({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t)return{type:`heading`,raw:t[0],depth:t[2].charAt(0)===`=`?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;let t=N(e.slice(0,-1),`\\`);if((e.length-t.length)%2==0)return}else{let e=qe(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let n=t[2],r=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):``;return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?n.slice(1):n.slice(1,-1)),Je(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,`$1`),title:r&&r.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let e=t[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `).toLowerCase()];if(!e){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return Je(n,e,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[2])||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=0,c=r[0][0]===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+n);(r=c.exec(t))!=null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i)continue;if(a=[...i].length,r[3]||r[4]){o+=a;continue}if((r[5]||r[6])&&n%3&&!((n+a)%3)){s+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o+s);let t=[...r[0]][0].length,c=e.slice(0,n+r.index+t+a);if(Math.min(n,a)%2){let e=c.slice(1,-1);return{type:`em`,raw:c,text:e,tokens:this.lexer.inlineTokens(e)}}let l=c.slice(2,-2);return{type:`strong`,raw:c,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e){let t=this.rules.inline.del.exec(e);if(t)return{type:`del`,raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:t[0],escaped:e}}}},F=class e{tokens;options;state;tokenizer;inlineQueue;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||f,this.options.tokenizer=this.options.tokenizer||new P,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let t={other:_,block:A.normal,inline:j.normal};this.options.pedantic?(t.block=A.pedantic,t.inline=j.pedantic):this.options.gfm&&(t.block=A.gfm,t.inline=this.options.breaks?j.breaks:j.gfm),this.tokenizer.rules=t}static get rules(){return{block:A,inline:j}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(_.carriageReturn,` +`),this.blockTokens(e,this.tokens);for(let e=0;e(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.space(e)){e=e.substring(r.raw.length);let n=t.at(-1);r.raw.length===1&&n!==void 0?n.raw+=` +`:t.push(r);continue}if(r=this.tokenizer.code(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.text,this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(r=this.tokenizer.fences(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.heading(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.hr(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.blockquote(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.list(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.html(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.def(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title},t.push(r));continue}if(r=this.tokenizer.table(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.lheading(e)){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startBlock){let t=1/0,n=e.slice(1),r;this.options.extensions.startBlock.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i))){let a=t.at(-1);n&&a?.type===`paragraph`?(a.raw+=(a.raw.endsWith(` +`)?``:` +`)+r.raw,a.text+=` +`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=a.text):t.push(r),n=i.length!==e.length,e=e.substring(r.raw.length);continue}if(r=this.tokenizer.text(e)){e=e.substring(r.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+r.raw,n.text+=` +`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n=e,r=null;if(this.tokens.links){let e=Object.keys(this.tokens.links);if(e.length>0)for(;(r=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)e.includes(r[0].slice(r[0].lastIndexOf(`[`)+1,-1))&&(n=n.slice(0,r.index)+`[`+`a`.repeat(r[0].length-2)+`]`+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(r=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,r.index)+`++`+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let i;for(;(r=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)i=r[2]?r[2].length:0,n=n.slice(0,r.index+i)+`[`+`a`.repeat(r[0].length-i-2)+`]`+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let a=!1,o=``;for(;e;){a||(o=``),a=!1;let r;if(this.options.extensions?.inline?.some(n=>(r=n.call({lexer:this},e,t))?(e=e.substring(r.raw.length),t.push(r),!0):!1))continue;if(r=this.tokenizer.escape(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.tag(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.link(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(r.raw.length);let n=t.at(-1);r.type===`text`&&n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(r=this.tokenizer.emStrong(e,n,o)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.codespan(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.br(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.del(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.autolink(e)){e=e.substring(r.raw.length),t.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(e))){e=e.substring(r.raw.length),t.push(r);continue}let i=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(i=e.substring(0,t+1))}if(r=this.tokenizer.inlineText(i)){e=e.substring(r.raw.length),r.raw.slice(-1)!==`_`&&(o=r.raw.slice(-1)),a=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(e){let t=`Infinite loop on byte: `+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw Error(t)}}return t}},I=class{options;parser;constructor(e){this.options=e||f}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(_.notSpaceStart)?.[0],i=e.replace(_.endingNewline,``)+` +`;return r?`

    `+(n?i:M(i,!0))+`
    +`:`
    `+(n?i:M(i,!0))+`
    +`}blockquote({tokens:e}){return`
    +${this.parser.parse(e)}
    +`}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`${this.parser.parseInline(e)} +`}hr(e){return`
    +`}list(e){let t=e.ordered,n=e.start,r=``;for(let t=0;t +`+r+` +`}listitem(e){let t=``;if(e.task){let n=this.checkbox({checked:!!e.checked});e.loose?e.tokens[0]?.type===`paragraph`?(e.tokens[0].text=n+` `+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&e.tokens[0].tokens[0].type===`text`&&(e.tokens[0].tokens[0].text=n+` `+M(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:`text`,raw:n+` `,text:n+` `,escaped:!0}):t+=n+` `}return t+=this.parser.parse(e.tokens,!!e.loose),`
  • ${t}
  • +`}checkbox({checked:e}){return``}paragraph({tokens:e}){return`

    ${this.parser.parseInline(e)}

    +`}table(e){let t=``,n=``;for(let t=0;t${r}`,` + +`+t+` +`+r+`
    +`}tablerow({text:e}){return` +${e} +`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+` +`}strong({tokens:e}){return`${this.parser.parseInline(e)}`}em({tokens:e}){return`${this.parser.parseInline(e)}`}codespan({text:e}){return`${M(e,!0)}`}br(e){return`
    `}del({tokens:e}){return`${this.parser.parseInline(e)}`}link({href:e,title:t,tokens:n}){let r=this.parser.parseInline(n),i=Ge(e);if(i===null)return r;e=i;let a=`
    `+r+``,a}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=Ge(e);if(i===null)return M(n);e=i;let a=`${n}`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:M(e.text)}},L=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}},R=class e{options;renderer;textRenderer;constructor(e){this.options=e||f,this.options.renderer=this.options.renderer||new I,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new L}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e,t=!0){let n=``;for(let r=0;r{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new I(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new P(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new z;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];t[r]=z.passThroughHooks.has(n)?e=>{if(this.defaults.async&&z.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return F.lex(e,t??this.defaults)}parser(e,t){return R.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer():e?F.lex:F.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser():e?R.parse:R.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer():e?F.lex:F.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser():e?R.parse:R.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=` +Please report this to https://github.com/markedjs/marked.`,e){let e=`

    An error occurred:

    `+M(n.message+``,!0)+`
    `;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}};function V(e,t){return B.parse(e,t)}V.options=V.setOptions=function(e){return B.setOptions(e),V.defaults=B.defaults,p(V.defaults),V},V.getDefaults=d,V.defaults=f,V.use=function(...e){return B.use(...e),V.defaults=B.defaults,p(V.defaults),V},V.walkTokens=function(e,t){return B.walkTokens(e,t)},V.parseInline=B.parseInline,V.Parser=R,V.parser=R.parse,V.Renderer=I,V.TextRenderer=L,V.Lexer=F,V.lexer=F.lex,V.Tokenizer=P,V.Hooks=z,V.parse=V,V.options,V.setOptions,V.use,V.walkTokens,V.parseInline,R.parse,F.lex;function Xe(e){var t=[...arguments].slice(1),n=Array.from(typeof e==`string`?[e]:e);n[n.length-1]=n[n.length-1].replace(/\r?\n([\t ]*)$/,``);var r=n.reduce(function(e,t){var n=t.match(/\n([\t ]+|(?!\s).)/g);return n?e.concat(n.map(function(e){return e.match(/[\t ]/g)?.length??0})):e},[]);if(r.length){var i=RegExp(` +[ ]{${Math.min.apply(Math,r)}}`,`g`);n=n.map(function(e){return e.replace(i,` +`)})}n[0]=n[0].replace(/^\r?\n/,``);var a=n[0];return t.forEach(function(e,t){var r=a.match(/(?:^|\n)( *)$/),i=r?r[1]:``,o=e;typeof e==`string`&&e.includes(` +`)&&(o=String(e).split(` +`).map(function(e,t){return t===0?e:`${i}${e}`}).join(` +`)),a+=o+n[t+1]}),a}var H=typeof performance<`u`&&typeof performance.now==`function`,U=n(()=>H?performance.now():0,`now`),W=`🧜 `,Ze=`Mermaid render`,Qe=`Mermaid`,$e={parse:`tertiary`,prepare:`secondary`,measure:`primary`,layout:`primary-dark`,layoutCore:`error`,draw:`primary-light`,paint:`secondary-dark`,serialize:`tertiary-dark`,render:`primary-light`};(class{constructor(){this.enabled=!1,this.autoPrint=!0,this.records=[],this.maxRecords=200,this.roots=[],this.stack=[],this.buckets={}}static{n(this,`Profiler`)}enable(){return this.enabled=!0,this}disable(){return this.enabled=!1,this}start(e){this.enabled&&(this.roots=[],this.stack=[],this.buckets={},this.begin(e))}tickSync(e,t){if(!this.enabled)return t();let n=U();try{return t()}finally{this.buckets[e]=(this.buckets[e]??0)+(U()-n)}}async tick(e,t){if(!this.enabled)return t();let n=U();try{return await t()}finally{this.buckets[e]=(this.buckets[e]??0)+(U()-n)}}stop(){if(!this.enabled)return;for(;this.stack.length>0;)this.end();let e=this.roots.at(-1),t=this.runLabel??e?.name;return e&&(this.records.push({label:t??e.name,tree:e,buckets:{...this.buckets}}),this.records.length>this.maxRecords&&this.records.splice(0,this.records.length-this.maxRecords),this.autoPrint&&this.printSummary(e,t)),this.runLabel=void 0,e}begin(e){if(!this.enabled)return;let t={name:e,start:U(),duration:-1,children:[]},n=this.stack.at(-1);if(n?n.children.push(t):this.roots.push(t),this.stack.push(t),H&&typeof performance.mark==`function`)try{performance.mark(`${W}${e} \u25B6`)}catch{}}end(){if(!this.enabled)return;let e=this.stack.pop();if(!e)return;let t=U();if(e.duration=t-e.start,H&&typeof performance.measure==`function`)try{performance.measure(`${W}${e.name}`,{start:e.start,end:t,detail:{devtools:{dataType:`track-entry`,track:Ze,trackGroup:Qe,color:$e[e.name]??`primary`,tooltipText:`${e.name} \u2014 ${e.duration.toFixed(1)} ms`}}})}catch{}}async span(e,t){if(!this.enabled)return t();this.begin(e);try{return await t()}finally{this.end()}}report(){return this.records.at(-1)?.tree??this.roots.at(-1)}clear(){this.records.length=0,this.roots=[],this.stack=[],this.runLabel=void 0}reset(){this.roots=[],this.stack=[]}printSummary(e=this.report(),t){if(!e)return;let r=e.duration,i=t&&t!==e.name?`${e.name} [${t}]`:e.name,a=[`ms % phase`],o=n((e,t)=>{let n=` `.repeat(t),i=e.duration.toFixed(1).padStart(8),s=r>0?`${(e.duration/r*100).toFixed(0).padStart(3)}%`:` -`;a.push(`${i} ${s} ${n}${e.name}`);for(let n of e.children)o(n,t+1);if(e.children.length>0){let t=e.children.reduce((e,t)=>e+t.duration,0),r=e.duration-t;if(r>.5){let e=r.toFixed(1).padStart(8);a.push(`${e} ${n} (self)`)}}},`walk`);o(e,0);let s=Object.keys(this.buckets);if(s.length>0){a.push(`—— buckets (summed) ——`);for(let e of s)a.push(`${this.buckets[e].toFixed(1).padStart(8)} ${e}`)}console.log(`${W}mermaid render profile \xB7 ${i} +${a.join(` +`)}`)}}),globalThis.injected??={includeLargeFeatures:!0,profiling:!1,version:`0.0.0`};function et(e,{markdownAutoWrap:t}){return Xe(e.replace(//g,` +`).replace(/\n{2,}/g,` +`))}n(et,`preprocessMarkdown`);function tt(e){return e.split(/\\n|\n|/gi).map(e=>e.trim().match(/<[^>]+>|[^\s<>]+/g)?.map(e=>({content:e,type:`normal`}))??[])}n(tt,`nonMarkdownToLines`);function G(e,t={}){let r=et(e,t),i=V.lexer(r),a=[[]],o=0;function s(e,t=`normal`){e.type===`text`?e.text.split(` +`).forEach((e,n)=>{n!==0&&(o++,a.push([])),e.split(` `).forEach(e=>{e=e.replace(/'/g,`'`),e&&a[o].push({content:e,type:t})})}):e.type===`strong`||e.type===`em`?e.tokens.forEach(t=>{s(t,e.type)}):e.type===`html`&&a[o].push({content:e.text,type:`normal`})}return n(s,`processNode`),i.forEach(e=>{e.type===`paragraph`?e.tokens?.forEach(e=>{s(e)}):e.type===`html`?a[o].push({content:e.text,type:`normal`}):a[o].push({content:e.raw,type:`normal`})}),a}n(G,`markdownToLines`);function nt(e){return e?`

    ${e.replace(/\\n|\n/g,`
    `)}

    `:``}n(nt,`nonMarkdownToHTML`);function rt(t,{markdownAutoWrap:r}={}){let i=V.lexer(t);function a(t){return t.type===`text`?r===!1?t.text.replace(/\n */g,`
    `).replace(/ /g,` `):t.text.replace(/\n */g,`
    `):t.type===`strong`?`${t.tokens?.map(a).join(``)}`:t.type===`em`?`${t.tokens?.map(a).join(``)}`:t.type===`paragraph`?`

    ${t.tokens?.map(a).join(``)}

    `:t.type===`space`?``:t.type===`html`?`${t.text}`:t.type===`escape`?t.text:(e.warn(`Unsupported markdown: ${t.type}`),t.raw)}return n(a,`output`),i.map(a).join(``)}n(rt,`markdownToHTML`);var it=(function(e){var t=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.msRequestAnimationFrame||function(e){return setTimeout(e,16)};function r(){var n=this;n.reads=[],n.writes=[],n.raf=t.bind(e)}n(r,`FastDom`),r.prototype={constructor:r,runTasks:n(function(e){for(var t;t=e.shift();)t()},`runTasks`),measure:n(function(e,t){var n=t?e.bind(t):e;return this.reads.push(n),i(this),n},`measure`),mutate:n(function(e,t){var n=t?e.bind(t):e;return this.writes.push(n),i(this),n},`mutate`),clear:n(function(e){return o(this.reads,e)||o(this.writes,e)},`clear`),extend:n(function(e){if(typeof e!=`object`)throw Error(`expected object`);var t=Object.create(this);return s(t,e),t.fastdom=this,t.initialize&&t.initialize(),t},`extend`),catch:null};function i(e){e.scheduled||(e.scheduled=!0,e.raf(a.bind(null,e)))}n(i,`scheduleFlush`);function a(e){var t=e.writes,n=e.reads,r;try{n.length,e.runTasks(n),t.length,e.runTasks(t)}catch(e){r=e}if(e.scheduled=!1,(n.length||t.length)&&i(e),r){if(r.message,e.catch)e.catch(r);else throw r}}n(a,`flush`);function o(e,t){var n=e.indexOf(t);return!!~n&&!!e.splice(n,1)}n(o,`remove`);function s(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])}return n(s,`mixin`),e.fastdom=e.fastdom||new r})(typeof window<`u`?window:globalThis),at={initialize:n(function(){this._tasks=new Map},`initialize`),mutate:n(function(e,t){return K(this,`mutate`,e,t)},`mutate`),measure:n(function(e,t){return K(this,`measure`,e,t)},`measure`),clear:n(function(e){var t=this._tasks,n=t.get(e);this.fastdom.clear(n),t.delete(e)},`clear`)};function K(e,t,n,r){var i=e._tasks,a=e.fastdom,o,s=new Promise(function(e,c){o=a[t](function(){i.delete(s);try{e(r?n.call(r):n())}catch(e){c(e)}},r)});return i.set(s,o),s}n(K,`create`);var{initialize:ot,mutate:st,measure:ct,clear:lt}=at,ut=at,dt=it.extend({raf(e){typeof queueMicrotask==`function`?queueMicrotask(e):setTimeout(e,0)}}).extend(ut);function ft(e){return Intl.Segmenter?[...new Intl.Segmenter().segment(e)].map(e=>e.segment):[...e]}n(ft,`splitTextToChars`);function pt(e,t){return q(e,[],ft(t.content),t.type)}n(pt,`splitWordToFitWidth`);function q(e,t,n,r){if(n.length===0)return[{content:t.join(``),type:r},{content:``,type:r}];let[i,...a]=n,o=[...t,i];return e([{content:o.join(``),type:r}])?q(e,o,a,r):(t.length===0&&i&&(t.push(i),n.shift()),[{content:t.join(``),type:r},{content:n.join(``),type:r}])}n(q,`splitWordToFitWidthRecursion`);function mt(e,t){if(e.some(({content:e})=>e.includes(` +`)))throw Error(`splitLineToFitWidth does not support newlines in the line`);return J(e,t)}n(mt,`splitLineToFitWidth`);function J(e,t,n=[],r=[]){if(e.length===0)return r.length>0&&n.push(r),n.length>0?n:[];let i=``;e[0].content===` `&&(i=` `,e.shift());let a=e.shift()??{content:` `,type:`normal`},o=[...r];if(i!==``&&o.push({content:i,type:`normal`}),o.push(a),t(o))return J(e,t,n,o);if(r.length>0)n.push(r),e.unshift(a);else if(a.content){let[r,i]=pt(t,a);n.push([r]),i.content&&e.unshift(i)}return J(e,t,n)}n(J,`splitLineToFitWidthRecursion`);function Y(e,t){t&&e.attr(`style`,t)}n(Y,`applyStyle`);var ht=16384;async function X(e,t,n,c,l=!1,u=a(),d=0){let f=e.append(`foreignObject`);f.attr(`width`,`${Math.min(10*n,ht)}px`),f.attr(`height`,`${Math.min(10*n,ht)}px`);let p=f.append(`xhtml:div`),m=r(t.label)?await i(t.label.replace(o.lineBreakRegex,` +`),u):s(t.label,u),h=t.isNode?`nodeLabel`:`edgeLabel`,g=p.append(`span`);g.html(m),Y(g,t.labelStyle),g.attr(`class`,`${h} ${c}`),Y(p,t.labelStyle),p.style(`display`,`table-cell`),p.style(`white-space`,`nowrap`),p.style(`line-height`,`1.5`),n!==1/0&&(p.style(`max-width`,n+`px`),p.style(`text-align`,`center`)),p.attr(`xmlns`,`http://www.w3.org/1999/xhtml`),l&&p.attr(`class`,`labelBkg`);let _=await dt.measure(()=>p.node().getBoundingClientRect());return _.width===n?(p.style(`display`,`table`),p.style(`white-space`,`break-spaces`),p.style(`width`,n+`px`)):_.widthgt(s,o,t)<=e,`checkWidth`),i=r(t)?[t]:mt(t,r);for(let e of i)$(Z(l,u,o,a),e),u++}if(i){let e=l.node().getBBox();return c.attr(`x`,e.x-2).attr(`y`,e.y-2).attr(`width`,e.width+4).attr(`height`,e.height+4),s.node()}return l.node()}n(vt,`createFormattedText`);function Q(e){return e.replace(/&(amp|lt|gt);/g,(e,t)=>{switch(t){case`amp`:return`&`;case`lt`:return`<`;case`gt`:return`>`;default:return e}})}n(Q,`decodeHTMLEntities`);function $(e,t){e.text(``),t.forEach((t,n)=>{let r=e.append(`tspan`).attr(`font-style`,t.type===`em`?`italic`:`normal`).attr(`class`,`text-inner-tspan`).attr(`font-weight`,t.type===`strong`?`bold`:`normal`);n===0?r.text(Q(t.content)):r.text(` `+Q(t.content))})}n($,`updateTextContentAndStyles`);async function yt(e,t={}){let n=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(e,r,i)=>(n.push((async()=>{let n=`${r}:${i}`;return await l(n)?await u(n,void 0,{class:`label-icon`}):``})()),e));let r=await Promise.all(n);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>r.shift()??``)}n(yt,`replaceIconSubstring`);var bt=n(async(n,i=``,{style:a=``,isTitle:o=!1,classes:s=``,useHtmlLabels:l=!0,markdown:u=!0,isNode:d=!0,width:f=200,minWidth:p=0,addSvgBackground:m=!1}={},h)=>{if(e.debug(`XYZ createText`,i,a,o,s,l,d,`addSvgBackground: `,m),l){let e=u?rt(i,h):nt(i),t=await yt(c(e),h),o=i.replace(/\\\\/g,`\\`);return await X(n,{isNode:d,label:r(i)?o:t,labelStyle:a.replace(`fill:`,`color:`)},f,s,m,h,p)}{let e=c(i.replace(//g,`
    `)),r=vt(f,n,u?G(e.replace(`
    `,`
    `),h):tt(e),i?m:!1,!d);if(d){/stroke:/.exec(a)&&(a=a.replace(`stroke:`,`lineColor:`));let e=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/color:/g,`fill:`);t(r).attr(`style`,e)}else{let e=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/background:/g,`fill:`);t(r).select(`rect`).attr(`style`,e.replace(/background:/g,`fill:`));let n=a.replace(/stroke:[^;]+;?/g,``).replace(/stroke-width:[^;]+;?/g,``).replace(/fill:[^;]+;?/g,``).replace(/color:/g,`fill:`);t(r).select(`text`).attr(`style`,n)}return o?t(r).selectAll(`tspan.text-outer-tspan`).classed(`title-row`,!0):t(r).selectAll(`tspan.text-outer-tspan`).classed(`row`,!0),r}},`createText`);export{Xe as a,G as i,bt as n,dt as r,_t as t}; \ No newline at end of file diff --git a/www/assets/chunk-NETBCI7D-Br7cqgBT.js b/www/assets/chunk-NETBCI7D-Br7cqgBT.js new file mode 100644 index 0000000..9960acf --- /dev/null +++ b/www/assets/chunk-NETBCI7D-Br7cqgBT.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as t}from"./index-DoQkmpth.js";var n=5,r=1e-5,i=2,a=.6,o=1e-6;function s(e){let t=[];for(let n=0;n=1-o||p<=o||p>=1-o?null:{point:{x:e.x+f*i,y:e.y+f*a},tA:f,tB:p}}e(c,`segmentIntersection`);function l(e){return Math.abs(e.b.x-e.a.x)>=Math.abs(e.b.y-e.a.y)}e(l,`isHorizontalSeg`);function u(e,t,r){if(e.curve!==`rounded`)return!1;let i=e.points,a=i[t],o=i[t+1];if(!a||!o)return!1;let s=Math.hypot(o.x-a.x,o.y-a.y),c=r*s,l=t>0?_(i[t-1],a,o,n):null;if(l&&c=Math.abs(n)?+(t>=0):+(n>=0)}e(m,`getArcSweepFlag`);function h(e,n){if(e.length<2)return e.map(e=>({...e}));let r=e.map(e=>({...e})),i=n.arrowTypeStart&&t[n.arrowTypeStart];if(i){let t=e[0],n=e[1],a=Math.atan2(n.y-t.y,n.x-t.x);r[0].x=t.x+i*Math.cos(a),r[0].y=t.y+i*Math.sin(a)}let a=n.arrowTypeEnd&&t[n.arrowTypeEnd];if(a){let t=e.length,n=e[t-2],i=e[t-1],o=Math.atan2(i.y-n.y,i.x-n.x);r[t-1].x=i.x-a*Math.cos(o),r[t-1].y=i.y-a*Math.sin(o)}return r}e(h,`applyMarkerOffsets`);function g(e,t,n,r,i){let a=e.point.x,o=e.point.y,s={x:a-t*e.r,y:o-n*e.r},c={x:a+t*e.r,y:o+n*e.r},l=[`L${p(s)}`];return i===`arc`?l.push(`A${f(e.r)},${f(e.r)} 0 0 ${r} ${p(c)}`):l.push(`M${p(c)}`),l}e(g,`emitJump`);function _(e,t,n,i){let a=t.x-e.x,o=t.y-e.y,s=n.x-t.x,c=n.y-t.y,l=Math.hypot(a,o),u=Math.hypot(s,c);if(l0){let t=_(c[e-1],c[e],c[e+1]??c[e],n);t&&(b=t.cutLen)}let x=o,S=null;l&&ee.t-t.t).filter(e=>{let t=Math.min(e.d-b,x-e.d)-i;return e.r=Math.min(e.r,t),e.r>=C});for(let e=0;et){let n=t/2;w[e].r=Math.min(w[e].r,n),w[e+1].r=Math.min(w[e+1].r,n)}}for(let e of w)e.r=2?r:null}catch{return null}}e(x,`decodeDataPoints`);function S(e,t,n){if(!n.enabled)return;let r=e.node();if(!r)return;let i=new Map;for(let e of t)i.set(e.id,e);let a=new Map;for(let e of r.querySelectorAll(`path[data-id]`)){let t=e.getAttribute(`data-id`);t!==null&&!a.has(t)&&a.set(t,e)}let o=[];for(let e of t){let t=a.get(e.id);if(!t)continue;let n=x(t.getAttribute(`data-points`))??e.points;o.push({...e,points:n})}let s=d(o);if(s.length===0)return;let c=new Map;for(let e of s){let t=c.get(e.jumpEdgeId)??[];t.push(e),c.set(e.jumpEdgeId,t)}for(let e of o){let t=c.get(e.id);if(!t||t.length===0)continue;let r=i.get(e.id)?.curve;if(r!==void 0&&!b(r))continue;let o=a.get(e.id);if(!o||r===void 0&&!y(o.getAttribute(`d`)??``))continue;let s=o.getAttribute(`style`)??``,l=/stroke-dasharray\s*:\s*0\s+([\d.]+)\s+[\d.]+\s+([\d.]+)/.exec(s),u=l?Number.parseFloat(l[1]):null,d=l?Number.parseFloat(l[2]):null,f=v(e,t,n);if(o.setAttribute(`d`,f),u!==null&&d!==null&&typeof o.getTotalLength==`function`){let e=o.getTotalLength(),t=`0 ${u} ${Math.max(0,e-u-d)} ${d}`,n=s.replace(/stroke-dasharray\s*:[^;]*;?/g,`stroke-dasharray: ${t};`).replace(/;\s*;+/g,`;`);o.setAttribute(`style`,n)}}}e(S,`applyLineJumpsToSvg`);export{S as t}; \ No newline at end of file diff --git a/www/assets/chunk-O7XYJQB3-Bce2lzyF.js b/www/assets/chunk-O7XYJQB3-Bce2lzyF.js new file mode 100644 index 0000000..5a69edf --- /dev/null +++ b/www/assets/chunk-O7XYJQB3-Bce2lzyF.js @@ -0,0 +1,128 @@ +import{h as e,m as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var i={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{let t=e/255;return e>.03928?((t+.055)/1.055)**2.4:t/12.92},hue2rgb:(e,t,n)=>(n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e),hsl2rgb:({h:e,s:t,l:n},r)=>{if(!t)return n*2.55;e/=360,t/=100,n/=100;let a=n<.5?n*(1+t):n+t-n*t,o=2*n-a;switch(r){case`r`:return i.hue2rgb(o,a,e+1/3)*255;case`g`:return i.hue2rgb(o,a,e)*255;case`b`:return i.hue2rgb(o,a,e-1/3)*255}},rgb2hsl:({r:e,g:t,b:n},r)=>{e/=255,t/=255,n/=255;let i=Math.max(e,t,n),a=Math.min(e,t,n),o=(i+a)/2;if(r===`l`)return o*100;if(i===a)return 0;let s=i-a,c=o>.5?s/(2-i-a):s/(i+a);if(r===`s`)return c*100;switch(i){case e:return((t-n)/s+(tt>n?Math.min(t,Math.max(n,e)):Math.min(n,Math.max(t,e)),round:e=>Math.round(e*1e10)/1e10},unit:{dec2hex:e=>{let t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}}},o={};for(let e=0;e<=255;e++)o[e]=a.unit.dec2hex(e);var s={ALL:0,RGB:1,HSL:2},c=class{constructor(){this.type=s.ALL}get(){return this.type}set(e){if(this.type&&this.type!==e)throw Error(`Cannot change both RGB and HSL channels at the same time`);this.type=e}reset(){this.type=s.ALL}is(e){return this.type===e}},l=new class{constructor(e,t){this.color=t,this.changed=!1,this.data=e,this.type=new c}set(e,t){return this.color=t,this.changed=!1,this.data=e,this.type.type=s.ALL,this}_ensureHSL(){let e=this.data,{h:t,s:n,l:r}=e;t===void 0&&(e.h=a.channel.rgb2hsl(e,`h`)),n===void 0&&(e.s=a.channel.rgb2hsl(e,`s`)),r===void 0&&(e.l=a.channel.rgb2hsl(e,`l`))}_ensureRGB(){let e=this.data,{r:t,g:n,b:r}=e;t===void 0&&(e.r=a.channel.hsl2rgb(e,`r`)),n===void 0&&(e.g=a.channel.hsl2rgb(e,`g`)),r===void 0&&(e.b=a.channel.hsl2rgb(e,`b`))}get r(){let e=this.data,t=e.r;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`r`))}get g(){let e=this.data,t=e.g;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`g`))}get b(){let e=this.data,t=e.b;return!this.type.is(s.HSL)&&t!==void 0?t:(this._ensureHSL(),a.channel.hsl2rgb(e,`b`))}get h(){let e=this.data,t=e.h;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`h`))}get s(){let e=this.data,t=e.s;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`s`))}get l(){let e=this.data,t=e.l;return!this.type.is(s.RGB)&&t!==void 0?t:(this._ensureRGB(),a.channel.rgb2hsl(e,`l`))}get a(){return this.data.a}set r(e){this.type.set(s.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(s.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(s.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(s.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(s.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(s.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}({r:0,g:0,b:0,a:0},`transparent`),u={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(e.charCodeAt(0)!==35)return;let t=e.match(u.re);if(!t)return;let n=t[1],r=parseInt(n,16),i=n.length,a=i%4==0,o=i>4,s=o?1:17,c=o?8:4,d=a?0:-1,f=o?255:15;return l.set({r:(r>>c*(d+3)&f)*s,g:(r>>c*(d+2)&f)*s,b:(r>>c*(d+1)&f)*s,a:a?(r&f)*s/255:1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`#${o[Math.round(t)]}${o[Math.round(n)]}${o[Math.round(r)]}${o[Math.round(i*255)]}`:`#${o[Math.round(t)]}${o[Math.round(n)]}${o[Math.round(r)]}`}},d={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{let t=e.match(d.hueRe);if(t){let[,e,n]=t;switch(n){case`grad`:return a.channel.clamp.h(parseFloat(e)*.9);case`rad`:return a.channel.clamp.h(parseFloat(e)*180/Math.PI);case`turn`:return a.channel.clamp.h(parseFloat(e)*360)}}return a.channel.clamp.h(parseFloat(e))},parse:e=>{let t=e.charCodeAt(0);if(t!==104&&t!==72)return;let n=e.match(d.re);if(!n)return;let[,r,i,o,s,c]=n;return l.set({h:d._hue2deg(r),s:a.channel.clamp.s(parseFloat(i)),l:a.channel.clamp.l(parseFloat(o)),a:s?a.channel.clamp.a(c?parseFloat(s)/100:parseFloat(s)):1},e)},stringify:e=>{let{h:t,s:n,l:r,a:i}=e;return i<1?`hsla(${a.lang.round(t)}, ${a.lang.round(n)}%, ${a.lang.round(r)}%, ${i})`:`hsl(${a.lang.round(t)}, ${a.lang.round(n)}%, ${a.lang.round(r)}%)`}},f={colors:{aliceblue:`#f0f8ff`,antiquewhite:`#faebd7`,aqua:`#00ffff`,aquamarine:`#7fffd4`,azure:`#f0ffff`,beige:`#f5f5dc`,bisque:`#ffe4c4`,black:`#000000`,blanchedalmond:`#ffebcd`,blue:`#0000ff`,blueviolet:`#8a2be2`,brown:`#a52a2a`,burlywood:`#deb887`,cadetblue:`#5f9ea0`,chartreuse:`#7fff00`,chocolate:`#d2691e`,coral:`#ff7f50`,cornflowerblue:`#6495ed`,cornsilk:`#fff8dc`,crimson:`#dc143c`,cyanaqua:`#00ffff`,darkblue:`#00008b`,darkcyan:`#008b8b`,darkgoldenrod:`#b8860b`,darkgray:`#a9a9a9`,darkgreen:`#006400`,darkgrey:`#a9a9a9`,darkkhaki:`#bdb76b`,darkmagenta:`#8b008b`,darkolivegreen:`#556b2f`,darkorange:`#ff8c00`,darkorchid:`#9932cc`,darkred:`#8b0000`,darksalmon:`#e9967a`,darkseagreen:`#8fbc8f`,darkslateblue:`#483d8b`,darkslategray:`#2f4f4f`,darkslategrey:`#2f4f4f`,darkturquoise:`#00ced1`,darkviolet:`#9400d3`,deeppink:`#ff1493`,deepskyblue:`#00bfff`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1e90ff`,firebrick:`#b22222`,floralwhite:`#fffaf0`,forestgreen:`#228b22`,fuchsia:`#ff00ff`,gainsboro:`#dcdcdc`,ghostwhite:`#f8f8ff`,gold:`#ffd700`,goldenrod:`#daa520`,gray:`#808080`,green:`#008000`,greenyellow:`#adff2f`,grey:`#808080`,honeydew:`#f0fff0`,hotpink:`#ff69b4`,indianred:`#cd5c5c`,indigo:`#4b0082`,ivory:`#fffff0`,khaki:`#f0e68c`,lavender:`#e6e6fa`,lavenderblush:`#fff0f5`,lawngreen:`#7cfc00`,lemonchiffon:`#fffacd`,lightblue:`#add8e6`,lightcoral:`#f08080`,lightcyan:`#e0ffff`,lightgoldenrodyellow:`#fafad2`,lightgray:`#d3d3d3`,lightgreen:`#90ee90`,lightgrey:`#d3d3d3`,lightpink:`#ffb6c1`,lightsalmon:`#ffa07a`,lightseagreen:`#20b2aa`,lightskyblue:`#87cefa`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#b0c4de`,lightyellow:`#ffffe0`,lime:`#00ff00`,limegreen:`#32cd32`,linen:`#faf0e6`,magenta:`#ff00ff`,maroon:`#800000`,mediumaquamarine:`#66cdaa`,mediumblue:`#0000cd`,mediumorchid:`#ba55d3`,mediumpurple:`#9370db`,mediumseagreen:`#3cb371`,mediumslateblue:`#7b68ee`,mediumspringgreen:`#00fa9a`,mediumturquoise:`#48d1cc`,mediumvioletred:`#c71585`,midnightblue:`#191970`,mintcream:`#f5fffa`,mistyrose:`#ffe4e1`,moccasin:`#ffe4b5`,navajowhite:`#ffdead`,navy:`#000080`,oldlace:`#fdf5e6`,olive:`#808000`,olivedrab:`#6b8e23`,orange:`#ffa500`,orangered:`#ff4500`,orchid:`#da70d6`,palegoldenrod:`#eee8aa`,palegreen:`#98fb98`,paleturquoise:`#afeeee`,palevioletred:`#db7093`,papayawhip:`#ffefd5`,peachpuff:`#ffdab9`,peru:`#cd853f`,pink:`#ffc0cb`,plum:`#dda0dd`,powderblue:`#b0e0e6`,purple:`#800080`,rebeccapurple:`#663399`,red:`#ff0000`,rosybrown:`#bc8f8f`,royalblue:`#4169e1`,saddlebrown:`#8b4513`,salmon:`#fa8072`,sandybrown:`#f4a460`,seagreen:`#2e8b57`,seashell:`#fff5ee`,sienna:`#a0522d`,silver:`#c0c0c0`,skyblue:`#87ceeb`,slateblue:`#6a5acd`,slategray:`#708090`,slategrey:`#708090`,snow:`#fffafa`,springgreen:`#00ff7f`,tan:`#d2b48c`,teal:`#008080`,thistle:`#d8bfd8`,transparent:`#00000000`,turquoise:`#40e0d0`,violet:`#ee82ee`,wheat:`#f5deb3`,white:`#ffffff`,whitesmoke:`#f5f5f5`,yellow:`#ffff00`,yellowgreen:`#9acd32`},parse:e=>{e=e.toLowerCase();let t=f.colors[e];if(t)return u.parse(t)},stringify:e=>{let t=u.stringify(e);for(let e in f.colors)if(f.colors[e]===t)return e}},p={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{let t=e.charCodeAt(0);if(t!==114&&t!==82)return;let n=e.match(p.re);if(!n)return;let[,r,i,o,s,c,u,d,f]=n;return l.set({r:a.channel.clamp.r(i?parseFloat(r)*2.55:parseFloat(r)),g:a.channel.clamp.g(s?parseFloat(o)*2.55:parseFloat(o)),b:a.channel.clamp.b(u?parseFloat(c)*2.55:parseFloat(c)),a:d?a.channel.clamp.a(f?parseFloat(d)/100:parseFloat(d)):1},e)},stringify:e=>{let{r:t,g:n,b:r,a:i}=e;return i<1?`rgba(${a.lang.round(t)}, ${a.lang.round(n)}, ${a.lang.round(r)}, ${a.lang.round(i)})`:`rgb(${a.lang.round(t)}, ${a.lang.round(n)}, ${a.lang.round(r)})`}},m={format:{keyword:f,hex:u,rgb:p,rgba:p,hsl:d,hsla:d},parse:e=>{if(typeof e!=`string`)return e;let t=u.parse(e)||p.parse(e)||d.parse(e)||f.parse(e);if(t)return t;throw Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(s.HSL)||e.data.r===void 0?d.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?p.stringify(e):u.stringify(e)},ee=(e,t)=>{let n=m.parse(e);for(let e in t)n[e]=a.channel.clamp[e](t[e]);return m.stringify(n)},h=(e,t,n=0,r=1)=>{if(typeof e!=`number`)return ee(e,{a:t});let i=l.set({r:a.channel.clamp.r(e),g:a.channel.clamp.g(t),b:a.channel.clamp.b(n),a:a.channel.clamp.a(r)});return m.stringify(i)},g=e=>{let{r:t,g:n,b:r}=m.parse(e),i=.2126*a.channel.toLinear(t)+.7152*a.channel.toLinear(n)+.0722*a.channel.toLinear(r);return a.lang.round(i)},te=e=>g(e)>=.5,_=e=>!te(e),v=(e,t,n)=>{let r=m.parse(e),i=r[t],o=a.channel.clamp[t](i+n);return i!==o&&(r[t]=o),m.stringify(r)},y=(e,t)=>v(e,`l`,t),b=(e,t)=>v(e,`l`,-t),x=(e,t)=>{let n=m.parse(e),r={};for(let e in t)t[e]&&(r[e]=n[e]+t[e]);return ee(e,r)},ne=(e,t,n=50)=>{let{r,g:i,b:a,a:o}=m.parse(e),{r:s,g:c,b:l,a:u}=m.parse(t),d=n/100,f=d*2-1,p=o-u,ee=((f*p===-1?f:(f+p)/(1+f*p))+1)/2,g=1-ee;return h(r*ee+s*g,i*ee+c*g,a*ee+l*g,o*d+u*(1-d))},S=(e,t=100)=>{let n=m.parse(e);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,ne(n,e,t)};function re(e,t){this.v=e,this.k=t}function ie(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n`u`?null:O(BigInt.prototype.toString),Pe=typeof Symbol>`u`?null:O(Symbol.prototype.toString),E=O(Object.prototype.hasOwnProperty),Fe=O(Object.prototype.toString),D=O(RegExp.prototype.test),Ie=Le(TypeError);function O(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return ve(e,t,n)}}function Le(e){return function(){return T(e,[...arguments])}}function k(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Te;if(fe&&fe(e,null),!we(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(pe(t)||(t[r]=e),i=e)}e[i]=!0}return e}function Re(e){for(let t=0;t/g),et=w(/\${[\w\W]*/g),tt=w(/^data-[\-\w.\u00B7-\uFFFF]+$/),nt=w(/^aria-[\-\w]+$/),rt=w(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),it=w(/^(?:\w+script|data):/i),at=w(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ot=w(/^html$/i),st=w(/^[a-z][.\w]*(-[.\w]+)+$/i),ct=w(/<[/\w!]/g),lt=w(/<[/\w]/g),ut=w(/<\/no(script|embed|frames)/i),dt=w(/\/>/i),M={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},ft=[`style`,`script`,`xmp`,`iframe`,`noembed`,`noframes`,`plaintext`,`noscript`],pt=C(k({},ft)),mt=function(){let e={};return ye(ft,t=>{e[t]=w(RegExp(`])`,`i`))}),C(e)}(),ht=function(){return typeof window>`u`?null:window},gt=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},_t=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},N=function(e,t,n,r){return E(e,t)&&we(e[t])?k(r.base?A(r.base):{},e[t],r.transform):n},vt=function(e,t,n){let r=E(e,t)?e[t]:void 0;return r&&typeof r==`object`?A(r):n()};function yt(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ht(),t=e=>yt(e);if(t.version=`3.4.16`,t.removed=[],!e||!e.document||e.document.nodeType!==M.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=j(d,`cloneNode`),p=j(d,`remove`),m=j(d,`removeAttributeNode`),ee=j(d,`nextSibling`),h=j(d,`childNodes`),g=j(d,`parentNode`),te=j(d,`shadowRoot`),_=j(d,`attributes`),v=o&&o.prototype?j(o.prototype,`nodeType`):null,y=o&&o.prototype?j(o.prototype,`nodeName`):null,b=o&&o.prototype?j(o.prototype,`ownerDocument`):null,x=function(e){return v?v(e):e.nodeType},ne=function(e){return y?y(e):e.nodeName};if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let S,re=``,ie,ae=!1,oe=0,se=function(){if(oe>0)throw Ie(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},ce=function(e){se(),oe++;try{return S.createHTML(e)}finally{oe--}},le=function(e){se(),oe++;try{return S.createScriptURL(e)}finally{oe--}},ue=function(){return ae||=(ie=gt(u,i),!0),ie},fe=n,pe=fe.implementation,me=fe.createNodeIterator,he=fe.createDocumentFragment,_e=fe.getElementsByTagName,ve=r.importNode,T=_t();t.isSupported=typeof de==`function`&&typeof g==`function`&&pe&&pe.createHTMLDocument!==void 0;let je=Qe,Me=$e,Ne=et,Pe=tt,Fe=nt,O=it,Le=at,Re=st,ft=rt,P=null,bt=k({},[...Ve,...He,...Ue,...Ge,...qe]),F=null,xt=k({},[...Je,...Ye,...Xe,...Ze]),I=Object.seal(ge(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),St=null,Ct=null,L=Object.seal(ge(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),wt=!0,Tt=!0,Et=!1,Dt=!0,R=!1,z=!0,B=!1,Ot=!1,V=null,H=null,U=!1,W=!1,kt=!1,At=!1,jt=!0,Mt=!1,Nt=`user-content-`,Pt=!0,Ft=!1,It={},Lt=null,Rt=k({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),zt=null,Bt=k({},[`audio`,`video`,`img`,`source`,`image`,`track`]),Vt=null,Ht=k({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Ut=`http://www.w3.org/1998/Math/MathML`,Wt=`http://www.w3.org/2000/svg`,G=`http://www.w3.org/1999/xhtml`,Gt=G,Kt=!1,qt=null,Jt=k({},[Ut,Wt,G],Ee),K=C([`mi`,`mo`,`mn`,`ms`,`mtext`]),q=k({},K),Yt=C([`annotation-xml`]),Xt=k({},Yt),Zt=k({},[`title`,`style`,`font`,`a`,`script`]),Qt=null,$t=[`application/xhtml+xml`,`text/html`],J=null,en=null,tn=n.createElement(`form`),nn=function(e){return e instanceof RegExp||e instanceof Function},rn=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(en&&en===e)return;(!e||typeof e!=`object`)&&(e={}),e=A(e),Qt=$t.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,J=Qt===`application/xhtml+xml`?Ee:Te,P=N(e,`ALLOWED_TAGS`,bt,{transform:J}),F=N(e,`ALLOWED_ATTR`,xt,{transform:J}),qt=N(e,`ALLOWED_NAMESPACES`,Jt,{transform:Ee}),Vt=N(e,`ADD_URI_SAFE_ATTR`,Ht,{transform:J,base:Ht}),zt=N(e,`ADD_DATA_URI_TAGS`,Bt,{transform:J,base:Bt}),Lt=N(e,`FORBID_CONTENTS`,Rt,{transform:J}),St=N(e,`FORBID_TAGS`,A({}),{transform:J}),Ct=N(e,`FORBID_ATTR`,A({}),{transform:J}),It=E(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?A(e.USE_PROFILES):e.USE_PROFILES:!1,wt=e.ALLOW_ARIA_ATTR!==!1,Tt=e.ALLOW_DATA_ATTR!==!1,Et=e.ALLOW_UNKNOWN_PROTOCOLS||!1,Dt=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,R=e.SAFE_FOR_TEMPLATES||!1,z=e.SAFE_FOR_XML!==!1,B=e.WHOLE_DOCUMENT||!1,W=e.RETURN_DOM||!1,kt=e.RETURN_DOM_FRAGMENT||!1,At=e.RETURN_TRUSTED_TYPE||!1,U=e.FORCE_BODY||!1,jt=e.SANITIZE_DOM!==!1,Mt=e.SANITIZE_NAMED_PROPS||!1,Pt=e.KEEP_CONTENT!==!1,Ft=e.IN_PLACE||!1,ft=Be(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:rt,Gt=typeof e.NAMESPACE==`string`?e.NAMESPACE:G,q=vt(e,`MATHML_TEXT_INTEGRATION_POINTS`,()=>k({},K)),Xt=vt(e,`HTML_INTEGRATION_POINTS`,()=>k({},Yt));let t=vt(e,`CUSTOM_ELEMENT_HANDLING`,()=>ge(null));if(I=ge(null),E(t,`tagNameCheck`)&&nn(t.tagNameCheck)&&(I.tagNameCheck=t.tagNameCheck),E(t,`attributeNameCheck`)&&nn(t.attributeNameCheck)&&(I.attributeNameCheck=t.attributeNameCheck),E(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(I.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),w(I),R&&(Tt=!1),kt&&(W=!0),It&&(P=k({},qe),F=ge(null),It.html===!0&&(k(P,Ve),k(F,Je)),It.svg===!0&&(k(P,He),k(F,Ye),k(F,Ze)),It.svgFilters===!0&&(k(P,Ue),k(F,Ye),k(F,Ze)),It.mathMl===!0&&(k(P,Ge),k(F,Xe),k(F,Ze))),L.tagCheck=null,L.attributeCheck=null,E(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?L.tagCheck=e.ADD_TAGS:we(e.ADD_TAGS)&&(P===bt&&(P=A(P)),k(P,e.ADD_TAGS,J))),E(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?L.attributeCheck=e.ADD_ATTR:we(e.ADD_ATTR)&&(F===xt&&(F=A(F)),k(F,e.ADD_ATTR,J))),E(e,`ADD_FORBID_CONTENTS`)&&we(e.ADD_FORBID_CONTENTS)&&(Lt===Rt&&(Lt=A(Lt)),k(Lt,e.ADD_FORBID_CONTENTS,J)),Pt&&(P[`#text`]=!0),B&&k(P,[`html`,`head`,`body`]),P.table&&(k(P,[`tbody`]),delete St.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw Ie(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw Ie(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=S;S=e.TRUSTED_TYPES_POLICY;try{re=ce(``)}catch(e){throw S=t,e}}else e.TRUSTED_TYPES_POLICY===null?(S=void 0,re=``):(S===void 0&&(S=ue()),S&&typeof re==`string`&&(re=ce(``)));C&&C(e),en=e},an=k({},[...He,...Ue,...We]),on=k({},[...Ge,...Ke]),sn=function(e,t,n){return t.namespaceURI===G?e===`svg`:t.namespaceURI===Ut?e===`svg`&&(n===`annotation-xml`||q[n]):!!an[e]},cn=function(e,t,n){return t.namespaceURI===G?e===`math`:t.namespaceURI===Wt?e===`math`&&Xt[n]:!!on[e]},ln=function(e,t,n){return t.namespaceURI===Wt&&!Xt[n]||t.namespaceURI===Ut&&!q[n]?!1:!on[e]&&(Zt[e]||!an[e])},un=function(e){let t=g(e);(!t||!t.tagName)&&(t={namespaceURI:Gt,tagName:`template`});let n=Te(e.tagName),r=Te(t.tagName);return qt[e.namespaceURI]?e.namespaceURI===Wt?sn(n,t,r):e.namespaceURI===Ut?cn(n,t,r):e.namespaceURI===G?ln(n,t,r):!!(Qt===`application/xhtml+xml`&&qt[e.namespaceURI]):!1},Y=function(e){Se(t.removed,{element:e});try{g(e).removeChild(e)}catch{if(p(e),!g(e))throw Ie(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},dn=function(e,t,n){try{m(e,t)}catch{try{e.removeAttribute(n)}catch{}}},fn=function(e){Z(e);let t=h(e);if(t){let e=[];ye(t,t=>{Se(e,t)}),ye(e,e=>{try{p(e)}catch{}})}let n=_(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;typeof i==`string`&&dn(e,r,i)}},X=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch{r=null}Se(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch{try{n.removeAttribute(e)}catch{}}if(e===`is`){if(W||kt)try{Y(n)}catch{}else try{n.setAttribute(e,``)}catch{}}},pn=function(e){let t=_(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;typeof i!=`string`||F[J(i)]||dn(e,r,i)}},Z=function(e){let t=[e];for(;t.length>0;){let e=t.pop();x(e)===M.element&&pn(e);let n=h(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},mn=function(e,t){return z?e===`patchsrc`||e===`for`&&t!==`label`&&t!==`output`:!1},hn=function(e){if(!z)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=x(e);if(n===M.processingInstruction||n===M.comment&&D(lt,e.data)){try{p(e)}catch{}continue}if(n===M.element){let t=e,n=J(ne(e));try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&mn(`for`,n)&&t.removeAttribute(`for`)}catch{}}let r=h(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},gn=function(e){let t=null,r=null;if(U)e=``+e;else{let t=De(e,/^[\r\n\t ]+/);r=t&&t[0]}Qt===`application/xhtml+xml`&&Gt===G&&(e=``+e+``);let i=S?ce(e):e;if(Gt===G)try{t=new l().parseFromString(i,Qt)}catch{}if(!t||!t.documentElement){t=pe.createDocument(Gt,`template`,null);try{t.documentElement.innerHTML=Kt?re:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),Gt===G?_e.call(t,B?`html`:`body`)[0]:B?t.documentElement:a},_n=function(e){let t=b?b(e):e.ownerDocument;return me.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},vn=function(e){return e=Oe(e,je,` `),e=Oe(e,Me,` `),e=Oe(e,Ne,` `),e},yn=function(e){e.normalize();let t=b?b(e):e.ownerDocument,n=me.call(t||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),r=n.nextNode();for(;r;)r.data=vn(r.data),r=n.nextNode();let i=e.querySelectorAll?.call(e,`template`);i&&ye(i,e=>{xn(e.content)&&yn(e.content)})},bn=function(e){let t=y?y(e):null;return typeof t!=`string`||J(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==_(e)||typeof e.removeAttribute!=`function`||typeof e.removeAttributeNode!=`function`||typeof e.getAttributeNode!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==v(e)||e.childNodes!==h(e)},xn=function(e){if(!v||typeof e!=`object`||!e)return!1;try{return v(e)===M.documentFragment}catch{return!1}},Q=function(e){if(!v||typeof e!=`object`||!e)return!1;try{return typeof v(e)==`number`}catch{return!1}};function $(e,n,r){e.length!==0&&ye(e,e=>{e.call(t,n,r,en)})}let Sn=function(e,t){return!!(z&&e.hasChildNodes()&&!Q(e.firstElementChild)&&D(ct,e.textContent)&&D(ct,e.innerHTML)||z&&e.namespaceURI===G&&pt[t]&&(Q(e.firstElementChild)||typeof e.textContent==`string`&&D(mt[t],e.textContent))||e.nodeType===M.processingInstruction||z&&e.nodeType===M.comment&&D(lt,e.data))},Cn=function(e,t){return e instanceof RegExp?D(e,t):e instanceof Function&&!!e(t,...[...arguments].slice(2))},wn=function(e,t,n){if(!St[t]&&An(t)&&Cn(I.tagNameCheck,t))return!1;if(Pt&&!Lt[t]){let t=g(e),r=h(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,ee(e))}}}return Y(e),!0},Tn=function(e,t,n,r){return e.length===0?t:t===n||t===r?A(t):t},En=function(e,t){return e===t||g(e)!==null?!1:(Ft&&Z(e),!0)},Dn=function(e,n){if($(T.beforeSanitizeElements,e,null),En(e,n))return!0;if(bn(e))return Y(e),!0;let r=J(ne(e));if(P=Tn(T.uponSanitizeElement,P,bt,V),$(T.uponSanitizeElement,e,{tagName:r,allowedTags:P}),En(e,n))return!0;if(Sn(e,r))return Y(e),!0;if(St[r]||!(L.tagCheck instanceof Function&&L.tagCheck(r))&&!P[r]){let t=wn(e,r,n);return t===!1&&($(T.afterSanitizeElements,e,null),En(e,n))?!0:t}if(x(e)===M.element&&!un(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&D(ut,e.innerHTML))return Y(e),!0;if(R&&e.nodeType===M.text){let n=vn(e.textContent);e.textContent!==n&&(Se(t.removed,{element:e.cloneNode()}),e.textContent=n)}return $(T.afterSanitizeElements,e,null),En(e,n)},On=function(e,t,r){if(Ct[t]||mn(t,e)||jt&&(t===`id`||t===`name`)&&(r in n||r in tn))return!1;let i=F[t]||L.attributeCheck instanceof Function&&L.attributeCheck(t,e);return Tt&&D(Pe,t)||wt&&D(Fe,t)?!0:i?Vt[t]||D(ft,Oe(r,Le,``))||(t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&ke(r,`data:`)===0&&zt[e]||Et&&!D(O,Oe(r,Le,``))?!0:!r:An(e)&&Cn(I.tagNameCheck,e)&&Cn(I.attributeNameCheck,t,e)||t===`is`&&I.allowCustomizedBuiltInElements&&Cn(I.tagNameCheck,r)},kn=k({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),An=function(e){return!kn[Te(e)]&&D(Re,e)},jn=function(e,t,n,r){if(S&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return ce(r);case`TrustedScriptURL`:return le(r)}return r},Mn=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!bn(e)||(Y(e),!1)}catch{return X(t,e),!1}},Nn=function(e,n){if($(T.beforeSanitizeAttributes,e,null),En(e,n))return;let r=e.attributes;if(!r||bn(e))return;F=Tn(T.uponSanitizeAttribute,F,xt,H);let i={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:F,forceKeepAttr:void 0},a=r.length,o=J(e.nodeName);for(;a--;){let n=r[a],s=n.name,c=n.namespaceURI,l=n.value,u=J(s),d=l,f=s===`value`?d:Ae(d),p=!1;if(i.attrName=u,i.attrValue=f,i.keepAttr=!0,i.forceKeepAttr=void 0,$(T.uponSanitizeAttribute,e,i),f=i.attrValue,Mt&&(u===`id`||u===`name`)&&ke(f,Nt)!==0&&(X(s,e,n),f=Nt+f,p=!0),z&&D(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){X(s,e,n);continue}if(u===`attributename`&&De(f,`href`)){X(s,e,n);continue}if(!i.forceKeepAttr){if(!i.keepAttr){X(s,e,n);continue}if(!Dt&&D(dt,f)){X(s,e,n);continue}if(R&&(f=vn(f)),!On(o,u,f)){X(s,e,n);continue}f=jn(o,u,c,f),f!==d&&Mn(e,s,c,f)&&p&&xe(t.removed)}}$(T.afterSanitizeAttributes,e,null),En(e,n)},Pn=function(e){let t=null,n=_n(e);for($(T.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if($(T.uponSanitizeShadowNode,t,null),Dn(t,e),Nn(t,e),xn(t.content)&&Pn(t.content),x(t)===M.element){let e=te(t);xn(e)&&(Fn(e),Pn(e))}$(T.afterSanitizeShadowDOM,e,null)},Fn=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){Pn(e.shadow);continue}let n=e.node,r=x(n)===M.element,i=h(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=y?y(n):null;if(typeof e==`string`&&J(e)===`template`){let e=n.content;xn(e)&&t.push({node:e,shadow:null})}}if(r){let e=te(n);xn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if(Kt=!e,Kt&&(e=``),typeof e!=`string`&&!Q(e)&&(e=ze(e),typeof e!=`string`))throw Ie(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ot?(P=V,F=H):rn(n),(T.uponSanitizeElement.length>0||T.uponSanitizeAttribute.length>0)&&(P=A(P)),T.uponSanitizeAttribute.length>0&&(F=A(F)),t.removed=[];let c=Ft&&typeof e!=`string`&&Q(e);if(c){hn(e);let t=ne(e);if(typeof t==`string`){let n=J(t);if(!P[n]||St[n])throw fn(e),Ie(`root node is forbidden and cannot be sanitized in-place`)}if(bn(e))throw fn(e),Ie(`root node is clobbered and cannot be sanitized in-place`);try{Fn(e)}catch(t){throw fn(e),t}}else if(Q(e))i=gn(``),a=i.ownerDocument.importNode(e,!0),a.nodeType===M.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Fn(i);else{if(!W&&!R&&!B&&e.indexOf(`<`)===-1)return S&&At?ce(e):e;if(i=gn(e),!i)return W?null:At?re:``}i&&U&&Y(i.firstChild);let l=c?e:i;try{let e=_n(l);for(;o=e.nextNode();)Dn(o,l),Nn(o,l),xn(o.content)&&Pn(o.content)}catch(n){throw c&&(fn(e),ye(t.removed,e=>{e.element&&Z(e.element)})),n}if(c){let n=!1;if(ye(t.removed,t=>{t.element&&(t.element===e&&(n=!0),Z(t.element))}),n)throw Ie(`a node selected for removal could not be safely returned; refusing to sanitize in place`);return R&&yn(e),e}if(W){if(R&&yn(i),kt)for(s=he.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(F.shadowroot||F.shadowrootmode)&&(s=ve.call(r,s,!0)),s}let u=B?i.outerHTML:i.innerHTML;return B&&P[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&D(ot,i.ownerDocument.doctype.name)&&(u=` +`+u),R&&(u=vn(u)),S&&At?ce(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};rn(e),Ot=!0,V=P,H=F},t.clearConfig=function(){en=null,Ot=!1,V=null,H=null,S=ie,re=``},t.isValidAttribute=function(e,t,n){en||rn({});let r=J(e),i=J(t);return On(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&E(T,e)&&Se(T[e],t)},t.removeHook=function(e,t){if(E(T,e)){if(t!==void 0){let n=be(T[e],t);return n===-1?void 0:Ce(T[e],n,1)[0]}return xe(T[e])}},t.removeHooks=function(e){E(T,e)&&(T[e]=[])},t.removeAllHooks=function(){T=_t()},t}var P=yt(),bt=`modulepreload`,F=function(e){return`/`+e},xt={},I=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?import.meta.resolve(e):new URL(e,import.meta.url).href}r=o(t.map(t=>{if(t=F(t,n),t=s(t),t in xt)return;xt[t]=!0;let r=t.endsWith(`.css`);for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}let i=document.createElement(`link`);if(i.rel=r?`stylesheet`:bt,r||(i.as=`script`),i.crossOrigin=``,i.href=t,a&&i.setAttribute(`nonce`,a),document.head.appendChild(i),r)return new Promise((e,n)=>{i.addEventListener(`load`,e),i.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},St=/^([^\S\n\r]*)-{3}\s*[\n\r](.*?)[\n\r]\1-{3}\s*[\n\r]+/s,Ct=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,L=/\s/,wt=n(e=>{let t=``,n=0,r=0;for(;rn&&L.test(e[o-1]);)o--;t+=e.slice(n,o)+` +`,n=a+1,r=n}return t+e.slice(n)},`stripAnyComments`),Tt=class extends Error{static{n(this,`UnknownDiagramError`)}constructor(e){super(e),this.name=`UnknownDiagramError`}},Et={},Dt=n(function(e,t){e=wt(e.replace(St,``).replace(Ct,``));for(let[n,{detector:r}]of Object.entries(Et))if(r(e,t))return n;throw new Tt(`No diagram type detected matching given configuration for text: ${e}`)},`detectType`),R=n((...e)=>{for(let{id:t,detector:n,loader:r}of e)z(t,n,r)},`registerLazyLoadedDiagrams`),z=n((e,n,r)=>{Et[e]&&t.warn(`Detector with key ${e} already exists. Overwriting.`),Et[e]={detector:n,loader:r},t.debug(`Detector with key ${e} added${r?` with loader`:``}`)},`addDetector`),B=n(e=>Et[e].loader,`getDiagramLoader`),Ot=n((e,t,{depth:n=2}={})=>{let r={depth:n};if(Array.isArray(t)&&!Array.isArray(e))return t.forEach(t=>Ot(e,t,r)),e;if(Array.isArray(t)&&Array.isArray(e))return t.forEach(t=>{e.includes(t)||e.push(t)}),e;if(e==null||n<=0)return typeof e==`object`&&e&&typeof t==`object`?Object.assign(e,t):t;if(t!=null&&typeof e==`object`&&typeof t==`object`){let r=e;Object.entries(t).forEach(([t,i])=>{if(typeof i==`object`){if(i===null)return;Object.hasOwn(e,t)||Object.defineProperty(e,t,{value:void 0,writable:!0,enumerable:!0,configurable:!0}),r[t]===void 0&&(r[t]=Array.isArray(i)?[]:{}),typeof r[t]==`object`&&(r[t]=Ot(r[t],i,{depth:n-1}))}else typeof r[t]!=`object`&&(Object.hasOwn(e,t)?r[t]=i:Object.defineProperty(e,t,{value:i,writable:!0,enumerable:!0,configurable:!0}))})}return e},`assignWithDepth`),V=Ot,H=`#ffffff`,U=`#f2f2f2`,W=n((e,t)=>t?x(e,{s:-40,l:10}):x(e,{s:-40,l:-10}),`mkBorder`),kt=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#fff4dd`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.useGradient=!0,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||`navy`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||b(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||b(this.mainBkg,10)):(this.rowOdd=this.rowOdd||y(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||y(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]}),Object.hasOwn(e,`nodeBorder`)&&!Object.hasOwn(e,`useGradient`)&&(this.useGradient=!1)}},At=n(e=>{let t=new kt;return t.calculate(e),t},`getThemeVariables`),jt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.mainBkg=`#1f2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.lineColor=`calculated`,this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=`calculated`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#F9FFFE`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`calculated`,this.activationBkgColor=`calculated`,this.sequenceNumberColor=`black`,this.clusterBkg=`#302F3D`,this.sectionBkgColor=b(`#EAE8D9`,30),this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`#EAE8D9`,this.excludeBkgColor=b(this.sectionBkgColor,10),this.taskBorderColor=h(255,255,255,70),this.taskBkgColor=`calculated`,this.taskTextColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=h(255,255,255,50),this.activeTaskBkgColor=`#81B1DB`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#E83737`,this.critBkgColor=`#E83737`,this.taskTextDarkColor=`calculated`,this.todayLineColor=`#DB5757`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=this.rowOdd||y(this.mainBkg,5)||`#ffffff`,this.rowEven=this.rowEven||b(this.mainBkg,10),this.labelColor=`calculated`,this.errorBkgColor=`#a44141`,this.errorTextColor=`#ddd`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`}updateColors(){this.secondBkg=y(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=y(this.labelBackground,25),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.background,this.taskBkgColor=y(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=S(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#555`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=`#f4f4f4`,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=x(this.primaryColor,{h:64}),this.fillType3=x(this.secondaryColor,{h:64}),this.fillType4=x(this.primaryColor,{h:-64}),this.fillType5=x(this.secondaryColor,{h:-64}),this.fillType6=x(this.primaryColor,{h:128}),this.fillType7=x(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||`#0b0000`,this.cScale2=this.cScale2||`#4d1037`,this.cScale3=this.cScale3||`#3f5258`,this.cScale4=this.cScale4||`#4f2f1b`,this.cScale5=this.cScale5||`#6e0a0a`,this.cScale6=this.cScale6||`#3b0048`,this.cScale7=this.cScale7||`#995a01`,this.cScale8=this.cScale8||`#154706`,this.cScale9=this.cScale9||`#161722`,this.cScale10=this.cScale10||`#00296f`,this.cScale11=this.cScale11||`#01629c`,this.cScale12=this.cScale12||`#010029`,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330});for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Mt=n(e=>{let t=new jt;return t.calculate(e),t},`getThemeVariables`),Nt=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#ECECFF`,this.secondaryColor=x(this.primaryColor,{h:120}),this.secondaryColor=`#ffffde`,this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.background=`white`,this.mainBkg=`#ECECFF`,this.secondBkg=`#ffffde`,this.lineColor=`#333333`,this.border1=`#9370DB`,this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.border2=`#aaaa33`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.labelBackground=`rgba(232,232,232, 0.8)`,this.textColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`calculated`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.clusterBkg=`#FBFBFF`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`calculated`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`calculated`,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor=`calculated`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBorderColor=`calculated`,this.critBkgColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.sectionBkgColor=h(102,102,255,.49),this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#fff400`,this.taskBorderColor=`#534fbc`,this.taskBkgColor=`#8a90dd`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`#534fbc`,this.activeTaskBkgColor=`#bfc7ff`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`navy`,this.noteFontWeight=this.noteFontWeight||`normal`,this.fontWeight=this.fontWeight||`normal`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.rowOdd=`calculated`,this.rowEven=`calculated`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))`,this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||b(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||b(this.tertiaryColor,40);for(let e=0;e{this[e]===`calculated`&&(this[e]=void 0)}),typeof e!=`object`){this.updateColors();return}let t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Pt=n(e=>{let t=new Nt;return t.calculate(e),t},`getThemeVariables`),Ft=class{static{n(this,`Theme`)}constructor(){this.background=`#f4f4f4`,this.primaryColor=`#cde498`,this.secondaryColor=`#cdffb2`,this.background=`white`,this.mainBkg=`#cde498`,this.secondBkg=`#cdffb2`,this.lineColor=`green`,this.border1=`#13540c`,this.border2=`#6eaa49`,this.arrowheadColor=`green`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.tertiaryColor=y(`#cde498`,10),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.primaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`#333`,this.edgeLabelBackground=`#e8e8e8`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`black`,this.actorLineColor=`calculated`,this.signalColor=`#333`,this.signalTextColor=`#333`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`#326932`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`#6eaa49`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`#6eaa49`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`#487e3a`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`black`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`lightgrey`,this.doneTaskBkgColor=`lightgrey`,this.doneTaskBorderColor=`grey`,this.critBorderColor=`#ff8888`,this.critBkgColor=`red`,this.todayLineColor=`red`,this.vertLineColor=`#00BFFF`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))`}updateColors(){this.actorBorder=b(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||b(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||b(this.tertiaryColor,40);for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},It=n(e=>{let t=new Ft;return t.calculate(e),t},`getThemeVariables`),Lt=class{static{n(this,`Theme`)}constructor(){this.primaryColor=`#eee`,this.contrast=`#707070`,this.secondaryColor=y(this.contrast,55),this.background=`#ffffff`,this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.lineColor=S(this.background),this.textColor=S(this.background),this.mainBkg=`#eee`,this.secondBkg=`calculated`,this.lineColor=`#666`,this.border1=`#999`,this.border2=`calculated`,this.note=`#ffa`,this.text=`#333`,this.critical=`#d42`,this.done=`#bbb`,this.arrowheadColor=`#333333`,this.fontFamily=`"trebuchet ms", verdana, arial, sans-serif`,this.fontSize=`16px`,this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg=`calculated`,this.nodeBorder=`calculated`,this.clusterBkg=`calculated`,this.clusterBorder=`calculated`,this.defaultLinkColor=`calculated`,this.titleColor=`calculated`,this.edgeLabelBackground=`white`,this.actorBorder=`calculated`,this.actorBkg=`calculated`,this.actorTextColor=`calculated`,this.actorLineColor=this.actorBorder,this.signalColor=`calculated`,this.signalTextColor=`calculated`,this.labelBoxBkgColor=`calculated`,this.labelBoxBorderColor=`calculated`,this.labelTextColor=`calculated`,this.loopTextColor=`calculated`,this.noteBorderColor=`calculated`,this.noteBkgColor=`calculated`,this.noteTextColor=`calculated`,this.activationBorderColor=`#666`,this.activationBkgColor=`#f4f4f4`,this.sequenceNumberColor=`white`,this.sectionBkgColor=`calculated`,this.altSectionBkgColor=`white`,this.sectionBkgColor2=`calculated`,this.excludeBkgColor=`#eeeeee`,this.taskBorderColor=`calculated`,this.taskBkgColor=`calculated`,this.taskTextLightColor=`white`,this.taskTextColor=`calculated`,this.taskTextDarkColor=`calculated`,this.taskTextOutsideColor=`calculated`,this.taskTextClickableColor=`#003163`,this.activeTaskBorderColor=`calculated`,this.activeTaskBkgColor=`calculated`,this.gridColor=`calculated`,this.doneTaskBkgColor=`calculated`,this.doneTaskBorderColor=`calculated`,this.critBkgColor=`calculated`,this.critBorderColor=`calculated`,this.todayLineColor=`calculated`,this.vertLineColor=`calculated`,this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`,this.rowOdd=this.rowOdd||y(this.mainBkg,75)||`#ffffff`,this.rowEven=this.rowEven||`#f4f4f4`,this.labelColor=`black`,this.errorBkgColor=`#552222`,this.errorTextColor=`#552222`,this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,1))`}updateColors(){this.secondBkg=y(this.contrast,55),this.border2=this.contrast,this.actorBorder=y(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor=`#999`,this.noteBkgColor=`#666`,this.noteTextColor=`#fff`,this.cScale0=this.cScale0||`#555`,this.cScale1=this.cScale1||`#F4F4F4`,this.cScale2=this.cScale2||`#555`,this.cScale3=this.cScale3||`#BBB`,this.cScale4=this.cScale4||`#777`,this.cScale5=this.cScale5||`#999`,this.cScale6=this.cScale6||`#DDD`,this.cScale7=this.cScale7||`#FFF`,this.cScale8=this.cScale8||`#DDD`,this.cScale9=this.cScale9||`#BBB`,this.cScale10=this.cScale10||`#999`,this.cScale11=this.cScale11||`#777`;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Rt=n(e=>{let t=new Lt;return t.calculate(e),t},`getThemeVariables`),zt=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=W(this.primaryColor,this.darkMode),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#000000`,this.stateBorder=`#000000`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));`,this.tertiaryColor=`#ffffff`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=`#E9E9F1`,n=x(e,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||e,this.cScale1=this.cScale1||t,this.cScale2=this.cScale2||n,this.cScale3=this.cScale3||x(e,{h:30}),this.cScale4=this.cScale4||x(e,{h:60}),this.cScale5=this.cScale5||x(e,{h:90}),this.cScale6=this.cScale6||x(e,{h:120}),this.cScale7=this.cScale7||x(e,{h:150}),this.cScale8=this.cScale8||x(e,{h:210,l:150}),this.cScale9=this.cScale9||x(e,{h:270}),this.cScale10=this.cScale10||x(e,{h:300}),this.cScale11=this.cScale11||x(e,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Bt=n(e=>{let t=new zt;return t.calculate(e),t},`getThemeVariables`),Vt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#2a2020`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#181818`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#333`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`arial, sans-serif`,this.fontSize=`14px`,this.useGradient=!0,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.noteFontWeight=`normal`,this.fontWeight=`normal`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#333`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#333`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Ht=n(e=>{let t=new Vt;return t.calculate(e),t},`getThemeVariables`),Ut=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=W(`#28253D`,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.clusterBkg=`#F9F9FB`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#FEF9C3`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=`#E9E9F1`,n=x(e,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||n,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||t,this.sectionBkgColor2=this.sectionBkgColor2||e,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground=`#F9F9FB`,this.altBackground=`#F9F9FB`,this.stateEdgeLabelBackground=`#FFFFFF`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Wt=n(e=>{let t=new Ut;return t.calculate(e),t},`getThemeVariables`),G=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.filterColor=`#FFFFFF`}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||`white`,this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground=`#16141F`,this.altBackground=`#16141F`,this.compositeTitleBackground=`#16141F`,this.stateEdgeLabelBackground=`#16141F`,this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#f0f0f0`,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||x(this.primaryColor,{h:30}),this.cScale4=this.cScale4||x(this.primaryColor,{h:60}),this.cScale5=this.cScale5||x(this.primaryColor,{h:90}),this.cScale6=this.cScale6||x(this.primaryColor,{h:120}),this.cScale7=this.cScale7||x(this.primaryColor,{h:150}),this.cScale8=this.cScale8||x(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||x(this.primaryColor,{h:270}),this.cScale10=this.cScale10||x(this.primaryColor,{h:300}),this.cScale11=this.cScale11||x(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},Gt=n(e=>{let t=new G;return t.calculate(e),t},`getThemeVariables`),Kt=class{static{n(this,`Theme`)}constructor(){this.background=`#ffffff`,this.primaryColor=`#cccccc`,this.mainBkg=`#ffffff`,this.noteBkgColor=`#fff5ad`,this.noteTextColor=`#28253D`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=W(`#28253D`,this.darkMode),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#28253D`,this.stateBorder=`#28253D`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.tertiaryColor=`#ffffff`,this.clusterBkg=`#F9F9FB`,this.clusterBorder=`#BDBCCC`,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.actorBorder=`#28253D`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[`#FDF4FF`,`#F0FDFA`,`#FFF7ED`,`#ECFEFF`,`#F0FDF4`,`#F5F3FF`,`#FEF2F2`,`#FEFCE8`,`#EEF2FF`,`#F7FEE7`,`#F0F9FF`,`#FFF1F2`],this.usecaseActorBorder=`#A78BFA`,this.usecaseActorBkg=`#F5F3FF`,this.usecaseBorder=`#2DD4BF`,this.usecaseBkg=`#F0FDFA`,this.usecaseBoundaryBorder=`#BDBCCC`,this.usecaseBoundaryBkg=`#FAFAFC`,this.usecaseIncludeLine=`#38BDF8`,this.usecaseExtendLine=`#FB923C`,this.filterColor=`#000000`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#28253D`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#28253D`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||(_(this.background)?y(this.background,4):b(this.background,4));let e=`#ECECFE`,t=x(e,{h:180,l:5});this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||e,this.activeTaskBorderColor=this.activeTaskBorderColor||e,this.activeTaskBkgColor=this.activeTaskBkgColor||y(e,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||`lightgrey`,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||`#FFFFFF`,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||`#F9F9FB`,this.compositeTitleBackground=this.compositeTitleBackground||`#F9F9FB`,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`,this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||`white`;for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},qt=n(e=>{let t=new Kt;return t.calculate(e),t},`getThemeVariables`),Jt=class{static{n(this,`Theme`)}constructor(){this.background=`#333`,this.primaryColor=`#1f2020`,this.secondaryColor=y(this.primaryColor,16),this.tertiaryColor=x(this.primaryColor,{h:-160}),this.primaryBorderColor=S(this.background),this.secondaryBorderColor=W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=W(this.tertiaryColor,this.darkMode),this.primaryTextColor=S(this.primaryColor),this.secondaryTextColor=S(this.secondaryColor),this.tertiaryTextColor=S(this.tertiaryColor),this.mainBkg=`#111113`,this.secondBkg=`calculated`,this.mainContrastColor=`lightgrey`,this.darkTextColor=y(S(`#323D47`),10),this.border1=`#ccc`,this.border2=h(255,255,255,.25),this.arrowheadColor=S(this.background),this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.labelBackground=`#111113`,this.textColor=`#ccc`,this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??`#FEF9C3`,this.noteTextColor=this.noteTextColor??`#28253D`,this.THEME_COLOR_LIMIT=12,this.fontFamily=`"Recursive Variable", arial, sans-serif`,this.fontSize=`14px`,this.nodeBorder=`#FFFFFF`,this.stateBorder=`#FFFFFF`,this.useGradient=!1,this.gradientStart=`#0042eb`,this.gradientStop=`#eb0042`,this.dropShadow=`url(#drop-shadow)`,this.nodeShadow=!0,this.archEdgeColor=`calculated`,this.archEdgeArrowColor=`calculated`,this.archEdgeWidth=`3`,this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth=`2px`,this.clusterBkg=`#1E1A2E`,this.clusterBorder=`#BDBCCC`,this.noteBorderColor=`#FACC15`,this.noteFontWeight=600,this.borderColorArray=[`#E879F9`,`#2DD4BF`,`#FB923C`,`#22D3EE`,`#4ADE80`,`#A78BFA`,`#F87171`,`#FACC15`,`#818CF8`,`#A3E635 `,`#38BDF8`,`#FB7185`],this.bkgColorArray=[],this.usecaseActorBorder=`#A78BFA`,this.usecaseBorder=`#2DD4BF`,this.usecaseBoundaryBorder=`#BDBCCC`,this.usecaseIncludeLine=`#38BDF8`,this.usecaseExtendLine=`#FB923C`,this.filterColor=`#FFFFFF`}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?`#eee`:`#FFFFFF`),this.secondaryColor=this.secondaryColor||x(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||x(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||W(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||W(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||W(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||W(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||`#fff5ad`,this.noteTextColor=this.noteTextColor||`#FFFFFF`,this.secondaryTextColor=this.secondaryTextColor||S(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||S(this.tertiaryColor),this.lineColor=this.lineColor||S(this.background),this.arrowheadColor=this.arrowheadColor||S(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg===`calculated`?y(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?b(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=`#FFFFFF`,this.signalColor=`#FFFFFF`,this.labelBoxBorderColor=`#BDBCCC`,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||b(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||S(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.rootLabelColor=`#FFFFFF`,this.excludeBkgColor=this.excludeBkgColor||`#eeeeee`,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||y(this.primaryColor,23),this.gridColor=this.gridColor||`lightgrey`,this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||`grey`,this.critBorderColor=this.critBorderColor||`#ff8888`,this.critBkgColor=this.critBkgColor||`red`,this.todayLineColor=this.todayLineColor||`red`,this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||`#003163`,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||`#16141F`,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||`#16141F`,this.altBackground=this.altBackground||`#16141F`,this.compositeTitleBackground=this.compositeTitleBackground||`#16141F`,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||`#f4a8ff`,this.cScale1=this.cScale1||`#46ecd5`,this.cScale2=this.cScale2||`#ffb86a`,this.cScale3=this.cScale3||`#dab2ff`,this.cScale4=this.cScale4||`#7bf1a8`,this.cScale5=this.cScale5||`#c4b4ff`,this.cScale6=this.cScale6||`#ffa2a2`,this.cScale7=this.cScale7||`#ffdf20`,this.cScale8=this.cScale8||`#a3b3ff`,this.cScale9=this.cScale9||`#bbf451`,this.cScale10=this.cScale10||`#74d4ff`,this.cScale11=this.cScale11||`#ffa1ad`,this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||this.background;for(let e=0;e{this[`fillType`+t]=this[`fillType`+t]||e});for(let e=0;e{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},K={base:{getThemeVariables:At},dark:{getThemeVariables:Mt},default:{getThemeVariables:Pt},forest:{getThemeVariables:It},neutral:{getThemeVariables:Rt},neo:{getThemeVariables:Bt},"neo-dark":{getThemeVariables:Ht},redux:{getThemeVariables:Wt},"redux-dark":{getThemeVariables:Gt},"redux-color":{getThemeVariables:qt},"redux-dark-color":{getThemeVariables:n(e=>{let t=new Jt;return t.calculate(e),t},`getThemeVariables`)}},q={flowchart:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:`basis`,padding:15,wrappingWidth:120,minNodeWidth:120,inheritDir:!1},swimlane:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,layout:`swimlane`,lineHops:`arc`,ignoreCrossLaneEdges:!0,optimizeRanksByCrossings:!0,automaticLaneOrdering:!1},agentflow:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,diagramPadding:8,nodeSpacing:50,rankSpacing:50,wrappingWidth:120,minNodeWidth:120},sequence:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:`"Open Sans", sans-serif`,actorFontWeight:400,noteFontSize:14,noteFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,noteFontWeight:400,noteAlign:`center`,messageFontSize:16,messageFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:`%Y-%m-%d`,topAxis:!1,displayMode:``,weekday:`sunday`},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],titleColor:``,titleFontFamily:`"trebuchet ms", verdana, arial, sans-serif`,titleFontSize:`4ex`},class:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,htmlLabels:!1,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},state:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,layout:`elk`,wrappingWidth:120,minNodeWidth:120,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:`20`,compositTitleSize:35,radius:5},er:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,titleTopMargin:25,diagramPadding:20,layoutDirection:`TB`,minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:`gray`,fill:`honeydew`,fontSize:12},pie:{useMaxWidth:!0,textPosition:.75,donutHole:0,legendPosition:`right`,highlightSlice:``},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:`top`,yAxisPosition:`left`,quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,showLegend:!0,legendFontSize:14,legendPadding:10,xAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},yAxis:{$ref:`#/$defs/XYChartAxisConfig`,showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},chartOrientation:`vertical`,plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,rect_fill:`#f9f9f9`,text_color:`#333`,rect_border_size:`0.5px`,rect_border_color:`#bbb`,rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:`cose-bilkent`},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:``},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:`center`,bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:`"Open Sans", sans-serif`,taskMargin:50,activationWidth:10,textPlacement:`fo`,actorColours:[`#8FBC8F`,`#7CFC00`,`#00FFFF`,`#20B2AA`,`#B0E0E6`,`#FFFFE0`],sectionFills:[`#191970`,`#8B008B`,`#4B0082`,`#2F4F4F`,`#800000`,`#8B4513`,`#00008B`],sectionColours:[`#fff`],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:`main`,mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:`"Open Sans", sans-serif`,personFontWeight:`normal`,external_personFontSize:14,external_personFontFamily:`"Open Sans", sans-serif`,external_personFontWeight:`normal`,systemFontSize:14,systemFontFamily:`"Open Sans", sans-serif`,systemFontWeight:`normal`,external_systemFontSize:14,external_systemFontFamily:`"Open Sans", sans-serif`,external_systemFontWeight:`normal`,system_dbFontSize:14,system_dbFontFamily:`"Open Sans", sans-serif`,system_dbFontWeight:`normal`,external_system_dbFontSize:14,external_system_dbFontFamily:`"Open Sans", sans-serif`,external_system_dbFontWeight:`normal`,system_queueFontSize:14,system_queueFontFamily:`"Open Sans", sans-serif`,system_queueFontWeight:`normal`,external_system_queueFontSize:14,external_system_queueFontFamily:`"Open Sans", sans-serif`,external_system_queueFontWeight:`normal`,boundaryFontSize:14,boundaryFontFamily:`"Open Sans", sans-serif`,boundaryFontWeight:`normal`,messageFontSize:12,messageFontFamily:`"Open Sans", sans-serif`,messageFontWeight:`normal`,containerFontSize:14,containerFontFamily:`"Open Sans", sans-serif`,containerFontWeight:`normal`,external_containerFontSize:14,external_containerFontFamily:`"Open Sans", sans-serif`,external_containerFontWeight:`normal`,container_dbFontSize:14,container_dbFontFamily:`"Open Sans", sans-serif`,container_dbFontWeight:`normal`,external_container_dbFontSize:14,external_container_dbFontFamily:`"Open Sans", sans-serif`,external_container_dbFontWeight:`normal`,container_queueFontSize:14,container_queueFontFamily:`"Open Sans", sans-serif`,container_queueFontWeight:`normal`,external_container_queueFontSize:14,external_container_queueFontFamily:`"Open Sans", sans-serif`,external_container_queueFontWeight:`normal`,componentFontSize:14,componentFontFamily:`"Open Sans", sans-serif`,componentFontWeight:`normal`,external_componentFontSize:14,external_componentFontFamily:`"Open Sans", sans-serif`,external_componentFontWeight:`normal`,component_dbFontSize:14,component_dbFontFamily:`"Open Sans", sans-serif`,component_dbFontWeight:`normal`,external_component_dbFontSize:14,external_component_dbFontFamily:`"Open Sans", sans-serif`,external_component_dbFontWeight:`normal`,component_queueFontSize:14,component_queueFontFamily:`"Open Sans", sans-serif`,component_queueFontWeight:`normal`,external_component_queueFontSize:14,external_component_queueFontFamily:`"Open Sans", sans-serif`,external_component_queueFontWeight:`normal`,wrap:!0,wrapPadding:10,person_bg_color:`#08427B`,person_border_color:`#073B6F`,external_person_bg_color:`#686868`,external_person_border_color:`#8A8A8A`,system_bg_color:`#1168BD`,system_border_color:`#3C7FC0`,system_db_bg_color:`#1168BD`,system_db_border_color:`#3C7FC0`,system_queue_bg_color:`#1168BD`,system_queue_border_color:`#3C7FC0`,external_system_bg_color:`#999999`,external_system_border_color:`#8A8A8A`,external_system_db_bg_color:`#999999`,external_system_db_border_color:`#8A8A8A`,external_system_queue_bg_color:`#999999`,external_system_queue_border_color:`#8A8A8A`,container_bg_color:`#438DD5`,container_border_color:`#3C7FC0`,container_db_bg_color:`#438DD5`,container_db_border_color:`#3C7FC0`,container_queue_bg_color:`#438DD5`,container_queue_border_color:`#3C7FC0`,external_container_bg_color:`#B3B3B3`,external_container_border_color:`#A6A6A6`,external_container_db_bg_color:`#B3B3B3`,external_container_db_border_color:`#A6A6A6`,external_container_queue_bg_color:`#B3B3B3`,external_container_queue_border_color:`#A6A6A6`,component_bg_color:`#85BBF0`,component_border_color:`#78A8D8`,component_db_bg_color:`#85BBF0`,component_db_border_color:`#78A8D8`,component_queue_bg_color:`#85BBF0`,component_queue_border_color:`#78A8D8`,external_component_bg_color:`#CCCCCC`,external_component_border_color:`#BFBFBF`,external_component_db_bg_color:`#CCCCCC`,external_component_db_border_color:`#BFBFBF`,external_component_queue_bg_color:`#CCCCCC`,external_component_queue_border_color:`#BFBFBF`},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:`gradient`,nodeAlignment:`justify`,showValues:!0,prefix:``,suffix:``,nodeWidth:10,nodePadding:12,labelStyle:`legacy`},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1,showIcons:!1,defaultIconPack:``,filenameIcons:{},extensionIcons:{}},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1,nodeSeparation:75,idealEdgeLengthMultiplier:1.5,edgeElasticity:.45,numIter:2500,seed:1},eventmodeling:{useMaxWidth:!0,padding:30,rowHeight:32},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},usecase:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,wrappingWidth:120,minNodeWidth:120,actorFontSize:14,actorFontFamily:`"Open Sans", sans-serif`,actorFontWeight:`normal`,usecaseFontSize:12,usecaseFontFamily:`"Open Sans", sans-serif`,usecaseFontWeight:`normal`,nodeSpacing:50,rankSpacing:50,diagramPadding:20,colorScheme:`role`},venn:{useMaxWidth:!0,theme:`redux-color`,look:`neo`,width:800,height:450,padding:8,useDebugLayout:!1},cynefin:{useMaxWidth:!0,width:800,height:600,padding:40,showDomainDescriptions:!0,boundaryAmplitude:8,seed:0},theme:`default`,look:`classic`,handDrawnSeed:0,layout:`elk`,maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:`"trebuchet ms", verdana, arial, sans-serif;`,logLevel:5,securityLevel:`strict`,startOnLoad:!0,arrowMarkerAbsolute:!1,secure:[`secure`,`securityLevel`,`startOnLoad`,`maxTextSize`,`suppressErrorRendering`,`maxEdges`],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},Yt={...q,deterministicIDSeed:void 0,elk:{mergeEdges:!1,straightenEdges:!0,lineHops:!0,preset:`default`,nodePlacementStrategy:void 0,layeringStrategy:void 0,cycleBreakingStrategy:void 0,layeringLayerBound:4,nodePlacementAlignment:void 0,forceNodeModelOrder:!1,considerModelOrder:`NODES_AND_EDGES`,keepEntryNodeOnTop:!1},themeCSS:void 0,themeVariables:K.default.getThemeVariables(),sequence:{...q.sequence,messageFont:n(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`),noteFont:n(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},`noteFont`),actorFont:n(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},`actorFont`)},class:{theme:q.class?.theme,look:q.class?.look,layout:q.class?.layout,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...q.gantt,tickInterval:void 0,useWidth:void 0},c4:{...q.c4,useWidth:void 0,personFont:n(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},`personFont`),flowchart:{...q.flowchart,inheritDir:!1},external_personFont:n(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},`external_personFont`),systemFont:n(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},`systemFont`),external_systemFont:n(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},`external_systemFont`),system_dbFont:n(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},`system_dbFont`),external_system_dbFont:n(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},`external_system_dbFont`),system_queueFont:n(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},`system_queueFont`),external_system_queueFont:n(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},`external_system_queueFont`),containerFont:n(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},`containerFont`),external_containerFont:n(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},`external_containerFont`),container_dbFont:n(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},`container_dbFont`),external_container_dbFont:n(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},`external_container_dbFont`),container_queueFont:n(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},`container_queueFont`),external_container_queueFont:n(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},`external_container_queueFont`),componentFont:n(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},`componentFont`),external_componentFont:n(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},`external_componentFont`),component_dbFont:n(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},`component_dbFont`),external_component_dbFont:n(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},`external_component_dbFont`),component_queueFont:n(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},`component_queueFont`),external_component_queueFont:n(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},`external_component_queueFont`),boundaryFont:n(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},`boundaryFont`),messageFont:n(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},`messageFont`)},pie:{...q.pie,useWidth:984},xyChart:{...q.xyChart,useWidth:void 0},requirement:{...q.requirement,useWidth:void 0},packet:{...q.packet},eventmodeling:{...q.eventmodeling},treeView:{...q.treeView,useWidth:void 0},radar:{...q.radar},usecase:{...q.usecase},railroad:{...q.railroad,fontSize:void 0,fontFamily:void 0,terminalFill:void 0,terminalStroke:void 0,terminalTextColor:void 0,nonTerminalFill:void 0,nonTerminalStroke:void 0,nonTerminalTextColor:void 0,lineColor:void 0,markerFill:void 0,commentFill:void 0,commentStroke:void 0,commentTextColor:void 0,specialFill:void 0,specialStroke:void 0,ruleNameColor:void 0},ishikawa:{...q.ishikawa},sankey:{...q.sankey,nodeColors:void 0},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:`,`},venn:{...q.venn},cynefin:{...q.cynefin}},Xt=n((e,t=``)=>Object.keys(e).reduce((n,r)=>Array.isArray(e[r])?n:typeof e[r]==`object`&&e[r]!==null?[...n,t+r,...Xt(e[r],``)]:[...n,t+r],[]),`keyify`),Zt=new Set(Xt(Yt,``)),Qt=Yt,$t={"flowchart-v2":`flowchart`,"flowchart-elk":`flowchart`,classDiagram:`class`,stateDiagram:`state`,xychart:`xyChart`,railroadAbnf:`railroad`,railroadEbnf:`railroad`,railroadPeg:`railroad`},J=n(e=>$t[e]??e,`getDiagramConfigKey`),en={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},tn=n((e,n)=>{for(let r of Object.keys(e)){let i=e[r];(r.startsWith(`__`)||r.includes(`proto`)||r.includes(`constr`)||typeof i!=`string`||!n.test(i))&&(t.debug(`sanitize deleting dictionary entry:`,r,i),delete e[r])}},`sanitizeDictionaryConfig`),nn=n(e=>{if(t.debug(`sanitizeDirective called with`,e),!(typeof e!=`object`||!e)){if(Array.isArray(e)){e.forEach(e=>nn(e));return}for(let n of Object.keys(e)){if(t.debug(`Checking key`,n),n.startsWith(`__`)||n.includes(`proto`)||n.includes(`constr`)||!Zt.has(n)||e[n]==null){t.debug(`sanitize deleting key: `,n),delete e[n];continue}if(typeof e[n]==`object`){let r=en[n];r?tn(e[n],r):(t.debug(`sanitizing object`,n),nn(e[n]));continue}for(let r of[`themeCSS`,`fontFamily`,`altFontFamily`])n.includes(r)&&(t.debug(`sanitizing css option`,n),e[n]=rn(e[n]))}if(e.themeVariables)for(let t of Object.keys(e.themeVariables)){let n=e.themeVariables[t];n?.match&&!n.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]=``)}t.debug(`After sanitization`,e)}},`sanitizeDirective`),rn=n(e=>{let t=0,n=0;for(let r of e){if(te===`theme`?t===`null`||Object.hasOwn(K,t):e!==`look`||sn.has(t),`isUsableAppearance`),ln=n((e,t,n)=>{if(e)return[e[t]?.[n],e[n]].find(e=>e!==void 0&&cn(n,e))},`readAppearance`),un=n(e=>!(e===!1||[`false`,`null`,`0`].includes(String(e).trim().toLowerCase())),`evaluate`),Y=V({},an),dn,fn={},X=[],pn=V({},an),Z,mn=n((e,t)=>{if(!Z)return;let n=[t,...[...X].reverse(),fn,an],r=e[Z];for(let t of on)for(let i of n){let n=ln(i,Z,t);if(n!==void 0){e[t]=n,r?.[t]!==void 0&&(r[t]=n);break}}},`resolveAppearance`),hn=n((e,t)=>{let n=V({},e),r={};for(let e of t)$(e),r=V(r,e);if(n=V(n,r),mn(n,r),(r.theme||n.theme!==e.theme)&&n.theme&&Object.hasOwn(K,n.theme)){let e=V(V({},dn).themeVariables||{},r.themeVariables);n.themeVariables=K[n.theme].getThemeVariables(e)}return pn=n,Dn(pn),pn},`updateCurrentConfig`),gn=n(e=>{Z=e===void 0?void 0:J(e),hn(Y,X)},`setDiagramConfigScope`),_n=n(e=>(Y=V({},an),Y=V(Y,e),fn=V({},e),e.theme&&Object.hasOwn(K,e.theme)&&(Y.themeVariables=K[e.theme].getThemeVariables(e.themeVariables)),hn(Y,X),Y),`setSiteConfig`),vn=n(e=>{dn=V({},e)},`saveConfigFromInitialize`),yn=n(e=>(Y=V(Y,e),fn=V(fn,e),hn(Y,X),Y),`updateSiteConfig`),bn=n(()=>V({},Y),`getSiteConfig`),xn=n(e=>(hn(pn,[e]),Q()),`setConfig`),Q=n(()=>V({},pn),`getConfig`),$=n(e=>{e&&([`secure`,...Y.secure??[]].forEach(n=>{Object.hasOwn(e,n)&&(t.debug(`Denied attempt to modify a secure key ${n}`,e[n]),delete e[n])}),Object.keys(e).forEach(t=>{t.startsWith(`__`)&&delete e[t]}),Object.keys(e).forEach(t=>{typeof e[t]==`string`&&(e[t].includes(`<`)||e[t].includes(`>`)||e[t].includes(`url(data:`))&&delete e[t],typeof e[t]==`object`&&$(e[t])}))},`sanitize`),Sn=n(e=>{nn(e),e.fontFamily&&!e.themeVariables?.fontFamily&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),X.push(e),hn(Y,X)},`addDirective`),Cn=n((e=Y)=>{X=[],Z=void 0,hn(e,X)},`reset`),wn={LAZY_LOAD_DEPRECATED:`The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.`,FLOWCHART_HTML_LABELS_DEPRECATED:`flowchart.htmlLabels is deprecated. Please use global htmlLabels instead.`},Tn={},En=n(e=>{Tn[e]||(t.warn(wn[e]),Tn[e]=!0)},`issueWarning`),Dn=n(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&En(`LAZY_LOAD_DEPRECATED`)},`checkConfig`),On=n(()=>{let e={};dn&&(e=V(e,dn));for(let t of X)e=V(e,t);return e},`getUserDefinedConfig`),kn=n(e=>(e.flowchart?.htmlLabels!=null&&En(`FLOWCHART_HTML_LABELS_DEPRECATED`),un(e.htmlLabels??e.flowchart?.htmlLabels??!0)),`getEffectiveHtmlLabels`),An=/<\/?br\s*\/?>/gi,jn=new RegExp(An.source,`i`),Mn=n(e=>e?Hn(e).replace(/\\n/g,`#br#`).split(`#br#`):[``],`getRows`),Nn=(()=>{let e=!1;return()=>{e||=(Pn(),!0)}})();function Pn(){let e=`data-temp-href-target`;P.addHook(`beforeSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(`target`)&&t.setAttribute(e,t.getAttribute(`target`)??``)}),P.addHook(`afterSanitizeAttributes`,t=>{t.tagName===`A`&&t.hasAttribute(e)&&(t.setAttribute(`target`,t.getAttribute(e)??``),t.removeAttribute(e),t.getAttribute(`target`)===`_blank`&&t.setAttribute(`rel`,`noopener`))})}n(Pn,`setupDompurifyHooks`);var Fn=n(e=>(Nn(),P.sanitize(e)),`removeScript`),In=n((e,t)=>{if(kn(t)){let n=t.securityLevel;n===`antiscript`||n===`strict`||n===`sandbox`?e=Fn(e):n!==`loose`&&(e=Hn(e),e=e.replace(//g,`>`),e=e.replace(/=/g,`=`),e=Vn(e))}return e},`sanitizeMore`),Ln=n((e,t)=>e&&(e=t.dompurifyConfig?P.sanitize(In(e,t),t.dompurifyConfig).toString():P.sanitize(In(e,t),{FORBID_TAGS:[`style`]}).toString(),e),`sanitizeText`),Rn=n((e,t)=>typeof e==`string`?Ln(e,t):e.flat().map(e=>Ln(e,t)),`sanitizeTextOrArray`),zn=n(e=>jn.test(e),`hasBreaks`),Bn=n(e=>e.split(An),`splitBreaks`),Vn=n(e=>e.replace(/#br#/g,`
    `),`placeholderToBreak`),Hn=n(e=>e.replace(An,`#br#`),`breakToPlaceholder`),Un=n(e=>{let t=``;return e&&(t=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},`getUrl`),Wn=n(function(...e){let t=e.filter(e=>!isNaN(e));return Math.max(...t)},`getMax`),Gn=n(function(...e){let t=e.filter(e=>!isNaN(e));return Math.min(...t)},`getMin`),Kn=n(function(e){let t=e.split(/(,)/),n=[];for(let e=0;e0&&e+1Math.max(0,e.split(t).length-1),`countOccurrence`),Jn=n((e,t)=>{let n=qn(e,`~`),r=qn(t,`~`);return n===1&&r===1},`shouldCombineSets`),Yn=n(e=>{let t=qn(e,`~`),n=!1;if(t<=1)return e;t%2!=0&&e.startsWith(`~`)&&(e=e.substring(1),n=!0);let r=[...e],i=r.indexOf(`~`),a=r.lastIndexOf(`~`);for(;i!==-1&&a!==-1&&i!==a;)r[i]=`<`,r[a]=`>`,i=r.indexOf(`~`),a=r.lastIndexOf(`~`);return n&&r.unshift(`~`),r.join(``)},`processSet`),Xn=n(()=>window.MathMLElement!==void 0,`isMathMLSupported`),Zn=/\$\$(.*?)\$\$/g,Qn=n(e=>(e.match(Zn)?.length??0)>0,`hasKatex`),$n=n(async(e,t)=>{let n=document.createElement(`div`);n.innerHTML=await tr(e,t),n.id=`katex-temp`,n.style.visibility=`hidden`,n.style.position=`absolute`,n.style.top=`0`,document.querySelector(`body`)?.insertAdjacentElement(`beforeend`,n);let r={width:n.clientWidth,height:n.clientHeight};return n.remove(),r},`calculateMathMLDimensions`),er=n(async(e,t)=>{if(!Qn(e))return e;if(!(Xn()||t.legacyMathML||t.forceLegacyMathML))return e.replace(Zn,`MathML is unsupported in this environment.`);{let{default:n}=await I(async()=>{let{default:e}=await import(`./katex-CXMH3UgJ.js`);return{default:e}},[]),r=t.forceLegacyMathML||!Xn()&&t.legacyMathML?`htmlAndMathml`:`mathml`;return e.split(An).map(e=>Qn(e)?`
    ${e}
    `:`
    ${e}
    `).join(``).replace(Zn,(e,t)=>n.renderToString(t,{throwOnError:!0,displayMode:!0,output:r}).replace(/\n/g,` `).replace(//g,``))}},`renderKatexUnsanitized`),tr=n(async(e,t)=>Ln(await er(e,t),t),`renderKatexSanitized`),nr={getRows:Mn,sanitizeText:Ln,sanitizeTextOrArray:Rn,hasBreaks:zn,splitBreaks:Bn,lineBreakRegex:An,removeScript:Fn,getUrl:Un,evaluate:un,getMax:Wn,getMin:Gn},rr=n(function(e,t){for(let n of t)e.attr(n[0],n[1])},`d3Attrs`),ir=n(function(e,t,n){let r=new Map;return n?(r.set(`width`,`100%`),r.set(`style`,`max-width: ${t}px;`)):(r.set(`height`,e),r.set(`width`,t)),r},`calculateSvgSizeAttrs`),ar=n(function(e,t,n,r){rr(e,ir(t,n,r))},`configureSvgSize`),or=n(function(e,n,r,i){let a=n.node().getBBox(),o=a.width,s=a.height;t.info(`SVG bounds: ${o}x${s}`,a);let c=0,l=0;t.info(`Graph bounds: ${c}x${l}`,e),c=o+r*2,l=s+r*2,t.info(`Calculated bounds: ${c}x${l}`),ar(n,l,c,i);let u=`${a.x-r} ${a.y-r} ${a.width+2*r} ${a.height+2*r}`;n.attr(`viewBox`,u)},`setupGraphViewbox`),sr={};function cr(e){return[...e.cssRules].map(e=>e.cssText).join(` +`)}n(cr,`cssStyleSheetToString`);var lr=n((e,n,r,i)=>{let a=``;return e in sr&&sr[e]?a=sr[e]({...r,svgId:i}):t.warn(`No theme found for ${e}`),`& { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + fill: ${r.textColor} + } + @keyframes edge-animation-frame { + from { + stroke-dashoffset: 0; + } + } + @keyframes dash { + to { + stroke-dashoffset: 0; + } + } + & .edge-animation-slow { + stroke-dasharray: 9,5 !important; + stroke-dashoffset: 900; + animation: dash 50s linear infinite; + stroke-linecap: round; + } + & .edge-animation-fast { + stroke-dasharray: 9,5 !important; + stroke-dashoffset: 900; + animation: dash 20s linear infinite; + stroke-linecap: round; + } + /* Classes common for multiple diagrams */ + + & .error-icon { + fill: ${r.errorBkgColor}; + } + & .error-text { + fill: ${r.errorTextColor}; + stroke: ${r.errorTextColor}; + } + + & .edge-thickness-normal { + stroke-width: ${r.strokeWidth??1}px; + } + & .edge-thickness-thick { + stroke-width: 3.5px + } + & .edge-pattern-solid { + stroke-dasharray: 0; + } + & .edge-thickness-invisible { + stroke-width: 0; + fill: none; + } + & .edge-pattern-dashed{ + stroke-dasharray: 3; + } + .edge-pattern-dotted { + stroke-dasharray: 2; + } + + & .marker { + fill: ${r.lineColor}; + stroke: ${r.lineColor}; + } + & .marker.cross { + stroke: ${r.lineColor}; + } + + & svg { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + } + & p { + margin: 0 + } + + ${a} + .node .neo-node { + stroke: ${r.nodeBorder}; + } + + [data-look="neo"].node rect, [data-look="neo"].cluster rect, [data-look="neo"].node polygon { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + [data-look="neo"].swimlane.cluster rect { + filter: none; + } + + + [data-look="neo"].node path { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + stroke-width: ${r.strokeWidth??1}px; + } + + [data-look="neo"].node .outer-path { + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].node .neo-line path { + stroke: ${r.nodeBorder}; + filter: none; + } + + [data-look="neo"].node circle{ + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].node circle .state-start{ + fill: #000000; + } + + [data-look="neo"].icon-shape .icon { + fill: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + [data-look="neo"].icon-shape .icon-neo path { + stroke: ${r.useGradient?`url(`+i+`-gradient)`:r.nodeBorder}; + filter: ${r.dropShadow?r.dropShadow.replace(`url(#drop-shadow)`,`url(${i}-drop-shadow)`):`none`}; + } + + ${n} +`},`getStyles`),ur=n((e,t)=>{t!==void 0&&(sr[e]=t)},`addStylesForDiagram`),dr=lr,fr={};r(fr,{clear:()=>_r,getAccDescription:()=>xr,getAccTitle:()=>yr,getDiagramTitle:()=>Cr,setAccDescription:()=>br,setAccTitle:()=>vr,setDiagramTitle:()=>Sr});var pr=``,mr=``,hr=``,gr=n(e=>Ln(e,Q()),`sanitizeText`),_r=n(()=>{pr=``,hr=``,mr=``},`clear`),vr=n(e=>{pr=gr(e).replace(/^\s+/g,``)},`setAccTitle`),yr=n(()=>pr,`getAccTitle`),br=n(e=>{hr=gr(e).replace(/\n\s+/g,` +`)},`setAccDescription`),xr=n(()=>hr,`getAccDescription`),Sr=n(e=>{mr=gr(e)},`setDiagramTitle`),Cr=n(()=>mr,`getDiagramTitle`),wr=t,Tr=e,Er=Q,Dr=xn,Or=an,kr=n(e=>Ln(e,Er()),`sanitizeText`),Ar=or,jr=n(()=>fr,`getCommonDb`),Mr={},Nr=n((e,t,n)=>{Mr[e]&&wr.warn(`Diagram with id ${e} already registered. Overwriting.`),Mr[e]=t,n&&z(e,n),ur(e,t.styles),t.injectUtils?.(wr,Tr,Er,kr,Ar,jr(),()=>{})},`registerDiagram`),Pr=n(e=>{if(e in Mr)return Mr[e];throw new Fr(e)},`getDiagram`),Fr=class extends Error{static{n(this,`DiagramNotFoundError`)}constructor(e){super(`Diagram ${e} not found.`)}};export{yn as $,Qn as A,kr as B,B as C,Pt as D,bn as E,tr as F,Dr as G,br as H,Cn as I,_n as J,gn as K,rn as L,Kn as M,Nr as N,Un as O,R as P,K as Q,nn as R,Pr as S,kn as T,vr as U,vn as V,xn as W,Ar as X,or as Y,dr as Z,St as _,_r as a,_ as at,Q as b,ar as c,a as ct,Or as d,I as et,Qt as f,un as g,Ct as h,$n as i,v as it,An as j,On as k,cr as l,Et as m,Sn as n,b as nt,fr as o,h as ot,Dt as p,Sr as q,V as r,y as rt,nr as s,m as st,Tt as t,P as tt,an as u,xr as v,Cr as w,Er as x,yr as y,Ln as z}; \ No newline at end of file diff --git a/www/assets/chunk-WEXAMYUT-I3m-hOmT.js b/www/assets/chunk-WEXAMYUT-I3m-hOmT.js new file mode 100644 index 0000000..505f528 --- /dev/null +++ b/www/assets/chunk-WEXAMYUT-I3m-hOmT.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";var r=t((t,r,o,s)=>{t.attr(`class`,o);let{width:c,height:l,x:u,y:d}=i(t,r);n(t,l,c,s);let f=a(u,d,c,l,r);t.attr(`viewBox`,f),e.debug(`viewBox configured: ${f} with padding: ${r}`)},`setupViewPortForSVG`),i=t((e,t)=>{let n=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:n.width+t*2,height:n.height+t*2,x:n.x,y:n.y}},`calculateDimensionsWithPadding`),a=t((e,t,n,r,i)=>`${e-i} ${t-i} ${n} ${r}`,`createViewBox`);export{r as t}; \ No newline at end of file diff --git a/www/assets/chunk-XXDRQBXY-C1_eEj17.js b/www/assets/chunk-XXDRQBXY-C1_eEj17.js new file mode 100644 index 0000000..de422e3 --- /dev/null +++ b/www/assets/chunk-XXDRQBXY-C1_eEj17.js @@ -0,0 +1 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var n=t((t,n)=>{let r;return n===`sandbox`&&(r=e(`#i`+t)),e(n===`sandbox`?r.nodes()[0].contentDocument.body:`body`).select(`[id="${t}"]`)},`getDiagramElement`);export{n as t}; \ No newline at end of file diff --git a/www/assets/chunk-Y2CYZVJY-DsF7k-Jl.js b/www/assets/chunk-Y2CYZVJY-DsF7k-Jl.js new file mode 100644 index 0000000..70c3d40 --- /dev/null +++ b/www/assets/chunk-Y2CYZVJY-DsF7k-Jl.js @@ -0,0 +1 @@ +var e=Object.defineProperty,t=(t,n)=>e(t,`name`,{value:n,configurable:!0}),n=(t,n)=>{for(var r in n)e(t,r,{get:n[r],enumerable:!0})};export{t as n,n as t}; \ No newline at end of file diff --git a/www/assets/chunk-ZIGJFQKS-BJ6myxnF.js b/www/assets/chunk-ZIGJFQKS-BJ6myxnF.js new file mode 100644 index 0000000..4f9ffb3 --- /dev/null +++ b/www/assets/chunk-ZIGJFQKS-BJ6myxnF.js @@ -0,0 +1,2 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{R as r,h as i,p as a,r as o,s}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as c}from"./dist-Bfr8PhAA.js";function l(e){this._context=e}l.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};function u(e){return new l(e)}var d=class{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}};function f(e){return new d(e,!0)}function ee(e){return new d(e,!1)}function p(){}function m(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function h(e){this._context=e}h.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:m(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function te(e){return new h(e)}function ne(e){this._context=e}ne.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function re(e){return new ne(e)}function ie(e){this._context=e}ie.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:m(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ae(e){return new ie(e)}function oe(e,t){this._basis=new h(e),this._beta=t}oe.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r=e[0],i=t[0],a=e[n]-r,o=t[n]-i,s=-1,c;++s<=n;)c=s/n,this._basis.point(this._beta*e[s]+(1-this._beta)*(r+c*a),this._beta*t[s]+(1-this._beta)*(i+c*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};var se=(function e(t){function n(e){return t===1?new h(e):new oe(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function g(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function _(e,t){this._context=e,this._k=(1-t)/6}_.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:g(this,this._x1,this._y1)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ce=(function e(t){function n(e){return new _(e,t)}return n.tension=function(t){return e(+t)},n})(0);function v(e,t){this._context=e,this._k=(1-t)/6}v.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var le=(function e(t){function n(e){return new v(e,t)}return n.tension=function(t){return e(+t)},n})(0);function y(e,t){this._context=e,this._k=(1-t)/6}y.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:g(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ue=(function e(t){function n(e){return new y(e,t)}return n.tension=function(t){return e(+t)},n})(0);function b(e,t,n){var r=e._x1,i=e._y1,a=e._x2,o=e._y2;if(e._l01_a>1e-12){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,c=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/c,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/c}if(e._l23_a>1e-12){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*l+e._x1*e._l23_2a-t*e._l12_2a)/u,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/u}e._context.bezierCurveTo(r,i,a,o,e._x2,e._y2)}function de(e,t){this._context=e,this._alpha=t}de.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var fe=(function e(t){function n(e){return t?new de(e,t):new _(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function pe(e,t){this._context=e,this._alpha=t}pe.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var me=(function e(t){function n(e){return t?new pe(e,t):new v(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function he(e,t){this._context=e,this._alpha=t}he.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=(n*n+r*r)**+this._alpha)}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:b(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var ge=(function e(t){function n(e){return t?new he(e,t):new y(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function _e(e){this._context=e}_e.prototype={areaStart:p,areaEnd:p,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function ve(e){return new _e(e)}function ye(e){return e<0?-1:1}function be(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(ye(a)+ye(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function xe(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function x(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-r)/3;e._context.bezierCurveTo(r+s,i+s*t,a-s,o-s*n,a,o)}function S(e){this._context=e}S.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:x(this,this._t0,xe(this,this._t0))}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,e!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,x(this,xe(this,n=be(this,e,t)),n);break;default:x(this,this._t0,n=be(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Se(e){this._context=new Ce(e)}(Se.prototype=Object.create(S.prototype)).point=function(e,t){S.prototype.point.call(this,t,e)};function Ce(e){this._context=e}Ce.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function we(e){return new S(e)}function Te(e){return new Se(e)}function Ee(e){this._context=e}Ee.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n){if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=De(e),i=De(t),a=0,o=1;o=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};function w(e){return new C(e,.5)}function T(e){return new C(e,0)}function ke(e){return new C(e,1)}function E(e){if(typeof e!=`object`||!e)return!1;if(Object.getPrototypeOf(e)===null)return!0;if(Object.prototype.toString.call(e)!==`[object Object]`){let t=e[Symbol.toStringTag];return t==null||!Object.getOwnPropertyDescriptor(e,Symbol.toStringTag)?.writable?!1:e.toString()===`[object ${t}]`}let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function Ae(){}function je(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}function D(e){return e==null?e===void 0?`[object Undefined]`:`[object Null]`:Object.prototype.toString.call(e)}var Me=`[object RegExp]`,O=`[object String]`,k=`[object Number]`,A=`[object Boolean]`,j=`[object Arguments]`,Ne=`[object Symbol]`,Pe=`[object Date]`,Fe=`[object Map]`,Ie=`[object Set]`,Le=`[object Array]`,Re=`[object ArrayBuffer]`,ze=`[object Object]`,M=`[object DataView]`,Be=`[object Uint8Array]`,Ve=`[object Uint8ClampedArray]`,He=`[object Uint16Array]`,Ue=`[object Uint32Array]`,We=`[object Int8Array]`,Ge=`[object Int16Array]`,Ke=`[object Int32Array]`,qe=`[object Float32Array]`,Je=`[object Float64Array]`,Ye=typeof globalThis==`object`&&globalThis||typeof window==`object`&&window||typeof self==`object`&&self||typeof global==`object`&&global||(function(){return this})();function N(e){return Ye.Buffer!==void 0&&Ye.Buffer.isBuffer(e)}function Xe(e){return Number.isSafeInteger(e)&&e>=0}function Ze(e){return e!=null&&typeof e!=`function`&&Xe(e.length)}function Qe(e){return e===`__proto__`}function P(e){return e==null||typeof e!=`object`&&typeof e!=`function`}function F(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function $e(e,t){return I(e,void 0,e,new Map,t)}function I(e,t,n,r=new Map,i=void 0){let a=i?.(e,t,n,r);if(a!==void 0)return a;if(P(e))return e;if(r.has(e))return r.get(e);if(Array.isArray(e)){let t=Array(e.length);r.set(e,t);for(let a=0;a{let o=t?.(n,r,i,a);if(o!==void 0)return o;if(typeof e==`object`){if(D(e)===`[object Object]`&&typeof e.constructor!=`function`){let t={};return a.set(e,t),L(t,e,i,a),t}switch(Object.prototype.toString.call(e)){case k:case O:case A:{let t=new e.constructor(e?.valueOf());return L(t,e),t}case j:{let t={};return L(t,e),t.length=e.length,t[Symbol.iterator]=e[Symbol.iterator],t}default:return}}})}function nt(e){return tt(e)}function R(e){return typeof e==`object`&&!!e&&D(e)===`[object Arguments]`}function z(e){return typeof e==`object`&&!!e}function rt(e){return z(e)&&Ze(e)}function B(e){return F(e)}function V(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(`Expected a function`);let n=function(...r){let i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);let o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(V.Cache||Map),n}V.Cache=Map;function it(e){if(P(e))return e;if(Array.isArray(e)||F(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<`u`&&e instanceof SharedArrayBuffer)return e.slice(0);let t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);let n=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new n(e);if(e instanceof RegExp){let t=new n(e);return t.lastIndex=e.lastIndex,t}if(e instanceof DataView)return new n(e.buffer.slice(0));if(e instanceof Error){let t;return t=e instanceof AggregateError?new n(e.errors,e.message,{cause:e.cause}):new n(e.message,{cause:e.cause}),t.stack=e.stack,Object.assign(t,e),t}return typeof File<`u`&&e instanceof File?new n([e],e.name,{type:e.type,lastModified:e.lastModified}):typeof e==`object`?Object.assign(Object.create(t),e):e}function at(e,...t){let n=t.slice(0,-1),r=t[t.length-1],i=e;for(let e=0;ee.args);r(e),i=o(i,[...e])}else i=n.args;if(!i)return;let s=a(e,t),c=`config`;return i[c]!==void 0&&(s===`flowchart-v2`&&(s=`flowchart`),i[s]=i[c],delete i[c]),i},`detectInit`),dt=n(function(t,n=null){try{let r=RegExp(`[%]{2}(?![{]${lt.source})(?=[}][%]{2}).* +`,`ig`);t=t.trim().replace(r,``).replace(/'/gm,`"`),e.debug(`Detecting diagram directive${n===null?``:` type:`+n} based on the text:${t}`);let a,o=[];for(;(a=i.exec(t))!==null;)if(a.index===i.lastIndex&&i.lastIndex++,a&&!n||n&&a[1]?.match(n)||n&&a[2]?.match(n)){let e=a[1]?a[1]:a[2],t=a[3]?a[3].trim():a[4]?JSON.parse(a[4].trim()):null;o.push({type:e,args:t})}return o.length===0?{type:t,args:null}:o.length===1?o[0]:o}catch(r){return e.error(`ERROR: ${r.message} - Unable to parse directive type: '${n}' based on the text: '${t}'`),{type:void 0,args:null}}},`detectDirective`),ft=n(function(e){return e.replace(i,``)},`removeDirectives`),pt=n(function(e,t){for(let[n,r]of t.entries())if(r.match(e))return n;return-1},`isSubstringInArray`);function U(e,t){return e?ct[`curve${e.charAt(0).toUpperCase()+e.slice(1)}`]??t:t}n(U,`interpolateToCurve`);function mt(e,t){let n=e.trim();if(n)return t.securityLevel===`loose`?n:(0,st.sanitizeUrl)(n)}n(mt,`formatUrl`);var ht=n((t,...n)=>{let r=t.split(`.`),i=r.length-1,a=r[i],o=window;for(let n=0;n{n+=W(e,t),t=e}),G(e,n/2)}n(gt,`traverseEdge`);function _t(e){return e.length===1?e[0]:gt(e)}n(_t,`calcLabelPosition`);var vt=n((e,t=2)=>{let n=10**t;return Math.round(e*n)/n},`roundNumber`),G=n((e,t)=>{let n,r=t;for(let t of e){if(n){let e=W(t,n);if(e===0)return n;if(e=1)return{x:t.x,y:t.y};if(i>0&&i<1)return{x:vt((1-i)*n.x+i*t.x,5),y:vt((1-i)*n.y+i*t.y,5)}}}n=t}throw Error(`Could not find a suitable point for the given distance`)},`calculatePoint`),yt=n((t,n,r)=>{e.info(`our points ${JSON.stringify(n)}`),n[0]!==r&&(n=n.reverse());let i=G(n,25),a=t?10:5,o=Math.atan2(n[0].y-i.y,n[0].x-i.x),s={x:0,y:0};return s.x=Math.sin(o)*a+(n[0].x+i.x)/2,s.y=-Math.cos(o)*a+(n[0].y+i.y)/2,s},`calcCardinalityPosition`);function bt(t,n,r){let i=structuredClone(r);e.info(`our points`,i),n!==`start_left`&&n!==`start_right`&&i.reverse();let a=G(i,25+t),o=10+t*.5,s=Math.atan2(i[0].y-a.y,i[0].x-a.x),c={x:0,y:0};return n===`start_left`?(c.x=Math.sin(s+Math.PI)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s+Math.PI)*o+(i[0].y+a.y)/2):n===`end_right`?(c.x=Math.sin(s-Math.PI)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s-Math.PI)*o+(i[0].y+a.y)/2-5):n===`end_left`?(c.x=Math.sin(s)*o+(i[0].x+a.x)/2-5,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2-5):(c.x=Math.sin(s)*o+(i[0].x+a.x)/2,c.y=-Math.cos(s)*o+(i[0].y+a.y)/2),c}n(bt,`calcTerminalLabelPosition`);function K(e){let t=``,n=``;for(let r of e)r!==void 0&&(r.startsWith(`color:`)||r.startsWith(`text-align:`)?n=n+r+`;`:t=t+r+`;`);return{style:t,labelStyle:n}}n(K,`getStylesFromArray`);var xt=0,St=n(()=>(xt++,`id-`+Math.random().toString(36).substr(2,12)+`-`+xt),`generateId`);function Ct(e){let t=``;for(let n=0;nCt(e.length),`random`),Tt=n(function(){return{x:0,y:0,fill:void 0,anchor:`start`,style:`#666`,width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:``}},`getTextObj`),Et=n(function(e,t){let n=t.text.replace(s.lineBreakRegex,` `),[,r]=Z(t.fontSize),i=e.append(`text`);i.attr(`x`,t.x),i.attr(`y`,t.y),i.style(`text-anchor`,t.anchor),i.style(`font-family`,t.fontFamily),i.style(`font-size`,r),i.style(`font-weight`,t.fontWeight),i.attr(`fill`,t.fill),t.class!==void 0&&i.attr(`class`,t.class);let a=i.append(`tspan`);return a.attr(`x`,t.x+t.textMargin*2),a.attr(`fill`,t.fill),a.text(n),i},`drawSimpleText`),Dt=V((e,t,n)=>{if(!e||(n=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,joinWith:`
    `},n),s.hasBreaks(e)))return e;let r=e.split(` `).filter(Boolean),i=[],a=``;return r.forEach((e,o)=>{let s=J(`${e} `,n),c=J(a,n);if(s>t){let{hyphenatedStrings:r,remainingWord:o}=Ot(e,t,`-`,n);i.push(a,...r),a=o}else c+s>=t?(i.push(a),a=e):a=[a,e].filter(Boolean).join(` `);o+1===r.length&&i.push(a)}),i.filter(e=>e!==``).join(n.joinWith)},(e,t,n)=>`${e}${t}${n.fontSize}${n.fontWeight}${n.fontFamily}${n.joinWith}`),Ot=V((e,t,n=`-`,r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:`Arial`,margin:0},r);let i=[...e],a=[],o=``;return i.forEach((e,s)=>{let c=`${o}${e}`;if(J(c,r)>=t){let e=s+1,t=i.length===e,r=`${c}${n}`;a.push(t?c:r),o=``}else o=c}),{hyphenatedStrings:a,remainingWord:o}},(e,t,n=`-`,r)=>`${e}${t}${n}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function q(e,t){return Y(e,t).height}n(q,`calculateTextHeight`);function J(e,t){return Y(e,t).width}n(J,`calculateTextWidth`);var Y=V((e,n)=>{let{fontSize:r=12,fontFamily:i=`Arial`,fontWeight:a=400}=n;if(!e)return{width:0,height:0};let[,o]=Z(r),c=[`sans-serif`,i],l=e.split(s.lineBreakRegex),u=[],d=t(`body`);if(!d.remove)return{width:0,height:0,lineHeight:0};let f=d.append(`svg`);for(let e of c){let t=0,n={width:0,height:0,lineHeight:0};for(let r of l){let i=Tt();i.text=r||`​`;let s=Et(f,i).style(`font-size`,o).style(`font-weight`,a).style(`font-family`,e),c=(s._groups||s)[0][0].getBBox();if(c.width===0&&c.height===0)throw Error(`svg element not in render tree`);n.width=Math.round(Math.max(n.width,c.width)),t=Math.round(c.height),n.height+=t,n.lineHeight=Math.round(Math.max(n.lineHeight,t))}u.push(n)}return f.remove(),u[isNaN(u[1].height)||isNaN(u[1].width)||isNaN(u[1].lineHeight)||u[0].height>u[1].height&&u[0].width>u[1].width&&u[0].lineHeight>u[1].lineHeight?0:1]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),kt=class{constructor(e=!1,t){this.count=0,this.count=t?t.length:0,this.next=e?()=>this.count++:()=>Date.now()}static{n(this,`InitIDGenerator`)}},X,At=n(function(e){return X||=document.createElement(`div`),e=escape(e).replace(/%26/g,`&`).replace(/%23/g,`#`).replace(/%3B/g,`;`),X.innerHTML=e,unescape(X.textContent)},`entityDecode`);function jt(e){return`str`in e}n(jt,`isDetailedError`);var Mt=n((e,t,n,r)=>{if(!r)return;let i=e.node()?.getBBox();i&&e.append(`text`).text(r).attr(`text-anchor`,`middle`).attr(`x`,i.x+i.width/2).attr(`y`,-n).attr(`class`,t)},`insertTitle`),Z=n(e=>{if(typeof e==`number`)return[e,e+`px`];let t=parseInt(e??``,10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+`px`]:[t,e]},`parseFontSize`);function Q(e,t){return ot({},e,t)}n(Q,`cleanAndMerge`);var Nt={assignWithDepth:o,wrapLabel:Dt,calculateTextHeight:q,calculateTextWidth:J,calculateTextDimensions:Y,cleanAndMerge:Q,detectInit:ut,detectDirective:dt,isSubstringInArray:pt,interpolateToCurve:U,calcLabelPosition:_t,calcCardinalityPosition:yt,calcTerminalLabelPosition:bt,formatUrl:mt,getStylesFromArray:K,generateId:St,random:wt,runFunc:ht,entityDecode:At,insertTitle:Mt,isLabelCoordinateInPath:$,parseFontSize:Z,InitIDGenerator:kt},Pt=n(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/#\w+;/g,function(e){let t=e.substring(1,e.length-1);return/^\+?\d+$/.test(t)?`fl°°`+t+`¶ß`:`fl°`+t+`¶ß`}),t},`encodeEntities`),Ft=n(function(e){return e.replace(/fl°°/g,`&#`).replace(/fl°/g,`&`).replace(/¶ß/g,`;`)},`decodeEntities`),It=n((e,t,{counter:n=0,prefix:r,suffix:i},a)=>a||`${r?`${r}_`:``}${e}_${t}_${n}${i?`_${i}`:``}`,`getEdgeId`);function Lt(e){return e??null}n(Lt,`handleUndefinedAttr`);function $(e,t){let n=Math.round(e.x),r=Math.round(e.y),i=t.replace(/(\d+\.\d+)/g,e=>Math.round(parseFloat(e)).toString());return i.includes(n.toString())||i.includes(r.toString())}n($,`isLabelCoordinateInPath`);export{ce as $,Je as A,Ne as B,j as C,M as D,A as E,k as F,D as G,Ue as H,ze as I,w as J,ke as K,Me as L,Ke as M,We as N,Pe as O,Fe as P,fe as Q,Ie as R,N as S,Le as T,Be as U,He as V,Ve as W,we as X,Oe as Y,Te as Z,Dt as _,Ft as a,P as b,It as c,U as d,te as et,jt as f,Nt as g,ft as h,Q as i,Ge as j,qe as k,K as l,wt as m,q as n,ee as nt,Pt as o,Z as p,T as q,J as r,u as rt,St as s,Y as t,f as tt,Lt as u,B as v,Re as w,Ze as x,R as y,O as z}; \ No newline at end of file diff --git a/www/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js b/www/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js new file mode 100644 index 0000000..831d0dd --- /dev/null +++ b/www/assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js @@ -0,0 +1,217 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,M as i,U as a,a as o,q as s,s as c,tt as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{c as h,g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as _,n as v,o as y,r as b}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as x,t as S}from"./index-DoQkmpth.js";import{t as C}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as w}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as T}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as E}from"./chunk-WEXAMYUT-I3m-hOmT.js";var D=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,18],r=[1,19],i=[1,20],a=[1,41],o=[1,26],s=[1,42],c=[1,24],l=[1,25],u=[1,32],d=[1,33],f=[1,34],p=[1,45],m=[1,35],h=[1,36],g=[1,37],_=[1,38],v=[1,27],y=[1,28],b=[1,29],x=[1,30],S=[1,31],C=[1,44],w=[1,46],T=[1,43],E=[1,47],D=[1,9],O=[1,8,9],k=[1,58],A=[1,59],j=[1,60],M=[1,61],N=[1,62],P=[1,63],F=[1,64],I=[1,8,9,41],ee=[1,77],L=[1,8,9,12,13,22,39,41,44,46,68,69,70,71,72,73,74,79,81],R=[1,8,9,12,13,18,20,22,39,41,44,46,47,60,68,69,70,71,72,73,74,79,81,86,100,102,103],z=[13,60,86,100,102,103],B=[13,60,73,74,86,100,102,103],te=[13,60,68,69,70,71,72,86,100,102,103],V=[1,103],H=[1,121],U=[1,117],W=[1,113],G=[1,119],K=[1,114],q=[1,115],J=[1,116],Y=[1,118],X=[1,120],ne=[22,50,60,61,82,86,87,88,89,90],re=[1,128],Z=[12,39],ie=[1,8,9,39,41,44,46],Q=[1,8,9,22],ae=[1,153],oe=[1,8,9,61],$=[1,8,9,22,50,60,61,82,86,87,88,89,90],se={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,classLiteralName:17,DOT:18,className:19,GENERICTYPE:20,relationStatement:21,LABEL:22,namespaceStatement:23,classStatement:24,memberStatement:25,annotationStatement:26,clickStatement:27,styleStatement:28,cssClassStatement:29,noteStatement:30,classDefStatement:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,namespaceIdentifier:38,STRUCT_START:39,classStatements:40,STRUCT_STOP:41,NAMESPACE:42,classIdentifier:43,STYLE_SEPARATOR:44,members:45,ANNOTATION_START:46,ANNOTATION_END:47,CLASS:48,emptyBody:49,SPACE:50,MEMBER:51,SEPARATOR:52,relation:53,NOTE_FOR:54,noteText:55,NOTE:56,CLASSDEF:57,classList:58,stylesOpt:59,ALPHA:60,COMMA:61,direction_tb:62,direction_bt:63,direction_rl:64,direction_lr:65,relationType:66,lineType:67,AGGREGATION:68,EXTENSION:69,COMPOSITION:70,DEPENDENCY:71,LOLLIPOP:72,LINE:73,DOTTED_LINE:74,CALLBACK:75,LINK:76,LINK_TARGET:77,CLICK:78,CALLBACK_NAME:79,CALLBACK_ARGS:80,HREF:81,STYLE:82,CSSCLASS:83,style:84,styleComponent:85,NUM:86,COLON:87,UNIT:88,BRKT:89,PCT:90,commentToken:91,textToken:92,graphCodeTokens:93,textNoTagsToken:94,TAGSTART:95,TAGEND:96,"==":97,"--":98,DEFAULT:99,MINUS:100,keywords:101,UNICODE_TEXT:102,BQUOTE_STR:103,$accept:0,$end:1},terminals_:{2:`error`,7:`CLASS_DIAGRAM`,8:`NEWLINE`,9:`EOF`,12:`SQS`,13:`STR`,14:`SQE`,18:`DOT`,20:`GENERICTYPE`,22:`LABEL`,33:`acc_title`,34:`acc_title_value`,35:`acc_descr`,36:`acc_descr_value`,37:`acc_descr_multiline_value`,39:`STRUCT_START`,41:`STRUCT_STOP`,42:`NAMESPACE`,44:`STYLE_SEPARATOR`,46:`ANNOTATION_START`,47:`ANNOTATION_END`,48:`CLASS`,50:`SPACE`,51:`MEMBER`,52:`SEPARATOR`,54:`NOTE_FOR`,56:`NOTE`,57:`CLASSDEF`,60:`ALPHA`,61:`COMMA`,62:`direction_tb`,63:`direction_bt`,64:`direction_rl`,65:`direction_lr`,68:`AGGREGATION`,69:`EXTENSION`,70:`COMPOSITION`,71:`DEPENDENCY`,72:`LOLLIPOP`,73:`LINE`,74:`DOTTED_LINE`,75:`CALLBACK`,76:`LINK`,77:`LINK_TARGET`,78:`CLICK`,79:`CALLBACK_NAME`,80:`CALLBACK_ARGS`,81:`HREF`,82:`STYLE`,83:`CSSCLASS`,86:`NUM`,87:`COLON`,88:`UNIT`,89:`BRKT`,90:`PCT`,93:`graphCodeTokens`,95:`TAGSTART`,96:`TAGEND`,97:`==`,98:`--`,99:`DEFAULT`,100:`MINUS`,101:`keywords`,102:`UNICODE_TEXT`,103:`BQUOTE_STR`},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,1],[15,3],[15,2],[19,1],[19,3],[19,1],[19,2],[19,2],[19,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[23,4],[23,5],[38,2],[38,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[24,1],[24,3],[24,4],[24,3],[24,6],[24,4],[24,7],[24,6],[43,2],[43,3],[49,0],[49,2],[49,2],[26,4],[45,1],[45,2],[25,1],[25,2],[25,1],[25,1],[21,3],[21,4],[21,4],[21,5],[30,3],[30,2],[31,3],[58,1],[58,3],[32,1],[32,1],[32,1],[32,1],[53,3],[53,2],[53,2],[53,1],[66,1],[66,1],[66,1],[66,1],[66,1],[67,1],[67,1],[27,3],[27,4],[27,3],[27,4],[27,4],[27,5],[27,3],[27,4],[27,4],[27,5],[27,4],[27,5],[27,5],[27,6],[28,3],[29,3],[59,1],[59,3],[84,1],[84,2],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[91,1],[91,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[94,1],[94,1],[94,1],[94,1],[16,1],[16,1],[16,1],[16,1],[17,1],[55,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 8:this.$=a[s-1];break;case 9:case 10:case 13:case 15:this.$=a[s];break;case 11:case 14:this.$=a[s-2]+`.`+a[s];break;case 12:case 16:this.$=a[s-1]+a[s];break;case 17:case 18:this.$=a[s-1]+`~`+a[s]+`~`;break;case 19:r.addRelation(a[s]);break;case 20:a[s-1].title=r.cleanupLabel(a[s]),r.addRelation(a[s-1]);break;case 31:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 32:case 33:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 34:r.addClassesToNamespace(a[s-3],a[s-1][0],a[s-1][1]),r.popNamespace();break;case 35:r.addClassesToNamespace(a[s-4],a[s-1][0],a[s-1][1]),r.popNamespace();break;case 36:this.$=r.addNamespace(a[s]);break;case 37:this.$=r.addNamespace(a[s-1],a[s]);break;case 38:this.$=[[a[s]],[]];break;case 39:this.$=[[a[s-1]],[]];break;case 40:a[s][0].unshift(a[s-2]),this.$=a[s];break;case 41:this.$=[[],[a[s]]];break;case 42:this.$=[[],[a[s-1]]];break;case 43:a[s][1].unshift(a[s-2]),this.$=a[s];break;case 44:case 45:this.$=[[],[]];break;case 46:this.$=a[s];break;case 48:r.setCssClass(a[s-2],a[s]);break;case 49:r.addMembers(a[s-3],a[s-1]);break;case 51:r.setCssClass(a[s-5],a[s-3]),r.addMembers(a[s-5],a[s-1]);break;case 52:r.addAnnotation(a[s-3],a[s-1]);break;case 53:r.addAnnotation(a[s-6],a[s-4]),r.addMembers(a[s-6],a[s-1]);break;case 54:r.addAnnotation(a[s-5],a[s-3]);break;case 55:this.$=a[s],r.addClass(a[s]);break;case 56:this.$=a[s-1],r.addClass(a[s-1]),r.setClassLabel(a[s-1],a[s]);break;case 60:r.addAnnotation(a[s],a[s-2]);break;case 61:case 74:this.$=[a[s]];break;case 62:a[s].push(a[s-1]),this.$=a[s];break;case 63:break;case 64:r.addMember(a[s-1],r.cleanupLabel(a[s]));break;case 65:break;case 66:break;case 67:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:`none`,relationTitle2:`none`};break;case 68:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:`none`};break;case 69:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:`none`,relationTitle2:a[s-1]};break;case 70:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 71:this.$=r.addNote(a[s],a[s-1]);break;case 72:this.$=r.addNote(a[s]);break;case 73:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 75:this.$=a[s-2].concat([a[s]]);break;case 76:r.setDirection(`TB`);break;case 77:r.setDirection(`BT`);break;case 78:r.setDirection(`RL`);break;case 79:r.setDirection(`LR`);break;case 80:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 81:this.$={type1:`none`,type2:a[s],lineType:a[s-1]};break;case 82:this.$={type1:a[s-1],type2:`none`,lineType:a[s]};break;case 83:this.$={type1:`none`,type2:`none`,lineType:a[s]};break;case 84:this.$=r.relationType.AGGREGATION;break;case 85:this.$=r.relationType.EXTENSION;break;case 86:this.$=r.relationType.COMPOSITION;break;case 87:this.$=r.relationType.DEPENDENCY;break;case 88:this.$=r.relationType.LOLLIPOP;break;case 89:this.$=r.lineType.LINE;break;case 90:this.$=r.lineType.DOTTED_LINE;break;case 91:case 97:this.$=a[s-2],r.setClickEvent(a[s-1],a[s]);break;case 92:case 98:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 93:this.$=a[s-2],r.setLink(a[s-1],a[s]);break;case 94:this.$=a[s-3],r.setLink(a[s-2],a[s-1],a[s]);break;case 95:this.$=a[s-3],r.setLink(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 96:this.$=a[s-4],r.setLink(a[s-3],a[s-2],a[s]),r.setTooltip(a[s-3],a[s-1]);break;case 99:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 100:this.$=a[s-4],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 101:this.$=a[s-3],r.setLink(a[s-2],a[s]);break;case 102:this.$=a[s-4],r.setLink(a[s-3],a[s-1],a[s]);break;case 103:this.$=a[s-4],r.setLink(a[s-3],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 104:this.$=a[s-5],r.setLink(a[s-4],a[s-2],a[s]),r.setTooltip(a[s-4],a[s-1]);break;case 105:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 106:r.setCssClass(a[s-1],a[s]);break;case 107:this.$=[a[s]];break;case 108:a[s-2].push(a[s]),this.$=a[s-2];break;case 110:this.$=a[s-1]+a[s]}},`anonymous`),table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:t,35:r,37:i,38:22,42:a,43:23,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},e(D,[2,5],{8:[1,48]}),{8:[1,49]},e(O,[2,19],{22:[1,50]}),e(O,[2,21]),e(O,[2,22]),e(O,[2,23]),e(O,[2,24]),e(O,[2,25]),e(O,[2,26]),e(O,[2,27]),e(O,[2,28]),e(O,[2,29]),e(O,[2,30]),{34:[1,51]},{36:[1,52]},e(O,[2,33]),e(O,[2,63],{53:53,66:56,67:57,13:[1,54],22:[1,55],68:k,69:A,70:j,71:M,72:N,73:P,74:F}),{39:[1,65]},e(I,[2,47],{39:[1,67],44:[1,66],46:[1,68]}),e(O,[2,65]),e(O,[2,66]),{16:69,60:p,86:C,100:w,102:T},{16:39,17:40,19:70,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:71,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:72,60:p,86:C,100:w,102:T,103:E},{60:[1,73]},{13:[1,74]},{16:39,17:40,19:75,60:p,86:C,100:w,102:T,103:E},{13:ee,55:76},{58:78,60:[1,79]},e(O,[2,76]),e(O,[2,77]),e(O,[2,78]),e(O,[2,79]),e(L,[2,13],{16:39,17:40,19:81,18:[1,80],20:[1,82],60:p,86:C,100:w,102:T,103:E}),e(L,[2,15],{20:[1,83]}),{15:84,16:85,17:86,60:p,86:C,100:w,102:T,103:E},{16:39,17:40,19:87,60:p,86:C,100:w,102:T,103:E},e(R,[2,133]),e(R,[2,134]),e(R,[2,135]),e(R,[2,136]),e([1,8,9,12,13,20,22,39,41,44,46,68,69,70,71,72,73,74,79,81],[2,137]),e(D,[2,6],{10:5,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,19:21,38:22,43:23,16:39,17:40,5:88,33:t,35:r,37:i,42:a,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E}),{5:89,10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:t,35:r,37:i,38:22,42:a,43:23,46:o,48:s,51:c,52:l,54:u,56:d,57:f,60:p,62:m,63:h,64:g,65:_,75:v,76:y,78:b,82:x,83:S,86:C,100:w,102:T,103:E},e(O,[2,20]),e(O,[2,31]),e(O,[2,32]),{13:[1,91],16:39,17:40,19:90,60:p,86:C,100:w,102:T,103:E},{53:92,66:56,67:57,68:k,69:A,70:j,71:M,72:N,73:P,74:F},e(O,[2,64]),{67:93,73:P,74:F},e(z,[2,83],{66:94,68:k,69:A,70:j,71:M,72:N}),e(B,[2,84]),e(B,[2,85]),e(B,[2,86]),e(B,[2,87]),e(B,[2,88]),e(te,[2,89]),e(te,[2,90]),{8:[1,96],23:99,24:97,30:98,38:22,40:95,42:a,43:23,48:s,54:u,56:d},{16:100,60:p,86:C,100:w,102:T},{41:[1,102],45:101,51:V},{16:104,60:p,86:C,100:w,102:T},{47:[1,105]},{13:[1,106]},{13:[1,107]},{79:[1,108],81:[1,109]},{22:H,50:U,59:110,60:W,82:G,84:111,85:112,86:K,87:q,88:J,89:Y,90:X},{60:[1,122]},{13:ee,55:123},e(I,[2,72]),e(I,[2,138]),{22:H,50:U,59:124,60:W,61:[1,125],82:G,84:111,85:112,86:K,87:q,88:J,89:Y,90:X},e(ne,[2,74]),{16:39,17:40,19:126,60:p,86:C,100:w,102:T,103:E},e(L,[2,16]),e(L,[2,17]),e(L,[2,18]),{11:127,12:re,39:[2,36]},e(Z,[2,9],{16:85,17:86,15:130,18:[1,129],60:p,86:C,100:w,102:T,103:E}),e(Z,[2,10]),e(ie,[2,55],{11:131,12:re}),e(D,[2,7]),{9:[1,132]},e(Q,[2,67]),{16:39,17:40,19:133,60:p,86:C,100:w,102:T,103:E},{13:[1,135],16:39,17:40,19:134,60:p,86:C,100:w,102:T,103:E},e(z,[2,82],{66:136,68:k,69:A,70:j,71:M,72:N}),e(z,[2,81]),{41:[1,137]},{23:99,24:97,30:98,38:22,40:138,42:a,43:23,48:s,54:u,56:d},{8:[1,139],41:[2,38]},{8:[1,140],41:[2,41]},{8:[1,141],41:[2,44]},e(I,[2,48],{39:[1,142]}),{41:[1,143]},e(I,[2,50]),{41:[2,61],45:144,51:V},{47:[1,145]},{16:39,17:40,19:146,60:p,86:C,100:w,102:T,103:E},e(O,[2,91],{13:[1,147]}),e(O,[2,93],{13:[1,149],77:[1,148]}),e(O,[2,97],{13:[1,150],80:[1,151]}),{13:[1,152]},e(O,[2,105],{61:ae}),e(oe,[2,107],{85:154,22:H,50:U,60:W,82:G,86:K,87:q,88:J,89:Y,90:X}),e($,[2,109]),e($,[2,111]),e($,[2,112]),e($,[2,113]),e($,[2,114]),e($,[2,115]),e($,[2,116]),e($,[2,117]),e($,[2,118]),e($,[2,119]),e(O,[2,106]),e(I,[2,71]),e(O,[2,73],{61:ae}),{60:[1,155]},e(L,[2,14]),{39:[2,37]},{13:[1,156]},{15:157,16:85,17:86,60:p,86:C,100:w,102:T,103:E},e(Z,[2,12]),e(ie,[2,56]),{1:[2,4]},e(Q,[2,69]),e(Q,[2,68]),{16:39,17:40,19:158,60:p,86:C,100:w,102:T,103:E},e(z,[2,80]),e(I,[2,34]),{41:[1,159]},{23:99,24:97,30:98,38:22,40:160,41:[2,39],42:a,43:23,48:s,54:u,56:d},{23:99,24:97,30:98,38:22,40:161,41:[2,42],42:a,43:23,48:s,54:u,56:d},{23:99,24:97,30:98,38:22,40:162,41:[2,45],42:a,43:23,48:s,54:u,56:d},{45:163,51:V},e(I,[2,49]),{41:[2,62]},e(I,[2,52],{39:[1,164]}),e(O,[2,60]),e(O,[2,92]),e(O,[2,94]),e(O,[2,95],{77:[1,165]}),e(O,[2,98]),e(O,[2,99],{13:[1,166]}),e(O,[2,101],{13:[1,168],77:[1,167]}),{22:H,50:U,60:W,82:G,84:169,85:112,86:K,87:q,88:J,89:Y,90:X},e($,[2,110]),e(ne,[2,75]),{14:[1,170]},e(Z,[2,11]),e(Q,[2,70]),e(I,[2,35]),{41:[2,40]},{41:[2,43]},{41:[2,46]},{41:[1,171]},{41:[1,173],45:172,51:V},e(O,[2,96]),e(O,[2,100]),e(O,[2,102]),e(O,[2,103],{77:[1,174]}),e(oe,[2,108],{85:154,22:H,50:U,60:W,82:G,86:K,87:q,88:J,89:Y,90:X}),e(ie,[2,8]),e(I,[2,51]),{41:[1,175]},e(I,[2,54]),e(O,[2,104]),e(I,[2,53])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],127:[2,37],132:[2,4],144:[2,62],160:[2,40],161:[2,43],162:[2,46]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};se.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return 62;case 1:return 63;case 2:return 64;case 3:return 65;case 4:break;case 5:break;case 6:return this.begin(`acc_title`),33;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),35;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 8;case 14:break;case 15:return 7;case 16:return 7;case 17:return`EDGE_STATE`;case 18:this.begin(`callback_name`);break;case 19:this.popState();break;case 20:this.popState(),this.begin(`callback_args`);break;case 21:return 79;case 22:this.popState();break;case 23:return 80;case 24:this.popState();break;case 25:return`STR`;case 26:this.begin(`string`);break;case 27:return 82;case 28:return 57;case 29:return this.begin(`namespace`),42;case 30:return this.popState(),8;case 31:break;case 32:return this.begin(`namespace-body`),39;case 33:this.popState(),this.less(0);break;case 34:return this.popState(),41;case 35:return`EOF_IN_STRUCT`;case 36:return 8;case 37:break;case 38:return`EDGE_STATE`;case 39:return this.begin(`class`),48;case 40:return this.popState(),8;case 41:break;case 42:return this.popState(),this.popState(),41;case 43:return this.begin(`class-body`),39;case 44:return this.popState(),41;case 45:return`EOF_IN_STRUCT`;case 46:return`EDGE_STATE`;case 47:return`OPEN_IN_STRUCT`;case 48:break;case 49:return`MEMBER`;case 50:return 83;case 51:return 75;case 52:return 76;case 53:return 78;case 54:return 54;case 55:return 56;case 56:return 46;case 57:return 47;case 58:return 81;case 59:this.popState();break;case 60:return`GENERICTYPE`;case 61:this.begin(`generic`);break;case 62:this.popState();break;case 63:return`BQUOTE_STR`;case 64:this.begin(`bqstring`);break;case 65:return 77;case 66:return 77;case 67:return 77;case 68:return 77;case 69:return 69;case 70:return 69;case 71:return 71;case 72:return 71;case 73:return 70;case 74:return 68;case 75:return 72;case 76:return 73;case 77:return 74;case 78:return 22;case 79:return 44;case 80:return 100;case 81:return 18;case 82:return`PLUS`;case 83:return 87;case 84:return 61;case 85:return 89;case 86:return 89;case 87:return 90;case 88:return`EQUALS`;case 89:return`EQUALS`;case 90:return 60;case 91:return 12;case 92:return 14;case 93:return`PUNCTUATION`;case 94:return 86;case 95:return 102;case 96:return 50;case 97:return 50;case 98:return 9}},`anonymous`),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:\[\*\])/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:["])/,/^(?:[^"]*)/,/^(?:["])/,/^(?:style\b)/,/^(?:classDef\b)/,/^(?:namespace\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[{])/,/^(?:[}])/,/^(?:[}])/,/^(?:$)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:\[\*\])/,/^(?:class\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[}])/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\[\*\])/,/^(?:[{])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:note for\b)/,/^(?:note\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:href\b)/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:~)/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:[`])/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:\s*\(\))/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?::)/,/^(?:,)/,/^(?:#)/,/^(?:#)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:\[)/,/^(?:\])/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:\s)/,/^(?:$)/],conditions:{"namespace-body":{rules:[26,29,34,35,36,37,38,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},namespace:{rules:[26,29,30,31,32,33,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},"class-body":{rules:[26,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},class:{rules:[26,40,41,42,43,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr_multiline:{rules:[11,12,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr:{rules:[9,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_title:{rules:[7,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_args:{rules:[22,23,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_name:{rules:[19,20,21,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},href:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},struct:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},generic:{rules:[26,50,51,52,53,54,55,56,57,58,59,60,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},bqstring:{rules:[26,50,51,52,53,54,55,56,57,58,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},string:{rules:[24,25,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,26,27,28,29,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98],inclusive:!0}}}})();function ce(){this.yy={}}return n(ce,`Parser`),ce.prototype=se,se.Parser=ce,new ce})();D.parser=D;var O=D,k=[`#`,`+`,`~`,`-`,``],A=class{static{n(this,`ClassMember`)}constructor(e,t){this.memberType=t,this.visibility=``,this.classifier=``,this.text=``;let n=m(e,f());this.parseMember(n)}getDisplayDetails(){let e=this.visibility+i(this.id);this.memberType===`method`&&(e+=`(${i(this.parameters.trim())})`,this.returnType&&(e+=` : `+i(this.returnType))),e=e.trim();let t=this.parseClassifier();return{displayText:e,cssStyle:t}}parseMember(e){let t=``;if(this.memberType===`method`){let n=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(e);if(n){let e=n[1]?n[1].trim():``;if(k.includes(e)&&(this.visibility=e),this.id=n[2],this.parameters=n[3]?n[3].trim():``,t=n[4]?n[4].trim():``,this.returnType=n[5]?n[5].trim():``,t===``){let e=this.returnType.substring(this.returnType.length-1);/[$*]/.exec(e)&&(t=e,this.returnType=this.returnType.substring(0,this.returnType.length-1))}}}else{let n=e.length,r=e.substring(0,1),i=e.substring(n-1);k.includes(r)&&(this.visibility=r),/[$*]/.exec(i)&&(t=i),this.id=e.substring(this.visibility===``?0:1,t===``?n:n-1)}this.classifier=t,this.id=this.id.startsWith(` `)?` `+this.id.trim():this.id.trim();let n=`${this.visibility?`\\`+this.visibility:``}${i(this.id)}${this.memberType===`method`?`(${i(this.parameters)})${this.returnType?` : `+i(this.returnType):``}`:``}`;this.text=n.replaceAll(`<`,`<`).replaceAll(`>`,`>`),this.text.startsWith(`\\<`)&&(this.text=this.text.replace(`\\<`,`~`))}parseClassifier(){switch(this.classifier){case`*`:return`font-style:italic;`;case`$`:return`text-decoration:underline;`;default:return``}}},j=`classId-`,M=0,N=n(e=>c.sanitizeText(e,f()),`sanitizeText`),P=class i{constructor(){this.relations=[],this.classes=new Map,this.styleClasses=new Map,this.notes=new Map,this.interfaces=[],this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId=``,this.functions=[],this.lineType={LINE:0,DOTTED_LINE:1},this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3,LOLLIPOP:4},this.setupToolTips=n(e=>{let n=w();t(e).select(`svg`).selectAll(`g`).filter(function(){return t(this).attr(`title`)!==null}).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(!i)return;let a=e.currentTarget.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.html(l.sanitize(i)).style(`left`,`${window.scrollX+a.left+a.width/2}px`).style(`top`,`${window.scrollY+a.bottom+4}px`),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})},`setupToolTips`),this.direction=`TB`,this.setAccTitle=a,this.getAccTitle=p,this.setAccDescription=r,this.getAccDescription=u,this.setDiagramTitle=s,this.getDiagramTitle=d,this.getConfig=n(()=>f().class,`getConfig`),this.functions.push(this.setupToolTips.bind(this)),this.clear(),this.addRelation=this.addRelation.bind(this),this.addClassesToNamespace=this.addClassesToNamespace.bind(this),this.addNamespace=this.addNamespace.bind(this),this.popNamespace=this.popNamespace.bind(this),this.setCssClass=this.setCssClass.bind(this),this.addMembers=this.addMembers.bind(this),this.addClass=this.addClass.bind(this),this.setClassLabel=this.setClassLabel.bind(this),this.addAnnotation=this.addAnnotation.bind(this),this.addMember=this.addMember.bind(this),this.cleanupLabel=this.cleanupLabel.bind(this),this.addNote=this.addNote.bind(this),this.defineClass=this.defineClass.bind(this),this.setDirection=this.setDirection.bind(this),this.setLink=this.setLink.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.clear=this.clear.bind(this),this.setTooltip=this.setTooltip.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setCssStyle=this.setCssStyle.bind(this)}static{n(this,`ClassDB`)}splitClassNameAndType(e){let t=c.sanitizeText(e,f()),n=``,r=t;if(t.indexOf(`~`)>0){let e=t.split(`~`);r=N(e[0]),n=N(e[1])}return{className:r,type:n}}setClassLabel(e,t){let n=c.sanitizeText(e,f());t&&=N(t);let{className:r}=this.splitClassNameAndType(n);this.classes.get(r).label=t,this.classes.get(r).text=`${t}${this.classes.get(r).type?`<${this.classes.get(r).type}>`:``}`}addClass(e){let t=c.sanitizeText(e,f()),{className:n,type:r}=this.splitClassNameAndType(t);if(this.classes.has(n))return;let i=c.sanitizeText(n,f());this.classes.set(i,{id:i,type:r,label:i,text:`${i}${r?`<${r}>`:``}`,shape:`classBox`,cssClasses:`default`,methods:[],members:[],annotations:[],styles:[],domId:j+i+`-`+M}),M++}addInterface(e,t){let n={id:`interface${this.interfaces.length}`,label:e,classId:t};this.interfaces.push(n)}setDiagramId(e){this.diagramId=e}lookUpDomId(e){let t=c.sanitizeText(e,f());if(this.classes.has(t)){let e=this.classes.get(t).domId;return this.diagramId?`${this.diagramId}-${e}`:e}throw Error(`Class not found: `+t)}clear(){this.relations=[],this.classes=new Map,this.notes=new Map,this.interfaces=[],this.functions=[],this.functions.push(this.setupToolTips.bind(this)),this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId=``,this.direction=`TB`,o()}getClass(e){return this.classes.get(e)}getClasses(){return this.classes}getRelations(){return this.relations}getNote(e){let t=typeof e==`number`?`note${e}`:e;return this.notes.get(t)}getNotes(){return this.notes}addRelation(t){e.debug(`Adding relation: `+JSON.stringify(t));let n=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];t.relation.type1===this.relationType.LOLLIPOP&&!n.includes(t.relation.type2)?(this.addClass(t.id2),this.addInterface(t.id1,t.id2),t.id1=`interface${this.interfaces.length-1}`):t.relation.type2===this.relationType.LOLLIPOP&&!n.includes(t.relation.type1)?(this.addClass(t.id1),this.addInterface(t.id2,t.id1),t.id2=`interface${this.interfaces.length-1}`):(this.addClass(t.id1),this.addClass(t.id2)),t.id1=this.splitClassNameAndType(t.id1).className,t.id2=this.splitClassNameAndType(t.id2).className,t.relationTitle1=c.sanitizeText(t.relationTitle1.trim(),f()),t.relationTitle2=c.sanitizeText(t.relationTitle2.trim(),f()),this.relations.push(t)}addAnnotation(e,t){let n=this.splitClassNameAndType(e).className;this.classes.get(n).annotations.push(t)}addMember(e,t){this.addClass(e);let n=this.splitClassNameAndType(e).className,r=this.classes.get(n);if(typeof t==`string`){let e=t.trim();e.startsWith(`<<`)&&e.endsWith(`>>`)?r.annotations.push(N(e.substring(2,e.length-2))):e.indexOf(`)`)>0?r.methods.push(new A(e,`method`)):e&&r.members.push(new A(e,`attribute`))}}addMembers(e,t){Array.isArray(t)&&(t.reverse(),t.forEach(t=>this.addMember(e,t)))}addNote(e,t){let n=this.notes.size,r={id:`note${n}`,class:t,text:e,index:n};return this.notes.set(r.id,r),r.id}cleanupLabel(e){return e.startsWith(`:`)&&(e=e.substring(1)),N(e.trim())}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=e;/\d/.exec(e[0])&&(n=j+n),n=this.splitClassNameAndType(n).className;let r=this.classes.get(n);r&&(r.cssClasses+=` `+t)})}defineClass(e,t){for(let n of e){let e=this.styleClasses.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.styleClasses.set(n,e)),t&&t.forEach(t=>{if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.classes.forEach(e=>{e.cssClasses.includes(n)&&e.styles.push(...t.flatMap(e=>e.split(`,`)))})}}setTooltip(e,t){e.split(`,`).forEach(e=>{if(t!==void 0){let n=this.splitClassNameAndType(e).className,r=this.classes.get(n);r&&(r.tooltip=N(t))}})}getTooltip(e,t){return t&&this.namespaces.has(t)?this.namespaces.get(t).classes.get(e).tooltip:this.classes.get(e).tooltip}setLink(e,t,n){let r=f();e.split(`,`).forEach(e=>{let i=e;/\d/.exec(e[0])&&(i=j+i),i=this.splitClassNameAndType(i).className;let a=this.classes.get(i);a&&(a.link=g.formatUrl(t,r),a.linkTarget=r.securityLevel===`sandbox`?`_top`:typeof n==`string`?N(n):`_blank`)}),this.setCssClass(e,`clickable`)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFunc(e,t,n);let r=this.splitClassNameAndType(e).className,i=this.classes.get(r);i&&(i.haveCallback=!0)}),this.setCssClass(e,`clickable`)}setClickFunc(e,t,n){let r=c.sanitizeText(e,f());if(f().securityLevel!==`loose`||t===void 0)return;let i=this.splitClassNameAndType(r).className;if(this.classes.has(i)){let e=[];if(typeof n==`string`){e=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t{let n=this.lookUpDomId(i),r=document.querySelector(`[id="${n}"]`);r!==null&&r.addEventListener(`click`,()=>{g.runFunc(t,...e)},!1)})}}bindFunctions(e){this.functions.forEach(t=>{t(e)})}escapeHtml(e){return e.replace(/&/g,`&`).replace(//g,`>`).replace(/"/g,`"`).replace(/'/g,`'`)}getDirection(){return this.direction}setDirection(e){this.direction=e}static resolveQualifiedId(e,t){let n=t.at(-1);return n?`${n}.${e}`:e}static getAncestorIds(e){let t=e.split(`.`),n=Array(t.length);n[0]=t[0];for(let e=1;e0?a[e-1]:void 0,o=e===a.length-1,s=o&&t?t:r[e];this.namespaces.has(n)?o&&(this.namespaces.get(n).explicit=!0):this.namespaces.set(n,this.createNamespaceNode(n,s,i,o)),i&&this.linkParentChild(i,n)}return n}popNamespace(){this.namespaceStack.pop()}getNamespace(e){return this.namespaces.get(e)}getNamespaces(){return this.namespaces}addClassesToNamespace(e,t,n){if(this.namespaces.has(e)){for(let n of t){let{className:t}=this.splitClassNameAndType(n),r=this.getClass(t);r.parent=e,this.namespaces.get(e).classes.set(t,r)}for(let t of n){let n=this.getNote(t);n.parent=e,this.namespaces.get(e).notes.set(t,n)}}}setCssStyle(e,t){let n=this.classes.get(e);if(!(!t||!n))for(let e of t)e.includes(`,`)?n.styles.push(...e.split(`,`)):n.styles.push(e)}getArrowMarker(e){let t;switch(e){case 0:t=`aggregation`;break;case 1:t=`extension`;break;case 2:t=`composition`;break;case 3:t=`dependency`;break;case 4:t=`lollipop`;break;default:t=`none`}return t}resolveExplicitAncestor(e){let t=e;for(;t;){let e=this.namespaces.get(t);if(!e)return;if(e.explicit)return t;t=e.parent}}getData(){let e=[],t=[],n=f(),r=n.class?.hierarchicalNamespaces??!0;for(let t of this.namespaces.values()){if(!r&&!t.explicit)continue;let i={id:t.id,label:r?t.label:t.id,isGroup:!0,padding:n.class.padding??16,shape:`rect`,cssStyles:[],look:n.look,parentId:r?t.parent:void 0};e.push(i)}let i=0;for(let t of this.classes.values()){let a=r?t.parent:this.resolveExplicitAncestor(t.parent),o={...t,type:void 0,isGroup:!1,parentId:a,look:n.look,colorIndex:i++};e.push(o)}for(let i of this.notes.values()){let a=r?i.parent:this.resolveExplicitAncestor(i.parent),o={id:i.id,label:i.text,isGroup:!1,shape:`note`,padding:n.class.padding??6,cssStyles:[`text-align: left`,`white-space: nowrap`,`fill: ${n.themeVariables.noteBkgColor}`,`stroke: ${n.themeVariables.noteBorderColor}`],look:n.look,parentId:a,labelType:`markdown`};e.push(o);let s=this.classes.get(i.class)?.id;if(s){let e={id:`edgeNote${i.index}`,start:i.id,end:s,type:`normal`,thickness:`normal`,classes:`relation`,arrowTypeStart:`none`,arrowTypeEnd:`none`,arrowheadStyle:``,labelStyle:[``],style:[`fill: none`],pattern:`dotted`,look:n.look};t.push(e)}}for(let t of this.interfaces){let r={id:t.id,label:t.label,isGroup:!1,shape:`rect`,cssStyles:[`opacity: 0;`],look:n.look};e.push(r)}let a=0;for(let e of this.relations){a++;let r={id:h(e.id1,e.id2,{prefix:`id`,counter:a}),start:e.id1,end:e.id2,type:`normal`,label:e.title,labelpos:`c`,thickness:`normal`,classes:`relation`,arrowTypeStart:this.getArrowMarker(e.relation.type1),arrowTypeEnd:this.getArrowMarker(e.relation.type2),startLabelRight:e.relationTitle1===`none`?``:e.relationTitle1,endLabelLeft:e.relationTitle2===`none`?``:e.relationTitle2,arrowheadStyle:``,labelStyle:[`display: inline-block`],style:e.style||``,pattern:e.relation.lineType==1?`dashed`:`solid`,look:n.look,labelType:`markdown`};t.push(r)}return{nodes:e,edges:t,other:{},config:n,direction:this.getDirection()}}},F=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!_(t,r))return``;let i=y(e.look),a=b(n),o=``;for(let t=0;t{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`)},styles:n(e=>`${F(e)} + g.classGroup text { + fill: ${e.nodeBorder||e.classText}; + stroke: none; + font-family: ${e.fontFamily}; + font-size: 10px; + + .title { + font-weight: bolder; + } + +} + + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + +.nodeLabel, .edgeLabel { + color: ${e.classText}; +} + +.noteLabel .nodeLabel, .noteLabel .edgeLabel { + color: ${e.noteTextColor}; +} +.edgeLabel .label rect { + fill: ${e.mainBkg}; +} +.label text { + fill: ${e.classText}; +} + +.labelBkg { + background: ${e.mainBkg}; +} +.edgeLabel .label span { + background: ${e.mainBkg}; +} + +.classTitle { + font-weight: bolder; +} +.node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth}; + } + + +.divider { + stroke: ${e.nodeBorder}; + stroke-width: 1; +} + +g.clickable { + cursor: pointer; +} + +g.classGroup rect { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; +} + +g.classGroup line { + stroke: ${e.nodeBorder}; + stroke-width: 1; +} + +.classLabel .box { + stroke: none; + stroke-width: 0; + fill: ${e.mainBkg}; + opacity: 0.5; +} + +.classLabel .label { + fill: ${e.nodeBorder}; + font-size: 10px; +} + +.relation { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth}; + fill: none; +} + +.dashed-line{ + stroke-dasharray: 3; +} + +.dotted-line{ + stroke-dasharray: 1 2; +} + +[id$="-compositionStart"], .composition { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-compositionEnd"], .composition { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-dependencyStart"], .dependency { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-dependencyEnd"], .dependency { + fill: ${e.lineColor} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-extensionStart"], .extension { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-extensionEnd"], .extension { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-aggregationStart"], .aggregation { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-aggregationEnd"], .aggregation { + fill: transparent !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-lollipopStart"], .lollipop { + fill: ${e.mainBkg} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +[id$="-lollipopEnd"], .lollipop { + fill: ${e.mainBkg} !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; +} + +.edgeTerminals { + font-size: 11px; + line-height: initial; +} + +.classTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; +} + +.edgeLabel[data-look="neo"] { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; +} + ${C()} +`,`getStyles`),init:n(e=>{e.class||={},e.class.arrowMarkerAbsolute=e.arrowMarkerAbsolute},`init`)};export{I as diagram}; \ No newline at end of file diff --git a/www/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js b/www/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js new file mode 100644 index 0000000..3affc47 --- /dev/null +++ b/www/assets/cose-bilkent-JH36ORCC-BtJFQFL9.js @@ -0,0 +1 @@ +import{_ as e,m as t,p as n,y as r}from"./src-D_iIdUkB.js";import{n as i}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{t as a}from"./cytoscape.esm-CECbKnxF.js";var o=e(((e,t)=>{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r():typeof define==`function`&&define.amd?define([],r):typeof e==`object`?e.layoutBase=r():n.layoutBase=r()})(e,function(){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=26)})([(function(e,t,n){function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,e.exports=r}),(function(e,t,n){var r=n(2),i=n(8),a=n(9);function o(e,t,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=e,this.target=t}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];o.prototype.getSource=function(){return this.source},o.prototype.getTarget=function(){return this.target},o.prototype.isInterGraph=function(){return this.isInterGraph},o.prototype.getLength=function(){return this.length},o.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},o.prototype.getBendpoints=function(){return this.bendpoints},o.prototype.getLca=function(){return this.lca},o.prototype.getSourceInLca=function(){return this.sourceInLca},o.prototype.getTargetInLca=function(){return this.targetInLca},o.prototype.getOtherEnd=function(e){if(this.source===e)return this.target;if(this.target===e)return this.source;throw`Node is not incident with this edge`},o.prototype.getOtherEndInGraph=function(e,t){for(var n=this.getOtherEnd(e),r=t.getGraphManager().getRoot();;){if(n.getOwner()==t)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},o.prototype.updateLength=function(){var e=[,,,,];this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),e),this.isOverlapingSourceAndTarget||(this.lengthX=e[0]-e[2],this.lengthY=e[1]-e[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},o.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},e.exports=o}),(function(e,t,n){function r(e){this.vGraphObject=e}e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(13),o=n(0),s=n(16),c=n(4);function l(e,t,n,o){n==null&&o==null&&(o=t),r.call(this,o),e.graphManager!=null&&(e=e.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=o,this.edges=[],this.graphManager=e,this.rect=n!=null&&t!=null?new a(t.x,t.y,n.width,n.height):new a}for(var u in l.prototype=Object.create(r.prototype),r)l[u]=r[u];l.prototype.getEdges=function(){return this.edges},l.prototype.getChild=function(){return this.child},l.prototype.getOwner=function(){return this.owner},l.prototype.getWidth=function(){return this.rect.width},l.prototype.setWidth=function(e){this.rect.width=e},l.prototype.getHeight=function(){return this.rect.height},l.prototype.setHeight=function(e){this.rect.height=e},l.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},l.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},l.prototype.getCenter=function(){return new c(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},l.prototype.getLocation=function(){return new c(this.rect.x,this.rect.y)},l.prototype.getRect=function(){return this.rect},l.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},l.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},l.prototype.setRect=function(e,t){this.rect.x=e.x,this.rect.y=e.y,this.rect.width=t.width,this.rect.height=t.height},l.prototype.setCenter=function(e,t){this.rect.x=e-this.rect.width/2,this.rect.y=t-this.rect.height/2},l.prototype.setLocation=function(e,t){this.rect.x=e,this.rect.y=t},l.prototype.moveBy=function(e,t){this.rect.x+=e,this.rect.y+=t},l.prototype.getEdgeListToNode=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.target==e){if(r.source!=n)throw`Incorrect edge source!`;t.push(r)}}),t},l.prototype.getEdgesBetween=function(e){var t=[],n=this;return n.edges.forEach(function(r){if(r.source!=n&&r.target!=n)throw`Incorrect edge source and/or target`;(r.target==e||r.source==e)&&t.push(r)}),t},l.prototype.getNeighborsList=function(){var e=new Set,t=this;return t.edges.forEach(function(n){if(n.source==t)e.add(n.target);else{if(n.target!=t)throw`Incorrect incidency!`;e.add(n.source)}}),e},l.prototype.withChildren=function(){var e=new Set,t,n;if(e.add(this),this.child!=null)for(var r=this.child.getNodes(),i=0;it&&(this.rect.x-=(this.labelWidth-t)/2,this.setWidth(this.labelWidth)),this.labelHeight>n&&(this.labelPos==`center`?this.rect.y-=(this.labelHeight-n)/2:this.labelPos==`top`&&(this.rect.y-=this.labelHeight-n),this.setHeight(this.labelHeight))}}},l.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw`assert failed`;return this.inclusionTreeDepth},l.prototype.transform=function(e){var t=this.rect.x;t>o.WORLD_BOUNDARY?t=o.WORLD_BOUNDARY:t<-o.WORLD_BOUNDARY&&(t=-o.WORLD_BOUNDARY);var n=this.rect.y;n>o.WORLD_BOUNDARY?n=o.WORLD_BOUNDARY:n<-o.WORLD_BOUNDARY&&(n=-o.WORLD_BOUNDARY);var r=new c(t,n),i=e.inverseTransformPoint(r);this.setLocation(i.x,i.y)},l.prototype.getLeft=function(){return this.rect.x},l.prototype.getRight=function(){return this.rect.x+this.rect.width},l.prototype.getTop=function(){return this.rect.y},l.prototype.getBottom=function(){return this.rect.y+this.rect.height},l.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},e.exports=l}),(function(e,t,n){function r(e,t){e==null&&t==null?(this.x=0,this.y=0):(this.x=e,this.y=t)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(e){this.x=e},r.prototype.setY=function(e){this.y=e},r.prototype.getDifference=function(e){return new DimensionD(this.x-e.x,this.y-e.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(e){return this.x+=e.width,this.y+=e.height,this},e.exports=r}),(function(e,t,n){var r=n(2),i=n(10),a=n(0),o=n(6),s=n(3),c=n(1),l=n(13),u=n(12),d=n(11);function f(e,t,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=e,t!=null&&t instanceof o?this.graphManager=t:t!=null&&t instanceof Layout&&(this.graphManager=t.graphManager)}for(var p in f.prototype=Object.create(r.prototype),r)f[p]=r[p];f.prototype.getNodes=function(){return this.nodes},f.prototype.getEdges=function(){return this.edges},f.prototype.getGraphManager=function(){return this.graphManager},f.prototype.getParent=function(){return this.parent},f.prototype.getLeft=function(){return this.left},f.prototype.getRight=function(){return this.right},f.prototype.getTop=function(){return this.top},f.prototype.getBottom=function(){return this.bottom},f.prototype.isConnected=function(){return this.isConnected},f.prototype.add=function(e,t,n){if(t==null&&n==null){var r=e;if(this.graphManager==null)throw`Graph has no graph mgr!`;if(this.getNodes().indexOf(r)>-1)throw`Node already in graph!`;return r.owner=this,this.getNodes().push(r),r}var i=e;if(!(this.getNodes().indexOf(t)>-1&&this.getNodes().indexOf(n)>-1))throw`Source or target not in graph!`;if(t.owner!=n.owner||t.owner!=this)throw`Both owners must be this graph!`;return t.owner==n.owner?(i.source=t,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),t.edges.push(i),n!=t&&n.edges.push(i),i):null},f.prototype.remove=function(e){var t=e;if(e instanceof s){if(t==null)throw`Node is null!`;if(t.owner==null||t.owner!=this)throw`Owner graph is invalid!`;if(this.graphManager==null)throw`Owner graph manager is invalid!`;for(var n=t.edges.slice(),r,i=n.length,a=0;a-1&&u>-1))throw`Source and/or target doesn't know this edge!`;r.source.edges.splice(l,1),r.target!=r.source&&r.target.edges.splice(u,1);var o=r.source.owner.getEdges().indexOf(r);if(o==-1)throw`Not in owner's edge list!`;r.source.owner.getEdges().splice(o,1)}},f.prototype.updateLeftTop=function(){for(var e=i.MAX_VALUE,t=i.MAX_VALUE,n,r,a,o=this.getNodes(),s=o.length,c=0;cn&&(e=n),t>r&&(t=r)}return e==i.MAX_VALUE?null:(a=o[0].getParent().paddingLeft==null?this.margin:o[0].getParent().paddingLeft,this.left=t-a,this.top=e-a,new u(this.left,this.top))},f.prototype.updateBounds=function(e){for(var t=i.MAX_VALUE,n=-i.MAX_VALUE,r=i.MAX_VALUE,a=-i.MAX_VALUE,o,s,c,u,d,f=this.nodes,p=f.length,m=0;mo&&(t=o),nc&&(r=c),ao&&(t=o),nc&&(r=c),a=this.nodes.length){var c=0;n.forEach(function(t){t.owner==e&&c++}),c==this.nodes.length&&(this.isConnected=!0)}},e.exports=f}),(function(e,t,n){var r,i=n(1);function a(e){r=n(5),this.layout=e,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var e=this.layout.newGraph(),t=this.layout.newNode(null),n=this.add(e,t);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(e,t,n,r,i){if(n==null&&r==null&&i==null){if(e==null)throw`Graph is null!`;if(t==null)throw`Parent node is null!`;if(this.graphs.indexOf(e)>-1)throw`Graph already in this graph mgr!`;if(this.graphs.push(e),e.parent!=null)throw`Already has a parent!`;if(t.child!=null)throw`Already has a child!`;return e.parent=t,t.child=e,e}i=n,r=t,n=e;var a=r.getOwner(),o=i.getOwner();if(a==null||a.getGraphManager()!=this)throw`Source not in this graph mgr!`;if(o==null||o.getGraphManager()!=this)throw`Target not in this graph mgr!`;if(a==o)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw`Edge already in inter-graph edge list!`;if(this.edges.push(n),n.source==null||n.target==null)throw`Edge source and/or target is null!`;if(n.source.edges.indexOf(n)!=-1||n.target.edges.indexOf(n)!=-1)throw`Edge already in source and/or target incidency list!`;return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(e){if(e instanceof r){var t=e;if(t.getGraphManager()!=this)throw`Graph not in this graph mgr`;if(!(t==this.rootGraph||t.parent!=null&&t.parent.graphManager==this))throw`Invalid parent node!`;var n=[];n=n.concat(t.getEdges());for(var a,o=n.length,s=0;s=t.getRight()?n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight()):t.getX()<=e.getX()&&t.getRight()>=e.getRight()&&(n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight())),e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()?n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()):t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()&&(n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()));var a=Math.abs((t.getCenterY()-e.getCenterY())/(t.getCenterX()-e.getCenterX()));t.getCenterY()===e.getCenterY()&&t.getCenterX()===e.getCenterX()&&(a=1);var o=a*n[0],s=n[1]/a;n[0]o)return n[0]=r,n[1]=c,n[2]=a,n[3]=y,!1;if(ia)return n[0]=s,n[1]=i,n[2]=_,n[3]=o,!1;if(ra?(n[0]=u,n[1]=d,C=!0):(n[0]=l,n[1]=c,C=!0):T===D&&(r>a?(n[0]=s,n[1]=c,C=!0):(n[0]=f,n[1]=d,C=!0)),-E===D?a>r?(n[2]=v,n[3]=y,w=!0):(n[2]=_,n[3]=g,w=!0):E===D&&(a>r?(n[2]=h,n[3]=g,w=!0):(n[2]=b,n[3]=y,w=!0)),C&&w)return!1;if(r>a?i>o?(O=this.getCardinalDirection(T,D,4),k=this.getCardinalDirection(E,D,2)):(O=this.getCardinalDirection(-T,D,3),k=this.getCardinalDirection(-E,D,1)):i>o?(O=this.getCardinalDirection(-T,D,1),k=this.getCardinalDirection(-E,D,3)):(O=this.getCardinalDirection(T,D,2),k=this.getCardinalDirection(E,D,4)),!C)switch(O){case 1:j=c,A=r+-m/D,n[0]=A,n[1]=j;break;case 2:A=f,j=i+p*D,n[0]=A,n[1]=j;break;case 3:j=d,A=r+m/D,n[0]=A,n[1]=j;break;case 4:A=u,j=i+-p*D,n[0]=A,n[1]=j}if(!w)switch(k){case 1:N=g,M=a+-S/D,n[2]=M,n[3]=N;break;case 2:M=b,N=o+x*D,n[2]=M,n[3]=N;break;case 3:N=y,M=a+S/D,n[2]=M,n[3]=N;break;case 4:M=v,N=o+-x*D,n[2]=M,n[3]=N}}return!1},i.getCardinalDirection=function(e,t,n){return e>t?n:1+n%4},i.getIntersection=function(e,t,n,i){if(i==null)return this.getIntersection2(e,t,n);var a=e.x,o=e.y,s=t.x,c=t.y,l=n.x,u=n.y,d=i.x,f=i.y,p=void 0,m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0;return h=c-o,_=a-s,y=s*o-a*c,g=f-u,v=l-d,b=d*u-l*f,x=h*v-g*_,x===0?null:(p=(_*b-v*y)/x,m=(g*y-h*b)/x,new r(p,m))},i.angleOfVector=function(e,t,n,r){var i=void 0;return e===n?i=r0?1:e<0?-1:0},r.floor=function(e){return e<0?Math.ceil(e):Math.floor(e)},r.ceil=function(e){return e<0?Math.floor(e):Math.ceil(e)},e.exports=r}),(function(e,t,n){function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,e.exports=r}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n0&&t;){for(s.push(l[0]);s.length>0&&t;){var u=s[0];s.splice(0,1),o.add(u);for(var d=u.getEdges(),a=0;a-1&&l.splice(h,1)}o=new Set,c=new Map}}return e},f.prototype.createDummyNodesForBendpoints=function(e){for(var t=[],n=e.source,r=this.graphManager.calcLowestCommonAncestor(e.source,e.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&t.splice(d,1),s.getNeighborsList().forEach(function(e){if(n.indexOf(e)<0){var t=r.get(e)-1;t==1&&l.push(e),r.set(e,t)}})}n=n.concat(l),(t.length==1||t.length==2)&&(i=!0,a=t[0])}return a},f.prototype.setGraphManager=function(e){this.graphManager=e},e.exports=f}),(function(e,t,n){function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=Math.sin(r.seed++)*1e4,r.x-Math.floor(r.x)},e.exports=r}),(function(e,t,n){var r=n(4);function i(e,t){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(e){this.lworldExtX=e},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(e){this.lworldExtY=e},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},i.prototype.transformX=function(e){var t=0,n=this.lworldExtX;return n!=0&&(t=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/n),t},i.prototype.transformY=function(e){var t=0,n=this.lworldExtY;return n!=0&&(t=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/n),t},i.prototype.inverseTransformX=function(e){var t=0,n=this.ldeviceExtX;return n!=0&&(t=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/n),t},i.prototype.inverseTransformY=function(e){var t=0,n=this.ldeviceExtY;return n!=0&&(t=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/n),t},i.prototype.inverseTransformPoint=function(e){return new r(this.inverseTransformX(e.x),this.inverseTransformY(e.y))},e.exports=i}),(function(e,t,n){function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);ta.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*a.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-a.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT_INCREMENTAL):(this.coolingFactor=e>a.ADAPTATION_LOWER_NODE_LIMIT?Math.max(a.COOLING_ADAPTATION_FACTOR,1-(e-a.ADAPTATION_LOWER_NODE_LIMIT)/(a.ADAPTATION_UPPER_NODE_LIMIT-a.ADAPTATION_LOWER_NODE_LIMIT)*(1-a.COOLING_ADAPTATION_FACTOR)):1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=a.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var e=this.getAllEdges(),t,n=0;n0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n,r,i,o,s=this.getAllNodes(),c;if(this.useFRGridVariant)for(this.totalIterations%a.GRID_CALCULATION_CHECK_PERIOD==1&&e&&this.updateGrid(),c=new Set,n=0;nc||s>c)&&(e.gravitationForceX=-this.gravityConstant*i,e.gravitationForceY=-this.gravityConstant*a)):(c=t.getEstimatedSize()*this.compoundGravityRangeFactor,(o>c||s>c)&&(e.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,e.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant))},l.prototype.isConverged=function(){var e,t=!1;return this.totalIterations>this.maxIterations/3&&(t=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),e=this.totalDisplacement=c.length||u>=c[0].length)){for(var d=0;de}}]),e}()}),(function(e,t,n){var r=function(){function e(e,t){for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:1,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;i(this,e),this.sequence1=t,this.sequence2=n,this.match_score=r,this.mismatch_penalty=a,this.gap_penalty=o,this.iMax=t.length+1,this.jMax=n.length+1,this.grid=Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===e&&r.callback===t&&this.listeners.splice(n,1)}},i.emit=function(e,t){for(var n=0;n{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(o()):typeof define==`function`&&define.amd?define([`layout-base`],r):typeof e==`object`?e.coseBase=r(o()):n.coseBase=r(n.layoutBase)})(e,function(e){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=7)})([(function(t,n){t.exports=e}),(function(e,t,n){var r=n(0).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TREE_REDUCTION_ON_INCREMENTAL=!1,e.exports=i}),(function(e,t,n){var r=n(0).FDLayoutEdge;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).LGraph;function i(e,t,n){r.call(this,e,t,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).LGraphManager;function i(e){r.call(this,e)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];e.exports=i}),(function(e,t,n){var r=n(0).FDLayoutNode,i=n(0).IMath;function a(e,t,n,i){r.call(this,e,t,n,i)}for(var o in a.prototype=Object.create(r.prototype),r)a[o]=r[o];a.prototype.move=function(){var e=this.graphManager.getLayout();this.displacementX=e.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=e.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementX=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>e.coolingFactor*e.maxNodeDisplacement&&(this.displacementY=e.coolingFactor*e.maxNodeDisplacement*i.sign(this.displacementY)),this.child==null||this.child.getNodes().length==0?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),e.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},a.prototype.propogateDisplacementToChildren=function(e,t){for(var n=this.getChild().getNodes(),r,i=0;i0)this.positionNodesRadially(e);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}else if(c.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(n)}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},v.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}if(this.totalIterations%l.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0}this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-this.coolingCycle**+(Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0){if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),t=this.nodesWithGravity.filter(function(t){return e.has(t)});this.graphManager.setAllNodesToApplyGravitation(t),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0}this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},v.prototype.getPositionsData=function(){for(var e=this.graphManager.getAllNodes(),t={},n=0;n1){var s;for(s=0;sr&&(r=Math.floor(o.y)),a=Math.floor(o.x+c.DEFAULT_COMPONENT_SEPERATION)}this.transform(new f(u.WORLD_CENTER_X-o.x/2,u.WORLD_CENTER_Y-o.y/2))},v.radialLayout=function(e,t,n){var r=Math.max(this.maxDiagonalInTree(e),c.DEFAULT_RADIAL_SEPARATION);v.branchRadialLayout(t,null,0,359,0,r);var i=g.calculateBounds(e),a=new _;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var o=0;o1;){var _=g[0];g.splice(0,1);var y=u.indexOf(_);y>=0&&u.splice(y,1),p--,d--}m=t==null?0:(u.indexOf(g[0])+1)%p;for(var b=Math.abs(r-n)/d,x=m;f!=d;x=++x%p){var S=u[x].getOtherEnd(e);if(S!=t){var C=(n+f*b)%360,w=(C+b)%360;v.branchRadialLayout(S,e,C,w,i+a,a),f++}}},v.maxDiagonalInTree=function(e){for(var t=m.MIN_VALUE,n=0;nt&&(t=r)}return t},v.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},v.prototype.groupZeroDegreeMembers=function(){var e=this,t={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r=`DummyCompound_`+n;e.memberGroups[r]=t[n];var i=t[n][0].getParent(),a=new o(e.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,e.idToDummyNode[r]=a;var s=e.getGraphManager().add(e.newGraph(),a),c=i.getChild();c.add(a);for(var l=0;l=0;e--){var t=this.compoundOrder[e],n=t.id,r=t.paddingLeft,i=t.paddingTop;this.adjustLocations(this.tiledMemberPack[n],t.rect.x,t.rect.y,r,i)}},v.prototype.repopulateZeroDegreeMembers=function(){var e=this,t=this.tiledZeroDegreePack;Object.keys(t).forEach(function(n){var r=e.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop;e.adjustLocations(t[n],r.rect.x,r.rect.y,i,a)})},v.prototype.getToBeTiled=function(e){var t=e.id;if(this.toBeTiled[t]!=null)return this.toBeTiled[t];var n=e.getChild();if(n==null)return this.toBeTiled[t]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[t]=!1,!1;if(a.getChild()==null){this.toBeTiled[a.id]=!1;continue}if(!this.getToBeTiled(a))return this.toBeTiled[t]=!1,!1}return this.toBeTiled[t]=!0,!0},v.prototype.getNodeDegree=function(e){e.id;for(var t=e.getEdges(),n=0,r=0;rc&&(c=u.rect.height)}n+=c+e.verticalPadding}},v.prototype.tileCompoundMembers=function(e,t){var n=this;this.tiledMemberPack=[],Object.keys(e).forEach(function(r){var i=t[r];n.tiledMemberPack[r]=n.tileNodes(e[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height})},v.prototype.tileNodes=function(e,t){var n={rows:[],rowWidth:[],rowHeight:[],width:0,height:t,verticalPadding:c.TILING_PADDING_VERTICAL,horizontalPadding:c.TILING_PADDING_HORIZONTAL};e.sort(function(e,t){return e.rect.width*e.rect.height>t.rect.width*t.rect.height?-1:+(e.rect.width*e.rect.height0&&(a+=e.horizontalPadding),e.rowWidth[n]=a,e.width0&&(o+=e.verticalPadding);var s=0;o>e.rowHeight[n]&&(s=e.rowHeight[n],e.rowHeight[n]=o,s=e.rowHeight[n]-s),e.height+=s,e.rows[n].push(t)},v.prototype.getShortestRowIndex=function(e){for(var t=-1,n=Number.MAX_VALUE,r=0;rn&&(t=r,n=e.rowWidth[r]);return t},v.prototype.canAddHorizontal=function(e,t,n){var r=this.getShortestRowIndex(e);if(r<0)return!0;var i=e.rowWidth[r];if(i+e.horizontalPadding+t<=e.width)return!0;var a=0;e.rowHeight[r]0&&(a=n+e.verticalPadding-e.rowHeight[r]);var o=e.width-i>=t+e.horizontalPadding?(e.height+a)/(i+t+e.horizontalPadding):(e.height+a)/e.width;a=n+e.verticalPadding;var s=e.widtha&&t!=n){r.splice(-1,1),e.rows[n].push(i),e.rowWidth[t]=e.rowWidth[t]-a,e.rowWidth[n]=e.rowWidth[n]+a,e.width=e.rowWidth[instance.getLongestRowIndex(e)];for(var o=Number.MIN_VALUE,s=0;so&&(o=r[s].height);t>0&&(o+=e.verticalPadding);var c=e.rowHeight[t]+e.rowHeight[n];e.rowHeight[t]=o,e.rowHeight[n]0)for(var u=i;u<=a;u++)c[0]+=this.grid[u][o-1].length+this.grid[u][o].length-1;if(a0)for(var u=o;u<=s;u++)c[3]+=this.grid[i-1][u].length+this.grid[i][u].length-1;for(var d=m.MAX_VALUE,f,p,h=0;h{(function(n,r){typeof e==`object`&&typeof t==`object`?t.exports=r(s()):typeof define==`function`&&define.amd?define([`cose-base`],r):typeof e==`object`?e.cytoscapeCoseBilkent=r(s()):n.cytoscapeCoseBilkent=r(n.coseBase)})(e,function(e){return(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=1)})([(function(t,n){t.exports=e}),(function(e,t,n){var r=n(0).layoutBase.LayoutConstants,i=n(0).layoutBase.FDLayoutConstants,a=n(0).CoSEConstants,o=n(0).CoSELayout,s=n(0).CoSENode,c=n(0).layoutBase.PointD,l=n(0).layoutBase.DimensionD,u={ready:function(){},stop:function(){},quality:`default`,nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:`end`,animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function d(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n}function f(e){this.options=d(u,e),p(this.options)}var p=function(e){e.nodeRepulsion!=null&&(a.DEFAULT_REPULSION_STRENGTH=i.DEFAULT_REPULSION_STRENGTH=e.nodeRepulsion),e.idealEdgeLength!=null&&(a.DEFAULT_EDGE_LENGTH=i.DEFAULT_EDGE_LENGTH=e.idealEdgeLength),e.edgeElasticity!=null&&(a.DEFAULT_SPRING_STRENGTH=i.DEFAULT_SPRING_STRENGTH=e.edgeElasticity),e.nestingFactor!=null&&(a.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=e.nestingFactor),e.gravity!=null&&(a.DEFAULT_GRAVITY_STRENGTH=i.DEFAULT_GRAVITY_STRENGTH=e.gravity),e.numIter!=null&&(a.MAX_ITERATIONS=i.MAX_ITERATIONS=e.numIter),e.gravityRange!=null&&(a.DEFAULT_GRAVITY_RANGE_FACTOR=i.DEFAULT_GRAVITY_RANGE_FACTOR=e.gravityRange),e.gravityCompound!=null&&(a.DEFAULT_COMPOUND_GRAVITY_STRENGTH=i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=e.gravityCompound),e.gravityRangeCompound!=null&&(a.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=e.gravityRangeCompound),e.initialEnergyOnIncremental!=null&&(a.DEFAULT_COOLING_FACTOR_INCREMENTAL=i.DEFAULT_COOLING_FACTOR_INCREMENTAL=e.initialEnergyOnIncremental),r.QUALITY=e.quality==`draft`?0:e.quality==`proof`?2:1,a.NODE_DIMENSIONS_INCLUDE_LABELS=i.NODE_DIMENSIONS_INCLUDE_LABELS=r.NODE_DIMENSIONS_INCLUDE_LABELS=e.nodeDimensionsIncludeLabels,a.DEFAULT_INCREMENTAL=i.DEFAULT_INCREMENTAL=r.DEFAULT_INCREMENTAL=!e.randomize,a.ANIMATE=i.ANIMATE=r.ANIMATE=e.animate,a.TILE=e.tile,a.TILING_PADDING_VERTICAL=typeof e.tilingPaddingVertical==`function`?e.tilingPaddingVertical.call():e.tilingPaddingVertical,a.TILING_PADDING_HORIZONTAL=typeof e.tilingPaddingHorizontal==`function`?e.tilingPaddingHorizontal.call():e.tilingPaddingHorizontal};f.prototype.run=function(){var e,t,n=this.options;this.idToLNode={};var r=this.layout=new o,i=this;i.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:`layoutstart`,layout:this});var a=r.newGraphManager();this.gm=a;var s=this.options.eles.nodes(),c=this.options.eles.edges();this.root=a.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(s),r);for(var l=0;l0){var h=n.getGraphManager().add(n.newGraph(),u);this.processChildrenList(h,o,n)}}},f.prototype.stop=function(){return this.stopped=!0,this};var m=function(e){e(`layout`,`cose-bilkent`,f)};typeof cytoscape<`u`&&m(cytoscape),e.exports=m})])})}))(),1);a.use(c.default);function l(e,t){e.forEach(e=>{let n={id:e.id,labelText:e.label,height:e.height,width:e.width,padding:e.padding??0};Object.keys(e).forEach(t=>{[`id`,`label`,`height`,`width`,`padding`,`x`,`y`].includes(t)||(n[t]=e[t])}),t.add({group:`nodes`,data:n,position:{x:e.x??0,y:e.y??0}})})}i(l,`addNodes`);function u(e,t){e.forEach(e=>{let n={id:e.id,source:e.start,target:e.end};Object.keys(e).forEach(t=>{[`id`,`start`,`end`].includes(t)||(n[t]=e[t])}),t.add({group:`edges`,data:n})})}i(u,`addEdges`);function d(e){return new Promise(r=>{let i=n(`body`).append(`div`).attr(`id`,`cy`).attr(`style`,`display:none`),o=a({container:document.getElementById(`cy`),style:[{selector:`edge`,style:{"curve-style":`bezier`}}]});i.remove(),l(e.nodes,o),u(e.edges,o),o.nodes().forEach(function(e){e.layoutDimensions=()=>{let t=e.data();return{w:t.width,h:t.height}}}),o.layout({name:`cose-bilkent`,quality:`proof`,styleEnabled:!1,animate:!1}).run(),o.ready(e=>{t.info(`Cytoscape ready`,e),r(o)})})}i(d,`createCytoscapeInstance`);function f(e){return e.nodes().map(e=>{let t=e.data(),n=e.position(),r={id:t.id,x:n.x,y:n.y};return Object.keys(t).forEach(e=>{e!==`id`&&(r[e]=t[e])}),r})}i(f,`extractPositionedNodes`);function p(e){return e.edges().map(e=>{let t=e.data(),n=e._private.rscratch,r={id:t.id,source:t.source,target:t.target,startX:n.startX,startY:n.startY,midX:n.midX,midY:n.midY,endX:n.endX,endY:n.endY};return Object.keys(t).forEach(e=>{[`id`,`source`,`target`].includes(e)||(r[e]=t[e])}),r})}i(p,`extractPositionedEdges`);async function m(e,n){t.debug(`Starting cose-bilkent layout algorithm`);try{h(e);let n=await d(e),r=f(n),i=p(n);return t.debug(`Layout completed: ${r.length} nodes, ${i.length} edges`),{nodes:r,edges:i}}catch(e){throw t.error(`Error in cose-bilkent layout algorithm:`,e),e}}i(m,`executeCoseBilkentLayout`);function h(e){if(!e)throw Error(`Layout data is required`);if(!e.config)throw Error(`Configuration is required in layout data`);if(!e.rootNode)throw Error(`Root node is required`);if(!e.nodes||!Array.isArray(e.nodes))throw Error(`No nodes found in layout data`);if(!Array.isArray(e.edges))throw Error(`Edges array is required in layout data`);return!0}i(h,`validateLayoutData`);var g=i(async(e,t,{insertCluster:n,insertEdge:r,insertEdgeLabel:i,insertMarkers:a,insertNode:o,log:s,positionEdgeLabel:c},{algorithm:l})=>{let u={},d={},f=t.select(`g`);a(f,e.markers,e.type,e.diagramId);let p=f.insert(`g`).attr(`class`,`subgraphs`),h=f.insert(`g`).attr(`class`,`edgePaths`),g=f.insert(`g`).attr(`class`,`edgeLabels`),_=f.insert(`g`).attr(`class`,`nodes`);s.debug(`Inserting nodes into DOM for dimension calculation`),await Promise.all(e.nodes.map(async t=>{if(t.isGroup){let e={...t};d[t.id]=e,u[t.id]=e,await n(p,t)}else{let n={...t};u[t.id]=n;let r=await o(_,t,{config:e.config,dir:e.direction||`TB`}),i=r.node().getBBox();n.width=i.width,n.height=i.height,n.domId=r,s.debug(`Node ${t.id} dimensions: ${i.width}x${i.height}`)}})),s.debug(`Running cose-bilkent layout algorithm`);let v=await m({...e,nodes:e.nodes.map(e=>{let t=u[e.id];return{...e,width:t.width,height:t.height}})},e.config);s.debug(`Positioning nodes based on layout results`),v.nodes.forEach(e=>{let t=u[e.id];t?.domId&&(t.domId.attr(`transform`,`translate(${e.x}, ${e.y})`),t.x=e.x,t.y=e.y,s.debug(`Positioned node ${t.id} at center (${e.x}, ${e.y})`))}),v.edges.forEach(t=>{let n=e.edges.find(e=>e.id===t.id);n&&(n.points=[{x:t.startX,y:t.startY},{x:t.midX,y:t.midY},{x:t.endX,y:t.endY}])}),s.debug(`Inserting and positioning edges`),await Promise.all(e.edges.map(async t=>{await i(g,t);let n=u[t.start??``],a=u[t.end??``];if(n&&a){let i=v.edges.find(e=>e.id===t.id);if(i){s.debug(`APA01 positionedEdge`,i);let o={...t};c(o,r(h,o,d,e.type,n,a,e.diagramId))}else{let i={...t,points:[{x:n.x||0,y:n.y||0},{x:a.x||0,y:a.y||0}]};c(i,r(h,i,d,e.type,n,a,e.diagramId))}}})),s.debug(`Cose-bilkent rendering completed`)},`render`);export{g as render}; \ No newline at end of file diff --git a/www/assets/cynefin-OW5HDTMX-DebjIew_.js b/www/assets/cynefin-OW5HDTMX-DebjIew_.js new file mode 100644 index 0000000..5a5c26a --- /dev/null +++ b/www/assets/cynefin-OW5HDTMX-DebjIew_.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{A as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createCynefinServices}; \ No newline at end of file diff --git a/www/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js b/www/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js new file mode 100644 index 0000000..87aa78d --- /dev/null +++ b/www/assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js @@ -0,0 +1,62 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=t(()=>({domains:new Map,transitions:[]}),`createDefaultData`),v=_(),y={getDomains:t(()=>v.domains,`getDomains`),getTransitions:t(()=>v.transitions,`getTransitions`),setDomains:t(e=>{if(e)for(let t of e){let e=t.domain,n=(t.items??[]).map(e=>({label:e.label}));v.domains.set(e,{name:e,items:n})}},`setDomains`),setTransitions:t(t=>{t&&(v.transitions=t.filter(t=>t.from!==t.to||(e.warn(`Cynefin: self-loop transition on domain "${t.from}" is not meaningful and will be skipped.`),!1)).map(e=>({from:e.from,to:e.to,label:e.label||void 0})))},`setTransitions`),getConfig:t(()=>p({...c.cynefin,...o().cynefin}),`getConfig`),clear:t(()=>{a(),v=_()},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r},b=t(e=>{g(e,y),y.setDomains(e.domains),y.setTransitions(e.transitions)},`populate`),x={parse:t(async t=>{let n=await h(`cynefin`,t);e.debug(n),b(n)},`parse`)};function S(e){let t=e+1831565813|0;return t=Math.imul(t^t>>>15,t|1),t^=t+Math.imul(t^t>>>7,t|61),((t^t>>>14)>>>0)/4294967296}t(S,`seededRandom`);function C(e){let t=0;for(let n=0;n{let n=e/2,r=t/2;return{complex:{cx:n/2,cy:r/2,x:0,y:0,w:n,h:r},complicated:{cx:n+n/2,cy:r/2,x:n,y:0,w:n,h:r},chaotic:{cx:n/2,cy:r+r/2,x:0,y:r,w:n,h:r},clear:{cx:n+n/2,cy:r+r/2,x:n,y:r,w:n,h:r},confusion:{cx:n,cy:r,x:n*.7,y:r*.7,w:n*.6,h:r*.6}}},`getDomainLayouts`),j=t(()=>{let e=n(),t=o();return p(e,t.themeVariables).cynefin},`getCynefinDomainColors`),M=3,N={draw:t((t,n,r,i)=>{let a=i.db,o=a.getDomains(),c=a.getTransitions(),l=a.getDiagramTitle(),u=a.getAccTitle(),d=a.getAccDescription(),f=a.getConfig(),p=j();e.debug(`Rendering Cynefin diagram`);let h=f.width,g=f.height,_=f.padding,v=f.showDomainDescriptions,y=f.boundaryAmplitude,b=h+_*2,x=g+_*2,S={complex:p.complexBg,complicated:p.complicatedBg,clear:p.clearBg,chaotic:p.chaoticBg,confusion:p.confusionBg},C=m(n);s(C,x,b,f.useMaxWidth??!0),C.attr(`viewBox`,`0 0 ${b} ${x}`),u&&C.append(`title`).text(u),d&&C.append(`desc`).text(d);let N=C.append(`g`).attr(`transform`,`translate(${_}, ${_})`),P=A(h,g),F=w(f.seed,n),I=N.append(`g`).attr(`class`,`cynefin-backgrounds`),L=[`complex`,`complicated`,`chaotic`,`clear`];for(let e of L){let t=P[e];I.append(`rect`).attr(`class`,`cynefinDomain`).attr(`x`,t.x).attr(`y`,t.y).attr(`width`,t.w).attr(`height`,t.h).attr(`fill`,S[e]).attr(`fill-opacity`,.4).attr(`stroke`,`none`)}let R=N.append(`g`).attr(`class`,`cynefin-boundaries`);R.append(`path`).attr(`class`,`cynefinBoundary`).attr(`d`,T(h,g,F,y)).attr(`fill`,`none`),R.append(`path`).attr(`class`,`cynefinBoundary`).attr(`d`,E(h,g,F+100,y)).attr(`fill`,`none`),R.append(`path`).attr(`class`,`cynefinCliff`).attr(`d`,D(h,g)).attr(`fill`,`none`);let z=h*.15,B=g*.15;N.append(`path`).attr(`class`,`cynefinConfusion`).attr(`d`,O(h/2,g/2,z,B)).attr(`fill`,S.confusion).attr(`fill-opacity`,.5);let V=N.append(`g`).attr(`class`,`cynefin-labels`);for(let e of L){let t=P[e];V.append(`text`).attr(`class`,`cynefinDomainLabel`).attr(`x`,t.cx).attr(`y`,v?t.cy-30:t.cy).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(e.charAt(0).toUpperCase()+e.slice(1))}if(V.append(`text`).attr(`class`,`cynefinDomainLabel`).attr(`x`,h/2).attr(`y`,v?g/2-10:g/2).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(`Confusion`),v){let e=N.append(`g`).attr(`class`,`cynefin-subtitles`);for(let t of L){let n=P[t],r=k[t];e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,n.cx).attr(`y`,n.cy-10).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(r.model),e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,n.cx).attr(`y`,n.cy+5).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(r.practice)}e.append(`text`).attr(`class`,`cynefinSubtitle`).attr(`x`,h/2).attr(`y`,g/2+8).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(k.confusion.practice)}let H=N.append(`g`).attr(`class`,`cynefin-items`);for(let e of[`complex`,`complicated`,`chaotic`,`clear`,`confusion`]){let t=o.get(e);if(!t||t.items.length===0)continue;let n=P[e],r=e===`confusion`,i=t.items,a=0;r&&t.items.length>M&&(a=t.items.length-M,i=t.items.slice(0,M));let s;if(r){let e=v?22:14;s=n.cy+e}else s=n.cy+(v?25:15);if([...i].forEach((t,r)=>{let i=s+r*30,a=H.append(`g`),o=a.append(`text`).attr(`class`,`cynefinItemText`).attr(`x`,0).attr(`y`,13).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).text(t.label),c=t.label.length*7,l=o.node();if(l&&typeof l.getBBox==`function`){let e=l.getBBox();e.width>0&&(c=e.width)}let u=c+20,d=n.cx-u/2;a.attr(`transform`,`translate(${d}, ${i})`),a.insert(`rect`,`text`).attr(`class`,`cynefinItem`).attr(`x`,0).attr(`y`,0).attr(`width`,u).attr(`height`,26).attr(`rx`,4).attr(`ry`,4).attr(`fill`,S[e]).attr(`fill-opacity`,.95),o.attr(`x`,u/2).attr(`y`,13)}),a>0){let t=s+i.length*30,r=`+${a} more`,o=H.append(`g`),c=o.append(`text`).attr(`class`,`cynefinItemText`).attr(`x`,0).attr(`y`,13).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).text(r),l=r.length*7,u=c.node();if(u&&typeof u.getBBox==`function`){let e=u.getBBox();e.width>0&&(l=e.width)}let d=l+20,f=n.cx-d/2;o.attr(`transform`,`translate(${f}, ${t})`),o.insert(`rect`,`text`).attr(`class`,`cynefinItemOverflow`).attr(`x`,0).attr(`y`,0).attr(`width`,d).attr(`height`,26).attr(`rx`,4).attr(`ry`,4).attr(`fill`,S[e]).attr(`fill-opacity`,.6),c.attr(`x`,d/2).attr(`y`,13)}}if(c.length>0){let t=C.select(`defs`).empty()?C.append(`defs`):C.select(`defs`),r=`cynefin-arrow-${n}`;t.append(`marker`).attr(`id`,r).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`class`,`cynefinArrowHead`);let i=N.append(`g`).attr(`class`,`cynefin-arrows`);c.forEach(t=>{let n=P[t.from],a=P[t.to];if(!n||!a)return;if(t.from===t.to){e.warn(`Cynefin renderer: skipping self-loop on domain "${t.from}"`);return}let o=n.cx,s=n.cy,c=a.cx,l=a.cy,u=(o+c)/2,d=(s+l)/2,f=c-o,p=l-s,m=Math.sqrt(f*f+p*p),h=m*.15,g=-p/m,_=f/m,v=u+g*h,y=d+_*h;i.append(`path`).attr(`class`,`cynefinArrowLine`).attr(`d`,`M${o},${s} Q${v},${y} ${c},${l}`).attr(`fill`,`none`).attr(`marker-end`,`url(#${r})`),t.label&&i.append(`text`).attr(`class`,`cynefinArrowLabel`).attr(`x`,v).attr(`y`,y-6).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`auto`).text(t.label)})}l&&N.append(`text`).attr(`class`,`cynefinTitle`).attr(`x`,h/2).attr(`y`,-_/2).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(l)},`draw`)},P=t(()=>{let e=n(),t=o();return p(e,t.themeVariables).cynefin},`getCynefinTheme`),F={parser:x,db:y,renderer:N,styles:t(()=>{let e=P();return` + .cynefinDomain { + stroke: none; + } + .cynefinDomainLabel { + font-size: ${e.domainFontSize}px; + font-weight: bold; + fill: ${e.labelColor}; + } + .cynefinSubtitle { + font-size: ${e.itemFontSize-1}px; + fill: ${e.textColor}; + font-style: italic; + } + .cynefinItem { + fill-opacity: 0.95; + stroke: ${e.boundaryColor}; + stroke-width: 1; + } + .cynefinItemText { + font-size: ${e.itemFontSize}px; + fill: ${e.textColor}; + } + .cynefinItemOverflow { + fill-opacity: 0.6; + stroke: ${e.boundaryColor}; + stroke-width: 1; + stroke-dasharray: 3 2; + } + .cynefinBoundary { + stroke: ${e.boundaryColor}; + stroke-width: ${e.boundaryWidth}; + stroke-dasharray: 6 3; + } + .cynefinCliff { + stroke: ${e.cliffColor}; + stroke-width: ${e.cliffWidth}; + } + .cynefinConfusion { + stroke: ${e.boundaryColor}; + stroke-width: 1.5; + stroke-dasharray: 4 2; + } + .cynefinArrowLine { + stroke: ${e.arrowColor}; + stroke-width: ${e.arrowWidth}; + fill: none; + } + .cynefinArrowHead { + fill: ${e.arrowColor}; + stroke: none; + } + .cynefinArrowLabel { + font-size: ${e.itemFontSize-1}px; + fill: ${e.textColor}; + } + .cynefinTitle { + font-size: ${e.domainFontSize+2}px; + font-weight: bold; + fill: ${e.labelColor}; + } + `},`styles`)};export{F as diagram}; \ No newline at end of file diff --git a/www/assets/cytoscape.esm-CECbKnxF.js b/www/assets/cytoscape.esm-CECbKnxF.js new file mode 100644 index 0000000..486bfe9 --- /dev/null +++ b/www/assets/cytoscape.esm-CECbKnxF.js @@ -0,0 +1,321 @@ +function e(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a,o=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,a=e},f:function(){try{o||n.return==null||n.return()}finally{if(s)throw a}}}}function s(e,t,n){return(t=h(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function c(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function l(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function u(){throw TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function d(){throw TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function f(e,n){return t(e)||l(e,n)||_(e,n)||u()}function p(e){return n(e)||c(e)||_(e)||d()}function m(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return String(e)}function h(e){var t=m(e,`string`);return typeof t==`symbol`?t:t+``}function g(e){"@babel/helpers - typeof";return g=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},g(e)}function _(t,n){if(t){if(typeof t==`string`)return e(t,n);var r={}.toString.call(t).slice(8,-1);return r===`Object`&&t.constructor&&(r=t.constructor.name),r===`Map`||r===`Set`?Array.from(t):r===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?e(t,n):void 0}}var v=typeof window>`u`?null:window,y=v?v.navigator:null;v&&v.document;var b=g(``),x=g({}),S=g(function(){}),C=typeof HTMLElement>`u`?`undefined`:g(HTMLElement),w=function(e){return e&&e.instanceString&&E(e.instanceString)?e.instanceString():null},T=function(e){return e!=null&&g(e)==b},E=function(e){return e!=null&&g(e)===S},D=function(e){return!N(e)&&(Array.isArray?Array.isArray(e):e!=null&&e instanceof Array)},O=function(e){return e!=null&&g(e)===x&&!D(e)&&e.constructor===Object},k=function(e){return e!=null&&g(e)===x},A=function(e){return e!=null&&g(e)===g(1)&&!isNaN(e)},j=function(e){return A(e)&&Math.floor(e)===e},M=function(e){if(C!==`undefined`)return e!=null&&e instanceof HTMLElement},N=function(e){return P(e)||F(e)},P=function(e){return w(e)===`collection`&&e._private.single},F=function(e){return w(e)===`collection`&&!e._private.single},I=function(e){return w(e)===`core`},L=function(e){return w(e)===`stylesheet`},R=function(e){return w(e)===`event`},z=function(e){return e==null||!!(e===``||e.match(/^\s+$/))},B=function(e){return typeof HTMLElement>`u`?!1:e instanceof HTMLElement},V=function(e){return O(e)&&A(e.x1)&&A(e.x2)&&A(e.y1)&&A(e.y2)},H=function(e){return k(e)&&E(e.then)},U=function(){return y&&y.userAgent.match(/msie|trident|edge/i)},W=function(e,t){t||=function(){if(arguments.length===1)return arguments[0];if(arguments.length===0)return`undefined`;for(var e=[],t=0;tt)},ce=function(e,t){return-1*se(e,t)},X=Object.assign==null?function(e){for(var t=arguments,n=1;n1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}var u=RegExp(`^`+re+`$`).exec(e);if(u){if(n=parseInt(u[1]),n<0?n=(360- -1*n%360)%360:n>360&&(n%=360),n/=360,r=parseFloat(u[2]),r<0||r>100||(r/=100,i=parseFloat(u[3]),i<0||i>100)||(i/=100,a=u[4],a!==void 0&&(a=parseFloat(a),a<0||a>1)))return;if(r===0)o=s=c=Math.round(i*255);else{var d=i<.5?i*(1+r):i+r-i*r,f=2*i-d;o=Math.round(255*l(f,d,n+1/3)),s=Math.round(255*l(f,d,n)),c=Math.round(255*l(f,d,n-1/3))}t=[o,s,c,a]}return t},de=function(e){var t,n=RegExp(`^`+te+`$`).exec(e);if(n){t=[];for(var r=[],i=1;i<=3;i++){var a=n[i];if(a[a.length-1]===`%`&&(r[i]=!0),a=parseFloat(a),r[i]&&(a=a/100*255),a<0||a>255)return;t.push(Math.floor(a))}var o=r[1]||r[2]||r[3],s=r[1]&&r[2]&&r[3];if(o&&!s)return;var c=n[4];if(c!==void 0){if(c=parseFloat(c),c<0||c>1)return;t.push(c)}}return t},fe=function(e){return me[e.toLowerCase()]},pe=function(e){return(D(e)?e:null)||fe(e)||le(e)||de(e)||ue(e)},me={transparent:[0,0,0,0],aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],grey:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},he=function(e){for(var t=e.map,n=e.keys,r=n.length,i=0;i=s||t<0||_&&n>=d}function C(){var e=t();if(S(e))return w(e);p=setTimeout(C,x(e))}function w(e){return p=void 0,v&&l?y(e):(l=u=void 0,f)}function T(){p!==void 0&&clearTimeout(p),h=0,l=m=u=p=void 0}function E(){return p===void 0?f:w(t())}function D(){var e=t(),n=S(e);if(l=arguments,u=this,m=e,n){if(p===void 0)return b(m);if(_)return clearTimeout(p),p=setTimeout(C,s),y(m)}return p===void 0&&(p=setTimeout(C,s)),f}return D.cancel=T,D.flush=E,D}return it=o,it}var st=ve(ot()),ct=v?v.performance:null,lt=ct&&ct.now?function(){return ct.now()}:function(){return Date.now()},ut=function(){if(v){if(v.requestAnimationFrame)return function(e){v.requestAnimationFrame(e)};if(v.mozRequestAnimationFrame)return function(e){v.mozRequestAnimationFrame(e)};if(v.webkitRequestAnimationFrame)return function(e){v.webkitRequestAnimationFrame(e)};if(v.msRequestAnimationFrame)return function(e){v.msRequestAnimationFrame(e)}}return function(e){e&&setTimeout(function(){e(lt())},1e3/60)}}(),dt=function(e){return ut(e)},ft=lt,pt=9261,mt=65599,ht=5381,gt=function(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:pt,n;n=e.next(),!n.done;)t=t*mt+n.value|0;return t},_t=function(e){return(arguments.length>1&&arguments[1]!==void 0?arguments[1]:pt)*mt+e|0},vt=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ht;return(t<<5)+t+e|0},yt=function(e,t){return e*2097152+t},bt=function(e){return e[0]*2097152+e[1]},xt=function(e,t){return[_t(e[0],t[0]),vt(e[1],t[1])]},St=function(e,t){var n={value:0,done:!1},r=0,i=e.length;return gt({next:function(){return r=0;r--)e[r]===t&&e.splice(r,1)},Jt=function(e){e.splice(0,e.length)},Yt=function(e,t){for(var n=0;n`u`?`undefined`:g(Set))===$t?en:Set,nn=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(e===void 0||t===void 0||!I(e)){Lt(`An element must have a core reference and parameters set`);return}var r=t.group;if(r??=t.data&&t.data.source!=null&&t.data.target!=null?`edges`:`nodes`,r!==`nodes`&&r!==`edges`){Lt("An element must be of type `nodes` or `edges`; you specified `"+r+"`");return}this.length=1,this[0]=this;var i=this._private={cy:e,single:!0,data:t.data||{},position:t.position||{x:0,y:0},autoWidth:void 0,autoHeight:void 0,autoPadding:void 0,compoundBoundsClean:!1,listeners:[],group:r,style:{},rstyle:{},styleCxts:[],styleKeys:{},removed:!0,selected:!!t.selected,selectable:t.selectable===void 0||!!t.selectable,locked:!!t.locked,grabbed:!1,grabbable:t.grabbable===void 0||!!t.grabbable,pannable:t.pannable===void 0?r===`edges`:!!t.pannable,active:!1,classes:new tn,animation:{current:[],queue:[]},rscratch:{},scratch:t.scratch||{},edges:[],children:[],parent:t.parent&&t.parent.isNode()?t.parent:null,traversalCache:{},backgrounding:!1,bbCache:null,bbCacheShift:{x:0,y:0},bodyBounds:null,overlayBounds:null,labelBounds:{all:null,source:null,target:null,main:null},arrowBounds:{source:null,target:null,"mid-source":null,"mid-target":null}};if(i.position.x??(i.position.x=0),i.position.y??(i.position.y=0),t.renderedPosition){var a=t.renderedPosition,o=e.pan(),s=e.zoom();i.position={x:(a.x-o.x)/s,y:(a.y-o.y)/s}}var c=[];D(t.classes)?c=t.classes:T(t.classes)&&(c=t.classes.split(/\s+/));for(var l=0,u=c.length;lt)},l=function(e,t,i,a,o){var s;if(i??=0,o??=n,i<0)throw Error(`lo must be non-negative`);for(a??=e.length;in;0<=n?t++:t--)l.push(t);return l}).apply(this).reverse(),c=[],a=0,o=s.length;ah;0<=h?++f:--f)g.push(a(e,r));return g},m=function(e,t,r,i){var a,o,s;for(i??=n,a=e[r];r>t;){if(s=r-1>>1,o=e[s],i(a,o)<0){e[r]=o,r=s;continue}break}return e[r]=a},h=function(e,t,r){var i,a,o,s,c;for(r??=n,a=e.length,c=t,o=e[t],i=2*t+1;i0;){var x=_.pop(),S=h(x),C=x.id();if(d[C]=S,S!==1/0)for(var w=x.neighborhood().intersect(p),E=0;E0)for(n.unshift(t);u[i];){var a=u[i];n.unshift(a.edge),n.unshift(a.node),r=a.node,i=r.id()}return o.spawn(n)}}}},gn={kruskal:function(e){e||=function(e){return 1};for(var t=this.byGroup(),n=t.nodes,r=t.edges,i=n.length,a=Array(i),o=n,s=function(e){for(var t=0;t0;){if(b(),S++,y===l){for(var C=[],w=i,T=l,E=g[T];C.unshift(w),E!=null&&C.unshift(E),w=h[T],w!=null;)T=w.id(),E=g[T];return{found:!0,distance:u[y],path:this.spawn(C),steps:S}}f[y]=!0;for(var D=v._private.edges,O=0;OE&&(p[w]=E,g[w]=C,_[w]=y),!i){var D=C*l+S;!i&&p[D]>E&&(p[D]=E,g[D]=S,_[D]=y)}}}for(var O=0;O1&&arguments[1]!==void 0?arguments[1]:a,r=v(e),i=[],o=r;;){if(o==null)return t.spawn();var c=_(o),l=c.edge,u=c.pred;if(i.unshift(o[0]),o.same(n)&&i.length>0)break;l!=null&&i.unshift(l),o=u}return s.spawn(i)},x=0;x=0;l--){var u=c[l],d=u[1],f=u[2];(t[d]===o&&t[f]===s||t[d]===s&&t[f]===o)&&c.splice(l,1)}for(var p=0;pr;)t=wn(Math.floor(Math.random()*t.length),e,t),n--;return t},En={kargerStein:function(){var e=this,t=this.byGroup(),n=t.nodes,r=t.edges;r.unmergeBy(function(e){return e.isLoop()});var i=n.length,a=r.length,o=Math.ceil((Math.log(i)/Math.LN2)**2),s=Math.floor(i/Cn);if(i<2){Lt(`At least 2 nodes are required for Karger-Stein algorithm`);return}for(var c=[],l=0;l1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=1/0,i=t;i1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=-1/0,i=t;i1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=0,i=0,a=t;a1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0;r?e=e.slice(t,n):(n0&&e.splice(0,t));for(var o=0,s=e.length-1;s>=0;s--){var c=e[s];a?isFinite(c)||(e[s]=-1/0,o++):e.splice(s,1)}i&&e.sort(function(e,t){return e-t});var l=e.length,u=Math.floor(l/2);return l%2==0?(e[u-1+o]+e[u+o])/2:e[u+1+o]},Fn=function(e,t){return t===0?e:Fn(t,e%t)},In=function(e){for(var t=e[0],n=0;n0&&(t=Fn(t,e[n]));else return 0;return t},Ln=function(e){return Math.PI*e/180},Rn=function(e,t){return Math.atan2(t,e)-Math.PI/2},zn=Math.log2||function(e){return Math.log(e)/Math.log(2)},Bn=function(e){return e>0?1:e<0?-1:0},Vn=function(e,t){return Math.sqrt(Hn(e,t))},Hn=function(e,t){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r},Un=function(e){for(var t=e.length,n=0,r=0;r=e.x1&&e.y2>=e.y1)return{x1:e.x1,y1:e.y1,x2:e.x2,y2:e.y2,w:e.x2-e.x1,h:e.y2-e.y1};if(e.w!=null&&e.h!=null&&e.w>=0&&e.h>=0)return{x1:e.x1,y1:e.y1,x2:e.x1+e.w,y2:e.y1+e.h,w:e.w,h:e.h}}},Yn=function(e){return{x1:e.x1,x2:e.x2,w:e.w,y1:e.y1,y2:e.y2,h:e.h}},Xn=function(e){e.x1=1/0,e.y1=1/0,e.x2=-1/0,e.y2=-1/0,e.w=0,e.h=0},Zn=function(e,t){e.x1=Math.min(e.x1,t.x1),e.x2=Math.max(e.x2,t.x2),e.w=e.x2-e.x1,e.y1=Math.min(e.y1,t.y1),e.y2=Math.max(e.y2,t.y2),e.h=e.y2-e.y1},Qn=function(e,t,n){e.x1=Math.min(e.x1,t),e.x2=Math.max(e.x2,t),e.w=e.x2-e.x1,e.y1=Math.min(e.y1,n),e.y2=Math.max(e.y2,n),e.h=e.y2-e.y1},$n=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return e.x1-=t,e.x2+=t,e.y1-=t,e.y2+=t,e.w=e.x2-e.x1,e.h=e.y2-e.y1,e},er=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[0],n,r,i,a;if(t.length===1)n=r=i=a=t[0];else if(t.length===2)n=i=t[0],a=r=t[1];else if(t.length===4){var o=f(t,4);n=o[0],r=o[1],i=o[2],a=o[3]}return e.x1-=a,e.x2+=r,e.y1-=n,e.y2+=i,e.w=e.x2-e.x1,e.h=e.y2-e.y1,e},tr=function(e,t){e.x1=t.x1,e.y1=t.y1,e.x2=t.x2,e.y2=t.y2,e.w=e.x2-e.x1,e.h=e.y2-e.y1},nr=function(e,t){return!(e.x1>t.x2||t.x1>e.x2||e.x2t.y2||t.y1>e.y2)},rr=function(e,t,n){return e.x1<=t&&t<=e.x2&&e.y1<=n&&n<=e.y2},ir=function(e,t){return rr(e,t.x,t.y)},ar=function(e,t){return rr(e,t.x1,t.y1)&&rr(e,t.x2,t.y2)},or=Math.hypot??function(e,t){return Math.sqrt(e*e+t*t)};function sr(e,t){if(e.length<3)throw Error(`Need at least 3 vertices`);var n=function(e,t){return{x:e.x+t.x,y:e.y+t.y}},r=function(e,t){return{x:e.x-t.x,y:e.y-t.y}},i=function(e,t){return{x:e.x*t,y:e.y*t}},a=function(e,t){return e.x*t.y-e.y*t.x},o=function(e){var t=or(e.x,e.y);return t===0?{x:0,y:0}:{x:e.x/t,y:e.y/t}},s=function(e){for(var t=0,n=0;n7&&arguments[7]!==void 0?arguments[7]:`auto`,c=s===`auto`?Nr(i,a):s,l=i/2,u=a/2;c=Math.min(c,l,u);var d=c!==l,f=c!==u,p;if(d){var m=n-l+c-o,h=r-u-o;if(p=Tr(e,t,n,r,m,h,n+l-c+o,h,!1),p.length>0)return p}if(f){var g=n+l+o;if(p=Tr(e,t,n,r,g,r-u+c-o,g,r+u-c+o,!1),p.length>0)return p}if(d){var _=n-l+c-o,v=r+u+o;if(p=Tr(e,t,n,r,_,v,n+l-c+o,v,!1),p.length>0)return p}if(f){var y=n-l-o;if(p=Tr(e,t,n,r,y,r-u+c-o,y,r+u-c+o,!1),p.length>0)return p}var b,x=n-l+c,S=r-u+c;if(b=Cr(e,t,n,r,x,S,c+o),b.length>0&&b[0]<=x&&b[1]<=S)return[b[0],b[1]];var C=n+l-c,w=r-u+c;if(b=Cr(e,t,n,r,C,w,c+o),b.length>0&&b[0]>=C&&b[1]<=w)return[b[0],b[1]];var T=n+l-c,E=r+u-c;if(b=Cr(e,t,n,r,T,E,c+o),b.length>0&&b[0]>=T&&b[1]>=E)return[b[0],b[1]];var D=n-l+c,O=r+u-c;return b=Cr(e,t,n,r,D,O,c+o),b.length>0&&b[0]<=D&&b[1]>=O?[b[0],b[1]]:[]},ur=function(e,t,n,r,i,a,o){var s=o,c=Math.min(n,i),l=Math.max(n,i),u=Math.min(r,a),d=Math.max(r,a);return c-s<=e&&e<=l+s&&u-s<=t&&t<=d+s},dr=function(e,t,n,r,i,a,o,s,c){var l={x1:Math.min(n,o,i)-c,x2:Math.max(n,o,i)+c,y1:Math.min(r,s,a)-c,y2:Math.max(r,s,a)+c};return!(el.x2||tl.y2)},fr=function(e,t,n,r){n-=r;var i=t*t-4*e*n;if(i<0)return[];var a=Math.sqrt(i),o=2*e;return[(-t+a)/o,(-t-a)/o]},pr=function(e,t,n,r,i){e===0&&(e=1e-5),t/=e,n/=e,r/=e;var a,o=(3*n-t*t)/9,s=-(27*r)+t*(9*n-t*t*2),c,l,u,d,f;if(s/=54,a=o*o*o+s*s,i[1]=0,d=t/3,a>0){l=s+Math.sqrt(a),l=l<0?-((-l)**(1/3)):l**(1/3),u=s-Math.sqrt(a),u=u<0?-((-u)**(1/3)):u**(1/3),i[0]=-d+l+u,d+=(l+u)/2,i[4]=i[2]=-d,d=Math.sqrt(3)*(-u+l)/2,i[3]=d,i[5]=-d;return}if(i[5]=i[3]=0,a===0){f=s<0?-((-s)**(1/3)):s**(1/3),i[0]=-d+2*f,i[4]=i[2]=-(f+d);return}o=-o,c=o*o*o,c=Math.acos(s/Math.sqrt(c)),f=2*Math.sqrt(o),i[0]=-d+f*Math.cos(c/3),i[2]=-d+f*Math.cos((c+2*Math.PI)/3),i[4]=-d+f*Math.cos((c+4*Math.PI)/3)},mr=function(e,t,n,r,i,a,o,s){var c=1*n*n-4*n*i+2*n*o+4*i*i-4*i*o+o*o+r*r-4*r*a+2*r*s+4*a*a-4*a*s+s*s,l=9*n*i-3*n*n-3*n*o-6*i*i+3*i*o+9*r*a-3*r*r-3*r*s-6*a*a+3*a*s,u=3*n*n-6*n*i+n*o-n*e+2*i*i+2*i*e-o*e+3*r*r-6*r*a+r*s-r*t+2*a*a+2*a*t-s*t,d=1*n*i-n*n+n*e-i*e+r*a-r*r+r*t-a*t,f=[];pr(c,l,u,d,f);for(var p=1e-7,m=[],h=0;h<6;h+=2)Math.abs(f[h+1])=0&&f[h]<=1&&m.push(f[h]);m.push(1),m.push(0);for(var g=-1,_,v,y,b=0;b=0?yc?(e-i)*(e-i)+(t-a)*(t-a):l-d},gr=function(e,t,n){for(var r,i,a,o,s,c=0,l=0;l=e&&e>=a||r<=e&&e<=a)s=(e-r)/(a-r)*(o-i)+i,s>t&&c++;else continue}return c%2!=0},_r=function(e,t,n,r,i,a,o,s,c){var l=Array(n.length),u;s[0]==null?u=s:(u=Math.atan(s[1]/s[0]),s[0]<0?u+=Math.PI/2:u=-u-Math.PI/2);for(var d=Math.cos(-u),f=Math.sin(-u),p=0;p0?yr(br(l,-c)):l)},vr=function(e,t,n,r,i,a,o,s){for(var c=Array(n.length*2),l=0;l=0&&h<=1&&_.push(h),g>=0&&g<=1&&_.push(g),_.length===0)return[];var v=_[0]*s[0]+e,y=_[0]*s[1]+t;return _.length>1?_[0]==_[1]?[v,y]:[v,y,_[1]*s[0]+e,_[1]*s[1]+t]:[v,y]},wr=function(e,t,n){return t<=e&&e<=n||n<=e&&e<=t?e:e<=t&&t<=n||n<=t&&t<=e?t:n},Tr=function(e,t,n,r,i,a,o,s,c){var l=e-i,u=n-e,d=o-i,f=t-a,p=r-t,m=s-a,h=d*f-m*l,g=u*f-p*l,_=m*u-d*p;if(_!==0){var v=h/_,y=g/_,b=.001,x=0-b,S=1+b;return x<=v&&v<=S&&x<=y&&y<=S||c?[e+v*u,t+v*p]:[]}return h===0||g===0?wr(e,n,o)===o?[o,s]:wr(e,n,i)===i?[i,a]:wr(i,o,n)===n?[n,r]:[]:[]},Er=function(e,t,n,r,i){var a=[],o=r/2,s=i/2,c=t,l=n;a.push({x:c+o*e[0],y:l+s*e[1]});for(var u=1;u0?yr(br(u,-s)):u}else f=n;for(var m,h,g,_,v=0;v2){for(var p=[l[0],l[1]],m=(p[0]-e)**2+(p[1]-t)**2,h=1;hl&&(l=t)},get:function(e){return c[e]}},d=0;d0?v.edgesTo(_)[0]:_.edgesTo(v)[0];var b=r(y);_=_.id(),l[_]>l[m]+b&&(l[_]=l[m]+b,d.nodes.indexOf(_)<0?d.push(_):d.updateItem(_),c[_]=0,n[_]=[]),l[_]==l[m]+b&&(c[_]=c[_]+c[m],n[_].push(m))}else for(var x=0;x0;){for(var T=t.pop(),E=0;E0&&o.push(n[s]);o.length!==0&&i.push(r.collection(o))}return i},ri=function(e,t){for(var n=0;n5&&arguments[5]!==void 0?arguments[5]:si,o=r,s,c,l=0;l=2?pi(e,t,n,0,ui,di):pi(e,t,n,0,li)},squaredEuclidean:function(e,t,n){return pi(e,t,n,0,ui)},manhattan:function(e,t,n){return pi(e,t,n,0,li)},max:function(e,t,n){return pi(e,t,n,-1/0,fi)}};mi[`squared-euclidean`]=mi.squaredEuclidean,mi.squaredeuclidean=mi.squaredEuclidean;function hi(e,t,n,r,i,a){var o=E(e)?e:mi[e]||mi.euclidean;return t===0&&E(e)?o(i,a):o(t,n,r,i,a)}var gi=Kt({k:2,m:2,sensitivityThreshold:1e-4,distance:`euclidean`,maxIterations:10,attributes:[],testMode:!1,testCentroids:null}),_i=function(e){return gi(e)},vi=function(e,t,n,r,i){var a=i===`kMedoids`?function(e){return r[e](n)}:function(e){return n[e]},o=function(e){return r[e](t)},s=n,c=t;return hi(e,r.length,a,o,s,c)},yi=function(e,t,n){for(var r=n.length,i=Array(r),a=Array(r),o=Array(t),s=null,c=0;cn)return!1;return!0},wi=function(e,t,n){for(var r=0;ro&&(o=t[c][l],s=l);i[s].push(e[c])}for(var u=0;u=i.threshold||i.mode===`dendrogram`&&e.length===1)return!1;var p=t[a],m=t[r[a]],h=i.mode===`dendrogram`?{left:p,right:m,key:p.key}:{value:p.value.concat(m.value),key:p.key};e[p.index]=h,e.splice(m.index,1),t[p.key]=h;for(var g=0;gn[m.key][_.key]&&(s=n[m.key][_.key])):i.linkage===`max`?(s=n[p.key][_.key],n[p.key][_.key]0&&r.push(i);return r},Ji=function(e,t,n){for(var r=[],i=0;io&&(a=c,o=t[i*e+c])}a>0&&r.push(a)}for(var l=0;lc&&(s=l,c=u)}n[i]=a[s]}return r=Ji(e,t,n),r},Xi=function(e){for(var t=this.cy(),n=this.nodes(),r=Wi(e),i={},a=0;a=E?(D=E,E=k,O=A):k>D&&(D=k);for(var j=0;j0);S[w%r.minIterations*o+L]=R,I+=R}if(I>0&&(w>=r.minIterations-1||w==r.maxIterations-1)){for(var z=0,B=0;B1||i>1)&&(o=!0),u[t]=[],e.outgoers().forEach(function(e){e.isEdge()&&u[t].push(e.id())})}else d[t]=[void 0,e.target().id()]}):a.forEach(function(e){var t=e.id();e.isNode()?(e.degree(!0)%2&&(s?c?o=!0:c=t:s=t),u[t]=[],e.connectedEdges().forEach(function(e){return u[t].push(e.id())})):d[t]=[e.source().id(),e.target().id()]});var f={found:!1,trail:void 0};if(o)return f;if(c&&s){if(i){if(l&&c!=l)return f;l=c}else if(l&&c!=l&&s!=l)return f;else l||=c}else l||=a[0].id();var p=function(e){for(var t=e,n=[e],r,a,o;u[t].length;)r=u[t].shift(),a=d[r][0],o=d[r][1],t==o?!i&&t!=a&&(u[a]=u[a].filter(function(e){return e!=r}),t=a):(u[o]=u[o].filter(function(e){return e!=r}),t=o),n.unshift(r),n.unshift(t);return n},m=[],h=[];for(h=p(l);h.length!=1;)u[h[0]].length==0?(m.unshift(a.getElementById(h.shift())),m.unshift(a.getElementById(h.shift()))):h=p(h.shift()).concat(h);for(var g in m.unshift(a.getElementById(h.shift())),u)if(u[g].length)return f;return f.found=!0,f.trail=this.spawn(m,!0),f}},ea=function(){var e=this,t={},n=0,r=0,i=[],a=[],o={},s=function(n,r){for(var o=a.length-1,s=[],c=e.spawn();a[o].x!=n||a[o].y!=r;)s.push(a.pop().edge),o--;s.push(a.pop().edge),s.forEach(function(n){var r=n.connectedNodes().intersection(e);c.merge(n),r.forEach(function(n){var r=n.id(),i=n.connectedEdges().intersection(e);c.merge(n),t[r].cutVertex?c.merge(i.filter(function(e){return e.isLoop()})):c.merge(i)})}),i.push(c)},c=function(l,u,d){l===d&&(r+=1),t[u]={id:n,low:n++,cutVertex:!1};var f=e.getElementById(u).connectedEdges().intersection(e);if(f.size()===0)i.push(e.spawn(e.getElementById(u)));else{var p,m,h,g;f.forEach(function(e){p=e.source().id(),m=e.target().id(),h=p===u?m:p,h!==d&&(g=e.id(),o[g]||(o[g]=!0,a.push({x:u,y:h,edge:e})),h in t?t[u].low=Math.min(t[u].low,t[h].id):(c(l,h,u),t[u].low=Math.min(t[u].low,t[h].low),t[u].id<=t[h].low&&(t[u].cutVertex=!0,s(u,h))))})}};e.forEach(function(e){if(e.isNode()){var n=e.id();n in t||(r=0,c(n,n),t[n].cutVertex=r>1)}});var l=Object.keys(t).filter(function(e){return t[e].cutVertex}).map(function(t){return e.getElementById(t)});return{cut:e.spawn(l),components:i}},ta={hopcroftTarjanBiconnected:ea,htbc:ea,htb:ea,hopcroftTarjanBiconnectedComponents:ea},na=function(){var e=this,t={},n=0,r=[],i=[],a=e.spawn(e),o=function(s){if(i.push(s),t[s]={index:n,low:n++,explored:!1},e.getElementById(s).connectedEdges().intersection(e).forEach(function(e){var n=e.target().id();n!==s&&(n in t||o(n),t[n].explored||(t[s].low=Math.min(t[s].low,t[n].low)))}),t[s].index===t[s].low){for(var c=e.spawn();;){var l=i.pop();if(c.merge(e.getElementById(l)),t[l].low=t[s].index,t[l].explored=!0,l===s)break}var u=c.edgesWith(c),d=c.merge(u);r.push(d),a=a.difference(d)}};return e.forEach(function(e){if(e.isNode()){var n=e.id();n in t||o(n)}}),{cut:a,components:r}},ra={tarjanStronglyConnected:na,tsc:na,tscc:na,tarjanStronglyConnectedComponents:na},ia={};[an,hn,gn,vn,bn,Sn,En,Br,Hr,Wr,Kr,oi,Ni,Hi,Zi,$i,ta,ra].forEach(function(e){X(ia,e)});var aa=0,oa=1,sa=2,ca=function(e){if(!(this instanceof ca))return new ca(e);this.id=`Thenable/1.0.7`,this.state=aa,this.fulfillValue=void 0,this.rejectReason=void 0,this.onFulfilled=[],this.onRejected=[],this.proxy={then:this.then.bind(this)},typeof e==`function`&&e.call(this,this.fulfill.bind(this),this.reject.bind(this))};ca.prototype={fulfill:function(e){return la(this,oa,`fulfillValue`,e)},reject:function(e){return la(this,sa,`rejectReason`,e)},then:function(e,t){var n=this,r=new ca;return n.onFulfilled.push(fa(e,r,`fulfill`)),n.onRejected.push(fa(t,r,`reject`)),ua(n),r.proxy}};var la=function(e,t,n,r){return e.state===aa&&(e.state=t,e[n]=r,ua(e)),e},ua=function(e){e.state===oa?da(e,`onFulfilled`,e.fulfillValue):e.state===sa&&da(e,`onRejected`,e.rejectReason)},da=function(e,t,n){if(e[t].length!==0){var r=e[t];e[t]=[];var i=function(){for(var e=0;e0}},clearQueue:function(){return function(){var e=this,t=e.length===void 0?[e]:e;if(!(this._private.cy||this).styleEnabled())return this;for(var n=0;n-1}return Oo=t,Oo}var jo,Mo;function No(){if(Mo)return jo;Mo=1;var e=xo();function t(t,n){var r=this.__data__,i=e(r,t);return i<0?(++this.size,r.push([t,n])):r[i][1]=n,this}return jo=t,jo}var Po,Fo;function Io(){if(Fo)return Po;Fo=1;var e=ho(),t=wo(),n=Do(),r=Ao(),i=No();function a(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&n%1==0&&n0&&this.spawn(r).updateStyle().emit(`class`),t},addClass:function(e){return this.toggleClass(e,!0)},hasClass:function(e){var t=this[0];return t!=null&&t._private.classes.has(e)},toggleClass:function(e,t){D(e)||(e=e.match(/\S+/g)||[]);for(var n=this,r=t===void 0,i=[],a=0,o=n.length;a0&&this.spawn(i).updateStyle().emit(`class`),n},removeClass:function(e){return this.toggleClass(e,!1)},flashClass:function(e,t){var n=this;if(t==null)t=250;else if(t===0)return n;return n.addClass(e),setTimeout(function(){n.removeClass(e)},t),n}};_c.className=_c.classNames=_c.classes;var Z={metaChar:`[\\!\\"\\#\\$\\%\\&\\'\\(\\)\\*\\+\\,\\.\\/\\:\\;\\<\\=\\>\\?\\@\\[\\]\\^\\\`\\{\\|\\}\\~]`,comparatorOp:`=|\\!=|>|>=|<|<=|\\$=|\\^=|\\*=`,boolOp:`\\?|\\!|\\^`,string:`"(?:\\\\"|[^"])*"|'(?:\\\\'|[^'])*'`,number:Y,meta:`degree|indegree|outdegree`,separator:`\\s*,\\s*`,descendant:`\\s+`,child:`\\s+>\\s+`,subject:`\\$`,group:`node|edge|\\*`,directedEdge:`\\s+->\\s+`,undirectedEdge:`\\s+<->\\s+`};Z.variable=`(?:[\\w-.]|(?:\\\\`+Z.metaChar+`))+`,Z.className=`(?:[\\w-]|(?:\\\\`+Z.metaChar+`))+`,Z.value=Z.string+`|`+Z.number,Z.id=Z.variable,(function(){var e=Z.comparatorOp.split(`|`),t,n;for(n=0;n=0)&&t!==`=`&&(Z.comparatorOp+=`|\\!`+t)})();var vc=function(){return{checks:[]}},Q={GROUP:0,COLLECTION:1,FILTER:2,DATA_COMPARE:3,DATA_EXIST:4,DATA_BOOL:5,META_COMPARE:6,STATE:7,ID:8,CLASS:9,UNDIRECTED_EDGE:10,DIRECTED_EDGE:11,NODE_SOURCE:12,NODE_TARGET:13,NODE_NEIGHBOR:14,CHILD:15,DESCENDANT:16,PARENT:17,ANCESTOR:18,COMPOUND_SPLIT:19,TRUE:20},yc=[{selector:`:selected`,matches:function(e){return e.selected()}},{selector:`:unselected`,matches:function(e){return!e.selected()}},{selector:`:selectable`,matches:function(e){return e.selectable()}},{selector:`:unselectable`,matches:function(e){return!e.selectable()}},{selector:`:locked`,matches:function(e){return e.locked()}},{selector:`:unlocked`,matches:function(e){return!e.locked()}},{selector:`:visible`,matches:function(e){return e.visible()}},{selector:`:hidden`,matches:function(e){return!e.visible()}},{selector:`:transparent`,matches:function(e){return e.transparent()}},{selector:`:grabbed`,matches:function(e){return e.grabbed()}},{selector:`:free`,matches:function(e){return!e.grabbed()}},{selector:`:removed`,matches:function(e){return e.removed()}},{selector:`:inside`,matches:function(e){return!e.removed()}},{selector:`:grabbable`,matches:function(e){return e.grabbable()}},{selector:`:ungrabbable`,matches:function(e){return!e.grabbable()}},{selector:`:animated`,matches:function(e){return e.animated()}},{selector:`:unanimated`,matches:function(e){return!e.animated()}},{selector:`:parent`,matches:function(e){return e.isParent()}},{selector:`:childless`,matches:function(e){return e.isChildless()}},{selector:`:child`,matches:function(e){return e.isChild()}},{selector:`:orphan`,matches:function(e){return e.isOrphan()}},{selector:`:nonorphan`,matches:function(e){return e.isChild()}},{selector:`:compound`,matches:function(e){return e.isNode()?e.isParent():e.source().isParent()||e.target().isParent()}},{selector:`:loop`,matches:function(e){return e.isLoop()}},{selector:`:simple`,matches:function(e){return e.isSimple()}},{selector:`:active`,matches:function(e){return e.active()}},{selector:`:inactive`,matches:function(e){return!e.active()}},{selector:`:backgrounding`,matches:function(e){return e.backgrounding()}},{selector:`:nonbackgrounding`,matches:function(e){return!e.backgrounding()}}].sort(function(e,t){return ce(e.selector,t.selector)}),bc=function(){for(var e={},t,n=0;n0&&l.edgeCount>0)return zt("The selector `"+e+"` is invalid because it uses both a compound selector and an edge selector"),!1;if(l.edgeCount>1)return zt("The selector `"+e+"` is invalid because it uses multiple edge selectors"),!1;l.edgeCount===1&&zt("The selector `"+e+"` is deprecated. Edge selectors do not take effect on changes to source and target nodes after an edge is added, for performance reasons. Use a class or data selector on edges instead, updating the class or data of an edge when your app detects a change in source or target nodes.")}return!0},toString:function(){if(this.toStringCache!=null)return this.toStringCache;for(var e=function(e){return e??``},t=function(t){return T(t)?`"`+t+`"`:e(t)},n=function(e){return` `+e+` `},r=function(r,a){var o=r.type,s=r.value;switch(o){case Q.GROUP:var c=e(s);return c.substring(0,c.length-1);case Q.DATA_COMPARE:var l=r.field,u=r.operator;return`[`+l+n(e(u))+t(s)+`]`;case Q.DATA_BOOL:var d=r.operator,f=r.field;return`[`+e(d)+f+`]`;case Q.DATA_EXIST:return`[`+r.field+`]`;case Q.META_COMPARE:var p=r.operator;return`[[`+r.field+n(e(p))+t(s)+`]]`;case Q.STATE:return s;case Q.ID:return`#`+s;case Q.CLASS:return`.`+s;case Q.PARENT:case Q.CHILD:return i(r.parent,a)+n(`>`)+i(r.child,a);case Q.ANCESTOR:case Q.DESCENDANT:return i(r.ancestor,a)+` `+i(r.descendant,a);case Q.COMPOUND_SPLIT:var m=i(r.left,a),h=i(r.subject,a),g=i(r.right,a);return m+(m.length>0?` `:``)+h+g;case Q.TRUE:return``}},i=function(e,t){return e.checks.reduce(function(n,i,a){return n+(t===e&&a===0?`$`:``)+r(i,t)},``)},a=``,o=0;o1&&o=0&&(t=t.replace(`!`,``),u=!0),t.indexOf(`@`)>=0&&(t=t.replace(`@`,``),l=!0),(i||o||l)&&(s=!i&&!a?``:``+e,c=``+n),l&&(e=s=s.toLowerCase(),n=c=c.toLowerCase()),t){case`*=`:r=s.indexOf(c)>=0;break;case`$=`:r=s.indexOf(c,s.length-c.length)>=0;break;case`^=`:r=s.indexOf(c)===0;break;case`=`:r=e===n;break;case`>`:d=!0,r=e>n;break;case`>=`:d=!0,r=e>=n;break;case`<`:d=!0,r=e0;){var l=i.shift();t(l),a.add(l.id()),o&&r(i,a,l)}return e}function Uc(e,t,n){if(n.isParent())for(var r=n._private.children,i=0;i1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Uc)};function Wc(e,t,n){if(n.isChild()){var r=n._private.parent;t.has(r.id())||e.push(r)}}Vc.forEachUp=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Wc)};function Gc(e,t,n){Wc(e,t,n),Uc(e,t,n)}Vc.forEachUpAndDown=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return Hc(this,e,t,Gc)},Vc.ancestors=Vc.parents;var Kc=qc={data:hc.data({field:`data`,bindingEvent:`data`,allowBinding:!0,allowSetting:!0,settingEvent:`data`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),removeData:hc.removeData({field:`data`,event:`data`,triggerFnName:`trigger`,triggerEvent:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),scratch:hc.data({field:`scratch`,bindingEvent:`scratch`,allowBinding:!0,allowSetting:!0,settingEvent:`scratch`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeScratch:hc.removeData({field:`scratch`,event:`scratch`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0}),rscratch:hc.data({field:`rscratch`,allowBinding:!1,allowSetting:!0,settingTriggersEvent:!1,allowGetting:!0}),removeRscratch:hc.removeData({field:`rscratch`,triggerEvent:!1}),id:function(){var e=this[0];if(e)return e._private.data.id}},qc;Kc.attr=Kc.data,Kc.removeAttr=Kc.removeData;var Jc=qc,Yc={};function Xc(e){return function(t){var n=this;if(t===void 0&&(t=!0),n.length!==0&&n.isNode()&&!n.removed()){for(var r=0,i=n[0],a=i._private.edges,o=0;ot}),minIndegree:Zc(`indegree`,function(e,t){return et}),minOutdegree:Zc(`outdegree`,function(e,t){return et})}),X(Yc,{totalDegree:function(e){for(var t=0,n=this.nodes(),r=0;r0,d=u;u&&(l=l[0]);var f=d?l.position():{x:0,y:0};t===void 0?i!==void 0&&c.position({x:i.x+f.x,y:i.y+f.y}):c.position(e,t+f[e])}else{var p=n.position(),m=o?n.parent():null,h=m&&m.length>0,g=h;h&&(m=m[0]);var _=g?m.position():{x:0,y:0};return i={x:p.x-_.x,y:p.y-_.y},e===void 0?i:i[e]}}else if(!a)return;return this}},Qc.modelPosition=Qc.point=Qc.position,Qc.modelPositions=Qc.points=Qc.positions,Qc.renderedPoint=Qc.renderedPosition,Qc.relativePoint=Qc.relativePosition;var nl=$c,rl=function(e){switch(e){case`left`:case`right-inside`:return`left`;case`right`:case`left-inside`:return`right`;default:return`center`}},il=function(e){switch(e){case`top`:case`bottom-inside`:return`top`;case`bottom`:case`top-inside`:return`bottom`;default:return`center`}},al=function(e){switch(e){case`left`:return`right`;case`right`:return`left`;case`left-inside`:return`left`;case`right-inside`:return`right`;default:return`center`}},ol=sl={},sl;sl.renderedBoundingBox=function(e){var t=this.boundingBox(e),n=this.cy(),r=n.zoom(),i=n.pan(),a=t.x1*r+i.x,o=t.x2*r+i.x,s=t.y1*r+i.y,c=t.y2*r+i.y;return{x1:a,x2:o,y1:s,y2:c,w:o-a,h:c-s}},sl.dirtyCompoundBoundsCache=function(){var e=arguments.length>0&&arguments[0]!==void 0&&arguments[0],t=this.cy();return!t.styleEnabled()||!t.hasCompoundNodes()||this.forEachUp(function(t){if(t.isParent()){var n=t._private;n.compoundBoundsClean=!1,n.bbCache=null,e||t.emitAndNotify(`bounds`)}}),this},sl.updateCompoundBounds=function(){var e=arguments.length>0&&arguments[0]!==void 0&&arguments[0],t=this.cy();if(!t.styleEnabled()||!t.hasCompoundNodes()||!e&&t.batching())return this;function n(e){if(!e.isParent())return;var t=e._private,n=e.children(),r=e.pstyle(`compound-sizing-wrt-labels`).value===`include`,i={width:{val:e.pstyle(`min-width`).pfValue,left:e.pstyle(`min-width-bias-left`),right:e.pstyle(`min-width-bias-right`)},height:{val:e.pstyle(`min-height`).pfValue,top:e.pstyle(`min-height-bias-top`),bottom:e.pstyle(`min-height-bias-bottom`)}},a=n.boundingBox({includeLabels:r,includeOverlays:!1,useCache:!1}),o=t.position;(a.w===0||a.h===0)&&(a={w:e.pstyle(`width`).pfValue,h:e.pstyle(`height`).pfValue},a.x1=o.x-a.w/2,a.x2=o.x+a.w/2,a.y1=o.y-a.h/2,a.y2=o.y+a.h/2);function s(e,t,n){var r=0,i=0,a=t+n;return e>0&&a>0&&(r=t/a*e,i=n/a*e),{biasDiff:r,biasComplementDiff:i}}function c(e,t,n,r){if(n.units===`%`)switch(r){case`width`:return e>0?n.pfValue*e:0;case`height`:return t>0?n.pfValue*t:0;case`average`:return e>0&&t>0?n.pfValue*(e+t)/2:0;case`min`:return e>0&&t>0?e>t?n.pfValue*t:n.pfValue*e:0;case`max`:return e>0&&t>0?e>t?n.pfValue*e:n.pfValue*t:0;default:return 0}else if(n.units===`px`)return n.pfValue;else return 0}var l=i.width.left.value;i.width.left.units===`px`&&i.width.val>0&&(l=l*100/i.width.val);var u=i.width.right.value;i.width.right.units===`px`&&i.width.val>0&&(u=u*100/i.width.val);var d=i.height.top.value;i.height.top.units===`px`&&i.height.val>0&&(d=d*100/i.height.val);var f=i.height.bottom.value;i.height.bottom.units===`px`&&i.height.val>0&&(f=f*100/i.height.val);var p=s(i.width.val-a.w,l,u),m=p.biasDiff,h=p.biasComplementDiff,g=s(i.height.val-a.h,d,f),_=g.biasDiff,v=g.biasComplementDiff;t.autoPadding=c(a.w,a.h,e.pstyle(`padding`),e.pstyle(`padding-relative-to`).value),t.autoWidth=Math.max(a.w,i.width.val),o.x=(-m+a.x1+a.x2+h)/2,t.autoHeight=Math.max(a.h,i.height.val),o.y=(-_+a.y1+a.y2+v)/2}for(var r=0;re.x2?r:e.x2,e.y1=ne.y2?i:e.y2,e.w=e.x2-e.x1,e.h=e.y2-e.y1)},ul=function(e,t){return t==null?e:ll(e,t.x1,t.y1,t.x2,t.y2)},dl=function(e,t,n){return Xt(e,t,n)},fl=function(e,t,n){if(!t.cy().headless()){var r=t._private,i=r.rstyle,a=i.arrowWidth/2,o=t.pstyle(n+`-arrow-shape`).value,s,c;if(o!==`none`){n===`source`?(s=i.srcX,c=i.srcY):n===`target`?(s=i.tgtX,c=i.tgtY):(s=i.midX,c=i.midY);var l=r.arrowBounds=r.arrowBounds||{},u=l[n]=l[n]||{};u.x1=s-a,u.y1=c-a,u.x2=s+a,u.y2=c+a,u.w=u.x2-u.x1,u.h=u.y2-u.y1,$n(u,1),ll(e,u.x1,u.y1,u.x2,u.y2)}}},pl=function(e,t,n){if(!t.cy().headless()){var r=n?n+`-`:``,i=t._private,a=i.rstyle;if(t.pstyle(r+`label`).strValue){var o=t.pstyle(`text-halign`),s=t.pstyle(`text-valign`),c=dl(a,`labelWidth`,n),l=dl(a,`labelHeight`,n),u=dl(a,`labelX`,n),d=dl(a,`labelY`,n),f=t.pstyle(r+`text-margin-x`).pfValue,p=t.pstyle(r+`text-margin-y`).pfValue,m=t.isEdge(),h=t.pstyle(r+`text-rotation`),g=t.pstyle(`text-outline-width`).pfValue,_=t.pstyle(`text-border-width`).pfValue/2,v=t.pstyle(`text-background-padding`).pfValue,y=2,b=l,x=c,S=x/2,C=b/2,w,T,E,D;if(m)w=u-S,T=u+S,E=d-C,D=d+C;else{switch(rl(o.value)){case`left`:w=u-x,T=u;break;case`center`:w=u-S,T=u+S;break;case`right`:w=u,T=u+x}switch(il(s.value)){case`top`:E=d-b,D=d;break;case`center`:E=d-C,D=d+C;break;case`bottom`:E=d,D=d+b}}var O=f-Math.max(g,_)-v-y,k=f+Math.max(g,_)+v+y,A=p-Math.max(g,_)-v-y,j=p+Math.max(g,_)+v+y;w+=O,T+=k,E+=A,D+=j;var M=n||`main`,N=i.labelBounds,P=N[M]=N[M]||{};P.x1=w,P.y1=E,P.x2=T,P.y2=D,P.w=T-w,P.h=D-E,P.leftPad=O,P.rightPad=k,P.topPad=A,P.botPad=j;var F=m&&h.strValue===`autorotate`,I=h.pfValue!=null&&h.pfValue!==0;if(F||I){var L=F?dl(i.rstyle,`labelAngle`,n):h.pfValue,R=Math.cos(L),z=Math.sin(L),B=(w+T)/2,V=(E+D)/2;if(!m){switch(rl(o.value)){case`left`:B=T;break;case`right`:B=w}switch(il(s.value)){case`top`:V=D;break;case`bottom`:V=E}}var H=function(e,t){return e-=B,t-=V,{x:e*R-t*z+B,y:e*z+t*R+V}},U=H(w,E),W=H(w,D),G=H(T,E),K=H(T,D);w=Math.min(U.x,W.x,G.x,K.x),T=Math.max(U.x,W.x,G.x,K.x),E=Math.min(U.y,W.y,G.y,K.y),D=Math.max(U.y,W.y,G.y,K.y)}var q=M+`Rot`,J=N[q]=N[q]||{};J.x1=w,J.y1=E,J.x2=T,J.y2=D,J.w=T-w,J.h=D-E,ll(e,w,E,T,D),ll(i.labelBounds.all,w,E,T,D)}return e}},ml=function(e,t){if(!t.cy().headless()){var n=t.pstyle(`outline-opacity`).value,r=t.pstyle(`outline-width`).value+t.pstyle(`outline-offset`).value;hl(e,t,n,r,`outside`,r/2)}},hl=function(e,t,n,r,i,a){if(!(n===0||r<=0||i===`inside`)){var o=t.cy().renderer(),s=o.nodeShapes[o.getNodeShape(t)];if(s){var c=t.position(),l=c.x,u=c.y,d=t.width(),f=t.height();s.hasMiterBounds?(i===`center`&&(r/=2),ul(e,s.miterBounds(l,u,d,f,r))):a!=null&&a>0&&er(e,[a,a,a,a])}}},gl=function(e,t){if(!t.cy().headless()){var n=t.pstyle(`border-opacity`).value,r=t.pstyle(`border-width`).pfValue,i=t.pstyle(`border-position`).value;hl(e,t,n,r,i)}},_l=function(e,t){var n=e._private.cy,r=n.styleEnabled(),i=n.headless(),a=Jn(),o=e._private,s=e.isNode(),c=e.isEdge(),l,u,d,f,p,m,h=o.rstyle,g=s&&r?e.pstyle(`bounds-expansion`).pfValue:[0],_=function(e){return e.pstyle(`display`).value!==`none`},v=!r||_(e)&&(!c||_(e.source())&&_(e.target()));if(v){var y=0,b=0;r&&t.includeOverlays&&(y=e.pstyle(`overlay-opacity`).value,y!==0&&(b=e.pstyle(`overlay-padding`).value));var x=0,S=0;r&&t.includeUnderlays&&(x=e.pstyle(`underlay-opacity`).value,x!==0&&(S=e.pstyle(`underlay-padding`).value));var C=Math.max(b,S),w=0,T=0;if(r&&(w=e.pstyle(`width`).pfValue,T=w/2),s&&t.includeNodes){var E=e.position();p=E.x,m=E.y;var D=e.outerWidth()/2,O=e.outerHeight()/2;l=p-D,u=p+D,d=m-O,f=m+O,ll(a,l,d,u,f),r&&ml(a,e),r&&t.includeOutlines&&!i&&ml(a,e),r&&gl(a,e)}else if(c&&t.includeEdges){if(r&&!i){var k=e.pstyle(`curve-style`).strValue;if(l=Math.min(h.srcX,h.midX,h.tgtX),u=Math.max(h.srcX,h.midX,h.tgtX),d=Math.min(h.srcY,h.midY,h.tgtY),f=Math.max(h.srcY,h.midY,h.tgtY),l-=T,u+=T,d-=T,f+=T,ll(a,l,d,u,f),k===`haystack`){var A=h.haystackPts;if(A&&A.length===2){if(l=A[0].x,d=A[0].y,u=A[1].x,f=A[1].y,l>u){var j=l;l=u,u=j}if(d>f){var M=d;d=f,f=M}ll(a,l-T,d-T,u+T,f+T)}}else if(k===`bezier`||k===`unbundled-bezier`||ee(k,`segments`)||ee(k,`taxi`)){var N;switch(k){case`bezier`:case`unbundled-bezier`:N=h.bezierPts;break;case`segments`:case`taxi`:case`round-segments`:case`round-taxi`:N=h.linePts}if(N!=null)for(var P=0;Pu){var R=l;l=u,u=R}if(d>f){var z=d;d=f,f=z}l-=T,u+=T,d-=T,f+=T,ll(a,l,d,u,f)}}if(r&&t.includeEdges&&c&&(fl(a,e,`mid-source`),fl(a,e,`mid-target`),fl(a,e,`source`),fl(a,e,`target`)),r&&e.pstyle(`ghost`).value===`yes`){var B=e.pstyle(`ghost-offset-x`).pfValue,V=e.pstyle(`ghost-offset-y`).pfValue;ll(a,a.x1+B,a.y1+V,a.x2+B,a.y2+V)}var H=o.bodyBounds=o.bodyBounds||{};tr(H,a),er(H,g),$n(H,1),r&&(l=a.x1,u=a.x2,d=a.y1,f=a.y2,ll(a,l-C,d-C,u+C,f+C));var U=o.overlayBounds=o.overlayBounds||{};tr(U,a),er(U,g),$n(U,1);var W=o.labelBounds=o.labelBounds||{};W.all==null?W.all=Jn():Xn(W.all),r&&t.includeLabels&&(t.includeMainLabels&&pl(a,e,null),c&&(t.includeSourceLabels&&pl(a,e,`source`),t.includeTargetLabels&&pl(a,e,`target`)))}return a.x1=cl(a.x1),a.y1=cl(a.y1),a.x2=cl(a.x2),a.y2=cl(a.y2),a.w=cl(a.x2-a.x1),a.h=cl(a.y2-a.y1),a.w>0&&a.h>0&&v&&(er(a,g),$n(a,1)),a},vl=function(e){var t=0,n=function(e){return+!!e<0&&arguments[0]!==void 0?arguments[0]:Hl,t=arguments.length>1?arguments[1]:void 0,n=0;n=0;s--)o(s);return this},Wl.removeAllListeners=function(){return this.removeListener(`*`)},Wl.emit=Wl.trigger=function(e,t,n){var r=this.listeners,i=r.length;return this.emitting++,D(t)||(t=[t]),ql(this,function(e,a){n!=null&&(r=[{event:a.event,type:a.type,namespace:a.namespace,callback:n}],i=r.length);for(var o=function(){var n=r[s];if(n.type===a.type&&(!n.namespace||n.namespace===a.namespace||n.namespace===zl)&&e.eventMatches(e.context,n,a)){var i=[a];t!=null&&Yt(i,t),e.beforeEmit(e.context,n,a),n.conf&&n.conf.one&&(e.listeners=e.listeners.filter(function(e){return e!==n}));var o=e.callbackContext(e.context,n,a),c=n.callback.apply(o,i);e.afterEmit(e.context,n,a),c===!1&&(a.stopPropagation(),a.preventDefault())}},s=0;s1&&!r){var i=this.length-1,a=this[i],o=a._private.data.id;this[i]=void 0,this[e]=a,n.set(o,{ele:a,index:e})}return this.length--,this},unmergeOne:function(e){e=e[0];var t=this._private,n=e._private.data.id,r=t.map.get(n);if(!r)return this;var i=r.index;return this.unmergeAt(i),this},unmerge:function(e){var t=this._private.cy;if(!e)return this;if(e&&T(e)){var n=e;e=t.mutableElements().filter(n)}for(var r=0;r=0;t--){var n=this[t];e(n)&&this.unmergeAt(t)}return this},map:function(e,t){for(var n=[],r=this,i=0;in&&(n=s,r=o)}return{value:n,ele:r}},min:function(e,t){for(var n=1/0,r,i=this,a=0;a=0&&i`u`?`undefined`:g(Symbol))!=e&&g(Symbol.iterator)!=e&&(tu[Symbol.iterator]=function(){var e=this,t={value:void 0,done:!1},n=0,r=this.length;return s({next:function(){return n1&&arguments[1]!==void 0?arguments[1]:!0,n=this[0],r=n.cy();if(r.styleEnabled()&&n)return n._private.styleDirty&&(n._private.styleDirty=!1,r.style().apply(n)),n._private.style[e]??(t?r.style().getDefaultProperty(e):null)},numericStyle:function(e){var t=this[0];if(t.cy().styleEnabled()&&t){var n=t.pstyle(e);return n.pfValue===void 0?n.value:n.pfValue}},numericStyleUnits:function(e){var t=this[0];if(t.cy().styleEnabled()&&t)return t.pstyle(e).units},renderedStyle:function(e){var t=this.cy();if(!t.styleEnabled())return this;var n=this[0];if(n)return t.style().getRenderedStyle(n,e)},style:function(e,t){var n=this.cy();if(!n.styleEnabled())return this;var r=!1,i=n.style();if(O(e)){var a=e;i.applyBypass(this,a,r),this.emitAndNotify(`style`)}else if(T(e)){if(t===void 0){var o=this[0];return o?i.getStylePropertyValue(o,e):void 0}i.applyBypass(this,e,t,r),this.emitAndNotify(`style`)}else if(e===void 0){var s=this[0];return s?i.getRawStyle(s):void 0}return this},removeStyle:function(e){var t=this.cy();if(!t.styleEnabled())return this;var n=!1,r=t.style(),i=this;if(e===void 0)for(var a=0;a0&&t.push(u[0]),t.push(s[0])}return this.spawn(t,!0).filter(e)},`neighborhood`),closedNeighborhood:function(e){return this.neighborhood().add(this).filter(e)},openNeighborhood:function(e){return this.neighborhood(e)}}),mu.neighbourhood=mu.neighborhood,mu.closedNeighbourhood=mu.closedNeighborhood,mu.openNeighbourhood=mu.openNeighborhood,X(mu,{source:Bc(function(e){var t=this[0],n;return t&&(n=t._private.source||t.cy().collection()),n&&e?n.filter(e):n},`source`),target:Bc(function(e){var t=this[0],n;return t&&(n=t._private.target||t.cy().collection()),n&&e?n.filter(e):n},`target`),sources:vu({attr:`source`}),targets:vu({attr:`target`})});function vu(e){return function(t){for(var n=[],r=0;r0);return a},component:function(){var e=this[0];return e.cy().mutableElements().components(e)[0]}}),mu.componentsOf=mu.components;var xu=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0&&arguments[2],r=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(e===void 0){Lt(`A collection must have a reference to the core`);return}var i=new Qt,a=!1;if(!t)t=[];else if(t.length>0&&O(t[0])&&!P(t[0])){a=!0;for(var o=[],s=new tn,c=0,l=t.length;c0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=this,r=n.cy(),i=r._private,a=[],o=[],s,c=0,l=n.length;c0){for(var I=s.length===n.length?n:new xu(r,s),L=0;L0&&arguments[0]!==void 0?arguments[0]:!0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=this,r=[],i={},a=n._private.cy;function o(e){for(var t=e._private.edges,n=0;n0&&(e?E.emitAndNotify(`remove`):t&&E.emit(`remove`));for(var D=0;D0?i=o:r=o;while(Math.abs(a)>1e-7&&++s<10);return o}function _(t){for(var r=0,o=1,s=i-1;o!==s&&c[o]<=t;++o)r+=a;--o;var l=(t-c[o])/(c[o+1]-c[o]),u=r+l*a,d=p(u,e,n);return d>=.001?m(t,u):d===0?u:g(t,r,r+a)}var v=!1;function y(){v=!0,(e!==t||n!==r)&&h()}var b=function(i){return v||y(),e===t&&n===r?i:i===0?0:i===1?1:f(_(i),t,r)};b.getControlPoints=function(){return[{x:e,y:t},{x:n,y:r}]};var x=`generateBezier(`+[e,t,n,r]+`)`;return b.toString=function(){return x},b}var Tu=function(){function e(e){return-e.tension*e.x-e.friction*e.v}function t(t,n,r){var i={x:t.x+r.dx*n,v:t.v+r.dv*n,tension:t.tension,friction:t.friction};return{dx:i.v,dv:e(i)}}function n(n,r){var i={dx:n.v,dv:e(n)},a=t(n,r*.5,i),o=t(n,r*.5,a),s=t(n,r,o),c=1/6*(i.dx+2*(a.dx+o.dx)+s.dx),l=1/6*(i.dv+2*(a.dv+o.dv)+s.dv);return n.x+=c*r,n.v+=l*r,n}return function e(t,r,i){var a={x:-1,v:0,tension:null,friction:null},o=[0],s=0,c=1/1e4,l=16/1e3,u,d,f;for(t=parseFloat(t)||500,r=parseFloat(r)||20,i||=null,a.tension=t,a.friction=r,u=i!==null,u?(s=e(t,r),d=s/i*l):d=l;f=n(f||a,d),o.push(1+f.x),s+=16,Math.abs(f.x)>c&&Math.abs(f.v)>c;);return u?function(e){return o[e*(o.length-1)|0]}:s}}(),Eu=function(e,t,n,r){var i=wu(e,t,n,r);return function(e,t,n){return e+(t-e)*i(n)}},Du={linear:function(e,t,n){return e+(t-e)*n},ease:Eu(.25,.1,.25,1),"ease-in":Eu(.42,0,1,1),"ease-out":Eu(0,0,.58,1),"ease-in-out":Eu(.42,0,.58,1),"ease-in-sine":Eu(.47,0,.745,.715),"ease-out-sine":Eu(.39,.575,.565,1),"ease-in-out-sine":Eu(.445,.05,.55,.95),"ease-in-quad":Eu(.55,.085,.68,.53),"ease-out-quad":Eu(.25,.46,.45,.94),"ease-in-out-quad":Eu(.455,.03,.515,.955),"ease-in-cubic":Eu(.55,.055,.675,.19),"ease-out-cubic":Eu(.215,.61,.355,1),"ease-in-out-cubic":Eu(.645,.045,.355,1),"ease-in-quart":Eu(.895,.03,.685,.22),"ease-out-quart":Eu(.165,.84,.44,1),"ease-in-out-quart":Eu(.77,0,.175,1),"ease-in-quint":Eu(.755,.05,.855,.06),"ease-out-quint":Eu(.23,1,.32,1),"ease-in-out-quint":Eu(.86,0,.07,1),"ease-in-expo":Eu(.95,.05,.795,.035),"ease-out-expo":Eu(.19,1,.22,1),"ease-in-out-expo":Eu(1,0,0,1),"ease-in-circ":Eu(.6,.04,.98,.335),"ease-out-circ":Eu(.075,.82,.165,1),"ease-in-out-circ":Eu(.785,.135,.15,.86),spring:function(e,t,n){if(n===0)return Du.linear;var r=Tu(e,t,n);return function(e,t,n){return e+(t-e)*r(n)}},"cubic-bezier":Eu};function Ou(e,t,n,r,i){if(r===1||t===n)return n;var a=i(t,n,r);return e==null?a:((e.roundValue||e.color)&&(a=Math.round(a)),e.min!==void 0&&(a=Math.max(a,e.min)),e.max!==void 0&&(a=Math.min(a,e.max)),a)}function ku(e,t){return e.pfValue!=null||e.value!=null?e.pfValue!=null&&(t==null||t.type.units!==`%`)?e.pfValue:e.value:e}function Au(e,t,n,r,i){var a=i==null?null:i.type;n<0?n=0:n>1&&(n=1);var o=ku(e,i),s=ku(t,i);if(A(o)&&A(s))return Ou(a,o,s,n,r);if(D(o)&&D(s)){for(var c=[],l=0;l0?(d===`spring`&&f.push(o.duration),o.easingImpl=Du[d].apply(null,f)):o.easingImpl=Du[d]}}var p=o.easingImpl,m=o.duration===0?1:(n-c)/o.duration;if(o.applying&&(m=o.progress),m<0?m=0:m>1&&(m=1),o.delay==null){var h=o.startPosition,g=o.position;if(g&&i&&!e.locked()){var _={};Mu(h.x,g.x)&&(_.x=Au(h.x,g.x,m,p)),Mu(h.y,g.y)&&(_.y=Au(h.y,g.y,m,p)),e.position(_)}var v=o.startPan,y=o.pan,b=a.pan,x=y!=null&&r;x&&(Mu(v.x,y.x)&&(b.x=Au(v.x,y.x,m,p)),Mu(v.y,y.y)&&(b.y=Au(v.y,y.y,m,p)),e.emit(`pan`));var S=o.startZoom,C=o.zoom,w=C!=null&&r;w&&(Mu(S,C)&&(a.zoom=qn(a.minZoom,Au(S,C,m,p),a.maxZoom)),e.emit(`zoom`)),(x||w)&&e.emit(`viewport`);var E=o.style;if(E&&E.length>0&&i){for(var D=0;D=0;t--){var n=e[t];n()}e.splice(0,e.length)},u=a.length-1;u>=0;u--){var d=a[u],f=d._private;if(f.stopped){a.splice(u,1),f.hooked=!1,f.playing=!1,f.started=!1,l(f.frames);continue}!f.playing&&!f.applying||(f.playing&&f.applying&&(f.applying=!1),f.started||Nu(t,d,e),ju(t,d,e,n),f.applying&&=!1,l(f.frames),f.step!=null&&f.step(e),d.completed()&&(a.splice(u,1),f.hooked=!1,f.playing=!1,f.started=!1,l(f.completes)),s=!0)}return!n&&a.length===0&&o.length===0&&r.push(t),s}for(var a=!1,o=0;o0?t.notify(`draw`,n):t.notify(`draw`)),n.unmerge(r),t.emit(`step`)}var Fu={animate:hc.animate(),animation:hc.animation(),animated:hc.animated(),clearQueue:hc.clearQueue(),delay:hc.delay(),delayAnimation:hc.delayAnimation(),stop:hc.stop(),addToAnimationPool:function(e){var t=this;t.styleEnabled()&&t._private.aniEles.merge(e)},stopAnimationLoop:function(){this._private.animationsRunning=!1},startAnimationLoop:function(){var e=this;if(e._private.animationsRunning=!0,!e.styleEnabled())return;function t(){e._private.animationsRunning&&dt(function(n){Pu(n,e),t()})}var n=e.renderer();n&&n.beforeRender?n.beforeRender(function(t,n){Pu(n,e)},n.beforeRenderPriorities.animations):t()}},Iu={qualifierCompare:function(e,t){return e==null||t==null?e==null&&t==null:e.sameText(t)},eventMatches:function(e,t,n){var r=t.qualifier;return r==null||e!==n.target&&P(n.target)&&r.matches(n.target)},addEventFields:function(e,t){t.cy=e,t.target=e},callbackContext:function(e,t,n){return t.qualifier==null?e:n.target}},Lu=function(e){return T(e)?new Lc(e):e},Ru={createEmitter:function(){var e=this._private;return e.emitter||=new Ul(Iu,this),this},emitter:function(){return this._private.emitter},on:function(e,t,n){return this.emitter().on(e,Lu(t),n),this},removeListener:function(e,t,n){return this.emitter().removeListener(e,Lu(t),n),this},removeAllListeners:function(){return this.emitter().removeAllListeners(),this},one:function(e,t,n){return this.emitter().one(e,Lu(t),n),this},once:function(e,t,n){return this.emitter().one(e,Lu(t),n),this},emit:function(e,t){return this.emitter().emit(e,t),this},emitAndNotify:function(e,t){return this.emit(e),this.notify(e,t),this}};hc.eventAliasesOn(Ru);var zu={png:function(e){var t=this._private.renderer;return e||={},t.png(e)},jpg:function(e){var t=this._private.renderer;return e||={},e.bg=e.bg||`#fff`,t.jpg(e)}};zu.jpeg=zu.jpg;var Bu={layout:function(e){var t=this;if(e==null){Lt(`Layout options must be specified to make a layout`);return}if(e.name==null){Lt("A `name` must be specified to make a layout");return}var n=e.name,r=t.extension(`layout`,n);if(r==null){Lt("No such layout `"+n+"` found. Did you forget to import it and `cytoscape.use()` it?");return}return new r(X({},e,{cy:t,eles:T(e.eles)?t.$(e.eles):e.eles==null?t.$():e.eles}))}};Bu.createLayout=Bu.makeLayout=Bu.layout;var Vu={notify:function(e,t){var n=this._private;if(this.batching()){n.batchNotifications=n.batchNotifications||{};var r=n.batchNotifications[e]=n.batchNotifications[e]||this.collection();t!=null&&r.merge(t);return}if(n.notificationsEnabled){var i=this.renderer();this.destroyed()||!i||i.notify(e,t)}},notifications:function(e){var t=this._private;return e===void 0?t.notificationsEnabled:(t.notificationsEnabled=!!e,this)},noNotifications:function(e){this.notifications(!1),e(),this.notifications(!0)},batching:function(){return this._private.batchCount>0},startBatch:function(){var e=this._private;return e.batchCount??=0,e.batchCount===0&&(e.batchStyleEles=this.collection(),e.batchNotifications={}),e.batchCount++,this},endBatch:function(){var e=this._private;if(e.batchCount===0)return this;if(e.batchCount--,e.batchCount===0){e.batchStyleEles.updateStyle();var t=this.renderer();Object.keys(e.batchNotifications).forEach(function(n){var r=e.batchNotifications[n];r.empty()?t.notify(n):t.notify(n,r)})}return this},batch:function(e){return this.startBatch(),e(),this.endBatch(),this},batchData:function(e){var t=this;return this.batch(function(){for(var n=Object.keys(e),r=0;r0;)t.removeChild(t.childNodes[0]);e._private.renderer=null,e.mutableElements().forEach(function(e){var t=e._private;t.rscratch={},t.rstyle={},t.animation.current=[],t.animation.queue=[]})},onRender:function(e){return this.on(`render`,e)},offRender:function(e){return this.off(`render`,e)}};Uu.invalidateDimensions=Uu.resize;var Wu={collection:function(e,t){return T(e)?this.$(e):N(e)?e.collection():D(e)?(t||={},new xu(this,e,t.unique,t.removed)):new xu(this)},nodes:function(e){var t=this.$(function(e){return e.isNode()});return e?t.filter(e):t},edges:function(e){var t=this.$(function(e){return e.isEdge()});return e?t.filter(e):t},$:function(e){var t=this._private.elements;return e?t.filter(e):t.spawnSelf()},mutableElements:function(){return this._private.elements}};Wu.elements=Wu.filter=Wu.$;var Gu={},Ku=`t`,qu=`f`;Gu.apply=function(e){for(var t=this,n=t._private.cy.collection(),r=0;r0;if(f||d&&p){var m=void 0;f&&p||f?m=l.properties:p&&(m=l.mappedProperties);for(var h=0;h1&&(b=1),s.color){var S=r.valueMin[0],C=r.valueMax[0],w=r.valueMin[1],T=r.valueMax[1],E=r.valueMin[2],D=r.valueMax[2],O=r.valueMin[3]==null?1:r.valueMin[3],k=r.valueMax[3]==null?1:r.valueMax[3],j=[Math.round(S+(C-S)*b),Math.round(w+(T-w)*b),Math.round(E+(D-E)*b),Math.round(O+(k-O)*b)];a={bypass:r.bypass,name:r.name,value:j,strValue:`rgb(`+j[0]+`, `+j[1]+`, `+j[2]+`)`}}else if(s.number){var M=r.valueMin+(r.valueMax-r.valueMin)*b;a=this.parse(r.name,M,r.bypass,f)}else return!1;if(!a)return h(),!1;a.mapping=r,r=a;break;case o.data:for(var N=r.field.split(`.`),P=d.data,F=0;F0&&a>0){for(var s={},c=!1,l=0;l0?e.delayAnimation(o).play().promise().then(t):t()}).then(function(){return e.animation({style:s,duration:a,easing:e.pstyle(`transition-timing-function`).value,queue:!1}).play().promise()}).then(function(){n.removeBypasses(e,i),e.emitAndNotify(`style`),r.transitioning=!1})}else r.transitioning&&=(this.removeBypasses(e,i),e.emitAndNotify(`style`),!1)},Gu.checkTrigger=function(e,t,n,r,i,a){var o=this.properties[t],s=i(o);e.removed()||s!=null&&s(n,r,e)&&a(o)},Gu.checkZOrderTrigger=function(e,t,n,r){var i=this;this.checkTrigger(e,t,n,r,function(e){return e.triggersZOrder},function(){i._private.cy.notify(`zorder`,e)})},Gu.checkBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBounds},function(t){e.dirtyCompoundBoundsCache(),e.dirtyBoundingBoxCache()})},Gu.checkConnectedEdgesBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBoundsOfConnectedEdges},function(t){e.connectedEdges().forEach(function(e){e.dirtyBoundingBoxCache()})})},Gu.checkParallelEdgesBoundsTrigger=function(e,t,n,r){this.checkTrigger(e,t,n,r,function(e){return e.triggersBoundsOfParallelEdges},function(t){e.parallelEdges().forEach(function(e){e.dirtyBoundingBoxCache()})})},Gu.checkTriggers=function(e,t,n,r){e.dirtyStyleCache(),this.checkZOrderTrigger(e,t,n,r),this.checkBoundsTrigger(e,t,n,r),this.checkConnectedEdgesBoundsTrigger(e,t,n,r),this.checkParallelEdgesBoundsTrigger(e,t,n,r)};var Ju={};Ju.applyBypass=function(e,t,n,r){var i=this,a=[],o=!0;if(t===`*`||t===`**`){if(n!==void 0)for(var s=0;si.length?r.substr(i.length):``}function c(){a=a.length>o.length?a.substr(o.length):``}for(;!r.match(/^\s*$/);){var l=r.match(/^\s*((?:.|\s)+?)\s*\{((?:.|\s)+?)\}/);if(!l){zt(`Halting stylesheet parsing: String stylesheet contains more to parse but no selector and block found in: `+r);break}i=l[0];var u=l[1];if(u!==`core`&&new Lc(u).invalid){zt(`Skipping parsing of block: Invalid selector found in string stylesheet: `+u),s();continue}var d=l[2],f=!1;a=d;for(var p=[];!a.match(/^\s*$/);){var m=a.match(/^\s*(.+?)\s*:\s*(.+?)(?:\s*;|\s*$)/);if(!m){zt(`Skipping parsing of block: Invalid formatting of style property and value definitions found in:`+d),f=!0;break}o=m[0];var h=m[1],g=m[2];if(!t.properties[h]){zt(`Skipping property: Invalid property name in: `+o),c();continue}if(!n.parse(h,g)){zt(`Skipping property: Invalid property definition in: `+o),c();continue}p.push({name:h,val:g}),c()}if(f){s();break}n.selector(u);for(var _=0;_=7&&t[0]===`d`&&(u=new RegExp(s.data.regex).exec(t))){if(n)return!1;var f=s.data;return{name:e,value:u,strValue:``+t,mapped:f,field:u[1],bypass:n}}if(t.length>=10&&t[0]===`m`&&(d=new RegExp(s.mapData.regex).exec(t))){if(n||l.multiple)return!1;var p=s.mapData;if(!(l.color||l.number))return!1;var m=this.parse(e,d[4]);if(!m||m.mapped)return!1;var h=this.parse(e,d[5]);if(!h||h.mapped)return!1;if(m.pfValue===h.pfValue||m.strValue===h.strValue)return zt("`"+e+`: `+t+"` is not a valid mapper because the output range is zero; converting to `"+e+`: `+m.strValue+"`"),this.parse(e,m.strValue);if(l.color){var g=m.value,_=h.value;if(g[0]===_[0]&&g[1]===_[1]&&g[2]===_[2]&&(g[3]===_[3]||(g[3]==null||g[3]===1)&&(_[3]==null||_[3]===1)))return!1}return{name:e,value:d,strValue:``+t,mapped:p,field:d[1],fieldMin:parseFloat(d[2]),fieldMax:parseFloat(d[3]),valueMin:m.value,valueMax:h.value,bypass:n}}}if(l.multiple&&r!==`multiple`){var v=c?t.split(/\s+/):D(t)?t:[t];if(l.evenMultiple&&v.length%2!=0)return null;for(var y=[],b=[],x=[],S=``,C=!1,w=0;w0?` `:``)+O.strValue}return l.validate&&!l.validate(y,b)?null:l.singleEnum&&C?y.length===1&&T(y[0])?{name:e,value:y[0],strValue:y[0],bypass:n}:null:{name:e,value:y,pfValue:x,strValue:S,bypass:n,units:b}}var k=function(){for(var r=0;rl.max||l.strictMax&&t===l.max))return null;var F={name:e,value:t,strValue:``+t+(A||``),units:A,bypass:n};return F.pfValue=l.unitless||A!==`px`&&A!==`em`||A===`px`||!A?t:this.getEmSizeInPixels()*t,(A===`ms`||A===`s`)&&(F.pfValue=A===`ms`?t:1e3*t),(A===`deg`||A===`rad`)&&(F.pfValue=A===`rad`?t:Ln(t)),A===`%`&&(F.pfValue=t/100),F}if(l.propList){var I=[],L=``+t;if(L!==`none`){for(var R=L.split(/\s*,\s*|\s+/),z=0;z0&&o>0&&!isNaN(n.w)&&!isNaN(n.h)&&n.w>0&&n.h>0){s=Math.min((a-2*t)/n.w,(o-2*t)/n.h),s=s>this._private.maxZoom?this._private.maxZoom:s,s=s=n.minZoom&&(n.maxZoom=t),this},minZoom:function(e){return e===void 0?this._private.minZoom:this.zoomRange({min:e})},maxZoom:function(e){return e===void 0?this._private.maxZoom:this.zoomRange({max:e})},getZoomedViewport:function(e){var t=this._private,n=t.pan,r=t.zoom,i,a,o=!1;if(t.zoomingEnabled||(o=!0),A(e)?a=e:O(e)&&(a=e.level,e.position==null?e.renderedPosition!=null&&(i=e.renderedPosition):i=On(e.position,r,n),i!=null&&!t.panningEnabled&&(o=!0)),a=a>t.maxZoom?t.maxZoom:a,a=at.maxZoom||!t.zoomingEnabled?a=!0:(t.zoom=s,i.push(`zoom`))}if(r&&(!a||!e.cancelOnFailedZoom)&&t.panningEnabled){var c=e.pan;A(c.x)&&(t.pan.x=c.x,o=!1),A(c.y)&&(t.pan.y=c.y,o=!1),o||i.push(`pan`)}return i.length>0&&(i.push(`viewport`),this.emit(i.join(` `)),this.notify(`viewport`)),this},center:function(e){var t=this.getCenterPan(e);return t&&(this._private.pan=t,this.emit(`pan viewport`),this.notify(`viewport`)),this},getCenterPan:function(e,t){if(this._private.panningEnabled){if(T(e)){var n=e;e=this.mutableElements().filter(n)}else N(e)||(e=this.mutableElements());if(e.length!==0){var r=e.boundingBox(),i=this.width(),a=this.height();return t=t===void 0?this._private.zoom:t,{x:(i-t*(r.x1+r.x2))/2,y:(a-t*(r.y1+r.y2))/2}}}},reset:function(){return!this._private.panningEnabled||!this._private.zoomingEnabled||this.viewport({pan:{x:0,y:0},zoom:1}),this},invalidateSize:function(){this._private.sizeCache=null},size:function(){var e=this._private,t=e.container,n=this;return e.sizeCache=e.sizeCache||(t?function(){var e=n.window().getComputedStyle(t),r=function(t){return parseFloat(e.getPropertyValue(t))};return{width:t.clientWidth-r(`padding-left`)-r(`padding-right`),height:t.clientHeight-r(`padding-top`)-r(`padding-bottom`)}}():{width:1,height:1})},width:function(){return this.size().width},height:function(){return this.size().height},extent:function(){var e=this._private.pan,t=this._private.zoom,n=this.renderedExtent(),r={x1:(n.x1-e.x)/t,x2:(n.x2-e.x)/t,y1:(n.y1-e.y)/t,y2:(n.y2-e.y)/t};return r.w=r.x2-r.x1,r.h=r.y2-r.y1,r},renderedExtent:function(){var e=this.width(),t=this.height();return{x1:0,y1:0,x2:e,y2:t,w:e,h:t}},multiClickDebounceTime:function(e){if(e)this._private.multiClickDebounceTime=e;else return this._private.multiClickDebounceTime;return this}};ad.centre=ad.center,ad.autolockNodes=ad.autolock,ad.autoungrabifyNodes=ad.autoungrabify;var od={data:hc.data({field:`data`,bindingEvent:`data`,allowBinding:!0,allowSetting:!0,settingEvent:`data`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeData:hc.removeData({field:`data`,event:`data`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0}),scratch:hc.data({field:`scratch`,bindingEvent:`scratch`,allowBinding:!0,allowSetting:!0,settingEvent:`scratch`,settingTriggersEvent:!0,triggerFnName:`trigger`,allowGetting:!0,updateStyle:!0}),removeScratch:hc.removeData({field:`scratch`,event:`scratch`,triggerFnName:`trigger`,triggerEvent:!0,updateStyle:!0})};od.attr=od.data,od.removeAttr=od.removeData;var sd=function(e){var t=this;e=X({},e);var n=e.container;n&&!M(n)&&M(n[0])&&(n=n[0]);var r=n?n._cyreg:null;r||={},r&&r.cy&&(r.cy.destroy(),r={});var i=r.readies=r.readies||[];n&&(n._cyreg=r),r.cy=t;var a=v!==void 0&&n!==void 0&&!e.headless,o=e;o.layout=X({name:a?`grid`:`null`},o.layout),o.renderer=X({name:a?`canvas`:`null`},o.renderer);var s=function(e,t,n){return t===void 0?n===void 0?e:n:t},c=this._private={container:n,ready:!1,options:o,elements:new xu(this),listeners:[],aniEles:new xu(this),data:o.data||{},scratch:{},layout:null,renderer:null,destroyed:!1,notificationsEnabled:!0,minZoom:1e-50,maxZoom:1e50,zoomingEnabled:s(!0,o.zoomingEnabled),userZoomingEnabled:s(!0,o.userZoomingEnabled),panningEnabled:s(!0,o.panningEnabled),userPanningEnabled:s(!0,o.userPanningEnabled),boxSelectionEnabled:s(!0,o.boxSelectionEnabled),autolock:s(!1,o.autolock,o.autolockNodes),autoungrabify:s(!1,o.autoungrabify,o.autoungrabifyNodes),autounselectify:s(!1,o.autounselectify),styleEnabled:o.styleEnabled===void 0?a:o.styleEnabled,zoom:A(o.zoom)?o.zoom:1,pan:{x:O(o.pan)&&A(o.pan.x)?o.pan.x:0,y:O(o.pan)&&A(o.pan.y)?o.pan.y:0},animation:{current:[],queue:[]},hasCompoundNodes:!1,multiClickDebounceTime:s(250,o.multiClickDebounceTime)};this.createEmitter(),this.selectionType(o.selectionType),this.zoomRange({min:o.minZoom,max:o.maxZoom});var l=function(e,t){if(e.some(H))return ma.all(e).then(t);t(e)};c.styleEnabled&&t.setStyle([]);var u=X({},o,o.renderer);t.initRenderer(u);var d=function(e,n,r){t.notifications(!1);var i=t.mutableElements();i.length>0&&i.remove(),e!=null&&(O(e)||D(e))&&t.add(e),t.one(`layoutready`,function(e){t.notifications(!0),t.emit(e),t.one(`load`,n),t.emitAndNotify(`load`)}).one(`layoutstop`,function(){t.one(`done`,r),t.emit(`done`)});var a=X({},t._private.options.layout);a.eles=t.elements(),t.layout(a).run()};l([o.style,o.elements],function(e){var n=e[0],a=e[1];c.styleEnabled&&t.style().append(n),d(a,function(){t.startAnimationLoop(),c.ready=!0,E(o.ready)&&t.on(`ready`,o.ready);for(var e=0;e0,s=!!e.boundingBox,c=Jn(s?e.boundingBox:structuredClone(t.extent())),l;if(N(e.roots))l=e.roots;else if(D(e.roots)){for(var u=[],d=0;d0;){var M=j(),P=E(M,k);if(P)M.outgoers().filter(function(e){return e.isNode()&&n.has(e)}).forEach(A);else if(P===null){zt("Detected double maximal shift for node `"+M.id()+"`. Bailing maximal adjustment due to cycle. Use `options.maximal: true` only on DAGs.");break}}}var F=0;if(e.avoidOverlap)for(var I=0;I0&&_[0].length<=3?a/2:0),l=2*Math.PI/_[r].length*i;return r===0&&_[0].length===1&&(o=1),{x:ee.x+o*Math.cos(l),y:ee.y+o*Math.sin(l)}}var u=_[r].length,d=Math.max(u===1?0:s?(c.w-e.padding*2-Y.w)/((e.grid?ne:u)-1):(c.w-e.padding*2-Y.w)/((e.grid?ne:u)+1),F);return{x:ee.x+(i+1-(u+1)/2)*d,y:ee.y+(r+1-(U+1)/2)*te}},ie={downward:0,leftward:90,upward:180,rightward:-90};return Object.keys(ie).indexOf(e.direction)===-1&&Lt(`Invalid direction '${e.direction}' specified for breadthfirst layout. Valid values are: ${Object.keys(ie).join(`, `)}`),n.nodes().layoutPositions(this,e,function(t){return Ot(re(t),c,ie[e.direction])}),this};var md={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,radius:void 0,startAngle:3/2*Math.PI,sweep:void 0,clockwise:!0,sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function hd(e){this.options=X({},md,e)}hd.prototype.run=function(){var e=this.options,t=e,n=e.cy,r=t.eles,i=t.counterclockwise===void 0?t.clockwise:!t.counterclockwise,a=r.nodes().not(`:parent`);t.sort&&(a=a.sort(t.sort));for(var o=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()}),s={x:o.x1+o.w/2,y:o.y1+o.h/2},c=(t.sweep===void 0?2*Math.PI-2*Math.PI/a.length:t.sweep)/Math.max(1,a.length-1),l,u=0,d=0;d1&&t.avoidOverlap){u*=1.75;var h=Math.cos(c)-Math.cos(0),g=Math.sin(c)-Math.sin(0),_=Math.sqrt(u*u/(h*h+g*g));l=Math.max(_,l)}return r.nodes().layoutPositions(this,t,function(e,n){var r=t.startAngle+n*c*(i?1:-1),a=l*Math.cos(r),o=l*Math.sin(r);return{x:s.x+a,y:s.y+o}}),this};var gd={fit:!0,padding:30,startAngle:3/2*Math.PI,sweep:void 0,clockwise:!0,equidistant:!1,minNodeSpacing:10,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,height:void 0,width:void 0,spacingFactor:void 0,concentric:function(e){return e.degree()},levelWidth:function(e){return e.maxDegree()/4},animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function _d(e){this.options=X({},gd,e)}_d.prototype.run=function(){for(var e=this.options,t=e,n=t.counterclockwise===void 0?t.clockwise:!t.counterclockwise,r=e.cy,i=t.eles,a=i.nodes().not(`:parent`),o=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:r.width(),h:r.height()}),s={x:o.x1+o.w/2,y:o.y1+o.h/2},c=[],l=0,u=0;u0&&Math.abs(_[0].value-y.value)>=h&&(_=[],g.push(_)),_.push(y)}var b=l+t.minNodeSpacing;if(!t.avoidOverlap){var x=g.length>0&&g[0].length>1,S=(Math.min(o.w,o.h)/2-b)/(g.length+x?1:0);b=Math.min(b,S)}for(var C=0,w=0;w1&&t.avoidOverlap){var D=Math.cos(E)-Math.cos(0),O=Math.sin(E)-Math.sin(0),k=Math.sqrt(b*b/(D*D+O*O));C=Math.max(k,C)}T.r=C,C+=b}if(t.equidistant){for(var A=0,j=0,M=0;M=e.numIter||(Od(r,e),r.temperature*=e.coolingFactor,r.temperature=e.animationThreshold&&a(),dt(u)):(Bd(r,e),s())};u()}else{for(;l;)l=o(c),c++;Bd(r,e),s()}return this},bd.prototype.stop=function(){return this.stopped=!0,this.thread&&this.thread.stop(),this.emit(`layoutstop`),this},bd.prototype.destroy=function(){return this.thread&&this.thread.stop(),this};var xd=function(e,t,n){for(var r=n.eles.edges(),i=n.eles.nodes(),a=Jn(n.boundingBox?n.boundingBox:{x1:0,y1:0,w:e.width(),h:e.height()}),o={isCompound:e.hasCompoundNodes(),layoutNodes:[],idToIndex:{},nodeSize:i.size(),graphSet:[],indexToGraph:[],layoutEdges:[],edgeSize:r.size(),temperature:n.initialTemp,clientWidth:a.w,clientHeight:a.h,boundingBox:a},s=n.eles.components(),c={},l=0;l0){o.graphSet.push(C);for(var l=0;lr.count?0:r.graph},Cd=function(e,t,n,r){var i=r.graphSet[n];if(-10)var c=r.nodeOverlap*s,l=Math.sqrt(i*i+a*a),u=c*i/l,d=c*a/l;else var f=Nd(e,i,a),p=Nd(t,-1*i,-1*a),m=p.x-f.x,h=p.y-f.y,g=m*m+h*h,l=Math.sqrt(g),c=(e.nodeRepulsion+t.nodeRepulsion)/g,u=c*m/l,d=c*h/l;e.isLocked||(e.offsetX-=u,e.offsetY-=d),t.isLocked||(t.offsetX+=u,t.offsetY+=d)}},Md=function(e,t,n,r){if(n>0)var i=e.maxX-t.minX;else var i=t.maxX-e.minX;if(r>0)var a=e.maxY-t.minY;else var a=t.maxY-e.minY;return i>=0&&a>=0?Math.sqrt(i*i+a*a):0},Nd=function(e,t,n){var r=e.positionX,i=e.positionY,a=e.height||1,o=e.width||1,s=n/t,c=a/o,l={};return t===0&&0n?(l.x=r,l.y=i+a/2,l):0t&&-1*c<=s&&s<=c?(l.x=r-o/2,l.y=i-o*n/2/t,l):0=c)?(l.x=r+a*t/2/n,l.y=i+a/2,l):0>n&&(s<=-1*c||s>=c)?(l.x=r-a*t/2/n,l.y=i-a/2,l):l},Pd=function(e,t){for(var n=0;nn){var h=t.gravity*f/m,g=t.gravity*p/m;d.offsetX+=h,d.offsetY+=g}}}}},Id=function(e,t){var n=[],r=0,i=-1;for(n.push.apply(n,e.graphSet[0]),i+=e.graphSet[0].length;r<=i;){var a=n[r++],o=e.idToIndex[a],s=e.layoutNodes[o],c=s.children;if(0n)var i={x:n*e/r,y:n*t/r};else var i={x:e,y:t};return i},zd=function(e,t){var n=e.parentId;if(n!=null){var r=t.layoutNodes[t.idToIndex[n]],i=!1;if((r.maxX==null||e.maxX+r.padRight>r.maxX)&&(r.maxX=e.maxX+r.padRight,i=!0),(r.minX==null||e.minX-r.padLeftr.maxY)&&(r.maxY=e.maxY+r.padBottom,i=!0),(r.minY==null||e.minY-r.padToph&&(f+=m+t.componentSpacing,d=0,p=0,m=0)}}},Vd={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,avoidOverlapPadding:10,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,condense:!1,rows:void 0,cols:void 0,position:function(e){},sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(e,t){return!0},ready:void 0,stop:void 0,transform:function(e,t){return t}};function Hd(e){this.options=X({},Vd,e)}Hd.prototype.run=function(){var e=this.options,t=e,n=e.cy,r=t.eles,i=r.nodes().not(`:parent`);t.sort&&(i=i.sort(t.sort));var a=Jn(t.boundingBox?t.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()});if(a.h===0||a.w===0)r.nodes().layoutPositions(this,t,function(e){return{x:a.x1,y:a.y1}});else{var o=i.size(),s=Math.sqrt(o*a.h/a.w),c=Math.round(s),l=Math.round(a.w/a.h*s),u=function(e){if(e==null)return Math.min(c,l);Math.min(c,l)==c?c=e:l=e},d=function(e){if(e==null)return Math.max(c,l);Math.max(c,l)==c?c=e:l=e},f=t.rows,p=t.cols==null?t.columns:t.cols;if(f!=null&&p!=null)c=f,l=p;else if(f!=null&&p==null)c=f,l=Math.ceil(o/c);else if(f==null&&p!=null)l=p,c=Math.ceil(o/l);else if(l*c>o){var m=u(),h=d();(m-1)*h>=o?u(m-1):(h-1)*m>=o&&d(h-1)}else for(;l*c=o?d(_+1):u(g+1)}var v=a.w/l,y=a.h/c;if(t.condense&&(v=0,y=0),t.avoidOverlap)for(var b=0;b=l&&(j=0,A++)},N={},P=0;P(y=hr(e,t,b[x],b[x+1],b[x+2],b[x+3])))return g(n,y),!0}else if(o.edgeType===`bezier`||o.edgeType===`multibezier`||o.edgeType===`self`||o.edgeType===`compound`){for(var b=o.allpts,x=0;x+5(y=mr(e,t,b[x],b[x+1],b[x+2],b[x+3],b[x+4],b[x+5])))return g(n,y),!0}for(var h=h||r.source,v=v||r.target,S=i.getArrowWidth(c,d),C=[{name:`source`,x:o.arrowStartX,y:o.arrowStartY,angle:o.srcArrowAngle},{name:`target`,x:o.arrowEndX,y:o.arrowEndY,angle:o.tgtArrowAngle},{name:`mid-source`,x:o.midX,y:o.midY,angle:o.midsrcArrowAngle},{name:`mid-target`,x:o.midX,y:o.midY,angle:o.midtgtArrowAngle}],x=0;x0&&(_(h),_(v))}function y(e,t,n){return Xt(e,t,n)}function b(n,r){var i=n._private,a=f,o=r?r+`-`:``;n.boundingBox();var s=i.labelBounds[r||`main`],c=n.pstyle(o+`label`).value;if(!(n.pstyle(`text-events`).strValue!==`yes`||!c)){var l=y(i.rscratch,`labelX`,r),u=y(i.rscratch,`labelY`,r),d=y(i.rscratch,`labelAngle`,r),p=n.pstyle(o+`text-margin-x`).pfValue,m=n.pstyle(o+`text-margin-y`).pfValue,h=s.x1-a-p,_=s.x2+a-p,v=s.y1-a-m,b=s.y2+a-m;if(d){var x=Math.cos(d),S=Math.sin(d),C=function(e,t){return e-=l,t-=u,{x:e*x-t*S+l,y:e*S+t*x+u}},w=C(h,v),T=C(h,b),E=C(_,v),D=C(_,b);if(gr(e,t,[w.x+p,w.y+m,E.x+p,E.y+m,D.x+p,D.y+m,T.x+p,T.y+m]))return g(n),!0}else if(rr(s,e,t))return g(n),!0}}for(var x=o.length-1;x>=0;x--){var S=o[x];S.isNode()?_(S)||b(S):v(S)||b(S)||b(S,`source`)||b(S,`target`)}return s},ef.getAllInBox=function(e,t,n,r){var i=this.getCachedZSortedEles().interactive,a=2/this.cy.zoom(),o=[],s=Math.min(e,n),c=Math.max(e,n),l=Math.min(t,r),u=Math.max(t,r);e=s,n=c,t=l,r=u;var d=Jn({x1:e,y1:t,x2:n,y2:r}),p=[{x:d.x1,y:d.y1},{x:d.x2,y:d.y1},{x:d.x2,y:d.y2},{x:d.x1,y:d.y2}],m=[[p[0],p[1]],[p[1],p[2]],[p[2],p[3]],[p[3],p[0]]];function h(e,t,n){return Xt(e,t,n)}function g(e,t){var n=e._private,r=a,i=``;e.boundingBox();var o=n.labelBounds.main;if(!o)return null;var s=h(n.rscratch,`labelX`,t),c=h(n.rscratch,`labelY`,t),l=h(n.rscratch,`labelAngle`,t),u=e.pstyle(i+`text-margin-x`).pfValue,d=e.pstyle(i+`text-margin-y`).pfValue,f=o.x1-r-u,p=o.x2+r-u,m=o.y1-r-d,g=o.y2+r-d;if(l){var _=Math.cos(l),v=Math.sin(l),y=function(e,t){return e-=s,t-=c,{x:e*_-t*v+s,y:e*v+t*_+c}};return[y(f,m),y(p,m),y(p,g),y(f,g)]}return[{x:f,y:m},{x:p,y:m},{x:p,y:g},{x:f,y:g}]}function _(e,t,n,r){function i(e,t,n){return(n.y-e.y)*(t.x-e.x)>(t.y-e.y)*(n.x-e.x)}return i(e,n,r)!==i(t,n,r)&&i(e,t,n)!==i(e,t,r)}for(var v=0;v0?-(Math.PI-e.ang):Math.PI+e.ang},wf=function(e,t,n,r,i){if(e===xf?Cf(of,af):Sf(t,e,af),Sf(t,n,of),sf=af.nx*of.ny-af.ny*of.nx,cf=af.nx*of.nx-af.ny*-of.ny,df=Math.asin(Math.max(-1,Math.min(1,sf))),Math.abs(df)<1e-6){nf=t.x,rf=t.y,pf=hf=0;return}lf=1,uf=!1,cf<0?df<0?df=Math.PI+df:(df=Math.PI-df,lf=-1,uf=!0):df>0&&(lf=-1,uf=!0),hf=t.radius===void 0?r:t.radius,ff=df/2,gf=Math.min(af.len/2,of.len/2),i?(mf=Math.abs(Math.cos(ff)*hf/Math.sin(ff)),mf>gf?(mf=gf,pf=Math.abs(mf*Math.sin(ff)/Math.cos(ff))):pf=hf):(mf=Math.min(gf,hf),pf=Math.abs(mf*Math.sin(ff)/Math.cos(ff))),yf=t.x+of.nx*mf,bf=t.y+of.ny*mf,nf=yf-of.ny*pf*lf,rf=bf+of.nx*pf*lf,_f=t.x+af.nx*mf,vf=t.y+af.ny*mf,xf=t};function Tf(e,t){t.radius===0?e.lineTo(t.cx,t.cy):e.arc(t.cx,t.cy,t.radius,t.startAngle,t.endAngle,t.counterClockwise)}function Ef(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0;return r===0||t.radius===0?{cx:t.x,cy:t.y,radius:0,startX:t.x,startY:t.y,stopX:t.x,stopY:t.y,startAngle:void 0,endAngle:void 0,counterClockwise:void 0}:(wf(e,t,n,r,i),{cx:nf,cy:rf,radius:pf,startX:_f,startY:vf,stopX:yf,stopY:bf,startAngle:af.ang+Math.PI/2*lf,endAngle:of.ang-Math.PI/2*lf,counterClockwise:uf})}var Df=.01,Of=Math.sqrt(2*Df),kf={};kf.findMidptPtsEtc=function(e,t){var n=t.posPts,r=t.intersectionPts,i=t.vectorNormInverse,a,o=e.pstyle(`source-endpoint`),s=e.pstyle(`target-endpoint`),c=o.units!=null&&s.units!=null,l=function(e,t,n,r){var i=r-t,a=n-e,o=Math.sqrt(a*a+i*i);return{x:-i/o,y:a/o}};switch(e.pstyle(`edge-distances`).value){case`node-position`:a=n;break;case`intersection`:a=r;break;case`endpoints`:if(c){var u=f(this.manualEndptToPx(e.source()[0],o),2),d=u[0],p=u[1],m=f(this.manualEndptToPx(e.target()[0],s),2),h=m[0],g=m[1],_={x1:d,y1:p,x2:h,y2:g};i=l(d,p,h,g),a=_}else zt(`Edge ${e.id()} has edge-distances:endpoints specified without manual endpoints specified via source-endpoint and target-endpoint. Falling back on edge-distances:intersection (default).`),a=r}return{midptPts:a,vectorNormInverse:i}},kf.findHaystackPoints=function(e){for(var t=0;t0?Math.max(e-t,0):Math.min(e+t,0)},O=D(T,C),k=D(E,w),A=!1;_===l?g=Math.abs(O)>Math.abs(k)?i:r:_===c||_===s?(g=r,A=!0):(_===a||_===o)&&(g=i,A=!0);var j=g===r,M=j?k:O,N=j?E:T,P=Bn(N),F=!1;!(A&&(y||x))&&(_===s&&N<0||_===c&&N>0||_===a&&N>0||_===o&&N<0)&&(P*=-1,M=P*Math.abs(M),F=!0);var I=y?(b<0?1+b:b)*M:(b<0?M:0)+b*P,L=function(e){return Math.abs(e)=Math.abs(M)},R=L(I),z=L(Math.abs(M)-Math.abs(I));if((R||z)&&!F){if(j){var B=Math.abs(N)<=f/2,V=Math.abs(T)<=p/2;if(B){var H=(u.x1+u.x2)/2;n.segpts=[H,u.y1,H,u.y2]}else if(V){var U=(u.y1+u.y2)/2;n.segpts=[u.x1,U,u.x2,U]}else n.segpts=[u.x1,u.y2]}else{var W=Math.abs(N)<=d/2,G=Math.abs(E)<=m/2;if(W){var K=(u.y1+u.y2)/2;n.segpts=[u.x1,K,u.x2,K]}else if(G){var q=(u.x1+u.x2)/2;n.segpts=[q,u.y1,q,u.y2]}else n.segpts=[u.x2,u.y1]}}else if(j){var J=u.y1+I+(h?f/2*P:0);n.segpts=[u.x1,J,u.x2,J]}else{var ee=u.x1+I+(h?d/2*P:0);n.segpts=[ee,u.y1,ee,u.y2]}if(n.isRound){var Y=e.pstyle(`taxi-radius`).value,te=e.pstyle(`radius-type`).value[0]===`arc-radius`;n.radii=Array(n.segpts.length/2).fill(Y),n.isArcRadius=Array(n.segpts.length/2).fill(te)}},kf.tryToCorrectInvalidPoints=function(e,t){var n=e._private.rscratch;if(n.edgeType===`bezier`){var r=t.srcPos,i=t.tgtPos,a=t.srcW,o=t.srcH,s=t.tgtW,c=t.tgtH,l=t.srcShape,u=t.tgtShape,d=t.srcCornerRadius,f=t.tgtCornerRadius,p=t.srcRs,m=t.tgtRs,h=!A(n.startX)||!A(n.startY),g=!A(n.arrowStartX)||!A(n.arrowStartY),_=!A(n.endX)||!A(n.endY),v=!A(n.arrowEndX)||!A(n.arrowEndY),y=3*(this.getArrowWidth(e.pstyle(`width`).pfValue,e.pstyle(`arrow-scale`).value)*this.arrowShapeWidth),b=Vn({x:n.ctrlpts[0],y:n.ctrlpts[1]},{x:n.startX,y:n.startY}),x=bh.poolIndex()){var g=m;m=h,h=g}var _=u.srcPos=m.position(),v=u.tgtPos=h.position(),y=u.srcW=m.outerWidth(),b=u.srcH=m.outerHeight(),S=u.tgtW=h.outerWidth(),C=u.tgtH=h.outerHeight(),w=u.srcShape=n.nodeShapes[t.getNodeShape(m)],T=u.tgtShape=n.nodeShapes[t.getNodeShape(h)],E=u.srcCornerRadius=m.pstyle(`corner-radius`).value===`auto`?`auto`:m.pstyle(`corner-radius`).pfValue,D=u.tgtCornerRadius=h.pstyle(`corner-radius`).value===`auto`?`auto`:h.pstyle(`corner-radius`).pfValue,O=u.tgtRs=h._private.rscratch,k=u.srcRs=m._private.rscratch;u.dirCounts={north:0,west:0,south:0,east:0,northwest:0,southwest:0,northeast:0,southeast:0};for(var j=0;j=Of||(G=Math.sqrt(Math.max(W*W,Df)+Math.max(U*U,Df)));var K=u.vector={x:W,y:U},q=u.vectorNorm={x:K.x/G,y:K.y/G},J={x:-q.y,y:q.x};u.nodesOverlap=!A(G)||T.checkPoint(L[0],L[1],0,S,C,v.x,v.y,D,O)||w.checkPoint(z[0],z[1],0,y,b,_.x,_.y,E,k),u.vectorNormInverse=J,d={nodesOverlap:u.nodesOverlap,dirCounts:u.dirCounts,calculatedIntersection:!0,hasBezier:u.hasBezier,hasUnbundled:u.hasUnbundled,eles:u.eles,srcPos:v,srcRs:O,tgtPos:_,tgtRs:k,srcW:S,srcH:C,tgtW:y,tgtH:b,srcIntn:B,tgtIntn:R,srcShape:T,tgtShape:w,posPts:{x1:H.x2,y1:H.y2,x2:H.x1,y2:H.y1},intersectionPts:{x1:V.x2,y1:V.y2,x2:V.x1,y2:V.y1},vector:{x:-K.x,y:-K.y},vectorNorm:{x:-q.x,y:-q.y},vectorNormInverse:{x:-J.x,y:-J.y}}}var Y=I?d:u;N.nodesOverlap=Y.nodesOverlap,N.srcIntn=Y.srcIntn,N.tgtIntn=Y.tgtIntn,N.isRound=P.startsWith(`round`),r&&(m.isParent()||m.isChild()||h.isParent()||h.isChild())&&(m.parents().anySame(h)||h.parents().anySame(m)||m.same(h)&&m.isParent())?t.findCompoundLoopPoints(M,Y,j,F):m===h?t.findLoopPoints(M,Y,j,F):P.endsWith(`segments`)?t.findSegmentsPoints(M,Y):P.endsWith(`taxi`)?t.findTaxiPoints(M,Y):P===`straight`||!F&&u.eles.length%2==1&&j===Math.floor(u.eles.length/2)?t.findStraightEdgePoints(M):t.findBezierPoints(M,Y,j,F,I),t.findEndpoints(M),t.tryToCorrectInvalidPoints(M,Y),t.checkForInvalidEdgeWarning(M),t.storeAllpts(M),t.storeEdgeProjections(M),t.calculateArrowAngles(M),t.recalculateEdgeLabelProjections(M),t.calculateLabelAngles(M)}},x=0;x0){var ne=s,re=Hn(ne,An(i)),ie=Hn(ne,An(te)),ae=re;ie2&&Hn(ne,{x:te[2],y:te[3]})0){var _e=c,ve=Hn(_e,An(i)),ye=Hn(_e,An(ge)),be=ve;ye2&&Hn(_e,{x:ge[2],y:ge[3]})=l||v){d={cp:h,segment:_};break}}if(d)break}var y=d.cp,b=d.segment,x=(l-f)/b.length,S=b.t1-b.t0,C=c?b.t0+S*x:b.t1-S*x;C=qn(0,C,1),t=Gn(y.p0,y.p1,y.p2,C),i=Lf(y.p0,y.p1,y.p2,C);break;case`straight`:case`segments`:case`haystack`:for(var w=0,T,E,D,O,k=r.allpts.length,A=0;A+3=l));A+=2);var j=(l-E)/T;j=qn(0,j,1),t=Kn(D,O,j),i=If(D,O)}o(`labelX`,n,t.x),o(`labelY`,n,t.y),o(`labelAutoAngle`,n,i)}};c(`source`),c(`target`),this.applyLabelDimensions(e)}},Pf.applyLabelDimensions=function(e){this.applyPrefixedLabelDimensions(e),e.isEdge()&&(this.applyPrefixedLabelDimensions(e,`source`),this.applyPrefixedLabelDimensions(e,`target`))},Pf.applyPrefixedLabelDimensions=function(e,t){var n=e._private,r=this.getLabelText(e,t),i=Ct(r,e._private.labelDimsKey);if(Xt(n.rscratch,`prefixedLabelDimsKey`,t)!==i){Zt(n.rscratch,`prefixedLabelDimsKey`,t,i);var a=this.calculateLabelDimensions(e,r),o=e.pstyle(`line-height`).pfValue,s=e.pstyle(`font-size`).pfValue,c=e.pstyle(`text-wrap`).strValue,l=Xt(n.rscratch,`labelWrapCachedLines`,t)||[],u=c===`wrap`?Math.max(l.length,1):1,d=s*o,f=a.width,p=a.height+(u-1)*(o-1)*s;Zt(n.rstyle,`labelWidth`,t,f),Zt(n.rscratch,`labelWidth`,t,f),Zt(n.rstyle,`labelHeight`,t,p),Zt(n.rscratch,`labelHeight`,t,p),Zt(n.rscratch,`labelLineHeight`,t,d),Zt(n.rscratch,`labelActualDescent`,t,a.labelActualDescent)}},Pf.getLabelText=function(e,t){var n=e._private,r=t?t+`-`:``,i=e.pstyle(r+`label`).strValue,a=e.pstyle(`text-transform`).value,s=function(e,r){return r?(Zt(n.rscratch,e,t,r),r):Xt(n.rscratch,e,t)};if(!i)return``;a==`none`||(a==`uppercase`?i=i.toUpperCase():a==`lowercase`&&(i=i.toLowerCase()));var c=e.pstyle(`text-wrap`).value;if(c===`wrap`){var l=s(`labelKey`);if(l!=null&&s(`labelWrapKey`)===l)return s(`labelWrapCachedText`);for(var u=`​`,d=i.split(` +`),f=e.pstyle(`text-max-width`).pfValue,p=e.pstyle(`text-overflow-wrap`).value===`anywhere`,m=[],h=/[\s\u200b]+|$/g,g=0;gf){var y=_.matchAll(h),b=``,x=0,S=o(y),C;try{for(S.s();!(C=S.n()).done;){var w=C.value,T=w[0],E=_.substring(x,w.index);x=w.index+T.length;var D=b.length===0?E:b+E+T;this.calculateLabelDimensions(e,D).width<=f?b+=E+T:(b&&m.push(b),b=E+T)}}catch(e){S.e(e)}finally{S.f()}b.match(/^[\s\u200b]+$/)||m.push(b)}else m.push(_)}s(`labelWrapCachedLines`,m),i=s(`labelWrapCachedText`,m.join(` +`)),s(`labelWrapKey`,l)}else if(c===`ellipsis`){var O=e.pstyle(`text-max-width`).pfValue,k=``,A=`…`,j=!1;if(this.calculateLabelDimensions(e,i).widthO);M++)k+=i[M],M===i.length-1&&(j=!0);return j||(k+=A),k}return i},Pf.getLabelJustification=function(e){var t=e.pstyle(`text-justification`).strValue,n=e.pstyle(`text-halign`).strValue;return t===`auto`?e.isNode()?al(n):`center`:t},Pf.calculateLabelDimensions=function(e,t){var n=this.cy.window().document,r=0,i=e.pstyle(`font-style`).strValue,a=e.pstyle(`font-size`).pfValue,o=e.pstyle(`font-family`).strValue,s=e.pstyle(`font-weight`).strValue,c=e.pstyle(`text-metrics`).strValue||`font`,l=this.labelCalcCanvas,u=this.labelCalcCanvasContext;if(!l){l=this.labelCalcCanvas=n.createElement(`canvas`),u=this.labelCalcCanvasContext=l.getContext(`2d`);var d=l.style;d.position=`absolute`,d.left=`-9999px`,d.top=`-9999px`,d.zIndex=`-1`,d.visibility=`hidden`,d.pointerEvents=`none`}u.font=`${i} ${s} ${a}px ${o}`;for(var f=0,p=0,m=t.split(` +`),h=m.length,g=0,_=0,v=0;v1&&arguments[1]!==void 0?arguments[1]:!0;if(t.merge(e),n)for(var r=0;r=e.desktopTapThreshold2}var E=a(t);b&&(e.hoverData.tapholdCancelled=!0);var D=function(){var t=e.hoverData.dragDelta=e.hoverData.dragDelta||[];t.length===0?(t.push(v[0]),t.push(v[1])):(t[0]+=v[0],t[1]+=v[1])};n=!0,i(m,[`mousemove`,`vmousemove`,`tapdrag`],t,{x:l[0],y:l[1]});var O=function(e){return{originalEvent:t,type:e,position:{x:l[0],y:l[1]}}},k=function(){e.data.bgActivePosistion=void 0,e.hoverData.selecting||r.emit(O(`boxstart`)),f[4]=1,e.hoverData.selecting=!0,e.redrawHint(`select`,!0),e.redraw()};if(e.hoverData.which===3){if(b){var j=O(`cxtdrag`);_?_.emit(j):r.emit(j),e.hoverData.cxtDragged=!0,(!e.hoverData.cxtOver||m!==e.hoverData.cxtOver)&&(e.hoverData.cxtOver&&e.hoverData.cxtOver.emit(O(`cxtdragout`)),e.hoverData.cxtOver=m,m&&m.emit(O(`cxtdragover`)))}}else if(e.hoverData.dragging){if(n=!0,r.panningEnabled()&&r.userPanningEnabled()){var M;if(e.hoverData.justStartedPan){var N=e.hoverData.mdownPos;M={x:(l[0]-N[0])*s,y:(l[1]-N[1])*s},e.hoverData.justStartedPan=!1}else M={x:v[0]*s,y:v[1]*s};r.panBy(M),r.emit(O(`dragpan`)),e.hoverData.dragged=!0}l=e.projectIntoViewport(t.clientX,t.clientY)}else if(f[4]==1&&(_==null||_.pannable()))b&&(!e.hoverData.dragging&&r.boxSelectionEnabled()&&(E||!r.panningEnabled()||!r.userPanningEnabled())?k():!e.hoverData.selecting&&r.panningEnabled()&&r.userPanningEnabled()&&o(_,e.hoverData.downs)&&(e.hoverData.dragging=!0,e.hoverData.justStartedPan=!0,f[4]=0,e.data.bgActivePosistion=An(u),e.redrawHint(`select`,!0),e.redraw()),_&&_.pannable()&&_.active()&&_.unactivate());else{if(_&&_.pannable()&&_.active()&&_.unactivate(),(!_||!_.grabbed())&&m!=g&&(g&&i(g,[`mouseout`,`tapdragout`],t,{x:l[0],y:l[1]}),m&&i(m,[`mouseover`,`tapdragover`],t,{x:l[0],y:l[1]}),e.hoverData.last=m),_){if(b){if(r.boxSelectionEnabled()&&E)_&&_.grabbed()&&(h(y),_.emit(O(`freeon`)),y.emit(O(`free`)),e.dragData.didDrag&&(_.emit(O(`dragfreeon`)),y.emit(O(`dragfree`)))),k();else if(_&&_.grabbed()&&e.nodeIsDraggable(_)){var P=!e.dragData.didDrag;P&&e.redrawHint(`eles`,!0),e.dragData.didDrag=!0,e.hoverData.draggingEles||p(y,{inDragLayer:!0});var F={x:0,y:0};if(A(v[0])&&A(v[1])&&(F.x+=v[0],F.y+=v[1],P)){var I=e.hoverData.dragDelta;I&&A(I[0])&&A(I[1])&&(F.x+=I[0],F.y+=I[1])}e.hoverData.draggingEles=!0,y.silentShift(F).emit(O(`position`)).emit(O(`drag`)),e.redrawHint(`drag`,!0),e.redraw()}}else D()}n=!0}if(f[2]=l[0],f[3]=l[1],n)return t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),!1}},!1);var E,D,O;e.registerBinding(t,`mouseup`,function(t){if(!(e.hoverData.which===1&&t.which!==1&&e.hoverData.capture)&&e.hoverData.capture){e.hoverData.capture=!1;var r=e.cy,o=e.projectIntoViewport(t.clientX,t.clientY),s=e.selection,c=e.findNearestElement(o[0],o[1],!0,!1),l=e.dragData.possibleDragElements,u=e.hoverData.down,d=a(t);e.data.bgActivePosistion&&(e.redrawHint(`select`,!0),e.redraw()),e.hoverData.tapholdCancelled=!0,e.data.bgActivePosistion=void 0,u&&u.unactivate();var f=function(e){return{originalEvent:t,type:e,position:{x:o[0],y:o[1]}}};if(e.hoverData.which===3){var p=f(`cxttapend`);if(u?u.emit(p):r.emit(p),!e.hoverData.cxtDragged){var m=f(`cxttap`);u?u.emit(m):r.emit(m)}e.hoverData.cxtDragged=!1,e.hoverData.which=null}else if(e.hoverData.which===1){if(i(c,[`mouseup`,`tapend`,`vmouseup`],t,{x:o[0],y:o[1]}),!e.dragData.didDrag&&!e.hoverData.dragged&&!e.hoverData.selecting&&!e.hoverData.isOverThresholdDrag&&(i(u,[`click`,`tap`,`vclick`],t,{x:o[0],y:o[1]}),D=!1,t.timeStamp-O<=r.multiClickDebounceTime()?(E&&clearTimeout(E),D=!0,O=null,i(u,[`dblclick`,`dbltap`,`vdblclick`],t,{x:o[0],y:o[1]})):(E=setTimeout(function(){D||i(u,[`oneclick`,`onetap`,`voneclick`],t,{x:o[0],y:o[1]})},r.multiClickDebounceTime()),O=t.timeStamp)),u==null&&!e.dragData.didDrag&&!e.hoverData.selecting&&!e.hoverData.dragged&&!a(t)&&(r.$(n).unselect([`tapunselect`]),l.length>0&&e.redrawHint(`eles`,!0),e.dragData.possibleDragElements=l=r.collection()),c==u&&!e.dragData.didDrag&&!e.hoverData.selecting&&c!=null&&c._private.selectable&&(e.hoverData.dragging||(r.selectionType()===`additive`||d?c.selected()?c.unselect([`tapunselect`]):c.select([`tapselect`]):d||(r.$(n).unmerge(c).unselect([`tapunselect`]),c.select([`tapselect`]))),e.redrawHint(`eles`,!0)),e.hoverData.selecting){var g=r.collection(e.getAllInBox(s[0],s[1],s[2],s[3]));e.redrawHint(`select`,!0),g.length>0&&e.redrawHint(`eles`,!0),r.emit(f(`boxend`)),r.selectionType()===`additive`||d||r.$(n).unmerge(g).unselect(),g.emit(f(`box`)).stdFilter(function(e){return e.selectable()&&!e.selected()}).select().emit(f(`boxselect`)),e.redraw()}if(e.hoverData.dragging&&(e.hoverData.dragging=!1,e.redrawHint(`select`,!0),e.redrawHint(`eles`,!0),e.redraw()),!s[4]){e.redrawHint(`drag`,!0),e.redrawHint(`eles`,!0);var _=u&&u.grabbed();h(l),_&&(u.emit(f(`freeon`)),l.emit(f(`free`)),e.dragData.didDrag&&(u.emit(f(`dragfreeon`)),l.emit(f(`dragfree`))))}}s[4]=0,e.hoverData.down=null,e.hoverData.cxtStarted=!1,e.hoverData.draggingEles=!1,e.hoverData.selecting=!1,e.hoverData.isOverThresholdDrag=!1,e.dragData.didDrag=!1,e.hoverData.dragged=!1,e.hoverData.dragDelta=[],e.hoverData.mdownPos=null,e.hoverData.mdownGPos=null,e.hoverData.which=null}},!1);var k=[],j=4,M,N=1e5,P=function(e){for(var t=Math.abs(e[0]),n=1;n=j){M=!1;var i=k;if(i[0]>=5){var a=P(i)?i[0]:In(i);a>1&&(M=!0,N=a)}}else k.push(Math.abs(r)),n=!0}else M&&(N=Math.min(Math.abs(r),N));if(!e.scrollingPage){var o=e.cy,s=o.zoom(),c=o.pan(),l=e.projectIntoViewport(t.clientX,t.clientY),u=[l[0]*s+c.x,l[1]*s+c.y];if(e.hoverData.draggingEles||e.hoverData.dragging||e.hoverData.cxtStarted||C()){t.preventDefault();return}if(o.panningEnabled()&&o.userPanningEnabled()&&o.zoomingEnabled()&&o.userZoomingEnabled()){t.preventDefault(),e.data.wheelZooming=!0,clearTimeout(e.data.wheelTimeout),e.data.wheelTimeout=setTimeout(function(){e.data.wheelZooming=!1,e.redrawHint(`eles`,!0),e.redraw()},150);var d;n&&Math.abs(r)>5&&(r=Bn(r)*5),d=r/-250,M&&(d/=N,d*=3),d*=e.wheelSensitivity,t.deltaMode===1&&(d*=33);var f=o.zoom()*10**d;t.type===`gesturechange`&&(f=e.gestureStartZoom*t.scale),o.zoom({level:f,renderedPosition:{x:u[0],y:u[1]}}),o.emit({type:t.type===`gesturechange`?`pinchzoom`:`scrollzoom`,originalEvent:t,position:{x:l[0],y:l[1]}})}}}};e.registerBinding(e.container,`wheel`,F,!0),e.registerBinding(t,`scroll`,function(t){e.scrollingPage=!0,clearTimeout(e.scrollingPageTimeout),e.scrollingPageTimeout=setTimeout(function(){e.scrollingPage=!1},250)},!0),e.registerBinding(e.container,`gesturestart`,function(t){e.gestureStartZoom=e.cy.zoom(),e.hasTouchStarted||t.preventDefault()},!0),e.registerBinding(e.container,`gesturechange`,function(t){e.hasTouchStarted||F(t)},!0),e.registerBinding(e.container,`mouseout`,function(t){var n=e.projectIntoViewport(t.clientX,t.clientY);e.cy.emit({originalEvent:t,type:`mouseout`,position:{x:n[0],y:n[1]}})},!1),e.registerBinding(e.container,`mouseover`,function(t){var n=e.projectIntoViewport(t.clientX,t.clientY);e.cy.emit({originalEvent:t,type:`mouseover`,position:{x:n[0],y:n[1]}})},!1);var I,L,R,z,B,V,H,U,W,G,K,q,J,ee=function(e,t,n,r){return Math.sqrt((n-e)*(n-e)+(r-t)*(r-t))},Y=function(e,t,n,r){return(n-e)*(n-e)+(r-t)*(r-t)},te;e.registerBinding(e.container,`touchstart`,te=function(t){if(e.hasTouchStarted=!0,w(t)){_(),e.touchData.capture=!0,e.data.bgActivePosistion=void 0;var n=e.cy,r=e.touchData.now,a=e.touchData.earlier;if(t.touches[0]){var o=e.projectIntoViewport(t.touches[0].clientX,t.touches[0].clientY);r[0]=o[0],r[1]=o[1]}if(t.touches[1]){var o=e.projectIntoViewport(t.touches[1].clientX,t.touches[1].clientY);r[2]=o[0],r[3]=o[1]}if(t.touches[2]){var o=e.projectIntoViewport(t.touches[2].clientX,t.touches[2].clientY);r[4]=o[0],r[5]=o[1]}var s=function(e){return{originalEvent:t,type:e,position:{x:r[0],y:r[1]}}};if(t.touches[1]){e.touchData.singleTouchMoved=!0,h(e.dragData.touchDragEles);var c=e.findContainerClientCoords();W=c[0],G=c[1],K=c[2],q=c[3],I=t.touches[0].clientX-W,L=t.touches[0].clientY-G,R=t.touches[1].clientX-W,z=t.touches[1].clientY-G,J=0<=I&&I<=K&&0<=R&&R<=K&&0<=L&&L<=q&&0<=z&&z<=q;var u=n.pan(),d=n.zoom();B=ee(I,L,R,z),V=Y(I,L,R,z),H=[(I+R)/2,(L+z)/2],U=[(H[0]-u.x)/d,(H[1]-u.y)/d];var f=200,g=f*f;if(V=1){for(var T=e.touchData.startPosition=[null,null,null,null,null,null],E=0;E=e.touchTapThreshold2}if(n&&e.touchData.cxt){t.preventDefault();var x=t.touches[0].clientX-W,S=t.touches[0].clientY-G,C=t.touches[1].clientX-W,T=t.touches[1].clientY-G,E=Y(x,S,C,T),D=E/V,O=150,k=O*O,j=1.5;if(D>=j*j||E>=k){e.touchData.cxt=!1,e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var M=d(`cxttapend`);e.touchData.start?(e.touchData.start.unactivate().emit(M),e.touchData.start=null):a.emit(M)}}if(n&&e.touchData.cxt){var M=d(`cxtdrag`);e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0),e.touchData.start?e.touchData.start.emit(M):a.emit(M),e.touchData.start&&(e.touchData.start._private.grabbed=!1),e.touchData.cxtDragged=!0;var N=e.findNearestElement(s[0],s[1],!0,!0);(!e.touchData.cxtOver||N!==e.touchData.cxtOver)&&(e.touchData.cxtOver&&e.touchData.cxtOver.emit(d(`cxtdragout`)),e.touchData.cxtOver=N,N&&N.emit(d(`cxtdragover`)))}else if(n&&t.touches[2]&&a.boxSelectionEnabled())t.preventDefault(),e.data.bgActivePosistion=void 0,this.lastThreeTouch=+new Date,e.touchData.selecting||a.emit(d(`boxstart`)),e.touchData.selecting=!0,e.touchData.didSelect=!0,r[4]=1,!r||r.length===0||r[0]===void 0?(r[0]=(s[0]+s[2]+s[4])/3,r[1]=(s[1]+s[3]+s[5])/3,r[2]=(s[0]+s[2]+s[4])/3+1,r[3]=(s[1]+s[3]+s[5])/3+1):(r[2]=(s[0]+s[2]+s[4])/3,r[3]=(s[1]+s[3]+s[5])/3),e.redrawHint(`select`,!0),e.redraw();else if(n&&t.touches[1]&&!e.touchData.didSelect&&a.zoomingEnabled()&&a.panningEnabled()&&a.userZoomingEnabled()&&a.userPanningEnabled()){t.preventDefault(),e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var P=e.dragData.touchDragEles;if(P){e.redrawHint(`drag`,!0);for(var F=0;F0&&!e.hoverData.draggingEles&&!e.swipePanning&&e.data.bgActivePosistion!=null&&(e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0),e.redraw())}},!1);var re;e.registerBinding(t,`touchcancel`,re=function(t){var n=e.touchData.start;e.touchData.capture=!1,n&&n.unactivate()});var ie,ae,oe,se;if(e.registerBinding(t,`touchend`,ie=function(t){var r=e.touchData.start;if(e.touchData.capture)t.touches.length===0&&(e.touchData.capture=!1),t.preventDefault();else return;var a=e.selection;e.swipePanning=!1,e.hoverData.draggingEles=!1;var o=e.cy,s=o.zoom(),c=e.touchData.now,l=e.touchData.earlier;if(t.touches[0]){var u=e.projectIntoViewport(t.touches[0].clientX,t.touches[0].clientY);c[0]=u[0],c[1]=u[1]}if(t.touches[1]){var u=e.projectIntoViewport(t.touches[1].clientX,t.touches[1].clientY);c[2]=u[0],c[3]=u[1]}if(t.touches[2]){var u=e.projectIntoViewport(t.touches[2].clientX,t.touches[2].clientY);c[4]=u[0],c[5]=u[1]}var d=function(e){return{originalEvent:t,type:e,position:{x:c[0],y:c[1]}}};r&&r.unactivate();var f;if(e.touchData.cxt){if(f=d(`cxttapend`),r?r.emit(f):o.emit(f),!e.touchData.cxtDragged){var p=d(`cxttap`);r?r.emit(p):o.emit(p)}e.touchData.start&&(e.touchData.start._private.grabbed=!1),e.touchData.cxt=!1,e.touchData.start=null,e.redraw();return}if(!t.touches[2]&&o.boxSelectionEnabled()&&e.touchData.selecting){e.touchData.selecting=!1;var m=o.collection(e.getAllInBox(a[0],a[1],a[2],a[3]));a[0]=void 0,a[1]=void 0,a[2]=void 0,a[3]=void 0,a[4]=0,e.redrawHint(`select`,!0),o.emit(d(`boxend`)),m.emit(d(`box`)).stdFilter(function(e){return e.selectable()&&!e.selected()}).select().emit(d(`boxselect`)),m.nonempty()&&e.redrawHint(`eles`,!0),e.redraw()}if(r?.unactivate(),t.touches[2])e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);else if(!t.touches[1]&&!t.touches[0]&&!t.touches[0]){e.data.bgActivePosistion=void 0,e.redrawHint(`select`,!0);var g=e.dragData.touchDragEles;if(r!=null){var _=r._private.grabbed;h(g),e.redrawHint(`drag`,!0),e.redrawHint(`eles`,!0),_&&(r.emit(d(`freeon`)),g.emit(d(`free`)),e.dragData.didDrag&&(r.emit(d(`dragfreeon`)),g.emit(d(`dragfree`)))),i(r,[`touchend`,`tapend`,`vmouseup`,`tapdragout`],t,{x:c[0],y:c[1]}),r.unactivate(),e.touchData.start=null}else i(e.findNearestElement(c[0],c[1],!0,!0),[`touchend`,`tapend`,`vmouseup`,`tapdragout`],t,{x:c[0],y:c[1]});var v=e.touchData.startPosition[0]-c[0],y=v*v,b=e.touchData.startPosition[1]-c[1],x=(y+b*b)*s*s;e.touchData.singleTouchMoved||(r||o.$(`:selected`).unselect([`tapunselect`]),i(r,[`tap`,`vclick`],t,{x:c[0],y:c[1]}),ae=!1,t.timeStamp-se<=o.multiClickDebounceTime()?(oe&&clearTimeout(oe),ae=!0,se=null,i(r,[`dbltap`,`vdblclick`],t,{x:c[0],y:c[1]})):(oe=setTimeout(function(){ae||i(r,[`onetap`,`voneclick`],t,{x:c[0],y:c[1]})},o.multiClickDebounceTime()),se=t.timeStamp)),r!=null&&!e.dragData.didDrag&&r._private.selectable&&x`u`){var ce=[],X=function(e){return{clientX:e.clientX,clientY:e.clientY,force:1,identifier:e.pointerId,pageX:e.pageX,pageY:e.pageY,radiusX:e.width/2,radiusY:e.height/2,screenX:e.screenX,screenY:e.screenY,target:e.target}},le=function(e){return{event:e,touch:X(e)}},ue=function(e){ce.push(le(e))},de=function(e){for(var t=0;t0)return l[0]}return null},p=Object.keys(d),m=0;m0?d:lr(i,a,e,t,n,r,o,s)},checkPoint:function(e,t,n,r,i,a,o,s){s=s===`auto`?Nr(r,i):s;var c=2*s;if(_r(e,t,this.points,a,o,r,i-c,[0,-1],n)||_r(e,t,this.points,a,o,r-c,i,[0,-1],n))return!0;var l=r/2+2*n,u=i/2+2*n;return!!(gr(e,t,[a-l,o-u,a-l,o,a+l,o,a+l,o-u])||Sr(e,t,c,c,a+r/2-s,o+i/2-s,n)||Sr(e,t,c,c,a-r/2+s,o+i/2-s,n))}}},Yf.registerNodeShapes=function(){var e=this.nodeShapes={},t=this;this.generateEllipse(),this.generatePolygon(`triangle`,Ar(3,0)),this.generateRoundPolygon(`round-triangle`,Ar(3,0)),this.generatePolygon(`rectangle`,Ar(4,0)),e.square=e.rectangle,this.generateRoundRectangle(),this.generateCutRectangle(),this.generateBarrel(),this.generateBottomRoundrectangle();var n=[0,1,1,0,0,-1,-1,0];this.generatePolygon(`diamond`,n),this.generateRoundPolygon(`round-diamond`,n),this.generatePolygon(`pentagon`,Ar(5,0)),this.generateRoundPolygon(`round-pentagon`,Ar(5,0)),this.generatePolygon(`hexagon`,Ar(6,0)),this.generateRoundPolygon(`round-hexagon`,Ar(6,0)),this.generatePolygon(`heptagon`,Ar(7,0)),this.generateRoundPolygon(`round-heptagon`,Ar(7,0)),this.generatePolygon(`octagon`,Ar(8,0)),this.generateRoundPolygon(`round-octagon`,Ar(8,0));var r=Array(20),i=Mr(5,0),a=Mr(5,Math.PI/5),o=.5*(3-Math.sqrt(5));o*=1.57;for(var s=0;s=e.deqFastCost*h)break}else if(i){if(p>=e.deqCost*c||p>=e.deqAvgCost*s)break}else if(m>=e.deqNoDrawCost*ep)break;var g=e.deq(t,d,u);if(g.length>0)for(var _=0;_0&&(e.onDeqd(t,l),!i&&e.shouldRedraw(t,l,d,u)&&r())},a=e.priority||It;n.beforeRender(i,a(t))}}}},np=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Pt;r(this,e),this.idsByKey=new Qt,this.keyForId=new Qt,this.cachesByLvl=new Qt,this.lvls=[],this.getKey=t,this.doesEleInvalidateKey=n}return a(e,[{key:`getIdsFor`,value:function(e){e??Lt(`Can not get id list for null key`);var t=this.idsByKey,n=this.idsByKey.get(e);return n||(n=new tn,t.set(e,n)),n}},{key:`addIdForKey`,value:function(e,t){e!=null&&this.getIdsFor(e).add(t)}},{key:`deleteIdForKey`,value:function(e,t){e!=null&&this.getIdsFor(e).delete(t)}},{key:`getNumberOfIdsForKey`,value:function(e){return e==null?0:this.getIdsFor(e).size}},{key:`updateKeyMappingFor`,value:function(e){var t=e.id(),n=this.keyForId.get(t),r=this.getKey(e);this.deleteIdForKey(n,t),this.addIdForKey(r,t),this.keyForId.set(t,r)}},{key:`deleteKeyMappingFor`,value:function(e){var t=e.id(),n=this.keyForId.get(t);this.deleteIdForKey(n,t),this.keyForId.delete(t)}},{key:`keyHasChangedFor`,value:function(e){var t=e.id();return this.keyForId.get(t)!==this.getKey(e)}},{key:`isInvalid`,value:function(e){return this.keyHasChangedFor(e)||this.doesEleInvalidateKey(e)}},{key:`getCachesAt`,value:function(e){var t=this.cachesByLvl,n=this.lvls,r=t.get(e);return r||(r=new Qt,t.set(e,r),n.push(e)),r}},{key:`getCache`,value:function(e,t){return this.getCachesAt(t).get(e)}},{key:`get`,value:function(e,t){var n=this.getKey(e),r=this.getCache(n,t);return r!=null&&this.updateKeyMappingFor(e),r}},{key:`getForCachedKey`,value:function(e,t){var n=this.keyForId.get(e.id());return this.getCache(n,t)}},{key:`hasCache`,value:function(e,t){return this.getCachesAt(t).has(e)}},{key:`has`,value:function(e,t){var n=this.getKey(e);return this.hasCache(n,t)}},{key:`setCache`,value:function(e,t,n){n.key=e,this.getCachesAt(t).set(e,n)}},{key:`set`,value:function(e,t,n){var r=this.getKey(e);this.setCache(r,t,n),this.updateKeyMappingFor(e)}},{key:`deleteCache`,value:function(e,t){this.getCachesAt(t).delete(e)}},{key:`delete`,value:function(e,t){var n=this.getKey(e);this.deleteCache(n,t)}},{key:`invalidateKey`,value:function(e){var t=this;this.lvls.forEach(function(n){return t.deleteCache(e,n)})}},{key:`invalidate`,value:function(e){var t=e.id(),n=this.keyForId.get(t);this.deleteKeyMappingFor(e);var r=this.doesEleInvalidateKey(e);return r&&this.invalidateKey(n),r||this.getNumberOfIdsForKey(n)===0}}])}(),rp=25,ip=50,ap=-4,op=3,sp=7.99,cp=8,lp=1024,up=1024,dp=1024,fp=.2,pp=.8,mp=10,hp=.15,gp=.1,_p=.9,vp=.9,yp=100,bp=1,xp={dequeue:`dequeue`,downscale:`downscale`,highQuality:`highQuality`},Sp=Kt({getKey:null,doesEleInvalidateKey:Pt,drawElement:null,getBoundingBox:null,getRotationPoint:null,getRotationOffset:null,isVisible:Nt,allowEdgeTxrCaching:!0,allowParentTxrCaching:!0}),Cp=function(e,t){var n=this;n.renderer=e,n.onDequeues=[];var r=Sp(t);X(n,r),n.lookup=new np(r.getKey,r.doesEleInvalidateKey),n.setupDequeueing()},wp=Cp.prototype;wp.reasons=xp,wp.getTextureQueue=function(e){var t=this;return t.eleImgCaches=t.eleImgCaches||{},t.eleImgCaches[e]=t.eleImgCaches[e]||[]},wp.getRetiredTextureQueue=function(e){var t=this,n=t.eleImgCaches.retired=t.eleImgCaches.retired||{};return n[e]=n[e]||[]},wp.getElementQueue=function(){var e=this;return e.eleCacheQueue=e.eleCacheQueue||new pn(function(e,t){return t.reqs-e.reqs})},wp.getElementKeyToQueue=function(){var e=this;return e.eleKeyToCacheQueue=e.eleKeyToCacheQueue||{}},wp.getElement=function(e,t,n,r,i){var a=this,o=this.renderer,s=o.cy.zoom(),c=this.lookup;if(!t||t.w===0||t.h===0||isNaN(t.w)||isNaN(t.h)||!e.visible()||e.removed()||!a.allowEdgeTxrCaching&&e.isEdge()||!a.allowParentTxrCaching&&e.isParent())return null;if(r??=Math.ceil(zn(s*n)),r=sp||r>op)return null;var l=2**r,u=t.h*l,d=t.w*l,f=o.eleTextBiggerThanMin(e,l);if(!this.isVisible(e,f))return null;var p=c.get(e,r);if(p&&p.invalidated&&(p.invalidated=!1,p.texture.invalidatedWidth-=p.width),p)return p;var m=u<=rp?rp:u<=ip?ip:Math.ceil(u/ip)*ip;if(u>dp||d>up)return null;var h=a.getTextureQueue(m),g=h[h.length-2],_=function(){return a.recycleTexture(m,d)||a.addTexture(m,d)};g||=h[h.length-1],g||=_(),g.width-g.usedWidthr;D--)T=a.getElement(e,t,n,D,xp.downscale);E()}else return a.queueElement(e,S.level-1),S}else{var O;if(!y&&!b&&!x)for(var k=r-1;k>=ap;k--){var A=c.get(e,k);if(A){O=A;break}}if(v(O))return a.queueElement(e,r),O;g.context.translate(g.usedWidth,0),g.context.scale(l,l),this.drawElement(g.context,e,t,f,!1),g.context.scale(1/l,1/l),g.context.translate(-g.usedWidth,0)}return p={x:g.usedWidth,texture:g,level:r,scale:l,width:d,height:u,scaledLabelShown:f},g.usedWidth+=Math.ceil(d+cp),g.eleCaches.push(p),c.set(e,r,p),a.checkTextureFullness(g),p},wp.invalidateElements=function(e){for(var t=0;t=fp*e.width&&this.retireTexture(e)},wp.checkTextureFullness=function(e){var t=this.getTextureQueue(e.height);e.usedWidth/e.width>pp&&e.fullnessChecks>=mp?qt(t,e):e.fullnessChecks++},wp.retireTexture=function(e){var t=this,n=e.height,r=t.getTextureQueue(n),i=this.lookup;qt(r,e),e.retired=!0;for(var a=e.eleCaches,o=0;o=t)return o.retired=!1,o.usedWidth=0,o.invalidatedWidth=0,o.fullnessChecks=0,Jt(o.eleCaches),o.context.setTransform(1,0,0,1,0,0),o.context.clearRect(0,0,o.width,o.height),qt(i,o),r.push(o),o}},wp.queueElement=function(e,t){var n=this,r=n.getElementQueue(),i=n.getElementKeyToQueue(),a=this.getKey(e),o=i[a];if(o)o.level=Math.max(o.level,t),o.eles.merge(e),o.reqs++,r.updateItem(o);else{var s={eles:e.spawn().merge(e),level:t,reqs:1,key:a};r.push(s),i[a]=s}},wp.dequeue=function(e){for(var t=this,n=t.getElementQueue(),r=t.getElementKeyToQueue(),i=[],a=t.lookup,o=0;o0;o++){var s=n.pop(),c=s.key,l=s.eles[0],u=a.hasCache(l,s.level);if(r[c]=null,!u){i.push(s);var d=t.getBoundingBox(l);t.getElement(l,d,e,s.level,xp.dequeue)}}return i},wp.removeFromQueue=function(e){var t=this,n=t.getElementQueue(),r=t.getElementKeyToQueue(),i=this.getKey(e),a=r[i];a!=null&&(a.eles.length===1?(a.reqs=Mt,n.updateItem(a),n.pop(),r[i]=null):a.eles.unmerge(e))},wp.onDequeue=function(e){this.onDequeues.push(e)},wp.offDequeue=function(e){qt(this.onDequeues,e)},wp.setupDequeueing=tp.setupDequeueing({deqRedrawThreshold:yp,deqCost:hp,deqAvgCost:gp,deqNoDrawCost:_p,deqFastCost:vp,deq:function(e,t,n){return e.dequeue(t,n)},onDeqd:function(e,t){for(var n=0;n=Op||n>Dp)return null}r.validateLayersElesOrdering(n,e);var o=r.layersByLevel,s=2**n,c=o[n]=o[n]||[],l,u=r.levelIsComplete(n,e),d,f=function(){var t=function(t){if(r.validateLayersElesOrdering(t,e),r.levelIsComplete(t,e))return d=o[t],!0},i=function(e){if(!d)for(var r=n+e;Ep<=r&&r<=Dp&&!t(r);r+=e);};i(1),i(-1);for(var a=c.length-1;a>=0;a--){var s=c[a];s.invalid&&qt(c,s)}};if(!u)f();else return c;var p=function(){if(!l){l=Jn();for(var t=0;tRp||a>Rp||i*a>Lp)return null;var o=r.makeLayer(l,n);if(t!=null){var u=c.indexOf(t)+1;c.splice(u,0,o)}else(e.insert===void 0||e.insert)&&c.unshift(o);return o};if(r.skipping&&!a)return null;for(var h=null,g=e.length/Tp,_=!a,v=0;v=g||!ar(h.bb,y.boundingBox()))&&(h=m({insert:!0,after:h}),!h))return null;d||_?r.queueLayer(h,y):r.drawEleInLayer(h,y,n,t),h.eles.push(y),x[n]=h}return d||(_?null:c)},Vp.getEleLevelForLayerLevel=function(e,t){return e},Vp.drawEleInLayer=function(e,t,n,r){var i=this,a=this.renderer,o=e.context,s=t.boundingBox();s.w===0||s.h===0||!t.visible()||(n=i.getEleLevelForLayerLevel(n,r),a.setImgSmoothing(o,!1),a.drawCachedElement(o,t,null,null,n,zp),a.setImgSmoothing(o,!0))},Vp.levelIsComplete=function(e,t){var n=this.layersByLevel[e];if(!n||n.length===0)return!1;for(var r=0,i=0;i0||a.invalid)return!1;r+=a.eles.length}return r===t.length},Vp.validateLayersElesOrdering=function(e,t){var n=this.layersByLevel[e];if(n)for(var r=0;r0){t=!0;break}}return t},Vp.invalidateElements=function(e){var t=this;e.length!==0&&(t.lastInvalidationTime=ft(),!(e.length===0||!t.haveLayers())&&t.updateElementsInLayers(e,function(e,n,r){t.invalidateLayer(e)}))},Vp.invalidateLayer=function(e){if(this.lastInvalidationTime=ft(),!e.invalid){var t=e.level,n=e.eles,r=this.layersByLevel[t];qt(r,e),e.elesQueue=[],e.invalid=!0,e.replacement&&(e.replacement.invalid=!0);for(var i=0;i3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0,o=this,s=t._private.rscratch;if(!(a&&!t.visible())&&!(s.badLine||s.allpts==null||isNaN(s.allpts[0]))){var c;n&&(c=n,e.translate(-c.x1,-c.y1));var l=a?t.pstyle(`opacity`).value:1,u=a?t.pstyle(`line-opacity`).value:1,d=t.pstyle(`curve-style`).value,f=t.pstyle(`line-style`).value,p=t.pstyle(`width`).pfValue,m=t.pstyle(`line-cap`).value,h=t.pstyle(`line-outline-width`).value,g=t.pstyle(`line-outline-color`).value,_=l*u,v=l*u,y=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_;d===`straight-triangle`?(o.eleStrokeStyle(e,t,n),o.drawEdgeTrianglePath(t,e,s.allpts)):(e.lineWidth=p,e.lineCap=m,o.eleStrokeStyle(e,t,n),o.drawEdgePath(t,e,s.allpts,f),e.lineCap=`butt`)},b=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_;if(e.lineWidth=p+h,e.lineCap=m,h>0)o.colorStrokeStyle(e,g[0],g[1],g[2],n);else{e.lineCap=`butt`;return}d===`straight-triangle`?o.drawEdgeTrianglePath(t,e,s.allpts):(o.drawEdgePath(t,e,s.allpts,f),e.lineCap=`butt`)},x=function(){i&&o.drawEdgeOverlay(e,t)},S=function(){i&&o.drawEdgeUnderlay(e,t)},C=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:v;o.drawArrowheads(e,t,n)},w=function(){o.drawElementText(e,t,null,r)};if(e.lineJoin=`round`,t.pstyle(`ghost`).value===`yes`){var T=t.pstyle(`ghost-offset-x`).pfValue,E=t.pstyle(`ghost-offset-y`).pfValue,D=_*t.pstyle(`ghost-opacity`).value;e.translate(T,E),y(D),C(D),e.translate(-T,-E)}else b();S(),y(),C(),x(),w(),n&&e.translate(c.x1,c.y1)}};var am=function(e){if(![`overlay`,`underlay`].includes(e))throw Error(`Invalid state`);return function(t,n){if(n.visible()){var r=n.pstyle(`${e}-opacity`).value;if(r!==0){var i=this,a=i.usePaths(),o=n._private.rscratch,s=2*n.pstyle(`${e}-padding`).pfValue,c=n.pstyle(`${e}-color`).value;t.lineWidth=s,t.lineCap=o.edgeType===`self`&&!a?`butt`:`round`,i.colorStrokeStyle(t,c[0],c[1],c[2],r),i.drawEdgePath(n,t,o.allpts,`solid`)}}}};im.drawEdgeOverlay=am(`overlay`),im.drawEdgeUnderlay=am(`underlay`),im.drawEdgePath=function(e,t,n,r){var i=e._private.rscratch,a=t,s,c=!1,l=this.usePaths(),u=e.pstyle(`line-dash-pattern`).pfValue,d=e.pstyle(`line-dash-offset`).pfValue;if(l){var f=n.join(`$`);i.pathCacheKey&&i.pathCacheKey===f?(s=t=i.pathCache,c=!0):(s=t=new Path2D,i.pathCacheKey=f,i.pathCache=s)}if(a.setLineDash)switch(r){case`dotted`:a.setLineDash([1,1]);break;case`dashed`:a.setLineDash(u),a.lineDashOffset=d;break;case`solid`:a.setLineDash([])}if(!c&&!i.badLine)switch(t.beginPath&&t.beginPath(),t.moveTo(n[0],n[1]),i.edgeType){case`bezier`:case`self`:case`compound`:case`multibezier`:for(var p=2;p+35&&arguments[5]!==void 0?arguments[5]:!0,o=this;if(r==null){if(a&&!o.eleTextBiggerThanMin(t))return}else if(r===!1)return;if(t.isNode()){var s=t.pstyle(`label`);if(!s||!s.value)return;var c=o.getLabelJustification(t),l=t.pstyle(`text-metrics`).strValue===`glyph`;e.textAlign=c,e.textBaseline=l?`alphabetic`:`bottom`}else{var u=t.element()._private.rscratch.badLine,d=t.pstyle(`label`),f=t.pstyle(`source-label`),p=t.pstyle(`target-label`);if(u||(!d||!d.value)&&(!f||!f.value)&&(!p||!p.value))return;e.textAlign=`center`,e.textBaseline=`bottom`}var m=!n,h;n&&(h=n,e.translate(-h.x1,-h.y1)),i==null?(o.drawText(e,t,null,m,a),t.isEdge()&&(o.drawText(e,t,`source`,m,a),o.drawText(e,t,`target`,m,a))):o.drawText(e,t,i,m,a),n&&e.translate(h.x1,h.y1)},sm.getFontCache=function(e){var t;this.fontCaches=this.fontCaches||[];for(var n=0;n2&&arguments[2]!==void 0?arguments[2]:!0,r=t.pstyle(`font-style`).strValue,i=t.pstyle(`font-size`).pfValue+`px`,a=t.pstyle(`font-family`).strValue,o=t.pstyle(`font-weight`).strValue,s=n?t.effectiveOpacity()*t.pstyle(`text-opacity`).value:1,c=t.pstyle(`text-outline-opacity`).value*s,l=t.pstyle(`color`).value,u=t.pstyle(`text-outline-color`).value;e.font=r+` `+o+` `+i+` `+a,e.lineJoin=`round`,this.colorFillStyle(e,l[0],l[1],l[2],s),this.colorStrokeStyle(e,u[0],u[1],u[2],c)};function cm(e,t,n,r,i){var a=Math.min(r,i)/2,o=t+r/2,s=n+i/2;e.beginPath(),e.arc(o,s,a,0,Math.PI*2),e.closePath()}function lm(e,t,n,r,i){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:5,o=Math.min(a,r/2,i/2);e.beginPath(),e.moveTo(t+o,n),e.lineTo(t+r-o,n),e.quadraticCurveTo(t+r,n,t+r,n+o),e.lineTo(t+r,n+i-o),e.quadraticCurveTo(t+r,n+i,t+r-o,n+i),e.lineTo(t+o,n+i),e.quadraticCurveTo(t,n+i,t,n+i-o),e.lineTo(t,n+o),e.quadraticCurveTo(t,n,t+o,n),e.closePath()}sm.getTextAngle=function(e,t){var n,r=e._private.rscratch,i=t?t+`-`:``,a=e.pstyle(i+`text-rotation`);if(a.strValue===`autorotate`){var o=Xt(r,`labelAngle`,t);n=e.isEdge()?o:0}else n=a.strValue===`none`?0:a.pfValue;return n},sm.drawText=function(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=t._private.rscratch,o=i?t.effectiveOpacity():1;if(!(i&&(o===0||t.pstyle(`text-opacity`).value===0))){n===`main`&&(n=null);var s=Xt(a,`labelX`,n),c=Xt(a,`labelY`,n),l,u,d=this.getLabelText(t,n);if(d!=null&&d!==``&&!isNaN(s)&&!isNaN(c)){this.setupTextStyle(e,t,i);var f=n?n+`-`:``,p=Xt(a,`labelWidth`,n),m=Xt(a,`labelHeight`,n),h=Xt(a,`labelActualDescent`,n),g=t.pstyle(f+`text-margin-x`).pfValue,_=t.pstyle(f+`text-margin-y`).pfValue,v=t.isEdge(),y=t.pstyle(`text-halign`).value,b=t.pstyle(`text-valign`).value;v&&(y=`center`,b=`center`),s+=g,c+=_;var x=r?this.getTextAngle(t,n):0;x!==0&&(l=s,u=c,e.translate(l,u),e.rotate(x),s=0,c=0);var S=rl(y),C=il(b);switch(C){case`top`:break;case`center`:c+=m/2;break;case`bottom`:c+=m}var w=t.pstyle(`text-background-opacity`).value,T=t.pstyle(`text-border-opacity`).value,E=t.pstyle(`text-border-width`).pfValue,D=t.pstyle(`text-background-padding`).pfValue,O=t.pstyle(`text-background-shape`).strValue,k=O===`round-rectangle`||O===`roundrectangle`,A=O===`circle`,j=2;if(w>0||E>0&&T>0){var M=e.fillStyle,N=e.strokeStyle,P=e.lineWidth,F=t.pstyle(`text-background-color`).value,I=t.pstyle(`text-border-color`).value,L=t.pstyle(`text-border-style`).value,R=w>0,z=E>0&&T>0,B=s-D;switch(S){case`left`:B-=p;break;case`center`:B-=p/2}var V=c-m-D,H=p+2*D,U=m+2*D;if(R&&(e.fillStyle=`rgba(${F[0]},${F[1]},${F[2]},${w*o})`),z&&(e.strokeStyle=`rgba(${I[0]},${I[1]},${I[2]},${T*o})`,e.lineWidth=E,e.setLineDash))switch(L){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash([4,2]);break;case`double`:e.lineWidth=E/4,e.setLineDash([]);break;default:e.setLineDash([])}if(k?(e.beginPath(),lm(e,B,V,H,U,j)):A?(e.beginPath(),cm(e,B,V,H,U)):(e.beginPath(),e.rect(B,V,H,U)),R&&e.fill(),z&&e.stroke(),z&&L===`double`){var W=E/2;e.beginPath(),k?lm(e,B+W,V+W,H-2*W,U-2*W,j):e.rect(B+W,V+W,H-2*W,U-2*W),e.stroke()}e.fillStyle=M,e.strokeStyle=N,e.lineWidth=P,e.setLineDash&&e.setLineDash([])}var G=2*t.pstyle(`text-outline-width`).pfValue;if(G>0&&(e.lineWidth=G),c-=h,t.pstyle(`text-wrap`).value===`wrap`){var K=Xt(a,`labelWrapCachedLines`,n),q=Xt(a,`labelLineHeight`,n),J=p/2,ee=this.getLabelJustification(t);switch(ee===`auto`||(S===`left`?ee===`left`?s+=-p:ee===`center`&&(s+=-J):S===`center`?ee===`left`?s+=-J:ee===`right`&&(s+=J):S===`right`&&(ee===`center`?s+=J:ee===`right`&&(s+=p))),C){case`top`:c-=(K.length-1)*q;break;case`center`:case`bottom`:c-=(K.length-1)*q}for(var Y=0;Y0&&e.strokeText(K[Y],s,c),e.fillText(K[Y],s,c),c+=q}else G>0&&e.strokeText(d,s,c),e.fillText(d,s,c);x!==0&&(e.rotate(-x),e.translate(-l,-u))}}};var um={};um.drawNode=function(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0,o=this,s,c,l=t._private,u=l.rscratch,d=t.position();if(!(!A(d.x)||!A(d.y))&&!(a&&!t.visible())){var f=a?t.effectiveOpacity():1,p=o.usePaths(),m,h=!1,g=t.padding();s=t.width()+2*g,c=t.height()+2*g;var _;n&&(_=n,e.translate(-_.x1,-_.y1));for(var v=t.pstyle(`background-image`).value,y=Array(v.length),b=Array(v.length),x=0,S=0;S0&&arguments[0]!==void 0?arguments[0]:D;o.eleFillStyle(e,t,n)},W=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:I;o.colorStrokeStyle(e,O[0],O[1],O[2],t)},G=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:B;o.colorStrokeStyle(e,R[0],R[1],R[2],t)},K=function(e,t,n,r){var i=o.nodePathCache=o.nodePathCache||[],a=wt(n===`polygon`?n+`,`+r.join(`,`):n,``+t,``+e,``+H),s=i[a],c,l=!1;return s==null?(c=new Path2D,i[a]=u.pathCache=c):(c=s,l=!0,u.pathCache=c),{path:c,cacheHit:l}},q=t.pstyle(`shape`).strValue,J=t.pstyle(`shape-polygon-points`).pfValue;if(p){e.translate(d.x,d.y);var ee=K(s,c,q,J);m=ee.path,h=ee.cacheHit}var Y=function(){if(!h){var n=d;p&&(n={x:0,y:0}),o.nodeShapes[o.getNodeShape(t)].draw(m||e,n.x,n.y,s,c,H,u)}p?e.fill(m):e.fill()},te=function(){for(var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:f,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,i=l.backgrounding,a=0,s=0;s0&&arguments[0]!==void 0&&arguments[0],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f;o.hasPie(t)&&(o.drawPie(e,t,r),n&&(p||o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u)))},re=function(){var n=arguments.length>0&&arguments[0]!==void 0&&arguments[0],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f;o.hasStripe(t)&&(e.save(),p?e.clip(u.pathCache):(o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u),e.clip()),o.drawStripe(e,t,r),e.restore(),n&&(p||o.nodeShapes[o.getNodeShape(t)].draw(e,d.x,d.y,s,c,H,u)))},ie=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:f,n=(T>0?T:-T)*t,r=T>0?0:255;T!==0&&(o.colorFillStyle(e,r,r,r,n),p?e.fill(m):e.fill())},ae=function(){if(E>0){if(e.lineWidth=E,e.lineCap=M,e.lineJoin=j,e.setLineDash)switch(k){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash(P),e.lineDashOffset=F;break;case`solid`:case`double`:e.setLineDash([])}if(N!==`center`){if(e.save(),e.lineWidth*=2,N===`inside`)p?e.clip(m):e.clip();else{var t=new Path2D;t.rect(-s/2-E,-c/2-E,s+2*E,c+2*E),t.addPath(m),e.clip(t,`evenodd`)}p?e.stroke(m):e.stroke(),e.restore()}else p?e.stroke(m):e.stroke();if(k===`double`){e.lineWidth=E/3;var n=e.globalCompositeOperation;e.globalCompositeOperation=`destination-out`,p?e.stroke(m):e.stroke(),e.globalCompositeOperation=n}e.setLineDash&&e.setLineDash([])}},oe=function(){if(L>0){if(e.lineWidth=L,e.lineCap=`butt`,e.setLineDash)switch(z){case`dotted`:e.setLineDash([1,1]);break;case`dashed`:e.setLineDash([4,2]);break;case`solid`:case`double`:e.setLineDash([])}var n=d;p&&(n={x:0,y:0});var r=o.getNodeShape(t),i=E;N===`inside`&&(i=0),N===`outside`&&(i*=2);var a=(s+i+(L+V))/s,l=(c+i+(L+V))/c,u=s*a,f=c*l,m=o.nodeShapes[r].points,h;if(p&&(h=K(u,f,r,m).path),r===`ellipse`)o.drawEllipsePath(h||e,n.x,n.y,u,f);else if([`round-diamond`,`round-heptagon`,`round-hexagon`,`round-octagon`,`round-pentagon`,`round-polygon`,`round-triangle`,`round-tag`].includes(r)){var g=0,_=0,v=0;r===`round-diamond`?g=(i+V+L)*1.4:r===`round-heptagon`?(g=(i+V+L)*1.075,v=-(i/2+V+L)/35):r===`round-hexagon`?g=(i+V+L)*1.12:r===`round-pentagon`?(g=(i+V+L)*1.13,v=-(i/2+V+L)/15):r===`round-tag`?(g=(i+V+L)*1.12,_=(i/2+L+V)*.07):r===`round-triangle`&&(g=(i+V+L)*(Math.PI/2),v=-(i+V/2+L)/Math.PI),g!==0&&(a=(s+g)/s,u=s*a,[`round-hexagon`,`round-tag`].includes(r)||(l=(c+g)/c,f=c*l)),H=H===`auto`?Pr(u,f):H;for(var y=u/2,b=f/2,x=H+(i+L+V)/2,S=Array(m.length/2),C=Array(m.length/2),w=0;w0){if(r||=n.position(),i==null||a==null){var f=n.padding();i=n.width()+2*f,a=n.height()+2*f}o.colorFillStyle(t,l[0],l[1],l[2],c),o.nodeShapes[u].draw(t,r.x,r.y,i+s*2,a+s*2,d),t.fill()}}}};um.drawNodeOverlay=dm(`overlay`),um.drawNodeUnderlay=dm(`underlay`),um.hasPie=function(e){return e=e[0],e._private.hasPie},um.hasStripe=function(e){return e=e[0],e._private.hasStripe},um.drawPie=function(e,t,n,r){t=t[0],r||=t.position();var i=t.cy().style(),a=t.pstyle(`pie-size`),o=t.pstyle(`pie-hole`),s=t.pstyle(`pie-start-angle`).pfValue,c=r.x,l=r.y,u=t.width(),d=t.height(),f=Math.min(u,d)/2,p,m=0;if(this.usePaths()&&(c=0,l=0),a.units===`%`?f*=a.pfValue:a.pfValue!==void 0&&(f=a.pfValue/2),o.units===`%`?p=f*o.pfValue:o.pfValue!==void 0&&(p=o.pfValue/2),!(p>=f))for(var h=1;h<=i.pieBackgroundN;h++){var g=t.pstyle(`pie-`+h+`-background-size`).value,_=t.pstyle(`pie-`+h+`-background-color`).value,v=t.pstyle(`pie-`+h+`-background-opacity`).value*n,y=g/100;y+m>1&&(y=1-m);var b=1.5*Math.PI+2*Math.PI*m;b+=s;var x=2*Math.PI*y,S=b+x;g===0||m>=1||m+y>1||(p===0?(e.beginPath(),e.moveTo(c,l),e.arc(c,l,f,b,S),e.closePath()):(e.beginPath(),e.arc(c,l,f,b,S),e.arc(c,l,p,S,b,!0),e.closePath()),this.colorFillStyle(e,_[0],_[1],_[2],v),e.fill(),m+=y)}},um.drawStripe=function(e,t,n,r){t=t[0],r||=t.position();var i=t.cy().style(),a=r.x,o=r.y,s=t.width(),c=t.height(),l=0,u=this.usePaths();e.save();var d=t.pstyle(`stripe-direction`).value,f=t.pstyle(`stripe-size`);switch(d){case`vertical`:break;case`righward`:e.rotate(-Math.PI/2)}var p=s,m=c;f.units===`%`?(p*=f.pfValue,m*=f.pfValue):f.pfValue!==void 0&&(p=f.pfValue,m=f.pfValue),u&&(a=0,o=0),o-=p/2,a-=m/2;for(var h=1;h<=i.stripeBackgroundN;h++){var g=t.pstyle(`stripe-`+h+`-background-size`).value,_=t.pstyle(`stripe-`+h+`-background-color`).value,v=t.pstyle(`stripe-`+h+`-background-opacity`).value*n,y=g/100;y+l>1&&(y=1-l),!(g===0||l>=1||l+y>1)&&(e.beginPath(),e.rect(a,o+m*l,p,m*y),e.closePath(),this.colorFillStyle(e,_[0],_[1],_[2],v),e.fill(),l+=y)}e.restore()};var fm={},pm=100;fm.getPixelRatio=function(){var e=this.data.contexts[0];if(this.forcedPixelRatio!=null)return this.forcedPixelRatio;var t=this.cy.window(),n=e.backingStorePixelRatio||e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1;return(t.devicePixelRatio||1)/n},fm.paintCache=function(e){for(var t=this.paintCaches=this.paintCaches||[],n=!0,r,i=0;it.minMbLowQualFrames&&(t.motionBlurPxRatio=t.mbPxRBlurry)),t.clearingMotionBlur&&(t.motionBlurPxRatio=1),t.textureDrawLastFrame&&!d&&(u[t.NODE]=!0,u[t.SELECT_BOX]=!0);var v=n.style(),y=n.zoom(),b=o===void 0?y:o,x=n.pan(),S={x:x.x,y:x.y},C={zoom:y,pan:{x:x.x,y:x.y}},w=t.prevViewport;w!==void 0&&C.zoom===w.zoom&&C.pan.x===w.pan.x&&C.pan.y===w.pan.y&&!(h&&!m)&&(t.motionBlurPxRatio=1),s&&(S=s),b*=c,S.x*=c,S.y*=c;var T=t.getCachedZSortedEles();function E(e,n,r,i,a){var o=e.globalCompositeOperation;e.globalCompositeOperation=`destination-out`,t.colorFillStyle(e,255,255,255,t.motionBlurTransparency),e.fillRect(n,r,i,a),e.globalCompositeOperation=o}function D(e,n){var a,c,u,d;!t.clearingMotionBlur&&(e===l.bufferContexts[t.MOTIONBLUR_BUFFER_NODE]||e===l.bufferContexts[t.MOTIONBLUR_BUFFER_DRAG])?(a={x:x.x*p,y:x.y*p},c=y*p,u=t.canvasWidth*p,d=t.canvasHeight*p):(a=S,c=b,u=t.canvasWidth,d=t.canvasHeight),e.setTransform(1,0,0,1,0,0),n===`motionBlur`?E(e,0,0,u,d):!r&&(n===void 0||n)&&e.clearRect(0,0,u,d),i||(e.translate(a.x,a.y),e.scale(c,c)),s&&e.translate(s.x,s.y),o&&e.scale(o,o)}if(d||(t.textureDrawLastFrame=!1),d){if(t.textureDrawLastFrame=!0,!t.textureCache){t.textureCache={},t.textureCache.bb=n.mutableElements().boundingBox(),t.textureCache.texture=t.data.bufferCanvases[t.TEXTURE_BUFFER];var O=t.data.bufferContexts[t.TEXTURE_BUFFER];O.setTransform(1,0,0,1,0,0),O.clearRect(0,0,t.canvasWidth*t.textureMult,t.canvasHeight*t.textureMult),t.render({forcedContext:O,drawOnlyNodeLayer:!0,forcedPxRatio:c*t.textureMult});var C=t.textureCache.viewport={zoom:n.zoom(),pan:n.pan(),width:t.canvasWidth,height:t.canvasHeight};C.mpan={x:(0-C.pan.x)/C.zoom,y:(0-C.pan.y)/C.zoom}}u[t.DRAG]=!1,u[t.NODE]=!1;var k=l.contexts[t.NODE],A=t.textureCache.texture,C=t.textureCache.viewport;k.setTransform(1,0,0,1,0,0),f?E(k,0,0,C.width,C.height):k.clearRect(0,0,C.width,C.height);var j=v.core(`outside-texture-bg-color`).value,M=v.core(`outside-texture-bg-opacity`).value;t.colorFillStyle(k,j[0],j[1],j[2],M),k.fillRect(0,0,C.width,C.height);var y=n.zoom();D(k,!1),k.clearRect(C.mpan.x,C.mpan.y,C.width/C.zoom/c,C.height/C.zoom/c),k.drawImage(A,C.mpan.x,C.mpan.y,C.width/C.zoom/c,C.height/C.zoom/c)}else t.textureOnViewport&&!r&&(t.textureCache=null);var N=n.extent(),P=t.pinching||t.hoverData.dragging||t.swipePanning||t.data.wheelZooming||t.hoverData.draggingEles||t.cy.animated(),F=t.hideEdgesOnViewport&&P,I=[];if(I[t.NODE]=!u[t.NODE]&&f&&!t.clearedForMotionBlur[t.NODE]||t.clearingMotionBlur,I[t.NODE]&&(t.clearedForMotionBlur[t.NODE]=!0),I[t.DRAG]=!u[t.DRAG]&&f&&!t.clearedForMotionBlur[t.DRAG]||t.clearingMotionBlur,I[t.DRAG]&&(t.clearedForMotionBlur[t.DRAG]=!0),u[t.NODE]||i||a||I[t.NODE]){var L=f&&!I[t.NODE]&&p!==1,k=r||(L?t.data.bufferContexts[t.MOTIONBLUR_BUFFER_NODE]:l.contexts[t.NODE]);D(k,f&&!L?`motionBlur`:void 0),F?t.drawCachedNodes(k,T.nondrag,c,N):t.drawLayeredElements(k,T.nondrag,c,N),t.debug&&t.drawDebugPoints(k,T.nondrag),!i&&!f&&(u[t.NODE]=!1)}if(!a&&(u[t.DRAG]||i||I[t.DRAG])){var L=f&&!I[t.DRAG]&&p!==1,k=r||(L?t.data.bufferContexts[t.MOTIONBLUR_BUFFER_DRAG]:l.contexts[t.DRAG]);D(k,f&&!L?`motionBlur`:void 0),F?t.drawCachedNodes(k,T.drag,c,N):t.drawCachedElements(k,T.drag,c,N),t.debug&&t.drawDebugPoints(k,T.drag),!i&&!f&&(u[t.DRAG]=!1)}if(this.drawSelectionRectangle(e,D),f&&p!==1){var R=l.contexts[t.NODE],z=t.data.bufferCanvases[t.MOTIONBLUR_BUFFER_NODE],B=l.contexts[t.DRAG],V=t.data.bufferCanvases[t.MOTIONBLUR_BUFFER_DRAG],H=function(e,n,r){e.setTransform(1,0,0,1,0,0),r||!_?e.clearRect(0,0,t.canvasWidth,t.canvasHeight):E(e,0,0,t.canvasWidth,t.canvasHeight);var i=p;e.drawImage(n,0,0,t.canvasWidth*i,t.canvasHeight*i,0,0,t.canvasWidth,t.canvasHeight)};(u[t.NODE]||I[t.NODE])&&(H(R,z,I[t.NODE]),u[t.NODE]=!1),(u[t.DRAG]||I[t.DRAG])&&(H(B,V,I[t.DRAG]),u[t.DRAG]=!1)}t.prevViewport=C,t.clearingMotionBlur&&(t.clearingMotionBlur=!1,t.motionBlurCleared=!0,t.motionBlur=!0),f&&(t.motionBlurTimeout=setTimeout(function(){t.motionBlurTimeout=null,t.clearedForMotionBlur[t.NODE]=!1,t.clearedForMotionBlur[t.DRAG]=!1,t.motionBlur=!1,t.clearingMotionBlur=!d,t.mbFrames=0,u[t.NODE]=!0,u[t.DRAG]=!0,t.redraw()},pm)),r||n.emit(`render`)};var mm;fm.drawSelectionRectangle=function(e,t){var n=this,r=n.cy,i=n.data,a=r.style(),o=e.drawOnlyNodeLayer,s=e.drawAllLayers,c=i.canvasNeedsRedraw,l=e.forcedContext;if(n.showFps||!o&&c[n.SELECT_BOX]&&!s){var u=l||i.contexts[n.SELECT_BOX];if(t(u),n.selection[4]==1&&(n.hoverData.selecting||n.touchData.selecting)){var d=n.cy.zoom(),f=a.core(`selection-box-border-width`).value/d;u.lineWidth=f,u.fillStyle=`rgba(`+a.core(`selection-box-color`).value[0]+`,`+a.core(`selection-box-color`).value[1]+`,`+a.core(`selection-box-color`).value[2]+`,`+a.core(`selection-box-opacity`).value+`)`,u.fillRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]),f>0&&(u.strokeStyle=`rgba(`+a.core(`selection-box-border-color`).value[0]+`,`+a.core(`selection-box-border-color`).value[1]+`,`+a.core(`selection-box-border-color`).value[2]+`,`+a.core(`selection-box-opacity`).value+`)`,u.strokeRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]))}if(i.bgActivePosistion&&!n.hoverData.selecting){var d=n.cy.zoom(),p=i.bgActivePosistion;u.fillStyle=`rgba(`+a.core(`active-bg-color`).value[0]+`,`+a.core(`active-bg-color`).value[1]+`,`+a.core(`active-bg-color`).value[2]+`,`+a.core(`active-bg-opacity`).value+`)`,u.beginPath(),u.arc(p.x,p.y,a.core(`active-bg-size`).pfValue/d,0,2*Math.PI),u.fill()}var m=n.lastRedrawTime;if(n.showFps&&m){m=Math.round(m);var h=Math.round(1e3/m),g=`1 frame = `+m+` ms = `+h+` fps`;u.setTransform(1,0,0,1,0,0),u.fillStyle=`rgba(255, 0, 0, 0.75)`,u.strokeStyle=`rgba(255, 0, 0, 0.75)`,u.font=`30px Arial`,mm||=u.measureText(g).actualBoundingBoxAscent,u.fillText(g,0,mm),u.strokeRect(0,mm+10,250,20),u.fillRect(0,mm+10,250*Math.min(h/60,1),20)}s||(c[n.SELECT_BOX]=!1)}};function hm(e,t,n){var r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS))throw Error(e.getShaderInfoLog(r));return r}function gm(e,t,n){var r=hm(e,e.VERTEX_SHADER,t),i=hm(e,e.FRAGMENT_SHADER,n),a=e.createProgram();if(e.attachShader(a,r),e.attachShader(a,i),e.linkProgram(a),!e.getProgramParameter(a,e.LINK_STATUS))throw Error(`Could not initialize shaders`);return a}function _m(e,t,n){n===void 0&&(n=t);var r=e.makeOffscreenCanvas(t,n),i=r.context=r.getContext(`2d`);return r.clear=function(){return i.clearRect(0,0,r.width,r.height)},r.clear(),r}function vm(e){var t=e.pixelRatio,n=e.cy.zoom(),r=e.cy.pan();return{zoom:n*t,pan:{x:r.x*t,y:r.y*t}}}function ym(e){var t=e.pixelRatio;return e.cy.zoom()*t}function bm(e,t,n,r,i){var a=r*n+t.x,o=i*n+t.y;return o=Math.round(e.canvasHeight-o),[a,o]}function xm(e,t){return t.picking?!0:e.pstyle(`background-fill`).value!==`solid`||e.pstyle(`background-image`).strValue!==`none`?!1:e.pstyle(`border-width`).value===0||e.pstyle(`border-opacity`).value===0||e.pstyle(`border-style`).value===`solid`}function Sm(e,t){if(e.length!==t.length)return!1;for(var n=0;n>0&255)/255,n[1]=(e>>8&255)/255,n[2]=(e>>16&255)/255,n[3]=(e>>24&255)/255,n}function Tm(e){return e[0]+(e[1]<<8)+(e[2]<<16)+(e[3]<<24)}function Em(e,t){var n=e.createTexture();return n.buffer=function(t){e.bindTexture(e.TEXTURE_2D,n),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR_MIPMAP_NEAREST),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),e.generateMipmap(e.TEXTURE_2D),e.bindTexture(e.TEXTURE_2D,null)},n.deleteTexture=function(){e.deleteTexture(n)},n}function Dm(e,t){switch(t){case`float`:return[1,e.FLOAT,4];case`vec2`:return[2,e.FLOAT,4];case`vec3`:return[3,e.FLOAT,4];case`vec4`:return[4,e.FLOAT,4];case`int`:return[1,e.INT,4];case`ivec2`:return[2,e.INT,4]}}function Om(e,t,n){switch(t){case e.FLOAT:return new Float32Array(n);case e.INT:return new Int32Array(n)}}function km(e,t,n,r,i,a){switch(t){case e.FLOAT:return new Float32Array(n.buffer,a*r,i);case e.INT:return new Int32Array(n.buffer,a*r,i)}}function Am(e,t,n,r){var i=f(Dm(e,t),2),a=i[0],o=i[1],s=Om(e,o,r),c=e.createBuffer();return e.bindBuffer(e.ARRAY_BUFFER,c),e.bufferData(e.ARRAY_BUFFER,s,e.STATIC_DRAW),o===e.FLOAT?e.vertexAttribPointer(n,a,o,!1,0,0):o===e.INT&&e.vertexAttribIPointer(n,a,o,0,0),e.enableVertexAttribArray(n),e.bindBuffer(e.ARRAY_BUFFER,null),c}function jm(e,t,n,r){var i=f(Dm(e,n),3),a=i[0],o=i[1],s=i[2],c=Om(e,o,t*a),l=a*s,u=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,u),e.bufferData(e.ARRAY_BUFFER,t*l,e.DYNAMIC_DRAW),e.enableVertexAttribArray(r),o===e.FLOAT?e.vertexAttribPointer(r,a,o,!1,l,0):o===e.INT&&e.vertexAttribIPointer(r,a,o,l,0),e.vertexAttribDivisor(r,1),e.bindBuffer(e.ARRAY_BUFFER,null);for(var d=Array(t),p=0;pi&&(a=i/t,o=t*a,s=n*a),{scale:a,texW:o,texH:s}}},{key:`draw`,value:function(e,t,n){var r=this;if(this.locked)throw Error(`can't draw, atlas is locked`);var i=this.texSize,a=this.texRows,o=this.texHeight,s=this.getScale(t),c=s.scale,l=s.texW,u=s.texH,d=function(e,r){if(n&&r){var i=r.context,a=e.x,s=e.row,l=a,u=o*s;i.save(),i.translate(l,u),i.scale(c,c),n(i,t),i.restore()}},f=[null,null],p=function(){d(r.freePointer,r.canvas),f[0]={x:r.freePointer.x,y:r.freePointer.row*o,w:l,h:u},f[1]={x:r.freePointer.x+l,y:r.freePointer.row*o,w:0,h:u},r.freePointer.x+=l,r.freePointer.x==i&&(r.freePointer.x=0,r.freePointer.row++)},m=function(){var e=r.scratch,t=r.canvas;e.clear(),d({x:0,row:0},e);var n=i-r.freePointer.x,a=l-n,s=o,c=r.freePointer.x,p=r.freePointer.row*o,m=n;t.context.drawImage(e,0,0,m,s,c,p,m,s),f[0]={x:c,y:p,w:m,h:u};var h=n,g=(r.freePointer.row+1)*o,_=a;t&&t.context.drawImage(e,h,0,_,s,0,g,_,s),f[1]={x:0,y:g,w:_,h:u},r.freePointer.x=a,r.freePointer.row++},h=function(){r.freePointer.x=0,r.freePointer.row++};if(this.freePointer.x+l<=i)p();else if(this.freePointer.row>=a-1)return!1;else this.freePointer.x===i?(h(),p()):this.enableWrapping?m():(h(),p());return this.keyToLocation.set(e,f),this.needsBuffer=!0,f}},{key:`getOffsets`,value:function(e){return this.keyToLocation.get(e)}},{key:`isEmpty`,value:function(){return this.freePointer.x===0&&this.freePointer.row===0}},{key:`canFit`,value:function(e){if(this.locked)return!1;var t=this.texSize,n=this.texRows,r=this.getScale(e).texW;return this.freePointer.x+r>t?this.freePointer.row1&&arguments[1]!==void 0?arguments[1]:{},r=n.forceRedraw,i=r!==void 0&&r,a=n.filterEle,s=a===void 0?function(){return!0}:a,c=n.filterType,l=c===void 0?function(){return!0}:c,u=!1,d=!1,f=o(e),p;try{for(f.s();!(p=f.n()).done;){var m=p.value;if(s(m)){var h=o(this.renderTypes.values()),g;try{var _=function(){var e=g.value,n=e.type;if(l(n)){var r=t.collections.get(e.collection),a=e.getKey(m),o=Array.isArray(a)?a:[a];if(i)o.forEach(function(e){return r.markKeyForGC(e)}),d=!0;else{var s=e.getID?e.getID(m):m.id(),c=t._key(n,s),f=t.typeAndIdToKey.get(c);f!==void 0&&!Sm(o,f)&&(u=!0,t.typeAndIdToKey.delete(c),f.forEach(function(e){return r.markKeyForGC(e)}))}}};for(h.s();!(g=h.n()).done;)_()}catch(e){h.e(e)}finally{h.f()}}}}catch(e){f.e(e)}finally{f.f()}return d&&(this.gc(),u=!1),u}},{key:`gc`,value:function(){var e=o(this.collections.values()),t;try{for(e.s();!(t=e.n()).done;)t.value.gc()}catch(t){e.e(t)}finally{e.f()}}},{key:`getOrCreateAtlas`,value:function(e,t,n,r){var i=this.renderTypes.get(t),a=this.collections.get(i.collection),o=!1,s=a.draw(r,n,function(t){i.drawClipped?(t.save(),t.beginPath(),t.rect(0,0,n.w,n.h),t.clip(),i.drawElement(t,e,n,!0,!0),t.restore()):i.drawElement(t,e,n,!0,!0),o=!0});if(o){var c=i.getID?i.getID(e):e.id(),l=this._key(t,c);this.typeAndIdToKey.has(l)?this.typeAndIdToKey.get(l).push(r):this.typeAndIdToKey.set(l,[r])}return s}},{key:`getAtlasInfo`,value:function(e,t){var n=this,r=this.renderTypes.get(t),i=r.getKey(e);return(Array.isArray(i)?i:[i]).map(function(i){var a=r.getBoundingBox(e,i),o=n.getOrCreateAtlas(e,t,a,i),s=f(o.getOffsets(i),2),c=s[0];return{atlas:o,tex:c,tex1:c,tex2:s[1],bb:a}})}},{key:`getDebugInfo`,value:function(){var e=[],t=o(this.collections),n;try{for(t.s();!(n=t.n()).done;){var r=f(n.value,2),i=r[0],a=r[1].getCounts(),s=a.keyCount,c=a.atlasCount;e.push({type:i,keyCount:s,atlasCount:c})}}catch(e){t.e(e)}finally{t.f()}return e}}])}(),Km=function(){function e(t){r(this,e),this.globalOptions=t,this.atlasSize=t.webglTexSize,this.maxAtlasesPerBatch=t.webglTexPerBatch,this.batchAtlases=[]}return a(e,[{key:`getMaxAtlasesPerBatch`,value:function(){return this.maxAtlasesPerBatch}},{key:`getAtlasSize`,value:function(){return this.atlasSize}},{key:`getIndexArray`,value:function(){return Array.from({length:this.maxAtlasesPerBatch},function(e,t){return t})}},{key:`startBatch`,value:function(){this.batchAtlases=[]}},{key:`getAtlasCount`,value:function(){return this.batchAtlases.length}},{key:`getAtlases`,value:function(){return this.batchAtlases}},{key:`canAddToCurrentBatch`,value:function(e){return this.batchAtlases.length!==this.maxAtlasesPerBatch||this.batchAtlases.includes(e)}},{key:`getAtlasIndexForBatch`,value:function(e){var t=this.batchAtlases.indexOf(e);if(t<0){if(this.batchAtlases.length===this.maxAtlasesPerBatch)throw Error(`cannot add more atlases to batch`);this.batchAtlases.push(e),t=this.batchAtlases.length-1}return t}}])}(),qm=` + float circleSD(vec2 p, float r) { + return distance(vec2(0), p) - r; // signed distance + } +`,Jm=` + float rectangleSD(vec2 p, vec2 b) { + vec2 d = abs(p)-b; + return distance(vec2(0),max(d,0.0)) + min(max(d.x,d.y),0.0); + } +`,Ym=` + float roundRectangleSD(vec2 p, vec2 b, vec4 cr) { + cr.xy = (p.x > 0.0) ? cr.xy : cr.zw; + cr.x = (p.y > 0.0) ? cr.x : cr.y; + vec2 q = abs(p) - b + cr.x; + return min(max(q.x, q.y), 0.0) + distance(vec2(0), max(q, 0.0)) - cr.x; + } +`,Xm=` + float ellipseSD(vec2 p, vec2 ab) { + p = abs( p ); // symmetry + + // find root with Newton solver + vec2 q = ab*(p-ab); + float w = (q.x1.0) ? d : -d; + } +`,Zm={SCREEN:{name:`screen`,screen:!0},PICKING:{name:`picking`,picking:!0}},Qm={IGNORE:1,USE_BB:2},$m=0,eh=1,th=2,nh=3,rh=4,ih=5,ah=6,oh=7,sh=function(){function e(t,n,i){r(this,e),this.r=t,this.gl=n,this.maxInstances=i.webglBatchSize,this.atlasSize=i.webglTexSize,this.bgColor=i.bgColor,this.debug=i.webglDebug,this.batchDebugInfo=[],i.enableWrapping=!0,i.createTextureCanvas=_m,this.atlasManager=new Gm(t,i),this.batchManager=new Km(i),this.simpleShapeOptions=new Map,this.program=this._createShaderProgram(Zm.SCREEN),this.pickingProgram=this._createShaderProgram(Zm.PICKING),this.vao=this._createVAO()}return a(e,[{key:`addAtlasCollection`,value:function(e,t){this.atlasManager.addAtlasCollection(e,t)}},{key:`addTextureAtlasRenderType`,value:function(e,t){this.atlasManager.addRenderType(e,t)}},{key:`addSimpleShapeRenderType`,value:function(e,t){this.simpleShapeOptions.set(e,t)}},{key:`invalidate`,value:function(e){var t=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:{}).type,n=this.atlasManager;return t?n.invalidate(e,{filterType:function(e){return e===t},forceRedraw:!0}):n.invalidate(e)}},{key:`gc`,value:function(){this.atlasManager.gc()}},{key:`_createShaderProgram`,value:function(e){var t=this.gl,n=`#version 300 es + precision highp float; + + uniform mat3 uPanZoomMatrix; + uniform int uAtlasSize; + + // instanced + in vec2 aPosition; // a vertex from the unit square + + in mat3 aTransform; // used to transform verticies, eg into a bounding box + in int aVertType; // the type of thing we are rendering + + // the z-index that is output when using picking mode + in vec4 aIndex; + + // For textures + in int aAtlasId; // which shader unit/atlas to use + in vec4 aTex; // x/y/w/h of texture in atlas + + // for edges + in vec4 aPointAPointB; + in vec4 aPointCPointD; + in vec2 aLineWidth; // also used for node border width + + // simple shapes + in vec4 aCornerRadius; // for round-rectangle [top-right, bottom-right, top-left, bottom-left] + in vec4 aColor; // also used for edges + in vec4 aBorderColor; // aLineWidth is used for border width + + // output values passed to the fragment shader + out vec2 vTexCoord; + out vec4 vColor; + out vec2 vPosition; + // flat values are not interpolated + flat out int vAtlasId; + flat out int vVertType; + flat out vec2 vTopRight; + flat out vec2 vBotLeft; + flat out vec4 vCornerRadius; + flat out vec4 vBorderColor; + flat out vec2 vBorderWidth; + flat out vec4 vIndex; + + void main(void) { + int vid = gl_VertexID; + vec2 position = aPosition; // TODO make this a vec3, simplifies some code below + + if(aVertType == ${$m}) { + float texX = aTex.x; // texture coordinates + float texY = aTex.y; + float texW = aTex.z; + float texH = aTex.w; + + if(vid == 1 || vid == 2 || vid == 4) { + texX += texW; + } + if(vid == 2 || vid == 4 || vid == 5) { + texY += texH; + } + + float d = float(uAtlasSize); + vTexCoord = vec2(texX / d, texY / d); // tex coords must be between 0 and 1 + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + } + else if(aVertType == ${rh} || aVertType == ${oh} + || aVertType == ${ih} || aVertType == ${ah}) { // simple shapes + + // the bounding box is needed by the fragment shader + vBotLeft = (aTransform * vec3(0, 0, 1)).xy; // flat + vTopRight = (aTransform * vec3(1, 1, 1)).xy; // flat + vPosition = (aTransform * vec3(position, 1)).xy; // will be interpolated + + // calculations are done in the fragment shader, just pass these along + vColor = aColor; + vCornerRadius = aCornerRadius; + vBorderColor = aBorderColor; + vBorderWidth = aLineWidth; + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + } + else if(aVertType == ${eh}) { + vec2 source = aPointAPointB.xy; + vec2 target = aPointAPointB.zw; + + // adjust the geometry so that the line is centered on the edge + position.y = position.y - 0.5; + + // stretch the unit square into a long skinny rectangle + vec2 xBasis = target - source; + vec2 yBasis = normalize(vec2(-xBasis.y, xBasis.x)); + vec2 point = source + xBasis * position.x + yBasis * aLineWidth[0] * position.y; + + gl_Position = vec4(uPanZoomMatrix * vec3(point, 1.0), 1.0); + vColor = aColor; + } + else if(aVertType == ${th}) { + vec2 pointA = aPointAPointB.xy; + vec2 pointB = aPointAPointB.zw; + vec2 pointC = aPointCPointD.xy; + vec2 pointD = aPointCPointD.zw; + + // adjust the geometry so that the line is centered on the edge + position.y = position.y - 0.5; + + vec2 p0, p1, p2, pos; + if(position.x == 0.0) { // The left side of the unit square + p0 = pointA; + p1 = pointB; + p2 = pointC; + pos = position; + } else { // The right side of the unit square, use same approach but flip the geometry upside down + p0 = pointD; + p1 = pointC; + p2 = pointB; + pos = vec2(0.0, -position.y); + } + + vec2 p01 = p1 - p0; + vec2 p12 = p2 - p1; + vec2 p21 = p1 - p2; + + // Find the normal vector. + vec2 tangent = normalize(normalize(p12) + normalize(p01)); + vec2 normal = vec2(-tangent.y, tangent.x); + + // Find the vector perpendicular to p0 -> p1. + vec2 p01Norm = normalize(vec2(-p01.y, p01.x)); + + // Determine the bend direction. + float sigma = sign(dot(p01 + p21, normal)); + float width = aLineWidth[0]; + + if(sign(pos.y) == -sigma) { + // This is an intersecting vertex. Adjust the position so that there's no overlap. + vec2 point = 0.5 * width * normal * -sigma / dot(normal, p01Norm); + gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0); + } else { + // This is a non-intersecting vertex. Treat it like a mitre join. + vec2 point = 0.5 * width * normal * sigma * dot(normal, p01Norm); + gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0); + } + + vColor = aColor; + } + else if(aVertType == ${nh} && vid < 3) { + // massage the first triangle into an edge arrow + if(vid == 0) + position = vec2(-0.15, -0.3); + if(vid == 1) + position = vec2( 0.0, 0.0); + if(vid == 2) + position = vec2( 0.15, -0.3); + + gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0); + vColor = aColor; + } + else { + gl_Position = vec4(2.0, 0.0, 0.0, 1.0); // discard vertex by putting it outside webgl clip space + } + + vAtlasId = aAtlasId; + vVertType = aVertType; + vIndex = aIndex; + } + `,r=this.batchManager.getIndexArray(),i=gm(t,n,`#version 300 es + precision highp float; + + // declare texture unit for each texture atlas in the batch + ${r.map(function(e){return`uniform sampler2D uTexture${e};`}).join(` + `)} + + uniform vec4 uBGColor; + uniform float uZoom; + + in vec2 vTexCoord; + in vec4 vColor; + in vec2 vPosition; // model coordinates + + flat in int vAtlasId; + flat in vec4 vIndex; + flat in int vVertType; + flat in vec2 vTopRight; + flat in vec2 vBotLeft; + flat in vec4 vCornerRadius; + flat in vec4 vBorderColor; + flat in vec2 vBorderWidth; + + out vec4 outColor; + + ${qm} + ${Jm} + ${Ym} + ${Xm} + + vec4 blend(vec4 top, vec4 bot) { // blend colors with premultiplied alpha + return vec4( + top.rgb + (bot.rgb * (1.0 - top.a)), + top.a + (bot.a * (1.0 - top.a)) + ); + } + + vec4 distInterp(vec4 cA, vec4 cB, float d) { // interpolate color using Signed Distance + // scale to the zoom level so that borders don't look blurry when zoomed in + // note 1.5 is an aribitrary value chosen because it looks good + return mix(cA, cB, 1.0 - smoothstep(0.0, 1.5 / uZoom, abs(d))); + } + + void main(void) { + if(vVertType == ${$m}) { + // look up the texel from the texture unit + ${r.map(function(e){return`if(vAtlasId == ${e}) outColor = texture(uTexture${e}, vTexCoord);`}).join(` + else `)} + } + else if(vVertType == ${nh}) { + // mimics how canvas renderer uses context.globalCompositeOperation = 'destination-out'; + outColor = blend(vColor, uBGColor); + outColor.a = 1.0; // make opaque, masks out line under arrow + } + else if(vVertType == ${rh} && vBorderWidth == vec2(0.0)) { // simple rectangle with no border + outColor = vColor; // unit square is already transformed to the rectangle, nothing else needs to be done + } + else if(vVertType == ${rh} || vVertType == ${oh} + || vVertType == ${ih} || vVertType == ${ah}) { // use SDF + + float outerBorder = vBorderWidth[0]; + float innerBorder = vBorderWidth[1]; + float borderPadding = outerBorder * 2.0; + float w = vTopRight.x - vBotLeft.x - borderPadding; + float h = vTopRight.y - vBotLeft.y - borderPadding; + vec2 b = vec2(w/2.0, h/2.0); // half width, half height + vec2 p = vPosition - vec2(vTopRight.x - b[0] - outerBorder, vTopRight.y - b[1] - outerBorder); // translate to center + + float d; // signed distance + if(vVertType == ${rh}) { + d = rectangleSD(p, b); + } else if(vVertType == ${oh} && w == h) { + d = circleSD(p, b.x); // faster than ellipse + } else if(vVertType == ${oh}) { + d = ellipseSD(p, b); + } else { + d = roundRectangleSD(p, b, vCornerRadius.wzyx); + } + + // use the distance to interpolate a color to smooth the edges of the shape, doesn't need multisampling + // we must smooth colors inwards, because we can't change pixels outside the shape's bounding box + if(d > 0.0) { + if(d > outerBorder) { + discard; + } else { + outColor = distInterp(vBorderColor, vec4(0), d - outerBorder); + } + } else { + if(d > innerBorder) { + vec4 outerColor = outerBorder == 0.0 ? vec4(0) : vBorderColor; + vec4 innerBorderColor = blend(vBorderColor, vColor); + outColor = distInterp(innerBorderColor, outerColor, d); + } + else { + vec4 outerColor; + if(innerBorder == 0.0 && outerBorder == 0.0) { + outerColor = vec4(0); + } else if(innerBorder == 0.0) { + outerColor = vBorderColor; + } else { + outerColor = blend(vBorderColor, vColor); + } + outColor = distInterp(vColor, outerColor, d - innerBorder); + } + } + } + else { + outColor = vColor; + } + + ${e.picking?`if(outColor.a == 0.0) discard; + else outColor = vIndex;`:``} + } + `);i.aPosition=t.getAttribLocation(i,`aPosition`),i.aIndex=t.getAttribLocation(i,`aIndex`),i.aVertType=t.getAttribLocation(i,`aVertType`),i.aTransform=t.getAttribLocation(i,`aTransform`),i.aAtlasId=t.getAttribLocation(i,`aAtlasId`),i.aTex=t.getAttribLocation(i,`aTex`),i.aPointAPointB=t.getAttribLocation(i,`aPointAPointB`),i.aPointCPointD=t.getAttribLocation(i,`aPointCPointD`),i.aLineWidth=t.getAttribLocation(i,`aLineWidth`),i.aColor=t.getAttribLocation(i,`aColor`),i.aCornerRadius=t.getAttribLocation(i,`aCornerRadius`),i.aBorderColor=t.getAttribLocation(i,`aBorderColor`),i.uPanZoomMatrix=t.getUniformLocation(i,`uPanZoomMatrix`),i.uAtlasSize=t.getUniformLocation(i,`uAtlasSize`),i.uBGColor=t.getUniformLocation(i,`uBGColor`),i.uZoom=t.getUniformLocation(i,`uZoom`),i.uTextures=[];for(var a=0;a1&&arguments[1]!==void 0?arguments[1]:Zm.SCREEN;this.panZoomMatrix=e,this.renderTarget=t,this.batchDebugInfo=[],this.wrappedCount=0,this.simpleCount=0,this.startBatch()}},{key:`startBatch`,value:function(){this.instanceCount=0,this.batchManager.startBatch()}},{key:`endFrame`,value:function(){this.endBatch()}},{key:`_isVisible`,value:function(e,t){return e.visible()?t&&t.isVisible?t.isVisible(e):!0:!1}},{key:`drawTexture`,value:function(e,t,n){var r=this.atlasManager,i=this.batchManager,a=r.getRenderTypeOpts(n);if(this._isVisible(e,a)&&!(e.isEdge()&&!this._isValidEdge(e))){if(this.renderTarget.picking&&a.getTexPickingMode){var s=a.getTexPickingMode(e);if(s===Qm.IGNORE)return;if(s==Qm.USE_BB){this.drawPickingRectangle(e,t,n);return}}var c=o(r.getAtlasInfo(e,n)),l;try{for(c.s();!(l=c.n()).done;){var u=l.value,d=u.atlas,p=u.tex1,m=u.tex2;i.canAddToCurrentBatch(d)||this.endBatch();for(var h=i.getAtlasIndexForBatch(d),g=0,_=[[p,!0],[m,!1]];g<_.length;g++){var v=f(_[g],2),y=v[0],b=v[1];if(y.w!=0){var x=this.instanceCount;this.vertTypeBuffer.getView(x)[0]=$m,wm(t,this.indexBuffer.getView(x));var S=this.atlasIdBuffer.getView(x);S[0]=h;var C=this.texBuffer.getView(x);C[0]=y.x,C[1]=y.y,C[2]=y.w,C[3]=y.h;var w=this.transformBuffer.getMatrixView(x);this.setTransformMatrix(e,w,a,u,b),this.instanceCount++,b||this.wrappedCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}}catch(e){c.e(e)}finally{c.f()}}}},{key:`setTransformMatrix`,value:function(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=0;if(n.shapeProps&&n.shapeProps.padding&&(a=e.pstyle(n.shapeProps.padding).pfValue),r){var o=r.bb,s=r.tex1,c=r.tex2,l=s.w/(s.w+c.w);i||(l=1-l);var u=this._getAdjustedBB(o,a,i,l);this._applyTransformMatrix(t,u,n,e)}else{var d=n.getBoundingBox(e),f=this._getAdjustedBB(d,a,!0,1);this._applyTransformMatrix(t,f,n,e)}}},{key:`_applyTransformMatrix`,value:function(e,t,n,r){var i,a;Im(e);var o=n.getRotation?n.getRotation(r):0;if(o!==0){var s=n.getRotationPoint(r),c=s.x,l=s.y;Rm(e,e,[c,l]),zm(e,e,o);var u=n.getRotationOffset(r);i=u.x+(t.xOffset||0),a=u.y+(t.yOffset||0)}else i=t.x1,a=t.y1;Rm(e,e,[i,a]),Bm(e,e,[t.w,t.h])}},{key:`_getAdjustedBB`,value:function(e,t,n,r){var i=e.x1,a=e.y1,o=e.w,s=e.h,c=e.yOffset;t&&(i-=t,a-=t,o+=2*t,s+=2*t);var l=0,u=o*r;return n&&r<1?o=u:!n&&r<1&&(l=o-u,i+=l,o=u),{x1:i,y1:a,w:o,h:s,xOffset:l,yOffset:c}}},{key:`drawPickingRectangle`,value:function(e,t,n){var r=this.atlasManager.getRenderTypeOpts(n),i=this.instanceCount;this.vertTypeBuffer.getView(i)[0]=rh,wm(t,this.indexBuffer.getView(i)),Cm([0,0,0],1,this.colorBuffer.getView(i));var a=this.transformBuffer.getMatrixView(i);this.setTransformMatrix(e,a,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}},{key:`drawNode`,value:function(e,t,n){var r=this.simpleShapeOptions.get(n);if(this._isVisible(e,r)){var i=r.shapeProps,a=this._getVertTypeForShape(e,i.shape);if(a===void 0||r.isSimple&&!r.isSimple(e,this.renderTarget)){this.drawTexture(e,t,n);return}var o=this.instanceCount;if(this.vertTypeBuffer.getView(o)[0]=a,a===ih||a===ah){var s=r.getBoundingBox(e),c=this._getCornerRadius(e,i.radius,s),l=this.cornerRadiusBuffer.getView(o);l[0]=c,l[1]=c,l[2]=c,l[3]=c,a===ah&&(l[0]=0,l[2]=0)}wm(t,this.indexBuffer.getView(o));var u=this.renderTarget.picking?1:n===`node-body`?e.effectiveOpacity():1,d=this.renderTarget.picking?1:e.pstyle(i.opacity).value*u,f=e.pstyle(i.color).value;Cm(f,d,this.colorBuffer.getView(o));var p=this.lineWidthBuffer.getView(o);if(p[0]=0,p[1]=0,i.border){var m=e.pstyle(`border-width`).value;if(m>0){var h=e.pstyle(`border-color`).value;Cm(h,u*e.pstyle(`border-opacity`).value,this.borderColorBuffer.getView(o));var g=e.pstyle(`border-position`).value;if(g===`inside`)p[0]=0,p[1]=-m;else if(g===`outside`)p[0]=m,p[1]=0;else{var _=m/2;p[0]=_,p[1]=-_}}}var v=this.transformBuffer.getMatrixView(o);this.setTransformMatrix(e,v,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}},{key:`_getVertTypeForShape`,value:function(e,t){switch(e.pstyle(t).value){case`rectangle`:return rh;case`ellipse`:return oh;case`roundrectangle`:case`round-rectangle`:return ih;case`bottom-round-rectangle`:return ah;default:return}}},{key:`_getCornerRadius`,value:function(e,t,n){var r=n.w,i=n.h;if(e.pstyle(t).value===`auto`)return Nr(r,i);var a=e.pstyle(t).pfValue,o=r/2,s=i/2;return Math.min(a,s,o)}},{key:`drawEdgeArrow`,value:function(e,t,n){if(e.visible()){var r=e._private.rscratch,i,a,o;if(n===`source`?(i=r.arrowStartX,a=r.arrowStartY,o=r.srcArrowAngle):(i=r.arrowEndX,a=r.arrowEndY,o=r.tgtArrowAngle),!(isNaN(i)||i==null||isNaN(a)||a==null||isNaN(o)||o==null)&&e.pstyle(n+`-arrow-shape`).value!==`none`){var s=e.pstyle(n+`-arrow-color`).value,c=e.pstyle(`opacity`).value*e.pstyle(`line-opacity`).value,l=e.pstyle(`width`).pfValue,u=e.pstyle(`arrow-scale`).value,d=this.r.getArrowWidth(l,u),f=this.instanceCount,p=this.transformBuffer.getMatrixView(f);Im(p),Rm(p,p,[i,a]),Bm(p,p,[d,d]),zm(p,p,o),this.vertTypeBuffer.getView(f)[0]=nh,wm(t,this.indexBuffer.getView(f)),Cm(s,c,this.colorBuffer.getView(f)),this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}},{key:`drawEdgeLine`,value:function(e,t){if(e.visible()){var n=this._getEdgePoints(e);if(n){var r=e.pstyle(`opacity`).value,i=e.pstyle(`line-opacity`).value,a=e.pstyle(`width`).pfValue,o=e.pstyle(`line-color`).value,s=r*i;if(n.length/2+this.instanceCount>this.maxInstances&&this.endBatch(),n.length==4){var c=this.instanceCount;this.vertTypeBuffer.getView(c)[0]=eh,wm(t,this.indexBuffer.getView(c)),Cm(o,s,this.colorBuffer.getView(c));var l=this.lineWidthBuffer.getView(c);l[0]=a;var u=this.pointAPointBBuffer.getView(c);u[0]=n[0],u[1]=n[1],u[2]=n[2],u[3]=n[3],this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}else for(var d=0;d=this.maxInstances&&this.endBatch()}}}}},{key:`_isValidEdge`,value:function(e){var t=e._private.rscratch;return!(t.badLine||t.allpts==null||isNaN(t.allpts[0]))}},{key:`_getEdgePoints`,value:function(e){var t=e._private.rscratch;if(this._isValidEdge(e)){var n=t.allpts;if(n.length==4)return n;var r=this._getNumSegments(e);return this._getCurveSegmentPoints(n,r)}}},{key:`_getNumSegments`,value:function(e){return Math.min(15,this.maxInstances)}},{key:`_getCurveSegmentPoints`,value:function(e,t){if(e.length==4)return e;for(var n=Array((t+1)*2),r=0;r<=t;r++)if(r==0)n[0]=e[0],n[1]=e[1];else if(r==t)n[r*2]=e[e.length-2],n[r*2+1]=e[e.length-1];else{var i=r/t;this._setCurvePoint(e,i,n,r*2)}return n}},{key:`_setCurvePoint`,value:function(e,t,n,r){if(e.length<=2)n[r]=e[0],n[r+1]=e[1];else{for(var i=Array(e.length-2),a=0;a0}},s=function(e){return e.pstyle(`text-events`).strValue===`yes`?Qm.USE_BB:Qm.IGNORE},c=function(e){var t=e.position(),n=t.x,r=t.y,i=e.outerWidth(),a=e.outerHeight();return{w:i,h:a,x1:n-i/2,y1:r-a/2}};n.drawing.addAtlasCollection(`node`,{texRows:e.webglTexRowsNodes}),n.drawing.addAtlasCollection(`label`,{texRows:e.webglTexRows}),n.drawing.addTextureAtlasRenderType(`node-body`,{collection:`node`,getKey:t.getStyleKey,getBoundingBox:t.getElementBox,drawElement:t.drawElement}),n.drawing.addSimpleShapeRenderType(`node-body`,{getBoundingBox:c,isSimple:xm,shapeProps:{shape:`shape`,color:`background-color`,opacity:`background-opacity`,radius:`corner-radius`,border:!0}}),n.drawing.addSimpleShapeRenderType(`node-overlay`,{getBoundingBox:c,isVisible:o(`overlay`),shapeProps:{shape:`overlay-shape`,color:`overlay-color`,opacity:`overlay-opacity`,padding:`overlay-padding`,radius:`overlay-corner-radius`}}),n.drawing.addSimpleShapeRenderType(`node-underlay`,{getBoundingBox:c,isVisible:o(`underlay`),shapeProps:{shape:`underlay-shape`,color:`underlay-color`,opacity:`underlay-opacity`,padding:`underlay-padding`,radius:`underlay-corner-radius`}}),n.drawing.addTextureAtlasRenderType(`label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getLabelKey,null),getBoundingBox:fh(t.getLabelBox,null),drawClipped:!0,drawElement:t.drawLabel,getRotation:i(null),getRotationPoint:t.getLabelRotationPoint,getRotationOffset:t.getLabelRotationOffset,isVisible:a(`label`)}),n.drawing.addTextureAtlasRenderType(`edge-source-label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getSourceLabelKey,`source`),getBoundingBox:fh(t.getSourceLabelBox,`source`),drawClipped:!0,drawElement:t.drawSourceLabel,getRotation:i(`source`),getRotationPoint:t.getSourceLabelRotationPoint,getRotationOffset:t.getSourceLabelRotationOffset,isVisible:a(`source-label`)}),n.drawing.addTextureAtlasRenderType(`edge-target-label`,{collection:`label`,getTexPickingMode:s,getKey:dh(t.getTargetLabelKey,`target`),getBoundingBox:fh(t.getTargetLabelBox,`target`),drawClipped:!0,drawElement:t.drawTargetLabel,getRotation:i(`target`),getRotationPoint:t.getTargetLabelRotationPoint,getRotationOffset:t.getTargetLabelRotationOffset,isVisible:a(`target-label`)});var l=st(function(){console.log(`garbage collect flag set`),n.data.gc=!0},1e4);n.onUpdateEleCalcs(function(e,t){var r=!1;t&&t.length>0&&(r|=n.drawing.invalidate(t)),r&&l()}),ph(n)};function lh(e){var t=e.cy.container();return pe(t&&t.style&&t.style.backgroundColor||`white`)}function uh(e,t){var n=e._private.rscratch;return Xt(n,`labelWrapCachedLines`,t)||[]}var dh=function(e,t){return function(n){var r=e(n),i=uh(n,t);return i.length>1?i.map(function(e,t){return`${r}_${t}`}):r}},fh=function(e,t){return function(n,r){var i=e(n);if(typeof r==`string`){var a=r.indexOf(`_`);if(a>0){var o=Number(r.substring(a+1)),s=uh(n,t),c=i.h/s.length,l=c*o,u=i.y1+l;return{x1:i.x1,w:i.w,y1:u,h:c,yOffset:l}}}return i}};function ph(e){var t=e.render;e.render=function(n){n||={};var r=e.cy;e.webgl&&(r.zoom()>sp?(mh(e),t.call(e,n)):(hh(e),wh(e,n,Zm.SCREEN)))};var n=e.matchCanvasSize;e.matchCanvasSize=function(t){n.call(e,t),e.pickingFrameBuffer.setFramebufferAttachmentSizes(e.canvasWidth,e.canvasHeight),e.pickingFrameBuffer.needsDraw=!0},e.findNearestElements=function(t,n,r,i){return Sh(e,t,n)};var r=e.invalidateCachedZSortedEles;e.invalidateCachedZSortedEles=function(){r.call(e),e.pickingFrameBuffer.needsDraw=!0};var i=e.notify;e.notify=function(t,n){i.call(e,t,n),t===`viewport`||t===`bounds`?e.pickingFrameBuffer.needsDraw=!0:t===`background`&&e.drawing.invalidate(n,{type:`node-body`})}}function mh(e){var t=e.data.contexts[e.WEBGL];t.clear(t.COLOR_BUFFER_BIT|t.DEPTH_BUFFER_BIT)}function hh(e){var t=function(t){t.save(),t.setTransform(1,0,0,1,0,0),t.clearRect(0,0,e.canvasWidth,e.canvasHeight),t.restore()};t(e.data.contexts[e.NODE]),t(e.data.contexts[e.DRAG])}function gh(e){var t=e.canvasWidth,n=e.canvasHeight,r=vm(e),i=r.pan,a=r.zoom,o=Fm();Rm(o,o,[i.x,i.y]),Bm(o,o,[a,a]);var s=Fm();Vm(s,t,n);var c=Fm();return Lm(c,s,o),c}function _h(e,t){var n=e.canvasWidth,r=e.canvasHeight,i=vm(e),a=i.pan,o=i.zoom;t.setTransform(1,0,0,1,0,0),t.clearRect(0,0,n,r),t.translate(a.x,a.y),t.scale(o,o)}function vh(e,t){e.drawSelectionRectangle(t,function(t){return _h(e,t)})}function yh(e){var t=e.data.contexts[e.NODE];t.save(),_h(e,t),t.strokeStyle=`rgba(0, 0, 0, 0.3)`,t.beginPath(),t.moveTo(-1e3,0),t.lineTo(1e3,0),t.stroke(),t.beginPath(),t.moveTo(0,-1e3),t.lineTo(0,1e3),t.stroke(),t.restore()}function bh(e){var t=function(t,n,r){for(var i=t.atlasManager.getAtlasCollection(n),a=e.data.contexts[e.NODE],o=i.atlases,s=0;s=0&&b.add(S)}return b}function Sh(e,t,n){var r=xh(e,t,n),i=e.getCachedZSortedEles(),a,s,c=o(r),l;try{for(c.s();!(l=c.n()).done;){var u=i[l.value];if(!a&&u.isNode()&&(a=u),!s&&u.isEdge()&&(s=u),a&&s)break}}catch(e){c.e(e)}finally{c.f()}return[a,s].filter(Boolean)}function Ch(e,t,n){var r=e.drawing;t+=1,n.isNode()?(r.drawNode(n,t,`node-underlay`),r.drawNode(n,t,`node-body`),r.drawTexture(n,t,`label`),r.drawNode(n,t,`node-overlay`)):(r.drawEdgeLine(n,t),r.drawEdgeArrow(n,t,`source`),r.drawEdgeArrow(n,t,`target`),r.drawTexture(n,t,`label`),r.drawTexture(n,t,`edge-source-label`),r.drawTexture(n,t,`edge-target-label`))}function wh(e,t,n){var r;e.webglDebug&&(r=performance.now());var i=e.drawing,a=0;if(n.screen&&e.data.canvasNeedsRedraw[e.SELECT_BOX]&&vh(e,t),e.data.canvasNeedsRedraw[e.NODE]||n.picking){var s=e.data.contexts[e.WEBGL];n.screen?(s.clearColor(0,0,0,0),s.enable(s.BLEND),s.blendFunc(s.ONE,s.ONE_MINUS_SRC_ALPHA)):s.disable(s.BLEND),s.clear(s.COLOR_BUFFER_BIT|s.DEPTH_BUFFER_BIT),s.viewport(0,0,s.canvas.width,s.canvas.height);var c=gh(e),l=e.getCachedZSortedEles();if(a=l.length,i.startFrame(c,n),n.screen){for(var u=0;u0&&a>0){f.clearRect(0,0,i,a),f.globalCompositeOperation=`source-over`;var p=this.getCachedZSortedEles();if(e.full)f.translate(-n.x1*c,-n.y1*c),f.scale(c,c),this.drawElements(f,p),f.scale(1/c,1/c),f.translate(n.x1*c,n.y1*c);else{var m=t.pan(),h={x:m.x*c,y:m.y*c};c*=t.zoom(),f.translate(h.x,h.y),f.scale(c,c),this.drawElements(f,p),f.scale(1/c,1/c),f.translate(-h.x,-h.y)}e.bg&&(f.globalCompositeOperation=`destination-over`,f.fillStyle=e.bg,f.rect(0,0,i,a),f.fill())}return d};function Nh(e,t){for(var n=atob(e),r=new ArrayBuffer(n.length),i=new Uint8Array(r),a=0;a`u`?`undefined`:g(OffscreenCanvas))===`undefined`?(n=this.cy.window().document.createElement(`canvas`),n.width=e,n.height=t):n=new OffscreenCanvas(e,t),n},[Wp,Zp,im,om,sm,um,fm,ch,Th,Mh,Ih].forEach(function(e){X($,e)});var Bh=[{type:`layout`,extensions:Yd},{type:`renderer`,extensions:[{name:`null`,impl:Xd},{name:`base`,impl:Qf},{name:`canvas`,impl:Lh}]}],Vh={},Hh={};function Uh(e,t,n){var r=n,i=function(n){zt("Can not register `"+t+"` for `"+e+"` since `"+n+"` already exists in the prototype and can not be overridden")};if(e===`core`){if(sd.prototype[t])return i(t);sd.prototype[t]=n}else if(e===`collection`){if(xu.prototype[t])return i(t);xu.prototype[t]=n}else if(e===`layout`){for(var a=function(e){this.options=e,n.call(this,e),O(this._private)||(this._private={}),this._private.cy=e.cy,this._private.listeners=[],this.createEmitter()},o=a.prototype=Object.create(n.prototype),s=[],c=0;ct}function ft(e,t){return et||a&&o&&c&&!s&&!l||r&&o&&c||!n&&c||!i)return 1;if(!r&&!a&&!l&&e=s?c:c*(n[r]==`desc`?-1:1)}return e.index-t.index}function gt(e,t,n){t=t.length?x(t,function(e){return b(e)?function(t){return te(t,e.length===1?e[0]:e)}:e}):[ge];var r=-1;return t=x(t,h(de)),pt(Ce(e,function(e,n,i){return{criteria:x(t,function(t){return t(e)}),index:++r,value:e}}),function(e,t){return ht(e,t,n)})}var _t=ue(`length`),vt=`\\ud800-\\udfff`,yt=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,bt=`\\ufe0e\\ufe0f`,xt=`[`+vt+`]`,B=`[`+yt+`]`,V=`\\ud83c[\\udffb-\\udfff]`,St=`(?:`+B+`|`+V+`)`,Ct=`[^`+vt+`]`,wt=`(?:\\ud83c[\\udde6-\\uddff]){2}`,Tt=`[\\ud800-\\udbff][\\udc00-\\udfff]`,Et=`\\u200d`,Dt=St+`?`,Ot=`[`+bt+`]?`,kt=`(?:`+Et+`(?:`+[Ct,wt,Tt].join(`|`)+`)`+Ot+Dt+`)*`,At=Ot+Dt+kt,jt=`(?:`+[Ct+B+`?`,B,wt,Tt,xt].join(`|`)+`)`,Mt=RegExp(V+`(?=`+V+`)|`+jt+At,`g`);function Nt(e){for(var t=Mt.lastIndex=0;Mt.test(e);)++t;return t}function Pt(e){return $e(e)?Nt(e):_t(e)}function Ft(e,t){return Me(e,t,function(t,n){return ae(e,n)})}var H=We(function(e,t){return e==null?{}:Ft(e,t)}),It=Math.ceil,Lt=Math.max;function Rt(e,t,n,r){for(var i=-1,a=Lt(It((t-e)/(n||1)),0),o=Array(a);a--;)o[r?a:++i]=e,e+=n;return o}function zt(e){return function(t,n,r){return r&&typeof r!=`number`&&Pe(t,n,r)&&(n=r=void 0),t=Fe(t),n===void 0?(n=t,t=0):n=Fe(n),r=r===void 0?t1&&Pe(e,t[0],t[1])?t=[]:n>2&&Pe(t[0],t[1],t[2])&&(t=[t[0]]),gt(e,d(t,1),[])}),Ut=0;function G(e){var t=++Ut;return m(e)+t}function Wt(e,t,n){for(var r=-1,i=e.length,a=t.length,o={};++r0;--s)if(o=t[s].dequeue(),o){r=r.concat(K(e,t,n,o,!0));break}}}return r}function K(e,t,n,r,i){var a=i?[]:void 0;return y(e.inEdges(r.v),function(r){var o=e.edge(r),s=e.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,q(t,n,s)}),y(e.outEdges(r.v),function(r){var i=e.edge(r),a=r.w,o=e.node(a);o.in-=i,q(t,n,o)}),e.removeNode(r.v),a}function Qt(e,t){var n=new M,r=0,i=0;y(e.nodes(),function(e){n.setNode(e,{v:e,in:0,out:0})}),y(e.edges(),function(e){var a=n.edge(e.v,e.w)||0,o=t(e),s=a+o;n.setEdge(e.v,e.w,s),i=Math.max(i,n.node(e.v).out+=o),r=Math.max(r,n.node(e.w).in+=o)});var a=U(i+r+3).map(function(){return new Kt}),o=r+1;return y(n.nodes(),function(e){q(a,o,n.node(e))}),{graph:n,buckets:a,zeroIdx:o}}function q(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}function $t(e){var t=e.graph().acyclicer===`greedy`?Xt(e,n(e)):en(e);y(t,function(t){var n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,G(`rev`))});function n(e){return function(t){return e.edge(t).weight}}}function en(e){var t=[],n={},r={};function i(a){Object.prototype.hasOwnProperty.call(r,a)||(r[a]=!0,n[a]=!0,y(e.outEdges(a),function(e){Object.prototype.hasOwnProperty.call(n,e.w)?t.push(e):i(e.w)}),delete n[a])}return y(e.nodes(),i),t}function tn(e){y(e.edges(),function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}})}function J(e,t,n,r){var i;do i=G(r);while(e.hasNode(i));return n.dummy=t,e.setNode(i,n),i}function nn(e){var t=new M().setGraph(e.graph());return y(e.nodes(),function(n){t.setNode(n,e.node(n))}),y(e.edges(),function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},i=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})}),t}function rn(e){var t=new M({multigraph:e.isMultigraph()}).setGraph(e.graph());return y(e.nodes(),function(n){e.children(n).length||t.setNode(n,e.node(n))}),y(e.edges(),function(n){t.setEdge(n,e.edge(n))}),t}function an(e,t){var n=e.x,r=e.y,i=t.x-n,a=t.y-r,o=e.width/2,s=e.height/2;if(!i&&!a)throw Error(`Not possible to find intersection inside of the rectangle`);var c,l;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),c=s*i/a,l=s):(i<0&&(o=-o),c=o,l=o*a/i),{x:n+c,y:r+l}}function Y(e){var t=k(U(ln(e)+1),function(){return[]});return y(e.nodes(),function(n){var r=e.node(n),i=r.rank;w(i)||(t[i][r.order]=n)}),t}function on(e){var t=R(k(e.nodes(),function(t){return e.node(t).rank}));y(e.nodes(),function(n){var r=e.node(n);je(r,`rank`)&&(r.rank-=t)})}function sn(e){var t=R(k(e.nodes(),function(t){return e.node(t).rank})),n=[];y(e.nodes(),function(r){var i=e.node(r).rank-t;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=e.graph().nodeRankFactor;y(n,function(t,n){w(t)&&n%i!==0?--r:r&&y(t,function(t){e.node(t).rank+=r})})}function cn(e,t,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),J(e,`border`,i,t)}function ln(e){return I(k(e.nodes(),function(t){var n=e.node(t).rank;if(!w(n))return n}))}function un(e,t){var n={lhs:[],rhs:[]};return y(e,function(e){t(e)?n.lhs.push(e):n.rhs.push(e)}),n}function dn(e,t){var n=rt();try{return t()}finally{console.log(e+` time: `+(rt()-n)+`ms`)}}function fn(e,t){return t()}function pn(e){function t(n){var r=e.children(n),i=e.node(n);if(r.length&&y(r,t),Object.prototype.hasOwnProperty.call(i,`minRank`)){i.borderLeft=[],i.borderRight=[];for(var a=i.minRank,o=i.maxRank+1;ao.lim&&(s=o,c=!0),z(C(t.edges(),function(t){return c===Gn(e,e.node(t.v),s)&&c!==Gn(e,e.node(t.w),s)}),function(e){return X(t,e)})}function Hn(e,t,n,r){var i=n.v,a=n.w;e.removeEdge(i,a),e.setEdge(r.v,r.w,{}),$(e),In(e,t),Un(e,t)}function Un(e,t){var n=Fn(e,A(e.nodes(),function(e){return!t.node(e).parent}));n=n.slice(1),y(n,function(n){var r=e.node(n).parent,i=t.edge(n,r),a=!1;i||(i=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?i.minlen:-i.minlen)})}function Wn(e,t,n){return e.hasEdge(t,n)}function Gn(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}function Kn(e){switch(e.graph().ranker){case`network-simplex`:Yn(e);break;case`tight-tree`:Jn(e);break;case`longest-path`:qn(e);break;default:Yn(e)}}var qn=En;function Jn(e){En(e),Dn(e)}function Yn(e){Q(e)}function Xn(e){var t=J(e,`root`,{},`_root`),n=Qn(e),r=I(v(n))-1,i=2*r+1;e.graph().nestingRoot=t,y(e.edges(),function(t){e.edge(t).minlen*=i});var a=$n(e)+1;y(e.children(),function(o){Zn(e,t,i,a,r,n,o)}),e.graph().nodeRankFactor=i}function Zn(e,t,n,r,i,a,o){var s=e.children(o);if(!s.length){o!==t&&e.setEdge(t,o,{weight:0,minlen:n});return}var c=cn(e,`_bt`),l=cn(e,`_bb`),u=e.node(o);e.setParent(c,o),u.borderTop=c,e.setParent(l,o),u.borderBottom=l,y(s,function(s){Zn(e,t,n,r,i,a,s);var u=e.node(s),d=u.borderTop?u.borderTop:s,f=u.borderBottom?u.borderBottom:s,p=u.borderTop?r:2*r,m=d===f?i-a[o]+1:1;e.setEdge(c,d,{weight:p,minlen:m,nestingEdge:!0}),e.setEdge(f,l,{weight:p,minlen:m,nestingEdge:!0})}),e.parent(o)||e.setEdge(t,c,{weight:0,minlen:i+a[o]})}function Qn(e){var t={};function n(r,i){var a=e.children(r);a&&a.length&&y(a,function(e){n(e,i+1)}),t[r]=i}return y(e.children(),function(e){n(e,1)}),t}function $n(e){return S(e.edges(),function(t,n){return t+e.edge(n).weight},0)}function er(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,y(e.edges(),function(t){e.edge(t).nestingEdge&&e.removeEdge(t)})}function tr(e,t,n){var r={},i;y(n,function(n){for(var a=e.parent(n),o,s;a;){if(o=e.parent(a),o?(s=r[o],r[o]=a):(s=i,i=a),s&&s!==a){t.setEdge(s,a);return}a=o}})}function nr(e,t,n){var r=rr(e),i=new M({compound:!0}).setGraph({root:r}).setDefaultNodeLabel(function(t){return e.node(t)});return y(e.nodes(),function(a){var o=e.node(a),s=e.parent(a);(o.rank===t||o.minRank<=t&&t<=o.maxRank)&&(i.setNode(a),i.setParent(a,s||r),y(e[n](a),function(t){var n=t.v===a?t.w:t.v,r=i.edge(n,a),o=w(r)?0:r.weight;i.setEdge(n,a,{weight:e.edge(t).weight+o})}),Object.prototype.hasOwnProperty.call(o,`minRank`)&&i.setNode(a,{borderLeft:o.borderLeft[t],borderRight:o.borderRight[t]}))}),i}function rr(e){for(var t;e.hasNode(t=G(`_root`)););return t}function ir(e,t){for(var n=0,r=1;r0;)t%2&&(n+=s[t+1]),t=t-1>>1,s[t]+=e.weight;c+=e.weight*n})),c}function or(e){var t={},n=C(e.nodes(),function(t){return!e.children(t).length}),r=I(k(n,function(t){return e.node(t).rank})),i=k(U(r+1),function(){return[]});function a(n){je(t,n)||(t[n]=!0,i[e.node(n).rank].push(n),y(e.successors(n),a))}var o=W(n,function(t){return e.node(t).rank});return y(o,a),i}function sr(e,t){return k(t,function(t){var n=e.inEdges(t);if(n.length){var r=S(n,function(t,n){var r=e.edge(n),i=e.node(n.v);return{sum:t.sum+r.weight*i.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}})}function cr(e,t){var n={};return y(e,function(e,t){var r=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};w(e.barycenter)||(r.barycenter=e.barycenter,r.weight=e.weight)}),y(t.edges(),function(e){var t=n[e.v],r=n[e.w];!w(t)&&!w(r)&&(r.indegree++,t.out.push(n[e.w]))}),lr(C(n,function(e){return!e.indegree}))}function lr(e){var t=[];function n(e){return function(t){t.merged||(w(t.barycenter)||w(e.barycenter)||t.barycenter>=e.barycenter)&&ur(e,t)}}function r(t){return function(n){n.in.push(t),--n.indegree===0&&e.push(n)}}for(;e.length;){var i=e.pop();t.push(i),y(i.in.reverse(),n(i)),y(i.out,r(i))}return k(C(t,function(e){return!e.merged}),function(e){return H(e,[`vs`,`i`,`barycenter`,`weight`])})}function ur(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}function dr(e,t){var n=un(e,function(e){return Object.prototype.hasOwnProperty.call(e,`barycenter`)}),r=n.lhs,i=W(n.rhs,function(e){return-e.i}),a=[],o=0,s=0,c=0;r.sort(pr(!!t)),c=fr(a,i,c),y(r,function(e){c+=e.vs.length,a.push(e.vs),o+=e.barycenter*e.weight,s+=e.weight,c=fr(a,i,c)});var l={vs:O(a)};return s&&(l.barycenter=o/s,l.weight=s),l}function fr(e,t,n){for(var r;t.length&&(r=j(t)).i<=n;)t.pop(),e.push(r.vs),n++;return n}function pr(e){return function(t,n){return t.barycentern.barycenter?1:e?n.i-t.i:t.i-n.i}}function mr(e,t,n,r){var i=e.children(t),a=e.node(t),o=a?a.borderLeft:void 0,s=a?a.borderRight:void 0,c={};o&&(i=C(i,function(e){return e!==o&&e!==s}));var l=sr(e,i);y(l,function(t){if(e.children(t.v).length){var i=mr(e,t.v,n,r);c[t.v]=i,Object.prototype.hasOwnProperty.call(i,`barycenter`)&&gr(t,i)}});var u=cr(l,n);hr(u,c);var d=dr(u,r);if(o&&(d.vs=O([o,d.vs,s]),e.predecessors(o).length)){var f=e.node(e.predecessors(o)[0]),p=e.node(e.predecessors(s)[0]);Object.prototype.hasOwnProperty.call(d,`barycenter`)||(d.barycenter=0,d.weight=0),d.barycenter=(d.barycenter*d.weight+f.order+p.order)/(d.weight+2),d.weight+=2}return d}function hr(e,t){y(e,function(e){e.vs=O(e.vs.map(function(e){return t[e]?t[e].vs:e}))})}function gr(e,t){w(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}function _r(e){var t=ln(e),n=vr(e,U(1,t+1),`inEdges`),r=vr(e,U(t-1,-1,-1),`outEdges`),i=or(e);br(e,i);for(var a=1/0,o,s=0,c=0;c<4;++s,++c){yr(s%2?n:r,s%4>=2),i=Y(e);var l=ir(e,i);lo||s>t[c].lim));for(l=c,c=r;(c=e.parent(c))!==l;)a.push(c);return{path:i.concat(a.reverse()),lca:l}}function Cr(e){var t={},n=0;function r(i){var a=n;y(e.children(i),r),t[i]={low:a,lim:n++}}return y(e.children(),r),t}function wr(e,t){var n={};function r(t,r){var i=0,a=0,o=t.length,s=j(r);return y(r,function(t,c){var l=Er(e,t),u=l?e.node(l).order:o;(l||t===s)&&(y(r.slice(a,c+1),function(t){y(e.predecessors(t),function(r){var a=e.node(r),o=a.order;(oo)&&Dr(n,t,s)})})}function i(t,n){var i=-1,a,o=0;return y(n,function(s,c){if(e.node(s).dummy===`border`){var l=e.predecessors(s);l.length&&(a=e.node(l[0]).order,r(n,o,c,i,a),o=c,i=a)}r(n,o,n.length,a,t.length)}),n}return S(t,i),n}function Er(e,t){if(e.node(t).dummy)return A(e.predecessors(t),function(t){return e.node(t).dummy})}function Dr(e,t,n){if(t>n){var r=t;t=n,n=r}Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,configurable:!0,value:{},writable:!0});var i=e[t];Object.defineProperty(i,n,{enumerable:!0,configurable:!0,value:!0,writable:!0})}function Or(e,t,n){if(t>n){var r=t;t=n,n=r}return!!e[t]&&Object.prototype.hasOwnProperty.call(e[t],n)}function kr(e,t,n,r){var i={},a={},o={};return y(t,function(e){y(e,function(e,t){i[e]=e,a[e]=e,o[e]=t})}),y(t,function(e){var t=-1;y(e,function(e){var s=r(e);if(s.length){s=W(s,function(e){return o[e]});for(var c=(s.length-1)/2,l=Math.floor(c),u=Math.ceil(c);l<=u;++l){var d=s[l];a[e]===e&&t{var t=n(` buildLayoutGraph`,()=>Zr(e));n(` runLayout`,()=>Vr(t,n)),n(` updateInputGraph`,()=>Hr(e,t))})}function Vr(e,t){t(` makeSpaceForEdgeLabels`,()=>Qr(e)),t(` removeSelfEdges`,()=>si(e)),t(` acyclic`,()=>$t(e)),t(` nestingGraph.run`,()=>Xn(e)),t(` rank`,()=>Kn(rn(e))),t(` injectEdgeLabelProxies`,()=>$r(e)),t(` removeEmptyRanks`,()=>sn(e)),t(` nestingGraph.cleanup`,()=>er(e)),t(` normalizeRanks`,()=>on(e)),t(` assignRankMinMax`,()=>ei(e)),t(` removeEdgeLabelProxies`,()=>ti(e)),t(` normalize.run`,()=>Cn(e)),t(` parentDummyChains`,()=>xr(e)),t(` addBorderSegments`,()=>pn(e)),t(` order`,()=>_r(e)),t(` insertSelfEdges`,()=>ci(e)),t(` adjustCoordinateSystem`,()=>hn(e)),t(` position`,()=>Rr(e)),t(` positionSelfEdges`,()=>li(e)),t(` removeBorderNodes`,()=>oi(e)),t(` normalize.undo`,()=>Tn(e)),t(` fixupEdgeLabelCoords`,()=>ii(e)),t(` undoCoordinateSystem`,()=>gn(e)),t(` translateGraph`,()=>ni(e)),t(` assignNodeIntersects`,()=>ri(e)),t(` reversePoints`,()=>ai(e)),t(` acyclic.undo`,()=>tn(e))}function Hr(e,t){y(e.nodes(),function(n){var r=e.node(n),i=t.node(n);r&&(r.x=i.x,r.y=i.y,t.children(n).length&&(r.width=i.width,r.height=i.height))}),y(e.edges(),function(n){var r=e.edge(n),i=t.edge(n);r.points=i.points,Object.prototype.hasOwnProperty.call(i,`x`)&&(r.x=i.x,r.y=i.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}var Ur=[`nodesep`,`edgesep`,`ranksep`,`marginx`,`marginy`],Wr={ranksep:50,edgesep:20,nodesep:50,rankdir:`tb`},Gr=[`acyclicer`,`ranker`,`rankdir`,`align`],Kr=[`width`,`height`],qr={width:0,height:0},Jr=[`minlen`,`weight`,`width`,`height`,`labeloffset`],Yr={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:`r`},Xr=[`labelpos`];function Zr(e){var t=new M({multigraph:!0,compound:!0}),n=di(e.graph());return t.setGraph(L({},Wr,ui(n,Ur),H(n,Gr))),y(e.nodes(),function(n){var r=di(e.node(n));t.setNode(n,Te(ui(r,Kr),qr)),t.setParent(n,e.parent(n))}),y(e.edges(),function(n){var r=di(e.edge(n));t.setEdge(n,L({},Yr,ui(r,Jr),H(r,Xr)))}),t}function Qr(e){var t=e.graph();t.ranksep/=2,y(e.edges(),function(n){var r=e.edge(n);r.minlen*=2,r.labelpos.toLowerCase()!==`c`&&(t.rankdir===`TB`||t.rankdir===`BT`?r.width+=r.labeloffset:r.height+=r.labeloffset)})}function $r(e){y(e.edges(),function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v);J(e,`edge-proxy`,{rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t},`_ep`)}})}function ei(e){var t=0;y(e.nodes(),function(n){var r=e.node(n);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=I(t,r.maxRank))}),e.graph().maxRank=t}function ti(e){y(e.nodes(),function(t){var n=e.node(t);n.dummy===`edge-proxy`&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))})}function ni(e){var t=1/0,n=0,r=1/0,i=0,a=e.graph(),o=a.marginx||0,s=a.marginy||0;function c(e){var a=e.x,o=e.y,s=e.width,c=e.height;t=Math.min(t,a-s/2),n=Math.max(n,a+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}y(e.nodes(),function(t){c(e.node(t))}),y(e.edges(),function(t){var n=e.edge(t);Object.prototype.hasOwnProperty.call(n,`x`)&&c(n)}),t-=o,r-=s,y(e.nodes(),function(n){var i=e.node(n);i.x-=t,i.y-=r}),y(e.edges(),function(n){var i=e.edge(n);y(i.points,function(e){e.x-=t,e.y-=r}),Object.prototype.hasOwnProperty.call(i,`x`)&&(i.x-=t),Object.prototype.hasOwnProperty.call(i,`y`)&&(i.y-=r)}),a.width=n-t+o,a.height=i-r+s}function ri(e){y(e.edges(),function(t){var n=e.edge(t),r=e.node(t.v),i=e.node(t.w),a,o;n.points?(a=n.points[0],o=n.points[n.points.length-1]):(n.points=[],a=i,o=r),n.points.unshift(an(r,a)),n.points.push(an(i,o))})}function ii(e){y(e.edges(),function(t){var n=e.edge(t);if(Object.prototype.hasOwnProperty.call(n,`x`))switch((n.labelpos===`l`||n.labelpos===`r`)&&(n.width-=n.labeloffset),n.labelpos){case`l`:n.x-=n.width/2+n.labeloffset;break;case`r`:n.x+=n.width/2+n.labeloffset}})}function ai(e){y(e.edges(),function(t){var n=e.edge(t);n.reversed&&n.points.reverse()})}function oi(e){y(e.nodes(),function(t){if(e.children(t).length){var n=e.node(t),r=e.node(n.borderTop),i=e.node(n.borderBottom),a=e.node(j(n.borderLeft)),o=e.node(j(n.borderRight));n.width=Math.abs(o.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),y(e.nodes(),function(t){e.node(t).dummy===`border`&&e.removeNode(t)})}function si(e){y(e.edges(),function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||=[],n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}function ci(e){var t=Y(e);y(t,function(t){var n=0;y(t,function(t,r){var i=e.node(t);i.order=r+n,y(i.selfEdges,function(t){J(e,`selfedge`,{width:t.label.width,height:t.label.height,rank:i.rank,order:r+ ++n,e:t.e,label:t.label},`_se`)}),delete i.selfEdges})})}function li(e){y(e.nodes(),function(t){var n=e.node(t);if(n.dummy===`selfedge`){var r=e.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}})}function ui(e,t){return P(H(e,t),Number)}function di(e){var t={};return y(e,function(e,n){t[n.toLowerCase()]=e}),t}var fi=t((e,t,n)=>Math.max(t,Math.min(n,e)),`clamp`),pi=t((e=`TB`)=>{switch(e){case`BT`:return`bottom`;case`LR`:return`right`;case`RL`:return`left`;default:return`top`}},`getDefaultSelfLoopSide`),mi=t(e=>e===`flowchart`||e===`flowchart-v2`||e===`stateDiagram`||e===`er`||e===`classDiagram`,`shouldMergeSelfLoopSegments`),hi=[`x`,`y`,`width`,`height`,`labelBBox`,`intersect`,`calcIntersect`,`diff`,`clusterNode`],gi=t((e,t,n,r,i)=>{let a=[],o=new Set;if(n.forEach(({start:e,end:t})=>{e!==r&&o.add(e),t!==r&&o.add(t)}),o.forEach(t=>{let n=e.node(t);typeof n?.x==`number`&&typeof n?.y==`number`&&a.push(n)}),a.length===0&&n.forEach(({edge:e})=>{(e.points??[]).forEach(e=>{typeof e?.x==`number`&&typeof e?.y==`number`&&a.push(e)})}),a.length===0)return pi(i);let s=a.reduce((e,t)=>({x:e.x+t.x/a.length,y:e.y+t.y/a.length}),{x:0,y:0}),c=s.x-t.x,l=s.y-t.y;return Math.abs(c)>Math.abs(l)?c>0?`right`:`left`:Math.abs(l)>0?l>0?`bottom`:`top`:pi(i)},`getSelfLoopSide`),_i=t((e,t=`top`,n=0,r=0)=>{let i=e.x,a=e.y-n,o=e.width/2,s=e.height/2,c=Math.max(36,Math.min(100,e.width*.8)),l=fi(Math.max(r,e.width*.35),36,c),u=fi(Math.min(e.width,e.height)*.45,24,48);switch(t){case`bottom`:{let e=a+s;return[{x:i-l/2,y:e},{x:i-l/2,y:e+u},{x:i+l/2,y:e+u},{x:i+l/2,y:e}]}case`right`:{let e=i+o;return[{x:e,y:a-l/2},{x:e+u,y:a-l/2},{x:e+u,y:a+l/2},{x:e,y:a+l/2}]}case`left`:{let e=i-o;return[{x:e,y:a-l/2},{x:e-u,y:a-l/2},{x:e-u,y:a+l/2},{x:e,y:a+l/2}]}default:{let e=a-s;return[{x:i-l/2,y:e},{x:i-l/2,y:e-u},{x:i+l/2,y:e-u},{x:i+l/2,y:e}]}}},`getSelfLoopPoints`),vi=t((e,t,n=`top`,r=0,i={})=>{let a=e.x,o=e.y-r,s=i.width??0,c=i.height??0;switch(n){case`bottom`:return{x:a,y:Math.max(...t.map(e=>e.y))+c/2+4};case`right`:return{x:Math.max(...t.map(e=>e.x))+s/2+4,y:o};case`left`:return{x:Math.min(...t.map(e=>e.x))-s/2-4,y:o};default:return{x:a,y:Math.min(...t.map(e=>e.y))-c/2-4}}},`getSelfLoopLabelPosition`),yi=t((e,t=0,{mergeSelfLoops:n=!0}={})=>{let r=new Map,i=[],a=e.graph()?.rankdir;return e.edges().forEach(t=>{let a=e.edge(t);if(n&&a.selfLoop){let e=a.selfLoop.id;r.has(e)||r.set(e,[]),r.get(e).push({edge:a,start:t.v,end:t.w})}else i.push({edge:a,start:t.v,end:t.w})}),r.forEach(n=>{if(n.length!==3){n.forEach(e=>i.push(e));return}n.sort((e,t)=>e.edge.selfLoop.order-t.edge.selfLoop.order);let[r,o,s]=n,c=r.edge.originalEdge??o.edge.originalEdge??s.edge.originalEdge??o.edge,l=e.node(c.start);if(!l){n.forEach(e=>i.push(e));return}let u={width:o.edge.width,height:o.edge.height},d=gi(e,l,n,c.start,a),f=_i(l,d,t,u.width??0),p=vi(l,f,d,t,u),m={...o.edge,...c,id:c.id,points:f,start:c.start,end:c.end,x:p.x,y:p.y,width:u.width,height:u.height,labelStyle:o.edge.labelStyle,fromCluster:r.edge.fromCluster??o.edge.fromCluster??s.edge.fromCluster,toCluster:r.edge.toCluster??o.edge.toCluster??s.edge.toCluster};delete m.selfLoop,delete m.originalEdge,i.push({edge:m,start:m.start,end:m.end})}),i},`getEdgesToRender`),bi=t(async({element:n,graph:a,diagramType:s,id:c,parentCluster:l,siteConfig:d})=>{let f=a.graph().rankdir;e.trace(`Dir in recursive render - dir:`,f);let{clusters:p,edgePaths:m,edgeLabels:h,nodes:g,rootGroups:ee}=ze(n,{edgePathsClass:`edgePaths`});a.nodes()?e.info(`Recursive render XXX`,a.nodes()):e.info(`No nodes found for`,a),a.edges().length>0&&e.info(`Recursive edges`,a.edge(a.edges()[0]));let _=mi(s);await Promise.all(a.nodes().map(async function(t){let n=a.node(t);if(l!==void 0){let n=JSON.parse(JSON.stringify(l.clusterData));e.trace(`Setting data for parent cluster XXX + Node.id = `,t,` + data=`,n.height,` +Parent cluster`,l.height),a.setNode(l.id,n),a.parent(t)||(e.trace(`Setting parent`,t,l.id),a.setParent(t,l.id,n))}if(e.info(`(Insert) Node XXX`+t+`: `+JSON.stringify(a.node(t))),n?.clusterNode){e.info(`Cluster identified XBX`,t,n.width,a.node(t));let{ranksep:o,nodesep:l}=a.graph();n.graph.setGraph({...n.graph.graph(),ranksep:o+25,nodesep:l});let u=await Di({element:g,graph:n.graph,diagramType:s,id:c,parentCluster:a.node(t),siteConfig:d}),f=u.elem;r(n,f),n.diff=u.diff||0,e.info(`New compound node after recursive render XAX`,t,`width`,n.width,`height`,n.height),i(f,n)}else a.children(t).length>0?(e.trace(`Cluster - the non recursive path XBX`,t,n.id,n,n.width,`Graph:`,a),e.trace(Be(n.id,a)),N.set(n.id,{id:Be(n.id,a),node:n})):(e.trace(`Node - the non recursive path XAX`,t,g,a.node(t),f),await He(g,a.node(t),{config:d,dir:f}))})),await t(async()=>{let t=a.edges().map(async function(t){let n=a.edge(t.v,t.w,t.name);if(e.info(`Edge `+t.v+` -> `+t.w+`: `+JSON.stringify(t)),e.info(`Edge `+t.v+` -> `+t.w+`: `,t,` `,JSON.stringify(a.edge(t))),e.info(`Fix`,N,`ids:`,t.v,t.w,`Translating: `,N.get(t.v),N.get(t.w)),_&&n.selfLoop){if(n.selfLoop.order!==1)return;let e={...n.originalEdge,...n,id:n.selfLoop.id,startLabelLeft:n.originalEdge?.startLabelLeft??n.startLabelLeft,startLabelRight:n.originalEdge?.startLabelRight??n.startLabelRight,endLabelLeft:n.originalEdge?.endLabelLeft??n.endLabelLeft,endLabelRight:n.originalEdge?.endLabelRight??n.endLabelRight};await u(h,e),n.width=e.width,n.height=e.height,n.labelStyle=e.labelStyle;return}await u(h,n)});await Promise.all(t)},`processEdges`)();let{subGraphTitleTotalMargin:te}=o(d);return{elem:ee,graph:a,groups:{clusters:p,edgePaths:m,edgeLabels:h,nodes:g,rootGroups:ee},diagramType:s,id:c,mergeSelfLoops:_,subGraphTitleTotalMargin:te}},`measureDagreGraph`),xi=t(t=>{e.info(`############################################# XXX`),e.info(`### Layout ### XXX`),e.info(`############################################# XXX`),Br(t)},`runDagreGraphLayout`),Si=t((e,t,n)=>{let r=e.node(t);if(!r)return;let i={...r};return r?.clusterNode?i.y=(r.y??0)+n:e.children(t).length>0?i.height=(r.height??0)+n:i.y=(r.y??0)+n/2,i},`normalizeDagreNode`),Ci=t((e,t)=>{hi.forEach(n=>{t[n]!==void 0&&(e[n]=t[n])})},`applyDagreNodeLayout`),wi=t((e,t,n,r)=>({...e,start:e.start??t,end:e.end??n,points:(e.points??[]).map(e=>({...e,y:typeof e.y==`number`?e.y+r:e.y}))}),`normalizeDagreEdge`),Ti=t((e,t)=>{let{graph:n,mergeSelfLoops:r,subGraphTitleTotalMargin:i=0}=t,a=new Map(e.nodes.map(e=>[e.id,e]));Re(n).forEach(e=>{let t=Si(n,e,i);if(!t)return;Ci(n.node(e),t);let r=a.get(e);r&&Ci(r,t)});let o=i/2;return e.edges=yi(n,o,{mergeSelfLoops:r}).map(({edge:e,start:t,end:n})=>wi(e,t,n,o)),e},`applyDagreLayoutResult`),Ei=t(async({elem:t,graph:n,groups:{clusters:r,edgePaths:i},diagramType:o,id:u,mergeSelfLoops:d,subGraphTitleTotalMargin:f})=>{let p=0;await Promise.all(Re(n).map(async function(t){let i=n.node(t);if(e.info(`Position XBX => `+t+`: (`+i.x,`,`+i.y,`) width: `,i.width,` height: `,i.height),i?.clusterNode)i.y+=f,e.info(`A tainted cluster node XBX1`,t,i.id,i.width,i.height,i.x,i.y,n.parent(t)),N.get(i.id).node=i,a(i);else if(n.children(t).length>0){e.info(`A pure cluster node XBX1`,t,i.id,i.x,i.y,i.width,i.height,n.parent(t)),i.height+=f,n.node(i.parentId);let a=i?.padding/2||0,o=i?.labelBBox?.height||0,s=o-a||0;e.debug(`OffsetY`,s,`labelHeight`,o,`halfPadding`,a),await c(r,i),N.get(i.id).node=i}else{let t=n.node(i.parentId);i.y+=f/2,e.info(`A regular node XBX1 - using the padding`,i.id,`parent`,i.parentId,i.width,i.height,i.x,i.y,`offsetY`,i.offsetY,`parent`,t,t?.offsetY,i),a(i)}}));let m=f/2;return yi(n,m,{mergeSelfLoops:d}).forEach(function({edge:t,start:r,end:a}){e.info(`Edge `+r+` -> `+a+`: `+JSON.stringify(t),t),t.points.forEach(e=>e.y+=m);let c=n.node(r),d=n.node(a),f=l(i,t,N,o,c,d,u);s(t,f)}),n.nodes().forEach(function(t){let r=n.node(t);e.info(t,r.type,r.diff),r.isGroup&&(p=r.diff)}),e.warn(`Returning from recursive render XAX`,t,p),{elem:t,diff:p}},`paintDagreLayoutCore`),Di=t(async e=>{let t=await bi(e);return xi(t.graph),await Ei(t)},`renderDagreSubgraph`),Oi=t(t=>{let n=new M({multigraph:!0,compound:!0}).setGraph({rankdir:t.direction,nodesep:t.config?.nodeSpacing||t.nodeSpacing||t.config?.flowchart?.nodeSpacing,ranksep:t.config?.rankSpacing||t.rankSpacing||t.config?.flowchart?.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});return t.nodes.forEach(e=>{n.setNode(e.id,{...e}),e.parentId&&n.setParent(e.id,e.parentId)}),e.debug(`Edges:`,t.edges),t.edges.forEach(e=>{if(e.start===e.end){let t=e.start,r=t+`---`+t+`---1`,i=t+`---`+t+`---2`,a=n.node(t);n.setNode(r,{domId:r,id:r,parentId:a.parentId,labelStyle:``,label:``,padding:0,shape:`labelRect`,style:``,width:10,height:10}),n.setParent(r,a.parentId),n.setNode(i,{domId:i,id:i,parentId:a.parentId,labelStyle:``,padding:0,shape:`labelRect`,label:``,style:``,width:10,height:10}),n.setParent(i,a.parentId);let o=structuredClone(e),s=structuredClone(e),c=structuredClone(e),l=structuredClone(e);s.originalEdge=o,s.selfLoop={id:o.id,order:0},c.originalEdge=o,c.selfLoop={id:o.id,order:1},l.originalEdge=o,l.selfLoop={id:o.id,order:2},s.label=``,s.arrowTypeEnd=`none`,s.endLabelLeft=``,s.endLabelRight=``,s.startLabelLeft=``,s.id=t+`-cyclic-special-1`,c.startLabelRight=``,c.startLabelLeft=``,c.endLabelLeft=``,c.endLabelRight=``,c.arrowTypeStart=`none`,c.arrowTypeEnd=`none`,c.id=t+`-cyclic-special-mid`,l.label=``,l.startLabelRight=``,l.startLabelLeft=``,l.arrowTypeStart=`none`,a.isGroup&&(s.fromCluster=t,l.toCluster=t),l.id=t+`-cyclic-special-2`,l.arrowTypeStart=`none`,n.setEdge(t,r,s,t+`-cyclic-special-0`),n.setEdge(r,i,c,t+`-cyclic-special-1`),n.setEdge(i,t,l,t+`-cyclic-special-2`)}else n.setEdge(e.start,e.end,{...e},e.id)}),Ue(n),{graph:n}},`prepareLayoutForDagre`),ki=t(async(e,{element:t,preparedLayout:r})=>{let i=r??Oi(e),a=n(),o=await bi({element:t,graph:i.graph,diagramType:e.type,id:e.diagramId,parentCluster:void 0,siteConfig:a});return i.measuredLayout=o,o},`measureDagreLayout`),Ai=t((e,t)=>{let n=t.preparedLayout?.measuredLayout;if(!n)throw Error(`runDagreLayoutCore requires measureDagreLayout to run first`);return xi(n.graph),Ti(e,n),n},`runDagreLayoutCore`),ji=Ve({prepareLayout:Oi,measureLayout:ki,runLayoutCore:Ai,paintOptions:{clusterDb:N,getNodes:t((e,{measure:t})=>Re(t.graph).map(e=>t.graph.node(e)).filter(Boolean),`getDagrePaintNodes`),getEdgeNode:t((e,t,{measure:n})=>e?n.graph.node(e):void 0,`getDagreEdgeNode`),skipNode:t((e,{measure:t})=>!t.graph.hasNode(e.id),`skipNode`),isCluster:t((e,{measure:t})=>t.graph.hasNode(e.id)&&(t.graph.children(e.id)??[]).length>0,`isCluster`)}});export{Ti as applyDagreLayoutResult,yi as getEdgesToRender,ki as measureDagreLayout,Oi as prepareLayoutForDagre,ji as render,Ai as runDagreLayoutCore}; \ No newline at end of file diff --git a/www/assets/defaultLocale-BFoDCU3G.js b/www/assets/defaultLocale-BFoDCU3G.js new file mode 100644 index 0000000..3304660 --- /dev/null +++ b/www/assets/defaultLocale-BFoDCU3G.js @@ -0,0 +1 @@ +function e(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString(`en`).replace(/,/g,``):e.toString(10)}function t(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf(`e`),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function n(e){return e=t(Math.abs(e)),e?e[1]:NaN}function r(e,t){return function(n,r){for(var i=n.length,a=[],o=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),a.push(n.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function i(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}var a=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function o(e){if(!(t=a.exec(e)))throw Error(`invalid format: `+e);var t;return new s({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}o.prototype=s.prototype;function s(e){this.fill=e.fill===void 0?` `:e.fill+``,this.align=e.align===void 0?`>`:e.align+``,this.sign=e.sign===void 0?`-`:e.sign+``,this.symbol=e.symbol===void 0?``:e.symbol+``,this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?``:e.type+``}s.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?`0`:``)+(this.width===void 0?``:Math.max(1,this.width|0))+(this.comma?`,`:``)+(this.precision===void 0?``:`.`+Math.max(0,this.precision|0))+(this.trim?`~`:``)+this.type};function c(e){out:for(var t=e.length,n=1,r=-1,i;n0&&(r=0)}return r>0?e.slice(0,r)+e.slice(i+1):e}var l;function u(e,n){var r=t(e,n);if(!r)return l=void 0,e.toPrecision(n);var i=r[0],a=r[1],o=a-(l=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,s=i.length;return o===s?i:o>s?i+Array(o-s+1).join(`0`):o>0?i.slice(0,o)+`.`+i.slice(o):`0.`+Array(1-o).join(`0`)+t(e,Math.max(0,n+o-1))[0]}function d(e,n){var r=t(e,n);if(!r)return e+``;var i=r[0],a=r[1];return a<0?`0.`+Array(-a).join(`0`)+i:i.length>a+1?i.slice(0,a+1)+`.`+i.slice(a+1):i+Array(a-i.length+2).join(`0`)}var f={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+``,d:e,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>d(e*100,t),r:d,s:u,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function p(e){return e}var m=Array.prototype.map,h=[`y`,`z`,`a`,`f`,`p`,`n`,`µ`,`m`,``,`k`,`M`,`G`,`T`,`P`,`E`,`Z`,`Y`];function g(e){var t=e.grouping===void 0||e.thousands===void 0?p:r(m.call(e.grouping,Number),e.thousands+``),a=e.currency===void 0?``:e.currency[0]+``,s=e.currency===void 0?``:e.currency[1]+``,u=e.decimal===void 0?`.`:e.decimal+``,d=e.numerals===void 0?p:i(m.call(e.numerals,String)),g=e.percent===void 0?`%`:e.percent+``,_=e.minus===void 0?`−`:e.minus+``,v=e.nan===void 0?`NaN`:e.nan+``;function y(e,n){e=o(e);var r=e.fill,i=e.align,p=e.sign,m=e.symbol,y=e.zero,b=e.width,x=e.comma,S=e.precision,C=e.trim,w=e.type;w===`n`?(x=!0,w=`g`):f[w]||(S===void 0&&(S=12),C=!0,w=`g`),(y||r===`0`&&i===`=`)&&(y=!0,r=`0`,i=`=`);var T=(n&&n.prefix!==void 0?n.prefix:``)+(m===`$`?a:m===`#`&&/[boxX]/.test(w)?`0`+w.toLowerCase():``),E=(m===`$`?s:/[%p]/.test(w)?g:``)+(n&&n.suffix!==void 0?n.suffix:``),D=f[w],O=/[defgprs%]/.test(w);S=S===void 0?6:/[gprs]/.test(w)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S));function k(e){var n=T,a=E,o,s,f;if(w===`c`)a=D(e)+a,e=``;else{e=+e;var m=e<0||1/e<0;if(e=isNaN(e)?v:D(Math.abs(e),S),C&&(e=c(e)),m&&+e==0&&p!==`+`&&(m=!1),n=(m?p===`(`?p:_:p===`-`||p===`(`?``:p)+n,a=(w===`s`&&!isNaN(e)&&l!==void 0?h[8+l/3]:``)+a+(m&&p===`(`?`)`:``),O){for(o=-1,s=e.length;++of||f>57){a=(f===46?u+e.slice(o+1):e.slice(o))+a,e=e.slice(0,o);break}}}x&&!y&&(e=t(e,1/0));var g=n.length+e.length+a.length,k=g>1)+n+e+a+k.slice(g);break;default:e=k+n+e+a}return d(e)}return k.toString=function(){return e+``},k}function b(e,t){var r=Math.max(-8,Math.min(8,Math.floor(n(t)/3)))*3,i=10**-r,a=y((e=o(e),e.type=`f`,e),{suffix:h[8+r/3]});return function(e){return a(i*e)}}return{format:y,formatPrefix:b}}var _,v,y;b({thousands:`,`,grouping:[3],currency:[`$`,``]});function b(e){return _=g(e),v=_.format,y=_.formatPrefix,_}export{n as i,y as n,o as r,v as t}; \ No newline at end of file diff --git a/www/assets/diagram-22UHCM2B-B4G_FQZz.js b/www/assets/diagram-22UHCM2B-B4G_FQZz.js new file mode 100644 index 0000000..2afccde --- /dev/null +++ b/www/assets/diagram-22UHCM2B-B4G_FQZz.js @@ -0,0 +1,200 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as r,H as i,U as a,a as o,d as s,ot as c,q as l,s as u,tt as d,v as f,w as p,x as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as g}from"./channel-_oCHZhRo.js";import{c as _,g as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{i as y,n as b,o as x,r as S}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{a as C}from"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{_ as w,n as T,t as E,v as D}from"./index-DoQkmpth.js";import{t as O}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{t as k}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as A}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as j}from"./chunk-WEXAMYUT-I3m-hOmT.js";var M={SHAPE_UNSUPPORTED:`SHAPE_UNSUPPORTED`,SHAPE_REMOVED:`SHAPE_REMOVED`,EDGE_OPERATOR_UNSUPPORTED:`EDGE_OPERATOR_UNSUPPORTED`,REFERENCE_EDGE_LABEL_REJECTED:`REFERENCE_EDGE_LABEL_REJECTED`,CONNECTOR_REF_UNRESOLVED:`CONNECTOR_REF_UNRESOLVED`,CONNECTOR_REF_NOT_A_CONNECTOR:`CONNECTOR_REF_NOT_A_CONNECTOR`,METADATA_KEY_MISAPPLIED:`METADATA_KEY_MISAPPLIED`,DUPLICATE_ID_NODE:`DUPLICATE_ID_NODE`,RESERVED_SYNTHETIC_ID:`RESERVED_SYNTHETIC_ID`,CONTAINMENT_VIOLATION:`CONTAINMENT_VIOLATION`,EDGE_SEMANTIC_CONTRADICTION:`EDGE_SEMANTIC_CONTRADICTION`,FLOW_NO_INPUT:`FLOW_NO_INPUT`},N=new Set([M.SHAPE_UNSUPPORTED,M.SHAPE_REMOVED,M.CONTAINMENT_VIOLATION]);new Set(Object.values(M).filter(e=>!N.has(e)));var P=new Map([[`task`,`roundedRect`],[`tool`,`subroutine`],[`input`,`lean-right`],[`decision`,`diamond`],[`refdoc`,`lin-doc`],[`action`,`hexagon`],[`round`,`rect`]]),ee=new Set(`doc.stadium.terminal.circle.trapezoid.inv_trapezoid.inv-trapezoid.doublecircle.double-circle.typeDeclaration.procs.lean_left.lean-left.in-out.cylinder.ellipse.odd.tag-rect.tagged-rectangle.delay.half-rounded-rectangle.lin-rect.lined-rectangle.win-pane.window-pane.curv-trap.curved-trapezoid`.split(`.`)),te=new Set([`roundedRect`,`subroutine`,`subprocess`,`subproc`,`framed-rectangle`,`lean-right`,`diamond`,`lin-doc`,`lined-document`,`hexagon`,`hex`,`connector`,`collapsedGroup`]),F=`roundedRect`;function I(e){return e&&(P.get(e)??e)}n(I,`resolveShapeAlias`);function ne(t,n){for(let r of t)if(!r.isGroup){if((!r.shape||r.shape===`squareRect`||r.shape===`rect`)&&(r.shape=F),ee.has(r.shape)){let t=`shape "${r.shape}" was removed in v0.8.1, using "${F}"`;n?.emitError?n.emitError(`SHAPE_REMOVED`,t,{nodeId:r.id}):e.warn(`agentflow: ${t}`),r.shape=F;continue}if(!te.has(r.shape)){let t=`shape "${r.shape}" is not supported, using "${F}"`;n?.emitWarning?n.emitWarning(`SHAPE_UNSUPPORTED`,t,{nodeId:r.id}):e.warn(`agentflow: ${t}`),r.shape=F}}}n(ne,`normaliseNodeShapes`);var L=new Map([[`tool`,0],[`task`,1],[`decision`,2],[`input`,3],[`refdoc`,4],[`connector`,5],[`action`,6]]),R=L.size,z=n(e=>`af-kind-${e}`,`kindClass`),B=[...L.keys()],V=n(e=>Math.max(1,e-R),`containerSlotCount`),H=n((e,t)=>{let n=R+e%V(t);return t>0?n%t:n},`containerSlot`);function re(e,t,n){let r=m().themeVariables?.borderColorArray,i=Array.isArray(r)?r.length:0,a=n.size;for(let r of e??[]){if(r.isGroup||r.shape===`collapsedGroup`){r.colorIndex=H(n.get(String(r.id))??a++,i);continue}let e=t(String(r.id));e&&L.has(e)&&(r.cssClasses=`${r.cssClasses??``} ${z(e)}`.replace(/\s+/g,` `).trim())}}n(re,`assignColorSlots`);var ie=`agentflow-`,ae=new Set([`shape`,`view`,`icon`,`img`,`form`,`pos`,`w`,`h`,`class`,`style`,`labelType`]),oe=new Set([`subroutine`,`subprocess`,`subproc`,`framed-rectangle`,`tool`]),se={flow:`flowGroup`};function ce(e){if(Array.isArray(e))return e.map(e=>ce(e));if(typeof e!=`object`||!e)return e;let t={};for(let n of Object.keys(e))n!==`__proto__`&&n!==`constructor`&&n!==`prototype`&&(t[n]=ce(e[n]));return t}n(ce,`stripPrototypeKeys`);function le(e){let t=!1,n=!1,r=0,i,a=[];for(let o of e.split(` +`)){if(i!==void 0){let e=o.length-o.trimStart().length;if(o.trim()===``||e>i){a.push(o);continue}i=void 0}let e=-1;for(let i=0;i0){a.push(o);continue}let s=e>=0?o.slice(0,e):o,c=e>=0?o.slice(e):``;if(/:\s*[>|][\d+-]*\s*$/.test(s)){i=o.length-o.trimStart().length,a.push(o);continue}a.push(s.replace(/,([\t ]*)$/,`$1`)+c)}return a.join(` +`)}n(le,`stripLineTrailingCommas`);var ue=class{constructor(){this.vertexCounter=0,this.config=m(),this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.diagramId=``,this.preserveCommentsWhenParsing=!0,this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,this.funs=[],this.setAccTitle=a,this.setAccDescription=i,this.setDiagramTitle=l,this.getAccTitle=h,this.getAccDescription=f,this.getDiagramTitle=p,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addGlobal=this.addGlobal.bind(this),this.addConnector=this.addConnector.bind(this),this.addConnectorMapping=this.addConnectorMapping.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.setFrontmatterLineOffset=this.setFrontmatterLineOffset.bind(this),this.addVertexMapping=this.addVertexMapping.bind(this),this.extendVertexMapping=this.extendVertexMapping.bind(this),this.addEdgeMapping=this.addEdgeMapping.bind(this),this.addSubgraphMapping=this.addSubgraphMapping.bind(this),this.emitWarning=this.emitWarning.bind(this),this.emitError=this.emitError.bind(this),this.getDiagnostics=this.getDiagnostics.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen(`gen-2`)}static{n(this,`AgentFlowDB`)}sanitizeText(e){return u.sanitizeText(e,this.config)}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}setDiagramId(e){this.diagramId=e}lookUpDomId(e){for(let t of this.vertices.values())if(t.id===e)return this.diagramId?`${this.diagramId}-${t.domId}`:t.domId;return this.diagramId?`${this.diagramId}-${e}`:e}addVertex(e,t,n,r,i,a,o={},s,c){if(!e||e.trim().length===0)return;let l;if(s!==void 0){let e;e=s.includes(` +`)?s+` +`:`{ +`+s+` +}`;try{l=D(e,{schema:w})??{}}catch(e){let t=s.includes(` +`)?le(s):s;if(t!==s)try{l=D(t+` +`,{schema:w})??{}}catch{this.rethrowMetadataYamlError(e,s,c)}else this.rethrowMetadataYamlError(e,s,c)}l=ce(l)}let u;if(l&&typeof l.shape==`string`){let e=l;u=e.shape;let t=I(u);t&&t!==u&&(e.shape=t)}let d=this.subGraphLookup.get(e);if(d&&l){d.metadata={...d.metadata,...l};return}let f=this.connectors.get(e);if(f&&l){f.metadata={...f.metadata,...l};return}if(e===`connectors`)return;let p=this.edges.find(t=>t.id===e);if(p){let e=l;e?.animate!==void 0&&(p.animate=e.animate),e?.animation!==void 0&&(p.animation=e.animation),e?.curve!==void 0&&(p.interpolate=e.curve),l&&(p.metadata={...p.metadata,...l});return}let h,g=this.vertices.get(e);if(g===void 0&&(g={id:e,labelType:`text`,domId:ie+e+`-`+this.vertexCounter,styles:[],classes:[]},this.vertices.set(e,g)),this.vertexCounter++,t===void 0?g.text===void 0&&(g.text=e):(this.config=m(),h=this.sanitizeText(t.text.trim()),g.labelType=t.type,h.startsWith(`"`)&&h.endsWith(`"`)&&(h=h.substring(1,h.length-1)),g.text=h),n!==void 0&&(g.type=n),r?.forEach(e=>{g.styles.push(e)}),i?.forEach(e=>{g.classes.push(e)}),a!==void 0&&(g.dir=a),g.props===void 0?g.props=o:o!==void 0&&Object.assign(g.props,o),l){if(g.metadata={...g.metadata,...l},l.shape){let e=u??l.shape;if(typeof e!=`string`)throw this.positionedShapeError(`No such shape: ${JSON.stringify(e)}.`,c);if(e!==e.toLowerCase()||e.includes(`_`))throw this.positionedShapeError(`No such shape: ${e}. Shape names should be lowercase.`,c);if(!C(l.shape))throw this.positionedShapeError(`No such shape: ${l.shape}.`,c);g.type=l?.shape}l?.label&&(g.text=this.sanitizeText(l.label),g.labelType=this.sanitizeNodeLabelType(l?.labelType))}}positionedShapeError(e,t){let n=Error(e);if(!t)return n;let r=t.first_line+this.frontmatterLineOffset;return Object.assign(n,{hash:{text:``,token:null,line:r-1,loc:{first_line:r,last_line:t.last_line+this.frontmatterLineOffset,first_column:t.first_column,last_column:t.last_column},expected:[]}}),n}rethrowMetadataYamlError(e,t,r){let i=e;if(!i||i.name!==`YAMLException`||!i.mark||!r)throw e;let a;try{let e=!t.includes(` +`),o=e?`{ +`+t+` +}`:t+` +`,s=r.first_line+this.frontmatterLineOffset,c=r.first_column+2,l=n((t,n)=>e?{line:s,column:c+(t===1?n:0)}:{line:s+t,column:t===0?c+n:n},`toSource`),u=l(i.mark.line,i.mark.column),d=i.reason??(i.message??``).split(` +`)[0].replace(/\s*\(\d+:\d+\)\s*$/,``),f=o.split(` +`),p=[];if(e)p.push(1);else for(let e=i.mark.line-1;e<=i.mark.line+1;e++)e<0||e>=f.length||(e!==f.length-1||f[e]!==``||e===i.mark.line)&&p.push(e);let m=Math.max(...p.map(e=>String(l(e,0).line).length)),h=[];for(let e of p){let t=l(e,0).line,n=` ${String(t).padStart(m)} | `;h.push(n+f[e].replace(/\t/g,`→`)),e===i.mark.line&&h.push(`-`.repeat(n.length+i.mark.column)+`^`)}a={message:`${d} (${u.line}:${u.column+1}) + +${h.join(` +`)}`,markLine:u.line-1,markColumn:u.column,hash:{text:``,token:null,line:u.line-1,loc:{first_line:u.line,last_line:u.line,first_column:u.column,last_column:u.column+1},expected:[]}}}catch{}throw a&&(i.message=a.message,i.mark.line=a.markLine,i.mark.column=a.markColumn,i.hash=a.hash),i}addSingleLink(t,n,r,i){let a={start:t,end:n,type:void 0,text:``,labelType:`text`,classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};e.info(`abc78 Got edge...`,a);let o=r.text;if(o!==void 0&&(a.text=this.sanitizeText(o.text.trim()),a.text.startsWith(`"`)&&a.text.endsWith(`"`)&&(a.text=a.text.substring(1,a.text.length-1)),a.labelType=this.sanitizeNodeLabelType(o.type)),r!==void 0&&(a.type=r.type,a.stroke=r.stroke,a.length=r.length>10?10:r.length,r.edgeSemantic&&(a.edgeSemantic=r.edgeSemantic)),i&&!this.edges.some(e=>e.id===i))a.id=i,a.isUserDefinedId=!0;else{let e=this.edges.filter(e=>e.start===a.start&&e.end===a.end);a.id=e.length===0?_(a.start,a.end,{counter:0,prefix:`L`}):_(a.start,a.end,{counter:e.length+1,prefix:`L`})}if(this.edges.length<(this.config.maxEdges??500))e.info(`Pushing edge...`),this.edges.push(a);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}. + +Initialize mermaid with maxEdges set to a higher number to allow more edges. +You cannot set this config via configuration inside the diagram as it is a secure config. +You have to call mermaid.initialize.`)}isLinkData(e){return typeof e==`object`&&!!e&&`id`in e&&typeof e.id==`string`}addLink(t,n,r){let i=this.isLinkData(r)?r.id.replace(`@`,``):void 0;e.info(`addLink`,t,n,i);for(let e of t)for(let a of n){let o=e===t[t.length-1],s=a===n[0];o&&s?this.addSingleLink(e,a,r,i):this.addSingleLink(e,a,r,void 0)}}updateLinkInterpolate(e,t){e.forEach(e=>{if(e==="default"){this.edges.defaultInterpolate=t;return}if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);this.edges[e].interpolate=t})}updateLink(e,t){e.forEach(e=>{if(typeof e==`number`&&e>=this.edges.length)throw Error(`The index ${e} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);e==="default"?this.edges.defaultStyle=t:(this.edges[e].style=t,(this.edges[e]?.style?.length??0)>0&&!this.edges[e]?.style?.some(e=>e?.startsWith(`fill`))&&this.edges[e]?.style?.push(`fill:none`))})}addClass(e,t){let n=t.join().replace(/\\,/g,`§§§`).replace(/,/g,`;`).replace(/§§§/g,`,`).split(`;`);e.split(`,`).forEach(e=>{let t=this.classes.get(e);t===void 0&&(t={id:e,styles:[],textStyles:[]},this.classes.set(e,t)),n?.forEach(e=>{if(/color/.exec(e)){let n=e.replace(`fill`,`bgFill`);t.textStyles.push(n)}t.styles.push(e)})})}setDirection(e){this.direction=e.trim(),/.*/.exec(this.direction)&&(this.direction=`LR`),/.*v/.exec(this.direction)&&(this.direction=`TB`),this.direction===`TD`&&(this.direction=`TB`)}setClass(e,t){for(let n of e.split(`,`)){let e=this.vertices.get(n);e&&e.classes.push(t);let r=this.edges.find(e=>e.id===n);r&&r.classes.push(t);let i=this.subGraphLookup.get(n);i&&i.classes.push(t)}}setTooltip(e,t){if(t!==void 0){t=this.sanitizeText(t);for(let n of e.split(`,`))this.tooltips.set(this.version===`gen-1`?this.lookUpDomId(n):n,t)}}setClickFun(e,t,n){if(m().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{let n=this.lookUpDomId(e),i=document.querySelector(`[id="${n}"]`);i!==null&&i.addEventListener(`click`,()=>{v.runFunc(t,...r)},!1)}))}setLink(e,t,n){e.split(`,`).forEach(e=>{let r=this.vertices.get(e);r!==void 0&&(r.link=v.formatUrl(t,this.config),r.linkTarget=n)}),this.setClass(e,`clickable`)}getTooltip(e){return this.tooltips.get(e)}setClickEvent(e,t,n){e.split(`,`).forEach(e=>{this.setClickFun(e,t,n)}),this.setClass(e,`clickable`)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}isToolDefinition(e){return oe.has(e.type)}getTools(){let e=[];for(let t of this.vertices.values())this.isToolDefinition(t)&&e.push(t);return e}getClasses(){return this.classes}setupToolTips(e){let n=k();t(e).select(`svg`).selectAll(`g.node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.text(r.attr(`title`)).style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(d.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}clear(e=`gen-2`){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=e,this.config=m(),this.diagramId=``,this.vertexCounter=0,this.direction=void 0,this.secCount=-1,this.posCrossRef=[],this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,o()}setGen(e){this.version=e||`gen-2`}defaultStyle(){return`fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;`}addSubGraph(t,r,i,a){let o=t?.text?.trim(),s=i?.text;t===i&&i?.text&&/\s/.exec(i.text)&&(o=void 0);let c=n(e=>{let t={boolean:{},number:{},string:{}},n=[],r;return{nodeList:e.filter(function(e){let i=typeof e;return e.stmt&&e.stmt===`dir`?(r=e.value,!1):e.trim()===``?!1:i in t?t[i].hasOwnProperty(e)?!1:t[i][e]=!0:!n.includes(e)&&n.push(e)}),dir:r}},`uniq`)(r.flat()),l=c.nodeList,u=c.dir,d=m().flowchart??{};if(u??=d.inheritDir?this.getDirection()??m().direction??void 0:void 0,this.version===`gen-1`)for(let e=0;ee!==o&&!this.globalNodes.has(e)),title:s.trim(),classes:[],dir:u,labelType:this.sanitizeNodeLabelType(i?.type),type:a??`flow`};e.info(`Adding`,f.id,f.nodes,f.dir),f.nodes=this.makeUniq(f,this.subGraphs).nodes;let p=this.getPosForId(o);if(p!==-1){let e=this.subGraphs[p];for(let t of f.nodes)e.nodes.includes(t)||e.nodes.push(t);f.title&&(e.title=f.title),f.dir&&(e.dir=f.dir),f.type&&(e.type=f.type),this.subGraphLookup.set(o,e)}else this.subGraphs.push(f),this.subGraphLookup.set(o,f);return o}addGlobal(e){for(let t of e.flat()){if(typeof t!=`string`)continue;let e=t.trim();e!==``&&this.globalNodes.add(e)}for(let e of this.subGraphs)e.nodes=e.nodes.filter(e=>!this.globalNodes.has(e))}getPosForId(e){for(let[t,n]of this.subGraphs.entries())if(n.id===e)return t;return-1}indexNodes2(e,t){let n=this.subGraphs[t].nodes;if(this.secCount+=1,this.secCount>2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=t,this.subGraphs[t].id===e)return{result:!0,count:0};let r=0,i=1;for(;r=0){let n=this.indexNodes2(e,t);if(n.result)return{result:!0,count:i+n.count};i+=n.count}r+=1}return{result:!1,count:i}}getDepthFirstPos(e){return this.posCrossRef[e]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2(`none`,this.subGraphs.length-1)}addConnector(e,t){let n=e?.text?.trim();if(!n)return``;let r=t?.text?.trim()??``,i=r.length>0?this.sanitizeText(r):n,a=this.connectors.get(n);return a?r.length>0&&(a.text=i):(a={id:n,labelType:`text`,domId:ie+n+`-`+this.vertexCounter,styles:[],classes:[],isConnector:!0,text:i},this.connectors.set(n,a),this.vertices.set(n,a),this.vertexCounter++),n}getSubGraphs(){return this.subGraphs}getConnectors(){return[...this.connectors.values()]}firstGraph(){return this.firstGraphFlag?(this.firstGraphFlag=!1,!0):!1}computeEdgeSemantic(e,t){if(e===`arrow_point`&&t===`normal`)return`sequence`;if(e===`arrow_cross`&&t===`normal`)return`failure`;if(e===`arrow_open`&&t===`dotted`)return`reference`}destructStartLink(e){let t=e.trim(),n=`normal`;return t.includes(`.`)&&(n=`dotted`),{type:`arrow_open`,stroke:n}}countChar(e,t){let n=t.length,r=0;for(let i=0;i`:r=`arrow_point`;break;case`-`:case`.`:r=`arrow_open`,n=t}let i=`normal`,a=n.length-1,o=this.countChar(`.`,n);return o>0&&(i=`dotted`,a=o),{type:r,stroke:i,length:a}}destructLink(e,t){let n=this.destructEndLink(e),r;return t?(r=this.destructStartLink(t),r.stroke===n.stroke?(r.type=n.type,r.length=n.length,{...r,edgeSemantic:this.computeEdgeSemantic(r.type,r.stroke)}):{type:`INVALID`,stroke:`INVALID`}):{...n,edgeSemantic:this.computeEdgeSemantic(n.type,n.stroke)}}exists(e,t){for(let n of e)if(n.nodes.includes(t))return!0;return!1}makeUniq(e,t){let n=[];return e.nodes.forEach((r,i)=>{this.exists(t,r)||n.push(e.nodes[i])}),{nodes:n}}getTypeFromVertex(e){let t=typeof e.type==`string`?I(e.type):e.type;switch(t){case`square`:case void 0:return`squareRect`;case`round`:return`roundedRect`;case`ellipse`:return`ellipse`;default:return t}}findNode(e,t){return e.find(e=>e.id===t)}destructEdgeType(e){let t=`none`,n=`arrow_point`;switch(e){case`arrow_point`:case`arrow_circle`:case`arrow_cross`:case`arrow_hierarchy`:n=e;break;case`double_arrow_point`:case`double_arrow_circle`:case`double_arrow_cross`:t=e.replace(`double_`,``),n=t}return{arrowTypeStart:t,arrowTypeEnd:n}}addNodeFromVertex(e,t,n,r,i,a){let o=n.get(e.id),s=r.get(e.id)??!1,c=this.findNode(t,e.id);if(c)c.cssStyles=e.styles,c.cssCompiledStyles=this.getCompiledStyles(e.classes),c.cssClasses=e.classes.join(` `);else{let n={id:e.id,label:e.text,labelType:e.labelType,labelStyle:``,parentId:o,padding:i.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:this.getCompiledStyles([`default`,`node`,...e.classes]),cssClasses:`default `+e.classes.join(` `),dir:e.dir,domId:e.domId,look:a,link:e.link,linkTarget:e.linkTarget,tooltip:this.getTooltip(e.id),metadata:e.metadata};s?t.push({...n,isGroup:!0,shape:`rect`}):t.push({...n,isGroup:!1,shape:this.getTypeFromVertex(e),wrappingWidth:i.agentflow?.wrappingWidth,minWidth:i.agentflow?.minNodeWidth})}}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}runPostParseValidators(){this.postParseValidationRun||=!0}getData(){this.runPostParseValidators();let e=m(),t=[],r=[],i=this.getSubGraphs(),a=new Map,o=new Map,s=new Set,c=new Map,l=n((e,t,n=new Set)=>{if(n.has(e))return;n.add(e);let r=this.subGraphLookup.get(e);if(r)for(let e of r.nodes)e===t||n.has(e)||(s.add(e),c.set(e,t),l(e,t,n))},`collectDescendants`);for(let e of i)e.metadata?.view===`collapsed`&&!s.has(e.id)&&l(e.id,e.id);let u=n((e,t)=>{let n=new Set,r=t;for(;r!==void 0&&!n.has(r);){if(r===e)return!0;n.add(r),r=a.get(r)}return!1},`wouldCloseContainmentCycle`);for(let e=i.length-1;e>=0;e--){let t=i[e];if(!s.has(t.id)){t.nodes.length>0&&o.set(t.id,!0);for(let e of t.nodes){if(u(e,t.id)){this.emitWarning(M.CONTAINMENT_VIOLATION,`Container "${t.id}" cannot contain "${e}" because "${e}" already contains it. The nesting that would close the loop is dropped.`,{nodeId:e});continue}a.set(e,t.id)}}}for(let n=i.length-1;n>=0;n--){let r=i[n];if(!s.has(r.id)){if(r.metadata?.view===`collapsed`){let n={...r.metadata,containerType:r.type};t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:`collapsedGroup`,dir:r.dir,isGroup:!1,look:e.look,metadata:n})}else t.push({id:r.id,label:r.title,labelStyle:``,labelType:r.labelType,parentId:a.get(r.id),padding:8,cssCompiledStyles:this.getCompiledStyles(r.classes),cssClasses:r.classes.join(` `),shape:se[r.type??`flow`],dir:r.dir,isGroup:!0,look:e.look,metadata:r.metadata})}}this.getVertices().forEach(n=>{s.has(n.id)||this.addNodeFromVertex(n,t,a,o,e,e.look||`classic`)});let d=this.getEdges();d.forEach((t,n)=>{let i=c.get(t.start)??t.start,a=c.get(t.end)??t.end;if(i===a&&t.start!==t.end)return;let{arrowTypeStart:o,arrowTypeEnd:s}=this.destructEdgeType(t.type),l=[...d.defaultStyle??[]];t.style&&l.push(...t.style);let u={id:_(i,a,{counter:n,prefix:`L`},t.id),isUserDefinedId:t.isUserDefinedId,start:i,end:a,type:t.type??`normal`,label:t.text,labelType:t.labelType,labelpos:`c`,thickness:t.stroke,minlen:t.length,classes:t?.stroke===`invisible`?``:`edge-thickness-normal edge-pattern-solid flowchart-link`,arrowTypeStart:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:o,arrowTypeEnd:t?.stroke===`invisible`||t?.type===`arrow_open`?`none`:s,arrowheadStyle:`fill: #333`,cssCompiledStyles:this.getCompiledStyles(t.classes),labelStyle:l,style:l,pattern:t.stroke,look:e.look,animate:t.animate,animation:t.animation,curve:t.interpolate||this.edges.defaultInterpolate||e.flowchart?.curve,metadata:t.metadata};r.push(u)}),ne(t,this);let f=new Map,p=new Map;for(let e of i){let t=a.get(e.id);t!==void 0&&p.set(t,[...p.get(t)??[],e.id])}let h=0,g=n(e=>{if(!f.has(e)){f.set(e,h++);for(let t of p.get(e)??[])g(t)}},`walkContainers`);for(let e of i)a.get(e.id)===void 0&&g(e.id);let v=new Set(this.getConnectors().map(e=>e.id));return re(t,e=>{if(v.has(e))return`connector`;let t=this.vertices.get(e);return t?this.deriveVertexKind(t,I(t.type)):void 0},f),{nodes:t,edges:r,other:{},config:e,connectors:this.getConnectors()}}defaultConfig(){return s.flowchart}deriveVertexKind(e,t){return this.isToolDefinition(e)?`tool`:t===`hexagon`||t===`hex`?`action`:t===`lean-right`||t===`lean_right`?`input`:t===`lin-doc`||t===`lined-document`?`refdoc`:t===`diamond`?`decision`:`task`}getSemanticModel(){this.runPostParseValidators();let e=new Set(this.subGraphs.map(e=>e.id)),t=[],n=[];for(let[r,i]of this.vertices){if(e.has(r))continue;if(i.isConnector){let e={id:r};if(i.text!==void 0&&i.text!==r&&(e.title=i.text),i.metadata&&Object.keys(i.metadata).length>0){let t={};for(let[e,n]of Object.entries(i.metadata))ae.has(e)||(t[e]=n);Object.keys(t).length>0&&(e.metadata=t)}n.push(e);continue}let a={id:r};i.text!==void 0&&(a.label=i.text);let o=typeof i.type==`string`?I(i.type):i.type;if(o!==void 0&&(a.shape=o),a.vertexKind=this.deriveVertexKind(i,o),i.metadata&&Object.keys(i.metadata).length>0){let e={};for(let[t,n]of Object.entries(i.metadata))ae.has(t)||(e[t]=n);Object.keys(e).length>0&&(a.metadata=e)}t.push(a)}let r={vertices:t,edges:this.edges.map(e=>{let t={start:e.start,end:e.end};return e.id!==void 0&&(t.id=e.id),typeof e.text==`string`&&e.text.length>0&&(t.label=e.text),e.type!==void 0&&(t.type=e.type),e.stroke!==void 0&&(t.stroke=e.stroke),e.edgeSemantic!==void 0&&(t.edgeSemantic=e.edgeSemantic),e.length!==void 0&&(t.length=e.length),e.metadata&&Object.keys(e.metadata).length>0&&(t.metadata={...e.metadata}),t}),subGraphs:this.subGraphs.map(e=>{let t={id:e.id,nodes:[...e.nodes]};if(e.type!==void 0&&(t.type=e.type),e.title!==void 0&&(t.title=e.title),e.dir!==void 0&&(t.direction=e.dir),e.metadata&&Object.keys(e.metadata).length>0){let n={};for(let[t,r]of Object.entries(e.metadata))ae.has(t)||(n[t]=r);Object.keys(n).length>0&&(t.metadata=n)}return t}),connectors:n,diagnostics:this.diagnostics};return this.direction!==void 0&&(r.direction=this.direction),r}setFrontmatterLineOffset(e){this.frontmatterLineOffset=e??0}toElementPosition(e){let t=e?.first_line??0,n=e?.first_column??0,r=e?.last_line??t,i=e?.last_column??n,[a,o]=e?.range??[0,0];return{startLine:t+this.frontmatterLineOffset,startColumn:n,endLine:r+this.frontmatterLineOffset,endColumn:i,startIndex:a,endIndex:o}}pushMapping(e,t,n){if(!e)return;let r={id:e,type:t,position:this.toElementPosition(n)};return this.elementMappings.push(r),r}addVertexMapping(e,t,n,r){let i=this.pushMapping(e,`vertex`,r);i&&n==null&&this.bareVertexMappings.add(i)}extendVertexMapping(e,t){if(!e||!t)return;let n=this.toElementPosition(t);for(let t=this.elementMappings.length-1;t>=0;t--){let r=this.elementMappings[t];if(r.type===`vertex`&&r.id===e){this.bareVertexMappings.has(r)&&(r.type=`attachment`,this.bareVertexMappings.delete(r)),(n.endLine>r.position.endLine||n.endLine===r.position.endLine&&n.endColumn>r.position.endColumn)&&(r.position.endLine=n.endLine,r.position.endColumn=n.endColumn,r.position.endIndex=n.endIndex);return}}this.pushMapping(e,`attachment`,t)}addEdgeMapping(e,t,n,r){let i=Array.isArray(t)?t.map(e=>typeof e==`string`?e:e?.id??``).filter(Boolean):[],a=i.length>0?i.join(`>`):`edge`;this.pushMapping(a,`edge`,r)}addSubgraphMapping(e,t,n,r){let i=(typeof e==`string`?e:e?.text)??``,a=this.toElementPosition(n),o=r?this.toElementPosition(r):a;i&&this.elementMappings.push({id:i,type:`subgraph`,position:{startLine:a.startLine,startColumn:a.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:a.startIndex,endIndex:o.endIndex}})}addConnectorMapping(e,t,n,r){let i=e?.text?.trim()??``;if(!i)return;let a=this.toElementPosition(n),o=r?this.toElementPosition(r):a;this.elementMappings.push({id:i,type:`connector`,position:{startLine:a.startLine,startColumn:a.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:a.startIndex,endIndex:o.endIndex}})}getElementMappings(){return[...this.elementMappings]}getElementById(e){return this.elementMappings.find(t=>t.id===e)}getElementsOnLine(e){return this.elementMappings.filter(t=>e>=t.position.startLine&&e<=t.position.endLine)}getElementAtPosition(e,t){let r=this.elementMappings.filter(n=>{let{startLine:r,startColumn:i,endLine:a,endColumn:o}=n.position;return!(ea||e===r&&to)});if(r.length===0)return;let i=n(({position:e})=>[e.endLine-e.startLine,e.endColumn-e.startColumn],`span`);return r.reduce((e,t)=>{let[n,r]=i(e),[a,o]=i(t);return a===n?oe.id===s.id&&e.severity===s.severity&&e.message===s.message&&e.nodeId===s.nodeId&&e.edgeId===s.edgeId))return;this.diagnostics.push(s);let c=`agentflow[${t}]: ${r}`;n===`error`?e.error(c):e.warn(c)}emitWarning(e,t,n){this.emitDiagnostic(e,`warning`,t,n)}emitError(e,t,n){this.emitDiagnostic(e,`error`,t,n)}getDiagnostics(){return[...this.diagnostics]}},de={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.debug(`Drawing agentflow diagram`,n);let{securityLevel:a,agentflow:o,layout:s}=m();i.db.setDiagramId(n),e.debug(`Before getData: `);let c=i.db.getData();e.debug(`Data: `,c);let l=A(n,a),u=i.db.getDirection();c.type=i.type,c.layoutAlgorithm=E(s),c.layoutAlgorithm===`dagre`&&s===`elk`&&e.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback."),c.direction=u,c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=[`point`,`circle`,`cross`,`hierarchy`],c.diagramId=n,e.debug(`REF1:`,c),await T(c,l);let d=o?.diagramPadding??8;v.insertTitle(l,`agentflowTitleText`,o?.titleTopMargin??0,i.db.getDiagramTitle()),j(l,d,`agentflow`,o?.useMaxWidth??!0)},`draw`)},fe=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,5],r=[1,4],i=[1,3],a=[1,6],o=[1,8,9,10,11,12,28,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],s=[2,2],c=[1,15],l=[1,16],u=[1,17],d=[1,18],f=[1,19],p=[1,26],m=[1,27],h=[1,28],g=[1,30],_=[1,31],v=[1,32],y=[1,55],b=[1,54],x=[1,34],S=[1,35],C=[1,36],w=[1,37],T=[1,38],E=[1,50],D=[1,52],O=[1,48],k=[1,53],A=[1,49],j=[1,56],M=[1,51],N=[1,57],P=[1,58],ee=[1,39],te=[1,40],F=[1,41],I=[1,42],ne=[1,43],L=[1,64],R=[1,8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],z=[1,70],B=[1,68],V=[1,67],H=[1,69],re=[8,9,10,12,78,80,81],ie=[1,88],ae=[1,101],oe=[1,106],se=[1,105],ce=[1,102],le=[1,98],ue=[1,104],de=[1,100],fe=[1,107],pe=[1,103],me=[1,108],he=[1,99],ge=[8,9,10,11,12,43,78,80,81],U=[8,9,10,11,12,43,49,78,80,81],W=[8,9,10,11,12,30,43,47,49,51,53,55,57,59,61,63,66,68,70,71,73,78,80,81,92,105,108,109,112,114,117,118,119],_e=[8,9,10,12,47,63,78,80,81,92,105,108,109,112,114,117,118,119],ve=[47,63,92,105,108,109,112,114,117,118,119],ye=[1,131],be=[1,132],xe=[1,134],Se=[1,133],Ce=[47,63,65,77,92,105,108,109,112,114,117,118,119],we=[1,143],Te=[1,157],Ee=[1,158],De=[1,159],Oe=[1,162],ke=[1,161],Ae=[1,160],je=[1,145],Me=[1,147],Ne=[1,151],Pe=[1,139],Fe=[1,140],Ie=[1,152],Le=[1,153],Re=[1,154],ze=[1,155],Be=[1,156],Ve=[1,163],He=[1,164],Ue=[1,141],We=[1,142],Ge=[1,149],Ke=[1,144],qe=[1,148],Je=[1,146],Ye=[8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],Xe=[1,168],Ze=[1,170],G=[8,9,10,12],K=[8,9,10,11,12,15,47,63,92,108,109,112,114,117,118,119],q=[1,190],J=[1,186],Y=[1,187],X=[1,191],Z=[1,188],Q=[1,189],Qe=[80,119,122],$=[8,9,10,11,12,13,15,28,30,33,35,36,43,47,63,78,87,88,89,90,91,92,93,108,112,114,117,118,119],$e=[11,109],et=[32,52,54,56,58,60,65,67,69,70,72,74,119,120,121],tt=[1,269],nt=[1,267],rt=[1,271],it=[1,265],at=[1,266],ot=[1,268],st=[1,270],ct=[1,272],lt=[1,292],ut=[8,9,10,12,109],dt=[8,9,10,11,12,63,87,108,109,112,113,114,115],ft={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,COMMENT:8,SEMI:9,NEWLINE:10,SPACE:11,EOF:12,GRAPH:13,NODIR:14,DIR:15,FirstStmtSeparator:16,ending:17,endToken:18,spaceList:19,spaceListNewline:20,vertexStatement:21,separator:22,styleStatement:23,linkStyleStatement:24,classDefStatement:25,classStatement:26,clickStatement:27,flow:28,textNoTags:29,SQS:30,text:31,SQE:32,end:33,shapeData:34,global:35,connector:36,direction:37,acc_title:38,acc_title_value:39,acc_descr:40,acc_descr_value:41,acc_descr_multiline_value:42,SHAPE_DATA:43,link:44,node:45,styledVertex:46,AMP:47,vertex:48,STYLE_SEPARATOR:49,idString:50,DOUBLECIRCLESTART:51,DOUBLECIRCLEEND:52,PS:53,PE:54,"(-":55,"-)":56,STADIUMSTART:57,STADIUMEND:58,SUBROUTINESTART:59,SUBROUTINEEND:60,VERTEX_WITH_PROPS_START:61,"NODE_STRING[field]":62,COLON:63,"NODE_STRING[value]":64,PIPE:65,CYLINDERSTART:66,CYLINDEREND:67,DIAMOND_START:68,DIAMOND_STOP:69,TAGEND:70,TRAPSTART:71,TRAPEND:72,INVTRAPSTART:73,INVTRAPEND:74,linkStatement:75,arrowText:76,TESTSTR:77,START_LINK:78,edgeText:79,LINK:80,LINK_ID:81,edgeTextToken:82,STR:83,MD_STR:84,textToken:85,keywords:86,STYLE:87,LINKSTYLE:88,CLASSDEF:89,CLASS:90,CLICK:91,DOWN:92,UP:93,textNoTagsToken:94,stylesOpt:95,"idString[vertex]":96,"idString[class]":97,CALLBACKNAME:98,CALLBACKARGS:99,HREF:100,LINK_TARGET:101,"STR[link]":102,"STR[tooltip]":103,alphaNum:104,DEFAULT:105,numList:106,INTERPOLATE:107,NUM:108,COMMA:109,style:110,styleComponent:111,NODE_STRING:112,UNIT:113,BRKT:114,PCT:115,idStringToken:116,MINUS:117,MULT:118,UNICODE_TEXT:119,TEXT:120,TAGSTART:121,EDGE_TEXT:122,alphaNumToken:123,direction_tb:124,direction_bt:125,direction_rl:126,direction_lr:127,direction_td:128,$accept:0,$end:1},terminals_:{2:`error`,8:`COMMENT`,9:`SEMI`,10:`NEWLINE`,11:`SPACE`,12:`EOF`,13:`GRAPH`,14:`NODIR`,15:`DIR`,28:`flow`,30:`SQS`,32:`SQE`,33:`end`,35:`global`,36:`connector`,38:`acc_title`,39:`acc_title_value`,40:`acc_descr`,41:`acc_descr_value`,42:`acc_descr_multiline_value`,43:`SHAPE_DATA`,47:`AMP`,49:`STYLE_SEPARATOR`,51:`DOUBLECIRCLESTART`,52:`DOUBLECIRCLEEND`,53:`PS`,54:`PE`,55:`(-`,56:`-)`,57:`STADIUMSTART`,58:`STADIUMEND`,59:`SUBROUTINESTART`,60:`SUBROUTINEEND`,61:`VERTEX_WITH_PROPS_START`,62:`NODE_STRING[field]`,63:`COLON`,64:`NODE_STRING[value]`,65:`PIPE`,66:`CYLINDERSTART`,67:`CYLINDEREND`,68:`DIAMOND_START`,69:`DIAMOND_STOP`,70:`TAGEND`,71:`TRAPSTART`,72:`TRAPEND`,73:`INVTRAPSTART`,74:`INVTRAPEND`,77:`TESTSTR`,78:`START_LINK`,80:`LINK`,81:`LINK_ID`,83:`STR`,84:`MD_STR`,87:`STYLE`,88:`LINKSTYLE`,89:`CLASSDEF`,90:`CLASS`,91:`CLICK`,92:`DOWN`,93:`UP`,96:`idString[vertex]`,97:`idString[class]`,98:`CALLBACKNAME`,99:`CALLBACKARGS`,100:`HREF`,101:`LINK_TARGET`,102:`STR[link]`,103:`STR[tooltip]`,105:`DEFAULT`,107:`INTERPOLATE`,108:`NUM`,109:`COMMA`,112:`NODE_STRING`,113:`UNIT`,114:`BRKT`,115:`PCT`,117:`MINUS`,118:`MULT`,119:`UNICODE_TEXT`,120:`TEXT`,121:`TAGSTART`,122:`EDGE_TEXT`,124:`direction_tb`,125:`direction_bt`,126:`direction_rl`,127:`direction_lr`,128:`direction_td`},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,2],[4,3],[17,2],[17,1],[18,1],[18,1],[18,1],[16,1],[16,1],[16,2],[16,1],[20,2],[20,2],[20,2],[20,1],[20,1],[20,1],[19,2],[19,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,10],[7,6],[7,7],[7,4],[7,4],[7,7],[7,8],[7,4],[7,5],[7,1],[7,2],[7,2],[7,1],[22,1],[22,1],[22,1],[22,1],[34,2],[34,1],[21,4],[21,3],[21,4],[21,2],[21,2],[21,1],[45,1],[45,6],[45,5],[46,1],[46,3],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,8],[48,4],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,4],[48,4],[48,1],[44,2],[44,3],[44,3],[44,1],[44,3],[44,4],[79,1],[79,2],[79,1],[79,1],[75,1],[75,2],[76,3],[31,1],[31,2],[31,1],[31,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[29,1],[29,2],[29,1],[29,1],[25,5],[26,5],[27,2],[27,4],[27,3],[27,5],[27,3],[27,5],[27,5],[27,7],[27,2],[27,4],[27,2],[27,4],[27,4],[27,6],[23,5],[24,5],[24,5],[24,9],[24,9],[24,7],[24,7],[106,1],[106,3],[95,1],[95,3],[110,1],[110,2],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[85,1],[85,1],[85,1],[85,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[82,1],[82,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[50,1],[50,2],[104,1],[104,2],[37,1],[37,1],[37,1],[37,1],[37,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:(!Array.isArray(a[s])||a[s].length>0)&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 198:this.$=a[s];break;case 5:case 33:case 34:case 35:case 36:case 37:this.$=[];break;case 13:r.setDirection(`TB`),this.$=`TB`;break;case 14:r.setDirection(a[s-1]),this.$=a[s-1];break;case 32:this.$=a[s-1].nodes;break;case 38:this.$=r.addSubGraph(a[s-6],a[s-1],a[s-4],`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-6],a[s-4],o[s-8],o[s]);break;case 39:this.$=r.addSubGraph(a[s-7],a[s-1],a[s-5],`flow`),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-3],o[s-3]),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-7],a[s-5],o[s-9],o[s]);break;case 40:this.$=r.addSubGraph(a[s-3],a[s-1],{text:``,type:`text`},`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-3],{text:``,type:`text`},o[s-5],o[s]);break;case 41:this.$=r.addSubGraph(a[s-4],a[s-1],{text:``,type:`text`},`flow`),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-3],o[s-3]),r.addSubgraphMapping&&r.addSubgraphMapping(a[s-4],{text:``,type:`text`},o[s-6],o[s]);break;case 42:this.$=r.addSubGraph(void 0,a[s-1],void 0,`flow`),r.addSubgraphMapping&&r.addSubgraphMapping(void 0,void 0,o[s-3],o[s]);break;case 43:r.addGlobal(a[s-1]),this.$=[];break;case 44:this.$=r.addConnector(a[s-4],a[s-2]),r.addConnectorMapping&&r.addConnectorMapping(a[s-4],a[s-2],o[s-6],o[s]);break;case 45:this.$=r.addConnector(a[s-5],a[s-3]),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-1],o[s-1]),r.addConnectorMapping&&r.addConnectorMapping(a[s-5],a[s-3],o[s-7],o[s]);break;case 46:this.$=r.addConnector(a[s-1],{text:``,type:`text`}),r.addConnectorMapping&&r.addConnectorMapping(a[s-1],{text:``,type:`text`},o[s-3],o[s]);break;case 47:this.$=r.addConnector(a[s-2],{text:``,type:`text`}),r.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,a[s-1],o[s-1]),r.addConnectorMapping&&r.addConnectorMapping(a[s-2],{text:``,type:`text`},o[s-4],o[s]);break;case 49:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 50:case 51:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 56:this.$=a[s-1]+a[s];break;case 57:this.$=a[s];break;case 58:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s],o[s]),r.extendVertexMapping&&r.extendVertexMapping(a[s-1][a[s-1].length-1],o[s]),r.addLink(a[s-3].stmt,a[s-1],a[s-2]),r.addEdgeMapping&&r.addEdgeMapping(a[s-3].stmt,a[s-1],a[s-2],this._$),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 59:r.addLink(a[s-2].stmt,a[s],a[s-1]),r.addEdgeMapping&&r.addEdgeMapping(a[s-2].stmt,a[s],a[s-1],this._$),this.$={stmt:a[s],nodes:a[s].concat(a[s-2].nodes)};break;case 60:r.addLink(a[s-3].stmt,a[s-1],a[s-2]),r.addEdgeMapping&&r.addEdgeMapping(a[s-3].stmt,a[s-1],a[s-2],this._$),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 61:this.$={stmt:a[s-1],nodes:a[s-1]};break;case 62:r.addVertex(a[s-1][a[s-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s],o[s]),r.extendVertexMapping&&r.extendVertexMapping(a[s-1][a[s-1].length-1],o[s]),this.$={stmt:a[s-1],nodes:a[s-1],shapeData:a[s]};break;case 63:this.$={stmt:a[s],nodes:a[s]};break;case 64:this.$=[a[s]];break;case 65:r.addVertex(a[s-5][a[s-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[s-4],o[s-4]),r.extendVertexMapping&&r.extendVertexMapping(a[s-5][a[s-5].length-1],o[s-4]),this.$=a[s-5].concat(a[s]);break;case 66:this.$=a[s-4].concat(a[s]);break;case 67:this.$=a[s];break;case 68:this.$=a[s-2],r.setClass(a[s-2],a[s]);break;case 69:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`square`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`square`,this._$);break;case 70:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`doublecircle`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`doublecircle`,this._$);break;case 71:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`circle`),r.addVertexMapping&&r.addVertexMapping(a[s-5],a[s-2],`circle`,this._$);break;case 72:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`ellipse`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`ellipse`,this._$);break;case 73:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`stadium`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`stadium`,this._$);break;case 74:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`subroutine`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`subroutine`,this._$);break;case 75:this.$=a[s-7],r.addVertex(a[s-7],a[s-1],`rect`,void 0,void 0,void 0,Object.fromEntries([[a[s-5],a[s-3]]])),r.addVertexMapping&&r.addVertexMapping(a[s-7],a[s-1],`rect`,this._$);break;case 76:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`cylinder`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`cylinder`,this._$);break;case 77:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`round`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`round`,this._$);break;case 78:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`diamond`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`diamond`,this._$);break;case 79:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],`hexagon`),r.addVertexMapping&&r.addVertexMapping(a[s-5],a[s-2],`hexagon`,this._$);break;case 80:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`odd`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`odd`,this._$);break;case 81:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`trapezoid`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`trapezoid`,this._$);break;case 82:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`inv_trapezoid`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`inv_trapezoid`,this._$);break;case 83:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_right`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`lean_right`,this._$);break;case 84:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],`lean_left`),r.addVertexMapping&&r.addVertexMapping(a[s-3],a[s-1],`lean_left`,this._$);break;case 85:this.$=a[s],r.addVertex(a[s]),r.addVertexMapping&&r.addVertexMapping(a[s],void 0,void 0,this._$);break;case 86:a[s-1].text=a[s],this.$=a[s-1];break;case 87:case 88:a[s-2].text=a[s-1],this.$=a[s-2];break;case 89:this.$=a[s];break;case 90:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,text:a[s-1]};break;case 91:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,text:a[s-1],id:a[s-3]};break;case 92:this.$={text:a[s],type:`text`};break;case 93:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 94:this.$={text:a[s],type:`string`};break;case 95:this.$={text:a[s],type:`markdown`};break;case 96:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic};break;case 97:var c=r.destructLink(a[s]);this.$={type:c.type,stroke:c.stroke,length:c.length,edgeSemantic:c.edgeSemantic,id:a[s-1]};break;case 98:this.$=a[s-1];break;case 99:this.$={text:a[s],type:`text`};break;case 100:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 101:this.$={text:a[s],type:`string`};break;case 102:case 119:this.$={text:a[s],type:`markdown`};break;case 116:this.$={text:a[s],type:`text`};break;case 117:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 118:this.$={text:a[s],type:`text`};break;case 120:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 121:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 122:case 130:this.$=a[s-1],r.setClickEvent(a[s-1],a[s]);break;case 123:case 131:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 124:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 125:this.$=a[s-4],r.setClickEvent(a[s-4],a[s-3],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 126:this.$=a[s-2],r.setLink(a[s-2],a[s]);break;case 127:this.$=a[s-4],r.setLink(a[s-4],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 128:this.$=a[s-4],r.setLink(a[s-4],a[s-2],a[s]);break;case 129:this.$=a[s-6],r.setLink(a[s-6],a[s-4],a[s]),r.setTooltip(a[s-6],a[s-2]);break;case 132:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 133:this.$=a[s-3],r.setLink(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 134:this.$=a[s-3],r.setLink(a[s-3],a[s-2],a[s]);break;case 135:this.$=a[s-5],r.setLink(a[s-5],a[s-4],a[s]),r.setTooltip(a[s-5],a[s-2]);break;case 136:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 137:this.$=a[s-4],r.updateLink([a[s-2]],a[s]);break;case 138:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 139:this.$=a[s-8],r.updateLinkInterpolate([a[s-6]],a[s-2]),r.updateLink([a[s-6]],a[s]);break;case 140:this.$=a[s-8],r.updateLinkInterpolate(a[s-6],a[s-2]),r.updateLink(a[s-6],a[s]);break;case 141:this.$=a[s-6],r.updateLinkInterpolate([a[s-4]],a[s]);break;case 142:this.$=a[s-6],r.updateLinkInterpolate(a[s-4],a[s]);break;case 143:case 145:this.$=[a[s]];break;case 144:case 146:a[s-2].push(a[s]),this.$=a[s-2];break;case 148:this.$=a[s-1]+a[s];break;case 196:this.$=a[s];break;case 197:this.$=a[s-1]+``+a[s];break;case 199:this.$=a[s-1]+``+a[s];break;case 200:this.$={stmt:`dir`,value:`TB`};break;case 201:this.$={stmt:`dir`,value:`BT`};break;case 202:this.$={stmt:`dir`,value:`RL`};break;case 203:this.$={stmt:`dir`,value:`LR`};break;case 204:this.$={stmt:`dir`,value:`TD`}}},`anonymous`),table:[{3:1,4:2,8:t,10:r,11:i,13:a},{1:[3]},e(o,s,{5:7}),{4:8,8:t,10:r,11:i,13:a},{4:9,8:t,10:r,11:i,13:a},{4:10,8:t,10:r,11:i,13:a},{14:[1,11],15:[1,12]},{1:[2,1],6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(o,[2,10]),e(o,[2,11]),e(o,[2,12]),e(o,[2,13]),{8:[1,63],9:[1,60],10:[1,61],11:L,16:59,19:62},e(R,[2,3]),e(R,[2,4]),e(R,[2,5]),e(R,[2,6]),e(R,[2,7]),e(R,[2,8]),e(R,[2,9]),{8:z,9:B,10:V,12:H,22:65,44:66,75:71,78:[1,72],80:[1,74],81:[1,73]},{8:z,9:B,10:V,12:H,22:75},{8:z,9:B,10:V,12:H,22:76},{8:z,9:B,10:V,12:H,22:77},{8:z,9:B,10:V,12:H,22:78},{8:z,9:B,10:V,12:H,22:79},{8:z,9:B,10:V,11:[1,80],12:H,22:81},{8:z,9:B,10:V,12:H,22:82},{11:[1,83]},e(R,[2,48]),{39:[1,84]},{41:[1,85]},e(R,[2,51]),e(re,[2,63],{19:86,34:87,11:L,43:ie}),{11:[1,89]},{11:[1,90]},{11:[1,91]},{11:[1,92]},{15:ae,47:oe,63:se,83:[1,96],92:ce,98:[1,93],100:[1,94],104:95,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},e(R,[2,200]),e(R,[2,201]),e(R,[2,202]),e(R,[2,203]),e(R,[2,204]),e(ge,[2,64]),e(ge,[2,67],{49:[1,109]}),e(U,[2,85],{116:122,30:[1,110],47:y,51:[1,111],53:[1,112],55:[1,113],57:[1,114],59:[1,115],61:[1,116],63:b,66:[1,117],68:[1,118],70:[1,119],71:[1,120],73:[1,121],92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),e(W,[2,196]),e(W,[2,157]),e(W,[2,158]),e(W,[2,159]),e(W,[2,160]),e(W,[2,161]),e(W,[2,162]),e(W,[2,163]),e(W,[2,164]),e(W,[2,165]),e(W,[2,166]),e(W,[2,167]),e(o,[2,14]),e(o,[2,20]),e(o,[2,21]),{10:[1,123]},e(o,[2,23]),e(_e,[2,31],{19:124,11:L}),e(R,[2,32]),{45:125,46:44,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(R,[2,52]),e(R,[2,53]),e(R,[2,54]),e(R,[2,55]),e(ve,[2,89],{76:126,65:[1,128],77:[1,127]}),{79:129,82:130,83:ye,84:be,119:xe,122:Se},{78:[1,135],80:[1,136]},e(Ce,[2,96]),e(R,[2,33]),e(R,[2,34]),e(R,[2,35]),e(R,[2,36]),e(R,[2,37]),{11:we,13:Te,15:Ee,28:De,29:137,33:Oe,35:ke,36:Ae,47:je,63:Me,78:Ne,83:Pe,84:Fe,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:138,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e(Ye,s,{5:165}),e(Ye,s,{5:166}),{11:we,13:Te,15:Ee,28:De,29:167,33:Oe,35:ke,36:Ae,47:je,63:Me,78:Ne,83:Pe,84:Fe,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:138,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e(R,[2,49]),e(R,[2,50]),e(re,[2,61],{47:Xe}),e(re,[2,62],{19:169,11:L,43:Ze}),e(ge,[2,57]),{47:y,50:171,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{105:[1,172],106:173,108:[1,174]},{47:y,50:175,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{47:y,50:176,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,122],{11:[1,177],99:[1,178]}),{83:[1,179]},e(G,[2,130],{123:181,11:[1,180],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,132],{11:[1,182]}),e(K,[2,198]),e(K,[2,185]),e(K,[2,186]),e(K,[2,187]),e(K,[2,188]),e(K,[2,189]),e(K,[2,190]),e(K,[2,191]),e(K,[2,192]),e(K,[2,193]),e(K,[2,194]),e(K,[2,195]),{47:y,50:183,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{31:184,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:192,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:194,53:[1,193],70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:195,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:196,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:197,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{112:[1,198]},{31:199,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:200,68:[1,201],70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:202,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:203,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{31:204,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(W,[2,197]),e(o,[2,22]),e(_e,[2,30]),e(re,[2,59],{34:205,19:206,11:L,43:ie}),e(ve,[2,86],{11:[1,207]}),{11:[1,208]},{31:209,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{80:[1,210],82:211,119:xe,122:Se},e(Qe,[2,92]),e(Qe,[2,94]),e(Qe,[2,95]),e(Qe,[2,183]),e(Qe,[2,184]),{79:212,82:130,83:ye,84:be,119:xe,122:Se},e(Ce,[2,97]),{8:z,9:B,10:V,11:we,12:H,13:Te,15:Ee,22:214,28:De,30:[1,213],33:Oe,34:215,35:ke,36:Ae,43:ie,47:je,63:Me,78:Ne,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:216,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},e($,[2,116]),e($,[2,118]),e($,[2,119]),e($,[2,172]),e($,[2,173]),e($,[2,174]),e($,[2,175]),e($,[2,176]),e($,[2,177]),e($,[2,178]),e($,[2,179]),e($,[2,180]),e($,[2,181]),e($,[2,182]),e($,[2,103]),e($,[2,104]),e($,[2,105]),e($,[2,106]),e($,[2,107]),e($,[2,108]),e($,[2,109]),e($,[2,110]),e($,[2,111]),e($,[2,112]),e($,[2,113]),e($,[2,114]),e($,[2,115]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,217],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,218],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{8:z,9:B,10:V,11:we,12:H,13:Te,15:Ee,22:220,28:De,30:[1,219],33:Oe,34:221,35:ke,36:Ae,43:ie,47:je,63:Me,78:Ne,86:150,87:Ie,88:Le,89:Re,90:ze,91:Be,92:Ve,93:He,94:216,108:Ue,112:We,114:Ge,117:Ke,118:qe,119:Je},{11:L,19:222},{47:[1,223]},e(ge,[2,56]),{11:[1,224],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{11:[1,225]},{11:[1,226],109:[1,227]},e($e,[2,143]),{11:[1,228],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{11:[1,229],47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:122,117:M,118:N,119:P},{83:[1,230]},e(G,[2,124],{11:[1,231]}),e(G,[2,126],{11:[1,232]}),{83:[1,233]},e(K,[2,199]),{83:[1,234],101:[1,235]},e(ge,[2,68],{116:122,47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),{32:[1,236],70:q,85:237,119:X,120:Z,121:Q},e(et,[2,99]),e(et,[2,101]),e(et,[2,102]),e(et,[2,168]),e(et,[2,169]),e(et,[2,170]),e(et,[2,171]),{52:[1,238],70:q,85:237,119:X,120:Z,121:Q},{31:239,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{54:[1,240],70:q,85:237,119:X,120:Z,121:Q},{56:[1,241],70:q,85:237,119:X,120:Z,121:Q},{58:[1,242],70:q,85:237,119:X,120:Z,121:Q},{60:[1,243],70:q,85:237,119:X,120:Z,121:Q},{63:[1,244]},{67:[1,245],70:q,85:237,119:X,120:Z,121:Q},{69:[1,246],70:q,85:237,119:X,120:Z,121:Q},{31:247,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},{32:[1,248],70:q,85:237,119:X,120:Z,121:Q},{70:q,72:[1,249],74:[1,250],85:237,119:X,120:Z,121:Q},{70:q,72:[1,252],74:[1,251],85:237,119:X,120:Z,121:Q},e(re,[2,58],{19:169,11:L,43:Ze}),e(re,[2,60],{47:Xe}),e(ve,[2,88]),e(ve,[2,87]),{65:[1,253],70:q,85:237,119:X,120:Z,121:Q},e(ve,[2,90]),e(Qe,[2,93]),{80:[1,254],82:211,119:xe,122:Se},{31:255,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(Ye,s,{5:256}),{8:z,9:B,10:V,12:H,22:257,43:Ze},e($,[2,117]),e(R,[2,42]),e(R,[2,43]),{31:258,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(R,[2,46]),{8:z,9:B,10:V,12:H,22:259,43:Ze},{46:260,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},{11:L,19:261},{11:tt,63:nt,87:rt,95:262,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:273,107:[1,274],108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:275,107:[1,276],108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{108:[1,277]},{11:tt,63:nt,87:rt,95:278,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{47:y,50:279,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,123]),{83:[1,280]},{83:[1,281],101:[1,282]},e(G,[2,131]),e(G,[2,133],{11:[1,283]}),e(G,[2,134]),e(U,[2,69]),e(et,[2,100]),e(U,[2,70]),{54:[1,284],70:q,85:237,119:X,120:Z,121:Q},e(U,[2,77]),e(U,[2,72]),e(U,[2,73]),e(U,[2,74]),{112:[1,285]},e(U,[2,76]),e(U,[2,78]),{69:[1,286],70:q,85:237,119:X,120:Z,121:Q},e(U,[2,80]),e(U,[2,81]),e(U,[2,83]),e(U,[2,82]),e(U,[2,84]),e([11,47,63,92,105,108,109,112,114,117,118,119],[2,98]),e(ve,[2,91]),{32:[1,287],70:q,85:237,119:X,120:Z,121:Q},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,288],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(Ye,s,{5:289}),{32:[1,290],70:q,85:237,119:X,120:Z,121:Q},e(R,[2,47]),e(ge,[2,66]),{46:291,47:y,48:45,50:46,63:b,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P},e(G,[2,136],{109:lt}),e(ut,[2,145],{111:293,11:tt,63:nt,87:rt,108:it,112:at,113:ot,114:st,115:ct}),e(dt,[2,147]),e(dt,[2,149]),e(dt,[2,150]),e(dt,[2,151]),e(dt,[2,152]),e(dt,[2,153]),e(dt,[2,154]),e(dt,[2,155]),e(dt,[2,156]),e(G,[2,137],{109:lt}),{11:[1,294]},e(G,[2,138],{109:lt}),{11:[1,295]},e($e,[2,144]),e(G,[2,120],{109:lt}),e(G,[2,121],{116:122,47:y,63:b,92:E,105:D,108:O,109:k,112:A,114:j,117:M,118:N,119:P}),e(G,[2,125]),e(G,[2,127],{11:[1,296]}),e(G,[2,128]),{101:[1,297]},{54:[1,298]},{65:[1,299]},{69:[1,300]},{8:z,9:B,10:V,12:H,22:301,34:302,43:ie},e(R,[2,40]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,303],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},{8:z,9:B,10:V,12:H,22:304,34:305,43:ie},e(ge,[2,65]),{11:tt,63:nt,87:rt,108:it,110:306,111:264,112:at,113:ot,114:st,115:ct},e(dt,[2,148]),{15:ae,47:oe,63:se,92:ce,104:307,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},{15:ae,47:oe,63:se,92:ce,104:308,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he,123:97},{101:[1,309]},e(G,[2,135]),e(U,[2,71]),{31:310,70:q,83:J,84:Y,85:185,119:X,120:Z,121:Q},e(U,[2,79]),e(Ye,s,{5:311}),{8:z,9:B,10:V,12:H,22:312,43:Ze},e(R,[2,41]),e(R,[2,44]),{8:z,9:B,10:V,12:H,22:313,43:Ze},e(ut,[2,146],{111:293,11:tt,63:nt,87:rt,108:it,112:at,113:ot,114:st,115:ct}),e(G,[2,141],{123:181,11:[1,314],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,142],{123:181,11:[1,315],15:ae,47:oe,63:se,92:ce,108:le,109:ue,112:de,114:fe,117:pe,118:me,119:he}),e(G,[2,129]),{32:[1,316],70:q,85:237,119:X,120:Z,121:Q},{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,317],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(Ye,s,{5:318}),e(R,[2,45]),{11:tt,63:nt,87:rt,95:319,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},{11:tt,63:nt,87:rt,95:320,108:it,110:263,111:264,112:at,113:ot,114:st,115:ct},e(U,[2,75]),e(R,[2,38]),{6:13,7:14,8:c,9:l,10:u,11:d,12:f,21:20,23:21,24:22,25:23,26:24,27:25,28:p,33:[1,321],35:m,36:h,37:29,38:g,40:_,42:v,45:33,46:44,47:y,48:45,50:46,63:b,87:x,88:S,89:C,90:w,91:T,92:E,105:D,108:O,109:k,112:A,114:j,116:47,117:M,118:N,119:P,124:ee,125:te,126:F,127:I,128:ne},e(G,[2,139],{109:lt}),e(G,[2,140],{109:lt}),e(R,[2,39])],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};ft.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),38;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),40;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return this.pushState(`shapeData`),t.yytext=``,43;case 8:return this.pushState(`shapeDataStr`),43;case 9:return this.popState(),43;case 10:return t.yytext=t.yytext.replace(/\n\s*/g,`
    `),43;case 11:return 43;case 12:this.popState();break;case 13:this.begin(`callbackname`);break;case 14:this.popState();break;case 15:this.popState(),this.begin(`callbackargs`);break;case 16:return 98;case 17:this.popState();break;case 18:return 99;case 19:return`MD_STR`;case 20:this.popState();break;case 21:this.begin(`md_string`);break;case 22:return`STR`;case 23:this.popState();break;case 24:this.pushState(`string`);break;case 25:return 87;case 26:return 105;case 27:return 88;case 28:return 107;case 29:return 89;case 30:return 90;case 31:return 100;case 32:this.begin(`click`);break;case 33:this.popState();break;case 34:return 91;case 35:return e.lex.firstGraph()&&this.begin(`dir`),13;case 36:return 28;case 37:return 36;case 38:return 35;case 39:return 33;case 40:return 101;case 41:return 101;case 42:return 101;case 43:return 101;case 44:return this.popState(),14;case 45:return this.popState(),15;case 46:return this.popState(),15;case 47:return this.popState(),15;case 48:return this.popState(),15;case 49:return this.popState(),15;case 50:return this.popState(),15;case 51:return this.popState(),15;case 52:return this.popState(),15;case 53:return this.popState(),15;case 54:return this.popState(),15;case 55:return 124;case 56:return 125;case 57:return 126;case 58:return 127;case 59:return 128;case 60:return 81;case 61:return 108;case 62:return 114;case 63:return 49;case 64:return 63;case 65:return 47;case 66:return 9;case 67:return 109;case 68:return 118;case 69:return this.popState(),80;case 70:return this.pushState(`edgeText`),78;case 71:return 122;case 72:return 80;case 73:break;case 74:return this.popState(),56;case 75:return`TEXT`;case 76:return this.pushState(`ellipseText`),55;case 77:return this.popState(),58;case 78:return this.pushState(`text`),57;case 79:return this.popState(),60;case 80:return this.pushState(`text`),59;case 81:return 61;case 82:return this.pushState(`text`),70;case 83:return this.popState(),67;case 84:return this.pushState(`text`),66;case 85:return this.popState(),52;case 86:return this.pushState(`text`),51;case 87:break;case 88:return this.popState(),72;case 89:return this.popState(),74;case 90:return 120;case 91:return this.pushState(`trapText`),71;case 92:return this.pushState(`trapText`),73;case 93:return 121;case 94:return 70;case 95:return 93;case 96:return`SEP`;case 97:return 92;case 98:return 118;case 99:return 114;case 100:return 47;case 101:return 8;case 102:return 112;case 103:return 117;case 104:return 119;case 105:return this.popState(),65;case 106:return this.pushState(`text`),65;case 107:return this.popState(),54;case 108:return this.pushState(`text`),53;case 109:return this.popState(),32;case 110:return this.pushState(`text`),30;case 111:return this.popState(),69;case 112:return this.pushState(`text`),68;case 113:break;case 114:return`TEXT`;case 115:return`QUOTE`;case 116:return 10;case 117:return 11;case 118:return 12}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:agentflow-beta\b)/,/^(?:flow\b)/,/^(?:connector\b)/,/^(?:global\b[ \t]*)/,/^(?:end\b[ \t]*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*--+[x>]\s*)/,/^(?:\s*--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*-\.+-\s*)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|(?:[^\\\[\]\(\)\{\}\/%]+|(?!))+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:[ \t]*%%(?!\{)[^\n]*)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:(?:[^\[\]\(\)\{\}\|\"%]+|(?!))+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeData:{rules:[8,11,12,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackargs:{rules:[17,18,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackname:{rules:[14,15,16,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},href:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},click:{rules:[21,24,33,34,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},edgeText:{rules:[21,24,69,71,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},trapText:{rules:[21,24,76,78,80,84,86,87,88,89,90,91,92,106,108,110,112],inclusive:!1},ellipseText:{rules:[21,24,73,74,75,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},text:{rules:[21,24,76,77,78,79,80,83,84,85,86,91,92,105,106,107,108,109,110,111,112,113,114],inclusive:!1},vertex:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr:{rules:[3,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_title:{rules:[1,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},md_string:{rules:[19,20,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},string:{rules:[21,22,23,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,72,76,78,80,81,82,84,86,91,92,93,94,95,96,97,98,99,100,101,102,103,104,106,108,110,112,115,116,117,118],inclusive:!0}}}})();function pt(){this.yy={}}return n(pt,`Parser`),pt.prototype=ft,ft.Parser=pt,new pt})();fe.parser=fe;var pe=fe,me=Object.assign({},pe);me.parse=e=>{let t=e.replace(/}[^\S\n]*\n/g,`} +`);return pe.parse(t)};var he=me,ge=n(e=>{let{theme:t,bkgColorArray:r,borderColorArray:i}=e;if(!y(t,i))return``;let a=x(e.look),o=S(r),s=b(e.THEME_COLOR_LIMIT,i),c=n(e=>i[e%i.length],`border`),l=n(e=>o?`fill: ${r[e%r.length]};`:``,`fill`),u=``;for(let e of B){let t=L.get(e),n=`[data-look="${a}"].node.${z(e)}`;u+=` + + ${n} rect, + ${n} path, + ${n} polygon { + stroke: ${c(t)}; + ${l(t)} + } +`}for(let e=0;e`${r} ${e}, ${i} ${e}`,`rule`);u+=` + + ${o(`rect`)}, + ${o(`path`)} { + stroke: ${c(t)}; + ${l(t)} + } +`}return u},`genColor`),U=n((e,t)=>{let n=g,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return c(r,i,a,t)},`fade`),W={parser:he,get db(){return new ue},renderer:de,styles:n(e=>`${ge(e)} + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}px; + } + .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label { + text-anchor: middle; + } + .node .katex path { + fill: ${e.nodeTextColor||e.textColor}; + stroke: ${e.nodeTextColor||e.textColor}; + stroke-width: 1px; + } + + .rough-node .label,.node .label, .image-shape .label, .icon-shape .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + + .root .anchor path { + fill: ${e.lineColor} !important; + stroke-width: 0; + stroke: ${e.lineColor}; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth??2}px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${U(e.edgeLabelBackground,.5)}; + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .flow-cluster rect { + fill: none; + stroke: ${e.clusterBorder}; + stroke-width: 0.75px; + } + + .node .collapsed-indicator { + fill: ${e.nodeBorder}; + stroke: none; + stroke-width: 0; + opacity: 0.5; + } + + .node .collapsed-separator { + stroke-width: 0.75px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .agentflowTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + + rect.text { + fill: none; + stroke-width: 0; + } + + .icon-shape, .image-shape { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + padding: 2px; + } + .label rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + ${O()} +`,`getStyles`),init:n(e=>{e.agentflow??={},e.layout&&r({layout:e.layout}),e.flowchart??={},e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,r({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}})},`init`)};export{W as diagram}; \ No newline at end of file diff --git a/www/assets/diagram-3UASUU5V-Dv_f5rjj.js b/www/assets/diagram-3UASUU5V-Dv_f5rjj.js new file mode 100644 index 0000000..30cbcb6 --- /dev/null +++ b/www/assets/diagram-3UASUU5V-Dv_f5rjj.js @@ -0,0 +1,24 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as r,H as i,U as a,a as o,b as s,c,f as l,q as u,v as d,w as f,y as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./ordinal-BDEzSJ7C.js";import{t as h}from"./defaultLocale-BFoDCU3G.js";import{i as g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as _,n as v}from"./chunk-7PRAP22T-DSs4vaIy.js";import{y}from"./index-DoQkmpth.js";import{n as b}from"./mermaid-parser.core-CUrDj5TF.js";import{t as x}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as S}from"./chunk-WEXAMYUT-I3m-hOmT.js";function C(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function w(){return this.eachAfter(C)}function T(e,t){let n=-1;for(let r of this)e.call(t,r,++n,this);return this}function E(e,t){for(var n=this,r=[n],i,a,o=-1;n=r.pop();)if(e.call(t,n,++o,this),i=n.children)for(a=i.length-1;a>=0;--a)r.push(i[a]);return this}function D(e,t){for(var n=this,r=[n],i=[],a,o,s,c=-1;n=r.pop();)if(i.push(n),a=n.children)for(o=0,s=a.length;o=0;)n+=r[i].value;t.value=n})}function A(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function j(e){for(var t=this,n=M(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function M(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function N(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function P(){return Array.from(this)}function F(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function I(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*L(){var e=this,t,n=[e],r,i,a;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,a=r.length;i=0;--s)i.push(a=o[s]=new W(o[s])),a.parent=r,a.depth=r.depth+1;return n.eachBefore(U)}function z(){return R(this).eachBefore(H)}function B(e){return e.children}function V(e){return Array.isArray(e)?e[1]:null}function H(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function U(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function W(e){this.data=e,this.depth=this.height=0,this.parent=null}W.prototype=R.prototype={constructor:W,count:w,each:T,eachAfter:D,eachBefore:E,find:O,sum:k,sort:A,path:j,ancestors:N,descendants:P,leaves:F,links:I,copy:z,[Symbol.iterator]:L};function G(e){if(typeof e!=`function`)throw Error();return e}function K(){return 0}function q(e){return function(){return e}}function ee(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function te(e,t,n,r,i){for(var a=e.children,o,s=-1,c=a.length,l=e.value&&(r-t)/e.value;++sv&&(v=l),S=g*g*x,y=Math.max(v/S,S/_),y>b){g-=l;break}b=y}o.push(c={value:g,dice:p1?t:1)},n})(re);function oe(){var e=ae,t=!1,n=1,r=1,i=[0],a=K,o=K,s=K,c=K,l=K;function u(e){return e.x0=e.y0=0,e.x1=n,e.y1=r,e.eachBefore(d),i=[0],t&&e.eachBefore(ee),e}function d(t){var n=i[t.depth],r=t.x0+n,u=t.y0+n,d=t.x1-n,f=t.y1-n;d{v(e)&&(n?.textStyles?n.textStyles.push(e):n.textStyles=[e]),n?.styles?n.styles.push(e):n.styles=[e]}),this.classes.set(e,n)}getClasses(){return this.classes}getStylesForClass(e){return this.classes.get(e)?.styles??[]}clear(){o(),this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.root=void 0}};function Y(e){if(!e.length)return[];let t=[],n=[];return e.forEach(e=>{let r={name:e.name,children:e.type===`Leaf`?void 0:[]};for(r.classSelector=e?.classSelector,e?.cssCompiledStyles&&(r.cssCompiledStyles=e.cssCompiledStyles),e.type===`Leaf`&&e.value!==void 0&&(r.value=e.value);n.length>0&&n[n.length-1].level>=e.level;)n.pop();if(n.length===0)t.push(r);else{let e=n[n.length-1].node;e.children?e.children.push(r):e.children=[r]}e.type!==`Leaf`&&n.push({node:r,level:e.level})}),t}n(Y,`buildHierarchy`);var se=n((e,t)=>{x(e,t);let r=[];for(let n of e.TreemapRows??[])n.$type===`ClassDefStatement`&&t.addClass(n.className??``,n.styleText??``);for(let n of e.TreemapRows??[]){let e=n.item;if(!e)continue;let i=n.indent?parseInt(n.indent):0,a=ce(e),o=e.classSelector?t.getStylesForClass(e.classSelector):[],s=o.length>0?o:void 0,c={level:i,name:a,type:e.$type,value:e.value,classSelector:e.classSelector,cssCompiledStyles:s};r.push(c)}let i=Y(r),a=n((e,n)=>{for(let r of e)t.addNode(r,n),r.children&&r.children.length>0&&a(r.children,n+1)},`addNodesRecursively`);a(i,0)},`populate`),ce=n(e=>e.name?String(e.name):``,`getItemName`),X={parser:{yy:void 0},parse:n(async t=>{try{let n=await b(`treemap`,t);e.debug(`Treemap AST:`,n);let r=X.parser?.yy;if(!(r instanceof J))throw Error(`parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);se(n,r)}catch(t){throw e.error(`Error parsing treemap:`,t),t}},`parse`)},Z=10,Q=10,$=25,le={draw:n((r,i,a,o)=>{let l=o.db,u=l.getConfig(),d=u.padding??Z,f=l.getDiagramTitle(),p=l.getRoot(),{themeVariables:g}=s();if(!p)return;let v=f?30:0,b=y(i),x=u.nodeWidth?u.nodeWidth*Q:960,C=u.nodeHeight?u.nodeHeight*Q:500,w=x,T=C+v;b.attr(`viewBox`,`0 0 ${w} ${T}`),c(b,T,w,u.useMaxWidth);let E;try{let e=u.valueFormat||`,`;if(e===`$0,0`)E=n(e=>`$`+h(`,`)(e),`valueFormat`);else if(e.startsWith(`$`)&&e.includes(`,`)){let t=/\.\d+/.exec(e),r=t?t[0]:``;E=n(e=>`$`+h(`,`+r)(e),`valueFormat`)}else if(e.startsWith(`$`)){let t=e.substring(1);E=n(e=>`$`+h(t||``)(e),`valueFormat`)}else E=h(e)}catch(t){e.error(`Error creating format function:`,t),E=h(`,`)}let D=m().range([`transparent`,g.cScale0,g.cScale1,g.cScale2,g.cScale3,g.cScale4,g.cScale5,g.cScale6,g.cScale7,g.cScale8,g.cScale9,g.cScale10,g.cScale11]),O=m().range([`transparent`,g.cScalePeer0,g.cScalePeer1,g.cScalePeer2,g.cScalePeer3,g.cScalePeer4,g.cScalePeer5,g.cScalePeer6,g.cScalePeer7,g.cScalePeer8,g.cScalePeer9,g.cScalePeer10,g.cScalePeer11]),k=m().range([g.cScaleLabel0,g.cScaleLabel1,g.cScaleLabel2,g.cScaleLabel3,g.cScaleLabel4,g.cScaleLabel5,g.cScaleLabel6,g.cScaleLabel7,g.cScaleLabel8,g.cScaleLabel9,g.cScaleLabel10,g.cScaleLabel11]);f&&b.append(`text`).attr(`x`,w/2).attr(`y`,v/2).attr(`class`,`treemapTitle`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(f);let A=b.append(`g`).attr(`transform`,`translate(0, ${v})`).attr(`class`,`treemapContainer`),j=R(p).sum(e=>e.value??0).sort((e,t)=>(t.value??0)-(e.value??0)),M=oe().size([x,C]).paddingTop(e=>e.children&&e.children.length>0?$+Q:0).paddingInner(d).paddingLeft(e=>e.children&&e.children.length>0?Q:0).paddingRight(e=>e.children&&e.children.length>0?Q:0).paddingBottom(e=>e.children&&e.children.length>0?Q:0).round(!0)(j),N=M.descendants().filter(e=>e.children&&e.children.length>0),P=A.selectAll(`.treemapSection`).data(N).enter().append(`g`).attr(`class`,`treemapSection`).attr(`transform`,e=>`translate(${e.x0},${e.y0})`);P.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,$).attr(`class`,`treemapSectionHeader`).attr(`fill`,`none`).attr(`fill-opacity`,.6).attr(`stroke-width`,.6).attr(`style`,e=>e.depth===0?`display: none;`:``),P.append(`clipPath`).attr(`id`,(e,t)=>`clip-section-${i}-${t}`).append(`rect`).attr(`width`,e=>Math.max(0,e.x1-e.x0-12)).attr(`height`,$),P.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,e=>e.y1-e.y0).attr(`class`,(e,t)=>`treemapSection section${t}`).attr(`fill`,e=>D(e.data.name)).attr(`fill-opacity`,.6).attr(`stroke`,e=>O(e.data.name)).attr(`stroke-width`,2).attr(`stroke-opacity`,.4).attr(`style`,e=>{if(e.depth===0)return`display: none;`;let t=_({cssCompiledStyles:e.data.cssCompiledStyles});return t.nodeStyles+`;`+t.borderStyles.join(`;`)}),P.append(`text`).attr(`class`,`treemapSectionLabel`).attr(`x`,6).attr(`y`,$/2).attr(`dominant-baseline`,`middle`).text(e=>e.depth===0?``:e.data.name).attr(`font-weight`,`bold`).attr(`clip-path`,(e,t)=>`url(#clip-section-${i}-${t})`).attr(`style`,e=>e.depth===0?`display: none;`:`dominant-baseline: middle; font-size: 12px; fill:`+k(e.data.name)+`; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).each(function(e){if(e.depth===0)return;let n=t(this),r=e.data.name;n.text(r);let i=e.x1-e.x0,a;a=u.showValues!==!1&&e.value?i-10-30-10-6:i-6-6;let o=Math.max(15,a),s=n.node();if(s.getComputedTextLength()>o){let e=r;for(;e.length>0;){if(e=r.substring(0,e.length-1),e.length===0){n.text(`...`),s.getComputedTextLength()>o&&n.text(``);break}if(n.text(e+`...`),s.getComputedTextLength()<=o)break}}}),u.showValues!==!1&&P.append(`text`).attr(`class`,`treemapSectionValue`).attr(`x`,e=>e.x1-e.x0-10).attr(`y`,$/2).attr(`text-anchor`,`end`).attr(`dominant-baseline`,`middle`).text(e=>e.value?E(e.value):``).attr(`font-style`,`italic`).attr(`style`,e=>e.depth===0?`display: none;`:`text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:`+k(e.data.name)+`; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`));let F=M.leaves(),I=F.length>20,L=I?16:38,z=I?14:28,B=I?4:8,V=I?4:6,H=I?2:4,U=I?8:10,W=I?1:2,G=A.selectAll(`.treemapLeafGroup`).data(F).enter().append(`g`).attr(`class`,(e,t)=>`treemapNode treemapLeafGroup leaf${t}${e.data.classSelector?` ${e.data.classSelector}`:``}x`).attr(`transform`,e=>`translate(${e.x0},${e.y0})`);G.append(`rect`).attr(`width`,e=>e.x1-e.x0).attr(`height`,e=>e.y1-e.y0).attr(`class`,`treemapLeaf`).attr(`fill`,e=>e.parent?D(e.parent.data.name):D(e.data.name)).attr(`style`,e=>_({cssCompiledStyles:e.data.cssCompiledStyles}).nodeStyles).attr(`fill-opacity`,.3).attr(`stroke`,e=>e.parent?D(e.parent.data.name):D(e.data.name)).attr(`stroke-width`,3),G.append(`clipPath`).attr(`id`,(e,t)=>`clip-${i}-${t}`).append(`rect`).attr(`width`,e=>Math.max(0,e.x1-e.x0-4)).attr(`height`,e=>Math.max(0,e.y1-e.y0-4)),G.append(`text`).attr(`class`,`treemapLabel`).attr(`x`,e=>(e.x1-e.x0)/2).attr(`y`,e=>(e.y1-e.y0)/2).attr(`style`,e=>`text-anchor: middle; dominant-baseline: middle; font-size: ${L}px;fill:`+k(e.data.name)+`;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).attr(`clip-path`,(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.data.name).each(function(e){let n=t(this),r=e.x1-e.x0,i=e.y1-e.y0,a=n.node(),o=r-2*H,s=i-2*H;if(oo&&c>B;)c--,n.style(`font-size`,`${c}px`);let u=Math.max(V,Math.min(z,Math.round(c*l))),d=c+W+u;for(;d>s&&c>B&&(c--,u=Math.max(V,Math.min(z,Math.round(c*l))),!(uo||c(e.x1-e.x0)/2).attr(`y`,function(e){return(e.y1-e.y0)/2}).attr(`style`,e=>`text-anchor: middle; dominant-baseline: hanging; font-size: ${z}px;fill:`+k(e.data.name)+`;`+_({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace(`color:`,`fill:`)).attr(`clip-path`,(e,t)=>`url(#clip-${i}-${t})`).text(e=>e.value?E(e.value):``).each(function(e){let n=t(this),r=this.parentNode;if(!r){n.style(`display`,`none`);return}let i=t(r).select(`.treemapLabel`);if(i.empty()||i.style(`display`)===`none`){n.style(`display`,`none`);return}let a=parseFloat(i.style(`font-size`)),o=Math.max(V,Math.min(z,Math.round(a*.6)));n.style(`font-size`,`${o}px`);let s=(e.y1-e.y0)/2+a/2+W;n.attr(`y`,s);let c=e.x1-e.x0,l=e.y1-e.y0-4,u=c-2*H;n.node().getComputedTextLength()>u||s+o>l||o{let t=r(),n=s(),i=g(t,n.themeVariables),a=g(ue,e),o=a.titleColor??i.titleColor,c=a.labelColor??i.textColor,l=a.valueColor??i.textColor;return` + .treemapNode.section { + stroke: ${a.sectionStrokeColor}; + stroke-width: ${a.sectionStrokeWidth}; + fill: ${a.sectionFillColor}; + } + .treemapNode.leaf { + stroke: ${a.leafStrokeColor}; + stroke-width: ${a.leafStrokeWidth}; + fill: ${a.leafFillColor}; + } + .treemapLabel { + fill: ${c}; + font-size: ${a.labelFontSize}; + } + .treemapValue { + fill: ${l}; + font-size: ${a.valueFontSize}; + } + .treemapTitle { + fill: ${o}; + font-size: ${a.titleFontSize}; + } + `},`getStyles`)};export{de as diagram}; \ No newline at end of file diff --git a/www/assets/diagram-ATOU4E4O-BNgT_lbL.js b/www/assets/diagram-ATOU4E4O-BNgT_lbL.js new file mode 100644 index 0000000..253c2f5 --- /dev/null +++ b/www/assets/diagram-ATOU4E4O-BNgT_lbL.js @@ -0,0 +1,3 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,X as a,a as o,b as s,f as c,q as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{_ as h,i as g,t as ee}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{T as te}from"./chunk-FOHPRMQF-DHwB1DNv.js";import{n as ne}from"./mermaid-parser.core-CUrDj5TF.js";import{t as re}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=`position frame`,v=`frame positioned`,y=`position relation`,b=`relation positioned`,ie=n(function(t){e.debug(`options str`,t)},`setOptions`),ae=n(function(){return{}},`getOptions`),oe=n(function(){x(),o()},`clear`);function x(){S={}}n(x,`reset`);var se=c.eventmodeling,ce=n(()=>g({...se,...s().eventmodeling}),`getConfig`),S={};function C(){let t=le,{ast:n}=S,r=E();if(!n)throw Error(`No data for EventModel`);return n.frames.forEach((i,a)=>{let o=N(i,n.dataEntities,r);t=q(t,{$kind:_,index:a,frame:i,textProps:o});let s;B(i)?(e.debug(`source frame`,i.sourceFrames),s=n.frames.filter(e=>i.sourceFrames.some(t=>t.$refText===e.name)),s.forEach(e=>{t=q(t,{$kind:y,index:a,frame:i,sourceFrame:e})})):t=q(t,{$kind:y,index:a,frame:i})}),t={...t,sortedSwimlanesArray:L(t.swimlanes)},t}n(C,`getState`);function w(e){S.ast=e}n(w,`setAst`);var T={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:`bold`,boxTextPadding:10,swimlaneTextFontWeight:`bold`,labelUiAutomation:`UI/Automation`,labelUiAutomationPrefix:`UI/A: `,labelCommandReadModel:`Command/Read Model`,labelCommandReadModelPrefix:`C/RM: `,labelEvents:`Events`,labelEventsPrefix:`Stream: `};function E(){return T}n(E,`getDiagramProps`);var le={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function D(e){let t=e.split(`.`);if(t.length===2)return t[0]}n(D,`extractNamespace`);function O(e){let t=e.split(`.`);return t.length===2?t[1]:e}n(O,`extractName`);function k(e,t){if(!(!t||t.length===0))return Object.values(e).find(e=>e.namespace===t)}n(k,`findSwimlaneByNamespace`);function A(e,t,n){return Math.max(t,...Object.keys(e).filter(e=>{let r=Number.parseInt(e);return r>t&&rNumber.parseInt(e)))+1}n(A,`findNextAvailableIndex`);function j(e,t){let n=D(e.entityIdentifier),r=k(t,n);switch(e.modelEntityType){case`ui`:case`pcr`:case`processor`:return r?{index:r.index,label:r.namespace||T.labelUiAutomation}:n?{index:A(t,0,100),label:T.labelUiAutomationPrefix+n}:{index:0,label:T.labelUiAutomation};case`rmo`:case`readmodel`:case`cmd`:case`command`:return r?{index:r.index,label:r.namespace||T.labelCommandReadModel}:n?{index:A(t,100,200),label:T.labelCommandReadModelPrefix+n}:{index:100,label:T.labelCommandReadModel};default:return r?{index:r.index,label:r.namespace||T.labelEvents}:n?{index:A(t,200,300),label:T.labelEventsPrefix+n}:{index:200,label:T.labelEvents}}}n(j,`calculateSwimlaneProps`);function M(e){let{themeVariables:t}=s();switch(e.modelEntityType){case`ui`:return{fill:t.emUiFill??`white`,stroke:t.emUiStroke??`#dbdada`};case`pcr`:case`processor`:return{fill:t.emProcessorFill??`#edb3f6`,stroke:t.emProcessorStroke??`#b88cbf`};case`rmo`:case`readmodel`:return{fill:t.emReadModelFill??`#d3f1a2`,stroke:t.emReadModelStroke??`#a3b732`};case`cmd`:case`command`:return{fill:t.emCommandFill??`#bcd6fe`,stroke:t.emCommandStroke??`#679ac3`};case`evt`:case`event`:return{fill:t.emEventFill??`#ffb778`,stroke:t.emEventStroke??`#c19a0f`};default:return{fill:`red`,stroke:`black`}}}n(M,`calculateEntityVisualProps`);function N(t,n,r){let i=s(),a=m(O(t.entityIdentifier)??``,i),o,c={fontSize:16,fontWeight:700,fontFamily:`"trebuchet ms", verdana, arial, sans-serif`,joinWith:`
    `},l=`${h(a,r.textMaxWidth,c)}`;if(t.dataInlineValue&&(o=t.dataInlineValue,o=o.substring(o.indexOf(`{`)+1),o=o.substring(0,o.lastIndexOf(`}`)-1),o=m(o,i),o=h(o,r.textMaxWidth,c),o=o.replaceAll(` `,` `)),t.dataReference){let e=n.find(e=>e.name===t.dataReference?.$refText);e&&(o=e.dataBlockValue,o=o.substring(o.indexOf(`{ +`)+2),o=o.substring(0,o.lastIndexOf(`}`)-1),o=m(o,i),o=h(o,r.textMaxWidth,c),o=o.replaceAll(` `,` `),o+=`
    `)}let u=o!==void 0;u&&(l+=`

    ${o}`);let d={fontSize:c.fontSize,fontWeight:c.fontWeight,fontFamily:c.fontFamily},f=ee(l,d),p=u?f.width/3:f.width,g={content:l,width:p,height:f.height};return e.debug(`[${t.name}] ${t.entityIdentifier} text`,g),g}n(N,`calculateTextProps`);function P(e,t){let n=t,r=M(n.frame),i={width:n.textProps.width+2*T.boxTextPadding,height:n.textProps.height+2*T.boxTextPadding};return[{$kind:v,frame:n.frame,index:n.index,visual:r,dimension:i,textProps:n.textProps}]}n(P,`decidePositionFrame`);function F(e,t,n){return t===void 0?T.contentStartX:t.index===e.index&&e.r?e.r+T.boxPadding:n===void 0?T.contentStartX:n.r-T.boxOverlap+T.boxPadding}n(F,`calculateX`);function I(e,t){let n=[...e.map(e=>e.r),t];return Math.max(...n)}n(I,`calculateMaxRight`);function L(e){return Object.values(e).sort((e,t)=>e.index-t.index)}n(L,`sortedSwimlanesArray`);function R(e,t){let n=t,r=j(n.frame,e.swimlanes),i;i=r.index in e.swimlanes?e.swimlanes[r.index]:{index:r.index,label:r.label,r:0,y:r.index*T.swimlaneMinHeight+T.swimlaneGap,height:T.swimlaneMinHeight,maxHeight:T.swimlaneMinHeight};let a=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,o=e.previousSwimlaneNumber===void 0?void 0:e.swimlanes[e.previousSwimlaneNumber],s={width:Math.max(T.boxMinWidth,Math.min(T.boxMaxWidth,n.dimension.width))+2*T.boxPadding,height:Math.max(T.boxMinHeight,Math.min(T.boxMaxHeight,n.dimension.height))+2*T.boxPadding},c=F(i,o,a),l=c+s.width+T.boxPadding,u=I(Object.values(e.swimlanes),l);i.r=c+s.width,i.maxHeight=Math.max(i.maxHeight,s.height),i.height=Math.max(T.swimlaneMinHeight,i.maxHeight)+2*T.swimlanePadding;let d={x:c,y:T.swimlanePadding+i.y,r:l,dimension:s,leftSibling:!1,swimlane:i,visual:n.visual,text:n.textProps.content,frame:n.frame,index:n.index},f={...e,boxes:[...e.boxes,d],swimlanes:{...e.swimlanes,[`${i.index}`]:i},previousSwimlaneNumber:r.index,previousFrame:n.frame,maxR:u},p=L(f.swimlanes);p.length>0&&(p[0].y=0);for(let e=1;e0}n(B,`hasSourceFrame`);function V(e,t){if(t!=null)return e.find(e=>e.frame.name===t.name)}n(V,`findBoxByFrame`);function H(e,t,n){if(!(n<0))for(let r=n;r>=0;r--){let n=e[r];if(n.swimlane.index!==t)return n}}n(H,`findBoxByLineIndex`);function U(e,t){let n=t;if(te(n.frame)||z(n.index,n.frame))return[];let r=V(e.boxes,n.frame);if(r===void 0)throw Error(`Target box not found for frame ${n.frame.name}`);let i;return i=n.sourceFrame?V(e.boxes,n.sourceFrame):H(e.boxes,r.swimlane.index,n.index-1),i===void 0?[]:[{$kind:b,frame:n.frame,index:n.index,sourceBox:i,targetBox:r}]}n(U,`decidePositionRelation`);function W(e,t){let n=t,r={visual:{fill:`none`,stroke:`#000`},source:{x:n.sourceBox.x,y:n.sourceBox.y},target:{x:n.targetBox.x,y:n.targetBox.y},sourceBox:n.sourceBox,targetBox:n.targetBox};return{...e,relations:[...e.relations,r]}}n(W,`evolveRelationPositioned`);var ue={[_]:P,[y]:U},de={[v]:R,[b]:W};function G(t,n){let r=ue[n.$kind];if(r==null)return[];let i=r(t,n);return e.debug(`decided events`,i),i}n(G,`decide`);function K(t,n){let r=n.reduce((e,t)=>{let n=de[t.$kind];return n==null?e:n(e,t)},t);return e.debug(`evolve events`,{state:t,newState:r,events:n}),r}n(K,`evolve`);function q(e,t){return K(e,G(e,t))}n(q,`dispatch`);var J={getConfig:ce,setOptions:ie,getOptions:ae,clear:oe,setAccTitle:i,getAccTitle:p,getAccDescription:u,setAccDescription:r,setDiagramTitle:l,getDiagramTitle:d,setAst:w,getDiagramProps:E,getState:C},fe={parse:n(async t=>{let n=await ne(`eventmodeling`,t);e.debug(n),J.setAst(n),re(n,J)},`parse`)},Y=f()?.eventmodeling;function X(e,t){return n=>{let r=n.swimlane.y+t.swimlanePadding,i=e.append(`g`).attr(`class`,`em-box`);i.append(`rect`).attr(`x`,n.x).attr(`y`,r).attr(`rx`,`3`).attr(`width`,n.dimension.width).attr(`height`,n.dimension.height).attr(`stroke`,n.visual.stroke).attr(`fill`,n.visual.fill),i.append(`foreignObject`).attr(`x`,n.x+t.boxPadding).attr(`y`,r+10).attr(`width`,n.dimension.width-2*t.boxPadding).attr(`height`,n.dimension.height-2*t.boxPadding).append(`xhtml:div`).style(`display`,`table`).style(`height`,`100%`).style(`width`,`100%`).append(`span`).style(`display`,`table-cell`).style(`text-align`,`center`).style(`vertical-align`,`middle`).html(n.text)}}n(X,`renderD3Box`);function Z(e,t){return e>t}n(Z,`dirUpwards`);function Q(t,n,r,i){return a=>{let o=a.sourceBox.swimlane.y+n.swimlanePadding,s=a.targetBox.swimlane.y+n.swimlanePadding,c=Z(o,s),l=a.sourceBox.x+a.sourceBox.dimension.width*2/3,u=a.targetBox.x+a.targetBox.dimension.width/3,d,f;e.debug(`rendering relation up=${c} for `,{sourceBox:a.sourceBox,targetBox:a.targetBox}),c?(d=o,f=s+a.targetBox.dimension.height):(d=o+a.sourceBox.dimension.height,f=s);let p=i.emRelationStroke??a.visual.stroke;t.append(`path`).attr(`class`,`em-relation`).attr(`fill`,a.visual.fill).attr(`stroke`,p).attr(`stroke-width`,`1`).attr(`marker-end`,`url(#${r})`).attr(`d`,`M${l} ${d} L${u} ${f}`)}}n(Q,`renderD3Relation`);function $(e,t,n,r){return i=>{let a=e.append(`g`).attr(`class`,`em-swimlane`),o=r.emSwimlaneBackgroundOdd??`rgb(250,250,250)`,s=r.emSwimlaneBackgroundStroke??`rgb(240,240,240)`;a.append(`rect`).attr(`x`,0).attr(`y`,i.y).attr(`rx`,`3`).attr(`width`,t+n.swimlanePadding).attr(`height`,i.height).attr(`fill`,o).attr(`stroke`,s),a.append(`text`).attr(`font-weight`,n.swimlaneTextFontWeight).attr(`x`,30).attr(`y`,i.y+30).text(i.label)}}n($,`renderD3Swimlane`);var pe={parser:fe,db:J,renderer:{draw:n(function(n,r,i,o){if(e.debug(`in eventmodeling renderer`,n+` +`,`id:`,r,i),!Y)throw Error(`EventModeling config not found`);let s=o.db,{themeVariables:c,eventmodeling:l}=f(),u=t(`[id="${r}"]`),d=s.getDiagramProps(),p=s.getState(),m=`em-arrowhead-${r}`,h=c.emArrowhead??`#000000`;p.sortedSwimlanesArray.forEach($(u,p.maxR,d,c)),p.boxes.forEach(X(u,d)),p.relations.forEach(Q(u,d,m,c)),u.append(`defs`).append(`marker`).attr(`id`,m).attr(`markerWidth`,`10`).attr(`markerHeight`,`7`).attr(`refX`,`10`).attr(`refY`,`3.5`).attr(`orient`,`auto`).append(`polygon`).attr(`points`,`0 0, 10 3.5, 0 7`).attr(`fill`,h),a(void 0,u,l?.padding??30,l?.useMaxWidth)},`draw`)},styles:n(e=>``,`getStyles`)};export{pe as diagram}; \ No newline at end of file diff --git a/www/assets/diagram-CDSNMT55-DcWw9GHj.js b/www/assets/diagram-CDSNMT55-DcWw9GHj.js new file mode 100644 index 0000000..a4a4aea --- /dev/null +++ b/www/assets/diagram-CDSNMT55-DcWw9GHj.js @@ -0,0 +1,30 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,b as a,c as o,f as s,q as c,v as l,w as u,y as d,z as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{r as m,t as h}from"./chunk-742MDFTN-5mFByRwZ.js";import{y as g}from"./index-DoQkmpth.js";import{n as _}from"./mermaid-parser.core-CUrDj5TF.js";import{t as v}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as y}from"./chunk-2Q5K7J3B-C1jixKkw.js";var b=/[─━│┃└┗├┣]/,x=/[└┗├┣]/,S=/[─━]/,C=/^[\s│┃]+$/,w=/^\s*(title[\t ]|accTitle[\t ]*:|accDescr[\t ]*[:{])/,T=/^\s*%%/,E=` `;function D(e){return e.some(e=>b.test(e))}t(D,`isBoxDrawingFormat`);function O(e){for(let t of e){let e=x.exec(t);if(e?.index&&e.index>0)return e.index}return 4}t(O,`inferSegmentWidth`);function k(e,t){return e.replace(/\bline\s+(\d+)\b/gi,(e,n)=>{let r=parseInt(n,10),i=t.get(r);return i?`line ${i}`:e})}t(k,`remapErrorLines`);function A(e){let t=e.split(` +`),n=new Map,r=-1;for(let[e,n]of t.entries())if(n.trim()===`treeView-beta`){r=e;break}if(r===-1)return{text:e,lineMap:n};let i=[];for(let e=r+1;e({cnt:1,stack:[{id:0,level:-1,name:`/`,nodeType:`directory`,children:[]}]})),M=t(()=>{j.reset(),i()},`clear`),N=t(()=>j.records.stack[0],`getRoot`),P=t(()=>j.records.cnt,`getCount`),F=s.treeView,I={clear:M,addNode:t((e,t,n,r,i,a)=>{for(;e<=j.records.stack[j.records.stack.length-1].level;)j.records.stack.pop();let o={id:j.records.cnt++,level:e,name:t,nodeType:n,icon:i,cssClass:r,description:a,children:[]};j.records.stack[j.records.stack.length-1].children.push(o),j.records.stack.push(o)},`addNode`),getRoot:N,getCount:P,getConfig:t(()=>p(F,a().treeView),`getConfig`),getAccTitle:d,getAccDescription:l,getDiagramTitle:u,setAccDescription:n,setAccTitle:r,setDiagramTitle:c},L=t(e=>{v(e,I);for(let t of e.nodes){let e=typeof t.indent==`number`?t.indent:0,n=t.name,r=n.endsWith(`/`);r&&(n=n.slice(0,-1));let i=r?`directory`:`file`,o=t.classAnnotation||void 0,s=t.iconAnnotation,c=s===void 0?void 0:s||`none`,l=t.descAnnotation||void 0,u=l?f(l,a()):void 0;I.addNode(e,n,i,o,c,u)}},`populate`),R={parse:t(async t=>{let{text:n,lineMap:r}=A(t);try{let t=await _(`treeView`,n);e.debug(t),L(t)}catch(e){throw r.size>0&&e instanceof Error&&(e.message=k(e.message,r)),e}},`parse`)},z={prefix:`mermaid-treeview`,height:24,width:24,icons:{folder:{body:``},file:{body:``}}};function B(e,t){let n=t?.filenameIcons?.[e];if(n)return n;let r=e.lastIndexOf(`.`);if(r>0){let n=e.substring(r).toLowerCase(),i=t?.extensionIcons;return i?.[n]??i?.[n.slice(1)]}}t(B,`detectIcon`);function V(e,t){return e.includes(`:`)?e:e in z.icons||!t?`${z.prefix}:${e}`:`${t}:${e}`}t(V,`qualifyIcon`);function H(e,t){if(e.icon!==`none`){if(e.icon)return V(e.icon,t.defaultIconPack);if(t.showIcons){if(e.nodeType===`file`){let n=B(e.name,t);if(n===`none`)return;if(n)return V(n,t.defaultIconPack)}return`${z.prefix}:${e.nodeType===`directory`?`folder`:`file`}`}}}t(H,`getNodeIcon`),m([{name:z.prefix,icons:z}]);var U=14,W=4,G=16,K=t(async(e,n)=>{let r=[],i=t(e=>{let t=H(e,n);t&&r.push({icon:t,node:e}),e.children.forEach(i)},`collect`);i(e);let a=await Promise.all(r.map(async({icon:e,node:t})=>({id:t.id,svg:await h(e,{height:U,width:U})})));return new Map(a.map(({id:e,svg:t})=>[e,t]))},`resolveNodeIcons`),q=t((e,t,n,r,i,a)=>{let o=r.append(`g`),s=`treeView-node-label`;n.nodeType===`directory`&&(s+=` treeView-node-dir`),n.cssClass&&(s+=` ${n.cssClass}`);let c=U+W,l=H(n,i),u=l!==void 0;l&&o.append(`g`).attr(`class`,`treeView-node-icon`).attr(`transform`,`translate(${e+i.paddingX}, ${t+i.paddingY})`).html(a.get(n.id)??``);let d=o.append(`text`).text(n.name).attr(`dominant-baseline`,`middle`).attr(`class`,s),{height:f,width:p}=d.node().getBBox(),m=f+i.paddingY*2,h=e+i.paddingX+(u?c:0);d.attr(`x`,h),d.attr(`y`,t+m/2);let g=h+p;return n.BBox={x:e,y:t,width:p+i.paddingX*2+(u?c:0),height:m},n.cssClass?.split(/\s+/).includes(`highlight`)&&o.insert(`rect`,`:first-child`).attr(`x`,e).attr(`y`,t+1).attr(`width`,0).attr(`height`,m-2).attr(`rx`,3).attr(`class`,`treeView-highlight-bg`),{node:n,nodeGroup:o,labelRightEdge:g,centerY:t+m/2}},`positionLabel`),J=t((e,t,n,r,i,a)=>e.append(`line`).attr(`x1`,t).attr(`y1`,n).attr(`x2`,r).attr(`y2`,i).attr(`stroke-width`,a).attr(`class`,`treeView-node-line`),`positionLine`),Y=t((e,n,r,i)=>{let a=0,o=0,s=[],c=t((e,t,n,r)=>{let c=r*(n.rowIndent+n.paddingX),l=q(c,a,t,e,n,i);s.push(l);let{height:u,width:d}=t.BBox;J(e,c-n.rowIndent,a+u/2,c,a+u/2,n.lineThickness),o=Math.max(o,c+d),a+=u},`drawNode`),l=t((t,n=0)=>{c(e,t,r,n),t.children.forEach(e=>{l(e,n+1)});let{x:i,y:a,height:o}=t.BBox;if(t.children.length){let{y:n,height:s}=t.children[t.children.length-1].BBox;J(e,i+r.paddingX,a+o,i+r.paddingX,n+s/2+r.lineThickness/2,r.lineThickness)}},`processNode`);l(n);let u=s.filter(e=>e.node.description);if(u.length>0){let e=Math.max(...s.map(e=>e.labelRightEdge))+G;for(let t of u){let n=t.nodeGroup.append(`text`).text(t.node.description).attr(`dominant-baseline`,`middle`).attr(`class`,`treeView-node-description`).attr(`x`,e).attr(`y`,t.centerY).node().getBBox();o=Math.max(o,e+n.width+r.paddingX)}}for(let e of s)if(e.node.cssClass?.split(/\s+/).includes(`highlight`)){let t=e.nodeGroup.select(`.treeView-highlight-bg`);if(!t.empty()){let n=o-e.node.BBox.x+8;t.attr(`width`,n),o=Math.max(o,e.node.BBox.x+n+2)}}return{totalHeight:a,totalWidth:o}},`drawTree`),X={draw:t(async(t,n,r,i)=>{e.debug(`Rendering treeView diagram +`+t);let a=i.db,s=a.getRoot(),c=a.getConfig(),l=g(n),u=l.append(`g`);u.attr(`class`,`tree-view`);let{totalHeight:d,totalWidth:f}=Y(u,s,c,await K(s,c));l.attr(`viewBox`,`-${c.lineThickness/2} 0 ${f} ${d}`),o(l,d,f,c.useMaxWidth)},`draw`)},Z={labelFontSize:`16px`,labelColor:`black`,lineColor:`black`,iconColor:`#546e7a`,descriptionColor:`#6a9955`,highlightBg:`rgba(255, 193, 7, 0.15)`,highlightStroke:`#ffc107`},Q={db:I,renderer:X,parser:R,styles:t(({treeView:e})=>{let{labelFontSize:t,labelColor:n,lineColor:r,iconColor:i,descriptionColor:a,highlightBg:o,highlightStroke:s}=p(Z,e);return` + .treeView-node-label { + font-size: ${t}; + fill: ${n}; + white-space: pre; + } + .treeView-node-dir { + font-weight: bold; + } + .treeView-node-line { + stroke: ${r}; + } + .treeView-node-icon { + color: ${i}; + } + .treeView-node-description { + font-size: ${t}; + fill: ${a}; + font-style: italic; + white-space: pre; + } + .treeView-highlight-bg { + fill: ${o}; + stroke: ${s}; + stroke-width: 1; + } + `},`styles`)};export{Q as diagram}; \ No newline at end of file diff --git a/www/assets/diagram-MLGK6HIB-DILal1CA.js b/www/assets/diagram-MLGK6HIB-DILal1CA.js new file mode 100644 index 0000000..9ef5457 --- /dev/null +++ b/www/assets/diagram-MLGK6HIB-DILal1CA.js @@ -0,0 +1,24 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,b as a,c as o,f as s,q as c,v as l,w as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as f}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as p}from"./index-DoQkmpth.js";import{n as m}from"./mermaid-parser.core-CUrDj5TF.js";import{t as h}from"./chunk-JWPE2WC7-DVXcaiue.js";var g=s.packet,_=class{constructor(){this.packet=[],this.setAccTitle=r,this.getAccTitle=d,this.setDiagramTitle=c,this.getDiagramTitle=u,this.getAccDescription=l,this.setAccDescription=n}static{t(this,`PacketDB`)}getConfig(){let e=f({...g,...a().packet});return e.showBits&&(e.paddingY+=10),e}getPacket(){return this.packet}pushWord(e){e.length>0&&this.packet.push(e)}clear(){i(),this.packet=[]}},v=1e4,y=t((t,n)=>{h(t,n);let r=-1,i=[],a=1,{bitsPerRow:o}=n.getConfig();for(let{start:s,end:c,bits:l,label:u}of t.blocks){if(s!==void 0&&c!==void 0&&c{if(e.start===void 0)throw Error(`start should have been set during first phase`);if(e.end===void 0)throw Error(`end should have been set during first phase`);if(e.start>e.end)throw Error(`Block start ${e.start} is greater than block end ${e.end}.`);if(e.end+1<=t*n)return[e,void 0];let r=t*n-1,i=t*n;return[{start:e.start,end:r,label:e.label,bits:r-e.start},{start:i,end:e.end,label:e.label,bits:e.end-i}]},`getNextFittingBlock`),x={parser:{yy:void 0},parse:t(async t=>{let n=await m(`packet`,t),r=x.parser?.yy;if(!(r instanceof _))throw Error(`parser.parser?.yy was not a PacketDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);e.debug(n),y(n,r)},`parse`)},S=t((e,t,n,r)=>{let i=r.db,a=i.getConfig(),{rowHeight:s,paddingY:c,bitWidth:l,bitsPerRow:u}=a,d=i.getPacket(),f=i.getDiagramTitle(),m=s+c,h=m*(d.length+1)-(f?0:s),g=l*u+2,_=p(t);_.attr(`viewBox`,`0 0 ${g} ${h}`),o(_,h,g,a.useMaxWidth);for(let[e,t]of d.entries())C(_,t,e,a);_.append(`text`).text(f).attr(`x`,g/2).attr(`y`,h-m/2).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).attr(`class`,`packetTitle`)},`draw`),C=t((e,t,n,{rowHeight:r,paddingX:i,paddingY:a,bitWidth:o,bitsPerRow:s,showBits:c})=>{let l=e.append(`g`),u=n*(r+a)+a;for(let e of t){let t=e.start%s*o+1,n=(e.end-e.start+1)*o-i;if(l.append(`rect`).attr(`x`,t).attr(`y`,u).attr(`width`,n).attr(`height`,r).attr(`class`,`packetBlock`),l.append(`text`).attr(`x`,t+n/2).attr(`y`,u+r/2).attr(`class`,`packetLabel`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).text(e.label),!c)continue;let a=e.end===e.start,d=u-2;l.append(`text`).attr(`x`,t+(a?n/2:0)).attr(`y`,d).attr(`class`,`packetByte start`).attr(`dominant-baseline`,`auto`).attr(`text-anchor`,a?`middle`:`start`).text(e.start),a||l.append(`text`).attr(`x`,t+n).attr(`y`,d).attr(`class`,`packetByte end`).attr(`dominant-baseline`,`auto`).attr(`text-anchor`,`end`).text(e.end)}},`drawWord`),w={draw:S},T={byteFontSize:`10px`,startByteColor:`black`,endByteColor:`black`,labelColor:`black`,labelFontSize:`12px`,titleColor:`black`,titleFontSize:`14px`,blockStrokeColor:`black`,blockStrokeWidth:`1`,blockFillColor:`#efefef`},E={parser:x,get db(){return new _},renderer:w,styles:t(({packet:e}={})=>{let t=f(T,e);return` + .packetByte { + font-size: ${t.byteFontSize}; + } + .packetByte.start { + fill: ${t.startByteColor}; + } + .packetByte.end { + fill: ${t.endByteColor}; + } + .packetLabel { + fill: ${t.labelColor}; + font-size: ${t.labelFontSize}; + } + .packetTitle { + fill: ${t.titleColor}; + font-size: ${t.titleFontSize}; + } + .packetBlock { + stroke: ${t.blockStrokeColor}; + stroke-width: ${t.blockStrokeWidth}; + fill: ${t.blockFillColor}; + } + `},`styles`)};export{E as diagram}; \ No newline at end of file diff --git a/www/assets/diagram-MPIPVDR6-8w_EEv4v.js b/www/assets/diagram-MPIPVDR6-8w_EEv4v.js new file mode 100644 index 0000000..379ca46 --- /dev/null +++ b/www/assets/diagram-MPIPVDR6-8w_EEv4v.js @@ -0,0 +1,41 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _={showLegend:!0,ticks:5,max:null,min:0,graticule:`circle`},v=32,y={axes:[],curves:[],options:_},b=structuredClone(y),x=c.radar,S=t(()=>p({...x,...o().radar}),`getConfig`),C=t(()=>b.axes,`getAxes`),w=t(()=>b.curves,`getCurves`),T=t(()=>b.options,`getOptions`),E=t(e=>{b.axes=e.map(e=>({name:e.name,label:e.label??e.name}))},`setAxes`),D=t(e=>{b.curves=e.map(e=>({name:e.name,label:e.label??e.name,entries:O(e.entries)}))},`setCurves`),O=t(e=>{if(e[0].axis==null)return e.map(e=>e.value);let t=C();if(t.length===0)throw Error(`Axes must be populated before curves for reference entries`);return t.map(t=>{let n=e.find(e=>e.axis?.$refText===t.name);if(n===void 0)throw Error(`Missing entry for axis `+t.label);return n.value})},`computeCurveEntries`),k={getAxes:C,getCurves:w,getOptions:T,setAxes:E,setCurves:D,setOptions:t(t=>{let n=t.reduce((e,t)=>(e[t.name]=t,e),{});b.options={showLegend:n.showLegend?.value??_.showLegend,ticks:n.ticks?.value??_.ticks,max:n.max?.value??_.max,min:n.min?.value??_.min,graticule:n.graticule?.value??_.graticule},b.options.ticks>v&&(e.warn(`Radar diagram ticks (${b.options.ticks}) exceeds maximum allowed (${v}). Using ${v} instead.`),b.options.ticks=v)},`setOptions`),getConfig:S,clear:t(()=>{a(),b=structuredClone(y)},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r},A=t(e=>{g(e,k);let{axes:t,curves:n,options:r}=e;k.setAxes(t),k.setCurves(n),k.setOptions(r)},`populate`),j={parse:t(async t=>{let n=await h(`radar`,t);e.debug(n),A(n)},`parse`)},M=t((e,t,n,r)=>{let i=r.db,a=i.getAxes(),o=i.getCurves(),s=i.getOptions(),c=i.getConfig(),l=i.getDiagramTitle(),u=N(m(t),c),d=s.max??Math.max(...o.map(e=>Math.max(...e.entries))),f=s.min,p=Math.min(c.width,c.height)/2;P(u,a,p,s.ticks,s.graticule),F(u,a,p,c),I(u,a,o,f,d,s.graticule,c),z(u,o,s.showLegend,c),u.append(`text`).attr(`class`,`radarTitle`).text(l).attr(`x`,0).attr(`y`,-c.height/2-c.marginTop)},`draw`),N=t((e,t)=>{let n=t.width+t.marginLeft+t.marginRight,r=t.height+t.marginTop+t.marginBottom,i={x:t.marginLeft+t.width/2,y:t.marginTop+t.height/2};return s(e,r,n,t.useMaxWidth??!0),e.attr(`viewBox`,`0 0 ${n} ${r}`).attr(`overflow`,`visible`),e.append(`g`).attr(`transform`,`translate(${i.x}, ${i.y})`)},`drawFrame`),P=t((e,t,n,r,i)=>{if(i===`circle`)for(let t=0;t{let n=2*t*Math.PI/i-Math.PI/2;return`${o*Math.cos(n)},${o*Math.sin(n)}`}).join(` `);e.append(`polygon`).attr(`points`,s).attr(`class`,`radarGraticule`)}}},`drawGraticule`),F=t((e,t,n,r)=>{let i=t.length;for(let a=0;a.01?`start`:c<-.01?`end`:`middle`,d=l>.01?`hanging`:l<-.01?`auto`:`central`;e.append(`text`).text(o).attr(`x`,n*r.axisLabelFactor*c+4*c).attr(`y`,n*r.axisLabelFactor*l+4*l).attr(`text-anchor`,u).attr(`dominant-baseline`,d).attr(`class`,`radarAxisLabel`)}},`drawAxes`);function I(e,t,n,r,i,a,o){let s=t.length,c=Math.min(o.width,o.height)/2;n.forEach((t,n)=>{if(t.entries.length!==s)return;let l=t.entries.map((e,t)=>{let n=2*Math.PI*t/s-Math.PI/2,a=L(e,r,i,c);return{x:a*Math.cos(n),y:a*Math.sin(n)}});a===`circle`?e.append(`path`).attr(`d`,R(l,o.curveTension)).attr(`class`,`radarCurve-${n}`):a===`polygon`&&e.append(`polygon`).attr(`points`,l.map(e=>`${e.x},${e.y}`).join(` `)).attr(`class`,`radarCurve-${n}`)})}t(I,`drawCurves`);function L(e,t,n,r){return r*(Math.min(Math.max(e,t),n)-t)/(n-t)}t(L,`relativeRadius`);function R(e,t){let n=e.length,r=`M${e[0].x},${e[0].y}`;for(let i=0;i{let r=e.append(`g`).attr(`transform`,`translate(${i}, ${a+n*20})`);r.append(`rect`).attr(`width`,12).attr(`height`,12).attr(`class`,`radarLegendBox-${n}`),r.append(`text`).attr(`x`,16).attr(`y`,0).attr(`class`,`radarLegendText`).text(t.label)})}t(z,`drawLegend`);var B={draw:M},V=t((e,t)=>{let n=``;for(let r=0;r{let t=n(),r=o(),i=p(t,r.themeVariables);return{themeVariables:i,radarOptions:p(i.radar,e)}},`buildRadarStyleOptions`),U={parser:j,db:k,renderer:B,styles:t(({radar:e}={})=>{let{themeVariables:t,radarOptions:n}=H(e);return` + .radarTitle { + font-size: ${t.fontSize}; + color: ${t.titleColor}; + dominant-baseline: hanging; + text-anchor: middle; + } + .radarAxisLine { + stroke: ${n.axisColor}; + stroke-width: ${n.axisStrokeWidth}; + } + .radarAxisLabel { + font-size: ${n.axisLabelFontSize}px; + color: ${n.axisColor}; + } + .radarGraticule { + fill: ${n.graticuleColor}; + fill-opacity: ${n.graticuleOpacity}; + stroke: ${n.graticuleColor}; + stroke-width: ${n.graticuleStrokeWidth}; + } + .radarLegendText { + text-anchor: start; + font-size: ${n.legendFontSize}px; + dominant-baseline: hanging; + } + ${V(t,n)} + `},`styles`)};export{U as diagram}; \ No newline at end of file diff --git a/www/assets/dist-Bfr8PhAA.js b/www/assets/dist-Bfr8PhAA.js new file mode 100644 index 0000000..ca70aba --- /dev/null +++ b/www/assets/dist-Bfr8PhAA.js @@ -0,0 +1 @@ +import{_ as e}from"./src-D_iIdUkB.js";var t=Math.abs,n=Math.atan2,r=Math.cos,i=Math.max,a=Math.min,o=Math.sin,s=Math.sqrt,c=1e-12,l=Math.PI,u=l/2,d=2*l;function f(e){return e>1?0:e<-1?l:Math.acos(e)}function p(e){return e>=1?u:e<=-1?-u:Math.asin(e)}var m=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.BLANK_URL=e.relativeFirstCharacters=e.whitespaceEscapeCharsRegex=e.urlSchemeRegex=e.ctrlCharactersRegex=e.htmlCtrlEntityRegex=e.htmlEntitiesRegex=e.invalidProtocolRegex=void 0,e.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,e.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,e.htmlCtrlEntityRegex=/&(newline|tab);/gi,e.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,e.urlSchemeRegex=/^.+(:|:)/gim,e.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,e.relativeFirstCharacters=[`.`,`/`],e.BLANK_URL=`about:blank`})),h=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.sanitizeUrl=o;var t=m();function n(e){return t.relativeFirstCharacters.indexOf(e[0])>-1}function r(e){return e.replace(t.ctrlCharactersRegex,``).replace(t.htmlEntitiesRegex,function(e,t){return String.fromCharCode(t)})}function i(e){return URL.canParse(e)}function a(e){try{return decodeURIComponent(e)}catch{return e}}function o(e){if(!e)return t.BLANK_URL;var o,s=a(e.trim());do s=r(s).replace(t.htmlCtrlEntityRegex,``).replace(t.ctrlCharactersRegex,``).replace(t.whitespaceEscapeCharsRegex,``).trim(),s=a(s),o=s.match(t.ctrlCharactersRegex)||s.match(t.htmlEntitiesRegex)||s.match(t.htmlCtrlEntityRegex)||s.match(t.whitespaceEscapeCharsRegex);while(o&&o.length>0);var c=s;if(!c)return t.BLANK_URL;if(n(c))return c;var l=c.trimStart(),u=l.match(t.urlSchemeRegex);if(!u)return c;var d=u[0].toLowerCase().trim();if(t.invalidProtocolRegex.test(d))return t.BLANK_URL;var f=l.replace(/\\/g,`/`);if(d===`mailto:`||d.includes(`://`))return f;if(d===`http:`||d===`https:`){if(!i(f))return t.BLANK_URL;var p=new URL(f);return p.protocol=p.protocol.toLowerCase(),p.hostname=p.hostname.toLowerCase(),p.toString()}return f}}));export{n as a,u as c,l as d,o as f,p as i,i as l,d as m,t as n,r as o,s as p,f as r,c as s,h as t,a as u}; \ No newline at end of file diff --git a/www/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js b/www/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js new file mode 100644 index 0000000..004edd5 --- /dev/null +++ b/www/assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{f as n,t as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=n().RailroadEbnf.parser.LangiumParser,l=t(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformChoice`),u=t(e=>{let t=e.elements.map(p);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformSequence`),d=t(e=>{switch(e.$type){case`EbnfTerminal`:return{type:`terminal`,value:e.value};case`EbnfNonTerminal`:return{type:`nonterminal`,name:e.name};case`EbnfSpecial`:return{type:`special`,text:e.text};case`EbnfGroup`:return l(e.element);case`EbnfOptional`:return{type:`optional`,element:l(e.element)};case`EbnfRepetition`:return{type:`repetition`,element:l(e.element),min:0,max:1/0};default:throw Error(`Unsupported EBNF primary node: ${e.$type}`)}},`transformPrimary`),f=t((e,t)=>{switch(t.$type){case`EbnfOptionalPostfix`:return{type:`optional`,element:e};case`EbnfZeroOrMorePostfix`:return{type:`repetition`,element:e,min:0,max:1/0};case`EbnfOneOrMorePostfix`:return{type:`repetition`,element:e,min:1,max:1/0};case`EbnfExceptionPostfix`:return{type:`sequence`,elements:[e,{type:`terminal`,value:`-`},d(t.except)]};default:throw Error(`Unsupported EBNF postfix node: ${t.$type}`)}},`transformPostfix`),p=t(e=>e.postfixes.reduce((e,t)=>f(e,t),d(e.base)),`transformTerm`),m=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:t(t=>{o.clear(),e.debug(`[EBNF Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[EBNF Parser] Parsed rules:`,i.rules.length),h(i),e.debug(`[EBNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram}; \ No newline at end of file diff --git a/www/assets/elk-276RUBZZ-On_DNuCd.js b/www/assets/elk-276RUBZZ-On_DNuCd.js new file mode 100644 index 0000000..b744b05 --- /dev/null +++ b/www/assets/elk-276RUBZZ-On_DNuCd.js @@ -0,0 +1,27 @@ +import{_ as e,v as t,y as n}from"./src-D_iIdUkB.js";import{n as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{G as i}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{rt as a}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{c as o,l as s,m as c}from"./index-DoQkmpth.js";import{a as l,r as u}from"./chunk-3FUC2YCW-CmoZ3fbX.js";import{t as d}from"./chunk-NETBCI7D-Br7cqgBT.js";var f=n(e(((e,n)=>{(function(t){if(typeof e==`object`&&n!==void 0)n.exports=t();else if(typeof define==`function`&&define.amd)define([],t);else{var r=typeof window<`u`?window:typeof global<`u`?global:typeof self<`u`?self:this;r.ELK=t()}})(function(){return(function(){function e(n,r,i){function a(s,c){if(!r[s]){if(!n[s]){var l=typeof t==`function`&&t;if(!c&&l)return l(s,!0);if(o)return o(s,!0);var u=Error(`Cannot find module '`+s+`'`);throw u.code=`MODULE_NOT_FOUND`,u}var d=r[s]={exports:{}};n[s][0].call(d.exports,function(e){var t=n[s][1][e];return a(t||e)},d,d.exports,e,n,r,i)}return r[s].exports}for(var o=typeof t==`function`&&t,s=0;s0&&arguments[0]!==void 0?arguments[0]:{},r=n.defaultLayoutOptions,o=r===void 0?{}:r,s=n.algorithms,c=s===void 0?[`layered`,`stress`,`mrtree`,`radial`,`force`,`disco`,`sporeOverlap`,`sporeCompaction`,`rectpacking`]:s,l=n.workerFactory,u=n.workerUrl;if(i(this,e),this.defaultLayoutOptions=o,this.initialized=!1,u===void 0&&l===void 0)throw Error(`Cannot construct an ELK without both 'workerUrl' and 'workerFactory'.`);var d=l;u!==void 0&&l===void 0&&(d=function(e){return new Worker(e)});var f=d(u);if(typeof f.postMessage!=`function`)throw TypeError(`Created worker does not provide the required 'postMessage' function.`);this.worker=new a(f),this.worker.postMessage({cmd:`register`,algorithms:c}).then(function(e){return t.initialized=!0}).catch(console.err)}return r(e,[{key:`layout`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.layoutOptions,r=n===void 0?this.defaultLayoutOptions:n,i=t.logging,a=i!==void 0&&i,o=t.measureExecutionTime,s=o!==void 0&&o;return e?this.worker.postMessage({cmd:`layout`,graph:e,layoutOptions:r,options:{logging:a,measureExecutionTime:s}}):Promise.reject(Error(`Missing mandatory parameter 'graph'.`))}},{key:`knownLayoutAlgorithms`,value:function(){return this.worker.postMessage({cmd:`algorithms`})}},{key:`knownLayoutOptions`,value:function(){return this.worker.postMessage({cmd:`options`})}},{key:`knownLayoutCategories`,value:function(){return this.worker.postMessage({cmd:`categories`})}},{key:`terminateWorker`,value:function(){this.worker&&this.worker.terminate()}}]),e}();var a=function(){function e(t){var n=this;if(i(this,e),t===void 0)throw Error(`Missing mandatory parameter 'worker'.`);this.resolvers={},this.worker=t,this.worker.onmessage=function(e){setTimeout(function(){n.receive(n,e)},0)}}return r(e,[{key:`postMessage`,value:function(e){var t=this.id||0;this.id=t+1,e.id=t;var n=this;return new Promise(function(r,i){n.resolvers[t]=function(e,t){e?(n.convertGwtStyleError(e),i(e)):r(t)},n.worker.postMessage(e)})}},{key:`receive`,value:function(e,t){var n=t.data,r=e.resolvers[n.id];r&&(delete e.resolvers[n.id],n.error?r(n.error):r(null,n.data))}},{key:`terminate`,value:function(){this.worker&&this.worker.terminate()}},{key:`convertGwtStyleError`,value:function(e){if(e){var t=e.__java$exception;t&&(t.cause&&t.cause.backingJsObject&&(e.cause=t.cause.backingJsObject,this.convertGwtStyleError(e.cause)),delete e.__java$exception)}}}]),e}()},{}],2:[function(e,t,n){(function(e){(function(){var r;typeof window<`u`?r=window:e===void 0?typeof self<`u`&&(r=self):r=e;var i;function a(){}function o(){}function s(){}function c(){}function l(){}function u(){}function d(){}function f(){}function p(){}function m(){}function h(){}function g(){}function _(){}function v(){}function y(){}function b(){}function x(){}function S(){}function ee(){}function te(){}function ne(){}function C(){}function re(){}function ie(){}function ae(){}function oe(){}function se(){}function ce(){}function le(){}function ue(){}function de(){}function fe(){}function pe(){}function me(){}function he(){}function ge(){}function _e(){}function ve(){}function ye(){}function be(){}function xe(){}function Se(){}function Ce(){}function we(){}function Te(){}function Ee(){}function De(){}function Oe(){}function ke(){}function Ae(){}function je(){}function Me(){}function Ne(){}function Pe(){}function Fe(){}function Ie(){}function Le(){}function Re(){}function ze(){}function Be(){}function Ve(){}function He(){}function Ue(){}function We(){}function Ge(){}function Ke(){}function qe(){}function Je(){}function Ye(){}function Xe(){}function Ze(){}function Qe(){}function $e(){}function et(){}function tt(){}function nt(){}function rt(){}function it(){}function at(){}function ot(){}function st(){}function ct(){}function lt(){}function ut(){}function dt(){}function ft(){}function pt(){}function mt(){}function ht(){}function gt(){}function _t(){}function vt(){}function yt(){}function bt(){}function xt(){}function St(){}function Ct(){}function wt(){}function Tt(){}function Et(){}function Dt(){}function Ot(){}function kt(){}function At(){}function jt(){}function Mt(){}function Nt(){}function Pt(){}function Ft(){}function It(){}function Lt(){}function Rt(){}function zt(){}function Bt(){}function eee(){}function Vt(){}function tee(){}function nee(){}function Ht(){}function ree(){}function iee(){}function aee(){}function oee(){}function see(){}function cee(){}function lee(){}function uee(){}function dee(){}function fee(){}function pee(){}function mee(){}function hee(){}function Ut(){}function gee(){}function _ee(){}function vee(){}function yee(){}function bee(){}function xee(){}function See(){}function Cee(){}function wee(){}function Wt(){}function Gt(){}function Tee(){}function Eee(){}function Dee(){}function Oee(){}function kee(){}function Aee(){}function jee(){}function Mee(){}function Nee(){}function Pee(){}function Fee(){}function Iee(){}function Lee(){}function Ree(){}function zee(){}function Bee(){}function Vee(){}function Hee(){}function Uee(){}function Wee(){}function Gee(){}function Kee(){}function qee(){}function Jee(){}function Yee(){}function Xee(){}function Zee(){}function Qee(){}function $ee(){}function ete(){}function tte(){}function nte(){}function rte(){}function ite(){}function ate(){}function ote(){}function ste(){}function cte(){}function lte(){}function ute(){}function dte(){}function fte(){}function pte(){}function mte(){}function hte(){}function gte(){}function _te(){}function vte(){}function yte(){}function bte(){}function xte(){}function Ste(){}function Cte(){}function wte(){}function Tte(){}function Ete(){}function Dte(){}function Ote(){}function kte(){}function Ate(){}function jte(){}function Mte(){}function Nte(){}function Pte(){}function Fte(){}function Ite(){}function Lte(){}function Rte(){}function zte(){}function Bte(){}function Vte(){}function Hte(){}function Ute(){}function Wte(){}function Gte(){}function Kte(){}function qte(){}function Jte(){}function Yte(){}function Xte(){}function Zte(){}function Qte(){}function $te(){}function ene(){}function tne(){}function nne(){}function rne(){}function ine(){}function ane(){}function one(){}function sne(){}function cne(){}function lne(){}function une(){}function dne(){}function fne(){}function pne(){}function mne(){}function hne(){}function gne(){}function Kt(){}function _ne(){}function vne(){}function yne(){}function bne(){}function xne(){}function Sne(){}function Cne(){}function wne(){}function Tne(){}function Ene(){}function Dne(){}function One(){}function kne(){}function Ane(){}function jne(){}function Mne(){}function Nne(){}function Pne(){}function Fne(){}function Ine(){}function Lne(){}function Rne(){}function zne(){}function Bne(){}function Vne(){}function Hne(){}function Une(){}function Wne(){}function Gne(){}function Kne(){}function qne(){}function Jne(){}function Yne(){}function Xne(){}function Zne(){}function Qne(){}function $ne(){}function ere(){}function tre(){}function nre(){}function rre(){}function ire(){}function are(){}function ore(){}function sre(){}function cre(){}function lre(){}function ure(){}function dre(){}function fre(){}function pre(){}function mre(){}function hre(){}function gre(){}function _re(){}function vre(){}function yre(){}function bre(){}function xre(){}function Sre(){}function Cre(){}function wre(){}function Tre(){}function Ere(){}function Dre(){}function Ore(){}function kre(){}function Are(){}function jre(){}function Mre(){}function Nre(){}function Pre(){}function Fre(){}function qt(){}function Ire(){}function Lre(){}function Rre(){}function zre(){}function Bre(){}function Vre(){}function Hre(){}function Ure(){}function Wre(){}function Gre(){}function Kre(){}function qre(){}function Jre(){}function Yre(){}function Xre(){}function Zre(){}function Qre(){}function $re(){}function eie(){}function tie(){}function nie(){}function rie(){}function iie(){}function aie(){}function oie(){}function sie(){}function cie(){}function lie(){}function uie(){}function die(){}function fie(){}function pie(){}function mie(){}function hie(){}function gie(){}function _ie(){}function vie(){}function yie(){}function bie(){}function xie(){}function Sie(){}function Cie(){}function wie(){}function Tie(){}function Eie(){}function Die(){}function Oie(){}function kie(){}function Aie(){}function jie(){}function Mie(){}function Nie(){}function Pie(){}function Fie(){}function Iie(){}function Lie(){}function Rie(){}function zie(){}function Bie(){}function Vie(){}function Hie(){}function Uie(){}function Wie(){}function Gie(){}function Kie(){}function qie(){}function Jie(){}function Yie(){}function Xie(){}function Zie(){}function Qie(){}function $ie(){}function eae(){}function tae(){}function nae(){}function rae(){}function iae(){}function aae(){}function oae(){}function sae(){}function cae(){}function lae(){}function uae(){}function dae(){}function fae(){}function pae(){}function mae(){}function hae(){}function gae(){}function _ae(){}function vae(){}function yae(){}function bae(){}function xae(){}function Sae(){}function Cae(){}function wae(){}function Tae(){}function Eae(){}function Dae(){}function Oae(){}function kae(){}function Aae(){}function jae(){}function Mae(){}function Nae(){}function Pae(){}function Fae(){}function Iae(){}function Lae(){}function Rae(){}function zae(){}function Bae(){}function Vae(){}function Hae(){}function Uae(){}function Wae(){}function Gae(){}function Kae(){}function qae(){}function Jae(){}function Yae(){}function Xae(){}function Zae(){}function Qae(){}function $ae(){}function eoe(){}function toe(){}function noe(){}function roe(){}function ioe(){}function aoe(){}function ooe(){}function soe(){}function coe(){}function loe(){}function uoe(){}function doe(){}function foe(){}function poe(){}function moe(){}function hoe(){}function goe(){}function _oe(){}function voe(){}function yoe(){}function boe(){}function xoe(){}function Jt(){}function Yt(){}function Soe(){}function Xt(){}function Coe(){}function woe(){}function Toe(){}function Eoe(){}function Doe(){}function Ooe(){}function koe(){}function Aoe(){}function joe(){}function Moe(){}function Noe(){}function Poe(){}function Foe(){}function Ioe(){}function Loe(){}function Roe(){}function zoe(){}function Boe(){}function Voe(){}function Hoe(){}function Uoe(){}function Woe(){}function Zt(){}function Goe(){}function Qt(){}function Koe(){}function qoe(){}function Joe(){}function Yoe(){}function Xoe(){}function Zoe(){}function Qoe(){}function $oe(){}function ese(){}function tse(){}function nse(){}function rse(){}function ise(){}function ase(){}function ose(){}function sse(){}function cse(){}function lse(){}function use(){}function dse(){}function $t(){}function fse(){}function pse(){}function mse(){}function hse(){}function gse(){}function _se(){}function vse(){}function yse(){}function bse(){}function xse(){}function Sse(){}function Cse(){}function wse(){}function en(){}function Tse(){}function Ese(){}function Dse(){}function tn(){}function Ose(){}function nn(){}function rn(){}function kse(){}function Ase(){}function jse(){}function Mse(){}function Nse(){}function Pse(){}function Fse(){}function Ise(){}function an(){}function Lse(){}function Rse(){}function on(){}function zse(){}function sn(){}function Bse(){}function Vse(){}function Hse(){}function cn(){}function Use(){}function Wse(){}function Gse(){}function Kse(){}function qse(){}function Jse(){}function Yse(){}function Xse(){}function Zse(){}function Qse(){}function $se(){}function ece(){}function tce(){}function nce(){}function rce(){}function ice(){}function ln(){}function un(){}function ace(){}function oce(){}function sce(){}function cce(){}function lce(){}function uce(){}function dce(){}function fce(){}function pce(){}function mce(){}function hce(){}function gce(){}function _ce(){}function vce(){}function yce(){}function bce(){}function xce(){}function Sce(){}function Cce(){}function wce(){}function Tce(){}function Ece(){}function Dce(){}function Oce(){}function kce(){}function Ace(){}function jce(){}function Mce(){}function Nce(){}function Pce(){}function Fce(){}function Ice(){}function Lce(){}function Rce(){}function zce(){}function Bce(){}function Vce(){}function Hce(){}function Uce(){}function Wce(){}function Gce(){}function Kce(){}function qce(){}function Jce(){}function Yce(){}function Xce(){}function Zce(){}function Qce(){}function $ce(){}function ele(){}function tle(){}function nle(){}function rle(){}function ile(){}function ale(){}function ole(){}function sle(){}function cle(){}function lle(){}function ule(){}function dle(){}function fle(){}function ple(){}function mle(){}function hle(){}function gle(){}function _le(){}function vle(){}function yle(){}function ble(){}function xle(){}function Sle(){}function Cle(){}function wle(){}function Tle(){}function Ele(){}function Dle(){}function Ole(){}function kle(){}function Ale(){}function jle(){}function Mle(){}function Nle(){}function Ple(){}function Fle(){}function Ile(){}function Lle(){}function Rle(){}function zle(){}function Ble(){}function Vle(){}function Hle(){}function Ule(){}function Wle(){}function Gle(){}function Kle(){}function qle(){}function Jle(){}function Yle(){}function Xle(){}function Zle(){}function Qle(){}function $le(){}function eue(){}function dn(){fi()}function tue(){Fo()}function nue(){Rk()}function rue(){qw()}function iue(){bO()}function aue(){I9e()}function oue(){XM()}function sue(){e6e()}function cue(){Nk()}function lue(){Io()}function uue(){Ff()}function due(){Ibe()}function fue(){cC()}function pue(){sWe()}function mue(){mJe()}function hue(){DRe()}function gue(){gJe()}function _ue(){eGe()}function vue(){TRe()}function yue(){Fw()}function bue(){vJe()}function xue(){_Je()}function Sue(){HBe()}function Cue(){yJe()}function wue(){wA()}function Tue(){Ro()}function Eue(){bP()}function Due(){mP()}function Oue(){bJe()}function kue(){kYe()}function Aue(){ORe()}function jue(){o6e()}function Mue(){kRe()}function Nue(){Aut()}function Pue(){Hrt()}function Fue(){zx()}function Iue(){Q$e()}function Lue(){rN()}function Rue(){fze()}function zue(){Rx()}function Bue(){Ylt()}function Vue(){PA()}function Hue(){Qlt()}function Uue(){gM()}function Wue(){yA()}function Gue(){bM()}function Kue(){ek()}function fn(){rke()}function que(){gb()}function Jue(){bA()}function Yue(){vP()}function Xue(){Iw()}function Zue(){wD()}function Que(){uC()}function $ue(){_N()}function ede(){Odt()}function tde(e){Gh(e)}function nde(e){this.a=e}function pn(e){this.a=e}function rde(e){this.a=e}function ide(e){this.a=e}function ade(e){this.a=e}function ode(e){this.a=e}function sde(e){this.a=e}function cde(e){this.a=e}function mn(e){this.a=e}function hn(e){this.a=e}function lde(e){this.a=e}function ude(e){this.a=e}function gn(e){this.a=e}function dde(e){this.a=e}function fde(e){this.a=e}function _n(e){this.a=e}function vn(e){this.a=e}function pde(e){this.a=e}function yn(e){this.a=e}function mde(e){this.a=e}function hde(e){this.a=e}function gde(e){this.a=e}function bn(e){this.b=e}function _de(e){this.c=e}function vde(e){this.a=e}function yde(e){this.a=e}function bde(e){this.a=e}function xde(e){this.a=e}function Sde(e){this.a=e}function Cde(e){this.a=e}function wde(e){this.a=e}function Tde(e){this.a=e}function Ede(e){this.a=e}function Dde(e){this.a=e}function Ode(e){this.a=e}function kde(e){this.a=e}function Ade(e){this.a=e}function xn(e){this.a=e}function Sn(e){this.a=e}function Cn(e){this.a=e}function wn(e){this.a=e}function Tn(){this.a=[]}function jde(e,t){e.a=t}function Mde(e,t){e.a=t}function Nde(e,t){e.b=t}function Pde(e,t){e.b=t}function Fde(e,t){e.b=t}function Ide(e,t){e.j=t}function Lde(e,t){e.g=t}function Rde(e,t){e.i=t}function zde(e,t){e.c=t}function Bde(e,t){e.c=t}function Vde(e,t){e.d=t}function Hde(e,t){e.d=t}function En(e,t){e.k=t}function Ude(e,t){e.c=t}function Wde(e,t){e.c=t}function Gde(e,t){e.a=t}function Kde(e,t){e.a=t}function qde(e,t){e.f=t}function Jde(e,t){e.a=t}function Yde(e,t){e.b=t}function Dn(e,t){e.d=t}function On(e,t){e.i=t}function Xde(e,t){e.o=t}function Zde(e,t){e.r=t}function Qde(e,t){e.a=t}function $de(e,t){e.b=t}function efe(e,t){e.e=t}function tfe(e,t){e.f=t}function nfe(e,t){e.g=t}function rfe(e,t){e.e=t}function ife(e,t){e.f=t}function afe(e,t){e.f=t}function kn(e,t){e.a=t}function An(e,t){e.b=t}function ofe(e,t){e.n=t}function sfe(e,t){e.a=t}function cfe(e,t){e.c=t}function lfe(e,t){e.c=t}function ufe(e,t){e.c=t}function dfe(e,t){e.a=t}function ffe(e,t){e.a=t}function pfe(e,t){e.d=t}function mfe(e,t){e.d=t}function hfe(e,t){e.e=t}function gfe(e,t){e.e=t}function _fe(e,t){e.g=t}function vfe(e,t){e.f=t}function yfe(e,t){e.j=t}function bfe(e,t){e.a=t}function xfe(e,t){e.a=t}function Sfe(e,t){e.b=t}function Cfe(e){e.b=e.a}function wfe(e){e.c=e.d.d}function jn(e){this.a=e}function Mn(e){this.a=e}function Nn(e){this.a=e}function Pn(e){this.a=e}function Fn(e){this.a=e}function In(e){this.a=e}function Tfe(e){this.a=e}function Ln(e){this.a=e}function Rn(e){this.a=e}function zn(e){this.a=e}function Bn(e){this.a=e}function Vn(e){this.a=e}function Efe(e){this.a=e}function Dfe(e){this.a=e}function Hn(e){this.b=e}function Un(e){this.b=e}function Wn(e){this.b=e}function Gn(e){this.a=e}function Ofe(e){this.a=e}function Kn(e){this.c=e}function w(e){this.c=e}function kfe(e){this.c=e}function qn(e){this.d=e}function Jn(e){this.a=e}function Yn(e){this.a=e}function Afe(e){this.a=e}function Xn(e){this.a=e}function Zn(e){this.a=e}function Qn(e){this.a=e}function $n(e){this.a=e}function er(e){this.a=e}function tr(e){this.a=e}function nr(e){this.a=e}function jfe(e){this.a=e}function Mfe(e){this.a=e}function rr(e){this.a=e}function Nfe(e){this.a=e}function Pfe(e){this.a=e}function Ffe(e){this.a=e}function Ife(e){this.a=e}function Lfe(e){this.a=e}function Rfe(e){this.a=e}function zfe(e){this.a=e}function Bfe(e){this.a=e}function Vfe(e){this.a=e}function Hfe(e){this.a=e}function Ufe(e){this.a=e}function Wfe(e){this.a=e}function Gfe(e){this.a=e}function Kfe(e){this.a=e}function qfe(e){this.a=e}function ir(e){this.a=e}function Jfe(e){this.a=e}function Yfe(e){this.a=e}function Xfe(e){this.a=e}function Zfe(e){this.a=e}function ar(e){this.a=e}function Qfe(e){this.a=e}function $fe(e){this.a=e}function or(e){this.a=e}function sr(e){this.a=e}function epe(e){this.a=e}function tpe(e){this.a=e}function npe(e){this.a=e}function rpe(e){this.a=e}function ipe(e){this.a=e}function ape(e){this.a=e}function cr(e){this.a=e}function lr(e){this.a=e}function ur(e){this.a=e}function dr(e){this.a=e}function fr(e){this.e=e}function pr(e){this.a=e}function ope(e){this.a=e}function mr(e){this.a=e}function spe(e){this.a=e}function cpe(e){this.a=e}function lpe(e){this.a=e}function upe(e){this.a=e}function dpe(e){this.a=e}function fpe(e){this.a=e}function ppe(e){this.a=e}function mpe(e){this.a=e}function hpe(e){this.a=e}function gpe(e){this.a=e}function _pe(e){this.a=e}function vpe(e){this.a=e}function ype(e){this.a=e}function bpe(e){this.a=e}function xpe(e){this.a=e}function Spe(e){this.a=e}function Cpe(e){this.a=e}function wpe(e){this.a=e}function Tpe(e){this.a=e}function Epe(e){this.a=e}function Dpe(e){this.a=e}function Ope(e){this.a=e}function kpe(e){this.a=e}function Ape(e){this.a=e}function jpe(e){this.a=e}function Mpe(e){this.a=e}function Npe(e){this.a=e}function Ppe(e){this.a=e}function Fpe(e){this.a=e}function Ipe(e){this.a=e}function Lpe(e){this.a=e}function Rpe(e){this.a=e}function zpe(e){this.a=e}function Bpe(e){this.a=e}function Vpe(e){this.a=e}function Hpe(e){this.a=e}function Upe(e){this.a=e}function Wpe(e){this.a=e}function Gpe(e){this.a=e}function Kpe(e){this.a=e}function qpe(e){this.a=e}function Jpe(e){this.a=e}function Ype(e){this.a=e}function Xpe(e){this.a=e}function Zpe(e){this.a=e}function Qpe(e){this.a=e}function $pe(e){this.a=e}function eme(e){this.a=e}function tme(e){this.a=e}function nme(e){this.a=e}function rme(e){this.a=e}function ime(e){this.c=e}function ame(e){this.b=e}function ome(e){this.a=e}function sme(e){this.a=e}function cme(e){this.a=e}function lme(e){this.a=e}function ume(e){this.a=e}function dme(e){this.a=e}function fme(e){this.a=e}function pme(e){this.a=e}function mme(e){this.a=e}function hme(e){this.a=e}function gme(e){this.a=e}function _me(e){this.a=e}function vme(e){this.a=e}function yme(e){this.a=e}function bme(e){this.a=e}function xme(e){this.a=e}function Sme(e){this.a=e}function Cme(e){this.a=e}function wme(e){this.a=e}function Tme(e){this.a=e}function Eme(e){this.a=e}function Dme(e){this.a=e}function Ome(e){this.a=e}function kme(e){this.a=e}function Ame(e){this.a=e}function jme(e){this.a=e}function Mme(e){this.a=e}function hr(e){this.a=e}function gr(e){this.a=e}function Nme(e){this.a=e}function Pme(e){this.a=e}function Fme(e){this.a=e}function Ime(e){this.a=e}function Lme(e){this.a=e}function Rme(e){this.a=e}function zme(e){this.a=e}function Bme(e){this.a=e}function Vme(e){this.a=e}function Hme(e){this.a=e}function Ume(e){this.a=e}function Wme(e){this.a=e}function Gme(e){this.a=e}function Kme(e){this.a=e}function qme(e){this.a=e}function Jme(e){this.a=e}function Yme(e){this.a=e}function Xme(e){this.a=e}function Zme(e){this.a=e}function Qme(e){this.a=e}function $me(e){this.a=e}function ehe(e){this.a=e}function the(e){this.a=e}function nhe(e){this.a=e}function rhe(e){this.a=e}function ihe(e){this.a=e}function _r(e){this.a=e}function ahe(e){this.f=e}function ohe(e){this.a=e}function she(e){this.a=e}function che(e){this.a=e}function lhe(e){this.a=e}function uhe(e){this.a=e}function dhe(e){this.a=e}function fhe(e){this.a=e}function phe(e){this.a=e}function mhe(e){this.a=e}function hhe(e){this.a=e}function ghe(e){this.a=e}function _he(e){this.a=e}function vhe(e){this.a=e}function yhe(e){this.a=e}function bhe(e){this.a=e}function xhe(e){this.a=e}function She(e){this.a=e}function Che(e){this.a=e}function whe(e){this.a=e}function The(e){this.a=e}function Ehe(e){this.a=e}function Dhe(e){this.a=e}function Ohe(e){this.a=e}function khe(e){this.a=e}function Ahe(e){this.a=e}function jhe(e){this.a=e}function Mhe(e){this.a=e}function Nhe(e){this.a=e}function vr(e){this.a=e}function Phe(e){this.a=e}function yr(e){this.b=e}function Fhe(e){this.a=e}function Ihe(e){this.a=e}function Lhe(e){this.a=e}function Rhe(e){this.a=e}function zhe(e){this.a=e}function Bhe(e){this.a=e}function Vhe(e){this.a=e}function Hhe(e){this.b=e}function Uhe(e){this.a=e}function br(e){this.a=e}function Whe(e){this.a=e}function Ghe(e){this.a=e}function Khe(e){this.c=e}function xr(e){this.e=e}function Sr(e){this.a=e}function Cr(e){this.a=e}function wr(e){this.a=e}function qhe(e){this.d=e}function Jhe(e){this.a=e}function Yhe(e){this.a=e}function Xhe(e){this.a=e}function Tr(e){this.e=e}function Er(){this.a=0}function Dr(){Pm(this)}function T(){au(this)}function Or(){_Fe(this)}function Zhe(){}function kr(){this.c=nHt}function Qhe(e,t){e.b+=t}function $he(e,t){t.Wb(e)}function ege(e){return e.a}function tge(e){return e.a}function nge(e){return e.a}function rge(e){return e.a}function ige(e){return e.a}function E(e){return e.e}function age(){return null}function oge(){return null}function sge(){La(),P_t()}function cge(e){e.b.Of(e.e)}function lge(e){e.b=new la}function Ar(e,t){e.b=t-e.b}function jr(e,t){e.a=t-e.a}function Mr(e,t){e.push(t)}function uge(e,t){e.sort(t)}function dge(e,t){t.jd(e.a)}function fge(e,t){tj(t,e)}function pge(e,t,n){e.Yd(n,t)}function Nr(e,t){e.e=t,t.b=e}function mge(e){wf(),this.a=e}function hge(e){wf(),this.a=e}function gge(e){wf(),this.a=e}function Pr(e){gh(),this.a=e}function _ge(e){Xg(),lG.le(e)}function vge(){vge=C,new Dr}function Fr(){WTe.call(this)}function yge(){WTe.call(this)}function bge(){Fr.call(this)}function Ir(){Fr.call(this)}function xge(){Fr.call(this)}function Lr(){Fr.call(this)}function Rr(){Fr.call(this)}function zr(){Fr.call(this)}function Br(){Fr.call(this)}function Vr(){Fr.call(this)}function Sge(){Fr.call(this)}function Hr(){Fr.call(this)}function Cge(){Fr.call(this)}function wge(){this.a=this}function Ur(){this.Bb|=256}function Tge(){this.b=new lCe}function Wr(e,t){e.length=t}function Gr(e,t){M(e.a,t)}function Ege(e,t){tet(e.c,t)}function Dge(e,t){Lm(e.b,t)}function Oge(e,t){JO(e.a,t)}function kge(e,t){$T(e.a,t)}function Kr(e,t){AC(e.e,t)}function qr(e){_j(e.c,e.b)}function Age(e,t){e.kc().Nb(t)}function jge(e){this.a=y1e(e)}function Jr(){this.a=new Dr}function Mge(){this.a=new Dr}function Nge(){this.a=new gbe}function Yr(){this.a=new T}function Xr(){this.a=new T}function Pge(){this.a=new T}function Zr(){this.a=new Xe}function Qr(){this.a=new qUe}function Fge(){this.a=new Vt}function Ige(){this.a=new wRe}function Lge(){this.a=new eOe}function Rge(){this.a=new T}function zge(){this.a=new T}function Bge(){this.a=new T}function Vge(){this.a=new T}function Hge(){this.d=new T}function Uge(){this.a=new Qze}function Wge(){this.a=new Jr}function Gge(){this.a=new Dr}function Kge(){this.b=new Dr}function qge(){this.b=new T}function Jge(){this.e=new T}function Yge(){this.a=new wue}function Xge(){this.d=new T}function Zge(){QIe.call(this)}function Qge(){QIe.call(this)}function $ge(){T.call(this)}function e_e(){bge.call(this)}function $r(){Yr.call(this)}function t_e(){Qd.call(this)}function n_e(){Vge.call(this)}function ei(){Zhe.call(this)}function ti(){ei.call(this)}function ni(){Zhe.call(this)}function ri(){ni.call(this)}function r_e(){b_e.call(this)}function i_e(){b_e.call(this)}function a_e(){b_e.call(this)}function o_e(){C_e.call(this)}function ii(){Ose.call(this)}function s_e(){Ose.call(this)}function ai(){vo.call(this)}function c_e(){E_e.call(this)}function l_e(){E_e.call(this)}function u_e(){Dr.call(this)}function d_e(){Dr.call(this)}function f_e(){Dr.call(this)}function oi(){EJe.call(this)}function p_e(){Jr.call(this)}function m_e(){Ur.call(this)}function si(){gTe.call(this)}function ci(){Dr.call(this)}function li(){gTe.call(this)}function ui(){Dr.call(this)}function h_e(){Dr.call(this)}function g_e(){sn.call(this)}function __e(){g_e.call(this)}function v_e(){sn.call(this)}function y_e(){Qle.call(this)}function b_e(){this.a=new Jr}function x_e(){this.a=new Dr}function S_e(){this.a=new T}function C_e(){this.a=new Dr}function di(){this.a=new vo}function w_e(){this.j=new T}function T_e(){this.a=new bye}function E_e(){this.a=new zse}function D_e(){this.a=new goe}function fi(){fi=C,GW=new o}function pi(){pi=C,XW=new k_e}function mi(){mi=C,ZW=new O_e}function O_e(){_n.call(this,``)}function k_e(){_n.call(this,``)}function A_e(e){mqe.call(this,e)}function j_e(e){mqe.call(this,e)}function M_e(e){mn.call(this,e)}function N_e(e){nbe.call(this,e)}function P_e(e){nbe.call(this,e)}function F_e(e){N_e.call(this,e)}function I_e(e){N_e.call(this,e)}function L_e(e){N_e.call(this,e)}function R_e(e){ny.call(this,e)}function z_e(e){ny.call(this,e)}function B_e(e){VOe.call(this,e)}function V_e(e){obe.call(this,e)}function hi(e){lo.call(this,e)}function gi(e){lo.call(this,e)}function H_e(e){lo.call(this,e)}function _i(e){P9e.call(this,e)}function vi(e){_i.call(this,e)}function yi(e){KNe.call(this,e)}function U_e(e){yi.call(this,e)}function bi(){wn.call(this,{})}function W_e(){W_e=C,zTt=new te}function xi(){xi=C,tG=new Vwe}function G_e(){G_e=C,iG=new a}function Si(){Si=C,cG=new v}function Ci(){Ci=C,dG=new x}function wi(e){Bu(),this.a=e}function Ti(e){lC(),this.a=e}function Ei(e){em(),this.f=e}function Di(e){em(),this.f=e}function K_e(e){nke(),this.a=e}function q_e(e){e.b=null,e.c=0}function J_e(e,t){e.e=t,Sst(e,t)}function Y_e(e,t){e.a=t,ott(e)}function Oi(e,t,n){e.a[t.g]=n}function X_e(e,t,n){y8e(n,e,t)}function Z_e(e,t){HOe(t.i,e.n)}function Q_e(e,t){ZZe(e).Cd(t)}function $_e(e,t){e.a.ec().Mc(t)}function eve(e,t){return e.g-t.g}function tve(e,t){return e*e/t}function ki(e){return Gh(e),e}function D(e){return Gh(e),e}function Ai(e){return Gh(e),e}function nve(e){return new Cn(e)}function rve(e){return new mh(e)}function ive(e){return Gh(e),e}function ave(e){return Gh(e),e}function ji(e){yi.call(this,e)}function Mi(e){yi.call(this,e)}function ove(e){yi.call(this,e)}function Ni(e){KNe.call(this,e)}function Pi(e){yi.call(this,e)}function Fi(e){yi.call(this,e)}function Ii(e){yi.call(this,e)}function sve(e){yi.call(this,e)}function Li(e){yi.call(this,e)}function Ri(e){yi.call(this,e)}function zi(e){yi.call(this,e)}function Bi(e){yi.call(this,e)}function Vi(e){yi.call(this,e)}function Hi(e){yi.call(this,e)}function Ui(e){yi.call(this,e)}function Wi(e){Gh(e),this.a=e}function Gi(e){return Tw(e),e}function Ki(e){CPe(e,e.length)}function qi(e){return e.b==e.c}function Ji(e){return!!e&&e.b}function cve(e){return!!e&&e.k}function lve(e){return!!e&&e.j}function uve(e,t,n){e.c.Ef(t,n)}function dve(e,t){e.be(t),t.ae(e)}function Yi(e){wf(),this.a=ph(e)}function Xi(){this.a=kd(ph(PP))}function fve(){throw E(new Br)}function pve(){throw E(new Br)}function Zi(){throw E(new Br)}function mve(){throw E(new Br)}function hve(){throw E(new Br)}function gve(){throw E(new Br)}function Qi(){Qi=C,Xg()}function $i(){In.call(this,``)}function ea(){In.call(this,``)}function ta(){In.call(this,``)}function na(){In.call(this,``)}function ra(e){Mi.call(this,e)}function ia(e){Mi.call(this,e)}function aa(e){Fi.call(this,e)}function oa(e){Wn.call(this,e)}function _ve(e){oa.call(this,e)}function sa(e){qu.call(this,e)}function ca(e){sEe.call(this,e,0)}function la(){URe.call(this,12,3)}function O(e,t){return _Re(e,t)}function ua(e,t){return yb(e,t)}function vve(e,t){return e.a-t.a}function yve(e,t){return e.a-t.a}function bve(e,t){return e.a-t.a}function xve(e,t){return t in e.a}function Sve(e){return e.a?e.b:0}function Cve(e){return e.a?e.b:0}function wve(e,t,n){t.Cd(e.a[n])}function Tve(e,t,n){t.Pe(e.a[n])}function Eve(e,t){e.b=new Vl(t)}function Dve(e,t){return e.b=t,e}function Ove(e,t){return e.c=t,e}function kve(e,t){return e.f=t,e}function Ave(e,t){return e.g=t,e}function da(e,t){return e.a=t,e}function fa(e,t){return e.f=t,e}function jve(e,t){return e.k=t,e}function pa(e,t){return e.a=t,e}function Mve(e,t){return e.e=t,e}function ma(e,t){return e.e=t,e}function Nve(e,t){return e.f=t,e}function Pve(e,t){e.b=!0,e.d=t}function Fve(e,t){return e.b-t.b}function Ive(e,t){return e.g-t.g}function Lve(e,t){return e?0:t-1}function Rve(e,t){return e?0:t-1}function zve(e,t){return e?t-1:0}function Bve(e,t){return e.s-t.s}function Vve(e,t){return t.rg(e)}function ha(e,t){return e.b=t,e}function ga(e,t){return e.a=t,e}function _a(e,t){return e.c=t,e}function va(e,t){return e.d=t,e}function ya(e,t){return e.e=t,e}function ba(e,t){return e.f=t,e}function xa(e,t){return e.a=t,e}function Sa(e,t){return e.b=t,e}function Ca(e,t){return e.c=t,e}function wa(e,t){return e.c=t,e}function Ta(e,t){return e.b=t,e}function Ea(e,t){return e.d=t,e}function Da(e,t){return e.e=t,e}function Hve(e,t){return e.f=t,e}function Oa(e,t){return e.g=t,e}function ka(e,t){return e.a=t,e}function Aa(e,t){return e.i=t,e}function ja(e,t){return e.j=t,e}function Uve(e,t){wA(),G_(t,e)}function Wve(e,t,n){CNe(e.a,t,n)}function Ma(e){yf.call(this,e)}function Gve(e){L1e.call(this,e)}function Kve(e){uIe.call(this,e)}function Na(e){uIe.call(this,e)}function Pa(e){kx.call(this,e)}function qve(e){Ig.call(this,e)}function Jve(e){Ig.call(this,e)}function Yve(){Dwe.call(this,``)}function Fa(){this.a=0,this.b=0}function Xve(){this.b=0,this.a=0}function Zve(e,t){e.b=0,Qx(e,t)}function Qve(e,t){return e.k=t,e}function $ve(e,t){return e.j=t,e}function eye(e,t){e.c=t,e.b=!0}function tye(){tye=C,rEt=c5e()}function Ia(){Ia=C,iVt=X6e()}function nye(){nye=C,Y5=X5e()}function La(){La=C,h7=dS()}function Ra(){Ra=C,R7=Z6e()}function rye(){rye=C,wHt=Q6e()}function za(){za=C,b9=rtt()}function Ba(e){return e.e&&e.e()}function iye(e){return e.l|e.m<<22}function aye(e,t){return e.c._b(t)}function oye(e,t){return E$e(e.b,t)}function Va(e){return e?e.d:null}function sye(e){return e?e.g:null}function cye(e){return e?e.i:null}function Ha(e){return Ad(e),e.o}function Ua(e,t){return e.a+=t,e}function Wa(e,t){return e.a+=t,e}function Ga(e,t){return e.a+=t,e}function Ka(e,t){return e.a+=t,e}function lye(e,t){for(;e.Bd(t););}function qa(e){this.a=new go(e)}function uye(){throw E(new Br)}function dye(){throw E(new Br)}function fye(){throw E(new Br)}function pye(){throw E(new Br)}function mye(){throw E(new Br)}function hye(){throw E(new Br)}function Ja(e){this.a=new mm(e)}function gye(){this.a=new Yj(NFt)}function _ye(){this.b=new Yj(yPt)}function vye(){this.a=new Yj(kIt)}function yye(){this.b=new Yj(_3)}function bye(){this.b=new Yj(_3)}function Ya(e){this.a=0,this.b=e}function xye(e){Ngt(),tvt(this,e)}function Xa(e){return Hh(e),e.a}function Za(e){return e.b!=e.d.c}function Sye(e,t){return e.d[t.p]}function Cye(e,t){return bst(e,t)}function wye(e,t,n){e.splice(t,n)}function Qa(e,t){for(;e.Re(t););}function Tye(e){e.c?gct(e):_ct(e)}function Eye(){throw E(new Br)}function Dye(){throw E(new Br)}function Oye(){throw E(new Br)}function kye(){throw E(new Br)}function Aye(){throw E(new Br)}function jye(){throw E(new Br)}function Mye(){throw E(new Br)}function Nye(){throw E(new Br)}function Pye(){throw E(new Br)}function Fye(){throw E(new Br)}function Iye(){throw E(new Hr)}function Lye(){throw E(new Hr)}function $a(e){this.a=new Rye(e)}function Rye(e){IJe(this,e,B9e())}function eo(e){return!e||mFe(e)}function to(e){return A9[e]!=-1}function zye(){oG!=0&&(oG=0),sG=-1}function Bye(){xTt??=[]}function no(e,t){zu.call(this,e,t)}function ro(e,t){no.call(this,e,t)}function Vye(e,t){this.a=e,this.b=t}function Hye(e,t){this.a=e,this.b=t}function Uye(e,t){this.a=e,this.b=t}function Wye(e,t){this.a=e,this.b=t}function Gye(e,t){this.a=e,this.b=t}function Kye(e,t){this.a=e,this.b=t}function qye(e,t){this.a=e,this.b=t}function io(e,t){this.e=e,this.d=t}function Jye(e,t){this.b=e,this.c=t}function Yye(e,t){this.b=e,this.a=t}function Xye(e,t){this.b=e,this.a=t}function Zye(e,t){this.b=e,this.a=t}function Qye(e,t){this.b=e,this.a=t}function $ye(e,t){this.a=e,this.b=t}function ao(e,t){this.a=e,this.b=t}function ebe(e,t){this.a=e,this.f=t}function oo(e,t){this.g=e,this.i=t}function so(e,t){this.f=e,this.g=t}function tbe(e,t){this.b=e,this.c=t}function nbe(e){vTe(e.dc()),this.c=e}function rbe(e,t){this.a=e,this.b=t}function ibe(e,t){this.a=e,this.b=t}function abe(e){this.a=P(ph(e),15)}function obe(e){this.a=P(ph(e),15)}function sbe(e){this.a=P(ph(e),85)}function co(e){this.b=P(ph(e),85)}function lo(e){this.b=P(ph(e),51)}function uo(){this.q=new r.Date}function fo(e,t){this.a=e,this.b=t}function cbe(e,t){return km(e.b,t)}function po(e,t){return e.b.Hc(t)}function lbe(e,t){return e.b.Ic(t)}function ube(e,t){return e.b.Qc(t)}function dbe(e,t){return e.b.Hc(t)}function fbe(e,t){return e.c.uc(t)}function pbe(e,t){return NT(e.c,t)}function mo(e,t){return e.a._b(t)}function mbe(e,t){return e>t&&t0}function rs(e,t){return dT(e,t)<0}function exe(e,t){return Gp(e.a,t)}function txe(e,t){yRe.call(this,e,t)}function nxe(e){_h(),VOe.call(this,e)}function rxe(e,t){mNe(e,e.length,t)}function is(e,t){NPe(e,e.length,t)}function as(e,t){return e.a.get(t)}function ixe(e,t){return km(e.e,t)}function os(e){return Gh(e),!1}function ss(e){this.a=P(ph(e),229)}function cs(e){cv.call(this,e,21)}function ls(e,t){so.call(this,e,t)}function us(e,t){so.call(this,e,t)}function axe(e,t){this.b=e,this.a=t}function ds(e,t){this.d=e,this.e=t}function oxe(e,t){this.a=e,this.b=t}function sxe(e,t){this.a=e,this.b=t}function cxe(e,t){this.a=e,this.b=t}function lxe(e,t){this.a=e,this.b=t}function fs(e,t){this.a=e,this.b=t}function uxe(e,t){this.b=e,this.a=t}function dxe(e,t){this.b=e,this.a=t}function fxe(e,t){so.call(this,e,t)}function pxe(e,t){so.call(this,e,t)}function ps(e,t){so.call(this,e,t)}function ms(e,t){so.call(this,e,t)}function hs(e,t){so.call(this,e,t)}function gs(e,t){so.call(this,e,t)}function _s(e,t){so.call(this,e,t)}function vs(e,t){this.b=e,this.a=t}function ys(e,t){so.call(this,e,t)}function bs(e,t){this.b=e,this.a=t}function xs(e,t){so.call(this,e,t)}function mxe(e,t){this.b=e,this.a=t}function Ss(e,t){so.call(this,e,t)}function Cs(e,t){so.call(this,e,t)}function ws(e,t){so.call(this,e,t)}function Ts(e,t,n){e.splice(t,0,n)}function hxe(e,t,n){e.Mb(n)&&t.Cd(n)}function gxe(e,t,n){t.Pe(e.a.Ye(n))}function _xe(e,t,n){t.Dd(e.a.Ze(n))}function vxe(e,t,n){t.Cd(e.a.Kb(n))}function yxe(e,t){return $u(e.c,t)}function bxe(e,t){return $u(e.e,t)}function Es(e,t){so.call(this,e,t)}function Ds(e,t){so.call(this,e,t)}function Os(e,t){so.call(this,e,t)}function xxe(e,t){so.call(this,e,t)}function ks(e,t){so.call(this,e,t)}function As(e,t){so.call(this,e,t)}function Sxe(e,t){this.a=e,this.b=t}function Cxe(e,t){this.a=e,this.b=t}function wxe(e,t){this.a=e,this.b=t}function Txe(e,t){this.a=e,this.b=t}function Exe(e,t){this.a=e,this.b=t}function Dxe(e,t){this.a=e,this.b=t}function Oxe(e,t){this.b=e,this.a=t}function kxe(e,t){this.b=e,this.a=t}function Axe(e,t){this.b=e,this.a=t}function js(e,t){this.c=e,this.d=t}function jxe(e,t){this.e=e,this.d=t}function Mxe(e,t){this.a=e,this.b=t}function Nxe(e,t){this.a=e,this.b=t}function Pxe(e,t){this.a=e,this.b=t}function Fxe(e,t){this.b=e,this.a=t}function Ixe(e,t){this.b=t,this.c=e}function Ms(e,t){so.call(this,e,t)}function Ns(e,t){so.call(this,e,t)}function Ps(e,t){so.call(this,e,t)}function Lxe(e,t){so.call(this,e,t)}function Fs(e,t){so.call(this,e,t)}function Is(e,t){so.call(this,e,t)}function Ls(e,t){so.call(this,e,t)}function Rs(e,t){so.call(this,e,t)}function zs(e,t){so.call(this,e,t)}function Bs(e,t){so.call(this,e,t)}function Vs(e,t){so.call(this,e,t)}function Hs(e,t){so.call(this,e,t)}function Us(e,t){so.call(this,e,t)}function Ws(e,t){so.call(this,e,t)}function Gs(e,t){so.call(this,e,t)}function Ks(e,t){so.call(this,e,t)}function qs(e,t){so.call(this,e,t)}function Js(e,t){so.call(this,e,t)}function Ys(e,t){so.call(this,e,t)}function Xs(e,t){so.call(this,e,t)}function Zs(e,t){so.call(this,e,t)}function Qs(e,t){so.call(this,e,t)}function $s(e,t){so.call(this,e,t)}function ec(e,t){so.call(this,e,t)}function tc(e,t){so.call(this,e,t)}function nc(e,t){so.call(this,e,t)}function rc(e,t){so.call(this,e,t)}function ic(e,t){so.call(this,e,t)}function ac(e,t){so.call(this,e,t)}function oc(e,t){so.call(this,e,t)}function sc(e,t){so.call(this,e,t)}function cc(e,t){so.call(this,e,t)}function lc(e,t){so.call(this,e,t)}function Rxe(e,t){this.b=e,this.a=t}function zxe(e,t){so.call(this,e,t)}function Bxe(e,t){this.a=e,this.b=t}function Vxe(e,t){this.a=e,this.b=t}function Hxe(e,t){this.a=e,this.b=t}function Uxe(e,t){so.call(this,e,t)}function Wxe(e,t){so.call(this,e,t)}function Gxe(e,t){this.a=e,this.b=t}function Kxe(e,t){return Rf(),t!=e}function uc(e){return jd(e.a),e.b}function dc(e){return Drt(e,e.c),e}function qxe(){return tye(),new rEt}function Jxe(){If(),this.a=new Zd}function Yxe(){rM(),this.a=new Jr}function Xxe(){B_(),this.b=new Jr}function Zxe(e,t){this.b=e,this.d=t}function Qxe(e,t){this.a=e,this.b=t}function $xe(e,t){this.a=e,this.b=t}function eSe(e,t){this.a=e,this.b=t}function tSe(e,t){this.b=e,this.a=t}function nSe(e,t){so.call(this,e,t)}function rSe(e,t){so.call(this,e,t)}function fc(e,t){so.call(this,e,t)}function pc(e,t){so.call(this,e,t)}function mc(e,t){so.call(this,e,t)}function hc(e,t){so.call(this,e,t)}function iSe(e,t){so.call(this,e,t)}function aSe(e,t){so.call(this,e,t)}function gc(e,t){so.call(this,e,t)}function oSe(e,t){so.call(this,e,t)}function _c(e,t){so.call(this,e,t)}function vc(e,t){so.call(this,e,t)}function yc(e,t){so.call(this,e,t)}function bc(e,t){so.call(this,e,t)}function xc(e,t){so.call(this,e,t)}function Sc(e,t){so.call(this,e,t)}function sSe(e,t){so.call(this,e,t)}function Cc(e,t){so.call(this,e,t)}function cSe(e,t){so.call(this,e,t)}function wc(e,t){so.call(this,e,t)}function Tc(e,t){so.call(this,e,t)}function lSe(e,t){so.call(this,e,t)}function Ec(e,t){so.call(this,e,t)}function uSe(e,t){so.call(this,e,t)}function dSe(e,t){this.b=e,this.a=t}function fSe(e,t){this.b=e,this.a=t}function pSe(e,t){this.b=e,this.a=t}function mSe(e,t){this.b=e,this.a=t}function hSe(e,t){this.a=e,this.b=t}function gSe(e,t){this.a=e,this.b=t}function _Se(e,t){this.a=e,this.b=t}function k(e,t){this.a=e,this.b=t}function Dc(e,t){so.call(this,e,t)}function Oc(e,t){so.call(this,e,t)}function kc(e,t){so.call(this,e,t)}function Ac(e,t){so.call(this,e,t)}function jc(e,t){so.call(this,e,t)}function Mc(e,t){so.call(this,e,t)}function Nc(e,t){so.call(this,e,t)}function Pc(e,t){so.call(this,e,t)}function Fc(e,t){so.call(this,e,t)}function Ic(e,t){so.call(this,e,t)}function Lc(e,t){so.call(this,e,t)}function Rc(e,t){so.call(this,e,t)}function zc(e,t){so.call(this,e,t)}function Bc(e,t){so.call(this,e,t)}function Vc(e,t){so.call(this,e,t)}function Hc(e,t){so.call(this,e,t)}function Uc(e,t){so.call(this,e,t)}function Wc(e,t){so.call(this,e,t)}function vSe(e,t){so.call(this,e,t)}function Gc(e,t){so.call(this,e,t)}function ySe(e,t){this.a=e,this.b=t}function bSe(e,t){this.a=e,this.b=t}function xSe(e,t){this.a=e,this.b=t}function SSe(e,t){this.a=e,this.b=t}function CSe(e,t){this.a=e,this.b=t}function wSe(e,t){this.a=e,this.b=t}function Kc(e,t){this.a=e,this.b=t}function TSe(e,t){this.a=e,this.b=t}function ESe(e,t){this.a=e,this.b=t}function DSe(e,t){this.a=e,this.b=t}function OSe(e,t){this.a=e,this.b=t}function kSe(e,t){this.a=e,this.b=t}function ASe(e,t){this.a=e,this.b=t}function jSe(e,t){this.b=e,this.a=t}function MSe(e,t){this.b=e,this.a=t}function NSe(e,t){this.b=e,this.a=t}function PSe(e,t){this.b=e,this.a=t}function FSe(e,t){this.a=e,this.b=t}function ISe(e,t){this.a=e,this.b=t}function qc(e,t){so.call(this,e,t)}function LSe(e,t){this.a=e,this.b=t}function RSe(e,t){this.a=e,this.b=t}function Jc(e,t){so.call(this,e,t)}function zSe(e,t){this.f=e,this.c=t}function Yc(e,t){return $u(e.g,t)}function BSe(e,t){return $u(t.b,e)}function VSe(e,t){return uD(e.a,t)}function HSe(e,t){return-e.b.af(t)}function USe(e,t){e&&Qh(f7,e,t)}function Xc(e,t){e.i=null,OS(e,t)}function WSe(e,t,n){I8e(t,KA(e,n))}function GSe(e,t,n){I8e(t,KA(e,n))}function KSe(e,t){not(e.a,P(t,58))}function qSe(e,t){KGe(e.a,P(t,12))}function Zc(e,t){this.a=e,this.b=t}function JSe(e,t){this.a=e,this.b=t}function YSe(e,t){this.a=e,this.b=t}function XSe(e,t){this.a=e,this.b=t}function ZSe(e,t){this.a=e,this.b=t}function QSe(e,t){this.d=e,this.b=t}function $Se(e,t){this.e=e,this.a=t}function Qc(e,t){this.b=e,this.c=t}function $c(e,t){this.i=e,this.g=t}function el(e,t){this.d=e,this.e=t}function eCe(e,t){kKe(new Lu(e),t)}function tl(e){return lD(e.c,e.b)}function nl(e){return e?e.md():null}function A(e){return e??null}function rl(e){return typeof e===OP}function il(e){return typeof e===DP}function al(e){return typeof e===Vvt}function ol(e,t){return dT(e,t)==0}function sl(e,t){return dT(e,t)>=0}function cl(e,t){return dT(e,t)!=0}function ll(e,t){return VYe(e.Kc(),t)}function ul(e,t){return e.Rd().Xb(t)}function tCe(e){return RE(e),e.d.gc()}function dl(e){return bp(e==null),e}function fl(e,t){return e.a+=``+t,e}function pl(e,t){return e.a+=``+t,e}function ml(e,t){return e.a+=``+t,e}function hl(e,t){return e.a+=``+t,e}function gl(e,t){return e.a+=``+t,e}function _l(e,t){return e.a+=``+t,e}function nCe(e){return``+(Gh(e),e)}function rCe(e){Pm(this),mC(this,e)}function iCe(){ERe(),bNe.call(this)}function aCe(e,t){GNe.call(this,e,t)}function oCe(e,t){GNe.call(this,e,t)}function vl(e,t){GNe.call(this,e,t)}function yl(e,t){iy(e,t,e.c.b,e.c)}function bl(e,t){iy(e,t,e.a,e.a.a)}function xl(e){return ov(e,0),null}function sCe(){this.b=0,this.a=!1}function cCe(){this.b=0,this.a=!1}function lCe(){this.b=new go(xx(12))}function uCe(){uCe=C,oDt=nT(sO())}function dCe(){dCe=C,NOt=nT(wot())}function fCe(){fCe=C,NPt=nT(qYe())}function Sl(){Sl=C,vge(),uG=new Dr}function Cl(e){return e.a=0,e.b=0,e}function pCe(e,t){return e.a=t.g+1,e}function wl(e,t){lf.call(this,e,t)}function Tl(e,t){Wd.call(this,e,t)}function El(e,t){$c.call(this,e,t)}function mCe(e,t){ad.call(this,e,t)}function Dl(e,t){WC.call(this,e,t)}function Ol(e,t){Jo(),Qh(v7,e,t)}function hCe(e,t){e.q.setTime(Dv(t))}function gCe(e){r.clearTimeout(e)}function _Ce(e){return ph(e),new Hl(e)}function vCe(e,t){return A(e)===A(t)}function yCe(e,t){return e.a.a.a.cc(t)}function kl(e,t){return p_(e.a,0,t)}function Al(e){return zPe(P(e,74))}function jl(e){return C_((Gh(e),e))}function bCe(e){return C_((Gh(e),e))}function xCe(e){return vu(e.l,e.m,e.h)}function Ml(e,t){return _u(e.a,t.a)}function SCe(e,t){return DPe(e.a,t.a)}function CCe(e,t){return aE(e.a,t.a)}function Nl(e,t){return e.indexOf(t)}function wCe(e,t){return e.j[t.p]==2}function Pl(e,t){return e==t?0:e?1:-1}function Fl(e){return e<10?`0`+e:``+e}function Il(e){return typeof e===Vvt}function TCe(e){return e==kJ||e==MJ}function ECe(e){return e==kJ||e==AJ}function DCe(e,t){return _u(e.g,t.g)}function Ll(e){return Ab(e.b.b,e,0)}function OCe(){Np.call(this,0,0,0,0)}function Rl(){Xn.call(this,new ry)}function zl(e,t){bb(e,0,e.length,t)}function kCe(e,t){return M(e.a,t),t}function ACe(e,t){return Lf(),t.a+=e}function jCe(e,t){return Lf(),t.a+=e}function MCe(e,t){return Lf(),t.c+=e}function NCe(e,t){return M(e.c,t),e}function Bl(e,t){return OC(e.a,t),e}function PCe(e){this.a=qxe(),this.b=e}function FCe(e){this.a=qxe(),this.b=e}function Vl(e){this.a=e.a,this.b=e.b}function Hl(e){this.a=e,dn.call(this)}function ICe(e){this.a=e,dn.call(this)}function Ul(){wg.call(this,0,0,0,0)}function Wl(e){return OC(new Zh,e)}function LCe(e){return ag(P(e,123))}function Gl(e){return e.vh()&&e.wh()}function Kl(e){return e!=V8&&e!=H8}function ql(e){return e==t8||e==n8}function Jl(e){return e==i8||e==e8}function RCe(e){return e==L0||e==I0}function zCe(e,t){return _u(e.g,t.g)}function BCe(e,t){return new WC(t,e)}function VCe(e,t){return new WC(t,e)}function Yl(e){return wje(e.b.Kc(),e.a)}function Xl(e,t){Gw(e,t),eS(e,e.D)}function Zl(e,t,n){Xx(e,t),Vx(e,n)}function Ql(e,t,n){Wx(e,t),Ux(e,n)}function $l(e,t,n){Gx(e,t),Kx(e,n)}function eu(e,t,n){Hx(e,t),Jx(e,n)}function tu(e,t,n){qx(e,t),Yx(e,n)}function HCe(e,t,n){mDe.call(this,e,t,n)}function nu(e){zSe.call(this,e,!0)}function UCe(){ls.call(this,`Tail`,3)}function WCe(){ls.call(this,`Head`,1)}function ru(e){AM(),IYe.call(this,e)}function iu(e){Np.call(this,e,e,e,e)}function au(e){e.c=V(WW,FP,1,0,5,1)}function GCe(e){return e.b&&yN(e),e.a}function KCe(e){return e.b&&yN(e),e.c}function qCe(e,t){_K||(e.b=t)}function JCe(e,t){return e[e.length]=t}function YCe(e,t){return e[e.length]=t}function XCe(e,t){return Ex(t,E_(e))}function ZCe(e,t){return Ex(t,E_(e))}function QCe(e,t){return yS(uh(e.d),t)}function $Ce(e,t){return yS(uh(e.g),t)}function ewe(e,t){return yS(uh(e.j),t)}function ou(e,t){Wd.call(this,e.b,t)}function twe(e,t){tb(Jv(e.a),IRe(t))}function nwe(e,t){tb(Ib(e.a),LRe(t))}function rwe(e,t,n){$l(n,n.i+e,n.j+t)}function iwe(e,t,n){Sh(e.c[t.g],t.g,n)}function awe(e,t,n){P(e.c,71).Gi(t,n)}function su(e,t,n){return Sh(e,t,n),n}function owe(e){Dx(e.Sf(),new Zfe(e))}function cu(e){return e==null?0:US(e)}function swe(e){return e==null?0:US(e)}function lu(e){xP(),Tr.call(this,e)}function cwe(e){this.a=e,xje.call(this,e)}function uu(){uu=C,r.Math.log(2)}function du(){du=C,s9=(Xbe(),mVt)}function lwe(){lwe=C,D2=new NE(p8)}function fu(){fu=C,new uwe,new T}function uwe(){new Dr,new Dr,new Dr}function dwe(){throw E(new Ri(_Tt))}function fwe(){throw E(new Ri(_Tt))}function pwe(){throw E(new Ri(vTt))}function mwe(){throw E(new Ri(vTt))}function pu(e){this.a=e,co.call(this,e)}function mu(e){this.a=e,co.call(this,e)}function hwe(e,t){gh(),this.a=e,this.b=t}function gwe(e,t){ph(t),bg(e).Jc(new m)}function hu(e,t){qp(e.c,e.c.length,t)}function gu(e){return e.at)}function ywe(e,t){return dT(e,t)>0?e:t}function vu(e,t,n){return{l:e,m:t,h:n}}function bwe(e,t){e.a!=null&&qSe(t,e.a)}function xwe(e){U_(e,null),K_(e,null)}function Swe(e,t,n){return Qh(e.g,n,t)}function yu(e,t,n){return AD(t,n,e.c)}function Cwe(e,t,n){return Qh(e.k,n,t)}function wwe(e,t,n){return kht(e,t,n),n}function Twe(e,t){return z_(),t.n.b+=e}function Ewe(e){r_.call(this),this.b=e}function Dwe(e){$De.call(this),this.a=e}function Owe(){ls.call(this,`Range`,2)}function bu(e){this.b=e,this.a=new T}function kwe(e){this.b=new jt,this.a=e}function Awe(e){e.a=new me,e.c=new me}function jwe(e){e.a=new Dr,e.d=new Dr}function Mwe(e){q_(e,null),J_(e,null)}function Nwe(e,t){return Nht(e.a,t,null)}function Pwe(e,t){return Qh(e.a,t.a,t)}function xu(e){return new k(e.a,e.b)}function Fwe(e){return new k(e.c,e.d)}function Iwe(e){return new k(e.c,e.d)}function Su(e,t){return xmt(e.c,e.b,t)}function j(e,t){return e!=null&&kO(e,t)}function Cu(e,t){return XXe(e.Kc(),t)!=-1}function wu(e){return e.Ob()?e.Pb():null}function Lwe(e){this.b=(Vg(),new Kn(e))}function Rwe(e){this.a=e,Dr.call(this)}function zwe(){ad.call(this,null,null)}function Bwe(){od.call(this,null,null)}function Vwe(){so.call(this,`INSTANCE`,0)}function Hwe(){i8e(),this.a=new Yj(CJ)}function Uwe(e){return ND(e,0,e.length)}function Wwe(e,t){return new PTe(e.Kc(),t)}function Gwe(e,t){return e.a.Bc(t)!=null}function Kwe(e,t){RN(e),e.Gc(P(t,15))}function qwe(e,t,n){e.c.bd(t,P(n,136))}function Jwe(e,t,n){e.c.Ui(t,P(n,136))}function Ywe(e,t){e.c&&(pMe(t),LLe(t))}function Xwe(e,t){e.q.setHours(t),dN(e,t)}function Zwe(e,t){Sd(t,e.a.a.a,e.a.a.b)}function Qwe(e,t,n,r){Sh(e.a[t.g],n.g,r)}function Tu(e,t,n){return e.a[t.g][n.g]}function $we(e,t){return e.e[t.c.p][t.p]}function eTe(e,t){return e.c[t.c.p][t.p]}function Eu(e,t){return e.a[t.c.p][t.p]}function tTe(e,t){return e.j[t.p]=Aat(t)}function Du(e,t){return e.a.Bc(t)!=null}function nTe(e,t){return D(N(t.a))<=e}function rTe(e,t){return D(N(t.a))>=e}function iTe(e,t){return zUe(e.f,t.Pg())}function Ou(e,t){return e.a*t.a+e.b*t.b}function aTe(e,t){return e.a0?t/(e*e):t*100}function SEe(e,t){return e>0?t*t/e:t*t*100}function xd(e,t){return P(ix(e.a,t),34)}function CEe(e,t){return wA(),fj(e,t.e,t)}function wEe(e,t,n){return zo(),n.Mg(e,t)}function TEe(e){return zx(),e.e.a+e.f.a/2}function EEe(e,t,n){return zx(),n.e.a-e*t}function DEe(e){return zx(),e.e.b+e.f.b/2}function OEe(e,t,n){return zx(),n.e.b-e*t}function kEe(e){e.d=new gEe(e),e.e=new Dr}function AEe(){this.a=new g_,this.b=new g_}function jEe(e){this.c=e,this.a=1,this.b=1}function MEe(e){dP(),lge(this),this.Ff(e)}function NEe(e,t,n){gb(),e.pf(t)&&n.Cd(e)}function PEe(e,t,n){return M(t,Y1e(e,n))}function Sd(e,t,n){return e.a+=t,e.b+=n,e}function FEe(e,t,n){return e.a*=t,e.b*=n,e}function IEe(e,t){return e.a=t.a,e.b=t.b,e}function Cd(e){return e.a=-e.a,e.b=-e.b,e}function wd(e,t,n){return e.a-=t,e.b-=n,e}function LEe(e){vo.call(this),_S(this,e)}function REe(){so.call(this,`GROW_TREE`,0)}function zEe(){so.call(this,`POLYOMINO`,0)}function Td(e,t,n){lb.call(this,e,t,n,2)}function BEe(e,t,n){WT(Jv(e.a),t,IRe(n))}function VEe(e,t){Yo(),ad.call(this,e,t)}function HEe(e,t){Xo(),od.call(this,e,t)}function UEe(e,t){Xo(),HEe.call(this,e,t)}function WEe(e,t){Xo(),od.call(this,e,t)}function GEe(e,t){return e.c.Fc(P(t,136))}function KEe(e,t,n){WT(Ib(e.a),t,LRe(n))}function qEe(e){this.c=e,Gx(e,0),Kx(e,0)}function Ed(e,t){du(),Bp.call(this,e,t)}function JEe(e,t){du(),Ed.call(this,e,t)}function YEe(e,t){du(),Ed.call(this,e,t)}function XEe(e,t){du(),Bp.call(this,e,t)}function ZEe(e,t){du(),YEe.call(this,e,t)}function QEe(e,t){du(),XEe.call(this,e,t)}function $Ee(e,t){du(),Bp.call(this,e,t)}function eDe(e,t,n){return t.zl(e.e,e.c,n)}function tDe(e,t,n){return t.Al(e.e,e.c,n)}function nDe(e,t,n){return jN(Lb(e,t),n)}function Dd(e,t){return pT(e.e,P(t,54))}function rDe(e){return e==null?null:Fgt(e)}function iDe(e){return e==null?null:G9e(e)}function aDe(e){return e==null?null:PE(e)}function oDe(e){return e==null?null:PE(e)}function Od(e){return bp(e==null||il(e)),e}function N(e){return bp(e==null||al(e)),e}function kd(e){return bp(e==null||rl(e)),e}function Ad(e){e.o??zit(e)}function sDe(e){if(!e)throw E(new Lr)}function cDe(e){if(!e)throw E(new Ir)}function jd(e){if(!e)throw E(new Hr)}function Md(e){if(!e)throw E(new Rr)}function lDe(e){if(!e)throw E(new Vr)}function Nd(){Nd=C,_7=new c_e,new l_e}function Pd(){Pd=C,y4=new yr(`root`)}function uDe(){EJe.call(this),this.Bb|=pI}function dDe(e,t){this.d=e,wfe(this),this.b=t}function fDe(e,t){Qy.call(this,e),this.a=t}function pDe(e,t){Qy.call(this,e),this.a=t}function mDe(e,t,n){Ry.call(this,e,t,n,null)}function hDe(e,t,n){Ry.call(this,e,t,n,null)}function Fd(e,t){this.c=e,io.call(this,e,t)}function Id(e,t){this.a=e,Fd.call(this,e,t)}function gDe(e){this.q=new r.Date(Dv(e))}function _De(e){return e>8?0:e+1}function vDe(e,t){_K||M(e.a,t)}function yDe(e,t){return Io(),jC(t.d.i,e)}function bDe(e,t){return cC(),new Ilt(t,e)}function xDe(e,t,n){return e.Ne(t,n)<=0?n:t}function SDe(e,t,n){return e.Ne(t,n)<=0?t:n}function CDe(e,t){return P(ix(e.b,t),143)}function wDe(e,t){return P(ix(e.c,t),233)}function Ld(e){return P(Ep(e.a,e.b),294)}function TDe(e){return new k(e.c,e.d+e.a)}function EDe(e){return Gh(e),e?1231:1237}function DDe(e){return z_(),RCe(P(e,203))}function Rd(){Rd=C,lq=sE((TD(),x5))}function ODe(e,t){t.a?Irt(e,t):Du(e.a,t.b)}function zd(e,t,n){++e.j,e.tj(),Xy(e,t,n)}function kDe(e,t,n){++e.j,e.qj(t,e.Zi(t,n))}function ADe(e,t,n){e.fd(t).Rb(n)}function jDe(e,t,n){return n=qM(e,t,6,n),n}function Bd(e,t,n){return n=qM(e,t,3,n),n}function Vd(e,t,n){return n=qM(e,t,9,n),n}function Hd(e,t){return c_(t,Iyt),e.f=t,e}function MDe(e,t){return(t&AP)%e.d.length}function NDe(e,t,n){return Xft(e.c,e.b,t,n)}function PDe(e,t){this.c=e,kx.call(this,t)}function FDe(e,t){this.a=e,Hhe.call(this,t)}function Ud(e,t){this.a=e,Hhe.call(this,t)}function Wd(e,t){yr.call(this,e),this.a=t}function IDe(e,t){Khe.call(this,e),this.a=t}function Gd(e,t){Khe.call(this,e),this.a=t}function LDe(e){iD.call(this,0,0),this.f=e}function RDe(e,t,n){return e.a+=ND(t,0,n),e}function Kd(e){return!e.a&&(e.a=new ee),e.a}function zDe(e,t){var n=e.e;return e.e=t,n}function BDe(e,t){var n=t;return!!e.Fe(n)}function VDe(e,t){return rd(),e==t?0:e?1:-1}function qd(e,t){e.a.bd(e.b,t),++e.b,e.c=-1}function Jd(e){e.b?Jd(e.b):e.f.c.zc(e.e,e.d)}function HDe(e){Pm(e.e),e.d.b=e.d,e.d.a=e.d}function UDe(e,t,n){wo(),jde(e,t.Ve(e.a,n))}function WDe(e,t,n){return zm(e,P(t,22),n)}function Yd(e,t){return ua(Array(t),e)}function GDe(e){return nm(um(e,32))^nm(e)}function Xd(e){return String.fromCharCode(e)}function KDe(e){return e==null?null:e.message}function qDe(e,t,n){return e.apply(t,n)}function JDe(e,t){e[TI].call(e,t)}function YDe(e,t){e[TI].call(e,t)}function XDe(e,t){return Io(),!jC(t.d.i,e)}function ZDe(e,t,n,r){Np.call(this,e,t,n,r)}function QDe(){Qd.call(this),this.a=new Fa}function $De(){this.n=new Fa,this.o=new Fa}function eOe(){this.b=new Fa,this.c=new T}function tOe(){this.a=new T,this.b=new T}function nOe(){this.a=new Vt,this.b=new Tge}function Zd(){this.b=new ry,this.a=new ry}function rOe(){this.b=new Jr,this.a=new Jr}function iOe(){this.b=new Dr,this.a=new Dr}function aOe(){this.b=new _ye,this.a=new iae}function oOe(){this.a=new Tue,this.b=new Ure}function sOe(){this.a=new T,this.d=new T}function Qd(){this.n=new ni,this.i=new Ul}function cOe(e){this.a=(vS(e,hF),new Hy(e))}function lOe(e){this.a=(vS(e,hF),new Hy(e))}function uOe(e){return e<100?null:new Pa(e)}function dOe(e,t){return e.n.a=(Gh(t),t+10)}function fOe(e,t){return e.n.a=(Gh(t),t+10)}function pOe(e,t){return t==e||Uk(zj(t),e)}function mOe(e,t){return Qh(e.a,t,``)==null}function hOe(e,t){return t.qi(e.a)}function $d(e,t){return e.a+=t.a,e.b+=t.b,e}function ef(e,t){return e.a-=t.a,e.b-=t.b,e}function gOe(e){return Wr(e.j.c,0),e.a=-1,e}function tf(e,t,n){return n=qM(e,t,11,n),n}function _Oe(e,t,n){n!=null&&TS(t,dk(e,n))}function vOe(e,t,n){n!=null&&ES(t,dk(e,n))}function nf(e,t,n,r){F.call(this,e,t,n,r)}function rf(e,t,n,r){F.call(this,e,t,n,r)}function yOe(e,t,n,r){rf.call(this,e,t,n,r)}function bOe(e,t,n,r){wm.call(this,e,t,n,r)}function af(e,t,n,r){wm.call(this,e,t,n,r)}function of(e,t,n,r){wm.call(this,e,t,n,r)}function xOe(e,t,n,r){af.call(this,e,t,n,r)}function sf(e,t,n,r){af.call(this,e,t,n,r)}function cf(e,t,n,r){of.call(this,e,t,n,r)}function SOe(e,t,n,r){sf.call(this,e,t,n,r)}function COe(e,t,n,r){dPe.call(this,e,t,n,r)}function lf(e,t){Mi.call(this,PU+e+bU+t)}function uf(e,t){return e.jk().wi().ri(e,t)}function df(e,t){return e.jk().wi().ti(e,t)}function wOe(e,t){return Gh(e),A(e)===A(t)}function ff(e,t){return Gh(e),A(e)===A(t)}function TOe(e,t){return e.b.Bd(new sxe(e,t))}function EOe(e,t){return e.b.Bd(new cxe(e,t))}function DOe(e,t){return e.b.Bd(new lxe(e,t))}function OOe(e,t){return e.e=P(e.d.Kb(t),159)}function pf(e,t,n){return e.lastIndexOf(t,n)}function kOe(e,t,n){return aE(e[t.a],e[n.a])}function AOe(e,t){return W(t,(mP(),d1),e)}function jOe(e,t){return _u(t.a.d.p,e.a.d.p)}function MOe(e,t){return _u(e.a.d.p,t.a.d.p)}function NOe(e,t){return aE(e.c-e.s,t.c-t.s)}function POe(e,t){return aE(e.b.e.a,t.b.e.a)}function FOe(e,t){return aE(e.c.e.a,t.c.e.a)}function IOe(e){return e.c?Ab(e.c.a,e,0):-1}function mf(e){return e==L8||e==z8||e==R8}function LOe(e,t){this.c=e,Hm.call(this,e,t)}function ROe(e,t,n){this.a=e,sEe.call(this,t,n)}function zOe(e){this.c=e,vl.call(this,tF,0)}function BOe(e,t,n){this.c=t,this.b=n,this.a=e}function hf(e){Rf(),this.d=e,this.a=new Iu}function VOe(e){wf(),this.a=(Vg(),new oa(e))}function HOe(e,t){ql(e.f)?Ait(e,t):f7e(e,t)}function UOe(e,t){kje.call(this,e,e.length,t)}function WOe(e,t){_K||t&&(e.d=t)}function GOe(e,t){return j(t,15)&&Mct(e.c,t)}function KOe(e,t,n){return P(e.c,71).Wk(t,n)}function gf(e,t,n){return P(e.c,71).Xk(t,n)}function qOe(e,t,n){return eDe(e,P(t,343),n)}function JOe(e,t,n){return tDe(e,P(t,343),n)}function YOe(e,t,n){return E5e(e,P(t,343),n)}function XOe(e,t,n){return A7e(e,P(t,343),n)}function _f(e,t){return t==null?null:TT(e.b,t)}function ZOe(e){return al(e)?(Gh(e),e):e.ue()}function vf(e){return!isNaN(e)&&!isFinite(e)}function yf(e){Awe(this),Fg(this),XS(this,e)}function bf(e){au(this),Fje(this.c,0,e.Pc())}function xf(e,t,n){this.a=e,this.b=t,this.c=n}function QOe(e,t,n){this.a=e,this.b=t,this.c=n}function $Oe(e,t,n){this.d=e,this.b=n,this.a=t}function eke(e){this.a=e,yo(),LC(Date.now())}function tke(e){Fh(e.a),KWe(e.c,e.b),e.b=null}function Sf(){Sf=C,aK=new he,oEt=new ge}function nke(){nke=C,TVt=V(WW,FP,1,0,5,1)}function rke(){rke=C,QVt=V(WW,FP,1,0,5,1)}function Cf(){Cf=C,$Vt=V(WW,FP,1,0,5,1)}function wf(){wf=C,new mge((Vg(),Vg(),QG))}function ike(e){return Sb(),iS((TGe(),dEt),e)}function ake(e){return Zw(),iS((MWe(),vEt),e)}function oke(e){return fO(),iS((wHe(),DEt),e)}function ske(e){return dx(),iS((THe(),OEt),e)}function cke(e){return vM(),iS((CXe(),kEt),e)}function lke(e){return Ix(),iS((AWe(),MEt),e)}function uke(e){return Cb(),iS((kWe(),PEt),e)}function dke(e){return Xb(),iS((jWe(),LEt),e)}function fke(e){return SP(),iS((uCe(),oDt),e)}function pke(e){return KC(),iS((DGe(),cDt),e)}function mke(e){return TO(),iS((kGe(),uDt),e)}function hke(e){return wO(),iS((OGe(),mDt),e)}function gke(e){return No(),iS((VBe(),hDt),e)}function _ke(e){return fx(),iS((EHe(),NDt),e)}function vke(e){return Yb(),iS((NWe(),aOt),e)}function yke(e){return vA(),iS((PKe(),lOt),e)}function bke(e){return ow(),iS((jGe(),hOt),e)}function xke(e){return YD(),iS((AGe(),xOt),e)}function Tf(e,t){if(!e)throw E(new Fi(t))}function Ef(e){if(!e)throw E(new Ii(Wvt))}function Df(e,t){if(e!=t)throw E(new Vr)}function Ske(e,t,n){this.a=e,this.b=t,this.c=n}function Of(e,t,n){this.a=e,this.b=t,this.c=n}function Cke(e,t,n){this.a=e,this.b=t,this.c=n}function kf(e,t,n){this.b=e,this.a=t,this.c=n}function Af(e,t,n){this.b=e,this.c=t,this.a=n}function jf(e,t,n){this.a=e,this.b=t,this.c=n}function Mf(e,t,n){this.e=t,this.b=e,this.d=n}function wke(e,t,n){this.b=e,this.a=t,this.c=n}function Tke(e,t,n){return wo(),e.a.Yd(t,n),t}function Nf(e){var t=new Ze;return t.e=e,t}function Pf(e){var t=new Hge;return t.b=e,t}function Ff(){Ff=C,oY=new vte,sY=new yte}function If(){If=C,ROt=new Kte,LOt=new qte}function Lf(){Lf=C,UOt=new tre,WOt=new nre}function Eke(e){return kS(),iS((uWe(),ekt),e)}function Dke(e){return yP(),iS((dCe(),NOt),e)}function Oke(e){return iw(),iS((NGe(),IOt),e)}function kke(e){return aw(),iS((MGe(),qOt),e)}function Ake(e){return tA(),iS((FKe(),YOt),e)}function jke(e){return dM(),iS((KYe(),tkt),e)}function Mke(e){return GA(),iS((Eqe(),nkt),e)}function Nke(e){return Ky(),iS((NHe(),rkt),e)}function Pke(e){return bS(),iS((cWe(),ikt),e)}function Fke(e){return lS(),iS((lWe(),akt),e)}function Ike(e){return FD(),iS((IKe(),okt),e)}function Lke(e){return px(),iS((kHe(),skt),e)}function Rke(e){return TA(),iS((kqe(),pkt),e)}function zke(e){return uM(),iS((gZe(),mkt),e)}function Bke(e){return qC(),iS((fWe(),hkt),e)}function Vke(e){return Zb(),iS((pWe(),_kt),e)}function Hke(e){return Bv(),iS((OHe(),vkt),e)}function Uke(e){return qk(),iS((Oqe(),fkt),e)}function Wke(e){return _w(),iS((dWe(),lkt),e)}function Gke(e){return kA(),iS((Dqe(),ukt),e)}function Kke(e){return wb(),iS((AHe(),dkt),e)}function qke(e){return XE(),iS((RKe(),ykt),e)}function Jke(e){return Zj(),iS((bXe(),MMt),e)}function Yke(e){return hT(),iS((mWe(),FMt),e)}function Xke(e){return IO(),iS((PGe(),IMt),e)}function Zke(e){return CO(),iS((LKe(),zMt),e)}function Qke(e){return FM(),iS((_Ze(),GMt),e)}function $ke(e){return ID(),iS((FGe(),JMt),e)}function eAe(e){return Qb(),iS((jHe(),XMt),e)}function tAe(e){return uS(),iS((_We(),QMt),e)}function nAe(e){return CC(),iS((hWe(),nNt),e)}function rAe(e){return Nw(),iS((gWe(),iNt),e)}function iAe(e){return Xw(),iS((vWe(),sNt),e)}function aAe(e){return cS(),iS((yWe(),dNt),e)}function oAe(e){return sw(),iS((bWe(),pNt),e)}function sAe(e){return sS(),iS((OWe(),jNt),e)}function cAe(e){return Vv(),iS((MHe(),RNt),e)}function lAe(e){return O_(),iS((IHe(),qNt),e)}function uAe(e){return k_(),iS((LHe(),YNt),e)}function dAe(e){return Wy(),iS((RHe(),dPt),e)}function fAe(e){return D_(),iS((zHe(),vPt),e)}function pAe(e){return Ok(),iS((YGe(),bPt),e)}function mAe(e){return LM(),iS((fCe(),NPt),e)}function hAe(e){return Pw(),iS((xWe(),IPt),e)}function gAe(e){return Jw(),iS((JGe(),TFt),e)}function _Ae(e){return iv(),iS((PHe(),OFt),e)}function vAe(e){return AS(),iS((FHe(),PFt),e)}function yAe(e){return iA(),iS((zKe(),IFt),e)}function bAe(e){return Yw(),iS((SWe(),UFt),e)}function xAe(e){return _b(),iS((BHe(),zFt),e)}function SAe(e){return uk(),iS((qGe(),wIt),e)}function CAe(e){return SC(),iS((CWe(),OIt),e)}function wAe(e){return ED(),iS((wWe(),AIt),e)}function TAe(e){return LO(),iS((TWe(),MIt),e)}function EAe(e){return TE(),iS((EWe(),RIt),e)}function DAe(e){return my(),iS((VHe(),xLt),e)}function OAe(e){return dC(),iS((DHe(),AOt),e)}function kAe(e){return DA(),iS((Aqe(),TOt),e)}function AAe(e){return Tb(),iS((DWe(),TLt),e)}function jAe(e){return JC(),iS((HHe(),kLt),e)}function MAe(e){return Wj(),iS((BKe(),MLt),e)}function NAe(e){return Bo(),iS((sVe(),FLt),e)}function PAe(e){return KT(),iS((FWe(),NLt),e)}function FAe(e){return Vo(),iS((cVe(),LLt),e)}function IAe(e){return Gy(),iS((UHe(),zLt),e)}function LAe(e){return MA(),iS((VKe(),WLt),e)}function RAe(e){return Ho(),iS((lVe(),SRt),e)}function zAe(e){return cw(),iS((WHe(),TRt),e)}function BAe(e){return uO(),iS((UKe(),FRt),e)}function VAe(e){return VA(),iS((WYe(),RRt),e)}function HAe(e){return RO(),iS((jqe(),HRt),e)}function UAe(e){return eA(),iS((Mqe(),ezt),e)}function WAe(e){return GT(),iS((HKe(),nBt),e)}function GAe(e){return Lx(),iS((IWe(),iBt),e)}function KAe(e){return wE(),iS((XGe(),aBt),e)}function qAe(e){return hA(),iS((Nqe(),fBt),e)}function JAe(e){return _T(),iS((PWe(),bBt),e)}function YAe(e){return kk(),iS((ZGe(),SBt),e)}function XAe(e){return Ej(),iS((SXe(),CBt),e)}function ZAe(e){return pO(),iS((WKe(),EBt),e)}function QAe(e){return rA(),iS((Pqe(),OBt),e)}function $Ae(e){return rj(),iS((Fqe(),kBt),e)}function eje(e){return nP(),iS((GKe(),ABt),e)}function tje(e){return TD(),iS((QGe(),IBt),e)}function nje(e){return UM(),iS((xXe(),RBt),e)}function rje(e){return gT(),iS((LWe(),VBt),e)}function ije(e,t){return Gh(e),e+(Gh(t),t)}function aje(e){return zf(),iS((GHe(),WBt),e)}function oje(e){return ZE(),iS(($Ge(),YBt),e)}function sje(e){return Mw(),iS((eKe(),tVt),e)}function Rf(){Rf=C,PNt=(nP(),g5),v2=X8}function zf(){zf=C,HBt=new AMe,UBt=new cPe}function cje(e){return!e.e&&(e.e=new T),e.e}function Bf(e,t){this.c=e,this.a=t,this.b=t-e}function lje(e,t,n){this.a=e,this.b=t,this.c=n}function Vf(e,t,n){this.a=e,this.b=t,this.c=n}function Hf(e,t,n){this.a=e,this.b=t,this.c=n}function Uf(e,t,n){this.a=e,this.b=t,this.c=n}function uje(e,t,n){this.a=e,this.b=t,this.c=n}function dje(e,t,n){this.a=e,this.b=t,this.c=n}function Wf(e,t,n){this.e=e,this.a=t,this.c=n}function fje(e,t,n){du(),ILe.call(this,e,t,n)}function Gf(e,t,n){du(),Ph.call(this,e,t,n)}function pje(e,t,n){du(),Ph.call(this,e,t,n)}function mje(e,t,n){du(),Ph.call(this,e,t,n)}function hje(e,t,n){du(),Gf.call(this,e,t,n)}function gje(e,t,n){du(),Gf.call(this,e,t,n)}function _je(e,t,n){du(),gje.call(this,e,t,n)}function vje(e,t,n){du(),pje.call(this,e,t,n)}function yje(e,t,n){du(),mje.call(this,e,t,n)}function Kf(e){Np.call(this,e.d,e.c,e.a,e.b)}function bje(e){Np.call(this,e.d,e.c,e.a,e.b)}function xje(e){this.d=e,wfe(this),this.b=FNe(e.d)}function Sje(e){return Sj(),iS((GYe(),bVt),e)}function qf(e,t){return ph(e),ph(t),new Hye(e,t)}function Jf(e,t){return ph(e),ph(t),new oMe(e,t)}function Cje(e,t){return ph(e),ph(t),new sMe(e,t)}function wje(e,t){return ph(e),ph(t),new Qye(e,t)}function Yf(e){return jd(e.b!=0),Ox(e,e.a.a)}function Tje(e){return jd(e.b!=0),Ox(e,e.c.b)}function Eje(e){return!e.c&&(e.c=new ln),e.c}function Xf(e){var t=new T;return rx(t,e),t}function Dje(e){var t=new Jr;return rx(t,e),t}function Oje(e){var t=new Nge;return HS(t,e),t}function Zf(e){var t=new vo;return HS(t,e),t}function P(e,t){return bp(e==null||kO(e,t)),e}function kje(e,t,n){WNe.call(this,t,n),this.a=e}function Aje(e,t){this.c=e,this.b=t,this.a=!1}function jje(){this.a=`;,;`,this.b=``,this.c=``}function Mje(e,t,n){this.b=e,aCe.call(this,t,n)}function Nje(e,t,n){this.c=e,ds.call(this,t,n)}function Pje(e,t,n){js.call(this,e,t),this.b=n}function Fje(e,t,n){art(n,0,e,t,n.length,!1)}function Qf(e,t,n,r,i){e.b=t,e.c=n,e.d=r,e.a=i}function Ije(e,t,n,r,i){e.d=t,e.c=n,e.a=r,e.b=i}function Lje(e,t){t&&(e.b=t,e.a=(Hh(t),t.a))}function $f(e,t){if(!e)throw E(new Fi(t))}function ep(e,t){if(!e)throw E(new Ii(t))}function Rje(e,t){if(!e)throw E(new ove(t))}function zje(e,t){return Ro(),_u(e.d.p,t.d.p)}function Bje(e,t){return zx(),aE(e.e.b,t.e.b)}function Vje(e,t){return zx(),aE(e.e.a,t.e.a)}function Hje(e,t){return _u(bMe(e.d),bMe(t.d))}function tp(e,t){return t&&Lh(e,t.d)?t:null}function Uje(e,t){return t==(nP(),g5)?e.c:e.d}function Wje(e){return MC(gPe(Il(e)?zC(e):e))}function Gje(e){return new k(e.c+e.b,e.d+e.a)}function Kje(e){return e!=null&&!zE(e,y7,b7)}function qje(e,t){return(R$e(e)<<4|R$e(t))&OF}function Jje(e,t,n,r,i){e.c=t,e.d=n,e.b=r,e.a=i}function Yje(e){var t=e.b;e.b=e.c,e.c=t}function Xje(e){var t,n=e.d;t=e.a,e.d=t,e.a=n}function Zje(e,t){var n=e.c;return PJe(e,t),n}function Qje(e,t){return e.g=t<0?-1:t,e}function np(e,t){return bqe(e),e.a*=t,e.b*=t,e}function $je(e,t,n){pqe.call(this,t,n),this.d=e}function rp(e,t,n){el.call(this,e,t),this.c=n}function ip(e,t,n){el.call(this,e,t),this.c=n}function eMe(e){Cf(),sn.call(this),this.ci(e)}function tMe(){By(),uFe.call(this,(qo(),N7))}function nMe(e){return xP(),++W9,new zp(0,e)}function rMe(){rMe=C,f9=(Vg(),new Gn(xW))}function ap(){ap=C,new FO((mi(),ZW),(pi(),XW))}function iMe(){iMe=C,OG=V(DG,X,17,256,0,1)}function aMe(){this.b=D(N(hO((XM(),eJ))))}function op(e){this.b=e,this.a=am(this.b.a).Od()}function oMe(e,t){this.b=e,this.a=t,dn.call(this)}function sMe(e,t){this.a=e,this.b=t,dn.call(this)}function cMe(e,t,n){this.a=e,El.call(this,t,n)}function lMe(e,t,n){this.a=e,El.call(this,t,n)}function sp(e,t,n){hx(e,t,new mh(n))}function uMe(e,t,n){var r=e[t];return e[t]=n,r}function cp(e){return yb(e.slice(),e)}function lp(e){var t=e.n;return e.a.b+t.d+t.a}function dMe(e){var t=e.n;return e.e.b+t.d+t.a}function fMe(e){var t=e.n;return e.e.a+t.b+t.c}function pMe(e){e.a.b=e.b,e.b.a=e.a,e.a=e.b=null}function up(e,t){return iy(e,t,e.c.b,e.c),!0}function mMe(e){return e.a?e.a:xg(e)}function hMe(e){return Ug(),xA(e)==I_(SA(e))}function gMe(e){return Ug(),SA(e)==I_(xA(e))}function dp(e,t){return Bk(e,new js(t.a,t.b))}function _Me(e,t){return eg(),ik(e,t),new jFe(e,t)}function vMe(e,t){return e.c=t)throw E(new e_e)}function _m(e,t){return MT(e,(Gh(t),new jfe(t)))}function vm(e,t){return MT(e,(Gh(t),new Mfe(t)))}function XNe(e,t,n){return kvt(e,P(t,12),P(n,12))}function ZNe(e){return fC(),P(e,12).g.c.length!=0}function QNe(e){return fC(),P(e,12).e.c.length!=0}function $Ne(e,t){return cC(),aE(t.a.o.a,e.a.o.a)}function ePe(e,t){(t.Bb&GH)!=0&&!e.a.o&&(e.a.o=t)}function tPe(e,t){t.Ug(`General 'Rotator`,1),vgt(e)}function nPe(e,t,n){t.qf(n,D(N(xh(e.b,n)))*e.a)}function rPe(e,t,n){return fM(),_C(e,t)&&_C(e,n)}function ym(e){return rj(),!e.Hc(G8)&&!e.Hc(q8)}function iPe(e){return e.e?$Ue(e.e):null}function bm(e){return Il(e)?``+e:Ect(e)}function aPe(e){for(var t=e;t.f;)t=t.f;return t}function oPe(e,t,n){return Sh(t,0,Op(t[0],n[0])),t}function xm(e,t,n,r){var i=e.i;i.i=t,i.a=n,i.b=r}function F(e,t,n,r){ju.call(this,e,t,n),this.b=r}function Sm(e,t,n,r,i){ub.call(this,e,t,n,r,i,-1)}function Cm(e,t,n,r,i){db.call(this,e,t,n,r,i,-1)}function wm(e,t,n,r){rp.call(this,e,t,n),this.b=r}function sPe(e){zSe.call(this,e,!1),this.a=!1}function cPe(){vSe.call(this,`LOOKAHEAD_LAYOUT`,1)}function lPe(e){this.b=e,cd.call(this,e),CTe(this)}function uPe(e){this.b=e,ud.call(this,e),wTe(this)}function Tm(e,t,n){this.a=e,nf.call(this,t,n,5,6)}function dPe(e,t,n,r){this.b=e,ju.call(this,t,n,r)}function fPe(e,t){this.b=e,_de.call(this,e.b),this.a=t}function pPe(e){this.a=m4e(e.a),this.b=new bf(e.b)}function mPe(e,t){gh(),rbe.call(this,e,bT(new Wi(t)))}function Em(e,t){return xP(),++W9,new Nh(e,t,0)}function Dm(e,t){return xP(),++W9,new Nh(6,e,t)}function Om(e,t){for(Gh(t);e.Ob();)t.Cd(e.Pb())}function km(e,t){return rl(t)?e_(e,t):!!Kp(e.f,t)}function Am(e,t){return t.Vh()?pT(e.b,P(t,54)):t}function hPe(e,t){return ff(e.substr(0,t.length),t)}function jm(e){return new pm(new ATe(e.a.length,e.a))}function Mm(e){return new k(e.c+e.b/2,e.d+e.a/2)}function gPe(e){return vu(~e.l&QF,~e.m&QF,~e.h&$F)}function Nm(e){return typeof e===EP||typeof e===kP}function Pm(e){e.f=new PCe(e),e.i=new FCe(e),++e.g}function _Pe(e){if(!e)throw E(new Hr);return e.d}function Fm(e){var t=yw(e);return jd(t!=null),t}function vPe(e){var t=u1e(e);return jd(t!=null),t}function Im(e,t){var n=e.a.gc();return RUe(t,n),n-t}function Lm(e,t){return e.a.zc(t,e)==null}function Rm(e,t){return e.a.zc(t,(rd(),vG))==null}function yPe(e){return new Mp(null,OPe(e,e.length))}function bPe(e,t,n){return ypt(e,P(t,42),P(n,176))}function zm(e,t,n){return PS(e.a,t),uMe(e.b,t.g,n)}function xPe(e,t,n){gm(n,e.a.c.length),uy(e.a,n,t)}function I(e,t,n,r){TQe(t,n,e.length),SPe(e,t,n,r)}function SPe(e,t,n,r){var i;for(i=t;i0?r.Math.log(e/t):-100}function DPe(e,t){return dT(e,t)<0?-1:+(dT(e,t)>0)}function qm(e,t){Kwe(e,j(t,160)?t:P(t,2036).Rl())}function Jm(e,t){if(e==null)throw E(new Li(t))}function OPe(e,t){return gqe(t,e.length),new kMe(e,t)}function Ym(e,t){return t?XS(e,t):!1}function kPe(){return xi(),U(O(MTt,1),Z,549,0,[tG])}function Xm(e){return e.e==0?e:new Bm(-e.e,e.d,e.a)}function APe(e,t){return aE(e.c.c+e.c.b,t.c.c+t.c.b)}function Zm(e,t){iy(e.d,t,e.b.b,e.b),++e.a,e.c=null}function jPe(e,t){return e.c?jPe(e.c,t):M(e.b,t),e}function MPe(e,t,n){var r=ax(e,t);return Yv(e,t,n),r}function NPe(e,t,n){var r;for(r=0;r=e.g}function Sh(e,t,n){return cDe(n==null||mdt(e,n)),e[t]=n}function Ch(e,t){return sv(t,e.length+1),e.substr(t)}function wh(e,t){for(Gh(t);e.c=e?new _be:RJe(e-1)}function Bh(e){return!e.a&&e.c?e.c.b:e.a}function Vh(e){return j(e,616)?e:new KLe(e)}function Hh(e){e.c?Hh(e.c):(lE(e),e.d=!0)}function Uh(e){e.c?e.c.$e():(e.d=!0,bot(e))}function _Fe(e){e.b=!1,e.c=!1,e.d=!1,e.a=!1}function vFe(e){return e.c.i.c==e.d.i.c}function yFe(e,t){var n=e.Ih(t);n>=0?e.ki(n):Qtt(e,t)}function bFe(e,t){e.c<0||e.b.b0;)e=e<<1|e<0;return e}function BFe(e,t){var n=new Eh(e);return Mr(t.c,n),n}function VFe(e,t){e.u.Hc((rj(),G8))&&bnt(e,t),RWe(e,t)}function rg(e,t){return A(e)===A(t)||e!=null&&NT(e,t)}function ig(e,t){return Gp(e.a,t)?e.b[P(t,22).g]:null}function HFe(){return No(),U(O(Oq,1),Z,489,0,[Dq])}function UFe(){return Bo(),U(O(PLt,1),Z,490,0,[v3])}function WFe(){return Vo(),U(O(ILt,1),Z,558,0,[y3])}function GFe(){return Ho(),U(O(xRt,1),Z,539,0,[O3])}function ag(e){return!e.n&&(e.n=new F(Q5,e,1,7)),e.n}function og(e){return!e.c&&(e.c=new F(e7,e,9,9)),e.c}function sg(e){return!e.c&&(e.c=new cf(H5,e,5,8)),e.c}function KFe(e){return!e.b&&(e.b=new cf(H5,e,4,7)),e.b}function cg(e){return e.j.c.length=0,yg(e.c),gOe(e.a),e}function lg(e){return e.e==SW&&gfe(e,p2e(e.g,e.b)),e.e}function ug(e){return e.f==SW&&vfe(e,O6e(e.g,e.b)),e.f}function dg(e,t,n,r){return lXe(e,t,n,!1),LT(e,r),e}function qFe(e,t){this.b=e,Hm.call(this,e,t),CTe(this)}function JFe(e,t){this.b=e,LOe.call(this,e,t),wTe(this)}function fg(e){this.d=e,this.a=this.d.b,this.b=this.d.c}function pg(e,t){this.b=e,this.c=t,this.a=new _o(this.b)}function mg(e,t){return sv(t,e.length),e.charCodeAt(t)}function YFe(e,t){fE(e,D(nS(t,`x`)),D(nS(t,`y`)))}function XFe(e,t){fE(e,D(nS(t,`x`)),D(nS(t,`y`)))}function hg(e,t){return lE(e),new Mp(e,new UGe(t,e.a))}function gg(e,t){return lE(e),new Mp(e,new WUe(t,e.a))}function _g(e,t){return lE(e),new fDe(e,new HUe(t,e.a))}function vg(e,t){return lE(e),new pDe(e,new UUe(t,e.a))}function ZFe(e,t){return new VIe(P(ph(e),50),P(ph(t),50))}function QFe(e,t){return aE(e.d.c+e.d.b/2,t.d.c+t.d.b/2)}function $Fe(e,t,n){n.a?Kx(e,t.b-e.f/2):Gx(e,t.a-e.g/2)}function eIe(e,t){return aE(e.g.c+e.g.b/2,t.g.c+t.g.b/2)}function tIe(e,t){return Pbe(),aE((Gh(e),e),(Gh(t),t))}function nIe(e){return e!=null&&po(x7,e.toLowerCase())}function yg(e){var t;for(t=e.Kc();t.Ob();)t.Pb(),t.Qb()}function bg(e){var t=e.b;return!t&&(e.b=t=new lde(e)),t}function xg(e){return HJe(e)||null}function rIe(e,t){var n=e/t,r=C_(n);return n>r&&++r,r}function iIe(e,t,n){var r=P(e.d.Kb(n),159);r&&r.Nb(t)}function aIe(e,t,n){gpt(e.a,n),PXe(n),sit(e.b,n),Wpt(t,n)}function Sg(e,t,n,r){this.a=e,this.c=t,this.b=n,this.d=r}function Cg(e,t,n,r){this.c=e,this.b=t,this.a=n,this.d=r}function oIe(e,t,n,r){this.c=e,this.b=t,this.d=n,this.a=r}function wg(e,t,n,r){this.c=e,this.d=t,this.b=n,this.a=r}function sIe(e,t,n,r){this.a=e,this.d=t,this.c=n,this.b=r}function Tg(e,t,n,r){this.a=e,this.e=t,this.d=n,this.c=r}function cIe(e,t,n,r){this.a=e,this.c=t,this.d=n,this.b=r}function Eg(e,t,n){this.a=ryt,this.d=e,this.b=t,this.c=n}function Dg(e,t,n,r){so.call(this,e,t),this.a=n,this.b=r}function lIe(e,t){this.d=(Gh(e),e),this.a=16449,this.c=t}function uIe(e){this.a=new T,this.e=V(q9,X,53,e,0,2)}function dIe(e){e.Ug(`No crossing minimization`,1),e.Vg()}function fIe(){yi.call(this,`There is no more element.`)}function pIe(e,t,n,r){this.a=e,this.b=t,this.c=n,this.d=r}function mIe(e,t,n,r){this.a=e,this.b=t,this.c=n,this.d=r}function Og(e,t,n,r){this.e=e,this.a=t,this.c=n,this.d=r}function hIe(e,t,n,r){this.a=e,this.c=t,this.d=n,this.b=r}function gIe(e,t,n,r){du(),GUe.call(this,t,n,r),this.a=e}function _Ie(e,t,n,r){du(),GUe.call(this,t,n,r),this.a=e}function kg(e,t,n){var r=n_t(e);return t.ti(n,r)}function Ag(e){var t,n=(t=new kr,t);return Nx(n,e),n}function jg(e){var t,n=(t=new kr,t);return i9e(n,e),n}function vIe(e,t){return yC(t,xh(e.f,t)),null}function yIe(e){return!e.b&&(e.b=new F(U5,e,12,3)),e.b}function bIe(e){return bp(e==null||Nm(e)&&e.Tm!==ne),e}function Mg(e){return e.n&&(e.e!==eyt&&e.je(),e.j=null),e}function Ng(e){if(RE(e.d),e.d.d!=e.c)throw E(new Vr)}function Pg(e){return jd(e.b0&&d8e(this)}function xIe(e,t){this.a=e,dDe.call(this,e,P(e.d,15).fd(t))}function SIe(e,t){return aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function CIe(e,t){return aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function wIe(e){return uj(e)&&ki(Od(J(e,(mP(),A1))))}function TIe(e,t){return fj(e,P(K(t,(mP(),Y1)),17),t)}function EIe(e,t){return P(K(e,(Y(),PQ)),15).Fc(t),t}function Lg(e,t){return e.b=t.b,e.c=t.c,e.d=t.d,e.a=t.a,e}function DIe(e,t,n,r){this.b=e,this.c=r,vl.call(this,t,n)}function OIe(e,t,n){e.i=0,e.e=0,t!=n&&RZe(e,t,n)}function kIe(e,t,n){e.i=0,e.e=0,t!=n&&zZe(e,t,n)}function AIe(e,t,n){return Lo(),N1e(P(xh(e.e,t),529),n)}function Rg(e){var t;return t=e.f,t||(e.f=new io(e,e.c))}function jIe(e,t){return CT(e.j,t.s,t.c)+CT(t.e,e.s,e.c)}function MIe(e,t){e.e&&!e.e.a&&(Qhe(e.e,t),MIe(e.e,t))}function NIe(e,t){e.d&&!e.d.a&&(Qhe(e.d,t),NIe(e.d,t))}function PIe(e,t){return-aE(Lp(e)*Ip(e),Lp(t)*Ip(t))}function FIe(e){return P(e.ld(),149).Pg()+`:`+PE(e.md())}function IIe(){EA(this,new $ue),this.wb=(vh(),z7),Ra()}function LIe(e){this.b=new T,nw(this.b,this.b),this.a=e}function zg(e,t){new vo,this.a=new ai,this.b=e,this.c=t}function Bg(){Bg=C,nK=new ue,rK=new ue,iK=new de}function Vg(){Vg=C,QG=new ae,$G=new se,eK=new ce}function Hg(){Hg=C,wEt=new Ge,EEt=new yNe,TEt=new Ke}function Ug(){Ug=C,zq=new T,Rq=new Dr,Lq=new T}function Wg(e,t){if(e==null)throw E(new Li(t));return e}function Gg(e){return!e.a&&(e.a=new F($5,e,10,11)),e.a}function Kg(e){return!e.q&&(e.q=new F(M7,e,11,10)),e.q}function R(e){return!e.s&&(e.s=new F(w7,e,21,17)),e.s}function RIe(e){return ph(e),z4e(new pm(Vu(e.a.Kc(),new d)))}function zIe(e,t){return $w(e),$w(t),eve(P(e,22),P(t,22))}function qg(e,t,n){hx(e,t,new Cn(ZOe(n)))}function Jg(e,t,n,r,i,a){db.call(this,e,t,n,r,i,a?-2:-1)}function BIe(e,t,n,r){el.call(this,t,n),this.b=e,this.a=r}function VIe(e,t){F_e.call(this,new mm(e)),this.a=e,this.b=t}function Yg(e){this.b=e,this.c=e,e.e=null,e.c=null,this.a=1}function HIe(e){Lf();var t=P(e.g,10);t.n.a=e.d.c+t.d.b}function Xg(){Xg=C;var e,t=!L0e();e=new b,lG=t?new y:e}function Zg(e){return Vg(),j(e,59)?new sa(e):new qu(e)}function Qg(e){return j(e,16)?new jp(P(e,16)):Dje(e.Kc())}function UIe(e){return new DTe(e,e.e.Rd().gc()*e.c.Rd().gc())}function WIe(e){return new OTe(e,e.e.Rd().gc()*e.c.Rd().gc())}function $g(e){return e&&e.hashCode?e.hashCode():td(e)}function e_(e,t){return t==null?!!Kp(e.f,null):dNe(e.i,t)}function GIe(e,t){var n=Gwe(e.a,t);return n&&(t.d=null),n}function KIe(e,t,n){return e.f?e.f.ef(t,n):!1}function t_(e,t,n,r){Sh(e.c[t.g],n.g,r),Sh(e.c[n.g],t.g,r)}function n_(e,t,n,r){Sh(e.c[t.g],t.g,n),Sh(e.b[t.g],t.g,r)}function qIe(e,t,n){return D(N(n.a))<=e&&D(N(n.b))>=t}function JIe(e,t){this.g=e,this.d=U(O(UJ,1),jR,10,0,[t])}function YIe(e){this.c=e,this.b=new Ja(P(ph(new qe),50))}function XIe(e){this.c=e,this.b=new Ja(P(ph(new dee),50))}function ZIe(e){this.b=e,this.a=new Ja(P(ph(new At),50))}function QIe(){this.b=new Jr,this.d=new vo,this.e=new $r}function r_(){this.c=new Fa,this.d=new Fa,this.e=new Fa}function i_(){this.a=new ai,this.b=(vS(3,hF),new Hy(3))}function a_(e,t){this.e=e,this.a=WW,this.b=glt(t),this.c=t}function o_(e){this.c=e.c,this.d=e.d,this.b=e.b,this.a=e.a}function $Ie(e,t,n,r,i,a){this.a=e,xS.call(this,t,n,r,i,a)}function eLe(e,t,n,r,i,a){this.a=e,xS.call(this,t,n,r,i,a)}function s_(e,t,n,r,i,a,o){return new ey(e.e,t,n,r,i,a,o)}function tLe(e,t,n){return n>=0&&ff(e.substr(n,t.length),t)}function nLe(e,t){return j(t,149)&&ff(e.b,P(t,149).Pg())}function rLe(e,t){return e.a?t.Gh().Kc():P(t.Gh(),71).Ii()}function iLe(e,t){var n=e.b.Qc(t);return bHe(n,e.b.gc()),n}function c_(e,t){if(e==null)throw E(new Li(t));return e}function l_(e){return e.u||=(_y(e),new FDe(e,e)),e.u}function u_(e){this.a=(Vg(),j(e,59)?new sa(e):new qu(e))}function d_(e){return P(NC(e,16),29)||e.ii()}function f_(e,t){var n=Ha(e.Rm);return t==null?n:n+`: `+t}function p_(e,t,n){return Zy(t,n,e.length),e.substr(t,n-t)}function aLe(e,t){Qd.call(this),Px(this),this.a=e,this.c=t}function oLe(e){!e||f_(e,e.ie())}function sLe(e){Qi(),r.setTimeout(function(){throw e},0)}function cLe(){return fO(),U(O(DK,1),Z,436,0,[EK,TK])}function lLe(){return dx(),U(O(AK,1),Z,435,0,[OK,kK])}function uLe(){return fx(),U(O(Uq,1),Z,432,0,[Vq,Hq])}function dLe(){return dC(),U(O(kOt,1),Z,517,0,[aY,iY])}function fLe(){return Bv(),U(O(lQ,1),Z,429,0,[sQ,cQ])}function pLe(){return px(),U(O(hZ,1),Z,428,0,[pZ,mZ])}function mLe(){return Ky(),U(O(QX,1),Z,431,0,[XX,ZX])}function hLe(){return Qb(),U(O(YMt,1),Z,430,0,[e2,t2])}function gLe(){return Vv(),U(O(LNt,1),Z,531,0,[b2,y2])}function _Le(){return AS(),U(O(NFt,1),Z,501,0,[b4,x4])}function vLe(){return O_(),U(O(KNt,1),Z,523,0,[w2,C2])}function yLe(){return k_(),U(O(JNt,1),Z,522,0,[T2,E2])}function bLe(){return Wy(),U(O(uPt,1),Z,528,0,[A2,k2])}function xLe(){return wb(),U(O(OZ,1),Z,488,0,[DZ,EZ])}function SLe(){return my(),U(O(bLt,1),Z,491,0,[s3,yLt])}function CLe(){return JC(),U(O(OLt,1),Z,492,0,[ELt,DLt])}function wLe(){return iv(),U(O(DFt,1),Z,433,0,[v4,EFt])}function TLe(){return _b(),U(O(RFt,1),Z,434,0,[LFt,D4])}function ELe(){return D_(),U(O(_Pt,1),Z,465,0,[j2,M2])}function DLe(){return Gy(),U(O(RLt,1),Z,438,0,[x3,b3])}function OLe(){return cw(),U(O(wRt,1),Z,437,0,[k3,CRt])}function kLe(){return zf(),U(O(P5,1),Z,347,0,[HBt,UBt])}function m_(e,t,n,r){return n>=0?e.Uh(t,n,r):e.Ch(null,n,r)}function h_(e){return e.b.b==0?e.a.sf():Yf(e.b)}function ALe(e){if(e.p!=5)throw E(new Rr);return nm(e.f)}function jLe(e){if(e.p!=5)throw E(new Rr);return nm(e.k)}function MLe(e){return A(e.a)===A((uC(),r9))&&bmt(e),e.a}function NLe(e,t){e.b=t,e.c>0&&e.b>0&&(e.g=Pp(e.c,e.b,e.a))}function PLe(e,t){e.c=t,e.c>0&&e.b>0&&(e.g=Pp(e.c,e.b,e.a))}function FLe(e,t){Qde(this,new k(e.a,e.b)),$de(this,Zf(t))}function g_(){I_e.call(this,new go(xx(12))),vTe(!0),this.a=2}function __(e,t,n){xP(),Tr.call(this,e),this.b=t,this.a=n}function ILe(e,t,n){du(),xr.call(this,t),this.a=e,this.b=n}function LLe(e){var t=e.c.d.b;e.b=t,e.a=e.c.d,t.a=e.c.d.b=e}function RLe(e){return e.b==0?null:(jd(e.b!=0),Ox(e,e.a.a))}function v_(e,t){return t==null?nl(Kp(e.f,null)):as(e.i,t)}function zLe(e,t,n,r,i){return new IA(e,(Sb(),fK),t,n,r,i)}function y_(e,t){return dHe(t),eJe(e,V(q9,HF,28,t,15,1),t)}function b_(e,t){return Wg(e,`set1`),Wg(t,`set2`),new ibe(e,t)}function BLe(e,t){return aG[e.charCodeAt(0)]??e}function VLe(e,t){var n=t,r=new ve;return Aht(e,n,r),r.d}function x_(e,t,n,r){var i=new QDe;t.a[n.g]=i,zm(e.b,r,i)}function HLe(e,t){return $d(Cd(Bqe(e.f,t)),e.f.d)}function S_(e){var t;xJe(e.a),owe(e.a),t=new ar(e.a),KE(t)}function ULe(e,t){Uct(e,!0),Dx(e.e.Rf(),new Af(e,!0,t))}function WLe(e,t){return Ug(),e==I_(xA(t))||e==I_(SA(t))}function GLe(e,t){return zx(),P(K(t,(rN(),p4)),17).a==e}function C_(e){return Math.max(Math.min(e,AP),-2147483648)|0}function KLe(e){this.a=P(ph(e),277),this.b=(Vg(),new UTe(e))}function qLe(e,t,n){this.i=new T,this.b=e,this.g=t,this.a=n}function JLe(e,t,n){this.a=new T,this.e=e,this.f=t,this.c=n}function w_(e,t,n){this.c=new T,this.e=e,this.f=t,this.b=n}function YLe(e){Qd.call(this),Px(this),this.a=e,this.c=!0}function XLe(e){function t(){}return t.prototype=e||{},new t}function ZLe(e){if(e.Ae())return null;var t=e.n;return UW[t]}function T_(e){return e.Db>>16==3?P(e.Cb,27):null}function E_(e){return e.Db>>16==9?P(e.Cb,27):null}function QLe(e){return e.Db>>16==6?P(e.Cb,74):null}function D_(){D_=C,j2=new rSe(cL,0),M2=new rSe(lL,1)}function O_(){O_=C,w2=new Uxe(lL,0),C2=new Uxe(cL,1)}function k_(){k_=C,T2=new Wxe(hL,0),E2=new Wxe(`UP`,1)}function $Le(){$Le=C,NTt=nT((xi(),U(O(MTt,1),Z,549,0,[tG])))}function eRe(e){var t=new qa(xx(e.length));return wZe(t,e),t}function tRe(e,t){return e.b+=t.b,e.c+=t.c,e.d+=t.d,e.a+=t.a,e}function nRe(e,t){return IXe(e,t)?(oJe(e),!0):!1}function A_(e,t){if(t==null)throw E(new zr);return K0e(e,t)}function j_(e,t){var n=e.q.getHours();e.q.setDate(t),dN(e,n)}function rRe(e,t,n){var r=e.Ih(t);r>=0?e.bi(r,n):Pat(e,t,n)}function iRe(e,t){var n=e.Ih(t);return n>=0?e.Wh(n):cj(e,t)}function aRe(e,t){var n;for(ph(t),n=e.a;n;n=n.c)t.Yd(n.g,n.i)}function M_(e,t,n){e.b=new VS(kZe(e,t,n).c.length)}function N_(e,t,n){R_(),e&&Qh(p7,e,t),e&&Qh(f7,e,n)}function oRe(e,t){return If(),rd(),P(t.a,17).a0}function lRe(e){var t=e.d;return t=e.bj(e.f),tb(e,t),t.Ob()}function uRe(e,t){var n=new Ap(t);return L7e(n,e),new bf(n)}function dRe(e){if(e.p!=0)throw E(new Rr);return cl(e.f,0)}function fRe(e){if(e.p!=0)throw E(new Rr);return cl(e.k,0)}function pRe(e){return e.Db>>16==7?P(e.Cb,241):null}function F_(e){return e.Db>>16==6?P(e.Cb,241):null}function mRe(e){return e.Db>>16==7?P(e.Cb,167):null}function I_(e){return e.Db>>16==11?P(e.Cb,27):null}function L_(e){return e.Db>>16==17?P(e.Cb,29):null}function hRe(e){return e.Db>>16==3?P(e.Cb,155):null}function gRe(e){var t;return lE(e),t=new Jr,hg(e,new Wfe(t))}function _Re(e,t){var n=e.a=e.a||[];return n[t]||(n[t]=e.ve(t))}function vRe(e,t){var n=e.q.getHours();e.q.setMonth(t),dN(e,n)}function yRe(e,t){Fu(this),this.f=t,this.g=e,Mg(this),this.je()}function bRe(e,t){this.a=e,this.c=xu(this.a),this.b=new o_(t)}function xRe(e,t,n){this.a=t,this.c=e,this.b=(ph(n),new bf(n))}function SRe(e,t,n){this.a=t,this.c=e,this.b=(ph(n),new bf(n))}function CRe(e){this.a=e,this.b=V(MNt,X,2043,e.e.length,0,2)}function wRe(){this.a=new Rl,this.e=new Jr,this.g=0,this.i=0}function R_(){R_=C,p7=new Dr,f7=new Dr,USe(tEt,new Ise)}function TRe(){TRe=C,mNt=tm(new Zh,(vA(),SJ),(yP(),nX))}function ERe(){ERe=C,hNt=tm(new Zh,(vA(),SJ),(yP(),nX))}function DRe(){DRe=C,_Nt=tm(new Zh,(vA(),SJ),(yP(),nX))}function ORe(){ORe=C,zNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function z_(){z_=C,HNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function kRe(){kRe=C,GNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function B_(){B_=C,XNt=vp(new Zh,(vA(),SJ),(yP(),OY))}function V_(e,t,n,r,i,a){return new Hb(e.e,t,e.Lj(),n,r,i,a)}function H_(e,t,n){return t==null?XA(e.f,null,n):uE(e.i,t,n)}function U_(e,t){e.c&&Db(e.c.g,e),e.c=t,e.c&&M(e.c.g,e)}function W_(e,t){e.c&&Db(e.c.a,e),e.c=t,e.c&&M(e.c.a,e)}function G_(e,t){e.i&&Db(e.i.j,e),e.i=t,e.i&&M(e.i.j,e)}function K_(e,t){e.d&&Db(e.d.e,e),e.d=t,e.d&&M(e.d.e,e)}function q_(e,t){e.a&&Db(e.a.k,e),e.a=t,e.a&&M(e.a.k,e)}function J_(e,t){e.b&&Db(e.b.f,e),e.b=t,e.b&&M(e.b.f,e)}function ARe(e,t){rFe(e,e.b,e.c),P(e.b.b,68),t&&P(t.b,68).b}function jRe(e,t){return aE(P(e.c,65).c.e.b,P(t.c,65).c.e.b)}function MRe(e,t){return aE(P(e.c,65).c.e.a,P(t.c,65).c.e.a)}function NRe(e){return Qw(),rd(),P(e.a,86).d.e!=0}function Y_(e,t){j(e.Cb,184)&&(P(e.Cb,184).tb=null),GS(e,t)}function X_(e,t){j(e.Cb,90)&&$A(_y(P(e.Cb,90)),4),GS(e,t)}function PRe(e,t){hE(e,t),j(e.Cb,90)&&$A(_y(P(e.Cb,90)),2)}function FRe(e,t){t.c!=null&&Dh(e,new mh(t.c))}function IRe(e){var t,n=(Ra(),t=new kr,t);return Nx(n,e),n}function LRe(e){var t,n=(Ra(),t=new kr,t);return Nx(n,e),n}function RRe(e){for(var t;;)if(t=e.Pb(),!e.Ob())return t}function zRe(e,t,n){return M(e.a,(eg(),ik(t,n),new oo(t,n))),e}function Z_(e,t){return Qo(),ex(t)?new hp(t,e):new Qc(t,e)}function Q_(e){return AM(),dT(e,0)>=0?yD(e):Xm(yD(kb(e)))}function BRe(e){var t=P(cp(e.b),9);return new xf(e.a,t,e.c)}function VRe(e,t){var n=P(TT(Rg(e.a),t),16);return n?n.gc():0}function HRe(e,t,n){var r;I$e(t,n,e.c.length),r=n-t,wye(e.c,t,r)}function $_(e,t,n){I$e(t,n,e.gc()),this.c=e,this.a=t,this.b=n-t}function ev(e){this.c=new vo,this.b=e.b,this.d=e.c,this.a=e.a}function tv(e){this.a=r.Math.cos(e),this.b=r.Math.sin(e)}function nv(e,t,n,r){this.c=e,this.d=r,q_(this,t),J_(this,n)}function URe(e,t){P_e.call(this,new go(xx(e))),vS(t,Jvt),this.a=t}function WRe(e,t,n){return new IA(e,(Sb(),dK),null,!1,t,n)}function GRe(e,t,n){return new IA(e,(Sb(),pK),t,n,null,!1)}function KRe(){return Zw(),U(O(xK,1),Z,108,0,[vK,yK,bK])}function qRe(){return Xb(),U(O(IEt,1),Z,472,0,[sq,oq,aq])}function JRe(){return Cb(),U(O(NEt,1),Z,471,0,[rq,nq,iq])}function YRe(){return Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])}function XRe(){return Yb(),U(O(_J,1),Z,391,0,[hJ,mJ,gJ])}function ZRe(){return kS(),U(O(MX,1),Z,372,0,[jX,AX,kX])}function QRe(){return bS(),U(O(nZ,1),Z,322,0,[eZ,$X,tZ])}function $Re(){return lS(),U(O(oZ,1),Z,351,0,[rZ,aZ,iZ])}function eze(){return _w(),U(O(ckt,1),Z,460,0,[_Z,gZ,vZ])}function tze(){return qC(),U(O(rQ,1),Z,299,0,[tQ,nQ,eQ])}function nze(){return Zb(),U(O(gkt,1),Z,311,0,[aQ,oQ,iQ])}function rze(){return hT(),U(O(PMt,1),Z,390,0,[P0,NMt,F0])}function ize(){return uS(),U(O(ZMt,1),Z,463,0,[i2,n2,r2])}function aze(){return CC(),U(O(tNt,1),Z,387,0,[$Mt,a2,eNt])}function oze(){return Nw(),U(O(rNt,1),Z,349,0,[c2,o2,s2])}function sze(){return Xw(),U(O(oNt,1),Z,350,0,[l2,aNt,u2])}function cze(){return cS(),U(O(uNt,1),Z,352,0,[lNt,d2,cNt])}function lze(){return sw(),U(O(fNt,1),Z,388,0,[p2,m2,f2])}function uze(){return sS(),U(O(ANt,1),Z,464,0,[h2,g2,_2])}function rv(e){return Sw(U(O(K3,1),X,8,0,[e.i.n,e.n,e.a]))}function dze(){return Pw(),U(O(FPt,1),Z,392,0,[PPt,B2,z2])}function fze(){fze=C,kFt=tm(new Zh,(Ok(),F2),(LM(),CPt))}function iv(){iv=C,v4=new iSe(`DFS`,0),EFt=new iSe(`BFS`,1)}function pze(e,t,n){var r=new zie;r.b=t,r.a=n,++t.b,M(e.d,r)}function mze(e,t,n){var r=new Vl(n.d);$d(r,e),fE(t,r.a,r.b)}function hze(e,t){cTe(e,nm(uv(lm(t,24),jI)),nm(uv(t,jI)))}function av(e,t){if(e<0||e>t)throw E(new Mi(HI+e+UI+t))}function ov(e,t){if(e<0||e>=t)throw E(new Mi(HI+e+UI+t))}function sv(e,t){if(e<0||e>=t)throw E(new ra(HI+e+UI+t))}function cv(e,t){this.b=(Gh(e),e),this.a=(t&uI)==0?t|64|ZP:t}function gze(e){var t;return lE(e),t=(Bg(),Bg(),rK),Cx(e,t)}function _ze(e,t,n){var r=vN(e,t,!1);return r.b<=t&&r.a<=n}function vze(){return Tb(),U(O(wLt,1),Z,439,0,[c3,CLt,SLt])}function yze(){return TE(),U(O(LIt,1),Z,394,0,[IIt,Q4,FIt])}function bze(){return ED(),U(O(kIt,1),Z,445,0,[L4,R4,z4])}function xze(){return LO(),U(O(jIt,1),Z,456,0,[B4,H4,V4])}function Sze(){return Yw(),U(O(HFt,1),Z,393,0,[O4,BFt,VFt])}function Cze(){return SC(),U(O(DIt,1),Z,300,0,[I4,EIt,TIt])}function wze(){return _T(),U(O(yBt,1),Z,346,0,[_8,g8,v8])}function Tze(){return KT(),U(O(_3,1),Z,444,0,[m3,h3,g3])}function Eze(){return Lx(),U(O(rBt,1),Z,278,0,[o8,s8,c8])}function Dze(){return gT(),U(O(BBt,1),Z,280,0,[zBt,M5,N5])}function lv(e){return ph(e),j(e,16)?new bf(P(e,16)):Xf(e.Kc())}function Oze(e,t){return e&&e.equals?e.equals(t):A(e)===A(t)}function uv(e,t){return MC(BNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function dv(e,t){return MC(VNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function fv(e,t){return MC(HNe(Il(e)?zC(e):e,Il(t)?zC(t):t))}function kze(e,t){var n=(Gh(e),e).g;return sDe(!!n),Gh(t),n(t)}function Aze(e,t){var n,r=Im(e,t);return n=e.a.fd(r),new tbe(e,n)}function jze(e){return e.Db>>16==6?P(xj(e),241):null}function Mze(e){if(e.p!=2)throw E(new Rr);return nm(e.f)&OF}function Nze(e){if(e.p!=2)throw E(new Rr);return nm(e.k)&OF}function z(e){return jd(e.ar)}function Yze(e,t){var n=jb(t);return P(xh(e.c,n),17).a}function gv(e,t,n){var r=e.d[t.p];e.d[t.p]=e.d[n.p],e.d[n.p]=r}function Xze(e,t,n){var r;e.n&&t&&n&&(r=new Ese,M(e.e,r))}function _v(e,t){if(Lm(e.a,t),t.d)throw E(new yi(xyt));t.d=e}function Zze(e,t){this.a=new T,this.d=new T,this.f=e,this.c=t}function Qze(){this.c=new Hwe,this.a=new JUe,this.b=new Kge,Fbe()}function $ze(){lw(),this.b=new Dr,this.a=new Dr,this.c=new T}function eBe(e,t,n){this.d=e,this.j=t,this.e=n,this.o=-1,this.p=3}function tBe(e,t,n){this.d=e,this.k=t,this.f=n,this.o=-1,this.p=5}function nBe(e,t,n,r,i,a){Gqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function rBe(e,t,n,r,i,a){Kqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function iBe(e,t,n,r,i,a){vUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function aBe(e,t,n,r,i,a){Yqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function oBe(e,t,n,r,i,a){yUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function sBe(e,t,n,r,i,a){qqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function cBe(e,t,n,r,i,a){Jqe.call(this,e,t,n,r,i),a&&(this.o=-2)}function lBe(e,t,n,r,i,a){bUe.call(this,e,t,n,r,i),a&&(this.o=-2)}function uBe(e,t,n,r){xr.call(this,n),this.b=e,this.c=t,this.d=r}function dBe(e,t){this.f=e,this.a=(By(),u9),this.c=u9,this.b=t}function fBe(e,t){this.g=e,this.d=(By(),d9),this.a=d9,this.b=t}function pBe(e,t){!e.c&&(e.c=new DC(e,0)),ON(e.c,(UN(),w9),t)}function mBe(e,t){return Wit(e,t,j(t,102)&&(P(t,19).Bb&pI)!=0)}function hBe(e,t){return DPe(LC(e.q.getTime()),LC(t.q.getTime()))}function gBe(e){return yp(e.e.Rd().gc()*e.c.Rd().gc(),16,new ode(e))}function _Be(e){return!!e.u&&Jv(e.u.a).i!=0&&!(e.n&&QO(e.n))}function vBe(e){return!!e.a&&Ib(e.a.a).i!=0&&!(e.b&&$O(e.b))}function yBe(e,t){return t==0?!!e.o&&e.o.f!=0:mO(e,t)}function bBe(e,t,n){var r=P(e.Zb().xc(t),16);return!!r&&r.Hc(n)}function xBe(e,t,n){var r=P(e.Zb().xc(t),16);return!!r&&r.Mc(n)}function SBe(e,t){var n=1-t;return e.a[n]=FS(e.a[n],n),FS(e,t)}function CBe(e,t){var n,r=uv(e,_I);return n=cm(t,32),dv(n,r)}function wBe(e,t,n){Z3e(new xRe((ph(e),new bf(e)),t,n))}function vv(e,t,n){Q3e(new SRe((ph(e),new bf(e)),t,n))}function yv(e,t,n,r,i,a){return lXe(e,t,n,a),IT(e,r),zT(e,i),e}function TBe(e,t,n,r){return e.a+=``+p_(t==null?IP:PE(t),n,r),e}function bv(e,t){this.a=e,qn.call(this,e),av(t,e.gc()),this.b=t}function EBe(e){this.a=V(WW,FP,1,dZe(r.Math.max(8,e))<<1,5,1)}function xv(e){return P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199)}function Sv(e){return P(rO(e,V(VJ,AR,18,e.c.length,0,1)),483)}function DBe(e){return e.a?e.e.length==0?e.a.a:e.a.a+(``+e.e):e.c}function Cv(e){for(;e.d>0&&e.a[--e.d]==0;);e.a[e.d++]==0&&(e.e=0)}function OBe(e){return jd(e.b.b!=e.d.a),e.c=e.b=e.b.b,--e.a,e.c.c}function kBe(e,t,n){e.a=t,e.c=n,e.b.a.$b(),Fg(e.d),Wr(e.e.a.c,0)}function ABe(e,t){var n;e.e=new D_e,n=sM(t),hu(n,e.c),pct(e,n,0)}function wv(e,t,n,r){var i=new Koe;i.a=t,i.b=n,i.c=r,up(e.a,i)}function B(e,t,n,r){var i=new Koe;i.a=t,i.b=n,i.c=r,up(e.b,i)}function jBe(e,t,n){if(e<0||tn)throw E(new Mi(yet(e,t,n)))}function Tv(e,t){if(e<0||e>=t)throw E(new Mi(jtt(e,t)));return e}function MBe(e){if(!(`stack`in e))try{throw e}catch{}return e}function Ev(e){return Lo(),j(e.g,10)?P(e.g,10):null}function NBe(e){return!bg(e).dc()&&(gwe(e,new h),!0)}function Dv(e){var t;return Il(e)?(t=e,t==-0?0:t):lKe(e)}function PBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function FBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function IBe(e,t){return j(t,44)?lk(e.a,P(t,44)):!1}function LBe(e){var t;return Hh(e),t=new fe,Qa(e.a,new Vfe(t)),t}function RBe(){var e,t=(n=(e=new kr,e),n),n;return M(fHt,t),t}function Ov(e){var t;return Hh(e),t=new pe,Qa(e.a,new Hfe(t)),t}function zBe(e,t){return e.a<=e.b&&(t.Dd(e.a++),!0)}function BBe(e){rC.call(this,e,(Sb(),uK),null,!1,null,!1)}function VBe(){VBe=C,hDt=nT((No(),U(O(Oq,1),Z,489,0,[Dq])))}function HBe(){HBe=C,wNt=LFe(G(1),G(4)),CNt=LFe(G(1),G(2))}function UBe(e,t){return new Vf(t,wd(xu(t.e),e,e),(rd(),!0))}function kv(e){return new Hy((vS(e,_F),bx(yE(yE(5,e),e/10|0))))}function WBe(e){return yp(e.e.Rd().gc()*e.c.Rd().gc(),273,new ade(e))}function GBe(e){return P(rO(e,V(EOt,Sbt,12,e.c.length,0,1)),2042)}function KBe(e){return z_(),!gy(e)&&!(!gy(e)&&e.c.i.c==e.d.i.c)}function qBe(e,t){return Rx(),P(K(t,(rN(),u4)),17).a>=e.gc()}function Av(e,t){L_t(t,e),Yje(e.d),Yje(P(K(e,(mP(),L1)),214))}function jv(e,t){R_t(t,e),Xje(e.d),Xje(P(K(e,(mP(),L1)),214))}function JBe(e,t,n){e.d&&Db(e.d.e,e),e.d=t,e.d&&Jp(e.d.e,n,e)}function YBe(e,t,n){return n.f.c.length>0?bPe(e.a,t,n):bPe(e.b,t,n)}function XBe(e,t,n){var r=b2e();try{return qDe(e,t,n)}finally{CHe(r)}}function Mv(e,t){var n=A_(e,t),r=null;return n&&(r=n.pe()),r}function Nv(e,t){var n=A_(e,t),r=null;return n&&(r=n.se()),r}function Pv(e,t){var n=ax(e,t),r=null;return n&&(r=n.se()),r}function Fv(e,t){var n=A_(e,t),r=null;return n&&(r=ket(n)),r}function ZBe(e,t,n){var r=RD(n);return PM(e.g,r,t),PM(e.i,t,n),t}function QBe(e,t,n){this.d=new nme(this),this.e=e,this.i=t,this.f=n}function $Be(e,t,n,r){this.e=null,this.c=e,this.d=t,this.a=n,this.b=r}function eVe(e,t,n,r){jwe(this),this.c=e,this.e=t,this.f=n,this.b=r}function tVe(e,t,n,r){this.d=e,this.n=t,this.g=n,this.o=r,this.p=-1}function nVe(e,t,n,r){return j(n,59)?new lEe(e,t,n,r):new qNe(e,t,n,r)}function Iv(e){return j(e,16)?P(e,16).dc():!e.Kc().Ob()}function rVe(e){if(e.e.g!=e.b)throw E(new Vr);return!!e.c&&e.d>0}function Lv(e){return jd(e.b!=e.d.c),e.c=e.b,e.b=e.b.a,++e.a,e.c.c}function iVe(e,t){Gh(t),Sh(e.a,e.c,t),e.c=e.c+1&e.a.length-1,L3e(e)}function Rv(e,t){Gh(t),e.b=e.b-1&e.a.length-1,Sh(e.a,e.b,t),L3e(e)}function aVe(e){var t=e.Gh();this.a=j(t,71)?P(t,71).Ii():t.Kc()}function oVe(e){return new cv(wqe(P(e.a.md(),16).gc(),e.a.ld()),16)}function sVe(){sVe=C,FLt=nT((Bo(),U(O(PLt,1),Z,490,0,[v3])))}function cVe(){cVe=C,LLt=nT((Vo(),U(O(ILt,1),Z,558,0,[y3])))}function lVe(){lVe=C,SRt=nT((Ho(),U(O(xRt,1),Z,539,0,[O3])))}function uVe(){return YD(),U(O(zJ,1),Z,389,0,[RJ,IJ,FJ,LJ])}function dVe(){return Sb(),U(O(mK,1),Z,304,0,[uK,dK,fK,pK])}function fVe(){return TO(),U(O(lDt,1),Z,332,0,[gq,hq,_q,vq])}function pVe(){return wO(),U(O(pDt,1),Z,406,0,[wq,Cq,Tq,Eq])}function mVe(){return KC(),U(O(sDt,1),Z,417,0,[mq,dq,fq,pq])}function hVe(){return ow(),U(O(mOt,1),Z,416,0,[kJ,MJ,AJ,jJ])}function gVe(){return aw(),U(O(KOt,1),Z,421,0,[bX,xX,SX,CX])}function _Ve(){return iw(),U(O(FOt,1),Z,371,0,[gX,mX,hX,pX])}function vVe(){return IO(),U(O(B0,1),Z,203,0,[R0,z0,L0,I0])}function yVe(){return ID(),U(O(qMt,1),Z,284,0,[Z0,KMt,Q0,$0])}function bVe(e){var t;return e.j==(nP(),m5)&&(t=krt(e),$u(t,X8))}function xVe(e,t){var n=t.a;U_(n,t.c.d),K_(n,t.d.d),vC(n.a,e.n)}function SVe(e,t){var n=P(ix(e.b,t),67);return!n&&(n=new vo),n}function zv(e){return Lo(),j(e.g,154)?P(e.g,154):null}function CVe(e){e.a=null,e.e=null,Wr(e.b.c,0),Wr(e.f.c,0),e.c=null}function Bv(){Bv=C,sQ=new Js(sL,0),cQ=new Js(`TOP_LEFT`,1)}function Vv(){Vv=C,b2=new zxe(`UPPER`,0),y2=new zxe(`LOWER`,1)}function wVe(e,t){return Ou(new k(t.e.a+t.f.a/2,t.e.b+t.f.b/2),e)}function TVe(e,t){return P(Ju(_m(P(Dy(e.k,t),15).Oc(),HX)),113)}function EVe(e,t){return P(Ju(vm(P(Dy(e.k,t),15).Oc(),HX)),113)}function DVe(){return Ok(),U(O(yPt,1),Z,405,0,[N2,P2,F2,I2])}function OVe(){return Jw(),U(O(wFt,1),Z,353,0,[_4,h4,g4,m4])}function kVe(){return uk(),U(O(CIt,1),Z,354,0,[F4,xIt,SIt,bIt])}function AVe(){return TD(),U(O(S5,1),Z,386,0,[b5,x5,y5,v5])}function jVe(){return kk(),U(O(xBt,1),Z,291,0,[S8,y8,b8,x8])}function MVe(){return wE(),U(O(p8,1),Z,223,0,[f8,u8,l8,d8])}function NVe(){return ZE(),U(O(JBt,1),Z,320,0,[F5,GBt,qBt,KBt])}function PVe(){return Mw(),U(O(eVt,1),Z,415,0,[I5,QBt,ZBt,$Bt])}function FVe(e){return R_(),km(p7,e)?P(xh(p7,e),341).Qg():null}function Hv(e,t,n){return t<0?cj(e,n):P(n,69).wk().Bk(e,e.hi(),t)}function IVe(e,t,n){var r=RD(n);return PM(e.j,r,t),Qh(e.k,t,n),t}function LVe(e,t,n){var r=RD(n);return PM(e.d,r,t),Qh(e.e,t,n),t}function RVe(e){var t=(Ia(),n=new nn,n),n;return e&&Hj(t,e),t}function zVe(e){var t=e.aj(e.i);return e.i>0&&tN(e.g,0,t,0,e.i),t}function BVe(e,t){var n;for(n=e.j.c.length;n>24}function WVe(e){if(e.p!=1)throw E(new Rr);return nm(e.k)<<24>>24}function GVe(e){if(e.p!=7)throw E(new Rr);return nm(e.k)<<16>>16}function KVe(e){if(e.p!=7)throw E(new Rr);return nm(e.f)<<16>>16}function Uv(e,t){return t.e==0||e.e==0?JG:(pM(),Xj(e,t))}function qVe(e,t){return A(t)===A(e)?`(this Map)`:t==null?IP:PE(t)}function JVe(e,t,n){return dm(N(nl(Kp(e.f,t))),N(nl(Kp(e.f,n))))}function YVe(e,t,n){var r=P(xh(e.g,n),60);M(e.a.c,new Kc(t,r))}function XVe(e,t,n){e.i=0,e.e=0,t!=n&&(zZe(e,t,n),RZe(e,t,n))}function ZVe(e,t,n,r,i){M(t,vtt(i,mat(i,n,r))),p9e(e,i,t)}function QVe(e,t,n,r,i){this.i=e,this.a=t,this.e=n,this.j=r,this.f=i}function $Ve(e,t){r_.call(this),this.a=e,this.b=t,M(this.a.b,this)}function eHe(e){this.b=new Dr,this.c=new Dr,this.d=new Dr,this.a=e}function tHe(e,t){var n=new na;return e.Gd(n),n.a+=`..`,t.Hd(n),n.a}function nHe(e,t){for(var n=t;n;)Sd(e,n.i,n.j),n=I_(n);return e}function rHe(e,t,n){var r=RD(n);return Qh(e.b,r,t),Qh(e.c,t,n),t}function Wv(e){for(var t=0;e.Ob();)e.Pb(),t=yE(t,1);return bx(t)}function Gv(e,t){Qo();var n=P(e,69).vk();return L9e(n,t),n.xl(t)}function iHe(e,t,n){if(n){var r=n.oe();e.a[t]=r(n)}else delete e.a[t]}function aHe(e,t){var n=e.q.getHours();e.q.setFullYear(t+VF),dN(e,n)}function oHe(e,t){return P(t==null?nl(Kp(e.f,null)):as(e.i,t),288)}function sHe(e,t){return e==(DA(),JJ)&&t==JJ?4:e==JJ||t==JJ?8:32}function Kv(e,t,n){return sN(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function cHe(e,t,n){return pN(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function lHe(e,t,n){return tat(e,t,n,j(t,102)&&(P(t,19).Bb&pI)!=0)}function uHe(e){e.b!=e.c&&(e.a=V(WW,FP,1,8,5,1),e.b=0,e.c=0)}function qv(e){return jd(e.a=0&&e.a[n]===t[n];n--);return n<0}function oy(e){var t;return e?new Ap(e):(t=new Rl,HS(t,e),t)}function SHe(e,t){var n,r=!1;do n=mZe(e,t),r|=n;while(n);return r}function CHe(e){e&&OKe((Si(),cG)),--oG,e&&sG!=-1&&(gCe(sG),sG=-1)}function sy(e){s7e(),cTe(this,nm(uv(lm(e,24),jI)),nm(uv(e,jI)))}function wHe(){wHe=C,DEt=nT((fO(),U(O(DK,1),Z,436,0,[EK,TK])))}function THe(){THe=C,OEt=nT((dx(),U(O(AK,1),Z,435,0,[OK,kK])))}function EHe(){EHe=C,NDt=nT((fx(),U(O(Uq,1),Z,432,0,[Vq,Hq])))}function DHe(){DHe=C,AOt=nT((dC(),U(O(kOt,1),Z,517,0,[aY,iY])))}function OHe(){OHe=C,vkt=nT((Bv(),U(O(lQ,1),Z,429,0,[sQ,cQ])))}function kHe(){kHe=C,skt=nT((px(),U(O(hZ,1),Z,428,0,[pZ,mZ])))}function AHe(){AHe=C,dkt=nT((wb(),U(O(OZ,1),Z,488,0,[DZ,EZ])))}function jHe(){jHe=C,XMt=nT((Qb(),U(O(YMt,1),Z,430,0,[e2,t2])))}function MHe(){MHe=C,RNt=nT((Vv(),U(O(LNt,1),Z,531,0,[b2,y2])))}function NHe(){NHe=C,rkt=nT((Ky(),U(O(QX,1),Z,431,0,[XX,ZX])))}function PHe(){PHe=C,OFt=nT((iv(),U(O(DFt,1),Z,433,0,[v4,EFt])))}function FHe(){FHe=C,PFt=nT((AS(),U(O(NFt,1),Z,501,0,[b4,x4])))}function IHe(){IHe=C,qNt=nT((O_(),U(O(KNt,1),Z,523,0,[w2,C2])))}function LHe(){LHe=C,YNt=nT((k_(),U(O(JNt,1),Z,522,0,[T2,E2])))}function RHe(){RHe=C,dPt=nT((Wy(),U(O(uPt,1),Z,528,0,[A2,k2])))}function zHe(){zHe=C,vPt=nT((D_(),U(O(_Pt,1),Z,465,0,[j2,M2])))}function BHe(){BHe=C,zFt=nT((_b(),U(O(RFt,1),Z,434,0,[LFt,D4])))}function VHe(){VHe=C,xLt=nT((my(),U(O(bLt,1),Z,491,0,[s3,yLt])))}function HHe(){HHe=C,kLt=nT((JC(),U(O(OLt,1),Z,492,0,[ELt,DLt])))}function UHe(){UHe=C,zLt=nT((Gy(),U(O(RLt,1),Z,438,0,[x3,b3])))}function WHe(){WHe=C,TRt=nT((cw(),U(O(wRt,1),Z,437,0,[k3,CRt])))}function GHe(){GHe=C,WBt=nT((zf(),U(O(P5,1),Z,347,0,[HBt,UBt])))}function KHe(){return GT(),U(O(a8,1),Z,88,0,[r8,n8,t8,e8,i8])}function qHe(){return nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])}function JHe(e,t,n){return P(t==null?XA(e.f,null,n):uE(e.i,t,n),288)}function YHe(e){return(e.k==(DA(),JJ)||e.k==GJ)&&yd(e,(Y(),bQ))}function cy(e){return e.c&&e.d?Gze(e.c)+`->`+Gze(e.d):`e_`+td(e)}function ly(e,t){var n,r;for(Gh(t),r=e.Kc();r.Ob();)n=r.Pb(),t.Cd(n)}function XHe(e,t){var n=new bi;qg(n,`x`,t.a),qg(n,`y`,t.b),Dh(e,n)}function ZHe(e,t){var n=new bi;qg(n,`x`,t.a),qg(n,`y`,t.b),Dh(e,n)}function QHe(e,t){for(var n=t;n;)Sd(e,-n.i,-n.j),n=I_(n);return e}function $He(e,t){for(var n=t,r=0;n>0;)r+=e.a[n],n-=n&-n;return r}function uy(e,t,n){var r=(ov(t,e.c.length),e.c[t]);return e.c[t]=n,r}function eUe(e,t,n){e.a.c.length=0,Tmt(e,t,n),e.a.c.length==0||Mut(e,t)}function dy(e){e.i=0,is(e.b,null),is(e.c,null),e.a=null,e.e=null,++e.g}function fy(){fy=C,_K=!0,mEt=!1,hEt=!1,_Et=!1,gEt=!1}function py(e){fy(),!_K&&(this.c=e,this.e=!0,this.a=new T)}function tUe(e,t){this.c=0,this.b=t,oCe.call(this,e,17493),this.a=this.c}function nUe(e){Cvt(),lge(this),this.a=new vo,tQe(this,e),up(this.a,e)}function rUe(){au(this),this.b=new k(cI,cI),this.a=new k(lI,lI)}function my(){my=C,s3=new sSe(YR,0),yLt=new sSe(`TARGET_WIDTH`,1)}function hy(e,t){return(lE(e),Xa(new Mp(e,new UGe(t,e.a)))).Bd(SK)}function iUe(){return vA(),U(O(CJ,1),Z,367,0,[vJ,yJ,bJ,xJ,SJ])}function aUe(){return tA(),U(O(JOt,1),Z,375,0,[TX,DX,OX,EX,wX])}function oUe(){return FD(),U(O(fZ,1),Z,348,0,[cZ,sZ,uZ,dZ,lZ])}function sUe(){return CO(),U(O(RMt,1),Z,323,0,[LMt,H0,U0,V0,W0])}function cUe(){return XE(),U(O(y$,1),Z,171,0,[v$,m$,h$,g$,_$])}function lUe(){return iA(),U(O(FFt,1),Z,368,0,[T4,S4,E4,C4,w4])}function uUe(){return Wj(),U(O(jLt,1),Z,373,0,[u3,l3,f3,d3,p3])}function dUe(){return MA(),U(O(ULt,1),Z,324,0,[BLt,S3,HLt,C3,VLt])}function fUe(){return uO(),U(O(L3,1),Z,170,0,[F3,P3,M3,I3,N3])}function pUe(){return pO(),U(O(I8,1),Z,256,0,[P8,F8,wBt,N8,TBt])}function mUe(e){return Qi(),function(){return XBe(e,this,arguments)}}function gy(e){return!e.c||!e.d?!1:!!e.c.i&&e.c.i==e.d.i}function hUe(e,t){return j(t,143)?ff(e.c,P(t,143).c):!1}function _y(e){return e.t||(e.t=new Bhe(e),WT(new K_e(e),0,e.t)),e.t}function gUe(e){this.b=e,Lu.call(this,e),this.a=P(NC(this.b.a,4),129)}function _Ue(e){this.b=e,ld.call(this,e),this.a=P(NC(this.b.a,4),129)}function vy(e,t,n,r,i){KUe.call(this,t,r,i),this.c=e,this.b=n}function vUe(e,t,n,r,i){eBe.call(this,t,r,i),this.c=e,this.a=n}function yUe(e,t,n,r,i){tBe.call(this,t,r,i),this.c=e,this.a=n}function bUe(e,t,n,r,i){KUe.call(this,t,r,i),this.c=e,this.a=n}function yy(e,t){return P(ix(e.d,t),23)||P(ix(e.e,t),23)}function xUe(e,t){var n=t.ld(),r=e.Fe(n);return!!r&&rg(r.e,t.md())}function SUe(e,t){var n=t.ld();return new oo(n,e.e.pc(n,P(t.md(),16)))}function CUe(e,t){return e.a.get(t)??V(WW,FP,1,0,5,1)}function wUe(e){var t=e.length;return ff(fI.substr(fI.length-t,t),e)}function by(e){if(Cj(e))return e.c=e.a,e.a.Pb();throw E(new Hr)}function TUe(e,t){return t==0||e.e==0?e:t>0?Cst(e,t):F0e(e,-t)}function xy(e,t){return t==0||e.e==0?e:t>0?F0e(e,t):Cst(e,-t)}function EUe(e){txe.call(this,e==null?IP:PE(e),j(e,82)?P(e,82):null)}function DUe(e){var t;return e.c||(t=e.r,j(t,90)&&(e.c=P(t,29))),e.c}function Sy(e){var t=new i_;return VC(t,e),W(t,(mP(),j1),null),t}function OUe(e){var t=e.c.i,n=e.d.i;return t.k==(DA(),GJ)&&n.k==GJ}function Cy(e){return vu(e&QF,e>>22&QF,e<0?$F:0)}function kUe(e){var t,n,r,i;for(n=e,r=0,i=n.length;r=0?e.Lh(r,n,!0):mj(e,t,n)}function jUe(e,t,n){return aE(Ou(cO(e),xu(t.b)),Ou(cO(e),xu(n.b)))}function MUe(e,t,n){return aE(Ou(cO(e),xu(t.e)),Ou(cO(e),xu(n.e)))}function NUe(e,t){return r.Math.min(ab(t.a,e.d.d.c),ab(t.b,e.d.d.c))}function Ty(e,t){e._i(e.i+1),Au(e,e.i,e.Zi(e.i,t)),e.Mi(e.i++,t),e.Ni()}function Ey(e){var t,n;++e.j,t=e.g,n=e.i,e.g=null,e.i=0,e.Oi(n,t),e.Ni()}function PUe(e,t,n){var r=new Rwe(e.a);mC(r,e.a.a),XA(r.f,t,n),e.a.a=r}function FUe(e,t,n,r){var i;for(i=0;it)throw E(new Mi(ptt(e,t,`index`)));return e}function Ay(e,t){var n=(ov(t,e.c.length),e.c[t]);return wye(e.c,t,1),n}function zUe(e,t){var n=(Gh(e),e),r=(Gh(t),t);return n==r?0:nt.p?-1:0}function tWe(e){var t;return e.a||(t=e.r,j(t,156)&&(e.a=P(t,156))),e.a}function nWe(e,t,n){var r;return++e.e,--e.f,r=P(e.d[t].gd(n),136),r.md()}function rWe(e){var t=e.ld();return qf(P(e.md(),16).Nc(),new cde(t))}function iWe(e,t){return km(e.a,t)?(My(e.a,t),!0):!1}function Iy(e,t,n){return Tv(t,e.e.Rd().gc()),Tv(n,e.c.Rd().gc()),e.a[t][n]}function Ly(e,t,n){this.a=e,this.b=t,this.c=n,M(e.t,this),M(t.i,this)}function Ry(e,t,n,r){this.f=e,this.e=t,this.d=n,this.b=r,this.c=r?r.d:null}function zy(){this.b=new vo,this.a=new vo,this.b=new vo,this.a=new vo}function By(){By=C;var e,t;u9=(Ra(),t=new Ur,t),d9=(e=new oi,e)}function aWe(e){var t;return lE(e),t=new Mje(e,e.a.e,e.a.d|4),new fDe(e,t)}function oWe(e){var t;for(Hh(e),t=0;e.a.Bd(new Be);)t=yE(t,1);return t}function Vy(e,t){return Gh(t),e.c=0,`Initial capacity must not be negative`)}function Uy(){Uy=C,G3=new yr(`org.eclipse.elk.labels.labelManager`)}function sWe(){sWe=C,fX=new Wd(`separateLayerConnections`,(iw(),gX))}function Wy(){Wy=C,A2=new nSe(`REGULAR`,0),k2=new nSe(`CRITICAL`,1)}function Gy(){Gy=C,x3=new lSe(`FIXED`,0),b3=new lSe(`CENTER_NODE`,1)}function Ky(){Ky=C,XX=new Lxe(`QUADRATIC`,0),ZX=new Lxe(`SCANLINE`,1)}function cWe(){cWe=C,ikt=nT((bS(),U(O(nZ,1),Z,322,0,[eZ,$X,tZ])))}function lWe(){lWe=C,akt=nT((lS(),U(O(oZ,1),Z,351,0,[rZ,aZ,iZ])))}function uWe(){uWe=C,ekt=nT((kS(),U(O(MX,1),Z,372,0,[jX,AX,kX])))}function dWe(){dWe=C,lkt=nT((_w(),U(O(ckt,1),Z,460,0,[_Z,gZ,vZ])))}function fWe(){fWe=C,hkt=nT((qC(),U(O(rQ,1),Z,299,0,[tQ,nQ,eQ])))}function pWe(){pWe=C,_kt=nT((Zb(),U(O(gkt,1),Z,311,0,[aQ,oQ,iQ])))}function mWe(){mWe=C,FMt=nT((hT(),U(O(PMt,1),Z,390,0,[P0,NMt,F0])))}function hWe(){hWe=C,nNt=nT((CC(),U(O(tNt,1),Z,387,0,[$Mt,a2,eNt])))}function gWe(){gWe=C,iNt=nT((Nw(),U(O(rNt,1),Z,349,0,[c2,o2,s2])))}function _We(){_We=C,QMt=nT((uS(),U(O(ZMt,1),Z,463,0,[i2,n2,r2])))}function vWe(){vWe=C,sNt=nT((Xw(),U(O(oNt,1),Z,350,0,[l2,aNt,u2])))}function yWe(){yWe=C,dNt=nT((cS(),U(O(uNt,1),Z,352,0,[lNt,d2,cNt])))}function bWe(){bWe=C,pNt=nT((sw(),U(O(fNt,1),Z,388,0,[p2,m2,f2])))}function xWe(){xWe=C,IPt=nT((Pw(),U(O(FPt,1),Z,392,0,[PPt,B2,z2])))}function SWe(){SWe=C,UFt=nT((Yw(),U(O(HFt,1),Z,393,0,[O4,BFt,VFt])))}function CWe(){CWe=C,OIt=nT((SC(),U(O(DIt,1),Z,300,0,[I4,EIt,TIt])))}function wWe(){wWe=C,AIt=nT((ED(),U(O(kIt,1),Z,445,0,[L4,R4,z4])))}function TWe(){TWe=C,MIt=nT((LO(),U(O(jIt,1),Z,456,0,[B4,H4,V4])))}function EWe(){EWe=C,RIt=nT((TE(),U(O(LIt,1),Z,394,0,[IIt,Q4,FIt])))}function DWe(){DWe=C,TLt=nT((Tb(),U(O(wLt,1),Z,439,0,[c3,CLt,SLt])))}function OWe(){OWe=C,jNt=nT((sS(),U(O(ANt,1),Z,464,0,[h2,g2,_2])))}function kWe(){kWe=C,PEt=nT((Cb(),U(O(NEt,1),Z,471,0,[rq,nq,iq])))}function AWe(){AWe=C,MEt=nT((Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])))}function jWe(){jWe=C,LEt=nT((Xb(),U(O(IEt,1),Z,472,0,[sq,oq,aq])))}function MWe(){MWe=C,vEt=nT((Zw(),U(O(xK,1),Z,108,0,[vK,yK,bK])))}function NWe(){NWe=C,aOt=nT((Yb(),U(O(_J,1),Z,391,0,[hJ,mJ,gJ])))}function PWe(){PWe=C,bBt=nT((_T(),U(O(yBt,1),Z,346,0,[_8,g8,v8])))}function FWe(){FWe=C,NLt=nT((KT(),U(O(_3,1),Z,444,0,[m3,h3,g3])))}function IWe(){IWe=C,iBt=nT((Lx(),U(O(rBt,1),Z,278,0,[o8,s8,c8])))}function LWe(){LWe=C,VBt=nT((gT(),U(O(BBt,1),Z,280,0,[zBt,M5,N5])))}function qy(e,t){return!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),uD(e.o,t)}function RWe(e,t){var n;e.C&&(n=P(ig(e.b,t),127).n,n.d=e.C.d,n.a=e.C.a)}function zWe(e){var t,n,r,i=e.d;t=e.a,n=e.b,r=e.c,e.d=n,e.a=r,e.b=i,e.c=t}function BWe(e){return!e.g&&(e.g=new on),!e.g.b&&(e.g.b=new Ihe(e)),e.g.b}function Jy(e){return!e.g&&(e.g=new on),!e.g.c&&(e.g.c=new zhe(e)),e.g.c}function VWe(e){return!e.g&&(e.g=new on),!e.g.d&&(e.g.d=new Lhe(e)),e.g.d}function HWe(e){return!e.g&&(e.g=new on),!e.g.a&&(e.g.a=new Rhe(e)),e.g.a}function UWe(e,t,n,r){return n&&(r=n.Rh(t,eD(n.Dh(),e.c.uk()),null,r)),r}function WWe(e,t,n,r){return n&&(r=n.Th(t,eD(n.Dh(),e.c.uk()),null,r)),r}function Yy(e,t,n,r){var i=V(q9,HF,28,t+1,15,1);return Gdt(i,e,t,n,r),i}function V(e,t,n,r,i,a){var o=b3e(i,r);return i!=10&&U(O(e,a),t,n,i,o),o}function GWe(e,t,n){var r,i=new WC(t,e);for(r=0;rn||t=0?e.Lh(n,!0,!0):mj(e,t,!0)}function gGe(e,t,n){var r=kZe(e,t,n);return e.b=new VS(r.c.length),Xst(e,r)}function _Ge(e){if(e.b<=0)throw E(new Hr);return--e.b,e.a-=e.c.c,G(e.a)}function vGe(e){var t;if(!e.a)throw E(new fIe);return t=e.a,e.a=I_(e.a),t}function yGe(e){for(;!e.a;)if(!DOe(e.c,new Ufe(e)))return!1;return!0}function hb(e){var t;return ph(e),j(e,204)?(t=P(e,204),t):new gde(e)}function bGe(e){gb(),P(e.of((vP(),z6)),181).Fc((rj(),K8)),e.qf(R6,null)}function gb(){gb=C,jRt=new Hoe,NRt=new Uoe,MRt=oQe((vP(),R6),jRt,D6,NRt)}function _b(){_b=C,LFt=new oSe(`LEAF_NUMBER`,0),D4=new oSe(`NODE_SIZE`,1)}function vb(e){e.a=V(q9,HF,28,e.b+1,15,1),e.c=V(q9,HF,28,e.b,15,1),e.d=0}function xGe(e,t){e.a.Ne(t.d,e.b)>0&&(M(e.c,new Pje(t.c,t.d,e.d)),e.b=t.d)}function SGe(e,t){if(e.g==null||t>=e.i)throw E(new wl(t,e.i));return e.g[t]}function CGe(e,t,n){if(Aw(e,n),n!=null&&!e.fk(n))throw E(new Ir);return n}function yb(e,t){return lx(t)!=10&&U($w(t),t.Sm,t.__elementTypeId$,lx(t),e),e}function bb(e,t,n,r){var i;r=(Bg(),r||nK),i=e.slice(t,n),mtt(i,e,t,n,-t,r)}function xb(e,t,n,r,i){return t<0?mj(e,n,r):P(n,69).wk().yk(e,e.hi(),t,r,i)}function wGe(e,t){return aE(D(N(K(e,(Y(),$Q)))),D(N(K(t,$Q))))}function TGe(){TGe=C,dEt=nT((Sb(),U(O(mK,1),Z,304,0,[uK,dK,fK,pK])))}function Sb(){Sb=C,uK=new ls(`All`,0),dK=new WCe,fK=new Owe,pK=new UCe}function Cb(){Cb=C,rq=new hs(cL,0),nq=new hs(sL,1),iq=new hs(lL,2)}function EGe(){EGe=C,_N(),VHt=cI,BHt=lI,UHt=new Rn(cI),HHt=new Rn(lI)}function DGe(){DGe=C,cDt=nT((KC(),U(O(sDt,1),Z,417,0,[mq,dq,fq,pq])))}function OGe(){OGe=C,mDt=nT((wO(),U(O(pDt,1),Z,406,0,[wq,Cq,Tq,Eq])))}function kGe(){kGe=C,uDt=nT((TO(),U(O(lDt,1),Z,332,0,[gq,hq,_q,vq])))}function AGe(){AGe=C,xOt=nT((YD(),U(O(zJ,1),Z,389,0,[RJ,IJ,FJ,LJ])))}function jGe(){jGe=C,hOt=nT((ow(),U(O(mOt,1),Z,416,0,[kJ,MJ,AJ,jJ])))}function MGe(){MGe=C,qOt=nT((aw(),U(O(KOt,1),Z,421,0,[bX,xX,SX,CX])))}function NGe(){NGe=C,IOt=nT((iw(),U(O(FOt,1),Z,371,0,[gX,mX,hX,pX])))}function PGe(){PGe=C,IMt=nT((IO(),U(O(B0,1),Z,203,0,[R0,z0,L0,I0])))}function FGe(){FGe=C,JMt=nT((ID(),U(O(qMt,1),Z,284,0,[Z0,KMt,Q0,$0])))}function wb(){wb=C,DZ=new Hs(wR,0),EZ=new Hs(`IMPROVE_STRAIGHTNESS`,1)}function IGe(e,t){var n,r=t/e.c.Rd().gc()|0;return n=t%e.c.Rd().gc(),Iy(e,r,n)}function LGe(e){var t;if(e.nl())for(t=e.i-1;t>=0;--t)H(e,t);return zVe(e)}function RGe(e){var t,n;if(!e.b)return null;for(n=e.b;t=n.a[0];)n=t;return n}function zGe(e){var t,n;if(!e.b)return null;for(n=e.b;t=n.a[1];)n=t;return n}function BGe(e){return j(e,180)?``+P(e,180).a:e==null?null:PE(e)}function VGe(e){return j(e,180)?``+P(e,180).a:e==null?null:PE(e)}function HGe(e,t){if(t.a)throw E(new yi(xyt));Lm(e.a,t),t.a=e,!e.j&&(e.j=t)}function UGe(e,t){vl.call(this,t.zd(),t.yd()&-16449),Gh(e),this.a=e,this.c=t}function WGe(e,t){return new Vf(t,Sd(xu(t.e),t.f.a+e,t.f.b+e),(rd(),!1))}function GGe(e,t){return Rf(),M(e,new Kc(t,G(t.e.c.length+t.g.c.length)))}function KGe(e,t){return Rf(),M(e,new Kc(t,G(t.e.c.length+t.g.c.length)))}function qGe(){qGe=C,wIt=nT((uk(),U(O(CIt,1),Z,354,0,[F4,xIt,SIt,bIt])))}function JGe(){JGe=C,TFt=nT((Jw(),U(O(wFt,1),Z,353,0,[_4,h4,g4,m4])))}function YGe(){YGe=C,bPt=nT((Ok(),U(O(yPt,1),Z,405,0,[N2,P2,F2,I2])))}function XGe(){XGe=C,aBt=nT((wE(),U(O(p8,1),Z,223,0,[f8,u8,l8,d8])))}function ZGe(){ZGe=C,SBt=nT((kk(),U(O(xBt,1),Z,291,0,[S8,y8,b8,x8])))}function QGe(){QGe=C,IBt=nT((TD(),U(O(S5,1),Z,386,0,[b5,x5,y5,v5])))}function $Ge(){$Ge=C,YBt=nT((ZE(),U(O(JBt,1),Z,320,0,[F5,GBt,qBt,KBt])))}function eKe(){eKe=C,tVt=nT((Mw(),U(O(eVt,1),Z,415,0,[I5,QBt,ZBt,$Bt])))}function Tb(){Tb=C,c3=new Cc(_xt,0),CLt=new Cc(vV,1),SLt=new Cc(wR,2)}function Eb(e,t,n,r,i){return Gh(e),Gh(t),Gh(n),Gh(r),Gh(i),new Vm(e,t,r)}function tKe(e,t){var n=P(My(e.e,t),400);return n?(pMe(n),n.e):null}function Db(e,t){var n=Ab(e,t,0);return n!=-1&&(Ay(e,n),!0)}function nKe(e,t,n){var r;return Hh(e),r=new Re,r.a=t,e.a.Nb(new uxe(r,n)),r.a}function rKe(e){var t;return Hh(e),t=V(Z9,hI,28,0,15,1),Qa(e.a,new Bfe(t)),t}function Ob(e){var t;if(!DS(e))throw E(new Hr);return e.e=1,t=e.d,e.d=null,t}function kb(e){var t;return Il(e)&&(t=0-e,!isNaN(t))?t:MC(mw(e))}function Ab(e,t,n){for(;n=0?jO(e,n,!0,!0):mj(e,t,!0)}function qb(e){var t=rS(NC(e,32));return t??=(WD(e),rS(NC(e,32))),t}function Jb(e){var t;return e.Oh()||(t=bh(e.Dh())-e.ji(),e.$h().Mk(t)),e.zh()}function fKe(e,t){bq=new Mt,fDt=t,yq=e,P(yq.b,68),ZWe(yq,bq,null),Jpt(yq)}function Yb(){Yb=C,hJ=new Cs(`XY`,0),mJ=new Cs(`X`,1),gJ=new Cs(`Y`,2)}function Xb(){Xb=C,sq=new gs(`TOP`,0),oq=new gs(sL,1),aq=new gs(Lyt,2)}function Zb(){Zb=C,aQ=new qs(wR,0),oQ=new qs(`TOP`,1),iQ=new qs(Lyt,2)}function Qb(){Qb=C,e2=new nc(`INPUT_ORDER`,0),t2=new nc(`PORT_DEGREE`,1)}function $b(){$b=C,hG=vu(QF,QF,524287),BTt=vu(0,0,eI),gG=Cy(1),Cy(2),_G=Cy(0)}function ex(e){var t;return e.d!=e.r&&(t=Ik(e),e.e=!!t&&t.lk()==xwt,e.d=t),e.e}function tx(e,t,n){var r=e.g[t];return Au(e,t,e.Zi(t,n)),e.Ri(t,n,r),e.Ni(),r}function nx(e,t){var n=e.dd(t);return n>=0&&(e.gd(n),!0)}function rx(e,t){var n;for(ph(e),ph(t),n=!1;t.Ob();)n|=e.Fc(t.Pb());return n}function ix(e,t){var n=P(xh(e.e,t),400);return n?(Ywe(e,n),n.e):null}function pKe(e){var t=e/60|0,n=e%60;return n==0?``+t:``+t+`:`+(``+n)}function ax(e,t){var n=e.a[t],r=(vw(),pG)[typeof n];return r?r(n):XQe(typeof n)}function ox(e,t){var n,r;return lE(e),r=new WUe(t,e.a),n=new zOe(r),new Mp(e,n)}function sx(e){var t=e.b.c.length==0?null:Ep(e.b,0);return t!=null&&LS(e,0),t}function mKe(e,t){var n,r,i=t.c.i;n=P(xh(e.f,i),60),r=n.d.c-n.e.c,eC(t.a,r,0)}function cx(e,t){var n;for(++e.d,++e.c[t],n=t+1;n=0;)++t[0]}function _Ke(e,t){Gx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function vKe(e,t){Kx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function yKe(e,t){Wx(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function bKe(e,t){Ux(e,t==null||vf((Gh(t),t))||isNaN((Gh(t),t))?0:(Gh(t),t))}function xKe(e,t,n){return Ou(new k(n.e.a+n.f.a/2,n.e.b+n.f.b/2),e)==(Gh(t),t)}function SKe(e,t){return j(t,102)&&(P(t,19).Bb&pI)!=0?new Dl(t,e):new WC(t,e)}function CKe(e,t){return j(t,102)&&(P(t,19).Bb&pI)!=0?new Dl(t,e):new WC(t,e)}function lx(e){return e.__elementTypeCategory$==null?10:e.__elementTypeCategory$}function wKe(e,t){return t==(Sf(),Sf(),oEt)?e.toLocaleLowerCase():e.toLowerCase()}function TKe(e){if(!e.e)throw E(new Hr);return e.c=e.a=e.e,e.e=e.e.e,--e.d,e.a.f}function ux(e){if(!e.c)throw E(new Hr);return e.e=e.a=e.c,e.c=e.c.c,++e.d,e.a.f}function EKe(e){var t;for(++e.a,t=e.c.a.length;e.ae.a[r]&&(r=n);return r}function MKe(e){var t=P(K(e,(Y(),fQ)),313);return t?t.a==e:!1}function NKe(e){var t=P(K(e,(Y(),fQ)),313);return t?t.i==e:!1}function PKe(){PKe=C,lOt=nT((vA(),U(O(CJ,1),Z,367,0,[vJ,yJ,bJ,xJ,SJ])))}function FKe(){FKe=C,YOt=nT((tA(),U(O(JOt,1),Z,375,0,[TX,DX,OX,EX,wX])))}function IKe(){IKe=C,okt=nT((FD(),U(O(fZ,1),Z,348,0,[cZ,sZ,uZ,dZ,lZ])))}function LKe(){LKe=C,zMt=nT((CO(),U(O(RMt,1),Z,323,0,[LMt,H0,U0,V0,W0])))}function RKe(){RKe=C,ykt=nT((XE(),U(O(y$,1),Z,171,0,[v$,m$,h$,g$,_$])))}function zKe(){zKe=C,IFt=nT((iA(),U(O(FFt,1),Z,368,0,[T4,S4,E4,C4,w4])))}function BKe(){BKe=C,MLt=nT((Wj(),U(O(jLt,1),Z,373,0,[u3,l3,f3,d3,p3])))}function VKe(){VKe=C,WLt=nT((MA(),U(O(ULt,1),Z,324,0,[BLt,S3,HLt,C3,VLt])))}function HKe(){HKe=C,nBt=nT((GT(),U(O(a8,1),Z,88,0,[r8,n8,t8,e8,i8])))}function UKe(){UKe=C,FRt=nT((uO(),U(O(L3,1),Z,170,0,[F3,P3,M3,I3,N3])))}function WKe(){WKe=C,EBt=nT((pO(),U(O(I8,1),Z,256,0,[P8,F8,wBt,N8,TBt])))}function GKe(){GKe=C,ABt=nT((nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])))}function dx(){dx=C,OK=new pxe(`BY_SIZE`,0),kK=new pxe(`BY_SIZE_AND_SHAPE`,1)}function fx(){fx=C,Vq=new Ss(`EADES`,0),Hq=new Ss(`FRUCHTERMAN_REINGOLD`,1)}function px(){px=C,pZ=new zs(`READING_DIRECTION`,0),mZ=new zs(`ROTATION`,1)}function mx(){mx=C,vOt=new mee,yOt=new _ee,gOt=new vee,_Ot=new gee,bOt=new yee}function KKe(e){this.b=new T,this.a=new T,this.c=new T,this.d=new T,this.e=e}function qKe(e){this.g=e,this.f=new T,this.a=r.Math.min(this.g.c.c,this.g.d.c)}function JKe(e,t,n){Qd.call(this),Px(this),this.a=e,this.c=n,this.b=t.d,this.f=t.e}function YKe(e,t,n){var r,i;for(i=new w(n);i.a=0&&t0?t-1:t;return Qve($ve(Uqe(Qje(new di,n),e.n),e.j),e.k)}function vx(e){var t,n=(t=new si,t);tb((!e.q&&(e.q=new F(M7,e,11,10)),e.q),n)}function yx(e){return(e.i&2?`interface `:e.i&1?``:`class `)+(Ad(e),e.o)}function bx(e){return dT(e,AP)>0?AP:dT(e,xF)<0?xF:nm(e)}function xx(e){return e<3?(vS(e,Qvt),e+1):e=-.01&&e.a<=fL&&(e.a=0),e.b>=-.01&&e.b<=fL&&(e.b=0),e}function Tx(e){fM();var t,n=zV;for(t=0;tn&&(n=e[t]);return n}function lqe(e,t){var n=Qj(e.Dh(),t);if(!n)throw E(new Fi(HH+t+WH));return n}function Ex(e,t){for(var n=e;I_(n);)if(n=I_(n),n==t)return!0;return!1}function uqe(e,t){var n,r=t.a.ld(),i;for(n=P(t.a.md(),16).gc(),i=0;ie||e>t)throw E(new ia(`fromIndex: 0, toIndex: `+e+MI+t))}function kx(e){if(e<0)throw E(new Fi(`Illegal Capacity: `+e));this.g=this.aj(e)}function Ax(e,t){return uu(),fS(bF),r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)}function jx(e,t){var n,r,i,a;for(r=e.d,i=0,a=r.length;i0&&(e.a/=t,e.b/=t),e}function Mx(e){var t;return e.w?e.w:(t=jze(e),t&&!t.Vh()&&(e.w=t),t)}function Nx(e,t){var n,r=e.a;n=V$e(e,t,null),r!=t&&!e.e&&(n=JN(e,t,n)),n&&n.oj()}function xqe(e,t,n){var r=t,i;do i=D(e.p[r.p])+n,e.p[r.p]=i,r=e.a[r.p];while(r!=t)}function Sqe(e,t,n){var r=function(){return e.apply(r,arguments)};return t.apply(r,n),r}function Cqe(e){var t;return e==null?null:(t=P(e,195),E7e(t,t.length))}function H(e,t){if(e.g==null||t>=e.i)throw E(new wl(t,e.i));return e.Wi(t,e.g[t])}function wqe(e,t){Vg();var n,r=new T;for(n=0;n=14&&t<=16))),e}function iS(e,t){var n;return Gh(t),n=e[`:`+t],$f(!!n,`Enum constant undefined: `+t),n}function aS(e,t,n,r,i,a){var o=fh(e,t);return Wqe(n,o),o.i=i?8:0,o.f=r,o.e=i,o.g=a,o}function Gqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=1,this.c=e,this.a=n}function Kqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=2,this.c=e,this.a=n}function qqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=6,this.c=e,this.a=n}function Jqe(e,t,n,r,i){this.d=t,this.k=r,this.f=i,this.o=-1,this.p=7,this.c=e,this.a=n}function Yqe(e,t,n,r,i){this.d=t,this.j=r,this.e=i,this.o=-1,this.p=4,this.c=e,this.a=n}function Xqe(e,t){var n,r,i,a;for(r=t,i=0,a=r.length;i=0))throw E(new Fi(`tolerance (`+e+`) must be >= 0`));return e}function aJe(e,t){var n;return j(t,44)?e.c.Mc(t):(n=uD(e,t),BD(e,t),n)}function pS(e,t,n){return aT(e,t),GS(e,n),Zx(e,0),Qx(e,1),RT(e,!0),FT(e,!0),e}function mS(e,t){var n=e.gc();if(t<0||t>n)throw E(new lf(t,n));return new LOe(e,t)}function hS(e,t){e.b=r.Math.max(e.b,t.d),e.e+=t.r+(e.a.c.length==0?0:e.c),M(e.a,t)}function oJe(e){Md(e.c>=0),Q0e(e.d,e.c)<0&&(e.a=e.a-1&e.d.a.length-1,e.b=e.d.c),e.c=-1}function gS(e){var t,n;for(n=e.c.Cc().Kc();n.Ob();)t=P(n.Pb(),16),t.$b();e.c.$b(),e.d=0}function sJe(e){var t,n,r,i;for(n=e.a,r=0,i=n.length;r=0}function kJe(e,t){e.r>0&&e.c0&&e.g!=0&&kJe(e.i,t/e.r*e.i.d))}function AJe(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.c))}function SS(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,4,n,e.c))}function CS(e,t){var n=e.k;e.k=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,2,n,e.k))}function wS(e,t){var n=e.D;e.D=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,2,n,e.D))}function TS(e,t){var n=e.f;e.f=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,8,n,e.f))}function ES(e,t){var n=e.i;e.i=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,7,n,e.i))}function jJe(e,t){var n=e.a;e.a=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,8,n,e.a))}function MJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,n,e.b))}function NJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,n,e.b))}function PJe(e,t){var n=e.c;e.c=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.c))}function FJe(e,t){var n=e.d;e.d=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,1,n,e.d))}function IJe(e,t,n){var r;e.b=t,e.a=n,r=(e.a&512)==512?new y_e:new Qle,e.c=Ust(r,e.b,e.a)}function LJe(e,t){return aM(e.e,t)?(Qo(),ex(t)?new hp(t,e):new Qc(t,e)):new ZSe(t,e)}function RJe(e){var t,n;return 0>e?new _be:(t=e+1,n=new tUe(t,e),new pDe(null,n))}function zJe(e,t){Vg();var n=new go(1);return rl(e)?H_(n,e,t):XA(n.f,e,t),new Kn(n)}function BJe(e,t){var n=e.c,r=t.e[e.p];return r>0?P(Ep(n.a,r-1),10):null}function VJe(e,t){var n=e.o+e.p,r=t.o+t.p;return nt?(t<<=1,t>0?t:mF):t}function DS(e){switch(yTe(e.e!=3),e.e){case 2:return!1;case 0:return!0}return VUe(e)}function WJe(e,t){var n;return j(t,8)?(n=P(t,8),e.a==n.a&&e.b==n.b):!1}function GJe(e,t){var n=new Mt;P(t.b,68),P(t.b,68),P(t.b,68),Dx(t.a,new Uf(e,n,t))}function KJe(e,t){var n,r;for(r=t.vc().Kc();r.Ob();)n=P(r.Pb(),44),Hk(e,n.ld(),n.md())}function qJe(e,t){var n=e.d;e.d=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,11,n,e.d))}function OS(e,t){var n=e.j;e.j=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,13,n,e.j))}function JJe(e,t){var n=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,21,n,e.b))}function YJe(e,t){(fy(),_K?null:t.c).length==0&&vDe(t,new xe),H_(e.a,_K?null:t.c,t)}function XJe(e,t){t.Ug(`Hierarchical port constraint processing`,1),G2e(e),pvt(e),t.Vg()}function kS(){kS=C,jX=new Ps(`START`,0),AX=new Ps(`MIDDLE`,1),kX=new Ps(`END`,2)}function AS(){AS=C,b4=new aSe(`P1_NODE_PLACEMENT`,0),x4=new aSe(`P2_EDGE_ROUTING`,1)}function jS(){jS=C,iJ=new yr(sbt),aJ=new yr(cbt),rJ=new yr(lbt),nJ=new yr(ubt)}function MS(e){var t;return Df(e.f.g,e.d),jd(e.b),e.c=e.a,t=P(e.a.Pb(),44),e.b=FXe(e),t}function NS(e){var t;return e.b==null?(Xo(),Xo(),a9):(t=e.ul()?e.tl():e.sl(),t)}function ZJe(e,t){var n=t==null?-1:Ab(e.b,t,0);return n<0?!1:(LS(e,n),!0)}function PS(e,t){var n;return Gh(t),n=t.g,!e.b[n]&&(Sh(e.b,n,t),++e.c,!0)}function FS(e,t){var n=1-t,r=e.a[n];return e.a[n]=r.a[t],r.a[t]=e,e.b=!0,r.b=!1,r}function QJe(e,t){var n,r;for(r=t.Kc();r.Ob();)n=P(r.Pb(),272),e.b=!0,Lm(e.e,n),n.b=e}function $Je(e,t){var n=P(K(e,(mP(),n0)),8),r=P(K(t,n0),8);return aE(n.b,r.b)}function IS(e,t,n){var r,i,a=t>>5;return i=t&31,r=uv(um(e.n[n][a],nm(cm(i,1))),3),r}function eYe(e,t,n){var r,i,a=e.a.length-1;for(i=e.b,r=0;r0):(!e.c&&(e.c=Q_(LC(e.f))),e.c).e}function fYe(e,t){t?e.B??(e.B=e.D,e.D=null):e.B!=null&&(e.D=e.B,e.B=null)}function pYe(e,t){return ow(),e==kJ&&t==MJ||e==MJ&&t==kJ||e==jJ&&t==AJ||e==AJ&&t==jJ}function mYe(e,t){return ow(),e==kJ&&t==AJ||e==kJ&&t==jJ||e==MJ&&t==jJ||e==MJ&&t==AJ}function hYe(e,t){return uu(),fS(fL),r.Math.abs(0-t)<=fL||t==0?0:e/t}function gYe(e,t){return D(N(Ju(MT(gg(new Mp(null,new cv(e.c.b,16)),new Zpe(e)),t))))}function $S(e,t){return D(N(Ju(MT(gg(new Mp(null,new cv(e.c.b,16)),new Xpe(e)),t))))}function _Ye(){return uM(),U(O($Z,1),Z,259,0,[WZ,KZ,qZ,JZ,YZ,XZ,QZ,UZ,GZ,ZZ])}function vYe(){return FM(),U(O(WMt,1),Z,243,0,[Y0,q0,J0,VMt,HMt,BMt,UMt,X0,G0,K0])}function yYe(e,t){var n;t.Ug(`General Compactor`,1),n=$1e(P(J(e,(PA(),A4)),393)),n.Cg(e)}function bYe(e,t){var n=P(J(e,(PA(),j4)),17),r=P(J(t,j4),17);return _u(n.a,r.a)}function eC(e,t,n){var r,i;for(i=dO(e,0);i.b!=i.d.c;)r=P(Lv(i),8),r.a+=t,r.b+=n;return e}function tC(e,t,n){var r;for(r=e.b[n&e.f];r;r=r.b)if(n==r.a&&zh(t,r.g))return r;return null}function nC(e,t,n){var r;for(r=e.c[n&e.f];r;r=r.d)if(n==r.f&&zh(t,r.i))return r;return null}function xYe(e,t,n){var r=0,i,a;for(i=0;i>>31;r!=0&&(e[n]=r)}function rC(e,t,n,r,i,a){var o;this.c=e,o=new T,t3e(e,o,t,e.b,n,r,i,a),this.a=new bv(o,0)}function SYe(){this.c=new Ya(0),this.b=new Ya(PV),this.d=new Ya(txt),this.a=new Ya(RL)}function iC(e,t,n,r,i,a,o){so.call(this,e,t),this.d=n,this.e=r,this.c=i,this.b=a,this.a=Oy(o)}function aC(e,t,n,r,i,a,o,s,c,l,u,d,f){return ftt(e,t,n,r,i,a,o,s,c,l,u,d,f),mE(e,!1),e}function CYe(e){return e.b.c.i.k==(DA(),GJ)?P(K(e.b.c.i,(Y(),WQ)),12):e.b.c}function wYe(e){return e.b.d.i.k==(DA(),GJ)?P(K(e.b.d.i,(Y(),WQ)),12):e.b.d}function TYe(e){var t=Ov(e);return ol(t.a,0)?(So(),So(),sEt):(So(),new _Ee(t.b))}function oC(e){var t=LBe(e);return ol(t.a,0)?(xo(),xo(),sK):(xo(),new gd(t.b))}function sC(e){var t=LBe(e);return ol(t.a,0)?(xo(),xo(),sK):(xo(),new gd(t.c))}function EYe(e){switch(e.g){case 2:return nP(),g5;case 4:return nP(),X8;default:return e}}function DYe(e){switch(e.g){case 1:return nP(),m5;case 3:return nP(),Z8;default:return e}}function OYe(e){switch(e.g){case 0:return new Doe;case 1:return new Ooe;default:return null}}function cC(){cC=C,dX=new Wd(`edgelabelcenterednessanalysis.includelabel`,(rd(),vG))}function lC(){lC=C,kNt=HD(pCe(vp(vp(new Zh,(vA(),bJ),(yP(),KY)),xJ,IY),SJ),GY)}function kYe(){kYe=C,NNt=HD(pCe(vp(vp(new Zh,(vA(),bJ),(yP(),KY)),xJ,IY),SJ),GY)}function uC(){uC=C,n9=new p_e,r9=U(O(w7,1),qU,179,0,[]),eHt=U(O(M7,1),Cwt,62,0,[])}function dC(){dC=C,aY=new xxe(`TO_INTERNAL_LTR`,0),iY=new xxe(`TO_INPUT_DIRECTION`,1)}function fC(){fC=C,tY=new Tee,$J=new Eee,eY=new Dee,QJ=new Oee,nY=new kee,rY=new Aee}function AYe(e,t){t.Ug(Mbt,1),KE(kbe(new ar((Po(),new Tg(e,!1,!1,new Wt))))),t.Vg()}function jYe(e,t,n){n.Ug(`DFS Treeifying phase`,1),k0e(e,t),Yot(e,t),e.a=null,e.b=null,n.Vg()}function pC(e,t){return rd(),rl(e)?zUe(e,kd(t)):al(e)?dm(e,N(t)):il(e)?UNe(e,Od(t)):e.Fd(t)}function mC(e,t){var n,r;for(Gh(t),r=t.vc().Kc();r.Ob();)n=P(r.Pb(),44),e.zc(n.ld(),n.md())}function MYe(e,t,n){var r;for(r=n.Kc();r.Ob();)if(!Kv(e,t,r.Pb()))return!1;return!0}function NYe(e,t,n,r,i){var a;return n&&(a=eD(t.Dh(),e.c),i=n.Rh(t,-1-(a==-1?r:a),null,i)),i}function PYe(e,t,n,r,i){var a;return n&&(a=eD(t.Dh(),e.c),i=n.Th(t,-1-(a==-1?r:a),null,i)),i}function FYe(e){var t;if(e.b==-2){if(e.e==0)t=-1;else for(t=0;e.a[t]==0;t++);e.b=t}return e.b}function IYe(e){if(Gh(e),e.length==0)throw E(new aa(`Zero length BigInteger`));uut(this,e)}function hC(e){this.i=e.gc(),this.i>0&&(this.g=this.aj(this.i+(this.i/8|0)+1),e.Qc(this.g))}function LYe(e,t,n){this.g=e,this.d=t,this.e=n,this.a=new T,Utt(this),Vg(),hu(this.a,null)}function gC(e,t){t.q=e,e.d=r.Math.max(e.d,t.r),e.b+=t.d+(e.a.c.length==0?0:e.c),M(e.a,t)}function _C(e,t){var n,r,i=e.c,a;return n=e.c+e.b,a=e.d,r=e.d+e.a,t.a>i&&t.aa&&t.bi?n=i:sv(t,n+1),e.a=p_(e.a,0,t)+(``+r)+Ch(e.a,n)}function QYe(e,t){e.a=yE(e.a,1),e.c=r.Math.min(e.c,t),e.b=r.Math.max(e.b,t),e.d=yE(e.d,t)}function $Ye(e,t){return t1||e.Ob())return++e.a,e.g=0,t=e.i,e.Ob(),t;throw E(new Hr)}function fXe(e){switch(e.a.g){case 1:return new Yxe;case 3:return new P3e;default:return new Nue}}function pXe(e,t){switch(t){case 1:return!!e.n&&e.n.i!=0;case 2:return e.k!=null}return yBe(e,t)}function LC(e){return iI>22),i=e.h+t.h+(r>>22);return vu(n&QF,r&QF,i&$F)}function NXe(e,t){var n=e.l-t.l,r=e.m-t.m+(n>>22),i=e.h-t.h+(r>>22);return vu(n&QF,r&QF,i&$F)}function PXe(e){var t,n;for(Wgt(e),n=new w(e.d);n.ar)throw E(new lf(t,r));return e.Si()&&(n=uRe(e,n)),e.Ei(t,n)}function pw(e,t,n,r,i){var a,o;for(o=n;o<=i;o++)for(a=t;a<=r;a++)sk(e,a,o)||EM(e,a,o,!0,!1)}function uZe(e){fM();var t,n=V(K3,X,8,2,0,1),r=0;for(t=0;t<2;t++)r+=.5,n[t]=Y4e(r,e);return n}function mw(e){var t=~e.l+1&QF,n=~e.m+ +(t==0)&QF;return vu(t,n,~e.h+ +(t==0&&n==0)&$F)}function dZe(e){var t;if(e<0)return xF;if(e==0)return 0;for(t=mF;(t&e)==0;t>>=1);return t}function hw(e,t,n){return e>=128?!1:cl(e<64?uv(cm(1,e),n):uv(cm(1,e-64),t),0)}function gw(e,t,n){return n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n)),e}function W(e,t,n){return n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n)),e}function fZe(e){var t,n=new Py;return VC(n,e),W(n,(jS(),iJ),e),t=new Dr,gft(e,n,t),$ht(e,n,t),n}function pZe(e){var t=e.t-e.k[e.o.p]*e.d+e.j[e.o.p]>e.f,n=e.u+e.e[e.o.p]*e.d>e.f*e.s*e.d;return t||n}function mZe(e,t){var n=!1,r=e.a[t].length,i,a;for(a=0;a=0,`Negative initial capacity`),$f(t>=0,`Non-positive load factor`),Pm(this)}function CZe(e,t,n,r,i){var a,o=e.length;if(a=n.length,t<0||r<0||i<0||t+i>o||r+i>a)throw E(new bge)}function wZe(e,t){Vg();var n,r,i,a,o=!1;for(r=t,i=0,a=r.length;i1||t>=0&&e.b<3)}function ww(e){var t=~e.l+1&QF,n=~e.m+ +(t==0)&QF,r=~e.h+ +(t==0&&n==0)&$F;e.l=t,e.m=n,e.h=r}function IZe(e){Vg();var t,n,r=1;for(n=e.Kc();n.Ob();)t=n.Pb(),r=31*r+(t==null?0:US(t)),r|=0;return r}function LZe(e,t,n,r,i){var a=$rt(e,t);return n&&ww(a),i&&(e=s3e(e,t),mG=r?mw(e):vu(e.l,e.m,e.h)),a}function RZe(e,t,n){e.g=WA(e,t,(nP(),X8),e.b),e.d=WA(e,n,X8,e.b),e.g.c!=0&&e.d.c!=0&&f9e(e)}function zZe(e,t,n){e.g=WA(e,t,(nP(),g5),e.j),e.d=WA(e,n,g5,e.j),e.g.c!=0&&e.d.c!=0&&f9e(e)}function BZe(e,t){switch(t){case 7:return!!e.e&&e.e.i!=0;case 8:return!!e.d&&e.d.i!=0}return JE(e,t)}function VZe(e,t){switch(t.g){case 0:j(e.b,641)||(e.b=new XYe);break;case 1:j(e.b,642)||(e.b=new aMe)}}function HZe(e){switch(e.g){case 0:return new Poe;default:throw E(new Fi(fH+(e.f==null?``+e.g:e.f)))}}function UZe(e){switch(e.g){case 0:return new Moe;default:throw E(new Fi(fH+(e.f==null?``+e.g:e.f)))}}function WZe(e,t,n){return!Xa(hg(new Mp(null,new cv(e.c,16)),new rr(new bSe(t,n)))).Bd((wo(),SK))}function GZe(e,t){return Ou(cO(P(K(t,(rN(),c4)),88)),new k(e.c.e.a-e.b.e.a,e.c.e.b-e.b.e.b))<=0}function KZe(e,t){for(;e.g==null&&!e.c?lRe(e):e.g==null||e.i!=0&&P(e.g[e.i-1],51).Ob();)KSe(t,Pj(e))}function Tw(e){var t,n;for(n=new w(e.a.b);n.ar)}function ZZe(e){return M(e.c,(lw(),ORt)),Ax(e.a,D(N(hO((aD(),O0)))))?new Sse:new nhe(e)}function QZe(e){for(;!e.d||!e.d.Ob();)if(e.b&&!qi(e.b))e.d=P(Fm(e.b),51);else return null;return e.d}function $Ze(e){switch(e.g){case 1:return txt;default:case 2:return 0;case 3:return RL;case 4:return PV}}function eQe(){xP();var e;return JHt||(e=uEe(oP(`M`,!0)),e=Rp(oP(`M`,!1),e),JHt=e,JHt)}function Mw(){Mw=C,I5=new qc(`ELK`,0),QBt=new qc(`JSON`,1),ZBt=new qc(`DOT`,2),$Bt=new qc(`SVG`,3)}function Nw(){Nw=C,c2=new ac(`STACKED`,0),o2=new ac(`REVERSE_STACKED`,1),s2=new ac(`SEQUENCED`,2)}function Pw(){Pw=C,PPt=new mc(wR,0),B2=new mc(`MIDDLE_TO_MIDDLE`,1),z2=new mc(`AVOID_OVERLAP`,2)}function Fw(){Fw=C,vX=new cne,yX=new lne,VOt=new one,BOt=new une,zOt=new sne,_X=(Gh(zOt),new le)}function Iw(){Iw=C,vBt=new iu(15),_Bt=new ou((vP(),A6),vBt),h8=V6,pBt=rzt,mBt=w6,gBt=E6,hBt=T6}function Lw(e,t){var n,r,i,a,o;for(r=t,i=0,a=r.length;i=e.b.c.length||(sQe(e,2*t+1),n=2*t+2,n0&&(t.Cd(n),n.i&&n1e(n))}function lQe(e,t,n){var r;for(r=n-1;r>=0&&e[r]===t[r];r--);return r<0?0:rs(uv(e[r],_I),uv(t[r],_I))?-1:1}function uQe(e,t,n){var r,i;this.g=e,this.c=t,this.a=this,this.d=this,i=UJe(n),r=V(PTt,fF,227,i,0,1),this.b=r}function Vw(e,t,n,r,i){var a,o;for(o=n;o<=i;o++)for(a=t;a<=r;a++)if(sk(e,a,o))return!0;return!1}function dQe(e,t){var n,r;for(r=e.Zb().Cc().Kc();r.Ob();)if(n=P(r.Pb(),16),n.Hc(t))return!0;return!1}function fQe(e,t,n){var r,i,a,o;for(Gh(n),o=!1,a=e.fd(t),i=n.Kc();i.Ob();)r=i.Pb(),a.Rb(r),o=!0;return o}function Hw(e,t){var n,r=P(NC(e.a,4),129);return n=V(g7,FU,424,t,0,1),r!=null&&tN(r,0,n,0,r.length),n}function pQe(e,t){var n=new yM(!!(e.f&256),e.i,e.a,e.d,!!(e.f&16),e.j,e.g,t);return e.e??(n.c=e),n}function mQe(e,t){var n;return e===t?!0:j(t,85)?(n=P(t,85),eet(am(e),n.vc())):!1}function hQe(e,t,n){var r,i;for(i=n.Kc();i.Ob();)if(r=P(i.Pb(),44),e.Be(t,r.md()))return!0;return!1}function gQe(e,t,n){return e.d[t.p][n.p]||(p4e(e,t,n),e.d[t.p][n.p]=!0,e.d[n.p][t.p]=!0),e.a[t.p][n.p]}function _Qe(e,t){var n;return!e||e==t||!yd(t,(Y(),NQ))?!1:(n=P(K(t,(Y(),NQ)),10),n!=e)}function Uw(e){switch(e.i){case 2:return!0;case 1:return!1;case-1:++e.c;default:return e.$l()}}function vQe(e){switch(e.i){case-2:return!0;case-1:return!1;case 1:--e.c;default:return e._l()}}function yQe(e){yRe.call(this,`The given string does not match the expected format for individual spacings.`,e)}function bQe(e,t){var n;t.Ug(`Min Size Preprocessing`,1),n=Zet(e),OO(e,(xM(),Y4),n.a),OO(e,K4,n.b),t.Vg()}function xQe(e){var t=0,n,r=V(K3,X,8,e.b,0,1);for(n=dO(e,0);n.b!=n.d.c;)r[t++]=P(Lv(n),8);return r}function Ww(e,t,n){var r=new vo,i,a;for(a=dO(n,0);a.b!=a.d.c;)i=P(Lv(a),8),up(r,new Vl(i));fQe(e,t,r)}function SQe(e,t){var n=yE(e,t);return rs(fv(e,t),0)|sl(fv(e,n),0)?n:yE(tF,fv(um(n,63),1))}function CQe(e,t){var n=P(e.d.Bc(t),16),r;return n?(r=e.e.hc(),r.Gc(n),e.e.d-=n.gc(),n.$b(),r):null}function wQe(e){var t=e.a.c.length;if(t>0)return gm(t-1,e.a.c.length),Ay(e.a,t-1);throw E(new Sge)}function TQe(e,t,n){if(e>t)throw E(new Fi(BI+e+vyt+t));if(e<0||t>n)throw E(new ia(BI+e+VI+t+MI+n))}function Gw(e,t){e.D==null&&e.B!=null&&(e.D=e.B,e.B=null),wS(e,t==null?null:(Gh(t),t)),e.C&&e.hl(null)}function EQe(e,t){var n=hO((aD(),O0))!=null&&t.Sg()!=null?D(N(t.Sg()))/D(N(hO(O0))):1;Qh(e.b,t,n)}function DQe(e,t){var n,r=e.c[t];if(r!=0)for(e.c[t]=0,e.d-=r,n=t+1;nNV?e-n>NV:n-e>NV}function ZQe(e,t){var n;for(n=0;ni&&(Z8e(t.q,i),r=n!=t.q.d)),r}function e$e(e,t){var n,i,a,o,s,c,l=t.i,u=t.j;return i=e.f,a=i.i,o=i.j,s=l-a,c=u-o,n=r.Math.sqrt(s*s+c*c),n}function t$e(e,t){var n,r=KD(e);return r||(!_Vt&&(_Vt=new Jse),n=(NN(),Vit(t)),r=new qhe(n),tb(r.El(),e)),r}function sT(e,t){var n=P(e.c.Bc(t),16),r;return n?(r=e.hc(),r.Gc(n),e.d-=n.gc(),n.$b(),e.mc(r)):e.jc()}function n$e(e,t){var n,r=Lj(e.d,1)!=0;for(n=!0;n;)n=!1,n=t.c.mg(t.e,r),n|=$j(e,t,r,!1),r=!r;WS(e)}function r$e(e,t,n,r){var i,a;e.a=t,a=+!r,e.f=(i=new uet(e.c,e.a,n,a),new Hct(n,e.a,i,e.e,e.b,e.c==(sS(),g2)))}function cT(e){var t;return jd(e.a!=e.b),t=e.d.a[e.a],lDe(e.b==e.d.c&&t!=null),e.c=e.a,e.a=e.a+1&e.d.a.length-1,t}function i$e(e){var t;if(e.c!=0)return e.c;for(t=0;t=e.c.b:e.a<=e.c.b))throw E(new Hr);return t=e.a,e.a+=e.c.c,++e.b,G(t)}function lT(e){var t=new Dwe(e.a);return VC(t,e),W(t,(Y(),WQ),e),t.o.a=e.g,t.o.b=e.f,t.n.a=e.i,t.n.b=e.j,t}function uT(e){return(nP(),c5).Hc(e.j)?D(N(K(e,(Y(),c$)))):Sw(U(O(K3,1),X,8,0,[e.i.n,e.n,e.a])).b}function o$e(e){var t=Wl(ONt);return P(K(e,(Y(),OQ)),21).Hc((uM(),YZ))&&vp(t,(vA(),bJ),(yP(),eX)),t}function s$e(e){var t,n,r,i=new Jr;for(r=new w(e);r.a=0?t:-t;r>0;)r%2==0?(n*=n,r=r/2|0):(i*=n,--r);return t<0?1/i:i}function f$e(e,t){var n,r,i=1;for(n=e,r=t>=0?t:-t;r>0;)r%2==0?(n*=n,r=r/2|0):(i*=n,--r);return t<0?1/i:i}function pT(e,t){var n,r,i,a=(i=e?KD(e):null,btt((r=t,i&&i.Gl(),r)));return a==t&&(n=KD(e),n&&n.Gl()),a}function p$e(e,t,n){var r,i=e.f;return e.f=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,0,i,t),n?n.nj(r):n=r),n}function m$e(e,t,n){var r,i=e.b;return e.b=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,3,i,t),n?n.nj(r):n=r),n}function mT(e,t,n){var r,i=e.a;return e.a=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,1,i,t),n?n.nj(r):n=r),n}function h$e(e){var t,n,r,i;if(e!=null){for(n=0;n=r||t-129&&e<128?(iMe(),t=e+128,n=OG[t],!n&&(n=OG[t]=new jn(e)),n):new jn(e)}function xT(e){var t,n;return e>-129&&e<128?(GMe(),t=e+128,n=FG[t],!n&&(n=FG[t]=new Nn(e)),n):new Nn(e)}function C$e(e,t){var n;e.a.c.length>0&&(n=P(Ep(e.a,e.a.c.length-1),579),tQe(n,t))||M(e.a,new nUe(t))}function w$e(e){Lf();var t=e.d.c-e.e.c,n=P(e.g,154);Dx(n.b,new Rpe(t)),Dx(n.c,new zpe(t)),ly(n.i,new Bpe(t))}function T$e(e){var t=new ta;return t.a+=`VerticalSegment `,hl(t,e.e),t.a+=` `,gl(t,_Te(new Xi,new w(e.k))),t.a}function ST(e,t){var n=0,r,i;for(i=SE(e,t).Kc();i.Ob();)r=P(i.Pb(),12),n+=K(r,(Y(),QQ))==null?0:1;return n}function CT(e,t,n){var r=0,i,a;for(a=dO(e,0);a.b!=a.d.c&&(i=D(N(Lv(a))),!(i>n));)i>=t&&++r;return r}function E$e(e,t){ph(e);try{return e._b(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function wT(e,t){ph(e);try{return e.Hc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function D$e(e,t){ph(e);try{return e.Mc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return!1;throw E(e)}}function TT(e,t){ph(e);try{return e.xc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return null;throw E(e)}}function O$e(e,t){ph(e);try{return e.Bc(t)}catch(e){if(e=ew(e),j(e,212)||j(e,169))return null;throw E(e)}}function ET(e,t){switch(t.g){case 2:case 1:return SE(e,t);case 3:case 4:return UE(SE(e,t))}return Vg(),Vg(),QG}function DT(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (name: `,pl(t,e.zb),t.a+=`)`,t.a)}function k$e(e){var t=P(ix(e.c.c,``),233);return t||(t=new ev(Ca(Sa(new Qt,``),`Other`)),oO(e.c.c,``,t)),t}function OT(e,t,n){var r,i=e.sb;return e.sb=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,4,i,t),n?n.nj(r):n=r),n}function kT(e,t,n){var r,i=e.r;return e.r=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,8,i,e.r),n?n.nj(r):n=r),n}function A$e(e,t,n){var r=new Hb(e.e,4,13,(i=t.c,i||(CP(),q7)),null,NO(e,t),!1),i;return n?n.nj(r):n=r,n}function j$e(e,t,n){var r=new Hb(e.e,3,13,null,(i=t.c,i||(CP(),q7)),NO(e,t),!1),i;return n?n.nj(r):n=r,n}function AT(e,t){var n=P(t,691),r=n.el();return!r&&n.fl(r=j(t,90)?new QSe(e,P(t,29)):new dBe(e,P(t,156))),r}function jT(e,t,n){var r;e._i(e.i+1),r=e.Zi(t,n),t!=e.i&&tN(e.g,t,e.g,t+1,e.i-t),Sh(e.g,t,r),++e.i,e.Mi(t,n),e.Ni()}function M$e(e,t){var n;return t.a&&(n=t.a.a.length,e.a?gl(e.a,e.b):e.a=new Gu(e.d),TBe(e.a,t.a,t.d.length,n)),e}function N$e(e,t){var n;e.c=t,e.a=a0e(t),e.a<54&&(e.f=(n=t.d>1?CBe(t.a[0],t.a[1]):CBe(t.a[0],0),Dv(t.e>0?n:kb(n))))}function MT(e,t){var n=new Re;return e.a.Bd(n)?(Bu(),new wi(Gh(nKe(e,n.a,t)))):(Hh(e),Bu(),Bu(),oK)}function P$e(e,t){var n;e.c.length!=0&&(n=P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199),zl(n,new mte),Unt(n,t))}function F$e(e,t){var n;e.c.length!=0&&(n=P(rO(e,V(UJ,jR,10,e.c.length,0,1)),199),zl(n,new hte),Unt(n,t))}function NT(e,t){return rl(e)?ff(e,t):al(e)?wOe(e,t):il(e)?(Gh(e),A(e)===A(t)):RNe(e)?e.Fb(t):Wp(e)?vCe(e,t):Oze(e,t)}function PT(e,t,n){if(t<0)Qtt(e,n);else{if(!n.rk())throw E(new Fi(HH+n.xe()+UH));P(n,69).wk().Ek(e,e.hi(),t)}}function I$e(e,t,n){if(e<0||t>n)throw E(new Mi(BI+e+VI+t+`, size: `+n));if(e>t)throw E(new Fi(BI+e+vyt+t))}function L$e(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (source: `,pl(t,e.d),t.a+=`)`,t.a)}function R$e(e){return e>=65&&e<=70?e-65+10:e>=97&&e<=102?e-97+10:e>=48&&e<=57?e-48:0}function z$e(e){SP();var t,n,r,i;for(n=sO(),r=0,i=n.length;r=0?yD(e):Xm(yD(kb(e))))}function W$e(e,t,n,r,i,a){this.e=new T,this.f=(uS(),i2),M(this.e,e),this.d=t,this.a=n,this.b=r,this.f=i,this.c=a}function G$e(e,t,n){e.n=Dp(Y9,[X,dI],[376,28],14,[n,C_(r.Math.ceil(t/32))],2),e.o=t,e.p=n,e.j=t-1>>1,e.k=n-1>>1}function K$e(e){return e-=e>>1&1431655765,e=(e>>2&858993459)+(e&858993459),e=(e>>4)+e&252645135,e+=e>>8,e+=e>>16,e&63}function q$e(e,t){var n,r;for(r=new Lu(e);r.e!=r.i.gc();)if(n=P(gO(r),142),A(t)===A(n))return!0;return!1}function J$e(e,t,n){var r,i,a=(i=Mj(e.b,t),i);return a&&(r=P(jN(Lb(e,a),``),29),r)?Hit(e,r,t,n):null}function UT(e,t,n){var r,i,a=(i=Mj(e.b,t),i);return a&&(r=P(jN(Lb(e,a),``),29),r)?Uit(e,r,t,n):null}function Y$e(e,t){var n=Bx(e.i,t);if(n==null)throw E(new Vi(`Node did not exist in input.`));return yC(t,n),null}function X$e(e,t){var n=Qj(e,t);if(j(n,331))return P(n,35);throw E(new Fi(HH+t+`' is not a valid attribute`))}function WT(e,t,n){var r=e.gc();if(t>r)throw E(new lf(t,r));if(e.Si()&&e.Hc(n))throw E(new Fi(vU));e.Gi(t,n)}function Z$e(e,t){t.Ug(`Sort end labels`,1),To(hg(ox(new Mp(null,new cv(e.b,16)),new Qee),new $ee),new ete),t.Vg()}function GT(){GT=C,r8=new jc(dL,0),n8=new jc(lL,1),t8=new jc(cL,2),e8=new jc(hL,3),i8=new jc(`UP`,4)}function KT(){KT=C,m3=new Tc(`P1_STRUCTURE`,0),h3=new Tc(`P2_PROCESSING_ORDER`,1),g3=new Tc(`P3_EXECUTION`,2)}function Q$e(){Q$e=C,jFt=HD(HD(Go(HD(HD(Go(vp(new Zh,(Ok(),P2),(LM(),R2)),F2),OPt),APt),I2),wPt),jPt)}function $$e(e){switch(P(K(e,(Y(),MQ)),311).g){case 1:W(e,MQ,(Zb(),iQ));break;case 2:W(e,MQ,(Zb(),oQ))}}function e1e(e){switch(e){case 0:return new a_e;case 1:return new r_e;case 2:return new i_e;default:throw E(new Lr)}}function t1e(e){switch(e.g){case 2:return n8;case 1:return t8;case 4:return e8;case 3:return i8;default:return r8}}function qT(e,t){switch(e.b.g){case 0:case 1:return t;case 2:case 3:return new wg(t.d,0,t.a,t.b);default:return null}}function JT(e){switch(e.g){case 1:return g5;case 2:return Z8;case 3:return X8;case 4:return m5;default:return h5}}function YT(e){switch(e.g){case 1:return m5;case 2:return g5;case 3:return Z8;case 4:return X8;default:return h5}}function XT(e){switch(e.g){case 1:return X8;case 2:return m5;case 3:return g5;case 4:return Z8;default:return h5}}function ZT(e,t,n,r){switch(t){case 1:return!e.n&&(e.n=new F(Q5,e,1,7)),e.n;case 2:return e.k}return W3e(e,t,n,r)}function QT(e,t,n){var r,i;return e.Pj()?(i=e.Qj(),r=dj(e,t,n),e.Jj(e.Ij(7,G(n),r,t,i)),r):dj(e,t,n)}function $T(e,t){var n,r,i;e.d==null?(++e.e,--e.f):(i=t.ld(),n=t.Bi(),r=(n&AP)%e.d.length,nWe(e,r,Zit(e,r,n,i)))}function eE(e,t){var n=(e.Bb&pF)!=0;t?e.Bb|=pF:e.Bb&=-1025,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,10,n,t))}function tE(e,t){var n=(e.Bb&uI)!=0;t?e.Bb|=uI:e.Bb&=-4097,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,12,n,t))}function nE(e,t){var n=(e.Bb&RU)!=0;t?e.Bb|=RU:e.Bb&=-8193,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,15,n,t))}function rE(e,t){var n=(e.Bb&zU)!=0;t?e.Bb|=zU:e.Bb&=-2049,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,11,n,t))}function n1e(e){var t;e.g&&(t=e.c.kg()?e.f:e.a,Ost(t.a,e.o,!0),Ost(t.a,e.o,!1),W(e.o,(mP(),Q1),(rA(),L8)))}function r1e(e){var t;if(!e.a)throw E(new Ii(`Cannot offset an unassigned cut.`));t=e.c-e.b,e.b+=t,NIe(e,t),MIe(e,t)}function i1e(e,t){var n=xh(e.k,t);if(n==null)throw E(new Vi(`Port did not exist in input.`));return yC(t,n),null}function a1e(e){var t,n;for(n=Git(Mx(e)).Kc();n.Ob();)if(t=kd(n.Pb()),JM(e,t))return _He((Zbe(),VVt),t);return null}function o1e(e){var t,n;for(n=e.p.a.ec().Kc();n.Ob();)if(t=P(n.Pb(),218),t.f&&e.b[t.c]<-1e-10)return t;return null}function s1e(e){var t,n=jh(new ta,91);for(t=!0;e.Ob();)t||(n.a+=PP),t=!1,hl(n,e.Pb());return(n.a+=`]`,n).a}function c1e(e){var t=new T,n,r;for(r=new w(e.b);r.at?1:e==t?e==0?aE(1/e,1/t):0:isNaN(e)?+!isNaN(t):-1}function u1e(e){var t=e.a[e.c-1&e.a.length-1];return t==null?null:(e.c=e.c-1&e.a.length-1,Sh(e.a,e.c,null),t)}function d1e(e){var t,n,r=0;for(n=e.length,t=0;t=1?n8:e8):n}function g1e(e){switch(P(K(e,(mP(),S1)),223).g){case 1:return new zre;case 3:return new Wre;default:return new Rre}}function lE(e){if(e.c)lE(e.c);else if(e.d)throw E(new Ii(`Stream already terminated, can't be modified or used`))}function uE(e,t,n){var r=e.a.get(t);return e.a.set(t,n===void 0?null:n),r===void 0?(++e.c,++e.b.g):++e.d,r}function _1e(e,t,n){var r,i;for(i=e.a.ec().Kc();i.Ob();)if(r=P(i.Pb(),10),$C(n,P(Ep(t,r.p),16)))return r;return null}function dE(e,t,n){var r=0;return t&&(Jl(e.a)?r+=t.f.a/2:r+=t.f.b/2),n&&(Jl(e.a)?r+=n.f.a/2:r+=n.f.b/2),r}function v1e(e,t,n){var r=n;!r&&(r=Qje(new di,0)),r.Ug(_bt,2),v4e(e.b,t,r.eh(1)),fmt(e,t,r.eh(1)),u_t(t,r.eh(1)),r.Vg()}function fE(e,t,n){var r=(Ia(),i=new tn,i),i;return Xx(r,t),Vx(r,n),e&&tb((!e.a&&(e.a=new ju(z5,e,5)),e.a),r),r}function pE(e){var t;return e.Db&64?Aj(e):(t=new Wu(Aj(e)),t.a+=` (identifier: `,pl(t,e.k),t.a+=`)`,t.a)}function mE(e,t){var n=(e.Bb&GH)!=0;t?e.Bb|=GH:e.Bb&=-32769,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,18,n,t))}function hE(e,t){var n=(e.Bb&GH)!=0;t?e.Bb|=GH:e.Bb&=-32769,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,18,n,t))}function gE(e,t){var n=(e.Bb&ZP)!=0;t?e.Bb|=ZP:e.Bb&=-16385,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,16,n,t))}function _E(e,t){var n=(e.Bb&pI)!=0;t?e.Bb|=pI:e.Bb&=-65537,e.Db&4&&!(e.Db&1)&&AC(e,new vy(e,1,20,n,t))}function vE(e){var t=V(K9,EF,28,2,15,1);return e-=pI,t[0]=(e>>10)+mI&OF,t[1]=(e&1023)+56320&OF,ND(t,0,t.length)}function y1e(e){var t=OA(e);return t>34028234663852886e22?cI:t<-34028234663852886e22?lI:t}function yE(e,t){var n;return Il(e)&&Il(t)&&(n=e+t,iI`+hv(t.c):`e_`+US(t),e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))}function S1e(e,t){return ff(t.b&&t.c?hv(t.b)+`->`+hv(t.c):`e_`+US(t),e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))}function CE(e,t){return uu(),fS(bF),r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t))}function wE(){wE=C,f8=new Nc(dL,0),u8=new Nc(`POLYLINE`,1),l8=new Nc(`ORTHOGONAL`,2),d8=new Nc(`SPLINES`,3)}function TE(){TE=C,IIt=new Sc(`ASPECT_RATIO_DRIVEN`,0),Q4=new Sc(`MAX_SCALE_DRIVEN`,1),FIt=new Sc(`AREA_DRIVEN`,2)}function C1e(e,t,n){var r;try{MZe(e,t,n)}catch(e){throw e=ew(e),j(e,606)?(r=e,E(new EUe(r))):E(e)}return t}function w1e(e){var t,n,r;for(n=0,r=e.length;nt&&r.Ne(e[a-1],e[a])>0;--a)o=e[a],Sh(e,a,e[a-1]),Sh(e,a-1,o)}function jE(e,t){var n=t.f,r,i,a,o;if(oO(e.c.d,n,t),t.g!=null)for(i=t.g,a=0,o=i.length;at){OBe(n);break}}Zm(n,t)}function A1e(e,t){var n,i=D(N(gD(Ev(t),(mP(),c0))));n=r.Math.max(0,i/2-.5),zk(t,n,1),M(e,new Oxe(t,n))}function j1e(e,t,n){var r;n.Ug(`Straight Line Edge Routing`,1),n.dh(t,mxt),r=P(J(t,(Pd(),y4)),27),ppt(e,r),n.dh(t,YV)}function ME(e,t){e.n.c.length==0&&M(e.n,new w_(e.s,e.t,e.i)),M(e.b,t),q4e(P(Ep(e.n,e.n.c.length-1),209),t),tft(e,t)}function NE(e){var t;this.a=(t=P(e.e&&e.e(),9),new xf(t,P(Yd(t,t.length),9),0)),this.b=V(WW,FP,1,this.a.a.length,5,1)}function PE(e){var t;return Array.isArray(e)&&e.Tm===ne?Ha($w(e))+`@`+(t=US(e)>>>0,t.toString(16)):e.toString()}function M1e(e,t){return e.h==eI&&e.m==0&&e.l==0?(t&&(mG=vu(0,0,0)),xCe(($b(),gG))):(t&&(mG=vu(e.l,e.m,e.h)),vu(0,0,0))}function N1e(e,t){switch(t.g){case 2:return e.b;case 1:return e.c;case 4:return e.d;case 3:return e.a;default:return!1}}function P1e(e,t){switch(t.g){case 2:return e.b;case 1:return e.c;case 4:return e.d;case 3:return e.a;default:return!1}}function FE(e,t,n,r){switch(t){case 3:return e.f;case 4:return e.g;case 5:return e.i;case 6:return e.j}return ZT(e,t,n,r)}function IE(e,t){if(t==e.d)return e.e;if(t==e.e)return e.d;throw E(new Fi(`Node `+t+` not part of edge `+e))}function F1e(e,t){var n=Qj(e.Dh(),t);if(j(n,102))return P(n,19);throw E(new Fi(HH+t+`' is not a valid reference`))}function LE(e,t,n,r){if(t<0)Pat(e,n,r);else{if(!n.rk())throw E(new Fi(HH+n.xe()+UH));P(n,69).wk().Ck(e,e.hi(),t,r)}}function RE(e){var t;if(e.b){if(RE(e.b),e.b.d!=e.c)throw E(new Vr)}else e.d.dc()&&(t=P(e.f.c.xc(e.e),16),t&&(e.d=t))}function I1e(e){Rd();var t=e.o.b,n,r,i;for(r=P(P(Dy(e.r,(nP(),m5)),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i=n.e,i.b+=t}function L1e(e){var t,n,r;for(this.a=new Rl,r=new w(e);r.a=i)return t.c+n;return t.c+t.b.gc()}function z1e(e,t){Nd();var n,r=LGe(e),i=t,a;for(bb(r,0,r.length,i),n=0;n0&&(r+=i,++n);return n>1&&(r+=e.d*(n-1)),r}function V1e(e){var t,n,r,i,a=m7e(e);return n=eo(e.c),r=!n,r&&(i=new Tn,hx(a,`knownLayouters`,i),t=new Mhe(i),ly(e.c,t)),a}function HE(e){var t,n,r=new $i;for(r.a+=`[`,t=0,n=e.gc();t0&&(sv(t-1,e.length),e.charCodeAt(t-1)==58)&&!zE(e,y7,b7))}function WE(e,t){var n;return A(e)===A(t)?!0:j(t,92)?(n=P(t,92),e.e==n.e&&e.d==n.d&&xHe(e,n.a)):!1}function GE(e){switch(nP(),e.g){case 4:return Z8;case 1:return X8;case 3:return m5;case 2:return g5;default:return h5}}function G1e(e){var t,n;if(e.b)return e.b;for(n=_K?null:e.d;n;){if(t=_K?null:n.b,t)return t;n=_K?null:n.d}return Co(),hK}function KE(e){var t,n,r=D(N(e.a.of((vP(),q6))));for(n=new w(e.a.Sf());n.a>5,t=e&31,r=V(q9,HF,28,n+1,15,1),r[n]=1<3;)i*=10,--a;e=(e+(i>>1))/i|0}return r.i=e,!0}function eD(e,t){var n=(e.i??aN(e),e.i),r=t.Lj(),i;if(r!=-1){for(i=n.length;r=0;--r)for(t=n[r],i=0;i>1,this.k=t-1>>1}function f0e(e){gb(),P(e.of((vP(),D6)),181).Hc((UM(),A5))&&(P(e.of(z6),181).Fc((rj(),J8)),P(e.of(D6),181).Mc(A5))}function p0e(e){var t=e.d==(GA(),WX),n=x5e(e);t&&!n||!t&&n?W(e.a,(mP(),J$),(RO(),Z3)):W(e.a,(mP(),J$),(RO(),X3))}function aD(){aD=C,zo(),O0=(mP(),v0),EMt=Oy(U(O(j3,1),_V,149,0,[s0,c0,u0,d0,m0,h0,g0,_0,b0,S0,l0,f0,y0]))}function m0e(e,t){var n=P(ay(e,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15);return n.Qc(MMe(n.gc()))}function h0e(e,t){var n,r=new nr(e.a.ad(t,!0));if(r.a.gc()<=1)throw E(new zr);return n=r.a.ec().Kc(),n.Pb(),P(n.Pb(),40)}function g0e(e,t,n){var r=D(e.p[t.i.p])+D(e.d[t.i.p])+t.n.b+t.a.b;return D(e.p[n.i.p])+D(e.d[n.i.p])+n.n.b+n.a.b-r}function oD(e,t){var n;return e.i>0&&(t.lengthe.i&&Sh(t,e.i,null),t}function sD(e){var t;return e.Db&64?DT(e):(t=new Wu(DT(e)),t.a+=` (instanceClassName: `,pl(t,e.D),t.a+=`)`,t.a)}function cD(e){var t,n,r,i=0;for(n=0,r=e.length;n0&&(e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Zit(e,i,r,t),n!=-1)}function v0e(e,t){var n,i;e.a=yE(e.a,1),e.c=r.Math.min(e.c,t),e.b=r.Math.max(e.b,t),e.d+=t,n=t-e.f,i=e.e+n,e.f=i-e.e-n,e.e=i}function dD(e,t){switch(t){case 3:Ux(e,0);return;case 4:Wx(e,0);return;case 5:Gx(e,0);return;case 6:Kx(e,0);return}vT(e,t)}function fD(e,t){switch(t.g){case 1:return Jf(e.j,(fC(),$J));case 2:return Jf(e.j,(fC(),tY));default:return Vg(),Vg(),QG}}function pD(e){gh();var t=e.Pc();switch(t.length){case 0:return QW;case 1:return new wp(ph(t[0]));default:return new u_(w1e(t))}}function y0e(e,t){e.Xj();try{e.d.bd(e.e++,t),e.f=e.d.j,e.g=-1}catch(e){throw e=ew(e),j(e,77)?E(new Vr):E(e)}}function mD(){mD=C,c9=new Xse,iHt=new Zse,aHt=new Qse,oHt=new $se,sHt=new ece,cHt=new tce,lHt=new nce,uHt=new rce,dHt=new ice}function hD(e,t){Sl();var n=Kd((Ci(),Ci(),dG)),r=null;return t==n&&(r=P(v_(uG,e),624)),r||(r=new ZPe(e),t==n&&H_(uG,e,r)),r}function b0e(e){return IO(),(e.q?e.q:(Vg(),Vg(),$G))._b((mP(),V1))?P(K(e,V1),203):P(K(Bh(e),H1),203)}function gD(e,t){var n,r=null;return yd(e,(mP(),p0))&&(n=P(K(e,p0),96),n.pf(t)&&(r=n.of(t))),r??=K(Bh(e),t),r}function x0e(e,t){var n,r,i;return j(t,44)?(n=P(t,44),r=n.ld(),i=TT(e.Rc(),r),zh(i,n.md())&&(i!=null||e.Rc()._b(r))):!1}function _D(e,t){var n,r,i;return e.f>0&&(e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Knt(e,i,r,t),n)?n.md():null}function vD(e,t,n){var r,i,a;return e.Pj()?(r=e.i,a=e.Qj(),jT(e,r,t),i=e.Ij(3,null,t,r,a),n?n.nj(i):n=i):jT(e,e.i,t),n}function S0e(e,t,n){var r=new Hb(e.e,4,10,(i=t.c,j(i,90)?P(i,29):(CP(),J7)),null,NO(e,t),!1),i;return n?n.nj(r):n=r,n}function C0e(e,t,n){var r=new Hb(e.e,3,10,null,(i=t.c,j(i,90)?P(i,29):(CP(),J7)),NO(e,t),!1),i;return n?n.nj(r):n=r,n}function w0e(e){Rd();var t=new Vl(P(e.e.of((vP(),E6)),8));return e.B.Hc((UM(),T5))&&(t.a<=0&&(t.a=20),t.b<=0&&(t.b=20)),t}function yD(e){AM();var t,n=nm(e);return t=nm(um(e,32)),t==0?n>10||n<0?new Xv(1,n):YTt[n]:new Ize(n,t)}function bD(e,t){var n;return Il(e)&&Il(t)&&(n=e%t,iI=0?a=a.a[1]:(i=a,a=a.a[0])}return i}function OD(e,t,n){for(var r,i=null,a=e.b;a;){if(r=e.a.Ne(t,a.d),n&&r==0)return a;r<=0?a=a.a[0]:(i=a,a=a.a[1])}return i}function N0e(e,t,n,r){var i=!1,a,o;return mht(e.f,n,r)&&(_2e(e.f,e.a[t][n],e.a[t][r]),a=e.a[t],o=a[r],a[r]=a[n],a[n]=o,i=!0),i}function P0e(e,t,n){var r,i=P(xh(e.b,n),183),a,o;for(r=0,o=new w(t.j);o.a>5,r,i,a;return t&=31,i=e.d+n+(t==0?0:1),r=V(q9,HF,28,i,15,1),v7e(r,e.a,n,t),a=new Bm(e.e,i,r),Cv(a),a}function I0e(e,t){var n,r,i;for(r=new pm(Vu(OE(e).a.Kc(),new d));Cj(r);)if(n=P(by(r),18),i=n.d.i,i.c==t)return!1;return!0}function AD(e,t,n){var i,a,o,s=e.k,c=t.k;return i=n[s.g][c.g],a=N(gD(e,i)),o=N(gD(t,i)),r.Math.max((Gh(a),a),(Gh(o),o))}function L0e(){return Error.stackTraceLimit>0?(r.Error.stackTraceLimit=Error.stackTraceLimit=64,!0):`stack`in Error()}function R0e(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))>0}function jD(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))<0}function z0e(e,t){return uu(),uu(),fS(bF),(r.Math.abs(e-t)<=bF||e==t||isNaN(e)&&isNaN(t)?0:et?1:Pl(isNaN(e),isNaN(t)))<=0}function MD(e,t){for(var n=0;!t[n]||t[n]==``;)n++;for(var r=t[n++];n0&&this.b>0&&(this.g=Pp(this.c,this.b,this.a))}function K0e(e,t){var n=e.a,r;t=String(t),n.hasOwnProperty(t)&&(r=n[t]);var i=(vw(),pG)[typeof r];return i?i(r):XQe(typeof r)}function RD(e){var t,n,r=null;if(t=dU in e.a,n=!t,n)throw E(new Vi(`Every element must have an id.`));return r=ij(A_(e,dU)),r}function zD(e){var t,n=vet(e);for(t=null;e.c==2;)hP(e),t||(t=(xP(),xP(),++W9,new lu(2)),LN(t,n),n=t),n.Jm(vet(e));return n}function BD(e,t){var n,r,i;return e._j(),r=t==null?0:US(t),i=(r&AP)%e.d.length,n=Knt(e,i,r,t),n?(aJe(e,n),n.md()):null}function q0e(e,t){return e.e>t.e?1:e.et.d?e.e:e.d=48&&e<48+r.Math.min(10,10)?e-48:e>=97&&e<97?e-97+10:e>=65&&e<65?e-65+10:-1}function Y0e(e,t){if(t.c==e)return t.d;if(t.d==e)return t.c;throw E(new Fi(`Input edge is not connected to the input port.`))}function X0e(e){if(qD(DH,e))return rd(),yG;if(qD(OH,e))return rd(),vG;throw E(new Fi(`Expecting true or false`))}function VD(e){switch(typeof e){case OP:return jw(e);case Vvt:return jl(e);case DP:return EDe(e);default:return e==null?0:td(e)}}function HD(e,t){if(e.a<0)throw E(new Ii(`Did not call before(...) or after(...) before calling add(...).`));return mEe(e,e.a,t),e}function UD(e){return R_(),j(e,162)?P(xh(f7,tEt),295).Rg(e):km(f7,$w(e))?P(xh(f7,$w(e)),295).Rg(e):null}function WD(e){var t,n;return e.Db&32||(n=(t=P(NC(e,16),29),bh(t||e.ii())-bh(e.ii())),n!=0&&GD(e,32,V(WW,FP,1,n,5,1))),e}function GD(e,t,n){var r;(e.Db&t)==0?n!=null&&pst(e,t,n):n==null?jrt(e,t):(r=pk(e,t),r==-1?e.Eb=n:Sh(rS(e.Eb),r,n))}function Z0e(e,t,n,r){var i,a;t.c.length!=0&&(i=Lat(n,r),a=ent(t),To(Cx(new Mp(null,new cv(a,1)),new Yie),new sIe(e,n,i,r)))}function Q0e(e,t){var n,r=e.a.length-1,i,a;return n=t-e.b&r,a=e.c-t&r,i=e.c-e.b&r,lDe(n=a?(PQe(e,t),-1):(NQe(e,t),1)}function KD(e){var t,n,r=e.Jh();if(!r)for(t=0,n=e.Ph();n;n=n.Ph()){if(++t>gI)return n.Qh();if(r=n.Jh(),r||n==e)break}return r}function $0e(e,t){var n;return A(t)===A(e)?!0:!j(t,21)||(n=P(t,21),n.gc()!=e.gc())?!1:e.Ic(n)}function e2e(e,t){return e.et.e?1:e.ft.f?1:US(e)-US(t)}function qD(e,t){return Gh(e),t==null?!1:ff(e,t)?!0:e.length==t.length&&ff(e.toLowerCase(),t.toLowerCase())}function JD(e){var t,n;return dT(e,-129)>0&&dT(e,128)<0?(WMe(),t=nm(e)+128,n=AG[t],!n&&(n=AG[t]=new Mn(e)),n):new Mn(e)}function YD(){YD=C,RJ=new Ds(wR,0),IJ=new Ds(`INSIDE_PORT_SIDE_GROUPS`,1),FJ=new Ds(`GROUP_MODEL_ORDER`,2),LJ=new Ds(vbt,3)}function t2e(e){var t;return e.b||eye(e,(t=hOe(e.e,e.a),!t||!ff(OH,_D((!t.b&&(t.b=new Td((CP(),$7),o9,t)),t.b),`qualified`)))),e.c}function n2e(e,t){for(var n=(sv(t,e.length),e.charCodeAt(t)),r=t+1;r2e3&&(ITt=e,sG=r.setTimeout(zye,10))),oG++==0&&(DKe((Si(),cG)),!0)}function x2e(e,t,n){var r;(mEt?(G1e(e),!0):hEt||_Et?(Co(),!0):gEt&&(Co(),!1))&&(r=new eke(t),r.b=n,w9e(e,r))}function eO(e,t){var n=!e.A.Hc((TD(),x5))||e.q==(rA(),R8);e.u.Hc((rj(),G8))?n?Qgt(e,t):Dgt(e,t):e.u.Hc(q8)&&(n?igt(e,t):x_t(e,t))}function S2e(e){var t;A(J(e,(vP(),g6)))===A((_T(),_8))&&(I_(e)?(t=P(J(I_(e),g6),346),OO(e,g6,t)):OO(e,g6,v8))}function C2e(e){var t,n;return yd(e.d.i,(mP(),Y1))?(t=P(K(e.c.i,Y1),17),n=P(K(e.d.i,Y1),17),_u(t.a,n.a)>0):!1}function w2e(e,t,n){return new wg(r.Math.min(e.a,t.a)-n/2,r.Math.min(e.b,t.b)-n/2,r.Math.abs(e.a-t.a)+n,r.Math.abs(e.b-t.b)+n)}function T2e(e){var t;this.d=new T,this.j=new Fa,this.g=new Fa,t=e.g.b,this.f=P(K(Bh(t),(mP(),_1)),88),this.e=D(N(yO(t,m0)))}function E2e(e){this.d=new T,this.e=new ry,this.c=V(q9,HF,28,(nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,15,1),this.b=e}function tO(e,t,n){var r=n[e.g][t];switch(e.g){case 1:case 3:return new k(0,r);case 2:case 4:return new k(r,0);default:return null}}function D2e(e,t,n){var r,i=P(h_(t.f),205);try{i.rf(e,n),bFe(t.f,i)}catch(e){throw e=ew(e),j(e,103)?(r=e,E(r)):E(e)}}function O2e(e,t,n){var r=null,i,a,o,s=Ymt(dS(),t),c;return a=null,s&&(i=null,c=Pmt(s,n),o=null,c!=null&&(o=e.qf(s,c)),i=o,a=i),r=a,r}function nO(e,t,n,r){var i=e.length;if(t>=i)return i;for(t=t>0?t:0;tr&&Sh(t,r,null),t}function k2e(e,t){var n,r=e.a.length;for(t.lengthr&&Sh(t,r,null),t}function iO(e,t){var n,r;if(++e.j,t!=null&&(n=(r=e.a.Cb,j(r,99)?P(r,99).th():null),Jnt(t,n))){GD(e.a,4,n);return}GD(e.a,4,P(t,129))}function A2e(e){var t;if(e==null)return null;if(t=Qit(EN(e,!0)),t==null)throw E(new Hi(`Invalid hexBinary value: '`+e+`'`));return t}function aO(e,t,n){var r;t.a.length>0&&(M(e.b,new Aje(t.a,n)),r=t.a.length,0r&&(t.a+=Uwe(V(K9,EF,28,-r,15,1))))}function j2e(e,t,n){var r,i,a;if(!n[t.d])for(n[t.d]=!0,i=new w(eT(t));i.a=e.b>>1)for(r=e.c,n=e.b;n>t;--n)r=r.b;else for(r=e.a.a,n=0;n=0?e.Wh(i):cj(e,r)):n<0?cj(e,r):P(r,69).wk().Bk(e,e.hi(),n)}function H2e(e){var t,n,r=(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),e.o);for(n=r.c.Kc();n.e!=n.i.gc();)t=P(n.Yj(),44),t.md();return Jy(r)}function hO(e){var t;if(j(e.a,4)){if(t=UD(e.a),t==null)throw E(new Ii(lSt+e.b+`'. `+sSt+(Ad(m7),m7.k)+cSt));return t}return e.a}function U2e(e,t){var n,r;if(e.j.length!=t.j.length)return!1;for(n=0,r=e.j.length;n=64&&t<128&&(i=dv(i,cm(1,t-64)));return i}function yO(e,t){var n,r=null;return yd(e,(vP(),K6))&&(n=P(K(e,K6),96),n.pf(t)&&(r=n.of(t))),r==null&&Bh(e)&&(r=K(Bh(e),t)),r}function W2e(e,t){var n=P(K(e,(mP(),j1)),75);return Cu(t,SOt)?n?Fg(n):(n=new ai,W(e,j1,n)):n&&W(e,j1,null),n}function bO(){bO=C,Iq=(vP(),Bzt),Pq=fzt,yDt=c6,Fq=A6,CDt=(Rk(),FK),SDt=NK,wDt=LK,xDt=MK,bDt=(qw(),kq),jq=gDt,Mq=_Dt,Nq=vDt}function xO(e){switch(Pbe(),this.c=new T,this.d=e,e.g){case 0:case 2:this.a=$h(NJ),this.b=cI;break;case 3:case 1:this.a=NJ,this.b=lI}}function G2e(e){var t;mf(P(K(e,(mP(),Q1)),101))&&(t=e.b,Znt((ov(0,t.c.length),P(t.c[0],30))),Znt(P(Ep(t,t.c.length-1),30)))}function K2e(e,t){t.Ug(`Self-Loop post-processing`,1),To(hg(hg(ox(new Mp(null,new cv(e.b,16)),new vne),new yne),new bne),new xne),t.Vg()}function q2e(e,t,n){var r,i;if(e.c)Gx(e.c,e.c.i+t),Kx(e.c,e.c.j+n);else for(i=new w(e.b);i.a=0&&(n.d=e.t);break;case 3:e.t>=0&&(n.a=e.t)}e.C&&(n.b=e.C.b,n.c=e.C.c)}function CO(){CO=C,LMt=new $s(vV,0),H0=new $s(JR,1),U0=new $s(`LINEAR_SEGMENTS`,2),V0=new $s(`BRANDES_KOEPF`,3),W0=new $s(Qbt,4)}function wO(){wO=C,wq=new xs(_L,0),Cq=new xs(vL,1),Tq=new xs(yL,2),Eq=new xs(bL,3),wq.a=!1,Cq.a=!0,Tq.a=!1,Eq.a=!0}function TO(){TO=C,gq=new ys(_L,0),hq=new ys(vL,1),_q=new ys(yL,2),vq=new ys(bL,3),gq.a=!1,hq.a=!0,_q.a=!1,vq.a=!0}function EO(e,t,n,r){var i;return n>=0?e.Sh(t,n,r):(e.Ph()&&(r=(i=e.Fh(),i>=0?e.Ah(r):e.Ph().Th(e,-1-i,null,r))),e.Ch(t,n,r))}function DO(e,t){switch(t){case 7:!e.e&&(e.e=new cf(U5,e,7,4)),RN(e.e);return;case 8:!e.d&&(e.d=new cf(U5,e,8,5)),RN(e.d);return}dD(e,t)}function OO(e,t,n){return n==null?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),BD(e.o,t)):(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),Hk(e.o,t,n)),e}function t4e(e,t){Vg();var n=e,r,i,a=t;for(j(e,21)&&!j(t,21)&&(n=t,a=e),i=n.Kc();i.Ob();)if(r=i.Pb(),a.Hc(r))return!1;return!0}function n4e(e,t,n,r){return t.an.b)}function kO(e,t){return rl(e)?!!TTt[t]:e.Sm?!!e.Sm[t]:al(e)?!!wTt[t]:il(e)?!!CTt[t]:!1}function r4e(e){var t=e.a;do t=P(by(new pm(Vu(DE(t).a.Kc(),new d))),18).c.i,t.k==(DA(),qJ)&&e.b.Fc(t);while(t.k==(DA(),qJ));e.b=UE(e.b)}function i4e(e,t){var n,i,a=e;for(i=new pm(Vu(DE(t).a.Kc(),new d));Cj(i);)n=P(by(i),18),n.c.i.c&&(a=r.Math.max(a,n.c.i.c.p));return a}function a4e(e,t){var n,r,i=0;for(r=P(P(Dy(e.r,t),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i+=n.d.d+n.b.Mf().b+n.d.a,r.Ob()&&(i+=e.w);return i}function o4e(e,t){var n,r,i=0;for(r=P(P(Dy(e.r,t),21),87).Kc();r.Ob();)n=P(r.Pb(),117),i+=n.d.b+n.b.Mf().a+n.d.c,r.Ob()&&(i+=e.w);return i}function s4e(e){var t,n,r=0,i=sM(e);if(i.c.length==0)return 1;for(n=new w(i);n.a=0?e.Lh(o,n,!0):mj(e,a,n)):P(a,69).wk().yk(e,e.hi(),i,n,r)}function d4e(e,t,n,r){var i=z$e(t.pf((vP(),C6))?P(t.of(C6),21):e.j);i!=(SP(),cq)&&(n&&!PD(i)||tet($it(e,i,r),t))}function f4e(e){switch(e.g){case 1:return KC(),mq;case 3:return KC(),dq;case 2:return KC(),pq;case 4:return KC(),fq;default:return null}}function p4e(e,t,n){if(e.e)switch(e.b){case 1:OIe(e.c,t,n);break;case 0:kIe(e.c,t,n)}else XVe(e.c,t,n);e.a[t.p][n.p]=e.c.i,e.a[n.p][t.p]=e.c.e}function m4e(e){var t,n;if(e==null)return null;for(n=V(UJ,X,199,e.length,0,2),t=0;t=0)return i;if(e.ol()){for(r=0;r=i)throw E(new lf(t,i));if(e.Si()&&(r=e.dd(n),r>=0&&r!=t))throw E(new Fi(vU));return e.Xi(t,n)}function FO(e,t){if(this.a=P(ph(e),253),this.b=P(ph(t),253),e.Ed(t)>0||e==(pi(),XW)||t==(mi(),ZW))throw E(new Fi(`Invalid range: `+tHe(e,t)))}function g4e(e){var t,n;for(this.b=new T,this.c=e,this.a=!1,n=new w(e.a);n.a0),(t&-t)==t)return C_(t*Lj(e,31)*4656612873077393e-25);do n=Lj(e,31),r=n%t;while(n-r+(t-1)<0);return C_(r)}function C4e(e,t,n){switch(n.g){case 1:e.a=t.a/2,e.b=0;break;case 2:e.a=t.a,e.b=t.b/2;break;case 3:e.a=t.a/2,e.b=t.b;break;case 4:e.a=0,e.b=t.b/2}}function HO(e,t,n,r){var i,a;for(i=t;i1&&(a=_4e(e,t)),a}function T4e(e){var t=D(N(J(e,(vP(),X6))))*r.Math.sqrt((!e.a&&(e.a=new F($5,e,10,11)),e.a).i);return new k(t,t/D(N(J(e,Y6))))}function GO(e){var t;return e.f&&e.f.Vh()&&(t=P(e.f,54),e.f=P(pT(e,t),84),e.f!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,8,t,e.f))),e.f}function KO(e){var t;return e.i&&e.i.Vh()&&(t=P(e.i,54),e.i=P(pT(e,t),84),e.i!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,7,t,e.i))),e.i}function qO(e){var t;return e.b&&e.b.Db&64&&(t=e.b,e.b=P(pT(e,t),19),e.b!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,21,t,e.b))),e.b}function JO(e,t){var n,r,i;e.d==null?(++e.e,++e.f):(r=t.Bi(),hot(e,e.f+1),i=(r&AP)%e.d.length,n=e.d[i],!n&&(n=e.d[i]=e.dk()),n.Fc(t),++e.f)}function YO(e,t,n){var r;return t.tk()?!1:t.Ik()==-2?t.qk()==e.e.Dh()&&n==null:(r=t.ik(),r==null?n==null:NT(r,n))}function XO(){var e;vS(16,Qvt),e=UJe(16),this.b=V($W,fF,303,e,0,1),this.c=V($W,fF,303,e,0,1),this.a=null,this.e=null,this.i=0,this.f=e-1,this.g=0}function ZO(e){$De.call(this),this.k=(DA(),JJ),this.j=(vS(6,hF),new Hy(6)),this.b=(vS(2,hF),new Hy(2)),this.d=new ti,this.f=new ri,this.a=e}function E4e(e){var t,n;e.c.length<=1||(t=oct(e,(nP(),m5)),Tet(e,P(t.a,17).a,P(t.b,17).a),n=oct(e,g5),Tet(e,P(n.a,17).a,P(n.b,17).a))}function D4e(e,t,n){var r,i=e.a.b;for(r=i.c.length;r102?-1:e<=57?e-48:e<65?-1:e<=70?e-65+10:e<97?-1:e-97+10}function ik(e,t){if(e==null)throw E(new Li(`null key in entry: null=`+t));if(t==null)throw E(new Li(`null value in entry: `+e+`=null`))}function M4e(e,t){for(var n,r;e.Ob();)if(!t.Ob()||(n=e.Pb(),r=t.Pb(),!(A(n)===A(r)||n!=null&&NT(n,r))))return!1;return!t.Ob()}function N4e(e,t){var n=U(O(Z9,1),hI,28,15,[rT(e.a[0],t),rT(e.a[1],t),rT(e.a[2],t)]);return e.d&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function P4e(e,t){var n=U(O(Z9,1),hI,28,15,[iT(e.a[0],t),iT(e.a[1],t),iT(e.a[2],t)]);return e.d&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function ak(e,t,n){mf(P(K(t,(mP(),Q1)),101))||(eUe(e,t,NA(t,n)),eUe(e,t,NA(t,(nP(),m5))),eUe(e,t,NA(t,Z8)),Vg(),hu(t.j,new tme(e)))}function F4e(e){var t,n;for(e.c||wmt(e),n=new ai,t=new w(e.a),z(t);t.a0&&(sv(0,t.length),t.charCodeAt(0)==43)?(sv(1,t.length+1),t.substr(1)):t))}function e3e(e){var t;return e==null?null:new ru((t=EN(e,!0),t.length>0&&(sv(0,t.length),t.charCodeAt(0)==43)?(sv(1,t.length+1),t.substr(1)):t))}function t3e(e,t,n,r,i,a,o,s){var c,l;r&&(c=r.a[0],c&&t3e(e,t,n,c,i,a,o,s),Tk(e,n,r.d,i,a,o,s)&&t.Fc(r),l=r.a[1],l&&t3e(e,t,n,l,i,a,o,s))}function sk(e,t,n){try{return ol(IS(e,t,n),1)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function n3e(e,t,n){try{return ol(IS(e,t,n),0)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function r3e(e,t,n){try{return ol(IS(e,t,n),2)}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function i3e(e,t){if(e.g==-1)throw E(new Rr);e.Xj();try{e.d.hd(e.g,t),e.f=e.d.j}catch(e){throw e=ew(e),j(e,77)?E(new Vr):E(e)}}function a3e(e){var t,n,r,i,a;for(r=new w(e.b);r.aa&&Sh(t,a,null),t}function o3e(e,t){var n,r=e.gc();if(t==null){for(n=0;n0&&(c+=i),l[u]=o,o+=s*(c+r)}function _3e(e){var t,n,r=e.f;for(e.n=V(Z9,hI,28,r,15,1),e.d=V(Z9,hI,28,r,15,1),t=0;t0?e.c:0),++a;e.b=i,e.d=o}function S3e(e,t){var n=U(O(Z9,1),hI,28,15,[BO(e,(Ix(),XK),t),BO(e,ZK,t),BO(e,QK,t)]);return e.f&&(n[0]=r.Math.max(n[0],n[2]),n[2]=n[0]),n}function C3e(e,t,n){var r;try{EM(e,t+e.j,n+e.k,!1,!0)}catch(e){throw e=ew(e),j(e,77)?(r=e,E(new Mi(r.g+TL+t+PP+n+`).`))):E(e)}}function w3e(e,t,n){var r;try{EM(e,t+e.j,n+e.k,!0,!1)}catch(e){throw e=ew(e),j(e,77)?(r=e,E(new Mi(r.g+TL+t+PP+n+`).`))):E(e)}}function T3e(e){var t;yd(e,(mP(),R1))&&(t=P(K(e,R1),21),t.Hc((Ej(),w8))?(t.Mc(w8),t.Fc(E8)):t.Hc(E8)&&(t.Mc(E8),t.Fc(w8)))}function E3e(e){var t;yd(e,(mP(),R1))&&(t=P(K(e,R1),21),t.Hc((Ej(),j8))?(t.Mc(j8),t.Fc(k8)):t.Hc(k8)&&(t.Mc(k8),t.Fc(j8)))}function gk(e,t,n,r){var i,a,o,s;return e.a??j9e(e,t),o=t.b.j.c.length,a=n.d.p,s=r.d.p,i=s-1,i<0&&(i=o-1),a<=i?e.a[i]-e.a[a]:e.a[o-1]-e.a[a]+e.a[i]}function D3e(e){var t,n;if(!e.b)for(e.b=kv(P(e.f,27).kh().i),n=new Lu(P(e.f,27).kh());n.e!=n.i.gc();)t=P(gO(n),135),M(e.b,new Di(t));return e.b}function O3e(e){var t,n;if(!e.e)for(e.e=kv(og(P(e.f,27)).i),n=new Lu(og(P(e.f,27)));n.e!=n.i.gc();)t=P(gO(n),123),M(e.e,new ahe(t));return e.e}function k3e(e){var t,n;if(!e.a)for(e.a=kv(Gg(P(e.f,27)).i),n=new Lu(Gg(P(e.f,27)));n.e!=n.i.gc();)t=P(gO(n),27),M(e.a,new sd(e,t));return e.a}function _k(e){var t;if(!e.C&&(e.D!=null||e.B!=null)){if(t=qht(e),t)e.hl(t);else try{e.hl(null)}catch(e){if(e=ew(e),!j(e,63))throw E(e)}}return e.C}function A3e(e){switch(e.q.g){case 5:h8e(e,(nP(),Z8)),h8e(e,m5);break;case 4:Lmt(e,(nP(),Z8)),Lmt(e,m5);break;default:Het(e,(nP(),Z8)),Het(e,m5)}}function j3e(e){switch(e.q.g){case 5:g8e(e,(nP(),X8)),g8e(e,g5);break;case 4:Rmt(e,(nP(),X8)),Rmt(e,g5);break;default:Uet(e,(nP(),X8)),Uet(e,g5)}}function vk(e,t){var n,i,a=new Fa;for(i=e.Kc();i.Ob();)n=P(i.Pb(),36),kM(n,a.a,0),a.a+=n.f.a+t,a.b=r.Math.max(a.b,n.f.b);return a.b>0&&(a.b+=t),a}function yk(e,t){var n,i,a=new Fa;for(i=e.Kc();i.Ob();)n=P(i.Pb(),36),kM(n,0,a.b),a.b+=n.f.b+t,a.a=r.Math.max(a.a,n.f.a);return a.a>0&&(a.a+=t),a}function M3e(e){var t,n,i=AP;for(n=new w(e.a);n.a>16==6?e.Cb.Th(e,5,J5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||e.ii()),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function F3e(e){Xg();var t=e.e;if(t&&t.stack){var n=t.stack,r=t+` +`;return n.substring(0,r.length)==r&&(n=n.substring(r.length)),n.split(` +`)}return[]}function I3e(e){var t=(pJe(),UTt);return t[e>>>28]|t[e>>24&15]<<4|t[e>>20&15]<<8|t[e>>16&15]<<12|t[e>>12&15]<<16|t[e>>8&15]<<20|t[e>>4&15]<<24|t[e&15]<<28}function L3e(e){var t,n,i;e.b==e.c&&(i=e.a.length,n=dZe(r.Math.max(8,i))<<1,e.b==0?Wr(e.a,n):(t=Yd(e.a,n),eYe(e,t,i),e.a=t,e.b=0),e.c=i)}function R3e(e,t){var n=e.b;return n.pf((vP(),F6))?n.ag()==(nP(),g5)?-n.Mf().a-D(N(n.of(F6))):t+D(N(n.of(F6))):n.ag()==(nP(),g5)?-n.Mf().a:t}function xk(e){var t;return e.b.c.length!=0&&P(Ep(e.b,0),72).a?P(Ep(e.b,0),72).a:(t=xg(e),t??``+(e.c?Ab(e.c.a,e,0):-1))}function Sk(e){var t;return e.f.c.length!=0&&P(Ep(e.f,0),72).a?P(Ep(e.f,0),72).a:(t=xg(e),t??``+(e.i?Ab(e.i.j,e,0):-1))}function z3e(e,t){var n,r;if(t<0||t>=e.gc())return null;for(n=t;n0?e.c:0),a=r.Math.max(a,t.d),++i;e.e=o,e.b=a}function H3e(e){var t,n;if(!e.b)for(e.b=kv(P(e.f,123).kh().i),n=new Lu(P(e.f,123).kh());n.e!=n.i.gc();)t=P(gO(n),135),M(e.b,new Di(t));return e.b}function U3e(e,t){var n,r,i;if(t.dc())return Nd(),Nd(),_7;for(n=new PDe(e,t.gc()),i=new Lu(e);i.e!=i.i.gc();)r=gO(i),t.Hc(r)&&tb(n,r);return n}function W3e(e,t,n,r){return t==0?r?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),e.o):(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),Jy(e.o)):jO(e,t,n,r)}function Ck(e){var t,n;if(e.rb)for(t=0,n=e.rb.i;t>22),i+=r>>22,i<0)?!1:(e.l=n&QF,e.m=r&QF,e.h=i&$F,!0)}function Tk(e,t,n,r,i,a,o){var s,c;return!(t.Te()&&(c=e.a.Ne(n,r),c<0||!i&&c==0)||t.Ue()&&(s=e.a.Ne(n,a),s>0||!o&&s==0))}function J3e(e,t){if(Fw(),e.j.g-t.j.g!=0)return 0;switch(e.j.g){case 2:return kE(t,yX)-kE(e,yX);case 4:return kE(e,vX)-kE(t,vX)}return 0}function Y3e(e){switch(e.g){case 0:return yZ;case 1:return bZ;case 2:return xZ;case 3:return SZ;case 4:return CZ;case 5:return wZ;default:return null}}function Ek(e,t,n){var r=(i=new li,aT(i,t),GS(i,n),tb((!e.c&&(e.c=new F(P7,e,12,10)),e.c),i),i),i;return Zx(r,0),Qx(r,1),RT(r,!0),FT(r,!0),r}function Dk(e,t){var n,r;if(t>=e.i)throw E(new wl(t,e.i));return++e.j,n=e.g[t],r=e.i-t-1,r>0&&tN(e.g,t+1,e.g,t,r),Sh(e.g,--e.i,null),e.Qi(t,n),e.Ni(),n}function X3e(e,t){var n,r;return e.Db>>16==17?e.Cb.Th(e,21,D7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||e.ii()),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function Z3e(e){var t,n,r,i;for(Vg(),hu(e.c,e.a),i=new w(e.c);i.an.a.c.length))throw E(new Fi(`index must be >= 0 and <= layer node count`));e.c&&Db(e.c.a,e),e.c=n,n&&Jp(n.a,t,e)}function d6e(e,t){var n,r,i;for(r=new pm(Vu(EE(e).a.Kc(),new d));Cj(r);)return n=P(by(r),18),i=P(t.Kb(n),10),new pn(ph(i.n.b+i.o.b/2));return fi(),fi(),GW}function f6e(e,t){this.c=new Dr,this.a=e,this.b=t,this.d=P(K(e,(Y(),o$)),312),this.e=A(K(e,(mP(),Jjt)))===A((wb(),EZ))?new Qge:new Zge}function jk(e,t){var n,r=null;return e.pf((vP(),K6))&&(n=P(e.of(K6),96),n.pf(t)&&(r=n.of(t))),r==null&&e.Tf()&&(r=e.Tf().of(t)),r??=hO(t),r}function Mk(e,t){var n=e.fd(t),r;try{return r=n.Pb(),n.Qb(),r}catch(e){throw e=ew(e),j(e,112)?E(new Mi(`Can't remove element `+t)):E(e)}}function p6e(e,t){var n,r=new uo,i=new xZe(r.q.getFullYear()-VF,r.q.getMonth(),r.q.getDate());if(n=zft(e,t,i),n==0||n0?t:0),++n;return new k(i,a)}function b6e(e,t){var n,r;return e.Db>>16==6?e.Cb.Th(e,6,U5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),X5)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function x6e(e,t){var n,r;return e.Db>>16==7?e.Cb.Th(e,1,B5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),lVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function S6e(e,t){var n,r;return e.Db>>16==9?e.Cb.Th(e,9,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),dVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function C6e(e,t){var n,r;return e.Db>>16==5?e.Cb.Th(e,9,k7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),W7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function w6e(e,t){var n,r;return e.Db>>16==7?e.Cb.Th(e,6,J5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),X7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function T6e(e,t){var n,r;return e.Db>>16==3?e.Cb.Th(e,0,G5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),B7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function E6e(){this.a=new Pse,this.g=new XO,this.j=new XO,this.b=new Dr,this.d=new XO,this.i=new XO,this.k=new Dr,this.c=new Dr,this.e=new Dr,this.f=new Dr}function D6e(e,t,n){var r,i,a;for(n<0&&(n=0),a=e.i,i=n;igI)return Pk(e,r);if(r==e)return!0}}return!1}function k6e(e){switch(nd(),e.q.g){case 5:fnt(e,(nP(),Z8)),fnt(e,m5);break;case 4:dat(e,(nP(),Z8)),dat(e,m5);break;default:Rgt(e,(nP(),Z8)),Rgt(e,m5)}}function A6e(e){switch(nd(),e.q.g){case 5:drt(e,(nP(),X8)),drt(e,g5);break;case 4:Y2e(e,(nP(),X8)),Y2e(e,g5);break;default:zgt(e,(nP(),X8)),zgt(e,g5)}}function j6e(e){var t=P(K(e,(XM(),HDt)),17),n;t?(n=t.a,n==0?W(e,(jS(),aJ),new YE):W(e,(jS(),aJ),new sy(n))):W(e,(jS(),aJ),new sy(1))}function M6e(e,t){var n=e.i;switch(t.g){case 1:return-(e.n.b+e.o.b);case 2:return e.n.a-n.o.a;case 3:return e.n.b-n.o.b;case 4:return-(e.n.a+e.o.a)}return 0}function N6e(e,t){switch(e.g){case 0:return t==(XE(),h$)?mX:hX;case 1:return t==(XE(),h$)?mX:pX;case 2:return t==(XE(),h$)?pX:hX;default:return pX}}function Fk(e,t){var n,i,a;for(Db(e.a,t),e.e-=t.r+(e.a.c.length==0?0:e.c),a=hxt,i=new w(e.a);i.a>16==3?e.Cb.Th(e,12,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),sVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function F6e(e,t){var n,r;return e.Db>>16==11?e.Cb.Th(e,10,$5,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(lP(),uVt)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function I6e(e,t){var n,r;return e.Db>>16==10?e.Cb.Th(e,11,D7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),Y7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function L6e(e,t){var n,r;return e.Db>>16==10?e.Cb.Th(e,12,M7,t):(r=qO(P(_x((n=P(NC(e,16),29),n||(CP(),Z7)),e.Db>>16),19)),e.Cb.Th(e,r.n,r.f,t))}function Ik(e){var t;return!(e.Bb&1)&&e.r&&e.r.Vh()&&(t=P(e.r,54),e.r=P(pT(e,t),142),e.r!=t&&e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,9,8,t,e.r))),e.r}function Lk(e,t,n){var i=U(O(Z9,1),hI,28,15,[j7e(e,(Ix(),XK),t,n),j7e(e,ZK,t,n),j7e(e,QK,t,n)]);return e.f&&(i[0]=r.Math.max(i[0],i[2]),i[2]=i[0]),i}function R6e(e,t){var n,r,i=X2e(e,t);if(i.c.length!=0)for(hu(i,new zte),n=i.c.length,r=0;r>19,l=t.h>>19;return c==l?(i=e.h,s=t.h,i==s?(r=e.m,o=t.m,r==o?(n=e.l,a=t.l,n-a):r-o):i-s):l-c}function Rk(){Rk=C,RK=(vM(),GK),LK=new Tl(QI,RK),IK=(dx(),kK),FK=new Tl($I,IK),PK=(fO(),EK),NK=new Tl(eL,PK),MK=new Tl(tL,(rd(),!0))}function zk(e,t,n){var r=t*n,i;j(e.g,154)?(i=zv(e),i.f.d?i.f.a||(e.d.a+=r+fL):(e.d.d-=r+fL,e.d.a+=r+fL)):j(e.g,10)&&(e.d.d-=r,e.d.a+=2*r)}function G6e(e,t,n){var i,a=e[n.g],o,s,c;for(c=new w(t.d);c.a0?e.b:0),++n;t.b=i,t.e=a}function q6e(e){var t,n,r=e.b;if(mbe(e.i,r.length)){for(n=r.length*2,e.b=V($W,fF,303,n,0,1),e.c=V($W,fF,303,n,0,1),e.f=n-1,e.i=0,t=e.a;t;t=t.c)nj(e,t,t);++e.g}}function J6e(e,t,n,r){var i,a,o,s;for(i=0;is&&(c=s/i),a>o&&(l=o/a),ku(e,r.Math.min(c,l)),e}function X6e(){_N();var e,t;try{if(t=P(U8e((qo(),N7),eU),2113),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new kse}function Z6e(){_N();var e,t;try{if(t=P(U8e((qo(),N7),iW),2040),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new ace}function Q6e(){EGe();var e,t;try{if(t=P(U8e((qo(),N7),bW),2122),t)return t}catch(t){if(t=ew(t),j(t,103))e=t,rh((fu(),e));else throw E(t)}return new Qce}function $6e(e,t,n){var r,i=e.e;return e.e=t,e.Db&4&&!(e.Db&1)&&(r=new Sm(e,1,4,i,t),n?n.nj(r):n=r),i!=t&&(n=t?JN(e,Rj(e,t),n):JN(e,e.a,n)),n}function e8e(){uo.call(this),this.e=-1,this.a=!1,this.p=xF,this.k=-1,this.c=-1,this.b=-1,this.g=!1,this.f=-1,this.j=-1,this.n=-1,this.i=-1,this.d=-1,this.o=xF}function t8e(e,t){var n,r=e.b.d.d,i;if(e.a||(r+=e.b.d.a),i=t.b.d.d,t.a||(i+=t.b.d.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function n8e(e,t){var n,r=e.b.b.d,i;if(e.a||(r+=e.b.b.a),i=t.b.b.d,t.a||(i+=t.b.b.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function r8e(e,t){var n,r=e.b.g.d,i;if(e.a||(r+=e.b.g.a),i=t.b.g.d,t.a||(i+=t.b.g.a),n=aE(r,i),n==0){if(!e.a&&t.a)return-1;if(!t.a&&e.a)return 1}return n}function i8e(){i8e=C,oOt=tm(vp(vp(vp(new Zh,(vA(),xJ),(yP(),NY)),xJ,LY),SJ,WY),SJ,xY),cOt=vp(vp(new Zh,xJ,dY),xJ,SY),sOt=tm(new Zh,SJ,wY)}function a8e(e){var t=P(K(e,(Y(),bQ)),85),n,r,i,a=e.n;for(r=t.Cc().Kc();r.Ob();)n=P(r.Pb(),314),i=n.i,i.c+=a.a,i.d+=a.b,n.c?gct(n):_ct(n);W(e,bQ,null)}function o8e(e,t,n){var r,i=e.b;switch(r=i.d,t.g){case 1:return-r.d-n;case 2:return i.o.a+r.c+n;case 3:return i.o.b+r.a+n;case 4:return-r.b-n;default:return-1}}function s8e(e,t,n){var r,i;for(n.Ug(`Interactive node placement`,1),e.a=P(K(t,(Y(),o$)),312),i=new w(t.b);i.a0&&(o=(a&AP)%e.d.length,i=Knt(e,o,a,t),i)?(s=i.nd(n),s):(r=e.ck(a,t,n),e.c.Fc(r),null)}function C8e(e,t){var n,r,i,a;switch(AT(e,t).Kl()){case 3:case 2:for(n=bN(t),i=0,a=n.i;i=0;i--)if(ff(e[i].d,t)||ff(e[i].d,n)){e.length>=i+1&&e.splice(0,i+1);break}return e}function Wk(e,t){var n;return Il(e)&&Il(t)&&(n=e/t,iI0&&(e.b+=2,e.a+=i):(e.b+=1,e.a+=r.Math.min(i,a))}function F8e(e){var t=P(K(P(SO(e.b,0),40),(rN(),fFt)),107);W(e,(tP(),H2),new k(0,0)),but(new zy,e,t.b+t.c-D(N(K(e,K2))),t.d+t.a-D(N(K(e,q2))))}function I8e(e,t){var n,r=!1;if(rl(t)&&(r=!0,Dh(e,new mh(kd(t)))),r||j(t,242)&&(r=!0,Dh(e,(n=ZOe(P(t,242)),new Cn(n)))),!r)throw E(new Ni(pCt))}function L8e(e,t,n,r){var i=new Hb(e.e,1,10,(o=t.c,j(o,90)?P(o,29):(CP(),J7)),(a=n.c,j(a,90)?P(a,29):(CP(),J7)),NO(e,t),!1),a,o;return r?r.nj(i):r=i,r}function R8e(e){var t,n;switch(P(K(Bh(e),(mP(),Bjt)),429).g){case 0:return t=e.n,n=e.o,new k(t.a+n.a/2,t.b+n.b/2);case 1:return new Vl(e.n);default:return null}}function qk(){qk=C,MZ=new Us(wR,0),jZ=new Us(`LEFTUP`,1),PZ=new Us(`RIGHTUP`,2),AZ=new Us(`LEFTDOWN`,3),NZ=new Us(`RIGHTDOWN`,4),kZ=new Us(`BALANCED`,5)}function z8e(e,t,n){var r=aE(e.a[t.p],e.a[n.p]),i,a;if(r==0){if(i=P(K(t,(Y(),PQ)),15),a=P(K(n,PQ),15),i.Hc(n))return-1;if(a.Hc(t))return 1}return r}function B8e(e){switch(e.g){case 1:return new soe;case 2:return new coe;case 3:return new ooe;case 0:return null;default:throw E(new Fi(ZV+(e.f==null?``+e.g:e.f)))}}function V8e(e,t,n){switch(t){case 1:!e.n&&(e.n=new F(Q5,e,1,7)),RN(e.n),!e.n&&(e.n=new F(Q5,e,1,7)),th(e.n,P(n,16));return;case 2:CS(e,kd(n));return}qZe(e,t,n)}function H8e(e,t,n){switch(t){case 3:Ux(e,D(N(n)));return;case 4:Wx(e,D(N(n)));return;case 5:Gx(e,D(N(n)));return;case 6:Kx(e,D(N(n)));return}V8e(e,t,n)}function Jk(e,t,n){var r,i,a=(r=new li,r);i=fA(a,t,null),i&&i.oj(),GS(a,n),tb((!e.c&&(e.c=new F(P7,e,12,10)),e.c),a),Zx(a,0),Qx(a,1),RT(a,!0),FT(a,!0)}function U8e(e,t){var n=as(e.i,t),r,i;return j(n,241)?(i=P(n,241),i.zi(),i.wi()):j(n,507)?(r=P(n,2037),i=r.b,i):null}function W8e(e,t,n,r){var i,a;return ph(t),ph(n),a=P(_f(e.d,t),17),oKe(!!a,`Row %s not in %s`,t,e.e),i=P(_f(e.b,n),17),oKe(!!i,`Column %s not in %s`,n,e.c),JXe(e,a.a,i.a,r)}function G8e(e,t,n,r,i,a,o){var s,c,l,u=i[a],d;if(l=a==o-1,s=l?r:0,d=b3e(s,u),r!=10&&U(O(e,o-a),t[a],n[a],s,d),!l)for(++a,c=0;c1||s==-1?(a=P(c,15),i.Wb(r0e(e,a))):i.Wb(WM(e,P(c,58)))))}function e5e(e,t,n,r){Bye();var i=xTt;STt=r;function a(){for(var e=0;e0)return!1;return!0}function r5e(e){var t,n,r,i,a;for(r=new EC(new Fn(e.b).a);r.b;)n=MS(r),t=P(n.ld(),10),a=P(P(n.md(),42).a,10),i=P(P(n.md(),42).b,8),$d(Cl(t.n),$d(xu(a.n),i))}function i5e(e){switch(P(K(e.b,(mP(),Njt)),387).g){case 1:To(gg(ox(new Mp(null,new cv(e.d,16)),new jre),new Mre),new Nre);break;case 2:elt(e);break;case 0:Dtt(e)}}function a5e(e,t,n){var r=n,i,a;for(!r&&(r=new di),r.Ug(`Layout`,e.a.c.length),a=new w(e.a);a.aAV)return n;i>-1e-6&&++n}return n}function u5e(e,t){var n;t==e.b?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t)):(n=null,e.b&&(n=m_(e.b,e,-4,n)),t&&(n=EO(t,e,-4,n)),n=m$e(e,t,n),n&&n.oj())}function d5e(e,t){var n;t==e.f?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,0,t,t)):(n=null,e.f&&(n=m_(e.f,e,-1,n)),t&&(n=EO(t,e,-1,n)),n=p$e(e,t,n),n&&n.oj())}function f5e(e,t,n,r){var i,a,o,s;return Gl(e.e)&&(i=t.Lk(),s=t.md(),a=n.md(),o=s_(e,1,i,s,a,i.Jk()?pN(e,i,a,j(i,102)&&(P(i,19).Bb&pI)!=0):-1,!0),r?r.nj(o):r=o),r}function p5e(e){var t,n,r;if(e==null)return null;if(n=P(e,15),n.dc())return``;for(r=new $i,t=n.Kc();t.Ob();)pl(r,(UN(),kd(t.Pb()))),r.a+=` `;return kl(r,r.a.length-1)}function m5e(e){var t,n,r;if(e==null)return null;if(n=P(e,15),n.dc())return``;for(r=new $i,t=n.Kc();t.Ob();)pl(r,(UN(),kd(t.Pb()))),r.a+=` `;return kl(r,r.a.length-1)}function h5e(e,t,n){var r=e.c[t.c.p][t.p],i=e.c[n.c.p][n.p];return r.a!=null&&i.a!=null?dm(r.a,i.a):r.a==null?i.a==null?0:1:-1}function g5e(e,t,n){return n.Ug(`Tree layout`,1),cg(e.b),Um(e.b,(Ok(),N2),N2),Um(e.b,P2,P2),Um(e.b,F2,F2),Um(e.b,I2,I2),e.a=BN(e.b,t),a5e(e,t,n.eh(1)),n.Vg(),t}function _5e(e,t){var n,r,i,a,o,s;if(t)for(a=t.a.length,n=new hm(a),s=(n.b-n.a)*n.c<0?($o(),G9):new Ru(n);s.Ob();)o=P(s.Pb(),17),i=Pv(t,o.a),r=new hhe(e),XFe(r.a,i)}function v5e(e,t){var n,r,i,a,o,s;if(t)for(a=t.a.length,n=new hm(a),s=(n.b-n.a)*n.c<0?($o(),G9):new Ru(n);s.Ob();)o=P(s.Pb(),17),i=Pv(t,o.a),r=new ohe(e),YFe(r.a,i)}function y5e(e){var t;if(e!=null&&e.length>0&&mg(e,e.length-1)==33)try{return t=Vit(p_(e,0,e.length-1)),t.e==null}catch(e){if(e=ew(e),!j(e,33))throw E(e)}return!1}function b5e(e,t,n){var r=cE(Bh(t)),i=new jA;switch(G_(i,t),n.g){case 1:tj(i,YT(GE(r)));break;case 2:tj(i,GE(r))}return W(i,(mP(),Z1),N(K(e,Z1))),i}function x5e(e){var t=P(by(new pm(Vu(DE(e.a).a.Kc(),new d))),18),n=P(by(new pm(Vu(OE(e.a).a.Kc(),new d))),18);return ki(Od(K(t,(Y(),r$))))||ki(Od(K(n,r$)))}function tA(){tA=C,TX=new Ns(`ONE_SIDE`,0),DX=new Ns(`TWO_SIDES_CORNER`,1),OX=new Ns(`TWO_SIDES_OPPOSING`,2),EX=new Ns(`THREE_SIDES`,3),wX=new Ns(`FOUR_SIDES`,4)}function S5e(e,t){var n,r,i,a=new T;for(i=0,r=t.Kc();r.Ob();){for(n=G(P(r.Pb(),17).a+i);n.a=e.f)break;Mr(a.c,n)}return a}function C5e(e,t){var n,r,i,a,o;for(a=new w(t.a);a.a0&&t6e(this,this.c-1,(nP(),X8)),this.c0&&e[0].length>0&&(this.c=ki(Od(K(Bh(e[0][0]),(Y(),FQ))))),this.a=V(ENt,X,2117,e.length,0,2),this.b=V(DNt,X,2118,e.length,0,2),this.d=new YQe}function I5e(e){return e.c.length==0?!1:(ov(0,e.c.length),P(e.c[0],18)).c.i.k==(DA(),qJ)||hy(gg(new Mp(null,new cv(e,16)),new vie),new yie)}function L5e(e,t){var n,i,a,o,s,c=sM(t),l;for(o=t.f,l=t.g,s=r.Math.sqrt(o*o+l*l),a=0,i=new w(c);i.a=0?(n=Wk(e,rI),r=bD(e,rI)):(t=um(e,1),n=Wk(t,5e8),r=bD(t,5e8),r=yE(cm(r,1),uv(e,1))),dv(cm(r,32),uv(n,_I))}function $5e(e,t,n){var r=(jd(t.b!=0),P(Ox(t,t.a.a),8)),i;switch(n.g){case 0:r.b=0;break;case 2:r.b=e.f;break;case 3:r.a=0;break;default:r.a=e.g}return i=dO(t,0),Zm(i,r),t}function e7e(e,t,n,r){var i,a,o,s,c=e.b;switch(a=t.d,o=a.j,s=tO(o,c.d[o.g],n),i=$d(xu(a.n),a.a),a.j.g){case 1:case 3:s.a+=i.a;break;case 2:case 4:s.b+=i.b}iy(r,s,r.c.b,r.c)}function t7e(e,t,n){var r,i,a,o=Ab(e.e,t,0);for(a=new Jge,a.b=n,r=new bv(e.e,o);r.b1;t>>=1)t&1&&(r=Uv(r,n)),n=n.d==1?Uv(n,n):new c2e(Zut(n.a,n.d,V(q9,HF,28,n.d<<1,15,1)));return r=Uv(r,n),r}function s7e(){s7e=C;var e,t,n,r;for(cK=V(Z9,hI,28,25,15,1),lK=V(Z9,hI,28,33,15,1),r=152587890625e-16,t=32;t>=0;t--)lK[t]=r,r*=.5;for(n=1,e=24;e>=0;e--)cK[e]=n,n*=.5}function c7e(e){var t,n;if(ki(Od(J(e,(mP(),k1))))){for(n=new pm(Vu(Ij(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),74),uj(t)&&ki(Od(J(t,A1))))return!0}return!1}function l7e(e,t){var n,r,i;Lm(e.f,t)&&(t.b=e,r=t.c,Ab(e.j,r,0)!=-1||M(e.j,r),i=t.d,Ab(e.j,i,0)!=-1||M(e.j,i),n=t.a.b,n.c.length!=0&&(!e.i&&(e.i=new T2e(e)),iXe(e.i,n)))}function u7e(e){var t,n=e.c.d,r=n.j,i=e.d.d,a=i.j;return r==a?n.p=0&&ff(e.substr(t,3),`GMT`)||t>=0&&ff(e.substr(t,3),`UTC`))&&(n[0]=t+3),zut(e,n,r)}function f7e(e,t){var n,r,i,a=e.g.a,o=e.g.b;for(r=new w(e.d);r.an;a--)e[a]|=t[a-n-1]>>>o,e[a-1]=t[a-n-1]<0&&tN(e.g,t,e.g,t+r,s),o=n.Kc(),e.i+=r,i=0;i>4&15,a=e[r]&15,o[i++]=hVt[n],o[i++]=hVt[a];return ND(o,0,o.length)}function mA(e){var t,n;return e>=pI?(t=mI+(e-pI>>10&1023)&OF,n=56320+(e-pI&1023)&OF,String.fromCharCode(t)+(``+String.fromCharCode(n))):String.fromCharCode(e&OF)}function D7e(e,t){Rd();var n,r,i=P(P(Dy(e.r,t),21),87),a;return i.gc()>=2&&(r=P(i.Kc().Pb(),117),n=e.u.Hc((rj(),W8)),a=e.u.Hc(J8),!r.a&&!n&&(i.gc()==2||a))}function O7e(e,t,n,r,i){for(var a=Gst(e,t,n,r,i),o,s=!1;!a;)Oj(e,i,!0),s=!0,a=Gst(e,t,n,r,i);s&&Oj(e,i,!1),o=uw(i),o.c.length!=0&&(e.d&&e.d.Gg(o),O7e(e,i,n,r,o))}function hA(){hA=C,m8=new Pc(wR,0),cBt=new Pc(`DIRECTED`,1),uBt=new Pc(`UNDIRECTED`,2),oBt=new Pc(`ASSOCIATION`,3),lBt=new Pc(`GENERALIZATION`,4),sBt=new Pc(`DEPENDENCY`,5)}function k7e(e,t){var n;if(!E_(e))throw E(new Ii(zSt));switch(n=E_(e),t.g){case 1:return-(e.j+e.f);case 2:return e.i-n.g;case 3:return e.j-n.f;case 4:return-(e.i+e.g)}return 0}function A7e(e,t,n){var r=t.Lk(),i,a=t.md();return i=r.Jk()?s_(e,4,r,a,null,pN(e,r,a,j(r,102)&&(P(r,19).Bb&pI)!=0),!0):s_(e,r.tk()?2:1,r,a,r.ik(),-1,!0),n?n.nj(i):n=i,n}function gA(e,t){var n,r;for(Gh(t),r=e.b.c.length,M(e.b,t);r>0;){if(n=r,r=(r-1)/2|0,e.a.Ne(Ep(e.b,r),t)<=0)return uy(e.b,n,t),!0;uy(e.b,n,Ep(e.b,r))}return uy(e.b,r,t),!0}function j7e(e,t,n,i){var a=0,o;if(n)a=iT(e.a[n.g][t.g],i);else for(o=0;o=s)}function N7e(e){switch(e.g){case 0:return new Soe;case 1:return new Coe;default:throw E(new Fi(`No implementation is available for the width approximator `+(e.f==null?``+e.g:e.f)))}}function P7e(e,t,n,r){var i=!1;if(rl(r)&&(i=!0,sp(t,n,kd(r))),i||il(r)&&(i=!0,P7e(e,t,n,r)),i||j(r,242)&&(i=!0,qg(t,n,P(r,242))),!i)throw E(new Ni(pCt))}function F7e(e,t){var n=t.qi(e.a),r,i;if(n&&(i=_D((!n.b&&(n.b=new Td((CP(),$7),o9,n)),n.b),ZU),i!=null)){for(r=1;r<(UA(),hHt).length;++r)if(ff(hHt[r],i))return r}return 0}function I7e(e,t){var n=t.qi(e.a),r,i;if(n&&(i=_D((!n.b&&(n.b=new Td((CP(),$7),o9,n)),n.b),ZU),i!=null)){for(r=1;r<(UA(),gHt).length;++r)if(ff(gHt[r],i))return r}return 0}function L7e(e,t){var n,r,i,a;if(Gh(t),a=e.a.gc(),a0);a.a[i]!=n;)a=a.a[i],i=+(e.a.Ne(n.d,a.d)>0);a.a[i]=r,r.b=n.b,r.a[0]=n.a[0],r.a[1]=n.a[1],n.a[0]=null,n.a[1]=null}function H7e(e){var t=new T,n=V(J9,aL,28,e.a.c.length,16,1),r,i;for(CPe(n,n.length),i=new w(e.a);i.a0&&Eut((ov(0,n.c.length),P(n.c[0],30)),e),n.c.length>1&&Eut(P(Ep(n,n.c.length-1),30),e),t.Vg()}function G7e(e){rj();var t=Zp(G8,U(O(Y8,1),Z,279,0,[q8])),n;return!(BC(b_(t,e))>1||(n=Zp(W8,U(O(Y8,1),Z,279,0,[U8,J8])),BC(b_(n,e))>1))}function K7e(e,t){j(v_((qo(),N7),e),507)?H_(N7,e,new YSe(this,t)):H_(N7,e,this),EA(this,t),t==(Ra(),R7)?(this.wb=P(this,2038),P(t,2040)):this.wb=(vh(),z7)}function q7e(e){var t,n,r;if(e==null)return null;for(t=null,n=0;n=DF?`error`:r>=900?`warn`:r>=800?`info`:`log`),aFe(n,e.a),e.b&&Not(t,n,e.b,`Exception: `,!0))}function K(e,t){var n;return!e.q&&(e.q=new Dr),xh(e.q,t)??(n=t.Sg(),j(n,4)&&(n==null?(!e.q&&(e.q=new Dr),My(e.q,t)):(!e.q&&(e.q=new Dr),Qh(e.q,t,n))),n)}function vA(){vA=C,vJ=new ws(`P1_CYCLE_BREAKING`,0),yJ=new ws(`P2_LAYERING`,1),bJ=new ws(`P3_NODE_ORDERING`,2),xJ=new ws(`P4_NODE_PLACEMENT`,3),SJ=new ws(`P5_EDGE_ROUTING`,4)}function X7e(e,t){mx();var n;if(e.c==t.c){if(e.b==t.b||pYe(e.b,t.b)){if(n=TCe(e.b)?1:-1,e.a&&!t.a)return n;if(!e.a&&t.a)return-n}return _u(e.b.g,t.b.g)}return aE(e.c,t.c)}function Z7e(e,t){var n,r,i;if(n9e(e,t))return!0;for(r=new w(t);r.a=i||t<0)throw E(new Mi(yU+t+bU+i));if(n>=i||n<0)throw E(new Mi(xU+n+bU+i));return r=t==n?e.xj(n):(a=e.Cj(n),e.qj(t,a),a),r}function t9e(e){var t,n,r=e;if(e)for(t=0,n=e.Eh();n;n=n.Eh()){if(++t>gI)return t9e(n);if(r=n,n==e)throw E(new Ii(`There is a cycle in the containment hierarchy of `+e))}return r}function CA(e){var t,n,r=new UC(PP,`[`,`]`);for(n=e.Kc();n.Ob();)t=n.Pb(),jy(r,A(t)===A(e)?`(this Collection)`:t==null?IP:PE(t));return r.a?r.e.length==0?r.a.a:r.a.a+(``+r.e):r.c}function n9e(e,t){var n,r=!1;if(t.gc()<2)return!1;for(n=0;n1&&(e.j.b+=e.e)):(e.j.a+=n.a,e.j.b=r.Math.max(e.j.b,n.b),e.d.c.length>1&&(e.j.a+=e.e))}function wA(){wA=C,ZOt=U(O(_5,1),TR,64,0,[(nP(),Z8),X8,m5]),XOt=U(O(_5,1),TR,64,0,[X8,m5,g5]),QOt=U(O(_5,1),TR,64,0,[m5,g5,Z8]),$Ot=U(O(_5,1),TR,64,0,[g5,Z8,X8])}function o9e(e,t,n,r){var i,a,o=e.c.d,s=e.d.d,c,l,u;if(o.j!=s.j)for(u=e.b,i=o.j,c=null;i!=s.j;)c=t==0?XT(i):JT(i),a=tO(i,u.d[i.g],n),l=tO(c,u.d[c.g],n),up(r,$d(a,l)),i=c}function s9e(e,t,n,r){var i,a,o=a6e(e.a,t,n),s=P(o.a,17).a,c;return a=P(o.b,17).a,r&&(c=P(K(t,(Y(),QQ)),10),i=P(K(n,QQ),10),c&&i&&(XVe(e.b,c,i),s+=e.b.i,a+=e.b.e)),s>a}function c9e(e){var t,n,r,i,a,o,s,c,l;for(this.a=m4e(e),this.b=new T,n=e,r=0,i=n.length;rLd(e.d).c?(e.i+=e.g.c,SD(e.d)):Ld(e.d).c>Ld(e.g).c?(e.e+=e.d.c,SD(e.g)):(e.i+=aNe(e.g),e.e+=aNe(e.d),SD(e.g),SD(e.d))}function p9e(e,t,n){var r,i,a=t.q,o=t.r;for(new nv((Wy(),k2),t,a,1),new nv(k2,a,o,1),i=new w(n);i.ac&&(l=c/i),a>o&&(u=o/a),s=r.Math.min(l,u),e.a+=s*(t.a-e.a),e.b+=s*(t.b-e.b)}function y9e(e,t,n,r,i){var a,o=!1;for(a=P(Ep(n.b,0),27);xft(e,t,a,r,i)&&(o=!0,X8e(n,a),n.b.c.length!=0);)a=P(Ep(n.b,0),27);return n.b.c.length==0&&Fk(n.j,n),o&&hk(t.q),o}function b9e(e,t){fM();var n,r,i,a;if(t.b<2)return!1;for(a=dO(t,0),n=P(Lv(a),8),r=n;a.b!=a.d.c;){if(i=P(Lv(a),8),Kj(e,r,i))return!0;r=i}return!!Kj(e,r,n)}function x9e(e,t,n,r){var i,a;return n==0?(!e.o&&(e.o=new lb((lP(),Z5),n7,e,0)),gf(e.o,t,r)):(a=P(_x((i=P(NC(e,16),29),i||e.ii()),n),69),a.wk().Ak(e,WD(e),n-bh(e.ii()),t,r))}function EA(e,t){var n;t==e.sb?e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,4,t,t)):(n=null,e.sb&&(n=P(e.sb,54).Th(e,1,K5,n)),t&&(n=P(t,54).Rh(e,1,K5,n)),n=OT(e,t,n),n&&n.oj())}function S9e(e,t){var n,r,i,a;if(t)i=nS(t,`x`),n=new fhe(e),Hx(n.a,(Gh(i),i)),a=nS(t,`y`),r=new phe(e),Jx(r.a,(Gh(a),a));else throw E(new Vi(`All edge sections need an end point.`))}function C9e(e,t){var n,r,i,a;if(t)i=nS(t,`x`),n=new lhe(e),qx(n.a,(Gh(i),i)),a=nS(t,`y`),r=new uhe(e),Yx(r.a,(Gh(a),a));else throw E(new Vi(`All edge sections need a start point.`))}function w9e(e,t){var n,r,i,a,o,s,c;for(r=aQe(e),a=0,s=r.length;a>22-t,i=e.h<>22-t):t<44?(n=0,r=e.l<>44-t):(n=0,r=0,i=e.l<e)throw E(new Fi(`k must be smaller than n`));return t==0||t==e?1:e==0?0:E8e(e)/(E8e(t)*E8e(e-t))}function N9e(e,t){for(var n=new nu(e),r,i,a;n.g==null&&!n.c?lRe(n):n.g==null||n.i!=0&&P(n.g[n.i-1],51).Ob();)if(a=P(Pj(n),58),j(a,167))for(r=P(a,167),i=0;i>4],t[n*2+1]=N9[a&15];return ND(t,0,t.length)}function K9e(e){eg();var t,n;switch(e.c.length){case 0:return ATt;case 1:return t=P(Jtt(new w(e)),44),_Me(t.ld(),t.md());default:return n=P(rO(e,V(YW,oF,44,e.c.length,0,1)),173),new _i(n)}}function q9e(e){var t=new Iu,n=new Iu,r,i,a,o;for(Rv(t,e),Rv(n,e);n.b!=n.c;)for(i=P(Fm(n),36),o=new w(i.a);o.a0&&MM(e,n,t),i):hrt(e,t,n):r}function PA(){PA=C,mIt=(vP(),V6),vIt=J6,cIt=w6,lIt=E6,uIt=D6,sIt=C6,dIt=k6,pIt=z6,k4=(Ylt(),GFt),A4=KFt,hIt=QFt,N4=tIt,gIt=$Ft,_It=eIt,fIt=JFt,j4=XFt,M4=ZFt,P4=nIt,yIt=iIt,oIt=WFt}function X9e(e,t){var n,r,i,a,o;if(e.e<=t||_ze(e,e.g,t))return e.g;for(a=e.r,r=e.g,o=e.r,i=(a-r)/2+r;r+11&&(e.e.b+=e.a)):(e.e.a+=n.a,e.e.b=r.Math.max(e.e.b,n.b),e.d.c.length>1&&(e.e.a+=e.a))}function net(e){var t,n,r,i=e.i;switch(t=i.b,r=i.j,n=i.g,i.a.g){case 0:n.a=(e.g.b.o.a-r.a)/2;break;case 1:n.a=t.d.n.a+t.d.a.a;break;case 2:n.a=t.d.n.a+t.d.a.a-r.a;break;case 3:n.b=t.d.n.b+t.d.a.b}}function ret(e,t,n){var r,i,a;for(i=new pm(Vu(EE(n).a.Kc(),new d));Cj(i);)r=P(by(i),18),!gy(r)&&!(!gy(r)&&r.c.i.c==r.d.i.c)&&(a=kat(e,r,n,new $ge),a.c.length>1&&Mr(t.c,a))}function iet(e,t,n,r,i){if(rr&&(e.a=r),e.bi&&(e.b=i),e}function aet(e){if(j(e,143))return Eot(P(e,143));if(j(e,233))return V1e(P(e,233));if(j(e,23))return D9e(P(e,23));throw E(new Fi(mCt+CA(new Wi(U(O(WW,1),FP,1,5,[e])))))}function oet(e,t,n,r,i){var a=!0,o,s;for(o=0;o>>i|n[o+r+1]<>>i,++o}return a}function set(e,t,n,r){var i,a,o;if(t.k==(DA(),qJ)){for(a=new pm(Vu(DE(t).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),o=i.c.i.k,o==qJ&&e.c.a[i.c.i.c.p]==r&&e.c.a[t.c.p]==n)return!0}return!1}function cet(e,t){var n,r,i,a;return t&=63,n=e.h&$F,t<22?(a=n>>>t,i=e.m>>t|n<<22-t,r=e.l>>t|e.m<<22-t):t<44?(a=0,i=n>>>t-22,r=e.m>>t-22|e.h<<44-t):(a=0,i=0,r=n>>>t-44),vu(r&QF,i&QF,a&$F)}function uet(e,t,n,r){var i;this.b=r,this.e=e==(sS(),g2),i=t[n],this.d=Dp(J9,[X,aL],[183,28],16,[i.length,i.length],2),this.a=Dp(q9,[X,HF],[53,28],15,[i.length,i.length],2),this.c=new N5e(t,n)}function det(e){var t,n,r;for(e.k=new URe((nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,e.j.c.length),r=new w(e.j);r.a=n)return RA(e,t,r.p),!0;return!1}function LA(e,t,n,r){var i,a,o=n.length,s,c,l;for(a=0,i=-1,l=wKe((sv(t,e.length+1),e.substr(t)),(Sf(),aK)),s=0;sa&&hPe(l,wKe(n[s],aK))&&(i=s,a=c);return i>=0&&(r[0]=t+a),i}function get(e){var t;return e.Db&64?AA(e):(t=new Gu(YSt),!e.a||gl(gl((t.a+=` "`,t),e.a),`"`),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function _et(e,t,n){var r,i,a,o,s=nM(e.e.Dh(),t);for(i=P(e.g,124),r=0,o=0;on?ptt(e,n,`start index`):t<0||t>n?ptt(t,n,`end index`):CM(`end index (%s) must not be less than start index (%s)`,U(O(WW,1),FP,1,5,[G(t),G(e)]))}function bet(e,t){var n,r,i,a;for(r=0,i=e.length;r0&&Cet(e,a,n));t.p=0}function zA(e){var t;this.c=new vo,this.f=e.e,this.e=e.d,this.i=e.g,this.d=e.c,this.b=e.b,this.k=e.j,this.a=e.a,this.j=e.i?e.i:(t=P(Ba(L3),9),new xf(t,P(Yd(t,t.length),9),0)),this.g=e.f}function wet(e){var t=jh(gl(new Gu(`Predicates.`),`and`),40),n=!0,r,i;for(i=new qn(e);i.b0?s[o-1]:V(UJ,jR,10,0,0,1),i=s[o],l=o=0?e.ki(i):Qtt(e,r);else throw E(new Fi(HH+r.xe()+UH))}else PT(e,n,r)}function ket(e){var t,n=null;if(t=!1,j(e,211)&&(t=!0,n=P(e,211).a),t||j(e,263)&&(t=!0,n=``+P(e,263).a),t||j(e,493)&&(t=!0,n=``+P(e,493).a),!t)throw E(new Ni(pCt));return n}function Aet(e,t,n){var r,i,a,o,s,c=nM(e.e.Dh(),t);for(r=0,s=e.i,i=P(e.g,124),o=0;o=e.d.b.c.length&&(t=new Eh(e.d),t.p=r.p-1,M(e.d.b,t),n=new Eh(e.d),n.p=r.p,M(e.d.b,n)),W_(r,P(Ep(e.d.b,r.p),30))}function Let(e,t,n){var r,i,a;if(!e.b[t.g]){for(e.b[t.g]=!0,r=n,!r&&(r=new zy),up(r.b,t),a=e.a[t.g].Kc();a.Ob();)i=P(a.Pb(),65),i.b!=t&&Let(e,i.b,r),i.c!=t&&Let(e,i.c,r),up(r.a,i);return r}return null}function Ret(e){switch(e.g){case 0:case 1:case 2:return nP(),Z8;case 3:case 4:case 5:return nP(),m5;case 6:case 7:case 8:return nP(),g5;case 9:case 10:case 11:return nP(),X8;default:return nP(),h5}}function zet(e,t){var n;return e.c.length!=0&&(n=b0e((ov(0,e.c.length),P(e.c[0],18)).c.i),z_(),n==(IO(),L0)||n==I0||hy(gg(new Mp(null,new cv(e,16)),new bie),new yme(t)))}function KA(e,t){if(j(t,207))return $Ce(e,P(t,27));if(j(t,193))return ewe(e,P(t,123));if(j(t,452))return QCe(e,P(t,166));throw E(new Fi(mCt+CA(new Wi(U(O(WW,1),FP,1,5,[t])))))}function Bet(e,t,n){var r,i;if(this.f=e,r=P(xh(e.b,t),260),i=r?r.a:0,RUe(n,i),n>=(i/2|0))for(this.e=r?r.c:null,this.d=i;n++0;)ux(this);this.b=t,this.a=null}function Vet(e,t){var n,r;t.a?Qot(e,t):(n=P(Do(e.b,t.b),60),n&&n==e.a[t.b.f]&&n.a&&n.a!=t.b.a&&n.c.Fc(t.b),r=P(Eo(e.b,t.b),60),r&&e.a[r.f]==t.b&&r.a&&r.a!=t.b.a&&t.b.c.Fc(r),Du(e.b,t.b))}function Het(e,t){var n=P(ig(e.b,t),127),r;if(P(P(Dy(e.r,t),21),87).dc()){n.n.b=0,n.n.c=0;return}n.n.b=e.C.b,n.n.c=e.C.c,e.A.Hc((TD(),x5))&&rlt(e,t),r=o4e(e,t),hM(e,t)==(pO(),P8)&&(r+=2*e.w),n.a.a=r}function Uet(e,t){var n=P(ig(e.b,t),127),r;if(P(P(Dy(e.r,t),21),87).dc()){n.n.d=0,n.n.a=0;return}n.n.d=e.C.d,n.n.a=e.C.a,e.A.Hc((TD(),x5))&&ilt(e,t),r=a4e(e,t),hM(e,t)==(pO(),P8)&&(r+=2*e.w),n.a.b=r}function Wet(e,t){var n,r,i,a=new T;for(r=new w(t);r.ar&&(sv(t-1,e.length),e.charCodeAt(t-1)<=32);)--t;return r>0||tn.a&&(r.Hc((eA(),e6))?i=(t.a-n.a)/2:r.Hc(n6)&&(i=t.a-n.a)),t.b>n.b&&(r.Hc((eA(),i6))?a=(t.b-n.b)/2:r.Hc(r6)&&(a=t.b-n.b)),B7e(e,i,a)}function ftt(e,t,n,r,i,a,o,s,c,l,u,d,f){j(e.Cb,90)&&$A(_y(P(e.Cb,90)),4),GS(e,n),e.f=o,tE(e,s),rE(e,c),eE(e,l),nE(e,u),RT(e,d),gE(e,f),FT(e,!0),Zx(e,i),e.Zk(a),aT(e,t),r!=null&&(e.i=null,OS(e,r))}function ptt(e,t,n){if(e<0)return CM(Hvt,U(O(WW,1),FP,1,5,[n,G(e)]));if(t<0)throw E(new Fi(Uvt+t));return CM(`%s (%s) must not be greater than size (%s)`,U(O(WW,1),FP,1,5,[n,G(e),G(t)]))}function mtt(e,t,n,r,i,a){var o=r-n,s,c,l;if(o<7){O1e(t,n,r,a);return}if(c=n+i,s=r+i,l=c+(s-c>>1),mtt(t,e,c,l,-i,a),mtt(t,e,l,s,-i,a),a.Ne(e[l-1],e[l])<=0){for(;n=0?e.bi(a,n):Pat(e,i,n);else throw E(new Fi(HH+i.xe()+UH))}else LE(e,r,i,n)}function ytt(e){var t,n;if(e.f){for(;e.n>0;){if(t=P(e.k.Xb(e.n-1),76),n=t.Lk(),j(n,102)&&(P(n,19).Bb&GH)!=0&&(!e.e||n.pk()!=R5||n.Lj()!=0)&&t.md()!=null)return!0;--e.n}return!1}return e.n>0}function btt(e){var t,n=P(e,54)._h(),r,i;if(n)try{if(r=null,t=Mj((qo(),N7),qut(H1e(n))),t&&(i=t.ai(),i&&(r=i.Fl(ave(n.e)))),r&&r!=e)return btt(r)}catch(e){if(e=ew(e),!j(e,63))throw E(e)}return e}function xtt(e,t,n){var r,i,a;n.Ug(`Remove overlaps`,1),n.dh(t,mxt),r=P(J(t,(Pd(),y4)),27),e.f=r,e.a=UO(P(J(t,(PA(),P4)),300)),i=N(J(t,(vP(),J6))),nfe(e,(Gh(i),i)),a=sM(r),Kht(e,t,a,n),n.dh(t,YV)}function Stt(e){var t,n,r;if(ki(Od(J(e,(vP(),_6))))){for(r=new T,n=new pm(Vu(Ij(e).a.Kc(),new d));Cj(n);)t=P(by(n),74),uj(t)&&ki(Od(J(t,v6)))&&Mr(r.c,t);return r}return Vg(),Vg(),QG}function Ctt(e){if(!e)return W_e(),zTt;var t=e.valueOf?e.valueOf():e;if(t!==e){var n=pG[typeof t];return n?n(t):XQe(typeof t)}return e instanceof Array||e instanceof r.Array?new xn(e):new wn(e)}function wtt(e,t,n){var i,a,o=e.o;switch(i=P(ig(e.p,n),252),a=i.i,a.b=oj(i),a.a=aj(i),a.b=r.Math.max(a.b,o.a),a.b>o.a&&!t&&(a.b=o.a),a.c=-(a.b-o.a)/2,n.g){case 1:a.d=-a.a;break;case 3:a.d=o.b}iN(i),oN(i)}function Ttt(e,t,n){var i,a,o=e.o;switch(i=P(ig(e.p,n),252),a=i.i,a.b=oj(i),a.a=aj(i),a.a=r.Math.max(a.a,o.b),a.a>o.b&&!t&&(a.a=o.b),a.d=-(a.a-o.b)/2,n.g){case 4:a.c=-a.b;break;case 2:a.c=o.a}iN(i),oN(i)}function Ett(e,t){var n,r,i,a,o;if(!t.dc()){if(i=P(t.Xb(0),131),t.gc()==1){hst(e,i,i,1,0,t);return}for(n=1;n0)try{i=GM(t,xF,AP)}catch(e){throw e=ew(e),j(e,130)?(r=e,E(new Nb(r))):E(e)}return n=(!e.a&&(e.a=new wr(e)),e.a),i=0?P(H(n,i),58):null}function jtt(e,t){if(e<0)return CM(Hvt,U(O(WW,1),FP,1,5,[`index`,G(e)]));if(t<0)throw E(new Fi(Uvt+t));return CM(`%s (%s) must be less than size (%s)`,U(O(WW,1),FP,1,5,[`index`,G(e),G(t)]))}function Mtt(e){var t,n,r,i,a;if(e==null)return IP;for(a=new UC(PP,`[`,`]`),n=e,r=0,i=n.length;r`,E(new Fi(r.a))}function Ytt(e){var t,n=-e.a;return t=U(O(K9,1),EF,28,15,[43,48,48,48,48]),n<0&&(t[0]=45,n=-n),t[1]=t[1]+((n/60|0)/10|0)&OF,t[2]=t[2]+(n/60|0)%10&OF,t[3]=t[3]+(n%60/10|0)&OF,t[4]=t[4]+n%10&OF,ND(t,0,t.length)}function Xtt(e){var t,n,r,i;for(e.g=new NE(P(ph(_5),297)),r=0,n=(nP(),Z8),t=0;t=0?e.Lh(n,!0,!0):mj(e,i,!0),160)),P(r,220).Zl(t);else throw E(new Fi(HH+t.xe()+UH))}function $tt(e){var t,n;return e>-0x800000000000&&e<0x800000000000?e==0?0:(t=e<0,t&&(e=-e),n=C_(r.Math.floor(r.Math.log(e)/.6931471805599453)),(!t||e!=r.Math.pow(2,n))&&++n,n):kXe(LC(e))}function ent(e){var t,n,r,i,a=new Rl,o,s;for(n=new w(e);n.a2&&s.e.b+s.j.b<=2&&(i=s,r=o),a.a.zc(i,a),i.q=r);return a}function tnt(e,t,n){n.Ug(`Eades radial`,1),n.dh(t,YV),e.d=P(J(t,(Pd(),y4)),27),e.c=D(N(J(t,(PA(),M4)))),e.e=UO(P(J(t,P4),300)),e.a=Q1e(P(J(t,yIt),434)),e.b=B8e(P(J(t,fIt),354)),c8e(e),n.dh(t,YV)}function nnt(e,t){if(t.Ug(`Target Width Setter`,1),qy(e,(gM(),o3)))OO(e,(xM(),Z4),N(J(e,o3)));else throw E(new zi(`A target width has to be set if the TargetWidthWidthApproximator should be used.`));t.Vg()}function rnt(e,t){var n,r=new ZO(e),i;return VC(r,t),W(r,(Y(),wQ),t),W(r,(mP(),Q1),(rA(),R8)),W(r,J$,(RO(),Y3)),En(r,(DA(),GJ)),n=new jA,G_(n,r),tj(n,(nP(),g5)),i=new jA,G_(i,r),tj(i,X8),r}function int(e){switch(e.g){case 0:return new Ti((sS(),h2));case 1:return new Oue;case 2:return new kue;default:throw E(new Fi(`No implementation is available for the crossing minimizer `+(e.f==null?``+e.g:e.f)))}}function ant(e,t){var n,r,i,a,o;for(e.c[t.p]=!0,M(e.a,t),o=new w(t.j);o.a=a)o.$b();else for(i=o.Kc(),r=0;r0?Zi():o<0&&gnt(e,t,-o),!0)}function aj(e){var t,n,r,i,a,o,s=0;if(e.b==0){for(o=N4e(e,!0),t=0,r=o,i=0,a=r.length;i0&&(s+=n,++t);t>1&&(s+=e.c*(t-1))}else s=Sve(oC(_g(hg(yPe(e.a),new et),new tt)));return s>0?s+e.n.d+e.n.a:0}function oj(e){var t,n,r,i,a,o,s=0;if(e.b==0)s=Sve(oC(_g(hg(yPe(e.a),new Qe),new $e)));else{for(o=P4e(e,!0),t=0,r=o,i=0,a=r.length;i0&&(s+=n,++t);t>1&&(s+=e.c*(t-1))}return s>0?s+e.n.b+e.n.c:0}function vnt(e){var t,n;if(e.c.length!=2)throw E(new Ii(`Order only allowed for two paths.`));t=(ov(0,e.c.length),P(e.c[0],18)),n=(ov(1,e.c.length),P(e.c[1],18)),t.d.i!=n.c.i&&(e.c.length=0,Mr(e.c,n),Mr(e.c,t))}function ynt(e,t,n){var r;for(Ql(n,t.g,t.f),$l(n,t.i,t.j),r=0;r<(!t.a&&(t.a=new F($5,t,10,11)),t.a).i;r++)ynt(e,P(H((!t.a&&(t.a=new F($5,t,10,11)),t.a),r),27),P(H((!n.a&&(n.a=new F($5,n,10,11)),n.a),r),27))}function bnt(e,t){var n,i,a,o=P(ig(e.b,t),127);for(n=o.a,a=P(P(Dy(e.r,t),21),87).Kc();a.Ob();)i=P(a.Pb(),117),i.c&&(n.a=r.Math.max(n.a,fMe(i.c)));if(n.a>0)switch(t.g){case 2:o.n.c=e.s;break;case 4:o.n.b=e.s}}function xnt(e,t){var n=P(K(t,(XM(),Xq)),17).a-P(K(e,Xq),17).a,r,i;return n==0?(r=ef(xu(P(K(e,(jS(),nJ)),8)),P(K(e,rJ),8)),i=ef(xu(P(K(t,nJ),8)),P(K(t,rJ),8)),aE(r.a*r.b,i.a*i.b)):n}function Snt(e,t){var n=P(K(t,(rN(),d4)),17).a-P(K(e,d4),17).a,r,i;return n==0?(r=ef(xu(P(K(e,(tP(),V2)),8)),P(K(e,H2),8)),i=ef(xu(P(K(t,V2),8)),P(K(t,H2),8)),aE(r.a*r.b,i.a*i.b)):n}function Cnt(e){var t,n=new ta;return n.a+=`e_`,t=DXe(e),t!=null&&(n.a+=``+t),e.c&&e.d&&(gl((n.a+=` `,n),Sk(e.c)),gl(hl((n.a+=`[`,n),e.c.i),`]`),gl((n.a+=kR,n),Sk(e.d)),gl(hl((n.a+=`[`,n),e.d.i),`]`)),n.a}function wnt(e){switch(e.g){case 0:return new Rue;case 1:return new zue;case 2:return new Iue;case 3:return new Fue;default:throw E(new Fi(`No implementation is available for the layout phase `+(e.f==null?``+e.g:e.f)))}}function Tnt(e,t,n,i,a){var o=0;switch(a.g){case 1:o=r.Math.max(0,t.b+e.b-(n.b+i));break;case 3:o=r.Math.max(0,-e.b-i);break;case 2:o=r.Math.max(0,-e.a-i);break;case 4:o=r.Math.max(0,t.a+e.a-(n.a+i))}return o}function Ent(e,t,n){var r,i,a,o,s;if(n)for(i=n.a.length,r=new hm(i),s=(r.b-r.a)*r.c<0?($o(),G9):new Ru(r);s.Ob();)o=P(s.Pb(),17),a=Pv(n,o.a),sCt in a.a||cU in a.a?zlt(e,a,t):J_t(e,a,t),STe(P(xh(e.b,RD(a)),74))}function Dnt(e){var t,n;switch(e.b){case-1:return!0;case 0:return n=e.t,n>1||n==-1?(e.b=-1,!0):(t=Ik(e),t&&(Qo(),t.lk()==xwt)?(e.b=-1,!0):(e.b=1,!1));default:case 1:return!1}}function Ont(e,t){var n,r,i,a;if(hP(e),e.c!=0||e.a!=123)throw E(new Ui(TP((fu(),FCt))));if(a=t==112,r=e.d,n=fd(e.i,125,r),n<0)throw E(new Ui(TP((fu(),ICt))));return i=p_(e.i,r,n),e.d=n+1,dGe(i,a,(e.e&512)==512)}function knt(e){var t,n,r=e.a.c.length,i,a,o,s;if(r>0)for(o=e.c.d,s=e.d.d,i=ku(ef(new k(s.a,s.b),o),1/(r+1)),a=new k(o.a,o.b),n=new w(e.a);n.a=0&&r=0?e.Lh(n,!0,!0):mj(e,i,!0),160)),P(r,220).Wl(t);throw E(new Fi(HH+t.xe()+WH))}function Pnt(){Qbe();var e;return pHt?P(Mj((qo(),N7),iW),2038):(Ol(YW,new Wce),Pht(),e=P(j(v_((qo(),N7),iW),560)?v_(N7,iW):new MFe,560),pHt=!0,Avt(e),Bvt(e),Qh((Jbe(),UVt),e,new oce),H_(N7,iW,e),e)}function Fnt(e,t){var n,r,i,a;e.j=-1,Gl(e.e)?(n=e.i,a=e.i!=0,Ty(e,t),r=new Hb(e.e,3,e.c,null,t,n,a),i=t.zl(e.e,e.c,null),i=E5e(e,t,i),i?(i.nj(r),i.oj()):AC(e.e,r)):(Ty(e,t),i=t.zl(e.e,e.c,null),i&&i.oj())}function lj(e,t){var n,r,i=0;if(r=t[0],r>=e.length)return-1;for(n=(sv(r,e.length),e.charCodeAt(r));n>=48&&n<=57&&(i=i*10+(n-48),++r,!(r>=e.length));)n=(sv(r,e.length),e.charCodeAt(r));return r>t[0]?t[0]=r:i=-1,i}function Int(e){var t,n,i,a=P(e.a,17).a,o=P(e.b,17).a;return n=a,i=o,t=r.Math.max(r.Math.abs(a),r.Math.abs(o)),a<=0&&a==o?(n=0,i=o-1):a==-t&&o!=t?(n=o,i=a,o>=0&&++n):(n=-o,i=a),new Kc(G(n),G(i))}function Lnt(e,t,n,r){var i,a,o,s,c,l;for(i=0;i=0&&l>=0&&c=e.i)throw E(new Mi(yU+t+bU+e.i));if(n>=e.i)throw E(new Mi(xU+n+bU+e.i));return r=e.g[n],t!=n&&(t>16),t=r>>16&16,n=16-t,e>>=t,r=e-256,t=r>>16&8,n+=t,e<<=t,r=e-uI,t=r>>16&4,n+=t,e<<=t,r=e-ZP,t=r>>16&2,n+=t,e<<=t,r=e>>14,t=r&~(r>>1),n+2-t)}function znt(e){Ug();var t,n,r,i;for(zq=new T,Rq=new Dr,Lq=new T,t=(!e.a&&(e.a=new F($5,e,10,11)),e.a),$gt(t),i=new Lu(t);i.e!=i.i.gc();)r=P(gO(i),27),Ab(zq,r,0)==-1&&(n=new T,M(Lq,n),g2e(r,n));return Lq}function Bnt(e,t,n){var r,i,a,o;e.a=n.b.d,j(t,326)?(i=cM(P(t,74),!1,!1),a=FA(i),r=new npe(e),ly(a,r),cN(a,i),t.of((vP(),x6))!=null&&ly(P(t.of(x6),75),r)):(o=P(t,422),o.rh(o.nh()+e.a.a),o.sh(o.oh()+e.a.b))}function Vnt(e,t){var n,r,i=new T;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),n.c.g==e.g&&A(K(n.b,(rN(),p4)))!==A(K(n.c,p4))&&!hy(new Mp(null,new cv(i,16)),new jme(n))&&Mr(i.c,n);return hu(i,new oae),i}function Hnt(e,t,n){var r,i,a,o;return j(t,153)&&j(n,153)?(a=P(t,153),o=P(n,153),e.a[a.a][o.a]+e.a[o.a][a.a]):j(t,250)&&j(n,250)&&(r=P(t,250),i=P(n,250),r.a==i.a)?P(K(i.a,(XM(),Xq)),17).a:0}function Unt(e,t){var n,i,a,o,s,c,l,u=D(N(K(t,(mP(),S0))));for(l=e[0].n.a+e[0].o.a+e[0].d.c+u,c=1;c=0?n:(s=Ih(ef(new k(o.c+o.b/2,o.d+o.a/2),new k(a.c+a.b/2,a.d+a.a/2))),-(gdt(a,o)-1)*s)}function Gnt(e,t,n){var r;To(new Mp(null,(!n.a&&(n.a=new F(W5,n,6,6)),new cv(n.a,16))),new CSe(e,t)),To(new Mp(null,(!n.n&&(n.n=new F(Q5,n,1,7)),new cv(n.n,16))),new wSe(e,t)),r=P(J(n,(vP(),x6)),75),r&&eC(r,e,t)}function mj(e,t,n){var r,i,a=HN((UA(),l9),e.Dh(),t);if(a)return Qo(),P(a,69).xk()||(a=mv(Rb(l9,a))),i=(r=e.Ih(a),P(r>=0?e.Lh(r,!0,!0):mj(e,a,!0),160)),P(i,220).Sl(t,n);throw E(new Fi(HH+t.xe()+WH))}function Knt(e,t,n,r){var i=e.d[t],a,o,s,c;if(i){if(a=i.g,c=i.i,r!=null){for(s=0;s=n&&(r=t,l=(c.c+c.a)/2,o=l-n,c.c<=l-n&&(i=new Bf(c.c,o),Jp(e,r++,i)),s=l+n,s<=c.a&&(a=new Bf(s,c.a),av(r,e.c.length),Ts(e.c,r,a)))}function $nt(e,t,n){var r,i,a,o,s,c;if(!t.dc()){for(i=new vo,c=t.Kc();c.Ob();)for(s=P(c.Pb(),40),Qh(e.a,G(s.g),G(n)),o=(r=dO(new hr(s).a.d,0),new gr(r));Za(o.a);)a=P(Lv(o.a),65).c,iy(i,a,i.c.b,i.c);$nt(e,i,n+1)}}function ert(e){var t;if(!e.c&&e.g==null)e.d=e.bj(e.f),tb(e,e.d),t=e.d;else if(e.g==null)return!0;else if(e.i==0)return!1;else t=P(e.g[e.i-1],51);return t==e.b&&null.Vm>=null.Um()?(Pj(e),ert(e)):t.Ob()}function trt(e){if(this.a=e,e.c.i.k==(DA(),GJ))this.c=e.c,this.d=P(K(e.c.i,(Y(),TQ)),64);else if(e.d.i.k==GJ)this.c=e.d,this.d=P(K(e.d.i,(Y(),TQ)),64);else throw E(new Fi(`Edge `+e+` is not an external edge.`))}function nrt(e,t){var n,r,i=e.b;e.b=t,e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,i,e.b)),t?t!=e&&(GS(e,t.zb),$x(e,t.d),n=(r=t.c,r??t.zb),SS(e,n==null||ff(n,t.zb)?null:n)):(GS(e,null),$x(e,0),SS(e,null))}function rrt(e,t){var n;this.e=(gh(),ph(e),gh(),pD(e)),this.c=(ph(t),pD(t)),vTe(this.e.Rd().dc()==this.c.Rd().dc()),this.d=D1e(this.e),this.b=D1e(this.c),n=Dp(WW,[X,FP],[5,1],5,[this.e.Rd().gc(),this.c.Rd().gc()],2),this.a=n,sJe(this)}function irt(e){var t=(!aG&&(aG=v_t()),aG);return`"`+e.replace(/[\x00-\x1f\xad\u0600-\u0603\u06dd\u070f\u17b4\u17b5\u200b-\u200f\u2028-\u202e\u2060-\u2064\u206a-\u206f\ufeff\ufff9-\ufffb"\\]/g,function(e){return BLe(e,t)})+`"`}function art(e,t,n,i,a,o){var s,c,l,u,d;if(a!=0)for(A(e)===A(n)&&(e=e.slice(t,t+a),t=0),l=n,c=t,u=t+a;c=o)throw E(new lf(t,o));return i=n[t],o==1?r=null:(r=V(g7,FU,424,o-1,0,1),tN(n,0,r,0,t),a=o-t-1,a>0&&tN(n,t+1,r,t,a)),iO(e,r),ntt(e,t,i),i}function lrt(e){var t,n;if(e.f){for(;e.n0?GE(n):YT(GE(n))),OO(t,t0,a)}function prt(e,t){var n;t.Ug(`Partition preprocessing`,1),n=P(ay(hg(ox(hg(new Mp(null,new cv(e.a,16)),new nne),new rne),new ine),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),To(n.Oc(),new ane),t.Vg()}function mrt(e,t){var n,r,i,a,o=e.j;for(t.a!=t.b&&hu(o,new Fre),i=o.c.length/2|0,r=0;r0&&MM(e,n,t),a):r.a==null?i.a==null?0:(MM(e,n,t),1):(MM(e,t,n),-1)}function grt(e,t){var n,r,i=t.b.b,a,o;for(e.a=V(JW,BL,15,i,0,1),e.b=V(J9,aL,28,i,16,1),o=dO(t.b,0);o.b!=o.d.c;)a=P(Lv(o),40),e.a[a.g]=new vo;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),e.a[n.b.g].Fc(n),e.a[n.c.g].Fc(n)}function _rt(e,t){var n,r,i,a;e.Pj()?(n=e.Ej(),a=e.Qj(),++e.j,e.qj(n,e.Zi(n,t)),r=e.Ij(3,null,t,n,a),e.Mj()?(i=e.Nj(t,null),i?(i.nj(r),i.oj()):e.Jj(r)):e.Jj(r)):(oFe(e,t),e.Mj()&&(i=e.Nj(t,null),i&&i.oj()))}function vrt(e,t,n){var r,i,a;e.Pj()?(a=e.Qj(),jT(e,t,n),r=e.Ij(3,null,n,t,a),e.Mj()?(i=e.Nj(n,null),e.Tj()&&(i=e.Uj(n,i)),i?(i.nj(r),i.oj()):e.Jj(r)):e.Jj(r)):(jT(e,t,n),e.Mj()&&(i=e.Nj(n,null),i&&i.oj()))}function _j(e,t){var n,r,i,a,o=nM(e.e.Dh(),t);for(i=new an,n=P(e.g,124),a=e.i;--a>=0;)r=n[a],o.am(r.Lk())&&tb(i,r);!E_t(e,i)&&Gl(e.e)&&Kr(e,t.Jk()?s_(e,6,t,(Vg(),QG),null,-1,!1):s_(e,t.tk()?2:1,t,null,null,-1,!1))}function yrt(e,t){var n,r,i,a,o;return e.a==(TA(),BZ)||(a=t.a.c,n=t.a.c+t.a.b,!(t.j&&(r=t.A,o=r.c.c.a-r.o.a/2,i=a-(r.n.a+r.o.a),i>o)||t.q&&(r=t.C,o=r.c.c.a-r.o.a/2,i=r.n.a-n,i>o)))}function brt(e){B_();var t,n=new ry,r,i,a,o,s;for(i=new w(e.e.b);i.a1?e.e*=D(e.a):e.f/=D(e.a),HQe(e),a2e(e),clt(e),W(e.b,(bO(),Nq),e.g)}function Ert(e,t,n){var r=0,i,a,o,s,c=n;for(t||(r=n*(e.c.length-1),c*=-1),a=new w(e);a.a=0?e.Ah(null):e.Ph().Th(e,-1-t,null,null)),e.Bh(P(i,54),n),r&&r.oj(),e.vh()&&e.wh()&&n>-1&&AC(e,new Sm(e,9,n,a,i)),i):a}function Rrt(e,t){var n,r,i,a=e.b.Ce(t),o;for(r=(n=e.a.get(a),n??V(WW,FP,1,0,5,1)),o=0;o>5,i>=e.d)return e.e<0;if(n=e.a[i],t=1<<(t&31),e.e<0){if(r=FYe(e),i>16)),15).dd(a),s0&&(!(ql(e.a.c)&&t.n.d)&&!(Jl(e.a.c)&&t.n.b)&&(t.g.d+=r.Math.max(0,i/2-.5)),!(ql(e.a.c)&&t.n.a)&&!(Jl(e.a.c)&&t.n.c)&&(t.g.a-=i-1))}function Xrt(e){var t,n,i,a=new T,o=idt(e,a);if(t=P(K(e,(Y(),QQ)),10),t)for(i=new w(t.j);i.a>t,a=e.m>>t|n<<22-t,i=e.l>>t|e.m<<22-t):t<44?(o=r?$F:0,a=n>>t-22,i=e.m>>t-22|n<<44-t):(o=r?$F:0,a=r?QF:0,i=n>>t-44),vu(i&QF,a&QF,o&$F)}function wj(e){var t,n,i,a,o,s;for(this.c=new T,this.d=e,i=cI,a=cI,t=lI,n=lI,s=dO(e,0);s.b!=s.d.c;)o=P(Lv(s),8),i=r.Math.min(i,o.a),a=r.Math.min(a,o.b),t=r.Math.max(t,o.a),n=r.Math.max(n,o.b);this.a=new wg(i,a,t-i,n-a)}function eit(e,t){var n,r,i,a,o,s;for(a=new w(e.b);a.a0&&j(t,44)&&(e.a._j(),l=P(t,44),c=l.ld(),a=c==null?0:US(c),o=MDe(e.a,a),n=e.a.d[o],n)){for(r=P(n.g,379),u=n.i,s=0;s=2)for(n=a.Kc(),t=N(n.Pb());n.Ob();)o=t,t=N(n.Pb()),i=r.Math.min(i,(Gh(t),t-(Gh(o),o)));return i}function vit(e,t){var n,r,i=new T;for(r=dO(t.a,0);r.b!=r.d.c;)n=P(Lv(r),65),n.b.g==e.g&&!ff(n.b.c,LV)&&A(K(n.b,(rN(),p4)))!==A(K(n.c,p4))&&!hy(new Mp(null,new cv(i,16)),new Mme(n))&&Mr(i.c,n);return hu(i,new uae),i}function yit(e,t){var n,r,i;if(A(t)===A(ph(e)))return!0;if(!j(t,15)||(r=P(t,15),i=e.gc(),i!=r.gc()))return!1;if(j(r,59)){for(n=0;n0&&(i=n),o=new w(e.f.e);o.a0?(--t,--n):r>=0&&i<0?(t+=1,n+=1):r>0&&i>=0?(--t,n+=1):(t+=1,--n),new Kc(G(t),G(n))}function Fit(e,t){return e.ct.c?1:e.bt.b?1:e.a==t.a?e.d==(Vv(),b2)&&t.d==y2?-1:+(e.d==y2&&t.d==b2):US(e.a)-US(t.a)}function Iit(e,t){var n,r,i,a=t.a,o=a.c.i==t.b?a.d:a.c;return r=a.c.i==t.b?a.c:a.d,i=g0e(e.a,o,r),i>0&&i0):i<0&&-i0)}function Lit(e,t,n,r){var i=(t-e.d)/e.c.c.length,a=0,o,s,c,l,u,d;for(e.a+=n,e.d=t,d=new w(e.c);d.a>24;return o}function zit(e){if(e.ze()){var t=e.c;e.o=t.Ae()?`[`+t.n:t.ze()?`[`+t.xe():`[L`+t.xe()+`;`,e.b=t.we()+`[]`,e.k=t.ye()+`[]`;return}var n=e.j,r=e.d;r=r.split(`/`),e.o=MD(`.`,[n,MD(`$`,r)]),e.b=MD(`.`,[n,MD(`.`,r)]),e.k=r[r.length-1]}function Bit(e,t){var n,r,i,a,o=null;for(a=new w(e.e.a);a.a=0;t-=2)for(n=0;n<=t;n+=2)(e.b[n]>e.b[n+2]||e.b[n]===e.b[n+2]&&e.b[n+1]>e.b[n+3])&&(r=e.b[n+2],e.b[n+2]=e.b[n],e.b[n]=r,r=e.b[n+3],e.b[n+3]=e.b[n+1],e.b[n+1]=r);e.c=!0}}function Jit(e,t){var n,r,i,a,o,s,c,l=-1,u=0;for(o=e,s=0,c=o.length;s0&&++u;++l}return u}function Aj(e){var t,n=new Gu(Ha(e.Rm));return n.a+=`@`,gl(n,(t=US(e)>>>0,t.toString(16))),e.Vh()?(n.a+=` (eProxyURI: `,hl(n,e._h()),e.Kh()&&(n.a+=` eClass: `,hl(n,e.Kh())),n.a+=`)`):e.Kh()&&(n.a+=` (eClass: `,hl(n,e.Kh()),n.a+=`)`),n.a}function jj(e){var t,n,r,i;if(e.e)throw E(new Ii((Ad(wK),qI+wK.k+JI)));for(e.d==(GT(),r8)&&ZN(e,t8),n=new w(e.a.a);n.a>24}return n}function $it(e,t,n){var r,i=P(ig(e.i,t),314),a;if(!i){if(i=new JKe(e.d,t,n),zm(e.i,t,i),PD(t))Qwe(e.a,t.c,t.b,i);else switch(a=Ret(t),r=P(ig(e.p,a),252),a.g){case 1:case 3:i.j=!0,Oi(r,t.b,i);break;case 4:case 2:i.k=!0,Oi(r,t.c,i)}}return i}function eat(e,t){var n,r,i,a,o,s,c=dd(e.c-e.b&e.a.length-1),l=null,u=null;for(a=new fg(e);a.a!=a.b;)i=P(cT(a),10),n=(s=P(K(i,(Y(),zQ)),12),s?s.i:null),r=(o=P(K(i,BQ),12),o?o.i:null),(l!=n||u!=r)&&(Ort(c,t),l=n,u=r),Mr(c.c,i);Ort(c,t)}function tat(e,t,n,r){var i,a,o,s=new an,c=nM(e.e.Dh(),t),l;if(i=P(e.g,124),Qo(),P(t,69).xk())for(o=0;o=0)return a;for(o=1,c=new w(t.j);c.a=0)return a;for(o=1,c=new w(t.j);c.a0&&t.Ne((ov(i-1,e.c.length),P(e.c[i-1],10)),a)>0;)uy(e,i,(ov(i-1,e.c.length),P(e.c[i-1],10))),--i;ov(i,e.c.length),e.c[i]=a}n.a=new Dr,n.b=new Dr}function aat(e,t,n){var r,i,a,o,s,c,l,u=(r=P(t.e&&t.e(),9),new xf(r,P(Yd(r,r.length),9),0));for(c=nN(n,`[\\[\\]\\s,]+`),a=c,o=0,s=a.length;o=0?(t||(t=new ea,r>0&&pl(t,(Zy(0,r,e.length),e.substr(0,r)))),t.a+=`\\`,Ah(t,n&OF)):t&&Ah(t,n&OF);return t?t.a:e}function sat(e){var t,n,i;for(n=new w(e.a.a.b);n.a0&&(!(ql(e.a.c)&&t.n.d)&&!(Jl(e.a.c)&&t.n.b)&&(t.g.d-=r.Math.max(0,i/2-.5)),!(ql(e.a.c)&&t.n.a)&&!(Jl(e.a.c)&&t.n.c)&&(t.g.a+=r.Math.max(0,i-1)))}function cat(e,t,n){var r,i;if((e.c-e.b&e.a.length-1)==2)t==(nP(),Z8)||t==X8?(Sx(P(yw(e),15),(kk(),y8)),Sx(P(yw(e),15),b8)):(Sx(P(yw(e),15),(kk(),b8)),Sx(P(yw(e),15),y8));else for(i=new fg(e);i.a!=i.b;)r=P(cT(i),15),Sx(r,n)}function lat(e,t){var n,r,i=Xf(new Phe(e)),a,o,s=new bv(i,i.c.length),c;for(a=Xf(new Phe(t)),c=new bv(a,a.c.length),o=null;s.b>0&&c.b>0&&(n=(jd(s.b>0),P(s.a.Xb(s.c=--s.b),27)),r=(jd(c.b>0),P(c.a.Xb(c.c=--c.b),27)),n==r);)o=n;return o}function uat(e,t,n){var r,i,a,o;Yze(e,t)>Yze(e,n)?(r=SE(n,(nP(),X8)),e.d=r.dc()?0:fp(P(r.Xb(0),12)),o=SE(t,g5),e.b=o.dc()?0:fp(P(o.Xb(0),12))):(i=SE(n,(nP(),g5)),e.d=i.dc()?0:fp(P(i.Xb(0),12)),a=SE(t,X8),e.b=a.dc()?0:fp(P(a.Xb(0),12)))}function dat(e,t){var n=e.o.a,r,i,a;for(a=P(P(Dy(e.r,t),21),87).Kc();a.Ob();)i=P(a.Pb(),117),i.e.a=n*D(N(i.b.of(uq))),i.e.b=(r=i.b,r.pf((vP(),F6))?r.ag()==(nP(),Z8)?-r.Mf().b-D(N(r.of(F6))):D(N(r.of(F6))):r.ag()==(nP(),Z8)?-r.Mf().b:0)}function fat(e,t){var n,r,i,a;for(t.Ug(`Self-Loop pre-processing`,1),r=new w(e.a);r.ae.c));o++)i.a>=e.s&&(a<0&&(a=o),s=o);return c=(e.s+e.c)/2,a>=0&&(r=Llt(e,t,a,s),c=Kbe((ov(r,t.c.length),P(t.c[r],339))),Qnt(t,r,n)),c}function Nj(e,t,n){var r,i,a,o=(a=new Vse,a),s,c,l;for(FJe(o,(Gh(t),t)),l=(!o.b&&(o.b=new Td((CP(),$7),o9,o)),o.b),c=1;c0&&ymt(this,i)}function gat(e,t,n,r,i,a){var o,s,c;if(!i[t.a]){for(i[t.a]=!0,o=r,!o&&(o=new Py),M(o.e,t),c=a[t.a].Kc();c.Ob();)s=P(c.Pb(),290),s.d!=n&&s.c!=n&&(s.c!=t&&gat(e,s.c,t,o,i,a),s.d!=t&&gat(e,s.d,t,o,i,a),M(o.c,s),nw(o.d,s.b));return o}return null}function _at(e){var t=0,n,r,i,a,o,s;for(i=new w(e.e);i.a=2}function vat(e,t,n,r,i){var a=e.c.d.j,o=P(SO(n,0),8),s,c,l,u;for(u=1;u1||(t=Zp(w8,U(O(M8,1),Z,95,0,[C8,E8])),BC(b_(t,e))>1)||(r=Zp(j8,U(O(M8,1),Z,95,0,[A8,k8])),BC(b_(r,e))>1))}function bat(e,t,n){var r,i,a;for(a=new w(e.t);a.a0&&(r.b.n-=r.c,r.b.n<=0&&r.b.u>0&&up(t,r.b));for(i=new w(e.i);i.a0&&(r.a.u-=r.c,r.a.u<=0&&r.a.n>0&&up(n,r.a))}function Pj(e){var t,n,r,i,a;if(e.g==null&&(e.d=e.bj(e.f),tb(e,e.d),e.c))return a=e.f,a;if(t=P(e.g[e.i-1],51),i=t.Pb(),e.e=t,n=e.bj(i),n.Ob())e.d=n,tb(e,n);else for(e.d=null;!t.Ob()&&(Sh(e.g,--e.i,null),e.i!=0);)r=P(e.g[e.i-1],51),t=r;return i}function xat(e,t){var n,r=t,i=r.Lk(),a,o,s;if(aM(e.e,i)){if(i.Si()&&Kv(e,i,r.md()))return!1}else for(s=nM(e.e.Dh(),i),n=P(e.g,124),a=0;a1||n>1)return 2;return t+n==1?2:0}function Lj(e,t){var n,i,a,o=e.a*OI+e.b*1502,s,c=e.b*OI+11;return n=r.Math.floor(c*kI),o+=n,c-=n*AI,o%=AI,e.a=o,e.b=c,t<=24?r.Math.floor(e.a*cK[t]):(a=e.a*(1<=2147483648&&(i-=4294967296),i)}function jat(e,t,n){var r,i,a=new T,o,s,c,l=new vo;for(o=new vo,Pft(e,l,o,t),Zmt(e,l,o,t,n),c=new w(e);c.ar.b.g&&Mr(a.c,r);return a}function Mat(e,t,n){var r,i,a,o,s=e.c,c;for(o=(n.q?n.q:(Vg(),Vg(),$G)).vc().Kc();o.Ob();)a=P(o.Pb(),44),r=!Xa(hg(new Mp(null,new cv(s,16)),new rr(new gSe(t,a)))).Bd((wo(),SK)),r&&(c=a.md(),j(c,4)&&(i=UD(c),i!=null&&(c=i)),t.qf(P(a.ld(),149),c))}function Nat(e,t,n){var r,i;if(cg(e.b),Um(e.b,(KT(),m3),(Ho(),O3)),Um(e.b,h3,t.g),Um(e.b,g3,t.a),e.a=BN(e.b,t),n.Ug(`Compaction by shrinking a tree`,e.a.c.length),t.i.c.length>1)for(i=new w(e.a);i.a=0?e.Lh(r,!0,!0):mj(e,a,!0),160)),P(i,220).Xl(t,n)}else throw E(new Fi(HH+t.xe()+UH))}function Rj(e,t){var n,r,i,a,o;if(t){for(a=j(e.Cb,90)||j(e.Cb,102),o=!a&&j(e.Cb,331),r=new Lu((!t.a&&(t.a=new Vp(t,j7,t)),t.a));r.e!=r.i.gc();)if(n=P(gO(r),89),i=ZM(n),a?j(i,90):o?j(i,156):i)return i;return a?(CP(),J7):(CP(),q7)}return null}function Fat(e,t){var n,r,i,a;for(t.Ug(`Resize child graph to fit parent.`,1),r=new w(e.b);r.a=2*t&&M(n,new Bf(o[r-1]+t,o[r]-t));return n}function Rat(e,t,n){var r,i,a,o,s,c,l,u;if(n)for(a=n.a.length,r=new hm(a),s=(r.b-r.a)*r.c<0?($o(),G9):new Ru(r);s.Ob();)o=P(s.Pb(),17),i=Pv(n,o.a),i&&(c=IVe(e,(l=(Ia(),u=new s_e,u),t&&Yat(l,t),l),i),CS(c,Fv(i,dU)),sA(i,c),ktt(i,c),Cw(e,i,c))}function zj(e){var t,n,r,i,a,o;if(!e.j){if(o=new qse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(l_(e));r.e!=r.i.gc();)n=P(gO(r),29),i=zj(n),th(o,i),tb(o,n);t.a.Bc(e)}Kw(o),e.j=new El((P(H(R((vh(),z7).o),11),19),o.i),o.g),_y(e).b&=-33}return e.j}function zat(e){var t,n,r,i;if(e==null)return null;if(r=EN(e,!0),i=EW.length,ff(r.substr(r.length-i,i),EW)){if(n=r.length,n==4){if(t=(sv(0,r.length),r.charCodeAt(0)),t==43)return UHt;if(t==45)return HHt}else if(n==3)return UHt}return new jge(r)}function Bat(e){var t,n=e.l,r;return n&n-1||(r=e.m,r&r-1)||(t=e.h,t&t-1)||t==0&&r==0&&n==0?-1:t==0&&r==0&&n!=0?lJe(n):t==0&&r!=0&&n==0?lJe(r)+22:t!=0&&r==0&&n==0?lJe(t)+44:-1}function Bj(e,t){var n,r,i=t.a&e.f,a=null,o;for(r=e.b[i];;r=r.b){if(r==t){a?a.b=t.b:e.b[i]=t.b;break}a=r}for(o=t.f&e.f,a=null,n=e.c[o];;n=n.d){if(n==t){a?a.d=t.d:e.c[o]=t.d;break}a=n}t.e?t.e.c=t.c:e.a=t.c,t.c?t.c.e=t.e:e.e=t.e,--e.i,++e.g}function Vat(e,t){var n;t.d?t.d.b=t.b:e.a=t.b,t.b?t.b.d=t.d:e.e=t.d,!t.e&&!t.c?(n=P(Wh(P(My(e.b,t.a),260)),260),n.a=0,++e.c):(n=P(Wh(P(xh(e.b,t.a),260)),260),--n.a,t.e?t.e.c=t.c:n.b=P(Wh(t.c),511),t.c?t.c.e=t.e:n.c=P(Wh(t.e),511)),--e.d}function Hat(e){var t,n=e.o,i,a,o,s,c,l,u,d;for(t=e.p,s=AP,a=xF,c=AP,o=xF,u=0;u0),a.a.Xb(a.c=--a.b),qd(a,i),jd(a.b3&&Ub(e,0,t-3))}function Kat(e){var t,n,r,i;return A(K(e,(mP(),D1)))===A((_T(),g8))?!e.e&&A(K(e,d1))!==A((qC(),eQ)):(r=P(K(e,f1),299),i=ki(Od(K(e,m1)))||A(K(e,h1))===A((bS(),$X)),t=P(K(e,u1),17).a,n=e.a.c.length,!i&&r!=(qC(),eQ)&&(t==0||t>n))}function qat(e){for(var t,n=0;n0);n++);if(n>0&&n0);t++);return t>0&&n>16!=6&&t){if(Pk(e,t))throw E(new Fi(JH+xrt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?b6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,6,r)),r=jDe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,6,t,t))}function Hj(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=3&&t){if(Pk(e,t))throw E(new Fi(JH+ipt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?P6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,12,r)),r=Bd(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t))}function Yat(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=9&&t){if(Pk(e,t))throw E(new Fi(JH+Dlt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?S6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,9,r)),r=Vd(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,9,t,t))}function Uj(e){var t,n,r=Ik(e),i,a=e.j;if(a==null&&r)return e.Jk()?null:r.ik();if(j(r,156)){if(n=r.jk(),n&&(i=n.wi(),i!=e.i)){if(t=P(r,156),t.nk())try{e.g=i.ti(t,a)}catch(t){if(t=ew(t),j(t,82))e.g=null;else throw E(t)}e.i=i}return e.g}return null}function Xat(e){var t=new T;return M(t,new fs(new k(e.c,e.d),new k(e.c+e.b,e.d))),M(t,new fs(new k(e.c,e.d),new k(e.c,e.d+e.a))),M(t,new fs(new k(e.c+e.b,e.d+e.a),new k(e.c+e.b,e.d))),M(t,new fs(new k(e.c+e.b,e.d+e.a),new k(e.c,e.d+e.a))),t}function Zat(e){var t,n,r;if(e==null)return IP;try{return PE(e)}catch(i){if(i=ew(i),j(i,103))return t=i,r=Ha($w(e))+`@`+(n=(yo(),VD(e)>>>0),n.toString(16)),x2e(AXe(),(Co(),`Exception during lenientFormat for `+r),t),`<`+r+` threw `+Ha(t.Rm)+`>`;throw E(i)}}function Qat(e,t,n){var r,i,a;for(a=t.a.ec().Kc();a.Ob();)i=P(a.Pb(),74),r=P(xh(e.b,i),272),!r&&(I_(xA(i))==I_(SA(i))?$ot(e,i,n):xA(i)==I_(SA(i))?xh(e.c,i)==null&&xh(e.b,SA(i))!=null&&Eht(e,i,n,!1):xh(e.d,i)==null&&xh(e.b,xA(i))!=null&&Eht(e,i,n,!0))}function $at(e,t){var n,r,i,a,o,s,c;for(i=e.Kc();i.Ob();)for(r=P(i.Pb(),10),s=new jA,G_(s,r),tj(s,(nP(),X8)),W(s,(Y(),ZQ),(rd(),!0)),o=t.Kc();o.Ob();)a=P(o.Pb(),10),c=new jA,G_(c,a),tj(c,g5),W(c,ZQ,!0),n=new i_,W(n,ZQ,!0),U_(n,s),K_(n,c)}function eot(e,t,n,r){var i=P0e(e,t,n),a=P0e(e,n,t),o=P(xh(e.c,t),118),s=P(xh(e.c,n),118);i1)for(t=Yu((n=new Qr,++e.b,n),e.d),s=dO(a,0);s.b!=s.d.c;)o=P(Lv(s),125),tM(Ao(ko(jo(Oo(new Zr,1),0),t),o))}function iot(e,t,n){var r,i,a,o,s;for(n.Ug(`Breaking Point Removing`,1),e.a=P(K(t,(mP(),S1)),223),a=new w(t.b);a.a>16!=11&&t){if(Pk(e,t))throw E(new Fi(JH+Elt(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?F6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=EO(t,e,10,r)),r=tf(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,11,t,t))}function aot(e){var t,n,r,i;for(r=new EC(new Fn(e.b).a);r.b;)n=MS(r),i=P(n.ld(),12),t=P(n.md(),10),W(t,(Y(),WQ),i),W(i,QQ,t),W(i,jQ,(rd(),!0)),tj(i,P(K(t,TQ),64)),K(t,TQ),W(i.i,(mP(),Q1),(rA(),B8)),P(K(Bh(i.i),OQ),21).Fc((uM(),YZ))}function oot(e,t,n){var r,i,a=0,o=0,s,c;if(e.c)for(c=new w(e.d.i.j);c.aa.a?-1:i.ac){for(u=e.d,e.d=V(SVt,awt,66,2*c+4,0,1),a=0;a=0x8000000000000000?($b(),hG):(i=!1,e<0&&(i=!0,e=-e),r=0,e>=nI&&(r=C_(e/nI),e-=r*nI),n=0,e>=tI&&(n=C_(e/tI),e-=n*tI),t=C_(e),a=vu(t,n,r),i&&ww(a),a)}function bot(e){var t,n,r,i,a=new T;if(Dx(e.b,new qfe(a)),e.b.c.length=0,a.c.length!=0){for(t=(ov(0,a.c.length),P(a.c[0],82)),n=1,r=a.c.length;n=-t&&i==t?new Kc(G(n-1),G(i)):new Kc(G(n),G(i-1))}function wot(){return yP(),U(O(MOt,1),Z,81,0,[_Y,mY,vY,PY,$Y,RY,aX,UY,ZY,kY,qY,HY,QY,TY,sX,cY,KY,tX,FY,eX,lX,YY,lY,XY,uX,rX,cX,IY,SY,LY,NY,oX,fY,bY,BY,dY,VY,jY,EY,WY,OY,hY,pY,MY,DY,GY,iX,uY,JY,AY,zY,CY,xY,nX,yY,wY,gY])}function Tot(e,t,n){e.d=0,e.b=0,t.k==(DA(),YJ)&&n.k==YJ&&P(K(t,(Y(),WQ)),10)==P(K(n,WQ),10)&&(jb(t).j==(nP(),Z8)?uat(e,t,n):uat(e,n,t)),t.k==YJ&&n.k==qJ?jb(t).j==(nP(),Z8)?e.d=1:e.b=1:n.k==YJ&&t.k==qJ&&(jb(n).j==(nP(),Z8)?e.b=1:e.d=1),G4e(e,t,n)}function Eot(e){var t,n,r,i,a,o,s,c,l,u,d=m7e(e);return t=e.a,c=t!=null,c&&sp(d,`category`,e.a),i=eo(new Pn(e.d)),o=!i,o&&(l=new Tn,hx(d,`knownOptions`,l),n=new Ahe(l),ly(new Pn(e.d),n)),a=eo(e.g),s=!a,s&&(u=new Tn,hx(d,`supportedFeatures`,u),r=new jhe(u),ly(e.g,r)),d}function Dot(e){var t,n,r=!1,i,a,o,s,c,l;for(t=336,n=0,a=new cOe(e.length),s=e,c=0,l=s.length;c>16!=7&&t){if(Pk(e,t))throw E(new Fi(JH+get(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?x6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=P(t,54).Rh(e,1,B5,r)),r=jNe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,7,t,t))}function Aot(e,t){var n,r;if(t!=e.Cb||e.Db>>16!=3&&t){if(Pk(e,t))throw E(new Fi(JH+L$e(e)));r=null,e.Cb&&(r=(n=e.Db>>16,n>=0?T6e(e,r):e.Cb.Th(e,-1-n,null,r))),t&&(r=P(t,54).Rh(e,0,G5,r)),r=MNe(e,t,r),r&&r.oj()}else e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,3,t,t))}function Xj(e,t){pM();var n,r,i,a,o,s,c,l,u;return t.d>e.d&&(s=e,e=t,t=s),t.d<63?Rst(e,t):(o=(e.d&-2)<<4,l=TUe(e,o),u=TUe(t,o),r=TN(e,xy(l,o)),i=TN(t,xy(u,o)),c=Xj(l,u),n=Xj(r,i),a=Xj(TN(l,r),TN(i,u)),a=VN(VN(a,c),n),a=xy(a,o),c=xy(c,o<<1),VN(VN(c,a),n))}function Zj(){Zj=C,N0=new Xs(Qbt,0),OMt=new Xs(`LONGEST_PATH`,1),kMt=new Xs(`LONGEST_PATH_SOURCE`,2),A0=new Xs(`COFFMAN_GRAHAM`,3),DMt=new Xs(JR,4),AMt=new Xs(`STRETCH_WIDTH`,5),M0=new Xs(`MIN_WIDTH`,6),k0=new Xs(`BF_MODEL_ORDER`,7),j0=new Xs(`DF_MODEL_ORDER`,8)}function jot(e,t,n){var r,i,a,o=ET(e,n),s=V(UJ,jR,10,t.length,0,1);for(r=0,a=o.Kc();a.Ob();)i=P(a.Pb(),12),ki(Od(K(i,(Y(),jQ))))&&(s[r++]=P(K(i,QQ),10));if(r=0;a+=n?1:-1)o|=t.c.lg(c,a,n,r&&!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,(Y(),i$))))),o|=t.q.ug(c,a,n),o|=Qct(e,c[a],n,r);return Lm(e.c,t),o}function eM(e,t,n){var r,i,a,o,s,c,l,u,d,f;for(u=GBe(e.j),d=0,f=u.length;d1&&(e.a=!0),_Ne(P(n.b,68),$d(xu(P(t.b,68).c),ku(ef(xu(P(n.b,68).a),P(t.b,68).a),i))),ARe(e,t),Iot(e,n)}function Lot(e){var t,n,r,i,a,o,s;for(a=new w(e.a.a);a.a0&&a>0?o.p=t++:r>0?o.p=n++:a>0?o.p=i++:o.p=n++}Vg(),hu(e.j,new Zte)}function zot(e){var t,n=null;t=P(Ep(e.g,0),18);do{if(n=t.d.i,yd(n,(Y(),BQ)))return P(K(n,BQ),12).i;if(n.k!=(DA(),JJ)&&Cj(new pm(Vu(OE(n).a.Kc(),new d))))t=P(by(new pm(Vu(OE(n).a.Kc(),new d))),18);else if(n.k!=JJ)return null}while(n&&n.k!=(DA(),JJ));return n}function Bot(e,t){var n,r,i,a,o,s=t.j,c,l,u;for(o=t.g,c=P(Ep(s,s.c.length-1),113),u=(ov(0,s.c.length),P(s.c[0],113)),l=gk(e,o,c,u),a=1;al&&(c=n,u=i,l=r);t.a=u,t.c=c}function Vot(e,t,n){var r,i,a,o,s,c,l=new Ja(new mme(e));for(o=U(O(EOt,1),Sbt,12,0,[t,n]),s=0,c=o.length;sc-e.b&&sc-e.a&&s0?a.a?(s=a.b.Mf().a,n>s&&(i=(n-s)/2,a.d.b=i,a.d.c=i)):a.d.c=e.s+n:ym(e.u)&&(r=S7e(a.b),r.c<0&&(a.d.b=-r.c),r.c+r.b>a.b.Mf().a&&(a.d.c=r.c+r.b-a.b.Mf().a))}function sst(e,t){var n,r,i,a,o=new T;n=t;do a=P(xh(e.b,n),131),a.B=n.c,a.D=n.d,Mr(o.c,a),n=P(xh(e.k,n),18);while(n);return r=(ov(0,o.c.length),P(o.c[0],131)),r.j=!0,r.A=P(r.d.a.ec().Kc().Pb(),18).c.i,i=P(Ep(o,o.c.length-1),131),i.q=!0,i.C=P(i.d.a.ec().Kc().Pb(),18).d.i,o}function cst(e){var t=P(e.a,17).a,n=P(e.b,17).a;if(t>=0){if(t==n)return new Kc(G(-t-1),G(-t-1));if(t==-n)return new Kc(G(-t),G(n+1))}return r.Math.abs(t)>r.Math.abs(n)?t<0?new Kc(G(-t),G(n)):new Kc(G(-t),G(n+1)):new Kc(G(t+1),G(n))}function lst(e){var t,n=P(K(e,(mP(),M1)),171);t=P(K(e,(Y(),MQ)),311),n==(XE(),h$)?(W(e,M1,v$),W(e,MQ,(Zb(),oQ))):n==_$?(W(e,M1,v$),W(e,MQ,(Zb(),iQ))):t==(Zb(),oQ)?(W(e,M1,h$),W(e,MQ,aQ)):t==iQ&&(W(e,M1,_$),W(e,MQ,aQ))}function rM(){rM=C,O2=new Uie,aPt=vp(new Zh,(vA(),bJ),(yP(),FY)),cPt=tm(vp(new Zh,bJ,YY),SJ,JY),lPt=HD(HD(Go(tm(vp(new Zh,vJ,aX),SJ,iX),xJ),rX),oX),oPt=tm(vp(vp(vp(new Zh,yJ,RY),xJ,BY),xJ,VY),SJ,zY),sPt=tm(vp(vp(new Zh,xJ,VY),xJ,bY),SJ,yY)}function iM(){iM=C,fPt=vp(tm(new Zh,(vA(),SJ),(yP(),CY)),bJ,FY),gPt=HD(HD(Go(tm(vp(new Zh,vJ,aX),SJ,iX),xJ),rX),oX),pPt=tm(vp(vp(vp(new Zh,yJ,RY),xJ,BY),xJ,VY),SJ,zY),hPt=vp(vp(new Zh,bJ,YY),SJ,JY),mPt=tm(vp(vp(new Zh,xJ,VY),xJ,bY),SJ,yY)}function ust(e,t,n,r,i){var a,o;(!gy(t)&&t.c.i.c==t.d.i.c||!WJe(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])),n))&&!gy(t)&&(t.c==i?md(t.a,0,new Vl(n)):up(t.a,new Vl(n)),r&&!mo(e.a,n)&&(o=P(K(t,(mP(),j1)),75),o||(o=new ai,W(t,j1,o)),a=new Vl(n),iy(o,a,o.c.b,o.c),Lm(e.a,a)))}function dst(e,t){var n,r,i,a=nm(bE(uF,ng(nm(bE(t==null?0:US(t),dF)),15)));for(n=a&e.b.length-1,i=null,r=e.b[n];r;i=r,r=r.a)if(r.d==a&&zh(r.i,t))return i?i.a=r.a:e.b[n]=r.a,dve(P(Wh(r.c),604),P(Wh(r.f),604)),Nr(P(Wh(r.b),227),P(Wh(r.e),227)),--e.f,++e.e,!0;return!1}function fst(e){var t,n;for(n=new pm(Vu(DE(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),18),t.c.i.k!=(DA(),KJ))throw E(new zi(LR+xk(e)+`' has its layer constraint set to FIRST, but has at least one incoming edge that does not come from a FIRST_SEPARATE node. That must not happen.`))}function pst(e,t,n){var r,i=K$e(e.Db&254),a,o,s,c,l;if(i==0)e.Eb=n;else{if(i==1)s=V(WW,FP,1,2,5,1),a=pk(e,t),a==0?(s[0]=n,s[1]=e.Eb):(s[0]=e.Eb,s[1]=n);else for(s=V(WW,FP,1,i+1,5,1),o=rS(e.Eb),r=2,c=0,l=0;r<=128;r<<=1)r==t?s[l++]=n:(e.Db&r)!=0&&(s[l++]=o[c++]);e.Eb=s}e.Db|=t}function mst(e,t,n){var i,a,o,s;for(this.b=new T,a=0,i=0,s=new w(e);s.a0&&(o=P(Ep(this.b,0),176),a+=o.o,i+=o.p),a*=2,i*=2,t>1?a=C_(r.Math.ceil(a*t)):i=C_(r.Math.ceil(i/t)),this.a=new iD(a,i)}function hst(e,t,n,i,a,o){var s,c,l,u,d=i,f,p,m,h,g,_,v;for(t.j&&t.o?(m=P(xh(e.f,t.A),60),g=m.d.c+m.d.b,--d):g=t.a.c+t.a.b,f=a,n.q&&n.o?(m=P(xh(e.f,n.C),60),u=m.d.c,++f):u=n.a.c,_=u-g,l=r.Math.max(2,f-d),c=_/l,h=g+c,p=d;p=0;o+=i?1:-1){for(s=t[o],c=r==(nP(),X8)?i?SE(s,r):UE(SE(s,r)):i?UE(SE(s,r)):SE(s,r),a&&(e.c[s.p]=c.gc()),d=c.Kc();d.Ob();)u=P(d.Pb(),12),e.d[u.p]=l++;nw(n,c)}}function vst(e,t,n){var r,i,a=D(N(e.b.Kc().Pb())),o,s,c,l=D(N(OXe(t.b))),u;for(r=ku(xu(e.a),l-n),i=ku(xu(t.a),n-a),u=$d(r,i),ku(u,1/(l-a)),this.a=u,this.b=new T,s=!0,o=e.b.Kc(),o.Pb();o.Ob();)c=D(N(o.Pb())),s&&c-n>AV&&(this.b.Fc(n),s=!1),this.b.Fc(c);s&&this.b.Fc(n)}function yst(e){var t,n,r,i;if(Blt(e,e.n),e.d.c.length>0){for(Ki(e.c);Jrt(e,P(z(new w(e.e.a)),125))>5,i,a,o;if(t&=31,r>=e.d)return e.e<0?(AM(),JTt):(AM(),JG);if(a=e.d-r,i=V(q9,HF,28,a+1,15,1),oet(i,a,e.a,r,t),e.e<0){for(n=0;n0&&e.a[n]<<32-t){for(n=0;n=0?!1:(n=HN((UA(),l9),i,t),!n||(r=n.Ik(),(r>1||r==-1)&&qh(Rb(l9,n))!=3))):!1}function Est(e,t,n,r){var i,a,o,s=cA(P(H((!t.b&&(t.b=new cf(H5,t,4,7)),t.b),0),84)),c=cA(P(H((!t.c&&(t.c=new cf(H5,t,5,8)),t.c),0),84));return I_(s)==I_(c)||Ex(c,s)?null:(o=T_(t),o==n?r:(a=P(xh(e.a,o),10),a&&(i=a.e,i)?i:null))}function Dst(e,t,n){var r,i,a,o,s;for(n.Ug(`Longest path to source layering`,1),e.a=t,s=e.a.a,e.b=V(q9,HF,28,s.c.length,15,1),r=0,o=new w(s);o.a0&&(n[0]+=e.d,s-=n[0]),n[2]>0&&(n[2]+=e.d,s-=n[2]),o=r.Math.max(0,s),n[1]=r.Math.max(n[1],s),FUe(e,ZK,a.c+i.b+n[0]-(n[1]-s)/2,n),t==ZK&&(e.c.b=o,e.c.c=a.c+i.b+(o-s)/2)}function Vst(){this.c=V(Z9,hI,28,(nP(),U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5])).length,15,1),this.b=V(Z9,hI,28,U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5]).length,15,1),this.a=V(Z9,hI,28,U(O(_5,1),TR,64,0,[h5,Z8,X8,m5,g5]).length,15,1),rxe(this.c,cI),rxe(this.b,lI),rxe(this.a,lI)}function oM(e,t,n){var r,i,a,o;if(t<=n?(i=t,a=n):(i=n,a=t),r=0,e.b==null)e.b=V(q9,HF,28,2,15,1),e.b[0]=i,e.b[1]=a,e.c=!0;else{if(r=e.b.length,e.b[r-1]+1==i){e.b[r-1]=a;return}o=V(q9,HF,28,r+2,15,1),tN(e.b,0,o,0,r),e.b=o,e.b[r-1]>=i&&(e.c=!1,e.a=!1),e.b[r++]=i,e.b[r]=a,e.c||kj(e)}}function Hst(e,t,n){var r,i,a,o,s,c,l=t.d;for(e.a=new Hy(l.c.length),e.c=new Dr,s=new w(l);s.a=0?e.Lh(l,!1,!0):mj(e,n,!1),61));n:for(a=d.Kc();a.Ob();){for(i=P(a.Pb(),58),u=0;u1;)lM(i,i.i-1);return r}function Yst(e,t){var n=new Iu,r,i,a,o,s,c;for(a=new w(e.b);a.ae.d[o.p]&&(n+=$He(e.b,a),Rv(e.a,G(a)));for(;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function Zst(e){var t,n,r,i,a,o,s,c,l;for(e.a=new Zd,l=0,i=0,r=new w(e.i.b);r.ac.d&&(d=c.d+c.a+u));n.c.d=d,t.a.zc(n,t),l=r.Math.max(l,n.c.d+n.c.a)}return l}function uM(){uM=C,WZ=new Gs(`COMMENTS`,0),KZ=new Gs(`EXTERNAL_PORTS`,1),qZ=new Gs(`HYPEREDGES`,2),JZ=new Gs(`HYPERNODES`,3),YZ=new Gs(`NON_FREE_PORTS`,4),XZ=new Gs(`NORTH_SOUTH_PORTS`,5),QZ=new Gs(Bbt,6),UZ=new Gs(`CENTER_LABELS`,7),GZ=new Gs(`END_LABELS`,8),ZZ=new Gs(`PARTITIONS`,9)}function ect(e,t,n,r,i){return r<0?(r=LA(e,i,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF]),t),r<0&&(r=LA(e,i,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]),t)),r<0?!1:(n.k=r,!0)):r>0&&(n.k=r-1,!0)}function tct(e,t,n,r,i){return r<0?(r=LA(e,i,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF]),t),r<0&&(r=LA(e,i,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]),t)),r<0?!1:(n.k=r,!0)):r>0&&(n.k=r-1,!0)}function nct(e,t,n,r,i,a){var o,s=32,c,l;if(r<0){if(t[0]>=e.length||(s=mg(e,t[0]),s!=43&&s!=45)||(++t[0],r=lj(e,t),r<0))return!1;s==45&&(r=-r)}return s==32&&t[0]-n==2&&i.b==2&&(c=new uo,l=c.q.getFullYear()-VF+VF-80,o=l%100,a.a=r==o,r+=(l/100|0)*100+(r=0?yD(e):Xm(yD(kb(e)))),ZG[t]=sl(cm(e,t),0)?yD(cm(e,t)):Xm(yD(kb(cm(e,t)))),e=bE(e,5);for(;t=u&&(l=i);l&&(d=r.Math.max(d,l.a.o.a)),d>p&&(f=u,p=d)}return f}function uct(e){var t,n,r,i,a=new Ja(P(ph(new dt),50)),o,s=lI;for(n=new w(e.d);n.ajxt?hu(l,e.b):i<=jxt&&i>Mxt?hu(l,e.d):i<=Mxt&&i>Nxt?hu(l,e.c):i<=Nxt&&hu(l,e.a),o=pct(e,l,o);return a}function mct(e,t,n,r){var i=(r.c+r.a)/2,a,o,s,c,l;for(Fg(t.j),up(t.j,i),Fg(n.e),up(n.e,i),l=new Xve,s=new w(e.f);s.a1,s&&(r=new k(i,n.b),up(t.a,r)),_S(t.a,U(O(K3,1),X,8,0,[f,d]))}function yct(e,t,n){var r,i;for(t=48;n--)M9[n]=n-48<<24>>24;for(r=70;r>=65;r--)M9[r]=r-65+10<<24>>24;for(i=102;i>=97;i--)M9[i]=i-97+10<<24>>24;for(a=0;a<10;a++)N9[a]=48+a&OF;for(e=10;e<=15;e++)N9[e]=65+e-10&OF}function Sct(e,t){t.Ug(`Process graph bounds`,1),W(e,(tP(),K2),uc(sC(_g(new Mp(null,new cv(e.b,16)),new bae)))),W(e,q2,uc(sC(_g(new Mp(null,new cv(e.b,16)),new xae)))),W(e,zPt,uc(oC(_g(new Mp(null,new cv(e.b,16)),new Sae)))),W(e,BPt,uc(oC(_g(new Mp(null,new cv(e.b,16)),new Cae)))),t.Vg()}function Cct(e){var t,n,i,a=P(K(e,(mP(),W1)),21),o=P(K(e,q1),21);n=new k(e.f.a+e.d.b+e.d.c,e.f.b+e.d.d+e.d.a),t=new Vl(n),a.Hc((TD(),v5))&&(i=P(K(e,K1),8),o.Hc((UM(),T5))&&(i.a<=0&&(i.a=20),i.b<=0&&(i.b=20)),t.a=r.Math.max(n.a,i.a),t.b=r.Math.max(n.b,i.b)),ki(Od(K(e,G1)))||qft(e,n,t)}function wct(e,t){var n,r,i,a;for(a=SE(t,(nP(),m5)).Kc();a.Ob();)r=P(a.Pb(),12),n=P(K(r,(Y(),QQ)),10),n&&tM(Ao(ko(jo(Oo(new Zr,0),.1),e.i[t.p].d),e.i[n.p].a));for(i=SE(t,Z8).Kc();i.Ob();)r=P(i.Pb(),12),n=P(K(r,(Y(),QQ)),10),n&&tM(Ao(ko(jo(Oo(new Zr,0),.1),e.i[n.p].d),e.i[t.p].a))}function _M(e){var t,n,r,i,a,o;if(!e.c){if(o=new Hse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(Jv(e));r.e!=r.i.gc();)n=P(gO(r),89),i=ZM(n),j(i,90)&&th(o,_M(P(i,29))),tb(o,n);t.a.Bc(e),t.a.gc()}l0e(o),Kw(o),e.c=new El((P(H(R((vh(),z7).o),15),19),o.i),o.g),_y(e).b&=-33}return e.c}function Tct(e){var t;if(e.c!=10)throw E(new Ui(TP((fu(),TU))));switch(t=e.a,t){case 110:t=10;break;case 114:t=13;break;case 116:t=9;break;case 92:case 124:case 46:case 94:case 45:case 63:case 42:case 43:case 123:case 125:case 40:case 41:case 91:case 93:break;default:throw E(new Ui(TP((fu(),MU))))}return t}function Ect(e){var t,n,r,i,a;if(e.l==0&&e.m==0&&e.h==0)return`0`;if(e.h==eI&&e.m==0&&e.l==0)return`-9223372036854775808`;if(e.h>>19)return`-`+Ect(mw(e));for(n=e,r=``;n.l!=0||n.m!=0||n.h!=0;){if(i=Cy(rI),n=_mt(n,i,!0),t=``+iye(mG),n.l!=0||n.m!=0||n.h!=0)for(a=9-t.length;a>0;a--)t=`0`+t;r=t+r}return r}function Dct(e){var t=!1,n=0,r,i,a,o,s;for(i=new w(e.d.b);i.a=e.a||!U5e(t,n))return-1;if(Iv(P(i.Kb(t),20)))return 1;for(a=0,s=P(i.Kb(t),20).Kc();s.Ob();)if(o=P(s.Pb(),18),l=o.c.i==t?o.d.i:o.c.i,c=jct(e,l,n,i),c==-1||(a=r.Math.max(a,c),a>e.c-1))return-1;return a+1}function Mct(e,t){var n,r,i,a,o,s;if(A(t)===A(e))return!0;if(!j(t,15)||(r=P(t,15),s=e.gc(),r.gc()!=s))return!1;if(o=r.Kc(),e.Yi()){for(n=0;n0){if(e._j(),t!=null){for(a=0;a>24;case 97:case 98:case 99:case 100:case 101:case 102:return e-97+10<<24>>24;case 65:case 66:case 67:case 68:case 69:case 70:return e-65+10<<24>>24;default:throw E(new aa(`Invalid hexadecimal`))}}function vM(){vM=C,qK=new ps(`SPIRAL`,0),HK=new ps(`LINE_BY_LINE`,1),UK=new ps(`MANHATTAN`,2),VK=new ps(`JITTER`,3),GK=new ps(`QUADRANTS_LINE_BY_LINE`,4),KK=new ps(`QUADRANTS_MANHATTAN`,5),WK=new ps(`QUADRANTS_JITTER`,6),BK=new ps(`COMBINE_LINE_BY_LINE_MANHATTAN`,7),zK=new ps(`COMBINE_JITTER_MANHATTAN`,8)}function Lct(e,t,n,r){var i,a,o,s,c=Gk(e,n),l=Gk(t,n);for(i=!1;c&&l&&(r||B3e(c,l,n));)o=Gk(c,n),s=Gk(l,n),Fb(t),Fb(e),a=c.c,WN(c,!1),WN(l,!1),n?(Ak(t,l.p,a),t.p=l.p,Ak(e,c.p+1,a),e.p=c.p):(Ak(e,c.p,a),e.p=c.p,Ak(t,l.p+1,a),t.p=l.p),W_(c,null),W_(l,null),c=o,l=s,i=!0;return i}function Rct(e){switch(e.g){case 0:return new Cue;case 1:return new xue;case 3:return new Lbe;case 4:return new cie;case 5:return new rOe;case 6:return new Sue;case 2:return new bue;case 7:return new mue;case 8:return new gue;default:throw E(new Fi(`No implementation is available for the layerer `+(e.f==null?``+e.g:e.f)))}}function zct(e,t,n,r){var i=!1,a=!1,o,s,c;for(s=new w(r.j);s.a=t.length)throw E(new Mi(`Greedy SwitchDecider: Free layer not in graph.`));this.c=t[e],this.e=new hf(r),RS(this.e,this.c,(nP(),g5)),this.i=new hf(r),RS(this.i,this.c,X8),this.f=new YMe(this.c),this.a=!a&&i.i&&!i.s&&this.c[0].k==(DA(),GJ),this.a&&Eet(this,e,t.length)}function Uct(e,t){var n,r,i,a=!e.B.Hc((UM(),C5)),o=e.B.Hc(E5),s;e.a=new d0e(o,a,e.c),e.n&&Lg(e.a.n,e.n),Oi(e.g,(Ix(),ZK),e.a),t||(r=new $D(1,a,e.c),r.n.a=e.k,zm(e.p,(nP(),Z8),r),i=new $D(1,a,e.c),i.n.d=e.k,zm(e.p,m5,i),s=new $D(0,a,e.c),s.n.c=e.k,zm(e.p,g5,s),n=new $D(0,a,e.c),n.n.b=e.k,zm(e.p,X8,n))}function Wct(e){var t=P(K(e.d,(mP(),S1)),223),n,r;switch(t.g){case 2:n=B_t(e);break;case 3:n=(r=new T,To(hg(gg(ox(ox(new Mp(null,new cv(e.d.b,16)),new pre),new mre),new hre),new ere),new Wpe(r)),r);break;default:throw E(new Ii(`Compaction not supported for `+t+` edges.`))}rmt(e,n),ly(new Pn(e.g),new Hpe(e))}function Gct(e,t){var n,r,i,a,o,s,c;if(t.Ug(`Process directions`,1),n=P(K(e,(rN(),c4)),88),n!=(GT(),e8))for(i=dO(e.b,0);i.b!=i.d.c;){switch(r=P(Lv(i),40),s=P(K(r,(tP(),o4)),17).a,c=P(K(r,s4),17).a,n.g){case 4:c*=-1;break;case 1:a=s,s=c,c=a;break;case 2:o=s,s=-c,c=o}W(r,o4,G(s)),W(r,s4,G(c))}t.Vg()}function Kct(e,t){var n=new Ot;return t&&VC(n,P(xh(e.a,B5),96)),j(t,422)&&VC(n,P(xh(e.a,V5),96)),j(t,366)?(VC(n,P(xh(e.a,Q5),96)),n):(j(t,84)&&VC(n,P(xh(e.a,H5),96)),j(t,207)?(VC(n,P(xh(e.a,$5),96)),n):j(t,193)?(VC(n,P(xh(e.a,e7),96)),n):(j(t,326)&&VC(n,P(xh(e.a,U5),96)),n))}function qct(e){var t,n,r,i,a,o,s,c=new rUe;for(s=new w(e.a);s.a0&&t=0)return!1;if(t.p=n.b,M(n.e,t),i==(DA(),qJ)||i==YJ){for(o=new w(t.j);o.ae.d[s.p]&&(n+=$He(e.b,a),Rv(e.a,G(a)))):++o;for(n+=e.b.d*o;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function glt(e){var t,n,r,i,a=0,o;return t=Ik(e),t.kk()&&(a|=4),(e.Bb&RU)!=0&&(a|=2),j(e,102)?(n=P(e,19),i=qO(n),(n.Bb&GH)!=0&&(a|=32),i&&(bh(L_(i)),a|=8,o=i.t,(o>1||o==-1)&&(a|=16),(i.Bb&GH)!=0&&(a|=64)),(n.Bb&pI)!=0&&(a|=zU),a|=pF):j(t,469)?a|=512:(r=t.kk(),r&&r.i&1&&(a|=256)),e.Bb&512&&(a|=128),a}function _lt(e,t){var n;return e.f==f9?(n=qh(Rb((UA(),l9),t)),e.e?n==4&&t!=(gj(),g9)&&t!=(gj(),p9)&&t!=(gj(),m9)&&t!=(gj(),h9):n==2):e.d&&(e.d.Hc(t)||e.d.Hc(mv(Rb((UA(),l9),t)))||e.d.Hc(HN((UA(),l9),e.b,t)))?!0:e.f&&cot((UA(),e.f),ug(Rb(l9,t)))?(n=qh(Rb(l9,t)),e.e?n==4:n==2):!1}function vlt(e){var t,n,r,i,a,o,s,c,l,u,d,f=-1,p=0;for(l=e,u=0,d=l.length;u0&&++p;++f}return p}function ylt(e,t,n,i){var a,o,s=P(J(n,(vP(),V6)),8),c,l=s.a,u,d=s.b+e,f;return a=r.Math.atan2(d,l),a<0&&(a+=JV),a+=t,a>JV&&(a-=JV),c=P(J(i,V6),8),u=c.a,f=c.b+e,o=r.Math.atan2(f,u),o<0&&(o+=JV),o+=t,o>JV&&(o-=JV),uu(),fS(1e-10),r.Math.abs(a-o)<=1e-10||a==o||isNaN(a)&&isNaN(o)?0:ao?1:Pl(isNaN(a),isNaN(o))}function wM(e){var t,n,r,i,a,o,s=new Dr;for(r=new w(e.a.b);r.a=e.o)throw E(new e_e);s=t>>5,o=t&31,a=cm(1,nm(cm(o,1))),i?e.n[n][s]=dv(e.n[n][s],a):e.n[n][s]=uv(e.n[n][s],Wje(a)),a=cm(a,1),r?e.n[n][s]=dv(e.n[n][s],a):e.n[n][s]=uv(e.n[n][s],Wje(a))}catch(r){throw r=ew(r),j(r,333)?E(new Mi(SL+e.o+`*`+e.p+CL+t+PP+n+wL)):E(r)}}function Slt(e,t,n,r){var i,a,o,s,c,l,u,d,f=new Ja(new pme(e));for(s=U(O(UJ,1),jR,10,0,[t,n]),c=0,l=s.length;c0&&(r=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!r||gl(gl((t.a+=` "`,t),r),`"`))),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function Dlt(e){var t,n,r;return e.Db&64?AA(e):(t=new Gu(ZSt),n=e.k,n?gl(gl((t.a+=` "`,t),n),`"`):(!e.n&&(e.n=new F(Q5,e,1,7)),e.n.i>0&&(r=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!r||gl(gl((t.a+=` "`,t),r),`"`))),gl(Ka(gl(Ka(gl(Ka(gl(Ka((t.a+=` (`,t),e.i),`,`),e.j),` | `),e.g),`,`),e.f),`)`),t.a)}function Olt(e,t){var n,r,i,a,o;for(t==(Nw(),o2)&&JA(P(Dy(e.a,(tA(),TX)),15)),i=P(Dy(e.a,(tA(),TX)),15).Kc();i.Ob();)switch(r=P(i.Pb(),105),n=P(Ep(r.j,0),113).d.j,a=new bf(r.j),hu(a,new Sre),t.g){case 2:lA(e,a,n,(kS(),AX),1);break;case 1:case 0:o=qat(a),lA(e,new $_(a,0,o),n,(kS(),AX),0),lA(e,new $_(a,o,a.c.length),n,AX,1)}}function DM(e,t){var n,r,i,a,o,s,c;if(t==null||t.length==0)return null;if(i=P(v_(e.a,t),143),!i){for(r=(s=new Bn(e.b).a.vc().Kc(),new Vn(s));r.a.Ob();)if(n=(a=P(r.a.Pb(),44),P(a.md(),143)),o=n.c,c=t.length,ff(o.substr(o.length-c,c),t)&&(t.length==o.length||mg(o,o.length-t.length-1)==46)){if(i)return null;i=n}i&&H_(e.a,t,i)}return i}function klt(e,t){var n=new _t,r=P(ay(gg(new Mp(null,new cv(e.f,16)),n),Eb(new Ee,new De,new Pe,new Fe,U(O(xK,1),Z,108,0,[(Zw(),bK),yK]))),21),i=r.gc(),a;return r=P(ay(gg(new Mp(null,new cv(t.f,16)),n),Eb(new Ee,new De,new Pe,new Fe,U(O(xK,1),Z,108,0,[bK,yK]))),21),a=r.gc(),ii.p?(tj(a,m5),a.d&&(s=a.o.b,t=a.a.b,a.a.b=s-t)):a.j==m5&&i.p>e.p&&(tj(a,Z8),a.d&&(s=a.o.b,t=a.a.b,a.a.b=-(s-t)));break}return i}function OM(e,t,n,r,i){var a,o,s,c,l,u,d;if(!(j(t,207)||j(t,366)||j(t,193)))throw E(new Fi(`Method only works for ElkNode-, ElkLabel and ElkPort-objects.`));return o=e.a/2,c=t.i+r-o,u=t.j+i-o,l=c+t.g+e.a,d=u+t.f+e.a,a=new ai,up(a,new k(c,u)),up(a,new k(c,d)),up(a,new k(l,d)),up(a,new k(l,u)),s=new wj(a),VC(s,t),n&&Qh(e.b,t,s),s}function kM(e,t,n){var r,i,a=new k(t,n),o,s,c,l,u,d,f;for(u=new w(e.a);u.a1,s&&(r=new k(i,n.b),up(t.a,r)),_S(t.a,U(O(K3,1),X,8,0,[f,d]))}function FM(){FM=C,Y0=new ec(wR,0),q0=new ec(`NIKOLOV`,1),J0=new ec(`NIKOLOV_PIXEL`,2),VMt=new ec(`NIKOLOV_IMPROVED`,3),HMt=new ec(`NIKOLOV_IMPROVED_PIXEL`,4),BMt=new ec(`DUMMYNODE_PERCENTAGE`,5),UMt=new ec(`NODECOUNT_PERCENTAGE`,6),X0=new ec(`NO_BOUNDARY`,7),G0=new ec(`MODEL_ORDER_LEFT_TO_RIGHT`,8),K0=new ec(`MODEL_ORDER_RIGHT_TO_LEFT`,9)}function Jlt(e){var t,n,r=e.length,i,a;for(t=new ea,a=0;a=40,o&&Ldt(e),Opt(e),yst(e),n=o1e(e),r=0;n&&r0&&up(e.f,a)):(e.c[o]-=l+1,e.c[o]<=0&&e.a[o]>0&&up(e.e,a))))}function but(e,t,n,r){var i,a,o,s,c=new k(n,r),l,u;for(ef(c,P(K(t,(tP(),H2)),8)),u=dO(t.b,0);u.b!=u.d.c;)l=P(Lv(u),40),$d(l.e,c),up(e.b,l);for(s=P(ay(gRe(new Mp(null,new cv(t.a,16))),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15).Kc();s.Ob();){for(o=P(s.Pb(),65),a=dO(o.a,0);a.b!=a.d.c;)i=P(Lv(a),8),i.a+=c.a,i.b+=c.b;up(e.a,o)}}function xut(e,t){var n,r,i,a;if(0<(j(e,16)?P(e,16).gc():Wv(e.Kc()))){if(i=t,1=0&&ca*2?(u=new Fx(d),l=Lp(o)/Ip(o),c=cP(u,t,new ni,n,r,i,l),$d(Cl(u.e),c),d.c.length=0,a=0,Mr(d.c,u),Mr(d.c,o),a=Lp(u)*Ip(u)+Lp(o)*Ip(o)):(Mr(d.c,o),a+=Lp(o)*Ip(o));return d}function Eut(e,t){var n,r,i,a,o,s=P(K(t,(mP(),Q1)),101);if(s==(rA(),z8)||s==R8)for(i=new k(t.f.a+t.d.b+t.d.c,t.f.b+t.d.d+t.d.a).b,o=new w(e.a);o.an?t:n;l<=d;++l)l==n?s=r++:(a=i[l],u=m.am(a.Lk()),l==t&&(c=l==d&&!u?r-1:r),u&&++r);return f=P(QT(e,t,n),76),s!=c&&Kr(e,new db(e.e,7,o,G(s),p.md(),c)),f}}else return P(dj(e,t,n),76);return P(QT(e,t,n),76)}function Out(e,t){var n,r,i,a,o,s,c;for(t.Ug(`Port order processing`,1),c=P(K(e,(mP(),oMt)),430),r=new w(e.b);r.a=0&&(s=q3e(e,o),!(s&&(l<22?c.l|=1<>>1,o.m=u>>>1|(d&1)<<21,o.l=f>>>1|(u&1)<<21,--l;return n&&ww(c),a&&(r?(mG=mw(e),i&&(mG=NXe(mG,($b(),gG)))):mG=vu(e.l,e.m,e.h)),c}function Mut(e,t){var n,r,i,a,o,s,c,l=e.e[t.c.p][t.p]+1,u,d;for(c=t.c.a.c.length+1,s=new w(e.a);s.a0&&(sv(0,e.length),e.charCodeAt(0)==45||(sv(0,e.length),e.charCodeAt(0)==43))),r=o;rn)throw E(new aa(sI+e+`"`));return s}function Nut(e){var t,n,i,a,o,s=new vo,c;for(o=new w(e.a);o.a1)&&t==1&&P(e.a[e.b],10).k==(DA(),KJ)?hN(P(e.a[e.b],10),(kk(),y8)):r&&(!n||(e.c-e.b&e.a.length-1)>1)&&t==1&&P(e.a[e.c-1&e.a.length-1],10).k==(DA(),KJ)?hN(P(e.a[e.c-1&e.a.length-1],10),(kk(),b8)):(e.c-e.b&e.a.length-1)==2?(hN(P(yw(e),10),(kk(),y8)),hN(P(yw(e),10),b8)):eat(e,i),uHe(e)}function Lut(e,t,n){var i,a,o=0,s,c;for(a=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));a.e!=a.i.gc();)i=P(gO(a),27),s=``,(!i.n&&(i.n=new F(Q5,i,1,7)),i.n).i==0||(s=P(H((!i.n&&(i.n=new F(Q5,i,1,7)),i.n),0),135).a),c=new Ow(o++,t,s),VC(c,i),W(c,(tP(),t4),i),c.e.b=i.j+i.f/2,c.f.a=r.Math.max(i.g,1),c.e.a=i.i+i.g/2,c.f.b=r.Math.max(i.f,1),up(t.b,c),XA(n.f,i,c)}function Rut(e){var t,n,r=P(K(e,(Y(),WQ)),27),i,a=P(J(r,(mP(),W1)),181).Hc((TD(),x5));e.e||(i=P(K(e,OQ),21),t=new k(e.f.a+e.d.b+e.d.c,e.f.b+e.d.d+e.d.a),i.Hc((uM(),KZ))?(OO(r,Q1,(rA(),R8)),iP(r,t.a,t.b,!1,!0)):ki(Od(J(r,G1)))||iP(r,t.a,t.b,!0,!0)),a?OO(r,W1,sE(x5)):OO(r,W1,(n=P(Ba(S5),9),new xf(n,P(Yd(n,n.length),9),0)))}function zut(e,t,n){var r,i,a,o;if(t[0]>=e.length)return n.o=0,!0;switch(mg(e,t[0])){case 43:i=1;break;case 45:i=-1;break;default:return n.o=0,!0}if(++t[0],a=t[0],o=lj(e,t),o==0&&t[0]==a)return!1;if(t[0]s&&(s=i,u.c.length=0),i==s&&M(u,new Kc(n.c.i,n)));Vg(),hu(u,e.c),Jp(e.b,c.p,u)}}function Uut(e,t){var n,r,i,a,o,s,c,l,u;for(o=new w(t.b);o.as&&(s=i,u.c.length=0),i==s&&M(u,new Kc(n.d.i,n)));Vg(),hu(u,e.c),Jp(e.f,c.p,u)}}function Wut(e,t){var n,r,i,a,o,s,c,l=Od(K(t,(rN(),gFt)));if(l==null||(Gh(l),l)){for(grt(e,t),i=new T,c=dO(t.b,0);c.b!=c.d.c;)o=P(Lv(c),40),n=Let(e,o,null),n&&(VC(n,t),Mr(i.c,n));if(e.a=null,e.b=null,i.c.length>1)for(r=new w(i);r.a=0&&s!=n&&(a=new Sm(e,1,s,o,null),r?r.nj(a):r=a),n>=0&&(a=new Sm(e,1,n,s==n?o:null,t),r?r.nj(a):r=a)),r}function qut(e){var t,n,r;if(e.b==null){if(r=new $i,e.i!=null&&(pl(r,e.i),r.a+=`:`),e.f&256){for(e.f&256&&e.a!=null&&(nIe(e.i)||(r.a+=`//`),pl(r,e.a)),e.d!=null&&(r.a+=`/`,pl(r,e.d)),e.f&16&&(r.a+=`/`),t=0,n=e.j.length;tf?!1:(d=(c=vN(r,f,!1),c.a),u+s+d<=t.b&&(fb(n,a-n.s),n.c=!0,fb(r,a-n.s),WO(r,n.s,n.t+n.d+s),r.k=!0,gC(n.q,r),p=!0,i&&(hS(t,r),r.j=t,e.c.length>o&&(Fk((ov(o,e.c.length),P(e.c[o],186)),r),(ov(o,e.c.length),P(e.c[o],186)).a.c.length==0&&Ay(e,o)))),p)}function edt(e,t){var n,r,i,a,o,s;if(t.Ug(`Partition midprocessing`,1),i=new g_,To(hg(new Mp(null,new cv(e.a,16)),new $te),new jpe(i)),i.d!=0){for(s=P(ay(gze((a=i.i,new Mp(null,(a||(i.i=new zu(i,i.c))).Nc()))),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),r=s.Kc(),n=P(r.Pb(),17);r.Ob();)o=P(r.Pb(),17),$at(P(Dy(i,n),21),P(Dy(i,o),21)),n=o;t.Vg()}}function tdt(e,t,n){var r,i,a,o,s,c,l,u;if(t.p==0){for(t.p=1,o=n,o||=(i=new T,a=(r=P(Ba(_5),9),new xf(r,P(Yd(r,r.length),9),0)),new Kc(i,a)),P(o.a,15).Fc(t),t.k==(DA(),GJ)&&P(o.b,21).Fc(P(K(t,(Y(),TQ)),64)),c=new w(t.j);c.a0){if(i=P(e.Ab.g,2033),t==null){for(a=0;an.s&&co)return nP(),X8;break;case 4:case 3:if(u<0)return nP(),Z8;if(u+n>a)return nP(),m5}return c=(l+s/2)/o,r=(u+n/2)/a,c+r<=1&&c-r<=0?(nP(),g5):c+r>=1&&c-r>=0?(nP(),X8):r<.5?(nP(),Z8):(nP(),m5)}function udt(e,t){var n=!1,r,i,a,o,s,c,l,u=D(N(K(t,(mP(),v0)))),d,f,p,m=bF*u,h;for(i=new w(t.b);i.ac+m&&(h=d.g+f.g,f.a=(f.g*f.a+d.g*d.a)/h,f.g=h,d.f=f,n=!0)),a=s,d=f;return n}function ddt(e,t,n,r,i,a,o){var s,c,l,u,d,f=new Ul;for(l=t.Kc();l.Ob();)for(s=P(l.Pb(),853),d=new w(s.Rf());d.a0?c.a?(u=c.b.Mf().b,a>u&&(e.v||c.c.d.c.length==1?(s=(a-u)/2,c.d.d=s,c.d.a=s):(n=P(Ep(c.c.d,0),187).Mf().b,i=(n-u)/2,c.d.d=r.Math.max(0,i),c.d.a=a-i-u))):c.d.a=e.t+a:ym(e.u)&&(o=S7e(c.b),o.d<0&&(c.d.d=-o.d),o.d+o.a>c.b.Mf().b&&(c.d.a=o.d+o.a-c.b.Mf().b))}function XM(){XM=C,Xq=new ou((vP(),H6),G(1)),$q=new ou(J6,80),WDt=new ou(Hzt,5),PDt=new ou(c6,JL),HDt=new ou(U6,G(1)),UDt=new ou(G6,(rd(),!0)),Jq=new iu(50),BDt=new ou(A6,Jq),Wq=y6,Yq=I6,FDt=new ou(m6,!1),qq=k6,RDt=T6,zDt=D6,LDt=w6,IDt=C6,VDt=z6,Kq=(I9e(),DDt),eJ=jDt,Gq=EDt,Zq=ODt,Qq=ADt,qDt=Z6,JDt=$6,KDt=X6,GDt=Y6,tJ=(gT(),M5),new ou(Q6,tJ)}function mdt(e,t){var n;switch(lx(e)){case 6:return rl(t);case 7:return al(t);case 8:return il(t);case 3:return Array.isArray(t)&&(n=lx(t),!(n>=14&&n<=16));case 11:return t!=null&&typeof t===kP;case 12:return t!=null&&(typeof t===EP||typeof t==kP);case 0:return kO(t,e.__elementTypeId$);case 2:return Nm(t)&&t.Tm!==ne;case 1:return Nm(t)&&t.Tm!==ne||kO(t,e.__elementTypeId$);default:return!0}}function hdt(e){var t,n,i=e.o,a;Rd(),e.A.dc()||NT(e.A,lq)?a=i.a:(a=e.D?r.Math.max(i.a,oj(e.f)):oj(e.f),e.A.Hc((TD(),y5))&&!e.B.Hc((UM(),O5))&&(a=r.Math.max(a,oj(P(ig(e.p,(nP(),Z8)),252))),a=r.Math.max(a,oj(P(ig(e.p,m5),252)))),t=YYe(e),t&&(a=r.Math.max(a,t.a))),i.a=ki(Od(e.e.Tf().of((vP(),T6))))?r.Math.max(i.a,a):a,n=e.f.i,n.c=0,n.b=a,iN(e.f)}function gdt(e,t){var n,i=r.Math.min(r.Math.abs(e.c-(t.c+t.b)),r.Math.abs(e.c+e.b-t.c)),a,o=r.Math.min(r.Math.abs(e.d-(t.d+t.a)),r.Math.abs(e.d+e.a-t.d));return n=r.Math.abs(e.c+e.b/2-(t.c+t.b/2)),n>e.b/2+t.b/2||(a=r.Math.abs(e.d+e.a/2-(t.d+t.a/2)),a>e.a/2+t.a/2)?1:n==0&&a==0?0:n==0?o/a+1:a==0?i/n+1:r.Math.min(i/n,o/a)+1}function _dt(e,t){var n,r,i,a=0,o,s=0,c=0;for(i=new w(e.f.e);i.a0&&e.d!=(Yb(),gJ)&&(s+=o*(r.d.a+e.a[t.a][r.a]*(t.d.a-r.d.a)/n)),n>0&&e.d!=(Yb(),mJ)&&(c+=o*(r.d.b+e.a[t.a][r.a]*(t.d.b-r.d.b)/n)));switch(e.d.g){case 1:return new k(s/a,t.d.b);case 2:return new k(t.d.a,c/a);default:return new k(s/a,c/a)}}function vdt(e){var t,n=(!e.a&&(e.a=new ju(z5,e,5)),e.a).i+2,r,i,a,o=new Hy(n);for(M(o,new k(e.j,e.k)),To(new Mp(null,(!e.a&&(e.a=new ju(z5,e,5)),new cv(e.a,16))),new rhe(o)),M(o,new k(e.b,e.c)),t=1;t0&&(fw(c,!1,(GT(),t8)),fw(c,!0,n8)),Dx(t.g,new Pxe(e,n)),Qh(e.g,t,n)}function xdt(){xdt=C;var e;for(jG=U(O(q9,1),HF,28,15,[-1,-1,30,19,15,13,11,11,10,9,9,8,8,8,8,7,7,7,7,7,7,7,6,6,6,6,6,6,6,6,6,6,6,6,6,6,5]),MG=V(q9,HF,28,37,15,1),WTt=U(O(q9,1),HF,28,15,[-1,-1,63,40,32,28,25,23,21,20,19,19,18,18,17,17,16,16,16,15,15,15,15,14,14,14,14,14,14,13,13,13,13,13,13,13,13]),NG=V(Y9,dI,28,37,14,1),e=2;e<=36;e++)MG[e]=C_(r.Math.pow(e,jG[e])),NG[e]=Wk(tF,MG[e])}function Sdt(e){var t;if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i!=1)throw E(new Fi(BSt+(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i));return t=new ai,tw(P(H((!e.b&&(e.b=new cf(H5,e,4,7)),e.b),0),84))&&XS(t,lvt(e,tw(P(H((!e.b&&(e.b=new cf(H5,e,4,7)),e.b),0),84)),!1)),tw(P(H((!e.c&&(e.c=new cf(H5,e,5,8)),e.c),0),84))&&XS(t,lvt(e,tw(P(H((!e.c&&(e.c=new cf(H5,e,5,8)),e.c),0),84)),!0)),t}function Cdt(e,t){var n,r,i=t.d?e.a.c==(O_(),w2)?DE(t.b):OE(t.b):e.a.c==(O_(),C2)?DE(t.b):OE(t.b),a=!1,o;for(r=new pm(Vu(i.a.Kc(),new d));Cj(r);)if(n=P(by(r),18),o=ki(e.a.f[e.a.g[t.b.p].p]),!(!o&&!gy(n)&&n.c.i.c==n.d.i.c)&&!(ki(e.a.n[e.a.g[t.b.p].p])||ki(e.a.n[e.a.g[t.b.p].p]))&&(a=!0,mo(e.b,e.a.g[m3e(n,t.b).p])))return t.c=!0,t.a=n,t;return t.c=a,t.a=null,t}function wdt(e,t,n){var r=n.gc(),i,a,o,s,c,l;if(r==0)return!1;if(e.Pj()){if(c=e.Qj(),$E(e,t,n),o=r==1?e.Ij(3,null,n.Kc().Pb(),t,c):e.Ij(5,null,n,t,c),e.Mj()){for(s=r<100?null:new Pa(r),a=t+r,i=t;i0){for(s=0;s>16==-15&&e.Cb.Yh()&&Pb(new ub(e.Cb,9,13,n,e.c,NO(Ib(P(e.Cb,62)),e))):j(e.Cb,90)&&e.Db>>16==-23&&e.Cb.Yh()&&(t=e.c,j(t,90)||(t=(CP(),J7)),j(n,90)||(n=(CP(),J7)),Pb(new ub(e.Cb,9,10,n,t,NO(Jv(P(e.Cb,29)),e)))))),e.c}function jdt(e,t,n){var r,i,a,o,s,c,l,u,d;for(n.Ug(`Hyperedge merging`,1),uit(e,t),c=new bv(t.b,0);c.b0,s=IE(t,a),JTe(n?s.b:s.g,t),eT(s).c.length==1&&iy(r,s,r.c.b,r.c),i=new Kc(a,t),Rv(e.o,i),Db(e.e.a,a))}function Rdt(e,t){var n,i=r.Math.abs(Mm(e.b).a-Mm(t.b).a),a,o,s,c=r.Math.abs(Mm(e.b).b-Mm(t.b).b),l;return a=0,l=0,n=1,s=1,i>e.b.b/2+t.b.b/2&&(a=r.Math.min(r.Math.abs(e.b.c-(t.b.c+t.b.b)),r.Math.abs(e.b.c+e.b.b-t.b.c)),n=1-a/i),c>e.b.a/2+t.b.a/2&&(l=r.Math.min(r.Math.abs(e.b.d-(t.b.d+t.b.a)),r.Math.abs(e.b.d+e.b.a-t.b.d)),s=1-l/c),o=r.Math.min(n,s),(1-o)*r.Math.sqrt(i*i+c*c)}function zdt(e){var t,n,r,i;for(eP(e,e.e,e.f,(D_(),j2),!0,e.c,e.i),eP(e,e.e,e.f,j2,!1,e.c,e.i),eP(e,e.e,e.f,M2,!0,e.c,e.i),eP(e,e.e,e.f,M2,!1,e.c,e.i),Adt(e,e.c,e.e,e.f,e.i),r=new bv(e.i,0);r.b=65;n--)A9[n]=n-65<<24>>24;for(r=122;r>=97;r--)A9[r]=r-97+26<<24>>24;for(i=57;i>=48;i--)A9[i]=i-48+52<<24>>24;for(A9[43]=62,A9[47]=63,a=0;a<=25;a++)j9[a]=65+a&OF;for(o=26,c=0;o<=51;++o,c++)j9[o]=97+c&OF;for(e=52,s=0;e<=61;++e,s++)j9[e]=48+s&OF;j9[62]=43,j9[63]=47}function Vdt(e,t){var n,i,a=QS(e),o,s,c=QS(t);return a==c?e.e==t.e&&e.a<54&&t.a<54?e.ft.f):(i=e.e-t.e,n=(e.d>0?e.d:r.Math.floor((e.a-1)*dyt)+1)-(t.d>0?t.d:r.Math.floor((t.a-1)*dyt)+1),n>i+1?a:n0&&(s=Uv(s,Mft(i))),q0e(o,s))):au&&(p=0,m+=l+t,l=0),kM(s,p,m),n=r.Math.max(n,p+d.a),l=r.Math.max(l,d.b),p+=d.a+t;return new k(n+t,m+l+t)}function Wdt(e,t){var n,r,i,a,o,s,c;if(!E_(e))throw E(new Ii(zSt));if(r=E_(e),a=r.g,i=r.f,a<=0&&i<=0)return nP(),h5;switch(s=e.i,c=e.j,t.g){case 2:case 1:if(s<0)return nP(),g5;if(s+e.g>a)return nP(),X8;break;case 4:case 3:if(c<0)return nP(),Z8;if(c+e.f>i)return nP(),m5}return o=(s+e.g/2)/a,n=(c+e.f/2)/i,o+n<=1&&o-n<=0?(nP(),g5):o+n>=1&&o-n>=0?(nP(),X8):n<.5?(nP(),Z8):(nP(),m5)}function Gdt(e,t,n,r,i){var a=yE(uv(t[0],_I),uv(r[0],_I)),o;if(e[0]=nm(a),a=lm(a,32),n>=i){for(o=1;o0&&(i.b[o++]=0,i.b[o++]=a.b[0]-1),t=1;t0&&(Dn(c,c.d-i.d),i.c==(Wy(),k2)&&Jde(c,c.a-i.d),c.d<=0&&c.i>0&&iy(t,c,t.c.b,t.c)));for(a=new w(e.f);a.a0&&(On(s,s.i-i.d),i.c==(Wy(),k2)&&Yde(s,s.b-i.d),s.i<=0&&s.d>0&&iy(n,s,n.c.b,n.c)))}function Ydt(e,t,n,r,i){var a,o,s,c,l,u,d,f,p;for(Vg(),hu(e,new gse),o=Zf(e),p=new T,f=new T,s=null,c=0;o.b!=0;)a=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),163),!s||Lp(s)*Ip(s)/21&&(c>Lp(s)*Ip(s)/2||o.b==0)&&(d=new Fx(f),u=Lp(s)/Ip(s),l=cP(d,t,new ni,n,r,i,u),$d(Cl(d.e),l),s=d,Mr(p.c,d),c=0,f.c.length=0));return nw(p,f),p}function tN(e,t,n,r,i){yo();var a,o,s,c,l,u,d;if(Jm(e,`src`),Jm(n,`dest`),d=$w(e),c=$w(n),Rje(!!(d.i&4),`srcType is not an array`),Rje(!!(c.i&4),`destType is not an array`),u=d.c,o=c.c,Rje(u.i&1?u==o:!(o.i&1),`Array types don't match`),CZe(e,t,n,r,i),!(u.i&1)&&d!=c){if(l=rS(e),a=rS(n),A(e)===A(n)&&tr;)Sh(a,s,l[--t]);else for(s=r+i;r0),r.a.Xb(r.c=--r.b),d>f+c&&Fh(r);for(o=new w(p);o.a0),r.a.Xb(r.c=--r.b)}}function Qdt(){xP();var e,t,n,r,i,a;if(V9)return V9;for(e=(++W9,new pv(4)),DN(e,oP(zW,!0)),KN(e,oP(`M`,!0)),KN(e,oP(`C`,!0)),a=(++W9,new pv(4)),r=0;r<11;r++)oM(a,r,r);return t=(++W9,new pv(4)),DN(t,oP(`M`,!0)),oM(t,4448,4607),oM(t,65438,65439),i=(++W9,new lu(2)),LN(i,e),LN(i,B9),n=(++W9,new lu(2)),n.Jm(Rp(a,oP(`L`,!0))),n.Jm(t),n=(++W9,new Zv(3,n)),n=(++W9,new Km(i,n)),V9=n,V9}function nN(e,t){var n=new RegExp(t,`g`),r,i,a,o,s,c=V(LG,X,2,0,6,1),l;for(r=0,l=e,a=null;;){if(s=n.exec(l),s==null||l==``){c[r]=l;break}o=s.index,c[r]=(Zy(0,o,l.length),l.substr(0,o)),l=p_(l,o+s[0].length,l.length),n.lastIndex=0,a==l&&(c[r]=(Zy(0,1,l.length),l.substr(0,1)),l=(sv(1,l.length+1),l.substr(1))),a=l,++r}if(e.length>0){for(i=c.length;i>0&&c[i-1]==``;)--i;i0&&(f-=i[0]+e.c,i[0]+=e.c),i[2]>0&&(f-=i[2]+e.c),i[1]=r.Math.max(i[1],f),Yp(e.a[1],n.c+t.b+i[0]-(i[1]-f)/2,i[1]);for(o=e.a,c=0,u=o.length;c0?(e.n.c.length-1)*e.i:0,i=new w(e.n);i.a1)for(r=dO(i,0);r.b!=r.d.c;)for(n=P(Lv(r),235),a=0,c=new w(n.e);c.a0&&(t[0]+=e.c,f-=t[0]),t[2]>0&&(f-=t[2]+e.c),t[1]=r.Math.max(t[1],f),Xp(e.a[1],i.d+n.d+t[0]-(t[1]-f)/2,t[1]);else for(h=i.d+n.d,m=i.a-n.d-n.a,s=e.a,l=0,d=s.length;l0||CE(a.b.d,e.b.d+e.b.a)==0&&i.b<0||CE(a.b.d+a.b.a,e.b.d)==0&&i.b>0){c=0;break}}else c=r.Math.min(c,ztt(e,a,i));c=r.Math.min(c,oft(e,o,c,i))}return c}function cN(e,t){var n,r,i,a,o,s,c;if(e.b<2)throw E(new Fi(`The vector chain must contain at least a source and a target point.`));for(i=(jd(e.b!=0),P(e.a.a.c,8)),tu(t,i.a,i.b),c=new cd((!t.a&&(t.a=new ju(z5,t,5)),t.a)),o=dO(e,1);o.a=0&&a!=n))throw E(new Fi(vU));for(i=0,c=0;cD(Eu(o.g,o.d[0]).a)?(jd(c.b>0),c.a.Xb(c.c=--c.b),qd(c,o),i=!0):s.e&&s.e.gc()>0&&(a=(!s.e&&(s.e=new T),s.e).Mc(t),l=(!s.e&&(s.e=new T),s.e).Mc(n),(a||l)&&((!s.e&&(s.e=new T),s.e).Fc(o),++o.c));i||Mr(r.c,o)}function uft(e,t,n){var r,i,a,o,s,c,l,u,d=e.a.i+e.a.g/2,f=e.a.i+e.a.g/2,p,m=t.i+t.g/2,h,g=t.j+t.f/2,_;return s=new k(m,g),l=P(J(t,(vP(),V6)),8),l.a+=d,l.b+=f,a=(s.b-l.b)/(s.a-l.a),r=s.b-a*s.a,h=n.i+n.g/2,_=n.j+n.f/2,c=new k(h,_),u=P(J(n,V6),8),u.a+=d,u.b+=f,o=(c.b-u.b)/(c.a-u.a),i=c.b-o*c.a,p=(r-i)/(o-a),l.a>>0,`0`+t.toString(16)),r=`\\x`+p_(n,n.length-2,n.length)):e>=pI?(n=(t=e>>>0,`0`+t.toString(16)),r=`\\v`+p_(n,n.length-6,n.length)):r=``+String.fromCharCode(e&OF)}return r}function vft(e){var t,n,r;if(Kl(P(K(e,(mP(),Q1)),101)))for(n=new w(e.j);n.a=t.o&&n.f<=t.f||t.a*.5<=n.f&&t.a*1.5>=n.f){if(o=P(Ep(t.n,t.n.c.length-1),209),o.e+o.d+n.g+i<=r&&(a=P(Ep(t.n,t.n.c.length-1),209),a.f-e.f+n.f<=e.b||e.a.c.length==1))return ME(t,n),!0;if(t.s+n.g<=r&&(t.t+t.d+n.f+i<=e.b||e.a.c.length==1))return M(t.b,n),s=P(Ep(t.n,t.n.c.length-1),209),M(t.n,new w_(t.s,s.f+s.a+t.i,t.i)),q4e(P(Ep(t.n,t.n.c.length-1),209),n),tft(t,n),!0}return!1}function Sft(e,t,n){var r,i,a,o;return e.Pj()?(i=null,a=e.Qj(),r=e.Ij(1,o=tx(e,t,n),n,t,a),e.Mj()&&!(e.Yi()&&o!=null?NT(o,n):A(o)===A(n))?(o!=null&&(i=e.Oj(o,i)),i=e.Nj(n,i),e.Tj()&&(i=e.Wj(o,n,i)),i?(i.nj(r),i.oj()):e.Jj(r)):(e.Tj()&&(i=e.Wj(o,n,i)),i?(i.nj(r),i.oj()):e.Jj(r)),o):(o=tx(e,t,n),e.Mj()&&!(e.Yi()&&o!=null?NT(o,n):A(o)===A(n))&&(i=null,o!=null&&(i=e.Oj(o,null)),i=e.Nj(n,i),i&&i.oj()),o)}function Cft(e,t){var n,r,i,a,o;if(t.Ug(`Path-Like Graph Wrapping`,1),e.b.c.length==0){t.Vg();return}if(i=new Qrt(e),o=(i.i??(i.i=$S(i,new $re)),D(i.i)*i.f),n=o/(i.i??(i.i=$S(i,new $re)),D(i.i)),i.b>n){t.Vg();return}switch(P(K(e,(mP(),T0)),351).g){case 2:a=new nie;break;case 0:a=new Kre;break;default:a=new rie}if(r=a.og(e,i),!a.pg())switch(P(K(e,D0),352).g){case 2:r=Wtt(i,r);break;case 1:r=S5e(i,r)}Hpt(e,i,r),t.Vg()}function dN(e,t){var n,i,a,o,s,c,l,u;t%=24,e.q.getHours()!=t&&(i=new r.Date(e.q.getTime()),i.setDate(i.getDate()+1),c=e.q.getTimezoneOffset()-i.getTimezoneOffset(),c>0&&(l=c/60|0,u=c%60,a=e.q.getDate(),n=e.q.getHours(),n+l>=24&&++a,o=new r.Date(e.q.getFullYear(),e.q.getMonth(),a,t+l,e.q.getMinutes()+u,e.q.getSeconds(),e.q.getMilliseconds()),e.q.setTime(o.getTime()))),s=e.q.getTime(),e.q.setTime(s+36e5),e.q.getHours()!=t&&e.q.setTime(s)}function wft(e,t){var n,r,i,a;if(hze(e.d,e.e),e.c.a.$b(),D(N(K(t.j,(mP(),n1))))!=0||D(N(K(t.j,n1)))!=0)for(n=zL,A(K(t.j,s1))!==A((ID(),Z0))&&W(t.j,(Y(),DQ),(rd(),!0)),a=P(K(t.j,C0),17).a,i=0;ii&&++l,M(o,(ov(s+l,t.c.length),P(t.c[s+l],17))),c+=(ov(s+l,t.c.length),P(t.c[s+l],17)).a-r,++n;n=_&&e.e[l.p]>h*e.b||b>=n*_)&&(Mr(p.c,c),c=new T,XS(s,o),o.a.$b(),u-=d,m=r.Math.max(m,u*e.b+g),u+=b,y=b,b=0,d=0,g=0);return new Kc(m,p)}function fN(e){var t,n,r,i,a,o,s;if(!e.d){if(s=new Gse,t=n9,a=t.a.zc(e,t),a==null){for(r=new Lu(l_(e));r.e!=r.i.gc();)n=P(gO(r),29),th(s,fN(n));t.a.Bc(e),t.a.gc()}for(o=s.i,i=(!e.q&&(e.q=new F(M7,e,11,10)),new Lu(e.q));i.e!=i.i.gc();++o)P(gO(i),411);th(s,(!e.q&&(e.q=new F(M7,e,11,10)),e.q)),Kw(s),e.d=new El((P(H(R((vh(),z7).o),9),19),s.i),s.g),e.e=P(s.g,688),e.e??=eHt,_y(e).b&=-17}return e.d}function pN(e,t,n,r){var i,a,o,s,c,l=nM(e.e.Dh(),t);if(c=0,i=P(e.g,124),Qo(),P(t,69).xk()){for(o=0;o1||m==-1){if(d=P(h,71),f=P(u,71),d.dc())f.$b();else for(o=!!qO(t),a=0,s=e.a?d.Kc():d.Ii();s.Ob();)l=P(s.Pb(),58),i=P(ix(e,l),58),i?(o?(c=f.dd(i),c==-1?f.Gi(a,i):a!=c&&f.Ui(a,i)):f.Gi(a,i),++a):e.b&&!o&&(f.Gi(a,l),++a)}else h==null?u.Wb(null):(i=ix(e,h),i==null?e.b&&!qO(t)&&u.Wb(h):u.Wb(i))}}function kft(e,t){var n=new _te,i,a,o,s,c,l,u;for(a=new pm(Vu(DE(t).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),!gy(i)&&(c=i.c.i,U5e(c,sY))){if(u=jct(e,c,sY,oY),u==-1)continue;n.b=r.Math.max(n.b,u),!n.a&&(n.a=new T),M(n.a,c)}for(s=new pm(Vu(OE(t).a.Kc(),new d));Cj(s);)if(o=P(by(s),18),!gy(o)&&(l=o.d.i,U5e(l,oY))){if(u=jct(e,l,oY,sY),u==-1)continue;n.d=r.Math.max(n.d,u),!n.c&&(n.c=new T),M(n.c,l)}return n}function Aft(e,t,n,r){var i,a,o,s,c,l,u;if(n.d.i!=t.i){for(i=new ZO(e),En(i,(DA(),qJ)),W(i,(Y(),WQ),n),W(i,(mP(),Q1),(rA(),R8)),Mr(r.c,i),o=new jA,G_(o,i),tj(o,(nP(),g5)),s=new jA,G_(s,i),tj(s,X8),u=n.d,K_(n,o),a=new i_,VC(a,n),W(a,j1,null),U_(a,s),K_(a,u),l=new bv(n.b,0);l.b1e6)throw E(new ji(`power of ten too big`));if(e<=AP)return xy(hj(XG[1],t),t);for(r=hj(XG[1],AP),i=r,n=LC(e-AP),t=C_(e%AP);dT(n,AP)>0;)i=Uv(i,r),n=xE(n,AP);for(i=Uv(i,hj(XG[1],t)),i=xy(i,AP),n=LC(e-AP);dT(n,AP)>0;)i=xy(i,AP),n=xE(n,AP);return i=xy(i,t),i}function Nft(e){var t,n,r,i,a,o,s,c,l,u;for(c=new w(e.a);c.al&&r>l)u=s,l=D(t.p[s.p])+D(t.d[s.p])+s.o.b+s.d.a;else{i=!1,n._g()&&n.bh(`bk node placement breaks on `+s+` which should have been after `+u);break}if(!i)break}return n._g()&&n.bh(t+` is feasible: `+i),i}function Ift(e,t,n,r){var i,a=new ZO(e),o,s,c,l,u,d,f;if(En(a,(DA(),YJ)),W(a,(mP(),Q1),(rA(),R8)),i=0,t){for(o=new jA,W(o,(Y(),WQ),t),W(a,WQ,t.i),tj(o,(nP(),g5)),G_(o,a),f=Sv(t.e),l=f,u=0,d=l.length;u0){if(i<0&&u.a&&(i=c,a=l[0],r=0),i>=0){if(s=u.b,c==i&&(s-=r++,s==0))return 0;if(!i_t(t,l,u,s,o)){c=i-1,l[0]=a;continue}}else if(i=-1,!i_t(t,l,u,0,o))return 0}else{if(i=-1,mg(u.c,0)==32){if(d=l[0],gKe(t,l),l[0]>d)continue}else if(tLe(t,u.c,l[0])){l[0]+=u.c.length;continue}return 0}return Igt(o,n)?l[0]:0}function Bft(e,t,n){var r,i,a,o,s,c,l,u=new fm(new rpe(n)),d,f;for(s=V(J9,aL,28,e.f.e.c.length,16,1),CPe(s,s.length),n[t.a]=0,l=new w(e.f.e);l.a=0&&!sk(e,u,d);)--d;i[u]=d}for(p=0;p=0&&!sk(e,s,m);)--s;a[m]=s}for(c=0;ct[f]&&fr[c]&&EM(e,c,f,!1,!0)}function Hft(e){var t,n=ki(Od(K(e,(XM(),FDt)))),r,i,a=e.a.c.d,o,s=e.a.d.d,c;n?(o=ku(ef(new k(s.a,s.b),a),.5),c=ku(xu(e.e),.5),t=ef($d(new k(a.a,a.b),o),c),IEe(e.d,t)):(i=D(N(K(e.a,WDt))),r=e.d,a.a>=s.a?a.b>=s.b?(r.a=s.a+(a.a-s.a)/2+i,r.b=s.b+(a.b-s.b)/2-i-e.e.b):(r.a=s.a+(a.a-s.a)/2+i,r.b=a.b+(s.b-a.b)/2+i):a.b>=s.b?(r.a=a.a+(s.a-a.a)/2+i,r.b=s.b+(a.b-s.b)/2+i):(r.a=a.a+(s.a-a.a)/2+i,r.b=a.b+(s.b-a.b)/2-i-e.e.b))}function gN(e){var t,n,r,i,a,o,s,c;if(!e.f){if(c=new Use,s=new Use,t=n9,o=t.a.zc(e,t),o==null){for(a=new Lu(l_(e));a.e!=a.i.gc();)i=P(gO(a),29),th(c,gN(i));t.a.Bc(e),t.a.gc()}for(r=(!e.s&&(e.s=new F(w7,e,21,17)),new Lu(e.s));r.e!=r.i.gc();)n=P(gO(r),179),j(n,102)&&tb(s,P(n,19));Kw(s),e.r=new cMe(e,(P(H(R((vh(),z7).o),6),19),s.i),s.g),th(c,e.r),Kw(c),e.f=new El((P(H(R(z7.o),5),19),c.i),c.g),_y(e).b&=-3}return e.f}function Uft(e){Wo(e,new oA(ya(ha(va(_a(new Zt,ML),`ELK DisCo`),`Layouter for arranging unconnected subgraphs. The subgraphs themselves are, by default, not laid out.`),new Ft))),B(e,ML,NL,hO(Iq)),B(e,ML,PL,hO(Pq)),B(e,ML,FL,hO(yDt)),B(e,ML,IL,hO(Fq)),B(e,ML,$I,hO(CDt)),B(e,ML,eL,hO(SDt)),B(e,ML,QI,hO(wDt)),B(e,ML,tL,hO(xDt)),B(e,ML,Jyt,hO(bDt)),B(e,ML,Yyt,hO(jq)),B(e,ML,Xyt,hO(Mq)),B(e,ML,Zyt,hO(Nq))}function _N(){_N=C,hVt=U(O(K9,1),EF,28,15,[48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70]),gVt=RegExp(`[ +\r\f]+`);try{t7=U(O(tHt,1),FP,2114,0,[new br((Sl(),hD(`yyyy-MM-dd'T'HH:mm:ss'.'SSSZ`,Kd((Ci(),Ci(),dG))))),new br(hD(`yyyy-MM-dd'T'HH:mm:ss'.'SSS`,Kd(dG))),new br(hD(`yyyy-MM-dd'T'HH:mm:ss`,Kd(dG))),new br(hD(`yyyy-MM-dd'T'HH:mm`,Kd(dG))),new br(hD(`yyyy-MM-dd`,Kd(dG)))])}catch(e){if(e=ew(e),!j(e,82))throw E(e)}}function Wft(e,t){var n,r,i=Lj(e.d,1)!=0,a;if(r=Plt(e,t),r==0&&ki(Od(K(t.j,(Y(),DQ)))))return 0;!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,i$)))||A(K(t.j,(mP(),s1)))===A((ID(),Z0))?t.c.mg(t.e,i):i=ki(Od(K(t.j,DQ))),$j(e,t,i,!0),ki(Od(K(t.j,i$)))&&W(t.j,i$,(rd(),!1)),ki(Od(K(t.j,DQ)))&&(W(t.j,DQ,(rd(),!1)),W(t.j,i$,!0)),n=Plt(e,t);do{if(WS(e),n==0)return 0;i=!i,a=n,$j(e,t,i,!1),n=Plt(e,t)}while(a>n);return a}function Gft(e,t){var n,r,i=Lj(e.d,1)!=0,a;if(r=YA(e,t),r==0&&ki(Od(K(t.j,(Y(),DQ)))))return 0;!ki(Od(K(t.j,(Y(),DQ))))&&!ki(Od(K(t.j,i$)))||A(K(t.j,(mP(),s1)))===A((ID(),Z0))?t.c.mg(t.e,i):i=ki(Od(K(t.j,DQ))),$j(e,t,i,!0),ki(Od(K(t.j,i$)))&&W(t.j,i$,(rd(),!1)),ki(Od(K(t.j,DQ)))&&(W(t.j,DQ,(rd(),!1)),W(t.j,i$,!0)),n=YA(e,t);do{if(WS(e),n==0)return 0;i=!i,a=n,$j(e,t,i,!1),n=YA(e,t)}while(a>n);return a}function Kft(e,t,n,i){var a,o,s,c,l=ef(new k(n.a,n.b),e),u=l.a*t.b-l.b*t.a,d=t.a*i.b-t.b*i.a,f=(l.a*i.b-l.b*i.a)/d,p=u/d;return d==0?u==0?(a=$d(new k(n.a,n.b),ku(new k(i.a,i.b),.5)),o=ab(e,a),s=ab($d(new k(e.a,e.b),t),a),c=r.Math.sqrt(i.a*i.a+i.b*i.b)*.5,o=0&&f<=1&&p>=0&&p<=1?$d(new k(e.a,e.b),ku(new k(t.a,t.b),f)):null}function qft(e,t,n){var r=P(K(e,(mP(),c1)),21),i,a,o,s;if(n.a>t.a&&(r.Hc((eA(),e6))?e.c.a+=(n.a-t.a)/2:r.Hc(n6)&&(e.c.a+=n.a-t.a)),n.b>t.b&&(r.Hc((eA(),i6))?e.c.b+=(n.b-t.b)/2:r.Hc(r6)&&(e.c.b+=n.b-t.b)),P(K(e,(Y(),OQ)),21).Hc((uM(),KZ))&&(n.a>t.a||n.b>t.b))for(s=new w(e.a);s.at.a&&(r.Hc((eA(),e6))?e.c.a+=(n.a-t.a)/2:r.Hc(n6)&&(e.c.a+=n.a-t.a)),n.b>t.b&&(r.Hc((eA(),i6))?e.c.b+=(n.b-t.b)/2:r.Hc(r6)&&(e.c.b+=n.b-t.b)),P(K(e,(Y(),OQ)),21).Hc((uM(),KZ))&&(n.a>t.a||n.b>t.b))for(o=new w(e.a);o.a0?e.i:0)>t&&l>0&&(o=0,s+=l+e.i,a=r.Math.max(a,p),i+=l+e.i,l=0,p=0,n&&(++f,M(e.n,new w_(e.s,s,e.i))),c=0),p+=u.g+(c>0?e.i:0),l=r.Math.max(l,u.f),n&&q4e(P(Ep(e.n,f),209),u),o+=u.g+(c>0?e.i:0),++c;return a=r.Math.max(a,p),i+=l,n&&(e.r=a,e.d=i,V3e(e.j)),new wg(e.s,e.t,a,i)}function yN(e){var t,n,i,a,o,s,c,l,u,d,f,p;for(e.b=!1,f=cI,l=lI,p=cI,u=lI,i=e.e.a.ec().Kc();i.Ob();)for(n=P(i.Pb(),272),a=n.a,f=r.Math.min(f,a.c),l=r.Math.max(l,a.c+a.b),p=r.Math.min(p,a.d),u=r.Math.max(u,a.d+a.a),s=new w(n.c);s.ae.o.a&&(d=(l-e.o.a)/2,c.b=r.Math.max(c.b,d),c.c=r.Math.max(c.c,d))}}function Qft(e){var t,n,r,i,a=new $ze,o,s,c;for(NCe(a,(lw(),DRt)),r=(i=ZS(e,V(LG,X,2,0,6,1)),new qn(new Wi(new fo(e,i).b)));r.bs?1:-1,i==-1)d=-c,u=o==c?ky(t.a,s,e.a,a):Yy(t.a,s,e.a,a);else if(d=o,o==c){if(i==0)return AM(),JG;u=ky(e.a,a,t.a,s)}else u=Yy(e.a,a,t.a,s);return l=new Bm(d,u.length,u),Cv(l),l}function $ft(e,t){var n,r,i,a=Fdt(t);if(!t.c&&(t.c=new F(e7,t,9,9)),To(new Mp(null,(!t.c&&(t.c=new F(e7,t,9,9)),new cv(t.c,16))),new cpe(a)),i=P(K(a,(Y(),OQ)),21),zht(t,i),i.Hc((uM(),KZ)))for(r=new Lu((!t.c&&(t.c=new F(e7,t,9,9)),t.c));r.e!=r.i.gc();)n=P(gO(r),123),Sgt(e,t,a,n);return P(J(t,(mP(),W1)),181).gc()!=0&&rct(t,a),ki(Od(K(a,Qjt)))&&i.Fc(ZZ),yd(a,a0)&&Q_e(new rD(D(N(K(a,a0)))),a),A(J(t,D1))===A((_T(),g8))?jvt(e,t,a):svt(e,t,a),a}function ept(e){var t,n,r,i,a,o,s,c;for(i=new w(e.b);i.a0?p_(n.a,0,a-1):``):(Zy(0,a-1,e.length),e.substr(0,a-1)):n?n.a:e}function tpt(e,t){var n,r,i,a,o,s,c;for(t.Ug(`Sort By Input Model `+K(e,(mP(),s1)),1),i=0,r=new w(e.b);r.a=e.b.length?(a[i++]=o.b[r++],a[i++]=o.b[r++]):r>=o.b.length?(a[i++]=e.b[n++],a[i++]=e.b[n++]):o.b[r]0?e.i:0)),++t;for(oE(e.n,l),e.d=n,e.r=i,e.g=0,e.f=0,e.e=0,e.o=cI,e.p=cI,o=new w(e.b);o.a0&&(i=(!e.n&&(e.n=new F(Q5,e,1,7)),P(H(e.n,0),135)).a,!i||gl(gl((t.a+=` "`,t),i),`"`))),n=(!e.b&&(e.b=new cf(H5,e,4,7)),!(e.b.i<=1&&(!e.c&&(e.c=new cf(H5,e,5,8)),e.c.i<=1))),n?t.a+=` [`:t.a+=` `,gl(t,_Te(new Xi,new Lu(e.b))),n&&(t.a+=`]`),t.a+=kR,n&&(t.a+=`[`),gl(t,_Te(new Xi,new Lu(e.c))),n&&(t.a+=`]`),t.a)}function apt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x=e.c,S=t.c,ee,te,ne,C;for(n=Ab(x.a,e,0),r=Ab(S.a,t,0),y=P(fD(e,(uS(),n2)).Kc().Pb(),12),ne=P(fD(e,r2).Kc().Pb(),12),b=P(fD(t,n2).Kc().Pb(),12),C=P(fD(t,r2).Kc().Pb(),12),_=Sv(y.e),ee=Sv(ne.g),v=Sv(b.e),te=Sv(C.g),Ak(e,r,S),o=v,u=0,m=o.length;ud?new nv((Wy(),A2),n,t,u-d):u>0&&d>0&&(new nv((Wy(),A2),t,n,0),new nv(A2,n,t,0))),s)}function lpt(e,t,n){var r,i,a;for(e.a=new T,a=dO(t.b,0);a.b!=a.d.c;){for(i=P(Lv(a),40);P(K(i,(rN(),p4)),17).a>e.a.c.length-1;)M(e.a,new Kc(zL,zV));r=P(K(i,p4),17).a,n==(GT(),t8)||n==n8?(i.e.aD(N(P(Ep(e.a,r),42).b))&&An(P(Ep(e.a,r),42),i.e.a+i.f.a)):(i.e.bD(N(P(Ep(e.a,r),42).b))&&An(P(Ep(e.a,r),42),i.e.b+i.f.b))}}function upt(e,t,n,r){var i,a=cE(r),o,s=ki(Od(K(r,(mP(),Kjt)))),c,l,u;if((s||ki(Od(K(e,O1))))&&!Kl(P(K(e,Q1),101)))i=GE(a),c=rdt(e,n,n==(uS(),r2)?i:YT(i));else switch(c=new jA,G_(c,e),t?(u=c.n,u.a=t.a-e.n.a,u.b=t.b-e.n.b,iet(u,0,0,e.o.a,e.o.b),tj(c,ldt(c,a))):(i=GE(a),tj(c,n==(uS(),r2)?i:YT(i))),o=P(K(r,(Y(),OQ)),21),l=c.j,a.g){case 2:case 1:(l==(nP(),Z8)||l==m5)&&o.Fc((uM(),XZ));break;case 4:case 3:(l==(nP(),X8)||l==g5)&&o.Fc((uM(),XZ))}return c}function dpt(e,t){var n,i,a,o,s,c;for(s=new EC(new Fn(e.f.b).a);s.b;){if(o=MS(s),a=P(o.ld(),602),t==1){if(a.Af()!=(GT(),i8)&&a.Af()!=e8)continue}else if(a.Af()!=(GT(),t8)&&a.Af()!=n8)continue;switch(i=P(P(o.md(),42).b,86),c=P(P(o.md(),42).a,194),n=c.c,a.Af().g){case 2:i.g.c=e.e.a,i.g.b=r.Math.max(1,i.g.b+n);break;case 1:i.g.c=i.g.c+n,i.g.b=r.Math.max(1,i.g.b-n);break;case 4:i.g.d=e.e.b,i.g.a=r.Math.max(1,i.g.a+n);break;case 3:i.g.d=i.g.d+n,i.g.a=r.Math.max(1,i.g.a-n)}}}function fpt(e,t){var n,i,a,o,s,c=V(q9,HF,28,t.b.c.length,15,1),l,u=V(XJ,Z,273,t.b.c.length,0,1),d,f,p,m,h,g;for(l=V(UJ,jR,10,t.b.c.length,0,1),f=e.a,p=0,m=f.length;p0&&l[i]&&(h=yu(e.b,l[i],a)),g=r.Math.max(g,a.c.c.b+h);for(o=new w(d.e);o.a1)throw E(new Fi(CW));c||(a=Gv(t,r.Kc().Pb()),o.Fc(a))}return lZe(e,Aet(e,t,n),o)}function ON(e,t,n){var r,i,a,o,s,c,l,u;if(aM(e.e,t))c=(Qo(),P(t,69).xk()?new hp(t,e):new Qc(t,e)),_j(c.c,c.b),Su(c,P(n,16));else{for(u=nM(e.e.Dh(),t),r=P(e.g,124),o=0;o`}c!=null&&(t.a+=``+c)}else e.e?(s=e.e.zb,s!=null&&(t.a+=``+s)):(t.a+=`?`,e.b?(t.a+=` super `,kN(e.b,t)):e.f&&(t.a+=` extends `,kN(e.f,t)))}function Spt(e){e.b=null,e.a=null,e.o=null,e.q=null,e.v=null,e.w=null,e.B=null,e.p=null,e.Q=null,e.R=null,e.S=null,e.T=null,e.U=null,e.V=null,e.W=null,e.bb=null,e.eb=null,e.ab=null,e.H=null,e.db=null,e.c=null,e.d=null,e.f=null,e.n=null,e.r=null,e.s=null,e.u=null,e.G=null,e.J=null,e.e=null,e.j=null,e.i=null,e.g=null,e.k=null,e.t=null,e.F=null,e.I=null,e.L=null,e.M=null,e.O=null,e.P=null,e.$=null,e.N=null,e.Z=null,e.cb=null,e.K=null,e.D=null,e.A=null,e.C=null,e._=null,e.fb=null,e.X=null,e.Y=null,e.gb=!1,e.hb=!1}function Cpt(e){var t,n,i=pP((!e.c&&(e.c=Q_(LC(e.f))),e.c),0),a;if(e.e==0||e.a==0&&e.f!=-1&&e.e<0)return i;if(t=+(QS(e)<0),n=e.e,a=(i.length+1+r.Math.abs(C_(e.e)),new na),t==1&&(a.a+=`-`),e.e>0){if(n-=i.length-t,n>=0){for(a.a+=`0.`;n>RG.length;n-=RG.length)RMe(a,RG);RDe(a,RG,C_(n)),gl(a,(sv(t,i.length+1),i.substr(t)))}else n=t-n,gl(a,p_(i,t,C_(n))),a.a+=`.`,gl(a,Ch(i,C_(n)))}else{for(gl(a,(sv(t,i.length+1),i.substr(t)));n<-RG.length;n+=RG.length)RMe(a,RG);RDe(a,RG,C_(-n))}return a.a}function AN(e){var t,n,r,i,a,o,s,c,l;return!(e.k!=(DA(),JJ)||e.j.c.length<=1||(a=P(K(e,(mP(),Q1)),101),a==(rA(),R8))||(i=(IO(),r=(e.q?e.q:(Vg(),Vg(),$G))._b(V1)?P(K(e,V1),203):P(K(Bh(e),H1),203),r),i==R0)||i!=L0&&i!=I0&&(o=D(N(gD(e,S0))),t=P(K(e,x0),140),!t&&(t=new ZDe(o,o,o,o)),l=SE(e,(nP(),g5)),c=t.d+t.a+(l.gc()-1)*o,c>e.o.b||(n=SE(e,X8),s=t.d+t.a+(n.gc()-1)*o,s>e.o.b)))}function wpt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;t.Ug(`Orthogonal edge routing`,1),l=D(N(K(e,(mP(),y0)))),n=D(N(K(e,l0))),r=D(N(K(e,f0))),f=new ah(0,n),g=0,o=new bv(e.b,0),s=null,u=null,c=null,d=null;do u=o.b0?(p=(m-1)*n,s&&(p+=r),u&&(p+=r),pt||ki(Od(J(c,(gM(),t3)))))&&(i=0,a+=u.b+n,Mr(d.c,u),u=new Zze(a,n),r=new kw(0,u.f,u,n),hS(u,r),i=0),r.b.c.length==0||!ki(Od(J(I_(c),(gM(),r3))))&&(c.f>=r.o&&c.f<=r.f||r.a*.5<=c.f&&r.a*1.5>=c.f)?ME(r,c):(o=new kw(r.s+r.r+n,u.f,u,n),hS(u,o),ME(o,c)),i=c.i+c.g;return Mr(d.c,u),d}function FN(e){var t,n,r,i;if(!(e.b==null||e.b.length<=2)&&!e.a){for(t=0,i=0;i=e.b[i+1])i+=2;else if(n0)for(r=new bf(P(Dy(e.a,a),21)),Vg(),hu(r,new ur(t)),i=new bv(a.b,0);i.b0&&r>=-6?r>=0?Xu(a,n-C_(e.e),`.`):(kC(a,t-1,t-1,`0.`),Xu(a,t+1,ND(RG,0,-C_(r)-1))):(n-t>=1&&(Xu(a,t,`.`),++n),Xu(a,n,`E`),r>0&&Xu(a,++n,`+`),Xu(a,++n,``+bm(LC(r)))),e.g=a.a,e.g)):e.g}function zpt(e,t){var n,i=D(N(K(t,(mP(),Yjt)))),a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(K(t,C0),17).a,ee,te;p=4,a=3,ee=20/S,m=!1,l=0,s=AP;do{for(o=l!=1,f=l!=0,te=0,_=e.a,y=0,x=_.length;yS)?(l=2,s=AP):l==0?(l=1,s=te):(l=0,s=te)):(m=te>=s||s-te0?1:Pl(isNaN(i),!1))>=0^(fS(TV),(r.Math.abs(c)<=TV||c==0?0:c<0?-1:c>0?1:Pl(isNaN(c),!1))>=0)?r.Math.max(c,i):(fS(TV),(r.Math.abs(i)<=TV||i==0?0:i<0?-1:i>0?1:Pl(isNaN(i),!1))>0?r.Math.sqrt(c*c+i*i):-r.Math.sqrt(c*c+i*i))}function LN(e,t){var n,r,i,a,o,s;if(t){if(!e.a&&(e.a=new Yr),e.e==2){Gr(e.a,t);return}if(t.e==1){for(i=0;i=pI?pl(n,vE(r)):Ah(n,r&OF),o=(++W9,new __(10,null,0)),xPe(e.a,o,s-1)):(n=(o.Mm().length+a,new ea),pl(n,o.Mm())),t.e==0?(r=t.Km(),r>=pI?pl(n,vE(r)):Ah(n,r&OF)):pl(n,t.Mm()),P(o,530).b=n.a}}function Hpt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(!n.dc()){for(s=0,f=0,r=n.Kc(),m=P(r.Pb(),17).a;s1&&(c=l.Hg(c,e.a,s));return c.c.length==1?P(Ep(c,c.c.length-1),238):c.c.length==2?Ept((ov(0,c.c.length),P(c.c[0],238)),(ov(1,c.c.length),P(c.c[1],238)),o,a):null}function qpt(e,t,n){var r,i,a,o,s,c,l;for(n.Ug(`Find roots`,1),e.a.c.length=0,i=dO(t.b,0);i.b!=i.d.c;)r=P(Lv(i),40),r.b.b==0&&(W(r,(tP(),a4),(rd(),!0)),M(e.a,r));switch(e.a.c.length){case 0:a=new Ow(0,t,`DUMMY_ROOT`),W(a,(tP(),a4),(rd(),!0)),W(a,W2,!0),up(t.b,a);break;case 1:break;default:for(o=new Ow(0,t,LV),c=new w(e.a);c.a=r.Math.abs(i.b)?(i.b=0,o.d+o.a>s.d&&o.ds.c&&o.c0){if(t=new $c(e.i,e.g),n=e.i,a=n<100?null:new Pa(n),e.Tj())for(r=0;r0){for(s=e.g,l=e.i,Ey(e),a=l<100?null:new Pa(l),r=0;r>13|(e.m&15)<<9,i=e.m>>4&8191,a=e.m>>17|(e.h&255)<<5,o=(e.h&1048320)>>8,s=t.l&8191,c=t.l>>13|(t.m&15)<<9,l=t.m>>4&8191,u=t.m>>17|(t.h&255)<<5,d=(t.h&1048320)>>8,f,p,m,h,g,_,v,y,b,x,S,ee,te=n*s,ne=r*s,C=i*s,re=a*s,ie=o*s;return c!=0&&(ne+=n*c,C+=r*c,re+=i*c,ie+=a*c),l!=0&&(C+=n*l,re+=r*l,ie+=i*l),u!=0&&(re+=n*u,ie+=r*u),d!=0&&(ie+=n*d),p=te&QF,m=(ne&511)<<13,f=p+m,g=te>>22,_=ne>>9,v=(C&262143)<<4,y=(re&31)<<17,h=g+_+v+y,x=C>>18,S=re>>5,ee=(ie&4095)<<8,b=x+S+ee,h+=f>>22,f&=QF,b+=h>>22,h&=QF,b&=$F,vu(f,h,b)}function Qpt(e){var t,n,i,a,o,s,c=P(Ep(e.j,0),12);if(c.g.c.length!=0&&c.e.c.length!=0)throw E(new Ii(`Interactive layout does not support NORTH/SOUTH ports with incoming _and_ outgoing edges.`));if(c.g.c.length!=0){for(o=cI,n=new w(c.g);n.a4){if(e.fk(t)){if(e.al()){if(i=P(t,54),r=i.Eh(),c=r==e.e&&(e.ml()?i.yh(i.Fh(),e.il())==e.jl():-1-i.Fh()==e.Lj()),e.nl()&&!c&&!r&&i.Jh()){for(a=0;a0&&Cet(e,s,d);for(i=new w(d);i.ae.d[o.p]&&(n+=$He(e.b,a)*P(c.b,17).a,Rv(e.a,G(a)));for(;!qi(e.a);)cx(e.b,P(Fm(e.a),17).a)}return n}function nmt(e,t){var n,r,i,a,o,s,c,l,u=P(K(e,(Y(),TQ)),64),d;if(r=P(Ep(e.j,0),12),u==(nP(),Z8)?tj(r,m5):u==m5&&tj(r,Z8),P(K(t,(mP(),W1)),181).Hc((TD(),x5))){if(c=D(N(K(e,g0))),l=D(N(K(e,_0))),o=D(N(K(e,m0))),s=P(K(t,e0),21),s.Hc((rj(),G8)))for(n=l,d=e.o.a/2-r.n.a,a=new w(r.f);a.a0&&(l=e.n.a/a);break;case 2:case 4:i=e.i.o.b,i>0&&(l=e.n.b/i)}W(e,(Y(),$Q),l)}if(c=e.o,o=e.a,r)o.a=r.a,o.b=r.b,e.d=!0;else if(t!=V8&&t!=H8&&s!=h5)switch(s.g){case 1:o.a=c.a/2;break;case 2:o.a=c.a,o.b=c.b/2;break;case 3:o.a=c.a/2,o.b=c.b;break;case 4:o.b=c.b/2}else o.a=c.a/2,o.b=c.b/2}function zN(e){var t,n,r,i,a,o,s,c,l,u;if(e.Pj()){if(u=e.Ej(),c=e.Qj(),u>0){if(t=new hC(e.pj()),n=u,a=n<100?null:new Pa(n),zd(e,n,t.g),i=n==1?e.Ij(4,H(t,0),null,0,c):e.Ij(6,t,null,-1,c),e.Mj()){for(r=new Lu(t);r.e!=r.i.gc();)a=e.Oj(gO(r),a);a?(a.nj(i),a.oj()):e.Jj(i)}else a?(a.nj(i),a.oj()):e.Jj(i)}else zd(e,e.Ej(),e.Fj()),e.Jj(e.Ij(6,(Vg(),QG),null,-1,c))}else if(e.Mj()){if(u=e.Ej(),u>0){for(s=e.Fj(),l=u,zd(e,u,s),a=l<100?null:new Pa(l),r=0;r1&&Lp(o)*Ip(o)/2>s[0]){for(a=0;as[a];)++a;m=new $_(h,0,a+1),d=new Fx(m),u=Lp(o)/Ip(o),c=cP(d,t,new ni,n,r,i,u),$d(Cl(d.e),c),ep(gA(f,d),bI),p=new $_(h,a+1,h.c.length),m6e(f,p),h.c.length=0,l=0,mNe(s,s.length,0)}else g=f.b.c.length==0?null:Ep(f.b,0),g!=null&&LS(f,0),l>0&&(s[l]=s[l-1]),s[l]+=Lp(o)*Ip(o),++l,Mr(h.c,o);return h}function cmt(e,t){var n=t.b,r,i,a=new bf(n.j);i=0,r=n.j,r.c.length=0,$m(P(TC(e.b,(nP(),Z8),(kS(),jX)),15),n),i=HO(a,i,new wre,r),$m(P(TC(e.b,Z8,AX),15),n),i=HO(a,i,new _re,r),$m(P(TC(e.b,Z8,kX),15),n),$m(P(TC(e.b,X8,jX),15),n),$m(P(TC(e.b,X8,AX),15),n),i=HO(a,i,new Tre,r),$m(P(TC(e.b,X8,kX),15),n),$m(P(TC(e.b,m5,jX),15),n),i=HO(a,i,new Ere,r),$m(P(TC(e.b,m5,AX),15),n),i=HO(a,i,new Dre,r),$m(P(TC(e.b,m5,kX),15),n),$m(P(TC(e.b,g5,jX),15),n),i=HO(a,i,new bre,r),$m(P(TC(e.b,g5,AX),15),n),$m(P(TC(e.b,g5,kX),15),n)}function lmt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p;for(s=new w(t);s.a.5?v-=s*2*(h-.5):h<.5&&(v+=o*2*(.5-h)),a=c.d.b,v_.a-g-d&&(v=_.a-g-d),c.n.a=t+v}}function hmt(e){var t,n,r=P(K(e,(mP(),M1)),171),i,a;if(r==(XE(),h$)){for(n=new pm(Vu(DE(e).a.Kc(),new d));Cj(n);)if(t=P(by(n),18),!OUe(t))throw E(new zi(LR+xk(e)+`' has its layer constraint set to FIRST_SEPARATE, but has at least one incoming edge. FIRST_SEPARATE nodes must not have incoming edges.`))}else if(r==_$){for(a=new pm(Vu(OE(e).a.Kc(),new d));Cj(a);)if(i=P(by(a),18),!OUe(i))throw E(new zi(LR+xk(e)+`' has its layer constraint set to LAST_SEPARATE, but has at least one outgoing edge. LAST_SEPARATE nodes must not have outgoing edges.`))}}function BN(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m;if(e.e&&e.c.c>19&&(t=mw(t),c=!c),o=Bat(t),a=!1,i=!1,r=!1,e.h==eI&&e.m==0&&e.l==0){if(i=!0,a=!0,o==-1)e=xCe(($b(),hG)),r=!0,c=!c;else return s=$rt(e,o),c&&ww(s),n&&(mG=vu(0,0,0)),s}else e.h>>19&&(a=!0,e=mw(e),r=!0,c=!c);return o==-1?W6e(e,t)<0?(n&&(mG=a?mw(e):vu(e.l,e.m,e.h)),vu(0,0,0)):jut(r?e:vu(e.l,e.m,e.h),t,c,a,i,n):LZe(e,o,c,a,n)}function VN(e,t){var n,r,i,a,o=e.e,s,c=t.e,l,u,d,f,p,m;if(o==0)return t;if(c==0)return e;if(a=e.d,s=t.d,a+s==2)return n=uv(e.a[0],_I),r=uv(t.a[0],_I),o==c?(u=yE(n,r),m=nm(u),p=nm(um(u,32)),p==0?new Xv(o,m):new Bm(o,2,U(O(q9,1),HF,28,15,[m,p]))):(AM(),sl(o<0?xE(r,n):xE(n,r),0)?yD(o<0?xE(r,n):xE(n,r)):Xm(yD(kb(o<0?xE(r,n):xE(n,r)))));if(o==c)f=o,d=a>=s?Yy(e.a,a,t.a,s):Yy(t.a,s,e.a,a);else{if(i=a==s?lQe(e.a,t.a,a):a>s?1:-1,i==0)return AM(),JG;i==1?(f=o,d=ky(e.a,a,t.a,s)):(f=c,d=ky(t.a,s,e.a,a))}return l=new Bm(f,d.length,d),Cv(l),l}function vmt(e,t){var n,r,i,a,o,s,c;if(!(e.g>t.f||t.g>e.f)){for(n=0,r=0,o=e.w.a.ec().Kc();o.Ob();)i=P(o.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,t.g,t.f)&&++n;for(s=e.r.a.ec().Kc();s.Ob();)i=P(s.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,t.g,t.f)&&--n;for(c=t.w.a.ec().Kc();c.Ob();)i=P(c.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,e.g,e.f)&&++r;for(a=t.r.a.ec().Kc();a.Ob();)i=P(a.Pb(),12),oT(Sw(U(O(K3,1),X,8,0,[i.i.n,i.n,i.a])).b,e.g,e.f)&&--r;n=0)return n;switch(qh(Rb(e,n))){case 2:if(ff(``,AT(e,n.qk()).xe())){if(c=ug(Rb(e,n)),s=lg(Rb(e,n)),u=Hit(e,t,c,s),u)return u;for(i=$lt(e,t),o=0,d=i.gc();o1)throw E(new Fi(CW));for(u=nM(e.e.Dh(),t),r=P(e.g,124),o=0;o1,u=new Ny(p.b);gu(u.a)||gu(u.b);)l=P(gu(u.a)?z(u.a):z(u.b),18),f=l.c==p?l.d:l.c,r.Math.abs(Sw(U(O(K3,1),X,8,0,[f.i.n,f.n,f.a])).b-s.b)>1&&ust(e,l,s,o,p)}}function wmt(e){var t,n,i,a=new bv(e.e,0),o,s;if(i=new bv(e.a,0),e.d)for(n=0;nAV;){for(o=t,s=0;r.Math.abs(t-o)0),a.a.Xb(a.c=--a.b),Zdt(e,e.b-s,o,i,a),jd(a.b0),i.a.Xb(i.c=--i.b)}if(!e.d)for(n=0;n0?(e.f[d.p]=m/(d.e.c.length+d.g.c.length),e.c=r.Math.min(e.c,e.f[d.p]),e.b=r.Math.max(e.b,e.f[d.p])):c&&(e.f[d.p]=m)}}function Emt(e){e.b=null,e.bb=null,e.fb=null,e.qb=null,e.a=null,e.c=null,e.d=null,e.e=null,e.f=null,e.n=null,e.M=null,e.L=null,e.Q=null,e.R=null,e.K=null,e.db=null,e.eb=null,e.g=null,e.i=null,e.j=null,e.k=null,e.gb=null,e.o=null,e.p=null,e.q=null,e.r=null,e.$=null,e.ib=null,e.S=null,e.T=null,e.t=null,e.s=null,e.u=null,e.v=null,e.w=null,e.B=null,e.A=null,e.C=null,e.D=null,e.F=null,e.G=null,e.H=null,e.I=null,e.J=null,e.P=null,e.Z=null,e.U=null,e.V=null,e.W=null,e.X=null,e.Y=null,e._=null,e.ab=null,e.cb=null,e.hb=null,e.nb=null,e.lb=null,e.mb=null,e.ob=null,e.pb=null,e.jb=null,e.kb=null,e.N=!1,e.O=!1}function Dmt(e,t,n){var r,i,a,o;for(n.Ug(`Graph transformation (`+e.a+`)`,1),o=lv(t.a),a=new w(t.b);a.a=s.b.c)&&(s.b=t),(!s.c||t.c<=s.c.c)&&(s.d=s.c,s.c=t),(!s.e||t.d>=s.e.d)&&(s.e=t),(!s.f||t.d<=s.f.d)&&(s.f=t);return r=new xO((ow(),kJ)),vv(e,yOt,new Wi(U(O(OJ,1),FP,382,0,[r]))),o=new xO(MJ),vv(e,vOt,new Wi(U(O(OJ,1),FP,382,0,[o]))),i=new xO(AJ),vv(e,_Ot,new Wi(U(O(OJ,1),FP,382,0,[i]))),a=new xO(jJ),vv(e,gOt,new Wi(U(O(OJ,1),FP,382,0,[a]))),Vj(r.c,kJ),Vj(i.c,AJ),Vj(a.c,jJ),Vj(o.c,MJ),s.a.c.length=0,nw(s.a,r.c),nw(s.a,UE(i.c)),nw(s.a,a.c),nw(s.a,UE(o.c)),s}function Amt(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h;for(t.Ug(Yxt,1),m=D(N(J(e,(xM(),Z4)))),s=D(N(J(e,(gM(),a3)))),c=P(J(e,i3),107),BS((!e.a&&(e.a=new F($5,e,10,11)),e.a)),d=Mpt((!e.a&&(e.a=new F($5,e,10,11)),e.a),m,s),!e.a&&(e.a=new F($5,e,10,11)),u=new w(d);u.a0&&(e.a=c+(m-1)*a,t.c.b+=e.a,t.f.b+=e.a)),h.a.gc()!=0&&(p=new ah(1,a),m=fht(p,t,h,g,t.f.b+c-t.c.b),m>0&&(t.f.b+=c+(m-1)*a))}function Mmt(e,t,n){var i,a,o,s,c,l,u,d=D(N(K(e,(mP(),d0)))),f,p,m,h,g,_,v,y,b,x;for(i=D(N(K(e,_Mt))),p=new en,W(p,d0,d+i),u=t,v=u.d,g=u.c.i,y=u.d.i,_=Ll(g.c),b=Ll(y.c),a=new T,f=_;f<=b;f++)c=new ZO(e),En(c,(DA(),qJ)),W(c,(Y(),WQ),u),W(c,Q1,(rA(),R8)),W(c,p0,p),m=P(Ep(e.b,f),30),f==_?Ak(c,m.a.c.length-n,m):W_(c,m),x=D(N(K(u,T1))),x<0&&(x=0,W(u,T1,x)),c.o.b=x,h=r.Math.floor(x/2),s=new jA,tj(s,(nP(),g5)),G_(s,c),s.n.b=h,l=new jA,tj(l,X8),G_(l,c),l.n.b=h,K_(u,s),o=new i_,VC(o,u),W(o,j1,null),U_(o,l),K_(o,v),Y6e(c,u,o),Mr(a.c,o),u=o;return a}function WN(e,t){var n,r,i,a,o,s,c=P(NA(e,(nP(),g5)).Kc().Pb(),12).e,l,u,d,f,p=P(NA(e,X8).Kc().Pb(),12).g,m,h,g,_,v,y;for(s=c.c.length,y=rv(P(Ep(e.j,0),12));s-->0;){for(h=(ov(0,c.c.length),P(c.c[0],18)),i=(ov(0,p.c.length),P(p.c[0],18)),v=i.d.e,a=Ab(v,i,0),JBe(h,i.d,a),U_(i,null),K_(i,null),m=h.a,t&&up(m,new Vl(y)),r=dO(i.a,0);r.b!=r.d.c;)n=P(Lv(r),8),up(m,new Vl(n));for(_=h.b,f=new w(i.b);f.ao)&&Lm(e.b,P(g.b,18));++s}a=o}}}function Pmt(e,t){var n;if(t==null||ff(t,IP)||t.length==0&&e.k!=(VA(),V3))return null;switch(e.k.g){case 1:return qD(t,DH)?(rd(),yG):qD(t,OH)?(rd(),vG):null;case 2:try{return G(GM(t,xF,AP))}catch(e){if(e=ew(e),j(e,130))return null;throw E(e)}case 4:try{return OA(t)}catch(e){if(e=ew(e),j(e,130))return null;throw E(e)}case 3:return t;case 5:return kQe(e),Nnt(e,t);case 6:return kQe(e),aat(e,e.a,t);case 7:try{return n=Lrt(e),n.cg(t),n}catch(e){if(e=ew(e),j(e,33))return null;throw E(e)}default:throw E(new Ii(`Invalid type set for this layout option.`))}}function Fmt(e){var t;switch(e.d){case 1:if(e.Sj())return e.o!=-2;break;case 2:if(e.Sj())return e.o==-2;break;case 3:case 5:case 4:case 6:case 7:return e.o>-2;default:return!1}switch(t=e.Rj(),e.p){case 0:return t!=null&&ki(Od(t))!=cl(e.k,0);case 1:return t!=null&&P(t,222).a!=nm(e.k)<<24>>24;case 2:return t!=null&&P(t,180).a!=(nm(e.k)&OF);case 6:return t!=null&&cl(P(t,168).a,e.k);case 5:return t!=null&&P(t,17).a!=nm(e.k);case 7:return t!=null&&P(t,191).a!=nm(e.k)<<16>>16;case 3:return t!=null&&D(N(t))!=e.j;case 4:return t!=null&&P(t,161).a!=e.j;default:return t==null?e.n!=null:!NT(t,e.n)}}function GN(e,t,n){var r,i,a,o;return e.ol()&&e.nl()&&(o=Am(e,P(n,58)),A(o)!==A(n))?(e.xj(t),e.Dj(t,CGe(e,t,o)),e.al()&&(a=(i=P(n,54),e.ml()?e.kl()?i.Th(e.b,qO(P(_x(d_(e.b),e.Lj()),19)).n,P(_x(d_(e.b),e.Lj()).Hk(),29).kk(),null):i.Th(e.b,eD(i.Dh(),qO(P(_x(d_(e.b),e.Lj()),19))),null,null):i.Th(e.b,-1-e.Lj(),null,null)),!P(o,54).Ph()&&(a=(r=P(o,54),e.ml()?e.kl()?r.Rh(e.b,qO(P(_x(d_(e.b),e.Lj()),19)).n,P(_x(d_(e.b),e.Lj()).Hk(),29).kk(),a):r.Rh(e.b,eD(r.Dh(),qO(P(_x(d_(e.b),e.Lj()),19))),null,a):r.Rh(e.b,-1-e.Lj(),null,a))),a&&a.oj()),Gl(e.b)&&e.Jj(e.Ij(9,n,o,t,!1)),o):n}function Imt(e){var t,n,r=new T,i,a,o,s,c,l,u;for(o=new w(e.e.a);o.a0&&(s=r.Math.max(s,hYe(e.C.b+i.d.b,a))),d=i,f=a,p=o;e.C&&e.C.c>0&&(m=p+e.C.c,u&&(m+=d.d.c),s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(f-1)<=fL||f==1?0:m/(1-f)))),n.n.b=0,n.a.a=s}function Rmt(e,t){var n=P(ig(e.b,t),127),i,a,o,s,c,l=P(P(Dy(e.r,t),21),87),u,d,f,p,m;if(l.dc()){n.n.d=0,n.n.a=0;return}for(u=e.u.Hc((rj(),G8)),s=0,e.A.Hc((TD(),x5))&&ilt(e,t),c=l.Kc(),d=null,p=0,f=0;c.Ob();)i=P(c.Pb(),117),o=D(N(i.b.of((nd(),uq)))),a=i.b.Mf().b,d?(m=f+d.d.a+e.w+i.d.d,s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(p-o)<=fL||p==o||isNaN(p)&&isNaN(o)?0:m/(o-p)))):e.C&&e.C.d>0&&(s=r.Math.max(s,hYe(e.C.d+i.d.d,o))),d=i,p=o,f=a;e.C&&e.C.a>0&&(m=f+e.C.a,u&&(m+=d.d.a),s=r.Math.max(s,(uu(),fS(fL),r.Math.abs(p-1)<=fL||p==1?0:m/(1-p)))),n.n.d=0,n.a.b=s}function zmt(e,t,n,r,i,a,o,s){var c,l,u,d,f,p,m=!1,h,g,_;if(l=vot(n.q,t.f+t.b-n.q.f),p=r.f>t.b&&s,_=i-(n.q.e+l-o),d=(c=vN(r,_,!1),c.a),p&&d>r.f)return!1;if(p){for(f=0,g=new w(t.d);g.a=(ov(a,e.c.length),P(e.c[a],186)).e,!p&&d>t.b&&!u)?!1:((u||p||d<=t.b)&&(u&&d>t.b?(n.d=d,fb(n,X9e(n,d))):(Z8e(n.q,l),n.c=!0),fb(r,i-(n.s+n.r)),WO(r,n.q.e+n.q.d,t.f),hS(t,r),e.c.length>a&&(Fk((ov(a,e.c.length),P(e.c[a],186)),r),(ov(a,e.c.length),P(e.c[a],186)).a.c.length==0&&Ay(e,a)),m=!0),m)}function Bmt(e,t,n){var r,i,a,o,s,c;for(this.g=e,s=t.d.length,c=n.d.length,this.d=V(UJ,jR,10,s+c,0,1),o=0;o0?jx(this,this.f/this.a):Eu(t.g,t.d[0]).a!=null&&Eu(n.g,n.d[0]).a!=null?jx(this,(D(Eu(t.g,t.d[0]).a)+D(Eu(n.g,n.d[0]).a))/2):Eu(t.g,t.d[0]).a==null?Eu(n.g,n.d[0]).a!=null&&jx(this,Eu(n.g,n.d[0]).a):jx(this,Eu(t.g,t.d[0]).a)}function Vmt(e,t){var n,r,i,a,o,s,c,l,u,d;for(e.a=new nFe($Xe(a8)),r=new w(t.a);r.a=1&&(g-o>0&&d>=0?(c.n.a+=h,c.n.b+=a*o):g-o<0&&u>=0&&(c.n.a+=h*g,c.n.b+=a));e.o.a=t.a,e.o.b=t.b,W(e,(mP(),W1),(TD(),r=P(Ba(S5),9),new xf(r,P(Yd(r,r.length),9),0)))}function Kmt(e,t,n,r,i,a){var o;if(!(t==null||!zE(t,FVt,IVt)))throw E(new Fi(`invalid scheme: `+t));if(!e&&!(n!=null&&Nl(n,mA(35))==-1&&n.length>0&&(sv(0,n.length),n.charCodeAt(0)!=47)))throw E(new Fi(`invalid opaquePart: `+n));if(e&&!(t!=null&&po(x7,t.toLowerCase()))&&!(n==null||!zE(n,y7,b7))||e&&t!=null&&po(x7,t.toLowerCase())&&!y5e(n))throw E(new Fi(cwt+n));if(!W1e(r))throw E(new Fi(`invalid device: `+r));if(!QQe(i))throw o=i==null?`invalid segments: null`:`invalid segment: `+LQe(i),E(new Fi(o));if(a!=null&&Nl(a,mA(35))!=-1)throw E(new Fi(`invalid query: `+a))}function qmt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v;if(n.Ug(`Network simplex layering`,1),e.b=t,v=P(K(t,(mP(),C0)),17).a*4,_=e.b.a,_.c.length<1){n.Vg();return}for(o=nut(e,_),g=null,a=dO(o,0);a.b!=a.d.c;){for(i=P(Lv(a),15),c=v*C_(r.Math.sqrt(i.gc())),s=kut(i),HM(da(jve(fa(Nf(s),c),g),!0),n.eh(1)),p=e.b.b,h=new w(s.a);h.a1)for(g=V(q9,HF,28,e.b.b.c.length,15,1),f=0,u=new w(e.b.b);u.a0){aO(e,n,0),n.a+=String.fromCharCode(r),i=n2e(t,a),aO(e,n,i),a+=i-1;continue}r==39?a+10&&m.a<=0){c.c.length=0,Mr(c.c,m);break}p=m.i-m.d,p>=s&&(p>s&&(c.c.length=0,s=p),Mr(c.c,m))}c.c.length!=0&&(o=P(Ep(c,VO(i,c.c.length)),118),y.a.Bc(o),o.g=u++,Jdt(o,t,n,r),c.c.length=0)}for(g=e.c.length+1,f=new w(e);f.alI||t.o==T2&&u=s&&i<=c)s<=i&&a<=c?(n[u++]=i,n[u++]=a,r+=2):s<=i?(n[u++]=i,n[u++]=c,e.b[r]=c+1,o+=2):a<=c?(n[u++]=s,n[u++]=a,r+=2):(n[u++]=s,n[u++]=c,e.b[r]=c+1);else if(cbF)&&c<10);ma(e.c,new cee),eht(e),wPe(e.c),Omt(e.f)}function oht(e,t){var n=P(K(e,(mP(),Q1)),101),i,a,o,s=e.f,c,l,u,d,f,p,m,h,g;for(o=e.d,c=s.a+o.b+o.c,l=0-o.d-e.c.b,d=s.b+o.d+o.a-e.c.b,u=new T,f=new T,a=new w(t);a.a=2){for(c=dO(n,0),o=P(Lv(c),8),s=P(Lv(c),8);s.a0&&fw(l,!0,(GT(),n8)),s.k==(DA(),GJ)&&_Fe(l),Qh(e.f,s,t)}}function lht(e){var t,n,i,a=P(K(e,(tP(),t4)),27),o,s,c,l,u=AP,d=AP,f,p,m,h,g,_,v,y,b,x;for(c=xF,l=xF,b=dO(e.b,0);b.b!=b.d.c;)v=P(Lv(b),40),m=v.e,h=v.f,u=r.Math.min(u,m.a-h.a/2),d=r.Math.min(d,m.b-h.b/2),c=r.Math.max(c,m.a+h.a/2),l=r.Math.max(l,m.b+h.b/2);for(p=P(J(a,(rN(),fFt)),107),y=dO(e.b,0);y.b!=y.d.c;)v=P(Lv(y),40),f=K(v,t4),j(f,207)&&(o=P(f,27),$l(o,v.e.a,v.e.b),qj(o,v));for(_=dO(e.a,0);_.b!=_.d.c;)g=P(Lv(_),65),i=P(K(g,t4),74),i&&(t=g.a,n=cM(i,!0,!0),cN(t,n));x=c-u+(p.b+p.c),s=l-d+(p.d+p.a),ki(Od(J(a,(vP(),T6))))||iP(a,x,s,!1,!1),OO(a,u6,x-(p.b+p.c)),OO(a,l6,s-(p.d+p.a))}function uht(e,t){var n,r,i,a,o,s,c=!0,l,u,f;for(i=0,l=e.g[t.p],u=t.o.b+e.o,n=e.d[t.p][2],uy(e.b,l,G(P(Ep(e.b,l),17).a-1+n)),uy(e.c,l,D(N(Ep(e.c,l)))-u+n*e.f),++l,l>=e.j?(++e.j,M(e.b,G(1)),M(e.c,u)):(r=e.d[t.p][1],uy(e.b,l,G(P(Ep(e.b,l),17).a+1-r)),uy(e.c,l,D(N(Ep(e.c,l)))+u-r*e.f)),(e.r==(FM(),q0)&&(P(Ep(e.b,l),17).a>e.k||P(Ep(e.b,l-1),17).a>e.k)||e.r==J0&&(D(N(Ep(e.c,l)))>e.n||D(N(Ep(e.c,l-1)))>e.n))&&(c=!1),o=new pm(Vu(DE(t).a.Kc(),new d));Cj(o);)a=P(by(o),18),s=a.c.i,e.g[s.p]==l&&(f=uht(e,s),i+=P(f.a,17).a,c&&=ki(Od(f.b)));return e.g[t.p]=l,i+=e.d[t.p][0],new Kc(G(i),(rd(),!!c))}function dht(e,t){var n=D(N(K(t,(mP(),c0)))),r,i,a,o;n<2&&W(t,c0,2),r=P(K(t,_1),88),r==(GT(),r8)&&W(t,_1,cE(t)),i=P(K(t,lMt),17),i.a==0?W(t,(Y(),t$),new YE):W(t,(Y(),t$),new sy(i.a)),a=Od(K(t,B1)),a??W(t,B1,(rd(),A(K(t,S1))===A((wE(),l8)))),To(new Mp(null,new cv(t.a,16)),new cr(e)),To(ox(new Mp(null,new cv(t.b,16)),new Ht),new lr(e)),o=new Hmt(t),W(t,(Y(),o$),o),cg(e.a),Um(e.a,(vA(),vJ),P(K(t,g1),188)),Um(e.a,yJ,P(K(t,F1),188)),Um(e.a,bJ,P(K(t,h1),188)),Um(e.a,xJ,P(K(t,U1),188)),Um(e.a,SJ,dXe(P(K(t,S1),223))),Bl(e.a,$_t(t)),W(t,e$,BN(e.a,t))}function fht(e,t,n,i,a){var o,s,c,l,u,d,f=new Dr,p,m,h,g,_,v;for(s=new T,ett(e,n,e.d.Ag(),s,f),ett(e,i,e.d.Bg(),s,f),e.b=.2*(g=_it(ox(new Mp(null,new cv(s,16)),new $ie)),_=_it(ox(new Mp(null,new cv(s,16)),new eae)),r.Math.min(g,_)),o=0,c=0;c=2&&(v=jat(s,!0,p),!e.e&&(e.e=new Ome(e)),Z0e(e.e,v,s,e.b)),W5e(s,p),xht(s),m=-1,d=new w(s);d.as)}function hht(e,t){var n,i,a,o,s,c,l,u=cI,d=cI,f,p,m,h,g,_,v,y;for(c=lI,l=lI,p=new w(t.i);p.a-1){for(a=dO(c,0);a.b!=a.d.c;)i=P(Lv(a),131),i.v=s;for(;c.b!=0;)for(i=P(Mk(c,0),131),n=new w(i.i);n.a-1){for(o=new w(c);o.a0)&&(Xde(l,r.Math.min(l.o,a.o-1)),On(l,l.i-1),l.i==0&&Mr(c.c,l))}}function Sht(e,t,n,i,a){var o,s,c,l=cI;return s=!1,c=Kft(e,ef(new k(t.a,t.b),e),$d(new k(n.a,n.b),a),ef(new k(i.a,i.b),n)),o=!!c&&!(r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH||r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH),c=Kft(e,ef(new k(t.a,t.b),e),n,a),c&&((r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH)==(r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH)||o?l=r.Math.min(l,Ih(ef(c,n))):s=!0),c=Kft(e,ef(new k(t.a,t.b),e),i,a),c&&(s||(r.Math.abs(c.a-e.a)<=kH&&r.Math.abs(c.b-e.b)<=kH)==(r.Math.abs(c.a-t.a)<=kH&&r.Math.abs(c.b-t.b)<=kH)||o)&&(l=r.Math.min(l,Ih(ef(c,i)))),l}function Cht(e){Wo(e,new oA(ga(ya(ha(va(_a(new Zt,hR),gbt),`Minimizes the stress within a layout using stress majorization. Stress exists if the euclidean distance between a pair of nodes doesn't match their graph theoretic distance, that is, the shortest path between the two nodes. The method allows to specify individual edge lengths.`),new ree),YL))),B(e,hR,tR,hO(dJ)),B(e,hR,rR,(rd(),!0)),B(e,hR,sR,hO(tOt)),B(e,hR,gR,hO(nOt)),B(e,hR,oR,hO(rOt)),B(e,hR,cR,hO(eOt)),B(e,hR,iR,hO(pJ)),B(e,hR,lR,hO(iOt)),B(e,hR,dbt,hO(uJ)),B(e,hR,pbt,hO(cJ)),B(e,hR,mbt,hO(lJ)),B(e,hR,hbt,hO(fJ)),B(e,hR,fbt,hO(sJ))}function wht(e){var t=null,n,r,i,a,o,s,c;for(r=new w(e);r.a0&&n.c==0&&(!t&&(t=new T),Mr(t.c,n));if(t)for(;t.c.length!=0;){if(n=P(Ay(t,0),239),n.b&&n.b.c.length>0){for(a=(!n.b&&(n.b=new T),new w(n.b));a.aAb(e,n,0))return new Kc(i,n)}else if(D(Eu(i.g,i.d[0]).a)>D(Eu(n.g,n.d[0]).a))return new Kc(i,n)}for(s=(!n.e&&(n.e=new T),n.e).Kc();s.Ob();)o=P(s.Pb(),239),c=(!o.b&&(o.b=new T),o.b),av(0,c.c.length),Ts(c.c,0,n),o.c==c.c.length&&Mr(t.c,o)}return null}function Tht(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_;for(t.Ug(`Interactive crossing minimization`,1),o=0,a=new w(e.b);a.a0&&(n+=c.n.a+c.o.a/2,++d),m=new w(c.j);m.a0&&(n/=d),_=V(Z9,hI,28,r.a.c.length,15,1),s=0,l=new w(r.a);l.a=s&&i<=c)s<=i&&a<=c?r+=2:s<=i?(e.b[r]=c+1,o+=2):a<=c?(n[u++]=i,n[u++]=s-1,r+=2):(n[u++]=i,n[u++]=s-1,e.b[r]=c+1,o+=2);else if(c2?(d=new T,nw(d,new $_(v,1,v.b)),o=dvt(d,b+e.a),y=new wj(o),VC(y,t),Mr(n.c,y)):y=P(i?xh(e.b,xA(t)):xh(e.b,SA(t)),272),l=xA(t),i&&(l=SA(t)),s=met(_,l),u=b+e.a,s.a?(u+=r.Math.abs(_.b-f.b),g=new k(f.a,(f.b+_.b)/2)):(u+=r.Math.abs(_.a-f.a),g=new k((f.a+_.a)/2,f.b)),Qh(i?e.d:e.c,t,new u3e(y,s,g,u)),Qh(e.b,t,y),h=(!t.n&&(t.n=new F(Q5,t,1,7)),t.n),m=new Lu(h);m.e!=m.i.gc();)p=P(gO(m),135),a=OM(e,p,!0,0,0),Mr(n.c,a)}function Dht(e){var t,n,r,i,a,o,s;if(!e.A.dc()){if(e.A.Hc((TD(),b5))&&(P(ig(e.b,(nP(),Z8)),127).k=!0,P(ig(e.b,m5),127).k=!0,t=e.q!=(rA(),z8)&&e.q!=R8,Ide(P(ig(e.b,X8),127),t),Ide(P(ig(e.b,g5),127),t),Ide(e.g,t),e.A.Hc(x5)&&(P(ig(e.b,Z8),127).j=!0,P(ig(e.b,m5),127).j=!0,P(ig(e.b,X8),127).k=!0,P(ig(e.b,g5),127).k=!0,e.g.k=!0)),e.A.Hc(y5))for(e.a.j=!0,e.a.k=!0,e.g.j=!0,e.g.k=!0,s=e.B.Hc((UM(),O5)),i=sO(),a=0,o=i.length;a0),P(u.a.Xb(u.c=--u.b),18));a!=r&&u.b>0;)e.a[a.p]=!0,e.a[r.p]=!0,a=(jd(u.b>0),P(u.a.Xb(u.c=--u.b),18));u.b>0&&Fh(u)}}function Aht(e,t,n){var r,i,a,o,s,c,l,u,d,f,p;if(!e.b)return!1;for(o=null,f=null,c=new $y(null,null),i=1,c.a[1]=e.b,d=c;d.a[i];)l=i,s=f,f=d,d=d.a[i],r=e.a.Ne(t,d.d),i=r<0?0:1,r==0&&(!n.c||rg(d.e,n.d))&&(o=d),!(d&&d.b)&&!Ji(d.a[i])&&(Ji(d.a[1-i])?f=f.a[l]=FS(d,i):Ji(d.a[1-i])||(p=f.a[1-l],p&&(!Ji(p.a[1-l])&&!Ji(p.a[l])?(f.b=!1,p.b=!0,d.b=!0):(a=+(s.a[1]==f),Ji(p.a[l])?s.a[a]=SBe(f,l):Ji(p.a[1-l])&&(s.a[a]=FS(f,l)),d.b=s.a[a].b=!0,s.a[a].a[0].b=!1,s.a[a].a[1].b=!1))));return o&&(n.b=!0,n.d=o.e,d!=o&&(u=new $y(d.d,d.e),V7e(e,c,o,u),f==o&&(f=u)),f.a[+(f.a[1]==d)]=d.a[+!d.a[0]],--e.c),e.b=c.a[1],e.b&&(e.b.b=!1),n.b}function jht(e){var t,n,i,a,o,s,c,l,u,d,f,p;for(a=new w(e.a.a.b);a.a0?i-=864e5:i+=864e5,c=new gDe(yE(LC(t.q.getTime()),i))),u=new na,l=e.a.length,a=0;a=97&&r<=122||r>=65&&r<=90){for(o=a+1;o=l)throw E(new Fi(`Missing trailing '`));o+1=14&&u<=16))?t.a._b(r)?(n.a?gl(n.a,n.b):n.a=new Gu(n.d),ml(n.a,`[...]`)):(s=rS(r),l=new jp(t),jy(n,Fht(s,l))):j(r,183)?jy(n,Ftt(P(r,183))):j(r,195)?jy(n,z5e(P(r,195))):j(r,201)?jy(n,F9e(P(r,201))):j(r,2111)?jy(n,B5e(P(r,2111))):j(r,53)?jy(n,Ptt(P(r,53))):j(r,376)?jy(n,unt(P(r,376))):j(r,846)?jy(n,Ntt(P(r,846))):j(r,109)&&jy(n,Mtt(P(r,109))):jy(n,r==null?IP:PE(r));return n.a?n.e.length==0?n.a.a:n.a.a+(``+n.e):n.c}function qN(e,t){var n,r,i,a=e.F;t==null?(e.F=null,Gw(e,null)):(e.F=(Gh(t),t),r=Nl(t,mA(60)),r==-1?(i=t,Nl(t,mA(46))==-1&&(r=Nl(t,mA(91)),r!=-1&&(i=(Zy(0,r,t.length),t.substr(0,r))),!ff(i,DP)&&!ff(i,BU)&&!ff(i,VU)&&!ff(i,HU)&&!ff(i,UU)&&!ff(i,WU)&&!ff(i,GU)&&!ff(i,KU)?(i=Swt,r!=-1&&(i+=``+(sv(r,t.length+1),t.substr(r)))):i=t),Gw(e,i),i==t&&(e.F=e.D)):(i=(Zy(0,r,t.length),t.substr(0,r)),Nl(t,mA(46))==-1&&!ff(i,DP)&&!ff(i,BU)&&!ff(i,VU)&&!ff(i,HU)&&!ff(i,UU)&&!ff(i,WU)&&!ff(i,GU)&&!ff(i,KU)&&(i=Swt),n=Hu(t,mA(62)),n!=-1&&(i+=``+(sv(n+1,t.length+1),t.substr(n+1))),Gw(e,i))),e.Db&4&&!(e.Db&1)&&AC(e,new Sm(e,1,5,a,t))}function Iht(e,t){var n,r,i,a,o,s,c=t.length-1,l,u,d;if(s=(sv(c,t.length),t.charCodeAt(c)),s==93){if(o=Nl(t,mA(91)),o>=0)return i=F1e(e,(Zy(1,o,t.length),t.substr(1,o-1))),u=(Zy(o+1,c,t.length),t.substr(o+1,c-(o+1))),V_t(e,u,i)}else{if(n=-1,HTt??=RegExp(`\\d`),HTt.test(String.fromCharCode(s))&&(n=pf(t,mA(46),c-1),n>=0)){r=P(wy(e,lqe(e,(Zy(1,n,t.length),t.substr(1,n-1))),!1),61),l=0;try{l=GM((sv(n+1,t.length+1),t.substr(n+1)),xF,AP)}catch(e){throw e=ew(e),j(e,130)?(a=e,E(new Nb(a))):E(e)}if(l>16==-10?n=P(e.Cb,292).Yk(t,n):e.Db>>16==-15&&(!t&&(t=(CP(),q7)),!l&&(l=(CP(),q7)),e.Cb.Yh()&&(c=new Hb(e.Cb,1,13,l,t,NO(Ib(P(e.Cb,62)),e),!1),n?n.nj(c):n=c));else if(j(e.Cb,90))e.Db>>16==-23&&(j(t,90)||(t=(CP(),J7)),j(l,90)||(l=(CP(),J7)),e.Cb.Yh()&&(c=new Hb(e.Cb,1,10,l,t,NO(Jv(P(e.Cb,29)),e),!1),n?n.nj(c):n=c));else if(j(e.Cb,457))for(s=P(e.Cb,850),o=(!s.b&&(s.b=new Sr(new ui)),s.b),a=(r=new EC(new Fn(o.a).a),new Cr(r));a.a.b;)i=P(MS(a.a).ld(),89),n=JN(i,Rj(i,s),n)}return n}function zht(e,t){var n,r,i,a,o=ki(Od(J(e,(mP(),k1)))),s,c,l,u,d,f=P(J(e,e0),21);for(c=!1,l=!1,d=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));d.e!=d.i.gc()&&(!c||!l);){for(a=P(gO(d),123),s=0,i=jm(oS(U(O(KW,1),FP,20,0,[(!a.d&&(a.d=new cf(U5,a,8,5)),a.d),(!a.e&&(a.e=new cf(U5,a,7,4)),a.e)])));Cj(i)&&(r=P(by(i),74),u=o&&uj(r)&&ki(Od(J(r,A1))),n=$pt((!r.b&&(r.b=new cf(H5,r,4,7)),r.b),a)?e==I_(cA(P(H((!r.c&&(r.c=new cf(H5,r,5,8)),r.c),0),84))):e==I_(cA(P(H((!r.b&&(r.b=new cf(H5,r,4,7)),r.b),0),84))),!((u||n)&&(++s,s>1))););(s>0||f.Hc((rj(),G8))&&(!a.n&&(a.n=new F(Q5,a,1,7)),a.n).i>0)&&(c=!0),s>1&&(l=!0)}c&&t.Fc((uM(),KZ)),l&&t.Fc((uM(),qZ))}function Bht(e){var t,n,i,a,o,s,c,l,u,d,f,p=P(J(e,(vP(),w6)),21);if(p.dc())return null;if(c=0,s=0,p.Hc((TD(),b5))){for(d=P(J(e,I6),101),i=2,n=2,a=2,o=2,t=I_(e)?P(J(I_(e),p6),88):P(J(e,p6),88),u=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));u.e!=u.i.gc();)if(l=P(gO(u),123),f=P(J(l,B6),64),f==(nP(),h5)&&(f=Wdt(l,t),OO(l,B6,f)),d==(rA(),R8))switch(f.g){case 1:i=r.Math.max(i,l.i+l.g);break;case 2:n=r.Math.max(n,l.j+l.f);break;case 3:a=r.Math.max(a,l.i+l.g);break;case 4:o=r.Math.max(o,l.j+l.f)}else switch(f.g){case 1:i+=l.g+2;break;case 2:n+=l.f+2;break;case 3:a+=l.g+2;break;case 4:o+=l.f+2}c=r.Math.max(i,a),s=r.Math.max(n,o)}return iP(e,c,s,!0,!0)}function YN(e,t,n,i,a){var o,s,c,l,u,d,f,p,m,h,g,_,v,y=P(ay(Cx(hg(new Mp(null,new cv(t.d,16)),new Jpe(n)),new Ype(n)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),b,x;for(f=AP,d=xF,l=new w(t.b.j);l.a0,l?l&&(f=_.p,o?++f:--f,d=P(Ep(_.c.a,f),10),r=rZe(d),p=!(Kj(r,S,n[0])||rPe(r,S,n[0]))):p=!0),m=!1,x=t.D.i,x&&x.c&&s.e&&(u=o&&x.p>0||!o&&x.p=0){for(c=null,s=new bv(u.a,l+1);s.bs?1:Pl(!1,isNaN(s)))<0&&(fS(TV),(r.Math.abs(s-1)<=TV||s==1?0:s<1?-1:s>1?1:Pl(isNaN(s),!1))<0)&&(fS(TV),(r.Math.abs(0-c)<=TV||c==0?0:0c?1:Pl(!1,isNaN(c)))<0)&&(fS(TV),(r.Math.abs(c-1)<=TV||c==1?0:c<1?-1:c>1?1:Pl(isNaN(c),!1))<0)),o)}function qht(e){var t,n=e.D==null?e.B:e.D,r,i;if(t=Nl(n,mA(91)),t!=-1){r=(Zy(0,t,n.length),n.substr(0,t)),i=new $i;do i.a+=`[`;while((t=fd(n,91,++t))!=-1);ff(r,DP)?i.a+=`Z`:ff(r,BU)?i.a+=`B`:ff(r,VU)?i.a+=`C`:ff(r,HU)?i.a+=`D`:ff(r,UU)?i.a+=`F`:ff(r,WU)?i.a+=`I`:ff(r,GU)?i.a+=`J`:ff(r,KU)?i.a+=`S`:(i.a+=`L`,i.a+=``+r,i.a+=`;`);try{return null}catch(e){if(e=ew(e),!j(e,63))throw E(e)}}else if(Nl(n,mA(46))==-1){if(ff(n,DP))return J9;if(ff(n,BU))return X9;if(ff(n,VU))return K9;if(ff(n,HU))return Z9;if(ff(n,UU))return Q9;if(ff(n,WU))return q9;if(ff(n,GU))return Y9;if(ff(n,KU))return $9}return null}function Jht(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;for(e.e=t,s=znt(t),S=new T,r=new w(s);r.a=0&&h=u.c.c.length?sHe((DA(),JJ),qJ):sHe((DA(),qJ),qJ),d*=2,o=n.a.g,n.a.g=r.Math.max(o,o+(d-o)),s=n.b.g,n.b.g=r.Math.max(s,s+(d-s)),a=t}}function Qht(e){var t,n,i,a;for(To(hg(new Mp(null,new cv(e.a.b,16)),new rre),new ire),r5e(e),To(hg(new Mp(null,new cv(e.a.b,16)),new are),new ore),e.c==(wE(),d8)&&(To(hg(ox(new Mp(null,new cv(new Pn(e.f),1)),new sre),new cre),new Vpe(e)),To(hg(gg(ox(ox(new Mp(null,new cv(e.d.b,16)),new lre),new ure),new dre),new fre),new Upe(e))),a=new k(cI,cI),t=new k(lI,lI),i=new w(e.a.b);i.a `):t.a+=`Root `,n=e.Dh().zb,ff(n.substr(0,3),`Elk`)?gl(t,(sv(3,n.length+1),n.substr(3))):t.a+=``+n,i=e.jh(),i){gl((t.a+=` `,t),i);return}if(j(e,366)&&(l=P(e,135).a,l)){gl((t.a+=` `,t),l);return}for(o=new Lu(e.kh());o.e!=o.i.gc();)if(a=P(gO(o),135),l=a.a,l){gl((t.a+=` `,t),l);return}if(j(e,326)&&(r=P(e,74),!r.b&&(r.b=new cf(H5,r,4,7)),r.b.i!=0&&(!r.c&&(r.c=new cf(H5,r,5,8)),r.c.i!=0))){for(t.a+=` (`,s=new cd((!r.b&&(r.b=new cf(H5,r,4,7)),r.b));s.e!=s.i.gc();)s.e>0&&(t.a+=PP),$N(P(gO(s),167),t);for(t.a+=kR,c=new cd((!r.c&&(r.c=new cf(H5,r,5,8)),r.c));c.e!=c.i.gc();)c.e>0&&(t.a+=PP),$N(P(gO(c),167),t);t.a+=`)`}}function $ht(e,t,n){var i,a,o,s,c,l,u,f;for(l=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));l.e!=l.i.gc();)for(c=P(gO(l),27),a=new pm(Vu(Ij(c).a.Kc(),new d));Cj(a);){if(i=P(by(a),74),!i.b&&(i.b=new cf(H5,i,4,7)),!(i.b.i<=1&&(!i.c&&(i.c=new cf(H5,i,5,8)),i.c.i<=1)))throw E(new Bi(`Graph must not contain hyperedges.`));if(!yj(i)&&c!=cA(P(H((!i.c&&(i.c=new cf(H5,i,5,8)),i.c),0),84)))for(u=new tOe,VC(u,i),W(u,(jS(),iJ),i),zde(u,P(nl(Kp(n.f,c)),153)),Hde(u,P(xh(n,cA(P(H((!i.c&&(i.c=new cf(H5,i,5,8)),i.c),0),84))),153)),M(t.c,u),s=new Lu((!i.n&&(i.n=new F(Q5,i,1,7)),i.n));s.e!=s.i.gc();)o=P(gO(s),135),f=new $Ve(u,o.a),VC(f,o),W(f,iJ,o),f.e.a=r.Math.max(o.g,1),f.e.b=r.Math.max(o.f,1),Hft(f),M(t.d,f)}}function egt(e,t,n){var i,a,o,s,c,l,u,d,f,p;switch(n.Ug(`Node promotion heuristic`,1),e.i=t,e.r=P(K(t,(mP(),P1)),243),e.r!=(FM(),G0)&&e.r!=K0?Vgt(e):Zst(e),d=P(K(e.i,Gjt),17).a,o=new Jte,e.r.g){case 2:case 1:PN(e,o);break;case 3:for(e.r=X0,PN(e,o),l=0,c=new w(e.b);c.ae.k&&(e.r=q0,PN(e,o));break;case 4:for(e.r=X0,PN(e,o),u=0,a=new w(e.c);a.ae.n&&(e.r=J0,PN(e,o));break;case 6:p=C_(r.Math.ceil(e.g.length*d/100)),PN(e,new kpe(p));break;case 5:f=C_(r.Math.ceil(e.e*d/100)),PN(e,new Ape(f));break;case 8:yvt(e,!0);break;case 9:yvt(e,!1);break;default:PN(e,o)}e.r!=G0&&e.r!=K0?est(e,t):xlt(e,t),n.Vg()}function tgt(e){var t,n,r,i,a,o,s,c,l,u,d=e.b,f,p,m,h,g,_,v,y;for(u=new bv(d,0),qd(u,new Eh(e)),v=!1,o=1;u.b0&&(p.d+=d.n.d,p.d+=d.d),p.a>0&&(p.a+=d.n.a,p.a+=d.d),p.b>0&&(p.b+=d.n.b,p.b+=d.d),p.c>0&&(p.c+=d.n.c,p.c+=d.d),p}function rgt(e,t,n){var i,a,o,s,c,l,u,d,f,p=n.d,m,h;for(f=n.c,o=new k(n.f.a+n.d.b+n.d.c,n.f.b+n.d.d+n.d.a),s=o.b,u=new w(e.a);u.a0&&(e.c[t.c.p][t.p].d+=Lj(e.i,24)*kI*.07000000029802322-.03500000014901161,e.c[t.c.p][t.p].a=e.c[t.c.p][t.p].d/e.c[t.c.p][t.p].b)}}function sgt(e){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;for(m=new w(e);m.ai.d,i.d=r.Math.max(i.d,t),c&&n&&(i.d=r.Math.max(i.d,i.a),i.a=i.d+a);break;case 3:n=t>i.a,i.a=r.Math.max(i.a,t),c&&n&&(i.a=r.Math.max(i.a,i.d),i.d=i.a+a);break;case 2:n=t>i.c,i.c=r.Math.max(i.c,t),c&&n&&(i.c=r.Math.max(i.b,i.c),i.b=i.c+a);break;case 4:n=t>i.b,i.b=r.Math.max(i.b,t),c&&n&&(i.b=r.Math.max(i.b,i.c),i.c=i.b+a)}}}function ugt(e,t){var n,r,i,a,o,s,c,l=``,u;return t.length==0?e.ne(ryt,wF,-1,-1):(u=qA(t),ff(u.substr(0,3),`at `)&&(u=(sv(3,u.length+1),u.substr(3))),u=u.replace(/\[.*?\]/g,``),o=u.indexOf(`(`),o==-1?(o=u.indexOf(`@`),o==-1?(l=u,u=``):(l=qA((sv(o+1,u.length+1),u.substr(o+1))),u=qA((Zy(0,o,u.length),u.substr(0,o))))):(n=u.indexOf(`)`,o),l=(Zy(o+1,n,u.length),u.substr(o+1,n-(o+1))),u=qA((Zy(0,o,u.length),u.substr(0,o)))),o=Nl(u,mA(46)),o!=-1&&(u=(sv(o+1,u.length+1),u.substr(o+1))),(u.length==0||ff(u,`Anonymous function`))&&(u=wF),s=Hu(l,mA(58)),i=pf(l,mA(58),s-1),c=-1,r=-1,a=ryt,s!=-1&&i!=-1&&(a=(Zy(0,i,l.length),l.substr(0,i)),c=dEe((Zy(i+1,s,l.length),l.substr(i+1,s-(i+1)))),r=dEe((sv(s+1,l.length+1),l.substr(s+1)))),e.ne(a,u,c,r))}function dgt(e){var t,n,r,i,a,o,s,c,l,u,d;for(l=new w(e);l.a0||u.j==g5&&u.e.c.length-u.g.c.length<0)){t=!1;break}for(i=new w(u.g);i.a=u&&S>=_&&(p+=h.n.b+g.n.b+g.a.b-x,++c));if(n)for(s=new w(y.e);s.a=u&&S>=_&&(p+=h.n.b+g.n.b+g.a.b-x,++c))}c>0&&(ee+=p/c,++m)}m>0?(t.a=a*ee/m,t.g=m):(t.a=0,t.g=0)}function pgt(e){var t,n,r,i,a=e.f.b,o,s,c,l,u,d,f=a.a,p,m,h,g,_,v,y,b,x,S,ee;for(u=a.b,m=e.e.g,p=e.e.f,Ql(e.e,a.a,a.b),S=f/m,ee=u/p,l=new Lu(ag(e.e));l.e!=l.i.gc();)c=P(gO(l),135),Gx(c,c.i*S),Kx(c,c.j*ee);for(v=new Lu(og(e.e));v.e!=v.i.gc();)_=P(gO(v),123),b=_.i,x=_.j,b>0&&Gx(_,b*S),x>0&&Kx(_,x*ee);for(xC(e.b,new eee),t=new T,s=new EC(new Fn(e.c).a);s.b;)o=MS(s),r=P(o.ld(),74),n=P(o.md(),407).a,i=cM(r,!1,!1),d=$5e(xA(r),FA(i),n),cN(d,i),y=Q7e(r),y&&Ab(t,y,0)==-1&&(Mr(t.c,y),$Fe(y,(jd(d.b!=0),P(d.a.a.c,8)),n));for(g=new EC(new Fn(e.d).a);g.b;)h=MS(g),r=P(h.ld(),74),n=P(h.md(),407).a,i=cM(r,!1,!1),d=$5e(SA(r),Ew(FA(i)),n),d=Ew(d),cN(d,i),y=$7e(r),y&&Ab(t,y,0)==-1&&(Mr(t.c,y),$Fe(y,(jd(d.b!=0),P(d.c.b.c,8)),n))}function mgt(e,t,n,r){var i,a,o,s=new Agt(t),c;return xot(s,r),i=!0,e&&e.pf((vP(),p6))&&(a=P(e.of((vP(),p6)),88),i=a==(GT(),r8)||a==t8||a==n8),Uct(s,!1),Dx(s.e.Rf(),new Af(s,!1,i)),x_(s,s.f,(Ix(),XK),(nP(),Z8)),x_(s,s.f,QK,m5),x_(s,s.g,XK,g5),x_(s,s.g,QK,X8),e4e(s,Z8),e4e(s,m5),VFe(s,X8),VFe(s,g5),Rd(),o=s.A.Hc((TD(),v5))&&s.B.Hc((UM(),D5))?w0e(s):null,o&&Eve(s.a,o),lgt(s),A3e(s),j3e(s),Dht(s),hdt(s),k6e(s),eO(s,Z8),eO(s,m5),flt(s),Gpt(s),n?(I1e(s),A6e(s),eO(s,X8),eO(s,g5),c=s.B.Hc((UM(),O5)),wtt(s,c,Z8),wtt(s,c,m5),Ttt(s,c,X8),Ttt(s,c,g5),To(new Mp(null,new cv(new Bn(s.i),0)),new it),To(hg(new Mp(null,ch(s.r).a.oc()),new at),new ot),k5e(s),s.e.Pf(s.o),To(new Mp(null,ch(s.r).a.oc()),new st),s.o):s.o}function hgt(e){var t,n,i,a,o,s,c,l,u=cI,d,f,p,m,h,g;for(i=new w(e.a.b);i.a1)for(m=new Xpt(h,b,i),ly(b,new Qxe(e,m)),Mr(s.c,m),f=b.a.ec().Kc();f.Ob();)d=P(f.Pb(),42),Db(o,d.b);if(c.a.gc()>1)for(m=new Xpt(h,c,i),ly(c,new $xe(e,m)),Mr(s.c,m),f=c.a.ec().Kc();f.Ob();)d=P(f.Pb(),42),Db(o,d.b)}}function bgt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g=e.n,_=e.o,v;if(p=e.d,f=D(N(gD(e,(mP(),o0)))),t){for(d=f*(t.gc()-1),m=0,l=t.Kc();l.Ob();)s=P(l.Pb(),10),d+=s.o.a,m=r.Math.max(m,s.o.b);for(v=g.a-(d-_.a)/2,o=g.b-p.d+m,i=_.a/(t.gc()+1),a=i,c=t.Kc();c.Ob();)s=P(c.Pb(),10),s.n.a=v,s.n.b=o-s.o.b,v+=s.o.a+f,u=Uat(s),u.n.a=s.o.a/2-u.a.a,u.n.b=s.o.b,h=P(K(s,(Y(),pQ)),12),h.e.c.length+h.g.c.length==1&&(h.n.a=a-h.a.a,h.n.b=0,G_(h,e)),a+=i}if(n){for(d=f*(n.gc()-1),m=0,l=n.Kc();l.Ob();)s=P(l.Pb(),10),d+=s.o.a,m=r.Math.max(m,s.o.b);for(v=g.a-(d-_.a)/2,o=g.b+_.b+p.a-m,i=_.a/(n.gc()+1),a=i,c=n.Kc();c.Ob();)s=P(c.Pb(),10),s.n.a=v,s.n.b=o,v+=s.o.a+f,u=Uat(s),u.n.a=s.o.a/2-u.a.a,u.n.b=0,h=P(K(s,(Y(),pQ)),12),h.e.c.length+h.g.c.length==1&&(h.n.a=a-h.a.a,h.n.b=_.b,G_(h,e)),a+=i}}function xgt(e,t){var n,i,a,o,s,c;if(P(K(t,(Y(),OQ)),21).Hc((uM(),KZ))){for(c=new w(t.a);c.a=0&&o0&&(P(ig(e.b,t),127).a.b=n)}function Ogt(e,t,n,r){var i,a,o,s,c,l,u,d,f=D(N(K(e,(mP(),g0)))),p=D(N(K(e,_0))),m,h;if(d=D(N(K(e,m0))),s=e.o,a=P(Ep(e.j,0),12),o=a.n,h=jet(a,d),h){if(t.Hc((rj(),G8)))switch(P(K(e,(Y(),TQ)),64).g){case 1:h.c=(s.a-h.b)/2-o.a,h.d=p;break;case 3:h.c=(s.a-h.b)/2-o.a,h.d=-p-h.a;break;case 2:n&&a.e.c.length==0&&a.g.c.length==0?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=s.b+p-o.b,h.c=-f-h.b;break;case 4:n&&a.e.c.length==0&&a.g.c.length==0?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=s.b+p-o.b,h.c=f}else if(t.Hc(q8))switch(P(K(e,(Y(),TQ)),64).g){case 1:case 3:h.c=o.a+f;break;case 2:case 4:n&&!a.c?(u=r?h.a:P(Ep(a.f,0),72).o.b,h.d=(s.b-u)/2-o.b):h.d=o.b+p}for(i=h.d,l=new w(a.f);l.a=e.length)return{done:!0};var r=e[n++];return{value:[r,t.get(r)],done:!1}}}},Oct()||(e.prototype.createObject=function(){return{}},e.prototype.get=function(e){return this.obj[`:`+e]},e.prototype.set=function(e,t){this.obj[`:`+e]=t},e.prototype[TI]=function(e){delete this.obj[`:`+e]},e.prototype.keys=function(){var e=[];for(var t in this.obj)t.charCodeAt(0)==58&&e.push(t.substring(1));return e}),e}function tP(){tP=C,t4=new yr(sbt),new yr(cbt),new Wd(`DEPTH`,G(0)),G2=new Wd(`FAN`,G(0)),RPt=new Wd(ixt,G(0)),a4=new Wd(`ROOT`,(rd(),!1)),Y2=new Wd(`LEFTNEIGHBOR`,null),HPt=new Wd(`RIGHTNEIGHBOR`,null),X2=new Wd(`LEFTSIBLING`,null),i4=new Wd(`RIGHTSIBLING`,null),W2=new Wd(`DUMMY`,!1),new Wd(`LEVEL`,G(0)),VPt=new Wd(`REMOVABLE_EDGES`,new vo),o4=new Wd(`XCOOR`,G(0)),s4=new Wd(`YCOOR`,G(0)),Z2=new Wd(`LEVELHEIGHT`,0),$2=new Wd(`LEVELMIN`,0),Q2=new Wd(`LEVELMAX`,0),K2=new Wd(`GRAPH_XMIN`,0),q2=new Wd(`GRAPH_YMIN`,0),zPt=new Wd(`GRAPH_XMAX`,0),BPt=new Wd(`GRAPH_YMAX`,0),LPt=new Wd(`COMPACT_LEVEL_ASCENSION`,!1),U2=new Wd(`COMPACT_CONSTRAINTS`,new T),J2=new Wd(`ID`,``),n4=new Wd(`POSITION`,G(0)),r4=new Wd(`PRELIM`,0),e4=new Wd(`MODIFIER`,0),H2=new yr(lbt),V2=new yr(ubt)}function Fgt(e){Bdt();var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(e==null)return null;if(d=e.length*8,d==0)return``;for(s=d%24,p=d/24|0,f=s==0?p:p+1,a=null,a=V(K9,EF,28,f*4,15,1),l=0,u=0,t=0,n=0,r=0,o=0,i=0,c=0;c>24,l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,h=n&-128?(n>>4^240)<<24>>24:n>>4<<24>>24,g=r&-128?(r>>6^252)<<24>>24:r>>6<<24>>24,a[o++]=j9[m],a[o++]=j9[h|l<<4],a[o++]=j9[u<<2|g],a[o++]=j9[r&63];return s==8?(t=e[i],l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,a[o++]=j9[m],a[o++]=j9[l<<4],a[o++]=61,a[o++]=61):s==16&&(t=e[i],n=e[i+1],u=(n&15)<<24>>24,l=(t&3)<<24>>24,m=t&-128?(t>>2^192)<<24>>24:t>>2<<24>>24,h=n&-128?(n>>4^240)<<24>>24:n>>4<<24>>24,a[o++]=j9[m],a[o++]=j9[h|l<<4],a[o++]=j9[u<<2],a[o++]=61),ND(a,0,a.length)}function Igt(e,t){var n,i,a,o,s,c,l;if(e.e==0&&e.p>0&&(e.p=-(e.p-1)),e.p>xF&&aHe(t,e.p-VF),s=t.q.getDate(),j_(t,1),e.k>=0&&vRe(t,e.k),e.c>=0?j_(t,e.c):e.k>=0?(l=new xZe(t.q.getFullYear()-VF,t.q.getMonth(),35),i=35-l.q.getDate(),j_(t,r.Math.min(i,s))):j_(t,s),e.f<0&&(e.f=t.q.getHours()),e.b>0&&e.f<12&&(e.f+=12),Xwe(t,e.f==24&&e.g?0:e.f),e.j>=0&&QUe(t,e.j),e.n>=0&&qWe(t,e.n),e.i>=0&&hCe(t,yE(bE(Wk(LC(t.q.getTime()),DF),DF),e.i)),e.a&&(a=new uo,aHe(a,a.q.getFullYear()-VF-80),rs(LC(t.q.getTime()),LC(a.q.getTime()))&&aHe(t,a.q.getFullYear()-VF+100)),e.d>=0){if(e.c==-1)n=(7+e.d-t.q.getDay())%7,n>3&&(n-=7),c=t.q.getMonth(),j_(t,t.q.getDate()+n),t.q.getMonth()!=c&&j_(t,t.q.getDate()+(n>0?-7:7));else if(t.q.getDay()!=e.d)return!1}return e.o>xF&&(o=t.q.getTimezoneOffset(),hCe(t,yE(LC(t.q.getTime()),(e.o-o)*60*DF))),!0}function Lgt(e,t){var n,r,i=K(t,(Y(),WQ)),a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b;if(j(i,207)){for(m=P(i,27),h=t.e,f=new Vl(t.c),a=t.d,f.a+=a.b,f.b+=a.d,b=P(J(m,(mP(),q1)),181),$u(b,(UM(),w5))&&(p=P(J(m,Xjt),107),Mde(p,a.a),Vde(p,a.d),Nde(p,a.b),Bde(p,a.c)),n=new T,u=new w(t.a);u.ar.c.length-1;)M(r,new Kc(zL,zV));n=P(K(i,p4),17).a,ql(P(K(e,c4),88))?(i.e.aD(N((ov(n,r.c.length),P(r.c[n],42)).b))&&An((ov(n,r.c.length),P(r.c[n],42)),i.e.a+i.f.a)):(i.e.bD(N((ov(n,r.c.length),P(r.c[n],42)).b))&&An((ov(n,r.c.length),P(r.c[n],42)),i.e.b+i.f.b))}for(a=dO(e.b,0);a.b!=a.d.c;)i=P(Lv(a),40),n=P(K(i,(rN(),p4)),17).a,W(i,(tP(),$2),N((ov(n,r.c.length),P(r.c[n],42)).a)),W(i,Q2,N((ov(n,r.c.length),P(r.c[n],42)).b));t.Vg()}function Vgt(e){var t,n,i,a,o,s,c,l,u,f,p,m,h,g,_;for(e.o=D(N(K(e.i,(mP(),v0)))),e.f=D(N(K(e.i,f0))),e.j=e.i.b.c.length,c=e.j-1,m=0,e.k=0,e.n=0,e.b=Oy(V(DG,X,17,e.j,0,1)),e.c=Oy(V(TG,X,345,e.j,7,1)),s=new w(e.i.b);s.a0&&M(e.q,f),M(e.p,f);t-=i,h=l+t,u+=t*e.f,uy(e.b,c,G(h)),uy(e.c,c,u),e.k=r.Math.max(e.k,h),e.n=r.Math.max(e.n,u),e.e+=t,t+=_}}function nP(){nP=C;var e;h5=new Vc(dL,0),Z8=new Vc(_L,1),X8=new Vc(vL,2),m5=new Vc(yL,3),g5=new Vc(bL,4),n5=(Vg(),new oa((e=P(Ba(_5),9),new xf(e,P(Yd(e,e.length),9),0)))),r5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[]))),Q8=yT(Zp(X8,U(O(_5,1),TR,64,0,[]))),d5=yT(Zp(m5,U(O(_5,1),TR,64,0,[]))),p5=yT(Zp(g5,U(O(_5,1),TR,64,0,[]))),c5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[m5]))),t5=yT(Zp(X8,U(O(_5,1),TR,64,0,[g5]))),u5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[g5]))),i5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8]))),f5=yT(Zp(m5,U(O(_5,1),TR,64,0,[g5]))),$8=yT(Zp(X8,U(O(_5,1),TR,64,0,[m5]))),s5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,g5]))),e5=yT(Zp(X8,U(O(_5,1),TR,64,0,[m5,g5]))),l5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[m5,g5]))),a5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,m5]))),o5=yT(Zp(Z8,U(O(_5,1),TR,64,0,[X8,m5,g5])))}function Hgt(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;for(t.Ug(Lbt,1),h=new T,S=new T,l=new w(e.b);l.a0&&(x-=h),mmt(s,x),f=0,m=new w(s.a);m.a0),c.a.Xb(c.c=--c.b)),l=.4*i*f,!o&&c.b0&&(c=(sv(0,t.length),t.charCodeAt(0)),c!=64)){if(c==37&&(d=t.lastIndexOf(`%`),l=!1,d!=0&&(d==f-1||(l=(sv(d+1,t.length),t.charCodeAt(d+1)==46))))){if(o=(Zy(1,d,t.length),t.substr(1,d-1)),y=ff(`%`,o)?null:n_t(o),r=0,l)try{r=GM((sv(d+2,t.length+1),t.substr(d+2)),xF,AP)}catch(e){throw e=ew(e),j(e,130)?(s=e,E(new Nb(s))):E(e)}for(g=NS(e.Gh());g.Ob();)if(m=IC(g),j(m,519)&&(i=P(m,598),v=i.d,(y==null?v==null:ff(y,v))&&r--==0))return i;return null}if(u=t.lastIndexOf(`.`),p=u==-1?t:(Zy(0,u,t.length),t.substr(0,u)),n=0,u!=-1)try{n=GM((sv(u+1,t.length+1),t.substr(u+1)),xF,AP)}catch(e){if(e=ew(e),j(e,130))p=t;else throw E(e)}for(p=ff(`%`,p)?null:n_t(p),h=NS(e.Gh());h.Ob();)if(m=IC(h),j(m,197)&&(a=P(m,197),_=a.xe(),(p==null?_==null:ff(p,_))&&n--==0))return a;return null}return Iht(e,t)}function Zgt(e){var t,n,r,i,a,o,s,c,l,u=new Dr,f,p,m,h,g,_,v,y;for(c=new g_,r=new w(e.a.a.b);r.at.d.c){if(m=e.c[t.a.d],_=e.c[f.a.d],m==_)continue;tM(Ao(ko(jo(Oo(new Zr,1),100),m),_))}}}}}function Qgt(e,t){var n,i,a,o,s,c,l,u,d,f,p=P(P(Dy(e.r,t),21),87),m,h,g,_,v,y,b,x,S,ee;if(t==(nP(),X8)||t==g5){Dgt(e,t);return}for(o=t==Z8?(KC(),dq):(KC(),mq),x=t==Z8?(Xb(),sq):(Xb(),aq),n=P(ig(e.b,t),127),i=n.i,a=i.c+Tx(U(O(Z9,1),hI,28,15,[n.n.b,e.C.b,e.k])),v=i.c+i.b-Tx(U(O(Z9,1),hI,28,15,[n.n.c,e.C.c,e.k])),s=pa(Pf(o),e.t),y=t==Z8?lI:cI,f=p.Kc();f.Ob();)u=P(f.Pb(),117),!(!u.c||u.c.d.c.length<=0)&&(_=u.b.Mf(),g=u.e,m=u.c,h=m.i,h.b=(l=m.n,m.e.a+l.b+l.c),h.a=(c=m.n,m.e.b+c.d+c.a),c_(x,Iyt),m.f=x,nb(m,(Cb(),iq)),h.c=g.a-(h.b-_.a)/2,S=r.Math.min(a,g.a),ee=r.Math.max(v,g.a+_.a),h.cee&&(h.c=ee-h.b),M(s.d,new $p(h,qT(s,h))),y=t==Z8?r.Math.max(y,g.b+u.b.Mf().b):r.Math.min(y,g.b));for(y+=t==Z8?e.t:-e.t,b=nD((s.e=y,s)),b>0&&(P(ig(e.b,t),127).a.b=b),d=p.Kc();d.Ob();)u=P(d.Pb(),117),!(!u.c||u.c.d.c.length<=0)&&(h=u.c.i,h.c-=u.e.a,h.d-=u.e.b)}function $gt(e){var t=new Dr,n,r,i,a,o,s,c,l,u,f,p,m;for(c=new Lu(e);c.e!=c.i.gc();){for(s=P(gO(c),27),n=new Jr,Qh(Rq,s,n),m=new It,i=P(ay(new Mp(null,new ih(new pm(Vu(Fj(s).a.Kc(),new d)))),pNe(m,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)])))),85),tJe(n,P(i.xc((rd(),!0)),16),new Lt),r=P(ay(hg(P(i.xc(!1),15).Lc(),new Rt),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),o=r.Kc();o.Ob();)a=P(o.Pb(),74),p=Q7e(a),p&&(l=P(nl(Kp(t.f,p)),21),l||(l=wst(p),XA(t.f,p,l)),XS(n,l));for(i=P(ay(new Mp(null,new ih(new pm(Vu(Ij(s).a.Kc(),new d)))),pNe(m,cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK])))),85),tJe(n,P(i.xc(!0),16),new zt),r=P(ay(hg(P(i.xc(!1),15).Lc(),new Bt),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),f=r.Kc();f.Ob();)u=P(f.Pb(),74),p=$7e(u),p&&(l=P(nl(Kp(t.f,p)),21),l||(l=wst(p),XA(t.f,p,l)),XS(n,l))}}function e_t(e,t){wN();var n,r,i,a,o,s,c=dT(e,0)<0,l,u,d,f,p,m,h;if(c&&(e=kb(e)),dT(e,0)==0)switch(t){case 0:return`0`;case 1:return vI;case 2:return`0.00`;case 3:return`0.000`;case 4:return`0.0000`;case 5:return`0.00000`;case 6:return`0.000000`;default:return p=new ta,t<0?p.a+=`0E+`:p.a+=`0E`,p.a+=t==xF?`2147483648`:``+-t,p.a}u=18,d=V(K9,EF,28,u+1,15,1),n=u,h=e;do l=h,h=Wk(h,10),d[--n]=nm(yE(48,xE(l,bE(h,10))))&OF;while(dT(h,0)!=0);if(i=xE(xE(xE(u,n),t),1),t==0)return c&&(d[--n]=45),ND(d,n,u-n);if(t>0&&dT(i,-6)>=0){if(dT(i,0)>=0){for(a=n+nm(i),s=u-1;s>=a;s--)d[s+1]=d[s];return d[++a]=46,c&&(d[--n]=45),ND(d,n,u-n+1)}for(o=2;rs(o,yE(kb(i),1));o++)d[--n]=48;return d[--n]=46,d[--n]=48,c&&(d[--n]=45),ND(d,n,u-n)}return m=n+1,r=u,f=new na,c&&(f.a+=`-`),r-m>=1?(jh(f,d[n]),f.a+=`.`,f.a+=ND(d,n+1,u-n-1)):f.a+=ND(d,n,u-n),f.a+=`E`,dT(i,0)>0&&(f.a+=`+`),f.a+=``+bm(i),f.a}function iP(e,t,n,i,a){var o,s,c,l,u,d,f,p,m,h,g,_=new k(e.g,e.f),v,y,b,x,S,ee;if(g=Zet(e),g.a=r.Math.max(g.a,t),g.b=r.Math.max(g.b,n),ee=g.a/_.a,d=g.b/_.b,x=g.a-_.a,l=g.b-_.b,i)for(s=I_(e)?P(J(I_(e),(vP(),p6)),88):P(J(e,(vP(),p6)),88),c=A(J(e,(vP(),I6)))===A((rA(),R8)),y=new Lu((!e.c&&(e.c=new F(e7,e,9,9)),e.c));y.e!=y.i.gc();)switch(v=P(gO(y),123),b=P(J(v,B6),64),b==(nP(),h5)&&(b=Wdt(v,s),OO(v,B6,b)),b.g){case 1:c||Gx(v,v.i*ee);break;case 2:Gx(v,v.i+x),c||Kx(v,v.j*d);break;case 3:c||Gx(v,v.i*ee),Kx(v,v.j+l);break;case 4:c||Kx(v,v.j*d)}if(Ql(e,g.a,g.b),a)for(p=new Lu((!e.n&&(e.n=new F(Q5,e,1,7)),e.n));p.e!=p.i.gc();)f=P(gO(p),135),m=f.i+f.g/2,h=f.j+f.f/2,S=m/_.a,u=h/_.b,S+u>=1&&(S-u>0&&h>=0?(Gx(f,f.i+x),Kx(f,f.j+l*u)):S-u<0&&m>=0&&(Gx(f,f.i+x*S),Kx(f,f.j+l)));return OO(e,(vP(),w6),(TD(),o=P(Ba(S5),9),new xf(o,P(Yd(o,o.length),9),0))),new k(ee,d)}function t_t(e){Wo(e,new oA(ga(ya(ha(va(_a(new Zt,iH),`ELK Radial`),`A radial layout provider which is based on the algorithm of Peter Eades published in "Drawing free trees.", published by International Institute for Advanced Study of Social Information Science, Fujitsu Limited in 1991. The radial layouter takes a tree and places the nodes in radial order around the root. The nodes of the same tree level are placed on the same radius.`),new doe),iH))),B(e,iH,fV,hO(mIt)),B(e,iH,ZL,hO(vIt)),B(e,iH,sR,hO(cIt)),B(e,iH,gR,hO(lIt)),B(e,iH,oR,hO(uIt)),B(e,iH,cR,hO(sIt)),B(e,iH,iR,hO(dIt)),B(e,iH,lR,hO(pIt)),B(e,iH,tH,hO(k4)),B(e,iH,eH,hO(A4)),B(e,iH,$V,hO(hIt)),B(e,iH,nH,hO(N4)),B(e,iH,rH,hO(gIt)),B(e,iH,Ext,hO(_It)),B(e,iH,Txt,hO(fIt)),B(e,iH,xxt,hO(j4)),B(e,iH,Sxt,hO(M4)),B(e,iH,Cxt,hO(P4)),B(e,iH,wxt,hO(yIt)),B(e,iH,bxt,hO(oIt))}function aP(e){var t,n,r,i,a,o,s,c,l,u,d;if(e==null)throw E(new aa(IP));if(l=e,a=e.length,c=!1,a>0&&(t=(sv(0,e.length),e.charCodeAt(0)),(t==45||t==43)&&(e=(sv(1,e.length+1),e.substr(1)),--a,c=t==45)),a==0)throw E(new aa(sI+l+`"`));for(;e.length>0&&(sv(0,e.length),e.charCodeAt(0)==48);)e=(sv(1,e.length+1),e.substr(1)),--a;if(a>(xdt(),WTt)[10])throw E(new aa(sI+l+`"`));for(i=0;i0&&(d=-parseInt((Zy(0,r,e.length),e.substr(0,r)),10),e=(sv(r,e.length+1),e.substr(r)),a-=r,n=!1);a>=o;){if(r=parseInt((Zy(0,o,e.length),e.substr(0,o)),10),e=(sv(o,e.length+1),e.substr(o)),a-=o,n)n=!1;else{if(dT(d,s)<0)throw E(new aa(sI+l+`"`));d=bE(d,u)}d=xE(d,r)}if(dT(d,0)>0||!c&&(d=kb(d),dT(d,0)<0))throw E(new aa(sI+l+`"`));return d}function n_t(e){NN();var t,n,r,i,a,o,s,c;if(e==null)return null;if(i=Nl(e,mA(37)),i<0)return e;for(c=new Gu((Zy(0,i,e.length),e.substr(0,i))),t=V(X9,QH,28,4,15,1),s=0,r=0,o=e.length;ii+2&&hw((sv(i+1,e.length),e.charCodeAt(i+1)),NVt,PVt)&&hw((sv(i+2,e.length),e.charCodeAt(i+2)),NVt,PVt)){if(n=qje((sv(i+1,e.length),e.charCodeAt(i+1)),(sv(i+2,e.length),e.charCodeAt(i+2))),i+=2,r>0?(n&192)==128?t[s++]=n<<24>>24:r=0:n>=128&&((n&224)==192?(t[s++]=n<<24>>24,r=2):(n&240)==224?(t[s++]=n<<24>>24,r=3):(n&248)==240&&(t[s++]=n<<24>>24,r=4)),r>0){if(s==r){switch(s){case 2:jh(c,((t[0]&31)<<6|t[1]&63)&OF);break;case 3:jh(c,((t[0]&15)<<12|(t[1]&63)<<6|t[2]&63)&OF)}s=0,r=0}}else{for(a=0;a=2){if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i==0)n=(Ia(),a=new rn,a),tb((!e.a&&(e.a=new F(W5,e,6,6)),e.a),n);else if((!e.a&&(e.a=new F(W5,e,6,6)),e.a).i>1)for(p=new cd((!e.a&&(e.a=new F(W5,e,6,6)),e.a));p.e!=p.i.gc();)Yk(p);cN(t,P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166))}if(f)for(i=new Lu((!e.a&&(e.a=new F(W5,e,6,6)),e.a));i.e!=i.i.gc();)for(n=P(gO(i),166),u=new Lu((!n.a&&(n.a=new ju(z5,n,5)),n.a));u.e!=u.i.gc();)l=P(gO(u),377),c.a=r.Math.max(c.a,l.a),c.b=r.Math.max(c.b,l.b);for(s=new Lu((!e.n&&(e.n=new F(Q5,e,1,7)),e.n));s.e!=s.i.gc();)o=P(gO(s),135),d=P(J(o,h8),8),d&&$l(o,d.a,d.b),f&&(c.a=r.Math.max(c.a,o.i+o.g),c.b=r.Math.max(c.b,o.j+o.f));return c}function i_t(e,t,n,r,i){var a,o,s;if(gKe(e,t),o=t[0],a=mg(n.c,0),s=-1,FZe(n)){if(r>0){if(o+r>e.length)return!1;s=lj((Zy(0,o+r,e.length),e.substr(0,o+r)),t)}else s=lj(e,t)}switch(a){case 71:return s=LA(e,o,U(O(LG,1),X,2,6,[iyt,ayt]),t),i.e=s,!0;case 77:return ect(e,t,i,s,o);case 76:return tct(e,t,i,s,o);case 69:return itt(e,t,o,i);case 99:return att(e,t,o,i);case 97:return s=LA(e,o,U(O(LG,1),X,2,6,[`AM`,`PM`]),t),i.b=s,!0;case 121:return nct(e,t,o,s,n,i);case 100:return s<=0?!1:(i.c=s,!0);case 83:return s<0?!1:c0e(s,o,t[0],i);case 104:s==12&&(s=0);case 75:case 72:return s<0?!1:(i.f=s,i.g=!1,!0);case 107:return s<0?!1:(i.f=s,i.g=!0,!0);case 109:return s<0?!1:(i.j=s,!0);case 115:return s<0?!1:(i.n=s,!0);case 90:if(one[l]&&(_=l),f=new w(e.a.b);f.a1;){if(a=pot(t),f=o.g,h=P(J(t,i3),107),g=D(N(J(t,$4))),(!t.a&&(t.a=new F($5,t,10,11)),t.a).i>1&&D(N(J(t,(xM(),J4))))!=cI&&(o.c+(h.b+h.c))/(o.b+(h.d+h.a))1&&D(N(J(t,(xM(),q4))))!=cI&&(o.c+(h.b+h.c))/(o.b+(h.d+h.a))>g&&OO(a,(xM(),Z4),r.Math.max(D(N(J(t,Y4))),D(N(J(a,Z4)))-D(N(J(t,q4))))),m=new hSe(i,d),l=fvt(m,a,p),u=l.g,u>=f&&u==u){for(s=0;s<(!a.a&&(a.a=new F($5,a,10,11)),a.a).i;s++)ynt(e,P(H((!a.a&&(a.a=new F($5,a,10,11)),a.a),s),27),P(H((!t.a&&(t.a=new F($5,t,10,11)),t.a),s),27));fqe(t,m),PLe(o,l.c),NLe(o,l.b)}--c}OO(t,(xM(),W4),o.b),OO(t,G4,o.c),n.Vg()}function c_t(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y;for(t.Ug(`Interactive node layering`,1),n=new T,p=new w(e.a);p.a=c){jd(y.b>0),y.a.Xb(y.c=--y.b);break}_.a>l&&(i?(nw(i.b,_.b),i.a=r.Math.max(i.a,_.a),Fh(y)):(M(_.b,d),_.c=r.Math.min(_.c,l),_.a=r.Math.max(_.a,c),i=_))}i||(i=new qge,i.c=l,i.a=c,qd(y,i),M(i.b,d))}for(s=e.b,u=0,v=new w(n);v.am&&(o&&(yl(ee,p),yl(ne,G(u.b-1))),oe=n.b,se+=p+t,p=0,d=r.Math.max(d,n.b+n.c+ae)),Gx(c,oe),Kx(c,se),d=r.Math.max(d,oe+ae+n.c),p=r.Math.max(p,f),oe+=ae+t;if(d=r.Math.max(d,i),ie=se+p+n.a,ieGL,C=r.Math.abs(p.b-h.b)>GL,(!n&&ne&&C||n&&(ne||C))&&up(_.a,x)),XS(_.a,i),p=i.b==0?x:(jd(i.b!=0),P(i.c.b.c,8)),TXe(m,f,g),wYe(a)==te&&(Bh(te.i)!=a.a&&(g=new Fa,Fet(g,Bh(te.i),y)),W(_,f$,g)),R9e(m,_,y),d.a.zc(m,d);U_(_,S),K_(_,te)}for(u=d.a.ec().Kc();u.Ob();)l=P(u.Pb(),18),U_(l,null),K_(l,null);t.Vg()}function d_t(e,t){var n,r,i=P(K(e,(rN(),c4)),88),a,o,s,c,l,u=i==(GT(),t8)||i==n8?e8:n8,d,f;for(n=P(ay(hg(new Mp(null,new cv(e.b,16)),new gae),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),c=P(ay(gg(n.Oc(),new Ime(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),c.Gc(P(ay(gg(n.Oc(),new Lme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),16)),c.jd(new Rme(u)),f=new Ja(new zme(i)),r=new Dr,s=c.Kc();s.Ob();)o=P(s.Pb(),240),l=P(o.a,40),ki(Od(o.c))?(f.a.zc(l,(rd(),vG)),new nr(f.a.Zc(l,!1)).a.gc()>0&&Qh(r,l,P(new nr(f.a.Zc(l,!1)).a.Vc(),40)),new nr(f.a.ad(l,!0)).a.gc()>1&&Qh(r,h0e(f,l),l)):(new nr(f.a.Zc(l,!1)).a.gc()>0&&(a=P(new nr(f.a.Zc(l,!1)).a.Vc(),40),A(a)===A(nl(Kp(r.f,l)))&&P(K(l,(tP(),U2)),15).Fc(a)),new nr(f.a.ad(l,!0)).a.gc()>1&&(d=h0e(f,l),A(nl(Kp(r.f,d)))===A(l)&&P(K(d,(tP(),U2)),15).Fc(l)),f.a.Bc(l))}function f_t(e){var t,n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(e.gc()==1)return P(e.Xb(0),235);if(e.gc()<=0)return new Py;for(a=e.Kc();a.Ob();){for(n=P(a.Pb(),235),h=0,d=AP,f=AP,l=xF,u=xF,m=new w(n.e);m.ac&&(b=0,x+=s+v,s=0),vut(g,n,b,x),t=r.Math.max(t,b+_.a),s=r.Math.max(s,_.b),b+=_.a+v;return g}function p_t(e){Bdt();var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(e==null||(a=Wb(e),m=d1e(a),m%4!=0))return null;if(h=m/4|0,h==0)return V(X9,QH,28,0,15,1);for(d=null,t=0,n=0,r=0,i=0,o=0,s=0,c=0,l=0,p=0,f=0,u=0,d=V(X9,QH,28,h*3,15,1);p>4)<<24>>24,d[f++]=((n&15)<<4|r>>2&15)<<24>>24,d[f++]=(r<<6|i)<<24>>24}return!to(o=a[u++])||!to(s=a[u++])?null:(t=A9[o],n=A9[s],c=a[u++],l=a[u++],A9[c]==-1||A9[l]==-1?c==61&&l==61?n&15?null:(g=V(X9,QH,28,p*3+1,15,1),tN(d,0,g,0,p*3),g[f]=(t<<2|n>>4)<<24>>24,g):c!=61&&l==61?(r=A9[c],r&3?null:(g=V(X9,QH,28,p*3+2,15,1),tN(d,0,g,0,p*3),g[f++]=(t<<2|n>>4)<<24>>24,g[f]=((n&15)<<4|r>>2&15)<<24>>24,g)):null:(r=A9[c],i=A9[l],d[f++]=(t<<2|n>>4)<<24>>24,d[f++]=((n&15)<<4|r>>2&15)<<24>>24,d[f++]=(r<<6|i)<<24>>24,d))}function m_t(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for(t.Ug(Lbt,1),m=P(K(e,(mP(),S1)),223),i=new w(e.b);i.a=2){for(h=!0,f=new w(a.j),n=P(z(f),12),p=null;f.a0){if(i=f.gc(),u=C_(r.Math.floor((i+1)/2))-1,a=C_(r.Math.ceil((i+1)/2))-1,t.o==E2)for(d=a;d>=u;d--)t.a[x.p]==x&&(g=P(f.Xb(d),42),h=P(g.a,10),!mo(n,g.b)&&m>e.b.e[h.p]&&(t.a[h.p]=x,t.g[x.p]=t.g[h.p],t.a[x.p]=t.g[x.p],t.f[t.g[x.p].p]=(rd(),!!(ki(t.f[t.g[x.p].p])&x.k==(DA(),qJ))),m=e.b.e[h.p]));else for(d=u;d<=a;d++)t.a[x.p]==x&&(v=P(f.Xb(d),42),_=P(v.a,10),!mo(n,v.b)&&m0&&(a=P(Ep(_.c.a,ee-1),10),s=e.i[a.p],ne=r.Math.ceil(yu(e.n,a,_)),o=S.a.e-_.d.d-(s.a.e+a.o.b+a.d.a)-ne),u=cI,ee<_.c.a.c.length-1&&(l=P(Ep(_.c.a,ee+1),10),d=e.i[l.p],ne=r.Math.ceil(yu(e.n,l,_)),u=d.a.e-l.d.d-(S.a.e+_.o.b+_.d.a)-ne),n&&(uu(),fS(TV),r.Math.abs(o-u)<=TV||o==u||isNaN(o)&&isNaN(u))?!0:(i=eh(b.a),c=-eh(b.b),f=-eh(te.a),y=eh(te.b),g=b.a.e.e-b.a.a-(b.b.e.e-b.b.a)>0&&te.a.e.e-te.a.a-(te.b.e.e-te.b.a)<0,h=b.a.e.e-b.a.a-(b.b.e.e-b.b.a)<0&&te.a.e.e-te.a.a-(te.b.e.e-te.b.a)>0,m=b.a.e.e+b.b.ate.b.e.e+te.a.a,x=0,!g&&!h&&(p?o+f>0?x=f:u-i>0&&(x=i):m&&(o+c>0?x=c:u-y>0&&(x=y))),S.a.e+=x,S.b&&(S.d.e+=x),!1))}function __t(e,t,n){var i=new wg(t.Lf().a,t.Lf().b,t.Mf().a,t.Mf().b),a=new Ul,o,s,c,l,u,d,f,p;if(e.c)for(s=new w(t.Rf());s.al&&(r.a+=Uwe(V(K9,EF,28,-l,15,1))),r.a+=`Is`,Nl(c,mA(32))>=0)for(i=0;i=r.o.b/2}else v=!d;v?(_=P(K(r,(Y(),p$)),15),_?f?a=_:(i=P(K(r,dQ),15),i?a=_.gc()<=i.gc()?_:i:(a=new T,W(r,dQ,a))):(a=new T,W(r,p$,a))):(i=P(K(r,(Y(),dQ)),15),i?d?a=i:(_=P(K(r,p$),15),_?a=i.gc()<=_.gc()?i:_:(a=new T,W(r,p$,a))):(a=new T,W(r,dQ,a))),a.Fc(e),W(e,(Y(),pQ),n),t.d==n?(K_(t,null),n.e.c.length+n.g.c.length==0&&G_(n,null),nQe(n)):(U_(t,null),n.e.c.length+n.g.c.length==0&&G_(n,null)),Fg(t.a)}function C_t(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae,oe,se;for(n.Ug(`MinWidth layering`,1),m=t.b,te=t.a,se=P(K(t,(mP(),Ujt)),17).a,c=P(K(t,Wjt),17).a,e.b=D(N(K(t,c0))),e.d=cI,x=new w(te);x.a0?(u=0,_&&(u+=c),u+=(C-1)*s,b&&(u+=c),ne&&b&&(u=r.Math.max(u,Jot(b,s,y,te))),u=e.a&&(i=kft(e,b),f=r.Math.max(f,i.b),S=r.Math.max(S,i.d),M(c,new Kc(b,i)));for(C=new T,u=0;u0),v.a.Xb(v.c=--v.b),re=new Eh(e.b),qd(v,re),jd(v.b0){for(f=u<100?null:new Pa(u),l=new hC(t),m=l.g,_=V(q9,HF,28,u,15,1),r=0,b=new kx(u),i=0;i=0;)if(p==null?A(p)===A(m[c]):NT(p,m[c])){_.length<=r&&(g=_,_=V(q9,HF,28,2*_.length,15,1),tN(g,0,_,0,r)),_[r++]=i,tb(b,m[c]);break v}if(p=p,A(p)===A(s))break}}if(l=b,m=b.g,u=r,r>_.length&&(g=_,_=V(q9,HF,28,r,15,1),tN(g,0,_,0,r)),r>0){for(y=!0,a=0;a=0;)Dk(e,_[o]);if(r!=u){for(i=u;--i>=r;)Dk(l,i);g=_,_=V(q9,HF,28,r,15,1),tN(g,0,_,0,r)}t=l}}}else for(t=U3e(e,t),i=e.i;--i>=0;)t.Hc(e.g[i])&&(Dk(e,i),y=!0);if(y){if(_!=null){for(n=t.gc(),d=n==1?V_(e,4,t.Kc().Pb(),null,_[0],h):V_(e,6,t,_,_[0],h),f=n<100?null:new Pa(n),i=t.Kc();i.Ob();)p=i.Pb(),f=JOe(e,P(p,76),f);f?(f.nj(d),f.oj()):AC(e.e,d)}else{for(f=uOe(t.gc()),i=t.Kc();i.Ob();)p=i.Pb(),f=JOe(e,P(p,76),f);f&&f.oj()}return!0}return!1}function D_t(e,t){var n=new g4e(t),r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b;for(n.a||Fut(t),l=qct(t),c=new g_,_=new Vst,g=new w(t.a);g.a0||n.o==E2&&a=n}function A_t(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y=t,b,x,S,ee,te,ne,C,re,ie;for(v=new g_,b=new g_,u=Mv(y,cCt),r=new pIe(e,n,v,b),$9e(r.a,r.b,r.c,r.d,u),c=(ee=v.i,ee||(v.i=new zu(v,v.c))),ne=c.Kc();ne.Ob();)for(te=P(ne.Pb(),166),i=P(Dy(v,te),21),h=i.Kc();h.Ob();)if(m=h.Pb(),x=P(Bx(e.d,m),166),x)s=(!te.e&&(te.e=new cf(W5,te,10,9)),te.e),tb(s,x);else throw o=Fv(y,dU),f=_Ct+m+vCt+o,p=f+pU,E(new Vi(p));for(l=(S=b.i,S||(b.i=new zu(b,b.c))),re=l.Kc();re.Ob();)for(C=P(re.Pb(),166),a=P(Dy(b,C),21),_=a.Kc();_.Ob();)if(g=_.Pb(),x=P(Bx(e.d,g),166),x)d=(!C.g&&(C.g=new cf(W5,C,9,10)),C.g),tb(d,x);else throw o=Fv(y,dU),f=_Ct+g+vCt+o,p=f+pU,E(new Vi(p));!n.b&&(n.b=new cf(H5,n,4,7)),n.b.i!=0&&(!n.c&&(n.c=new cf(H5,n,5,8)),n.c.i!=0)&&(!n.b&&(n.b=new cf(H5,n,4,7)),n.b.i<=1&&(!n.c&&(n.c=new cf(H5,n,5,8)),n.c.i<=1))&&(!n.a&&(n.a=new F(W5,n,6,6)),n.a).i==1&&(ie=P(H((!n.a&&(n.a=new F(W5,n,6,6)),n.a),0),166),!GO(ie)&&!KO(ie)&&(TS(ie,P(H((!n.b&&(n.b=new cf(H5,n,4,7)),n.b),0),84)),ES(ie,P(H((!n.c&&(n.c=new cf(H5,n,5,8)),n.c),0),84))))}function j_t(e){var t,n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re;for(b=e.a,x=0,S=b.length;x0?(f=P(Ep(p.c.a,s-1),10),ne=yu(e.b,p,f),_=p.n.b-p.d.d-(f.n.b+f.o.b+f.d.a+ne)):_=p.n.b-p.d.d,u=r.Math.min(_,u),s1&&(s=r.Math.min(s,r.Math.abs(P(SO(c.a,1),8).b-d.b)))));else for(g=new w(t.j);g.aa&&(o=p.a-a,s=AP,i.c.length=0,a=p.a),p.a>=a&&(Mr(i.c,c),c.a.b>1&&(s=r.Math.min(s,r.Math.abs(P(SO(c.a,c.a.b-2),8).b-p.b)))));if(i.c.length!=0&&o>t.o.a/2&&s>t.o.b/2){for(m=new jA,G_(m,t),tj(m,(nP(),Z8)),m.n.a=t.o.a/2,v=new jA,G_(v,t),tj(v,m5),v.n.a=t.o.a/2,v.n.b=t.o.b,l=new w(i);l.a=u.b?U_(c,v):U_(c,m)):(u=P(Tje(c.a),8),_=c.a.b==0?rv(c.c):P(vd(c.a),8),_.b>=u.b?K_(c,v):K_(c,m)),f=P(K(c,(mP(),j1)),75),f&&QE(f,u,!0);t.n.a=a-t.o.a/2}}function N_t(e,t,n){var i,a,o,s,c,l,u,d,f,p;for(c=dO(e.b,0);c.b!=c.d.c;)if(s=P(Lv(c),40),!ff(s.c,LV))for(u=vit(s,e),t==(GT(),t8)||t==n8?hu(u,new Vae):hu(u,new Hae),l=u.c.length,i=0;i=0?GE(s):YT(GE(s)),e.qf(t0,p)),l=new Fa,f=!1,e.pf(X1)?(IEe(l,P(e.of(X1),8)),f=!0):lTe(l,o.a/2,o.b/2),p.g){case 4:W(u,M1,(XE(),h$)),W(u,yQ,(_w(),vZ)),u.o.b=o.b,h<0&&(u.o.a=-h),tj(d,(nP(),X8)),f||(l.a=o.a),l.a-=o.a;break;case 2:W(u,M1,(XE(),_$)),W(u,yQ,(_w(),gZ)),u.o.b=o.b,h<0&&(u.o.a=-h),tj(d,(nP(),g5)),f||(l.a=0);break;case 1:W(u,MQ,(Zb(),oQ)),u.o.a=o.a,h<0&&(u.o.b=-h),tj(d,(nP(),m5)),f||(l.b=o.b),l.b-=o.b;break;case 3:W(u,MQ,(Zb(),iQ)),u.o.a=o.a,h<0&&(u.o.b=-h),tj(d,(nP(),Z8)),f||(l.b=0)}if(IEe(d.n,l),W(u,X1,l),t==L8||t==z8||t==R8){if(m=0,t==L8&&e.pf($1))switch(p.g){case 1:case 2:m=P(e.of($1),17).a;break;case 3:case 4:m=-P(e.of($1),17).a}else switch(p.g){case 4:case 2:m=a.b,t==z8&&(m/=i.b);break;case 1:case 3:m=a.a,t==z8&&(m/=i.a)}W(u,$Q,m)}return W(u,TQ,p),u}function P_t(){La();function e(e){var t=this;this.dispatch=function(t){var n=t.data;switch(n.cmd){case`algorithms`:var r=tD((Vg(),new Wn(new Bn(h7.b))));e.postMessage({id:n.id,data:r});break;case`categories`:var i=tD((Vg(),new Wn(new Bn(h7.c))));e.postMessage({id:n.id,data:i});break;case`options`:var a=tD((Vg(),new Wn(new Bn(h7.d))));e.postMessage({id:n.id,data:a});break;case`register`:Wmt(n.algorithms),e.postMessage({id:n.id});break;case`layout`:Rft(n.graph,n.layoutOptions||{},n.options||{}),e.postMessage({id:n.id,data:n.graph})}},this.saveDispatch=function(n){try{t.dispatch(n)}catch(t){e.postMessage({id:n.data.id,error:t})}}}function r(t){var n=this;this.dispatcher=new e({postMessage:function(e){n.onmessage({data:e})}}),this.postMessage=function(e){setTimeout(function(){n.dispatcher.saveDispatch({data:e})},0)}}if(typeof document===LI&&typeof self!==LI){var i=new e(self);self.onmessage=i.saveDispatch}else typeof t!==LI&&t.exports&&(Object.defineProperty(n,"__esModule",{value:!0}),t.exports={default:r,Worker:r})}function F_t(e,t,n){var r,i,a,o,s,c,l,u=new ZO(n),d,f;for(VC(u,t),W(u,(Y(),WQ),t),u.o.a=t.g,u.o.b=t.f,u.n.a=t.i,u.n.b=t.j,M(n.a,u),Qh(e.a,t,u),((!t.a&&(t.a=new F($5,t,10,11)),t.a).i!=0||ki(Od(J(t,(mP(),k1)))))&&W(u,mQ,(rd(),!0)),l=P(K(n,OQ),21),d=P(K(u,(mP(),Q1)),101),d==(rA(),H8)?W(u,Q1,V8):d!=V8&&l.Fc((uM(),YZ)),f=0,r=P(K(n,_1),88),c=new Lu((!t.c&&(t.c=new F(e7,t,9,9)),t.c));c.e!=c.i.gc();)s=P(gO(c),123),i=I_(t),(A(J(i,s1))!==A((ID(),Z0))||A(J(i,g1))===A((FD(),dZ))||A(J(i,g1))===A((FD(),lZ))||ki(Od(J(i,l1)))||A(J(i,t1))!==A((YD(),RJ))||A(J(i,P1))===A((FM(),G0))||A(J(i,P1))===A((FM(),K0))||A(J(i,F1))===A((Zj(),k0))||A(J(i,F1))===A((Zj(),j0)))&&!ki(Od(J(t,a1)))&&OO(s,UQ,G(f++)),ki(Od(J(s,J1)))||Cgt(e,s,u,l,r,d);for(o=new Lu((!t.n&&(t.n=new F(Q5,t,1,7)),t.n));o.e!=o.i.gc();)a=P(gO(o),135),!ki(Od(J(a,J1)))&&a.a&&M(u.b,lT(a));return ki(Od(K(u,Z$)))&&l.Fc((uM(),WZ)),ki(Od(K(u,O1)))&&(l.Fc((uM(),JZ)),l.Fc(qZ),W(u,Q1,V8)),u}function cP(e,t,n,i,a,o,s){var c,l,u,d,f,p,m,h,g=0,_,v,y,b,x,S,ee,te,ne,C,re=0,ie,ae,oe,se;for(u=new w(e.b);u.ag&&(o&&(yl(ee,m),yl(ne,G(d.b-1)),M(e.d,h),c.c.length=0),oe=n.b,se+=m+t,m=0,f=r.Math.max(f,n.b+n.c+ae)),Mr(c.c,l),q2e(l,oe,se),f=r.Math.max(f,oe+ae+n.c),m=r.Math.max(m,p),oe+=ae+t,h=l;if(nw(e.a,c),M(e.d,P(Ep(c,c.c.length-1),163)),f=r.Math.max(f,i),ie=se+m+n.a,iei.d.d+i.d.a?u.f.d=!0:(u.f.d=!0,u.f.a=!0))),r.b!=r.d.c&&(t=n);u&&(a=P(xh(e.f,o.d.i),60),t.ba.d.d+a.d.a?u.f.d=!0:(u.f.d=!0,u.f.a=!0))}for(s=new pm(Vu(DE(m).a.Kc(),new d));Cj(s);)o=P(by(s),18),o.a.b!=0&&(t=P(vd(o.a),8),o.d.j==(nP(),Z8)&&(_=new mN(t,new k(t.a,i.d.d),i,o),_.f.a=!0,_.a=o.d,Mr(g.c,_)),o.d.j==m5&&(_=new mN(t,new k(t.a,i.d.d+i.d.a),i,o),_.f.d=!0,_.a=o.d,Mr(g.c,_)))}return g}function V_t(e,t,n){var r,i,a,o,s,c=new T,l,u,d=t.length,f;for(o=DZe(n),l=0;l=m&&(v>m&&(p.c.length=0,m=v),Mr(p.c,o));p.c.length!=0&&(f=P(Ep(p,VO(t,p.c.length)),131),re.a.Bc(f),f.s=h++,bat(f,ne,S),p.c.length=0)}for(b=e.c.length+1,s=new w(e);s.aC.s&&(Fh(n),Db(C.i,r),r.c>0&&(r.a=C,M(C.t,r),r.b=ee,M(ee.i,r)))}function W_t(e,t,n,r,i){var a,o,s,c,l,u,d,f,p,m,h=new Hy(t.b),g,_,v,y,b=new Hy(t.b),x,S,ee,te,ne,C,re;for(f=new Hy(t.b),te=new Hy(t.b),g=new Hy(t.b),ee=dO(t,0);ee.b!=ee.d.c;)for(x=P(Lv(ee),12),s=new w(x.g);s.a0,_=x.g.c.length>0,l&&_?Mr(f.c,x):l?Mr(h.c,x):_&&Mr(b.c,x);for(m=new w(h);m.ay.nh()-u.b&&(p=y.nh()-u.b),m>y.oh()-u.d&&(m=y.oh()-u.d),d0){for(x=dO(e.f,0);x.b!=x.d.c;)b=P(Lv(x),10),b.p+=m-e.e;Iet(e),Fg(e.f),yct(e,i,h)}else{for(up(e.f,h),h.p=i,e.e=r.Math.max(e.e,i),o=new pm(Vu(DE(h).a.Kc(),new d));Cj(o);)a=P(by(o),18),!a.c.i.c&&a.c.i.k==(DA(),KJ)&&(up(e.f,a.c.i),a.c.i.p=i-1);e.c=i}}else Iet(e),Fg(e.f),i=0,Cj(new pm(Vu(DE(h).a.Kc(),new d)))?(m=0,m=i4e(m,h),i=m+2,yct(e,i,h)):(up(e.f,h),h.p=0,e.e=r.Math.max(e.e,0),e.b=P(Ep(e.d.b,0),30),e.c=0);for(e.f.b==0||Iet(e),e.d.a.c.length=0,y=new T,u=new w(e.d.b);u.a=48&&t<=57){for(r=t-48;i=48&&t<=57;)if(r=r*10+t-48,r<0)throw E(new Ui(TP((fu(),ewt))))}else throw E(new Ui(TP((fu(),XCt))));if(n=r,t==44){if(i>=e.j)throw E(new Ui(TP((fu(),QCt))));if((t=mg(e.i,i++))>=48&&t<=57){for(n=t-48;i=48&&t<=57;)if(n=n*10+t-48,n<0)throw E(new Ui(TP((fu(),ewt))));if(r>n)throw E(new Ui(TP((fu(),$Ct))))}else n=-1}if(t!=125)throw E(new Ui(TP((fu(),ZCt))));e.bm(i)?(a=(xP(),xP(),++W9,new Zv(9,a)),e.d=i+1):(a=(xP(),xP(),++W9,new Zv(3,a)),e.d=i),a.Om(r),a.Nm(n),hP(e)}}return a}function $_t(e){var t,n=P(K(e,(Y(),OQ)),21),r,i,a;switch(t=Wl(oOt),i=P(K(e,(mP(),D1)),346),i==(_T(),g8)&&OC(t,sOt),ki(Od(K(e,E1)))?vp(t,(vA(),vJ),(yP(),tX)):vp(t,(vA(),bJ),(yP(),tX)),K(e,(Uy(),G3))!=null&&OC(t,cOt),(ki(Od(K(e,zjt)))||ki(Od(K(e,Fjt))))&&tm(t,(vA(),SJ),(yP(),hY)),P(K(e,_1),88).g){case 2:case 3:case 4:tm(vp(t,(vA(),vJ),(yP(),_Y)),SJ,gY)}switch(n.Hc((uM(),WZ))&&tm(vp(vp(t,(vA(),vJ),(yP(),mY)),xJ,fY),SJ,pY),A(K(e,P1))!==A((FM(),Y0))&&vp(t,(vA(),bJ),(yP(),qY)),n.Hc(ZZ)&&(vp(t,(vA(),vJ),(yP(),$Y)),vp(t,yJ,ZY),vp(t,bJ,QY)),A(K(e,e1))!==A((TA(),BZ))&&A(K(e,S1))!==A((wE(),u8))&&tm(t,(vA(),SJ),(yP(),AY)),ki(Od(K(e,Ljt)))&&vp(t,(vA(),bJ),(yP(),kY)),ki(Od(K(e,m1)))&&vp(t,(vA(),bJ),(yP(),sX)),Kat(e)&&(r=A(K(e,D1))===A(g8)?P(K(e,d1),299):P(K(e,f1),299),a=r==(qC(),tQ)?(yP(),XY):(yP(),uX),vp(t,(vA(),xJ),a)),P(K(e,wMt),388).g){case 1:vp(t,(vA(),xJ),(yP(),cX));break;case 2:tm(vp(vp(t,(vA(),bJ),(yP(),cY)),xJ,lY),SJ,uY)}return A(K(e,s1))!==A((ID(),Z0))&&vp(t,(vA(),bJ),(yP(),lX)),t}function evt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y;if(km(e.a,t)){if(mo(P(xh(e.a,t),49),n))return 1}else Qh(e.a,t,new Jr);if(km(e.a,n)){if(mo(P(xh(e.a,n),49),t))return-1}else Qh(e.a,n,new Jr);if(km(e.e,t)){if(mo(P(xh(e.e,t),49),n))return-1}else Qh(e.e,t,new Jr);if(km(e.e,n)){if(mo(P(xh(e.a,n),49),t))return 1}else Qh(e.e,n,new Jr);if(e.c==(ID(),Q0)||!yd(t,(Y(),UQ))||!yd(n,(Y(),UQ))){for(d=null,l=new w(t.j);l.ao?jM(e,t,n):jM(e,n,t),io)}return r=P(K(t,(Y(),UQ)),17).a,a=P(K(n,UQ),17).a,r>a?jM(e,t,n):jM(e,n,t),ra)}function uP(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(n==null)return null;if(e.a!=t.jk())throw E(new Fi(YH+t.xe()+XH));if(j(t,469)){if(g=fct(P(t,685),n),!g)throw E(new Fi(ZH+n+`' is not a valid enumerator of '`+t.xe()+`'`));return g}switch(AT((UA(),l9),t).Nl()){case 2:n=EN(n,!1);break;case 3:n=EN(n,!0)}if(r=AT(l9,t).Jl(),r)return r.jk().wi().ti(r,n);if(f=AT(l9,t).Ll(),f){for(g=new T,l=Bw(n),u=0,d=l.length;u1)for(h=new cd((!e.a&&(e.a=new F(W5,e,6,6)),e.a));h.e!=h.i.gc();)Yk(h);for(s=P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166),_=oe,oe>S+x?_=S+x:oeee+g?v=ee+g:seS-x&&_ee-g&&voe+ae?ne=oe+ae:Sse+te?C=se+te:eeoe-ae&&nese-te&&Cn&&(p=n-1),m=fe+Lj(t,24)*kI*f-f/2,m<0?m=1:m>i&&(m=i-1),a=(Ia(),l=new tn,l),Xx(a,p),Vx(a,m),tb((!s.a&&(s.a=new ju(z5,s,5)),s.a),a)}function avt(e){Wo(e,new oA(ya(ha(va(_a(new Zt,cH),`ELK Rectangle Packing`),`Algorithm for packing of unconnected boxes, i.e. graphs without edges. The given order of the boxes is always preserved and the main reading direction of the boxes is left to right. The algorithm is divided into two phases. One phase approximates the width in which the rectangles can be placed. The next phase places the rectangles in rows using the previously calculated width as bounding width and bundles rectangles with a similar height in blocks. A compaction step reduces the size of the drawing. Finally, the rectangles are expanded to fill their bounding box and eliminate empty unused spaces.`),new xoe))),B(e,cH,FL,1.3),B(e,cH,aR,(rd(),!1)),B(e,cH,IL,dLt),B(e,cH,ZL,15),B(e,cH,rV,hO(eLt)),B(e,cH,sR,hO(aLt)),B(e,cH,gR,hO(sLt)),B(e,cH,oR,hO(cLt)),B(e,cH,cR,hO(iLt)),B(e,cH,iR,hO(n3)),B(e,cH,lR,hO(fLt)),B(e,cH,Vxt,hO(gLt)),B(e,cH,Hxt,hO(hLt)),B(e,cH,Bxt,hO(o3)),B(e,cH,zxt,hO(_Lt)),B(e,cH,Uxt,hO(uLt)),B(e,cH,Wxt,hO(r3)),B(e,cH,Gxt,hO(lLt)),B(e,cH,Kxt,hO(mLt)),B(e,cH,tR,hO(nLt)),B(e,cH,hV,hO(rLt)),B(e,cH,Lxt,hO(e3)),B(e,cH,Ixt,hO(tLt)),B(e,cH,Rxt,hO(t3)),B(e,cH,Fxt,hO(pLt))}function pP(e,t){wN();var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te=e.e,ne,C,re,ie,ae;if(m=e.d,i=e.a,te==0)switch(t){case 0:return`0`;case 1:return vI;case 2:return`0.00`;case 3:return`0.000`;case 4:return`0.0000`;case 5:return`0.00000`;case 6:return`0.000000`;default:return S=new ta,t<0?S.a+=`0E+`:S.a+=`0E`,S.a+=-t,S.a}if(y=m*10+1+7,b=V(K9,EF,28,y+1,15,1),n=y,m==1){if(s=i[0],s<0){ae=uv(s,_I);do h=ae,ae=Wk(ae,10),b[--n]=48+nm(xE(h,bE(ae,10)))&OF;while(dT(ae,0)!=0)}else{ae=s;do h=ae,ae=ae/10|0,b[--n]=48+(h-ae*10)&OF;while(ae!=0)}}else{C=V(q9,HF,28,m,15,1),ie=m,tN(i,0,C,0,ie);I:for(;;){for(ee=0,l=ie-1;l>=0;l--)re=yE(cm(ee,32),uv(C[l],_I)),_=Q5e(re),C[l]=nm(_),ee=nm(lm(_,32));v=nm(ee),g=n;do b[--n]=48+v%10&OF;while((v=v/10|0)!=0&&n!=0);for(r=9-g+n,c=0;c0;c++)b[--n]=48;for(d=ie-1;C[d]==0;d--)if(d==0)break I;ie=d+1}for(;b[n]==48;)++n}if(p=te<0,o=y-n-t-1,t==0)return p&&(b[--n]=45),ND(b,n,y-n);if(t>0&&o>=-6){if(o>=0){for(u=n+o,f=y-1;f>=u;f--)b[f+1]=b[f];return b[++u]=46,p&&(b[--n]=45),ND(b,n,y-n+1)}for(d=2;d<-o+1;d++)b[--n]=48;return b[--n]=46,b[--n]=48,p&&(b[--n]=45),ND(b,n,y-n)}return ne=n+1,a=y,x=new na,p&&(x.a+=`-`),a-ne>=1?(jh(x,b[n]),x.a+=`.`,x.a+=ND(b,n+1,y-n-1)):x.a+=ND(b,n,y-n),x.a+=`E`,o>0&&(x.a+=`+`),x.a+=``+o,x.a}function ovt(e,t){var n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee;switch(e.c=t,e.g=new Dr,n=(Ko(),new Ei(e.c)),i=new ar(n),KE(i),b=kd(J(e.c,(yA(),XLt))),l=P(J(e.c,T3),324),S=P(J(e.c,E3),437),s=P(J(e.c,GLt),490),x=P(J(e.c,w3),438),e.j=D(N(J(e.c,ZLt))),c=e.a,l.g){case 0:c=e.a;break;case 1:c=e.b;break;case 2:c=e.i;break;case 3:c=e.e;break;case 4:c=e.f;break;default:throw E(new Fi(fH+(l.f==null?``+l.g:l.f)))}if(e.d=new qLe(c,S,s),W(e.d,(wC(),xq),Od(J(e.c,qLt))),e.d.c=ki(Od(J(e.c,KLt))),Gg(e.c).i==0)return e.d;for(f=new Lu(Gg(e.c));f.e!=f.i.gc();){for(d=P(gO(f),27),m=d.g/2,p=d.f/2,ee=new k(d.i+m,d.j+p);km(e.g,ee);)Sd(ee,(r.Math.random()-.5)*GL,(r.Math.random()-.5)*GL);g=P(J(d,(vP(),S6)),140),_=new bRe(ee,new wg(ee.a-m-e.j/2-g.b,ee.b-p-e.j/2-g.d,d.g+e.j+(g.b+g.c),d.f+e.j+(g.d+g.a))),M(e.d.i,_),Qh(e.g,ee,new Kc(_,d))}switch(x.g){case 0:if(b==null)e.d.d=P(Ep(e.d.i,0),68);else for(y=new w(e.d.i);y.a0?ie+1:1);for(o=new w(S.g);o.a0?ie+1:1)}e.c[l]==0?up(e.e,h):e.a[l]==0&&up(e.f,h),++l}for(m=-1,p=1,d=new T,e.d=P(K(t,(Y(),t$)),234);le>0;){for(;e.e.b!=0;)oe=P(Yf(e.e),10),e.b[oe.p]=m--,yut(e,oe),--le;for(;e.f.b!=0;)se=P(Yf(e.f),10),e.b[se.p]=p++,yut(e,se),--le;if(le>0){for(f=xF,v=new w(y);v.a=f&&(b>f&&(d.c.length=0,f=b),Mr(d.c,h)));u=e.sg(d),e.b[u.p]=p++,yut(e,u),--le}}for(ae=y.c.length+1,l=0;le.b[ce]&&(lN(r,!0),W(t,vQ,(rd(),!0)));e.a=null,e.c=null,e.b=null,Fg(e.f),Fg(e.e),n.Vg()}function lvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(H((!e.a&&(e.a=new F(W5,e,6,6)),e.a),0),166),ee;for(d=new ai,x=new Dr,ee=vdt(S),XA(x.f,S,ee),p=new Dr,i=new vo,h=jm(oS(U(O(KW,1),FP,20,0,[(!t.d&&(t.d=new cf(U5,t,8,5)),t.d),(!t.e&&(t.e=new cf(U5,t,7,4)),t.e)])));Cj(h);){if(m=P(by(h),74),(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i!=1)throw E(new Fi(BSt+(!e.a&&(e.a=new F(W5,e,6,6)),e.a).i));m!=e&&(_=P(H((!m.a&&(m.a=new F(W5,m,6,6)),m.a),0),166),iy(i,_,i.c.b,i.c),g=P(nl(Kp(x.f,_)),13),g||(g=vdt(_),XA(x.f,_,g)),f=n?ef(new Vl(P(Ep(ee,ee.c.length-1),8)),P(Ep(g,g.c.length-1),8)):ef(new Vl((ov(0,ee.c.length),P(ee.c[0],8))),(ov(0,g.c.length),P(g.c[0],8))),XA(p.f,_,f))}if(i.b!=0)for(v=P(Ep(ee,n?ee.c.length-1:0),8),u=1;u1&&iy(d,v,d.c.b,d.c),wx(a)));v=y}return d}function uvt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C;for(n.Ug(fxt,1),C=P(ay(hg(new Mp(null,new cv(t,16)),new Xae),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),u=P(ay(hg(new Mp(null,new cv(t,16)),new Vme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),m=P(ay(hg(new Mp(null,new cv(t,16)),new Bme(t)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[yK]))),15),h=V(L2,VV,40,t.gc(),0,1),o=0;o=0&&ne=0&&!h[p]){h[p]=i,u.gd(s),--s;break}if(p=ne-f,p=0&&!h[p]){h[p]=i,u.gd(s),--s;break}}for(m.jd(new Zae),c=h.length-1;c>=0;c--)!h[c]&&!m.dc()&&(h[c]=P(m.Xb(0),40),m.gd(0));for(l=0;l=0;c--)up(n,(ov(c,o.c.length),P(o.c[c],8)));return n}function fvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b=D(N(J(t,(xM(),Z4)))),x;for(m=D(N(J(t,Y4))),p=D(N(J(t,K4))),BS((!t.a&&(t.a=new F($5,t,10,11)),t.a)),v=Mpt((!t.a&&(t.a=new F($5,t,10,11)),t.a),b,e.b),_=0;_f&&Fk((ov(f,t.c.length),P(t.c[f],186)),u),u=null;t.c.length>f&&(ov(f,t.c.length),P(t.c[f],186)).a.c.length==0;)Db(t,(ov(f,t.c.length),t.c[f]));if(!u){--o;continue}if(!ki(Od(P(Ep(u.b,0),27).of((gM(),t3))))&&$ut(t,m,a,u,g,n,f,r)){h=!0;continue}if(g){if(p=m.b,d=u.f,!ki(Od(P(Ep(u.b,0),27).of(t3)))&&zmt(t,m,a,u,n,f,r,i)){if(h=!0,p=e.j){e.a=-1,e.c=1;return}if(t=mg(e.i,e.d++),e.a=t,e.b==1){switch(t){case 92:if(r=10,e.d>=e.j)throw E(new Ui(TP((fu(),TU))));e.a=mg(e.i,e.d++);break;case 45:(e.e&512)==512&&e.d=e.j||mg(e.i,e.d)!=63)break;if(++e.d>=e.j)throw E(new Ui(TP((fu(),EU))));switch(t=mg(e.i,e.d++),t){case 58:r=13;break;case 61:r=14;break;case 33:r=15;break;case 91:r=19;break;case 62:r=18;break;case 60:if(e.d>=e.j)throw E(new Ui(TP((fu(),EU))));if(t=mg(e.i,e.d++),t==61)r=16;else if(t==33)r=17;else throw E(new Ui(TP((fu(),DCt))));break;case 35:for(;e.d=e.j)throw E(new Ui(TP((fu(),TU))));e.a=mg(e.i,e.d++);break;default:r=0}e.c=r}function gvt(e,t,n){var r,i,a,o,s,c,l,u,d,f,p,m,h,g;if(n.Ug(`Process compaction`,1),ki(Od(K(t,(rN(),eFt))))){for(i=P(K(t,c4),88),p=D(N(K(t,f4))),lpt(e,t,i),d_t(t,p/2/2),m=t.b,zS(m,new Nme(i)),l=dO(m,0);l.b!=l.d.c;)if(c=P(Lv(l),40),!ki(Od(K(c,(tP(),a4))))){if(r=Yct(c,i),h=mft(c,t),d=0,f=0,r)switch(g=r.e,i.g){case 2:d=g.a-p-c.f.a,h.e.a-p-c.f.ad&&(d=h.e.a+h.f.a+p),f=d+c.f.a;break;case 4:d=g.b-p-c.f.b,h.e.b-p-c.f.bd&&(d=h.e.b+h.f.b+p),f=d+c.f.b}else if(h)switch(i.g){case 2:d=h.e.a-p-c.f.a,f=d+c.f.a;break;case 1:d=h.e.a+h.f.a+p,f=d+c.f.a;break;case 4:d=h.e.b-p-c.f.b,f=d+c.f.b;break;case 3:d=h.e.b+h.f.b+p,f=d+c.f.b}A(K(t,l4))===A((Pw(),z2))?(a=d,o=f,s=Dw(hg(new Mp(null,new cv(e.a,16)),new tSe(a,o))),s.a==null?(s=i==(GT(),t8)||i==i8?Dw(hg(Tqe(new Mp(null,new cv(e.a,16))),new Pme(a))):Dw(hg(Tqe(new Mp(null,new cv(e.a,16))),new Fme(a))),s.a!=null&&(i==t8||i==n8?c.e.a=D(N((jd(s.a!=null),P(s.a,42)).a)):c.e.b=D(N((jd(s.a!=null),P(s.a,42)).a)))):i==(GT(),t8)||i==n8?c.e.a=d:c.e.b=d,s.a!=null&&(u=Ab(e.a,(jd(s.a!=null),s.a),0),u>0&&u!=P(K(c,p4),17).a&&(W(c,LPt,(rd(),!0)),W(c,p4,G(u))))):i==(GT(),t8)||i==n8?c.e.a=d:c.e.b=d}n.Vg()}}function _vt(e){var t,n,r,i,a,o,s,c,l;for(e.b=1,hP(e),t=null,e.c==0&&e.a==94?(hP(e),t=(xP(),xP(),++W9,new pv(4)),oM(t,0,NW),s=(++W9,new pv(4))):s=(xP(),xP(),++W9,new pv(4)),i=!0;(l=e.c)!=1;){if(l==0&&e.a==93&&!i){t&&(KN(t,s),s=t);break}if(n=e.a,r=!1,l==10)switch(n){case 100:case 68:case 119:case 87:case 115:case 83:DN(s,KM(n)),r=!0;break;case 105:case 73:case 99:case 67:n=(DN(s,KM(n)),-1),n<0&&(r=!0);break;case 112:case 80:if(c=Ont(e,n),!c)throw E(new Ui(TP((fu(),OU))));DN(s,c),r=!0;break;default:n=Tct(e)}else if(l==24&&!i){if(t&&(KN(t,s),s=t),a=_vt(e),KN(s,a),e.c!=0||e.a!=93)throw E(new Ui(TP((fu(),BCt))));break}if(hP(e),!r){if(l==0){if(n==91)throw E(new Ui(TP((fu(),VCt))));if(n==93)throw E(new Ui(TP((fu(),HCt))));if(n==45&&!i&&e.a!=93)throw E(new Ui(TP((fu(),AU))))}if(e.c!=0||e.a!=45||n==45&&i)oM(s,n,n);else{if(hP(e),(l=e.c)==1)throw E(new Ui(TP((fu(),kU))));if(l==0&&e.a==93)oM(s,n,n),oM(s,45,45);else if(l==0&&e.a==93||l==24)throw E(new Ui(TP((fu(),AU))));else{if(o=e.a,l==0){if(o==91)throw E(new Ui(TP((fu(),VCt))));if(o==93)throw E(new Ui(TP((fu(),HCt))));if(o==45)throw E(new Ui(TP((fu(),AU))))}else l==10&&(o=Tct(e));if(hP(e),n>o)throw E(new Ui(TP((fu(),GCt))));oM(s,n,o)}}}i=!1}if(e.c==1)throw E(new Ui(TP((fu(),kU))));return kj(s),FN(s),e.b=0,hP(e),s}function vvt(e,t,n){var r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x,S;if(n.Ug(`Coffman-Graham Layering`,1),t.a.c.length==0){n.Vg();return}for(S=P(K(t,(mP(),Vjt)),17).a,c=0,o=0,p=new w(t.a);p.a=S||!I0e(v,r))&&(r=BFe(t,u)),W_(v,r),a=new pm(Vu(DE(v).a.Kc(),new d));Cj(a);)i=P(by(a),18),!e.a[i.p]&&(g=i.c.i,--e.e[g.p],e.e[g.p]==0&&ep(gA(m,g),bI));for(l=u.c.length-1;l>=0;--l)M(t.b,(ov(l,u.c.length),P(u.c[l],30)));t.a.c.length=0,n.Vg()}function yvt(e,t){var n,r,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x=!1;do for(x=!1,a=t?new Pn(e.a.b).a.gc()-2:1;t?a>=0:aP(K(_,UQ),17).a)&&(b=!1);if(b){for(c=t?a+1:a-1,s=SVe(e.a,G(c)),o=!1,y=!0,r=!1,u=dO(s,0);u.b!=u.d.c;)l=P(Lv(u),10),yd(l,UQ)?l.p!=f.p&&(o|=t?P(K(l,UQ),17).aP(K(f,UQ),17).a,y=!1):!o&&y&&l.k==(DA(),KJ)&&(r=!0,p=t?P(by(new pm(Vu(DE(l).a.Kc(),new d))),18).c.i:P(by(new pm(Vu(OE(l).a.Kc(),new d))),18).d.i,p==f&&(n=t?P(by(new pm(Vu(OE(l).a.Kc(),new d))),18).d.i:P(by(new pm(Vu(DE(l).a.Kc(),new d))),18).c.i,(t?P(xd(e.a,n),17).a-P(xd(e.a,p),17).a:P(xd(e.a,p),17).a-P(xd(e.a,n),17).a)<=2&&(y=!1)));if(r&&y&&(n=t?P(by(new pm(Vu(OE(f).a.Kc(),new d))),18).d.i:P(by(new pm(Vu(DE(f).a.Kc(),new d))),18).c.i,(t?P(xd(e.a,n),17).a-P(xd(e.a,f),17).a:P(xd(e.a,f),17).a-P(xd(e.a,n),17).a)<=2&&n.k==(DA(),JJ)&&(y=!1)),o||y){for(g=Wat(e,f,t);g.a.gc()!=0;)h=P(g.a.ec().Kc().Pb(),10),g.a.Bc(h),XS(g,Wat(e,h,t));--m,x=!0}}}while(x)}function bvt(e){Nj(e.c,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#decimal`])),Nj(e.d,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#integer`])),Nj(e.e,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#boolean`])),Nj(e.f,XU,U(O(LG,1),X,2,6,[sW,`EBoolean`,hU,`EBoolean:Object`])),Nj(e.i,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#byte`])),Nj(e.g,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#hexBinary`])),Nj(e.j,XU,U(O(LG,1),X,2,6,[sW,`EByte`,hU,`EByte:Object`])),Nj(e.n,XU,U(O(LG,1),X,2,6,[sW,`EChar`,hU,`EChar:Object`])),Nj(e.t,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#double`])),Nj(e.u,XU,U(O(LG,1),X,2,6,[sW,`EDouble`,hU,`EDouble:Object`])),Nj(e.F,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#float`])),Nj(e.G,XU,U(O(LG,1),X,2,6,[sW,`EFloat`,hU,`EFloat:Object`])),Nj(e.I,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#int`])),Nj(e.J,XU,U(O(LG,1),X,2,6,[sW,`EInt`,hU,`EInt:Object`])),Nj(e.N,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#long`])),Nj(e.O,XU,U(O(LG,1),X,2,6,[sW,`ELong`,hU,`ELong:Object`])),Nj(e.Z,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#short`])),Nj(e.$,XU,U(O(LG,1),X,2,6,[sW,`EShort`,hU,`EShort:Object`])),Nj(e._,XU,U(O(LG,1),X,2,6,[sW,`http://www.w3.org/2001/XMLSchema#string`]))}function xvt(e,t,n,r,i,a,o){var s,c,l,u,d,f=P(r.a,17).a,p=P(r.b,17).a,m;return d=e.b,m=e.c,s=0,u=0,t==(GT(),t8)||t==n8?(u=uc(U$e(_g(gg(new Mp(null,new cv(n.b,16)),new $ae),new Pae))),d.e.b+d.f.b/2>u?(l=++p,s=D(N(Ju(_m(gg(new Mp(null,new cv(n.b,16)),new pSe(i,l)),new Fae))))):(c=++f,s=D(N(Ju(vm(gg(new Mp(null,new cv(n.b,16)),new mSe(i,c)),new Iae)))))):(u=uc(U$e(_g(gg(new Mp(null,new cv(n.b,16)),new Bae),new Nae))),d.e.a+d.f.a/2>u?(l=++p,s=D(N(Ju(_m(gg(new Mp(null,new cv(n.b,16)),new dSe(i,l)),new Lae))))):(c=++f,s=D(N(Ju(vm(gg(new Mp(null,new cv(n.b,16)),new fSe(i,c)),new Rae)))))),t==t8?(yl(e.a,new k(D(N(K(d,(tP(),$2))))-i,s)),yl(e.a,new k(m.e.a+m.f.a+i+a,s)),yl(e.a,new k(m.e.a+m.f.a+i+a,m.e.b+m.f.b/2)),yl(e.a,new k(m.e.a+m.f.a,m.e.b+m.f.b/2))):t==n8?(yl(e.a,new k(D(N(K(d,(tP(),Q2))))+i,d.e.b+d.f.b/2)),yl(e.a,new k(d.e.a+d.f.a+i,s)),yl(e.a,new k(m.e.a-i-a,s)),yl(e.a,new k(m.e.a-i-a,m.e.b+m.f.b/2)),yl(e.a,new k(m.e.a,m.e.b+m.f.b/2))):t==i8?(yl(e.a,new k(s,D(N(K(d,(tP(),$2))))-i)),yl(e.a,new k(s,m.e.b+m.f.b+i+a)),yl(e.a,new k(m.e.a+m.f.a/2,m.e.b+m.f.b+i+a)),yl(e.a,new k(m.e.a+m.f.a/2,m.e.b+m.f.b+i))):(e.a.b==0||(P(vd(e.a),8).b=D(N(K(d,(tP(),Q2))))+i*P(o.b,17).a),yl(e.a,new k(s,D(N(K(d,(tP(),Q2))))+i*P(o.b,17).a)),yl(e.a,new k(s,m.e.b-i*P(o.a,17).a-a))),new Kc(G(f),G(p))}function Svt(e){var t,n,r,i,a,o=!0,s,c,l,u,d=null,f,p;if(r=null,i=null,t=!1,p=LVt,l=null,a=null,s=0,c=nO(e,s,FVt,IVt),c=0&&ff(e.substr(s,2),`//`)?(s+=2,c=nO(e,s,y7,b7),r=(Zy(s,c,e.length),e.substr(s,c-s)),s=c):d!=null&&(s==e.length||(sv(s,e.length),e.charCodeAt(s)!=47))&&(o=!1,c=ITe(e,mA(35),s),c==-1&&(c=e.length),r=(Zy(s,c,e.length),e.substr(s,c-s)),s=c);if(!n&&s0&&mg(u,u.length-1)==58&&(i=u,s=c)),sDj(a))&&(d=a);for(!d&&(d=(ov(0,g.c.length),P(g.c[0],185))),h=new w(t.b);h.af&&(ie=0,ae+=d+te,d=0),but(S,s,ie,ae),t=r.Math.max(t,ie+ee.a),d=r.Math.max(d,ee.b),ie+=ee.a+te;for(x=new Dr,n=new Dr,C=new w(e);C.a=-1900),n>=4?gl(e,U(O(LG,1),X,2,6,[iyt,ayt])[s]):gl(e,U(O(LG,1),X,2,6,[`BC`,`AD`])[s]);break;case 121:P2e(e,n,r);break;case 77:_ut(e,n,r);break;case 107:c=i.q.getHours(),c==0?Ub(e,24,n):Ub(e,c,n);break;case 83:Gat(e,n,i);break;case 69:u=r.q.getDay(),n==5?gl(e,U(O(LG,1),X,2,6,[`S`,`M`,`T`,`W`,`T`,`F`,`S`])[u]):n==4?gl(e,U(O(LG,1),X,2,6,[UF,WF,GF,KF,qF,JF,YF])[u]):gl(e,U(O(LG,1),X,2,6,[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`])[u]);break;case 97:i.q.getHours()>=12&&i.q.getHours()<24?gl(e,U(O(LG,1),X,2,6,[`AM`,`PM`])[1]):gl(e,U(O(LG,1),X,2,6,[`AM`,`PM`])[0]);break;case 104:d=i.q.getHours()%12,d==0?Ub(e,12,n):Ub(e,d,n);break;case 75:f=i.q.getHours()%12,Ub(e,f,n);break;case 72:p=i.q.getHours(),Ub(e,p,n);break;case 99:m=r.q.getDay(),n==5?gl(e,U(O(LG,1),X,2,6,[`S`,`M`,`T`,`W`,`T`,`F`,`S`])[m]):n==4?gl(e,U(O(LG,1),X,2,6,[UF,WF,GF,KF,qF,JF,YF])[m]):n==3?gl(e,U(O(LG,1),X,2,6,[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`])[m]):Ub(e,m,1);break;case 76:h=r.q.getMonth(),n==5?gl(e,U(O(LG,1),X,2,6,[`J`,`F`,`M`,`A`,`M`,`J`,`J`,`A`,`S`,`O`,`N`,`D`])[h]):n==4?gl(e,U(O(LG,1),X,2,6,[kF,AF,jF,MF,NF,PF,FF,IF,LF,RF,zF,BF])[h]):n==3?gl(e,U(O(LG,1),X,2,6,[`Jan`,`Feb`,`Mar`,`Apr`,NF,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`])[h]):Ub(e,h+1,n);break;case 81:g=r.q.getMonth()/3|0,n<4?gl(e,U(O(LG,1),X,2,6,[`Q1`,`Q2`,`Q3`,`Q4`])[g]):gl(e,U(O(LG,1),X,2,6,[`1st quarter`,`2nd quarter`,`3rd quarter`,`4th quarter`])[g]);break;case 100:_=r.q.getDate(),Ub(e,_,n);break;case 109:l=i.q.getMinutes(),Ub(e,l,n);break;case 115:o=i.q.getSeconds(),Ub(e,o,n);break;case 122:n<4?gl(e,a.c[0]):gl(e,a.c[1]);break;case 118:gl(e,a.b);break;case 90:n<3?gl(e,Ytt(a)):n==3?gl(e,cnt(a)):gl(e,lnt(a.a));break;default:return!1}return!0}function _P(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae;if(Nlt(t),c=P(H((!t.b&&(t.b=new cf(H5,t,4,7)),t.b),0),84),u=P(H((!t.c&&(t.c=new cf(H5,t,5,8)),t.c),0),84),s=cA(c),l=cA(u),o=(!t.a&&(t.a=new F(W5,t,6,6)),t.a).i==0?null:P(H((!t.a&&(t.a=new F(W5,t,6,6)),t.a),0),166),ee=P(xh(e.a,s),10),re=P(xh(e.a,l),10),te=null,ie=null,j(c,193)&&(S=P(xh(e.a,c),305),j(S,12)?te=P(S,12):j(S,10)&&(ee=P(S,10),te=P(Ep(ee.j,0),12))),j(u,193)&&(C=P(xh(e.a,u),305),j(C,12)?ie=P(C,12):j(C,10)&&(re=P(C,10),ie=P(Ep(re.j,0),12))),!ee||!re)throw E(new Bi(`The source or the target of edge `+t+` could not be found. This usually happens when an edge connects a node laid out by ELK Layered to a node in another level of hierarchy laid out by either another instance of ELK Layered or another layout algorithm alltogether. The former can be solved by setting the hierarchyHandling option to INCLUDE_CHILDREN.`));for(h=new i_,VC(h,t),W(h,(Y(),WQ),t),W(h,(mP(),j1),null),p=P(K(r,OQ),21),ee==re&&p.Fc((uM(),QZ)),te||=(x=(uS(),r2),ne=null,o&&Kl(P(K(ee,Q1),101))&&(ne=new k(o.j,o.k),nHe(ne,T_(t)),QHe(ne,n),Ex(l,s)&&(x=n2,$d(ne,ee.n))),upt(ee,ne,x,r)),ie||=(x=(uS(),n2),ae=null,o&&Kl(P(K(re,Q1),101))&&(ae=new k(o.b,o.c),nHe(ae,T_(t)),QHe(ae,n)),upt(re,ae,x,Bh(re))),U_(h,te),K_(h,ie),(te.e.c.length>1||te.g.c.length>1||ie.e.c.length>1||ie.g.c.length>1)&&p.Fc((uM(),qZ)),f=new Lu((!t.n&&(t.n=new F(Q5,t,1,7)),t.n));f.e!=f.i.gc();)if(d=P(gO(f),135),!ki(Od(J(d,J1)))&&d.a)switch(g=lT(d),M(h.b,g),P(K(g,b1),278).g){case 1:case 2:p.Fc((uM(),GZ));break;case 0:p.Fc((uM(),UZ)),W(g,b1,(Lx(),o8))}if(a=P(K(r,h1),322),_=P(K(r,U1),323),i=a==(bS(),$X)||_==(CO(),H0),o&&(!o.a&&(o.a=new ju(z5,o,5)),o.a).i!=0&&i){for(v=FA(o),m=new ai,b=dO(v,0);b.b!=b.d.c;)y=P(Lv(b),8),up(m,new Vl(y));W(h,GQ,m)}return h}function Ovt(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne=0,C=0,re,ie,ae,oe;for(ee=new Dr,x=P(Ju(_m(gg(new Mp(null,new cv(e.b,16)),new zae),new qae)),17).a+1,te=V(q9,HF,28,x,15,1),g=V(q9,HF,28,x,15,1),h=0;h1)for(s=ie+1;sl.b.e.b*(1-_)+l.c.e.b*_));m++);if(S.gc()>0&&(ae=l.a.b==0?xu(l.b.e):P(vd(l.a),8),y=$d(xu(P(S.Xb(S.gc()-1),40).e),P(S.Xb(S.gc()-1),40).f),f=$d(xu(P(S.Xb(0),40).e),P(S.Xb(0),40).f),m>=S.gc()-1&&ae.b>y.b&&l.c.e.b>y.b||m<=0&&ae.bl.b.e.a*(1-_)+l.c.e.a*_));m++);if(S.gc()>0&&(ae=l.a.b==0?xu(l.b.e):P(vd(l.a),8),y=$d(xu(P(S.Xb(S.gc()-1),40).e),P(S.Xb(S.gc()-1),40).f),f=$d(xu(P(S.Xb(0),40).e),P(S.Xb(0),40).f),m>=S.gc()-1&&ae.a>y.a&&l.c.e.a>y.a||m<=0&&ae.a=D(N(K(e,(tP(),BPt))))&&++C):(p.f&&p.d.e.a<=D(N(K(e,(tP(),K2))))&&++ne,p.g&&p.c.e.a+p.c.f.a>=D(N(K(e,(tP(),zPt))))&&++C)}else b==0?mnt(l):b<0&&(++te[ie],++g[oe],re=xvt(l,t,e,new Kc(G(ne),G(C)),n,r,new Kc(G(g[oe]),G(te[ie]))),ne=P(re.a,17).a,C=P(re.b,17).a)}function kvt(e,t,n){var r=t,i,a,o,s,c=n,l,u,d,f,p,m,h,g,_,v;if(e.b&&r.j==(nP(),g5)&&c.j==(nP(),g5)&&(v=r,r=c,c=v),km(e.a,r)){if(mo(P(xh(e.a,r),49),c))return 1}else Qh(e.a,r,new Jr);if(km(e.a,c)){if(mo(P(xh(e.a,c),49),r))return-1}else Qh(e.a,c,new Jr);if(km(e.d,r)){if(mo(P(xh(e.d,r),49),c))return-1}else Qh(e.d,r,new Jr);if(km(e.d,c)){if(mo(P(xh(e.a,c),49),r))return 1}else Qh(e.d,c,new Jr);if(r.j!=c.j)return _=zCe(r.j,c.j),_==-1?NM(e,c,r):NM(e,r,c),_;if(r.e.c.length!=0&&c.e.c.length!=0){if(e.b&&(_=RQe(r,c),_!=0))return _==-1?NM(e,c,r):_==1&&NM(e,r,c),_;if(a=P(Ep(r.e,0),18).c.i,u=P(Ep(c.e,0),18).c.i,a==u)return i=P(K(P(Ep(r.e,0),18),(Y(),UQ)),17).a,l=P(K(P(Ep(c.e,0),18),UQ),17).a,i>l?NM(e,r,c):NM(e,c,r),il);for(m=e.c,h=0,g=m.length;hl?NM(e,r,c):NM(e,c,r),il)):e.b&&(_=RQe(r,c),_!=0)?(_==-1?NM(e,c,r):_==1&&NM(e,r,c),_):(o=0,d=0,yd(P(Ep(r.g,0),18),UQ)&&(o=P(K(P(Ep(r.g,0),18),UQ),17).a),yd(P(Ep(c.g,0),18),UQ)&&(d=P(K(P(Ep(r.g,0),18),UQ),17).a),s&&s==f?ki(Od(K(P(Ep(r.g,0),18),r$)))&&!ki(Od(K(P(Ep(c.g,0),18),r$)))?(NM(e,r,c),1):!ki(Od(K(P(Ep(r.g,0),18),r$)))&&ki(Od(K(P(Ep(c.g,0),18),r$)))?(NM(e,c,r),-1):(o>d?NM(e,r,c):NM(e,c,r),od)):(e.f&&(e.f._b(s)&&(o=P(e.f.xc(s),17).a),e.f._b(f)&&(d=P(e.f.xc(f),17).a)),o>d?NM(e,r,c):NM(e,c,r),od)))):r.e.c.length!=0&&c.g.c.length!=0?(NM(e,r,c),1):r.g.c.length!=0&&c.e.c.length!=0?(NM(e,c,r),-1):yd(r,(Y(),UQ))&&yd(c,UQ)?(i=P(K(r,UQ),17).a,l=P(K(c,UQ),17).a,i>l?NM(e,r,c):NM(e,c,r),il)):(NM(e,c,r),-1)}function Avt(e){e.gb||(e.gb=!0,e.b=PC(e,0),JS(e.b,18),YS(e.b,19),e.a=PC(e,1),JS(e.a,1),YS(e.a,2),YS(e.a,3),YS(e.a,4),YS(e.a,5),e.o=PC(e,2),JS(e.o,8),JS(e.o,9),YS(e.o,10),YS(e.o,11),YS(e.o,12),YS(e.o,13),YS(e.o,14),YS(e.o,15),YS(e.o,16),YS(e.o,17),YS(e.o,18),YS(e.o,19),YS(e.o,20),YS(e.o,21),YS(e.o,22),YS(e.o,23),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),vx(e.o),e.p=PC(e,3),JS(e.p,2),JS(e.p,3),JS(e.p,4),JS(e.p,5),YS(e.p,6),YS(e.p,7),vx(e.p),vx(e.p),e.q=PC(e,4),JS(e.q,8),e.v=PC(e,5),YS(e.v,9),vx(e.v),vx(e.v),vx(e.v),e.w=PC(e,6),JS(e.w,2),JS(e.w,3),JS(e.w,4),YS(e.w,5),e.B=PC(e,7),YS(e.B,1),vx(e.B),vx(e.B),vx(e.B),e.Q=PC(e,8),YS(e.Q,0),vx(e.Q),e.R=PC(e,9),JS(e.R,1),e.S=PC(e,10),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),vx(e.S),e.T=PC(e,11),YS(e.T,10),YS(e.T,11),YS(e.T,12),YS(e.T,13),YS(e.T,14),vx(e.T),vx(e.T),e.U=PC(e,12),JS(e.U,2),JS(e.U,3),YS(e.U,4),YS(e.U,5),YS(e.U,6),YS(e.U,7),vx(e.U),e.V=PC(e,13),YS(e.V,10),e.W=PC(e,14),JS(e.W,18),JS(e.W,19),JS(e.W,20),YS(e.W,21),YS(e.W,22),YS(e.W,23),e.bb=PC(e,15),JS(e.bb,10),JS(e.bb,11),JS(e.bb,12),JS(e.bb,13),JS(e.bb,14),JS(e.bb,15),JS(e.bb,16),YS(e.bb,17),vx(e.bb),vx(e.bb),e.eb=PC(e,16),JS(e.eb,2),JS(e.eb,3),JS(e.eb,4),JS(e.eb,5),JS(e.eb,6),JS(e.eb,7),YS(e.eb,8),YS(e.eb,9),e.ab=PC(e,17),JS(e.ab,0),JS(e.ab,1),e.H=PC(e,18),YS(e.H,0),YS(e.H,1),YS(e.H,2),YS(e.H,3),YS(e.H,4),YS(e.H,5),vx(e.H),e.db=PC(e,19),YS(e.db,2),e.c=FC(e,20),e.d=FC(e,21),e.e=FC(e,22),e.f=FC(e,23),e.i=FC(e,24),e.g=FC(e,25),e.j=FC(e,26),e.k=FC(e,27),e.n=FC(e,28),e.r=FC(e,29),e.s=FC(e,30),e.t=FC(e,31),e.u=FC(e,32),e.fb=FC(e,33),e.A=FC(e,34),e.C=FC(e,35),e.D=FC(e,36),e.F=FC(e,37),e.G=FC(e,38),e.I=FC(e,39),e.J=FC(e,40),e.L=FC(e,41),e.M=FC(e,42),e.N=FC(e,43),e.O=FC(e,44),e.P=FC(e,45),e.X=FC(e,46),e.Y=FC(e,47),e.Z=FC(e,48),e.$=FC(e,49),e._=FC(e,50),e.cb=FC(e,51),e.K=FC(e,52))}function jvt(e,t,n){var r,i,a,o=new vo,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=P(K(n,(mP(),_1)),88),ee,te,ne,C,re,ie;for(h=0,XS(o,(!t.a&&(t.a=new F($5,t,10,11)),t.a));o.b!=0;)u=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),27),l=I_(u),(A(J(l,s1))!==A((ID(),Z0))||A(J(l,g1))===A((FD(),dZ))||A(J(l,g1))===A((FD(),lZ))||ki(Od(J(l,l1)))||A(J(l,t1))!==A((YD(),RJ))||A(J(l,P1))===A((FM(),G0))||A(J(l,P1))===A((FM(),K0))||A(J(l,F1))===A((Zj(),k0))||A(J(l,F1))===A((Zj(),j0)))&&!ki(Od(J(u,a1)))&&OO(u,(Y(),UQ),G(h++)),_=!ki(Od(J(u,J1))),_&&(f=(!u.a&&(u.a=new F($5,u,10,11)),u.a).i!=0,m=c7e(u),p=A(J(u,D1))===A((_T(),g8)),ie=!qy(u,(vP(),s6))||wUe(kd(J(u,s6))),b=null,ie&&p&&(f||m)&&(b=Fdt(u),W(b,_1,S),yd(b,a0)&&Q_e(new rD(D(N(K(b,a0)))),b),P(J(u,W1),181).gc()!=0&&(d=b,To(new Mp(null,(!u.c&&(u.c=new F(e7,u,9,9)),new cv(u.c,16))),new lpe(d)),rct(u,b))),ee=n,te=P(xh(e.a,I_(u)),10),te&&(ee=te.e),y=F_t(e,u,ee),b&&(y.e=b,b.e=y,XS(o,(!u.a&&(u.a=new F($5,u,10,11)),u.a))));for(h=0,iy(o,t,o.c.b,o.c);o.b!=0;){for(a=P(o.b==0?null:(jd(o.b!=0),Ox(o,o.a.a)),27),c=new Lu((!a.b&&(a.b=new F(U5,a,12,3)),a.b));c.e!=c.i.gc();)s=P(gO(c),74),Nlt(s),(A(J(t,s1))!==A((ID(),Z0))||A(J(t,g1))===A((FD(),dZ))||A(J(t,g1))===A((FD(),lZ))||ki(Od(J(t,l1)))||A(J(t,t1))!==A((YD(),RJ))||A(J(t,P1))===A((FM(),G0))||A(J(t,P1))===A((FM(),K0))||A(J(t,F1))===A((Zj(),k0))||A(J(t,F1))===A((Zj(),j0)))&&OO(s,(Y(),UQ),G(h++)),C=cA(P(H((!s.b&&(s.b=new cf(H5,s,4,7)),s.b),0),84)),re=cA(P(H((!s.c&&(s.c=new cf(H5,s,5,8)),s.c),0),84)),!(ki(Od(J(s,J1)))||ki(Od(J(C,J1)))||ki(Od(J(re,J1))))&&(g=uj(s)&&ki(Od(J(C,k1)))&&ki(Od(J(s,A1))),x=a,g||Ex(re,C)?x=C:Ex(C,re)&&(x=re),ee=n,te=P(xh(e.a,x),10),te&&(ee=te.e),v=_P(e,s,x,ee),W(v,(Y(),hQ),Est(e,s,t,n)));if(p=A(J(a,D1))===A((_T(),g8)),p)for(i=new Lu((!a.a&&(a.a=new F($5,a,10,11)),a.a));i.e!=i.i.gc();)r=P(gO(i),27),ie=!qy(r,(vP(),s6))||wUe(kd(J(r,s6))),ne=A(J(r,D1))===A(g8),ie&&ne&&iy(o,r,o.c.b,o.c)}}function Y(){Y=C;var e,t;WQ=new yr(sbt),hQ=new yr(`coordinateOrigin`),e$=new yr(`processors`),mQ=new Wd(`compoundNode`,(rd(),!1)),jQ=new Wd(`insideConnections`,!1),GQ=new yr(`originalBendpoints`),KQ=new yr(`originalDummyNodePosition`),qQ=new yr(`originalLabelEdge`),n$=new yr(`representedLabels`),bQ=new yr(`endLabels`),xQ=new yr(`endLabel.origin`),IQ=new Wd(`labelSide`,(kk(),S8)),HQ=new Wd(`maxEdgeThickness`,0),r$=new Wd(`reversed`,!1),t$=new yr(cbt),zQ=new Wd(`longEdgeSource`,null),BQ=new Wd(`longEdgeTarget`,null),RQ=new Wd(`longEdgeHasLabelDummies`,!1),LQ=new Wd(`longEdgeBeforeLabelDummy`,!1),yQ=new Wd(`edgeConstraint`,(_w(),_Z)),NQ=new yr(`inLayerLayoutUnit`),MQ=new Wd(`inLayerConstraint`,(Zb(),aQ)),PQ=new Wd(`inLayerSuccessorConstraint`,new T),FQ=new Wd(`inLayerSuccessorConstraintBetweenNonDummies`,!1),QQ=new yr(`portDummy`),gQ=new Wd(`crossingHint`,G(0)),OQ=new Wd(`graphProperties`,(t=P(Ba($Z),9),new xf(t,P(Yd(t,t.length),9),0))),TQ=new Wd(`externalPortSide`,(nP(),h5)),EQ=new Wd(`externalPortSize`,new Fa),CQ=new yr(`externalPortReplacedDummies`),wQ=new yr(`externalPortReplacedDummy`),SQ=new Wd(`externalPortConnections`,(e=P(Ba(_5),9),new xf(e,P(Yd(e,e.length),9),0))),$Q=new Wd(Byt,0),uQ=new yr(`barycenterAssociates`),p$=new yr(`TopSideComments`),dQ=new yr(`BottomSideComments`),pQ=new yr(`CommentConnectionPort`),AQ=new Wd(`inputCollect`,!1),XQ=new Wd(`outputCollect`,!1),vQ=new Wd(`cyclic`,!1),_Q=new yr(`crossHierarchyMap`),f$=new yr(`targetOffset`),new Wd(`splineLabelSize`,new Fa),o$=new yr(`spacings`),ZQ=new Wd(`partitionConstraint`,!1),fQ=new yr(`breakingPoint.info`),u$=new yr(`splines.survivingEdge`),l$=new yr(`splines.route.start`),s$=new yr(`splines.edgeChain`),YQ=new yr(`originalPortConstraints`),a$=new yr(`selfLoopHolder`),c$=new yr(`splines.nsPortY`),UQ=new yr(`modelOrder`),VQ=new yr(`longEdgeTargetNode`),DQ=new Wd(Vbt,!1),i$=new Wd(Vbt,!1),kQ=new yr(`layerConstraints.hiddenNodes`),JQ=new yr(`layerConstraints.opposidePort`),d$=new yr(`targetNode.modelOrder`)}function Mvt(e,t,n,i){var a,o,s,c,l,u,d,f,p,m,h;for(f=dO(e.b,0);f.b!=f.d.c;)if(d=P(Lv(f),40),!ff(d.c,LV))for(o=P(ay(new Mp(null,new cv(Vnt(d,e),16)),cb(new Te,new we,new Ne,U(O(xK,1),Z,108,0,[(Zw(),yK)]))),15),t==(GT(),t8)||t==n8?o.jd(new Uae):o.jd(new Wae),h=o.gc(),a=0;a0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(l-m)/(r.Math.abs(c-p)/40)>50&&(m>l?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a+i/5.3,d.e.b+d.f.b*s-i/2)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a+i/5.3,d.e.b+d.f.b*s+i/2)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a,d.e.b+d.f.b*s))):t==n8?(u=D(N(K(d,(tP(),$2)))),d.e.a-i>u?yl(P(o.Xb(a),65).a,new k(u-n,d.e.b+d.f.b*s)):P(o.Xb(a),65).a.b>0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(l-m)/(r.Math.abs(c-p)/40)>50&&(m>l?yl(P(o.Xb(a),65).a,new k(d.e.a-i/5.3,d.e.b+d.f.b*s-i/2)):yl(P(o.Xb(a),65).a,new k(d.e.a-i/5.3,d.e.b+d.f.b*s+i/2)))),yl(P(o.Xb(a),65).a,new k(d.e.a,d.e.b+d.f.b*s))):t==i8?(u=D(N(K(d,(tP(),Q2)))),d.e.b+d.f.b+i0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(c-p)/(r.Math.abs(l-m)/40)>50&&(p>c?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s-i/2,d.e.b+i/5.3+d.f.b)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s+i/2,d.e.b+i/5.3+d.f.b)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,d.e.b+d.f.b))):(u=D(N(K(d,(tP(),$2)))),GZe(P(o.Xb(a),65),e)?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,P(vd(P(o.Xb(a),65).a),8).b)):d.e.b-i>u?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,u-n)):P(o.Xb(a),65).a.b>0&&(c=P(vd(P(o.Xb(a),65).a),8).a,p=d.e.a+d.f.a/2,l=P(vd(P(o.Xb(a),65).a),8).b,m=d.e.b+d.f.b/2,i>0&&r.Math.abs(c-p)/(r.Math.abs(l-m)/40)>50&&(p>c?yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s-i/2,d.e.b-i/5.3)):yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s+i/2,d.e.b-i/5.3)))),yl(P(o.Xb(a),65).a,new k(d.e.a+d.f.a*s,d.e.b)))}function vP(){vP=C;var e,t;s6=new yr(pSt),W6=new yr(mSt),nzt=(RO(),q3),tzt=new Tl(GB,nzt),new Er,c6=new Tl(FL,null),rzt=new yr(hSt),szt=(eA(),Zp(a6,U(O(o6,1),Z,298,0,[t6]))),d6=new Tl(rV,szt),f6=new Tl(WB,(rd(),!1)),czt=(GT(),r8),p6=new Tl(JB,czt),dzt=(wE(),f8),uzt=new Tl(xB,dzt),mzt=new Tl(dSt,!1),hzt=(_T(),_8),g6=new Tl(bB,hzt),Tzt=new iu(12),A6=new Tl(IL,Tzt),y6=new Tl(tR,!1),b6=new Tl(hV,!1),k6=new Tl(iR,!1),Nzt=(rA(),H8),I6=new Tl(nR,Nzt),V6=new yr(fV),H6=new yr(XL),U6=new yr($L),G6=new yr(eR),_zt=new ai,x6=new Tl(iV,_zt),ozt=new Tl(sV,!1),gzt=new Tl(cV,!1),new yr(gSt),vzt=new ei,S6=new Tl(pV,vzt),O6=new Tl(HB,!1),new Er,Lzt=new Tl(_St,1),u6=new yr(vSt),l6=new yr(ySt),Z6=new Tl(uR,!1),new Tl(bSt,!0),G(0),new Tl(xSt,G(100)),new Tl(SSt,!1),G(0),new Tl(CSt,G(4e3)),G(0),new Tl(wSt,G(400)),new Tl(TSt,!1),new Tl(ESt,!1),new Tl(DSt,!0),new Tl(OSt,!1),azt=(ZE(),F5),izt=new Tl(fSt,azt),Rzt=new Tl(AB,10),zzt=new Tl(jB,10),Bzt=new Tl(NL,20),Vzt=new Tl(MB,10),Hzt=new Tl(QL,2),Uzt=new Tl(NB,10),Wzt=new Tl(PB,0),q6=new Tl(LB,5),Gzt=new Tl(FB,1),Kzt=new Tl(IB,1),J6=new Tl(ZL,20),qzt=new Tl(RB,10),Xzt=new Tl(zB,10),K6=new yr(BB),Yzt=new OCe,Jzt=new Tl(mV,Yzt),Ozt=new yr(dV),Dzt=!1,Ezt=new Tl(uV,Dzt),bzt=new iu(5),yzt=new Tl(YB,bzt),xzt=(Ej(),t=P(Ba(M8),9),new xf(t,P(Yd(t,t.length),9),0)),C6=new Tl(cR,xzt),jzt=(pO(),P8),Azt=new Tl(QB,jzt),M6=new yr($B),N6=new yr(eV),P6=new yr(tV),j6=new yr(nV),Szt=(e=P(Ba(S5),9),new xf(e,P(Yd(e,e.length),9),0)),w6=new Tl(sR,Szt),wzt=sE((UM(),T5)),D6=new Tl(oR,wzt),Czt=new k(0,0),E6=new Tl(gR,Czt),T6=new Tl(aR,!1),lzt=(Lx(),o8),h6=new Tl(aV,lzt),m6=new Tl(rR,!1),new yr(kSt),G(1),new Tl(ASt,null),Mzt=new yr(lV),L6=new yr(oV),Izt=(nP(),h5),B6=new Tl(UB,Izt),F6=new yr(VB),Pzt=(rj(),sE(q8)),z6=new Tl(lR,Pzt),R6=new Tl(XB,!1),Fzt=new Tl(ZB,!0),new Er,$6=new Tl(dR,1),eBt=new Tl(jSt,null),X6=new Tl(fR,150),Y6=new Tl(pR,1.414),Q6=new Tl(mR,null),Zzt=new Tl(MSt,1),_6=new Tl(KB,!1),v6=new Tl(qB,!1),fzt=new Tl(PL,1),pzt=(hA(),m8),new Tl(NSt,pzt),kzt=!0,$zt=(gT(),M5),tBt=M5,Qzt=M5}function yP(){yP=C,_Y=new ks(`DIRECTION_PREPROCESSOR`,0),mY=new ks(`COMMENT_PREPROCESSOR`,1),vY=new ks(`EDGE_AND_LAYER_CONSTRAINT_EDGE_REVERSER`,2),PY=new ks(`INTERACTIVE_EXTERNAL_PORT_POSITIONER`,3),$Y=new ks(`PARTITION_PREPROCESSOR`,4),RY=new ks(`LABEL_DUMMY_INSERTER`,5),aX=new ks(`SELF_LOOP_PREPROCESSOR`,6),UY=new ks(`LAYER_CONSTRAINT_PREPROCESSOR`,7),ZY=new ks(`PARTITION_MIDPROCESSOR`,8),kY=new ks(`HIGH_DEGREE_NODE_LAYER_PROCESSOR`,9),qY=new ks(`NODE_PROMOTION`,10),HY=new ks(`LAYER_CONSTRAINT_POSTPROCESSOR`,11),QY=new ks(`PARTITION_POSTPROCESSOR`,12),TY=new ks(`HIERARCHICAL_PORT_CONSTRAINT_PROCESSOR`,13),sX=new ks(`SEMI_INTERACTIVE_CROSSMIN_PROCESSOR`,14),cY=new ks(`BREAKING_POINT_INSERTER`,15),KY=new ks(`LONG_EDGE_SPLITTER`,16),tX=new ks(`PORT_SIDE_PROCESSOR`,17),FY=new ks(`INVERTED_PORT_PROCESSOR`,18),eX=new ks(`PORT_LIST_SORTER`,19),lX=new ks(`SORT_BY_INPUT_ORDER_OF_MODEL`,20),YY=new ks(`NORTH_SOUTH_PORT_PREPROCESSOR`,21),lY=new ks(`BREAKING_POINT_PROCESSOR`,22),XY=new ks(Nbt,23),uX=new ks(Pbt,24),rX=new ks(`SELF_LOOP_PORT_RESTORER`,25),cX=new ks(`SINGLE_EDGE_GRAPH_WRAPPER`,26),IY=new ks(`IN_LAYER_CONSTRAINT_PROCESSOR`,27),SY=new ks(`END_NODE_PORT_LABEL_MANAGEMENT_PROCESSOR`,28),LY=new ks(`LABEL_AND_NODE_SIZE_PROCESSOR`,29),NY=new ks(`INNERMOST_NODE_MARGIN_CALCULATOR`,30),oX=new ks(`SELF_LOOP_ROUTER`,31),fY=new ks(`COMMENT_NODE_MARGIN_CALCULATOR`,32),bY=new ks(`END_LABEL_PREPROCESSOR`,33),BY=new ks(`LABEL_DUMMY_SWITCHER`,34),dY=new ks(`CENTER_LABEL_MANAGEMENT_PROCESSOR`,35),VY=new ks(`LABEL_SIDE_SELECTOR`,36),jY=new ks(`HYPEREDGE_DUMMY_MERGER`,37),EY=new ks(`HIERARCHICAL_PORT_DUMMY_SIZE_PROCESSOR`,38),WY=new ks(`LAYER_SIZE_AND_GRAPH_HEIGHT_CALCULATOR`,39),OY=new ks(`HIERARCHICAL_PORT_POSITION_PROCESSOR`,40),hY=new ks(`CONSTRAINTS_POSTPROCESSOR`,41),pY=new ks(`COMMENT_POSTPROCESSOR`,42),MY=new ks(`HYPERNODE_PROCESSOR`,43),DY=new ks(`HIERARCHICAL_PORT_ORTHOGONAL_EDGE_ROUTER`,44),GY=new ks(`LONG_EDGE_JOINER`,45),iX=new ks(`SELF_LOOP_POSTPROCESSOR`,46),uY=new ks(`BREAKING_POINT_REMOVER`,47),JY=new ks(`NORTH_SOUTH_PORT_POSTPROCESSOR`,48),AY=new ks(`HORIZONTAL_COMPACTOR`,49),zY=new ks(`LABEL_DUMMY_REMOVER`,50),CY=new ks(`FINAL_SPLINE_BENDPOINTS_CALCULATOR`,51),xY=new ks(`END_LABEL_SORTER`,52),nX=new ks(`REVERSED_EDGE_RESTORER`,53),yY=new ks(`END_LABEL_POSTPROCESSOR`,54),wY=new ks(`HIERARCHICAL_NODE_RESIZER`,55),gY=new ks(`DIRECTION_POSTPROCESSOR`,56)}function bP(){bP=C,k$=(px(),pZ),Jkt=new Tl(XR,k$),oAt=new Tl(ZR,(rd(),!1)),F$=(Bv(),sQ),dAt=new Tl(QR,F$),EAt=new Tl($R,!1),DAt=new Tl(ez,!0),bkt=new Tl(tz,!1),U$=(Qb(),e2),HAt=new Tl(nz,U$),G(1),XAt=new Tl(rz,G(7)),ZAt=new Tl(iz,!1),sAt=new Tl(az,!1),O$=(FD(),cZ),qkt=new Tl(oz,O$),R$=(Zj(),N0),TAt=new Tl(sz,R$),I$=(XE(),v$),_At=new Tl(cz,I$),G(-1),gAt=new Tl(lz,null),G(-1),vAt=new Tl(uz,G(-1)),G(-1),yAt=new Tl(dz,G(4)),G(-1),xAt=new Tl(fz,G(2)),L$=(FM(),Y0),wAt=new Tl(pz,L$),G(0),CAt=new Tl(mz,G(0)),mAt=new Tl(hz,G(AP)),D$=(bS(),eZ),Kkt=new Tl(gz,D$),jkt=new Tl(_z,!1),Rkt=new Tl(vz,.1),Wkt=new Tl(yz,!1),Bkt=new Tl(bz,null),Vkt=new Tl(xz,null),G(-1),Hkt=new Tl(Sz,null),G(-1),Ukt=new Tl(Cz,G(-1)),G(0),Mkt=new Tl(wz,G(40)),E$=(qC(),nQ),Ikt=new Tl(Tz,E$),T$=eQ,Nkt=new Tl(Ez,T$),H$=(CO(),V0),VAt=new Tl(Dz,H$),MAt=new yr(Oz),z$=(wb(),EZ),OAt=new Tl(kz,z$),B$=(qk(),MZ),AAt=new Tl(Az,B$),new Er,FAt=new Tl(jz,.3),LAt=new yr(Mz),V$=(IO(),R0),RAt=new Tl(Nz,V$),M$=(CC(),a2),$kt=new Tl(Pz,M$),N$=(Nw(),c2),eAt=new Tl(Fz,N$),P$=(Xw(),u2),tAt=new Tl(Iz,P$),rAt=new Tl(Lz,.2),Zkt=new Tl(Rz,2),KAt=new Tl(zz,null),JAt=new Tl(Bz,10),qAt=new Tl(Vz,10),YAt=new Tl(Hz,20),G(0),UAt=new Tl(Uz,G(0)),G(0),WAt=new Tl(Wz,G(0)),G(0),GAt=new Tl(Gz,G(0)),xkt=new Tl(Kz,!1),x$=(TA(),BZ),Ckt=new Tl(qz,x$),b$=(Ky(),ZX),Skt=new Tl(Jz,b$),lAt=new Tl(Yz,!1),G(0),cAt=new Tl(Xz,G(16)),G(0),uAt=new Tl(Zz,G(5)),K$=(sw(),p2),_jt=new Tl(Qz,K$),QAt=new Tl($z,10),tjt=new Tl(eB,1),G$=(lS(),aZ),cjt=new Tl(tB,G$),ijt=new yr(nB),W$=G(1),G(0),ojt=new Tl(rB,W$),q$=(cS(),d2),xjt=new Tl(iB,q$),vjt=new yr(aB),pjt=new Tl(oB,!0),djt=new Tl(sB,2),hjt=new Tl(cB,!0),j$=(kA(),CZ),Xkt=new Tl(lB,j$),A$=(GA(),GX),Ykt=new Tl(uB,A$),w$=(ID(),Z0),Akt=new Tl(dB,w$),kkt=new Tl(fB,!1),Okt=new Tl(pB,!1),S$=(YD(),RJ),wkt=new Tl(mB,S$),C$=(hT(),P0),Dkt=new Tl(hB,C$),Tkt=new Tl(gB,0),Ekt=new Tl(_B,0),pAt=uZ,fAt=$X,bAt=M0,SAt=M0,hAt=A0,zkt=(_T(),g8),Gkt=eZ,Lkt=eZ,Pkt=eZ,Fkt=g8,NAt=W0,PAt=V0,kAt=V0,jAt=V0,IAt=U0,BAt=W0,zAt=W0,nAt=(wE(),d8),iAt=d8,aAt=u2,Qkt=u8,$At=m2,ejt=f2,njt=m2,rjt=f2,ljt=m2,ujt=f2,ajt=iZ,sjt=aZ,Sjt=m2,Cjt=f2,yjt=m2,bjt=f2,mjt=f2,fjt=f2,gjt=f2}function Nvt(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C,re,ie,ae,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe=0,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le;for(oe=t,le=0,fe=oe.length;le0&&(e.a[ye.p]=Oe++)}for(Ne=0,se=n,ue=0,pe=se.length;ue0;){for(ye=(jd(Ce.b>0),P(Ce.a.Xb(Ce.c=--Ce.b),12)),Se=0,c=new w(ye.e);c.a0&&(ye.j==(nP(),Z8)?(e.a[ye.p]=Ne,++Ne):(e.a[ye.p]=Ne+me+ge,++ge))}Ne+=ge}for(xe=new Dr,h=new Rl,ae=t,ce=0,de=ae.length;ceu.b&&(u.b=we)):ye.i.c==De&&(weu.c&&(u.c=we));for(bb(g,0,g.length,null),Me=V(q9,HF,28,g.length,15,1),i=V(q9,HF,28,Ne+1,15,1),v=0;v0;)te%2>0&&(a+=Ie[te+1]),te=(te-1)/2|0,++Ie[te];for(C=V(INt,FP,374,g.length*2,0,1),x=0;x0&&h_(ce.f),J(v,eBt)!=null&&(c=P(J(v,eBt),347),xe=c.Tg(v),Ql(v,r.Math.max(v.g,xe.a),r.Math.max(v.f,xe.b)));if(pe=P(J(t,A6),107),m=t.g-(pe.b+pe.c),p=t.f-(pe.d+pe.a),we.bh(`Available Child Area: (`+m+`|`+p+`)`),OO(t,c6,m/p),D2e(t,a,i.eh(de)),P(J(t,Q6),280)==N5&&(G_t(t),Ql(t,pe.b+D(N(J(t,u6)))+pe.c,pe.d+D(N(J(t,l6)))+pe.a)),we.bh(`Executed layout algorithm: `+kd(J(t,s6))+` on node `+t.k),P(J(t,Q6),280)==M5){if(m<0||p<0)throw E(new zi(`The size defined by the parent parallel node is too small for the space provided by the paddings of the child hierarchical node. `+t.k));for(qy(t,u6)||qy(t,l6)||G_t(t),g=D(N(J(t,u6))),h=D(N(J(t,l6))),we.bh(`Desired Child Area: (`+g+`|`+h+`)`),he=m/g,ge=p/h,me=r.Math.min(he,r.Math.min(ge,D(N(J(t,Zzt))))),OO(t,$6,me),we.bh(t.k+` -- Local Scale Factor (X|Y): (`+he+`|`+ge+`)`),x=P(J(t,d6),21),o=0,s=0,me'?`:ff(DCt,e)?`'(?<' or '(? toIndex: `,VI=`, toIndex: `,HI=`Index: `,UI=`, Size: `,WI=`org.eclipse.elk.alg.common`,GI={50:1},yyt=`org.eclipse.elk.alg.common.compaction`,byt=`Scanline/EventHandler`,KI=`org.eclipse.elk.alg.common.compaction.oned`,xyt=`CNode belongs to another CGroup.`,Syt=`ISpacingsHandler/1`,qI=`The `,JI=` instance has been finished already.`,Cyt=`The direction `,wyt=` is not supported by the CGraph instance.`,Tyt=`OneDimensionalCompactor`,Eyt=`OneDimensionalCompactor/lambda$0$Type`,Dyt=`Quadruplet`,Oyt=`ScanlineConstraintCalculator`,kyt=`ScanlineConstraintCalculator/ConstraintsScanlineHandler`,Ayt=`ScanlineConstraintCalculator/ConstraintsScanlineHandler/lambda$0$Type`,jyt=`ScanlineConstraintCalculator/Timestamp`,Myt=`ScanlineConstraintCalculator/lambda$0$Type`,YI={178:1,46:1},XI=`org.eclipse.elk.alg.common.compaction.options`,ZI=`org.eclipse.elk.core.data`,QI=`org.eclipse.elk.polyomino.traversalStrategy`,$I=`org.eclipse.elk.polyomino.lowLevelSort`,eL=`org.eclipse.elk.polyomino.highLevelSort`,tL=`org.eclipse.elk.polyomino.fill`,nL={134:1},rL=`polyomino`,iL=`org.eclipse.elk.alg.common.networksimplex`,aL={183:1,3:1,4:1},Nyt=`org.eclipse.elk.alg.common.nodespacing`,oL=`org.eclipse.elk.alg.common.nodespacing.cellsystem`,sL=`CENTER`,Pyt={217:1,336:1},Fyt={3:1,4:1,5:1,603:1},cL=`LEFT`,lL=`RIGHT`,Iyt=`Vertical alignment cannot be null`,Lyt=`BOTTOM`,uL=`org.eclipse.elk.alg.common.nodespacing.internal`,dL=`UNDEFINED`,fL=.01,pL=`org.eclipse.elk.alg.common.nodespacing.internal.algorithm`,Ryt=`LabelPlacer/lambda$0$Type`,zyt=`LabelPlacer/lambda$1$Type`,Byt=`portRatioOrPosition`,mL=`org.eclipse.elk.alg.common.overlaps`,hL=`DOWN`,gL=`org.eclipse.elk.alg.common.polyomino`,_L=`NORTH`,vL=`EAST`,yL=`SOUTH`,bL=`WEST`,xL=`org.eclipse.elk.alg.common.polyomino.structures`,Vyt=`Direction`,SL=`Grid is only of size `,CL=`. Requested point (`,wL=`) is out of bounds.`,TL=` Given center based coordinates were (`,EL=`org.eclipse.elk.graph.properties`,Hyt=`IPropertyHolder`,Uyt={3:1,96:1,137:1},DL=`org.eclipse.elk.alg.common.spore`,Wyt=`org.eclipse.elk.alg.common.utils`,OL={205:1},kL=`org.eclipse.elk.core`,Gyt=`Connected Components Compaction`,Kyt=`org.eclipse.elk.alg.disco`,AL=`org.eclipse.elk.alg.disco.graph`,jL=`org.eclipse.elk.alg.disco.options`,qyt=`CompactionStrategy`,Jyt=`org.eclipse.elk.disco.componentCompaction.strategy`,Yyt=`org.eclipse.elk.disco.componentCompaction.componentLayoutAlgorithm`,Xyt=`org.eclipse.elk.disco.debug.discoGraph`,Zyt=`org.eclipse.elk.disco.debug.discoPolys`,Qyt=`componentCompaction`,ML=`org.eclipse.elk.disco`,NL=`org.eclipse.elk.spacing.componentComponent`,PL=`org.eclipse.elk.edge.thickness`,FL=`org.eclipse.elk.aspectRatio`,IL=`org.eclipse.elk.padding`,LL=`org.eclipse.elk.alg.disco.transform`,RL=1.5707963267948966,zL=17976931348623157e292,BL={3:1,4:1,5:1,198:1},$yt={3:1,6:1,4:1,5:1,100:1,115:1},VL=`org.eclipse.elk.alg.force`,ebt=`ComponentsProcessor`,tbt=`ComponentsProcessor/1`,nbt=`ElkGraphImporter/lambda$0$Type`,HL=`org.eclipse.elk.alg.force.graph`,rbt=`Component Layout`,ibt=`org.eclipse.elk.alg.force.model`,UL=`org.eclipse.elk.force.model`,abt=`org.eclipse.elk.force.iterations`,obt=`org.eclipse.elk.force.repulsivePower`,WL=`org.eclipse.elk.force.temperature`,GL=.001,KL=`org.eclipse.elk.force.repulsion`,qL=`org.eclipse.elk.alg.force.options`,JL=1.600000023841858,YL=`org.eclipse.elk.force`,XL=`org.eclipse.elk.priority`,ZL=`org.eclipse.elk.spacing.nodeNode`,QL=`org.eclipse.elk.spacing.edgeLabel`,$L=`org.eclipse.elk.randomSeed`,eR=`org.eclipse.elk.separateConnectedComponents`,tR=`org.eclipse.elk.interactive`,nR=`org.eclipse.elk.portConstraints`,rR=`org.eclipse.elk.edgeLabels.inline`,iR=`org.eclipse.elk.omitNodeMicroLayout`,aR=`org.eclipse.elk.nodeSize.fixedGraphSize`,oR=`org.eclipse.elk.nodeSize.options`,sR=`org.eclipse.elk.nodeSize.constraints`,cR=`org.eclipse.elk.nodeLabels.placement`,lR=`org.eclipse.elk.portLabels.placement`,uR=`org.eclipse.elk.topdownLayout`,dR=`org.eclipse.elk.topdown.scaleFactor`,fR=`org.eclipse.elk.topdown.hierarchicalNodeWidth`,pR=`org.eclipse.elk.topdown.hierarchicalNodeAspectRatio`,mR=`org.eclipse.elk.topdown.nodeType`,sbt=`origin`,cbt=`random`,lbt=`boundingBox.upLeft`,ubt=`boundingBox.lowRight`,dbt=`org.eclipse.elk.stress.fixed`,fbt=`org.eclipse.elk.stress.desiredEdgeLength`,pbt=`org.eclipse.elk.stress.dimension`,mbt=`org.eclipse.elk.stress.epsilon`,hbt=`org.eclipse.elk.stress.iterationLimit`,hR=`org.eclipse.elk.stress`,gbt=`ELK Stress`,gR=`org.eclipse.elk.nodeSize.minimum`,_R=`org.eclipse.elk.alg.force.stress`,_bt=`Layered layout`,vR=`org.eclipse.elk.alg.layered`,yR=`org.eclipse.elk.alg.layered.compaction.components`,bR=`org.eclipse.elk.alg.layered.compaction.oned`,xR=`org.eclipse.elk.alg.layered.compaction.oned.algs`,SR=`org.eclipse.elk.alg.layered.compaction.recthull`,CR=`org.eclipse.elk.alg.layered.components`,wR=`NONE`,vbt=`MODEL_ORDER`,TR={3:1,6:1,4:1,9:1,5:1,126:1},ybt={3:1,6:1,4:1,5:1,150:1,100:1,115:1},ER=`org.eclipse.elk.alg.layered.compound`,DR={47:1},OR=`org.eclipse.elk.alg.layered.graph`,kR=` -> `,bbt=`Not supported by LGraph`,xbt=`Port side is undefined`,AR={3:1,6:1,4:1,5:1,483:1,150:1,100:1,115:1},jR={3:1,6:1,4:1,5:1,150:1,199:1,210:1,100:1,115:1},Sbt={3:1,6:1,4:1,5:1,150:1,2042:1,210:1,100:1,115:1},Cbt=`([{"' \r +`,wbt=`)]}"' \r +`,Tbt=`The given string contains parts that cannot be parsed as numbers.`,MR=`org.eclipse.elk.core.math`,Ebt={3:1,4:1,140:1,214:1,423:1},Dbt={3:1,4:1,107:1,214:1,423:1},NR=`org.eclipse.elk.alg.layered.graph.transform`,Obt=`ElkGraphImporter`,kbt=`ElkGraphImporter/lambda$1$Type`,Abt=`ElkGraphImporter/lambda$2$Type`,jbt=`ElkGraphImporter/lambda$4$Type`,PR=`org.eclipse.elk.alg.layered.intermediate`,Mbt=`Node margin calculation`,Nbt=`ONE_SIDED_GREEDY_SWITCH`,Pbt=`TWO_SIDED_GREEDY_SWITCH`,FR=`No implementation is available for the layout processor `,IR=`IntermediateProcessorStrategy`,LR=`Node '`,Fbt=`FIRST_SEPARATE`,Ibt=`LAST_SEPARATE`,Lbt=`Odd port side processing`,RR=`org.eclipse.elk.alg.layered.intermediate.compaction`,zR=`org.eclipse.elk.alg.layered.intermediate.greedyswitch`,BR=`org.eclipse.elk.alg.layered.p3order.counting`,VR={230:1},HR=`org.eclipse.elk.alg.layered.intermediate.loops`,UR=`org.eclipse.elk.alg.layered.intermediate.loops.ordering`,WR=`org.eclipse.elk.alg.layered.intermediate.loops.routing`,GR=`org.eclipse.elk.alg.layered.intermediate.preserveorder`,KR=`org.eclipse.elk.alg.layered.intermediate.wrapping`,qR=`org.eclipse.elk.alg.layered.options`,JR=`INTERACTIVE`,YR=`GREEDY`,Rbt=`DEPTH_FIRST`,zbt=`EDGE_LENGTH`,Bbt=`SELF_LOOPS`,Vbt=`firstTryWithInitialOrder`,XR=`org.eclipse.elk.layered.directionCongruency`,ZR=`org.eclipse.elk.layered.feedbackEdges`,QR=`org.eclipse.elk.layered.interactiveReferencePoint`,$R=`org.eclipse.elk.layered.mergeEdges`,ez=`org.eclipse.elk.layered.mergeHierarchyEdges`,tz=`org.eclipse.elk.layered.allowNonFlowPortsToSwitchSides`,nz=`org.eclipse.elk.layered.portSortingStrategy`,rz=`org.eclipse.elk.layered.thoroughness`,iz=`org.eclipse.elk.layered.unnecessaryBendpoints`,az=`org.eclipse.elk.layered.generatePositionAndLayerIds`,oz=`org.eclipse.elk.layered.cycleBreaking.strategy`,sz=`org.eclipse.elk.layered.layering.strategy`,cz=`org.eclipse.elk.layered.layering.layerConstraint`,lz=`org.eclipse.elk.layered.layering.layerChoiceConstraint`,uz=`org.eclipse.elk.layered.layering.layerId`,dz=`org.eclipse.elk.layered.layering.minWidth.upperBoundOnWidth`,fz=`org.eclipse.elk.layered.layering.minWidth.upperLayerEstimationScalingFactor`,pz=`org.eclipse.elk.layered.layering.nodePromotion.strategy`,mz=`org.eclipse.elk.layered.layering.nodePromotion.maxIterations`,hz=`org.eclipse.elk.layered.layering.coffmanGraham.layerBound`,gz=`org.eclipse.elk.layered.crossingMinimization.strategy`,_z=`org.eclipse.elk.layered.crossingMinimization.forceNodeModelOrder`,vz=`org.eclipse.elk.layered.crossingMinimization.hierarchicalSweepiness`,yz=`org.eclipse.elk.layered.crossingMinimization.semiInteractive`,bz=`org.eclipse.elk.layered.crossingMinimization.inLayerPredOf`,xz=`org.eclipse.elk.layered.crossingMinimization.inLayerSuccOf`,Sz=`org.eclipse.elk.layered.crossingMinimization.positionChoiceConstraint`,Cz=`org.eclipse.elk.layered.crossingMinimization.positionId`,wz=`org.eclipse.elk.layered.crossingMinimization.greedySwitch.activationThreshold`,Tz=`org.eclipse.elk.layered.crossingMinimization.greedySwitch.type`,Ez=`org.eclipse.elk.layered.crossingMinimization.greedySwitchHierarchical.type`,Dz=`org.eclipse.elk.layered.nodePlacement.strategy`,Oz=`org.eclipse.elk.layered.nodePlacement.favorStraightEdges`,kz=`org.eclipse.elk.layered.nodePlacement.bk.edgeStraightening`,Az=`org.eclipse.elk.layered.nodePlacement.bk.fixedAlignment`,jz=`org.eclipse.elk.layered.nodePlacement.linearSegments.deflectionDampening`,Mz=`org.eclipse.elk.layered.nodePlacement.networkSimplex.nodeFlexibility`,Nz=`org.eclipse.elk.layered.nodePlacement.networkSimplex.nodeFlexibility.default`,Pz=`org.eclipse.elk.layered.edgeRouting.selfLoopDistribution`,Fz=`org.eclipse.elk.layered.edgeRouting.selfLoopOrdering`,Iz=`org.eclipse.elk.layered.edgeRouting.splines.mode`,Lz=`org.eclipse.elk.layered.edgeRouting.splines.sloppy.layerSpacingFactor`,Rz=`org.eclipse.elk.layered.edgeRouting.polyline.slopedEdgeZoneWidth`,zz=`org.eclipse.elk.layered.spacing.baseValue`,Bz=`org.eclipse.elk.layered.spacing.edgeNodeBetweenLayers`,Vz=`org.eclipse.elk.layered.spacing.edgeEdgeBetweenLayers`,Hz=`org.eclipse.elk.layered.spacing.nodeNodeBetweenLayers`,Uz=`org.eclipse.elk.layered.priority.direction`,Wz=`org.eclipse.elk.layered.priority.shortness`,Gz=`org.eclipse.elk.layered.priority.straightness`,Kz=`org.eclipse.elk.layered.compaction.connectedComponents`,qz=`org.eclipse.elk.layered.compaction.postCompaction.strategy`,Jz=`org.eclipse.elk.layered.compaction.postCompaction.constraints`,Yz=`org.eclipse.elk.layered.highDegreeNodes.treatment`,Xz=`org.eclipse.elk.layered.highDegreeNodes.threshold`,Zz=`org.eclipse.elk.layered.highDegreeNodes.treeHeight`,Qz=`org.eclipse.elk.layered.wrapping.strategy`,$z=`org.eclipse.elk.layered.wrapping.additionalEdgeSpacing`,eB=`org.eclipse.elk.layered.wrapping.correctionFactor`,tB=`org.eclipse.elk.layered.wrapping.cutting.strategy`,nB=`org.eclipse.elk.layered.wrapping.cutting.cuts`,rB=`org.eclipse.elk.layered.wrapping.cutting.msd.freedom`,iB=`org.eclipse.elk.layered.wrapping.validify.strategy`,aB=`org.eclipse.elk.layered.wrapping.validify.forbiddenIndices`,oB=`org.eclipse.elk.layered.wrapping.multiEdge.improveCuts`,sB=`org.eclipse.elk.layered.wrapping.multiEdge.distancePenalty`,cB=`org.eclipse.elk.layered.wrapping.multiEdge.improveWrappedEdges`,lB=`org.eclipse.elk.layered.edgeLabels.sideSelection`,uB=`org.eclipse.elk.layered.edgeLabels.centerLabelPlacementStrategy`,dB=`org.eclipse.elk.layered.considerModelOrder.strategy`,fB=`org.eclipse.elk.layered.considerModelOrder.portModelOrder`,pB=`org.eclipse.elk.layered.considerModelOrder.noModelOrder`,mB=`org.eclipse.elk.layered.considerModelOrder.components`,hB=`org.eclipse.elk.layered.considerModelOrder.longEdgeStrategy`,gB=`org.eclipse.elk.layered.considerModelOrder.crossingCounterNodeInfluence`,_B=`org.eclipse.elk.layered.considerModelOrder.crossingCounterPortInfluence`,vB=`layering`,Hbt=`layering.minWidth`,Ubt=`layering.nodePromotion`,yB=`crossingMinimization`,bB=`org.eclipse.elk.hierarchyHandling`,Wbt=`crossingMinimization.greedySwitch`,Gbt=`nodePlacement`,Kbt=`nodePlacement.bk`,qbt=`edgeRouting`,xB=`org.eclipse.elk.edgeRouting`,SB=`spacing`,CB=`priority`,wB=`compaction`,Jbt=`compaction.postCompaction`,Ybt=`Specifies whether and how post-process compaction is applied.`,TB=`highDegreeNodes`,EB=`wrapping`,Xbt=`wrapping.cutting`,Zbt=`wrapping.validify`,DB=`wrapping.multiEdge`,OB=`edgeLabels`,kB=`considerModelOrder`,AB=`org.eclipse.elk.spacing.commentComment`,jB=`org.eclipse.elk.spacing.commentNode`,MB=`org.eclipse.elk.spacing.edgeEdge`,NB=`org.eclipse.elk.spacing.edgeNode`,PB=`org.eclipse.elk.spacing.labelLabel`,FB=`org.eclipse.elk.spacing.labelPortHorizontal`,IB=`org.eclipse.elk.spacing.labelPortVertical`,LB=`org.eclipse.elk.spacing.labelNode`,RB=`org.eclipse.elk.spacing.nodeSelfLoop`,zB=`org.eclipse.elk.spacing.portPort`,BB=`org.eclipse.elk.spacing.individual`,VB=`org.eclipse.elk.port.borderOffset`,HB=`org.eclipse.elk.noLayout`,UB=`org.eclipse.elk.port.side`,WB=`org.eclipse.elk.debugMode`,GB=`org.eclipse.elk.alignment`,KB=`org.eclipse.elk.insideSelfLoops.activate`,qB=`org.eclipse.elk.insideSelfLoops.yo`,JB=`org.eclipse.elk.direction`,YB=`org.eclipse.elk.nodeLabels.padding`,XB=`org.eclipse.elk.portLabels.nextToPortIfPossible`,ZB=`org.eclipse.elk.portLabels.treatAsGroup`,QB=`org.eclipse.elk.portAlignment.default`,$B=`org.eclipse.elk.portAlignment.north`,eV=`org.eclipse.elk.portAlignment.south`,tV=`org.eclipse.elk.portAlignment.west`,nV=`org.eclipse.elk.portAlignment.east`,rV=`org.eclipse.elk.contentAlignment`,iV=`org.eclipse.elk.junctionPoints`,aV=`org.eclipse.elk.edgeLabels.placement`,oV=`org.eclipse.elk.port.index`,sV=`org.eclipse.elk.commentBox`,cV=`org.eclipse.elk.hypernode`,lV=`org.eclipse.elk.port.anchor`,uV=`org.eclipse.elk.partitioning.activate`,dV=`org.eclipse.elk.partitioning.partition`,fV=`org.eclipse.elk.position`,pV=`org.eclipse.elk.margins`,mV=`org.eclipse.elk.spacing.portsSurrounding`,hV=`org.eclipse.elk.interactiveLayout`,gV=`org.eclipse.elk.core.util`,_V={3:1,4:1,5:1,601:1},Qbt=`NETWORK_SIMPLEX`,vV=`SIMPLE`,yV={106:1,47:1},bV=`org.eclipse.elk.alg.layered.p1cycles`,xV=`org.eclipse.elk.alg.layered.p2layers`,SV={413:1,230:1},$bt={846:1,3:1,4:1},CV=`org.eclipse.elk.alg.layered.p3order`,wV=`org.eclipse.elk.alg.layered.p4nodes`,ext={3:1,4:1,5:1,854:1},TV=1e-5,EV=`org.eclipse.elk.alg.layered.p4nodes.bk`,DV=`org.eclipse.elk.alg.layered.p5edges`,OV=`org.eclipse.elk.alg.layered.p5edges.orthogonal`,kV=`org.eclipse.elk.alg.layered.p5edges.orthogonal.direction`,AV=1e-6,jV=`org.eclipse.elk.alg.layered.p5edges.splines`,MV=.09999999999999998,NV=1e-8,txt=4.71238898038469,PV=3.141592653589793,FV=`org.eclipse.elk.alg.mrtree`,IV=.10000000149011612,LV=`SUPER_ROOT`,RV=`org.eclipse.elk.alg.mrtree.graph`,zV=-17976931348623157e292,BV=`org.eclipse.elk.alg.mrtree.intermediate`,nxt=`Processor compute fanout`,VV={3:1,6:1,4:1,5:1,534:1,100:1,115:1},rxt=`Set neighbors in level`,HV=`org.eclipse.elk.alg.mrtree.options`,ixt=`DESCENDANTS`,UV=`org.eclipse.elk.mrtree.compaction`,WV=`org.eclipse.elk.mrtree.edgeEndTextureLength`,axt=`org.eclipse.elk.mrtree.treeLevel`,oxt=`org.eclipse.elk.mrtree.positionConstraint`,sxt=`org.eclipse.elk.mrtree.weighting`,cxt=`org.eclipse.elk.mrtree.edgeRoutingMode`,lxt=`org.eclipse.elk.mrtree.searchOrder`,uxt=`Position Constraint`,GV=`org.eclipse.elk.mrtree`,dxt=`org.eclipse.elk.tree`,fxt=`Processor arrange level`,KV=`org.eclipse.elk.alg.mrtree.p2order`,qV=`org.eclipse.elk.alg.mrtree.p4route`,pxt=`org.eclipse.elk.alg.radial`,JV=6.283185307179586,mxt=`Before`,hxt=5e-324,YV=`After`,gxt=`org.eclipse.elk.alg.radial.intermediate`,_xt=`COMPACTION`,XV=`org.eclipse.elk.alg.radial.intermediate.compaction`,vxt={3:1,4:1,5:1,100:1},yxt=`org.eclipse.elk.alg.radial.intermediate.optimization`,ZV=`No implementation is available for the layout option `,QV=`org.eclipse.elk.alg.radial.options`,bxt=`org.eclipse.elk.radial.centerOnRoot`,xxt=`org.eclipse.elk.radial.orderId`,Sxt=`org.eclipse.elk.radial.radius`,$V=`org.eclipse.elk.radial.rotate`,eH=`org.eclipse.elk.radial.compactor`,tH=`org.eclipse.elk.radial.compactionStepSize`,Cxt=`org.eclipse.elk.radial.sorter`,wxt=`org.eclipse.elk.radial.wedgeCriteria`,Txt=`org.eclipse.elk.radial.optimizationCriteria`,nH=`org.eclipse.elk.radial.rotation.targetAngle`,rH=`org.eclipse.elk.radial.rotation.computeAdditionalWedgeSpace`,Ext=`org.eclipse.elk.radial.rotation.outgoingEdgeAngles`,Dxt=`Compaction`,Oxt=`rotation`,iH=`org.eclipse.elk.radial`,kxt=`org.eclipse.elk.alg.radial.p1position.wedge`,Axt=`org.eclipse.elk.alg.radial.sorting`,jxt=5.497787143782138,Mxt=3.9269908169872414,Nxt=2.356194490192345,Pxt=`org.eclipse.elk.alg.rectpacking`,aH=`org.eclipse.elk.alg.rectpacking.intermediate`,oH=`org.eclipse.elk.alg.rectpacking.options`,Fxt=`org.eclipse.elk.rectpacking.trybox`,Ixt=`org.eclipse.elk.rectpacking.currentPosition`,Lxt=`org.eclipse.elk.rectpacking.desiredPosition`,Rxt=`org.eclipse.elk.rectpacking.inNewRow`,zxt=`org.eclipse.elk.rectpacking.widthApproximation.strategy`,Bxt=`org.eclipse.elk.rectpacking.widthApproximation.targetWidth`,Vxt=`org.eclipse.elk.rectpacking.widthApproximation.optimizationGoal`,Hxt=`org.eclipse.elk.rectpacking.widthApproximation.lastPlaceShift`,Uxt=`org.eclipse.elk.rectpacking.packing.strategy`,Wxt=`org.eclipse.elk.rectpacking.packing.compaction.rowHeightReevaluation`,Gxt=`org.eclipse.elk.rectpacking.packing.compaction.iterations`,Kxt=`org.eclipse.elk.rectpacking.whiteSpaceElimination.strategy`,sH=`widthApproximation`,qxt=`Compaction Strategy`,Jxt=`packing.compaction`,cH=`org.eclipse.elk.rectpacking`,lH=`org.eclipse.elk.alg.rectpacking.p1widthapproximation`,uH=`org.eclipse.elk.alg.rectpacking.p2packing`,Yxt=`No Compaction`,Xxt=`org.eclipse.elk.alg.rectpacking.p3whitespaceelimination`,dH=`org.eclipse.elk.alg.rectpacking.util`,fH=`No implementation available for `,pH=`org.eclipse.elk.alg.spore`,mH=`org.eclipse.elk.alg.spore.options`,hH=`org.eclipse.elk.sporeCompaction`,gH=`org.eclipse.elk.underlyingLayoutAlgorithm`,Zxt=`org.eclipse.elk.processingOrder.treeConstruction`,Qxt=`org.eclipse.elk.processingOrder.spanningTreeCostFunction`,_H=`org.eclipse.elk.processingOrder.preferredRoot`,vH=`org.eclipse.elk.processingOrder.rootSelection`,yH=`org.eclipse.elk.structure.structureExtractionStrategy`,$xt=`org.eclipse.elk.compaction.compactionStrategy`,eSt=`org.eclipse.elk.compaction.orthogonal`,tSt=`org.eclipse.elk.overlapRemoval.maxIterations`,nSt=`org.eclipse.elk.overlapRemoval.runScanline`,bH=`processingOrder`,rSt=`overlapRemoval`,xH=`org.eclipse.elk.sporeOverlap`,iSt=`org.eclipse.elk.alg.spore.p1structure`,SH=`org.eclipse.elk.alg.spore.p2processingorder`,CH=`org.eclipse.elk.alg.spore.p3execution`,aSt=`Topdown Layout`,oSt=`Invalid index: `,wH=`org.eclipse.elk.core.alg`,TH={341:1},EH={295:1},sSt=`Make sure its type is registered with the `,cSt=` utility class.`,DH=`true`,OH=`false`,lSt=`Couldn't clone property '`,kH=.05,AH=`org.eclipse.elk.core.options`,uSt=1.2999999523162842,jH=`org.eclipse.elk.box`,dSt=`org.eclipse.elk.expandNodes`,fSt=`org.eclipse.elk.box.packingMode`,pSt=`org.eclipse.elk.algorithm`,mSt=`org.eclipse.elk.resolvedAlgorithm`,hSt=`org.eclipse.elk.bendPoints`,gSt=`org.eclipse.elk.labelManager`,_St=`org.eclipse.elk.scaleFactor`,vSt=`org.eclipse.elk.childAreaWidth`,ySt=`org.eclipse.elk.childAreaHeight`,bSt=`org.eclipse.elk.animate`,xSt=`org.eclipse.elk.animTimeFactor`,SSt=`org.eclipse.elk.layoutAncestors`,CSt=`org.eclipse.elk.maxAnimTime`,wSt=`org.eclipse.elk.minAnimTime`,TSt=`org.eclipse.elk.progressBar`,ESt=`org.eclipse.elk.validateGraph`,DSt=`org.eclipse.elk.validateOptions`,OSt=`org.eclipse.elk.zoomToFit`,kSt=`org.eclipse.elk.font.name`,ASt=`org.eclipse.elk.font.size`,jSt=`org.eclipse.elk.topdown.sizeApproximator`,MSt=`org.eclipse.elk.topdown.scaleCap`,NSt=`org.eclipse.elk.edge.type`,PSt=`partitioning`,FSt=`nodeLabels`,MH=`portAlignment`,NH=`nodeSize`,PH=`port`,ISt=`portLabels`,FH=`topdown`,LSt=`insideSelfLoops`,IH=`org.eclipse.elk.fixed`,LH=`org.eclipse.elk.random`,RSt={3:1,34:1,22:1,347:1},zSt=`port must have a parent node to calculate the port side`,BSt=`The edge needs to have exactly one edge section. Found: `,RH=`org.eclipse.elk.core.util.adapters`,zH=`org.eclipse.emf.ecore`,BH=`org.eclipse.elk.graph`,VSt=`EMapPropertyHolder`,HSt=`ElkBendPoint`,USt=`ElkGraphElement`,WSt=`ElkConnectableShape`,GSt=`ElkEdge`,KSt=`ElkEdgeSection`,qSt=`EModelElement`,JSt=`ENamedElement`,YSt=`ElkLabel`,XSt=`ElkNode`,ZSt=`ElkPort`,QSt={94:1,93:1},VH=`org.eclipse.emf.common.notify.impl`,HH=`The feature '`,UH=`' is not a valid changeable feature`,$St=`Expecting null`,WH=`' is not a valid feature`,eCt=`The feature ID`,tCt=` is not a valid feature ID`,GH=32768,nCt={110:1,94:1,93:1,58:1,54:1,99:1},KH=`org.eclipse.emf.ecore.impl`,qH=`org.eclipse.elk.graph.impl`,JH=`Recursive containment not allowed for `,YH=`The datatype '`,XH=`' is not a valid classifier`,ZH=`The value '`,QH={195:1,3:1,4:1},$H=`The class '`,eU=`http://www.eclipse.org/elk/ElkGraph`,rCt=`property`,tU=`value`,nU=`source`,iCt=`properties`,aCt=`identifier`,rU=`height`,iU=`width`,aU=`parent`,oU=`text`,sU=`children`,oCt=`hierarchical`,sCt=`sources`,cU=`targets`,cCt=`sections`,lU=`bendPoints`,lCt=`outgoingShape`,uCt=`incomingShape`,dCt=`outgoingSections`,fCt=`incomingSections`,uU=`org.eclipse.emf.common.util`,pCt=`Severe implementation error in the Json to ElkGraph importer.`,dU=`id`,fU=`org.eclipse.elk.graph.json`,mCt=`Unhandled parameter types: `,hCt=`startPoint`,gCt=`An edge must have at least one source and one target (edge id: '`,pU=`').`,_Ct=`Referenced edge section does not exist: `,vCt=` (edge id: '`,yCt=`target`,bCt=`sourcePoint`,xCt=`targetPoint`,mU=`group`,hU=`name`,SCt=`connectableShape cannot be null`,CCt=`edge cannot be null`,gU=`Passed edge is not 'simple'.`,_U=`org.eclipse.elk.graph.util`,vU=`The 'no duplicates' constraint is violated`,yU=`targetIndex=`,bU=`, size=`,xU=`sourceIndex=`,SU={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1},CU={3:1,4:1,20:1,31:1,56:1,16:1,51:1,15:1,59:1,70:1,66:1,61:1,596:1},wU=`logging`,wCt=`measureExecutionTime`,TCt=`parser.parse.1`,ECt=`parser.parse.2`,TU=`parser.next.1`,EU=`parser.next.2`,DCt=`parser.next.3`,OCt=`parser.next.4`,DU=`parser.factor.1`,kCt=`parser.factor.2`,ACt=`parser.factor.3`,jCt=`parser.factor.4`,MCt=`parser.factor.5`,NCt=`parser.factor.6`,PCt=`parser.atom.1`,FCt=`parser.atom.2`,ICt=`parser.atom.3`,LCt=`parser.atom.4`,OU=`parser.atom.5`,RCt=`parser.cc.1`,kU=`parser.cc.2`,zCt=`parser.cc.3`,BCt=`parser.cc.5`,VCt=`parser.cc.6`,HCt=`parser.cc.7`,AU=`parser.cc.8`,UCt=`parser.ope.1`,WCt=`parser.ope.2`,GCt=`parser.ope.3`,jU=`parser.descape.1`,KCt=`parser.descape.2`,qCt=`parser.descape.3`,JCt=`parser.descape.4`,YCt=`parser.descape.5`,MU=`parser.process.1`,XCt=`parser.quantifier.1`,ZCt=`parser.quantifier.2`,QCt=`parser.quantifier.3`,$Ct=`parser.quantifier.4`,ewt=`parser.quantifier.5`,twt=`org.eclipse.emf.common.notify`,nwt={424:1,686:1},rwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,70:1,61:1},NU={378:1,152:1},PU=`index=`,FU={3:1,4:1,5:1,129:1},iwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,61:1},awt={3:1,6:1,4:1,5:1,198:1},owt={3:1,4:1,5:1,173:1,379:1},swt=`;/?:@&=+$,`,cwt=`invalid authority: `,lwt=`EAnnotation`,uwt=`ETypedElement`,dwt=`EStructuralFeature`,fwt=`EAttribute`,pwt=`EClassifier`,mwt=`EEnumLiteral`,hwt=`EGenericType`,gwt=`EOperation`,_wt=`EParameter`,vwt=`EReference`,ywt=`ETypeParameter`,IU=`org.eclipse.emf.ecore.util`,LU={79:1},bwt={3:1,20:1,16:1,15:1,61:1,597:1,79:1,71:1,97:1},xwt=`org.eclipse.emf.ecore.util.FeatureMap$Entry`,RU=8192,zU=2048,BU=`byte`,VU=`char`,HU=`double`,UU=`float`,WU=`int`,GU=`long`,KU=`short`,Swt=`java.lang.Object`,qU={3:1,4:1,5:1,254:1},Cwt={3:1,4:1,5:1,688:1},wwt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,71:1},JU={3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,79:1,71:1,97:1},YU=`mixed`,XU=`http:///org/eclipse/emf/ecore/util/ExtendedMetaData`,ZU=`kind`,Twt={3:1,4:1,5:1,689:1},Ewt={3:1,4:1,20:1,31:1,56:1,16:1,15:1,70:1,61:1,79:1,71:1,97:1},QU={20:1,31:1,56:1,16:1,15:1,61:1,71:1},$U={51:1,128:1,287:1},eW={76:1,343:1},tW=`The value of type '`,nW=`' must be of type '`,rW=1352,iW=`http://www.eclipse.org/emf/2002/Ecore`,aW=-32768,oW=`constraints`,sW=`baseType`,Dwt=`getEStructuralFeature`,Owt=`getFeatureID`,cW=`feature`,kwt=`getOperationID`,Awt=`operation`,jwt=`defaultValue`,Mwt=`eTypeParameters`,Nwt=`isInstance`,Pwt=`getEEnumLiteral`,Fwt=`eContainingClass`,lW={57:1},Iwt={3:1,4:1,5:1,124:1},Lwt=`org.eclipse.emf.ecore.resource`,Rwt={94:1,93:1,599:1,2034:1},uW=`org.eclipse.emf.ecore.resource.impl`,zwt=`unspecified`,dW=`simple`,fW=`attribute`,Bwt=`attributeWildcard`,pW=`element`,mW=`elementWildcard`,hW=`collapse`,gW=`itemType`,_W=`namespace`,vW=`##targetNamespace`,yW=`whiteSpace`,Vwt=`wildcards`,bW=`http://www.eclipse.org/emf/2003/XMLType`,xW=`##any`,SW=`uninitialized`,CW=`The multiplicity constraint is violated`,wW=`org.eclipse.emf.ecore.xml.type`,Hwt=`ProcessingInstruction`,Uwt=`SimpleAnyType`,Wwt=`XMLTypeDocumentRoot`,TW=`org.eclipse.emf.ecore.xml.type.impl`,EW=`INF`,Gwt=`processing`,Kwt=`ENTITIES_._base`,qwt=`minLength`,Jwt=`ENTITY`,DW=`NCName`,Ywt=`IDREFS_._base`,Xwt=`integer`,OW=`token`,kW=`pattern`,Zwt=`[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*`,Qwt=`\\i\\c*`,$wt=`[\\i-[:]][\\c-[:]]*`,eTt=`nonPositiveInteger`,AW=`maxInclusive`,tTt=`NMTOKEN`,nTt=`NMTOKENS_._base`,rTt=`nonNegativeInteger`,jW=`minInclusive`,iTt=`normalizedString`,aTt=`unsignedByte`,oTt=`unsignedInt`,sTt=`18446744073709551615`,cTt=`unsignedShort`,lTt=`processingInstruction`,MW=`org.eclipse.emf.ecore.xml.type.internal`,NW=1114111,uTt=`Internal Error: shorthands: \\u`,PW=`xml:isDigit`,FW=`xml:isWord`,IW=`xml:isSpace`,LW=`xml:isNameChar`,RW=`xml:isInitialNameChar`,dTt=`09٠٩۰۹०९০৯੦੯૦૯୦୯௧௯౦౯೦೯൦൯๐๙໐໙༠༩`,fTt=`AZazÀÖØöøıĴľŁňŊžƀǃǍǰǴǵǺȗɐʨʻˁΆΆΈΊΌΌΎΡΣώϐϖϚϚϜϜϞϞϠϠϢϳЁЌЎяёќўҁҐӄӇӈӋӌӐӫӮӵӸӹԱՖՙՙաֆאתװײءغفيٱڷںھۀێېۓەەۥۦअहऽऽक़ॡঅঌএঐওনপরললশহড়ঢ়য়ৡৰৱਅਊਏਐਓਨਪਰਲਲ਼ਵਸ਼ਸਹਖ਼ੜਫ਼ਫ਼ੲੴઅઋઍઍએઑઓનપરલળવહઽઽૠૠଅଌଏଐଓନପରଲଳଶହଽଽଡ଼ଢ଼ୟୡஅஊஎஐஒகஙசஜஜஞடணதநபமவஷஹఅఌఎఐఒనపళవహౠౡಅಌಎಐಒನಪಳವಹೞೞೠೡഅഌഎഐഒനപഹൠൡกฮะะาำเๅກຂຄຄງຈຊຊຍຍດທນຟມຣລລວວສຫອຮະະາຳຽຽເໄཀཇཉཀྵႠჅაჶᄀᄀᄂᄃᄅᄇᄉᄉᄋᄌᄎᄒᄼᄼᄾᄾᅀᅀᅌᅌᅎᅎᅐᅐᅔᅕᅙᅙᅟᅡᅣᅣᅥᅥᅧᅧᅩᅩᅭᅮᅲᅳᅵᅵᆞᆞᆨᆨᆫᆫᆮᆯᆷᆸᆺᆺᆼᇂᇫᇫᇰᇰᇹᇹḀẛẠỹἀἕἘἝἠὅὈὍὐὗὙὙὛὛὝὝὟώᾀᾴᾶᾼιιῂῄῆῌῐΐῖΊῠῬῲῴῶῼΩΩKÅ℮℮ↀↂ〇〇〡〩ぁゔァヺㄅㄬ一龥가힣`,pTt=`Private Use`,zW=`ASSIGNED`,BW=`\0€ÿĀſƀɏɐʯʰ˿̀ͯͰϿЀӿ԰֏֐׿؀ۿ܀ݏހ޿ऀॿঀ৿਀੿઀૿଀୿஀௿ఀ౿ಀ೿ഀൿ඀෿฀๿຀໿ༀ࿿က႟Ⴀჿᄀᇿሀ፿Ꭰ᏿᐀ᙿ ᚟ᚠ᛿ក៿᠀᢯Ḁỿἀ῿ ⁰₟₠⃏⃐⃿℀⅏⅐↏←⇿∀⋿⌀⏿␀␿⑀⑟①⓿─╿▀▟■◿☀⛿✀➿⠀⣿⺀⻿⼀⿟⿰⿿ 〿぀ゟ゠ヿ㄀ㄯ㄰㆏㆐㆟ㆠㆿ㈀㋿㌀㏿㐀䶵一鿿ꀀ꒏꒐꓏가힣豈﫿ffﭏﭐ﷿︠︯︰﹏﹐﹯ﹰ﻾＀￯`,mTt=`UNASSIGNED`,VW={3:1,122:1},hTt=`org.eclipse.emf.ecore.xml.type.util`,HW={3:1,4:1,5:1,381:1},gTt=`org.eclipse.xtext.xbase.lib`,_Tt=`Cannot add elements to a Range`,vTt=`Cannot set elements in a Range`,yTt=`Cannot remove elements from a Range`,bTt=`user.agent`,Q,UW,xTt,STt=-1;r.goog=r.goog||{},r.goog.global=r.goog.global||r,UW={},q(1,null,{},a),Q.Fb=function(e){return vCe(this,e)},Q.Gb=function(){return this.Rm},Q.Hb=function(){return td(this)},Q.Ib=function(){var e;return Ha($w(this))+`@`+(e=US(this)>>>0,e.toString(16))},Q.equals=function(e){return this.Fb(e)},Q.hashCode=function(){return this.Hb()},Q.toString=function(){return this.Ib()};var CTt,wTt,TTt;q(297,1,{297:1,2124:1},vZe),Q.ve=function(e){var t=new vZe;return t.i=4,t.c=e>1?_Re(this,e-1):this,t},Q.we=function(){return Ad(this),this.b},Q.xe=function(){return Ha(this)},Q.ye=function(){return Ad(this),this.k},Q.ze=function(){return!!(this.i&4)},Q.Ae=function(){return!!(this.i&1)},Q.Ib=function(){return yx(this)},Q.i=0;var ETt=1,WW=L(jP,`Object`,1),DTt=L(jP,`Class`,297);q(2096,1,MP),L(NP,`Optional`,2096),q(1191,2096,MP,o),Q.Fb=function(e){return e===this},Q.Hb=function(){return 2040732332},Q.Ib=function(){return`Optional.absent()`},Q.Jb=function(e){return ph(e),fi(),GW};var GW;L(NP,`Absent`,1191),q(636,1,{},Xi),L(NP,`Joiner`,636);var OTt=gp(NP,`Predicate`);q(589,1,{178:1,589:1,3:1,46:1},nde),Q.Mb=function(e){return NZe(this,e)},Q.Lb=function(e){return NZe(this,e)},Q.Fb=function(e){var t;return j(e,589)?(t=P(e,589),lit(this.a,t.a)):!1},Q.Hb=function(){return IZe(this.a)+306654252},Q.Ib=function(){return wet(this.a)},L(NP,`Predicates/AndPredicate`,589),q(419,2096,{419:1,3:1},pn),Q.Fb=function(e){var t;return j(e,419)?(t=P(e,419),NT(this.a,t.a)):!1},Q.Hb=function(){return 1502476572+US(this.a)},Q.Ib=function(){return Gvt+this.a+`)`},Q.Jb=function(e){return new pn(Wg(e.Kb(this.a),`the Function passed to Optional.transform() must not return null.`))},L(NP,`Present`,419),q(204,1,LP),Q.Nb=function(e){Om(this,e)},Q.Qb=function(){fve()},L(RP,`UnmodifiableIterator`,204),q(2076,204,zP),Q.Qb=function(){fve()},Q.Rb=function(e){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(RP,`UnmodifiableListIterator`,2076),q(399,2076,zP),Q.Ob=function(){return this.c0},Q.Pb=function(){if(this.c>=this.d)throw E(new Hr);return this.Xb(this.c++)},Q.Tb=function(){return this.c},Q.Ub=function(){if(this.c<=0)throw E(new Hr);return this.Xb(--this.c)},Q.Vb=function(){return this.c-1},Q.c=0,Q.d=0,L(RP,`AbstractIndexedListIterator`,399),q(713,204,LP),Q.Ob=function(){return DS(this)},Q.Pb=function(){return Ob(this)},Q.e=1,L(RP,`AbstractIterator`,713),q(2084,1,{229:1}),Q.Zb=function(){var e;return e=this.f,e||(this.f=this.ac())},Q.Fb=function(e){return Rw(this,e)},Q.Hb=function(){return US(this.Zb())},Q.dc=function(){return this.gc()==0},Q.ec=function(){return rm(this)},Q.Ib=function(){return PE(this.Zb())},L(RP,`AbstractMultimap`,2084),q(742,2084,BP),Q.$b=function(){gS(this)},Q._b=function(e){return aye(this,e)},Q.ac=function(){return new io(this,this.c)},Q.ic=function(e){return this.hc()},Q.bc=function(){return new zu(this,this.c)},Q.jc=function(){return this.mc(this.hc())},Q.kc=function(){return new j_e(this)},Q.lc=function(){return pA(this.c.vc().Nc(),new c,64,this.d)},Q.cc=function(e){return Dy(this,e)},Q.fc=function(e){return sT(this,e)},Q.gc=function(){return this.d},Q.mc=function(e){return Vg(),new Wn(e)},Q.nc=function(){return new A_e(this)},Q.oc=function(){return pA(this.c.Cc().Nc(),new s,64,this.d)},Q.pc=function(e,t){return new Ry(this,e,t,null)},Q.d=0,L(RP,`AbstractMapBasedMultimap`,742),q(1696,742,BP),Q.hc=function(){return new Hy(this.a)},Q.jc=function(){return Vg(),Vg(),QG},Q.cc=function(e){return P(Dy(this,e),15)},Q.fc=function(e){return P(sT(this,e),15)},Q.Zb=function(){return Rg(this)},Q.Fb=function(e){return Rw(this,e)},Q.qc=function(e){return P(Dy(this,e),15)},Q.rc=function(e){return P(sT(this,e),15)},Q.mc=function(e){return Zg(P(e,15))},Q.pc=function(e,t){return nVe(this,e,P(t,15),null)},L(RP,`AbstractListMultimap`,1696),q(748,1,VP),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.c.Ob()||this.e.Ob()},Q.Pb=function(){var e;return this.e.Ob()||(e=P(this.c.Pb(),44),this.b=e.ld(),this.a=P(e.md(),16),this.e=this.a.Kc()),this.sc(this.b,this.e.Pb())},Q.Qb=function(){this.e.Qb(),P(Wh(this.a),16).dc()&&this.c.Qb(),--this.d.d},L(RP,`AbstractMapBasedMultimap/Itr`,748),q(1129,748,VP,A_e),Q.sc=function(e,t){return t},L(RP,`AbstractMapBasedMultimap/1`,1129),q(1130,1,{},s),Q.Kb=function(e){return P(e,16).Nc()},L(RP,`AbstractMapBasedMultimap/1methodref$spliterator$Type`,1130),q(1131,748,VP,j_e),Q.sc=function(e,t){return new oo(e,t)},L(RP,`AbstractMapBasedMultimap/2`,1131);var kTt=gp(HP,`Map`);q(2065,1,UP),Q.wc=function(e){xC(this,e)},Q.yc=function(e,t,n){return AE(this,e,t,n)},Q.$b=function(){this.vc().$b()},Q.tc=function(e){return lk(this,e)},Q._b=function(e){return!!O5e(this,e,!1)},Q.uc=function(e){var t,n,r;for(n=this.vc().Kc();n.Ob();)if(t=P(n.Pb(),44),r=t.md(),A(e)===A(r)||e!=null&&NT(e,r))return!0;return!1},Q.Fb=function(e){var t,n,r;if(e===this)return!0;if(!j(e,85)||(r=P(e,85),this.gc()!=r.gc()))return!1;for(n=r.vc().Kc();n.Ob();)if(t=P(n.Pb(),44),!this.tc(t))return!1;return!0},Q.xc=function(e){return nl(O5e(this,e,!1))},Q.Hb=function(){return QXe(this.vc())},Q.dc=function(){return this.gc()==0},Q.ec=function(){return new Pn(this)},Q.zc=function(e,t){throw E(new Ri(`Put not supported on this map`))},Q.Ac=function(e){mC(this,e)},Q.Bc=function(e){return nl(O5e(this,e,!0))},Q.gc=function(){return this.vc().gc()},Q.Ib=function(){return V5e(this)},Q.Cc=function(){return new Bn(this)},L(HP,`AbstractMap`,2065),q(2085,2065,UP),Q.bc=function(){return new co(this)},Q.vc=function(){return PNe(this)},Q.ec=function(){return this.g||=this.bc()},Q.Cc=function(){return this.i||=new sbe(this)},L(RP,`Maps/ViewCachingAbstractMap`,2085),q(402,2085,UP,io),Q.xc=function(e){return QKe(this,e)},Q.Bc=function(e){return CQe(this,e)},Q.$b=function(){this.d==this.e.c?this.e.$b():Cp(new Tp(this))},Q._b=function(e){return E$e(this.d,e)},Q.Ec=function(){return new rde(this)},Q.Dc=function(){return this.Ec()},Q.Fb=function(e){return this===e||NT(this.d,e)},Q.Hb=function(){return US(this.d)},Q.ec=function(){return this.e.ec()},Q.gc=function(){return this.d.gc()},Q.Ib=function(){return PE(this.d)},L(RP,`AbstractMapBasedMultimap/AsMap`,402);var KW=gp(jP,`Iterable`);q(31,1,WP),Q.Jc=function(e){ly(this,e)},Q.Lc=function(){return this.Oc()},Q.Nc=function(){return new cv(this,0)},Q.Oc=function(){return new Mp(null,this.Nc())},Q.Fc=function(e){throw E(new Ri(`Add not supported on this collection`))},Q.Gc=function(e){return XS(this,e)},Q.$b=function(){yg(this)},Q.Hc=function(e){return QE(this,e,!1)},Q.Ic=function(e){return $C(this,e)},Q.dc=function(){return this.gc()==0},Q.Mc=function(e){return QE(this,e,!0)},Q.Pc=function(){return INe(this)},Q.Qc=function(e){return ck(this,e)},Q.Ib=function(){return CA(this)},L(HP,`AbstractCollection`,31);var qW=gp(HP,`Set`);q(GP,31,KP),Q.Nc=function(){return new cv(this,1)},Q.Fb=function(e){return $0e(this,e)},Q.Hb=function(){return QXe(this)},L(HP,`AbstractSet`,GP),q(2068,GP,KP),L(RP,`Sets/ImprovedAbstractSet`,2068),q(2069,2068,KP),Q.$b=function(){this.Rc().$b()},Q.Hc=function(e){return x0e(this,e)},Q.dc=function(){return this.Rc().dc()},Q.Mc=function(e){var t;return this.Hc(e)&&j(e,44)?(t=P(e,44),this.Rc().ec().Mc(t.ld())):!1},Q.gc=function(){return this.Rc().gc()},L(RP,`Maps/EntrySet`,2069),q(1127,2069,KP,rde),Q.Hc=function(e){return wT(this.a.d.vc(),e)},Q.Kc=function(){return new Tp(this.a)},Q.Rc=function(){return this.a},Q.Mc=function(e){var t;return wT(this.a.d.vc(),e)?(t=P(Wh(P(e,44)),44),AUe(this.a.e,t.ld()),!0):!1},Q.Nc=function(){return qf(this.a.d.vc().Nc(),new ide(this.a))},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapEntries`,1127),q(1128,1,{},ide),Q.Kb=function(e){return SUe(this.a,P(e,44))},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapEntries/0methodref$wrapEntry$Type`,1128),q(746,1,VP,Tp),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){var e;return e=P(this.b.Pb(),44),this.a=P(e.md(),16),SUe(this.c,e)},Q.Ob=function(){return this.b.Ob()},Q.Qb=function(){Ef(!!this.a),this.b.Qb(),this.c.e.d-=this.a.gc(),this.a.$b(),this.a=null},L(RP,`AbstractMapBasedMultimap/AsMap/AsMapIterator`,746),q(542,2068,KP,co),Q.$b=function(){this.b.$b()},Q.Hc=function(e){return this.b._b(e)},Q.Jc=function(e){ph(e),this.b.wc(new xde(e))},Q.dc=function(){return this.b.dc()},Q.Kc=function(){return new hi(this.b.vc().Kc())},Q.Mc=function(e){return this.b._b(e)?(this.b.Bc(e),!0):!1},Q.gc=function(){return this.b.gc()},L(RP,`Maps/KeySet`,542),q(327,542,KP,zu),Q.$b=function(){var e;Cp((e=this.b.vc().Kc(),new Jye(this,e)))},Q.Ic=function(e){return this.b.ec().Ic(e)},Q.Fb=function(e){return this===e||NT(this.b.ec(),e)},Q.Hb=function(){return US(this.b.ec())},Q.Kc=function(){var e;return e=this.b.vc().Kc(),new Jye(this,e)},Q.Mc=function(e){var t,n=0;return t=P(this.b.Bc(e),16),t&&(n=t.gc(),t.$b(),this.a.d-=n),n>0},Q.Nc=function(){return this.b.ec().Nc()},L(RP,`AbstractMapBasedMultimap/KeySet`,327),q(747,1,VP,Jye),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.c.Ob()},Q.Pb=function(){return this.a=P(this.c.Pb(),44),this.a.ld()},Q.Qb=function(){var e;Ef(!!this.a),e=P(this.a.md(),16),this.c.Qb(),this.b.a.d-=e.gc(),e.$b(),this.a=null},L(RP,`AbstractMapBasedMultimap/KeySet/1`,747),q(503,402,{85:1,133:1},Fd),Q.bc=function(){return this.Sc()},Q.ec=function(){return this.Uc()},Q.Sc=function(){return new no(this.c,this.Wc())},Q.Tc=function(){return this.Wc().Tc()},Q.Uc=function(){var e;return e=this.b,e||(this.b=this.Sc())},Q.Vc=function(){return this.Wc().Vc()},Q.Wc=function(){return P(this.d,133)},L(RP,`AbstractMapBasedMultimap/SortedAsMap`,503),q(446,503,qP,Id),Q.bc=function(){return new ro(this.a,P(P(this.d,133),139))},Q.Sc=function(){return new ro(this.a,P(P(this.d,133),139))},Q.ec=function(){var e;return e=this.b,P(e||(this.b=new ro(this.a,P(P(this.d,133),139))),277)},Q.Uc=function(){var e;return e=this.b,P(e||(this.b=new ro(this.a,P(P(this.d,133),139))),277)},Q.Wc=function(){return P(P(this.d,133),139)},Q.Xc=function(e){return P(P(this.d,133),139).Xc(e)},Q.Yc=function(e){return P(P(this.d,133),139).Yc(e)},Q.Zc=function(e,t){return new Id(this.a,P(P(this.d,133),139).Zc(e,t))},Q.$c=function(e){return P(P(this.d,133),139).$c(e)},Q._c=function(e){return P(P(this.d,133),139)._c(e)},Q.ad=function(e,t){return new Id(this.a,P(P(this.d,133),139).ad(e,t))},L(RP,`AbstractMapBasedMultimap/NavigableAsMap`,446),q(502,327,Kvt,no),Q.Nc=function(){return this.b.ec().Nc()},L(RP,`AbstractMapBasedMultimap/SortedKeySet`,502),q(401,502,JP,ro),L(RP,`AbstractMapBasedMultimap/NavigableKeySet`,401),q(551,31,WP,Ry),Q.Fc=function(e){var t,n;return RE(this),n=this.d.dc(),t=this.d.Fc(e),t&&(++this.f.d,n&&Jd(this)),t},Q.Gc=function(e){var t,n,r;return!e.dc()&&(r=(RE(this),this.d.gc()),t=this.d.Gc(e),t&&(n=this.d.gc(),this.f.d+=n-r,r==0&&Jd(this)),t)},Q.$b=function(){var e=(RE(this),this.d.gc());e!=0&&(this.d.$b(),this.f.d-=e,Up(this))},Q.Hc=function(e){return RE(this),this.d.Hc(e)},Q.Ic=function(e){return RE(this),this.d.Ic(e)},Q.Fb=function(e){return e===this||(RE(this),NT(this.d,e))},Q.Hb=function(){return RE(this),US(this.d)},Q.Kc=function(){return RE(this),new xje(this)},Q.Mc=function(e){var t;return RE(this),t=this.d.Mc(e),t&&(--this.f.d,Up(this)),t},Q.gc=function(){return tCe(this)},Q.Nc=function(){return RE(this),this.d.Nc()},Q.Ib=function(){return RE(this),PE(this.d)},L(RP,`AbstractMapBasedMultimap/WrappedCollection`,551);var JW=gp(HP,`List`);q(744,551,{20:1,31:1,16:1,15:1},qNe),Q.jd=function(e){zS(this,e)},Q.Nc=function(){return RE(this),this.d.Nc()},Q.bd=function(e,t){var n;RE(this),n=this.d.dc(),P(this.d,15).bd(e,t),++this.a.d,n&&Jd(this)},Q.cd=function(e,t){var n,r,i;return!t.dc()&&(i=(RE(this),this.d.gc()),n=P(this.d,15).cd(e,t),n&&(r=this.d.gc(),this.a.d+=r-i,i==0&&Jd(this)),n)},Q.Xb=function(e){return RE(this),P(this.d,15).Xb(e)},Q.dd=function(e){return RE(this),P(this.d,15).dd(e)},Q.ed=function(){return RE(this),new cwe(this)},Q.fd=function(e){return RE(this),new xIe(this,e)},Q.gd=function(e){var t;return RE(this),t=P(this.d,15).gd(e),--this.a.d,Up(this),t},Q.hd=function(e,t){return RE(this),P(this.d,15).hd(e,t)},Q.kd=function(e,t){return RE(this),nVe(this.a,this.e,P(this.d,15).kd(e,t),this.b?this.b:this)},L(RP,`AbstractMapBasedMultimap/WrappedList`,744),q(1126,744,{20:1,31:1,16:1,15:1,59:1},lEe),L(RP,`AbstractMapBasedMultimap/RandomAccessWrappedList`,1126),q(628,1,VP,xje),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return Ng(this),this.b.Ob()},Q.Pb=function(){return Ng(this),this.b.Pb()},Q.Qb=function(){TTe(this)},L(RP,`AbstractMapBasedMultimap/WrappedCollection/WrappedIterator`,628),q(745,628,YP,cwe,xIe),Q.Qb=function(){TTe(this)},Q.Rb=function(e){var t=tCe(this.a)==0;(Ng(this),P(this.b,128)).Rb(e),++this.a.a.d,t&&Jd(this.a)},Q.Sb=function(){return(Ng(this),P(this.b,128)).Sb()},Q.Tb=function(){return(Ng(this),P(this.b,128)).Tb()},Q.Ub=function(){return(Ng(this),P(this.b,128)).Ub()},Q.Vb=function(){return(Ng(this),P(this.b,128)).Vb()},Q.Wb=function(e){(Ng(this),P(this.b,128)).Wb(e)},L(RP,`AbstractMapBasedMultimap/WrappedList/WrappedListIterator`,745),q(743,551,Kvt,mDe),Q.Nc=function(){return RE(this),this.d.Nc()},L(RP,`AbstractMapBasedMultimap/WrappedSortedSet`,743),q(1125,743,JP,HCe),L(RP,`AbstractMapBasedMultimap/WrappedNavigableSet`,1125),q(1124,551,KP,hDe),Q.Nc=function(){return RE(this),this.d.Nc()},L(RP,`AbstractMapBasedMultimap/WrappedSet`,1124),q(1133,1,{},c),Q.Kb=function(e){return rWe(P(e,44))},L(RP,`AbstractMapBasedMultimap/lambda$1$Type`,1133),q(1132,1,{},cde),Q.Kb=function(e){return new oo(this.a,e)},L(RP,`AbstractMapBasedMultimap/lambda$2$Type`,1132);var YW=gp(HP,`Map/Entry`);q(358,1,XP),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),zh(this.ld(),t.ld())&&zh(this.md(),t.md())):!1},Q.Hb=function(){var e=this.ld(),t=this.md();return(e==null?0:US(e))^(t==null?0:US(t))},Q.nd=function(e){throw E(new Br)},Q.Ib=function(){return this.ld()+`=`+this.md()},L(RP,qvt,358),q(2086,31,WP),Q.$b=function(){this.od().$b()},Q.Hc=function(e){var t;return j(e,44)?(t=P(e,44),bBe(this.od(),t.ld(),t.md())):!1},Q.Mc=function(e){var t;return j(e,44)?(t=P(e,44),xBe(this.od(),t.ld(),t.md())):!1},Q.gc=function(){return this.od().d},L(RP,`Multimaps/Entries`,2086),q(749,2086,WP,mn),Q.Kc=function(){return this.a.kc()},Q.od=function(){return this.a},Q.Nc=function(){return this.a.lc()},L(RP,`AbstractMultimap/Entries`,749),q(750,749,KP,M_e),Q.Nc=function(){return this.a.lc()},Q.Fb=function(e){return eet(this,e)},Q.Hb=function(){return uYe(this)},L(RP,`AbstractMultimap/EntrySet`,750),q(751,31,WP,hn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return dQe(this.a,e)},Q.Kc=function(){return this.a.nc()},Q.gc=function(){return this.a.d},Q.Nc=function(){return this.a.oc()},L(RP,`AbstractMultimap/Values`,751),q(2087,31,{849:1,20:1,31:1,16:1}),Q.Jc=function(e){ph(e),bg(this).Jc(new Dde(e))},Q.Nc=function(){var e;return e=bg(this).Nc(),pA(e,new g,64|e.yd()&1296,this.a.d)},Q.Fc=function(e){return Zi(),!0},Q.Gc=function(e){return ph(this),ph(e),j(e,552)?NBe(P(e,849)):!e.dc()&&rx(this,e.Kc())},Q.Hc=function(e){var t;return t=P(TT(Rg(this.a),e),16),(t?t.gc():0)>0},Q.Fb=function(e){return Nit(this,e)},Q.Hb=function(){return US(bg(this))},Q.dc=function(){return bg(this).dc()},Q.Mc=function(e){return gnt(this,e,1)>0},Q.Ib=function(){return PE(bg(this))},L(RP,`AbstractMultiset`,2087),q(2089,2068,KP),Q.$b=function(){gS(this.a.a)},Q.Hc=function(e){var t,n;return j(e,504)?(n=P(e,425),P(n.a.md(),16).gc()<=0?!1:(t=VRe(this.a,n.a.ld()),t==P(n.a.md(),16).gc())):!1},Q.Mc=function(e){var t,n,r,i;return j(e,504)&&(n=P(e,425),t=n.a.ld(),r=P(n.a.md(),16).gc(),r!=0)?(i=this.a,_nt(i,t,r)):!1},L(RP,`Multisets/EntrySet`,2089),q(1139,2089,KP,lde),Q.Kc=function(){return new H_e(PNe(Rg(this.a.a)).Kc())},Q.gc=function(){return Rg(this.a.a).gc()},L(RP,`AbstractMultiset/EntrySet`,1139),q(627,742,BP),Q.hc=function(){return this.pd()},Q.jc=function(){return this.qd()},Q.cc=function(e){return this.rd(e)},Q.fc=function(e){return this.sd(e)},Q.Zb=function(){var e;return e=this.f,e||(this.f=this.ac())},Q.qd=function(){return Vg(),Vg(),eK},Q.Fb=function(e){return Rw(this,e)},Q.rd=function(e){return P(Dy(this,e),21)},Q.sd=function(e){return P(sT(this,e),21)},Q.mc=function(e){return Vg(),new oa(P(e,21))},Q.pc=function(e,t){return new hDe(this,e,P(t,21))},L(RP,`AbstractSetMultimap`,627),q(1723,627,BP),Q.hc=function(){return new Ja(this.b)},Q.pd=function(){return new Ja(this.b)},Q.jc=function(){return Vh(new Ja(this.b))},Q.qd=function(){return Vh(new Ja(this.b))},Q.cc=function(e){return P(P(Dy(this,e),21),87)},Q.rd=function(e){return P(P(Dy(this,e),21),87)},Q.fc=function(e){return P(P(sT(this,e),21),87)},Q.sd=function(e){return P(P(sT(this,e),21),87)},Q.mc=function(e){return j(e,277)?Vh(P(e,277)):(Vg(),new UTe(P(e,87)))},Q.Zb=function(){var e;return e=this.f,e||(this.f=j(this.c,139)?new Id(this,P(this.c,139)):j(this.c,133)?new Fd(this,P(this.c,133)):new io(this,this.c))},Q.pc=function(e,t){return j(t,277)?new HCe(this,e,P(t,277)):new mDe(this,e,P(t,87))},L(RP,`AbstractSortedSetMultimap`,1723),q(1724,1723,BP),Q.Zb=function(){var e;return e=this.f,P(P(e||(this.f=j(this.c,139)?new Id(this,P(this.c,139)):j(this.c,133)?new Fd(this,P(this.c,133)):new io(this,this.c)),133),139)},Q.ec=function(){var e;return e=this.i,P(P(e||(this.i=j(this.c,139)?new ro(this,P(this.c,139)):j(this.c,133)?new no(this,P(this.c,133)):new zu(this,this.c)),87),277)},Q.bc=function(){return j(this.c,139)?new ro(this,P(this.c,139)):j(this.c,133)?new no(this,P(this.c,133)):new zu(this,this.c)},L(RP,`AbstractSortedKeySortedSetMultimap`,1724),q(2109,1,{2046:1}),Q.Fb=function(e){return O8e(this,e)},Q.Hb=function(){var e;return QXe((e=this.g,e||(this.g=new gn(this))))},Q.Ib=function(){var e;return V5e((e=this.f,e||(this.f=new ETe(this))))},L(RP,`AbstractTable`,2109),q(679,GP,KP,gn),Q.$b=function(){mve()},Q.Hc=function(e){var t,n;return j(e,479)?(t=P(e,697),n=P(TT(JPe(this.a),ul(t.c.e,t.b)),85),!!n&&wT(n.vc(),new oo(ul(t.c.c,t.a),Iy(t.c,t.b,t.a)))):!1},Q.Kc=function(){return UIe(this.a)},Q.Mc=function(e){var t,n;return j(e,479)?(t=P(e,697),n=P(TT(JPe(this.a),ul(t.c.e,t.b)),85),!!n&&D$e(n.vc(),new oo(ul(t.c.c,t.a),Iy(t.c,t.b,t.a)))):!1},Q.gc=function(){return NMe(this.a)},Q.Nc=function(){return WBe(this.a)},L(RP,`AbstractTable/CellSet`,679),q(2025,31,WP,dde),Q.$b=function(){mve()},Q.Hc=function(e){return Z5e(this.a,e)},Q.Kc=function(){return WIe(this.a)},Q.gc=function(){return NMe(this.a)},Q.Nc=function(){return gBe(this.a)},L(RP,`AbstractTable/Values`,2025),q(1697,1696,BP),L(RP,`ArrayListMultimapGwtSerializationDependencies`,1697),q(520,1697,BP,la,URe),Q.hc=function(){return new Hy(this.a)},Q.a=0,L(RP,`ArrayListMultimap`,520),q(678,2109,{678:1,2046:1,3:1},rrt),L(RP,`ArrayTable`,678),q(2021,399,zP,DTe),Q.Xb=function(e){return new yZe(this.a,e)},L(RP,`ArrayTable/1`,2021),q(2022,1,{},ade),Q.td=function(e){return new yZe(this.a,e)},L(RP,`ArrayTable/1methodref$getCell$Type`,2022),q(2110,1,{697:1}),Q.Fb=function(e){var t;return e===this?!0:j(e,479)?(t=P(e,697),zh(ul(this.c.e,this.b),ul(t.c.e,t.b))&&zh(ul(this.c.c,this.a),ul(t.c.c,t.a))&&zh(Iy(this.c,this.b,this.a),Iy(t.c,t.b,t.a))):!1},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[ul(this.c.e,this.b),ul(this.c.c,this.a),Iy(this.c,this.b,this.a)]))},Q.Ib=function(){return`(`+ul(this.c.e,this.b)+`,`+ul(this.c.c,this.a)+`)=`+Iy(this.c,this.b,this.a)},L(RP,`Tables/AbstractCell`,2110),q(479,2110,{479:1,697:1},yZe),Q.a=0,Q.b=0,Q.d=0,L(RP,`ArrayTable/2`,479),q(2024,1,{},ode),Q.td=function(e){return IGe(this.a,e)},L(RP,`ArrayTable/2methodref$getValue$Type`,2024),q(2023,399,zP,OTe),Q.Xb=function(e){return IGe(this.a,e)},L(RP,`ArrayTable/3`,2023),q(2077,2065,UP),Q.$b=function(){Cp(this.kc())},Q.vc=function(){return new bde(this)},Q.lc=function(){return new lIe(this.kc(),this.gc())},L(RP,`Maps/IteratorBasedAbstractMap`,2077),q(842,2077,UP),Q.$b=function(){throw E(new Br)},Q._b=function(e){return oye(this.c,e)},Q.kc=function(){return new kTe(this,this.c.b.c.gc())},Q.lc=function(){return yp(this.c.b.c.gc(),16,new sde(this))},Q.xc=function(e){var t=P(_f(this.c,e),17);return t?this.vd(t.a):null},Q.dc=function(){return this.c.b.c.dc()},Q.ec=function(){return om(this.c)},Q.zc=function(e,t){var n=P(_f(this.c,e),17);if(!n)throw E(new Fi(this.ud()+` `+e+` not in `+om(this.c)));return this.wd(n.a,t)},Q.Bc=function(e){throw E(new Br)},Q.gc=function(){return this.c.b.c.gc()},L(RP,`ArrayTable/ArrayMap`,842),q(2020,1,{},sde),Q.td=function(e){return XPe(this.a,e)},L(RP,`ArrayTable/ArrayMap/0methodref$getEntry$Type`,2020),q(2018,358,XP,Vye),Q.ld=function(){return pEe(this.a,this.b)},Q.md=function(){return this.a.vd(this.b)},Q.nd=function(e){return this.a.wd(this.b,e)},Q.b=0,L(RP,`ArrayTable/ArrayMap/1`,2018),q(2019,399,zP,kTe),Q.Xb=function(e){return XPe(this.a,e)},L(RP,`ArrayTable/ArrayMap/2`,2019),q(2017,842,UP,fPe),Q.ud=function(){return`Column`},Q.vd=function(e){return Iy(this.b,this.a,e)},Q.wd=function(e,t){return JXe(this.b,this.a,e,t)},Q.a=0,L(RP,`ArrayTable/Row`,2017),q(843,842,UP,ETe),Q.vd=function(e){return new fPe(this.a,e)},Q.zc=function(e,t){return P(t,85),hve()},Q.wd=function(e,t){return P(t,85),gve()},Q.ud=function(){return`Row`},L(RP,`ArrayTable/RowMap`,843),q(1157,1,QP,Hye),Q.Ad=function(e){return!!(this.a.yd()&-262&e)},Q.yd=function(){return this.a.yd()&-262},Q.zd=function(){return this.a.zd()},Q.Nb=function(e){this.a.Nb(new Wye(e,this.b))},Q.Bd=function(e){return this.a.Bd(new Uye(e,this.b))},L(RP,`CollectSpliterators/1`,1157),q(1158,1,$P,Uye),Q.Cd=function(e){this.a.Cd(this.b.Kb(e))},L(RP,`CollectSpliterators/1/lambda$0$Type`,1158),q(1159,1,$P,Wye),Q.Cd=function(e){this.a.Cd(this.b.Kb(e))},L(RP,`CollectSpliterators/1/lambda$1$Type`,1159),q(1154,1,QP,BOe),Q.Ad=function(e){return!!((16464|this.b)&e)},Q.yd=function(){return 16464|this.b},Q.zd=function(){return this.a.zd()},Q.Nb=function(e){this.a.Qe(new Kye(e,this.c))},Q.Bd=function(e){return this.a.Re(new Gye(e,this.c))},Q.b=0,L(RP,`CollectSpliterators/1WithCharacteristics`,1154),q(1155,1,eF,Gye),Q.Dd=function(e){this.a.Cd(this.b.td(e))},L(RP,`CollectSpliterators/1WithCharacteristics/lambda$0$Type`,1155),q(1156,1,eF,Kye),Q.Dd=function(e){this.a.Cd(this.b.td(e))},L(RP,`CollectSpliterators/1WithCharacteristics/lambda$1$Type`,1156),q(1150,1,QP),Q.Ad=function(e){return(this.a&e)!=0},Q.yd=function(){return this.a},Q.zd=function(){return this.e&&(this.b=ywe(this.b,this.e.zd())),ywe(this.b,0)},Q.Nb=function(e){this.e&&=(this.e.Nb(e),null),this.c.Nb(new qye(this,e)),this.b=0},Q.Bd=function(e){for(;;){if(this.e&&this.e.Bd(e))return cl(this.b,tF)&&(this.b=xE(this.b,1)),!0;if(this.e=null,!this.c.Bd(new fde(this)))return!1}},Q.a=0,Q.b=0,L(RP,`CollectSpliterators/FlatMapSpliterator`,1150),q(1152,1,$P,fde),Q.Cd=function(e){OOe(this.a,e)},L(RP,`CollectSpliterators/FlatMapSpliterator/lambda$0$Type`,1152),q(1153,1,$P,qye),Q.Cd=function(e){iIe(this.a,this.b,e)},L(RP,`CollectSpliterators/FlatMapSpliterator/lambda$1$Type`,1153),q(1151,1150,QP,$Be),L(RP,`CollectSpliterators/FlatMapSpliteratorOfObject`,1151),q(253,1,nF),Q.Fd=function(e){return this.Ed(P(e,253))},Q.Ed=function(e){var t;return e==(mi(),ZW)?1:e==(pi(),XW)?-1:(t=(ap(),pC(this.a,e.a)),t==0?j(this,526)==j(e,526)?0:j(this,526)?1:-1:t)},Q.Id=function(){return this.a},Q.Fb=function(e){return f3e(this,e)},L(RP,`Cut`,253),q(1823,253,nF,k_e),Q.Ed=function(e){return e==this?0:1},Q.Gd=function(e){throw E(new yge)},Q.Hd=function(e){e.a+=`+∞)`},Q.Id=function(){throw E(new Ii(Yvt))},Q.Hb=function(){return yo(),VD(this)},Q.Jd=function(e){return!1},Q.Ib=function(){return`+∞`};var XW;L(RP,`Cut/AboveAll`,1823),q(526,253,{253:1,526:1,3:1,34:1},BTe),Q.Gd=function(e){hl((e.a+=`(`,e),this.a)},Q.Hd=function(e){jh(hl(e,this.a),93)},Q.Hb=function(){return~US(this.a)},Q.Jd=function(e){return ap(),pC(this.a,e)<0},Q.Ib=function(){return`/`+this.a+`\\`},L(RP,`Cut/AboveValue`,526),q(1822,253,nF,O_e),Q.Ed=function(e){return e==this?0:-1},Q.Gd=function(e){e.a+=`(-∞`},Q.Hd=function(e){throw E(new yge)},Q.Id=function(){throw E(new Ii(Yvt))},Q.Hb=function(){return yo(),VD(this)},Q.Jd=function(e){return!0},Q.Ib=function(){return`-∞`};var ZW;L(RP,`Cut/BelowAll`,1822),q(1824,253,nF,VTe),Q.Gd=function(e){hl((e.a+=`[`,e),this.a)},Q.Hd=function(e){jh(hl(e,this.a),41)},Q.Hb=function(){return US(this.a)},Q.Jd=function(e){return ap(),pC(this.a,e)<=0},Q.Ib=function(){return`\\`+this.a+`/`},L(RP,`Cut/BelowValue`,1824),q(547,1,rF),Q.Jc=function(e){ly(this,e)},Q.Ib=function(){return s1e(P(Wg(this,`use Optional.orNull() instead of Optional.or(null)`),20).Kc())},L(RP,`FluentIterable`,547),q(442,547,rF,Hl),Q.Kc=function(){return new pm(Vu(this.a.Kc(),new d))},L(RP,`FluentIterable/2`,442),q(1059,547,rF,ICe),Q.Kc=function(){return jm(this)},L(RP,`FluentIterable/3`,1059),q(724,399,zP,ATe),Q.Xb=function(e){return this.a[e].Kc()},L(RP,`FluentIterable/3/1`,724),q(2070,1,{}),Q.Ib=function(){return PE(this.Kd().b)},L(RP,`ForwardingObject`,2070),q(2071,2070,Xvt),Q.Kd=function(){return this.Ld()},Q.Jc=function(e){ly(this,e)},Q.Lc=function(){return this.Oc()},Q.Nc=function(){return new cv(this,0)},Q.Oc=function(){return new Mp(null,this.Nc())},Q.Fc=function(e){return this.Ld(),dye()},Q.Gc=function(e){return this.Ld(),fye()},Q.$b=function(){this.Ld(),pye()},Q.Hc=function(e){return this.Ld().Hc(e)},Q.Ic=function(e){return this.Ld().Ic(e)},Q.dc=function(){return this.Ld().b.dc()},Q.Kc=function(){return this.Ld().Kc()},Q.Mc=function(e){return this.Ld(),mye()},Q.gc=function(){return this.Ld().b.gc()},Q.Pc=function(){return this.Ld().Pc()},Q.Qc=function(e){return this.Ld().Qc(e)},L(RP,`ForwardingCollection`,2071),q(2078,31,iF),Q.Kc=function(){return this.Od()},Q.Fc=function(e){throw E(new Br)},Q.Gc=function(e){throw E(new Br)},Q.Md=function(){return this.c||=this.Nd()},Q.$b=function(){throw E(new Br)},Q.Hc=function(e){return e!=null&&QE(this,e,!1)},Q.Nd=function(){switch(this.gc()){case 0:return gh(),gh(),QW;case 1:return gh(),new wp(ph(this.Od().Pb()));default:return new mPe(this,this.Pc())}},Q.Mc=function(e){throw E(new Br)},L(RP,`ImmutableCollection`,2078),q(727,2078,iF,mge),Q.Kc=function(){return hb(this.a.Kc())},Q.Hc=function(e){return e!=null&&this.a.Hc(e)},Q.Ic=function(e){return this.a.Ic(e)},Q.dc=function(){return this.a.dc()},Q.Od=function(){return hb(this.a.Kc())},Q.gc=function(){return this.a.gc()},Q.Pc=function(){return this.a.Pc()},Q.Qc=function(e){return this.a.Qc(e)},Q.Ib=function(){return PE(this.a)},L(RP,`ForwardingImmutableCollection`,727),q(307,2078,aF),Q.Kc=function(){return this.Od()},Q.ed=function(){return this.Pd(0)},Q.fd=function(e){return this.Pd(e)},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.kd=function(e,t){return this.Qd(e,t)},Q.bd=function(e,t){throw E(new Br)},Q.cd=function(e,t){throw E(new Br)},Q.Md=function(){return this},Q.Fb=function(e){return yit(this,e)},Q.Hb=function(){return hXe(this)},Q.dd=function(e){return e==null?-1:o3e(this,e)},Q.Od=function(){return this.Pd(0)},Q.Pd=function(e){return pd(this,e)},Q.gd=function(e){throw E(new Br)},Q.hd=function(e,t){throw E(new Br)},Q.Qd=function(e,t){var n;return bT((n=new abe(this),new $_(n,e,t)))};var QW;L(RP,`ImmutableList`,307),q(2105,307,aF),Q.Kc=function(){return hb(this.Rd().Kc())},Q.kd=function(e,t){return bT(this.Rd().kd(e,t))},Q.Hc=function(e){return e!=null&&this.Rd().Hc(e)},Q.Ic=function(e){return this.Rd().Ic(e)},Q.Fb=function(e){return NT(this.Rd(),e)},Q.Xb=function(e){return ul(this,e)},Q.Hb=function(){return US(this.Rd())},Q.dd=function(e){return this.Rd().dd(e)},Q.dc=function(){return this.Rd().dc()},Q.Od=function(){return hb(this.Rd().Kc())},Q.gc=function(){return this.Rd().gc()},Q.Qd=function(e,t){return bT(this.Rd().kd(e,t))},Q.Pc=function(){return this.Rd().Qc(V(WW,FP,1,this.Rd().gc(),5,1))},Q.Qc=function(e){return this.Rd().Qc(e)},Q.Ib=function(){return PE(this.Rd())},L(RP,`ForwardingImmutableList`,2105),q(729,1,sF),Q.vc=function(){return am(this)},Q.wc=function(e){xC(this,e)},Q.ec=function(){return om(this)},Q.yc=function(e,t,n){return AE(this,e,t,n)},Q.Cc=function(){return this.Vd()},Q.$b=function(){throw E(new Br)},Q._b=function(e){return this.xc(e)!=null},Q.uc=function(e){return this.Vd().Hc(e)},Q.Td=function(){return new hge(this)},Q.Ud=function(){return new gge(this)},Q.Fb=function(e){return mQe(this,e)},Q.Hb=function(){return am(this).Hb()},Q.dc=function(){return this.gc()==0},Q.zc=function(e,t){return pve()},Q.Bc=function(e){throw E(new Br)},Q.Ib=function(){return O9e(this)},Q.Vd=function(){return this.e?this.e:this.e=this.Ud()},Q.c=null,Q.d=null,Q.e=null;var ATt;L(RP,`ImmutableMap`,729),q(730,729,sF),Q._b=function(e){return oye(this,e)},Q.uc=function(e){return fbe(this.b,e)},Q.Sd=function(){return S$e(new ude(this))},Q.Td=function(){return S$e(zFe(this.b))},Q.Ud=function(){return wf(),new mge(RFe(this.b))},Q.Fb=function(e){return pbe(this.b,e)},Q.xc=function(e){return _f(this,e)},Q.Hb=function(){return US(this.b.c)},Q.dc=function(){return this.b.c.dc()},Q.gc=function(){return this.b.c.gc()},Q.Ib=function(){return PE(this.b.c)},L(RP,`ForwardingImmutableMap`,730),q(2072,2071,cF),Q.Kd=function(){return this.Wd()},Q.Ld=function(){return this.Wd()},Q.Nc=function(){return new cv(this,1)},Q.Fb=function(e){return e===this||this.Wd().Fb(e)},Q.Hb=function(){return this.Wd().Hb()},L(RP,`ForwardingSet`,2072),q(1085,2072,cF,ude),Q.Kd=function(){return tg(this.a.b)},Q.Ld=function(){return tg(this.a.b)},Q.Hc=function(e){if(j(e,44)&&P(e,44).ld()==null)return!1;try{return dbe(tg(this.a.b),e)}catch(e){if(e=ew(e),j(e,212))return!1;throw E(e)}},Q.Wd=function(){return tg(this.a.b)},Q.Qc=function(e){var t=iLe(tg(this.a.b),e);return tg(this.a.b).b.gc()=0?`+`:``)+(n/60|0),t=Fl(r.Math.abs(n)%60),(J7e(),$Tt)[this.q.getDay()]+` `+eEt[this.q.getMonth()]+` `+Fl(this.q.getDate())+` `+Fl(this.q.getHours())+`:`+Fl(this.q.getMinutes())+`:`+Fl(this.q.getSeconds())+` GMT`+e+t+` `+this.q.getFullYear()};var fG=L(HP,`Date`,206);q(2015,206,lyt,e8e),Q.a=!1,Q.b=0,Q.c=0,Q.d=0,Q.e=0,Q.f=0,Q.g=!1,Q.i=0,Q.j=0,Q.k=0,Q.n=0,Q.o=0,Q.p=0,L(`com.google.gwt.i18n.shared.impl`,`DateRecord`,2015),q(2064,1,{}),Q.pe=function(){return null},Q.qe=function(){return null},Q.re=function(){return null},Q.se=function(){return null},Q.te=function(){return null},L(ZF,`JSONValue`,2064),q(221,2064,{221:1},Tn,xn),Q.Fb=function(e){return j(e,221)?Oze(this.a,P(e,221).a):!1},Q.oe=function(){return rge},Q.Hb=function(){return $g(this.a)},Q.pe=function(){return this},Q.Ib=function(){var e,t,n=new Gu(`[`);for(t=0,e=this.a.length;t0&&(n.a+=`,`),hl(n,ax(this,t));return n.a+=`]`,n.a},L(ZF,`JSONArray`,221),q(493,2064,{493:1},Sn),Q.oe=function(){return ige},Q.qe=function(){return this},Q.Ib=function(){return rd(),``+this.a},Q.a=!1;var LTt,RTt;L(ZF,`JSONBoolean`,493),q(997,63,SF,U_e),L(ZF,`JSONException`,997),q(1036,2064,{},te),Q.oe=function(){return age},Q.Ib=function(){return IP};var zTt;L(ZF,`JSONNull`,1036),q(263,2064,{263:1},Cn),Q.Fb=function(e){return j(e,263)?this.a==P(e,263).a:!1},Q.oe=function(){return tge},Q.Hb=function(){return jl(this.a)},Q.re=function(){return this},Q.Ib=function(){return this.a+``},Q.a=0,L(ZF,`JSONNumber`,263),q(190,2064,{190:1},bi,wn),Q.Fb=function(e){return j(e,190)?Oze(this.a,P(e,190).a):!1},Q.oe=function(){return nge},Q.Hb=function(){return $g(this.a)},Q.se=function(){return this},Q.Ib=function(){var e,t,n,r,i,a,o=new Gu(`{`);for(e=!0,a=ZS(this,V(LG,X,2,0,6,1)),n=a,r=0,i=n.length;r=0?`:`+this.c:``)+`)`},Q.c=0;var IG=L(jP,`StackTraceElement`,319);TTt={3:1,484:1,34:1,2:1};var LG=L(jP,tyt,2);q(111,427,{484:1},$i,ea,Wu),L(jP,`StringBuffer`,111),q(104,427,{484:1},ta,na,Gu),L(jP,`StringBuilder`,104),q(702,77,oI,ra),L(jP,`StringIndexOutOfBoundsException`,702),q(2145,1,{});var GTt;q(48,63,{3:1,103:1,63:1,82:1,48:1},Br,Ri),L(jP,`UnsupportedOperationException`,48),q(247,242,{3:1,34:1,242:1,247:1},HT,xye),Q.Fd=function(e){return Vdt(this,P(e,247))},Q.ue=function(){return OA(Rpt(this))},Q.Fb=function(e){var t;return this===e?!0:j(e,247)?(t=P(e,247),this.e==t.e&&Vdt(this,t)==0):!1},Q.Hb=function(){var e;return this.b==0?this.a<54?(e=LC(this.f),this.b=nm(uv(e,-1)),this.b=33*this.b+nm(uv(lm(e,32),-1)),this.b=17*this.b+C_(this.e),this.b):(this.b=17*i$e(this.c)+C_(this.e),this.b):this.b},Q.Ib=function(){return Rpt(this)},Q.a=0,Q.b=0,Q.d=0,Q.e=0,Q.f=0;var KTt,RG,zG,BG,VG,HG,UG,qTt,WG=L(`java.math`,`BigDecimal`,247);q(92,242,{3:1,34:1,242:1,92:1},Xv,Ize,Bm,c2e,ru),Q.Fd=function(e){return q0e(this,P(e,92))},Q.ue=function(){return OA(pP(this,0))},Q.Fb=function(e){return WE(this,e)},Q.Hb=function(){return i$e(this)},Q.Ib=function(){return pP(this,0)},Q.b=-2,Q.c=0,Q.d=0,Q.e=0;var JTt,GG,YTt,KG,qG,JG,YG=L(`java.math`,`BigInteger`,92),XTt,ZTt,XG,ZG;q(498,2065,UP),Q.$b=function(){Pm(this)},Q._b=function(e){return km(this,e)},Q.uc=function(e){return hQe(this,e,this.i)||hQe(this,e,this.f)},Q.vc=function(){return new Fn(this)},Q.xc=function(e){return xh(this,e)},Q.zc=function(e,t){return Qh(this,e,t)},Q.Bc=function(e){return My(this,e)},Q.gc=function(){return ho(this)},Q.g=0,L(HP,`AbstractHashMap`,498),q(267,GP,KP,Fn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return PBe(this,e)},Q.Kc=function(){return new EC(this.a)},Q.Mc=function(e){var t;return PBe(this,e)?(t=P(e,44).ld(),this.a.Bc(t),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractHashMap/EntrySet`,267),q(268,1,VP,EC),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return MS(this)},Q.Ob=function(){return this.b},Q.Qb=function(){aKe(this)},Q.b=!1,Q.d=0,L(HP,`AbstractHashMap/EntrySetIterator`,268),q(426,1,VP,qn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return ts(this)},Q.Pb=function(){return Pg(this)},Q.Qb=function(){Fh(this)},Q.b=0,Q.c=-1,L(HP,`AbstractList/IteratorImpl`,426),q(98,426,YP,bv),Q.Qb=function(){Fh(this)},Q.Rb=function(e){qd(this,e)},Q.Sb=function(){return this.b>0},Q.Tb=function(){return this.b},Q.Ub=function(){return jd(this.b>0),this.a.Xb(this.c=--this.b)},Q.Vb=function(){return this.b-1},Q.Wb=function(e){Md(this.c!=-1),this.a.hd(this.c,e)},L(HP,`AbstractList/ListIteratorImpl`,98),q(244,56,gF,$_),Q.bd=function(e,t){av(e,this.b),this.c.bd(this.a+e,t),++this.b},Q.Xb=function(e){return ov(e,this.b),this.c.Xb(this.a+e)},Q.gd=function(e){var t;return ov(e,this.b),t=this.c.gd(this.a+e),--this.b,t},Q.hd=function(e,t){return ov(e,this.b),this.c.hd(this.a+e,t)},Q.gc=function(){return this.b},Q.a=0,Q.b=0,L(HP,`AbstractList/SubList`,244),q(266,GP,KP,Pn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a._b(e)},Q.Kc=function(){var e;return e=this.a.vc().Kc(),new zn(e)},Q.Mc=function(e){return this.a._b(e)?(this.a.Bc(e),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractMap/1`,266),q(541,1,VP,zn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a.Ob()},Q.Pb=function(){var e;return e=P(this.a.Pb(),44),e.ld()},Q.Qb=function(){this.a.Qb()},L(HP,`AbstractMap/1/1`,541),q(231,31,WP,Bn),Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a.uc(e)},Q.Kc=function(){var e;return e=this.a.vc().Kc(),new Vn(e)},Q.gc=function(){return this.a.gc()},L(HP,`AbstractMap/2`,231),q(301,1,VP,Vn),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a.Ob()},Q.Pb=function(){var e;return e=P(this.a.Pb(),44),e.md()},Q.Qb=function(){this.a.Qb()},L(HP,`AbstractMap/2/1`,301),q(494,1,{494:1,44:1}),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),rg(this.d,t.ld())&&rg(this.e,t.md())):!1},Q.ld=function(){return this.d},Q.md=function(){return this.e},Q.Hb=function(){return cu(this.d)^cu(this.e)},Q.nd=function(e){return zDe(this,e)},Q.Ib=function(){return this.d+`=`+this.e},L(HP,`AbstractMap/AbstractEntry`,494),q(397,494,{494:1,397:1,44:1},ds),L(HP,`AbstractMap/SimpleEntry`,397),q(2082,1,yI),Q.Fb=function(e){var t;return j(e,44)?(t=P(e,44),rg(this.ld(),t.ld())&&rg(this.md(),t.md())):!1},Q.Hb=function(){return cu(this.ld())^cu(this.md())},Q.Ib=function(){return this.ld()+`=`+this.md()},L(HP,qvt,2082),q(2090,2065,qP),Q.Xc=function(e){return Va(this.Ee(e))},Q.tc=function(e){return xUe(this,e)},Q._b=function(e){return BDe(this,e)},Q.vc=function(){return new Hn(this)},Q.Tc=function(){return _Pe(this.Ge())},Q.Yc=function(e){return Va(this.He(e))},Q.xc=function(e){var t=e;return nl(this.Fe(t))},Q.$c=function(e){return Va(this.Ie(e))},Q.ec=function(){return new Efe(this)},Q.Vc=function(){return _Pe(this.Je())},Q._c=function(e){return Va(this.Ke(e))},L(HP,`AbstractNavigableMap`,2090),q(629,GP,KP,Hn),Q.Hc=function(e){return j(e,44)&&xUe(this.b,P(e,44))},Q.Kc=function(){return this.b.De()},Q.Mc=function(e){var t;return j(e,44)?(t=P(e,44),this.b.Le(t)):!1},Q.gc=function(){return this.b.gc()},L(HP,`AbstractNavigableMap/EntrySet`,629),q(1146,GP,JP,Efe),Q.Nc=function(){return new cs(this)},Q.$b=function(){this.a.$b()},Q.Hc=function(e){return BDe(this.a,e)},Q.Kc=function(){return new Dfe(this.a.vc().b.De())},Q.Mc=function(e){return BDe(this.a,e)?(this.a.Bc(e),!0):!1},Q.gc=function(){return this.a.gc()},L(HP,`AbstractNavigableMap/NavigableKeySet`,1146),q(1147,1,VP,Dfe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return ts(this.a.a)},Q.Pb=function(){return yEe(this.a).ld()},Q.Qb=function(){tke(this.a)},L(HP,`AbstractNavigableMap/NavigableKeySet/1`,1147),q(2103,31,WP),Q.Fc=function(e){return ep(gA(this,e),bI),!0},Q.Gc=function(e){return Gh(e),$f(e!=this,`Can't add a queue to itself`),XS(this,e)},Q.$b=function(){for(;sx(this)!=null;);},L(HP,`AbstractQueue`,2103),q(310,31,{4:1,20:1,31:1,16:1},Iu,EBe),Q.Fc=function(e){return iVe(this,e),!0},Q.$b=function(){uHe(this)},Q.Hc=function(e){return IXe(new fg(this),e)},Q.dc=function(){return qi(this)},Q.Kc=function(){return new fg(this)},Q.Mc=function(e){return nRe(new fg(this),e)},Q.gc=function(){return this.c-this.b&this.a.length-1},Q.Nc=function(){return new cv(this,272)},Q.Qc=function(e){var t=this.c-this.b&this.a.length-1;return e.lengtht&&Sh(e,t,null),e},Q.b=0,Q.c=0,L(HP,`ArrayDeque`,310),q(459,1,VP,fg),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return this.a!=this.b},Q.Pb=function(){return cT(this)},Q.Qb=function(){oJe(this)},Q.a=0,Q.b=0,Q.c=-1,L(HP,`ArrayDeque/IteratorImpl`,459),q(13,56,fyt,T,Hy,bf),Q.bd=function(e,t){Jp(this,e,t)},Q.Fc=function(e){return M(this,e)},Q.cd=function(e,t){return FQe(this,e,t)},Q.Gc=function(e){return nw(this,e)},Q.$b=function(){Wr(this.c,0)},Q.Hc=function(e){return Ab(this,e,0)!=-1},Q.Jc=function(e){Dx(this,e)},Q.Xb=function(e){return Ep(this,e)},Q.dd=function(e){return Ab(this,e,0)},Q.dc=function(){return this.c.length==0},Q.Kc=function(){return new w(this)},Q.gd=function(e){return Ay(this,e)},Q.Mc=function(e){return Db(this,e)},Q.ce=function(e,t){HRe(this,e,t)},Q.hd=function(e,t){return uy(this,e,t)},Q.gc=function(){return this.c.length},Q.jd=function(e){hu(this,e)},Q.Pc=function(){return cp(this.c)},Q.Qc=function(e){return rO(this,e)};var QTt=L(HP,`ArrayList`,13);q(7,1,VP,w),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return gu(this)},Q.Pb=function(){return z(this)},Q.Qb=function(){Gm(this)},Q.a=0,Q.b=-1,L(HP,`ArrayList/1`,7),q(2112,r.Function,{},ie),Q.Me=function(e,t){return aE(e,t)},q(151,56,pyt,Wi),Q.Hc=function(e){return cJe(this,e)!=-1},Q.Jc=function(e){var t,n,r,i;for(Gh(e),n=this.a,r=0,i=n.length;r0)throw E(new Fi(NI+e+` greater than `+this.e));return this.f.Te()?zLe(this.c,this.b,this.a,e,t):WRe(this.c,e,t)},Q.zc=function(e,t){if(!Tk(this.c,this.f,e,this.b,this.a,this.e,this.d))throw E(new Fi(e+` outside the range `+this.b+` to `+this.e));return TZe(this.c,e,t)},Q.Bc=function(e){var t=e;return Tk(this.c,this.f,t,this.b,this.a,this.e,this.d)?VLe(this.c,t):null},Q.Le=function(e){return Lh(this,e.ld())&&KWe(this.c,e)},Q.gc=function(){var e,t=this.f.Te()?this.a?DD(this.c,this.b,!0):DD(this.c,this.b,!1):RGe(this.c),n;if(!(t&&Lh(this,t.d)&&t))return 0;for(e=0,n=new rC(this.c,this.f,this.b,this.a,this.e,this.d);ts(n.a);n.b=P(Pg(n.a),44))++e;return e},Q.ad=function(e,t){if(this.f.Te()&&this.c.a.Ne(e,this.b)<0)throw E(new Fi(NI+e+gyt+this.b));return this.f.Ue()?zLe(this.c,e,t,this.e,this.d):GRe(this.c,e,t)},Q.a=!1,Q.d=!1,L(HP,`TreeMap/SubMap`,631),q(304,22,PI,ls),Q.Te=function(){return!1},Q.Ue=function(){return!1};var uK,dK,fK,pK,mK=aS(HP,`TreeMap/SubMapType`,304,eG,dVe,ike);q(1143,304,PI,WCe),Q.Ue=function(){return!0},aS(HP,`TreeMap/SubMapType/1`,1143,mK,null,null),q(1144,304,PI,Owe),Q.Te=function(){return!0},Q.Ue=function(){return!0},aS(HP,`TreeMap/SubMapType/2`,1144,mK,null,null),q(1145,304,PI,UCe),Q.Te=function(){return!0},aS(HP,`TreeMap/SubMapType/3`,1145,mK,null,null);var dEt;q(157,GP,{3:1,20:1,31:1,16:1,277:1,21:1,87:1,157:1},Nge,Ja,nr),Q.Nc=function(){return new cs(this)},Q.Fc=function(e){return Rm(this,e)},Q.$b=function(){this.a.$b()},Q.Hc=function(e){return this.a._b(e)},Q.Kc=function(){return this.a.ec().Kc()},Q.Mc=function(e){return Du(this,e)},Q.gc=function(){return this.a.gc()};var fEt=L(HP,`TreeSet`,157);q(1082,1,{},jfe),Q.Ve=function(e,t){return xDe(this.a,e,t)},L(FI,`BinaryOperator/lambda$0$Type`,1082),q(1083,1,{},Mfe),Q.Ve=function(e,t){return SDe(this.a,e,t)},L(FI,`BinaryOperator/lambda$1$Type`,1083),q(952,1,{},ye),Q.Kb=function(e){return e},L(FI,`Function/lambda$0$Type`,952),q(395,1,vF,rr),Q.Mb=function(e){return!this.a.Mb(e)},L(FI,`Predicate/lambda$2$Type`,395),q(581,1,{581:1});var pEt=L(II,`Handler`,581);q(2107,1,MP),Q.xe=function(){return`DUMMY`},Q.Ib=function(){return this.xe()};var hK;L(II,`Level`,2107),q(1706,2107,MP,be),Q.xe=function(){return`INFO`},L(II,`Level/LevelInfo`,1706),q(1843,1,{},Mge);var gK;L(II,`LogManager`,1843),q(1896,1,MP,eke),Q.b=null,L(II,`LogRecord`,1896),q(525,1,{525:1},py),Q.e=!1;var mEt=!1,hEt=!1,_K=!1,gEt=!1,_Et=!1;L(II,`Logger`,525),q(835,581,{581:1},xe),L(II,`SimpleConsoleLogHandler`,835),q(108,22,{3:1,34:1,22:1,108:1},us);var vK,yK,bK,xK=aS(RI,`Collector/Characteristics`,108,eG,KRe,ake),vEt;q(758,1,{},Vm),L(RI,`CollectorImpl`,758),q(1074,1,{},Se),Q.Ve=function(e,t){return M$e(P(e,213),P(t,213))},L(RI,`Collectors/10methodref$merge$Type`,1074),q(1075,1,{},Ce),Q.Kb=function(e){return DBe(P(e,213))},L(RI,`Collectors/11methodref$toString$Type`,1075),q(1076,1,{},Nfe),Q.Kb=function(e){return rd(),!!Al(e)},L(RI,`Collectors/12methodref$test$Type`,1076),q(144,1,{},we),Q.Yd=function(e,t){P(e,16).Fc(t)},L(RI,`Collectors/20methodref$add$Type`,144),q(146,1,{},Te),Q.Xe=function(){return new T},L(RI,`Collectors/21methodref$ctor$Type`,146),q(359,1,{},Ee),Q.Xe=function(){return new Jr},L(RI,`Collectors/23methodref$ctor$Type`,359),q(360,1,{},De),Q.Yd=function(e,t){Lm(P(e,49),t)},L(RI,`Collectors/24methodref$add$Type`,360),q(1069,1,{},Oe),Q.Ve=function(e,t){return wbe(P(e,15),P(t,16))},L(RI,`Collectors/4methodref$addAll$Type`,1069),q(1073,1,{},ke),Q.Yd=function(e,t){jy(P(e,213),P(t,484))},L(RI,`Collectors/9methodref$add$Type`,1073),q(1072,1,{},jje),Q.Xe=function(){return new UC(this.a,this.b,this.c)},L(RI,`Collectors/lambda$15$Type`,1072),q(1077,1,{},Ae),Q.Xe=function(){var e;return e=new ry,oO(e,(rd(),!1),new T),oO(e,!0,new T),e},L(RI,`Collectors/lambda$22$Type`,1077),q(1078,1,{},Pfe),Q.Xe=function(){return U(O(WW,1),FP,1,5,[this.a])},L(RI,`Collectors/lambda$25$Type`,1078),q(1079,1,{},Ffe),Q.Yd=function(e,t){HMe(this.a,rS(e))},L(RI,`Collectors/lambda$26$Type`,1079),q(1080,1,{},Ife),Q.Ve=function(e,t){return oPe(this.a,rS(e),rS(t))},L(RI,`Collectors/lambda$27$Type`,1080),q(1081,1,{},je),Q.Kb=function(e){return rS(e)[0]},L(RI,`Collectors/lambda$28$Type`,1081),q(728,1,{},Me),Q.Ve=function(e,t){return Op(e,t)},L(RI,`Collectors/lambda$4$Type`,728),q(145,1,{},Ne),Q.Ve=function(e,t){return bbe(P(e,16),P(t,16))},L(RI,`Collectors/lambda$42$Type`,145),q(361,1,{},Pe),Q.Ve=function(e,t){return xbe(P(e,49),P(t,49))},L(RI,`Collectors/lambda$50$Type`,361),q(362,1,{},Fe),Q.Kb=function(e){return P(e,49)},L(RI,`Collectors/lambda$51$Type`,362),q(1068,1,{},Lfe),Q.Yd=function(e,t){YZe(this.a,P(e,85),t)},L(RI,`Collectors/lambda$7$Type`,1068),q(1070,1,{},Ie),Q.Ve=function(e,t){return RXe(P(e,85),P(t,85),new Oe)},L(RI,`Collectors/lambda$8$Type`,1070),q(1071,1,{},Rfe),Q.Kb=function(e){return T1e(this.a,P(e,85))},L(RI,`Collectors/lambda$9$Type`,1071),q(550,1,{}),Q.$e=function(){Uh(this)},Q.d=!1,L(RI,`TerminatableStream`,550),q(827,550,zI,fDe),Q.$e=function(){Uh(this)},L(RI,`DoubleStreamImpl`,827),q(1847,736,QP,Mje),Q.Re=function(e){return B4e(this,P(e,189))},Q.a=null,L(RI,`DoubleStreamImpl/2`,1847),q(1848,1,SI,zfe),Q.Pe=function(e){YCe(this.a,e)},L(RI,`DoubleStreamImpl/2/lambda$0$Type`,1848),q(1845,1,SI,Bfe),Q.Pe=function(e){JCe(this.a,e)},L(RI,`DoubleStreamImpl/lambda$0$Type`,1845),q(1846,1,SI,Vfe),Q.Pe=function(e){v0e(this.a,e)},L(RI,`DoubleStreamImpl/lambda$2$Type`,1846),q(1397,735,QP,tUe),Q.Re=function(e){return zBe(this,P(e,202))},Q.a=0,Q.b=0,Q.c=0,L(RI,`IntStream/5`,1397),q(806,550,zI,pDe),Q.$e=function(){Uh(this)},Q._e=function(){return Hh(this),this.a},L(RI,`IntStreamImpl`,806),q(807,550,zI,_be),Q.$e=function(){Uh(this)},Q._e=function(){return Hh(this),bTe(),lEt},L(RI,`IntStreamImpl/Empty`,807),q(1687,1,eF,Hfe),Q.Dd=function(e){QYe(this.a,e)},L(RI,`IntStreamImpl/lambda$4$Type`,1687);var yEt=gp(RI,`Stream`);q(26,550,{533:1,687:1,848:1},Mp),Q.$e=function(){Uh(this)};var SK;L(RI,`StreamImpl`,26),q(1102,500,QP,zOe),Q.Bd=function(e){for(;yGe(this);)if(this.a.Bd(e))return!0;else Uh(this.b),this.b=null,this.a=null;return!1},L(RI,`StreamImpl/1`,1102),q(1103,1,$P,Ufe),Q.Cd=function(e){Lje(this.a,P(e,848))},L(RI,`StreamImpl/1/lambda$0$Type`,1103),q(1104,1,vF,Wfe),Q.Mb=function(e){return Lm(this.a,e)},L(RI,`StreamImpl/1methodref$add$Type`,1104),q(1105,500,QP,DIe),Q.Bd=function(e){var t;return this.a||=(t=new T,this.b.a.Nb(new Gfe(t)),Vg(),hu(t,this.c),new cv(t,16)),ZKe(this.a,e)},Q.a=null,L(RI,`StreamImpl/5`,1105),q(1106,1,$P,Gfe),Q.Cd=function(e){M(this.a,e)},L(RI,`StreamImpl/5/2methodref$add$Type`,1106),q(737,500,QP,UGe),Q.Bd=function(e){for(this.b=!1;!this.b&&this.c.Bd(new oxe(this,e)););return this.b},Q.b=!1,L(RI,`StreamImpl/FilterSpliterator`,737),q(1096,1,$P,oxe),Q.Cd=function(e){JNe(this.a,this.b,e)},L(RI,`StreamImpl/FilterSpliterator/lambda$0$Type`,1096),q(1091,736,QP,HUe),Q.Re=function(e){return TOe(this,P(e,189))},L(RI,`StreamImpl/MapToDoubleSpliterator`,1091),q(1095,1,$P,sxe),Q.Cd=function(e){gxe(this.a,this.b,e)},L(RI,`StreamImpl/MapToDoubleSpliterator/lambda$0$Type`,1095),q(1090,735,QP,UUe),Q.Re=function(e){return EOe(this,P(e,202))},L(RI,`StreamImpl/MapToIntSpliterator`,1090),q(1094,1,$P,cxe),Q.Cd=function(e){_xe(this.a,this.b,e)},L(RI,`StreamImpl/MapToIntSpliterator/lambda$0$Type`,1094),q(734,500,QP,WUe),Q.Bd=function(e){return DOe(this,e)},L(RI,`StreamImpl/MapToObjSpliterator`,734),q(1093,1,$P,lxe),Q.Cd=function(e){vxe(this.a,this.b,e)},L(RI,`StreamImpl/MapToObjSpliterator/lambda$0$Type`,1093),q(1092,500,QP,DJe),Q.Bd=function(e){for(;ns(this.b,0);){if(!this.a.Bd(new Le))return!1;this.b=xE(this.b,1)}return this.a.Bd(e)},Q.b=0,L(RI,`StreamImpl/SkipSpliterator`,1092),q(1097,1,$P,Le),Q.Cd=function(e){},L(RI,`StreamImpl/SkipSpliterator/lambda$0$Type`,1097),q(626,1,$P,Re),Q.Cd=function(e){jde(this,e)},L(RI,`StreamImpl/ValueConsumer`,626),q(1098,1,$P,ze),Q.Cd=function(e){wo()},L(RI,`StreamImpl/lambda$0$Type`,1098),q(1099,1,$P,Be),Q.Cd=function(e){wo()},L(RI,`StreamImpl/lambda$1$Type`,1099),q(1100,1,{},Kfe),Q.Ve=function(e,t){return Tke(this.a,e,t)},L(RI,`StreamImpl/lambda$4$Type`,1100),q(1101,1,$P,uxe),Q.Cd=function(e){UDe(this.b,this.a,e)},L(RI,`StreamImpl/lambda$5$Type`,1101),q(1107,1,$P,qfe),Q.Cd=function(e){mXe(this.a,P(e,380))},L(RI,`TerminatableStream/lambda$0$Type`,1107),q(2142,1,{}),q(2014,1,{},Ve),L(`javaemul.internal`,`ConsoleLogger`,2014);var bEt=0;q(2134,1,{}),q(1830,1,$P,He),Q.Cd=function(e){P(e,317)},L(WI,`BowyerWatsonTriangulation/lambda$0$Type`,1830),q(1831,1,$P,Jfe),Q.Cd=function(e){XS(this.a,P(e,317).e)},L(WI,`BowyerWatsonTriangulation/lambda$1$Type`,1831),q(1832,1,$P,Ue),Q.Cd=function(e){P(e,177)},L(WI,`BowyerWatsonTriangulation/lambda$2$Type`,1832),q(1827,1,GI,Yfe),Q.Ne=function(e,t){return JVe(this.a,P(e,177),P(t,177))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(WI,`NaiveMinST/lambda$0$Type`,1827),q(449,1,{},ir),L(WI,`NodeMicroLayout`,449),q(177,1,{177:1},fs),Q.Fb=function(e){var t;return j(e,177)?(t=P(e,177),rg(this.a,t.a)&&rg(this.b,t.b)||rg(this.a,t.b)&&rg(this.b,t.a)):!1},Q.Hb=function(){return cu(this.a)+cu(this.b)};var xEt=L(WI,`TEdge`,177);q(317,1,{317:1},pft),Q.Fb=function(e){var t;return j(e,317)?(t=P(e,317),Bb(this,t.a)&&Bb(this,t.b)&&Bb(this,t.c)):!1},Q.Hb=function(){return cu(this.a)+cu(this.b)+cu(this.c)},L(WI,`TTriangle`,317),q(225,1,{225:1},bu),L(WI,`Tree`,225),q(1218,1,{},xRe),L(yyt,`Scanline`,1218);var SEt=gp(yyt,byt);q(1758,1,{},KKe),L(KI,`CGraph`,1758),q(316,1,{316:1},wRe),Q.b=0,Q.c=0,Q.d=0,Q.g=0,Q.i=0,Q.k=lI,L(KI,`CGroup`,316),q(830,1,{},Ige),L(KI,`CGroup/CGroupBuilder`,830),q(60,1,{60:1},eOe),Q.Ib=function(){var e;return this.j?kd(this.j.Kb(this)):(Ad(CK),CK.o+`@`+(e=td(this)>>>0,e.toString(16)))},Q.f=0,Q.i=lI;var CK=L(KI,`CNode`,60);q(829,1,{},Lge),L(KI,`CNode/CNodeBuilder`,829);var CEt;q(1590,1,{},We),Q.ff=function(e,t){return 0},Q.gf=function(e,t){return 0},L(KI,Syt,1590),q(1853,1,{},Ge),Q.cf=function(e){var t,n,i,a,o,s,c,l,u=cI,d,f,p,m,h,g;for(i=new w(e.a.b);i.ar.d.c||r.d.c==a.d.c&&r.d.b0?e+this.n.d+this.n.a:0},Q.kf=function(){var e,t,n,i,a=0;if(this.e)this.b?a=this.b.a:this.a[1][1]&&(a=this.a[1][1].kf());else if(this.g)a=VE(this,Lk(this,null,!0));else for(t=(Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])),n=0,i=t.length;n0?a+this.n.b+this.n.c:0},Q.lf=function(){var e,t,n,r,i;if(this.g)for(e=Lk(this,null,!1),n=(Ix(),U(O($K,1),Z,237,0,[XK,ZK,QK])),r=0,i=n.length;r0&&(i[0]+=this.d,n-=i[0]),i[2]>0&&(i[2]+=this.d,n-=i[2]),this.c.a=r.Math.max(0,n),this.c.d=t.d+e.d+(this.c.a-n)/2,i[1]=r.Math.max(i[1],n),IUe(this,ZK,t.d+e.d+i[0]-(i[1]-n)/2,i)},Q.b=null,Q.d=0,Q.e=!1,Q.f=!1,Q.g=!1;var eq=0,tq=0;L(oL,`GridContainerCell`,1538),q(471,22,{3:1,34:1,22:1,471:1},hs);var nq,rq,iq,NEt=aS(oL,`HorizontalLabelAlignment`,471,eG,JRe,uke),PEt;q(314,217,{217:1,314:1},YLe,JKe,aLe),Q.jf=function(){return dMe(this)},Q.kf=function(){return fMe(this)},Q.a=0,Q.c=!1;var FEt=L(oL,`LabelCell`,314);q(252,336,{217:1,336:1,252:1},$D),Q.jf=function(){return aj(this)},Q.kf=function(){return oj(this)},Q.lf=function(){iN(this)},Q.mf=function(){oN(this)},Q.b=0,Q.c=0,Q.d=!1,L(oL,`StripContainerCell`,252),q(1691,1,vF,Qe),Q.Mb=function(e){return cve(P(e,217))},L(oL,`StripContainerCell/lambda$0$Type`,1691),q(1692,1,{},$e),Q.Ye=function(e){return P(e,217).kf()},L(oL,`StripContainerCell/lambda$1$Type`,1692),q(1693,1,vF,et),Q.Mb=function(e){return lve(P(e,217))},L(oL,`StripContainerCell/lambda$2$Type`,1693),q(1694,1,{},tt),Q.Ye=function(e){return P(e,217).jf()},L(oL,`StripContainerCell/lambda$3$Type`,1694),q(472,22,{3:1,34:1,22:1,472:1},gs);var aq,oq,sq,IEt=aS(oL,`VerticalLabelAlignment`,472,eG,qRe,dke),LEt;q(800,1,{},Agt),Q.c=0,Q.d=0,Q.k=0,Q.s=0,Q.t=0,Q.v=!1,Q.w=0,Q.D=!1,Q.F=!1,L(uL,`NodeContext`,800),q(1536,1,GI,nt),Q.Ne=function(e,t){return DCe(P(e,64),P(t,64))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(uL,`NodeContext/0methodref$comparePortSides$Type`,1536),q(1537,1,GI,rt),Q.Ne=function(e,t){return w7e(P(e,117),P(t,117))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(uL,`NodeContext/1methodref$comparePortContexts$Type`,1537),q(164,22,{3:1,34:1,22:1,164:1},iC);var REt,zEt,BEt,VEt,HEt,UEt,WEt,GEt,KEt,qEt,JEt,YEt,XEt,ZEt,QEt,$Et,eDt,tDt,nDt,rDt,iDt,cq,aDt=aS(uL,`NodeLabelLocation`,164,eG,sO,fke),oDt;q(117,1,{117:1},urt),Q.a=!1,L(uL,`PortContext`,117),q(1541,1,$P,it),Q.Cd=function(e){Tye(P(e,314))},L(pL,Ryt,1541),q(1542,1,vF,at),Q.Mb=function(e){return!!P(e,117).c},L(pL,zyt,1542),q(1543,1,$P,ot),Q.Cd=function(e){Tye(P(e,117).c)},L(pL,`LabelPlacer/lambda$2$Type`,1543);var lq;q(1540,1,$P,st),Q.Cd=function(e){Rd(),cge(P(e,117))},L(pL,`NodeLabelAndSizeUtilities/lambda$0$Type`,1540),q(801,1,$P,Af),Q.Cd=function(e){Bbe(this.b,this.c,this.a,P(e,187))},Q.a=!1,Q.c=!1,L(pL,`NodeLabelCellCreator/lambda$0$Type`,801),q(1539,1,$P,Qfe),Q.Cd=function(e){Ege(this.a,P(e,187))},L(pL,`PortContextCreator/lambda$0$Type`,1539);var uq;q(1902,1,{},ct),L(mL,`GreedyRectangleStripOverlapRemover`,1902),q(1903,1,GI,lt),Q.Ne=function(e,t){return YTe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`GreedyRectangleStripOverlapRemover/0methodref$compareByYCoordinate$Type`,1903),q(1849,1,{},Hge),Q.a=5,Q.e=0,L(mL,`RectangleStripOverlapRemover`,1849),q(1850,1,GI,ut),Q.Ne=function(e,t){return XTe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`RectangleStripOverlapRemover/0methodref$compareLeftRectangleBorders$Type`,1850),q(1852,1,GI,dt),Q.Ne=function(e,t){return APe(P(e,226),P(t,226))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(mL,`RectangleStripOverlapRemover/1methodref$compareRightRectangleBorders$Type`,1852),q(417,22,{3:1,34:1,22:1,417:1},_s);var dq,fq,pq,mq,sDt=aS(mL,`RectangleStripOverlapRemover/OverlapRemovalDirection`,417,eG,mVe,pke),cDt;q(226,1,{226:1},$p),L(mL,`RectangleStripOverlapRemover/RectangleNode`,226),q(1851,1,$P,$fe),Q.Cd=function(e){l3e(this.a,P(e,226))},L(mL,`RectangleStripOverlapRemover/lambda$1$Type`,1851),q(1323,1,GI,ft),Q.Ne=function(e,t){return Ppt(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator`,1323),q(1326,1,{},pt),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$0$Type`,1326),q(1327,1,vF,mt),Q.Mb=function(e){return P(e,332).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$1$Type`,1327),q(1328,1,vF,ht),Q.Mb=function(e){return P(e,332).a},L(gL,`PolyominoCompactor/CornerCasesGreaterThanRestComparator/lambda$2$Type`,1328),q(1321,1,GI,gt),Q.Ne=function(e,t){return klt(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinNumOfExtensionDirectionsComparator`,1321),q(1324,1,{},_t),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/MinNumOfExtensionDirectionsComparator/lambda$0$Type`,1324),q(781,1,GI,vt),Q.Ne=function(e,t){return EXe(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinNumOfExtensionsComparator`,781),q(1319,1,GI,yt),Q.Ne=function(e,t){return VJe(P(e,330),P(t,330))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinPerimeterComparator`,1319),q(1320,1,GI,bt),Q.Ne=function(e,t){return h4e(P(e,330),P(t,330))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/MinPerimeterComparatorWithShape`,1320),q(1322,1,GI,xt),Q.Ne=function(e,t){return dut(P(e,176),P(t,176))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gL,`PolyominoCompactor/SingleExtensionSideGreaterThanRestComparator`,1322),q(1325,1,{},St),Q.Kb=function(e){return P(e,334).a},L(gL,`PolyominoCompactor/SingleExtensionSideGreaterThanRestComparator/lambda$0$Type`,1325),q(782,1,{},vs),Q.Ve=function(e,t){return YBe(this,P(e,42),P(t,176))},L(gL,`SuccessorCombination`,782),q(649,1,{},Ct),Q.Ve=function(e,t){var n;return Int((n=P(e,42),P(t,176),n))},L(gL,`SuccessorJitter`,649),q(648,1,{},wt),Q.Ve=function(e,t){var n;return cst((n=P(e,42),P(t,176),n))},L(gL,`SuccessorLineByLine`,648),q(573,1,{},Tt),Q.Ve=function(e,t){var n;return Pit((n=P(e,42),P(t,176),n))},L(gL,`SuccessorManhattan`,573),q(1344,1,{},Et),Q.Ve=function(e,t){var n;return Cot((n=P(e,42),P(t,176),n))},L(gL,`SuccessorMaxNormWindingInMathPosSense`,1344),q(409,1,{},or),Q.Ve=function(e,t){return bPe(this,e,t)},Q.c=!1,Q.d=!1,Q.e=!1,Q.f=!1,L(gL,`SuccessorQuadrantsGeneric`,409),q(1345,1,{},Dt),Q.Kb=function(e){return P(e,334).a},L(gL,`SuccessorQuadrantsGeneric/lambda$0$Type`,1345),q(332,22,{3:1,34:1,22:1,332:1},ys),Q.a=!1;var hq,gq,_q,vq,lDt=aS(xL,Vyt,332,eG,fVe,mke),uDt;q(1317,1,{}),Q.Ib=function(){var e,t,n=` `,r,i,a;for(e=G(0),i=0;i=0?`b`+e+`[`+cy(this.a)+`]`:`b[`+cy(this.a)+`]`):`b_`+td(this)},L(HL,`FBendpoint`,250),q(290,137,{3:1,290:1,96:1,137:1},tOe),Q.Ib=function(){return cy(this)},L(HL,`FEdge`,290),q(235,137,{3:1,235:1,96:1,137:1},Py);var TDt=L(HL,`FGraph`,235);q(454,309,{3:1,454:1,309:1,96:1,137:1},$Ve),Q.Ib=function(){return this.b==null||this.b.length==0?`l[`+cy(this.a)+`]`:`l_`+this.b},L(HL,`FLabel`,454),q(153,309,{3:1,153:1,309:1,96:1,137:1},Ewe),Q.Ib=function(){return Gze(this)},Q.a=0,L(HL,`FNode`,153),q(2100,1,{}),Q.vf=function(e){Edt(this,e)},Q.wf=function(){x3e(this)},Q.d=0,L(ibt,`AbstractForceModel`,2100),q(641,2100,{641:1},XYe),Q.uf=function(e,t){var n,i,a,o,s;return dmt(this.f,e,t),a=ef(xu(t.d),e.d),s=r.Math.sqrt(a.a*a.a+a.b*a.b),i=r.Math.max(0,s-Ih(e.e)/2-Ih(t.e)/2),n=Hnt(this.e,e,t),o=n>0?-EPe(i,this.c)*n:xEe(i,this.b)*P(K(e,(XM(),Xq)),17).a,ku(a,o/s),a},Q.vf=function(e){Edt(this,e),this.a=P(K(e,(XM(),Gq)),17).a,this.c=D(N(K(e,$q))),this.b=D(N(K(e,Zq)))},Q.xf=function(e){return e0&&(o-=tve(i,this.a)*n),ku(a,o*this.b/s),a},Q.vf=function(e){var t,n,i,a,o,s,c;for(Edt(this,e),this.b=D(N(K(e,(XM(),eJ)))),this.c=this.b/P(K(e,Gq),17).a,i=e.e.c.length,o=0,a=0,c=new w(e.e);c.a0},Q.a=0,Q.b=0,Q.c=0,L(ibt,`FruchtermanReingoldModel`,642),q(860,1,nL,aue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UL),``),`Force Model`),`Determines the model for force calculation.`),Bq),(VA(),B3)),Uq),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,abt),``),`Iterations`),`The number of iterations on the force model.`),G(300)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,obt),``),`Repulsive Power`),`Determines how many bend points are added to the edge; such bend points are regarded as repelling particles in the force model`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WL),``),`FR Temperature`),`The temperature is used as a scaling factor for particle displacements.`),GL),z3),TG),sE(F3)))),wv(e,WL,UL,MDt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,KL),``),`Eades Repulsion`),`Factor for repulsive forces in Eades' model.`),5),z3),TG),sE(F3)))),wv(e,KL,UL,kDt),y_t((new oue,e))};var EDt,DDt,Bq,ODt,kDt,ADt,jDt,MDt;L(qL,`ForceMetaDataProvider`,860),q(432,22,{3:1,34:1,22:1,432:1},Ss);var Vq,Hq,Uq=aS(qL,`ForceModelStrategy`,432,eG,uLe,_ke),NDt;q(DF,1,nL,oue),Q.hf=function(e){y_t(e)};var PDt,FDt,Wq,Gq,Kq,IDt,LDt,RDt,zDt,qq,BDt,Jq,Yq,VDt,Xq,HDt,Zq,Qq,UDt,WDt,$q,eJ,GDt,KDt,qDt,tJ,JDt;L(qL,`ForceOptions`,DF),q(1001,1,{},aee),Q.sf=function(){var e;return e=new Fge,e},Q.tf=function(e){},L(qL,`ForceOptions/ForceFactory`,1001);var nJ,rJ,iJ,aJ;q(861,1,nL,sue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dbt),``),`Fixed Position`),`Prevent that the node is moved by the layout algorithm.`),(rd(),!1)),(VA(),R3)),bG),sE((uO(),P3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fbt),``),`Desired Edge Length`),`Either specified for parent nodes or for individual edges, where the latter takes higher precedence.`),100),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[M3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pbt),``),`Layout Dimension`),`Dimensions that are permitted to be altered during layout.`),oJ),B3),_J),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mbt),``),`Stress Epsilon`),`Termination criterion for the iterative process.`),GL),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hbt),``),`Iteration Limit`),`Maximum number of performed iterations. Takes higher precedence than 'epsilon'.`),G(AP)),H3),DG),sE(F3)))),Cht((new cue,e))};var YDt,XDt,oJ,ZDt,QDt,$Dt;L(qL,`StressMetaDataProvider`,861),q(1004,1,nL,cue),Q.hf=function(e){Cht(e)};var sJ,cJ,lJ,uJ,dJ,fJ,eOt,tOt,nOt,rOt,pJ,iOt;L(qL,`StressOptions`,1004),q(1005,1,{},ree),Q.sf=function(){var e;return e=new nOe,e},Q.tf=function(e){},L(qL,`StressOptions/StressFactory`,1005),q(1110,205,OL,nOe),Q.rf=function(e,t){var n,r,i,a,o;for(t.Ug(gbt,1),ki(Od(J(e,(Nk(),dJ))))?ki(Od(J(e,pJ)))||S_((n=new ir((Ko(),new Ei(e))),n)):wat(new Fge,e,t.eh(1)),i=fZe(e),r=nft(this.a,i),o=r.Kc();o.Ob();)a=P(o.Pb(),235),!(a.e.c.length<=1)&&(kpt(this.b,a),kit(this.b),Dx(a.d,new iee));i=f_t(r),Y_t(i),t.Vg()},L(_R,`StressLayoutProvider`,1110),q(1111,1,$P,iee),Q.Cd=function(e){Hft(P(e,454))},L(_R,`StressLayoutProvider/lambda$0$Type`,1111),q(1002,1,{},Tge),Q.c=0,Q.e=0,Q.g=0,L(_R,`StressMajorization`,1002),q(391,22,{3:1,34:1,22:1,391:1},Cs);var mJ,hJ,gJ,_J=aS(_R,`StressMajorization/Dimension`,391,eG,XRe,vke),aOt;q(1003,1,GI,rpe),Q.Ne=function(e,t){return kOe(this.a,P(e,153),P(t,153))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(_R,`StressMajorization/lambda$0$Type`,1003),q(1192,1,{},Qze),L(vR,`ElkLayered`,1192),q(1193,1,$P,ipe),Q.Cd=function(e){Ltt(this.a,P(e,36))},L(vR,`ElkLayered/lambda$0$Type`,1193),q(1194,1,$P,ape),Q.Cd=function(e){AOe(this.a,P(e,36))},L(vR,`ElkLayered/lambda$1$Type`,1194),q(1281,1,{},Hwe);var oOt,sOt,cOt;L(vR,`GraphConfigurator`,1281),q(770,1,$P,cr),Q.Cd=function(e){T9e(this.a,P(e,10))},L(vR,`GraphConfigurator/lambda$0$Type`,770),q(771,1,{},Ht),Q.Kb=function(e){return i8e(),new Mp(null,new cv(P(e,30).a,16))},L(vR,`GraphConfigurator/lambda$1$Type`,771),q(772,1,$P,lr),Q.Cd=function(e){T9e(this.a,P(e,10))},L(vR,`GraphConfigurator/lambda$2$Type`,772),q(1109,205,OL,Uge),Q.rf=function(e,t){var n=$ft(new Gge,e);A(J(e,(mP(),D1)))===A((_T(),g8))?v1e(this.a,n,t):Cit(this.a,n,t),t.$g()||Lgt(new lue,n)},L(vR,`LayeredLayoutProvider`,1109),q(367,22,{3:1,34:1,22:1,367:1},ws);var vJ,yJ,bJ,xJ,SJ,CJ=aS(vR,`LayeredPhases`,367,eG,iUe,yke),lOt;q(1717,1,{},CJe),Q.i=0;var uOt;L(yR,`ComponentsToCGraphTransformer`,1717);var dOt;q(1718,1,{},nee),Q.yf=function(e,t){return r.Math.min(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},Q.zf=function(e,t){return r.Math.min(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},L(yR,`ComponentsToCGraphTransformer/1`,1718),q(86,1,{86:1}),Q.i=0,Q.k=!0,Q.o=lI;var wJ=L(bR,`CNode`,86);q(470,86,{470:1,86:1},cEe,ZD),Q.Ib=function(){return``},L(yR,`ComponentsToCGraphTransformer/CRectNode`,470),q(1688,1,{},oee);var TJ,EJ;L(yR,`OneDimensionalComponentsCompaction`,1688),q(1689,1,{},see),Q.Kb=function(e){return NRe(P(e,42))},Q.Fb=function(e){return this===e},L(yR,`OneDimensionalComponentsCompaction/lambda$0$Type`,1689),q(1690,1,{},cee),Q.Kb=function(e){return b1e(P(e,42))},Q.Fb=function(e){return this===e},L(yR,`OneDimensionalComponentsCompaction/lambda$1$Type`,1690),q(1720,1,{},nFe),L(bR,`CGraph`,1720),q(194,1,{194:1},QD),Q.b=0,Q.c=0,Q.e=0,Q.g=!0,Q.i=lI,L(bR,`CGroup`,194),q(1719,1,{},lee),Q.yf=function(e,t){return r.Math.max(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},Q.zf=function(e,t){return r.Math.max(e.a==null?e.c.i:D(e.a),t.a==null?t.c.i:D(t.a))},L(bR,Syt,1719),q(1721,1,{},Ynt),Q.d=!1;var fOt,DJ=L(bR,Tyt,1721);q(1722,1,{},uee),Q.Kb=function(e){return Nbe(),rd(),P(P(e,42).a,86).d.e!=0},Q.Fb=function(e){return this===e},L(bR,Eyt,1722),q(833,1,{},kp),Q.a=!1,Q.b=!1,Q.c=!1,Q.d=!1,L(bR,Dyt,833),q(1898,1,{},vNe),L(xR,Oyt,1898);var OJ=gp(SR,byt);q(1899,1,{382:1},XIe),Q.bf=function(e){Fst(this,P(e,476))},L(xR,kyt,1899),q(VF,1,GI,dee),Q.Ne=function(e,t){return eIe(P(e,86),P(t,86))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(xR,Ayt,VF),q(476,1,{476:1},Axe),Q.a=!1,L(xR,jyt,476),q(1901,1,GI,fee),Q.Ne=function(e,t){return r8e(P(e,476),P(t,476))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(xR,Myt,1901),q(148,1,{148:1},js,Pje),Q.Fb=function(e){var t;return e==null||pOt!=$w(e)?!1:(t=P(e,148),rg(this.c,t.c)&&rg(this.d,t.d))},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.c,this.d]))},Q.Ib=function(){return`(`+this.c+PP+this.d+(this.a?`cx`:``)+this.b+`)`},Q.a=!0,Q.c=0,Q.d=0;var pOt=L(SR,`Point`,148);q(416,22,{3:1,34:1,22:1,416:1},Es);var kJ,AJ,jJ,MJ,mOt=aS(SR,`Point/Quadrant`,416,eG,hVe,bke),hOt;q(1708,1,{},Bge),Q.b=null,Q.c=null,Q.d=null,Q.e=null,Q.f=null;var gOt,_Ot,vOt,yOt,bOt;L(SR,`RectilinearConvexHull`,1708),q(583,1,{382:1},xO),Q.bf=function(e){xGe(this,P(e,148))},Q.b=0;var NJ;L(SR,`RectilinearConvexHull/MaximalElementsEventHandler`,583),q(1710,1,GI,pee),Q.Ne=function(e,t){return tIe(N(e),N(t))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/MaximalElementsEventHandler/lambda$0$Type`,1710),q(1709,1,{382:1},qKe),Q.bf=function(e){Oot(this,P(e,148))},Q.a=0,Q.b=null,Q.c=null,Q.d=null,Q.e=null,L(SR,`RectilinearConvexHull/RectangleEventHandler`,1709),q(1711,1,GI,mee),Q.Ne=function(e,t){return Bze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$0$Type`,1711),q(1712,1,GI,_ee),Q.Ne=function(e,t){return Vze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$1$Type`,1712),q(1713,1,GI,vee),Q.Ne=function(e,t){return zze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$2$Type`,1713),q(1714,1,GI,gee),Q.Ne=function(e,t){return Hze(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$3$Type`,1714),q(1715,1,GI,yee),Q.Ne=function(e,t){return X7e(P(e,148),P(t,148))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(SR,`RectilinearConvexHull/lambda$4$Type`,1715),q(1716,1,{},SRe),L(SR,`Scanline`,1716),q(2104,1,{}),L(CR,`AbstractGraphPlacer`,2104),q(335,1,{335:1},MEe),Q.Ff=function(e){return this.Gf(e)?(fj(this.b,P(K(e,(Y(),SQ)),21),e),!0):!1},Q.Gf=function(e){var t=P(K(e,(Y(),SQ)),21),n,r;for(r=P(Dy(PJ,t),21).Kc();r.Ob();)if(n=P(r.Pb(),21),!P(Dy(this.b,n),15).dc())return!1;return!0};var PJ;L(CR,`ComponentGroup`,335),q(779,2104,{},Vge),Q.Hf=function(e){var t,n;for(n=new w(this.a);n.an&&(d=0,f+=c+i,c=0),l=o.c,kM(o,d+l.a,f+l.b),Cl(l),a=r.Math.max(a,d+u.a),c=r.Math.max(c,u.b),d+=u.a+i;t.f.a=a,t.f.b=f+c},Q.Jf=function(e,t){var n,r,i,a,o;if(A(K(t,(mP(),t1)))===A((YD(),RJ))){for(r=e.Kc();r.Ob();){for(n=P(r.Pb(),36),o=0,a=new w(n.a);a.an&&!P(K(o,(Y(),SQ)),21).Hc((nP(),Z8))||l&&P(K(l,(Y(),SQ)),21).Hc((nP(),X8))||P(K(o,(Y(),SQ)),21).Hc((nP(),g5)))&&(p=f,m+=c+i,c=0),u=o.c,P(K(o,(Y(),SQ)),21).Hc((nP(),Z8))&&(p=a+i),kM(o,p+u.a,m+u.b),a=r.Math.max(a,p+d.a),P(K(o,SQ),21).Hc(m5)&&(f=r.Math.max(f,p+d.a+i)),Cl(u),c=r.Math.max(c,d.b),p+=d.a+i,l=o;t.f.a=a,t.f.b=m+c},Q.Jf=function(e,t){},L(CR,`ModelOrderRowGraphPlacer`,1313),q(1311,1,GI,See),Q.Ne=function(e,t){return _Xe(P(e,36),P(t,36))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(CR,`SimpleRowGraphPlacer/1`,1311);var SOt;q(1280,1,YI,Cee),Q.Lb=function(e){var t;return t=P(K(P(e,249).b,(mP(),j1)),75),!!t&&t.b!=0},Q.Fb=function(e){return this===e},Q.Mb=function(e){var t;return t=P(K(P(e,249).b,(mP(),j1)),75),!!t&&t.b!=0},L(ER,`CompoundGraphPostprocessor/1`,1280),q(1279,1,DR,Kge),Q.Kf=function(e,t){v4e(this,P(e,36),t)},L(ER,`CompoundGraphPreprocessor`,1279),q(453,1,{453:1},W$e),Q.c=!1,L(ER,`CompoundGraphPreprocessor/ExternalPort`,453),q(249,1,{249:1},kf),Q.Ib=function(){return bd(this.c)+`:`+Cnt(this.b)},L(ER,`CrossHierarchyEdge`,249),q(777,1,GI,ur),Q.Ne=function(e,t){return u6e(this,P(e,249),P(t,249))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(ER,`CrossHierarchyEdgeComparator`,777),q(305,137,{3:1,305:1,96:1,137:1}),Q.p=0,L(OR,`LGraphElement`,305),q(18,305,{3:1,18:1,305:1,96:1,137:1},i_),Q.Ib=function(){return Cnt(this)};var VJ=L(OR,`LEdge`,18);q(36,305,{3:1,20:1,36:1,305:1,96:1,137:1},wJe),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new w(this.b)},Q.Ib=function(){return this.b.c.length==0?`G-unlayered`+CA(this.a):this.a.c.length==0?`G-layered`+CA(this.b):`G[layerless`+CA(this.a)+`, layers`+CA(this.b)+`]`};var COt=L(OR,`LGraph`,36),wOt;q(666,1,{}),Q.Lf=function(){return this.e.n},Q.of=function(e){return K(this.e,e)},Q.Mf=function(){return this.e.o},Q.Nf=function(){return this.e.p},Q.pf=function(e){return yd(this.e,e)},Q.Of=function(e){this.e.n.a=e.a,this.e.n.b=e.b},Q.Pf=function(e){this.e.o.a=e.a,this.e.o.b=e.b},Q.Qf=function(e){this.e.p=e},L(OR,`LGraphAdapters/AbstractLShapeAdapter`,666),q(474,1,{853:1},dr),Q.Rf=function(){var e,t;if(!this.b)for(this.b=dd(this.a.b.c.length),t=new w(this.a.b);t.a0&&WQe((sv(t-1,e.length),e.charCodeAt(t-1)),wbt);)--t;if(a> `,e),Sk(n)),gl(hl((e.a+=`[`,e),n.i),`]`)),e.a},Q.c=!0,Q.d=!1;var QJ,$J,eY,tY,nY,rY,EOt=L(OR,`LPort`,12);q(408,1,rF,pr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new ope(new w(this.a.e))},L(OR,`LPort/1`,408),q(1309,1,VP,ope),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(z(this.a),18).c},Q.Ob=function(){return gu(this.a)},Q.Qb=function(){Gm(this.a)},L(OR,`LPort/1/1`,1309),q(369,1,rF,mr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){var e;return e=new w(this.a.g),new spe(e)},L(OR,`LPort/2`,369),q(776,1,VP,spe),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(z(this.a),18).d},Q.Ob=function(){return gu(this.a)},Q.Qb=function(){Gm(this.a)},L(OR,`LPort/2/1`,776),q(1302,1,rF,wxe),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new Ny(this)},L(OR,`LPort/CombineIter`,1302),q(208,1,VP,Ny),Q.Nb=function(e){Om(this,e)},Q.Qb=function(){uye()},Q.Ob=function(){return ed(this)},Q.Pb=function(){return gu(this.a)?z(this.a):z(this.b)},L(OR,`LPort/CombineIter/1`,208),q(1303,1,YI,Tee),Q.Lb=function(e){return ZNe(e)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).g.c.length!=0},L(OR,`LPort/lambda$0$Type`,1303),q(1304,1,YI,Eee),Q.Lb=function(e){return QNe(e)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).e.c.length!=0},L(OR,`LPort/lambda$1$Type`,1304),q(1305,1,YI,Dee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),Z8)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),Z8)},L(OR,`LPort/lambda$2$Type`,1305),q(1306,1,YI,Oee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),X8)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),X8)},L(OR,`LPort/lambda$3$Type`,1306),q(1307,1,YI,kee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),m5)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),m5)},L(OR,`LPort/lambda$4$Type`,1307),q(1308,1,YI,Aee),Q.Lb=function(e){return fC(),P(e,12).j==(nP(),g5)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return fC(),P(e,12).j==(nP(),g5)},L(OR,`LPort/lambda$5$Type`,1308),q(30,305,{3:1,20:1,305:1,30:1,96:1,137:1},Eh),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return new w(this.a)},Q.Ib=function(){return`L_`+Ab(this.b.b,this,0)+CA(this.a)},L(OR,`Layer`,30),q(1330,1,{},Gge),L(NR,Obt,1330),q(1334,1,{},jee),Q.Kb=function(e){return cA(P(e,84))},L(NR,`ElkGraphImporter/0methodref$connectableShapeToNode$Type`,1334),q(1337,1,{},Mee),Q.Kb=function(e){return cA(P(e,84))},L(NR,`ElkGraphImporter/1methodref$connectableShapeToNode$Type`,1337),q(1331,1,$P,cpe),Q.Cd=function(e){frt(this.a,P(e,123))},L(NR,nbt,1331),q(1332,1,$P,lpe),Q.Cd=function(e){frt(this.a,P(e,123))},L(NR,kbt,1332),q(1333,1,{},Nee),Q.Kb=function(e){return new Mp(null,new cv(sg(P(e,74)),16))},L(NR,Abt,1333),q(1335,1,vF,upe),Q.Mb=function(e){return XCe(this.a,P(e,27))},L(NR,jbt,1335),q(1336,1,{},Pee),Q.Kb=function(e){return new Mp(null,new cv(KFe(P(e,74)),16))},L(NR,`ElkGraphImporter/lambda$5$Type`,1336),q(1338,1,vF,dpe),Q.Mb=function(e){return ZCe(this.a,P(e,27))},L(NR,`ElkGraphImporter/lambda$7$Type`,1338),q(1339,1,vF,Fee),Q.Mb=function(e){return wIe(P(e,74))},L(NR,`ElkGraphImporter/lambda$8$Type`,1339),q(1297,1,{},lue);var DOt;L(NR,`ElkGraphLayoutTransferrer`,1297),q(1298,1,vF,fpe),Q.Mb=function(e){return XDe(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$0$Type`,1298),q(1299,1,$P,ppe),Q.Cd=function(e){Io(),M(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$1$Type`,1299),q(1300,1,vF,mpe),Q.Mb=function(e){return yDe(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$2$Type`,1300),q(1301,1,$P,hpe),Q.Cd=function(e){Io(),M(this.a,P(e,18))},L(NR,`ElkGraphLayoutTransferrer/lambda$3$Type`,1301),q(819,1,{},Zd),L(PR,`BiLinkedHashMultiMap`,819),q(1550,1,DR,Iee),Q.Kf=function(e,t){cYe(P(e,36),t)},L(PR,`CommentNodeMarginCalculator`,1550),q(1551,1,{},Lee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`CommentNodeMarginCalculator/lambda$0$Type`,1551),q(1552,1,$P,Ree),Q.Cd=function(e){Zft(P(e,10))},L(PR,`CommentNodeMarginCalculator/lambda$1$Type`,1552),q(1553,1,DR,zee),Q.Kf=function(e,t){qst(P(e,36),t)},L(PR,`CommentPostprocessor`,1553),q(1554,1,DR,Bee),Q.Kf=function(e,t){Tgt(P(e,36),t)},L(PR,`CommentPreprocessor`,1554),q(1555,1,DR,Vee),Q.Kf=function(e,t){Hot(P(e,36),t)},L(PR,`ConstraintsPostprocessor`,1555),q(1556,1,DR,Hee),Q.Kf=function(e,t){aXe(P(e,36),t)},L(PR,`EdgeAndLayerConstraintEdgeReverser`,1556),q(1557,1,DR,Uee),Q.Kf=function(e,t){u0e(P(e,36),t)},L(PR,`EndLabelPostprocessor`,1557),q(1558,1,{},Wee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelPostprocessor/lambda$0$Type`,1558),q(1559,1,vF,Gee),Q.Mb=function(e){return YHe(P(e,10))},L(PR,`EndLabelPostprocessor/lambda$1$Type`,1559),q(1560,1,$P,Kee),Q.Cd=function(e){a8e(P(e,10))},L(PR,`EndLabelPostprocessor/lambda$2$Type`,1560),q(1561,1,DR,qee),Q.Kf=function(e,t){Ket(P(e,36),t)},L(PR,`EndLabelPreprocessor`,1561),q(1562,1,{},Jee),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelPreprocessor/lambda$0$Type`,1562),q(1563,1,$P,Cke),Q.Cd=function(e){Vbe(this.a,this.b,this.c,P(e,10))},Q.a=0,Q.b=0,Q.c=!1,L(PR,`EndLabelPreprocessor/lambda$1$Type`,1563),q(1564,1,vF,Yee),Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),c8))},L(PR,`EndLabelPreprocessor/lambda$2$Type`,1564),q(1565,1,$P,gpe),Q.Cd=function(e){up(this.a,P(e,72))},L(PR,`EndLabelPreprocessor/lambda$3$Type`,1565),q(1566,1,vF,Xee),Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),s8))},L(PR,`EndLabelPreprocessor/lambda$4$Type`,1566),q(1567,1,$P,_pe),Q.Cd=function(e){up(this.a,P(e,72))},L(PR,`EndLabelPreprocessor/lambda$5$Type`,1567),q(1615,1,DR,tue),Q.Kf=function(e,t){Z$e(P(e,36),t)};var OOt;L(PR,`EndLabelSorter`,1615),q(1616,1,GI,Zee),Q.Ne=function(e,t){return m2e(P(e,466),P(t,466))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`EndLabelSorter/1`,1616),q(466,1,{466:1},LIe),L(PR,`EndLabelSorter/LabelGroup`,466),q(1617,1,{},Qee),Q.Kb=function(e){return Fo(),new Mp(null,new cv(P(e,30).a,16))},L(PR,`EndLabelSorter/lambda$0$Type`,1617),q(1618,1,vF,$ee),Q.Mb=function(e){return Fo(),P(e,10).k==(DA(),JJ)},L(PR,`EndLabelSorter/lambda$1$Type`,1618),q(1619,1,$P,ete),Q.Cd=function(e){E9e(P(e,10))},L(PR,`EndLabelSorter/lambda$2$Type`,1619),q(1620,1,vF,tte),Q.Mb=function(e){return Fo(),A(K(P(e,72),(mP(),b1)))===A((Lx(),s8))},L(PR,`EndLabelSorter/lambda$3$Type`,1620),q(1621,1,vF,nte),Q.Mb=function(e){return Fo(),A(K(P(e,72),(mP(),b1)))===A((Lx(),c8))},L(PR,`EndLabelSorter/lambda$4$Type`,1621),q(1568,1,DR,rte),Q.Kf=function(e,t){xpt(this,P(e,36))},Q.b=0,Q.c=0,L(PR,`FinalSplineBendpointsCalculator`,1568),q(1569,1,{},ite),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`FinalSplineBendpointsCalculator/lambda$0$Type`,1569),q(1570,1,{},ate),Q.Kb=function(e){return new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(PR,`FinalSplineBendpointsCalculator/lambda$1$Type`,1570),q(1571,1,vF,ote),Q.Mb=function(e){return!gy(P(e,18))},L(PR,`FinalSplineBendpointsCalculator/lambda$2$Type`,1571),q(1572,1,vF,ste),Q.Mb=function(e){return yd(P(e,18),(Y(),l$))},L(PR,`FinalSplineBendpointsCalculator/lambda$3$Type`,1572),q(1573,1,$P,vpe),Q.Cd=function(e){hut(this.a,P(e,131))},L(PR,`FinalSplineBendpointsCalculator/lambda$4$Type`,1573),q(1574,1,$P,cte),Q.Cd=function(e){JA(P(e,18).a)},L(PR,`FinalSplineBendpointsCalculator/lambda$5$Type`,1574),q(803,1,DR,ype),Q.Kf=function(e,t){Dmt(this,P(e,36),t)},L(PR,`GraphTransformer`,803),q(517,22,{3:1,34:1,22:1,517:1},xxe);var iY,aY,kOt=aS(PR,`GraphTransformer/Mode`,517,eG,dLe,OAe),AOt;q(1575,1,DR,lte),Q.Kf=function(e,t){Fat(P(e,36),t)},L(PR,`HierarchicalNodeResizingProcessor`,1575),q(1576,1,DR,ute),Q.Kf=function(e,t){XJe(P(e,36),t)},L(PR,`HierarchicalPortConstraintProcessor`,1576),q(1577,1,GI,dte),Q.Ne=function(e,t){return Q2e(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortConstraintProcessor/NodeComparator`,1577),q(1578,1,DR,fte),Q.Kf=function(e,t){qdt(P(e,36),t)},L(PR,`HierarchicalPortDummySizeProcessor`,1578),q(1579,1,DR,pte),Q.Kf=function(e,t){Fct(this,P(e,36),t)},Q.a=0,L(PR,`HierarchicalPortOrthogonalEdgeRouter`,1579),q(1580,1,GI,mte),Q.Ne=function(e,t){return ZTe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortOrthogonalEdgeRouter/1`,1580),q(1581,1,GI,hte),Q.Ne=function(e,t){return wGe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`HierarchicalPortOrthogonalEdgeRouter/2`,1581),q(1582,1,DR,gte),Q.Kf=function(e,t){W7e(P(e,36),t)},L(PR,`HierarchicalPortPositionProcessor`,1582),q(1583,1,DR,uue),Q.Kf=function(e,t){T_t(this,P(e,36))},Q.a=0,Q.c=0;var oY,sY;L(PR,`HighDegreeNodeLayeringProcessor`,1583),q(580,1,{580:1},_te),Q.b=-1,Q.d=-1,L(PR,`HighDegreeNodeLayeringProcessor/HighDegreeNodeInformation`,580),q(1584,1,{},vte),Q.Kb=function(e){return Ff(),DE(P(e,10))},Q.Fb=function(e){return this===e},L(PR,`HighDegreeNodeLayeringProcessor/lambda$0$Type`,1584),q(1585,1,{},yte),Q.Kb=function(e){return Ff(),OE(P(e,10))},Q.Fb=function(e){return this===e},L(PR,`HighDegreeNodeLayeringProcessor/lambda$1$Type`,1585),q(1591,1,DR,bte),Q.Kf=function(e,t){jdt(this,P(e,36),t)},L(PR,`HyperedgeDummyMerger`,1591),q(804,1,{},jf),Q.a=!1,Q.b=!1,Q.c=!1,L(PR,`HyperedgeDummyMerger/MergeState`,804),q(1592,1,{},xte),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`HyperedgeDummyMerger/lambda$0$Type`,1592),q(1593,1,{},Ste),Q.Kb=function(e){return new Mp(null,new cv(P(e,10).j,16))},L(PR,`HyperedgeDummyMerger/lambda$1$Type`,1593),q(1594,1,$P,Cte),Q.Cd=function(e){P(e,12).p=-1},L(PR,`HyperedgeDummyMerger/lambda$2$Type`,1594),q(1595,1,DR,wte),Q.Kf=function(e,t){kdt(P(e,36),t)},L(PR,`HypernodesProcessor`,1595),q(1596,1,DR,Tte),Q.Kf=function(e,t){Kdt(P(e,36),t)},L(PR,`InLayerConstraintProcessor`,1596),q(1597,1,DR,Ete),Q.Kf=function(e,t){AYe(P(e,36),t)},L(PR,`InnermostNodeMarginCalculator`,1597),q(1598,1,DR,Dte),Q.Kf=function(e,t){xgt(this,P(e,36))},Q.a=lI,Q.b=lI,Q.c=cI,Q.d=cI;var jOt=L(PR,`InteractiveExternalPortPositioner`,1598);q(1599,1,{},Ote),Q.Kb=function(e){return P(e,18).d.i},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$0$Type`,1599),q(1600,1,{},bpe),Q.Kb=function(e){return QTe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$1$Type`,1600),q(1601,1,{},kte),Q.Kb=function(e){return P(e,18).c.i},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$2$Type`,1601),q(1602,1,{},xpe),Q.Kb=function(e){return $Te(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$3$Type`,1602),q(1603,1,{},Spe),Q.Kb=function(e){return dOe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$4$Type`,1603),q(1604,1,{},Cpe),Q.Kb=function(e){return fOe(this.a,N(e))},Q.Fb=function(e){return this===e},L(PR,`InteractiveExternalPortPositioner/lambda$5$Type`,1604),q(81,22,{3:1,34:1,22:1,81:1,196:1},ks),Q.dg=function(){switch(this.g){case 15:return new qre;case 22:return new Jre;case 47:return new Zre;case 28:case 35:return new Bte;case 32:return new Iee;case 42:return new zee;case 1:return new Bee;case 41:return new Vee;case 56:return new ype((dC(),aY));case 0:return new ype((dC(),iY));case 2:return new Hee;case 54:return new Uee;case 33:return new qee;case 51:return new rte;case 55:return new lte;case 13:return new ute;case 38:return new fte;case 44:return new pte;case 40:return new gte;case 9:return new uue;case 49:return new oEe;case 37:return new bte;case 43:return new wte;case 27:return new Tte;case 30:return new Ete;case 3:return new Dte;case 18:return new jte;case 29:return new Mte;case 5:return new due;case 50:return new Ate;case 34:return new fue;case 36:return new Vte;case 52:return new tue;case 11:return new Hte;case 7:return new pue;case 39:return new Ute;case 45:return new Wte;case 16:return new Gte;case 10:return new Jxe;case 48:return new Yte;case 21:return new Xte;case 23:return new Ti((sS(),g2));case 8:return new Qte;case 12:return new ene;case 4:return new tne;case 19:return new yue;case 17:return new dne;case 53:return new fne;case 6:return new wne;case 25:return new Yge;case 46:return new _ne;case 31:return new oOe;case 14:return new Mne;case 26:return new iie;case 20:return new Lne;case 24:return new Ti((sS(),_2));default:throw E(new Fi(FR+(this.f==null?``+this.g:this.f)))}};var cY,lY,uY,dY,fY,pY,mY,hY,gY,_Y,vY,yY,bY,xY,SY,CY,wY,TY,EY,DY,OY,kY,AY,jY,MY,NY,PY,FY,IY,LY,RY,zY,BY,VY,HY,UY,WY,GY,KY,qY,JY,YY,XY,ZY,QY,$Y,eX,tX,nX,rX,iX,aX,oX,sX,cX,lX,uX,MOt=aS(PR,IR,81,eG,wot,Dke),NOt;q(1605,1,DR,jte),Q.Kf=function(e,t){ygt(P(e,36),t)},L(PR,`InvertedPortProcessor`,1605),q(1606,1,DR,Mte),Q.Kf=function(e,t){tut(P(e,36),t)},L(PR,`LabelAndNodeSizeProcessor`,1606),q(1607,1,vF,Nte),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`LabelAndNodeSizeProcessor/lambda$0$Type`,1607),q(1608,1,vF,Pte),Q.Mb=function(e){return P(e,10).k==(DA(),GJ)},L(PR,`LabelAndNodeSizeProcessor/lambda$1$Type`,1608),q(1609,1,$P,wke),Q.Cd=function(e){Hbe(this.b,this.a,this.c,P(e,10))},Q.a=!1,Q.c=!1,L(PR,`LabelAndNodeSizeProcessor/lambda$2$Type`,1609),q(1610,1,DR,due),Q.Kf=function(e,t){Lht(P(e,36),t)};var POt;L(PR,`LabelDummyInserter`,1610),q(1611,1,YI,Fte),Q.Lb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),o8))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return A(K(P(e,72),(mP(),b1)))===A((Lx(),o8))},L(PR,`LabelDummyInserter/1`,1611),q(1612,1,DR,Ate),Q.Kf=function(e,t){ght(P(e,36),t)},L(PR,`LabelDummyRemover`,1612),q(1613,1,vF,Ite),Q.Mb=function(e){return ki(Od(K(P(e,72),(mP(),y1))))},L(PR,`LabelDummyRemover/lambda$0$Type`,1613),q(1378,1,DR,fue),Q.Kf=function(e,t){rht(this,P(e,36),t)},Q.a=null;var dX;L(PR,`LabelDummySwitcher`,1378),q(293,1,{293:1},Ilt),Q.c=0,Q.d=null,Q.f=0,L(PR,`LabelDummySwitcher/LabelDummyInfo`,293),q(1379,1,{},Lte),Q.Kb=function(e){return cC(),new Mp(null,new cv(P(e,30).a,16))},L(PR,`LabelDummySwitcher/lambda$0$Type`,1379),q(1380,1,vF,Rte),Q.Mb=function(e){return cC(),P(e,10).k==(DA(),KJ)},L(PR,`LabelDummySwitcher/lambda$1$Type`,1380),q(1381,1,{},wpe),Q.Kb=function(e){return bDe(this.a,P(e,10))},L(PR,`LabelDummySwitcher/lambda$2$Type`,1381),q(1382,1,$P,Tpe),Q.Cd=function(e){iFe(this.a,P(e,293))},L(PR,`LabelDummySwitcher/lambda$3$Type`,1382),q(1383,1,GI,zte),Q.Ne=function(e,t){return $Ne(P(e,293),P(t,293))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`LabelDummySwitcher/lambda$4$Type`,1383),q(802,1,DR,Bte),Q.Kf=function(e,t){YWe(P(e,36),t)},L(PR,`LabelManagementProcessor`,802),q(1614,1,DR,Vte),Q.Kf=function(e,t){Tst(P(e,36),t)},L(PR,`LabelSideSelector`,1614),q(1622,1,DR,Hte),Q.Kf=function(e,t){_ft(P(e,36),t)},L(PR,`LayerConstraintPostprocessor`,1622),q(1623,1,DR,pue),Q.Kf=function(e,t){tit(P(e,36),t)};var fX;L(PR,`LayerConstraintPreprocessor`,1623),q(371,22,{3:1,34:1,22:1,371:1},As);var pX,mX,hX,gX,FOt=aS(PR,`LayerConstraintPreprocessor/HiddenNodeConnections`,371,eG,_Ve,Oke),IOt;q(1624,1,DR,Ute),Q.Kf=function(e,t){pmt(P(e,36),t)},L(PR,`LayerSizeAndGraphHeightCalculator`,1624),q(1625,1,DR,Wte),Q.Kf=function(e,t){Iat(P(e,36),t)},L(PR,`LongEdgeJoiner`,1625),q(1626,1,DR,Gte),Q.Kf=function(e,t){Ipt(P(e,36),t)},L(PR,`LongEdgeSplitter`,1626),q(1627,1,DR,Jxe),Q.Kf=function(e,t){egt(this,P(e,36),t)},Q.e=0,Q.f=0,Q.j=0,Q.k=0,Q.n=0,Q.o=0;var LOt,ROt;L(PR,`NodePromotion`,1627),q(1628,1,GI,Kte),Q.Ne=function(e,t){return rQe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NodePromotion/1`,1628),q(1629,1,GI,qte),Q.Ne=function(e,t){return iQe(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NodePromotion/2`,1629),q(1630,1,{},Jte),Q.Kb=function(e){return P(e,42),If(),rd(),!0},Q.Fb=function(e){return this===e},L(PR,`NodePromotion/lambda$0$Type`,1630),q(1631,1,{},kpe),Q.Kb=function(e){return sRe(this.a,P(e,42))},Q.Fb=function(e){return this===e},Q.a=0,L(PR,`NodePromotion/lambda$1$Type`,1631),q(1632,1,{},Ape),Q.Kb=function(e){return oRe(this.a,P(e,42))},Q.Fb=function(e){return this===e},Q.a=0,L(PR,`NodePromotion/lambda$2$Type`,1632),q(1633,1,DR,Yte),Q.Kf=function(e,t){m_t(P(e,36),t)},L(PR,`NorthSouthPortPostprocessor`,1633),q(1634,1,DR,Xte),Q.Kf=function(e,t){Hgt(P(e,36),t)},L(PR,`NorthSouthPortPreprocessor`,1634),q(1635,1,GI,Zte),Q.Ne=function(e,t){return vXe(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`NorthSouthPortPreprocessor/lambda$0$Type`,1635),q(1636,1,DR,Qte),Q.Kf=function(e,t){edt(P(e,36),t)},L(PR,`PartitionMidprocessor`,1636),q(1637,1,vF,$te),Q.Mb=function(e){return yd(P(e,10),(mP(),Y1))},L(PR,`PartitionMidprocessor/lambda$0$Type`,1637),q(1638,1,$P,jpe),Q.Cd=function(e){TIe(this.a,P(e,10))},L(PR,`PartitionMidprocessor/lambda$1$Type`,1638),q(1639,1,DR,ene),Q.Kf=function(e,t){uot(P(e,36),t)},L(PR,`PartitionPostprocessor`,1639),q(1640,1,DR,tne),Q.Kf=function(e,t){prt(P(e,36),t)},L(PR,`PartitionPreprocessor`,1640),q(1641,1,vF,nne),Q.Mb=function(e){return yd(P(e,10),(mP(),Y1))},L(PR,`PartitionPreprocessor/lambda$0$Type`,1641),q(1642,1,{},rne),Q.Kb=function(e){return new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(PR,`PartitionPreprocessor/lambda$1$Type`,1642),q(1643,1,vF,ine),Q.Mb=function(e){return C2e(P(e,18))},L(PR,`PartitionPreprocessor/lambda$2$Type`,1643),q(1644,1,$P,ane),Q.Cd=function(e){tZe(P(e,18))},L(PR,`PartitionPreprocessor/lambda$3$Type`,1644),q(1645,1,DR,yue),Q.Kf=function(e,t){Out(P(e,36),t)};var _X,zOt,BOt,VOt,vX,yX;L(PR,`PortListSorter`,1645),q(1648,1,GI,one),Q.Ne=function(e,t){return fHe(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$0$Type`,1648),q(1650,1,GI,sne),Q.Ne=function(e,t){return ydt(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$1$Type`,1650),q(1646,1,{},cne),Q.Kb=function(e){return Fw(),P(e,12).e},L(PR,`PortListSorter/lambda$2$Type`,1646),q(1647,1,{},lne),Q.Kb=function(e){return Fw(),P(e,12).g},L(PR,`PortListSorter/lambda$3$Type`,1647),q(1649,1,GI,une),Q.Ne=function(e,t){return J3e(P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`PortListSorter/lambda$4$Type`,1649),q(1651,1,DR,dne),Q.Kf=function(e,t){xit(P(e,36),t)},L(PR,`PortSideProcessor`,1651),q(1652,1,DR,fne),Q.Kf=function(e,t){llt(P(e,36),t)},L(PR,`ReversedEdgeRestorer`,1652),q(1657,1,DR,Yge),Q.Kf=function(e,t){h3e(this,P(e,36),t)},L(PR,`SelfLoopPortRestorer`,1657),q(1658,1,{},pne),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopPortRestorer/lambda$0$Type`,1658),q(1659,1,vF,mne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopPortRestorer/lambda$1$Type`,1659),q(1660,1,vF,hne),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopPortRestorer/lambda$2$Type`,1660),q(1661,1,{},gne),Q.Kb=function(e){return P(K(P(e,10),(Y(),a$)),337)},L(PR,`SelfLoopPortRestorer/lambda$3$Type`,1661),q(1662,1,$P,Dpe),Q.Cd=function(e){W9e(this.a,P(e,337))},L(PR,`SelfLoopPortRestorer/lambda$4$Type`,1662),q(805,1,$P,Kt),Q.Cd=function(e){det(P(e,105))},L(PR,`SelfLoopPortRestorer/lambda$5$Type`,805),q(1663,1,DR,_ne),Q.Kf=function(e,t){K2e(P(e,36),t)},L(PR,`SelfLoopPostProcessor`,1663),q(1664,1,{},vne),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopPostProcessor/lambda$0$Type`,1664),q(1665,1,vF,yne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopPostProcessor/lambda$1$Type`,1665),q(1666,1,vF,bne),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopPostProcessor/lambda$2$Type`,1666),q(1667,1,$P,xne),Q.Cd=function(e){M8e(P(e,10))},L(PR,`SelfLoopPostProcessor/lambda$3$Type`,1667),q(1668,1,{},Sne),Q.Kb=function(e){return new Mp(null,new cv(P(e,105).f,1))},L(PR,`SelfLoopPostProcessor/lambda$4$Type`,1668),q(1669,1,$P,Epe),Q.Cd=function(e){xVe(this.a,P(e,340))},L(PR,`SelfLoopPostProcessor/lambda$5$Type`,1669),q(1670,1,vF,Cne),Q.Mb=function(e){return!!P(e,105).i},L(PR,`SelfLoopPostProcessor/lambda$6$Type`,1670),q(1671,1,$P,Ope),Q.Cd=function(e){Z_e(this.a,P(e,105))},L(PR,`SelfLoopPostProcessor/lambda$7$Type`,1671),q(1653,1,DR,wne),Q.Kf=function(e,t){fat(P(e,36),t)},L(PR,`SelfLoopPreProcessor`,1653),q(1654,1,{},Tne),Q.Kb=function(e){return new Mp(null,new cv(P(e,105).f,1))},L(PR,`SelfLoopPreProcessor/lambda$0$Type`,1654),q(1655,1,{},Ene),Q.Kb=function(e){return P(e,340).a},L(PR,`SelfLoopPreProcessor/lambda$1$Type`,1655),q(1656,1,$P,Dne),Q.Cd=function(e){xwe(P(e,18))},L(PR,`SelfLoopPreProcessor/lambda$2$Type`,1656),q(1672,1,DR,oOe),Q.Kf=function(e,t){_9e(this,P(e,36),t)},L(PR,`SelfLoopRouter`,1672),q(1673,1,{},One),Q.Kb=function(e){return new Mp(null,new cv(P(e,30).a,16))},L(PR,`SelfLoopRouter/lambda$0$Type`,1673),q(1674,1,vF,kne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SelfLoopRouter/lambda$1$Type`,1674),q(1675,1,vF,Ane),Q.Mb=function(e){return yd(P(e,10),(Y(),a$))},L(PR,`SelfLoopRouter/lambda$2$Type`,1675),q(1676,1,{},jne),Q.Kb=function(e){return P(K(P(e,10),(Y(),a$)),337)},L(PR,`SelfLoopRouter/lambda$3$Type`,1676),q(1677,1,$P,Sxe),Q.Cd=function(e){aIe(this.a,this.b,P(e,337))},L(PR,`SelfLoopRouter/lambda$4$Type`,1677),q(1678,1,DR,Mne),Q.Kf=function(e,t){ist(P(e,36),t)},L(PR,`SemiInteractiveCrossMinProcessor`,1678),q(1679,1,vF,Nne),Q.Mb=function(e){return P(e,10).k==(DA(),JJ)},L(PR,`SemiInteractiveCrossMinProcessor/lambda$0$Type`,1679),q(1680,1,vF,Pne),Q.Mb=function(e){return iNe(P(e,10))._b((mP(),n0))},L(PR,`SemiInteractiveCrossMinProcessor/lambda$1$Type`,1680),q(1681,1,GI,Fne),Q.Ne=function(e,t){return $Je(P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(PR,`SemiInteractiveCrossMinProcessor/lambda$2$Type`,1681),q(1682,1,{},Ine),Q.Ve=function(e,t){return EIe(P(e,10),P(t,10))},L(PR,`SemiInteractiveCrossMinProcessor/lambda$3$Type`,1682),q(1684,1,DR,Lne),Q.Kf=function(e,t){tpt(P(e,36),t)},L(PR,`SortByInputModelProcessor`,1684),q(1685,1,vF,Rne),Q.Mb=function(e){return P(e,12).g.c.length!=0},L(PR,`SortByInputModelProcessor/lambda$0$Type`,1685),q(1686,1,$P,Mpe),Q.Cd=function(e){xet(this.a,P(e,12))},L(PR,`SortByInputModelProcessor/lambda$1$Type`,1686),q(1759,817,{},oYe),Q.df=function(e){var t,n,r,i;switch(this.c=e,this.a.g){case 2:t=new T,To(hg(new Mp(null,new cv(this.c.a.b,16)),new Qne),new Mxe(this,t)),ZA(this,new Bne),Dx(t,new Vne),t.c.length=0,To(hg(new Mp(null,new cv(this.c.a.b,16)),new Hne),new Ppe(t)),ZA(this,new Une),Dx(t,new Wne),t.c.length=0,n=vwe(sC(_g(new Mp(null,new cv(this.c.a.b,16)),new Fpe(this))),new Gne),To(new Mp(null,new cv(this.c.a.a,16)),new Txe(n,t)),ZA(this,new qne),Dx(t,new Jne),t.c.length=0;break;case 3:r=new T,ZA(this,new zne),i=vwe(sC(_g(new Mp(null,new cv(this.c.a.b,16)),new Npe(this))),new Kne),To(hg(new Mp(null,new cv(this.c.a.b,16)),new Yne),new Dxe(i,r)),ZA(this,new Xne),Dx(r,new Zne),r.c.length=0;break;default:throw E(new Cge)}},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation`,1759),q(1760,1,YI,zne),Q.Lb=function(e){return j(P(e,60).g,154)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$0$Type`,1760),q(1761,1,{},Npe),Q.Ye=function(e){return Btt(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$1$Type`,1761),q(1769,1,yF,Cxe),Q.de=function(){zk(this.a,this.b,-1)},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$10$Type`,1769),q(1771,1,YI,Bne),Q.Lb=function(e){return j(P(e,60).g,154)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$11$Type`,1771),q(1772,1,$P,Vne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$12$Type`,1772),q(1773,1,vF,Hne),Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$13$Type`,1773),q(1775,1,$P,Ppe),Q.Cd=function(e){A1e(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$14$Type`,1775),q(1774,1,yF,Oxe),Q.de=function(){zk(this.b,this.a,-1)},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$15$Type`,1774),q(1776,1,YI,Une),Q.Lb=function(e){return j(P(e,60).g,10)},Q.Fb=function(e){return this===e},Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$16$Type`,1776),q(1777,1,$P,Wne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$17$Type`,1777),q(1778,1,{},Fpe),Q.Ye=function(e){return Vtt(this.a,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$18$Type`,1778),q(1779,1,{},Gne),Q.We=function(){return 0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$19$Type`,1779),q(1762,1,{},Kne),Q.We=function(){return 0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$2$Type`,1762),q(1781,1,$P,Txe),Q.Cd=function(e){TNe(this.a,this.b,P(e,316))},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$20$Type`,1781),q(1780,1,yF,Exe),Q.de=function(){wit(this.a,this.b,-1)},Q.b=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$21$Type`,1780),q(1782,1,YI,qne),Q.Lb=function(e){return P(e,60),!0},Q.Fb=function(e){return this===e},Q.Mb=function(e){return P(e,60),!0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$22$Type`,1782),q(1783,1,$P,Jne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$23$Type`,1783),q(1763,1,vF,Yne),Q.Mb=function(e){return j(P(e,60).g,10)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$3$Type`,1763),q(1765,1,$P,Dxe),Q.Cd=function(e){ENe(this.a,this.b,P(e,60))},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$4$Type`,1765),q(1764,1,yF,kxe),Q.de=function(){zk(this.b,this.a,-1)},Q.a=0,L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$5$Type`,1764),q(1766,1,YI,Xne),Q.Lb=function(e){return P(e,60),!0},Q.Fb=function(e){return this===e},Q.Mb=function(e){return P(e,60),!0},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$6$Type`,1766),q(1767,1,$P,Zne),Q.Cd=function(e){P(e,380).de()},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$7$Type`,1767),q(1768,1,vF,Qne),Q.Mb=function(e){return j(P(e,60).g,154)},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$8$Type`,1768),q(1770,1,$P,Mxe),Q.Cd=function(e){oqe(this.a,this.b,P(e,60))},L(RR,`EdgeAwareScanlineConstraintCalculation/lambda$9$Type`,1770),q(1586,1,DR,oEe),Q.Kf=function(e,t){Upt(this,P(e,36),t)};var HOt;L(RR,`HorizontalGraphCompactor`,1586),q(1587,1,{},Ipe),Q.ff=function(e,t){var n,r,i;return zb(e,t)||(n=Ev(e),r=Ev(t),n&&n.k==(DA(),GJ)||r&&r.k==(DA(),GJ))?0:(i=P(K(this.a.a,(Y(),o$)),312),rEe(i,n?n.k:(DA(),qJ),r?r.k:(DA(),qJ)))},Q.gf=function(e,t){var n,r,i;return zb(e,t)?1:(n=Ev(e),r=Ev(t),i=P(K(this.a.a,(Y(),o$)),312),iEe(i,n?n.k:(DA(),qJ),r?r.k:(DA(),qJ)))},L(RR,`HorizontalGraphCompactor/1`,1587),q(1588,1,{},$ne),Q.ef=function(e,t){return Lo(),e.a.i==0},L(RR,`HorizontalGraphCompactor/lambda$0$Type`,1588),q(1589,1,{},Lpe),Q.ef=function(e,t){return AIe(this.a,e,t)},L(RR,`HorizontalGraphCompactor/lambda$1$Type`,1589),q(1730,1,{},iKe);var UOt,WOt;L(RR,`LGraphToCGraphTransformer`,1730),q(1738,1,vF,ere),Q.Mb=function(e){return e!=null},L(RR,`LGraphToCGraphTransformer/0methodref$nonNull$Type`,1738),q(1731,1,{},tre),Q.Kb=function(e){return Lf(),PE(K(P(P(e,60).g,10),(Y(),WQ)))},L(RR,`LGraphToCGraphTransformer/lambda$0$Type`,1731),q(1732,1,{},nre),Q.Kb=function(e){return Lf(),T$e(P(P(e,60).g,154))},L(RR,`LGraphToCGraphTransformer/lambda$1$Type`,1732),q(1741,1,vF,rre),Q.Mb=function(e){return Lf(),j(P(e,60).g,10)},L(RR,`LGraphToCGraphTransformer/lambda$10$Type`,1741),q(1742,1,$P,ire),Q.Cd=function(e){HIe(P(e,60))},L(RR,`LGraphToCGraphTransformer/lambda$11$Type`,1742),q(1743,1,vF,are),Q.Mb=function(e){return Lf(),j(P(e,60).g,154)},L(RR,`LGraphToCGraphTransformer/lambda$12$Type`,1743),q(1747,1,$P,ore),Q.Cd=function(e){w$e(P(e,60))},L(RR,`LGraphToCGraphTransformer/lambda$13$Type`,1747),q(1744,1,$P,Rpe),Q.Cd=function(e){ACe(this.a,P(e,8))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$14$Type`,1744),q(1745,1,$P,zpe),Q.Cd=function(e){MCe(this.a,P(e,116))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$15$Type`,1745),q(1746,1,$P,Bpe),Q.Cd=function(e){jCe(this.a,P(e,8))},Q.a=0,L(RR,`LGraphToCGraphTransformer/lambda$16$Type`,1746),q(1748,1,{},sre),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$17$Type`,1748),q(1749,1,vF,cre),Q.Mb=function(e){return Lf(),gy(P(e,18))},L(RR,`LGraphToCGraphTransformer/lambda$18$Type`,1749),q(1750,1,$P,Vpe),Q.Cd=function(e){mKe(this.a,P(e,18))},L(RR,`LGraphToCGraphTransformer/lambda$19$Type`,1750),q(1734,1,$P,Hpe),Q.Cd=function(e){qze(this.a,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$2$Type`,1734),q(1751,1,{},lre),Q.Kb=function(e){return Lf(),new Mp(null,new cv(P(e,30).a,16))},L(RR,`LGraphToCGraphTransformer/lambda$20$Type`,1751),q(1752,1,{},ure),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$21$Type`,1752),q(1753,1,{},dre),Q.Kb=function(e){return Lf(),P(K(P(e,18),(Y(),l$)),15)},L(RR,`LGraphToCGraphTransformer/lambda$22$Type`,1753),q(1754,1,vF,fre),Q.Mb=function(e){return aEe(P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$23$Type`,1754),q(1755,1,$P,Upe),Q.Cd=function(e){Ett(this.a,P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$24$Type`,1755),q(1733,1,$P,Nxe),Q.Cd=function(e){YVe(this.a,this.b,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$3$Type`,1733),q(1735,1,{},pre),Q.Kb=function(e){return Lf(),new Mp(null,new cv(P(e,30).a,16))},L(RR,`LGraphToCGraphTransformer/lambda$4$Type`,1735),q(1736,1,{},mre),Q.Kb=function(e){return Lf(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(RR,`LGraphToCGraphTransformer/lambda$5$Type`,1736),q(1737,1,{},hre),Q.Kb=function(e){return Lf(),P(K(P(e,18),(Y(),l$)),15)},L(RR,`LGraphToCGraphTransformer/lambda$6$Type`,1737),q(1739,1,$P,Wpe),Q.Cd=function(e){Htt(this.a,P(e,15))},L(RR,`LGraphToCGraphTransformer/lambda$8$Type`,1739),q(1740,1,$P,Pxe),Q.Cd=function(e){Swe(this.a,this.b,P(e,154))},L(RR,`LGraphToCGraphTransformer/lambda$9$Type`,1740),q(1729,1,{},gre),Q.cf=function(e){var t,n,r,i,a;for(this.a=e,this.d=new Xr,this.c=V(YK,FP,125,this.a.a.a.c.length,0,1),this.b=0,n=new w(this.a.a.a);n.a=g&&(M(o,G(d)),y=r.Math.max(y,b[d-1]-f),c+=h,_+=b[d-1]-_,f=b[d-1],h=l[d]),h=r.Math.max(h,l[d]),++d;c+=h}m=r.Math.min(1/y,1/t.b/c),m>i&&(i=m,n=o)}return n},Q.pg=function(){return!1},L(KR,`MSDCutIndexHeuristic`,816),q(1683,1,DR,iie),Q.Kf=function(e,t){Cft(P(e,36),t)},L(KR,`SingleEdgeGraphWrapper`,1683),q(232,22,{3:1,34:1,22:1,232:1},Fs);var UX,WX,GX,KX,qX,JX,YX=aS(qR,`CenterEdgeLabelPlacementStrategy`,232,eG,iGe,Mke),nkt;q(431,22,{3:1,34:1,22:1,431:1},Lxe);var XX,ZX,QX=aS(qR,`ConstraintCalculationStrategy`,431,eG,mLe,Nke),rkt;q(322,22,{3:1,34:1,22:1,322:1,188:1,196:1},Is),Q.dg=function(){return int(this)},Q.qg=function(){return int(this)};var $X,eZ,tZ,nZ=aS(qR,`CrossingMinimizationStrategy`,322,eG,QRe,Pke),ikt;q(351,22,{3:1,34:1,22:1,351:1},Ls);var rZ,iZ,aZ,oZ=aS(qR,`CuttingStrategy`,351,eG,$Re,Fke),akt;q(348,22,{3:1,34:1,22:1,348:1,188:1,196:1},Rs),Q.dg=function(){return fit(this)},Q.qg=function(){return fit(this)};var sZ,cZ,lZ,uZ,dZ,fZ=aS(qR,`CycleBreakingStrategy`,348,eG,oUe,Ike),okt;q(428,22,{3:1,34:1,22:1,428:1},zs);var pZ,mZ,hZ=aS(qR,`DirectionCongruency`,428,eG,pLe,Lke),skt;q(460,22,{3:1,34:1,22:1,460:1},Bs);var gZ,_Z,vZ,ckt=aS(qR,`EdgeConstraint`,460,eG,eze,Wke),lkt;q(283,22,{3:1,34:1,22:1,283:1},Vs);var yZ,bZ,xZ,SZ,CZ,wZ,TZ=aS(qR,`EdgeLabelSideSelection`,283,eG,tGe,Gke),ukt;q(488,22,{3:1,34:1,22:1,488:1},Hs);var EZ,DZ,OZ=aS(qR,`EdgeStraighteningStrategy`,488,eG,xLe,Kke),dkt;q(281,22,{3:1,34:1,22:1,281:1},Us);var kZ,AZ,jZ,MZ,NZ,PZ,FZ=aS(qR,`FixedAlignment`,281,eG,nGe,Uke),fkt;q(282,22,{3:1,34:1,22:1,282:1},Ws);var IZ,LZ,RZ,zZ,BZ,VZ,HZ=aS(qR,`GraphCompactionStrategy`,282,eG,rGe,Rke),pkt;q(259,22,{3:1,34:1,22:1,259:1},Gs);var UZ,WZ,GZ,KZ,qZ,JZ,YZ,XZ,ZZ,QZ,$Z=aS(qR,`GraphProperties`,259,eG,_Ye,zke),mkt;q(299,22,{3:1,34:1,22:1,299:1},Ks);var eQ,tQ,nQ,rQ=aS(qR,`GreedySwitchType`,299,eG,tze,Bke),hkt;q(311,22,{3:1,34:1,22:1,311:1},qs);var iQ,aQ,oQ,gkt=aS(qR,`InLayerConstraint`,311,eG,nze,Vke),_kt;q(429,22,{3:1,34:1,22:1,429:1},Js);var sQ,cQ,lQ=aS(qR,`InteractiveReferencePoint`,429,eG,fLe,Hke),vkt,uQ,dQ,fQ,pQ,mQ,hQ,gQ,_Q,vQ,yQ,bQ,xQ,SQ,CQ,wQ,TQ,EQ,DQ,OQ,kQ,AQ,jQ,MQ,NQ,PQ,FQ,IQ,LQ,RQ,zQ,BQ,VQ,HQ,UQ,WQ,GQ,KQ,qQ,JQ,YQ,XQ,ZQ,QQ,$Q,e$,t$,n$,r$,i$,a$,o$,s$,c$,l$,u$,d$,f$,p$;q(171,22,{3:1,34:1,22:1,171:1},Ys);var m$,h$,g$,_$,v$,y$=aS(qR,`LayerConstraint`,171,eG,cUe,qke),ykt;q(859,1,nL,Eue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,XR),``),`Direction Congruency`),`Specifies how drawings of the same graph with different layout directions compare to each other: either a natural reading direction is preserved or the drawings are rotated versions of each other.`),k$),(VA(),B3)),hZ),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZR),``),`Feedback Edges`),`Whether feedback edges should be highlighted by routing around the nodes.`),(rd(),!1)),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QR),``),`Interactive Reference Point`),`Determines which point of a node is considered by interactive layout phases.`),F$),B3),lQ),sE(F3)))),wv(e,QR,oz,pAt),wv(e,QR,gz,fAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,$R),``),`Merge Edges`),`Edges that have no ports are merged so they touch the connected nodes at the same points. When this option is disabled, one port is created for each edge directly connected to a node. When it is enabled, all such incoming edges share an input port, and all outgoing edges share an output port.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ez),``),`Merge Hierarchy-Crossing Edges`),`If hierarchical layout is active, hierarchy-crossing edges use as few hierarchical ports as possible. They are broken by the algorithm, with hierarchical ports inserted as required. Usually, one such port is created for each edge at each hierarchy crossing point. With this option set to true, we try to create as few hierarchical ports as possible in the process. In particular, all edges that form a hyperedge can share a port.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Hve(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tz),``),`Allow Non-Flow Ports To Switch Sides`),`Specifies whether non-flow ports may switch sides if their node's port constraints are either FIXED_SIDE or FIXED_ORDER. A non-flow port is a port on a side that is not part of the currently configured layout flow. For instance, given a left-to-right layout direction, north and south ports would be considered non-flow ports. Further note that the underlying criterium whether to switch sides or not solely relies on the minimization of edge crossings. Hence, edge length and other aesthetics criteria are not addressed.`),!1),R3),bG),sE(I3)),U(O(LG,1),X,2,6,[`org.eclipse.elk.layered.northOrSouthPort`])))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,nz),``),`Port Sorting Strategy`),`Only relevant for nodes with FIXED_SIDE port constraints. Determines the way a node's ports are distributed on the sides of a node if their order is not prescribed. The option is set on parent nodes.`),U$),B3),YMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rz),``),`Thoroughness`),`How much effort should be spent to produce a nice layout.`),G(7)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iz),``),`Add Unnecessary Bendpoints`),`Adds bend points even if an edge does not change direction. If true, each long edge dummy will contribute a bend point to its edges and hierarchy-crossing edges will always get a bend point where they cross hierarchy boundaries. By default, bend points are only added where an edge changes direction.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,az),``),`Generate Position and Layer IDs`),`If enabled position id and layer id are generated, which are usually only used internally when setting the interactiveLayout option. This option should be specified on the root node.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oz),`cycleBreaking`),`Cycle Breaking Strategy`),`Strategy for cycle breaking. Cycle breaking looks for cycles in the graph and determines which edges to reverse to break the cycles. Reversed edges will end up pointing to the opposite direction of regular edges (that is, reversed edges will point left if edges usually point right).`),O$),B3),fZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sz),vB),`Node Layering Strategy`),`Strategy for node layering.`),R$),B3),jMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cz),vB),`Layer Constraint`),`Determines a constraint on the placement of the node regarding the layering.`),I$),B3),y$),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lz),vB),`Layer Choice Constraint`),"Allows to set a constraint regarding the layer placement of a node. Let i be the value of teh constraint. Assumed the drawing has n layers and i < n. If set to i, it expresses that the node should be placed in i-th layer. Should i>=n be true then the node is placed in the last layer of the drawing. Note that this option is not part of any of ELK Layered's default configurations but is only evaluated as part of the `InteractiveLayeredGraphVisitor`, which must be applied manually or used via the `DiagramLayoutEngine."),null),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uz),vB),`Layer ID`),`Layer identifier that was calculated by ELK Layered for a node. This is only generated if interactiveLayot or generatePositionAndLayerIds is set.`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dz),Hbt),`Upper Bound On Width [MinWidth Layerer]`),`Defines a loose upper bound on the width of the MinWidth layerer. If set to '-1' multiple values are tested and the best result is selected.`),G(4)),H3),DG),sE(F3)))),wv(e,dz,sz,bAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fz),Hbt),`Upper Layer Estimation Scaling Factor [MinWidth Layerer]`),`Multiplied with Upper Bound On Width for defining an upper bound on the width of layers which haven't been determined yet, but whose maximum width had been (roughly) estimated by the MinWidth algorithm. Compensates for too high estimations. If set to '-1' multiple values are tested and the best result is selected.`),G(2)),H3),DG),sE(F3)))),wv(e,fz,sz,SAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pz),Ubt),`Node Promotion Strategy`),`Reduces number of dummy nodes after layering phase (if possible).`),L$),B3),WMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mz),Ubt),`Max Node Promotion Iterations`),`Limits the number of iterations for node promotion.`),G(0)),H3),DG),sE(F3)))),wv(e,mz,pz,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hz),`layering.coffmanGraham`),`Layer Bound`),`The maximum number of nodes allowed per layer.`),G(AP)),H3),DG),sE(F3)))),wv(e,hz,sz,hAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gz),yB),`Crossing Minimization Strategy`),`Strategy for crossing minimization.`),D$),B3),nZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_z),yB),`Force Node Model Order`),`The node order given by the model does not change to produce a better layout. E.g. if node A is before node B in the model this is not changed during crossing minimization. This assumes that the node model order is already respected before crossing minimization. This can be achieved by setting considerModelOrder.strategy to NODES_AND_EDGES.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,vz),yB),`Hierarchical Sweepiness`),`How likely it is to use cross-hierarchy (1) vs bottom-up (-1).`),.1),z3),TG),sE(F3)))),wv(e,vz,bB,zkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,yz),yB),`Semi-Interactive Crossing Minimization`),`Preserves the order of nodes within a layer but still minimizes crossings between edges connecting long edge dummies. Derives the desired order from positions specified by the 'org.eclipse.elk.position' layout option. Requires a crossing minimization strategy that is able to process 'in-layer' constraints.`),!1),R3),bG),sE(F3)))),wv(e,yz,gz,Gkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bz),yB),`In Layer Predecessor of`),`Allows to set a constraint which specifies of which node the current node is the predecessor. If set to 's' then the node is the predecessor of 's' and is in the same layer`),null),W3),LG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xz),yB),`In Layer Successor of`),`Allows to set a constraint which specifies of which node the current node is the successor. If set to 's' then the node is the successor of 's' and is in the same layer`),null),W3),LG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Sz),yB),`Position Choice Constraint`),"Allows to set a constraint regarding the position placement of a node in a layer. Assumed the layer in which the node placed includes n other nodes and i < n. If set to i, it expresses that the node should be placed at the i-th position. Should i>=n be true then the node is placed at the last position in the layer. Note that this option is not part of any of ELK Layered's default configurations but is only evaluated as part of the `InteractiveLayeredGraphVisitor`, which must be applied manually or used via the `DiagramLayoutEngine."),null),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Cz),yB),`Position ID`),`Position within a layer that was determined by ELK Layered for a node. This is only generated if interactiveLayot or generatePositionAndLayerIds is set.`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,wz),Wbt),`Greedy Switch Activation Threshold`),`By default it is decided automatically if the greedy switch is activated or not. The decision is based on whether the size of the input graph (without dummy nodes) is smaller than the value of this option. A '0' enforces the activation.`),G(40)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Tz),Wbt),`Greedy Switch Crossing Minimization`),`Greedy Switch strategy for crossing minimization. The greedy switch heuristic is executed after the regular crossing minimization as a post-processor. Note that if 'hierarchyHandling' is set to 'INCLUDE_CHILDREN', the 'greedySwitchHierarchical.type' option must be used.`),E$),B3),rQ),sE(F3)))),wv(e,Tz,gz,Lkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Ez),`crossingMinimization.greedySwitchHierarchical`),`Greedy Switch Crossing Minimization (hierarchical)`),`Activates the greedy switch heuristic in case hierarchical layout is used. The differences to the non-hierarchical case (see 'greedySwitch.type') are: 1) greedy switch is inactive by default, 3) only the option value set on the node at which hierarchical layout starts is relevant, and 2) if it's activated by the user, it properly addresses hierarchy-crossing edges.`),T$),B3),rQ),sE(F3)))),wv(e,Ez,gz,Pkt),wv(e,Ez,bB,Fkt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Dz),Gbt),`Node Placement Strategy`),`Strategy for node placement.`),H$),B3),RMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,Oz),Gbt),`Favor Straight Edges Over Balancing`),`Favor straight edges over a balanced node placement. The default behavior is determined automatically based on the used 'edgeRouting'. For an orthogonal style it is set to true, for all other styles to false.`),R3),bG),sE(F3)))),wv(e,Oz,Dz,NAt),wv(e,Oz,Dz,PAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,kz),Kbt),`BK Edge Straightening`),`Specifies whether the Brandes Koepf node placer tries to increase the number of straight edges at the expense of diagram size. There is a subtle difference to the 'favorStraightEdges' option, which decides whether a balanced placement of the nodes is desired, or not. In bk terms this means combining the four alignments into a single balanced one, or not. This option on the other hand tries to straighten additional edges during the creation of each of the four alignments.`),z$),B3),OZ),sE(F3)))),wv(e,kz,Dz,kAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Az),Kbt),`BK Fixed Alignment`),`Tells the BK node placer to use a certain alignment (out of its four) instead of the one producing the smallest height, or the combination of all four.`),B$),B3),FZ),sE(F3)))),wv(e,Az,Dz,jAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jz),`nodePlacement.linearSegments`),`Linear Segments Deflection Dampening`),`Dampens the movement of nodes to keep the diagram from getting too large.`),.3),z3),TG),sE(F3)))),wv(e,jz,Dz,IAt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,Mz),`nodePlacement.networkSimplex`),`Node Flexibility`),`Aims at shorter and straighter edges. Two configurations are possible: (a) allow ports to move freely on the side they are assigned to (the order is always defined beforehand), (b) additionally allow to enlarge a node wherever it helps. If this option is not configured for a node, the 'nodeFlexibility.default' value is used, which is specified for the node's parent.`),B3),B0),sE(P3)))),wv(e,Mz,Dz,BAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Nz),`nodePlacement.networkSimplex.nodeFlexibility`),`Node Flexibility Default`),`Default value of the 'nodeFlexibility' option for the children of a hierarchical node.`),V$),B3),B0),sE(F3)))),wv(e,Nz,Dz,zAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Pz),qbt),`Self-Loop Distribution`),`Alter the distribution of the loops around the node. It only takes effect for PortConstraints.FREE.`),M$),B3),tNt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Fz),qbt),`Self-Loop Ordering`),`Alter the ordering of the loops they can either be stacked or sequenced. It only takes effect for PortConstraints.FREE.`),N$),B3),rNt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Iz),`edgeRouting.splines`),`Spline Routing Mode`),`Specifies the way control points are assembled for each individual edge. CONSERVATIVE ensures that edges are properly routed around the nodes but feels rather orthogonal at times. SLOPPY uses fewer control points to obtain curvier edge routes but may result in edges overlapping nodes.`),P$),B3),oNt),sE(F3)))),wv(e,Iz,xB,nAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Lz),`edgeRouting.splines.sloppy`),`Sloppy Spline Layer Spacing Factor`),`Spacing factor for routing area between layers when using sloppy spline routing.`),.2),z3),TG),sE(F3)))),wv(e,Lz,xB,iAt),wv(e,Lz,Iz,aAt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Rz),`edgeRouting.polyline`),`Sloped Edge Zone Width`),`Width of the strip to the left and to the right of each layer where the polyline edge router is allowed to refrain from ensuring that edges are routed horizontally. This prevents awkward bend points for nodes that extent almost to the edge of their layer.`),2),z3),TG),sE(F3)))),wv(e,Rz,xB,Qkt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,zz),SB),`Spacing Base Value`),`An optional base value for all other layout options of the 'spacing' group. It can be used to conveniently alter the overall 'spaciousness' of the drawing. Whenever an explicit value is set for the other layout options, this base value will have no effect. The base value is not inherited, i.e. it must be set for each hierarchical node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Bz),SB),`Edge Node Between Layers Spacing`),`The spacing to be preserved between nodes and edges that are routed next to the node's layer. For the spacing between nodes and edges that cross the node's layer 'spacing.edgeNode' is used.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Vz),SB),`Edge Edge Between Layer Spacing`),`Spacing to be preserved between pairs of edges that are routed between the same pair of layers. Note that 'spacing.edgeEdge' is used for the spacing between pairs of edges crossing the same layer.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Hz),SB),`Node Node Between Layers Spacing`),`The spacing to be preserved between any pair of nodes of two adjacent layers. Note that 'spacing.nodeNode' is used for the spacing between nodes within the layer itself.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Uz),CB),`Direction Priority`),`Defines how important it is to have a certain edge point into the direction of the overall layout. This option is evaluated during the cycle breaking phase.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Wz),CB),`Shortness Priority`),`Defines how important it is to keep an edge as short as possible. This option is evaluated during the layering phase.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Gz),CB),`Straightness Priority`),`Defines how important it is to keep an edge straight, i.e. aligned with one of the two axes. This option is evaluated during node placement.`),G(0)),H3),DG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Kz),wB),Gyt),`Tries to further compact components (disconnected sub-graphs).`),!1),R3),bG),sE(F3)))),wv(e,Kz,eR,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,qz),Jbt),`Post Compaction Strategy`),Ybt),x$),B3),HZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Jz),Jbt),`Post Compaction Constraint Calculation`),Ybt),b$),B3),QX),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Yz),TB),`High Degree Node Treatment`),`Makes room around high degree nodes to place leafs and trees.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Xz),TB),`High Degree Node Threshold`),`Whether a node is considered to have a high degree.`),G(16)),H3),DG),sE(F3)))),wv(e,Xz,Yz,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Zz),TB),`High Degree Node Maximum Tree Height`),`Maximum height of a subtree connected to a high degree node to be moved to separate layers.`),G(5)),H3),DG),sE(F3)))),wv(e,Zz,Yz,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,Qz),EB),`Graph Wrapping Strategy`),`For certain graphs and certain prescribed drawing areas it may be desirable to split the laid out graph into chunks that are placed side by side. The edges that connect different chunks are 'wrapped' around from the end of one chunk to the start of the other chunk. The points between the chunks are referred to as 'cuts'.`),K$),B3),fNt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,$z),EB),`Additional Wrapped Edges Spacing`),`To visually separate edges that are wrapped from regularly routed edges an additional spacing value can be specified in form of this layout option. The spacing is added to the regular edgeNode spacing.`),10),z3),TG),sE(F3)))),wv(e,$z,Qz,$At),wv(e,$z,Qz,ejt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,eB),EB),`Correction Factor for Wrapping`),`At times and for certain types of graphs the executed wrapping may produce results that are consistently biased in the same fashion: either wrapping to often or to rarely. This factor can be used to correct the bias. Internally, it is simply multiplied with the 'aspect ratio' layout option.`),1),z3),TG),sE(F3)))),wv(e,eB,Qz,njt),wv(e,eB,Qz,rjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tB),Xbt),`Cutting Strategy`),`The strategy by which the layer indexes are determined at which the layering crumbles into chunks.`),G$),B3),oZ),sE(F3)))),wv(e,tB,Qz,ljt),wv(e,tB,Qz,ujt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,nB),Xbt),`Manually Specified Cuts`),`Allows the user to specify her own cuts for a certain graph.`),U3),JW),sE(F3)))),wv(e,nB,tB,ajt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rB),`wrapping.cutting.msd`),`MSD Freedom`),`The MSD cutting strategy starts with an initial guess on the number of chunks the graph should be split into. The freedom specifies how much the strategy may deviate from this guess. E.g. if an initial number of 3 is computed, a freedom of 1 allows 2, 3, and 4 cuts.`),W$),H3),DG),sE(F3)))),wv(e,rB,tB,sjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iB),Zbt),`Validification Strategy`),`When wrapping graphs, one can specify indices that are not allowed as split points. The validification strategy makes sure every computed split point is allowed.`),q$),B3),uNt),sE(F3)))),wv(e,iB,Qz,Sjt),wv(e,iB,Qz,Cjt),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,aB),Zbt),`Valid Indices for Wrapping`),null),U3),JW),sE(F3)))),wv(e,aB,Qz,yjt),wv(e,aB,Qz,bjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oB),DB),`Improve Cuts`),`For general graphs it is important that not too many edges wrap backwards. Thus a compromise between evenly-distributed cuts and the total number of cut edges is sought.`),!0),R3),bG),sE(F3)))),wv(e,oB,Qz,mjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sB),DB),`Distance Penalty When Improving Cuts`),null),2),z3),TG),sE(F3)))),wv(e,sB,Qz,fjt),wv(e,sB,oB,!0),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cB),DB),`Improve Wrapped Edges`),`The initial wrapping is performed in a very simple way. As a consequence, edges that wrap from one chunk to another may be unnecessarily long. Activating this option tries to shorten such edges.`),!0),R3),bG),sE(F3)))),wv(e,cB,Qz,gjt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lB),OB),`Edge Label Side Selection`),`Method to decide on edge label sides.`),j$),B3),TZ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uB),OB),`Edge Center Label Placement Strategy`),`Determines in which layer center labels of long edges should be placed.`),A$),B3),YX),Zp(F3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dB),kB),`Consider Model Order`),`Preserves the order of nodes and edges in the model file if this does not lead to additional edge crossings. Depending on the strategy this is not always possible since the node and edge order might be conflicting.`),w$),B3),qMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fB),kB),`Consider Port Order`),`If disabled the port order of output ports is derived from the edge order and input ports are ordered by their incoming connections. If enabled all ports are ordered by the port model order.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pB),kB),`No Model Order`),`Set on a node to not set a model order for this node even though it is a real node.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mB),kB),`Consider Model Order for Components`),`If set to NONE the usual ordering strategy (by cumulative node priority and size of nodes) is used. INSIDE_PORT_SIDES orders the components with external ports only inside the groups with the same port side. FORCE_MODEL_ORDER enforces the mode order on components. This option might produce bad alignments and sub optimal drawings in terms of used area since the ordering should be respected.`),S$),B3),zJ),sE(F3)))),wv(e,mB,eR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hB),kB),`Long Edge Ordering Strategy`),`Indicates whether long edges are sorted under, over, or equal to nodes that have no connection to a previous layer in a left-to-right or right-to-left layout. Under and over changes to right and left in a vertical layout.`),C$),B3),PMt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gB),kB),`Crossing Counter Node Order Influence`),`Indicates with what percentage (1 for 100%) violations of the node model order are weighted against the crossings e.g. a value of 0.5 means two model order violations are as important as on edge crossing. This allows some edge crossings in favor of preserving the model order. It is advised to set this value to a very small positive value (e.g. 0.001) to have minimal crossing and a optimal node order. Defaults to no influence (0).`),0),z3),TG),sE(F3)))),wv(e,gB,dB,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_B),kB),`Crossing Counter Port Order Influence`),`Indicates with what percentage (1 for 100%) violations of the port model order are weighted against the crossings e.g. a value of 0.5 means two model order violations are as important as on edge crossing. This allows some edge crossings in favor of preserving the model order. It is advised to set this value to a very small positive value (e.g. 0.001) to have minimal crossing and a optimal port order. Defaults to no influence (0).`),0),z3),TG),sE(F3)))),wv(e,_B,dB,null),Ivt((new Due,e))};var bkt,xkt,Skt,b$,Ckt,x$,wkt,S$,Tkt,Ekt,Dkt,C$,Okt,kkt,Akt,w$,jkt,Mkt,Nkt,T$,Pkt,Fkt,Ikt,E$,Lkt,Rkt,zkt,Bkt,Vkt,Hkt,Ukt,Wkt,Gkt,Kkt,D$,qkt,O$,Jkt,k$,Ykt,A$,Xkt,j$,Zkt,Qkt,$kt,M$,eAt,N$,tAt,P$,nAt,rAt,iAt,aAt,oAt,sAt,cAt,lAt,uAt,dAt,F$,fAt,pAt,mAt,hAt,gAt,_At,I$,vAt,yAt,bAt,xAt,SAt,CAt,wAt,L$,TAt,R$,EAt,DAt,OAt,z$,kAt,AAt,B$,jAt,MAt,NAt,PAt,FAt,IAt,LAt,RAt,V$,zAt,BAt,VAt,H$,HAt,U$,UAt,WAt,GAt,KAt,qAt,JAt,YAt,XAt,ZAt,QAt,$At,ejt,tjt,njt,rjt,ijt,ajt,ojt,W$,sjt,cjt,G$,ljt,ujt,djt,fjt,pjt,mjt,hjt,gjt,_jt,K$,vjt,yjt,bjt,xjt,q$,Sjt,Cjt;L(qR,`LayeredMetaDataProvider`,859),q(998,1,nL,Due),Q.hf=function(e){Ivt(e)};var J$,Y$,X$,Z$,Q$,$$,e1,t1,n1,r1,i1,a1,o1,s1,c1,l1,u1,d1,f1,wjt,Tjt,Ejt,Djt,p1,m1,h1,g1,Ojt,_1,kjt,Ajt,v1,y1,b1,x1,S1,jjt,Mjt,Njt,C1,w1,Pjt,T1,E1,Fjt,D1,Ijt,Ljt,Rjt,O1,k1,A1,zjt,Bjt,j1,Vjt,Hjt,M1,N1,Ujt,Wjt,Gjt,P1,F1,I1,Kjt,qjt,L1,R1,Jjt,z1,B1,Yjt,V1,H1,U1,W1,G1,K1,q1,J1,Xjt,Zjt,Qjt,Y1,$jt,eMt,tMt,nMt,rMt,X1,Z1,Q1,$1,iMt,e0,aMt,t0,oMt,n0,sMt,r0,cMt,i0,lMt,uMt,a0,o0,dMt,s0,c0,l0,u0,d0,f0,p0,m0,h0,g0,_0,v0,y0,b0,x0,S0,C0,fMt,pMt,mMt,hMt,gMt,w0,_Mt,vMt,yMt,bMt,T0,xMt,SMt,CMt,wMt,E0,D0;L(qR,`LayeredOptions`,998),q(999,1,{},aie),Q.sf=function(){var e;return e=new Uge,e},Q.tf=function(e){},L(qR,`LayeredOptions/LayeredFactory`,999),q(1391,1,{}),Q.a=0;var TMt;L(gV,`ElkSpacings/AbstractSpacingsBuilder`,1391),q(792,1391,{},rD);var O0,EMt;L(qR,`LayeredSpacings/LayeredSpacingsBuilder`,792),q(265,22,{3:1,34:1,22:1,265:1,188:1,196:1},Xs),Q.dg=function(){return Rct(this)},Q.qg=function(){return Rct(this)};var k0,A0,j0,DMt,OMt,kMt,M0,N0,AMt,jMt=aS(qR,`LayeringStrategy`,265,eG,iJe,Jke),MMt;q(390,22,{3:1,34:1,22:1,390:1},Zs);var P0,NMt,F0,PMt=aS(qR,`LongEdgeOrderingStrategy`,390,eG,rze,Yke),FMt;q(203,22,{3:1,34:1,22:1,203:1},Qs);var I0,L0,R0,z0,B0=aS(qR,`NodeFlexibility`,203,eG,vVe,Xke),IMt;q(323,22,{3:1,34:1,22:1,323:1,188:1,196:1},$s),Q.dg=function(){return dit(this)},Q.qg=function(){return dit(this)};var V0,H0,U0,W0,LMt,RMt=aS(qR,`NodePlacementStrategy`,323,eG,sUe,Zke),zMt;q(243,22,{3:1,34:1,22:1,243:1},ec);var BMt,G0,K0,q0,VMt,HMt,J0,UMt,Y0,X0,WMt=aS(qR,`NodePromotionStrategy`,243,eG,vYe,Qke),GMt;q(284,22,{3:1,34:1,22:1,284:1},tc);var KMt,Z0,Q0,$0,qMt=aS(qR,`OrderingStrategy`,284,eG,yVe,$ke),JMt;q(430,22,{3:1,34:1,22:1,430:1},nc);var e2,t2,YMt=aS(qR,`PortSortingStrategy`,430,eG,hLe,eAe),XMt;q(463,22,{3:1,34:1,22:1,463:1},rc);var n2,r2,i2,ZMt=aS(qR,`PortType`,463,eG,ize,tAe),QMt;q(387,22,{3:1,34:1,22:1,387:1},ic);var $Mt,a2,eNt,tNt=aS(qR,`SelfLoopDistributionStrategy`,387,eG,aze,nAe),nNt;q(349,22,{3:1,34:1,22:1,349:1},ac);var o2,s2,c2,rNt=aS(qR,`SelfLoopOrderingStrategy`,349,eG,oze,rAe),iNt;q(312,1,{312:1},Hmt),L(qR,`Spacings`,312),q(350,22,{3:1,34:1,22:1,350:1},oc);var l2,aNt,u2,oNt=aS(qR,`SplineRoutingMode`,350,eG,sze,iAe),sNt;q(352,22,{3:1,34:1,22:1,352:1},sc);var d2,cNt,lNt,uNt=aS(qR,`ValidifyStrategy`,352,eG,cze,aAe),dNt;q(388,22,{3:1,34:1,22:1,388:1},cc);var f2,p2,m2,fNt=aS(qR,`WrappingStrategy`,388,eG,lze,oAe),pNt;q(1398,1,yV,vue),Q.rg=function(e){return P(e,36),mNt},Q.Kf=function(e,t){Bpt(this,P(e,36),t)};var mNt;L(bV,`DepthFirstCycleBreaker`,1398),q(793,1,yV,bNe),Q.rg=function(e){return P(e,36),hNt},Q.Kf=function(e,t){cvt(this,P(e,36),t)},Q.sg=function(e){return P(Ep(e,VO(this.d,e.c.length)),10)};var hNt;L(bV,`GreedyCycleBreaker`,793),q(1401,793,yV,iCe),Q.sg=function(e){var t,n,r,i=null;for(t=AP,r=new w(e);r.a1&&(ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),(mP(),l1))))?iat(e,this.d,P(this,669)):(Vg(),hu(e,this.d)),uXe(this.e,e))},Q.lg=function(e,t,n,r){var i,a,o,s,c,l,u;for(t!=nNe(n,e.length)&&(a=e[t-(n?1:-1)],XUe(this.f,a,n?(uS(),r2):(uS(),n2))),i=e[t][0],u=!r||i.k==(DA(),GJ),l=Oy(e[t]),this.vg(l,u,!1,n),o=0,c=new w(l);c.a`),e0?M_(this.a,e[t-1],e[t]):!n&&t1&&(ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),(mP(),l1))))?iat(e,this.d,this):(Vg(),hu(e,this.d)),ki(Od(K(Bh((ov(0,e.c.length),P(e.c[0],10))),l1)))||uXe(this.e,e))},L(CV,`ModelOrderBarycenterHeuristic`,669),q(1866,1,GI,ume),Q.Ne=function(e,t){return Y9e(this.a,P(e,10),P(t,10))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(CV,`ModelOrderBarycenterHeuristic/lambda$0$Type`,1866),q(1423,1,yV,kue),Q.rg=function(e){var t;return P(e,36),t=Wl(NNt),vp(t,(vA(),bJ),(yP(),eX)),t},Q.Kf=function(e,t){dIe((P(e,36),t))};var NNt;L(CV,`NoCrossingMinimizer`,1423),q(809,413,SV,Na),Q.tg=function(e,t,n){var r,i,a,o,s,c,l,u,d=this.g,f,p;switch(n.g){case 1:for(i=0,a=0,u=new w(e.j);u.a1&&(i.j==(nP(),X8)?this.b[e]=!0:i.j==g5&&e>0&&(this.b[e-1]=!0))},Q.f=0,L(BR,`AllCrossingsCounter`,1861),q(595,1,{},VS),Q.b=0,Q.d=0,L(BR,`BinaryIndexedTree`,595),q(532,1,{},hf);var PNt,v2;L(BR,`CrossingsCounter`,532),q(1950,1,GI,dme),Q.Ne=function(e,t){return QMe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$0$Type`,1950),q(1951,1,GI,fme),Q.Ne=function(e,t){return $Me(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$1$Type`,1951),q(1952,1,GI,pme),Q.Ne=function(e,t){return eNe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$2$Type`,1952),q(1953,1,GI,mme),Q.Ne=function(e,t){return tNe(this.a,P(e,12),P(t,12))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BR,`CrossingsCounter/lambda$3$Type`,1953),q(1954,1,$P,hme),Q.Cd=function(e){GGe(this.a,P(e,12))},L(BR,`CrossingsCounter/lambda$4$Type`,1954),q(1955,1,vF,gme),Q.Mb=function(e){return Kxe(this.a,P(e,12))},L(BR,`CrossingsCounter/lambda$5$Type`,1955),q(1956,1,$P,_me),Q.Cd=function(e){qSe(this,e)},L(BR,`CrossingsCounter/lambda$6$Type`,1956),q(1957,1,$P,Rxe),Q.Cd=function(e){var t;Rf(),Rv(this.b,(t=this.a,P(e,12),t))},L(BR,`CrossingsCounter/lambda$7$Type`,1957),q(839,1,YI,hie),Q.Lb=function(e){return Rf(),yd(P(e,12),(Y(),QQ))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return Rf(),yd(P(e,12),(Y(),QQ))},L(BR,`CrossingsCounter/lambda$8$Type`,839),q(1949,1,{},vme),L(BR,`HyperedgeCrossingsCounter`,1949),q(478,1,{34:1,478:1},sOe),Q.Fd=function(e){return e2e(this,P(e,478))},Q.b=0,Q.c=0,Q.e=0,Q.f=0;var FNt=L(BR,`HyperedgeCrossingsCounter/Hyperedge`,478);q(374,1,{34:1,374:1},Sg),Q.Fd=function(e){return Fit(this,P(e,374))},Q.b=0,Q.c=0;var INt=L(BR,`HyperedgeCrossingsCounter/HyperedgeCorner`,374);q(531,22,{3:1,34:1,22:1,531:1},zxe);var y2,b2,LNt=aS(BR,`HyperedgeCrossingsCounter/HyperedgeCorner/Type`,531,eG,gLe,cAe),RNt;q(1425,1,yV,Aue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?zNt:null},Q.Kf=function(e,t){s8e(this,P(e,36),t)};var zNt;L(wV,`InteractiveNodePlacer`,1425),q(1426,1,yV,jue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?BNt:null},Q.Kf=function(e,t){K4e(this,P(e,36),t)};var BNt,x2,S2;L(wV,`LinearSegmentsNodePlacer`,1426),q(261,1,{34:1,261:1},Jge),Q.Fd=function(e){return Fve(this,P(e,261))},Q.Fb=function(e){var t;return j(e,261)?(t=P(e,261),this.b==t.b):!1},Q.Hb=function(){return this.b},Q.Ib=function(){return`ls`+CA(this.e)},Q.a=0,Q.b=0,Q.c=-1,Q.d=-1,Q.g=0;var VNt=L(wV,`LinearSegmentsNodePlacer/LinearSegment`,261);q(1428,1,yV,xNe),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?HNt:null},Q.Kf=function(e,t){K_t(this,P(e,36),t)},Q.b=0,Q.g=0;var HNt;L(wV,`NetworkSimplexPlacer`,1428),q(1447,1,GI,gie),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(wV,`NetworkSimplexPlacer/0methodref$compare$Type`,1447),q(1449,1,GI,_ie),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(wV,`NetworkSimplexPlacer/1methodref$compare$Type`,1449),q(655,1,{655:1},Bxe);var UNt=L(wV,`NetworkSimplexPlacer/EdgeRep`,655);q(412,1,{412:1},Cg),Q.b=!1;var WNt=L(wV,`NetworkSimplexPlacer/NodeRep`,412);q(515,13,{3:1,4:1,20:1,31:1,56:1,13:1,16:1,15:1,59:1,515:1},$ge),L(wV,`NetworkSimplexPlacer/Path`,515),q(1429,1,{},vie),Q.Kb=function(e){return P(e,18).d.i.k},L(wV,`NetworkSimplexPlacer/Path/lambda$0$Type`,1429),q(1430,1,vF,yie),Q.Mb=function(e){return P(e,273)==(DA(),qJ)},L(wV,`NetworkSimplexPlacer/Path/lambda$1$Type`,1430),q(1431,1,{},bie),Q.Kb=function(e){return P(e,18).d.i},L(wV,`NetworkSimplexPlacer/Path/lambda$2$Type`,1431),q(1432,1,vF,yme),Q.Mb=function(e){return DDe(b0e(P(e,10)))},L(wV,`NetworkSimplexPlacer/Path/lambda$3$Type`,1432),q(1433,1,vF,xie),Q.Mb=function(e){return SMe(P(e,12))},L(wV,`NetworkSimplexPlacer/lambda$0$Type`,1433),q(1434,1,$P,Vxe),Q.Cd=function(e){Cwe(this.a,this.b,P(e,12))},L(wV,`NetworkSimplexPlacer/lambda$1$Type`,1434),q(1443,1,$P,bme),Q.Cd=function(e){Gtt(this.a,P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$10$Type`,1443),q(1444,1,{},Sie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$11$Type`,1444),q(1445,1,$P,xme),Q.Cd=function(e){wct(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$12$Type`,1445),q(1446,1,{},Cie),Q.Kb=function(e){return z_(),G(P(e,125).e)},L(wV,`NetworkSimplexPlacer/lambda$13$Type`,1446),q(1448,1,{},wie),Q.Kb=function(e){return z_(),G(P(e,125).e)},L(wV,`NetworkSimplexPlacer/lambda$15$Type`,1448),q(1450,1,vF,Tie),Q.Mb=function(e){return z_(),P(e,412).c.k==(DA(),JJ)},L(wV,`NetworkSimplexPlacer/lambda$17$Type`,1450),q(1451,1,vF,Eie),Q.Mb=function(e){return z_(),P(e,412).c.j.c.length>1},L(wV,`NetworkSimplexPlacer/lambda$18$Type`,1451),q(1452,1,$P,oIe),Q.Cd=function(e){J1e(this.c,this.b,this.d,this.a,P(e,412))},Q.c=0,Q.d=0,L(wV,`NetworkSimplexPlacer/lambda$19$Type`,1452),q(1435,1,{},Die),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$2$Type`,1435),q(1453,1,$P,Sme),Q.Cd=function(e){Twe(this.a,P(e,12))},Q.a=0,L(wV,`NetworkSimplexPlacer/lambda$20$Type`,1453),q(1454,1,{},Oie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$21$Type`,1454),q(1455,1,$P,Cme),Q.Cd=function(e){tTe(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$22$Type`,1455),q(1456,1,vF,kie),Q.Mb=function(e){return DDe(e)},L(wV,`NetworkSimplexPlacer/lambda$23$Type`,1456),q(1457,1,{},Aie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$24$Type`,1457),q(1458,1,vF,wme),Q.Mb=function(e){return wCe(this.a,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$25$Type`,1458),q(1459,1,$P,Hxe),Q.Cd=function(e){ret(this.a,this.b,P(e,10))},L(wV,`NetworkSimplexPlacer/lambda$26$Type`,1459),q(1460,1,vF,jie),Q.Mb=function(e){return z_(),!gy(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$27$Type`,1460),q(1461,1,vF,Mie),Q.Mb=function(e){return z_(),!gy(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$28$Type`,1461),q(1462,1,{},Tme),Q.Ve=function(e,t){return wwe(this.a,P(e,30),P(t,30))},L(wV,`NetworkSimplexPlacer/lambda$29$Type`,1462),q(1436,1,{},Nie),Q.Kb=function(e){return z_(),new Mp(null,new ih(new pm(Vu(OE(P(e,10)).a.Kc(),new d))))},L(wV,`NetworkSimplexPlacer/lambda$3$Type`,1436),q(1437,1,vF,Pie),Q.Mb=function(e){return z_(),KBe(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$4$Type`,1437),q(1438,1,$P,Eme),Q.Cd=function(e){hft(this.a,P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$5$Type`,1438),q(1439,1,{},Fie),Q.Kb=function(e){return z_(),new Mp(null,new cv(P(e,30).a,16))},L(wV,`NetworkSimplexPlacer/lambda$6$Type`,1439),q(1440,1,vF,Iie),Q.Mb=function(e){return z_(),P(e,10).k==(DA(),JJ)},L(wV,`NetworkSimplexPlacer/lambda$7$Type`,1440),q(1441,1,{},Lie),Q.Kb=function(e){return z_(),new Mp(null,new ih(new pm(Vu(EE(P(e,10)).a.Kc(),new d))))},L(wV,`NetworkSimplexPlacer/lambda$8$Type`,1441),q(1442,1,vF,Rie),Q.Mb=function(e){return z_(),xMe(P(e,18))},L(wV,`NetworkSimplexPlacer/lambda$9$Type`,1442),q(1424,1,yV,Mue),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?GNt:null},Q.Kf=function(e,t){hpt(P(e,36),t)};var GNt;L(wV,`SimpleNodePlacer`,1424),q(185,1,{185:1},VM),Q.Ib=function(){var e=``;return this.c==(O_(),w2)?e+=lL:this.c==C2&&(e+=cL),this.o==(k_(),T2)?e+=hL:this.o==E2?e+=`UP`:e+=`BALANCED`,e},L(EV,`BKAlignedLayout`,185),q(523,22,{3:1,34:1,22:1,523:1},Uxe);var C2,w2,KNt=aS(EV,`BKAlignedLayout/HDirection`,523,eG,vLe,lAe),qNt;q(522,22,{3:1,34:1,22:1,522:1},Wxe);var T2,E2,JNt=aS(EV,`BKAlignedLayout/VDirection`,522,eG,yLe,uAe),YNt;q(1699,1,{},Gxe),L(EV,`BKAligner`,1699),q(1702,1,{},f6e),L(EV,`BKCompactor`,1702),q(663,1,{663:1},zie),Q.a=0,L(EV,`BKCompactor/ClassEdge`,663),q(467,1,{467:1},Xge),Q.a=null,Q.b=0,L(EV,`BKCompactor/ClassNode`,467),q(1427,1,yV,Xxe),Q.rg=function(e){return P(K(P(e,36),(Y(),OQ)),21).Hc((uM(),KZ))?XNt:null},Q.Kf=function(e,t){wvt(this,P(e,36),t)},Q.d=!1;var XNt;L(EV,`BKNodePlacer`,1427),q(1700,1,{},Bie),Q.d=0,L(EV,`NeighborhoodInformation`,1700),q(1701,1,GI,Dme),Q.Ne=function(e,t){return sqe(this,P(e,42),P(t,42))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(EV,`NeighborhoodInformation/NeighborComparator`,1701),q(823,1,{}),L(EV,`ThresholdStrategy`,823),q(1825,823,{},Zge),Q.wg=function(e,t,n){return this.a.o==(k_(),E2)?cI:lI},Q.xg=function(){},L(EV,`ThresholdStrategy/NullThresholdStrategy`,1825),q(587,1,{587:1},Zxe),Q.c=!1,Q.d=!1,L(EV,`ThresholdStrategy/Postprocessable`,587),q(1826,823,{},Qge),Q.wg=function(e,t,n){var r,i=t==n,a;return r=this.a.a[n.p]==t,i||r?(a=e,this.a.c,O_(),i&&(a=_pt(this,t,!0)),!isNaN(a)&&!isFinite(a)&&r&&(a=_pt(this,n,!1)),a):e},Q.xg=function(){for(var e,t,n,r,i;this.d.b!=0;)i=P(RLe(this.d),587),r=Cdt(this,i),r.a&&(e=r.a,n=ki(this.a.f[this.a.g[i.b.p].p]),!(!n&&!gy(e)&&e.c.i.c==e.d.i.c)&&(t=Iit(this,i),t||kCe(this.e,i)));for(;this.e.a.c.length!=0;)Iit(this,P(wQe(this.e),587))},L(EV,`ThresholdStrategy/SimpleThresholdStrategy`,1826),q(645,1,{645:1,188:1,196:1},Vie),Q.dg=function(){return fXe(this)},Q.qg=function(){return fXe(this)};var D2;L(DV,`EdgeRouterFactory`,645),q(1485,1,yV,Nue),Q.rg=function(e){return Lst(P(e,36))},Q.Kf=function(e,t){wpt(P(e,36),t)};var ZNt,QNt,$Nt,ePt,tPt,nPt,rPt,iPt;L(DV,`OrthogonalEdgeRouter`,1485),q(1478,1,yV,Yxe),Q.rg=function(e){return T8e(P(e,36))},Q.Kf=function(e,t){Ygt(this,P(e,36),t)};var aPt,oPt,sPt,cPt,O2,lPt;L(DV,`PolylineEdgeRouter`,1478),q(1479,1,YI,Uie),Q.Lb=function(e){return wXe(P(e,10))},Q.Fb=function(e){return this===e},Q.Mb=function(e){return wXe(P(e,10))},L(DV,`PolylineEdgeRouter/1`,1479),q(1872,1,vF,Wie),Q.Mb=function(e){return P(e,132).c==(Wy(),k2)},L(OV,`HyperEdgeCycleDetector/lambda$0$Type`,1872),q(1873,1,{},Gie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$1$Type`,1873),q(1874,1,vF,Kie),Q.Mb=function(e){return P(e,132).c==(Wy(),k2)},L(OV,`HyperEdgeCycleDetector/lambda$2$Type`,1874),q(1875,1,{},qie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$3$Type`,1875),q(1876,1,{},Jie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$4$Type`,1876),q(1877,1,{},Hie),Q.Ze=function(e){return P(e,132).d},L(OV,`HyperEdgeCycleDetector/lambda$5$Type`,1877),q(118,1,{34:1,118:1},GC),Q.Fd=function(e){return Ive(this,P(e,118))},Q.Fb=function(e){var t;return j(e,118)?(t=P(e,118),this.g==t.g):!1},Q.Hb=function(){return this.g},Q.Ib=function(){for(var e=new Gu(`{`),t,n,r=new w(this.n);r.a`+this.b+` (`+bEe(this.c)+`)`},Q.d=0,L(OV,`HyperEdgeSegmentDependency`,132),q(528,22,{3:1,34:1,22:1,528:1},nSe);var k2,A2,uPt=aS(OV,`HyperEdgeSegmentDependency/DependencyType`,528,eG,bLe,dAe),dPt;q(1878,1,{},Ome),L(OV,`HyperEdgeSegmentSplitter`,1878),q(1879,1,{},Xve),Q.a=0,Q.b=0,L(OV,`HyperEdgeSegmentSplitter/AreaRating`,1879),q(339,1,{339:1},Bf),Q.a=0,Q.b=0,Q.c=0,L(OV,`HyperEdgeSegmentSplitter/FreeArea`,339),q(1880,1,GI,Yie),Q.Ne=function(e,t){return NOe(P(e,118),P(t,118))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(OV,`HyperEdgeSegmentSplitter/lambda$0$Type`,1880),q(1881,1,$P,sIe),Q.Cd=function(e){ZVe(this.a,this.d,this.c,this.b,P(e,118))},Q.b=0,L(OV,`HyperEdgeSegmentSplitter/lambda$1$Type`,1881),q(1882,1,{},Xie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).e,16))},L(OV,`HyperEdgeSegmentSplitter/lambda$2$Type`,1882),q(1883,1,{},Zie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).j,16))},L(OV,`HyperEdgeSegmentSplitter/lambda$3$Type`,1883),q(1884,1,{},Qie),Q.Ye=function(e){return D(N(e))},L(OV,`HyperEdgeSegmentSplitter/lambda$4$Type`,1884),q(664,1,{},ah),Q.a=0,Q.b=0,Q.c=0,L(OV,`OrthogonalRoutingGenerator`,664),q(1703,1,{},$ie),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).e,16))},L(OV,`OrthogonalRoutingGenerator/lambda$0$Type`,1703),q(1704,1,{},eae),Q.Kb=function(e){return new Mp(null,new cv(P(e,118).j,16))},L(OV,`OrthogonalRoutingGenerator/lambda$1$Type`,1704),q(670,1,{}),L(kV,`BaseRoutingDirectionStrategy`,670),q(1870,670,{},r_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t+e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(f,o),up(s.a,i),YM(this,s,a,i,!1),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1),o=t+p.o*n,a=p,i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1)),i=new k(g,o),up(s.a,i),YM(this,s,a,i,!1)))},Q.zg=function(e){return e.i.n.a+e.n.a+e.a.a},Q.Ag=function(){return nP(),m5},Q.Bg=function(){return nP(),Z8},L(kV,`NorthToSouthRoutingStrategy`,1870),q(1871,670,{},i_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t-e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(f,o),up(s.a,i),YM(this,s,a,i,!1),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1),o=t-p.o*n,a=p,i=new k(m,o),up(s.a,i),YM(this,s,a,i,!1)),i=new k(g,o),up(s.a,i),YM(this,s,a,i,!1)))},Q.zg=function(e){return e.i.n.a+e.n.a+e.a.a},Q.Ag=function(){return nP(),Z8},Q.Bg=function(){return nP(),m5},L(kV,`SouthToNorthRoutingStrategy`,1871),q(1869,670,{},a_e),Q.yg=function(e,t,n){var i,a,o,s,c,l,u,d,f,p,m,h,g;if(!(e.r&&!e.q))for(d=t+e.o*n,u=new w(e.n);u.aGL&&(o=d,a=e,i=new k(o,f),up(s.a,i),YM(this,s,a,i,!0),p=e.r,p&&(m=D(N(SO(p.e,0))),i=new k(o,m),up(s.a,i),YM(this,s,a,i,!0),o=t+p.o*n,a=p,i=new k(o,m),up(s.a,i),YM(this,s,a,i,!0)),i=new k(o,g),up(s.a,i),YM(this,s,a,i,!0)))},Q.zg=function(e){return e.i.n.b+e.n.b+e.a.b},Q.Ag=function(){return nP(),X8},Q.Bg=function(){return nP(),g5},L(kV,`WestToEastRoutingStrategy`,1869),q(828,1,{},yft),Q.Ib=function(){return CA(this.a)},Q.b=0,Q.c=!1,Q.d=!1,Q.f=0,L(jV,`NubSpline`,828),q(418,1,{418:1},vst,FLe),L(jV,`NubSpline/PolarCP`,418),q(1480,1,yV,P3e),Q.rg=function(e){return G5e(P(e,36))},Q.Kf=function(e,t){w_t(this,P(e,36),t)};var fPt,pPt,mPt,hPt,gPt;L(jV,`SplineEdgeRouter`,1480),q(274,1,{274:1},Ly),Q.Ib=function(){return this.a+` ->(`+this.c+`) `+this.b},Q.c=0,L(jV,`SplineEdgeRouter/Dependency`,274),q(465,22,{3:1,34:1,22:1,465:1},rSe);var j2,M2,_Pt=aS(jV,`SplineEdgeRouter/SideToProcess`,465,eG,ELe,fAe),vPt;q(1481,1,vF,tae),Q.Mb=function(e){return iM(),!P(e,131).o},L(jV,`SplineEdgeRouter/lambda$0$Type`,1481),q(1482,1,{},nae),Q.Ze=function(e){return iM(),P(e,131).v+1},L(jV,`SplineEdgeRouter/lambda$1$Type`,1482),q(1483,1,$P,Qxe),Q.Cd=function(e){TMe(this.a,this.b,P(e,42))},L(jV,`SplineEdgeRouter/lambda$2$Type`,1483),q(1484,1,$P,$xe),Q.Cd=function(e){EMe(this.a,this.b,P(e,42))},L(jV,`SplineEdgeRouter/lambda$3$Type`,1484),q(131,1,{34:1,131:1},ttt,Xpt),Q.Fd=function(e){return Bve(this,P(e,131))},Q.b=0,Q.e=!1,Q.f=0,Q.g=0,Q.j=!1,Q.k=!1,Q.n=0,Q.o=!1,Q.p=!1,Q.q=!1,Q.s=0,Q.u=0,Q.v=0,Q.F=0,L(jV,`SplineSegment`,131),q(468,1,{468:1},rae),Q.a=0,Q.b=!1,Q.c=!1,Q.d=!1,Q.e=!1,Q.f=0,L(jV,`SplineSegment/EdgeInformation`,468),q(1198,1,{},iae),L(FV,ebt,1198),q(1199,1,GI,aae),Q.Ne=function(e,t){return Snt(P(e,121),P(t,121))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(FV,tbt,1199),q(1197,1,{},_ye),L(FV,`MrTree`,1197),q(405,22,{3:1,34:1,22:1,405:1,188:1,196:1},fc),Q.dg=function(){return wnt(this)},Q.qg=function(){return wnt(this)};var N2,P2,F2,I2,yPt=aS(FV,`TreeLayoutPhases`,405,eG,DVe,pAe),bPt;q(1112,205,OL,aOe),Q.rf=function(e,t){var n,r,i,a,o,s,c,l;for(ki(Od(J(e,(rN(),dFt))))||S_((n=new ir((Ko(),new Ei(e))),n)),o=t.eh(IV),o.Ug(`build tGraph`,1),s=(c=new zy,VC(c,e),W(c,(tP(),t4),e),l=new Dr,Lut(e,c,l),fdt(e,c,l),c),o.Vg(),o=t.eh(IV),o.Ug(`Split graph`,1),a=Wut(this.a,s),o.Vg(),i=new w(a);i.a`+hv(this.c):`e_`+US(this)},L(RV,`TEdge`,65),q(121,137,{3:1,121:1,96:1,137:1},zy),Q.Ib=function(){var e,t,n,r,i=null;for(r=dO(this.b,0);r.b!=r.d.c;)n=P(Lv(r),40),i+=(n.c==null||n.c.length==0?`n_`+n.g:`n_`+n.c)+` +`;for(t=dO(this.a,0);t.b!=t.d.c;)e=P(Lv(t),65),i+=(e.b&&e.c?hv(e.b)+`->`+hv(e.c):`e_`+US(e))+` +`;return i};var xPt=L(RV,`TGraph`,121);q(643,508,{3:1,508:1,643:1,96:1,137:1}),L(RV,`TShape`,643),q(40,643,{3:1,508:1,40:1,643:1,96:1,137:1},Ow),Q.Ib=function(){return hv(this)};var L2=L(RV,`TNode`,40);q(236,1,rF,hr),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){var e;return e=dO(this.a.d,0),new gr(e)},L(RV,`TNode/2`,236),q(329,1,VP,gr),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(Lv(this.a),65).c},Q.Ob=function(){return Za(this.a)},Q.Qb=function(){wx(this.a)},L(RV,`TNode/2/1`,329),q(1923,1,DR,fae),Q.Kf=function(e,t){gvt(this,P(e,121),t)},L(BV,`CompactionProcessor`,1923),q(1924,1,GI,Nme),Q.Ne=function(e,t){return eXe(this.a,P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$0$Type`,1924),q(1925,1,vF,tSe),Q.Mb=function(e){return qIe(this.b,this.a,P(e,42))},Q.a=0,Q.b=0,L(BV,`CompactionProcessor/lambda$1$Type`,1925),q(1934,1,GI,pae),Q.Ne=function(e,t){return FPe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$10$Type`,1934),q(1935,1,GI,mae),Q.Ne=function(e,t){return tEe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$11$Type`,1935),q(1936,1,GI,hae),Q.Ne=function(e,t){return IPe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$12$Type`,1936),q(1926,1,vF,Pme),Q.Mb=function(e){return nTe(this.a,P(e,42))},Q.a=0,L(BV,`CompactionProcessor/lambda$2$Type`,1926),q(1927,1,vF,Fme),Q.Mb=function(e){return rTe(this.a,P(e,42))},Q.a=0,L(BV,`CompactionProcessor/lambda$3$Type`,1927),q(1928,1,vF,gae),Q.Mb=function(e){return P(e,40).c.indexOf(LV)==-1},L(BV,`CompactionProcessor/lambda$4$Type`,1928),q(1929,1,{},Ime),Q.Kb=function(e){return UBe(this.a,P(e,40))},Q.a=0,L(BV,`CompactionProcessor/lambda$5$Type`,1929),q(1930,1,{},Lme),Q.Kb=function(e){return WGe(this.a,P(e,40))},Q.a=0,L(BV,`CompactionProcessor/lambda$6$Type`,1930),q(1931,1,GI,Rme),Q.Ne=function(e,t){return jUe(this.a,P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$7$Type`,1931),q(1932,1,GI,zme),Q.Ne=function(e,t){return MUe(this.a,P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$8$Type`,1932),q(1933,1,GI,_ae),Q.Ne=function(e,t){return nEe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(BV,`CompactionProcessor/lambda$9$Type`,1933),q(1921,1,DR,vae),Q.Kf=function(e,t){Gct(P(e,121),t)},L(BV,`DirectionProcessor`,1921),q(1913,1,DR,iOe),Q.Kf=function(e,t){sdt(this,P(e,121),t)},L(BV,`FanProcessor`,1913),q(1937,1,DR,yae),Q.Kf=function(e,t){Sct(P(e,121),t)},L(BV,`GraphBoundsProcessor`,1937),q(1938,1,{},bae),Q.Ye=function(e){return P(e,40).e.a},L(BV,`GraphBoundsProcessor/lambda$0$Type`,1938),q(1939,1,{},xae),Q.Ye=function(e){return P(e,40).e.b},L(BV,`GraphBoundsProcessor/lambda$1$Type`,1939),q(1940,1,{},Sae),Q.Ye=function(e){return Wbe(P(e,40))},L(BV,`GraphBoundsProcessor/lambda$2$Type`,1940),q(1941,1,{},Cae),Q.Ye=function(e){return Ube(P(e,40))},L(BV,`GraphBoundsProcessor/lambda$3$Type`,1941),q(262,22,{3:1,34:1,22:1,262:1,196:1},pc),Q.dg=function(){switch(this.g){case 0:return new S_e;case 1:return new iOe;case 2:return new x_e;case 3:return new Oae;case 4:return new Tae;case 8:return new wae;case 5:return new vae;case 6:return new Aae;case 7:return new fae;case 9:return new yae;case 10:return new jae;default:throw E(new Fi(FR+(this.f==null?``+this.g:this.f)))}};var SPt,CPt,wPt,TPt,EPt,DPt,OPt,kPt,APt,jPt,R2,MPt=aS(BV,IR,262,eG,qYe,mAe),NPt;q(1920,1,DR,wae),Q.Kf=function(e,t){Bgt(P(e,121),t)},L(BV,`LevelCoordinatesProcessor`,1920),q(1918,1,DR,Tae),Q.Kf=function(e,t){fot(this,P(e,121),t)},Q.a=0,L(BV,`LevelHeightProcessor`,1918),q(1919,1,rF,Eae),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return Vg(),bo(),tK},L(BV,`LevelHeightProcessor/1`,1919),q(1914,1,DR,x_e),Q.Kf=function(e,t){cct(this,P(e,121),t)},L(BV,`LevelProcessor`,1914),q(1915,1,vF,Dae),Q.Mb=function(e){return ki(Od(K(P(e,40),(tP(),a4))))},L(BV,`LevelProcessor/lambda$0$Type`,1915),q(1916,1,DR,Oae),Q.Kf=function(e,t){Xet(this,P(e,121),t)},Q.a=0,L(BV,`NeighborsProcessor`,1916),q(1917,1,rF,kae),Q.Jc=function(e){ly(this,e)},Q.Kc=function(){return Vg(),bo(),tK},L(BV,`NeighborsProcessor/1`,1917),q(1922,1,DR,Aae),Q.Kf=function(e,t){odt(this,P(e,121),t)},Q.a=0,L(BV,`NodePositionProcessor`,1922),q(1912,1,DR,S_e),Q.Kf=function(e,t){qpt(this,P(e,121),t)},L(BV,`RootProcessor`,1912),q(1942,1,DR,jae),Q.Kf=function(e,t){b4e(P(e,121),t)},L(BV,`Untreeifyer`,1942),q(392,22,{3:1,34:1,22:1,392:1},mc);var z2,B2,PPt,FPt=aS(HV,`EdgeRoutingMode`,392,eG,dze,hAe),IPt,V2,H2,U2,LPt,RPt,W2,G2,zPt,K2,BPt,q2,J2,Y2,X2,Z2,Q2,$2,e4,t4,n4,r4,VPt,HPt,i4,a4,o4,s4;q(862,1,nL,Pue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UV),``),uxt),`Turns on Tree compaction which decreases the size of the whole tree by placing nodes of multiple levels in one large level`),(rd(),!1)),(VA(),R3)),bG),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WV),``),`Edge End Texture Length`),`Should be set to the length of the texture at the end of an edge. This value can be used to improve the Edge Routing.`),7),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,axt),``),`Tree Level`),`The index for the tree level the node is in`),G(0)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oxt),``),uxt),`When set to a positive number this option will force the algorithm to place the node to the specified position within the trees layer if weighting is set to constraint`),G(-1)),H3),DG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sxt),``),`Weighting of Nodes`),`Which weighting to use when computing a node order.`),QPt),B3),wFt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cxt),``),`Edge Routing Mode`),`Chooses an Edge Routing algorithm.`),KPt),B3),FPt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lxt),``),`Search Order`),`Which search order to use when computing a spanning tree.`),YPt),B3),DFt),sE(F3)))),b_t((new Lue,e))};var UPt,WPt,GPt,KPt,qPt,JPt,YPt,XPt,ZPt,QPt;L(HV,`MrTreeMetaDataProvider`,862),q(1006,1,nL,Lue),Q.hf=function(e){b_t(e)};var $Pt,eFt,tFt,c4,nFt,rFt,l4,iFt,aFt,oFt,sFt,cFt,lFt,uFt,dFt,fFt,pFt,mFt,u4,d4,hFt,gFt,_Ft,f4,vFt,yFt,bFt,xFt,SFt,p4,CFt;L(HV,`MrTreeOptions`,1006),q(1007,1,{},Mae),Q.sf=function(){var e;return e=new aOe,e},Q.tf=function(e){},L(HV,`MrTreeOptions/MrtreeFactory`,1007),q(353,22,{3:1,34:1,22:1,353:1},hc);var m4,h4,g4,_4,wFt=aS(HV,`OrderWeighting`,353,eG,OVe,gAe),TFt;q(433,22,{3:1,34:1,22:1,433:1},iSe);var EFt,v4,DFt=aS(HV,`TreeifyingOrder`,433,eG,wLe,_Ae),OFt;q(1486,1,yV,Rue),Q.rg=function(e){return P(e,121),kFt},Q.Kf=function(e,t){jYe(this,P(e,121),t)};var kFt;L(`org.eclipse.elk.alg.mrtree.p1treeify`,`DFSTreeifyer`,1486),q(1487,1,yV,zue),Q.rg=function(e){return P(e,121),AFt},Q.Kf=function(e,t){hct(this,P(e,121),t)};var AFt;L(KV,`NodeOrderer`,1487),q(1494,1,{},Jae),Q.td=function(e){return MMe(e)},L(KV,`NodeOrderer/0methodref$lambda$6$Type`,1494),q(1488,1,vF,Yae),Q.Mb=function(e){return Rx(),ki(Od(K(P(e,40),(tP(),a4))))},L(KV,`NodeOrderer/lambda$0$Type`,1488),q(1489,1,vF,Xae),Q.Mb=function(e){return Rx(),P(K(P(e,40),(rN(),u4)),17).a<0},L(KV,`NodeOrderer/lambda$1$Type`,1489),q(1490,1,vF,Vme),Q.Mb=function(e){return OJe(this.a,P(e,40))},L(KV,`NodeOrderer/lambda$2$Type`,1490),q(1491,1,vF,Bme),Q.Mb=function(e){return qBe(this.a,P(e,40))},L(KV,`NodeOrderer/lambda$3$Type`,1491),q(1492,1,GI,Zae),Q.Ne=function(e,t){return eqe(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(KV,`NodeOrderer/lambda$4$Type`,1492),q(1493,1,vF,Qae),Q.Mb=function(e){return Rx(),P(K(P(e,40),(tP(),G2)),17).a!=0},L(KV,`NodeOrderer/lambda$5$Type`,1493),q(1495,1,yV,Iue),Q.rg=function(e){return P(e,121),jFt},Q.Kf=function(e,t){Sut(this,P(e,121),t)},Q.b=0;var jFt;L(`org.eclipse.elk.alg.mrtree.p3place`,`NodePlacer`,1495),q(1496,1,yV,Fue),Q.rg=function(e){return P(e,121),MFt},Q.Kf=function(e,t){Hlt(P(e,121),t)};var MFt;L(qV,`EdgeRouter`,1496),q(1498,1,GI,qae),Q.Ne=function(e,t){return _u(P(e,17).a,P(t,17).a)},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/0methodref$compare$Type`,1498),q(1503,1,{},Pae),Q.Ye=function(e){return D(N(e))},L(qV,`EdgeRouter/1methodref$doubleValue$Type`,1503),q(1505,1,GI,Fae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/2methodref$compare$Type`,1505),q(1507,1,GI,Iae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/3methodref$compare$Type`,1507),q(1509,1,{},Nae),Q.Ye=function(e){return D(N(e))},L(qV,`EdgeRouter/4methodref$doubleValue$Type`,1509),q(1511,1,GI,Lae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/5methodref$compare$Type`,1511),q(1513,1,GI,Rae),Q.Ne=function(e,t){return aE(D(N(e)),D(N(t)))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/6methodref$compare$Type`,1513),q(1497,1,{},zae),Q.Kb=function(e){return zx(),P(K(P(e,40),(rN(),p4)),17)},L(qV,`EdgeRouter/lambda$0$Type`,1497),q(1508,1,{},Bae),Q.Kb=function(e){return TEe(P(e,40))},L(qV,`EdgeRouter/lambda$11$Type`,1508),q(1510,1,{},dSe),Q.Kb=function(e){return CMe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$13$Type`,1510),q(1512,1,{},fSe),Q.Kb=function(e){return EEe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$15$Type`,1512),q(1514,1,GI,Vae),Q.Ne=function(e,t){return R2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$17$Type`,1514),q(1515,1,GI,Hae),Q.Ne=function(e,t){return z2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$18$Type`,1515),q(1516,1,GI,Uae),Q.Ne=function(e,t){return V2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$19$Type`,1516),q(1499,1,vF,Hme),Q.Mb=function(e){return GLe(this.a,P(e,40))},Q.a=0,L(qV,`EdgeRouter/lambda$2$Type`,1499),q(1517,1,GI,Wae),Q.Ne=function(e,t){return B2e(P(e,65),P(t,65))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$20$Type`,1517),q(1500,1,GI,Gae),Q.Ne=function(e,t){return Bje(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$3$Type`,1500),q(1501,1,GI,Kae),Q.Ne=function(e,t){return Vje(P(e,40),P(t,40))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`EdgeRouter/lambda$4$Type`,1501),q(1502,1,{},$ae),Q.Kb=function(e){return DEe(P(e,40))},L(qV,`EdgeRouter/lambda$5$Type`,1502),q(1504,1,{},pSe),Q.Kb=function(e){return wMe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$7$Type`,1504),q(1506,1,{},mSe),Q.Kb=function(e){return OEe(this.b,this.a,P(e,40))},Q.a=0,Q.b=0,L(qV,`EdgeRouter/lambda$9$Type`,1506),q(675,1,{675:1},d3e),Q.e=0,Q.f=!1,Q.g=!1,L(qV,`MultiLevelEdgeNodeNodeGap`,675),q(1943,1,GI,eoe),Q.Ne=function(e,t){return jRe(P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`MultiLevelEdgeNodeNodeGap/lambda$0$Type`,1943),q(1944,1,GI,toe),Q.Ne=function(e,t){return MRe(P(e,240),P(t,240))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(qV,`MultiLevelEdgeNodeNodeGap/lambda$1$Type`,1944);var y4;q(501,22,{3:1,34:1,22:1,501:1,188:1,196:1},aSe),Q.dg=function(){return Z1e(this)},Q.qg=function(){return Z1e(this)};var b4,x4,NFt=aS(pxt,`RadialLayoutPhases`,501,eG,_Le,vAe),PFt;q(1113,205,OL,gye),Q.rf=function(e,t){var n=Wot(this,e),r,i,a,o,s;if(t.Ug(`Radial layout`,n.c.length),ki(Od(J(e,(PA(),dIt))))||S_((r=new ir((Ko(),new Ei(e))),r)),s=Y5e(e),OO(e,(Pd(),y4),s),!s)throw E(new Fi(`The given graph is not a tree!`));for(i=D(N(J(e,M4))),i==0&&(i=ont(e)),OO(e,M4,i),o=new w(Wot(this,e));o.a=3)for(S=P(H(b,0),27),ee=P(H(b,1),27),o=0;o+2=S.f+ee.f+d||ee.f>=x.f+S.f+d){ne=!0;break}++o}else ne=!0;if(!ne){for(p=b.i,c=new Lu(b);c.e!=c.i.gc();)s=P(gO(c),27),OO(s,(vP(),H6),G(p)),--p;Xdt(e,new di),t.Vg();return}for(n=(cg(this.a),Um(this.a,(ED(),L4),P(J(e,_Lt),188)),Um(this.a,R4,P(J(e,uLt),188)),Um(this.a,z4,P(J(e,mLt),188)),Bl(this.a,(re=new Zh,vp(re,L4,(LO(),H4)),vp(re,R4,V4),ki(Od(J(e,nLt)))&&vp(re,L4,B4),re)),BN(this.a,e)),u=1/n.c.length,te=0,h=new w(n);h.a0&&ZQe((sv(t-1,e.length),e.charCodeAt(t-1)),wbt);)--t;if(r>=t)throw E(new Fi(`The given string does not contain any numbers.`));if(i=nN((Zy(r,t,e.length),e.substr(r,t-r)),`,|;|\r| +`),i.length!=2)throw E(new Fi(`Exactly two numbers are expected, `+i.length+` were found.`));try{this.a=OA(qA(i[0])),this.b=OA(qA(i[1]))}catch(e){throw e=ew(e),j(e,130)?(n=e,E(new Fi(Tbt+n))):E(e)}},Q.Ib=function(){return`(`+this.a+`,`+this.b+`)`},Q.a=0,Q.b=0;var K3=L(MR,`KVector`,8);q(75,67,{3:1,4:1,20:1,31:1,56:1,16:1,67:1,15:1,75:1,423:1},ai,Ma,LEe),Q.Pc=function(){return xQe(this)},Q.cg=function(e){var t,n,r=nN(e,`,|;|\\(|\\)|\\[|\\]|\\{|\\}| | | +`),i,a,o;Fg(this);try{for(n=0,a=0,i=0,o=0;n0&&(a%2==0?i=OA(r[n]):o=OA(r[n]),a>0&&a%2!=0&&up(this,new k(i,o)),++a),++n}catch(e){throw e=ew(e),j(e,130)?(t=e,E(new Fi(`The given string does not match the expected format for vectors.`+t))):E(e)}},Q.Ib=function(){for(var e=new Gu(`(`),t=dO(this,0),n;t.b!=t.d.c;)n=P(Lv(t),8),gl(e,n.a+`,`+n.b),t.b!=t.d.c&&(e.a+=`; `);return(e.a+=`)`,e).a};var BRt=L(MR,`KVectorChain`,75);q(255,22,{3:1,34:1,22:1,255:1},Dc);var q3,J3,Y3,X3,Z3,Q3,VRt=aS(AH,`Alignment`,255,eG,lGe,HAe),HRt;q(991,1,nL,Jue),Q.hf=function(e){cdt(e)};var URt,$3,WRt,GRt,KRt,qRt,JRt,YRt,XRt,ZRt,QRt,$Rt;L(AH,`BoxLayouterOptions`,991),q(992,1,{},fse),Q.sf=function(){var e;return e=new hse,e},Q.tf=function(e){},L(AH,`BoxLayouterOptions/BoxFactory`,992),q(298,22,{3:1,34:1,22:1,298:1},Ac);var e6,t6,n6,r6,i6,a6,o6=aS(AH,`ContentAlignment`,298,eG,uGe,UAe),ezt;q(699,1,nL,Yue),Q.hf=function(e){jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,pSt),``),`Layout Algorithm`),`Select a specific layout algorithm.`),(VA(),W3)),LG),sE((uO(),F3))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,mSt),``),`Resolved Layout Algorithm`),`Meta data associated with the selected algorithm.`),U3),PRt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,GB),``),`Alignment`),`Alignment of the selected node relative to other nodes; the exact meaning depends on the used algorithm.`),nzt),B3),VRt),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,FL),``),`Aspect Ratio`),`The desired aspect ratio of the drawing, that is the quotient of width by height.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,hSt),``),`Bend Points`),`A fixed list of bend points for the edge. This is used by the 'Fixed Layout' algorithm to specify a pre-defined routing for an edge. The vector chain must include the source point, any bend points, and the target point, so it must have at least two points.`),U3),BRt),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rV),``),`Content Alignment`),`Specifies how the content of a node are aligned. Each node can individually control the alignment of its contents. I.e. if a node should be aligned top left in its parent node, the parent node should specify that option.`),szt),V3),o6),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,WB),``),`Debug Mode`),`Whether additional debug information shall be generated.`),(rd(),!1)),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,JB),``),Vyt),`Overall direction of edges: horizontal (right / left) or vertical (down / up).`),czt),B3),a8),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xB),``),`Edge Routing`),`What kind of edge routing style should be applied for the content of a parent node. Algorithms may also set this option to single edges in order to mark them as splines. The bend point list of edges with this option set to SPLINES must be interpreted as control points for a piecewise cubic spline.`),dzt),B3),p8),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dSt),``),`Expand Nodes`),`If active, nodes are expanded to fill the area of their parent.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bB),``),`Hierarchy Handling`),"Determines whether separate layout runs are triggered for different compound nodes in a hierarchical graph. Setting a node's hierarchy handling to `INCLUDE_CHILDREN` will lay out that node and all of its descendants in a single layout run, until a descendant is encountered which has its hierarchy handling set to `SEPARATE_CHILDREN`. In general, `SEPARATE_CHILDREN` will ensure that a new layout run is triggered for a node with that setting. Including multiple levels of hierarchy in a single layout run may allow cross-hierarchical edges to be laid out properly. If the root node is set to `INHERIT` (or not set at all), the default behavior is `SEPARATE_CHILDREN`."),hzt),B3),yBt),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,IL),``),`Padding`),`The padding to be left to a parent element's border when placing child elements. This can also serve as an output option of a layout algorithm if node size calculation is setup appropriately.`),Tzt),U3),ZJ),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,tR),``),`Interactive`),`Whether the algorithm should be run in interactive mode for the content of a parent node. What this means exactly depends on how the specific algorithm interprets this option. Usually in the interactive mode algorithms try to modify the current layout as little as possible.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,hV),``),`interactive Layout`),`Whether the graph should be changeable interactively and by setting constraints`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iR),``),`Omit Node Micro Layout`),`Node micro layout comprises the computation of node dimensions (if requested), the placement of ports and their labels, and the placement of node labels. The functionality is implemented independent of any specific layout algorithm and shouldn't have any negative impact on the layout algorithm's performance itself. Yet, if any unforeseen behavior occurs, this option allows to deactivate the micro layout.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,nR),``),`Port Constraints`),`Defines constraints of the position of the ports of a node.`),Nzt),B3),DBt),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,fV),``),`Position`),`The position of a node, port, or label. This is used by the 'Fixed Layout' algorithm to specify a pre-defined position.`),U3),K3),Zp(P3,U(O(L3,1),Z,170,0,[I3,N3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,XL),``),`Priority`),`Defines the priority of an object; its meaning depends on the specific layout algorithm and the context where it is used.`),H3),DG),Zp(P3,U(O(L3,1),Z,170,0,[M3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,$L),``),`Randomization Seed`),`Seed used for pseudo-random number generators to control the layout algorithm. If the value is 0, the seed shall be determined pseudo-randomly (e.g. from the system time).`),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,eR),``),`Separate Connected Components`),`Whether each connected component should be processed separately.`),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,iV),``),`Junction Points`),`This option is not used as option, but as output of the layout algorithms. It is attached to edges and determines the points where junction symbols should be drawn in order to represent hyperedges with orthogonal routing. Whether such points are computed depends on the chosen layout algorithm and edge routing style. The points are put into the vector chain with no specific order.`),_zt),U3),BRt),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sV),``),`Comment Box`),`Whether the node should be regarded as a comment box instead of a regular node. In that case its placement should be similar to how labels are handled. Any edges incident to a comment box specify to which graph elements the comment is related.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cV),``),`Hypernode`),`Whether the node should be handled as a hypernode.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,gSt),``),`Label Manager`),`Label managers can shorten labels upon a layout algorithm's request.`),U3),uUt),Zp(F3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pV),``),`Margins`),`Margins define additional space around the actual bounds of a graph element. For instance, ports or labels being placed on the outside of a node's border might introduce such a margin. The margin is used to guarantee non-overlap of other graph elements with those ports or labels.`),vzt),U3),HJ),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,HB),``),`No Layout`),`No layout is done for the associated element. This is used to mark parts of a diagram to avoid their inclusion in the layout graph, or to mark parts of the layout graph to prevent layout engines from processing them. If you wish to exclude the contents of a compound node from automatic layout, while the node itself is still considered on its own layer, use the 'Fixed Layout' algorithm for that node.`),!1),R3),bG),Zp(P3,U(O(L3,1),Z,170,0,[M3,I3,N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,_St),``),`Scale Factor`),`The scaling factor to be applied to the corresponding node in recursive layout. It causes the corresponding node's size to be adjusted, and its ports and labels to be sized and placed accordingly after the layout of that node has been determined (and before the node itself and its siblings are arranged). The scaling is not reverted afterwards, so the resulting layout graph contains the adjusted size and position data. This option is currently not supported if 'Layout Hierarchy' is set.`),1),z3),TG),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,vSt),``),`Child Area Width`),`The width of the area occupied by the laid out children of a node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,ySt),``),`Child Area Height`),`The height of the area occupied by the laid out children of a node.`),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uR),``),aSt),`Turns topdown layout on and off. If this option is enabled, hierarchical layout will be computed first for the root node and then for its children recursively. Layouts are then scaled down to fit the area provided by their parents. Graphs must follow a certain structure for topdown layout to work properly. {@link TopdownNodeTypes.PARALLEL_NODE} nodes must have children of type {@link TopdownNodeTypes.HIERARCHICAL_NODE} and must define {@link topdown.hierarchicalNodeWidth} and {@link topdown.hierarchicalNodeAspectRatio} for their children. Furthermore they need to be laid out using an algorithm that is a {@link TopdownLayoutProvider}. Hierarchical nodes can also be parents of other hierarchical nodes and can optionally use a {@link TopdownSizeApproximator} to dynamically set sizes during topdown layout. In this case {@link topdown.hierarchicalNodeWidth} and {@link topdown.hierarchicalNodeAspectRatio} should be set on the node itself rather than the parent. The values are then used by the size approximator as base values. Hierarchical nodes require the layout option {@link nodeSize.fixedGraphSize} to be true to prevent the algorithm used there from resizing the hierarchical node. This option is not supported if 'Hierarchy Handling' is set to 'INCLUDE_CHILDREN'`),!1),R3),bG),sE(F3)))),wv(e,uR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,bSt),``),`Animate`),`Whether the shift from the old layout to the new computed layout shall be animated.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,xSt),``),`Animation Time Factor`),`Factor for computation of animation time. The higher the value, the longer the animation time. If the value is 0, the resulting time is always equal to the minimum defined by 'Minimal Animation Time'.`),G(100)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,SSt),``),`Layout Ancestors`),`Whether the hierarchy levels on the path from the selected element to the root of the diagram shall be included in the layout process.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,CSt),``),`Maximal Animation Time`),`The maximal time for animations, in milliseconds.`),G(4e3)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,wSt),``),`Minimal Animation Time`),`The minimal time for animations, in milliseconds.`),G(400)),H3),DG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,TSt),``),`Progress Bar`),`Whether a progress bar shall be displayed during layout computations.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ESt),``),`Validate Graph`),`Whether the graph shall be validated before any layout algorithm is applied. If this option is enabled and at least one error is found, the layout process is aborted and a message is shown to the user.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,DSt),``),`Validate Options`),`Whether layout options shall be validated before any layout algorithm is applied. If this option is enabled and at least one error is found, the layout process is aborted and a message is shown to the user.`),!0),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,OSt),``),`Zoom to Fit`),`Whether the zoom level shall be set to view the whole diagram after layout.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fSt),`box`),`Box Layout Mode`),`Configures the packing mode used by the {@link BoxLayoutProvider}. If SIMPLE is not required (neither priorities are used nor the interactive mode), GROUP_DEC can improve the packing and decrease the area. GROUP_MIXED and GROUP_INC may, in very specific scenarios, work better.`),azt),B3),JBt),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,AB),SB),`Comment Comment Spacing`),`Spacing to be preserved between a comment box and other comment boxes connected to the same node. The space left between comment boxes of different nodes is controlled by the node-node spacing.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jB),SB),`Comment Node Spacing`),`Spacing to be preserved between a node and its connected comment boxes. The space left between a node and the comments of another node is controlled by the node-node spacing.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NL),SB),`Components Spacing`),`Spacing to be preserved between pairs of connected components. This option is only relevant if 'separateConnectedComponents' is activated.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,MB),SB),`Edge Spacing`),`Spacing to be preserved between any two edges. Note that while this can somewhat easily be satisfied for the segments of orthogonally drawn edges, it is harder for general polylines or splines.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QL),SB),`Edge Label Spacing`),`The minimal distance to be preserved between a label and the edge it is associated with. Note that the placement of a label is influenced by the 'edgelabels.placement' option.`),2),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NB),SB),`Edge Node Spacing`),`Spacing to be preserved between nodes and edges.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,PB),SB),`Label Spacing`),`Determines the amount of space to be left between two labels of the same graph element.`),0),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,LB),SB),`Label Node Spacing`),`Spacing to be preserved between labels and the border of node they are associated with. Note that the placement of a label is influenced by the 'nodelabels.placement' option.`),5),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,FB),SB),`Horizontal spacing between Label and Port`),`Horizontal spacing to be preserved between labels and the ports they are associated with. Note that the placement of a label is influenced by the 'portlabels.placement' option.`),1),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,IB),SB),`Vertical spacing between Label and Port`),`Vertical spacing to be preserved between labels and the ports they are associated with. Note that the placement of a label is influenced by the 'portlabels.placement' option.`),1),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZL),SB),`Node Spacing`),`The minimal distance to be preserved between each two nodes.`),20),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,RB),SB),`Node Self Loop Spacing`),`Spacing to be preserved between a node and its self loops.`),10),z3),TG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,zB),SB),`Port Spacing`),`Spacing between pairs of ports of the same node.`),10),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,BB),SB),`Individual Spacing`),`Allows to specify individual spacing values for graph elements that shall be different from the value specified for the element's parent.`),U3),XBt),Zp(P3,U(O(L3,1),Z,170,0,[M3,I3,N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mV),SB),`Additional Port Space`),`Additional space around the sets of ports on each node side. For each side of a node, this option can reserve additional space before and after the ports on each side. For example, a top spacing of 20 makes sure that the first port on the western and eastern side is 20 units away from the northern border.`),Yzt),U3),HJ),sE(F3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,dV),PSt),`Layout Partition`),`Partition to which the node belongs. This requires Layout Partitioning to be active. Nodes with lower partition IDs will appear to the left of nodes with higher partition IDs (assuming a left-to-right layout direction).`),H3),DG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,dV,uV,kzt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,uV),PSt),`Layout Partitioning`),`Whether to activate partitioned layout. This will allow to group nodes through the Layout Partition option. a pair of nodes with different partition indices is then placed such that the node with lower index is placed to the left of the other node (with left-to-right layout direction). Depending on the layout algorithm, this may only be guaranteed to work if all nodes have a layout partition configured, or at least if edges that cross partitions are not part of a partition-crossing cycle.`),Dzt),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,YB),FSt),`Node Label Padding`),`Define padding for node labels that are placed inside of a node.`),bzt),U3),ZJ),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,cR),FSt),`Node Label Placement`),`Hints for where node labels are to be placed; if empty, the node label's position is not modified.`),xzt),V3),M8),Zp(P3,U(O(L3,1),Z,170,0,[N3]))))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,QB),MH),`Port Alignment`),`Defines the default port distribution for a node. May be overridden for each side individually.`),jzt),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,$B),MH),`Port Alignment (North)`),`Defines how ports on the northern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,eV),MH),`Port Alignment (South)`),`Defines how ports on the southern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,tV),MH),`Port Alignment (West)`),`Defines how ports on the western side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,nV),MH),`Port Alignment (East)`),`Defines how ports on the eastern side are placed, overriding the node's general port alignment.`),B3),I8),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,sR),NH),`Node Size Constraints`),`What should be taken into account when calculating a node's size. Empty size constraints specify that a node's size is already fixed and should not be changed.`),Szt),V3),S5),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,oR),NH),`Node Size Options`),`Options modifying the behavior of the size constraints set on a node. Each member of the set specifies something that should be taken into account when calculating node sizes. The empty set corresponds to no further modifications.`),wzt),V3),LBt),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,gR),NH),`Node Size Minimum`),`The minimal size to which a node can be reduced.`),Czt),U3),K3),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,aR),NH),`Fixed Graph Size`),`By default, the fixed layout provider will enlarge a graph until it is large enough to contain its children. If this option is set, it won't do so.`),!1),R3),bG),sE(F3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,aV),OB),`Edge Label Placement`),`Gives a hint on where to put edge labels.`),lzt),B3),rBt),sE(N3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,rR),OB),`Inline Edge Labels`),`If true, an edge label is placed directly on its edge. May only apply to center edge labels. This kind of label placement is only advisable if the label's rendering is such that it is not crossed by its edge and thus stays legible.`),!1),R3),bG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,kSt),`font`),`Font Name`),`Font name used for a label.`),W3),LG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,ASt),`font`),`Font Size`),`Font size used for a label.`),H3),DG),sE(N3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,lV),PH),`Port Anchor Offset`),`The offset to the port position where connections shall be attached.`),U3),K3),sE(I3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,oV),PH),`Port Index`),`The index of a port in the fixed order around a node. The order is assumed as clockwise, starting with the leftmost port on the top side. This option must be set if 'Port Constraints' is set to FIXED_ORDER and no specific positions are given for the ports. Additionally, the option 'Port Side' must be defined in this case.`),H3),DG),sE(I3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,UB),PH),`Port Side`),`The side of a node on which a port is situated. This option must be set if 'Port Constraints' is set to FIXED_SIDE or FIXED_ORDER and no specific positions are given for the ports.`),Izt),B3),_5),sE(I3)))),jE(e,new zA(Aa(ka(ja(wa(Oa(Ea(Da(new $t,VB),PH),`Port Border Offset`),`The offset of ports on the node border. With a positive offset the port is moved outside of the node, while with a negative offset the port is moved towards the inside. An offset of 0 means that the port is placed directly on the node border, i.e. if the port side is north, the port's south border touches the nodes's north border; if the port side is east, the port's west border touches the nodes's east border; if the port side is south, the port's north border touches the node's south border; if the port side is west, the port's east border touches the node's west border.`),z3),TG),sE(I3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,lR),ISt),`Port Label Placement`),`Decides on a placement method for port labels; if empty, the node label's position is not modified.`),Pzt),V3),Y8),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,XB),ISt),`Port Labels Next to Port`),`Use 'portLabels.placement': NEXT_TO_PORT_OF_POSSIBLE.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,ZB),ISt),`Treat Port Labels as Group`),`If this option is true (default), the labels of a port will be treated as a group when it comes to centering them next to their port. If this option is false, only the first label will be centered next to the port, with the others being placed below. This only applies to labels of eastern and western ports and will have no effect if labels are not placed next to their port.`),!0),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,dR),FH),`Topdown Scale Factor`),`The scaling factor to be applied to the nodes laid out within the node in recursive topdown layout. The difference to 'Scale Factor' is that the node itself is not scaled. This value has to be set on hierarchical nodes.`),1),z3),TG),sE(F3)))),wv(e,dR,mR,$zt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,jSt),FH),`Topdown Size Approximator`),`The size approximator to be used to set sizes of hierarchical nodes during topdown layout. The default value is null, which results in nodes keeping whatever size is defined for them e.g. through parent parallel node or by manually setting the size.`),null),B3),P5),sE(P3)))),wv(e,jSt,mR,tBt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,fR),FH),`Topdown Hierarchical Node Width`),`The fixed size of a hierarchical node when using topdown layout. If this value is set on a parallel node it applies to its children, when set on a hierarchical node it applies to the node itself.`),150),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,fR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,pR),FH),`Topdown Hierarchical Node Aspect Ratio`),`The fixed aspect ratio of a hierarchical node when using topdown layout. Default is 1/sqrt(2). If this value is set on a parallel node it applies to its children, when set on a hierarchical node it applies to the node itself.`),1.414),z3),TG),Zp(F3,U(O(L3,1),Z,170,0,[P3]))))),wv(e,pR,mR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,mR),FH),`Topdown Node Type`),`The different node types used for topdown layout. If the node type is set to {@link TopdownNodeTypes.PARALLEL_NODE} the algorithm must be set to a {@link TopdownLayoutProvider} such as {@link TopdownPacking}. The {@link nodeSize.fixedGraphSize} option is technically only required for hierarchical nodes.`),null),B3),BBt),sE(P3)))),wv(e,mR,aR,null),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,MSt),FH),`Topdown Scale Cap`),`Determines the upper limit for the topdown scale factor. The default value is 1.0 which ensures that nested children never end up appearing larger than their parents in terms of unit sizes such as the font size. If the limit is larger, nodes will fully utilize the available space, but it is counteriniuitive for inner nodes to have a larger scale than outer nodes.`),1),z3),TG),sE(F3)))),wv(e,MSt,mR,Qzt),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,KB),LSt),`Activate Inside Self Loops`),`Whether this node allows to route self loops inside of it instead of around it. If set to true, this will make the node a compound node if it isn't already, and will require the layout algorithm to support compound nodes with hierarchical ports.`),!1),R3),bG),sE(P3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,qB),LSt),`Inside Self Loop`),`Whether a self loop should be routed inside a node instead of around that node.`),!1),R3),bG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,PL),`edge`),`Edge Thickness`),`The thickness of an edge. This is a hint on the line width used to draw an edge, possibly requiring more space to be reserved for it.`),1),z3),TG),sE(M3)))),jE(e,new zA(Aa(ka(ja(Ta(wa(Oa(Ea(Da(new $t,NSt),`edge`),`Edge Type`),`The type of an edge. This is usually used for UML class diagrams, where associations must be handled differently from generalizations.`),pzt),B3),dBt),sE(M3)))),Uo(e,new ev(xa(Ca(Sa(new Qt,fI),`Layered`),`The layer-based method was introduced by Sugiyama, Tagawa and Toda in 1981. It emphasizes the direction of edges by pointing as many edges as possible into the same direction. The nodes are arranged in layers, which are sometimes called "hierarchies", and then reordered such that the number of edge crossings is minimized. Afterwards, concrete coordinates are computed for the nodes and edge bend points.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.orthogonal`),`Orthogonal`),`Orthogonal methods that follow the "topology-shape-metrics" approach by Batini, Nardelli and Tamassia '86. The first phase determines the topology of the drawing by applying a planarization technique, which results in a planar representation of the graph. The orthogonal shape is computed in the second phase, which aims at minimizing the number of edge bends, and is called orthogonalization. The third phase leads to concrete coordinates for nodes and edge bend points by applying a compaction method, thus defining the metrics.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,YL),`Force`),`Layout algorithms that follow physical analogies by simulating a system of attractive and repulsive forces. The first successful method of this kind was proposed by Eades in 1984.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.circle`),`Circle`),`Circular layout algorithms emphasize cycles or biconnected components of a graph by arranging them in circles. This is useful if a drawing is desired where such components are clearly grouped, or where cycles are shown as prominent OPTIONS of the graph.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,dxt),`Tree`),`Specialized layout methods for trees, i.e. acyclic graphs. The regular structure of graphs that have no undirected cycles can be emphasized using an algorithm of this type.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,`org.eclipse.elk.planar`),`Planar`),`Algorithms that require a planar or upward planar graph. Most of these algorithms are theoretically interesting, but not practically usable.`))),Uo(e,new ev(xa(Ca(Sa(new Qt,iH),`Radial`),`Radial layout algorithms usually position the nodes of the graph on concentric circles.`))),Klt((new Xue,e)),cdt((new Jue,e)),bct((new Zue,e))};var s6,tzt,nzt,c6,rzt,izt,azt,l6,u6,ozt,d6,szt,f6,p6,czt,m6,h6,lzt,uzt,dzt,fzt,pzt,mzt,g6,hzt,gzt,_6,v6,y6,b6,x6,_zt,S6,vzt,yzt,bzt,C6,xzt,w6,Szt,T6,E6,Czt,D6,wzt,O6,k6,A6,Tzt,Ezt,Dzt,Ozt,kzt,Azt,jzt,j6,M6,N6,P6,Mzt,F6,I6,Nzt,L6,R6,z6,Pzt,Fzt,B6,Izt,V6,H6,U6,W6,Lzt,G6,Rzt,zzt,Bzt,Vzt,Hzt,Uzt,K6,Wzt,q6,Gzt,Kzt,J6,qzt,Jzt,Yzt,Xzt,Y6,X6,Z6,Q6,Zzt,Qzt,$6,$zt,eBt,tBt;L(AH,`CoreOptions`,699),q(88,22,{3:1,34:1,22:1,88:1},jc);var e8,t8,n8,r8,i8,a8=aS(AH,Vyt,88,eG,KHe,WAe),nBt;q(278,22,{3:1,34:1,22:1,278:1},Mc);var o8,s8,c8,rBt=aS(AH,`EdgeLabelPlacement`,278,eG,Eze,GAe),iBt;q(223,22,{3:1,34:1,22:1,223:1},Nc);var l8,u8,d8,f8,p8=aS(AH,`EdgeRouting`,223,eG,MVe,KAe),aBt;q(321,22,{3:1,34:1,22:1,321:1},Pc);var oBt,sBt,cBt,lBt,m8,uBt,dBt=aS(AH,`EdgeType`,321,eG,cGe,qAe),fBt;q(989,1,nL,Xue),Q.hf=function(e){Klt(e)};var pBt,mBt,hBt,gBt,_Bt,vBt,h8;L(AH,`FixedLayouterOptions`,989),q(990,1,{},pse),Q.sf=function(){var e;return e=new wse,e},Q.tf=function(e){},L(AH,`FixedLayouterOptions/FixedFactory`,990),q(346,22,{3:1,34:1,22:1,346:1},Fc);var g8,_8,v8,yBt=aS(AH,`HierarchyHandling`,346,eG,wze,JAe),bBt;q(291,22,{3:1,34:1,22:1,291:1},Ic);var y8,b8,x8,S8,xBt=aS(AH,`LabelSide`,291,eG,jVe,YAe),SBt;q(95,22,{3:1,34:1,22:1,95:1},Lc);var C8,w8,T8,E8,D8,O8,k8,A8,j8,M8=aS(AH,`NodeLabelPlacement`,95,eG,Lqe,XAe),CBt;q(256,22,{3:1,34:1,22:1,256:1},Rc);var wBt,N8,P8,TBt,F8,I8=aS(AH,`PortAlignment`,256,eG,pUe,ZAe),EBt;q(101,22,{3:1,34:1,22:1,101:1},zc);var L8,R8,z8,B8,V8,H8,DBt=aS(AH,`PortConstraints`,101,eG,sGe,QAe),OBt;q(279,22,{3:1,34:1,22:1,279:1},Bc);var U8,W8,G8,K8,q8,J8,Y8=aS(AH,`PortLabelPlacement`,279,eG,oGe,$Ae),kBt;q(64,22,{3:1,34:1,22:1,64:1},Vc);var X8,Z8,Q8,$8,e5,t5,n5,r5,i5,a5,o5,s5,c5,l5,u5,d5,f5,p5,m5,h5,g5,_5=aS(AH,`PortSide`,64,eG,qHe,eje),ABt;q(993,1,nL,Zue),Q.hf=function(e){bct(e)};var jBt,MBt,NBt,PBt,FBt;L(AH,`RandomLayouterOptions`,993),q(994,1,{},mse),Q.sf=function(){var e;return e=new xse,e},Q.tf=function(e){},L(AH,`RandomLayouterOptions/RandomFactory`,994),q(386,22,{3:1,34:1,22:1,386:1},Hc);var v5,y5,b5,x5,S5=aS(AH,`SizeConstraint`,386,eG,AVe,tje),IBt;q(264,22,{3:1,34:1,22:1,264:1},Uc);var C5,w5,T5,E5,D5,O5,k5,A5,j5,LBt=aS(AH,`SizeOptions`,264,eG,fJe,nje),RBt;q(280,22,{3:1,34:1,22:1,280:1},Wc);var M5,zBt,N5,BBt=aS(AH,`TopdownNodeTypes`,280,eG,Dze,rje),VBt;q(347,22,RSt);var HBt,UBt,P5=aS(AH,`TopdownSizeApproximator`,347,eG,kLe,aje);q(987,347,RSt,AMe),Q.Tg=function(e){return T4e(e)},aS(AH,`TopdownSizeApproximator/1`,987,P5,null,null),q(988,347,RSt,cPe),Q.Tg=function(e){var t=P(J(e,(vP(),W6)),143),n,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee=(Ia(),m=new ii,m),te,ne,C;for(qj(ee,e),te=new Dr,o=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));o.e!=o.i.gc();)i=P(gO(o),27),y=(p=new ii,p),Gj(y,ee),qj(y,i),C=T4e(i),Ql(y,r.Math.max(i.g,C.a),r.Math.max(i.f,C.b)),XA(te.f,i,y);for(a=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));a.e!=a.i.gc();)for(i=P(gO(a),27),d=new Lu((!i.e&&(i.e=new cf(U5,i,7,4)),i.e));d.e!=d.i.gc();)u=P(gO(d),74),x=P(nl(Kp(te.f,i)),27),S=P(xh(te,H((!u.c&&(u.c=new cf(H5,u,5,8)),u.c),0)),27),b=(f=new nn,f),tb((!b.b&&(b.b=new cf(H5,b,4,7)),b.b),x),tb((!b.c&&(b.c=new cf(H5,b,5,8)),b.c),S),Hj(b,I_(x)),qj(b,u);g=P(h_(t.f),205);try{g.rf(ee,new Dse),bFe(t.f,g)}catch(e){throw e=ew(e),j(e,103)?(h=e,E(h)):E(e)}return qy(ee,u6)||qy(ee,l6)||G_t(ee),l=D(N(J(ee,u6))),c=D(N(J(ee,l6))),s=l/c,n=D(N(J(ee,X6)))*r.Math.sqrt((!ee.a&&(ee.a=new F($5,ee,10,11)),ee.a).i),ne=P(J(ee,A6),107),v=ne.b+ne.c+1,_=ne.d+ne.a+1,new k(r.Math.max(v,n),r.Math.max(_,n/s))},aS(AH,`TopdownSizeApproximator/2`,988,P5,null,null);var WBt;q(344,1,{871:1},di),Q.Ug=function(e,t){return p7e(this,e,t)},Q.Vg=function(){Q9e(this)},Q.Wg=function(){return this.q},Q.Xg=function(){return this.f?Zg(this.f):null},Q.Yg=function(){return Zg(this.a)},Q.Zg=function(){return this.p},Q.$g=function(){return!1},Q._g=function(){return this.n},Q.ah=function(){return this.p!=null&&!this.b},Q.bh=function(e){var t;this.n&&(t=e,M(this.f,t))},Q.dh=function(e,t){var n,r;this.n&&e&&Xze(this,(n=new GPe,r=WM(n,e),Yht(n),r),(Mw(),I5))},Q.eh=function(e){var t;return this.b?null:(t=XKe(this,this.g),up(this.a,t),t.i=this,this.d=e,t)},Q.fh=function(e){e>0&&!this.b&&kJe(this,e)},Q.b=!1,Q.c=0,Q.d=-1,Q.e=null,Q.f=null,Q.g=-1,Q.j=!1,Q.k=!1,Q.n=!1,Q.o=0,Q.q=0,Q.r=0,L(gV,`BasicProgressMonitor`,344),q(717,205,OL,hse),Q.rf=function(e,t){Xdt(e,t)},L(gV,`BoxLayoutProvider`,717),q(983,1,GI,ehe),Q.Ne=function(e,t){return mot(this,P(e,27),P(t,27))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},Q.a=!1,L(gV,`BoxLayoutProvider/1`,983),q(163,1,{163:1},Fx,qEe),Q.Ib=function(){return this.c?Elt(this.c):CA(this.b)},L(gV,`BoxLayoutProvider/Group`,163),q(320,22,{3:1,34:1,22:1,320:1},Gc);var GBt,KBt,qBt,F5,JBt=aS(gV,`BoxLayoutProvider/PackingMode`,320,eG,NVe,oje),YBt;q(984,1,GI,gse),Q.Ne=function(e,t){return PIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$0$Type`,984),q(985,1,GI,_se),Q.Ne=function(e,t){return SIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$1$Type`,985),q(986,1,GI,vse),Q.Ne=function(e,t){return CIe(P(e,163),P(t,163))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(gV,`BoxLayoutProvider/lambda$2$Type`,986),q(1384,1,{845:1},yse),Q.Mg=function(e,t){return zo(),!j(t,167)||Cye((lw(),P(e,167)),t)},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$0$Type`,1384),q(1385,1,$P,the),Q.Cd=function(e){EQe(this.a,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$1$Type`,1385),q(1386,1,$P,Sse),Q.Cd=function(e){P(e,96),zo()},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$2$Type`,1386),q(1390,1,$P,nhe),Q.Cd=function(e){sYe(this.a,P(e,96))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$3$Type`,1390),q(1388,1,vF,ySe),Q.Mb=function(e){return WZe(this.a,this.b,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$4$Type`,1388),q(1387,1,vF,bSe),Q.Mb=function(e){return wEe(this.a,this.b,P(e,845))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$5$Type`,1387),q(1389,1,$P,xSe),Q.Cd=function(e){nPe(this.a,this.b,P(e,149))},L(gV,`ElkSpacings/AbstractSpacingsBuilder/lambda$6$Type`,1389),q(947,1,{},Cse),Q.Kb=function(e){return LCe(e)},Q.Fb=function(e){return this===e},L(gV,`ElkUtil/lambda$0$Type`,947),q(948,1,$P,SSe),Q.Cd=function(e){Gnt(this.a,this.b,P(e,74))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$1$Type`,948),q(949,1,$P,CSe),Q.Cd=function(e){X_e(this.a,this.b,P(e,166))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$2$Type`,949),q(950,1,$P,wSe),Q.Cd=function(e){rwe(this.a,this.b,P(e,135))},Q.a=0,Q.b=0,L(gV,`ElkUtil/lambda$3$Type`,950),q(951,1,$P,rhe),Q.Cd=function(e){jMe(this.a,P(e,377))},L(gV,`ElkUtil/lambda$4$Type`,951),q(325,1,{34:1,325:1},Er),Q.Fd=function(e){return aTe(this,P(e,242))},Q.Fb=function(e){var t;return j(e,325)?(t=P(e,325),this.a==t.a):!1},Q.Hb=function(){return C_(this.a)},Q.Ib=function(){return this.a+` (exclusive)`},Q.a=0,L(gV,`ExclusiveBounds/ExclusiveLowerBound`,325),q(1119,205,OL,wse),Q.rf=function(e,t){var n,i,a,o,s,c,l,u,f,p,m,h,g,_,v,y,b,x,S,ee,te,ne,C;for(t.Ug(`Fixed Layout`,1),o=P(J(e,(vP(),uzt)),223),p=0,m=0,b=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));b.e!=b.i.gc();){for(v=P(gO(b),27),C=P(J(v,(Iw(),h8)),8),C&&($l(v,C.a,C.b),P(J(v,mBt),181).Hc((TD(),v5))&&(h=P(J(v,gBt),8),h.a>0&&h.b>0&&iP(v,h.a,h.b,!0,!0))),p=r.Math.max(p,v.i+v.g),m=r.Math.max(m,v.j+v.f),u=new Lu((!v.n&&(v.n=new F(Q5,v,1,7)),v.n));u.e!=u.i.gc();)c=P(gO(u),135),C=P(J(c,h8),8),C&&$l(c,C.a,C.b),p=r.Math.max(p,v.i+c.i+c.g),m=r.Math.max(m,v.j+c.j+c.f);for(ee=new Lu((!v.c&&(v.c=new F(e7,v,9,9)),v.c));ee.e!=ee.i.gc();)for(S=P(gO(ee),123),C=P(J(S,h8),8),C&&$l(S,C.a,C.b),te=v.i+S.i,ne=v.j+S.j,p=r.Math.max(p,te+S.g),m=r.Math.max(m,ne+S.f),l=new Lu((!S.n&&(S.n=new F(Q5,S,1,7)),S.n));l.e!=l.i.gc();)c=P(gO(l),135),C=P(J(c,h8),8),C&&$l(c,C.a,C.b),p=r.Math.max(p,te+c.i+c.g),m=r.Math.max(m,ne+c.j+c.f);for(a=new pm(Vu(Ij(v).a.Kc(),new d));Cj(a);)n=P(by(a),74),f=r_t(n),p=r.Math.max(p,f.a),m=r.Math.max(m,f.b);for(i=new pm(Vu(Fj(v).a.Kc(),new d));Cj(i);)n=P(by(i),74),I_(xA(n))!=e&&(f=r_t(n),p=r.Math.max(p,f.a),m=r.Math.max(m,f.b))}if(o==(wE(),l8))for(y=new Lu((!e.a&&(e.a=new F($5,e,10,11)),e.a));y.e!=y.i.gc();)for(v=P(gO(y),27),i=new pm(Vu(Ij(v).a.Kc(),new d));Cj(i);)n=P(by(i),74),s=Sdt(n),s.b==0?OO(n,x6,null):OO(n,x6,s);ki(Od(J(e,(Iw(),hBt))))||(x=P(J(e,_Bt),107),_=p+x.b+x.c,g=m+x.d+x.a,iP(e,_,g,!0,!0)),t.Vg()},L(gV,`FixedLayoutProvider`,1119),q(385,137,{3:1,423:1,385:1,96:1,137:1},en,uKe),Q.cg=function(e){var t,n,r,i,a,o,s,c,l;if(e)try{for(c=nN(e,`;,;`),a=c,o=0,s=a.length;o>16&OF|t^r<<16},Q.Kc=function(){return new ihe(this)},Q.Ib=function(){return this.a==null&&this.b==null?`pair(null,null)`:this.a==null?`pair(null,`+PE(this.b)+`)`:this.b==null?`pair(`+PE(this.a)+`,null)`:`pair(`+PE(this.a)+`,`+PE(this.b)+`)`},L(gV,`Pair`,42),q(995,1,VP,ihe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return!this.c&&(!this.b&&this.a.a!=null||this.a.b!=null)},Q.Pb=function(){if(!this.c&&!this.b&&this.a.a!=null)return this.b=!0,this.a.a;if(!this.c&&this.a.b!=null)return this.c=!0,this.a.b;throw E(new Hr)},Q.Qb=function(){throw this.c&&this.a.b!=null?this.a.b=null:this.b&&this.a.a!=null&&(this.a.a=null),E(new Rr)},Q.b=!1,Q.c=!1,L(gV,`Pair/1`,995),q(455,1,{455:1},cIe),Q.Fb=function(e){return rg(this.a,P(e,455).a)&&rg(this.c,P(e,455).c)&&rg(this.d,P(e,455).d)&&rg(this.b,P(e,455).b)},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.a,this.c,this.d,this.b]))},Q.Ib=function(){return`(`+this.a+PP+this.c+PP+this.d+PP+this.b+`)`},L(gV,`Quadruple`,455),q(1108,205,OL,xse),Q.rf=function(e,t){var n,r,i,a,o;if(t.Ug(`Random Layout`,1),(!e.a&&(e.a=new F($5,e,10,11)),e.a).i==0){t.Vg();return}a=P(J(e,(wD(),PBt)),17),i=a&&a.a!=0?new sy(a.a):new YE,n=Ai(N(J(e,jBt))),o=Ai(N(J(e,FBt))),r=P(J(e,MBt),107),wgt(e,i,n,o,r),t.Vg()},L(gV,`RandomLayoutProvider`,1108),q(240,1,{240:1},Vf),Q.Fb=function(e){return rg(this.a,P(e,240).a)&&rg(this.b,P(e,240).b)&&rg(this.c,P(e,240).c)},Q.Hb=function(){return tT(U(O(WW,1),FP,1,5,[this.a,this.b,this.c]))},Q.Ib=function(){return`(`+this.a+PP+this.b+PP+this.c+`)`},L(gV,`Triple`,240);var nVt;q(562,1,{}),Q.Lf=function(){return new k(this.f.i,this.f.j)},Q.of=function(e){return nLe(e,(vP(),F6))?J(this.f,rVt):J(this.f,e)},Q.Mf=function(){return new k(this.f.g,this.f.f)},Q.Nf=function(){return this.g},Q.pf=function(e){return qy(this.f,e)},Q.Of=function(e){Gx(this.f,e.a),Kx(this.f,e.b)},Q.Pf=function(e){Wx(this.f,e.a),Ux(this.f,e.b)},Q.Qf=function(e){this.g=e},Q.g=0;var rVt;L(RH,`ElkGraphAdapters/AbstractElkGraphElementAdapter`,562),q(563,1,{853:1},_r),Q.Rf=function(){var e,t;if(!this.b)for(this.b=kv(ag(this.a).i),t=new Lu(ag(this.a));t.e!=t.i.gc();)e=P(gO(t),135),M(this.b,new Di(e));return this.b},Q.b=null,L(RH,`ElkGraphAdapters/ElkEdgeAdapter`,563),q(289,562,{},Ei),Q.Sf=function(){return k3e(this)},Q.a=null,L(RH,`ElkGraphAdapters/ElkGraphAdapter`,289),q(640,562,{187:1},Di),L(RH,`ElkGraphAdapters/ElkLabelAdapter`,640),q(639,562,{695:1},sd),Q.Rf=function(){return D3e(this)},Q.Vf=function(){var e;return e=P(J(this.f,(vP(),S6)),140),!e&&(e=new ei),e},Q.Xf=function(){return O3e(this)},Q.Zf=function(e){var t=new Kf(e);OO(this.f,(vP(),S6),t)},Q.$f=function(e){OO(this.f,(vP(),A6),new bje(e))},Q.Tf=function(){return this.d},Q.Uf=function(){var e,t;if(!this.a)for(this.a=new T,t=new pm(Vu(Fj(P(this.f,27)).a.Kc(),new d));Cj(t);)e=P(by(t),74),M(this.a,new _r(e));return this.a},Q.Wf=function(){var e,t;if(!this.c)for(this.c=new T,t=new pm(Vu(Ij(P(this.f,27)).a.Kc(),new d));Cj(t);)e=P(by(t),74),M(this.c,new _r(e));return this.c},Q.Yf=function(){return Gg(P(this.f,27)).i!=0||ki(Od(P(this.f,27).of((vP(),_6))))},Q._f=function(){dKe(this,(Ko(),nVt))},Q.a=null,Q.b=null,Q.c=null,Q.d=null,Q.e=null,L(RH,`ElkGraphAdapters/ElkNodeAdapter`,639),q(1284,562,{852:1},ahe),Q.Rf=function(){return H3e(this)},Q.Uf=function(){var e,t;if(!this.a)for(this.a=dd(P(this.f,123).hh().i),t=new Lu(P(this.f,123).hh());t.e!=t.i.gc();)e=P(gO(t),74),M(this.a,new _r(e));return this.a},Q.Wf=function(){var e,t;if(!this.c)for(this.c=dd(P(this.f,123).ih().i),t=new Lu(P(this.f,123).ih());t.e!=t.i.gc();)e=P(gO(t),74),M(this.c,new _r(e));return this.c},Q.ag=function(){return P(P(this.f,123).of((vP(),B6)),64)},Q.bg=function(){var e,t,n,r=E_(P(this.f,123)),i,a,o,s;for(n=new Lu(P(this.f,123).ih());n.e!=n.i.gc();)for(e=P(gO(n),74),s=new Lu((!e.c&&(e.c=new cf(H5,e,5,8)),e.c));s.e!=s.i.gc();)if(o=P(gO(s),84),Ex(cA(o),r)||cA(o)==r&&ki(Od(J(e,(vP(),v6)))))return!0;for(t=new Lu(P(this.f,123).hh());t.e!=t.i.gc();)for(e=P(gO(t),74),a=new Lu((!e.b&&(e.b=new cf(H5,e,4,7)),e.b));a.e!=a.i.gc();)if(i=P(gO(a),84),Ex(cA(i),r))return!0;return!1},Q.a=null,Q.b=null,Q.c=null,L(RH,`ElkGraphAdapters/ElkPortAdapter`,1284),q(1285,1,GI,bse),Q.Ne=function(e,t){return Tlt(P(e,123),P(t,123))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(RH,`ElkGraphAdapters/PortComparator`,1285);var L5=gp(zH,`EObject`),R5=gp(BH,VSt),z5=gp(BH,HSt),B5=gp(BH,USt),V5=gp(BH,`ElkShape`),H5=gp(BH,WSt),U5=gp(BH,GSt),W5=gp(BH,KSt),G5=gp(zH,qSt),K5=gp(zH,`EFactory`),iVt,q5=gp(zH,JSt),J5=gp(zH,`EPackage`),Y5,aVt,oVt,sVt,X5,cVt,lVt,uVt,dVt,Z5,fVt,pVt,Q5=gp(BH,YSt),$5=gp(BH,XSt),e7=gp(BH,ZSt);q(93,1,QSt),Q.th=function(){return this.uh(),null},Q.uh=function(){return null},Q.vh=function(){return this.uh(),!1},Q.wh=function(){return!1},Q.xh=function(e){AC(this,e)},L(VH,`BasicNotifierImpl`,93),q(99,93,nCt),Q.Yh=function(){return Gl(this)},Q.yh=function(e,t){return e},Q.zh=function(){throw E(new Br)},Q.Ah=function(e){var t;return t=qO(P(_x(this.Dh(),this.Fh()),19)),this.Ph().Th(this,t.n,t.f,e)},Q.Bh=function(e,t){throw E(new Br)},Q.Ch=function(e,t,n){return qM(this,e,t,n)},Q.Dh=function(){var e;return this.zh()&&(e=this.zh().Nk(),e)?e:this.ii()},Q.Eh=function(){return xj(this)},Q.Fh=function(){throw E(new Br)},Q.Gh=function(){var e,t=this.$h().Ok();return!t&&this.zh().Tk(t=(Yo(),e=MLe(aN(this.Dh())),e==null?i9:new ad(this,e))),t},Q.Hh=function(e,t){return e},Q.Ih=function(e){return e.pk()?e.Lj():eD(this.Dh(),e)},Q.Jh=function(){var e=this.zh();return e?e.Qk():null},Q.Kh=function(){return this.zh()?this.zh().Nk():null},Q.Lh=function(e,t,n){return jO(this,e,t,n)},Q.Mh=function(e){return mb(this,e)},Q.Nh=function(e,t){return wy(this,e,t)},Q.Oh=function(){var e=this.zh();return!!e&&e.Rk()},Q.Ph=function(){throw E(new Br)},Q.Qh=function(){return KD(this)},Q.Rh=function(e,t,n,r){return EO(this,e,t,r)},Q.Sh=function(e,t,n){var r;return r=P(_x(this.Dh(),t),69),r.wk().zk(this,this.hi(),t-this.ji(),e,n)},Q.Th=function(e,t,n,r){return m_(this,e,t,r)},Q.Uh=function(e,t,n){var r;return r=P(_x(this.Dh(),t),69),r.wk().Ak(this,this.hi(),t-this.ji(),e,n)},Q.Vh=function(){return!!this.zh()&&!!this.zh().Pk()},Q.Wh=function(e){return mO(this,e)},Q.Xh=function(e){return iRe(this,e)},Q.Zh=function(e){return Iht(this,e)},Q.$h=function(){throw E(new Br)},Q._h=function(){return this.zh()?this.zh().Pk():null},Q.ai=function(){return KD(this)},Q.bi=function(e,t){QA(this,e,t)},Q.ci=function(e){this.$h().Sk(e)},Q.di=function(e){this.$h().Vk(e)},Q.ei=function(e){this.$h().Uk(e)},Q.fi=function(e,t){var n,r,i,a=this.Jh();return a&&e&&(t=AO(a.El(),this,t),a.Il(this)),r=this.Ph(),r&&((IM(this,this.Ph(),this.Fh()).Bb&pI)==0?(t=(n=this.Fh(),n>=0?this.Ah(t):this.Ph().Th(this,-1-n,null,t)),t=this.Ch(null,-1,t)):(i=r.Qh(),i&&(e?!a&&i.Il(this):i.Hl(this)))),this.di(e),t},Q.gi=function(e){var t,n=this.Dh(),r,i,a=eD(n,e),o,s,c;if(t=this.ji(),a>=t)return P(e,69).wk().Dk(this,this.hi(),a-t);if(a<=-1){if(o=HN((UA(),l9),n,e),o){if(Qo(),P(o,69).xk()||(o=mv(Rb(l9,o))),i=(r=this.Ih(o),P(r>=0?this.Lh(r,!0,!0):mj(this,o,!0),160)),c=o.Ik(),c>1||c==-1)return P(P(i,220).Sl(e,!1),79)}else throw E(new Fi(HH+e.xe()+WH))}else if(e.Jk())return r=this.Ih(e),P(r>=0?this.Lh(r,!1,!0):mj(this,e,!1),79);return s=new JSe(this,e),s},Q.hi=function(){return Jb(this)},Q.ii=function(){return(vh(),z7).S},Q.ji=function(){return bh(this.ii())},Q.ki=function(e){BA(this,e)},Q.Ib=function(){return Aj(this)},L(KH,`BasicEObjectImpl`,99);var mVt;q(119,99,{110:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1}),Q.li=function(e){return qb(this)[e]},Q.mi=function(e,t){Sh(qb(this),e,t)},Q.ni=function(e){Sh(qb(this),e,null)},Q.th=function(){return P(NC(this,4),129)},Q.uh=function(){throw E(new Br)},Q.vh=function(){return!!(this.Db&4)},Q.zh=function(){throw E(new Br)},Q.oi=function(e){GD(this,2,e)},Q.Bh=function(e,t){this.Db=t<<16|this.Db&255,this.oi(e)},Q.Dh=function(){return d_(this)},Q.Fh=function(){return this.Db>>16},Q.Gh=function(){var e,t;return Yo(),t=MLe(aN((e=P(NC(this,16),29),e||this.ii()))),t==null?i9:new ad(this,t)},Q.wh=function(){return!(this.Db&1)},Q.Jh=function(){return P(NC(this,128),2034)},Q.Kh=function(){return P(NC(this,16),29)},Q.Oh=function(){return!!(this.Db&32)},Q.Ph=function(){return P(NC(this,2),54)},Q.Vh=function(){return!!(this.Db&64)},Q.$h=function(){throw E(new Br)},Q._h=function(){return P(NC(this,64),288)},Q.ci=function(e){GD(this,16,e)},Q.di=function(e){GD(this,128,e)},Q.ei=function(e){GD(this,64,e)},Q.hi=function(){return WD(this)},Q.Db=0,L(KH,`MinimalEObjectImpl`,119),q(120,119,{110:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.oi=function(e){this.Cb=e},Q.Ph=function(){return this.Cb},L(KH,`MinimalEObjectImpl/Container`,120),q(2083,120,{110:1,342:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return W3e(this,e,t,n)},Q.Uh=function(e,t,n){return x9e(this,e,t,n)},Q.Wh=function(e){return yBe(this,e)},Q.bi=function(e,t){qZe(this,e,t)},Q.ii=function(){return lP(),pVt},Q.ki=function(e){sZe(this,e)},Q.nf=function(){return H2e(this)},Q.gh=function(){return!this.o&&(this.o=new lb((lP(),Z5),n7,this,0)),this.o},Q.of=function(e){return J(this,e)},Q.pf=function(e){return qy(this,e)},Q.qf=function(e,t){return OO(this,e,t)},L(qH,`EMapPropertyHolderImpl`,2083),q(572,120,{110:1,377:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},tn),Q.Lh=function(e,t,n){switch(e){case 0:return this.a;case 1:return this.b}return jO(this,e,t,n)},Q.Wh=function(e){switch(e){case 0:return this.a!=0;case 1:return this.b!=0}return mO(this,e)},Q.bi=function(e,t){switch(e){case 0:Xx(this,D(N(t)));return;case 1:Vx(this,D(N(t)));return}QA(this,e,t)},Q.ii=function(){return lP(),aVt},Q.ki=function(e){switch(e){case 0:Xx(this,0);return;case 1:Vx(this,0);return}BA(this,e)},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new Wu(Aj(this)),e.a+=` (x: `,Ua(e,this.a),e.a+=`, y: `,Ua(e,this.b),e.a+=`)`,e.a)},Q.a=0,Q.b=0,L(qH,`ElkBendPointImpl`,572),q(739,2083,{110:1,342:1,167:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return ZT(this,e,t,n)},Q.Sh=function(e,t,n){return uA(this,e,t,n)},Q.Uh=function(e,t,n){return XC(this,e,t,n)},Q.Wh=function(e){return pXe(this,e)},Q.bi=function(e,t){V8e(this,e,t)},Q.ii=function(){return lP(),cVt},Q.ki=function(e){vT(this,e)},Q.jh=function(){return this.k},Q.kh=function(){return ag(this)},Q.Ib=function(){return pE(this)},Q.k=null,L(qH,`ElkGraphElementImpl`,739),q(740,739,{110:1,342:1,167:1,422:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return FE(this,e,t,n)},Q.Wh=function(e){return JE(this,e)},Q.bi=function(e,t){H8e(this,e,t)},Q.ii=function(){return lP(),fVt},Q.ki=function(e){dD(this,e)},Q.lh=function(){return this.f},Q.mh=function(){return this.g},Q.nh=function(){return this.i},Q.oh=function(){return this.j},Q.ph=function(e,t){Ql(this,e,t)},Q.qh=function(e,t){$l(this,e,t)},Q.rh=function(e){Gx(this,e)},Q.sh=function(e){Kx(this,e)},Q.Ib=function(){return AA(this)},Q.f=0,Q.g=0,Q.i=0,Q.j=0,L(qH,`ElkShapeImpl`,740),q(741,740,{110:1,342:1,84:1,167:1,422:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1}),Q.Lh=function(e,t,n){return tk(this,e,t,n)},Q.Sh=function(e,t,n){return b8e(this,e,t,n)},Q.Uh=function(e,t,n){return x8e(this,e,t,n)},Q.Wh=function(e){return BZe(this,e)},Q.bi=function(e,t){cit(this,e,t)},Q.ii=function(){return lP(),oVt},Q.ki=function(e){DO(this,e)},Q.hh=function(){return!this.d&&(this.d=new cf(U5,this,8,5)),this.d},Q.ih=function(){return!this.e&&(this.e=new cf(U5,this,7,4)),this.e},L(qH,`ElkConnectableShapeImpl`,741),q(326,739,{110:1,342:1,74:1,167:1,326:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},nn),Q.Ah=function(e){return P6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 3:return T_(this);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),this.b;case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),this.c;case 6:return!this.a&&(this.a=new F(W5,this,6,6)),this.a;case 7:return rd(),!this.b&&(this.b=new cf(H5,this,4,7)),!(this.b.i<=1&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i<=1));case 8:return rd(),!!yj(this);case 9:return rd(),!!uj(this);case 10:return rd(),!this.b&&(this.b=new cf(H5,this,4,7)),this.b.i!=0&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i!=0)}return ZT(this,e,t,n)},Q.Sh=function(e,t,n){var r;switch(t){case 3:return this.Cb&&(n=(r=this.Db>>16,r>=0?P6e(this,n):this.Cb.Th(this,-1-r,null,n))),Bd(this,P(e,27),n);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),vD(this.b,e,n);case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),vD(this.c,e,n);case 6:return!this.a&&(this.a=new F(W5,this,6,6)),vD(this.a,e,n)}return uA(this,e,t,n)},Q.Uh=function(e,t,n){switch(t){case 3:return Bd(this,null,n);case 4:return!this.b&&(this.b=new cf(H5,this,4,7)),AO(this.b,e,n);case 5:return!this.c&&(this.c=new cf(H5,this,5,8)),AO(this.c,e,n);case 6:return!this.a&&(this.a=new F(W5,this,6,6)),AO(this.a,e,n)}return XC(this,e,t,n)},Q.Wh=function(e){switch(e){case 3:return!!T_(this);case 4:return!!this.b&&this.b.i!=0;case 5:return!!this.c&&this.c.i!=0;case 6:return!!this.a&&this.a.i!=0;case 7:return!this.b&&(this.b=new cf(H5,this,4,7)),!(this.b.i<=1&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i<=1));case 8:return yj(this);case 9:return uj(this);case 10:return!this.b&&(this.b=new cf(H5,this,4,7)),this.b.i!=0&&(!this.c&&(this.c=new cf(H5,this,5,8)),this.c.i!=0)}return pXe(this,e)},Q.bi=function(e,t){switch(e){case 3:Hj(this,P(t,27));return;case 4:!this.b&&(this.b=new cf(H5,this,4,7)),RN(this.b),!this.b&&(this.b=new cf(H5,this,4,7)),th(this.b,P(t,16));return;case 5:!this.c&&(this.c=new cf(H5,this,5,8)),RN(this.c),!this.c&&(this.c=new cf(H5,this,5,8)),th(this.c,P(t,16));return;case 6:!this.a&&(this.a=new F(W5,this,6,6)),RN(this.a),!this.a&&(this.a=new F(W5,this,6,6)),th(this.a,P(t,16));return}V8e(this,e,t)},Q.ii=function(){return lP(),sVt},Q.ki=function(e){switch(e){case 3:Hj(this,null);return;case 4:!this.b&&(this.b=new cf(H5,this,4,7)),RN(this.b);return;case 5:!this.c&&(this.c=new cf(H5,this,5,8)),RN(this.c);return;case 6:!this.a&&(this.a=new F(W5,this,6,6)),RN(this.a);return}vT(this,e)},Q.Ib=function(){return ipt(this)},L(qH,`ElkEdgeImpl`,326),q(452,2083,{110:1,342:1,166:1,452:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},rn),Q.Ah=function(e){return b6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 1:return this.j;case 2:return this.k;case 3:return this.b;case 4:return this.c;case 5:return!this.a&&(this.a=new ju(z5,this,5)),this.a;case 6:return QLe(this);case 7:return t?KO(this):this.i;case 8:return t?GO(this):this.f;case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),this.g;case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),this.e;case 11:return this.d}return W3e(this,e,t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?b6e(this,n):this.Cb.Th(this,-1-i,null,n))),jDe(this,P(e,74),n);case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),vD(this.g,e,n);case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),vD(this.e,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(lP(),X5)),t),69),a.wk().zk(this,WD(this),t-bh((lP(),X5)),e,n)},Q.Uh=function(e,t,n){switch(t){case 5:return!this.a&&(this.a=new ju(z5,this,5)),AO(this.a,e,n);case 6:return jDe(this,null,n);case 9:return!this.g&&(this.g=new cf(W5,this,9,10)),AO(this.g,e,n);case 10:return!this.e&&(this.e=new cf(W5,this,10,9)),AO(this.e,e,n)}return x9e(this,e,t,n)},Q.Wh=function(e){switch(e){case 1:return this.j!=0;case 2:return this.k!=0;case 3:return this.b!=0;case 4:return this.c!=0;case 5:return!!this.a&&this.a.i!=0;case 6:return!!QLe(this);case 7:return!!this.i;case 8:return!!this.f;case 9:return!!this.g&&this.g.i!=0;case 10:return!!this.e&&this.e.i!=0;case 11:return this.d!=null}return yBe(this,e)},Q.bi=function(e,t){switch(e){case 1:qx(this,D(N(t)));return;case 2:Yx(this,D(N(t)));return;case 3:Hx(this,D(N(t)));return;case 4:Jx(this,D(N(t)));return;case 5:!this.a&&(this.a=new ju(z5,this,5)),RN(this.a),!this.a&&(this.a=new ju(z5,this,5)),th(this.a,P(t,16));return;case 6:Jat(this,P(t,74));return;case 7:ES(this,P(t,84));return;case 8:TS(this,P(t,84));return;case 9:!this.g&&(this.g=new cf(W5,this,9,10)),RN(this.g),!this.g&&(this.g=new cf(W5,this,9,10)),th(this.g,P(t,16));return;case 10:!this.e&&(this.e=new cf(W5,this,10,9)),RN(this.e),!this.e&&(this.e=new cf(W5,this,10,9)),th(this.e,P(t,16));return;case 11:qJe(this,kd(t));return}qZe(this,e,t)},Q.ii=function(){return lP(),X5},Q.ki=function(e){switch(e){case 1:qx(this,0);return;case 2:Yx(this,0);return;case 3:Hx(this,0);return;case 4:Jx(this,0);return;case 5:!this.a&&(this.a=new ju(z5,this,5)),RN(this.a);return;case 6:Jat(this,null);return;case 7:ES(this,null);return;case 8:TS(this,null);return;case 9:!this.g&&(this.g=new cf(W5,this,9,10)),RN(this.g);return;case 10:!this.e&&(this.e=new cf(W5,this,10,9)),RN(this.e);return;case 11:qJe(this,null);return}sZe(this,e)},Q.Ib=function(){return xrt(this)},Q.b=0,Q.c=0,Q.d=null,Q.j=0,Q.k=0,L(qH,`ElkEdgeSectionImpl`,452),q(158,120,{110:1,94:1,93:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1}),Q.Lh=function(e,t,n){var r;return e==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab):xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i;return t==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n)):(i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().zk(this,WD(this),t-bh(this.ii()),e,n))},Q.Uh=function(e,t,n){var r,i;return t==0?(!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n)):(i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n))},Q.Wh=function(e){var t;return e==0?!!this.Ab&&this.Ab.i!=0:Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.Zh=function(e){return rP(this,e)},Q.bi=function(e,t){var n;if(e===0){!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.di=function(e){GD(this,128,e)},Q.ii=function(){return CP(),qVt},Q.ki=function(e){var t;if(e===0){!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){this.Bb|=1},Q.qi=function(e){return JM(this,e)},Q.Bb=0,L(KH,`EModelElementImpl`,158),q(720,158,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1},$ue),Q.ri=function(e,t){return yht(this,e,t)},Q.si=function(e){var t,n,r,i,a;if(this.a!=Mx(e)||e.Bb&256)throw E(new Fi($H+e.zb+XH));for(r=l_(e);Jv(r.a).i!=0;){if(n=P(GN(r,0,(t=P(H(Jv(r.a),0),89),a=t.c,j(a,90)?P(a,29):(CP(),J7))),29),_k(n))return i=Mx(n).wi().si(n),P(i,54).ci(e),i;r=l_(n)}return(e.D==null?e.B:e.D)==`java.util.Map$Entry`?new OMe(e):new eMe(e)},Q.ti=function(e,t){return uP(this,e,t)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.a}return xb(this,e-bh((CP(),G7)),_x((r=P(NC(this,16),29),r||G7),e),t,n)},Q.Sh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 1:return this.a&&(n=P(this.a,54).Th(this,4,J5,n)),mT(this,P(e,241),n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),G7)),t),69),i.wk().zk(this,WD(this),t-bh((CP(),G7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 1:return mT(this,null,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),G7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),G7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return!!this.a}return Hv(this,e-bh((CP(),G7)),_x((t=P(NC(this,16),29),t||G7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:r9e(this,P(t,241));return}LE(this,e-bh((CP(),G7)),_x((n=P(NC(this,16),29),n||G7),e),t)},Q.ii=function(){return CP(),G7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:r9e(this,null);return}PT(this,e-bh((CP(),G7)),_x((t=P(NC(this,16),29),t||G7),e))};var t7,hVt,gVt;L(KH,`EFactoryImpl`,720),q(1037,720,{110:1,2113:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1},kse),Q.ri=function(e,t){switch(e.hk()){case 12:return P(t,149).Pg();case 13:return PE(t);default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a,o,s,c;switch(e.G==-1&&(e.G=(t=Mx(e),t?NO(t.vi(),e):-1)),e.G){case 4:return a=new Ase,a;case 6:return o=new ii,o;case 7:return s=new s_e,s;case 8:return r=new nn,r;case 9:return n=new tn,n;case 10:return i=new rn,i;case 11:return c=new jse,c;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){switch(e.hk()){case 13:case 12:return null;default:throw E(new Fi(YH+e.xe()+XH))}},L(qH,`ElkGraphFactoryImpl`,1037),q(448,158,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1}),Q.Gh=function(){var e,t=(e=P(NC(this,16),29),MLe(aN(e||this.ii())));return t==null?(Yo(),Yo(),i9):new VEe(this,t)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.xe()}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:this.ui(kd(t));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),JVt},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:this.ui(null);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.xe=function(){return this.zb},Q.ui=function(e){GS(this,e)},Q.Ib=function(){return DT(this)},Q.zb=null,L(KH,`ENamedElementImpl`,448),q(184,448,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1},IIe),Q.Ah=function(e){return w6e(this,e)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.yb;case 3:return this.xb;case 4:return this.sb;case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),this.rb;case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),this.vb;case 7:return t?this.Db>>16==7?P(this.Cb,241):null:pRe(this)}return xb(this,e-bh((CP(),X7)),_x((r=P(NC(this,16),29),r||X7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 4:return this.sb&&(n=P(this.sb,54).Th(this,1,K5,n)),OT(this,P(e,480),n);case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),vD(this.rb,e,n);case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),vD(this.vb,e,n);case 7:return this.Cb&&(n=(i=this.Db>>16,i>=0?w6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,7,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),X7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),X7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 4:return OT(this,null,n);case 5:return!this.rb&&(this.rb=new Tm(this,E7,this)),AO(this.rb,e,n);case 6:return!this.vb&&(this.vb=new nf(J5,this,6,7)),AO(this.vb,e,n);case 7:return qM(this,null,7,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),X7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),X7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.yb!=null;case 3:return this.xb!=null;case 4:return!!this.sb;case 5:return!!this.rb&&this.rb.i!=0;case 6:return!!this.vb&&this.vb.i!=0;case 7:return!!pRe(this)}return Hv(this,e-bh((CP(),X7)),_x((t=P(NC(this,16),29),t||X7),e))},Q.Zh=function(e){return Mot(this,e)||rP(this,e)},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:qS(this,kd(t));return;case 3:KS(this,kd(t));return;case 4:EA(this,P(t,480));return;case 5:!this.rb&&(this.rb=new Tm(this,E7,this)),RN(this.rb),!this.rb&&(this.rb=new Tm(this,E7,this)),th(this.rb,P(t,16));return;case 6:!this.vb&&(this.vb=new nf(J5,this,6,7)),RN(this.vb),!this.vb&&(this.vb=new nf(J5,this,6,7)),th(this.vb,P(t,16));return}LE(this,e-bh((CP(),X7)),_x((n=P(NC(this,16),29),n||X7),e),t)},Q.ei=function(e){var t,n;if(e&&this.rb)for(n=new Lu(this.rb);n.e!=n.i.gc();)t=gO(n),j(t,364)&&(P(t,364).w=null);GD(this,64,e)},Q.ii=function(){return CP(),X7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:qS(this,null);return;case 3:KS(this,null);return;case 4:EA(this,null);return;case 5:!this.rb&&(this.rb=new Tm(this,E7,this)),RN(this.rb);return;case 6:!this.vb&&(this.vb=new nf(J5,this,6,7)),RN(this.vb);return}PT(this,e-bh((CP(),X7)),_x((t=P(NC(this,16),29),t||X7),e))},Q.pi=function(){Ck(this)},Q.vi=function(){return!this.rb&&(this.rb=new Tm(this,E7,this)),this.rb},Q.wi=function(){return this.sb},Q.xi=function(){return this.ub},Q.yi=function(){return this.xb},Q.zi=function(){return this.yb},Q.Ai=function(e){this.ub=e},Q.Ib=function(){var e;return this.Db&64?DT(this):(e=new Wu(DT(this)),e.a+=` (nsURI: `,pl(e,this.yb),e.a+=`, nsPrefix: `,pl(e,this.xb),e.a+=`)`,e.a)},Q.xb=null,Q.yb=null;var _Vt;L(KH,`EPackageImpl`,184),q(569,184,{110:1,2115:1,569:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1},Urt),Q.q=!1,Q.r=!1;var vVt=!1;L(qH,`ElkGraphPackageImpl`,569),q(366,740,{110:1,342:1,167:1,135:1,422:1,366:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},Ase),Q.Ah=function(e){return x6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 7:return mRe(this);case 8:return this.a}return FE(this,e,t,n)},Q.Sh=function(e,t,n){var r;return t===7?(this.Cb&&(n=(r=this.Db>>16,r>=0?x6e(this,n):this.Cb.Th(this,-1-r,null,n))),jNe(this,P(e,167),n)):uA(this,e,t,n)},Q.Uh=function(e,t,n){return t==7?jNe(this,null,n):XC(this,e,t,n)},Q.Wh=function(e){switch(e){case 7:return!!mRe(this);case 8:return!ff(``,this.a)}return JE(this,e)},Q.bi=function(e,t){switch(e){case 7:kot(this,P(t,167));return;case 8:jJe(this,kd(t));return}H8e(this,e,t)},Q.ii=function(){return lP(),lVt},Q.ki=function(e){switch(e){case 7:kot(this,null);return;case 8:jJe(this,``);return}dD(this,e)},Q.Ib=function(){return get(this)},Q.a=``,L(qH,`ElkLabelImpl`,366),q(207,741,{110:1,342:1,84:1,167:1,27:1,422:1,207:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},ii),Q.Ah=function(e){return F6e(this,e)},Q.Lh=function(e,t,n){switch(e){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),this.c;case 10:return!this.a&&(this.a=new F($5,this,10,11)),this.a;case 11:return I_(this);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),this.b;case 13:return rd(),!this.a&&(this.a=new F($5,this,10,11)),this.a.i>0}return tk(this,e,t,n)},Q.Sh=function(e,t,n){var r;switch(t){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),vD(this.c,e,n);case 10:return!this.a&&(this.a=new F($5,this,10,11)),vD(this.a,e,n);case 11:return this.Cb&&(n=(r=this.Db>>16,r>=0?F6e(this,n):this.Cb.Th(this,-1-r,null,n))),tf(this,P(e,27),n);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),vD(this.b,e,n)}return b8e(this,e,t,n)},Q.Uh=function(e,t,n){switch(t){case 9:return!this.c&&(this.c=new F(e7,this,9,9)),AO(this.c,e,n);case 10:return!this.a&&(this.a=new F($5,this,10,11)),AO(this.a,e,n);case 11:return tf(this,null,n);case 12:return!this.b&&(this.b=new F(U5,this,12,3)),AO(this.b,e,n)}return x8e(this,e,t,n)},Q.Wh=function(e){switch(e){case 9:return!!this.c&&this.c.i!=0;case 10:return!!this.a&&this.a.i!=0;case 11:return!!I_(this);case 12:return!!this.b&&this.b.i!=0;case 13:return!this.a&&(this.a=new F($5,this,10,11)),this.a.i>0}return BZe(this,e)},Q.bi=function(e,t){switch(e){case 9:!this.c&&(this.c=new F(e7,this,9,9)),RN(this.c),!this.c&&(this.c=new F(e7,this,9,9)),th(this.c,P(t,16));return;case 10:!this.a&&(this.a=new F($5,this,10,11)),RN(this.a),!this.a&&(this.a=new F($5,this,10,11)),th(this.a,P(t,16));return;case 11:Gj(this,P(t,27));return;case 12:!this.b&&(this.b=new F(U5,this,12,3)),RN(this.b),!this.b&&(this.b=new F(U5,this,12,3)),th(this.b,P(t,16));return}cit(this,e,t)},Q.ii=function(){return lP(),uVt},Q.ki=function(e){switch(e){case 9:!this.c&&(this.c=new F(e7,this,9,9)),RN(this.c);return;case 10:!this.a&&(this.a=new F($5,this,10,11)),RN(this.a);return;case 11:Gj(this,null);return;case 12:!this.b&&(this.b=new F(U5,this,12,3)),RN(this.b);return}DO(this,e)},Q.Ib=function(){return Elt(this)},L(qH,`ElkNodeImpl`,207),q(193,741,{110:1,342:1,84:1,167:1,123:1,422:1,193:1,96:1,94:1,93:1,58:1,114:1,54:1,99:1,119:1,120:1},s_e),Q.Ah=function(e){return S6e(this,e)},Q.Lh=function(e,t,n){return e==9?E_(this):tk(this,e,t,n)},Q.Sh=function(e,t,n){var r;return t===9?(this.Cb&&(n=(r=this.Db>>16,r>=0?S6e(this,n):this.Cb.Th(this,-1-r,null,n))),Vd(this,P(e,27),n)):b8e(this,e,t,n)},Q.Uh=function(e,t,n){return t==9?Vd(this,null,n):x8e(this,e,t,n)},Q.Wh=function(e){return e==9?!!E_(this):BZe(this,e)},Q.bi=function(e,t){if(e===9){Yat(this,P(t,27));return}cit(this,e,t)},Q.ii=function(){return lP(),dVt},Q.ki=function(e){if(e===9){Yat(this,null);return}DO(this,e)},Q.Ib=function(){return Dlt(this)},L(qH,`ElkPortImpl`,193);var yVt=gp(uU,`BasicEMap/Entry`);q(1122,120,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1,119:1,120:1},jse),Q.Fb=function(e){return this===e},Q.ld=function(){return this.b},Q.Hb=function(){return td(this)},Q.Di=function(e){MJe(this,P(e,149))},Q.Lh=function(e,t,n){switch(e){case 0:return this.b;case 1:return this.c}return jO(this,e,t,n)},Q.Wh=function(e){switch(e){case 0:return!!this.b;case 1:return this.c!=null}return mO(this,e)},Q.bi=function(e,t){switch(e){case 0:MJe(this,P(t,149));return;case 1:AJe(this,t);return}QA(this,e,t)},Q.ii=function(){return lP(),Z5},Q.ki=function(e){switch(e){case 0:MJe(this,null);return;case 1:AJe(this,null);return}BA(this,e)},Q.Bi=function(){var e;return this.a==-1&&(e=this.b,this.a=e?US(e):0),this.a},Q.md=function(){return this.c},Q.Ci=function(e){this.a=e},Q.nd=function(e){var t=this.c;return AJe(this,e),t},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new ta,gl(gl(gl(e,this.b?this.b.Pg():IP),kR),Uu(this.c)),e.a)},Q.a=-1,Q.c=null;var n7=L(qH,`ElkPropertyToValueMapEntryImpl`,1122);q(996,1,{},Pse),L(fU,`JsonAdapter`,996),q(216,63,SF,Vi),L(fU,`JsonImportException`,216),q(868,1,{},E6e),L(fU,`JsonImporter`,868),q(903,1,{},TSe),L(fU,`JsonImporter/lambda$0$Type`,903),q(904,1,{},ESe),L(fU,`JsonImporter/lambda$1$Type`,904),q(912,1,{},ohe),L(fU,`JsonImporter/lambda$10$Type`,912),q(914,1,{},DSe),L(fU,`JsonImporter/lambda$11$Type`,914),q(915,1,{},OSe),L(fU,`JsonImporter/lambda$12$Type`,915),q(921,1,{},pIe),L(fU,`JsonImporter/lambda$13$Type`,921),q(920,1,{},mIe),L(fU,`JsonImporter/lambda$14$Type`,920),q(916,1,{},kSe),L(fU,`JsonImporter/lambda$15$Type`,916),q(917,1,{},ASe),L(fU,`JsonImporter/lambda$16$Type`,917),q(918,1,{},jSe),L(fU,`JsonImporter/lambda$17$Type`,918),q(919,1,{},MSe),L(fU,`JsonImporter/lambda$18$Type`,919),q(924,1,{},she),L(fU,`JsonImporter/lambda$19$Type`,924),q(905,1,{},che),L(fU,`JsonImporter/lambda$2$Type`,905),q(922,1,{},lhe),L(fU,`JsonImporter/lambda$20$Type`,922),q(923,1,{},uhe),L(fU,`JsonImporter/lambda$21$Type`,923),q(927,1,{},dhe),L(fU,`JsonImporter/lambda$22$Type`,927),q(925,1,{},fhe),L(fU,`JsonImporter/lambda$23$Type`,925),q(926,1,{},phe),L(fU,`JsonImporter/lambda$24$Type`,926),q(929,1,{},mhe),L(fU,`JsonImporter/lambda$25$Type`,929),q(928,1,{},hhe),L(fU,`JsonImporter/lambda$26$Type`,928),q(930,1,$P,NSe),Q.Cd=function(e){mGe(this.b,this.a,kd(e))},L(fU,`JsonImporter/lambda$27$Type`,930),q(931,1,$P,PSe),Q.Cd=function(e){hGe(this.b,this.a,kd(e))},L(fU,`JsonImporter/lambda$28$Type`,931),q(932,1,{},FSe),L(fU,`JsonImporter/lambda$29$Type`,932),q(908,1,{},ghe),L(fU,`JsonImporter/lambda$3$Type`,908),q(933,1,{},ISe),L(fU,`JsonImporter/lambda$30$Type`,933),q(934,1,{},_he),L(fU,`JsonImporter/lambda$31$Type`,934),q(935,1,{},vhe),L(fU,`JsonImporter/lambda$32$Type`,935),q(936,1,{},yhe),L(fU,`JsonImporter/lambda$33$Type`,936),q(937,1,{},bhe),L(fU,`JsonImporter/lambda$34$Type`,937),q(870,1,{},xhe),L(fU,`JsonImporter/lambda$35$Type`,870),q(941,1,{},uje),L(fU,`JsonImporter/lambda$36$Type`,941),q(938,1,$P,She),Q.Cd=function(e){XHe(this.a,P(e,377))},L(fU,`JsonImporter/lambda$37$Type`,938),q(939,1,$P,LSe),Q.Cd=function(e){WSe(this.a,this.b,P(e,166))},L(fU,`JsonImporter/lambda$38$Type`,939),q(940,1,$P,RSe),Q.Cd=function(e){GSe(this.a,this.b,P(e,166))},L(fU,`JsonImporter/lambda$39$Type`,940),q(906,1,{},Che),L(fU,`JsonImporter/lambda$4$Type`,906),q(942,1,$P,whe),Q.Cd=function(e){ZHe(this.a,P(e,8))},L(fU,`JsonImporter/lambda$40$Type`,942),q(907,1,{},The),L(fU,`JsonImporter/lambda$5$Type`,907),q(911,1,{},Ehe),L(fU,`JsonImporter/lambda$6$Type`,911),q(909,1,{},Dhe),L(fU,`JsonImporter/lambda$7$Type`,909),q(910,1,{},Ohe),L(fU,`JsonImporter/lambda$8$Type`,910),q(913,1,{},khe),L(fU,`JsonImporter/lambda$9$Type`,913),q(961,1,$P,Ahe),Q.Cd=function(e){Dh(this.a,new mh(kd(e)))},L(fU,`JsonMetaDataConverter/lambda$0$Type`,961),q(962,1,$P,jhe),Q.Cd=function(e){VPe(this.a,P(e,245))},L(fU,`JsonMetaDataConverter/lambda$1$Type`,962),q(963,1,$P,Mhe),Q.Cd=function(e){FRe(this.a,P(e,143))},L(fU,`JsonMetaDataConverter/lambda$2$Type`,963),q(964,1,$P,Nhe),Q.Cd=function(e){HPe(this.a,P(e,170))},L(fU,`JsonMetaDataConverter/lambda$3$Type`,964),q(245,22,{3:1,34:1,22:1,245:1},Jc);var r7,i7,a7,o7,s7,c7,l7,u7,d7=aS(EL,`GraphFeature`,245,eG,nqe,Sje),bVt;q(11,1,{34:1,149:1},yr,Wd,Tl,ou),Q.Fd=function(e){return oTe(this,P(e,149))},Q.Fb=function(e){return nLe(this,e)},Q.Sg=function(){return hO(this)},Q.Pg=function(){return this.b},Q.Hb=function(){return jw(this.b)},Q.Ib=function(){return this.b},L(EL,`Property`,11),q(671,1,GI,vr),Q.Ne=function(e,t){return h1e(this,P(e,96),P(t,96))},Q.Fb=function(e){return this===e},Q.Oe=function(){return new Yn(this)},L(EL,`PropertyHolderComparator`,671),q(709,1,VP,Phe),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return vGe(this)},Q.Qb=function(){uye()},Q.Ob=function(){return!!this.a},L(_U,`ElkGraphUtil/AncestorIterator`,709);var xVt=gp(uU,`EList`);q(70,56,{20:1,31:1,56:1,16:1,15:1,70:1,61:1}),Q.bd=function(e,t){WT(this,e,t)},Q.Fc=function(e){return tb(this,e)},Q.cd=function(e,t){return lZe(this,e,t)},Q.Gc=function(e){return th(this,e)},Q.Ii=function(){return new ld(this)},Q.Ji=function(){return new ud(this)},Q.Ki=function(e){return mS(this,e)},Q.Li=function(){return!0},Q.Mi=function(e,t){},Q.Ni=function(){},Q.Oi=function(e,t){Xy(this,e,t)},Q.Pi=function(e,t,n){},Q.Qi=function(e,t){},Q.Ri=function(e,t,n){},Q.Fb=function(e){return Mct(this,e)},Q.Hb=function(){return qXe(this)},Q.Si=function(){return!1},Q.Kc=function(){return new Lu(this)},Q.ed=function(){return new cd(this)},Q.fd=function(e){var t=this.gc();if(e<0||e>t)throw E(new lf(e,t));return new Hm(this,e)},Q.Ui=function(e,t){this.Ti(e,this.dd(t))},Q.Mc=function(e){return nx(this,e)},Q.Wi=function(e,t){return t},Q.hd=function(e,t){return PO(this,e,t)},Q.Ib=function(){return HE(this)},Q.Yi=function(){return!0},Q.Zi=function(e,t){return Aw(this,t)},L(uU,`AbstractEList`,70),q(66,70,SU,an,kx,hC),Q.Ei=function(e,t){return dA(this,e,t)},Q.Fi=function(e){return X4e(this,e)},Q.Gi=function(e,t){jT(this,e,t)},Q.Hi=function(e){Ty(this,e)},Q.$i=function(e){return SGe(this,e)},Q.$b=function(){Ey(this)},Q.Hc=function(e){return Uk(this,e)},Q.Xb=function(e){return H(this,e)},Q._i=function(e){var t,n,r;++this.j,n=this.g==null?0:this.g.length,e>n&&(r=this.g,t=n+(n/2|0)+4,t=0&&(this.gd(t),!0)},Q.Xi=function(e,t){return this.Dj(e,this.Zi(e,t))},Q.gc=function(){return this.Ej()},Q.Pc=function(){return this.Fj()},Q.Qc=function(e){return this.Gj(e)},Q.Ib=function(){return this.Hj()},L(uU,`DelegatingEList`,2093),q(2094,2093,rwt),Q.Ei=function(e,t){return wdt(this,e,t)},Q.Fi=function(e){return this.Ei(this.Ej(),e)},Q.Gi=function(e,t){Wrt(this,e,t)},Q.Hi=function(e){_rt(this,e)},Q.Li=function(){return!this.Mj()},Q.$b=function(){zN(this)},Q.Ij=function(e,t,n,r,i){return new eLe(this,e,t,n,r,i)},Q.Jj=function(e){AC(this.jj(),e)},Q.Kj=function(){return null},Q.Lj=function(){return-1},Q.jj=function(){return null},Q.Mj=function(){return!1},Q.Nj=function(e,t){return t},Q.Oj=function(e,t){return t},Q.Pj=function(){return!1},Q.Qj=function(){return!this.Aj()},Q.Ti=function(e,t){var n,r;return this.Pj()?(r=this.Qj(),n=e9e(this,e,t),this.Jj(this.Ij(7,G(t),n,e,r)),n):e9e(this,e,t)},Q.gd=function(e){var t,n,r,i;return this.Pj()?(n=null,r=this.Qj(),t=this.Ij(4,i=_p(this,e),null,e,r),this.Mj()&&i&&(n=this.Oj(i,n)),n?(n.nj(t),n.oj()):this.Jj(t),i):(i=_p(this,e),this.Mj()&&i&&(n=this.Oj(i,null),n&&n.oj()),i)},Q.Xi=function(e,t){return Tdt(this,e,t)},L(VH,`DelegatingNotifyingListImpl`,2094),q(152,1,NU),Q.nj=function(e){return T5e(this,e)},Q.oj=function(){Pb(this)},Q.gj=function(){return this.d},Q.Kj=function(){return null},Q.Rj=function(){return null},Q.hj=function(e){return-1},Q.ij=function(){return Ast(this)},Q.jj=function(){return null},Q.kj=function(){return jst(this)},Q.lj=function(){return this.o<0?this.o<-2?-2-this.o-1:-1:this.o},Q.Sj=function(){return!1},Q.mj=function(e){var t,n,r,i,a,o,s,c,l,u,d;switch(this.d){case 1:case 2:switch(i=e.gj(),i){case 1:case 2:if(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null))return this.g=e.ij(),e.gj()==1&&(this.d=1),!0}case 4:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null)))return l=Fmt(this),c=this.o<0?this.o<-2?-2-this.o-1:-1:this.o,o=e.lj(),this.d=6,d=new kx(2),c<=o?(tb(d,this.n),tb(d,e.kj()),this.g=U(O(q9,1),HF,28,15,[this.o=c,o+1])):(tb(d,e.kj()),tb(d,this.n),this.g=U(O(q9,1),HF,28,15,[this.o=o,c])),this.n=d,l||(this.o=-2-this.o-1),!0;break;case 6:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.jj())&&this.hj(null)==e.hj(null))){for(l=Fmt(this),o=e.lj(),u=P(this.g,53),r=V(q9,HF,28,u.length+1,15,1),t=0;t>>0,t.toString(16)));switch(r.a+=` (eventType: `,this.d){case 1:r.a+=`SET`;break;case 2:r.a+=`UNSET`;break;case 3:r.a+=`ADD`;break;case 5:r.a+=`ADD_MANY`;break;case 4:r.a+=`REMOVE`;break;case 6:r.a+=`REMOVE_MANY`;break;case 7:r.a+=`MOVE`;break;case 8:r.a+=`REMOVING_ADAPTER`;break;case 9:r.a+=`RESOLVE`;break;default:Wa(r,this.d)}if(Ult(this)&&(r.a+=`, touch: true`),r.a+=`, position: `,Wa(r,this.o<0?this.o<-2?-2-this.o-1:-1:this.o),r.a+=`, notifier: `,fl(r,this.jj()),r.a+=`, feature: `,fl(r,this.Kj()),r.a+=`, oldValue: `,fl(r,jst(this)),r.a+=`, newValue: `,this.d==6&&j(this.g,53)){for(n=P(this.g,53),r.a+=`[`,e=0;e10?((!this.b||this.c.j!=this.a)&&(this.b=new jp(this),this.a=this.j),mo(this.b,e)):Uk(this,e)},Q.Yi=function(){return!0},Q.a=0,L(uU,`AbstractEList/1`,966),q(302,77,oI,lf),L(uU,`AbstractEList/BasicIndexOutOfBoundsException`,302),q(37,1,VP,Lu),Q.Nb=function(e){Om(this,e)},Q.Xj=function(){if(this.i.j!=this.f)throw E(new Vr)},Q.Yj=function(){return gO(this)},Q.Ob=function(){return this.e!=this.i.gc()},Q.Pb=function(){return this.Yj()},Q.Qb=function(){Yk(this)},Q.e=0,Q.f=0,Q.g=-1,L(uU,`AbstractEList/EIterator`,37),q(286,37,YP,cd,Hm),Q.Qb=function(){Yk(this)},Q.Rb=function(e){y0e(this,e)},Q.Zj=function(){var e;try{return e=this.d.Xb(--this.e),this.Xj(),this.g=this.e,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.$j=function(e){i3e(this,e)},Q.Sb=function(){return this.e!=0},Q.Tb=function(){return this.e},Q.Ub=function(){return this.Zj()},Q.Vb=function(){return this.e-1},Q.Wb=function(e){this.$j(e)},L(uU,`AbstractEList/EListIterator`,286),q(355,37,VP,ld),Q.Yj=function(){return _O(this)},Q.Qb=function(){throw E(new Br)},L(uU,`AbstractEList/NonResolvingEIterator`,355),q(398,286,YP,ud,LOe),Q.Rb=function(e){throw E(new Br)},Q.Yj=function(){var e;try{return e=this.c.Vi(this.e),this.Xj(),this.g=this.e++,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.Zj=function(){var e;try{return e=this.c.Vi(--this.e),this.Xj(),this.g=this.e,e}catch(e){throw e=ew(e),j(e,77)?(this.Xj(),E(new Hr)):E(e)}},Q.Qb=function(){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(uU,`AbstractEList/NonResolvingEListIterator`,398),q(2080,70,iwt),Q.Ei=function(e,t){var n,r,i=t.gc(),a,o,s,c,l,u,d,f;if(i!=0){for(l=P(NC(this.a,4),129),u=l==null?0:l.length,f=u+i,r=Hw(this,f),d=u-e,d>0&&tN(l,e,r,e+i,d),c=t.Kc(),o=0;on)throw E(new lf(e,n));return new JFe(this,e)},Q.$b=function(){var e,t;++this.j,e=P(NC(this.a,4),129),t=e==null?0:e.length,iO(this,null),Xy(this,t,e)},Q.Hc=function(e){var t=P(NC(this.a,4),129),n,r,i,a;if(t!=null){if(e!=null){for(r=t,i=0,a=r.length;i=n)throw E(new lf(e,n));return t[e]},Q.dd=function(e){var t=P(NC(this.a,4),129),n,r;if(t!=null){if(e!=null){for(n=0,r=t.length;nn)throw E(new lf(e,n));return new qFe(this,e)},Q.Ti=function(e,t){var n=B0e(this),r,i=n==null?0:n.length;if(e>=i)throw E(new Mi(yU+e+bU+i));if(t>=i)throw E(new Mi(xU+t+bU+i));return r=n[t],e!=t&&(e0&&tN(e,0,t,0,n),t},Q.Qc=function(e){var t=P(NC(this.a,4),129),n,r=t==null?0:t.length;return r>0&&(e.lengthr&&Sh(e,r,null),e};var TVt;L(uU,`ArrayDelegatingEList`,2080),q(1051,37,VP,gUe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},Q.Qb=function(){Yk(this),this.a=P(NC(this.b.a,4),129)},L(uU,`ArrayDelegatingEList/EIterator`,1051),q(722,286,YP,lPe,qFe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},Q.$j=function(e){i3e(this,e),this.a=P(NC(this.b.a,4),129)},Q.Qb=function(){Yk(this),this.a=P(NC(this.b.a,4),129)},L(uU,`ArrayDelegatingEList/EListIterator`,722),q(1052,355,VP,_Ue),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},L(uU,`ArrayDelegatingEList/NonResolvingEIterator`,1052),q(723,398,YP,uPe,JFe),Q.Xj=function(){if(this.b.j!=this.f||A(P(NC(this.b.a,4),129))!==A(this.a))throw E(new Vr)},L(uU,`ArrayDelegatingEList/NonResolvingEListIterator`,723),q(615,302,oI,wl),L(uU,`BasicEList/BasicIndexOutOfBoundsException`,615),q(710,66,SU,$c),Q.bd=function(e,t){throw E(new Br)},Q.Fc=function(e){throw E(new Br)},Q.cd=function(e,t){throw E(new Br)},Q.Gc=function(e){throw E(new Br)},Q.$b=function(){throw E(new Br)},Q._i=function(e){throw E(new Br)},Q.Kc=function(){return this.Ii()},Q.ed=function(){return this.Ji()},Q.fd=function(e){return this.Ki(e)},Q.Ti=function(e,t){throw E(new Br)},Q.Ui=function(e,t){throw E(new Br)},Q.gd=function(e){throw E(new Br)},Q.Mc=function(e){throw E(new Br)},Q.hd=function(e,t){throw E(new Br)},L(uU,`BasicEList/UnmodifiableEList`,710),q(721,1,{3:1,20:1,16:1,15:1,61:1,597:1}),Q.bd=function(e,t){qwe(this,e,P(t,44))},Q.Fc=function(e){return GEe(this,P(e,44))},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return P(H(this.c,e),136)},Q.Ti=function(e,t){return P(this.c.Ti(e,t),44)},Q.Ui=function(e,t){Jwe(this,e,P(t,44))},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return P(this.c.gd(e),44)},Q.hd=function(e,t){return BPe(this,e,P(t,44))},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.cd=function(e,t){return this.c.cd(e,t)},Q.Gc=function(e){return this.c.Gc(e)},Q.$b=function(){this.c.$b()},Q.Hc=function(e){return this.c.Hc(e)},Q.Ic=function(e){return $C(this.c,e)},Q._j=function(){var e,t,n;if(this.d==null){for(this.d=V(SVt,awt,66,2*this.f+1,0,1),n=this.e,this.f=0,t=this.c.Kc();t.e!=t.i.gc();)e=P(t.Yj(),136),JO(this,e);this.e=n}},Q.Fb=function(e){return GOe(this,e)},Q.Hb=function(){return qXe(this.c)},Q.dd=function(e){return this.c.dd(e)},Q.ak=function(){this.c=new Fhe(this)},Q.dc=function(){return this.f==0},Q.Kc=function(){return this.c.Kc()},Q.ed=function(){return this.c.ed()},Q.fd=function(e){return this.c.fd(e)},Q.bk=function(){return Jy(this)},Q.ck=function(e,t,n){return new dje(e,t,n)},Q.dk=function(){return new Rse},Q.Mc=function(e){return aJe(this,e)},Q.gc=function(){return this.f},Q.kd=function(e,t){return new $_(this.c,e,t)},Q.Pc=function(){return this.c.Pc()},Q.Qc=function(e){return this.c.Qc(e)},Q.Ib=function(){return HE(this.c)},Q.e=0,Q.f=0,L(uU,`BasicEMap`,721),q(1046,66,SU,Fhe),Q.Mi=function(e,t){Oge(this,P(t,136))},Q.Pi=function(e,t,n){var r;++(r=this,P(t,136),r).a.e},Q.Qi=function(e,t){kge(this,P(t,136))},Q.Ri=function(e,t,n){hEe(this,P(t,136),P(n,136))},Q.Oi=function(e,t){sXe(this.a)},L(uU,`BasicEMap/1`,1046),q(1047,66,SU,Rse),Q.aj=function(e){return V(EVt,owt,621,e,0,1)},L(uU,`BasicEMap/2`,1047),q(1048,GP,KP,Ihe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){return uD(this.a,e)},Q.Kc=function(){return this.a.f==0?(Nd(),_7.a):new qve(this.a)},Q.Mc=function(e){var t=this.a.f;return BD(this.a,e),this.a.f!=t},Q.gc=function(){return this.a.f},L(uU,`BasicEMap/3`,1048),q(1049,31,WP,Lhe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){return Nct(this.a,e)},Q.Kc=function(){return this.a.f==0?(Nd(),_7.a):new Jve(this.a)},Q.gc=function(){return this.a.f},L(uU,`BasicEMap/4`,1049),q(1050,GP,KP,Rhe),Q.$b=function(){this.a.c.$b()},Q.Hc=function(e){var t,n,r,i,a,o,s,c,l;if(this.a.f>0&&j(e,44)&&(this.a._j(),c=P(e,44),s=c.ld(),i=s==null?0:US(s),a=MDe(this.a,i),t=this.a.d[a],t)){for(n=P(t.g,379),l=t.i,o=0;o`+this.c},Q.a=0;var EVt=L(uU,`BasicEMap/EntryImpl`,621);q(546,1,{},on),L(uU,`BasicEMap/View`,546);var _7;q(783,1,{}),Q.Fb=function(e){return lit((Vg(),QG),e)},Q.Hb=function(){return IZe((Vg(),QG))},Q.Ib=function(){return CA((Vg(),QG))},L(uU,`ECollections/BasicEmptyUnmodifiableEList`,783),q(1348,1,YP,zse),Q.Nb=function(e){Om(this,e)},Q.Rb=function(e){throw E(new Br)},Q.Ob=function(){return!1},Q.Sb=function(){return!1},Q.Pb=function(){throw E(new Hr)},Q.Tb=function(){return 0},Q.Ub=function(){throw E(new Hr)},Q.Vb=function(){return-1},Q.Qb=function(){throw E(new Br)},Q.Wb=function(e){throw E(new Br)},L(uU,`ECollections/BasicEmptyUnmodifiableEList/1`,1348),q(1346,783,{20:1,16:1,15:1,61:1},c_e),Q.bd=function(e,t){Eye()},Q.Fc=function(e){return Dye()},Q.cd=function(e,t){return Oye()},Q.Gc=function(e){return kye()},Q.$b=function(){Aye()},Q.Hc=function(e){return!1},Q.Ic=function(e){return!1},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return xl((Vg(),e)),null},Q.dd=function(e){return-1},Q.dc=function(){return!0},Q.Kc=function(){return this.a},Q.ed=function(){return this.a},Q.fd=function(e){return this.a},Q.Ti=function(e,t){return jye()},Q.Ui=function(e,t){Mye()},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return Nye()},Q.Mc=function(e){return Pye()},Q.hd=function(e,t){return Fye()},Q.gc=function(){return 0},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.kd=function(e,t){return Vg(),new $_(QG,e,t)},Q.Pc=function(){return INe((Vg(),QG))},Q.Qc=function(e){return Vg(),ck(QG,e)},L(uU,`ECollections/EmptyUnmodifiableEList`,1346),q(1347,783,{20:1,16:1,15:1,61:1,597:1},l_e),Q.bd=function(e,t){Eye()},Q.Fc=function(e){return Dye()},Q.cd=function(e,t){return Oye()},Q.Gc=function(e){return kye()},Q.$b=function(){Aye()},Q.Hc=function(e){return!1},Q.Ic=function(e){return!1},Q.Jc=function(e){ly(this,e)},Q.Xb=function(e){return xl((Vg(),e)),null},Q.dd=function(e){return-1},Q.dc=function(){return!0},Q.Kc=function(){return this.a},Q.ed=function(){return this.a},Q.fd=function(e){return this.a},Q.Ti=function(e,t){return jye()},Q.Ui=function(e,t){Mye()},Q.Lc=function(){return new Mp(null,new cv(this,16))},Q.gd=function(e){return Nye()},Q.Mc=function(e){return Pye()},Q.hd=function(e,t){return Fye()},Q.gc=function(){return 0},Q.jd=function(e){zS(this,e)},Q.Nc=function(){return new cv(this,16)},Q.Oc=function(){return new Mp(null,new cv(this,16))},Q.kd=function(e,t){return Vg(),new $_(QG,e,t)},Q.Pc=function(){return INe((Vg(),QG))},Q.Qc=function(e){return Vg(),ck(QG,e)},Q.bk=function(){return Vg(),Vg(),$G},L(uU,`ECollections/EmptyUnmodifiableEMap`,1347);var DVt=gp(uU,`Enumerator`),v7;q(288,1,{288:1},yM),Q.Fb=function(e){var t;return this===e?!0:j(e,288)?(t=P(e,288),this.f==t.f&&rNe(this.i,t.i)&&Fp(this.a,this.f&256?t.f&256?t.a:null:t.f&256?null:t.a)&&Fp(this.d,t.d)&&Fp(this.g,t.g)&&Fp(this.e,t.e)&&U2e(this,t)):!1},Q.Hb=function(){return this.f},Q.Ib=function(){return qut(this)},Q.f=0;var OVt=0,kVt=0,AVt=0,jVt=0,MVt=0,NVt=0,PVt=0,FVt=0,IVt=0,LVt,y7=0,b7=0,RVt=0,zVt=0,x7,BVt;L(uU,`URI`,288),q(1121,45,CI,u_e),Q.zc=function(e,t){return P(H_(this,kd(e),P(t,288)),288)},L(uU,`URI/URICache`,1121),q(506,66,SU,Nse,Hp),Q.Si=function(){return!0},L(uU,`UniqueEList`,506),q(590,63,SF,Nb),L(uU,`WrappedException`,590);var S7=gp(zH,lwt),C7=gp(zH,uwt),w7=gp(zH,dwt),T7=gp(zH,fwt),E7=gp(zH,pwt),D7=gp(zH,`EClass`),O7=gp(zH,`EDataType`),VVt;q(1233,45,CI,d_e),Q.xc=function(e){return rl(e)?v_(this,e):nl(Kp(this.f,e))},L(zH,`EDataType/Internal/ConversionDelegate/Factory/Registry/Impl`,1233);var k7=gp(zH,`EEnum`),A7=gp(zH,mwt),j7=gp(zH,hwt),M7=gp(zH,gwt),N7,P7=gp(zH,_wt),F7=gp(zH,vwt);q(1042,1,{},Mse),Q.Ib=function(){return`NIL`},L(zH,`EStructuralFeature/Internal/DynamicValueHolder/1`,1042);var HVt;q(1041,45,CI,f_e),Q.xc=function(e){return rl(e)?v_(this,e):nl(Kp(this.f,e))},L(zH,`EStructuralFeature/Internal/SettingDelegate/Factory/Registry/Impl`,1041);var I7=gp(zH,ywt),L7=gp(zH,`EValidator/PatternMatcher`),UVt,R7,z7,B7,V7,H7,WVt,GVt,KVt,U7,W7,G7,K7,q7,qVt,JVt,J7,Y7,YVt,X7,Z7,Q7,$7,XVt,ZVt,e9,t9=gp(IU,`FeatureMap/Entry`);q(545,1,{76:1},Zc),Q.Lk=function(){return this.a},Q.md=function(){return this.b},L(KH,`BasicEObjectImpl/1`,545),q(1040,1,LU,JSe),Q.Fk=function(e){return wy(this.a,this.b,e)},Q.Qj=function(){return iRe(this.a,this.b)},Q.Wb=function(e){rRe(this.a,this.b,e)},Q.Gk=function(){yFe(this.a,this.b)},L(KH,`BasicEObjectImpl/4`,1040),q(2081,1,{114:1}),Q.Mk=function(e){this.e=e==0?QVt:V(WW,FP,1,e,5,1)},Q.li=function(e){return this.e[e]},Q.mi=function(e,t){this.e[e]=t},Q.ni=function(e){this.e[e]=null},Q.Nk=function(){return this.c},Q.Ok=function(){throw E(new Br)},Q.Pk=function(){throw E(new Br)},Q.Qk=function(){return this.d},Q.Rk=function(){return this.e!=null},Q.Sk=function(e){this.c=e},Q.Tk=function(e){throw E(new Br)},Q.Uk=function(e){throw E(new Br)},Q.Vk=function(e){this.d=e};var QVt;L(KH,`BasicEObjectImpl/EPropertiesHolderBaseImpl`,2081),q(192,2081,{114:1},fn),Q.Ok=function(){return this.a},Q.Pk=function(){return this.b},Q.Tk=function(e){this.a=e},Q.Uk=function(e){this.b=e},L(KH,`BasicEObjectImpl/EPropertiesHolderImpl`,192),q(516,99,nCt,sn),Q.uh=function(){return this.f},Q.zh=function(){return this.k},Q.Bh=function(e,t){this.g=e,this.i=t},Q.Dh=function(){return this.j&2?this.$h().Nk():this.ii()},Q.Fh=function(){return this.i},Q.wh=function(){return!!(this.j&1)},Q.Ph=function(){return this.g},Q.Vh=function(){return!!(this.j&4)},Q.$h=function(){return!this.k&&(this.k=new fn),this.k},Q.ci=function(e){this.$h().Sk(e),e?this.j|=2:this.j&=-3},Q.ei=function(e){this.$h().Uk(e),e?this.j|=4:this.j&=-5},Q.ii=function(){return(vh(),z7).S},Q.i=0,Q.j=1,L(KH,`EObjectImpl`,516),q(798,516,{110:1,94:1,93:1,58:1,114:1,54:1,99:1},eMe),Q.li=function(e){return this.e[e]},Q.mi=function(e,t){this.e[e]=t},Q.ni=function(e){this.e[e]=null},Q.Dh=function(){return this.d},Q.Ih=function(e){return eD(this.d,e)},Q.Kh=function(){return this.d},Q.Oh=function(){return this.e!=null},Q.$h=function(){return!this.k&&(this.k=new Bse),this.k},Q.ci=function(e){this.d=e},Q.hi=function(){var e;return this.e??=(e=bh(this.d),e==0?$Vt:V(WW,FP,1,e,5,1)),this},Q.ji=function(){return 0};var $Vt;L(KH,`DynamicEObjectImpl`,798),q(1522,798,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1},OMe),Q.Fb=function(e){return this===e},Q.Hb=function(){return td(this)},Q.ci=function(e){this.d=e,this.b=Qj(e,`key`),this.c=Qj(e,tU)},Q.Bi=function(){var e;return this.a==-1&&(e=Kb(this,this.b),this.a=e==null?0:US(e)),this.a},Q.ld=function(){return Kb(this,this.b)},Q.md=function(){return Kb(this,this.c)},Q.Ci=function(e){this.a=e},Q.Di=function(e){rRe(this,this.b,e)},Q.nd=function(e){var t=Kb(this,this.c);return rRe(this,this.c,e),t},Q.a=0,L(KH,`DynamicEObjectImpl/BasicEMapEntry`,1522),q(1523,1,{114:1},Bse),Q.Mk=function(e){throw E(new Br)},Q.li=function(e){throw E(new Br)},Q.mi=function(e,t){throw E(new Br)},Q.ni=function(e){throw E(new Br)},Q.Nk=function(){throw E(new Br)},Q.Ok=function(){return this.a},Q.Pk=function(){return this.b},Q.Qk=function(){return this.c},Q.Rk=function(){throw E(new Br)},Q.Sk=function(e){throw E(new Br)},Q.Tk=function(e){this.a=e},Q.Uk=function(e){this.b=e},Q.Vk=function(e){this.c=e},L(KH,`DynamicEObjectImpl/DynamicEPropertiesHolderImpl`,1523),q(519,158,{110:1,94:1,93:1,598:1,155:1,58:1,114:1,54:1,99:1,519:1,158:1,119:1,120:1},Vse),Q.Ah=function(e){return T6e(this,e)},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.d;case 2:return n?(!this.b&&(this.b=new Td((CP(),$7),o9,this)),this.b):(!this.b&&(this.b=new Td((CP(),$7),o9,this)),Jy(this.b));case 3:return hRe(this);case 4:return!this.a&&(this.a=new ju(L5,this,4)),this.a;case 5:return!this.c&&(this.c=new Pu(L5,this,5)),this.c}return xb(this,e-bh((CP(),B7)),_x((r=P(NC(this,16),29),r||B7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 3:return this.Cb&&(n=(i=this.Db>>16,i>=0?T6e(this,n):this.Cb.Th(this,-1-i,null,n))),MNe(this,P(e,155),n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),B7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),B7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 2:return!this.b&&(this.b=new Td((CP(),$7),o9,this)),gf(this.b,e,n);case 3:return MNe(this,null,n);case 4:return!this.a&&(this.a=new ju(L5,this,4)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),B7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),B7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.d!=null;case 2:return!!this.b&&this.b.f!=0;case 3:return!!hRe(this);case 4:return!!this.a&&this.a.i!=0;case 5:return!!this.c&&this.c.i!=0}return Hv(this,e-bh((CP(),B7)),_x((t=P(NC(this,16),29),t||B7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:PMe(this,kd(t));return;case 2:!this.b&&(this.b=new Td((CP(),$7),o9,this)),bC(this.b,t);return;case 3:Aot(this,P(t,155));return;case 4:!this.a&&(this.a=new ju(L5,this,4)),RN(this.a),!this.a&&(this.a=new ju(L5,this,4)),th(this.a,P(t,16));return;case 5:!this.c&&(this.c=new Pu(L5,this,5)),RN(this.c),!this.c&&(this.c=new Pu(L5,this,5)),th(this.c,P(t,16));return}LE(this,e-bh((CP(),B7)),_x((n=P(NC(this,16),29),n||B7),e),t)},Q.ii=function(){return CP(),B7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:FJe(this,null);return;case 2:!this.b&&(this.b=new Td((CP(),$7),o9,this)),this.b.c.$b();return;case 3:Aot(this,null);return;case 4:!this.a&&(this.a=new ju(L5,this,4)),RN(this.a);return;case 5:!this.c&&(this.c=new Pu(L5,this,5)),RN(this.c);return}PT(this,e-bh((CP(),B7)),_x((t=P(NC(this,16),29),t||B7),e))},Q.Ib=function(){return L$e(this)},Q.d=null,L(KH,`EAnnotationImpl`,519),q(141,721,bwt,lb),Q.Gi=function(e,t){awe(this,e,P(t,44))},Q.Wk=function(e,t){return KOe(this,P(e,44),t)},Q.$i=function(e){return P(P(this.c,71).$i(e),136)},Q.Ii=function(){return P(this.c,71).Ii()},Q.Ji=function(){return P(this.c,71).Ji()},Q.Ki=function(e){return P(this.c,71).Ki(e)},Q.Xk=function(e,t){return gf(this,e,t)},Q.Fk=function(e){return P(this.c,79).Fk(e)},Q.ak=function(){},Q.Qj=function(){return P(this.c,79).Qj()},Q.ck=function(e,t,n){var r=P(Mx(this.b).wi().si(this.b),136);return r.Ci(e),r.Di(t),r.nd(n),r},Q.dk=function(){return new Yhe(this)},Q.Wb=function(e){bC(this,e)},Q.Gk=function(){P(this.c,79).Gk()},L(IU,`EcoreEMap`,141),q(165,141,bwt,Td),Q._j=function(){var e,t,n,r,i,a;if(this.d==null){for(a=V(SVt,awt,66,2*this.f+1,0,1),n=this.c.Kc();n.e!=n.i.gc();)t=P(n.Yj(),136),r=t.Bi(),i=(r&AP)%a.length,e=a[i],!e&&(e=a[i]=new Yhe(this)),e.Fc(t);this.d=a}},L(KH,`EAnnotationImpl/1`,165),q(292,448,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,481:1,54:1,99:1,158:1,292:1,119:1,120:1}),Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!this.Jk();case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return this.Jk();case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0)}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:this.ui(kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:this.Zk(P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),ZVt},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:this.ui(null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.Zk(1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){Ik(this),this.Bb|=1},Q.Hk=function(){return Ik(this)},Q.Ik=function(){return this.t},Q.Jk=function(){var e;return e=this.t,e>1||e==-1},Q.Si=function(){return!!(this.Bb&512)},Q.Yk=function(e,t){return kT(this,e,t)},Q.Zk=function(e){Qx(this,e)},Q.Ib=function(){return Srt(this)},Q.s=0,Q.t=1,L(KH,`ETypedElementImpl`,292),q(462,292,{110:1,94:1,93:1,155:1,197:1,58:1,179:1,69:1,114:1,481:1,54:1,99:1,158:1,462:1,292:1,119:1,120:1,692:1}),Q.Ah=function(e){return X3e(this,e)},Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!this.Jk();case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this)}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 17:return this.Cb&&(n=(i=this.Db>>16,i>=0?X3e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,17,n)}return a=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),a.wk().zk(this,WD(this),t-bh(this.ii()),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 17:return qM(this,null,17,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return this.Jk();case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this)}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:this.Zk(P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),XVt},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.Zk(1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.pi=function(){lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.pk=function(){return this.f},Q.ik=function(){return Uj(this)},Q.qk=function(){return L_(this)},Q.uk=function(){return null},Q.$k=function(){return this.k},Q.Lj=function(){return this.n},Q.vk=function(){return $k(this)},Q.wk=function(){var e,t,n,r,i,a,o,s,c;return this.p||(n=L_(this),(n.i??aN(n),n.i).length,r=this.uk(),r&&bh(L_(r)),i=Ik(this),o=i.kk(),e=o?o.i&1?o==J9?bG:o==q9?DG:o==Q9?EG:o==Z9?TG:o==Y9?kG:o==$9?PG:o==X9?xG:CG:o:null,t=Uj(this),s=i.ik(),E1e(this),(this.Bb&ZP)!=0&&((a=C8e((UA(),l9),n))&&a!=this||(a=mv(Rb(l9,this))))?this.p=new XSe(this,a):this.Jk()?this.al()?this.p=r?(this.Bb&RU)==0?e?this.bl()?new Og(49,e,this,r):new Og(7,e,this,r):this.bl()?new ty(48,this,r):new ty(6,this,r):e?this.bl()?new Og(47,e,this,r):new Og(5,e,this,r):this.bl()?new ty(46,this,r):new ty(4,this,r):(this.Bb&RU)==0?e?e==YW?new Wf(41,yVt,this):this.bl()?new Wf(45,e,this):new Wf(3,e,this):this.bl()?new a_(44,this):new a_(2,this):e?e==YW?new Wf(50,yVt,this):this.bl()?new Wf(43,e,this):new Wf(1,e,this):this.bl()?new a_(42,this):new a_(0,this):j(i,156)?this.p=e==t9?new a_(40,this):this.Bb&512?(this.Bb&RU)==0?e?new Wf(11,e,this):new a_(10,this):e?new Wf(9,e,this):new a_(8,this):(this.Bb&RU)==0?e?new Wf(15,e,this):new a_(14,this):e?new Wf(13,e,this):new a_(12,this):r?(c=r.t,this.p=c>1||c==-1?this.bl()?(this.Bb&RU)==0?e?new Og(27,e,this,r):new ty(26,this,r):e?new Og(25,e,this,r):new ty(24,this,r):(this.Bb&RU)==0?e?new Og(31,e,this,r):new ty(30,this,r):e?new Og(29,e,this,r):new ty(28,this,r):this.bl()?(this.Bb&RU)==0?e?new Og(35,e,this,r):new ty(34,this,r):e?new Og(33,e,this,r):new ty(32,this,r):(this.Bb&RU)==0?e?new Og(39,e,this,r):new ty(38,this,r):e?new Og(37,e,this,r):new ty(36,this,r)):this.p=this.bl()?(this.Bb&RU)==0?e?new Wf(19,e,this):new a_(18,this):e?new Wf(17,e,this):new a_(16,this):(this.Bb&RU)==0?e?new Wf(23,e,this):new a_(22,this):e?new Wf(21,e,this):new a_(20,this):this.p=this._k()?this.bl()?new fje(P(i,29),this,r):new ILe(P(i,29),this,r):j(i,156)?e==t9?new a_(40,this):(this.Bb&RU)==0?e?new kNe(t,s,this,(mD(),o==q9?lHt:o==J9?iHt:o==Y9?uHt:o==Q9?cHt:o==Z9?sHt:o==$9?dHt:o==X9?aHt:o==K9?oHt:c9)):new gIe(P(i,156),t,s,this):e?new ANe(t,s,this,(mD(),o==q9?lHt:o==J9?iHt:o==Y9?uHt:o==Q9?cHt:o==Z9?sHt:o==$9?dHt:o==X9?aHt:o==K9?oHt:c9)):new _Ie(P(i,156),t,s,this):this.al()?r?(this.Bb&RU)==0?this.bl()?new hje(P(i,29),this,r):new Gf(P(i,29),this,r):this.bl()?new _je(P(i,29),this,r):new gje(P(i,29),this,r):(this.Bb&RU)==0?this.bl()?new JEe(P(i,29),this):new Ed(P(i,29),this):this.bl()?new ZEe(P(i,29),this):new YEe(P(i,29),this):this.bl()?r?(this.Bb&RU)==0?new pje(P(i,29),this,r):new vje(P(i,29),this,r):(this.Bb&RU)==0?new XEe(P(i,29),this):new QEe(P(i,29),this):r?(this.Bb&RU)==0?new mje(P(i,29),this,r):new yje(P(i,29),this,r):(this.Bb&RU)==0?new Bp(P(i,29),this):new $Ee(P(i,29),this)),this.p},Q.rk=function(){return(this.Bb&pF)!=0},Q._k=function(){return!1},Q.al=function(){return!1},Q.sk=function(){return(this.Bb&ZP)!=0},Q.xk=function(){return ex(this)},Q.bl=function(){return!1},Q.tk=function(){return(this.Bb&RU)!=0},Q.cl=function(e){this.k=e},Q.ui=function(e){X_(this,e)},Q.Ib=function(){return SM(this)},Q.e=!1,Q.n=0,L(KH,`EStructuralFeatureImpl`,462),q(331,462,{110:1,94:1,93:1,35:1,155:1,197:1,58:1,179:1,69:1,114:1,481:1,54:1,99:1,331:1,158:1,462:1,292:1,119:1,120:1,692:1},oi),Q.Lh=function(e,t,n){var r,i;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),!!Dnt(this);case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this);case 18:return rd(),(this.Bb&GH)!=0;case 19:return t?QC(this):tWe(this)}return xb(this,e-bh((CP(),V7)),_x((r=P(NC(this,16),29),r||V7),e),t,n)},Q.Wh=function(e){var t,n;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return Dnt(this);case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this);case 18:return(this.Bb&GH)!=0;case 19:return!!tWe(this)}return Hv(this,e-bh((CP(),V7)),_x((t=P(NC(this,16),29),t||V7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Zve(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return;case 18:mE(this,ki(Od(t)));return}LE(this,e-bh((CP(),V7)),_x((n=P(NC(this,16),29),n||V7),e),t)},Q.ii=function(){return CP(),V7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:this.b=0,Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return;case 18:mE(this,!1);return}PT(this,e-bh((CP(),V7)),_x((t=P(NC(this,16),29),t||V7),e))},Q.pi=function(){QC(this),lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.Jk=function(){return Dnt(this)},Q.Yk=function(e,t){return this.b=0,this.a=null,kT(this,e,t)},Q.Zk=function(e){Zve(this,e)},Q.Ib=function(){var e;return this.Db&64?SM(this):(e=new Wu(SM(this)),e.a+=` (iD: `,Ga(e,(this.Bb&GH)!=0),e.a+=`)`,e.a)},Q.b=0,L(KH,`EAttributeImpl`,331),q(364,448,{110:1,94:1,93:1,142:1,155:1,197:1,58:1,114:1,54:1,99:1,364:1,158:1,119:1,120:1,691:1}),Q.dl=function(e){return e.Dh()==this},Q.Ah=function(e){return bk(this,e)},Q.Bh=function(e,t){this.w=null,this.Db=t<<16|this.Db&255,this.Cb=e},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.D==null?this.B:this.D;case 3:return _k(this);case 4:return this.ik();case 5:return this.F;case 6:return t?Mx(this):F_(this);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),this.A}return xb(this,e-bh(this.ii()),_x((r=P(NC(this,16),29),r||this.ii()),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n)}return a=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),a.wk().zk(this,WD(this),t-bh(this.ii()),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n)}return i=P(_x((r=P(NC(this,16),29),r||this.ii()),t),69),i.wk().Ak(this,WD(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return this.ik()!=null;case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0}return Hv(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return}LE(this,e-bh(this.ii()),_x((n=P(NC(this,16),29),n||this.ii()),e),t)},Q.ii=function(){return CP(),WVt},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return}PT(this,e-bh(this.ii()),_x((t=P(NC(this,16),29),t||this.ii()),e))},Q.hk=function(){var e;return this.G==-1&&(this.G=(e=Mx(this),e?NO(e.vi(),this):-1)),this.G},Q.ik=function(){return null},Q.jk=function(){return Mx(this)},Q.el=function(){return this.v},Q.kk=function(){return _k(this)},Q.lk=function(){return this.D==null?this.B:this.D},Q.mk=function(){return this.F},Q.fk=function(e){return QM(this,e)},Q.fl=function(e){this.v=e},Q.gl=function(e){fYe(this,e)},Q.hl=function(e){this.C=e},Q.ui=function(e){Y_(this,e)},Q.Ib=function(){return sD(this)},Q.C=null,Q.D=null,Q.G=-1,L(KH,`EClassifierImpl`,364),q(90,364,{110:1,94:1,93:1,29:1,142:1,155:1,197:1,58:1,114:1,54:1,99:1,90:1,364:1,158:1,482:1,119:1,120:1,691:1},Que),Q.dl=function(e){return pOe(this,e.Dh())},Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return this.D==null?this.B:this.D;case 3:return _k(this);case 4:return null;case 5:return this.F;case 6:return t?Mx(this):F_(this);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),this.A;case 8:return rd(),!!(this.Bb&256);case 9:return rd(),!!(this.Bb&512);case 10:return l_(this);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),this.q;case 12:return bN(this);case 13:return gN(this);case 14:return gN(this),this.r;case 15:return bN(this),this.k;case 16:return Qet(this);case 17:return fN(this);case 18:return aN(this);case 19:return zj(this);case 20:return bN(this),this.o;case 21:return!this.s&&(this.s=new F(w7,this,21,17)),this.s;case 22:return Jv(this);case 23:return _M(this)}return xb(this,e-bh((CP(),H7)),_x((r=P(NC(this,16),29),r||H7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 6:return this.Cb&&(n=(i=this.Db>>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),vD(this.q,e,n);case 21:return!this.s&&(this.s=new F(w7,this,21,17)),vD(this.s,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),H7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),H7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n);case 11:return!this.q&&(this.q=new F(M7,this,11,10)),AO(this.q,e,n);case 21:return!this.s&&(this.s=new F(w7,this,21,17)),AO(this.s,e,n);case 22:return AO(Jv(this),e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),H7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),H7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return!1;case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0;case 8:return!!(this.Bb&256);case 9:return!!(this.Bb&512);case 10:return!!this.u&&Jv(this.u.a).i!=0&&!(this.n&&QO(this.n));case 11:return!!this.q&&this.q.i!=0;case 12:return bN(this).i!=0;case 13:return gN(this).i!=0;case 14:return gN(this),this.r.i!=0;case 15:return bN(this),this.k.i!=0;case 16:return Qet(this).i!=0;case 17:return fN(this).i!=0;case 18:return aN(this).i!=0;case 19:return zj(this).i!=0;case 20:return bN(this),!!this.o;case 21:return!!this.s&&this.s.i!=0;case 22:return!!this.n&&QO(this.n);case 23:return _M(this).i!=0}return Hv(this,e-bh((CP(),H7)),_x((t=P(NC(this,16),29),t||H7),e))},Q.Zh=function(e){return(this.i==null||this.q&&this.q.i!=0?null:Qj(this,e))||rP(this,e)},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return;case 8:IT(this,ki(Od(t)));return;case 9:zT(this,ki(Od(t)));return;case 10:zN(l_(this)),th(l_(this),P(t,16));return;case 11:!this.q&&(this.q=new F(M7,this,11,10)),RN(this.q),!this.q&&(this.q=new F(M7,this,11,10)),th(this.q,P(t,16));return;case 21:!this.s&&(this.s=new F(w7,this,21,17)),RN(this.s),!this.s&&(this.s=new F(w7,this,21,17)),th(this.s,P(t,16));return;case 22:RN(Jv(this)),th(Jv(this),P(t,16));return}LE(this,e-bh((CP(),H7)),_x((n=P(NC(this,16),29),n||H7),e),t)},Q.ii=function(){return CP(),H7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return;case 8:IT(this,!1);return;case 9:zT(this,!1);return;case 10:this.u&&zN(this.u);return;case 11:!this.q&&(this.q=new F(M7,this,11,10)),RN(this.q);return;case 21:!this.s&&(this.s=new F(w7,this,21,17)),RN(this.s);return;case 22:this.n&&RN(this.n);return}PT(this,e-bh((CP(),H7)),_x((t=P(NC(this,16),29),t||H7),e))},Q.pi=function(){var e,t;if(bN(this),gN(this),Qet(this),fN(this),aN(this),zj(this),_M(this),Ey(Eje(_y(this))),this.s)for(e=0,t=this.s.i;e=0;--t)H(this,t);return oD(this,e)},Q.Gk=function(){RN(this)},Q.Zi=function(e,t){return Hqe(this,e,t)},L(IU,`EcoreEList`,632),q(505,632,JU,rp),Q.Li=function(){return!1},Q.Lj=function(){return this.c},Q.Mj=function(){return!1},Q.ol=function(){return!0},Q.Si=function(){return!0},Q.Wi=function(e,t){return t},Q.Yi=function(){return!1},Q.c=0,L(IU,`EObjectEList`,505),q(83,505,JU,ju),Q.Mj=function(){return!0},Q.ml=function(){return!1},Q.al=function(){return!0},L(IU,`EObjectContainmentEList`,83),q(555,83,JU,Mu),Q.Ni=function(){this.b=!0},Q.Qj=function(){return this.b},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.b,this.b=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.b=!1},Q.b=!1,L(IU,`EObjectContainmentEList/Unsettable`,555),q(1161,555,JU,DNe),Q.Ti=function(e,t){var n,r;return n=P(QT(this,e,t),89),Gl(this.e)&&Kr(this,new db(this.a,7,(CP(),GVt),G(t),(r=n.c,j(r,90)?P(r,29):J7),e)),n},Q.Uj=function(e,t){return C0e(this,P(e,89),t)},Q.Vj=function(e,t){return S0e(this,P(e,89),t)},Q.Wj=function(e,t,n){return L8e(this,P(e,89),P(t,89),n)},Q.Ij=function(e,t,n,r,i){switch(e){case 3:return V_(this,e,t,n,r,this.i>1);case 5:return V_(this,e,t,n,r,this.i-P(n,15).gc()>0);default:return new Hb(this.e,e,this.c,t,n,r,!0)}},Q.Tj=function(){return!0},Q.Qj=function(){return QO(this)},Q.Gk=function(){RN(this)},L(KH,`EClassImpl/1`,1161),q(1175,1174,nwt),Q.dj=function(e){var t,n=e.gj(),r,i,a,o,s;if(n!=8){if(r=N2e(e),r==0)switch(n){case 1:case 9:s=e.kj(),s!=null&&(t=_y(P(s,482)),!t.c&&(t.c=new ln),nx(t.c,e.jj())),o=e.ij(),o!=null&&(i=P(o,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29))));break;case 3:o=e.ij(),o!=null&&(i=P(o,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29))));break;case 5:if(o=e.ij(),o!=null)for(a=P(o,16).Kc();a.Ob();)i=P(a.Pb(),482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),tb(t.c,P(e.jj(),29)));break;case 4:s=e.kj(),s!=null&&(i=P(s,482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),nx(t.c,e.jj())));break;case 6:if(s=e.kj(),s!=null)for(a=P(s,16).Kc();a.Ob();)i=P(a.Pb(),482),i.Bb&1||(t=_y(i),!t.c&&(t.c=new ln),nx(t.c,e.jj()))}this.ql(r)}},Q.ql=function(e){Zct(this,e)},Q.b=63,L(KH,`ESuperAdapter`,1175),q(1176,1175,nwt,Bhe),Q.ql=function(e){$A(this,e)},L(KH,`EClassImpl/10`,1176),q(1165,710,JU),Q.Ei=function(e,t){return dA(this,e,t)},Q.Fi=function(e){return X4e(this,e)},Q.Gi=function(e,t){jT(this,e,t)},Q.Hi=function(e){Ty(this,e)},Q.$i=function(e){return SGe(this,e)},Q.Xi=function(e,t){return tx(this,e,t)},Q.Wk=function(e,t){throw E(new Br)},Q.Ii=function(){return new ld(this)},Q.Ji=function(){return new ud(this)},Q.Ki=function(e){return mS(this,e)},Q.Xk=function(e,t){throw E(new Br)},Q.Fk=function(e){return this},Q.Qj=function(){return this.i!=0},Q.Wb=function(e){throw E(new Br)},Q.Gk=function(){throw E(new Br)},L(IU,`EcoreEList/UnmodifiableEList`,1165),q(328,1165,JU,El),Q.Yi=function(){return!1},L(IU,`EcoreEList/UnmodifiableEList/FastCompare`,328),q(1168,328,JU,bZe),Q.dd=function(e){var t,n,r;if(j(e,179)&&(t=P(e,179),n=t.Lj(),n!=-1)){for(r=this.i;n4){if(this.fk(e)){if(this.al()){if(r=P(e,54),n=r.Eh(),s=n==this.b&&(this.ml()?r.yh(r.Fh(),P(_x(d_(this.b),this.Lj()).Hk(),29).kk())==qO(P(_x(d_(this.b),this.Lj()),19)).n:-1-r.Fh()==this.Lj()),this.nl()&&!s&&!n&&r.Jh()){for(i=0;i1||r==-1)):!1},Q.ml=function(){var e,t=_x(d_(this.b),this.Lj()),n;return j(t,102)?(e=P(t,19),n=qO(e),!!n):!1},Q.nl=function(){var e,t=_x(d_(this.b),this.Lj());return j(t,102)?(e=P(t,19),(e.Bb&pI)!=0):!1},Q.dd=function(e){var t,n,r=this.zj(e),i;if(r>=0)return r;if(this.ol()){for(n=0,i=this.Ej();n=0;--e)GN(this,e,this.xj(e));return this.Fj()},Q.Qc=function(e){var t;if(this.nl())for(t=this.Ej()-1;t>=0;--t)GN(this,t,this.xj(t));return this.Gj(e)},Q.Gk=function(){zN(this)},Q.Zi=function(e,t){return CGe(this,e,t)},L(IU,`DelegatingEcoreEList`,756),q(1171,756,Ewt,FDe),Q.qj=function(e,t){BEe(this,e,P(t,29))},Q.rj=function(e){twe(this,P(e,29))},Q.xj=function(e){var t,n;return t=P(H(Jv(this.a),e),89),n=t.c,j(n,90)?P(n,29):(CP(),J7)},Q.Cj=function(e){var t,n;return t=P(lM(Jv(this.a),e),89),n=t.c,j(n,90)?P(n,29):(CP(),J7)},Q.Dj=function(e,t){return Q4e(this,e,P(t,29))},Q.Li=function(){return!1},Q.Ij=function(e,t,n,r,i){return null},Q.sj=function(){return new Uhe(this)},Q.tj=function(){RN(Jv(this.a))},Q.uj=function(e){return H$e(this,e)},Q.vj=function(e){var t,n;for(n=e.Kc();n.Ob();)if(t=n.Pb(),!H$e(this,t))return!1;return!0},Q.wj=function(e){var t,n,r;if(j(e,15)&&(r=P(e,15),r.gc()==Jv(this.a).i)){for(t=r.Kc(),n=new Lu(this);t.Ob();)if(A(t.Pb())!==A(gO(n)))return!1;return!0}return!1},Q.yj=function(){var e,t,n=1,r,i;for(t=new Lu(Jv(this.a));t.e!=t.i.gc();)e=P(gO(t),89),r=(i=e.c,j(i,90)?P(i,29):(CP(),J7)),n=31*n+(r?td(r):0);return n},Q.zj=function(e){var t,n,r=0,i;for(n=new Lu(Jv(this.a));n.e!=n.i.gc();){if(t=P(gO(n),89),A(e)===A((i=t.c,j(i,90)?P(i,29):(CP(),J7))))return r;++r}return-1},Q.Aj=function(){return Jv(this.a).i==0},Q.Bj=function(){return null},Q.Ej=function(){return Jv(this.a).i},Q.Fj=function(){var e,t,n,r,i,a=Jv(this.a).i;for(i=V(WW,FP,1,a,5,1),n=0,t=new Lu(Jv(this.a));t.e!=t.i.gc();)e=P(gO(t),89),i[n++]=(r=e.c,j(r,90)?P(r,29):(CP(),J7));return i},Q.Gj=function(e){var t,n,r,i,a,o,s=Jv(this.a).i;for(e.lengths&&Sh(e,s,null),r=0,n=new Lu(Jv(this.a));n.e!=n.i.gc();)t=P(gO(n),89),a=(o=t.c,j(o,90)?P(o,29):(CP(),J7)),Sh(e,r++,a);return e},Q.Hj=function(){var e,t,n,r,i=new $i;for(i.a+=`[`,e=Jv(this.a),t=0,r=Jv(this.a).i;t>16,i>=0?bk(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,6,n);case 9:return!this.a&&(this.a=new F(A7,this,9,5)),vD(this.a,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),U7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),U7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 6:return qM(this,null,6,n);case 7:return!this.A&&(this.A=new Nu(I7,this,7)),AO(this.A,e,n);case 9:return!this.a&&(this.a=new F(A7,this,9,5)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),U7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),U7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.D!=null&&this.D==this.F;case 3:return!!_k(this);case 4:return!!AQe(this);case 5:return this.F!=null&&this.F!=this.D&&this.F!=this.B;case 6:return!!F_(this);case 7:return!!this.A&&this.A.i!=0;case 8:return!(this.Bb&256);case 9:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),U7)),_x((t=P(NC(this,16),29),t||U7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:Y_(this,kd(t));return;case 2:Xl(this,kd(t));return;case 5:qN(this,kd(t));return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A),!this.A&&(this.A=new Nu(I7,this,7)),th(this.A,P(t,16));return;case 8:LT(this,ki(Od(t)));return;case 9:!this.a&&(this.a=new F(A7,this,9,5)),RN(this.a),!this.a&&(this.a=new F(A7,this,9,5)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),U7)),_x((n=P(NC(this,16),29),n||U7),e),t)},Q.ii=function(){return CP(),U7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,184)&&(P(this.Cb,184).tb=null),GS(this,null);return;case 2:Gw(this,null),eS(this,this.D);return;case 5:qN(this,null);return;case 7:!this.A&&(this.A=new Nu(I7,this,7)),RN(this.A);return;case 8:LT(this,!0);return;case 9:!this.a&&(this.a=new F(A7,this,9,5)),RN(this.a);return}PT(this,e-bh((CP(),U7)),_x((t=P(NC(this,16),29),t||U7),e))},Q.pi=function(){var e,t;if(this.a)for(e=0,t=this.a.i;e>16==5?P(this.Cb,685):null}return xb(this,e-bh((CP(),W7)),_x((r=P(NC(this,16),29),r||W7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 5:return this.Cb&&(n=(i=this.Db>>16,i>=0?C6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,5,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),W7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),W7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 5:return qM(this,null,5,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),W7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),W7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return this.d!=0;case 3:return!!this.b;case 4:return this.c!=null;case 5:return!!(this.Db>>16==5&&P(this.Cb,685))}return Hv(this,e-bh((CP(),W7)),_x((t=P(NC(this,16),29),t||W7),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:$x(this,P(t,17).a);return;case 3:nrt(this,P(t,2039));return;case 4:SS(this,kd(t));return}LE(this,e-bh((CP(),W7)),_x((n=P(NC(this,16),29),n||W7),e),t)},Q.ii=function(){return CP(),W7},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:$x(this,0);return;case 3:nrt(this,null);return;case 4:SS(this,null);return}PT(this,e-bh((CP(),W7)),_x((t=P(NC(this,16),29),t||W7),e))},Q.Ib=function(){var e;return e=this.c,e??this.zb},Q.b=null,Q.c=null,Q.d=0,L(KH,`EEnumLiteralImpl`,582);var tHt=gp(KH,`EFactoryImpl/InternalEDateTimeFormat`);q(499,1,{2114:1},br),L(KH,`EFactoryImpl/1ClientInternalEDateTimeFormat`,499),q(248,120,{110:1,94:1,93:1,89:1,58:1,114:1,54:1,99:1,248:1,119:1,120:1},kr),Q.Ch=function(e,t,n){var r;return n=qM(this,e,t,n),this.e&&j(e,179)&&(r=Rj(this,this.e),r!=this.c&&(n=JN(this,r,n))),n},Q.Lh=function(e,t,n){var r;switch(e){case 0:return this.f;case 1:return!this.d&&(this.d=new ju(j7,this,1)),this.d;case 2:return t?ZM(this):this.c;case 3:return this.b;case 4:return this.e;case 5:return t?nk(this):this.a}return xb(this,e-bh((CP(),K7)),_x((r=P(NC(this,16),29),r||K7),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return p$e(this,null,n);case 1:return!this.d&&(this.d=new ju(j7,this,1)),AO(this.d,e,n);case 3:return m$e(this,null,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),K7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),K7)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.f;case 1:return!!this.d&&this.d.i!=0;case 2:return!!this.c;case 3:return!!this.b;case 4:return!!this.e;case 5:return!!this.a}return Hv(this,e-bh((CP(),K7)),_x((t=P(NC(this,16),29),t||K7),e))},Q.bi=function(e,t){var n;switch(e){case 0:d5e(this,P(t,89));return;case 1:!this.d&&(this.d=new ju(j7,this,1)),RN(this.d),!this.d&&(this.d=new ju(j7,this,1)),th(this.d,P(t,16));return;case 3:u5e(this,P(t,89));return;case 4:i9e(this,P(t,850));return;case 5:Nx(this,P(t,142));return}LE(this,e-bh((CP(),K7)),_x((n=P(NC(this,16),29),n||K7),e),t)},Q.ii=function(){return CP(),K7},Q.ki=function(e){var t;switch(e){case 0:d5e(this,null);return;case 1:!this.d&&(this.d=new ju(j7,this,1)),RN(this.d);return;case 3:u5e(this,null);return;case 4:i9e(this,null);return;case 5:Nx(this,null);return}PT(this,e-bh((CP(),K7)),_x((t=P(NC(this,16),29),t||K7),e))},Q.Ib=function(){var e=new Gu(Aj(this));return e.a+=` (expression: `,kN(this,e),e.a+=`)`,e.a};var nHt;L(KH,`EGenericTypeImpl`,248),q(2067,2062,QU),Q.Gi=function(e,t){ADe(this,e,t)},Q.Wk=function(e,t){return ADe(this,this.gc(),e),t},Q.$i=function(e){return SO(this.pj(),e)},Q.Ii=function(){return this.Ji()},Q.pj=function(){return new Jhe(this)},Q.Ji=function(){return this.Ki(0)},Q.Ki=function(e){return this.pj().fd(e)},Q.Xk=function(e,t){return QE(this,e,!0),t},Q.Ti=function(e,t){var n,r=Mk(this,t);return n=this.fd(e),n.Rb(r),r},Q.Ui=function(e,t){var n;QE(this,t,!0),n=this.fd(e),n.Rb(t)},L(IU,`AbstractSequentialInternalEList`,2067),q(496,2067,QU,ad),Q.$i=function(e){return SO(this.pj(),e)},Q.Ii=function(){return this.b==null?(Xo(),Xo(),a9):this.sl()},Q.pj=function(){return new mCe(this.a,this.b)},Q.Ji=function(){return this.b==null?(Xo(),Xo(),a9):this.sl()},Q.Ki=function(e){var t,n;if(this.b==null){if(e<0||e>1)throw E(new Mi(PU+e+`, size=0`));return Xo(),Xo(),a9}for(n=this.sl(),t=0;t0;)if(t=this.c[--this.d],(!this.e||t.pk()!=R5||t.Lj()!=0)&&(!this.vl()||this.b.Xh(t))){if(a=this.b.Nh(t,this.ul()),this.f=(Qo(),P(t,69).xk()),this.f||t.Jk()){if(this.ul()?(r=P(a,15),this.k=r):(r=P(a,71),this.k=this.j=r),j(this.k,59)?(this.o=this.k.gc(),this.n=this.o):this.p=this.j?this.j.Ki(this.k.gc()):this.k.fd(this.k.gc()),this.p?Pet(this,this.p):ytt(this))return i=this.p?this.p.Ub():this.j?this.j.$i(--this.n):this.k.Xb(--this.n),this.f?(e=P(i,76),e.Lk(),n=e.md(),this.i=n):(n=i,this.i=n),this.g=-3,!0}else if(a!=null)return this.k=null,this.p=null,n=a,this.i=n,this.g=-2,!0}return this.k=null,this.p=null,this.g=-1,!1}return i=this.p?this.p.Ub():this.j?this.j.$i(--this.n):this.k.Xb(--this.n),this.f?(e=P(i,76),e.Lk(),n=e.md(),this.i=n):(n=i,this.i=n),this.g=-3,!0}},Q.Pb=function(){return IC(this)},Q.Tb=function(){return this.a},Q.Ub=function(){var e;if(this.g<-1||this.Sb())return--this.a,this.g=0,e=this.i,this.Sb(),e;throw E(new Hr)},Q.Vb=function(){return this.a-1},Q.Qb=function(){throw E(new Br)},Q.ul=function(){return!1},Q.Wb=function(e){throw E(new Br)},Q.vl=function(){return!0},Q.a=0,Q.d=0,Q.f=!1,Q.g=0,Q.n=0,Q.o=0;var a9;L(IU,`EContentsEList/FeatureIteratorImpl`,287),q(711,287,$U,HEe),Q.ul=function(){return!0},L(IU,`EContentsEList/ResolvingFeatureIteratorImpl`,711),q(1178,711,$U,UEe),Q.vl=function(){return!1},L(KH,`ENamedElementImpl/1/1`,1178),q(1179,287,$U,WEe),Q.vl=function(){return!1},L(KH,`ENamedElementImpl/1/2`,1179),q(39,152,NU,Qv,$v,Sm,ub,Hb,vy,Gqe,nBe,Kqe,rBe,vUe,iBe,Yqe,aBe,yUe,oBe,qqe,sBe,Cm,db,Jg,Jqe,cBe,bUe,lBe),Q.Kj=function(){return eb(this)},Q.Rj=function(){var e=eb(this);return e?e.ik():null},Q.hj=function(e){return this.b==-1&&this.a&&(this.b=this.c.Hh(this.a.Lj(),this.a.pk())),this.c.yh(this.b,e)},Q.jj=function(){return this.c},Q.Sj=function(){var e=eb(this);return e?e.tk():!1},Q.b=-1,L(KH,`ENotificationImpl`,39),q(411,292,{110:1,94:1,93:1,155:1,197:1,58:1,62:1,114:1,481:1,54:1,99:1,158:1,411:1,292:1,119:1,120:1},si),Q.Ah=function(e){return I6e(this,e)},Q.Lh=function(e,t,n){var r,i,a;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),a=this.t,a>1||a==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return this.Db>>16==10?P(this.Cb,29):null;case 11:return!this.d&&(this.d=new Nu(I7,this,11)),this.d;case 12:return!this.c&&(this.c=new F(P7,this,12,10)),this.c;case 13:return!this.a&&(this.a=new Ud(this,this)),this.a;case 14:return Ib(this)}return xb(this,e-bh((CP(),Y7)),_x((r=P(NC(this,16),29),r||Y7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 10:return this.Cb&&(n=(i=this.Db>>16,i>=0?I6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,10,n);case 12:return!this.c&&(this.c=new F(P7,this,12,10)),vD(this.c,e,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),Y7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),Y7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 10:return qM(this,null,10,n);case 11:return!this.d&&(this.d=new Nu(I7,this,11)),AO(this.d,e,n);case 12:return!this.c&&(this.c=new F(P7,this,12,10)),AO(this.c,e,n);case 14:return AO(Ib(this),e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),Y7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),Y7)),e,n)},Q.Wh=function(e){var t,n,r;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return r=this.t,r>1||r==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return!!(this.Db>>16==10&&P(this.Cb,29));case 11:return!!this.d&&this.d.i!=0;case 12:return!!this.c&&this.c.i!=0;case 13:return!!this.a&&Ib(this.a.a).i!=0&&!(this.b&&$O(this.b));case 14:return!!this.b&&$O(this.b)}return Hv(this,e-bh((CP(),Y7)),_x((t=P(NC(this,16),29),t||Y7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Qx(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 11:!this.d&&(this.d=new Nu(I7,this,11)),RN(this.d),!this.d&&(this.d=new Nu(I7,this,11)),th(this.d,P(t,16));return;case 12:!this.c&&(this.c=new F(P7,this,12,10)),RN(this.c),!this.c&&(this.c=new F(P7,this,12,10)),th(this.c,P(t,16));return;case 13:!this.a&&(this.a=new Ud(this,this)),zN(this.a),!this.a&&(this.a=new Ud(this,this)),th(this.a,P(t,16));return;case 14:RN(Ib(this)),th(Ib(this),P(t,16));return}LE(this,e-bh((CP(),Y7)),_x((n=P(NC(this,16),29),n||Y7),e),t)},Q.ii=function(){return CP(),Y7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 11:!this.d&&(this.d=new Nu(I7,this,11)),RN(this.d);return;case 12:!this.c&&(this.c=new F(P7,this,12,10)),RN(this.c);return;case 13:this.a&&zN(this.a);return;case 14:this.b&&RN(this.b);return}PT(this,e-bh((CP(),Y7)),_x((t=P(NC(this,16),29),t||Y7),e))},Q.pi=function(){var e,t;if(this.c)for(e=0,t=this.c.i;es&&Sh(e,s,null),r=0,n=new Lu(Ib(this.a));n.e!=n.i.gc();)t=P(gO(n),89),a=(o=t.c,o||(CP(),q7)),Sh(e,r++,a);return e},Q.Hj=function(){var e,t,n,r,i=new $i;for(i.a+=`[`,e=Ib(this.a),t=0,r=Ib(this.a).i;t1);case 5:return V_(this,e,t,n,r,this.i-P(n,15).gc()>0);default:return new Hb(this.e,e,this.c,t,n,r,!0)}},Q.Tj=function(){return!0},Q.Qj=function(){return $O(this)},Q.Gk=function(){RN(this)},L(KH,`EOperationImpl/2`,1377),q(507,1,{2037:1,507:1},YSe),L(KH,`EPackageImpl/1`,507),q(14,83,JU,F),Q.il=function(){return this.d},Q.jl=function(){return this.b},Q.ml=function(){return!0},Q.b=0,L(IU,`EObjectContainmentWithInverseEList`,14),q(365,14,JU,nf),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentWithInverseEList/Resolving`,365),q(308,365,JU,Tm),Q.Ni=function(){this.a.tb=null},L(KH,`EPackageImpl/2`,308),q(1278,1,{},Jse),L(KH,`EPackageImpl/3`,1278),q(733,45,CI,ci),Q._b=function(e){return rl(e)?e_(this,e):!!Kp(this.f,e)},L(KH,`EPackageRegistryImpl`,733),q(518,292,{110:1,94:1,93:1,155:1,197:1,58:1,2116:1,114:1,481:1,54:1,99:1,158:1,518:1,292:1,119:1,120:1},li),Q.Ah=function(e){return L6e(this,e)},Q.Lh=function(e,t,n){var r,i,a;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),a=this.t,a>1||a==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return this.Db>>16==10?P(this.Cb,62):null}return xb(this,e-bh((CP(),Z7)),_x((r=P(NC(this,16),29),r||Z7),e),t,n)},Q.Sh=function(e,t,n){var r,i,a;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),vD(this.Ab,e,n);case 10:return this.Cb&&(n=(i=this.Db>>16,i>=0?L6e(this,n):this.Cb.Th(this,-1-i,null,n))),qM(this,e,10,n)}return a=P(_x((r=P(NC(this,16),29),r||(CP(),Z7)),t),69),a.wk().zk(this,WD(this),t-bh((CP(),Z7)),e,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 9:return nh(this,n);case 10:return qM(this,null,10,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),Z7)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),Z7)),e,n)},Q.Wh=function(e){var t,n,r;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return r=this.t,r>1||r==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return!!(this.Db>>16==10&&P(this.Cb,62))}return Hv(this,e-bh((CP(),Z7)),_x((t=P(NC(this,16),29),t||Z7),e))},Q.ii=function(){return CP(),Z7},L(KH,`EParameterImpl`,518),q(102,462,{110:1,94:1,93:1,155:1,197:1,58:1,19:1,179:1,69:1,114:1,481:1,54:1,99:1,158:1,102:1,462:1,292:1,119:1,120:1,692:1},uDe),Q.Lh=function(e,t,n){var r,i,a,o;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return rd(),!!(this.Bb&256);case 3:return rd(),!!(this.Bb&512);case 4:return G(this.s);case 5:return G(this.t);case 6:return rd(),o=this.t,o>1||o==-1;case 7:return rd(),i=this.s,i>=1;case 8:return t?Ik(this):this.r;case 9:return this.q;case 10:return rd(),(this.Bb&pF)!=0;case 11:return rd(),(this.Bb&zU)!=0;case 12:return rd(),(this.Bb&uI)!=0;case 13:return this.j;case 14:return Uj(this);case 15:return rd(),(this.Bb&RU)!=0;case 16:return rd(),(this.Bb&ZP)!=0;case 17:return L_(this);case 18:return rd(),(this.Bb&GH)!=0;case 19:return rd(),a=qO(this),!!(a&&(a.Bb&GH)!=0);case 20:return rd(),(this.Bb&pI)!=0;case 21:return t?qO(this):this.b;case 22:return t?DZe(this):DUe(this);case 23:return!this.a&&(this.a=new Pu(T7,this,23)),this.a}return xb(this,e-bh((CP(),Q7)),_x((r=P(NC(this,16),29),r||Q7),e),t,n)},Q.Wh=function(e){var t,n,r,i;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!(this.Bb&256);case 3:return!(this.Bb&512);case 4:return this.s!=0;case 5:return this.t!=1;case 6:return i=this.t,i>1||i==-1;case 7:return n=this.s,n>=1;case 8:return!!this.r&&!this.q.e&&kh(this.q).i==0;case 9:return!!this.q&&!(this.r&&!this.q.e&&kh(this.q).i==0);case 10:return(this.Bb&pF)==0;case 11:return(this.Bb&zU)!=0;case 12:return(this.Bb&uI)!=0;case 13:return this.j!=null;case 14:return Uj(this)!=null;case 15:return(this.Bb&RU)!=0;case 16:return(this.Bb&ZP)!=0;case 17:return!!L_(this);case 18:return(this.Bb&GH)!=0;case 19:return r=qO(this),!!r&&(r.Bb&GH)!=0;case 20:return(this.Bb&pI)==0;case 21:return!!this.b;case 22:return!!DUe(this);case 23:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),Q7)),_x((t=P(NC(this,16),29),t||Q7),e))},Q.bi=function(e,t){var n,r;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:X_(this,kd(t));return;case 2:FT(this,ki(Od(t)));return;case 3:RT(this,ki(Od(t)));return;case 4:Zx(this,P(t,17).a);return;case 5:Qx(this,P(t,17).a);return;case 8:aT(this,P(t,142));return;case 9:r=fA(this,P(t,89),null),r&&r.oj();return;case 10:eE(this,ki(Od(t)));return;case 11:rE(this,ki(Od(t)));return;case 12:tE(this,ki(Od(t)));return;case 13:Xc(this,kd(t));return;case 15:nE(this,ki(Od(t)));return;case 16:gE(this,ki(Od(t)));return;case 18:PRe(this,ki(Od(t)));return;case 20:_E(this,ki(Od(t)));return;case 21:JJe(this,P(t,19));return;case 23:!this.a&&(this.a=new Pu(T7,this,23)),RN(this.a),!this.a&&(this.a=new Pu(T7,this,23)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),Q7)),_x((n=P(NC(this,16),29),n||Q7),e),t)},Q.ii=function(){return CP(),Q7},Q.ki=function(e){var t,n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:j(this.Cb,90)&&$A(_y(P(this.Cb,90)),4),GS(this,null);return;case 2:FT(this,!0);return;case 3:RT(this,!0);return;case 4:Zx(this,0);return;case 5:Qx(this,1);return;case 8:aT(this,null);return;case 9:n=fA(this,null,null),n&&n.oj();return;case 10:eE(this,!0);return;case 11:rE(this,!1);return;case 12:tE(this,!1);return;case 13:this.i=null,OS(this,null);return;case 15:nE(this,!1);return;case 16:gE(this,!1);return;case 18:hE(this,!1),j(this.Cb,90)&&$A(_y(P(this.Cb,90)),2);return;case 20:_E(this,!0);return;case 21:JJe(this,null);return;case 23:!this.a&&(this.a=new Pu(T7,this,23)),RN(this.a);return}PT(this,e-bh((CP(),Q7)),_x((t=P(NC(this,16),29),t||Q7),e))},Q.pi=function(){DZe(this),lg(Rb((UA(),l9),this)),Ik(this),this.Bb|=1},Q.uk=function(){return qO(this)},Q._k=function(){var e;return e=qO(this),!!e&&(e.Bb&GH)!=0},Q.al=function(){return(this.Bb&GH)!=0},Q.bl=function(){return(this.Bb&pI)!=0},Q.Yk=function(e,t){return this.c=null,kT(this,e,t)},Q.Ib=function(){var e;return this.Db&64?SM(this):(e=new Wu(SM(this)),e.a+=` (containment: `,Ga(e,(this.Bb&GH)!=0),e.a+=`, resolveProxies: `,Ga(e,(this.Bb&pI)!=0),e.a+=`)`,e.a)},L(KH,`EReferenceImpl`,102),q(561,120,{110:1,44:1,94:1,93:1,136:1,58:1,114:1,54:1,99:1,561:1,119:1,120:1},Yse),Q.Fb=function(e){return this===e},Q.ld=function(){return this.b},Q.md=function(){return this.c},Q.Hb=function(){return td(this)},Q.Di=function(e){FMe(this,kd(e))},Q.nd=function(e){return Zje(this,kd(e))},Q.Lh=function(e,t,n){var r;switch(e){case 0:return this.b;case 1:return this.c}return xb(this,e-bh((CP(),$7)),_x((r=P(NC(this,16),29),r||$7),e),t,n)},Q.Wh=function(e){var t;switch(e){case 0:return this.b!=null;case 1:return this.c!=null}return Hv(this,e-bh((CP(),$7)),_x((t=P(NC(this,16),29),t||$7),e))},Q.bi=function(e,t){var n;switch(e){case 0:IMe(this,kd(t));return;case 1:PJe(this,kd(t));return}LE(this,e-bh((CP(),$7)),_x((n=P(NC(this,16),29),n||$7),e),t)},Q.ii=function(){return CP(),$7},Q.ki=function(e){var t;switch(e){case 0:NJe(this,null);return;case 1:PJe(this,null);return}PT(this,e-bh((CP(),$7)),_x((t=P(NC(this,16),29),t||$7),e))},Q.Bi=function(){var e;return this.a==-1&&(e=this.b,this.a=e==null?0:jw(e)),this.a},Q.Ci=function(e){this.a=e},Q.Ib=function(){var e;return this.Db&64?Aj(this):(e=new Wu(Aj(this)),e.a+=` (key: `,pl(e,this.b),e.a+=`, value: `,pl(e,this.c),e.a+=`)`,e.a)},Q.a=-1,Q.b=null,Q.c=null;var o9=L(KH,`EStringToStringMapEntryImpl`,561),rHt=gp(IU,`FeatureMap/Entry/Internal`);q(576,1,eW),Q.xl=function(e){return this.yl(P(e,54))},Q.yl=function(e){return this.xl(e)},Q.Fb=function(e){var t,n;return this===e?!0:j(e,76)?(t=P(e,76),t.Lk()==this.c&&(n=this.md(),n==null?t.md()==null:NT(n,t.md()))):!1},Q.Lk=function(){return this.c},Q.Hb=function(){var e=this.md();return US(this.c)^(e==null?0:US(e))},Q.Ib=function(){var e=this.c,t=Mx(e.qk()).yi();return e.xe(),(t!=null&&t.length!=0?t+`:`+e.xe():e.xe())+`=`+this.md()},L(KH,`EStructuralFeatureImpl/BasicFeatureMapEntry`,576),q(791,576,eW,IDe),Q.yl=function(e){return new IDe(this.c,e)},Q.md=function(){return this.a},Q.zl=function(e,t,n){return NYe(this,e,this.a,t,n)},Q.Al=function(e,t,n){return PYe(this,e,this.a,t,n)},L(KH,`EStructuralFeatureImpl/ContainmentUpdatingFeatureMapEntry`,791),q(1350,1,{},XSe),Q.yk=function(e,t,n,r,i){return P(mb(e,this.b),220).Yl(this.a).Fk(r)},Q.zk=function(e,t,n,r,i){return P(mb(e,this.b),220).Pl(this.a,r,i)},Q.Ak=function(e,t,n,r,i){return P(mb(e,this.b),220).Ql(this.a,r,i)},Q.Bk=function(e,t,n){return P(mb(e,this.b),220).Yl(this.a).Qj()},Q.Ck=function(e,t,n,r){P(mb(e,this.b),220).Yl(this.a).Wb(r)},Q.Dk=function(e,t,n){return P(mb(e,this.b),220).Yl(this.a)},Q.Ek=function(e,t,n){P(mb(e,this.b),220).Yl(this.a).Gk()},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateFeatureMapDelegator`,1350),q(91,1,{},Wf,Og,a_,ty),Q.yk=function(e,t,n,r,i){var a=t.li(n);if(a??t.mi(n,a=gP(this,e)),!i)switch(this.e){case 50:case 41:return P(a,597).bk();case 40:return P(a,220).Vl()}return a},Q.zk=function(e,t,n,r,i){var a,o=t.li(n);return o??t.mi(n,o=gP(this,e)),a=P(o,71).Wk(r,i),a},Q.Ak=function(e,t,n,r,i){var a=t.li(n);return a!=null&&(i=P(a,71).Xk(r,i)),i},Q.Bk=function(e,t,n){var r=t.li(n);return r!=null&&P(r,79).Qj()},Q.Ck=function(e,t,n,r){var i=P(t.li(n),79);!i&&t.mi(n,i=gP(this,e)),i.Wb(r)},Q.Dk=function(e,t,n){var r,i=t.li(n);return i??t.mi(n,i=gP(this,e)),j(i,79)?P(i,79):(r=P(t.li(n),15),new Ghe(r))},Q.Ek=function(e,t,n){var r=P(t.li(n),79);!r&&t.mi(n,r=gP(this,e)),r.Gk()},Q.b=0,Q.e=0,L(KH,`EStructuralFeatureImpl/InternalSettingDelegateMany`,91),q(512,1,{}),Q.zk=function(e,t,n,r,i){throw E(new Br)},Q.Ak=function(e,t,n,r,i){throw E(new Br)},Q.Dk=function(e,t,n){return new hIe(this,e,t,n)};var s9;L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingle`,512),q(1367,1,LU,hIe),Q.Fk=function(e){return this.a.yk(this.c,this.d,this.b,e,!0)},Q.Qj=function(){return this.a.Bk(this.c,this.d,this.b)},Q.Wb=function(e){this.a.Ck(this.c,this.d,this.b,e)},Q.Gk=function(){this.a.Ek(this.c,this.d,this.b)},Q.b=0,L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingle/1`,1367),q(784,512,{},ILe),Q.yk=function(e,t,n,r,i){return IM(e,e.Ph(),e.Fh())==this.b?this.bl()&&r?xj(e):e.Ph():null},Q.zk=function(e,t,n,r,i){var a,o;return e.Ph()&&(i=(a=e.Fh(),a>=0?e.Ah(i):e.Ph().Th(e,-1-a,null,i))),o=eD(e.Dh(),this.e),e.Ch(r,o,i)},Q.Ak=function(e,t,n,r,i){var a=eD(e.Dh(),this.e);return e.Ch(null,a,i)},Q.Bk=function(e,t,n){var r=eD(e.Dh(),this.e);return!!e.Ph()&&e.Fh()==r},Q.Ck=function(e,t,n,r){var i,a,o,s,c;if(r!=null&&!QM(this.a,r))throw E(new Pi(tW+(j(r,58)?o5e(P(r,58).Dh()):yx($w(r)))+nW+this.a+`'`));if(i=e.Ph(),o=eD(e.Dh(),this.e),A(r)!==A(i)||e.Fh()!=o&&r!=null){if(Pk(e,P(r,58)))throw E(new Fi(JH+e.Ib()));c=null,i&&(c=(a=e.Fh(),a>=0?e.Ah(c):e.Ph().Th(e,-1-a,null,c))),s=P(r,54),s&&(c=s.Rh(e,eD(s.Dh(),this.b),null,c)),c=e.Ch(s,o,c),c&&c.oj()}else e.vh()&&e.wh()&&AC(e,new Sm(e,1,o,r,r))},Q.Ek=function(e,t,n){var r=e.Ph(),i,a,o;r?(o=(i=e.Fh(),i>=0?e.Ah(null):e.Ph().Th(e,-1-i,null,null)),a=eD(e.Dh(),this.e),o=e.Ch(null,a,o),o&&o.oj()):e.vh()&&e.wh()&&AC(e,new Cm(e,1,this.e,null,null))},Q.bl=function(){return!1},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleContainer`,784),q(1351,784,{},fje),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleContainerResolving`,1351),q(574,512,{}),Q.yk=function(e,t,n,r,i){var a;return a=t.li(n),a==null?this.b:A(a)===A(s9)?null:a},Q.Bk=function(e,t,n){var r=t.li(n);return r!=null&&(A(r)===A(s9)||!NT(r,this.b))},Q.Ck=function(e,t,n,r){var i,a;e.vh()&&e.wh()?(i=(a=t.li(n),a==null?this.b:A(a)===A(s9)?null:a),r==null?this.c==null?this.b==null?t.mi(n,null):t.mi(n,s9):(t.mi(n,null),r=this.b):(this.Bl(r),t.mi(n,r)),AC(e,this.d.Cl(e,1,this.e,i,r))):r==null?this.c==null?this.b==null?t.mi(n,null):t.mi(n,s9):t.mi(n,null):(this.Bl(r),t.mi(n,r))},Q.Ek=function(e,t,n){var r,i;e.vh()&&e.wh()?(r=(i=t.li(n),i==null?this.b:A(i)===A(s9)?null:i),t.ni(n),AC(e,this.d.Cl(e,1,this.e,r,this.b))):t.ni(n)},Q.Bl=function(e){throw E(new xge)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData`,574),q(rW,1,{},Xse),Q.Cl=function(e,t,n,r,i){return new Cm(e,t,n,r,i)},Q.Dl=function(e,t,n,r,i,a){return new Jg(e,t,n,r,i,a)};var iHt,aHt,oHt,sHt,cHt,lHt,uHt,c9,dHt;L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator`,rW),q(1368,rW,{},Zse),Q.Cl=function(e,t,n,r,i){return new bUe(e,t,n,ki(Od(r)),ki(Od(i)))},Q.Dl=function(e,t,n,r,i,a){return new lBe(e,t,n,ki(Od(r)),ki(Od(i)),a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/1`,1368),q(1369,rW,{},Qse),Q.Cl=function(e,t,n,r,i){return new Gqe(e,t,n,P(r,222).a,P(i,222).a)},Q.Dl=function(e,t,n,r,i,a){return new nBe(e,t,n,P(r,222).a,P(i,222).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/2`,1369),q(1370,rW,{},$se),Q.Cl=function(e,t,n,r,i){return new Kqe(e,t,n,P(r,180).a,P(i,180).a)},Q.Dl=function(e,t,n,r,i,a){return new rBe(e,t,n,P(r,180).a,P(i,180).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/3`,1370),q(1371,rW,{},ece),Q.Cl=function(e,t,n,r,i){return new vUe(e,t,n,D(N(r)),D(N(i)))},Q.Dl=function(e,t,n,r,i,a){return new iBe(e,t,n,D(N(r)),D(N(i)),a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/4`,1371),q(1372,rW,{},tce),Q.Cl=function(e,t,n,r,i){return new Yqe(e,t,n,P(r,161).a,P(i,161).a)},Q.Dl=function(e,t,n,r,i,a){return new aBe(e,t,n,P(r,161).a,P(i,161).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/5`,1372),q(1373,rW,{},nce),Q.Cl=function(e,t,n,r,i){return new yUe(e,t,n,P(r,17).a,P(i,17).a)},Q.Dl=function(e,t,n,r,i,a){return new oBe(e,t,n,P(r,17).a,P(i,17).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/6`,1373),q(1374,rW,{},rce),Q.Cl=function(e,t,n,r,i){return new qqe(e,t,n,P(r,168).a,P(i,168).a)},Q.Dl=function(e,t,n,r,i,a){return new sBe(e,t,n,P(r,168).a,P(i,168).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/7`,1374),q(1375,rW,{},ice),Q.Cl=function(e,t,n,r,i){return new Jqe(e,t,n,P(r,191).a,P(i,191).a)},Q.Dl=function(e,t,n,r,i,a){return new cBe(e,t,n,P(r,191).a,P(i,191).a,a)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleData/NotificationCreator/8`,1375),q(1353,574,{},gIe),Q.Bl=function(e){if(!this.a.fk(e))throw E(new Pi(tW+$w(e)+nW+this.a+`'`))},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataDynamic`,1353),q(1354,574,{},kNe),Q.Bl=function(e){},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataStatic`,1354),q(785,574,{}),Q.Bk=function(e,t,n){return t.li(n)!=null},Q.Ck=function(e,t,n,r){var i,a;e.vh()&&e.wh()?(i=!0,a=t.li(n),a==null?(i=!1,a=this.b):A(a)===A(s9)&&(a=null),r==null?this.c==null?t.mi(n,s9):(t.mi(n,null),r=this.b):(this.Bl(r),t.mi(n,r)),AC(e,this.d.Dl(e,1,this.e,a,r,!i))):r==null?this.c==null?t.mi(n,s9):t.mi(n,null):(this.Bl(r),t.mi(n,r))},Q.Ek=function(e,t,n){var r,i;e.vh()&&e.wh()?(r=!0,i=t.li(n),i==null?(r=!1,i=this.b):A(i)===A(s9)&&(i=null),t.ni(n),AC(e,this.d.Dl(e,2,this.e,i,this.b,r))):t.ni(n)},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettable`,785),q(1355,785,{},_Ie),Q.Bl=function(e){if(!this.a.fk(e))throw E(new Pi(tW+$w(e)+nW+this.a+`'`))},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettableDynamic`,1355),q(1356,785,{},ANe),Q.Bl=function(e){},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleDataUnsettableStatic`,1356),q(410,512,{},Bp),Q.yk=function(e,t,n,r,i){var a,o,s,c,l=t.li(n);if(this.tk()&&A(l)===A(s9))return null;if(this.bl()&&r&&l!=null){if(s=P(l,54),s.Vh()&&(c=pT(e,s),s!=c)){if(!QM(this.a,c))throw E(new Pi(tW+$w(c)+nW+this.a+`'`));t.mi(n,l=c),this.al()&&(a=P(c,54),o=s.Th(e,this.b?eD(s.Dh(),this.b):-1-eD(e.Dh(),this.e),null,null),!a.Ph()&&(o=a.Rh(e,this.b?eD(a.Dh(),this.b):-1-eD(e.Dh(),this.e),null,o)),o&&o.oj()),e.vh()&&e.wh()&&AC(e,new Cm(e,9,this.e,s,c))}return l}return l},Q.zk=function(e,t,n,r,i){var a,o=t.li(n);return A(o)===A(s9)&&(o=null),t.mi(n,r),this.Mj()?A(o)!==A(r)&&o!=null&&(a=P(o,54),i=a.Th(e,eD(a.Dh(),this.b),null,i)):this.al()&&o!=null&&(i=P(o,54).Th(e,-1-eD(e.Dh(),this.e),null,i)),e.vh()&&e.wh()&&(!i&&(i=new Pa(4)),i.nj(new Cm(e,1,this.e,o,r))),i},Q.Ak=function(e,t,n,r,i){var a=t.li(n);return A(a)===A(s9)&&(a=null),t.ni(n),e.vh()&&e.wh()&&(!i&&(i=new Pa(4)),this.tk()?i.nj(new Cm(e,2,this.e,a,null)):i.nj(new Cm(e,1,this.e,a,null))),i},Q.Bk=function(e,t,n){return t.li(n)!=null},Q.Ck=function(e,t,n,r){var i,a,o,s,c;if(r!=null&&!QM(this.a,r))throw E(new Pi(tW+(j(r,58)?o5e(P(r,58).Dh()):yx($w(r)))+nW+this.a+`'`));c=t.li(n),s=c!=null,this.tk()&&A(c)===A(s9)&&(c=null),o=null,this.Mj()?A(c)!==A(r)&&(c!=null&&(i=P(c,54),o=i.Th(e,eD(i.Dh(),this.b),null,o)),r!=null&&(i=P(r,54),o=i.Rh(e,eD(i.Dh(),this.b),null,o))):this.al()&&A(c)!==A(r)&&(c!=null&&(o=P(c,54).Th(e,-1-eD(e.Dh(),this.e),null,o)),r!=null&&(o=P(r,54).Rh(e,-1-eD(e.Dh(),this.e),null,o))),r==null&&this.tk()?t.mi(n,s9):t.mi(n,r),e.vh()&&e.wh()?(a=new Jg(e,1,this.e,c,r,this.tk()&&!s),o?(o.nj(a),o.oj()):AC(e,a)):o&&o.oj()},Q.Ek=function(e,t,n){var r,i,a,o,s=t.li(n);o=s!=null,this.tk()&&A(s)===A(s9)&&(s=null),a=null,s!=null&&(this.Mj()?(r=P(s,54),a=r.Th(e,eD(r.Dh(),this.b),null,a)):this.al()&&(a=P(s,54).Th(e,-1-eD(e.Dh(),this.e),null,a))),t.ni(n),e.vh()&&e.wh()?(i=new Jg(e,this.tk()?2:1,this.e,s,null,o),a?(a.nj(i),a.oj()):AC(e,i)):a&&a.oj()},Q.Mj=function(){return!1},Q.al=function(){return!1},Q.bl=function(){return!1},Q.tk=function(){return!1},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObject`,410),q(575,410,{},Ed),Q.al=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainment`,575),q(1359,575,{},JEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentResolving`,1359),q(787,575,{},YEe),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentUnsettable`,787),q(1361,787,{},ZEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentUnsettableResolving`,1361),q(650,575,{},Gf),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverse`,650),q(1360,650,{},hje),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseResolving`,1360),q(788,650,{},gje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseUnsettable`,788),q(1362,788,{},_je),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectContainmentWithInverseUnsettableResolving`,1362),q(651,410,{},XEe),Q.bl=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolving`,651),q(1363,651,{},QEe),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingUnsettable`,1363),q(789,651,{},pje),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingWithInverse`,789),q(1364,789,{},vje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectResolvingWithInverseUnsettable`,1364),q(1357,410,{},$Ee),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectUnsettable`,1357),q(786,410,{},mje),Q.Mj=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectWithInverse`,786),q(1358,786,{},yje),Q.tk=function(){return!0},L(KH,`EStructuralFeatureImpl/InternalSettingDelegateSingleEObjectWithInverseUnsettable`,1358),q(790,576,eW,Mh),Q.yl=function(e){return new Mh(this.a,this.c,e)},Q.md=function(){return this.b},Q.zl=function(e,t,n){return UWe(this,e,this.b,n)},Q.Al=function(e,t,n){return WWe(this,e,this.b,n)},L(KH,`EStructuralFeatureImpl/InverseUpdatingFeatureMapEntry`,790),q(1365,1,LU,Ghe),Q.Fk=function(e){return this.a},Q.Qj=function(){return j(this.a,97)?P(this.a,97).Qj():!this.a.dc()},Q.Wb=function(e){this.a.$b(),this.a.Gc(P(e,15))},Q.Gk=function(){j(this.a,97)?P(this.a,97).Gk():this.a.$b()},L(KH,`EStructuralFeatureImpl/SettingMany`,1365),q(1366,576,eW,gHe),Q.xl=function(e){return new Gd((UN(),k9),this.b.ri(this.a,e))},Q.md=function(){return null},Q.zl=function(e,t,n){return n},Q.Al=function(e,t,n){return n},L(KH,`EStructuralFeatureImpl/SimpleContentFeatureMapEntry`,1366),q(652,576,eW,Gd),Q.xl=function(e){return new Gd(this.c,e)},Q.md=function(){return this.a},Q.zl=function(e,t,n){return n},Q.Al=function(e,t,n){return n},L(KH,`EStructuralFeatureImpl/SimpleFeatureMapEntry`,652),q(403,506,SU,ln),Q.aj=function(e){return V(D7,FP,29,e,0,1)},Q.Yi=function(){return!1},L(KH,`ESuperAdapter/1`,403),q(457,448,{110:1,94:1,93:1,155:1,197:1,58:1,114:1,850:1,54:1,99:1,158:1,457:1,119:1,120:1},un),Q.Lh=function(e,t,n){var r;switch(e){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),this.Ab;case 1:return this.zb;case 2:return!this.a&&(this.a=new Vp(this,j7,this)),this.a}return xb(this,e-bh((CP(),e9)),_x((r=P(NC(this,16),29),r||e9),e),t,n)},Q.Uh=function(e,t,n){var r,i;switch(t){case 0:return!this.Ab&&(this.Ab=new F(S7,this,0,3)),AO(this.Ab,e,n);case 2:return!this.a&&(this.a=new Vp(this,j7,this)),AO(this.a,e,n)}return i=P(_x((r=P(NC(this,16),29),r||(CP(),e9)),t),69),i.wk().Ak(this,WD(this),t-bh((CP(),e9)),e,n)},Q.Wh=function(e){var t;switch(e){case 0:return!!this.Ab&&this.Ab.i!=0;case 1:return this.zb!=null;case 2:return!!this.a&&this.a.i!=0}return Hv(this,e-bh((CP(),e9)),_x((t=P(NC(this,16),29),t||e9),e))},Q.bi=function(e,t){var n;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab),!this.Ab&&(this.Ab=new F(S7,this,0,3)),th(this.Ab,P(t,16));return;case 1:GS(this,kd(t));return;case 2:!this.a&&(this.a=new Vp(this,j7,this)),RN(this.a),!this.a&&(this.a=new Vp(this,j7,this)),th(this.a,P(t,16));return}LE(this,e-bh((CP(),e9)),_x((n=P(NC(this,16),29),n||e9),e),t)},Q.ii=function(){return CP(),e9},Q.ki=function(e){var t;switch(e){case 0:!this.Ab&&(this.Ab=new F(S7,this,0,3)),RN(this.Ab);return;case 1:GS(this,null);return;case 2:!this.a&&(this.a=new Vp(this,j7,this)),RN(this.a);return}PT(this,e-bh((CP(),e9)),_x((t=P(NC(this,16),29),t||e9),e))},L(KH,`ETypeParameterImpl`,457),q(458,83,JU,Vp),Q.Nj=function(e,t){return g7e(this,P(e,89),t)},Q.Oj=function(e,t){return _7e(this,P(e,89),t)},L(KH,`ETypeParameterImpl/1`,458),q(647,45,CI,ui),Q.ec=function(){return new Sr(this)},L(KH,`ETypeParameterImpl/2`,647),q(570,GP,KP,Sr),Q.Fc=function(e){return mOe(this,P(e,89))},Q.Gc=function(e){var t,n,r=!1;for(n=e.Kc();n.Ob();)t=P(n.Pb(),89),Qh(this.a,t,``)??(r=!0);return r},Q.$b=function(){Pm(this.a)},Q.Hc=function(e){return km(this.a,e)},Q.Kc=function(){var e;return e=new EC(new Fn(this.a).a),new Cr(e)},Q.Mc=function(e){return iWe(this,e)},Q.gc=function(){return ho(this.a)},L(KH,`ETypeParameterImpl/2/1`,570),q(571,1,VP,Cr),Q.Nb=function(e){Om(this,e)},Q.Pb=function(){return P(MS(this.a).ld(),89)},Q.Ob=function(){return this.a.b},Q.Qb=function(){aKe(this.a)},L(KH,`ETypeParameterImpl/2/1/1`,571),q(1329,45,CI,h_e),Q._b=function(e){return rl(e)?e_(this,e):!!Kp(this.f,e)},Q.xc=function(e){var t=rl(e)?v_(this,e):nl(Kp(this.f,e)),n;return j(t,851)?(n=P(t,851),t=n.Kk(),Qh(this,P(e,241),t),t):t??(e==null?(Zo(),yHt):null)},L(KH,`EValidatorRegistryImpl`,1329),q(1349,720,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,2040:1,54:1,99:1,158:1,119:1,120:1},ace),Q.ri=function(e,t){switch(e.hk()){case 21:case 22:case 23:case 24:case 26:case 31:case 32:case 37:case 38:case 39:case 40:case 43:case 44:case 48:case 49:case 20:return t==null?null:PE(t);case 25:return Cqe(t);case 27:return BGe(t);case 28:return VGe(t);case 29:return t==null?null:Nwe(t7[0],P(t,206));case 41:return t==null?``:Ha(P(t,297));case 42:return PE(t);case 50:return kd(t);default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g;switch(e.G==-1&&(e.G=(f=Mx(e),f?NO(f.vi(),e):-1)),e.G){case 0:return n=new oi,n;case 1:return t=new Vse,t;case 2:return r=new Que,r;case 4:return i=new Ur,i;case 5:return a=new m_e,a;case 6:return o=new wge,o;case 7:return s=new $ue,s;case 10:return l=new sn,l;case 11:return u=new si,u;case 12:return d=new IIe,d;case 13:return p=new li,p;case 14:return m=new uDe,m;case 17:return h=new Yse,h;case 18:return c=new kr,c;case 19:return g=new un,g;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){switch(e.hk()){case 20:return t==null?null:new xye(t);case 21:return t==null?null:new ru(t);case 23:case 22:return t==null?null:X0e(t);case 26:case 24:return t==null?null:Gb(GM(t,-128,127)<<24>>24);case 25:return Rit(t);case 27:return G3e(t);case 28:return K3e(t);case 29:return q7e(t);case 32:case 31:return t==null?null:OA(t);case 38:case 37:return t==null?null:new jge(t);case 40:case 39:return t==null?null:G(GM(t,xF,AP));case 41:return null;case 42:return null;case 44:case 43:return t==null?null:JD(aP(t));case 49:case 48:return t==null?null:xT(GM(t,aW,32767)<<16>>16);case 50:return t;default:throw E(new Fi(YH+e.xe()+XH))}},L(KH,`EcoreFactoryImpl`,1349),q(560,184,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,2038:1,54:1,99:1,158:1,184:1,560:1,119:1,120:1,690:1},MFe),Q.gb=!1,Q.hb=!1;var fHt,pHt=!1;L(KH,`EcorePackageImpl`,560),q(1234,1,{851:1},oce),Q.Kk=function(){return xTe(),bHt},L(KH,`EcorePackageImpl/1`,1234),q(1243,1,lW,sce),Q.fk=function(e){return j(e,155)},Q.gk=function(e){return V(G5,FP,155,e,0,1)},L(KH,`EcorePackageImpl/10`,1243),q(1244,1,lW,cce),Q.fk=function(e){return j(e,197)},Q.gk=function(e){return V(q5,FP,197,e,0,1)},L(KH,`EcorePackageImpl/11`,1244),q(1245,1,lW,lce),Q.fk=function(e){return j(e,58)},Q.gk=function(e){return V(L5,FP,58,e,0,1)},L(KH,`EcorePackageImpl/12`,1245),q(1246,1,lW,uce),Q.fk=function(e){return j(e,411)},Q.gk=function(e){return V(M7,Cwt,62,e,0,1)},L(KH,`EcorePackageImpl/13`,1246),q(1247,1,lW,dce),Q.fk=function(e){return j(e,241)},Q.gk=function(e){return V(J5,FP,241,e,0,1)},L(KH,`EcorePackageImpl/14`,1247),q(1248,1,lW,fce),Q.fk=function(e){return j(e,518)},Q.gk=function(e){return V(P7,FP,2116,e,0,1)},L(KH,`EcorePackageImpl/15`,1248),q(1249,1,lW,pce),Q.fk=function(e){return j(e,102)},Q.gk=function(e){return V(F7,qU,19,e,0,1)},L(KH,`EcorePackageImpl/16`,1249),q(1250,1,lW,mce),Q.fk=function(e){return j(e,179)},Q.gk=function(e){return V(w7,qU,179,e,0,1)},L(KH,`EcorePackageImpl/17`,1250),q(1251,1,lW,hce),Q.fk=function(e){return j(e,481)},Q.gk=function(e){return V(C7,FP,481,e,0,1)},L(KH,`EcorePackageImpl/18`,1251),q(1252,1,lW,gce),Q.fk=function(e){return j(e,561)},Q.gk=function(e){return V(o9,owt,561,e,0,1)},L(KH,`EcorePackageImpl/19`,1252),q(1235,1,lW,_ce),Q.fk=function(e){return j(e,331)},Q.gk=function(e){return V(T7,qU,35,e,0,1)},L(KH,`EcorePackageImpl/2`,1235),q(1253,1,lW,vce),Q.fk=function(e){return j(e,248)},Q.gk=function(e){return V(j7,Twt,89,e,0,1)},L(KH,`EcorePackageImpl/20`,1253),q(1254,1,lW,yce),Q.fk=function(e){return j(e,457)},Q.gk=function(e){return V(I7,FP,850,e,0,1)},L(KH,`EcorePackageImpl/21`,1254),q(1255,1,lW,bce),Q.fk=function(e){return il(e)},Q.gk=function(e){return V(bG,X,485,e,8,1)},L(KH,`EcorePackageImpl/22`,1255),q(1256,1,lW,xce),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(KH,`EcorePackageImpl/23`,1256),q(1257,1,lW,Sce),Q.fk=function(e){return j(e,222)},Q.gk=function(e){return V(xG,X,222,e,0,1)},L(KH,`EcorePackageImpl/24`,1257),q(1258,1,lW,Cce),Q.fk=function(e){return j(e,180)},Q.gk=function(e){return V(CG,X,180,e,0,1)},L(KH,`EcorePackageImpl/25`,1258),q(1259,1,lW,wce),Q.fk=function(e){return j(e,206)},Q.gk=function(e){return V(fG,X,206,e,0,1)},L(KH,`EcorePackageImpl/26`,1259),q(1260,1,lW,Tce),Q.fk=function(e){return!1},Q.gk=function(e){return V(dUt,FP,2215,e,0,1)},L(KH,`EcorePackageImpl/27`,1260),q(1261,1,lW,Ece),Q.fk=function(e){return al(e)},Q.gk=function(e){return V(TG,X,345,e,7,1)},L(KH,`EcorePackageImpl/28`,1261),q(1262,1,lW,Dce),Q.fk=function(e){return j(e,61)},Q.gk=function(e){return V(xVt,BL,61,e,0,1)},L(KH,`EcorePackageImpl/29`,1262),q(1236,1,lW,Oce),Q.fk=function(e){return j(e,519)},Q.gk=function(e){return V(S7,{3:1,4:1,5:1,2033:1},598,e,0,1)},L(KH,`EcorePackageImpl/3`,1236),q(1263,1,lW,kce),Q.fk=function(e){return j(e,582)},Q.gk=function(e){return V(DVt,FP,2039,e,0,1)},L(KH,`EcorePackageImpl/30`,1263),q(1264,1,lW,Ace),Q.fk=function(e){return j(e,160)},Q.gk=function(e){return V(vHt,BL,160,e,0,1)},L(KH,`EcorePackageImpl/31`,1264),q(1265,1,lW,jce),Q.fk=function(e){return j(e,76)},Q.gk=function(e){return V(t9,Iwt,76,e,0,1)},L(KH,`EcorePackageImpl/32`,1265),q(1266,1,lW,Mce),Q.fk=function(e){return j(e,161)},Q.gk=function(e){return V(EG,X,161,e,0,1)},L(KH,`EcorePackageImpl/33`,1266),q(1267,1,lW,Nce),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(KH,`EcorePackageImpl/34`,1267),q(1268,1,lW,Pce),Q.fk=function(e){return j(e,297)},Q.gk=function(e){return V(DTt,FP,297,e,0,1)},L(KH,`EcorePackageImpl/35`,1268),q(1269,1,lW,Fce),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(KH,`EcorePackageImpl/36`,1269),q(1270,1,lW,Ice),Q.fk=function(e){return j(e,85)},Q.gk=function(e){return V(kTt,FP,85,e,0,1)},L(KH,`EcorePackageImpl/37`,1270),q(1271,1,lW,Lce),Q.fk=function(e){return j(e,599)},Q.gk=function(e){return V(mHt,FP,599,e,0,1)},L(KH,`EcorePackageImpl/38`,1271),q(1272,1,lW,Rce),Q.fk=function(e){return!1},Q.gk=function(e){return V(fUt,FP,2216,e,0,1)},L(KH,`EcorePackageImpl/39`,1272),q(1237,1,lW,zce),Q.fk=function(e){return j(e,90)},Q.gk=function(e){return V(D7,FP,29,e,0,1)},L(KH,`EcorePackageImpl/4`,1237),q(1273,1,lW,Bce),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(KH,`EcorePackageImpl/40`,1273),q(1274,1,lW,Vce),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(KH,`EcorePackageImpl/41`,1274),q(1275,1,lW,Hce),Q.fk=function(e){return j(e,596)},Q.gk=function(e){return V(CVt,FP,596,e,0,1)},L(KH,`EcorePackageImpl/42`,1275),q(1276,1,lW,Uce),Q.fk=function(e){return!1},Q.gk=function(e){return V(pUt,X,2217,e,0,1)},L(KH,`EcorePackageImpl/43`,1276),q(1277,1,lW,Wce),Q.fk=function(e){return j(e,44)},Q.gk=function(e){return V(YW,oF,44,e,0,1)},L(KH,`EcorePackageImpl/44`,1277),q(1238,1,lW,Gce),Q.fk=function(e){return j(e,142)},Q.gk=function(e){return V(E7,FP,142,e,0,1)},L(KH,`EcorePackageImpl/5`,1238),q(1239,1,lW,Kce),Q.fk=function(e){return j(e,156)},Q.gk=function(e){return V(O7,FP,156,e,0,1)},L(KH,`EcorePackageImpl/6`,1239),q(1240,1,lW,qce),Q.fk=function(e){return j(e,469)},Q.gk=function(e){return V(k7,FP,685,e,0,1)},L(KH,`EcorePackageImpl/7`,1240),q(1241,1,lW,Jce),Q.fk=function(e){return j(e,582)},Q.gk=function(e){return V(A7,FP,694,e,0,1)},L(KH,`EcorePackageImpl/8`,1241),q(1242,1,lW,Yce),Q.fk=function(e){return j(e,480)},Q.gk=function(e){return V(K5,FP,480,e,0,1)},L(KH,`EcorePackageImpl/9`,1242),q(1038,2080,iwt,K_e),Q.Mi=function(e,t){B$e(this,P(t,424))},Q.Qi=function(e,t){ntt(this,e,P(t,424))},L(KH,`MinimalEObjectImpl/1ArrayDelegatingAdapterList`,1038),q(1039,152,NU,cFe),Q.jj=function(){return this.a.a},L(KH,`MinimalEObjectImpl/1ArrayDelegatingAdapterList/1`,1039),q(1067,1066,{},uwe),L(`org.eclipse.emf.ecore.plugin`,`EcorePlugin`,1067);var mHt=gp(Lwt,`Resource`);q(799,1524,Rwt),Q.Hl=function(e){},Q.Il=function(e){},Q.El=function(){return!this.a&&(this.a=new wr(this)),this.a},Q.Fl=function(e){var t,n,r=e.length,i,a;if(r>0){if(sv(0,e.length),e.charCodeAt(0)==47){for(a=new Hy(4),i=1,t=1;t0&&(e=(Zy(0,n,e.length),e.substr(0,n))))}return hnt(this,e)},Q.Gl=function(){return this.c},Q.Ib=function(){var e;return Ha(this.Rm)+`@`+(e=US(this)>>>0,e.toString(16))+` uri='`+this.d+`'`},Q.b=!1,L(uW,`ResourceImpl`,799),q(1525,799,Rwt,qhe),L(uW,`BinaryResourceImpl`,1525),q(1190,708,CU),Q.bj=function(e){return j(e,58)?rLe(this,P(e,58)):j(e,599)?new Lu(P(e,599).El()):A(e)===A(this.f)?P(e,16).Kc():(Nd(),_7.a)},Q.Ob=function(){return ert(this)},Q.a=!1,L(IU,`EcoreUtil/ContentTreeIterator`,1190),q(1526,1190,CU,sPe),Q.bj=function(e){return A(e)===A(this.f)?P(e,15).Kc():new aVe(P(e,58))},L(uW,`ResourceImpl/5`,1526),q(658,2092,wwt,wr),Q.Hc=function(e){return this.i<=4?Uk(this,e):j(e,54)&&P(e,54).Jh()==this.a},Q.Mi=function(e,t){e==this.i-1&&(this.a.b||(this.a.b=!0))},Q.Oi=function(e,t){e==0?this.a.b||(this.a.b=!0):Xy(this,e,t)},Q.Qi=function(e,t){},Q.Ri=function(e,t,n){},Q.Lj=function(){return 2},Q.jj=function(){return this.a},Q.Mj=function(){return!0},Q.Nj=function(e,t){return t=P(e,54).fi(this.a,t),t},Q.Oj=function(e,t){return P(e,54).fi(null,t)},Q.Pj=function(){return!1},Q.Si=function(){return!0},Q.aj=function(e){return V(L5,FP,58,e,0,1)},Q.Yi=function(){return!1},L(uW,`ResourceImpl/ContentsEList`,658),q(970,2062,gF,Jhe),Q.fd=function(e){return this.a.Ki(e)},Q.gc=function(){return this.a.gc()},L(IU,`AbstractSequentialInternalEList/1`,970);var hHt,gHt,l9,_Ht;q(634,1,{},tMe);var u9,d9;L(IU,`BasicExtendedMetaData`,634),q(1181,1,{},QSe),Q.Jl=function(){return null},Q.Kl=function(){return this.a==-2&&sfe(this,F7e(this.d,this.b)),this.a},Q.Ll=function(){return null},Q.Ml=function(){return Vg(),Vg(),QG},Q.xe=function(){return this.c==SW&&cfe(this,f2e(this.d,this.b)),this.c},Q.Nl=function(){return 0},Q.a=-2,Q.c=SW,L(IU,`BasicExtendedMetaData/EClassExtendedMetaDataImpl`,1181),q(1182,1,{},dBe),Q.Jl=function(){return this.a==(By(),u9)&&dfe(this,olt(this.f,this.b)),this.a},Q.Kl=function(){return 0},Q.Ll=function(){return this.c==(By(),u9)&&lfe(this,slt(this.f,this.b)),this.c},Q.Ml=function(){return!this.d&&pfe(this,rft(this.f,this.b)),this.d},Q.xe=function(){return this.e==SW&&hfe(this,f2e(this.f,this.b)),this.e},Q.Nl=function(){return this.g==-2&&_fe(this,R5e(this.f,this.b)),this.g},Q.e=SW,Q.g=-2,L(IU,`BasicExtendedMetaData/EDataTypeExtendedMetaDataImpl`,1182),q(1180,1,{},$Se),Q.b=!1,Q.c=!1,L(IU,`BasicExtendedMetaData/EPackageExtendedMetaDataImpl`,1180),q(1183,1,{},fBe),Q.c=-2,Q.e=SW,Q.f=SW,L(IU,`BasicExtendedMetaData/EStructuralFeatureExtendedMetaDataImpl`,1183),q(593,632,JU,ip),Q.Lj=function(){return this.c},Q.ol=function(){return!1},Q.Wi=function(e,t){return t},Q.c=0,L(IU,`EDataTypeEList`,593);var vHt=gp(IU,`FeatureMap`);q(78,593,{3:1,4:1,20:1,31:1,56:1,16:1,15:1,59:1,70:1,66:1,61:1,79:1,160:1,220:1,2036:1,71:1,97:1},DC),Q.bd=function(e,t){got(this,e,P(t,76))},Q.Fc=function(e){return xat(this,P(e,76))},Q.Hi=function(e){UPe(this,P(e,76))},Q.Nj=function(e,t){return qOe(this,P(e,76),t)},Q.Oj=function(e,t){return JOe(this,P(e,76),t)},Q.Ti=function(e,t){return Dut(this,e,t)},Q.Wi=function(e,t){return Umt(this,e,P(t,76))},Q.hd=function(e,t){return xst(this,e,P(t,76))},Q.Uj=function(e,t){return YOe(this,P(e,76),t)},Q.Vj=function(e,t){return XOe(this,P(e,76),t)},Q.Wj=function(e,t,n){return f5e(this,P(e,76),P(t,76),n)},Q.Zi=function(e,t){return aA(this,e,P(t,76))},Q.Ol=function(e,t){return cut(this,e,t)},Q.cd=function(e,t){var n,r,i,a,o,s,c,l=new kx(t.gc()),u;for(i=t.Kc();i.Ob();)if(r=P(i.Pb(),76),a=r.Lk(),aM(this.e,a))(!a.Si()||!Kv(this,a,r.md())&&!Uk(l,r))&&tb(l,r);else{for(u=nM(this.e.Dh(),a),n=P(this.g,124),o=!0,s=0;s=0;)if(t=e[this.c],this.k.am(t.Lk()))return this.j=this.f?t:t.md(),this.i=-2,!0;return this.i=-1,this.g=-1,!1},L(IU,`BasicFeatureMap/FeatureEIterator`,420),q(676,420,YP,Dl),Q.ul=function(){return!0},L(IU,`BasicFeatureMap/ResolvingFeatureEIterator`,676),q(968,496,QU,zwe),Q.pj=function(){return this},L(IU,`EContentsEList/1`,968),q(969,496,QU,mCe),Q.ul=function(){return!1},L(IU,`EContentsEList/2`,969),q(967,287,$U,Bwe),Q.wl=function(e){},Q.Ob=function(){return!1},Q.Sb=function(){return!1},L(IU,`EContentsEList/FeatureIteratorImpl/1`,967),q(840,593,JU,uTe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EDataTypeEList/Unsettable`,840),q(1958,593,JU,dTe),Q.Si=function(){return!0},L(IU,`EDataTypeUniqueEList`,1958),q(1959,840,JU,fTe),Q.Si=function(){return!0},L(IU,`EDataTypeUniqueEList/Unsettable`,1959),q(147,83,JU,Nu),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentEList/Resolving`,147),q(1184,555,JU,pTe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentEList/Unsettable/Resolving`,1184),q(766,14,JU,rf),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectContainmentWithInverseEList/Unsettable`,766),q(1222,766,JU,yOe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectContainmentWithInverseEList/Unsettable/Resolving`,1222),q(757,505,JU,mTe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectEList/Unsettable`,757),q(338,505,JU,Pu),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectResolvingEList`,338),q(1844,757,JU,hTe),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectResolvingEList/Unsettable`,1844),q(1527,1,{},Xce);var yHt;L(IU,`EObjectValidator`,1527),q(559,505,JU,wm),Q.il=function(){return this.d},Q.jl=function(){return this.b},Q.Mj=function(){return!0},Q.ml=function(){return!0},Q.b=0,L(IU,`EObjectWithInverseEList`,559),q(1225,559,JU,bOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseEList/ManyInverse`,1225),q(635,559,JU,af),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EObjectWithInverseEList/Unsettable`,635),q(1224,635,JU,xOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseEList/Unsettable/ManyInverse`,1224),q(767,559,JU,of),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectWithInverseResolvingEList`,767),q(32,767,JU,cf),Q.ll=function(){return!0},L(IU,`EObjectWithInverseResolvingEList/ManyInverse`,32),q(768,635,JU,sf),Q.nl=function(){return!0},Q.Wi=function(e,t){return vj(this,e,P(t,58))},L(IU,`EObjectWithInverseResolvingEList/Unsettable`,768),q(1223,768,JU,SOe),Q.ll=function(){return!0},L(IU,`EObjectWithInverseResolvingEList/Unsettable/ManyInverse`,1223),q(1185,632,JU),Q.Li=function(){return!(this.b&1792)},Q.Ni=function(){this.b|=1},Q.kl=function(){return!!(this.b&4)},Q.Mj=function(){return!!(this.b&40)},Q.ll=function(){return!!(this.b&16)},Q.ml=function(){return!!(this.b&8)},Q.nl=function(){return(this.b&zU)!=0},Q.al=function(){return!!(this.b&32)},Q.ol=function(){return(this.b&pF)!=0},Q.fk=function(e){return this.d?HVe(this.d,e):this.Lk().Hk().fk(e)},Q.Qj=function(){return this.b&2?!!(this.b&1):this.i!=0},Q.Si=function(){return!!(this.b&128)},Q.Gk=function(){var e;RN(this),this.b&2&&(Gl(this.e)?(e=!!(this.b&1),this.b&=-2,Kr(this,new vy(this.e,2,eD(this.e.Dh(),this.Lk()),e,!1))):this.b&=-2)},Q.Yi=function(){return!(this.b&1536)},Q.b=0,L(IU,`EcoreEList/Generic`,1185),q(1186,1185,JU,BIe),Q.Lk=function(){return this.a},L(IU,`EcoreEList/Dynamic`,1186),q(765,66,SU,Yhe),Q.aj=function(e){return tS(this.a.a,e)},L(IU,`EcoreEMap/1`,765),q(764,83,JU,dPe),Q.Mi=function(e,t){JO(this.b,P(t,136))},Q.Oi=function(e,t){sXe(this.b)},Q.Pi=function(e,t,n){var r;++(r=this.b,P(t,136),r).e},Q.Qi=function(e,t){$T(this.b,P(t,136))},Q.Ri=function(e,t,n){$T(this.b,P(n,136)),A(n)===A(t)&&P(n,136).Ci(swe(P(t,136).ld())),JO(this.b,P(t,136))},L(IU,`EcoreEMap/DelegateEObjectContainmentEList`,764),q(1220,141,bwt,TJe),L(IU,`EcoreEMap/Unsettable`,1220),q(1221,764,JU,COe),Q.Ni=function(){this.a=!0},Q.Qj=function(){return this.a},Q.Gk=function(){var e;RN(this),Gl(this.e)?(e=this.a,this.a=!1,AC(this.e,new vy(this.e,2,this.c,e,!1))):this.a=!1},Q.a=!1,L(IU,`EcoreEMap/Unsettable/UnsettableDelegateEObjectContainmentEList`,1221),q(1189,215,CI,GPe),Q.a=!1,Q.b=!1,L(IU,`EcoreUtil/Copier`,1189),q(759,1,VP,aVe),Q.Nb=function(e){Om(this,e)},Q.Ob=function(){return M0e(this)},Q.Pb=function(){var e;return M0e(this),e=this.b,this.b=null,e},Q.Qb=function(){this.a.Qb()},L(IU,`EcoreUtil/ProperContentIterator`,759),q(1528,1527,{},ede);var bHt;L(IU,`EcoreValidator`,1528);var xHt;gp(IU,`FeatureMapUtil/Validator`),q(1295,1,{2041:1},Zce),Q.am=function(e){return!0},L(IU,`FeatureMapUtil/1`,1295),q(773,1,{2041:1},Egt),Q.am=function(e){var t;return this.c==e||(t=Od(xh(this.a,e)),t==null?_lt(this,e)?(PUe(this.a,e,(rd(),yG)),!0):(PUe(this.a,e,(rd(),vG)),!1):t==(rd(),yG))},Q.e=!1;var f9;L(IU,`FeatureMapUtil/BasicValidator`,773),q(774,45,CI,Rwe),L(IU,`FeatureMapUtil/BasicValidator/Cache`,774),q(509,56,{20:1,31:1,56:1,16:1,15:1,61:1,79:1,71:1,97:1},Qc),Q.bd=function(e,t){Mst(this.c,this.b,e,t)},Q.Fc=function(e){return cut(this.c,this.b,e)},Q.cd=function(e,t){return vpt(this.c,this.b,e,t)},Q.Gc=function(e){return Su(this,e)},Q.Gi=function(e,t){$Ke(this.c,this.b,e,t)},Q.Wk=function(e,t){return plt(this.c,this.b,e,t)},Q.$i=function(e){return CN(this.c,this.b,e,!1)},Q.Ii=function(){return BCe(this.c,this.b)},Q.Ji=function(){return VCe(this.c,this.b)},Q.Ki=function(e){return GWe(this.c,this.b,e)},Q.Xk=function(e,t){return NDe(this,e,t)},Q.$b=function(){qr(this)},Q.Hc=function(e){return Kv(this.c,this.b,e)},Q.Ic=function(e){return MYe(this.c,this.b,e)},Q.Xb=function(e){return CN(this.c,this.b,e,!0)},Q.Fk=function(e){return this},Q.dd=function(e){return cHe(this.c,this.b,e)},Q.dc=function(){return tl(this)},Q.Qj=function(){return!lD(this.c,this.b)},Q.Kc=function(){return SKe(this.c,this.b)},Q.ed=function(){return CKe(this.c,this.b)},Q.fd=function(e){return p1e(this.c,this.b,e)},Q.Ti=function(e,t){return Ndt(this.c,this.b,e,t)},Q.Ui=function(e,t){XWe(this.c,this.b,e,t)},Q.gd=function(e){return _et(this.c,this.b,e)},Q.Mc=function(e){return eut(this.c,this.b,e)},Q.hd=function(e,t){return sft(this.c,this.b,e,t)},Q.Wb=function(e){_j(this.c,this.b),Su(this,P(e,15))},Q.gc=function(){return f1e(this.c,this.b)},Q.Pc=function(){return mBe(this.c,this.b)},Q.Qc=function(e){return lHe(this.c,this.b,e)},Q.Ib=function(){var e,t=new $i;for(t.a+=`[`,e=BCe(this.c,this.b);Uw(e);)pl(t,Uu(MO(e))),Uw(e)&&(t.a+=PP);return t.a+=`]`,t.a},Q.Gk=function(){_j(this.c,this.b)},L(IU,`FeatureMapUtil/FeatureEList`,509),q(644,39,NU,ey),Q.hj=function(e){return BT(this,e)},Q.mj=function(e){var t,n,r,i,a,o,s;switch(this.d){case 1:case 2:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.g=e.ij(),e.gj()==1&&(this.d=1),!0;break;case 3:if(i=e.gj(),i===3&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return this.d=5,t=new kx(2),tb(t,this.g),tb(t,e.ij()),this.g=t,!0;break;case 5:if(i=e.gj(),i===3&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return n=P(this.g,16),n.Fc(e.ij()),!0;break;case 4:switch(i=e.gj(),i){case 3:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.d=1,this.g=e.ij(),!0;break;case 4:if(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null))return this.d=6,s=new kx(2),tb(s,this.n),tb(s,e.kj()),this.n=s,o=U(O(q9,1),HF,28,15,[this.o,e.lj()]),this.g=o,!0}break;case 6:if(i=e.gj(),i===4&&(a=e.jj(),A(a)===A(this.c)&&BT(this,null)==e.hj(null)))return n=P(this.n,16),n.Fc(e.kj()),o=P(this.g,53),r=V(q9,HF,28,o.length+1,15,1),tN(o,0,r,0,o.length),r[o.length]=e.lj(),this.g=r,!0}return!1},L(IU,`FeatureMapUtil/FeatureENotificationImpl`,644),q(564,509,{20:1,31:1,56:1,16:1,15:1,61:1,79:1,160:1,220:1,2036:1,71:1,97:1},hp),Q.Ol=function(e,t){return cut(this.c,e,t)},Q.Pl=function(e,t,n){return plt(this.c,e,t,n)},Q.Ql=function(e,t,n){return Xft(this.c,e,t,n)},Q.Rl=function(){return this},Q.Sl=function(e,t){return SN(this.c,e,t)},Q.Tl=function(e){return P(CN(this.c,this.b,e,!1),76).Lk()},Q.Ul=function(e){return P(CN(this.c,this.b,e,!1),76).md()},Q.Vl=function(){return this.a},Q.Wl=function(e){return!lD(this.c,e)},Q.Xl=function(e,t){ON(this.c,e,t)},Q.Yl=function(e){return LJe(this.c,e)},Q.Zl=function(e){v3e(this.c,e)},L(IU,`FeatureMapUtil/FeatureFeatureMap`,564),q(1294,1,LU,ZSe),Q.Fk=function(e){return CN(this.b,this.a,-1,e)},Q.Qj=function(){return!lD(this.b,this.a)},Q.Wb=function(e){ON(this.b,this.a,e)},Q.Gk=function(){_j(this.b,this.a)},L(IU,`FeatureMapUtil/FeatureValue`,1294);var p9,m9,h9,g9,SHt,_9=gp(wW,`AnyType`);q(680,63,SF,Hi),L(wW,`InvalidDatatypeValueException`,680);var v9=gp(wW,Hwt),y9=gp(wW,Uwt),CHt=gp(wW,Wwt),wHt,b9,THt,x9,EHt,DHt,OHt,kHt,AHt,jHt,MHt,NHt,PHt,FHt,IHt,S9,LHt,C9,w9,RHt,T9,E9,D9,zHt,O9,k9;q(844,516,{110:1,94:1,93:1,58:1,54:1,99:1,857:1},g_e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.c&&(this.c=new DC(this,0)),this.c):(!this.c&&(this.c=new DC(this,0)),this.c.b);case 1:return n?(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)):(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Vl();case 2:return n?(!this.b&&(this.b=new DC(this,2)),this.b):(!this.b&&(this.b=new DC(this,2)),this.b.b)}return xb(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e),t,n)},Q.Uh=function(e,t,n){var r;switch(t){case 0:return!this.c&&(this.c=new DC(this,0)),zM(this.c,e,n);case 1:return(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),71)).Xk(e,n);case 2:return!this.b&&(this.b=new DC(this,2)),zM(this.b,e,n)}return r=P(_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),t),69),r.wk().Ak(this,Jb(this),t-bh(this.ii()),e,n)},Q.Wh=function(e){switch(e){case 0:return!!this.c&&this.c.i!=0;case 1:return!(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).dc();case 2:return!!this.b&&this.b.i!=0}return Hv(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e))},Q.bi=function(e,t){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),qm(this.c,t);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Wb(t);return;case 2:!this.b&&(this.b=new DC(this,2)),qm(this.b,t);return}LE(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e),t)},Q.ii=function(){return UN(),THt},Q.ki=function(e){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),RN(this.c);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).$b();return;case 2:!this.b&&(this.b=new DC(this,2)),RN(this.b);return}PT(this,e-bh(this.ii()),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():this.ii(),e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (mixed: `,fl(e,this.c),e.a+=`, anyAttribute: `,fl(e,this.b),e.a+=`)`,e.a)},L(TW,`AnyTypeImpl`,844),q(681,516,{110:1,94:1,93:1,58:1,54:1,99:1,2119:1,681:1},cle),Q.Lh=function(e,t,n){switch(e){case 0:return this.a;case 1:return this.b}return xb(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e),t,n)},Q.Wh=function(e){switch(e){case 0:return this.a!=null;case 1:return this.b!=null}return Hv(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e))},Q.bi=function(e,t){switch(e){case 0:bfe(this,kd(t));return;case 1:Sfe(this,kd(t));return}LE(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e),t)},Q.ii=function(){return UN(),S9},Q.ki=function(e){switch(e){case 0:this.a=null;return;case 1:this.b=null;return}PT(this,e-bh((UN(),S9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():S9,e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (data: `,pl(e,this.a),e.a+=`, target: `,pl(e,this.b),e.a+=`)`,e.a)},Q.a=null,Q.b=null,L(TW,`ProcessingInstructionImpl`,681),q(682,844,{110:1,94:1,93:1,58:1,54:1,99:1,857:1,2120:1,682:1},__e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.c&&(this.c=new DC(this,0)),this.c):(!this.c&&(this.c=new DC(this,0)),this.c.b);case 1:return n?(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)):(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Vl();case 2:return n?(!this.b&&(this.b=new DC(this,2)),this.b):(!this.b&&(this.b=new DC(this,2)),this.b.b);case 3:return!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0));case 4:return df(this.a,(!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))));case 5:return this.a}return xb(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e),t,n)},Q.Wh=function(e){switch(e){case 0:return!!this.c&&this.c.i!=0;case 1:return!(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).dc();case 2:return!!this.b&&this.b.i!=0;case 3:return!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))!=null;case 4:return df(this.a,(!this.c&&(this.c=new DC(this,0)),kd(SN(this.c,(UN(),w9),!0))))!=null;case 5:return!!this.a}return Hv(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e))},Q.bi=function(e,t){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),qm(this.c,t);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(P(Z_(this.c,(UN(),x9)),160),220)).Wb(t);return;case 2:!this.b&&(this.b=new DC(this,2)),qm(this.b,t);return;case 3:pBe(this,kd(t));return;case 4:pBe(this,uf(this.a,t));return;case 5:xfe(this,P(t,156));return}LE(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e),t)},Q.ii=function(){return UN(),C9},Q.ki=function(e){switch(e){case 0:!this.c&&(this.c=new DC(this,0)),RN(this.c);return;case 1:(!this.c&&(this.c=new DC(this,0)),P(Z_(this.c,(UN(),x9)),160)).$b();return;case 2:!this.b&&(this.b=new DC(this,2)),RN(this.b);return;case 3:!this.c&&(this.c=new DC(this,0)),ON(this.c,(UN(),w9),null);return;case 4:pBe(this,uf(this.a,null));return;case 5:this.a=null;return}PT(this,e-bh((UN(),C9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():C9,e))},L(TW,`SimpleAnyTypeImpl`,682),q(683,516,{110:1,94:1,93:1,58:1,54:1,99:1,2121:1,683:1},v_e),Q.Lh=function(e,t,n){switch(e){case 0:return n?(!this.a&&(this.a=new DC(this,0)),this.a):(!this.a&&(this.a=new DC(this,0)),this.a.b);case 1:return n?(!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),this.b):(!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),Jy(this.b));case 2:return n?(!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),this.c):(!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),Jy(this.c));case 3:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),E9));case 4:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),D9));case 5:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),O9));case 6:return!this.a&&(this.a=new DC(this,0)),Z_(this.a,(UN(),k9))}return xb(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e),t,n)},Q.Uh=function(e,t,n){var r;switch(t){case 0:return!this.a&&(this.a=new DC(this,0)),zM(this.a,e,n);case 1:return!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),gf(this.b,e,n);case 2:return!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),gf(this.c,e,n);case 5:return!this.a&&(this.a=new DC(this,0)),NDe(Z_(this.a,(UN(),O9)),e,n)}return r=P(_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():(UN(),T9),t),69),r.wk().Ak(this,Jb(this),t-bh((UN(),T9)),e,n)},Q.Wh=function(e){switch(e){case 0:return!!this.a&&this.a.i!=0;case 1:return!!this.b&&this.b.f!=0;case 2:return!!this.c&&this.c.f!=0;case 3:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),E9)));case 4:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),D9)));case 5:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),O9)));case 6:return!this.a&&(this.a=new DC(this,0)),!tl(Z_(this.a,(UN(),k9)))}return Hv(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e))},Q.bi=function(e,t){switch(e){case 0:!this.a&&(this.a=new DC(this,0)),qm(this.a,t);return;case 1:!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),bC(this.b,t);return;case 2:!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),bC(this.c,t);return;case 3:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),E9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,E9),P(t,16));return;case 4:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),D9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,D9),P(t,16));return;case 5:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),O9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,O9),P(t,16));return;case 6:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),k9))),!this.a&&(this.a=new DC(this,0)),Su(Z_(this.a,k9),P(t,16));return}LE(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e),t)},Q.ii=function(){return UN(),T9},Q.ki=function(e){switch(e){case 0:!this.a&&(this.a=new DC(this,0)),RN(this.a);return;case 1:!this.b&&(this.b=new lb((CP(),$7),o9,this,1)),this.b.c.$b();return;case 2:!this.c&&(this.c=new lb((CP(),$7),o9,this,2)),this.c.c.$b();return;case 3:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),E9)));return;case 4:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),D9)));return;case 5:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),O9)));return;case 6:!this.a&&(this.a=new DC(this,0)),qr(Z_(this.a,(UN(),k9)));return}PT(this,e-bh((UN(),T9)),_x(this.j&2?(!this.k&&(this.k=new fn),this.k).Nk():T9,e))},Q.Ib=function(){var e;return this.j&4?Aj(this):(e=new Wu(Aj(this)),e.a+=` (mixed: `,fl(e,this.a),e.a+=`)`,e.a)},L(TW,`XMLTypeDocumentRootImpl`,683),q(2028,720,{110:1,94:1,93:1,480:1,155:1,58:1,114:1,54:1,99:1,158:1,119:1,120:1,2122:1},Qce),Q.ri=function(e,t){switch(e.hk()){case 7:case 8:case 9:case 10:case 16:case 22:case 23:case 24:case 25:case 26:case 32:case 33:case 34:case 36:case 37:case 44:case 45:case 50:case 51:case 53:case 55:case 56:case 57:case 58:case 60:case 61:case 4:return t==null?null:PE(t);case 19:case 28:case 29:case 35:case 38:case 39:case 41:case 46:case 52:case 54:case 5:return kd(t);case 6:return rDe(P(t,195));case 12:case 47:case 49:case 11:return yht(this,e,t);case 13:return t==null?null:Cpt(P(t,247));case 15:case 14:return t==null?null:LPe(D(N(t)));case 17:return p5e((UN(),t));case 18:return p5e(t);case 21:case 20:return t==null?null:RPe(P(t,161).a);case 27:return iDe(P(t,195));case 30:return y3e((UN(),P(t,15)));case 31:return y3e(P(t,15));case 40:return oDe((UN(),t));case 42:return m5e((UN(),t));case 43:return m5e(t);case 59:case 48:return aDe((UN(),t));default:throw E(new Fi(YH+e.xe()+XH))}},Q.si=function(e){var t,n,r,i,a;switch(e.G==-1&&(e.G=(n=Mx(e),n?NO(n.vi(),e):-1)),e.G){case 0:return t=new g_e,t;case 1:return r=new cle,r;case 2:return i=new __e,i;case 3:return a=new v_e,a;default:throw E(new Fi($H+e.zb+XH))}},Q.ti=function(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_;switch(e.hk()){case 5:case 52:case 4:return t;case 6:return J2e(t);case 8:case 7:return t==null?null:D5e(t);case 9:return t==null?null:Gb(GM((r=EN(t,!0),r.length>0&&(sv(0,r.length),r.charCodeAt(0)==43)?(sv(1,r.length+1),r.substr(1)):r),-128,127)<<24>>24);case 10:return t==null?null:Gb(GM((i=EN(t,!0),i.length>0&&(sv(0,i.length),i.charCodeAt(0)==43)?(sv(1,i.length+1),i.substr(1)):i),-128,127)<<24>>24);case 11:return kd(uP(this,(UN(),OHt),t));case 12:return kd(uP(this,(UN(),kHt),t));case 13:return t==null?null:new xye(EN(t,!0));case 15:case 14:return Eat(t);case 16:return kd(uP(this,(UN(),AHt),t));case 17:return V0e((UN(),t));case 18:return V0e(t);case 28:case 29:case 35:case 38:case 39:case 41:case 54:case 19:return EN(t,!0);case 21:case 20:return zat(t);case 22:return kd(uP(this,(UN(),jHt),t));case 23:return kd(uP(this,(UN(),MHt),t));case 24:return kd(uP(this,(UN(),NHt),t));case 25:return kd(uP(this,(UN(),PHt),t));case 26:return kd(uP(this,(UN(),FHt),t));case 27:return A2e(t);case 30:return H0e((UN(),t));case 31:return H0e(t);case 32:return t==null?null:G(GM((u=EN(t,!0),u.length>0&&(sv(0,u.length),u.charCodeAt(0)==43)?(sv(1,u.length+1),u.substr(1)):u),xF,AP));case 33:return t==null?null:new ru((d=EN(t,!0),d.length>0&&(sv(0,d.length),d.charCodeAt(0)==43)?(sv(1,d.length+1),d.substr(1)):d));case 34:return t==null?null:G(GM((f=EN(t,!0),f.length>0&&(sv(0,f.length),f.charCodeAt(0)==43)?(sv(1,f.length+1),f.substr(1)):f),xF,AP));case 36:return t==null?null:JD(aP((p=EN(t,!0),p.length>0&&(sv(0,p.length),p.charCodeAt(0)==43)?(sv(1,p.length+1),p.substr(1)):p)));case 37:return t==null?null:JD(aP((m=EN(t,!0),m.length>0&&(sv(0,m.length),m.charCodeAt(0)==43)?(sv(1,m.length+1),m.substr(1)):m)));case 40:return e3e((UN(),t));case 42:return U0e((UN(),t));case 43:return U0e(t);case 44:return t==null?null:new ru((h=EN(t,!0),h.length>0&&(sv(0,h.length),h.charCodeAt(0)==43)?(sv(1,h.length+1),h.substr(1)):h));case 45:return t==null?null:new ru((g=EN(t,!0),g.length>0&&(sv(0,g.length),g.charCodeAt(0)==43)?(sv(1,g.length+1),g.substr(1)):g));case 46:return EN(t,!1);case 47:return kd(uP(this,(UN(),IHt),t));case 59:case 48:return $4e((UN(),t));case 49:return kd(uP(this,(UN(),LHt),t));case 50:return t==null?null:xT(GM((_=EN(t,!0),_.length>0&&(sv(0,_.length),_.charCodeAt(0)==43)?(sv(1,_.length+1),_.substr(1)):_),aW,32767)<<16>>16);case 51:return t==null?null:xT(GM((a=EN(t,!0),a.length>0&&(sv(0,a.length),a.charCodeAt(0)==43)?(sv(1,a.length+1),a.substr(1)):a),aW,32767)<<16>>16);case 53:return kd(uP(this,(UN(),RHt),t));case 55:return t==null?null:xT(GM((o=EN(t,!0),o.length>0&&(sv(0,o.length),o.charCodeAt(0)==43)?(sv(1,o.length+1),o.substr(1)):o),aW,32767)<<16>>16);case 56:return t==null?null:xT(GM((s=EN(t,!0),s.length>0&&(sv(0,s.length),s.charCodeAt(0)==43)?(sv(1,s.length+1),s.substr(1)):s),aW,32767)<<16>>16);case 57:return t==null?null:JD(aP((c=EN(t,!0),c.length>0&&(sv(0,c.length),c.charCodeAt(0)==43)?(sv(1,c.length+1),c.substr(1)):c)));case 58:return t==null?null:JD(aP((l=EN(t,!0),l.length>0&&(sv(0,l.length),l.charCodeAt(0)==43)?(sv(1,l.length+1),l.substr(1)):l)));case 60:return t==null?null:G(GM((n=EN(t,!0),n.length>0&&(sv(0,n.length),n.charCodeAt(0)==43)?(sv(1,n.length+1),n.substr(1)):n),xF,AP));case 61:return t==null?null:G(GM(EN(t,!0),xF,AP));default:throw E(new Fi(YH+e.xe()+XH))}};var BHt,VHt,HHt,UHt;L(TW,`XMLTypeFactoryImpl`,2028),q(594,184,{110:1,94:1,93:1,155:1,197:1,58:1,241:1,114:1,54:1,99:1,158:1,184:1,119:1,120:1,690:1,2044:1,594:1},NFe),Q.N=!1,Q.O=!1;var WHt=!1;L(TW,`XMLTypePackageImpl`,594),q(1961,1,{851:1},$ce),Q.Kk=function(){return Odt(),lUt},L(TW,`XMLTypePackageImpl/1`,1961),q(1970,1,lW,ele),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/10`,1970),q(1971,1,lW,tle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/11`,1971),q(1972,1,lW,nle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/12`,1972),q(1973,1,lW,rle),Q.fk=function(e){return al(e)},Q.gk=function(e){return V(TG,X,345,e,7,1)},L(TW,`XMLTypePackageImpl/13`,1973),q(1974,1,lW,ile),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/14`,1974),q(1975,1,lW,ale),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/15`,1975),q(1976,1,lW,ole),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/16`,1976),q(1977,1,lW,sle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/17`,1977),q(1978,1,lW,lle),Q.fk=function(e){return j(e,161)},Q.gk=function(e){return V(EG,X,161,e,0,1)},L(TW,`XMLTypePackageImpl/18`,1978),q(1979,1,lW,ule),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/19`,1979),q(1962,1,lW,dle),Q.fk=function(e){return j(e,857)},Q.gk=function(e){return V(_9,FP,857,e,0,1)},L(TW,`XMLTypePackageImpl/2`,1962),q(1980,1,lW,fle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/20`,1980),q(1981,1,lW,ple),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/21`,1981),q(1982,1,lW,mle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/22`,1982),q(1983,1,lW,hle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/23`,1983),q(1984,1,lW,gle),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(TW,`XMLTypePackageImpl/24`,1984),q(1985,1,lW,_le),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/25`,1985),q(1986,1,lW,vle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/26`,1986),q(1987,1,lW,yle),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/27`,1987),q(1988,1,lW,ble),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/28`,1988),q(1989,1,lW,xle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/29`,1989),q(1963,1,lW,Sle),Q.fk=function(e){return j(e,681)},Q.gk=function(e){return V(v9,FP,2119,e,0,1)},L(TW,`XMLTypePackageImpl/3`,1963),q(1990,1,lW,Cle),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(TW,`XMLTypePackageImpl/30`,1990),q(1991,1,lW,wle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/31`,1991),q(1992,1,lW,Tle),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(TW,`XMLTypePackageImpl/32`,1992),q(1993,1,lW,Ele),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/33`,1993),q(1994,1,lW,Dle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/34`,1994),q(1995,1,lW,Ole),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/35`,1995),q(1996,1,lW,kle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/36`,1996),q(1997,1,lW,Ale),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/37`,1997),q(1998,1,lW,jle),Q.fk=function(e){return j(e,15)},Q.gk=function(e){return V(JW,BL,15,e,0,1)},L(TW,`XMLTypePackageImpl/38`,1998),q(1999,1,lW,Mle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/39`,1999),q(1964,1,lW,Nle),Q.fk=function(e){return j(e,682)},Q.gk=function(e){return V(y9,FP,2120,e,0,1)},L(TW,`XMLTypePackageImpl/4`,1964),q(2e3,1,lW,Ple),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/40`,2e3),q(2001,1,lW,Fle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/41`,2001),q(2002,1,lW,Ile),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/42`,2002),q(2003,1,lW,Lle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/43`,2003),q(2004,1,lW,Rle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/44`,2004),q(2005,1,lW,zle),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(TW,`XMLTypePackageImpl/45`,2005),q(2006,1,lW,Ble),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/46`,2006),q(2007,1,lW,Vle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/47`,2007),q(2008,1,lW,Hle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/48`,2008),q(2009,1,lW,Ule),Q.fk=function(e){return j(e,191)},Q.gk=function(e){return V(PG,X,191,e,0,1)},L(TW,`XMLTypePackageImpl/49`,2009),q(1965,1,lW,Wle),Q.fk=function(e){return j(e,683)},Q.gk=function(e){return V(CHt,FP,2121,e,0,1)},L(TW,`XMLTypePackageImpl/5`,1965),q(2010,1,lW,Gle),Q.fk=function(e){return j(e,168)},Q.gk=function(e){return V(kG,X,168,e,0,1)},L(TW,`XMLTypePackageImpl/50`,2010),q(2011,1,lW,Kle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/51`,2011),q(2012,1,lW,qle),Q.fk=function(e){return j(e,17)},Q.gk=function(e){return V(DG,X,17,e,0,1)},L(TW,`XMLTypePackageImpl/52`,2012),q(1966,1,lW,Jle),Q.fk=function(e){return rl(e)},Q.gk=function(e){return V(LG,X,2,e,6,1)},L(TW,`XMLTypePackageImpl/6`,1966),q(1967,1,lW,Yle),Q.fk=function(e){return j(e,195)},Q.gk=function(e){return V(X9,X,195,e,0,2)},L(TW,`XMLTypePackageImpl/7`,1967),q(1968,1,lW,Xle),Q.fk=function(e){return il(e)},Q.gk=function(e){return V(bG,X,485,e,8,1)},L(TW,`XMLTypePackageImpl/8`,1968),q(1969,1,lW,Zle),Q.fk=function(e){return j(e,222)},Q.gk=function(e){return V(xG,X,222,e,0,1)},L(TW,`XMLTypePackageImpl/9`,1969);var A9,j9,M9,N9,$;q(55,63,SF,Ui),L(MW,`RegEx/ParseException`,55),q(836,1,{},Qle),Q.bm=function(e){return en*16)throw E(new Ui(TP((fu(),KCt))));n=n*16+i}while(!0);if(this.a!=125)throw E(new Ui(TP((fu(),qCt))));if(n>NW)throw E(new Ui(TP((fu(),JCt))));e=n}else{if(i=0,this.c!=0||(i=rk(this.a))<0||(n=i,hP(this),this.c!=0||(i=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));n=n*16+i,e=n}break;case 117:if(r=0,hP(this),this.c!=0||(r=rk(this.a))<0||(t=r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));t=t*16+r,e=t;break;case 118:if(hP(this),this.c!=0||(r=rk(this.a))<0||(t=r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0)||(t=t*16+r,hP(this),this.c!=0||(r=rk(this.a))<0))throw E(new Ui(TP((fu(),jU))));if(t=t*16+r,t>NW)throw E(new Ui(TP((fu(),`parser.descappe.4`))));e=t;break;case 65:case 90:case 122:throw E(new Ui(TP((fu(),YCt))))}return e},Q.dm=function(e){var t,n;switch(e){case 100:n=(this.e&32)==32?oP(`Nd`,!0):(xP(),z9);break;case 68:n=(this.e&32)==32?oP(`Nd`,!1):(xP(),QHt);break;case 119:n=(this.e&32)==32?oP(`IsWord`,!0):(xP(),U9);break;case 87:n=(this.e&32)==32?oP(`IsWord`,!1):(xP(),eUt);break;case 115:n=(this.e&32)==32?oP(`IsSpace`,!0):(xP(),H9);break;case 83:n=(this.e&32)==32?oP(`IsSpace`,!1):(xP(),$Ht);break;default:throw E(new yi((t=e,uTt+t.toString(16))))}return n},Q.em=function(e){var t,n,r,i,a,o,s,c,l,u,d,f;for(this.b=1,hP(this),t=null,this.c==0&&this.a==94?(hP(this),e?u=(xP(),xP(),++W9,new pv(5)):(t=(xP(),xP(),++W9,new pv(4)),oM(t,0,NW),u=(++W9,new pv(4)))):u=(xP(),xP(),++W9,new pv(4)),i=!0;(f=this.c)!=1&&!(f==0&&this.a==93&&!i);){if(i=!1,n=this.a,r=!1,f==10)switch(n){case 100:case 68:case 119:case 87:case 115:case 83:DN(u,this.dm(n)),r=!0;break;case 105:case 73:case 99:case 67:n=this.um(u,n),n<0&&(r=!0);break;case 112:case 80:if(d=Ont(this,n),!d)throw E(new Ui(TP((fu(),OU))));DN(u,d),r=!0;break;default:n=this.cm()}else if(f==20){if(o=fd(this.i,58,this.d),o<0)throw E(new Ui(TP((fu(),RCt))));if(s=!0,mg(this.i,this.d)==94&&(++this.d,s=!1),a=p_(this.i,this.d,o),c=dGe(a,s,(this.e&512)==512),!c)throw E(new Ui(TP((fu(),zCt))));if(DN(u,c),r=!0,o+1>=this.j||mg(this.i,o+1)!=93)throw E(new Ui(TP((fu(),RCt))));this.d=o+2}if(hP(this),!r){if(this.c!=0||this.a!=45)oM(u,n,n);else{if(hP(this),(f=this.c)==1)throw E(new Ui(TP((fu(),kU))));f==0&&this.a==93?(oM(u,n,n),oM(u,45,45)):(l=this.a,f==10&&(l=this.cm()),hP(this),oM(u,n,l))}}(this.e&pF)==pF&&this.c==0&&this.a==44&&hP(this)}if(this.c==1)throw E(new Ui(TP((fu(),kU))));return t&&(KN(t,u),u=t),kj(u),FN(u),this.b=0,hP(this),u},Q.fm=function(){for(var e,t,n=this.em(!1),r;(r=this.c)!=7;)if(e=this.a,r==0&&(e==45||e==38)||r==4){if(hP(this),this.c!=9)throw E(new Ui(TP((fu(),UCt))));if(t=this.em(!1),r==4)DN(n,t);else if(e==45)KN(n,t);else if(e==38)iht(n,t);else throw E(new yi(`ASSERT`))}else throw E(new Ui(TP((fu(),WCt))));return hP(this),n},Q.gm=function(){var e=this.a-48,t=(xP(),xP(),++W9,new __(12,null,e));return!this.g&&(this.g=new Yr),Gr(this.g,new Xhe(e)),hP(this),t},Q.hm=function(){return hP(this),xP(),nUt},Q.im=function(){return hP(this),xP(),tUt},Q.jm=function(){throw E(new Ui(TP((fu(),MU))))},Q.km=function(){throw E(new Ui(TP((fu(),MU))))},Q.lm=function(){return hP(this),eQe()},Q.mm=function(){return hP(this),xP(),iUt},Q.nm=function(){return hP(this),xP(),oUt},Q.om=function(){var e;if(this.d>=this.j||((e=mg(this.i,this.d++))&65504)!=64)throw E(new Ui(TP((fu(),PCt))));return hP(this),xP(),xP(),++W9,new zp(0,e-64)},Q.pm=function(){return hP(this),Qdt()},Q.qm=function(){return hP(this),xP(),sUt},Q.rm=function(){var e=(xP(),xP(),++W9,new zp(0,105));return hP(this),e},Q.sm=function(){return hP(this),xP(),aUt},Q.tm=function(){return hP(this),xP(),rUt},Q.um=function(e,t){return this.cm()},Q.vm=function(){return hP(this),xP(),XHt},Q.wm=function(){var e,t,n,r,i;if(this.d+1>=this.j)throw E(new Ui(TP((fu(),jCt))));if(r=-1,t=null,e=mg(this.i,this.d),49<=e&&e<=57){if(r=e-48,!this.g&&(this.g=new Yr),Gr(this.g,new Xhe(r)),++this.d,mg(this.i,this.d)!=41)throw E(new Ui(TP((fu(),DU))));++this.d}else switch(e==63&&--this.d,hP(this),t=Q_t(this),t.e){case 20:case 21:case 22:case 23:break;case 8:if(this.c!=7)throw E(new Ui(TP((fu(),DU))));break;default:throw E(new Ui(TP((fu(),MCt))))}if(hP(this),i=zD(this),n=null,i.e==2){if(i.Pm()!=2)throw E(new Ui(TP((fu(),NCt))));n=i.Lm(1),i=i.Lm(0)}if(this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),xP(),xP(),++W9,new hKe(r,t,i,n)},Q.xm=function(){return hP(this),xP(),ZHt},Q.ym=function(){var e;if(hP(this),e=Em(24,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.zm=function(){var e;if(hP(this),e=Em(20,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Am=function(){var e;if(hP(this),e=Em(22,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Bm=function(){var e=0,t,n=0,r,i;for(t=-1;this.d=this.j)throw E(new Ui(TP((fu(),kCt))));if(t==45){for(++this.d;this.d=this.j)throw E(new Ui(TP((fu(),kCt))))}if(t==58){if(++this.d,hP(this),r=YPe(zD(this),e,n),this.c!=7)throw E(new Ui(TP((fu(),DU))));hP(this)}else if(t==41)++this.d,hP(this),r=YPe(zD(this),e,n);else throw E(new Ui(TP((fu(),ACt))));return r},Q.Cm=function(){var e;if(hP(this),e=Em(21,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Dm=function(){var e;if(hP(this),e=Em(23,zD(this)),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Em=function(){var e,t;if(hP(this),e=this.f++,t=Dm(zD(this),e),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),t},Q.Fm=function(){var e;if(hP(this),e=Dm(zD(this),0),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Gm=function(e){return hP(this),this.c==5?(hP(this),Rp(e,(xP(),xP(),++W9,new Zv(9,e)))):Rp(e,(xP(),xP(),++W9,new Zv(3,e)))},Q.Hm=function(e){var t;return hP(this),t=(xP(),xP(),++W9,new lu(2)),this.c==5?(hP(this),LN(t,B9),LN(t,e)):(LN(t,e),LN(t,B9)),t},Q.Im=function(e){return hP(this),this.c==5?(hP(this),xP(),xP(),++W9,new Zv(9,e)):(xP(),xP(),++W9,new Zv(3,e))},Q.a=0,Q.b=0,Q.c=0,Q.d=0,Q.e=0,Q.f=1,Q.g=null,Q.j=0,L(MW,`RegEx/RegexParser`,836),q(1947,836,{},y_e),Q.bm=function(e){return!1},Q.cm=function(){return Tct(this)},Q.dm=function(e){return KM(e)},Q.em=function(e){return _vt(this)},Q.fm=function(){throw E(new Ui(TP((fu(),MU))))},Q.gm=function(){throw E(new Ui(TP((fu(),MU))))},Q.hm=function(){throw E(new Ui(TP((fu(),MU))))},Q.im=function(){throw E(new Ui(TP((fu(),MU))))},Q.jm=function(){return hP(this),KM(67)},Q.km=function(){return hP(this),KM(73)},Q.lm=function(){throw E(new Ui(TP((fu(),MU))))},Q.mm=function(){throw E(new Ui(TP((fu(),MU))))},Q.nm=function(){throw E(new Ui(TP((fu(),MU))))},Q.om=function(){return hP(this),KM(99)},Q.pm=function(){throw E(new Ui(TP((fu(),MU))))},Q.qm=function(){throw E(new Ui(TP((fu(),MU))))},Q.rm=function(){return hP(this),KM(105)},Q.sm=function(){throw E(new Ui(TP((fu(),MU))))},Q.tm=function(){throw E(new Ui(TP((fu(),MU))))},Q.um=function(e,t){return DN(e,KM(t)),-1},Q.vm=function(){return hP(this),xP(),xP(),++W9,new zp(0,94)},Q.wm=function(){throw E(new Ui(TP((fu(),MU))))},Q.xm=function(){return hP(this),xP(),xP(),++W9,new zp(0,36)},Q.ym=function(){throw E(new Ui(TP((fu(),MU))))},Q.zm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Am=function(){throw E(new Ui(TP((fu(),MU))))},Q.Bm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Cm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Dm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Em=function(){var e;if(hP(this),e=Dm(zD(this),0),this.c!=7)throw E(new Ui(TP((fu(),DU))));return hP(this),e},Q.Fm=function(){throw E(new Ui(TP((fu(),MU))))},Q.Gm=function(e){return hP(this),Rp(e,(xP(),xP(),++W9,new Zv(3,e)))},Q.Hm=function(e){var t;return hP(this),t=(xP(),xP(),++W9,new lu(2)),LN(t,e),LN(t,B9),t},Q.Im=function(e){return hP(this),xP(),xP(),++W9,new Zv(3,e)};var P9=null,F9=null;L(MW,`RegEx/ParserForXMLSchema`,1947),q(122,1,VW,Tr),Q.Jm=function(e){throw E(new yi(`Not supported.`))},Q.Km=function(){return-1},Q.Lm=function(e){return null},Q.Mm=function(){return null},Q.Nm=function(e){},Q.Om=function(e){},Q.Pm=function(){return 0},Q.Ib=function(){return this.Qm(0)},Q.Qm=function(e){return this.e==11?`.`:``},Q.e=0;var GHt,I9,L9,KHt,qHt,R9=null,z9,JHt=null,YHt,B9,V9=null,XHt,ZHt,QHt,$Ht,eUt,tUt,H9,nUt,rUt,iUt,aUt,U9,oUt,sUt,W9=0,cUt=L(MW,`RegEx/Token`,122);q(138,122,{3:1,138:1,122:1},pv),Q.Qm=function(e){var t,n,r;if(this.e==4){if(this==YHt)n=`.`;else if(this==z9)n=`\\d`;else if(this==U9)n=`\\w`;else if(this==H9)n=`\\s`;else{for(r=new $i,r.a+=`[`,t=0;t0&&(r.a+=`,`),this.b[t]===this.b[t+1]?pl(r,uN(this.b[t])):(pl(r,uN(this.b[t])),r.a+=`-`,pl(r,uN(this.b[t+1])));r.a+=`]`,n=r.a}}else if(this==QHt)n=`\\D`;else if(this==eUt)n=`\\W`;else if(this==$Ht)n=`\\S`;else{for(r=new $i,r.a+=`[^`,t=0;t0&&(r.a+=`,`),this.b[t]===this.b[t+1]?pl(r,uN(this.b[t])):(pl(r,uN(this.b[t])),r.a+=`-`,pl(r,uN(this.b[t+1])));r.a+=`]`,n=r.a}return n},Q.a=!1,Q.c=!1,L(MW,`RegEx/RangeToken`,138),q(592,1,{592:1},Xhe),Q.a=0,L(MW,`RegEx/RegexParser/ReferencePosition`,592),q(591,1,{3:1,591:1},Rye),Q.Fb=function(e){var t;return e==null||!j(e,591)?!1:(t=P(e,591),ff(this.b,t.b)&&this.a==t.a)},Q.Hb=function(){return jw(this.b+`/`+Xot(this.a))},Q.Ib=function(){return this.c.Qm(this.a)},Q.a=0,L(MW,`RegEx/RegularExpression`,591),q(228,122,VW,zp),Q.Km=function(){return this.a},Q.Qm=function(e){var t,n,r;switch(this.e){case 0:switch(this.a){case 124:case 42:case 43:case 63:case 40:case 41:case 46:case 91:case 123:case 92:r=`\\`+Xd(this.a&OF);break;case 12:r=`\\f`;break;case 10:r=`\\n`;break;case 13:r=`\\r`;break;case 9:r=`\\t`;break;case 27:r=`\\e`;break;default:this.a>=pI?(n=(t=this.a>>>0,`0`+t.toString(16)),r=`\\v`+p_(n,n.length-6,n.length)):r=``+Xd(this.a&OF)}break;case 8:r=this==XHt||this==ZHt?``+Xd(this.a&OF):`\\`+Xd(this.a&OF);break;default:r=null}return r},Q.a=0,L(MW,`RegEx/Token/CharToken`,228),q(318,122,VW,Zv),Q.Lm=function(e){return this.a},Q.Nm=function(e){this.b=e},Q.Om=function(e){this.c=e},Q.Pm=function(){return 1},Q.Qm=function(e){var t;if(this.e==3){if(this.c<0&&this.b<0)t=this.a.Qm(e)+`*`;else if(this.c==this.b)t=this.a.Qm(e)+`{`+this.c+`}`;else if(this.c>=0&&this.b>=0)t=this.a.Qm(e)+`{`+this.c+`,`+this.b+`}`;else if(this.c>=0&&this.b<0)t=this.a.Qm(e)+`{`+this.c+`,}`;else throw E(new yi(`Token#toString(): CLOSURE `+this.c+PP+this.b))}else if(this.c<0&&this.b<0)t=this.a.Qm(e)+`*?`;else if(this.c==this.b)t=this.a.Qm(e)+`{`+this.c+`}?`;else if(this.c>=0&&this.b>=0)t=this.a.Qm(e)+`{`+this.c+`,`+this.b+`}?`;else if(this.c>=0&&this.b<0)t=this.a.Qm(e)+`{`+this.c+`,}?`;else throw E(new yi(`Token#toString(): NONGREEDYCLOSURE `+this.c+PP+this.b));return t},Q.b=0,Q.c=0,L(MW,`RegEx/Token/ClosureToken`,318),q(837,122,VW,Km),Q.Lm=function(e){return e==0?this.a:this.b},Q.Pm=function(){return 2},Q.Qm=function(e){return this.b.e==3&&this.b.Lm(0)==this.a?this.a.Qm(e)+`+`:this.b.e==9&&this.b.Lm(0)==this.a?this.a.Qm(e)+`+?`:this.a.Qm(e)+(``+this.b.Qm(e))},L(MW,`RegEx/Token/ConcatToken`,837),q(1945,122,VW,hKe),Q.Lm=function(e){if(e==0)return this.d;if(e==1)return this.b;throw E(new yi(`Internal Error: `+e))},Q.Pm=function(){return this.b?2:1},Q.Qm=function(e){var t=this.c>0?`(?(`+this.c+`)`:this.a.e==8?`(?(`+this.a+`)`:`(?`+this.a;return this.b?t+=this.d+`|`+this.b+`)`:t+=this.d+`)`,t},Q.c=0,L(MW,`RegEx/Token/ConditionToken`,1945),q(1946,122,VW,Lze),Q.Lm=function(e){return this.b},Q.Pm=function(){return 1},Q.Qm=function(e){return`(?`+(this.a==0?``:Xot(this.a))+(this.c==0?``:Xot(this.c))+`:`+this.b.Qm(e)+`)`},Q.a=0,Q.c=0,L(MW,`RegEx/Token/ModifierToken`,1946),q(838,122,VW,Nh),Q.Lm=function(e){return this.a},Q.Pm=function(){return 1},Q.Qm=function(e){var t=null;switch(this.e){case 6:t=this.b==0?`(?:`+this.a.Qm(e)+`)`:`(`+this.a.Qm(e)+`)`;break;case 20:t=`(?=`+this.a.Qm(e)+`)`;break;case 21:t=`(?!`+this.a.Qm(e)+`)`;break;case 22:t=`(?<=`+this.a.Qm(e)+`)`;break;case 23:t=`(?`+this.a.Qm(e)+`)`}return t},Q.b=0,L(MW,`RegEx/Token/ParenToken`,838),q(530,122,{3:1,122:1,530:1},__),Q.Mm=function(){return this.b},Q.Qm=function(e){return this.e==12?`\\`+this.a:oat(this.b)},Q.a=0,L(MW,`RegEx/Token/StringToken`,530),q(477,122,VW,lu),Q.Jm=function(e){LN(this,e)},Q.Lm=function(e){return P(Rh(this.a,e),122)},Q.Pm=function(){return this.a?this.a.a.c.length:0},Q.Qm=function(e){var t,n,r,i,a;if(this.e==1){if(this.a.a.c.length==2)t=P(Rh(this.a,0),122),n=P(Rh(this.a,1),122),i=n.e==3&&n.Lm(0)==t?t.Qm(e)+`+`:n.e==9&&n.Lm(0)==t?t.Qm(e)+`+?`:t.Qm(e)+(``+n.Qm(e));else{for(a=new $i,r=0;r=this.c.b:this.a<=this.c.b},Q.Sb=function(){return this.b>0},Q.Tb=function(){return this.b},Q.Vb=function(){return this.b-1},Q.Qb=function(){throw E(new Ri(yTt))},Q.a=0,Q.b=0,L(gTt,`ExclusiveRange/RangeIterator`,258);var K9=Jh(VU,`C`),q9=Jh(WU,`I`),J9=Jh(DP,`Z`),Y9=Jh(GU,`J`),X9=Jh(BU,`B`),Z9=Jh(HU,`D`),Q9=Jh(UU,`F`),$9=Jh(KU,`S`),uUt=gp(`org.eclipse.elk.core.labels`,`ILabelManager`),dUt=gp(uU,`DiagnosticChain`),fUt=gp(Lwt,`ResourceSet`),pUt=L(uU,`InvocationTargetException`,null),mUt=(Qi(),mUe),hUt=hUt=e5e;SJe(sge),uJe(`permProps`,[[[`locale`,`default`],[bTt,`gecko1_8`]],[[`locale`,`default`],[bTt,`safari`]]]),hUt(null,`elk`,null)}).call(this)}).call(this,typeof global<`u`?global:typeof self<`u`?self:typeof window<`u`?window:{})},{}],3:[function(e,t,n){function r(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}function i(e,t){if(!e)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return t&&(typeof t==`object`||typeof t==`function`)?t:e}function a(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Super expression must either be null or a function, not `+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var o=function(t){a(n,t);function n(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};r(this,n);var a=Object.assign({},t),o=!1;try{e.resolve(`web-worker`),o=!0}catch{}if(t.workerUrl){if(o){var s=e("web-worker");a.workerFactory=function(e){return new s(e)}}else console.warn(`Web worker requested but 'web-worker' package not installed. +Consider installing the package or pass your own 'workerFactory' to ELK's constructor. +... Falling back to non-web worker version.`)}if(!a.workerFactory){var c=e("./elk-worker.min.js").Worker;a.workerFactory=function(e){return new c(e)}}return i(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,a))}return n}(e("./elk-api.js").default);Object.defineProperty(t.exports,"__esModule",{value:!0}),t.exports=o,o.default=o},{"./elk-api.js":1,"./elk-worker.min.js":2,"web-worker":4}],4:[function(e,t,n){t.exports=Worker},{}]},{},[3])(3)})}))(),1),p=r((e,t,{parentById:n})=>{let r=new Set,i=e;if(e===t)return n[e]||`root`;for(;i;){if(r.add(i),i===t)return i;i=n[i]}for(i=t;i;){if(r.has(i))return i;i=n[i]}return`root`},`findCommonAncestor`),m=6;function h(e,{measure:t}){let n=e.config?.elk?.lineHops;if(n===!1)return;let r=e.edges.filter(e=>Array.isArray(e.points)&&e.points.length>=2).map(e=>({id:e.id,points:e.points,curve:e.curve,arrowTypeStart:e.arrowTypeStart,arrowTypeEnd:e.arrowTypeEnd}));d(t.groups.edgePaths,r,{enabled:!0,jumpRadius:m,jumpStyle:n===`gap`?`gap`:`arc`})}r(h,`applyElkLineJumps`);var g={},_={},v={},y={},b=1,x=10,S=r((e,t,n=.5)=>{let r=e.width/2,i=e.height/2,a=e.x-r,o=e.x+r,s=e.y-i,c=e.y+i,l=Math.abs(t.x-a)<=n&&t.y>=s-n&&t.y<=c+n,u=Math.abs(t.x-o)<=n&&t.y>=s-n&&t.y<=c+n,d=Math.abs(t.y-s)<=n&&t.x>=a-n&&t.x<=o+n,f=Math.abs(t.y-c)<=n&&t.x>=a-n&&t.x<=o+n;return l||u||d||f},`onBorder`),ee=r((e,t,n)=>{let r=e.x,i=e.y,a=Math.abs(r-n.x),o=e.width/2,s=n.xMath.abs(r-t.x)*c){let e=n.y{let n=e.x,r=e.y,i=Math.abs(t.x-n),a=Math.abs(t.y-r),o=e.width/2,s=e.height/2;return i>=o||a>=s},`outsideNode`),ne=r((e,t,n=x)=>{let r=Math.abs(t.x-e.x),i=Math.abs(t.y-e.y),a=e.width/2,o=e.height/2;if(Math.abs(r-a)0)return{x:e.x+r/a*(a+n),y:e.y+i/a*(a+n)}}return t},`ensureTrulyOutside`),C=r((e,t,n)=>{let r=Math.abs(t.x-e.x){if(!e?.intersect)return null;let r=e.intersect(n);return!r||n.xt.x||n.x>t.x&&r.xee(e,t,C(e,t,n)),`fallbackIntersection`),ae=20,oe=1e-6,se=r((e,t,n)=>{let r=e.intersect?.(n);return r?Math.hypot(n.x-t.x,n.y-t.y)<=Math.hypot(r.x-t.x,r.y-t.y)+1e-9:!1},`insideOutline`),ce=r((e,t,n,i)=>{if(!e?.intersect)return null;let a=i.x-n.x,o=i.y-n.y;if(a===0&&o===0||Math.abs(a)>oe&&Math.abs(o)>oe)return null;let s={x:t.x,y:t.y},c=Math.abs(a)>Math.abs(o),l=r(e=>c?{x:e,y:n.y}:{x:n.x,y:e},`along`),u=c?s.x:s.y,d=c?n.x:n.y;if(!se(e,s,l(u)))return null;if(se(e,s,l(d)))return{...n};for(let t=0;t{let i=ne(t,n);return re(e,t,i)??ie(t,i,r)},`computeNodeIntersection`),ue=r((e,t,n,r=.1)=>{if(!(!n||e.length===0)){if(t===`start`)e.length>0&&Math.abs(e[0].x-n.x)0&&Math.abs(e[t].x-n.x)typeof e==`string`?Math.max(o[e]??0,s[e]??0):0,`markerPathOffset`),pe={arrow_open:[`none`,`none`],arrow_cross:[`none`,`arrow_cross`],double_arrow_cross:[`arrow_cross`,`arrow_cross`],arrow_point:[`none`,`arrow_point`],double_arrow_point:[`arrow_point`,`arrow_point`],arrow_circle:[`none`,`arrow_circle`],double_arrow_circle:[`arrow_circle`,`arrow_circle`]},me=12,he=`[top=${me},left=${me},bottom=${me},right=${me}]`,ge=24,_e=24,ve=50,ye=15,be=10,xe={"spacing.baseValue":15,"spacing.nodeNode":15,"elk.aspectRatio":`1.6`,"elk.expandNodes":`true`,"elk.rectpacking.trybox":`true`,"elk.rectpacking.packing.compaction.rowHeightReevaluation":`true`,"elk.rectpacking.packing.compaction.iterations":10,"elk.rectpacking.whiteSpaceElimination.strategy":`EQUAL_BETWEEN_STRUCTURES`,"elk.rectpacking.widthApproximation.strategy":`SCANLINE`},Se=[`nodeSize.constraints`,`nodeSize.minimum`,`elk.algorithm`,`elk.aspectRatio`,`elk.contentAlignment`,`elk.expandNodes`,`elk.padding`,...Object.keys(xe)];function Ce(e){for(let t of Se)delete e[t];e[`spacing.baseValue`]=_e,e[`spacing.nodeNode`]=ve}r(Ce,`clearContainerAlgorithmOptions`);var we=new Set([`elk.layered`,`elk.box`,`elk.rectpacking`,`elk.stress`,`elk.force`,`elk.mrtree`,`elk.radial`,`elk.sporeOverlap`]);function Te(e,t){if(typeof e==`string`){if(!we.has(e)){t?.warn(`Unknown container layout algorithm "${e}". Supported values: ${[...we].join(`, `)}. Falling back to the diagram's layout algorithm.`);return}return e}}r(Te,`resolveContainerAlgorithm`);function Ee(e){switch(e){case`LR`:return`RIGHT`;case`RL`:return`LEFT`;case`TB`:case`TD`:return`DOWN`;case`BT`:return`UP`;default:return`DOWN`}}r(Ee,`dir2ElkDirection`);function De(e){return c(e.shape)?(e.labelData?.width??e.labels?.[0]?.width??0)+(e.padding??0):0}r(De,`groupTitleWidth`);function Oe(e){return c(e.shape)?{"nodeSize.constraints":`[MINIMUM_SIZE, NODE_LABELS]`,"nodeSize.minimum":`(${De(e)}, 0)`}:{}}r(Oe,`groupTitleSizeOptions`);function ke(e,t,n,r){let i=(e.labelData?.width??0)+2*(e.padding??0),a=e.labelData?.height??0,o=Ve(t?.preset),s={...Oe(e),"spacing.baseValue":_e,"elk.layered.spacing.edgeNodeBetweenLayers":30,"elk.spacing.edgeEdge":20,"spacing.nodeNode":ve,"elk.padding":`[top=${ge},left=${ge},bottom=${ge},right=${ge}]`,"nodeLabels.placement":`[H_CENTER V_TOP, INSIDE]`,"elk.layered.mergeEdges":t?.mergeEdges,"elk.layered.nodePlacement.bk.fixedAlignment":t?.nodePlacementAlignment??o.alignment,"elk.layered.nodePlacement.strategy":t?.nodePlacementStrategy??o.containerPlacement,"elk.layered.cycleBreaking.strategy":t?.cycleBreakingStrategy??o.cycleBreaking,"elk.layered.nodePlacement.networkSimplex.nodeFlexibility":`PORT_POSITION`,"elk.spacing.portsSurrounding":he},c=Te(e.metadata?.algorithm,r);if(c){let e=a+ye;if(s[`nodeSize.constraints`]=`[MINIMUM_SIZE, NODE_LABELS]`,s[`nodeSize.minimum`]=`(${i}, ${e+ye})`,s[`elk.algorithm`]=c,s[`elk.hierarchyHandling`]=`SEPARATE_CHILDREN`,s[`elk.aspectRatio`]=`2.0`,s[`elk.contentAlignment`]=`H_CENTER V_TOP`,s[`elk.expandNodes`]=`true`,s[`elk.padding`]=`[top=${e},left=${ye},bottom=${ye},right=${ye}]`,c===`elk.rectpacking`){let e=a+be;Object.assign(s,xe,{"elk.padding":`[top=${e},left=${be},bottom=${be},right=${be}]`,"nodeSize.minimum":`(${i}, ${e+be})`})}}else e.dir&&(s[`elk.algorithm`]=n,s[`elk.direction`]=Ee(e.dir),s[`elk.hierarchyHandling`]=`SEPARATE_CHILDREN`);return Object.assign(s,y),s}r(ke,`buildSubgraphLayoutOptions`);function Ae(e,t){let n=new Set,i=new Map;for(let{id:t,parentId:n}of e){let e=i.get(n);e?e.push(t):i.set(n,[t])}for(let e of i.values()){let i=new Set(e),a=new Map(e.map(e=>[e,0])),o=new Map(e.map(e=>[e,[]])),s=[];for(let e of t){let t=e.source==null?void 0:String(e.source),n=e.target==null?void 0:String(e.target);!t||!n||t===n||!i.has(t)||!i.has(n)||(a.set(n,(a.get(n)??0)+1),o.get(t).push(n),o.get(n).push(t),s.push([t,n]))}let c=new Map,l=0;for(let t of e){if(c.has(t))continue;let e=[t];for(c.set(t,l);e.length>0;){let t=e.pop();for(let n of o.get(t))c.has(n)||(c.set(n,l),e.push(n))}l++}let u=Array(l).fill(!1);for(let t of e)(a.get(t)??0)===0&&(u[c.get(t)]=!0);if(!u.includes(!1))continue;let d=new Map(e.map(e=>[e,[]])),f=new Map(e.map(e=>[e,0])),p=r((e,t)=>{let n=new Set([e]),r=[e];for(;r.length>0;){let e=r.pop();if(e===t)return!0;for(let t of d.get(e))n.has(t)||(n.add(t),r.push(t))}return!1},`reaches`);for(let[e,t]of s)p(t,e)||(d.get(e).push(t),f.set(t,(f.get(t)??0)+1));let m=Array(l).fill(!1);for(let t of e){let e=c.get(t);!u[e]&&!m[e]&&f.get(t)===0&&(n.add(t),m[e]=!0)}}return n}r(Ae,`findCyclicEntryNodes`);function je(e,t){if(!e.config.elk?.keepEntryNodeOnTop)return;let n=Ae(e.nodes,e.edges.map(e=>({source:e.start,target:e.end})));for(let e of n){let n=t[e];n&&(n.layoutOptions={...n.layoutOptions,"elk.layered.layering.layerConstraint":`FIRST`})}}r(je,`applyCyclicEntryConstraint`);function Me(e,t){let n=ze(t);return Ie(n),Tt(e,n),{algorithm:n.algorithm}}r(Me,`prepareLayoutForElk`);async function Ne(e,t){let n=ze(t),r=Pe(e,n),i=new f.default;n.log.info(`Drawing flowchart using v4 renderer`,i);let a=await $e(i,r.elkGraph,n.log);return et(e,a,r,n.log),Le(e.nodes),a}r(Ne,`runElkLayoutCore`);function Pe(e,t){let n={},r=He(e,t.algorithm,t.rootLayoutOptions),i=e.direction??`DOWN`;r.layoutOptions[`elk.direction`]=Ee(i);let a=Ue(e.nodes,t.log);return We(e.nodes,r,n,t),Je(e,r,n,t),Xe(e,n,a,t),Ze(r,n,a,t.log),je(e,n),{elkGraph:r,nodeDb:n,parentLookupDb:a}}r(Pe,`buildElkGraphFromLayoutData`);var Fe=u({afterPaint:h,prepareLayout:Me,measureLayout:r((e,t)=>l(e,t,{unwrapGroupLabels:!0}),`measureLayout`),runLayoutCore:Ne,paintOptions:{skipIntersect:!0}});function Ie(e){i(e.getConfig())}r(Ie,`syncHostConfig`);function Le(e){let t=new Map(e.map(e=>[e.id,e]));e.sort((e,n)=>e.isGroup===n.isGroup?e.isGroup&&n.isGroup?Re(e,t)-Re(n,t):0:e.isGroup?-1:1)}r(Le,`orderNodesForElkPaint`);function Re(e,t){let n=0,r=new Set,i=e.parentId;for(;i&&!r.has(i);){r.add(i);let e=t.get(i);if(!e?.isGroup)break;n++,i=e.parentId}return n}r(Re,`getGroupDepth`);function ze(e){let t=e.helpers;if(!t)throw Error(`ELK layout requires Mermaid internal helpers`);return{algorithm:e.preparedLayout?.algorithm??e.options?.algorithm,rootLayoutOptions:e.options?.rootLayoutOptions,common:t.common,getConfig:t.getConfig,interpolateToCurve:t.interpolateToCurve,log:t.log}}r(ze,`getElkLayoutContext`);var Be={default:{layering:`NETWORK_SIMPLEX`,placement:`BRANDES_KOEPF`,containerPlacement:`BRANDES_KOEPF`,alignment:`BALANCED`,cycleBreaking:`DEPTH_FIRST`},legacy:{layering:`NETWORK_SIMPLEX`,placement:`BRANDES_KOEPF`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`GREEDY`},modelOrder:{layering:`NETWORK_SIMPLEX`,placement:`NETWORK_SIMPLEX`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`GREEDY_MODEL_ORDER`},depthFirst:{layering:`NETWORK_SIMPLEX`,placement:`NETWORK_SIMPLEX`,containerPlacement:`BRANDES_KOEPF`,alignment:`NONE`,cycleBreaking:`DEPTH_FIRST`}};function Ve(e){return e!==void 0&&Object.hasOwn(Be,e)?Be[e]:Be.default}r(Ve,`resolveElkPreset`);function He(e,t,n){let r=Ve(e.config.elk?.preset),i={id:`root`,layoutOptions:{"elk.hierarchyHandling":`INCLUDE_CHILDREN`,"elk.algorithm":t,"elk.layered.nodePlacement.strategy":e.config.elk?.nodePlacementStrategy??r.placement,"elk.layered.nodePlacement.bk.fixedAlignment":e.config.elk?.nodePlacementAlignment??r.alignment,"elk.layered.mergeEdges":e.config.elk?.mergeEdges,"elk.direction":`DOWN`,"spacing.baseValue":40,"elk.layered.crossingMinimization.forceNodeModelOrder":e.config.elk?.forceNodeModelOrder,"elk.layered.considerModelOrder.strategy":e.config.elk?.considerModelOrder,"elk.layered.unnecessaryBendpoints":!0,"elk.layered.cycleBreaking.strategy":e.config.elk?.cycleBreakingStrategy??r.cycleBreaking,"elk.layered.layering.strategy":e.config.elk?.layeringStrategy??r.layering,"elk.layered.layering.coffmanGraham.layerBound":e.config.elk?.layeringLayerBound,"elk.layered.wrapping.multiEdge.improveCuts":!0,"elk.layered.wrapping.multiEdge.improveWrappedEdges":!0,"elk.layered.edgeRouting.selfLoopDistribution":`EQUALLY`,"elk.layered.mergeHierarchyEdges":!0,"elk.spacing.portsSurrounding":he},children:[],edges:[]};return t===`elk.rectpacking`&&Object.assign(i.layoutOptions,xe,{"elk.contentAlignment":`H_CENTER V_TOP`,"elk.padding":`[top=15,left=15,bottom=15,right=15]`}),n&&Object.assign(i.layoutOptions,n),Object.assign(i.layoutOptions,g,_,v),i}r(He,`createRootElkGraph`);function Ue(e,t){let n={parentById:{},childrenById:{}},r=e.filter(e=>e.isGroup);return t.info(`Subgraphs - `,r),r.forEach(t=>{e.filter(e=>e.parentId===t.id).forEach(e=>{n.parentById[e.id]=t.id,n.childrenById[t.id]??=[],n.childrenById[t.id].push(e.id)})}),n}r(Ue,`addSubGraphs`);function We(e,t,n,r,i){let a=e.filter(e=>e?.parentId===i);return r.log.info(`addVertices APA12`,a,i),a.forEach(i=>{Ge(t,e,i,n,r)}),t}r(We,`addVertices`);function Ge(e,t,n,r,i){let a=Ke(n);e.children.push(a),r[n.id]=a,n.isGroup&&(a.children=[],We(t,a,r,i,n.id),a.labelData=qe(n,i.getConfig()))}r(Ge,`addVertex`);function Ke(e){let t={...e};return delete t.domId,e.isGroup?t.children=[]:(t.width=e.width??0,t.height=e.height??0,e.spreadPorts&&(t.layoutOptions={...t.layoutOptions,"elk.portAlignment.default":`CENTER`})),t}r(Ke,`createElkNode`);function qe(e,t){return e.labelData||(e.labelBBox?{width:e.labelBBox.width,height:Math.max(0,e.labelBBox.height-2),wrappingWidth:e.wrappingWidth??t.flowchart?.wrappingWidth}:{width:0,height:0,wrappingWidth:e.wrappingWidth??t.flowchart?.wrappingWidth})}r(qe,`getMeasuredLabelData`);function Je(e,t,n,r){r.log.info(`abc78 DAGA edges = `,e);let i={};return e.edges.forEach(e=>{let a=e.id;i[a]=(i[a]??-1)+1;let o=a;e.id=o,r.log.info(`abc78 new link id to be used is`,a,o,i[a]);let{source:s,target:c,sourceId:l,targetId:u}=Ye(e,n);r.log.debug(`abc78 source and target`,s,c),t.edges.push({...e,sources:[s],targets:[c],sourceId:l,targetId:u,labels:[{width:e.width??0,height:e.height??0,orgWidth:e.width??0,orgHeight:e.height??0,text:e.label??``,layoutOptions:{"edgeLabels.inline":`true`,"edgeLabels.placement":`CENTER`}}]})}),t}r(Je,`addEdgesToElkGraph`);function Ye(e,t){let n=e.start,r=e.end,i=n,a=r,o=n?t[n]:void 0,s=r?t[r]:void 0;return!o||!s?{source:i,target:a}:{source:i,target:a,sourceId:n,targetId:r}}r(Ye,`getEdgeStartEndPoint`);function Xe(e,t,n,r){e.nodes.forEach(i=>{let a=t[i.id];!a||n.childrenById[a.id]===void 0||(a.labels=[{text:a.label,width:a?.labelData?.width??50,height:a?.labelData?.height??50}],r.log.debug(`UIO node label`,a?.labelData?.width,a.padding),a.layoutOptions=ke(a,e.config.elk,r.algorithm,r.log),delete a.x,delete a.y,delete a.width,delete a.height)})}r(Xe,`configureSubgraphNodes`);function Ze(e,t,n,r){r.debug(`APA01 processing edges, count:`,e.edges.length),e.edges.forEach((e,i)=>{r.debug(`APA01 processing edge`,i,`:`,e);let a=e.sources[0],o=e.targets[0];if(r.debug(`APA01 source:`,a,`target:`,o),r.debug(`APA01 nodeDb[source]:`,t[a]),r.debug(`APA01 nodeDb[target]:`,t[o]),t[a]&&t[o]&&t[a].parentId!==t[o].parentId){let e=p(a,o,n);Qe(t,a,e,r),Qe(t,o,e,r)}})}r(Ze,`configureCrossHierarchyEdges`);function Qe(e,t,n,r){let i=e[t];i&&(i.layoutOptions??={},i.layoutOptions[`elk.hierarchyHandling`]===`SEPARATE_CHILDREN`&&Te(i.metadata?.algorithm)&&(r.debug(`Dropping explicit algorithm for node`,i.id,`due to cross-boundary edges`),Ce(i.layoutOptions),Object.assign(i.layoutOptions,Oe(i))),i.layoutOptions[`elk.hierarchyHandling`]=`INCLUDE_CHILDREN`,i.id!==n&&i.parentId&&Qe(e,i.parentId,n,r))}r(Qe,`setIncludeChildrenPolicy`);async function $e(e,t,n){let r=globalThis.__mermaidProfiler;try{r?.begin(`layoutCore`);let i;try{i=await e.layout(t)}finally{r?.end()}return n.debug(`APA01 after - success`),n.debug(`APA01 layout result:`,i),i}catch(e){throw n.error(`ELK layout error:`,e),e}}r($e,`runElkLayout`);function et(e,t,n,r){let i=new Map(e.nodes.map(e=>[e.id,e]));it(t.children??[],n,i,0,0,0,r),rt(t.children??[],n,i,t),mt(e,t,n,r)}r(et,`applyElkLayoutResult`);function tt(e,t=new Set){for(let n of e.children??[])t.add(n.id),tt(n,t);return t}r(tt,`collectDescendantIds`);function nt(e,t,n,r){let i=[];for(let a of e.edges??[]){let e=a.sources?.[0]??a.start,o=a.targets?.[0]??a.end,s=t.has(e)&&t.has(o),c=e===r,l=o===r;if(!s&&!c&&!l)continue;let u=_t(e,o,n.parentLookupDb,n.nodeDb);for(let e of a.sections??[]){let t=s?[e.startPoint,...e.bendPoints??[],e.endPoint]:[c?e.startPoint:null,l?e.endPoint:null];for(let e of t)e&&i.push({x:e.x+u.x,y:e.y+u.y})}}return i}r(nt,`internalEdgePoints`);function rt(e,t,n,r={}){for(let i of e){if(!i?.isGroup)continue;let e=i.children??[];rt(e,t,n,r);let a=t.nodeDb[i.id],o=e.map(e=>t.nodeDb[e.id]).filter(e=>e?.offset&&e.width&&e.height);if(!a?.offset||o.length===0)continue;let s=nt(r,tt(i),t,i.id),c=[...o.map(e=>e.offset.posX),...o.map(e=>e.offset.posX+e.width),...s.map(e=>e.x)],l=[...o.map(e=>e.offset.posY),...o.map(e=>e.offset.posY+e.height),...s.map(e=>e.y)],u=a.offset,d=Math.max(u.posX,Math.min(...c)-ge),f=Math.min(u.posX+a.width,Math.max(...c)+ge),p=Math.min(u.posY+a.height,Math.max(...l)+ge),m=u.posY,h=De(i),g=d,_=f-d;if(_{if(!e)return;let s=t.nodeDb[e.id]??e,c=Math.max(e.width,e.labels&&e.labels[0]?.width||0),l={posX:e.x+r,posY:e.y+i,x:r,y:i,depth:a,width:c,height:e.height};s.offset=l,s.x=l.posX+e.width/2,s.y=l.posY+e.height/2,s.width=e.width,s.height=e.height;let u=n.get(e.id);if(u){u.x=s.x,u.y=s.y,u.width=e.isGroup?Math.max(e.width,e.labelData?.width??0):e.width,u.height=e.height;let t=u;t.labelData=e.labelData,t.labels=e.labels}e.isGroup?(o.debug(`Id abc88 subgraph = `,e.id,e.x,e.y,e.labelData),it(e.children??[],t,n,l.posX,l.posY,a+1,o)):o.info(`Id NODE = `,e.id,e.x,e.y,r,i,`translate(${s.x}, ${s.y})`)})}r(it,`applyElkNodePositions`);var at=16,ot=30,st=.01;function ct(e,t){let n=Math.abs(t.x-e.x),r=Math.abs(t.y-e.y);if(n>st&&r<=st)return`h`;if(r>st&&n<=st)return`v`}r(ct,`axisOf`);function lt(e){let t=ut(e)??e,n=ut([...t].reverse());return n&&(t=n.reverse()),t}r(lt,`straightenTerminalJogs`);function ut(e){if(e.length<5)return null;let[t,n,r,i]=e,a=ct(t,n);if(!a||ct(r,i)!==a||ct(n,r)!==(a===`h`?`v`:`h`)||Math.hypot(n.x-t.x,n.y-t.y)>ot)return null;let o=Math.abs(a===`h`?r.y-n.y:r.x-n.x);if(oat||!(a===`h`?Math.sign(n.x-t.x)===Math.sign(i.x-r.x):Math.sign(n.y-t.y)===Math.sign(i.y-r.y)))return null;let s=3;for(;s+1(t.x-e.x)*(n.y-e.y)-(t.y-e.y)*(n.x-e.x),`side`),o=a(n,i,e),s=a(n,i,t),c=a(e,t,n),l=a(e,t,i);return(o>0&&s<0||o<0&&s>0)&&(c>0&&l<0||c<0&&l>0)}r(dt,`segmentsCrossStrict`);function ft(e,t){let n=0;for(let r=0;re.points??[]);for(let[n,r]of e.entries()){let e=t[n];if(e.length<5)continue;let i=lt(e);if(i===e)continue;let a=0,o=0;for(let[r,s]of t.entries())r===n||s.length<2||(a+=ft(e,s),o+=ft(i,s));o>a||(r.points=i,t[n]=i)}}r(pt,`straightenEdgeTerminals`);function mt(e,t,n,i){let a=new Map(e.edges.map(e=>[e.id,e])),o=e.config.elk?.straightenEdges!==!1,s=new Map(e.nodes.map(e=>[e.id,e])),c=new Set;t.edges?.forEach(e=>{if(!e.sections?.length)return;let t=n.nodeDb[e.sources?.[0]??e.start],r=n.nodeDb[e.targets?.[0]??e.end];if(!t||!r)return;let i=_t(e.start??e.sourceId??e.sources?.[0],e.end??e.targetId??e.targets?.[0],n.parentLookupDb,n.nodeDb),a=e.sections[0];t.shape!==`rect33`&&ht(t,{x:a.startPoint.x+i.x,y:a.startPoint.y+i.y},s,c),r.shape!==`rect33`&&ht(r,{x:a.endPoint.x+i.x,y:a.endPoint.y+i.y},s,c)}),t.edges?.forEach(e=>{let t=a.get(e.id);if(!t)return;let o=e.sources?.[0]??e.start,s=e.targets?.[0]??e.end,c=n.nodeDb[o],l=n.nodeDb[s];if(!c||!l)return;if(!e.sections?.length){let n=r(e=>({x:(e.offset?.posX??e.x??0)+(e.width??0)/2,y:(e.offset?.posY??e.y??0)+(e.height??0)/2}),`centre`),a=n(c),o=n(l);c.x=a.x,c.y=a.y,l.x=o.x,l.y=o.y;let s=vt([a,o],c,l,i);t.points=s,t.curve=`linear`;let u=s[0],d=s[s.length-1];t.x=(u.x+d.x)/2,t.y=(u.y+d.y)/2,i.debug(`APA18 no edge sections, using a straight line`,e.id,t.points);return}let u=e.start??e.sourceId??o,d=e.end??e.targetId??s,f=_t(u,d,n.parentLookupDb,n.nodeDb);i.debug(`APA18 offset`,f,u,` ==> `,d,`edge:`,e,c);let p=e.sections[0],m=gt(p,f);c.x=c.offset.posX+c.width/2,c.y=c.offset.posY+c.height/2,l.x=l.offset.posX+l.width/2,l.y=l.offset.posY+l.height/2,c.shape!==`rect33`&&m.unshift({x:c.x,y:c.y}),l.shape!==`rect33`&&m.push({x:l.x,y:l.y}),t.points=Ct(wt(vt(m,c,l,i),jt(l),xt(t),i),jt(c),St(t),i),t.curve=`rounded`;let h=e.labels?.[0];h&&(t.x=h.x+f.x+h.width/2,t.y=h.y+f.y+h.height/2)}),o&&pt(e.edges)}r(mt,`applyElkEdgeLayout`);function ht(e,t,n,r){let i=e.width??0,a=e.height??0,o=e.offset.posY,s=o+a,c=.5,l=Math.abs(t.y-o)<=c||Math.abs(t.y-s)<=c;if((l?i:a)>=2*me||r.has(e.id))return;r.add(e.id);let u=l?t.x-(e.offset.posX+i/2):t.y-(e.offset.posY+a/2);if(Math.abs(u)<.01)return;l?(e.offset.posX+=u,e.x=e.offset.posX+i/2):(e.offset.posY+=u,e.y=e.offset.posY+a/2);let d=n.get(e.id);d&&(d.x=e.offset.posX+i/2,d.y=e.offset.posY+a/2)}r(ht,`alignDegenerateNodeToAnchor`);function gt(e,t){let n=e.startPoint,r=e.endPoint,i=(e.bendPoints?e.bendPoints:[]).map(e=>({x:e.x+t.x,y:e.y+t.y}));return[{x:n.x+t.x,y:n.y+t.y},...i,{x:r.x+t.x,y:r.y+t.y}]}r(gt,`createEdgePointsFromSection`);function _t(e,t,n,r){let i=p(e,t,n);if(i===void 0||i===`root`)return{x:0,y:0};let a=r[i],o=a?.elkOrigin??a?.offset;return{x:o?.posX??0,y:o?.posY??0}}r(_t,`calcOffset`);function vt(e,t,n,r){let i=Array.isArray(e)?[...e]:[],a=jt(n);r.debug(`PPP cutter2: Points before cutter2:`,JSON.stringify(e),`endBounds:`,a,S(a,e[e.length-1]));let o;{let e=jt(t),a=jt(n),s=!!t?.isGroup,c=!!n?.isGroup,{candidate:l,centerApprox:u}=Pt(i,t,`start`),{candidate:d,centerApprox:f}=Pt(i,n,`end`),p=s&&S(e,l),m=c&&S(a,d);Ft(i,`start`,p&&u),Ft(i,`end`,m&&f),s&&!p&&(p=It(i,e,`start`)),c&&!m&&(m=It(i,a,`end`)),p||m?(p||Lt(i,t,e,r),m||Rt(i,n,a,r),r.debug(`PPP cutter2: skipping cutter2 due to on-border group endpoint(s)`,{skipStart:p,skipEnd:m,startCenterApprox:u,endCenterApprox:f,startCandidate:l,endCandidate:d}),o=i):o=Bt(t,n,i,r)}if(r.debug(`PPP cutter2: Points after cutter2:`,JSON.stringify(o)),!Array.isArray(o)||o.length<2||yt(o)){r.warn(`POI cutter2: Invalid points from cutter2, falling back to prevPoints`,o);let e=i.filter(e=>Number.isFinite(e?.x)&&Number.isFinite(e?.y));o=e.length>=2?e:i}return r.debug(`UIO cutter2: Points after cutter2 (sanitized):`,o),bt(o,r)}r(vt,`sanitizeElkEdgePoints`);function yt(e){return e?.some(e=>!Number.isFinite(e?.x)||!Number.isFinite(e?.y))}r(yt,`hasInvalidPoint`);function bt(e,t){let n=e.filter((e,t,n)=>{if(t===0)return!0;let r=n[t-1];return Math.abs(e.x-r.x)>1e-6||Math.abs(e.y-r.y)>1e-6});return n.length!==e.length&&t.debug(`UIO cutter2: removed consecutive duplicate points`,{before:e,after:n}),n}r(bt,`dedupeConsecutivePoints`);function xt(e){return fe(e.arrowTypeEnd)}r(xt,`getEndMarkerPathOffset`);function St(e){return fe(e.arrowTypeStart)}r(St,`getStartMarkerPathOffset`);function Ct(e,t,n,r){if(n<=0||e.length<3)return e;let i=e[0],a=e[1],o=Math.hypot(a.x-i.x,a.y-i.y);if(o>=Math.max(de,n*2)||!S(t,a,1))return e;let s=[i,...e.slice(2)];return r.debug(`UIO cutter2: removed short start marker segment`,{before:e,after:s,markerOffset:n,segmentLength:o}),s}r(Ct,`ensureStartMarkerSegmentLength`);function wt(e,t,n,r){if(n<=0||e.length<3)return e;let i=e[e.length-1],a=e[e.length-2],o=Math.hypot(i.x-a.x,i.y-a.y);if(o>=Math.max(de,n*2)||!S(t,a,1))return e;let s=[...e.slice(0,-2),i];return r.debug(`UIO cutter2: removed short end marker segment`,{before:e,after:s,markerOffset:n,segmentLength:o}),s}r(wt,`ensureEndMarkerSegmentLength`);function Tt(e,t){let n=e.edges.defaultInterpolate,r=e.edges.defaultStyle,i=t.getConfig();e.edges.forEach(e=>{let a=kt(e,{defaultStyle:r,defaultInterpolate:n,confCurve:i.curve},t);Object.assign(e,a)})}r(Tt,`applyElkEdgeRenderData`);function Et(e){if(e.classes!==void 0)return e.classes;if(e.start&&e.end)return`flowchart-link LS_${e.start} LE_${e.end}`}r(Et,`buildFallbackEdgeClasses`);function Dt(e,t,n){let r=`normal`,i=`solid`,a=[],o=[];return e===`dotted`?(i=`dotted`,a=[`fill:none`,`stroke-width:2px`,`stroke-dasharray:3`]):e===`thick`?(r=`thick`,a=[`stroke-width: 3.5px`,`fill:none`]):(a=t??[`fill:none`],n!==void 0&&(o=n)),{thickness:r,pattern:i,style:a,labelStyle:o}}r(Dt,`computeStroke`);function Ot(e,t,n){return e===void 0?t===void 0?n:t:e}r(Ot,`getCurve`);function kt(e,t,n){let r={};r.minlen=e.minlen??e.length??1,r.text=e.text??e.label,r.arrowhead=e.arrowhead??(e.type===`arrow_open`?`none`:`normal`);let i=pe[e.type??`arrow_open`]??pe.arrow_open;r.arrowTypeStart=e.arrowTypeStart??i[0],r.arrowTypeEnd=e.arrowTypeEnd??i[1],r.startLabelRight=e.startLabelRight,r.endLabelLeft=e.endLabelLeft;let o=Dt(e.stroke,t.defaultStyle,t.defaultLabelStyle);r.thickness=e.thickness??o.thickness,r.pattern=e.pattern??o.pattern,r.style=e.style??o.style,r.labelStyle=e.labelStyle??o.labelStyle,r.classes=Et(e),r.curve=n.interpolateToCurve(Ot(e.curve??e.interpolate,t.defaultInterpolate,t.confCurve),a);let s=(r.text??``)!==``;return e.arrowheadStyle===void 0?(s||e.style!==void 0)&&(r.arrowheadStyle=`fill: #333`):r.arrowheadStyle=e.arrowheadStyle,r.labelpos=e.labelpos??(s?`c`:void 0),r.labelType=e.labelType,r.label=(e.label??r.text??``).replace(n.common.lineBreakRegex,` +`),r}r(kt,`buildEdgeData`);function At(e){return Math.max(e.width??0,De(e))}r(At,`getEffectiveGroupWidth`);function jt(e){let t=e?.isGroup?At(e):e.width;return{x:e.offset.posX+e.width/2,y:e.offset.posY+e.height/2,width:t??0,height:e.height??0,padding:e.padding}}r(jt,`boundsFor`);function Mt(e,t,n=1e-6){return Math.abs(e-t)1?e[1]:n,centerApprox:r}}{let n=e[e.length-1],r=Nt(n,t);return{candidate:r&&e.length>1?e[e.length-2]:n,centerApprox:r}}}r(Pt,`getCandidateBorderPoint`);function Ft(e,t,n){n&&(t===`start`?e.length>0&&e.shift():e.length>0&&e.pop())}r(Ft,`dropAutoCenterPoint`);function It(e,t,n){let r=n===`start`?1:-1,i=n===`start`?0:e.length-1,a=i;for(;i>=0&&i=e.length)return!1;let o=e[i],s=e[i-r],c=o.x-s.x,l=o.y-s.y,u=c===0?1/0:(t.x+Math.sign(c)*t.width/2-s.x)/c,d=l===0?1/0:(t.y+Math.sign(l)*t.height/2-s.y)/l,f=Math.min(u,d),p={x:s.x+f*c,y:s.y+f*l};return n===`start`?e.splice(0,i,p):e.splice(i+1,e.length-i-1,p),!0}r(It,`clipGroupEndpoint`);function Lt(e,t,n,r){let i=-1;for(let[t,r]of e.entries())if(te(n,r)){i=t;break}if(i!==-1){let a=e[i],o=e[0],s=le(t,n,a,o);ue(e,`start`,s),r.debug(`UIO cutter2: start-only intersection applied`,{startIntersection:s})}}r(Lt,`applyStartIntersectionIfNeeded`);function Rt(e,t,n,r){let i=-1;for(let t=e.length-1;t>=0;t--)if(te(n,e[t])){i=t;break}if(i!==-1){let a=e[i],o=e[e.length-1],s=le(t,n,a,o);ue(e,`end`,s),r.debug(`UIO cutter2: end-only intersection applied`,{endIntersection:s})}}r(Rt,`applyEndIntersectionIfNeeded`);function zt(e,t,n,r,i){if(e?.isGroup)return null;let a=n[r],o=n[r+i];return!a||!o?null:ce(e,t,a,o)}r(zt,`attachAlongDepartureAxis`);function Bt(e,t,n,r){let i=jt(e),a=jt(t);if(n.length===0)return[];let o=[...n],s=o[0],c=o[o.length-1];r.debug(`PPP cutter2: bounds`,{startBounds:i,endBounds:a}),r.debug(`PPP cutter2: original points`,n);let l=-1;for(let[e,t]of o.entries())l===-1&&te(i,t)&&(l=e);if(l!==-1){let t=o[l],n=zt(e,i,o,l,1)??le(e,i,t,s);r.debug(`UIO cutter2: start intersection`,n),ue(o,`start`,n)}let u=null,d=-1;for(let e=o.length-1;e>=0;e--)if(te(a,o[e])){u=o[e],d=e;break}if(!u&&o.length>1&&(u=o[o.length-2],d=o.length-2),u){let e=zt(t,a,o,d,-1)??le(t,a,u,c);r.debug(`UIO cutter2: end intersection`,{endIntersection:e,outsideIndexForEnd:d}),ue(o,`end`,e)}if(o.length>1){let e=o[o.length-1],t=o[o.length-2],n=Math.sqrt((e.x-t.x)**2+(e.y-t.y)**2);n<2&&(r.debug(`UIO cutter2: trimming tail point (too close)`,{distance:n,lastPoint:e,secondLastPoint:t}),o.pop())}return r.debug(`UIO cutter2: final points`,o),o}r(Bt,`cutter2`);export{Fe as render}; \ No newline at end of file diff --git a/www/assets/erDiagram-OPXOYQCR-YD8i2JM4.js b/www/assets/erDiagram-OPXOYQCR-YD8i2JM4.js new file mode 100644 index 0000000..9314ec0 --- /dev/null +++ b/www/assets/erDiagram-OPXOYQCR-YD8i2JM4.js @@ -0,0 +1,99 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as i,U as a,a as o,ot as s,q as c,s as l,v as u,w as d,x as f,y as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./channel-_oCHZhRo.js";import{c as h,g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{a as _,i as v,o as y,r as b,t as x}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as S,t as C}from"./index-DoQkmpth.js";import{t as w}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as T}from"./chunk-WEXAMYUT-I3m-hOmT.js";var E=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],r=[2,2],i=[1,7],a=[1,9],o=[1,10],s=[1,11],c=[1,12],l=[1,30],u=[1,23],d=[1,24],f=[1,25],p=[1,26],m=[1,27],h=[1,19],g=[1,28],_=[1,29],v=[1,20],y=[1,18],b=[1,21],x=[1,22],S=[2,6],C=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],w=[1,36],T=[1,37],E=[1,38],D=[1,39],O=[1,40],k=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],A=[1,46],j=[1,47],M=[1,57],N=[43,51,53,54,55,74,75],P=[1,70],F=[1,68],I=[1,65],L=[1,69],R=[1,71],z=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],B=[1,78],V=[1,77],H=[1,76],U=[69,70,71,72,73],W=[1,91],G=[6,9,45,50],K=[6,9,12,44,45,50,51,52],q=[1,101],J=[1,100],Y=[1,99],X=[18,61],ee=[1,110],te=[1,109],ne=[20,43,51,53,54,55],Z=[18,61,64,66],Q={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:`error`,4:`ER_DIAGRAM`,6:`EOF`,9:`NEWLINE`,12:`COLON`,14:`STYLE_SEPARATOR`,16:`BLOCK_START`,18:`BLOCK_STOP`,19:`SQS`,20:`SQE`,21:`title`,22:`title_value`,23:`acc_title`,24:`acc_title_value`,25:`acc_descr`,26:`acc_descr_value`,27:`acc_descr_multiline_value`,33:`END`,34:`SUBGRAPH`,37:`direction_tb`,38:`direction_bt`,39:`direction_rl`,40:`direction_lr`,41:`CLASSDEF`,43:`UNICODE_TEXT`,44:`STYLE_TEXT`,45:`COMMA`,46:`CLASS`,47:`STYLE`,50:`SEMI`,51:`NUM`,52:`BRKT`,53:`ENTITY_NAME`,54:`DECIMAL_NUM`,55:`ENTITY_ONE`,61:`ATTRIBUTE_WORD`,62:`?`,64:`,`,65:`ATTRIBUTE_KEY`,66:`COMMENT`,69:`ZERO_OR_ONE`,70:`ZERO_OR_MORE`,71:`ONE_OR_MORE`,72:`ONLY_ONE`,73:`MD_PARENT`,74:`NON_IDENTIFYING`,75:`IDENTIFYING`,76:`WORD`},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:break;case 2:this.$=[];break;case 3:this.$=a[s-1].concat(a[s]);break;case 4:this.$=a[s];break;case 5:case 6:this.$=[];break;case 7:r.addEntity(a[s-4]),r.addEntity(a[s-2]),r.addRelationship(a[s-4],a[s],a[s-2],a[s-3]),this.$=[a[s-4],a[s-2]];break;case 8:r.addEntity(a[s-8]),r.addEntity(a[s-4]),r.addRelationship(a[s-8],a[s],a[s-4],a[s-5]),r.setClass([a[s-8]],a[s-6]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-8],a[s-4]];break;case 9:r.addEntity(a[s-6]),r.addEntity(a[s-2]),r.addRelationship(a[s-6],a[s],a[s-2],a[s-3]),r.setClass([a[s-6]],a[s-4]),this.$=[a[s-6],a[s-2]];break;case 10:r.addEntity(a[s-6]),r.addEntity(a[s-4]),r.addRelationship(a[s-6],a[s],a[s-4],a[s-5]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-6],a[s-4]];break;case 11:r.addEntity(a[s-3]),r.addAttributes(a[s-3],a[s-1]),this.$=[a[s-3]];break;case 12:r.addEntity(a[s-5]),r.addAttributes(a[s-5],a[s-1]),r.setClass([a[s-5]],a[s-3]),this.$=[a[s-5]];break;case 13:r.addEntity(a[s-2]),this.$=[a[s-2]];break;case 14:r.addEntity(a[s-4]),r.setClass([a[s-4]],a[s-2]),this.$=[a[s-4]];break;case 15:r.addEntity(a[s]),this.$=[a[s]];break;case 16:r.addEntity(a[s-2]),r.setClass([a[s-2]],a[s]),this.$=[a[s-2]];break;case 17:r.addEntity(a[s-6],a[s-4]),r.addAttributes(a[s-6],a[s-1]),this.$=[a[s-6]];break;case 18:r.addEntity(a[s-8],a[s-6]),r.addAttributes(a[s-8],a[s-1]),r.setClass([a[s-8]],a[s-3]),this.$=[a[s-8]];break;case 19:r.addEntity(a[s-5],a[s-3]),this.$=[a[s-5]];break;case 20:r.addEntity(a[s-7],a[s-5]),r.setClass([a[s-7]],a[s-2]),this.$=[a[s-7]];break;case 21:r.addEntity(a[s-3],a[s-1]);break;case 22:r.addEntity(a[s-5],a[s-3]),r.setClass([a[s-5]],a[s]);break;case 23:case 24:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 25:case 26:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 27:r.subgraphDepth?this.$=a[s]:(r.setDirection(a[s].value),this.$=[]);break;case 31:r.subgraphDepth=(r.subgraphDepth||1)-1,this.$=r.addSubGraph({text:a[s-2].id},a[s-1],{text:a[s-2].text});break;case 32:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:a[s-1],text:a[s-1]};break;case 33:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:a[s-4],text:a[s-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=a[s];break;case 35:this.$=a[s-1]+` `+a[s];break;case 36:this.$={stmt:`dir`,value:`TB`};break;case 37:this.$={stmt:`dir`,value:`BT`};break;case 38:this.$={stmt:`dir`,value:`RL`};break;case 39:this.$={stmt:`dir`,value:`LR`};break;case 40:this.$=a[s-3],r.addClass(a[s-2],a[s-1]);break;case 41:case 42:case 63:case 72:this.$=[a[s]];break;case 43:case 44:this.$=a[s-2].concat([a[s]]);break;case 45:this.$=a[s-2],r.setClass(a[s-1],a[s]);break;case 46:this.$=a[s-3],r.addCssStyles(a[s-2],a[s-1]);break;case 47:this.$=[a[s]];break;case 48:a[s-2].push(a[s]),this.$=a[s-2];break;case 50:this.$=a[s-1]+a[s];break;case 58:case 84:case 85:this.$=a[s].replace(/"/g,``);break;case 64:a[s].push(a[s-1]),this.$=a[s];break;case 65:this.$={type:a[s-1],name:a[s]};break;case 66:this.$={type:a[s-2],name:a[s-1],keys:a[s]};break;case 67:this.$={type:a[s-2],name:a[s-1],comment:a[s]};break;case 68:this.$={type:a[s-3],name:a[s-2],keys:a[s-1],comment:a[s]};break;case 69:case 71:case 74:this.$=a[s];break;case 70:this.$=a[s-1]+a[s];break;case 73:a[s-2].push(a[s]),this.$=a[s-2];break;case 75:this.$=a[s].replace(/"/g,``);break;case 76:this.$={cardA:a[s],relType:a[s-1],cardB:a[s-2]};break;case 77:this.$=r.Cardinality.ZERO_OR_ONE;break;case 78:this.$=r.Cardinality.ZERO_OR_MORE;break;case 79:this.$=r.Cardinality.ONE_OR_MORE;break;case 80:this.$=r.Cardinality.ONLY_ONE;break;case 81:this.$=r.Cardinality.MD_PARENT;break;case 82:this.$=r.Identification.NON_IDENTIFYING;break;case 83:this.$=r.Identification.IDENTIFYING}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(t,r,{5:3}),{6:[1,4],7:5,8:6,9:i,10:8,21:a,23:o,25:s,27:c,28:13,29:14,30:15,31:16,32:17,34:l,37:u,38:d,39:f,40:p,41:m,43:h,46:g,47:_,51:v,53:y,54:b,55:x},e(t,S,{1:[2,1]}),e(C,[2,3]),e(C,[2,4]),e(C,[2,5]),e(C,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:w,70:T,71:E,72:D,73:O}),{22:[1,41]},{24:[1,42]},{26:[1,43]},e(C,[2,26]),e(C,[2,27]),e(C,[2,28]),e(C,[2,29]),e(C,[2,30]),e(C,r,{5:44}),e(k,[2,58]),e(k,[2,59]),e(k,[2,60]),e(k,[2,61]),e(k,[2,62]),e(C,[2,36]),e(C,[2,37]),e(C,[2,38]),e(C,[2,39]),{15:45,43:A,44:j},{15:48,43:A,44:j},{15:49,43:A,44:j},{10:50,43:h,51:v,53:y,54:b,55:x},{10:51,43:h,51:v,53:y,54:b,55:x},{15:52,43:A,44:j},{17:53,18:[1,54],56:55,57:56,61:M},{10:58,43:h,51:v,53:y,54:b,55:x},{68:59,74:[1,60],75:[1,61]},e(N,[2,77]),e(N,[2,78]),e(N,[2,79]),e(N,[2,80]),e(N,[2,81]),e(C,[2,23]),e(C,[2,24]),e(C,[2,25]),{6:[1,63],7:5,8:6,9:i,10:8,21:a,23:o,25:s,27:c,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:l,37:u,38:d,39:f,40:p,41:m,43:h,46:g,47:_,51:v,53:y,54:b,55:x},{12:P,42:64,44:F,45:I,48:66,49:67,51:L,52:R},e(z,[2,41]),e(z,[2,42]),{15:72,43:A,44:j,45:I},{12:P,42:73,44:F,45:I,48:66,49:67,51:L,52:R},{6:B,9:V,19:[1,75],35:74,50:H},{12:[1,79],14:[1,80]},e(C,[2,16],{67:35,11:81,16:[1,82],45:I,69:w,70:T,71:E,72:D,73:O}),{18:[1,83]},e(C,[2,13]),{17:84,18:[2,63],56:55,57:56,61:M},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:w,70:T,71:E,72:D,73:O},e(U,[2,82]),e(U,[2,83]),e(C,[2,31]),e(C,S),{6:B,9:V,35:90,45:W,50:H},{43:[1,92],44:[1,93]},e(G,[2,47],{49:94,12:P,44:F,51:L,52:R}),e(K,[2,49]),e(K,[2,54]),e(K,[2,55]),e(K,[2,56]),e(K,[2,57]),e(C,[2,45],{45:I}),{6:B,9:V,35:95,45:W,50:H},e(C,[2,32]),{10:97,36:96,43:h,51:v,53:y,54:b,55:x},e(C,[2,51]),e(C,[2,52]),e(C,[2,53]),{13:98,43:q,53:J,76:Y},{15:102,43:A,44:j},{10:103,43:h,51:v,53:y,54:b,55:x},{17:104,18:[1,105],56:55,57:56,61:M},e(C,[2,11]),{18:[2,64]},e(X,[2,65],{59:106,60:107,63:108,65:ee,66:te}),e([18,61,65,66],[2,71]),{61:[2,70]},e(C,[2,21],{14:[1,112],16:[1,111]}),e([43,51,53,54,55],[2,76]),e(C,[2,40]),{12:P,44:F,48:113,49:67,51:L,52:R},e(z,[2,43]),e(z,[2,44]),e(K,[2,50]),e(C,[2,46]),{10:115,20:[1,114],43:h,51:v,53:y,54:b,55:x},e(ne,[2,34]),e(C,[2,7]),e(C,[2,84]),e(C,[2,85]),e(C,[2,86]),{12:[1,116],45:I},{12:[1,118],14:[1,117]},{18:[1,119]},e(C,[2,14]),e(X,[2,66],{60:120,64:[1,121],66:te}),e(X,[2,67]),e(Z,[2,72]),e(X,[2,75]),e(Z,[2,74]),{17:122,18:[1,123],56:55,57:56,61:M},{15:124,43:A,44:j},e(G,[2,48],{49:94,12:P,44:F,51:L,52:R}),{6:B,9:V,35:125,50:H},e(ne,[2,35]),{13:126,43:q,53:J,76:Y},{15:127,43:A,44:j},{13:128,43:q,53:J,76:Y},e(C,[2,12]),e(X,[2,68]),{63:129,65:ee},{18:[1,130]},e(C,[2,19]),e(C,[2,22],{16:[1,131],45:I}),e(C,[2,33]),e(C,[2,10]),{12:[1,132],45:I},e(C,[2,9]),e(Z,[2,73]),e(C,[2,17]),{17:133,18:[1,134],56:55,57:56,61:M},{13:135,43:q,53:J,76:Y},{18:[1,136]},e(C,[2,20]),e(C,[2,8]),e(C,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};Q.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:return this.begin(`acc_title`),23;case 1:return this.popState(),`acc_title_value`;case 2:return this.begin(`acc_descr`),25;case 3:return this.popState(),`acc_descr_value`;case 4:this.begin(`acc_descr_multiline`);break;case 5:this.popState();break;case 6:return`acc_descr_multiline_value`;case 7:return 37;case 8:return 38;case 9:return 39;case 10:return 40;case 11:break;case 12:return 9;case 13:return 53;case 14:return 76;case 15:return 4;case 16:return this.begin(`block`),16;case 17:return 52;case 18:return 52;case 19:return 45;case 20:return 14;case 21:return 12;case 22:break;case 23:return 65;case 24:return 61;case 25:return 61;case 26:this.begin(`block_bq`);break;case 27:return 61;case 28:this.popState();break;case 29:return 66;case 30:break;case 31:return this.popState(),18;case 32:return t.yytext[0];case 33:return 19;case 34:return 20;case 35:return this.begin(`style`),47;case 36:return this.popState(),9;case 37:break;case 38:return 12;case 39:return 45;case 40:return 52;case 41:return this.begin(`style`),41;case 42:return 46;case 43:return 34;case 44:return 33;case 45:return 69;case 46:return 71;case 47:return 71;case 48:return 71;case 49:return 69;case 50:return 69;case 51:return 70;case 52:return 70;case 53:return 70;case 54:return 70;case 55:return 70;case 56:return 71;case 57:return 70;case 58:return 71;case 59:return 72;case 60:return 72;case 61:return 54;case 62:return 72;case 63:return 72;case 64:return 72;case 65:return 55;case 66:return 51;case 67:return 72;case 68:return 69;case 69:return 70;case 70:return 71;case 71:return 73;case 72:return 74;case 73:return 75;case 74:return 75;case 75:return 74;case 76:return 74;case 77:return 74;case 78:return 44;case 79:return 50;case 80:return 43;case 81:return t.yytext[0];case 82:return 6}},`anonymous`),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[ \t\r]+)/i,/^(?:[\n]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:subgraph\b)/i,/^(?:end\b\s*)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[36,37,38,39,40,78,79],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[27,28],inclusive:!1},block:{rules:[22,23,24,25,26,29,30,31,32],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,33,34,35,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,80,81,82],inclusive:!0}}}})();function $(){this.yy={}}return n($,`Parser`),$.prototype=Q,Q.Parser=$,new $})();E.parser=E;var D=E,O=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.subgraphDepth=0,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.direction=`TB`,this.Cardinality={ZERO_OR_ONE:`ZERO_OR_ONE`,ZERO_OR_MORE:`ZERO_OR_MORE`,ONE_OR_MORE:`ONE_OR_MORE`,ONLY_ONE:`ONLY_ONE`,MD_PARENT:`MD_PARENT`},this.Identification={NON_IDENTIFYING:`NON_IDENTIFYING`,IDENTIFYING:`IDENTIFYING`},this.setAccTitle=a,this.getAccTitle=p,this.setAccDescription=i,this.getAccDescription=u,this.setDiagramTitle=c,this.getDiagramTitle=d,this.getConfig=n(()=>f().er,`getConfig`),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this),this.addSubGraph=this.addSubGraph.bind(this)}static{n(this,`ErDB`)}addEntity(t,n=``){return this.entities.has(t)?!this.entities.get(t)?.alias&&n&&(this.entities.get(t).alias=n,e.info(`Add alias '${n}' to entity '${t}'`)):(this.entities.set(t,{id:`entity-${t}-${this.entities.size}`,label:t,attributes:[],alias:n,shape:`erBox`,look:f().look??`default`,cssClasses:`default`,cssStyles:[],labelType:`markdown`}),e.info(`Added new entity :`,t)),this.entities.get(t)}getEntity(e){return this.entities.get(e)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(t,n){let r=this.addEntity(t),i;for(i=n.length-1;i>=0;i--)n[i].keys||(n[i].keys=[]),n[i].comment||(n[i].comment=``),r.attributes.push(n[i]),e.debug(`Added attribute `,n[i].name)}addRelationship(t,n,r,i){let a;if(this.subGraphLookup.has(t))a=t;else{let e=this.addEntity(t);if(!e)return;a=e.id}let o;if(this.subGraphLookup.has(r))o=r;else{let e=this.addEntity(r);if(!e)return;o=e.id}let s={entityA:a,roleA:n,entityB:o,relSpec:i};this.relationships.push(s),e.debug(`Added new relationship :`,s)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(e){this.direction=e}getCompiledStyles(e){let t=[];for(let n of e){let e=this.classes.get(n);e?.styles&&(t=[...t,...e.styles??[]].map(e=>e.trim())),e?.textStyles&&(t=[...t,...e.textStyles??[]].map(e=>e.trim()))}return t}addCssStyles(e,t){for(let n of e){let e=this.entities.get(n),r=this.subGraphLookup.get(n);if(t){if(e)for(let n of t)e.cssStyles.push(n);if(r){r.cssStyles||=[];for(let e of t)r.cssStyles.push(e)}}}}addClass(e,t){e.forEach(e=>{let n=this.classes.get(e);n===void 0&&(n={id:e,styles:[],textStyles:[]},this.classes.set(e,n)),t&&t.forEach(function(e){if(/color/.exec(e)){let t=e.replace(`fill`,`bgFill`);n.textStyles.push(t)}n.styles.push(e)})})}addSubGraph(t,r,i){let a=t.text.trim(),o=i.text,s=n(e=>{let t=new Set,n;return{nodeList:e.filter(e=>{if(e?.stmt)return e.stmt===`dir`&&(n=e.value),!1;if(typeof e!=`string`)return!1;let r=e.trim();return!r||t.has(r)?!1:(t.add(r),!0)}),dir:n}},`uniq`)(r.flat()),c=s.nodeList,l=s.dir;a??=`subGraph`+this.subCount,o||=``,o=this.sanitizeText(o),this.subCount+=1;let u={id:a,nodes:c,title:o.trim(),classes:[],cssStyles:[],dir:l,labelType:this.sanitizeNodeLabelType(i?.type)};return e.info(`Adding`,u.id,u.nodes,u.dir),u.nodes=this.makeUniq(u,this.subGraphs).nodes,this.subGraphs.push(u),this.subGraphLookup.set(a,u),a}getSubGraphs(){return this.subGraphs}setClass(e,t){for(let n of e){let e=this.entities.get(n);if(e)for(let n of t)e.cssClasses+=` `+n;let r=this.subGraphLookup.get(n);if(r)for(let e of t)r.classes.push(e)}}subgraphNodeCache(e){let t=new Set;for(let n of e)for(let e of n.nodes)t.add(e);return t}makeUniq(t,n){let r=this.subgraphNodeCache(n),i=[];return t.nodes.forEach((n,a)=>{r.has(n)?e.warn(`Entity '${n}' already belongs to another subgraph and will be ignored`):i.push(t.nodes[a])}),{nodes:i}}sanitizeText(e){return l.sanitizeText(e,f())}sanitizeNodeLabelType(e){switch(e){case`markdown`:case`string`:case`text`:return e;default:return`markdown`}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.subgraphDepth=0,o()}getData(){let e=[],t=[],n=f(),r=this.getSubGraphs(),i=new Map,a=new Map;for(let e=r.length-1;e>=0;e--){let t=r[e];t.nodes.length>0&&a.set(t.id,!0);for(let e of t.nodes)i.set(e,t.id)}for(let t=r.length-1;t>=0;t--){let a=r[t];e.push({id:a.id,label:a.title,labelStyle:``,labelType:a.labelType,parentId:i.get(a.id),padding:8,cssCompiledStyles:this.getCompiledStyles(a.classes),cssStyles:a.cssStyles,cssClasses:a.classes.join(` `),shape:`rect`,dir:a.dir,isGroup:!0,look:n.look})}let o=new Set(r.map(e=>e.id)),s=0;for(let t of this.entities.keys()){if(o.has(t))continue;let n=this.entities.get(t);n&&(n.cssCompiledStyles=this.getCompiledStyles(n.cssClasses.split(` `)),n.colorIndex=s++,e.push({...n,parentId:i.get(t),isGroup:!1}))}let c=0;for(let e of this.relationships){let r={id:h(e.entityA,e.entityB,{prefix:`id`,counter:c++}),type:`normal`,curve:`basis`,start:e.entityA,end:e.entityB,label:e.roleA,labelpos:`c`,thickness:`normal`,classes:`relationshipLine`,arrowTypeStart:e.relSpec.cardB.toLowerCase(),arrowTypeEnd:e.relSpec.cardA.toLowerCase(),pattern:e.relSpec.relType==`IDENTIFYING`?`solid`:`dashed`,look:n.look,labelType:`markdown`};t.push(r)}return{nodes:e,edges:t,other:{},config:n,direction:this.direction}}},k={};r(k,{draw:()=>A});var A=n(async function(n,r,i,a){e.info(`REF0:`),e.info(`Drawing er diagram (unified)`,r);let{securityLevel:o,er:s,layout:c}=f(),l=a.db.getData(),u=w(r,o);l.type=a.type,l.layoutAlgorithm=C(c),l.config.flowchart.nodeSpacing=s?.nodeSpacing||140,l.config.flowchart.rankSpacing=s?.rankSpacing||80,l.direction=a.db.getDirection();let{config:d}=l,{look:p}=d;l.markers=p===`neo`?[`only_one_neo`,`zero_or_one_neo`,`one_or_more_neo`,`zero_or_more_neo`]:[`only_one`,`zero_or_one`,`one_or_more`,`zero_or_more`],l.diagramId=r,await S(l,u);let m=u.selectAll(`[id*="-background"]`);Array.from(m).length>0&&m.each(function(){let e=t(this),n=e.attr(`id`).replace(`-background`,``),r=u.select(`#${CSS.escape(n)}`);if(!r.empty()){let t=r.attr(`transform`);e.attr(`transform`,t)}}),g.insertTitle(u,`erDiagramTitleText`,s?.titleTopMargin??25,a.db.getDiagramTitle()),T(u,8,`erDiagram`,s?.useMaxWidth??!0)},`draw`),j=n((e,t)=>{let n=m,r=n(e,`r`),i=n(e,`g`),a=n(e,`b`);return s(r,i,a,t)},`fade`),M=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!v(t,r))return``;let i=y(e.look),a=b(n),o=``;for(let e=0;e<_(r);e++){let t=r[e],s=a?`fill: ${n[e%n.length]};`:``;o+=` + + [data-look="${i}"][data-color-id="color-${e}"].node path { + stroke: ${t}; + ${s} + } + + [data-look="${i}"][data-color-id="color-${e}"].node rect { + stroke: ${t}; + ${s} + } + `}return o},`genColor`),N={parser:D,get db(){return new O},renderer:k,styles:n(e=>{let{look:t,theme:n,erEdgeLabelBackground:r,strokeWidth:i}=e;return` + ${M(e)} + .entityBox { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + } + + .relationshipLabelBox { + fill: ${e.tertiaryColor}; + opacity: 0.7; + background-color: ${e.tertiaryColor}; + rect { + opacity: 0.5; + } + } + + .labelBkg { + background-color: ${x.has(n)&&r?r:j(e.tertiaryColor,.5)}; + } + + .edgeLabel { + background-color: ${x.has(n)&&r?r:e.edgeLabelBackground}; + } + .edgeLabel .label rect { + fill: ${x.has(n)&&r?r:e.edgeLabelBackground}; + } + .edgeLabel .label text { + fill: ${e.textColor}; + } + + .edgeLabel .label { + fill: ${e.nodeBorder}; + font-size: 14px; + } + + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + + .edge-pattern-dashed { + stroke-dasharray: 8,8; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon + { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: ${t===`neo`?i:`1px`}; + } + + .relationshipLine { + stroke: ${e.lineColor}; + stroke-width: ${t===`neo`?i:`1px`}; + fill: none; + } + + .marker { + fill: none !important; + stroke: ${e.lineColor} !important; + stroke-width: 1; + } + [data-look=neo].labelBkg { + background-color: ${j(e.tertiaryColor,.5)}; + } + + .cluster rect { + fill: ${e.clusterBkg??e.mainBkg}; + stroke: ${e.clusterBorder??e.nodeBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor??e.textColor}; + } + + .cluster-label text { + fill: ${e.titleColor??e.textColor}; + } +`},`getStyles`)};export{N as diagram}; \ No newline at end of file diff --git a/www/assets/eventmodeling-NTZA5JFV-CetGhGTA.js b/www/assets/eventmodeling-NTZA5JFV-CetGhGTA.js new file mode 100644 index 0000000..8d0a5c9 --- /dev/null +++ b/www/assets/eventmodeling-NTZA5JFV-CetGhGTA.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{O as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createEventModelingServices}; \ No newline at end of file diff --git a/www/assets/flowDiagram-KWPJA3E3-BO7njBlM.js b/www/assets/flowDiagram-KWPJA3E3-BO7njBlM.js new file mode 100644 index 0000000..65689a0 --- /dev/null +++ b/www/assets/flowDiagram-KWPJA3E3-BO7njBlM.js @@ -0,0 +1 @@ +import"./src-D_iIdUkB.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import"./chunk-GWA4HPMP-C1P4FmAY.js";import"./chunk-XXDRQBXY-C1_eEj17.js";import"./chunk-WEXAMYUT-I3m-hOmT.js";import{n as e}from"./chunk-7M6MHVWA-ZnPgs1Wx.js";export{e as diagram}; \ No newline at end of file diff --git a/www/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js b/www/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js new file mode 100644 index 0000000..b28dee7 --- /dev/null +++ b/www/assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js @@ -0,0 +1,292 @@ +import{_ as e,a as t,c as n,d as r,f as i,g as a,i as o,m as s,p as c,s as l,u,y as d}from"./src-D_iIdUkB.js";import{n as f}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as p,U as m,a as h,c as g,q as _,s as v,v as y,w as b,x,y as S}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{a as C,i as w,n as T,r as E,t as D}from"./linear-CZ6dxGrP.js";import{t as O}from"./init-C-OQMol4.js";import{t as k}from"./dist-Bfr8PhAA.js";import{g as ee}from"./chunk-ZIGJFQKS-BJ6myxnF.js";function A(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function te(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function ne(e){return e}var j=1,re=2,ie=3,ae=4,oe=1e-6;function se(e){return`translate(`+e+`,0)`}function ce(e){return`translate(0,`+e+`)`}function le(e){return t=>+e(t)}function ue(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function de(){return!this.__axis}function fe(e,t){var n=[],r=null,i=null,a=6,o=6,s=3,c=typeof window<`u`&&window.devicePixelRatio>1?0:.5,l=e===j||e===ae?-1:1,u=e===ae||e===re?`x`:`y`,d=e===j||e===ie?se:ce;function f(f){var p=r??(t.ticks?t.ticks.apply(t,n):t.domain()),m=i??(t.tickFormat?t.tickFormat.apply(t,n):ne),h=Math.max(a,0)+s,g=t.range(),_=+g[0]+c,v=+g[g.length-1]+c,y=(t.bandwidth?ue:le)(t.copy(),c),b=f.selection?f.selection():f,x=b.selectAll(`.domain`).data([null]),S=b.selectAll(`.tick`).data(p,t).order(),C=S.exit(),w=S.enter().append(`g`).attr(`class`,`tick`),T=S.select(`line`),E=S.select(`text`);x=x.merge(x.enter().insert(`path`,`.tick`).attr(`class`,`domain`).attr(`stroke`,`currentColor`)),S=S.merge(w),T=T.merge(w.append(`line`).attr(`stroke`,`currentColor`).attr(u+`2`,l*a)),E=E.merge(w.append(`text`).attr(`fill`,`currentColor`).attr(u,l*h).attr(`dy`,e===j?`0em`:e===ie?`0.71em`:`0.32em`)),f!==b&&(x=x.transition(f),S=S.transition(f),T=T.transition(f),E=E.transition(f),C=C.transition(f).attr(`opacity`,oe).attr(`transform`,function(e){return isFinite(e=y(e))?d(e+c):this.getAttribute(`transform`)}),w.attr(`opacity`,oe).attr(`transform`,function(e){var t=this.parentNode.__axis;return d((t&&isFinite(t=t(e))?t:y(e))+c)})),C.remove(),x.attr(`d`,e===ae||e===re?o?`M`+l*o+`,`+_+`H`+c+`V`+v+`H`+l*o:`M`+c+`,`+_+`V`+v:o?`M`+_+`,`+l*o+`V`+c+`H`+v+`V`+l*o:`M`+_+`,`+c+`H`+v),S.attr(`opacity`,1).attr(`transform`,function(e){return d(y(e)+c)}),T.attr(u+`2`,l*a),E.attr(u,l*h).text(m),b.filter(de).attr(`fill`,`none`).attr(`font-size`,10).attr(`font-family`,`sans-serif`).attr(`text-anchor`,e===re?`start`:e===ae?`end`:`middle`),b.each(function(){this.__axis=y})}return f.scale=function(e){return arguments.length?(t=e,f):t},f.ticks=function(){return n=Array.from(arguments),f},f.tickArguments=function(e){return arguments.length?(n=e==null?[]:Array.from(e),f):n.slice()},f.tickValues=function(e){return arguments.length?(r=e==null?null:Array.from(e),f):r&&r.slice()},f.tickFormat=function(e){return arguments.length?(i=e,f):i},f.tickSize=function(e){return arguments.length?(a=o=+e,f):a},f.tickSizeInner=function(e){return arguments.length?(a=+e,f):a},f.tickSizeOuter=function(e){return arguments.length?(o=+e,f):o},f.tickPadding=function(e){return arguments.length?(s=+e,f):s},f.offset=function(e){return arguments.length?(c=+e,f):c},f}function pe(e){return fe(j,e)}function me(e){return fe(ie,e)}var he=Math.PI/180,ge=180/Math.PI,_e=18,ve=.96422,ye=1,be=.82521,xe=4/29,Se=6/29,Ce=3*Se*Se,we=Se*Se*Se;function Te(e){if(e instanceof M)return new M(e.l,e.a,e.b,e.opacity);if(e instanceof N)return Ne(e);e instanceof n||(e=u(e));var t=Ae(e.r),r=Ae(e.g),i=Ae(e.b),a=De((.2225045*t+.7168786*r+.0606169*i)/ye),o,s;return t===r&&r===i?o=s=a:(o=De((.4360747*t+.3850649*r+.1430804*i)/ve),s=De((.0139322*t+.0971045*r+.7141733*i)/be)),new M(116*a-16,500*(o-a),200*(a-s),e.opacity)}function Ee(e,t,n,r){return arguments.length===1?Te(e):new M(e,t,n,r??1)}function M(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}r(M,Ee,i(l,{brighter(e){return new M(this.l+_e*(e??1),this.a,this.b,this.opacity)},darker(e){return new M(this.l-_e*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,r=isNaN(this.b)?e:e-this.b/200;return t=ve*Oe(t),e=ye*Oe(e),r=be*Oe(r),new n(ke(3.1338561*t-1.6168667*e-.4906146*r),ke(-.9787684*t+1.9161415*e+.033454*r),ke(.0719453*t-.2289914*e+1.4052427*r),this.opacity)}}));function De(e){return e>we?e**(1/3):e/Ce+xe}function Oe(e){return e>Se?e*e*e:Ce*(e-xe)}function ke(e){return 255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055)}function Ae(e){return(e/=255)<=.04045?e/12.92:((e+.055)/1.055)**2.4}function je(e){if(e instanceof N)return new N(e.h,e.c,e.l,e.opacity);if(e instanceof M||(e=Te(e)),e.a===0&&e.b===0)return new N(NaN,0(e(t=new Date(+t)),t),i.ceil=n=>(e(n=new Date(n-1)),t(n,1),e(n),n),i.round=e=>{let t=i(e),n=i.ceil(e);return e-t(t(e=new Date(+e),n==null?1:Math.floor(n)),e),i.range=(n,r,a)=>{let o=[];if(n=i.ceil(n),a=a==null?1:Math.floor(a),!(n0))return o;let s;do o.push(s=new Date(+n)),t(n,a),e(n);while(sP(t=>{if(t>=t)for(;e(t),!n(t);)t.setTime(t-1)},(e,r)=>{if(e>=e){if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}}),n&&(i.count=(t,r)=>(Le.setTime(+t),Re.setTime(+r),e(Le),e(Re),Math.floor(n(Le,Re))),i.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?i.filter(r?t=>r(t)%e===0:t=>i.count(0,t)%e===0):i)),i}var ze=P(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);ze.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?P(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):ze),ze.range;var F=1e3,I=F*60,L=I*60,R=L*24,Be=R*7,Ve=R*30,He=R*365,z=P(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*F)},(e,t)=>(t-e)/F,e=>e.getUTCSeconds());z.range;var Ue=P(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*F)},(e,t)=>{e.setTime(+e+t*I)},(e,t)=>(t-e)/I,e=>e.getMinutes());Ue.range;var We=P(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*I)},(e,t)=>(t-e)/I,e=>e.getUTCMinutes());We.range;var Ge=P(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*F-e.getMinutes()*I)},(e,t)=>{e.setTime(+e+t*L)},(e,t)=>(t-e)/L,e=>e.getHours());Ge.range;var Ke=P(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*L)},(e,t)=>(t-e)/L,e=>e.getUTCHours());Ke.range;var B=P(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*I)/R,e=>e.getDate()-1);B.range;var qe=P(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/R,e=>e.getUTCDate()-1);qe.range;var Je=P(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/R,e=>Math.floor(e/R));Je.range;function V(e){return P(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(e,t)=>{e.setDate(e.getDate()+t*7)},(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*I)/Be)}var Ye=V(0),Xe=V(1),Ze=V(2),Qe=V(3),H=V(4),$e=V(5),et=V(6);Ye.range,Xe.range,Ze.range,Qe.range,H.range,$e.range,et.range;function U(e){return P(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t*7)},(e,t)=>(t-e)/Be)}var tt=U(0),nt=U(1),rt=U(2),it=U(3),at=U(4),ot=U(5),st=U(6);tt.range,nt.range,rt.range,it.range,at.range,ot.range,st.range;var ct=P(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());ct.range;var lt=P(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());lt.range;var W=P(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());W.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:P(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),W.range;var G=P(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());G.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:P(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),G.range;function ut(e,t,n,r,i,a){let o=[[z,1,F],[z,5,5*F],[z,15,15*F],[z,30,30*F],[a,1,I],[a,5,5*I],[a,15,15*I],[a,30,30*I],[i,1,L],[i,3,3*L],[i,6,6*L],[i,12,12*L],[r,1,R],[r,2,2*R],[n,1,Be],[t,1,Ve],[t,3,3*Ve],[e,1,He]];function s(e,t,n){let r=te).right(o,i);if(a===o.length)return e.every(w(t/He,n/He,r));if(a===0)return ze.every(Math.max(w(t,n,r),1));let[s,c]=o[i/o[a-1][2]53)return null;`w`in r||(r.w=1),`Z`in r?(a=gt(_t(r.y,0,1)),o=a.getUTCDay(),a=o>4||o===0?nt.ceil(a):nt(a),a=qe.offset(a,(r.V-1)*7),r.y=a.getUTCFullYear(),r.m=a.getUTCMonth(),r.d=a.getUTCDate()+(r.w+6)%7):(a=ht(_t(r.y,0,1)),o=a.getDay(),a=o>4||o===0?Xe.ceil(a):Xe(a),a=B.offset(a,(r.V-1)*7),r.y=a.getFullYear(),r.m=a.getMonth(),r.d=a.getDate()+(r.w+6)%7)}else(`W`in r||`U`in r)&&(`w`in r||(r.w=`u`in r?r.u%7:+(`W`in r)),o=`Z`in r?gt(_t(r.y,0,1)).getUTCDay():ht(_t(r.y,0,1)).getDay(),r.m=0,r.d=`W`in r?(r.w+6)%7+r.W*7-(o+5)%7:r.w+r.U*7-(o+6)%7);return`Z`in r?(r.H+=r.Z/100|0,r.M+=r.Z%100,gt(r)):ht(r)}}function w(e,t,n,r){for(var i=0,a=t.length,o=n.length,s,c;i=o)return-1;if(s=t.charCodeAt(i++),s===37){if(s=t.charAt(i++),c=x[s in yt?t.charAt(i++):s],!c||(r=c(e,n,r))<0)return-1}else if(s!=n.charCodeAt(r++))return-1}return r}function T(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1}function E(e,t,n){var r=p.exec(t.slice(n));return r?(e.w=m.get(r[0].toLowerCase()),n+r[0].length):-1}function D(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f.get(r[0].toLowerCase()),n+r[0].length):-1}function O(e,t,n){var r=_.exec(t.slice(n));return r?(e.m=v.get(r[0].toLowerCase()),n+r[0].length):-1}function k(e,t,n){var r=h.exec(t.slice(n));return r?(e.m=g.get(r[0].toLowerCase()),n+r[0].length):-1}function ee(e,n,r){return w(e,t,n,r)}function A(e,t,r){return w(e,n,t,r)}function te(e,t,n){return w(e,r,t,n)}function ne(e){return o[e.getDay()]}function j(e){return a[e.getDay()]}function re(e){return c[e.getMonth()]}function ie(e){return s[e.getMonth()]}function ae(e){return i[+(e.getHours()>=12)]}function oe(e){return 1+~~(e.getMonth()/3)}function se(e){return o[e.getUTCDay()]}function ce(e){return a[e.getUTCDay()]}function le(e){return c[e.getUTCMonth()]}function ue(e){return s[e.getUTCMonth()]}function de(e){return i[+(e.getUTCHours()>=12)]}function fe(e){return 1+~~(e.getUTCMonth()/3)}return{format:function(e){var t=S(e+=``,y);return t.toString=function(){return e},t},parse:function(e){var t=C(e+=``,!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=S(e+=``,b);return t.toString=function(){return e},t},utcParse:function(e){var t=C(e+=``,!0);return t.toString=function(){return e},t}}}var yt={"-":``,_:` `,0:`0`},K=/^\s*\d+/,bt=/^%/,xt=/[\\^$*+?|[\]().{}]/g;function q(e,t,n){var r=e<0?`-`:``,i=(r?-e:e)+``,a=i.length;return r+(a[e.toLowerCase(),t]))}function Tt(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Et(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function Dt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function Ot(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function kt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function At(e,t,n){var r=K.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function jt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Mt(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||`00`)),n+r[0].length):-1}function Nt(e,t,n){var r=K.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function Pt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Ft(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function It(e,t,n){var r=K.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Lt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Rt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function zt(e,t,n){var r=K.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Bt(e,t,n){var r=K.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Vt(e,t,n){var r=K.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ht(e,t,n){var r=bt.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Ut(e,t,n){var r=K.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function Wt(e,t,n){var r=K.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Gt(e,t){return q(e.getDate(),t,2)}function Kt(e,t){return q(e.getHours(),t,2)}function qt(e,t){return q(e.getHours()%12||12,t,2)}function Jt(e,t){return q(1+B.count(W(e),e),t,3)}function Yt(e,t){return q(e.getMilliseconds(),t,3)}function Xt(e,t){return Yt(e,t)+`000`}function Zt(e,t){return q(e.getMonth()+1,t,2)}function Qt(e,t){return q(e.getMinutes(),t,2)}function $t(e,t){return q(e.getSeconds(),t,2)}function en(e){var t=e.getDay();return t===0?7:t}function tn(e,t){return q(Ye.count(W(e)-1,e),t,2)}function nn(e){var t=e.getDay();return t>=4||t===0?H(e):H.ceil(e)}function rn(e,t){return e=nn(e),q(H.count(W(e),e)+(W(e).getDay()===4),t,2)}function an(e){return e.getDay()}function on(e,t){return q(Xe.count(W(e)-1,e),t,2)}function sn(e,t){return q(e.getFullYear()%100,t,2)}function cn(e,t){return e=nn(e),q(e.getFullYear()%100,t,2)}function ln(e,t){return q(e.getFullYear()%1e4,t,4)}function un(e,t){var n=e.getDay();return e=n>=4||n===0?H(e):H.ceil(e),q(e.getFullYear()%1e4,t,4)}function dn(e){var t=e.getTimezoneOffset();return(t>0?`-`:(t*=-1,`+`))+q(t/60|0,`0`,2)+q(t%60,`0`,2)}function fn(e,t){return q(e.getUTCDate(),t,2)}function pn(e,t){return q(e.getUTCHours(),t,2)}function mn(e,t){return q(e.getUTCHours()%12||12,t,2)}function hn(e,t){return q(1+qe.count(G(e),e),t,3)}function gn(e,t){return q(e.getUTCMilliseconds(),t,3)}function _n(e,t){return gn(e,t)+`000`}function vn(e,t){return q(e.getUTCMonth()+1,t,2)}function yn(e,t){return q(e.getUTCMinutes(),t,2)}function bn(e,t){return q(e.getUTCSeconds(),t,2)}function xn(e){var t=e.getUTCDay();return t===0?7:t}function Sn(e,t){return q(tt.count(G(e)-1,e),t,2)}function Cn(e){var t=e.getUTCDay();return t>=4||t===0?at(e):at.ceil(e)}function wn(e,t){return e=Cn(e),q(at.count(G(e),e)+(G(e).getUTCDay()===4),t,2)}function Tn(e){return e.getUTCDay()}function En(e,t){return q(nt.count(G(e)-1,e),t,2)}function Dn(e,t){return q(e.getUTCFullYear()%100,t,2)}function On(e,t){return e=Cn(e),q(e.getUTCFullYear()%100,t,2)}function kn(e,t){return q(e.getUTCFullYear()%1e4,t,4)}function An(e,t){var n=e.getUTCDay();return e=n>=4||n===0?at(e):at.ceil(e),q(e.getUTCFullYear()%1e4,t,4)}function jn(){return`+0000`}function Mn(){return`%`}function Nn(e){return+e}function Pn(e){return Math.floor(e/1e3)}var Fn,In;Ln({dateTime:`%x, %X`,date:`%-m/%-d/%Y`,time:`%-I:%M:%S %p`,periods:[`AM`,`PM`],days:[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`],shortDays:[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],months:[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`],shortMonths:[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`]});function Ln(e){return Fn=vt(e),In=Fn.format,Fn.parse,Fn.utcFormat,Fn.utcParse,Fn}function Rn(e){return new Date(e)}function zn(e){return e instanceof Date?+e:+new Date(+e)}function Bn(e,t,n,r,i,a,o,s,c,l){var u=T(),d=u.invert,f=u.domain,p=l(`.%L`),m=l(`:%S`),h=l(`%I:%M`),g=l(`%I %p`),_=l(`%a %d`),v=l(`%b %d`),y=l(`%B`),b=l(`%Y`);function x(e){return(c(e){(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_isoWeek=r()})(e,(function(){return function(e,t,n){var r=function(e){return e.add(4-e.isoWeekday(),`day`)},i=t.prototype;i.isoWeekYear=function(){return r(this).year()},i.isoWeek=function(e){if(!this.$utils().u(e))return this.add(7*(e-this.isoWeek()),`day`);var t,i,a,o,s=r(this),c=(t=this.isoWeekYear(),i=this.$u,a=(i?n.utc:n)().year(t).startOf(`year`),o=4-a.isoWeekday(),a.isoWeekday()>4&&(o+=7),a.add(o,`day`));return s.diff(c,`week`)+1},i.isoWeekday=function(e){return this.$utils().u(e)?this.day()||7:this.day(this.day()%7?e:e-7)};var a=i.startOf;i.startOf=function(e,t){var n=this.$utils(),r=!!n.u(t)||t;return n.p(e)===`isoweek`?r?this.date(this.date()-(this.isoWeekday()-1)).startOf(`day`):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf(`day`):a.bind(this)(e,t)}}}))})),Un=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_customParseFormat=r()})(e,(function(){var e={LTS:`h:mm:ss A`,LT:`h:mm A`,L:`MM/DD/YYYY`,LL:`MMMM D, YYYY`,LLL:`MMMM D, YYYY h:mm A`,LLLL:`dddd, MMMM D, YYYY h:mm A`},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n=/\d/,r=/\d\d/,i=/\d\d?/,a=/\d*[^-_:/,()\s\d]+/,o={},s=function(e){return(e=+e)+(e>68?1900:2e3)},c=function(e){return function(t){this[e]=+t}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||={}).offset=function(e){if(!e||e===`Z`)return 0;var t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return n===0?0:t[0]===`+`?-n:n}(e)}],u=function(e){var t=o[e];return t&&(t.indexOf?t:t.s.concat(t.f))},d=function(e,t){var n,r=o.meridiem;if(r){for(var i=1;i<=24;i+=1)if(e.indexOf(r(i,0,t))>-1){n=i>12;break}}else n=e===(t?`pm`:`PM`);return n},f={A:[a,function(e){this.afternoon=d(e,!1)}],a:[a,function(e){this.afternoon=d(e,!0)}],Q:[n,function(e){this.month=3*(e-1)+1}],S:[n,function(e){this.milliseconds=100*e}],SS:[r,function(e){this.milliseconds=10*e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[i,c(`seconds`)],ss:[i,c(`seconds`)],m:[i,c(`minutes`)],mm:[i,c(`minutes`)],H:[i,c(`hours`)],h:[i,c(`hours`)],HH:[i,c(`hours`)],hh:[i,c(`hours`)],D:[i,c(`day`)],DD:[r,c(`day`)],Do:[a,function(e){var t=o.ordinal,n=e.match(/\d+/);if(this.day=n[0],t)for(var r=1;r<=31;r+=1)t(r).replace(/\[|\]/g,``)===e&&(this.day=r)}],w:[i,c(`week`)],ww:[r,c(`week`)],M:[i,c(`month`)],MM:[r,c(`month`)],MMM:[a,function(e){var t=u(`months`),n=(u(`monthsShort`)||t.map((function(e){return e.slice(0,3)}))).indexOf(e)+1;if(n<1)throw Error();this.month=n%12||n}],MMMM:[a,function(e){var t=u(`months`).indexOf(e)+1;if(t<1)throw Error();this.month=t%12||t}],Y:[/[+-]?\d+/,c(`year`)],YY:[r,function(e){this.year=s(e)}],YYYY:[/\d{4}/,c(`year`)],Z:l,ZZ:l};function p(n){for(var r=n,i=o&&o.formats,a=(n=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(t,n,r){var a=r&&r.toUpperCase();return n||i[r]||e[r]||i[a].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(e,t,n){return t||n.slice(1)}))}))).match(t),s=a.length,c=0;c-1)return new Date((t===`X`?1e3:1)*e);var i=p(t)(e),a=i.year,o=i.month,s=i.day,c=i.hours,l=i.minutes,u=i.seconds,d=i.milliseconds,f=i.zone,m=i.week,h=new Date,g=s||(a||o?1:h.getDate()),_=a||h.getFullYear(),v=0;a&&!o||(v=o>0?o-1:h.getMonth());var y,b=c||0,x=l||0,S=u||0,C=d||0;return f?new Date(Date.UTC(_,v,g,b,x,S,C+60*f.offset*1e3)):n?new Date(Date.UTC(_,v,g,b,x,S,C)):(y=new Date(_,v,g,b,x,S,C),m&&(y=r(y).week(m).toDate()),y)}catch{return new Date(``)}}(t,s,r,n),this.init(),d&&!0!==d&&(this.$L=this.locale(d).$L),u&&t!=this.format(s)&&(this.$d=new Date(``)),o={}}else if(s instanceof Array)for(var f=s.length,m=1;m<=f;m+=1){a[1]=s[m-1];var h=n.apply(this,a);if(h.isValid()){this.$d=h.$d,this.$L=h.$L,this.init();break}m===f&&(this.$d=new Date(``))}else i.call(this,e)}}}))})),Wn=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_advancedFormat=r()})(e,(function(){return function(e,t){var n=t.prototype,r=n.format;n.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return r.bind(this)(e);var i=this.$utils(),a=(e||`YYYY-MM-DDTHH:mm:ssZ`).replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(e){switch(e){case`Q`:return Math.ceil((t.$M+1)/3);case`Do`:return n.ordinal(t.$D);case`gggg`:return t.weekYear();case`GGGG`:return t.isoWeekYear();case`wo`:return n.ordinal(t.week(),`W`);case`w`:case`ww`:return i.s(t.week(),e===`w`?1:2,`0`);case`W`:case`WW`:return i.s(t.isoWeek(),e===`W`?1:2,`0`);case`k`:case`kk`:return i.s(String(t.$H===0?24:t.$H),e===`k`?1:2,`0`);case`X`:return Math.floor(t.$d.getTime()/1e3);case`x`:return t.$d.getTime();case`z`:return`[`+t.offsetName()+`]`;case`zzz`:return`[`+t.offsetName(`long`)+`]`;default:return e}}));return r.bind(this)(a)}}}))})),Gn=e(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs_plugin_duration=r()})(e,(function(){var e,t,n=1e3,r=6e4,i=36e5,a=864e5,o=31536e6,s=2628e6,c=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,l=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,u={years:o,months:s,days:a,hours:i,minutes:r,seconds:n,milliseconds:1,weeks:6048e5},d=function(e){return e instanceof v},f=function(e,t,n){return new v(e,n,t.$l)},p=function(e){return t.p(e)+`s`},m=function(e){return e<0},h=function(e){return m(e)?Math.ceil(e):Math.floor(e)},g=function(e){return Math.abs(e)},_=function(e,t){return e?m(e)?{negative:!0,format:``+g(e)+t}:{negative:!1,format:``+e+t}:{negative:!1,format:``}},v=function(){function m(e,t,n){var r=this;if(this.$d={},this.$l=n,e===void 0&&(this.$ms=0,this.parseFromMilliseconds()),t)return f(e*u[p(t)],this);if(typeof e==`number`)return this.$ms=e,this.parseFromMilliseconds(),this;if(typeof e==`object`)return Object.keys(e).forEach((function(t){r.$d[p(t)]=e[t]})),this.calMilliseconds(),this;if(typeof e==`string`){var i=e.match(c);if(i){var a=i.slice(2).map((function(e){return e==null?0:Number(e)}));return this.$d.years=a[0],this.$d.months=a[1],this.$d.weeks=a[2],this.$d.days=a[3],this.$d.hours=a[4],this.$d.minutes=a[5],this.$d.seconds=a[6],this.calMilliseconds(),this}}return this}var g=m.prototype;return g.calMilliseconds=function(){var e=this;this.$ms=Object.keys(this.$d).reduce((function(t,n){return t+(e.$d[n]||0)*u[n]}),0)},g.parseFromMilliseconds=function(){var e=this.$ms;this.$d.years=h(e/o),e%=o,this.$d.months=h(e/s),e%=s,this.$d.days=h(e/a),e%=a,this.$d.hours=h(e/i),e%=i,this.$d.minutes=h(e/r),e%=r,this.$d.seconds=h(e/n),e%=n,this.$d.milliseconds=e},g.toISOString=function(){var e=_(this.$d.years,`Y`),t=_(this.$d.months,`M`),n=+this.$d.days||0;this.$d.weeks&&(n+=7*this.$d.weeks);var r=_(n,`D`),i=_(this.$d.hours,`H`),a=_(this.$d.minutes,`M`),o=this.$d.seconds||0;this.$d.milliseconds&&(o+=this.$d.milliseconds/1e3,o=Math.round(1e3*o)/1e3);var s=_(o,`S`),c=e.negative||t.negative||r.negative||i.negative||a.negative||s.negative,l=i.format||a.format||s.format?`T`:``,u=(c?`-`:``)+`P`+e.format+t.format+r.format+l+i.format+a.format+s.format;return u===`P`||u===`-P`?`P0D`:u},g.toJSON=function(){return this.toISOString()},g.format=function(e){var n=e||`YYYY-MM-DDTHH:mm:ss`,r={Y:this.$d.years,YY:t.s(this.$d.years,2,`0`),YYYY:t.s(this.$d.years,4,`0`),M:this.$d.months,MM:t.s(this.$d.months,2,`0`),D:this.$d.days,DD:t.s(this.$d.days,2,`0`),H:this.$d.hours,HH:t.s(this.$d.hours,2,`0`),m:this.$d.minutes,mm:t.s(this.$d.minutes,2,`0`),s:this.$d.seconds,ss:t.s(this.$d.seconds,2,`0`),SSS:t.s(this.$d.milliseconds,3,`0`)};return n.replace(l,(function(e,t){return t||String(r[e])}))},g.as=function(e){return this.$ms/u[p(e)]},g.get=function(e){var t=this.$ms,n=p(e);return n===`milliseconds`?t%=1e3:t=n===`weeks`?h(t/u[n]):this.$d[n],t||0},g.add=function(e,t,n){var r;return r=t?e*u[p(t)]:d(e)?e.$ms:f(e,this).$ms,f(this.$ms+r*(n?-1:1),this)},g.subtract=function(e,t){return this.add(e,t,!0)},g.locale=function(e){var t=this.clone();return t.$l=e,t},g.clone=function(){return f(this.$ms,this)},g.humanize=function(t){return e().add(this.$ms,`ms`).locale(this.$l).fromNow(!t)},g.valueOf=function(){return this.asMilliseconds()},g.milliseconds=function(){return this.get(`milliseconds`)},g.asMilliseconds=function(){return this.as(`milliseconds`)},g.seconds=function(){return this.get(`seconds`)},g.asSeconds=function(){return this.as(`seconds`)},g.minutes=function(){return this.get(`minutes`)},g.asMinutes=function(){return this.as(`minutes`)},g.hours=function(){return this.get(`hours`)},g.asHours=function(){return this.as(`hours`)},g.days=function(){return this.get(`days`)},g.asDays=function(){return this.as(`days`)},g.weeks=function(){return this.get(`weeks`)},g.asWeeks=function(){return this.as(`weeks`)},g.months=function(){return this.get(`months`)},g.asMonths=function(){return this.as(`months`)},g.years=function(){return this.get(`years`)},g.asYears=function(){return this.as(`years`)},m}(),y=function(e,t,n){return e.add(t.years()*n,`y`).add(t.months()*n,`M`).add(t.days()*n,`d`).add(t.hours()*n,`h`).add(t.minutes()*n,`m`).add(t.seconds()*n,`s`).add(t.milliseconds()*n,`ms`)};return function(n,r,i){e=i,t=i().$utils(),i.duration=function(e,t){return f(e,{$l:i.locale()},t)},i.isDuration=d;var a=r.prototype.add,o=r.prototype.subtract;r.prototype.add=function(e,t){return d(e)?y(this,e,1):a.bind(this)(e,t)},r.prototype.subtract=function(e,t){return d(e)?y(this,e,-1):o.bind(this)(e,t)}}}))})),Kn=k(),J=d(a(),1),qn=d(Hn(),1),Jn=d(Un(),1),Yn=d(Wn(),1),Xn=d(Gn(),1),Zn=(function(){var e=f(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],n=[1,26],r=[1,27],i=[1,28],a=[1,29],o=[1,30],s=[1,31],c=[1,32],l=[1,33],u=[1,34],d=[1,9],p=[1,10],m=[1,11],h=[1,12],g=[1,13],_=[1,14],v=[1,15],y=[1,16],b=[1,19],x=[1,20],S=[1,21],C=[1,22],w=[1,23],T=[1,25],E=[1,35],D={trace:f(function(){},`trace`),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:`error`,4:`gantt`,6:`EOF`,8:`SPACE`,10:`NL`,12:`weekday_monday`,13:`weekday_tuesday`,14:`weekday_wednesday`,15:`weekday_thursday`,16:`weekday_friday`,17:`weekday_saturday`,18:`weekday_sunday`,20:`weekend_friday`,21:`weekend_saturday`,22:`dateFormat`,23:`inclusiveEndDates`,24:`topAxis`,25:`axisFormat`,26:`tickInterval`,27:`excludes`,28:`includes`,29:`todayMarker`,30:`title`,31:`acc_title`,32:`acc_title_value`,33:`acc_descr`,34:`acc_descr_value`,35:`acc_descr_multiline_value`,36:`section`,38:`taskTxt`,39:`taskData`,40:`click`,41:`callbackname`,42:`callbackargs`,43:`href`},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:f(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:case 7:this.$=[];break;case 8:r.setWeekday(`monday`);break;case 9:r.setWeekday(`tuesday`);break;case 10:r.setWeekday(`wednesday`);break;case 11:r.setWeekday(`thursday`);break;case 12:r.setWeekday(`friday`);break;case 13:r.setWeekday(`saturday`);break;case 14:r.setWeekday(`sunday`);break;case 15:r.setWeekend(`friday`);break;case 16:r.setWeekend(`saturday`);break;case 17:r.setDateFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 18:r.enableInclusiveEndDates(),this.$=a[s].substr(18);break;case 19:r.TopAxis(),this.$=a[s].substr(8);break;case 20:r.setAxisFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 21:r.setTickInterval(a[s].substr(13)),this.$=a[s].substr(13);break;case 22:r.setExcludes(a[s].substr(9)),this.$=a[s].substr(9);break;case 23:r.setIncludes(a[s].substr(9)),this.$=a[s].substr(9);break;case 24:r.setTodayMarker(a[s].substr(12)),this.$=a[s].substr(12);break;case 27:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 28:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 29:case 30:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 31:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 33:r.addTask(a[s-1],a[s]),this.$=`task`;break;case 34:this.$=a[s-1],r.setClickEvent(a[s-1],a[s],null);break;case 35:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 36:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],null),r.setLink(a[s-2],a[s]);break;case 37:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setLink(a[s-3],a[s]);break;case 38:this.$=a[s-2],r.setClickEvent(a[s-2],a[s],null),r.setLink(a[s-2],a[s-1]);break;case 39:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-1],a[s]),r.setLink(a[s-3],a[s-2]);break;case 40:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 41:case 47:this.$=a[s-1]+` `+a[s];break;case 42:case 43:case 45:this.$=a[s-2]+` `+a[s-1]+` `+a[s];break;case 44:case 46:this.$=a[s-3]+` `+a[s-2]+` `+a[s-1]+` `+a[s]}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(t,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:i,15:a,16:o,17:s,18:c,19:18,20:l,21:u,22:d,23:p,24:m,25:h,26:g,27:_,28:v,29:y,30:b,31:x,33:S,35:C,36:w,37:24,38:T,40:E},e(t,[2,7],{1:[2,1]}),e(t,[2,3]),{9:36,11:17,12:n,13:r,14:i,15:a,16:o,17:s,18:c,19:18,20:l,21:u,22:d,23:p,24:m,25:h,26:g,27:_,28:v,29:y,30:b,31:x,33:S,35:C,36:w,37:24,38:T,40:E},e(t,[2,5]),e(t,[2,6]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,20]),e(t,[2,21]),e(t,[2,22]),e(t,[2,23]),e(t,[2,24]),e(t,[2,25]),e(t,[2,26]),e(t,[2,27]),{32:[1,37]},{34:[1,38]},e(t,[2,30]),e(t,[2,31]),e(t,[2,32]),{39:[1,39]},e(t,[2,8]),e(t,[2,9]),e(t,[2,10]),e(t,[2,11]),e(t,[2,12]),e(t,[2,13]),e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),{41:[1,40],43:[1,41]},e(t,[2,4]),e(t,[2,28]),e(t,[2,29]),e(t,[2,33]),e(t,[2,34],{42:[1,42],43:[1,43]}),e(t,[2,40],{41:[1,44]}),e(t,[2,35],{43:[1,45]}),e(t,[2,36]),e(t,[2,38],{42:[1,46]}),e(t,[2,37]),e(t,[2,39])],defaultActions:{},parseError:f(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:f(function(e){var t=this,n=[0],r=[],i=[null],a=[],o=this.table,s=``,c=0,l=0,u=0,d=2,p=1,m=a.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;a.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){n.length-=2*e,i.length-=e,a.length-=e}f(b,`popStack`);function x(){var e=r.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(r=e,e=r.pop()),e=t.symbols_[e]||e),e}f(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=n[n.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=o[w]&&o[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],o[w])this.terminals_[O]&&O>d&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(c+1)+`: +`+h.showPosition()+` +Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(c+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:n.push(S),i.push(h.yytext),a.push(h.yylloc),n.push(T[1]),S=null,C?(S=C,C=null):(l=h.yyleng,s=h.yytext,c=h.yylineno,v=h.yylloc,u>0&&u--);break;case 2:if(k=this.productions_[T[1]][1],D.$=i[i.length-k],D._$={first_line:a[a.length-(k||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(k||1)].first_column,last_column:a[a.length-1].last_column},y&&(D._$.range=[a[a.length-(k||1)].range[0],a[a.length-1].range[1]]),E=this.performAction.apply(D,[s,l,c,g.yy,T[1],i,a].concat(m)),E!==void 0)return E;k&&(n=n.slice(0,-1*k*2),i=i.slice(0,-1*k),a=a.slice(0,-1*k)),n.push(this.productions_[T[1]][0]),i.push(D.$),a.push(D._$),ee=o[n[n.length-2]][n[n.length-1]],n.push(ee);break;case 3:return!0}}return!0},`parse`)};D.lexer=(function(){return{EOF:1,parseError:f(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:f(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:f(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:f(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:f(function(){return this._more=!0,this},`more`),reject:f(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:f(function(e){this.unput(this.match.slice(e))},`less`),pastInput:f(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:f(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:f(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:f(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:f(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:f(function(){return this.next()||this.lex()},`lex`),begin:f(function(e){this.conditionStack.push(e)},`begin`),popState:f(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:f(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:f(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:f(function(e){this.begin(e)},`pushState`),stateStackSize:f(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:f(function(e,t,n,r){switch(n){case 0:return this.begin(`open_directive`),`open_directive`;case 1:return this.begin(`acc_title`),31;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),33;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:break;case 9:break;case 10:break;case 11:return 10;case 12:break;case 13:break;case 14:this.begin(`href`);break;case 15:this.popState();break;case 16:return 43;case 17:this.begin(`callbackname`);break;case 18:this.popState();break;case 19:this.popState(),this.begin(`callbackargs`);break;case 20:return 41;case 21:this.popState();break;case 22:return 42;case 23:this.begin(`click`);break;case 24:this.popState();break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return`date`;case 45:return 30;case 46:return`accDescription`;case 47:return 36;case 48:return 38;case 49:return 39;case 50:return`:`;case 51:return 6;case 52:return`INVALID`}},`anonymous`),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}})();function O(){this.yy={}}return f(O,`Parser`),O.prototype=D,D.Parser=O,new O})();Zn.parser=Zn;var Qn=Zn;J.default.extend(qn.default),J.default.extend(Jn.default),J.default.extend(Yn.default);var $n={friday:5,saturday:6},Y=``,er=``,tr=void 0,nr=``,rr=[],ir=[],ar=new Map,or=[],sr=[],X=``,cr=``,lr=[`active`,`done`,`crit`,`milestone`,`vert`],ur=[],dr=``,fr=!1,pr=!1,mr=`sunday`,hr=`saturday`,gr=0,_r=f(function(){or=[],sr=[],X=``,ur=[],Zr=0,ti=void 0,ni=void 0,Z=[],Y=``,er=``,cr=``,tr=void 0,nr=``,rr=[],ir=[],fr=!1,pr=!1,gr=0,ar=new Map,dr=``,h(),mr=`sunday`,hr=`saturday`},`clear`),vr=f(function(e){dr=e},`setDiagramId`),yr=f(function(e){er=e},`setAxisFormat`),br=f(function(){return er},`getAxisFormat`),xr=f(function(e){tr=e},`setTickInterval`),Sr=f(function(){return tr},`getTickInterval`),Cr=f(function(e){nr=e},`setTodayMarker`),wr=f(function(){return nr},`getTodayMarker`),Tr=f(function(e){Y=e},`setDateFormat`),Er=f(function(){fr=!0},`enableInclusiveEndDates`),Dr=f(function(){return fr},`endDatesAreInclusive`),Or=f(function(){pr=!0},`enableTopAxis`),kr=f(function(){return pr},`topAxisEnabled`),Ar=f(function(e){cr=e},`setDisplayMode`),jr=f(function(){return cr},`getDisplayMode`),Mr=f(function(){return Y},`getDateFormat`),Nr=f((e,t)=>{let n=t.toLowerCase().split(/[\s,]+/).filter(e=>e!==``);return[...new Set([...e,...n])]},`mergeTokens`),Pr=f(function(e){rr=Nr(rr,e)},`setIncludes`),Fr=f(function(){return rr},`getIncludes`),Ir=f(function(e){ir=Nr(ir,e)},`setExcludes`),Lr=f(function(){return ir},`getExcludes`),Rr=f(function(){return ar},`getLinks`),zr=f(function(e){X=e,or.push(e)},`addSection`),Br=f(function(){return or},`getSections`),Vr=f(function(){let e=oi(),t=0;for(;!e&&t<10;)e=oi(),t++;return sr=Z,sr},`getTasks`),Hr=f(function(e,t,n,r){let i=e.format(t.trim()),a=e.format(`YYYY-MM-DD`);return r.includes(i)||r.includes(a)?!1:n.includes(`weekends`)&&(e.isoWeekday()===$n[hr]||e.isoWeekday()===$n[hr]+1)||n.includes(e.format(`dddd`).toLowerCase())?!0:n.includes(i)||n.includes(a)},`isInvalidDate`),Ur=f(function(e){mr=e},`setWeekday`),Wr=f(function(){return mr},`getWeekday`),Gr=f(function(e){hr=e},`setWeekend`),Kr=f(function(e,t,n,r){if(!n.length||e.manualEndTime)return;let i;i=e.startTime instanceof Date?(0,J.default)(e.startTime):(0,J.default)(e.startTime,t,!0),i=i.add(1,`d`);let a;a=e.endTime instanceof Date?(0,J.default)(e.endTime):(0,J.default)(e.endTime,t,!0);let[o,s]=qr(i,a,t,n,r);e.endTime=o.toDate(),e.renderEndTime=s},`checkTaskDates`),qr=f(function(e,t,n,r,i){let a=!1,o=null,s=t.add(1e4,`d`);for(;e<=t;){if(a||(o=t.toDate()),a=Hr(e,n,r,i),a&&(t=t.add(1,`d`),t>s))throw Error("Failed to find a valid date that was not excluded by `excludes` after 10,000 iterations.");e=e.add(1,`d`)}return[t,o]},`fixTaskDates`),Jr=f(function(e,t,n){if(n=n.trim(),f(e=>{let t=e.trim();return t===`x`||t===`X`},`isTimestampFormat`)(t)&&/^\d+$/.test(n))return new Date(Number(n));let r=/^after\s+(?[\d\w- ]+)/.exec(n);if(r!==null){let e=null;for(let t of r.groups.ids.split(` `)){let n=Q(t);n!==void 0&&(!e||n.endTime>e.endTime)&&(e=n)}if(e)return e.endTime;let t=new Date;return t.setHours(0,0,0,0),t}let i=(0,J.default)(n,t.trim(),!0);if(i.isValid())return i.toDate();{s.debug(`Invalid date:`+n),s.debug(`With date format:`+t.trim());let e=new Date(n);if(e===void 0||isNaN(e.getTime())||e.getFullYear()<-1e4||e.getFullYear()>1e4)throw Error(`Invalid date:`+n);return e}},`getStartDate`),Yr=f(function(e){let t=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(e.trim());return t===null?[NaN,`ms`]:[Number.parseFloat(t[1]),t[2]]},`parseDuration`),Xr=f(function(e,t,n,r=!1){n=n.trim();let i=/^until\s+(?[\d\w- ]+)/.exec(n);if(i!==null){let e=null;for(let t of i.groups.ids.split(` `)){let n=Q(t);n!==void 0&&(!e||n.startTime{window.open(n,`_self`)}),ar.set(e,n))}),ci(e,`clickable`)},`setLink`),ci=f(function(e,t){e.split(`,`).forEach(function(e){let n=Q(e);n!==void 0&&n.classes.push(t)})},`setClass`),li=f(function(e,t,n){if(x().securityLevel!==`loose`||t===void 0)return;let r=[];if(typeof n==`string`){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e{ee.runFunc(t,...r)})},`setClickFun`),ui=f(function(e,t){ur.push(function(){let n=dr?`${dr}-${e}`:e,r=document.querySelector(`[id="${n}"]`);r!==null&&r.addEventListener(`click`,function(){t()})},function(){let n=dr?`${dr}-${e}`:e,r=document.querySelector(`[id="${n}-text"]`);r!==null&&r.addEventListener(`click`,function(){t()})})},`pushFun`),di={getConfig:f(()=>x().gantt,`getConfig`),clear:_r,setDateFormat:Tr,getDateFormat:Mr,enableInclusiveEndDates:Er,endDatesAreInclusive:Dr,enableTopAxis:Or,topAxisEnabled:kr,setAxisFormat:yr,getAxisFormat:br,setTickInterval:xr,getTickInterval:Sr,setTodayMarker:Cr,getTodayMarker:wr,setAccTitle:m,getAccTitle:S,setDiagramTitle:_,getDiagramTitle:b,setDiagramId:vr,setDisplayMode:Ar,getDisplayMode:jr,setAccDescription:p,getAccDescription:y,addSection:zr,getSections:Br,getTasks:Vr,addTask:ii,findTaskById:Q,addTaskOrg:ai,setIncludes:Pr,getIncludes:Fr,setExcludes:Ir,getExcludes:Lr,setClickEvent:f(function(e,t,n){e.split(`,`).forEach(function(e){li(e,t,n)}),ci(e,`clickable`)},`setClickEvent`),setLink:si,getLinks:Rr,bindFunctions:f(function(e){ur.forEach(function(t){t(e)})},`bindFunctions`),parseDuration:Yr,isInvalidDate:Hr,setWeekday:Ur,getWeekday:Wr,setWeekend:Gr};function fi(e,t,n){let r=!0;for(;r;)r=!1,n.forEach(function(n){let i=`^\\s*`+n+`\\s*$`,a=new RegExp(i);e[0].match(a)&&(t[n]=!0,e.shift(1),r=!0)})}f(fi,`getTaskTags`),J.default.extend(Xn.default);var pi=f(function(){s.debug(`Something is calling, setConf, remove the call`)},`setConf`),mi={monday:Xe,tuesday:Ze,wednesday:Qe,thursday:H,friday:$e,saturday:et,sunday:Ye},hi=f((e,t)=>{let n=[...e].map(()=>-1/0),r=[...e].sort((e,t)=>e.startTime-t.startTime||e.order-t.order),i=0;for(let e of r)for(let r=0;r=n[r]){n[r]=e.endTime,e.order=r+t,r>i&&(i=r);break}return i},`getMaxIntersections`),$,gi=1e4,_i={parser:Qn,db:di,renderer:{setConf:pi,draw:f(function(e,t,n,r){let i=x().gantt;r.db.setDiagramId(t);let a=x().securityLevel,o;a===`sandbox`&&(o=c(`#i`+t));let l=c(a===`sandbox`?o.nodes()[0].contentDocument.body:`body`),u=a===`sandbox`?o.nodes()[0].contentDocument:document,d=u.getElementById(t);$=d.parentElement.offsetWidth,$===void 0&&($=1200),i.useWidth!==void 0&&($=i.useWidth);let p=r.db.getTasks(),m=p.filter(e=>!e.vert),h=[];for(let e of m)h.push(e.type);h=j(h);let _={},y=2*i.topPadding;if(r.db.getDisplayMode()===`compact`||i.displayMode===`compact`){let e={};for(let t of m)e[t.section]===void 0?e[t.section]=[t]:e[t.section].push(t);let t=0;for(let n of Object.keys(e)){let r=hi(e[n],t)+1;t+=r,y+=r*(i.barHeight+i.barGap),_[n]=r}}else{y+=m.length*(i.barHeight+i.barGap);for(let e of h)_[e]=m.filter(t=>t.type===e).length}d.setAttribute(`viewBox`,`0 0 `+$+` `+y);let b=l.select(`[id="${t}"]`),S=Vn().domain([te(p,function(e){return e.startTime}),A(p,function(e){return e.endTime})]).rangeRound([0,$-i.leftPadding-i.rightPadding]);function C(e,t){let n=e.startTime,r=t.startTime,i=0;return n>r?i=1:ne.vert===t.vert?0:e.vert?1:-1);let d=e.filter(e=>!e.vert),f=[...new Set(d.map(e=>e.order))].map(e=>d.find(t=>t.order===e));b.append(`g`).selectAll(`rect`).data(f).enter().append(`rect`).attr(`x`,0).attr(`y`,function(e,t){return t=e.order,t*n+a-2}).attr(`width`,function(){return u-i.rightPadding/2}).attr(`height`,n).attr(`class`,function(e){for(let[t,n]of h.entries())if(e.type===n)return`section section`+t%i.numberSectionStyles;return`section section0`}).enter();let p=b.append(`g`).selectAll(`rect`).data(e).enter(),m=r.db.getLinks();if(p.append(`rect`).attr(`id`,function(e){return t+`-`+e.id}).attr(`rx`,3).attr(`ry`,3).attr(`x`,function(e){return e.milestone?S(e.startTime)+o+.5*(S(e.endTime)-S(e.startTime))-.5*s:S(e.startTime)+o}).attr(`y`,function(e,t){return t=e.order,e.vert?i.gridLineStartPadding:t*n+a}).attr(`width`,function(e){return e.milestone?s:e.vert?.08*s:S(e.renderEndTime||e.endTime)-S(e.startTime)}).attr(`height`,function(e){return e.vert?d.length*(i.barHeight+i.barGap)+i.barHeight*2:s}).attr(`transform-origin`,function(e,t){return t=e.order,(S(e.startTime)+o+.5*(S(e.endTime)-S(e.startTime))).toString()+`px `+(t*n+a+.5*s).toString()+`px`}).attr(`class`,function(e){let t=``;e.classes.length>0&&(t=e.classes.join(` `));let n=0;for(let[t,r]of h.entries())e.type===r&&(n=t%i.numberSectionStyles);let r=``;return e.active?e.crit?r+=` activeCrit`:r=` active`:e.done?r=e.crit?` doneCrit`:` done`:e.crit&&(r+=` crit`),r.length===0&&(r=` task`),e.milestone&&(r=` milestone `+r),e.vert&&(r=` vert `+r),r+=n,r+=` `+t,`task`+r}),p.append(`text`).attr(`id`,function(e){return t+`-`+e.id+`-text`}).text(function(e){return e.task}).attr(`font-size`,i.fontSize).attr(`x`,function(e){let t=S(e.startTime),n=S(e.renderEndTime||e.endTime);if(e.milestone&&(t+=.5*(S(e.endTime)-S(e.startTime))-.5*s,n=t+s),e.vert)return S(e.startTime)+o;let r=this.getBBox().width;return r>n-t?n+r+1.5*i.leftPadding>u?t+o-5:n+o+5:(n-t)/2+t+o}).attr(`y`,function(e,t){return e.vert?i.gridLineStartPadding+d.length*(i.barHeight+i.barGap)+60:(t=e.order,t*n+i.barHeight/2+(i.fontSize/2-2)+a)}).attr(`text-height`,s).attr(`class`,function(e){let t=S(e.startTime),n=S(e.endTime);e.milestone&&(n=t+s);let r=this.getBBox().width,a=``;e.classes.length>0&&(a=e.classes.join(` `));let o=0;for(let[t,n]of h.entries())e.type===n&&(o=t%i.numberSectionStyles);let c=``;return e.active&&(c=e.crit?`activeCritText`+o:`activeText`+o),e.done?c=e.crit?c+` doneCritText`+o:c+` doneText`+o:e.crit&&(c=c+` critText`+o),e.milestone&&(c+=` milestoneText`),e.vert&&(c+=` vertText`),r>n-t?n+r+1.5*i.leftPadding>u?a+` taskTextOutsideLeft taskTextOutside`+o+` `+c:a+` taskTextOutsideRight taskTextOutside`+o+` `+c+` width-`+r:a+` taskText taskText`+o+` `+c+` width-`+r}),x().securityLevel===`sandbox`){let e;e=c(`#i`+t);let n=e.nodes()[0].contentDocument;p.filter(function(e){return m.has(e.id)}).each(function(e){var r=n.querySelector(`#`+CSS.escape(t+`-`+e.id)),i=n.querySelector(`#`+CSS.escape(t+`-`+e.id+`-text`));let a=r.parentNode;var o=n.createElement(`a`);o.setAttribute(`xlink:href`,m.get(e.id)),o.setAttribute(`target`,`_top`),a.appendChild(o),o.appendChild(r),o.appendChild(i)})}}f(T,`drawRects`);function E(e,n,a,o,c,l,u,d){if(u.length===0&&d.length===0)return;let f,p;for(let{startTime:e,endTime:t}of l)(f===void 0||ep)&&(p=t);if(!f||!p)return;if((0,J.default)(p).diff((0,J.default)(f),`year`)>5){s.warn(`The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.`);return}let m=r.db.getDateFormat(),h=[],g=null,_=(0,J.default)(f);for(;_.valueOf()<=p;)r.db.isInvalidDate(_,m,u,d)?g?g.end=_:g={start:_,end:_}:g&&=(h.push(g),null),_=_.add(1,`d`);b.append(`g`).selectAll(`rect`).data(h).enter().append(`rect`).attr(`id`,e=>t+`-exclude-`+e.start.format(`YYYY-MM-DD`)).attr(`x`,e=>S(e.start.startOf(`day`))+a).attr(`y`,i.gridLineStartPadding).attr(`width`,e=>S(e.end.endOf(`day`))-S(e.start.startOf(`day`))).attr(`height`,c-n-i.gridLineStartPadding).attr(`transform-origin`,function(t,n){return(S(t.start)+a+.5*(S(t.end)-S(t.start))).toString()+`px `+(n*e+.5*c).toString()+`px`}).attr(`class`,`exclude-range`)}f(E,`drawExcludeDays`);function O(e,t,n,r){if(n<=0||e>t)return 1/0;let i=t-e,a=J.default.duration({[r??`day`]:n}).asMilliseconds();return a<=0?1/0:Math.ceil(i/a)}f(O,`getEstimatedTickCount`);function k(e,t,n,a){let o=r.db.getDateFormat(),c=r.db.getAxisFormat(),l;l=c||(o===`D`?`%d`:i.axisFormat??`%Y-%m-%d`);let u=me(S).tickSize(-a+t+i.gridLineStartPadding).tickFormat(In(l)),d=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||i.tickInterval);if(d!==null){let e=parseInt(d[1],10);if(isNaN(e)||e<=0)s.warn(`Invalid tick interval value: "${d[1]}". Skipping custom tick interval.`);else{let t=d[2],n=r.db.getWeekday()||i.weekday,a=S.domain(),o=a[0],c=a[1],l=O(o,c,e,t);if(l>gi)s.warn(`The tick interval "${e}${t}" would generate ${l} ticks, which exceeds the maximum allowed (${gi}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(t){case`millisecond`:u.ticks(ze.every(e));break;case`second`:u.ticks(z.every(e));break;case`minute`:u.ticks(Ue.every(e));break;case`hour`:u.ticks(Ge.every(e));break;case`day`:u.ticks(B.every(e));break;case`week`:u.ticks(mi[n].every(e));break;case`month`:u.ticks(ct.every(e))}}}if(b.append(`g`).attr(`class`,`grid`).attr(`transform`,`translate(`+e+`, `+(a-50)+`)`).call(u).selectAll(`text`).style(`text-anchor`,`middle`).attr(`fill`,`#000`).attr(`stroke`,`none`).attr(`font-size`,10).attr(`dy`,`1em`),r.db.topAxisEnabled()||i.topAxis){let n=pe(S).tickSize(-a+t+i.gridLineStartPadding).tickFormat(In(l));if(d!==null){let e=parseInt(d[1],10);if(isNaN(e)||e<=0)s.warn(`Invalid tick interval value: "${d[1]}". Skipping custom tick interval.`);else{let t=d[2],a=r.db.getWeekday()||i.weekday,o=S.domain(),s=o[0],c=o[1];if(O(s,c,e,t)<=gi)switch(t){case`millisecond`:n.ticks(ze.every(e));break;case`second`:n.ticks(z.every(e));break;case`minute`:n.ticks(Ue.every(e));break;case`hour`:n.ticks(Ge.every(e));break;case`day`:n.ticks(B.every(e));break;case`week`:n.ticks(mi[a].every(e));break;case`month`:n.ticks(ct.every(e))}}}b.append(`g`).attr(`class`,`grid`).attr(`transform`,`translate(`+e+`, `+t+`)`).call(n).selectAll(`text`).style(`text-anchor`,`middle`).attr(`fill`,`#000`).attr(`stroke`,`none`).attr(`font-size`,10)}}f(k,`makeGrid`);function ee(e,t){let n=0,r=Object.keys(_).map(e=>[e,_[e]]);b.append(`g`).selectAll(`text`).data(r).enter().append(function(e){let t=e[0].split(v.lineBreakRegex),n=-(t.length-1)/2,r=u.createElementNS(`http://www.w3.org/2000/svg`,`text`);r.setAttribute(`dy`,n+`em`);for(let[e,n]of t.entries()){let t=u.createElementNS(`http://www.w3.org/2000/svg`,`tspan`);t.setAttribute(`alignment-baseline`,`central`),t.setAttribute(`x`,`10`),e>0&&t.setAttribute(`dy`,`1em`),t.textContent=n,r.appendChild(t)}return r}).attr(`x`,10).attr(`y`,function(i,a){if(a>0)for(let o=0;o` + .mermaid-main-font { + font-family: ${e.fontFamily}; + } + + .exclude-range { + fill: ${e.excludeBkgColor}; + } + + .section { + stroke: none; + opacity: 0.2; + } + + .section0 { + fill: ${e.sectionBkgColor}; + } + + .section2 { + fill: ${e.sectionBkgColor2}; + } + + .section1, + .section3 { + fill: ${e.altSectionBkgColor}; + opacity: 0.2; + } + + .sectionTitle0 { + fill: ${e.titleColor}; + } + + .sectionTitle1 { + fill: ${e.titleColor}; + } + + .sectionTitle2 { + fill: ${e.titleColor}; + } + + .sectionTitle3 { + fill: ${e.titleColor}; + } + + .sectionTitle { + text-anchor: start; + font-family: ${e.fontFamily}; + } + + + /* Grid and axis */ + + .grid .tick { + stroke: ${e.gridColor}; + opacity: 0.8; + shape-rendering: crispEdges; + } + + .grid .tick text { + font-family: ${e.fontFamily}; + fill: ${e.textColor}; + } + + .grid path { + stroke-width: 0; + } + + + /* Today line */ + + .today { + fill: none; + stroke: ${e.todayLineColor}; + stroke-width: 2px; + } + + + /* Task styling */ + + /* Default task */ + + .task { + stroke-width: 2; + } + + .taskText { + text-anchor: middle; + font-family: ${e.fontFamily}; + } + + .taskTextOutsideRight { + fill: ${e.taskTextDarkColor}; + text-anchor: start; + font-family: ${e.fontFamily}; + } + + .taskTextOutsideLeft { + fill: ${e.taskTextDarkColor}; + text-anchor: end; + } + + + /* Special case clickable */ + + .task.clickable { + cursor: pointer; + } + + .taskText.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + .taskTextOutsideLeft.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + .taskTextOutsideRight.clickable { + cursor: pointer; + fill: ${e.taskTextClickableColor} !important; + font-weight: bold; + } + + + /* Specific task settings for the sections*/ + + .taskText0, + .taskText1, + .taskText2, + .taskText3 { + fill: ${e.taskTextColor}; + } + + .task0, + .task1, + .task2, + .task3 { + fill: ${e.taskBkgColor}; + stroke: ${e.taskBorderColor}; + } + + .taskTextOutside0, + .taskTextOutside2 + { + fill: ${e.taskTextOutsideColor}; + } + + .taskTextOutside1, + .taskTextOutside3 { + fill: ${e.taskTextOutsideColor}; + } + + + /* Active task */ + + .active0, + .active1, + .active2, + .active3 { + fill: ${e.activeTaskBkgColor}; + stroke: ${e.activeTaskBorderColor}; + } + + .activeText0, + .activeText1, + .activeText2, + .activeText3 { + fill: ${e.taskTextDarkColor} !important; + } + + + /* Completed task */ + + .done0, + .done1, + .done2, + .done3 { + stroke: ${e.doneTaskBorderColor}; + fill: ${e.doneTaskBkgColor}; + stroke-width: 2; + } + + .doneText0, + .doneText1, + .doneText2, + .doneText3 { + fill: ${e.taskTextDarkColor} !important; + } + + /* Done task text displayed outside the bar sits against the diagram background, + not against the done-task bar, so it must use the outside/contrast color. */ + .doneText0.taskTextOutsideLeft, + .doneText0.taskTextOutsideRight, + .doneText1.taskTextOutsideLeft, + .doneText1.taskTextOutsideRight, + .doneText2.taskTextOutsideLeft, + .doneText2.taskTextOutsideRight, + .doneText3.taskTextOutsideLeft, + .doneText3.taskTextOutsideRight { + fill: ${e.taskTextOutsideColor} !important; + } + + + /* Tasks on the critical line */ + + .crit0, + .crit1, + .crit2, + .crit3 { + stroke: ${e.critBorderColor}; + fill: ${e.critBkgColor}; + stroke-width: 2; + } + + .activeCrit0, + .activeCrit1, + .activeCrit2, + .activeCrit3 { + stroke: ${e.critBorderColor}; + fill: ${e.activeTaskBkgColor}; + stroke-width: 2; + } + + .doneCrit0, + .doneCrit1, + .doneCrit2, + .doneCrit3 { + stroke: ${e.critBorderColor}; + fill: ${e.doneTaskBkgColor}; + stroke-width: 2; + cursor: pointer; + shape-rendering: crispEdges; + } + + .milestone { + transform: rotate(45deg) scale(0.8,0.8); + } + + .milestoneText { + font-style: italic; + } + .doneCritText0, + .doneCritText1, + .doneCritText2, + .doneCritText3 { + fill: ${e.taskTextDarkColor} !important; + } + + /* Done-crit task text outside the bar \u2014 same reasoning as doneText above. */ + .doneCritText0.taskTextOutsideLeft, + .doneCritText0.taskTextOutsideRight, + .doneCritText1.taskTextOutsideLeft, + .doneCritText1.taskTextOutsideRight, + .doneCritText2.taskTextOutsideLeft, + .doneCritText2.taskTextOutsideRight, + .doneCritText3.taskTextOutsideLeft, + .doneCritText3.taskTextOutsideRight { + fill: ${e.taskTextOutsideColor} !important; + } + + .vert { + stroke: ${e.vertLineColor}; + } + + .vertText { + font-size: 15px; + text-anchor: middle; + fill: ${e.vertLineColor} !important; + } + + .activeCritText0, + .activeCritText1, + .activeCritText2, + .activeCritText3 { + fill: ${e.taskTextDarkColor} !important; + } + + .titleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.titleColor||e.textColor}; + font-family: ${e.fontFamily}; + } +`,`getStyles`)};export{_i as diagram}; \ No newline at end of file diff --git a/www/assets/gitGraph-4MIJSDKK-DroQcAWn.js b/www/assets/gitGraph-4MIJSDKK-DroQcAWn.js new file mode 100644 index 0000000..e66b602 --- /dev/null +++ b/www/assets/gitGraph-4MIJSDKK-DroQcAWn.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{E as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createGitGraphServices}; \ No newline at end of file diff --git a/www/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js b/www/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js new file mode 100644 index 0000000..ce6e6d6 --- /dev/null +++ b/www/assets/gitGraphDiagram-X574FWY7-BEOc0w88.js @@ -0,0 +1,106 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,X as a,a as o,b as s,f as c,q as l,s as u,v as d,w as f,x as p,y as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as h,i as g,m as _}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{n as v}from"./mermaid-parser.core-CUrDj5TF.js";import{t as y}from"./chunk-JWPE2WC7-DVXcaiue.js";import{t as b}from"./chunk-2Q5K7J3B-C1jixKkw.js";var x={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},ee=c.gitGraph,S=n(()=>g({...ee,...s().gitGraph}),`getConfig`),C=new b(()=>{let e=S(),t=e.mainBranchName,n=e.mainBranchOrder;return{mainBranchName:t,commits:new Map,head:null,branchConfig:new Map([[t,{name:t,order:n}]]),branches:new Map([[t,null]]),currBranch:t,direction:`LR`,seq:0,options:{}}});function w(){return _({length:7})}n(w,`getID`);function T(e,t){let n=Object.create(null);return e.reduce((e,r)=>{let i=t(r);return n[i]||(n[i]=!0,e.push(r)),e},[])}n(T,`uniqBy`);var te=n(function(e){C.records.direction=e},`setDirection`),ne=n(function(t){e.debug(`options str`,t),t=t?.trim(),t||=`{}`;try{C.records.options=JSON.parse(t)}catch(t){e.error(`error while parsing gitGraph options`,t.message)}},`setOptions`),re=n(function(){return C.records.options},`getOptions`),ie=n(function(t){let n=t.msg,r=t.id,i=t.type,a=t.tags;e.info(`commit`,n,r,i,a),e.debug(`Entering commit:`,n,r,i,a);let o=S();r=u.sanitizeText(r,o),n=u.sanitizeText(n,o),a=a?.map(e=>u.sanitizeText(e,o));let s={id:r||C.records.seq+`-`+w(),message:n,seq:C.records.seq++,type:i??x.NORMAL,tags:a??[],parents:C.records.head==null?[]:[C.records.head.id],branch:C.records.currBranch};C.records.head=s,e.info(`main branch`,o.mainBranchName),C.records.commits.has(s.id)&&e.warn(`Commit ID ${s.id} already exists`),C.records.commits.set(s.id,s),C.records.branches.set(C.records.currBranch,s.id),e.debug(`in pushCommit `+s.id)},`commit`),ae=n(function(t){let n=t.name,r=t.order;if(n=u.sanitizeText(n,S()),C.records.branches.has(n))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${n}")`);C.records.branches.set(n,C.records.head==null?null:C.records.head.id),C.records.branchConfig.set(n,{name:n,order:r}),E(n),e.debug(`in createBranch`)},`branch`),oe=n(t=>{let n=t.branch,r=t.id,i=t.type,a=t.tags,o=S();n=u.sanitizeText(n,o),r&&=u.sanitizeText(r,o);let s=C.records.branches.get(C.records.currBranch),c=C.records.branches.get(n),l=s?C.records.commits.get(s):void 0,d=c?C.records.commits.get(c):void 0;if(l&&d&&l.branch===n)throw Error(`Cannot merge branch '${n}' into itself.`);if(C.records.currBranch===n){let e=Error(`Incorrect usage of "merge". Cannot merge a branch to itself`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch abc`]},e}if(l===void 0||!l){let e=Error(`Incorrect usage of "merge". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`commit`]},e}if(!C.records.branches.has(n)){let e=Error(`Incorrect usage of "merge". Branch to be merged (`+n+`) does not exist`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch ${n}`]},e}if(d===void 0||!d){let e=Error(`Incorrect usage of "merge". Branch to be merged (`+n+`) has no commits`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`"commit"`]},e}if(l===d){let e=Error(`Incorrect usage of "merge". Both branches have same head`);throw e.hash={text:`merge ${n}`,token:`merge ${n}`,expected:[`branch abc`]},e}if(r&&C.records.commits.has(r)){let e=Error(`Incorrect usage of "merge". Commit with id:`+r+` already exists, use different custom id`);throw e.hash={text:`merge ${n} ${r} ${i} ${a?.join(` `)}`,token:`merge ${n} ${r} ${i} ${a?.join(` `)}`,expected:[`merge ${n} ${r}_UNIQUE ${i} ${a?.join(` `)}`]},e}let f=c||``,p={id:r||`${C.records.seq}-${w()}`,message:`merged branch ${n} into ${C.records.currBranch}`,seq:C.records.seq++,parents:C.records.head==null?[]:[C.records.head.id,f],branch:C.records.currBranch,type:x.MERGE,customType:i,customId:!!r,tags:a??[]};C.records.head=p,C.records.commits.set(p.id,p),C.records.branches.set(C.records.currBranch,p.id),e.debug(C.records.branches),e.debug(`in mergeBranch`)},`merge`),se=n(function(t){let n=t.id,r=t.targetId,i=t.tags,a=t.parent;e.debug(`Entering cherryPick:`,n,r,i);let o=S();if(n=u.sanitizeText(n,o),r=u.sanitizeText(r,o),i=i?.map(e=>u.sanitizeText(e,o)),a=u.sanitizeText(a,o),!n||!C.records.commits.has(n)){let e=Error(`Incorrect usage of "cherryPick". Source commit id should exist and provided`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let s=C.records.commits.get(n);if(s===void 0||!s)throw Error(`Incorrect usage of "cherryPick". Source commit id should exist and provided`);if(a&&!(Array.isArray(s.parents)&&s.parents.includes(a)))throw Error(`Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.`);let c=s.branch;if(s.type===x.MERGE&&!a)throw Error(`Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.`);if(!r||!C.records.commits.has(r)){if(c===C.records.currBranch){let e=Error(`Incorrect usage of "cherryPick". Source commit is already on current branch`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let t=C.records.branches.get(C.records.currBranch);if(t===void 0||!t){let e=Error(`Incorrect usage of "cherry-pick". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let o=C.records.commits.get(t);if(o===void 0||!o){let e=Error(`Incorrect usage of "cherry-pick". Current branch (${C.records.currBranch})has no commits`);throw e.hash={text:`cherryPick ${n} ${r}`,token:`cherryPick ${n} ${r}`,expected:[`cherry-pick abc`]},e}let l={id:C.records.seq+`-`+w(),message:`cherry-picked ${s?.message} into ${C.records.currBranch}`,seq:C.records.seq++,parents:C.records.head==null?[]:[C.records.head.id,s.id],branch:C.records.currBranch,type:x.CHERRY_PICK,tags:i?i.filter(Boolean):[`cherry-pick:${s.id}${s.type===x.MERGE?`|parent:${a}`:``}`]};C.records.head=l,C.records.commits.set(l.id,l),C.records.branches.set(C.records.currBranch,l.id),e.debug(C.records.branches),e.debug(`in cherryPick`)}},`cherryPick`),E=n(function(e){if(e=u.sanitizeText(e,S()),C.records.branches.has(e)){C.records.currBranch=e;let t=C.records.branches.get(C.records.currBranch);t===void 0||!t?C.records.head=null:C.records.head=C.records.commits.get(t)??null}else{let t=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw t.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},t}},`checkout`);function D(e,t,n){let r=e.indexOf(t);r===-1?e.push(n):e.splice(r,1,n)}n(D,`upsert`);function O(t){let n=t.reduce((e,t)=>e.seq>t.seq?e:t,t[0]),r=``;t.forEach(function(e){r+=e===n?` *`:` |`});let i=[r,n.id,n.seq];for(let e in C.records.branches)C.records.branches.get(e)===n.id&&i.push(e);if(e.debug(i.join(` `)),n.parents&&n.parents.length==2&&n.parents[0]&&n.parents[1]){let e=C.records.commits.get(n.parents[0]);D(t,n,e),n.parents[1]&&t.push(C.records.commits.get(n.parents[1]))}else if(n.parents.length==0)return;else if(n.parents[0]){let e=C.records.commits.get(n.parents[0]);D(t,n,e)}t=T(t,e=>e.id),O(t)}n(O,`prettyPrintCommitHistory`);var ce=n(function(){e.debug(C.records.commits);let t=k()[0];O([t])},`prettyPrint`),le=n(function(){C.reset(),o()},`clear`),ue=n(function(){return[...C.records.branchConfig.values()].map((e,t)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${t}`)}).sort((e,t)=>(e.order??0)-(t.order??0)).map(({name:e})=>({name:e}))},`getBranchesAsObjArray`),de=n(function(){return C.records.branches},`getBranches`),fe=n(function(){return C.records.commits},`getCommits`),k=n(function(){let t=[...C.records.commits.values()];return t.forEach(function(t){e.debug(t.id)}),t.sort((e,t)=>e.seq-t.seq),t},`getCommitsArray`),A={commitType:x,getConfig:S,setDirection:te,setOptions:ne,getOptions:re,commit:ie,branch:ae,merge:oe,cherryPick:se,checkout:E,prettyPrint:ce,clear:le,getBranchesAsObjArray:ue,getBranches:de,getCommits:fe,getCommitsArray:k,getCurrentBranch:n(function(){return C.records.currBranch},`getCurrentBranch`),getDirection:n(function(){return C.records.direction},`getDirection`),getHead:n(function(){return C.records.head},`getHead`),setAccTitle:i,getAccTitle:m,getAccDescription:d,setAccDescription:r,setDiagramTitle:l,getDiagramTitle:f},pe=n((e,t)=>{y(e,t),e.dir&&t.setDirection(e.dir);for(let n of e.statements)me(n,t)},`populate`),me=n((t,r)=>{let i={Commit:n(e=>r.commit(he(e)),`Commit`),Branch:n(e=>r.branch(ge(e)),`Branch`),Merge:n(e=>r.merge(_e(e)),`Merge`),Checkout:n(e=>r.checkout(ve(e)),`Checkout`),CherryPicking:n(e=>r.cherryPick(ye(e)),`CherryPicking`)}[t.$type];i?i(t):e.error(`Unknown statement type: ${t.$type}`)},`parseStatement`),he=n(e=>({id:e.id,msg:e.message??``,type:e.type===void 0?x.NORMAL:x[e.type],tags:e.tags??void 0}),`parseCommit`),ge=n(e=>({name:e.name,order:e.order??0}),`parseBranch`),_e=n(e=>({branch:e.branch,id:e.id??``,type:e.type===void 0?void 0:x[e.type],tags:e.tags??void 0}),`parseMerge`),ve=n(e=>e.branch,`parseCheckout`),ye=n(e=>({id:e.id,targetId:``,tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),`parseCherryPicking`),be={parse:n(async t=>{let n=await v(`gitGraph`,t);e.debug(n),pe(n,A)},`parse`)},j=10,M=40,N=4,P=2,F=8,I=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]),L=12,R=new Set([`redux-color`,`redux-dark-color`]),xe=new Set([`dark`,`redux-dark`,`redux-dark-color`,`neo-dark`]),z=n((e,t,n=!1)=>n&&e>0?(e-1)%(t-1)+1:e%t,`calcColorIndex`),B=new Map,V=new Map,H=30,U=new Map,W=[],G=0,K=`LR`,q=n(()=>{B.clear(),V.clear(),U.clear(),G=0,W=[],K=`LR`},`clear`),J=n(e=>{let t=document.createElementNS(`http://www.w3.org/2000/svg`,`text`);return(typeof e==`string`?e.split(/\\n|\n|/gi):e).forEach(e=>{let n=document.createElementNS(`http://www.w3.org/2000/svg`,`tspan`);n.setAttributeNS(`http://www.w3.org/XML/1998/namespace`,`xml:space`,`preserve`),n.setAttribute(`dy`,`1em`),n.setAttribute(`x`,`0`),n.setAttribute(`class`,`row`),n.textContent=e.trim(),t.appendChild(n)}),t},`drawText`),Y=n(e=>{let t,r,i;return K===`BT`?(r=n((e,t)=>e<=t,`comparisonFunc`),i=1/0):(r=n((e,t)=>e>=t,`comparisonFunc`),i=0),e.forEach(e=>{let n=K===`TB`||K==`BT`?V.get(e)?.y:V.get(e)?.x;n!==void 0&&r(n,i)&&(t=e,i=n)}),t},`findClosestParent`),Se=n(e=>{let t=``,n=1/0;return e.forEach(e=>{let r=V.get(e).y;r<=n&&(t=e,n=r)}),t||void 0},`findClosestParentBT`),Ce=n((e,t,n)=>{let r=n,i=n,a=[];e.forEach(e=>{let n=t.get(e);if(!n)throw Error(`Commit not found for key ${e}`);n.parents.length?(r=Te(n),i=Math.max(r,i)):a.push(n),Ee(n,r)}),r=i,a.forEach(e=>{De(e,r,n)}),e.forEach(e=>{let n=t.get(e);if(n?.parents.length){let e=Se(n.parents);r=V.get(e).y-M,r<=i&&(i=r);let t=B.get(n.branch).pos,a=r-j;V.set(n.id,{x:t,y:a})}})},`setParallelBTPos`),we=n(e=>{let t=Y(e.parents.filter(e=>e!==null));if(!t)throw Error(`Closest parent not found for commit ${e.id}`);let n=V.get(t)?.y;if(n===void 0)throw Error(`Closest parent position not found for commit ${e.id}`);return n},`findClosestParentPos`),Te=n(e=>we(e)+M,`calculateCommitPosition`),Ee=n((e,t)=>{let n=B.get(e.branch);if(!n)throw Error(`Branch not found for commit ${e.id}`);let r=n.pos,i=t+j;return V.set(e.id,{x:r,y:i}),{x:r,y:i}},`setCommitPosition`),De=n((e,t,n)=>{let r=B.get(e.branch);if(!r)throw Error(`Branch not found for commit ${e.id}`);let i=t+n,a=r.pos;V.set(e.id,{x:a,y:i})},`setRootPosition`),Oe=n((e,t,n,r,i,a)=>{let{theme:o}=p(),s=I.has(o??``),c=R.has(o??``),l=xe.has(o??``);if(a===x.HIGHLIGHT)e.append(`rect`).attr(`x`,n.x-10+(s?3:0)).attr(`y`,n.y-10+(s?3:0)).attr(`width`,s?14:20).attr(`height`,s?14:20).attr(`class`,`commit ${t.id} commit-highlight${z(i,F,c)} ${r}-outer`),e.append(`rect`).attr(`x`,n.x-6+(s?2:0)).attr(`y`,n.y-6+(s?2:0)).attr(`width`,s?8:12).attr(`height`,s?8:12).attr(`class`,`commit ${t.id} commit${z(i,F,c)} ${r}-inner`);else if(a===x.CHERRY_PICK)e.append(`circle`).attr(`cx`,n.x).attr(`cy`,n.y).attr(`r`,s?7:10).attr(`class`,`commit ${t.id} ${r}`),e.append(`circle`).attr(`cx`,n.x-3).attr(`cy`,n.y+2).attr(`r`,s?2.5:2.75).attr(`fill`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`circle`).attr(`cx`,n.x+3).attr(`cy`,n.y+2).attr(`r`,s?2.5:2.75).attr(`fill`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`line`).attr(`x1`,n.x+3).attr(`y1`,n.y+1).attr(`x2`,n.x).attr(`y2`,n.y-5).attr(`stroke`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`),e.append(`line`).attr(`x1`,n.x-3).attr(`y1`,n.y+1).attr(`x2`,n.x).attr(`y2`,n.y-5).attr(`stroke`,l?`#000000`:`#fff`).attr(`class`,`commit ${t.id} ${r}`);else{let o=e.append(`circle`);if(o.attr(`cx`,n.x),o.attr(`cy`,n.y),o.attr(`r`,s?7:10),o.attr(`class`,`commit ${t.id} commit${z(i,F,c)}`),a===x.MERGE){let a=e.append(`circle`);a.attr(`cx`,n.x),a.attr(`cy`,n.y),a.attr(`r`,s?5:6),a.attr(`class`,`commit ${r} ${t.id} commit${z(i,F,c)}`)}if(a===x.REVERSE){let a=e.append(`path`),o=s?4:5;a.attr(`d`,`M ${n.x-o},${n.y-o}L${n.x+o},${n.y+o}M${n.x-o},${n.y+o}L${n.x+o},${n.y-o}`).attr(`class`,`commit ${r} ${t.id} commit${z(i,F,c)}`)}}},`drawCommitBullet`),ke=n((e,t,n,r,i)=>{if(t.type!==x.CHERRY_PICK&&(t.customId&&t.type===x.MERGE||t.type!==x.MERGE)&&i.showCommitLabel){let a=e.append(`g`),o=a.insert(`rect`).attr(`class`,`commit-label-bkg`),s=a.append(`text`).attr(`x`,r).attr(`y`,n.y+25).attr(`class`,`commit-label`).text(t.id),c=s.node()?.getBBox();if(c&&(o.attr(`x`,n.posWithOffset-c.width/2-P).attr(`y`,n.y+13.5).attr(`width`,c.width+2*P).attr(`height`,c.height+2*P),K===`TB`||K===`BT`?(o.attr(`x`,n.x-(c.width+4*N+5)).attr(`y`,n.y-12),s.attr(`x`,n.x-(c.width+4*N)).attr(`y`,n.y+c.height-12)):s.attr(`x`,n.posWithOffset-c.width/2),i.rotateCommitLabel)){if(K===`TB`||K===`BT`)s.attr(`transform`,`rotate(-45, `+n.x+`, `+n.y+`)`),o.attr(`transform`,`rotate(-45, `+n.x+`, `+n.y+`)`);else{let e=-7.5-(c.width+10)/25*9.5,t=10+c.width/25*8.5;a.attr(`transform`,`translate(`+e+`, `+t+`) rotate(-45, `+r+`, `+n.y+`)`)}}}},`drawCommitLabel`),Ae=n((e,t,n,r)=>{if(t.tags.length>0){let i=0,a=0,o=0,s=[];for(let r of t.tags.reverse()){let t=e.insert(`polygon`),c=e.append(`circle`),l=e.append(`text`).attr(`y`,n.y-16-i).attr(`class`,`tag-label`).text(r),u=l.node()?.getBBox();if(!u)throw Error(`Tag bbox not found`);a=Math.max(a,u.width),o=Math.max(o,u.height),l.attr(`x`,n.posWithOffset-u.width/2),s.push({tag:l,hole:c,rect:t,yOffset:i}),i+=20}for(let{tag:e,hole:t,rect:i,yOffset:c}of s){let s=o/2,l=n.y-19.2-c;if(i.attr(`class`,`tag-label-bkg`).attr(`points`,` + ${r-a/2-N/2},${l+P} + ${r-a/2-N/2},${l-P} + ${n.posWithOffset-a/2-N},${l-s-P} + ${n.posWithOffset+a/2+N},${l-s-P} + ${n.posWithOffset+a/2+N},${l+s+P} + ${n.posWithOffset-a/2-N},${l+s+P}`),t.attr(`cy`,l).attr(`cx`,r-a/2+N/2).attr(`r`,1.5).attr(`class`,`tag-hole`),K===`TB`||K===`BT`){let o=r+c;i.attr(`class`,`tag-label-bkg`).attr(`points`,` + ${n.x},${o+2} + ${n.x},${o-2} + ${n.x+j},${o-s-2} + ${n.x+j+a+4},${o-s-2} + ${n.x+j+a+4},${o+s+2} + ${n.x+j},${o+s+2}`).attr(`transform`,`translate(12,12) rotate(45, `+n.x+`,`+r+`)`),t.attr(`cx`,n.x+N/2).attr(`cy`,o).attr(`transform`,`translate(12,12) rotate(45, `+n.x+`,`+r+`)`),e.attr(`x`,n.x+5).attr(`y`,o+3).attr(`transform`,`translate(14,14) rotate(45, `+n.x+`,`+r+`)`)}}}},`drawCommitTags`),je=n(e=>{switch(e.customType??e.type){case x.NORMAL:return`commit-normal`;case x.REVERSE:return`commit-reverse`;case x.HIGHLIGHT:return`commit-highlight`;case x.MERGE:return`commit-merge`;case x.CHERRY_PICK:return`commit-cherry-pick`;default:return`commit-normal`}},`getCommitClassType`),Me=n((e,t,n,r)=>{let i={x:0,y:0};if(e.parents.length>0){let n=Y(e.parents);if(n){let a=r.get(n)??i;return t===`TB`?a.y+M:t===`BT`?(r.get(e.id)??i).y-M:a.x+M}}else if(t===`TB`)return H;else if(t===`BT`)return(r.get(e.id)??i).y-M;else return 0;return 0},`calculatePosition`),Ne=n((e,t,n)=>{let r=K===`BT`&&n?t:t+j,i=B.get(e.branch)?.pos,a=K===`TB`||K===`BT`?B.get(e.branch)?.pos:r;if(a===void 0||i===void 0)throw Error(`Position were undefined for commit ${e.id}`);let o=I.has(p().theme??``);return{x:a,y:K===`TB`||K===`BT`?r:i+(o?L/2+1:-2),posWithOffset:r}},`getCommitPosition`),X=n((e,t,r,i)=>{let a=e.append(`g`).attr(`class`,`commit-bullets`),o=e.append(`g`).attr(`class`,`commit-labels`),s=K===`TB`||K===`BT`?H:0,c=[...t.keys()],l=i.parallelCommits??!1,u=n((e,n)=>{let r=t.get(e)?.seq,i=t.get(n)?.seq;return r!==void 0&&i!==void 0?r-i:0},`sortKeys`),d=c.sort(u);K===`BT`&&(l&&Ce(d,t,s),d=d.reverse()),d.forEach(e=>{let n=t.get(e);if(!n)throw Error(`Commit not found for key ${e}`);l&&(s=Me(n,K,s,V));let c=Ne(n,s,l);if(r){let e=je(n),t=n.customType??n.type,r=B.get(n.branch)?.index??0;Oe(a,n,c,e,r,t),ke(o,n,c,s,i),Ae(o,n,c,s)}K===`TB`||K===`BT`?V.set(n.id,{x:c.x,y:c.posWithOffset}):V.set(n.id,{x:c.posWithOffset,y:c.y}),s=K===`BT`&&l?s+M:s+M+j,s>G&&(G=s)})},`drawCommits`),Pe=n((e,t,r,i,a)=>{let o=(K===`TB`||K===`BT`?r.xe.branch===o,`isOnBranchToGetCurve`),c=n(n=>n.seq>e.seq&&n.seqc(e)&&s(e))},`shouldRerouteArrow`),Z=n((e,t,n=0)=>{let r=e+Math.abs(e-t)/2;return n>5?r:W.every(e=>Math.abs(e-r)>=10)?(W.push(r),r):Z(e,t-Math.abs(e-t)/5,n+1)},`findLane`),Fe=n((e,t,n,r)=>{let{theme:i}=p(),a=R.has(i??``),o=V.get(t.id),s=V.get(n.id);if(o===void 0||s===void 0)throw Error(`Commit positions not found for commits ${t.id} and ${n.id}`);let c=Pe(t,n,o,s,r),l=``,u=``,d=0,f=0,m=B.get(n.branch)?.index;n.type===x.MERGE&&t.id!==n.parents[0]&&(m=B.get(t.branch)?.index);let h;if(c){l=`A 10 10, 0, 0, 0,`,u=`A 10 10, 0, 0, 1,`,d=10,f=10;let e=o.ys.x&&(l=`A 20 20, 0, 0, 0,`,u=`A 20 20, 0, 0, 1,`,d=20,f=20,h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${o.x} ${s.y-d} ${u} ${o.x-f} ${s.y} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${s.x+d} ${o.y} ${l} ${s.x} ${o.y+f} L ${s.x} ${s.y}`),o.x===s.x&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`)):K===`BT`?(o.xs.x&&(l=`A 20 20, 0, 0, 0,`,u=`A 20 20, 0, 0, 1,`,d=20,f=20,h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${o.x} ${s.y+d} ${l} ${o.x-f} ${s.y} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${s.x+d} ${o.y} ${u} ${s.x} ${o.y-f} L ${s.x} ${s.y}`),o.x===s.x&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`)):(o.ys.y&&(h=n.type===x.MERGE&&t.id!==n.parents[0]?`M ${o.x} ${o.y} L ${s.x-d} ${o.y} ${l} ${s.x} ${o.y-f} L ${s.x} ${s.y}`:`M ${o.x} ${o.y} L ${o.x} ${s.y+d} ${u} ${o.x+f} ${s.y} L ${s.x} ${s.y}`),o.y===s.y&&(h=`M ${o.x} ${o.y} L ${s.x} ${s.y}`));if(h===void 0)throw Error(`Line definition not found`);e.append(`path`).attr(`d`,h).attr(`class`,`arrow arrow`+z(m,F,a))},`drawArrow`),Ie=n((e,t)=>{let n=e.append(`g`).attr(`class`,`commit-arrows`);[...t.keys()].forEach(e=>{let r=t.get(e);r.parents&&r.parents.length>0&&r.parents.forEach(e=>{Fe(n,t.get(e),r,t)})})},`drawArrows`),Le=n((e,t,n,r)=>{let{look:i,theme:a,themeVariables:o}=p(),{dropShadow:s,THEME_COLOR_LIMIT:c}=o,l=I.has(a??``),u=R.has(a??``),d=e.append(`g`);t.forEach((e,t)=>{let a=z(t,l?c:F,u),o=B.get(e.name)?.pos;if(o===void 0)throw Error(`Position not found for branch ${e.name}`);let f=K===`TB`||K===`BT`?o:l?o+L/2+1:o-2,p=d.append(`line`);p.attr(`x1`,0),p.attr(`y1`,f),p.attr(`x2`,G),p.attr(`y2`,f),p.attr(`class`,`branch branch`+a),K===`TB`?(p.attr(`y1`,H),p.attr(`x1`,o),p.attr(`y2`,G),p.attr(`x2`,o)):K===`BT`&&(p.attr(`y1`,G),p.attr(`x1`,o),p.attr(`y2`,H),p.attr(`x2`,o)),W.push(f);let m=e.name,h=J(m),g=d.insert(`rect`),_=d.insert(`g`).attr(`class`,`branchLabel`).insert(`g`).attr(`class`,`label branch-label`+a);_.node().appendChild(h);let v=h.getBBox(),y=l?0:4,b=l?16:0,x=l?L:0;i===`neo`&&g.attr(`data-look`,`neo`),g.attr(`class`,`branchLabelBkg label`+a).attr(`style`,i===`neo`?`filter:${l?`url(#${r}-drop-shadow)`:s}`:``).attr(`rx`,y).attr(`ry`,y).attr(`x`,-v.width-4-(n.rotateCommitLabel===!0?30:0)).attr(`y`,-v.height/2+10).attr(`width`,v.width+18+b).attr(`height`,v.height+4+x),_.attr(`transform`,`translate(`+(-v.width-14-(n.rotateCommitLabel===!0?30:0)+b/2)+`, `+(f-v.height/2-2)+`)`),K===`TB`?(g.attr(`x`,o-v.width/2-10).attr(`y`,0),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, 0)`),l&&(g.attr(`transform`,`translate(${-b/2-3}, ${-x-10})`),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+(-x*2+7)+`)`))):K===`BT`?(g.attr(`x`,o-v.width/2-10).attr(`y`,G),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+G+`)`),l&&(g.attr(`transform`,`translate(${-b/2-3}, ${x+10})`),_.attr(`transform`,`translate(`+(o-v.width/2-5)+`, `+(G+x*2+4)+`)`))):g.attr(`transform`,`translate(-19, `+(f-12-x/2)+`)`)})},`drawBranches`),Re=n(function(e,t,n,r,i){return B.set(e,{pos:t,index:n}),t+=50+(i?40:0)+(K===`TB`||K===`BT`?r.width/2:0),t},`setBranchPosition`),ze={draw:n(function(n,r,i,o){q(),e.debug(`in gitgraph renderer`,n+` +`,`id:`,r,i);let s=o.db;if(!s.getConfig){e.error(`getConfig method is not available on db`);return}let c=s.getConfig(),l=c.rotateCommitLabel??!1;U=s.getCommits();let u=s.getBranchesAsObjArray();K=s.getDirection();let d=t(`[id="${r}"]`),{look:f,theme:m,themeVariables:g}=p(),{useGradient:_,gradientStart:v,gradientStop:y,filterColor:b}=g;if(_){let e=d.append(`defs`).append(`linearGradient`).attr(`id`,r+`-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);e.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,v).attr(`stop-opacity`,1),e.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,y).attr(`stop-opacity`,1)}f===`neo`&&I.has(m??``)&&d.append(`defs`).append(`filter`).attr(`id`,r+`-drop-shadow`).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,b);let x=0;u.forEach((e,t)=>{let n=J(e.name),r=d.append(`g`),i=r.insert(`g`).attr(`class`,`branchLabel`),a=i.insert(`g`).attr(`class`,`label branch-label`);a.node()?.appendChild(n);let o=n.getBBox();x=Re(e.name,x,t,o,l),a.remove(),i.remove(),r.remove()}),X(d,U,!1,c),c.showBranches&&Le(d,u,c,r),Ie(d,U),X(d,U,!0,c),h.insertTitle(d,`gitTitleText`,c.titleTopMargin??0,s.getDiagramTitle()),a(void 0,d,c.diagramPadding,c.useMaxWidth)},`draw`)},Q=8,$=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`]),Be=new Set([`redux-color`,`redux-dark-color`]),Ve=new Set([`neo`,`neo-dark`]),He=new Set([`dark`,`redux-dark`,`redux-dark-color`,`neo-dark`]),Ue=new Set([`redux`,`redux-dark`,`redux-color`,`redux-dark-color`,`neo`,`neo-dark`]),We=n(e=>{let{svgId:t}=e,n=``;if(e.useGradient&&t)for(let r=0;r{let{theme:t,themeVariables:n}=s(),{borderColorArray:r}=n,i=$.has(t);if(Ve.has(t)){let t=``;for(let n=0;n`${Array.from({length:e.THEME_COLOR_LIMIT},(e,t)=>t).map(t=>{let n=t%Q;return` + .branch-label${t} { fill: ${e[`gitBranchLabel`+n]}; } + .commit${t} { stroke: ${e[`git`+n]}; fill: ${e[`git`+n]}; } + .commit-highlight${t} { stroke: ${e[`gitInv`+n]}; fill: ${e[`gitInv`+n]}; } + .label${t} { fill: ${e[`git`+n]}; } + .arrow${t} { stroke: ${e[`git`+n]}; } + `}).join(` +`)}`,`normalTheme`),qe={parser:be,db:A,renderer:ze,styles:n(e=>{let{theme:t}=s(),n=Ue.has(t);return` + .commit-id, + .commit-msg, + .branch-label { + fill: lightgrey; + color: lightgrey; + font-family: 'trebuchet ms', verdana, arial, sans-serif; + font-family: var(--mermaid-font-family); + } + + ${n?Ge(e):Ke(e)} + + .branch { + stroke-width: ${e.strokeWidth}; + stroke: ${e.commitLineColor??e.lineColor}; + stroke-dasharray: ${n?`4 2`:`2`}; + } + .commit-label { font-size: ${e.commitLabelFontSize}; fill: ${n?e.nodeBorder:e.commitLabelColor}; ${n?`font-weight:${e.noteFontWeight};`:``}} + .commit-label-bkg { font-size: ${e.commitLabelFontSize}; fill: ${n?`transparent`:e.commitLabelBackground}; opacity: ${n?``:.5}; } + .tag-label { font-size: ${e.tagLabelFontSize}; fill: ${e.tagLabelColor};} + .tag-label-bkg { fill: ${n?e.mainBkg:e.tagLabelBackground}; stroke: ${n?e.nodeBorder:e.tagLabelBorder}; ${n?`filter:${e.dropShadow}`:``} } + .tag-hole { fill: ${e.textColor}; } + + .commit-merge { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + } + .commit-reverse { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + stroke-width: ${n?e.strokeWidth:3}; + } + .commit-highlight-outer { + } + .commit-highlight-inner { + stroke: ${n?e.mainBkg:e.primaryColor}; + fill: ${n?e.mainBkg:e.primaryColor}; + } + + .arrow { + /* Intentional: neo themes keep the bold 8px arrow (like classic themes); only redux-geometry themes use the thinner options.strokeWidth. */ + stroke-width: ${$.has(t)?e.strokeWidth:8}; + stroke-linecap: round; + fill: none + } + .gitTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } +`},`getStyles`)};export{qe as diagram}; \ No newline at end of file diff --git a/www/assets/graphlib-C9Tl7QrK.js b/www/assets/graphlib-C9Tl7QrK.js new file mode 100644 index 0000000..dbe1de2 --- /dev/null +++ b/www/assets/graphlib-C9Tl7QrK.js @@ -0,0 +1 @@ +import{A as e,I as t,a as n,at as r,c as i,d as a,i as o,n as s,o as c,q as l,r as u,rt as d,t as f}from"./_baseUniq-DR4vVjyC.js";var p=l(function(t){return f(e(t,1,a,!0))}),m=`\0`,h=`\0`,g=``,_=class{constructor(e={}){this._isDirected=!Object.prototype.hasOwnProperty.call(e,`directed`)||e.directed,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,`multigraph`)?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=d(void 0),this._defaultEdgeLabelFn=d(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[h]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return r(e)||(e=d(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return t(this._nodes)}sources(){var e=this;return c(this.nodes(),function(t){return o(e._in[t])})}sinks(){var e=this;return c(this.nodes(),function(t){return o(e._out[t])})}setNodes(e,t){var n=arguments,r=this;return i(e,function(e){n.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=h,this._children[e]={},this._children[h][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var n=e=>this.removeEdge(this._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],i(this.children(e),e=>{this.setParent(e)}),delete this._children[e]),i(t(this._in[e]),n),delete this._in[e],delete this._preds[e],i(t(this._out[e]),n),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(u(t))t=h;else{t+=``;for(var n=t;!u(n);n=this.parent(n))if(n===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==h)return t}}children(e){if(u(e)&&(e=h),this._isCompound){var n=this._children[e];if(n)return t(n)}else if(e===h)return this.nodes();else if(this.hasNode(e))return[]}predecessors(e){var n=this._preds[e];if(n)return t(n)}successors(e){var n=this._sucs[e];if(n)return t(n)}neighbors(e){var t=this.predecessors(e);if(t)return p(t,this.successors(e))}isLeaf(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;i(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),i(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))});var r={};function a(e){var i=n.parent(e);return i===void 0||t.hasNode(i)?(r[e]=i,i):i in r?r[i]:a(i)}return this._isCompound&&i(t.nodes(),function(e){t.setParent(e,a(e))}),t}setDefaultEdgeLabel(e){return r(e)||(e=d(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return n(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return s(e,function(e,i){return r.length>1?n.setEdge(e,i,t):n.setEdge(e,i),i}),this}setEdge(){var e,t,n,r,i=!1,a=arguments[0];typeof a==`object`&&a&&`v`in a?(e=a.v,t=a.w,n=a.name,arguments.length===2&&(r=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),e=``+e,t=``+t,u(n)||(n=``+n);var o=b(this._isDirected,e,t,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!u(n)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(e,t,n);var s=x(this._isDirected,e,t,n);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[o]=s,v(this._preds[t],e),v(this._sucs[e],t),this._in[t][o]=s,this._out[e][o]=s,this._edgeCount++,this}edge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n);return this._edgeLabels[r]}hasEdge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(e,t,n){var r=arguments.length===1?S(this._isDirected,arguments[0]):b(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],y(this._preds[t],e),y(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var r=this._in[e];if(r){var i=n(r);return t?c(i,function(e){return e.v===t}):i}}outEdges(e,t){var r=this._out[e];if(r){var i=n(r);return t?c(i,function(e){return e.w===t}):i}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}};_.prototype._nodeCount=0,_.prototype._edgeCount=0;function v(e,t){e[t]?e[t]++:e[t]=1}function y(e,t){--e[t]||delete e[t]}function b(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}return i+g+a+g+(u(r)?m:r)}function x(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function S(e,t){return b(e,t.v,t.w,t.name)}export{_ as t}; \ No newline at end of file diff --git a/www/assets/index-0i5Xvc5h.css b/www/assets/index-0i5Xvc5h.css new file mode 100644 index 0000000..00e08a2 --- /dev/null +++ b/www/assets/index-0i5Xvc5h.css @@ -0,0 +1 @@ +:root,[data-theme=deep-ocean]{--bg-base:#07181b;--bg-card:#0d2c2f;--border-card:#15474d;--primary:#0891b2;--primary-hover:#0e7490;--accent:#14b8a6;--accent-light:#2dd4bf;--danger:#ef4444;--danger-hover:#dc2626;--text:#f8fafc;--text-muted:#94a3b8;--code-bg:#00000059;--radius:10px;--font-family-base:"Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-family-heading:"Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-family-mono:"JetBrains Mono", monospace;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--font-weight-extrabold:800;--font-size-xs:.75rem;--font-size-sm:.85rem;--font-size-base:1rem;--font-size-lg:1.15rem;--font-size-xl:1.35rem;--font-size-2xl:1.65rem}[data-theme=midnight-blue]{--bg-base:#0a0f1d;--bg-card:#121a2fa6;--border-card:#ffffff14;--primary:#3b82f6;--primary-hover:#2563eb;--accent:#14b8a6;--accent-light:#2dd4bf;--danger:#ef4444;--danger-hover:#dc2626;--text:#f8fafc;--text-muted:#94a3b8;--code-bg:#00000059;--radius:12px}[data-theme=lavender-haze],[data-theme=aqua-breeze],[data-theme=arctic-frost]{--bg-base:#f5f3ff;--bg-card:#faf8ff;--border-card:#ddd6fe;--primary:#7c3aed;--primary-hover:#6d28d9;--accent:#ec4899;--accent-light:#f472b6;--danger:#dc2626;--danger-hover:#b91c1c;--text:#1e1035;--text-muted:#6b5b82;--code-bg:#7c3aed14;--radius:10px}[data-theme=amber-warmth],[data-theme=azure-daylight],[data-theme=solar-daybreak]{--bg-base:#fdf8f4;--bg-card:#fff;--border-card:#fed7aa;--primary:#ea580c;--primary-hover:#c2410c;--accent:#d97706;--accent-light:#f59e0b;--danger:#dc2626;--danger-hover:#b91c1c;--text:#291508;--text-muted:#7c5e4a;--code-bg:#ea580c14;--radius:12px}*{box-sizing:border-box;margin:0;padding:0}h1,h2,h3,h4,h5,h6{font-family:var(--font-family-heading)}body{font-family:var(--font-family-base);background-color:var(--bg-base);color:var(--text);min-height:100vh;display:block;position:relative;overflow:hidden scroll}.dashboard-container{z-index:1;flex-direction:column;gap:16px;width:100%;min-width:0;max-width:1720px;margin:0 auto;padding:16px 20px;display:flex}.dashboard-header{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);box-sizing:border-box;justify-content:space-between;align-items:center;gap:16px;min-height:52px;padding:10px 18px;display:flex}.header-brand{flex-shrink:0;align-items:center;gap:12px;display:flex}.menu-toggle-btn{border:1px solid var(--border-card);color:var(--text);cursor:pointer;background:#ffffff14;border-radius:6px;padding:6px 10px;font-size:1.1rem;transition:all .2s;display:none}.menu-toggle-btn:hover{background:#ffffff26}.header-logo{align-items:center;gap:8px;display:flex}.logo-icon{color:var(--accent-light);font-size:1.3rem}.header-title{align-items:center;gap:8px;display:flex}.header-title h1{letter-spacing:-.4px;white-space:nowrap;margin:0;font-size:1.15rem;font-weight:700}.dashboard-nav{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);scrollbar-width:none;white-space:nowrap;box-sizing:border-box;flex-direction:row;align-items:center;gap:6px;width:100%;padding:6px 10px;display:flex;overflow:auto}.dashboard-nav::-webkit-scrollbar{display:none}.nav-tab{color:var(--text-muted);box-sizing:border-box;cursor:pointer;white-space:nowrap;background:0 0;border:1px solid #0000;border-radius:6px;flex:1 0;justify-content:center;align-items:center;gap:7px;min-height:36px;padding:8px 10px;font-family:inherit;font-size:.86rem;font-weight:600;transition:all .15s;display:inline-flex}.nav-tab:hover{color:var(--text);background:#ffffff0f}.nav-tab.active{color:#fff;background:color-mix(in srgb, var(--primary) 22%, transparent);border-color:color-mix(in srgb, var(--primary) 45%, transparent)}.header-status{flex-shrink:0;align-items:center;gap:8px;display:flex}.status-item{background:#00000040;border:1px solid #ffffff0d;border-radius:6px;flex-direction:row;align-items:center;gap:6px;padding:4px 10px;display:flex}.status-item .label{color:var(--text-muted);font-size:.72rem;font-weight:500;display:inline-block}.status-item .value{white-space:nowrap;align-items:center;gap:4px;font-size:.78rem;font-weight:600;display:flex}.indicator{border-radius:50%;width:8px;height:8px;display:inline-block}.indicator.online{background:#10b981;box-shadow:0 0 10px #10b981}.indicator.indexing{background:#f59e0b;animation:1.5s infinite pulse;box-shadow:0 0 10px #f59e0b}@keyframes pulse{0%{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(1.2)}to{opacity:1;transform:scale(1)}}.glass-card{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);width:100%;min-width:0;padding:16px 20px}.glass-card h2{align-items:center;gap:8px;margin-bottom:12px;font-size:1.05rem;font-weight:600;display:flex}.tab-content{width:100%;min-width:0;display:none}.tab-content.active{flex-direction:column;gap:16px;width:100%;min-width:0;display:flex}.overview-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,200px),1fr));gap:12px;display:grid}.stat-metric{align-items:center;gap:12px;padding:14px 16px;display:flex}.metric-icon{color:var(--accent-light);background:#14b8a626;border-radius:10px;justify-content:center;align-items:center;width:40px;height:40px;font-size:1.4rem;display:flex}.metric-info{flex-direction:column;gap:4px;display:flex}.metric-info .stat-number{font-size:var(--font-size-xl);font-weight:var(--font-weight-extrabold);font-family:var(--font-family-mono);color:var(--text);line-height:1.1}.metric-info .stat-label{color:var(--text-muted);font-size:.85rem}.two-col-layout{grid-template-columns:1fr 1fr;gap:20px;display:grid}@media (width<=900px){.two-col-layout{grid-template-columns:1fr}}.specs-list{flex-direction:column;gap:12px;margin-top:12px;display:flex}.spec-row{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;gap:12px;padding:10px 0;font-size:.9rem;display:flex}.spec-row span:first-child{color:var(--text-muted);flex-shrink:0;font-weight:500}code,.code{background:var(--code-bg);vertical-align:baseline;word-break:break-word;overflow-wrap:break-word;border-radius:4px;max-width:100%;padding:1px 5px;font-family:JetBrains Mono,Fira Code,monospace;font-size:.85em;line-height:1.25;display:inline-block}.spec-row span:last-child,.spec-row code{text-align:right;word-break:break-word;max-width:100%}@media (width<=576px){.spec-row{flex-direction:column;align-items:flex-start;gap:6px}.spec-row span:last-child,.spec-row code{text-align:left}.stat-metric{padding:16px}.path-input-row{flex-direction:column}.browser-breadcrumbs{word-break:break-all}}.tag-cloud{flex-wrap:wrap;gap:8px;max-height:250px;margin-top:12px;display:flex;overflow-y:auto}.topic-tag{background:color-mix(in srgb, var(--accent) 12%, transparent);border:1px solid color-mix(in srgb, var(--accent) 25%, transparent);color:var(--accent);font-size:var(--font-size-xs);font-family:var(--font-family-mono);border-radius:6px;padding:4px 10px}.badge{white-space:nowrap;border-radius:6px;align-items:center;gap:6px;max-width:100%;padding:3px 8px;font-size:.75rem;font-weight:600;display:inline-flex}.badge-primary{background:color-mix(in srgb, var(--primary) 15%, transparent);color:var(--primary);border:1px solid color-mix(in srgb, var(--primary) 30%, transparent)}.badge-accent{background:color-mix(in srgb, var(--accent) 15%, transparent);color:var(--accent);border:1px solid color-mix(in srgb, var(--accent) 30%, transparent)}.badge-success{color:#6ee7b7;background:#10b98133;border:1px solid #10b9814d}.badge-danger{color:#fca5a5;background:#ef444433;border:1px solid #ef44444d}code,.code{font-family:var(--font-family-mono);background:var(--code-bg);border-radius:4px;padding:2px 6px;font-size:.85rem}.desktop-table-view{display:block}.mobile-card-list{flex-direction:column;gap:14px;display:none}.data-mobile-card{border:1px solid var(--border-card);background:#ffffff06;border-radius:10px;flex-direction:column;gap:12px;padding:16px;display:flex}.data-mobile-card-header{justify-content:space-between;align-items:center;gap:10px;display:flex}.data-mobile-card-body{flex-direction:column;gap:8px;font-size:.85rem;display:flex}.data-mobile-card-actions{border-top:1px solid #ffffff0f;flex-wrap:wrap;gap:8px;margin-top:4px;padding-top:10px;display:flex}.data-mobile-card-actions .btn{flex:calc(50% - 8px);justify-content:center;min-width:0}.card-header-btn{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;margin-bottom:16px;display:flex}.card-header-btn>div{flex:1 1 0;min-width:0;max-width:100%}.card-header-btn p{overflow-wrap:anywhere;word-break:break-word;margin:0}.table-container{-webkit-overflow-scrolling:touch;max-width:100%;margin-top:10px;overflow-x:auto}table{border-collapse:collapse;table-layout:auto;width:100%;font-size:.9rem}th{text-align:left;color:var(--text-muted);border-bottom:1px solid var(--border-card);white-space:nowrap;padding:12px 14px;font-weight:600}td{border-bottom:1px solid var(--border-card);color:var(--text);padding:14px}td a.repo-url-link,td a[href*=http]{text-overflow:ellipsis;white-space:nowrap;vertical-align:middle;max-width:220px;display:inline-block;overflow:hidden}tr:hover td{background:color-mix(in srgb, var(--text) 3%, transparent)}.empty-state{text-align:center;color:var(--text-muted);padding:40px!important}.btn{cursor:pointer;border:none;border-radius:8px;align-items:center;gap:8px;padding:8px 16px;font-family:inherit;font-size:.9rem;font-weight:600;transition:all .2s;display:inline-flex}.btn-primary{background:var(--primary);color:#fff}.btn-primary:hover{background:var(--primary-hover)}.btn-secondary{background:color-mix(in srgb, var(--text) 10%, transparent);color:var(--text);border:1px solid var(--border-card)}.btn-secondary:hover{background:color-mix(in srgb, var(--text) 16%, transparent)}.btn-icon{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;padding:6px;font-size:.9rem;transition:all .2s}.btn-icon:hover{color:var(--text);background:color-mix(in srgb, var(--text) 10%, transparent)}.btn-delete:hover{color:var(--danger)}.form-group{flex-direction:column;gap:6px;margin-bottom:14px;display:flex}.form-group label{color:var(--text-muted);font-size:.85rem;font-weight:600}.form-row{box-sizing:border-box;gap:14px;width:100%;display:flex}.form-row>.form-group{flex:1;min-width:0}.form-row-3col{box-sizing:border-box;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:12px;width:100%;display:grid}.form-row-3col>.form-group{min-width:0}input[type=text],input[type=url],input[type=password],input[type=number],select,textarea{background:var(--code-bg);border:1px solid var(--border-card);color:var(--text);box-sizing:border-box;border-radius:8px;outline:none;width:100%;min-width:0;max-width:100%;padding:10px 14px;font-family:inherit;font-size:.9rem;transition:border-color .2s}input:focus,select:focus,textarea:focus{border-color:var(--primary)}.path-input-row{gap:8px;display:flex}.path-input-row input{flex:1}.modal-backdrop{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);z-index:10000;box-sizing:border-box;background:#000000bf;justify-content:center;align-items:center;width:100vw;max-width:100vw;height:100vh;padding:24px 16px;display:flex;position:fixed;inset:0;overflow-y:auto}.modal-card{background:var(--bg-card);border:1px solid var(--border-card);box-sizing:border-box;width:90%;max-width:550px;max-height:calc(100vh - 48px);margin:auto;overflow-y:auto}.modal-header{justify-content:space-between;align-items:center;margin-bottom:20px;display:flex}.modal-header h2{margin-bottom:0}.btn-close{color:var(--text-muted);cursor:pointer;background:0 0;border:none;font-size:1.5rem}.modal-footer{justify-content:flex-end;gap:10px;margin-top:20px;display:flex}.browser-body{margin:16px 0}.browser-breadcrumbs{background:#0000004d;border-radius:6px;margin-bottom:12px;padding:8px 12px;font-size:.85rem}.browser-list-container{background:#0003;border:1px solid #ffffff14;border-radius:6px;max-height:300px;overflow-y:auto}.browser-list{list-style:none}.browser-item{cursor:pointer;border-bottom:1px solid #ffffff0a;align-items:center;gap:10px;padding:8px 12px;font-size:.9rem;display:flex}.browser-item:hover{background:#ffffff0f}.search-hit-card{background:#0000004d;border:1px solid #ffffff14;border-radius:8px;margin-bottom:14px;padding:16px}.search-hit-header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;margin-bottom:10px;display:flex}.search-hit-code{background:var(--code-bg);border:1px solid var(--border-card);font-family:var(--font-family-mono);white-space:pre-wrap;word-break:break-all;color:var(--text);border-radius:6px;margin-top:8px;padding:12px;font-size:.85rem;overflow-x:auto}.search-mode-segmented{border:1px solid var(--border-card);background:#ffffff0d;border-radius:8px;gap:4px;margin-bottom:14px;padding:3px;display:inline-flex}.search-mode-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;align-items:center;gap:6px;padding:6px 14px;font-size:.85rem;transition:all .15s ease-in-out;display:flex}.search-mode-btn:hover{color:var(--text);background:#ffffff0f}.search-mode-btn.active{background:var(--primary);color:#fff;font-weight:600;box-shadow:0 2px 6px #0003}.hybrid-slider-container{border:1px solid var(--border-card);background:#ffffff05;border-radius:8px;margin-bottom:16px;padding:12px 16px}.hybrid-slider-header{justify-content:space-between;align-items:center;margin-bottom:8px;font-size:.85rem;display:flex}.hybrid-split-value{font-family:var(--font-family-mono);color:var(--accent);font-weight:600}.hybrid-range-input{width:100%;accent-color:var(--primary);cursor:pointer}.hybrid-presets{flex-wrap:wrap;gap:6px;margin-top:10px;display:flex}.btn-preset{border:1px solid var(--border-card);color:var(--text-muted);cursor:pointer;background:#ffffff0a;border-radius:4px;padding:3px 8px;font-size:.75rem;transition:all .15s}.btn-preset:hover{color:var(--text);border-color:var(--primary);background:rgba(var(--primary-rgb), .1)}.btn-preset.active{background:rgba(var(--primary-rgb), .25);border-color:var(--primary);color:var(--primary);font-weight:600}.search-hit-signature{border-left:3px solid var(--primary);font-family:var(--font-family-mono);color:var(--accent);background:#ffffff08;border-radius:0 4px 4px 0;margin-bottom:6px;padding:6px 10px;font-size:.82rem;overflow-x:auto}.search-hit-actions{align-items:center;gap:8px;display:flex}.badge-info{color:#38bdf8;background:#38bdf826;border:1px solid #38bdf84d}.badge-warning{color:#fbbf24;background:#fbbf2426;border:1px solid #fbbf244d}.dashboard-footer{text-align:center;color:var(--text-muted);padding:20px 0;font-size:.8rem}@media (width<=768px){.menu-toggle-btn{justify-content:center;align-items:center;display:inline-flex}.dashboard-header{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px;min-height:auto;max-height:none;padding:12px 14px;display:flex}.header-brand{order:1;align-items:center;display:flex}.menu-toggle-btn{order:2;justify-content:center;align-items:center;display:inline-flex}.header-status{border-top:1px solid #ffffff0f;flex-wrap:wrap;order:3;justify-content:space-between;gap:8px 12px;width:100%;padding-top:8px;display:flex}.status-item{align-items:center}.dashboard-nav{border:1px solid var(--border-card);border-radius:var(--radius);background:#00000059;flex-direction:column;gap:6px;max-height:60vh;margin:4px 0 0;padding:10px;display:none;overflow:auto}.dashboard-nav.drawer-open{animation:.25s ease-out forwards drawer-slide-down;display:flex}.nav-tab{justify-content:flex-start;width:100%;padding:10px 14px;font-size:.92rem}.dashboard-container{box-sizing:border-box;max-width:100vw;padding:16px 12px}.vs-box{box-sizing:border-box;max-width:100%;padding:16px 12px}.glass-card{box-sizing:border-box;max-width:100%;padding:18px 14px}.desktop-table-view{display:none}.mobile-card-list{display:flex}.card-header-btn{flex-direction:column;align-items:stretch;gap:14px}.form-row,.form-row-3col{flex-direction:column;gap:12px;display:flex!important}.search-hit-header{flex-direction:column;align-items:flex-start;gap:8px}.search-form-btn-group{align-self:stretch!important}.search-form-btn-group .btn{justify-content:center;width:100%}.log-viewer-header{flex-direction:column;align-items:stretch;gap:12px}.log-viewer-actions{justify-content:space-between;width:100%}.log-toolbar{flex-direction:column;align-items:stretch;gap:12px}.log-filter-pills{-webkit-overflow-scrolling:touch;padding-bottom:4px;overflow-x:auto}.log-search-wrapper{width:100%;min-width:0;max-width:100%}.log-entry-main{flex-direction:column;align-items:flex-start;gap:4px}.sync-progress-container{min-width:unset;width:100%;max-width:100%}.sync-file-caption{max-width:100%}}@keyframes drawer-slide-down{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toast-container{z-index:9999;pointer-events:none;flex-direction:column;gap:10px;display:flex;position:fixed;bottom:24px;right:24px}.toast{color:#fff;pointer-events:auto;background:#1e293b;border-left:4px solid #0000;border-radius:8px;align-items:center;gap:12px;max-width:400px;padding:14px 20px;font-size:.95rem;font-weight:500;animation:.3s ease-out forwards toast-slide-in;display:flex;box-shadow:0 10px 25px #00000080}@keyframes toast-slide-in{0%{opacity:0;transform:translate(50px)}to{opacity:1;transform:translate(0)}}.toast-success{border-left-color:#10b981}.toast-success i{color:#10b981}.toast-error{border-left-color:#ef4444}.toast-error i{color:#ef4444}.toast-info{border-left-color:#3b82f6}.toast-info i{color:#3b82f6}.toast-warning{border-left-color:#f59e0b}.toast-warning i{color:#f59e0b}.toast-message{flex:1;line-height:1.4}.toast-dismiss-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:4px;justify-content:center;align-items:center;margin-left:6px;padding:4px;font-size:.85rem;transition:all .2s;display:inline-flex}.toast-dismiss-btn:hover{color:#fff;background:#ffffff1f}.log-viewer-container{flex-direction:column;gap:16px;display:flex}.log-viewer-header{flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:16px;display:flex}.log-viewer-actions{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.log-autoscroll-label{color:var(--text-muted);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:6px;font-size:.85rem;font-weight:500;display:inline-flex}.log-autoscroll-label input[type=checkbox]{cursor:pointer;accent-color:var(--primary)}.log-toolbar{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:16px;display:flex}.log-filter-pills{flex-wrap:wrap;gap:8px;display:flex}.log-filter-btn{color:var(--text-muted);cursor:pointer;background:#ffffff0d;border:1px solid #ffffff1a;border-radius:20px;align-items:center;gap:6px;padding:5px 12px;font-family:inherit;font-size:.8rem;font-weight:600;transition:all .2s;display:inline-flex}.log-filter-btn:hover{color:var(--text);background:#ffffff1a}.log-filter-btn.active{color:#93c5fd;background:#3b82f633;border-color:#3b82f666}.log-filter-btn.warning.active{color:#fcd34d;background:#f59e0b33;border-color:#f59e0b66}.log-filter-btn.error.active{color:#fca5a5;background:#ef444433;border-color:#ef444466}.log-filter-btn.debug.active{color:#cbd5e1;background:#94a3b833;border-color:#94a3b866}.pill-count{background:#0000004d;border-radius:10px;padding:1px 6px;font-size:.72rem}.log-search-wrapper{flex:1;align-items:center;min-width:280px;max-width:480px;display:flex;position:relative}.log-search-wrapper .search-icon{color:var(--text-muted);pointer-events:none;font-size:.85rem;position:absolute;left:12px}.log-search-input{background:var(--code-bg);border:1px solid var(--border-card);width:100%;color:var(--text);border-radius:8px;outline:none;padding:8px 32px 8px 34px;font-family:inherit;font-size:.85rem;transition:border-color .2s}.log-search-input:focus{border-color:var(--primary)}.clear-search-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;padding:4px;font-size:.8rem;position:absolute;right:8px}.clear-search-btn:hover{color:var(--text)}.log-stream-container{background:var(--code-bg);border:1px solid var(--border-card);min-height:320px;max-height:580px;font-family:var(--font-family-mono);border-radius:8px;padding:12px;overflow-y:auto}.log-stream-list{flex-direction:column;gap:4px;display:flex}.log-entry{background:#ffffff04;border-left:3px solid #0000;border-radius:6px;padding:8px 12px;font-size:.82rem;line-height:1.5;transition:background .15s}.log-entry:hover{background:#ffffff09}.log-entry.log-level-info{border-left-color:#3b82f6}.log-entry.log-level-warning{background:#f59e0b08;border-left-color:#f59e0b}.log-entry.log-level-error{background:#ef44440f;border-left-color:#ef4444}.log-entry.log-level-debug{opacity:.85;border-left-color:#64748b}.log-entry-main{flex-wrap:wrap;align-items:baseline;gap:10px;display:flex}.log-timestamp{color:var(--text-muted);white-space:nowrap;font-size:.78rem}.log-logger{color:var(--accent-light);font-size:.78rem}.log-message{color:#e2e8f0;word-break:break-word;flex:1}.btn-traceback-toggle{color:#fca5a5;cursor:pointer;background:#ef44441f;border:1px solid #ef44444d;border-radius:4px;align-items:center;gap:5px;padding:2px 8px;font-family:inherit;font-size:.75rem;transition:all .2s;display:inline-flex}.btn-traceback-toggle:hover{background:#ef444438}.log-traceback-wrapper{margin-top:8px;padding-left:8px}.traceback-box{background:color-mix(in srgb, var(--danger) 10%, transparent);border:1px solid color-mix(in srgb, var(--danger) 30%, transparent);color:var(--danger);font-family:var(--font-family-mono);white-space:pre-wrap;border-radius:6px;padding:10px 14px;font-size:.78rem;line-height:1.45;overflow-x:auto}.settings-dashboard-layout{align-items:flex-start;gap:20px;width:100%;min-height:520px;display:flex}.settings-category-sidebar{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);box-sizing:border-box;flex-direction:column;gap:4px;width:240px;min-width:240px;padding:10px;display:flex}.settings-category-btn{width:100%;color:var(--text-muted);cursor:pointer;text-align:left;background:0 0;border:none;border-radius:6px;align-items:center;gap:10px;padding:10px 14px;font-size:.84rem;font-weight:500;transition:all .2s;display:flex}.settings-category-btn svg,.settings-category-btn i{text-align:center;flex-shrink:0;width:16px}.settings-category-btn:hover{color:var(--text);background:#ffffff0d}.settings-category-btn.active{color:var(--text);border-left:3px solid var(--primary);background:#0891b22e;font-weight:600}.settings-active-panel{flex-direction:column;flex:1;min-width:0;display:flex}@media (width<=840px){.settings-dashboard-layout{flex-direction:column}.settings-category-sidebar{flex-direction:row;width:100%;min-width:100%;padding:6px;overflow-x:auto}.settings-category-btn{white-space:nowrap;padding:8px 12px}.settings-category-btn.active{border-left:none;border-bottom:2px solid var(--primary)}}.vs-config-layout{box-sizing:border-box;grid-template-columns:1fr 1fr;gap:20px;width:100%;min-width:0;margin-top:16px;display:grid}@media (width<=960px){.vs-config-layout{grid-template-columns:1fr}}.vs-box{border:1px solid var(--border-card);box-sizing:border-box;overflow-wrap:break-word;background:#ffffff05;border-radius:10px;width:100%;min-width:0;padding:20px}.vs-box h3{color:var(--text);align-items:center;gap:8px;margin-bottom:14px;font-size:1rem;font-weight:600;display:flex}.vs-feedback-banner{border-radius:8px;align-items:center;gap:10px;margin-bottom:16px;padding:10px 14px;font-size:.85rem;line-height:1.4;display:flex}.feedback-success{color:#6ee7b7;background:#10b9811f;border:1px solid #10b9814d}.feedback-error{color:#fca5a5;background:#ef44441f;border:1px solid #ef44444d}.theme-options-grid{grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px;margin-top:12px;display:grid}.theme-card{background:var(--bg-card);border:1.5px solid var(--border-card);border-radius:var(--radius);cursor:pointer;text-align:left;flex-direction:column;gap:8px;padding:12px 14px;transition:all .2s;display:flex;position:relative}.theme-card:hover{border-color:color-mix(in srgb, var(--primary) 60%, transparent);transform:translateY(-2px)}.theme-card.active{border-color:var(--primary);box-shadow:0 0 0 1px var(--primary), 0 4px 14px #00000040}.theme-card-header{justify-content:space-between;align-items:center;display:flex}.theme-card-title{color:var(--text);align-items:center;gap:6px;font-size:.92rem;font-weight:600;display:flex}.theme-card-desc{color:var(--text-muted);font-size:.76rem;line-height:1.35}.theme-swatches{align-items:center;gap:6px;padding-top:2px;display:flex}.theme-swatch{border:1px solid #fff3;border-radius:50%;width:18px;height:18px;box-shadow:0 1px 3px #00000040}.sync-drawer-backdrop{-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);z-index:1100;background:#000000a6;justify-content:flex-end;width:100vw;height:100vh;display:flex;position:fixed;top:0;left:0}.sync-drawer{background:var(--bg-card,#111827);border-left:1px solid var(--border-card);flex-direction:column;width:620px;max-width:95vw;height:100vh;animation:.25s cubic-bezier(.16,1,.3,1) slideInRight;display:flex;box-shadow:-10px 0 35px #0000008c}.sync-drawer-header{border-bottom:1px solid var(--border-card);background:#0003;justify-content:space-between;align-items:flex-start;gap:14px;padding:18px 22px;display:flex}.sync-drawer-title-group{flex-direction:column;flex:1;gap:4px;display:flex}.sync-drawer-body{flex-direction:column;flex:1;gap:18px;padding:20px 22px;display:flex;overflow-y:auto}.sync-progress-section{border:1px solid var(--border-card);background:#0003;border-radius:8px;padding:12px 14px}.sync-progress-bar-container{background:#ffffff14;border-radius:4px;width:100%;height:8px;overflow:hidden}.sync-progress-bar-fill{border-radius:4px;height:100%;transition:width .3s,background .3s}.sync-progress-bar-fill.fill-active{background:var(--primary)}.sync-progress-bar-fill.fill-success{background:#10b981}.sync-progress-bar-fill.fill-error{background:#ef4444}.sync-progress-container{box-sizing:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;flex-direction:column;gap:5px;width:100%;min-width:140px;max-width:100%;transition:opacity .2s,transform .15s;display:flex}.sync-progress-container:hover{opacity:.92}.sync-progress-container:focus-visible{outline:2px solid var(--primary);border-radius:6px}.progress-pill{white-space:nowrap;box-sizing:border-box;border-radius:12px;align-items:center;gap:6px;min-width:0;max-width:100%;padding:3px 8px;font-size:.76rem;font-weight:600;display:inline-flex}.progress-pill>span{text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;overflow:hidden}.sync-progress-bar-wrapper{background:#ffffff14;border-radius:3px;width:100%;height:6px;overflow:hidden}.sync-file-caption{color:var(--text-muted);font-size:.72rem;font-family:var(--font-family-mono);text-overflow:ellipsis;white-space:nowrap;align-items:center;min-width:0;max-width:100%;display:flex;overflow:hidden}.sync-file-caption code{text-overflow:ellipsis;white-space:nowrap;max-width:100%;padding:1px 4px;font-size:.72rem;overflow:hidden}.sync-stepper-container{border:1px solid var(--border-card);background:#0003;border-radius:8px;padding:14px 16px}.sync-stepper-list{flex-direction:column;gap:10px;display:flex}.sync-stepper-item{border-radius:6px;align-items:flex-start;gap:12px;padding:8px 10px;transition:background .15s;display:flex}.sync-stepper-item.item-active{background:#f59e0b1a;border:1px solid #f59e0b40}.sync-stepper-item.item-completed{background:#10b9810d}.sync-stepper-item.item-error{background:#ef44441a;border:1px solid #ef444440}.sync-stepper-icon{justify-content:center;align-items:center;min-width:18px;margin-top:1px;font-size:1rem;display:flex}.sync-stepper-content{color:var(--text);flex-direction:column;flex:1;gap:2px;font-size:.88rem;display:flex}.sync-stepper-details{margin-top:4px;font-size:.8rem}.sync-current-file{font-family:var(--font-family-mono);color:var(--accent,#60a5fa);word-break:break-all;font-size:.78rem}.sync-terminal-section{background:#0d1117;border:1px solid #ffffff1f;border-radius:8px;flex-direction:column;flex:1;min-height:260px;display:flex;overflow:hidden}.sync-terminal-header{background:#161b22;border-bottom:1px solid #ffffff1a;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;padding:10px 14px;display:flex}.sync-terminal-actions{align-items:center;gap:12px;display:flex}.sync-autoscroll-toggle{color:var(--text-muted);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:6px;font-size:.78rem;display:flex}.sync-terminal-search{background:#11161d;border-bottom:1px solid #ffffff14;align-items:center;gap:8px;padding:6px 14px;display:flex}.sync-terminal-body{font-family:var(--font-family-mono,monospace);color:#e6edf3;flex:1;min-height:180px;max-height:380px;padding:12px 14px;font-size:.8rem;overflow-y:auto}.sync-terminal-empty{color:#8b949e;flex-direction:column;justify-content:center;align-items:center;height:160px;font-size:.85rem;display:flex}.sync-terminal-lines{flex-direction:column;gap:4px;display:flex}.sync-terminal-line{word-break:break-all;align-items:flex-start;gap:8px;line-height:1.45;display:flex}.log-time{color:#8b949e;flex-shrink:0;font-size:.75rem}.log-badge{border-radius:3px;flex-shrink:0;padding:0 4px;font-size:.7rem;font-weight:700}.log-badge.level-info{color:#38bdf8;background:#38bdf833}.log-badge.level-warn{color:#fbbf24;background:#fbbf2433}.log-badge.level-error{color:#f87171;background:#f8717133}.log-msg{color:#e6edf3;flex:1}theme-editor-overlay{pointer-events:none!important}theme-editor-overlay button,theme-editor-overlay [role=button],theme-editor-overlay a{pointer-events:auto!important}.stats-grid{grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px;margin-bottom:24px;display:grid}.stat-card{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);border-radius:8px;align-items:center;gap:12px;min-width:0;padding:12px 14px;transition:border-color .2s,box-shadow .2s;display:flex;box-shadow:0 2px 8px #00000026}.stat-card:hover{border-color:var(--primary,#00bd7e)}.stat-icon{width:40px;height:40px;color:var(--primary,#00bd7e);background:#00bd7e1f;border-radius:8px;flex-shrink:0;justify-content:center;align-items:center;display:flex}.stat-icon svg{width:20px;height:20px}.stat-info{flex-direction:column;gap:2px;min-width:0;display:flex;overflow:hidden}.stat-label{color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.04em;white-space:nowrap;text-overflow:ellipsis;font-size:.76rem;font-weight:500;overflow:hidden}.stat-value{color:var(--text-color,#e2e8f0);white-space:nowrap;text-overflow:ellipsis;min-width:0;font-size:1.25rem;font-weight:700;line-height:1.2;overflow:hidden}.catalog-filter-bar{border:1px solid var(--border-card,#15474d);background:#0003;border-radius:10px;margin-bottom:24px;padding:16px}.catalog-filter-inputs{grid-template-columns:repeat(auto-fit,minmax(200px,1fr));align-items:flex-end;gap:14px;display:grid}.catalog-filter-inputs .form-group input{box-sizing:border-box;height:36px}.files-storage-page{flex-direction:column;gap:0;height:100%;display:flex}.files-storage-header{border-bottom:1px solid var(--border-card,#15474d);flex-wrap:wrap;flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:16px 20px 12px;display:flex}.files-storage-header .page-title{color:var(--text);margin:0;font-size:1.1rem;font-weight:600}.files-storage-section-tabs{background:var(--bg-card);border:1px solid var(--border-card,#15474d);border-radius:8px;gap:6px;padding:4px;display:flex}.section-tab{color:var(--text-muted);cursor:pointer;white-space:nowrap;background:0 0;border:none;border-radius:6px;align-items:center;gap:6px;padding:6px 14px;font-size:.85rem;transition:background .15s,color .15s;display:flex}.section-tab:hover{color:var(--text);background:#ffffff0f}.section-tab.active{background:var(--primary,#0d9488);color:#fff;font-weight:500}.files-storage-content{flex:1;min-height:0;overflow:auto}.topology-container{flex-direction:column;gap:16px;display:flex;position:relative}.topology-toolbar{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:14px 18px;display:flex}.topology-toolbar-group{flex-wrap:wrap;align-items:center;gap:10px;display:flex}.topology-select,.topology-input{border:1px solid var(--border-card);color:var(--text);background:#00000059;border-radius:8px;outline:none;padding:7px 12px;font-family:inherit;font-size:.85rem;transition:all .2s}.topology-select:focus,.topology-input:focus{border-color:var(--primary);box-shadow:0 0 0 2px #3b82f633}.topology-view-btn-group{border:1px solid var(--border-card);background:#00000059;border-radius:8px;display:inline-flex;overflow:hidden}.topology-view-btn{color:var(--text-muted);cursor:pointer;background:0 0;border:none;padding:6px 12px;font-size:.82rem;transition:all .15s}.topology-view-btn:hover{color:var(--text)}.topology-view-btn.active{background:var(--primary);color:#fff;font-weight:500}.topology-filter-chip{cursor:pointer;-webkit-user-select:none;user-select:none;border:1px solid #0000;border-radius:6px;align-items:center;gap:6px;padding:4px 10px;font-size:.78rem;font-weight:500;transition:all .15s;display:inline-flex}.topology-filter-chip.chip-file{color:#38bdf8;background:#0ea5e926;border-color:#0ea5e94d}.topology-filter-chip.chip-class{color:#c084fc;background:#a855f726;border-color:#a855f74d}.topology-filter-chip.chip-function{color:#34d399;background:#10b98126;border-color:#10b9814d}.topology-filter-chip.chip-route{color:#fbbf24;background:#f59e0b26;border-color:#f59e0b4d}.topology-filter-chip.chip-orphan{color:#fb7185;background:#f43f5e26;border-color:#f43f5e4d}.topology-filter-chip.inactive{opacity:.4;filter:grayscale(80%);color:var(--text-muted);border-color:var(--border-card);background:#ffffff0d}.topology-canvas-wrapper{border:1px solid var(--border-card);border-radius:var(--radius);cursor:grab;background:radial-gradient(circle,#121a2fbf 0%,#0a0f1df2 100%);width:100%;height:640px;position:relative;overflow:hidden}.topology-canvas-wrapper:active{cursor:grabbing}.topology-canvas-wrapper svg{width:100%;height:100%;display:block}.topology-node{cursor:pointer;transition:filter .15s,transform .15s}.topology-node:hover{filter:drop-shadow(0 0 8px #3b82f6cc)}.topology-node.selected{filter:drop-shadow(0 0 12px #14b8a6f2)}.topology-node.highlighted{filter:drop-shadow(0 0 14px #f59e0b)}.topology-edge{transition:stroke-opacity .2s,stroke-width .2s}.topology-controls-panel{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);z-index:10;background:#121a2fd9;border-radius:10px;align-items:center;gap:6px;padding:6px 10px;display:flex;position:absolute;bottom:20px;left:20px}.topology-btn-ctrl{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;padding:6px 8px;font-size:.85rem;transition:all .15s}.topology-btn-ctrl:hover{color:var(--text);background:#ffffff1a}.topology-legend{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);z-index:10;background:#121a2fd9;border-radius:10px;flex-wrap:wrap;gap:8px;padding:8px 12px;display:flex;position:absolute;top:20px;left:20px}.topology-minimap{border:1px solid var(--border-card);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);z-index:10;pointer-events:none;background:#0a0f1dd9;border-radius:8px;width:140px;height:95px;position:absolute;bottom:20px;right:20px;overflow:hidden}.topology-minimap svg{width:100%;height:100%}.topology-drawer{border-left:1px solid var(--border-card);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);z-index:50;background:#0f172af2;flex-direction:column;width:440px;max-width:90%;height:100%;animation:.25s cubic-bezier(.16,1,.3,1) slideInRight;display:flex;position:absolute;top:0;right:0;box-shadow:-10px 0 30px #00000080}@keyframes slideInRight{0%{transform:translate(100%)}to{transform:translate(0)}}.topology-drawer-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;padding:16px 20px;display:flex}.topology-drawer-body{flex-direction:column;flex:1;gap:16px;padding:20px;display:flex;overflow-y:auto}.topology-drawer-section{flex-direction:column;gap:8px;display:flex}.topology-drawer-section-title{text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);font-size:.8rem;font-weight:600}.topology-code-snippet{background:var(--code-bg);border:1px solid var(--border-card);font-family:var(--font-family-mono);color:var(--text);white-space:pre-wrap;border-radius:8px;max-height:220px;padding:12px;font-size:.78rem;line-height:1.45;overflow-x:auto}.topology-neighbor-list{flex-direction:column;gap:6px;display:flex}.topology-neighbor-item{border:1px solid var(--border-card);cursor:pointer;background:#ffffff08;border-radius:6px;justify-content:space-between;align-items:center;padding:8px 12px;font-size:.82rem;transition:all .15s;display:flex}.topology-neighbor-item:hover{border-color:var(--primary);background:#ffffff12}.topology-badge-type{text-transform:uppercase;border-radius:4px;align-items:center;gap:4px;padding:2px 8px;font-size:.72rem;font-weight:600;display:inline-flex}.badge-file{color:#38bdf8;background:#0ea5e933}.badge-class{color:#c084fc;background:#a855f733}.badge-function{color:#34d399;background:#10b98133}.badge-route{color:#fbbf24;background:#f59e0b33}.badge-module{color:#818cf8;background:#6366f133}.badge-edge-imports{color:#38bdf8;background:#0ea5e926}.badge-edge-calls{color:#34d399;background:#10b98126}.badge-edge-defines{color:#c084fc;background:#a855f726}.badge-edge-handles{color:#fbbf24;background:#f59e0b26}.badge-edge-routes-to{color:#fb7185;background:#f43f5e26}.badge-edge-doc-links-to{color:#a78bfa;background:#a78bfa26}.topology-search-results{border:1px solid var(--border-card);z-index:60;background:#0f172afa;border-radius:8px;max-height:240px;margin-top:4px;position:absolute;top:100%;left:0;right:0;overflow-y:auto;box-shadow:0 10px 25px #00000080}.topology-search-item{cursor:pointer;border-bottom:1px solid #ffffff0d;justify-content:space-between;align-items:center;padding:8px 12px;font-size:.82rem;display:flex}.topology-search-item:hover{background:#3b82f626}.topology-empty-state{height:100%;color:var(--text-muted);flex-direction:column;justify-content:center;align-items:center;gap:12px;display:flex}.neighborhood-view{flex-direction:column;gap:14px;width:100%;display:flex;position:relative}.neighborhood-breadcrumbs{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;display:flex}.neighborhood-breadcrumbs-left{flex-wrap:wrap;align-items:center;gap:12px;display:flex}.neighborhood-breadcrumbs-right{flex-wrap:wrap;align-items:center;gap:14px;display:flex}.neighborhood-focal-selector-wrap{align-items:center;gap:6px;display:inline-flex}.neighborhood-focal-label{color:var(--text-muted);white-space:nowrap;font-size:.78rem;font-weight:600}.neighborhood-focal-select{max-width:260px;padding:4px 10px;font-size:.82rem}.neighborhood-back-btn{align-items:center;gap:6px;padding:5px 10px;font-size:.8rem;display:inline-flex}.neighborhood-breadcrumb-trail{flex-wrap:wrap;align-items:center;gap:6px;display:inline-flex}.neighborhood-breadcrumb-sep{color:var(--text-muted);-webkit-user-select:none;user-select:none;margin:0 2px;font-size:.9rem}.neighborhood-breadcrumb-item{cursor:pointer;color:var(--text-muted);background:0 0;border:1px solid #0000;border-radius:6px;align-items:center;gap:6px;padding:3px 8px;font-size:.82rem;transition:all .15s;display:inline-flex}.neighborhood-breadcrumb-item:hover{color:var(--text);background:#ffffff0f}.neighborhood-breadcrumb-item.active{color:var(--text);background:#3b82f626;border-color:#3b82f64d;font-weight:600}.neighborhood-breadcrumb-badge{padding:1px 5px;font-size:.65rem}.neighborhood-breadcrumb-text{font-family:var(--font-family-mono,monospace)}.neighborhood-hop-selector{align-items:center;gap:8px;display:inline-flex}.neighborhood-hop-label{color:var(--text-muted);font-size:.8rem;font-weight:500}.neighborhood-panels{grid-template-columns:280px 1fr 280px;gap:14px;min-height:640px;display:grid}@media (width<=1100px){.neighborhood-panels{grid-template-columns:1fr}}.neighborhood-panel{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);flex-direction:column;max-height:640px;padding:14px;display:flex;overflow:hidden}.neighborhood-panel-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;margin-bottom:10px;padding-bottom:10px;display:flex}.neighborhood-panel-title{color:var(--text);align-items:center;gap:8px;font-size:.85rem;font-weight:600;display:flex}.neighborhood-panel-count{color:var(--text-muted);background:#ffffff14;border-radius:12px;padding:2px 8px;font-size:.75rem;font-weight:600}.neighborhood-panel-list{flex-direction:column;flex:1;gap:8px;padding-right:2px;display:flex;overflow-y:auto}.neighborhood-panel-item{border:1px solid var(--border-card);background:#ffffff05;border-radius:8px;flex-direction:column;gap:6px;padding:10px;transition:all .15s;display:flex}.neighborhood-panel-item:hover{background:#ffffff0d;border-color:#3b82f666}.neighborhood-panel-item-header{justify-content:space-between;align-items:center;gap:6px;display:flex}.neighborhood-panel-item-name{font-family:var(--font-family-mono,monospace);color:var(--text);word-break:break-all;font-size:.8rem}.neighborhood-panel-item-actions{gap:6px;margin-top:4px;display:flex}.neighborhood-panel-empty{text-align:center;color:var(--text-muted);padding:24px 8px;font-size:.8rem}.neighborhood-center{flex-direction:column;min-height:640px;display:flex;position:relative}.neighborhood-canvas-wrapper{border:1px solid var(--border-card);border-radius:var(--radius);background:radial-gradient(circle,#121a2fbf 0%,#0a0f1df2 100%);width:100%;height:100%;min-height:640px;position:relative;overflow:hidden}.neighborhood-svg{width:100%;height:100%;display:block}.neighborhood-orbital-ring{fill:none;stroke:#94a3b82e;stroke-dasharray:4 4;stroke-width:1.5px}.neighborhood-orbital-ring.ring-2{stroke:#94a3b81f}.neighborhood-orbital-label{fill:var(--text-muted);letter-spacing:.04em;pointer-events:none;text-transform:uppercase;font-size:10px}.neighborhood-edge-path{transition:stroke-opacity .2s,stroke-width .2s}.neighborhood-edge-path:hover{stroke-opacity:1;stroke-width:2.5px}.neighborhood-node-item{transition:transform .15s,filter .15s}.neighborhood-node-item:hover{filter:drop-shadow(0 0 10px #3b82f6d9)}.neighborhood-node-circle{transition:filter .15s,stroke-width .15s}.neighborhood-node-name{font-family:var(--font-family-mono,monospace);font-weight:500}.focal-pulse-ring{transform-origin:50%;animation:2.5s cubic-bezier(.4,0,.6,1) infinite pulse-ring}@keyframes pulse-ring{0%{opacity:.8;transform:scale(.95)}50%{opacity:.2;transform:scale(1.15)}to{opacity:.8;transform:scale(.95)}}.neighborhood-focal-node:hover .focal-body{filter:drop-shadow(0 0 12px #3b82f6e6)}.neighborhood-empty-state{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);height:480px}.topology-physics-panel,.topology-physics-popover{z-index:100;border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);background:#0f172af2;flex-direction:column;gap:14px;width:calc(100% - 40px);min-width:320px;max-width:380px;padding:16px;animation:.2s cubic-bezier(.16,1,.3,1) fadeInPhysics;display:flex;position:absolute;top:70px;right:20px;box-shadow:0 12px 32px #0000008c}@keyframes fadeInPhysics{0%{opacity:0;transform:translateY(-8px)scale(.98)}to{opacity:1;transform:translateY(0)scale(1)}}.topology-physics-header{border-bottom:1px solid var(--border-card);justify-content:space-between;align-items:center;gap:8px;padding-bottom:10px;display:flex}.topology-physics-title-wrap{align-items:center;gap:8px;display:flex}.topology-physics-title{color:var(--text);margin:0;font-size:.9rem;font-weight:600}.topology-physics-body{flex-direction:column;gap:14px;display:flex}.topology-physics-section{flex-direction:column;gap:8px;display:flex}.topology-physics-section-title{text-transform:uppercase;letter-spacing:.05em;color:var(--text-muted);font-size:.75rem;font-weight:600}.topology-physics-presets-grid{grid-template-columns:repeat(2,1fr);gap:6px;display:grid}.topology-physics-preset-btn{border:1px solid var(--border-card);color:var(--text-muted);cursor:pointer;background:#ffffff0a;border-radius:6px;align-items:center;gap:6px;padding:6px 10px;font-size:.78rem;font-weight:500;transition:all .15s;display:flex}.topology-physics-preset-btn:hover{color:var(--text);border-color:var(--primary);background:#ffffff14}.topology-physics-preset-btn.active{color:#60a5fa;background:#3b82f633;border-color:#3b82f680;font-weight:600}.topology-physics-sliders-list{flex-direction:column;gap:10px;display:flex}.topology-physics-slider-row{flex-direction:column;gap:4px;display:flex}.topology-physics-slider-header{justify-content:space-between;align-items:center;font-size:.8rem;display:flex}.topology-physics-slider-label{color:var(--text);cursor:pointer;align-items:center;gap:4px;font-weight:500;display:inline-flex}.topology-physics-symbol{color:var(--text-muted);font-size:.72rem;font-family:var(--font-family-mono,monospace)}.topology-physics-value-chip{font-family:var(--font-family-mono,monospace);color:var(--primary,#38bdf8);background:#ffffff0f;border-radius:4px;padding:2px 6px;font-size:.75rem;font-weight:600}.topology-physics-range-input{appearance:none;cursor:pointer;background:#ffffff1f;border-radius:3px;outline:none;width:100%;height:6px;transition:background .15s}.topology-physics-range-input:hover{background:#ffffff2e}.topology-physics-range-input::-webkit-slider-thumb{appearance:none;background:var(--primary,#3b82f6);cursor:pointer;border-radius:50%;width:14px;height:14px;transition:transform .1s;box-shadow:0 0 6px #3b82f699}.topology-physics-range-input::-webkit-slider-thumb:hover{transform:scale(1.2)}.topology-physics-range-input::-moz-range-thumb{background:var(--primary,#3b82f6);cursor:pointer;border:none;border-radius:50%;width:14px;height:14px}.topology-physics-actions{gap:8px;margin-top:4px;display:flex}.topology-physics-action-btn{flex:1;justify-content:center;align-items:center;gap:6px;font-size:.8rem;display:inline-flex}.code-navigator-container,.code-navigator-container.density-balanced{--nav-item-height:28px;--nav-font-size:.84rem;--nav-item-padding:5px 10px;--nav-icon-size:15px;--nav-badge-font-size:.72rem;--nav-card-padding:12px 14px;--nav-header-padding:10px 14px}.code-navigator-container.density-compact{--nav-item-height:22px;--nav-font-size:.76rem;--nav-item-padding:2px 8px;--nav-icon-size:13px;--nav-badge-font-size:.66rem;--nav-card-padding:8px 10px;--nav-header-padding:6px 10px}.code-navigator-container.density-spacious{--nav-item-height:36px;--nav-font-size:.9rem;--nav-item-padding:8px 14px;--nav-icon-size:17px;--nav-badge-font-size:.78rem;--nav-card-padding:16px 18px;--nav-header-padding:14px 18px}.code-navigator-container{background-color:var(--bg-base,#07181b);height:100%;min-height:calc(100vh - 80px);color:var(--text,#f8fafc);font-family:var(--font-family-base,"Outfit", sans-serif);box-sizing:border-box;flex-direction:column;display:flex;overflow:hidden}.nav-breadcrumbs-bar{border-bottom:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#0d2c2fb3;justify-content:space-between;align-items:center;max-width:100%;min-height:38px;padding:6px 16px;font-size:.8rem;display:flex;overflow:hidden}.nav-breadcrumbs-left{flex:1;align-items:center;gap:10px;min-width:0;max-width:100%;display:flex;overflow:hidden}.nav-sidebar-toggle-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border-radius:4px;flex-shrink:0;justify-content:center;align-items:center;padding:4px 6px;transition:all .2s;display:flex}.nav-sidebar-toggle-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-history-controls{flex-shrink:0;align-items:center;gap:2px;display:flex}.nav-history-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border-radius:4px;justify-content:center;align-items:center;padding:4px 6px;transition:all .2s;display:flex}.nav-history-btn:disabled{opacity:.35;cursor:not-allowed}.nav-history-btn:not(:disabled):hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-breadcrumb-trail{white-space:nowrap;scrollbar-width:none;align-items:center;gap:6px;min-width:0;display:flex;overflow-x:auto}.nav-breadcrumb-trail::-webkit-scrollbar{display:none}.breadcrumb-repo-badge{color:var(--accent,#14b8a6);background:#0891b233;border:1px solid #0891b266;border-radius:4px;flex-shrink:0;align-items:center;gap:4px;padding:2px 7px;font-size:.76rem;font-weight:600;display:inline-flex}.breadcrumb-separator{color:var(--text-muted,#64748b);-webkit-user-select:none;user-select:none}.breadcrumb-segment{color:var(--text-muted,#94a3b8);cursor:pointer;font-size:.8rem;font-family:var(--font-mono,monospace);background:0 0;border:none;border-radius:3px;padding:2px 4px;transition:all .15s}.breadcrumb-segment:hover{color:var(--text,#f8fafc);background:#ffffff14}.breadcrumb-segment.active{color:var(--text,#f8fafc);font-weight:600}.breadcrumb-symbol-badge{color:var(--accent,#14b8a6);font-family:var(--font-mono,monospace);background:#14b8a626;border:1px solid #14b8a64d;border-radius:4px;align-items:center;padding:2px 6px;font-size:.78rem;font-weight:600;display:inline-flex}.nav-breadcrumbs-right{flex-shrink:0;align-items:center;gap:8px;display:flex}.nav-permalink-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:#0000004d;border-radius:5px;align-items:center;gap:6px;padding:4px 10px;font-size:.76rem;transition:all .2s;display:inline-flex}.nav-permalink-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#0891b226}.nav-permalink-btn.copied{color:#6ee7b7;background:#10b9811a;border-color:#10b98180}.nav-hero-layout{flex:1;min-height:0;display:flex;position:relative;overflow:hidden}.nav-sidebar-column{border-right:1px solid var(--border-card,#15474d);background:#0003;flex-direction:column;width:340px;min-width:300px;max-width:480px;transition:width .2s,min-width .2s,opacity .2s;display:flex;overflow:hidden}.nav-sidebar-column.collapsed{opacity:0;pointer-events:none;border-right:none;width:0!important;min-width:0!important}.nav-sidebar-tabs{border-bottom:1px solid var(--border-card,#15474d);background:#0000004d;display:flex}.nav-sidebar-tab-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-bottom:2px solid #0000;flex:1;justify-content:center;align-items:center;gap:6px;padding:8px 12px;font-size:.78rem;font-weight:500;transition:all .2s;display:flex}.nav-sidebar-tab-btn:hover{color:var(--text,#f8fafc);background:#ffffff08}.nav-sidebar-tab-btn.active{color:var(--primary,#0891b2);border-bottom-color:var(--primary,#0891b2);background:#0891b214}.nav-hero-viewer{background:var(--bg-card,#0d2c2f);flex-direction:column;flex:1;min-width:0;display:flex;overflow:hidden}.nav-sliding-impact-drawer{border-left:1px solid var(--border-card,#15474d);z-index:20;background:#0d2c2ff2;flex-direction:column;width:360px;min-width:360px;display:flex;overflow-y:auto;box-shadow:-4px 0 16px #0006}.nav-toolbar{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);box-sizing:border-box;z-index:10;flex-wrap:nowrap;justify-content:space-between;align-items:center;gap:12px;height:44px;min-height:44px;max-height:44px;padding:0 16px;display:flex;overflow:visible}.nav-toolbar-single-row{flex-wrap:nowrap!important}.nav-toolbar-left{flex-shrink:0;align-items:center;gap:12px;display:flex}.nav-repo-selector-wrapper{align-items:center;gap:8px;display:flex}.nav-repo-label{color:var(--text-muted,#94a3b8);font-size:.82rem;font-weight:500}.nav-repo-select{border:1px solid var(--border-card,#15474d);color:var(--text,#f8fafc);cursor:pointer;background:#0006;border-radius:6px;outline:none;padding:5px 12px;font-size:.84rem;transition:border-color .2s,box-shadow .2s}.nav-repo-select:focus{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-stats-badges{align-items:center;gap:8px;display:flex}.nav-stat-badge{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);background:#15474d80;border-radius:12px;padding:3px 8px;font-size:.76rem}.nav-stat-badge .stat-num{color:var(--accent,#14b8a6);font-weight:600}.nav-toolbar-center{flex:1;min-width:200px;max-width:580px}.nav-global-search{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;width:100%;padding:0 10px;transition:all .2s;display:flex;position:relative}.nav-global-search:focus-within{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-global-search .search-icon-wrapper{width:16px;height:16px;color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;justify-content:center;align-items:center;margin-right:8px;display:flex}.nav-search-input{color:var(--text,#f8fafc);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:6px 0;font-size:.82rem}.nav-search-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;padding:2px 4px;font-size:.75rem}.nav-search-clear-btn:hover{color:var(--text,#f8fafc)}.nav-omni-container{width:100%;position:relative}.nav-omni-input-wrapper{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;width:100%;padding:0 10px;transition:all .2s;display:flex;position:relative}.nav-omni-input-wrapper:focus-within{border-color:var(--primary,#0891b2);box-shadow:0 0 0 2px #0891b240}.nav-omni-search-icon{color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;margin-right:8px}.nav-omni-input{color:var(--text,#f8fafc);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:6px 0;font-size:.82rem}.nav-omni-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;padding:2px 4px;font-size:.75rem}.nav-omni-clear-btn:hover{color:var(--text,#f8fafc)}.nav-omni-spinner{flex-shrink:0;width:14px;height:14px;margin-left:6px;animation:.8s linear infinite nav-spin;display:block}.nav-svg-spinner{animation:.8s linear infinite nav-spin;display:inline-block}@keyframes nav-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.nav-omni-kbd{font-size:.65rem;font-family:var(--font-mono,monospace);color:var(--text-muted,#94a3b8);letter-spacing:.05em;-webkit-user-select:none;user-select:none;background:#ffffff14;border:1px solid #ffffff1f;border-radius:4px;flex-shrink:0;margin-left:6px;padding:2px 6px}.nav-omni-dropdown{z-index:100;background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);border-radius:8px;flex-direction:column;width:max(100%,640px);max-width:min(92vw,760px);max-height:480px;display:flex;position:absolute;top:calc(100% + 6px);left:50%;overflow:hidden;transform:translate(-50%);box-shadow:0 20px 45px #000000bf,0 8px 20px #00000080}@media (width<=768px){.nav-omni-dropdown{width:100%;max-width:100%;left:0;transform:none}}.nav-omni-dropdown-header{border-bottom:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.05em;background:#00000059;justify-content:space-between;align-items:center;padding:8px 14px;font-size:.72rem;font-weight:600;display:flex}.nav-omni-hint{color:var(--text-muted,#64748b);text-transform:none;font-size:.68rem}.nav-omni-empty{text-align:center;color:var(--text-muted,#94a3b8);padding:20px 16px;font-size:.82rem}.nav-omni-list{padding:6px;overflow-y:auto}.nav-omni-item{cursor:pointer;border:1px solid #0000;border-radius:6px;flex-direction:column;gap:5px;margin-bottom:3px;padding:9px 12px;transition:all .15s;display:flex}.nav-omni-item:hover,.nav-omni-item.active{background:#0ea5e91f;border-color:#38bdf859}.nav-omni-item-top{justify-content:space-between;align-items:center;gap:12px;display:flex}.nav-omni-item-title-group{flex:1;align-items:center;gap:8px;min-width:0;display:flex;overflow:hidden}.nav-omni-badge{text-transform:uppercase;letter-spacing:.04em;font-size:.65rem;font-weight:700;font-family:var(--font-mono,monospace);border-radius:4px;flex-shrink:0;padding:2px 6px}.badge-symbol{color:#38bdf8;background:#0ea5e933;border:1px solid #38bdf859}.badge-code{color:#c084fc;background:#a855f733;border:1px solid #c084fc59}.badge-file{color:#2dd4bf;background:#14b8a633;border:1px solid #2dd4bf59}.badge-route{color:#4ade80;background:#22c55e33;border:1px solid #4ade8059}.badge-doc{color:#fbbf24;background:#f59e0b33;border:1px solid #fbbf2459}.badge-default{color:#cbd5e1;background:#94a3b833}.nav-omni-item-container{color:#94a3b8;font-size:.82rem;font-family:var(--font-mono,monospace);white-space:nowrap;flex-shrink:0}.nav-omni-item-name{color:#f8fafc;font-size:.85rem;font-weight:600;font-family:var(--font-mono,monospace);white-space:nowrap;text-overflow:ellipsis;min-width:0;overflow:hidden}.nav-omni-item-kind{color:#94a3b8;text-transform:lowercase;background:#ffffff0f;border:1px solid #ffffff17;border-radius:4px;flex-shrink:0;padding:1px 5px;font-size:.65rem;font-weight:500}.nav-omni-score-pill{color:#34d399;white-space:nowrap;background:#10b9811f;border:1px solid #34d39940;border-radius:6px;flex-shrink:0;padding:2px 7px;font-size:.65rem;font-weight:600}.nav-omni-match{color:#38bdf8;background:#38bdf840;border-radius:2px;padding:0 1px;font-weight:700}.nav-omni-item-bottom{color:#94a3b8;font-size:.73rem;font-family:var(--font-mono,monospace);align-items:center;gap:8px;line-height:1.3;display:flex;overflow:hidden}.nav-omni-item-path{color:#38bdf8;text-overflow:ellipsis;white-space:nowrap;flex-shrink:0;max-width:48%;overflow:hidden}.nav-omni-line-badge{color:#64748b;font-weight:600}.nav-omni-sep{color:#475569;flex-shrink:0;font-size:.65rem}.nav-omni-item-preview{color:#cbd5e1;white-space:nowrap;text-overflow:ellipsis;flex:1;min-width:0;overflow:hidden}.nav-code-viewer-container{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);border-radius:8px;flex-direction:column;max-width:100%;height:100%;display:flex;position:relative;overflow:hidden}.nav-code-viewer-header{border-bottom:1px solid var(--border-card,#15474d);background:#0006;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;max-width:100%;padding:8px 14px;display:flex}.nav-code-viewer-meta{align-items:center;gap:8px;max-width:100%;display:flex;overflow:hidden}.nav-code-file-icon{color:var(--primary,#38bdf8);flex-shrink:0}.nav-code-filename{color:var(--text,#f8fafc);font-size:.84rem;font-weight:700;font-family:var(--font-mono,monospace);white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.nav-code-stat-chip{color:var(--text-muted,#94a3b8);font-size:.72rem;font-family:var(--font-mono,monospace);background:#ffffff14;border-radius:4px;flex-shrink:0;padding:1px 6px}.nav-code-viewer-actions{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.nav-code-action-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#cbd5e1);cursor:pointer;background:#ffffff0f;border-radius:4px;padding:3px 8px;font-size:.74rem;transition:all .15s}.nav-code-action-btn:hover{color:var(--text,#f8fafc);border-color:var(--primary,#0891b2);background:#ffffff1f}.nav-code-impact-toggle-btn{color:#c084fc;cursor:pointer;background:#a855f726;border:1px solid #a855f759;border-radius:4px;align-items:center;gap:5px;padding:3px 9px;font-size:.74rem;font-weight:600;transition:all .15s;display:flex}.nav-code-impact-toggle-btn:hover,.nav-code-impact-toggle-btn.active{color:#f3e8ff;background:#a855f747;border-color:#a855f7}.nav-code-body{background:#061113;outline:none;flex:1;max-width:100%;padding:8px 0;position:relative;overflow:hidden auto}.nav-code-lines-wrapper{flex-direction:column;width:100%;max-width:100%;display:flex}.nav-code-line-row{box-sizing:border-box;border-left:3px solid #0000;max-width:100%;min-height:20px;padding:0 4px;line-height:20px;transition:background-color .1s;display:flex}.nav-code-line-row:hover{background:#ffffff08}.nav-code-line-number{text-align:right;width:44px;min-width:44px;font-size:.72rem;font-family:var(--font-mono,monospace);color:#475569;-webkit-user-select:none;user-select:none;flex-shrink:0;padding-right:12px}.nav-code-line-content{font-size:.78rem;font-family:var(--font-mono,monospace);color:#cbd5e1;white-space:pre-wrap;word-break:break-all;overflow-wrap:anywhere;tab-size:4;flex:1;min-width:0}.nav-code-line-target{background:#0ea5e90a!important;border-left:3px solid #38bdf838!important}.nav-code-line-target .nav-code-line-number{color:#64748b}.nav-code-line-primary{background:#0ea5e929!important;border-left:3px solid #38bdf8!important}.nav-code-line-primary .nav-code-line-number{font-weight:700;color:#38bdf8!important}.nav-code-line-primary .nav-code-line-content{font-weight:500}.nav-code-impact-drawer{border-top:1px solid var(--border-card,#15474d);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);background:#091d20f2;flex-direction:column;max-height:260px;animation:.18s ease-out slide-up;display:flex}@keyframes slide-up{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}.nav-impact-drawer-header{border-bottom:1px solid var(--border-card,#15474d);background:#00000059;justify-content:space-between;align-items:center;padding:6px 12px;display:flex}.nav-impact-drawer-title{align-items:center;gap:8px;font-size:.76rem;display:flex}.nav-impact-symbol-name{color:var(--text,#f8fafc);font-family:var(--font-mono,monospace)}.nav-impact-symbol-lines{color:var(--text-muted,#94a3b8);font-size:.7rem}.nav-impact-close-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;padding:2px 6px;font-size:.8rem}.nav-impact-close-btn:hover{color:var(--text,#f8fafc)}.nav-impact-drawer-body{grid-template-columns:1fr 1fr;gap:12px;padding:10px 14px;display:grid;overflow-y:auto}.nav-impact-column-title{text-transform:uppercase;color:var(--text-muted,#94a3b8);margin-bottom:6px;font-size:.72rem;font-weight:600}.nav-impact-empty{color:var(--text-muted,#64748b);font-size:.72rem;font-style:italic}.nav-impact-chips-list{flex-direction:column;gap:4px;display:flex}.nav-impact-chip{border:1px solid var(--border-card,#15474d);cursor:pointer;text-align:left;color:var(--text,#f8fafc);background:#0000004d;border-radius:4px;align-items:center;gap:6px;padding:3px 8px;font-size:.72rem;transition:all .12s;display:flex}.nav-impact-chip:hover{border-color:var(--primary,#0891b2);background:#0891b233}.nav-impact-chip.caller .chip-name{color:#38bdf8;font-weight:600;font-family:var(--font-mono,monospace)}.nav-impact-chip.callee .chip-name{color:#a7f3d0;font-weight:600;font-family:var(--font-mono,monospace)}.nav-impact-chip .chip-path{color:var(--text-muted,#94a3b8);font-size:.68rem;font-family:var(--font-mono,monospace)}.nav-impact-chip .chip-line{color:#facc15;font-size:.68rem}.nav-toolbar-right{flex-shrink:0;align-items:center;gap:12px;display:flex}.nav-density-switcher{border:1px solid var(--border-card,#15474d);background:#0000004d;border-radius:6px;align-items:center;gap:2px;padding:2px;display:flex}.nav-density-switcher .density-label{color:var(--text-muted,#94a3b8);padding:0 6px;font-size:.76rem}.density-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;padding:3px 8px;font-size:.76rem;font-weight:500;transition:all .15s}.density-btn:hover{color:var(--text,#f8fafc);background:#ffffff0d}.density-btn.active{background:var(--primary,#0891b2);color:#fff}.nav-refresh-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;background:#0000004d;border-radius:6px;justify-content:center;align-items:center;padding:6px;transition:all .2s;display:flex}.nav-refresh-btn:hover:not(:disabled){color:var(--accent,#14b8a6);border-color:var(--accent,#14b8a6)}.nav-refresh-btn.spinning svg{animation:1s linear infinite spin}.nav-error-banner{border-bottom:1px solid var(--danger,#ef4444);color:#fca5a5;background:#ef444426;align-items:center;gap:10px;padding:8px 16px;font-size:.84rem;display:flex}.nav-error-banner span{flex:1}.error-close-btn{color:#fca5a5;cursor:pointer;background:0 0;border:none;font-size:.9rem}.nav-panes-layout{background:var(--bg-base,#07181b);flex:1;display:flex;position:relative;overflow:hidden}.nav-pane-column{border-right:1px solid var(--border-card,#15474d);flex-direction:column;height:100%;display:flex;overflow:hidden}.nav-pane-column:last-child{border-right:none}.nav-pane-tree{background:#07181bf2;flex:0 0 320px;min-width:250px;max-width:420px}.nav-pane-outline{background:#0a2024f2;flex:0 0 360px;min-width:280px;max-width:480px}.nav-pane-inspector{background:var(--bg-base,#07181b);flex:400px;min-width:320px}.nav-tree-header,.nav-outline-header,.nav-inspector-header{padding:var(--nav-header-padding);background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);flex-direction:column;flex-shrink:0;gap:8px;display:flex}.nav-inspector-header{box-sizing:border-box;flex-flow:wrap;justify-content:space-between;align-items:center;gap:8px;min-width:0;max-width:100%}.nav-tree-title-row,.nav-outline-title-row{justify-content:space-between;align-items:center;gap:8px;display:flex}.nav-tree-title,.nav-outline-title,.nav-inspector-title{color:var(--text,#f8fafc);text-transform:uppercase;letter-spacing:.04em;align-items:center;gap:8px;font-size:.86rem;font-weight:600;display:flex}.nav-tree-actions{align-items:center;gap:4px;display:flex}.nav-icon-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:1px solid #0000;border-radius:4px;justify-content:center;align-items:center;padding:4px;display:flex}.nav-icon-btn:hover{color:var(--text,#f8fafc);border-color:var(--border-card,#15474d);background:#ffffff0d}.nav-file-badge{color:var(--accent-light,#2dd4bf);text-overflow:ellipsis;white-space:nowrap;background:#14b8a626;border:1px solid #14b8a64d;border-radius:12px;max-width:180px;padding:2px 8px;font-size:.74rem;overflow:hidden}.nav-tree-search-bar,.nav-outline-search-bar{border:1px solid var(--border-card,#15474d);box-sizing:border-box;background:#0000004d;border-radius:5px;align-items:center;width:100%;padding:0 8px;display:flex;position:relative}.nav-tree-search-bar:focus-within,.nav-outline-search-bar:focus-within{border-color:var(--primary,#0891b2)}.nav-tree-search-bar .search-icon-wrapper,.nav-outline-search-bar .search-icon-wrapper{width:14px;height:14px;color:var(--text-muted,#94a3b8);pointer-events:none;flex-shrink:0;justify-content:center;align-items:center;margin-right:6px;display:flex}.nav-tree-search-input,.nav-outline-search-input{color:var(--text,#f8fafc);font-size:var(--nav-font-size);background:0 0;border:none;outline:none;flex:1;min-width:0;padding:4px 0}.nav-tree-clear-btn,.nav-outline-clear-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;flex-shrink:0;margin-left:4px;font-size:.72rem}.nav-category-chips{scrollbar-width:none;flex-wrap:wrap;align-items:center;gap:4px;padding-bottom:2px;display:flex;overflow-x:hidden}.nav-category-chips::-webkit-scrollbar{display:none}.category-chip{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;white-space:nowrap;background:#0000004d;border-radius:12px;align-items:center;gap:4px;padding:2px 8px;font-size:.72rem;transition:all .15s;display:flex}.category-chip:hover{color:var(--text,#f8fafc);border-color:#14b8a666}.category-chip.active{border-color:var(--primary,#0891b2);color:var(--accent-light,#2dd4bf);background:#0891b240;font-weight:600}.chip-count{opacity:.8;font-size:.68rem}.nav-tree-content,.nav-outline-content,.nav-inspector-content{flex:1;padding:6px 0;overflow:hidden auto}.nav-inspector-content{padding:14px}.nav-tree-pane{outline:none;flex-direction:column;height:100%;display:flex}.nav-tree-list{flex-direction:column;display:flex}.nav-tree-item{min-height:var(--nav-item-height);padding:var(--nav-item-padding);font-size:var(--nav-font-size);color:var(--text,#f8fafc);cursor:pointer;-webkit-user-select:none;user-select:none;border-left:2px solid #0000;align-items:center;gap:6px;transition:background-color .1s,border-color .1s;display:flex}.nav-tree-item:hover{background:#ffffff0a}.nav-tree-item.selected{border-left-color:var(--accent,#14b8a6);color:#fff;background:#0891b233;font-weight:500}.nav-tree-item.focused{outline:1px dotted var(--accent,#14b8a6);outline-offset:-1px}.tree-chevron{width:14px;color:var(--text-muted,#94a3b8);justify-content:center;align-items:center;font-size:.64rem;display:inline-flex}.chevron-arrow{transition:transform .15s;display:inline-block}.chevron-arrow.open{transform:rotate(90deg)}.chevron-spacer{width:14px}.tree-icon{font-size:var(--nav-icon-size);justify-content:center;align-items:center;width:16px;display:inline-flex}.tree-label{text-overflow:ellipsis;white-space:nowrap;flex:1;overflow:hidden}.tree-badges{align-items:center;gap:4px;margin-left:auto;padding-right:6px;display:flex}.badge-symbols{font-size:var(--nav-badge-font-size);color:#67e8f9;font-family:var(--font-family-mono,monospace);background:#0891b226;border:1px solid #0891b24d;border-radius:8px;padding:1px 5px}.badge-routes{font-size:var(--nav-badge-font-size);color:#5eead4;font-family:var(--font-family-mono,monospace);background:#14b8a62e;border:1px solid #14b8a659;border-radius:8px;padding:1px 5px;font-weight:600}.nav-outline-pane{flex-direction:column;height:100%;display:flex}.nav-symbol-list{flex-direction:column;gap:4px;padding:6px 8px;display:flex}.nav-symbol-item{border:1px solid var(--border-card,#15474d);padding:var(--nav-card-padding);cursor:pointer;background:#0d2c2f66;border-radius:6px;flex-direction:column;gap:6px;transition:all .15s;display:flex}.nav-symbol-item:hover{background:#15474d66;border-color:#14b8a666}.nav-symbol-item.active{border-color:var(--accent,#14b8a6);background:#0891b238;box-shadow:0 0 10px #14b8a626}.symbol-header-row{justify-content:space-between;align-items:center;gap:8px;display:flex}.symbol-name-col{align-items:center;gap:6px;display:flex;overflow:hidden}.symbol-name-text{font-weight:600;font-size:var(--nav-font-size);color:var(--text,#f8fafc);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.symbol-meta-col{flex-shrink:0}.symbol-line-badge{font-size:var(--nav-badge-font-size);color:var(--text-muted,#94a3b8);font-family:var(--font-family-mono,monospace);background:#00000040;border-radius:4px;padding:1px 6px}.symbol-kind-badge{text-transform:uppercase;letter-spacing:.03em;border-radius:4px;flex-shrink:0;padding:1px 5px;font-size:.65rem;font-weight:700}.kind-class{color:#c084fc;background:#a855f733;border:1px solid #a855f766}.kind-function{color:#60a5fa;background:#3b82f633;border:1px solid #3b82f666}.kind-variable{color:#fbbf24;background:#f59e0b33;border:1px solid #f59e0b66}.kind-type{color:#2dd4bf;background:#14b8a633;border:1px solid #14b8a666}.kind-default{color:#cbd5e1;background:#94a3b833;border:1px solid #94a3b84d}.symbol-route-row{background:#0000004d;border-radius:4px;align-items:center;gap:6px;padding:3px 6px;font-size:.74rem;display:flex;overflow:hidden}.route-method-badge{text-transform:uppercase;border-radius:3px;flex-shrink:0;padding:1px 5px;font-size:.64rem;font-weight:700}.method-get{color:#a7f3d0;background:#065f46}.method-post{color:#bfdbfe;background:#1e40af}.method-put{color:#fde68a;background:#92400e}.method-delete{color:#fecaca;background:#991b1b}.method-patch{color:#ddd6fe;background:#5b21b6}.method-other{color:#e5e7eb;background:#374151}.route-path-text{font-family:var(--font-family-mono,monospace);color:#67e8f9;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.route-framework-tag{color:var(--text-muted,#94a3b8);margin-left:auto;padding-left:4px;font-size:.62rem}.symbol-signature-snippet{background:var(--code-bg,#00000059);font-family:var(--font-family-mono,monospace);color:#cbd5e1;text-overflow:ellipsis;white-space:nowrap;border-radius:4px;padding:4px 6px;font-size:.72rem;overflow-x:hidden}.nav-inspector-pane{box-sizing:border-box;flex-direction:column;min-width:0;max-width:100%;height:100%;display:flex;overflow-x:hidden}.nav-copy-permalink-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;box-sizing:border-box;background:#00000059;border-radius:6px;align-items:center;gap:6px;max-width:100%;padding:4px 10px;font-size:.76rem;transition:all .15s;display:flex}.nav-copy-permalink-btn:hover{color:var(--accent,#14b8a6);border-color:var(--accent,#14b8a6)}.nav-inspector-body{box-sizing:border-box;flex-direction:column;gap:12px;min-width:0;max-width:100%;display:flex}.inspector-card{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);padding:var(--nav-card-padding);box-sizing:border-box;border-radius:8px;min-width:0;max-width:100%;overflow-x:hidden}.card-section-title{color:var(--text-muted,#94a3b8);text-transform:uppercase;letter-spacing:.04em;align-items:center;gap:6px;margin-bottom:8px;font-size:.8rem;font-weight:600;display:flex}.symbol-summary-card{flex-direction:column;gap:6px;display:flex}.summary-title-row{flex-wrap:wrap;align-items:center;gap:8px;min-width:0;max-width:100%;display:flex}.summary-name{color:#fff;overflow-wrap:anywhere;word-break:break-word;min-width:0;font-size:1.15rem;font-weight:700}.summary-location-row{color:var(--text-muted,#94a3b8);align-items:center;gap:12px;font-size:.8rem;display:flex}.summary-file-path{color:var(--accent-light,#2dd4bf);font-family:var(--font-family-mono,monospace);align-items:center;gap:4px;display:flex}.summary-line-range{font-family:var(--font-family-mono,monospace);background:#0000004d;border-radius:4px;padding:1px 6px}.inspector-metrics-grid{grid-template-columns:repeat(4,1fr);gap:10px;display:grid}.metric-box{background:var(--bg-card,#0d2c2f);border:1px solid var(--border-card,#15474d);text-align:center;border-radius:8px;flex-direction:column;align-items:center;padding:10px;display:flex}.metric-label{color:var(--text-muted,#94a3b8);margin-bottom:4px;font-size:.72rem}.metric-value{color:var(--accent,#14b8a6);font-size:1.25rem;font-weight:700}.metric-lang{text-transform:uppercase;font-size:.95rem}.route-detail-row{align-items:center;gap:8px;display:flex}.route-path-code{font-family:var(--font-family-mono,monospace);color:#67e8f9;font-size:.88rem;font-weight:600}.signature-code-block{background:var(--code-bg,#00000059);font-family:var(--font-family-mono,monospace);color:#f1f5f9;white-space:pre-wrap;word-break:break-all;border:1px solid #ffffff0d;border-radius:6px;padding:10px;font-size:.82rem;overflow-x:auto}.docstring-text{color:#cbd5e1;white-space:pre-wrap;font-size:.84rem;line-height:1.5}.relation-list{flex-direction:column;gap:6px;display:flex}.relation-item{border:1px solid var(--border-card,#15474d);background:#00000040;border-radius:6px;flex-direction:column;gap:4px;padding:8px 10px;transition:all .15s;display:flex}.relation-item.caller-item,.relation-item.callee-item.is-clickable{cursor:pointer}.relation-item.caller-item:hover,.relation-item.callee-item.is-clickable:hover{border-color:var(--accent,#14b8a6);background:#0891b22e;transform:translate(2px)}.relation-top{justify-content:space-between;align-items:center;display:flex}.rel-top-right{align-items:center;gap:6px;display:flex}.rel-symbol-name{color:var(--text,#f8fafc);font-size:.82rem;font-weight:600}.rel-jump-hint{color:var(--accent-light,#2dd4bf);font-size:.72rem;font-weight:500}.relation-bottom{color:var(--text-muted,#94a3b8);align-items:center;gap:8px;font-size:.74rem;display:flex}.rel-filepath{font-family:var(--font-family-mono,monospace);color:#93c5fd}.rel-line{font-family:var(--font-family-mono,monospace)}.rel-type-tag,.rel-type-badge{text-transform:uppercase;background:#ffffff14;border-radius:4px;padding:1px 5px;font-size:.64rem}.import-badge{color:#c084fc;background:#a855f726}.rel-count-badge{color:var(--accent-light,#2dd4bf);font-size:.65rem;font-weight:500;font-family:var(--font-family-mono,monospace);background:#14b8a626;border-radius:4px;padding:1px 5px}.nav-no-items-text{color:var(--text-muted,#94a3b8);font-size:.8rem;font-style:italic}.nav-empty-state{text-align:center;color:var(--text-muted,#94a3b8);flex-direction:column;justify-content:center;align-items:center;gap:8px;padding:32px 16px;display:flex}.nav-empty-state .empty-icon{opacity:.5;margin-bottom:4px;font-size:2rem}.nav-empty-state h4{color:var(--text,#f8fafc);font-size:.95rem}.nav-empty-state p{max-width:280px;font-size:.8rem}.nav-clear-filter-btn{background:var(--primary,#0891b2);color:#fff;cursor:pointer;border:none;border-radius:4px;margin-top:6px;padding:4px 10px;font-size:.76rem}.nav-loading-wrapper{color:var(--text-muted,#94a3b8);flex-direction:column;justify-content:center;align-items:center;gap:12px;padding:40px 16px;font-size:.84rem;display:flex}.nav-spinner{border:2px solid var(--border-card,#15474d);border-top-color:var(--accent,#14b8a6);border-radius:50%;width:24px;height:24px;animation:.8s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.nav-outline-skeleton,.nav-inspector-skeleton{flex-direction:column;gap:10px;padding:12px;display:flex}.skeleton-item,.skeleton-header,.skeleton-metrics,.skeleton-block{background:#ffffff0d;border-radius:6px}.skeleton-item{height:48px}.skeleton-header{height:70px}.skeleton-metrics{height:60px}.skeleton-block{height:90px}.shimmer{position:relative;overflow:hidden}.shimmer:after{content:"";background:linear-gradient(90deg,#0000 0%,#ffffff0a 50%,#0000 100%);width:100%;height:100%;animation:1.5s infinite shimmer;position:absolute;top:0;left:0;transform:translate(-100%)}@keyframes shimmer{to{transform:translate(100%)}}.nav-inspector-header-actions{flex-wrap:wrap;align-items:center;gap:8px;min-width:0;max-width:100%;display:flex}.nav-inspector-tabs{border:1px solid var(--border-card,#15474d);background:#0006;border-radius:6px;gap:2px;padding:2px;display:flex}.inspector-tab-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;align-items:center;gap:5px;padding:4px 10px;font-size:.74rem;font-weight:500;transition:all .15s;display:inline-flex}.inspector-tab-btn:hover:not(:disabled){color:var(--text,#f8fafc)}.inspector-tab-btn.active{background:var(--primary,#0891b2);color:#fff}.inspector-tab-btn.dimmed,.inspector-tab-btn:disabled{opacity:.4;cursor:default}.nav-doc-reader{background:var(--bg-base,#07181b);flex-direction:column;height:100%;display:flex;overflow:hidden}.doc-reader-header{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;display:flex}.doc-reader-meta{flex:1;align-items:center;gap:10px;min-width:0;display:flex}.doc-icon{flex-shrink:0;font-size:1.3rem}.doc-title-wrapper{flex-direction:column;gap:2px;min-width:0;display:flex}.doc-filename{color:var(--text,#f8fafc);white-space:nowrap;text-overflow:ellipsis;margin:0;font-size:.92rem;font-weight:600;overflow:hidden}.doc-meta-badges{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.doc-badge{color:var(--text-muted,#94a3b8);background:#ffffff0f;border:1px solid #ffffff14;border-radius:4px;padding:1px 6px;font-size:.7rem}.badge-path{color:var(--accent,#14b8a6);white-space:nowrap;text-overflow:ellipsis;max-width:250px;overflow:hidden}.doc-reader-actions{flex-shrink:0;align-items:center;gap:8px;display:flex}.doc-view-toggle{border:1px solid var(--border-card,#15474d);background:#0006;border-radius:5px;padding:2px;display:flex}.doc-view-toggle .toggle-btn{color:var(--text-muted,#94a3b8);cursor:pointer;background:0 0;border:none;border-radius:4px;padding:3px 8px;font-size:.72rem;transition:all .15s}.doc-view-toggle .toggle-btn.active{background:var(--primary,#0891b2);color:#fff}.doc-copy-btn{border:1px solid var(--border-card,#15474d);color:var(--text,#f8fafc);cursor:pointer;background:#ffffff0f;border-radius:5px;padding:4px 10px;font-size:.74rem;transition:all .2s}.doc-copy-btn:hover{background:var(--primary,#0891b2);color:#fff;border-color:var(--primary,#0891b2)}.doc-reader-body{background:var(--bg-base,#07181b);color:var(--text,#f8fafc);flex:1;padding:16px 20px;font-size:.88rem;line-height:1.6;overflow-y:auto}.doc-rendered-content{max-width:960px;margin:0 auto;line-height:1.65}.doc-rendered-content h1{color:var(--text,#f8fafc);border-bottom:1px solid var(--border-card,#15474d);margin:20px 0 14px;padding-bottom:8px;font-size:1.55rem;font-weight:700}.doc-rendered-content h2{color:var(--text,#f8fafc);border-bottom:1px solid #ffffff14;margin:18px 0 12px;padding-bottom:6px;font-size:1.3rem;font-weight:600}.doc-rendered-content h3{color:var(--accent-light,#2dd4bf);margin:14px 0 8px;font-size:1.1rem;font-weight:600}.doc-rendered-content h4{color:var(--text,#f8fafc);margin:12px 0 6px;font-size:.98rem;font-weight:600}.doc-rendered-content p{color:#cbd5e1;margin:0 0 12px}.doc-rendered-content table{border-collapse:collapse;border:1px solid var(--border-card,#15474d);background:#00000040;border-radius:6px;width:100%;margin:18px 0;font-size:.85rem;overflow:hidden}.doc-rendered-content thead{background:#0891b22e}.doc-rendered-content th{color:#f8fafc;border-bottom:2px solid var(--border-card,#15474d);text-align:left;border-right:1px solid #ffffff0f;padding:10px 14px;font-weight:600}.doc-rendered-content td{color:#cbd5e1;border-bottom:1px solid #ffffff0d;border-right:1px solid #ffffff0f;padding:9px 14px}.doc-rendered-content th:last-child,.doc-rendered-content td:last-child{border-right:none}.doc-rendered-content tr:last-child td{border-bottom:none}.doc-rendered-content tbody tr:hover{background:#ffffff08}.mermaid-container{border:1px solid var(--border-card,#15474d);background:#00000059;border-radius:8px;justify-content:center;align-items:center;margin:18px 0;padding:24px 16px;display:flex;overflow-x:auto}.mermaid-container .mermaid{justify-content:center;width:100%;display:flex}.mermaid-container svg{max-width:100%!important;height:auto!important}.doc-rendered-content code{font-family:var(--font-family-mono,monospace);color:var(--accent-light,#2dd4bf);background:#00000073;border:1px solid #ffffff1a;border-radius:4px;padding:2px 6px;font-size:.82rem}.doc-rendered-content pre{border:1px solid var(--border-card,#15474d);font-family:var(--font-family-mono,monospace);color:#e2e8f0;background:#0000008c;border-radius:6px;margin:14px 0;padding:12px 14px;font-size:.82rem;line-height:1.5;overflow-x:auto}.doc-rendered-content pre code{color:inherit;background:0 0;border:none;padding:0}.doc-rendered-content blockquote{border-left:3px solid var(--primary,#0891b2);color:var(--text-muted,#94a3b8);background:#0891b214;border-radius:0 6px 6px 0;margin:12px 0;padding:6px 14px;font-style:italic}.doc-rendered-content ul,.doc-rendered-content ol{color:#cbd5e1;margin:8px 0 14px 24px;padding:0}.doc-rendered-content li{margin-bottom:4px}.doc-rendered-content a{color:var(--accent-light,#2dd4bf);text-underline-offset:2px;text-decoration:underline}.doc-rendered-content a:hover{color:#5eead4}.doc-rendered-content hr{border:none;border-top:1px solid var(--border-card,#15474d);margin:20px 0}.doc-raw-container{font-family:var(--font-family-mono,monospace);font-size:.82rem;overflow-x:auto}.doc-raw-pre{margin:0}.doc-lines-table{border-collapse:collapse;width:100%}.doc-line-row:hover{background:#ffffff08}.doc-line-num{text-align:right;color:#94a3b880;-webkit-user-select:none;user-select:none;vertical-align:top;border-right:1px solid #ffffff0f;width:45px;padding:2px 10px 2px 4px}.doc-line-code{white-space:pre-wrap;word-break:break-all;color:#e2e8f0;padding:2px 12px}.doc-reader-loading{flex-direction:column;gap:12px;padding:20px;display:flex}.doc-reader-error{color:var(--danger,#ef4444);flex-direction:column;align-items:flex-start;gap:10px;padding:20px;display:flex}.nav-mobile-pane-switcher{background:var(--bg-card,#0d2c2f);border-bottom:1px solid var(--border-card,#15474d);z-index:5;gap:6px;padding:6px 12px;display:none}.mobile-pane-btn{border:1px solid var(--border-card,#15474d);color:var(--text-muted,#94a3b8);cursor:pointer;text-align:center;background:#0000004d;border-radius:5px;flex:1;padding:6px 8px;font-size:.78rem;font-weight:500;transition:all .15s}.mobile-pane-btn.active{background:var(--primary,#0891b2);color:#fff;border-color:var(--primary,#0891b2)}@media (width<=899px){.nav-mobile-pane-switcher{display:none}.nav-panes-layout,.nav-hero-layout{flex-direction:column;flex:1;gap:16px;height:auto;overflow:hidden auto}.nav-pane-column,.nav-sidebar-column{border-right:none;border-bottom:1px solid var(--border,#334155);height:auto;min-height:320px;flex:none!important;width:100%!important;min-width:0!important;max-width:100%!important;display:flex!important}.nav-hero-viewer{height:auto;min-height:360px;flex:none!important;width:100%!important;min-width:0!important;max-width:100%!important;display:flex!important}.nav-toolbar{flex-direction:column;align-items:stretch;gap:10px;height:auto;min-height:auto;max-height:none;padding:10px 12px}.nav-toolbar-left{justify-content:space-between;width:100%}.nav-toolbar-center{width:100%;max-width:100%}.nav-toolbar-right{justify-content:space-between;width:100%}.nav-breadcrumbs-bar{height:auto;min-height:auto;padding:8px 12px}.nav-breadcrumbs-left{flex-wrap:wrap;width:100%}.nav-breadcrumb-trail{white-space:normal;flex-wrap:wrap;max-width:100%}}@media (width>=900px){.nav-mobile-pane-switcher{display:none}.nav-pane-column{display:flex!important}} diff --git a/www/assets/index-DQk4WmqX.css b/www/assets/index-DQk4WmqX.css deleted file mode 100644 index 1fc7a6e..0000000 --- a/www/assets/index-DQk4WmqX.css +++ /dev/null @@ -1 +0,0 @@ -:root{--bg-base:#0a0f1d;--bg-card:#121a2fa6;--border-card:#ffffff14;--primary:#3b82f6;--primary-hover:#2563eb;--accent:#14b8a6;--accent-light:#2dd4bf;--danger:#ef4444;--danger-hover:#dc2626;--text:#f8fafc;--text-muted:#94a3b8;--code-bg:#00000059;--radius:12px}*{box-sizing:border-box;margin:0;padding:0}body{background-color:var(--bg-base);color:var(--text);min-height:100vh;font-family:Outfit,sans-serif;display:block;position:relative;overflow:hidden scroll}.background-decor{pointer-events:none;z-index:0;width:100vw;height:100vh;position:fixed;top:0;left:0;overflow:hidden}.circle{filter:blur(120px);opacity:.25;border-radius:50%;position:absolute}.circle-1{background:#3b82f6;width:450px;height:450px;top:-100px;left:-100px}.circle-2{background:#14b8a6;width:500px;height:500px;bottom:-150px;right:-100px}.dashboard-container{z-index:1;flex-direction:column;gap:20px;width:100%;min-width:0;max-width:1400px;margin:0 auto;padding:30px 48px;display:flex}.dashboard-header{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);justify-content:space-between;align-items:center;padding:20px 24px;display:flex}.header-logo{align-items:center;gap:16px;display:flex}.logo-icon{color:var(--accent-light);font-size:2rem}.header-title h1{letter-spacing:-.5px;font-size:1.4rem;font-weight:700}.header-status{align-items:center;gap:20px;display:flex}.status-item{flex-direction:column;align-items:flex-end;display:flex}.status-item .label{color:var(--text-muted);text-transform:uppercase;letter-spacing:.5px;font-size:.75rem}.status-item .value{align-items:center;gap:6px;font-size:.95rem;font-weight:600;display:flex}.indicator{border-radius:50%;width:8px;height:8px;display:inline-block}.indicator.online{background:#10b981;box-shadow:0 0 10px #10b981}.indicator.indexing{background:#f59e0b;animation:1.5s infinite pulse;box-shadow:0 0 10px #f59e0b}@keyframes pulse{0%{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(1.2)}to{opacity:1;transform:scale(1)}}.dashboard-nav{border-bottom:1px solid var(--border-card);gap:10px;padding-bottom:8px;display:flex}.nav-tab{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:8px;align-items:center;gap:8px;padding:10px 18px;font-family:inherit;font-size:.95rem;font-weight:600;transition:all .2s;display:flex}.nav-tab:hover{color:var(--text);background:#ffffff0d}.nav-tab.active{color:#fff;background:#3b82f633;border:1px solid #3b82f666}.glass-card{background:var(--bg-card);border:1px solid var(--border-card);border-radius:var(--radius);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);width:100%;min-width:0;padding:24px}.glass-card h2{align-items:center;gap:10px;margin-bottom:16px;font-size:1.15rem;font-weight:600;display:flex}.tab-content{width:100%;min-width:0;display:none}.tab-content.active{flex-direction:column;gap:24px;width:100%;min-width:0;display:flex}.overview-grid{grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:16px;display:grid}.stat-metric{align-items:center;gap:16px;padding:20px;display:flex}.metric-icon{color:var(--accent-light);background:#14b8a626;border-radius:12px;justify-content:center;align-items:center;width:52px;height:52px;font-size:2rem;display:flex}.metric-info{flex-direction:column;gap:4px;display:flex}.metric-info .stat-number{color:#fff;font-family:JetBrains Mono,monospace;font-size:1.35rem;font-weight:800;line-height:1.1}.metric-info .stat-label{color:var(--text-muted);font-size:.85rem}.two-col-layout{grid-template-columns:1fr 1fr;gap:20px;display:grid}@media (width<=900px){.two-col-layout{grid-template-columns:1fr}}.specs-list{flex-direction:column;gap:12px;margin-top:12px;display:flex}.spec-row{border-bottom:1px solid #ffffff0d;justify-content:space-between;align-items:center;padding-bottom:8px;font-size:.9rem;display:flex}.tag-cloud{flex-wrap:wrap;gap:8px;max-height:250px;margin-top:12px;display:flex;overflow-y:auto}.topic-tag{color:var(--accent-light);background:#14b8a61f;border:1px solid #14b8a640;border-radius:6px;padding:4px 10px;font-family:JetBrains Mono,monospace;font-size:.8rem}.badge{border-radius:6px;padding:3px 8px;font-size:.75rem;font-weight:600}.badge-primary{color:#93c5fd;background:#3b82f633;border:1px solid #3b82f64d}.badge-accent{color:#5eead4;background:#14b8a633;border:1px solid #14b8a64d}.badge-success{color:#6ee7b7;background:#10b98133;border:1px solid #10b9814d}.badge-warning{color:#fcd34d;background:#f59e0b33;border:1px solid #f59e0b4d}.badge-danger{color:#fca5a5;background:#ef444433;border:1px solid #ef44444d}code,.code{background:var(--code-bg);border-radius:4px;padding:2px 6px;font-family:JetBrains Mono,monospace;font-size:.85rem}.card-header-btn{justify-content:space-between;align-items:center;margin-bottom:16px;display:flex}.table-container{margin-top:10px;overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:.9rem}th{text-align:left;color:var(--text-muted);border-bottom:1px solid #ffffff1a;padding:12px 14px;font-weight:600}td{border-bottom:1px solid #ffffff0a;padding:14px}tr:hover td{background:#ffffff05}.empty-state{text-align:center;color:var(--text-muted);padding:40px!important}.btn{cursor:pointer;border:none;border-radius:8px;align-items:center;gap:8px;padding:8px 16px;font-family:inherit;font-size:.9rem;font-weight:600;transition:all .2s;display:inline-flex}.btn-primary{background:var(--primary);color:#fff}.btn-primary:hover{background:var(--primary-hover)}.btn-secondary{color:#fff;background:#ffffff1a}.btn-secondary:hover{background:#ffffff26}.btn-icon{color:var(--text-muted);cursor:pointer;background:0 0;border:none;border-radius:6px;padding:6px;font-size:.9rem;transition:all .2s}.btn-icon:hover{color:var(--text);background:#ffffff1a}.btn-delete:hover{color:var(--danger)}.form-group{flex-direction:column;gap:6px;margin-bottom:14px;display:flex}.form-group label{color:var(--text-muted);font-size:.85rem;font-weight:600}.form-row{gap:14px;display:flex}input[type=text],input[type=url],input[type=password],select,textarea{color:#fff;background:#00000059;border:1px solid #ffffff1f;border-radius:8px;outline:none;padding:10px 14px;font-family:inherit;font-size:.9rem;transition:border-color .2s}input:focus,select:focus,textarea:focus{border-color:var(--primary)}.path-input-row{gap:8px;display:flex}.path-input-row input{flex:1}.modal-backdrop{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);z-index:1000;background:#000000b3;justify-content:center;align-items:center;width:100vw;height:100vh;display:flex;position:fixed;top:0;left:0}.modal-card{background:#111827;border:1px solid #ffffff26;width:90%;max-width:550px}.modal-header{justify-content:space-between;align-items:center;margin-bottom:20px;display:flex}.modal-header h2{margin-bottom:0}.btn-close{color:var(--text-muted);cursor:pointer;background:0 0;border:none;font-size:1.5rem}.modal-footer{justify-content:flex-end;gap:10px;margin-top:20px;display:flex}.browser-body{margin:16px 0}.browser-breadcrumbs{background:#0000004d;border-radius:6px;margin-bottom:12px;padding:8px 12px;font-size:.85rem}.browser-list-container{background:#0003;border:1px solid #ffffff14;border-radius:6px;max-height:300px;overflow-y:auto}.browser-list{list-style:none}.browser-item{cursor:pointer;border-bottom:1px solid #ffffff0a;align-items:center;gap:10px;padding:8px 12px;font-size:.9rem;display:flex}.browser-item:hover{background:#ffffff0f}.search-hit-card{background:#0000004d;border:1px solid #ffffff14;border-radius:8px;margin-bottom:14px;padding:16px}.search-hit-header{justify-content:space-between;align-items:center;margin-bottom:10px;display:flex}.search-hit-code{white-space:pre-wrap;color:#e2e8f0;background:#070b14;border:1px solid #ffffff0f;border-radius:6px;padding:12px;font-family:JetBrains Mono,monospace;font-size:.85rem;overflow-x:auto}.dashboard-footer{text-align:center;color:var(--text-muted);padding:20px 0;font-size:.8rem}@media (width<=768px){.dashboard-header{flex-direction:column;align-items:flex-start;gap:16px;padding:16px}.header-status{flex-wrap:wrap;justify-content:space-between;width:100%}.dashboard-nav{white-space:nowrap;-webkit-overflow-scrolling:touch;padding-bottom:8px;overflow-x:auto}.dashboard-container{padding:16px 12px}} diff --git a/www/assets/index-DoQkmpth.js b/www/assets/index-DoQkmpth.js new file mode 100644 index 0000000..2eb59ca --- /dev/null +++ b/www/assets/index-DoQkmpth.js @@ -0,0 +1,135 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/elk-276RUBZZ-On_DNuCd.js","assets/src-D_iIdUkB.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js","assets/chunk-O7XYJQB3-Bce2lzyF.js","assets/chunk-ZIGJFQKS-BJ6myxnF.js","assets/dist-Bfr8PhAA.js","assets/chunk-7PRAP22T-DSs4vaIy.js","assets/chunk-742MDFTN-5mFByRwZ.js","assets/chunk-MBY4JIJT-CGQ6Fu8G.js","assets/chunk-7INBJB4K-BkZ96Hf7.js","assets/chunk-J5ZVWO5B-oDCd-gWO.js","assets/rough.esm-Dy-Kn_BL.js","assets/chunk-5DYCD2WN-WToj2Jza.js","assets/chunk-3FUC2YCW-CmoZ3fbX.js","assets/graphlib-C9Tl7QrK.js","assets/_baseUniq-DR4vVjyC.js","assets/chunk-NETBCI7D-Br7cqgBT.js","assets/dagre-6A5THRUB-Bmed3uZj.js","assets/_basePickBy-Cj4iqGU4.js","assets/swimlanes-2SLR337P-BKvviDHP.js","assets/cose-bilkent-JH36ORCC-BtJFQFL9.js","assets/cytoscape.esm-CECbKnxF.js","assets/c4Diagram-YGBWAQC7-Dp1I9kRE.js","assets/chunk-GWA4HPMP-C1P4FmAY.js","assets/flowDiagram-KWPJA3E3-BO7njBlM.js","assets/chunk-XXDRQBXY-C1_eEj17.js","assets/chunk-WEXAMYUT-I3m-hOmT.js","assets/chunk-7M6MHVWA-ZnPgs1Wx.js","assets/channel-_oCHZhRo.js","assets/chunk-5VM5RSS4-ZNzvKenW.js","assets/diagram-22UHCM2B-B4G_FQZz.js","assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js","assets/erDiagram-OPXOYQCR-YD8i2JM4.js","assets/gitGraphDiagram-X574FWY7-BEOc0w88.js","assets/mermaid-parser.core-CUrDj5TF.js","assets/chunk-FOHPRMQF-DHwB1DNv.js","assets/chunk-JWPE2WC7-DVXcaiue.js","assets/chunk-2Q5K7J3B-C1jixKkw.js","assets/ganttDiagram-FUAMR5RP-DWE1bJiy.js","assets/linear-CZ6dxGrP.js","assets/defaultLocale-BFoDCU3G.js","assets/init-C-OQMol4.js","assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js","assets/pieDiagram-5QR66LMP-0Fjx8Dye.js","assets/ordinal-BDEzSJ7C.js","assets/path-fybaL0A-.js","assets/arc-BJA87daU.js","assets/array-BifhSqXX.js","assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js","assets/xychartDiagram-PMCCYNJV-BE8PLguK.js","assets/line-gOgo9JIs.js","assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js","assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js","assets/classDiagram-v2-NBCMYWYE-DLd33yZL.js","assets/stateDiagram-v2-GCMORJYK-CepxBhD6.js","assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js","assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js","assets/mindmap-definition-NLK3R4M7-BCTxemjG.js","assets/kanban-definition-PNTS6WVX-BAMaaT6d.js","assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js","assets/diagram-MLGK6HIB-DILal1CA.js","assets/diagram-MPIPVDR6-8w_EEv4v.js","assets/blockDiagram-BEXU5L5S-LcLXSRjx.js","assets/diagram-CDSNMT55-DcWw9GHj.js","assets/architectureDiagram-NJMV4G6O-CQM7JOeV.js","assets/diagram-ATOU4E4O-BNgT_lbL.js","assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js","assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js","assets/diagram-3UASUU5V-Dv_f5rjj.js","assets/usecaseDiagram-POWQR4AR-1e9d35eQ.js","assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js","assets/cynefinDiagram-VND7K2PF-9xRwA2wI.js","assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js","assets/chunk-GTNCS2PH-CoZ--rjp.js","assets/ebnfDiagram-ZINNZB2B-CGBBBydS.js","assets/abnfDiagram-O67JEVCF-CQJZpKdi.js","assets/pegDiagram-GJSIUBJH-B0Gktij4.js"])))=>i.map(i=>d[i]); +import{_ as e,h as t,m as n,p as r,y as i}from"./src-D_iIdUkB.js";import{n as a}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{$ as o,C as s,E as c,I as l,J as u,K as d,L as f,N as p,P as m,Q as h,S as g,T as _,V as v,W as y,Z as b,_ as x,b as S,c as C,et as w,f as T,g as E,l as D,m as O,n as k,p as A,r as j,s as M,t as N,tt as P,u as F,x as I}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{$ as L,J as R,K as z,Q as B,S as ee,X as te,Y as ne,Z as re,a as ie,d as ae,et as oe,f as se,g as ce,h as le,i as ue,nt as de,o as fe,q as pe,rt as me,tt as he,u as ge,v as _e,x as ve,y as ye}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as be}from"./line-gOgo9JIs.js";import{a as xe,i as Se,n as Ce,t as we}from"./chunk-7PRAP22T-DSs4vaIy.js";import{r as Te}from"./chunk-742MDFTN-5mFByRwZ.js";import{a as Ee,n as De,r as Oe}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{s as ke}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{t as Ae}from"./rough.esm-Dy-Kn_BL.js";import{i as je,n as Me,o as Ne,t as Pe}from"./chunk-7INBJB4K-BkZ96Hf7.js";import{n as Fe,r as Ie}from"./chunk-5DYCD2WN-WToj2Jza.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var Le=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function M(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function N(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,N(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),N(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u{t.exports=Le()})),ze=e((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0>>1,a=e[r];if(0>>1;ri(c,n))li(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(li(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-Tt&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Be=e(((e,t)=>{t.exports=ze()})),Ve=e((e=>{var t=Re();function n(e){var t=`https://react.dev/errors/`+e;if(1{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Ve()})),Ue=e((e=>{var t=Be(),n=Re(),r=He();function i(e){var t=`https://react.dev/errors/`+e;if(1L||(e.current=I[L],I[L]=null,L--)}function B(e,t){L++,I[L]=e.current,e.current=t}var ee=R(null),te=R(null),ne=R(null),re=R(null);function ie(e,t){switch(B(ne,t),B(te,e),B(ee,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}z(ee),B(ee,e)}function ae(){z(ee),z(te),z(ne)}function oe(e){e.memoizedState!==null&&B(re,e);var t=ee.current,n=Hd(t,e.type);t!==n&&(B(te,e),B(ee,n))}function se(e){te.current===e&&(z(ee),z(te)),re.current===e&&(z(re),Qf._currentValue=F)}var ce,le;function ue(e){if(ce===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ce=t&&t[1]||``,le=-1)`:-1i||c[r]!==l[i]){var u=` +`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(``)&&(u=u.replace(``,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{de=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ue(n):``}function pe(e,t){switch(e.tag){case 26:case 27:case 5:return ue(e.type);case 16:return ue(`Lazy`);case 13:return e.child!==t&&t!==null?ue(`Suspense Fallback`):ue(`Suspense`);case 19:return ue(`SuspenseList`);case 0:case 15:return fe(e.type,!1);case 11:return fe(e.type.render,!1);case 1:return fe(e.type,!0);case 31:return ue(`Activity`);default:return``}}function me(e){try{var t=``,n=null;do t+=pe(e,n),n=e,e=e.return;while(e);return t}catch(e){return` +Error generating stack: `+e.message+` +`+e.stack}}var he=Object.prototype.hasOwnProperty,ge=t.unstable_scheduleCallback,_e=t.unstable_cancelCallback,ve=t.unstable_shouldYield,ye=t.unstable_requestPaint,be=t.unstable_now,xe=t.unstable_getCurrentPriorityLevel,Se=t.unstable_ImmediatePriority,Ce=t.unstable_UserBlockingPriority,we=t.unstable_NormalPriority,Te=t.unstable_LowPriority,Ee=t.unstable_IdlePriority,De=t.log,Oe=t.unstable_setDisableYieldValue,ke=null,Ae=null;function je(e){if(typeof De==`function`&&Oe(e),Ae&&typeof Ae.setStrictMode==`function`)try{Ae.setStrictMode(ke,e)}catch{}}var Me=Math.clz32?Math.clz32:Fe,Ne=Math.log,Pe=Math.LN2;function Fe(e){return e>>>=0,e===0?32:31-(Ne(e)/Pe|0)|0}var Ie=256,Le=262144,ze=4194304;function Ve(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ue(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Ve(n))):i=Ve(o):i=Ve(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ve(n))):i=Ve(o)):i=Ve(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function V(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ge(){var e=ze;return ze<<=1,!(ze&62914560)&&(ze=4194304),e}function Ke(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function H(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function qe(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0`u`||window.document===void 0||window.document.createElement===void 0),rn=!1;if(nn)try{var an={};Object.defineProperty(an,"passive",{get:function(){rn=!0}}),window.addEventListener(`test`,an,an),window.removeEventListener(`test`,an,an)}catch{rn=!1}var on=null,sn=null,cn=null;function ln(){if(cn)return cn;var e,t=sn,n=t.length,r,i=`value`in on?on.value:on.textContent,a=i.length;for(e=0;e=Vn),Wn=` `,Gn=!1;function Kn(e,t){switch(e){case`keyup`:return zn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function qn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Jn=!1;function Yn(e,t){switch(e){case`compositionend`:return qn(t);case`keypress`:return t.which===32?(Gn=!0,Wn):null;case`textInput`:return e=t.data,e===Wn&&Gn?null:e;default:return null}}function Xn(e,t){if(Jn)return e===`compositionend`||!Bn&&Kn(e,t)?(e=ln(),cn=sn=on=null,Jn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=vr(n)}}function br(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?br(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function xr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=jt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=jt(e.document)}return t}function Sr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Cr=nn&&`documentMode`in document&&11>=document.documentMode,wr=null,Tr=null,Er=null,Dr=!1;function Or(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Dr||wr==null||wr!==jt(r)||(r=wr,`selectionStart`in r&&Sr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Er&&_r(Er,r)||(Er=r,r=Td(Tr,`onSelect`),0>=o,i-=o,bi=1<<32-Me(t)+i|n<m?(h=d,d=null):h=d.sibling;var g=p(i,d,s[m],c);if(g===null){d===null&&(d=h);break}e&&d&&g.alternate===null&&t(i,d),a=o(g,a,m),u===null?l=g:u.sibling=g,u=g,d=h}if(m===s.length)return n(i,d),G&&Si(i,m),l;if(d===null){for(;mh?(g=m,m=null):g=m.sibling;var y=p(a,m,v.value,l);if(y===null){m===null&&(m=g);break}e&&m&&y.alternate===null&&t(a,m),s=o(y,s,h),d===null?u=y:d.sibling=y,d=y,m=g}if(v.done)return n(a,m),G&&Si(a,h),u;if(m===null){for(;!v.done;h++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return G&&Si(a,h),u}for(m=r(m);!v.done;h++,v=c.next())v=_(m,a,h,v.value,l),v!==null&&(e&&v.alternate!==null&&m.delete(v.key===null?h:v.key),s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return e&&m.forEach(function(e){return t(a,e)}),G&&Si(a,h),u}function x(e,r,o,c){if(typeof o==`object`&&o&&o.type===g&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case m:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===g){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===T&&Sa(l)===r.type){n(e,r.sibling),c=a(r,o.props),ka(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===g?(c=si(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=oi(o.type,o.key,o.props,null,e.mode,c),ka(c,o),c.return=e,e=c)}return s(e);case h:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=ui(o,e.mode,c),c.return=e,e=c}return s(e);case T:return o=Sa(o),x(e,r,o,c)}if(M(o))return v(e,r,o,c);if(k(o)){if(l=k(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return x(e,r,Oa(o),c);if(o.$$typeof===b)return x(e,r,Xi(e,o),c);Aa(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=ci(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Da=0;var i=x(e,t,n,r);return Ea=null,i}catch(t){if(t===ga||t===va)throw t;var a=ni(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ma=ja(!0),Na=ja(!1),K=!1;function Pa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Fa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ia(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function La(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=$r(e),Qr(e,null,n),t}return Yr(e,r,t,n),$r(e)}function Ra(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ye(e,n)}}function za(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ba=!1;function Va(){if(Ba){var e=sa;if(e!==null)throw e}}function Ha(e,t,n,r){Ba=!1;var i=e.updateQueue;K=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var p=s.lane&-536870913,m=p!==s.lane;if(m?(X&p)===p:(r&p)===p){p!==0&&p===oa&&(Ba=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;p=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,p);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,p=typeof h==`function`?h.call(_,d,p):h,p==null)break a;d=f({},d,p);break a;case 2:K=!0}}p=s.callback,p!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[p]:m.push(p))}else m={lane:p,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=p;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Wl|=o,e.lanes=o,e.memoizedState=d}}function Ua(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function Wa(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;ea?a:8;var o=N.T,s={};N.T=s,As(e,!1,t,n);try{var c=i(),l=N.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?ks(e,t,ua(c,r),du(e)):ks(e,t,r,du(e))}catch(n){ks(e,t,{then:function(){},status:`rejected`,reason:n},du())}finally{P.p=a,o!==null&&s.types!==null&&(o.types=s.types),N.T=o}}function ys(){}function bs(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=xs(e).queue;vs(e,a,t,F,n===null?ys:function(){return Ss(e),n(r)})}function xs(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:F,baseState:F,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jo,lastRenderedState:F},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ss(e){var t=xs(e);t.next===null&&(t=e.alternate.memoizedState),ks(e,t.next.queue,{},du())}function Cs(){return Yi(Qf)}function ws(){return Eo().memoizedState}function Ts(){return Eo().memoizedState}function Es(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=du();e=Ia(n);var r=La(t,e,n);r!==null&&(pu(r,t,n),Ra(r,t,n)),t={cache:na()},e.payload=t;return}t=t.return}}function Ds(e,t,n){var r=du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},js(e)?Ms(t,n):(n=Xr(e,t,n,r),n!==null&&(pu(n,e,r),Ns(n,t,r)))}function Os(e,t,n){ks(e,t,n,du())}function ks(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(js(e))Ms(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,gr(s,o))return Yr(e,t,i,0),Ll===null&&Jr(),!1}catch{}if(n=Xr(e,t,i,r),n!==null)return pu(n,e,r),Ns(n,t,r),!0}return!1}function As(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},js(e)){if(t)throw Error(i(479))}else t=Xr(e,n,r,2),t!==null&&pu(t,e,2)}function js(e){var t=e.alternate;return e===q||t!==null&&t===q}function Ms(e,t){lo=co=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ns(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ye(e,n)}}var Ps={readContext:Yi,use:ko,useCallback:go,useContext:go,useEffect:go,useImperativeHandle:go,useLayoutEffect:go,useInsertionEffect:go,useMemo:go,useReducer:go,useRef:go,useState:go,useDebugValue:go,useDeferredValue:go,useTransition:go,useSyncExternalStore:go,useId:go,useHostTransitionStatus:go,useFormState:go,useActionState:go,useOptimistic:go,useMemoCache:go,useCacheRefresh:go};Ps.useEffectEvent=go;var Fs={readContext:Yi,use:ko,useCallback:function(e,t){return To().memoizedState=[e,t===void 0?null:t],e},useContext:Yi,useEffect:as,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),rs(4194308,4,ds.bind(null,t,e),n)},useLayoutEffect:function(e,t){return rs(4194308,4,e,t)},useInsertionEffect:function(e,t){rs(4,2,e,t)},useMemo:function(e,t){var n=To();t=t===void 0?null:t;var r=e();if(uo){je(!0);try{e()}finally{je(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=To();if(n!==void 0){var i=n(t);if(uo){je(!0);try{n(t)}finally{je(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ds.bind(null,q,e),[r.memoizedState,e]},useRef:function(e){var t=To();return e={current:e},t.memoizedState=e},useState:function(e){e=Vo(e);var t=e.queue,n=Os.bind(null,q,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ps,useDeferredValue:function(e,t){return gs(To(),e,t)},useTransition:function(){var e=Vo(!1);return e=vs.bind(null,q,e.queue,!0,!1),To().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=q,a=To();if(G){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Ll===null)throw Error(i(349));X&127||Io(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,as(Ro.bind(null,r,o,e),[e]),r.flags|=2048,ts(9,{destroy:void 0},Lo.bind(null,r,o,n,t),null),n},useId:function(){var e=To(),t=Ll.identifierPrefix;if(G){var n=xi,r=bi;n=(r&~(1<<32-Me(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=fo++,0<\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[tt]=t,o[nt]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&kc(t)}}return Pc(t),Ac(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&kc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=ne.current,Fi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Di,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[tt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Mi(t,!0)}else e=Bd(e).createTextNode(r),e[tt]=t,t.stateNode=e}return Pc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Fi(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[tt]=t}else Ii(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Pc(t),e=!1}else n=Li(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(no(t),t):(no(t),null);if(t.flags&128)throw Error(i(558))}return Pc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Fi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[tt]=t}else Ii(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Pc(t),a=!1}else a=Li(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(no(t),t):(no(t),null)}return no(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Mc(t,t.updateQueue),Pc(t),null);case 4:return ae(),e===null&&xd(t.stateNode.containerInfo),Pc(t),null;case 10:return Ui(t.type),Pc(t),null;case 19:if(z(ro),r=t.memoizedState,r===null)return Pc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Nc(r,!1);else{if(Ul!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=io(e),o!==null){for(t.flags|=128,Nc(r,!1),e=o.updateQueue,t.updateQueue=e,Mc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ai(n,e),n=n.sibling;return B(ro,ro.current&1|2),G&&Si(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&be()>eu&&(t.flags|=128,a=!0,Nc(r,!1),t.lanes=4194304)}}else{if(!a){if(e=io(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Mc(t,e),Nc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!G)return Pc(t),null}else 2*be()-r.renderingStartTime>eu&&n!==536870912&&(t.flags|=128,a=!0,Nc(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Pc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=be(),e.sibling=null,n=ro.current,B(ro,a?n&1|2:n&1),G&&Si(t,r.treeForkCount),e);case 22:case 23:return no(t),Ya(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Pc(t),t.subtreeFlags&6&&(t.flags|=8192)):Pc(t),n=t.updateQueue,n!==null&&Mc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&z(fa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Ui(ta),Pc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Ic(e,t){switch(Ti(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ui(ta),ae(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return se(t),null;case 31:if(t.memoizedState!==null){if(no(t),t.alternate===null)throw Error(i(340));Ii()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(no(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Ii()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return z(ro),null;case 4:return ae(),null;case 10:return Ui(t.type),null;case 22:case 23:return no(t),Ya(),e!==null&&z(fa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Ui(ta),null;case 25:return null;default:return null}}function Lc(e,t){switch(Ti(t),t.tag){case 3:Ui(ta),ae();break;case 26:case 27:case 5:se(t);break;case 4:ae();break;case 31:t.memoizedState!==null&&no(t);break;case 13:no(t);break;case 19:z(ro);break;case 10:Ui(t.type);break;case 22:case 23:no(t),Ya(),e!==null&&z(fa);break;case 24:Ui(ta)}}function Rc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Uu(t,t.return,e)}}function zc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Uu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Uu(t,t.return,e)}}function Bc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Wa(t,n)}catch(t){Uu(e,e.return,t)}}}function Vc(e,t,n){n.props=Hs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Uu(e,t,n)}}function Hc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Uu(e,t,n)}}function Uc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Uu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Uu(e,t,n)}else n.current=null}}function Wc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Uu(e,e.return,t)}}function Gc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[nt]=t}catch(t){Uu(e,e.return,t)}}function Kc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function qc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Kc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Jc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=qt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Jc(e,t,n),e=e.sibling;e!==null;)Jc(e,t,n),e=e.sibling}function Yc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Yc(e,t,n),e=e.sibling;e!==null;)Yc(e,t,n),e=e.sibling}function Xc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[tt]=e,t[nt]=n}catch(t){Uu(e,e.return,t)}}var Zc=!1,Qc=!1,$c=!1,el=typeof WeakSet==`function`?WeakSet:Set,tl=null;function nl(e,t){if(e=e.containerInfo,Rd=sp,e=xr(e),Sr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,tl=t;tl!==null;)if(t=tl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,tl=e;else for(;tl!==null;){switch(t=tl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n title`))),Pd(o,r,n),o[tt]=e,mt(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;cg&&(o=g,g=h,h=o);var _=yr(s,h),v=yr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;sn?32:n,N.T=null,n=su,su=null;var o=iu,s=au;if(ru=0,Q=iu=null,au=0,J&6)throw Error(i(331));var c=J;if(J|=4,Ml(o.current),wl(o,o.current,s,n),J=c,rd(0,!1),Ae&&typeof Ae.onPostCommitFiberRoot==`function`)try{Ae.onPostCommitFiberRoot(ke,o)}catch{}return!0}finally{P.p=a,N.T=r,zu(e,t)}}function Hu(e,t,n){t=fi(n,t),t=Js(e.stateNode,t,2),e=La(e,t,2),e!==null&&(H(e,2),nd(e))}function Uu(e,t,n){if(e.tag===3)Hu(e,e,n);else for(;t!==null;){if(t.tag===3){Hu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(nu===null||!nu.has(r))){e=fi(n,e),n=Ys(2),r=La(t,n,2),r!==null&&(Xs(n,r,t,e),H(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Il;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Vl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Ll===e&&(X&n)===n&&(Ul===4||Ul===3&&(X&62914560)===X&&300>be()-Ql?!(J&2)&&bu(e,0):Kl|=n,Jl===X&&(Jl=0)),nd(e)}function Ku(e,t){t===0&&(t=Ge()),e=Zr(e,t),e!==null&&(H(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return ge(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Me(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=X,a=Ue(r,r===Ll?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,cd(r,a))}r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Gd()&&(e=td);for(var t=be(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}ru!==0&&ru!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Nt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Nt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Nt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Nt(n.imageSizes)+`"]`)):i+=`[href="`+Nt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=f({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),mt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Nt(r)+`"][href="`+Nt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=f({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),mt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=pt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=f({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);mt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=f({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=pt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=f({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),mt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var a=(a=ne.current)?gf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=pt(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=pt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=pt(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Af(e){return`href="`+Nt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return f({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),mt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Nt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Nt(n.href)+`"]`);if(r)return t.instance=r,mt(r),r;var a=f({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),mt(r),Pd(r,`style`,a),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Af(n.href);var o=e.querySelector(jf(a));if(o)return t.state.loading|=4,t.instance=o,mt(o),o;r=Mf(n),(a=mf.get(a))&&Rf(r,a),o=(e.ownerDocument||e).createElement(`link`),mt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(a=e.querySelector(Ff(o)))?(t.instance=a,mt(a),a):(r=n,(a=mf.get(o))&&(r=f({},n),zf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),mt(a),Pd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,mt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),mt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Ue()})),V=i(Re(),1),Ge=We(),Ke=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),H=e(((e,t)=>{t.exports=Ke()}))(),qe=(0,V.createContext)(void 0);function Je(){let e=(0,V.useContext)(qe);if(!e)throw Error(`useToast must be used within a ToastProvider`);return e.toast}var Ye=0;function Xe({children:e}){let[t,n]=(0,V.useState)([]),r=(0,V.useState)(()=>new Map)[0];(0,V.useEffect)(()=>()=>{r.forEach(e=>clearTimeout(e)),r.clear()},[r]);let i=(0,V.useCallback)(e=>{let t=r.get(e);t&&(clearTimeout(t),r.delete(e)),n(t=>t.filter(t=>t.id!==e))},[r]),a=(0,V.useCallback)((e,t=`info`)=>{let i=++Ye;n(n=>[...n,{id:i,message:e,type:t}]);let a=setTimeout(()=>{r.delete(i),n(e=>e.filter(e=>e.id!==i))},4e3);r.set(i,a)},[r]),o=(0,V.useMemo)(()=>({success:e=>a(e,`success`),error:e=>a(e,`error`),info:e=>a(e,`info`),warning:e=>a(e,`warning`),showToast:(e,t)=>a(e,t||`info`),dismiss:i}),[a,i]);return(0,H.jsxs)(qe.Provider,{value:{toast:o},children:[e,(0,H.jsx)(`div`,{className:`toast-container`,"aria-live":`polite`,"aria-atomic":`true`,children:t.map(e=>(0,H.jsxs)(`div`,{className:`toast toast-${e.type}`,role:`status`,children:[e.type===`error`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`,"aria-hidden":`true`}),e.type===`success`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,"aria-hidden":`true`}),e.type===`info`&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-info`,"aria-hidden":`true`}),e.type===`warning`&&(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,"aria-hidden":`true`}),(0,H.jsx)(`span`,{className:`toast-message`,children:e.message}),(0,H.jsx)(`button`,{type:`button`,className:`toast-dismiss-btn`,onClick:()=>i(e.id),"aria-label":`Dismiss notification`,title:`Dismiss`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-xmark`,"aria-hidden":`true`})})]},e.id))})]})}function Ze({stats:e,refreshStats:t}){let n=Je();return e?(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`overview-grid`,children:[(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-brands fa-github`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.repos_count??e.git_repos??0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`Git Repositories`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-code`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.symbols_count||0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`AST Code Symbols`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.files_count||0).toLocaleString()}),(0,H.jsx)(`span`,{className:`stat-label`,children:`Indexed Files`})]})]}),(0,H.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,H.jsx)(`div`,{className:`metric-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-network-wired`})}),(0,H.jsxs)(`div`,{className:`metric-info`,children:[(0,H.jsx)(`span`,{className:`stat-number`,children:(e.points_count||0).toLocaleString()}),(0,H.jsxs)(`span`,{className:`stat-label`,children:[(e.vector_store_provider||`Qdrant`).toUpperCase(),` (`,(e.vector_store_mode||`embedded`)===`embedded`?`Embedded`:`Remote`,`) Vectors`]})]})]})]}),(0,H.jsxs)(`div`,{className:`two-col-layout`,style:{marginTop:`20px`},children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-server`}),` System & Embedding Specs`]}),(0,H.jsxs)(`div`,{className:`specs-list`,children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Vector Database:`}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsxs)(`span`,{className:`badge badge-accent`,children:[e.vector_store_provider===`chroma`?`ChromaDB`:`Qdrant`,` (`,(e.vector_store_mode||`embedded`)===`embedded`?`Embedded Disk`:`Remote Server`,`)`]}),e.vector_db_status&&(0,H.jsx)(`span`,{className:`badge ${e.vector_db_status===`Healthy`?`badge-success`:`badge-danger`}`,"data-testid":`overview-vector-db-status`,children:e.vector_db_status})]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Dense Embedding Model:`}),(0,H.jsx)(`code`,{children:e.dense_model||`bge-small-en-v1.5 (384d)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Sparse BM25 Model:`}),(0,H.jsx)(`code`,{children:e.sparse_model?`${e.sparse_model} (FastEmbed)`:`Qdrant/bm25 (FastEmbed)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Retrieval Strategy:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.vector_store_provider===`chroma`?`Dense Vector Cosine Similarity`:`Dense + BM25 Normalized Weighted Fusion`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`AST Chunker:`}),(0,H.jsx)(`span`,{children:`Tree-sitter AST (Classes, Functions, Methods)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Last Global Index:`}),(0,H.jsx)(`span`,{className:`code`,children:e.last_indexed||`Never`})]})]}),(0,H.jsx)(`div`,{style:{marginTop:`20px`},children:(0,H.jsx)(`button`,{className:`btn btn-primary`,onClick:async()=>{try{let e=await fetch(`/admin/api/reindex`,{method:`POST`});if(!e.ok){let t=await e.json().catch(()=>({}));throw Error(t.error||`Failed to trigger reindex`)}n.success(`Re-indexing triggered successfully`),t()}catch(e){n.error(`Reindex error: `+e.message)}},disabled:e.is_indexing,children:e.is_indexing?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Reindex All Sources`]})})})]}),(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-tags`}),` Top Extracted Topics & Symbols`]}),(0,H.jsx)(`div`,{className:`tag-cloud`,children:!e.top_keywords||e.top_keywords.length===0?(0,H.jsx)(`span`,{className:`text-muted`,children:`No topics extracted yet. Sync repositories to populate.`}):e.top_keywords.map(e=>(0,H.jsx)(`span`,{className:`topic-tag`,children:e},e))})]})]})]}):(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsx)(`p`,{children:`Loading...`})})}var Qe=He();function $e({isOpen:e,onClose:t,onSave:n,alias:r,setAlias:i,url:a,setUrl:o,branch:s,setBranch:c,provider:l,setProvider:u,authUser:d,setAuthUser:f,token:p,setToken:m,keepShallow:h=!1,setKeepShallow:g,isSaving:_}){if(!e)return null;let v=(0,H.jsx)(`div`,{className:`modal-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`}),` Register Git Repository`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:n,children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-alias`,children:`Repository Alias / Identifier`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-alias`,required:!0,placeholder:`e.g. backend-api or contextcortex`,value:r,onChange:e=>i(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-provider`,children:`Git Provider`}),(0,H.jsxs)(`select`,{id:`repo-provider`,value:l,onChange:e=>u(e.target.value),children:[(0,H.jsx)(`option`,{value:`auto`,children:`Auto-Detect`}),(0,H.jsx)(`option`,{value:`github`,children:`GitHub / GitHub Enterprise`}),(0,H.jsx)(`option`,{value:`gitlab`,children:`GitLab (Cloud / Self-Hosted)`}),(0,H.jsx)(`option`,{value:`gitea`,children:`Gitea / Forgejo`}),(0,H.jsx)(`option`,{value:`bitbucket`,children:`Bitbucket`}),(0,H.jsx)(`option`,{value:`generic`,children:`Generic Git (HTTP / HTTPS)`})]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-url`,children:`Git Clone URL (HTTP / HTTPS)`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-url`,required:!0,placeholder:`https://github.com/owner/repo.git or http://git.lan:3000/repo.git`,value:a,onChange:e=>o(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-row form-row-3col`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-branch`,children:`Branch / Tag`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-branch`,placeholder:`main`,value:s,onChange:e=>c(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-user`,children:`Auth User (Optional)`}),(0,H.jsx)(`input`,{type:`text`,id:`repo-user`,placeholder:`e.g. oauth2`,value:d,onChange:e=>f(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`repo-token`,children:`Auth Token (Optional)`}),(0,H.jsx)(`input`,{type:`password`,id:`repo-token`,placeholder:`Token override`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginTop:`12px`},children:[(0,H.jsxs)(`label`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,cursor:`pointer`,fontWeight:600,color:`var(--text)`},children:[(0,H.jsx)(`input`,{type:`checkbox`,id:`repo-keep-shallow`,checked:h,onChange:e=>g?.(e.target.checked),style:{width:`16px`,height:`16px`,accentColor:`var(--primary)`,cursor:`pointer`}}),(0,H.jsx)(`span`,{children:`Keep shallow copy on disk`})]}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{fontSize:`0.82rem`,marginTop:`4px`,marginLeft:`24px`,lineHeight:`1.4`},children:[`When enabled, retains a shallow clone (`,(0,H.jsx)(`code`,{children:`--depth 1`}),`) in persistent storage on disk after indexing, enabling instant full-file inspection in Code Navigator and faster delta updates.`]})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:t,children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:_,children:_?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Adding & Syncing...`]}):`Add & Start Sync`})]})]})]})});return typeof document<`u`?(0,Qe.createPortal)(v,document.body):v}function et({repo:e,onClose:t,onCopyUrl:n,copiedUrl:r}){if(!e)return null;let i=`${typeof window<`u`?window.location.origin:``}/api/webhooks/git`,a=(0,H.jsx)(`div`,{className:`modal-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},"data-testid":`webhook-modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`650px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook Setup: `,e.name]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,"aria-label":`Close webhook modal`,children:`×`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`16px`,fontSize:`0.9rem`},children:[(0,H.jsx)(`p`,{className:`text-muted`,children:`Configure a webhook in your Git repository provider to automatically trigger synchronization on every push event.`}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Webhook URL (Payload URL)`}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:i,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`},"aria-label":`Webhook Payload URL`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>n(i),style:{minWidth:`95px`},"aria-label":`Copy Webhook URL`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-check`:`fa-copy`}`}),` `,r?`Copied!`:`Copy`]})]})]}),e.webhook_secret&&(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Repository Secret Token (HMAC)`}),(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:e.webhook_secret,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`},"aria-label":`Repository Secret Token`})]}),(0,H.jsxs)(`div`,{style:{background:`rgba(0, 0, 0, 0.25)`,border:`1px solid var(--border-card)`,borderRadius:`8px`,padding:`14px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`0.95rem`,marginBottom:`10px`,color:`var(--text)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-list-check`}),` Provider Setup Instructions`]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`10px`,fontSize:`0.85rem`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{marginRight:`6px`}}),` GitHub:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks > Add webhook`}),` → set `,(0,H.jsx)(`em`,{children:`Payload URL`}),` to the URL above → set `,(0,H.jsx)(`em`,{children:`Content type`}),` to `,(0,H.jsx)(`code`,{children:`application/json`}),` → select `,(0,H.jsx)(`em`,{children:`Push events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add webhook`}),`.`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab`,style:{color:`#fc6d26`,marginRight:`6px`}}),` GitLab:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks`}),` (or `,(0,H.jsx)(`code`,{children:`Settings > Integrations`}),`) → set `,(0,H.jsx)(`em`,{children:`URL`}),` → select `,(0,H.jsx)(`em`,{children:`Push events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add webhook`}),`.`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`strong`,{style:{color:`#fff`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot`,style:{color:`#609926`,marginRight:`6px`}}),` Gitea / Forgejo:`]}),(0,H.jsxs)(`div`,{style:{color:`var(--text-muted)`,marginTop:`2px`,marginLeft:`18px`},children:[`Navigate to `,(0,H.jsx)(`code`,{children:`Settings > Webhooks > Add Webhook > Gitea`}),` → set `,(0,H.jsx)(`em`,{children:`Target URL`}),` → set `,(0,H.jsx)(`em`,{children:`HTTP Method`}),` to `,(0,H.jsx)(`code`,{children:`POST`}),` → select `,(0,H.jsx)(`em`,{children:`Push Events`}),` → click `,(0,H.jsx)(`strong`,{children:`Add Webhook`}),`.`]})]})]})]}),(0,H.jsx)(`div`,{className:`modal-footer`,style:{marginTop:`8px`,padding:0},children:(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:t,children:`Close`})})]})]})});return typeof document<`u`?(0,Qe.createPortal)(a,document.body):a}function U({repos:e,isLoading:t,syncStates:n,onSync:r,onToggleAutoSync:i,onToggleKeepShallow:a,onOpenWebhook:o,onDelete:s,onOpenSyncDrawer:c}){let l=e=>{let t=(e||`github`).toLowerCase();return t===`gitlab`?(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab`,style:{color:`#fc6d26`,marginRight:`6px`},title:`GitLab`}):t===`gitea`||t===`forgejo`?(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot`,style:{color:`#609926`,marginRight:`6px`},title:`Gitea / Forgejo`}):t===`bitbucket`?(0,H.jsx)(`i`,{className:`fa-brands fa-bitbucket`,style:{color:`#2684ff`,marginRight:`6px`},title:`Bitbucket`}):t===`generic`?(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`,style:{color:`var(--accent)`,marginRight:`6px`},title:`Generic Git`}):(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{marginRight:`6px`},title:`GitHub`})},u=(e,t)=>{let n=t?.step||1,r=t?.total_steps||5,i=t?.step_name||`Syncing...`,a=t?.percent??0,o=t?.current_file;return(0,H.jsxs)(`div`,{className:`sync-progress-container`,onClick:()=>c?.(e.id),role:`button`,tabIndex:0,style:{cursor:`pointer`},title:`Click to view live ingestion progress & logs`,onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&c?.(e.id)},children:[(0,H.jsxs)(`div`,{className:`progress-pill badge badge-warning`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),(0,H.jsxs)(`span`,{children:[`Step `,n,`/`,r,`: `,i,` (`,a,`%)`]})]}),(0,H.jsx)(`div`,{className:`sync-progress-bar-wrapper`,children:(0,H.jsx)(`div`,{className:`sync-progress-bar-fill fill-active`,style:{width:`${a}%`}})}),o&&(0,H.jsxs)(`div`,{className:`sync-file-caption`,title:o,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{marginRight:`4px`}}),(0,H.jsx)(`code`,{children:o})]})]})};return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Git URL`}),(0,H.jsx)(`th`,{children:`Branch`}),(0,H.jsx)(`th`,{children:`Commit SHA`}),(0,H.jsx)(`th`,{children:`Status`}),(0,H.jsx)(`th`,{children:`Auto-Sync`}),(0,H.jsx)(`th`,{children:`Shallow Copy`}),(0,H.jsx)(`th`,{children:`Files`}),(0,H.jsx)(`th`,{children:`Last Synced`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:t&&e.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsxs)(`td`,{colSpan:10,className:`empty-state`,"data-testid":`repo-loading-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading repositories...`]})}):e.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:10,className:`empty-state`,children:`No Git repositories registered. Click "Add Repository" to index a remote repo.`})}):e.map(e=>{let t=e.auto_sync!==!1&&e.auto_sync!==0,d=e.keep_shallow===!0||e.keep_shallow===1,f=n?.[e.id],p=e.status===`syncing`||f?.status===`syncing`;return(0,H.jsxs)(`tr`,{children:[(0,H.jsxs)(`td`,{children:[l(e.provider),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`a`,{href:e.url,target:`_blank`,rel:`noreferrer`,className:`repo-url-link`,style:{color:`var(--primary)`,textDecoration:`none`,fontSize:`0.85rem`},title:e.url,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrow-up-right-from-square`}),` `,e.url]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.branch})}),(0,H.jsx)(`td`,{children:e.commit_sha?(0,H.jsx)(`code`,{children:e.commit_sha.substring(0,8)}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:p?u(e,f):e.status===`error`||f?.status===`error`?(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.last_error||f?.error||`Sync failed`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}),(e.last_error||f?.error)&&(0,H.jsx)(`div`,{style:{fontSize:`0.75rem`,color:`var(--danger)`,marginTop:`4px`,maxWidth:`180px`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},title:e.last_error||f?.error||``,children:e.last_error||f?.error})]}):e.status===`pending`||f?.status===`pending`?(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]}):(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]})}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{type:`button`,className:`badge ${t?`badge-success`:`badge-danger`}`,style:{cursor:`pointer`,background:t?`rgba(16, 185, 129, 0.2)`:`rgba(239, 68, 68, 0.2)`,border:t?`1px solid rgba(16, 185, 129, 0.4)`:`1px solid rgba(239, 68, 68, 0.4)`,color:t?`#6ee7b7`:`#fca5a5`,padding:`4px 8px`,display:`inline-flex`,alignItems:`center`,gap:`6px`},onClick:()=>i(e.id,t),title:`Auto-Sync: ${t?`ON`:`OFF`} (Click to toggle)`,"aria-label":`Toggle auto-sync for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${t?`fa-toggle-on`:`fa-toggle-off`}`}),`Auto-Sync: `,t?`ON`:`OFF`]})}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{type:`button`,className:`badge ${d?`badge-primary`:`badge-secondary`}`,style:{cursor:`pointer`,background:d?`rgba(8, 145, 178, 0.2)`:`rgba(100, 116, 139, 0.2)`,border:d?`1px solid rgba(8, 145, 178, 0.4)`:`1px solid rgba(100, 116, 139, 0.4)`,color:d?`#38bdf8`:`#94a3b8`,padding:`4px 8px`,display:`inline-flex`,alignItems:`center`,gap:`6px`},onClick:()=>a?.(e.id,d),title:`Shallow Copy: ${d?`Retained on disk (persistent)`:`Ephemeral (pruned)`} (Click to toggle)`,"aria-label":`Toggle shallow copy retention for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${d?`fa-hard-drive`:`fa-trash-can`}`}),d?`Kept on Disk`:`Ephemeral`]})}),(0,H.jsxs)(`td`,{children:[(e.file_count||0).toLocaleString(),` files`]}),(0,H.jsx)(`td`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`},children:e.last_synced||`Never`}),(0,H.jsx)(`td`,{children:(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>c?.(e.id),title:`View Ingestion Logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Logs`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>r(e.id),title:`Trigger Sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Sync`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>o(e),title:`Webhook Setup`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook`]}),(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>s(e.id,e.name),title:`Delete Repo`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})]})})]},e.id)})})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:t&&e.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,"data-testid":`repo-loading-state-mobile`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading repositories...`]}):e.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No Git repositories registered. Click "Add Repository" to index a remote repo.`}):e.map(e=>{let t=e.auto_sync!==!1&&e.auto_sync!==0,d=e.keep_shallow===!0||e.keep_shallow===1,f=n?.[e.id],p=e.status===`syncing`||f?.status===`syncing`;return(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:[l(e.provider),(0,H.jsx)(`strong`,{style:{fontSize:`1rem`},children:e.name})]}),!p&&(e.status===`error`||f?.status===`error`?(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.last_error||f?.error||`Sync failed`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}):e.status===`pending`||f?.status===`pending`?(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]}):(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]}))]}),p&&(0,H.jsx)(`div`,{style:{margin:`4px 0 2px 0`},children:u(e,f)}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`,alignItems:`baseline`},children:[(0,H.jsx)(`span`,{className:`data-label`,style:{flexShrink:0},children:`URL:`}),(0,H.jsx)(`a`,{href:e.url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,textDecoration:`none`,wordBreak:`break-all`,minWidth:0},children:e.url})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Branch:`}),(0,H.jsx)(`code`,{children:e.branch})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Commit:`}),e.commit_sha?(0,H.jsx)(`code`,{children:e.commit_sha.substring(0,8)}):`-`]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Auto-Sync:`}),(0,H.jsx)(`button`,{type:`button`,className:`badge ${t?`badge-success`:`badge-danger`}`,style:{cursor:`pointer`,padding:`4px 8px`,fontSize:`0.75rem`,minHeight:`24px`,minWidth:`24px`,display:`inline-flex`,alignItems:`center`,justifyContent:`center`},onClick:()=>i(e.id,t),title:`Auto-Sync: ${t?`ON`:`OFF`} (Click to toggle)`,"aria-label":`Toggle auto-sync for ${e.name}`,children:t?`ON`:`OFF`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Shallow Copy:`}),(0,H.jsxs)(`button`,{type:`button`,className:`badge ${d?`badge-primary`:`badge-secondary`}`,style:{cursor:`pointer`,padding:`4px 8px`,fontSize:`0.75rem`,minHeight:`24px`,display:`inline-flex`,alignItems:`center`,gap:`4px`},onClick:()=>a?.(e.id,d),title:`Shallow Copy: ${d?`Retained on disk`:`Ephemeral`} (Click to toggle)`,"aria-label":`Toggle shallow copy retention for ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${d?`fa-hard-drive`:`fa-trash-can`}`}),d?`Kept on Disk`:`Ephemeral`]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Files:`}),(e.file_count||0).toLocaleString(),` files`]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Last Synced:`}),e.last_synced||`Never`]}),!p&&(e.last_error||f?.error)&&(0,H.jsxs)(`div`,{style:{color:`var(--danger)`,fontSize:`0.75rem`},children:[(0,H.jsx)(`span`,{className:`data-label`,children:`Error:`}),e.last_error||f?.error]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-actions`,children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>c?.(e.id),title:`View Ingestion Logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Logs`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>r(e.id),title:`Trigger Sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Sync`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>o(e),title:`Webhook Setup`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Webhook`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>s(e.id,e.name),title:`Delete Repo`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})]})]},`card-${e.id}`)})})]})}var tt=[{step:1,title:`1. Connecting & Remote Check`},{step:2,title:`2. Shallow Cloning Repository`},{step:3,title:`3. Computing File Delta & Scanning`},{step:4,title:`4. Parsing AST Symbols & API Routes`},{step:5,title:`5. Upserting Embeddings & Finalizing`}];function nt({isOpen:e,onClose:t,repoId:n,repoName:r,job:i,onCancelSync:a}){let[o,s]=(0,V.useState)(``),[c,l]=(0,V.useState)(!0),[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)(0),[m,h]=(0,V.useState)(!1),g=(0,V.useRef)(null),_=(0,V.useRef)(null),v=n??i?.repo_id??null,y=r||i?.repo_name||`Repository`;(0,V.useEffect)(()=>{if(!e||!i?.started_at){p(0);return}let t=()=>{let e=i.started_at>1e11?i.started_at:i.started_at*1e3;return Math.max(0,Math.floor((Date.now()-e)/1e3))};if(p(t()),i.status===`syncing`||i.status===`pending`){let e=setInterval(()=>{p(t())},1e3);return()=>clearInterval(e)}},[e,i?.started_at,i?.status]);let b=e=>{let t=Math.floor(e/60),n=e%60;return`${t.toString().padStart(2,`0`)}:${n.toString().padStart(2,`0`)}`},x=i?.logs,S=(0,V.useMemo)(()=>{let e=x||[];if(!o.trim())return e;let t=o.toLowerCase();return e.filter(e=>e.message.toLowerCase().includes(t)||e.level.toLowerCase().includes(t)||e.timestamp.toLowerCase().includes(t))},[x,o]);(0,V.useEffect)(()=>{c&&g.current&&typeof g.current.scrollIntoView==`function`&&g.current.scrollIntoView({behavior:`smooth`})},[S,c]);let C=async()=>{let e=(i?.logs||[]).map(e=>`[${e.timestamp}] [${e.level.toUpperCase()}] ${e.message}`).join(` +`);try{await navigator.clipboard.writeText(e),d(!0),setTimeout(()=>d(!1),2e3)}catch(e){console.error(`Failed to copy logs:`,e)}},w=async()=>{if(!(!v||!a))try{h(!0),await a(v)}catch(e){console.error(`Failed to cancel sync:`,e)}finally{h(!1)}};if(!e)return null;let T=i?.status||`pending`,E=i?.percent??(T===`synced`?100:0),D=i?.step??(T===`synced`?5:1),O=(0,H.jsx)(`div`,{className:`sync-drawer-backdrop`,onClick:e=>{e.target===e.currentTarget&&t()},"data-testid":`sync-drawer-backdrop`,children:(0,H.jsxs)(`div`,{className:`sync-drawer`,children:[(0,H.jsxs)(`div`,{className:`sync-drawer-header`,children:[(0,H.jsxs)(`div`,{className:`sync-drawer-title-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`,flexWrap:`wrap`},children:[(0,H.jsxs)(`h2`,{style:{fontSize:`1.1rem`,margin:0,fontWeight:700,color:`var(--text)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`,style:{marginRight:`8px`,color:`var(--primary)`}}),y,` Ingestion Progress & Live Logs`]}),T===`syncing`?(0,H.jsxs)(`span`,{className:`badge badge-warning`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing`]}):T===`synced`?(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]}):T===`error`?(0,H.jsxs)(`span`,{className:`badge badge-danger`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}):(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]})]}),(0,H.jsxs)(`div`,{className:`sync-drawer-meta`,style:{display:`flex`,alignItems:`center`,gap:`12px`,marginTop:`6px`,fontSize:`0.82rem`,color:`var(--text-muted)`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`i`,{className:`fa-regular fa-clock`,style:{marginRight:`4px`}}),`Elapsed: `,(0,H.jsx)(`strong`,{children:b(f)})]}),i?.step_name&&(0,H.jsxs)(`span`,{children:[`• Current: `,(0,H.jsx)(`strong`,{children:i.step_name})]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[T===`syncing`&&a&&v!=null&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-cancel-sync`,onClick:w,disabled:m,style:{fontSize:`0.8rem`,padding:`6px 12px`,color:`var(--danger)`,borderColor:`rgba(239, 68, 68, 0.4)`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${m?`fa-spinner fa-spin`:`fa-stop`}`}),m?`Cancelling...`:`Cancel Sync`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:t,"aria-label":`Close sync drawer`,style:{fontSize:`1.4rem`,lineHeight:1},children:`×`})]})]}),(0,H.jsxs)(`div`,{className:`sync-drawer-body`,children:[(0,H.jsxs)(`div`,{className:`sync-progress-section`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`span`,{style:{fontWeight:600,color:`var(--text)`},children:`Overall Ingestion`}),(0,H.jsxs)(`span`,{style:{fontWeight:700,color:T===`error`?`var(--danger)`:`var(--primary)`},children:[E,`%`]})]}),(0,H.jsx)(`div`,{className:`sync-progress-bar-container`,children:(0,H.jsx)(`div`,{className:`sync-progress-bar-fill ${T===`error`?`fill-error`:T===`synced`?`fill-success`:`fill-active`}`,style:{width:`${E}%`}})})]}),(0,H.jsxs)(`div`,{className:`sync-stepper-container`,children:[(0,H.jsx)(`h4`,{style:{fontSize:`0.82rem`,textTransform:`uppercase`,letterSpacing:`0.05em`,color:`var(--text-muted)`,marginBottom:`10px`},children:`Ingestion Stages`}),(0,H.jsx)(`div`,{className:`sync-stepper-list`,children:tt.map(e=>{let t=T===`synced`||T!==`error`&&D>e.step||T===`error`&&D>e.step,n=T===`syncing`&&D===e.step,r=T===`error`&&D===e.step;return(0,H.jsxs)(`div`,{className:`sync-stepper-item ${t?`item-completed`:n?`item-active`:r?`item-error`:`item-pending`}`,children:[(0,H.jsxs)(`div`,{className:`sync-stepper-icon`,children:[t&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,style:{color:`#10b981`}}),n&&(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{color:`#f59e0b`}}),r&&(0,H.jsx)(`i`,{className:`fa-solid fa-circle-xmark`,style:{color:`#ef4444`}}),!t&&!n&&!r&&(0,H.jsx)(`i`,{className:`fa-regular fa-circle`,style:{color:`var(--text-muted)`}})]}),(0,H.jsxs)(`div`,{className:`sync-stepper-content`,children:[(0,H.jsx)(`div`,{className:`sync-stepper-title`,style:{fontWeight:n?600:500},children:e.title}),n&&(0,H.jsxs)(`div`,{className:`sync-stepper-details`,children:[i?.current_file&&(0,H.jsxs)(`div`,{className:`sync-current-file`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{marginRight:`4px`}}),(0,H.jsx)(`code`,{children:i.current_file})]}),i?.total_files!=null&&i.total_files>0&&(0,H.jsxs)(`div`,{className:`sync-file-count`,style:{marginTop:`2px`,color:`var(--text-muted)`},children:[i.processed_files,` / `,i.total_files,` files (`,E,`%)`]})]}),r&&i?.error&&(0,H.jsxs)(`div`,{className:`sync-stepper-error-msg`,style:{marginTop:`4px`,color:`var(--danger)`,fontSize:`0.82rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{marginRight:`4px`}}),i.error]})]})]},e.step)})})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-section`,children:[(0,H.jsxs)(`div`,{className:`sync-terminal-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`,style:{color:`var(--accent)`}}),(0,H.jsx)(`span`,{style:{fontSize:`0.85rem`,fontWeight:600,color:`var(--text)`},children:`Live Terminal Output`}),(0,H.jsxs)(`span`,{className:`badge badge-secondary`,style:{fontSize:`0.75rem`,padding:`1px 6px`},children:[S.length,` `,S.length===1?`event`:`events`]})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-actions`,children:[(0,H.jsxs)(`label`,{className:`sync-autoscroll-toggle`,children:[(0,H.jsx)(`input`,{type:`checkbox`,checked:c,onChange:e=>l(e.target.checked),"aria-label":`Autoscroll`}),(0,H.jsx)(`span`,{children:`Autoscroll`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-sm`,onClick:C,"aria-label":`Copy logs`,style:{fontSize:`0.75rem`,padding:`3px 8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${u?`fa-check`:`fa-copy`}`}),` `,u?`Copied!`:`Copy Logs`]})]})]}),(0,H.jsxs)(`div`,{className:`sync-terminal-search`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`,style:{color:`var(--text-muted)`,fontSize:`0.8rem`}}),(0,H.jsx)(`input`,{type:`text`,placeholder:`Filter logs by keyword or level...`,value:o,onChange:e=>s(e.target.value),style:{width:`100%`,background:`transparent`,border:`none`,outline:`none`,color:`var(--text)`,fontSize:`0.82rem`,padding:`4px 0`}}),o&&(0,H.jsx)(`button`,{type:`button`,onClick:()=>s(``),style:{background:`transparent`,border:`none`,color:`var(--text-muted)`,cursor:`pointer`,fontSize:`0.8rem`},children:`×`})]}),(0,H.jsx)(`div`,{className:`sync-terminal-body`,ref:_,children:S.length===0?(0,H.jsxs)(`div`,{className:`sync-terminal-empty`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-clock-rotate-left`,style:{marginBottom:`6px`,fontSize:`1.2rem`,opacity:.5}}),(0,H.jsx)(`div`,{children:(x?.length||0)===0?`Waiting for sync activity...`:`No logs matching filter`})]}):(0,H.jsxs)(`div`,{className:`sync-terminal-lines`,children:[S.map((e,t)=>{let n=(e.level||`INFO`).toUpperCase(),r=`level-info`;return(n===`WARN`||n===`WARNING`)&&(r=`level-warn`),(n===`ERROR`||n===`FATAL`)&&(r=`level-error`),(0,H.jsxs)(`div`,{className:`sync-terminal-line`,children:[(0,H.jsxs)(`span`,{className:`log-time`,children:[`[`,e.timestamp,`]`]}),(0,H.jsx)(`span`,{className:`log-badge ${r}`,children:n}),(0,H.jsx)(`span`,{className:`log-msg`,children:e.message})]},t)}),(0,H.jsx)(`div`,{ref:g})]})})]})]})]})});return typeof document<`u`?(0,Qe.createPortal)(O,document.body):O}function rt(){let[e,t]=(0,V.useState)({}),[n,r]=(0,V.useState)(!1),i=(0,V.useRef)(null),a=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/repos/sync-status`);if(e&&e.ok){let n=await e.json();if(n&&typeof n==`object`&&!Array.isArray(n)){let e={};Object.entries(n).forEach(([t,n])=>{let r=n;r&&(r.repo_id!=null||r.step!=null||r.status!=null)&&(e[Number(t)]=r)}),t(t=>({...t,...e}))}else if(Array.isArray(n)){let e={};n.forEach(t=>{t&&t.repo_id!=null&&(t.step!=null||t.status===`syncing`)&&(e[t.repo_id]=t)}),Object.keys(e).length>0&&t(t=>({...t,...e}))}}}catch(e){console.error(`Failed to fetch initial sync status snapshot:`,e)}},[]);return(0,V.useEffect)(()=>{if(a(),typeof EventSource>`u`)return;let e=null;try{e=new EventSource(`/admin/api/repos/sync/stream`),i.current=e,e.onopen=()=>{r(!0)},e.onerror=()=>{r(!1)},e.addEventListener(`init`,e=>{try{let n=JSON.parse(e.data);if(n&&typeof n==`object`){let e={};Object.entries(n).forEach(([t,n])=>{e[Number(t)]=n}),t(e),r(!0)}}catch(e){console.error(`Failed to parse init sync stream event:`,e)}}),e.addEventListener(`progress`,e=>{try{let n=JSON.parse(e.data),i=n.data||n;i&&i.repo_id!=null&&(t(e=>{let t=e[i.repo_id];return{...e,[i.repo_id]:{...t||{},...i,logs:i.logs??t?.logs??[]}}}),r(!0))}catch(e){console.error(`Failed to parse progress event:`,e)}}),e.addEventListener(`log`,e=>{try{let n=JSON.parse(e.data),r=n.repo_id??n.data?.repo_id,i=n.data&&!n.data.repo_id?n.data:n.log||n.data;r!=null&&i&&t(e=>{let t=e[r];if(!t)return e;let n=t.logs||[];return{...e,[r]:{...t,logs:[...n,i]}}})}catch(e){console.error(`Failed to parse log event:`,e)}})}catch(e){console.error(`Failed to initialize EventSource:`,e),r(!1)}return()=>{e&&(e.close(),i.current=null)}},[a]),{syncStates:e,isConnected:n,cancelSync:(0,V.useCallback)(async e=>{try{let t=await fetch(`/admin/api/repos/${e}/cancel-sync`,{method:`POST`});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||`Failed to cancel sync: ${t.statusText}`)}return await t.json()}catch(t){throw console.error(`Error cancelling sync for repo ${e}:`,t),t}},[])}}function it({refreshStats:e}){let[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!0),[a,o]=(0,V.useState)(!1),[s,c]=(0,V.useState)(null),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(null),p=Je(),m=(0,V.useRef)(null);(0,V.useEffect)(()=>()=>{m.current&&clearTimeout(m.current)},[]);let{syncStates:h,cancelSync:g}=rt(),[_,v]=(0,V.useState)(``),[y,b]=(0,V.useState)(``),[x,S]=(0,V.useState)(`main`),[C,w]=(0,V.useState)(`auto`),[T,E]=(0,V.useState)(``),[D,O]=(0,V.useState)(``),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),N=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/repos`);if(!e.ok){p.error(`Failed to load repositories`);return}let t=await e.json();n(Array.isArray(t)?t:[])}catch(e){p.error(`Error loading repos: `+e.message),console.error(`Error loading repos:`,e)}finally{i(!1)}},[p]);(0,V.useEffect)(()=>{N();let e=setInterval(N,8e3);return()=>clearInterval(e)},[N]);let P=async t=>{t.preventDefault(),M(!0);try{let t=await fetch(`/admin/api/repos`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({name:_.trim(),url:y.trim(),branch:x.trim()||`main`,provider:C===`auto`?void 0:C,auth_user:T.trim()||null,auth_token:D.trim()||null,keep_shallow:k})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add repository`);o(!1),v(``),b(``),S(`main`),w(`auto`),E(``),O(``),A(!1),N(),e(),p.success(`Repository '${_.trim()}' added successfully`)}catch(e){p.error(`Error: ${e.message}`)}finally{M(!1)}},F=async t=>{n(e=>e.map(e=>e.id===t?{...e,status:`syncing`}:e));try{let n=await fetch(`/admin/api/repos/sync/${t}`,{method:`POST`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to trigger sync`)}N(),e(),p.info(`Sync triggered successfully`)}catch(e){N(),p.error(`Failed to trigger sync: `+e.message)}},I=async(e,t)=>{let r=!t;n(t=>t.map(t=>t.id===e?{...t,auto_sync:r}:t));try{let t=await fetch(`/admin/api/repos/${e}/auto-sync`,{method:`PATCH`,headers:{"Content-Type":`application/json`},body:JSON.stringify({auto_sync:r})});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||e.detail||`Failed to update auto-sync`)}p.info(`Auto-sync ${r?`enabled`:`disabled`}`),N()}catch(e){N(),p.error(`Failed to update auto-sync: `+e.message)}},L=async(e,t)=>{let r=!t;n(t=>t.map(t=>t.id===e?{...t,keep_shallow:r}:t));try{let t=await fetch(`/admin/api/repos/${e}/keep-shallow`,{method:`PATCH`,headers:{"Content-Type":`application/json`},body:JSON.stringify({keep_shallow:r})});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||e.detail||`Failed to update shallow copy retention`)}p.info(`Shallow copy retention ${r?`enabled (retained on disk)`:`disabled (ephemeral)`}`),N()}catch(e){N(),p.error(`Failed to update shallow copy setting: `+e.message)}},R=async e=>{try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(e),u(!0),p.info(`Webhook URL copied to clipboard`),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{typeof window<`u`&&u(!1)},2e3)}catch(e){p.error(`Failed to copy: `+e.message)}},z=async(t,r)=>{if(window.confirm(`Are you sure you want to delete repository '${r}'? All vectors and indexed symbols for this repo will be permanently purged.`)){n(e=>e.filter(e=>e.id!==t));try{let n=await fetch(`/admin/api/repos/${t}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete repo`)}N(),e(),p.success(`Repository '${r}' deleted successfully`)}catch(e){N(),p.error(`Failed to delete repo: `+e.message)}}},B=d===null?null:h[d],ee=t.find(e=>e.id===d)?.name||B?.repo_name||``;return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-branch`}),` Registered Git Repositories`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Supports GitHub, GitLab, Gitea, Bitbucket, and custom self-hosted Git repositories over HTTP/HTTPS.`})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>o(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Repository`]})]}),(0,H.jsx)(U,{repos:t,isLoading:r,syncStates:h,onSync:F,onToggleAutoSync:I,onToggleKeepShallow:L,onOpenWebhook:e=>c(e),onDelete:z,onOpenSyncDrawer:e=>f(e)})]}),(0,H.jsx)($e,{isOpen:a,onClose:()=>o(!1),onSave:P,alias:_,setAlias:v,url:y,setUrl:b,branch:x,setBranch:S,provider:C,setProvider:w,authUser:T,setAuthUser:E,token:D,setToken:O,keepShallow:k,setKeepShallow:A,isSaving:j}),(0,H.jsx)(et,{repo:s,onClose:()=>c(null),onCopyUrl:R,copiedUrl:l}),(0,H.jsx)(nt,{isOpen:d!==null,onClose:()=>f(null),repoId:d,repoName:ee,job:B,onCancelSync:g})]})}function at({refreshStats:e}){let[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!0),a=Je(),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(``),[f,p]=(0,V.useState)(`local`),[m,h]=(0,V.useState)(``),[g,_]=(0,V.useState)(`directory`),[v,y]=(0,V.useState)(1),[b,x]=(0,V.useState)(null),S=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/paths`);if(!e.ok){a.error(`Failed to load local paths`);return}let t=await e.json();n(t)}catch(e){a.error(`Error loading paths: `+e.message),console.error(`Error loading paths:`,e)}finally{i(!1)}},[a]);(0,V.useEffect)(()=>{S();let e=setInterval(S,8e3);return()=>clearInterval(e)},[S]);let C=async t=>{t.preventDefault();try{let t=await fetch(`/admin/api/paths`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:u.trim(),repo:f.trim()||`local`,category:m.trim()||null,type:g,recursive:v,enabled:1})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add path`);s(!1),d(``),p(`local`),h(``),_(`directory`),y(1),S(),e(),a.success(`Path added successfully`)}catch(e){a.error(`Error: ${e.message}`)}},w=async t=>{if(window.confirm(`Are you sure you want to delete this local search path?`)){n(e=>e.filter(e=>e.id!==t));try{let n=await fetch(`/admin/api/paths/${t}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete path`)}a.success(`Path deleted successfully`),S(),e()}catch(e){S(),a.error(`Failed to delete path: `+e.message)}}},T=(e=`/`)=>{l(!0),E(e)},E=async e=>{try{let t=await fetch(`/admin/api/browse?path=${encodeURIComponent(e)}`),n=await t.json();if(!t.ok){a.error(n.error||`Failed to browse directory`);return}x(n)}catch(e){a.error(`Browse error: `+e.message),console.error(`Browse error:`,e)}};return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Monitored Local Paths`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Mounted documentation vaults and local workspaces scanned for changes.`})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>s(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Local Path`]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Type`}),(0,H.jsx)(`th`,{children:`Recursive`}),(0,H.jsx)(`th`,{children:`Category`}),(0,H.jsx)(`th`,{children:`Enabled`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:r&&t.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsxs)(`td`,{colSpan:7,className:`empty-state`,"data-testid":`path-loading-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading local paths...`]})}):t.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:7,className:`empty-state`,children:`No local search paths configured.`})}):t.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo||`local`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.type})}),(0,H.jsx)(`td`,{children:e.recursive?`Yes`:`No`}),(0,H.jsx)(`td`,{children:e.category?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:e.enabled?(0,H.jsx)(`span`,{className:`badge badge-success`,children:`Enabled`}):(0,H.jsx)(`span`,{className:`badge badge-danger`,children:`Disabled`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>w(e.id),title:`Delete Path`,"aria-label":`Delete Path`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:r&&t.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,"data-testid":`path-loading-state-mobile`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`,color:`var(--primary)`}}),`Loading local paths...`]}):t.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No local search paths configured.`}):t.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,minWidth:0},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{color:`var(--accent)`}}),(0,H.jsx)(`strong`,{style:{fontSize:`1rem`},children:e.repo||`local`})]}),e.enabled?(0,H.jsx)(`span`,{className:`badge badge-success`,children:`Enabled`}):(0,H.jsx)(`span`,{className:`badge badge-danger`,children:`Disabled`})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.path})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,flexWrap:`wrap`,alignItems:`center`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Type: `}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.type})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Recursive: `}),(0,H.jsx)(`span`,{children:e.recursive?`Yes`:`No`})]})]}),e.category&&(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Category: `}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category})]})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>w(e.id),title:`Delete Path`,"aria-label":`Delete Path`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})})]},`card-${e.id}`))})]}),o&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Add Monitored Local Path`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>s(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:C,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Selected Directory / File`}),(0,H.jsxs)(`div`,{className:`path-input-row`,children:[(0,H.jsx)(`input`,{type:`text`,readOnly:!0,required:!0,placeholder:`Browse workspace directories...`,value:u}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>T(b?.current_path||`/`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Browse`]})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-repo-alias`,children:`Repo / Vault Alias`}),(0,H.jsx)(`input`,{type:`text`,id:`path-repo-alias`,placeholder:`local`,value:f,onChange:e=>p(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-category`,children:`Category Override`}),(0,H.jsx)(`input`,{type:`text`,id:`path-category`,placeholder:`Optional category`,value:m,onChange:e=>h(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-type`,children:`Path Type`}),(0,H.jsxs)(`select`,{id:`path-type`,value:g,onChange:e=>_(e.target.value),children:[(0,H.jsx)(`option`,{value:`directory`,children:`Directory`}),(0,H.jsx)(`option`,{value:`file`,children:`Single File`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`path-recursive`,children:`Scan Subfolders`}),(0,H.jsxs)(`select`,{id:`path-recursive`,value:v,onChange:e=>y(parseInt(e.target.value)),children:[(0,H.jsx)(`option`,{value:1,children:`Yes (Recursive)`}),(0,H.jsx)(`option`,{value:0,children:`No (Top-level only)`})]})]})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>s(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,children:`Save Path`})]})]})]})}),c&&b&&(0,H.jsx)(`div`,{className:`modal-backdrop`,style:{zIndex:1100},children:(0,H.jsxs)(`div`,{className:`glass-card modal-card browser-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-search`}),` Browse Workspace Files`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>l(!1),children:`×`})]}),(0,H.jsxs)(`div`,{className:`browser-body`,children:[(0,H.jsxs)(`div`,{className:`browser-breadcrumbs`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Current: `}),(0,H.jsx)(`span`,{className:`code`,style:{wordBreak:`break-all`},children:b.current_path})]}),(0,H.jsx)(`div`,{className:`browser-list-container`,children:(0,H.jsxs)(`ul`,{className:`browser-list`,children:[b.parent_path&&(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>E(b.parent_path),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-level-up-alt`,style:{color:`var(--accent)`}}),` `,(0,H.jsx)(`span`,{children:`.. (Parent Directory)`})]}),b.directories.map(e=>(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>E(e.path),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`}}),` `,(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.name})]},e.path)),b.files.map(e=>(0,H.jsxs)(`li`,{className:`browser-item`,onClick:()=>{d(e.path),_(`file`),l(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{color:`var(--text-muted)`}}),` `,(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.name})]},e.path))]})})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>l(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-primary`,onClick:()=>{b&&(d(b.current_path),_(`directory`),l(!1))},children:`Select Current Folder`})]})]})})]})}function ot({data:e,onConfirm:t,onCancel:n,isIngesting:r=!1}){let[i,a]=(0,V.useState)(`pages`),[o,s]=(0,V.useState)(0),c=e.total_pages||e.pages.length||1,l=e.pages[o]||{page_number:1,text:``,char_count:0,ocr_applied:!1};return(0,H.jsx)(`div`,{className:`modal-backdrop`,"data-testid":`pdf-preview-modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`850px`,width:`95%`,maxHeight:`90vh`,display:`flex`,flexDirection:`column`},"data-testid":`pdf-preview-modal`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,style:{marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,margin:0,fontSize:`1.25rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`}}),(0,H.jsx)(`span`,{children:`PDF Extraction Preview`})]}),(0,H.jsx)(`div`,{style:{fontSize:`0.85rem`,color:`var(--text-muted)`,marginTop:`4px`},children:(0,H.jsx)(`code`,{children:e.filename})})]}),(0,H.jsx)(`button`,{type:`button`,className:`btn-close`,onClick:n,"aria-label":`Close modal`,children:`×`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`10px`,padding:`10px 14px`,background:`rgba(255, 255, 255, 0.04)`,borderRadius:`6px`,marginBottom:`14px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`14px`,flexWrap:`wrap`,alignItems:`center`,fontSize:`0.85rem`},children:[(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`Total Pages:`}),` `,(0,H.jsx)(`span`,{className:`badge badge-primary`,"data-testid":`total-pages-badge`,children:e.total_pages})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`Total Characters:`}),` `,(0,H.jsx)(`span`,{className:`badge badge-primary`,"data-testid":`total-chars-badge`,children:e.total_characters.toLocaleString()})]}),(0,H.jsxs)(`span`,{children:[(0,H.jsx)(`strong`,{children:`OCR Applied:`}),` `,(0,H.jsxs)(`span`,{className:`badge ${e.ocr_pages_count>0?`badge-warning`:`badge-secondary`}`,"data-testid":`ocr-count-badge`,children:[e.ocr_pages_count,` `,e.ocr_pages_count===1?`page`:`pages`]})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},children:[(0,H.jsxs)(`button`,{type:`button`,className:`btn ${i===`pages`?`btn-primary`:`btn-secondary`}`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:()=>a(`pages`),"data-testid":`tab-pages-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{marginRight:`5px`}}),` Page Text`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn ${i===`chunks`?`btn-primary`:`btn-secondary`}`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:()=>a(`chunks`),"data-testid":`tab-chunks-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group`,style:{marginRight:`5px`}}),` Sample Chunks (`,e.sample_chunks?.length||0,`)`]})]})]}),(0,H.jsx)(`div`,{style:{flex:1,overflowY:`auto`,minHeight:`320px`,display:`flex`,flexDirection:`column`},children:i===`pages`?(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,height:`100%`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`8px`,marginBottom:`10px`,padding:`6px 10px`,background:`rgba(0, 0, 0, 0.2)`,borderRadius:`6px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>{o>0&&s(e=>e-1)},disabled:o<=0,"aria-label":`Previous Page`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-chevron-left`}),` Prev`]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`span`,{children:`Page`}),(0,H.jsx)(`select`,{value:o,onChange:t=>{let n=parseInt(t.target.value,10);!isNaN(n)&&n>=0&&n(0,H.jsxs)(`option`,{value:t,children:[e.page_number,` `,e.ocr_applied?`(OCR)`:``]},e.page_number))}),(0,H.jsxs)(`span`,{children:[`of `,c]})]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>{oe+1)},disabled:o>=e.pages.length-1,"aria-label":`Next Page`,children:[`Next `,(0,H.jsx)(`i`,{className:`fa-solid fa-chevron-right`})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[l.ocr_applied?(0,H.jsxs)(`span`,{className:`badge badge-warning`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`},"data-testid":`page-ocr-applied-badge`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-eye`}),` OCR Fallback`]}):(0,H.jsxs)(`span`,{className:`badge badge-secondary`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`},"data-testid":`page-digital-badge`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-font`}),` Digital`]}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[l.char_count.toLocaleString(),` chars`]})]})]}),(0,H.jsx)(`div`,{style:{flex:1,minHeight:`260px`,position:`relative`},children:l.text?(0,H.jsx)(`pre`,{className:`search-hit-code`,style:{maxHeight:`400px`,overflowY:`auto`,margin:0,whiteSpace:`pre-wrap`,wordBreak:`break-word`,fontSize:`0.85rem`,lineHeight:`1.5`,padding:`12px`,background:`rgba(0, 0, 0, 0.3)`,borderRadius:`6px`},"data-testid":`page-text-content`,children:l.text}):(0,H.jsxs)(`div`,{className:`empty-state`,style:{padding:`30px`,textAlign:`center`,color:`var(--text-muted)`},"data-testid":`page-empty-text`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-circle-question`,style:{fontSize:`1.5rem`,marginBottom:`8px`,display:`block`}}),`No text extracted from Page `,l.page_number,`.`]})})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`10px`},"data-testid":`chunks-container`,children:[(0,H.jsx)(`div`,{style:{fontSize:`0.82rem`,color:`var(--text-muted)`,marginBottom:`4px`},children:`Simulated chunking for vector ingestion (approx. 1000 chars / chunk with 200 char overlap):`}),!e.sample_chunks||e.sample_chunks.length===0?(0,H.jsx)(`div`,{className:`empty-state`,style:{padding:`24px`},children:`No vector chunks generated for this document.`}):e.sample_chunks.map(e=>(0,H.jsxs)(`div`,{style:{border:`1px solid var(--border-card)`,borderRadius:`6px`,background:`rgba(0, 0, 0, 0.25)`,padding:`10px 12px`},"data-testid":`chunk-card-${e.chunk_index}`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,fontSize:`0.8rem`,marginBottom:`6px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,alignItems:`center`},children:[(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[`Chunk #`,e.chunk_index+1]}),(0,H.jsxs)(`span`,{className:`text-muted`,children:[e.heading,` (Page `,e.page_number,`)`]})]}),(0,H.jsxs)(`span`,{className:`badge badge-secondary`,children:[e.char_count,` chars`]})]}),(0,H.jsx)(`pre`,{style:{margin:0,whiteSpace:`pre-wrap`,wordBreak:`break-word`,fontFamily:`var(--font-family-mono)`,fontSize:`0.8rem`,color:`var(--text)`,lineHeight:`1.4`,background:`rgba(0, 0, 0, 0.2)`,padding:`8px`,borderRadius:`4px`},children:e.preview})]},e.chunk_index))]})}),(0,H.jsxs)(`div`,{className:`modal-footer`,style:{marginTop:`16px`,paddingTop:`12px`,borderTop:`1px solid var(--border-card)`,display:`flex`,justifyContent:`flex-end`,gap:`10px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:n,disabled:r,children:`Cancel`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-primary`,onClick:t,disabled:r,"data-testid":`confirm-ingest-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-spinner fa-spin`:`fa-database`}`,style:{marginRight:`6px`}}),r?`Ingesting...`:`Confirm & Ingest to Vector DB`]})]})]})})}function st({refreshStats:e}){let t=Je(),[n,r]=(0,V.useState)(null),[i,a]=(0,V.useState)(``),[o,s]=(0,V.useState)(!1),[c,l]=(0,V.useState)(!1),[u,d]=(0,V.useState)(``),[f,p]=(0,V.useState)(``),[m,h]=(0,V.useState)(`local_storage`),[g,_]=(0,V.useState)(``),[v,y]=(0,V.useState)(null),[b,x]=(0,V.useState)(!1),[S,C]=(0,V.useState)(!1),[w,T]=(0,V.useState)(!1),[E,D]=(0,V.useState)(null),[O,k]=(0,V.useState)(!1),[A,j]=(0,V.useState)(!1),[M,N]=(0,V.useState)(null),[P,F]=(0,V.useState)(``),[I,L]=(0,V.useState)(``),[R,z]=(0,V.useState)(!1),[B,ee]=(0,V.useState)(!1),[te,ne]=(0,V.useState)(!1),[re,ie]=(0,V.useState)(null),[ae,oe]=(0,V.useState)(null),[se,ce]=(0,V.useState)(``),[le,ue]=(0,V.useState)(`local_storage`),[de,fe]=(0,V.useState)(``),[pe,me]=(0,V.useState)(!1),he=e=>{if(!e||e===0)return`0 B`;let t=1024,n=[`B`,`KB`,`MB`,`GB`],r=Math.floor(Math.log(e)/Math.log(t));return parseFloat((e/t**r).toFixed(1))+` `+n[r]},ge=e=>{if(!e)return`-`;let t=e<1e11?e*1e3:e;return new Date(t).toLocaleString()},_e=(0,V.useCallback)(async(e=i)=>{s(!0);try{let t=e?`/admin/api/storage/tree?folder=${encodeURIComponent(e)}`:`/admin/api/storage/tree`,n=await fetch(t);if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to load storage tree`)}let i=await n.json();r(i),a(i.current_folder||``)}catch(e){t.error(`Error loading storage: `+e.message),console.error(`Error loading storage tree:`,e)}finally{s(!1)}},[i,t]);(0,V.useEffect)(()=>{_e(``)},[]);let ve=e=>{_e(e)},ye=()=>{if(!i)return;let e=i.split(`/`).filter(Boolean);e.pop(),ve(e.join(`/`))},be=e=>{let t=e===void 0?i:e;d(t?`${t}/`:``),p(``),h(`local_storage`),_(``),y(null),l(!0)},xe=e=>{if(e.preventDefault(),x(!1),e.dataTransfer.files&&e.dataTransfer.files.length>0){let t=e.dataTransfer.files[0];Ee(t)}},Se=e=>{e.target.files&&e.target.files.length>0&&Ee(e.target.files[0])},Ce=async(e,n,r,a)=>{ne(!0);try{let t=new FormData;t.append(`file`,e),t.append(`ocr_fallback`,`true`);let o=await fetch(`/admin/api/storage/pdf/preview`,{method:`POST`,body:t}),s=await o.json();if(!o.ok)throw Error(s.error||`Failed to generate PDF preview`);oe(e),ce(n||(i?`${i}/${e.name}`:e.name)),ue(r||m||`local_storage`),fe(a||f||``),ie(s),l(!1),ee(!0)}catch(e){t.error(`PDF preview error: ${e.message}`)}finally{ne(!1)}},we=async()=>{if(ae){me(!0);try{let n=new FormData;n.append(`file`,ae),n.append(`path`,se||ae.name),n.append(`repo`,le||`local_storage`),de&&n.append(`category`,de);let r=await fetch(`/admin/api/storage/upload`,{method:`POST`,body:n}),a=await r.json();if(!r.ok)throw Error(a.error||`Failed to ingest PDF`);ee(!1),oe(null),ie(null);let o=a.chunks_indexed??0;t.success(`PDF uploaded and indexed (${o} chunks)`),_e(i),e&&e()}catch(e){t.error(`PDF ingestion error: ${e.message}`)}finally{me(!1)}}},Te=()=>{ee(!1),oe(null),ie(null)},Ee=e=>{y(e);let t=i?`${i}/${e.name}`:e.name;if(d(t),e.name.toLowerCase().endsWith(`.pdf`)||e.type===`application/pdf`){_(``),Ce(e,t,m,f);return}let n=new FileReader;n.onload=e=>{typeof e.target?.result==`string`&&_(e.target.result)},n.readAsText(e)},De=async n=>{if(n.preventDefault(),!u.trim()){t.error(`File path is required`);return}if(v&&v.name.toLowerCase().endsWith(`.pdf`)){await Ce(v,u.trim(),m.trim(),f.trim());return}C(!0);try{let n;if(v&&!g){let e=new FormData;e.append(`file`,v),e.append(`path`,u.trim()),e.append(`repo`,m.trim()||`local_storage`),f.trim()&&e.append(`category`,f.trim()),n=await fetch(`/admin/api/storage/upload`,{method:`POST`,body:e})}else n=await fetch(`/admin/api/storage/upload`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:u.trim(),content:g,repo:m.trim()||`local_storage`,category:f.trim()||null})});let r=await n.json();if(!n.ok)throw Error(r.error||`Failed to upload file`);l(!1);let a=r.chunks_indexed??0;t.success(`File uploaded and indexed (${a} chunks)`),_e(i),e&&e()}catch(e){t.error(`Upload error: ${e.message}`)}finally{C(!1)}},Oe=async e=>{k(!0),T(!0);try{let t=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(e.rel_path)}`),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to read file`);D(n)}catch(e){t.error(`Preview error: ${e.message}`),T(!1)}finally{k(!1)}},ke=async e=>{if(N(e),L(``),j(!0),e.rel_path.toLowerCase().endsWith(`.pdf`)){F(``);return}try{let t=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(e.rel_path)}`),n=await t.json();t.ok&&n.content!==void 0?F(n.content):F(``)}catch{F(``)}},Ae=async n=>{if(n.preventDefault(),M){if(M.rel_path.toLowerCase().endsWith(`.pdf`)){t.error(`PDF files cannot be edited directly via text editor. Upload a new PDF file instead.`);return}z(!0);try{let n=await fetch(`/admin/api/storage/file`,{method:`PUT`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:M.rel_path,content:P,repo:`local_storage`,category:I.trim()||``})}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to update file`);j(!1);let a=r.chunks_indexed??0;t.success(`File updated and indexed (${a} chunks)`),_e(i),e&&e()}catch(e){t.error(`Replace error: ${e.message}`)}finally{z(!1)}}},je=async n=>{if(window.confirm(`Are you sure you want to delete '${n.name}' from local storage and purge its vector embeddings?`))try{let r=await fetch(`/admin/api/storage/file?path=${encodeURIComponent(n.rel_path)}`,{method:`DELETE`}),a=await r.json();if(!r.ok)throw Error(a.error||`Failed to delete file`);t.success(`File deleted successfully: ${n.name}`),_e(i),e&&e()}catch(e){t.error(`Delete error: ${e.message}`)}},Me=i?i.split(`/`).filter(Boolean):[];return(0,H.jsxs)(`div`,{className:`tab-content active`,children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),` Local Storage Explorer`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Upload, browse, inspect, replace, and delete managed documents in ContextCortex local storage with real-time vector indexing.`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`10px`},children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>_e(i),title:`Refresh directory`,disabled:o,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate ${o?`fa-spin`:``}`}),` Refresh`]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>be(),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-upload`}),` Upload File`]})]})]}),(0,H.jsxs)(`div`,{className:`browser-breadcrumbs`,style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,flexWrap:`wrap`,gap:`10px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,flexWrap:`wrap`},children:[(0,H.jsx)(`span`,{className:`label`,style:{fontWeight:600},children:`Location:`}),(0,H.jsxs)(`button`,{className:`btn-icon`,style:{padding:`2px 6px`,fontSize:`0.85rem`,color:i===``?`var(--primary)`:`var(--text)`},onClick:()=>ve(``),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-house`}),` root`]}),Me.map((e,t)=>{let n=Me.slice(0,t+1).join(`/`),r=t===Me.length-1;return(0,H.jsxs)(`span`,{style:{display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`/`}),(0,H.jsx)(`button`,{className:`btn-icon`,style:{padding:`2px 6px`,fontSize:`0.85rem`,fontWeight:r?`bold`:`normal`,color:r?`var(--primary)`:`var(--text)`},onClick:()=>ve(n),children:e})]},n)})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,fontSize:`0.8rem`,color:`var(--text-muted)`},children:[(0,H.jsxs)(`span`,{children:[`Directories: `,(0,H.jsx)(`strong`,{children:n?.directories.length||0})]}),(0,H.jsx)(`span`,{children:`•`}),(0,H.jsxs)(`span`,{children:[`Files: `,(0,H.jsx)(`strong`,{children:n?.files.length||0})]})]})]}),i!==``&&(0,H.jsx)(`div`,{style:{marginTop:`8px`,marginBottom:`8px`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.82rem`},onClick:ye,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-level-up-alt`}),` .. (Parent Directory)`]})}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{style:{width:`40%`},children:`Name`}),(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Size`}),(0,H.jsx)(`th`,{children:`Modified`}),(0,H.jsx)(`th`,{style:{textAlign:`right`},children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:!n||n.directories.length===0&&n.files.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:5,className:`empty-state`,children:`No files or subdirectories found in this storage directory. Click "Upload File" to add documents.`})}):(0,H.jsxs)(H.Fragment,{children:[n.directories.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsxs)(`button`,{className:`btn-icon`,style:{display:`inline-flex`,alignItems:`center`,gap:`8px`,textAlign:`left`,color:`var(--text)`},onClick:()=>ve(e.rel_path),"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`,fontSize:`1.05rem`}}),(0,H.jsx)(`strong`,{children:e.name})]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.rel_path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{style:{textAlign:`right`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`3px 8px`,fontSize:`0.8rem`},onClick:()=>ve(e.rel_path),title:`Open ${e.name}`,"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Open`]})})]},e.rel_path)),n.files.map(e=>{let t=e.name.toLowerCase().endsWith(`.pdf`);return(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[t?(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`,fontSize:`1.05rem`}}):(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{color:`var(--primary)`,fontSize:`1.05rem`}}),(0,H.jsx)(`span`,{children:e.name})]})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.rel_path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:he(e.size_bytes)})}),(0,H.jsx)(`td`,{style:{fontSize:`0.85rem`},children:ge(e.mtime)}),(0,H.jsx)(`td`,{style:{textAlign:`right`},children:(0,H.jsxs)(`div`,{style:{display:`inline-flex`,gap:`6px`},children:[(0,H.jsx)(`button`,{className:`btn-icon`,onClick:()=>Oe(e),title:`Preview File`,"aria-label":`Preview File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-eye`})}),(0,H.jsx)(`button`,{className:`btn-icon`,onClick:()=>ke(e),title:`Replace File`,"aria-label":`Replace File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`})}),(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>je(e),title:`Delete File`,"aria-label":`Delete File`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})]})})]},e.rel_path)})]})})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:!n||n.directories.length===0&&n.files.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No files or subdirectories found.`}):(0,H.jsxs)(H.Fragment,{children:[n.directories.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`}}),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`span`,{className:`badge badge-warning`,children:`Directory`})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-body`,children:(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.rel_path})]})}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>ve(e.rel_path),"aria-label":`open ${e.name}`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Open Folder`]})})]},`m-${e.rel_path}`)),n.files.map(e=>{let t=e.name.toLowerCase().endsWith(`.pdf`);return(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`},children:[t?(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf text-red-500 mr-2`,style:{color:`#ef4444`}}):(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`,style:{color:`var(--primary)`}}),(0,H.jsx)(`strong`,{children:e.name})]}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:he(e.size_bytes)})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.rel_path})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Modified: `}),(0,H.jsx)(`span`,{children:ge(e.mtime)})]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-actions`,children:[(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>Oe(e),title:`Preview File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-eye`}),` Preview`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>ke(e),title:`Replace File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`}),` Replace`]}),(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>je(e),title:`Delete File`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})]})]},`m-${e.rel_path}`)})]})})]}),c&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`640px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-cloud-arrow-up`}),` Upload to Local Storage`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>l(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:De,children:[(0,H.jsxs)(`div`,{style:{border:b?`2px dashed var(--primary)`:`2px dashed rgba(255, 255, 255, 0.15)`,borderRadius:`8px`,padding:`20px`,textAlign:`center`,background:b?`rgba(59, 130, 246, 0.08)`:`rgba(0, 0, 0, 0.15)`,marginBottom:`16px`,cursor:`pointer`,transition:`all 0.2s ease`},onDragOver:e=>{e.preventDefault(),x(!0)},onDragLeave:()=>x(!1),onDrop:xe,onClick:()=>document.getElementById(`storage-file-input`)?.click(),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-arrow-up`,style:{fontSize:`2rem`,color:`var(--primary)`,marginBottom:`8px`}}),(0,H.jsx)(`p`,{style:{margin:`4px 0`,fontSize:`0.9rem`},children:v?`Selected: ${v.name} (${he(v.size)})`:`Drag & drop a file here, or click to browse`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`},children:`Supports Markdown, code, JSON, YAML, plain text, PDF (up to 50MB)`}),te&&(0,H.jsxs)(`div`,{style:{marginTop:`8px`,fontSize:`0.85rem`,color:`var(--primary)`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`6px`}}),`Extracting and analyzing PDF preview...`]}),(0,H.jsx)(`input`,{id:`storage-file-input`,type:`file`,accept:`.md,.markdown,.txt,.json,.yaml,.yml,.sql,.html,.css,.pdf`,style:{display:`none`},onChange:Se})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:2},children:[(0,H.jsx)(`label`,{htmlFor:`upload-path`,children:`Relative File Path (e.g. docs/guide.md)`}),(0,H.jsx)(`input`,{id:`upload-path`,type:`text`,required:!0,placeholder:`folder/document.md`,value:u,onChange:e=>d(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsx)(`label`,{htmlFor:`upload-category`,children:`Category Override`}),(0,H.jsx)(`input`,{id:`upload-category`,type:`text`,placeholder:`Optional category`,value:f,onChange:e=>p(e.target.value)})]})]}),v?.name.toLowerCase().endsWith(`.pdf`)||v?.type===`application/pdf`||u.trim().toLowerCase().endsWith(`.pdf`)?(0,H.jsxs)(`div`,{className:`alert alert-info`,style:{margin:`12px 0`,padding:`12px`,background:`rgba(59, 130, 246, 0.1)`,border:`1px solid var(--primary)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pdf`,style:{color:`#ef4444`,marginRight:`8px`}}),(0,H.jsx)(`strong`,{children:`PDF Document Selected:`}),` Binary PDF content cannot be edited manually as text. Extracted text, page segmentation, and vector chunks will be previewed in the extraction modal before ingestion.`]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`upload-content`,children:`File Content (Optional if file uploaded directly)`}),(0,H.jsx)(`textarea`,{id:`upload-content`,rows:8,placeholder:`# Enter or paste text content here...`,value:g,onChange:e=>_(e.target.value),style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`}})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>l(!1),children:`Cancel`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:S,children:[(0,H.jsx)(`i`,{className:`fa-solid ${S?`fa-spinner fa-spin`:`fa-upload`}`}),` Upload & Index`]})]})]})]})}),w&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`750px`,maxHeight:`90vh`,display:`flex`,flexDirection:`column`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`}),` File Preview: `,E?.rel_path||`Loading...`]}),E&&(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[`Size: `,he(E.size_bytes),` • Modified: `,ge(E.mtime)]})]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>T(!1),children:`×`})]}),(0,H.jsx)(`div`,{style:{flex:1,overflowY:`auto`,margin:`10px 0`},children:O?(0,H.jsxs)(`div`,{className:`empty-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Loading content...`]}):(0,H.jsx)(`pre`,{className:`search-hit-code`,style:{maxHeight:`420px`,overflowY:`auto`,margin:0,whiteSpace:`pre-wrap`},children:E?.content||`Empty file.`})}),(0,H.jsx)(`div`,{className:`modal-footer`,children:(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>T(!1),children:`Close`})})]})}),A&&M&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,style:{maxWidth:`680px`},children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-pen`}),` Replace File: `,M.name]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>j(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:Ae,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Target File Path`}),(0,H.jsx)(`input`,{type:`text`,readOnly:!0,value:M.rel_path})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`replace-category`,children:`Category Override`}),(0,H.jsx)(`input`,{id:`replace-category`,type:`text`,placeholder:`Optional category`,value:I,onChange:e=>L(e.target.value)})]}),M.rel_path.toLowerCase().endsWith(`.pdf`)?(0,H.jsxs)(`div`,{className:`alert alert-warning`,style:{margin:`14px 0`,padding:`12px`,background:`rgba(245, 158, 11, 0.1)`,border:`1px solid rgba(245, 158, 11, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{marginRight:`8px`,color:`#f59e0b`}}),(0,H.jsx)(`strong`,{children:`PDF Replacement:`}),` PDF documents contain binary page streams and cannot be edited as plain text. To replace this document, please upload a new `,(0,H.jsx)(`code`,{children:`.pdf`}),` file using the "Upload File" tool.`]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`replace-content`,children:`File Content`}),(0,H.jsx)(`textarea`,{id:`replace-content`,rows:10,required:!0,placeholder:`Updated file text...`,value:P,onChange:e=>F(e.target.value),style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`}})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>j(!1),children:`Cancel`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:R||M.rel_path.toLowerCase().endsWith(`.pdf`),children:[(0,H.jsx)(`i`,{className:`fa-solid ${R?`fa-spinner fa-spin`:`fa-save`}`}),` Save & Re-Index`]})]})]})]})}),B&&re&&(0,H.jsx)(ot,{data:re,onConfirm:we,onCancel:Te,isIngesting:pe})]})}function ct({refreshStats:e}){let[t,n]=(0,V.useState)(`local-paths`);return(0,H.jsxs)(`div`,{className:`files-storage-page`,children:[(0,H.jsxs)(`div`,{className:`files-storage-header`,children:[(0,H.jsxs)(`h2`,{className:`page-title`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{marginRight:`10px`}}),`Files & Storage`]}),(0,H.jsxs)(`div`,{className:`files-storage-section-tabs`,children:[(0,H.jsxs)(`button`,{className:`section-tab ${t===`local-paths`?`active`:``}`,onClick:()=>n(`local-paths`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),(0,H.jsx)(`span`,{children:`Local Paths`})]}),(0,H.jsxs)(`button`,{className:`section-tab ${t===`local-storage`?`active`:``}`,onClick:()=>n(`local-storage`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),(0,H.jsx)(`span`,{children:`Local Storage`})]})]})]}),(0,H.jsxs)(`div`,{className:`files-storage-content`,children:[t===`local-paths`&&(0,H.jsx)(at,{refreshStats:e}),t===`local-storage`&&(0,H.jsx)(st,{refreshStats:e})]})]})}function lt(e){switch(e.toUpperCase()){case`GET`:return`method-get`;case`POST`:return`method-post`;case`PUT`:return`method-put`;case`DELETE`:return`method-delete`;case`PATCH`:return`method-patch`;default:return`method-other`}}function ut(e){switch(e.toLowerCase()){case`class`:return`kind-class`;case`function`:case`method`:case`async function`:return`kind-function`;case`variable`:case`constant`:return`kind-variable`;case`interface`:case`type`:return`kind-type`;default:return`kind-default`}}var dt=({outline:e,selectedSymbolId:t,onSelectSymbol:n,onReadDoc:r,density:i=`balanced`,loading:a=!1})=>{let[o,s]=(0,V.useState)(`all`),[c,l]=(0,V.useState)(``),u=(0,V.useMemo)(()=>e?.symbols||[],[e?.symbols]),d=(0,V.useMemo)(()=>{let e=0,t=0,n=0;for(let r of u){r.route&&e++;let i=r.kind.toLowerCase();i===`class`||i===`interface`?t++:(i.includes(`func`)||i===`method`)&&(r.route||n++)}return{all:u.length,routes:e,classes:t,functions:n}},[u]),f=(0,V.useMemo)(()=>u.filter(e=>{if(o===`routes`){if(!e.route)return!1}else if(o===`classes`){let t=e.kind.toLowerCase();if(t!==`class`&&t!==`interface`)return!1}else if(o===`functions`){let t=e.kind.toLowerCase();if(!t.includes(`func`)&&t!==`method`||e.route)return!1}if(c.trim()){let t=c.toLowerCase(),n=e.name.toLowerCase().includes(t),r=(e.signature||``).toLowerCase().includes(t),i=e.route?e.route.path_pattern.toLowerCase().includes(t)||e.route.http_method.toLowerCase().includes(t):!1;if(!n&&!r&&!i)return!1}return!0}),[u,o,c]),p=e?.filepath?e.filepath.split(`/`).pop():``;return(0,H.jsxs)(`div`,{className:`nav-outline-pane density-${i}`,"data-testid":`navigator-outline-container`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-header`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-title-row`,children:[(0,H.jsxs)(`div`,{className:`nav-outline-title`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`8`,y1:`6`,x2:`21`,y2:`6`}),(0,H.jsx)(`line`,{x1:`8`,y1:`12`,x2:`21`,y2:`12`}),(0,H.jsx)(`line`,{x1:`8`,y1:`18`,x2:`21`,y2:`18`}),(0,H.jsx)(`line`,{x1:`3`,y1:`6`,x2:`3.01`,y2:`6`}),(0,H.jsx)(`line`,{x1:`3`,y1:`12`,x2:`3.01`,y2:`12`}),(0,H.jsx)(`line`,{x1:`3`,y1:`18`,x2:`3.01`,y2:`18`})]}),(0,H.jsx)(`span`,{children:`Symbols & Routes`})]}),e&&(0,H.jsx)(`div`,{className:`nav-file-badge`,title:e.filepath,children:(0,H.jsx)(`span`,{className:`file-name`,children:p})})]}),e&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`nav-outline-search-bar`,children:[(0,H.jsx)(`span`,{className:`search-icon-wrapper`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{className:`search-icon`,width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]})}),(0,H.jsx)(`input`,{type:`text`,className:`nav-outline-search-input`,placeholder:`Filter symbols...`,value:c,onChange:e=>l(e.target.value)}),c&&(0,H.jsx)(`button`,{type:`button`,className:`nav-outline-clear-btn`,onClick:()=>l(``),"aria-label":`Clear symbol search`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-category-chips`,role:`tablist`,"aria-label":`Symbol Category Filter`,children:[(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`all`?`active`:``}`,onClick:()=>s(`all`),children:[`All `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.all})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`routes`?`active`:``}`,onClick:()=>s(`routes`),children:[`Routes `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.routes})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`classes`?`active`:``}`,onClick:()=>s(`classes`),children:[`Classes `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.classes})]}),(0,H.jsxs)(`button`,{type:`button`,role:`button`,className:`category-chip ${o===`functions`?`active`:``}`,onClick:()=>s(`functions`),children:[`Functions `,(0,H.jsx)(`span`,{className:`chip-count`,children:d.functions})]})]})]})]}),(0,H.jsx)(`div`,{className:`nav-outline-content`,children:a?(0,H.jsxs)(`div`,{className:`nav-outline-skeleton`,"data-testid":`outline-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-item shimmer`})]}):e?u.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state doc-file-state`,"data-testid":`outline-doc-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsxs)(`svg`,{width:`28`,height:`28`,viewBox:`0 0 24 24`,fill:`none`,stroke:`var(--primary)`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`}),(0,H.jsx)(`polyline`,{points:`10 9 9 9 8 9`})]})}),(0,H.jsx)(`h4`,{children:`Document File Active`}),(0,H.jsx)(`p`,{style:{fontSize:`0.82rem`,color:`var(--text-muted)`,margin:`6px 0 14px`},children:`Full document is loaded in the main viewer.`}),r&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-sm btn-primary read-doc-action-btn`,onClick:r,style:{padding:`6px 14px`,fontSize:`0.8rem`,display:`inline-flex`,alignItems:`center`,gap:`6px`},children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z`}),(0,H.jsx)(`path`,{d:`M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z`})]}),(0,H.jsx)(`span`,{children:`Read Full Document`})]})]}):f.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`h4`,{children:`No Matching Symbols`}),(0,H.jsx)(`p`,{children:`No symbols match the current category and search filters.`}),(0,H.jsx)(`button`,{type:`button`,className:`nav-clear-filter-btn`,onClick:()=>{s(`all`),l(``)},children:`Reset Filters`})]}):(0,H.jsx)(`div`,{className:`nav-symbol-list`,role:`list`,children:f.map(e=>{let r=e.id===t,i=ut(e.kind);return(0,H.jsxs)(`div`,{"data-testid":`symbol-item-${e.id}`,className:`nav-symbol-item ${r?`active`:``}`,onClick:()=>n(e),role:`listitem`,tabIndex:0,onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),n(e))},children:[(0,H.jsxs)(`div`,{className:`symbol-header-row`,children:[(0,H.jsxs)(`div`,{className:`symbol-name-col`,children:[(0,H.jsx)(`span`,{className:`symbol-kind-badge ${i}`,children:e.kind}),(0,H.jsx)(`span`,{className:`symbol-name-text`,title:e.full_symbol||e.name,children:e.name})]}),(0,H.jsx)(`div`,{className:`symbol-meta-col`,children:(0,H.jsxs)(`span`,{className:`symbol-line-badge`,children:[`L`,e.start_line,e.end_line&&e.end_line!==e.start_line?` - L${e.end_line}`:``]})})]}),e.route&&(0,H.jsxs)(`div`,{className:`symbol-route-row`,children:[(0,H.jsx)(`span`,{className:`route-method-badge ${lt(e.route.http_method)}`,children:e.route.http_method}),(0,H.jsx)(`span`,{className:`route-path-text`,title:e.route.path_pattern,children:e.route.path_pattern}),e.route.framework&&(0,H.jsx)(`span`,{className:`route-framework-tag`,children:e.route.framework})]}),e.signature&&(0,H.jsx)(`div`,{className:`symbol-signature-snippet`,children:(0,H.jsx)(`code`,{children:e.signature})})]},e.id)})}):(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`svg`,{width:`28`,height:`28`,viewBox:`0 0 24 24`,fill:`none`,stroke:`var(--text-muted)`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`})})}),(0,H.jsx)(`h4`,{children:`No File Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to inspect its symbols and routes.`})]})})]})};function ft(e){if(!e)return``;let t=e.toLowerCase();return t.includes(`class`)?`class`:t.includes(`method`)?`method`:t.includes(`func`)?`func`:t.includes(`interface`)?`interface`:t.includes(`struct`)?`struct`:t.includes(`enum`)?`enum`:t.includes(`module`)?`module`:e.replace(/_declaration|_item/g,``)}function pt({onOpenInNavigator:e}={}){let t=Je(),[n,r]=(0,V.useState)(``),[i,a]=(0,V.useState)(`code`),[o,s]=(0,V.useState)(``),[c,l]=(0,V.useState)(5),[u,d]=(0,V.useState)(`hybrid`),[f,p]=(0,V.useState)(.5),[m,h]=(0,V.useState)([]),[g,_]=(0,V.useState)(!1),[v,y]=(0,V.useState)(null),[b,x]=(0,V.useState)(null),[S,C]=(0,V.useState)(null);(0,V.useEffect)(()=>{(async()=>{try{let e=await fetch(`/admin/api/repos`);if(e.ok){let t=await e.json();Array.isArray(t)&&h(t.map(e=>typeof e==`string`?e:e.name).filter(Boolean))}}catch(e){console.error(`Failed to load repositories list:`,e)}})()},[]);let w=async e=>{if(e&&e.preventDefault(),n.trim()){_(!0),x(null),y(null);try{let e={query:n.trim(),type:i,repo:o.trim()||null,limit:c,search_mode:u,dense_weight:u===`hybrid`?f:+(u===`semantic`)},t=await fetch(`/admin/api/search/test`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await t.json();if(!t.ok)throw Error(r.error||`Search failed`);y(r.results||[])}catch(e){x(e.message),t.error(`Search failed: `+e.message)}finally{_(!1)}}},T=async(e,n)=>{try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(n),C(e),setTimeout(()=>C(null),2e3))}catch{t.error(`Failed to copy to clipboard`)}};return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Live Hybrid Search Inspector`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Test hybrid, semantic, and lexical search results with configurable scoring calibration and AST context.`}),(0,H.jsx)(`div`,{style:{marginTop:`16px`},children:(0,H.jsxs)(`div`,{className:`search-mode-segmented`,role:`group`,"aria-label":`Search Mode`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`hybrid`?`active`:``}`,onClick:()=>d(`hybrid`),"data-testid":`mode-hybrid-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-merge`}),` Hybrid Fusion`]}),(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`semantic`?`active`:``}`,onClick:()=>d(`semantic`),"data-testid":`mode-semantic-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-brain`}),` Semantic (Dense)`]}),(0,H.jsxs)(`button`,{type:`button`,className:`search-mode-btn ${u===`lexical`?`active`:``}`,onClick:()=>d(`lexical`),"data-testid":`mode-lexical-btn`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-font`}),` Lexical (BM25)`]})]})}),u===`hybrid`&&(0,H.jsxs)(`div`,{className:`hybrid-slider-container`,children:[(0,H.jsxs)(`div`,{className:`hybrid-slider-header`,children:[(0,H.jsx)(`span`,{children:(0,H.jsx)(`strong`,{children:`Hybrid Scoring Split:`})}),(0,H.jsxs)(`span`,{className:`hybrid-split-value`,children:[`Semantic: `,Math.round(f*100),`% / Lexical: `,Math.round((1-f)*100),`%`]})]}),(0,H.jsx)(`input`,{type:`range`,min:`0`,max:`1`,step:`0.05`,value:f,onChange:e=>p(parseFloat(e.target.value)),className:`hybrid-range-input`,"aria-label":`Hybrid dense weight slider`}),(0,H.jsxs)(`div`,{className:`hybrid-presets`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.5?`active`:``}`,onClick:()=>p(.5),children:`Balanced (50/50)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.7?`active`:``}`,onClick:()=>p(.7),children:`Semantic Bias (70/30)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===.3?`active`:``}`,onClick:()=>p(.3),children:`Keyword Bias (30/70)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===1?`active`:``}`,onClick:()=>p(1),children:`Pure Semantic (100/0)`}),(0,H.jsx)(`button`,{type:`button`,className:`btn-preset ${f===0?`active`:``}`,onClick:()=>p(0),children:`Pure Keyword (0/100)`})]})]}),(0,H.jsx)(`form`,{onSubmit:w,style:{marginTop:`14px`},children:(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:2},children:[(0,H.jsx)(`label`,{children:`Search Query`}),(0,H.jsx)(`input`,{type:`text`,required:!0,placeholder:`e.g. JWT token authentication or chunk_markdown`,value:n,onChange:e=>r(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Target Type`}),(0,H.jsxs)(`select`,{"aria-label":`Target Type`,value:i,onChange:e=>a(e.target.value),children:[(0,H.jsx)(`option`,{value:`code`,children:`Code Snippets & Symbols`}),(0,H.jsx)(`option`,{value:`doc`,children:`Documentation & Notes`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{children:`Repo Filter`}),(0,H.jsx)(`input`,{type:`text`,list:`search-inspector-repos`,placeholder:`All Repos`,value:o,onChange:e=>s(e.target.value)}),(0,H.jsxs)(`datalist`,{id:`search-inspector-repos`,children:[(0,H.jsx)(`option`,{value:``,children:`All Repos`}),m.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e))]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{maxWidth:`110px`},children:[(0,H.jsx)(`label`,{children:`Limit`}),(0,H.jsxs)(`select`,{"aria-label":`Result Limit`,value:c,onChange:e=>l(Number(e.target.value)),children:[(0,H.jsx)(`option`,{value:5,children:`Top 5`}),(0,H.jsx)(`option`,{value:10,children:`Top 10`}),(0,H.jsx)(`option`,{value:25,children:`Top 25`})]})]}),(0,H.jsx)(`div`,{className:`form-group search-form-btn-group`,style:{alignSelf:`flex-end`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:g,children:g?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{className:`nav-svg-spinner animate-spin`,"data-testid":`search-inspector-spinner`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,style:{marginRight:`6px`,verticalAlign:`middle`,display:`inline-block`},children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(255,255,255,0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`currentColor`,strokeWidth:`3`,strokeLinecap:`round`})]}),`Searching...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`currentColor`,style:{marginRight:`6px`,verticalAlign:`middle`},children:(0,H.jsx)(`polygon`,{points:`5 3 19 12 5 21 5 3`})}),`Search`]})})})]})}),(0,H.jsxs)(`div`,{style:{marginTop:`20px`},children:[g&&(0,H.jsx)(`div`,{className:`empty-state`,children:`Running hybrid retrieval with Normalized Weighted Fusion...`}),b&&(0,H.jsxs)(`div`,{className:`empty-state`,style:{color:`var(--danger)`},children:[`Search error: `,b]}),!g&&!b&&v===null&&(0,H.jsx)(`div`,{className:`empty-state`,children:`Enter a query above to test hybrid retrieval.`}),!g&&!b&&v!==null&&v.length===0&&(0,H.jsx)(`div`,{className:`empty-state`,children:`No matching results found in index.`}),!g&&!b&&v!==null&&v.length>0&&v.map((t,n)=>{let r=t.payload,i=t.dense_score!==void 0&&t.dense_score!==null,a=t.sparse_score!==void 0&&t.sparse_score!==null,o=ft(r.kind);return(0,H.jsxs)(`div`,{className:`search-hit-card`,children:[(0,H.jsxs)(`div`,{className:`search-hit-header`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:`6px`},children:[(0,H.jsx)(`span`,{className:`badge badge-primary`,children:r.repo}),(0,H.jsx)(`strong`,{children:r.rel_path}),o&&(0,H.jsx)(`span`,{className:`badge ${ut(o)}`,children:o}),r.symbol&&(0,H.jsx)(`span`,{className:`badge badge-accent`,children:r.full_symbol||r.symbol}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:[`(Lines `,r.start_line,`-`,r.end_line,`)`]}),r.github_url&&(()=>{let e=``;try{e=new URL(r.github_url).hostname.toLowerCase()}catch{}let t=r.github_url.toLowerCase(),n=`View Source`,i=`fa-solid fa-code-branch`;return e===`gitlab.com`||e.endsWith(`.gitlab.com`)||t.includes(`/-/blob/`)?(n=`View on GitLab`,i=`fa-brands fa-gitlab`):e.includes(`gitea`)||e.includes(`forgejo`)?(n=`View on Gitea`,i=`fa-solid fa-mug-hot`):e===`bitbucket.org`||e.endsWith(`.bitbucket.org`)?(n=`View on Bitbucket`,i=`fa-brands fa-bitbucket`):(e===`github.com`||e.endsWith(`.github.com`))&&(n=`View on GitHub`,i=`fa-brands fa-github`),(0,H.jsxs)(`a`,{href:r.github_url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,fontSize:`0.8rem`},children:[(0,H.jsx)(`i`,{className:i,style:{marginRight:`4px`}}),n]})})()]}),(0,H.jsxs)(`div`,{style:{display:`flex`,flexWrap:`wrap`,alignItems:`center`,gap:`8px`},children:[(0,H.jsxs)(`span`,{className:`badge badge-success`,title:`Overall relevance score`,children:[`Score: `,(t.score*100).toFixed(1),`% (`,t.score.toFixed(4),`)`]}),i&&(0,H.jsxs)(`span`,{className:`badge badge-info`,title:`Dense semantic vector similarity`,children:[`Semantic: `,((t.dense_score||0)*100).toFixed(1),`%`]}),a&&(0,H.jsxs)(`span`,{className:`badge badge-warning`,title:`Sparse lexical BM25 similarity`,children:[`Lexical: `,((t.sparse_score||0)*100).toFixed(1),`%`]}),(0,H.jsxs)(`div`,{className:`search-hit-actions`,children:[e&&r.rel_path&&(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary btn-xs`,onClick:()=>e(r.repo,r.rel_path,r.ast_symbol_id,r.start_line,r.end_line),title:`Open in Code Navigator`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`,fontSize:`0.75rem`,padding:`2px 8px`},children:[(0,H.jsxs)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`}),(0,H.jsx)(`polyline`,{points:`15 3 21 3 21 9`}),(0,H.jsx)(`line`,{x1:`10`,y1:`14`,x2:`21`,y2:`3`})]}),`Open in Navigator`]}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary btn-xs`,onClick:()=>T(n,r.content),title:`Copy snippet`,style:{display:`inline-flex`,alignItems:`center`,gap:`4px`,fontSize:`0.75rem`,padding:`2px 8px`},children:S===n?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2.5`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),`Copied`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`11`,height:`11`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`rect`,{x:`9`,y:`9`,width:`13`,height:`13`,rx:`2`,ry:`2`}),(0,H.jsx)(`path`,{d:`M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1`})]}),`Copy`]})})]})]})]}),r.signature&&(0,H.jsxs)(`div`,{className:`search-hit-signature`,children:[(0,H.jsx)(`span`,{style:{opacity:.7,marginRight:`6px`},children:`Signature:`}),(0,H.jsx)(`code`,{children:r.signature})]}),(0,H.jsx)(`pre`,{className:`search-hit-code`,children:r.content})]},n)})]})]})})}function mt({vectorStore:e,isLoadingVs:t,testFeedback:n,vsProvider:r,vsMode:i,vsStoragePath:a,setVsStoragePath:o,vsUrl:s,setVsUrl:c,vsCollection:l,setVsCollection:u,isTestingVs:d,isSwitchingVs:f,onProviderChange:p,onModeChange:m,onTestConnection:h,onSwitchBackend:g}){return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`}),` Vector Database Engine`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure and switch between vector database backends (Qdrant & ChromaDB). Switching backends updates system metadata and triggers full re-indexing.`}),(0,H.jsxs)(`div`,{className:`vs-config-layout`,children:[(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-nodes`}),` Active Vector Backend`]}),t&&!e?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading vector store configuration...`}):e?(0,H.jsxs)(`div`,{className:`specs-list`,style:{marginTop:0},children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Provider:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider===`chroma`?`ChromaDB`:`Qdrant`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Operating Mode:`}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.mode===`embedded`?`Embedded Disk`:`Remote Server`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:e.mode===`embedded`?`Storage Path:`:`Server URL:`}),(0,H.jsx)(`code`,{children:e.mode===`embedded`?e.storage_path||`data/qdrant_db`:e.url||`http://localhost:6333`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Collection Name:`}),(0,H.jsx)(`code`,{children:e.collection||`knowledge_rag_v1`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Points Count:`}),(0,H.jsx)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:(e.points_count||0).toLocaleString()})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Health Status:`}),e.healthy?(0,H.jsxs)(`span`,{className:`badge badge-success`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`}),` Healthy`]}):(0,H.jsxs)(`span`,{className:`badge badge-danger`,title:e.health_message||`Unhealthy`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`}),` `,e.health_message?e.health_message.length>35?e.health_message.slice(0,35)+`...`:e.health_message:`Unhealthy`]})]})]}):(0,H.jsx)(`p`,{className:`text-muted`,children:`No vector store configuration found.`})]}),(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-sliders`}),` Configure & Switch Backend`]}),n&&(0,H.jsxs)(`div`,{className:`vs-feedback-banner ${n.success?`feedback-success`:`feedback-error`}`,children:[(0,H.jsx)(`i`,{className:n.success?`fa-solid fa-circle-check`:`fa-solid fa-circle-exclamation`}),(0,H.jsx)(`span`,{children:n.message})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),g()},children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-provider`,children:`Vector Store Provider`}),(0,H.jsxs)(`select`,{id:`vs-provider`,value:r,onChange:e=>p(e.target.value),children:[(0,H.jsx)(`option`,{value:`qdrant`,children:`Qdrant (Hybrid Dense + BM25)`}),(0,H.jsx)(`option`,{value:`chroma`,children:`ChromaDB (Dense Vectors)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-mode`,children:`Operating Mode`}),(0,H.jsxs)(`select`,{id:`vs-mode`,value:i,onChange:e=>m(e.target.value),children:[(0,H.jsx)(`option`,{value:`embedded`,children:`Embedded Disk Storage`}),(0,H.jsx)(`option`,{value:`remote`,children:`Remote Server URL`})]})]})]}),i===`embedded`?(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-storage-path`,children:`Storage Directory Path`}),(0,H.jsx)(`input`,{id:`vs-storage-path`,type:`text`,value:a,onChange:e=>o(e.target.value),placeholder:r===`chroma`?`data/chroma_db`:`data/qdrant_db`})]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-url`,children:`Remote Server URL`}),(0,H.jsx)(`input`,{id:`vs-url`,type:`text`,value:s,onChange:e=>c(e.target.value),placeholder:r===`chroma`?`http://localhost:8000`:`http://localhost:6333`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`vs-collection`,children:`Collection Name`}),(0,H.jsx)(`input`,{id:`vs-collection`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`knowledge_rag_v1`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`16px`,flexWrap:`wrap`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:h,disabled:d||f,children:d?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Testing Connection...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plug`}),` Test Connection`]})}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-primary`,onClick:g,disabled:d||f,children:f?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Switching Backend...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Save & Switch Backend`]})})]})]})]})]})]})}function ht({embeddingConfig:e,isLoadingEmb:t,isSavingEmb:n,embProvider:r,setEmbProvider:i,embThreads:a,setEmbThreads:o,embBatchSize:s,setEmbBatchSize:c,embDenseModel:l,setEmbDenseModel:u,embSparseModel:d,setEmbSparseModel:f,embLitellmUrl:p,setEmbLitellmUrl:m,embLitellmApiKey:h=``,setEmbLitellmApiKey:g,embVisionOcrModel:_=`gemini-2.5-flash`,setEmbVisionOcrModel:v,embChatModel:y=`gemini-2.5-flash`,setEmbChatModel:b,discoveryResult:x=null,isDiscovering:S=!1,onDiscoverModels:C,onSaveEmbeddingSettings:w}){let T=e?.system_cpus||2,E=e?.system_memory_gb||4,[D,O]=(0,V.useState)(!1),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),N=x?.embedding_models||[],P=x?.vision_models||[],F=x?.chat_models||[];return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-microchip`}),` Embedding Engine & Resource Limits`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure local FastEmbed (ONNX) resource limits, CPU thread concurrency, or remote LiteLLM endpoints with dynamic model discovery for embeddings, Vision AI OCR, and chat synthesis.`}),(0,H.jsxs)(`div`,{className:`vs-config-layout`,children:[(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-gauge-high`}),` Active Embedding Engine`]}),t&&!e?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading embedding configuration...`}):e?(0,H.jsxs)(`div`,{className:`specs-list`,style:{marginTop:0},children:[(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Execution Provider:`}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider===`api`?`Remote API (LiteLLM)`:`Local FastEmbed (ONNX)`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`CPU Threads Allocation:`}),(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[e.threads,` `,e.threads===1?`Core`:`Cores`,` (of `,T,` detected)`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Batch Processing Size:`}),(0,H.jsxs)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:[e.batch_size,` chunks/batch`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`System RAM Capacity:`}),(0,H.jsxs)(`span`,{style:{fontSize:`0.9rem`,fontWeight:600},children:[E,` GB`]})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Dense Model:`}),(0,H.jsx)(`code`,{children:e.dense_model||`BAAI/bge-small-en-v1.5`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Sparse Model (BM25):`}),(0,H.jsx)(`code`,{children:e.sparse_model||`Qdrant/bm25`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Vision AI OCR Model:`}),(0,H.jsx)(`code`,{children:e.vision_ocr_model||`gemini-2.5-flash`})]}),(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`Chat Completion Model:`}),(0,H.jsx)(`code`,{children:e.chat_model||`gemini-2.5-flash`})]}),e.provider===`api`&&(0,H.jsxs)(`div`,{className:`spec-row`,children:[(0,H.jsx)(`span`,{children:`API Endpoint URL:`}),(0,H.jsx)(`code`,{children:e.litellm_url||`http://litellm:4000/v1`})]})]}):(0,H.jsx)(`p`,{className:`text-muted`,children:`No embedding configuration found.`})]}),(0,H.jsxs)(`div`,{className:`vs-box`,children:[(0,H.jsxs)(`h3`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-sliders`}),` Configure Models & Resources`]}),(0,H.jsxs)(`form`,{onSubmit:w,children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-provider`,children:`Embedding Provider`}),(0,H.jsxs)(`select`,{id:`emb-provider`,value:r,onChange:e=>i(e.target.value),children:[(0,H.jsx)(`option`,{value:`local`,children:`Local Model (FastEmbed / ONNX Runtime)`}),(0,H.jsx)(`option`,{value:`api`,children:`API Endpoint (LiteLLM / OpenAI Compatible)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-threads`,children:`CPU Thread Cap`}),(0,H.jsx)(`input`,{id:`emb-threads`,type:`number`,min:`1`,max:Math.max(T,128),value:a,onChange:e=>o(Math.max(1,parseInt(e.target.value)||1)),placeholder:`2`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`2px`,display:`block`},children:`Recommended: 2 cores. Prevents container CPU spikes.`})]})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-batch-size`,children:`Embedding Batch Size`}),(0,H.jsxs)(`select`,{id:`emb-batch-size`,value:s,onChange:e=>c(parseInt(e.target.value)||32),children:[(0,H.jsx)(`option`,{value:`16`,children:`16 chunks (Lowest RAM footprint)`}),(0,H.jsx)(`option`,{value:`32`,children:`32 chunks (Balanced Default)`}),(0,H.jsx)(`option`,{value:`64`,children:`64 chunks (High throughput)`}),(0,H.jsx)(`option`,{value:`128`,children:`128 chunks (Large RAM environments)`}),(0,H.jsx)(`option`,{value:`256`,children:`256 chunks (FastEmbed default)`})]})]}),r===`api`?(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-litellm-url`,children:`API Endpoint URL (LiteLLM)`}),(0,H.jsx)(`input`,{id:`emb-litellm-url`,type:`text`,value:p,onChange:e=>m(e.target.value),placeholder:`http://litellm:4000/v1`})]}):(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-dense-model`,children:`Dense Model Name`}),(0,H.jsx)(`input`,{id:`emb-dense-model`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`BAAI/bge-small-en-v1.5`})]})]}),r===`api`&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-litellm-api-key`,children:`LiteLLM API Key (Optional / Bearer)`}),(0,H.jsx)(`input`,{id:`emb-litellm-api-key`,type:`password`,value:h,onChange:e=>g?.(e.target.value),placeholder:`sk-...`,autoComplete:`off`})]}),(0,H.jsx)(`div`,{className:`form-group`,style:{display:`flex`,flexDirection:`column`,justifyContent:`flex-end`},children:(0,H.jsx)(`button`,{type:`button`,id:`btn-discover-models`,className:`btn btn-secondary`,onClick:C,disabled:S,style:{height:`38px`,whiteSpace:`nowrap`},children:S?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Discovering...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-bolt`}),` Discover Models`]})})})]}),x&&(0,H.jsx)(`div`,{style:{marginBottom:`16px`},children:x.status===`success`?(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,padding:`8px 12px`,background:`rgba(16, 185, 129, 0.1)`,border:`1px solid rgba(16, 185, 129, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-check`,style:{color:`#10b981`}}),(0,H.jsxs)(`span`,{children:[`Connected to LiteLLM — `,(0,H.jsxs)(`strong`,{children:[x.total_models,` models available`]}),` (`,N.length,` embedding, `,P.length,` vision, `,F.length,` chat)`]})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,padding:`8px 12px`,background:`rgba(239, 68, 68, 0.1)`,border:`1px solid rgba(239, 68, 68, 0.3)`,borderRadius:`6px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-triangle-exclamation`,style:{color:`#ef4444`}}),(0,H.jsx)(`span`,{children:x.message||`Could not connect to LiteLLM endpoint`})]})}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{htmlFor:`emb-dense-model`,style:{marginBottom:0},children:`Dense Embedding Model`}),N.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>O(!D),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:D?`← Select from discovered`:`Enter custom model →`})]}),!D&&N.length>0?(0,H.jsxs)(`select`,{id:`emb-dense-model`,value:l,onChange:e=>{e.target.value===`__custom__`?O(!0):u(e.target.value)},children:[N.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-dense-model`,type:`text`,value:l,onChange:e=>u(e.target.value),placeholder:`gemini-embedding-2`})]})]}),r===`local`&&(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`emb-sparse-model`,children:`Sparse BM25 Model`}),(0,H.jsx)(`input`,{id:`emb-sparse-model`,type:`text`,value:d,onChange:e=>f(e.target.value),placeholder:`Qdrant/bm25`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsxs)(`label`,{htmlFor:`emb-vision-ocr-model`,style:{marginBottom:0},children:[`Vision AI OCR Model `,(0,H.jsx)(`span`,{className:`text-muted`,style:{fontWeight:400,fontSize:`0.8rem`},children:`(PDF Ingestion Fallback)`})]}),P.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>A(!k),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:k?`← Select from discovered`:`Enter custom model →`})]}),!k&&P.length>0?(0,H.jsxs)(`select`,{id:`emb-vision-ocr-model`,value:_,onChange:e=>{e.target.value===`__custom__`?A(!0):v?.(e.target.value)},children:[P.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-vision-ocr-model`,type:`text`,value:_,onChange:e=>v?.(e.target.value),placeholder:`gemini-2.5-flash`})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{htmlFor:`emb-chat-model`,style:{marginBottom:0},children:`General Chat & Synthesis Model`}),F.length>0&&(0,H.jsx)(`button`,{type:`button`,className:`btn-link`,onClick:()=>M(!j),style:{fontSize:`0.75rem`,background:`none`,border:`none`,color:`#38bdf8`,cursor:`pointer`,padding:0},children:j?`← Select from discovered`:`Enter custom model →`})]}),!j&&F.length>0?(0,H.jsxs)(`select`,{id:`emb-chat-model`,value:y,onChange:e=>{e.target.value===`__custom__`?M(!0):b?.(e.target.value)},children:[F.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),(0,H.jsx)(`option`,{value:`__custom__`,children:`Custom / Enter manually...`})]}):(0,H.jsx)(`input`,{id:`emb-chat-model`,type:`text`,value:y,onChange:e=>b?.(e.target.value),placeholder:`gemini-2.5-flash`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`16px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:n||t,children:n?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving & Applying...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save & Apply Embedding Limits & Model Settings`]})})})]})]})]})]})}function gt({isLoadingAutoSync:e,intervalMins:t,setIntervalMins:n,hasGlobalSecret:r,showWebhookSecret:i,setShowWebhookSecret:a,webhookSecret:o,setWebhookSecret:s,fullWebhookUrl:c,copiedWebhookUrl:l,isSavingAutoSync:u,onSaveAutoSync:d,onClearWebhookSecret:f,onCopyWebhookUrl:p}){return(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Auto-Sync & Webhooks`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure scheduled background repository polling interval and global incoming webhook triggers.`}),e&&!t?(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`12px`},children:`Loading auto-sync settings...`}):(0,H.jsxs)(`form`,{onSubmit:d,style:{marginTop:`16px`},children:[(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-interval`,children:`Repository Polling Interval`}),(0,H.jsxs)(`select`,{id:`auto-sync-interval`,value:t,onChange:e=>n(Number(e.target.value)),style:{width:`100%`},children:[(0,H.jsx)(`option`,{value:0,children:`Disabled (0m)`}),(0,H.jsx)(`option`,{value:5,children:`5 minutes`}),(0,H.jsx)(`option`,{value:15,children:`15 minutes (Default)`}),(0,H.jsx)(`option`,{value:30,children:`30 minutes`}),(0,H.jsx)(`option`,{value:60,children:`1 hour`}),(0,H.jsx)(`option`,{value:360,children:`6 hours`}),![0,5,15,30,60,360].includes(t)&&(0,H.jsxs)(`option`,{value:t,children:[t,` minutes (Custom)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{flex:1},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`6px`},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-secret`,style:{marginBottom:0},children:`Global Webhook Secret (HMAC / Token)`}),r?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:`Secret Active`}):(0,H.jsx)(`span`,{className:`badge badge-secondary`,style:{color:`var(--text-muted)`},children:`None`})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`input`,{id:`auto-sync-secret`,type:i?`text`:`password`,value:o,onChange:e=>s(e.target.value),placeholder:r?`Secret configured (enter new to change)`:`Enter webhook secret (optional)`,style:{flex:1}}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>a(!i),title:i?`Hide secret`:`Reveal secret`,"aria-label":i?`Hide secret`:`Reveal secret`,style:{minWidth:`42px`,padding:`0 12px`},children:(0,H.jsx)(`i`,{className:`fa-solid ${i?`fa-eye-slash`:`fa-eye`}`})}),(r||o)&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:f,title:`Clear secret`,"aria-label":`Clear secret`,disabled:u,style:{padding:`0 12px`},children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginTop:`14px`,minWidth:0,width:`100%`},children:[(0,H.jsx)(`label`,{htmlFor:`auto-sync-webhook-url`,children:`Incoming Webhook Payload URL`}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`,minWidth:0,width:`100%`},children:[(0,H.jsx)(`input`,{id:`auto-sync-webhook-url`,type:`text`,readOnly:!0,value:c,style:{fontFamily:`var(--font-family-mono)`,fontSize:`0.85rem`,flex:1,minWidth:0,width:`100%`},"aria-label":`Webhook Payload URL`}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:p,style:{minWidth:`95px`},"aria-label":`Copy Webhook URL`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${l?`fa-check`:`fa-copy`}`}),` `,l?`Copied!`:`Copy`]})]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{fontSize:`0.8rem`,marginTop:`6px`},children:`Payload URL for repository push webhooks. Webhooks trigger immediate background synchronization for registered repositories.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`,marginTop:`18px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:u,children:u?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save Auto-Sync Settings`]})})})]})]})}function _t({stats:e,ghAuth:t,glAuth:n,gtAuth:r,ghToken:i,setGhToken:a,glToken:o,setGlToken:s,gtToken:c,setGtToken:l,hostCredentials:u,isHostModalOpen:d,setIsHostModalOpen:f,newHost:p,setNewHost:m,newHostProvider:h,setNewHostProvider:g,newHostUser:_,setNewHostUser:v,newHostToken:y,setNewHostToken:b,isSavingHost:x,onSaveToken:S,onClearToken:C,onSaveHostCredential:w,onDeleteHostCredential:T}){return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-key`}),` Global Git Provider Authentication`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Default tokens are automatically applied to repositories matching these providers when no per-repo or host-specific override exists.`}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(min(100%, 300px), 1fr))`,gap:`20px`,marginTop:`20px`},children:[(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github fa-lg`}),` GitHub`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:t.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`8px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:t.masked_token})]}),e?.rate_limit&&(0,H.jsxs)(`div`,{style:{fontSize:`0.78rem`,color:`var(--text-muted)`,marginBottom:`12px`},children:[`Rate Limit: `,e.rate_limit.remaining,` / `,e.rate_limit.limit,` requests`]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`github_token`,i,`GitHub`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`ghp_xxxxxxxxxxxx`,value:i,onChange:e=>a(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`github_token`,`GitHub`),children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-gitlab fa-lg`,style:{color:`#fc6d26`}}),` GitLab (Global)`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:n.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`16px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:n.masked_token})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`gitlab_token`,o,`GitLab`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`glpat-xxxxxxxxxxxx`,value:o,onChange:e=>s(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`gitlab_token`,`GitLab`),children:`Clear`})]})]})]}),(0,H.jsxs)(`div`,{className:`settings-provider-box`,style:{background:`rgba(255,255,255,0.02)`,padding:`16px`,borderRadius:`10px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,fontWeight:600},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-mug-hot fa-lg`,style:{color:`#609926`}}),` Gitea / Forgejo`]}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:r.token_source})]}),(0,H.jsxs)(`div`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`,marginBottom:`16px`,wordBreak:`break-all`},children:[`Active Token: `,(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:r.masked_token})]}),(0,H.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),S(`gitea_token`,c,`Gitea`)},children:[(0,H.jsx)(`div`,{className:`form-group`,style:{marginBottom:`10px`},children:(0,H.jsx)(`input`,{type:`password`,placeholder:`Token / Personal Token`,value:c,onChange:e=>l(e.target.value)})}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},children:`Save`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`4px 10px`,fontSize:`0.8rem`},onClick:()=>C(`gitea_token`,`Gitea`),children:`Clear`})]})]})]})]})]}),(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-shield-halved`}),` Custom & Self-Hosted Git Host Vault`]}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:[`Define credentials for self-hosted GitLab Enterprise, Gitea, or custom servers (e.g. `,(0,H.jsx)(`code`,{children:`gitlab.mycorp.com`}),` or `,(0,H.jsx)(`code`,{children:`git.lan:3000`}),`).`]})]}),(0,H.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>f(!0),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Host Credential`]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,style:{marginTop:`16px`},children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Host Domain / Address`}),(0,H.jsx)(`th`,{children:`Provider Type`}),(0,H.jsx)(`th`,{children:`Auth User`}),(0,H.jsx)(`th`,{children:`Masked Token`}),(0,H.jsx)(`th`,{children:`Added At`}),(0,H.jsx)(`th`,{children:`Actions`})]})}),(0,H.jsx)(`tbody`,{children:u.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:6,className:`empty-state`,children:`No custom host credentials configured. Add a host domain to authenticate self-hosted instances.`})}):u.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.host})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider.toUpperCase()})}),(0,H.jsx)(`td`,{children:e.auth_user?(0,H.jsx)(`code`,{children:e.auth_user}):(0,H.jsx)(`span`,{className:`text-muted`,children:`Default`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.masked_token})}),(0,H.jsx)(`td`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`},children:e.added_at}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>T(e.id,e.host),title:`Delete Credential`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`})})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:u.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No custom host credentials configured. Add a host domain to authenticate self-hosted instances.`}):u.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`6px`},children:(0,H.jsx)(`code`,{style:{fontSize:`0.95rem`},children:e.host})}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.provider.toUpperCase()})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Auth User: `}),e.auth_user?(0,H.jsx)(`code`,{children:e.auth_user}):(0,H.jsx)(`span`,{className:`text-muted`,children:`Default`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Masked Token: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.masked_token})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Added At: `}),(0,H.jsx)(`span`,{style:{color:`var(--text-muted)`},children:e.added_at})]})]}),(0,H.jsx)(`div`,{className:`data-mobile-card-actions`,children:(0,H.jsxs)(`button`,{className:`btn btn-secondary btn-delete`,onClick:()=>T(e.id,e.host),title:`Delete Credential`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Delete`]})})]},`card-${e.id}`))})]}),d&&(0,H.jsx)(`div`,{className:`modal-backdrop`,children:(0,H.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,H.jsxs)(`div`,{className:`modal-header`,children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-shield-halved`}),` Add Host Credential`]}),(0,H.jsx)(`button`,{className:`btn-close`,onClick:()=>f(!1),children:`×`})]}),(0,H.jsxs)(`form`,{onSubmit:w,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-domain`,children:`Host Domain / IP`}),(0,H.jsx)(`input`,{type:`text`,id:`host-domain`,required:!0,placeholder:`e.g. gitlab.mycorp.internal or git.lan:3000`,value:p,onChange:e=>m(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-row`,children:[(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-provider`,children:`Provider Type`}),(0,H.jsxs)(`select`,{id:`host-provider`,value:h,onChange:e=>g(e.target.value),children:[(0,H.jsx)(`option`,{value:`gitlab`,children:`GitLab Enterprise / Self-Hosted`}),(0,H.jsx)(`option`,{value:`gitea`,children:`Gitea / Forgejo`}),(0,H.jsx)(`option`,{value:`github`,children:`GitHub Enterprise`}),(0,H.jsx)(`option`,{value:`bitbucket`,children:`Bitbucket Server / Cloud`}),(0,H.jsx)(`option`,{value:`generic`,children:`Generic Git (HTTP / HTTPS)`})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-user`,children:`Auth User (Optional)`}),(0,H.jsx)(`input`,{type:`text`,id:`host-user`,placeholder:`e.g. oauth2 or gitlab-ci-token`,value:_,onChange:e=>v(e.target.value)})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,children:[(0,H.jsx)(`label`,{htmlFor:`host-token`,children:`Personal Access Token / Password`}),(0,H.jsx)(`input`,{type:`password`,id:`host-token`,required:!0,placeholder:`Token or password`,value:y,onChange:e=>b(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`modal-footer`,children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>f(!1),children:`Cancel`}),(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:x,children:x?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):`Save Host Credential`})]})]})]})})]})}var vt=`contextcortex_theme`,yt=`deep-ocean`,bt=[{id:`deep-ocean`,name:`Deep Ocean`,mode:`dark`,description:`Monochromatic petrol slate with vibrant cyan and mint accents.`,swatches:[`#07181b`,`#0d2c2f`,`#0891b2`,`#2dd4bf`]},{id:`midnight-blue`,name:`Midnight Blue`,mode:`dark`,description:`Classic deep space navy with cobalt blue and teal highlights.`,swatches:[`#0a0f1d`,`#121a2f`,`#3b82f6`,`#14b8a6`]},{id:`lavender-haze`,name:`Lavender Haze`,mode:`light`,description:`Elegant soft violet canvas with vibrant purple, fuchsia accents, and plum text.`,swatches:[`#f5f3ff`,`#faf8ff`,`#7c3aed`,`#ec4899`]},{id:`amber-warmth`,name:`Amber Warmth`,mode:`light`,description:`Warm sandstone canvas with terracotta orange, amber accents, and espresso text.`,swatches:[`#fdf8f4`,`#ffffff`,`#ea580c`,`#d97706`]}];function xt(){if(typeof window>`u`)return yt;try{let e=localStorage.getItem(vt);if(e===`arctic-frost`||e===`aqua-breeze`)return`lavender-haze`;if(e===`solar-daybreak`||e===`azure-daylight`)return`amber-warmth`;if(e&&bt.some(t=>t.id===e))return e}catch{}return yt}function St(e){if(!(typeof document>`u`)){document.documentElement.setAttribute(`data-theme`,e);try{localStorage.setItem(vt,e)}catch{}}}function Ct(){let[e,t]=(0,V.useState)(`deep-ocean`),n=Je();(0,V.useEffect)(()=>{t(xt())},[]);let r=(e,r)=>{St(e),t(e),n.success(`Switched theme to ${r}`)};return(0,H.jsxs)(`section`,{className:`settings-section glass-card`,"aria-labelledby":`theme-settings-heading`,children:[(0,H.jsxs)(`div`,{className:`section-header`,children:[(0,H.jsx)(`div`,{className:`header-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-palette`})}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h2`,{id:`theme-settings-heading`,style:{fontSize:`1.1rem`,fontWeight:600},children:`Appearance & Theme`}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Choose your preferred color scheme. The selected theme will persist across browser sessions.`})]})]}),(0,H.jsx)(`div`,{className:`theme-options-grid`,role:`radiogroup`,"aria-label":`Appearance Themes`,children:bt.map(t=>{let n=e===t.id;return(0,H.jsxs)(`button`,{type:`button`,className:`theme-card ${n?`active`:``}`,onClick:()=>r(t.id,t.name),role:`radio`,"aria-checked":n,"aria-label":`Select ${t.name} theme`,children:[(0,H.jsxs)(`div`,{className:`theme-card-header`,children:[(0,H.jsxs)(`div`,{className:`theme-card-title`,children:[(0,H.jsx)(`span`,{children:t.name}),(0,H.jsxs)(`span`,{className:`badge`,style:{fontSize:`0.68rem`,fontWeight:500,opacity:.85,padding:`2px 6px`},children:[(0,H.jsx)(`i`,{className:`fa-solid ${t.mode===`dark`?`fa-moon`:`fa-sun`}`,style:{marginRight:`3px`}}),t.mode===`dark`?`Dark`:`Light`]})]}),n?(0,H.jsxs)(`span`,{className:`badge badge-accent`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-check`,style:{marginRight:`4px`}}),` Active`]}):(0,H.jsx)(`span`,{className:`badge badge-primary`,children:`Select`})]}),(0,H.jsx)(`div`,{className:`theme-card-desc`,children:t.description}),(0,H.jsx)(`div`,{className:`theme-swatches`,"aria-hidden":`true`,children:t.swatches.map((e,t)=>(0,H.jsx)(`span`,{className:`theme-swatch`,style:{backgroundColor:e},title:e},t))})]},t.id)})})]})}function wt(){let[e,t]=(0,V.useState)({summary_enabled:!0,summary_threshold_kb:500,summary_max_file_size_mb:10,read_file_max_lines:2e3,summary_chat_model:`gemini-2.5-flash`}),[n,r]=(0,V.useState)(!1),[i,a]=(0,V.useState)(!1),o=Je(),s=async()=>{r(!0);try{let e=await fetch(`/admin/api/settings/files`);if(e.ok){let n=await e.json();t({summary_enabled:n.summary_enabled!==!1,summary_threshold_kb:n.summary_threshold_kb??500,summary_max_file_size_mb:n.summary_max_file_size_mb??10,read_file_max_lines:n.read_file_max_lines??2e3,summary_chat_model:n.summary_chat_model||`gemini-2.5-flash`})}}catch(e){console.error(`Failed to load file settings:`,e)}finally{r(!1)}};return(0,V.useEffect)(()=>{s()},[]),(0,H.jsxs)(`section`,{className:`settings-section glass-card`,"aria-labelledby":`file-settings-heading`,children:[(0,H.jsxs)(`div`,{className:`section-header`,children:[(0,H.jsx)(`div`,{className:`header-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`})}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`h2`,{id:`file-settings-heading`,style:{fontSize:`1.1rem`,fontWeight:600},children:`Files & Large File Summarization`}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Configure retrieval ceilings for AI agents and automatic LLM summarization thresholds for large files in watched folders and uploads.`})]})]}),n?(0,H.jsxs)(`div`,{style:{padding:`24px`,textAlign:`center`},className:`text-muted`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`,style:{marginRight:`8px`}}),` Loading settings...`]}):(0,H.jsx)(`form`,{onSubmit:async n=>{n.preventDefault(),a(!0);try{let n=await fetch(`/admin/api/settings/files`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)});if(n.ok){let e=await n.json();t(e),o.success(`File and summarization settings updated successfully`)}else{let e=await n.json();o.error(e.error||`Failed to save settings`)}}catch(e){o.error(`Save failed: ${e.message}`)}finally{a(!1)}},style:{marginTop:`16px`},children:(0,H.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:`16px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,padding:`12px 16px`,background:`rgba(255,255,255,0.03)`,borderRadius:`8px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-enabled-toggle`,style:{fontWeight:600,display:`block`,cursor:`pointer`},children:`Enable Large File Summarization`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`},children:`Automatically generate and vector-embed an executive summary when files exceed the size threshold instead of skipping them.`})]}),(0,H.jsx)(`input`,{id:`summary-enabled-toggle`,type:`checkbox`,checked:e.summary_enabled,onChange:n=>t({...e,summary_enabled:n.target.checked}),style:{width:`18px`,height:`18px`,cursor:`pointer`},"aria-label":`Enable Large File Summarization`})]}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(220px, 1fr))`,gap:`16px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-threshold-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Auto-Summarize Threshold (KB)`}),(0,H.jsx)(`input`,{id:`summary-threshold-input`,type:`number`,min:`10`,max:`50000`,value:e.summary_threshold_kb,onChange:n=>t({...e,summary_threshold_kb:Number(n.target.value)}),className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`Files larger than this (default: 500 KB) trigger LLM summarization.`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-max-size-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Max File Size for Summarization (MB)`}),(0,H.jsx)(`input`,{id:`summary-max-size-input`,type:`number`,min:`1`,max:`100`,value:e.summary_max_file_size_mb,onChange:n=>t({...e,summary_max_file_size_mb:Number(n.target.value)}),className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`Files larger than this ceiling (default: 10 MB) are skipped to protect memory.`})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`read-file-max-lines-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Max Lines Per Read`}),(0,H.jsx)(`input`,{id:`read-file-max-lines-input`,type:`number`,min:`50`,max:`20000`,value:e.read_file_max_lines,onChange:n=>t({...e,read_file_max_lines:Number(n.target.value)}),className:`input-field`,style:{width:`100%`}}),(0,H.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:[`Default line ceiling for `,(0,H.jsx)(`code`,{children:`read_file`}),` tool calls (default: 2000 lines).`]})]})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`label`,{htmlFor:`summary-chat-model-input`,style:{fontSize:`0.85rem`,fontWeight:500,display:`block`,marginBottom:`6px`},children:`Summarization Chat Model`}),(0,H.jsx)(`input`,{id:`summary-chat-model-input`,type:`text`,value:e.summary_chat_model,onChange:n=>t({...e,summary_chat_model:n.target.value}),placeholder:`e.g. gemini-2.5-flash or gpt-4o-mini`,className:`input-field`,style:{width:`100%`},disabled:!e.summary_enabled}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.75rem`,marginTop:`4px`,display:`block`},children:`LiteLLM chat model identifier used for generating file summaries.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,marginTop:`8px`},children:(0,H.jsx)(`button`,{type:`submit`,disabled:i,className:`btn btn-primary`,style:{display:`flex`,alignItems:`center`,gap:`8px`},children:i?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Saving...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-floppy-disk`}),` Save File Settings`]})})})]})})]})}function Tt({config:e,isLoading:t,isSaving:n,onSave:r,onTestConnection:i}){let a=Je(),[o,s]=(0,V.useState)(e?.url||`http://litellm:4000/v1`),[c,l]=(0,V.useState)(``),[u,d]=(0,V.useState)(!1),[f,p]=(0,V.useState)(!1),[m,h]=(0,V.useState)(e?.chat_model||`gemini-2.5-flash`),[g,_]=(0,V.useState)(e?.vision_ocr_model||`gemini-2.5-flash`),[v,y]=(0,V.useState)(e?.embedding_model||`BAAI/bge-small-en-v1.5`),[b,x]=(0,V.useState)(!1),[S,C]=(0,V.useState)(!1),[w,T]=(0,V.useState)(!1),[E,D]=(0,V.useState)(!1),[O,k]=(0,V.useState)(null);(0,V.useEffect)(()=>{e&&(s(e.url),h(e.chat_model),_(e.vision_ocr_model),y(e.embedding_model))},[e]);let A=async()=>{D(!0);try{if(i){let e=await i(o,u?c:void 0);k(e)}else{let e=new URLSearchParams;o&&e.set(`url`,o),u&&c.trim()&&e.set(`api_key`,c.trim());let t=await(await fetch(`/admin/api/models/discover?${e.toString()}`)).json();k(t),t.status===`success`?a.success(`Connected to gateway: ${t.total_models} models available`):a.error(t.message||`Failed to connect to gateway`)}}catch(e){a.error(`Discovery error: `+e.message),k({status:`error`,total_models:0,models:[],embedding_models:[],vision_models:[],chat_models:[],message:e.message})}finally{D(!1)}},j=async e=>{e.preventDefault();try{await r({url:o.trim(),api_key:u?c.trim():void 0,chat_model:m.trim(),vision_ocr_model:g.trim(),embedding_model:v.trim()}),d(!1),l(``)}catch(e){a.error(`Save failed: `+e.message)}},M=async()=>{if(window.confirm(`Clear stored API key from database?`))try{await r({api_key:``}),d(!1),l(``),a.success(`API key cleared`)}catch(e){a.error(`Failed to clear key: `+e.message)}},N=e=>Array.isArray(e)?e.map(e=>typeof e==`string`?e:e?.id||e?.name||``).filter(Boolean):[],P=N(O?.chat_models),F=N(O?.vision_models),I=N(O?.embedding_models);return(0,H.jsxs)(`div`,{className:`glass-card`,"data-testid":`ai-gateway-settings-card`,children:[(0,H.jsx)(`div`,{style:{display:`flex`,alignItems:`center`,justifyContent:`space-between`,marginBottom:`8px`},children:(0,H.jsxs)(`h2`,{children:[(0,H.jsxs)(`svg`,{width:`20`,height:`20`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,style:{marginRight:`8px`,verticalAlign:`middle`},children:[(0,H.jsx)(`rect`,{x:`3`,y:`11`,width:`18`,height:`10`,rx:`2`}),(0,H.jsx)(`circle`,{cx:`12`,cy:`5`,r:`2`}),(0,H.jsx)(`path`,{d:`M12 7v4`}),(0,H.jsx)(`line`,{x1:`8`,y1:`16`,x2:`8.01`,y2:`16`}),(0,H.jsx)(`line`,{x1:`16`,y1:`16`,x2:`16.01`,y2:`16`})]}),`AI & Model Gateway (OpenAI-Compatible)`]})}),(0,H.jsxs)(`p`,{className:`text-muted`,style:{fontSize:`0.85rem`,marginBottom:`18px`},children:[`Connect universal OpenAI-compatible LLM gateways such as `,(0,H.jsx)(`strong`,{children:`LiteLLM`}),`, `,(0,H.jsx)(`strong`,{children:`Ollama`}),`, `,(0,H.jsx)(`strong`,{children:`vLLM`}),`, `,(0,H.jsx)(`strong`,{children:`LocalAI`}),`, `,(0,H.jsx)(`strong`,{children:`OpenAI`}),`, or `,(0,H.jsx)(`strong`,{children:`OpenRouter`}),`. Settings are managed directly from the UI and persisted to the database.`]}),t?(0,H.jsx)(`p`,{className:`text-muted`,children:`Loading gateway configuration...`}):(0,H.jsxs)(`form`,{onSubmit:j,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{marginBottom:`16px`},children:[(0,H.jsx)(`label`,{htmlFor:`ai-gateway-url`,style:{fontWeight:600},children:`API Endpoint URL`}),(0,H.jsx)(`input`,{id:`ai-gateway-url`,type:`text`,required:!0,value:o,onChange:e=>s(e.target.value),placeholder:`http://litellm:4000/v1`}),(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.78rem`},children:`Base OpenAI-compatible API endpoint root (including /v1).`})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{marginBottom:`16px`},children:[(0,H.jsx)(`label`,{htmlFor:`ai-gateway-key`,style:{fontWeight:600},children:`API Key / Bearer Token`}),e?.has_api_key&&!u?(0,H.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`},children:[(0,H.jsx)(`div`,{style:{flex:1,padding:`8px 12px`,background:`rgba(0,0,0,0.3)`,border:`1px solid var(--border-card)`,borderRadius:`6px`,fontFamily:`var(--font-mono)`},children:(0,H.jsx)(`span`,{children:e.masked_api_key||`••••••••`})}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>d(!0),style:{fontSize:`0.82rem`,padding:`6px 12px`},children:`Change Key`}),(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:M,style:{fontSize:`0.82rem`,padding:`6px 12px`,color:`var(--danger)`},children:`Clear Key`})]}):(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`8px`},children:[(0,H.jsxs)(`div`,{style:{position:`relative`,flex:1},children:[(0,H.jsx)(`input`,{id:`ai-gateway-key`,type:f?`text`:`password`,value:c,onChange:e=>l(e.target.value),placeholder:`Enter API key (e.g. sk-...)`,autoComplete:`new-password`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>p(!f),style:{position:`absolute`,right:`10px`,top:`50%`,transform:`translateY(-50%)`,background:`none`,border:`none`,color:`var(--text-muted)`,cursor:`pointer`},title:f?`Hide Key`:`Show Key`,children:f?`Hide`:`Show`})]}),e?.has_api_key&&u&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>{d(!1),l(``)},style:{fontSize:`0.82rem`,padding:`6px 12px`},children:`Cancel`})]})]}),(0,H.jsxs)(`div`,{style:{marginBottom:`22px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:A,disabled:E,style:{display:`inline-flex`,alignItems:`center`,gap:`8px`,fontSize:`0.85rem`,padding:`7px 14px`},children:E?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{className:`nav-svg-spinner animate-spin`,width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(255,255,255,0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`currentColor`,strokeWidth:`3`,strokeLinecap:`round`})]}),(0,H.jsx)(`span`,{children:`Connecting & Discovering...`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]}),(0,H.jsx)(`span`,{children:`Test Connection & Discover Models`})]})}),O&&(0,H.jsx)(`div`,{style:{marginTop:`10px`,padding:`8px 12px`,borderRadius:`6px`,fontSize:`0.82rem`,background:O.status===`success`?`rgba(20, 184, 166, 0.15)`:`rgba(239, 68, 68, 0.15)`,border:`1px solid ${O.status===`success`?`rgba(20, 184, 166, 0.4)`:`rgba(239, 68, 68, 0.4)`}`,color:O.status===`success`?`var(--accent)`:`var(--danger)`},children:O.status===`success`?`Connected successfully (${O.total_models} models available)`:`Connection error: ${O.message}`})]}),(0,H.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(auto-fit, minmax(280px, 1fr))`,gap:`16px`,marginBottom:`22px`},children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`Chat Completion Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>x(!b),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:b?`Use Discovered List`:`Custom Input`})]}),b||P.length===0?(0,H.jsx)(`input`,{type:`text`,value:m,onChange:e=>h(e.target.value),placeholder:`e.g. gemini-2.5-flash or gpt-4o`}):(0,H.jsxs)(`select`,{value:m,onChange:e=>h(e.target.value),children:[P.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!P.includes(m)&&(0,H.jsxs)(`option`,{value:m,children:[m,` (Current)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`Vision OCR Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>C(!S),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:S?`Use Discovered List`:`Custom Input`})]}),S||F.length===0?(0,H.jsx)(`input`,{type:`text`,value:g,onChange:e=>_(e.target.value),placeholder:`e.g. gemini-2.5-flash or gpt-4o-mini`}):(0,H.jsxs)(`select`,{value:g,onChange:e=>_(e.target.value),children:[F.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!F.includes(g)&&(0,H.jsxs)(`option`,{value:g,children:[g,` (Current)`]})]})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,marginBottom:`4px`},children:[(0,H.jsx)(`label`,{style:{fontWeight:600,fontSize:`0.84rem`},children:`API Embedding Model`}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>T(!w),style:{background:`none`,border:`none`,color:`var(--primary)`,cursor:`pointer`,fontSize:`0.74rem`},children:w?`Use Discovered List`:`Custom Input`})]}),w||I.length===0?(0,H.jsx)(`input`,{type:`text`,value:v,onChange:e=>y(e.target.value),placeholder:`e.g. text-embedding-3-small`}):(0,H.jsxs)(`select`,{value:v,onChange:e=>y(e.target.value),children:[I.map(e=>(0,H.jsx)(`option`,{value:e,children:e},e)),!I.includes(v)&&(0,H.jsxs)(`option`,{value:v,children:[v,` (Current)`]})]})]})]}),(0,H.jsx)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,marginTop:`16px`},children:(0,H.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:n,style:{padding:`8px 20px`,fontSize:`0.88rem`},children:n?`Saving Settings...`:`Save AI Gateway Settings`})})]})]})}function Et({stats:e,refreshStats:t,initialCategory:n}){let[r,i]=(0,V.useState)(n??(globalThis.__vitest_worker__||globalThis.vi?`all`:`ai-gateway`)),[a,o]=(0,V.useState)(null),[s,c]=(0,V.useState)(!1),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(``),[p,m]=(0,V.useState)(``),[h,g]=(0,V.useState)(``),[_,v]=(0,V.useState)([]),[y,b]=(0,V.useState)(15),[x,S]=(0,V.useState)(``),[C,w]=(0,V.useState)(!1),[T,E]=(0,V.useState)(`/api/webhooks/git`),[D,O]=(0,V.useState)(!1),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(!1),[N,P]=(0,V.useState)(!1),[F,I]=(0,V.useState)(!1),[L,R]=(0,V.useState)(``),[z,B]=(0,V.useState)(`gitlab`),[ee,te]=(0,V.useState)(``),[ne,re]=(0,V.useState)(``),[ie,ae]=(0,V.useState)(!1),[oe,se]=(0,V.useState)(null),[ce,le]=(0,V.useState)(!1),[ue,de]=(0,V.useState)(`qdrant`),[fe,pe]=(0,V.useState)(`embedded`),[me,he]=(0,V.useState)(`data/qdrant_db`),[ge,_e]=(0,V.useState)(`http://localhost:6333`),[ve,ye]=(0,V.useState)(`knowledge_rag_v1`),[be,xe]=(0,V.useState)(!1),[Se,Ce]=(0,V.useState)(null),[we,Te]=(0,V.useState)(!1),[Ee,De]=(0,V.useState)(null),[Oe,ke]=(0,V.useState)(!1),[Ae,je]=(0,V.useState)(!1),[Me,Ne]=(0,V.useState)(`local`),[Pe,Fe]=(0,V.useState)(2),[Ie,Le]=(0,V.useState)(32),[Re,ze]=(0,V.useState)(`BAAI/bge-small-en-v1.5`),[Be,Ve]=(0,V.useState)(`Qdrant/bm25`),[He,Ue]=(0,V.useState)(`http://litellm:4000/v1`),[We,Ge]=(0,V.useState)(``),[Ke,qe]=(0,V.useState)(`gemini-2.5-flash`),[Ye,Xe]=(0,V.useState)(`gemini-2.5-flash`),[Ze,Qe]=(0,V.useState)(null),[$e,et]=(0,V.useState)(!1),U=Je(),tt=(0,V.useCallback)(async()=>{c(!0);try{let e=await fetch(`/admin/api/settings/ai-gateway`);if(e.ok){let t=await e.json();o(t)}}catch(e){console.error(`Failed to load AI gateway settings:`,e)}finally{c(!1)}},[]),nt=async e=>{u(!0);try{let n=await fetch(`/admin/api/settings/ai-gateway`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to save AI gateway settings`);r.config&&o(r.config),U.success(`AI & Model Gateway settings saved successfully.`),t()}catch(e){throw U.error(`Error saving AI gateway settings: `+e.message),e}finally{u(!1)}},rt=(0,V.useCallback)(async()=>{try{let e=await fetch(`/admin/api/settings/hosts`);if(e.ok){let t=await e.json();v(Array.isArray(t)?t:[])}}catch(e){console.error(`Failed to load host credentials:`,e),v([])}},[]),it=(0,V.useCallback)(async()=>{le(!0);try{let e=await fetch(`/admin/api/vector-store`);if(e.ok){let t=await e.json();se(t),t.provider&&de(t.provider),t.mode&&pe(t.mode),t.storage_path&&he(t.storage_path),t.url&&_e(t.url),t.collection&&ye(t.collection)}}catch(e){console.error(`Failed to load vector store config:`,e)}finally{le(!1)}},[]),at=(0,V.useCallback)(async()=>{O(!0);try{let e=await fetch(`/admin/api/settings/auto-sync`);if(e.ok){let t=await e.json();typeof t.interval_mins==`number`&&b(t.interval_mins),typeof t.webhook_url==`string`&&E(t.webhook_url),typeof t.has_global_secret==`boolean`&&w(t.has_global_secret)}}catch(e){console.error(`Failed to load auto-sync settings:`,e)}finally{O(!1)}},[]),ot=(0,V.useCallback)(async()=>{ke(!0);try{let e=await fetch(`/admin/api/settings/embedding`);if(e.ok){let t=await e.json();De(t),t.provider&&Ne(t.provider),typeof t.threads==`number`&&Fe(t.threads),typeof t.batch_size==`number`&&Le(t.batch_size),t.dense_model&&ze(t.dense_model),t.sparse_model&&Ve(t.sparse_model),t.litellm_url&&Ue(t.litellm_url),t.litellm_api_key&&Ge(t.litellm_api_key),t.vision_ocr_model&&qe(t.vision_ocr_model),t.chat_model&&Xe(t.chat_model)}}catch(e){console.error(`Failed to load embedding config:`,e)}finally{ke(!1)}},[]);(0,V.useEffect)(()=>{tt(),rt(),it(),at(),ot()},[tt,rt,it,at,ot]),(0,V.useEffect)(()=>{e?.vector_store?(se(e.vector_store),e.vector_store.provider&&de(e.vector_store.provider),e.vector_store.mode&&pe(e.vector_store.mode),e.vector_store.storage_path&&he(e.vector_store.storage_path),e.vector_store.url&&_e(e.vector_store.url),e.vector_store.collection&&ye(e.vector_store.collection)):e?.vector_store_provider&&(se(t=>t?{...t,provider:e.vector_store_provider||t.provider,mode:e.vector_store_mode||t.mode,collection:e.vector_store_collection||t.collection}:null),e.vector_store_provider&&de(e.vector_store_provider),e.vector_store_mode&&pe(e.vector_store_mode),e.vector_store_collection&&ye(e.vector_store_collection))},[e]);let st=async()=>{et(!0);try{let e=new URLSearchParams;He&&e.set(`url`,He),We.trim()&&e.set(`api_key`,We.trim());let t=await(await fetch(`/admin/api/models/discover?${e.toString()}`)).json();Qe(t),t.status===`success`?U.success(`Discovered ${t.total_models} models from OpenAI-compatible endpoint`):U.error(t.message||`Model discovery returned an error`)}catch(e){U.error(`Failed to discover models: `+e.message),Qe({status:`error`,total_models:0,models:[],embedding_models:[],vision_models:[],chat_models:[],message:e.message})}finally{et(!1)}},ct=async e=>{e.preventDefault(),je(!0);try{let e={provider:Me,threads:Number(Pe),batch_size:Number(Ie),dense_model:Re.trim()||void 0,sparse_model:Be.trim()||void 0,vision_ocr_model:Ke.trim()||void 0,chat_model:Ye.trim()||void 0},n=await fetch(`/admin/api/settings/embedding`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||r.message||`Failed to save embedding settings`);r.config&&De(r.config),U.success(`Embedding resource limits updated successfully`),t()}catch(e){U.error(`Error saving embedding settings: `+e.message)}finally{je(!1)}},lt=`${typeof window<`u`?window.location.origin:``}${T||`/api/webhooks/git`}`,ut=async()=>{try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(lt),P(!0),U.info(`Webhook URL copied to clipboard`),setTimeout(()=>P(!1),2e3)}catch(e){U.error(`Failed to copy: `+e.message)}},dt=async e=>{e.preventDefault(),A(!0);try{let e={interval_mins:Number(y)};x.trim()&&(e.global_webhook_secret=x.trim());let n=await fetch(`/admin/api/settings/auto-sync`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),r=await n.json();if(!n.ok)throw Error(r.error||`Failed to save auto-sync settings`);typeof r.has_global_secret==`boolean`?w(r.has_global_secret):x.trim()&&w(!0),typeof r.interval_mins==`number`&&b(r.interval_mins),S(``),U.success(`Auto-sync settings saved successfully`),t()}catch(e){U.error(`Error saving auto-sync settings: `+e.message)}finally{A(!1)}},ft=async()=>{if(!C){S(``);return}if(window.confirm(`Clear the global webhook signature secret?`)){A(!0);try{let e=await fetch(`/admin/api/settings/auto-sync`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({interval_mins:Number(y),global_webhook_secret:``})}),t=await e.json();if(!e.ok)throw Error(t.error||`Failed to clear global webhook secret`);w(!1),S(``),U.success(`Global webhook secret cleared`)}catch(e){U.error(`Failed to clear webhook secret: `+e.message)}finally{A(!1)}}},pt=e=>{de(e),e===`qdrant`?((!me||me===`data/chroma_db`)&&he(`data/qdrant_db`),(!ge||ge===`http://localhost:8000`)&&_e(`http://localhost:6333`)):((!me||me===`data/qdrant_db`)&&he(`data/chroma_db`),(!ge||ge===`http://localhost:6333`)&&_e(`http://localhost:8000`))},vt=e=>{pe(e),e===`embedded`&&!me&&he(ue===`chroma`?`data/chroma_db`:`data/qdrant_db`),e===`remote`&&!ge&&_e(ue===`chroma`?`http://localhost:8000`:`http://localhost:6333`)},yt=async()=>{xe(!0),Ce(null);try{let e={provider:ue,mode:fe,storage_path:fe===`embedded`?me.trim():null,url:fe===`remote`?ge.trim():null,collection:ve.trim()||`knowledge_rag_v1`},t=await fetch(`/admin/api/vector-store/test`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),n=await t.json();if(t.ok){let e=n.message||(n.success?`Vector store connection healthy.`:`Vector store test failed.`);Ce({success:n.success,message:e}),n.success?U.success(e):U.error(`Vector store test: `+e)}else{let e=n.error||n.message||`Connection test failed`;Ce({success:!1,message:e}),U.error(`Vector store test: `+e)}}catch(e){Ce({success:!1,message:e.message}),U.error(`Vector store test error: `+e.message)}finally{xe(!1)}},bt=async()=>{let e=ue===`qdrant`?`Qdrant`:`ChromaDB`;if(window.confirm(`Switch active vector database backend to ${e} (${fe})? Existing embeddings in the old database will remain intact.`)){Te(!0),Ce(null);try{let n={provider:ue,mode:fe,storage_path:fe===`embedded`?me.trim():null,url:fe===`remote`?ge.trim():null,collection:ve.trim()||`knowledge_rag_v1`},r=await fetch(`/admin/api/vector-store/switch`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(n)}),i=await r.json();if(!r.ok||i.status===`error`){let e=i.error||i.message||`Failed to switch vector database backend`;Ce({success:!1,message:e}),U.error(`Switch error: `+e)}else{let n=i.message||`Switched vector backend to ${e}`;Ce({success:!0,message:n}),U.success(n),await it(),t()}}catch(e){Ce({success:!1,message:e.message}),U.error(`Switch error: `+e.message)}finally{Te(!1)}}},xt=async(e,n,r)=>{if(n.trim())try{let i=await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({[e]:n.trim()})}),a=await i.json();if(!i.ok)throw Error(a.error||`Failed to save token`);U.success(`${r} token saved successfully.`),e===`github_token`&&f(``),e===`gitlab_token`&&m(``),e===`gitea_token`&&g(``),t()}catch(e){U.error(`Error saving ${r} token: `+e.message)}},St=async(e,n)=>{if(window.confirm(`Clear the stored ${n} token from database?`))try{let r=await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({[e]:``})});if(!r.ok){let e=await r.json().catch(()=>({}));throw Error(e.error||`Failed to clear token`)}U.success(`${n} token cleared`),t()}catch(e){U.error(`Failed to clear ${n} token: `+e.message)}},Et=async e=>{if(e.preventDefault(),!(!L.trim()||!ne.trim())){ae(!0);try{let e=await fetch(`/admin/api/settings/hosts`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({host:L.trim(),provider:z,auth_user:ee.trim()||null,auth_token:ne.trim()})}),t=await e.json();if(!e.ok)throw Error(t.error||`Failed to save host credential`);U.success(`Host credential for '${L.trim()}' saved`),I(!1),R(``),B(`gitlab`),te(``),re(``),rt()}catch(e){U.error(`Error: `+e.message)}finally{ae(!1)}}},Dt=async(e,t)=>{if(window.confirm(`Remove stored credentials for host '${t}'?`))try{let n=await fetch(`/admin/api/settings/hosts/${e}`,{method:`DELETE`});if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Failed to delete`)}U.success(`Removed credentials for '${t}'`),rt()}catch(e){U.error(`Failed to remove: `+e.message)}},Ot=e?.providers_auth?.github||{token_source:e?.token_source||`None`,masked_token:e?.masked_token||`None`},kt=e?.providers_auth?.gitlab||{token_source:`None`,masked_token:`None`},At=e?.providers_auth?.gitea||{token_source:`None`,masked_token:`None`};return(0,H.jsx)(`div`,{className:`tab-content active`,"data-testid":`settings-tab-content`,children:(0,H.jsxs)(`div`,{className:`settings-dashboard-layout`,children:[(0,H.jsxs)(`aside`,{className:`settings-category-sidebar`,role:`tablist`,"aria-label":`Settings Categories`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`ai-gateway`?`active`:``}`,onClick:()=>i(`ai-gateway`),role:`tab`,"aria-selected":r===`ai-gateway`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-robot`}),(0,H.jsx)(`span`,{children:`AI & Model Gateway`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`vector-store`?`active`:``}`,onClick:()=>i(`vector-store`),role:`tab`,"aria-selected":r===`vector-store`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`}),(0,H.jsx)(`span`,{children:`Vector Database`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`embedding`?`active`:``}`,onClick:()=>i(`embedding`),role:`tab`,"aria-selected":r===`embedding`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-microchip`}),(0,H.jsx)(`span`,{children:`Embedding Engine`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`auto-sync`?`active`:``}`,onClick:()=>i(`auto-sync`),role:`tab`,"aria-selected":r===`auto-sync`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),(0,H.jsx)(`span`,{children:`Auto-Sync & Webhooks`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`git-hosts`?`active`:``}`,onClick:()=>i(`git-hosts`),role:`tab`,"aria-selected":r===`git-hosts`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-key`}),(0,H.jsx)(`span`,{children:`Git & Host Credentials`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`files`?`active`:``}`,onClick:()=>i(`files`),role:`tab`,"aria-selected":r===`files`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-lines`}),(0,H.jsx)(`span`,{children:`File & Summaries`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`settings-category-btn ${r===`appearance`?`active`:``}`,onClick:()=>i(`appearance`),role:`tab`,"aria-selected":r===`appearance`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-palette`}),(0,H.jsx)(`span`,{children:`Appearance & Theme`})]})]}),(0,H.jsxs)(`main`,{className:`settings-active-panel`,children:[(r===`all`||r===`ai-gateway`)&&(0,H.jsx)(Tt,{config:a,isLoading:s,isSaving:l,onSave:nt}),(r===`all`||r===`vector-store`)&&(0,H.jsx)(mt,{vectorStore:oe,isLoadingVs:ce,testFeedback:Se,vsProvider:ue,vsMode:fe,vsStoragePath:me,setVsStoragePath:he,vsUrl:ge,setVsUrl:_e,vsCollection:ve,setVsCollection:ye,isTestingVs:be,isSwitchingVs:we,onProviderChange:pt,onModeChange:vt,onTestConnection:yt,onSwitchBackend:bt}),(r===`all`||r===`embedding`)&&(0,H.jsx)(ht,{embeddingConfig:Ee,isLoadingEmb:Oe,isSavingEmb:Ae,embProvider:Me,setEmbProvider:Ne,embThreads:Pe,setEmbThreads:Fe,embBatchSize:Ie,setEmbBatchSize:Le,embDenseModel:Re,setEmbDenseModel:ze,embSparseModel:Be,setEmbSparseModel:Ve,embLitellmUrl:He,setEmbLitellmUrl:Ue,embLitellmApiKey:We,setEmbLitellmApiKey:Ge,embVisionOcrModel:Ke,setEmbVisionOcrModel:qe,embChatModel:Ye,setEmbChatModel:Xe,discoveryResult:Ze,isDiscovering:$e,onDiscoverModels:st,onSaveEmbeddingSettings:ct}),(r===`all`||r===`auto-sync`)&&(0,H.jsx)(gt,{isLoadingAutoSync:D,intervalMins:y,setIntervalMins:b,hasGlobalSecret:C,showWebhookSecret:j,setShowWebhookSecret:M,webhookSecret:x,setWebhookSecret:S,fullWebhookUrl:lt,copiedWebhookUrl:N,isSavingAutoSync:k,onSaveAutoSync:dt,onClearWebhookSecret:ft,onCopyWebhookUrl:ut}),(r===`all`||r===`git-hosts`)&&(0,H.jsx)(_t,{stats:e,ghAuth:Ot,glAuth:kt,gtAuth:At,ghToken:d,setGhToken:f,glToken:p,setGlToken:m,gtToken:h,setGtToken:g,hostCredentials:_,isHostModalOpen:F,setIsHostModalOpen:I,newHost:L,setNewHost:R,newHostProvider:z,setNewHostProvider:B,newHostUser:ee,setNewHostUser:te,newHostToken:ne,setNewHostToken:re,isSavingHost:ie,onSaveToken:xt,onClearToken:St,onSaveHostCredential:Et,onDeleteHostCredential:Dt}),(r===`all`||r===`files`)&&(0,H.jsx)(wt,{}),(r===`all`||r===`appearance`)&&(0,H.jsx)(Ct,{})]})]})})}function Dt(){let e=Je(),[t,n]=(0,V.useState)([]),[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(`ALL`),[s,c]=(0,V.useState)(``),[l,u]=(0,V.useState)(!0),[d,f]=(0,V.useState)(new Set),p=(0,V.useRef)(null),m=(0,V.useRef)(null),h=(0,V.useCallback)(async()=>{i(!0);try{let e=await fetch(`/admin/api/logs`);if(!e.ok)throw Error(`HTTP ${e.status}`);let t=await e.json();n(Array.isArray(t)?t:[])}catch(t){e.error(`Failed to load diagnostics logs: ${t.message}`)}finally{i(!1)}},[e]);(0,V.useEffect)(()=>{h();let e=setInterval(h,8e3);return()=>clearInterval(e)},[h]),(0,V.useEffect)(()=>{l&&m.current&&(m.current.scrollTop=m.current.scrollHeight)},[t,l]);let g=async()=>{if(window.confirm(`Are you sure you want to clear all server diagnostics logs?`))try{let t=await fetch(`/admin/api/logs`,{method:`DELETE`});if(!t.ok){let e=await t.json().catch(()=>({}));throw Error(e.error||`HTTP ${t.status}`)}n([]),f(new Set),e.success(`Diagnostics logs cleared.`)}catch(t){e.error(`Failed to clear logs: ${t.message}`)}},_=e=>{f(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},v=e=>{switch(e.toUpperCase()){case`ERROR`:return`badge badge-danger`;case`WARNING`:return`badge badge-warning`;case`INFO`:return`badge badge-primary`;case`DEBUG`:return`badge badge-secondary`;default:return`badge badge-secondary`}},y=t.filter(e=>{if(a!==`ALL`&&e.level.toUpperCase()!==a)return!1;if(s.trim()){let t=s.toLowerCase(),n=e.message?.toLowerCase().includes(t),r=e.logger?.toLowerCase().includes(t),i=e.traceback?.toLowerCase().includes(t),a=e.level?.toLowerCase().includes(t);if(!n&&!r&&!i&&!a)return!1}return!0}),b={ALL:t.length,INFO:t.filter(e=>e.level===`INFO`).length,WARNING:t.filter(e=>e.level===`WARNING`).length,ERROR:t.filter(e=>e.level===`ERROR`).length,DEBUG:t.filter(e=>e.level===`DEBUG`).length};return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card log-viewer-container`,children:[(0,H.jsxs)(`div`,{className:`log-viewer-header`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),` Diagnostics & Server Logs`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Inspect real-time server runtime events, tree-sitter AST parsing, background indexing, and MCP tool traces.`})]}),(0,H.jsxs)(`div`,{className:`log-viewer-actions`,children:[(0,H.jsxs)(`label`,{className:`log-autoscroll-label`,children:[(0,H.jsx)(`input`,{type:`checkbox`,checked:l,onChange:e=>u(e.target.checked)}),`Auto-scroll`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:h,disabled:r,title:`Refresh logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-rotate ${r?`fa-spin`:``}`}),` Refresh`]}),(0,H.jsxs)(`button`,{type:`button`,className:`btn btn-danger`,onClick:g,title:`Clear all logs`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-trash-can`}),` Clear Logs`]})]})]}),(0,H.jsxs)(`div`,{className:`log-toolbar`,children:[(0,H.jsx)(`div`,{className:`log-filter-pills`,children:[`ALL`,`INFO`,`WARNING`,`ERROR`,`DEBUG`].map(e=>(0,H.jsxs)(`button`,{type:`button`,className:`log-filter-btn ${a===e?`active`:``} ${e.toLowerCase()}`,onClick:()=>o(e),children:[e,` `,(0,H.jsx)(`span`,{className:`pill-count`,children:b[e]})]},e))}),(0,H.jsxs)(`div`,{className:`log-search-wrapper`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass search-icon`}),(0,H.jsx)(`input`,{type:`text`,className:`log-search-input`,placeholder:`Search logs by message, logger, or traceback...`,value:s,onChange:e=>c(e.target.value)}),s&&(0,H.jsx)(`button`,{type:`button`,className:`clear-search-btn`,onClick:()=>c(``),title:`Clear search`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-xmark`})})]})]}),(0,H.jsx)(`div`,{className:`log-stream-container`,ref:m,children:y.length===0?(0,H.jsxs)(`div`,{className:`empty-state`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-circle-info`,style:{fontSize:`2rem`,marginBottom:`12px`,opacity:.5}}),(0,H.jsxs)(`p`,{children:[`No logs available `,s||a!==`ALL`?`matching current filter`:``,`.`]})]}):(0,H.jsxs)(`div`,{className:`log-stream-list`,children:[y.map((e,t)=>{let n=!!e.traceback,r=d.has(t);return(0,H.jsxs)(`div`,{className:`log-entry log-level-${e.level.toLowerCase()} ${n?`has-traceback`:``}`,children:[(0,H.jsxs)(`div`,{className:`log-entry-main`,children:[(0,H.jsx)(`span`,{className:`log-timestamp`,children:e.timestamp}),(0,H.jsx)(`span`,{className:v(e.level),children:e.level}),(0,H.jsx)(`span`,{className:`log-logger code`,children:e.logger}),(0,H.jsx)(`span`,{className:`log-message`,children:e.message}),n&&(0,H.jsxs)(`button`,{type:`button`,className:`btn-traceback-toggle`,onClick:()=>_(t),title:`Toggle traceback details`,children:[(0,H.jsx)(`i`,{className:`fa-solid ${r?`fa-chevron-down`:`fa-chevron-right`}`}),(0,H.jsx)(`span`,{children:r?`Hide Stack Trace`:`View Stack Trace`})]})]}),n&&r&&(0,H.jsx)(`div`,{className:`log-traceback-wrapper`,children:(0,H.jsx)(`pre`,{className:`traceback-box`,children:e.traceback})})]},`${e.timestamp}-${t}`)}),(0,H.jsx)(`div`,{ref:p})]})})]})})}function Ot(e){switch(e){case`symbol`:return`badge-symbol`;case`code`:return`badge-code`;case`file`:return`badge-file`;case`route`:return`badge-route`;case`doc`:return`badge-doc`;default:return`badge-default`}}function kt({text:e,query:t}){if(!t||!t.trim()||!e)return(0,H.jsx)(H.Fragment,{children:e});let n=t.trim(),r=n.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`),i=RegExp(`(${r})`,`gi`),a=e.split(i);return a.length<=1?(0,H.jsx)(H.Fragment,{children:e}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`sr-only`,children:e}),(0,H.jsx)(`span`,{"aria-hidden":`true`,children:a.map((e,t)=>e.toLowerCase()===n.toLowerCase()?(0,H.jsx)(`mark`,{className:`nav-omni-match`,children:e},t):(0,H.jsx)(V.Fragment,{children:e},t))})]})}function At(e){if(!e)return``;let t=e.toLowerCase();return t.includes(`method`)?`method`:t.includes(`func`)?`func`:t.includes(`class`)?`class`:t.includes(`interface`)?`interface`:t.includes(`struct`)?`struct`:t.includes(`type`)?`type`:t.includes(`enum`)?`enum`:t.includes(`property`)||t.includes(`field`)?`prop`:t===`route`?`route`:t===`file`?`file`:t===`code`?`code`:t.replace(/_declaration|_definition|_specifier/g,``)}function jt(e){return e.includes(`://`)?e.split(`://`)[1]:e}var Mt=({repo:e,onSelectResult:t,placeholder:n=`Search files, symbols, routes, or code text...`})=>{let[r,i]=(0,V.useState)(``),[a,o]=(0,V.useState)([]),[s,c]=(0,V.useState)(!1),[l,u]=(0,V.useState)(!1),[d,f]=(0,V.useState)(-1),p=(0,V.useRef)(null),m=(0,V.useRef)(null),h=(0,V.useRef)(null);(0,V.useEffect)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`k`&&(e.preventDefault(),m.current?.focus(),m.current?.select())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[]),(0,V.useEffect)(()=>{let t=r.trim();if(!t){o([]),u(!1),f(-1);return}h.current&&h.current.abort();let n=new AbortController;h.current=n,c(!0);let i=setTimeout(async()=>{try{let r=await fetch(`/admin/api/navigator/omni-search?repo=${encodeURIComponent(e)}&q=${encodeURIComponent(t)}&limit=25`,{signal:n.signal});if(r.ok){let e=await r.json();o(e.matches||[]),u(!0),f(-1)}}catch(e){e.name!==`AbortError`&&console.error(`Omni-search error:`,e)}finally{c(!1)}},150);return()=>{clearTimeout(i),n.abort()}},[r,e]),(0,V.useEffect)(()=>{let e=e=>{p.current&&!p.current.contains(e.target)&&u(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[]);let g=e=>{if(!l||a.length===0){e.key===`ArrowDown`&&a.length>0&&u(!0);return}e.key===`ArrowDown`?(e.preventDefault(),f(e=>ee>0?e-1:a.length-1)):e.key===`Enter`?(e.preventDefault(),d>=0&&d{u(!1),i(``),o([]),t(e)},[t]);return(0,H.jsxs)(`div`,{className:`nav-omni-container`,ref:p,"data-testid":`navigator-omni-search`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-input-wrapper`,children:[(0,H.jsxs)(`svg`,{className:`nav-omni-search-icon`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]}),(0,H.jsx)(`input`,{ref:m,type:`text`,className:`nav-omni-input`,value:r,onChange:e=>i(e.target.value),onKeyDown:g,onFocus:()=>{a.length>0&&u(!0)},placeholder:n,"aria-label":`Omni-Search`,"aria-autocomplete":`list`,"aria-expanded":l}),!r&&(0,H.jsx)(`span`,{className:`nav-omni-kbd`,title:`Shortcut: Ctrl+K / ⌘K`,"aria-hidden":`true`,children:`Ctrl K`}),s&&(0,H.jsxs)(`svg`,{className:`nav-omni-spinner animate-spin`,"data-testid":`omni-search-spinner`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`,stroke:`rgba(8, 145, 178, 0.25)`,strokeWidth:`3`}),(0,H.jsx)(`path`,{d:`M12 2a10 10 0 0 1 10 10`,stroke:`var(--primary, #0891b2)`,strokeWidth:`3`,strokeLinecap:`round`})]}),r&&(0,H.jsx)(`button`,{type:`button`,className:`nav-omni-clear-btn`,onClick:()=>{i(``),o([]),u(!1),f(-1),m.current?.focus()},title:`Clear search`,"aria-label":`Clear Search`,children:`✕`})]}),l&&(0,H.jsxs)(`div`,{className:`nav-omni-dropdown`,"data-testid":`nav-omni-dropdown`,role:`listbox`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-dropdown-header`,children:[(0,H.jsxs)(`span`,{children:[`Matches (`,a.length,`)`]}),(0,H.jsx)(`span`,{className:`nav-omni-hint`,children:`↑↓ Navigate • Enter Select • Esc Close`})]}),a.length===0&&!s&&(0,H.jsxs)(`div`,{className:`nav-omni-empty`,children:[`No matching files, symbols, or code found for "`,r,`"`]}),(0,H.jsx)(`div`,{className:`nav-omni-list`,children:a.map((e,t)=>{let n=t===d,i=Ot(e.type),a=``,o=e.name;if(e.full_symbol&&e.full_symbol.includes(`.`)&&e.type===`symbol`){let t=e.full_symbol.lastIndexOf(`.`);a=e.full_symbol.substring(0,t+1),o=e.full_symbol.substring(t+1)}return(0,H.jsxs)(`div`,{className:`nav-omni-item ${n?`active`:``}`,onClick:()=>_(e),onMouseEnter:()=>f(t),role:`option`,"aria-selected":n,title:e.full_symbol||e.name,children:[(0,H.jsxs)(`div`,{className:`nav-omni-item-top`,children:[(0,H.jsxs)(`div`,{className:`nav-omni-item-title-group`,children:[(0,H.jsx)(`span`,{className:`nav-omni-badge ${i}`,children:e.type.toUpperCase()}),a&&(0,H.jsx)(`span`,{className:`nav-omni-item-container`,title:a,children:(0,H.jsx)(kt,{text:a,query:r})}),(0,H.jsx)(`span`,{className:`nav-omni-item-name`,title:e.full_symbol||e.name,children:(0,H.jsx)(kt,{text:o,query:r})}),e.kind&&e.kind!==e.type&&(0,H.jsx)(`span`,{className:`nav-omni-item-kind`,title:`Kind: ${e.kind}`,children:At(e.kind)})]}),(0,H.jsx)(`span`,{className:`nav-omni-score-pill`,title:e.score_label,children:e.score_label})]}),(0,H.jsxs)(`div`,{className:`nav-omni-item-bottom`,children:[(0,H.jsxs)(`span`,{className:`nav-omni-item-path`,title:e.filepath,children:[(0,H.jsx)(kt,{text:jt(e.filepath),query:r}),e.start_line>0&&(0,H.jsxs)(`span`,{className:`nav-omni-line-badge`,children:[`:`,e.start_line]})]}),e.preview&&e.preview!==e.name&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`nav-omni-sep`,"aria-hidden":`true`,children:`•`}),(0,H.jsx)(`span`,{className:`nav-omni-item-preview`,title:e.preview,children:(0,H.jsx)(kt,{text:e.preview,query:r})})]})]})]},e.id)})})]})]})},Nt=({repos:e,selectedRepo:t,onSelectRepo:n,density:r,onChangeDensity:i,searchQuery:a=``,onSearchChange:o,onSelectSearchResult:s,totalFiles:c=0,totalSymbols:l=0,onRefresh:u,loading:d=!1})=>(0,H.jsxs)(`div`,{className:`nav-toolbar nav-toolbar-single-row`,"data-testid":`navigator-toolbar`,children:[(0,H.jsxs)(`div`,{className:`nav-toolbar-left`,children:[(0,H.jsxs)(`div`,{className:`nav-repo-selector-wrapper`,children:[(0,H.jsx)(`label`,{htmlFor:`nav-repo-select`,className:`nav-repo-label`,children:`Repository:`}),(0,H.jsxs)(`select`,{id:`nav-repo-select`,"aria-label":`Repository`,className:`nav-repo-select`,value:t,onChange:e=>n(e.target.value),disabled:d,children:[(0,H.jsx)(`option`,{value:`__all__`,children:`All Repositories (__all__)`}),e.filter(e=>e.name!==`__all__`).map(e=>(0,H.jsx)(`option`,{value:e.name,children:e.name},e.id??e.name))]})]}),(0,H.jsxs)(`div`,{className:`nav-stats-badges`,children:[(0,H.jsxs)(`span`,{className:`nav-stat-badge`,title:`Total Indexed Files`,children:[(0,H.jsx)(`span`,{className:`stat-num`,children:c}),` files`]}),(0,H.jsxs)(`span`,{className:`nav-stat-badge`,title:`Total Extracted AST Symbols`,children:[(0,H.jsx)(`span`,{className:`stat-num`,children:l}),` symbols`]})]})]}),(0,H.jsx)(`div`,{className:`nav-toolbar-center`,children:s?(0,H.jsx)(Mt,{repo:t,onSelectResult:s}):o?(0,H.jsxs)(`div`,{className:`nav-global-search`,children:[(0,H.jsx)(`span`,{className:`search-icon-wrapper`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{className:`search-icon`,width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`circle`,{cx:`11`,cy:`11`,r:`8`}),(0,H.jsx)(`line`,{x1:`21`,y1:`21`,x2:`16.65`,y2:`16.65`})]})}),(0,H.jsx)(`input`,{type:`text`,className:`nav-search-input`,placeholder:`Search files (Ctrl+P / /)...`,value:a,onChange:e=>o(e.target.value),"aria-label":`Quick search files`}),a&&(0,H.jsx)(`button`,{type:`button`,className:`nav-search-clear-btn`,onClick:()=>o(``),"aria-label":`Clear search`,children:`✕`})]}):null}),(0,H.jsxs)(`div`,{className:`nav-toolbar-right`,children:[(0,H.jsxs)(`div`,{className:`nav-density-switcher`,role:`group`,"aria-label":`Density mode`,children:[(0,H.jsx)(`span`,{className:`density-label`,children:`Density:`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`compact`?`active`:``}`,onClick:()=>i(`compact`),title:`Compact (20px rows - IDE mode)`,"aria-pressed":r===`compact`,children:`Compact`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`balanced`?`active`:``}`,onClick:()=>i(`balanced`),title:`Balanced (28px rows - Default)`,"aria-pressed":r===`balanced`,children:`Balanced`}),(0,H.jsx)(`button`,{type:`button`,className:`density-btn ${r===`spacious`?`active`:``}`,onClick:()=>i(`spacious`),title:`Spacious (36px rows - Cards)`,"aria-pressed":r===`spacious`,children:`Spacious`})]}),u&&(0,H.jsx)(`button`,{type:`button`,className:`nav-refresh-btn ${d?`spinning`:``}`,onClick:u,title:`Refresh codebase tree`,disabled:d,"aria-label":`Refresh codebase tree`,children:(0,H.jsx)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,H.jsx)(`path`,{d:`M21.5 2v6h-6M21.34 15.57a10 10 0 1 1-.57-8.38l5.67-5.67`})})})]})]}),Pt=({repo:e,path:t,symbol:n,onNavigatePath:r,canGoBack:i,canGoForward:a,onGoBack:o,onGoForward:s,onToggleSidebar:c,isSidebarOpen:l})=>{let[u,d]=(0,V.useState)(!1),f=V.useMemo(()=>t?t.replace(/\\/g,`/`).replace(/^[^/]+:\/\//,``).replace(/^\/+/,``).split(`/`).filter(Boolean):[],[t]);return(0,H.jsxs)(`div`,{className:`nav-breadcrumbs-bar`,"data-testid":`navigator-breadcrumbs`,children:[(0,H.jsxs)(`div`,{className:`nav-breadcrumbs-left`,children:[(0,H.jsx)(`button`,{type:`button`,className:`nav-breadcrumb-btn nav-sidebar-toggle-btn`,onClick:c,title:l?`Collapse Sidebar (Ctrl+B)`:`Expand Sidebar (Ctrl+B)`,"aria-label":l?`Collapse Sidebar`:`Expand Sidebar`,children:(0,H.jsxs)(`svg`,{width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`rect`,{x:`3`,y:`3`,width:`18`,height:`18`,rx:`2`,ry:`2`}),(0,H.jsx)(`line`,{x1:`9`,y1:`3`,x2:`9`,y2:`21`})]})}),(0,H.jsxs)(`div`,{className:`nav-history-controls`,role:`group`,"aria-label":`Navigation History`,children:[(0,H.jsx)(`button`,{type:`button`,className:`nav-history-btn`,onClick:o,disabled:!i,title:`Go Back`,"aria-label":`Go Back`,children:(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`15 18 9 12 15 6`})})}),(0,H.jsx)(`button`,{type:`button`,className:`nav-history-btn`,onClick:s,disabled:!a,title:`Go Forward`,"aria-label":`Go Forward`,children:(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`9 18 15 12 9 6`})})})]}),(0,H.jsxs)(`nav`,{className:`nav-breadcrumb-trail`,"aria-label":`Breadcrumb`,children:[(0,H.jsxs)(`span`,{className:`breadcrumb-repo-badge`,title:`Repository`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`line`,{x1:`6`,y1:`3`,x2:`6`,y2:`15`}),(0,H.jsx)(`circle`,{cx:`18`,cy:`6`,r:`3`}),(0,H.jsx)(`circle`,{cx:`6`,cy:`18`,r:`3`}),(0,H.jsx)(`path`,{d:`M18 9a9 9 0 0 1-9 9`})]}),(0,H.jsx)(`span`,{className:`crumb-repo-text`,children:e})]}),f.length>0&&(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`/`}),f.map((e,t)=>{let i=t===f.length-1&&!n,a=f.slice(0,t+1).join(`/`);return(0,H.jsxs)(V.Fragment,{children:[t>0&&(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`/`}),(0,H.jsx)(`button`,{type:`button`,className:`breadcrumb-segment ${i?`active`:``}`,onClick:()=>r(a),title:`Navigate to ${a}`,children:e})]},a)}),n&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`breadcrumb-separator`,children:`#`}),(0,H.jsx)(`span`,{className:`breadcrumb-symbol-badge`,title:`Active Symbol: ${n}`,children:n})]})]})]}),t&&(0,H.jsx)(`div`,{className:`nav-breadcrumbs-right`,children:(0,H.jsx)(`button`,{type:`button`,className:`nav-breadcrumb-btn nav-permalink-btn ${u?`copied`:``}`,onClick:async()=>{if(!t)return;let e=`${t}${n?`#${n}`:``}`;try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(e),d(!0),setTimeout(()=>d(!1),2e3))}catch{}},title:`Copy path permalink`,"aria-label":`Copy Permalink`,children:u?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),(0,H.jsx)(`span`,{children:`Copied!`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`}),(0,H.jsx)(`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`})]}),(0,H.jsx)(`span`,{children:`Copy Link`})]})})})]})};function Ft(e,t){let n=e.toLowerCase();return n.endsWith(`.py`)||t===`python`?{faClass:`fa-brands fa-python`,className:`icon-py`}:n.endsWith(`.tsx`)||n.endsWith(`.ts`)||t===`typescript`?{faClass:`fa-brands fa-js`,className:`icon-ts`}:n.endsWith(`.jsx`)||n.endsWith(`.js`)||n.endsWith(`.mjs`)||t===`javascript`?{faClass:`fa-brands fa-square-js`,className:`icon-js`}:n.endsWith(`.go`)||t===`go`?{faClass:`fa-solid fa-g`,className:`icon-go`}:n.endsWith(`.rs`)||t===`rust`?{faClass:`fa-solid fa-gear`,className:`icon-rs`}:n.endsWith(`.cs`)||t===`csharp`?{faClass:`fa-brands fa-microsoft`,className:`icon-cs`}:n.endsWith(`.json`)?{faClass:`fa-solid fa-brackets-curly`,className:`icon-json`}:n.endsWith(`.md`)||n.endsWith(`.markdown`)?{faClass:`fa-solid fa-file-lines`,className:`icon-md`}:n.endsWith(`.css`)||n.endsWith(`.scss`)?{faClass:`fa-brands fa-css3-alt`,className:`icon-css`}:n.endsWith(`.html`)||n.endsWith(`.htm`)?{faClass:`fa-brands fa-html5`,className:`icon-html`}:n.endsWith(`.sql`)||n.endsWith(`.psql`)||n.endsWith(`.pls`)||n.endsWith(`.plsql`)||n.endsWith(`.ddl`)||n.endsWith(`.dml`)||n.endsWith(`.cql`)||t===`sql`?{faClass:`fa-solid fa-database`,className:`icon-sql`}:n.endsWith(`.yaml`)||n.endsWith(`.yml`)||n.endsWith(`.toml`)?{faClass:`fa-solid fa-sliders`,className:`icon-yaml`}:n.endsWith(`.sh`)||n.endsWith(`.bash`)||n.endsWith(`.zsh`)?{faClass:`fa-solid fa-terminal`,className:`icon-sh`}:n.endsWith(`.dockerfile`)||n===`dockerfile`?{faClass:`fa-brands fa-docker`,className:`icon-docker`}:n.endsWith(`.cbl`)||n.endsWith(`.cob`)||n.endsWith(`.cpy`)||n.endsWith(`.cobol`)||t===`cobol`?{faClass:`fa-solid fa-server`,className:`icon-cobol`}:{faClass:`fa-solid fa-file-code`,className:`icon-file`}}var It=({nodes:e,selectedPath:t,onSelectFile:n,filterText:r,onFilterChange:i,density:a=`balanced`,loading:o=!1,repo:s,autoExpandRoot:c=!1})=>{let[l,u]=(0,V.useState)(``),d=r===void 0?l:r,f=i||u,p=`cc_nav_expanded_${s||`all`}`,[m,h]=(0,V.useState)(()=>{try{let e=sessionStorage.getItem(p);if(e){let t=JSON.parse(e);if(Array.isArray(t)&&t.length>0)return new Set(t)}}catch{}return new Set});(0,V.useEffect)(()=>{try{sessionStorage.setItem(p,JSON.stringify(Array.from(m)))}catch{}},[m,p]),(0,V.useEffect)(()=>{try{let e=sessionStorage.getItem(`cc_nav_expanded_${s||`all`}`);if(e){let t=JSON.parse(e);Array.isArray(t)&&t.length>0&&h(new Set(t))}}catch{}},[s]),(0,V.useEffect)(()=>{c&&e&&e.length>0&&h(t=>{if(t.size===0){let n=e.filter(e=>e.is_dir).map(e=>e.id);return n.length>0?new Set(n):t}return t})},[e,c]);let[g,_]=(0,V.useState)(-1),v=(0,V.useRef)(null),y=(0,V.useCallback)(e=>{let t=[],n=e=>{if(!(!e||!Array.isArray(e)))for(let r of e)r&&r.is_dir&&(t.push(r.id),Array.isArray(r.children)&&n(r.children))};return n(e),t},[]),b=(0,V.useCallback)((e,t)=>{if(!e||!Array.isArray(e))return{filteredNodes:[],matchedDirIds:new Set};let n=t.toLowerCase().trim(),r=new Set,i=e=>{if(!e)return null;let t=(e.name||``).toLowerCase().includes(n)||(e.path||``).toLowerCase().includes(n);if(e.is_dir){let n=Array.isArray(e.children)?e.children:[],a=n.map(i).filter(e=>e!==null);return a.length>0||t?(r.add(e.id),{...e,children:a.length>0?a:n}):null}return t?e:null};return{filteredNodes:e.map(i).filter(e=>e!==null),matchedDirIds:r}},[]),{filteredNodes:x,matchedDirIds:S}=(0,V.useMemo)(()=>d.trim()?b(e,d):{filteredNodes:Array.isArray(e)?e:[],matchedDirIds:new Set},[e,d,b]);(0,V.useEffect)(()=>{d.trim()&&h(e=>{let t=new Set(e);return S.forEach(e=>t.add(e)),t})},[d,S]),(0,V.useEffect)(()=>{if(t){let e=t.split(`/`),n=[];for(let t=1;t0&&h(e=>{let t=new Set(e);return n.forEach(e=>t.add(e)),t})}},[t]);let C=(0,V.useCallback)(e=>{h(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},[]),w=(0,V.useCallback)(()=>{let t=y(e);h(new Set(t))},[e,y]),T=(0,V.useCallback)(()=>{h(new Set)},[]),E=(0,V.useMemo)(()=>{let e=[],t=!!d.trim(),n=(r,i)=>{if(!(!r||!Array.isArray(r)))for(let a of r){if(!a)continue;let r=!!(a.is_dir&&Array.isArray(a.children)&&a.children.length>0),o=m.has(a.id)||t&&S.has(a.id);e.push({node:a,depth:i,isExpanded:o,hasChildren:r}),a.is_dir&&o&&Array.isArray(a.children)&&n(a.children,i+1)}};return n(x,0),e},[x,m,d,S]);return(0,H.jsxs)(`div`,{className:`nav-tree-pane density-${a}`,"data-testid":`navigator-tree-container`,tabIndex:0,ref:v,onKeyDown:e=>{if(E.length!==0){if(e.key===`ArrowDown`)e.preventDefault(),_(e=>ee>0?e-1:E.length-1);else if(e.key===`ArrowRight`){if(e.preventDefault(),g>=0&&g=0&&g=0&&gf(e.target.value)}),d&&(0,H.jsx)(`button`,{type:`button`,className:`nav-tree-clear-btn`,onClick:()=>f(``),"aria-label":`Clear filter`,children:`✕`})]})]}),(0,H.jsx)(`div`,{className:`nav-tree-content`,children:o?(0,H.jsxs)(`div`,{className:`nav-loading-wrapper`,"data-testid":`tree-loading-spinner`,children:[(0,H.jsx)(`div`,{className:`nav-spinner`}),(0,H.jsx)(`span`,{children:`Loading codebase tree...`})]}):E.length===0?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`p`,{children:`No matching files found`}),d&&(0,H.jsx)(`button`,{type:`button`,className:`nav-clear-filter-btn`,onClick:()=>f(``),children:`Clear filter`})]}):(0,H.jsx)(`div`,{className:`nav-tree-list`,role:`tree`,children:E.map((e,r)=>{let{node:i,depth:a,isExpanded:o}=e,s=!i.is_dir&&i.path===t,c=r===g,l=o?`fa-solid fa-folder-open`:`fa-solid fa-folder`,{faClass:u,className:d}=i.is_dir?{faClass:l,className:`icon-dir`}:Ft(i.name,i.language);return(0,H.jsxs)(`div`,{role:`treeitem`,"aria-expanded":i.is_dir?o:void 0,"aria-selected":s,className:`nav-tree-item ${i.is_dir?`dir-item`:`file-item`} ${s?`selected`:``} ${c?`focused`:``}`,style:{paddingLeft:`${a*14+10}px`},onClick:()=>{_(r),i.is_dir?C(i.id):n(i)},children:[(0,H.jsx)(`span`,{className:`tree-chevron`,children:i.is_dir?(0,H.jsx)(`span`,{className:`chevron-arrow ${o?`open`:``}`,children:`▶`}):(0,H.jsx)(`span`,{className:`chevron-spacer`})}),(0,H.jsx)(`span`,{className:`tree-icon ${d}`,"aria-hidden":`true`,children:(0,H.jsx)(`i`,{className:u})}),(0,H.jsx)(`span`,{className:`tree-label`,title:i.path,children:i.name}),(0,H.jsxs)(`div`,{className:`tree-badges`,children:[i.symbol_count>0&&(0,H.jsxs)(`span`,{className:`badge-symbols`,title:`${i.symbol_count} AST Symbols`,children:[i.symbol_count,` sym`]}),i.route_count>0&&(0,H.jsxs)(`span`,{className:`badge-routes`,title:`${i.route_count} API Routes`,children:[i.route_count,` rts`]})]})]},i.id)})})})]})};function Lt(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Rt=Lt();function zt(e){Rt=e}var Bt={exec:()=>null};function Vt(e){let t=[];return n=>{let r=Math.max(0,Math.min(3,n-1)),i=t[r];return i||(i=e(r),t[r]=i),i}}function W(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(Ut.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var Ht=((e=``)=>{try{return!!RegExp(`(?<=1)(?/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:Vt(e=>RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:Vt(e=>RegExp(`^ {0,${e}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:Vt(e=>RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),headingBeginRegex:Vt(e=>RegExp(`^ {0,${e}}#`)),htmlBeginRegex:Vt(e=>RegExp(`^ {0,${e}}(?:)|<(?:script|pre|style|textarea|!--))`,`i`)),blockquoteBeginRegex:Vt(e=>RegExp(`^ {0,${e}}>`))},Wt=/^(?:[ \t]*(?:\n|$))+/,Gt=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,Kt=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,qt=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Jt=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Yt=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,Xt=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Zt=W(Xt).replace(/bull/g,Yt).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),Qt=W(Xt).replace(/bull/g,Yt).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),$t=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,en=/^[^\n]+/,tn=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,nn=W(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,tn).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),rn=W(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,Yt).getRegex(),an=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,on=/|$))/,sn=W(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|[^\\n]*\\n*|$)|[^\\n]*\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][a-z0-9-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,on).replace(`tag`,an).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),cn=e=>W($t).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,e).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex(),ln=cn(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),un=cn(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),dn={blockquote:W(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,un).getRegex(),code:Gt,def:nn,fences:Kt,heading:Jt,hr:qt,html:sn,lheading:Zt,list:rn,newline:Wt,paragraph:ln,table:Bt,text:en},fn=W(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex(),pn={...dn,lheading:Qt,table:fn,paragraph:W($t).replace(`hr`,qt).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,fn).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]`).replace(`html`,`)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,an).getRegex()},mn={...dn,html:W(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,on).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Bt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:W($t).replace(`hr`,qt).replace(`heading`,` *#{1,6} *[^ +]`).replace(`lheading`,Zt).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},hn=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,gn=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,_n=/^( {2,}|\\)\n(?!\s*$)[ \t]*/,vn=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,Ht?"(?`+)[^`]+\k(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),On=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,kn=W(On,`u`).replace(/punct/g,yn).getRegex(),An=W(On,`u`).replace(/punct/g,wn).getRegex(),jn=W(/^(?:\*+(?:((?!\*)(?!openQuote)punct)|([^\s*]))?)|^_+(?:((?!_)(?!openQuote)punct)|([^\s_]))?/,`u`).replace(/openQuote/g,Cn).replace(/punct/g,yn).getRegex(),Mn=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,Nn=W(Mn,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Pn=W(Mn,`gu`).replace(/notPunctSpace/g,En).replace(/punctSpace/g,Tn).replace(/punct/g,wn).getRegex(),Fn=W(`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)[\\s](\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|(?:(?!\\*)punct|notPunctSpace)(\\*+)(?!\\*)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),In=W(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Ln=W(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)[\\s](_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)|(?:(?!_)punct|notPunctSpace)(_+)(?!_)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Rn=W(/^~~?(?:((?!~)punct)|[^\s~])/,`u`).replace(/punct/g,yn).getRegex(),zn=W(`^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,xn).replace(/punctSpace/g,bn).replace(/punct/g,yn).getRegex(),Bn=W(/\\(punct)/,`gu`).replace(/punct/g,yn).getRegex(),Vn=W(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Hn=W(on).replace(`(?:-->|$)`,`-->`).getRegex(),Un=W(`^comment|^|^<[a-zA-Z][a-zA-Z0-9-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^`).replace(`comment`,Hn).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Wn=/\[(?:\\[\s\S]|[^\[\]\\])*\]/,Gn=W(/(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/).replace(`brackets`,Wn).getRegex(),Kn=W(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace(`label`,Gn).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]+|(?=\))/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),qn=W(/^!?\[(label)\]\[(ref)\]/).replace(`label`,Gn).replace(`ref`,tn).getRegex(),Jn=W(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,tn).getRegex(),Yn=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\]){1,999}/,Xn=W(/(?:[^\[\]\\`]*(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\]))){0,999}?[^\[\]\\`]*?/).replace(`brackets`,Wn).getRegex(),Zn=W(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,W(/^!?\[(label)\]\[(ref)\]/).replace(`label`,Xn).replace(`ref`,Yn).getRegex()).replace(`nolink`,W(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,Yn).getRegex()).getRegex(),Qn=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,$n=W(/(?:mailto:email|xmpp:email(?:\/[A-Za-z0-9@.]+)?)/).replace(/email/g,/[A-Za-z0-9._+-]+@[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),er={_backpedal:Bt,anyPunctuation:Bn,autolink:Vn,blockSkip:Dn,br:_n,code:gn,del:Bt,delLDelim:Bt,delRDelim:Bt,emStrongLDelim:kn,emStrongRDelimAst:Nn,emStrongRDelimUnd:In,escape:hn,link:Kn,nolink:Jn,punctuation:Sn,reflink:qn,reflinkSearch:Zn,tag:Un,text:vn,url:Bt},tr={...er,emStrongLDelim:jn,emStrongRDelimAst:Fn,emStrongRDelimUnd:Ln,link:W(/^!?\[(label)\]\((.*?)\)/).replace(`label`,Gn).getRegex(),reflink:W(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,Gn).getRegex()},nr={...er,emStrongRDelimAst:Pn,emStrongLDelim:An,delLDelim:Rn,delRDelim:zn,url:W(/^emailProtocol|^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`emailProtocol`,$n).replace(`protocol`,Qn).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:W(/^(?:[^a-zA-Z0-9](?=emailProtocol)|(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":`>`,'"':`"`,"'":`'`},sr=e=>or[e];function cr(e,t){if(t){if(Ut.escapeTest.test(e))return e.replace(Ut.escapeReplace,sr)}else if(Ut.escapeTestNoEncode.test(e))return e.replace(Ut.escapeReplaceNoEncode,sr);return e}function lr(e){return e.replace(Ut.numericCharacterReference,(e,t,n)=>{let r=t===void 0?Number.parseInt(n,16):Number.parseInt(t,10);return r===0||r>1114111||r>=55296&&r<=57343?`�`:String.fromCodePoint(r)})}function ur(e){try{e=encodeURI(e).replace(Ut.percentDecode,`%`)}catch{return null}return e}function dr(e,t){let n=e.replace(Ut.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(Ut.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t){if(n.length>t)n.splice(t);else for(;n.length=0&&Ut.blankLine.test(t[n]);)n--;return t.length-n<=2?e:t.slice(0,n+1).join(` +`)}function mr(e){return e.trim().toLowerCase().toUpperCase().toLowerCase()}function hr(e,t){if(e.indexOf(t[1])===-1)return-1;let n=0;for(let r=0;r0?-2:-1}function gr(e,t=0){let n=t,r=``;for(let t of e)if(t===` `){let e=4-n%4;r+=` `.repeat(e),n+=e}else r+=t,n++;return r}function _r(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`),c=e[0].charAt(0)===`!`;r.state.inLink=!0;let l=r.state.linkEmitted,u=r.state.inRawBlock;r.state.linkEmitted=!1;let d=r.inlineTokens(s),f=r.state.linkEmitted;if(r.state.linkEmitted=l,r.state.inLink=!1,!c){if(f){r.state.inRawBlock=u;return}r.state.linkEmitted=!0}return{type:c?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:d}}function vr(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(` +`).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return e.slice(Math.min(r.length,i.length))}).join(` +`)}function yr(e,t,n,r){if(!t.includes(`<`))return!1;for(let i=0;it.length-i)return!0;i+=o[0].length-1}}return!1}var br=class{options;rules;lexer;constructor(e){this.options=e||Rt}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=this.options.pedantic?t[0]:pr(t[0]);return{type:`code`,raw:e,codeBlockStyle:`indented`,text:e.replace(this.rules.other.codeRemoveIndent,``)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=vr(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=fr(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceTabChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:fr(t[0],` +`),depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:fr(t[0],` +`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=fr(t[0],` +`).split(` +`),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o;for(o=0;o0&&(n=`${n} +${d.join(` +`)}`),r=r.substring(0,r.length-t.text.length)+s.text;break}if(u?.type===`list`){let t=u,a=t.raw+` +`+e.join(` +`),o=this.list(a);i[i.length-1]=o,n=n.substring(0,n.length-u.raw.length)+o.raw,r=r.substring(0,r.length-t.raw.length)+o.raw,e=a.substring(i.at(-1).raw.length).split(` +`);continue}}return{type:`blockquote`,raw:n,tokens:i,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=t[2].split(` +`,1)[0],l=t[1].length,u=this.options.pedantic?gr(c,l):c.replace(this.rules.other.leadingSpaceTab,e=>gr(e,l)),d=e.split(` +`,1)[0],f=!u.trim(),p=0;if(this.options.pedantic?(p=2,s=u.trimStart()):f?p=l+1:(p=u.search(this.rules.other.nonSpaceChar),p=p>4?1:p,s=u.slice(p),p+=l),f&&this.rules.other.blankLine.test(d)&&(r+=d+` +`,e=e.substring(d.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(p),n=this.rules.other.hrRegex(p),i=this.rules.other.fencesBeginRegex(p),a=this.rules.other.headingBeginRegex(p),o=this.rules.other.htmlBeginRegex(p),c=this.rules.other.blockquoteBeginRegex(p);for(;e;){let l=e.split(` +`,1)[0],m;if(d=l,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting,` `),m=d):m=d.replace(this.rules.other.leadingSpaceTab,e=>e.replace(this.rules.other.tabCharGlobal,` `)),i.test(d)||a.test(d)||o.test(d)||c.test(d)||t.test(d)||n.test(d))break;if(m.search(this.rules.other.nonSpaceChar)>=p||!d.trim())s+=` +`+m.slice(p);else{if(f||u.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(u)||a.test(u)||n.test(u))break;s+=` +`+d}f=!d.trim(),r+=l+` +`,e=e.substring(l.length+1),u=m.slice(p)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0)),i.items.push({type:`list_item`,raw:r,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e of i.items)if(this.lexer.state.top=!1,e.tokens=this.lexer.blockTokens(e.text,[]),!i.loose){let t=e.tokens.filter(e=>e.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}for(let e of i.items){let t=e.tokens[0];if(e.task&&(t?.type===`text`||t?.type===`paragraph`)){e.text=e.text.replace(this.rules.other.listReplaceTask,``),t.raw=t.raw.replace(this.rules.other.listReplaceTask,``),t.text=t.text.replace(this.rules.other.listReplaceTask,``);for(let e=this.lexer.inlineQueue.length-1;e>=0;e--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)){this.lexer.inlineQueue[e].src=this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask,``);break}let n=this.rules.other.listTaskCheckbox.exec(e.raw);if(n){let t={type:`checkbox`,raw:n[0]+` `,checked:n[0]!==`[ ]`};e.checked=t.checked,i.loose?e.tokens[0]&&[`paragraph`,`text`].includes(e.tokens[0].type)&&`tokens`in e.tokens[0]&&e.tokens[0].tokens?(e.tokens[0].raw=t.raw+e.tokens[0].raw,e.tokens[0].text=t.raw+e.tokens[0].text,e.tokens[0].tokens.unshift(t)):e.tokens.unshift({type:`paragraph`,raw:t.raw,text:t.raw,tokens:[t]}):e.tokens.unshift(t)}}else e.task&&=!1}if(i.loose)for(let e of i.items){e.loose=!0;for(let t of e.tokens)t.type===`text`&&(t.type=`paragraph`)}return i}}html(e){let t=this.rules.block.html.exec(e);if(t){let e=pr(t[0]);return{type:`html`,block:!0,raw:e,pre:t[1]===`pre`||t[1]===`script`||t[1]===`style`,text:e}}}def(e){let t=this.rules.block.def.exec(e);if(t){let e=mr(t[1]).replace(this.rules.other.multipleSpaceGlobal,` `),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,`$1`).replace(this.rules.inline.anyPunctuation,`$1`):``,r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,`$1`):t[3];return{type:`def`,tag:e,raw:fr(t[0],` +`),href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=dr(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,``).split(`|`),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,``).split(` +`):[],a={type:`table`,raw:fr(t[0],` +`),header:[],align:[],rows:[]};if(n.length===r.length){for(let e of r)this.rules.other.tableAlignRight.test(e)?a.align.push(`right`):this.rules.other.tableAlignCenter.test(e)?a.align.push(`center`):this.rules.other.tableAlignLeft.test(e)?a.align.push(`left`):a.align.push(null);for(let e=0;e({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t){let e=t[1].trim();return{type:`heading`,raw:fr(t[0],` +`),depth:t[2].charAt(0)===`=`?1:2,text:e,tokens:this.lexer.inline(e)}}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&yr(e,t[1],n,this.rules))return;let r=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let e=fr(r.slice(0,-1),`\\`);if((r.length-e.length)%2==0)return}else{let e=hr(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let i=t[2],a=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(i);e&&(i=e[1],a=e[3])}else a=t[3]?t[3].slice(1,-1):``;return i=i.trim(),this.rules.other.startAngleBracket.test(i)&&(i=this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?i.slice(1):i.slice(1,-1)),_r(t,{href:i&&i.replace(this.rules.inline.anyPunctuation,`$1`),title:a&&a.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let r=n[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&yr(e,n[1],r,this.rules))return;let i=t[mr((n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `))];if(!i){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return _r(n,i,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||!r[1]&&!r[2]&&!r[3]&&!r[4]||r[4]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[3])||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,a,o,s=i,c=0,l=r[0][0],u=n===l,d=l===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(d.lastIndex=0,t=t.slice(-1*e.length+i);(r=d.exec(t))!==null;){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(o=[...a].length,r[3]||r[4]){s+=o;continue}if(r[5]||r[6]){if(i%3&&!((i+o)%3)){c+=o;continue}if(u)break}if(s-=o,s>0)continue;o=Math.min(o,o+s+c);let t=[...r[0]][0].length,n=e.slice(0,i+r.index+t+o);if(Math.min(i,o)%2){let e=n.slice(1,-1);return{type:`em`,raw:n,text:e,tokens:this.lexer.inlineTokens(e)}}let l=n.slice(2,-2);return{type:`strong`,raw:n,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e,t,n=``){let r=this.rules.inline.delLDelim.exec(e);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=this.rules.inline.delRDelim;for(s.lastIndex=0,t=t.slice(-1*e.length+n);(r=s.exec(t))!==null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i||(a=[...i].length,a!==n))continue;if(r[3]||r[4]){o+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o);let t=[...r[0]][0].length,s=e.slice(0,n+r.index+t+a),c=s.slice(n,-n);return{type:`del`,raw:s,text:c,tokens:this.lexer.inlineTokens(c)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:e?t[0]:lr(t[0]),escaped:e}}}},xr=class e{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Rt,this.options.tokenizer=this.options.tokenizer||new br,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,linkEmitted:!1,top:!0};let t={other:Ut,block:ir.normal,inline:ar.normal};this.options.pedantic?(t.block=ir.pedantic,t.inline=ar.pedantic):this.options.gfm&&(t.block=ir.gfm,t.inline=this.options.breaks?ar.breaks:ar.gfm),this.tokenizer.rules=t}static get rules(){return{block:ir,inline:ar}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(Ut.carriageReturn,` +`),this.blockTokens(e,this.tokens);for(let e=0;e(i=n.call({lexer:this},e,t))?(e=e.substring(i.raw.length),t.push(i),!0):!1))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);let n=t.at(-1);i.raw.length===1&&n!==void 0?n.raw+=` +`:t.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.text,this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title},t.push(i));continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),t.push(i);continue}let a=e;if(this.options.extensions?.startBlock){let t=1/0,n=e.slice(1),r;this.options.extensions.startBlock.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(a=e.substring(0,t+1))}if(this.state.top&&(i=this.tokenizer.paragraph(a))){let r=t.at(-1);n&&r?.type===`paragraph`?(r.raw+=(r.raw.endsWith(` +`)?``:` +`)+i.raw,r.text+=` +`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(i),n=a.length!==e.length,e=e.substring(i.raw.length);continue}if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(` +`)?``:` +`)+i.raw,n.text+=` +`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}linkInText(e){if(!e.includes(`[`))return!1;let t=this.tokenizer.rules.inline.link;for(let n of e.matchAll(this.tokenizer.rules.inline.blockSkip))if(t.test(n[0])&&e.charAt(n.index-1)!==`!`)return!0;for(let t of e.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let e=t[0],n=e.lastIndexOf(`[`);if(!(e.charAt(0)===`!`||!Object.hasOwn(this.tokens.links,mr(e.slice(n+1,-1))))&&!(n>1&&this.linkInText(e.slice(1,n-1))))return!0}return!1}inlineTokens(e,t=[]){this.tokenizer.lexer=this;let n=e;if(this.tokens.links&&e.includes(`[`)){let e=this.tokenizer.rules.inline.reflinkSearch,t=n=>{let r=n.lastIndexOf(`[`);if(!Object.hasOwn(this.tokens.links,mr(n.slice(r+1,-1))))return n;if(r>1&&n.charAt(0)!==`!`){let i=n.slice(1,r-1);if(this.linkInText(i))return`[`+i.replace(e,t)+`][`+`a`.repeat(n.length-r-2)+`]`}return`[`+`a`.repeat(n.length-2)+`]`};n=n.replace(e,t)}n=n.replace(this.tokenizer.rules.inline.anyPunctuation,e=>`+`.repeat(e.length)),n=n.replace(this.tokenizer.rules.inline.blockSkip,(e,t,n)=>{let r=n?n.length:0;return e.slice(0,r)+`[`+`a`.repeat(e.length-r-2)+`]`}),n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let r=!1,i=``,a=1/0;for(;e;){if(e.length(o=n.call({lexer:this},e,t))?(e=e.substring(o.raw.length),t.push(o),!0):!1))continue;if(o=this.tokenizer.escape(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.tag(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.link(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(o.raw.length);let n=t.at(-1);o.type===`text`&&n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(o=this.tokenizer.emStrong(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.codespan(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.br(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.del(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.autolink(e)){e=e.substring(o.raw.length),t.push(o);continue}if(!this.state.inLink&&(o=this.tokenizer.url(e))){e=e.substring(o.raw.length),t.push(o);continue}let s=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(o=this.tokenizer.inlineText(s)){e=e.substring(o.raw.length),o.raw.slice(-1)!==`_`&&(i=o.raw.slice(-1)),r=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return t}infiniteLoopError(e){let t=`Infinite loop on byte: `+e;if(this.options.silent)console.error(t);else throw Error(t)}},Sr=class{options;parser;constructor(e){this.options=e||Rt}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(Ut.notSpaceStart)?.[0],i=e?e.replace(Ut.endingNewline,``)+` +`:``;return r?`
    `+(n?i:cr(i,!0))+`
    +`:`
    `+(n?i:cr(i,!0))+`
    +`}blockquote({tokens:e}){return`
    +${this.parser.parse(e)}
    +`}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`${this.parser.parseInline(e)} +`}hr(e){return`
    +`}list(e){let t=e.ordered,n=e.start,r=``;for(let t=0;t +`+r+` +`}listitem(e){return`
  • ${this.parser.parse(e.tokens)}
  • +`}checkbox({checked:e}){return` `}paragraph({tokens:e}){return`

    ${this.parser.parseInline(e)}

    +`}table(e){let t=``,n=``;for(let t=0;t${r}`,` + +`+t+` +`+r+`
    +`}tablerow({text:e}){return` +${e} +`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+` +`}strong({tokens:e}){return`${this.parser.parseInline(e)}`}em({tokens:e}){return`${this.parser.parseInline(e)}`}codespan({text:e}){return`${cr(e,!0)}`}br(e){return`
    `}del({tokens:e}){return`${this.parser.parseInline(e)}`}link({href:e,title:t,text:n,tokens:r,autolink:i}){let a=i?cr(n,!0):this.parser.parseInline(r),o=ur(e);if(o===null)return a;e=cr(o,i);let s=`
    `+a+``,s}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=ur(e);if(i===null)return cr(n);e=i;let a=`${cr(n)}`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:cr(e.text)}},Cr=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}checkbox({raw:e}){return e}},wr=class e{options;renderer;textRenderer;constructor(e){this.options=e||Rt,this.options.renderer=this.options.renderer||new Sr,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Cr}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e){this.renderer.parser=this;let t=``;for(let n=0;n{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new Sr(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new br(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new Tr;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];t[r]=Tr.passThroughHooks.has(n)?e=>{if(this.defaults.async&&Tr.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return xr.lex(e,t??this.defaults)}parser(e,t){return wr.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer(e):e?xr.lex:xr.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser(e):e?wr.parse:wr.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer(e):e?xr.lex:xr.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser(e):e?wr.parse:wr.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=` +Please report this to https://github.com/markedjs/marked.`,e){let e=`

    An error occurred:

    `+cr(n.message+``,!0)+`
    `;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}},Dr=new Er;function Or(e,t){return Dr.parse(e,t)}Or.options=Or.setOptions=function(e){return Dr.setOptions(e),Or.defaults=Dr.defaults,zt(Or.defaults),Or},Or.getDefaults=Lt,Or.defaults=Rt;function kr(...e){return Dr.use(...e),Or.defaults=Dr.defaults,zt(Or.defaults),Or}Or.use=kr,Or.walkTokens=function(e,t){return Dr.walkTokens(e,t)},Or.parseInline=Dr.parseInline,Or.Parser=wr,Or.parser=wr.parse,Or.Renderer=Sr,Or.TextRenderer=Cr,Or.Lexer=xr,Or.lexer=xr.lex,Or.Tokenizer=br,Or.Hooks=Tr,Or.parse=Or,Or.options,Or.setOptions,Or.walkTokens,Or.parseInline,wr.parse,xr.lex;var Ar=a(e=>{let{securityLevel:t}=I(),n=r(`body`);if(t===`sandbox`){let t=r(`#i${e}`).node()?.contentDocument??document;n=r(t.body)}return n.select(`#${e}`)},`selectSvgElement`);function jr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,`default`)?e.default:e}a(jr,`getDefaultExportFromCjs`);var Mr={},Nr={},Pr={},Fr;function Ir(){if(Fr)return Pr;Fr=1;function e(e){return e==null}a(e,`isNothing`);function t(e){return typeof e==`object`&&!!e}a(t,`isObject`);function n(t){return Array.isArray(t)?t:e(t)?[]:[t]}a(n,`toArray`);function r(e,t){if(t){let n=Object.keys(t);for(let r=0,i=n.length;rs&&(a=` ... `,t=r-s+a.length),n-r>s&&(o=` ...`,n=r+s-o.length),{str:a+e.slice(t,n).replace(/\t/g,`→`)+o,pos:r-t+a.length}}a(t,`getLine`);function n(t,n){return e.repeat(` `,n-t.length)+t}a(n,`padStart`);function r(r,i){if(i=Object.create(i||null),!r.buffer)return null;i.maxLength||(i.maxLength=79),typeof i.indent!=`number`&&(i.indent=1),typeof i.linesBefore!=`number`&&(i.linesBefore=3),typeof i.linesAfter!=`number`&&(i.linesAfter=2);let a=/\r?\n|\r|\0/g,o=[0],s=[],c,l=-1;for(;c=a.exec(r.buffer);)s.push(c.index),o.push(c.index+c[0].length),r.position<=c.index&&l<0&&(l=o.length-2);l<0&&(l=o.length-1);let u=``,d=Math.min(r.line+i.linesAfter,s.length).toString().length,f=i.maxLength-(i.indent+d+3);for(let a=1;a<=i.linesBefore&&!(l-a<0);a++){let c=t(r.buffer,o[l-a],s[l-a],r.position-(o[l]-o[l-a]),f);u=e.repeat(` `,i.indent)+n((r.line-a+1).toString(),d)+` | `+c.str+` +`+u}let p=t(r.buffer,o[l],s[l],r.position,f);u+=e.repeat(` `,i.indent)+n((r.line+1).toString(),d)+` | `+p.str+` +`,u+=e.repeat(`-`,i.indent+d+3+p.pos)+`^ +`;for(let a=1;a<=i.linesAfter&&!(l+a>=s.length);a++){let c=t(r.buffer,o[l+a],s[l+a],r.position-(o[l]-o[l+a]),f);u+=e.repeat(` `,i.indent)+n((r.line+a+1).toString(),d)+` | `+c.str+` +`}return u.replace(/\n$/,``)}return a(r,`makeSnippet`),Br=r,Br}a(Hr,`requireSnippet`);var Ur,Wr;function Gr(){if(Wr)return Ur;Wr=1;let e=zr(),t=[`kind`,`multi`,`resolve`,`construct`,`instanceOf`,`predicate`,`represent`,`representName`,`defaultStyle`,`styleAliases`],n=[`scalar`,`sequence`,`mapping`];function r(e){let t={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(e){t[String(e)]=n})}),t}a(r,`compileStyleAliases`);function i(i,a){if(a||={},Object.keys(a).forEach(function(n){if(t.indexOf(n)===-1)throw new e(`Unknown option "`+n+`" is met in definition of "`+i+`" YAML type.`)}),this.options=a,this.tag=i,this.kind=a.kind||null,this.resolve=a.resolve||function(){return!0},this.construct=a.construct||function(e){return e},this.instanceOf=a.instanceOf||null,this.predicate=a.predicate||null,this.represent=a.represent||null,this.representName=a.representName||null,this.defaultStyle=a.defaultStyle||null,this.multi=a.multi||!1,this.styleAliases=r(a.styleAliases||null),n.indexOf(this.kind)===-1)throw new e(`Unknown kind "`+this.kind+`" is specified for "`+i+`" YAML type.`)}return a(i,`Type2`),Ur=i,Ur}a(Gr,`requireType`);var Kr,qr;function Jr(){if(qr)return Kr;qr=1;let e=zr(),t=Gr();function n(e,t){let n=[];return e[t].forEach(function(e){let t=n.length;n.forEach(function(n,r){n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=r)}),n[t]=e}),n}a(n,`compileList`);function r(){let e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function t(t){t.multi?(e.multi[t.kind].push(t),e.multi.fallback.push(t)):e[t.kind][t.tag]=e.fallback[t.tag]=t}a(t,`collectType`);for(let e=0,n=arguments.length;e=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}a(n,`isHexCode`);function r(e){return e>=48&&e<=55}a(r,`isOctCode`);function i(e){return e>=48&&e<=57}a(i,`isDecCode`);function o(e){if(e===null)return!1;let t=e.length,a=0,o=!1;if(!t)return!1;let c=e[a];if((c===`-`||c===`+`)&&(c=e[++a]),c===`0`){if(a+1===t)return!0;if(c=e[++a],c===`b`){for(a++;a=0?`0b`+e.toString(2):`-0b`+e.toString(2).slice(1)},`binary`),octal:a(function(e){return e>=0?`0o`+e.toString(8):`-0o`+e.toString(8).slice(1)},`octal`),decimal:a(function(e){return e.toString(10)},`decimal`),hexadecimal:a(function(e){return e>=0?`0x`+e.toString(16).toUpperCase():`-0x`+e.toString(16).toUpperCase().slice(1)},`hexadecimal`)},defaultStyle:`decimal`,styleAliases:{binary:[2,`bin`],octal:[8,`oct`],decimal:[10,`dec`],hexadecimal:[16,`hex`]}}),pi}a(hi,`requireInt`);var gi,_i;function vi(){if(_i)return gi;_i=1;let e=Ir(),t=Gr(),n=RegExp(`^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$`),r=RegExp(`^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$`);function i(e){return e===null||!n.test(e)?!1:isFinite(parseFloat(e,10))?!0:r.test(e)}a(i,`resolveYamlFloat`);function o(e){let t=e.toLowerCase(),n=t[0]===`-`?-1:1;return`+-`.indexOf(t[0])>=0&&(t=t.slice(1)),t===`.inf`?n===1?1/0:-1/0:t===`.nan`?NaN:n*parseFloat(t,10)}a(o,`constructYamlFloat`);let s=/^[-+]?[0-9]+e/;function c(t,n){if(isNaN(t))switch(n){case`lowercase`:return`.nan`;case`uppercase`:return`.NAN`;case`camelcase`:return`.NaN`}else if(t===1/0)switch(n){case`lowercase`:return`.inf`;case`uppercase`:return`.INF`;case`camelcase`:return`.Inf`}else if(t===-1/0)switch(n){case`lowercase`:return`-.inf`;case`uppercase`:return`-.INF`;case`camelcase`:return`-.Inf`}else if(e.isNegativeZero(t))return`-0.0`;let r=t.toString(10);return s.test(r)?r.replace(`e`,`.e`):r}a(c,`representYamlFloat`);function l(t){return Object.prototype.toString.call(t)===`[object Number]`&&(t%1!=0||e.isNegativeZero(t))}return a(l,`isFloat`),gi=new t(`tag:yaml.org,2002:float`,{kind:`scalar`,resolve:i,construct:o,predicate:l,represent:c,defaultStyle:`lowercase`}),gi}a(vi,`requireFloat`);var yi,bi;function xi(){return bi?yi:(bi=1,yi=oi().extend({implicit:[li(),fi(),hi(),vi()]}),yi)}a(xi,`requireJson`);var Si,Ci;function wi(){return Ci?Si:(Ci=1,Si=xi(),Si)}a(wi,`requireCore`);var Ti,Ei;function Di(){if(Ei)return Ti;Ei=1;let e=Gr(),t=RegExp(`^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$`),n=RegExp(`^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$`);function r(e){return e===null?!1:t.exec(e)!==null||n.exec(e)!==null}a(r,`resolveYamlTimestamp`);function i(e){let r=0,i=null,a=t.exec(e);if(a===null&&(a=n.exec(e)),a===null)throw Error(`Date resolve error`);let o=+a[1],s=a[2]-1,c=+a[3];if(!a[4])return new Date(Date.UTC(o,s,c));let l=+a[4],u=+a[5],d=+a[6];if(a[7]){for(r=a[7].slice(0,3);r.length<3;)r+=`0`;r=+r}if(a[9]){let e=+a[10],t=+(a[11]||0);i=(e*60+t)*6e4,a[9]===`-`&&(i=-i)}let f=new Date(Date.UTC(o,s,c,l,u,d,r));return i&&f.setTime(f.getTime()-i),f}a(i,`constructYamlTimestamp`);function o(e){return e.toISOString()}return a(o,`representYamlTimestamp`),Ti=new e(`tag:yaml.org,2002:timestamp`,{kind:`scalar`,resolve:r,construct:i,instanceOf:Date,represent:o}),Ti}a(Di,`requireTimestamp`);var Oi,G;function ki(){if(G)return Oi;G=1;let e=Gr();function t(e){return e===`<<`||e===null}return a(t,`resolveYamlMerge`),Oi=new e(`tag:yaml.org,2002:merge`,{kind:`scalar`,resolve:t}),Oi}a(ki,`requireMerge`);var Ai,ji;function Mi(){if(ji)return Ai;ji=1;let e=Gr();function t(e){if(e===null)return!1;let t=0,n=e.length;for(let r=0;r64)){if(n<0)return!1;t+=6}}return t%8==0}a(t,`resolveYamlBinary`);function n(e){let t=e.replace(/[\r\n=]/g,``),n=t.length,r=0,i=[];for(let e=0;e>16&255),i.push(r>>8&255),i.push(r&255)),r=r<<6|`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`.indexOf(t.charAt(e));let a=n%4*6;return a===0?(i.push(r>>16&255),i.push(r>>8&255),i.push(r&255)):a===18?(i.push(r>>10&255),i.push(r>>2&255)):a===12&&i.push(r>>4&255),new Uint8Array(i)}a(n,`constructYamlBinary`);function r(e){let t=``,n=0,r=e.length,i=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`;for(let a=0;a>18&63],t+=i[n>>12&63],t+=i[n>>6&63],t+=i[n&63]),n=(n<<8)+e[a];let a=r%3;return a===0?(t+=i[n>>18&63],t+=i[n>>12&63],t+=i[n>>6&63],t+=i[n&63]):a===2?(t+=i[n>>10&63],t+=i[n>>4&63],t+=i[n<<2&63],t+=i[64]):a===1&&(t+=i[n>>2&63],t+=i[n<<4&63],t+=i[64],t+=i[64]),t}a(r,`representYamlBinary`);function i(e){return Object.prototype.toString.call(e)===`[object Uint8Array]`}return a(i,`isBinary`),Ai=new e(`tag:yaml.org,2002:binary`,{kind:`scalar`,resolve:t,construct:n,predicate:i,represent:r}),Ai}a(Mi,`requireBinary`);var Ni,Pi;function Fi(){if(Pi)return Ni;Pi=1;let e=Gr(),t=Object.prototype.hasOwnProperty,n=Object.prototype.toString;function r(e){if(e===null)return!0;let r=[],i=e;for(let e=0,a=i.length;e=48&&e<=57)return e-48;let t=e|32;return t>=97&&t<=102?t-97+10:-1}a(g,`fromHexCode`);function _(e){return e===120?2:e===117?4:e===85?8:0}a(_,`escapedHexLen`);function v(e){return e>=48&&e<=57?e-48:-1}a(v,`fromDecimalCode`);function y(e){switch(e){case 48:return`\0`;case 97:return`\x07`;case 98:return`\b`;case 116:return` `;case 9:return` `;case 110:return` +`;case 118:return`\v`;case 102:return`\f`;case 114:return`\r`;case 101:return`\x1B`;case 32:return` `;case 34:return`"`;case 47:return`/`;case 92:return`\\`;case 78:return`…`;case 95:return`\xA0`;case 76:return`\u2028`;case 80:return`\u2029`;default:return``}}a(y,`simpleEscapeSequence`);function b(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}a(b,`charFromCodepoint`);function x(e,t,n){t===`__proto__`?Object.defineProperty(e,t,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[t]=n}a(x,`setProperty`);let S=Array(256),C=Array(256);for(let e=0;e<256;e++)S[e]=+!!y(e),C[e]=y(e);function w(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||r,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.maxDepth=typeof t.maxDepth==`number`?t.maxDepth:100,this.maxTotalMergeKeys=typeof t.maxTotalMergeKeys==`number`?t.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}a(w,`State`);function T(e,r){let i={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return i.snippet=n(i),new t(r,i)}a(T,`generateError`);function E(e,t){throw T(e,t)}a(E,`throwError`);function D(e,t){e.onWarning&&e.onWarning.call(null,T(e,t))}a(D,`throwWarning`);function O(e,t,n){let r=e.anchorMapTransactions;if(r.length!==0){let n=r[r.length-1];i.call(n,t)||(n[t]={existed:i.call(e.anchorMap,t),value:e.anchorMap[t]})}e.anchorMap[t]=n}a(O,`storeAnchor`);function k(e){e.anchorMapTransactions.push(Object.create(null))}a(k,`beginAnchorTransaction`);function A(e){let t=e.anchorMapTransactions.pop(),n=e.anchorMapTransactions;if(n.length===0)return;let r=n[n.length-1],a=Object.keys(t);for(let e=0,n=a.length;e=0;--r){let i=t[n[r]];i.existed?e.anchorMap[n[r]]=i.value:delete e.anchorMap[n[r]]}}a(j,`rollbackAnchorTransaction`);function M(e){return{position:e.position,line:e.line,lineStart:e.lineStart,lineIndent:e.lineIndent,firstTabInLine:e.firstTabInLine,tag:e.tag,anchor:e.anchor,kind:e.kind,result:e.result}}a(M,`snapshotState`);function N(e,t){e.position=t.position,e.line=t.line,e.lineStart=t.lineStart,e.lineIndent=t.lineIndent,e.firstTabInLine=t.firstTabInLine,e.tag=t.tag,e.anchor=t.anchor,e.kind=t.kind,e.result=t.result}a(N,`restoreState`);let P={YAML:a(function(e,t,n){e.version!==null&&E(e,`duplication of %YAML directive`),n.length!==1&&E(e,`YAML directive accepts exactly one argument`);let r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]);r===null&&E(e,`ill-formed argument of the YAML directive`);let i=parseInt(r[1],10),a=parseInt(r[2],10);i!==1&&E(e,`unacceptable YAML version of the document`),e.version=n[0],e.checkLineBreaks=a<2,a!==1&&a!==2&&D(e,`unsupported YAML version of the document`)},`handleYamlDirective`),TAG:a(function(e,t,n){let r;n.length!==2&&E(e,`TAG directive accepts exactly two arguments`);let a=n[0];r=n[1],l.test(a)||E(e,`ill-formed tag handle (first argument) of the TAG directive`),i.call(e.tagMap,a)&&E(e,`there is a previously declared suffix for "`+a+`" tag handle`),u.test(r)||E(e,`ill-formed tag prefix (second argument) of the TAG directive`);try{r=decodeURIComponent(r)}catch{E(e,`tag prefix is malformed: `+r)}e.tagMap[a]=r},`handleTagDirective`)};function F(e,t,n,r){if(t=32&&n<=1114111||E(e,`expected valid JSON character`)}else o.test(i)&&E(e,`the stream contains non-printable characters`);e.result+=i}}a(F,`captureSegment`);function I(t,n,r,a){e.isObject(r)||E(t,`cannot merge mappings; the provided source object is unacceptable`);let o=Object.keys(r);for(let e=0,s=o.length;et.maxTotalMergeKeys&&E(t,`merge keys exceeded maxTotalMergeKeys (`+t.maxTotalMergeKeys+`)`),i.call(n,s)||(x(n,s,r[s]),a[s]=!0)}}a(I,`mergeMappings`);function L(e,t,n,r,a,o,s,c,l){if(Array.isArray(a)){a=Array.prototype.slice.call(a);for(let t=0,n=a.length;t1&&(t.result+=e.repeat(` +`,n-1))}a(ee,`writeFoldedLines`);function te(e,t,n){let r,i,a,o,s,c,l=e.kind,u=e.result,d=e.input.charCodeAt(e.position);if(m(d)||h(d)||d===35||d===38||d===42||d===33||d===124||d===62||d===39||d===34||d===37||d===64||d===96)return!1;if(d===63||d===45){let t=e.input.charCodeAt(e.position+1);if(m(t)||n&&h(t))return!1}for(e.kind=`scalar`,e.result=``,r=i=e.position,a=!1;d!==0;){if(d===58){let t=e.input.charCodeAt(e.position+1);if(m(t)||n&&h(t))break}else if(d===35){if(m(e.input.charCodeAt(e.position-1)))break}else if(e.position===e.lineStart&&B(e)||n&&h(d))break;else if(f(d)){if(o=e.line,s=e.lineStart,c=e.lineIndent,z(e,!1,-1),e.lineIndent>=t){a=!0,d=e.input.charCodeAt(e.position);continue}e.position=i,e.line=o,e.lineStart=s,e.lineIndent=c;break}a&&=(F(e,r,i,!1),ee(e,e.line-o),r=i=e.position,!1),p(d)||(i=e.position+1),d=e.input.charCodeAt(++e.position)}return F(e,r,i,!1),e.result?!0:(e.kind=l,e.result=u,!1)}a(te,`readPlainScalar`);function ne(e,t){let n,r,i=e.input.charCodeAt(e.position);if(i!==39)return!1;for(e.kind=`scalar`,e.result=``,e.position++,n=r=e.position;(i=e.input.charCodeAt(e.position))!==0;)if(i===39){if(F(e,n,e.position,!0),i=e.input.charCodeAt(++e.position),i===39)n=e.position,e.position++,r=e.position;else return!0}else f(i)?(F(e,n,r,!0),ee(e,z(e,!1,t)),n=r=e.position):e.position===e.lineStart&&B(e)?E(e,`unexpected end of the document within a single quoted scalar`):(e.position++,p(i)||(r=e.position));E(e,`unexpected end of the stream within a single quoted scalar`)}a(ne,`readSingleQuotedScalar`);function re(e,t){let n,r,i,a=e.input.charCodeAt(e.position);if(a!==34)return!1;for(e.kind=`scalar`,e.result=``,e.position++,n=r=e.position;(a=e.input.charCodeAt(e.position))!==0;)if(a===34)return F(e,n,e.position,!0),e.position++,!0;else if(a===92){if(F(e,n,e.position,!0),a=e.input.charCodeAt(++e.position),f(a))z(e,!1,t);else if(a<256&&S[a])e.result+=C[a],e.position++;else if((i=_(a))>0){let t=i,n=0;for(;t>0;t--)a=e.input.charCodeAt(++e.position),(i=g(a))>=0?n=(n<<4)+i:E(e,`expected hexadecimal character`);e.result+=b(n),e.position++}else E(e,`unknown escape sequence`);n=r=e.position}else f(a)?(F(e,n,r,!0),ee(e,z(e,!1,t)),n=r=e.position):e.position===e.lineStart&&B(e)?E(e,`unexpected end of the document within a double quoted scalar`):(e.position++,p(a)||(r=e.position));E(e,`unexpected end of the stream within a double quoted scalar`)}a(re,`readDoubleQuotedScalar`);function ie(e,t){let n=!0,r,i,a,o=e.tag,s,c=e.anchor,l,u,d,f,p=Object.create(null),h,g,_,v=e.input.charCodeAt(e.position);if(v===91)l=93,f=!1,s=[];else if(v===123)l=125,f=!0,s={};else return!1;for(e.anchor!==null&&O(e,e.anchor,s),v=e.input.charCodeAt(++e.position);v!==0;){if(z(e,!0,t),v=e.input.charCodeAt(e.position),v===l)return e.position++,e.tag=o,e.anchor=c,e.kind=f?`mapping`:`sequence`,e.result=s,!0;n?v===44&&E(e,`expected the node content, but found ','`):E(e,`missed comma between flow collection entries`),g=h=_=null,u=d=!1,v===63&&m(e.input.charCodeAt(e.position+1))&&(u=d=!0,e.position++,z(e,!0,t)),r=e.line,i=e.lineStart,a=e.position,fe(e,t,1,!1,!0),g=e.tag,h=e.result,z(e,!0,t),v=e.input.charCodeAt(e.position),(d||e.line===r)&&v===58&&(u=!0,v=e.input.charCodeAt(++e.position),z(e,!0,t),fe(e,t,1,!1,!0),_=e.result),f?L(e,s,p,g,h,_,r,i,a):u?s.push(L(e,null,p,g,h,_,r,i,a)):s.push(h),z(e,!0,t),v=e.input.charCodeAt(e.position),v===44?(n=!0,v=e.input.charCodeAt(++e.position)):n=!1}E(e,`unexpected end of the stream within a flow collection`)}a(ie,`readFlowCollection`);function ae(t,n){let r,i=1,a=!1,o=!1,s=n,c=0,l=!1,u,d=t.input.charCodeAt(t.position);if(d===124)r=!1;else if(d===62)r=!0;else return!1;for(t.kind=`scalar`,t.result=``;d!==0;)if(d=t.input.charCodeAt(++t.position),d===43||d===45)i===1?i=d===43?3:2:E(t,`repeat of a chomping mode identifier`);else if((u=v(d))>=0)u===0?E(t,`bad explicit indentation width of a block scalar; it cannot be less than one`):o?E(t,`repeat of an indentation width identifier`):(s=n+u-1,o=!0);else break;if(p(d)){do d=t.input.charCodeAt(++t.position);while(p(d));if(d===35)do d=t.input.charCodeAt(++t.position);while(!f(d)&&d!==0)}for(;d!==0;){for(R(t),t.lineIndent=0,d=t.input.charCodeAt(t.position);(!o||t.lineIndents&&(s=t.lineIndent),f(d)){c++;continue}if(!o&&s===0&&E(t,`missing indentation for block scalar`),t.lineIndentt)&&o!==0)E(e,`bad indentation of a sequence entry`);else if(e.lineIndentt)&&(g&&(i=e.line,a=e.lineStart,o=e.position),fe(e,t,4,!0,r)&&(g?f=e.result:h=e.result),g||(L(e,l,u,d,f,h,i,a,o),d=f=h=null),z(e,!0,-1),v=e.input.charCodeAt(e.position)),(e.line===b||e.lineIndent>t)&&v!==0)E(e,`bad indentation of a mapping entry`);else if(e.lineIndent=e.maxDepth&&E(e,`nesting exceeded maxDepth (`+e.maxDepth+`)`),e.depth+=1,e.listener!==null&&e.listener(`open`,e),e.tag=null,e.anchor=null,e.kind=null,e.result=null;let h=o=s=n===4||n===3;if(r&&z(e,!0,-1)&&(l=!0,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndentt?c=1:e.lineIndent===t?c=0:e.lineIndent tag; it should be "scalar", not "`+e.kind+`"`);for(let t=0,n=e.implicitTypes.length;t`),e.result!==null&&f.kind!==e.kind&&E(e,`unacceptable node kind for !<`+e.tag+`> tag; it should be "`+f.kind+`", not "`+e.kind+`"`),f.resolve(e.result,e.tag)?(e.result=f.construct(e.result,e.tag),e.anchor!==null&&O(e,e.anchor,e.result)):E(e,`cannot resolve a node with !<`+e.tag+`> explicit tag`)}return e.listener!==null&&e.listener(`close`,e),--e.depth,e.tag!==null||e.anchor!==null||u}a(fe,`composeNode`);function pe(e){let t=e.position,n=!1,r;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(r=e.input.charCodeAt(e.position))!==0&&(z(e,!0,-1),r=e.input.charCodeAt(e.position),!(e.lineIndent>0||r!==37));){n=!0,r=e.input.charCodeAt(++e.position);let t=e.position;for(;r!==0&&!m(r);)r=e.input.charCodeAt(++e.position);let a=e.input.slice(t,e.position),o=[];for(a.length<1&&E(e,`directive name must not be less than one character in length`);r!==0;){for(;p(r);)r=e.input.charCodeAt(++e.position);if(r===35){do r=e.input.charCodeAt(++e.position);while(r!==0&&!f(r));break}if(f(r))break;for(t=e.position;r!==0&&!m(r);)r=e.input.charCodeAt(++e.position);o.push(e.input.slice(t,e.position))}r!==0&&R(e),i.call(P,a)?P[a](e,a,o):D(e,`unknown document directive "`+a+`"`)}if(z(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,z(e,!0,-1)):n&&E(e,`directives end mark is expected`),fe(e,e.lineIndent-1,4,!1,!0),z(e,!0,-1),e.checkLineBreaks&&s.test(e.input.slice(t,e.position))&&D(e,`non-ASCII line breaks are interpreted as content`),e.documents.push(e.result),e.position===e.lineStart&&B(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,z(e,!0,-1));return}e.position=32&&e<=126||e>=161&&e<=55295&&e!==8232&&e!==8233||e>=57344&&e<=65533&&e!==o||e>=65536&&e<=1114111}a(_,`isPrintable`);function v(e){return _(e)&&e!==o&&e!==13&&e!==10}a(v,`isNsCharOrWhitespace`);function y(e,t,n){let r=v(e),i=r&&!g(e);return(n?r:r&&e!==44&&e!==91&&e!==93&&e!==123&&e!==125)&&e!==35&&!(t===58&&!i)||v(t)&&!g(t)&&e===35||t===58&&i}a(y,`isPlainSafe`);function b(e){return _(e)&&e!==o&&!g(e)&&e!==45&&e!==63&&e!==58&&e!==44&&e!==91&&e!==93&&e!==123&&e!==125&&e!==35&&e!==38&&e!==42&&e!==33&&e!==124&&e!==61&&e!==62&&e!==39&&e!==34&&e!==37&&e!==64&&e!==96}a(b,`isPlainSafeFirst`);function x(e){return!g(e)&&e!==58}a(x,`isPlainSafeLast`);function S(e,t){let n=e.charCodeAt(t),r;return n>=55296&&n<=56319&&t+1=56320&&r<=57343)?(n-55296)*1024+r-56320+65536:n}a(S,`codePointAt`);function C(e){return/^\n* /.test(e)}a(C,`needIndentIndicator`);function w(e,t,n,r,i,a,o,s){let c,l=0,u=null,d=!1,f=!1,p=r!==-1,m=-1,h=b(S(e,0))&&x(S(e,e.length-1));if(t||o)for(c=0;c=65536?c+=2:c++){if(l=S(e,c),!_(l))return 5;h&&=y(l,u,s),u=l}else{for(c=0;c=65536?c+=2:c++){if(l=S(e,c),l===10)d=!0,p&&(f||=c-m-1>r&&e[m+1]!==` `,m=c);else if(!_(l))return 5;h&&=y(l,u,s),u=l}f||=p&&c-m-1>r&&e[m+1]!==` `}return!d&&!f?h&&!o&&!i(e)?1:a===2?5:2:n>9&&C(e)?5:o?a===2?5:2:f?4:3}a(w,`chooseScalarStyle`);function T(e,n,r,i,o){e.dump=(function(){if(n.length===0)return e.quotingType===2?`""`:`''`;if(!e.noCompatMode&&(c.indexOf(n)!==-1||l.test(n)))return e.quotingType===2?`"`+n+`"`:`'`+n+`'`;let s=e.indent*Math.max(1,r),u=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-s),d=i||e.flowLevel>-1&&r>=e.flowLevel;function f(t){return h(e,t)}switch(a(f,`testAmbiguity`),w(n,d,e.indent,u,f,e.quotingType,e.forceQuotes&&!i,o)){case 1:return n;case 2:return`'`+n.replace(/'/g,`''`)+`'`;case 3:return`|`+E(n,e.indent)+D(p(n,s));case 4:return`>`+E(n,e.indent)+D(p(O(n,u),s));case 5:return`"`+A(n)+`"`;default:throw new t(`impossible error: invalid scalar style`)}})()}a(T,`writeScalar`);function E(e,t){let n=C(e)?String(t):``,r=e[e.length-1]===` +`;return n+(r&&(e[e.length-2]===` +`||e===` +`)?`+`:r?``:`-`)+` +`}a(E,`blockHeader`);function D(e){return e[e.length-1]===` +`?e.slice(0,-1):e}a(D,`dropEndingNewline`);function O(e,t){let n=/(\n+)([^\n]*)/g,r=(function(){let r=e.indexOf(` +`);return r=r===-1?e.length:r,n.lastIndex=r,k(e.slice(0,r),t)})(),i=e[0]===` +`||e[0]===` `,a,o;for(;o=n.exec(e);){let e=o[1],n=o[2];a=n[0]===` `,r+=e+(!i&&!a&&n!==``?` +`:``)+k(n,t),i=a}return r}a(O,`foldString`);function k(e,t){if(e===``||e[0]===` `)return e;let n=/ [^ ]/g,r,i=0,a,o=0,s=0,c=``;for(;r=n.exec(e);)s=r.index,s-i>t&&(a=o>i?o:s,c+=` +`+e.slice(i,a),i=a+1),o=s;return c+=` +`,e.length-i>t&&o>i?c+=e.slice(i,o)+` +`+e.slice(o+1):c+=e.slice(i),c.slice(1)}a(k,`foldLine`);function A(e){let t=``,n=0;for(let r=0;r=65536?r+=2:r++){n=S(e,r);let i=s[n];!i&&_(n)?(t+=e[r],n>=65536&&(t+=e[r+1])):t+=i||d(n)}return t}a(A,`escapeString`);function j(e,t,n){let r=``,i=e.tag;for(let i=0,a=n.length;i1024&&(o+=`? `),o+=e.dump+(e.condenseFlow?`"`:``)+`:`+(e.condenseFlow?``:` `),I(e,t,c,!1,!1)&&(o+=e.dump,r+=o))}e.tag=i,e.dump=`{`+r+`}`}a(N,`writeFlowMapping`);function P(e,n,r,i){let a=``,o=e.tag,s=Object.keys(r);if(e.sortKeys===!0)s.sort();else if(typeof e.sortKeys==`function`)s.sort(e.sortKeys);else if(e.sortKeys)throw new t(`sortKeys must be a boolean or a function`);for(let t=0,o=s.length;t1024;u&&(e.dump&&e.dump.charCodeAt(0)===10?o+=`?`:o+=`? `),o+=e.dump,u&&(o+=m(e,n)),I(e,n+1,l,!0,u)&&(e.dump&&e.dump.charCodeAt(0)===10?o+=`:`:o+=`: `,o+=e.dump,a+=o)}e.tag=o,e.dump=a||`{}`}a(P,`writeBlockMapping`);function F(e,n,a){let o=a?e.explicitTypes:e.implicitTypes;for(let s=0,c=o.length;s tag resolver accepts not "`+a+`" style`);e.dump=o}return!0}}return!1}a(F,`detectType`);function I(e,n,i,a,o,s,c){e.tag=null,e.dump=i,F(e,i,!1)||F(e,i,!0);let l=r.call(e.dump),u=a;a&&=e.flowLevel<0||e.flowLevel>n;let d=l===`[object Object]`||l===`[object Array]`,f,p;if(d&&(f=e.duplicates.indexOf(i),p=f!==-1),(e.tag!==null&&e.tag!==`?`||p||e.indent!==2&&n>0)&&(o=!1),p&&e.usedDuplicates[f])e.dump=`*ref_`+f;else{if(d&&p&&!e.usedDuplicates[f]&&(e.usedDuplicates[f]=!0),l===`[object Object]`)a&&Object.keys(e.dump).length!==0?(P(e,n,e.dump,o),p&&(e.dump=`&ref_`+f+e.dump)):(N(e,n,e.dump),p&&(e.dump=`&ref_`+f+` `+e.dump));else if(l===`[object Array]`)a&&e.dump.length!==0?(e.noArrayIndent&&!c&&n>0?M(e,n-1,e.dump,o):M(e,n,e.dump,o),p&&(e.dump=`&ref_`+f+e.dump)):(j(e,n,e.dump),p&&(e.dump=`&ref_`+f+` `+e.dump));else if(l===`[object String]`)e.tag!==`?`&&T(e,e.dump,n,s,u);else if(l===`[object Undefined]`)return!1;else{if(e.skipInvalid)return!1;throw new t(`unacceptable kind of an object to dump `+l)}if(e.tag!==null&&e.tag!==`?`){let t=encodeURI(e.tag[0]===`!`?e.tag.slice(1):e.tag).replace(/!/g,`%21`);t=e.tag[0]===`!`?`!`+t:t.slice(0,18)===`tag:yaml.org,2002:`?`!!`+t.slice(18):`!<`+t+`>`,e.dump=t+` `+e.dump}}return!0}a(I,`writeNode`);function L(e,t){let n=[],r=[];R(e,n,r);let i=r.length;for(let e=0;e{let{theme:n,themeVariables:r}=t,{useGradient:i,gradientStart:o,gradientStop:s}=r??{},c=e.attr(`id`),l=n?.includes(`dark`)?`#FFFFFF`:`#000000`,u=a((t,n,r)=>e.append(`defs`).append(`filter`).attr(`id`,t).attr(`height`,n).attr(`width`,n).append(`feDropShadow`).attr(`dx`,r).attr(`dy`,r).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,l),`dropShadow`);if(u(`${c}-drop-shadow`,`130%`,`4`),u(`${c}-drop-shadow-small`,`150%`,`2`),!i)return;let d=e.append(`linearGradient`).attr(`id`,`${c}-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);d.append(`svg:stop`).attr(`offset`,`0%`).attr(`stop-color`,o).attr(`stop-opacity`,1),d.append(`svg:stop`).attr(`offset`,`100%`).attr(`stop-color`,s).attr(`stop-opacity`,1)},`insertLookDefs`);function pa(e){let t=e?.constructor;return e===(typeof t==`function`?t.prototype:Object.prototype)}function ma(e){if(e==null)return!0;if(ve(e))return typeof e.splice!=`function`&&typeof e!=`string`&&!ee(e)&&!_e(e)&&!ye(e)?!1:e.length===0;if(typeof e==`object`||typeof e==`function`){if(e instanceof Map||e instanceof Set)return e.size===0;let t=Object.keys(e);return pa(e)?t.filter(e=>e!==`constructor`).length===0:t.length===0}return!0}var ha=a(async(e,t)=>{let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,d=l,{labelStyles:f,nodeStyles:p,borderStyles:m,backgroundStyles:h}=Se(t),g=e.insert(`g`).attr(`class`,`cluster swimlane `+(t.cssClasses||``)).attr(`id`,t.id).attr(`data-id`,t.id).attr(`data-et`,`cluster`).attr(`data-look`,t.look);ke(g,t.colorIndex,a,u);let _=E(i.flowchart.htmlLabels),v=t.direction===`LR`,y=g.insert(`g`).attr(`class`,`cluster-label swimlane-label`),b=await De(y,t.label,{style:t.labelStyle,useHtmlLabels:_,isNode:!0,width:t.width}),x=b.getBBox();if(_){let e=b.children[0],t=r(b);x=e.getBoundingClientRect(),t.attr(`width`,x.width),t.attr(`height`,x.height)}let S=t.padding??0,C=t.width<=x.width+S?x.width+S:t.width;t.diff=t.width<=x.width+S?(C-t.width)/2-S:-S;let w=t.height,T=t.y-w/2,D=t.y+w/2,O=t.x-C/2,k=t.swimlaneContentTop===void 0?T+w/3:t.swimlaneContentTop,A=v?4:0,j=x.height+2*A,M,N;if(v){let e=Math.max(j,x.height+2*A),n=O+e,r=Math.max(0,C-e);if(t.look===`handDrawn`){let i=Ae.svg(g),a=xe(t,{roughness:.7,fill:c,stroke:d,seed:s}),o=xe(t,{roughness:.7,fill:`none`,stroke:d,seed:s}),l=i.rectangle(O,T,e,w,a);M=g.insert(()=>l,`:first-child`).attr(`class`,`swimlane-title`);let u=i.rectangle(n,T,r,w,o);N=g.insert(()=>u,`:first-child`).attr(`class`,`swimlane-body`),M.select(`path:nth-child(2)`).attr(`style`,m.join(`;`)),M.select(`path`).attr(`style`,h.join(`;`).replace(`fill`,`stroke`))}else M=g.insert(`rect`,`:first-child`),N=g.insert(`rect`,`:first-child`),M.attr(`class`,`swimlane-title`).attr(`style`,p).attr(`x`,O).attr(`y`,T).attr(`width`,e).attr(`height`,w).attr(`fill`,c).attr(`stroke`,d),N.attr(`class`,`swimlane-body`).attr(`style`,p).attr(`x`,n).attr(`y`,T).attr(`width`,r).attr(`height`,w).attr(`fill`,`none`).attr(`stroke`,d);let i=O+e/2,a=t.y;y.attr(`transform`,`translate(${i}, ${a}) rotate(-90) translate(${-x.width/2}, ${-x.height/2})`)}else{let e=Math.max(0,k-T),n=Math.min(j,e),r=T+n,i=Math.max(0,D-r),a=t.x-C/2;if(t.look===`handDrawn`){let e=Ae.svg(g),o=xe(t,{roughness:.7,fill:c,stroke:d,fillWeight:3,seed:s}),l=xe(t,{roughness:.7,fill:`none`,stroke:d,seed:s}),u=e.rectangle(a,T,C,n,o);M=g.insert(()=>u,`:first-child`).attr(`class`,`swimlane-title`);let f=e.rectangle(a,r,C,i,l);N=g.insert(()=>f,`:first-child`).attr(`class`,`swimlane-body`),M.select(`path:nth-child(2)`).attr(`style`,m.join(`;`)),M.select(`path`).attr(`style`,h.join(`;`).replace(`fill`,`stroke`))}else M=g.insert(`rect`,`:first-child`),N=g.insert(`rect`,`:first-child`),M.attr(`class`,`swimlane-title`).attr(`style`,p).attr(`x`,a).attr(`y`,T).attr(`width`,C).attr(`height`,n).attr(`fill`,c).attr(`stroke`,d),N.attr(`class`,`swimlane-body`).attr(`style`,p).attr(`x`,a).attr(`y`,r).attr(`width`,C).attr(`height`,i).attr(`fill`,`none`).attr(`stroke`,d);let o=t.x-x.width/2,l=T+(n-x.height)/2;y.attr(`transform`,`translate(${o}, ${l})`)}if(n.trace(`Swimlane data `,t,JSON.stringify(t)),f){let e=y.select(`span`);e&&e.attr(`style`,f)}return t.offsetX=0,t.width=C,t.height=w,t.offsetY=x.height-S/2,t.intersect=function(e){return je(t,e)},{cluster:g,labelBBox:x}},`swimlane`),ga=a(async(e,t)=>{n.info(`Creating subgraph rect for `,t.id,t);let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,{labelStyles:d,nodeStyles:f,borderStyles:p,backgroundStyles:m}=Se(t),h=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look);ke(h,t.colorIndex,a,u);let g=_(i),v=h.insert(`g`).attr(`class`,`cluster-label `),y;y=t.labelType===`markdown`?await De(v,t.label,{style:t.labelStyle,useHtmlLabels:g,isNode:!0,width:t.width}):await Pe(v,t.label,t.labelStyle||``,!1,!0);let b=y.getBBox();if(_(i)){let e=y.children[0],t=r(y);b=e.getBoundingClientRect(),t.attr(`width`,b.width),t.attr(`height`,b.height)}let x=t.width<=b.width+t.padding?b.width+t.padding:t.width;t.diff=t.width<=b.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let S=t.height,C=t.x-x/2,w=t.y-S/2;n.trace(`Data `,t,JSON.stringify(t));let T;if(t.look===`handDrawn`){let e=Ae.svg(h),r=xe(t,{roughness:.7,fill:c,stroke:l,fillWeight:3,seed:s}),i=e.path(Me(C,w,x,S,0),r);T=h.insert(()=>(n.debug(`Rough node insert CXC`,i),i),`:first-child`),T.select(`path:nth-child(2)`).attr(`style`,p.join(`;`)),T.select(`path`).attr(`style`,m.join(`;`).replace(`fill`,`stroke`))}else T=h.insert(`rect`,`:first-child`),T.attr(`style`,f).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,C).attr(`y`,w).attr(`width`,x).attr(`height`,S);let{subGraphTitleTopMargin:E}=Fe(i);if(v.attr(`transform`,`translate(${t.x-b.width/2}, ${t.y-t.height/2+E})`),d){let e=v.select(`span`);e&&e.attr(`style`,d)}let D=T.node().getBBox();return t.offsetX=0,t.width=D.width,t.height=D.height,t.offsetY=b.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:h,labelBBox:b}},`rect`),_a=a((e,t)=>{let n=e.insert(`g`).attr(`class`,`note-cluster`).attr(`id`,t.domId),r=n.insert(`rect`,`:first-child`),i=0*t.padding,a=i/2;r.attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,t.x-t.width/2-a).attr(`y`,t.y-t.height/2-a).attr(`width`,t.width+i).attr(`height`,t.height+i).attr(`fill`,`none`);let o=r.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(e){return je(t,e)},{cluster:n,labelBBox:{width:0,height:0}}},`noteGroup`),va=a(async(e,t)=>{let n=I(),{theme:i,themeVariables:a,handDrawnSeed:o}=n,{altBackground:s,borderColorArray:c,compositeBackground:l,compositeTitleBackground:u,nodeBorder:d}=a,f=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-id`,t.id).attr(`data-look`,t.look);ke(f,t.colorIndex,i,c);let p=f.insert(`g`,`:first-child`),m=f.insert(`g`).attr(`class`,`cluster-label`),h=f.append(`rect`),g=await Pe(m,t.label,t.labelStyle,void 0,!0),v=g.getBBox();if(_(n)){let e=g.children[0],t=r(g);v=e.getBoundingClientRect(),t.attr(`width`,v.width),t.attr(`height`,v.height)}let y=0*t.padding,b=y/2,x=(t.width<=v.width+t.padding?v.width+t.padding:t.width)+y;t.diff=t.width<=v.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let S=t.height+y,C=t.height+y-v.height-6,w=t.x-x/2,T=t.y-S/2;t.width=x;let E=t.y-t.height/2-b+v.height+2,D;if(t.look===`handDrawn`){let e=t.cssClasses.includes(`statediagram-cluster-alt`),n=Ae.svg(f),r=t.rx||t.ry?n.path(Me(w,T,x,S,10),{roughness:.7,fill:u,fillStyle:`solid`,stroke:d,seed:o}):n.rectangle(w,T,x,S,{seed:o});D=f.insert(()=>r,`:first-child`);let i=n.rectangle(w,E,x,C,{fill:e?s:l,fillStyle:e?`hachure`:`solid`,stroke:d,seed:o});D=f.insert(()=>r,`:first-child`),h=f.insert(()=>i),D.attr(`class`,`outer`),h.attr(`class`,`inner`)}else D=p.insert(`rect`,`:first-child`),D.attr(`class`,`outer`).attr(`x`,w).attr(`y`,T).attr(`width`,x).attr(`height`,S).attr(`data-look`,t.look),h.attr(`class`,`inner`).attr(`x`,w).attr(`y`,E).attr(`width`,x).attr(`height`,C);return m.attr(`transform`,`translate(${t.x-v.width/2}, ${T+1-(_(n)?0:3)})`),t.height=D.node().getBBox().height,t.offsetX=0,t.offsetY=v.height-t.padding/2,t.labelBBox=v,t.intersect=function(e){return je(t,e)},{cluster:f,labelBBox:v}},`roundedWithTitle`),ya=a(async(e,t)=>{n.info(`Creating subgraph rect for `,t.id,t);let i=I(),{themeVariables:a,handDrawnSeed:o}=i,{clusterBkg:s,clusterBorder:c}=a,{labelStyles:l,nodeStyles:u,borderStyles:d,backgroundStyles:f}=Se(t),p=e.insert(`g`).attr(`class`,`cluster `+t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look),m=_(i),h=p.insert(`g`).attr(`class`,`cluster-label `),g=await De(h,t.label,{style:t.labelStyle,useHtmlLabels:m,isNode:!0,width:t.width}),v=g.getBBox();if(_(i)){let e=g.children[0],t=r(g);v=e.getBoundingClientRect(),t.attr(`width`,v.width),t.attr(`height`,v.height)}let y=t.width<=v.width+t.padding?v.width+t.padding:t.width;t.diff=t.width<=v.width+t.padding?(y-t.width)/2-t.padding:-t.padding;let b=t.height,x=t.x-y/2,S=t.y-b/2;n.trace(`Data `,t,JSON.stringify(t));let C;if(t.look===`handDrawn`){let e=Ae.svg(p),r=xe(t,{roughness:.7,fill:s,stroke:c,fillWeight:4,seed:o}),i=e.path(Me(x,S,y,b,t.rx),r);C=p.insert(()=>(n.debug(`Rough node insert CXC`,i),i),`:first-child`),C.select(`path:nth-child(2)`).attr(`style`,d.join(`;`)),C.select(`path`).attr(`style`,f.join(`;`).replace(`fill`,`stroke`))}else C=p.insert(`rect`,`:first-child`),C.attr(`style`,u).attr(`rx`,t.rx).attr(`ry`,t.ry).attr(`x`,x).attr(`y`,S).attr(`width`,y).attr(`height`,b);let{subGraphTitleTopMargin:w}=Fe(i);if(h.attr(`transform`,`translate(${t.x-v.width/2}, ${t.y-t.height/2+w})`),l){let e=h.select(`span`);e&&e.attr(`style`,l)}let T=C.node().getBBox();return t.offsetX=0,t.width=T.width,t.height=T.height,t.offsetY=v.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:p,labelBBox:v}},`kanbanSection`),ba=a((e,t)=>{let{theme:n,themeVariables:r,handDrawnSeed:i}=I(),{altBackground:a,nodeBorder:o,borderColorArray:s}=r,c=e.insert(`g`).attr(`class`,t.cssClasses).attr(`id`,t.domId).attr(`data-look`,t.look);ke(c,t.colorIndex,n,s);let l=c.insert(`g`,`:first-child`),u=0*t.padding,d=t.width+u;t.diff=-t.padding;let f=t.height+u,p=t.x-d/2,m=t.y-f/2;t.width=d;let h;if(t.look===`handDrawn`){let e=Ae.svg(c).rectangle(p,m,d,f,{fill:a??`#efefef`,fillStyle:`solid`,roughness:.5,strokeLineDash:[5],stroke:o,seed:i});h=c.insert(()=>e,`:first-child`).attr(`class`,`divider`)}else{h=l.insert(`rect`,`:first-child`);let e=`outer`;e=(t.look,`divider`),h.attr(`class`,e).attr(`x`,p).attr(`y`,m).attr(`width`,d).attr(`height`,f).attr(`data-look`,t.look)}return t.height=h.node().getBBox().height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return je(t,e)},{cluster:c,labelBBox:{}}},`divider`),xa=a(async(e,t,i)=>{n.info(`Creating ${i.cssClass} for `,t.id,t);let a=I(),{theme:o,themeVariables:s,handDrawnSeed:c}=a,{borderColorArray:l}=s,{labelStyles:u,borderStyles:d}=Se(t),f=e.insert(`g`).attr(`class`,`cluster `+i.cssClass+` `+t.cssClasses).attr(`id`,t.domId??t.id).attr(`data-look`,t.look);ke(f,t.colorIndex,o,l);let p=_(a),m=f.insert(`g`).attr(`class`,`cluster-label`),h={width:0,height:0},g=t.label?.trim();if(g){let e;if(e=t.labelType===`markdown`?await De(m,t.label,{style:t.labelStyle,useHtmlLabels:p,isNode:!0,width:t.width}):await Pe(m,t.label,t.labelStyle||``,!1,!0),h=e.getBBox(),p){let t=e.children[0],n=r(e);h=t.getBoundingClientRect(),n.attr(`width`,h.width),n.attr(`height`,h.height)}}let v=t.width<=h.width+t.padding?h.width+t.padding:t.width;t.diff=t.width<=h.width+t.padding?(v-t.width)/2-t.padding:-t.padding;let y=t.height,b=t.x-v/2,x=t.y-y/2,S;if(t.look===`handDrawn`){let e=Ae.svg(f),n=xe(t,{roughness:i.roughness,fill:i.fill,stroke:i.stroke,strokeWidth:i.strokeWidth,seed:c,...i.fill===`none`?{fillWeight:0}:{fillStyle:`solid`},...i.strokeDash?{strokeLineDash:i.strokeDash}:{}}),r=e.path(Me(b,x,v,y,i.rx),n);S=f.insert(()=>r,`:first-child`),S.select(`path:nth-child(2)`).attr(`style`,d.join(`;`))}else S=f.insert(`rect`,`:first-child`),S.attr(`rx`,i.rx).attr(`ry`,i.rx).attr(`x`,b).attr(`y`,x).attr(`width`,v).attr(`height`,y).attr(`fill`,i.fill).attr(`stroke`,i.stroke).attr(`stroke-width`,i.strokeWidth+`px`),i.strokeDash&&S.attr(`stroke-dasharray`,i.strokeDash.join(`, `));if(g){let{subGraphTitleTopMargin:e}=Fe(a);if(m.attr(`transform`,`translate(${t.x-h.width/2}, ${t.y-t.height/2+e})`),u){let e=m.select(`span`);e&&e.attr(`style`,u)}}let C=S.node().getBBox();return t.offsetX=0,t.width=C.width,t.height=C.height,t.offsetY=h.height-t.padding/2,t.intersect=function(e){return je(t,e)},{cluster:f,labelBBox:h}},`createContainerGroup`),Sa=a(async(e,t)=>{let{themeVariables:n}=I();return xa(e,t,{cssClass:`flow-cluster`,rx:10,fill:`none`,stroke:n.flowContainerStroke||n.secondaryBorderColor,strokeWidth:.75,roughness:.7})},`flowGroup`),Ca=a((e,t)=>{let n=e.boundaryType||`rect`,r=n===`package`?20:e.padding,i=n===`package`?t.height+10:0,a=Math.max(e.width,t.width+r),o=n===`package`?Math.max(e.height,i+e.padding*2):e.height,s=e.x-a/2,c=e.y-o/2;return{boundaryType:n,width:a,height:o,x:s,y:c,bodyY:c+i,bodyHeight:o-i,tabHeight:i,tabWidth:n===`package`?Math.min(a,Math.max(80,t.width+20)):0}},`getUsecaseSystemBoundaryGeometry`),wa={rect:ga,squareRect:ga,roundedWithTitle:va,noteGroup:_a,divider:ba,kanbanSection:ya,flowGroup:Sa,usecaseSystemBoundary:a(async(e,t)=>{n.info(`Creating usecase system boundary for `,t.id,t);let i=I(),{theme:a,themeVariables:o,handDrawnSeed:s}=i,{clusterBkg:c,clusterBorder:l,borderColorArray:u}=o,{labelStyles:d,nodeStyles:f}=Se(t),{stylesMap:p}=we(t),m=t.boundaryType||`rect`,h=e.insert(`g`).attr(`class`,`cluster usecase-system-boundary usecase-system-boundary-${m} ${t.cssClasses}`).attr(`id`,typeof t.domId==`string`?t.domId:t.id).attr(`data-boundary-type`,m).attr(`data-look`,t.look);ke(h,t.colorIndex,a,u);let g=_(i),v=h.insert(`g`).attr(`class`,`cluster-label system-boundary-title`),y=await De(v,t.label,{style:d,useHtmlLabels:g,isNode:!0}),b=y.getBBox();if(g){let e=y.children[0],t=r(y);b=e.getBoundingClientRect(),t.attr(`width`,b.width),t.attr(`height`,b.height)}let{width:x,height:S,x:C,y:w,bodyY:T,bodyHeight:E,tabHeight:D,tabWidth:O}=Ca(t,b);t.diff=t.width<=b.width+t.padding?(x-t.width)/2-t.padding:-t.padding;let k=xe(t,{fill:p.get(`fill`)||c,stroke:p.get(`stroke`)||l,strokeWidth:p.get(`stroke-width`)?.replace(`px`,``)||1,seed:s});if(t.look===`handDrawn`){let e=Ae.svg(h),t=e.rectangle(C,T,x,E,k);if(h.insert(()=>t,`:first-child`).attr(`class`,`boundary-body label-container`),m===`package`){let t=e.rectangle(C,w,O,D,k);h.insert(()=>t,`:first-child`).attr(`class`,`boundary-tab system-boundary-package-tab label-container`)}}else h.insert(`rect`,`:first-child`).attr(`class`,`boundary-body label-container`).attr(`style`,f).attr(`x`,C).attr(`y`,T).attr(`width`,x).attr(`height`,E),m===`package`&&h.insert(`rect`,`:first-child`).attr(`class`,`boundary-tab system-boundary-package-tab label-container`).attr(`style`,f).attr(`x`,C).attr(`y`,w).attr(`width`,O).attr(`height`,D);let{subGraphTitleTopMargin:A}=Fe(i);return m===`package`?v.attr(`transform`,`translate(${C+(O-b.width)/2}, ${w+(D-b.height)/2})`):v.attr(`transform`,`translate(${t.x-b.width/2}, ${w+A})`),d&&(v.attr(`style`,d),v.select(`span`).attr(`style`,d)),t.offsetX=0,t.width=x,t.height=S,t.offsetY=b.height-t.padding/2,t.labelBBox=b,t.intersect=function(e){return je(t,e)},{cluster:h,labelBBox:b}},`usecaseSystemBoundary`),swimlane:ha},Ta=new Set([`noteGroup`,`divider`]),Ea=a(e=>!Ta.has(e??`rect`),`clusterPaintsTitle`),Da=new Map,Oa=a(async(e,t)=>{let n=await wa[t.shape||`rect`](e,t);return Da.set(t.id,n),n},`insertCluster`),ka=a(()=>{Da=new Map},`clear`),Aa=a((e,t)=>{if(t)return`translate(`+-e.width/2+`, `+-e.height/2+`)`;let n=e.x??0,r=e.y??0;return`translate(`+-(n+e.width/2)+`, `+-(r+e.height/2)+`)`},`computeLabelTransform`),ja={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},Ma={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function Na(e,t){if(e===void 0||t===void 0)return{angle:0,deltaX:0,deltaY:0};e=K(e),t=K(t);let[n,r]=[e.x,e.y],[i,a]=[t.x,t.y],o=i-n,s=a-r;return{angle:Math.atan(s/o),deltaX:o,deltaY:s}}a(Na,`calculateDeltaAndAngle`);var K=a(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,`pointTransformer`),Pa=a(e=>({x:a(function(t,n,r){let i=0,a=K(r[0]).x=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(ja,e.arrowTypeEnd)){let{angle:t,deltaX:n}=Na(r[r.length-1],r[r.length-2]);i=ja[e.arrowTypeEnd]*Math.cos(t)*(n>=0?1:-1)}let o=Math.abs(K(t).x-K(r[r.length-1]).x),s=Math.abs(K(t).y-K(r[r.length-1]).y),c=Math.abs(K(t).x-K(r[0]).x),l=Math.abs(K(t).y-K(r[0]).y),u=ja[e.arrowTypeStart],d=ja[e.arrowTypeEnd];if(o0&&s0&&l=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(ja,e.arrowTypeEnd)){let{angle:t,deltaY:n}=Na(r[r.length-1],r[r.length-2]);i=ja[e.arrowTypeEnd]*Math.abs(Math.sin(t))*(n>=0?1:-1)}let o=Math.abs(K(t).y-K(r[r.length-1]).y),s=Math.abs(K(t).x-K(r[r.length-1]).x),c=Math.abs(K(t).y-K(r[0]).y),l=Math.abs(K(t).x-K(r[0]).x),u=ja[e.arrowTypeStart],d=ja[e.arrowTypeEnd];if(o0&&s0&&l{t.arrowTypeStart&&Ra(e,`start`,t.arrowTypeStart,n,r,i,a,o),t.arrowTypeEnd&&Ra(e,`end`,t.arrowTypeEnd,n,r,i,a,o)},`addEdgeMarkers`),Ia={arrow_cross:{type:`cross`,fill:!1},arrow_point:{type:`point`,fill:!0},arrow_barb:{type:`barb`,fill:!0},arrow_barb_neo:{type:`barb`,fill:!0},arrow_circle:{type:`circle`,fill:!1},arrow_hierarchy:{type:`hierarchy`,fill:!1},aggregation:{type:`aggregation`,fill:!1},extension:{type:`extension`,fill:!1},composition:{type:`composition`,fill:!0},dependency:{type:`dependency`,fill:!0},lollipop:{type:`lollipop`,fill:!1},only_one:{type:`onlyOne`,fill:!1},zero_or_one:{type:`zeroOrOne`,fill:!1},one_or_more:{type:`oneOrMore`,fill:!1},zero_or_more:{type:`zeroOrMore`,fill:!1},requirement_arrow:{type:`requirement_arrow`,fill:!1},requirement_contains:{type:`requirement_contains`,fill:!1}},La=[`cross`,`point`,`circle`,`lollipop`,`aggregation`,`extension`,`composition`,`dependency`,`barb`],Ra=a((e,t,r,i,a,o,s=!1,c)=>{if(!r||r===`none`)return;let l=Ia[r],u=l&&La.includes(l.type);if(!l){n.warn(`Unknown arrow type: ${r}`);return}let d=`${a}_${o}-${l.type}${t===`start`?`Start`:`End`}${s&&u?`-margin`:``}`;if(c&&c.trim()!==``){let n=`${d}_${c.replace(/[^\dA-Za-z]/g,`_`)}`;if(!document.getElementById(n)){let e=document.getElementById(d);if(e){let t=e.cloneNode(!0);t.id=n,t.querySelectorAll(`path, circle, line`).forEach(e=>{e.setAttribute(`stroke`,c),l.fill&&e.setAttribute(`fill`,c)}),e.parentNode?.appendChild(t)}}e.attr(`marker-${t}`,`url(${i}#${n})`)}else e.attr(`marker-${t}`,`url(${i}#${d})`)},`addEdgeMarker`),za=a(e=>typeof e==`string`?e:I()?.flowchart?.curve,`resolveEdgeCurveType`),Ba=new Map,Va=new Map,Ha=a(()=>{Ba.clear(),Va.clear()},`clear`),Ua=a(e=>!!(e.label||e.startLabelLeft||e.startLabelRight||e.endLabelLeft||e.endLabelRight),`hasEdgeLabel`),Wa=a(e=>e?typeof e==`string`?e:e.reduce((e,t)=>e+`;`+t,``):``,`getLabelStyles`),Ga=a(async(e,t)=>{let i=I(),a=_(i),{labelStyles:o}=Se(t);t.labelStyle=o;let s=e.insert(`g`).attr(`class`,`edgeLabel`),c=s.insert(`g`).attr(`class`,`label`).attr(`data-id`,t.id),l=t.labelType===`markdown`,u=await De(e,t.label,{style:Wa(t.labelStyle),useHtmlLabels:a,addSvgBackground:!0,isNode:!1,markdown:l,width:void 0},i);c.node().appendChild(u),n.info(`abc82`,t,t.labelType);let d,f;if(a){let e=u.children[0],t=r(u);d=await Oe.measure(()=>e.getBoundingClientRect()),f=d,t.attr(`width`,d.width),t.attr(`height`,d.height)}else{let e=r(u).select(`text`).node();await Oe.measure(()=>{d=u.getBBox(),f=e&&typeof e.getBBox==`function`?e.getBBox():d})}c.attr(`transform`,Aa(f,a)),Ba.set(t.id,s),t.width=d.width,t.height=d.height;let p;if(t.startLabelLeft){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(i,t.startLabelLeft,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).startLeft=n,Ka(p,t.startLabelLeft)}if(t.startLabelRight){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(i,t.startLabelRight,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).startRight=n,Ka(p,t.startLabelRight)}if(t.endLabelLeft){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(n,t.endLabelLeft,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).endLeft=n,Ka(p,t.endLabelLeft)}if(t.endLabelRight){let n=e.insert(`g`).attr(`class`,`edgeTerminals`),i=n.insert(`g`).attr(`class`,`inner`),o=await Pe(n,t.endLabelRight,Wa(t.labelStyle)||``,!1,!1);p=o;let s=o.getBBox();if(a){let e=o.children[0],t=r(o);s=e.getBoundingClientRect(),t.attr(`width`,s.width),t.attr(`height`,s.height)}i.attr(`transform`,Aa(s,a)),Va.get(t.id)||Va.set(t.id,{}),Va.get(t.id).endRight=n,Ka(p,t.endLabelRight)}return u},`insertEdgeLabel`);function Ka(e,t){_(I())&&e&&(e.style.width=t.length*9+`px`,e.style.height=`12px`)}a(Ka,`setTerminalWidth`);var qa=a((e,t)=>{n.debug(`Moving label abc88 `,e.id,e.label,Ba.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath,i=I(),{subGraphTitleTotalMargin:a}=Fe(i);if(e.label){let i=Ba.get(e.id),o=e.x,s=e.y;if(r){let i=ce.calcLabelPosition(r);n.debug(`Moving label `+e.label+` from (`,o,`,`,s,`) to (`,i.x,`,`,i.y,`) abc88`),t.updatedPath&&(o=i.x,s=i.y)}i.attr(`transform`,`translate(${o}, ${s+a/2})`)}if(e.startLabelLeft){let t=Va.get(e.id).startLeft,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_left`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.startLabelRight){let t=Va.get(e.id).startRight,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeStart?10:0,`start_right`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.endLabelLeft){let t=Va.get(e.id).endLeft,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_left`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}if(e.endLabelRight){let t=Va.get(e.id).endRight,n=e.x,i=e.y;if(r){let t=ce.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,`end_right`,r);n=t.x,i=t.y}t.attr(`transform`,`translate(${n}, ${i})`)}},`positionEdgeLabel`),Ja=a((e,t)=>{if(!e?.isLabelEdge||!e?.id?.endsWith(`-to-label`)||!Array.isArray(t)||t.length!==2)return t;let[n,r]=t,i=Math.abs(r.x-n.x),a=Math.abs(r.y-n.y);return i<.001||a<.001?t:a>=i?[n,{x:n.x,y:r.y},r]:[n,{x:r.x,y:n.y},r]},`orthogonalizeToLabelClippedPoints`),Ya=a((e,t)=>{let n=e.x,r=e.y,i=Math.abs(t.x-n),a=Math.abs(t.y-r),o=e.width/2,s=e.height/2;return i>=o||a>=s},`outsideNode`),Xa=a((e,t,r)=>{n.debug(`intersection calc abc89: + outsidePoint: ${JSON.stringify(t)} + insidePoint : ${JSON.stringify(r)} + node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);let i=e.x,a=e.y,o=Math.abs(i-r.x),s=e.width/2,c=r.xMath.abs(i-t.x)*l){let e=r.y{n.warn(`abc88 cutPathAtIntersect`,e,t);let r=[],i=e[0],a=!1;return e.forEach(e=>{if(n.info(`abc88 checking point`,e,t),!Ya(t,e)&&!a){let o=Xa(t,i,e);n.debug(`abc88 inside`,e,i,o),n.debug(`abc88 intersection`,o,t);let s=!1;r.forEach(e=>{s||=e.x===o.x&&e.y===o.y}),r.some(e=>e.x===o.x&&e.y===o.y)?n.warn(`abc88 no intersect`,o,r):r.push(o),a=!0}else n.warn(`abc88 outside`,e,i),i=e,a||r.push(e)}),n.debug(`returning points`,r),r},`cutPathAtIntersect`);function Qa(e){let t=[],n=[];for(let r=1;r5&&Math.abs(a.y-i.y)>5||i.y===a.y&&a.x===o.x&&Math.abs(a.x-i.x)>5&&Math.abs(a.y-o.y)>5)&&(t.push(a),n.push(r))}return{cornerPoints:t,cornerPointPositions:n}}a(Qa,`extractCornerPoints`);var $a=a(function(e,t,n){let r=t.x-e.x,i=t.y-e.y,a=n/Math.sqrt(r*r+i*i);return{x:t.x-a*r,y:t.y-a*i}},`findAdjacentPoint`),eo=a(function(e){let{cornerPointPositions:t}=Qa(e),r=[];for(let i=0;i10&&Math.abs(a.y-t.y)>=10?(n.debug(`Corner point fixing`,Math.abs(a.x-t.x),Math.abs(a.y-t.y)),f=o.x===s.x?{x:l<0?s.x-5+d:s.x+5-d,y:u<0?s.y-d:s.y+d}:{x:l<0?s.x-d:s.x+d,y:u<0?s.y-5+d:s.y+5-d}):n.debug(`Corner point skipping fixing`,Math.abs(a.x-t.x),Math.abs(a.y-t.y)),r.push(f,c)}else r.push(e[i]);return r},`fixCorners`),to=a((e,t,n)=>{let r=e-t-n,i=Math.floor(r/4);return`0 ${t} ${Array(Number.isFinite(i)?Math.max(0,i):0).fill(`2 2`).join(` `)} ${n}`},`generateDashArray`),no=a(function(e,t,i,a,o,s,c,l=!1){if(!c)throw Error(`insertEdge: missing diagramId for edge "${t.id}" \u2014 edge IDs require a diagram prefix for uniqueness`);let{handDrawnSeed:u,layout:d}=I(),f=t.points,p=!1,m=o;var h=s;let g=[];for(let e in t.cssCompiledStyles)Ce(e)||g.push(t.cssCompiledStyles[e]);if(d===`swimlane`){if(h.intersect&&m.intersect&&Array.isArray(f)&&f.length>=2){if(f.length===2)f=[m.intersect(f[0]),h.intersect(f[1])];else{let e=f.slice(1,-1),t=e[0],n=e[e.length-1],r=.5,i=Math.abs(f[f.length-1].x-n.x)!Number.isNaN(e.y)),y=za(t.curve);y!==`rounded`&&(v=eo(v));let b=me;switch(y){case`linear`:b=me;break;case`basis`:b=oe;break;case`cardinal`:b=L;break;case`bumpX`:b=he;break;case`bumpY`:b=de;break;case`catmullRom`:b=B;break;case`monotoneX`:b=te;break;case`monotoneY`:b=re;break;case`natural`:b=ne;break;case`step`:b=R;break;case`stepAfter`:b=z;break;case`stepBefore`:b=pe;break;case`rounded`:b=me;break;default:b=oe}let{x,y:S}=Pa(t),C=be().x(x).y(S).curve(b),w;switch(t.thickness){case`normal`:w=`edge-thickness-normal`;break;case`thick`:w=`edge-thickness-thick`;break;case`invisible`:w=`edge-thickness-invisible`;break;default:w=`edge-thickness-normal`}switch(t.pattern){case`solid`:w+=` edge-pattern-solid`;break;case`dotted`:w+=` edge-pattern-dotted`;break;case`dashed`:w+=` edge-pattern-dashed`;break;default:w+=` edge-pattern-solid`}let T,E=y===`rounded`?ro(ao(v,t),5):C(v),D=Array.isArray(t.style)?t.style:[t.style],O=D.find(e=>e?.startsWith(`stroke:`)),k=``;t.animate&&(k=`edge-animation-fast`),t.animation&&(k=`edge-animation-`+t.animation);let A=!1;if(t.look===`handDrawn`){let n=Ae.svg(e);Object.assign([],v);let i=n.path(E,{roughness:.3,seed:u});w+=` transition`,T=r(i).select(`path`).attr(`id`,`${c}-${t.id}`).attr(`class`,` `+w+(t.classes?` `+t.classes:``)+(k?` `+k:``)).attr(`style`,D?D.reduce((e,t)=>e+`;`+t,``):``);let a=T.attr(`d`);T.attr(`d`,a),e.node().appendChild(T.node())}else{let n=g.join(`;`),r=D?D.reduce((e,t)=>e+t+`;`,``):``,i=(n?n+`;`+r+`;`:r)+`;`+(D?D.reduce((e,t)=>e+`;`+t,``):``);T=e.append(`path`).attr(`d`,E).attr(`id`,`${c}-${t.id}`).attr(`class`,` `+w+(t.classes?` `+t.classes:``)+(k?` `+k:``)).attr(`style`,i),O=i.match(/stroke:([^;]+)/)?.[1],A=t.animate===!0||!!t.animation||n.includes(`animation`);let a=T.node(),o=typeof a.getTotalLength==`function`?a.getTotalLength():0,s=Ma[t.arrowTypeStart]||0,l=Ma[t.arrowTypeEnd]||0;if(t.look===`neo`&&!A){let e=`stroke-dasharray: ${t.pattern===`dotted`||t.pattern===`dashed`?to(o,s,l):`0 ${s} ${o-s-l} ${l}`}; stroke-dashoffset: 0;`;T.attr(`style`,e+T.attr(`style`))}}T.attr(`data-edge`,!0),T.attr(`data-et`,`edge`),T.attr(`data-id`,t.id),T.attr(`data-points`,_),T.attr(`data-look`,ge(t.look)),t.showPoints&&v.forEach(t=>{e.append(`circle`).style(`stroke`,`red`).style(`fill`,`red`).attr(`r`,1).attr(`cx`,t.x).attr(`cy`,t.y)});let j=``;(I().flowchart.arrowMarkerAbsolute||I().state.arrowMarkerAbsolute)&&(j=window.location.protocol+`//`+window.location.host+window.location.pathname+window.location.search,j=j.replace(/\(/g,`\\(`).replace(/\)/g,`\\)`)),n.info(`arrowTypeStart`,t.arrowTypeStart),n.info(`arrowTypeEnd`,t.arrowTypeEnd);let M=!A&&t?.look===`neo`;Fa(T,t,j,c,a,M,O);let N=Math.floor(f.length/2),P=f[N];ce.isLabelCoordinateInPath(P,T.attr(`d`))||(p=!0);let F={};return p&&(F.updatedPath=f),F.originalPath=t.points,F},`insertEdge`);function ro(e,t){if(e.length<2)return``;let n=``,r=e.length,i=1e-5;for(let a=0;a({...e}));if(e.length>=2&&ja[t.arrowTypeStart]){let r=ja[t.arrowTypeStart],i=e[0],a=e[1],{angle:o}=io(i,a),s=r*Math.cos(o),c=r*Math.sin(o);n[0].x=i.x+s,n[0].y=i.y+c}let r=e.length;if(r>=2&&ja[t.arrowTypeEnd]){let i=ja[t.arrowTypeEnd],a=e[r-1],o=e[r-2],{angle:s}=io(o,a),c=i*Math.cos(s),l=i*Math.sin(s);n[r-1].x=a.x-c,n[r-1].y=a.y-l}return n}a(ao,`applyMarkerOffsetsToPoints`);var q=a((e,t,n,r)=>{t.forEach(t=>{oo[t](e,n,r)})},`insertMarkers`),oo={extension:a((e,t,r)=>{n.trace(`Making markers for `,r),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionStart`).attr(`class`,`marker extension `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 1,7 L18,13 V 1 Z`),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionEnd`).attr(`class`,`marker extension `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 1,1 V 13 L18,7 Z`),e.append(`marker`).attr(`id`,r+`_`+t+`-extensionStart-margin`).attr(`class`,`marker extension `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`viewBox`,`0 0 20 14`).append(`polygon`).attr(`points`,`10,7 18,13 18,1`).style(`stroke-width`,2).style(`stroke-dasharray`,`0`),e.append(`defs`).append(`marker`).attr(`id`,r+`_`+t+`-extensionEnd-margin`).attr(`class`,`marker extension `+t).attr(`refX`,9).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`viewBox`,`0 0 20 14`).append(`polygon`).attr(`points`,`10,1 10,13 18,7`).style(`stroke-width`,2).style(`stroke-dasharray`,`0`)},`extension`),composition:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionStart`).attr(`class`,`marker composition `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionEnd`).attr(`class`,`marker composition `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionStart-margin`).attr(`class`,`marker composition `+t).attr(`refX`,15).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`viewBox`,`0 0 15 15`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-compositionEnd-margin`).attr(`class`,`marker composition `+t).attr(`refX`,3.5).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`)},`composition`),aggregation:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationStart`).attr(`class`,`marker aggregation `+t).attr(`refX`,18).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationEnd`).attr(`class`,`marker aggregation `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationStart-margin`).attr(`class`,`marker aggregation `+t).attr(`refX`,15).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,2).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-aggregationEnd-margin`).attr(`class`,`marker aggregation `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,2).attr(`d`,`M 18,7 L9,13 L1,7 L9,1 Z`)},`aggregation`),dependency:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyStart`).attr(`class`,`marker dependency `+t).attr(`refX`,6).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 5,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyEnd`).attr(`class`,`marker dependency `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyStart-margin`).attr(`class`,`marker dependency `+t).attr(`refX`,4).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 5,7 L9,13 L1,7 L9,1 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-dependencyEnd-margin`).attr(`class`,`marker dependency `+t).attr(`refX`,16).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).style(`stroke-width`,0).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`dependency`),lollipop:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopStart`).attr(`class`,`marker lollipop `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopEnd`).attr(`class`,`marker lollipop `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopStart-margin`).attr(`class`,`marker lollipop `+t).attr(`refX`,13).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6).attr(`stroke-width`,2),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-lollipopEnd-margin`).attr(`class`,`marker lollipop `+t).attr(`refX`,1).attr(`refY`,7).attr(`markerWidth`,190).attr(`markerHeight`,240).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`circle`).attr(`fill`,`transparent`).attr(`cx`,7).attr(`cy`,7).attr(`r`,6).attr(`stroke-width`,2)},`lollipop`),point:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-pointEnd`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,5).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,8).attr(`markerHeight`,8).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointStart`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,4.5).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,8).attr(`markerHeight`,8).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 5 L 10 10 L 10 0 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointEnd-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 11.5 14`).attr(`refX`,11.5).attr(`refY`,7).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,10.5).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 11.5 7 L 0 14 z`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-pointStart-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 11.5 14`).attr(`refX`,1).attr(`refY`,7).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11.5).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`polygon`).attr(`points`,`0,7 11.5,14 11.5,0`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`)},`point`),circle:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-circleEnd`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,11).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleStart`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,-1).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleEnd-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refY`,5).attr(`refX`,12.25).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,14).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-circleStart-margin`).attr(`class`,`marker `+t).attr(`viewBox`,`0 0 10 10`).attr(`refX`,-2).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,14).attr(`markerHeight`,14).attr(`orient`,`auto`).append(`circle`).attr(`cx`,`5`).attr(`cy`,`5`).attr(`r`,`5`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,0).style(`stroke-dasharray`,`1,0`)},`circle`),cross:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-crossEnd`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 11 11`).attr(`refX`,12).attr(`refY`,5.2).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 l 9,9 M 10,1 l -9,9`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-crossStart`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 11 11`).attr(`refX`,-1).attr(`refY`,5.2).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,11).attr(`markerHeight`,11).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 l 9,9 M 10,1 l -9,9`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2).style(`stroke-dasharray`,`1,0`),e.append(`marker`).attr(`id`,n+`_`+t+`-crossEnd-margin`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 15 15`).attr(`refX`,17.7).attr(`refY`,7.5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 L 14,14 M 1,14 L 14,1`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2.5),e.append(`marker`).attr(`id`,n+`_`+t+`-crossStart-margin`).attr(`class`,`marker cross `+t).attr(`viewBox`,`0 0 15 15`).attr(`refX`,-3.5).attr(`refY`,7.5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 1,1 L 14,14 M 1,14 L 14,1`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,2.5).style(`stroke-dasharray`,`1,0`)},`cross`),barb:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd`).attr(`refX`,19).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L9,13 L14,7 L9,1 Z`)},`barb`),barbNeo:a((e,t,n)=>{let{themeVariables:r}=S(),{transitionColor:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd`).attr(`refX`,19).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`strokeWidth`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L11,14 L13,7 L11,0 Z`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-barbEnd-margin`).attr(`refX`,17).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,14).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 19,7 L11,14 L13,7 L11,0 Z`).attr(`fill`,`${i}`)},`barbNeo`),hierarchy:a((e,t,n)=>{e.append(`marker`).attr(`id`,n+`_`+t+`-hierarchyEnd`).attr(`class`,`marker hierarchy `+t).attr(`viewBox`,`0 0 12 10`).attr(`refX`,10).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,10).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 6 5 L 0 10 M 4 0 L 10 5 L 4 10`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`).style(`fill`,`none`),e.append(`marker`).attr(`id`,n+`_`+t+`-hierarchyStart`).attr(`class`,`marker hierarchy `+t).attr(`viewBox`,`0 0 12 10`).attr(`refX`,2).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,10).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 12 0 L 6 5 L 12 10 M 8 0 L 2 5 L 8 10`).attr(`class`,`arrowMarkerPath`).style(`stroke-width`,1).style(`stroke-dasharray`,`1,0`).style(`fill`,`none`)},`hierarchy`),only_one:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneStart`).attr(`class`,`marker onlyOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).append(`path`).attr(`d`,`M9,0 L9,18 M15,0 L15,18`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneEnd`).attr(`class`,`marker onlyOne `+t).attr(`refX`,18).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,0 L3,18 M9,0 L9,18`)},`only_one`),zero_or_one:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneStart`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`);r.append(`circle`).attr(`fill`,`white`).attr(`cx`,21).attr(`cy`,9).attr(`r`,6),r.append(`path`).attr(`d`,`M9,0 L9,18`);let i=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneEnd`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,30).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`);i.append(`circle`).attr(`fill`,`white`).attr(`cx`,9).attr(`cy`,9).attr(`r`,6),i.append(`path`).attr(`d`,`M21,0 L21,18`)},`zero_or_one`),one_or_more:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreStart`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).append(`path`).attr(`d`,`M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreEnd`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,27).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18`)},`one_or_more`),zero_or_more:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreStart`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`);r.append(`circle`).attr(`fill`,`white`).attr(`cx`,48).attr(`cy`,18).attr(`r`,6),r.append(`path`).attr(`d`,`M0,18 Q18,0 36,18 Q18,36 0,18`);let i=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreEnd`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,39).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`);i.append(`circle`).attr(`fill`,`white`).attr(`cx`,9).attr(`cy`,18).attr(`r`,6),i.append(`path`).attr(`d`,`M21,18 Q39,0 57,18 Q39,36 21,18`)},`zero_or_more`),only_one_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneStart`).attr(`class`,`marker onlyOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M9,0 L9,18 M15,0 L15,18`).attr(`stroke-width`,`${i}`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-onlyOneEnd`).attr(`class`,`marker onlyOne `+t).attr(`refX`,18).attr(`refY`,9).attr(`markerWidth`,18).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M3,0 L3,18 M9,0 L9,18`).attr(`stroke-width`,`${i}`)},`only_one_neo`),zero_or_one_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i,mainBkg:a}=r,o=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneStart`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,0).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`);o.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,21).attr(`cy`,9).attr(`stroke-width`,`${i}`).attr(`r`,6),o.append(`path`).attr(`d`,`M9,0 L9,18`).attr(`stroke-width`,`${i}`);let s=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrOneEnd`).attr(`class`,`marker zeroOrOne `+t).attr(`refX`,30).attr(`refY`,9).attr(`markerWidth`,30).attr(`markerHeight`,18).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`);s.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,9).attr(`cy`,9).attr(`stroke-width`,`${i}`).attr(`r`,6),s.append(`path`).attr(`d`,`M21,0 L21,18`).attr(`stroke-width`,`${i}`)},`zero_or_one_neo`),one_or_more_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreStart`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`path`).attr(`d`,`M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27`).attr(`stroke-width`,`${i}`),e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-oneOrMoreEnd`).attr(`class`,`marker oneOrMore `+t).attr(`refX`,27).attr(`refY`,18).attr(`markerWidth`,45).attr(`markerHeight`,36).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`).append(`path`).attr(`d`,`M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18`).attr(`stroke-width`,`${i}`)},`one_or_more_neo`),zero_or_more_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i,mainBkg:a}=r,o=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreStart`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,18).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`markerUnits`,`userSpaceOnUse`).attr(`orient`,`auto`);o.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,45.5).attr(`cy`,18).attr(`r`,6).attr(`stroke-width`,`${i}`),o.append(`path`).attr(`d`,`M0,18 Q18,0 36,18 Q18,36 0,18`).attr(`stroke-width`,`${i}`);let s=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-zeroOrMoreEnd`).attr(`class`,`marker zeroOrMore `+t).attr(`refX`,39).attr(`refY`,18).attr(`markerWidth`,57).attr(`markerHeight`,36).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`);s.append(`circle`).attr(`fill`,a??`white`).attr(`cx`,11).attr(`cy`,18).attr(`r`,6).attr(`stroke-width`,`${i}`),s.append(`path`).attr(`d`,`M21,18 Q39,0 57,18 Q39,36 21,18`).attr(`stroke-width`,`${i}`)},`zero_or_more_neo`),requirement_arrow:a((e,t,n)=>{e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_arrowEnd`).attr(`refX`,20).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).append(`path`).attr(`d`,`M0,0 + L20,10 + M20,10 + L0,20`)},`requirement_arrow`),requirement_contains:a((e,t,n)=>{let r=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).append(`g`);r.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),r.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),r.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10)},`requirement_contains`),requirement_arrow_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r;e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_arrowEnd`).attr(`refX`,20).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).attr(`stroke-width`,`${i}`).attr(`viewBox`,`0 0 25 20`).append(`path`).attr(`d`,`M0,0 + L20,10 + M20,10 + L0,20`).attr(`stroke-linejoin`,`miter`)},`requirement_arrow_neo`),requirement_contains_neo:a((e,t,n)=>{let{themeVariables:r}=S(),{strokeWidth:i}=r,a=e.append(`defs`).append(`marker`).attr(`id`,n+`_`+t+`-requirement_containsStart`).attr(`refX`,0).attr(`refY`,10).attr(`markerWidth`,20).attr(`markerHeight`,20).attr(`orient`,`auto`).attr(`markerUnits`,`userSpaceOnUse`).append(`g`);a.append(`circle`).attr(`cx`,10).attr(`cy`,10).attr(`r`,9).attr(`fill`,`none`),a.append(`line`).attr(`x1`,1).attr(`x2`,19).attr(`y1`,10).attr(`y2`,10),a.append(`line`).attr(`y1`,1).attr(`y2`,19).attr(`x1`,10).attr(`x2`,10),a.selectAll(`*`).attr(`stroke-width`,`${i}`)},`requirement_contains_neo`)},so=q,co={common:M,getConfig:S,insertCluster:Oa,insertEdge:no,insertEdgeLabel:Ga,insertMarkers:so,insertNode:Ie,interpolateToCurve:ae,labelHelper:Ne,log:n,positionEdgeLabel:qa},lo=[`elk.stress`,`elk.force`,`elk.mrtree`,`elk.sporeOverlap`,`elk.box`,`elk.rectpacking`],uo=Object.create(null),fo=a(e=>{for(let t of e)uo[t.name]=t},`registerLayoutLoaders`),po=a(()=>{let e=a(async()=>await w(()=>import(`./elk-276RUBZZ-On_DNuCd.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16])),`loader`);return[{name:`elk`,loader:e,algorithm:`elk.layered`},...lo.map(t=>({name:t,loader:e,algorithm:t}))]},`elkLayoutLoaders`);a(()=>{fo([{name:`dagre`,loader:a(async()=>await w(()=>import(`./dagre-6A5THRUB-Bmed3uZj.js`),__vite__mapDeps([17,1,2,3,4,5,6,7,8,9,10,11,12,15,18,14,13])),`loader`)},{name:`swimlane`,loader:a(async()=>await w(()=>import(`./swimlanes-2SLR337P-BKvviDHP.js`),__vite__mapDeps([19,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16])),`loader`)},{name:`cose-bilkent`,loader:a(async()=>await w(()=>import(`./cose-bilkent-JH36ORCC-BtJFQFL9.js`),__vite__mapDeps([20,1,2,21])),`loader`)},...po()])},`registerDefaultLayoutLoaders`)();var mo=a(async(e,t)=>{if(!Object.hasOwn(uo,e.layoutAlgorithm))throw Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);if(e.diagramId)for(let t of e.nodes){let n=t.domId||t.id;t.domId=`${e.diagramId}-${n}`}let n=uo[e.layoutAlgorithm],r=await n.loader();return fa(t,e.config),r.render(e,t,co,{algorithm:n.algorithm})},`render`),ho=`dagre`,go=a((e=``,{fallback:t=ho}={})=>{if(Object.hasOwn(uo,e))return e;for(let r of[t,ho])if(Object.hasOwn(uo,r))return n.warn(`Layout algorithm ${e} is not registered. Using ${r} as fallback.`),r;throw Error(`Neither layout algorithm ${e}, ${t}, nor ${ho} is registered.`)},`getRegisteredLayoutAlgorithm`),_o=`comm`,vo=`rule`,yo=`decl`,bo=`@import`,xo=`@namespace`,So=`@keyframes`,Co=`@layer`,wo=Math.abs,To=String.fromCharCode;function Eo(e){return e.trim()}function Do(e,t,n){return e.replace(t,n)}function Oo(e,t){return e.charCodeAt(t)|0}function ko(e,t,n){return e.slice(t,n)}function Ao(e){return e.length}function jo(e){return e.length}function Mo(e,t){return t.push(e),e}var No=1,Po=1,Fo=0,Io=0,Lo=0,Ro=``;function zo(e,t,n,r,i,a,o,s){return{value:e,root:t,parent:n,type:r,props:i,children:a,line:No,column:Po,length:o,return:``,siblings:s}}function Bo(){return Lo}function Vo(){return Lo=Io>0?Oo(Ro,--Io):0,Po--,Lo===10&&(Po=1,No--),Lo}function Ho(){return Lo=Io2||Ko(Lo)>3?``:` `}function Zo(e,t){for(;--t&&Ho()&&!(Lo<48||Lo>102||Lo>57&&Lo<65||Lo>70&&Lo<97););return Go(e,Wo()+(t<6&&Uo()==32&&Ho()==32))}function Qo(e){for(;Ho();)switch(Lo){case e:return Io;case 34:case 39:e!==34&&e!==39&&Qo(Lo);break;case 40:e===41&&Qo(e);break;case 92:Ho();break}return Io}function $o(e,t){for(;Ho()&&e+Lo!==57&&(e+Lo!==84||Uo()!==47););return`/*`+Go(t,Io-1)+`*`+To(e===47?e:Ho())}function es(e){for(;!Ko(Uo());)Ho();return Go(e,Io)}function ts(e){return Jo(ns(``,null,null,null,[``],e=qo(e),0,[0],e))}function ns(e,t,n,r,i,a,o,s,c){for(var l=0,u=0,d=o,f=0,p=0,m=0,h=1,g=1,_=1,v=0,y=0,b=``,x=i,S=a,C=r,w=b;g;)switch(m=y,y=Ho()){case 40:m!=108&&Oo(w,d-1)==58?(v++,w+=`(`):w+=Yo(y);break;case 41:v--,w+=`)`;break;case 34:case 39:case 91:w+=Yo(y);break;case 9:case 10:case 13:case 32:if(v>0){w+=To(y);break}w+=Xo(m);break;case 92:w+=Zo(Wo()-1,7);continue;case 47:switch(Uo()){case 42:case 47:Mo(is($o(Ho(),Wo()),t,n,c),c),(Ko(m||1)==5||Ko(Uo()||1)==5)&&Ao(w)&&ko(w,-1,void 0)!==` `&&(w+=` `);break;default:w+=`/`}break;case 123*h:s[l++]=Ao(w)*_;case 125*h:case 59:case 0:if(v>0&&y){w+=To(y);break}switch(y){case 0:case 125:g=0;case 59+u:_==-1&&(w=Do(w,/\f/g,``)),p>0&&(Ao(w)-d||h===0)&&Mo(p>32?as(w+`;`,r,n,d-1,c):as(Do(w,` `,``)+`;`,r,n,d-2,c),c);break;case 59:w+=`;`;default:if(Mo(C=rs(w,t,n,l,u,i,s,b,x=[],S=[],d,a),a),y===123){if(u===0)ns(w,t,C,C,x,a,d,s,S);else{switch(f){case 99:if(Oo(w,3)===110)break;case 108:if(Oo(w,2)===97)break;default:u=0;case 100:case 109:case 115:}u?ns(e,C,C,r&&Mo(rs(e,C,C,0,0,i,s,b,i,x=[],d,S),S),i,S,d,s,r?x:S):ns(w,C,C,C,[``],S,0,s,S)}}}l=u=p=0,h=_=1,b=w=``,d=o;break;case 58:d=1+Ao(w),p=m;default:if(h<1){if(y==123)--h;else if(y==125&&h++==0&&Vo()==125)continue}switch(w+=To(y),y*h){case 38:_=u>0?1:(w+=`\f`,-1);break;case 44:if(v>0)break;s[l++]=(Ao(w)-1)*_,_=1;break;case 64:Uo()===45&&(w+=Yo(Ho())),f=Uo(),u=d=Ao(b=w+=es(Wo())),y++;break;case 45:m===45&&Ao(w)==2&&(h=0)}}return a}function rs(e,t,n,r,i,a,o,s,c,l,u,d){for(var f=i-1,p=i===0?a:[``],m=jo(p),h=0,g=0,_=0;h0?p[v]+` `+y:Do(y,/&\f/g,p[v])))&&(c[_++]=b);return zo(e,t,n,i===0?vo:s,c,l,u,d)}function is(e,t,n,r){return zo(e,t,n,_o,To(Bo()),ko(e,2,-2),0,r)}function as(e,t,n,r,i){return zo(e,t,n,yo,ko(e,0,r),ko(e,r+1,-1),r,i)}function os(e,t){for(var n=``,r=0;r/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./c4Diagram-YGBWAQC7-Dp1I9kRE.js`);return{diagram:e}},__vite__mapDeps([22,1,2,3,4,5,6,7,8,9,10,11,23]));return{id:ls,diagram:e}},`loader`)},ds=`flowchart-v2`,fs={id:ds,detector:a(e=>/^\s*(graph|flowchart)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./flowDiagram-KWPJA3E3-BO7njBlM.js`);return{diagram:e}},__vite__mapDeps([24,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:ds,diagram:e}},`loader`)},ps=`agentflow`,ms={id:ps,detector:a(e=>/^\s*agentflow-beta\b/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-22UHCM2B-B4G_FQZz.js`);return{diagram:e}},__vite__mapDeps([30,1,2,3,28,4,5,6,7,8,10,9,11,12,29,23,25,26]));return{id:ps,diagram:e}},`loader`)},hs=`swimlane`,gs={id:hs,detector:a(e=>/^\s*swimlane-beta\b/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./swimlanesDiagram-TC7HE7FX-D2_PSbBF.js`);return{diagram:e}},__vite__mapDeps([31,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:hs,diagram:e}},`loader`)},_s=`er`,vs={id:_s,detector:a(e=>/^\s*erDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./erDiagram-OPXOYQCR-YD8i2JM4.js`);return{diagram:e}},__vite__mapDeps([32,1,2,3,28,4,5,6,7,8,10,9,11,12,25,26]));return{id:_s,diagram:e}},`loader`)},ys=`gitGraph`,bs={id:ys,detector:a(e=>/^\s*gitGraph/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./gitGraphDiagram-X574FWY7-BEOc0w88.js`);return{diagram:e}},__vite__mapDeps([33,1,2,3,4,5,34,35,36,37]));return{id:ys,diagram:e}},`loader`)},xs=`gantt`,Ss={id:xs,detector:a(e=>/^\s*gantt/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ganttDiagram-FUAMR5RP-DWE1bJiy.js`);return{diagram:e}},__vite__mapDeps([38,1,2,3,39,40,41,5,4]));return{id:xs,diagram:e}},`loader`)},Cs=`info`,ws={id:Cs,detector:a(e=>/^\s*info/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./infoDiagram-VRGFBTTK-B6TQ-HH9.js`);return{diagram:e}},__vite__mapDeps([42,1,2,3,34,35]));return{id:Cs,diagram:e}},`loader`)},Ts=`pie`,Es={id:Ts,detector:a(e=>/^\s*pie/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./pieDiagram-5QR66LMP-0Fjx8Dye.js`);return{diagram:e}},__vite__mapDeps([43,1,2,3,44,41,45,5,46,47,4,34,35,36]));return{id:Ts,diagram:e}},`loader`)},Ds=`quadrantChart`,Os={id:Ds,detector:a(e=>/^\s*quadrantChart/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./quadrantDiagram-O4NWA36T-Crj0r6Xm.js`);return{diagram:e}},__vite__mapDeps([48,1,2,3,39,40,41]));return{id:Ds,diagram:e}},`loader`)},ks=`xychart`,As={id:ks,detector:a(e=>/^\s*xychart(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./xychartDiagram-PMCCYNJV-BE8PLguK.js`);return{diagram:e}},__vite__mapDeps([49,1,2,3,39,40,41,44,4,5,50,45,47,7,8]));return{id:ks,diagram:e}},`loader`)},js=`requirement`,Ms={id:js,detector:a(e=>/^\s*requirement(Diagram)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./requirementDiagram-PLB6GJNP-C2fhrVbm.js`);return{diagram:e}},__vite__mapDeps([51,1,2,3,4,5,6,7,8,10,9,11,12,25,26]));return{id:js,diagram:e}},`loader`)},Ns=`sequence`,Ps={id:Ns,detector:a(e=>/^\s*sequenceDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./sequenceDiagram-PO4LG4MO-BKPSlgwc.js`);return{diagram:e}},__vite__mapDeps([52,1,2,3,5,4,23,37]));return{id:Ns,diagram:e}},`loader`)},Fs=`classDiagram`,Is={id:Fs,detector:a(e=>/^\s*classDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./classDiagram-v2-NBCMYWYE-DLd33yZL.js`);return{diagram:e}},__vite__mapDeps([53,1,2,3,4,5,6,7,8,10,9,11,12,29,23,25,26]));return{id:Fs,diagram:e}},`loader`)},Ls=`stateDiagram`,Rs={id:Ls,detector:a(e=>/^\s*stateDiagram/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./stateDiagram-v2-GCMORJYK-CepxBhD6.js`);return{diagram:e}},__vite__mapDeps([54,1,2,3,4,5,6,7,8,10,9,11,12,23,25,26]));return{id:Ls,diagram:e}},`loader`)},zs=`journey`,Bs={id:zs,detector:a(e=>/^\s*journey/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./journeyDiagram-ZHPQQLJL-Bik9qTx9.js`);return{diagram:e}},__vite__mapDeps([55,1,2,3,46,45,5,29,23]));return{id:zs,diagram:e}},`loader`)},Vs={draw:a((e,t,r)=>{n.debug(`rendering svg for syntax error +`);let i=Ar(t),a=i.append(`g`);i.attr(`viewBox`,`0 0 2412 512`),C(i,100,512,!0),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z`),a.append(`path`).attr(`class`,`error-icon`).attr(`d`,`m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z`),a.append(`text`).attr(`class`,`error-text`).attr(`x`,1440).attr(`y`,250).attr(`font-size`,`150px`).style(`text-anchor`,`middle`).text(`Syntax error in text`),a.append(`text`).attr(`class`,`error-text`).attr(`x`,1250).attr(`y`,400).attr(`font-size`,`100px`).style(`text-anchor`,`middle`).text(`mermaid version ${r}`)},`draw`)},Hs=Vs,Us={db:{},renderer:Vs,parser:{parse:a(()=>{},`parse`)}},Ws=`flowchart-elk`,Gs={id:Ws,detector:a((e,t={})=>/^\s*flowchart-elk/.test(e)?(t.layout=`elk`,!0):!1,`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./flowDiagram-KWPJA3E3-BO7njBlM.js`);return{diagram:e}},__vite__mapDeps([24,1,2,3,4,5,6,7,8,9,10,11,12,23,25,26,27,28,29]));return{id:Ws,diagram:e}},`loader`)},Ks=`timeline`,qs={id:Ks,detector:a(e=>/^\s*timeline/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./timeline-definition-EJHVYXUP-Cj4l_LOm.js`);return{diagram:e}},__vite__mapDeps([56,1,2,3,46,45,5,4,10]));return{id:Ks,diagram:e}},`loader`)},Js=`mindmap`,Ys={id:Js,detector:a(e=>/^\s*mindmap/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./mindmap-definition-NLK3R4M7-BCTxemjG.js`);return{diagram:e}},__vite__mapDeps([57,1,2,3,4,5,6,7,8,9,10,11,12,25,26]));return{id:Js,diagram:e}},`loader`)},Xs=`kanban`,Zs={id:Xs,detector:a(e=>/^\s*kanban/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./kanban-definition-PNTS6WVX-BAMaaT6d.js`);return{diagram:e}},__vite__mapDeps([58,1,2,3,4,5,6,7,8,9,10,11,12,29]));return{id:Xs,diagram:e}},`loader`)},Qs=`sankey`,$s={id:Qs,detector:a(e=>/^\s*sankey(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js`);return{diagram:e}},__vite__mapDeps([59,1,2,3,44,41]));return{id:Qs,diagram:e}},`loader`)},ec=`packet`,tc={id:ec,detector:a(e=>/^\s*packet(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-MLGK6HIB-DILal1CA.js`);return{diagram:e}},__vite__mapDeps([60,1,2,3,4,5,34,35,36]));return{id:ec,diagram:e}},`loader`)},nc=`radar`,rc={id:nc,detector:a(e=>/^\s*radar-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-MPIPVDR6-8w_EEv4v.js`);return{diagram:e}},__vite__mapDeps([61,1,2,3,4,5,34,35,36]));return{id:nc,diagram:e}},`loader`)},ic=`block`,ac={id:ic,detector:a(e=>/^\s*block(-beta)?/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./blockDiagram-BEXU5L5S-LcLXSRjx.js`);return{diagram:e}},__vite__mapDeps([62,1,2,3,28,4,5,6,7,8,10,9,11,12,29,14,15]));return{id:ic,diagram:e}},`loader`)},oc=`treeView`,sc={id:oc,detector:a(e=>/^\s*treeView-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-CDSNMT55-DcWw9GHj.js`);return{diagram:e}},__vite__mapDeps([63,1,2,3,4,5,7,34,35,36,37]));return{id:oc,diagram:e}},`loader`)},cc=`architecture`,lc={id:cc,detector:a(e=>/^\s*architecture/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./architectureDiagram-NJMV4G6O-CQM7JOeV.js`);return{diagram:e}},__vite__mapDeps([64,1,2,3,4,5,7,8,34,35,36,21]));return{id:cc,diagram:e}},`loader`)},uc=`eventmodeling`,dc={id:uc,detector:a(e=>/^\s*eventmodeling/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-ATOU4E4O-BNgT_lbL.js`);return{diagram:e}},__vite__mapDeps([65,1,2,3,4,5,35,34,36]));return{id:uc,diagram:e}},`loader`)},fc=`ishikawa`,pc={id:fc,detector:a(e=>/^\s*ishikawa(-beta)?\b/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ishikawaDiagram-OU5B5YK6-BuTYOHFo.js`);return{diagram:e}},__vite__mapDeps([66,1,2,3,4,5,11]));return{id:fc,diagram:e}},`loader`)},mc=`venn`,hc={id:mc,detector:a(e=>/^\s*venn-beta/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./vennDiagram-UO4OBE2U-Bq0yqgVW.js`);return{diagram:e}},__vite__mapDeps([67,1,2,3,4,5,11]));return{id:mc,diagram:e}},`loader`)},gc=`treemap`,_c={id:gc,detector:a(e=>/^\s*treemap/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./diagram-3UASUU5V-Dv_f5rjj.js`);return{diagram:e}},__vite__mapDeps([68,1,2,3,44,41,40,4,5,6,34,35,36,26]));return{id:gc,diagram:e}},`loader`)},vc=`usecase`,yc={id:vc,detector:a(e=>/^\s*usecase-beta(?:\s|$)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./usecaseDiagram-POWQR4AR-1e9d35eQ.js`);return{diagram:e}},__vite__mapDeps([69,1,2,3,4,5,6,7,8,10,9,11,12,15,18,25,26]));return{id:vc,diagram:e}},`loader`)},bc=`wardley`,xc={id:bc,detector:a(e=>/^\s*wardley-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./wardleyDiagram-VNRHLVJA-DPtbrmxX.js`);return{diagram:e}},__vite__mapDeps([70,1,2,3,4,5,34,35,36]));return{id:bc,diagram:e}},`loader`)},Sc=`cynefin`,Cc={id:Sc,detector:a(e=>/^\s*cynefin-beta(?:[\s:]|$)/.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./cynefinDiagram-VND7K2PF-9xRwA2wI.js`);return{diagram:e}},__vite__mapDeps([71,1,2,3,4,5,34,35,36]));return{id:Sc,diagram:e}},`loader`)},wc=`railroad`,Tc={id:wc,detector:a(e=>/^\s*railroad-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./railroadDiagram-XR7U4H2S-BHZ1Lx2I.js`);return{diagram:e}},__vite__mapDeps([72,1,2,3,34,35,73,36]));return{id:wc,diagram:e}},`loader`)},Ec=`railroadEbnf`,Dc={id:Ec,detector:a(e=>/^\s*railroad-ebnf-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./ebnfDiagram-ZINNZB2B-CGBBBydS.js`);return{diagram:e}},__vite__mapDeps([74,1,2,3,34,35,73,36]));return{id:Ec,diagram:e}},`loader`)},Oc=`railroadAbnf`,kc={id:Oc,detector:a(e=>/^\s*railroad-abnf-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./abnfDiagram-O67JEVCF-CQJZpKdi.js`);return{diagram:e}},__vite__mapDeps([75,1,2,3,34,35,73,36]));return{id:Oc,diagram:e}},`loader`)},Ac=`railroadPeg`,jc={id:Ac,detector:a(e=>/^\s*railroad-peg-beta/i.test(e),`detector`),loader:a(async()=>{let{diagram:e}=await w(async()=>{let{diagram:e}=await import(`./pegDiagram-GJSIUBJH-B0Gktij4.js`);return{diagram:e}},__vite__mapDeps([76,1,2,3,34,35,73,36]));return{id:Ac,diagram:e}},`loader`)},Mc=!1,Nc=a(()=>{Mc||(Mc=!0,p(`error`,Us,e=>e.toLowerCase().trim()===`error`),p(`---`,{db:{clear:a(()=>{},`clear`)},styles:{},renderer:{draw:a(()=>{},`draw`)},parser:{parse:a(()=>{throw Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},`parse`)},init:a(()=>null,`init`)},e=>e.toLowerCase().trimStart().startsWith(`---`)),m(Gs,Ys,lc),m(ms,us,Zs,Is,vs,Ss,ws,Es,Ms,Ps,gs,fs,qs,bs,Rs,Bs,Os,$s,tc,As,ac,dc,sc,rc,pc,_c,Tc,Dc,kc,jc,hc,xc,Cc,yc))},`addDiagrams`),Pc=a(async()=>{n.debug(`Loading registered diagrams`);let e=(await Promise.allSettled(Object.entries(O).map(async([e,{detector:t,loader:r}])=>{if(r)try{g(e)}catch{try{let{diagram:e,id:n}=await r();p(n,e,t)}catch(t){throw n.error(`Failed to load external diagram with key ${e}. Removing from detectors.`),delete O[e],t}}}))).filter(e=>e.status===`rejected`);if(e.length>0){n.error(`Failed to load ${e.length} external diagrams`);for(let t of e)n.error(t);throw Error(`Failed to load ${e.length} external diagrams`)}},`loadRegisteredDiagrams`),Fc=`graphics-document document`;function Ic(e,t){e.attr(`role`,Fc),t!==``&&e.attr(`aria-roledescription`,t)}a(Ic,`setA11yDiagramInfo`);function Lc(e,t,n,r){if(e.insert!==void 0){if(n){let t=`chart-desc-${r}`;e.attr(`aria-describedby`,t),e.insert(`desc`,`:first-child`).attr(`id`,t).text(n)}if(t){let n=`chart-title-${r}`;e.attr(`aria-labelledby`,n),e.insert(`title`,`:first-child`).attr(`id`,n).text(t)}}}a(Lc,`addSVGa11yTitleDescription`);var Rc=class e{constructor(e,t,n,r,i){this.type=e,this.text=t,this.db=n,this.parser=r,this.renderer=i}static{a(this,`Diagram`)}static async fromText(t,r={}){let i=typeof t==`string`?{raw:t,cleaned:t}:t,a=S(),o=A(i.cleaned,a);try{g(o)}catch{let e=s(o);if(!e)throw new N(`Diagram ${o} not found.`);let{id:t,diagram:n}=await e();p(t,n)}let{db:c,parser:l,renderer:u,init:d}=g(o);l.parser&&(l.parser.yy=c),c.clear?.(),d?.(a),r.title&&c.setDiagramTitle?.(r.title);let f=i.cleaned;if(c.preserveCommentsWhenParsing&&i.withComments){let e=a.maxTextSize??T.maxTextSize;i.withComments.length>e?n.warn(`Comment-preserving source exceeds maxTextSize (${i.withComments.length} > ${e}); parsing the comment-stripped text instead. Reported source positions will not account for comment lines.`):f=i.withComments}let m=fe(f)+` +`;return i.frontmatterLineOffset&&c.setFrontmatterLineOffset?.(i.frontmatterLineOffset),await l.parse(m),new e(o,m,c,l,u)}async render(e,t){await this.renderer.draw(this.text,e,t,this)}getParser(){return this.parser}getType(){return this.type}},zc=[],Bc=a(()=>{zc.forEach(e=>{e()}),zc=[]},`attachFunctions`),Vc=a(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,``).trimStart(),`cleanupComments`);function Hc(e){let t=e.match(x);if(!t)return{text:e,metadata:{}};let n=t[1],r=ia(n?t[2].split(` +`).map(e=>e.startsWith(n)?e.slice(n.length):e).join(` +`):t[2],{schema:ta})??{};r=typeof r==`object`&&!Array.isArray(r)?r:{};let i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:e.slice(t[0].length),metadata:i}}a(Hc,`extractFrontMatter`);var Uc=a(e=>e.replace(/\r\n?/g,` +`).replace(/<(\w+)([^>]*)>/g,(e,t,n)=>`<`+t+n.replace(/="([^"]*)"/g,`='$1'`)+`>`),`cleanupText`),Wc=a(e=>{let{text:t,metadata:n}=Hc(e),{displayMode:r,title:i,config:a={}}=n;return r&&(a.gantt||={},a.gantt.displayMode=r),{title:i,config:a,text:t}},`processFrontmatter`),Gc=a(e=>{let t=ce.detectInit(e)??{},n=ce.detectDirective(e,`wrap`);return Array.isArray(n)?t.wrap=n.some(({type:e})=>e===`wrap`):n?.type===`wrap`&&(t.wrap=!0),{text:le(e),directive:t}},`processDirectives`);function Kc(e){let t=e,n=Uc(e),r=Wc(n),i=Gc(r.text),a=ue(r.config,i.directive),o=i.text;return{code:{raw:t,cleaned:Vc(o),withComments:o,frontmatterLineOffset:n.length>r.text.length?(n.substring(0,n.length-r.text.length).match(/\n/g)??[]).length:0},title:r.title,config:a}}a(Kc,`preprocessDiagram`);function qc(e){let t=new TextEncoder().encode(e),n=Array.from(t,e=>String.fromCodePoint(e)).join(``);return btoa(n)}a(qc,`toBase64`);var Jc=5e4,Yc=`graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa`,Xc=`sandbox`,Zc=`loose`,Qc=`http://www.w3.org/2000/svg`,$c=`http://www.w3.org/1999/xlink`,el=`http://www.w3.org/1999/xhtml`,tl=`100%`,nl=`100%`,rl=`border:0;margin:0;`,il=`margin:0`,al=`allow-top-navigation-by-user-activation allow-popups`,ol=`The "iframe" tag is not supported by your browser.`,sl=[`foreignobject`],cl=[`dominant-baseline`];function ll(e){let t=Kc(e);l();let n;try{n=A(t.code.cleaned,S())}catch{n=void 0}return d(n),k(t.config??{}),t}a(ll,`processAndSetConfigs`);async function ul(e,t){Nc();try{let{code:t,config:n}=ll(e);return{diagramType:(await Rc.fromText(t)).type,config:n}}catch(e){if(t?.suppressErrors)return!1;throw e}finally{d(void 0)}}a(ul,`parse`);var dl=a((e,t,n=[])=>`.${e} ${t} ${f(`{ ${n.join(` !important; `)} !important; }`)}`,`cssImportantStyles`),fl=a((e,t=new Map)=>{let n=new CSSStyleSheet;if(e.fontFamily!==void 0&&n.insertRule(`:root { --mermaid-font-family: ${e.fontFamily}}`,n.cssRules.length),e.altFontFamily!==void 0&&n.insertRule(`:root { --mermaid-alt-font-family: ${e.altFontFamily}}`,n.cssRules.length),t instanceof Map){let r=_(e)?[`> *`,`span`]:[`rect`,`polygon`,`ellipse`,`circle`,`path`];t.forEach(e=>{ma(e.styles)||r.forEach(t=>{n.insertRule(dl(e.id,t,e.styles),n.cssRules.length)}),ma(e.textStyles)||n.insertRule(dl(e.id,`tspan`,(e?.textStyles||[]).map(e=>e.replace(`color`,`fill`))),n.cssRules.length)})}let r=``;if(e.themeCSS!==void 0){if(typeof n.replaceSync==`function`){let t=new CSSStyleSheet;t.replaceSync(e.themeCSS),r=D(t)+` +`}else r+=`${e.themeCSS} +`}return r+D(n)},`createCssStyles`),pl=a((e,t)=>os(ts(`${e}{${t}}`),cs([a(function(t,r,i,a){if(t.type===`rule`&&Array.isArray(t.props)){if(t.parent&&t.parent.type===`@keyframes`)return;t.props=t.props.map(n=>n===e&&Array.isArray(t.children)&&t.children.every(e=>e.type===`decl`&&new Set([`font-family`,`font-size`,`fill`]).has(e.props))||(n.startsWith(`${e} `)||n.startsWith(`${e}>`))&&!n.startsWith(`${e} ||`)?n:`${e} ${n}`)}else t.type.startsWith(`@`)&&([`@media`,`@supports`,`@layer`,`@scope`,`@container`,`@starting-style`,`@keyframes`].includes(t.type)||(n.warn(`Removing unsupported at-rule ${t.type} from CSS`),t.type=_o))},`addNamespace`),ss])),`compileCSS`),ml=a((e,t,n,r)=>{let i=fl(e,n);return pl(r,b(t,i,{...e.themeVariables,theme:e.theme,look:e.look},r))},`createUserStyles`),hl=a((e=``,t,n)=>{let r=e;return!n&&!t&&(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,`marker-end="url(#`)),r=ie(r),r=r.replace(/
    /g,`
    `),r},`cleanUpSvgCode`),gl=a((e=``,t)=>``,`putIntoIFrame`),_l=a((e,t,n,r,i)=>{let a=e.append(`div`);a.attr(`id`,n),r&&a.attr(`style`,r);let o=a.append(`svg`).attr(`id`,t).attr(`width`,`100%`).attr(`xmlns`,Qc);return i&&o.attr(`xmlns:xlink`,i),o.append(`g`),e},`appendDivSvgG`);function vl(e,t){return e.append(`iframe`).attr(`id`,t).attr(`style`,`width: 100%; height: 100%;`).attr(`sandbox`,``)}a(vl,`sandboxedIframe`);var yl=a((e,t,n,r)=>{e.getElementById(t)?.remove(),e.getElementById(n)?.remove(),e.getElementById(r)?.remove()},`removeExistingElements`),bl=a(async function(e,t,i){Nc();let o=ll(t),s=o.code;t=s.cleaned;let c=S();n.debug(c),t.length>(c?.maxTextSize??Jc)&&(t=Yc,s={raw:t,cleaned:t});let l=`#${e}`,u=`i`+e,d=`#`+u,f=`d`+e,p=`#`+f,m=a(()=>{let e=r(g?d:p).node();e&&`remove`in e&&e.remove()},`removeTempElements`),h=r(document.body),g=c.securityLevel===Xc,_=c.securityLevel===Zc,v=c.fontFamily;if(i!==void 0){if(i&&(i.innerHTML=``),g){let e=vl(r(i),u);h=r(e.nodes()[0].contentDocument.body),h.node().style.margin=`0`}else h=r(i);_l(h,e,f,`font-family: ${v}`,$c)}else{if(yl(document,e,f,u),g){let e=vl(r(document.body),u);h=r(e.nodes()[0].contentDocument.body),h.node().style.margin=`0`}else h=r(`body`);_l(h,e,f)}let y,b;try{y=await Rc.fromText(s,{title:o.title})}catch(e){if(c.suppressErrorRendering)throw m(),e;y=await Rc.fromText(`error`),b=e}let x=h.select(p).node(),C=y.type,w=x.firstChild,T=w.firstChild,D=y.renderer.getClasses?.(t,y),O=ml(c,C,D,l),k=document.createElement(`style`);k.innerHTML=O,w.insertBefore(k,T);try{await y.renderer.draw(t,e,`12.0.0`,y)}catch(n){throw c.suppressErrorRendering?m():Hs.draw(t,e,`12.0.0`),n}let A=h.select(`${p} svg`),j=y.db.getAccTitle?.(),M=y.db.getAccDescription?.();wl(C,A,j,M);let N=a(()=>{h.select(`[id="${e}"]`).selectAll(`foreignobject > *`).attr(`xmlns`,el);let t=h.select(p).node().innerHTML;if(n.debug(`config.arrowMarkerAbsolute`,c.arrowMarkerAbsolute),t=hl(t,g,E(c.arrowMarkerAbsolute)),g){let e=h.select(p+` svg`).node();t=gl(t,e)}else _||(t=P.sanitize(t,{ADD_TAGS:sl,ADD_ATTR:cl,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));return Bc(),t},`serializeSvg`)();if(b)throw b;return m(),{diagramType:C,svg:N,bindFunctions:y.db.bindFunctions}},`renderDiagram`),xl=a(async function(e,t,n){try{return await bl(e,t,n)}finally{d(void 0)}},`render`);function Sl(e={}){let n=j({},e);n?.fontFamily&&!n.themeVariables?.fontFamily&&(n.themeVariables||={},n.themeVariables.fontFamily=n.fontFamily),v(n);let r=F.theme;n?.theme&&Object.hasOwn(h,n.theme)?n.themeVariables=h[n.theme].getThemeVariables(n.themeVariables):n&&(n.theme!=null&&n.theme!==`null`&&(n.theme=r),n.themeVariables=h[r].getThemeVariables(n.themeVariables));let i=typeof n==`object`?u(n):c();t(i.logLevel),Nc()}a(Sl,`initialize`);var Cl=a((e,t={})=>{let{code:n}=Kc(e);return Rc.fromText(n,t)},`getDiagramFromText`);function wl(e,t,n,r){Ic(t,e),Lc(t,n,r,t.attr(`id`))}a(wl,`addA11yInfo`);var Tl=Object.freeze({render:xl,parse:ul,getDiagramFromText:Cl,initialize:Sl,getConfig:S,setConfig:y,getSiteConfig:c,updateSiteConfig:o,reset:a(()=>{l()},`reset`),globalReset:a(()=>{l(F)},`globalReset`),defaultConfig:F});t(S().logLevel),l(S());var El=a((e,t,r)=>{n.warn(e),se(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},`handleError`),Dl=a(async function(e={querySelector:`.mermaid`}){try{await Ol(e)}catch(t){if(se(t)&&n.error(t.str),Y.parseError&&Y.parseError(t),!e.suppressErrors)throw n.error(`Use the suppressErrors option to suppress these errors`),t}},`run`),Ol=a(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:`.mermaid`}){let i=Tl.getConfig();n.debug(`${e?``:`No `}Callback function found`);let a;if(r)a=r;else if(t)a=document.querySelectorAll(t);else throw Error(`Nodes and querySelector are both undefined`);n.debug(`Found ${a.length} diagrams`),i?.startOnLoad!==void 0&&(n.debug(`Start On Load: `+i?.startOnLoad),Tl.updateSiteConfig({startOnLoad:i?.startOnLoad}));let o=new ce.InitIDGenerator(i.deterministicIds,i.deterministicIDSeed),s,c=[];for(let t of Array.from(a)){if(n.info(`Rendering diagram: `+t.id),t.getAttribute(`data-processed`))continue;t.setAttribute(`data-processed`,`true`);let r=`mermaid-${o.next()}`;s=t.innerHTML,s=Ee(ce.entityDecode(s)).trim().replace(//gi,`
    `);let i=ce.detectInit(s);i&&n.debug(`Detected early reinit: `,i);try{let{svg:n,bindFunctions:i}=await Ll(r,s,t);t.innerHTML=n,e&&await e(r),i&&i(t)}catch(e){El(e,c,Y.parseError)}}if(c.length>0)throw c[0]},`runThrowsErrors`),kl=a(function(e){Tl.initialize(e)},`initialize`),Al=a(async function(e,t,r){n.warn(`mermaid.init is deprecated. Please use run instead.`),e&&kl(e);let i={postRenderCallback:r,querySelector:`.mermaid`};typeof t==`string`?i.querySelector=t:t&&(i.nodes=t instanceof HTMLElement?[t]:t),await Dl(i)},`init`),jl=a(async(e,{lazyLoad:t=!0}={})=>{Nc(),m(...e),t===!1&&await Pc()},`registerExternalDiagrams`),Ml=a(function(){if(Y.startOnLoad){let{startOnLoad:e}=Tl.getConfig();e&&Y.run().catch(e=>n.error(`Mermaid failed to initialize`,e))}},`contentLoaded`);typeof document<`u`&&window.addEventListener(`load`,Ml,!1);var Nl=a(function(e){Y.parseError=e},`setParseErrorHandler`),Pl=[],Fl=!1,Il=a(async()=>{if(!Fl){for(Fl=!0;Pl.length>0;){let e=Pl.shift();if(e)try{await e()}catch(e){n.error(`Error executing queue`,e)}}Fl=!1}},`executeQueue`),J=a(async(e,t)=>new Promise((r,i)=>{let o=a(()=>new Promise((a,o)=>{Tl.parse(e,t).then(e=>{a(e),r(e)},e=>{n.error(`Error parsing`,e),Y.parseError?.(e),o(e),i(e)})}),`performCall`);Pl.push(o),Il().catch(i)}),`parse`),Ll=a((e,t,r)=>new Promise((i,o)=>{let s=a(()=>new Promise((a,s)=>{Tl.render(e,t,r).then(e=>{a(e),i(e)},e=>{n.error(`Error parsing`,e),Y.parseError?.(e),s(e),o(e)})}),`performCall`);Pl.push(s),Il().catch(o)}),`render`),Y={startOnLoad:!0,mermaidAPI:Tl,parse:J,render:Ll,init:Al,run:Dl,registerExternalDiagrams:jl,registerLayoutLoaders:fo,initialize:kl,parseError:void 0,contentLoaded:Ml,setParseErrorHandler:Nl,detectType:A,registerIconPacks:Te,getRegisteredDiagramsMetadata:a(()=>Object.keys(O).map(e=>({id:e})),`getRegisteredDiagramsMetadata`)},X=Y,Z=new Er({gfm:!0,breaks:!0,renderer:{code({text:e,lang:t}){return t===`mermaid`&&`
    ${e}
    \n`}}});function Rl(e){let t=e.split(` +`),n=[],r=!1,i=!1,a=0;for(let e=0;e{let s=e.toLowerCase().endsWith(`.md`)||e.toLowerCase().endsWith(`.markdown`),[c,l]=(0,V.useState)(s?`rendered`:`raw`),[u,d]=(0,V.useState)(!1),f=(0,V.useRef)(null),p=async()=>{if(t)try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(t),d(!0),setTimeout(()=>d(!1),2e3)}catch{}},m=e=>e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(1)} MB`,h=e?e.split(`/`).pop()||e:``,g=(0,V.useMemo)(()=>{if(!t)return``;try{let e=Rl(t);return Z.parse(e)}catch(e){return console.error(`Failed to parse markdown:`,e),`
    ${t}
    `}},[t]);return(0,V.useEffect)(()=>{if(c!==`rendered`||!f.current)return;let e=f.current.querySelectorAll(`.mermaid`);if(e.length!==0)try{X.initialize({startOnLoad:!1,theme:`dark`,securityLevel:`loose`,fontFamily:`monospace, sans-serif`,themeVariables:{darkMode:!0,background:`#07181b`,primaryColor:`#0891b2`,primaryTextColor:`#f8fafc`,primaryBorderColor:`#15474d`,lineColor:`#2dd4bf`,secondaryColor:`#164e63`,tertiaryColor:`#0d2c2f`}});let t=Array.from(e).filter(e=>!e.getAttribute(`data-processed`));t.length>0&&X.run({nodes:t}).catch(e=>{console.warn(`Mermaid rendering warning:`,e)})}catch(e){console.warn(`Failed to initialize mermaid:`,e)}},[g,c]),(0,H.jsxs)(`div`,{className:`nav-doc-reader`,"data-testid":`nav-doc-reader`,children:[(0,H.jsxs)(`div`,{className:`doc-reader-header`,children:[(0,H.jsxs)(`div`,{className:`doc-header-meta`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`})]}),(0,H.jsx)(`span`,{className:`doc-filename`,title:e,children:h}),(0,H.jsxs)(`span`,{className:`doc-badge-chip`,children:[n,` lines`]}),r>0&&(0,H.jsx)(`span`,{className:`doc-badge-chip`,children:m(r)})]}),(0,H.jsxs)(`div`,{className:`doc-header-actions`,children:[s&&(0,H.jsxs)(`div`,{className:`doc-view-toggle`,role:`group`,"aria-label":`Document View Mode`,children:[(0,H.jsx)(`button`,{type:`button`,className:`toggle-btn ${c===`rendered`?`active`:``}`,onClick:()=>l(`rendered`),"aria-pressed":c===`rendered`,children:`Rendered`}),(0,H.jsx)(`button`,{type:`button`,className:`toggle-btn ${c===`raw`?`active`:``}`,onClick:()=>l(`raw`),"aria-pressed":c===`raw`,children:`Raw Source`})]}),(0,H.jsx)(`button`,{type:`button`,className:`doc-copy-btn`,onClick:p,title:`Copy document content`,"aria-label":`Copy Document Content`,children:u?`✓ Copied!`:`Copy Content`})]})]}),(0,H.jsx)(`div`,{className:`doc-reader-body`,children:i?(0,H.jsxs)(`div`,{className:`doc-reader-loading`,"data-testid":`doc-loading`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):a?(0,H.jsxs)(`div`,{className:`doc-reader-error`,role:`alert`,children:[(0,H.jsxs)(`p`,{children:[`Failed to load file content: `,a]}),o&&(0,H.jsx)(`button`,{type:`button`,className:`btn btn-sm btn-primary`,onClick:o,children:`Retry`})]}):c===`rendered`&&s?(0,H.jsx)(`div`,{ref:f,className:`doc-rendered-content`,"data-testid":`doc-rendered-content`,dangerouslySetInnerHTML:{__html:g}}):(0,H.jsx)(`div`,{className:`doc-raw-container`,"data-testid":`doc-raw-content`,children:(0,H.jsx)(`pre`,{className:`doc-raw-pre`,children:(0,H.jsx)(`table`,{className:`doc-lines-table`,children:(0,H.jsx)(`tbody`,{children:t.split(` +`).map((e,t)=>(0,H.jsxs)(`tr`,{className:`doc-line-row`,children:[(0,H.jsx)(`td`,{className:`doc-line-num`,"data-line-number":t+1,children:t+1}),(0,H.jsx)(`td`,{className:`doc-line-code`,children:(0,H.jsx)(`code`,{children:e||` `})})]},t))})})})})})]})};function Bl(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`){if(Array.isArray(e)){var i=e.length;for(t=0;tt in e?Ul(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$l=(e,t)=>{for(var n in t||={})Xl.call(t,n)&&Ql(e,n,t[n]);if(Jl)for(var n of Jl(t))Zl.call(t,n)&&Ql(e,n,t[n]);return e},eu=(e,t)=>Wl(e,Kl(t)),tu=(e,t)=>{var n={};for(var r in e)Xl.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Jl)for(var r of Jl(e))t.indexOf(r)<0&&Zl.call(e,r)&&(n[r]=e[r]);return n},nu=(e,t)=>function(){return t||(0,e[ql(e)[0]])((t={exports:{}}).exports,t),t.exports},ru=(e,t)=>{for(var n in t)Ul(e,n,{get:t[n],enumerable:!0})},iu=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of ql(t))!Xl.call(e,i)&&i!==n&&Ul(e,i,{get:()=>t[i],enumerable:!(r=Gl(t,i))||r.enumerable});return e},Q=((e,t,n)=>(n=e==null?{}:Hl(Yl(e)),iu(t||!e||!e.__esModule?Ul(n,`default`,{value:e,enumerable:!0}):n,e)))(nu({"../../node_modules/.pnpm/prismjs@1.29.0_patch_hash=vrxx3pzkik6jpmgpayxfjunetu/node_modules/prismjs/prism.js"(e,t){var n=function(){var e=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,t=0,n={},r={util:{encode:function e(t){return t instanceof i?new i(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,`&`).replace(/`+a.content+``};function a(e,t,n,r){e.lastIndex=t;var i=e.exec(n);if(i&&r&&i[1]){var a=i[1].length;i.index+=a,i[0]=i[0].slice(a)}return i}function o(e,t,n,s,u,d){for(var f in n)if(!(!n.hasOwnProperty(f)||!n[f])){var p=n[f];p=Array.isArray(p)?p:[p];for(var m=0;m=d.reach);C+=S.value.length,S=S.next){var w=S.value;if(t.length>e.length)return;if(!(w instanceof i)){var T=1,E;if(v){if(E=a(x,C,e,_),!E||E.index>=e.length)break;var D=E.index,O=E.index+E[0].length,k=C;for(k+=S.value.length;D>=k;)S=S.next,k+=S.value.length;if(k-=S.value.length,C=k,S.value instanceof i)continue;for(var A=S;A!==t.tail&&(kd.reach&&(d.reach=P);var F=S.prev;M&&(F=c(t,F,M),C+=M.length),l(t,F,T);var I=new i(f,g?r.tokenize(j,g):j,y,j);if(S=c(t,F,I),N&&c(t,S,N),T>1){var L={cause:f+`,`+m,reach:P};o(e,t,n,S.prev,C,L),d&&L.reach>d.reach&&(d.reach=L.reach)}}}}}}function s(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function c(e,t,n){var r=t.next,i={value:n,prev:t,next:r};return t.next=i,r.prev=i,e.length++,i}function l(e,t,n){for(var r=t.next,i=0;i/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:`attr-equals`},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:`named-entity`},/&#x?[\da-f]{1,8};/i]},Q.languages.markup.tag.inside[`attr-value`].inside.entity=Q.languages.markup.entity,Q.languages.markup.doctype.inside[`internal-subset`].inside=Q.languages.markup,Q.hooks.add(`wrap`,function(e){e.type===`entity`&&(e.attributes.title=e.content.replace(/&/,`&`))}),Object.defineProperty(Q.languages.markup.tag,"addInlined",{value:function(e,t){var n={},n=(n[`language-`+t]={pattern:/(^$)/i,lookbehind:!0,inside:Q.languages[t]},n.cdata=/^$/i,{"included-cdata":{pattern://i,inside:n}}),t=(n[`language-`+t]={pattern:/[\s\S]+/,inside:Q.languages[t]},{});t[e]={pattern:RegExp(`(<__[^>]*>)(?:))*\\]\\]>|(?!)`.replace(/__/g,function(){return e}),`i`),lookbehind:!0,greedy:!0,inside:n},Q.languages.insertBefore(`markup`,`cdata`,t)}}),Object.defineProperty(Q.languages.markup.tag,"addAttribute",{value:function(e,t){Q.languages.markup.tag.inside[`special-attr`].push({pattern:RegExp(`(^|["'\\s])(?:`+e+`)\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s'">=]+(?=[\\s>]))`,`i`),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,`language-`+t],inside:Q.languages[t]},punctuation:[{pattern:/^=/,alias:`attr-equals`},/"|'/]}}}})}}),Q.languages.html=Q.languages.markup,Q.languages.mathml=Q.languages.markup,Q.languages.svg=Q.languages.markup,Q.languages.xml=Q.languages.extend(`markup`,{}),Q.languages.ssml=Q.languages.xml,Q.languages.atom=Q.languages.xml,Q.languages.rss=Q.languages.xml,function(e){var t={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:`escape`},n=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,r=`(?:[^\\\\-]|`+n.source+`)`,r=RegExp(r+`-`+r),i={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:`variable`};e.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:`operator`},"char-class-punctuation":{pattern:/^\[|\]$/,alias:`punctuation`},range:{pattern:r,inside:{escape:n,"range-punctuation":{pattern:/-/,alias:`operator`}}},"special-escape":t,"char-set":{pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:`class-name`},escape:n}},"special-escape":t,"char-set":{pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:`class-name`},backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:`keyword`},{pattern:/\\k<[^<>']+>/,alias:`keyword`,inside:{"group-name":i}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:`function`},escape:n,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},Q.languages.javascript=Q.languages.extend(`clike`,{"class-name":[Q.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Q.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Q.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:Q.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Q.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Q.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Q.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Q.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Q.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:Q.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),Q.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),Q.languages.markup&&(Q.languages.markup.tag.addInlined(`script`,`javascript`),Q.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),Q.languages.js=Q.languages.javascript,Q.languages.actionscript=Q.languages.extend(`javascript`,{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<>?>?|[!=]=?)=?|[~?@]/}),Q.languages.actionscript[`class-name`].alias=`function`,delete Q.languages.actionscript.parameter,delete Q.languages.actionscript[`literal-property`],Q.languages.markup&&Q.languages.insertBefore(`actionscript`,`string`,{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:Q.languages.markup}}),function(e){var t=/#(?!\{).+/,n={pattern:/#\{[^}]+\}/,alias:`variable`};e.languages.coffeescript=e.languages.extend(`javascript`,{comment:t,string:[{pattern:/'(?:\\[\s\S]|[^\\'])*'/,greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0,inside:{interpolation:n}}],keyword:/\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,"class-member":{pattern:/@(?!\d)\w+/,alias:`variable`}}),e.languages.insertBefore(`coffeescript`,`comment`,{"multiline-comment":{pattern:/###[\s\S]+?###/,alias:`comment`},"block-regex":{pattern:/\/{3}[\s\S]*?\/{3}/,alias:`regex`,inside:{comment:t,interpolation:n}}}),e.languages.insertBefore(`coffeescript`,`string`,{"inline-javascript":{pattern:/`(?:\\[\s\S]|[^\\`])*`/,inside:{delimiter:{pattern:/^`|`$/,alias:`punctuation`},script:{pattern:/[\s\S]+/,alias:`language-javascript`,inside:e.languages.javascript}}},"multiline-string":[{pattern:/'''[\s\S]*?'''/,greedy:!0,alias:`string`},{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:`string`,inside:{interpolation:n}}]}),e.languages.insertBefore(`coffeescript`,`keyword`,{property:/(?!\d)\w+(?=\s*:(?!:))/}),delete e.languages.coffeescript[`template-string`],e.languages.coffee=e.languages.coffeescript}(Q),function(e){var t=e.languages.javadoclike={parameter:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m,lookbehind:!0},keyword:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m,lookbehind:!0},punctuation:/[{}]/};Object.defineProperty(t,"addSupport",{value:function(t,n){(t=typeof t==`string`?[t]:t).forEach(function(t){var r=function(e){e.inside||={},e.inside.rest=n},i=`doc-comment`;if(a=e.languages[t]){var a,o=a[i];if((o||=(a=e.languages.insertBefore(t,`comment`,{"doc-comment":{pattern:/(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/,lookbehind:!0,alias:`comment`}}))[i])instanceof RegExp&&(o=a[i]={pattern:o}),Array.isArray(o))for(var s=0,c=o.length;s|\+|~|\|\|/,punctuation:/[(),]/}},e.languages.css.atrule.inside[`selector-function-argument`].inside=t,e.languages.insertBefore(`css`,`property`,{variable:{pattern:/(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,lookbehind:!0}}),{pattern:/(\b\d+)(?:%|[a-z]+(?![\w-]))/,lookbehind:!0}),n={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0};e.languages.insertBefore(`css`,`function`,{operator:{pattern:/(\s)[+\-*\/](?=\s)/,lookbehind:!0},hexcode:{pattern:/\B#[\da-f]{3,8}\b/i,alias:`color`},color:[{pattern:/(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|RebeccaPurple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,lookbehind:!0},{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:t,number:n,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:t,number:n})}(Q),function(e){var t=/[*&][^\s[\]{},]+/,n=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,r=`(?:`+n.source+`(?:[ ]+`+t.source+`)?|`+t.source+`(?:[ ]+`+n.source+`)?)`,i=`(?:[^\\s\\x00-\\x08\\x0e-\\x1f!"#%&'*,\\-:>?@[\\]\`{|}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]|[?:-])(?:[ \\t]*(?:(?![#:])|:))*`.replace(//g,function(){return`[^\\s\\x00-\\x08\\x0e-\\x1f,[\\]{}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]`}),a=`"(?:[^"\\\\\\r\\n]|\\\\.)*"|'(?:[^'\\\\\\r\\n]|\\\\.)*'`;function o(e,t){t=(t||``).replace(/m/g,``)+`m`;var n=`([:\\-,[{]\\s*(?:\\s<>[ \\t]+)?)(?:<>)(?=[ \\t]*(?:$|,|\\]|\\}|(?:[\\r\\n]\\s*)?#))`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return e});return RegExp(n,t)}e.languages.yaml={scalar:{pattern:RegExp(`([\\-:]\\s*(?:\\s<>[ \\t]+)?[|>])[ \\t]*(?:((?:\\r?\\n|\\r)[ \\t]+)\\S[^\\r\\n]*(?:\\2[^\\r\\n]+)*)`.replace(/<>/g,function(){return r})),lookbehind:!0,alias:`string`},comment:/#.*/,key:{pattern:RegExp(`((?:^|[:\\-,[{\\r\\n?])[ \\t]*(?:<>[ \\t]+)?)<>(?=\\s*:\\s)`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return`(?:`+i+`|`+a+`)`})),lookbehind:!0,greedy:!0,alias:`atrule`},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:`important`},datetime:{pattern:o(`\\d{4}-\\d\\d?-\\d\\d?(?:[tT]|[ \\t]+)\\d\\d?:\\d{2}:\\d{2}(?:\\.\\d*)?(?:[ \\t]*(?:Z|[-+]\\d\\d?(?::\\d{2})?))?|\\d{4}-\\d{2}-\\d{2}|\\d\\d?:\\d{2}(?::\\d{2}(?:\\.\\d*)?)?`),lookbehind:!0,alias:`number`},boolean:{pattern:o(`false|true`,`i`),lookbehind:!0,alias:`important`},null:{pattern:o(`null|~`,`i`),lookbehind:!0,alias:`important`},string:{pattern:o(a),lookbehind:!0,greedy:!0},number:{pattern:o(`[+-]?(?:0x[\\da-f]+|0o[0-7]+|(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:e[+-]?\\d+)?|\\.inf|\\.nan)`,`i`),lookbehind:!0},tag:n,important:t,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml}(Q),function(e){function t(e){return e=e.replace(//g,function(){return`(?:\\\\.|[^\\\\\\n\\r]|(?:\\n|\\r\\n?)(?![\\r\\n]))`}),RegExp(`((?:^|[^\\\\])(?:\\\\{2})*)(?:`+e+`)`)}var n="(?:\\\\.|``(?:[^`\\r\\n]|`(?!`))+``|`[^`\\r\\n]+`|[^\\\\|\\r\\n`])+",r=`\\|?__(?:\\|__)+\\|?(?:(?:\\n|\\r\\n?)|(?![\\s\\S]))`.replace(/__/g,function(){return n}),i=`\\|?[ \\t]*:?-{3,}:?[ \\t]*(?:\\|[ \\t]*:?-{3,}:?[ \\t]*)+\\|?(?:\\n|\\r\\n?)`,a=(e.languages.markdown=e.languages.extend(`markup`,{}),e.languages.insertBefore(`markdown`,`prolog`,{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:[`yaml`,`language-yaml`],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:`punctuation`},table:{pattern:RegExp(`^`+r+i+`(?:`+r+`)*`,`m`),inside:{"table-data-rows":{pattern:RegExp(`^(`+r+i+`)(?:`+r+`)*$`),lookbehind:!0,inside:{"table-data":{pattern:RegExp(n),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp(`^(`+r+`)`+i+`$`),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp(`^`+r+`$`),inside:{"table-header":{pattern:RegExp(n),alias:`important`,inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:`keyword`},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:`important`,inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:`important`,inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:`punctuation`},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:`punctuation`},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:`url`},bold:{pattern:t(`\\b__(?:(?!_)|_(?:(?!_))+_)+__\\b|\\*\\*(?:(?!\\*)|\\*(?:(?!\\*))+\\*)+\\*\\*`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:t(`\\b_(?:(?!_)|__(?:(?!_))+__)+_\\b|\\*(?:(?!\\*)|\\*\\*(?:(?!\\*))+\\*\\*)+\\*`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:t(`(~~?)(?:(?!~))+\\2`),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:[`code`,`keyword`]},url:{pattern:t(`!?\\[(?:(?!\\]))+\\](?:\\([^\\s)]+(?:[\\t ]+"(?:\\\\.|[^"\\\\])*")?\\)|[ \\t]?\\[(?:(?!\\]))+\\])`),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),[`url`,`bold`,`italic`,`strike`].forEach(function(t){[`url`,`bold`,`italic`,`strike`,`code-snippet`].forEach(function(n){t!==n&&(e.languages.markdown[t].inside.content.inside[n]=e.languages.markdown[n])})}),e.hooks.add(`after-tokenize`,function(e){e.language!==`markdown`&&e.language!==`md`||function e(t){if(t&&typeof t!=`string`)for(var n=0,r=t.length;n`,quot:`"`},s=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown}(Q),Q.languages.graphql={comment:/#.*/,description:{pattern:/(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i,greedy:!0,alias:`string`,inside:{"language-markdown":{pattern:/(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/,lookbehind:!0,inside:Q.languages.markdown}}},string:{pattern:/"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},number:/(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,boolean:/\b(?:false|true)\b/,variable:/\$[a-z_]\w*/i,directive:{pattern:/@[a-z_]\w*/i,alias:`function`},"attr-name":{pattern:/\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,greedy:!0},"atom-input":{pattern:/\b[A-Z]\w*Input\b/,alias:`class-name`},scalar:/\b(?:Boolean|Float|ID|Int|String)\b/,constant:/\b[A-Z][A-Z_\d]*\b/,"class-name":{pattern:/(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/,lookbehind:!0},fragment:{pattern:/(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},"definition-mutation":{pattern:/(\bmutation\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},"definition-query":{pattern:/(\bquery\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:`function`},keyword:/\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/,operator:/[!=|&]|\.{3}/,"property-query":/\w+(?=\s*\()/,object:/\w+(?=\s*\{)/,punctuation:/[!(){}\[\]:=,]/,property:/\w+/},Q.hooks.add(`after-tokenize`,function(e){if(e.language===`graphql`)for(var t=e.tokens.filter(function(e){return typeof e!=`string`&&e.type!==`comment`&&e.type!==`scalar`}),n=0;n?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},function(e){var t=e.languages.javascript[`template-string`],n=t.pattern.source,r=t.inside.interpolation,i=r.inside[`interpolation-punctuation`],a=r.pattern.source;function o(t,r){if(e.languages[t])return{pattern:RegExp(`((?:`+r+`)\\s*)`+n),lookbehind:!0,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},"embedded-code":{pattern:/[\s\S]+/,alias:t}}}}function s(t,n,r){return t={code:t,grammar:n,language:r},e.hooks.run(`before-tokenize`,t),t.tokens=e.tokenize(t.code,t.grammar),e.hooks.run(`after-tokenize`,t),t.tokens}function c(t,n,o){var c=e.tokenize(t,{interpolation:{pattern:RegExp(a),lookbehind:!0}}),l=0,u={},c=s(c.map(function(e){if(typeof e==`string`)return e;for(var n,r,e=e.content;t.indexOf((r=l++,n=`___`+o.toUpperCase()+`_`+r+`___`))!==-1;);return u[n]=e,n}).join(``),n,o),d=Object.keys(u);return l=0,function t(n){for(var a=0;a=d.length)return;var o,c,f,p,m,h,g,_=n[a];typeof _==`string`||typeof _.content==`string`?(o=d[l],(g=(h=typeof _==`string`?_:_.content).indexOf(o))!==-1&&(++l,c=h.substring(0,g),m=u[o],f=void 0,(p={})[`interpolation-punctuation`]=i,(p=e.tokenize(m,p)).length===3&&((f=[1,1]).push.apply(f,s(p[1],e.languages.javascript,`javascript`)),p.splice.apply(p,f)),f=new e.Token(`interpolation`,p,r.alias,m),p=h.substring(g+o.length),m=[],c&&m.push(c),m.push(f),p&&(t(h=[p]),m.push.apply(m,h)),typeof _==`string`?(n.splice.apply(n,[a,1].concat(m)),a+=m.length-1):_.content=m)):(g=_.content,t(Array.isArray(g)?g:[g]))}}(c),new e.Token(o,c,`language-`+o,t)}e.languages.javascript[`template-string`]=[o(`css`,`\\b(?:styled(?:\\([^)]*\\))?(?:\\s*\\.\\s*\\w+(?:\\([^)]*\\))*)*|css(?:\\s*\\.\\s*(?:global|resolve))?|createGlobalStyle|keyframes)`),o(`html`,`\\bhtml|\\.\\s*(?:inner|outer)HTML\\s*\\+?=`),o(`svg`,`\\bsvg`),o(`markdown`,`\\b(?:markdown|md)`),o(`graphql`,`\\b(?:gql|graphql(?:\\s*\\.\\s*experimental)?)`),o(`sql`,`\\bsql`),t].filter(Boolean);var l={javascript:!0,js:!0,typescript:!0,ts:!0,jsx:!0,tsx:!0};function u(e){return typeof e==`string`?e:Array.isArray(e)?e.map(u).join(``):u(e.content)}e.hooks.add(`after-tokenize`,function(t){t.language in l&&function t(n){for(var r=0,i=n.length;r]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript[`literal-property`];var t=e.languages.extend(`typescript`,{});delete t[`class-name`],e.languages.typescript[`class-name`].inside=t,e.languages.insertBefore(`typescript`,`function`,{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:`operator`},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:t}}}}),e.languages.ts=e.languages.typescript}(Q),function(e){var t=e.languages.javascript,n=`\\{(?:[^{}]|\\{(?:[^{}]|\\{[^{}]*\\})*\\})+\\}`,r=`(@(?:arg|argument|param|property)\\s+(?:`+n+`\\s+)?)`;e.languages.jsdoc=e.languages.extend(`javadoclike`,{parameter:{pattern:RegExp(r+`(?:(?!\\s)[$\\w\\xA0-\\uFFFF.])+(?=\\s|$)`),lookbehind:!0,inside:{punctuation:/\./}}}),e.languages.insertBefore(`jsdoc`,`keyword`,{"optional-parameter":{pattern:RegExp(r+`\\[(?:(?!\\s)[$\\w\\xA0-\\uFFFF.])+(?:=[^[\\]]+)?\\](?=\\s|$)`),lookbehind:!0,inside:{parameter:{pattern:/(^\[)[$\w\xA0-\uFFFF\.]+/,lookbehind:!0,inside:{punctuation:/\./}},code:{pattern:/(=)[\s\S]*(?=\]$)/,lookbehind:!0,inside:t,alias:`language-javascript`},punctuation:/[=[\]]/}},"class-name":[{pattern:RegExp(`(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\\s+(?:\\s+)?)[A-Z]\\w*(?:\\.[A-Z]\\w*)*`.replace(//g,function(){return n})),lookbehind:!0,inside:{punctuation:/\./}},{pattern:RegExp(`(@[a-z]+\\s+)`+n),lookbehind:!0,inside:{string:t.string,number:t.number,boolean:t.boolean,keyword:e.languages.typescript.keyword,operator:/=>|\.\.\.|[&|?:*]/,punctuation:/[.,;=<>{}()[\]]/}}],example:{pattern:/(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/,lookbehind:!0,inside:{code:{pattern:/^([\t ]*(?:\*\s*)?)\S.*$/m,lookbehind:!0,inside:t,alias:`language-javascript`}}}}),e.languages.javadoclike.addSupport(`javascript`,e.languages.jsdoc)}(Q),function(e){e.languages.flow=e.languages.extend(`javascript`,{}),e.languages.insertBefore(`flow`,`keyword`,{type:[{pattern:/\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|[Ss]ymbol|any|mixed|null|void)\b/,alias:`class-name`}]}),e.languages.flow[`function-variable`].pattern=/(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i,delete e.languages.flow.parameter,e.languages.insertBefore(`flow`,`operator`,{"flow-punctuation":{pattern:/\{\||\|\}/,alias:`punctuation`}}),Array.isArray(e.languages.flow.keyword)||(e.languages.flow.keyword=[e.languages.flow.keyword]),e.languages.flow.keyword.unshift({pattern:/(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,lookbehind:!0},{pattern:/(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,lookbehind:!0})}(Q),Q.languages.n4js=Q.languages.extend(`javascript`,{keyword:/\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/}),Q.languages.insertBefore(`n4js`,`constant`,{annotation:{pattern:/@+\w+/,alias:`operator`}}),Q.languages.n4jsd=Q.languages.n4js,function(e){function t(e,t){return RegExp(e.replace(//g,function(){return`(?!\\s)[_$a-zA-Z\\xA0-\\uFFFF](?:(?!\\s)[$\\w\\xA0-\\uFFFF])*`}),t)}e.languages.insertBefore(`javascript`,`function-variable`,{"method-variable":{pattern:RegExp(`(\\.\\s*)`+e.languages.javascript[`function-variable`].pattern.source),lookbehind:!0,alias:[`function-variable`,`method`,`function`,`property-access`]}}),e.languages.insertBefore(`javascript`,`function`,{method:{pattern:RegExp(`(\\.\\s*)`+e.languages.javascript.function.source),lookbehind:!0,alias:[`function`,`property-access`]}}),e.languages.insertBefore(`javascript`,`constant`,{"known-class-name":[{pattern:/\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/,alias:`class-name`},{pattern:/\b(?:[A-Z]\w*)Error\b/,alias:`class-name`}]}),e.languages.insertBefore(`javascript`,`keyword`,{imports:{pattern:t(`(\\bimport\\b\\s*)(?:(?:\\s*,\\s*(?:\\*\\s*as\\s+|\\{[^{}]*\\}))?|\\*\\s*as\\s+|\\{[^{}]*\\})(?=\\s*\\bfrom\\b)`),lookbehind:!0,inside:e.languages.javascript},exports:{pattern:t(`(\\bexport\\b\\s*)(?:\\*(?:\\s*as\\s+)?(?=\\s*\\bfrom\\b)|\\{[^{}]*\\})`),lookbehind:!0,inside:e.languages.javascript}}),e.languages.javascript.keyword.unshift({pattern:/\b(?:as|default|export|from|import)\b/,alias:`module`},{pattern:/\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/,alias:`control-flow`},{pattern:/\bnull\b/,alias:[`null`,`nil`]},{pattern:/\bundefined\b/,alias:`nil`}),e.languages.insertBefore(`javascript`,`operator`,{spread:{pattern:/\.{3}/,alias:`operator`},arrow:{pattern:/=>/,alias:`operator`}}),e.languages.insertBefore(`javascript`,`punctuation`,{"property-access":{pattern:t(`(\\.\\s*)#?`),lookbehind:!0},"maybe-class-name":{pattern:/(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/,lookbehind:!0},dom:{pattern:/\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/,alias:`variable`},console:{pattern:/\bconsole(?=\s*\.)/,alias:`class-name`}});for(var n=[`function`,`function-variable`,`method`,`method-variable`,`property-access`],r=0;r*\\.{3}(?:[^{}]|)*\\})`;function a(e,t){return e=e.replace(//g,function(){return n}).replace(//g,function(){return r}).replace(//g,function(){return i}),RegExp(e,t)}i=a(i).source,e.languages.jsx=e.languages.extend(`markup`,t),e.languages.jsx.tag.pattern=a(`<\\/?(?:[\\w.:-]+(?:+(?:[\\w.:$-]+(?:=(?:"(?:\\\\[\\s\\S]|[^\\\\"])*"|'(?:\\\\[\\s\\S]|[^\\\\'])*'|[^\\s{'"/>=]+|))?|))**\\/?)?>`),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside[`attr-value`].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside[`class-name`]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore(`inside`,`attr-name`,{spread:{pattern:a(``),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore(`inside`,`special-attr`,{script:{pattern:a(`=`),alias:`language-javascript`,inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:`punctuation`},rest:e.languages.jsx}}},e.languages.jsx.tag);function o(t){for(var n=[],r=0;r`&&n.push({tagName:s(i.content[0].content[1]),openedBraces:0}):0]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:`constant`},"other-directive":{pattern:/#\w+\b/,alias:`property`},attribute:{pattern:/@\w+/,alias:`atrule`},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:`function`},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:`important`},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:`constant`},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:`keyword`},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},Q.languages.swift[`string-literal`].forEach(function(e){e.inside.interpolation.inside=Q.languages.swift}),function(e){e.languages.kotlin=e.languages.extend(`clike`,{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete e.languages.kotlin[`class-name`];var t={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:`punctuation`},expression:{pattern:/[\s\S]+/,inside:e.languages.kotlin}};e.languages.insertBefore(`kotlin`,`string`,{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:`multiline`,inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:t},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:`singleline`,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:t},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete e.languages.kotlin.string,e.languages.insertBefore(`kotlin`,`keyword`,{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:`builtin`}}),e.languages.insertBefore(`kotlin`,`function`,{label:{pattern:/\b\w+@|@\w+\b/,alias:`symbol`}}),e.languages.kt=e.languages.kotlin,e.languages.kts=e.languages.kotlin}(Q),Q.languages.c=Q.languages.extend(`clike`,{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Q.languages.insertBefore(`c`,`string`,{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Q.languages.insertBefore(`c`,`string`,{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:`property`,inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Q.languages.c.string],char:Q.languages.c.char,comment:Q.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:`function`}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:`keyword`},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Q.languages.c}}}}),Q.languages.insertBefore(`c`,`function`,{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Q.languages.c.boolean,Q.languages.objectivec=Q.languages.extend(`c`,{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete Q.languages.objectivec[`class-name`],Q.languages.objc=Q.languages.objectivec,Q.languages.reason=Q.languages.extend(`clike`,{string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},"class-name":/\b[A-Z]\w*/,keyword:/\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|or|private|rec|sig|struct|switch|then|to|try|type|val|virtual|when|while|with)\b/,operator:/\.{3}|:[:=]|\|>|->|=(?:==?|>)?|<=?|>=?|[|^?'#!~`]|[+\-*\/]\.?|\b(?:asr|land|lor|lsl|lsr|lxor|mod)\b/}),Q.languages.insertBefore(`reason`,`class-name`,{char:{pattern:/'(?:\\x[\da-f]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^'\\\r\n])'/,greedy:!0},constructor:/\b[A-Z]\w*\b(?!\s*\.)/,label:{pattern:/\b[a-z]\w*(?=::)/,alias:`symbol`}}),delete Q.languages.reason.function,function(e){for(var t=`\\/\\*(?:[^*/]|\\*(?!\\/)|\\/(?!\\*)|)*\\*\\/`,n=0;n<2;n++)t=t.replace(//g,function(){return t});t=t.replace(//g,function(){return`[^\\s\\S]`}),e.languages.rust={comment:[{pattern:RegExp(`(^|[^\\\\])`+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:`attr-name`,inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:`punctuation`},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:`symbol`},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:`punctuation`},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:`function`},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:`class-name`},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:`namespace`},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:`namespace`,inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:`property`},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<>?=?|[@?]/},e.languages.rust[`closure-params`].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string}(Q),Q.languages.go=Q.languages.extend(`clike`,{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Q.languages.insertBefore(`go`,`string`,{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Q.languages.go[`class-name`],function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=`\\b(?!)\\w+(?:\\s*\\.\\s*\\w+)*\\b`.replace(//g,function(){return t.source});e.languages.cpp=e.languages.extend(`c`,{"class-name":[{pattern:RegExp(`(\\b(?:class|concept|enum|struct|typename)\\s+)(?!)\\w+`.replace(//g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore(`cpp`,`string`,{module:{pattern:RegExp(`(\\b(?:import|module)\\s+)(?:"(?:\\\\(?:\\r\\n|[\\s\\S])|[^"\\\\\\r\\n])*"|<[^<>\\r\\n]*>|`+`(?:\\s*:\\s*)?|:\\s*`.replace(//g,function(){return n})+`)`),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:`string`,greedy:!0}}),e.languages.insertBefore(`cpp`,`keyword`,{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:e.languages.cpp}}}}),e.languages.insertBefore(`cpp`,`operator`,{"double-colon":{pattern:/::/,alias:`punctuation`}}),e.languages.insertBefore(`cpp`,`class-name`,{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend(`cpp`,{})}}),e.languages.insertBefore(`inside`,`double-colon`,{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp[`base-clause`])}(Q),Q.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:`punctuation`},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:`string`},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:[`annotation`,`punctuation`],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Q.languages.python[`string-interpolation`].inside.interpolation.inside.rest=Q.languages.python,Q.languages.py=Q.languages.python,Q.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:`keyword`}},Q.languages.webmanifest=Q.languages.json,ru({},{dracula:()=>au,duotoneDark:()=>ou,duotoneLight:()=>su,github:()=>cu,gruvboxMaterialDark:()=>wu,gruvboxMaterialLight:()=>Tu,jettwaveDark:()=>bu,jettwaveLight:()=>xu,nightOwl:()=>lu,nightOwlLight:()=>uu,oceanicNext:()=>fu,okaidia:()=>pu,oneDark:()=>Su,oneLight:()=>Cu,palenight:()=>mu,shadesOfPurple:()=>hu,synthwave84:()=>gu,ultramin:()=>_u,vsDark:()=>vu,vsLight:()=>yu});var au={plain:{color:`#F8F8F2`,backgroundColor:`#282A36`},styles:[{types:[`prolog`,`constant`,`builtin`],style:{color:`rgb(189, 147, 249)`}},{types:[`inserted`,`function`],style:{color:`rgb(80, 250, 123)`}},{types:[`deleted`],style:{color:`rgb(255, 85, 85)`}},{types:[`changed`],style:{color:`rgb(255, 184, 108)`}},{types:[`punctuation`,`symbol`],style:{color:`rgb(248, 248, 242)`}},{types:[`string`,`char`,`tag`,`selector`],style:{color:`rgb(255, 121, 198)`}},{types:[`keyword`,`variable`],style:{color:`rgb(189, 147, 249)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(98, 114, 164)`}},{types:[`attr-name`],style:{color:`rgb(241, 250, 140)`}}]},ou={plain:{backgroundColor:`#2a2734`,color:`#9a86fd`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`,`punctuation`],style:{color:`#6c6783`}},{types:[`namespace`],style:{opacity:.7}},{types:[`tag`,`operator`,`number`],style:{color:`#e09142`}},{types:[`property`,`function`],style:{color:`#9a86fd`}},{types:[`tag-id`,`selector`,`atrule-id`],style:{color:`#eeebff`}},{types:[`attr-name`],style:{color:`#c4b9fe`}},{types:[`boolean`,`string`,`entity`,`url`,`attr-value`,`keyword`,`control`,`directive`,`unit`,`statement`,`regex`,`atrule`,`placeholder`,`variable`],style:{color:`#ffcc99`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`#c4b9fe`}}]},su={plain:{backgroundColor:`#faf8f5`,color:`#728fcb`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`,`punctuation`],style:{color:`#b6ad9a`}},{types:[`namespace`],style:{opacity:.7}},{types:[`tag`,`operator`,`number`],style:{color:`#063289`}},{types:[`property`,`function`],style:{color:`#b29762`}},{types:[`tag-id`,`selector`,`atrule-id`],style:{color:`#2d2006`}},{types:[`attr-name`],style:{color:`#896724`}},{types:[`boolean`,`string`,`entity`,`url`,`attr-value`,`keyword`,`control`,`directive`,`unit`,`statement`,`regex`,`atrule`],style:{color:`#728fcb`}},{types:[`placeholder`,`variable`],style:{color:`#93abdc`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`#896724`}}]},cu={plain:{color:`#393A34`,backgroundColor:`#f6f8fa`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`],style:{color:`#999988`,fontStyle:`italic`}},{types:[`namespace`],style:{opacity:.7}},{types:[`string`,`attr-value`],style:{color:`#e3116c`}},{types:[`punctuation`,`operator`],style:{color:`#393A34`}},{types:[`entity`,`url`,`symbol`,`number`,`boolean`,`variable`,`constant`,`property`,`regex`,`inserted`],style:{color:`#36acaa`}},{types:[`atrule`,`keyword`,`attr-name`,`selector`],style:{color:`#00a4db`}},{types:[`function`,`deleted`,`tag`],style:{color:`#d73a49`}},{types:[`function-variable`],style:{color:`#6f42c1`}},{types:[`tag`,`selector`,`keyword`],style:{color:`#00009f`}}]},lu={plain:{color:`#d6deeb`,backgroundColor:`#011627`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`,fontStyle:`italic`}},{types:[`inserted`,`attr-name`],style:{color:`rgb(173, 219, 103)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(99, 119, 119)`,fontStyle:`italic`}},{types:[`string`,`url`],style:{color:`rgb(173, 219, 103)`}},{types:[`variable`],style:{color:`rgb(214, 222, 235)`}},{types:[`number`],style:{color:`rgb(247, 140, 108)`}},{types:[`builtin`,`char`,`constant`,`function`],style:{color:`rgb(130, 170, 255)`}},{types:[`punctuation`],style:{color:`rgb(199, 146, 234)`}},{types:[`selector`,`doctype`],style:{color:`rgb(199, 146, 234)`,fontStyle:`italic`}},{types:[`class-name`],style:{color:`rgb(255, 203, 139)`}},{types:[`tag`,`operator`,`keyword`],style:{color:`rgb(127, 219, 202)`}},{types:[`boolean`],style:{color:`rgb(255, 88, 116)`}},{types:[`property`],style:{color:`rgb(128, 203, 196)`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`}}]},uu={plain:{color:`#403f53`,backgroundColor:`#FBFBFB`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`,fontStyle:`italic`}},{types:[`inserted`,`attr-name`],style:{color:`rgb(72, 118, 214)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`rgb(152, 159, 177)`,fontStyle:`italic`}},{types:[`string`,`builtin`,`char`,`constant`,`url`],style:{color:`rgb(72, 118, 214)`}},{types:[`variable`],style:{color:`rgb(201, 103, 101)`}},{types:[`number`],style:{color:`rgb(170, 9, 130)`}},{types:[`punctuation`],style:{color:`rgb(153, 76, 195)`}},{types:[`function`,`selector`,`doctype`],style:{color:`rgb(153, 76, 195)`,fontStyle:`italic`}},{types:[`class-name`],style:{color:`rgb(17, 17, 17)`}},{types:[`tag`],style:{color:`rgb(153, 76, 195)`}},{types:[`operator`,`property`,`keyword`,`namespace`],style:{color:`rgb(12, 150, 155)`}},{types:[`boolean`],style:{color:`rgb(188, 84, 84)`}}]},du={char:`#D8DEE9`,comment:`#999999`,keyword:`#c5a5c5`,primitive:`#5a9bcf`,string:`#8dc891`,variable:`#d7deea`,boolean:`#ff8b50`,punctuation:`#5FB3B3`,tag:`#fc929e`,function:`#79b6f2`,className:`#FAC863`,method:`#6699CC`,operator:`#fc929e`},fu={plain:{backgroundColor:`#282c34`,color:`#ffffff`},styles:[{types:[`attr-name`],style:{color:du.keyword}},{types:[`attr-value`],style:{color:du.string}},{types:[`comment`,`block-comment`,`prolog`,`doctype`,`cdata`,`shebang`],style:{color:du.comment}},{types:[`property`,`number`,`function-name`,`constant`,`symbol`,`deleted`],style:{color:du.primitive}},{types:[`boolean`],style:{color:du.boolean}},{types:[`tag`],style:{color:du.tag}},{types:[`string`],style:{color:du.string}},{types:[`punctuation`],style:{color:du.string}},{types:[`selector`,`char`,`builtin`,`inserted`],style:{color:du.char}},{types:[`function`],style:{color:du.function}},{types:[`operator`,`entity`,`url`,`variable`],style:{color:du.variable}},{types:[`keyword`],style:{color:du.keyword}},{types:[`atrule`,`class-name`],style:{color:du.className}},{types:[`important`],style:{fontWeight:`400`}},{types:[`bold`],style:{fontWeight:`bold`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`namespace`],style:{opacity:.7}}]},pu={plain:{color:`#f8f8f2`,backgroundColor:`#272822`},styles:[{types:[`changed`],style:{color:`rgb(162, 191, 252)`,fontStyle:`italic`}},{types:[`deleted`],style:{color:`#f92672`,fontStyle:`italic`}},{types:[`inserted`],style:{color:`rgb(173, 219, 103)`,fontStyle:`italic`}},{types:[`comment`],style:{color:`#8292a2`,fontStyle:`italic`}},{types:[`string`,`url`],style:{color:`#a6e22e`}},{types:[`variable`],style:{color:`#f8f8f2`}},{types:[`number`],style:{color:`#ae81ff`}},{types:[`builtin`,`char`,`constant`,`function`,`class-name`],style:{color:`#e6db74`}},{types:[`punctuation`],style:{color:`#f8f8f2`}},{types:[`selector`,`doctype`],style:{color:`#a6e22e`,fontStyle:`italic`}},{types:[`tag`,`operator`,`keyword`],style:{color:`#66d9ef`}},{types:[`boolean`],style:{color:`#ae81ff`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`,opacity:.7}},{types:[`tag`,`property`],style:{color:`#f92672`}},{types:[`attr-name`],style:{color:`#a6e22e !important`}},{types:[`doctype`],style:{color:`#8292a2`}},{types:[`rule`],style:{color:`#e6db74`}}]},mu={plain:{color:`#bfc7d5`,backgroundColor:`#292d3e`},styles:[{types:[`comment`],style:{color:`rgb(105, 112, 152)`,fontStyle:`italic`}},{types:[`string`,`inserted`],style:{color:`rgb(195, 232, 141)`}},{types:[`number`],style:{color:`rgb(247, 140, 108)`}},{types:[`builtin`,`char`,`constant`,`function`],style:{color:`rgb(130, 170, 255)`}},{types:[`punctuation`,`selector`],style:{color:`rgb(199, 146, 234)`}},{types:[`variable`],style:{color:`rgb(191, 199, 213)`}},{types:[`class-name`,`attr-name`],style:{color:`rgb(255, 203, 107)`}},{types:[`tag`,`deleted`],style:{color:`rgb(255, 85, 114)`}},{types:[`operator`],style:{color:`rgb(137, 221, 255)`}},{types:[`boolean`],style:{color:`rgb(255, 88, 116)`}},{types:[`keyword`],style:{fontStyle:`italic`}},{types:[`doctype`],style:{color:`rgb(199, 146, 234)`,fontStyle:`italic`}},{types:[`namespace`],style:{color:`rgb(178, 204, 214)`}},{types:[`url`],style:{color:`rgb(221, 221, 221)`}}]},hu={plain:{color:`#9EFEFF`,backgroundColor:`#2D2A55`},styles:[{types:[`changed`],style:{color:`rgb(255, 238, 128)`}},{types:[`deleted`],style:{color:`rgba(239, 83, 80, 0.56)`}},{types:[`inserted`],style:{color:`rgb(173, 219, 103)`}},{types:[`comment`],style:{color:`rgb(179, 98, 255)`,fontStyle:`italic`}},{types:[`punctuation`],style:{color:`rgb(255, 255, 255)`}},{types:[`constant`],style:{color:`rgb(255, 98, 140)`}},{types:[`string`,`url`],style:{color:`rgb(165, 255, 144)`}},{types:[`variable`],style:{color:`rgb(255, 238, 128)`}},{types:[`number`,`boolean`],style:{color:`rgb(255, 98, 140)`}},{types:[`attr-name`],style:{color:`rgb(255, 180, 84)`}},{types:[`keyword`,`operator`,`property`,`namespace`,`tag`,`selector`,`doctype`],style:{color:`rgb(255, 157, 0)`}},{types:[`builtin`,`char`,`constant`,`function`,`class-name`],style:{color:`rgb(250, 208, 0)`}}]},gu={plain:{backgroundColor:`linear-gradient(to bottom, #2a2139 75%, #34294f)`,backgroundImage:`#34294f`,color:`#f92aad`,textShadow:`0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3`},styles:[{types:[`comment`,`block-comment`,`prolog`,`doctype`,`cdata`],style:{color:`#495495`,fontStyle:`italic`}},{types:[`punctuation`],style:{color:`#ccc`}},{types:[`tag`,`attr-name`,`namespace`,`number`,`unit`,`hexcode`,`deleted`],style:{color:`#e2777a`}},{types:[`property`,`selector`],style:{color:`#72f1b8`,textShadow:`0 0 2px #100c0f, 0 0 10px #257c5575, 0 0 35px #21272475`}},{types:[`function-name`],style:{color:`#6196cc`}},{types:[`boolean`,`selector-id`,`function`],style:{color:`#fdfdfd`,textShadow:`0 0 2px #001716, 0 0 3px #03edf975, 0 0 5px #03edf975, 0 0 8px #03edf975`}},{types:[`class-name`,`maybe-class-name`,`builtin`],style:{color:`#fff5f6`,textShadow:`0 0 2px #000, 0 0 10px #fc1f2c75, 0 0 5px #fc1f2c75, 0 0 25px #fc1f2c75`}},{types:[`constant`,`symbol`],style:{color:`#f92aad`,textShadow:`0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3`}},{types:[`important`,`atrule`,`keyword`,`selector-class`],style:{color:`#f4eee4`,textShadow:`0 0 2px #393a33, 0 0 8px #f39f0575, 0 0 2px #f39f0575`}},{types:[`string`,`char`,`attr-value`,`regex`,`variable`],style:{color:`#f87c32`}},{types:[`parameter`],style:{fontStyle:`italic`}},{types:[`entity`,`url`],style:{color:`#67cdcc`}},{types:[`operator`],style:{color:`ffffffee`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`entity`],style:{cursor:`help`}},{types:[`inserted`],style:{color:`green`}}]},_u={plain:{color:`#282a2e`,backgroundColor:`#ffffff`},styles:[{types:[`comment`],style:{color:`rgb(197, 200, 198)`}},{types:[`string`,`number`,`builtin`,`variable`],style:{color:`rgb(150, 152, 150)`}},{types:[`class-name`,`function`,`tag`,`attr-name`],style:{color:`rgb(40, 42, 46)`}}]},vu={plain:{color:`#9CDCFE`,backgroundColor:`#1E1E1E`},styles:[{types:[`prolog`],style:{color:`rgb(0, 0, 128)`}},{types:[`comment`],style:{color:`rgb(106, 153, 85)`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`rgb(86, 156, 214)`}},{types:[`number`,`inserted`],style:{color:`rgb(181, 206, 168)`}},{types:[`constant`],style:{color:`rgb(100, 102, 149)`}},{types:[`attr-name`,`variable`],style:{color:`rgb(156, 220, 254)`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`rgb(206, 145, 120)`}},{types:[`selector`],style:{color:`rgb(215, 186, 125)`}},{types:[`tag`],style:{color:`rgb(78, 201, 176)`}},{types:[`tag`],languages:[`markup`],style:{color:`rgb(86, 156, 214)`}},{types:[`punctuation`,`operator`],style:{color:`rgb(212, 212, 212)`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`rgb(220, 220, 170)`}},{types:[`class-name`],style:{color:`rgb(78, 201, 176)`}},{types:[`char`],style:{color:`rgb(209, 105, 105)`}}]},yu={plain:{color:`#000000`,backgroundColor:`#ffffff`},styles:[{types:[`comment`],style:{color:`rgb(0, 128, 0)`}},{types:[`builtin`],style:{color:`rgb(0, 112, 193)`}},{types:[`number`,`variable`,`inserted`],style:{color:`rgb(9, 134, 88)`}},{types:[`operator`],style:{color:`rgb(0, 0, 0)`}},{types:[`constant`,`char`],style:{color:`rgb(129, 31, 63)`}},{types:[`tag`],style:{color:`rgb(128, 0, 0)`}},{types:[`attr-name`],style:{color:`rgb(255, 0, 0)`}},{types:[`deleted`,`string`],style:{color:`rgb(163, 21, 21)`}},{types:[`changed`,`punctuation`],style:{color:`rgb(4, 81, 165)`}},{types:[`function`,`keyword`],style:{color:`rgb(0, 0, 255)`}},{types:[`class-name`],style:{color:`rgb(38, 127, 153)`}}]},bu={plain:{color:`#f8fafc`,backgroundColor:`#011627`},styles:[{types:[`prolog`],style:{color:`#000080`}},{types:[`comment`],style:{color:`#6A9955`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`#569CD6`}},{types:[`number`,`inserted`],style:{color:`#B5CEA8`}},{types:[`constant`],style:{color:`#f8fafc`}},{types:[`attr-name`,`variable`],style:{color:`#9CDCFE`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`#cbd5e1`}},{types:[`selector`],style:{color:`#D7BA7D`}},{types:[`tag`],style:{color:`#0ea5e9`}},{types:[`tag`],languages:[`markup`],style:{color:`#0ea5e9`}},{types:[`punctuation`,`operator`],style:{color:`#D4D4D4`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`#7dd3fc`}},{types:[`class-name`],style:{color:`#0ea5e9`}},{types:[`char`],style:{color:`#D16969`}}]},xu={plain:{color:`#0f172a`,backgroundColor:`#f1f5f9`},styles:[{types:[`prolog`],style:{color:`#000080`}},{types:[`comment`],style:{color:`#6A9955`}},{types:[`builtin`,`changed`,`keyword`,`interpolation-punctuation`],style:{color:`#0c4a6e`}},{types:[`number`,`inserted`],style:{color:`#B5CEA8`}},{types:[`constant`],style:{color:`#0f172a`}},{types:[`attr-name`,`variable`],style:{color:`#0c4a6e`}},{types:[`deleted`,`string`,`attr-value`,`template-punctuation`],style:{color:`#64748b`}},{types:[`selector`],style:{color:`#D7BA7D`}},{types:[`tag`],style:{color:`#0ea5e9`}},{types:[`tag`],languages:[`markup`],style:{color:`#0ea5e9`}},{types:[`punctuation`,`operator`],style:{color:`#475569`}},{types:[`punctuation`],languages:[`markup`],style:{color:`#808080`}},{types:[`function`],style:{color:`#0e7490`}},{types:[`class-name`],style:{color:`#0ea5e9`}},{types:[`char`],style:{color:`#D16969`}}]},Su={plain:{backgroundColor:`hsl(220, 13%, 18%)`,color:`hsl(220, 14%, 71%)`,textShadow:`0 1px rgba(0, 0, 0, 0.3)`},styles:[{types:[`comment`,`prolog`,`cdata`],style:{color:`hsl(220, 10%, 40%)`}},{types:[`doctype`,`punctuation`,`entity`],style:{color:`hsl(220, 14%, 71%)`}},{types:[`attr-name`,`class-name`,`maybe-class-name`,`boolean`,`constant`,`number`,`atrule`],style:{color:`hsl(29, 54%, 61%)`}},{types:[`keyword`],style:{color:`hsl(286, 60%, 67%)`}},{types:[`property`,`tag`,`symbol`,`deleted`,`important`],style:{color:`hsl(355, 65%, 65%)`}},{types:[`selector`,`string`,`char`,`builtin`,`inserted`,`regex`,`attr-value`],style:{color:`hsl(95, 38%, 62%)`}},{types:[`variable`,`operator`,`function`],style:{color:`hsl(207, 82%, 66%)`}},{types:[`url`],style:{color:`hsl(187, 47%, 55%)`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`hsl(220, 14%, 71%)`}}]},Cu={plain:{backgroundColor:`hsl(230, 1%, 98%)`,color:`hsl(230, 8%, 24%)`},styles:[{types:[`comment`,`prolog`,`cdata`],style:{color:`hsl(230, 4%, 64%)`}},{types:[`doctype`,`punctuation`,`entity`],style:{color:`hsl(230, 8%, 24%)`}},{types:[`attr-name`,`class-name`,`boolean`,`constant`,`number`,`atrule`],style:{color:`hsl(35, 99%, 36%)`}},{types:[`keyword`],style:{color:`hsl(301, 63%, 40%)`}},{types:[`property`,`tag`,`symbol`,`deleted`,`important`],style:{color:`hsl(5, 74%, 59%)`}},{types:[`selector`,`string`,`char`,`builtin`,`inserted`,`regex`,`attr-value`,`punctuation`],style:{color:`hsl(119, 34%, 47%)`}},{types:[`variable`,`operator`,`function`],style:{color:`hsl(221, 87%, 60%)`}},{types:[`url`],style:{color:`hsl(198, 99%, 37%)`}},{types:[`deleted`],style:{textDecorationLine:`line-through`}},{types:[`inserted`],style:{textDecorationLine:`underline`}},{types:[`italic`],style:{fontStyle:`italic`}},{types:[`important`,`bold`],style:{fontWeight:`bold`}},{types:[`important`],style:{color:`hsl(230, 8%, 24%)`}}]},wu={plain:{color:`#ebdbb2`,backgroundColor:`#292828`},styles:[{types:[`imports`,`class-name`,`maybe-class-name`,`constant`,`doctype`,`builtin`,`function`],style:{color:`#d8a657`}},{types:[`property-access`],style:{color:`#7daea3`}},{types:[`tag`],style:{color:`#e78a4e`}},{types:[`attr-name`,`char`,`url`,`regex`],style:{color:`#a9b665`}},{types:[`attr-value`,`string`],style:{color:`#89b482`}},{types:[`comment`,`prolog`,`cdata`,`operator`,`inserted`],style:{color:`#a89984`}},{types:[`delimiter`,`boolean`,`keyword`,`selector`,`important`,`atrule`,`property`,`variable`,`deleted`],style:{color:`#ea6962`}},{types:[`entity`,`number`,`symbol`],style:{color:`#d3869b`}}]},Tu={plain:{color:`#654735`,backgroundColor:`#f9f5d7`},styles:[{types:[`delimiter`,`boolean`,`keyword`,`selector`,`important`,`atrule`,`property`,`variable`,`deleted`],style:{color:`#af2528`}},{types:[`imports`,`class-name`,`maybe-class-name`,`constant`,`doctype`,`builtin`],style:{color:`#b4730e`}},{types:[`string`,`attr-value`],style:{color:`#477a5b`}},{types:[`property-access`],style:{color:`#266b79`}},{types:[`function`,`attr-name`,`char`,`url`],style:{color:`#72761e`}},{types:[`tag`],style:{color:`#b94c07`}},{types:[`comment`,`prolog`,`cdata`,`operator`,`inserted`],style:{color:`#a89984`}},{types:[`entity`,`number`,`symbol`],style:{color:`#924f79`}}]},Eu=e=>(0,V.useCallback)(t=>{var n=t,{className:r,style:i,line:a}=n;let o=eu($l({},tu(n,[`className`,`style`,`line`])),{className:Vl(`token-line`,r)});return typeof e==`object`&&`plain`in e&&(o.style=e.plain),typeof i==`object`&&(o.style=$l($l({},o.style||{}),i)),o},[e]),Du=e=>{let t=(0,V.useCallback)(({types:t,empty:n})=>{if(e!=null)return t.length===1&&t[0]===`plain`?n==null?void 0:{display:`inline-block`}:t.length===1&&n!=null?e[t[0]]:Object.assign(n==null?{}:{display:`inline-block`},...t.map(t=>e[t]))},[e]);return(0,V.useCallback)(e=>{var n=e,{token:r,className:i,style:a}=n;let o=eu($l({},tu(n,[`token`,`className`,`style`])),{className:Vl(`token`,...r.types,i),children:r.content,style:t(r)});return a!=null&&(o.style=$l($l({},o.style||{}),a)),o},[t])},Ou=/\r\n|\r|\n/,ku=e=>{e.length===0?e.push({types:[`plain`],content:` +`,empty:!0}):e.length===1&&e[0].content===``&&(e[0].content=` +`,e[0].empty=!0)},Au=(e,t)=>{let n=e.length;return n>0&&e[n-1]===t?e:e.concat(t)},ju=e=>{let t=[[]],n=[e],r=[0],i=[e.length],a=0,o=0,s=[],c=[s];for(;o>-1;){for(;(a=r[o]++)0?l:[`plain`],e=u):(l=Au(l,u.type),u.alias&&(l=Au(l,u.alias)),e=u.content),typeof e!=`string`){o++,t.push(l),n.push(e),r.push(0),i.push(e.length);continue}let d=e.split(Ou),f=d.length;s.push({types:l,content:d[0]});for(let e=1;e(0,V.useMemo)(()=>{if(n==null)return ju([t]);let i={code:t,grammar:n,language:r,tokens:[]};return e.hooks.run(`before-tokenize`,i),i.tokens=e.tokenize(t,n),e.hooks.run(`after-tokenize`,i),ju(i.tokens)},[t,n,r,e]),Nu=(e,t)=>{let{plain:n}=e,r=e.styles.reduce((e,n)=>{let{languages:r,style:i}=n;return r&&!r.includes(t)||n.types.forEach(t=>{e[t]=$l($l({},e[t]),i)}),e},{});return r.root=n,r.plain=eu($l({},n),{backgroundColor:void 0}),r},Pu=({children:e,language:t,code:n,theme:r,prism:i})=>{let a=t.toLowerCase(),o=Nu(r,a),s=Eu(o),c=Du(o),l=i.languages[a];return e({tokens:Mu({prism:i,language:a,code:n,grammar:l}),className:`prism-code language-${a}`,style:o==null?{}:o.root,getLineProps:s,getTokenProps:c})},Fu=e=>(0,V.createElement)(Pu,eu($l({},e),{prism:e.prism||Q,theme:e.theme||vu,code:e.code,language:e.language})),Iu=i(e(((e,t)=>{var n=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,r={},i={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof a?new a(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,`&`).replace(/`u`)return null;if(document.currentScript&&document.currentScript.tagName===`SCRIPT`)return document.currentScript;try{throw Error()}catch(r){var e=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(r.stack)||[])[1];if(e){var t=document.getElementsByTagName(`script`);for(var n in t)if(t[n].src==e)return t[n]}return null}},isActive:function(e,t,n){for(var r=`no-`+t;e;){var i=e.classList;if(i.contains(t))return!0;if(i.contains(r))return!1;e=e.parentElement}return!!n}},languages:{plain:r,plaintext:r,text:r,txt:r,extend:function(e,t){var n=i.util.clone(i.languages[e]);for(var r in t)n[r]=t[r];return n},insertBefore:function(e,t,n,r){r||=i.languages;var a=r[e],o={};for(var s in a)if(a.hasOwnProperty(s)){if(s==t)for(var c in n)n.hasOwnProperty(c)&&(o[c]=n[c]);n.hasOwnProperty(s)||(o[s]=a[s])}var l=r[e];return r[e]=o,i.languages.DFS(i.languages,function(t,n){n===l&&t!=e&&(this[t]=o)}),o},DFS:function e(t,n,r,a){a||={};var o=i.util.objId;for(var s in t)if(t.hasOwnProperty(s)){n.call(t,s,t[s],r||s);var c=t[s],l=i.util.type(c);l===`Object`&&!a[o(c)]?(a[o(c)]=!0,e(c,n,null,a)):l===`Array`&&!a[o(c)]&&(a[o(c)]=!0,e(c,n,s,a))}}},plugins:{},highlightAll:function(e,t){i.highlightAllUnder(document,e,t)},highlightAllUnder:function(e,t,n){var r={callback:n,container:e,selector:`code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code`};i.hooks.run(`before-highlightall`,r),r.elements=Array.prototype.slice.apply(r.container.querySelectorAll(r.selector)),i.hooks.run(`before-all-elements-highlight`,r);for(var a=0,o;o=r.elements[a++];)i.highlightElement(o,t===!0,r.callback)},highlightElement:function(t,n,r){var a=i.util.getLanguage(t),o=i.languages[a];i.util.setLanguage(t,a);var s=t.parentElement;s&&s.nodeName.toLowerCase()===`pre`&&i.util.setLanguage(s,a);var c={element:t,language:a,grammar:o,code:t.textContent};function l(e){c.highlightedCode=e,i.hooks.run(`before-insert`,c),c.element.innerHTML=c.highlightedCode,i.hooks.run(`after-highlight`,c),i.hooks.run(`complete`,c),r&&r.call(c.element)}if(i.hooks.run(`before-sanity-check`,c),s=c.element.parentElement,s&&s.nodeName.toLowerCase()===`pre`&&!s.hasAttribute(`tabindex`)&&s.setAttribute(`tabindex`,`0`),!c.code){i.hooks.run(`complete`,c),r&&r.call(c.element);return}if(i.hooks.run(`before-highlight`,c),!c.grammar){l(i.util.encode(c.code));return}if(n&&e.Worker){var u=new Worker(i.filename);u.onmessage=function(e){l(e.data)},u.postMessage(JSON.stringify({language:c.language,code:c.code,immediateClose:!0}))}else l(i.highlight(c.code,c.grammar,c.language))},highlight:function(e,t,n){var r={code:e,grammar:t,language:n};if(i.hooks.run(`before-tokenize`,r),!r.grammar)throw Error(`The language "`+r.language+`" has no grammar.`);return r.tokens=i.tokenize(r.code,r.grammar),i.hooks.run(`after-tokenize`,r),a.stringify(i.util.encode(r.tokens),r.language)},tokenize:function(e,t){var n=t.rest;if(n){for(var r in n)t[r]=n[r];delete t.rest}var i=new c;return l(i,i.head,e),s(e,i,t,i.head,0),d(i)},hooks:{all:{},add:function(e,t){var n=i.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=i.hooks.all[e];if(!(!n||!n.length))for(var r=0,a;a=n[r++];)a(t)}},Token:a};e.Prism=i;function a(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.length=(r||``).length|0}a.stringify=function e(t,n){if(typeof t==`string`)return t;if(Array.isArray(t)){var r=``;return t.forEach(function(t){r+=e(t,n)}),r}var a={type:t.type,content:e(t.content,n),tag:`span`,classes:[`token`,t.type],attributes:{},language:n},o=t.alias;o&&(Array.isArray(o)?Array.prototype.push.apply(a.classes,o):a.classes.push(o)),i.hooks.run(`wrap`,a);var s=``;for(var c in a.attributes)s+=` `+c+`="`+(a.attributes[c]||``).replace(/"/g,`"`)+`"`;return`<`+a.tag+` class="`+a.classes.join(` `)+`"`+s+`>`+a.content+``};function o(e,t,n,r){e.lastIndex=t;var i=e.exec(n);if(i&&r&&i[1]){var a=i[1].length;i.index+=a,i[0]=i[0].slice(a)}return i}function s(e,t,n,r,c,d){for(var f in n)if(!(!n.hasOwnProperty(f)||!n[f])){var p=n[f];p=Array.isArray(p)?p:[p];for(var m=0;m=d.reach);C+=S.value.length,S=S.next){var w=S.value;if(t.length>e.length)return;if(!(w instanceof a)){var T=1,E;if(v){if(E=o(x,C,e,_),!E||E.index>=e.length)break;var D=E.index,O=E.index+E[0].length,k=C;for(k+=S.value.length;D>=k;)S=S.next,k+=S.value.length;if(k-=S.value.length,C=k,S.value instanceof a)continue;for(var A=S;A!==t.tail&&(kd.reach&&(d.reach=P);var F=S.prev;M&&(F=l(t,F,M),C+=M.length),u(t,F,T);var I=new a(f,g?i.tokenize(j,g):j,y,j);if(S=l(t,F,I),N&&l(t,S,N),T>1){var L={cause:f+`,`+m,reach:P};s(e,t,n,S.prev,C,L),d&&L.reach>d.reach&&(d.reach=L.reach)}}}}}}function c(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function l(e,t,n){var r=t.next,i={value:n,prev:t,next:r};return t.next=i,r.prev=i,e.length++,i}function u(e,t,n){for(var r=t.next,i=0;i/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:`attr-equals`},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:`named-entity`},/&#x?[\da-f]{1,8};/i]},n.languages.markup.tag.inside[`attr-value`].inside.entity=n.languages.markup.entity,n.languages.markup.doctype.inside[`internal-subset`].inside=n.languages.markup,n.hooks.add(`wrap`,function(e){e.type===`entity`&&(e.attributes.title=e.content.replace(/&/,`&`))}),Object.defineProperty(n.languages.markup.tag,"addInlined",{value:function(e,t){var r={};r[`language-`+t]={pattern:/(^$)/i,lookbehind:!0,inside:n.languages[t]},r.cdata=/^$/i;var i={"included-cdata":{pattern://i,inside:r}};i[`language-`+t]={pattern:/[\s\S]+/,inside:n.languages[t]};var a={};a[e]={pattern:RegExp(`(<__[^>]*>)(?:))*\\]\\]>|(?!)`.replace(/__/g,function(){return e}),`i`),lookbehind:!0,greedy:!0,inside:i},n.languages.insertBefore(`markup`,`cdata`,a)}}),Object.defineProperty(n.languages.markup.tag,"addAttribute",{value:function(e,t){n.languages.markup.tag.inside[`special-attr`].push({pattern:RegExp(`(^|["'\\s])(?:`+e+`)\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s'">=]+(?=[\\s>]))`,`i`),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,`language-`+t],inside:n.languages[t]},punctuation:[{pattern:/^=/,alias:`attr-equals`},/"|'/]}}}})}}),n.languages.html=n.languages.markup,n.languages.mathml=n.languages.markup,n.languages.svg=n.languages.markup,n.languages.xml=n.languages.extend(`markup`,{}),n.languages.ssml=n.languages.xml,n.languages.atom=n.languages.xml,n.languages.rss=n.languages.xml,(function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp(`@[\\w-](?:[^;{\\s"']|\\s+(?!\\s)|`+t.source+`)*?(?:;|(?=\\s*\\{))`),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:`selector`},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp(`\\burl\\((?:`+t.source+`|(?:[^\\\\\\r\\n()"']|\\\\[\\s\\S])*)\\)`,`i`),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp(`^`+t.source+`$`),alias:`url`}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+t.source+`)*(?=\\s*\\{)`),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined(`style`,`css`),n.tag.addAttribute(`style`,`css`))})(n),n.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},n.languages.javascript=n.languages.extend(`clike`,{"class-name":[n.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),n.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,n.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:n.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:n.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:n.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:n.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:n.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),n.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:n.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),n.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),n.languages.markup&&(n.languages.markup.tag.addInlined(`script`,`javascript`),n.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),n.languages.js=n.languages.javascript,(function(){if(n===void 0||typeof document>`u`)return;Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e=`Loading…`,t=function(e,t){return`✖ Error `+e+` while fetching file: `+t},r=`✖ Error: File does not exist or is empty`,i={js:`javascript`,py:`python`,rb:`ruby`,ps1:`powershell`,psm1:`powershell`,sh:`bash`,bat:`batch`,h:`c`,tex:`latex`},a=`data-src-status`,o=`loading`,s=`loaded`,c=`failed`,l=`pre[data-src]:not([`+a+`="`+s+`"]):not([`+a+`="`+o+`"])`;function u(e,n,i){var a=new XMLHttpRequest;a.open(`GET`,e,!0),a.onreadystatechange=function(){a.readyState==4&&(a.status<400&&a.responseText?n(a.responseText):a.status>=400?i(t(a.status,a.statusText)):i(r))},a.send(null)}function d(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||``);if(t){var n=Number(t[1]),r=t[2],i=t[3];return r?i?[n,Number(i)]:[n,void 0]:[n,n]}}n.hooks.add(`before-highlightall`,function(e){e.selector+=`, `+l}),n.hooks.add(`before-sanity-check`,function(t){var r=t.element;if(r.matches(l)){t.code=``,r.setAttribute(a,o);var f=r.appendChild(document.createElement(`CODE`));f.textContent=e;var p=r.getAttribute(`data-src`),m=t.language;if(m===`none`){var h=(/\.(\w+)$/.exec(p)||[,`none`])[1];m=i[h]||h}n.util.setLanguage(f,m),n.util.setLanguage(r,m);var g=n.plugins.autoloader;g&&g.loadLanguages(m),u(p,function(e){r.setAttribute(a,s);var t=d(r.getAttribute(`data-range`));if(t){var i=e.split(/\r\n?|\n/g),o=t[0],c=t[1]==null?i.length:t[1];o<0&&(o+=i.length),o=Math.max(0,Math.min(o-1,i.length)),c<0&&(c+=i.length),c=Math.max(0,Math.min(c,i.length)),e=i.slice(o,c).join(` +`),r.hasAttribute(`data-start`)||r.setAttribute(`data-start`,String(o+1))}f.textContent=e,n.highlightElement(f)},function(e){r.setAttribute(a,c),f.textContent=e})}}),n.plugins.fileHighlight={highlight:function(e){for(var t=(e||document).querySelectorAll(l),r=0,i;i=t[r++];)n.highlightElement(i)}};var f=!1;n.fileHighlight=function(){f||=(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),!0),n.plugins.fileHighlight.highlight.apply(this,arguments)}})()}))(),1);(function(e){function t(e,t){return e.replace(/<<(\d+)>>/g,function(e,n){return`(?:`+t[+n]+`)`})}function n(e,n,r){return RegExp(t(e,n),r||``)}function r(e,t){for(var n=0;n>/g,function(){return`(?:`+e+`)`});return e.replace(/<>/g,`[^\\s\\S]`)}var i={type:`bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void`,typeDeclaration:`class enum interface record struct`,contextual:`add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)`,other:`abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield`};function a(e){return`\\b(?:`+e.trim().replace(/ /g,`|`)+`)\\b`}var o=a(i.typeDeclaration),s=RegExp(a(i.type+` `+i.typeDeclaration+` `+i.contextual+` `+i.other)),c=a(i.typeDeclaration+` `+i.contextual+` `+i.other),l=a(i.type+` `+i.typeDeclaration+` `+i.other),u=r(`<(?:[^<>;=+\\-*/%&|^]|<>)*>`,2),d=r(`\\((?:[^()]|<>)*\\)`,2),f=`@?\\b[A-Za-z_]\\w*\\b`,p=t(`<<0>>(?:\\s*<<1>>)?`,[f,u]),m=t(`(?!<<0>>)<<1>>(?:\\s*\\.\\s*<<1>>)*`,[c,p]),h=`\\[\\s*(?:,\\s*)*\\]`,g=t(`<<0>>(?:\\s*(?:\\?\\s*)?<<1>>)*(?:\\s*\\?)?`,[m,h]),_=t(`(?:<<0>>|<<1>>)(?:\\s*(?:\\?\\s*)?<<2>>)*(?:\\s*\\?)?`,[t(`\\(<<0>>+(?:,<<0>>+)+\\)`,[t(`[^,()<>[\\];=+\\-*/%&|^]|<<0>>|<<1>>|<<2>>`,[u,d,h])]),m,h]),v={keyword:s,punctuation:/[<>()?,.:[\]]/},y=`'(?:[^\\r\\n'\\\\]|\\\\.|\\\\[Uux][\\da-fA-F]{1,8})'`,b=`"(?:\\\\.|[^\\\\"\\r\\n])*"`,x=`@"(?:""|\\\\[\\s\\S]|[^\\\\"])*"(?!")`;e.languages.csharp=e.languages.extend(`clike`,{string:[{pattern:n(`(^|[^$\\\\])<<0>>`,[x]),lookbehind:!0,greedy:!0},{pattern:n(`(^|[^@$\\\\])<<0>>`,[b]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:n(`(\\busing\\s+static\\s+)<<0>>(?=\\s*;)`,[m]),lookbehind:!0,inside:v},{pattern:n(`(\\busing\\s+<<0>>\\s*=\\s*)<<1>>(?=\\s*;)`,[f,_]),lookbehind:!0,inside:v},{pattern:n(`(\\busing\\s+)<<0>>(?=\\s*=)`,[f]),lookbehind:!0},{pattern:n(`(\\b<<0>>\\s+)<<1>>`,[o,p]),lookbehind:!0,inside:v},{pattern:n(`(\\bcatch\\s*\\(\\s*)<<0>>`,[m]),lookbehind:!0,inside:v},{pattern:n(`(\\bwhere\\s+)<<0>>`,[f]),lookbehind:!0},{pattern:n(`(\\b(?:is(?:\\s+not)?|as)\\s+)<<0>>`,[g]),lookbehind:!0,inside:v},{pattern:n(`\\b<<0>>(?=\\s+(?!<<1>>|with\\s*\\{)<<2>>(?:\\s*[=,;:{)\\]]|\\s+(?:in|when)\\b))`,[_,l,f]),inside:v}],keyword:s,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),e.languages.insertBefore(`csharp`,`number`,{range:{pattern:/\.\./,alias:`operator`}}),e.languages.insertBefore(`csharp`,`punctuation`,{"named-parameter":{pattern:n(`([(,]\\s*)<<0>>(?=\\s*:)`,[f]),lookbehind:!0,alias:`punctuation`}}),e.languages.insertBefore(`csharp`,`class-name`,{namespace:{pattern:n(`(\\b(?:namespace|using)\\s+)<<0>>(?:\\s*\\.\\s*<<0>>)*(?=\\s*[;{])`,[f]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:n(`(\\b(?:default|sizeof|typeof)\\s*\\(\\s*(?!\\s))(?:[^()\\s]|\\s(?!\\s)|<<0>>)*(?=\\s*\\))`,[d]),lookbehind:!0,alias:`class-name`,inside:v},"return-type":{pattern:n(`<<0>>(?=\\s+(?:<<1>>\\s*(?:=>|[({]|\\.\\s*this\\s*\\[)|this\\s*\\[))`,[_,m]),inside:v,alias:`class-name`},"constructor-invocation":{pattern:n(`(\\bnew\\s+)<<0>>(?=\\s*[[({])`,[_]),lookbehind:!0,inside:v,alias:`class-name`},"generic-method":{pattern:n(`<<0>>\\s*<<1>>(?=\\s*\\()`,[f,u]),inside:{function:n(`^<<0>>`,[f]),generic:{pattern:RegExp(u),alias:`class-name`,inside:v}}},"type-list":{pattern:n(`\\b((?:<<0>>\\s+<<1>>|record\\s+<<1>>\\s*<<5>>|where\\s+<<2>>)\\s*:\\s*)(?:<<3>>|<<4>>|<<1>>\\s*<<5>>|<<6>>)(?:\\s*,\\s*(?:<<3>>|<<4>>|<<6>>))*(?=\\s*(?:where|[{;]|=>|$))`,[o,p,f,_,s.source,d,`\\bnew\\s*\\(\\s*\\)`]),lookbehind:!0,inside:{"record-arguments":{pattern:n(`(^(?!new\\s*\\()<<0>>\\s*)<<1>>`,[p,d]),lookbehind:!0,greedy:!0,inside:e.languages.csharp},keyword:s,"class-name":{pattern:RegExp(_),greedy:!0,inside:v},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:`property`,inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:`keyword`}}}});var S=b+`|`+y,C=t(`\\/(?![*/])|\\/\\/[^\\r\\n]*[\\r\\n]|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/|<<0>>`,[S]),w=r(t(`[^"'/()]|<<0>>|\\(<>*\\)`,[C]),2),T=`\\b(?:assembly|event|field|method|module|param|property|return|type)\\b`,E=t(`<<0>>(?:\\s*\\(<<1>>*\\))?`,[m,w]);e.languages.insertBefore(`csharp`,`class-name`,{attribute:{pattern:n(`((?:^|[^\\s\\w>)?])\\s*\\[\\s*)(?:<<0>>\\s*:\\s*)?<<1>>(?:\\s*,\\s*<<1>>)*(?=\\s*\\])`,[T,E]),lookbehind:!0,greedy:!0,inside:{target:{pattern:n(`^<<0>>(?=\\s*:)`,[T]),alias:`keyword`},"attribute-arguments":{pattern:n(`\\(<<0>>*\\)`,[w]),inside:e.languages.csharp},"class-name":{pattern:RegExp(m),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var D=`:[^}\\r\\n]+`,O=r(t(`[^"'/()]|<<0>>|\\(<>*\\)`,[C]),2),k=t(`\\{(?!\\{)(?:(?![}:])<<0>>)*<<1>>?\\}`,[O,D]),A=r(t(`[^"'/()]|\\/(?!\\*)|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/|<<0>>|\\(<>*\\)`,[S]),2),j=t(`\\{(?!\\{)(?:(?![}:])<<0>>)*<<1>>?\\}`,[A,D]);function M(t,r){return{interpolation:{pattern:n(`((?:^|[^{])(?:\\{\\{)*)<<0>>`,[t]),lookbehind:!0,inside:{"format-string":{pattern:n(`(^\\{(?:(?![}:])<<0>>)*)<<1>>(?=\\}$)`,[r,D]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:`language-csharp`,inside:e.languages.csharp}}},string:/[\s\S]+/}}e.languages.insertBefore(`csharp`,`string`,{"interpolation-string":[{pattern:n(`(^|[^\\\\])(?:\\$@|@\\$)"(?:""|\\\\[\\s\\S]|\\{\\{|<<0>>|[^\\\\{"])*"`,[k]),lookbehind:!0,greedy:!0,inside:M(k,O)},{pattern:n(`(^|[^@\\\\])\\$"(?:\\\\.|\\{\\{|<<0>>|[^\\\\"{])*"`,[j]),lookbehind:!0,greedy:!0,inside:M(j,A)}],char:{pattern:RegExp(y),greedy:!0}}),e.languages.dotnet=e.languages.cs=e.languages.csharp})(Prism),Prism.languages.c=Prism.languages.extend(`clike`,{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore(`c`,`string`,{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore(`c`,`string`,{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:`property`,inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:`function`}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:`keyword`},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore(`c`,`function`,{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean,(function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=`\\b(?!)\\w+(?:\\s*\\.\\s*\\w+)*\\b`.replace(//g,function(){return t.source});e.languages.cpp=e.languages.extend(`c`,{"class-name":[{pattern:RegExp(`(\\b(?:class|concept|enum|struct|typename)\\s+)(?!)\\w+`.replace(//g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore(`cpp`,`string`,{module:{pattern:RegExp(`(\\b(?:import|module)\\s+)(?:"(?:\\\\(?:\\r\\n|[\\s\\S])|[^"\\\\\\r\\n])*"|<[^<>\\r\\n]*>|`+`(?:\\s*:\\s*)?|:\\s*`.replace(//g,function(){return n})+`)`),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:`string`,greedy:!0}}),e.languages.insertBefore(`cpp`,`keyword`,{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:e.languages.cpp}}}}),e.languages.insertBefore(`cpp`,`operator`,{"double-colon":{pattern:/::/,alias:`punctuation`}}),e.languages.insertBefore(`cpp`,`class-name`,{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend(`cpp`,{})}}),e.languages.insertBefore(`inside`,`double-colon`,{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp[`base-clause`])})(Prism),Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:`punctuation`},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:`string`},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:[`annotation`,`punctuation`],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python[`string-interpolation`].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python,Prism.languages.javascript=Prism.languages.extend(`clike`,{"class-name":[Prism.languages.clike[`class-name`],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(`(^|[^\\w$])(?:NaN|Infinity|0[bB][01]+(?:_[01]+)*n?|0[oO][0-7]+(?:_[0-7]+)*n?|0[xX][\\dA-Fa-f]+(?:_[\\dA-Fa-f]+)*n?|\\d+(?:_\\d+)*n|(?:\\d+(?:_\\d+)*(?:\\.(?:\\d+(?:_\\d+)*)?)?|\\.\\d+(?:_\\d+)*)(?:[Ee][+-]?\\d+(?:_\\d+)*)?)(?![\\w$])`),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Prism.languages.javascript[`class-name`][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Prism.languages.insertBefore(`javascript`,`keyword`,{regex:{pattern:RegExp(`((?:^|[^$\\w\\xA0-\\uFFFF."'\\])\\s]|\\b(?:return|yield))\\s*)\\/(?:(?:\\[(?:[^\\]\\\\\\r\\n]|\\\\.)*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}|(?:\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.|\\[(?:[^[\\]\\\\\\r\\n]|\\\\.)*\\])*\\])*\\]|\\\\.|[^/\\\\\\[\\r\\n])+\\/[dgimyus]{0,7}v[dgimyus]{0,7})(?=(?:\\s|\\/\\*(?:[^*]|\\*(?!\\/))*\\*\\/)*(?:$|[\\r\\n,.;:})\\]]|\\/\\/))`),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:`language-regex`,inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:`function`},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Prism.languages.insertBefore(`javascript`,`string`,{hashbang:{pattern:/^#!.*/,greedy:!0,alias:`comment`},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:`string`},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:`punctuation`},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:`property`}}),Prism.languages.insertBefore(`javascript`,`operator`,{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:`property`}}),Prism.languages.markup&&(Prism.languages.markup.tag.addInlined(`script`,`javascript`),Prism.languages.markup.tag.addAttribute(`on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)`,`javascript`)),Prism.languages.js=Prism.languages.javascript,(function(e){var t=e.util.clone(e.languages.javascript),n=`(?:\\s|\\/\\/.*(?!.)|\\/\\*(?:[^*]|\\*(?!\\/))\\*\\/)`,r=`(?:\\{(?:\\{(?:\\{[^{}]*\\}|[^{}])*\\}|[^{}])*\\})`,i=`(?:\\{*\\.{3}(?:[^{}]|)*\\})`;function a(e,t){return e=e.replace(//g,function(){return n}).replace(//g,function(){return r}).replace(//g,function(){return i}),RegExp(e,t)}i=a(i).source,e.languages.jsx=e.languages.extend(`markup`,t),e.languages.jsx.tag.pattern=a(`<\\/?(?:[\\w.:-]+(?:+(?:[\\w.:$-]+(?:=(?:"(?:\\\\[\\s\\S]|[^\\\\"])*"|'(?:\\\\[\\s\\S]|[^\\\\'])*'|[^\\s{'"/>=]+|))?|))**\\/?)?>`),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside[`attr-value`].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside[`class-name`]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore(`inside`,`attr-name`,{spread:{pattern:a(``),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore(`inside`,`special-attr`,{script:{pattern:a(`=`),alias:`language-javascript`,inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:`punctuation`},rest:e.languages.jsx}}},e.languages.jsx.tag);var o=function(e){return e?typeof e==`string`?e:typeof e.content==`string`?e.content:e.content.map(o).join(``):``},s=function(t){for(var n=[],r=0;r0&&n[n.length-1].tagName===o(i.content[0].content[1])&&n.pop():i.content[i.content.length-1].content===`/>`||n.push({tagName:o(i.content[0].content[1]),openedBraces:0}):n.length>0&&i.type===`punctuation`&&i.content===`{`?n[n.length-1].openedBraces++:n.length>0&&n[n.length-1].openedBraces>0&&i.type===`punctuation`&&i.content===`}`?n[n.length-1].openedBraces--:a=!0),(a||typeof i==`string`)&&n.length>0&&n[n.length-1].openedBraces===0){var c=o(i);r0&&(typeof t[r-1]==`string`||t[r-1].type===`plain-text`)&&(c=o(t[r-1])+c,t.splice(r-1,1),r--),t[r]=new e.Token(`plain-text`,c,null,c)}i.content&&typeof i.content!=`string`&&s(i.content)}};e.hooks.add(`after-tokenize`,function(e){(e.language===`jsx`||e.language===`tsx`)&&s(e.tokens)})})(Prism),(function(e){e.languages.typescript=e.languages.extend(`javascript`,{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript[`literal-property`];var t=e.languages.extend(`typescript`,{});delete t[`class-name`],e.languages.typescript[`class-name`].inside=t,e.languages.insertBefore(`typescript`,`function`,{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:`operator`},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:`class-name`,inside:t}}}}),e.languages.ts=e.languages.typescript})(Prism),(function(e){var t=e.util.clone(e.languages.typescript);e.languages.tsx=e.languages.extend(`jsx`,t),delete e.languages.tsx.parameter,delete e.languages.tsx[`literal-property`];var n=e.languages.tsx.tag;n.pattern=RegExp(`(^|[^\\w$]|(?=<\\/))(?:`+n.pattern.source+`)`,n.pattern.flags),n.lookbehind=!0})(Prism),Prism.languages.go=Prism.languages.extend(`clike`,{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore(`go`,`string`,{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go[`class-name`],(function(e){for(var t=`\\/\\*(?:[^*/]|\\*(?!\\/)|\\/(?!\\*)|)*\\*\\/`,n=0;n<2;n++)t=t.replace(//g,function(){return t});t=t.replace(//g,function(){return`[^\\s\\S]`}),e.languages.rust={comment:[{pattern:RegExp(`(^|[^\\\\])`+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:`attr-name`,inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:`punctuation`},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:`symbol`},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:`punctuation`},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:`function`},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:`class-name`},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:`namespace`},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:`namespace`,inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:`property`},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<>?=?|[@?]/},e.languages.rust[`closure-params`].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string})(Prism),(function(e){var t=`\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b`,n={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:`punctuation`,inside:null},r={bash:n,environment:{pattern:RegExp(`\\$`+t),alias:`constant`},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp(`(\\{)`+t),lookbehind:!0,alias:`constant`}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:`important`},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:`function`},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:`function`}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:`variable`,lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp(`(^|[\\s;|&]|[<>]\\()`+t),lookbehind:!0,alias:`constant`}},alias:`variable`,lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:`variable`,lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:r},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:n}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:r},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:r.entity}}],environment:{pattern:RegExp(`\\$?`+t),alias:`constant`},variable:r.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:`class-name`},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:`important`},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:`important`}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},n.inside=e.languages.bash;for(var i=[`comment`,`function-name`,`for-or-select`,`assign-left`,`parameter`,`string`,`environment`,`function`,`keyword`,`builtin`,`boolean`,`file-descriptor`,`operator`,`punctuation`,`number`],a=r.variable[1].inside,o=0;o)?|)`.replace(//g,function(){return`\\\\[\\r\\n](?:\\s|\\\\[\\r\\n]|#.*(?!.))*(?![\\s#]|\\\\[\\r\\n])`}),n=`"(?:[^"\\\\\\r\\n]|\\\\(?:\\r\\n|[\\s\\S]))*"|'(?:[^'\\\\\\r\\n]|\\\\(?:\\r\\n|[\\s\\S]))*'`,r=`--[\\w-]+=(?:|(?!["'])(?:[^\\s\\\\]|\\\\.)+)`.replace(//g,function(){return n}),i={pattern:RegExp(n),greedy:!0},a={pattern:/(^[ \t]*)#.*/m,lookbehind:!0,greedy:!0};function o(e,n){return e=e.replace(//g,function(){return r}).replace(//g,function(){return t}),RegExp(e,n)}e.languages.docker={instruction:{pattern:/(^[ \t]*)(?:ADD|ARG|CMD|COPY|ENTRYPOINT|ENV|EXPOSE|FROM|HEALTHCHECK|LABEL|MAINTAINER|ONBUILD|RUN|SHELL|STOPSIGNAL|USER|VOLUME|WORKDIR)(?=\s)(?:\\.|[^\r\n\\])*(?:\\$(?:\s|#.*$)*(?![\s#])(?:\\.|[^\r\n\\])*)*/im,lookbehind:!0,greedy:!0,inside:{options:{pattern:o(`(^(?:ONBUILD)?\\w+)(?:)*`,`i`),lookbehind:!0,greedy:!0,inside:{property:{pattern:/(^|\s)--[\w-]+/,lookbehind:!0},string:[i,{pattern:/(=)(?!["'])(?:[^\s\\]|\\.)+/,lookbehind:!0}],operator:/\\$/m,punctuation:/=/}},keyword:[{pattern:o(`(^(?:ONBUILD)?HEALTHCHECK(?:)*)(?:CMD|NONE)\\b`,`i`),lookbehind:!0,greedy:!0},{pattern:o(`(^(?:ONBUILD)?FROM(?:)*(?!--)[^ \\t\\\\]+)AS`,`i`),lookbehind:!0,greedy:!0},{pattern:o(`(^ONBUILD)\\w+`,`i`),lookbehind:!0,greedy:!0},{pattern:/^\w+/,greedy:!0}],comment:a,string:i,variable:/\$(?:\w+|\{[^{}"'\\]*\})/,operator:/\\$/m}},comment:a},e.languages.dockerfile=e.languages.docker})(Prism),Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},Prism.languages.plsql=Prism.languages.extend(`sql`,{comment:{pattern:/\/\*[\s\S]*?\*\/|--.*/,greedy:!0},keyword:/\b(?:A|ACCESSIBLE|ADD|AGENT|AGGREGATE|ALL|ALTER|AND|ANY|ARRAY|AS|ASC|AT|ATTRIBUTE|AUTHID|AVG|BEGIN|BETWEEN|BFILE_BASE|BINARY|BLOB_BASE|BLOCK|BODY|BOTH|BOUND|BULK|BY|BYTE|C|CALL|CALLING|CASCADE|CASE|CHAR|CHARACTER|CHARSET|CHARSETFORM|CHARSETID|CHAR_BASE|CHECK|CLOB_BASE|CLONE|CLOSE|CLUSTER|CLUSTERS|COLAUTH|COLLECT|COLUMNS|COMMENT|COMMIT|COMMITTED|COMPILED|COMPRESS|CONNECT|CONSTANT|CONSTRUCTOR|CONTEXT|CONTINUE|CONVERT|COUNT|CRASH|CREATE|CREDENTIAL|CURRENT|CURSOR|CUSTOMDATUM|DANGLING|DATA|DATE|DATE_BASE|DAY|DECLARE|DEFAULT|DEFINE|DELETE|DESC|DETERMINISTIC|DIRECTORY|DISTINCT|DOUBLE|DROP|DURATION|ELEMENT|ELSE|ELSIF|EMPTY|END|ESCAPE|EXCEPT|EXCEPTION|EXCEPTIONS|EXCLUSIVE|EXECUTE|EXISTS|EXIT|EXTERNAL|FETCH|FINAL|FIRST|FIXED|FLOAT|FOR|FORALL|FORCE|FROM|FUNCTION|GENERAL|GOTO|GRANT|GROUP|HASH|HAVING|HEAP|HIDDEN|HOUR|IDENTIFIED|IF|IMMEDIATE|IMMUTABLE|IN|INCLUDING|INDEX|INDEXES|INDICATOR|INDICES|INFINITE|INSERT|INSTANTIABLE|INT|INTERFACE|INTERSECT|INTERVAL|INTO|INVALIDATE|IS|ISOLATION|JAVA|LANGUAGE|LARGE|LEADING|LENGTH|LEVEL|LIBRARY|LIKE|LIKE2|LIKE4|LIKEC|LIMIT|LIMITED|LOCAL|LOCK|LONG|LOOP|MAP|MAX|MAXLEN|MEMBER|MERGE|MIN|MINUS|MINUTE|MOD|MODE|MODIFY|MONTH|MULTISET|MUTABLE|NAME|NAN|NATIONAL|NATIVE|NCHAR|NEW|NOCOMPRESS|NOCOPY|NOT|NOWAIT|NULL|NUMBER_BASE|OBJECT|OCICOLL|OCIDATE|OCIDATETIME|OCIDURATION|OCIINTERVAL|OCILOBLOCATOR|OCINUMBER|OCIRAW|OCIREF|OCIREFCURSOR|OCIROWID|OCISTRING|OCITYPE|OF|OLD|ON|ONLY|OPAQUE|OPEN|OPERATOR|OPTION|OR|ORACLE|ORADATA|ORDER|ORGANIZATION|ORLANY|ORLVARY|OTHERS|OUT|OVERLAPS|OVERRIDING|PACKAGE|PARALLEL_ENABLE|PARAMETER|PARAMETERS|PARENT|PARTITION|PASCAL|PERSISTABLE|PIPE|PIPELINED|PLUGGABLE|POLYMORPHIC|PRAGMA|PRECISION|PRIOR|PRIVATE|PROCEDURE|PUBLIC|RAISE|RANGE|RAW|READ|RECORD|REF|REFERENCE|RELIES_ON|REM|REMAINDER|RENAME|RESOURCE|RESULT|RESULT_CACHE|RETURN|RETURNING|REVERSE|REVOKE|ROLLBACK|ROW|SAMPLE|SAVE|SAVEPOINT|SB1|SB2|SB4|SECOND|SEGMENT|SELECT|SELF|SEPARATE|SEQUENCE|SERIALIZABLE|SET|SHARE|SHORT|SIZE|SIZE_T|SOME|SPARSE|SQL|SQLCODE|SQLDATA|SQLNAME|SQLSTATE|STANDARD|START|STATIC|STDDEV|STORED|STRING|STRUCT|STYLE|SUBMULTISET|SUBPARTITION|SUBSTITUTABLE|SUBTYPE|SUM|SYNONYM|TABAUTH|TABLE|TDO|THE|THEN|TIME|TIMESTAMP|TIMEZONE_ABBR|TIMEZONE_HOUR|TIMEZONE_MINUTE|TIMEZONE_REGION|TO|TRAILING|TRANSACTION|TRANSACTIONAL|TRUSTED|TYPE|UB1|UB2|UB4|UNDER|UNION|UNIQUE|UNPLUG|UNSIGNED|UNTRUSTED|UPDATE|USE|USING|VALIST|VALUE|VALUES|VARIABLE|VARIANCE|VARRAY|VARYING|VIEW|VIEWS|VOID|WHEN|WHERE|WHILE|WITH|WORK|WRAPPED|WRITE|YEAR|ZONE)\b/i,operator:/:=?|=>|[<>^~!]=|\.\.|\|\||\*\*|[-+*/%<>=@]/}),Prism.languages.insertBefore(`plsql`,`operator`,{label:{pattern:/<<\s*\w+\s*>>/,alias:`symbol`}}),Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:`keyword`}},Prism.languages.webmanifest=Prism.languages.json,(function(e){var t=/[*&][^\s[\]{},]+/,n=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,r=`(?:`+n.source+`(?:[ ]+`+t.source+`)?|`+t.source+`(?:[ ]+`+n.source+`)?)`,i=`(?:[^\\s\\x00-\\x08\\x0e-\\x1f!"#%&'*,\\-:>?@[\\]\`{|}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]|[?:-])(?:[ \\t]*(?:(?![#:])|:))*`.replace(//g,function(){return`[^\\s\\x00-\\x08\\x0e-\\x1f,[\\]{}\\x7f-\\x84\\x86-\\x9f\\ud800-\\udfff\\ufffe\\uffff]`}),a=`"(?:[^"\\\\\\r\\n]|\\\\.)*"|'(?:[^'\\\\\\r\\n]|\\\\.)*'`;function o(e,t){t=(t||``).replace(/m/g,``)+`m`;var n=`([:\\-,[{]\\s*(?:\\s<>[ \\t]+)?)(?:<>)(?=[ \\t]*(?:$|,|\\]|\\}|(?:[\\r\\n]\\s*)?#))`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return e});return RegExp(n,t)}e.languages.yaml={scalar:{pattern:RegExp(`([\\-:]\\s*(?:\\s<>[ \\t]+)?[|>])[ \\t]*(?:((?:\\r?\\n|\\r)[ \\t]+)\\S[^\\r\\n]*(?:\\2[^\\r\\n]+)*)`.replace(/<>/g,function(){return r})),lookbehind:!0,alias:`string`},comment:/#.*/,key:{pattern:RegExp(`((?:^|[:\\-,[{\\r\\n?])[ \\t]*(?:<>[ \\t]+)?)<>(?=\\s*:\\s)`.replace(/<>/g,function(){return r}).replace(/<>/g,function(){return`(?:`+i+`|`+a+`)`})),lookbehind:!0,greedy:!0,alias:`atrule`},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:`important`},datetime:{pattern:o(`\\d{4}-\\d\\d?-\\d\\d?(?:[tT]|[ \\t]+)\\d\\d?:\\d{2}:\\d{2}(?:\\.\\d*)?(?:[ \\t]*(?:Z|[-+]\\d\\d?(?::\\d{2})?))?|\\d{4}-\\d{2}-\\d{2}|\\d\\d?:\\d{2}(?::\\d{2}(?:\\.\\d*)?)?`),lookbehind:!0,alias:`number`},boolean:{pattern:o(`false|true`,`i`),lookbehind:!0,alias:`important`},null:{pattern:o(`null|~`,`i`),lookbehind:!0,alias:`important`},string:{pattern:o(a),lookbehind:!0,greedy:!0},number:{pattern:o(`[+-]?(?:0x[\\da-f]+|0o[0-7]+|(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:e[+-]?\\d+)?|\\.inf|\\.nan)`,`i`),lookbehind:!0},tag:n,important:t,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml})(Prism),Prism.languages.cobol={comment:{pattern:/\*>.*|(^[ \t]*)\*.*/m,lookbehind:!0,greedy:!0},string:{pattern:/[xzgn]?(?:"(?:[^\r\n"]|"")*"(?!")|'(?:[^\r\n']|'')*'(?!'))/i,greedy:!0},level:{pattern:/(^[ \t]*)\d+\b/m,lookbehind:!0,greedy:!0,alias:`number`},"class-name":{pattern:/(\bpic(?:ture)?\s+)(?:(?:[-\w$/,:*+<>]|\.(?!\s|$))(?:\(\d+\))?)+/i,lookbehind:!0,inside:{number:{pattern:/(\()\d+/,lookbehind:!0},punctuation:/[()]/}},keyword:{pattern:/(^|[^\w-])(?:ABORT|ACCEPT|ACCESS|ADD|ADDRESS|ADVANCING|AFTER|ALIGNED|ALL|ALPHABET|ALPHABETIC|ALPHABETIC-LOWER|ALPHABETIC-UPPER|ALPHANUMERIC|ALPHANUMERIC-EDITED|ALSO|ALTER|ALTERNATE|ANY|ARE|AREA|AREAS|AS|ASCENDING|ASCII|ASSIGN|ASSOCIATED-DATA|ASSOCIATED-DATA-LENGTH|AT|ATTRIBUTE|AUTHOR|AUTO|AUTO-SKIP|BACKGROUND-COLOR|BACKGROUND-COLOUR|BASIS|BEEP|BEFORE|BEGINNING|BELL|BINARY|BIT|BLANK|BLINK|BLOCK|BOTTOM|BOUNDS|BY|BYFUNCTION|BYTITLE|CALL|CANCEL|CAPABLE|CCSVERSION|CD|CF|CH|CHAINING|CHANGED|CHANNEL|CHARACTER|CHARACTERS|CLASS|CLASS-ID|CLOCK-UNITS|CLOSE|CLOSE-DISPOSITION|COBOL|CODE|CODE-SET|COL|COLLATING|COLUMN|COM-REG|COMMA|COMMITMENT|COMMON|COMMUNICATION|COMP|COMP-1|COMP-2|COMP-3|COMP-4|COMP-5|COMPUTATIONAL|COMPUTATIONAL-1|COMPUTATIONAL-2|COMPUTATIONAL-3|COMPUTATIONAL-4|COMPUTATIONAL-5|COMPUTE|CONFIGURATION|CONTAINS|CONTENT|CONTINUE|CONTROL|CONTROL-POINT|CONTROLS|CONVENTION|CONVERTING|COPY|CORR|CORRESPONDING|COUNT|CRUNCH|CURRENCY|CURSOR|DATA|DATA-BASE|DATE|DATE-COMPILED|DATE-WRITTEN|DAY|DAY-OF-WEEK|DBCS|DE|DEBUG-CONTENTS|DEBUG-ITEM|DEBUG-LINE|DEBUG-NAME|DEBUG-SUB-1|DEBUG-SUB-2|DEBUG-SUB-3|DEBUGGING|DECIMAL-POINT|DECLARATIVES|DEFAULT|DEFAULT-DISPLAY|DEFINITION|DELETE|DELIMITED|DELIMITER|DEPENDING|DESCENDING|DESTINATION|DETAIL|DFHRESP|DFHVALUE|DISABLE|DISK|DISPLAY|DISPLAY-1|DIVIDE|DIVISION|DONTCARE|DOUBLE|DOWN|DUPLICATES|DYNAMIC|EBCDIC|EGCS|EGI|ELSE|EMI|EMPTY-CHECK|ENABLE|END|END-ACCEPT|END-ADD|END-CALL|END-COMPUTE|END-DELETE|END-DIVIDE|END-EVALUATE|END-IF|END-MULTIPLY|END-OF-PAGE|END-PERFORM|END-READ|END-RECEIVE|END-RETURN|END-REWRITE|END-SEARCH|END-START|END-STRING|END-SUBTRACT|END-UNSTRING|END-WRITE|ENDING|ENTER|ENTRY|ENTRY-PROCEDURE|ENVIRONMENT|EOL|EOP|EOS|ERASE|ERROR|ESCAPE|ESI|EVALUATE|EVENT|EVERY|EXCEPTION|EXCLUSIVE|EXHIBIT|EXIT|EXPORT|EXTEND|EXTENDED|EXTERNAL|FD|FILE|FILE-CONTROL|FILLER|FINAL|FIRST|FOOTING|FOR|FOREGROUND-COLOR|FOREGROUND-COLOUR|FROM|FULL|FUNCTION|FUNCTION-POINTER|FUNCTIONNAME|GENERATE|GIVING|GLOBAL|GO|GOBACK|GRID|GROUP|HEADING|HIGH-VALUE|HIGH-VALUES|HIGHLIGHT|I-O|I-O-CONTROL|ID|IDENTIFICATION|IF|IMPLICIT|IMPORT|IN|INDEX|INDEXED|INDICATE|INITIAL|INITIALIZE|INITIATE|INPUT|INPUT-OUTPUT|INSPECT|INSTALLATION|INTEGER|INTO|INVALID|INVOKE|IS|JUST|JUSTIFIED|KANJI|KEPT|KEY|KEYBOARD|LABEL|LANGUAGE|LAST|LB|LD|LEADING|LEFT|LEFTLINE|LENGTH|LENGTH-CHECK|LIBACCESS|LIBPARAMETER|LIBRARY|LIMIT|LIMITS|LINAGE|LINAGE-COUNTER|LINE|LINE-COUNTER|LINES|LINKAGE|LIST|LOCAL|LOCAL-STORAGE|LOCK|LONG-DATE|LONG-TIME|LOW-VALUE|LOW-VALUES|LOWER|LOWLIGHT|MEMORY|MERGE|MESSAGE|MMDDYYYY|MODE|MODULES|MORE-LABELS|MOVE|MULTIPLE|MULTIPLY|NAMED|NATIONAL|NATIONAL-EDITED|NATIVE|NEGATIVE|NETWORK|NEXT|NO|NO-ECHO|NULL|NULLS|NUMBER|NUMERIC|NUMERIC-DATE|NUMERIC-EDITED|NUMERIC-TIME|OBJECT-COMPUTER|OCCURS|ODT|OF|OFF|OMITTED|ON|OPEN|OPTIONAL|ORDER|ORDERLY|ORGANIZATION|OTHER|OUTPUT|OVERFLOW|OVERLINE|OWN|PACKED-DECIMAL|PADDING|PAGE|PAGE-COUNTER|PASSWORD|PERFORM|PF|PH|PIC|PICTURE|PLUS|POINTER|PORT|POSITION|POSITIVE|PRINTER|PRINTING|PRIVATE|PROCEDURE|PROCEDURE-POINTER|PROCEDURES|PROCEED|PROCESS|PROGRAM|PROGRAM-ID|PROGRAM-LIBRARY|PROMPT|PURGE|QUEUE|QUOTE|QUOTES|RANDOM|RD|READ|READER|REAL|RECEIVE|RECEIVED|RECORD|RECORDING|RECORDS|RECURSIVE|REDEFINES|REEL|REF|REFERENCE|REFERENCES|RELATIVE|RELEASE|REMAINDER|REMARKS|REMOTE|REMOVAL|REMOVE|RENAMES|REPLACE|REPLACING|REPORT|REPORTING|REPORTS|REQUIRED|RERUN|RESERVE|RESET|RETURN|RETURN-CODE|RETURNING|REVERSE-VIDEO|REVERSED|REWIND|REWRITE|RF|RH|RIGHT|ROUNDED|RUN|SAME|SAVE|SCREEN|SD|SEARCH|SECTION|SECURE|SECURITY|SEGMENT|SEGMENT-LIMIT|SELECT|SEND|SENTENCE|SEPARATE|SEQUENCE|SEQUENTIAL|SET|SHARED|SHAREDBYALL|SHAREDBYRUNUNIT|SHARING|SHIFT-IN|SHIFT-OUT|SHORT-DATE|SIGN|SIZE|SORT|SORT-CONTROL|SORT-CORE-SIZE|SORT-FILE-SIZE|SORT-MERGE|SORT-MESSAGE|SORT-MODE-SIZE|SORT-RETURN|SOURCE|SOURCE-COMPUTER|SPACE|SPACES|SPECIAL-NAMES|STANDARD|STANDARD-1|STANDARD-2|START|STATUS|STOP|STRING|SUB-QUEUE-1|SUB-QUEUE-2|SUB-QUEUE-3|SUBTRACT|SUM|SUPPRESS|SYMBOL|SYMBOLIC|SYNC|SYNCHRONIZED|TABLE|TALLY|TALLYING|TAPE|TASK|TERMINAL|TERMINATE|TEST|TEXT|THEN|THREAD|THREAD-LOCAL|THROUGH|THRU|TIME|TIMER|TIMES|TITLE|TO|TODAYS-DATE|TODAYS-NAME|TOP|TRAILING|TRUNCATED|TYPE|TYPEDEF|UNDERLINE|UNIT|UNSTRING|UNTIL|UP|UPON|USAGE|USE|USING|VALUE|VALUES|VARYING|VIRTUAL|WAIT|WHEN|WHEN-COMPILED|WITH|WORDS|WORKING-STORAGE|WRITE|YEAR|YYYYDDD|YYYYMMDD|ZERO-FILL|ZEROES|ZEROS)(?![\w-])/i,lookbehind:!0},boolean:{pattern:/(^|[^\w-])(?:false|true)(?![\w-])/i,lookbehind:!0},number:{pattern:/(^|[^\w-])(?:[+-]?(?:(?:\d+(?:[.,]\d+)?|[.,]\d+)(?:e[+-]?\d+)?|zero))(?![\w-])/i,lookbehind:!0},operator:[/<>|[<>]=?|[=+*/&]/,{pattern:/(^|[^\w-])(?:-|and|equal|greater|less|not|or|than)(?![\w-])/i,lookbehind:!0}],punctuation:/[.:,()]/};var Lu={plain:{color:`#d4d4d4`,backgroundColor:`#1e1e1e`},styles:[{types:[`comment`,`prolog`,`doctype`,`cdata`],style:{color:`#6a9955`,fontStyle:`italic`}},{types:[`level`],style:{color:`#38bdf8`,fontWeight:`bold`}},{types:[`keyword`,`builtin-keyword`],style:{color:`#569cd6`}},{types:[`class-name`,`return-type`,`type-list`,`namespace`,`base-clause`,`builtin`],style:{color:`#4ec9b0`}},{types:[`interface`],style:{color:`#b8d7a3`}},{types:[`function`,`generic-function`,`function-variable`,`generic-method`],style:{color:`#dcdcaa`}},{types:[`decorator`,`attribute`],style:{color:`#dcdcaa`}},{types:[`string`,`char`,`attr-value`,`triple-quoted-string`,`raw-string`,`template-string`,`interpolation-string`,`string-interpolation`],style:{color:`#ce9178`}},{types:[`number`,`boolean`],style:{color:`#b5cea8`}},{types:[`variable`,`parameter`,`named-parameter`,`property`,`string-property`,`attr-name`,`identifier`],style:{color:`#9cdcfe`}},{types:[`constant`,`symbol`],style:{color:`#4fc1ff`}},{types:[`macro`,`directive`,`preprocessor`,`preprocessor-directive`],style:{color:`#c586c0`}},{types:[`directive-hash`],style:{color:`#9b9b9b`}},{types:[`tag`],style:{color:`#569cd6`}},{types:[`regex`],style:{color:`#d16969`}},{types:[`punctuation`,`operator`,`double-colon`],style:{color:`#d4d4d4`}}]};function Ru(e){let t={cs:`csharp`,csharp:`csharp`,py:`python`,pyw:`python`,python:`python`,ts:`typescript`,tsx:`tsx`,js:`javascript`,jsx:`jsx`,mjs:`javascript`,cjs:`javascript`,c:`c`,h:`cpp`,cpp:`cpp`,cc:`cpp`,cxx:`cpp`,hpp:`cpp`,hh:`cpp`,hxx:`cpp`,go:`go`,rs:`rust`,rust:`rust`,json:`json`,yml:`yaml`,yaml:`yaml`,md:`markdown`,markdown:`markdown`,css:`css`,scss:`css`,html:`markup`,xml:`markup`,svg:`markup`,sql:`sql`,psql:`sql`,pls:`plsql`,plsql:`plsql`,pkb:`plsql`,pks:`plsql`,ddl:`sql`,dml:`sql`,cql:`sql`,hql:`sql`,sh:`bash`,bash:`bash`,zsh:`bash`,dockerfile:`docker`,cbl:`cobol`,cob:`cobol`,cpy:`cobol`,cobol:`cobol`,pco:`cobol`}[(e.split(`?`)[0].split(`#`)[0].split(`.`).pop()||``).toLowerCase()]||`plain`;return Iu.default.languages[t]?t:`plain`}var zu=({filepath:e,content:t,totalLines:n,sizeBytes:r,targetStartLine:i,targetEndLine:a,impact:o,loading:s=!1,error:c=null,onRefresh:l,onSelectCaller:u,onSelectCallee:d,density:f=`balanced`})=>{let[p,m]=(0,V.useState)(!1),[h,g]=(0,V.useState)(!1),[_,v]=(0,V.useState)(!1),y=(0,V.useRef)(null),b=(0,V.useMemo)(()=>t?t.split(` +`):[],[t]);(0,V.useEffect)(()=>{i&&y.current&&y.current.scrollIntoView({behavior:`smooth`,block:`center`})},[i,e]);let x=async()=>{if(t)try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(t),m(!0),setTimeout(()=>m(!1),2e3))}catch{}},S=async()=>{if(!e)return;let t=`${e}${i?`#L${i}${a&&a!==i?`-L${a}`:``}`:``}`;try{navigator?.clipboard?.writeText&&(await navigator.clipboard.writeText(t),g(!0),setTimeout(()=>g(!1),2e3))}catch{}},C=e=>e==null?``:e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(1)} MB`,w=o?.callers||[],T=o?.callees||[],E=w.length+T.length;return(0,H.jsxs)(`div`,{className:`nav-code-viewer-container density-${f}`,"data-testid":`navigator-code-viewer`,children:[(0,H.jsxs)(`div`,{className:`nav-code-viewer-header`,children:[(0,H.jsxs)(`div`,{className:`nav-code-viewer-meta`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,className:`nav-code-file-icon`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`})]}),(0,H.jsx)(`span`,{className:`nav-code-filename`,title:e,children:e}),(0,H.jsxs)(`span`,{className:`nav-code-stat-chip`,children:[n||b.length,` lines`]}),r!==void 0&&r>0&&(0,H.jsx)(`span`,{className:`nav-code-stat-chip`,children:C(r)})]}),(0,H.jsxs)(`div`,{className:`nav-code-viewer-actions`,children:[o?.symbol&&(0,H.jsxs)(`button`,{type:`button`,className:`nav-code-impact-toggle-btn nav-code-drawer-toggle ${_?`active`:``}`,onClick:()=>v(e=>!e),"aria-label":`Callers & Impact`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`path`,{d:`M12 16v-4M12 8h.01`})]}),(0,H.jsxs)(`span`,{children:[`Callers & Impact (`,E,`)`]})]}),(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:S,title:`Copy path and line permalink`,"aria-label":`Copy Permalink`,children:h?`Link Copied!`:`Copy Link`}),(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:x,title:`Copy entire file contents`,"aria-label":`Copy File Code`,children:p?`Copied!`:`Copy Code`}),l&&(0,H.jsx)(`button`,{type:`button`,className:`nav-code-action-btn`,onClick:l,title:`Refresh file`,"aria-label":`Refresh File`,children:`↻`})]})]}),c&&(0,H.jsx)(`div`,{className:`nav-code-error-banner`,role:`alert`,children:(0,H.jsxs)(`span`,{children:[`Failed to load file: `,c]})}),s&&(0,H.jsxs)(`div`,{className:`nav-code-loading-overlay`,children:[(0,H.jsx)(`div`,{className:`nav-omni-spinner`}),(0,H.jsx)(`span`,{children:`Loading source code...`})]}),(0,H.jsx)(`div`,{className:`nav-code-body`,tabIndex:0,children:b.length===0&&!s&&!c?(0,H.jsx)(`div`,{className:`nav-code-empty-state`,style:{padding:`24px`,color:`#64748b`,textAlign:`center`},children:`File is empty.`}):(0,H.jsx)(Fu,{prism:Iu.default,theme:Lu,code:t||``,language:Ru(e),children:({tokens:e,getTokenProps:t})=>(0,H.jsx)(`div`,{className:`nav-code-lines-wrapper`,children:e.map((e,n)=>{let r=n+1,o=i!==void 0&&r>=i&&r<=(a||i),s=i!==void 0&&r===i;return(0,H.jsxs)(`div`,{ref:s?y:void 0,className:`nav-code-line-row ${o?`nav-code-line-target`:``} ${s?`nav-code-line-primary`:``}`,"data-testid":`code-line-${r}`,children:[(0,H.jsx)(`div`,{className:`nav-code-line-number select-none`,children:r}),(0,H.jsx)(`div`,{className:`nav-code-line-content font-mono`,children:e.length===0||e.length===1&&e[0].content===``?` `:e.map((e,n)=>(0,H.jsx)(`span`,{...t({token:e})},n))})]},r)})})})}),_&&o?.symbol&&(0,H.jsxs)(`div`,{className:`nav-code-impact-drawer`,"data-testid":`code-impact-drawer`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-drawer-header`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-drawer-title`,children:[(0,H.jsx)(`span`,{className:`outline-kind-badge ${ut(o.symbol.kind)}`,children:o.symbol.kind}),(0,H.jsx)(`strong`,{className:`nav-impact-symbol-name`,children:o.symbol.name}),(0,H.jsxs)(`span`,{className:`nav-impact-symbol-lines`,children:[`Lines `,o.symbol.start_line,`–`,o.symbol.end_line]}),o.route&&(0,H.jsxs)(`span`,{className:`outline-method-badge ${lt(o.route.http_method)}`,children:[o.route.http_method,` `,o.route.path_pattern]})]}),(0,H.jsx)(`button`,{type:`button`,className:`nav-impact-close-btn`,onClick:()=>v(!1),"aria-label":`Close Impact Drawer`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-impact-drawer-body`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column-title`,children:[`Incoming Callers (`,w.length,`)`]}),w.length===0?(0,H.jsx)(`div`,{className:`nav-impact-empty`,children:`No incoming callers detected`}):(0,H.jsx)(`div`,{className:`nav-impact-chips-list`,children:w.map((t,n)=>(0,H.jsxs)(`button`,{type:`button`,className:`nav-impact-chip caller`,onClick:()=>u&&u(t.source_filepath||e,t.source_symbol,t.source_symbol_id||void 0),children:[(0,H.jsx)(`span`,{className:`chip-name`,children:t.source_symbol||`anonymous`}),(0,H.jsx)(`span`,{className:`chip-path`,children:t.source_filepath}),t.line_number&&(0,H.jsxs)(`span`,{className:`chip-line`,children:[`:`,t.line_number]})]},t.id||n))})]}),(0,H.jsxs)(`div`,{className:`nav-impact-column`,children:[(0,H.jsxs)(`div`,{className:`nav-impact-column-title`,children:[`Outgoing Callees (`,T.length,`)`]}),T.length===0?(0,H.jsx)(`div`,{className:`nav-impact-empty`,children:`No outgoing callees detected`}):(0,H.jsx)(`div`,{className:`nav-impact-chips-list`,children:T.map((e,t)=>(0,H.jsxs)(`button`,{type:`button`,className:`nav-impact-chip callee`,onClick:()=>d&&d(e.target_filepath,e.target_symbol),children:[(0,H.jsx)(`span`,{className:`chip-name`,children:e.target_symbol}),e.target_filepath&&(0,H.jsx)(`span`,{className:`chip-path`,children:e.target_filepath}),e.line_number&&(0,H.jsxs)(`span`,{className:`chip-line`,children:[`:`,e.line_number]})]},e.id||t))})]})]})]})]})},Bu=({impact:e,fileContent:t,loadingContent:n=!1,contentError:r=null,targetStartLine:i,targetEndLine:a,activeInspectorTab:o,onChangeInspectorTab:s,onSelectCaller:c,onSelectCallee:l,density:u=`balanced`,loading:d=!1,onRefreshContent:f})=>{let[p,m]=(0,V.useState)(e?.symbol||d?`intelligence`:t?`reader`:`intelligence`),[h,g]=(0,V.useState)(!1),_=o===void 0?p:o,v=s||m,y=e?.symbol,b=e?.route,x=e?.callers||[],S=e?.callees||[],C=e?.imports||[],w=!!(t||n||r),T=_===`reader`;return(0,H.jsxs)(`div`,{className:`nav-inspector-pane density-${u}`,"data-testid":`navigator-inspector-container`,children:[(0,H.jsxs)(`div`,{className:`nav-inspector-header`,children:[(0,H.jsxs)(`div`,{className:`nav-inspector-title`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`})]}),(0,H.jsx)(`span`,{children:`Inspector`})]}),(0,H.jsxs)(`div`,{className:`nav-inspector-header-actions`,children:[(w||y)&&(0,H.jsxs)(`div`,{className:`nav-inspector-tabs`,role:`tablist`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`inspector-tab-btn ${_===`reader`?`active`:``}`,onClick:()=>v(`reader`),role:`tab`,"aria-selected":_===`reader`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`})]}),`File`]}),(0,H.jsxs)(`button`,{type:`button`,className:`inspector-tab-btn ${_===`intelligence`?`active`:``}`,onClick:()=>v(`intelligence`),title:`View symbol callers, callees & impact`,role:`tab`,"aria-selected":_===`intelligence`,children:[(0,H.jsxs)(`svg`,{width:`12`,height:`12`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`12`,y1:`16`,x2:`12`,y2:`12`}),(0,H.jsx)(`line`,{x1:`12`,y1:`8`,x2:`12.01`,y2:`8`})]}),`Intelligence`]})]}),y&&_===`intelligence`&&(0,H.jsx)(`button`,{type:`button`,className:`nav-copy-permalink-btn`,onClick:async()=>{if(!e?.symbol)return;let{filepath:t,start_line:n,end_line:r}=e.symbol,i=`${window.location.origin}${window.location.pathname}?repo=${encodeURIComponent(e.symbol.repo||``)}&file=${t}#L${n}-L${r}`;try{navigator?.clipboard?.writeText&&await navigator.clipboard.writeText(i),g(!0),setTimeout(()=>g(!1),2e3)}catch{}},title:`Copy file path & line range permalink`,"aria-label":`Copy Permalink`,children:h?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`polyline`,{points:`20 6 9 17 4 12`})}),(0,H.jsx)(`span`,{children:`Copied!`})]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`}),(0,H.jsx)(`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`})]}),(0,H.jsx)(`span`,{children:`Copy Permalink`})]})})]})]}),(0,H.jsx)(`div`,{className:`nav-inspector-content`,children:T&&t?t.filepath.toLowerCase().endsWith(`.md`)||t.filepath.toLowerCase().endsWith(`.markdown`)?(0,H.jsx)(zl,{filepath:t.filepath,content:t.content,totalLines:t.total_lines,sizeBytes:t.size_bytes,loading:n,error:r,onRefresh:f}):(0,H.jsx)(zu,{filepath:t.filepath,content:t.content,totalLines:t.total_lines,sizeBytes:t.size_bytes,targetStartLine:i||y?.start_line,targetEndLine:a||y?.end_line,impact:e,loading:n,error:r,onRefresh:f,onSelectCaller:c,onSelectCallee:l,density:u}):T&&n?(0,H.jsxs)(`div`,{className:`nav-inspector-skeleton`,"data-testid":`inspector-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-metrics shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):T?(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{fontSize:`2rem`,opacity:.3}})}),(0,H.jsx)(`h4`,{children:`No File or Symbol Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to read its documentation or select a symbol to inspect callers and dependencies.`})]}):d?(0,H.jsxs)(`div`,{className:`nav-inspector-skeleton`,"data-testid":`inspector-loading-skeleton`,children:[(0,H.jsx)(`div`,{className:`skeleton-header shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-metrics shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`}),(0,H.jsx)(`div`,{className:`skeleton-block shimmer`})]}):y?(0,H.jsxs)(`div`,{className:`nav-inspector-body`,children:[(0,H.jsxs)(`div`,{className:`inspector-card symbol-summary-card`,children:[(0,H.jsxs)(`div`,{className:`summary-title-row`,children:[(0,H.jsx)(`span`,{className:`symbol-kind-badge ${ut(y.kind)}`,children:y.kind}),(0,H.jsx)(`h3`,{className:`summary-name`,title:y.full_symbol||y.name,children:y.name})]}),(0,H.jsxs)(`div`,{className:`summary-location-row`,children:[(0,H.jsxs)(`span`,{className:`summary-file-path`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z`}),(0,H.jsx)(`polyline`,{points:`13 2 13 9 20 9`})]}),y.filepath]}),(0,H.jsxs)(`span`,{className:`summary-line-range`,children:[`L`,y.start_line,` - L`,y.end_line]})]})]}),(0,H.jsxs)(`div`,{className:`inspector-metrics-grid`,children:[(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Incoming Callers`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-callers`,children:x.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Outgoing Callees`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-callees`,children:S.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Total Imports`}),(0,H.jsx)(`span`,{className:`metric-value`,"data-testid":`metric-imports`,children:C.length})]}),(0,H.jsxs)(`div`,{className:`metric-box`,children:[(0,H.jsx)(`span`,{className:`metric-label`,children:`Language`}),(0,H.jsx)(`span`,{className:`metric-value metric-lang`,"data-testid":`metric-scope`,children:y.language||`code`})]})]}),b&&(0,H.jsxs)(`div`,{className:`inspector-card route-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`2`,y1:`12`,x2:`22`,y2:`12`}),(0,H.jsx)(`path`,{d:`M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z`})]}),(0,H.jsx)(`span`,{children:`API Route Mapping`})]}),(0,H.jsxs)(`div`,{className:`route-detail-row`,children:[(0,H.jsx)(`span`,{className:`route-method-badge ${lt(b.http_method)}`,children:b.http_method}),(0,H.jsx)(`span`,{className:`route-path-code`,children:b.path_pattern}),b.framework&&(0,H.jsx)(`span`,{className:`route-framework-tag`,children:b.framework})]})]}),y.signature&&(0,H.jsxs)(`div`,{className:`inspector-card code-preview-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`polyline`,{points:`16 18 22 12 16 6`}),(0,H.jsx)(`polyline`,{points:`8 6 2 12 8 18`})]}),(0,H.jsx)(`span`,{children:`Signature`})]}),(0,H.jsx)(`pre`,{className:`signature-code-block`,children:(0,H.jsx)(`code`,{children:y.signature})})]}),y.docstring&&(0,H.jsxs)(`div`,{className:`inspector-card docstring-card`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`path`,{d:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z`}),(0,H.jsx)(`polyline`,{points:`14 2 14 8 20 8`}),(0,H.jsx)(`line`,{x1:`16`,y1:`13`,x2:`8`,y2:`13`}),(0,H.jsx)(`line`,{x1:`16`,y1:`17`,x2:`8`,y2:`17`}),(0,H.jsx)(`polyline`,{points:`10 9 9 9 8 9`})]}),(0,H.jsx)(`span`,{children:`Documentation`})]}),(0,H.jsx)(`p`,{className:`docstring-text`,children:y.docstring})]}),(0,H.jsxs)(`div`,{className:`inspector-card relations-card callers-section`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M12 19V5M5 12l7-7 7 7`})}),(0,H.jsxs)(`span`,{children:[`Incoming Callers (`,x.length,`)`]})]}),x.length===0?(0,H.jsx)(`div`,{className:`nav-no-items-text`,children:`No incoming callers found in this repository.`}):(0,H.jsx)(`div`,{className:`relation-list`,children:x.map((e,t)=>(0,H.jsxs)(`div`,{"data-testid":`caller-item-${e.id??t}`,className:`relation-item caller-item`,onClick:()=>{e.source_filepath&&c&&c(e.source_filepath,e.source_symbol,e.source_symbol_id??void 0)},role:`button`,tabIndex:0,title:`Jump to ${e.source_symbol||`caller`} in ${e.source_filepath||``}`,children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.source_symbol||`Unknown Caller`}),(0,H.jsx)(`span`,{className:`rel-jump-hint`,"aria-hidden":`true`,children:`Jump ↗`})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.source_filepath&&(0,H.jsx)(`span`,{className:`rel-filepath`,children:e.source_filepath}),e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.call_count&&e.call_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.call_count,` calls`]}):null,e.relationship_type&&(0,H.jsx)(`span`,{className:`rel-type-tag`,children:e.relationship_type})]})]},e.id??t))})]}),(0,H.jsxs)(`div`,{className:`inspector-card relations-card dependencies-section`,children:[(0,H.jsxs)(`div`,{className:`card-section-title`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M12 5v14M5 12l7 7 7-7`})}),(0,H.jsxs)(`span`,{children:[`Outgoing Dependencies (`,S.length+C.length,`)`]})]}),S.length===0&&C.length===0?(0,H.jsx)(`div`,{className:`nav-no-items-text`,children:`No outgoing calls or imports.`}):(0,H.jsxs)(`div`,{className:`relation-list`,children:[S.map((e,t)=>(0,H.jsxs)(`div`,{"data-testid":`callee-item-${e.id??t}`,className:`relation-item callee-item ${e.target_filepath?`is-clickable`:``}`,onClick:()=>{e.target_filepath&&l&&l(e.target_filepath,e.target_symbol)},role:e.target_filepath?`button`:void 0,tabIndex:e.target_filepath?0:void 0,title:e.target_filepath?`Jump to ${e.target_symbol} in ${e.target_filepath}`:void 0,onKeyDown:t=>{e.target_filepath&&l&&(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),l(e.target_filepath,e.target_symbol))},children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.target_symbol}),(0,H.jsxs)(`div`,{className:`rel-top-right`,children:[(0,H.jsx)(`span`,{className:`rel-type-badge`,children:e.relationship_type||`CALLS`}),e.target_filepath&&(0,H.jsx)(`span`,{className:`rel-jump-hint`,"aria-hidden":`true`,children:`Jump ↗`})]})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.target_filepath&&(0,H.jsx)(`span`,{className:`rel-filepath`,children:e.target_filepath}),e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.call_count&&e.call_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.call_count,` calls`]}):null]})]},e.id??`callee-${t}`)),C.map((e,t)=>(0,H.jsxs)(`div`,{className:`relation-item import-item`,children:[(0,H.jsxs)(`div`,{className:`relation-top`,children:[(0,H.jsx)(`span`,{className:`rel-symbol-name`,children:e.target_symbol}),(0,H.jsx)(`span`,{className:`rel-type-badge import-badge`,children:`IMPORTS`})]}),(0,H.jsxs)(`div`,{className:`relation-bottom`,children:[e.all_lines?(0,H.jsxs)(`span`,{className:`rel-line`,title:`Lines: ${e.all_lines}`,children:[`L`,e.all_lines.includes(`,`)?e.all_lines.split(`,`).slice(0,3).join(`, L`)+(e.all_lines.split(`,`).length>3?`...`:``):e.all_lines]}):e.line_number?(0,H.jsxs)(`span`,{className:`rel-line`,children:[`L`,e.line_number]}):null,e.import_count&&e.import_count>1?(0,H.jsxs)(`span`,{className:`rel-count-badge`,children:[e.import_count,` imports`]}):null]})]},e.id??`import-${t}`))]})]})]}):(0,H.jsxs)(`div`,{className:`nav-empty-state`,children:[(0,H.jsx)(`div`,{className:`empty-icon`,children:(0,H.jsx)(`i`,{className:`fa-solid fa-circle-nodes`,style:{fontSize:`2rem`,opacity:.3}})}),(0,H.jsx)(`h4`,{children:`No File or Symbol Selected`}),(0,H.jsx)(`p`,{children:`Select a file from the tree to read its documentation or select a symbol to inspect callers and dependencies.`})]})})]})},Vu=`contextcortex_navigator_density`,Hu=({initialRepo:e=`__all__`,initialPath:t,initialSymbolId:n,initialStartLine:r,initialEndLine:i,onNavigationConsumed:a})=>{let[o,s]=(0,V.useState)(()=>{let e=localStorage.getItem(Vu);return e===`compact`||e===`balanced`||e===`spacious`?e:`balanced`}),c=e=>{s(e),localStorage.setItem(Vu,e)},[l,u]=(0,V.useState)([]),[d,f]=(0,V.useState)(e),[p,m]=(0,V.useState)(null),[h,g]=(0,V.useState)(!1),[_,v]=(0,V.useState)(``),[y,b]=(0,V.useState)(t||null),[x,S]=(0,V.useState)(null),[C,w]=(0,V.useState)(!1),[T,E]=(0,V.useState)(n||null),[D,O]=(0,V.useState)(null),[k,A]=(0,V.useState)(!1),[j,M]=(0,V.useState)(null),[N,P]=(0,V.useState)(!1),[F,I]=(0,V.useState)(null),[L,R]=(0,V.useState)(`reader`),[z,B]=(0,V.useState)(void 0),[ee,te]=(0,V.useState)(void 0),[ne,re]=(0,V.useState)(!0),[ie,ae]=(0,V.useState)(`files`),[oe,se]=(0,V.useState)([]),[ce,le]=(0,V.useState)(-1),[ue,de]=(0,V.useState)(null);(0,V.useEffect)(()=>{let e=e=>{(e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`b`&&(e.preventDefault(),re(e=>!e))};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[]),(0,V.useEffect)(()=>{(async()=>{try{let e=await fetch(`/admin/api/repos`);if(e.ok){let t=await e.json();u(Array.isArray(t)?t:[])}}catch(e){console.error(`Error fetching repositories:`,e)}})()},[]);let fe=(0,V.useCallback)(async e=>{g(!0),de(null);try{let t=await fetch(`/admin/api/navigator/tree?repo=${encodeURIComponent(e)}`);if(!t.ok)throw Error(`Failed to load tree: ${t.status} ${t.statusText}`);let n=await t.json();m(n)}catch(e){console.error(`Error fetching codebase tree:`,e),de(e.message||`Failed to load codebase tree`)}finally{g(!1)}},[]);(0,V.useEffect)(()=>{fe(d)},[d,fe]);let pe=(0,V.useCallback)(async(e,t)=>{A(!0);try{let n=await fetch(`/admin/api/navigator/symbol-impact?repo=${encodeURIComponent(e)}&symbol_id=${t}`);if(!n.ok)throw Error(`Failed to load symbol impact: ${n.status}`);let r=await n.json();O(r)}catch(e){console.error(`Error fetching symbol impact:`,e),O(null)}finally{A(!1)}},[]),me=(0,V.useCallback)(async(e,t)=>{P(!0),I(null);try{let n=await fetch(`/admin/api/files/read?path=${encodeURIComponent(t)}&repo=${encodeURIComponent(e)}`);if(!n.ok)throw Error(`Failed to read file: ${n.statusText}`);let r=await n.json();M(r)}catch(e){console.error(`Error fetching file content:`,e),I(e.message||`Failed to read file content`),M(null)}finally{P(!1)}},[]),he=(0,V.useCallback)(async(e,t,n,r)=>{w(!0);try{let i=await fetch(`/admin/api/navigator/file-outline?repo=${encodeURIComponent(e)}&filepath=${encodeURIComponent(t)}`);if(!i.ok)throw Error(`Failed to load file outline: ${i.status}`);let a=await i.json();if(S(a),a.symbols&&a.symbols.length>0){let t;typeof n==`number`?t=a.symbols.find(e=>e.id===n):typeof n==`string`&&(t=a.symbols.find(e=>e.name===n||e.full_symbol===n)),t||=a.symbols[0],t&&(E(t.id),(r===`intelligence`||n!==void 0)&&(B(t.start_line),te(t.end_line)),await pe(e,t.id))}else E(null),O(null);R(r||`reader`)}catch(e){console.error(`Error fetching outline:`,e),S(null),E(null),O(null),R(`reader`)}finally{w(!1)}},[pe]),ge=(0,V.useRef)(null);(0,V.useEffect)(()=>{if(!t&&!n&&(!e||e===`__all__`))return;let o=`${e||``}:${t||``}:${n||``}:${r||``}:${i||``}`;if(ge.current===o)return;ge.current=o;let s=e&&e!==`__all__`?e:d;e&&e!==`__all__`&&e!==d&&f(e),t&&(b(t),me(s,t),he(s,t),r!==void 0&&B(r),i!==void 0&&te(i),R(`reader`)),n&&(E(n),pe(s,n),R(`intelligence`)),a?.()},[e,t,n,r,i,me,he,pe,a]);let _e=(0,V.useCallback)(e=>{se(t=>[...t.slice(0,ce+1),e]),le(e=>e+1)},[ce]),ve=()=>{if(ce>0){let e=oe[ce-1];le(ce-1),f(e.repo),b(e.path),E(e.symbolId??null),B(e.startLine),te(e.endLine),he(e.repo,e.path,e.symbolId??void 0),me(e.repo,e.path),e.symbolId&&pe(e.repo,e.symbolId)}},ye=()=>{if(ce{f(e),b(null),S(null),E(null),O(null),M(null),B(void 0),te(void 0)},xe=e=>{let t=e.repo&&e.repo!==`__all__`?e.repo:d;e.repo&&e.repo!==d&&d!==`__all__`&&f(e.repo),b(e.filepath),B(e.start_line),te(e.end_line),_e({repo:t,path:e.filepath,symbolId:e.symbol_id,startLine:e.start_line,endLine:e.end_line}),me(t,e.filepath),e.type===`symbol`&&e.symbol_id?(E(e.symbol_id),he(t,e.filepath,e.symbol_id,`reader`),pe(t,e.symbol_id)):he(t,e.filepath,void 0,`reader`),R(`reader`)},Se=e=>{if(e.is_dir)return;let t=e.abs_path||e.path;b(t),B(void 0),te(void 0),_e({repo:d,path:t}),he(d,t,void 0,`reader`),me(d,t),R(`reader`),ae(`outline`)},Ce=e=>{if(R(e),e===`intelligence`){if(!T&&x?.symbols&&x.symbols.length>0){let e=x.symbols[0];E(e.id),B(e.start_line),te(e.end_line),d&&pe(d,e.id)}else T&&!D&&d&&pe(d,T)}},we=e=>{E(e.id),B(e.start_line),te(e.end_line),R(`intelligence`),pe(d,e.id),y&&_e({repo:d,path:y,symbolId:e.id,startLine:e.start_line,endLine:e.end_line})},Te=(e,t,n)=>{b(e),B(void 0),te(void 0),_e({repo:d,path:e,symbolId:n});let r=n?`intelligence`:`reader`;he(d,e,n??t,r),me(d,e),R(r),ae(`outline`),n&&(E(n),pe(d,n))},Ee=(e,t)=>{e&&(b(e),B(void 0),te(void 0),_e({repo:d,path:e}),he(d,e,t,`reader`),me(d,e),R(`reader`))},De=x?.symbols?.find(e=>e.id===T)?.name||null;return(0,H.jsxs)(`div`,{className:`code-navigator-container density-${o}`,"data-testid":`code-navigator-container`,children:[(0,H.jsx)(Nt,{repos:l,selectedRepo:d,onSelectRepo:be,density:o,onChangeDensity:c,searchQuery:_,onSearchChange:v,onSelectSearchResult:xe,totalFiles:p?.total_files??0,totalSymbols:p?.total_symbols??0,onRefresh:()=>fe(d),loading:h}),(0,H.jsx)(Pt,{repo:d,path:y,symbol:De,onNavigatePath:e=>{b(e),/\.[a-zA-Z0-9]+$/.test(e)?(me(d,e),he(d,e)):ae(`files`)},canGoBack:ce>0,canGoForward:cere(!ne),isSidebarOpen:ne}),ue&&(0,H.jsxs)(`div`,{className:`nav-error-banner`,role:`alert`,children:[(0,H.jsxs)(`svg`,{width:`15`,height:`15`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,H.jsx)(`line`,{x1:`12`,y1:`8`,x2:`12`,y2:`12`}),(0,H.jsx)(`line`,{x1:`12`,y1:`16`,x2:`12.01`,y2:`16`})]}),(0,H.jsx)(`span`,{children:ue}),(0,H.jsx)(`button`,{type:`button`,onClick:()=>de(null),className:`error-close-btn`,"aria-label":`Dismiss error`,children:`✕`})]}),(0,H.jsxs)(`div`,{className:`nav-hero-layout`,"data-testid":`nav-hero-layout`,children:[(0,H.jsxs)(`aside`,{className:`nav-sidebar-column ${ne?``:`collapsed`}`,"aria-label":`Codebase Navigator Sidebar`,children:[(0,H.jsxs)(`div`,{className:`nav-sidebar-tabs`,role:`tablist`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`nav-sidebar-tab-btn ${ie===`files`?`active`:``}`,onClick:()=>ae(`files`),role:`tab`,"aria-selected":ie===`files`,children:[(0,H.jsx)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`})}),(0,H.jsx)(`span`,{children:`Files`})]}),(0,H.jsxs)(`button`,{type:`button`,className:`nav-sidebar-tab-btn ${ie===`outline`?`active`:``}`,onClick:()=>ae(`outline`),role:`tab`,"aria-selected":ie===`outline`,children:[(0,H.jsxs)(`svg`,{width:`13`,height:`13`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,children:[(0,H.jsx)(`line`,{x1:`8`,y1:`6`,x2:`21`,y2:`6`}),(0,H.jsx)(`line`,{x1:`8`,y1:`12`,x2:`21`,y2:`12`}),(0,H.jsx)(`line`,{x1:`8`,y1:`18`,x2:`21`,y2:`18`}),(0,H.jsx)(`line`,{x1:`3`,y1:`6`,x2:`3.01`,y2:`6`}),(0,H.jsx)(`line`,{x1:`3`,y1:`12`,x2:`3.01`,y2:`12`}),(0,H.jsx)(`line`,{x1:`3`,y1:`18`,x2:`3.01`,y2:`18`})]}),(0,H.jsx)(`span`,{children:`Symbols`})]})]}),(0,H.jsxs)(`div`,{style:{flex:1,minHeight:0,display:`flex`,flexDirection:`column`,position:`relative`},children:[(0,H.jsx)(`div`,{style:{flex:1,minHeight:0,display:ie===`files`?`flex`:`none`,flexDirection:`column`,height:`100%`},children:(0,H.jsx)(It,{nodes:p?.tree??[],selectedPath:y,onSelectFile:Se,filterText:_,onFilterChange:v,density:o,loading:h,repo:d,autoExpandRoot:!0})}),(0,H.jsx)(`div`,{style:{flex:1,minHeight:0,display:ie===`outline`?`flex`:`none`,flexDirection:`column`,height:`100%`},children:(0,H.jsx)(dt,{outline:x,selectedSymbolId:T,onSelectSymbol:we,onReadDoc:()=>{R(`reader`)},density:o,loading:C})})]})]}),(0,H.jsx)(`main`,{className:`nav-hero-viewer`,"aria-label":`Code and Document Hero Viewport`,children:(0,H.jsx)(Bu,{impact:D,fileContent:j,loadingContent:N,contentError:F,targetStartLine:z,targetEndLine:ee,activeInspectorTab:L,onChangeInspectorTab:Ce,onSelectCaller:Te,onSelectCallee:Ee,density:o,loading:k,onRefreshContent:()=>y&&me(d,y)})})]})]})};function Uu(){let e=Je(),[t,n]=(0,V.useState)(null),[r,i]=(0,V.useState)(!1),[a,o]=(0,V.useState)(`all`),[s,c]=(0,V.useState)(`summary`),[l,u]=(0,V.useState)(``),[d,f]=(0,V.useState)(``),[p,m]=(0,V.useState)(``),[h,g]=(0,V.useState)(``),_=(0,V.useCallback)(async(t=a,r=s,o=l,c=d,u=p)=>{i(!0);try{let e=new URLSearchParams;e.set(`source_type`,t),e.set(`detail_level`,r),o.trim()&&e.set(`repo_name`,o.trim()),c.trim()&&e.set(`path_prefix`,c.trim()),u.trim()&&e.set(`file_extension`,u.trim());let i=await fetch(`/admin/api/ingestion/catalog?${e.toString()}`);if(!i.ok){let e=await i.json().catch(()=>({}));throw Error(e.error||`Failed to load ingestion catalog`)}let a=await i.json();n(a)}catch(t){e.error(`Error loading catalog: `+t.message),console.error(`Error loading ingestion catalog:`,t)}finally{i(!1)}},[a,s,l,d,p,e]);(0,V.useEffect)(()=>{_(a,s,l,d,p)},[a,s]);let v=e=>{e&&e.preventDefault(),_(a,s,l,d,p)},y=()=>{u(``),f(``),m(``),g(``),_(a,s,``,``,``)},b=e=>{o(e)},x=e=>{c(e)},S=e=>{if(!e)return`-`;if(typeof e==`string`)try{return new Date(e).toLocaleString()}catch{return e}let t=e<1e11?e*1e3:e;return new Date(t).toLocaleString()},C=t?.git_repositories||[],w=t?.monitored_paths||[],T=t?.local_storage,E=(t?.files||[]).filter(e=>{if(!h.trim())return!0;let t=h.toLowerCase();return e.filepath.toLowerCase().includes(t)||e.repo.toLowerCase().includes(t)||e.language&&e.language.toLowerCase().includes(t)}),D=C.reduce((e,t)=>e+(t.file_count||0),0),O=w.reduce((e,t)=>e+(t.file_count||0),0),k=T?.file_count||0,A=D+O+k;return(0,H.jsx)(`div`,{className:`tab-content active`,children:(0,H.jsxs)(`div`,{className:`glass-card`,children:[(0,H.jsxs)(`div`,{className:`card-header-btn`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsxs)(`h2`,{children:[(0,H.jsx)(`i`,{className:`fa-solid fa-book-bookmark`}),` Unified Ingestion Catalog`]}),(0,H.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Inspect all indexed Git repositories, monitored local workspaces, and uploaded local storage documents.`})]}),(0,H.jsx)(`div`,{style:{display:`flex`,gap:`10px`},children:(0,H.jsxs)(`button`,{className:`btn btn-secondary`,onClick:()=>v(),disabled:r,title:`Refresh catalog`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-arrows-rotate ${r?`fa-spin`:``}`}),` Refresh`]})})]}),(0,H.jsxs)(`div`,{className:`stats-grid`,children:[(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`6`,y1:`3`,x2:`6`,y2:`15`}),(0,H.jsx)(`circle`,{cx:`18`,cy:`6`,r:`3`}),(0,H.jsx)(`circle`,{cx:`6`,cy:`18`,r:`3`}),(0,H.jsx)(`path`,{d:`M18 9a9 9 0 0 1-9 9`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Git Repositories`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[C.length,` `,(0,H.jsxs)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:[`(`,D,` files)`]})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(251, 191, 36, 0.12)`,color:`#fbbf24`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`path`,{d:`M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z`}),(0,H.jsx)(`line`,{x1:`12`,y1:`11`,x2:`12`,y2:`17`}),(0,H.jsx)(`line`,{x1:`9`,y1:`14`,x2:`15`,y2:`14`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Monitored Paths`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[w.length,` `,(0,H.jsxs)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:[`(`,O,` files)`]})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(56, 189, 248, 0.12)`,color:`#38bdf8`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`22`,y1:`12`,x2:`2`,y2:`12`}),(0,H.jsx)(`path`,{d:`M5.45 5.11L2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`}),(0,H.jsx)(`line`,{x1:`6`,y1:`16`,x2:`6.01`,y2:`16`}),(0,H.jsx)(`line`,{x1:`10`,y1:`16`,x2:`10.01`,y2:`16`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Local Storage`}),(0,H.jsxs)(`span`,{className:`stat-value`,children:[k,` `,(0,H.jsx)(`small`,{style:{fontSize:`0.75rem`,fontWeight:`normal`,color:`var(--text-muted)`},children:`files`})]})]})]}),(0,H.jsxs)(`div`,{className:`stat-card`,"data-testid":`catalog-stat-card`,children:[(0,H.jsx)(`div`,{className:`stat-icon`,"aria-hidden":`true`,style:{background:`rgba(168, 85, 247, 0.12)`,color:`#a855f7`},children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`}),(0,H.jsx)(`path`,{d:`M21 12c0 1.66-4 3-9 3s-9-1.34-9-3`}),(0,H.jsx)(`path`,{d:`M3 5v14c0 1.66 4 3 9 3s9-1.34 9-3V5`})]})}),(0,H.jsxs)(`div`,{className:`stat-info`,children:[(0,H.jsx)(`span`,{className:`stat-label`,children:`Total Cataloged Files`}),(0,H.jsx)(`span`,{className:`stat-value`,children:A})]})]})]}),(0,H.jsxs)(`div`,{className:`catalog-filter-bar`,children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,flexWrap:`wrap`,gap:`12px`,marginBottom:`14px`},children:[(0,H.jsxs)(`div`,{className:`log-filter-pills`,role:`group`,"aria-label":`Source Type Filters`,children:[(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`all`?`active`:``}`,onClick:()=>b(`all`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group`}),` All Sources`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`git`?`active`:``}`,onClick:()=>b(`git`),children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`}),` Git Repositories`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`monitored_path`?`active`:``}`,onClick:()=>b(`monitored_path`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Monitored Paths`]}),(0,H.jsxs)(`button`,{className:`log-filter-btn ${a===`local_storage`?`active`:``}`,onClick:()=>b(`local_storage`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`}),` Local Storage`]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},role:`group`,"aria-label":`Detail Level Switch`,children:[(0,H.jsxs)(`button`,{className:`btn ${s===`summary`?`btn-primary`:`btn-secondary`}`,style:{padding:`5px 12px`,fontSize:`0.8rem`},onClick:()=>x(`summary`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-list`}),` Summary`]}),(0,H.jsxs)(`button`,{className:`btn ${s===`detailed`?`btn-primary`:`btn-secondary`}`,style:{padding:`5px 12px`,fontSize:`0.8rem`},onClick:()=>x(`detailed`),children:[(0,H.jsx)(`i`,{className:`fa-solid fa-network-wired`}),` Detailed File Tree`]})]})]}),(0,H.jsxs)(`form`,{onSubmit:v,children:[(0,H.jsxs)(`div`,{className:`catalog-filter-inputs`,children:[(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-repo-filter`,style:{fontSize:`0.8rem`},children:`Repository / Alias`}),(0,H.jsx)(`input`,{id:`catalog-repo-filter`,type:`text`,placeholder:`Filter by repo name...`,value:l,onChange:e=>u(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-prefix-filter`,style:{fontSize:`0.8rem`},children:`Path Prefix`}),(0,H.jsx)(`input`,{id:`catalog-prefix-filter`,type:`text`,placeholder:`e.g. app/api or docs/`,value:d,onChange:e=>f(e.target.value)})]}),(0,H.jsxs)(`div`,{className:`form-group`,style:{margin:0},children:[(0,H.jsx)(`label`,{htmlFor:`catalog-ext-filter`,style:{fontSize:`0.8rem`},children:`File Extension`}),(0,H.jsx)(`input`,{id:`catalog-ext-filter`,type:`text`,placeholder:`e.g. .md, .py, .ts`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`flex-end`,gap:`8px`,marginTop:`12px`},children:[(0,H.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,style:{padding:`6px 12px`,fontSize:`0.85rem`},onClick:y,children:`Clear`}),(0,H.jsxs)(`button`,{type:`submit`,className:`btn btn-primary`,style:{padding:`6px 14px`,fontSize:`0.85rem`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-filter`}),` Apply`]})]})]})]}),(a===`all`||a===`git`)&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`,style:{color:`var(--primary)`}}),` Git Repositories`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:C.length})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Name`}),(0,H.jsx)(`th`,{children:`Branch / Commit`}),(0,H.jsx)(`th`,{children:`Status`}),(0,H.jsx)(`th`,{children:`Files`}),(0,H.jsx)(`th`,{children:`Provider`}),(0,H.jsx)(`th`,{children:`URL`})]})}),(0,H.jsx)(`tbody`,{children:C.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:6,className:`empty-state`,children:`No Git repositories match criteria.`})}):C.map(e=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.name})}),(0,H.jsxs)(`td`,{children:[(0,H.jsx)(`code`,{children:e.branch}),e.commit_sha&&(0,H.jsxs)(`span`,{className:`text-muted`,style:{marginLeft:`6px`,fontSize:`0.8rem`},children:[`@`,e.commit_sha.substring(0,7)]})]}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge ${e.status===`synced`?`badge-success`:e.status===`syncing`?`badge-warning`:`badge-danger`}`,children:e.status})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.file_count??0})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.provider||`git`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.82rem`,wordBreak:`break-all`},children:e.url})})]},e.id))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:C.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No Git repositories match criteria.`}):C.map(e=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.name}),(0,H.jsx)(`span`,{className:`badge ${e.status===`synced`?`badge-success`:`badge-warning`}`,children:e.status})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Branch: `}),(0,H.jsx)(`code`,{children:e.branch})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Files: `}),(0,H.jsx)(`strong`,{children:e.file_count??0})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`URL: `}),(0,H.jsx)(`span`,{style:{wordBreak:`break-all`},children:e.url})]})]})]},`gm-${e.id}`))})]}),(a===`all`||a===`monitored_path`)&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`,style:{color:`#fbbf24`}}),` Monitored Local Paths`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:w.length})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Path`}),(0,H.jsx)(`th`,{children:`Repo Alias`}),(0,H.jsx)(`th`,{children:`Category`}),(0,H.jsx)(`th`,{children:`Files Indexed`})]})}),(0,H.jsx)(`tbody`,{children:w.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:4,className:`empty-state`,children:`No monitored paths match criteria.`})}):w.map((e,t)=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{children:e.path})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo})}),(0,H.jsx)(`td`,{children:e.category?(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category}):(0,H.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.file_count??0})})]},`${e.path}-${t}`))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:w.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No monitored paths match criteria.`}):w.map((e,t)=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.repo}),(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[e.file_count??0,` files`]})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{children:e.path})]}),e.category&&(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Category: `}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.category})]})]})]},`mpm-${t}`))})]}),(a===`all`||a===`local_storage`)&&T&&(0,H.jsxs)(`div`,{style:{marginBottom:`28px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,marginBottom:`10px`,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-hard-drive`,style:{color:`var(--accent)`}}),` Local Storage`,(0,H.jsxs)(`span`,{className:`badge badge-primary`,children:[T.file_count,` files`]})]}),(0,H.jsxs)(`div`,{style:{background:`rgba(255, 255, 255, 0.02)`,padding:`16px`,borderRadius:`8px`,border:`1px solid var(--border-card)`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,gap:`20px`,flexWrap:`wrap`,marginBottom:`12px`},children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.85rem`},children:`Storage Root: `}),(0,H.jsx)(`code`,{children:T.root_path})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,style:{fontSize:`0.85rem`},children:`Total Files: `}),(0,H.jsx)(`strong`,{children:T.file_count})]})]}),T.tree&&(0,H.jsxs)(`div`,{style:{fontSize:`0.85rem`,color:`var(--text-muted)`},children:[`Top-level Subfolders: `,(0,H.jsx)(`strong`,{children:T.tree.directories?.length||0}),` • Top-level Files: `,(0,H.jsx)(`strong`,{children:T.tree.files?.length||0})]})]})]}),s===`detailed`&&(0,H.jsxs)(`div`,{style:{marginTop:`20px`},children:[(0,H.jsxs)(`div`,{style:{display:`flex`,justifyContent:`space-between`,alignItems:`center`,flexWrap:`wrap`,gap:`10px`,marginBottom:`12px`},children:[(0,H.jsxs)(`h3`,{style:{fontSize:`1.05rem`,margin:0,display:`flex`,alignItems:`center`,gap:`8px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{color:`var(--primary)`}}),` Ingested Files Details`,(0,H.jsx)(`span`,{className:`badge badge-primary`,children:E.length})]}),(0,H.jsxs)(`div`,{className:`log-search-wrapper`,style:{maxWidth:`320px`},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass search-icon`}),(0,H.jsx)(`input`,{type:`text`,className:`log-search-input`,placeholder:`Search in loaded files...`,value:h,onChange:e=>g(e.target.value)}),h&&(0,H.jsx)(`button`,{className:`clear-search-btn`,onClick:()=>g(``),children:`×`})]})]}),(0,H.jsx)(`div`,{className:`table-container desktop-table-view`,children:(0,H.jsxs)(`table`,{children:[(0,H.jsx)(`thead`,{children:(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`th`,{children:`Filepath`}),(0,H.jsx)(`th`,{children:`Repository`}),(0,H.jsx)(`th`,{children:`Type`}),(0,H.jsx)(`th`,{children:`Language`}),(0,H.jsx)(`th`,{children:`Last Modified`})]})}),(0,H.jsx)(`tbody`,{children:E.length===0?(0,H.jsx)(`tr`,{children:(0,H.jsx)(`td`,{colSpan:5,className:`empty-state`,children:`No detailed files match current search or filters.`})}):E.map((e,t)=>(0,H.jsxs)(`tr`,{children:[(0,H.jsx)(`td`,{children:(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.filepath})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`strong`,{children:e.repo})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.doc_type})}),(0,H.jsx)(`td`,{children:(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.language||`text`})}),(0,H.jsx)(`td`,{style:{fontSize:`0.85rem`},children:S(e.mtime)})]},`${e.filepath}-${t}`))})]})}),(0,H.jsx)(`div`,{className:`mobile-card-list`,children:E.length===0?(0,H.jsx)(`div`,{className:`empty-state`,children:`No detailed files match current search or filters.`}):E.map((e,t)=>(0,H.jsxs)(`div`,{className:`data-mobile-card`,children:[(0,H.jsxs)(`div`,{className:`data-mobile-card-header`,children:[(0,H.jsx)(`strong`,{children:e.repo}),(0,H.jsx)(`span`,{className:`badge badge-accent`,children:e.language||`text`})]}),(0,H.jsxs)(`div`,{className:`data-mobile-card-body`,children:[(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Path: `}),(0,H.jsx)(`code`,{style:{wordBreak:`break-all`},children:e.filepath})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Type: `}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:e.doc_type})]}),(0,H.jsxs)(`div`,{children:[(0,H.jsx)(`span`,{className:`text-muted`,children:`Modified: `}),(0,H.jsx)(`span`,{children:S(e.mtime)})]})]})]},`dfm-${t}`))})]})]})})}function Wu(){let[e,t]=(0,V.useState)(`overview`),[n,r]=(0,V.useState)(!1),[i,a]=(0,V.useState)(null),[o,s]=(0,V.useState)(null),c=async()=>{try{let e=await fetch(`/admin/api/stats`);if(!e.ok)return;let t=await e.json();a(t)}catch(e){console.error(`Error loading stats:`,e)}};return(0,V.useEffect)(()=>{c();let e=setInterval(c,8e3);return()=>clearInterval(e)},[]),(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(`div`,{className:`dashboard-container`,children:[(0,H.jsxs)(`header`,{className:`dashboard-header`,children:[(0,H.jsx)(`div`,{className:`header-brand`,children:(0,H.jsxs)(`div`,{className:`header-logo`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-layer-group logo-icon`}),(0,H.jsxs)(`div`,{className:`header-title`,children:[(0,H.jsx)(`h1`,{children:`ContextCortex`}),(0,H.jsx)(`span`,{className:`badge badge-primary`,children:`v2.17.1`})]})]})}),(0,H.jsxs)(`div`,{className:`header-status`,children:[(0,H.jsxs)(`div`,{className:`status-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Engine State`}),(0,H.jsx)(`span`,{className:`value`,children:i?.is_indexing?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`indicator indexing`}),` Syncing...`]}):(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`span`,{className:`indicator online`}),` Idle`]})})]}),(0,H.jsxs)(`div`,{className:`status-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Vector Backend`}),(0,H.jsxs)(`span`,{className:`value`,children:[(0,H.jsx)(`i`,{className:`fa-solid fa-database`,style:{marginRight:`5px`}}),(0,H.jsxs)(`span`,{children:[i?.vector_store_provider===`chroma`?`ChromaDB`:`Qdrant`,` (`,(i?.vector_store_mode||`embedded`)===`embedded`?`Embedded`:`Remote`,`)`]}),i?.vector_db_status&&(0,H.jsx)(`span`,{className:`badge ${i.vector_db_status===`Healthy`?`badge-success`:`badge-danger`}`,style:{marginLeft:`6px`,fontSize:`0.75rem`,padding:`2px 6px`},"data-testid":`vector-db-status-badge`,children:i.vector_db_status})]})]}),(0,H.jsxs)(`div`,{className:`status-item header-collection-item`,children:[(0,H.jsx)(`span`,{className:`label`,children:`Collection`}),(0,H.jsx)(`span`,{className:`value code`,children:i?.vector_store_collection||`knowledge_rag_v1`})]})]}),(0,H.jsx)(`button`,{className:`menu-toggle-btn`,"aria-label":`Toggle navigation`,onClick:()=>r(!n),children:(0,H.jsx)(`i`,{className:`fa-solid ${n?`fa-xmark`:`fa-bars`}`})})]}),(0,H.jsxs)(`nav`,{className:`dashboard-nav ${n?`drawer-open`:``}`,"aria-label":`Main Navigation`,children:[(0,H.jsxs)(`button`,{className:`nav-tab ${e===`overview`?`active`:``}`,onClick:()=>{t(`overview`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-chart-pie`}),(0,H.jsx)(`span`,{children:`Overview`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`navigator`||e===`topology`?`active`:``}`,onClick:()=>{t(`navigator`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-code-fork`}),(0,H.jsx)(`span`,{children:`Navigator`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`git-repos`?`active`:``}`,onClick:()=>{t(`git-repos`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-brands fa-github`}),(0,H.jsx)(`span`,{children:`Git Repositories`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`files-storage`?`active`:``}`,onClick:()=>{t(`files-storage`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),(0,H.jsx)(`span`,{children:`Files & Storage`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`ingestion-catalog`?`active`:``}`,onClick:()=>{t(`ingestion-catalog`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-book-bookmark`}),(0,H.jsx)(`span`,{children:`Ingestion Catalog`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`search-inspector`?`active`:``}`,onClick:()=>{t(`search-inspector`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),(0,H.jsx)(`span`,{children:`Search & Inspector`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`settings`?`active`:``}`,onClick:()=>{t(`settings`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-gear`}),(0,H.jsx)(`span`,{children:`Settings`})]}),(0,H.jsxs)(`button`,{className:`nav-tab ${e===`diagnostics`?`active`:``}`,onClick:()=>{t(`diagnostics`),r(!1)},children:[(0,H.jsx)(`i`,{className:`fa-solid fa-terminal`}),(0,H.jsx)(`span`,{children:`Diagnostics & Logs`})]})]}),(0,H.jsxs)(`main`,{className:`dashboard-main`,children:[e===`overview`&&(0,H.jsx)(Ze,{stats:i,refreshStats:c}),(e===`navigator`||e===`topology`)&&(0,H.jsx)(Hu,{initialRepo:o?.repo,initialPath:o?.path,initialSymbolId:o?.symbolId,initialStartLine:o?.startLine,initialEndLine:o?.endLine,onNavigationConsumed:()=>s(null)}),e===`git-repos`&&(0,H.jsx)(it,{refreshStats:c}),e===`files-storage`&&(0,H.jsx)(ct,{refreshStats:c}),e===`ingestion-catalog`&&(0,H.jsx)(Uu,{}),e===`search-inspector`&&(0,H.jsx)(pt,{onOpenInNavigator:(e,n,r,i,a)=>{s({repo:e,path:n,symbolId:r,startLine:i,endLine:a}),t(`navigator`)}}),e===`settings`&&(0,H.jsx)(Et,{stats:i,refreshStats:c}),e===`diagnostics`&&(0,H.jsx)(Dt,{})]}),(0,H.jsx)(`footer`,{className:`dashboard-footer`,children:(0,H.jsx)(`p`,{children:`ContextCortex MCP • Universal Code & Knowledge RAG • 2026`})})]})})}(0,Ge.createRoot)(document.getElementById(`root`)).render((0,H.jsx)(V.StrictMode,{children:(0,H.jsx)(Xe,{children:(0,H.jsx)(Wu,{})})}));export{ta as _,Ua as a,ja as c,qa as d,Va as f,fa as g,Oa as h,Ba as i,Ma as l,Ea as m,mo as n,no as o,ka as p,Ha as r,Ga as s,go as t,so as u,ia as v,Ar as y}; \ No newline at end of file diff --git a/www/assets/index-Kt80tNPz.js b/www/assets/index-Kt80tNPz.js deleted file mode 100644 index 0491a7d..0000000 --- a/www/assets/index-Kt80tNPz.js +++ /dev/null @@ -1,9 +0,0 @@ -var e=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports);(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var t=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var ee=Array.isArray;function S(){}var C={H:null,A:null,T:null,S:null},te=Object.prototype.hasOwnProperty;function ne(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function re(e,t){return ne(e.type,t,e.props)}function ie(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ae(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var oe=/\/+/g;function se(e,t){return typeof e==`object`&&e&&e.key!=null?ae(``+e.key):t.toString(36)}function ce(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(S,S):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function le(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,le(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+se(e,0):a,ee(o)?(i=``,c!=null&&(i=c.replace(oe,`$&/`)+`/`),le(o,r,i,``,function(e){return e})):o!=null&&(ie(o)&&(o=re(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(oe,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(ee(e))for(var u=0;u{n.exports=t()})),r=e((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0>>1,a=e[r];if(0>>1;ri(c,n))li(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(li(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,ee||(ee=!0,ie());else{var t=n(l);t!==null&&se(x,t.startTime-e)}}}var ee=!1,S=-1,C=5,te=-1;function ne(){return g?!0:!(e.unstable_now()-tet&&ne());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&se(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}}}finally{i?ie():ee=!1}}}var ie;if(typeof y==`function`)ie=function(){y(re)};else if(typeof MessageChannel<`u`){var ae=new MessageChannel,oe=ae.port2;ae.port1.onmessage=re,ie=function(){oe.postMessage(null)}}else ie=function(){_(re,0)};function se(t,n){S=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(S),S=-1):h=!0,se(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,ee||(ee=!0,ie()))),r},e.unstable_shouldYield=ne,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),i=e(((e,t)=>{t.exports=r()})),a=e((e=>{var t=n();function r(e){var t=`https://react.dev/errors/`+e;if(1{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=a()})),s=e((e=>{var t=i(),r=n(),a=o();function s(e){var t=`https://react.dev/errors/`+e;if(1me||(e.current=pe[me],pe[me]=null,me--)}function D(e,t){me++,pe[me]=e.current,e.current=t}var ge=he(null),_e=he(null),ve=he(null),ye=he(null);function be(e,t){switch(D(ve,t),D(_e,e),D(ge,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}E(ge),D(ge,e)}function xe(){E(ge),E(_e),E(ve)}function Se(e){e.memoizedState!==null&&D(ye,e);var t=ge.current,n=Hd(t,e.type);t!==n&&(D(_e,e),D(ge,n))}function Ce(e){_e.current===e&&(E(ge),E(_e)),ye.current===e&&(E(ye),Qf._currentValue=fe)}var we,Te;function Ee(e){if(we===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);we=t&&t[1]||``,Te=-1)`:-1i||c[r]!==l[i]){var u=` -`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(``)&&(u=u.replace(``,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{De=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?Ee(n):``}function ke(e,t){switch(e.tag){case 26:case 27:case 5:return Ee(e.type);case 16:return Ee(`Lazy`);case 13:return e.child!==t&&t!==null?Ee(`Suspense Fallback`):Ee(`Suspense`);case 19:return Ee(`SuspenseList`);case 0:case 15:return Oe(e.type,!1);case 11:return Oe(e.type.render,!1);case 1:return Oe(e.type,!0);case 31:return Ee(`Activity`);default:return``}}function Ae(e){try{var t=``,n=null;do t+=ke(e,n),n=e,e=e.return;while(e);return t}catch(e){return` -Error generating stack: `+e.message+` -`+e.stack}}var je=Object.prototype.hasOwnProperty,Me=t.unstable_scheduleCallback,Ne=t.unstable_cancelCallback,Pe=t.unstable_shouldYield,Fe=t.unstable_requestPaint,Ie=t.unstable_now,Le=t.unstable_getCurrentPriorityLevel,Re=t.unstable_ImmediatePriority,ze=t.unstable_UserBlockingPriority,Be=t.unstable_NormalPriority,Ve=t.unstable_LowPriority,He=t.unstable_IdlePriority,Ue=t.log,We=t.unstable_setDisableYieldValue,Ge=null,Ke=null;function qe(e){if(typeof Ue==`function`&&We(e),Ke&&typeof Ke.setStrictMode==`function`)try{Ke.setStrictMode(Ge,e)}catch{}}var Je=Math.clz32?Math.clz32:Ze,Ye=Math.log,Xe=Math.LN2;function Ze(e){return e>>>=0,e===0?32:31-(Ye(e)/Xe|0)|0}var Qe=256,$e=262144,et=4194304;function tt(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function nt(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=tt(n))):i=tt(o):i=tt(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=tt(n))):i=tt(o)):i=tt(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function rt(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function it(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function at(){var e=et;return et<<=1,!(et&62914560)&&(et=4194304),e}function ot(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function st(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function ct(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0`u`||window.document===void 0||window.document.createElement===void 0),bn=!1;if(yn)try{var xn={};Object.defineProperty(xn,"passive",{get:function(){bn=!0}}),window.addEventListener(`test`,xn,xn),window.removeEventListener(`test`,xn,xn)}catch{bn=!1}var Sn=null,Cn=null,wn=null;function Tn(){if(wn)return wn;var e,t=Cn,n=t.length,r,i=`value`in Sn?Sn.value:Sn.textContent,a=i.length;for(e=0;e=rr),or=` `,sr=!1;function cr(e,t){switch(e){case`keyup`:return tr.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function lr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var ur=!1;function dr(e,t){switch(e){case`compositionend`:return lr(t);case`keypress`:return t.which===32?(sr=!0,or):null;case`textInput`:return e=t.data,e===or&&sr?null:e;default:return null}}function fr(e,t){if(ur)return e===`compositionend`||!nr&&cr(e,t)?(e=Tn(),wn=Cn=Sn=null,ur=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=Pr(n)}}function Ir(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ir(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Lr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Kt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Kt(e.document)}return t}function Rr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var zr=yn&&`documentMode`in document&&11>=document.documentMode,Br=null,Vr=null,Hr=null,Ur=!1;function Wr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ur||Br==null||Br!==Kt(r)||(r=Br,`selectionStart`in r&&Rr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Hr&&Nr(Hr,r)||(Hr=r,r=Ed(Vr,`onSelect`),0>=o,i-=o,Ii=1<<32-Je(t)+i|n<h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),o=a(_,o,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),j&&Ri(i,h),l;if(d===null){for(;hg?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),o=a(y,o,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),j&&Ri(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return j&&Ri(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),o=a(v,o,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),j&&Ri(i,g),u}function b(e,r,a,c){if(typeof a==`object`&&a&&a.type===y&&a.key===null&&(a=a.props.children),typeof a==`object`&&a){switch(a.$$typeof){case _:a:{for(var l=a.key;r!==null;){if(r.key===l){if(l=a.type,l===y){if(r.tag===7){n(e,r.sibling),c=i(r,a.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===ie&&Fa(l)===r.type){n(e,r.sibling),c=i(r,a.props),Ha(c,a),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}a.type===y?(c=Ci(a.props.children,e.mode,c,a.key),c.return=e,e=c):(c=Si(a.type,a.key,a.props,null,e.mode,c),Ha(c,a),c.return=e,e=c)}return o(e);case v:a:{for(l=a.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===a.containerInfo&&r.stateNode.implementation===a.implementation){n(e,r.sibling),c=i(r,a.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=Ei(a,e.mode,c),c.return=e,e=c}return o(e);case ie:return a=Fa(a),b(e,r,a,c)}if(de(a))return h(e,r,a,c);if(ce(a)){if(l=ce(a),typeof l!=`function`)throw Error(s(150));return a=l.call(a),g(e,r,a,c)}if(typeof a.then==`function`)return b(e,r,Va(a),c);if(a.$$typeof===S)return b(e,r,ua(e,a),c);Ua(e,a)}return typeof a==`string`&&a!==``||typeof a==`number`||typeof a==`bigint`?(a=``+a,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,a),c.return=e,e=c):(n(e,r),c=wi(a,e.mode,c),c.return=e,e=c),o(e)):n(e,r)}return function(e,t,n,r){try{Ba=0;var i=b(e,t,n,r);return za=null,i}catch(t){if(t===ka||t===ja)throw t;var a=vi(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ga=Wa(!0),Ka=Wa(!1),qa=!1;function Ja(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ya(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Xa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Za(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,W&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=hi(e),mi(e,null,n),t}return di(e,r,t,n),hi(e)}function Qa(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ut(e,n)}}function $a(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var eo=!1;function to(){if(eo){var e=ba;if(e!==null)throw e}}function no(e,t,n,r){eo=!1;var i=e.updateQueue;qa=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(q&f)===f:(r&f)===f){f!==0&&f===ya&&(eo=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:qa=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Kl|=o,e.lanes=o,e.memoizedState=d}}function ro(e,t){if(typeof e!=`function`)throw Error(s(191,e));e.call(t)}function io(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;ea?a:8;var o=w.T,s={};w.T=s,zs(e,!1,t,n);try{var c=i(),l=w.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Rs(e,t,Ca(c,r),pu(e)):Rs(e,t,r,pu(e))}catch(n){Rs(e,t,{then:function(){},status:`rejected`,reason:n},pu())}finally{T.p=a,o!==null&&s.types!==null&&(o.types=s.types),w.T=o}}function Os(){}function ks(e,t,n,r){if(e.tag!==5)throw Error(s(476));var i=As(e).queue;Ds(e,i,t,fe,n===null?Os:function(){return js(e),n(r)})}function As(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:fe,baseState:fe,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bo,lastRenderedState:fe},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function js(e){var t=As(e);t.next===null&&(t=e.alternate.memoizedState),Rs(e,t.next.queue,{},pu())}function Ms(){return la(Qf)}function Ns(){return R().memoizedState}function Ps(){return R().memoizedState}function Fs(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=pu();e=Xa(n);var r=Za(t,e,n);r!==null&&(hu(r,t,n),Qa(r,t,n)),t={cache:ha()},e.payload=t;return}t=t.return}}function Is(e,t,n){var r=pu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Bs(e)?Vs(t,n):(n=fi(e,t,n,r),n!==null&&(hu(n,e,r),Hs(n,t,r)))}function Ls(e,t,n){Rs(e,t,n,pu())}function Rs(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Bs(e))Vs(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Mr(s,o))return di(e,t,i,0),G===null&&ui(),!1}catch{}if(n=fi(e,t,i,r),n!==null)return hu(n,e,r),Hs(n,t,r),!0}return!1}function zs(e,t,n,r){if(r={lane:2,revertLane:dd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Bs(e)){if(t)throw Error(s(479))}else t=fi(e,n,r,2),t!==null&&hu(t,e,2)}function Bs(e){var t=e.alternate;return e===P||t!==null&&t===P}function Vs(e,t){xo=bo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Hs(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ut(e,n)}}var Us={readContext:la,use:Ro,useCallback:L,useContext:L,useEffect:L,useImperativeHandle:L,useLayoutEffect:L,useInsertionEffect:L,useMemo:L,useReducer:L,useRef:L,useState:L,useDebugValue:L,useDeferredValue:L,useTransition:L,useSyncExternalStore:L,useId:L,useHostTransitionStatus:L,useFormState:L,useActionState:L,useOptimistic:L,useMemoCache:L,useCacheRefresh:L};Us.useEffectEvent=L;var Ws={readContext:la,use:Ro,useCallback:function(e,t){return Fo().memoizedState=[e,t===void 0?null:t],e},useContext:la,useEffect:ms,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),fs(4194308,4,bs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return fs(4194308,4,e,t)},useInsertionEffect:function(e,t){fs(4,2,e,t)},useMemo:function(e,t){var n=Fo();t=t===void 0?null:t;var r=e();if(So){qe(!0);try{e()}finally{qe(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Fo();if(n!==void 0){var i=n(t);if(So){qe(!0);try{n(t)}finally{qe(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Is.bind(null,P,e),[r.memoizedState,e]},useRef:function(e){var t=Fo();return e={current:e},t.memoizedState=e},useState:function(e){e=Xo(e);var t=e.queue,n=Ls.bind(null,P,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Ss,useDeferredValue:function(e,t){return Ts(Fo(),e,t)},useTransition:function(){var e=Xo(!1);return e=Ds.bind(null,P,e.queue,!0,!1),Fo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=P,i=Fo();if(j){if(n===void 0)throw Error(s(407));n=n()}else{if(n=t(),G===null)throw Error(s(349));q&127||Go(r,t,n)}i.memoizedState=n;var a={value:n,getSnapshot:t};return i.queue=a,ms(qo.bind(null,r,a,e),[e]),r.flags|=2048,us(9,{destroy:void 0},Ko.bind(null,r,a,n,t),null),n},useId:function(){var e=Fo(),t=G.identifierPrefix;if(j){var n=Li,r=Ii;n=(r&~(1<<32-Je(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=Co++,0<\/script>`,a=a.removeChild(a.firstChild);break;case`select`:a=typeof r.is==`string`?o.createElement(`select`,{is:r.is}):o.createElement(`select`),r.multiple?a.multiple=!0:r.size&&(a.size=r.size);break;default:a=typeof r.is==`string`?o.createElement(i,{is:r.is}):o.createElement(i)}}a[_t]=t,a[vt]=r;a:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)a.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break a;for(;o.sibling===null;){if(o.return===null||o.return===t)break a;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=a;a:switch(Pd(a,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Lc(t)}}return B(t),Rc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Lc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(s(166));if(e=ve.current,Yi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=k,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[_t]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Md(e.nodeValue,n)),e||Ki(t,!0)}else e=Bd(e).createTextNode(r),e[_t]=t,t.stateNode=e}return B(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Yi(t),n!==null){if(e===null){if(!r)throw Error(s(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(s(557));e[_t]=t}else Xi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;B(t),e=!1}else n=Zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(_o(t),t):(_o(t),null);if(t.flags&128)throw Error(s(558))}return B(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Yi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(s(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(s(317));i[_t]=t}else Xi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;B(t),i=!1}else i=Zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(_o(t),t):(_o(t),null)}return _o(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),a=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(a=r.memoizedState.cachePool.pool),a!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Bc(t,t.updateQueue),B(t),null);case 4:return xe(),e===null&&Sd(t.stateNode.containerInfo),B(t),null;case 10:return ra(t.type),B(t),null;case 19:if(E(N),r=t.memoizedState,r===null)return B(t),null;if(i=!!(t.flags&128),a=r.rendering,a===null){if(i)Vc(r,!1);else{if(Y!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(a=vo(e),a!==null){for(t.flags|=128,Vc(r,!1),e=a.updateQueue,t.updateQueue=e,Bc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)xi(n,e),n=n.sibling;return D(N,N.current&1|2),j&&Ri(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ie()>nu&&(t.flags|=128,i=!0,Vc(r,!1),t.lanes=4194304)}}else{if(!i){if(e=vo(a),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Bc(t,e),Vc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!a.alternate&&!j)return B(t),null}else 2*Ie()-r.renderingStartTime>nu&&n!==536870912&&(t.flags|=128,i=!0,Vc(r,!1),t.lanes=4194304)}r.isBackwards?(a.sibling=t.child,t.child=a):(e=r.last,e===null?t.child=a:e.sibling=a,r.last=a)}return r.tail===null?(B(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ie(),e.sibling=null,n=N.current,D(N,i?n&1|2:n&1),j&&Ri(t,r.treeForkCount),e);case 22:case 23:return _o(t),lo(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(B(t),t.subtreeFlags&6&&(t.flags|=8192)):B(t),n=t.updateQueue,n!==null&&Bc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&E(Ta),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),ra(M),B(t),null;case 25:return null;case 30:return null}throw Error(s(156,t.tag))}function Uc(e,t){switch(Vi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ra(M),xe(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Ce(t),null;case 31:if(t.memoizedState!==null){if(_o(t),t.alternate===null)throw Error(s(340));Xi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(_o(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(s(340));Xi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return E(N),null;case 4:return xe(),null;case 10:return ra(t.type),null;case 22:case 23:return _o(t),lo(),e!==null&&E(Ta),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return ra(M),null;case 25:return null;default:return null}}function Wc(e,t){switch(Vi(t),t.tag){case 3:ra(M),xe();break;case 26:case 27:case 5:Ce(t);break;case 4:xe();break;case 31:t.memoizedState!==null&&_o(t);break;case 13:_o(t);break;case 19:E(N);break;case 10:ra(t.type);break;case 22:case 23:_o(t),lo(),e!==null&&E(Ta);break;case 24:ra(M)}}function Gc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Z(t,t.return,e)}}function Kc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Z(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Z(t,t.return,e)}}function qc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{io(t,n)}catch(t){Z(e,e.return,t)}}}function Jc(e,t,n){n.props=Zs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Z(e,t,n)}}function Yc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Z(e,t,n)}}function Xc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Z(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Z(e,t,n)}else n.current=null}}function Zc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Z(e,e.return,t)}}function Qc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[vt]=t}catch(t){Z(e,e.return,t)}}function $c(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function el(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||$c(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function tl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=un));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(tl(e,t,n),e=e.sibling;e!==null;)tl(e,t,n),e=e.sibling}function nl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(nl(e,t,n),e=e.sibling;e!==null;)nl(e,t,n),e=e.sibling}function rl(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[_t]=e,t[vt]=n}catch(t){Z(e,e.return,t)}}var il=!1,V=!1,al=!1,ol=typeof WeakSet==`function`?WeakSet:Set,H=null;function sl(e,t){if(e=e.containerInfo,Rd=sp,e=Lr(e),Rr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,a=r.focusNode;r=r.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break a}var o=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=o+i),f!==a||r!==0&&f.nodeType!==3||(l=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=o),p===a&&++d===r&&(l=o),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,H=t;H!==null;)if(t=H,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,H=e;else for(;H!==null;){switch(t=H,a=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n title`))),Pd(a,r,n),a[_t]=e,O(a),r=a;break a;case`link`:var o=Vf(`link`,`href`,i).get(r+(n.href||``));if(o){for(var c=0;cg&&(o=g,g=h,h=o);var _=Fr(s,h),v=Fr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;sn?32:n,w.T=null,n=lu,lu=null;var a=au,o=su;if(X=0,ou=au=null,su=0,W&6)throw Error(s(331));var c=W;if(W|=4,Il(a.current),Ol(a,a.current,o,n),W=c,id(0,!1),Ke&&typeof Ke.onPostCommitFiberRoot==`function`)try{Ke.onPostCommitFiberRoot(Ge,a)}catch{}return!0}finally{T.p=i,w.T=r,Vu(e,t)}}function Wu(e,t,n){t=Oi(n,t),t=rc(e.stateNode,t,2),e=Za(e,t,2),e!==null&&(st(e,2),rd(e))}function Z(e,t,n){if(e.tag===3)Wu(e,e,n);else for(;t!==null;){if(t.tag===3){Wu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(iu===null||!iu.has(r))){e=Oi(n,e),n=ic(2),r=Za(t,n,2),r!==null&&(ac(n,r,t,e),st(r,2),rd(r));break}}t=t.return}}function Gu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Bl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Wl=!0,i.add(n),e=Ku.bind(null,e,t,n),t.then(e,e))}function Ku(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,G===e&&(q&n)===n&&(Y===4||Y===3&&(q&62914560)===q&&300>Ie()-eu?!(W&2)&&Su(e,0):Jl|=n,Xl===q&&(Xl=0)),rd(e)}function qu(e,t){t===0&&(t=at()),e=pi(e,t),e!==null&&(st(e,t),rd(e))}function Ju(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),qu(e,n)}function Yu(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(s(314))}r!==null&&r.delete(t),qu(e,n)}function Xu(e,t){return Me(e,t)}var Zu=null,Qu=null,$u=!1,ed=!1,td=!1,nd=0;function rd(e){e!==Qu&&e.next===null&&(Qu===null?Zu=Qu=e:Qu=Qu.next=e),ed=!0,$u||($u=!0,ud())}function id(e,t){if(!td&&ed){td=!0;do for(var n=!1,r=Zu;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Je(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,ld(r,a))}else a=q,a=nt(r,r===G?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||rt(r,a)||(n=!0,ld(r,a))}r=r.next}while(n);td=!1}}function ad(){od()}function od(){ed=$u=!1;var e=0;nd!==0&&Gd()&&(e=nd);for(var t=Ie(),n=null,r=Zu;r!==null;){var i=r.next,a=sd(r,t);a===0?(r.next=null,n===null?Zu=i:n.next=i,i===null&&(Qu=n)):(n=r,(e!==0||a&3)&&(ed=!0)),r=i}X!==0&&X!==5||id(e,!1),nd!==0&&(nd=0)}function sd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Jt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),O(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Jt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Jt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Jt(n.imageSizes)+`"]`)):i+=`[href="`+Jt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),O(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Jt(r)+`"][href="`+Jt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=h({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),O(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=kt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);O(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=kt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),O(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=kt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),O(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=ve.current)?gf(i):null;if(!i)throw Error(s(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=kt(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var a=kt(i).hoistableStyles,o=a.get(e);if(o||(i=i.ownerDocument||i,o={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},a.set(e,o),(a=i.querySelector(jf(e)))&&!a._p&&(o.instance=a,o.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),a||Nf(i,e,n,o.state))),t&&r===null)throw Error(s(528,``));return o}if(t&&r!==null)throw Error(s(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=kt(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(s(444,e))}}function Af(e){return`href="`+Jt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),O(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Jt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Jt(n.href)+`"]`);if(r)return t.instance=r,O(r),r;var i=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),O(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var a=e.querySelector(jf(i));if(a)return t.state.loading|=4,t.instance=a,O(a),a;r=Mf(n),(i=mf.get(i))&&Rf(r,i),a=(e.ownerDocument||e).createElement(`link`),O(a);var o=a;return o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),t.state.loading|=4,Lf(a,n.precedence,e),t.instance=a;case`script`:return a=Pf(n.src),(i=e.querySelector(Ff(a)))?(t.instance=i,O(i),i):(r=n,(i=mf.get(a))&&(r=h({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),O(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(s(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,O(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),O(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=s()})),l=n(),u=c(),d=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),f=e(((e,t)=>{t.exports=d()}))();function p({stats:e,refreshStats:t}){return e?(0,f.jsxs)(`div`,{className:`tab-content active`,children:[(0,f.jsxs)(`div`,{className:`overview-grid`,children:[(0,f.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,f.jsx)(`div`,{className:`metric-icon`,children:(0,f.jsx)(`i`,{className:`fa-brands fa-github`})}),(0,f.jsxs)(`div`,{className:`metric-info`,children:[(0,f.jsx)(`span`,{className:`stat-number`,children:(e.repos_count||0).toLocaleString()}),(0,f.jsx)(`span`,{className:`stat-label`,children:`Git Repositories`})]})]}),(0,f.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,f.jsx)(`div`,{className:`metric-icon`,children:(0,f.jsx)(`i`,{className:`fa-solid fa-code`})}),(0,f.jsxs)(`div`,{className:`metric-info`,children:[(0,f.jsx)(`span`,{className:`stat-number`,children:(e.symbols_count||0).toLocaleString()}),(0,f.jsx)(`span`,{className:`stat-label`,children:`AST Code Symbols`})]})]}),(0,f.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,f.jsx)(`div`,{className:`metric-icon`,children:(0,f.jsx)(`i`,{className:`fa-solid fa-file-code`})}),(0,f.jsxs)(`div`,{className:`metric-info`,children:[(0,f.jsx)(`span`,{className:`stat-number`,children:(e.files_count||0).toLocaleString()}),(0,f.jsx)(`span`,{className:`stat-label`,children:`Indexed Files`})]})]}),(0,f.jsxs)(`div`,{className:`glass-card stat-metric`,children:[(0,f.jsx)(`div`,{className:`metric-icon`,children:(0,f.jsx)(`i`,{className:`fa-solid fa-network-wired`})}),(0,f.jsxs)(`div`,{className:`metric-info`,children:[(0,f.jsx)(`span`,{className:`stat-number`,children:(e.points_count||0).toLocaleString()}),(0,f.jsx)(`span`,{className:`stat-label`,children:`Hybrid Vectors`})]})]})]}),(0,f.jsxs)(`div`,{className:`two-col-layout`,style:{marginTop:`20px`},children:[(0,f.jsxs)(`div`,{className:`glass-card`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-server`}),` System & Embedding Specs`]}),(0,f.jsxs)(`div`,{className:`specs-list`,children:[(0,f.jsxs)(`div`,{className:`spec-row`,children:[(0,f.jsx)(`span`,{children:`Dense Embedding Model:`}),(0,f.jsx)(`code`,{children:e.dense_model||`bge-small-en-v1.5 (384d)`})]}),(0,f.jsxs)(`div`,{className:`spec-row`,children:[(0,f.jsx)(`span`,{children:`Sparse BM25 Model:`}),(0,f.jsx)(`code`,{children:e.sparse_model?`${e.sparse_model} (FastEmbed)`:`Qdrant/bm25 (FastEmbed)`})]}),(0,f.jsxs)(`div`,{className:`spec-row`,children:[(0,f.jsx)(`span`,{children:`Retrieval Strategy:`}),(0,f.jsx)(`span`,{className:`badge badge-accent`,children:`Dense + BM25 Reciprocal Rank Fusion (RRF)`})]}),(0,f.jsxs)(`div`,{className:`spec-row`,children:[(0,f.jsx)(`span`,{children:`AST Chunker:`}),(0,f.jsx)(`span`,{children:`Tree-sitter AST (Classes, Functions, Methods)`})]}),(0,f.jsxs)(`div`,{className:`spec-row`,children:[(0,f.jsx)(`span`,{children:`Last Global Index:`}),(0,f.jsx)(`span`,{className:`code`,children:e.last_indexed||`Never`})]})]}),(0,f.jsx)(`div`,{style:{marginTop:`20px`},children:(0,f.jsx)(`button`,{className:`btn btn-primary`,onClick:async()=>{try{await fetch(`/admin/api/reindex`,{method:`POST`}),t()}catch(e){alert(`Reindex error: `+e.message)}},disabled:e.is_indexing,children:e.is_indexing?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing...`]}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Reindex All Sources`]})})})]}),(0,f.jsxs)(`div`,{className:`glass-card`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-tags`}),` Top Extracted Topics & Symbols`]}),(0,f.jsx)(`div`,{className:`tag-cloud`,children:!e.top_keywords||e.top_keywords.length===0?(0,f.jsx)(`span`,{className:`text-muted`,children:`No topics extracted yet. Sync repositories to populate.`}):e.top_keywords.map(e=>(0,f.jsx)(`span`,{className:`topic-tag`,children:e},e))})]})]})]}):(0,f.jsx)(`div`,{className:`tab-content active`,children:(0,f.jsx)(`p`,{children:`Loading...`})})}function m({refreshStats:e}){let[t,n]=(0,l.useState)([]),[r,i]=(0,l.useState)(!1),[a,o]=(0,l.useState)(``),[s,c]=(0,l.useState)(``),[u,d]=(0,l.useState)(`main`),[p,m]=(0,l.useState)(``),[h,g]=(0,l.useState)(!1),_=async()=>{try{let e=await fetch(`/admin/api/repos`);if(!e.ok)return;let t=await e.json();n(t)}catch(e){console.error(`Error loading repos:`,e)}};(0,l.useEffect)(()=>{_();let e=setInterval(_,8e3);return()=>clearInterval(e)},[]);let v=async t=>{t.preventDefault(),g(!0);try{let t=await fetch(`/admin/api/repos`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({name:a.trim(),url:s.trim(),branch:u.trim()||`main`,auth_token:p.trim()||null})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add repository`);i(!1),o(``),c(``),d(`main`),m(``),_(),e()}catch(e){alert(`Error: ${e.message}`)}finally{g(!1)}},y=async t=>{try{await fetch(`/admin/api/repos/sync/${t}`,{method:`POST`}),_(),e()}catch(e){alert(`Failed to trigger sync: `+e.message)}},b=async(t,n)=>{if(window.confirm(`Are you sure you want to delete repository '${n}'? All vectors and indexed symbols for this repo will be permanently purged.`))try{await fetch(`/admin/api/repos/${t}`,{method:`DELETE`}),_(),e()}catch(e){alert(`Failed to delete repo: `+e.message)}};return(0,f.jsxs)(`div`,{className:`tab-content active`,children:[(0,f.jsxs)(`div`,{className:`glass-card`,children:[(0,f.jsxs)(`div`,{className:`card-header-btn`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-brands fa-github`}),` Registered Git Repositories`]}),(0,f.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Repositories are shallow-cloned, parsed into AST chunks, and immediately pruned from disk.`})]}),(0,f.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>i(!0),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Repository`]})]}),(0,f.jsx)(`div`,{className:`table-container`,children:(0,f.jsxs)(`table`,{children:[(0,f.jsx)(`thead`,{children:(0,f.jsxs)(`tr`,{children:[(0,f.jsx)(`th`,{children:`Repo Alias`}),(0,f.jsx)(`th`,{children:`Git URL`}),(0,f.jsx)(`th`,{children:`Branch`}),(0,f.jsx)(`th`,{children:`Commit SHA`}),(0,f.jsx)(`th`,{children:`Status`}),(0,f.jsx)(`th`,{children:`Files`}),(0,f.jsx)(`th`,{children:`Last Synced`}),(0,f.jsx)(`th`,{children:`Actions`})]})}),(0,f.jsx)(`tbody`,{children:t.length===0?(0,f.jsx)(`tr`,{children:(0,f.jsx)(`td`,{colSpan:8,className:`empty-state`,children:`No Git repositories registered. Click "Add Repository" to index a remote repo.`})}):t.map(e=>(0,f.jsxs)(`tr`,{children:[(0,f.jsx)(`td`,{children:(0,f.jsx)(`strong`,{children:e.name})}),(0,f.jsx)(`td`,{children:(0,f.jsxs)(`a`,{href:e.url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,textDecoration:`none`,fontSize:`0.85rem`},children:[(0,f.jsx)(`i`,{className:`fa-solid fa-arrow-up-right-from-square`}),` `,e.url]})}),(0,f.jsx)(`td`,{children:(0,f.jsx)(`code`,{children:e.branch})}),(0,f.jsx)(`td`,{children:e.commit_sha?(0,f.jsx)(`code`,{children:e.commit_sha.substring(0,8)}):(0,f.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,f.jsx)(`td`,{children:e.status===`syncing`?(0,f.jsxs)(`span`,{className:`badge badge-warning`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Syncing`]}):e.status===`error`?(0,f.jsxs)(`span`,{className:`badge badge-danger`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-circle-exclamation`}),` Error`]}):e.status===`pending`?(0,f.jsxs)(`span`,{className:`badge badge-primary`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-clock`}),` Pending`]}):(0,f.jsxs)(`span`,{className:`badge badge-success`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-check`}),` Synced`]})}),(0,f.jsxs)(`td`,{children:[(e.file_count||0).toLocaleString(),` files`]}),(0,f.jsx)(`td`,{style:{fontSize:`0.8rem`,color:`var(--text-muted)`},children:e.last_synced||`Never`}),(0,f.jsx)(`td`,{children:(0,f.jsxs)(`div`,{style:{display:`flex`,gap:`6px`},children:[(0,f.jsxs)(`button`,{className:`btn btn-secondary`,style:{padding:`4px 8px`,fontSize:`0.8rem`},onClick:()=>y(e.id),title:`Trigger Sync`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-arrows-rotate`}),` Sync`]}),(0,f.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>b(e.id,e.name),title:`Delete Repo`,children:(0,f.jsx)(`i`,{className:`fa-solid fa-trash-can`})})]})})]},e.id))})]})})]}),r&&(0,f.jsx)(`div`,{className:`modal-backdrop`,children:(0,f.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,f.jsxs)(`div`,{className:`modal-header`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-brands fa-github`}),` Register Git Repository`]}),(0,f.jsx)(`button`,{className:`btn-close`,onClick:()=>i(!1),children:`×`})]}),(0,f.jsxs)(`form`,{onSubmit:v,children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`repo-alias`,children:`Repository Alias / Identifier`}),(0,f.jsx)(`input`,{type:`text`,id:`repo-alias`,required:!0,placeholder:`e.g. backend-api or notes-rag-mcp`,value:a,onChange:e=>o(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`repo-url`,children:`Git Clone URL (HTTPS)`}),(0,f.jsx)(`input`,{type:`url`,id:`repo-url`,required:!0,placeholder:`https://github.com/owner/repository.git`,value:s,onChange:e=>c(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-row`,children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`repo-branch`,children:`Branch / Tag`}),(0,f.jsx)(`input`,{type:`text`,id:`repo-branch`,placeholder:`main`,value:u,onChange:e=>d(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`repo-token`,children:`Per-Repo Auth Token (Optional)`}),(0,f.jsx)(`input`,{type:`password`,id:`repo-token`,placeholder:`Optional token override`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,f.jsxs)(`div`,{className:`modal-footer`,children:[(0,f.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>i(!1),children:`Cancel`}),(0,f.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:h,children:h?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Adding & Syncing...`]}):`Add & Start Sync`})]})]})]})})]})}function h({refreshStats:e}){let[t,n]=(0,l.useState)([]),[r,i]=(0,l.useState)(!1),[a,o]=(0,l.useState)(!1),[s,c]=(0,l.useState)(``),[u,d]=(0,l.useState)(`local`),[p,m]=(0,l.useState)(``),[h,g]=(0,l.useState)(`directory`),[_,v]=(0,l.useState)(1),[y,b]=(0,l.useState)(null),x=async()=>{try{let e=await fetch(`/admin/api/paths`);if(!e.ok)return;let t=await e.json();n(t)}catch(e){console.error(`Error loading paths:`,e)}};(0,l.useEffect)(()=>{x();let e=setInterval(x,8e3);return()=>clearInterval(e)},[]);let ee=async t=>{t.preventDefault();try{let t=await fetch(`/admin/api/paths`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({path:s.trim(),repo:u.trim()||`local`,category:p.trim()||null,type:h,recursive:_,enabled:1})}),n=await t.json();if(!t.ok)throw Error(n.error||`Failed to add path`);i(!1),c(``),d(`local`),m(``),g(`directory`),v(1),x(),e()}catch(e){alert(`Error: ${e.message}`)}},S=async t=>{if(window.confirm(`Are you sure you want to delete this local search path?`))try{await fetch(`/admin/api/paths/${t}`,{method:`DELETE`}),x(),e()}catch(e){alert(`Failed to delete path: `+e.message)}},C=(e=`/`)=>{o(!0),te(e)},te=async e=>{try{let t=await fetch(`/admin/api/browse?path=${encodeURIComponent(e)}`),n=await t.json();if(!t.ok)return;b(n)}catch(e){console.error(`Browse error:`,e)}};return(0,f.jsxs)(`div`,{className:`tab-content active`,children:[(0,f.jsxs)(`div`,{className:`glass-card`,children:[(0,f.jsxs)(`div`,{className:`card-header-btn`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Monitored Local Paths`]}),(0,f.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Mounted documentation vaults and local workspaces scanned for changes.`})]}),(0,f.jsxs)(`button`,{className:`btn btn-primary`,onClick:()=>i(!0),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-plus`}),` Add Local Path`]})]}),(0,f.jsx)(`div`,{className:`table-container`,children:(0,f.jsxs)(`table`,{children:[(0,f.jsx)(`thead`,{children:(0,f.jsxs)(`tr`,{children:[(0,f.jsx)(`th`,{children:`Path`}),(0,f.jsx)(`th`,{children:`Repo Alias`}),(0,f.jsx)(`th`,{children:`Type`}),(0,f.jsx)(`th`,{children:`Recursive`}),(0,f.jsx)(`th`,{children:`Category`}),(0,f.jsx)(`th`,{children:`Enabled`}),(0,f.jsx)(`th`,{children:`Actions`})]})}),(0,f.jsx)(`tbody`,{children:t.length===0?(0,f.jsx)(`tr`,{children:(0,f.jsx)(`td`,{colSpan:7,className:`empty-state`,children:`No local search paths configured.`})}):t.map(e=>(0,f.jsxs)(`tr`,{children:[(0,f.jsx)(`td`,{children:(0,f.jsx)(`code`,{children:e.path})}),(0,f.jsx)(`td`,{children:(0,f.jsx)(`strong`,{children:e.repo||`local`})}),(0,f.jsx)(`td`,{children:(0,f.jsx)(`span`,{className:`badge badge-primary`,children:e.type})}),(0,f.jsx)(`td`,{children:e.recursive?`Yes`:`No`}),(0,f.jsx)(`td`,{children:e.category?(0,f.jsx)(`span`,{className:`badge badge-accent`,children:e.category}):(0,f.jsx)(`span`,{className:`text-muted`,children:`-`})}),(0,f.jsx)(`td`,{children:e.enabled?(0,f.jsx)(`span`,{className:`badge badge-success`,children:`Enabled`}):(0,f.jsx)(`span`,{className:`badge badge-danger`,children:`Disabled`})}),(0,f.jsx)(`td`,{children:(0,f.jsx)(`button`,{className:`btn-icon btn-delete`,onClick:()=>S(e.id),children:(0,f.jsx)(`i`,{className:`fa-solid fa-trash-can`})})})]},e.id))})]})})]}),r&&(0,f.jsx)(`div`,{className:`modal-backdrop`,children:(0,f.jsxs)(`div`,{className:`glass-card modal-card`,children:[(0,f.jsxs)(`div`,{className:`modal-header`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-folder-open`}),` Add Monitored Local Path`]}),(0,f.jsx)(`button`,{className:`btn-close`,onClick:()=>i(!1),children:`×`})]}),(0,f.jsxs)(`form`,{onSubmit:ee,children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{children:`Selected Directory / File`}),(0,f.jsxs)(`div`,{className:`path-input-row`,children:[(0,f.jsx)(`input`,{type:`text`,readOnly:!0,required:!0,placeholder:`Browse workspace directories...`,value:s}),(0,f.jsxs)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>C(y?.current_path||`/`),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Browse`]})]})]}),(0,f.jsxs)(`div`,{className:`form-row`,children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`path-repo-alias`,children:`Repo / Vault Alias`}),(0,f.jsx)(`input`,{type:`text`,id:`path-repo-alias`,placeholder:`local`,value:u,onChange:e=>d(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`path-category`,children:`Category Override`}),(0,f.jsx)(`input`,{type:`text`,id:`path-category`,placeholder:`Optional category`,value:p,onChange:e=>m(e.target.value)})]})]}),(0,f.jsxs)(`div`,{className:`form-row`,children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`path-type`,children:`Path Type`}),(0,f.jsxs)(`select`,{id:`path-type`,value:h,onChange:e=>g(e.target.value),children:[(0,f.jsx)(`option`,{value:`directory`,children:`Directory`}),(0,f.jsx)(`option`,{value:`file`,children:`Single File`})]})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`path-recursive`,children:`Scan Subfolders`}),(0,f.jsxs)(`select`,{id:`path-recursive`,value:_,onChange:e=>v(parseInt(e.target.value)),children:[(0,f.jsx)(`option`,{value:1,children:`Yes (Recursive)`}),(0,f.jsx)(`option`,{value:0,children:`No (Top-level only)`})]})]})]}),(0,f.jsxs)(`div`,{className:`modal-footer`,children:[(0,f.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>i(!1),children:`Cancel`}),(0,f.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,children:`Save Path`})]})]})]})}),a&&y&&(0,f.jsx)(`div`,{className:`modal-backdrop`,style:{zIndex:1100},children:(0,f.jsxs)(`div`,{className:`glass-card modal-card browser-card`,children:[(0,f.jsxs)(`div`,{className:`modal-header`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-search`}),` Browse Workspace Files`]}),(0,f.jsx)(`button`,{className:`btn-close`,onClick:()=>o(!1),children:`×`})]}),(0,f.jsxs)(`div`,{className:`browser-body`,children:[(0,f.jsxs)(`div`,{className:`browser-breadcrumbs`,children:[(0,f.jsx)(`span`,{className:`label`,children:`Current:`}),(0,f.jsx)(`span`,{className:`code`,children:y.current_path})]}),(0,f.jsx)(`div`,{className:`browser-list-container`,children:(0,f.jsxs)(`ul`,{className:`browser-list`,children:[y.parent_path&&(0,f.jsxs)(`li`,{className:`browser-item`,onClick:()=>te(y.parent_path),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-level-up-alt`,style:{color:`var(--accent)`}}),` `,(0,f.jsx)(`span`,{children:`.. (Parent Directory)`})]}),y.directories.map(e=>(0,f.jsxs)(`li`,{className:`browser-item`,onClick:()=>te(e.path),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-folder`,style:{color:`#fbbf24`}}),` `,(0,f.jsx)(`span`,{children:e.name})]},e.path)),y.files.map(e=>(0,f.jsxs)(`li`,{className:`browser-item`,onClick:()=>{c(e.path),g(`file`),o(!1)},children:[(0,f.jsx)(`i`,{className:`fa-solid fa-file-code`,style:{color:`var(--text-muted)`}}),` `,(0,f.jsx)(`span`,{children:e.name})]},e.path))]})})]}),(0,f.jsxs)(`div`,{className:`modal-footer`,children:[(0,f.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:()=>o(!1),children:`Cancel`}),(0,f.jsx)(`button`,{type:`button`,className:`btn btn-primary`,onClick:()=>{y&&(c(y.current_path),g(`directory`),o(!1))},children:`Select Current Folder`})]})]})})]})}function g(){let[e,t]=(0,l.useState)(``),[n,r]=(0,l.useState)(`code`),[i,a]=(0,l.useState)(``),[o,s]=(0,l.useState)(!1),[c,u]=(0,l.useState)(null),[d,p]=(0,l.useState)(null);return(0,f.jsx)(`div`,{className:`tab-content active`,children:(0,f.jsxs)(`div`,{className:`glass-card`,children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Live Hybrid Search Inspector`]}),(0,f.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Test RRF search results across code and documentation directly from the browser.`}),(0,f.jsx)(`form`,{onSubmit:async t=>{t.preventDefault(),s(!0),p(null),u(null);try{let t=await fetch(`/admin/api/search/test`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({query:e.trim(),type:n,repo:i.trim()||null})}),r=await t.json();if(!t.ok)throw Error(r.error||`Search failed`);u(r.results||[])}catch(e){p(e.message)}finally{s(!1)}},style:{marginTop:`16px`},children:(0,f.jsxs)(`div`,{className:`form-row`,children:[(0,f.jsxs)(`div`,{className:`form-group`,style:{flex:2},children:[(0,f.jsx)(`label`,{children:`Search Query`}),(0,f.jsx)(`input`,{type:`text`,required:!0,placeholder:`e.g. JWT token authentication or chunk_markdown`,value:e,onChange:e=>t(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{children:`Target Type`}),(0,f.jsxs)(`select`,{value:n,onChange:e=>r(e.target.value),children:[(0,f.jsx)(`option`,{value:`code`,children:`Code Snippets & Symbols`}),(0,f.jsx)(`option`,{value:`doc`,children:`Documentation & Notes`})]})]}),(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{children:`Repo Filter (Optional)`}),(0,f.jsx)(`input`,{type:`text`,placeholder:`All Repos`,value:i,onChange:e=>a(e.target.value)})]}),(0,f.jsx)(`div`,{className:`form-group`,style:{alignSelf:`flex-end`},children:(0,f.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,disabled:o,children:o?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-spinner fa-spin`}),` Searching...`]}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-play`}),` Search`]})})})]})}),(0,f.jsxs)(`div`,{style:{marginTop:`20px`},children:[o&&(0,f.jsx)(`div`,{className:`empty-state`,children:`Running hybrid retrieval with Reciprocal Rank Fusion (RRF)...`}),d&&(0,f.jsxs)(`div`,{className:`empty-state`,style:{color:`var(--danger)`},children:[`Search error: `,d]}),!o&&!d&&c===null&&(0,f.jsx)(`div`,{className:`empty-state`,children:`Enter a query above to test hybrid retrieval.`}),!o&&!d&&c!==null&&c.length===0&&(0,f.jsx)(`div`,{className:`empty-state`,children:`No matching results found in index.`}),!o&&!d&&c!==null&&c.length>0&&c.map((e,t)=>{let n=e.payload;return(0,f.jsxs)(`div`,{className:`search-hit-card`,children:[(0,f.jsxs)(`div`,{className:`search-hit-header`,children:[(0,f.jsxs)(`div`,{children:[(0,f.jsx)(`span`,{className:`badge badge-primary`,children:n.repo}),(0,f.jsx)(`strong`,{style:{marginLeft:`6px`},children:n.rel_path}),n.symbol&&(0,f.jsx)(`span`,{className:`badge badge-accent`,style:{marginLeft:`6px`},children:n.symbol}),(0,f.jsxs)(`span`,{className:`text-muted`,style:{fontSize:`0.8rem`,marginLeft:`6px`},children:[`(Lines `,n.start_line,`-`,n.end_line,`)`]}),n.github_url&&(0,f.jsxs)(`a`,{href:n.github_url,target:`_blank`,rel:`noreferrer`,style:{color:`var(--primary)`,fontSize:`0.8rem`,marginLeft:`8px`},children:[(0,f.jsx)(`i`,{className:`fa-solid fa-arrow-up-right-from-square`}),` View on GitHub`]})]}),(0,f.jsx)(`div`,{children:(0,f.jsxs)(`span`,{className:`badge badge-success`,children:[`RRF Score: `,e.score.toFixed(4)]})})]}),(0,f.jsx)(`pre`,{className:`search-hit-code`,children:n.content})]},t)})]})]})})}function _({stats:e,refreshStats:t}){let[n,r]=(0,l.useState)(``);return(0,f.jsx)(`div`,{className:`tab-content active`,children:(0,f.jsxs)(`div`,{className:`glass-card`,style:{maxWidth:`700px`},children:[(0,f.jsxs)(`h2`,{children:[(0,f.jsx)(`i`,{className:`fa-solid fa-key`}),` GitHub Authentication & Rate Limits`]}),(0,f.jsx)(`p`,{className:`text-muted`,style:{marginTop:`4px`,fontSize:`0.85rem`},children:`Providing a GitHub Personal Access Token increases API rate limits from 60 to 5,000 requests/hr and enables indexing private repositories.`}),(0,f.jsxs)(`div`,{className:`form-group`,style:{marginTop:`20px`},children:[(0,f.jsx)(`label`,{children:`Active Token Source`}),(0,f.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`10px`},children:[(0,f.jsx)(`span`,{className:`badge badge-accent`,children:e?.token_source||`None`}),(0,f.jsx)(`span`,{className:`code`,children:e?.masked_token||`None`})]})]}),(0,f.jsxs)(`form`,{onSubmit:async e=>{if(e.preventDefault(),n.trim())try{let e=await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({github_token:n.trim()})}),i=await e.json();if(!e.ok)throw Error(i.error||`Failed to save token`);alert(`GitHub Token saved successfully.`),r(``),t()}catch(e){alert(`Error saving token: `+e.message)}},style:{marginTop:`16px`},children:[(0,f.jsxs)(`div`,{className:`form-group`,children:[(0,f.jsx)(`label`,{htmlFor:`github-token-input`,children:`Update GitHub Token`}),(0,f.jsx)(`input`,{type:`password`,id:`github-token-input`,placeholder:`ghp_xxxxxxxxxxxxxxxxxxxx`,value:n,onChange:e=>r(e.target.value)})]}),(0,f.jsxs)(`div`,{className:`form-actions`,style:{display:`flex`,gap:`10px`,marginTop:`15px`},children:[(0,f.jsx)(`button`,{type:`submit`,className:`btn btn-primary`,children:`Save Token to DB`}),(0,f.jsx)(`button`,{type:`button`,className:`btn btn-secondary`,onClick:async()=>{if(window.confirm(`Clear the stored GitHub token from database?`))try{await fetch(`/admin/api/settings/token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({github_token:``})}),t()}catch(e){alert(`Failed to clear token: `+e.message)}},children:`Clear Token`})]})]})]})})}function v(){let[e,t]=(0,l.useState)(`overview`),[n,r]=(0,l.useState)(null),i=async()=>{try{let e=await fetch(`/admin/api/stats`);if(!e.ok)return;let t=await e.json();r(t)}catch(e){console.error(`Error loading stats:`,e)}};return(0,l.useEffect)(()=>{i();let e=setInterval(i,8e3);return()=>clearInterval(e)},[]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)(`div`,{className:`background-decor`,children:[(0,f.jsx)(`div`,{className:`circle circle-1`}),(0,f.jsx)(`div`,{className:`circle circle-2`})]}),(0,f.jsxs)(`div`,{className:`dashboard-container`,children:[(0,f.jsxs)(`header`,{className:`dashboard-header`,children:[(0,f.jsxs)(`div`,{className:`header-logo`,children:[(0,f.jsx)(`i`,{className:`fa-solid fa-layer-group logo-icon`}),(0,f.jsxs)(`div`,{className:`header-title`,children:[(0,f.jsx)(`h1`,{children:`Code & Docs RAG Server`}),(0,f.jsx)(`span`,{className:`badge badge-primary`,children:`v3.0.0 Hybrid`})]})]}),(0,f.jsxs)(`div`,{className:`header-status`,children:[(0,f.jsxs)(`div`,{className:`status-item`,children:[(0,f.jsx)(`span`,{className:`label`,children:`Engine State`}),(0,f.jsx)(`span`,{className:`value`,children:n?.is_indexing?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`span`,{className:`indicator indexing`}),` Syncing...`]}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`span`,{className:`indicator online`}),` Idle`]})})]}),(0,f.jsxs)(`div`,{className:`status-item`,children:[(0,f.jsx)(`span`,{className:`label`,children:`GitHub API`}),(0,f.jsxs)(`span`,{className:`value`,children:[(0,f.jsx)(`i`,{className:`fa-brands fa-github`}),(0,f.jsx)(`span`,{children:n?.rate_limit?`${n.rate_limit.remaining.toLocaleString()} / ${n.rate_limit.limit.toLocaleString()} reqs`:`Checking...`})]})]}),(0,f.jsxs)(`div`,{className:`status-item`,children:[(0,f.jsx)(`span`,{className:`label`,children:`Collection`}),(0,f.jsx)(`span`,{className:`value code`,children:`notes_rag_v2`})]})]})]}),(0,f.jsxs)(`nav`,{className:`dashboard-nav`,children:[(0,f.jsxs)(`button`,{className:`nav-tab ${e===`overview`?`active`:``}`,onClick:()=>t(`overview`),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-chart-pie`}),` Overview`]}),(0,f.jsxs)(`button`,{className:`nav-tab ${e===`git-repos`?`active`:``}`,onClick:()=>t(`git-repos`),children:[(0,f.jsx)(`i`,{className:`fa-brands fa-github`}),` Git Repositories`]}),(0,f.jsxs)(`button`,{className:`nav-tab ${e===`local-paths`?`active`:``}`,onClick:()=>t(`local-paths`),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-folder-tree`}),` Local Paths`]}),(0,f.jsxs)(`button`,{className:`nav-tab ${e===`search-inspector`?`active`:``}`,onClick:()=>t(`search-inspector`),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-magnifying-glass`}),` Search & Inspector`]}),(0,f.jsxs)(`button`,{className:`nav-tab ${e===`settings`?`active`:``}`,onClick:()=>t(`settings`),children:[(0,f.jsx)(`i`,{className:`fa-solid fa-gear`}),` Settings`]})]}),(0,f.jsxs)(`main`,{className:`dashboard-main`,children:[e===`overview`&&(0,f.jsx)(p,{stats:n,refreshStats:i}),e===`git-repos`&&(0,f.jsx)(m,{refreshStats:i}),e===`local-paths`&&(0,f.jsx)(h,{refreshStats:i}),e===`search-inspector`&&(0,f.jsx)(g,{}),e===`settings`&&(0,f.jsx)(_,{stats:n,refreshStats:i})]}),(0,f.jsx)(`footer`,{className:`dashboard-footer`,children:(0,f.jsx)(`p`,{children:`Notes & Code RAG MCP • High Precision Tree-sitter & Hybrid Qdrant • 2026`})})]})]})}(0,u.createRoot)(document.getElementById(`root`)).render((0,f.jsx)(l.StrictMode,{children:(0,f.jsx)(v,{})})); \ No newline at end of file diff --git a/www/assets/info-A6RAGUB7-CjXYSfue.js b/www/assets/info-A6RAGUB7-CjXYSfue.js new file mode 100644 index 0000000..6288cd6 --- /dev/null +++ b/www/assets/info-A6RAGUB7-CjXYSfue.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{w as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createInfoServices}; \ No newline at end of file diff --git a/www/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js b/www/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js new file mode 100644 index 0000000..deda7c9 --- /dev/null +++ b/www/assets/infoDiagram-VRGFBTTK-B6TQ-HH9.js @@ -0,0 +1,2 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{c as n}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{y as r}from"./index-DoQkmpth.js";import{n as i}from"./mermaid-parser.core-CUrDj5TF.js";var a={parse:t(async t=>{let n=await i(`info`,t);e.debug(n)},`parse`)},o={version:`12.0.0`},s={parser:a,db:{getVersion:t(()=>o.version,`getVersion`)},renderer:{draw:t((t,i,a)=>{e.debug(`rendering info diagram +`+t);let o=r(i);n(o,100,400,!0),o.append(`g`).append(`text`).attr(`x`,100).attr(`y`,40).attr(`class`,`version`).attr(`font-size`,32).style(`text-anchor`,`middle`).text(`v${a}`)},`draw`)}};export{s as diagram}; \ No newline at end of file diff --git a/www/assets/init-C-OQMol4.js b/www/assets/init-C-OQMol4.js new file mode 100644 index 0000000..8aff9b3 --- /dev/null +++ b/www/assets/init-C-OQMol4.js @@ -0,0 +1 @@ +function e(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}export{e as t}; \ No newline at end of file diff --git a/www/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js b/www/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js new file mode 100644 index 0000000..7266900 --- /dev/null +++ b/www/assets/ishikawaDiagram-OU5B5YK6-BuTYOHFo.js @@ -0,0 +1,70 @@ +import"./src-D_iIdUkB.js";import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as t,U as n,a as r,c as i,q as a,s as o,v as s,w as c,x as l,y as u}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{p as d}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as f}from"./rough.esm-Dy-Kn_BL.js";import{y as p}from"./index-DoQkmpth.js";var m=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,14],i=[1,12],a=[1,13],o=[6,7,8],s=[1,20],c=[1,18],l=[1,19],u=[6,7,11],d=[1,6,13,14],f=[1,23],p=[1,24],m=[1,6,7,11,13,14],h={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,ishikawa:4,spaceLines:5,SPACELINE:6,NL:7,ISHIKAWA:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,TEXT:14,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`ISHIKAWA`,11:`EOF`,13:`SPACELIST`,14:`TEXT`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,1],[12,1],[12,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 15:r.addNode(a[s-1].length,a[s].trim());break;case 16:r.addNode(0,a[s].trim())}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:a},t(o,[2,3]),{1:[2,2]},t(o,[2,4]),t(o,[2,5]),{1:[2,6],6:r,12:15,13:i,14:a},{6:r,9:16,12:11,13:i,14:a},{6:s,7:c,10:17,11:l},t(u,[2,18],{14:[1,21]}),t(u,[2,16]),t(u,[2,17]),{6:s,7:c,10:22,11:l},{1:[2,7],6:r,12:15,13:i,14:a},t(d,[2,14],{7:f,11:p}),t(m,[2,8]),t(m,[2,9]),t(m,[2,10]),t(u,[2,15]),t(d,[2,13],{7:f,11:p}),t(m,[2,11]),t(m,[2,12])],defaultActions:{2:[2,1],6:[2,2]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};h.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return 6;case 1:return 8;case 2:return 8;case 3:return 6;case 4:return 7;case 5:return 13;case 6:return 14;case 7:return 11}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:ishikawa-beta\b)/i,/^(?:ishikawa\b)/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:[^\n]+)/i,/^(?:$)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7],inclusive:!0}}}})();function g(){this.yy={}}return e(g,`Parser`),g.prototype=h,h.Parser=g,new g})();m.parser=m;var h=m,g=class{constructor(){this.stack=[],this.clear=this.clear.bind(this),this.addNode=this.addNode.bind(this),this.getRoot=this.getRoot.bind(this)}static{e(this,`IshikawaDB`)}clear(){this.root=void 0,this.stack=[],this.baseLevel=void 0,r()}getRoot(){return this.root}addNode(e,t){let n=o.sanitizeText(t,l());if(!this.root){this.root={text:n,children:[]},this.stack=[{level:0,node:this.root}],a(n);return}this.baseLevel??=e;let r=e-this.baseLevel+1;for(r<=0&&(r=1);this.stack.length>1&&this.stack[this.stack.length-1].level>=r;)this.stack.pop();let i=this.stack[this.stack.length-1].node,s={text:n,children:[]};i.children.push(s),this.stack.push({level:r,node:s})}getAccTitle(){return u()}setAccTitle(e){n(e)}getAccDescription(){return s()}setAccDescription(e){t(e)}getDiagramTitle(){return c()}setDiagramTitle(e){a(e)}},_=14,v=250,y=30,b=60,x=5,S=82*Math.PI/180,C=Math.cos(S),w=Math.sin(S),T=e((e,t,n)=>{let r=e.node().getBBox(),a=r.width+t*2,o=r.height+t*2;i(e,o,a,n),e.attr(`viewBox`,`${r.x-t} ${r.y-t} ${a} ${o}`)},`applyPaddedViewBox`),E=e((e,t,n,r)=>{let i=r.db.getRoot();if(!i)return;let a=l(),{look:o,handDrawnSeed:s,themeVariables:c}=a,u=d(a.fontSize)[0]??_,m=o===`handDrawn`,h=i.children??[],g=a.ishikawa?.diagramPadding??20,y=a.ishikawa?.useMaxWidth??!1,b=p(t),x=b.append(`g`).attr(`class`,`ishikawa`),S=m?f.svg(b.node()):void 0,C=S?{roughSvg:S,seed:s??0,lineColor:c?.lineColor??`#333`,fillColor:c?.mainBkg??`#fff`}:void 0,w=`ishikawa-arrow-${t}`;m||x.append(`defs`).append(`marker`).attr(`id`,w).attr(`viewBox`,`0 0 10 10`).attr(`refX`,0).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 Z`).attr(`class`,`ishikawa-arrow`);let E=0,k=v,A=m?void 0:L(x,E,k,E,k,`ishikawa-spine`);if(O(x,E,k,i.text,u,C),!h.length){m&&L(x,E,k,E,k,`ishikawa-spine`,C),T(b,g,y);return}E-=20;let j=h.filter((e,t)=>t%2==0),N=h.filter((e,t)=>t%2==1),P=D(j),F=D(N),I=P.total+F.total,R=v,z=v;if(I>0){let e=v*2,t=v*.3;R=Math.max(t,e*(P.total/I)),z=Math.max(t,e*(F.total/I))}let B=u*2;R=Math.max(R,P.max*B),z=Math.max(z,F.max*B),k=Math.max(R,v),A&&A.attr(`y1`,k).attr(`y2`,k),x.select(`.ishikawa-head-group`).attr(`transform`,`translate(0,${k})`);let V=Math.ceil(h.length/2);for(let e=0;eMath.min(e,t.getBBox().x),1/0)}if(m)L(x,E,k,0,k,`ishikawa-spine`,C);else{A.attr(`x1`,E);let e=`url(#${w})`;x.selectAll(`line.ishikawa-branch, line.ishikawa-sub-branch`).attr(`marker-start`,e)}T(b,g,y)},`draw`),D=e(t=>{let n=e(e=>e.children.reduce((e,t)=>e+1+n(t),0),`countDescendants`);return t.reduce((e,t)=>{let r=n(t);return e.total+=r,e.max=Math.max(e.max,r),e},{total:0,max:0})},`sideStats`),O=e((e,t,n,r,i,a)=>{let o=Math.max(6,Math.floor(110/(i*.6))),s=e.append(`g`).attr(`class`,`ishikawa-head-group`).attr(`transform`,`translate(${t},${n})`),c=F(s,P(r,o),0,0,`ishikawa-head-label`,`start`,i),l=c.node().getBBox(),u=Math.max(60,l.width+6),d=Math.max(40,l.height*2+40),f=`M 0 ${-d/2} L 0 ${d/2} Q ${u*2.4} 0 0 ${-d/2} Z`;if(a){let e=a.roughSvg.path(f,{roughness:1.5,seed:a.seed,fill:a.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:a.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-head`)}else s.insert(`path`,`:first-child`).attr(`class`,`ishikawa-head`).attr(`d`,f);c.attr(`transform`,`translate(${(u-l.width)/2-l.x+3},${-l.y-l.height/2})`)},`drawHead`),k=e((t,n)=>{let r=[],i=[],a=e((e,t,o)=>{let s=n===-1?[...e].reverse():e;for(let e of s){let n=r.length,s=e.children??[];r.push({depth:o,text:P(e.text,15),parentIndex:t,childCount:s.length}),o%2==0?(i.push(n),s.length&&a(s,n,o+1)):(s.length&&a(s,n,o+1),i.push(n))}},`walk`);return a(t,-1,2),{entries:r,yOrder:i}},`flattenTree`),A=e((e,t,n,r,i,a,o)=>{let s=e.append(`g`).attr(`class`,`ishikawa-label-group`),c=F(s,t,n,r+11*i,`ishikawa-label cause`,`middle`,a).node().getBBox();if(o){let e=o.roughSvg.rectangle(c.x-20,c.y-2,c.width+40,c.height+4,{roughness:1.5,seed:o.seed,fill:o.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:o.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-label-box`)}else s.insert(`rect`,`:first-child`).attr(`class`,`ishikawa-label-box`).attr(`x`,c.x-20).attr(`y`,c.y-2).attr(`width`,c.width+40).attr(`height`,c.height+4)},`drawCauseLabel`),j=e((e,t,n,r,i,a)=>{let o=Math.sqrt(r*r+i*i);if(o===0)return;let s=r/o,c=i/o,l=-c*6,u=s*6,d=t,f=n,p=`M ${d} ${f} L ${d-s*6*2+l} ${f-c*6*2+u} L ${d-s*6*2-l} ${f-c*6*2-u} Z`,m=a.roughSvg.path(p,{roughness:1,seed:a.seed,fill:a.lineColor,fillStyle:`solid`,stroke:a.lineColor,strokeWidth:1});e.append(()=>m)},`drawArrowMarker`),M=e((e,t,n,r,i,a,o,s)=>{let c=t.children??[],l=a*(c.length?1:.2),u=-C*l,d=w*l*i,f=n+u,p=r+d;if(L(e,n,r,f,p,`ishikawa-branch`,s),s&&j(e,n,r,n-f,r-p,s),A(e,t.text,f,p,i,o,s),!c.length)return;let{entries:m,yOrder:h}=k(c,i),g=m.length,_=Array(g);for(let[e,t]of h.entries())_[t]=r+d*((e+1)/(g+1));let v=new Map;v.set(-1,{x0:n,y0:r,x1:f,y1:p,childCount:c.length,childrenDrawn:0});let S=-C,T=w*i,E=i<0?`ishikawa-label up`:`ishikawa-label down`;for(let[t,n]of m.entries()){let r=_[t],i=v.get(n.parentIndex),a=e.append(`g`).attr(`class`,`ishikawa-sub-group`),c=0,l=0,u=0;if(n.depth%2==0){let e=i.y1-i.y0;c=I(i.x0,i.x1,e?(r-i.y0)/e:.5),l=r,u=c-(n.childCount>0?b+n.childCount*x:y),L(a,c,r,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,r,1,0,s),F(a,n.text,u,r,`ishikawa-label align`,`end`,o)}else{let e=i.childrenDrawn++;c=I(i.x0,i.x1,(i.childCount-e)/(i.childCount+1)),l=i.y0,u=c+S*((r-l)/T),L(a,c,l,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,l,c-u,l-r,s),F(a,n.text,u,r,E,`end`,o)}n.childCount>0&&v.set(t,{x0:c,y0:l,x1:u,y1:r,childCount:n.childCount,childrenDrawn:0})}},`drawBranch`),N=e(e=>e.split(/|\n/),`splitLines`),P=e((e,t)=>{if(e.length<=t)return e;let n=[];for(let r of e.split(/\s+/)){let e=n.length-1;e>=0&&n[e].length+1+r.length<=t?n[e]+=` `+r:n.push(r)}return n.join(` +`)},`wrapText`),F=e((e,t,n,r,i,a,o)=>{let s=N(t),c=o*1.05,l=e.append(`text`).attr(`class`,i).attr(`text-anchor`,a).attr(`x`,n).attr(`y`,r-(s.length-1)*c/2);for(let[e,t]of s.entries())l.append(`tspan`).attr(`x`,n).attr(`dy`,e===0?0:c).text(t);return l},`drawMultilineText`),I=e((e,t,n)=>e+(t-e)*n,`lerp`),L=e((e,t,n,r,i,a,o)=>{if(o){let s=o.roughSvg.line(t,n,r,i,{roughness:1.5,seed:o.seed,stroke:o.lineColor,strokeWidth:2});e.append(()=>s).attr(`class`,a);return}return e.append(`line`).attr(`class`,a).attr(`x1`,t).attr(`y1`,n).attr(`x2`,r).attr(`y2`,i)},`drawLine`),R={parser:h,get db(){return new g},renderer:{draw:E},styles:e(e=>` +.ishikawa .ishikawa-spine, +.ishikawa .ishikawa-branch, +.ishikawa .ishikawa-sub-branch { + stroke: ${e.lineColor}; + stroke-width: 2; + fill: none; +} + +.ishikawa .ishikawa-sub-branch { + stroke-width: 1; +} + +.ishikawa .ishikawa-arrow { + fill: ${e.lineColor}; +} + +.ishikawa .ishikawa-head { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + stroke-width: 2; +} + +.ishikawa .ishikawa-label-box { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + stroke-width: 2; +} + +.ishikawa text { + font-family: ${e.fontFamily}; + font-size: ${e.fontSize}; + fill: ${e.textColor}; +} + +.ishikawa .ishikawa-head-label { + font-weight: 600; + text-anchor: middle; + dominant-baseline: middle; + font-size: 14px; +} + +.ishikawa .ishikawa-label { + text-anchor: end; +} + +.ishikawa .ishikawa-label.cause { + text-anchor: middle; + dominant-baseline: middle; +} + +.ishikawa .ishikawa-label.align { + text-anchor: end; + dominant-baseline: middle; +} + +.ishikawa .ishikawa-label.up { + dominant-baseline: baseline; +} + +.ishikawa .ishikawa-label.down { + dominant-baseline: hanging; +} +`,`getStyles`)};export{R as diagram}; \ No newline at end of file diff --git a/www/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js b/www/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js new file mode 100644 index 0000000..212ca98 --- /dev/null +++ b/www/assets/journeyDiagram-ZHPQQLJL-Bik9qTx9.js @@ -0,0 +1,139 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,c as a,q as o,v as s,w as c,x as l,y as u}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as d}from"./arc-BJA87daU.js";import{t as f}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{a as p,n as m,o as h,s as g}from"./chunk-GWA4HPMP-C1P4FmAY.js";var _=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[6,8,10,11,12,14,16,17,18],r=[1,9],i=[1,10],a=[1,11],o=[1,12],s=[1,13],c=[1,14],l={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,journey:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,title:11,acc_title:12,acc_title_value:13,acc_descr:14,acc_descr_value:15,acc_descr_multiline_value:16,section:17,taskName:18,taskData:19,$accept:0,$end:1},terminals_:{2:`error`,4:`journey`,6:`EOF`,8:`SPACE`,10:`NEWLINE`,11:`title`,12:`acc_title`,13:`acc_title_value`,14:`acc_descr`,15:`acc_descr_value`,16:`acc_descr_multiline_value`,17:`section`,18:`taskName`,19:`taskData`},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,2]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:case 7:this.$=[];break;case 8:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 9:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 10:case 11:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 12:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 13:r.addTask(a[s-1],a[s]),this.$=`task`}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,7],{1:[2,1]}),e(n,[2,3]),{9:15,11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,5]),e(n,[2,6]),e(n,[2,8]),{13:[1,16]},{15:[1,17]},e(n,[2,11]),e(n,[2,12]),{19:[1,18]},e(n,[2,4]),e(n,[2,9]),e(n,[2,10]),e(n,[2,13])],defaultActions:{},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};l.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 10;case 3:break;case 4:break;case 5:return 4;case 6:return 11;case 7:return this.begin(`acc_title`),12;case 8:return this.popState(),`acc_title_value`;case 9:return this.begin(`acc_descr`),14;case 10:return this.popState(),`acc_descr_value`;case 11:this.begin(`acc_descr_multiline`);break;case 12:this.popState();break;case 13:return`acc_descr_multiline_value`;case 14:return 17;case 15:return 18;case 16:return 19;case 17:return`:`;case 18:return 6;case 19:return`INVALID`}},`anonymous`),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:journey\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,9,11,14,15,16,17,18,19],inclusive:!0}}}})();function u(){this.yy={}}return t(u,`Parser`),u.prototype=l,l.Parser=u,new u})();_.parser=_;var v=_,y=``,b=[],x=[],S=[],C=t(function(){b.length=0,x.length=0,y=``,S.length=0,i()},`clear`),w=t(function(e){y=e,b.push(e)},`addSection`),T=t(function(){return b},`getSections`),E=t(function(){let e=A(),t=0;for(;!e&&t<100;)e=A(),t++;return x.push(...S),x},`getTasks`),D=t(function(){let e=[];return x.forEach(t=>{t.people&&e.push(...t.people)}),[...new Set(e)].sort()},`updateActors`),O=t(function(e,t){let n=t.substr(1).split(`:`),r=0,i=[];n.length===1?(r=Number(n[0]),i=[]):(r=Number(n[0]),i=n[1].split(`,`));let a=i.map(e=>e.trim()),o={section:y,type:y,people:a,task:e,score:r};S.push(o)},`addTask`),k=t(function(e){let t={section:y,type:y,description:e,task:e,classes:[]};x.push(t)},`addTaskOrg`),A=t(function(){let e=t(function(e){return S[e].processed},`compileTask`),n=!0;for(let[t,r]of S.entries())e(t),n&&=r.processed;return n},`compileTasks`),j={getConfig:t(()=>l().journey,`getConfig`),clear:C,setDiagramTitle:o,getDiagramTitle:c,setAccTitle:r,getAccTitle:u,setAccDescription:n,getAccDescription:s,addSection:w,getSections:T,getTasks:E,addTask:O,addTaskOrg:k,getActors:t(function(){return D()},`getActors`)},M=t(e=>`.label { + font-family: ${e.fontFamily}; + color: ${e.textColor}; + } + .mouth { + stroke: #666; + } + + line { + stroke: ${e.textColor} + } + + .legend { + fill: ${e.textColor}; + font-family: ${e.fontFamily}; + } + + .label text { + fill: #333; + } + .label { + color: ${e.textColor} + } + + .face { + ${e.faceColor?`fill: ${e.faceColor}`:`fill: #FFF8DC`}; + stroke: #999; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: 1px; + } + + .node .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePaths .path { + stroke: ${e.lineColor}; + stroke-width: 1.5px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + rect { + opacity: 0.5; + } + text-align: center; + } + + .cluster rect { + } + + .cluster text { + fill: ${e.titleColor}; + } + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .task-type-0, .section-type-0 { + ${e.fillType0?`fill: ${e.fillType0}`:``}; + } + .task-type-1, .section-type-1 { + ${e.fillType0?`fill: ${e.fillType1}`:``}; + } + .task-type-2, .section-type-2 { + ${e.fillType0?`fill: ${e.fillType2}`:``}; + } + .task-type-3, .section-type-3 { + ${e.fillType0?`fill: ${e.fillType3}`:``}; + } + .task-type-4, .section-type-4 { + ${e.fillType0?`fill: ${e.fillType4}`:``}; + } + .task-type-5, .section-type-5 { + ${e.fillType0?`fill: ${e.fillType5}`:``}; + } + .task-type-6, .section-type-6 { + ${e.fillType0?`fill: ${e.fillType6}`:``}; + } + .task-type-7, .section-type-7 { + ${e.fillType0?`fill: ${e.fillType7}`:``}; + } + + .actor-0 { + ${e.actor0?`fill: ${e.actor0}`:``}; + } + .actor-1 { + ${e.actor1?`fill: ${e.actor1}`:``}; + } + .actor-2 { + ${e.actor2?`fill: ${e.actor2}`:``}; + } + .actor-3 { + ${e.actor3?`fill: ${e.actor3}`:``}; + } + .actor-4 { + ${e.actor4?`fill: ${e.actor4}`:``}; + } + .actor-5 { + ${e.actor5?`fill: ${e.actor5}`:``}; + } + ${f()} +`,`getStyles`),N=t(function(e,t){return p(e,t)},`drawRect`),P=t(function(e,n){let r=e.append(`circle`).attr(`cx`,n.cx).attr(`cy`,n.cy).attr(`class`,`face`).attr(`r`,15).attr(`stroke-width`,2).attr(`overflow`,`visible`),i=e.append(`g`);i.append(`circle`).attr(`cx`,n.cx-5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`),i.append(`circle`).attr(`cx`,n.cx+5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`);function a(e){let t=d().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+2)+`)`)}t(a,`smile`);function o(e){let t=d().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+7)+`)`)}t(o,`sad`);function s(e){e.append(`line`).attr(`class`,`mouth`).attr(`stroke`,2).attr(`x1`,n.cx-5).attr(`y1`,n.cy+7).attr(`x2`,n.cx+5).attr(`y2`,n.cy+7).attr(`class`,`mouth`).attr(`stroke-width`,`1px`).attr(`stroke`,`#666`)}return t(s,`ambivalent`),n.score>3?a(i):n.score<3?o(i):s(i),r},`drawFace`),F=t(function(e,t){let n=e.append(`circle`);return n.attr(`cx`,t.cx),n.attr(`cy`,t.cy),n.attr(`class`,`actor-`+t.pos),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`r`,t.r),n.class!==void 0&&n.attr(`class`,n.class),t.title!==void 0&&n.append(`title`).text(t.title),n},`drawCircle`),I=t(function(e,t){return h(e,t)},`drawText`),L=t(function(e,n){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}t(r,`genPoints`);let i=e.append(`polygon`);i.attr(`points`,r(n.x,n.y,50,20,7)),i.attr(`class`,`labelBox`),n.y+=n.labelMargin,n.x+=.5*n.labelMargin,I(e,n)},`drawLabel`),R=t(function(e,t,n){let r=e.append(`g`),i=g();i.x=t.x,i.y=t.y,i.fill=t.fill,i.width=n.width*t.taskCount+n.diagramMarginX*(t.taskCount-1),i.height=n.height,i.class=`journey-section section-type-`+t.num,i.rx=3,i.ry=3,N(r,i),H(n)(t.text,r,i.x,i.y,i.width,i.height,{class:`journey-section section-type-`+t.num},n,t.colour)},`drawSection`),z=-1,B=t(function(e,t,n,r){let i=t.x+n.width/2,a=e.append(`g`);z++,a.append(`line`).attr(`id`,r+`-task`+z).attr(`x1`,i).attr(`y1`,t.y).attr(`x2`,i).attr(`y2`,450).attr(`class`,`task-line`).attr(`stroke-width`,`1px`).attr(`stroke-dasharray`,`4 2`).attr(`stroke`,`#666`),P(a,{cx:i,cy:300+(5-t.score)*30,score:t.score});let o=g();o.x=t.x,o.y=t.y,o.fill=t.fill,o.width=n.width,o.height=n.height,o.class=`task task-type-`+t.num,o.rx=3,o.ry=3,N(a,o);let s=t.x+14;t.people.forEach(e=>{let n=t.actors[e].color,r={cx:s,cy:t.y,r:7,fill:n,stroke:`#000`,title:e,pos:t.actors[e].position};F(a,r),s+=10}),H(n)(t.task,a,o.x,o.y,o.width,o.height,{class:`task`},n,t.colour)},`drawTask`),V=t(function(e,t){m(e,t)},`drawBackgroundRect`),H=(function(){function e(e,t,n,r,a,o,s,c){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`font-color`,c).style(`text-anchor`,`middle`).text(e),s)}t(e,`byText`);function n(e,t,n,r,a,o,s,c,l){let{taskFontSize:u,taskFontFamily:d}=c,f=e.split(//gi);for(let e=0;e{let a=G[i].color,o={cx:20,cy:r,r:7,fill:a,stroke:`#000`,pos:G[i].position};U.drawCircle(e,o);let s=e.append(`text`).attr(`visibility`,`hidden`).text(i),c=s.node().getBoundingClientRect().width;s.remove();let l=[];if(c<=n)l=[i];else{let t=i.split(` `),r=``;s=e.append(`text`).attr(`visibility`,`hidden`),t.forEach(e=>{let t=r?`${r} ${e}`:e;if(s.text(t),s.node().getBoundingClientRect().width>n){if(r&&l.push(r),r=e,s.text(e),s.node().getBoundingClientRect().width>n){let t=``;for(let r of e)t+=r,s.text(t+`-`),s.node().getBoundingClientRect().width>n&&(l.push(t.slice(0,-1)+`-`),t=r);r=t}}else r=t}),r&&l.push(r),s.remove()}l.forEach((n,i)=>{let a={x:40,y:r+7+i*20,fill:`#666`,text:n,textMargin:t.boxTextMargin??5},o=U.drawText(e,a).node().getBoundingClientRect().width;o>K&&o>t.leftMargin-o&&(K=o)}),r+=Math.max(20,l.length*20)})}t(q,`drawActorLegend`);var J=l().journey,Y=0,ee=t(function(t,n,r,i){let o=l(),s=o.journey.titleColor,c=o.journey.titleFontSize,u=o.journey.titleFontFamily,d=o.securityLevel,f;d===`sandbox`&&(f=e(`#i`+n));let p=e(d===`sandbox`?f.nodes()[0].contentDocument.body:`body`);X.init();let m=p.select(`#`+n);U.initGraphics(m,n);let h=i.db.getTasks(),g=i.db.getDiagramTitle(),_=i.db.getActors();for(let e in G)delete G[e];let v=0;_.forEach(e=>{G[e]={color:J.actorColours[v%J.actorColours.length],position:v},v++}),q(m),Y=J.leftMargin+K,X.insert(0,0,Y,Object.keys(G).length*50),te(m,h,0,n);let y=X.getBounds();g&&m.append(`text`).text(g).attr(`x`,Y).attr(`font-size`,c).attr(`font-weight`,`bold`).attr(`y`,25).attr(`fill`,s).attr(`font-family`,u);let b=y.stopy-y.starty+2*J.diagramMarginY,x=Y+y.stopx+2*J.diagramMarginX;a(m,b,x,J.useMaxWidth),m.append(`line`).attr(`x1`,Y).attr(`y1`,J.height*4).attr(`x2`,x-Y-4).attr(`y2`,J.height*4).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#`+n+`-arrowhead)`);let S=g?70:0;m.attr(`viewBox`,`${y.startx} -25 ${x} ${b+S}`),m.attr(`preserveAspectRatio`,`xMinYMin meet`),m.attr(`height`,b+S+25)},`draw`),X={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],init:t(function(){this.sequenceItems=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0},`init`),updateVal:t(function(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])},`updateVal`),updateBounds:t(function(e,n,r,i){let a=l().journey,o=this,s=0;function c(c){return t(function(t){s++;let l=o.sequenceItems.length-s+1;o.updateVal(t,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(t,`stopy`,i+l*a.boxMargin,Math.max),o.updateVal(X.data,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopx`,r+l*a.boxMargin,Math.max),c!==`activation`&&(o.updateVal(t,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(t,`stopx`,r+l*a.boxMargin,Math.max),o.updateVal(X.data,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopy`,i+l*a.boxMargin,Math.max))},`updateItemBounds`)}t(c,`updateFn`),this.sequenceItems.forEach(c())},`updateBounds`),insert:t(function(e,t,n,r){let i=Math.min(e,n),a=Math.max(e,n),o=Math.min(t,r),s=Math.max(t,r);this.updateVal(X.data,`startx`,i,Math.min),this.updateVal(X.data,`starty`,o,Math.min),this.updateVal(X.data,`stopx`,a,Math.max),this.updateVal(X.data,`stopy`,s,Math.max),this.updateBounds(i,o,a,s)},`insert`),bumpVerticalPos:t(function(e){this.verticalPos+=e,this.data.stopy=this.verticalPos},`bumpVerticalPos`),getVerticalPos:t(function(){return this.verticalPos},`getVerticalPos`),getBounds:t(function(){return this.data},`getBounds`)},Z=J.sectionFills,Q=J.sectionColours,te=t(function(e,t,n,r){let i=l().journey,a=``,o=n+(i.height*2+i.diagramMarginY),s=0,c=`#CCC`,u=`black`,d=0;for(let[n,l]of t.entries()){if(a!==l.section){c=Z[s%Z.length],d=s%Z.length,u=Q[s%Q.length];let r=0,o=l.section;for(let e=n;e(G[t]&&(e[t]=G[t]),e),{});l.x=n*i.taskMargin+n*i.width+Y,l.y=o,l.width=i.diagramMarginX,l.height=i.diagramMarginY,l.colour=u,l.fill=c,l.num=d,l.actors=f,U.drawTask(e,l,i,r),X.insert(l.x,l.y,l.x+l.width+i.taskMargin,450)}},`drawTasks`),$={setConf:W,draw:ee},ne={parser:v,db:j,renderer:$,styles:M,init:t(e=>{$.setConf(e.journey),j.clear()},`init`)};export{ne as diagram}; \ No newline at end of file diff --git a/www/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js b/www/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js new file mode 100644 index 0000000..73d999c --- /dev/null +++ b/www/assets/kanban-definition-PNTS6WVX-BAMaaT6d.js @@ -0,0 +1,89 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{Y as n,at as r,f as i,nt as a,rt as o,x as s,z as c}from"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import{i as l,r as u}from"./chunk-5DYCD2WN-WToj2Jza.js";import{_ as d,h as f,v as p,y as m}from"./index-DoQkmpth.js";import{t as h}from"./chunk-5VM5RSS4-ZNzvKenW.js";var g=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,13],i=[1,12],a=[1,15],o=[1,16],s=[1,20],c=[1,19],l=[6,7,8],u=[1,26],d=[1,24],f=[1,25],p=[6,7,11],m=[1,31],h=[6,7,11,24],g=[1,6,13,16,17,20,23],_=[1,35],v=[1,36],y=[1,6,7,11,13,16,17,20,23],b=[1,38],x={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`KANBAN`,11:`EOF`,13:`SPACELIST`,16:`ICON`,17:`CLASS`,20:`NODE_DSTART`,21:`NODE_DESCR`,22:`NODE_DEND`,23:`NODE_ID`,24:`SHAPE_DATA`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace(`Stop NL `);break;case 9:r.getLogger().trace(`Stop EOF `);break;case 11:r.getLogger().trace(`Stop NL2 `);break;case 12:r.getLogger().trace(`Stop EOF2 `);break;case 15:r.getLogger().info(`Node: `,a[s-1].id),r.addNode(a[s-2].length,a[s-1].id,a[s-1].descr,a[s-1].type,a[s]);break;case 16:r.getLogger().info(`Node: `,a[s].id),r.addNode(a[s-1].length,a[s].id,a[s].descr,a[s].type);break;case 17:r.getLogger().trace(`Icon: `,a[s]),r.decorateNode({icon:a[s]});break;case 18:case 23:r.decorateNode({class:a[s]});break;case 19:r.getLogger().trace(`SPACELIST`);break;case 20:r.getLogger().trace(`Node: `,a[s-1].id),r.addNode(0,a[s-1].id,a[s-1].descr,a[s-1].type,a[s]);break;case 21:r.getLogger().trace(`Node: `,a[s].id),r.addNode(0,a[s].id,a[s].descr,a[s].type);break;case 22:r.decorateNode({icon:a[s]});break;case 27:r.getLogger().trace(`node found ..`,a[s-2]),this.$={id:a[s-1],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 28:this.$={id:a[s],descr:a[s],type:0};break;case 29:r.getLogger().trace(`node found ..`,a[s-3]),this.$={id:a[s-3],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 30:this.$=a[s-1]+a[s];break;case 31:this.$=a[s]}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},e(l,[2,3]),{1:[2,2]},e(l,[2,4]),e(l,[2,5]),{1:[2,6],6:r,12:21,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},{6:r,9:22,12:11,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},{6:u,7:d,10:23,11:f},e(p,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:s,23:c}),e(p,[2,19]),e(p,[2,21],{15:30,24:m}),e(p,[2,22]),e(p,[2,23]),e(h,[2,25]),e(h,[2,26]),e(h,[2,28],{20:[1,32]}),{21:[1,33]},{6:u,7:d,10:34,11:f},{1:[2,7],6:r,12:21,13:i,14:14,16:a,17:o,18:17,19:18,20:s,23:c},e(g,[2,14],{7:_,11:v}),e(y,[2,8]),e(y,[2,9]),e(y,[2,10]),e(p,[2,16],{15:37,24:m}),e(p,[2,17]),e(p,[2,18]),e(p,[2,20],{24:b}),e(h,[2,31]),{21:[1,39]},{22:[1,40]},e(g,[2,13],{7:_,11:v}),e(y,[2,11]),e(y,[2,12]),e(p,[2,15],{24:b}),e(h,[2,30]),{22:[1,41]},e(h,[2,27]),e(h,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};x.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return this.pushState(`shapeData`),t.yytext=``,24;case 1:return this.pushState(`shapeDataStr`),24;case 2:return this.popState(),24;case 3:return t.yytext=t.yytext.replace(/\n\s*/g,`
    `),24;case 4:return 24;case 5:this.popState();break;case 6:return e.getLogger().trace(`Found comment`,t.yytext),6;case 7:return 8;case 8:this.begin(`CLASS`);break;case 9:return this.popState(),17;case 10:this.popState();break;case 11:e.getLogger().trace(`Begin icon`),this.begin(`ICON`);break;case 12:return e.getLogger().trace(`SPACELINE`),6;case 13:return 7;case 14:return 16;case 15:e.getLogger().trace(`end icon`),this.popState();break;case 16:return e.getLogger().trace(`Exploding node`),this.begin(`NODE`),20;case 17:return e.getLogger().trace(`Cloud`),this.begin(`NODE`),20;case 18:return e.getLogger().trace(`Explosion Bang`),this.begin(`NODE`),20;case 19:return e.getLogger().trace(`Cloud Bang`),this.begin(`NODE`),20;case 20:return this.begin(`NODE`),20;case 21:return this.begin(`NODE`),20;case 22:return this.begin(`NODE`),20;case 23:return this.begin(`NODE`),20;case 24:return 13;case 25:return 23;case 26:return 11;case 27:this.begin(`NSTR2`);break;case 28:return`NODE_DESCR`;case 29:this.popState();break;case 30:e.getLogger().trace(`Starting NSTR`),this.begin(`NSTR`);break;case 31:return e.getLogger().trace(`description:`,t.yytext),`NODE_DESCR`;case 32:this.popState();break;case 33:return this.popState(),e.getLogger().trace(`node end ))`),`NODE_DEND`;case 34:return this.popState(),e.getLogger().trace(`node end )`),`NODE_DEND`;case 35:return this.popState(),e.getLogger().trace(`node end ...`,t.yytext),`NODE_DEND`;case 36:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 37:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 38:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 39:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 40:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 41:return e.getLogger().trace(`Long description:`,t.yytext),21;case 42:return e.getLogger().trace(`Long description:`,t.yytext),21}},`anonymous`),rules:[/^(?:@\{)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^\"]+)/i,/^(?:[^}^"]+)/i,/^(?:\})/i,/^(?:\s*%%.*)/i,/^(?:kanban\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}@]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{shapeDataEndBracket:{rules:[],inclusive:!1},shapeDataStr:{rules:[2,3],inclusive:!1},shapeData:{rules:[1,4,5],inclusive:!1},CLASS:{rules:[9,10],inclusive:!1},ICON:{rules:[14,15],inclusive:!1},NSTR2:{rules:[28,29],inclusive:!1},NSTR:{rules:[31,32],inclusive:!1},NODE:{rules:[27,30,33,34,35,36,37,38,39,40,41,42],inclusive:!1},INITIAL:{rules:[0,6,7,8,11,12,13,16,17,18,19,20,21,22,23,24,25,26],inclusive:!0}}}})();function S(){this.yy={}}return t(S,`Parser`),S.prototype=x,x.Parser=S,new S})();g.parser=g;var _=g,v=[],y=[],b=0,x={},S=t(()=>{v=[],y=[],b=0,x={}},`clear`),C=t(e=>{if(v.length===0)return null;let t=v[0].level,n=null;for(let e=v.length-1;e>=0;e--)if(v[e].level===t&&!n&&(n=v[e]),v[e].levelt.parentId===e.id);for(let n of i){let i={id:n.id,parentId:e.id,label:c(n.label??``,r),labelType:`markdown`,isGroup:!1,ticket:n?.ticket,priority:n?.priority,assigned:n?.assigned,icon:n?.icon,shape:`kanbanItem`,level:n.level,rx:5,ry:5,cssStyles:[`text-align: left`]};t.push(i)}}return{nodes:t,edges:e,other:{},config:s()}},`getData`),E=t((e,t,n,r,a)=>{let o=s(),l=o.mindmap?.padding??i.mindmap.padding;switch(r){case D.ROUNDED_RECT:case D.RECT:case D.HEXAGON:l*=2}let u={id:c(t,o)||`kbn`+b++,level:e,label:c(n,o),width:o.mindmap?.maxNodeWidth??i.mindmap.maxNodeWidth,padding:l,isGroup:!1};if(a!==void 0){let e;e=a.includes(` +`)?a+` +`:`{ +`+a+` +}`;let t=p(e,{schema:d});if(t.shape&&(t.shape!==t.shape.toLowerCase()||t.shape.includes(`_`)))throw Error(`No such shape: ${t.shape}. Shape names should be lowercase.`);t?.shape&&t.shape===`kanbanItem`&&(u.shape=t?.shape),t?.label&&(u.label=t?.label),t?.icon&&(u.icon=t?.icon.toString()),t?.assigned&&(u.assigned=t?.assigned.toString()),t?.ticket&&(u.ticket=t?.ticket.toString()),t?.priority&&(u.priority=t?.priority)}let f=C(e);f?u.parentId=f.id||`kbn`+b++:y.push(u),v.push(u)},`addNode`),D={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},O={clear:S,addNode:E,getSections:w,getData:T,nodeType:D,getType:t((t,n)=>{switch(e.debug(`In get type`,t,n),t){case`[`:return D.RECT;case`(`:return n===`)`?D.ROUNDED_RECT:D.CLOUD;case`((`:return D.CIRCLE;case`)`:return D.CLOUD;case`))`:return D.BANG;case`{{`:return D.HEXAGON;default:return D.DEFAULT}},`getType`),setElementForId:t((e,t)=>{x[e]=t},`setElementForId`),decorateNode:t(e=>{if(!e)return;let t=s(),n=v[v.length-1];e.icon&&(n.icon=c(e.icon,t)),e.class&&(n.cssClasses=c(e.class,t))},`decorateNode`),type2Str:t(e=>{switch(e){case D.DEFAULT:return`no-border`;case D.RECT:return`rect`;case D.ROUNDED_RECT:return`rounded-rect`;case D.CIRCLE:return`circle`;case D.CLOUD:return`cloud`;case D.BANG:return`bang`;case D.HEXAGON:return`hexgon`;default:return`no-border`}},`type2Str`),getLogger:t(()=>e,`getLogger`),getElementById:t(e=>x[e],`getElementById`)},k={draw:t(async(t,r,a,o)=>{e.debug(`Rendering kanban diagram +`+t);let c=o.db.getData(),d=s();d.htmlLabels=!1;let p=m(r);for(let e of c.nodes)e.domId=`${r}-${e.id}`;let h=p.append(`g`);h.attr(`class`,`sections`);let g=p.append(`g`);g.attr(`class`,`items`);let _=c.nodes.filter(e=>e.isGroup),v=0,y=[],b=25;for(let e of _){let t=d?.kanban?.sectionWidth||200;v+=1,e.x=t*v+(v-1)*10/2,e.width=t,e.y=0,e.height=t*3,e.rx=5,e.ry=5,e.cssClasses=e.cssClasses+` section-`+v;let n=await f(h,e);b=Math.max(b,n?.labelBBox?.height),y.push(n)}let x=0;for(let e of _){let t=y[x];x+=1;let n=d?.kanban?.sectionWidth||200,r=-n*3/2+b,i=r,a=c.nodes.filter(t=>t.parentId===e.id);for(let t of a){if(t.isGroup)throw Error(`Groups within groups are not allowed in Kanban diagrams`);t.x=e.x,t.width=n-15;let r=(await u(g,t,{config:d})).node().getBBox();t.y=i+r.height/2,await l(t),i=t.y+r.height/2+5}let o=t.cluster.select(`rect`),s=Math.max(i-r+30,50)+(b-25);o.attr(`height`,s)}n(void 0,p,d.mindmap?.padding??i.kanban.padding,d.mindmap?.useMaxWidth??i.kanban.useMaxWidth)},`draw`)},A=t(e=>{let n=``;for(let t=0;te.darkMode?a(t,n):o(t,n),`adjuster`);for(let t=0;t` + .edge { + stroke-width: 3; + } + ${A(e)} + .section-root rect, .section-root path, .section-root circle, .section-root polygon { + fill: ${e.git0}; + } + .section-root text { + fill: ${e.gitBranchLabel0}; + } + .icon-container { + height:100%; + display: flex; + justify-content: center; + align-items: center; + } + .edge { + fill: none; + } + .cluster-label, .label { + color: ${e.textColor}; + fill: ${e.textColor}; + } + .kanban-label { + dy: 1em; + alignment-baseline: middle; + text-anchor: middle; + dominant-baseline: middle; + text-align: center; + } + ${h()} +`,`getStyles`)};export{j as diagram}; \ No newline at end of file diff --git a/www/assets/katex-CXMH3UgJ.js b/www/assets/katex-CXMH3UgJ.js new file mode 100644 index 0000000..bd95525 --- /dev/null +++ b/www/assets/katex-CXMH3UgJ.js @@ -0,0 +1,257 @@ +var e=class e extends Error{constructor(t,n){var r=`KaTeX parse error: `+t,i,a,o=n&&n.loc;if(o&&o.start<=o.end){var s=o.lexer.input;i=o.start,a=o.end,i===s.length?r+=` at end of input: `:r+=` at position `+(i+1)+`: `;var c=s.slice(i,a).replace(/[^]/g,`$&̲`),l=i>15?`…`+s.slice(i-15,i):s.slice(0,i),u=a+15e.replace(t,`-$1`).toLowerCase(),r={"&":`&`,">":`>`,"<":`<`,'"':`"`,"'":`'`},i=/[&><"']/g,a=e=>String(e).replace(i,e=>r[e]),o=e=>e.type===`ordgroup`||e.type===`color`?e.body.length===1?o(e.body[0]):e:e.type===`font`?o(e.body):e,s=new Set([`mathord`,`textord`,`atom`]),c=e=>s.has(o(e).type),l=e=>{var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return t?t[2]!==`:`||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?null:t[1].toLowerCase():`_relative`},u={displayMode:{type:`boolean`,description:`Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.`,cli:`-d, --display-mode`},output:{type:{enum:[`htmlAndMathml`,`html`,`mathml`]},description:`Determines the markup language of the output.`,cli:`-F, --format `},leqno:{type:`boolean`,description:`Render display math in leqno style (left-justified tags).`},fleqn:{type:`boolean`,description:`Render display math flush left.`},throwOnError:{type:`boolean`,default:!0,cli:`-t, --no-throw-on-error`,cliDescription:`Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error.`},errorColor:{type:`string`,default:`#cc0000`,cli:`-c, --error-color `,cliDescription:`A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.`,cliProcessor:e=>`#`+e},macros:{type:`object`,cli:`-m, --macro `,cliDescription:`Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).`,cliDefault:[],cliProcessor:(e,t)=>(t.push(e),t)},minRuleThickness:{type:`number`,description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:`--min-rule-thickness `,cliProcessor:parseFloat},colorIsTextColor:{type:`boolean`,description:`Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.`,cli:`-b, --color-is-text-color`},strict:{type:[{enum:[`warn`,`ignore`,`error`]},`boolean`,`function`],description:`Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.`,cli:`-S, --strict`,cliDefault:!1},trust:{type:[`boolean`,`function`],description:`Trust the input, enabling all HTML features such as \\url.`,cli:`-T, --trust`},maxSize:{type:`number`,default:1/0,description:`If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large`,processor:e=>Math.max(0,e),cli:`-s, --max-size `,cliProcessor:parseInt},maxExpand:{type:`number`,default:1e3,description:`Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.`,processor:e=>Math.max(0,e),cli:`-e, --max-expand `,cliProcessor:e=>e===`Infinity`?1/0:parseInt(e)},globalGroup:{type:`boolean`,cli:!1}};function d(e){if(typeof e!=`string`)return e.enum[0];switch(e){case`boolean`:return!1;case`string`:return``;case`number`:return 0;case`object`:return{};default:throw Error(`Unexpected schema type; settings must declare an explicit default.`)}}function f(e){return e.default===void 0?d(Array.isArray(e.type)?e.type[0]:e.type):e.default}function p(e,t,n,r){var i=n[t];e[t]=i===void 0?f(r):r.processor?r.processor(i):i}var m=class{constructor(e){e===void 0&&(e={}),this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e||={};for(var t of Object.keys(u)){var n=u[t];n&&p(this,t,e,n)}}reportNonstrict(t,n,r){var i=this.strict;if(typeof i==`function`&&(i=i(t,n,r)),!(!i||i===`ignore`)){if(i===!0||i===`error`)throw new e(`LaTeX-incompatible input and strict mode is set to 'error': `+(n+` [`+t+`]`),r);i===`warn`?typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(n+` [`+t+`]`)):typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+i+`': `+n+` [`+t+`]`))}}useStrictBehavior(e,t,n){var r=this.strict;if(typeof r==`function`)try{r=r(e,t,n)}catch{r=`error`}return!r||r===`ignore`?!1:r===!0||r===`error`?!0:r===`warn`?(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)),!1):(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`)),!1)}isTrusted(e){if(`url`in e&&e.url&&!e.protocol){var t=l(e.url);if(t==null)return!1;e.protocol=t}return!!(typeof this.trust==`function`?this.trust(e):this.trust)}},h=class{constructor(e,t,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=t,this.cramped=n}sup(){return w[ee[this.id]]}sub(){return w[T[this.id]]}fracNum(){return w[te[this.id]]}fracDen(){return w[ne[this.id]]}cramp(){return w[re[this.id]]}text(){return w[ie[this.id]]}isTight(){return this.size>=2}},g=0,_=1,v=2,y=3,b=4,x=5,S=6,C=7,w=[new h(g,0,!1),new h(_,0,!0),new h(v,1,!1),new h(y,1,!0),new h(b,2,!1),new h(x,2,!0),new h(S,3,!1),new h(C,3,!0)],ee=[b,x,b,x,S,C,S,C],T=[x,x,x,x,C,C,C,C],te=[v,y,b,x,S,C,S,C],ne=[y,y,x,x,C,C,C,C],re=[_,_,y,y,x,x,C,C],ie=[g,_,v,y,v,y,v,y],E={DISPLAY:w[g],TEXT:w[v],SCRIPT:w[b],SCRIPTSCRIPT:w[S]},ae=[{name:`latin`,blocks:[[256,591],[768,879]]},{name:`cyrillic`,blocks:[[1024,1279]]},{name:`armenian`,blocks:[[1328,1423]]},{name:`brahmic`,blocks:[[2304,4255]]},{name:`georgian`,blocks:[[4256,4351]]},{name:`cjk`,blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:`hangul`,blocks:[[44032,55215]]}];function oe(e){for(var t=0;t=i[0]&&e<=i[1])return n.name}return null}var se=[];ae.forEach(e=>e.blocks.forEach(e=>se.push(...e)));function ce(e){for(var t=0;t=se[t]&&e<=se[t+1])return!0;return!1}var D=e=>e+` `+e,le=80,ue=function(e,t){return`M95,`+(622+e+t)+` +c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14 +c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54 +c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10 +s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429 +c69,-144,104.5,-217.7,106.5,-221 +l`+e/2.075+` -`+e+` +c5.3,-9.3,12,-14,20,-14 +H400000v`+(40+e)+`H845.2724 +s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7 +c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z +M`+(834+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},de=function(e,t){return`M263,`+(601+e+t)+`c0.7,0,18,39.7,52,119 +c34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120 +c340,-704.7,510.7,-1060.3,512,-1067 +l`+e/2.084+` -`+e+` +c4.7,-7.3,11,-11,19,-11 +H40000v`+(40+e)+`H1012.3 +s-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232 +c-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1 +s-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26 +c-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z +M`+(1001+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},fe=function(e,t){return`M983 `+(10+e+t)+` +l`+e/3.13+` -`+e+` +c4,-6.7,10,-10,18,-10 H400000v`+(40+e)+` +H1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7 +s-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744 +c-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30 +c26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722 +c56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5 +c53.7,-170.3,84.5,-266.8,92.5,-289.5z +M`+(1001+e)+` `+t+`h400000v`+(40+e)+`h-400000z`},pe=function(e,t){return`M424,`+(2398+e+t)+` +c-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514 +c0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20 +s-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121 +s209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081 +l`+e/4.223+` -`+e+`c4,-6.7,10,-10,18,-10 H400000 +v`+(40+e)+`H1014.6 +s-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185 +c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2z M`+(1001+e)+` `+t+` +h400000v`+(40+e)+`h-400000z`},me=function(e,t){return`M473,`+(2713+e+t)+` +c339.3,-1799.3,509.3,-2700,510,-2702 l`+e/5.298+` -`+e+` +c3.3,-7.3,9.3,-11,18,-11 H400000v`+(40+e)+`H1017.7 +s-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200 +c0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26 +s76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104, +606zM`+(1001+e)+` `+t+`h400000v`+(40+e)+`H1017.7z`},he=function(e){var t=e/2;return`M400000 `+e+` H0 L`+t+` 0 l65 45 L145 `+(e-80)+` H400000z`},ge=function(e,t,n){var r=n-54-t-e;return`M702 `+(e+t)+`H400000`+(40+e)+` +H742v`+r+`l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1 +h-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170 +c-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667 +219 661 l218 661zM702 `+t+`H400000v`+(40+e)+`H742z`},_e=function(e,t,n){t=1e3*t;var r=``;switch(e){case`sqrtMain`:r=ue(t,le);break;case`sqrtSize1`:r=de(t,le);break;case`sqrtSize2`:r=fe(t,le);break;case`sqrtSize3`:r=pe(t,le);break;case`sqrtSize4`:r=me(t,le);break;case`sqrtTall`:r=ge(t,le,n)}return r},ve=function(e,t){switch(e){case`⎜`:return D(`M291 0 H417 V`+t+` H291z`);case`∣`:return D(`M145 0 H188 V`+t+` H145z`);case`∥`:return D(`M145 0 H188 V`+t+` H145z`)+D(`M367 0 H410 V`+t+` H367z`);case`⎟`:return D(`M457 0 H583 V`+t+` H457z`);case`⎢`:return D(`M319 0 H403 V`+t+` H319z`);case`⎥`:return D(`M263 0 H347 V`+t+` H263z`);case`⎪`:return D(`M384 0 H504 V`+t+` H384z`);case`⏐`:return D(`M312 0 H355 V`+t+` H312z`);case`‖`:return D(`M257 0 H300 V`+t+` H257z`)+D(`M478 0 H521 V`+t+` H478z`);default:return``}},ye={doubleleftarrow:`M262 157 +l10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3 + 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28 + 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5 +c2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5 + 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87 +-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7 +-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z +m8 0v40h399730v-40zm0 194v40h399730v-40z`,doublerightarrow:`M399738 392l +-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5 + 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88 +-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68 +-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18 +-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782 +c-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3 +-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z`,leftarrow:`M400000 241H110l3-3c68.7-52.7 113.7-120 + 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8 +-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247 +c-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208 + 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3 + 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202 + l-3-3h399890zM100 241v40h399900v-40z`,leftbrace:`M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117 +-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7 + 5-6 9-10 13-.7 1-7.3 1-20 1H6z`,leftbraceunder:`M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13 + 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688 + 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7 +-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z`,leftgroup:`M400000 80 +H435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0 + 435 0h399565z`,leftgroupunder:`M400000 262 +H435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219 + 435 219h399565z`,leftharpoon:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3 +-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5 +-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7 +-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z`,leftharpoonplus:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5 + 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3 +-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7 +-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z +m0 0v40h400000v-40z`,leftharpoondown:`M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333 + 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5 + 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667 +-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z`,leftharpoondownplus:`M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12 + 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7 +-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0 +v40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z`,lefthook:`M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5 +-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3 +-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21 + 71.5 23h399859zM103 281v-40h399897v40z`,leftlinesegment:D(`M40 281 V428 H0 V94 H40 V241 H400000 v40z`),leftbracketunder:D(`M0 0 h120 V290 H399995 v120 H0z`),leftbracketover:D(`M0 440 h120 V150 H399995 v-120 H0z`),leftmapsto:D(`M40 281 V448H0V74H40V241H400000v40z`),leftToFrom:`M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23 +-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8 +c28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3 + 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z`,longequal:D(`M0 50 h400000 v40H0z m0 194h40000v40H0z`),midbrace:`M200428 334 +c-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14 +-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7 + 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11 + 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z`,midbraceunder:`M199572 214 +c100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14 + 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3 + 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0 +-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z`,oiintSize1:`M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6 +-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z +m368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8 +60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z`,oiintSize2:`M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8 +-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z +m502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2 +c0 110 84 276 504 276s502.4-166 502.4-276z`,oiiintSize1:`M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6 +-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z +m525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0 +85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z`,oiiintSize2:`M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8 +-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z +m770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1 +c0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z`,rightarrow:`M0 241v40h399891c-47.3 35.3-84 78-110 128 +-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 + 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 + 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85 +-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 + 151.7 139 205zm0 0v40h399900v-40z`,rightbrace:`M400000 542l +-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5 +s-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1 +c124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z`,rightbraceunder:`M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3 + 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237 +-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z`,rightgroup:`M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0 + 3-1 3-3v-38c-76-158-257-219-435-219H0z`,rightgroupunder:`M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18 + 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z`,rightharpoon:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3 +-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2 +-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 + 69.2 92 94.5zm0 0v40h399900v-40z`,rightharpoonplus:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11 +-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7 + 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z +m0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z`,rightharpoondown:`M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8 + 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5 +-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95 +-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z`,rightharpoondownplus:`M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8 + 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 + 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3 +-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z +m0-194v40h400000v-40zm0 0v40h400000v-40z`,righthook:`M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3 + 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0 +-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21 + 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z`,rightlinesegment:D(`M399960 241 V94 h40 V428 h-40 V281 H0 v-40z`),rightbracketunder:D(`M399995 0 h-120 V290 H0 v120 H400000z`),rightbracketover:D(`M399995 440 h-120 V150 H0 v-120 H399995z`),rightToFrom:`M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23 + 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32 +-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142 +-167z M100 147v40h399900v-40zM0 341v40h399900v-40z`,twoheadleftarrow:`M0 167c68 40 + 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69 +-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3 +-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19 +-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101 + 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z`,twoheadrightarrow:`M400000 167 +c-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3 + 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42 + 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333 +-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70 + 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z`,tilde1:`M200 55.538c-77 0-168 73.953-177 73.953-3 0-7 +-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0 + 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0 + 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128 +-68.267.847-113-73.952-191-73.952z`,tilde2:`M344 55.266c-142 0-300.638 81.316-311.5 86.418 +-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9 + 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114 +c1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751 + 181.476 676 181.476c-149 0-189-126.21-332-126.21z`,tilde3:`M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457 +-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0 + 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697 + 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696 + -338 0-409-156.573-744-156.573z`,tilde4:`M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345 +-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409 + 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9 + 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409 + -175.236-744-175.236z`,vec:`M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5 +3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11 +10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63 +-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1 +-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59 +H213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359 +c-16-25.333-24-45-24-59z`,widehat1:`M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22 +c-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z`,widehat2:`M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat3:`M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat4:`M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widecheck1:`M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1, +-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z`,widecheck2:`M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck3:`M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck4:`M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,baraboveleftarrow:`M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202 +c4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5 +c-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130 +s-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47 +121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6 +s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11 +c0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z +M100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z`,rightarrowabovebar:`M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32 +-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0 +13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39 +-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5 +-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 +151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z`,baraboveshortleftharpoon:`M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17 +c2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21 +c-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40 +c-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z +M0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z`,rightharpoonaboveshortbar:`M0,241 l0,40c399126,0,399993,0,399993,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z`,shortbaraboveleftharpoon:`M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9, +1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7, +-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z +M93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z`,shortrightharpoonabovebar:`M53,241l0,40c398570,0,399437,0,399437,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z`},be=function(e,t){switch(e){case`lbrack`:return`M403 1759 V84 H666 V0 H319 V1759 v`+t+` v1759 v84 h347 v-84 +H403z M403 1759 V0 H319 V1759 v`+t+` v1759 v84 h84z`;case`rbrack`:return`M347 1759 V0 H0 V84 H263 V1759 v`+t+` v1759 H0 v84 H347z +M347 1759 V0 H263 V1759 v`+t+` v1759 h84z`;case`vert`:return`M145 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+` v585 h43z`;case`doublevert`:return`M145 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+t+` v585 h43z +M367 15 v585 v`+t+` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v`+-t+` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M410 15 H367 v585 v`+t+` v585 h43z`;case`lfloor`:return`M319 602 V0 H403 V602 v`+t+` v1715 h263 v84 H319z +MM319 602 V0 H403 V602 v`+t+` v1715 H319z`;case`rfloor`:return`M319 602 V0 H403 V602 v`+t+` v1799 H0 v-84 H319z +MM319 602 V0 H403 V602 v`+t+` v1715 H319z`;case`lceil`:return`M403 1759 V84 H666 V0 H319 V1759 v`+t+` v602 h84z +M403 1759 V0 H319 V1759 v`+t+` v602 h84z`;case`rceil`:return`M347 1759 V0 H0 V84 H263 V1759 v`+t+` v602 h84z +M347 1759 V0 h-84 V1759 v`+t+` v602 h84z`;case`lparen`:return`M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1 +c-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349, +-36,557 l0,`+(t+84)+`c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210, +949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9 +c0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5, +-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189 +l0,-`+(t+92)+`c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3, +-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z`;case`rparen`:return`M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3, +63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5 +c11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,`+(t+9)+` +c-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664 +c-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11 +c0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17 +c242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558 +l0,-`+(t+144)+`c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7, +-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z`;default:throw Error(`Unknown stretchy delimiter.`)}};function xe(e){return`toText`in e}var Se=class{constructor(e){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=e,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(e){return this.classes.includes(e)}toNode(){for(var e=document.createDocumentFragment(),t=0;t{if(xe(e))return e.toText();throw Error(`Expected MathDomNode with toText, got `+e.constructor.name)}).join(``)}},Ce={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:803/800,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:803/800},we={ex:!0,em:!0,mu:!0},Te=function(e){return typeof e!=`string`&&(e=e.unit),e in Ce||e in we||e===`ex`},O=function(t,n){var r;if(t.unit in Ce)r=Ce[t.unit]/n.fontMetrics().ptPerEm/n.sizeMultiplier;else if(t.unit===`mu`)r=n.fontMetrics().cssEmPerMu;else{var i=n.style.isTight()?n.havingStyle(n.style.text()):n;if(t.unit===`ex`)r=i.fontMetrics().xHeight;else if(t.unit===`em`)r=i.fontMetrics().quad;else throw new e(`Invalid unit: '`+t.unit+`'`);i!==n&&(r*=i.sizeMultiplier/n.sizeMultiplier)}return Math.min(t.number*r,n.maxSize)},k=function(e){return+e.toFixed(4)+`em`},Ee=function(e){return e.filter(e=>e).join(` `)},De=function(e){var t=``;for(var r of Object.keys(e)){var i=e[r];i!==void 0&&(t+=n(r)+`:`+i+`;`)}return t},Oe=function(e,t,n){if(this.classes=e||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=n||{},t){t.style.isTight()&&this.classes.push(`mtight`);var r=t.getColor();r&&(this.style.color=r)}},ke=function(e){var t=document.createElement(e);t.className=Ee(this.classes),Object.assign(t.style,this.style);for(var n of Object.keys(this.attributes))t.setAttribute(n,this.attributes[n]);for(var r=0;r/=\x00-\x1f]/,je=function(t){var n=`<`+t;this.classes.length&&(n+=` class="`+a(Ee(this.classes))+`"`);var r=De(this.style);r&&(n+=` style="`+a(r)+`"`);for(var i of Object.keys(this.attributes)){if(Ae.test(i))throw new e(`Invalid attribute name '`+i+`'`);n+=` `+i+`="`+a(this.attributes[i])+`"`}n+=`>`;for(var o=0;o`,n},Me=class{constructor(e,t,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,this.italic=void 0,Oe.call(this,e,n,r),this.children=t||[]}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return this.classes.includes(e)}toNode(){return ke.call(this,`span`)}toMarkup(){return je.call(this,`span`)}},Ne=class{constructor(e,t,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,Oe.call(this,t,r),this.children=n||[],this.setAttribute(`href`,e)}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return this.classes.includes(e)}toNode(){return ke.call(this,`a`)}toMarkup(){return je.call(this,`a`)}},Pe=class{constructor(e,t,n){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=t,this.src=e,this.classes=[`mord`],this.height=0,this.depth=0,this.maxFontSize=0,this.style=n}hasClass(e){return this.classes.includes(e)}toNode(){var e=document.createElement(`img`);return e.src=this.src,e.alt=this.alt,e.className=`mord`,Object.assign(e.style,this.style),e}toMarkup(){var e=``+a(this.alt)+``,e}},Fe={î:`ı̂`,ï:`ı̈`,í:`ı́`,ì:`ı̀`},Ie=class{constructor(e,t,n,r,i,a,o,s){this.text=void 0,this.height=void 0,this.depth=void 0,this.italic=void 0,this.skew=void 0,this.width=void 0,this.maxFontSize=void 0,this.classes=void 0,this.style=void 0,this.text=e,this.height=t||0,this.depth=n||0,this.italic=r||0,this.skew=i||0,this.width=a||0,this.classes=o||[],this.style=s||{},this.maxFontSize=0;var c=oe(this.text.charCodeAt(0));c&&this.classes.push(c+`_fallback`),/[îïíì]/.test(this.text)&&(this.text=Fe[this.text])}hasClass(e){return this.classes.includes(e)}toNode(){var e=document.createTextNode(this.text),t=null;return this.italic>0&&(t=document.createElement(`span`),t.style.marginRight=k(this.italic)),this.classes.length>0&&(t||=document.createElement(`span`),t.className=Ee(this.classes)),Object.keys(this.style).length>0&&(t||=document.createElement(`span`),Object.assign(t.style,this.style)),t?(t.appendChild(e),t):e}toMarkup(){var e=!1,t=`0&&(n+=`margin-right:`+k(this.italic)+`;`),n+=De(this.style),n&&(e=!0,t+=` style="`+a(n)+`"`);var r=a(this.text);return e?(t+=`>`,t+=r,t+=``,t):r}},Le=class{constructor(e,t){this.children=void 0,this.attributes=void 0,this.children=e||[],this.attributes=t||{}}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`svg`);for(var t of Object.keys(this.attributes))e.setAttribute(t,this.attributes[t]);for(var n=0;n`;for(var n=0;n`,e}},Re=class{constructor(e,t){this.pathName=void 0,this.alternate=void 0,this.pathName=e,this.alternate=t}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`path`);return this.alternate?e.setAttribute(`d`,this.alternate):e.setAttribute(`d`,ye[this.pathName]),e}toMarkup(){return this.alternate?``:``}},ze=class{constructor(e){this.attributes=void 0,this.attributes=e||{}}toNode(){var e=document.createElementNS(`http://www.w3.org/2000/svg`,`line`);for(var t of Object.keys(this.attributes))e.setAttribute(t,this.attributes[t]);return e}toMarkup(){var e=``,e}};function Be(e){if(e instanceof Ie)return e;throw Error(`Expected symbolNode but got `+String(e)+`.`)}function Ve(e){if(e instanceof Me)return e;throw Error(`Expected span but got `+String(e)+`.`)}var He=e=>e instanceof Me||e instanceof Ne||e instanceof Se,Ue={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},We={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},Ge={Å:`A`,Ð:`D`,Þ:`o`,å:`a`,ð:`d`,þ:`o`,А:`A`,Б:`B`,В:`B`,Г:`F`,Д:`A`,Е:`E`,Ж:`K`,З:`3`,И:`N`,Й:`N`,К:`K`,Л:`N`,М:`M`,Н:`H`,О:`O`,П:`N`,Р:`P`,С:`C`,Т:`T`,У:`y`,Ф:`O`,Х:`X`,Ц:`U`,Ч:`h`,Ш:`W`,Щ:`W`,Ъ:`B`,Ы:`X`,Ь:`B`,Э:`3`,Ю:`X`,Я:`R`,а:`a`,б:`b`,в:`a`,г:`r`,д:`y`,е:`e`,ж:`m`,з:`e`,и:`n`,й:`n`,к:`n`,л:`n`,м:`m`,н:`n`,о:`o`,п:`n`,р:`p`,с:`c`,т:`o`,у:`y`,ф:`b`,х:`x`,ц:`n`,ч:`n`,ш:`w`,щ:`w`,ъ:`a`,ы:`m`,ь:`a`,э:`e`,ю:`m`,я:`r`};function Ke(e,t){Ue[e]=t}function qe(e,t,n){if(!Ue[t])throw Error(`Font metrics not found for font: `+t+`.`);var r=e.charCodeAt(0),i=Ue[t][r];if(!i&&e[0]in Ge&&(r=Ge[e[0]].charCodeAt(0),i=Ue[t][r]),!i&&n===`text`&&ce(r)&&(i=Ue[t][77]),i)return{depth:i[0],height:i[1],italic:i[2],skew:i[3],width:i[4]}}var Je={};function Ye(e){var t=e>=5?0:e>=3?1:2;if(!Je[t]){var n=Je[t]={cssEmPerMu:We.quad[t]/18};for(var r in We)We.hasOwnProperty(r)&&(n[r]=We[r][t])}return Je[t]}var A={math:{},text:{}};function j(e,t,n,r,i,a){A[e][i]={font:t,group:n,replace:r},a&&r&&(A[e][r]=A[e][i])}var M=`math`,N=`text`,P=`main`,F=`ams`,I=`accent-token`,L=`bin`,Xe=`close`,Ze=`inner`,R=`mathord`,z=`op-token`,Qe=`open`,$e=`punct`,B=`rel`,et=`spacing`,V=`textord`;j(M,P,B,`≡`,`\\equiv`,!0),j(M,P,B,`≺`,`\\prec`,!0),j(M,P,B,`≻`,`\\succ`,!0),j(M,P,B,`∼`,`\\sim`,!0),j(M,P,B,`⊥`,`\\perp`),j(M,P,B,`⪯`,`\\preceq`,!0),j(M,P,B,`⪰`,`\\succeq`,!0),j(M,P,B,`≃`,`\\simeq`,!0),j(M,P,B,`∣`,`\\mid`,!0),j(M,P,B,`≪`,`\\ll`,!0),j(M,P,B,`≫`,`\\gg`,!0),j(M,P,B,`≍`,`\\asymp`,!0),j(M,P,B,`∥`,`\\parallel`),j(M,P,B,`⋈`,`\\bowtie`,!0),j(M,P,B,`⌣`,`\\smile`,!0),j(M,P,B,`⊑`,`\\sqsubseteq`,!0),j(M,P,B,`⊒`,`\\sqsupseteq`,!0),j(M,P,B,`≐`,`\\doteq`,!0),j(M,P,B,`⌢`,`\\frown`,!0),j(M,P,B,`∋`,`\\ni`,!0),j(M,P,B,`∝`,`\\propto`,!0),j(M,P,B,`⊢`,`\\vdash`,!0),j(M,P,B,`⊣`,`\\dashv`,!0),j(M,P,B,`∋`,`\\owns`),j(M,P,$e,`.`,`\\ldotp`),j(M,P,$e,`⋅`,`\\cdotp`),j(M,P,$e,`⋅`,`·`),j(N,P,V,`⋅`,`·`),j(M,P,V,`#`,`\\#`),j(N,P,V,`#`,`\\#`),j(M,P,V,`&`,`\\&`),j(N,P,V,`&`,`\\&`),j(M,P,V,`ℵ`,`\\aleph`,!0),j(M,P,V,`∀`,`\\forall`,!0),j(M,P,V,`ℏ`,`\\hbar`,!0),j(M,P,V,`∃`,`\\exists`,!0),j(M,P,V,`∇`,`\\nabla`,!0),j(M,P,V,`♭`,`\\flat`,!0),j(M,P,V,`ℓ`,`\\ell`,!0),j(M,P,V,`♮`,`\\natural`,!0),j(M,P,V,`♣`,`\\clubsuit`,!0),j(M,P,V,`℘`,`\\wp`,!0),j(M,P,V,`♯`,`\\sharp`,!0),j(M,P,V,`♢`,`\\diamondsuit`,!0),j(M,P,V,`ℜ`,`\\Re`,!0),j(M,P,V,`♡`,`\\heartsuit`,!0),j(M,P,V,`ℑ`,`\\Im`,!0),j(M,P,V,`♠`,`\\spadesuit`,!0),j(M,P,V,`§`,`\\S`,!0),j(N,P,V,`§`,`\\S`),j(M,P,V,`¶`,`\\P`,!0),j(N,P,V,`¶`,`\\P`),j(M,P,V,`†`,`\\dag`),j(N,P,V,`†`,`\\dag`),j(N,P,V,`†`,`\\textdagger`),j(M,P,V,`‡`,`\\ddag`),j(N,P,V,`‡`,`\\ddag`),j(N,P,V,`‡`,`\\textdaggerdbl`),j(M,P,Xe,`⎱`,`\\rmoustache`,!0),j(M,P,Qe,`⎰`,`\\lmoustache`,!0),j(M,P,Xe,`⟯`,`\\rgroup`,!0),j(M,P,Qe,`⟮`,`\\lgroup`,!0),j(M,P,L,`∓`,`\\mp`,!0),j(M,P,L,`⊖`,`\\ominus`,!0),j(M,P,L,`⊎`,`\\uplus`,!0),j(M,P,L,`⊓`,`\\sqcap`,!0),j(M,P,L,`∗`,`\\ast`),j(M,P,L,`⊔`,`\\sqcup`,!0),j(M,P,L,`◯`,`\\bigcirc`,!0),j(M,P,L,`∙`,`\\bullet`,!0),j(M,P,L,`‡`,`\\ddagger`),j(M,P,L,`≀`,`\\wr`,!0),j(M,P,L,`⨿`,`\\amalg`),j(M,P,L,`&`,`\\And`),j(M,P,B,`⟵`,`\\longleftarrow`,!0),j(M,P,B,`⇐`,`\\Leftarrow`,!0),j(M,P,B,`⟸`,`\\Longleftarrow`,!0),j(M,P,B,`⟶`,`\\longrightarrow`,!0),j(M,P,B,`⇒`,`\\Rightarrow`,!0),j(M,P,B,`⟹`,`\\Longrightarrow`,!0),j(M,P,B,`↔`,`\\leftrightarrow`,!0),j(M,P,B,`⟷`,`\\longleftrightarrow`,!0),j(M,P,B,`⇔`,`\\Leftrightarrow`,!0),j(M,P,B,`⟺`,`\\Longleftrightarrow`,!0),j(M,P,B,`↦`,`\\mapsto`,!0),j(M,P,B,`⟼`,`\\longmapsto`,!0),j(M,P,B,`↗`,`\\nearrow`,!0),j(M,P,B,`↩`,`\\hookleftarrow`,!0),j(M,P,B,`↪`,`\\hookrightarrow`,!0),j(M,P,B,`↘`,`\\searrow`,!0),j(M,P,B,`↼`,`\\leftharpoonup`,!0),j(M,P,B,`⇀`,`\\rightharpoonup`,!0),j(M,P,B,`↙`,`\\swarrow`,!0),j(M,P,B,`↽`,`\\leftharpoondown`,!0),j(M,P,B,`⇁`,`\\rightharpoondown`,!0),j(M,P,B,`↖`,`\\nwarrow`,!0),j(M,P,B,`⇌`,`\\rightleftharpoons`,!0),j(M,F,B,`≮`,`\\nless`,!0),j(M,F,B,``,`\\@nleqslant`),j(M,F,B,``,`\\@nleqq`),j(M,F,B,`⪇`,`\\lneq`,!0),j(M,F,B,`≨`,`\\lneqq`,!0),j(M,F,B,``,`\\@lvertneqq`),j(M,F,B,`⋦`,`\\lnsim`,!0),j(M,F,B,`⪉`,`\\lnapprox`,!0),j(M,F,B,`⊀`,`\\nprec`,!0),j(M,F,B,`⋠`,`\\npreceq`,!0),j(M,F,B,`⋨`,`\\precnsim`,!0),j(M,F,B,`⪹`,`\\precnapprox`,!0),j(M,F,B,`≁`,`\\nsim`,!0),j(M,F,B,``,`\\@nshortmid`),j(M,F,B,`∤`,`\\nmid`,!0),j(M,F,B,`⊬`,`\\nvdash`,!0),j(M,F,B,`⊭`,`\\nvDash`,!0),j(M,F,B,`⋪`,`\\ntriangleleft`),j(M,F,B,`⋬`,`\\ntrianglelefteq`,!0),j(M,F,B,`⊊`,`\\subsetneq`,!0),j(M,F,B,``,`\\@varsubsetneq`),j(M,F,B,`⫋`,`\\subsetneqq`,!0),j(M,F,B,``,`\\@varsubsetneqq`),j(M,F,B,`≯`,`\\ngtr`,!0),j(M,F,B,``,`\\@ngeqslant`),j(M,F,B,``,`\\@ngeqq`),j(M,F,B,`⪈`,`\\gneq`,!0),j(M,F,B,`≩`,`\\gneqq`,!0),j(M,F,B,``,`\\@gvertneqq`),j(M,F,B,`⋧`,`\\gnsim`,!0),j(M,F,B,`⪊`,`\\gnapprox`,!0),j(M,F,B,`⊁`,`\\nsucc`,!0),j(M,F,B,`⋡`,`\\nsucceq`,!0),j(M,F,B,`⋩`,`\\succnsim`,!0),j(M,F,B,`⪺`,`\\succnapprox`,!0),j(M,F,B,`≆`,`\\ncong`,!0),j(M,F,B,``,`\\@nshortparallel`),j(M,F,B,`∦`,`\\nparallel`,!0),j(M,F,B,`⊯`,`\\nVDash`,!0),j(M,F,B,`⋫`,`\\ntriangleright`),j(M,F,B,`⋭`,`\\ntrianglerighteq`,!0),j(M,F,B,``,`\\@nsupseteqq`),j(M,F,B,`⊋`,`\\supsetneq`,!0),j(M,F,B,``,`\\@varsupsetneq`),j(M,F,B,`⫌`,`\\supsetneqq`,!0),j(M,F,B,``,`\\@varsupsetneqq`),j(M,F,B,`⊮`,`\\nVdash`,!0),j(M,F,B,`⪵`,`\\precneqq`,!0),j(M,F,B,`⪶`,`\\succneqq`,!0),j(M,F,B,``,`\\@nsubseteqq`),j(M,F,L,`⊴`,`\\unlhd`),j(M,F,L,`⊵`,`\\unrhd`),j(M,F,B,`↚`,`\\nleftarrow`,!0),j(M,F,B,`↛`,`\\nrightarrow`,!0),j(M,F,B,`⇍`,`\\nLeftarrow`,!0),j(M,F,B,`⇏`,`\\nRightarrow`,!0),j(M,F,B,`↮`,`\\nleftrightarrow`,!0),j(M,F,B,`⇎`,`\\nLeftrightarrow`,!0),j(M,F,B,`△`,`\\vartriangle`),j(M,F,V,`ℏ`,`\\hslash`),j(M,F,V,`▽`,`\\triangledown`),j(M,F,V,`◊`,`\\lozenge`),j(M,F,V,`Ⓢ`,`\\circledS`),j(M,F,V,`®`,`\\circledR`),j(N,F,V,`®`,`\\circledR`),j(M,F,V,`∡`,`\\measuredangle`,!0),j(M,F,V,`∄`,`\\nexists`),j(M,F,V,`℧`,`\\mho`),j(M,F,V,`Ⅎ`,`\\Finv`,!0),j(M,F,V,`⅁`,`\\Game`,!0),j(M,F,V,`‵`,`\\backprime`),j(M,F,V,`▲`,`\\blacktriangle`),j(M,F,V,`▼`,`\\blacktriangledown`),j(M,F,V,`■`,`\\blacksquare`),j(M,F,V,`⧫`,`\\blacklozenge`),j(M,F,V,`★`,`\\bigstar`),j(M,F,V,`∢`,`\\sphericalangle`,!0),j(M,F,V,`∁`,`\\complement`,!0),j(M,F,V,`ð`,`\\eth`,!0),j(N,P,V,`ð`,`ð`),j(M,F,V,`╱`,`\\diagup`),j(M,F,V,`╲`,`\\diagdown`),j(M,F,V,`□`,`\\square`),j(M,F,V,`□`,`\\Box`),j(M,F,V,`◊`,`\\Diamond`),j(M,F,V,`¥`,`\\yen`,!0),j(N,F,V,`¥`,`\\yen`,!0),j(M,F,V,`✓`,`\\checkmark`,!0),j(N,F,V,`✓`,`\\checkmark`),j(M,F,V,`ℶ`,`\\beth`,!0),j(M,F,V,`ℸ`,`\\daleth`,!0),j(M,F,V,`ℷ`,`\\gimel`,!0),j(M,F,V,`ϝ`,`\\digamma`,!0),j(M,F,V,`ϰ`,`\\varkappa`),j(M,F,Qe,`┌`,`\\@ulcorner`,!0),j(M,F,Xe,`┐`,`\\@urcorner`,!0),j(M,F,Qe,`└`,`\\@llcorner`,!0),j(M,F,Xe,`┘`,`\\@lrcorner`,!0),j(M,F,B,`≦`,`\\leqq`,!0),j(M,F,B,`⩽`,`\\leqslant`,!0),j(M,F,B,`⪕`,`\\eqslantless`,!0),j(M,F,B,`≲`,`\\lesssim`,!0),j(M,F,B,`⪅`,`\\lessapprox`,!0),j(M,F,B,`≊`,`\\approxeq`,!0),j(M,F,L,`⋖`,`\\lessdot`),j(M,F,B,`⋘`,`\\lll`,!0),j(M,F,B,`≶`,`\\lessgtr`,!0),j(M,F,B,`⋚`,`\\lesseqgtr`,!0),j(M,F,B,`⪋`,`\\lesseqqgtr`,!0),j(M,F,B,`≑`,`\\doteqdot`),j(M,F,B,`≓`,`\\risingdotseq`,!0),j(M,F,B,`≒`,`\\fallingdotseq`,!0),j(M,F,B,`∽`,`\\backsim`,!0),j(M,F,B,`⋍`,`\\backsimeq`,!0),j(M,F,B,`⫅`,`\\subseteqq`,!0),j(M,F,B,`⋐`,`\\Subset`,!0),j(M,F,B,`⊏`,`\\sqsubset`,!0),j(M,F,B,`≼`,`\\preccurlyeq`,!0),j(M,F,B,`⋞`,`\\curlyeqprec`,!0),j(M,F,B,`≾`,`\\precsim`,!0),j(M,F,B,`⪷`,`\\precapprox`,!0),j(M,F,B,`⊲`,`\\vartriangleleft`),j(M,F,B,`⊴`,`\\trianglelefteq`),j(M,F,B,`⊨`,`\\vDash`,!0),j(M,F,B,`⊪`,`\\Vvdash`,!0),j(M,F,B,`⌣`,`\\smallsmile`),j(M,F,B,`⌢`,`\\smallfrown`),j(M,F,B,`≏`,`\\bumpeq`,!0),j(M,F,B,`≎`,`\\Bumpeq`,!0),j(M,F,B,`≧`,`\\geqq`,!0),j(M,F,B,`⩾`,`\\geqslant`,!0),j(M,F,B,`⪖`,`\\eqslantgtr`,!0),j(M,F,B,`≳`,`\\gtrsim`,!0),j(M,F,B,`⪆`,`\\gtrapprox`,!0),j(M,F,L,`⋗`,`\\gtrdot`),j(M,F,B,`⋙`,`\\ggg`,!0),j(M,F,B,`≷`,`\\gtrless`,!0),j(M,F,B,`⋛`,`\\gtreqless`,!0),j(M,F,B,`⪌`,`\\gtreqqless`,!0),j(M,F,B,`≖`,`\\eqcirc`,!0),j(M,F,B,`≗`,`\\circeq`,!0),j(M,F,B,`≜`,`\\triangleq`,!0),j(M,F,B,`∼`,`\\thicksim`),j(M,F,B,`≈`,`\\thickapprox`),j(M,F,B,`⫆`,`\\supseteqq`,!0),j(M,F,B,`⋑`,`\\Supset`,!0),j(M,F,B,`⊐`,`\\sqsupset`,!0),j(M,F,B,`≽`,`\\succcurlyeq`,!0),j(M,F,B,`⋟`,`\\curlyeqsucc`,!0),j(M,F,B,`≿`,`\\succsim`,!0),j(M,F,B,`⪸`,`\\succapprox`,!0),j(M,F,B,`⊳`,`\\vartriangleright`),j(M,F,B,`⊵`,`\\trianglerighteq`),j(M,F,B,`⊩`,`\\Vdash`,!0),j(M,F,B,`∣`,`\\shortmid`),j(M,F,B,`∥`,`\\shortparallel`),j(M,F,B,`≬`,`\\between`,!0),j(M,F,B,`⋔`,`\\pitchfork`,!0),j(M,F,B,`∝`,`\\varpropto`),j(M,F,B,`◀`,`\\blacktriangleleft`),j(M,F,B,`∴`,`\\therefore`,!0),j(M,F,B,`∍`,`\\backepsilon`),j(M,F,B,`▶`,`\\blacktriangleright`),j(M,F,B,`∵`,`\\because`,!0),j(M,F,B,`⋘`,`\\llless`),j(M,F,B,`⋙`,`\\gggtr`),j(M,F,L,`⊲`,`\\lhd`),j(M,F,L,`⊳`,`\\rhd`),j(M,F,B,`≂`,`\\eqsim`,!0),j(M,P,B,`⋈`,`\\Join`),j(M,F,B,`≑`,`\\Doteq`,!0),j(M,F,L,`∔`,`\\dotplus`,!0),j(M,F,L,`∖`,`\\smallsetminus`),j(M,F,L,`⋒`,`\\Cap`,!0),j(M,F,L,`⋓`,`\\Cup`,!0),j(M,F,L,`⩞`,`\\doublebarwedge`,!0),j(M,F,L,`⊟`,`\\boxminus`,!0),j(M,F,L,`⊞`,`\\boxplus`,!0),j(M,F,L,`⋇`,`\\divideontimes`,!0),j(M,F,L,`⋉`,`\\ltimes`,!0),j(M,F,L,`⋊`,`\\rtimes`,!0),j(M,F,L,`⋋`,`\\leftthreetimes`,!0),j(M,F,L,`⋌`,`\\rightthreetimes`,!0),j(M,F,L,`⋏`,`\\curlywedge`,!0),j(M,F,L,`⋎`,`\\curlyvee`,!0),j(M,F,L,`⊝`,`\\circleddash`,!0),j(M,F,L,`⊛`,`\\circledast`,!0),j(M,F,L,`⋅`,`\\centerdot`),j(M,F,L,`⊺`,`\\intercal`,!0),j(M,F,L,`⋒`,`\\doublecap`),j(M,F,L,`⋓`,`\\doublecup`),j(M,F,L,`⊠`,`\\boxtimes`,!0),j(M,F,B,`⇢`,`\\dashrightarrow`,!0),j(M,F,B,`⇠`,`\\dashleftarrow`,!0),j(M,F,B,`⇇`,`\\leftleftarrows`,!0),j(M,F,B,`⇆`,`\\leftrightarrows`,!0),j(M,F,B,`⇚`,`\\Lleftarrow`,!0),j(M,F,B,`↞`,`\\twoheadleftarrow`,!0),j(M,F,B,`↢`,`\\leftarrowtail`,!0),j(M,F,B,`↫`,`\\looparrowleft`,!0),j(M,F,B,`⇋`,`\\leftrightharpoons`,!0),j(M,F,B,`↶`,`\\curvearrowleft`,!0),j(M,F,B,`↺`,`\\circlearrowleft`,!0),j(M,F,B,`↰`,`\\Lsh`,!0),j(M,F,B,`⇈`,`\\upuparrows`,!0),j(M,F,B,`↿`,`\\upharpoonleft`,!0),j(M,F,B,`⇃`,`\\downharpoonleft`,!0),j(M,P,B,`⊶`,`\\origof`,!0),j(M,P,B,`⊷`,`\\imageof`,!0),j(M,F,B,`⊸`,`\\multimap`,!0),j(M,F,B,`↭`,`\\leftrightsquigarrow`,!0),j(M,F,B,`⇉`,`\\rightrightarrows`,!0),j(M,F,B,`⇄`,`\\rightleftarrows`,!0),j(M,F,B,`↠`,`\\twoheadrightarrow`,!0),j(M,F,B,`↣`,`\\rightarrowtail`,!0),j(M,F,B,`↬`,`\\looparrowright`,!0),j(M,F,B,`↷`,`\\curvearrowright`,!0),j(M,F,B,`↻`,`\\circlearrowright`,!0),j(M,F,B,`↱`,`\\Rsh`,!0),j(M,F,B,`⇊`,`\\downdownarrows`,!0),j(M,F,B,`↾`,`\\upharpoonright`,!0),j(M,F,B,`⇂`,`\\downharpoonright`,!0),j(M,F,B,`⇝`,`\\rightsquigarrow`,!0),j(M,F,B,`⇝`,`\\leadsto`),j(M,F,B,`⇛`,`\\Rrightarrow`,!0),j(M,F,B,`↾`,`\\restriction`),j(M,P,V,`‘`,"`"),j(M,P,V,`$`,`\\$`),j(N,P,V,`$`,`\\$`),j(N,P,V,`$`,`\\textdollar`),j(M,P,V,`%`,`\\%`),j(N,P,V,`%`,`\\%`),j(M,P,V,`_`,`\\_`),j(N,P,V,`_`,`\\_`),j(N,P,V,`_`,`\\textunderscore`),j(M,P,V,`∠`,`\\angle`,!0),j(M,P,V,`∞`,`\\infty`,!0),j(M,P,V,`′`,`\\prime`),j(M,P,V,`△`,`\\triangle`),j(M,P,V,`Γ`,`\\Gamma`,!0),j(M,P,V,`Δ`,`\\Delta`,!0),j(M,P,V,`Θ`,`\\Theta`,!0),j(M,P,V,`Λ`,`\\Lambda`,!0),j(M,P,V,`Ξ`,`\\Xi`,!0),j(M,P,V,`Π`,`\\Pi`,!0),j(M,P,V,`Σ`,`\\Sigma`,!0),j(M,P,V,`Υ`,`\\Upsilon`,!0),j(M,P,V,`Φ`,`\\Phi`,!0),j(M,P,V,`Ψ`,`\\Psi`,!0),j(M,P,V,`Ω`,`\\Omega`,!0),j(M,P,V,`A`,`Α`),j(M,P,V,`B`,`Β`),j(M,P,V,`E`,`Ε`),j(M,P,V,`Z`,`Ζ`),j(M,P,V,`H`,`Η`),j(M,P,V,`I`,`Ι`),j(M,P,V,`K`,`Κ`),j(M,P,V,`M`,`Μ`),j(M,P,V,`N`,`Ν`),j(M,P,V,`O`,`Ο`),j(M,P,V,`P`,`Ρ`),j(M,P,V,`T`,`Τ`),j(M,P,V,`X`,`Χ`),j(M,P,V,`¬`,`\\neg`,!0),j(M,P,V,`¬`,`\\lnot`),j(M,P,V,`⊤`,`\\top`),j(M,P,V,`⊥`,`\\bot`),j(M,P,V,`∅`,`\\emptyset`),j(M,F,V,`∅`,`\\varnothing`),j(M,P,R,`α`,`\\alpha`,!0),j(M,P,R,`β`,`\\beta`,!0),j(M,P,R,`γ`,`\\gamma`,!0),j(M,P,R,`δ`,`\\delta`,!0),j(M,P,R,`ϵ`,`\\epsilon`,!0),j(M,P,R,`ζ`,`\\zeta`,!0),j(M,P,R,`η`,`\\eta`,!0),j(M,P,R,`θ`,`\\theta`,!0),j(M,P,R,`ι`,`\\iota`,!0),j(M,P,R,`κ`,`\\kappa`,!0),j(M,P,R,`λ`,`\\lambda`,!0),j(M,P,R,`μ`,`\\mu`,!0),j(M,P,R,`ν`,`\\nu`,!0),j(M,P,R,`ξ`,`\\xi`,!0),j(M,P,R,`ο`,`\\omicron`,!0),j(M,P,R,`π`,`\\pi`,!0),j(M,P,R,`ρ`,`\\rho`,!0),j(M,P,R,`σ`,`\\sigma`,!0),j(M,P,R,`τ`,`\\tau`,!0),j(M,P,R,`υ`,`\\upsilon`,!0),j(M,P,R,`ϕ`,`\\phi`,!0),j(M,P,R,`χ`,`\\chi`,!0),j(M,P,R,`ψ`,`\\psi`,!0),j(M,P,R,`ω`,`\\omega`,!0),j(M,P,R,`ε`,`\\varepsilon`,!0),j(M,P,R,`ϑ`,`\\vartheta`,!0),j(M,P,R,`ϖ`,`\\varpi`,!0),j(M,P,R,`ϱ`,`\\varrho`,!0),j(M,P,R,`ς`,`\\varsigma`,!0),j(M,P,R,`φ`,`\\varphi`,!0),j(M,P,L,`∗`,`*`,!0),j(M,P,L,`+`,`+`),j(M,P,L,`−`,`-`,!0),j(M,P,L,`⋅`,`\\cdot`,!0),j(M,P,L,`∘`,`\\circ`,!0),j(M,P,L,`÷`,`\\div`,!0),j(M,P,L,`±`,`\\pm`,!0),j(M,P,L,`×`,`\\times`,!0),j(M,P,L,`∩`,`\\cap`,!0),j(M,P,L,`∪`,`\\cup`,!0),j(M,P,L,`∖`,`\\setminus`,!0),j(M,P,L,`∧`,`\\land`),j(M,P,L,`∨`,`\\lor`),j(M,P,L,`∧`,`\\wedge`,!0),j(M,P,L,`∨`,`\\vee`,!0),j(M,P,V,`√`,`\\surd`),j(M,P,Qe,`⟨`,`\\langle`,!0),j(M,P,Qe,`∣`,`\\lvert`),j(M,P,Qe,`∥`,`\\lVert`),j(M,P,Xe,`?`,`?`),j(M,P,Xe,`!`,`!`),j(M,P,Xe,`⟩`,`\\rangle`,!0),j(M,P,Xe,`∣`,`\\rvert`),j(M,P,Xe,`∥`,`\\rVert`),j(M,P,B,`=`,`=`),j(M,P,B,`:`,`:`),j(M,P,B,`≈`,`\\approx`,!0),j(M,P,B,`≅`,`\\cong`,!0),j(M,P,B,`≥`,`\\ge`),j(M,P,B,`≥`,`\\geq`,!0),j(M,P,B,`←`,`\\gets`),j(M,P,B,`>`,`\\gt`,!0),j(M,P,B,`∈`,`\\in`,!0),j(M,P,B,``,`\\@not`),j(M,P,B,`⊂`,`\\subset`,!0),j(M,P,B,`⊃`,`\\supset`,!0),j(M,P,B,`⊆`,`\\subseteq`,!0),j(M,P,B,`⊇`,`\\supseteq`,!0),j(M,F,B,`⊈`,`\\nsubseteq`,!0),j(M,F,B,`⊉`,`\\nsupseteq`,!0),j(M,P,B,`⊨`,`\\models`),j(M,P,B,`←`,`\\leftarrow`,!0),j(M,P,B,`≤`,`\\le`),j(M,P,B,`≤`,`\\leq`,!0),j(M,P,B,`<`,`\\lt`,!0),j(M,P,B,`→`,`\\rightarrow`,!0),j(M,P,B,`→`,`\\to`),j(M,F,B,`≱`,`\\ngeq`,!0),j(M,F,B,`≰`,`\\nleq`,!0),j(M,P,et,`\xA0`,`\\ `),j(M,P,et,`\xA0`,`\\space`),j(M,P,et,`\xA0`,`\\nobreakspace`),j(N,P,et,`\xA0`,`\\ `),j(N,P,et,`\xA0`,` `),j(N,P,et,`\xA0`,`\\space`),j(N,P,et,`\xA0`,`\\nobreakspace`),j(M,P,et,``,`\\nobreak`),j(M,P,et,``,`\\allowbreak`),j(M,P,$e,`,`,`,`),j(M,P,$e,`;`,`;`),j(M,F,L,`⊼`,`\\barwedge`,!0),j(M,F,L,`⊻`,`\\veebar`,!0),j(M,P,L,`⊙`,`\\odot`,!0),j(M,P,L,`⊕`,`\\oplus`,!0),j(M,P,L,`⊗`,`\\otimes`,!0),j(M,P,V,`∂`,`\\partial`,!0),j(M,P,L,`⊘`,`\\oslash`,!0),j(M,F,L,`⊚`,`\\circledcirc`,!0),j(M,F,L,`⊡`,`\\boxdot`,!0),j(M,P,L,`△`,`\\bigtriangleup`),j(M,P,L,`▽`,`\\bigtriangledown`),j(M,P,L,`†`,`\\dagger`),j(M,P,L,`⋄`,`\\diamond`),j(M,P,L,`⋆`,`\\star`),j(M,P,L,`◃`,`\\triangleleft`),j(M,P,L,`▹`,`\\triangleright`),j(M,P,Qe,`{`,`\\{`),j(N,P,V,`{`,`\\{`),j(N,P,V,`{`,`\\textbraceleft`),j(M,P,Xe,`}`,`\\}`),j(N,P,V,`}`,`\\}`),j(N,P,V,`}`,`\\textbraceright`),j(M,P,Qe,`{`,`\\lbrace`),j(M,P,Xe,`}`,`\\rbrace`),j(M,P,Qe,`[`,`\\lbrack`,!0),j(N,P,V,`[`,`\\lbrack`,!0),j(M,P,Xe,`]`,`\\rbrack`,!0),j(N,P,V,`]`,`\\rbrack`,!0),j(M,P,Qe,`(`,`\\lparen`,!0),j(M,P,Xe,`)`,`\\rparen`,!0),j(N,P,V,`<`,`\\textless`,!0),j(N,P,V,`>`,`\\textgreater`,!0),j(M,P,Qe,`⌊`,`\\lfloor`,!0),j(M,P,Xe,`⌋`,`\\rfloor`,!0),j(M,P,Qe,`⌈`,`\\lceil`,!0),j(M,P,Xe,`⌉`,`\\rceil`,!0),j(M,P,V,`\\`,`\\backslash`),j(M,P,V,`∣`,`|`),j(M,P,V,`∣`,`\\vert`),j(N,P,V,`|`,`\\textbar`,!0),j(M,P,V,`∥`,`\\|`),j(M,P,V,`∥`,`\\Vert`),j(N,P,V,`∥`,`\\textbardbl`),j(N,P,V,`~`,`\\textasciitilde`),j(N,P,V,`\\`,`\\textbackslash`),j(N,P,V,`^`,`\\textasciicircum`),j(M,P,B,`↑`,`\\uparrow`,!0),j(M,P,B,`⇑`,`\\Uparrow`,!0),j(M,P,B,`↓`,`\\downarrow`,!0),j(M,P,B,`⇓`,`\\Downarrow`,!0),j(M,P,B,`↕`,`\\updownarrow`,!0),j(M,P,B,`⇕`,`\\Updownarrow`,!0),j(M,P,z,`∐`,`\\coprod`),j(M,P,z,`⋁`,`\\bigvee`),j(M,P,z,`⋀`,`\\bigwedge`),j(M,P,z,`⨄`,`\\biguplus`),j(M,P,z,`⋂`,`\\bigcap`),j(M,P,z,`⋃`,`\\bigcup`),j(M,P,z,`∫`,`\\int`),j(M,P,z,`∫`,`\\intop`),j(M,P,z,`∬`,`\\iint`),j(M,P,z,`∭`,`\\iiint`),j(M,P,z,`∏`,`\\prod`),j(M,P,z,`∑`,`\\sum`),j(M,P,z,`⨂`,`\\bigotimes`),j(M,P,z,`⨁`,`\\bigoplus`),j(M,P,z,`⨀`,`\\bigodot`),j(M,P,z,`∮`,`\\oint`),j(M,P,z,`∯`,`\\oiint`),j(M,P,z,`∰`,`\\oiiint`),j(M,P,z,`⨆`,`\\bigsqcup`),j(M,P,z,`∫`,`\\smallint`),j(N,P,Ze,`…`,`\\textellipsis`),j(M,P,Ze,`…`,`\\mathellipsis`),j(N,P,Ze,`…`,`\\ldots`,!0),j(M,P,Ze,`…`,`\\ldots`,!0),j(M,P,Ze,`⋯`,`\\@cdots`,!0),j(M,P,Ze,`⋱`,`\\ddots`,!0),j(M,P,V,`⋮`,`\\varvdots`),j(N,P,V,`⋮`,`\\varvdots`),j(M,P,I,`ˊ`,`\\acute`),j(M,P,I,`ˋ`,`\\grave`),j(M,P,I,`¨`,`\\ddot`),j(M,P,I,`~`,`\\tilde`),j(M,P,I,`ˉ`,`\\bar`),j(M,P,I,`˘`,`\\breve`),j(M,P,I,`ˇ`,`\\check`),j(M,P,I,`^`,`\\hat`),j(M,P,I,`⃗`,`\\vec`),j(M,P,I,`˙`,`\\dot`),j(M,P,I,`˚`,`\\mathring`),j(M,P,R,``,`\\@imath`),j(M,P,R,``,`\\@jmath`),j(M,P,V,`ı`,`ı`),j(M,P,V,`ȷ`,`ȷ`),j(N,P,V,`ı`,`\\i`,!0),j(N,P,V,`ȷ`,`\\j`,!0),j(N,P,V,`ß`,`\\ss`,!0),j(N,P,V,`æ`,`\\ae`,!0),j(N,P,V,`œ`,`\\oe`,!0),j(N,P,V,`ø`,`\\o`,!0),j(N,P,V,`Æ`,`\\AE`,!0),j(N,P,V,`Œ`,`\\OE`,!0),j(N,P,V,`Ø`,`\\O`,!0),j(N,P,I,`ˊ`,`\\'`),j(N,P,I,`ˋ`,"\\`"),j(N,P,I,`ˆ`,`\\^`),j(N,P,I,`˜`,`\\~`),j(N,P,I,`ˉ`,`\\=`),j(N,P,I,`˘`,`\\u`),j(N,P,I,`˙`,`\\.`),j(N,P,I,`¸`,`\\c`),j(N,P,I,`˚`,`\\r`),j(N,P,I,`ˇ`,`\\v`),j(N,P,I,`¨`,`\\"`),j(N,P,I,`˝`,`\\H`),j(N,P,I,`◯`,`\\textcircled`);var tt={"--":!0,"---":!0,"``":!0,"''":!0};j(N,P,V,`–`,`--`,!0),j(N,P,V,`–`,`\\textendash`),j(N,P,V,`—`,`---`,!0),j(N,P,V,`—`,`\\textemdash`),j(N,P,V,`‘`,"`",!0),j(N,P,V,`‘`,`\\textquoteleft`),j(N,P,V,`’`,`'`,!0),j(N,P,V,`’`,`\\textquoteright`),j(N,P,V,`“`,"``",!0),j(N,P,V,`“`,`\\textquotedblleft`),j(N,P,V,`”`,`''`,!0),j(N,P,V,`”`,`\\textquotedblright`),j(M,P,V,`°`,`\\degree`,!0),j(N,P,V,`°`,`\\degree`),j(N,P,V,`°`,`\\textdegree`,!0),j(M,P,V,`£`,`\\pounds`),j(M,P,V,`£`,`\\mathsterling`,!0),j(N,P,V,`£`,`\\pounds`),j(N,P,V,`£`,`\\textsterling`,!0),j(M,F,V,`✠`,`\\maltese`),j(N,F,V,`✠`,`\\maltese`);for(var nt=`0123456789/@."`,rt=0;rt{var n=t.charCodeAt(0),r=t.charCodeAt(1),i=(n-55296)*1024+(r-56320)+65536;if(119808<=i&&i<120484)return kt[Math.floor((i-119808)/26)];if(120782<=i&&i<=120831)return At[Math.floor((i-120782)/10)];if(i===120485||i===120486)return kt[0];if(120486{if(Ee(e.classes)!==Ee(t.classes)||e.skew!==t.skew||e.maxFontSize!==t.maxFontSize||e.italic!==0&&e.hasClass(`mathnormal`))return!1;if(e.classes.length===1){var n=e.classes[0];if(n===`mbin`||n===`mord`)return!1}for(var r of Object.keys(e.style))if(e.style[r]!==t.style[r])return!1;for(var i of Object.keys(t.style))if(e.style[i]!==t.style[i])return!1;return!0},Rt=e=>{for(var t=0;tt&&(t=a.height),a.depth>n&&(n=a.depth),a.maxFontSize>r&&(r=a.maxFontSize)}e.height=t,e.depth=n,e.maxFontSize=r},W=function(e,t,n,r){var i=new Me(e,t,n,r);return zt(i),i},Bt=(e,t,n,r)=>new Me(e,t,n,r),Vt=function(e,t,n){var r=W([e],[],t);return r.height=Math.max(n||t.fontMetrics().defaultRuleThickness,t.minRuleThickness),r.style.borderBottomWidth=k(r.height),r.maxFontSize=1,r},Ht=function(e,t,n,r){var i=new Ne(e,t,n,r);return zt(i),i},Ut=function(e){var t=new Se(e);return zt(t),t},Wt=function(e,t){return e instanceof Se?W([],[e],t):e},Gt=function(e){if(e.positionType===`individualShift`){for(var t=e.children,n=[t[0]],r=-t[0].shift-t[0].elem.depth,i=r,a=1;a{var n=W([`mspace`],[],t),r=O(e,t);return n.style.marginRight=k(r),n},qt=(e,t,n)=>{var r,i;switch(e){case`amsrm`:r=`AMS`;break;case`textrm`:r=`Main`;break;case`textsf`:r=`SansSerif`;break;case`texttt`:r=`Typewriter`;break;default:r=e}return i=t===`textbf`&&n===`textit`?`BoldItalic`:t===`textbf`?`Bold`:n===`textit`?`Italic`:`Regular`,r+`-`+i},Jt={mathbf:{variant:`bold`,fontName:`Main-Bold`},mathrm:{variant:`normal`,fontName:`Main-Regular`},textit:{variant:`italic`,fontName:`Main-Italic`},mathit:{variant:`italic`,fontName:`Main-Italic`},mathnormal:{variant:`italic`,fontName:`Math-Italic`},mathsfit:{variant:`sans-serif-italic`,fontName:`SansSerif-Italic`},mathbb:{variant:`double-struck`,fontName:`AMS-Regular`},mathcal:{variant:`script`,fontName:`Caligraphic-Regular`},mathfrak:{variant:`fraktur`,fontName:`Fraktur-Regular`},mathscr:{variant:`script`,fontName:`Script-Regular`},mathsf:{variant:`sans-serif`,fontName:`SansSerif-Regular`},mathtt:{variant:`monospace`,fontName:`Typewriter-Regular`}},Yt={vec:[`vec`,.471,.714],oiintSize1:[`oiintSize1`,.957,.499],oiintSize2:[`oiintSize2`,1.472,.659],oiiintSize1:[`oiiintSize1`,1.304,.499],oiiintSize2:[`oiiintSize2`,1.98,.659]},Xt=function(e,t){var[n,r,i]=Yt[e],a=Bt([`overlay`],[new Le([new Re(n)],{width:k(r),height:k(i),style:`width:`+k(r),viewBox:`0 0 `+1e3*r+` `+1e3*i,preserveAspectRatio:`xMinYMin`})],t);return a.height=i,a.style.height=k(i),a.style.width=k(r),a},K={number:3,unit:`mu`},Zt={number:4,unit:`mu`},Qt={number:5,unit:`mu`},$t={mord:{mop:K,mbin:Zt,mrel:Qt,minner:K},mop:{mord:K,mop:K,mrel:Qt,minner:K},mbin:{mord:Zt,mop:Zt,mopen:Zt,minner:Zt},mrel:{mord:Qt,mop:Qt,mopen:Qt,minner:Qt},mopen:{},mclose:{mop:K,mbin:Zt,mrel:Qt,minner:K},mpunct:{mord:K,mop:K,mrel:Qt,mopen:K,mclose:K,mpunct:K,minner:K},minner:{mord:K,mop:K,mbin:Zt,mrel:Qt,mopen:K,mpunct:K,minner:K}},en={mord:{mop:K},mop:{mord:K,mop:K},mbin:{},mrel:{},mopen:{},mclose:{mop:K},mpunct:{},minner:{mop:K}},tn={},nn={},rn={};function q(e){for(var{type:t,names:n,props:r,handler:i,htmlBuilder:a,mathmlBuilder:o}=e,s={type:t,numArgs:r.numArgs,argTypes:r.argTypes,allowedInArgument:!!r.allowedInArgument,allowedInText:!!r.allowedInText,allowedInMath:r.allowedInMath===void 0||r.allowedInMath,numOptionalArgs:r.numOptionalArgs||0,infix:!!r.infix,primitive:!!r.primitive,handler:i},c=0;c{var n=t.classes[0],r=e.classes[0];n===`mbin`&&cn.has(r)?t.classes[0]=`mord`:r===`mbin`&&sn.has(n)&&(e.classes[0]=`mord`)},{node:u},d,f),fn(i,(e,t)=>{var n=hn(t),r=hn(e),i=n&&r?e.hasClass(`mtight`)?en[n]?.[r]:$t[n]?.[r]:null;if(i)return Kt(i,c)},{node:u},d,f),i},fn=function(e,t,n,r,i){r&&e.push(r);for(var a=0;an=>{e.splice(t+1,0,n),a++})(a)}r&&e.pop()},pn=function(e){return e instanceof Se||e instanceof Ne||e instanceof Me&&e.hasClass(`enclosing`)?e:null},mn=function(e,t){var n=pn(e);if(n){var r=n.children;if(r.length){if(t===`right`)return mn(r[r.length-1],`right`);if(t===`left`)return mn(r[0],`left`)}}return e},hn=function(e,t){return e?(t&&(e=mn(e,t)),un[e.classes[0]]||null):null},gn=function(e,t){var n=[`nulldelimiter`].concat(e.baseSizingClasses());return W(t.concat(n))},Y=function(t,n,r){if(!t)return W();if(nn[t.type]){var i=nn[t.type](t,n);if(r&&n.size!==r.size){i=W(n.sizingClasses(r),[i],n);var a=n.sizeMultiplier/r.sizeMultiplier;i.height*=a,i.depth*=a}return i}throw new e(`Got group of unknown type: '`+t.type+`'`)};function _n(e,t){var n=W([`base`],e,t),r=W([`strut`]);return r.style.height=k(n.height+n.depth),n.depth&&(r.style.verticalAlign=k(-n.depth)),n.children.unshift(r),n}function vn(e,t){var n=null;e.length===1&&e[0].type===`tag`&&(n=e[0].tag,e=e[0].body);var r=dn(e,t,`root`),i;r.length===2&&r[1].hasClass(`tag`)&&(i=r.pop());for(var a=[],o=[],s=0;s0&&(a.push(_n(o,t)),o=[]),a.push(r[s]));o.length>0&&a.push(_n(o,t));var l;n?(l=_n(dn(n,t,!0),t),l.classes=[`tag`],a.push(l)):i&&a.push(i);var u=W([`katex-html`],a);if(u.setAttribute(`aria-hidden`,`true`),l){var d=l.children[0];d.style.height=k(u.height+u.depth),u.depth&&(d.style.verticalAlign=k(-u.depth))}return u}function yn(e){return new Se(e)}var X=class{constructor(e,t,n){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=e,this.attributes={},this.children=t||[],this.classes=n||[]}setAttribute(e,t){this.attributes[e]=t}getAttribute(e){return this.attributes[e]}toNode(){var e=document.createElementNS(`http://www.w3.org/1998/Math/MathML`,this.type);for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&e.setAttribute(t,this.attributes[t]);this.classes.length>0&&(e.className=Ee(this.classes));for(var n=0;n0&&(e+=` class ="`+a(Ee(this.classes))+`"`),e+=`>`;for(var n=0;n`,e}toText(){return this.children.map(e=>e.toText()).join(``)}},bn=class{constructor(e){this.text=void 0,this.text=e}toNode(){return document.createTextNode(this.text)}toMarkup(){return a(this.toText())}toText(){return this.text}},xn=class{constructor(e){this.width=void 0,this.character=void 0,this.width=e,this.character=e>=.05555&&e<=.05556?` `:e>=.1666&&e<=.1667?` `:e>=.2222&&e<=.2223?` `:e>=.2777&&e<=.2778?`  `:e>=-.05556&&e<=-.05555?` ⁣`:e>=-.1667&&e<=-.1666?` ⁣`:e>=-.2223&&e<=-.2222?` ⁣`:e>=-.2778&&e<=-.2777?` ⁣`:null}toNode(){if(this.character)return document.createTextNode(this.character);var e=document.createElementNS(`http://www.w3.org/1998/Math/MathML`,`mspace`);return e.setAttribute(`width`,k(this.width)),e}toMarkup(){return this.character?``+this.character+``:``}toText(){return this.character?this.character:` `}},Sn=new Set([`\\imath`,`\\jmath`]),Cn=new Set([`mrow`,`mtable`]),wn=function(e,t,n){return A[t][e]&&A[t][e].replace&&e.charCodeAt(0)!==55349&&!(tt.hasOwnProperty(e)&&n&&(n.fontFamily&&n.fontFamily.slice(4,6)===`tt`||n.font&&n.font.slice(4,6)===`tt`))&&(e=A[t][e].replace),new bn(e)},Tn=function(e){return e.length===1?e[0]:new X(`mrow`,e)},En={mathit:`italic`,boldsymbol:e=>e.type===`textord`?`bold`:`bold-italic`,mathbf:`bold`,mathbb:`double-struck`,mathsfit:`sans-serif-italic`,mathfrak:`fraktur`,mathscr:`script`,mathcal:`script`,mathsf:`sans-serif`,mathtt:`monospace`},Dn=(e,t)=>{if(e.mode===`text`){if(t.fontFamily===`texttt`)return`monospace`;if(t.fontFamily===`textsf`)return t.fontShape===`textit`&&t.fontWeight===`textbf`?`sans-serif-bold-italic`:t.fontShape===`textit`?`sans-serif-italic`:t.fontWeight===`textbf`?`bold-sans-serif`:`sans-serif`;if(t.fontShape===`textit`&&t.fontWeight===`textbf`)return`bold-italic`;if(t.fontShape===`textit`)return`italic`;if(t.fontWeight===`textbf`)return`bold`}var n=t.font;if(!n||n===`mathnormal`)return null;var r=e.mode,i=En[n];if(i)return typeof i==`function`?i(e):i;var a=e.text;if(Sn.has(a))return null;if(A[r][a]){var o=A[r][a].replace;o&&(a=o)}var s=Jt[n].fontName;return qe(a,s,r)?Jt[n].variant:null};function On(e){if(!e)return!1;if(e.type===`mi`&&e.children.length===1){var t=e.children[0];return t instanceof bn&&t.text===`.`}if(e.type===`mo`&&e.children.length===1&&e.getAttribute(`separator`)===`true`&&e.getAttribute(`lspace`)===`0em`&&e.getAttribute(`rspace`)===`0em`){var n=e.children[0];return n instanceof bn&&n.text===`,`}return!1}var kn=function(e,t,n){if(e.length===1){var r=Z(e[0],t);return n&&r instanceof X&&r.type===`mo`&&(r.setAttribute(`lspace`,`0em`),r.setAttribute(`rspace`,`0em`)),[r]}for(var i=[],a,o=0;o=1&&(a.type===`mn`||On(a))){var c=s.children[0];c instanceof X&&c.type===`mn`&&(c.children=[...a.children,...c.children],i.pop())}else if(a.type===`mi`&&a.children.length===1){var l=a.children[0];if(l instanceof bn&&l.text===`̸`&&(s.type===`mo`||s.type===`mi`||s.type===`mn`)){var u=s.children[0];u instanceof bn&&u.text.length>0&&(u.text=u.text.slice(0,1)+`̸`+u.text.slice(1),i.pop())}}}i.push(s),a=s}return i},An=function(e,t,n){return Tn(kn(e,t,n))},Z=function(t,n){if(!t)return new X(`mrow`);if(rn[t.type])return rn[t.type](t,n);throw new e(`Got group of unknown type: '`+t.type+`'`)};function jn(e,t,n,r,i){var a=kn(e,n),o=a.length===1&&a[0]instanceof X&&Cn.has(a[0].type)?a[0]:new X(`mrow`,a),s=new X(`annotation`,[new bn(t)]);s.setAttribute(`encoding`,`application/x-tex`);var c=new X(`math`,[new X(`semantics`,[o,s])]);return c.setAttribute(`xmlns`,`http://www.w3.org/1998/Math/MathML`),r&&c.setAttribute(`display`,`block`),W([i?`katex`:`katex-mathml`],[c])}var Mn=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],Nn=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],Pn=function(e,t){return t.size<2?e:Mn[e-1][t.size-1]},Fn=class e{constructor(t){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=t.style,this.color=t.color,this.size=t.size||e.BASESIZE,this.textSize=t.textSize||this.size,this.phantom=!!t.phantom,this.font=t.font||``,this.fontFamily=t.fontFamily||``,this.fontWeight=t.fontWeight||``,this.fontShape=t.fontShape||``,this.sizeMultiplier=Nn[this.size-1],this.maxSize=t.maxSize,this.minRuleThickness=t.minRuleThickness,this._fontMetrics=void 0}extend(t){var n={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};return Object.assign(n,t),new e(n)}havingStyle(e){return this.style===e?this:this.extend({style:e,size:Pn(this.textSize,e)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(e){return this.size===e&&this.textSize===e?this:this.extend({style:this.style.text(),size:e,textSize:e,sizeMultiplier:Nn[e-1]})}havingBaseStyle(t){t||=this.style.text();var n=Pn(e.BASESIZE,t);return this.size===n&&this.textSize===e.BASESIZE&&this.style===t?this:this.extend({style:t,size:n})}havingBaseSizing(){var e;switch(this.style.id){case 4:case 5:e=3;break;case 6:case 7:e=1;break;default:e=6}return this.extend({style:this.style.text(),size:e})}withColor(e){return this.extend({color:e})}withPhantom(){return this.extend({phantom:!0})}withFont(e){return this.extend({font:e})}withTextFontFamily(e){return this.extend({fontFamily:e,font:``})}withTextFontWeight(e){return this.extend({fontWeight:e,font:``})}withTextFontShape(e){return this.extend({fontShape:e,font:``})}sizingClasses(e){return e.size===this.size?[]:[`sizing`,`reset-size`+e.size,`size`+this.size]}baseSizingClasses(){return this.size===e.BASESIZE?[]:[`sizing`,`reset-size`+this.size,`size`+e.BASESIZE]}fontMetrics(){return this._fontMetrics||=Ye(this.size),this._fontMetrics}getColor(){return this.phantom?`transparent`:this.color}};Fn.BASESIZE=6;var In=function(e){return new Fn({style:e.displayMode?E.DISPLAY:E.TEXT,maxSize:e.maxSize,minRuleThickness:e.minRuleThickness})},Ln=function(e,t){if(t.displayMode){var n=[`katex-display`];t.leqno&&n.push(`leqno`),t.fleqn&&n.push(`fleqn`),e=W(n,[e])}return e},Rn=function(e,t,n){var r=In(n),i;return n.output===`mathml`?jn(e,t,r,n.displayMode,!0):(i=n.output===`html`?W([`katex`],[vn(e,r)]):W([`katex`],[jn(e,t,r,n.displayMode,!1),vn(e,r)]),Ln(i,n))},zn=function(e,t,n){return Ln(W([`katex`],[vn(e,In(n))]),n)},Bn={widehat:`^`,widecheck:`ˇ`,widetilde:`~`,utilde:`~`,overleftarrow:`←`,underleftarrow:`←`,xleftarrow:`←`,overrightarrow:`→`,underrightarrow:`→`,xrightarrow:`→`,underbrace:`⏟`,overbrace:`⏞`,underbracket:`⎵`,overbracket:`⎴`,overgroup:`⏠`,undergroup:`⏡`,overleftrightarrow:`↔`,underleftrightarrow:`↔`,xleftrightarrow:`↔`,Overrightarrow:`⇒`,xRightarrow:`⇒`,overleftharpoon:`↼`,xleftharpoonup:`↼`,overrightharpoon:`⇀`,xrightharpoonup:`⇀`,xLeftarrow:`⇐`,xLeftrightarrow:`⇔`,xhookleftarrow:`↩`,xhookrightarrow:`↪`,xmapsto:`↦`,xrightharpoondown:`⇁`,xleftharpoondown:`↽`,xrightleftharpoons:`⇌`,xleftrightharpoons:`⇋`,xtwoheadleftarrow:`↞`,xtwoheadrightarrow:`↠`,xlongequal:`=`,xtofrom:`⇄`,xrightleftarrows:`⇄`,xrightequilibrium:`⇌`,xleftequilibrium:`⇋`,"\\cdrightarrow":`→`,"\\cdleftarrow":`←`,"\\cdlongequal":`=`},Vn=function(e){var t=new X(`mo`,[new bn(Bn[e.replace(/^\\/,``)])]);return t.setAttribute(`stretchy`,`true`),t},Hn={overrightarrow:[[`rightarrow`],.888,522,`xMaxYMin`],overleftarrow:[[`leftarrow`],.888,522,`xMinYMin`],underrightarrow:[[`rightarrow`],.888,522,`xMaxYMin`],underleftarrow:[[`leftarrow`],.888,522,`xMinYMin`],xrightarrow:[[`rightarrow`],1.469,522,`xMaxYMin`],"\\cdrightarrow":[[`rightarrow`],3,522,`xMaxYMin`],xleftarrow:[[`leftarrow`],1.469,522,`xMinYMin`],"\\cdleftarrow":[[`leftarrow`],3,522,`xMinYMin`],Overrightarrow:[[`doublerightarrow`],.888,560,`xMaxYMin`],xRightarrow:[[`doublerightarrow`],1.526,560,`xMaxYMin`],xLeftarrow:[[`doubleleftarrow`],1.526,560,`xMinYMin`],overleftharpoon:[[`leftharpoon`],.888,522,`xMinYMin`],xleftharpoonup:[[`leftharpoon`],.888,522,`xMinYMin`],xleftharpoondown:[[`leftharpoondown`],.888,522,`xMinYMin`],overrightharpoon:[[`rightharpoon`],.888,522,`xMaxYMin`],xrightharpoonup:[[`rightharpoon`],.888,522,`xMaxYMin`],xrightharpoondown:[[`rightharpoondown`],.888,522,`xMaxYMin`],xlongequal:[[`longequal`],.888,334,`xMinYMin`],"\\cdlongequal":[[`longequal`],3,334,`xMinYMin`],xtwoheadleftarrow:[[`twoheadleftarrow`],.888,334,`xMinYMin`],xtwoheadrightarrow:[[`twoheadrightarrow`],.888,334,`xMaxYMin`],overleftrightarrow:[[`leftarrow`,`rightarrow`],.888,522],overbrace:[[`leftbrace`,`midbrace`,`rightbrace`],1.6,548],underbrace:[[`leftbraceunder`,`midbraceunder`,`rightbraceunder`],1.6,548],underleftrightarrow:[[`leftarrow`,`rightarrow`],.888,522],xleftrightarrow:[[`leftarrow`,`rightarrow`],1.75,522],xLeftrightarrow:[[`doubleleftarrow`,`doublerightarrow`],1.75,560],xrightleftharpoons:[[`leftharpoondownplus`,`rightharpoonplus`],1.75,716],xleftrightharpoons:[[`leftharpoonplus`,`rightharpoondownplus`],1.75,716],xhookleftarrow:[[`leftarrow`,`righthook`],1.08,522],xhookrightarrow:[[`lefthook`,`rightarrow`],1.08,522],overlinesegment:[[`leftlinesegment`,`rightlinesegment`],.888,522],underlinesegment:[[`leftlinesegment`,`rightlinesegment`],.888,522],overbracket:[[`leftbracketover`,`rightbracketover`],1.6,440],underbracket:[[`leftbracketunder`,`rightbracketunder`],1.6,410],overgroup:[[`leftgroup`,`rightgroup`],.888,342],undergroup:[[`leftgroupunder`,`rightgroupunder`],.888,342],xmapsto:[[`leftmapsto`,`rightarrow`],1.5,522],xtofrom:[[`leftToFrom`,`rightToFrom`],1.75,528],xrightleftarrows:[[`baraboveleftarrow`,`rightarrowabovebar`],1.75,901],xrightequilibrium:[[`baraboveshortleftharpoon`,`rightharpoonaboveshortbar`],1.75,716],xleftequilibrium:[[`shortbaraboveleftharpoon`,`shortrightharpoonabovebar`],1.75,716]},Un=new Set([`widehat`,`widecheck`,`widetilde`,`utilde`]),Wn=function(e,t){function n(){var n=4e5,r=e.label.slice(1);if(Un.has(r)&&`base`in e){var i=e.base.type===`ordgroup`?e.base.body.length:1,a,o,s;if(i>5)r===`widehat`||r===`widecheck`?(a=420,n=2364,s=.42,o=r+`4`):(a=312,n=2340,s=.34,o=`tilde4`);else{var c=[1,1,2,2,3,3][i];r===`widehat`||r===`widecheck`?(n=[0,1062,2364,2364,2364][c],a=[0,239,300,360,420][c],s=[0,.24,.3,.3,.36,.42][c],o=r+c):(n=[0,600,1033,2339,2340][c],a=[0,260,286,306,312][c],s=[0,.26,.286,.3,.306,.34][c],o=`tilde`+c)}return{span:Bt([],[new Le([new Re(o)],{width:`100%`,height:k(s),viewBox:`0 0 `+n+` `+a,preserveAspectRatio:`none`})],t),minWidth:0,height:s}}var l=[],u=Hn[r];if(!u)throw Error(`No SVG data for "`+r+`".`);var[d,f,p]=u,m=p/1e3,h=d.length,g,_;if(h===1){if(u.length!==4)throw Error(`Expected 4-tuple for single-path SVG data "`+r+`".`);g=[`hide-tail`],_=[u[3]]}else if(h===2)g=[`halfarrow-left`,`halfarrow-right`],_=[`xMinYMin`,`xMaxYMin`];else if(h===3)g=[`brace-left`,`brace-center`,`brace-right`],_=[`xMinYMin`,`xMidYMin`,`xMaxYMin`];else throw Error(`Correct katexImagesData or update code here to support + `+h+` children.`);for(var v=0;v0&&(r.style.minWidth=k(i)),r},Gn=function(e,t,n,r,i){var a,o=e.height+e.depth+n+r;if(/fbox|color|angl/.test(t)){if(a=W([`stretchy`,t],[],i),t===`fbox`){var s=i.color&&i.getColor();s&&(a.style.borderColor=s)}}else{var c=[];/^[bx]cancel$/.test(t)&&c.push(new ze({x1:`0`,y1:`0`,x2:`100%`,y2:`100%`,"stroke-width":`0.046em`})),/^x?cancel$/.test(t)&&c.push(new ze({x1:`0`,y1:`100%`,x2:`100%`,y2:`0`,"stroke-width":`0.046em`})),a=Bt([],[new Le(c,{width:`100%`,height:k(o)})],i)}return a.height=o,a.style.height=k(o),a},Kn={bin:1,close:1,inner:1,open:1,punct:1,rel:1},qn={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1};function Jn(e){return e in Kn}function Q(e,t){if(!e||e.type!==t)throw Error(`Expected node of type `+t+`, but got `+(e?`node of type `+e.type:String(e)));return e}function Yn(e){var t=Xn(e);if(!t)throw Error(`Expected node of symbol group type, but got `+(e?`node of type `+e.type:String(e)));return t}function Xn(e){return e&&(e.type===`atom`||qn.hasOwnProperty(e.type))?e:null}var Zn=e=>{if(e instanceof Ie)return e;if(He(e)&&e.children.length===1)return Zn(e.children[0])},Qn=(e,t)=>{var n,r,i;e&&e.type===`supsub`?(r=Q(e.base,`accent`),n=r.base,e.base=n,i=Ve(Y(e,t)),e.base=r):(r=Q(e,`accent`),n=r.base);var a=Y(n,t.havingCrampedStyle()),o=r.isShifty&&c(n),s=0;o&&(s=Zn(a)?.skew??0);var l=r.label===`\\c`,u=l?a.height+a.depth:Math.min(a.height,t.fontMetrics().xHeight),d;if(r.isStretchy)d=Wn(r,t),d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`elem`,elem:d,wrapperClasses:[`svg-align`],wrapperStyle:s>0?{width:`calc(100% - `+k(2*s)+`)`,marginLeft:k(2*s)}:void 0}]});else{var f,p;r.label===`\\vec`?(f=Xt(`vec`,t),p=Yt.vec[1]):(f=It({type:`textord`,mode:r.mode,text:r.label},t,`textord`),f=Be(f),f.italic=0,p=f.width,l&&(u+=f.depth)),d=W([`accent-body`],[f]);var m=r.label===`\\textcircled`;m&&(d.classes.push(`accent-full`),u=a.height);var h=s;m||(h-=p/2),d.style.left=k(h),r.label===`\\textcircled`&&(d.style.top=`.2em`),d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`kern`,size:-u},{type:`elem`,elem:d}]})}var g=W([`mord`,`accent`],[d],t);return i?(i.children[0]=g,i.height=Math.max(g.height,i.height),i.classes[0]=`mord`,i):g},$n=(e,t)=>{var n=e.isStretchy?Vn(e.label):new X(`mo`,[wn(e.label,e.mode)]),r=new X(`mover`,[Z(e.base,t),n]);return r.setAttribute(`accent`,`true`),r},er=new RegExp([`\\acute`,`\\grave`,`\\ddot`,`\\tilde`,`\\bar`,`\\breve`,`\\check`,`\\hat`,`\\vec`,`\\dot`,`\\mathring`].map(e=>`\\`+e).join(`|`));q({type:`accent`,names:[`\\acute`,`\\grave`,`\\ddot`,`\\tilde`,`\\bar`,`\\breve`,`\\check`,`\\hat`,`\\vec`,`\\dot`,`\\mathring`,`\\widecheck`,`\\widehat`,`\\widetilde`,`\\overrightarrow`,`\\overleftarrow`,`\\Overrightarrow`,`\\overleftrightarrow`,`\\overgroup`,`\\overlinesegment`,`\\overleftharpoon`,`\\overrightharpoon`],props:{numArgs:1},handler:(e,t)=>{var n=on(t[0]),r=!er.test(e.funcName),i=!r||e.funcName===`\\widehat`||e.funcName===`\\widetilde`||e.funcName===`\\widecheck`;return{type:`accent`,mode:e.parser.mode,label:e.funcName,isStretchy:r,isShifty:i,base:n}},htmlBuilder:Qn,mathmlBuilder:$n}),q({type:`accent`,names:[`\\'`,"\\`",`\\^`,`\\~`,`\\=`,`\\u`,`\\.`,`\\"`,`\\c`,`\\r`,`\\H`,`\\v`,`\\textcircled`],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:[`primitive`]},handler:(e,t)=>{var n=t[0],r=e.parser.mode;return r===`math`&&(e.parser.settings.reportNonstrict(`mathVsTextAccents`,`LaTeX's accent `+e.funcName+` works only in text mode`),r=`text`),{type:`accent`,mode:r,label:e.funcName,isStretchy:!1,isShifty:!0,base:n}},htmlBuilder:Qn,mathmlBuilder:$n}),q({type:`accentUnder`,names:[`\\underleftarrow`,`\\underrightarrow`,`\\underleftrightarrow`,`\\undergroup`,`\\underlinesegment`,`\\utilde`],props:{numArgs:1},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0];return{type:`accentUnder`,mode:n.mode,label:r,base:i}},htmlBuilder:(e,t)=>{var n=Y(e.base,t),r=Wn(e,t),i=e.label===`\\utilde`?.12:0;return W([`mord`,`accentunder`],[G({positionType:`top`,positionData:n.height,children:[{type:`elem`,elem:r,wrapperClasses:[`svg-align`]},{type:`kern`,size:i},{type:`elem`,elem:n}]})],t)},mathmlBuilder:(e,t)=>{var n=Vn(e.label),r=new X(`munder`,[Z(e.base,t),n]);return r.setAttribute(`accentunder`,`true`),r}});var tr=e=>{var t=new X(`mpadded`,e?[e]:[]);return t.setAttribute(`width`,`+0.6em`),t.setAttribute(`lspace`,`0.3em`),t};q({type:`xArrow`,names:[`\\xleftarrow`,`\\xrightarrow`,`\\xLeftarrow`,`\\xRightarrow`,`\\xleftrightarrow`,`\\xLeftrightarrow`,`\\xhookleftarrow`,`\\xhookrightarrow`,`\\xmapsto`,`\\xrightharpoondown`,`\\xrightharpoonup`,`\\xleftharpoondown`,`\\xleftharpoonup`,`\\xrightleftharpoons`,`\\xleftrightharpoons`,`\\xlongequal`,`\\xtwoheadrightarrow`,`\\xtwoheadleftarrow`,`\\xtofrom`,`\\xrightleftarrows`,`\\xrightequilibrium`,`\\xleftequilibrium`,`\\\\cdrightarrow`,`\\\\cdleftarrow`,`\\\\cdlongequal`],props:{numArgs:1,numOptionalArgs:1},handler(e,t,n){var{parser:r,funcName:i}=e;return{type:`xArrow`,mode:r.mode,label:i,body:t[0],below:n[0]}},htmlBuilder(e,t){var n=t.style,r=t.havingStyle(n.sup()),i=Wt(Y(e.body,r,t),t),a=e.label.slice(0,2)===`\\x`?`x`:`cd`;i.classes.push(a+`-arrow-pad`);var o;e.below&&(r=t.havingStyle(n.sub()),o=Wt(Y(e.below,r,t),t),o.classes.push(a+`-arrow-pad`));var s=Wn(e,t),c=-t.fontMetrics().axisHeight+.5*s.height,l=-t.fontMetrics().axisHeight-.5*s.height-.111;(i.depth>.25||e.label===`\\xleftequilibrium`)&&(l-=i.depth);var u;if(o){var d=-t.fontMetrics().axisHeight+o.height+.5*s.height+.111;u=G({positionType:`individualShift`,children:[{type:`elem`,elem:i,shift:l},{type:`elem`,elem:s,shift:c,wrapperClasses:[`svg-align`]},{type:`elem`,elem:o,shift:d}]})}else u=G({positionType:`individualShift`,children:[{type:`elem`,elem:i,shift:l},{type:`elem`,elem:s,shift:c,wrapperClasses:[`svg-align`]}]});return W([`mrel`,`x-arrow`],[u],t)},mathmlBuilder(e,t){var n=Vn(e.label);n.setAttribute(`minsize`,e.label.charAt(0)===`x`?`1.75em`:`3.0em`);var r;if(e.body){var i=tr(Z(e.body,t));r=e.below?new X(`munderover`,[n,tr(Z(e.below,t)),i]):new X(`mover`,[n,i])}else e.below?r=new X(`munder`,[n,tr(Z(e.below,t))]):(r=tr(),r=new X(`mover`,[n,r]));return r}});function nr(e,t){var n=dn(e.body,t,!0);return W([e.mclass],n,t)}function rr(e,t){var n,r=kn(e.body,t);return e.mclass===`minner`?n=new X(`mpadded`,r):e.mclass===`mord`?e.isCharacterBox?(n=r[0],n.type=`mi`):n=new X(`mi`,r):(e.isCharacterBox?(n=r[0],n.type=`mo`):n=new X(`mo`,r),e.mclass===`mbin`?(n.attributes.lspace=`0.22em`,n.attributes.rspace=`0.22em`):e.mclass===`mpunct`?(n.attributes.lspace=`0em`,n.attributes.rspace=`0.17em`):e.mclass===`mopen`||e.mclass===`mclose`?(n.attributes.lspace=`0em`,n.attributes.rspace=`0em`):e.mclass===`minner`&&(n.attributes.lspace=`0.0556em`,n.attributes.width=`+0.1111em`)),n}q({type:`mclass`,names:[`\\mathord`,`\\mathbin`,`\\mathrel`,`\\mathopen`,`\\mathclose`,`\\mathpunct`,`\\mathinner`],props:{numArgs:1,primitive:!0},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`mclass`,mode:n.mode,mclass:`m`+r.slice(5),body:J(i),isCharacterBox:c(i)}},htmlBuilder:nr,mathmlBuilder:rr});var ir=e=>{var t=e.type===`ordgroup`&&e.body.length?e.body[0]:e;return t.type===`atom`&&(t.family===`bin`||t.family===`rel`)?`m`+t.family:`mord`};q({type:`mclass`,names:[`\\@binrel`],props:{numArgs:2},handler(e,t){var{parser:n}=e;return{type:`mclass`,mode:n.mode,mclass:ir(t[0]),body:J(t[1]),isCharacterBox:c(t[1])}}}),q({type:`mclass`,names:[`\\stackrel`,`\\overset`,`\\underset`],props:{numArgs:2},handler(e,t){var{parser:n,funcName:r}=e,i=t[1],a=t[0],o=r===`\\stackrel`?`mrel`:ir(i),s={type:`op`,mode:i.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:r!==`\\stackrel`,body:J(i)},l={type:`supsub`,mode:a.mode,base:s,sup:r===`\\underset`?null:a,sub:r===`\\underset`?a:null};return{type:`mclass`,mode:n.mode,mclass:o,body:[l],isCharacterBox:c(l)}},htmlBuilder:nr,mathmlBuilder:rr}),q({type:`pmb`,names:[`\\pmb`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`pmb`,mode:n.mode,mclass:ir(t[0]),body:J(t[0])}},htmlBuilder(e,t){var n=dn(e.body,t,!0),r=W([e.mclass],n,t);return r.style.textShadow=`0.02em 0.01em 0.04px`,r},mathmlBuilder(e,t){var n=new X(`mstyle`,kn(e.body,t));return n.setAttribute(`style`,`text-shadow: 0.02em 0.01em 0.04px`),n}});var ar={">":`\\\\cdrightarrow`,"<":`\\\\cdleftarrow`,"=":`\\\\cdlongequal`,A:`\\uparrow`,V:`\\downarrow`,"|":`\\Vert`,".":`no arrow`},or=()=>({type:`styling`,body:[],mode:`math`,style:`display`,resetFont:!0}),sr=e=>e.type===`textord`&&e.text===`@`,cr=(e,t)=>(e.type===`mathord`||e.type===`atom`)&&e.text===t;function lr(e,t,n){var r=ar[e];switch(r){case`\\\\cdrightarrow`:case`\\\\cdleftarrow`:return n.callFunction(r,[t[0]],[t[1]]);case`\\uparrow`:case`\\downarrow`:var i=n.callFunction(`\\\\cdleft`,[t[0]],[]),a={type:`atom`,text:r,mode:`math`,family:`rel`},o={type:`ordgroup`,mode:`math`,body:[i,n.callFunction(`\\Big`,[a],[]),n.callFunction(`\\\\cdright`,[t[1]],[])]};return n.callFunction(`\\\\cdparent`,[o],[]);case`\\\\cdlongequal`:return n.callFunction(`\\\\cdlongequal`,[],[]);case`\\Vert`:return n.callFunction(`\\Big`,[{type:`textord`,text:`\\Vert`,mode:`math`}],[]);default:return{type:`textord`,text:` `,mode:`math`}}}function ur(t){var n=[];for(t.gullet.beginGroup(),t.gullet.macros.set(`\\cr`,`\\\\\\relax`),t.gullet.beginGroup();;){n.push(t.parseExpression(!1,`\\\\`)),t.gullet.endGroup(),t.gullet.beginGroup();var r=t.fetch().text;if(r===`&`||r===`\\\\`)t.consume();else if(r===`\\end`){n[n.length-1].length===0&&n.pop();break}else throw new e(`Expected \\\\ or \\cr or \\end`,t.nextToken)}for(var i=[],a=[i],o=0;oAV`.includes(u))for(var f=0;f<2;f++){for(var p=!0,m=l+1;mAV=|." after @`,s[l])}var h={type:`styling`,body:[lr(u,d,t)],mode:`math`,style:`display`,resetFont:!0};i.push(h),c=or()}o%2==0?i.push(c):i.shift(),i=[],a.push(i)}return t.gullet.endGroup(),t.gullet.endGroup(),{type:`array`,mode:`math`,body:a,arraystretch:1,addJot:!0,rowGaps:[null],cols:Array(a[0].length).fill({type:`align`,align:`c`,pregap:.25,postgap:.25}),colSeparationType:`CD`,hLinesBeforeRow:Array(a.length+1).fill([])}}q({type:`cdlabel`,names:[`\\\\cdleft`,`\\\\cdright`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e;return{type:`cdlabel`,mode:n.mode,side:r.slice(4),label:t[0]}},htmlBuilder(e,t){var n=t.havingStyle(t.style.sup()),r=Wt(Y(e.label,n,t),t);return r.classes.push(`cd-label-`+e.side),r.style.bottom=k(.8-r.depth),r.height=0,r.depth=0,r},mathmlBuilder(e,t){var n=new X(`mrow`,[Z(e.label,t)]);return n=new X(`mpadded`,[n]),n.setAttribute(`width`,`0`),e.side===`left`&&n.setAttribute(`lspace`,`-1width`),n.setAttribute(`voffset`,`0.7em`),n=new X(`mstyle`,[n]),n.setAttribute(`displaystyle`,`false`),n.setAttribute(`scriptlevel`,`1`),n}}),q({type:`cdlabelparent`,names:[`\\\\cdparent`],props:{numArgs:1},handler(e,t){var{parser:n}=e;return{type:`cdlabelparent`,mode:n.mode,fragment:t[0]}},htmlBuilder(e,t){var n=Wt(Y(e.fragment,t),t);return n.classes.push(`cd-vert-arrow`),n},mathmlBuilder(e,t){return new X(`mrow`,[Z(e.fragment,t)])}}),q({type:`textord`,names:[`\\@char`],props:{numArgs:1,allowedInText:!0},handler(t,n){for(var{parser:r}=t,i=Q(n[0],`ordgroup`).body,a=``,o=0;o=1114111)throw new e(`\\@char with invalid code point `+a);return c<=65535?l=String.fromCharCode(c):(c-=65536,l=String.fromCharCode((c>>10)+55296,(c&1023)+56320)),{type:`textord`,mode:r.mode,text:l}}});var dr=(e,t)=>Ut(dn(e.body,t.withColor(e.color),!1)),fr=(e,t)=>{var n=new X(`mstyle`,kn(e.body,t.withColor(e.color)));return n.setAttribute(`mathcolor`,e.color),n};q({type:`color`,names:[`\\textcolor`],props:{numArgs:2,allowedInText:!0,argTypes:[`color`,`original`]},handler(e,t){var{parser:n}=e,r=Q(t[0],`color-token`).color,i=t[1];return{type:`color`,mode:n.mode,color:r,body:J(i)}},htmlBuilder:dr,mathmlBuilder:fr}),q({type:`color`,names:[`\\color`],props:{numArgs:1,allowedInText:!0,argTypes:[`color`]},handler(e,t){var{parser:n,breakOnTokenText:r}=e,i=Q(t[0],`color-token`).color;n.gullet.macros.set(`\\current@color`,i);var a=n.parseExpression(!0,r);return{type:`color`,mode:n.mode,color:i,body:a}},htmlBuilder:dr,mathmlBuilder:fr}),q({type:`cr`,names:[`\\\\`],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(e,t,n){var{parser:r}=e,i=r.gullet.future().text===`[`?r.parseSizeGroup(!0):null,a=!r.settings.displayMode||!r.settings.useStrictBehavior(`newLineInDisplayMode`,`In LaTeX, \\\\ or \\newline does nothing in display mode`);return{type:`cr`,mode:r.mode,newLine:a,size:i&&Q(i,`size`).value}},htmlBuilder(e,t){var n=W([`mspace`],[],t);return e.newLine&&(n.classes.push(`newline`),e.size&&(n.style.marginTop=k(O(e.size,t)))),n},mathmlBuilder(e,t){var n=new X(`mspace`);return e.newLine&&(n.setAttribute(`linebreak`,`newline`),e.size&&n.setAttribute(`height`,k(O(e.size,t)))),n}});var pr={"\\global":`\\global`,"\\long":`\\\\globallong`,"\\\\globallong":`\\\\globallong`,"\\def":`\\gdef`,"\\gdef":`\\gdef`,"\\edef":`\\xdef`,"\\xdef":`\\xdef`,"\\let":`\\\\globallet`,"\\futurelet":`\\\\globalfuture`},mr=t=>{var n=t.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(n))throw new e(`Expected a control sequence`,t);return n},hr=e=>{var t=e.gullet.popToken();return t.text===`=`&&(t=e.gullet.popToken(),t.text===` `&&(t=e.gullet.popToken())),t},gr=(e,t,n,r)=>{var i=e.gullet.macros.get(n.text);i??=(n.noexpand=!0,{tokens:[n],numArgs:0,unexpandable:!e.gullet.isExpandable(n.text)}),e.gullet.macros.set(t,i,r)};q({type:`internal`,names:[`\\global`,`\\long`,`\\\\globallong`],props:{numArgs:0,allowedInText:!0},handler(t){var{parser:n,funcName:r}=t;n.consumeSpaces();var i=n.fetch();if(pr[i.text])return(r===`\\global`||r===`\\\\globallong`)&&(i.text=pr[i.text]),Q(n.parseFunction(),`internal`);throw new e(`Invalid token after macro prefix`,i)}}),q({type:`internal`,names:[`\\def`,`\\gdef`,`\\edef`,`\\xdef`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:n,funcName:r}=t,i=n.gullet.popToken(),a=i.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(a))throw new e(`Expected a control sequence`,i);for(var o=0,s,c=[[]];n.gullet.future().text!==`{`;)if(i=n.gullet.popToken(),i.text===`#`){if(n.gullet.future().text===`{`){s=n.gullet.future(),c[o].push(`{`);break}if(i=n.gullet.popToken(),!/^[1-9]$/.test(i.text))throw new e(`Invalid argument number "`+i.text+`"`);if(parseInt(i.text)!==o+1)throw new e(`Argument number "`+i.text+`" out of order`);o++,c.push([])}else if(i.text===`EOF`)throw new e(`Expected a macro definition`);else c[o].push(i.text);var{tokens:l}=n.gullet.consumeArg();return s&&l.unshift(s),(r===`\\edef`||r===`\\xdef`)&&(l=n.gullet.expandTokens(l),l.reverse()),n.gullet.macros.set(a,{tokens:l,numArgs:o,delimiters:c},r===pr[r]),{type:`internal`,mode:n.mode}}}),q({type:`internal`,names:[`\\let`,`\\\\globallet`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:n}=e,r=mr(t.gullet.popToken());return t.gullet.consumeSpaces(),gr(t,r,hr(t),n===`\\\\globallet`),{type:`internal`,mode:t.mode}}}),q({type:`internal`,names:[`\\futurelet`,`\\\\globalfuture`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:n}=e,r=mr(t.gullet.popToken()),i=t.gullet.popToken(),a=t.gullet.popToken();return gr(t,r,a,n===`\\\\globalfuture`),t.gullet.pushToken(a),t.gullet.pushToken(i),{type:`internal`,mode:t.mode}}});var _r=function(e,t,n){var r=qe(A.math[e]&&A.math[e].replace||e,t,n);if(!r)throw Error(`Unsupported symbol `+e+` and font size `+t+`.`);return r},vr=function(e,t,n,r){var i=n.havingBaseStyle(t),a=W(r.concat(i.sizingClasses(n)),[e],n),o=i.sizeMultiplier/n.sizeMultiplier;return a.height*=o,a.depth*=o,a.maxFontSize=i.sizeMultiplier,a},yr=function(e,t,n){var r=t.havingBaseStyle(n),i=(1-t.sizeMultiplier/r.sizeMultiplier)*t.fontMetrics().axisHeight;e.classes.push(`delimcenter`),e.style.top=k(i),e.height-=i,e.depth+=i},br=function(e,t,n,r,i,a){var o=vr(Nt(e,`Main-Regular`,i,r),t,r,a);return n&&yr(o,r,t),o},xr=function(e,t,n,r){return Nt(e,`Size`+t+`-Regular`,n,r)},Sr=function(e,t,n,r,i,a){var o=xr(e,t,i,r),s=vr(W([`delimsizing`,`size`+t],[o],r),E.TEXT,r,a);return n&&yr(s,r,E.TEXT),s},Cr=function(e,t,n){return{type:`elem`,elem:W([`delimsizinginner`,t===`Size1-Regular`?`delim-size1`:`delim-size4`],[W([],[Nt(e,t,n)])])}},wr=function(e,t,n){var r=Ue[`Size4-Regular`][e.charCodeAt(0)]?Ue[`Size4-Regular`][e.charCodeAt(0)][4]:Ue[`Size1-Regular`][e.charCodeAt(0)][4],i=Bt([],[new Le([new Re(`inner`,ve(e,Math.round(1e3*t)))],{width:k(r),height:k(t),style:`width:`+k(r),viewBox:`0 0 `+1e3*r+` `+Math.round(1e3*t),preserveAspectRatio:`xMinYMin`})],n);return i.height=t,i.style.height=k(t),i.style.width=k(r),{type:`elem`,elem:i}},Tr=.008,Er={type:`kern`,size:-1*Tr},Dr=new Set([`|`,`\\lvert`,`\\rvert`,`\\vert`]),Or=new Set([`\\|`,`\\lVert`,`\\rVert`,`\\Vert`]),kr=function(e,t,n,r,i,a){var o,s,c,l,u=``,d=0;o=c=l=e,s=null;var f=`Size1-Regular`;e===`\\uparrow`?c=l=`⏐`:e===`\\Uparrow`?c=l=`‖`:e===`\\downarrow`?o=c=`⏐`:e===`\\Downarrow`?o=c=`‖`:e===`\\updownarrow`?(o=`\\uparrow`,c=`⏐`,l=`\\downarrow`):e===`\\Updownarrow`?(o=`\\Uparrow`,c=`‖`,l=`\\Downarrow`):Dr.has(e)?(c=`∣`,u=`vert`,d=333):Or.has(e)?(c=`∥`,u=`doublevert`,d=556):e===`[`||e===`\\lbrack`?(o=`⎡`,c=`⎢`,l=`⎣`,f=`Size4-Regular`,u=`lbrack`,d=667):e===`]`||e===`\\rbrack`?(o=`⎤`,c=`⎥`,l=`⎦`,f=`Size4-Regular`,u=`rbrack`,d=667):e===`\\lfloor`||e===`⌊`?(c=o=`⎢`,l=`⎣`,f=`Size4-Regular`,u=`lfloor`,d=667):e===`\\lceil`||e===`⌈`?(o=`⎡`,c=l=`⎢`,f=`Size4-Regular`,u=`lceil`,d=667):e===`\\rfloor`||e===`⌋`?(c=o=`⎥`,l=`⎦`,f=`Size4-Regular`,u=`rfloor`,d=667):e===`\\rceil`||e===`⌉`?(o=`⎤`,c=l=`⎥`,f=`Size4-Regular`,u=`rceil`,d=667):e===`(`||e===`\\lparen`?(o=`⎛`,c=`⎜`,l=`⎝`,f=`Size4-Regular`,u=`lparen`,d=875):e===`)`||e===`\\rparen`?(o=`⎞`,c=`⎟`,l=`⎠`,f=`Size4-Regular`,u=`rparen`,d=875):e===`\\{`||e===`\\lbrace`?(o=`⎧`,s=`⎨`,l=`⎩`,c=`⎪`,f=`Size4-Regular`):e===`\\}`||e===`\\rbrace`?(o=`⎫`,s=`⎬`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):e===`\\lgroup`||e===`⟮`?(o=`⎧`,l=`⎩`,c=`⎪`,f=`Size4-Regular`):e===`\\rgroup`||e===`⟯`?(o=`⎫`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):e===`\\lmoustache`||e===`⎰`?(o=`⎧`,l=`⎭`,c=`⎪`,f=`Size4-Regular`):(e===`\\rmoustache`||e===`⎱`)&&(o=`⎫`,l=`⎩`,c=`⎪`,f=`Size4-Regular`);var p=_r(o,f,i),m=p.height+p.depth,h=_r(c,f,i),g=h.height+h.depth,_=_r(l,f,i),v=_.height+_.depth,y=0,b=1;if(s!==null){var x=_r(s,f,i);y=x.height+x.depth,b=2}var S=m+v+y,C=S+Math.max(0,Math.ceil((t-S)/(b*g)))*b*g,w=r.fontMetrics().axisHeight;n&&(w*=r.sizeMultiplier);var ee=C/2-w,T=[];if(u.length>0){var te=C-m-v,ne=Math.round(C*1e3),re=be(u,Math.round(te*1e3)),ie=new Re(u,re),ae=k(d/1e3),oe=k(ne/1e3),se=Bt([],[new Le([ie],{width:ae,height:oe,viewBox:`0 0 `+d+` `+ne})],r);se.height=ne/1e3,se.style.width=ae,se.style.height=oe,T.push({type:`elem`,elem:se})}else{if(T.push(Cr(l,f,i)),T.push(Er),s===null){var ce=C-m-v+2*Tr;T.push(wr(c,ce,r))}else{var D=(C-m-v-y)/2+2*Tr;T.push(wr(c,D,r)),T.push(Er),T.push(Cr(s,f,i)),T.push(Er),T.push(wr(c,D,r))}T.push(Er),T.push(Cr(o,f,i))}var le=r.havingBaseStyle(E.TEXT);return vr(W([`delimsizing`,`mult`],[G({positionType:`bottom`,positionData:ee,children:T})],le),E.TEXT,r,a)},Ar=80,jr=.08,Mr=function(e,t,n,r,i){return Bt([`hide-tail`],[new Le([new Re(e,_e(e,r,n))],{width:`400em`,height:k(t),viewBox:`0 0 400000 `+n,preserveAspectRatio:`xMinYMin slice`})],i)},Nr=function(e,t){var n=t.havingBaseSizing(),r=Ur(`\\surd`,e*n.sizeMultiplier,Vr,n),i=n.sizeMultiplier,a=Math.max(0,t.minRuleThickness-t.fontMetrics().sqrtRuleThickness),o,s,c,l,u;return r.type===`small`?(l=1e3+1e3*a+Ar,e<1?i=1:e<1.4&&(i=.7),s=(1+a+jr)/i,c=(1+a)/i,o=Mr(`sqrtMain`,s,l,a,t),o.style.minWidth=`0.853em`,u=.833/i):r.type===`large`?(l=(1e3+Ar)*Lr[r.size],c=(Lr[r.size]+a)/i,s=(Lr[r.size]+a+jr)/i,o=Mr(`sqrtSize`+r.size,s,l,a,t),o.style.minWidth=`1.02em`,u=1/i):(s=e+a+jr,c=e+a,l=Math.floor(1e3*e+a)+Ar,o=Mr(`sqrtTall`,s,l,a,t),o.style.minWidth=`0.742em`,u=1.056),o.height=c,o.style.height=k(s),{span:o,advanceWidth:u,ruleWidth:(t.fontMetrics().sqrtRuleThickness+a)*i}},Pr=new Set([`(`,`\\lparen`,`)`,`\\rparen`,`[`,`\\lbrack`,`]`,`\\rbrack`,`\\{`,`\\lbrace`,`\\}`,`\\rbrace`,`\\lfloor`,`\\rfloor`,`⌊`,`⌋`,`\\lceil`,`\\rceil`,`⌈`,`⌉`,`\\surd`]),Fr=new Set([`\\uparrow`,`\\downarrow`,`\\updownarrow`,`\\Uparrow`,`\\Downarrow`,`\\Updownarrow`,`|`,`\\|`,`\\vert`,`\\Vert`,`\\lvert`,`\\rvert`,`\\lVert`,`\\rVert`,`\\lgroup`,`\\rgroup`,`⟮`,`⟯`,`\\lmoustache`,`\\rmoustache`,`⎰`,`⎱`]),Ir=new Set([`<`,`>`,`\\langle`,`\\rangle`,`/`,`\\backslash`,`\\lt`,`\\gt`]),Lr=[0,1.2,1.8,2.4,3],Rr=function(t,n,r,i,a){if(t===`<`||t===`\\lt`||t===`⟨`?t=`\\langle`:(t===`>`||t===`\\gt`||t===`⟩`)&&(t=`\\rangle`),Pr.has(t)||Ir.has(t))return Sr(t,n,!1,r,i,a);if(Fr.has(t))return kr(t,Lr[n],!1,r,i,a);throw new e(`Illegal delimiter: '`+t+`'`)},zr=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`large`,size:1},{type:`large`,size:2},{type:`large`,size:3},{type:`large`,size:4}],Br=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`stack`}],Vr=[{type:`small`,style:E.SCRIPTSCRIPT},{type:`small`,style:E.SCRIPT},{type:`small`,style:E.TEXT},{type:`large`,size:1},{type:`large`,size:2},{type:`large`,size:3},{type:`large`,size:4},{type:`stack`}],Hr=function(e){if(e.type===`small`)return`Main-Regular`;if(e.type===`large`)return`Size`+e.size+`-Regular`;if(e.type===`stack`)return`Size4-Regular`;var t=e.type;throw Error(`Add support for delim type '`+t+`' here.`)},Ur=function(e,t,n,r){for(var i=Math.min(2,3-r.style.size);it)return a}return n[n.length-1]},Wr=function(e,t,n,r,i,a){e===`<`||e===`\\lt`||e===`⟨`?e=`\\langle`:(e===`>`||e===`\\gt`||e===`⟩`)&&(e=`\\rangle`);var o=Ir.has(e)?zr:Pr.has(e)?Vr:Br,s=Ur(e,t,o,r);return s.type===`small`?br(e,s.style,n,r,i,a):s.type===`large`?Sr(e,s.size,n,r,i,a):kr(e,t,n,r,i,a)},Gr=function(e,t,n,r,i,a){var o=r.fontMetrics().axisHeight*r.sizeMultiplier,s=901,c=5/r.fontMetrics().ptPerEm,l=Math.max(t-o,n+o);return Wr(e,Math.max(l/500*s,2*l-c),!0,r,i,a)},Kr={"\\bigl":{mclass:`mopen`,size:1},"\\Bigl":{mclass:`mopen`,size:2},"\\biggl":{mclass:`mopen`,size:3},"\\Biggl":{mclass:`mopen`,size:4},"\\bigr":{mclass:`mclose`,size:1},"\\Bigr":{mclass:`mclose`,size:2},"\\biggr":{mclass:`mclose`,size:3},"\\Biggr":{mclass:`mclose`,size:4},"\\bigm":{mclass:`mrel`,size:1},"\\Bigm":{mclass:`mrel`,size:2},"\\biggm":{mclass:`mrel`,size:3},"\\Biggm":{mclass:`mrel`,size:4},"\\big":{mclass:`mord`,size:1},"\\Big":{mclass:`mord`,size:2},"\\bigg":{mclass:`mord`,size:3},"\\Bigg":{mclass:`mord`,size:4}},qr=new Set(`(,\\lparen,),\\rparen,[,\\lbrack,],\\rbrack,\\{,\\lbrace,\\},\\rbrace,\\lfloor,\\rfloor,⌊,⌋,\\lceil,\\rceil,⌈,⌉,<,>,\\langle,⟨,\\rangle,⟩,\\lt,\\gt,\\lvert,\\rvert,\\lVert,\\rVert,\\lgroup,\\rgroup,⟮,⟯,\\lmoustache,\\rmoustache,⎰,⎱,/,\\backslash,|,\\vert,\\|,\\Vert,\\uparrow,\\Uparrow,\\downarrow,\\Downarrow,\\updownarrow,\\Updownarrow,.`.split(`,`));function Jr(e){return`isMiddle`in e}function Yr(t,n){var r=Xn(t);if(r&&qr.has(r.text))return r;throw r?new e(`Invalid delimiter '`+r.text+`' after '`+n.funcName+`'`,t):new e(`Invalid delimiter type '`+t.type+`'`,t)}q({type:`delimsizing`,names:[`\\bigl`,`\\Bigl`,`\\biggl`,`\\Biggl`,`\\bigr`,`\\Bigr`,`\\biggr`,`\\Biggr`,`\\bigm`,`\\Bigm`,`\\biggm`,`\\Biggm`,`\\big`,`\\Big`,`\\bigg`,`\\Bigg`],props:{numArgs:1,argTypes:[`primitive`]},handler:(e,t)=>{var n=Yr(t[0],e);return{type:`delimsizing`,mode:e.parser.mode,size:Kr[e.funcName].size,mclass:Kr[e.funcName].mclass,delim:n.text}},htmlBuilder:(e,t)=>e.delim===`.`?W([e.mclass]):Rr(e.delim,e.size,t,e.mode,[e.mclass]),mathmlBuilder:e=>{var t=[];e.delim!==`.`&&t.push(wn(e.delim,e.mode));var n=new X(`mo`,t);e.mclass===`mopen`||e.mclass===`mclose`?n.setAttribute(`fence`,`true`):n.setAttribute(`fence`,`false`),n.setAttribute(`stretchy`,`true`);var r=k(Lr[e.size]);return n.setAttribute(`minsize`,r),n.setAttribute(`maxsize`,r),n}});function Xr(e){if(!e.body)throw Error(`Bug: The leftright ParseNode wasn't fully parsed.`)}q({type:`leftright-right`,names:[`\\right`],props:{numArgs:1,primitive:!0},handler:(t,n)=>{var r=t.parser.gullet.macros.get(`\\current@color`);if(r&&typeof r!=`string`)throw new e(`\\current@color set to non-string in \\right`);return{type:`leftright-right`,mode:t.parser.mode,delim:Yr(n[0],t).text,color:r}}}),q({type:`leftright`,names:[`\\left`],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var n=Yr(t[0],e),r=e.parser;++r.leftrightDepth;var i=r.parseExpression(!1);--r.leftrightDepth,r.expect(`\\right`,!1);var a=Q(r.parseFunction(),`leftright-right`);return{type:`leftright`,mode:r.mode,body:i,left:n.text,right:a.delim,rightColor:a.color}},htmlBuilder:(e,t)=>{Xr(e);for(var n=dn(e.body,t,!0,[`mopen`,`mclose`]),r=0,i=0,a=!1,o=0;o{Xr(e);var n=kn(e.body,t);if(e.left!==`.`){var r=new X(`mo`,[wn(e.left,e.mode)]);r.setAttribute(`fence`,`true`),n.unshift(r)}if(e.right!==`.`){var i=new X(`mo`,[wn(e.right,e.mode)]);i.setAttribute(`fence`,`true`),e.rightColor&&i.setAttribute(`mathcolor`,e.rightColor),n.push(i)}return Tn(n)}}),q({type:`middle`,names:[`\\middle`],props:{numArgs:1,primitive:!0},handler:(t,n)=>{var r=Yr(n[0],t);if(!t.parser.leftrightDepth)throw new e(`\\middle without preceding \\left`,r);return{type:`middle`,mode:t.parser.mode,delim:r.text}},htmlBuilder:(e,t)=>{var n;return e.delim===`.`?n=gn(t,[]):(n=Rr(e.delim,1,t,e.mode,[]),n.isMiddle={delim:e.delim,options:t}),n},mathmlBuilder:(e,t)=>{var n=new X(`mo`,[e.delim===`\\vert`||e.delim===`|`?wn(`|`,`text`):wn(e.delim,e.mode)]);return n.setAttribute(`fence`,`true`),n.setAttribute(`lspace`,`0.05em`),n.setAttribute(`rspace`,`0.05em`),n}});var Zr=(e,t)=>{var n=Wt(Y(e.body,t),t),r=e.label.slice(1),i=t.sizeMultiplier,a,o,s=c(e.body);if(r===`sout`)a=W([`stretchy`,`sout`]),a.height=t.fontMetrics().defaultRuleThickness/i,o=-.5*t.fontMetrics().xHeight;else if(r===`phase`){var l=O({number:.6,unit:`pt`},t),u=O({number:.35,unit:`ex`},t),d=t.havingBaseSizing();i/=d.sizeMultiplier;var f=n.height+n.depth+l+u;n.style.paddingLeft=k(f/2+l);var p=Math.floor(1e3*f*i);a=Bt([`hide-tail`],[new Le([new Re(`phase`,he(p))],{width:`400em`,height:k(p/1e3),viewBox:`0 0 400000 `+p,preserveAspectRatio:`xMinYMin slice`})],t),a.style.height=k(f),o=n.depth+l+u}else{/cancel/.test(r)?s||n.classes.push(`cancel-pad`):r===`angl`?n.classes.push(`anglpad`):n.classes.push(`boxpad`);var m,h,g=0;/box/.test(r)?(g=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness),m=t.fontMetrics().fboxsep+(r===`colorbox`?0:g),h=m):r===`angl`?(g=Math.max(t.fontMetrics().defaultRuleThickness,t.minRuleThickness),m=4*g,h=Math.max(0,.25-n.depth)):(m=s?.2:0,h=m),a=Gn(n,r,m,h,t),/fbox|boxed|fcolorbox/.test(r)?(a.style.borderStyle=`solid`,a.style.borderWidth=k(g)):r===`angl`&&g!==.049&&(a.style.borderTopWidth=k(g),a.style.borderRightWidth=k(g)),o=n.depth+h,e.backgroundColor&&(a.style.backgroundColor=e.backgroundColor,e.borderColor&&(a.style.borderColor=e.borderColor))}var _;if(e.backgroundColor)_=G({positionType:`individualShift`,children:[{type:`elem`,elem:a,shift:o},{type:`elem`,elem:n,shift:0}]});else{var v=/cancel|phase/.test(r)?[`svg-align`]:[];_=G({positionType:`individualShift`,children:[{type:`elem`,elem:n,shift:0},{type:`elem`,elem:a,shift:o,wrapperClasses:v}]})}return/cancel/.test(r)&&(_.height=n.height,_.depth=n.depth),/cancel/.test(r)&&!s?W([`mord`,`cancel-lap`],[_],t):W([`mord`],[_],t)},Qr=(e,t)=>{var n,r=new X(e.label.includes(`colorbox`)?`mpadded`:`menclose`,[Z(e.body,t)]);switch(e.label){case`\\cancel`:r.setAttribute(`notation`,`updiagonalstrike`);break;case`\\bcancel`:r.setAttribute(`notation`,`downdiagonalstrike`);break;case`\\phase`:r.setAttribute(`notation`,`phasorangle`);break;case`\\sout`:r.setAttribute(`notation`,`horizontalstrike`);break;case`\\fbox`:r.setAttribute(`notation`,`box`);break;case`\\angl`:r.setAttribute(`notation`,`actuarial`);break;case`\\fcolorbox`:case`\\colorbox`:if(n=t.fontMetrics().fboxsep*t.fontMetrics().ptPerEm,r.setAttribute(`width`,`+`+2*n+`pt`),r.setAttribute(`height`,`+`+2*n+`pt`),r.setAttribute(`lspace`,n+`pt`),r.setAttribute(`voffset`,n+`pt`),e.label===`\\fcolorbox`){var i=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness);r.setAttribute(`style`,`border: `+k(i)+` solid `+e.borderColor)}break;case`\\xcancel`:r.setAttribute(`notation`,`updiagonalstrike downdiagonalstrike`)}return e.backgroundColor&&r.setAttribute(`mathbackground`,e.backgroundColor),r};q({type:`enclose`,names:[`\\colorbox`],props:{numArgs:2,allowedInText:!0,argTypes:[`color`,`hbox`]},handler(e,t,n){var{parser:r,funcName:i}=e,a=Q(t[0],`color-token`).color,o=t[1];return{type:`enclose`,mode:r.mode,label:i,backgroundColor:a,body:o}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\fcolorbox`],props:{numArgs:3,allowedInText:!0,argTypes:[`color`,`color`,`hbox`]},handler(e,t,n){var{parser:r,funcName:i}=e,a=Q(t[0],`color-token`).color,o=Q(t[1],`color-token`).color,s=t[2];return{type:`enclose`,mode:r.mode,label:i,backgroundColor:o,borderColor:a,body:s}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\fbox`],props:{numArgs:1,argTypes:[`hbox`],allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`enclose`,mode:n.mode,label:`\\fbox`,body:t[0]}}}),q({type:`enclose`,names:[`\\cancel`,`\\bcancel`,`\\xcancel`,`\\phase`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`enclose`,mode:n.mode,label:r,body:i}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\sout`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e;n.mode===`math`&&n.settings.reportNonstrict(`mathVsSout`,`LaTeX's \\sout works only in text mode`);var i=t[0];return{type:`enclose`,mode:n.mode,label:r,body:i}},htmlBuilder:Zr,mathmlBuilder:Qr}),q({type:`enclose`,names:[`\\angl`],props:{numArgs:1,argTypes:[`hbox`],allowedInText:!1},handler(e,t){var{parser:n}=e;return{type:`enclose`,mode:n.mode,label:`\\angl`,body:t[0]}}});var $r={};function ei(e){for(var{type:t,names:n,props:r,handler:i,htmlBuilder:a,mathmlBuilder:o}=e,s={type:t,numArgs:r.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:i},c=0;c{if(!t.parser.settings.displayMode)throw new e(`{`+t.envName+`} can be used only in display mode.`)},oi=new Set([`gather`,`gather*`]);function si(e){if(!e.includes(`ed`))return!e.includes(`*`)}function ci(t,n,r){var{hskipBeforeAndAfter:i,addJot:a,cols:o,arraystretch:s,colSeparationType:c,autoTag:l,singleRow:u,emptySingleRow:d,maxNumCols:f,leqno:p}=n;if(t.gullet.beginGroup(),u||t.gullet.macros.set(`\\cr`,`\\\\\\relax`),!s){var m=t.gullet.expandMacroAsText(`\\arraystretch`);if(m==null)s=1;else if(s=parseFloat(m),!s||s<0)throw new e(`Invalid \\arraystretch: `+m)}t.gullet.beginGroup();var h=[],g=[h],_=[],v=[],y=l==null?void 0:[];function b(){l&&t.gullet.macros.set(`\\@eqnsw`,`1`,!0)}function x(){y&&(t.gullet.macros.get(`\\df@tag`)?(y.push(t.subparse([new ri(`\\df@tag`)])),t.gullet.macros.set(`\\df@tag`,void 0,!0)):y.push(!!l&&t.gullet.macros.get(`\\@eqnsw`)===`1`))}for(b(),v.push(ii(t));;){var S=t.parseExpression(!1,u?`\\end`:`\\\\`);t.gullet.endGroup(),t.gullet.beginGroup();var C={type:`ordgroup`,mode:t.mode,body:S};r&&(C={type:`styling`,mode:t.mode,style:r,resetFont:!0,body:[C]}),h.push(C);var w=t.fetch().text;if(w===`&`){if(f&&h.length===f){if(u||c)throw new e(`Too many tab characters: &`,t.nextToken);t.settings.reportNonstrict(`textEnv`,`Too few columns specified in the {array} column argument.`)}t.consume()}else if(w===`\\end`){x(),h.length===1&&C.type===`styling`&&C.body.length===1&&C.body[0].type===`ordgroup`&&C.body[0].body.length===0&&(g.length>1||!d)&&g.pop(),v.length0&&(v+=.25),l.push({pos:v,isDashed:e[t]})}for(y(o[0]),r=0;r0&&(T+=_,Se))for(r=0;r=s)){var ge=void 0;(i>0||t.hskipBeforeAndAfter)&&(ge=ue?.pregap??f,ge!==0&&(ie=W([`arraycolsep`],[]),ie.style.width=k(ge),re.push(ie)));var _e=[];for(r=0;r0){for(var we=Vt(`hline`,n,u),Te=Vt(`hdashline`,n,u),Ee=[{type:`elem`,elem:Ce,shift:0}];l.length>0;){var De=l.pop(),Oe=De.pos-te;De.isDashed?Ee.push({type:`elem`,elem:Te,shift:Oe}):Ee.push({type:`elem`,elem:we,shift:Oe})}Ce=G({positionType:`individualShift`,children:Ee})}if(oe.length===0)return W([`mord`],[Ce],n);var ke=W([`tag`],[G({positionType:`individualShift`,children:oe})],n);return Ut([Ce,ke])},di={c:`center `,l:`left `,r:`right `},fi=function(e,t){for(var n=[],r=new X(`mtd`,[],[`mtr-glue`]),i=new X(`mtd`,[],[`mml-eqn-num`]),a=0;a0){var p=e.cols,m=``,h=!1,g=0,_=p.length;p[0].type===`separator`&&(d+=`top `,g=1),p[p.length-1].type===`separator`&&(d+=`bottom `,--_);for(var v=g;v<_;v++){var y=p[v];y.type===`align`?(f+=di[y.align],h&&(m+=`none `),h=!0):y.type===`separator`&&(h&&=(m+=y.separator===`|`?`solid `:`dashed `,!1))}l.setAttribute(`columnalign`,f.trim()),/[sd]/.test(m)&&l.setAttribute(`columnlines`,m.trim())}if(e.colSeparationType===`align`){for(var b=e.cols||[],x=``,S=1;S0?`left `:``,d+=w[w.length-1].length>0?`right `:``;for(var ee=1;ee0&&p&&(g=1),r[m]={type:`align`,align:h,pregap:g,postgap:0}}return o.colSeparationType=p?`align`:`alignat`,o};ei({type:`array`,names:[`array`,`darray`],props:{numArgs:1},handler(t,n){var r=(Xn(n[0])?[n[0]]:Q(n[0],`ordgroup`).body).map(function(t){var n=Yn(t).text;if(`lcr`.includes(n))return{type:`align`,align:n};if(n===`|`)return{type:`separator`,separator:`|`};if(n===`:`)return{type:`separator`,separator:`:`};throw new e(`Unknown column alignment: `+n,t)}),i={cols:r,hskipBeforeAndAfter:!0,maxNumCols:r.length};return ci(t.parser,i,li(t.envName))},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`matrix`,`pmatrix`,`bmatrix`,`Bmatrix`,`vmatrix`,`Vmatrix`,`matrix*`,`pmatrix*`,`bmatrix*`,`Bmatrix*`,`vmatrix*`,`Vmatrix*`],props:{numArgs:0},handler(t){var n={matrix:null,pmatrix:[`(`,`)`],bmatrix:[`[`,`]`],Bmatrix:[`\\{`,`\\}`],vmatrix:[`|`,`|`],Vmatrix:[`\\Vert`,`\\Vert`]}[t.envName.replace(`*`,``)],r=`c`,i={hskipBeforeAndAfter:!1,cols:[{type:`align`,align:r}]};if(t.envName.charAt(t.envName.length-1)===`*`){var a=t.parser;if(a.consumeSpaces(),a.fetch().text===`[`){if(a.consume(),a.consumeSpaces(),r=a.fetch().text,!`lcr`.includes(r))throw new e(`Expected l or c or r`,a.nextToken);a.consume(),a.consumeSpaces(),a.expect(`]`),a.consume(),i.cols=[{type:`align`,align:r}]}}var o=ci(t.parser,i,li(t.envName)),s=Math.max(0,...o.body.map(e=>e.length));return o.cols=Array(s).fill({type:`align`,align:r}),n?{type:`leftright`,mode:t.mode,body:[o],left:n[0],right:n[1],rightColor:void 0}:o},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`smallmatrix`],props:{numArgs:0},handler(e){var t=ci(e.parser,{arraystretch:.5},`script`);return t.colSeparationType=`small`,t},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`subarray`],props:{numArgs:1},handler(t,n){var r=(Xn(n[0])?[n[0]]:Q(n[0],`ordgroup`).body).map(function(t){var n=Yn(t).text;if(`lc`.includes(n))return{type:`align`,align:n};throw new e(`Unknown column alignment: `+n,t)});if(r.length>1)throw new e(`{subarray} can contain only one column`);var i={cols:r,hskipBeforeAndAfter:!1,arraystretch:.5},a=ci(t.parser,i,`script`);if(a.body.length>0&&a.body[0].length>1)throw new e(`{subarray} can contain only one column`);return a},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`cases`,`dcases`,`rcases`,`drcases`],props:{numArgs:0},handler(e){var t=ci(e.parser,{arraystretch:1.2,cols:[{type:`align`,align:`l`,pregap:0,postgap:1},{type:`align`,align:`l`,pregap:0,postgap:0}]},li(e.envName));return{type:`leftright`,mode:e.mode,body:[t],left:e.envName.includes(`r`)?`.`:`\\{`,right:e.envName.includes(`r`)?`\\}`:`.`,rightColor:void 0}},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`align`,`align*`,`aligned`,`split`],props:{numArgs:0},handler:pi,htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`gathered`,`gather`,`gather*`],props:{numArgs:0},handler(e){oi.has(e.envName)&&ai(e);var t={cols:[{type:`align`,align:`c`}],addJot:!0,colSeparationType:`gather`,autoTag:si(e.envName),emptySingleRow:!0,leqno:e.parser.settings.leqno};return ci(e.parser,t,`display`)},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`alignat`,`alignat*`,`alignedat`],props:{numArgs:1},handler:pi,htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`equation`,`equation*`],props:{numArgs:0},handler(e){ai(e);var t={autoTag:si(e.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:e.parser.settings.leqno};return ci(e.parser,t,`display`)},htmlBuilder:ui,mathmlBuilder:fi}),ei({type:`array`,names:[`CD`],props:{numArgs:0},handler(e){return ai(e),ur(e.parser)},htmlBuilder:ui,mathmlBuilder:fi}),$(`\\nonumber`,`\\gdef\\@eqnsw{0}`),$(`\\notag`,`\\nonumber`),q({type:`text`,names:[`\\hline`,`\\hdashline`],props:{numArgs:0,allowedInText:!0,allowedInMath:!0},handler(t,n){throw new e(t.funcName+` valid only within array environment`)}});var mi=$r;q({type:`environment`,names:[`\\begin`,`\\end`],props:{numArgs:1,argTypes:[`text`]},handler(t,n){var{parser:r,funcName:i}=t,a=n[0];if(a.type!==`ordgroup`)throw new e(`Invalid environment name`,a);for(var o=``,s=0;s{var n=e.font,r=t.withFont(n);return Y(e.body,r)},gi=(e,t)=>{var n=e.font,r=t.withFont(n);return Z(e.body,r)},_i={"\\Bbb":`\\mathbb`,"\\bold":`\\mathbf`,"\\frak":`\\mathfrak`};q({type:`font`,names:[`\\mathrm`,`\\mathit`,`\\mathbf`,`\\mathnormal`,`\\mathsfit`,`\\mathbb`,`\\mathcal`,`\\mathfrak`,`\\mathscr`,`\\mathsf`,`\\mathtt`,`\\Bbb`,`\\bold`,`\\frak`],props:{numArgs:1,allowedInArgument:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=on(t[0]),a=r;return a in _i&&(a=_i[a]),{type:`font`,mode:n.mode,font:a.slice(1),body:i}},htmlBuilder:hi,mathmlBuilder:gi}),q({type:`mclass`,names:[`\\boldsymbol`,`\\bm`],props:{numArgs:1},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`mclass`,mode:n.mode,mclass:ir(r),body:[{type:`font`,mode:n.mode,font:`boldsymbol`,body:r}],isCharacterBox:c(r)}}}),q({type:`font`,names:[`\\rm`,`\\sf`,`\\tt`,`\\bf`,`\\it`,`\\cal`],props:{numArgs:0,allowedInText:!0},handler:(e,t)=>{var{parser:n,funcName:r,breakOnTokenText:i}=e,{mode:a}=n,o=n.parseExpression(!0,i);return{type:`font`,mode:a,font:`math`+r.slice(1),body:{type:`ordgroup`,mode:n.mode,body:o}}},htmlBuilder:hi,mathmlBuilder:gi});var vi=(e,t)=>{var n=t.style,r=n.fracNum(),i=n.fracDen(),a=t.havingStyle(r),o=Y(e.numer,a,t);if(e.continued){var s=8.5/t.fontMetrics().ptPerEm,c=3.5/t.fontMetrics().ptPerEm;o.height=o.height0?3*f:7*f,h=t.fontMetrics().denom1):(d>0?(p=t.fontMetrics().num2,m=f):(p=t.fontMetrics().num3,m=3*f),h=t.fontMetrics().denom2);var g;if(u){var _=t.fontMetrics().axisHeight;p-o.depth-(_+.5*d){var n=new X(`mfrac`,[Z(e.numer,t),Z(e.denom,t)]);if(!e.hasBarLine)n.setAttribute(`linethickness`,`0px`);else if(e.barSize){var r=O(e.barSize,t);n.setAttribute(`linethickness`,k(r))}if(e.leftDelim!=null||e.rightDelim!=null){var i=[];if(e.leftDelim!=null){var a=new X(`mo`,[new bn(e.leftDelim.replace(`\\`,``))]);a.setAttribute(`fence`,`true`),i.push(a)}if(i.push(n),e.rightDelim!=null){var o=new X(`mo`,[new bn(e.rightDelim.replace(`\\`,``))]);o.setAttribute(`fence`,`true`),i.push(o)}return Tn(i)}return n},bi=(e,t)=>t?{type:`styling`,mode:e.mode,style:t,body:[e]}:e;q({type:`genfrac`,names:[`\\cfrac`,`\\dfrac`,`\\frac`,`\\tfrac`,`\\dbinom`,`\\binom`,`\\tbinom`,`\\\\atopfrac`,`\\\\bracefrac`,`\\\\brackfrac`],props:{numArgs:2,allowedInArgument:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0],a=t[1],o,s=null,c=null;switch(r){case`\\cfrac`:case`\\dfrac`:case`\\frac`:case`\\tfrac`:o=!0;break;case`\\\\atopfrac`:o=!1;break;case`\\dbinom`:case`\\binom`:case`\\tbinom`:o=!1,s=`(`,c=`)`;break;case`\\\\bracefrac`:o=!1,s=`\\{`,c=`\\}`;break;case`\\\\brackfrac`:o=!1,s=`[`,c=`]`;break;default:throw Error(`Unrecognized genfrac command`)}var l=r===`\\cfrac`,u=null;return l||r.startsWith(`\\d`)?u=`display`:r.startsWith(`\\t`)&&(u=`text`),bi({type:`genfrac`,mode:n.mode,numer:i,denom:a,continued:l,hasBarLine:o,leftDelim:s,rightDelim:c,barSize:null},u)},htmlBuilder:vi,mathmlBuilder:yi}),q({type:`infix`,names:[`\\over`,`\\choose`,`\\atop`,`\\brace`,`\\brack`],props:{numArgs:0,infix:!0},handler(e){var{parser:t,funcName:n,token:r}=e,i;switch(n){case`\\over`:i=`\\frac`;break;case`\\choose`:i=`\\binom`;break;case`\\atop`:i=`\\\\atopfrac`;break;case`\\brace`:i=`\\\\bracefrac`;break;case`\\brack`:i=`\\\\brackfrac`;break;default:throw Error(`Unrecognized infix genfrac command`)}return{type:`infix`,mode:t.mode,replaceWith:i,token:r}}});var xi=[`display`,`text`,`script`,`scriptscript`],Si=function(e){var t=null;return e.length>0&&(t=e,t=t===`.`?null:t),t};q({type:`genfrac`,names:[`\\genfrac`],props:{numArgs:6,allowedInArgument:!0,argTypes:[`math`,`math`,`size`,`text`,`math`,`math`]},handler(e,t){var{parser:n}=e,r=t[4],i=t[5],a=on(t[0]),o=a.type===`atom`&&a.family===`open`?Si(a.text):null,s=on(t[1]),c=s.type===`atom`&&s.family===`close`?Si(s.text):null,l=Q(t[2],`size`),u,d=null;l.isBlank?u=!0:(d=l.value,u=d.number>0);var f=null,p=t[3];if(p.type===`ordgroup`){if(p.body.length>0){var m=Q(p.body[0],`textord`);f=xi[Number(m.text)]}}else p=Q(p,`textord`),f=xi[Number(p.text)];return bi({type:`genfrac`,mode:n.mode,numer:r,denom:i,continued:!1,hasBarLine:u,barSize:d,leftDelim:o,rightDelim:c},f)}}),q({type:`infix`,names:[`\\above`],props:{numArgs:1,argTypes:[`size`],infix:!0},handler(e,t){var{parser:n,funcName:r,token:i}=e;return{type:`infix`,mode:n.mode,replaceWith:`\\\\abovefrac`,size:Q(t[0],`size`).value,token:i}}}),q({type:`genfrac`,names:[`\\\\abovefrac`],props:{numArgs:3,argTypes:[`math`,`size`,`math`]},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0],a=Q(t[1],`infix`).size;if(!a)throw Error(`\\\\abovefrac expected size, but got `+String(a));var o=t[2],s=a.number>0;return{type:`genfrac`,mode:n.mode,numer:i,denom:o,continued:!1,hasBarLine:s,barSize:a,leftDelim:null,rightDelim:null}}});var Ci=(e,t)=>{var n=t.style,r,i;e.type===`supsub`?(r=e.sup?Y(e.sup,t.havingStyle(n.sup()),t):Y(e.sub,t.havingStyle(n.sub()),t),i=Q(e.base,`horizBrace`)):i=Q(e,`horizBrace`);var a=Y(i.base,t.havingBaseStyle(E.DISPLAY)),o=Wn(i,t),s=i.isOver?G({positionType:`firstBaseline`,children:[{type:`elem`,elem:a},{type:`kern`,size:.1},{type:`elem`,elem:o,wrapperClasses:[`svg-align`]}]}):G({positionType:`bottom`,positionData:a.depth+.1+o.height,children:[{type:`elem`,elem:o,wrapperClasses:[`svg-align`]},{type:`kern`,size:.1},{type:`elem`,elem:a}]});if(r){var c=W([`minner`,i.isOver?`mover`:`munder`],[s],t);s=i.isOver?G({positionType:`firstBaseline`,children:[{type:`elem`,elem:c},{type:`kern`,size:.2},{type:`elem`,elem:r}]}):G({positionType:`bottom`,positionData:c.depth+.2+r.height+r.depth,children:[{type:`elem`,elem:r},{type:`kern`,size:.2},{type:`elem`,elem:c}]})}return W([`minner`,i.isOver?`mover`:`munder`],[s],t)};q({type:`horizBrace`,names:[`\\overbrace`,`\\underbrace`,`\\overbracket`,`\\underbracket`],props:{numArgs:1},handler(e,t){var{parser:n,funcName:r}=e;return{type:`horizBrace`,mode:n.mode,label:r,isOver:r.includes(`\\over`),base:t[0]}},htmlBuilder:Ci,mathmlBuilder:(e,t)=>{var n=Vn(e.label);return new X(e.isOver?`mover`:`munder`,[Z(e.base,t),n])}}),q({type:`href`,names:[`\\href`],props:{numArgs:2,argTypes:[`url`,`original`],allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[1],i=Q(t[0],`url`).url;return n.settings.isTrusted({command:`\\href`,url:i})?{type:`href`,mode:n.mode,href:i,body:J(r)}:n.formatUnsupportedCmd(`\\href`)},htmlBuilder:(e,t)=>{var n=dn(e.body,t,!1);return Ht(e.href,[],n,t)},mathmlBuilder:(e,t)=>{var n=An(e.body,t);return n instanceof X||(n=new X(`mrow`,[n])),n.setAttribute(`href`,e.href),n}}),q({type:`href`,names:[`\\url`],props:{numArgs:1,argTypes:[`url`],allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=Q(t[0],`url`).url;if(!n.settings.isTrusted({command:`\\url`,url:r}))return n.formatUnsupportedCmd(`\\url`);for(var i=[],a=0;a{var{parser:r,funcName:i,token:a}=t,o=Q(n[0],`raw`).string,s=n[1];r.settings.strict&&r.settings.reportNonstrict(`htmlExtension`,`HTML extension is disabled on strict mode`);var c,l={};switch(i){case`\\htmlClass`:l.class=o,c={command:`\\htmlClass`,class:o};break;case`\\htmlId`:l.id=o,c={command:`\\htmlId`,id:o};break;case`\\htmlStyle`:l.style=o,c={command:`\\htmlStyle`,style:o};break;case`\\htmlData`:for(var u=o.split(`,`),d=0;d{var n=dn(e.body,t,!1),r=[`enclosing`];e.attributes.class&&r.push(...e.attributes.class.trim().split(/\s+/));var i=W(r,n,t);for(var a in e.attributes)a!==`class`&&e.attributes.hasOwnProperty(a)&&i.setAttribute(a,e.attributes[a]);return i},mathmlBuilder:(e,t)=>An(e.body,t)}),q({type:`htmlmathml`,names:[`\\html@mathml`],props:{numArgs:2,allowedInArgument:!0,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e;return{type:`htmlmathml`,mode:n.mode,html:J(t[0]),mathml:J(t[1])}},htmlBuilder:(e,t)=>Ut(dn(e.html,t,!1)),mathmlBuilder:(e,t)=>An(e.mathml,t)});var wi=function(t){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(t))return{number:+t,unit:`bp`};var n=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(t);if(!n)throw new e(`Invalid size: '`+t+`' in \\includegraphics`);var r={number:+(n[1]+n[2]),unit:n[3]};if(!Te(r))throw new e(`Invalid unit: '`+r.unit+`' in \\includegraphics.`);return r};q({type:`includegraphics`,names:[`\\includegraphics`],props:{numArgs:1,numOptionalArgs:1,argTypes:[`raw`,`url`],allowedInText:!1},handler:(t,n,r)=>{var{parser:i}=t,a={number:0,unit:`em`},o={number:.9,unit:`em`},s={number:0,unit:`em`},c=``;if(r[0])for(var l=Q(r[0],`raw`).string.split(`,`),u=0;u{var n=O(e.height,t),r=0;e.totalheight.number>0&&(r=O(e.totalheight,t)-n);var i=0;e.width.number>0&&(i=O(e.width,t));var a={height:k(n+r)};i>0&&(a.width=k(i)),r>0&&(a.verticalAlign=k(-r));var o=new Pe(e.src,e.alt,a);return o.height=n,o.depth=r,o},mathmlBuilder:(e,t)=>{var n=new X(`mglyph`,[]);n.setAttribute(`alt`,e.alt);var r=O(e.height,t),i=0;if(e.totalheight.number>0&&(i=O(e.totalheight,t)-r,n.setAttribute(`valign`,k(-i))),n.setAttribute(`height`,k(r+i)),e.width.number>0){var a=O(e.width,t);n.setAttribute(`width`,k(a))}return n.setAttribute(`src`,e.src),n}}),q({type:`kern`,names:[`\\kern`,`\\mkern`,`\\hskip`,`\\mskip`],props:{numArgs:1,argTypes:[`size`],primitive:!0,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e,i=Q(t[0],`size`);if(n.settings.strict){var a=r[1]===`m`,o=i.value.unit===`mu`;a?(o||n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` supports only mu units, `+(`not `+i.value.unit+` units`)),n.mode!==`math`&&n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` works only in math mode`)):o&&n.settings.reportNonstrict(`mathVsTextUnits`,`LaTeX's `+r+` doesn't support mu units`)}return{type:`kern`,mode:n.mode,dimension:i.value}},htmlBuilder(e,t){return Kt(e.dimension,t)},mathmlBuilder(e,t){return new xn(O(e.dimension,t))}}),q({type:`lap`,names:[`\\mathllap`,`\\mathrlap`,`\\mathclap`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=t[0];return{type:`lap`,mode:n.mode,alignment:r.slice(5),body:i}},htmlBuilder:(e,t)=>{var n;e.alignment===`clap`?(n=W([],[Y(e.body,t)]),n=W([`inner`],[n],t)):n=W([`inner`],[Y(e.body,t)]);var r=W([`fix`],[]),i=W([e.alignment],[n,r],t),a=W([`strut`]);return a.style.height=k(i.height+i.depth),i.depth&&(a.style.verticalAlign=k(-i.depth)),i.children.unshift(a),i=W([`thinbox`],[i],t),W([`mord`,`vbox`],[i],t)},mathmlBuilder:(e,t)=>{var n=new X(`mpadded`,[Z(e.body,t)]);if(e.alignment!==`rlap`){var r=e.alignment===`llap`?`-1`:`-0.5`;n.setAttribute(`lspace`,r+`width`)}return n.setAttribute(`width`,`0px`),n}}),q({type:`styling`,names:[`\\(`,`$`],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,t){var{funcName:n,parser:r}=e,i=r.mode;r.switchMode(`math`);var a=n===`\\(`?`\\)`:`$`,o=r.parseExpression(!1,a);return r.expect(a),r.switchMode(i),{type:`styling`,mode:r.mode,style:`text`,resetFont:!0,body:o}}}),q({type:`text`,names:[`\\)`,`\\]`],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,n){throw new e(`Mismatched `+t.funcName)}});var Ti=(e,t)=>{switch(t.style.size){case E.DISPLAY.size:return e.display;case E.TEXT.size:return e.text;case E.SCRIPT.size:return e.script;case E.SCRIPTSCRIPT.size:return e.scriptscript;default:return e.text}};q({type:`mathchoice`,names:[`\\mathchoice`],props:{numArgs:4,primitive:!0},handler:(e,t)=>{var{parser:n}=e;return{type:`mathchoice`,mode:n.mode,display:J(t[0]),text:J(t[1]),script:J(t[2]),scriptscript:J(t[3])}},htmlBuilder:(e,t)=>Ut(dn(Ti(e,t),t,!1)),mathmlBuilder:(e,t)=>An(Ti(e,t),t)});var Ei=(e,t,n,r,i,a,o)=>{e=W([],[e]);var s=n&&c(n),l,u;if(t){var d=Y(t,r.havingStyle(i.sup()),r);u={elem:d,kern:Math.max(r.fontMetrics().bigOpSpacing1,r.fontMetrics().bigOpSpacing3-d.depth)}}if(n){var f=Y(n,r.havingStyle(i.sub()),r);l={elem:f,kern:Math.max(r.fontMetrics().bigOpSpacing2,r.fontMetrics().bigOpSpacing4-f.height)}}var p;if(u&&l)p=G({positionType:`bottom`,positionData:r.fontMetrics().bigOpSpacing5+l.elem.height+l.elem.depth+l.kern+e.depth+o,children:[{type:`kern`,size:r.fontMetrics().bigOpSpacing5},{type:`elem`,elem:l.elem,marginLeft:k(-a)},{type:`kern`,size:l.kern},{type:`elem`,elem:e},{type:`kern`,size:u.kern},{type:`elem`,elem:u.elem,marginLeft:k(a)},{type:`kern`,size:r.fontMetrics().bigOpSpacing5}]});else if(l)p=G({positionType:`top`,positionData:e.height-o,children:[{type:`kern`,size:r.fontMetrics().bigOpSpacing5},{type:`elem`,elem:l.elem,marginLeft:k(-a)},{type:`kern`,size:l.kern},{type:`elem`,elem:e}]});else if(u)p=G({positionType:`bottom`,positionData:e.depth+o,children:[{type:`elem`,elem:e},{type:`kern`,size:u.kern},{type:`elem`,elem:u.elem,marginLeft:k(a)},{type:`kern`,size:r.fontMetrics().bigOpSpacing5}]});else return e;var m=[p];if(l&&a!==0&&!s){var h=W([`mspace`],[],r);h.style.marginRight=k(a),m.unshift(h)}return W([`mop`,`op-limits`],m,r)},Di=new Set([`\\smallint`]),Oi=(e,t)=>{var n,r,i=!1,a;e.type===`supsub`?(n=e.sup,r=e.sub,a=Q(e.base,`op`),i=!0):a=Q(e,`op`);var o=t.style,s=!1;o.size===E.DISPLAY.size&&a.symbol&&!Di.has(a.name)&&(s=!0);var c,l;if(a.symbol){var u=s?`Size2-Regular`:`Size1-Regular`,d=``;if((a.name===`\\oiint`||a.name===`\\oiiint`)&&(d=a.name.slice(1),a.name=d===`oiint`?`\\iint`:`\\iiint`),c=Nt(a.name,u,`math`,t,[`mop`,`op-symbol`,s?`large-op`:`small-op`]),l=c.italic,d.length>0){var f=Xt(d+`Size`+(s?`2`:`1`),t);c=G({positionType:`individualShift`,children:[{type:`elem`,elem:c,shift:0},{type:`elem`,elem:f,shift:s?.08:0}]}),a.name=`\\`+d,c.classes.unshift(`mop`),c.italic=l}}else if(a.body){var p=dn(a.body,t,!0);p.length===1&&p[0]instanceof Ie?(c=p[0],c.classes[0]=`mop`):c=W([`mop`],p,t)}else{for(var m=[],h=1;h{var n;if(e.symbol)n=new X(`mo`,[wn(e.name,e.mode)]),Di.has(e.name)&&n.setAttribute(`largeop`,`false`);else if(e.body)n=new X(`mo`,kn(e.body,t));else{n=new X(`mi`,[new bn(e.name.slice(1))]);var r=new X(`mo`,[wn(`⁡`,`text`)]);n=e.parentIsSupSub?new X(`mrow`,[n,r]):yn([n,r])}return n},Ai={"∏":`\\prod`,"∐":`\\coprod`,"∑":`\\sum`,"⋀":`\\bigwedge`,"⋁":`\\bigvee`,"⋂":`\\bigcap`,"⋃":`\\bigcup`,"⨀":`\\bigodot`,"⨁":`\\bigoplus`,"⨂":`\\bigotimes`,"⨄":`\\biguplus`,"⨆":`\\bigsqcup`};q({type:`op`,names:`\\coprod.\\bigvee.\\bigwedge.\\biguplus.\\bigcap.\\bigcup.\\intop.\\prod.\\sum.\\bigotimes.\\bigoplus.\\bigodot.\\bigsqcup.\\smallint.∏.∐.∑.⋀.⋁.⋂.⋃.⨀.⨁.⨂.⨄.⨆`.split(`.`),props:{numArgs:0},handler:(e,t)=>{var{parser:n,funcName:r}=e,i=r;return i.length===1&&(i=Ai[i]),{type:`op`,mode:n.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:i}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\mathop`],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`op`,mode:n.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:J(r)}},htmlBuilder:Oi,mathmlBuilder:ki});var ji={"∫":`\\int`,"∬":`\\iint`,"∭":`\\iiint`,"∮":`\\oint`,"∯":`\\oiint`,"∰":`\\oiiint`};q({type:`op`,names:`\\arcsin.\\arccos.\\arctan.\\arctg.\\arcctg.\\arg.\\ch.\\cos.\\cosec.\\cosh.\\cot.\\cotg.\\coth.\\csc.\\ctg.\\cth.\\deg.\\dim.\\exp.\\hom.\\ker.\\lg.\\ln.\\log.\\sec.\\sin.\\sinh.\\sh.\\tan.\\tanh.\\tg.\\th`.split(`.`),props:{numArgs:0},handler(e){var{parser:t,funcName:n}=e;return{type:`op`,mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\det`,`\\gcd`,`\\inf`,`\\lim`,`\\max`,`\\min`,`\\Pr`,`\\sup`],props:{numArgs:0},handler(e){var{parser:t,funcName:n}=e;return{type:`op`,mode:t.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:Oi,mathmlBuilder:ki}),q({type:`op`,names:[`\\int`,`\\iint`,`\\iiint`,`\\oint`,`\\oiint`,`\\oiiint`,`∫`,`∬`,`∭`,`∮`,`∯`,`∰`],props:{numArgs:0,allowedInArgument:!0},handler(e){var{parser:t,funcName:n}=e,r=n;return r.length===1&&(r=ji[r]),{type:`op`,mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:r}},htmlBuilder:Oi,mathmlBuilder:ki});var Mi=(e,t)=>{var n,r,i=!1,a;e.type===`supsub`?(n=e.sup,r=e.sub,a=Q(e.base,`operatorname`),i=!0):a=Q(e,`operatorname`);var o;if(a.body.length>0){for(var s=dn(a.body.map(e=>{var t=`text`in e?e.text:void 0;return typeof t==`string`?{type:`textord`,mode:e.mode,text:t}:e}),t.withFont(`mathrm`),!0),c=0;c{var{parser:n,funcName:r}=e,i=t[0];return{type:`operatorname`,mode:n.mode,body:J(i),alwaysHandleSupSub:r===`\\operatornamewithlimits`,limits:!1,parentIsSupSub:!1}},htmlBuilder:Mi,mathmlBuilder:(e,t)=>{for(var n=kn(e.body,t.withFont(`mathrm`)),r=!0,i=0;ie.toText()).join(``))]);var s=new X(`mi`,n);s.setAttribute(`mathvariant`,`normal`);var c=new X(`mo`,[wn(`⁡`,`text`)]);return e.parentIsSupSub?new X(`mrow`,[s,c]):yn([s,c])}}),$(`\\operatorname`,`\\@ifstar\\operatornamewithlimits\\operatorname@`),an({type:`ordgroup`,htmlBuilder(e,t){return e.semisimple?Ut(dn(e.body,t,!1)):W([`mord`],dn(e.body,t,!0),t)},mathmlBuilder(e,t){return An(e.body,t,!0)}}),q({type:`overline`,names:[`\\overline`],props:{numArgs:1},handler(e,t){var{parser:n}=e,r=t[0];return{type:`overline`,mode:n.mode,body:r}},htmlBuilder(e,t){var n=Y(e.body,t.havingCrampedStyle()),r=Vt(`overline-line`,t),i=t.fontMetrics().defaultRuleThickness;return W([`mord`,`overline`],[G({positionType:`firstBaseline`,children:[{type:`elem`,elem:n},{type:`kern`,size:3*i},{type:`elem`,elem:r},{type:`kern`,size:i}]})],t)},mathmlBuilder(e,t){var n=new X(`mo`,[new bn(`‾`)]);n.setAttribute(`stretchy`,`true`);var r=new X(`mover`,[Z(e.body,t),n]);return r.setAttribute(`accent`,`true`),r}}),q({type:`phantom`,names:[`\\phantom`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`phantom`,mode:n.mode,body:J(r)}},htmlBuilder:(e,t)=>Ut(dn(e.body,t.withPhantom(),!1)),mathmlBuilder:(e,t)=>new X(`mphantom`,kn(e.body,t))}),$(`\\hphantom`,`\\smash{\\phantom{#1}}`),q({type:`vphantom`,names:[`\\vphantom`],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:n}=e,r=t[0];return{type:`vphantom`,mode:n.mode,body:r}},htmlBuilder:(e,t)=>W([`mord`,`rlap`],[W([`inner`],[Y(e.body,t.withPhantom())]),W([`fix`],[])],t),mathmlBuilder:(e,t)=>{var n=new X(`mpadded`,[new X(`mphantom`,kn(J(e.body),t))]);return n.setAttribute(`width`,`0px`),n}}),q({type:`raisebox`,names:[`\\raisebox`],props:{numArgs:2,argTypes:[`size`,`hbox`],allowedInText:!0},handler(e,t){var{parser:n}=e,r=Q(t[0],`size`).value,i=t[1];return{type:`raisebox`,mode:n.mode,dy:r,body:i}},htmlBuilder(e,t){var n=Y(e.body,t);return G({positionType:`shift`,positionData:-O(e.dy,t),children:[{type:`elem`,elem:n}]})},mathmlBuilder(e,t){var n=new X(`mpadded`,[Z(e.body,t)]),r=e.dy.number+e.dy.unit;return n.setAttribute(`voffset`,r),n}}),q({type:`internal`,names:[`\\relax`],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(e){var{parser:t}=e;return{type:`internal`,mode:t.mode}}}),q({type:`rule`,names:[`\\rule`],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:[`size`,`size`,`size`]},handler(e,t,n){var{parser:r}=e,i=n[0],a=Q(t[0],`size`),o=Q(t[1],`size`);return{type:`rule`,mode:r.mode,shift:i&&Q(i,`size`).value,width:a.value,height:o.value}},htmlBuilder(e,t){var n=W([`mord`,`rule`],[],t),r=O(e.width,t),i=O(e.height,t),a=e.shift?O(e.shift,t):0;return n.style.borderRightWidth=k(r),n.style.borderTopWidth=k(i),n.style.bottom=k(a),n.width=r,n.height=i+a,n.depth=-a,n.maxFontSize=i*1.125*t.sizeMultiplier,n},mathmlBuilder(e,t){var n=O(e.width,t),r=O(e.height,t),i=e.shift?O(e.shift,t):0,a=t.color&&t.getColor()||`black`,o=new X(`mspace`);o.setAttribute(`mathbackground`,a),o.setAttribute(`width`,k(n)),o.setAttribute(`height`,k(r));var s=new X(`mpadded`,[o]);return i>=0?s.setAttribute(`height`,k(i)):(s.setAttribute(`height`,k(i)),s.setAttribute(`depth`,k(-i))),s.setAttribute(`voffset`,k(i)),s}});function Ni(e,t,n){for(var r=dn(e,t,!1),i=t.sizeMultiplier/n.sizeMultiplier,a=0;a{var{breakOnTokenText:n,funcName:r,parser:i}=e,a=i.parseExpression(!1,n);return{type:`sizing`,mode:i.mode,size:Pi.indexOf(r)+1,body:a}},htmlBuilder:(e,t)=>{var n=t.havingSize(e.size);return Ni(e.body,n,t)},mathmlBuilder:(e,t)=>{var n=t.havingSize(e.size),r=new X(`mstyle`,kn(e.body,n));return r.setAttribute(`mathsize`,k(n.sizeMultiplier)),r}}),q({type:`smash`,names:[`\\smash`],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(e,t,n)=>{var{parser:r}=e,i=!1,a=!1,o=n[0]&&Q(n[0],`ordgroup`);if(o)for(var s,c=0;c{var n=W([],[Y(e.body,t)]);if(!e.smashHeight&&!e.smashDepth)return n;if(e.smashHeight&&(n.height=0),e.smashDepth&&(n.depth=0),e.smashHeight&&e.smashDepth)return W([`mord`,`smash`],[n],t);if(n.children)for(var r=0;r{var n=new X(`mpadded`,[Z(e.body,t)]);return e.smashHeight&&n.setAttribute(`height`,`0px`),e.smashDepth&&n.setAttribute(`depth`,`0px`),n}}),q({type:`sqrt`,names:[`\\sqrt`],props:{numArgs:1,numOptionalArgs:1},handler(e,t,n){var{parser:r}=e,i=n[0],a=t[0];return{type:`sqrt`,mode:r.mode,body:a,index:i}},htmlBuilder(e,t){var n=Y(e.body,t.havingCrampedStyle());n.height===0&&(n.height=t.fontMetrics().xHeight),n=Wt(n,t);var r=t.fontMetrics().defaultRuleThickness,i=r;t.style.idn.height+n.depth+a&&(a=(a+l-n.height-n.depth)/2);var u=o.height-n.height-a-s;n.style.paddingLeft=k(c);var d=G({positionType:`firstBaseline`,children:[{type:`elem`,elem:n,wrapperClasses:[`svg-align`]},{type:`kern`,size:-(n.height+u)},{type:`elem`,elem:o},{type:`kern`,size:s}]});if(e.index){var f=t.havingStyle(E.SCRIPTSCRIPT),p=Y(e.index,f,t);return W([`mord`,`sqrt`],[W([`root`],[G({positionType:`shift`,positionData:-(.6*(d.height-d.depth)),children:[{type:`elem`,elem:p}]})]),d],t)}return W([`mord`,`sqrt`],[d],t)},mathmlBuilder(e,t){var{body:n,index:r}=e;return r?new X(`mroot`,[Z(n,t),Z(r,t)]):new X(`msqrt`,[Z(n,t)])}});var Fi={display:E.DISPLAY,text:E.TEXT,script:E.SCRIPT,scriptscript:E.SCRIPTSCRIPT};function Ii(e){return e in Fi}q({type:`styling`,names:[`\\displaystyle`,`\\textstyle`,`\\scriptstyle`,`\\scriptscriptstyle`],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e,t){var{breakOnTokenText:n,funcName:r,parser:i}=e,a=i.parseExpression(!0,n),o=r.slice(1,r.length-5);if(!Ii(o))throw Error(`Unknown style: `+o);return{type:`styling`,mode:i.mode,style:o,body:a}},htmlBuilder(e,t){var n=Fi[e.style],r=t.havingStyle(n);return e.resetFont&&(r=r.withFont(``)),Ni(e.body,r,t)},mathmlBuilder(e,t){var n=Fi[e.style],r=t.havingStyle(n);e.resetFont&&(r=r.withFont(``));var i=new X(`mstyle`,kn(e.body,r)),a={display:[`0`,`true`],text:[`0`,`false`],script:[`1`,`false`],scriptscript:[`2`,`false`]}[e.style];return i.setAttribute(`scriptlevel`,a[0]),i.setAttribute(`displaystyle`,a[1]),i}});var Li=function(e,t){var n=e.base;return n?n.type===`op`?n.limits&&(t.style.size===E.DISPLAY.size||n.alwaysHandleSupSub)?Oi:null:n.type===`operatorname`?n.alwaysHandleSupSub&&(t.style.size===E.DISPLAY.size||n.limits)?Mi:null:n.type===`accent`?c(n.base)?Qn:null:n.type===`horizBrace`&&!e.sub===n.isOver?Ci:null:null};an({type:`supsub`,htmlBuilder(e,t){var n=Li(e,t);if(n)return n(e,t);var{base:r,sup:i,sub:a}=e,o=Y(r,t),s,l,u=t.fontMetrics(),d=0,f=0,p=r&&c(r);if(i){var m=t.havingStyle(t.style.sup());s=Y(i,m,t),p||(d=o.height-m.fontMetrics().supDrop*m.sizeMultiplier/t.sizeMultiplier)}if(a){var h=t.havingStyle(t.style.sub());l=Y(a,h,t),p||(f=o.depth+h.fontMetrics().subDrop*h.sizeMultiplier/t.sizeMultiplier)}var g=t.style===E.DISPLAY?u.sup1:t.style.cramped?u.sup3:u.sup2,_=t.sizeMultiplier,v=k(.5/u.ptPerEm/_),y=null;if(l){var b=e.base&&e.base.type===`op`&&e.base.name&&(e.base.name===`\\oiint`||e.base.name===`\\oiiint`);(o instanceof Ie||b)&&(y=k(-(o.italic??0)))}var x;if(s&&l){d=Math.max(d,g,s.depth+.25*u.xHeight),f=Math.max(f,u.sub2);var S=4*u.defaultRuleThickness;if(d-s.depth-(l.height-f)0&&(d+=C,f-=C)}x=G({positionType:`individualShift`,children:[{type:`elem`,elem:l,shift:f,marginRight:v,marginLeft:y},{type:`elem`,elem:s,shift:-d,marginRight:v}]})}else if(l)f=Math.max(f,u.sub1,l.height-.8*u.xHeight),x=G({positionType:`shift`,positionData:f,children:[{type:`elem`,elem:l,marginLeft:y,marginRight:v}]});else if(s)d=Math.max(d,g,s.depth+.25*u.xHeight),x=G({positionType:`shift`,positionData:-d,children:[{type:`elem`,elem:s,marginRight:v}]});else throw Error(`supsub must have either sup or sub.`);return W([hn(o,`right`)||`mord`],[o,W([`msupsub`],[x])],t)},mathmlBuilder(e,t){var n=!1,r,i;e.base&&e.base.type===`horizBrace`&&(i=!!e.sup,i===e.base.isOver&&(n=!0,r=e.base.isOver)),e.base&&(e.base.type===`op`||e.base.type===`operatorname`)&&(e.base.parentIsSupSub=!0);var a=[Z(e.base,t)];e.sub&&a.push(Z(e.sub,t)),e.sup&&a.push(Z(e.sup,t));var o;if(n)o=r?`mover`:`munder`;else if(!e.sub){var s=e.base;o=s&&s.type===`op`&&s.limits&&(t.style===E.DISPLAY||s.alwaysHandleSupSub)||s&&s.type===`operatorname`&&s.alwaysHandleSupSub&&(s.limits||t.style===E.DISPLAY)?`mover`:`msup`}else if(e.sup){var c=e.base;o=c&&c.type===`op`&&c.limits&&t.style===E.DISPLAY||c&&c.type===`operatorname`&&c.alwaysHandleSupSub&&(t.style===E.DISPLAY||c.limits)?`munderover`:`msubsup`}else{var l=e.base;o=l&&l.type===`op`&&l.limits&&(t.style===E.DISPLAY||l.alwaysHandleSupSub)||l&&l.type===`operatorname`&&l.alwaysHandleSupSub&&(l.limits||t.style===E.DISPLAY)?`munder`:`msub`}return new X(o,a)}}),an({type:`atom`,htmlBuilder(e,t){return Pt(e.text,e.mode,t,[`m`+e.family])},mathmlBuilder(e,t){var n=new X(`mo`,[wn(e.text,e.mode)]);if(e.family===`bin`){var r=Dn(e,t);r===`bold-italic`&&n.setAttribute(`mathvariant`,r)}else e.family===`punct`?n.setAttribute(`separator`,`true`):(e.family===`open`||e.family===`close`)&&n.setAttribute(`stretchy`,`false`);return n}});var Ri={mi:`italic`,mn:`normal`,mtext:`normal`};an({type:`mathord`,htmlBuilder(e,t){return It(e,t,`mathord`)},mathmlBuilder(e,t){var n=new X(`mi`,[wn(e.text,e.mode,t)]),r=Dn(e,t)||`italic`;return r!==Ri[n.type]&&n.setAttribute(`mathvariant`,r),n}}),an({type:`textord`,htmlBuilder(e,t){return It(e,t,`textord`)},mathmlBuilder(e,t){var n=wn(e.text,e.mode,t),r=Dn(e,t)||`normal`,i=e.mode===`text`?new X(`mtext`,[n]):/[0-9]/.test(e.text)?new X(`mn`,[n]):e.text===`\\prime`?new X(`mo`,[n]):new X(`mi`,[n]);return r!==Ri[i.type]&&i.setAttribute(`mathvariant`,r),i}});var zi={"\\nobreak":`nobreak`,"\\allowbreak":`allowbreak`},Bi={" ":{},"\\ ":{},"~":{className:`nobreak`},"\\space":{},"\\nobreakspace":{className:`nobreak`}};an({type:`spacing`,htmlBuilder(t,n){if(Bi.hasOwnProperty(t.text)){var r=Bi[t.text].className||``;if(t.mode===`text`){var i=It(t,n,`textord`);return i.classes.push(r),i}return W([`mspace`,r],[Pt(t.text,t.mode,n)],n)}if(zi.hasOwnProperty(t.text))return W([`mspace`,zi[t.text]],[],n);throw new e(`Unknown type of space "`+t.text+`"`)},mathmlBuilder(t,n){var r;if(Bi.hasOwnProperty(t.text))r=new X(`mtext`,[new bn(`\xA0`)]);else if(zi.hasOwnProperty(t.text))return new X(`mspace`);else throw new e(`Unknown type of space "`+t.text+`"`);return r}});var Vi=()=>{var e=new X(`mtd`,[]);return e.setAttribute(`width`,`50%`),e};an({type:`tag`,mathmlBuilder(e,t){var n=new X(`mtable`,[new X(`mtr`,[Vi(),new X(`mtd`,[An(e.body,t)]),Vi(),new X(`mtd`,[An(e.tag,t)])])]);return n.setAttribute(`width`,`100%`),n}});var Hi={"\\text":void 0,"\\textrm":`textrm`,"\\textsf":`textsf`,"\\texttt":`texttt`,"\\textnormal":`textrm`},Ui={"\\textbf":`textbf`,"\\textmd":`textmd`},Wi={"\\textit":`textit`,"\\textup":`textup`},Gi=(e,t)=>{var n=e.font;return n?Hi[n]?t.withTextFontFamily(Hi[n]):Ui[n]?t.withTextFontWeight(Ui[n]):n===`\\emph`?t.fontShape===`textit`?t.withTextFontShape(`textup`):t.withTextFontShape(`textit`):t.withTextFontShape(Wi[n]):t};q({type:`text`,names:[`\\text`,`\\textrm`,`\\textsf`,`\\texttt`,`\\textnormal`,`\\textbf`,`\\textmd`,`\\textit`,`\\textup`,`\\emph`],props:{numArgs:1,argTypes:[`text`],allowedInArgument:!0,allowedInText:!0},handler(e,t){var{parser:n,funcName:r}=e,i=t[0];return{type:`text`,mode:n.mode,body:J(i),font:r}},htmlBuilder(e,t){var n=Gi(e,t);return W([`mord`,`text`],dn(e.body,n,!0),n)},mathmlBuilder(e,t){var n=Gi(e,t);return An(e.body,n)}}),q({type:`underline`,names:[`\\underline`],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:n}=e;return{type:`underline`,mode:n.mode,body:t[0]}},htmlBuilder(e,t){var n=Y(e.body,t),r=Vt(`underline-line`,t),i=t.fontMetrics().defaultRuleThickness;return W([`mord`,`underline`],[G({positionType:`top`,positionData:n.height,children:[{type:`kern`,size:i},{type:`elem`,elem:r},{type:`kern`,size:3*i},{type:`elem`,elem:n}]})],t)},mathmlBuilder(e,t){var n=new X(`mo`,[new bn(`‾`)]);n.setAttribute(`stretchy`,`true`);var r=new X(`munder`,[Z(e.body,t),n]);return r.setAttribute(`accentunder`,`true`),r}}),q({type:`vcenter`,names:[`\\vcenter`],props:{numArgs:1,argTypes:[`original`],allowedInText:!1},handler(e,t){var{parser:n}=e;return{type:`vcenter`,mode:n.mode,body:t[0]}},htmlBuilder(e,t){var n=Y(e.body,t),r=t.fontMetrics().axisHeight;return G({positionType:`shift`,positionData:.5*(n.height-r-(n.depth+r)),children:[{type:`elem`,elem:n}]})},mathmlBuilder(e,t){return new X(`mrow`,[new X(`mpadded`,[Z(e.body,t)],[`vcenter`])])}}),q({type:`verb`,names:[`\\verb`],props:{numArgs:0,allowedInText:!0},handler(t,n,r){throw new e(`\\verb ended by end of line instead of matching delimiter`)},htmlBuilder(e,t){for(var n=Ki(e),r=[],i=t.havingStyle(t.style.text()),a=0;ae.body.replace(/ /g,e.star?`␣`:`\xA0`),qi=tn,Ji=`[ \r + ]`,Yi=`\\\\[a-zA-Z@]+`,Xi=`\\\\[^\ud800-\udfff]`,Zi=`(`+Yi+`)`+Ji+`*`,Qi=`\\\\( +|[ \r ]+ +?)[ \r ]*`,$i=`[̀-ͯ]`,ea=RegExp($i+`+$`),ta=`(`+Ji+`+)|`+(Qi+`|`)+`([!-\\[\\]-‧‪-퟿豈-￿]`+($i+`*`)+`|[\ud800-\udbff][\udc00-\udfff]`+($i+`*`)+`|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5`+(`|`+Zi)+(`|`+Xi+`)`),na=class{constructor(e,t){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=e,this.settings=t,this.tokenRegex=new RegExp(ta,`g`),this.catcodes={"%":14,"~":13}}setCatcode(e,t){this.catcodes[e]=t}lex(){var t=this.input,n=this.tokenRegex.lastIndex;if(n===t.length)return new ri(`EOF`,new ni(this,n,n));var r=this.tokenRegex.exec(t);if(r===null||r.index!==n)throw new e(`Unexpected character: '`+t[n]+`'`,new ri(t[n],new ni(this,n,n+1)));var i=r[6]||r[3]||(r[2]?`\\ `:` `);if(this.catcodes[i]===14){var a=t.indexOf(` +`,this.tokenRegex.lastIndex);return a===-1?(this.tokenRegex.lastIndex=t.length,this.settings.reportNonstrict(`commentAtEnd`,`% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)`)):this.tokenRegex.lastIndex=a+1,this.lex()}return new ri(i,new ni(this,n,this.tokenRegex.lastIndex))}},ra=class{constructor(e,t){e===void 0&&(e={}),t===void 0&&(t={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=t,this.builtins=e,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(this.undefStack.length===0)throw new e(`Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug`);var t=this.undefStack.pop();for(var n in t)t.hasOwnProperty(n)&&(t[n]==null?delete this.current[n]:this.current[n]=t[n])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(e){return this.current.hasOwnProperty(e)||this.builtins.hasOwnProperty(e)}get(e){return this.current.hasOwnProperty(e)?this.current[e]:this.builtins[e]}set(e,t,n){if(n===void 0&&(n=!1),n){for(var r=0;r0&&(this.undefStack[this.undefStack.length-1][e]=t)}else{var i=this.undefStack[this.undefStack.length-1];i&&!i.hasOwnProperty(e)&&(i[e]=this.current[e])}t==null?delete this.current[e]:this.current[e]=t}},ia=ti;$(`\\noexpand`,function(e){var t=e.popToken();return e.isExpandable(t.text)&&(t.noexpand=!0,t.treatAsRelax=!0),{tokens:[t],numArgs:0}}),$(`\\expandafter`,function(e){var t=e.popToken();return e.expandOnce(!0),{tokens:[t],numArgs:0}}),$(`\\@firstoftwo`,function(e){return{tokens:e.consumeArgs(2)[0],numArgs:0}}),$(`\\@secondoftwo`,function(e){return{tokens:e.consumeArgs(2)[1],numArgs:0}}),$(`\\@ifnextchar`,function(e){var t=e.consumeArgs(3);e.consumeSpaces();var n=e.future();return t[0].length===1&&t[0][0].text===n.text?{tokens:t[1],numArgs:0}:{tokens:t[2],numArgs:0}}),$(`\\@ifstar`,`\\@ifnextchar *{\\@firstoftwo{#1}}`),$(`\\TextOrMath`,function(e){var t=e.consumeArgs(2);return e.mode===`text`?{tokens:t[0],numArgs:0}:{tokens:t[1],numArgs:0}});var aa={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};$(`\\char`,function(t){var n=t.popToken(),r,i=0;if(n.text===`'`)r=8,n=t.popToken();else if(n.text===`"`)r=16,n=t.popToken();else if(n.text==="`"){if(n=t.popToken(),n.text[0]===`\\`)i=n.text.charCodeAt(1);else if(n.text===`EOF`)throw new e("\\char` missing argument");else i=n.text.charCodeAt(0)}else r=10;if(r){if(i=aa[n.text],i==null||i>=r)throw new e(`Invalid base-`+r+` digit `+n.text);for(var a;(a=aa[t.future().text])!=null&&a{var a=t.consumeArg().tokens;if(a.length!==1)throw new e(`\\newcommand's first argument must be a macro name`);var o=a[0].text,s=t.isDefined(o);if(s&&!n)throw new e(`\\newcommand{`+o+`} attempting to redefine `+(o+`; use \\renewcommand`));if(!s&&!r)throw new e(`\\renewcommand{`+o+`} when command `+o+` does not yet exist; use \\newcommand`);var c=0;if(a=t.consumeArg().tokens,a.length===1&&a[0].text===`[`){for(var l=``,u=t.expandNextToken();u.text!==`]`&&u.text!==`EOF`;)l+=u.text,u=t.expandNextToken();if(!l.match(/^\s*[0-9]+\s*$/))throw new e(`Invalid number of arguments: `+l);c=parseInt(l),a=t.consumeArg().tokens}return s&&i||t.macros.set(o,{tokens:a,numArgs:c}),``};$(`\\newcommand`,e=>oa(e,!1,!0,!1)),$(`\\renewcommand`,e=>oa(e,!0,!1,!1)),$(`\\providecommand`,e=>oa(e,!0,!0,!0)),$(`\\message`,e=>{var t=e.consumeArgs(1)[0];return console.log(t.reverse().map(e=>e.text).join(``)),``}),$(`\\errmessage`,e=>{var t=e.consumeArgs(1)[0];return console.error(t.reverse().map(e=>e.text).join(``)),``}),$(`\\show`,e=>{var t=e.popToken(),n=t.text;return console.log(t,e.macros.get(n),qi[n],A.math[n],A.text[n]),``}),$(`\\bgroup`,`{`),$(`\\egroup`,`}`),$(`~`,`\\nobreakspace`),$(`\\lq`,"`"),$(`\\rq`,`'`),$(`\\aa`,`\\r a`),$(`\\AA`,`\\r A`),$(`\\textcopyright`,"\\html@mathml{\\textcircled{c}}{\\char`©}"),$(`\\copyright`,`\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}`),$(`\\textregistered`,"\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}"),$(`ℬ`,`\\mathscr{B}`),$(`ℰ`,`\\mathscr{E}`),$(`ℱ`,`\\mathscr{F}`),$(`ℋ`,`\\mathscr{H}`),$(`ℐ`,`\\mathscr{I}`),$(`ℒ`,`\\mathscr{L}`),$(`ℳ`,`\\mathscr{M}`),$(`ℛ`,`\\mathscr{R}`),$(`ℭ`,`\\mathfrak{C}`),$(`ℌ`,`\\mathfrak{H}`),$(`ℨ`,`\\mathfrak{Z}`),$(`\\Bbbk`,`\\Bbb{k}`),$(`\\llap`,`\\mathllap{\\textrm{#1}}`),$(`\\rlap`,`\\mathrlap{\\textrm{#1}}`),$(`\\clap`,`\\mathclap{\\textrm{#1}}`),$(`\\mathstrut`,`\\vphantom{(}`),$(`\\underbar`,`\\underline{\\text{#1}}`),$(`\\not`,`\\html@mathml{\\mathrel{\\mathrlap\\@not}\\nobreak}{\\char"338}`),$(`\\neq`,"\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}"),$(`\\ne`,`\\neq`),$(`≠`,`\\neq`),$(`\\notin`,"\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}"),$(`∉`,`\\notin`),$(`≘`,"\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}"),$(`≙`,"\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}"),$(`≚`,"\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}"),$(`≛`,"\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}"),$(`≝`,"\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}"),$(`≞`,"\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}"),$(`≟`,"\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}"),$(`⟂`,`\\perp`),$(`‼`,`\\mathclose{!\\mkern-0.8mu!}`),$(`∌`,`\\notni`),$(`⌜`,`\\ulcorner`),$(`⌝`,`\\urcorner`),$(`⌞`,`\\llcorner`),$(`⌟`,`\\lrcorner`),$(`©`,`\\copyright`),$(`®`,`\\textregistered`),$(`\\ulcorner`,`\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}`),$(`\\urcorner`,`\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}`),$(`\\llcorner`,`\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}`),$(`\\lrcorner`,`\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}`),$(`\\vdots`,`{\\varvdots\\rule{0pt}{15pt}}`),$(`⋮`,`\\vdots`),$(`\\varGamma`,`\\mathit{\\Gamma}`),$(`\\varDelta`,`\\mathit{\\Delta}`),$(`\\varTheta`,`\\mathit{\\Theta}`),$(`\\varLambda`,`\\mathit{\\Lambda}`),$(`\\varXi`,`\\mathit{\\Xi}`),$(`\\varPi`,`\\mathit{\\Pi}`),$(`\\varSigma`,`\\mathit{\\Sigma}`),$(`\\varUpsilon`,`\\mathit{\\Upsilon}`),$(`\\varPhi`,`\\mathit{\\Phi}`),$(`\\varPsi`,`\\mathit{\\Psi}`),$(`\\varOmega`,`\\mathit{\\Omega}`),$(`\\substack`,`\\begin{subarray}{c}#1\\end{subarray}`),$(`\\colon`,`\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax`),$(`\\boxed`,`\\fbox{$\\displaystyle{#1}$}`),$(`\\iff`,`\\DOTSB\\;\\Longleftrightarrow\\;`),$(`\\implies`,`\\DOTSB\\;\\Longrightarrow\\;`),$(`\\impliedby`,`\\DOTSB\\;\\Longleftarrow\\;`),$(`\\dddot`,`{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}`),$(`\\ddddot`,`{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}`);var sa={",":`\\dotsc`,"\\not":`\\dotsb`,"+":`\\dotsb`,"=":`\\dotsb`,"<":`\\dotsb`,">":`\\dotsb`,"-":`\\dotsb`,"*":`\\dotsb`,":":`\\dotsb`,"\\DOTSB":`\\dotsb`,"\\coprod":`\\dotsb`,"\\bigvee":`\\dotsb`,"\\bigwedge":`\\dotsb`,"\\biguplus":`\\dotsb`,"\\bigcap":`\\dotsb`,"\\bigcup":`\\dotsb`,"\\prod":`\\dotsb`,"\\sum":`\\dotsb`,"\\bigotimes":`\\dotsb`,"\\bigoplus":`\\dotsb`,"\\bigodot":`\\dotsb`,"\\bigsqcup":`\\dotsb`,"\\And":`\\dotsb`,"\\longrightarrow":`\\dotsb`,"\\Longrightarrow":`\\dotsb`,"\\longleftarrow":`\\dotsb`,"\\Longleftarrow":`\\dotsb`,"\\longleftrightarrow":`\\dotsb`,"\\Longleftrightarrow":`\\dotsb`,"\\mapsto":`\\dotsb`,"\\longmapsto":`\\dotsb`,"\\hookrightarrow":`\\dotsb`,"\\doteq":`\\dotsb`,"\\mathbin":`\\dotsb`,"\\mathrel":`\\dotsb`,"\\relbar":`\\dotsb`,"\\Relbar":`\\dotsb`,"\\xrightarrow":`\\dotsb`,"\\xleftarrow":`\\dotsb`,"\\DOTSI":`\\dotsi`,"\\int":`\\dotsi`,"\\oint":`\\dotsi`,"\\iint":`\\dotsi`,"\\iiint":`\\dotsi`,"\\iiiint":`\\dotsi`,"\\idotsint":`\\dotsi`,"\\DOTSX":`\\dotsx`},ca=new Set([`bin`,`rel`]);$(`\\dots`,function(e){var t=`\\dotso`,n=e.expandAfterFuture().text;return n in sa?t=sa[n]:(n.slice(0,4)===`\\not`||n in A.math&&ca.has(A.math[n].group))&&(t=`\\dotsb`),t});var la={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};$(`\\dotso`,function(e){return e.future().text in la?`\\ldots\\,`:`\\ldots`}),$(`\\dotsc`,function(e){var t=e.future().text;return t in la&&t!==`,`?`\\ldots\\,`:`\\ldots`}),$(`\\cdots`,function(e){return e.future().text in la?`\\@cdots\\,`:`\\@cdots`}),$(`\\dotsb`,`\\cdots`),$(`\\dotsm`,`\\cdots`),$(`\\dotsi`,`\\!\\cdots`),$(`\\dotsx`,`\\ldots\\,`),$(`\\DOTSI`,`\\relax`),$(`\\DOTSB`,`\\relax`),$(`\\DOTSX`,`\\relax`),$(`\\tmspace`,`\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax`),$(`\\,`,`\\tmspace+{3mu}{.1667em}`),$(`\\thinspace`,`\\,`),$(`\\>`,`\\mskip{4mu}`),$(`\\:`,`\\tmspace+{4mu}{.2222em}`),$(`\\medspace`,`\\:`),$(`\\;`,`\\tmspace+{5mu}{.2777em}`),$(`\\thickspace`,`\\;`),$(`\\!`,`\\tmspace-{3mu}{.1667em}`),$(`\\negthinspace`,`\\!`),$(`\\negmedspace`,`\\tmspace-{4mu}{.2222em}`),$(`\\negthickspace`,`\\tmspace-{5mu}{.277em}`),$(`\\enspace`,`\\kern.5em `),$(`\\enskip`,`\\hskip.5em\\relax`),$(`\\quad`,`\\hskip1em\\relax`),$(`\\qquad`,`\\hskip2em\\relax`),$(`\\tag`,`\\@ifstar\\tag@literal\\tag@paren`),$(`\\tag@paren`,`\\tag@literal{({#1})}`),$(`\\tag@literal`,t=>{if(t.macros.get(`\\df@tag`))throw new e(`Multiple \\tag`);return`\\gdef\\df@tag{\\text{#1}}`}),$(`\\bmod`,`\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}`),$(`\\pod`,`\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)`),$(`\\pmod`,`\\pod{{\\rm mod}\\mkern6mu#1}`),$(`\\mod`,`\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1`),$(`\\newline`,`\\\\\\relax`),$(`\\TeX`,`\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}`);var ua=k(Ue[`Main-Regular`][84][1]-.7*Ue[`Main-Regular`][65][1]);$(`\\LaTeX`,`\\textrm{\\html@mathml{`+(`L\\kern-.36em\\raisebox{`+ua+`}{\\scriptstyle A}`)+`\\kern-.15em\\TeX}{LaTeX}}`),$(`\\KaTeX`,`\\textrm{\\html@mathml{`+(`K\\kern-.17em\\raisebox{`+ua+`}{\\scriptstyle A}`)+`\\kern-.15em\\TeX}{KaTeX}}`),$(`\\hspace`,`\\@ifstar\\@hspacer\\@hspace`),$(`\\@hspace`,`\\hskip #1\\relax`),$(`\\@hspacer`,`\\rule{0pt}{0pt}\\hskip #1\\relax`),$(`\\ordinarycolon`,`:`),$(`\\vcentcolon`,`\\mathrel{\\mathop\\ordinarycolon}`),$(`\\dblcolon`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}`),$(`\\coloneqq`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}`),$(`\\Coloneqq`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}`),$(`\\coloneq`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}`),$(`\\Coloneq`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}`),$(`\\eqqcolon`,`\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}`),$(`\\Eqqcolon`,`\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}`),$(`\\eqcolon`,`\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}`),$(`\\Eqcolon`,`\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}`),$(`\\colonapprox`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}`),$(`\\Colonapprox`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}`),$(`\\colonsim`,`\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}`),$(`\\Colonsim`,`\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}`),$(`∷`,`\\dblcolon`),$(`∹`,`\\eqcolon`),$(`≔`,`\\coloneqq`),$(`≕`,`\\eqqcolon`),$(`⩴`,`\\Coloneqq`),$(`\\ratio`,`\\vcentcolon`),$(`\\coloncolon`,`\\dblcolon`),$(`\\colonequals`,`\\coloneqq`),$(`\\coloncolonequals`,`\\Coloneqq`),$(`\\equalscolon`,`\\eqqcolon`),$(`\\equalscoloncolon`,`\\Eqqcolon`),$(`\\colonminus`,`\\coloneq`),$(`\\coloncolonminus`,`\\Coloneq`),$(`\\minuscolon`,`\\eqcolon`),$(`\\minuscoloncolon`,`\\Eqcolon`),$(`\\coloncolonapprox`,`\\Colonapprox`),$(`\\coloncolonsim`,`\\Colonsim`),$(`\\simcolon`,`\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}`),$(`\\simcoloncolon`,`\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}`),$(`\\approxcolon`,`\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}`),$(`\\approxcoloncolon`,`\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}`),$(`\\notni`,"\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}"),$(`\\limsup`,`\\DOTSB\\operatorname*{lim\\,sup}`),$(`\\liminf`,`\\DOTSB\\operatorname*{lim\\,inf}`),$(`\\injlim`,`\\DOTSB\\operatorname*{inj\\,lim}`),$(`\\projlim`,`\\DOTSB\\operatorname*{proj\\,lim}`),$(`\\varlimsup`,`\\DOTSB\\operatorname*{\\overline{lim}}`),$(`\\varliminf`,`\\DOTSB\\operatorname*{\\underline{lim}}`),$(`\\varinjlim`,`\\DOTSB\\operatorname*{\\underrightarrow{lim}}`),$(`\\varprojlim`,`\\DOTSB\\operatorname*{\\underleftarrow{lim}}`),$(`\\gvertneqq`,`\\html@mathml{\\@gvertneqq}{≩}`),$(`\\lvertneqq`,`\\html@mathml{\\@lvertneqq}{≨}`),$(`\\ngeqq`,`\\html@mathml{\\@ngeqq}{≱}`),$(`\\ngeqslant`,`\\html@mathml{\\@ngeqslant}{≱}`),$(`\\nleqq`,`\\html@mathml{\\@nleqq}{≰}`),$(`\\nleqslant`,`\\html@mathml{\\@nleqslant}{≰}`),$(`\\nshortmid`,`\\html@mathml{\\@nshortmid}{∤}`),$(`\\nshortparallel`,`\\html@mathml{\\@nshortparallel}{∦}`),$(`\\nsubseteqq`,`\\html@mathml{\\@nsubseteqq}{⊈}`),$(`\\nsupseteqq`,`\\html@mathml{\\@nsupseteqq}{⊉}`),$(`\\varsubsetneq`,`\\html@mathml{\\@varsubsetneq}{⊊}`),$(`\\varsubsetneqq`,`\\html@mathml{\\@varsubsetneqq}{⫋}`),$(`\\varsupsetneq`,`\\html@mathml{\\@varsupsetneq}{⊋}`),$(`\\varsupsetneqq`,`\\html@mathml{\\@varsupsetneqq}{⫌}`),$(`\\imath`,`\\html@mathml{\\@imath}{ı}`),$(`\\jmath`,`\\html@mathml{\\@jmath}{ȷ}`),$(`\\llbracket`,"\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}"),$(`\\rrbracket`,"\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}"),$(`⟦`,`\\llbracket`),$(`⟧`,`\\rrbracket`),$(`\\lBrace`,"\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}"),$(`\\rBrace`,"\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}"),$(`⦃`,`\\lBrace`),$(`⦄`,`\\rBrace`),$(`\\minuso`,"\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}"),$(`⦵`,`\\minuso`),$(`\\darr`,`\\downarrow`),$(`\\dArr`,`\\Downarrow`),$(`\\Darr`,`\\Downarrow`),$(`\\lang`,`\\langle`),$(`\\rang`,`\\rangle`),$(`\\uarr`,`\\uparrow`),$(`\\uArr`,`\\Uparrow`),$(`\\Uarr`,`\\Uparrow`),$(`\\N`,`\\mathbb{N}`),$(`\\R`,`\\mathbb{R}`),$(`\\Z`,`\\mathbb{Z}`),$(`\\alef`,`\\aleph`),$(`\\alefsym`,`\\aleph`),$(`\\Alpha`,`\\mathrm{A}`),$(`\\Beta`,`\\mathrm{B}`),$(`\\bull`,`\\bullet`),$(`\\Chi`,`\\mathrm{X}`),$(`\\clubs`,`\\clubsuit`),$(`\\cnums`,`\\mathbb{C}`),$(`\\Complex`,`\\mathbb{C}`),$(`\\Dagger`,`\\ddagger`),$(`\\diamonds`,`\\diamondsuit`),$(`\\empty`,`\\emptyset`),$(`\\Epsilon`,`\\mathrm{E}`),$(`\\Eta`,`\\mathrm{H}`),$(`\\exist`,`\\exists`),$(`\\harr`,`\\leftrightarrow`),$(`\\hArr`,`\\Leftrightarrow`),$(`\\Harr`,`\\Leftrightarrow`),$(`\\hearts`,`\\heartsuit`),$(`\\image`,`\\Im`),$(`\\infin`,`\\infty`),$(`\\Iota`,`\\mathrm{I}`),$(`\\isin`,`\\in`),$(`\\Kappa`,`\\mathrm{K}`),$(`\\larr`,`\\leftarrow`),$(`\\lArr`,`\\Leftarrow`),$(`\\Larr`,`\\Leftarrow`),$(`\\lrarr`,`\\leftrightarrow`),$(`\\lrArr`,`\\Leftrightarrow`),$(`\\Lrarr`,`\\Leftrightarrow`),$(`\\Mu`,`\\mathrm{M}`),$(`\\natnums`,`\\mathbb{N}`),$(`\\Nu`,`\\mathrm{N}`),$(`\\Omicron`,`\\mathrm{O}`),$(`\\plusmn`,`\\pm`),$(`\\rarr`,`\\rightarrow`),$(`\\rArr`,`\\Rightarrow`),$(`\\Rarr`,`\\Rightarrow`),$(`\\real`,`\\Re`),$(`\\reals`,`\\mathbb{R}`),$(`\\Reals`,`\\mathbb{R}`),$(`\\Rho`,`\\mathrm{P}`),$(`\\sdot`,`\\cdot`),$(`\\sect`,`\\S`),$(`\\spades`,`\\spadesuit`),$(`\\sub`,`\\subset`),$(`\\sube`,`\\subseteq`),$(`\\supe`,`\\supseteq`),$(`\\Tau`,`\\mathrm{T}`),$(`\\thetasym`,`\\vartheta`),$(`\\weierp`,`\\wp`),$(`\\Zeta`,`\\mathrm{Z}`),$(`\\argmin`,`\\DOTSB\\operatorname*{arg\\,min}`),$(`\\argmax`,`\\DOTSB\\operatorname*{arg\\,max}`),$(`\\plim`,`\\DOTSB\\mathop{\\operatorname{plim}}\\limits`),$(`\\bra`,`\\mathinner{\\langle{#1}|}`),$(`\\ket`,`\\mathinner{|{#1}\\rangle}`),$(`\\braket`,`\\mathinner{\\langle{#1}\\rangle}`),$(`\\Bra`,`\\left\\langle#1\\right|`),$(`\\Ket`,`\\left|#1\\right\\rangle`);var da=e=>t=>{var n=t.consumeArg().tokens,r=t.consumeArg().tokens,i=t.consumeArg().tokens,a=t.consumeArg().tokens,o=t.macros.get(`|`),s=t.macros.get(`\\|`);t.macros.beginGroup();var c=t=>n=>{e&&(n.macros.set(`|`,o),i.length&&n.macros.set(`\\|`,s));var a=t;return!t&&i.length&&n.future().text===`|`&&(n.popToken(),a=!0),{tokens:a?i:r,numArgs:0}};t.macros.set(`|`,c(!1)),i.length&&t.macros.set(`\\|`,c(!0));var l=t.consumeArg().tokens,u=t.expandTokens([...a,...l,...n]);return t.macros.endGroup(),{tokens:u.reverse(),numArgs:0}};$(`\\bra@ket`,da(!1)),$(`\\bra@set`,da(!0)),$(`\\Braket`,`\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}`),$(`\\Set`,`\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}`),$(`\\set`,`\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}`),$(`\\angln`,`{\\angl n}`),$(`\\blue`,`\\textcolor{##6495ed}{#1}`),$(`\\orange`,`\\textcolor{##ffa500}{#1}`),$(`\\pink`,`\\textcolor{##ff00af}{#1}`),$(`\\red`,`\\textcolor{##df0030}{#1}`),$(`\\green`,`\\textcolor{##28ae7b}{#1}`),$(`\\gray`,`\\textcolor{gray}{#1}`),$(`\\purple`,`\\textcolor{##9d38bd}{#1}`),$(`\\blueA`,`\\textcolor{##ccfaff}{#1}`),$(`\\blueB`,`\\textcolor{##80f6ff}{#1}`),$(`\\blueC`,`\\textcolor{##63d9ea}{#1}`),$(`\\blueD`,`\\textcolor{##11accd}{#1}`),$(`\\blueE`,`\\textcolor{##0c7f99}{#1}`),$(`\\tealA`,`\\textcolor{##94fff5}{#1}`),$(`\\tealB`,`\\textcolor{##26edd5}{#1}`),$(`\\tealC`,`\\textcolor{##01d1c1}{#1}`),$(`\\tealD`,`\\textcolor{##01a995}{#1}`),$(`\\tealE`,`\\textcolor{##208170}{#1}`),$(`\\greenA`,`\\textcolor{##b6ffb0}{#1}`),$(`\\greenB`,`\\textcolor{##8af281}{#1}`),$(`\\greenC`,`\\textcolor{##74cf70}{#1}`),$(`\\greenD`,`\\textcolor{##1fab54}{#1}`),$(`\\greenE`,`\\textcolor{##0d923f}{#1}`),$(`\\goldA`,`\\textcolor{##ffd0a9}{#1}`),$(`\\goldB`,`\\textcolor{##ffbb71}{#1}`),$(`\\goldC`,`\\textcolor{##ff9c39}{#1}`),$(`\\goldD`,`\\textcolor{##e07d10}{#1}`),$(`\\goldE`,`\\textcolor{##a75a05}{#1}`),$(`\\redA`,`\\textcolor{##fca9a9}{#1}`),$(`\\redB`,`\\textcolor{##ff8482}{#1}`),$(`\\redC`,`\\textcolor{##f9685d}{#1}`),$(`\\redD`,`\\textcolor{##e84d39}{#1}`),$(`\\redE`,`\\textcolor{##bc2612}{#1}`),$(`\\maroonA`,`\\textcolor{##ffbde0}{#1}`),$(`\\maroonB`,`\\textcolor{##ff92c6}{#1}`),$(`\\maroonC`,`\\textcolor{##ed5fa6}{#1}`),$(`\\maroonD`,`\\textcolor{##ca337c}{#1}`),$(`\\maroonE`,`\\textcolor{##9e034e}{#1}`),$(`\\purpleA`,`\\textcolor{##ddd7ff}{#1}`),$(`\\purpleB`,`\\textcolor{##c6b9fc}{#1}`),$(`\\purpleC`,`\\textcolor{##aa87ff}{#1}`),$(`\\purpleD`,`\\textcolor{##7854ab}{#1}`),$(`\\purpleE`,`\\textcolor{##543b78}{#1}`),$(`\\mintA`,`\\textcolor{##f5f9e8}{#1}`),$(`\\mintB`,`\\textcolor{##edf2df}{#1}`),$(`\\mintC`,`\\textcolor{##e0e5cc}{#1}`),$(`\\grayA`,`\\textcolor{##f6f7f7}{#1}`),$(`\\grayB`,`\\textcolor{##f0f1f2}{#1}`),$(`\\grayC`,`\\textcolor{##e3e5e6}{#1}`),$(`\\grayD`,`\\textcolor{##d6d8da}{#1}`),$(`\\grayE`,`\\textcolor{##babec2}{#1}`),$(`\\grayF`,`\\textcolor{##888d93}{#1}`),$(`\\grayG`,`\\textcolor{##626569}{#1}`),$(`\\grayH`,`\\textcolor{##3b3e40}{#1}`),$(`\\grayI`,`\\textcolor{##21242c}{#1}`),$(`\\kaBlue`,`\\textcolor{##314453}{#1}`),$(`\\kaGreen`,`\\textcolor{##71B307}{#1}`);var fa={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0},pa=class{constructor(e,t,n){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=t,this.expansionCount=0,this.feed(e),this.macros=new ra(ia,t.macros),this.mode=n,this.stack=[]}feed(e){this.lexer=new na(e,this.settings)}switchMode(e){this.mode=e}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return this.stack.length===0&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(e){this.stack.push(e)}pushTokens(e){this.stack.push(...e)}scanArgument(e){var t,n,r;if(e){if(this.consumeSpaces(),this.future().text!==`[`)return null;t=this.popToken(),{tokens:r,end:n}=this.consumeArg([`]`])}else({tokens:r,start:t,end:n}=this.consumeArg());return this.pushToken(new ri(`EOF`,n.loc)),this.pushTokens(r),new ri(``,ni.range(t,n))}consumeSpaces(){for(;this.future().text===` `;)this.stack.pop()}consumeArg(t){var n=[],r=t&&t.length>0;r||this.consumeSpaces();var i=this.future(),a,o=0,s=0;do{if(a=this.popToken(),n.push(a),a.text===`{`)++o;else if(a.text===`}`){if(--o,o===-1)throw new e(`Extra }`,a)}else if(a.text===`EOF`)throw new e(`Unexpected end of input in a macro argument, expected '`+(t&&r?t[s]:`}`)+`'`,a);if(t&&r){if((o===0||o===1&&t[s]===`{`)&&a.text===t[s]){if(++s,s===t.length){n.splice(-s,s);break}}else s=0}}while(o!==0||r);return i.text===`{`&&n[n.length-1].text===`}`&&(n.pop(),n.shift()),n.reverse(),{tokens:n,start:i,end:a}}consumeArgs(t,n){if(n){if(n.length!==t+1)throw new e(`The length of delimiters doesn't match the number of args!`);for(var r=n[0],i=0;ithis.settings.maxExpand)throw new e(`Too many expansions: infinite loop or need to increase maxExpand setting`)}expandOnce(t){var n=this.popToken(),r=n.text,i=n.noexpand?null:this._getExpansion(r);if(i==null||t&&i.unexpandable){if(t&&i==null&&r[0]===`\\`&&!this.isDefined(r))throw new e(`Undefined control sequence: `+r);return this.pushToken(n),!1}this.countExpansion(1);var a=i.tokens,o=this.consumeArgs(i.numArgs,i.delimiters);if(i.numArgs){a=a.slice();for(var s=a.length-1;s>=0;--s){var c=a[s];if(c.text===`#`){if(s===0)throw new e(`Incomplete placeholder at end of macro body`,c);if(c=a[--s],c.text===`#`)a.splice(s+1,1);else if(/^[1-9]$/.test(c.text))a.splice(s,2,...o[c.text-1]);else throw new e(`Not a valid argument number`,c)}}}return this.pushTokens(a),a.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(this.expandOnce()===!1){var e=this.stack.pop();return e.treatAsRelax&&(e.text=`\\relax`),e}}expandMacro(e){return this.macros.has(e)?this.expandTokens([new ri(e)]):void 0}expandTokens(e){var t=[],n=this.stack.length;for(this.pushTokens(e);this.stack.length>n;)if(this.expandOnce(!0)===!1){var r=this.stack.pop();r.treatAsRelax&&=(r.noexpand=!1,!1),t.push(r)}return this.countExpansion(t.length),t}expandMacroAsText(e){var t=this.expandMacro(e);return t&&t.map(e=>e.text).join(``)}_getExpansion(e){var t=this.macros.get(e);if(t==null)return t;if(e.length===1){var n=this.lexer.catcodes[e];if(n!=null&&n!==13)return}var r=typeof t==`function`?t(this):t;if(typeof r==`string`){var i=0;if(r.includes(`#`))for(var a=r.replace(/##/g,``);a.includes(`#`+(i+1));)++i;for(var o=new na(r,this.settings),s=[],c=o.lex();c.text!==`EOF`;)s.push(c),c=o.lex();return s.reverse(),{tokens:s,numArgs:i}}return r}isDefined(e){return this.macros.has(e)||qi.hasOwnProperty(e)||A.math.hasOwnProperty(e)||A.text.hasOwnProperty(e)||fa.hasOwnProperty(e)}isExpandable(e){var t=this.macros.get(e);return t==null?qi.hasOwnProperty(e)&&!qi[e].primitive:typeof t==`string`||typeof t==`function`||!t.unexpandable}},ma=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,ha=Object.freeze({"₊":`+`,"₋":`-`,"₌":`=`,"₍":`(`,"₎":`)`,"₀":`0`,"₁":`1`,"₂":`2`,"₃":`3`,"₄":`4`,"₅":`5`,"₆":`6`,"₇":`7`,"₈":`8`,"₉":`9`,ₐ:`a`,ₑ:`e`,ₕ:`h`,ᵢ:`i`,ⱼ:`j`,ₖ:`k`,ₗ:`l`,ₘ:`m`,ₙ:`n`,ₒ:`o`,ₚ:`p`,ᵣ:`r`,ₛ:`s`,ₜ:`t`,ᵤ:`u`,ᵥ:`v`,ₓ:`x`,ᵦ:`β`,ᵧ:`γ`,ᵨ:`ρ`,ᵩ:`ϕ`,ᵪ:`χ`,"⁺":`+`,"⁻":`-`,"⁼":`=`,"⁽":`(`,"⁾":`)`,"⁰":`0`,"¹":`1`,"²":`2`,"³":`3`,"⁴":`4`,"⁵":`5`,"⁶":`6`,"⁷":`7`,"⁸":`8`,"⁹":`9`,ᴬ:`A`,ᴮ:`B`,ᴰ:`D`,ᴱ:`E`,ᴳ:`G`,ᴴ:`H`,ᴵ:`I`,ᴶ:`J`,ᴷ:`K`,ᴸ:`L`,ᴹ:`M`,ᴺ:`N`,ᴼ:`O`,ᴾ:`P`,ᴿ:`R`,ᵀ:`T`,ᵁ:`U`,ⱽ:`V`,ᵂ:`W`,ᵃ:`a`,ᵇ:`b`,ᶜ:`c`,ᵈ:`d`,ᵉ:`e`,ᶠ:`f`,ᵍ:`g`,ʰ:`h`,ⁱ:`i`,ʲ:`j`,ᵏ:`k`,ˡ:`l`,ᵐ:`m`,ⁿ:`n`,ᵒ:`o`,ᵖ:`p`,ʳ:`r`,ˢ:`s`,ᵗ:`t`,ᵘ:`u`,ᵛ:`v`,ʷ:`w`,ˣ:`x`,ʸ:`y`,ᶻ:`z`,ᵝ:`β`,ᵞ:`γ`,ᵟ:`δ`,ᵠ:`ϕ`,ᵡ:`χ`,ᶿ:`θ`}),ga={"́":{text:`\\'`,math:`\\acute`},"̀":{text:"\\`",math:`\\grave`},"̈":{text:`\\"`,math:`\\ddot`},"̃":{text:`\\~`,math:`\\tilde`},"̄":{text:`\\=`,math:`\\bar`},"̆":{text:`\\u`,math:`\\breve`},"̌":{text:`\\v`,math:`\\check`},"̂":{text:`\\^`,math:`\\hat`},"̇":{text:`\\.`,math:`\\dot`},"̊":{text:`\\r`,math:`\\mathring`},"̋":{text:`\\H`},"̧":{text:`\\c`}},_a={á:`á`,à:`à`,ä:`ä`,ǟ:`ǟ`,ã:`ã`,ā:`ā`,ă:`ă`,ắ:`ắ`,ằ:`ằ`,ẵ:`ẵ`,ǎ:`ǎ`,â:`â`,ấ:`ấ`,ầ:`ầ`,ẫ:`ẫ`,ȧ:`ȧ`,ǡ:`ǡ`,å:`å`,ǻ:`ǻ`,ḃ:`ḃ`,ć:`ć`,ḉ:`ḉ`,č:`č`,ĉ:`ĉ`,ċ:`ċ`,ç:`ç`,ď:`ď`,ḋ:`ḋ`,ḑ:`ḑ`,é:`é`,è:`è`,ë:`ë`,ẽ:`ẽ`,ē:`ē`,ḗ:`ḗ`,ḕ:`ḕ`,ĕ:`ĕ`,ḝ:`ḝ`,ě:`ě`,ê:`ê`,ế:`ế`,ề:`ề`,ễ:`ễ`,ė:`ė`,ȩ:`ȩ`,ḟ:`ḟ`,ǵ:`ǵ`,ḡ:`ḡ`,ğ:`ğ`,ǧ:`ǧ`,ĝ:`ĝ`,ġ:`ġ`,ģ:`ģ`,ḧ:`ḧ`,ȟ:`ȟ`,ĥ:`ĥ`,ḣ:`ḣ`,ḩ:`ḩ`,í:`í`,ì:`ì`,ï:`ï`,ḯ:`ḯ`,ĩ:`ĩ`,ī:`ī`,ĭ:`ĭ`,ǐ:`ǐ`,î:`î`,ǰ:`ǰ`,ĵ:`ĵ`,ḱ:`ḱ`,ǩ:`ǩ`,ķ:`ķ`,ĺ:`ĺ`,ľ:`ľ`,ļ:`ļ`,ḿ:`ḿ`,ṁ:`ṁ`,ń:`ń`,ǹ:`ǹ`,ñ:`ñ`,ň:`ň`,ṅ:`ṅ`,ņ:`ņ`,ó:`ó`,ò:`ò`,ö:`ö`,ȫ:`ȫ`,õ:`õ`,ṍ:`ṍ`,ṏ:`ṏ`,ȭ:`ȭ`,ō:`ō`,ṓ:`ṓ`,ṑ:`ṑ`,ŏ:`ŏ`,ǒ:`ǒ`,ô:`ô`,ố:`ố`,ồ:`ồ`,ỗ:`ỗ`,ȯ:`ȯ`,ȱ:`ȱ`,ő:`ő`,ṕ:`ṕ`,ṗ:`ṗ`,ŕ:`ŕ`,ř:`ř`,ṙ:`ṙ`,ŗ:`ŗ`,ś:`ś`,ṥ:`ṥ`,š:`š`,ṧ:`ṧ`,ŝ:`ŝ`,ṡ:`ṡ`,ş:`ş`,ẗ:`ẗ`,ť:`ť`,ṫ:`ṫ`,ţ:`ţ`,ú:`ú`,ù:`ù`,ü:`ü`,ǘ:`ǘ`,ǜ:`ǜ`,ǖ:`ǖ`,ǚ:`ǚ`,ũ:`ũ`,ṹ:`ṹ`,ū:`ū`,ṻ:`ṻ`,ŭ:`ŭ`,ǔ:`ǔ`,û:`û`,ů:`ů`,ű:`ű`,ṽ:`ṽ`,ẃ:`ẃ`,ẁ:`ẁ`,ẅ:`ẅ`,ŵ:`ŵ`,ẇ:`ẇ`,ẘ:`ẘ`,ẍ:`ẍ`,ẋ:`ẋ`,ý:`ý`,ỳ:`ỳ`,ÿ:`ÿ`,ỹ:`ỹ`,ȳ:`ȳ`,ŷ:`ŷ`,ẏ:`ẏ`,ẙ:`ẙ`,ź:`ź`,ž:`ž`,ẑ:`ẑ`,ż:`ż`,Á:`Á`,À:`À`,Ä:`Ä`,Ǟ:`Ǟ`,Ã:`Ã`,Ā:`Ā`,Ă:`Ă`,Ắ:`Ắ`,Ằ:`Ằ`,Ẵ:`Ẵ`,Ǎ:`Ǎ`,Â:`Â`,Ấ:`Ấ`,Ầ:`Ầ`,Ẫ:`Ẫ`,Ȧ:`Ȧ`,Ǡ:`Ǡ`,Å:`Å`,Ǻ:`Ǻ`,Ḃ:`Ḃ`,Ć:`Ć`,Ḉ:`Ḉ`,Č:`Č`,Ĉ:`Ĉ`,Ċ:`Ċ`,Ç:`Ç`,Ď:`Ď`,Ḋ:`Ḋ`,Ḑ:`Ḑ`,É:`É`,È:`È`,Ë:`Ë`,Ẽ:`Ẽ`,Ē:`Ē`,Ḗ:`Ḗ`,Ḕ:`Ḕ`,Ĕ:`Ĕ`,Ḝ:`Ḝ`,Ě:`Ě`,Ê:`Ê`,Ế:`Ế`,Ề:`Ề`,Ễ:`Ễ`,Ė:`Ė`,Ȩ:`Ȩ`,Ḟ:`Ḟ`,Ǵ:`Ǵ`,Ḡ:`Ḡ`,Ğ:`Ğ`,Ǧ:`Ǧ`,Ĝ:`Ĝ`,Ġ:`Ġ`,Ģ:`Ģ`,Ḧ:`Ḧ`,Ȟ:`Ȟ`,Ĥ:`Ĥ`,Ḣ:`Ḣ`,Ḩ:`Ḩ`,Í:`Í`,Ì:`Ì`,Ï:`Ï`,Ḯ:`Ḯ`,Ĩ:`Ĩ`,Ī:`Ī`,Ĭ:`Ĭ`,Ǐ:`Ǐ`,Î:`Î`,İ:`İ`,Ĵ:`Ĵ`,Ḱ:`Ḱ`,Ǩ:`Ǩ`,Ķ:`Ķ`,Ĺ:`Ĺ`,Ľ:`Ľ`,Ļ:`Ļ`,Ḿ:`Ḿ`,Ṁ:`Ṁ`,Ń:`Ń`,Ǹ:`Ǹ`,Ñ:`Ñ`,Ň:`Ň`,Ṅ:`Ṅ`,Ņ:`Ņ`,Ó:`Ó`,Ò:`Ò`,Ö:`Ö`,Ȫ:`Ȫ`,Õ:`Õ`,Ṍ:`Ṍ`,Ṏ:`Ṏ`,Ȭ:`Ȭ`,Ō:`Ō`,Ṓ:`Ṓ`,Ṑ:`Ṑ`,Ŏ:`Ŏ`,Ǒ:`Ǒ`,Ô:`Ô`,Ố:`Ố`,Ồ:`Ồ`,Ỗ:`Ỗ`,Ȯ:`Ȯ`,Ȱ:`Ȱ`,Ő:`Ő`,Ṕ:`Ṕ`,Ṗ:`Ṗ`,Ŕ:`Ŕ`,Ř:`Ř`,Ṙ:`Ṙ`,Ŗ:`Ŗ`,Ś:`Ś`,Ṥ:`Ṥ`,Š:`Š`,Ṧ:`Ṧ`,Ŝ:`Ŝ`,Ṡ:`Ṡ`,Ş:`Ş`,Ť:`Ť`,Ṫ:`Ṫ`,Ţ:`Ţ`,Ú:`Ú`,Ù:`Ù`,Ü:`Ü`,Ǘ:`Ǘ`,Ǜ:`Ǜ`,Ǖ:`Ǖ`,Ǚ:`Ǚ`,Ũ:`Ũ`,Ṹ:`Ṹ`,Ū:`Ū`,Ṻ:`Ṻ`,Ŭ:`Ŭ`,Ǔ:`Ǔ`,Û:`Û`,Ů:`Ů`,Ű:`Ű`,Ṽ:`Ṽ`,Ẃ:`Ẃ`,Ẁ:`Ẁ`,Ẅ:`Ẅ`,Ŵ:`Ŵ`,Ẇ:`Ẇ`,Ẍ:`Ẍ`,Ẋ:`Ẋ`,Ý:`Ý`,Ỳ:`Ỳ`,Ÿ:`Ÿ`,Ỹ:`Ỹ`,Ȳ:`Ȳ`,Ŷ:`Ŷ`,Ẏ:`Ẏ`,Ź:`Ź`,Ž:`Ž`,Ẑ:`Ẑ`,Ż:`Ż`,ά:`ά`,ὰ:`ὰ`,ᾱ:`ᾱ`,ᾰ:`ᾰ`,έ:`έ`,ὲ:`ὲ`,ή:`ή`,ὴ:`ὴ`,ί:`ί`,ὶ:`ὶ`,ϊ:`ϊ`,ΐ:`ΐ`,ῒ:`ῒ`,ῑ:`ῑ`,ῐ:`ῐ`,ό:`ό`,ὸ:`ὸ`,ύ:`ύ`,ὺ:`ὺ`,ϋ:`ϋ`,ΰ:`ΰ`,ῢ:`ῢ`,ῡ:`ῡ`,ῠ:`ῠ`,ώ:`ώ`,ὼ:`ὼ`,Ύ:`Ύ`,Ὺ:`Ὺ`,Ϋ:`Ϋ`,Ῡ:`Ῡ`,Ῠ:`Ῠ`,Ώ:`Ώ`,Ὼ:`Ὼ`},va=class t{constructor(e,t){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode=`math`,this.gullet=new pa(e,t,this.mode),this.settings=t,this.leftrightDepth=0,this.nextToken=null}expect(t,n){if(n===void 0&&(n=!0),this.fetch().text!==t)throw new e(`Expected '`+t+`', got '`+this.fetch().text+`'`,this.fetch());n&&this.consume()}consume(){this.nextToken=null}fetch(){return this.nextToken??=this.gullet.expandNextToken(),this.nextToken}switchMode(e){this.mode=e,this.gullet.switchMode(e)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set(`\\color`,`\\textcolor`);try{var e=this.parseExpression(!1);return this.expect(`EOF`),this.settings.globalGroup||this.gullet.endGroup(),e}finally{this.gullet.endGroups()}}subparse(e){var t=this.nextToken;this.consume(),this.gullet.pushToken(new ri(`}`)),this.gullet.pushTokens(e);var n=this.parseExpression(!1);return this.expect(`}`),this.nextToken=t,n}parseExpression(e,n){for(var r=[];;){this.mode===`math`&&this.consumeSpaces();var i=this.fetch();if(t.endOfExpression.has(i.text)||n&&i.text===n||e&&qi[i.text]&&qi[i.text].infix)break;var a=this.parseAtom(n);if(!a)break;a.type!==`internal`&&r.push(a)}return this.mode===`text`&&this.formLigatures(r),this.handleInfixNodes(r)}handleInfixNodes(t){for(var n=-1,r,i=0;i=128)this.settings.strict&&(ce(n.charCodeAt(0))?this.mode===`math`&&this.settings.reportNonstrict(`unicodeTextInMathMode`,`Unicode text character "`+n[0]+`" used in math mode`,t):this.settings.reportNonstrict(`unknownSymbol`,`Unrecognized Unicode character "`+n[0]+`"`+(` (`+n.charCodeAt(0)+`)`),t)),o={type:`textord`,mode:`text`,loc:ni.range(t),text:n};else return null;if(this.consume(),a)for(var l=0;lt?1:e>=t?0:NaN}function d(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function f(e){let t,n,r;e.length===2?(t=e===u||e===d?e:p,n=e,r=e):(t=u,n=(t,n)=>u(e(t),n),r=(t,n)=>e(t)-n);function i(e,r,i=0,a=e.length){if(i>>1;n(e[t],r)<0?i=t+1:a=t}while(i>>1;n(e[t],r)<=0?i=t+1:a=t}while(in&&r(e[o-1],t)>-r(e[o],t)?o-1:o}return{left:i,center:o,right:a}}function p(){return 0}function m(e){return e===null?NaN:+e}var h=f(u),g=h.right;h.left,f(m).center;var _=Math.sqrt(50),v=Math.sqrt(10),y=Math.sqrt(2);function b(e,t,n){let r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/10**i,o=a>=_?10:a>=v?5:a>=y?2:1,s,c,l;return i<0?(l=10**-i/o,s=Math.round(e*l),c=Math.round(t*l),s/lt&&--c,l=-l):(l=10**i*o,s=Math.round(e/l),c=Math.round(t/l),s*lt&&--c),c0))return[];if(e===t)return[e];let r=t=i))return[];let s=a-i+1,c=Array(s);if(r){if(o<0)for(let e=0;et&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}function B(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i2?V:B,l=u=null,f}function f(t){return t==null||isNaN(t=+t)?o:(l||=c(e.map(i),n,r))(i(s(t)))}return f.invert=function(r){return s(a((u||=c(n,e.map(i),t))(r)))},f.domain=function(t){return arguments.length?(e=Array.from(t,F),d()):e.slice()},f.range=function(e){return arguments.length?(n=Array.from(e),d()):n.slice()},f.rangeRound=function(e){return n=Array.from(e),r=A,d()},f.clamp=function(e){return arguments.length?(s=e?!0:L,d()):s!==L},f.interpolate=function(e){return arguments.length?(r=e,d()):r},f.unknown=function(e){return arguments.length?(o=e,f):o},function(e,t){return i=e,a=t,d()}}function W(){return U()(L,L)}function G(e,t,n,r){var i=C(e,t,n),a;switch(r=s(r??`,f`),r.type){case`s`:var l=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=M(i,l))&&(r.precision=a),o(r,l);case``:case`e`:case`g`:case`p`:case`r`:r.precision==null&&!isNaN(a=N(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type===`e`));break;case`f`:case`%`:r.precision==null&&!isNaN(a=j(i))&&(r.precision=a-(r.type===`%`)*2)}return c(r)}function K(e){var t=e.domain;return e.ticks=function(e){var n=t();return x(n[0],n[n.length-1],e??10)},e.tickFormat=function(e,n){var r=t();return G(r[0],r[r.length-1],e??10,n)},e.nice=function(n){n??=10;var r=t(),i=0,a=r.length-1,o=r[i],s=r[a],c,l,u=10;for(s0;){if(l=S(o,s,n),l===c)return r[i]=o,r[a]=s,t(r);if(l>0)o=Math.floor(o/l)*l,s=Math.ceil(s/l)*l;else if(l<0)o=Math.ceil(o*l)/l,s=Math.floor(s*l)/l;else break;c=l}return e},e}function q(){var e=W();return e.copy=function(){return H(e,q())},l.apply(e,arguments),K(e)}export{f as a,C as i,W as n,H as r,q as t}; \ No newline at end of file diff --git a/www/assets/mermaid-parser.core-CUrDj5TF.js b/www/assets/mermaid-parser.core-CUrDj5TF.js new file mode 100644 index 0000000..1ff5673 --- /dev/null +++ b/www/assets/mermaid-parser.core-CUrDj5TF.js @@ -0,0 +1,7 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/info-A6RAGUB7-CjXYSfue.js","assets/chunk-FOHPRMQF-DHwB1DNv.js","assets/packet-AYTQ26CC-f7lhlK2y.js","assets/pie-WAS4IAKB-BbyREufe.js","assets/treeView-Q6P3EWNA-Bck3TsQB.js","assets/architecture-7GRP2DOG-B7cjyaKW.js","assets/gitGraph-4MIJSDKK-DroQcAWn.js","assets/eventmodeling-NTZA5JFV-CetGhGTA.js","assets/radar-RG4KPBEZ-BsN_WAuk.js","assets/railroad-74A4TZTK-CYJJ-7AP.js","assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js","assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js","assets/railroad-peg-WCYAUIDC-CNjo3yz4.js","assets/treemap-WGGIJYW6-BVec3Jfs.js","assets/wardley-WFR3VGLG-kIjJw24i.js","assets/cynefin-OW5HDTMX-DebjIew_.js"])))=>i.map(i=>d[i]); +import{et as e}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{C as t,S as n,_ as r,a as i,b as a,c as o,d as ee,f as te,g as ne,h as re,i as s,l as ie,m as ae,n as c,o as l,p as oe,r as se,s as ce,t as u,u as d,v as le,w as f,x as p,y as ue}from"./chunk-FOHPRMQF-DHwB1DNv.js";var de=class extends u{static{p(this,`ArchitectureTokenBuilder`)}constructor(){super([`architecture`])}},fe=class extends c{static{p(this,`ArchitectureValueConverter`)}runCustomConverter(e,t,n){if(e.name===`ARCH_ICON`)return t.replace(/[()]/g,``).trim();if(e.name===`ARCH_TEXT_ICON`)return t.replace(/["()]/g,``);if(e.name===`ARCH_TITLE`){let e=t.replace(/^\[|]$/g,``).trim();return(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))&&(e=e.slice(1,-1),e=e.replace(/\\"/g,`"`).replace(/\\'/g,`'`)),e.trim()}}},m={parser:{TokenBuilder:p(()=>new de,`TokenBuilder`),ValueConverter:p(()=>new fe,`ValueConverter`)}};function h(e=l){let r=f(t(e),d),i=f(n({shared:r}),se,m);return r.ServiceRegistry.register(i),{shared:r,Architecture:i}}p(h,`createArchitectureServices`);var pe=class extends u{static{p(this,`CynefinTokenBuilder`)}constructor(){super([`cynefin-beta`])}},g={parser:{TokenBuilder:p(()=>new pe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function _(e=l){let r=f(t(e),d),a=f(n({shared:r}),i,g);return r.ServiceRegistry.register(a),{shared:r,Cynefin:a}}p(_,`createCynefinServices`);var me=class extends u{static{p(this,`EventModelingTokenBuilder`)}constructor(){super([`eventmodeling`])}},v=new Set([`cmd`,`command`]),y=new Set([`evt`,`event`]),b=new Set([`rmo`,`readmodel`]),x=new Set([`pcr`,`processor`]),S=new Set([`ui`]);function C(e){let t=e.validation.EventModelingValidator,n=e.validation.ValidationRegistry;if(n){let e={EmTimeFrame:t.checkSourceFrameTypes.bind(t),EmResetFrame:t.checkSourceFrameTypes.bind(t)};n.register(e,t)}}p(C,`registerValidationChecks`);var he=class{static{p(this,`EventModelingValidator`)}checkSourceFrameTypes(e,t){e.sourceFrames.length!==0&&(v.has(e.modelEntityType)?this.validateSources(e,new Set([...S,...x]),`command`,`ui or processor`,t):y.has(e.modelEntityType)?this.validateSources(e,v,`event`,`command`,t):b.has(e.modelEntityType)?this.validateSources(e,y,`read model`,`event`,t):x.has(e.modelEntityType)?this.validateSources(e,b,`processor`,`read model`,t):S.has(e.modelEntityType)&&this.validateSources(e,b,`ui`,`read model`,t))}validateSources(e,t,n,r,i){for(let a of e.sourceFrames){let o=a.ref;o!==void 0&&!t.has(o.modelEntityType)&&i(`error`,`A ${n} can only receive input from a ${r}, not from '${o.modelEntityType}'.`,{node:e,property:`sourceFrames`})}}},w={parser:{TokenBuilder:p(()=>new me,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)},validation:{EventModelingValidator:p(()=>new he,`EventModelingValidator`)}};function T(e=l){let r=f(t(e),d),i=f(n({shared:r}),ce,w);return r.ServiceRegistry.register(i),C(i),{shared:r,EventModel:i}}p(T,`createEventModelingServices`);var ge=class extends u{static{p(this,`GitGraphTokenBuilder`)}constructor(){super([`gitGraph`])}},E={parser:{TokenBuilder:p(()=>new ge,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function D(e=l){let r=f(t(e),d),i=f(n({shared:r}),o,E);return r.ServiceRegistry.register(i),{shared:r,GitGraph:i}}p(D,`createGitGraphServices`);var _e=class extends u{static{p(this,`InfoTokenBuilder`)}constructor(){super([`info`,`showInfo`])}},O={parser:{TokenBuilder:p(()=>new _e,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function k(e=l){let r=f(t(e),d),i=f(n({shared:r}),ie,O);return r.ServiceRegistry.register(i),{shared:r,Info:i}}p(k,`createInfoServices`);var ve=class extends u{static{p(this,`PacketTokenBuilder`)}constructor(){super([`packet`])}},A={parser:{TokenBuilder:p(()=>new ve,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function j(e=l){let r=f(t(e),d),i=f(n({shared:r}),ee,A);return r.ServiceRegistry.register(i),{shared:r,Packet:i}}p(j,`createPacketServices`);var ye=class extends u{static{p(this,`PieTokenBuilder`)}constructor(){super([`pie`,`showData`])}},be=class extends c{static{p(this,`PieValueConverter`)}runCustomConverter(e,t,n){if(e.name===`PIE_SECTION_LABEL`)return t.replace(/"/g,``).trim()}},M={parser:{TokenBuilder:p(()=>new ye,`TokenBuilder`),ValueConverter:p(()=>new be,`ValueConverter`)}};function N(e=l){let r=f(t(e),d),i=f(n({shared:r}),te,M);return r.ServiceRegistry.register(i),{shared:r,Pie:i}}p(N,`createPieServices`);var xe=class extends u{static{p(this,`RadarTokenBuilder`)}constructor(){super([`radar-beta`])}},P={parser:{TokenBuilder:p(()=>new xe,`TokenBuilder`),ValueConverter:p(()=>new s,`ValueConverter`)}};function F(e=l){let r=f(t(e),d),i=f(n({shared:r}),oe,P);return r.ServiceRegistry.register(i),{shared:r,Radar:i}}p(F,`createRadarServices`);var Se=class extends u{static{p(this,`RailroadTokenBuilder`)}constructor(){super([`railroad-beta`])}},I=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew Se,`TokenBuilder`),ValueConverter:p(()=>new Ce,`ValueConverter`)}};function we(e=l){let r=f(t(e),d),i=f(n({shared:r}),ne,L);return r.ServiceRegistry.register(i),{shared:r,Railroad:i}}p(we,`createRailroadServices`);var Te=class extends u{static{p(this,`RailroadAbnfTokenBuilder`)}constructor(){super([`railroad-abnf-beta`])}},Ee=class extends c{static{p(this,`RailroadAbnfValueConverter`)}runConverter(e,t,n){let r=super.runConverter(e,t,n);if(e.name===`TITLE`&&typeof r==`string`){let e=r.trim();if(e.startsWith(`"`)&&e.endsWith(`"`)||e.startsWith(`'`)&&e.endsWith(`'`))return e.slice(1,-1)}return r}runCustomConverter(e,t,n){if(e.name===`ABNF_STRING`)return t.slice(1,-1)}},R={parser:{TokenBuilder:p(()=>new Te,`TokenBuilder`),ValueConverter:p(()=>new Ee,`ValueConverter`)}};function z(e=l){let r=f(t(e),d),i=f(n({shared:r}),ae,R);return r.ServiceRegistry.register(i),{shared:r,RailroadAbnf:i}}p(z,`createRailroadAbnfServices`);var De=class extends u{static{p(this,`RailroadEbnfTokenBuilder`)}constructor(){super([`railroad-ebnf-beta`])}},B=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew De,`TokenBuilder`),ValueConverter:p(()=>new Oe,`ValueConverter`)}};function H(e=l){let r=f(t(e),d),i=f(n({shared:r}),re,V);return r.ServiceRegistry.register(i),{shared:r,RailroadEbnf:i}}p(H,`createRailroadEbnfServices`);var ke=class extends u{static{p(this,`RailroadPegTokenBuilder`)}constructor(){super([`railroad-peg-beta`])}},U=p(e=>{let t=e.slice(1,-1),n=``;for(let e=0;enew ke,`TokenBuilder`),ValueConverter:p(()=>new Ae,`ValueConverter`)}};function G(e=l){let i=f(t(e),d),a=f(n({shared:i}),r,W);return i.ServiceRegistry.register(a),{shared:i,RailroadPeg:a}}p(G,`createRailroadPegServices`);var je=class extends c{static{p(this,`TreeViewValueConverter`)}runCustomConverter(e,t,n){if(e.name===`INDENTATION`)return t?.length||0;if(e.name===`QUOTED_NAME`)return t.substring(1,t.length-1);if(e.name===`BARE_NAME`)return t.replace(/[\t ]+$/,``);if(e.name===`CLASS_ANNOTATION`)return t.trim().substring(3).trim();if(e.name===`ICON_ANNOTATION`){let e=t.trim();return e.substring(5,e.length-1)}if(e.name===`DESC_ANNOTATION`)return t.trim().substring(2).trim()}},Me=class extends u{static{p(this,`TreeViewTokenBuilder`)}constructor(){super([`treeView-beta`])}},K={parser:{TokenBuilder:p(()=>new Me,`TokenBuilder`),ValueConverter:p(()=>new je,`ValueConverter`)}};function q(e=l){let r=f(t(e),d),i=f(n({shared:r}),le,K);return r.ServiceRegistry.register(i),{shared:r,TreeView:i}}p(q,`createTreeViewServices`);var Ne=class extends u{static{p(this,`TreemapTokenBuilder`)}constructor(){super([`treemap`])}},Pe=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,Fe=class extends c{static{p(this,`TreemapValueConverter`)}runCustomConverter(e,t,n){if(e.name===`NUMBER2`)return parseFloat(t.replace(/,/g,``));if(e.name===`SEPARATOR`||e.name===`STRING2`)return t.substring(1,t.length-1);if(e.name===`INDENTATION`)return t.length;if(e.name===`ClassDef`){if(typeof t!=`string`)return t;let e=Pe.exec(t);if(e)return{$type:`ClassDefStatement`,className:e[1],styleText:e[2]||void 0}}}};function J(e){let t=e.validation.TreemapValidator,n=e.validation.ValidationRegistry;if(n){let e={Treemap:t.checkSingleRoot.bind(t)};n.register(e,t)}}p(J,`registerValidationChecks`);var Ie=class{static{p(this,`TreemapValidator`)}checkSingleRoot(e,t){let n;for(let r of e.TreemapRows)r.item&&(n===void 0&&r.indent===void 0?n=0:(r.indent===void 0||n!==void 0&&n>=parseInt(r.indent,10))&&t(`error`,`Multiple root nodes are not allowed in a treemap.`,{node:r,property:`item`}))}},Y={parser:{TokenBuilder:p(()=>new Ne,`TokenBuilder`),ValueConverter:p(()=>new Fe,`ValueConverter`)},validation:{TreemapValidator:p(()=>new Ie,`TreemapValidator`)}};function X(e=l){let r=f(t(e),d),i=f(n({shared:r}),ue,Y);return r.ServiceRegistry.register(i),J(i),{shared:r,Treemap:i}}p(X,`createTreemapServices`);var Le=class extends c{static{p(this,`WardleyValueConverter`)}runCustomConverter(e,t,n){switch(e.name.toUpperCase()){case`LINK_LABEL`:return t.substring(1).trim();default:return}}},Z={parser:{ValueConverter:p(()=>new Le,`ValueConverter`)}};function Q(e=l){let r=f(t(e),d),i=f(n({shared:r}),a,Z);return r.ServiceRegistry.register(i),{shared:r,Wardley:i}}p(Q,`createWardleyServices`);var $={},Re={info:p(async()=>{let{createInfoServices:t}=await e(async()=>{let{createInfoServices:e}=await import(`./info-A6RAGUB7-CjXYSfue.js`);return{createInfoServices:e}},__vite__mapDeps([0,1]));$.info=t().Info.parser.LangiumParser},`info`),packet:p(async()=>{let{createPacketServices:t}=await e(async()=>{let{createPacketServices:e}=await import(`./packet-AYTQ26CC-f7lhlK2y.js`);return{createPacketServices:e}},__vite__mapDeps([2,1]));$.packet=t().Packet.parser.LangiumParser},`packet`),pie:p(async()=>{let{createPieServices:t}=await e(async()=>{let{createPieServices:e}=await import(`./pie-WAS4IAKB-BbyREufe.js`);return{createPieServices:e}},__vite__mapDeps([3,1]));$.pie=t().Pie.parser.LangiumParser},`pie`),treeView:p(async()=>{let{createTreeViewServices:t}=await e(async()=>{let{createTreeViewServices:e}=await import(`./treeView-Q6P3EWNA-Bck3TsQB.js`);return{createTreeViewServices:e}},__vite__mapDeps([4,1]));$.treeView=t().TreeView.parser.LangiumParser},`treeView`),architecture:p(async()=>{let{createArchitectureServices:t}=await e(async()=>{let{createArchitectureServices:e}=await import(`./architecture-7GRP2DOG-B7cjyaKW.js`);return{createArchitectureServices:e}},__vite__mapDeps([5,1]));$.architecture=t().Architecture.parser.LangiumParser},`architecture`),gitGraph:p(async()=>{let{createGitGraphServices:t}=await e(async()=>{let{createGitGraphServices:e}=await import(`./gitGraph-4MIJSDKK-DroQcAWn.js`);return{createGitGraphServices:e}},__vite__mapDeps([6,1]));$.gitGraph=t().GitGraph.parser.LangiumParser},`gitGraph`),eventmodeling:p(async()=>{let{createEventModelingServices:t}=await e(async()=>{let{createEventModelingServices:e}=await import(`./eventmodeling-NTZA5JFV-CetGhGTA.js`);return{createEventModelingServices:e}},__vite__mapDeps([7,1]));$.eventmodeling=t().EventModel.parser.LangiumParser},`eventmodeling`),radar:p(async()=>{let{createRadarServices:t}=await e(async()=>{let{createRadarServices:e}=await import(`./radar-RG4KPBEZ-BsN_WAuk.js`);return{createRadarServices:e}},__vite__mapDeps([8,1]));$.radar=t().Radar.parser.LangiumParser},`radar`),railroad:p(async()=>{let{createRailroadServices:t}=await e(async()=>{let{createRailroadServices:e}=await import(`./railroad-74A4TZTK-CYJJ-7AP.js`);return{createRailroadServices:e}},__vite__mapDeps([9,1]));$.railroad=t().Railroad.parser.LangiumParser},`railroad`),railroadEbnf:p(async()=>{let{createRailroadEbnfServices:t}=await e(async()=>{let{createRailroadEbnfServices:e}=await import(`./railroad-ebnf-LZEXJU2U-BuSvGFsc.js`);return{createRailroadEbnfServices:e}},__vite__mapDeps([10,1]));$.railroadEbnf=t().RailroadEbnf.parser.LangiumParser},`railroadEbnf`),railroadAbnf:p(async()=>{let{createRailroadAbnfServices:t}=await e(async()=>{let{createRailroadAbnfServices:e}=await import(`./railroad-abnf-HS5TGJTU-XdDFvlUB.js`);return{createRailroadAbnfServices:e}},__vite__mapDeps([11,1]));$.railroadAbnf=t().RailroadAbnf.parser.LangiumParser},`railroadAbnf`),railroadPeg:p(async()=>{let{createRailroadPegServices:t}=await e(async()=>{let{createRailroadPegServices:e}=await import(`./railroad-peg-WCYAUIDC-CNjo3yz4.js`);return{createRailroadPegServices:e}},__vite__mapDeps([12,1]));$.railroadPeg=t().RailroadPeg.parser.LangiumParser},`railroadPeg`),treemap:p(async()=>{let{createTreemapServices:t}=await e(async()=>{let{createTreemapServices:e}=await import(`./treemap-WGGIJYW6-BVec3Jfs.js`);return{createTreemapServices:e}},__vite__mapDeps([13,1]));$.treemap=t().Treemap.parser.LangiumParser},`treemap`),wardley:p(async()=>{let{createWardleyServices:t}=await e(async()=>{let{createWardleyServices:e}=await import(`./wardley-WFR3VGLG-kIjJw24i.js`);return{createWardleyServices:e}},__vite__mapDeps([14,1]));$.wardley=t().Wardley.parser.LangiumParser},`wardley`),cynefin:p(async()=>{let{createCynefinServices:t}=await e(async()=>{let{createCynefinServices:e}=await import(`./cynefin-OW5HDTMX-DebjIew_.js`);return{createCynefinServices:e}},__vite__mapDeps([15,1]));$.cynefin=t().Cynefin.parser.LangiumParser},`cynefin`)};async function ze(e,t){let n=Re[e];if(!n)throw Error(`Unknown diagram type: ${e}`);$[e]||await n();let r=$[e].parse(t);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new Be(r);return r.value}p(ze,`parse`);var Be=class extends Error{constructor(e){let t=e.lexerErrors.map(e=>`Lexer error on line ${e.line!==void 0&&!isNaN(e.line)?e.line:`?`}, column ${e.column!==void 0&&!isNaN(e.column)?e.column:`?`}: ${e.message}`).join(` +`),n=e.parserErrors.map(e=>`Parse error on line ${e.token.startLine!==void 0&&!isNaN(e.token.startLine)?e.token.startLine:`?`}, column ${e.token.startColumn!==void 0&&!isNaN(e.token.startColumn)?e.token.startColumn:`?`}: ${e.message}`).join(` +`);super(`Parsing failed: ${t} ${n}`),this.result=e}static{p(this,`MermaidParseError`)}};export{_ as A,O as C,w as D,D as E,h as M,T as O,j as S,E as T,P as _,Y as a,N as b,q as c,V as d,H as f,we as g,L as h,Q as i,m as j,g as k,W as l,z as m,ze as n,X as o,R as p,Z as r,K as s,Be as t,G as u,F as v,k as w,A as x,M as y}; \ No newline at end of file diff --git a/www/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js b/www/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js new file mode 100644 index 0000000..8fb267b --- /dev/null +++ b/www/assets/mindmap-definition-NLK3R4M7-BCTxemjG.js @@ -0,0 +1,96 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{at as n,b as r,f as i,k as a,nt as o,rt as s,x as c,z as l}from"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as u,t as d}from"./index-DoQkmpth.js";import{t as f}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as p}from"./chunk-WEXAMYUT-I3m-hOmT.js";var m=[];for(let e=0;e<256;++e)m.push((e+256).toString(16).slice(1));function h(e,t=0){return(m[e[t+0]]+m[e[t+1]]+m[e[t+2]]+m[e[t+3]]+`-`+m[e[t+4]]+m[e[t+5]]+`-`+m[e[t+6]]+m[e[t+7]]+`-`+m[e[t+8]]+m[e[t+9]]+`-`+m[e[t+10]]+m[e[t+11]]+m[e[t+12]]+m[e[t+13]]+m[e[t+14]]+m[e[t+15]]).toLowerCase()}var g=new Uint8Array(16);function _(){return crypto.getRandomValues(g)}function v(e,t,n){return!t&&!e&&crypto.randomUUID?crypto.randomUUID():y(e,t,n)}function y(e,t,n){e||={};let r=e.random??e.rng?.()??_();if(r.length<16)throw Error(`Random bytes length must be >= 16`);if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){if(n||=0,n<0||n+16>t.length)throw RangeError(`UUID byte range ${n}:${n+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[n+e]=r[e];return t}return h(r)}var b=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,13],i=[1,12],a=[1,15],o=[1,16],s=[1,20],c=[1,19],l=[6,7,8],u=[1,26],d=[1,24],f=[1,25],p=[6,7,11],m=[1,6,13,15,16,19,22],h=[1,33],g=[1,34],_=[1,6,7,11,13,15,16,19,22],v={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`MINDMAP`,11:`EOF`,13:`SPACELIST`,15:`ICON`,16:`CLASS`,19:`NODE_DSTART`,20:`NODE_DESCR`,21:`NODE_DEND`,22:`NODE_ID`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace(`Stop NL `);break;case 9:r.getLogger().trace(`Stop EOF `);break;case 11:r.getLogger().trace(`Stop NL2 `);break;case 12:r.getLogger().trace(`Stop EOF2 `);break;case 15:r.getLogger().info(`Node: `,a[s].id),r.addNode(a[s-1].length,a[s].id,a[s].descr,a[s].type);break;case 16:r.getLogger().trace(`Icon: `,a[s]),r.decorateNode({icon:a[s]});break;case 17:case 21:r.decorateNode({class:a[s]});break;case 18:r.getLogger().trace(`SPACELIST`);break;case 19:r.getLogger().trace(`Node: `,a[s].id),r.addNode(0,a[s].id,a[s].descr,a[s].type);break;case 20:r.decorateNode({icon:a[s]});break;case 25:r.getLogger().trace(`node found ..`,a[s-2]),this.$={id:a[s-1],descr:a[s-1],type:r.getType(a[s-2],a[s])};break;case 26:this.$={id:a[s],descr:a[s],type:r.nodeType.DEFAULT};break;case 27:r.getLogger().trace(`node found ..`,a[s-3]),this.$={id:a[s-3],descr:a[s-1],type:r.getType(a[s-2],a[s])}}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},e(l,[2,3]),{1:[2,2]},e(l,[2,4]),e(l,[2,5]),{1:[2,6],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:r,9:22,12:11,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},{6:u,7:d,10:23,11:f},e(p,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:s,22:c}),e(p,[2,18]),e(p,[2,19]),e(p,[2,20]),e(p,[2,21]),e(p,[2,23]),e(p,[2,24]),e(p,[2,26],{19:[1,30]}),{20:[1,31]},{6:u,7:d,10:32,11:f},{1:[2,7],6:r,12:21,13:i,14:14,15:a,16:o,17:17,18:18,19:s,22:c},e(m,[2,14],{7:h,11:g}),e(_,[2,8]),e(_,[2,9]),e(_,[2,10]),e(p,[2,15]),e(p,[2,16]),e(p,[2,17]),{20:[1,35]},{21:[1,36]},e(m,[2,13],{7:h,11:g}),e(_,[2,11]),e(_,[2,12]),{21:[1,37]},e(p,[2,25]),e(p,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};v.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return e.getLogger().trace(`Found comment`,t.yytext),6;case 1:return 8;case 2:this.begin(`CLASS`);break;case 3:return this.popState(),16;case 4:this.popState();break;case 5:e.getLogger().trace(`Begin icon`),this.begin(`ICON`);break;case 6:return e.getLogger().trace(`SPACELINE`),6;case 7:return 7;case 8:return 15;case 9:e.getLogger().trace(`end icon`),this.popState();break;case 10:return e.getLogger().trace(`Exploding node`),this.begin(`NODE`),19;case 11:return e.getLogger().trace(`Cloud`),this.begin(`NODE`),19;case 12:return e.getLogger().trace(`Explosion Bang`),this.begin(`NODE`),19;case 13:return e.getLogger().trace(`Cloud Bang`),this.begin(`NODE`),19;case 14:return this.begin(`NODE`),19;case 15:return this.begin(`NODE`),19;case 16:return this.begin(`NODE`),19;case 17:return this.begin(`NODE`),19;case 18:return 13;case 19:return 22;case 20:return 11;case 21:this.begin(`NSTR2`);break;case 22:return`NODE_DESCR`;case 23:this.popState();break;case 24:e.getLogger().trace(`Starting NSTR`),this.begin(`NSTR`);break;case 25:return e.getLogger().trace(`description:`,t.yytext),`NODE_DESCR`;case 26:this.popState();break;case 27:return this.popState(),e.getLogger().trace(`node end ))`),`NODE_DEND`;case 28:return this.popState(),e.getLogger().trace(`node end )`),`NODE_DEND`;case 29:return this.popState(),e.getLogger().trace(`node end ...`,t.yytext),`NODE_DEND`;case 30:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 31:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 32:return this.popState(),e.getLogger().trace(`node end (-`),`NODE_DEND`;case 33:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 34:return this.popState(),e.getLogger().trace(`node end ((`),`NODE_DEND`;case 35:return e.getLogger().trace(`Long description:`,t.yytext),20;case 36:return e.getLogger().trace(`Long description:`,t.yytext),20}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:mindmap\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{CLASS:{rules:[3,4],inclusive:!1},ICON:{rules:[8,9],inclusive:!1},NSTR2:{rules:[22,23],inclusive:!1},NSTR:{rules:[25,26],inclusive:!1},NODE:{rules:[21,24,27,28,29,30,31,32,33,34,35,36],inclusive:!1},INITIAL:{rules:[0,1,2,5,6,7,10,11,12,13,14,15,16,17,18,19,20],inclusive:!0}}}})();function y(){this.yy={}}return t(y,`Parser`),y.prototype=v,v.Parser=y,new y})();b.parser=b;var x=b,S=12,C={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},w=class{constructor(){this.nodes=[],this.count=0,this.elements={},this.getLogger=this.getLogger.bind(this),this.nodeType=C,this.clear(),this.getType=this.getType.bind(this),this.getElementById=this.getElementById.bind(this),this.getParent=this.getParent.bind(this),this.getMindmap=this.getMindmap.bind(this),this.addNode=this.addNode.bind(this),this.decorateNode=this.decorateNode.bind(this)}static{t(this,`MindmapDB`)}clear(){this.nodes=[],this.count=0,this.elements={},this.baseLevel=void 0}getParent(e){for(let t=this.nodes.length-1;t>=0;t--)if(this.nodes[t].level0?this.nodes[0]:null}addNode(t,n,r,a){e.info(`addNode`,t,n,r,a);let o=!1;this.nodes.length===0?(this.baseLevel=t,t=0,o=!0):this.baseLevel!==void 0&&(t-=this.baseLevel,o=!1);let s=c(),u=s.mindmap?.padding??i.mindmap.padding;switch(a){case this.nodeType.ROUNDED_RECT:case this.nodeType.RECT:case this.nodeType.HEXAGON:u*=2}let d={id:this.count++,nodeId:l(n,s),level:t,descr:l(r,s),type:a,children:[],width:s.mindmap?.maxNodeWidth??i.mindmap.maxNodeWidth,padding:u,isRoot:o},f=this.getParent(t);if(f)f.children.push(d),this.nodes.push(d);else if(o)this.nodes.push(d);else throw Error(`There can be only one root. No parent could be found for ("${d.descr}")`)}getType(t,n){switch(e.debug(`In get type`,t,n),t){case`[`:return this.nodeType.RECT;case`(`:return n===`)`?this.nodeType.ROUNDED_RECT:this.nodeType.CLOUD;case`((`:return this.nodeType.CIRCLE;case`)`:return this.nodeType.CLOUD;case`))`:return this.nodeType.BANG;case`{{`:return this.nodeType.HEXAGON;default:return this.nodeType.DEFAULT}}setElementForId(e,t){this.elements[e]=t}getElementById(e){return this.elements[e]}decorateNode(e){if(!e)return;let t=c(),n=this.nodes[this.nodes.length-1];e.icon&&(n.icon=l(e.icon,t)),e.class&&(n.class=l(e.class,t))}type2Str(e){switch(e){case this.nodeType.DEFAULT:return`no-border`;case this.nodeType.RECT:return`rect`;case this.nodeType.ROUNDED_RECT:return`rounded-rect`;case this.nodeType.CIRCLE:return`circle`;case this.nodeType.CLOUD:return`cloud`;case this.nodeType.BANG:return`bang`;case this.nodeType.HEXAGON:return`hexgon`;default:return`no-border`}}assignSections(e,t){if(e.section=e.level===0?void 0:t,e.children)for(let[n,r]of e.children.entries()){let i=e.level===0?n%(S-1):t;this.assignSections(r,i)}}flattenNodes(e,n){let r=c(),i=[`mindmap-node`];e.isRoot===!0?i.push(`section-root`,`section--1`):e.section!==void 0&&i.push(`section-${e.section}`),e.class&&i.push(e.class);let a=i.join(` `),o=t(e=>{let t=(r.theme?.toLowerCase()??``).includes(`redux`);switch(e){case C.CIRCLE:return`mindmapCircle`;case C.RECT:return`rect`;case C.ROUNDED_RECT:return`rounded`;case C.CLOUD:return`cloud`;case C.BANG:return`bang`;case C.HEXAGON:return`hexagon`;case C.DEFAULT:return t?`rounded`:`defaultMindmapNode`;case C.NO_BORDER:default:return`rect`}},`getShapeFromType`),s={id:e.id.toString(),domId:`node_`+e.id.toString(),label:e.descr,labelType:`markdown`,isGroup:!1,shape:o(e.type),width:e.width,height:e.height??0,padding:e.padding,cssClasses:a,cssStyles:[],look:r.look,icon:e.icon,x:e.x,y:e.y,level:e.level,nodeId:e.nodeId,type:e.type,section:e.section};if(n.push(s),e.children)for(let t of e.children)this.flattenNodes(t,n)}generateEdges(e,t){if(!e.children)return;let n=c();for(let r of e.children){let i=`edge`;r.section!==void 0&&(i+=` section-edge-${r.section}`);let a=e.level+1;i+=` edge-depth-${a}`;let o={id:`edge_${e.id}_${r.id}`,start:e.id.toString(),end:r.id.toString(),type:`normal`,curve:`basis`,thickness:`normal`,look:n.look,classes:i,depth:e.level,section:r.section};t.push(o),this.generateEdges(r,t)}}getData(){let t=this.getMindmap(),n=c(),r=a().layout!==void 0,i=n;if(r||(i.layout=`cose-bilkent`),!t)return{nodes:[],edges:[],config:i};e.debug(`getData: mindmapRoot`,t,n),this.assignSections(t);let o=[],s=[];this.flattenNodes(t,o),this.generateEdges(t,s),e.debug(`getData: processed ${o.length} nodes and ${s.length} edges`);let l=new Map;for(let e of o)l.set(e.id,{shape:e.shape,width:e.width,height:e.height,padding:e.padding});return{nodes:o,edges:s,config:i,rootNode:t,markers:[`point`],direction:`TB`,nodeSpacing:50,rankSpacing:50,shapes:Object.fromEntries(l),type:`mindmap`,diagramId:`mindmap-`+v()}}getLogger(){return e}},T={draw:t(async(t,n,a,o)=>{e.debug(`Rendering mindmap diagram +`+t);let s=o.db,c=s.getData(),l=f(n,c.config.securityLevel);if(c.type=o.type,c.layoutAlgorithm=d(c.config.layout,{fallback:`cose-bilkent`}),c.diagramId=n,!s.getMindmap())return;c.nodes.forEach(e=>{e.shape===`rounded`?(e.radius=15,e.taper=15,e.stroke=`none`,e.width=0,e.padding=15):e.shape===`circle`?e.padding=10:e.shape===`rect`?(e.width=0,e.padding=10):e.shape===`hexagon`&&(e.width=0,e.height=0)}),await u(c,l);let{themeVariables:m}=r(),{useGradient:h,gradientStart:g,gradientStop:_}=m;if(h&&g&&_){let e=l.attr(`id`),t=l.append(`defs`).append(`linearGradient`).attr(`id`,`${e}-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);t.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,g).attr(`stop-opacity`,1),t.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,_).attr(`stop-opacity`,1)}p(l,c.config.mindmap?.padding??i.mindmap.padding,`mindmapDiagram`,c.config.mindmap?.useMaxWidth??i.mindmap.useMaxWidth)},`draw`)},E=t(e=>{let{theme:t,look:r}=e,i=``;for(let t=0;t{let r=``;for(let i=0;i{let{theme:t}=e,n=e.svgId,r=e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${n}-drop-shadow)`):`none`;return` + .edge { + stroke-width: 3; + } + ${E(e)} + .section-root rect, .section-root path, .section-root circle, .section-root polygon { + fill: ${e.git0}; + } + .section-root text { + fill: ${e.gitBranchLabel0}; + } + .section-root span { + color: ${t?.includes(`redux`)?e.nodeBorder:e.gitBranchLabel0}; + } + .icon-container { + height:100%; + display: flex; + justify-content: center; + align-items: center; + } + .edge { + fill: none; + } + .mindmap-node-label { + dy: 1em; + alignment-baseline: middle; + text-anchor: middle; + dominant-baseline: middle; + text-align: center; + } + [data-look="neo"].mindmap-node { + filter: ${r}; + } + [data-look="neo"].mindmap-node.section-root rect, [data-look="neo"].mindmap-node.section-root path, [data-look="neo"].mindmap-node.section-root circle, [data-look="neo"].mindmap-node.section-root polygon { + fill: ${t?.includes(`redux`)?e.mainBkg:e.git0}; + } + [data-look="neo"].mindmap-node.section-root .text-inner-tspan { + fill: ${t?.includes(`redux`)?e.nodeBorder:e[`cScaleLabel`+ +(t===`neutral`)]}; + } + ${e.useGradient&&n&&e.mainBkg?D(e.THEME_COLOR_LIMIT,n,e.mainBkg):``} +`},`getStyles`)};export{O as diagram}; \ No newline at end of file diff --git a/www/assets/ordinal-BDEzSJ7C.js b/www/assets/ordinal-BDEzSJ7C.js new file mode 100644 index 0000000..200c228 --- /dev/null +++ b/www/assets/ordinal-BDEzSJ7C.js @@ -0,0 +1 @@ +import{t as e}from"./init-C-OQMol4.js";var t=class extends Map{constructor(e,t=a){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),e!=null)for(let[t,n]of e)this.set(t,n)}get(e){return super.get(n(this,e))}has(e){return super.has(n(this,e))}set(e,t){return super.set(r(this,e),t)}delete(e){return super.delete(i(this,e))}};function n({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):n}function r({_intern:e,_key:t},n){let r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function i({_intern:e,_key:t},n){let r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function a(e){return typeof e==`object`&&e?e.valueOf():e}var o=Symbol(`implicit`);function s(){var n=new t,r=[],i=[],a=o;function c(e){let t=n.get(e);if(t===void 0){if(a!==o)return a;n.set(e,t=r.push(e)-1)}return i[t%i.length]}return c.domain=function(e){if(!arguments.length)return r.slice();r=[],n=new t;for(let t of e)n.has(t)||n.set(t,r.push(t)-1);return c},c.range=function(e){return arguments.length?(i=Array.from(e),c):i.slice()},c.unknown=function(e){return arguments.length?(a=e,c):a},c.copy=function(){return s(r,i).unknown(a)},e.apply(c,arguments),c}export{s as t}; \ No newline at end of file diff --git a/www/assets/packet-AYTQ26CC-f7lhlK2y.js b/www/assets/packet-AYTQ26CC-f7lhlK2y.js new file mode 100644 index 0000000..92a9f52 --- /dev/null +++ b/www/assets/packet-AYTQ26CC-f7lhlK2y.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{S as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createPacketServices}; \ No newline at end of file diff --git a/www/assets/path-fybaL0A-.js b/www/assets/path-fybaL0A-.js new file mode 100644 index 0000000..5d78fd7 --- /dev/null +++ b/www/assets/path-fybaL0A-.js @@ -0,0 +1 @@ +var e=Math.PI,t=2*e,n=1e-6,r=t-n;function i(e){this._+=e[0];for(let t=1,n=e.length;t=0))throw Error(`invalid digits: ${e}`);if(t>15)return i;let n=10**t;return function(e){this._+=e[0];for(let t=1,r=e.length;tn){if(!(Math.abs(f*l-u*d)>n)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let m=i-s,h=a-c,g=l*l+u*u,_=m*m+h*h,v=Math.sqrt(g),y=Math.sqrt(p),b=o*Math.tan((e-Math.acos((g+p-_)/(2*v*y)))/2),x=b/y,S=b/v;Math.abs(x-1)>n&&this._append`L${t+x*d},${r+x*f}`,this._append`A${o},${o},0,0,${+(f*m>d*h)},${this._x1=t+S*l},${this._y1=r+S*u}`}}}arc(i,a,o,s,c,l){if(i=+i,a=+a,o=+o,l=!!l,o<0)throw Error(`negative radius: ${o}`);let u=o*Math.cos(s),d=o*Math.sin(s),f=i+u,p=a+d,m=1^l,h=l?s-c:c-s;this._x1===null?this._append`M${f},${p}`:(Math.abs(this._x1-f)>n||Math.abs(this._y1-p)>n)&&this._append`L${f},${p}`,o&&(h<0&&(h=h%t+t),h>r?this._append`A${o},${o},0,1,${m},${i-u},${a-d}A${o},${o},0,1,${m},${this._x1=f},${this._y1=p}`:h>n&&this._append`A${o},${o},0,${+(h>=e)},${m},${this._x1=i+o*Math.cos(c)},${this._y1=a+o*Math.sin(c)}`)}rect(e,t,n,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}};o.prototype;function s(e){return function(){return e}}function c(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{let e=Math.floor(n);if(!(e>=0))throw RangeError(`invalid digits: ${n}`);t=e}return e},()=>new o(t)}export{s as n,c as t}; \ No newline at end of file diff --git a/www/assets/pegDiagram-GJSIUBJH-B0Gktij4.js b/www/assets/pegDiagram-GJSIUBJH-B0Gktij4.js new file mode 100644 index 0000000..271e971 --- /dev/null +++ b/www/assets/pegDiagram-GJSIUBJH-B0Gktij4.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{t as n,u as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=r().RailroadPeg.parser.LangiumParser,l=t(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformOrderedChoice`),u=t(e=>{let t=e.elements.map(d);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformSequence`),d=t(e=>{let t=p(e.suffix);return e.operator?{type:`special`,text:e.operator===`&`?`&${f(t)}`:`!${f(t)}`}:t},`transformPrefix`),f=t(e=>{switch(e.type){case`terminal`:return`"${e.value}"`;case`nonterminal`:return e.name;case`special`:return e.text;default:return`(...)`}},`nodeToLabel`),p=t(e=>{let t=m(e.primary);if(!e.operator)return t;switch(e.operator){case`?`:return{type:`optional`,element:t};case`*`:return{type:`repetition`,element:t,min:0,max:1/0};case`+`:return{type:`repetition`,element:t,min:1,max:1/0};default:throw Error(`Unsupported PEG suffix operator: ${e.operator}`)}},`transformSuffix`),m=t(e=>{switch(e.$type){case`PegLiteral`:return{type:`terminal`,value:e.value};case`PegIdentifier`:return{type:`nonterminal`,name:e.name};case`PegGroup`:return l(e.element);case`PegAny`:return{type:`special`,text:e.dot};default:throw Error(`Unsupported PEG primary node: ${e.$type}`)}},`transformPrimary`),h=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),g=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(h(e)))},`populateDb`),_={parser:{parse:t(t=>{o.clear(),e.debug(`[PEG Parser] Starting Langium parse`);let r=c.parse(t);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new n(r);let i=r.value;e.debug(`[PEG Parser] Parsed rules:`,i.rules.length),g(i),e.debug(`[PEG Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{_ as diagram}; \ No newline at end of file diff --git a/www/assets/pie-WAS4IAKB-BbyREufe.js b/www/assets/pie-WAS4IAKB-BbyREufe.js new file mode 100644 index 0000000..36377d2 --- /dev/null +++ b/www/assets/pie-WAS4IAKB-BbyREufe.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{b as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createPieServices}; \ No newline at end of file diff --git a/www/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js b/www/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js new file mode 100644 index 0000000..8ea3af4 --- /dev/null +++ b/www/assets/pieDiagram-5QR66LMP-0Fjx8Dye.js @@ -0,0 +1,39 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,c as a,f as o,q as s,v as c,w as l,x as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as f}from"./ordinal-BDEzSJ7C.js";import{n as p}from"./path-fybaL0A-.js";import{m}from"./dist-Bfr8PhAA.js";import{t as h}from"./arc-BJA87daU.js";import{t as g}from"./array-BifhSqXX.js";import{i as _,p as v}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y}from"./index-DoQkmpth.js";import{n as b}from"./mermaid-parser.core-CUrDj5TF.js";import{t as x}from"./chunk-JWPE2WC7-DVXcaiue.js";function S(e,t){return te?1:t>=e?0:NaN}function C(e){return e}function w(){var e=C,t=S,n=null,r=p(0),i=p(m),a=p(0);function o(o){var s,c=(o=g(o)).length,l,u,d=0,f=Array(c),p=Array(c),h=+r.apply(this,arguments),_=Math.min(m,Math.max(-m,i.apply(this,arguments)-h)),v,y=Math.min(Math.abs(_)/c,a.apply(this,arguments)),b=y*(_<0?-1:1),x;for(s=0;s0&&(d+=x);for(t==null?n!=null&&f.sort(function(e,t){return n(o[e],o[t])}):f.sort(function(e,n){return t(p[e],p[n])}),s=0,u=d?(_-c*b)/d:0;s0?x*u:0)+b,p[l]={data:o[l],index:s,value:x,startAngle:h,endAngle:v,padAngle:y};return p}return o.value=function(t){return arguments.length?(e=typeof t==`function`?t:p(+t),o):e},o.sortValues=function(e){return arguments.length?(t=e,n=null,o):t},o.sort=function(e){return arguments.length?(n=e,t=null,o):n},o.startAngle=function(e){return arguments.length?(r=typeof e==`function`?e:p(+e),o):r},o.endAngle=function(e){return arguments.length?(i=typeof e==`function`?e:p(+e),o):i},o.padAngle=function(e){return arguments.length?(a=typeof e==`function`?e:p(+e),o):a},o}var T=o.pie,E={sections:new Map,showData:!1,config:T},D=E.sections,O=E.showData,k=structuredClone(T),A={getConfig:t(()=>structuredClone(k),`getConfig`),clear:t(()=>{D=new Map,O=E.showData,i()},`clear`),setDiagramTitle:s,getDiagramTitle:l,setAccTitle:r,getAccTitle:d,setAccDescription:n,getAccDescription:c,addSection:t(({label:t,value:n})=>{if(n<0)throw Error(`"${t}" has invalid value: ${n}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);D.has(t)||(D.set(t,n),e.debug(`added new section: ${t}, with value: ${n}`))},`addSection`),getSections:t(()=>D,`getSections`),setShowData:t(e=>{O=e},`setShowData`),getShowData:t(()=>O,`getShowData`)},j=t((e,t)=>{x(e,t),t.setShowData(e.showData),e.sections.map(t.addSection)},`populateDb`),M={parse:t(async t=>{let n=await b(`pie`,t);e.debug(n),j(n,A)},`parse`)},N=t(e=>` + .pieCircle{ + stroke: ${e.pieStrokeColor}; + stroke-width : ${e.pieStrokeWidth}; + opacity : ${e.pieOpacity}; + } + .pieCircle.highlighted{ + scale: 1.05; + opacity: 1; + } + .pieCircle.highlightedOnHover:hover{ + transition-duration: 250ms; + scale: 1.05; + opacity: 1; + } + .pieOuterCircle{ + stroke: ${e.pieOuterStrokeColor}; + stroke-width: ${e.pieOuterStrokeWidth}; + fill: none; + } + .pieTitleText { + text-anchor: middle; + font-size: ${e.pieTitleTextSize}; + fill: ${e.pieTitleTextColor}; + font-family: ${e.fontFamily}; + } + .slice { + font-family: ${e.fontFamily}; + fill: ${e.pieSectionTextColor}; + font-size:${e.pieSectionTextSize}; + // fill: white; + } + .legend text { + fill: ${e.pieLegendTextColor}; + font-family: ${e.fontFamily}; + font-size: ${e.pieLegendTextSize}; + } +`,`getStyles`),P=t(e=>{let t=[...e.values()].reduce((e,t)=>e+t,0),n=[...e.entries()].map(([e,t])=>({label:e,value:t})).filter(e=>e.value/t*100>=1);return w().value(e=>e.value).sort(null)(n)},`createPieArcs`),F={parser:M,db:A,renderer:{draw:t((t,n,r,i)=>{e.debug(`rendering pie chart +`+t);let o=i.db,s=u(),c=_(o.getConfig(),s.pie),l=y(n),d=l.append(`g`);d.attr(`transform`,`translate(225,225)`);let{themeVariables:p}=s,[m]=v(p.pieOuterStrokeWidth);m??=2;let g=c.legendPosition,b=c.textPosition,x=c.donutHole>0&&c.donutHole<=.9?c.donutHole:0,S=h().innerRadius(x*185).outerRadius(185),C=h().innerRadius(185*b).outerRadius(185*b),w=d.append(`g`);w.append(`circle`).attr(`cx`,0).attr(`cy`,0).attr(`r`,185+m/2).attr(`class`,`pieOuterCircle`);let T=o.getSections(),E=P(T),D=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],O=0;T.forEach(e=>{O+=e});let k=E.filter(e=>(e.data.value/O*100).toFixed(0)!==`0`),A=f(D).domain([...T.keys()]);w.selectAll(`mySlices`).data(k).enter().append(`path`).attr(`d`,S).attr(`fill`,e=>A(e.data.label)).attr(`class`,e=>{let t=`pieCircle`;return c.highlightSlice===`hover`?t+=` highlightedOnHover`:c.highlightSlice===e.data.label&&(t+=` highlighted`),t}),w.selectAll(`mySlices`).data(k).enter().append(`text`).text(e=>(e.data.value/O*100).toFixed(0)+`%`).attr(`transform`,e=>`translate(`+C.centroid(e)+`)`).style(`text-anchor`,`middle`).attr(`class`,`slice`);let j=d.append(`text`).text(o.getDiagramTitle()).attr(`x`,0).attr(`y`,-200).attr(`class`,`pieTitleText`),M=[...T.entries()].map(([e,t])=>({label:e,value:t})),N=d.selectAll(`.legend`).data(M).enter().append(`g`).attr(`class`,`legend`);N.append(`rect`).attr(`width`,18).attr(`height`,18).style(`fill`,e=>A(e.label)).style(`stroke`,e=>A(e.label)),N.append(`text`).attr(`x`,22).attr(`y`,14).text(e=>o.getShowData()?`${e.label} [${e.value}]`:e.label);let F=Math.max(...N.selectAll(`text`).nodes().map(e=>e?.getBoundingClientRect().width??0)),I=450,L=490,R=M.length*22;switch(g){case`center`:N.attr(`transform`,(e,t)=>{let n=22*M.length/2,r=-F/2-22,i=t*22-n;return`translate(`+r+`,`+i+`)`});break;case`top`:I+=R,N.attr(`transform`,(e,t)=>`translate(${-F/2-22}, ${t*22-185})`),w.attr(`transform`,()=>`translate(0, ${R+22})`);break;case`bottom`:I+=R,N.attr(`transform`,(e,t)=>{let n=-F/2-22,r=t*22- -207;return`translate(`+n+`,`+r+`)`});break;case`left`:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(-207,`+(t*22-n)+`)`}),w.attr(`transform`,()=>`translate(${F+18+4}, 0)`);break;default:L+=22+F,N.attr(`transform`,(e,t)=>{let n=22*M.length/2;return`translate(216,`+(t*22-n)+`)`})}let z=j.node()?.getBoundingClientRect().width??0,B=225-z/2,V=225+z/2,H=Math.min(0,B),U=Math.max(L,V)-H;l.attr(`viewBox`,`${H} 0 ${U} ${I}`),a(l,I,U,c.useMaxWidth)},`draw`)},styles:N};export{F as diagram}; \ No newline at end of file diff --git a/www/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js b/www/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js new file mode 100644 index 0000000..e8f48f7 --- /dev/null +++ b/www/assets/quadrantDiagram-O4NWA36T-Crj0r6Xm.js @@ -0,0 +1,7 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as r,H as i,U as a,a as o,c as s,f as c,q as l,v as u,w as d,x as f,y as p,z as m}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as h}from"./linear-CZ6dxGrP.js";var g=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[1,7],s=[1,4,5,10,12,13,14,15,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],c=[1,4,5,10,12,13,14,15,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],l=[55,56,57],u=[2,36],d=[1,37],f=[1,36],p=[1,38],m=[1,35],h=[1,43],g=[1,41],_=[1,45],v=[1,14],y=[1,23],b=[1,18],x=[1,19],S=[1,20],C=[1,21],w=[1,22],T=[1,24],E=[1,25],D=[1,26],O=[1,27],k=[1,28],A=[1,29],j=[1,32],M=[1,33],N=[1,34],P=[1,39],F=[1,40],I=[1,42],L=[1,44],R=[1,63],z=[1,62],B=[4,5,8,10,12,13,14,15,18,44,47,49,55,56,57,63,64,65,66,67],ee=[1,66],te=[1,67],ne=[1,68],re=[1,69],ie=[1,70],ae=[1,71],oe=[1,72],se=[1,73],ce=[1,74],le=[1,75],ue=[1,76],de=[1,77],V=[4,5,6,7,8,9,10,11,12,13,14,15,18],H=[1,91],U=[1,92],W=[1,93],G=[1,100],K=[1,94],q=[1,97],J=[1,95],Y=[1,96],X=[1,98],Z=[1,99],fe=[1,103],pe=[10,55,56,57],Q=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],me={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:`error`,4:`ALPHA`,5:`NUM`,6:`NODE_STRING`,7:`DOWN`,8:`MINUS`,9:`DEFAULT`,10:`COMMA`,11:`COLON`,12:`AMP`,13:`BRKT`,14:`MULT`,15:`UNICODE_TEXT`,17:`UNIT`,18:`SPACE`,19:`STYLE`,20:`PCT`,25:`CLASSDEF`,28:`QUADRANT`,35:`title`,36:`title_value`,37:`acc_title`,38:`acc_title_value`,39:`acc_descr`,40:`acc_descr_value`,41:`acc_descr_multiline_value`,42:`section`,44:`point_start`,45:`point_x`,46:`point_y`,47:`class_name`,48:`X-AXIS`,49:`AXIS-TEXT-DELIMITER`,50:`Y-AXIS`,51:`QUADRANT_1`,52:`QUADRANT_2`,53:`QUADRANT_3`,54:`QUADRANT_4`,55:`NEWLINE`,56:`SEMI`,57:`EOF`,60:`STR`,61:`MD_STR`,63:`PUNCTUATION`,64:`PLUS`,65:`EQUALS`,66:`DOT`,67:`UNDERSCORE`},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 23:this.$=a[s];break;case 24:this.$=a[s-1]+``+a[s];break;case 26:this.$=a[s-1]+a[s];break;case 27:this.$=[a[s].trim()];break;case 28:a[s-2].push(a[s].trim()),this.$=a[s-2];break;case 29:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 37:this.$=[];break;case 42:this.$=a[s].trim(),r.setDiagramTitle(this.$);break;case 43:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 44:case 45:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 46:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 47:r.addPoint(a[s-3],``,a[s-1],a[s],[]);break;case 48:r.addPoint(a[s-4],a[s-3],a[s-1],a[s],[]);break;case 49:r.addPoint(a[s-4],``,a[s-2],a[s-1],a[s]);break;case 50:r.addPoint(a[s-5],a[s-4],a[s-2],a[s-1],a[s]);break;case 51:r.setXAxisLeftText(a[s-2]),r.setXAxisRightText(a[s]);break;case 52:a[s-1].text+=` ⟶ `,r.setXAxisLeftText(a[s-1]);break;case 53:r.setXAxisLeftText(a[s]);break;case 54:r.setYAxisBottomText(a[s-2]),r.setYAxisTopText(a[s]);break;case 55:a[s-1].text+=` ⟶ `,r.setYAxisBottomText(a[s-1]);break;case 56:r.setYAxisBottomText(a[s]);break;case 57:r.setQuadrant1Text(a[s]);break;case 58:r.setQuadrant2Text(a[s]);break;case 59:r.setQuadrant3Text(a[s]);break;case 60:r.setQuadrant4Text(a[s]);break;case 64:this.$={text:a[s],type:`text`};break;case 65:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 66:this.$={text:a[s],type:`text`};break;case 67:this.$={text:a[s],type:`markdown`};break;case 68:this.$=a[s];break;case 69:this.$=a[s-1]+``+a[s]}},`anonymous`),table:[{18:t,26:1,27:2,28:r,55:i,56:a,57:o},{1:[3]},{18:t,26:8,27:2,28:r,55:i,56:a,57:o},{18:t,26:9,27:2,28:r,55:i,56:a,57:o},e(s,[2,33],{29:10}),e(c,[2,61]),e(c,[2,62]),e(c,[2,63]),{1:[2,30]},{1:[2,31]},e(l,u,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(s,[2,34]),{27:46,55:i,56:a,57:o},e(l,[2,37]),e(l,u,{24:13,32:15,33:16,34:17,43:30,58:31,31:47,4:d,5:f,10:p,12:m,13:h,14:g,15:_,18:v,25:y,35:b,37:x,39:S,41:C,42:w,48:T,50:E,51:D,52:O,53:k,54:A,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(l,[2,39]),e(l,[2,40]),e(l,[2,41]),{36:[1,48]},{38:[1,49]},{40:[1,50]},e(l,[2,45]),e(l,[2,46]),{18:[1,51]},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:52,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:53,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:54,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:55,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:56,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,10:p,12:m,13:h,14:g,15:_,43:57,58:31,60:j,61:M,63:N,64:P,65:F,66:I,67:L},{4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,44:[1,58],47:[1,59],58:61,59:60,63:N,64:P,65:F,66:I,67:L},e(B,[2,64]),e(B,[2,66]),e(B,[2,67]),e(B,[2,70]),e(B,[2,71]),e(B,[2,72]),e(B,[2,73]),e(B,[2,74]),e(B,[2,75]),e(B,[2,76]),e(B,[2,77]),e(B,[2,78]),e(B,[2,79]),e(B,[2,80]),e(B,[2,81]),e(s,[2,35]),e(l,[2,38]),e(l,[2,42]),e(l,[2,43]),e(l,[2,44]),{3:65,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,21:64},e(l,[2,53],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,78],63:N,64:P,65:F,66:I,67:L}),e(l,[2,56],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,49:[1,79],63:N,64:P,65:F,66:I,67:L}),e(l,[2,57],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,58],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,59],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,60],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),{45:[1,80]},{44:[1,81]},e(B,[2,65]),e(B,[2,82]),e(B,[2,83]),e(B,[2,84]),{3:83,4:ee,5:te,6:ne,7:re,8:ie,9:ae,10:oe,11:se,12:ce,13:le,14:ue,15:de,18:[1,82]},e(V,[2,23]),e(V,[2,1]),e(V,[2,2]),e(V,[2,3]),e(V,[2,4]),e(V,[2,5]),e(V,[2,6]),e(V,[2,7]),e(V,[2,8]),e(V,[2,9]),e(V,[2,10]),e(V,[2,11]),e(V,[2,12]),e(l,[2,52],{58:31,43:84,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),e(l,[2,55],{58:31,43:85,4:d,5:f,10:p,12:m,13:h,14:g,15:_,60:j,61:M,63:N,64:P,65:F,66:I,67:L}),{46:[1,86]},{45:[1,87]},{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:89,23:88},e(V,[2,24]),e(l,[2,51],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,54],{59:60,58:61,4:d,5:f,8:R,10:p,12:m,13:h,14:g,15:_,18:z,63:N,64:P,65:F,66:I,67:L}),e(l,[2,47],{22:89,16:90,23:101,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{46:[1,102]},e(l,[2,29],{10:fe}),e(pe,[2,27],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),e(Q,[2,25]),e(Q,[2,13]),e(Q,[2,14]),e(Q,[2,15]),e(Q,[2,16]),e(Q,[2,17]),e(Q,[2,18]),e(Q,[2,19]),e(Q,[2,20]),e(Q,[2,21]),e(Q,[2,22]),e(l,[2,49],{10:fe}),e(l,[2,48],{22:89,16:90,23:105,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{4:H,5:U,6:W,8:G,11:K,13:q,16:90,17:J,18:Y,19:X,20:Z,22:106},e(Q,[2,26]),e(l,[2,50],{10:fe}),e(pe,[2,28],{16:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z})],defaultActions:{8:[2,30],9:[2,31]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};me.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 55;case 3:break;case 4:return this.begin(`title`),35;case 5:return this.popState(),`title_value`;case 6:return this.begin(`acc_title`),37;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),39;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin(`md_string`);break;case 22:return`MD_STR`;case 23:this.popState();break;case 24:this.begin(`string`);break;case 25:this.popState();break;case 26:return`STR`;case 27:this.begin(`class_name`);break;case 28:return this.popState(),47;case 29:return this.begin(`point_start`),44;case 30:return this.begin(`point_x`),45;case 31:this.popState();break;case 32:this.popState(),this.begin(`point_y`);break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 15;case 37:return 11;case 38:return 64;case 39:return 10;case 40:return 65;case 41:return 65;case 42:return 14;case 43:return 13;case 44:return 67;case 45:return 66;case 46:return 12;case 47:return 8;case 48:return 5;case 49:return 18;case 50:return 56;case 51:return 63;case 52:return 57}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?:[^\x00-\x7F]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}})();function $(){this.yy={}}return n($,`Parser`),$.prototype=me,me.Parser=$,new $})();g.parser=g;var _=g,v=r(),y=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{n(this,`QuadrantBuilder`)}getDefaultData(){return{titleText:``,quadrant1Text:``,quadrant2Text:``,quadrant3Text:``,quadrant4Text:``,xAxisLeftText:``,xAxisRightText:``,yAxisBottomText:``,yAxisTopText:``,points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:c.quadrantChart?.chartWidth||500,chartWidth:c.quadrantChart?.chartHeight||500,titlePadding:c.quadrantChart?.titlePadding||10,titleFontSize:c.quadrantChart?.titleFontSize||20,quadrantPadding:c.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:c.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:c.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:c.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:c.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:c.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:c.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:c.quadrantChart?.pointTextPadding||5,pointLabelFontSize:c.quadrantChart?.pointLabelFontSize||12,pointRadius:c.quadrantChart?.pointRadius||5,xAxisPosition:c.quadrantChart?.xAxisPosition||`top`,yAxisPosition:c.quadrantChart?.yAxisPosition||`left`,quadrantInternalBorderStrokeWidth:c.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:c.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:v.quadrant1Fill,quadrant2Fill:v.quadrant2Fill,quadrant3Fill:v.quadrant3Fill,quadrant4Fill:v.quadrant4Fill,quadrant1TextFill:v.quadrant1TextFill,quadrant2TextFill:v.quadrant2TextFill,quadrant3TextFill:v.quadrant3TextFill,quadrant4TextFill:v.quadrant4TextFill,quadrantPointFill:v.quadrantPointFill,quadrantPointTextFill:v.quadrantPointTextFill,quadrantXAxisTextFill:v.quadrantXAxisTextFill,quadrantYAxisTextFill:v.quadrantYAxisTextFill,quadrantTitleFill:v.quadrantTitleFill,quadrantInternalBorderStrokeFill:v.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:v.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,e.info(`clear called`)}setData(e){this.data={...this.data,...e}}addPoints(e){this.data.points=[...e,...this.data.points]}addClass(e,t){this.classes.set(e,t)}setConfig(t){e.trace(`setConfig called with: `,t),this.config={...this.config,...t}}setThemeConfig(t){e.trace(`setThemeConfig called with: `,t),this.themeConfig={...this.themeConfig,...t}}calculateSpace(e,t,n,r){let i=this.config.xAxisLabelPadding*2+this.config.xAxisLabelFontSize,a={top:e===`top`&&t?i:0,bottom:e===`bottom`&&t?i:0},o=this.config.yAxisLabelPadding*2+this.config.yAxisLabelFontSize,s={left:this.config.yAxisPosition===`left`&&n?o:0,right:this.config.yAxisPosition===`right`&&n?o:0},c=this.config.titleFontSize+this.config.titlePadding*2,l={top:r?c:0},u=this.config.quadrantPadding+s.left,d=this.config.quadrantPadding+a.top+l.top,f=this.config.chartWidth-this.config.quadrantPadding*2-s.left-s.right,p=this.config.chartHeight-this.config.quadrantPadding*2-a.top-a.bottom-l.top;return{xAxisSpace:a,yAxisSpace:s,titleSpace:l,quadrantSpace:{quadrantLeft:u,quadrantTop:d,quadrantWidth:f,quadrantHalfWidth:f/2,quadrantHeight:p,quadrantHalfHeight:p/2}}}getAxisLabels(e,t,n,r){let{quadrantSpace:i,titleSpace:a}=r,{quadrantHalfHeight:o,quadrantHeight:s,quadrantLeft:c,quadrantHalfWidth:l,quadrantTop:u,quadrantWidth:d}=i,f=!!this.data.xAxisRightText,p=!!this.data.yAxisTopText,m=[];return this.data.xAxisLeftText&&t&&m.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.xAxisRightText&&t&&m.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+l+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.yAxisBottomText&&n&&m.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+s-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),this.data.yAxisTopText&&n&&m.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+o-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),m}getQuadrants(e){let{quadrantSpace:t}=e,{quadrantHalfHeight:n,quadrantLeft:r,quadrantHalfWidth:i,quadrantTop:a}=t,o=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a,width:i,height:n,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a,width:i,height:n,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant4Fill}];for(let e of o)e.text.x=e.x+e.width/2,this.data.points.length===0?(e.text.y=e.y+e.height/2,e.text.horizontalPos=`middle`):(e.text.y=e.y+this.config.quadrantTextTopPadding,e.text.horizontalPos=`top`);return o}getQuadrantPoints(e){let{quadrantSpace:t}=e,{quadrantHeight:n,quadrantLeft:r,quadrantTop:i,quadrantWidth:a}=t,o=h().domain([0,1]).range([r,a+r]),s=h().domain([0,1]).range([n+i,i]);return this.data.points.map(e=>{let t=this.classes.get(e.className);return t&&(e={...t,...e}),{x:o(e.x),y:s(e.y),fill:e.color??this.themeConfig.quadrantPointFill,radius:e.radius??this.config.pointRadius,text:{text:e.text,fill:this.themeConfig.quadrantPointTextFill,x:o(e.x),y:s(e.y)+this.config.pointTextPadding,verticalPos:`center`,horizontalPos:`top`,fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:e.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:e.strokeWidth??`0px`}})}getBorders(e){let t=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:n}=e,{quadrantHalfHeight:r,quadrantHeight:i,quadrantLeft:a,quadrantHalfWidth:o,quadrantTop:s,quadrantWidth:c}=n;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s,x2:a+c+t,y2:s},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a+c,y1:s+t,x2:a+c,y2:s+i-t},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s+i,x2:a+c+t,y2:s+i},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a,y1:s+t,x2:a,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+o,y1:s+t,x2:a+o,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+t,y1:s+r,x2:a+c-t,y2:s+r}]}getTitle(e){if(e)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:`top`,verticalPos:`center`,rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){let e=this.config.showXAxis&&!!(this.data.xAxisLeftText||this.data.xAxisRightText),t=this.config.showYAxis&&!!(this.data.yAxisTopText||this.data.yAxisBottomText),n=this.config.showTitle&&!!this.data.titleText,r=this.data.points.length>0?`bottom`:this.config.xAxisPosition,i=this.calculateSpace(r,e,t,n);return{points:this.getQuadrantPoints(i),quadrants:this.getQuadrants(i),axisLabels:this.getAxisLabels(r,e,t,i),borderLines:this.getBorders(i),title:this.getTitle(n)}}},b=class extends Error{static{n(this,`InvalidStyleError`)}constructor(e,t,n){super(`value for ${e} ${t} is invalid, please use a valid ${n}`),this.name=`InvalidStyleError`}};function x(e){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(e)}n(x,`validateHexCode`);function S(e){return!/^\d+$/.test(e)}n(S,`validateNumber`);function C(e){return!/^\d+px$/.test(e)}n(C,`validateSizeInPixels`);function w(e){return m(e.trim(),f())}n(w,`textSanitizer`);var T=new y;function E(e){T.setData({quadrant1Text:w(e.text)})}n(E,`setQuadrant1Text`);function D(e){T.setData({quadrant2Text:w(e.text)})}n(D,`setQuadrant2Text`);function O(e){T.setData({quadrant3Text:w(e.text)})}n(O,`setQuadrant3Text`);function k(e){T.setData({quadrant4Text:w(e.text)})}n(k,`setQuadrant4Text`);function A(e){T.setData({xAxisLeftText:w(e.text)})}n(A,`setXAxisLeftText`);function j(e){T.setData({xAxisRightText:w(e.text)})}n(j,`setXAxisRightText`);function M(e){T.setData({yAxisTopText:w(e.text)})}n(M,`setYAxisTopText`);function N(e){T.setData({yAxisBottomText:w(e.text)})}n(N,`setYAxisBottomText`);function P(e){let t={};for(let n of e){let[e,r]=n.trim().split(/\s*:\s*/);if(e===`radius`){if(S(r))throw new b(e,r,`number`);t.radius=parseInt(r)}else if(e===`color`){if(x(r))throw new b(e,r,`hex code`);t.color=r}else if(e===`stroke-color`){if(x(r))throw new b(e,r,`hex code`);t.strokeColor=r}else if(e===`stroke-width`){if(C(r))throw new b(e,r,`number of pixels (eg. 10px)`);t.strokeWidth=r}else throw Error(`style named ${e} is not supported.`)}return t}n(P,`parseStyles`);function F(e,t,n,r,i){let a=P(i);T.addPoints([{x:n,y:r,text:w(e.text),className:t,...a}])}n(F,`addPoint`);function I(e,t){T.addClass(e,P(t))}n(I,`addClass`);function L(e){T.setConfig({chartWidth:e})}n(L,`setWidth`);function R(e){T.setConfig({chartHeight:e})}n(R,`setHeight`);function z(){let{themeVariables:e,quadrantChart:t}=f();return t&&T.setConfig(t),T.setThemeConfig({quadrant1Fill:e.quadrant1Fill,quadrant2Fill:e.quadrant2Fill,quadrant3Fill:e.quadrant3Fill,quadrant4Fill:e.quadrant4Fill,quadrant1TextFill:e.quadrant1TextFill,quadrant2TextFill:e.quadrant2TextFill,quadrant3TextFill:e.quadrant3TextFill,quadrant4TextFill:e.quadrant4TextFill,quadrantPointFill:e.quadrantPointFill,quadrantPointTextFill:e.quadrantPointTextFill,quadrantXAxisTextFill:e.quadrantXAxisTextFill,quadrantYAxisTextFill:e.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:e.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:e.quadrantInternalBorderStrokeFill,quadrantTitleFill:e.quadrantTitleFill}),T.setData({titleText:d()}),T.build()}n(z,`getQuadrantData`);var B={parser:_,db:{setWidth:L,setHeight:R,setQuadrant1Text:E,setQuadrant2Text:D,setQuadrant3Text:O,setQuadrant4Text:k,setXAxisLeftText:A,setXAxisRightText:j,setYAxisTopText:M,setYAxisBottomText:N,parseStyles:P,addPoint:F,addClass:I,getQuadrantData:z,clear:n(function(){T.clear(),o()},`clear`),setAccTitle:a,getAccTitle:p,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:i},renderer:{draw:n((r,i,a,o)=>{function c(e){return e===`top`?`hanging`:`middle`}n(c,`getDominantBaseLine`);function l(e){return e===`left`?`start`:`middle`}n(l,`getTextAnchor`);function u(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}n(u,`getTransformation`);let d=f();e.debug(`Rendering quadrant chart +`+r);let p=d.securityLevel,m;p===`sandbox`&&(m=t(`#i`+i));let h=t(p===`sandbox`?m.nodes()[0].contentDocument.body:`body`).select(`[id="${i}"]`),g=h.append(`g`).attr(`class`,`main`),_=d.quadrantChart?.chartWidth??500,v=d.quadrantChart?.chartHeight??500;s(h,v,_,d.quadrantChart?.useMaxWidth??!0),h.attr(`viewBox`,`0 0 `+_+` `+v),o.db.setHeight(v),o.db.setWidth(_);let y=o.db.getQuadrantData(),b=g.append(`g`).attr(`class`,`quadrants`),x=g.append(`g`).attr(`class`,`border`),S=g.append(`g`).attr(`class`,`data-points`),C=g.append(`g`).attr(`class`,`labels`),w=g.append(`g`).attr(`class`,`title`);y.title&&w.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,y.title.fill).attr(`font-size`,y.title.fontSize).attr(`dominant-baseline`,c(y.title.horizontalPos)).attr(`text-anchor`,l(y.title.verticalPos)).attr(`transform`,u(y.title)).text(y.title.text),y.borderLines&&x.selectAll(`line`).data(y.borderLines).enter().append(`line`).attr(`x1`,e=>e.x1).attr(`y1`,e=>e.y1).attr(`x2`,e=>e.x2).attr(`y2`,e=>e.y2).style(`stroke`,e=>e.strokeFill).style(`stroke-width`,e=>e.strokeWidth);let T=b.selectAll(`g.quadrant`).data(y.quadrants).enter().append(`g`).attr(`class`,`quadrant`);T.append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill),T.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>c(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text)).text(e=>e.text.text),C.selectAll(`g.label`).data(y.axisLabels).enter().append(`g`).attr(`class`,`label`).append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>c(e.horizontalPos)).attr(`text-anchor`,e=>l(e.verticalPos)).attr(`transform`,e=>u(e));let E=S.selectAll(`g.data-point`).data(y.points).enter().append(`g`).attr(`class`,`data-point`);E.append(`circle`).attr(`cx`,e=>e.x).attr(`cy`,e=>e.y).attr(`r`,e=>e.radius).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeColor).attr(`stroke-width`,e=>e.strokeWidth),E.append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text.text).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>c(e.text.horizontalPos)).attr(`text-anchor`,e=>l(e.text.verticalPos)).attr(`transform`,e=>u(e.text))},`draw`)},styles:n(()=>``,`styles`)};export{B as diagram}; \ No newline at end of file diff --git a/www/assets/radar-RG4KPBEZ-BsN_WAuk.js b/www/assets/radar-RG4KPBEZ-BsN_WAuk.js new file mode 100644 index 0000000..7a9497e --- /dev/null +++ b/www/assets/radar-RG4KPBEZ-BsN_WAuk.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{v as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRadarServices}; \ No newline at end of file diff --git a/www/assets/railroad-74A4TZTK-CYJJ-7AP.js b/www/assets/railroad-74A4TZTK-CYJJ-7AP.js new file mode 100644 index 0000000..4a2773f --- /dev/null +++ b/www/assets/railroad-74A4TZTK-CYJJ-7AP.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{g as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadServices}; \ No newline at end of file diff --git a/www/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js b/www/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js new file mode 100644 index 0000000..ac16143 --- /dev/null +++ b/www/assets/railroad-abnf-HS5TGJTU-XdDFvlUB.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{m as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadAbnfServices}; \ No newline at end of file diff --git a/www/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js b/www/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js new file mode 100644 index 0000000..a333b8f --- /dev/null +++ b/www/assets/railroad-ebnf-LZEXJU2U-BuSvGFsc.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{f as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadEbnfServices}; \ No newline at end of file diff --git a/www/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js b/www/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js new file mode 100644 index 0000000..df71386 --- /dev/null +++ b/www/assets/railroad-peg-WCYAUIDC-CNjo3yz4.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{u as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createRailroadPegServices}; \ No newline at end of file diff --git a/www/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js b/www/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js new file mode 100644 index 0000000..71dbe67 --- /dev/null +++ b/www/assets/railroadDiagram-XR7U4H2S-BHZ1Lx2I.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./index-DoQkmpth.js";import{g as n,t as r}from"./mermaid-parser.core-CUrDj5TF.js";import{n as i,r as a,t as o}from"./chunk-GTNCS2PH-CoZ--rjp.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=n().Railroad.parser.LangiumParser,l=t(e=>{switch(e.$type){case`RailroadTerminalExpr`:return{type:`terminal`,value:e.value};case`RailroadNonTerminalExpr`:return{type:`nonterminal`,name:e.name};case`RailroadSpecialExpr`:return{type:`special`,text:e.text};case`RailroadSequenceExpr`:{let t=e.elements.map(l);return t.length===1?t[0]:{type:`sequence`,elements:t}}case`RailroadChoiceExpr`:{let t=e.alternatives.map(l);return t.length===1?t[0]:{type:`choice`,alternatives:t}}case`RailroadOptionalExpr`:return{type:`optional`,element:l(e.element)};case`RailroadOneOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:1,max:1/0};case`RailroadZeroOrMoreExpr`:return{type:`repetition`,element:l(e.element),min:0,max:1/0};default:throw Error(`Unsupported railroad expression: ${e.$type}`)}},`transformExpression`),u=t(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),d=t(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(u(e)))},`populateDb`),f={parser:{parse:t(t=>{o.clear(),e.debug(`[Railroad Parser] Starting Langium parse`);let n=c.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new r(n);let i=n.value;e.debug(`[Railroad Parser] Parsed rules:`,i.rules.length),d(i),e.debug(`[Railroad Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{f as diagram}; \ No newline at end of file diff --git a/www/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js b/www/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js new file mode 100644 index 0000000..1acf46a --- /dev/null +++ b/www/assets/requirementDiagram-PLB6GJNP-C2fhrVbm.js @@ -0,0 +1,84 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t,t as n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as r,U as i,a,b as o,q as s,v as c,w as l,x as u,y as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{g as f}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{a as p,i as m,o as h,r as g}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import{n as _,t as v}from"./index-DoQkmpth.js";import{t as y}from"./chunk-XXDRQBXY-C1_eEj17.js";import{t as b}from"./chunk-WEXAMYUT-I3m-hOmT.js";var x=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],s=[1,22],c=[2,7],l=[1,26],u=[1,27],d=[1,28],f=[1,29],p=[1,33],m=[1,34],h=[1,35],g=[1,36],_=[1,37],v=[1,38],y=[1,24],b=[1,31],x=[1,32],S=[1,30],C=[1,39],w=[1,40],T=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],E=[1,61],D=[89,90],O=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],k=[27,29],ee=[1,70],A=[1,71],te=[1,72],ne=[1,73],re=[1,74],ie=[1,75],ae=[1,76],j=[1,83],M=[1,80],N=[1,84],P=[1,85],F=[1,86],I=[1,87],L=[1,88],R=[1,89],z=[1,90],B=[1,91],V=[1,92],oe=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],H=[63,64],se=[1,101],ce=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],U=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],W=[1,110],G=[1,106],K=[1,107],q=[1,108],J=[1,109],Y=[1,111],X=[1,116],Z=[1,117],Q=[1,114],$=[1,115],le={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:`error`,5:`NEWLINE`,6:`RD`,8:`EOF`,9:`acc_title`,10:`acc_title_value`,11:`acc_descr`,12:`acc_descr_value`,13:`acc_descr_multiline_value`,21:`direction_tb`,22:`direction_bt`,23:`direction_rl`,24:`direction_lr`,27:`STRUCT_START`,29:`STYLE_SEPARATOR`,31:`ID`,32:`COLONSEP`,34:`TEXT`,36:`RISK`,38:`VERIFYMTHD`,40:`STRUCT_STOP`,41:`REQUIREMENT`,42:`FUNCTIONAL_REQUIREMENT`,43:`INTERFACE_REQUIREMENT`,44:`PERFORMANCE_REQUIREMENT`,45:`PHYSICAL_REQUIREMENT`,46:`DESIGN_CONSTRAINT`,47:`LOW_RISK`,48:`MED_RISK`,49:`HIGH_RISK`,50:`VERIFY_ANALYSIS`,51:`VERIFY_DEMONSTRATION`,52:`VERIFY_INSPECTION`,53:`VERIFY_TEST`,54:`ELEMENT`,57:`TYPE`,59:`DOCREF`,61:`END_ARROW_L`,63:`LINE`,64:`END_ARROW_R`,65:`CONTAINS`,66:`COPIES`,67:`DERIVES`,68:`SATISFIES`,69:`VERIFIES`,70:`REFINES`,71:`TRACES`,72:`CLASSDEF`,74:`CLASS`,75:`ALPHA`,76:`COMMA`,77:`STYLE`,80:`NUM`,81:`COLON`,82:`UNIT`,83:`SPACE`,84:`BRKT`,85:`PCT`,86:`MINUS`,87:`LABEL`,88:`SEMICOLON`,89:`unqString`,90:`qString`},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 5:case 6:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:r.setDirection(`TB`);break;case 18:r.setDirection(`BT`);break;case 19:r.setDirection(`RL`);break;case 20:r.setDirection(`LR`);break;case 21:r.addRequirement(a[s-3],a[s-4]);break;case 22:r.addRequirement(a[s-5],a[s-6]),r.setClass([a[s-5]],a[s-3]);break;case 23:r.setNewReqId(a[s-2]);break;case 24:r.setNewReqText(a[s-2]);break;case 25:r.setNewReqRisk(a[s-2]);break;case 26:r.setNewReqVerifyMethod(a[s-2]);break;case 29:this.$=r.RequirementType.REQUIREMENT;break;case 30:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=r.RiskLevel.LOW_RISK;break;case 36:this.$=r.RiskLevel.MED_RISK;break;case 37:this.$=r.RiskLevel.HIGH_RISK;break;case 38:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=r.VerifyType.VERIFY_TEST;break;case 42:r.addElement(a[s-3]);break;case 43:r.addElement(a[s-5]),r.setClass([a[s-5]],a[s-3]);break;case 44:r.setNewElementType(a[s-2]);break;case 45:r.setNewElementDocRef(a[s-2]);break;case 48:r.addRelationship(a[s-2],a[s],a[s-4]);break;case 49:r.addRelationship(a[s-2],a[s-4],a[s]);break;case 50:this.$=r.Relationships.CONTAINS;break;case 51:this.$=r.Relationships.COPIES;break;case 52:this.$=r.Relationships.DERIVES;break;case 53:this.$=r.Relationships.SATISFIES;break;case 54:this.$=r.Relationships.VERIFIES;break;case 55:this.$=r.Relationships.REFINES;break;case 56:this.$=r.Relationships.TRACES;break;case 57:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 58:r.setClass(a[s-1],a[s]);break;case 59:r.setClass([a[s-2]],a[s]);break;case 60:case 62:this.$=[a[s]];break;case 61:case 63:this.$=a[s-2].concat([a[s]]);break;case 64:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 65:this.$=[a[s]];break;case 66:a[s-2].push(a[s]),this.$=a[s-2];break;case 68:this.$=a[s-1]+a[s]}},`anonymous`),table:[{3:1,4:2,6:n,9:r,11:i,13:a},{1:[3]},{3:8,4:2,5:[1,7],6:n,9:r,11:i,13:a},{5:[1,9]},{10:[1,10]},{12:[1,11]},e(o,[2,6]),{3:12,4:2,6:n,9:r,11:i,13:a},{1:[2,2]},{4:17,5:s,7:13,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},e(o,[2,4]),e(o,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:s,7:42,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:43,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:44,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:45,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:46,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:47,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:48,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:49,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:50,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},e(T,[2,17]),e(T,[2,18]),e(T,[2,19]),e(T,[2,20]),{30:60,33:62,75:E,89:C,90:w},{30:63,33:62,75:E,89:C,90:w},{30:64,33:62,75:E,89:C,90:w},e(D,[2,29]),e(D,[2,30]),e(D,[2,31]),e(D,[2,32]),e(D,[2,33]),e(D,[2,34]),e(O,[2,81]),e(O,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},e(k,[2,79]),e(k,[2,80]),{27:[1,67],29:[1,68]},e(k,[2,85]),e(k,[2,86]),{62:69,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{62:77,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{30:78,33:62,75:E,89:C,90:w},{73:79,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,60]),e(oe,[2,62]),{73:93,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},{30:94,33:62,75:E,76:M,89:C,90:w},{5:[1,95]},{30:96,33:62,75:E,89:C,90:w},{5:[1,97]},{30:98,33:62,75:E,89:C,90:w},{63:[1,99]},e(H,[2,50]),e(H,[2,51]),e(H,[2,52]),e(H,[2,53]),e(H,[2,54]),e(H,[2,55]),e(H,[2,56]),{64:[1,100]},e(T,[2,59],{76:M}),e(T,[2,64],{76:se}),{33:103,75:[1,102],89:C,90:w},e(ce,[2,65],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),e(U,[2,67]),e(U,[2,69]),e(U,[2,70]),e(U,[2,71]),e(U,[2,72]),e(U,[2,73]),e(U,[2,74]),e(U,[2,75]),e(U,[2,76]),e(U,[2,77]),e(U,[2,78]),e(T,[2,57],{76:se}),e(T,[2,58],{76:M}),{5:W,28:105,31:G,34:K,36:q,38:J,40:Y},{27:[1,112],76:M},{5:X,40:Z,56:113,57:Q,59:$},{27:[1,118],76:M},{33:119,89:C,90:w},{33:120,89:C,90:w},{75:j,78:121,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,61]),e(oe,[2,63]),e(U,[2,68]),e(T,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:W,28:126,31:G,34:K,36:q,38:J,40:Y},e(T,[2,28]),{5:[1,127]},e(T,[2,42]),{32:[1,128]},{32:[1,129]},{5:X,40:Z,56:130,57:Q,59:$},e(T,[2,47]),{5:[1,131]},e(T,[2,48]),e(T,[2,49]),e(ce,[2,66],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),{33:132,89:C,90:w},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},e(T,[2,27]),{5:W,28:145,31:G,34:K,36:q,38:J,40:Y},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},e(T,[2,46]),{5:X,40:Z,56:152,57:Q,59:$},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},e(T,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},e(T,[2,43]),{5:W,28:159,31:G,34:K,36:q,38:J,40:Y},{5:W,28:160,31:G,34:K,36:q,38:J,40:Y},{5:W,28:161,31:G,34:K,36:q,38:J,40:Y},{5:W,28:162,31:G,34:K,36:q,38:J,40:Y},{5:X,40:Z,56:163,57:Q,59:$},{5:X,40:Z,56:164,57:Q,59:$},e(T,[2,23]),e(T,[2,24]),e(T,[2,25]),e(T,[2,26]),e(T,[2,44]),e(T,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],s[w])this.terminals_[O]&&O>f&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),ee=s[r[r.length-2]][r[r.length-1]],r.push(ee);break;case 3:return!0}}return!0},`parse`)};le.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return`title`;case 1:return this.begin(`acc_title`),9;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),11;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:break;case 14:break;case 15:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin(`style`),77;case 50:return 75;case 51:return 81;case 52:return 88;case 53:return`PERCENT`;case 54:return 86;case 55:return 84;case 56:break;case 57:this.begin(`string`);break;case 58:this.popState();break;case 59:return this.begin(`style`),72;case 60:return this.begin(`style`),74;case 61:return 61;case 62:return 64;case 63:return 63;case 64:this.begin(`string`);break;case 65:this.popState();break;case 66:return`qString`;case 67:return t.yytext=t.yytext.trim(),89;case 68:return 75;case 69:return 80;case 70:return 76}},`anonymous`),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}}})();function ue(){this.yy={}}return t(ue,`Parser`),ue.prototype=le,le.Parser=ue,new ue})();x.parser=x;var S=x,C=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction=`TB`,this.RequirementType={REQUIREMENT:`Requirement`,FUNCTIONAL_REQUIREMENT:`Functional Requirement`,INTERFACE_REQUIREMENT:`Interface Requirement`,PERFORMANCE_REQUIREMENT:`Performance Requirement`,PHYSICAL_REQUIREMENT:`Physical Requirement`,DESIGN_CONSTRAINT:`Design Constraint`},this.RiskLevel={LOW_RISK:`Low`,MED_RISK:`Medium`,HIGH_RISK:`High`},this.VerifyType={VERIFY_ANALYSIS:`Analysis`,VERIFY_DEMONSTRATION:`Demonstration`,VERIFY_INSPECTION:`Inspection`,VERIFY_TEST:`Test`},this.Relationships={CONTAINS:`contains`,COPIES:`copies`,DERIVES:`derives`,SATISFIES:`satisfies`,VERIFIES:`verifies`,REFINES:`refines`,TRACES:`traces`},this.setAccTitle=i,this.getAccTitle=d,this.setAccDescription=r,this.getAccDescription=c,this.setDiagramTitle=s,this.getDiagramTitle=l,this.getConfig=t(()=>u().requirement,`getConfig`),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{t(this,`RequirementDB`)}getDirection(){return this.direction}setDirection(e){this.direction=e}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:``,text:``,risk:``,verifyMethod:``,name:``,type:``,cssStyles:[],classes:[`default`]}}getInitialElement(){return{name:``,type:``,docRef:``,cssStyles:[],classes:[`default`]}}addRequirement(e,t){return this.requirements.has(e)||this.requirements.set(e,{name:e,type:t,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:[`default`]}),this.resetLatestRequirement(),this.requirements.get(e)}getRequirements(){return this.requirements}setNewReqId(e){this.latestRequirement!==void 0&&(this.latestRequirement.requirementId=e)}setNewReqText(e){this.latestRequirement!==void 0&&(this.latestRequirement.text=e)}setNewReqRisk(e){this.latestRequirement!==void 0&&(this.latestRequirement.risk=e)}setNewReqVerifyMethod(e){this.latestRequirement!==void 0&&(this.latestRequirement.verifyMethod=e)}addElement(t){return this.elements.has(t)||(this.elements.set(t,{name:t,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:[`default`]}),e.info(`Added new element: `,t)),this.resetLatestElement(),this.elements.get(t)}getElements(){return this.elements}setNewElementType(e){this.latestElement!==void 0&&(this.latestElement.type=e)}setNewElementDocRef(e){this.latestElement!==void 0&&(this.latestElement.docRef=e)}addRelationship(e,t,n){this.relations.push({type:e,src:t,dst:n})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,a()}setCssStyle(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(!t||!e)return;for(let n of t)n.includes(`,`)?e.cssStyles.push(...n.split(`,`)):e.cssStyles.push(n)}}setClass(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(e)for(let n of t){e.classes.push(n);let t=this.classes.get(n)?.styles;t&&e.cssStyles.push(...t)}}}defineClass(e,t){for(let n of e){let e=this.classes.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.classes.set(n,e)),t&&t.forEach(function(t){if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.requirements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))}),this.elements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))})}}getClasses(){return this.classes}getData(){let e=u(),t=[],n=[];for(let n of this.requirements.values()){let r=n;r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.shape=`requirementBox`,r.look=e.look,r.colorIndex=t.length,t.push(r)}for(let n of this.elements.values()){let r=n;r.shape=`requirementBox`,r.look=e.look,r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.colorIndex=t.length,t.push(r)}let r=0;for(let t of this.relations){let i=t.type===this.Relationships.CONTAINS,a={id:`${t.src}-${t.dst}-${r++}`,start:this.requirements.get(t.src)?.name??this.elements.get(t.src)?.name,end:this.requirements.get(t.dst)?.name??this.elements.get(t.dst)?.name,label:`<<${t.type}>>`,classes:`relationshipLine`,style:[`fill:none`,i?``:`stroke-dasharray: 10,7`],labelpos:`c`,thickness:`normal`,type:`normal`,pattern:i?`normal`:`dashed`,arrowTypeStart:i?`requirement_contains`:``,arrowTypeEnd:i?``:`requirement_arrow`,look:e.look,labelType:`markdown`};n.push(a)}return{nodes:t,edges:n,other:{},config:e,direction:this.getDirection()}}},w=t(()=>{let e=o(),{theme:t,themeVariables:n}=e,{bkgColorArray:r,borderColorArray:i}=n;if(!m(t,i))return``;let a=h(e.look),s=``,c=g(r);for(let e=0;e{let{look:t,themeVariables:n}=o(),{requirementEdgeLabelBackground:r}=n;return` + ${w()} + marker { + fill: ${e.relationColor}; + stroke: ${e.relationColor}; + } + + marker.cross { + stroke: ${e.lineColor}; + } + + svg { + font-family: ${e.fontFamily}; + font-size: ${e.fontSize}; + } + + .reqBox { + fill: ${e.requirementBackground}; + fill-opacity: 1.0; + stroke: ${e.requirementBorderColor}; + stroke-width: ${e.requirementBorderSize}; + } + + .reqTitle, .reqLabel{ + fill: ${e.requirementTextColor}; + } + .reqLabelBox { + fill: ${e.relationLabelBackground}; + fill-opacity: 1.0; + } + + .req-title-line { + stroke: ${e.requirementBorderColor}; + stroke-width: ${e.requirementBorderSize}; + } + .relationshipLine { + stroke: ${e.relationColor}; + stroke-width: ${t===`neo`?e.strokeWidth:`1px`}; + } + .relationshipLabel { + fill: ${e.relationLabelColor}; + } + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + } + .edgeLabel .label rect { + fill: ${e.edgeLabelBackground}; + } + .edgeLabel .label text { + fill: ${e.relationLabelColor}; + } + .divider { + stroke: ${e.nodeBorder}; + stroke-width: 1; + } + .label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + .labelBkg { + background-color: ${r??e.edgeLabelBackground}; + } + +`},`getStyles`),E={};n(E,{draw:()=>D});var D=t(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing requirement diagram (unified)`,n);let{securityLevel:a,state:o,layout:s,look:c}=u(),l=i.db.getData(),d=y(n,a);l.type=i.type,l.layoutAlgorithm=v(s),l.nodeSpacing=o?.nodeSpacing??50,l.rankSpacing=o?.rankSpacing??50,l.markers=c===`neo`?[`requirement_contains_neo`,`requirement_arrow_neo`]:[`requirement_contains`,`requirement_arrow`],l.diagramId=n,await _(l,d),f.insertTitle(d,`requirementDiagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),b(d,8,`requirementDiagram`,o?.useMaxWidth??!0)},`draw`),O={parser:S,get db(){return new C},renderer:E,styles:T};export{O as diagram}; \ No newline at end of file diff --git a/www/assets/rough.esm-Dy-Kn_BL.js b/www/assets/rough.esm-Dy-Kn_BL.js new file mode 100644 index 0000000..e503ecf --- /dev/null +++ b/www/assets/rough.esm-Dy-Kn_BL.js @@ -0,0 +1 @@ +function e(e,t,n){if(e&&e.length){let[r,i]=t,a=Math.PI/180*n,o=Math.cos(a),s=Math.sin(a);for(let t of e){let[e,n]=t;t[0]=(e-r)*o-(n-i)*s+r,t[1]=(e-r)*s+(n-i)*o+i}}}function t(e,t){return e[0]===t[0]&&e[1]===t[1]}function n(n,r,i,a=1){let o=i,s=Math.max(r,.1),c=n[0]&&n[0][0]&&typeof n[0][0]==`number`?[n]:n,l=[0,0];if(o)for(let t of c)e(t,l,o);let u=function(e,n,r){let i=[];for(let n of e){let e=[...n];t(e[0],e[e.length-1])||e.push([e[0][0],e[0][1]]),e.length>2&&i.push(e)}let a=[];n=Math.max(n,.1);let o=[];for(let e of i)for(let t=0;te.ymint.ymin?1:e.xt.x?1:e.ymax===t.ymax?0:(e.ymax-t.ymax)/Math.abs(e.ymax-t.ymax))),!o.length)return a;let s=[],c=o[0].ymin,l=0;for(;s.length||o.length;){if(o.length){let e=-1;for(let t=0;tc);t++)e=t;o.splice(0,e+1).forEach((e=>{s.push({s:c,edge:e})}))}if(s=s.filter((e=>!(e.edge.ymax<=c))),s.sort(((e,t)=>e.edge.x===t.edge.x?0:(e.edge.x-t.edge.x)/Math.abs(e.edge.x-t.edge.x))),(r!==1||l%n==0)&&s.length>1)for(let e=0;e=s.length)break;let n=s[e].edge,r=s[t].edge;a.push([[Math.round(n.x),c],[Math.round(r.x),c]])}c+=r,s.forEach((e=>{e.edge.x=e.edge.x+r*e.edge.islope})),l++}return a}(c,s,a);if(o){for(let t of c)e(t,l,-o);(function(t,n,r){let i=[];t.forEach((e=>i.push(...e))),e(i,n,r)})(u,l,-o)}return u}function r(e,t){let r=t.hachureAngle+90,i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let a=1;return t.roughness>=1&&(t.randomizer?.next()||Math.random())>.7&&(a=i),n(e,i,r,a||1)}var i=class{constructor(e){this.helper=e}fillPolygons(e,t){return this._fillPolygons(e,t)}_fillPolygons(e,t){let n=r(e,t);return{type:`fillSketch`,ops:this.renderLines(n,t)}}renderLines(e,t){let n=[];for(let r of e)n.push(...this.helper.doubleLineOps(r[0][0],r[0][1],r[1][0],r[1][1],t));return n}};function a(e){let t=e[0],n=e[1];return Math.sqrt((t[0]-n[0])**2+(t[1]-n[1])**2)}var o=class extends i{fillPolygons(e,t){let n=t.hachureGap;n<0&&(n=4*t.strokeWidth),n=Math.max(n,.1);let i=r(e,Object.assign({},t,{hachureGap:n})),o=Math.PI/180*t.hachureAngle,s=[],c=.5*n*Math.cos(o),l=.5*n*Math.sin(o);for(let[e,t]of i)a([e,t])&&s.push([[e[0]-c,e[1]+l],[...t]],[[e[0]+c,e[1]-l],[...t]]);return{type:`fillSketch`,ops:this.renderLines(s,t)}}},s=class extends i{fillPolygons(e,t){let n=this._fillPolygons(e,t),r=Object.assign({},t,{hachureAngle:t.hachureAngle+90}),i=this._fillPolygons(e,r);return n.ops=n.ops.concat(i.ops),n}},c=class{constructor(e){this.helper=e}fillPolygons(e,t){let n=r(e,t=Object.assign({},t,{hachureAngle:0}));return this.dotsOnLines(n,t)}dotsOnLines(e,t){let n=[],r=t.hachureGap;r<0&&(r=4*t.strokeWidth),r=Math.max(r,.1);let i=t.fillWeight;i<0&&(i=t.strokeWidth/2);let o=r/4;for(let s of e){let e=a(s),c=e/r,l=Math.ceil(c)-1,u=e-l*r,d=(s[0][0]+s[1][0])/2-r/4,f=Math.min(s[0][1],s[1][1]);for(let e=0;e{let o=a(e),s=Math.floor(o/(n+r)),c=(o+r-s*(n+r))/2,l=e[0],u=e[1];l[0]>u[0]&&(l=e[1],u=e[0]);let d=Math.atan((u[1]-l[1])/(u[0]-l[0]));for(let e=0;e{let i=a(e),o=Math.round(i/(2*t)),s=e[0],c=e[1];s[0]>c[0]&&(s=e[1],c=e[0]);let l=Math.atan((c[1]-s[1])/(c[0]-s[0]));for(let e=0;er%2?e+n:e+t));a.push({key:`C`,data:e}),t=e[4],n=e[5];break}case`Q`:a.push({key:`Q`,data:[...s]}),t=s[2],n=s[3];break;case`q`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`Q`,data:e}),t=e[2],n=e[3];break}case`A`:a.push({key:`A`,data:[...s]}),t=s[5],n=s[6];break;case`a`:t+=s[5],n+=s[6],a.push({key:`A`,data:[s[0],s[1],s[2],s[3],s[4],t,n]});break;case`H`:a.push({key:`H`,data:[...s]}),t=s[0];break;case`h`:t+=s[0],a.push({key:`H`,data:[t]});break;case`V`:a.push({key:`V`,data:[...s]}),n=s[0];break;case`v`:n+=s[0],a.push({key:`V`,data:[n]});break;case`S`:a.push({key:`S`,data:[...s]}),t=s[2],n=s[3];break;case`s`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`S`,data:e}),t=e[2],n=e[3];break}case`T`:a.push({key:`T`,data:[...s]}),t=s[0],n=s[1];break;case`t`:t+=s[0],n+=s[1],a.push({key:`T`,data:[t,n]});break;case`Z`:case`z`:a.push({key:`Z`,data:[]}),t=r,n=i}return a}function b(e){let t=[],n=``,r=0,i=0,a=0,o=0,s=0,c=0;for(let{key:l,data:u}of e){switch(l){case`M`:t.push({key:`M`,data:[...u]}),[r,i]=u,[a,o]=u;break;case`C`:t.push({key:`C`,data:[...u]}),r=u[4],i=u[5],s=u[2],c=u[3];break;case`L`:t.push({key:`L`,data:[...u]}),[r,i]=u;break;case`H`:r=u[0],t.push({key:`L`,data:[r,i]});break;case`V`:i=u[0],t.push({key:`L`,data:[r,i]});break;case`S`:{let e=0,a=0;n===`C`||n===`S`?(e=r+(r-s),a=i+(i-c)):(e=r,a=i),t.push({key:`C`,data:[e,a,...u]}),s=u[0],c=u[1],r=u[2],i=u[3];break}case`T`:{let[e,a]=u,o=0,l=0;n===`Q`||n===`T`?(o=r+(r-s),l=i+(i-c)):(o=r,l=i);let d=r+2*(o-r)/3,f=i+2*(l-i)/3,p=e+2*(o-e)/3,m=a+2*(l-a)/3;t.push({key:`C`,data:[d,f,p,m,e,a]}),s=o,c=l,r=e,i=a;break}case`Q`:{let[e,n,a,o]=u,l=r+2*(e-r)/3,d=i+2*(n-i)/3,f=a+2*(e-a)/3,p=o+2*(n-o)/3;t.push({key:`C`,data:[l,d,f,p,a,o]}),s=e,c=n,r=a,i=o;break}case`A`:{let e=Math.abs(u[0]),n=Math.abs(u[1]),a=u[2],o=u[3],s=u[4],c=u[5],l=u[6];e===0||n===0?(t.push({key:`C`,data:[r,i,c,l,c,l]}),r=c,i=l):(r!==c||i!==l)&&(S(r,i,c,l,e,n,a,o,s).forEach((function(e){t.push({key:`C`,data:e})})),r=c,i=l);break}case`Z`:t.push({key:`Z`,data:[]}),r=a,i=o}n=l}return t}function x(e,t,n){return[e*Math.cos(n)-t*Math.sin(n),e*Math.sin(n)+t*Math.cos(n)]}function S(e,t,n,r,i,a,o,s,c,l){let u=(d=o,Math.PI*d/180);var d;let f=[],p=0,m=0,h=0,g=0;if(l)[p,m,h,g]=l;else{[e,t]=x(e,t,-u),[n,r]=x(n,r,-u);let o=(e-n)/2,l=(t-r)/2,d=o*o/(i*i)+l*l/(a*a);d>1&&(d=Math.sqrt(d),i*=d,a*=d);let f=i*i,_=a*a,v=f*_-f*l*l-_*o*o,y=f*l*l+_*o*o,b=(s===c?-1:1)*Math.sqrt(Math.abs(v/y));h=b*i*l/a+(e+n)/2,g=b*-a*o/i+(t+r)/2,p=Math.asin(parseFloat(((t-g)/a).toFixed(9))),m=Math.asin(parseFloat(((r-g)/a).toFixed(9))),em&&(p-=2*Math.PI),!c&&m>p&&(m-=2*Math.PI)}let _=m-p;if(Math.abs(_)>120*Math.PI/180){let e=m,t=n,s=r;m=c&&m>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,f=S(n=h+i*Math.cos(m),r=g+a*Math.sin(m),t,s,i,a,o,0,c,[m,e,h,g])}_=m-p;let v=Math.cos(p),y=Math.sin(p),b=Math.cos(m),C=Math.sin(m),w=Math.tan(_/4),T=4/3*i*w,E=4/3*a*w,D=[e,t],O=[e+T*y,t-E*v],k=[n+T*C,r-E*b],A=[n,r];if(O[0]=2*D[0]-O[0],O[1]=2*D[1]-O[1],l)return[O,k,A].concat(f);{f=[O,k,A].concat(f);let e=[];for(let t=0;t2){let i=[];for(let t=0;t2*Math.PI&&(p=0,m=2*Math.PI);let h=2*Math.PI/c.curveStepCount,g=Math.min(h/2,(m-p)/2),_=U(g,l,u,d,f,p,m,1,c);if(!c.disableMultiStroke){let e=U(g,l,u,d,f,p,m,1.5,c);_.push(...e)}return o&&(s?_.push(...R(l,u,l+d*Math.cos(p),u+f*Math.sin(p),c),...R(l,u,l+d*Math.cos(m),u+f*Math.sin(m),c)):_.push({op:`lineTo`,data:[l,u]},{op:`lineTo`,data:[l+d*Math.cos(p),u+f*Math.sin(p)]})),{type:`path`,ops:_}}function j(e,t){let n=b(y(v(e))),r=[],i=[0,0],a=[0,0];for(let{key:e,data:o}of n)switch(e){case`M`:a=[o[0],o[1]],i=[o[0],o[1]];break;case`L`:r.push(...R(a[0],a[1],o[0],o[1],t)),a=[o[0],o[1]];break;case`C`:{let[e,n,i,s,c,l]=o;r.push(...ee(e,n,i,s,c,l,a,t)),a=[c,l];break}case`Z`:r.push(...R(a[0],a[1],i[0],i[1],t)),a=[i[0],i[1]]}return{type:`path`,ops:r}}function M(e,t){let n=[];for(let r of e)if(r.length){let e=t.maxRandomnessOffset||0,i=r.length;if(i>2){n.push({op:`move`,data:[r[0][0]+L(e,t),r[0][1]+L(e,t)]});for(let a=1;a500?.4:-.0016668*c+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>s&&(u=c/10);let d=u/2,f=.2+.2*F(i),p=i.bowing*i.maxRandomnessOffset*(r-t)/200,m=i.bowing*i.maxRandomnessOffset*(e-n)/200;p=L(p,i,l),m=L(m,i,l);let h=[],g=()=>L(d,i,l),_=()=>L(u,i,l),v=i.preserveVertices;return a&&(o?h.push({op:`move`,data:[e+(v?0:g()),t+(v?0:g())]}):h.push({op:`move`,data:[e+(v?0:L(u,i,l)),t+(v?0:L(u,i,l))]})),o?h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+g(),m+t+(r-t)*f+g(),p+e+2*(n-e)*f+g(),m+t+2*(r-t)*f+g(),n+(v?0:g()),r+(v?0:g())]}):h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+_(),m+t+(r-t)*f+_(),p+e+2*(n-e)*f+_(),m+t+2*(r-t)*f+_(),n+(v?0:_()),r+(v?0:_())]}),h}function B(e,t,n){if(!e.length)return[];let r=[];r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]),r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]);for(let i=1;i3){let a=[],o=1-n.curveTightness;i.push({op:`move`,data:[e[1][0],e[1][1]]});for(let t=1;t+21&&i.push(n)):i.push(n),i.push(e[t+3])}else{let r=.5,a=e[t+0],o=e[t+1],s=e[t+2],c=e[t+3],l=q(a,o,r),u=q(o,s,r),d=q(s,c,r),f=q(l,u,r),p=q(u,d,r),m=q(f,p,r);J([a,l,f,m],0,n,i),J([m,p,d,c],0,n,i)}var a,o;return i}function ne(e,t){return Y(e,0,e.length,t)}function Y(e,t,n,r,i){let a=i||[],o=e[t],s=e[n-1],c=0,l=1;for(let r=t+1;rc&&(c=t,l=r)}return Math.sqrt(c)>r?(Y(e,t,l+1,r,a),Y(e,l,n,r,a)):(a.length||a.push(o),a.push(s)),a}function X(e,t=.15,n){let r=[],i=(e.length-1)/3;for(let n=0;n0?Y(r,0,r.length,n):r}var Z=`none`,Q=class{constructor(e){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:`#000`,strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:`hachure`,fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=e||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(e){return e?Object.assign({},this.defaultOptions,e):this.defaultOptions}_d(e,t,n){return{shape:e,sets:t||[],options:n||this.defaultOptions}}line(e,t,n,r,i){let a=this._o(i);return this._d(`line`,[w(e,t,n,r,a)],a)}rectangle(e,t,n,r,i){let a=this._o(i),o=[],s=E(e,t,n,r,a);if(a.fill){let i=[[e,t],[e+n,t],[e+n,t+r],[e,t+r]];a.fillStyle===`solid`?o.push(M([i],a)):o.push(N([i],a))}return a.stroke!==Z&&o.push(s),this._d(`rectangle`,o,a)}ellipse(e,t,n,r,i){let a=this._o(i),o=[],s=O(n,r,a),c=k(e,t,a,s);if(a.fill){if(a.fillStyle===`solid`){let n=k(e,t,a,s).opset;n.type=`fillPath`,o.push(n)}else o.push(N([c.estimatedPoints],a))}return a.stroke!==Z&&o.push(c.opset),this._d(`ellipse`,o,a)}circle(e,t,n,r){let i=this.ellipse(e,t,n,n,r);return i.shape=`circle`,i}linearPath(e,t){let n=this._o(t);return this._d(`linearPath`,[T(e,!1,n)],n)}arc(e,t,n,r,i,a,o=!1,s){let c=this._o(s),l=[],u=A(e,t,n,r,i,a,o,!0,c);if(o&&c.fill){if(c.fillStyle===`solid`){let o=Object.assign({},c);o.disableMultiStroke=!0;let s=A(e,t,n,r,i,a,!0,!1,o);s.type=`fillPath`,l.push(s)}else l.push(function(e,t,n,r,i,a,o){let s=e,c=t,l=Math.abs(n/2),u=Math.abs(r/2);l+=L(.01*l,o),u+=L(.01*u,o);let d=i,f=a;for(;d<0;)d+=2*Math.PI,f+=2*Math.PI;f-d>2*Math.PI&&(d=0,f=2*Math.PI);let p=(f-d)/o.curveStepCount,m=[];for(let e=d;e<=f;e+=p)m.push([s+l*Math.cos(e),c+u*Math.sin(e)]);return m.push([s+l*Math.cos(f),c+u*Math.sin(f)]),m.push([s,c]),N([m],o)}(e,t,n,r,i,a,c))}return c.stroke!==Z&&l.push(u),this._d(`arc`,l,c)}curve(e,t){let n=this._o(t),r=[],i=D(e,n);if(n.fill&&n.fill!==Z){if(n.fillStyle===`solid`){let t=D(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else{let t=[],i=e;if(i.length){let e=typeof i[0][0]==`number`?[i]:i;for(let r of e)r.length<3?t.push(...r):r.length===3?t.push(...X(G([r[0],r[0],r[1],r[2]]),10,(1+n.roughness)/2)):t.push(...X(G(r),10,(1+n.roughness)/2))}t.length&&r.push(N([t],n))}}return n.stroke!==Z&&r.push(i),this._d(`curve`,r,n)}polygon(e,t){let n=this._o(t),r=[],i=T(e,!0,n);return n.fill&&(n.fillStyle===`solid`?r.push(M([e],n)):r.push(N([e],n))),n.stroke!==Z&&r.push(i),this._d(`polygon`,r,n)}path(e,t){let n=this._o(t),r=[];if(!e)return this._d(`path`,r,n);e=(e||``).replace(/\n/g,` `).replace(/(-\s)/g,`-`).replace(`/(ss)/g`,` `);let i=n.fill&&n.fill!==`transparent`&&n.fill!==Z,a=n.stroke!==Z,o=!!(n.simplification&&n.simplification<1),s=function(e,t,n){let r=b(y(v(e))),i=[],a=[],o=[0,0],s=[],c=()=>{s.length>=4&&a.push(...X(s,t)),s=[]},l=()=>{c(),a.length&&(i.push(a),a=[])};for(let{key:e,data:t}of r)switch(e){case`M`:l(),o=[t[0],t[1]],a.push(o);break;case`L`:c(),a.push([t[0],t[1]]);break;case`C`:if(!s.length){let e=a.length?a[a.length-1]:o;s.push([e[0],e[1]])}s.push([t[0],t[1]]),s.push([t[2],t[3]]),s.push([t[4],t[5]]);break;case`Z`:c(),a.push([o[0],o[1]])}if(l(),!n)return i;let u=[];for(let e of i){let t=ne(e,n);t.length&&u.push(t)}return u}(e,1,o?4-4*(n.simplification||1):(1+n.roughness)/2),c=j(e,n);if(i){if(n.fillStyle===`solid`){if(s.length===1){let t=j(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else r.push(M(s,n))}else r.push(N(s,n))}return a&&(o?s.forEach((e=>{r.push(T(e,!1,n))})):r.push(c)),this._d(`path`,r,n)}opsToPath(e,t){let n=``;for(let r of e.ops){let e=typeof t==`number`&&t>=0?r.data.map((e=>+e.toFixed(t))):r.data;switch(r.op){case`move`:n+=`M${e[0]} ${e[1]} `;break;case`bcurveTo`:n+=`C${e[0]} ${e[1]}, ${e[2]} ${e[3]}, ${e[4]} ${e[5]} `;break;case`lineTo`:n+=`L${e[0]} ${e[1]} `}}return n.trim()}toPaths(e){let t=e.sets||[],n=e.options||this.defaultOptions,r=[];for(let e of t){let t=null;switch(e.type){case`path`:t={d:this.opsToPath(e),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:Z};break;case`fillPath`:t={d:this.opsToPath(e),stroke:Z,strokeWidth:0,fill:n.fill||Z};break;case`fillSketch`:t=this.fillSketch(e,n)}t&&r.push(t)}return r}fillSketch(e,t){let n=t.fillWeight;return n<0&&(n=t.strokeWidth/2),{d:this.opsToPath(e),stroke:t.fill||Z,strokeWidth:n,fill:Z}}_mergedShape(e){return e.filter(((e,t)=>t===0||e.op!==`move`))}},re=class{constructor(e,t){this.canvas=e,this.ctx=this.canvas.getContext(`2d`),this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.ctx,i=e.options.fixedDecimalPlaceDigits;for(let a of t)switch(a.type){case`path`:r.save(),r.strokeStyle=n.stroke===`none`?`transparent`:n.stroke,r.lineWidth=n.strokeWidth,n.strokeLineDash&&r.setLineDash(n.strokeLineDash),n.strokeLineDashOffset&&(r.lineDashOffset=n.strokeLineDashOffset),this._drawToContext(r,a,i),r.restore();break;case`fillPath`:{r.save(),r.fillStyle=n.fill||``;let t=e.shape===`curve`||e.shape===`polygon`||e.shape===`path`?`evenodd`:`nonzero`;this._drawToContext(r,a,i,t),r.restore();break}case`fillSketch`:this.fillSketch(r,a,n)}}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2),e.save(),n.fillLineDash&&e.setLineDash(n.fillLineDash),n.fillLineDashOffset&&(e.lineDashOffset=n.fillLineDashOffset),e.strokeStyle=n.fill||``,e.lineWidth=r,this._drawToContext(e,t,n.fixedDecimalPlaceDigits),e.restore()}_drawToContext(e,t,n,r=`nonzero`){e.beginPath();for(let r of t.ops){let t=typeof n==`number`&&n>=0?r.data.map((e=>+e.toFixed(n))):r.data;switch(r.op){case`move`:e.moveTo(t[0],t[1]);break;case`bcurveTo`:e.bezierCurveTo(t[0],t[1],t[2],t[3],t[4],t[5]);break;case`lineTo`:e.lineTo(t[0],t[1])}}t.type===`fillPath`?e.fill(r):e.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a),a}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a),a}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a),a}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i),i}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n),n}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n),n}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c),c}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n),n}path(e,t){let n=this.gen.path(e,t);return this.draw(n),n}},$=`http://www.w3.org/2000/svg`,ie=class{constructor(e,t){this.svg=e,this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.svg.ownerDocument||window.document,i=r.createElementNS($,`g`),a=e.options.fixedDecimalPlaceDigits;for(let o of t){let t=null;switch(o.type){case`path`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,n.stroke),t.setAttribute(`stroke-width`,n.strokeWidth+``),t.setAttribute(`fill`,`none`),n.strokeLineDash&&t.setAttribute(`stroke-dasharray`,n.strokeLineDash.join(` `).trim()),n.strokeLineDashOffset&&t.setAttribute(`stroke-dashoffset`,`${n.strokeLineDashOffset}`);break;case`fillPath`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,`none`),t.setAttribute(`stroke-width`,`0`),t.setAttribute(`fill`,n.fill||``),e.shape!==`curve`&&e.shape!==`polygon`||t.setAttribute(`fill-rule`,`evenodd`);break;case`fillSketch`:t=this.fillSketch(r,o,n)}t&&i.appendChild(t)}return i}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2);let i=e.createElementNS($,`path`);return i.setAttribute(`d`,this.opsToPath(t,n.fixedDecimalPlaceDigits)),i.setAttribute(`stroke`,n.fill||``),i.setAttribute(`stroke-width`,r+``),i.setAttribute(`fill`,`none`),n.fillLineDash&&i.setAttribute(`stroke-dasharray`,n.fillLineDash.join(` `).trim()),n.fillLineDashOffset&&i.setAttribute(`stroke-dashoffset`,`${n.fillLineDashOffset}`),i}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(e,t){return this.gen.opsToPath(e,t)}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a)}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a)}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a)}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i)}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n)}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n)}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c)}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n)}path(e,t){let n=this.gen.path(e,t);return this.draw(n)}},ae={canvas:(e,t)=>new re(e,t),svg:(e,t)=>new ie(e,t),generator:e=>new Q(e),newSeed:()=>Q.newSeed()};export{ae as t}; \ No newline at end of file diff --git a/www/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js b/www/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js new file mode 100644 index 0000000..c314c67 --- /dev/null +++ b/www/assets/sankeyDiagram-IPEJSGJF-mp_GZ4Tp.js @@ -0,0 +1,40 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,Y as i,a,d as o,q as s,s as c,v as l,w as u,x as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as p}from"./ordinal-BDEzSJ7C.js";function m(e){for(var t=e.length/6|0,n=Array(t),r=0;r=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function _(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function v(e,t){let n=0;if(t===void 0)for(let t of e)(t=+t)&&(n+=t);else{let r=-1;for(let i of e)(i=+t(i,++r,e))&&(n+=i)}return n}function y(e){return e.target.depth}function b(e){return e.depth}function x(e,t){return t-1-e.height}function S(e,t){return e.sourceLinks.length?e.depth:t-1}function C(e){return e.targetLinks.length?e.depth:e.sourceLinks.length?_(e.sourceLinks,y)-1:0}function w(e){return function(){return e}}function T(e,t){return D(e.source,t.source)||e.index-t.index}function E(e,t){return D(e.target,t.target)||e.index-t.index}function D(e,t){return e.y0-t.y0}function O(e){return e.value}function k(e){return e.index}function A(e){return e.nodes}function j(e){return e.links}function M(e,t){let n=e.get(t);if(!n)throw Error(`missing: `+t);return n}function N({nodes:e}){for(let t of e){let e=t.y0,n=e;for(let n of t.sourceLinks)n.y0=e+n.width/2,e+=n.width;for(let e of t.targetLinks)e.y1=n+e.width/2,n+=e.width}}function P(){let e=0,t=0,n=1,r=1,i=24,a=8,o,s=k,c=S,l,u,d=A,f=j,p=6;function m(){let e={nodes:d.apply(null,arguments),links:f.apply(null,arguments)};return h(e),y(e),b(e),x(e),F(e),N(e),e}m.update=function(e){return N(e),e},m.nodeId=function(e){return arguments.length?(s=typeof e==`function`?e:w(e),m):s},m.nodeAlign=function(e){return arguments.length?(c=typeof e==`function`?e:w(e),m):c},m.nodeSort=function(e){return arguments.length?(l=e,m):l},m.nodeWidth=function(e){return arguments.length?(i=+e,m):i},m.nodePadding=function(e){return arguments.length?(a=o=+e,m):a},m.nodes=function(e){return arguments.length?(d=typeof e==`function`?e:w(e),m):d},m.links=function(e){return arguments.length?(f=typeof e==`function`?e:w(e),m):f},m.linkSort=function(e){return arguments.length?(u=e,m):u},m.size=function(i){return arguments.length?(e=t=0,n=+i[0],r=+i[1],m):[n-e,r-t]},m.extent=function(i){return arguments.length?(e=+i[0][0],n=+i[1][0],t=+i[0][1],r=+i[1][1],m):[[e,t],[n,r]]},m.iterations=function(e){return arguments.length?(p=+e,m):p};function h({nodes:e,links:t}){for(let[t,n]of e.entries())n.index=t,n.sourceLinks=[],n.targetLinks=[];let n=new Map(e.map((t,n)=>[s(t,n,e),t]));for(let[e,r]of t.entries()){r.index=e;let{source:t,target:i}=r;typeof t!=`object`&&(t=r.source=M(n,t)),typeof i!=`object`&&(i=r.target=M(n,i)),t.sourceLinks.push(r),i.targetLinks.push(r)}if(u!=null)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(u),n.sort(u)}function y({nodes:e}){for(let t of e)t.value=t.fixedValue===void 0?Math.max(v(t.sourceLinks,O),v(t.targetLinks,O)):t.fixedValue}function b({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.depth=i;for(let{target:t}of e.sourceLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function x({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.height=i;for(let{source:t}of e.targetLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function C({nodes:t}){let r=g(t,e=>e.depth)+1,a=(n-e-i)/(r-1),o=Array(r);for(let n of t){let t=Math.max(0,Math.min(r-1,Math.floor(c.call(null,n,r))));n.layer=t,n.x0=e+t*a,n.x1=n.x0+i,o[t]?o[t].push(n):o[t]=[n]}if(l)for(let e of o)e.sort(l);return o}function P(e){let n=_(e,e=>(r-t-(e.length-1)*o)/v(e,O));for(let i of e){let e=t;for(let t of i){t.y0=e,t.y1=e+t.value*n,e=t.y1+o;for(let e of t.sourceLinks)e.width=e.value*n}e=(r-e+o)/(i.length+1);for(let t=0;te.length)-1)),P(n);for(let e=0;e0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function L(e,t,n){for(let r=e.length-2;r>=0;--r){let i=e[r];for(let e of i){let n=0,r=0;for(let{target:t,value:i}of e.sourceLinks){let a=i*(t.layer-e.layer);n+=W(e,t)*a,r+=a}if(!(r>0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function R(e,n){let i=e.length>>1,a=e[i];B(e,a.y0-o,i-1,n),z(e,a.y1+o,i+1,n),B(e,r,e.length-1,n),z(e,t,0,n)}function z(e,t,n,r){for(;n1e-6&&(i.y0+=a,i.y1+=a),t=i.y1+o}}function B(e,t,n,r){for(;n>=0;--n){let i=e[n],a=(i.y1-t)*r;a>1e-6&&(i.y0-=a,i.y1-=a),t=i.y0-o}}function V({sourceLinks:e,targetLinks:t}){if(u===void 0){for(let{source:{sourceLinks:e}}of t)e.sort(E);for(let{target:{targetLinks:t}}of e)t.sort(T)}}function H(e){if(u===void 0)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(E),n.sort(T)}function U(e,t){let n=e.y0-(e.sourceLinks.length-1)*o/2;for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n+=i+o}for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n-=i}return n}function W(e,t){let n=t.y0-(t.targetLinks.length-1)*o/2;for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n+=i+o}for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n-=i}return n}return m}var F=Math.PI,I=2*F,L=1e-6,R=I-L;function z(){this._x0=this._y0=this._x1=this._y1=null,this._=``}function B(){return new z}z.prototype=B.prototype={constructor:z,moveTo:function(e,t){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+=`Z`)},lineTo:function(e,t){this._+=`L`+(this._x1=+e)+`,`+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+=`Q`+ +e+`,`+ +t+`,`+(this._x1=+n)+`,`+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,i,a){this._+=`C`+ +e+`,`+ +t+`,`+ +n+`,`+ +r+`,`+(this._x1=+i)+`,`+(this._y1=+a)},arcTo:function(e,t,n,r,i){e=+e,t=+t,n=+n,r=+r,i=+i;var a=this._x1,o=this._y1,s=n-e,c=r-t,l=a-e,u=o-t,d=l*l+u*u;if(i<0)throw Error(`negative radius: `+i);if(this._x1===null)this._+=`M`+(this._x1=e)+`,`+(this._y1=t);else if(d>L){if(!(Math.abs(u*s-c*l)>L)||!i)this._+=`L`+(this._x1=e)+`,`+(this._y1=t);else{var f=n-a,p=r-o,m=s*s+c*c,h=f*f+p*p,g=Math.sqrt(m),_=Math.sqrt(d),v=i*Math.tan((F-Math.acos((m+d-h)/(2*g*_)))/2),y=v/_,b=v/g;Math.abs(y-1)>L&&(this._+=`L`+(e+y*l)+`,`+(t+y*u)),this._+=`A`+i+`,`+i+`,0,0,`+ +(u*f>l*p)+`,`+(this._x1=e+b*s)+`,`+(this._y1=t+b*c)}}},arc:function(e,t,n,r,i,a){e=+e,t=+t,n=+n,a=!!a;var o=n*Math.cos(r),s=n*Math.sin(r),c=e+o,l=t+s,u=1^a,d=a?r-i:i-r;if(n<0)throw Error(`negative radius: `+n);this._x1===null?this._+=`M`+c+`,`+l:(Math.abs(this._x1-c)>L||Math.abs(this._y1-l)>L)&&(this._+=`L`+c+`,`+l),n&&(d<0&&(d=d%I+I),d>R?this._+=`A`+n+`,`+n+`,0,1,`+u+`,`+(e-o)+`,`+(t-s)+`A`+n+`,`+n+`,0,1,`+u+`,`+(this._x1=c)+`,`+(this._y1=l):d>L&&(this._+=`A`+n+`,`+n+`,0,`+ +(d>=F)+`,`+u+`,`+(this._x1=e+n*Math.cos(i))+`,`+(this._y1=t+n*Math.sin(i))))},rect:function(e,t,n,r){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)+`h`+ +n+`v`+ +r+`h`+-n+`Z`},toString:function(){return this._}};function V(e){return function(){return e}}function H(e){return e[0]}function U(e){return e[1]}var W=Array.prototype.slice;function G(e){return e.source}function ee(e){return e.target}function te(e){var t=G,n=ee,r=H,i=U,a=null;function o(){var o,s=W.call(arguments),c=t.apply(this,s),l=n.apply(this,s);if(a||=o=B(),e(a,+r.apply(this,(s[0]=c,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),o)return a=null,o+``||null}return o.source=function(e){return arguments.length?(t=e,o):t},o.target=function(e){return arguments.length?(n=e,o):n},o.x=function(e){return arguments.length?(r=typeof e==`function`?e:V(+e),o):r},o.y=function(e){return arguments.length?(i=typeof e==`function`?e:V(+e),o):i},o.context=function(e){return arguments.length?(a=e??null,o):a},o}function ne(e,t,n,r,i){e.moveTo(t,n),e.bezierCurveTo(t=(t+r)/2,n,t,i,r,i)}function re(){return te(ne)}function ie(e){return[e.source.x1,e.y0]}function ae(e){return[e.target.x0,e.y1]}function K(){return re().source(ie).target(ae)}var q=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,9],r=[1,10],i=[1,5,10,12],a={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SANKEY:4,NEWLINE:5,csv:6,opt_eof:7,record:8,csv_tail:9,EOF:10,"field[source]":11,COMMA:12,"field[target]":13,"field[value]":14,field:15,escaped:16,non_escaped:17,DQUOTE:18,ESCAPED_TEXT:19,NON_ESCAPED_TEXT:20,$accept:0,$end:1},terminals_:{2:`error`,4:`SANKEY`,5:`NEWLINE`,10:`EOF`,11:`field[source]`,12:`COMMA`,13:`field[target]`,14:`field[value]`,18:`DQUOTE`,19:`ESCAPED_TEXT`,20:`NON_ESCAPED_TEXT`},productions_:[0,[3,4],[6,2],[9,2],[9,0],[7,1],[7,0],[8,5],[15,1],[15,1],[16,3],[17,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 7:let e=r.findOrCreateNode(a[s-4].trim().replaceAll(`""`,`"`)),t=r.findOrCreateNode(a[s-2].trim().replaceAll(`""`,`"`)),n=parseFloat(a[s].trim());r.addLink(e,t,n);break;case 8:case 9:case 11:this.$=a[s];break;case 10:this.$=a[s-1]}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3]},{6:4,8:5,15:6,16:7,17:8,18:n,20:r},{1:[2,6],7:11,10:[1,12]},e(r,[2,4],{9:13,5:[1,14]}),{12:[1,15]},e(i,[2,8]),e(i,[2,9]),{19:[1,16]},e(i,[2,11]),{1:[2,1]},{1:[2,5]},e(r,[2,2]),{6:17,8:5,15:6,16:7,17:8,18:n,20:r},{15:18,16:7,17:8,18:n,20:r},{18:[1,19]},e(r,[2,3]),{12:[1,20]},e(i,[2,10]),{15:21,16:7,17:8,18:n,20:r},e([1,5,10],[2,7])],defaultActions:{11:[2,1],12:[2,5]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};a.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return this.pushState(`csv`),4;case 1:return this.pushState(`csv`),4;case 2:return 10;case 3:return 5;case 4:return 12;case 5:return this.pushState(`escaped_text`),18;case 6:return 20;case 7:return this.popState(`escaped_text`),18;case 8:return 19}},`anonymous`),rules:[/^(?:sankey-beta\b)/i,/^(?:sankey\b)/i,/^(?:$)/i,/^(?:((\u000D\u000A)|(\u000A)))/i,/^(?:(\u002C))/i,/^(?:(\u0022))/i,/^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,/^(?:(\u0022)(?!(\u0022)))/i,/^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i],conditions:{csv:{rules:[2,3,4,5,6,7,8],inclusive:!1},escaped_text:{rules:[7,8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8],inclusive:!0}}}})();function o(){this.yy={}}return t(o,`Parser`),o.prototype=a,a.Parser=o,new o})();q.parser=q;var J=q,Y=[],X=[],Z=new Map,oe=t(()=>{Y=[],X=[],Z=new Map,a()},`clear`),se=class{constructor(e,t,n=0){this.source=e,this.target=t,this.value=n}static{t(this,`SankeyLink`)}},ce=t((e,t,n)=>{Y.push(new se(e,t,n))},`addLink`),le=class{constructor(e){this.ID=e}static{t(this,`SankeyNode`)}},ue={nodesMap:Z,getConfig:t(()=>d().sankey,`getConfig`),getNodes:t(()=>X,`getNodes`),getLinks:t(()=>Y,`getLinks`),getGraph:t(()=>({nodes:X.map(e=>({id:e.ID})),links:Y.map(e=>({source:e.source.ID,target:e.target.ID,value:e.value}))}),`getGraph`),addLink:ce,findOrCreateNode:t(e=>{e=c.sanitizeText(e,d());let t=Z.get(e);return t===void 0&&(t=new le(e),Z.set(e,t),X.push(t)),t},`findOrCreateNode`),getAccTitle:f,setAccTitle:r,getAccDescription:l,setAccDescription:n,getDiagramTitle:u,setDiagramTitle:s,clear:oe},Q=class e{static{t(this,`Uid`)}static{this.count=0}static next(t){return new e(t+ ++e.count)}constructor(e){this.id=e,this.href=`#${e}`}toString(){return`url(`+this.href+`)`}},$={left:b,right:x,center:C,justify:S},de=t(e=>{let t=0,n=0;for(let r of e){let e=r.value??0;e>t&&(t=e,n=r.layer??0)}return n},`findCentralNodeLayer`),fe={draw:t(function(n,r,a,s){let{securityLevel:c,sankey:l}=d(),u=o.sankey,f;c===`sandbox`&&(f=e(`#i`+r));let m=e(c===`sandbox`?f.nodes()[0].contentDocument.body:`body`),g=c===`sandbox`?m.select(`[id="${r}"]`):e(`[id="${r}"]`),_=l?.width??u.width,v=l?.height??u.width,y=l?.useMaxWidth??u.useMaxWidth,b=l?.nodeAlignment??u.nodeAlignment,x=l?.prefix??u.prefix,S=l?.suffix??u.suffix,C=l?.showValues??u.showValues,w=l?.nodeWidth??u.nodeWidth??10,T=l?.nodePadding??u.nodePadding??12,E=l?.labelStyle??u.labelStyle??`legacy`,D=l?.nodeColors??{},O=s.db.getGraph(),k=$[b];P().nodeId(e=>e.id).nodeWidth(w).nodePadding(T+(C?15:0)).nodeAlign(k).extent([[0,0],[_,v]])(O);let A=de(O.nodes),j=p(h),M=t(e=>D[e]??j(e),`getNodeColor`);g.append(`g`).attr(`class`,`nodes`).selectAll(`.node`).data(O.nodes).join(`g`).attr(`class`,`node`).attr(`id`,e=>(e.uid=Q.next(`node-`)).id).attr(`transform`,function(e){return`translate(`+e.x0+`,`+e.y0+`)`}).attr(`x`,e=>e.x0).attr(`y`,e=>e.y0).append(`rect`).attr(`height`,e=>e.y1-e.y0).attr(`width`,e=>e.x1-e.x0).attr(`fill`,e=>M(e.id));let N=t(({id:e,value:t})=>C?`${e} +${x}${Math.round(t*100)/100}${S}`:e,`getText`),F=t(e=>E===`outlined`?(e.layer??0)I.selectAll(e?`.${e}`:`text`).data(O.nodes).join(`text`).attr(`class`,e??null).attr(`x`,e=>F(e).x).attr(`y`,e=>(e.y1+e.y0)/2).attr(`dy`,`${C?`0`:`0.35`}em`).attr(`text-anchor`,e=>F(e).anchor).text(N),`appendLabel`);E===`outlined`?(L(`sankey-label-bg`),L(`sankey-label-fg`)):L();let R=g.append(`g`).attr(`class`,`links`).attr(`fill`,`none`).attr(`stroke-opacity`,.5).selectAll(`.link`).data(O.links).join(`g`).attr(`class`,`link`).style(`mix-blend-mode`,`multiply`),z=l?.linkColor??`gradient`;if(z===`gradient`){let e=R.append(`linearGradient`).attr(`id`,e=>(e.uid=Q.next(`linearGradient-`)).id).attr(`gradientUnits`,`userSpaceOnUse`).attr(`x1`,e=>e.source.x1).attr(`x2`,e=>e.target.x0);e.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,e=>M(e.source.id)),e.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,e=>M(e.target.id))}let B;switch(z){case`gradient`:B=t(e=>e.uid,`coloring`);break;case`source`:B=t(e=>M(e.source.id),`coloring`);break;case`target`:B=t(e=>M(e.target.id),`coloring`);break;default:B=z}R.append(`path`).attr(`d`,K()).attr(`stroke`,B).attr(`stroke-width`,e=>Math.max(1,e.width)),i(void 0,g,0,y)},`draw`)},pe=t(e=>e.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g,``).replaceAll(/([\n\r])+/g,` +`).trim(),`prepareTextForParsing`),me=t(e=>`.label { + font-family: ${e.fontFamily}; + } + + .node-labels { + font-family: ${e.fontFamily}; + } + + /* Outlined label style - background stroke for better readability */ + .sankey-label-bg { + stroke: ${e.mainBkg||e.background||`#fff`}; + stroke-width: 4px; + stroke-linejoin: round; + paint-order: stroke; + } + + /* Foreground label text */ + .sankey-label-fg { + fill: ${e.textColor}; + } + + /* Node styling */ + .node rect { + shape-rendering: crispEdges; + } + + /* Link styling */ + .link { + fill: none; + stroke-opacity: 0.5; + mix-blend-mode: multiply; + } +`,`getStyles`),he=J.parse.bind(J);J.parse=e=>he(pe(e));var ge={styles:me,parser:J,db:ue,renderer:fe};export{ge as diagram}; \ No newline at end of file diff --git a/www/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js b/www/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js new file mode 100644 index 0000000..acae799 --- /dev/null +++ b/www/assets/sequenceDiagram-PO4LG4MO-BKPSlgwc.js @@ -0,0 +1,169 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{A as r,F as i,G as a,H as o,O as s,U as c,a as l,b as u,c as d,i as f,q as p,r as m,s as h,v as g,w as _,x as v,y,z as b}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as x}from"./dist-Bfr8PhAA.js";import{g as S,p as C}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{_ as w,v as T}from"./index-DoQkmpth.js";import{a as E,c as D,i as O,n as k,r as A,s as j}from"./chunk-GWA4HPMP-C1P4FmAY.js";import{t as M}from"./chunk-2Q5K7J3B-C1jixKkw.js";var N=x(),P=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[1,2],r=[1,3],i=[1,4],a=[2,4],o=[1,9],s=[1,11],c=[1,12],l=[1,14],u=[1,15],d=[1,17],f=[1,18],p=[1,19],m=[1,25],h=[1,26],g=[1,27],_=[1,28],v=[1,29],y=[1,30],b=[1,31],x=[1,32],S=[1,33],C=[1,34],w=[1,35],T=[1,36],E=[1,37],D=[1,38],O=[1,39],k=[1,40],A=[1,42],j=[1,43],M=[1,44],N=[1,45],P=[1,46],F=[1,47],I=[1,4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,48,49,50,51,53,54,56,61,62,63,64,73],ee=[1,74],te=[1,80],L=[1,81],ne=[1,82],re=[1,83],ie=[1,84],ae=[1,85],oe=[1,86],se=[1,87],ce=[1,88],le=[1,89],ue=[1,90],R=[1,91],de=[1,92],fe=[1,93],pe=[1,94],me=[1,95],z=[1,96],B=[1,97],he=[1,98],V=[1,99],H=[1,100],U=[1,101],ge=[1,102],_e=[1,103],ve=[1,104],ye=[1,105],W=[2,78],be=[4,5,17,51,53,54],G=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,51,53,54,56,61,62,63,64,73],xe=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,50,51,53,54,56,61,62,63,64,73],Se=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,49,51,53,54,56,61,62,63,64,73],Ce=[4,5,10,14,15,17,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,48,51,53,54,56,61,62,63,64,73],we=[5,52],K=[70,71,72,73],q=[1,151],Te={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SPACE:4,NEWLINE:5,SD:6,document:7,line:8,statement:9,INVALID:10,box_section:11,box_line:12,participant_statement:13,create:14,box:15,restOfLine:16,end:17,signal:18,autonumber:19,NUM:20,off:21,activate:22,actor:23,deactivate:24,note_statement:25,links_statement:26,link_statement:27,properties_statement:28,details_statement:29,title:30,legacy_title:31,acc_title:32,acc_title_value:33,acc_descr:34,acc_descr_value:35,acc_descr_multiline_value:36,loop:37,rect:38,opt:39,alt:40,else_sections:41,par:42,par_sections:43,par_over:44,critical:45,option_sections:46,break:47,option:48,and:49,else:50,participant:51,AS:52,participant_actor:53,destroy:54,actor_with_config:55,note:56,placement:57,text2:58,over:59,actor_pair:60,links:61,link:62,properties:63,details:64,spaceList:65,",":66,left_of:67,right_of:68,signaltype:69,"+":70,"-":71,"()":72,ACTOR:73,config_object:74,CONFIG_START:75,CONFIG_CONTENT:76,CONFIG_END:77,SOLID_OPEN_ARROW:78,DOTTED_OPEN_ARROW:79,SOLID_ARROW:80,SOLID_ARROW_TOP:81,SOLID_ARROW_BOTTOM:82,STICK_ARROW_TOP:83,STICK_ARROW_BOTTOM:84,SOLID_ARROW_TOP_DOTTED:85,SOLID_ARROW_BOTTOM_DOTTED:86,STICK_ARROW_TOP_DOTTED:87,STICK_ARROW_BOTTOM_DOTTED:88,SOLID_ARROW_TOP_REVERSE:89,SOLID_ARROW_BOTTOM_REVERSE:90,STICK_ARROW_TOP_REVERSE:91,STICK_ARROW_BOTTOM_REVERSE:92,SOLID_ARROW_TOP_REVERSE_DOTTED:93,SOLID_ARROW_BOTTOM_REVERSE_DOTTED:94,STICK_ARROW_TOP_REVERSE_DOTTED:95,STICK_ARROW_BOTTOM_REVERSE_DOTTED:96,BIDIRECTIONAL_SOLID_ARROW:97,DOTTED_ARROW:98,BIDIRECTIONAL_DOTTED_ARROW:99,SOLID_CROSS:100,DOTTED_CROSS:101,SOLID_POINT:102,DOTTED_POINT:103,TXT:104,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACE`,5:`NEWLINE`,6:`SD`,10:`INVALID`,14:`create`,15:`box`,16:`restOfLine`,17:`end`,19:`autonumber`,20:`NUM`,21:`off`,22:`activate`,24:`deactivate`,30:`title`,31:`legacy_title`,32:`acc_title`,33:`acc_title_value`,34:`acc_descr`,35:`acc_descr_value`,36:`acc_descr_multiline_value`,37:`loop`,38:`rect`,39:`opt`,40:`alt`,42:`par`,44:`par_over`,45:`critical`,47:`break`,48:`option`,49:`and`,50:`else`,51:`participant`,52:`AS`,53:`participant_actor`,54:`destroy`,56:`note`,59:`over`,61:`links`,62:`link`,63:`properties`,64:`details`,66:`,`,67:`left_of`,68:`right_of`,70:`+`,71:`-`,72:`()`,73:`ACTOR`,75:`CONFIG_START`,76:`CONFIG_CONTENT`,77:`CONFIG_END`,78:`SOLID_OPEN_ARROW`,79:`DOTTED_OPEN_ARROW`,80:`SOLID_ARROW`,81:`SOLID_ARROW_TOP`,82:`SOLID_ARROW_BOTTOM`,83:`STICK_ARROW_TOP`,84:`STICK_ARROW_BOTTOM`,85:`SOLID_ARROW_TOP_DOTTED`,86:`SOLID_ARROW_BOTTOM_DOTTED`,87:`STICK_ARROW_TOP_DOTTED`,88:`STICK_ARROW_BOTTOM_DOTTED`,89:`SOLID_ARROW_TOP_REVERSE`,90:`SOLID_ARROW_BOTTOM_REVERSE`,91:`STICK_ARROW_TOP_REVERSE`,92:`STICK_ARROW_BOTTOM_REVERSE`,93:`SOLID_ARROW_TOP_REVERSE_DOTTED`,94:`SOLID_ARROW_BOTTOM_REVERSE_DOTTED`,95:`STICK_ARROW_TOP_REVERSE_DOTTED`,96:`STICK_ARROW_BOTTOM_REVERSE_DOTTED`,97:`BIDIRECTIONAL_SOLID_ARROW`,98:`DOTTED_ARROW`,99:`BIDIRECTIONAL_DOTTED_ARROW`,100:`SOLID_CROSS`,101:`DOTTED_CROSS`,102:`SOLID_POINT`,103:`DOTTED_POINT`,104:`TXT`},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[8,1],[11,0],[11,2],[12,2],[12,1],[12,1],[9,1],[9,2],[9,4],[9,2],[9,4],[9,3],[9,3],[9,2],[9,3],[9,3],[9,2],[9,2],[9,2],[9,2],[9,2],[9,1],[9,1],[9,2],[9,2],[9,1],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[46,1],[46,4],[43,1],[43,4],[41,1],[41,4],[13,5],[13,3],[13,5],[13,3],[13,3],[13,5],[13,3],[13,5],[13,3],[25,4],[25,4],[26,3],[27,3],[28,3],[29,3],[65,2],[65,1],[60,3],[60,1],[57,1],[57,1],[18,5],[18,5],[18,5],[18,5],[18,6],[18,4],[55,2],[74,3],[23,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[69,1],[58,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:return r.apply(a[s]),a[s];case 4:case 10:this.$=[];break;case 5:case 11:a[s-1].push(a[s]),this.$=a[s-1];break;case 6:case 7:case 12:case 13:this.$=a[s];break;case 8:case 9:case 14:this.$=[];break;case 16:a[s].type=`createParticipant`,this.$=a[s];break;case 17:a[s-1].unshift({type:`boxStart`,boxData:r.parseBoxData(a[s-2])}),a[s-1].push({type:`boxEnd`,boxText:a[s-2]}),this.$=a[s-1];break;case 19:this.$={type:`sequenceIndex`,sequenceIndex:Number(a[s-2]),sequenceIndexStep:Number(a[s-1]),sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 20:this.$={type:`sequenceIndex`,sequenceIndex:Number(a[s-1]),sequenceIndexStep:1,sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 21:this.$={type:`sequenceIndex`,sequenceVisible:!1,signalType:r.LINETYPE.AUTONUMBER};break;case 22:this.$={type:`sequenceIndex`,sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 23:this.$={type:`activeStart`,signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1].actor};break;case 24:this.$={type:`activeEnd`,signalType:r.LINETYPE.ACTIVE_END,actor:a[s-1].actor};break;case 30:r.setDiagramTitle(a[s].substring(6)),this.$=a[s].substring(6);break;case 31:r.setDiagramTitle(a[s].substring(7)),this.$=a[s].substring(7);break;case 32:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 33:case 34:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 35:a[s-1].unshift({type:`loopStart`,loopText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.LOOP_START}),a[s-1].push({type:`loopEnd`,loopText:a[s-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[s-1];break;case 36:a[s-1].unshift({type:`rectStart`,color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_START}),a[s-1].push({type:`rectEnd`,color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_END}),this.$=a[s-1];break;case 37:a[s-1].unshift({type:`optStart`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_START}),a[s-1].push({type:`optEnd`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_END}),this.$=a[s-1];break;case 38:a[s-1].unshift({type:`altStart`,altText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.ALT_START}),a[s-1].push({type:`altEnd`,signalType:r.LINETYPE.ALT_END}),this.$=a[s-1];break;case 39:a[s-1].unshift({type:`parStart`,parText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.PAR_START}),a[s-1].push({type:`parEnd`,signalType:r.LINETYPE.PAR_END}),this.$=a[s-1];break;case 40:a[s-1].unshift({type:`parStart`,parText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.PAR_OVER_START}),a[s-1].push({type:`parEnd`,signalType:r.LINETYPE.PAR_END}),this.$=a[s-1];break;case 41:a[s-1].unshift({type:`criticalStart`,criticalText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.CRITICAL_START}),a[s-1].push({type:`criticalEnd`,signalType:r.LINETYPE.CRITICAL_END}),this.$=a[s-1];break;case 42:a[s-1].unshift({type:`breakStart`,breakText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.BREAK_START}),a[s-1].push({type:`breakEnd`,optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.BREAK_END}),this.$=a[s-1];break;case 44:this.$=a[s-3].concat([{type:`option`,optionText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.CRITICAL_OPTION},a[s]]);break;case 46:this.$=a[s-3].concat([{type:`and`,parText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.PAR_AND},a[s]]);break;case 48:this.$=a[s-3].concat([{type:`else`,altText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.ALT_ELSE},a[s]]);break;case 49:a[s-3].draw=`participant`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 50:a[s-1].draw=`participant`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 51:a[s-3].draw=`actor`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 52:case 57:a[s-1].draw=`actor`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 53:a[s-1].type=`destroyParticipant`,this.$=a[s-1];break;case 54:a[s-3].draw=`participant`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 55:a[s-1].draw=`participant`,a[s-1].type=`addParticipant`,this.$=a[s-1];break;case 56:a[s-3].draw=`actor`,a[s-3].type=`addParticipant`,a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 58:this.$=[a[s-1],{type:`addNote`,placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 59:a[s-2]=[].concat(a[s-1],a[s-1]).slice(0,2),a[s-2][0]=a[s-2][0].actor,a[s-2][1]=a[s-2][1].actor,this.$=[a[s-1],{type:`addNote`,placement:r.PLACEMENT.OVER,actor:a[s-2].slice(0,2),text:a[s]}];break;case 60:this.$=[a[s-1],{type:`addLinks`,actor:a[s-1].actor,text:a[s]}];break;case 61:this.$=[a[s-1],{type:`addALink`,actor:a[s-1].actor,text:a[s]}];break;case 62:this.$=[a[s-1],{type:`addProperties`,actor:a[s-1].actor,text:a[s]}];break;case 63:this.$=[a[s-1],{type:`addDetails`,actor:a[s-1].actor,text:a[s]}];break;case 66:this.$=[a[s-2],a[s]];break;case 67:this.$=a[s];break;case 68:this.$=r.PLACEMENT.LEFTOF;break;case 69:this.$=r.PLACEMENT.RIGHTOF;break;case 70:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0},{type:`activeStart`,signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1].actor}];break;case 71:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s]},{type:`activeEnd`,signalType:r.LINETYPE.ACTIVE_END,actor:a[s-4].actor}];break;case 72:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0,centralConnection:r.LINETYPE.CENTRAL_CONNECTION},{type:`centralConnection`,signalType:r.LINETYPE.CENTRAL_CONNECTION,actor:a[s-1].actor}];break;case 73:this.$=[a[s-4],a[s-1],{type:`addMessage`,from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-2],msg:a[s],activate:!1,centralConnection:r.LINETYPE.CENTRAL_CONNECTION_REVERSE},{type:`centralConnectionReverse`,signalType:r.LINETYPE.CENTRAL_CONNECTION_REVERSE,actor:a[s-4].actor}];break;case 74:this.$=[a[s-5],a[s-1],{type:`addMessage`,from:a[s-5].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s],activate:!0,centralConnection:r.LINETYPE.CENTRAL_CONNECTION_DUAL},{type:`centralConnection`,signalType:r.LINETYPE.CENTRAL_CONNECTION,actor:a[s-1].actor},{type:`centralConnectionReverse`,signalType:r.LINETYPE.CENTRAL_CONNECTION_REVERSE,actor:a[s-5].actor}];break;case 75:this.$=[a[s-3],a[s-1],{type:`addMessage`,from:a[s-3].actor,to:a[s-1].actor,signalType:a[s-2],msg:a[s]}];break;case 76:this.$={type:`addParticipant`,actor:a[s-1],config:a[s]};break;case 77:this.$=a[s-1].trim();break;case 78:this.$={type:`addParticipant`,actor:a[s]};break;case 79:this.$=r.LINETYPE.SOLID_OPEN;break;case 80:this.$=r.LINETYPE.DOTTED_OPEN;break;case 81:this.$=r.LINETYPE.SOLID;break;case 82:this.$=r.LINETYPE.SOLID_TOP;break;case 83:this.$=r.LINETYPE.SOLID_BOTTOM;break;case 84:this.$=r.LINETYPE.STICK_TOP;break;case 85:this.$=r.LINETYPE.STICK_BOTTOM;break;case 86:this.$=r.LINETYPE.SOLID_TOP_DOTTED;break;case 87:this.$=r.LINETYPE.SOLID_BOTTOM_DOTTED;break;case 88:this.$=r.LINETYPE.STICK_TOP_DOTTED;break;case 89:this.$=r.LINETYPE.STICK_BOTTOM_DOTTED;break;case 90:this.$=r.LINETYPE.SOLID_ARROW_TOP_REVERSE;break;case 91:this.$=r.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE;break;case 92:this.$=r.LINETYPE.STICK_ARROW_TOP_REVERSE;break;case 93:this.$=r.LINETYPE.STICK_ARROW_BOTTOM_REVERSE;break;case 94:this.$=r.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED;break;case 95:this.$=r.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED;break;case 96:this.$=r.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED;break;case 97:this.$=r.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED;break;case 98:this.$=r.LINETYPE.BIDIRECTIONAL_SOLID;break;case 99:this.$=r.LINETYPE.DOTTED;break;case 100:this.$=r.LINETYPE.BIDIRECTIONAL_DOTTED;break;case 101:this.$=r.LINETYPE.SOLID_CROSS;break;case 102:this.$=r.LINETYPE.DOTTED_CROSS;break;case 103:this.$=r.LINETYPE.SOLID_POINT;break;case 104:this.$=r.LINETYPE.DOTTED_POINT;break;case 105:this.$=r.parseMessage(a[s].trim().substring(1))}},`anonymous`),table:[{3:1,4:t,5:r,6:i},{1:[3]},{3:5,4:t,5:r,6:i},{3:6,4:t,5:r,6:i},e([1,4,5,10,14,15,19,22,24,30,31,32,34,36,37,38,39,40,42,44,45,47,51,53,54,56,61,62,63,64,73],a,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},e(I,[2,5]),{9:48,13:13,14:l,15:u,18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},e(I,[2,7]),e(I,[2,8]),e(I,[2,9]),e(I,[2,15]),{13:49,51:D,53:O,54:k},{16:[1,50]},{5:[1,51]},{5:[1,54],20:[1,52],21:[1,53]},{23:55,73:F},{23:56,73:F},{5:[1,57]},{5:[1,58]},{5:[1,59]},{5:[1,60]},{5:[1,61]},e(I,[2,30]),e(I,[2,31]),{33:[1,62]},{35:[1,63]},e(I,[2,34]),{16:[1,64]},{16:[1,65]},{16:[1,66]},{16:[1,67]},{16:[1,68]},{16:[1,69]},{16:[1,70]},{16:[1,71]},{23:72,55:73,73:ee},{23:75,55:76,73:ee},{23:77,73:F},{69:78,72:[1,79],78:te,79:L,80:ne,81:re,82:ie,83:ae,84:oe,85:se,86:ce,87:le,88:ue,89:R,90:de,91:fe,92:pe,93:me,94:z,95:B,96:he,97:V,98:H,99:U,100:ge,101:_e,102:ve,103:ye},{57:106,59:[1,107],67:[1,108],68:[1,109]},{23:110,73:F},{23:111,73:F},{23:112,73:F},{23:113,73:F},e([5,66,72,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104],W),e(I,[2,6]),e(I,[2,16]),e(be,[2,10],{11:114}),e(I,[2,18]),{5:[1,116],20:[1,115]},{5:[1,117]},e(I,[2,22]),{5:[1,118]},{5:[1,119]},e(I,[2,25]),e(I,[2,26]),e(I,[2,27]),e(I,[2,28]),e(I,[2,29]),e(I,[2,32]),e(I,[2,33]),e(G,a,{7:120}),e(G,a,{7:121}),e(G,a,{7:122}),e(xe,a,{41:123,7:124}),e(Se,a,{43:125,7:126}),e(Se,a,{7:126,43:127}),e(Ce,a,{46:128,7:129}),e(G,a,{7:130}),{5:[1,132],52:[1,131]},{5:[1,134],52:[1,133]},e(we,W,{74:135,75:[1,136]}),{5:[1,138],52:[1,137]},{5:[1,140],52:[1,139]},{5:[1,141]},{23:145,70:[1,142],71:[1,143],72:[1,144],73:F},{69:146,78:te,79:L,80:ne,81:re,82:ie,83:ae,84:oe,85:se,86:ce,87:le,88:ue,89:R,90:de,91:fe,92:pe,93:me,94:z,95:B,96:he,97:V,98:H,99:U,100:ge,101:_e,102:ve,103:ye},e(K,[2,79]),e(K,[2,80]),e(K,[2,81]),e(K,[2,82]),e(K,[2,83]),e(K,[2,84]),e(K,[2,85]),e(K,[2,86]),e(K,[2,87]),e(K,[2,88]),e(K,[2,89]),e(K,[2,90]),e(K,[2,91]),e(K,[2,92]),e(K,[2,93]),e(K,[2,94]),e(K,[2,95]),e(K,[2,96]),e(K,[2,97]),e(K,[2,98]),e(K,[2,99]),e(K,[2,100]),e(K,[2,101]),e(K,[2,102]),e(K,[2,103]),e(K,[2,104]),{23:147,73:F},{23:149,60:148,73:F},{73:[2,68]},{73:[2,69]},{58:150,104:q},{58:152,104:q},{58:153,104:q},{58:154,104:q},{4:[1,157],5:[1,159],12:156,13:158,17:[1,155],51:D,53:O,54:k},{5:[1,160]},e(I,[2,20]),e(I,[2,21]),e(I,[2,23]),e(I,[2,24]),{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,161],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,162],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,163],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,164]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,47],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,50:[1,165],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,166]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,45],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,49:[1,167],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{17:[1,168]},{17:[1,169]},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[2,43],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,48:[1,170],51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{4:o,5:s,8:8,9:10,10:c,13:13,14:l,15:u,17:[1,171],18:16,19:d,22:f,23:41,24:p,25:20,26:21,27:22,28:23,29:24,30:m,31:h,32:g,34:_,36:v,37:y,38:b,39:x,40:S,42:C,44:w,45:T,47:E,51:D,53:O,54:k,56:A,61:j,62:M,63:N,64:P,73:F},{16:[1,172]},e(I,[2,50]),{16:[1,173]},e(I,[2,55]),e(we,[2,76]),{76:[1,174]},{16:[1,175]},e(I,[2,52]),{16:[1,176]},e(I,[2,57]),e(I,[2,53]),{23:177,73:F},{23:178,73:F},{23:179,73:F},{58:180,104:q},{23:181,72:[1,182],73:F},{58:183,104:q},{58:184,104:q},{66:[1,185],104:[2,67]},{5:[2,60]},{5:[2,105]},{5:[2,61]},{5:[2,62]},{5:[2,63]},e(I,[2,17]),e(be,[2,11]),{13:186,51:D,53:O,54:k},e(be,[2,13]),e(be,[2,14]),e(I,[2,19]),e(I,[2,35]),e(I,[2,36]),e(I,[2,37]),e(I,[2,38]),{16:[1,187]},e(I,[2,39]),{16:[1,188]},e(I,[2,40]),e(I,[2,41]),{16:[1,189]},e(I,[2,42]),{5:[1,190]},{5:[1,191]},{77:[1,192]},{5:[1,193]},{5:[1,194]},{58:195,104:q},{58:196,104:q},{58:197,104:q},{5:[2,75]},{58:198,104:q},{23:199,73:F},{5:[2,58]},{5:[2,59]},{23:200,73:F},e(be,[2,12]),e(xe,a,{7:124,41:201}),e(Se,a,{7:126,43:202}),e(Ce,a,{7:129,46:203}),e(I,[2,49]),e(I,[2,54]),e(we,[2,77]),e(I,[2,51]),e(I,[2,56]),{5:[2,70]},{5:[2,71]},{5:[2,72]},{5:[2,73]},{58:204,104:q},{104:[2,66]},{17:[2,48]},{17:[2,46]},{17:[2,44]},{5:[2,74]}],defaultActions:{5:[2,1],6:[2,2],108:[2,68],109:[2,69],150:[2,60],151:[2,105],152:[2,61],153:[2,62],154:[2,63],180:[2,75],183:[2,58],184:[2,59],195:[2,70],196:[2,71],197:[2,72],198:[2,73],200:[2,66],201:[2,48],202:[2,46],203:[2,44],204:[2,74]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};Te.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:return 5;case 1:break;case 2:break;case 3:break;case 4:break;case 5:break;case 6:return 20;case 7:return this.begin(`CONFIG`),75;case 8:return 76;case 9:return this.popState(),this.begin(`ALIAS`),77;case 10:return this.popState(),this.popState(),77;case 11:return t.yytext=t.yytext.trim(),73;case 12:return t.yytext=t.yytext.trim(),this.begin(`ALIAS`),73;case 13:return t.yytext=t.yytext.trim(),this.popState(),73;case 14:return this.popState(),10;case 15:return t.yytext=t.yytext.trim(),this.popState(),10;case 16:return this.begin(`LINE`),15;case 17:return this.begin(`ID`),51;case 18:return this.begin(`ID`),53;case 19:return 14;case 20:return this.begin(`ID`),54;case 21:return this.popState(),this.popState(),this.begin(`LINE`),52;case 22:return this.popState(),this.popState(),5;case 23:return this.begin(`LINE`),37;case 24:return this.begin(`LINE`),38;case 25:return this.begin(`LINE`),39;case 26:return this.begin(`LINE`),40;case 27:return this.begin(`LINE`),50;case 28:return this.begin(`LINE`),42;case 29:return this.begin(`LINE`),44;case 30:return this.begin(`LINE`),49;case 31:return this.begin(`LINE`),45;case 32:return this.begin(`LINE`),48;case 33:return this.begin(`LINE`),47;case 34:return this.popState(),16;case 35:return 17;case 36:return 67;case 37:return 68;case 38:return 61;case 39:return 62;case 40:return 63;case 41:return 64;case 42:return 59;case 43:return 56;case 44:return this.begin(`ID`),22;case 45:return this.begin(`ID`),24;case 46:return 30;case 47:return 31;case 48:return this.begin(`acc_title`),32;case 49:return this.popState(),`acc_title_value`;case 50:return this.begin(`acc_descr`),34;case 51:return this.popState(),`acc_descr_value`;case 52:this.begin(`acc_descr_multiline`);break;case 53:this.popState();break;case 54:return`acc_descr_multiline_value`;case 55:return 6;case 56:return 19;case 57:return 21;case 58:return 66;case 59:return 5;case 60:return t.yytext=t.yytext.trim(),73;case 61:return 80;case 62:return 97;case 63:return 98;case 64:return 99;case 65:return 78;case 66:return 79;case 67:return 100;case 68:return 101;case 69:return 102;case 70:return 103;case 71:return 85;case 72:return 86;case 73:return 87;case 74:return 88;case 75:return 93;case 76:return 94;case 77:return 95;case 78:return 96;case 79:return 81;case 80:return 82;case 81:return 83;case 82:return 84;case 83:return 89;case 84:return 90;case 85:return 91;case 86:return 92;case 87:return 104;case 88:return 104;case 89:return 70;case 90:return 71;case 91:return 72;case 92:return 5;case 93:return 10}},`anonymous`),rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:([0-9]+(\.[0-9]{1,2})?|\.[0-9]{1,2})(?=[ \n]+))/i,/^(?:@\{)/i,/^(?:[^\}]+)/i,/^(?:\}(?=\s+as\s))/i,/^(?:\})/i,/^(?:[^\<->\->:\n,;@\s]+(?=@\{))/i,/^(?:[^<>:\n,;@\s]+(?=\s+as\s))/i,/^(?:[^<>:\n,;@]+(?=\s*[\n;#]|$))/i,/^(?:[^<>:\n,;@]*<[^\n]*)/i,/^(?:[^\n]+)/i,/^(?:box\b)/i,/^(?:participant\b)/i,/^(?:actor\b)/i,/^(?:create\b)/i,/^(?:destroy\b)/i,/^(?:as\b)/i,/^(?:(?:))/i,/^(?:loop\b)/i,/^(?:rect\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:par\b)/i,/^(?:par_over\b)/i,/^(?:and\b)/i,/^(?:critical\b)/i,/^(?:option\b)/i,/^(?:break\b)/i,/^(?:(?:[:]?(?:no)?wrap)?[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:links\b)/i,/^(?:link\b)/i,/^(?:properties\b)/i,/^(?:details\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:activate\b)/i,/^(?:deactivate\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:title:\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:sequenceDiagram\b)/i,/^(?:autonumber\b)/i,/^(?:off\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\/\\\+\()\+<\->\->:\n,;]+((?!(-x|--x|-\)|--\)|-\|\\|-\\|-\/|-\/\/|-\|\/|\/\|-|\\\|-|\/\/-|\\\\-|\/\|-|--\|\\|--|\(\)))[\-]*[^\+<\->\->:\n,;]+)*)/i,/^(?:->>)/i,/^(?:<<->>)/i,/^(?:-->>)/i,/^(?:<<-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?:-[\)])/i,/^(?:--[\)])/i,/^(?:--\|\\)/i,/^(?:--\|\/)/i,/^(?:--\\\\)/i,/^(?:--\/\/)/i,/^(?:\/\|--)/i,/^(?:\\\|--)/i,/^(?:\/\/--)/i,/^(?:\\\\--)/i,/^(?:-\|\\)/i,/^(?:-\|\/)/i,/^(?:-\\\\)/i,/^(?:-\/\/)/i,/^(?:\/\|-)/i,/^(?:\\\|-)/i,/^(?:\/\/-)/i,/^(?:\\\\-)/i,/^(?::(?:(?:no)?wrap)?[^#\n;]*)/i,/^(?::)/i,/^(?:\+)/i,/^(?:-)/i,/^(?:\(\))/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[53,54],inclusive:!1},acc_descr:{rules:[51],inclusive:!1},acc_title:{rules:[49],inclusive:!1},ID:{rules:[2,3,7,11,12,13,14,15],inclusive:!1},ALIAS:{rules:[2,3,21,22],inclusive:!1},LINE:{rules:[2,3,34],inclusive:!1},CONFIG:{rules:[8,9,10],inclusive:!1},CONFIG_DATA:{rules:[],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,16,17,18,19,20,23,24,25,26,27,28,29,30,31,32,33,35,36,37,38,39,40,41,42,43,44,45,46,47,48,50,52,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93],inclusive:!0}}}})();function Ee(){this.yy={}}return n(Ee,`Parser`),Ee.prototype=Te,Te.Parser=Ee,new Ee})();P.parser=P;var F=P,I={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25,AUTONUMBER:26,CRITICAL_START:27,CRITICAL_OPTION:28,CRITICAL_END:29,BREAK_START:30,BREAK_END:31,PAR_OVER_START:32,BIDIRECTIONAL_SOLID:33,BIDIRECTIONAL_DOTTED:34,SOLID_TOP:41,SOLID_BOTTOM:42,STICK_TOP:43,STICK_BOTTOM:44,SOLID_ARROW_TOP_REVERSE:45,SOLID_ARROW_BOTTOM_REVERSE:46,STICK_ARROW_TOP_REVERSE:47,STICK_ARROW_BOTTOM_REVERSE:48,SOLID_TOP_DOTTED:51,SOLID_BOTTOM_DOTTED:52,STICK_TOP_DOTTED:53,STICK_BOTTOM_DOTTED:54,SOLID_ARROW_TOP_REVERSE_DOTTED:55,SOLID_ARROW_BOTTOM_REVERSE_DOTTED:56,STICK_ARROW_TOP_REVERSE_DOTTED:57,STICK_ARROW_BOTTOM_REVERSE_DOTTED:58,CENTRAL_CONNECTION:59,CENTRAL_CONNECTION_REVERSE:60,CENTRAL_CONNECTION_DUAL:61},ee={FILLED:0,OPEN:1},te={LEFTOF:0,RIGHTOF:1,OVER:2},L={ACTOR:`actor`,BOUNDARY:`boundary`,COLLECTIONS:`collections`,CONTROL:`control`,DATABASE:`database`,ENTITY:`entity`,PARTICIPANT:`participant`,QUEUE:`queue`},ne=class{constructor(){this.state=new M(()=>({prevActor:void 0,actors:new Map,createdActors:new Map,destroyedActors:new Map,boxes:[],messages:[],notes:[],sequenceNumbersEnabled:!1,wrapEnabled:void 0,currentBox:void 0,lastCreated:void 0,lastDestroyed:void 0})),this.setAccTitle=c,this.setAccDescription=o,this.setDiagramTitle=p,this.getAccTitle=y,this.getAccDescription=g,this.getDiagramTitle=_,this.apply=this.apply.bind(this),this.parseBoxData=this.parseBoxData.bind(this),this.parseMessage=this.parseMessage.bind(this),this.clear(),this.setWrap(v().wrap),this.LINETYPE=I,this.ARROWTYPE=ee,this.PLACEMENT=te}static{n(this,`SequenceDB`)}addBox(e){this.state.records.boxes.push({name:e.text,wrap:e.wrap??this.autoWrap(),fill:e.color,actorKeys:[]}),this.state.records.currentBox=this.state.records.boxes.slice(-1)[0]}addActor(e,t,n,r,i){let a=this.state.records.currentBox,o;if(i!==void 0){let e;e=i.includes(` +`)?i+` +`:`{ +`+i+` +}`,o=T(e,{schema:w})}r=o?.type??r,o?.alias&&(!n||n.text===t)&&(n={text:o.alias,wrap:n?.wrap,type:r});let s=this.state.records.actors.get(e);if(s){if(this.state.records.currentBox&&s.box&&this.state.records.currentBox!==s.box)throw Error(`A same participant should only be defined in one Box: ${s.name} can't be in '${s.box.name}' and in '${this.state.records.currentBox.name}' at the same time.`);if(a=s.box?s.box:this.state.records.currentBox,s.box=a,s&&t===s.name&&n==null)return}if(n?.text??(n={text:t,type:r}),(r==null||n.text==null)&&(n={text:t,type:r}),this.state.records.actors.set(e,{box:a,name:t,description:n.text,wrap:n.wrap??this.autoWrap(),prevActor:this.state.records.prevActor,links:{},properties:{},actorCnt:null,rectData:null,type:r??`participant`}),this.state.records.prevActor){let t=this.state.records.actors.get(this.state.records.prevActor);t&&(t.nextActor=e)}this.state.records.currentBox&&this.state.records.currentBox.actorKeys.push(e),this.state.records.prevActor=e}activationCount(e){let t,n=0;if(!e)return 0;for(t=0;t>-`,token:`->>-`,line:`1`,loc:{first_line:1,last_line:1,first_column:1,last_column:1},expected:[`'ACTIVE_PARTICIPANT'`]},t}return this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:e,to:t,message:n?.text??``,wrap:n?.wrap??this.autoWrap(),type:r,activate:i,centralConnection:a??0}),!0}hasAtLeastOneBox(){return this.state.records.boxes.length>0}hasAtLeastOneBoxWithTitle(){return this.state.records.boxes.some(e=>e.name)}getMessages(){return this.state.records.messages}getBoxes(){return this.state.records.boxes}getActors(){return this.state.records.actors}getCreatedActors(){return this.state.records.createdActors}getDestroyedActors(){return this.state.records.destroyedActors}getActor(e){return this.state.records.actors.get(e)}getActorKeys(){return[...this.state.records.actors.keys()]}enableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!0}disableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!1}showSequenceNumbers(){return this.state.records.sequenceNumbersEnabled}setWrap(e){this.state.records.wrapEnabled=e}extractWrap(e){if(e===void 0)return{};e=e.trim();let t=/^:?wrap:/.exec(e)!==null||/^:?nowrap:/.exec(e)===null&&void 0;return{cleanedText:(t===void 0?e:e.replace(/^:?(?:no)?wrap:/,``)).trim(),wrap:t}}autoWrap(){return this.state.records.wrapEnabled===void 0?v().sequence?.wrap??!1:this.state.records.wrapEnabled}clear(){this.state.reset(),l()}parseMessage(t){let n=t.trim(),{wrap:r,cleanedText:i}=this.extractWrap(n),a={text:i,wrap:r};return e.debug(`parseMessage: ${JSON.stringify(a)}`),a}parseBoxData(e){let t=/^((?:rgba?|hsla?)\s*\(.*\)|\w*)(.*)$/.exec(e),n=t?.[1]?t[1].trim():`transparent`,r=t?.[2]?t[2].trim():void 0;if(window?.CSS)window.CSS.supports(`color`,n)||(n=`transparent`,r=e.trim());else{let t=new Option().style;t.color=n,t.color!==n&&(n=`transparent`,r=e.trim())}let{wrap:i,cleanedText:a}=this.extractWrap(r);return{text:a?b(a,v()):void 0,color:n,wrap:i}}addNote(e,t,n){let r={actor:e,placement:t,message:n.text,wrap:n.wrap??this.autoWrap()},i=[].concat(e,e);this.state.records.notes.push(r),this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:i[0],to:i[1],message:n.text,wrap:n.wrap??this.autoWrap(),type:this.LINETYPE.NOTE,placement:t})}addLinks(t,n){let r=this.getActor(t);try{let e=b(n.text,v());e=e.replace(/=/g,`=`),e=e.replace(/&/g,`&`);let t=JSON.parse(e);this.insertLinks(r,t)}catch(t){e.error(`error while parsing actor link text`,t)}}addALink(t,n){let r=this.getActor(t);try{let e={},t=b(n.text,v()),i=t.indexOf(`@`);t=t.replace(/=/g,`=`),t=t.replace(/&/g,`&`);let a=t.slice(0,i-1).trim();e[a]=t.slice(i+1).trim(),this.insertLinks(r,e)}catch(t){e.error(`error while parsing actor link text`,t)}}insertLinks(e,t){if(e.links==null)e.links=t;else for(let n in t)e.links[n]=t[n]}addProperties(t,n){let r=this.getActor(t);try{let e=b(n.text,v()),t=JSON.parse(e);this.insertProperties(r,t)}catch(t){e.error(`error while parsing actor properties text`,t)}}insertProperties(e,t){if(e.properties==null)e.properties=t;else for(let n in t)e.properties[n]=t[n]}boxEnd(){this.state.records.currentBox=void 0}addDetails(t,n){let r=this.getActor(t),i=document.getElementById(n.text);try{let e=i.innerHTML,t=JSON.parse(e);t.properties&&this.insertProperties(r,t.properties),t.links&&this.insertLinks(r,t.links)}catch(t){e.error(`error while parsing actor details text`,t)}}getActorProperty(e,t){if(e?.properties!==void 0)return e.properties[t]}apply(e){if(Array.isArray(e))e.forEach(e=>{this.apply(e)});else switch(e.type){case`sequenceIndex`:this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:void 0,to:void 0,message:{start:e.sequenceIndex,step:e.sequenceIndexStep,visible:e.sequenceVisible},wrap:!1,type:e.signalType});break;case`addParticipant`:this.addActor(e.actor,e.actor,e.description,e.draw,e.config);break;case`createParticipant`:if(this.state.records.actors.has(e.actor))throw Error(`It is not possible to have actors with the same id, even if one is destroyed before the next is created. Use 'AS' aliases to simulate the behavior`);this.state.records.lastCreated=e.actor,this.addActor(e.actor,e.actor,e.description,e.draw,e.config),this.state.records.createdActors.set(e.actor,this.state.records.messages.length);break;case`destroyParticipant`:this.state.records.lastDestroyed=e.actor,this.state.records.destroyedActors.set(e.actor,this.state.records.messages.length);break;case`activeStart`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`centralConnection`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`centralConnectionReverse`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`activeEnd`:this.addSignal(e.actor,void 0,void 0,e.signalType);break;case`addNote`:this.addNote(e.actor,e.placement,e.text);break;case`addLinks`:this.addLinks(e.actor,e.text);break;case`addALink`:this.addALink(e.actor,e.text);break;case`addProperties`:this.addProperties(e.actor,e.text);break;case`addDetails`:this.addDetails(e.actor,e.text);break;case`addMessage`:if(this.state.records.lastCreated){if(e.to!==this.state.records.lastCreated)throw Error(`The created participant `+this.state.records.lastCreated.name+` does not have an associated creating message after its declaration. Please check the sequence diagram.`);this.state.records.lastCreated=void 0}else if(this.state.records.lastDestroyed){if(e.to!==this.state.records.lastDestroyed&&e.from!==this.state.records.lastDestroyed)throw Error(`The destroyed participant `+this.state.records.lastDestroyed.name+` does not have an associated destroying message after its declaration. Please check the sequence diagram.`);this.state.records.lastDestroyed=void 0}this.addSignal(e.from,e.to,e.msg,e.signalType,e.activate,e.centralConnection);break;case`boxStart`:this.addBox(e.boxData);break;case`boxEnd`:this.boxEnd();break;case`loopStart`:this.addSignal(void 0,void 0,e.loopText,e.signalType);break;case`loopEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`rectStart`:this.addSignal(void 0,void 0,e.color,e.signalType);break;case`rectEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`optStart`:this.addSignal(void 0,void 0,e.optText,e.signalType);break;case`optEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`altStart`:this.addSignal(void 0,void 0,e.altText,e.signalType);break;case`else`:this.addSignal(void 0,void 0,e.altText,e.signalType);break;case`altEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`setAccTitle`:c(e.text);break;case`parStart`:this.addSignal(void 0,void 0,e.parText,e.signalType);break;case`and`:this.addSignal(void 0,void 0,e.parText,e.signalType);break;case`parEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`criticalStart`:this.addSignal(void 0,void 0,e.criticalText,e.signalType);break;case`option`:this.addSignal(void 0,void 0,e.optionText,e.signalType);break;case`criticalEnd`:this.addSignal(void 0,void 0,void 0,e.signalType);break;case`breakStart`:this.addSignal(void 0,void 0,e.breakText,e.signalType);break;case`breakEnd`:this.addSignal(void 0,void 0,void 0,e.signalType)}}getConfig(){return v().sequence}},re=n(e=>{let t=e.dropShadow??`none`,{look:n}=v();return`.actor { + stroke: ${e.actorBorder}; + fill: ${e.actorBkg}; + stroke-width: ${e.strokeWidth??1}; + } + + rect.actor.outer-path[data-look="neo"] { + filter: ${t}; + } + + rect.note[data-look="neo"] { + stroke:${e.noteBorderColor}; + fill:${e.noteBkgColor}; + filter: ${t}; + } + + text.actor > tspan { + fill: ${e.actorTextColor}; + stroke: none; + } + + .actor-line { + stroke: ${e.actorLineColor}; + } + + .innerArc { + stroke-width: 1.5; + stroke-dasharray: none; + } + + .messageLine0 { + stroke-width: 1.5; + stroke-dasharray: none; + stroke: ${e.signalColor}; + } + + .messageLine1 { + stroke-width: 1.5; + stroke-dasharray: 2, 2; + stroke: ${e.signalColor}; + } + + [id$="-arrowhead"] path { + fill: ${e.signalColor}; + stroke: ${e.signalColor}; + } + + .sequenceNumber { + fill: ${e.sequenceNumberColor}; + } + + [id$="-sequencenumber"] { + fill: ${e.signalColor}; + } + + [id$="-crosshead"] path { + fill: ${e.signalColor}; + stroke: ${e.signalColor}; + } + + .messageText { + fill: ${e.signalTextColor}; + stroke: none; + } + + .labelBox { + stroke: ${e.labelBoxBorderColor}; + fill: ${e.labelBoxBkgColor}; + filter: ${n===`neo`?t:`none`}; + } + + .labelText, .labelText > tspan { + fill: ${e.labelTextColor}; + stroke: none; + } + + .loopText, .loopText > tspan { + fill: ${e.loopTextColor}; + stroke: none; + } + + .sectionTitle, .sectionTitle > tspan { + fill: ${e.loopTextColor}; + stroke: none; + } + + .loopLine { + stroke-width: 2px; + stroke-dasharray: 2, 2; + stroke: ${e.labelBoxBorderColor}; + fill: ${e.labelBoxBorderColor}; + } + + .note { + //stroke: #decc93; + stroke: ${e.noteBorderColor}; + fill: ${e.noteBkgColor}; + } + + /* + * No font-weight here, deliberately. Note text renders inside tspan elements, and a weight emitted at + * tspan level outranks the inline style drawText puts on the parent text element from the + * sequence.noteFontWeight config key -- so that documented key would never reach the glyphs. + * The theme variable formerly emitted here is a different value from that config key, and + * git/styles.js reads it as its own bold-label weight under redux and neo, so it cannot be + * lowered there either. + */ + .noteText, .noteText > tspan { + fill: ${e.noteTextColor}; + stroke: none; + } + + .activation0 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .activation1 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .activation2 { + fill: ${e.activationBkgColor}; + stroke: ${e.activationBorderColor}; + } + + .actorPopupMenu { + position: absolute; + } + + .actorPopupMenuPanel { + position: absolute; + fill: ${e.actorBkg}; + box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); + filter: drop-shadow(3px 5px 2px rgb(0 0 0 / 0.4)); +} + .actor-man circle, line { + fill: ${e.actorBkg}; + stroke-width: 2px; + } + + g rect.rect { + filter: ${t}; + stroke: ${e.nodeBorder}; + } +`},`getStyles`),ie=44,ae=6,oe=6,se=n((e,t)=>e.actorTextHeight??S.calculateTextDimensions(e.description??``,{fontFamily:t.actorFontFamily,fontSize:t.actorFontSize,fontWeight:t.actorFontWeight}).height,`actorLabelHeight`),ce=n(e=>ie+ae+e+oe,`actorStackHeight`),le=n((e,t,n)=>{let r=e+t,i=r-oe-n/2;return{lifelineStartY:r,glyphBottomY:r-oe-n-ae,labelCenterY:i}},`headerBands`),ue=n((e,t)=>{let n=e+oe,r=n+ie;return{glyphTopY:n,glyphBottomY:r,labelCenterY:r+ae+t/2,stackHeight:ce(t)}},`footerBands`),R=36,de=-5,fe=60,pe=fe-de,me=n((e,t,n,r)=>{if(t.look!==`neo`)return null;let i=se(e,t);return n?ue(r,i):le(r,e.height,i)},`neoBands`),z=`actor-top`,B=`actor-bottom`,he=`actor-box`,V=`actor-man`,H=new Set([`redux-color`,`redux-dark-color`]),U=n((e,t)=>e?.length?e[t%e.length]:void 0,`paletteColor`),ge=n(function(e,t){let n=E(e,t);return u().look===`neo`&&n.attr(`data-look`,`neo`),n},`drawRect`),_e=n(function(e,t,n,r,i){if(t.links===void 0||t.links===null||Object.keys(t.links).length===0)return{height:0,width:0};let a=t.links,o=t.actorCnt,s=t.rectData;var c=`none`;i&&(c=`block !important`);let l=e.append(`g`);l.attr(`id`,`actor`+o+`_popup`),l.attr(`class`,`actorPopupMenu`),l.attr(`display`,c);var u=``;s.class!==void 0&&(u=` `+s.class);let d=s.width>n?s.width:n,f=l.append(`rect`);if(f.attr(`class`,`actorPopupMenuPanel`+u),f.attr(`x`,s.x),f.attr(`y`,s.height),f.attr(`fill`,s.fill),f.attr(`stroke`,s.stroke),f.attr(`width`,d),f.attr(`height`,s.height),f.attr(`rx`,s.rx),f.attr(`ry`,s.ry),a!=null){var p=20;for(let e in a){var m=l.append(`a`),h=(0,N.sanitizeUrl)(a[e]);m.attr(`xlink:href`,h),m.attr(`target`,`_blank`),We(r)(e,m,s.x+10,s.height+p,d,20,{class:`actor`},r),p+=30}}return f.attr(`height`,p),{height:s.height+p,width:d}},`drawPopup`),ve=n(function(e){return`var pu = document.getElementById('`+e+`'); if (pu != null) { pu.style.display = pu.style.display == 'block' ? 'none' : 'block'; }`},`popupMenuToggle`),ye=n(async function(e,t,n=null){let r=e.append(`foreignObject`),a=await i(t.text,u()),o=r.append(`xhtml:div`).attr(`style`,`width: fit-content;`).attr(`xmlns`,`http://www.w3.org/1999/xhtml`).html(a).node().getBoundingClientRect();if(r.attr(`height`,Math.round(o.height)).attr(`width`,Math.round(o.width)),t.class===`noteText`){let n=e.node().firstChild;n.setAttribute(`height`,o.height+2*t.textMargin);let i=n.getBBox();r.attr(`x`,Math.round(i.x+i.width/2-o.width/2)).attr(`y`,Math.round(i.y+i.height/2-o.height/2))}else if(n){let{startx:e,stopx:i,starty:a}=n;if(e>i){let t=e;e=i,i=t}r.attr(`x`,Math.round(e+Math.abs(e-i)/2-o.width/2)),t.class===`loopText`?r.attr(`y`,Math.round(a)):r.attr(`y`,Math.round(a-o.height))}return[r]},`drawKatex`),W=n(function(e,t){let r=0,i=0,a=t.text.split(h.lineBreakRegex),[o,s]=C(t.fontSize),c=[],l=0,u=n(()=>t.y,`yfunc`);if(t.valign!==void 0&&t.textMargin!==void 0&&t.textMargin>0)switch(t.valign){case`top`:case`start`:u=n(()=>Math.round(t.y+t.textMargin),`yfunc`);break;case`middle`:case`center`:u=n(()=>Math.round(t.y+(r+i+t.textMargin)/2),`yfunc`);break;case`bottom`:case`end`:u=n(()=>Math.round(t.y+(r+i+2*t.textMargin)-t.textMargin),`yfunc`)}if(t.anchor!==void 0&&t.textMargin!==void 0&&t.width!==void 0)switch(t.anchor){case`left`:case`start`:t.x=Math.round(t.x+t.textMargin),t.anchor=`start`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`;break;case`middle`:case`center`:t.x=Math.round(t.x+t.width/2),t.anchor=`middle`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`;break;case`right`:case`end`:t.x=Math.round(t.x+t.width-t.textMargin),t.anchor=`end`,t.dominantBaseline=`middle`,t.alignmentBaseline=`middle`}for(let[n,d]of a.entries()){t.textMargin!==void 0&&t.textMargin===0&&o!==void 0&&(l=n*o);let a=e.append(`text`);a.attr(`x`,t.x),a.attr(`y`,u()),t.anchor!==void 0&&a.attr(`text-anchor`,t.anchor).attr(`dominant-baseline`,t.dominantBaseline).attr(`alignment-baseline`,t.alignmentBaseline),t.fontFamily!==void 0&&a.style(`font-family`,t.fontFamily),s!==void 0&&a.style(`font-size`,s),t.fontWeight!==void 0&&a.style(`font-weight`,t.fontWeight),t.fill!==void 0&&a.attr(`fill`,t.fill),t.class!==void 0&&a.attr(`class`,t.class),t.dy===void 0?l!==0&&a.attr(`dy`,l):a.attr(`dy`,t.dy);let f=d||`​`;if(t.tspan){let e=a.append(`tspan`);e.attr(`x`,t.x),t.fill!==void 0&&e.attr(`fill`,t.fill),e.text(f)}else a.text(f);t.valign!==void 0&&t.textMargin!==void 0&&t.textMargin>0&&(i+=(a._groups||a)[0][0].getBBox().height,r=i),c.push(a)}return c},`drawText`),be=n(function(e,t){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}n(r,`genPoints`);let i=e.append(`polygon`);return i.attr(`points`,r(t.x,t.y,t.width,t.height,7)),i.attr(`class`,`labelBox`),t.y+=t.height/2,W(e,t),i},`drawLabel`),G=-1,xe=n((e,t,n,r)=>{e.select&&n.forEach(n=>{let i=t.get(n),a=e.select(`#actor`+i.actorCnt);!r.mirrorActors&&i.stopy?a.attr(`y2`,i.stopy+i.height/2):r.mirrorActors&&a.attr(`y2`,i.stopy)})},`fixLifeLineHeights`),Se=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower();var g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j();var v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.class=v,_.rx=3,_.ry=3,_.name=t.name,u===`neo`&&(_.rx=6,_.ry=6);let y=ge(g,_),b=o.get(t.name)??0;if(H.has(d)&&(y.style(`stroke`,U(m,b)),y.style(`fill`,U(p,b))),u===`neo`&&y.attr(`filter`,`url(#${J(a)})`),t.rectData=_,t.properties?.icon){let e=t.properties.icon.trim();e.charAt(0)===`@`?A(g,_.x+_.width-20,_.y+10,e.substr(1)):O(g,_.x+_.width-20,_.y+10,e)}i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`participant`),g.attr(`data-id`,t.name)),Y(n,r(t.description))(t.description,g,_.x,_.y,_.width,_.height,{class:`actor ${he}`},n);let x=t.height;if(y.node){let e=y.node().getBBox();n.look!==`neo`&&(t.height=e.height,x=e.height)}return x},`drawActorTypeParticipant`),Ce=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower();var g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j();var v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.class=v,_.name=t.name,n.look===`neo`&&(_.height=t.height-6);let y={..._,x:_.x+-6,y:_.y+6,class:`actor`},b=ge(g,_),x=ge(g,y);t.rectData=_,u===`neo`&&g.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;if(H.has(d)&&(b.style(`stroke`,U(m,S)),b.style(`fill`,U(p,S)),x.style(`stroke`,U(m,S)),x.style(`fill`,U(p,S))),t.properties?.icon){let e=t.properties.icon.trim();e.charAt(0)===`@`?A(g,_.x+_.width-20,_.y+10,e.substr(1)):O(g,_.x+_.width-20,_.y+10,e)}Y(n,r(t.description))(t.description,g,_.x-6,_.y+6,_.width,_.height,{class:`actor ${he}`},n);let C=t.height;if(b.node){let e=b.node().getBBox();n.look!==`neo`&&(t.height=e.height,C=e.height)}return i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`collections`),g.attr(`data-id`,t.name)),C},`drawActorTypeCollections`),we=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=s+t.height,{look:u,theme:d,themeVariables:f}=n,{bkgColorArray:p,borderColorArray:m}=f,h=e.append(`g`).lower(),g=h;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&g.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,l).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),g=h.append(`g`),t.actorCnt=G,t.links!=null&&g.attr(`id`,`root-`+G),u===`neo`&&g.attr(`data-look`,`neo`));let _=j(),v=`actor`;t.properties?.class?v=t.properties.class:_.fill=`#eaeaea`,v+=i?` ${B}`:` ${z}`,g.attr(`class`,v),_.x=t.x,_.y=s,_.width=t.width,_.height=t.height,_.name=t.name;let y=_.height/2,b=y/(2.5+_.height/50),x=g.append(`g`),S=g.append(`g`),C=`M ${_.x},${_.y+y} + a ${b},${y} 0 0 0 0,${_.height} + h ${_.width-2*b} + a ${b},${y} 0 0 0 0,-${_.height} + Z + `;x.append(`path`).attr(`d`,C),S.append(`path`).attr(`d`,`M ${_.x},${_.y+y} + a ${b},${y} 0 0 0 0,${_.height}`),x.attr(`transform`,`translate(${b}, ${-(_.height/2)})`),S.attr(`transform`,`translate(${_.width-b}, ${-_.height/2})`),t.rectData=_,u===`neo`&&x.attr(`filter`,`url(#${J(a)})`);let w=o.get(t.name)??0;if(H.has(d)&&(x.style(`stroke`,U(m,w)),x.style(`fill`,U(p,w)),S.style(`stroke`,U(m,w)),S.style(`fill`,U(p,w))),t.properties?.icon){let e=t.properties.icon.trim(),n=_.x+_.width-20,r=_.y+10;e.charAt(0)===`@`?A(g,n,r,e.substr(1)):O(g,n,r,e)}Y(n,r(t.description))(t.description,g,_.x,_.y,_.width,_.height,{class:`actor ${he}`},n);let T=t.height,E=x.select(`path:last-child`);if(E.node()){let e=E.node().getBBox();n.look!==`neo`&&(t.height=e.height,T=e.height)}return i||(g.attr(`data-et`,`participant`),g.attr(`data-type`,`queue`),g.attr(`data-id`,t.name)),T},`drawActorTypeQueue`),K=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+75,{look:d,theme:f,themeVariables:p}=n,{bkgColorArray:m,borderColorArray:h,actorBorder:g,actorBkg:_}=p,v=e.append(`g`).lower();i||(G++,v.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let y=e.append(`g`),b=V;b+=i?` ${B}`:` ${z}`,y.attr(`class`,b),y.attr(`name`,t.name);let x=j();x.x=t.x,x.y=s,x.fill=`#eaeaea`,x.width=t.width,x.height=t.height,x.class=`actor`;let S=t.x+t.width/2,C=l?l.glyphBottomY-22:s+32;y.append(`defs`).append(`marker`).attr(`id`,a+`-filled-head-control`).attr(`refX`,11).attr(`refY`,5.8).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`172.5`).attr(`stroke-width`,1.2).append(`path`).attr(`d`,`M 14.4 5.6 L 7.2 10.4 L 8.8 5.6 L 7.2 0.8 Z`),y.append(`circle`).attr(`cx`,S).attr(`cy`,C).attr(`r`,22).attr(`filter`,`${d===`neo`?`url(#${J(a)})`:``}`),y.append(`line`).attr(`marker-end`,`url(#`+a+`-filled-head-control)`).attr(`transform`,`translate(${S}, ${C-22})`);let w=o.get(t.name)??0;return H.has(f)?(y.style(`stroke`,U(h,w)),y.style(`fill`,U(m,w))):(y.style(`stroke`,g),y.style(`fill`,_)),l||(t.height=y.node().getBBox().height+2*(n?.sequence?.labelBoxHeight??0)),Y(n,r(t.description))(t.description,y,x.x,l?l.labelCenterY-x.height/2:x.y+22+(i?5:12),x.width,x.height,{class:`actor ${V}`},n),i||(y.attr(`data-et`,`participant`),y.attr(`data-type`,`control`),y.attr(`data-id`,t.name)),t.height},`drawActorTypeControl`),q=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+75,{look:d,theme:f,themeVariables:p}=n,{bkgColorArray:m,borderColorArray:h}=p,g=e.append(`g`).lower(),_=e.append(`g`),v=`actor`;v+=i?` ${B}`:` ${z}`,_.attr(`class`,v),_.attr(`name`,t.name);let y=j();y.x=t.x,y.y=s,y.fill=`#eaeaea`,y.width=t.width,y.height=t.height,y.class=`actor`;let b=t.x+t.width/2,x=l?l.glyphBottomY-22:s+(i?10:25);_.append(`circle`).attr(`cx`,b).attr(`cy`,x).attr(`r`,22).attr(`width`,t.width).attr(`height`,t.height),_.append(`line`).attr(`x1`,b-22).attr(`x2`,b+22).attr(`y1`,x+22).attr(`y2`,x+22).attr(`stroke-width`,2),d===`neo`&&_.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;return H.has(f)&&(_.style(`stroke`,U(h,S)),_.style(`fill`,U(m,S))),l||(t.height=_.node().getBBox().height+(n?.sequence?.labelBoxHeight??0)),i||(G++,g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G),Y(n,r(t.description))(t.description,_,y.x,l?l.labelCenterY-y.height/2:y.y+(i?15:30),y.width,y.height,{class:`actor ${V}`},n),l||_.attr(`transform`,`translate(0, ${i?22:6})`),i||(_.attr(`data-et`,`participant`),_.attr(`data-type`,`entity`),_.attr(`data-id`,t.name)),t.height},`drawActorTypeEntity`),Te=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+t.height+2*n.boxTextMargin,{theme:d,themeVariables:f,look:p}=n,{bkgColorArray:m,borderColorArray:h,actorBorder:g}=f,_=e.append(`g`).lower(),v=_;i||(G++,Object.keys(t.links||{}).length&&!n.forceMenus&&v.attr(`onclick`,ve(`actor${G}_popup`)).attr(`cursor`,`pointer`),v.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),v=_.append(`g`),t.actorCnt=G,t.links!=null&&v.attr(`id`,`root-`+G),p===`neo`&&v.attr(`data-look`,`neo`));let y=j(),b=`actor`;t.properties?.class?b=t.properties.class:y.fill=`#eaeaea`,b+=i?` ${B}`:` ${z}`,y.x=t.x,y.y=s,y.width=t.width,y.height=t.height,y.class=b,y.name=t.name,y.x=t.x,y.y=s;let x=y.width/3,S=x/2,C=S/(2.5+x/50),w=l?ie:y.width/3,T=l?l.glyphBottomY-w-C:y.y,E=v.append(`g`);E.attr(`class`,b);let D=` + M ${y.x},${T+C} + a ${S},${C} 0 0 0 ${x},0 + a ${S},${C} 0 0 0 -${x},0 + l 0,${w-2*C} + a ${S},${C} 0 0 0 ${x},0 + l 0,-${w-2*C} +`;E.append(`path`).attr(`d`,D),p===`neo`&&E.attr(`filter`,`url(#${J(a)})`);let O=o.get(t.name)??0;if(H.has(d)?(E.style(`stroke`,U(h,O)),E.style(`fill`,U(m,O))):E.style(`stroke`,g),E.attr(`transform`,`translate(${x}, ${C})`),t.rectData=y,Y(n,r(t.description))(t.description,v,y.x,l?l.labelCenterY-y.height/2:y.y+35,y.width,y.height,{class:`actor ${he}`},n),!l){let e=E.select(`path:last-child`);e.node()&&(t.height=e.node().getBBox().height+(n.sequence.labelBoxHeight??0))}return i||(v.attr(`data-et`,`participant`),v.attr(`data-type`,`database`),v.attr(`data-id`,t.name)),t.height},`drawActorTypeDatabase`),Ee=n(function(e,t,n,i,a,o){let s=i?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,n,i,s),u=l?l.lifelineStartY:s+80,d=l?l.glyphBottomY-22:s+12,f=e.append(`g`).lower(),{look:p,theme:m,themeVariables:h}=n,{bkgColorArray:g,borderColorArray:_,actorBorder:v}=h;i||(G++,f.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let y=e.append(`g`),b=V;b+=i?` ${B}`:` ${z}`,y.attr(`class`,b),y.attr(`name`,t.name);let x=j();x.x=t.x,x.y=s,x.fill=`#eaeaea`,x.width=t.width,x.height=t.height,x.class=`actor`,y.append(`line`).attr(`id`,`actor-man-torso`+G).attr(`x1`,t.x+t.width/2-55).attr(`y1`,d).attr(`x2`,t.x+t.width/2-15).attr(`y2`,d),y.append(`line`).attr(`id`,`actor-man-arms`+G).attr(`x1`,t.x+t.width/2-55).attr(`y1`,d-10).attr(`x2`,t.x+t.width/2-55).attr(`y2`,d+10),y.append(`circle`).attr(`cx`,t.x+t.width/2).attr(`cy`,d).attr(`r`,22),p===`neo`&&y.attr(`filter`,`url(#${J(a)})`);let S=o.get(t.name)??0;return H.has(m)?(y.style(`stroke`,U(_,S)),y.style(`fill`,U(g,S))):y.style(`stroke`,v),l||(t.height=y.node().getBBox().height+(n.sequence.labelBoxHeight??0)),Y(n,r(t.description))(t.description,y,x.x,l?l.labelCenterY-x.height/2:x.y+15,x.width,x.height,{class:`actor ${V}`},n),l||y.attr(`transform`,`translate(0,21)`),i||(y.attr(`data-et`,`participant`),y.attr(`data-type`,`boundary`),y.attr(`data-id`,t.name)),t.height},`drawActorTypeBoundary`),De=n(function(e,t,i,a,o){let s=a?t.stopy:t.starty,c=t.x+t.width/2,l=me(t,i,a,s),u=l?l.lifelineStartY:s+80,{theme:d,themeVariables:f}=i,{bkgColorArray:p,borderColorArray:m,actorBorder:h}=f,g=e.append(`g`).lower();a||(G++,g.append(`line`).attr(`id`,`actor`+G).attr(`x1`,c).attr(`y1`,u).attr(`x2`,c).attr(`y2`,2e3).attr(`class`,`actor-line 200`).attr(`stroke-width`,`0.5px`).attr(`stroke`,`#999`).attr(`name`,t.name).attr(`data-et`,`life-line`).attr(`data-id`,t.name),t.actorCnt=G);let _=e.append(`g`),v=V;v+=a?` ${B}`:` ${z}`,_.attr(`class`,v),_.attr(`name`,t.name),a||_.attr(`data-et`,`participant`).attr(`data-type`,`actor`).attr(`data-id`,t.name);let y=l?ie/pe:1,b=n(e=>l?l.glyphBottomY-(fe-e)*y:s+e,`gy`),x=n(e=>c+e*y,`gx`);_.append(`line`).attr(`id`,`actor-man-torso`+G).attr(`x1`,c).attr(`y1`,b(25)).attr(`x2`,c).attr(`y2`,b(45)),_.append(`line`).attr(`id`,`actor-man-arms`+G).attr(`x1`,x(-R/2)).attr(`y1`,b(33)).attr(`x2`,x(R/2)).attr(`y2`,b(33)),_.append(`line`).attr(`x1`,x(-R/2)).attr(`y1`,b(60)).attr(`x2`,c).attr(`y2`,b(45)),_.append(`line`).attr(`x1`,c).attr(`y1`,b(45)).attr(`x2`,x(R/2-2)).attr(`y2`,b(60));let S=_.append(`circle`);S.attr(`cx`,t.x+t.width/2),S.attr(`cy`,b(10)),S.attr(`r`,15*y),S.attr(`width`,t.width),S.attr(`height`,t.height),l||(t.height=pe);let C=j();C.x=t.x,C.y=s,C.fill=`#eaeaea`,C.width=t.width,C.height=t.height,C.class=`actor`,C.rx=3,C.ry=3;let w=o.get(t.name)??0;return H.has(d)?(_.style(`stroke`,U(m,w)),_.style(`fill`,U(p,w))):_.style(`stroke`,h),Y(i,r(t.description))(t.description,_,C.x,l?l.labelCenterY-C.height/2:s+35,C.width,C.height,{class:`actor ${V}`},i),t.height},`drawActorTypeActor`),Oe=n(async function(e,t,n,r,i,a,o){let s=o??new Map([...a.db.getActors().values()].map((e,t)=>[e.name,t]));switch(t.type){case`actor`:return await De(e,t,n,r,s);case`participant`:return await Se(e,t,n,r,i,s);case`boundary`:return await Ee(e,t,n,r,i,s);case`control`:return await K(e,t,n,r,i,s);case`entity`:return await q(e,t,n,r,i,s);case`database`:return await Te(e,t,n,r,i,s);case`collections`:return await Ce(e,t,n,r,i,s);case`queue`:return await we(e,t,n,r,i,s)}},`drawActor`),ke=n(function(e,t,n){let r=e.append(`g`);Ne(r,t),t.name&&Y(n)(t.name,r,t.x,t.y+n.boxTextMargin+(t.textMaxHeight||0)/2,t.width,0,{class:`text`},n),r.lower()},`drawBox`),Ae=n(function(e){return e.append(`g`)},`anchorElement`),je=n(function(e,t,n,r,i,a,o){let{theme:s,themeVariables:c}=r,{bkgColorArray:l,borderColorArray:u,mainBkg:d}=c,f=j(),p=t.anchored,m=t.actor;f.x=t.startx,f.y=t.starty,f.class=`activation`+i%3,f.width=t.stopx-t.startx,f.height=n-t.starty;let h=ge(p,f),g=(o??new Map([...a.db.getActors().values()].map((e,t)=>[e.name,t]))).get(m)??0;H.has(s)&&(h.style(`stroke`,U(u,g)),h.style(`fill`,U(l,g)??d))},`drawActivation`),Me=n(async function(e,t,i,a,o){let{boxMargin:s,boxTextMargin:c,labelBoxHeight:l,labelBoxWidth:u,messageFontFamily:d,messageFontSize:f,messageFontWeight:p}=a,m=e.append(`g`).attr(`data-et`,`control-structure`).attr(`data-id`,`i`+o.id),h=n(function(e,t,n,r){return m.append(`line`).attr(`x1`,e).attr(`y1`,t).attr(`x2`,n).attr(`y2`,r).attr(`class`,`loopLine`)},`drawLoopLine`);h(t.startx,t.starty,t.stopx,t.starty),h(t.stopx,t.starty,t.stopx,t.stopy),h(t.startx,t.stopy,t.stopx,t.stopy),h(t.startx,t.starty,t.startx,t.stopy),t.sections!==void 0&&t.sections.forEach(function(e){h(t.startx,e.y,t.stopx,e.y).style(`stroke-dasharray`,`3, 3`)});let g=D();g.text=i,g.x=t.startx,g.y=t.starty,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.anchor=`middle`,g.valign=`middle`,g.tspan=!1,g.width=Math.max(u??0,50),g.height=l+(a.look===`neo`?15:0)||20,g.textMargin=c,g.class=`labelText`,be(m,g),g=He(),g.text=t.title,g.x=t.startx+u/2+(t.stopx-t.startx)/2,g.y=t.starty+s+c,g.anchor=`middle`,g.valign=`middle`,g.textMargin=c,g.class=`loopText`,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.wrap=!0;let _=r(g.text)?await ye(m,g,t):W(m,g);if(t.sectionTitles!==void 0){for(let[e,n]of Object.entries(t.sectionTitles))if(n.message){g.text=n.message,g.x=t.startx+(t.stopx-t.startx)/2,g.y=t.sections[e].y+s+c,g.class=`sectionTitle`,g.anchor=`middle`,g.valign=`middle`,g.tspan=!1,g.fontFamily=d,g.fontSize=f,g.fontWeight=p,g.wrap=t.wrap,r(g.text)?(t.starty=t.sections[e].y,await ye(m,g,t)):W(m,g);let i=Math.round(_.map(e=>(e._groups||e)[0][0].getBBox().height).reduce((e,t)=>e+t));t.sections[e].height+=i-(s+c)}}return t.height=Math.round(t.stopy-t.starty),m},`drawLoop`),Ne=n(function(e,t){k(e,t)},`drawBackgroundRect`),Pe=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-database`).attr(`fill-rule`,`evenodd`).attr(`clip-rule`,`evenodd`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z`)},`insertDatabaseIcon`),Fe=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-computer`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z`)},`insertComputerIcon`),Ie=n(function(e,t){e.append(`defs`).append(`symbol`).attr(`id`,t+`-clock`).attr(`width`,`24`).attr(`height`,`24`).append(`path`).attr(`transform`,`scale(.5)`).attr(`d`,`M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z`)},`insertClockIcon`),Le=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowhead`).attr(`refX`,7.9).attr(`refY`,5).attr(`markerUnits`,`userSpaceOnUse`).attr(`markerWidth`,12).attr(`markerHeight`,12).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M -1 0 L 10 5 L 0 10 z`)},`insertArrowHead`),Re=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-filled-head`).attr(`refX`,15.5).attr(`refY`,7).attr(`markerWidth`,20).attr(`markerHeight`,28).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 18,7 L9,13 L14,7 L9,1 Z`)},`insertArrowFilledHead`),ze=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-sequencenumber`).attr(`refX`,15).attr(`refY`,15).attr(`markerWidth`,60).attr(`markerHeight`,40).attr(`orient`,`auto`).append(`circle`).attr(`cx`,15).attr(`cy`,15).attr(`r`,6)},`insertSequenceNumber`),Be=n(function(e,t){e.append(`defs`).append(`marker`).attr(`id`,t+`-crosshead`).attr(`markerWidth`,15).attr(`markerHeight`,8).attr(`orient`,`auto`).attr(`refX`,4).attr(`refY`,4.5).append(`path`).attr(`fill`,`none`).attr(`stroke`,`#000000`).style(`stroke-dasharray`,`0, 0`).attr(`stroke-width`,`1pt`).attr(`d`,`M 1,2 L 6,7 M 6,2 L 1,7`)},`insertArrowCrossHead`),J=n(e=>e?`${e}-drop-shadow`:`drop-shadow`,`dropShadowId`),Ve=n(function(e,t,n){let{theme:r}=t;e.append(`defs`).append(`filter`).attr(`id`,J(n)).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,`0.06`).attr(`flood-color`,`${r===`redux`||r===`redux-color`?`#000000`:`#FFFFFF`}`)},`insertDropShadow`),He=n(function(){return{x:0,y:0,fill:void 0,anchor:void 0,style:`#666`,width:void 0,height:void 0,textMargin:0,rx:0,ry:0,tspan:!0,valign:void 0}},`getTextObj`),Ue=n(function(){return{x:0,y:0,fill:`#EDF2AE`,stroke:`#666`,width:100,anchor:`start`,height:100,rx:0,ry:0}},`getNoteRect`),Y=(function(){function e(e,t,n,r,i,a,s){o(t.append(`text`).attr(`x`,n+i/2).attr(`y`,r+a/2+5).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,i,a,s,c){let{actorFontSize:l,actorFontFamily:u,actorFontWeight:d}=c,[f,p]=C(l),m=e.split(h.lineBreakRegex);for(let e=0;ee.height||0))+(this.loops.length===0?0:this.loops.map(e=>e.height||0).reduce((e,t)=>e+t))+(this.messages.length===0?0:this.messages.map(e=>e.height||0).reduce((e,t)=>e+t))+(this.notes.length===0?0:this.notes.map(e=>e.height||0).reduce((e,t)=>e+t))},`getHeight`),clear:n(function(){this.actors=[],this.boxes=[],this.loops=[],this.messages=[],this.notes=[]},`clear`),addBox:n(function(e){this.boxes.push(e)},`addBox`),addActor:n(function(e){this.actors.push(e)},`addActor`),addLoop:n(function(e){this.loops.push(e)},`addLoop`),addMessage:n(function(e){this.messages.push(e)},`addMessage`),addNote:n(function(e){this.notes.push(e)},`addNote`),lastActor:n(function(){return this.actors[this.actors.length-1]},`lastActor`),lastLoop:n(function(){return this.loops[this.loops.length-1]},`lastLoop`),lastMessage:n(function(){return this.messages[this.messages.length-1]},`lastMessage`),lastNote:n(function(){return this.notes[this.notes.length-1]},`lastNote`),actors:[],boxes:[],loops:[],messages:[],notes:[]},init:n(function(){this.sequenceItems=[],this.activations=[],this.models.clear(),this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0,tt(v())},`init`),updateVal:n(function(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])},`updateVal`),updateBounds:n(function(e,t,r,i){let a=this,o=0;function s(s){return n(function(n){o++;let c=a.sequenceItems.length-o+1;a.updateVal(n,`starty`,t-c*Z.boxMargin,Math.min),a.updateVal(n,`stopy`,i+c*Z.boxMargin,Math.max),a.updateVal(Q.data,`startx`,e-c*Z.boxMargin,Math.min),a.updateVal(Q.data,`stopx`,r+c*Z.boxMargin,Math.max),s!==`activation`&&(a.updateVal(n,`startx`,e-c*Z.boxMargin,Math.min),a.updateVal(n,`stopx`,r+c*Z.boxMargin,Math.max),a.updateVal(Q.data,`starty`,t-c*Z.boxMargin,Math.min),a.updateVal(Q.data,`stopy`,i+c*Z.boxMargin,Math.max))},`updateItemBounds`)}n(s,`updateFn`),this.sequenceItems.forEach(s()),this.activations.forEach(s(`activation`))},`updateBounds`),insert:n(function(e,t,n,r){let i=h.getMin(e,n),a=h.getMax(e,n),o=h.getMin(t,r),s=h.getMax(t,r);this.updateVal(Q.data,`startx`,i,Math.min),this.updateVal(Q.data,`starty`,o,Math.min),this.updateVal(Q.data,`stopx`,a,Math.max),this.updateVal(Q.data,`stopy`,s,Math.max),this.updateBounds(i,o,a,s)},`insert`),newActivation:n(function(e,t,n){let r=n.get(e.from),i=nt(e.from).length||0,a=r.x+r.width/2+(i-1)*Z.activationWidth/2;this.activations.push({startx:a,starty:this.verticalPos+2,stopx:a+Z.activationWidth,stopy:void 0,actor:e.from,anchored:X.anchorElement(t)})},`newActivation`),endActivation:n(function(e){let t=this.activations.map(function(e){return e.actor}).lastIndexOf(e.from);return this.activations.splice(t,1)[0]},`endActivation`),createLoop:n(function(e={message:void 0,wrap:!1,width:void 0},t){return{startx:void 0,starty:this.verticalPos,stopx:void 0,stopy:void 0,title:e.message,wrap:e.wrap,width:e.width,height:0,fill:t}},`createLoop`),newLoop:n(function(e={message:void 0,wrap:!1,width:void 0},t){this.sequenceItems.push(this.createLoop(e,t))},`newLoop`),endLoop:n(function(){return this.sequenceItems.pop()},`endLoop`),isLoopOverlap:n(function(){return this.sequenceItems.length?this.sequenceItems[this.sequenceItems.length-1].overlap:!1},`isLoopOverlap`),addSectionToLoop:n(function(e){let t=this.sequenceItems.pop();t.sections=t.sections||[],t.sectionTitles=t.sectionTitles||[],t.sections.push({y:Q.getVerticalPos(),height:0}),t.sectionTitles.push(e),this.sequenceItems.push(t)},`addSectionToLoop`),saveVerticalPos:n(function(){this.isLoopOverlap()&&(this.savedVerticalPos=this.verticalPos)},`saveVerticalPos`),resetVerticalPos:n(function(){this.isLoopOverlap()&&(this.verticalPos=this.savedVerticalPos)},`resetVerticalPos`),bumpVerticalPos:n(function(e){this.verticalPos+=e,this.data.stopy=h.getMax(this.data.stopy,this.verticalPos)},`bumpVerticalPos`),getVerticalPos:n(function(){return this.verticalPos},`getVerticalPos`),getBounds:n(function(){return{bounds:this.data,models:this.models}},`getBounds`)},Ge=n(async function(e,t,n){Q.bumpVerticalPos(Z.boxMargin),t.height=Z.boxMargin,t.starty=Q.getVerticalPos();let i=j();i.x=t.startx,i.y=t.starty,i.width=t.width||Z.width,i.class=`note`;let a=e.append(`g`);a.attr(`data-et`,`note`),a.attr(`data-id`,`i`+n);let o=X.drawRect(a,i),s=D();s.x=t.startx,s.y=t.starty,s.width=i.width,s.dy=`1em`,s.text=t.message,s.class=`noteText`,s.fontFamily=Z.noteFontFamily,s.fontSize=Z.noteFontSize,s.fontWeight=Z.noteFontWeight,s.anchor=Z.noteAlign,s.textMargin=Z.noteMargin,s.valign=`center`;let c=r(s.text)?await ye(a,s):W(a,s),l=Math.round(c.map(e=>(e._groups||e)[0][0].getBBox().height).reduce((e,t)=>e+t));o.attr(`height`,l+2*Z.noteMargin),t.height+=l+2*Z.noteMargin,Q.bumpVerticalPos(l+2*Z.noteMargin),t.stopy=t.starty+l+2*Z.noteMargin,t.stopx=t.startx+i.width,Q.insert(t.startx,t.starty,t.stopx,t.stopy),Q.models.addNote(t)},`drawNote`),Ke=n(function(e,t,r,i,a,o,s){let c=i.db.getActors(),l=c.get(t.from),u=c.get(t.to),d=r.sequenceVisible,f=l.x+l.width/2,p=u.x+u.width/2,m=f<=p,h=mt(t,i),g=e.append(`g`),_=n((e,t)=>{let n=e?16.5:-16.5;return t?-n:n},`getCircleOffset`),v=n(e=>{g.append(`circle`).attr(`cx`,e).attr(`cy`,s).attr(`r`,5).attr(`width`,10).attr(`height`,10)},`drawCircle`),{CENTRAL_CONNECTION:y,CENTRAL_CONNECTION_REVERSE:b,CENTRAL_CONNECTION_DUAL:x}=i.db.LINETYPE;if(d)switch(t.centralConnection){case y:h&&(p+=_(m,!0));break;case b:h||(f+=_(m,!1));break;case x:h?p+=_(m,!0):f+=_(m,!1)}switch(t.centralConnection){case y:v(p);break;case b:v(f);break;case x:v(f),v(p)}},`drawCentralConnection`),qe=n(e=>({fontFamily:e.messageFontFamily,fontSize:e.messageFontSize,fontWeight:e.messageFontWeight}),`messageFont`),Je=n(e=>({fontFamily:e.noteFontFamily,fontSize:e.noteFontSize,fontWeight:e.noteFontWeight}),`noteFont`),Ye=n(e=>({fontFamily:e.actorFontFamily,fontSize:e.actorFontSize,fontWeight:e.actorFontWeight}),`actorFont`);async function Xe(e,t){Q.bumpVerticalPos(10);let{startx:n,stopx:i,message:a}=t,o=h.splitBreaks(a).length,s=r(a),c=s?await f(a,v()):S.calculateTextDimensions(a,qe(Z));if(!s){let e=c.height/o;t.height+=e,Q.bumpVerticalPos(e)}let l,u=c.height-10,d=c.width;if(n===i){l=Q.getVerticalPos()+u,Z.rightAngles||(u+=Z.boxMargin,l=Q.getVerticalPos()+u),u+=30;let e=h.getMax(d/2,Z.width/2);Q.insert(n-e,Q.getVerticalPos()-10+u,i+e,Q.getVerticalPos()+30+u)}else u+=Z.boxMargin,l=Q.getVerticalPos()+u,Q.insert(n,l-10,i,l);return Q.bumpVerticalPos(u),t.height+=u,t.stopy=t.starty+t.height,Q.insert(t.fromBounds,t.starty,t.toBounds,t.stopy),l}n(Xe,`boundMessage`);var Ze=n(async function(e,t,n,i,a,o){let{startx:c,stopx:l,starty:u,message:d,type:f,sequenceIndex:p,sequenceVisible:m}=t,g=S.calculateTextDimensions(d,qe(Z)),_=D();_.x=Math.min(c,l),_.y=u+10,_.width=Math.abs(l-c),_.class=`messageText`,_.dy=`1em`,_.text=d,_.fontFamily=Z.messageFontFamily,_.fontSize=Z.messageFontSize,_.fontWeight=Z.messageFontWeight,_.anchor=Z.messageAlign,_.valign=`center`,_.textMargin=Z.wrapPadding,_.tspan=!1,r(_.text)?await ye(e,_,{startx:c,stopx:l,starty:n}):W(e,_);let v=g.width,y;if(c===l){let r=m||Z.showSequenceNumbers,o=mt(a,i),s=ht(a,i),u=c+(r&&(o||s)?10:0);y=Z.rightAngles?e.append(`path`).attr(`d`,`M ${u},${n} H ${c+h.getMax(Z.width/2,v/2)} V ${n+25} H ${c}`):e.append(`path`).attr(`d`,`M `+u+`,`+n+` C `+(u+60)+`,`+(n-10)+` `+(c+60)+`,`+(n+30)+` `+c+`,`+(n+20)),ft(a,i)&&Ke(e,a,t,i,c,l,n)}else y=e.append(`line`),y.attr(`x1`,c),y.attr(`y1`,n),y.attr(`x2`,l),y.attr(`y2`,n),ft(a,i)&&Ke(e,a,t,i,c,l,n);f===i.db.LINETYPE.DOTTED||f===i.db.LINETYPE.DOTTED_CROSS||f===i.db.LINETYPE.DOTTED_POINT||f===i.db.LINETYPE.DOTTED_OPEN||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED||f===i.db.LINETYPE.SOLID_TOP_DOTTED||f===i.db.LINETYPE.SOLID_BOTTOM_DOTTED||f===i.db.LINETYPE.STICK_TOP_DOTTED||f===i.db.LINETYPE.STICK_BOTTOM_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED?(y.style(`stroke-dasharray`,`3, 3`),y.attr(`class`,`messageLine1`)):y.attr(`class`,`messageLine0`),y.attr(`data-et`,`message`),y.attr(`data-id`,`i`+t.id),y.attr(`data-from`,t.from),y.attr(`data-to`,t.to);let b=``;if(Z.arrowMarkerAbsolute&&(b=s(!0)),y.attr(`stroke-width`,2),y.attr(`stroke`,`none`),y.style(`fill`,`none`),(f===i.db.LINETYPE.SOLID_TOP||f===i.db.LINETYPE.SOLID_TOP_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-solidTopArrowHead)`),(f===i.db.LINETYPE.SOLID_BOTTOM||f===i.db.LINETYPE.SOLID_BOTTOM_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-solidBottomArrowHead)`),(f===i.db.LINETYPE.STICK_TOP||f===i.db.LINETYPE.STICK_TOP_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-stickTopArrowHead)`),(f===i.db.LINETYPE.STICK_BOTTOM||f===i.db.LINETYPE.STICK_BOTTOM_DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-stickBottomArrowHead)`),(f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-solidBottomArrowHead)`),(f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-solidTopArrowHead)`),(f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-stickBottomArrowHead)`),(f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED)&&y.attr(`marker-start`,`url(`+b+`#`+o+`-stickTopArrowHead)`),(f===i.db.LINETYPE.SOLID||f===i.db.LINETYPE.DOTTED)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-arrowhead)`),(f===i.db.LINETYPE.BIDIRECTIONAL_SOLID||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED)&&(y.attr(`marker-start`,`url(`+b+`#`+o+`-arrowhead)`),y.attr(`marker-end`,`url(`+b+`#`+o+`-arrowhead)`)),(f===i.db.LINETYPE.SOLID_POINT||f===i.db.LINETYPE.DOTTED_POINT)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-filled-head)`),(f===i.db.LINETYPE.SOLID_CROSS||f===i.db.LINETYPE.DOTTED_CROSS)&&y.attr(`marker-end`,`url(`+b+`#`+o+`-crosshead)`),m||Z.showSequenceNumbers){let r=f===i.db.LINETYPE.BIDIRECTIONAL_SOLID||f===i.db.LINETYPE.BIDIRECTIONAL_DOTTED,s=f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE||f===i.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE||f===i.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,u=ft(a,i),d=c,m=l;r?(cc?m=l-12:(m=l-6,d+=a?.centralConnection===i.db.LINETYPE.CENTRAL_CONNECTION_DUAL||a?.centralConnection===i.db.LINETYPE.CENTRAL_CONNECTION_REVERSE?-7.5:0),m+=u?15:0,y.attr(`x2`,m),y.attr(`x1`,d)):y.attr(`x1`,c+6);let h=0,g=c===l,_=c<=l;h=g?t.fromBounds+1:s?_?t.toBounds-1:t.fromBounds+1:_?t.fromBounds+1:t.toBounds-1;let v=`12px`,x=p.toString().length;x>5?v=`7px`:x>3&&(v=`9px`),e.append(`line`).attr(`x1`,h).attr(`y1`,n).attr(`x2`,h).attr(`y2`,n).attr(`stroke-width`,0).attr(`marker-start`,`url(`+b+`#`+o+`-sequencenumber)`),e.append(`text`).attr(`x`,h).attr(`y`,n+4).attr(`font-family`,`sans-serif`).attr(`font-size`,v).attr(`text-anchor`,`middle`).attr(`class`,`sequenceNumber`).text(p)}},`drawMessage`),Qe=n(function(e,t,n,r,i,a,o){let s=0,c=0,l,u=0;for(let e of r){let r=t.get(e),a=r.box;l&&l!=a&&(o||Q.models.addBox(l),c+=Z.boxMargin+l.margin),a&&a!=l&&(o||(a.x=s+c,a.y=i),c+=a.margin),r.width=h.getMax(r.width||Z.width,Z.width),r.height=h.getMax(r.height||Z.height,Z.height),r.margin=r.margin||Z.actorMargin,u=h.getMax(u,r.height),n.get(r.name)&&(c+=r.width/2),r.x=s+c,r.starty=Q.getVerticalPos(),Q.insert(r.x,i,r.x+r.width,r.height),s+=r.width+c,r.box&&(r.box.width=s+a.margin-r.box.x),c=r.margin,l=r.box,Q.models.addActor(r)}l&&!o&&Q.models.addBox(l),Q.bumpVerticalPos(u)},`addActorRenderingData`),$e=n(async function(e,t,n,r,i,a,o){if(r){let r=0;Q.bumpVerticalPos(Z.boxMargin*2);for(let s of n){let n=t.get(s);n.stopy||=Q.getVerticalPos();let c=await X.drawActor(e,n,Z,!0,i,a,o);r=h.getMax(r,c)}Q.bumpVerticalPos(r+Z.boxMargin)}else for(let r of n){let n=t.get(r);await X.drawActor(e,n,Z,!1,i,a,o)}},`drawActors`),et=n(function(e,t,n,r){let i=0,a=0;for(let o of n){let n=t.get(o),s=st(n),c=X.drawPopup(e,n,s,Z,Z.forceMenus,r);c.height>i&&(i=c.height),c.width+n.x>a&&(a=c.width+n.x)}return{maxHeight:i,maxWidth:a}},`drawActorsPopup`),tt=n(function(e){m(Z,e),e.fontFamily&&(Z.actorFontFamily=Z.noteFontFamily=Z.messageFontFamily=e.fontFamily),e.fontSize&&(Z.actorFontSize=Z.noteFontSize=Z.messageFontSize=e.fontSize),e.fontWeight&&(Z.actorFontWeight=Z.noteFontWeight=Z.messageFontWeight=e.fontWeight)},`setConf`),nt=n(function(e){return Q.activations.filter(function(t){return t.actor===e})},`actorActivations`),rt=n(function(e,t){let n=t.get(e),r=nt(e);return[r.reduce(function(e,t){return h.getMin(e,t.startx)},n.x+n.width/2-1),r.reduce(function(e,t){return h.getMax(e,t.stopx)},n.x+n.width/2+1)]},`activationBounds`);function $(t,n,r,i,a){Q.bumpVerticalPos(r);let o=i;if(n.id&&n.message&&t[n.id]){let r=t[n.id].width,a=qe(Z);n.message=S.wrapLabel(`[${n.message}]`,r-2*Z.wrapPadding,a),n.width=r,n.wrap=!0;let s=S.calculateTextDimensions(n.message,a),c=h.getMax(s.height,Z.labelBoxHeight);o=i+c,e.debug(`${c} - ${n.message}`)}a(n),Q.bumpVerticalPos(o)}n($,`adjustLoopHeightForWrap`);function it(e,t,r,i,a,o,s){function c(n,r){n.x{e.add(t.from),e.add(t.to)}),x=x.filter(t=>e.has(t))}let D=new Map(x.map((e,t)=>[g.get(e)?.name??e,t]));Qe(h,g,_,x,0,S,!1);let O=await _t(S,g,E,o);X.insertArrowHead(h,i),X.insertArrowCrossHead(h,i),X.insertArrowFilledHead(h,i),X.insertSequenceNumber(h,i),X.insertSolidTopArrowHead(h,i),X.insertSolidBottomArrowHead(h,i),X.insertStickTopArrowHead(h,i),X.insertStickBottomArrowHead(h,i),l===`neo`&&X.insertDropShadow(h,Z,i);function k(e,t){let n=Q.endActivation(e);n.starty+18>t&&(n.starty=t-6,t+=12),X.drawActivation(h,n,t,Z,nt(e.from).length,o,D),Q.insert(n.startx,t-10,n.stopx,t)}n(k,`activeEnd`);let A=1,j=1,M=[],N=[],P=0;for(let t of S){let n,r,i;switch(t.type){case o.db.LINETYPE.NOTE:Q.resetVerticalPos(),r=t.noteModel,await Ge(h,r,t.id);break;case o.db.LINETYPE.ACTIVE_START:Q.newActivation(t,h,g);break;case o.db.LINETYPE.CENTRAL_CONNECTION:Q.newActivation(t,h,g);break;case o.db.LINETYPE.CENTRAL_CONNECTION_REVERSE:Q.newActivation(t,h,g);break;case o.db.LINETYPE.ACTIVE_END:k(t,Q.getVerticalPos());break;case o.db.LINETYPE.LOOP_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.LOOP_END:n=Q.endLoop(),await X.drawLoop(h,n,`loop`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.RECT_START:$(O,t,Z.boxMargin,Z.boxMargin,e=>{let t=e.message;t||=u?.rectBkgColor||u?.actorBkg||`rgba(128, 128, 128, 0.5)`,Q.newLoop(void 0,t)});break;case o.db.LINETYPE.RECT_END:n=Q.endLoop(),N.push(n),Q.models.addLoop(n),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos());break;case o.db.LINETYPE.OPT_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.OPT_END:n=Q.endLoop(),await X.drawLoop(h,n,`opt`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.ALT_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.ALT_ELSE:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.ALT_END:n=Q.endLoop(),await X.drawLoop(h,n,`alt`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.PAR_START:case o.db.LINETYPE.PAR_OVER_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e)),Q.saveVerticalPos();break;case o.db.LINETYPE.PAR_AND:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.PAR_END:n=Q.endLoop(),await X.drawLoop(h,n,`par`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.AUTONUMBER:A=t.message.start||A,j=t.message.step||j,t.message.visible?o.db.enableSequenceNumbers():o.db.disableSequenceNumbers();break;case o.db.LINETYPE.CRITICAL_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.CRITICAL_OPTION:$(O,t,Z.boxMargin+Z.boxTextMargin,Z.boxMargin,e=>Q.addSectionToLoop(e));break;case o.db.LINETYPE.CRITICAL_END:n=Q.endLoop(),await X.drawLoop(h,n,`critical`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;case o.db.LINETYPE.BREAK_START:$(O,t,Z.boxMargin,Z.boxMargin+Z.boxTextMargin,e=>Q.newLoop(e));break;case o.db.LINETYPE.BREAK_END:n=Q.endLoop(),await X.drawLoop(h,n,`break`,Z,t),Q.bumpVerticalPos(n.stopy-Q.getVerticalPos()),Q.models.addLoop(n);break;default:try{i=t.msgModel,i.starty=Q.getVerticalPos(),i.sequenceIndex=A,i.sequenceVisible=o.db.showSequenceNumbers(),i.id=t.id,i.from=t.from,i.to=t.to;let e=await Xe(h,i);it(t,i,e,P,g,_,y),M.push({messageModel:i,lineStartY:e,msg:t}),Q.models.addMessage(i)}catch(t){e.error(`error while drawing message`,t)}}[o.db.LINETYPE.SOLID_OPEN,o.db.LINETYPE.DOTTED_OPEN,o.db.LINETYPE.SOLID,o.db.LINETYPE.SOLID_TOP,o.db.LINETYPE.SOLID_BOTTOM,o.db.LINETYPE.STICK_TOP,o.db.LINETYPE.STICK_BOTTOM,o.db.LINETYPE.SOLID_TOP_DOTTED,o.db.LINETYPE.SOLID_BOTTOM_DOTTED,o.db.LINETYPE.STICK_TOP_DOTTED,o.db.LINETYPE.STICK_BOTTOM_DOTTED,o.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,o.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE,o.db.LINETYPE.STICK_ARROW_TOP_REVERSE,o.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE,o.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,o.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,o.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED,o.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,o.db.LINETYPE.DOTTED,o.db.LINETYPE.SOLID_CROSS,o.db.LINETYPE.DOTTED_CROSS,o.db.LINETYPE.SOLID_POINT,o.db.LINETYPE.DOTTED_POINT,o.db.LINETYPE.BIDIRECTIONAL_SOLID,o.db.LINETYPE.BIDIRECTIONAL_DOTTED].includes(t.type)&&(A=Math.round((A+j)*100)/100),P++}e.debug(`createdActors`,_),e.debug(`destroyedActors`,y),await $e(h,g,x,!1,i,o,D);for(let e of M)await Ze(h,e.messageModel,e.lineStartY,o,e.msg,i);Z.mirrorActors&&await $e(h,g,x,!0,i,o,D),N.forEach(e=>X.drawBackgroundRect(h,e)),xe(h,g,x,Z);for(let e of Q.models.boxes){e.height=Q.getVerticalPos()-e.y,Q.insert(e.x,e.y,e.x+e.width,e.height);let t=Z.boxMargin*2;e.startx=e.x-t,e.starty=e.y-t*.25,e.stopx=e.startx+e.width+2*t,e.stopy=e.starty+e.height+t*.75,e.stroke=`rgb(0,0,0, 0.5)`,X.drawBox(h,e,Z)}w&&Q.bumpVerticalPos(Z.boxMargin);let F=et(h,g,x,m),{bounds:I}=Q.getBounds();I.startx===void 0&&(I.startx=0),I.starty===void 0&&(I.starty=0),I.stopx===void 0&&(I.stopx=0),I.stopy===void 0&&(I.stopy=0);let ee=I.stopy-I.starty;ee{let n=qe(Z),r=t.actorKeys.reduce((t,n)=>t+=e.get(n).width+(e.get(n).margin||0),0),i=Z.boxMargin*8;r+=i,r-=2*Z.boxTextMargin,t.wrap&&(t.name=S.wrapLabel(t.name,r-2*Z.wrapPadding,n));let o=S.calculateTextDimensions(t.name,n);a=h.getMax(o.height,a);let s=h.getMax(r,o.width+2*Z.wrapPadding);if(t.margin=Z.boxTextMargin,re.textMaxHeight=a),h.getMax(i,Z.height)}n(ct,`calculateActorMargins`);var lt=n(async function(t,n,i){let a=n.get(t.from),o=n.get(t.to),s=a.x,c=o.x,l=t.wrap&&t.message,u=r(t.message)?await f(t.message,v()):S.calculateTextDimensions(l?S.wrapLabel(t.message,Z.width,Je(Z)):t.message,Je(Z)),d={width:l?Z.width:h.getMax(Z.width,u.width+2*Z.noteMargin),height:0,startx:a.x,stopx:0,starty:0,stopy:0,message:t.message};return t.placement===i.db.PLACEMENT.RIGHTOF?(d.width=l?h.getMax(Z.width,u.width):h.getMax(a.width/2+o.width/2,u.width+2*Z.noteMargin),d.startx=s+(a.width+Z.actorMargin)/2):t.placement===i.db.PLACEMENT.LEFTOF?(d.width=l?h.getMax(Z.width,u.width+2*Z.noteMargin):h.getMax(a.width/2+o.width/2,u.width+2*Z.noteMargin),d.startx=s-d.width+(a.width-Z.actorMargin)/2):t.to===t.from?(u=S.calculateTextDimensions(l?S.wrapLabel(t.message,h.getMax(Z.width,a.width),Je(Z)):t.message,Je(Z)),d.width=l?h.getMax(Z.width,a.width):h.getMax(a.width,Z.width,u.width+2*Z.noteMargin),d.startx=s+(a.width-d.width)/2):(d.width=Math.abs(s+a.width/2-(c+o.width/2))+Z.actorMargin,d.startx=s2,p=n(e=>l?-e:e,`adjustValue`);e.from===e.to?d=u:(e.activate&&!f&&(d+=p(Z.activationWidth/2-1)),[r.db.LINETYPE.SOLID_OPEN,r.db.LINETYPE.DOTTED_OPEN,r.db.LINETYPE.STICK_TOP,r.db.LINETYPE.STICK_BOTTOM,r.db.LINETYPE.STICK_TOP_DOTTED,r.db.LINETYPE.STICK_BOTTOM_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.STICK_ARROW_TOP_REVERSE,r.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE,r.db.LINETYPE.STICK_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.STICK_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE].includes(e.type)||(d+=p(3)),[r.db.LINETYPE.BIDIRECTIONAL_SOLID,r.db.LINETYPE.BIDIRECTIONAL_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE_DOTTED,r.db.LINETYPE.SOLID_ARROW_TOP_REVERSE,r.db.LINETYPE.SOLID_ARROW_BOTTOM_REVERSE].includes(e.type)&&(u-=p(3)));let m=[a,o,s,c],g=Math.abs(u-d);e.wrap&&e.message&&(e.message=S.wrapLabel(e.message,h.getMax(g+2*Z.wrapPadding,Z.width),qe(Z)));let _=S.calculateTextDimensions(e.message,qe(Z));return{width:h.getMax(e.wrap?0:_.width+2*Z.wrapPadding,g+2*Z.wrapPadding,Z.width),height:0,startx:u,stopx:d,starty:0,stopy:0,message:e.message,type:e.type,wrap:e.wrap,fromBounds:Math.min.apply(null,m),toBounds:Math.max.apply(null,m)}},`buildMessageModel`),_t=n(async function(t,n,r,i){let a={},o=[],s,c,l;for(let e of t){switch(e.type){case i.db.LINETYPE.LOOP_START:case i.db.LINETYPE.ALT_START:case i.db.LINETYPE.OPT_START:case i.db.LINETYPE.PAR_START:case i.db.LINETYPE.PAR_OVER_START:case i.db.LINETYPE.CRITICAL_START:case i.db.LINETYPE.BREAK_START:o.push({id:e.id,msg:e.message,from:2**53-1,to:-(2**53-1),width:0});break;case i.db.LINETYPE.ALT_ELSE:case i.db.LINETYPE.PAR_AND:case i.db.LINETYPE.CRITICAL_OPTION:e.message&&(s=o.pop(),a[s.id]=s,a[e.id]=s,o.push(s));break;case i.db.LINETYPE.LOOP_END:case i.db.LINETYPE.ALT_END:case i.db.LINETYPE.OPT_END:case i.db.LINETYPE.PAR_END:case i.db.LINETYPE.CRITICAL_END:case i.db.LINETYPE.BREAK_END:s=o.pop(),a[s.id]=s;break;case i.db.LINETYPE.ACTIVE_START:{let t=n.get(e.from?e.from:e.to.actor),r=nt(e.from?e.from:e.to.actor).length,i=t.x+t.width/2+(r-1)*Z.activationWidth/2,a={startx:i,stopx:i+Z.activationWidth,actor:e.from,enabled:!0};Q.activations.push(a)}break;case i.db.LINETYPE.ACTIVE_END:{let t=Q.activations.map(e=>e.actor).lastIndexOf(e.from);Q.activations.splice(t,1).splice(0,1)}}e.placement===void 0?(l=gt(e,n,i),e.msgModel=l,l.startx&&l.stopx&&o.length>0&&o.forEach(t=>{if(s=t,l.startx===l.stopx){let t=n.get(e.from),r=n.get(e.to);s.from=h.getMin(t.x-l.width/2,t.x-t.width/2,s.from),s.to=h.getMax(r.x+l.width/2,r.x+t.width/2,s.to),s.width=h.getMax(s.width,Math.abs(s.to-s.from))-Z.labelBoxWidth}else s.from=h.getMin(l.startx,s.from),s.to=h.getMax(l.stopx,s.to),s.width=h.getMax(s.width,l.width)-Z.labelBoxWidth})):(c=await lt(e,n,i),e.noteModel=c,o.forEach(e=>{s=e,s.from=h.getMin(s.from,c.startx),s.to=h.getMax(s.to,c.startx+c.width),s.width=h.getMax(s.width,Math.abs(s.from-s.to))-Z.labelBoxWidth}))}return Q.activations=[],e.debug(`Loop type widths:`,a),a},`calculateLoopBounds`),vt={parser:F,get db(){return new ne},renderer:{bounds:Q,drawActors:$e,drawActorsPopup:et,setConf:tt,draw:at},styles:re,init:n(e=>{e.sequence||={},e.wrap&&(e.sequence.wrap=e.wrap,a({sequence:{wrap:e.wrap}}))},`init`)};export{vt as diagram}; \ No newline at end of file diff --git a/www/assets/sizeCapture-INFHLROL-B0uUizjq.js b/www/assets/sizeCapture-INFHLROL-B0uUizjq.js new file mode 100644 index 0000000..ea2efbd --- /dev/null +++ b/www/assets/sizeCapture-INFHLROL-B0uUizjq.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=1;function n(){if(!(typeof globalThis>`u`))return globalThis}e(n,`getCaptureGlobal`);function r(){return!!n()?.mermaidCaptureSizes}e(r,`shouldCaptureSizes`);function i(){return typeof location>`u`?`browser-dev`:`${location.pathname}${location.search}`}e(i,`capturedFromLocation`);function a(e,t){let r=n();if(!r)return;let i=t.node(),a=((i&&`ownerSVGElement`in i?i.ownerSVGElement:null)??i)?.id??`(unknown)`;r.mermaidCapturedSizes??=[];let o={svgId:a,sizes:e};r.mermaidCapturedSizes.push(o),r.mermaidLastCapturedSizes=o}e(a,`emitCapturedSizes`);function o(e,n){let r=[];for(let e of n.nodes)e.isGroup||r.push({id:e.id,width:e.width??0,height:e.height??0});r.length!==0&&a({metadata:{captureVersion:t,capturedAt:new Date().toISOString(),capturedFrom:i()},nodes:r},e)}e(o,`captureNodeSizes`);export{o as captureNodeSizes}; \ No newline at end of file diff --git a/www/assets/src-D_iIdUkB.js b/www/assets/src-D_iIdUkB.js new file mode 100644 index 0000000..9535405 --- /dev/null +++ b/www/assets/src-D_iIdUkB.js @@ -0,0 +1 @@ +import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";var t=Object.create,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.getPrototypeOf,o=Object.prototype.hasOwnProperty,s=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),c=(e,t,a,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=i(t),l=0,u=c.length,d;lt[e]).bind(null,d),enumerable:!(s=r(t,d))||s.enumerable});return e},l=(e,r,i)=>(i=e==null?{}:t(a(e)),c(r||!e||!e.__esModule||!o.call(e,`default`)?n(i,`default`,{value:e,enumerable:!0}):i,e)),u=(e=>typeof require<`u`?require:typeof Proxy<`u`?new Proxy(e,{get:(e,t)=>(typeof require<`u`?require:e)[t]}):e)(function(e){if(typeof require<`u`)return require.apply(this,arguments);throw Error('Calling `require` for "'+e+"\" in an environment that doesn't expose the `require` function. See https://rolldown.rs/in-depth/bundling-cjs#require-external-modules for more details.")}),d=s(((e,t)=>{(function(n,r){typeof e==`object`&&t!==void 0?t.exports=r():typeof define==`function`&&define.amd?define(r):(n=typeof globalThis<`u`?globalThis:n||self).dayjs=r()})(e,(function(){var e=1e3,t=6e4,n=36e5,r=`millisecond`,i=`second`,a=`minute`,o=`hour`,s=`day`,c=`week`,l=`month`,u=`quarter`,d=`year`,f=`date`,p=`Invalid Date`,m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:`en`,weekdays:`Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday`.split(`_`),months:`January_February_March_April_May_June_July_August_September_October_November_December`.split(`_`),ordinal:function(e){var t=[`th`,`st`,`nd`,`rd`],n=e%100;return`[`+e+(t[(n-20)%10]||t[n]||t[0])+`]`}},_=function(e,t,n){var r=String(e);return!r||r.length>=t?e:``+Array(t+1-r.length).join(n)+e},v={s:_,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?`+`:`-`)+_(r,2,`0`)+`:`+_(i,2,`0`)},m:function e(t,n){if(t.date()1)return e(o[0])}else{var s=t.name;b[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},C=function(e,t){if(x(e))return e.clone();var n=typeof t==`object`?t:{};return n.date=e,n.args=arguments,new T(n)},w=v;w.l=S,w.i=x,w.w=function(e,t){return C(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var T=function(){function g(e){this.$L=S(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[ee]=!0}var _=g.prototype;return _.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(t===null)return new Date(NaN);if(w.u(t))return new Date;if(t instanceof Date)return new Date(t);if(typeof t==`string`&&!/Z$/i.test(t)){var r=t.match(m);if(r){var i=r[2]-1||0,a=(r[7]||`0`).substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(t)}(e),this.init()},_.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},_.$utils=function(){return w},_.isValid=function(){return this.$d.toString()!==p},_.isSame=function(e,t){var n=C(e);return this.startOf(t)<=n&&n<=this.endOf(t)},_.isAfter=function(e,t){return C(e){},`trace`),debug:e((...e)=>{},`debug`),info:e((...e)=>{},`info`),warn:e((...e)=>{},`warn`),error:e((...e)=>{},`error`),fatal:e((...e)=>{},`fatal`)},h=e(function(e=`fatal`){let t=p.fatal;typeof e==`string`?e.toLowerCase()in p&&(t=p[e]):typeof e==`number`&&(t=e),m.trace=()=>{},m.debug=()=>{},m.info=()=>{},m.warn=()=>{},m.error=()=>{},m.fatal=()=>{},t<=p.fatal&&(m.fatal=console.error?console.error.bind(console,g(`FATAL`),`color: orange`):console.log.bind(console,`\x1B[35m`,g(`FATAL`))),t<=p.error&&(m.error=console.error?console.error.bind(console,g(`ERROR`),`color: orange`):console.log.bind(console,`\x1B[31m`,g(`ERROR`))),t<=p.warn&&(m.warn=console.warn?console.warn.bind(console,g(`WARN`),`color: orange`):console.log.bind(console,`\x1B[33m`,g(`WARN`))),t<=p.info&&(m.info=console.info?console.info.bind(console,g(`INFO`),`color: lightblue`):console.log.bind(console,`\x1B[34m`,g(`INFO`))),t<=p.debug&&(m.debug=console.debug?console.debug.bind(console,g(`DEBUG`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,g(`DEBUG`))),t<=p.trace&&(m.trace=console.debug?console.debug.bind(console,g(`TRACE`),`color: lightgreen`):console.log.bind(console,`\x1B[32m`,g(`TRACE`)))},`setLogLevel`),g=e(e=>`%c${(0,f.default)().format(`ss.SSS`)} : ${e} : `,`format`),_={value:()=>{}};function v(){for(var e=0,t=arguments.length,n={},r;e=0&&(n=e.slice(r+1),e=e.slice(0,r)),e&&!t.hasOwnProperty(e))throw Error(`unknown type: `+e);return{type:e,name:n}})}y.prototype=v.prototype={constructor:y,on:function(e,t){var n=this._,r=b(e+``,n),i,a=-1,o=r.length;if(arguments.length<2){for(;++a0)for(var n=Array(i),r=0,i,a;r=0&&(t=e.slice(0,n))!==`xmlns`&&(e=e.slice(n+1)),S.hasOwnProperty(t)?{space:S[t],local:e}:e}function w(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===`http://www.w3.org/1999/xhtml`&&t.documentElement.namespaceURI===`http://www.w3.org/1999/xhtml`?t.createElement(e):t.createElementNS(n,e)}}function T(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function te(e){var t=C(e);return(t.local?T:w)(t)}function ne(){}function re(e){return e==null?ne:function(){return this.querySelector(e)}}function ie(e){typeof e!=`function`&&(e=re(e));for(var t=this._groups,n=t.length,r=Array(n),i=0;i=v&&(v=_+1);!(b=g[v])&&++v=0;)(o=r[i])&&(a&&o.compareDocumentPosition(a)^4&&a.parentNode.insertBefore(o,a),a=o);return this}function Ne(e){e||=Pe;function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}for(var n=this._groups,r=n.length,i=Array(r),a=0;at?1:e>=t?0:NaN}function Fe(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function Ie(){return Array.from(this)}function Le(){for(var e=this._groups,t=0,n=e.length;t1?this.each((t==null?Ye:typeof t==`function`?Ze:Xe)(e,t,n??``)):D(this.node(),e)}function D(e,t){return e.style.getPropertyValue(t)||Je(e).getComputedStyle(e,null).getPropertyValue(t)}function $e(e){return function(){delete this[e]}}function et(e,t){return function(){this[e]=t}}function tt(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function nt(e,t){return arguments.length>1?this.each((t==null?$e:typeof t==`function`?tt:et)(e,t)):this.node()[e]}function rt(e){return e.trim().split(/^|\s+/)}function it(e){return e.classList||new at(e)}function at(e){this._node=e,this._names=rt(e.getAttribute(`class`)||``)}at.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute(`class`,this._names.join(` `)))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute(`class`,this._names.join(` `)))},contains:function(e){return this._names.indexOf(e)>=0}};function ot(e,t){for(var n=it(e),r=-1,i=t.length;++r=0&&(t=e.slice(n+1),e=e.slice(0,n)),{type:e,name:t}})}function Ft(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,a;n>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?I(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?I(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=Xt.exec(e))?new L(t[1],t[2],t[3],1):(t=Zt.exec(e))?new L(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Qt.exec(e))?I(t[1],t[2],t[3],t[4]):(t=$t.exec(e))?I(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=en.exec(e))?mn(t[1],t[2]/100,t[3]/100,1):(t=tn.exec(e))?mn(t[1],t[2]/100,t[3]/100,t[4]):nn.hasOwnProperty(e)?cn(nn[e]):e===`transparent`?new L(NaN,NaN,NaN,0):null}function cn(e){return new L(e>>16&255,e>>8&255,e&255,1)}function I(e,t,n,r){return r<=0&&(e=t=n=NaN),new L(e,t,n,r)}function ln(e){return e instanceof A||(e=F(e)),e?(e=e.rgb(),new L(e.r,e.g,e.b,e.opacity)):new L}function un(e,t,n,r){return arguments.length===1?ln(e):new L(e,t,n,r??1)}function L(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Kt(L,un,qt(A,{brighter(e){return e=e==null?Jt:Jt**+e,new L(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?j:j**+e,new L(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new L(z(this.r),z(this.g),z(this.b),R(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:dn,formatHex:dn,formatHex8:fn,formatRgb:pn,toString:pn}));function dn(){return`#${B(this.r)}${B(this.g)}${B(this.b)}`}function fn(){return`#${B(this.r)}${B(this.g)}${B(this.b)}${B((isNaN(this.opacity)?1:this.opacity)*255)}`}function pn(){let e=R(this.opacity);return`${e===1?`rgb(`:`rgba(`}${z(this.r)}, ${z(this.g)}, ${z(this.b)}${e===1?`)`:`, ${e})`}`}function R(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function z(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function B(e){return e=z(e),(e<16?`0`:``)+e.toString(16)}function mn(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new V(e,t,n,r)}function hn(e){if(e instanceof V)return new V(e.h,e.s,e.l,e.opacity);if(e instanceof A||(e=F(e)),!e)return new V;if(e instanceof V)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=NaN,s=a-i,c=(a+i)/2;return s?(o=t===a?(n-r)/s+(n0&&c<1?0:o,new V(o,s,c,e.opacity)}function gn(e,t,n,r){return arguments.length===1?hn(e):new V(e,t,n,r??1)}function V(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Kt(V,gn,qt(A,{brighter(e){return e=e==null?Jt:Jt**+e,new V(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?j:j**+e,new V(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new L(vn(e>=240?e-240:e+120,i,r),vn(e,i,r),vn(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new V(_n(this.h),H(this.s),H(this.l),R(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let e=R(this.opacity);return`${e===1?`hsl(`:`hsla(`}${_n(this.h)}, ${H(this.s)*100}%, ${H(this.l)*100}%${e===1?`)`:`, ${e})`}`}}));function _n(e){return e=(e||0)%360,e<0?e+360:e}function H(e){return Math.max(0,Math.min(1,e||0))}function vn(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}var yn=e=>()=>e;function bn(e,t){return function(n){return e+n*t}}function xn(e,t,n){return e**=+n,t=t**+n-e,n=1/n,function(r){return(e+r*t)**+n}}function Sn(e,t){var n=t-e;return n?bn(e,n>180||n<-180?n-360*Math.round(n/360):n):yn(isNaN(e)?t:e)}function Cn(e){return(e=+e)==1?wn:function(t,n){return n-t?xn(t,n,e):yn(isNaN(t)?n:t)}}function wn(e,t){var n=t-e;return n?bn(e,n):yn(isNaN(e)?t:e)}var Tn=(function e(t){var n=Cn(t);function r(e,t){var r=n((e=un(e)).r,(t=un(t)).r),i=n(e.g,t.g),a=n(e.b,t.b),o=wn(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=i(t),e.b=a(t),e.opacity=o(t),e+``}}return r.gamma=e,r})(1);function U(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}var En=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Dn=new RegExp(En.source,`g`);function On(e){return function(){return e}}function kn(e){return function(t){return e(t)+``}}function An(e,t){var n=En.lastIndex=Dn.lastIndex=0,r,i,a,o=-1,s=[],c=[];for(e+=``,t+=``;(r=En.exec(e))&&(i=Dn.exec(t));)(a=i.index)>n&&(a=t.slice(n,a),s[o]?s[o]+=a:s[++o]=a),(r=r[0])===(i=i[0])?s[o]?s[o]+=i:s[++o]=i:(s[++o]=null,c.push({i:o,x:U(r,i)})),n=Dn.lastIndex;return n180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(i(n)+`rotate(`,null,r)-2,x:U(e,t)}))}function s(e,t,n,a){e===t?t&&n.push(i(n)+`skewX(`+t+r):a.push({i:n.push(i(n)+`skewX(`,null,r)-2,x:U(e,t)})}function c(e,t,n,r,a,o){if(e!==n||t!==r){var s=a.push(i(a)+`scale(`,null,`,`,null,`)`);o.push({i:s-4,x:U(e,n)},{i:s-2,x:U(t,r)})}else(n!==1||r!==1)&&a.push(i(a)+`scale(`+n+`,`+r+`)`)}return function(t,n){var r=[],i=[];return t=e(t),n=e(n),a(t.translateX,t.translateY,n.translateX,n.translateY,r,i),o(t.rotate,n.rotate,r,i),s(t.skewX,n.skewX,r,i),c(t.scaleX,t.scaleY,n.scaleX,n.scaleY,r,i),t=n=null,function(e){for(var t=-1,n=i.length,a;++t=0&&e._call.call(void 0,t),e=e._next;--W}function Qn(){K=(Wn=q.now())+Gn,W=Bn=0;try{Zn()}finally{W=0,er(),K=0}}function $n(){var e=q.now(),t=e-Wn;t>Hn&&(Gn-=t,Wn=e)}function er(){for(var e,t=Un,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Un=n);G=e,tr(r)}function tr(e){W||(Bn&&=clearTimeout(Bn),e-K>24?(e<1/0&&(Bn=setTimeout(Qn,e-q.now()-Gn)),Vn&&=clearInterval(Vn)):(Vn||=(Wn=q.now(),setInterval($n,Hn)),W=1,Kn(Qn)))}function nr(e,t,n){var r=new Yn;return t=t==null?0:+t,r.restart(n=>{r.stop(),e(n+t)},t,n),r}var rr=v(`start`,`end`,`cancel`,`interrupt`),ir=[];function J(e,t,n,r,i,a){var o=e.__transition;if(!o)e.__transition={};else if(n in o)return;or(e,n,{name:t,index:r,group:i,on:rr,tween:ir,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:0})}function ar(e,t){var n=X(e,t);if(n.state>0)throw Error(`too late; already scheduled`);return n}function Y(e,t){var n=X(e,t);if(n.state>3)throw Error(`too late; already running`);return n}function X(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw Error(`transition not found`);return n}function or(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=Xn(a,0,n.time);function a(e){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=e&&o(e-n.delay)}function o(a){var l,u,d,f;if(n.state!==1)return c();for(l in r)if(f=r[l],f.name===n.name){if(f.state===3)return nr(o);f.state===4?(f.state=6,f.timer.stop(),f.on.call(`interrupt`,e,e.__data__,f.index,f.group),delete r[l]):+l2&&r.state<5,r.state=6,r.timer.stop(),r.on.call(i?`interrupt`:`cancel`,e,e.__data__,r.index,r.group),delete n[o]}a&&delete e.__transition}}function cr(e){return this.each(function(){sr(this,e)})}function lr(e,t){var n,r;return function(){var i=Y(this,e),a=i.tween;if(a!==n){r=n=a;for(var o=0,s=r.length;o=0&&(e=e.slice(0,t)),!e||e===`start`})}function zr(e,t,n){var r,i,a=Rr(t)?ar:Y;return function(){var o=a(this,e),s=o.on;s!==r&&(i=(r=s).copy()).on(t,n),o.on=i}}function Br(e,t){var n=this._id;return arguments.length<2?X(this.node(),n).on.on(e):this.each(zr(n,e,t))}function Vr(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function Hr(){return this.on(`end.remove`,Vr(this._id))}function Ur(e){var t=this._name,n=this._id;typeof e!=`function`&&(e=re(e));for(var r=this._groups,i=r.length,a=Array(i),o=0;o":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACE`,5:`NL`,6:`SD`,14:`DESCR`,15:`-->`,16:`HIDE_EMPTY`,17:`scale`,18:`WIDTH`,19:`COMPOSIT_STATE`,20:`STRUCT_START`,21:`STRUCT_STOP`,22:`STATE_DESCR`,23:`AS`,24:`ID`,25:`FORK`,26:`JOIN`,27:`CHOICE`,28:`CONCURRENT`,29:`note`,31:`NOTE_TEXT`,33:`acc_title`,34:`acc_title_value`,35:`acc_descr`,36:`acc_descr_value`,37:`acc_descr_multiline_value`,38:`CLICK`,39:`STRING`,40:`HREF`,41:`classDef`,42:`CLASSDEF_ID`,43:`CLASSDEF_STYLEOPTS`,44:`DEFAULT`,45:`style`,46:`STYLE_IDS`,47:`STYLEDEF_STYLEOPTS`,48:`class`,49:`CLASSENTITY_IDS`,50:`STYLECLASS`,51:`direction_tb`,52:`direction_bt`,53:`direction_rl`,54:`direction_lr`,56:`;`,57:`EDGE_STATE`,58:`STYLE_SEPARATOR`,59:`left_of`,60:`right_of`},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:return r.setRootDoc(a[s]),a[s];case 4:this.$=[];break;case 5:a[s]!=`nl`&&(a[s-1].push(a[s]),this.$=a[s-1]);break;case 6:case 7:this.$=a[s];break;case 8:this.$=`nl`;break;case 12:this.$=a[s];break;case 13:let e=a[s-1];e.description=r.trimColon(a[s]),this.$=e;break;case 14:this.$={stmt:`relation`,state1:a[s-2],state2:a[s]};break;case 15:let t=r.trimColon(a[s]);this.$={stmt:`relation`,state1:a[s-3],state2:a[s-1],description:t};break;case 19:this.$={stmt:`state`,id:a[s-3],type:`default`,description:``,doc:a[s-1]};break;case 20:var c=a[s],l=a[s-2].trim();if(a[s].match(`:`)){var u=a[s].split(`:`);c=u[0],l=[l,u[1]]}this.$={stmt:`state`,id:c,type:`default`,description:l};break;case 21:this.$={stmt:`state`,id:a[s-3],type:`default`,description:a[s-5],doc:a[s-1]};break;case 22:this.$={stmt:`state`,id:a[s],type:`fork`};break;case 23:this.$={stmt:`state`,id:a[s],type:`join`};break;case 24:this.$={stmt:`state`,id:a[s],type:`choice`};break;case 25:this.$={stmt:`state`,id:r.getDividerId(),type:`divider`};break;case 26:this.$={stmt:`state`,id:a[s-1].trim(),note:{position:a[s-2].trim(),text:a[s].trim()}};break;case 29:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 30:case 31:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 32:this.$={stmt:`click`,id:a[s-3],url:a[s-2],tooltip:a[s-1]};break;case 33:this.$={stmt:`click`,id:a[s-3],url:a[s-1],tooltip:``};break;case 34:case 35:this.$={stmt:`classDef`,id:a[s-1].trim(),classes:a[s].trim()};break;case 36:this.$={stmt:`style`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 37:this.$={stmt:`applyClass`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 38:r.setDirection(`TB`),this.$={stmt:`dir`,value:`TB`};break;case 39:r.setDirection(`BT`),this.$={stmt:`dir`,value:`BT`};break;case 40:r.setDirection(`RL`),this.$={stmt:`dir`,value:`RL`};break;case 41:r.setDirection(`LR`),this.$={stmt:`dir`,value:`LR`};break;case 44:case 45:this.$={stmt:`state`,id:a[s].trim(),type:`default`,description:``};break;case 46:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``};break;case 47:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``}}},`anonymous`),table:[{3:1,4:t,5:r,6:i},{1:[3]},{3:5,4:t,5:r,6:i},{3:6,4:t,5:r,6:i},e([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],a,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,7]),e(A,[2,8]),e(A,[2,9]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12],{14:[1,40],15:[1,41]}),e(A,[2,16]),{18:[1,42]},e(A,[2,18],{20:[1,43]}),{23:[1,44]},e(A,[2,22]),e(A,[2,23]),e(A,[2,24]),e(A,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},e(A,[2,28]),{34:[1,49]},{36:[1,50]},e(A,[2,31]),{13:51,24:f,57:k},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},e(j,[2,44],{58:[1,56]}),e(j,[2,45],{58:[1,57]}),e(A,[2,38]),e(A,[2,39]),e(A,[2,40]),e(A,[2,41]),e(A,[2,6]),e(A,[2,13]),{13:58,24:f,57:k},e(A,[2,17]),e(M,a,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},e(A,[2,29]),e(A,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},e(A,[2,14],{14:[1,71]}),{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,72],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},e(A,[2,34]),e(A,[2,35]),e(A,[2,36]),e(A,[2,37]),e(j,[2,46]),e(j,[2,47]),e(A,[2,15]),e(A,[2,19]),e(M,a,{7:78}),e(A,[2,26]),e(A,[2,27]),{5:[1,79]},{5:[1,80]},{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,81],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,32]),e(A,[2,33]),e(A,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};N.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,r,i){function a(){let n=t.yytext.indexOf(`%%`);if(n===0)return!1;if(n>0){let r=t.yytext.slice(0,n),i=t.yytext.slice(n);i&&e.lexer.unput(i),t.yytext=r}return!0}switch(n(a,`processId`),r){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState(`SCALE`),17;case 14:return 18;case 15:this.popState();break;case 16:return this.begin(`acc_title`),33;case 17:return this.popState(),`acc_title_value`;case 18:return this.begin(`acc_descr`),35;case 19:return this.popState(),`acc_descr_value`;case 20:this.begin(`acc_descr_multiline`);break;case 21:this.popState();break;case 22:return`acc_descr_multiline_value`;case 23:return this.pushState(`CLASSDEF`),41;case 24:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 25:return this.popState(),this.pushState(`CLASSDEFID`),42;case 26:return this.popState(),43;case 27:return this.pushState(`CLASS`),48;case 28:return this.popState(),this.pushState(`CLASS_STYLE`),49;case 29:return this.popState(),50;case 30:return this.pushState(`STYLE`),45;case 31:return this.popState(),this.pushState(`STYLEDEF_STYLES`),46;case 32:return this.popState(),47;case 33:return this.pushState(`SCALE`),17;case 34:return 18;case 35:this.popState();break;case 36:this.pushState(`STATE`);break;case 37:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),25;case 38:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),26;case 39:return this.popState(),t.yytext=t.yytext.slice(0,-10).trim(),27;case 40:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),25;case 41:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),26;case 42:return this.popState(),t.yytext=t.yytext.slice(0,-10).trim(),27;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState(`STATE_STRING`);break;case 48:return this.pushState(`STATE_ID`),`AS`;case 49:return a()?(this.popState(),`ID`):void 0;case 50:this.popState();break;case 51:return`STATE_DESCR`;case 52:throw Error(`Error: State name must be a single word. Found: "`+t.yytext.trim()+`"`);case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState(`struct`),20;case 56:return this.popState(),21;case 57:break;case 58:return this.begin(`NOTE`),29;case 59:return this.popState(),this.pushState(`NOTE_ID`),59;case 60:return this.popState(),this.pushState(`NOTE_ID`),60;case 61:this.popState(),this.pushState(`FLOATING_NOTE`);break;case 62:return this.popState(),this.pushState(`FLOATING_NOTE_ID`),`AS`;case 63:break;case 64:return`NOTE_TEXT`;case 65:return a()?(this.popState(),`ID`):void 0;case 66:return a()?(this.popState(),this.pushState(`NOTE_TEXT`),24):void 0;case 67:return this.popState(),t.yytext=t.yytext.substr(2).trim(),31;case 68:return this.popState(),t.yytext=t.yytext.slice(0,-8).trim(),31;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:return a()?24:void 0;case 74:return t.yytext=t.yytext.trim(),14;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return`INVALID`}},`anonymous`),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}}})();function P(){this.yy={}}return n(P,`Parser`),P.prototype=N,N.Parser=P,new P})();w.parser=w;var T=w,E=`TB`,D=`TB`,O=`dir`,k=`state`,A=`root`,j=`relation`,M=`classDef`,N=`style`,P=`applyClass`,F=`default`,ee=`divider`,te=`fill:none`,ne=`fill: #333`,re=`c`,ie=`markdown`,ae=`normal`,I=`rect`,L=`rectWithTitle`,oe=`stateStart`,se=`stateEnd`,R=`divider`,ce=`roundedWithTitle`,le=`note`,ue=`noteGroup`,z=`statediagram`,de=`${z}-state`,B=`transition`,fe=`note`,pe=`${B} note-edge`,me=`${z}-${fe}`,he=`${z}-cluster`,ge=`${z}-cluster-alt`,V=`parent`,H=`note`,_e=`state`,U=`----`,ve=`${U}${H}`,ye=`${U}${V}`,W=new Map,G=0,be=0,K=new Map,xe=n((e,t,n,r)=>{if(e===R&&n?.id!==void 0&&K.has(n.id)){let e=K.get(n.id);return K.set(t,e),e}let i=be++,a=r?void 0:i;return K.set(t,a),a},`colorSlotFor`);function q(e=``,t=0,n=``,r=U){return`${_e}-${e}${n!==null&&n.length>0?`${r}${n}`:``}-${t}`}n(q,`stateDomId`);var Se=n((t,n,r,i,a,o,c,l)=>{e.trace(`items`,n),n.forEach(e=>{switch(e.stmt){case k:X(t,e,r,i,a,o,c,l);break;case F:X(t,e,r,i,a,o,c,l);break;case j:{X(t,e.state1,r,i,a,o,c,l),X(t,e.state2,r,i,a,o,c,l);let n=c===`neo`,u={id:`edge`+G,start:e.state1.id,end:e.state2.id,arrowhead:`normal`,arrowTypeEnd:n?`arrow_barb_neo`:`arrow_barb`,style:te,labelStyle:``,label:s.sanitizeText(e.description??``,d()),arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,classes:B,look:c};a.push(u),G++}}})},`setupDoc`),Ce=n((e,t=D)=>{let n=t;if(e.doc)for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`);function J(e,t,n){if(!t.id||t.id===``||t.id===``)return;t.cssClasses&&(Array.isArray(t.cssCompiledStyles)||(t.cssCompiledStyles=[]),t.cssClasses.split(` `).forEach(e=>{let r=n.get(e);r&&(t.cssCompiledStyles=[...t.cssCompiledStyles??[],...r.styles])}));let r=e.find(e=>e.id===t.id);r?Object.assign(r,t):e.push(t)}n(J,`insertOrUpdateNode`);function we(e){return e?.classes?.join(` `)??``}n(we,`getClassesFromDbInfo`);function Y(e){return e?.styles??[]}n(Y,`getStylesFromDbInfo`);var X=n((t,n,r,i,a,o,c,l)=>{let u=n.id,f=r.get(u),p=we(f),m=Y(f),h=d(),g=p.trim()!==``||m.length>0;if(e.info(`dataFetcher parsedItem`,n,f,m),u!==`root`){let r=I;n.start===!0?r=oe:n.start===!1&&(r=se),n.type!==F&&(r=n.type),W.get(u)||W.set(u,{id:u,shape:r,description:s.sanitizeText(u,h),cssClasses:`${p} ${de}`,cssStyles:m});let d=W.get(u);n.description&&(Array.isArray(d.description)?(d.shape=L,d.description.push(n.description)):d.description?.length&&d.description.length>0?(d.shape=L,d.description=d.description===u?[n.description]:[d.description,n.description]):(d.shape=I,d.description=n.description),d.description=s.sanitizeTextOrArray(d.description,h)),d.description?.length===1&&d.shape===L&&(d.shape=d.type===`group`?ce:I),!d.type&&n.doc&&(e.info(`Setting cluster for XCX`,u,Ce(n)),d.type=`group`,d.isGroup=!0,d.dir=Ce(n),d.shape=n.type===ee?R:ce,d.colorIndex=xe(d.shape,u,t,g),d.cssClasses=`${d.cssClasses} ${he} ${o?ge:``}`);let f={labelStyle:``,shape:d.shape,label:d.description,cssClasses:d.cssClasses,cssCompiledStyles:[],cssStyles:d.cssStyles,id:u,dir:d.dir,domId:q(u,G),type:d.type,isGroup:d.type===`group`,colorIndex:d.colorIndex,padding:8,rx:10,ry:10,look:c,labelType:`markdown`};if(f.shape===R&&(f.label=``),t&&t.id!==`root`&&(e.trace(`Setting node `,u,` to be child of its parent `,t.id),f.parentId=t.id),f.centerLabel=!0,n.note){let e={labelStyle:``,shape:le,label:n.note.text,labelType:`markdown`,cssClasses:me,cssStyles:[],cssCompiledStyles:[],id:u+ve+`-`+G,domId:q(u,G,H),type:`node`,isGroup:!1,padding:h.flowchart?.padding,look:c,position:n.note.position},t=u+ye,r={labelStyle:``,shape:ue,label:n.note.text,cssClasses:d.cssClasses,cssStyles:[],id:u+ye,domId:q(u,G,V),type:`group`,isGroup:!0,padding:16,look:c,position:n.note.position};G++,r.id=t,e.parentId=t,J(i,r,l),J(i,e,l),J(i,f,l);let o=u,s=e.id;n.note.position===`left of`&&(o=e.id,s=u),a.push({id:o+`-`+s,start:o,end:s,arrowhead:`none`,arrowTypeEnd:``,style:te,labelStyle:``,classes:pe,pattern:`dashed`,arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,look:c})}else J(i,f,l)}n.doc&&(e.trace(`Adding nodes children `),Se(n,n.doc,r,i,a,!o,c,l))},`dataFetcher`),Te=n(()=>{W.clear(),G=0,be=0,K.clear()},`reset`),Ee=n((e,t=D)=>{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`),De={getClasses:n(function(e,t){return t.db.getClasses()},`getClasses`),draw:n(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing state diagram (v2)`,n);let{securityLevel:a,state:o,layout:s}=d();i.db.extract(i.db.getRootDocV2());let c=i.db.getData(),l=S(n,a);c.type=i.type,c.layoutAlgorithm=b(s),c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=d().look===`neo`?[`barbNeo`]:[`barb`],c.diagramId=n,await y(c,l);try{(typeof i.db.getLinks==`function`?i.db.getLinks():new Map).forEach((t,n)=>{let r=typeof n==`string`?n:typeof n?.id==`string`?n.id:``,i=c.nodes.find(e=>e.id===r);if(!r){e.warn(`⚠️ Invalid or missing stateId from key:`,JSON.stringify(n));return}let a=l.node()?.querySelectorAll(`g.node, g.rough-node`),o;if(a?.forEach(e=>{let t=e.textContent?.trim();(e.id===i?.domId||t===r)&&(o=e)}),!o){e.warn(`⚠️ Could not find node matching text:`,r);return}let s=o.parentNode;if(!s){e.warn(`⚠️ Node has no parent, cannot wrap:`,r);return}let u=document.createElementNS(`http://www.w3.org/2000/svg`,`a`),d=t.url.replace(/^"+|"+$/g,``);if(u.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,d),u.setAttribute(`target`,`_blank`),t.tooltip){let e=t.tooltip.replace(/^"+|"+$/g,``);u.setAttribute(`title`,e),o.setAttribute(`title`,e)}s.replaceChild(u,o),u.appendChild(o),e.info(`🔗 Wrapped node in tag for:`,r,t.url)})}catch(t){e.error(`❌ Error injecting clickable links:`,t)}p.insertTitle(l,`statediagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),C(l,8,z,o?.useMaxWidth??!0)},`draw`),getDir:Ee},Z={START_NODE:`[*]`,START_TYPE:`start`,END_NODE:`[*]`,END_TYPE:`end`,COLOR_KEYWORD:`color`,FILL_KEYWORD:`fill`,BG_FILL:`bgFill`,STYLECLASS_SEP:`,`},Oe=n(()=>new Map,`newClassesList`),Q=n(()=>({relations:[],states:new Map,documents:{}}),`newDoc`),$=n(e=>JSON.parse(JSON.stringify(e)),`clone`),ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=Oe(),this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=f,this.setAccTitle=i,this.getAccDescription=l,this.setAccDescription=r,this.setDiagramTitle=o,this.getDiagramTitle=u,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{n(this,`StateDB`)}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let t of Array.isArray(e)?e:e.doc)switch(t.stmt){case k:this.addState(t.id.trim(),t.type,t.doc,t.description,t.note);break;case j:this.addRelation(t.state1,t.state2,t.description);break;case M:this.addStyleClass(t.id.trim(),t.classes);break;case N:this.handleStyleDef(t);break;case P:this.setCssClass(t.id.trim(),t.styleClass);break;case`click`:this.addLink(t.id,t.url,t.tooltip)}let t=this.getStates(),n=d();Te(),X(void 0,this.getRootDocV2(),t,this.nodes,this.edges,!0,n.look,this.classes);for(let e of this.nodes)if(Array.isArray(e.label)){if(e.description=e.label.slice(1),e.isGroup&&e.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${e.id}]`);e.label=e.label[0]}}handleStyleDef(e){let t=e.id.trim().split(`,`),n=e.styleClass.split(`,`);for(let e of t){let t=this.getState(e);if(!t){let n=e.trim();this.addState(n),t=this.getState(n)}t&&(t.styles=n.map(e=>e.replace(/;/g,``)?.trim()))}}setRootDoc(t){e.info(`Setting root doc`,t),this.rootDoc=t,this.version===1?this.extract(t):this.extract(this.getRootDocV2())}docTranslator(e,t,n){if(t.stmt===j){this.docTranslator(e,t.state1,!0),this.docTranslator(e,t.state2,!1);return}if(t.stmt===k&&(t.id===Z.START_NODE?(t.id=e.id+(n?`_start`:`_end`),t.start=n):t.id=t.id.trim()),t.stmt!==A&&t.stmt!==k||!t.doc)return;let r=[],i=[];for(let e of t.doc)if(e.type===ee){let t=$(e);t.doc=$(i),r.push(t),i=[]}else i.push(e);if(r.length>0&&i.length>0){let e={stmt:k,id:m(),type:`divider`,doc:$(i)};r.push($(e)),t.doc=r}t.doc.forEach(e=>this.docTranslator(t,e,!0))}getRootDocV2(){return this.docTranslator({id:A,stmt:A},{id:A,stmt:A,doc:this.rootDoc},!0),{id:A,doc:this.rootDoc}}addState(t,n=F,r=void 0,i=void 0,a=void 0,o=void 0,c=void 0,l=void 0){let u=t?.trim();if(!this.currentDocument.states.has(u))e.info(`Adding state `,u,i),this.currentDocument.states.set(u,{stmt:k,id:u,descriptions:[],type:n,doc:r,note:a,classes:[],styles:[],textStyles:[]});else{let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.doc||=r,e.type||=n}if(i&&(e.info(`Setting state description`,u,i),(Array.isArray(i)?i:[i]).forEach(e=>this.addDescription(u,e.trim()))),a){let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.note=a,e.note.text=s.sanitizeText(e.note.text,d())}o&&(e.info(`Setting state classes`,u,o),(Array.isArray(o)?o:[o]).forEach(e=>this.setCssClass(u,e.trim()))),c&&(e.info(`Setting state styles`,u,c),(Array.isArray(c)?c:[c]).forEach(e=>this.setStyle(u,e.trim()))),l&&(e.info(`Setting state styles`,u,c),(Array.isArray(l)?l:[l]).forEach(e=>this.setTextStyle(u,e.trim())))}clear(e){this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=Oe(),e||(this.links=new Map,a())}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){e.info(`Documents = `,this.documents)}getRelations(){return this.currentDocument.relations}addLink(t,n,r){this.links.set(t,{url:n,tooltip:r}),e.warn(`Adding link`,t,n,r)}getLinks(){return this.links}startIdIfNeeded(e=``){return e===Z.START_NODE?(this.startEndCount++,`${Z.START_TYPE}${this.startEndCount}`):e}startTypeIfNeeded(e=``,t=F){return e===Z.START_NODE?Z.START_TYPE:t}endIdIfNeeded(e=``){return e===Z.END_NODE?(this.startEndCount++,`${Z.END_TYPE}${this.startEndCount}`):e}endTypeIfNeeded(e=``,t=F){return e===Z.END_NODE?Z.END_TYPE:t}addRelationObjs(e,t,n=``){let r=this.startIdIfNeeded(e.id.trim()),i=this.startTypeIfNeeded(e.id.trim(),e.type),a=this.startIdIfNeeded(t.id.trim()),o=this.startTypeIfNeeded(t.id.trim(),t.type);this.addState(r,i,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(a,o,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:s.sanitizeText(n,d())})}addRelation(e,t,n){if(typeof e==`object`&&typeof t==`object`)this.addRelationObjs(e,t,n);else if(typeof e==`string`&&typeof t==`string`){let r=this.startIdIfNeeded(e.trim()),i=this.startTypeIfNeeded(e),a=this.endIdIfNeeded(t.trim()),o=this.endTypeIfNeeded(t);this.addState(r,i),this.addState(a,o),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:n?s.sanitizeText(n,d()):void 0})}}addDescription(e,t){let n=this.currentDocument.states.get(e),r=t.startsWith(`:`)?t.replace(`:`,``).trim():t;n?.descriptions?.push(s.sanitizeText(r,d()))}cleanupLabel(e){return e.startsWith(`:`)?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,t=``){this.classes.has(e)||this.classes.set(e,{id:e,styles:[],textStyles:[]});let n=this.classes.get(e);t&&n&&t.split(Z.STYLECLASS_SEP).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(Z.COLOR_KEYWORD).exec(e)){let e=t.replace(Z.FILL_KEYWORD,Z.BG_FILL).replace(Z.COLOR_KEYWORD,Z.FILL_KEYWORD);n.textStyles.push(e)}n.styles.push(t)})}getClasses(){return this.classes}setupToolTips(e){let n=x();t(e).select(`svg`).selectAll(`g.node, g.rough-node`).on(`mouseover`,e=>{let r=t(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),n.html(c.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),t(e.currentTarget).classed(`hover`,!1)})}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=this.getState(e);if(!n){let t=e.trim();this.addState(t),n=this.getState(t)}n?.classes?.push(t)})}setStyle(e,t){this.getState(e)?.styles?.push(t)}setTextStyle(e,t){this.getState(e)?.textStyles?.push(t)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirectionStatement(){return this.rootDoc.find(e=>e.stmt===O)}getDirection(){return this.getDirectionStatement()?.value??E}setDirection(e){let t=this.getDirectionStatement();t?t.value=e:this.rootDoc.unshift({stmt:O,value:e})}trimColon(e){return e.startsWith(`:`)?e.slice(1).trim():e.trim()}getData(){let e=d();for(let t of this.nodes)t.wrappingWidth??=e.state?.wrappingWidth,t.isGroup||(t.minWidth??=e.state?.minNodeWidth);return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:Ee(this.getRootDocV2())}}getConfig(){return d().state}},Ae=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!g(t,r))return``;let i=_(e.look),a=v(n),o=``;for(let e=0;e` +${Ae(e)} +defs [id$="-barbEnd"] { + fill: ${e.transitionColor}; + stroke: ${e.transitionColor}; + } +g.stateGroup text { + fill: ${e.nodeBorder}; + stroke: none; + font-size: 10px; +} +g.stateGroup text { + fill: ${e.textColor}; + stroke: none; + font-size: 10px; + +} +g.stateGroup .state-title { + font-weight: bolder; + fill: ${e.stateLabelColor}; +} + +g.stateGroup rect { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; +} + +g.stateGroup line { + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth||1}; +} + +.transition { + stroke: ${e.transitionColor}; + stroke-width: ${e.strokeWidth||1}; + fill: none; +} + +.stateGroup .composit { + fill: ${e.background}; + border-bottom: 1px +} + +.stateGroup .alt-composit { + fill: #e0e0e0; + border-bottom: 1px +} + +.state-note { + stroke: ${e.noteBorderColor}; + fill: ${e.noteBkgColor}; + + text { + fill: ${e.noteTextColor}; + stroke: none; + font-size: 10px; + } +} + +.stateLabel .box { + stroke: none; + stroke-width: 0; + fill: ${e.mainBkg}; + opacity: 0.5; +} + +.edgeLabel .label rect { + fill: ${e.labelBackgroundColor}; + opacity: 0.5; +} +.edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; +} +.edgeLabel .label text { + fill: ${e.transitionLabelColor||e.tertiaryTextColor}; +} +.label div .edgeLabel { + color: ${e.transitionLabelColor||e.tertiaryTextColor}; +} + +.stateLabel text { + fill: ${e.stateLabelColor}; + font-size: 10px; + font-weight: bold; +} + +.node circle.state-start { + fill: ${e.specialStateColor}; + stroke: ${e.specialStateColor}; +} + +.node .fork-join { + fill: ${e.specialStateColor}; + stroke: ${e.specialStateColor}; +} + +.node circle.state-end { + fill: ${e.innerEndBackground}; + stroke: ${e.background}; + stroke-width: 1.5 +} +.end-state-inner { + fill: ${e.compositeBackground||e.background}; + // stroke: ${e.background}; + stroke-width: 1.5 +} + +.node rect { + fill: ${e.stateBkg||e.mainBkg}; + stroke: ${e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth||1}px; +} +.node polygon { + fill: ${e.mainBkg}; + stroke: ${e.stateBorder||e.nodeBorder};; + stroke-width: ${e.strokeWidth||1}px; +} +[id$="-barbEnd"] { + fill: ${e.lineColor}; +} + +.statediagram-cluster rect { + fill: ${e.compositeTitleBackground}; + stroke: ${e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth||1}px; +} + +.cluster-label, .nodeLabel { + color: ${e.stateLabelColor}; + // line-height: 1; +} + +.statediagram-cluster rect.outer { + rx: 5px; + ry: 5px; +} +.statediagram-state .divider { + stroke: ${e.stateBorder||e.nodeBorder}; +} + +.statediagram-state .title-state { + rx: 5px; + ry: 5px; +} +.statediagram-cluster.statediagram-cluster .inner { + fill: ${e.compositeBackground||e.background}; +} +.statediagram-cluster.statediagram-cluster-alt .inner { + fill: ${e.altBackground?e.altBackground:`#efefef`}; +} + +.statediagram-cluster .inner { + rx:0; + ry:0; +} + +.statediagram-state rect.basic { + rx: 5px; + ry: 5px; +} +.statediagram-state rect.divider { + stroke-dasharray: 10,10; + fill: ${e.altBackground?e.altBackground:`#efefef`}; +} + +.note-edge { + stroke-dasharray: 5; +} + +.statediagram-note rect { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + stroke-width: 1px; + rx: 0; + ry: 0; +} +.statediagram-note rect { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + stroke-width: 1px; + rx: 0; + ry: 0; +} + +.statediagram-note text { + fill: ${e.noteTextColor}; +} + +.statediagram-note .nodeLabel { + color: ${e.noteTextColor}; +} +.statediagram .edgeLabel { + color: red; // ${e.noteTextColor}; +} + +[id$="-dependencyStart"], [id$="-dependencyEnd"] { + fill: ${e.lineColor}; + stroke: ${e.lineColor}; + stroke-width: ${e.strokeWidth||1}; +} + +.statediagramTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; +} + +[data-look="neo"].statediagram-cluster rect { + fill: ${e.mainBkg}; + stroke: ${e.useGradient?`url(`+e.svgId+`-gradient)`:e.stateBorder||e.nodeBorder}; + stroke-width: ${e.strokeWidth??1}; +} +[data-look="neo"].statediagram-cluster rect.outer { + rx: ${e.radius}px; + ry: ${e.radius}px; + filter: ${e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${e.svgId}-drop-shadow)`):`none`} +} +`,`getStyles`),init:n(e=>{e.state||={},e.state.arrowMarkerAbsolute=e.arrowMarkerAbsolute},`init`)};export{je as diagram}; \ No newline at end of file diff --git a/www/assets/swimlanes-2SLR337P-BKvviDHP.js b/www/assets/swimlanes-2SLR337P-BKvviDHP.js new file mode 100644 index 0000000..af51a89 --- /dev/null +++ b/www/assets/swimlanes-2SLR337P-BKvviDHP.js @@ -0,0 +1 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import{r as n}from"./chunk-3FUC2YCW-CmoZ3fbX.js";import{t as r}from"./chunk-NETBCI7D-Br7cqgBT.js";function i(e,{measure:t}){let n=e.config?.swimlane?.lineHops;if(n===!1)return;let i=n===`gap`?`gap`:`arc`,a=e.edges.filter(e=>Array.isArray(e.points)&&e.points.length>=2).map(e=>({id:e.id,points:e.points,curve:e.curve,arrowTypeStart:e.arrowTypeStart,arrowTypeEnd:e.arrowTypeEnd}));r(t.groups.edgePaths,a,{enabled:!0,jumpRadius:6,jumpStyle:i})}t(i,`applySwimlaneLineJumps`);var a=`__swimlane_default__`,o=21,s=20;function c(e){return Math.max(e.padding??s,s)}t(c,`topLaneHorizontalPadding`);function l(e){let{x:t,y:n,width:r,height:i}=e,a=e.swimlaneContentTop;if(typeof t!=`number`||typeof n!=`number`||typeof r!=`number`||typeof i!=`number`||typeof a!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||!Number.isFinite(r)||!Number.isFinite(i)||!Number.isFinite(a)||r<=0||i<=0){delete e.groupTitleRect;return}let s=n-i/2,c=Math.min(a,n+i/2),l=s+Math.min(o,Math.max(0,c-s));if(l<=s){delete e.groupTitleRect;return}e.groupTitleRect={left:t-r/2,right:t+r/2,top:s,bottom:l}}t(l,`assignTopLaneTitleRect`);function u(e){let t=e.direction,n=e.nodes??=[];for(let n of e.nodes??[])n.isGroup&&!n.parentId&&(n.shape=`swimlane`,t&&(n.direction=t));let r=n.filter(e=>!e.isGroup&&!e.parentId);if(r.length===0)return;let i=n.find(e=>e.id===a);i?i.isGroup&&(i.shape=`swimlane`,t&&(i.direction=t)):(i={id:a,label:``,isGroup:!0,shape:`swimlane`,padding:20,look:e.config?.look,colorIndex:n.reduce((e,t)=>Math.max(e,t.colorIndex??-1),-1)+1,...t?{direction:t}:{}},n.push(i));for(let e of r)e.parentId=a}t(u,`prepareLayoutForSwimlanes`);function d(e){let t=new Map;for(let n of e.nodes??[])t.set(n.id,n);let n=[];for(let t of e.edges??[]){let e=typeof t.start==`string`?t.start:void 0,r=typeof t.end==`string`?t.end:void 0;!e||!r||t.labelNodeId||n.push({id:t.id,src:e,dst:r,ref:t})}let r=e.nodes??[],i=r.filter(e=>e.isGroup),a=r.filter(e=>!e.isGroup);return{nodes:[...[...i].reverse(),...a].map(e=>e.id),edges:n,layout:e,nodeById:t}}t(d,`toGraphView`);function f(e,t,n,r){let{layout:i}=e,a=e.nodeById,o=r?.layerGap??100,s=r?.nodeGap??40,u=0;for(let e of t.layers){let t=0;for(let r of e){let e=a.get(r);if(!e){t++;continue}e.layer=u,e.order=t;let i=n.x[r]??t*s,c=n.y[r]??u*o;e.x=i,e.y=c,t++}u++}let d=i.nodes??[],f=new Map,p=[];for(let e of d){if(!e?.isGroup)continue;e.parentId||p.push(e);let t=d.filter(t=>t.parentId===e.id),r=1/0,i=-1/0,a=1/0,o=-1/0;for(let e of t){let t=e.x??n.x[e.id],s=e.y??n.y[e.id],c=e.width??0,l=e.height??0;t!=null&&s!=null&&(r=Math.min(r,t-c/2),i=Math.max(i,t+c/2),a=Math.min(a,s-l/2),o=Math.max(o,s+l/2))}if(r===1/0||a===1/0)e.x=e.x??0,e.y=e.y??0,e.width=e.width??0,e.height=e.height??0;else{let t=e.padding??20,n=e.parentId?t:2*c(e),s=t,l=Math.max(0,i-r)+n,u=Math.max(0,o-a)+s,d=(r+i)/2,p=(a+o)/2;e.x=d,e.y=p,e.width=l,e.height=u,f.set(e.id,{minX:r,maxX:i,minY:a,maxY:o})}}if(p.length>0&&f.size>0){let e=1/0,t=-1/0,n=0;for(let r of p){let i=r.padding??20;i>n&&(n=i);let a=f.get(r.id);a&&(e=Math.min(e,a.minY),t=Math.max(t,a.maxY))}if(e!==1/0&&t!==-1/0){let r=Math.max(0,t-e)+2*Math.max(n,36),i=(e+t)/2;for(let t of p)t.y=i,t.height=r,t.swimlaneContentTop=e;let a=[...p].sort((e,t)=>(e.x??0)-(t.x??0)),o=[],s=[],u=[];for(let e of a){let t=f.get(e.id);if(!t)continue;let n=Math.max(0,t.maxX-t.minX)+2*c(e),r=(t.minX+t.maxX)/2;o.push(e.id),s.push(r),u.push(n)}let d=o.length;if(d>0){let e=new Map;if(d===1)e.set(o[0],u[0]);else{let t=[];for(let e=0;e0&&i>0?{cx:t,cy:n,rect:P(t,n,r,i)}:void 0}t(g,`measuredNodeRect`);function _(e){if(e.isGroup)return;let t=g(e);if(t)return{id:String(e.id??``),cx:t.cx,cy:t.cy,rect:t.rect}}t(_,`nodeBoundsInfoFor`);function v(e,t,n=h){return Math.abs(e.x-t.x)n}t(x,`isHorizontalSegment`);function S(e,t,n=h){return y(e,t,n)&&Math.abs(e.y-t.y)>n}t(S,`isVerticalSegment`);function C(e,t,n,r){return Math.max(0,Math.min(Math.max(e,t),Math.max(n,r))-Math.max(Math.min(e,t),Math.min(n,r)))}t(C,`overlapLength`);function w(e,t,n=h){return e.horizontal&&t.horizontal&&b(e.a,t.a,n)?C(e.a.x,e.b.x,t.a.x,t.b.x):e.vertical&&t.vertical&&y(e.a,t.a,n)?C(e.a.y,e.b.y,t.a.y,t.b.y):0}t(w,`sameAxisSegmentOverlapLength`);function T(e,t=h){let n=[];for(let r=0;r0?n[n.length-1]:void 0;(!e||!v(e,r,t))&&n.push({x:r.x,y:r.y})}return n}t(D,`dedupeConsecutivePoints`);function O(e,t=h){if(!e||e.length!==4)return;let[n,r,i,a]=e;return x(n,r,t)&&S(r,i,t)&&x(i,a,t)?{kind:`HVH`,p0:n,p1:r,p2:i,p3:a}:S(n,r,t)&&x(r,i,t)&&S(i,a,t)?{kind:`VHV`,p0:n,p1:r,p2:i,p3:a}:void 0}t(O,`classifyThreeSegmentRoute`);function k(e,t,n,r=0){let i=Math.min(e.x,t.x),a=Math.max(e.x,t.x),o=Math.min(e.y,t.y),s=Math.max(e.y,t.y);return a>n.left-r&&in.top-r&&ot.left+n&&e.xt.top+n&&e.y=t.right&&e.top<=t.top&&e.bottom>=t.bottom}t(j,`rectContainsRect`);function M(e,t){return e.leftt.left&&e.topt.top}t(M,`rectsOverlap`);function N(e,t){return{left:e.left-t,right:e.right+t,top:e.top-t,bottom:e.bottom+t}}t(N,`inflateRect`);function P(e,t,n,r){return{left:e-n/2,right:e+n/2,top:t-r/2,bottom:t+r/2}}t(P,`rectFromCenterSize`);function F(e){return g(e)?.rect}t(F,`rectOfNodeBounds`);function I(e,t){switch(t){case`top`:return{x:e.cx,y:e.rect.top};case`bottom`:return{x:e.cx,y:e.rect.bottom};case`left`:return{x:e.rect.left,y:e.cy};case`right`:return{x:e.rect.right,y:e.cy}}}t(I,`portForRectSide`);function ee(e,t,n,r,i,a=h){let o=t===`left`||t===`right`,s=r===`left`||r===`right`;if(o&&s){if(t===`right`&&r===`left`&&e.xn.x){if(b(e,n,a))return[e,n];let t=(e.x+n.x)/2;return[e,{x:t,y:e.y},{x:t,y:n.y},n]}if(t===r){if(b(e,n,a))return;let r=t===`left`?Math.min(e.x,n.x)-i:Math.max(e.x,n.x)+i;return[e,{x:r,y:e.y},{x:r,y:n.y},n]}return}if(!o&&!s){if(t===r){if(y(e,n,a))return;let r=t===`top`?Math.min(e.y,n.y)-i:Math.max(e.y,n.y)+i;return[e,{x:e.x,y:r},{x:n.x,y:r},n]}if(!(t===`bottom`&&r===`top`&&e.yn.y))return;if(y(e,n,a))return[e,n];let o=(e.y+n.y)/2;return[e,{x:e.x,y:o},{x:n.x,y:o},n]}if(o&&!s){let i=t===`right`&&n.x>e.x||t===`left`&&n.xn.y;return i&&a?[e,{x:n.x,y:e.y},n]:void 0}let c=t===`bottom`&&n.y>e.y||t===`top`&&n.yn.x;return c&&l?[e,{x:e.x,y:n.y},n]:void 0}t(ee,`buildOrthogonalPortPath`);function L(e,t,n,r){return t===`left`||t===`right`?[e,{x:r,y:e.y},{x:r,y:n.y},n]:[e,{x:e.x,y:r},{x:n.x,y:r},n]}t(L,`buildSameSideTrackPath`);function R(e){let t=new Map,n=[];for(let r of e){if(r.isEdgeLabel)continue;let e=_(r);e&&(t.set(e.id,e),n.push({id:e.id,rect:e.rect}))}return{nodeInfoById:t,realNodeRects:n}}t(R,`collectRealNodeBounds`);function z(e){let t=[],n=[];for(let r of e){let e=_(r);if(!e)continue;let i={id:e.id,rect:e.rect};r.isEdgeLabel?n.push(i):t.push(i)}return{realNodeRects:t,labelNodeRects:n}}t(z,`collectNodeRectEntries`);function te(e,{includeEdgeLabels:t=!0}={}){let n=[];for(let r of e){if(r.isGroup||!t&&r.isEdgeLabel)continue;let e=r.x??0,i=r.y??0,a=r.width??0,o=r.height??0;n.push({nodeId:r.id,...P(e,i,a,o)})}return n}t(te,`collectLayoutNodeRects`);function ne(e,t,n=h){let r=e.start,i=e.end;if(!r||!i)return;let a=t.get(r),o=t.get(i);if(!(!a||!o))return{srcId:r,dstId:i,srcInfo:a,dstInfo:o,collinearX:Math.abs(a.cx-o.cx)m||f<_||f>v)return!1;let x=Math.abs(g-u.a.x)i:a&&s&&b(e,n,i)?C(e.x,t.x,n.x,r.x)>i:!1}t(ie,`sameAxisSegmentsOverlap`);function ae(e,t,n,r,{epsilon:i=h,skipDegenerateOther:a=!1}={}){for(let o of n){if(o===r||o.isLayoutOnly)continue;let n=o.points;if(!(!n||n.length<2))for(let r=0;rf+i&&mg+i&&d<_-i}t(V,`orthogonalSegmentsStrictlyCross`);function oe(e,t,n){let r=Math.min(t,n),i=Math.max(t,n);return e>r+h&&e=2?t[t.length-2]:void 0,n=e&&y(e,r)?{x:r.x,y:i.y}:{x:i.x,y:r.y};t.push(n)}t.push(i)}let n=[];for(let e of t){let t=n[n.length-1];(!t||!v(t,e))&&n.push(e)}return n}t(W,`orthogonalizePolyline`);function G(e){if(e.length<3)return e;let t=[...e];for(let e=0;e<32;e++){let e=U(t);if(t=e.points,!e.changed)break}return t}t(G,`simplifyPolyline`);var K=.001,se=.5,ce=4;function le(e,t,n){let r=e;if(r.isLayoutOnly||!r.points||r.points.length=0&&i=e.length)return e;let a=i-r;if(a<0||a>=e.length)return e;let o=ue(e[i],e[a],t);return n?[o,...e.slice(i)]:[...e.slice(0,i+1),o]}t(de,`clipEndpoint`);function q(e,t){for(let n of e){let e=le(n,t,2);if(!e)continue;let r=[...e.points];e.srcRect&&(r=de(r,e.srcRect,!0)),e.dstRect&&(r=de(r,e.dstRect,!1)),r=G(W(r)),r=xe(r,e.srcRect,e.dstRect),e.edge.points=G(W(r))}}t(q,`clipEdgeEndpointsToNodeBoundaries`);function J(e,t,n,r=!1){if(b(e,t,K)){if(t.yn.bottom+K)return t;if(r){if(e.xn.right+K)return{x:n.right,y:e.y}}return{x:Math.abs(t.x-n.left)<=Math.abs(t.x-n.right)?n.left:n.right,y:e.y}}if(y(e,t,K)){if(t.xn.right+K)return t;if(r){if(e.yn.bottom+K)return{x:e.x,y:n.bottom}}let i=Math.abs(t.y-n.top)<=Math.abs(t.y-n.bottom);return{x:e.x,y:i?n.top:n.bottom}}return t}t(J,`snapEndpointToBoundary`);function fe(e,t,n){let r=e[t];for(let i=t+n;i>=0&&ie.lo)),n=Math.min(...e.map(e=>e.hi));if(!(t>n))return{lo:t,hi:n}}t(he,`intersectRanges`);function ge(e,t){return t===`left`||t===`right`?pe(e.top,e.bottom):pe(e.left,e.right)}t(ge,`clearanceRangeForSide`);function _e(e,t,n){let r=e.y>=n.top-K&&e.y<=n.bottom+K,i=e.x>=n.left-K&&e.x<=n.right+K;if(b(e,t,K)&&r){if(Math.abs(e.x-n.left)0?he(a):void 0}t(ye,`straightClearanceRange`);function be(e,t,n,r,i){let a=ye(e,t,n,r,i);if(!a)return;let o=i?e.y:e.x,s=Math.min(a.hi,Math.max(a.lo,o));if(!(Math.abs(s-o)({...e}));for(let s=t;s>=0&&s=n.left-K&&Math.max(e.x,t.x)<=n.right+K,i=Math.min(e.y,t.y)>=n.top-K&&Math.max(e.y,t.y)<=n.bottom+K;if(Math.abs(e.y-n.top)r.bottom+K;case`left`:return b(t,n,K)&&n.xr.right+K}}t(Ee,`leavesOutward`);function De(e,t,n){if(e.length<3)return e;if(n){let n=Te(e[0],e[1],t);return n&&Ee(n,e[1],e[2],t)?e.slice(1):e}let r=e.length-1,i=Te(e[r-1],e[r],t);return i&&Ee(i,e[r-1],e[r-2],t)?e.slice(0,r):e}t(De,`collapseOwnBorderStub`);function Oe(e,t,n){let r=e;if(t){let e=fe(r,0,1);if(e){let n=J(e,r[0],t);n!==r[0]&&(r=[n,...r.slice(1)])}r=De(r,t,!0)}if(n){let e=r.length-1,t=fe(r,e,-1);if(t){let i=J(t,r[e],n,!0);i!==r[e]&&(r=[...r.slice(0,e),i])}r=De(r,n,!1)}let i=xe(r,t,n);return i!==r||r.length===2?i:(t&&(r=we(r,t,!0)),n&&(r=we(r,n,!1)),r)}t(Oe,`snapAndCollapseEndpoints`);function ke(e,t){for(let n of e){let e=le(n,t,2);if(!e)continue;let r=Oe(D(e.points,K),e.srcRect,e.dstRect);if(r.length<3){e.edge.points=r;continue}let i=[r[0],{...r[0]},...r.slice(1,-1),r[r.length-1],{...r[r.length-1]}];e.edge.points=i}}t(ke,`prepareEdgeEndpointsForRenderer`);function Ae(e){return new Map(e.map(e=>[e.id,e]))}t(Ae,`buildNodeMap`);function je(e,t){let n=e.parentId,r=null;for(;n;){let e=t.get(n);if(!e?.isGroup)break;r=e.id,n=e.parentId}return r}t(je,`resolveTopLevelGroupId`);function Me(e,t){let n=0,r=e.parentId;for(;r;){let e=t.get(r);if(!e?.isGroup)break;n++,r=e.parentId}return n}t(Me,`groupDepth`);function Ne(e){let t=1/0,n=-1/0,r=1/0,i=-1/0;for(let a of e){let e=a.x,o=a.y;if(typeof e!=`number`||typeof o!=`number`)continue;let s=a.width??0,c=a.height??0;t=Math.min(t,e-s/2),n=Math.max(n,e+s/2),r=Math.min(r,o-c/2),i=Math.max(i,o+c/2)}return t===1/0||r===1/0?null:{minX:t,maxX:n,minY:r,maxY:i}}t(Ne,`boundsForChildren`);function Pe(e,t){let n=e.padding??20;e.x=(t.minX+t.maxX)/2,e.y=(t.minY+t.maxY)/2,e.width=Math.max(0,t.maxX-t.minX)+n,e.height=Math.max(0,t.maxY-t.minY)+n}t(Pe,`applyGroupBounds`);function Fe(e){let t=Ae(e),n=e.filter(e=>e.isGroup&&e.parentId).sort((e,n)=>Me(n,t)-Me(e,t));for(let t of n){let n=Ne(e.filter(e=>e.parentId===t.id));n&&Pe(t,n)}}t(Fe,`recomputeNestedGroupBounds`);function Ie(e,n){let r=e.nodes??[],i=e.edges??[],a=r.filter(e=>!e.isGroup),o=1/0,s=-1/0;for(let e of a){let t=e[n];typeof t==`number`&&(o=Math.min(o,t),s=Math.max(s,t))}if(!Number.isFinite(o)||!Number.isFinite(s))return!1;let c=t(e=>o+s-e,`mirror`);for(let e of r){let t=e[n];typeof t==`number`&&(e[n]=c(t));let r=e.groupTitleRect;r&&(e.groupTitleRect=n===`x`?{...r,left:c(r.right),right:c(r.left)}:{...r,top:c(r.bottom),bottom:c(r.top)})}for(let e of i)for(let t of e.points??[])t[n]=c(t[n]);return!0}t(Ie,`mirrorAxis`);function Le(e){return!(e.nodes??[]).some(e=>!e.isGroup)||Ie(e,`y`)}t(Le,`applyBtDirectionTransform`);function Re(e,t=`LR`){let n=e.nodes??[],r=e.edges??[],i=n.filter(e=>!e.isGroup),a=1/0,o=1/0;for(let e of i){let t=e.x??0,n=e.y??0;t0?Math.max(1,l/u):1;for(let e of i){let t=e.x??0,n=((e.y??0)-o)*d+36,r=t-a;e.x=n,e.y=r}for(let e of r)if(e.points)for(let t of e.points){let e=t.x,n=(t.y-o)*d+36,r=e-a;t.x=n,t.y=r}Fe(n);let f=n.filter(e=>e.isGroup&&!e.parentId);if(f.length===0)return t===`RL`&&Ie(e,`x`),!0;let p=Ae(n),m=new Map;for(let e of n){if(e.isGroup)continue;let t=je(e,p);if(!t)continue;let n=m.get(t)??[];n.push(e),m.set(t,n)}let h=0;for(let e of f){let t=e.padding??0;t>h&&(h=t)}let g=[],_=1/0,v=-1/0;for(let e of f){let t=Ne(m.get(e.id)??[]);t&&(_=Math.min(_,t.minX),v=Math.max(v,t.maxX),g.push({lane:e,contentTop:t.minY,contentBottom:t.maxY,centerY:(t.minY+t.maxY)/2}))}if(_===1/0||v===-1/0)return!0;let y=Math.max(0,v-_)+2*Math.max(h,10),b=36+y,x=(_+v)/2-y/2-36,S=x+b/2,C=Math.max(h,36);g.sort((e,t)=>e.centerY-t.centerY);for(let e=0;ed.cy?g.bottom:g.top,t=d.cx+n;if(t<=g.left+ze||t>=g.right-ze)continue;i={x:t,y:e},a={x:t,y:o.y},c={x:o.x,y:o.y}}else{let e=f.cx>d.cx?g.right:g.left,t=d.cy+n;if(t<=g.top+ze||t>=g.bottom-ze)continue;i={x:e,y:t},a={x:o.x,y:t},c={x:o.x,y:o.y}}let p=v(i,a,ze),m=v(a,c,ze);if(p&&m||!p&&B(i,a,r,[l],1)||!m&&B(a,c,r,[u],1))continue;let _=!p&&ae(i,a,e,t,{epsilon:ze,skipDegenerateOther:!0}),y=!m&&ae(a,c,e,t,{epsilon:ze,skipDegenerateOther:!0});if(!(_||y)){h=p?[a,c]:m?[i,a]:[i,a,c];break}}h&&(t.points=h)}}t(He,`portSwapToLShape`);function Ue(e,n){let r=.001,{realNodeRects:i,labelNodeRects:a}=z(n.values());for(let o of e){if(o.isLayoutOnly)continue;let s=o.points;if(!s||s.length<4)continue;let c=D(s,r);if(c.length<4)continue;let l=c.length-1,u=c[l],d=c[l-1],f=c[l-2],p=u.x-d.x,m=u.y-d.y,h=Math.hypot(p,m);if(h>=10||h0;P={x:f.x,y:M},I={x:e?N.right:N.left,y:M}}if(B(P,I,i,E?[E]:[],-2)||B(P,I,a,[],-2))continue;if(O){let e=n.get(O),t=e?F(e):void 0;if(t&&A(P,t,2))continue}let ee=t((e,t)=>`${e.x.toFixed(3)},${e.y.toFixed(3)}|${t.x.toFixed(3)},${t.y.toFixed(3)}`,`ownSegmentKey`),L=new Set;for(let e=0;e{for(let i of e){if(i===o||i.isLayoutOnly)continue;let e=i.points;if(!(!e||e.length<2))for(let i=0;i=0){let e=c[l-3],t=[O,E].filter(e=>!!e);if(B(e,P,i,t,-2)||R(e,P))continue}let z=[...c.slice(0,l-2),P,I];o.points=z;let te=o.labelNodeId;if(te){let e=n.get(te);if(e){let t=e.width??0,n=e.height??0;if(t>0&&n>0){let i,a,o=-1;for(let e=0;e=t+2||d&&l>=n+2)&&l>o&&(o=l,i=(s.x+c.x)/2,a=(s.y+c.y)/2)}i!==void 0&&a!==void 0&&(e.x=i,e.y=a)}}}}}t(Ue,`collapseShortTerminalStub`);var Y=.001,X=8,Z=T,We=t((e,t)=>y(e,t,Y)||b(e,t,Y),`orthogonallyAligned`);function Ge(e,n){let r=t((e,t)=>{let n=e.x??0,r=e.y??0,i=t.x-n,a=t.y-r,o=(e.width??0)/2,s=(e.height??0)/2;return Math.abs(a)*o>Math.abs(i)*s?(a<0&&(s=-s),{x:n+(a===0?0:s*i/a),y:r+s}):(i<0&&(o=-o),{x:n+o,y:r+(i===0?0:o*a/i)})},`rectIntersect`),i=t((e,t)=>{let i=D(e.points??[]);if(i.length<2)return;let a=t?e.start:e.end,o=a?n.get(a):void 0,s=o?F(o):void 0;if(!o||!a||!s)return;let c=t?i[0]:i[i.length-1],l=t?i[1]:i[i.length-2],u=r(o,c),d=c;if(We(l,u)&&(d=l),y(u,d,Y))return{edge:e,edgeId:String(e.id??``),nodeId:a,atStart:t,orientation:`V`,coord:u.x,min:Math.min(u.y,d.y),max:Math.max(u.y,d.y),boundary:u,railEnd:d,rect:s};if(b(u,d,Y))return{edge:e,edgeId:String(e.id??``),nodeId:a,atStart:t,orientation:`H`,coord:u.y,min:Math.min(u.x,d.x),max:Math.max(u.x,d.x),boundary:u,railEnd:d,rect:s}},`terminalLaneFor`),a=t((e,t)=>Math.max(0,Math.min(e.max,t.max)-Math.max(e.min,t.min)),`projectedOverlapLength`),o=t((e,t)=>e.nodeId!==t.nodeId||e.orientation!==t.orientation?!1:e.orientation===`H`?(Math.abs(e.boundary.x-e.rect.left)<1||Math.abs(e.boundary.x-e.rect.right)<1)&&y(e.boundary,t.boundary,1):(Math.abs(e.boundary.y-e.rect.top)<1||Math.abs(e.boundary.y-e.rect.bottom)<1)&&b(e.boundary,t.boundary,1),`sameTerminalFace`),s=t((e,t)=>e.nodeId!==t.nodeId||e.orientation!==t.orientation?!1:a(e,t)>=X&&Math.abs(e.coord-t.coord)<.5,`exactTerminalLaneConflict`),c=t((e,t)=>{if(e.nodeId!==t.nodeId||e.orientation!==t.orientation||e.orientation!==`H`||e.atStart===t.atStart)return!1;let n=a(e,t);if(n2*r?!1:o(e,t)&&Math.abs(e.coord-t.coord)<16},`nearTerminalLaneConflict`),l=t((e,n)=>{let r=D(e.edge.points??[]);if(r.length<2)return;let i=e.orientation===`V`?{x:e.boundary.x+n,y:e.boundary.y}:{x:e.boundary.x,y:e.boundary.y+n},a=e.orientation===`V`?{x:e.railEnd.x+n,y:e.railEnd.y}:{x:e.railEnd.x,y:e.railEnd.y+n};if(!t(()=>Math.abs(e.boundary.y-e.rect.top)<1||Math.abs(e.boundary.y-e.rect.bottom)<1?b(i,e.boundary,Y)&&i.x>=e.rect.left+1&&i.x<=e.rect.right-1:Math.abs(e.boundary.x-e.rect.left)<1||Math.abs(e.boundary.x-e.rect.right)<1?y(i,e.boundary,Y)&&i.y>=e.rect.top+1&&i.y<=e.rect.bottom-1:!1,`boundaryStaysOnSameFace`)())return;if(e.atStart){let t=r.length>1&&v(r[1],e.railEnd,Y),n=r.slice(t?2:1),o=n[0];return o&&!We(o,a)?void 0:[i,a,...n]}let o=r.length>1&&v(r[r.length-2],e.railEnd,Y),s=r.slice(0,o?-2:-1),c=s[s.length-1];if(!(c&&!We(c,a)))return[...s,a,i]},`shiftedCandidate`),u=t(e=>{let t=e.edge,r=D(t.points??[]);if(r.length!==2)return!1;let i=t.start,a=t.end,o=i?n.get(i):void 0,s=a?n.get(a):void 0;if(!o||!s)return!1;let c=o.x??0,l=o.y??0,u=s.x??0,d=s.y??0,[f,p]=r;return b(f,p,Y)&&Math.abs(l-d)<1&&Math.abs(c-u)>1||y(f,p,Y)&&Math.abs(c-u)<1&&Math.abs(l-d)>1},`laneIsStraightCollinearConnector`),d=[-7,7,-14,14,-21,21];for(let t=0;t<8;t++){let t=e.filter(e=>!e.isLayoutOnly).flatMap(e=>[i(e,!0),i(e,!1)]).filter(e=>!!e),n=!1;for(let e=0;e{let n=u(e),r=u(t);return n===r?Number(!t.atStart)-Number(!e.atStart):Number(n)-Number(r)});for(let e of p){for(let r of d){let a=l(e,r);if(!a)continue;let o=i({...e.edge,points:a},e.atStart);if(!(!o||t.some(t=>t.edge!==e.edge&&(s(o,t)||f&&c(o,t))))){e.edge.points=a,n=!0;break}}if(n)break}}if(!n)return}}t(Ge,`separateSharedRenderedTerminalLanes`);function Ke(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=t((t,n)=>{let a=t.start,o=t.end,s=Z(n);if(s.length!==n.length-1)return!1;let c=[a,o].filter(e=>!!e);for(let e of s)if(B(e.a,e.b,r,c,-2)||B(e.a,e.b,i,[],-2))return!1;for(let n of e){if(n===t||n.isLayoutOnly)continue;let e=n.points;if(!(!e||e.length<2)){for(let t of s)for(let n of Z(D(e)))if(w(t,n,.5)>=X||V(t.a,t.b,n.a,n.b,Y))return!1}}return!0},`candidateIsSafe`),o=t((e,t)=>{if(t+4>=e.length)return;let n=e[t],r=e[t+1],i=e[t+2],a=e[t+3],o=e[t+4],s=x(n,r)&&S(r,i)&&x(i,a)&&S(a,o)&&y(n,a,Y)&&y(n,o,Y)&&y(r,i,Y)&&(r.x-n.x)*(a.x-i.x)<0,c=S(n,r)&&x(r,i)&&S(i,a)&&x(a,o)&&b(n,a,Y)&&b(n,o,Y)&&b(r,i,Y)&&(r.y-n.y)*(a.y-i.y)<0;if(s||c)return D([...e.slice(0,t+1),o,...e.slice(t+5)]);if(t+5>=e.length)return;let l=e[t+5],u=S(n,r)&&x(r,i)&&S(i,a)&&x(a,o)&&S(o,l)&&y(n,o,Y)&&y(n,l,Y)&&y(i,a,Y)&&(i.x-r.x)*(o.x-a.x)<0,d=x(n,r)&&S(r,i)&&x(i,a)&&S(a,o)&&x(o,l)&&b(n,o,Y)&&b(n,l,Y)&&b(i,a,Y)&&(i.y-r.y)*(o.y-a.y)<0;if(!(!u&&!d))return D([...e.slice(0,t+1),l,...e.slice(t+6)])},`withoutDogleg`);for(let t=0;t<8;t++){let t=!1;for(let n of e){if(n.isLayoutOnly)continue;let e=D(n.points??[]);for(let r=0;r<=e.length-5;r++){let i=o(e,r);if(!(!i||!a(n,i))){n.points=i,t=!0;break}}if(t)break}if(!t)return}}t(Ke,`collapseRedundantRectangularDoglegs`);function qe(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t,n)=>D(e===t?n??[]:e.points??[]),`pointsFor`),s=t((e,t)=>{let n=0;for(let r=0;r{let t=Z(e);if(t.length!==3)return;let n=t[1];if(t[0].horizontal!==n.horizontal&&t[2].horizontal!==n.horizontal)return{index:n.index,horizontal:n.horizontal,vertical:n.vertical,segment:n}},`middleRail`),l=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);return r.filter(e=>{if(n.includes(e.id))return!1;let r=e.rect;return t.horizontal?C(t.a.x,t.b.x,r.left,r.right)>=X&&t.a.y>=r.top-2&&t.a.y<=r.bottom+2:C(t.a.y,t.b.y,r.top,r.bottom)>=X&&t.a.x>=r.left-2&&t.a.x<=r.right+2})},`blockingRectsFor`),u=t((e,t,n)=>{let r=e.map(e=>({...e}));if(t.horizontal)r[t.index].y=n,r[t.index+1].y=n;else if(t.vertical)r[t.index].x=n,r[t.index+1].x=n;else return;let i=G(D(r));return Z(i).length===i.length-1?i:void 0},`candidateByMovingRail`),d=t((e,t,n)=>{let c=[e.start,e.end].filter(e=>!!e),l=Z(t);if(l.length!==t.length-1)return!1;for(let e of l)if(B(e.a,e.b,r,c,-2)||B(e.a,e.b,i,[],-2))return!1;for(let t of a)if(t!==e){for(let e of l)for(let n of Z(o(t)))if(w(e,n,.5)>=X)return!1}return s(e,t)<=n},`candidateIsSafe`);for(let e=0;e<8;e++){let e=s(),t=!1;for(let n of a){let r=o(n),i=c(r);if(!i)continue;let a=l(n,i.segment);if(a.length===0)continue;let s=i.horizontal?[Math.min(...a.map(e=>e.rect.top))-20,Math.max(...a.map(e=>e.rect.bottom))+20]:[Math.min(...a.map(e=>e.rect.left))-20,Math.max(...a.map(e=>e.rect.right))+20];for(let a of s){let o=u(r,i.segment,a);if(!(!o||!d(n,o,e))){n.points=o,t=!0;break}}if(t)break}if(!t)return}}t(qe,`liftObstacleHuggingSameSideRails`);function Je(e,n){let r=t(e=>{let t=e.groupTitleRect;if(!(!t||typeof t.left!=`number`||typeof t.right!=`number`||typeof t.top!=`number`||typeof t.bottom!=`number`||!Number.isFinite(t.left)||!Number.isFinite(t.right)||!Number.isFinite(t.top)||!Number.isFinite(t.bottom)||t.right<=t.left||t.bottom<=t.top))return{left:t.left,right:t.right,top:t.top,bottom:t.bottom}},`validTitleRect`),i=t(e=>{if(!e.isGroup||e.parentId)return;let t=e.direction,n=typeof t==`string`?t.toUpperCase():``;if(n===`LR`||n===`RL`||n===`BT`)return;let i=r(e),a=e.y,o=e.height;if(!i||typeof a!=`number`||typeof o!=`number`||!Number.isFinite(a)||!Number.isFinite(o)||o<=0)return;let s=i.right-i.left,c=i.bottom-i.top;if(!(c<=0||s{if(!e.horizontal)return!1;let n=e.a.y;return n<=t.top+Y||n>=t.bottom-Y?!1:C(e.a.x,e.b.x,t.left,t.right)>=X},`horizontalSegmentIntersectsTitle`),o=[...n.values()].map(i).filter(e=>!!e);if(o.length===0)return;let s=0;for(let t of e){if(t.isLayoutOnly)continue;let e=D(t.points??[]);for(let t of Z(e))for(let e of o)a(t,e.rect)&&(s=Math.max(s,e.rect.bottom-t.a.y+4))}if(!(s<=Y))for(let e of o){let t=e.node.y,n=e.node.height;typeof t!=`number`||typeof n!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||n<=0||(e.node.y=t-s/2,e.node.height=n+s,e.node.groupTitleRect={...e.rect,top:e.rect.top-s,bottom:e.rect.bottom-s})}}t(Je,`liftTopLaneTitleBandsAboveRails`);function Ye(e,n){let r=t(e=>{let t=e.groupTitleRect;if(!(!t||typeof t.left!=`number`||typeof t.right!=`number`||typeof t.top!=`number`||typeof t.bottom!=`number`||!Number.isFinite(t.left)||!Number.isFinite(t.right)||!Number.isFinite(t.top)||!Number.isFinite(t.bottom)||t.right<=t.left||t.bottom<=t.top))return{left:t.left,right:t.right,top:t.top,bottom:t.bottom}},`validTitleRect`),i=t(e=>{if(!e.isGroup||e.parentId||e.direction!==`LR`)return;let t=r(e),n=e.x,i=e.width;if(!t||typeof n!=`number`||typeof i!=`number`||!Number.isFinite(n)||!Number.isFinite(i)||i<=0)return;let a=t.right-t.left,o=t.bottom-t.top;if(!(a<=0||o{if(!e.vertical)return!1;let n=e.a.x;return n<=t.left+Y||n>=t.right-Y?!1:C(e.a.y,e.b.y,t.top,t.bottom)>=X},`verticalSegmentIntersectsTitle`),o=t((e,t)=>{if(!e.horizontal)return!1;let n=e.a.y;return n<=t.top+Y||n>=t.bottom-Y?!1:C(e.a.x,e.b.x,t.left,t.right)>=X},`horizontalSegmentIntersectsTitle`),s=[...n.values()].map(i).filter(e=>!!e);if(s.length===0)return;let c=0;for(let t of e){if(t.isLayoutOnly)continue;let e=D(t.points??[]);for(let t of Z(e))for(let e of s)if(a(t,e.rect))c=Math.max(c,e.rect.right-t.a.x+4);else if(o(t,e.rect)){let n=Math.min(t.a.x,t.b.x);c=Math.max(c,e.rect.right-n+4)}}if(!(c<=Y))for(let e of s){let t=e.node.x,n=e.node.width;typeof t!=`number`||typeof n!=`number`||!Number.isFinite(t)||!Number.isFinite(n)||n<=0||(e.node.x=t-c/2,e.node.width=n+c,e.node.groupTitleRect={...e.rect,left:e.rect.left-c,right:e.rect.right-c})}}t(Ye,`shiftLeftLaneTitleBandsLeftOfRails`);function Xe(e,n){let{realNodeRects:r}=z(n.values()),i=e.filter(e=>!e.isLayoutOnly),a=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),o=t((e=new Map)=>{let t=0;for(let n=0;ni.reduce((t,n)=>t+E(a(n,e)),0),`totalBends`),c=t(e=>{let t=a(e);if(t.length<4)return;let n=t[t.length-2],r=t[t.length-1];if(!(!x(n,r,Y)&&!S(n,r,Y)))return{tailStart:n,terminal:r}},`terminalTailFor`),l=t((e,t)=>{let n=a(e);if(n.length<3)return;let r=n[0],i=n[1],o;if(x(r,i,Y))o={x:i.x,y:t.tailStart.y};else if(S(r,i,Y))o={x:t.tailStart.x,y:i.y};else return;let s=G(D([r,i,o,t.tailStart,t.terminal]));return Z(s).length===s.length-1?s:void 0},`candidateWithDestinationTail`),u=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);for(let e of Z(t))if(B(e.a,e.b,r,n,-2))return!0;return!1},`pathHasNodeHit`),d=t((e,t,n)=>{for(let r of i)if(r!==e){for(let e of Z(t))for(let t of Z(a(r,n)))if(w(e,t,.5)>=X)return!0}return!1},`pathHasSharedTrack`),f=t((e,t,n)=>!u(e,t)&&!d(e,t,n),`candidateIsSafe`),p=t(()=>{let e=new Map;for(let t of i){let r=t.end;if(!r||!n.has(r)||a(t).length<4)continue;let i=e.get(r)??[];i.push(t),e.set(r,i)}return e},`edgesByDestination`);for(let e=0;e<4;e++){let e=o();if(e===0)return;let t=s(),n,r=e,i=t;for(let t of p().values())for(let a=0;a=e||y>r||y===r&&b>=i||(n=v,r=y,i=b)}if(!n)return;for(let[e,t]of n)e.points=t}}t(Xe,`swapDestinationTerminalTailsToReduceCrossings`);function Ze(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),s=t((e=new Map)=>{let t=0;for(let n=0;na.reduce((t,n)=>t+E(o(n,e)),0),`totalBends`),l=t(e=>{let t=e.start,r=e.end,i=t?n.get(t):void 0,a=r?n.get(r):void 0,o=i?F(i):void 0,s=a?F(a):void 0;return o&&s?{src:o,dst:s}:void 0},`endpointRectsFor`),u=t((e,t,n)=>{if(n.index<=0||n.index+1>=t.length-1)return;let r=l(e);if(r){if(n.vertical){let i=n.a.x,a=Math.min(r.src.left,r.dst.left),o=Math.max(r.src.right,r.dst.right),s=io+Y?`right`:void 0;return s?{edge:e,points:t,segmentIndex:n.index,axis:`vertical`,side:s,coord:i,min:Math.min(n.a.y,n.b.y),max:Math.max(n.a.y,n.b.y)}:void 0}if(n.horizontal){let i=n.a.y,a=Math.min(r.src.top,r.dst.top),o=Math.max(r.src.bottom,r.dst.bottom),s=io+Y?`bottom`:void 0;return s?{edge:e,points:t,segmentIndex:n.index,axis:`horizontal`,side:s,coord:i,min:Math.min(n.a.x,n.b.x),max:Math.max(n.a.x,n.b.x)}:void 0}}},`externalRailForSegment`),d=t(()=>{let e=[];for(let t of a){let n=o(t);for(let r of Z(n)){let i=u(t,n,r);i&&e.push(i)}}return e},`collectExternalRails`),f=t((e,t)=>e.edge!==t.edge&&e.axis===t.axis&&e.side===t.side&&C(e.min,e.max,t.min,t.max)>=X,`railsInteract`),p=t(e=>{let t=[],n=new Set;for(let r of e){if(n.has(r))continue;let i=[r],a=[];for(n.add(r);i.length>0;){let t=i.pop();a.push(t);for(let r of e)!n.has(r)&&f(t,r)&&(n.add(r),i.push(r))}a.length>1&&t.push(a)}return t},`connectedComponents`),m=t(e=>{let t=[];for(let n of e)t.some(e=>Math.abs(e-n.coord){let n=e.map(e=>e.coord),r=m(e),i=[];if(e.length<=6){let a=Array(r.length).fill(!1),o=[],s=t(()=>{if(o.length===e.length){o.some((e,t)=>Math.abs(e-n[t])>=Y)&&i.push([...o]);return}for(let[e,t]of r.entries())a[e]||(a[e]=!0,o.push(t),s(),o.pop(),a[e]=!1)},`visit`);return s(),i}for(let e=0;e{let n=new Map;for(let[r,i]of e.entries()){let e=t[r],a=n.get(i.edge)??i.points.map(e=>({x:e.x,y:e.y}));i.axis===`vertical`?(a[i.segmentIndex].x=e,a[i.segmentIndex+1].x=e):(a[i.segmentIndex].y=e,a[i.segmentIndex+1].y=e),n.set(i.edge,a)}let r=new Map;for(let[e,t]of n){let n=G(D(t));if(Z(n).length!==n.length-1)return;r.set(e,n)}return r},`replacementsForAssignment`),_=t(e=>{for(let[t,n]of e){let e=[t.start,t.end].filter(e=>!!e);for(let t of Z(n))if(B(t.a,t.b,r,e,-2)||B(t.a,t.b,i,[],-2))return!1}for(let t=0;t=X)return!1}}return!0},`candidateIsSafe`);for(let e=0;e<4;e++){let e=s();if(e===0)return;let t,n=e,r=c(),i=1/0;for(let a of p(d()))for(let o of h(a)){let l=g(a,o);if(!l||!_(l))continue;let u=s(l);if(u>=e)continue;let d=c(l),f=a.reduce((e,t,n)=>e+Math.abs(o[n]-t.coord),0);u>n||u===n&&(d>r||d===r&&f>=i)||(t=l,n=u,r=d,i=f)}if(!t)return;for(let[e,n]of t)e.points=n}}t(Ze,`reassignCrossingExternalRailChannels`);function Qe(e,n){let{realNodeRects:r,labelNodeRects:i}=z(n.values()),a=e.filter(e=>!e.isLayoutOnly),o=t((e,t,n)=>D(e===t?n??[]:e.points??[]),`pointsFor`),s=t(e=>Z(e).reduce((e,t)=>{let n=t.a.x-t.b.x,r=t.a.y-t.b.y;return e+Math.hypot(n,r)},0),`pathLength`),c=t((e,t)=>{let n=0;for(let r=0;r{if(e.horizontal){let n=e.a.y;return(Math.abs(n-t.top)<1||Math.abs(n-t.bottom)<1)&&C(e.a.x,e.b.x,t.left,t.right)>=X}if(e.vertical){let n=e.a.x;return(Math.abs(n-t.left)<1||Math.abs(n-t.right)<1)&&C(e.a.y,e.b.y,t.top,t.bottom)>=X}return!1},`segmentRunsAlongRectBorder`),u=t(e=>{let t=[e.start,e.end].filter(e=>!!e),r=[];for(let e of t){let t=n.get(e),i=t?F(t):void 0;i&&r.push(i)}return r},`endpointRectsFor`),d=t((e,t)=>{if(t+3>=e.length)return[];let n=e[t],r=e[t+1],i=e[t+2],a=e[t+3],o=x(n,r,Y)&&S(r,i,Y)&&x(i,a,Y),s=S(n,r,Y)&&x(r,i,Y)&&S(i,a,Y);if(!o&&!s||!(o?Math.sign(r.x-n.x)!==Math.sign(a.x-i.x):Math.sign(r.y-n.y)!==Math.sign(a.y-i.y)))return[];let c=y(n,a,Y)||b(n,a,Y)?[]:[{x:n.x,y:a.y},{x:a.x,y:n.y}],l=c.length===0?[[...e.slice(0,t+1),...e.slice(t+3)]]:c.map(n=>[...e.slice(0,t+1),n,...e.slice(t+3)]),u=new Set;return l.map(e=>G(D(e))).filter(e=>{if(Z(e).length!==e.length-1||!e.some(e=>v(e,a,Y)))return!1;let t=e.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return!u.has(t)&&(u.add(t),!0)})},`shortcutCandidatesAt`),f=t((e,t,n)=>{let s=[e.start,e.end].filter(e=>!!e),d=u(e);for(let e of Z(t))if(B(e.a,e.b,r,s,-2)||B(e.a,e.b,i,[],-2)||d.some(t=>l(e,t)))return!1;for(let n of a)if(n!==e){for(let e of Z(t))for(let t of Z(o(n)))if(w(e,t,.5)>=X)return!1}return c(e,t)<=n},`candidateIsSafe`);for(let e=0;e<8;e++){let e=c(),t,n,r=e,i=1/0,l=1/0;for(let u of a){let a=o(u),p=E(a,Y),m=s(a);for(let o=0;o<=a.length-4;o++)for(let h of d(a,o)){let a=E(h,Y),o=s(h);if(!(ar||d===r&&(a>i||a===i&&o>=l)||(t=u,n=h,r=d,i=a,l=o)}}if(!t||!n)return;t.points=n}}t(Qe,`shortcutRedundantOrthogonalJogs`);function $e(e,n){let r=[];for(let e of n.values()){if(e.isGroup||e.isEdgeLabel)continue;let t=e.x??0,n=e.y??0,i=F(e);i&&r.push({id:String(e.id??``),cx:t,cy:n,rect:i})}if(r.length===0)return;let i=new Map(r.map(e=>[e.id,e])),a=r.map(e=>({id:e.id,rect:e.rect})),o=[`top`,`bottom`,`left`,`right`],s={top:Math.min(...r.map(e=>e.rect.top))-20,bottom:Math.max(...r.map(e=>e.rect.bottom))+20,left:Math.min(...r.map(e=>e.rect.left))-20,right:Math.max(...r.map(e=>e.rect.right))+20},c=e.filter(e=>!e.isLayoutOnly),l=new Map(c.map((e,t)=>[e,t])),u=t(e=>{let t=e===`left`||e===`top`?-1:1,n=[];for(let r=0;r<=2;r++)n.push(s[e]+t*20*r);return n},`outwardTracksForSide`),d=t((e,t=new Map)=>D(t.get(e)??e.points??[]),`replacementPointsFor`),f=t((e,t)=>{let n=0;for(let r of e)for(let e of t)V(r.a,r.b,e.a,e.b,Y)&&n++;return n},`crossingCountBetweenSegments`),p=t((e,t)=>f(Z(e),Z(t)),`crossingCountBetweenPaths`),m=t((e=new Map)=>{let n=0,r=[],i=new Set,a=[],o=t(e=>{i.has(e)||(i.add(e),a.push(e))},`addEdge`);for(let t=0;t0&&(n+=l,r.push({first:i,second:t,count:l}),o(i),o(t))}}return a.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),{count:n,pairs:r,edgeSet:i,edges:a}},`crossingSnapshot`),h=t((e,t)=>{let n=new Set(t.keys());if(n.size===0)return e.count;let r=0;for(let t of e.pairs)(n.has(t.first)||n.has(t.second))&&(r+=t.count);let i=0;for(let e=0;e{let t=new Map;for(let n of e.pairs){let e=t.get(n.first)??new Set;e.add(n.second),t.set(n.first,e);let r=t.get(n.second)??new Set;r.add(n.first),t.set(n.second,r)}let n=[],r=new Set;for(let i of e.edges){if(r.has(i))continue;let e=[i],a=[];for(r.add(i);e.length>0;){let n=e.pop();a.push(n);for(let i of t.get(n)??[])r.has(i)||(r.add(i),e.push(i))}a.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),a.length>1&&n.push(a)}return n},`crossingComponents`),_=t(e=>[e.start,e.end].filter(e=>!!e),`endpointIdsFor`),v=t(e=>{let t=[];for(let n of g(e)){let e=new Set(n),r=new Set(n.flatMap(e=>_(e))),i=[...n];for(let t of c)e.has(t)||_(t).some(e=>r.has(e))&&i.push(t);i.sort((e,t)=>(l.get(e)??0)-(l.get(t)??0)),t.push(i)}return t},`pairSearchGroups`),y=t((e,t,n)=>h(e,new Map([[t,n]])),`crossingCountWithSingleReplacement`),b=t(e=>{let t=new Map;for(let n of e.pairs)t.set(n.first,(t.get(n.first)??0)+n.count),t.set(n.second,(t.get(n.second)??0)+n.count);return t},`currentCrossingsByEdge`),C=t(e=>e.slice(1).reduce((t,n,r)=>{let i=e[r];return t+Math.abs(n.x-i.x)+Math.abs(n.y-i.y)},0),`pathLength`),T=t((e=new Map)=>c.reduce((t,n)=>t+E(d(n,e)),0),`totalBends`),O=t((e=new Map)=>c.reduce((t,n)=>t+C(d(n,e)),0),`totalLength`),k=t((e,t,n=new Map)=>{let r=Z(t);for(let t of c)if(t!==e){for(let e of r)for(let r of Z(d(t,n)))if(w(e,r,.5)>=X)return!0}return!1},`pathHasSegmentConflict`),A=t((e,t)=>{let n=[e.start,e.end].filter(e=>!!e);for(let e of Z(t))if(B(e.a,e.b,a,n,-2))return!0;return!1},`pathHitsNode`),j=t((e,t)=>{let n=G(D(t));Z(n).length===n.length-1&&e.push(n)},`pushOrthogonalCandidate`),M=t(e=>e===`left`||e===`right`,`sideIsHorizontal`),N=t((e,t,n)=>{switch(t){case`left`:return Math.min(e.x,n.x)-20;case`right`:return Math.max(e.x,n.x)+20;case`top`:return Math.min(e.y,n.y)-20;case`bottom`:return Math.max(e.y,n.y)+20}},`localTrackForSameSide`),P=t((e,t,n,r)=>{let i=n===`left`||n===`top`?-1:1,a=[N(t,n,r),s[n]];for(let o of a)for(let a=0;a<=2;a++)j(e,L(t,n,r,o+i*20*a))},`addSameSideCandidates`),R=t((e,t,n,r,i)=>{for(let a of u(n))for(let n of u(i))j(e,[t,{x:a,y:t.y},{x:a,y:n},{x:r.x,y:n},r])},`addHorizontalToVerticalCandidates`),z=t((e,t,n,r,i)=>{for(let a of u(n))for(let n of u(i))j(e,[t,{x:t.x,y:a},{x:n,y:a},{x:n,y:r.y},r])},`addVerticalToHorizontalCandidates`),te=t((e,t,n,r,i)=>{let a=[...u(`top`),...u(`bottom`)];for(let o of u(n))for(let n of u(i))for(let i of a)j(e,[t,{x:o,y:t.y},{x:o,y:i},{x:n,y:i},{x:n,y:r.y},r])},`addHorizontalPairCandidates`),ne=t((e,t,n,r,i)=>{let a=[...u(`left`),...u(`right`)];for(let o of u(n))for(let n of u(i))for(let i of a)j(e,[t,{x:t.x,y:o},{x:i,y:o},{x:i,y:n},{x:r.x,y:n},r])},`addVerticalPairCandidates`),re=t(e=>{let t=new Set;return e.map(e=>D(e)).filter(e=>{let n=e.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return t.has(n)||e.length<2?!1:(t.add(n),!0)})},`dedupeCandidatePaths`),ie=t((e,t,n,r)=>{let i=[],a=ee(e,t,n,r,20,Y);a&&j(i,a),t===r&&P(i,e,t,n);let o=M(t),s=M(r);return o&&!s?R(i,e,t,n,r):!o&&s?z(i,e,t,n,r):o?te(i,e,t,n,r):ne(i,e,t,n,r),re(i)},`buildCandidatesForSides`),ae=t((e,t,n,r)=>{let i=[...u(`left`),...u(`right`)],a=[...u(`top`),...u(`bottom`)];for(let s of o){let o=I(r,s),c=s===`top`||s===`bottom`?u(s):a;for(let r of i){j(e,[t,n,{x:r,y:n.y},{x:r,y:o.y},o]);for(let i of c)j(e,[t,n,{x:r,y:n.y},{x:r,y:i},{x:o.x,y:i},o])}}},`addVerticalDepartureOuterTrackCandidates`),oe=t((e,t,n,r)=>{let i=[...u(`left`),...u(`right`)],a=[...u(`top`),...u(`bottom`)];for(let s of o){let o=I(r,s),c=s===`left`||s===`right`?u(s):i;for(let r of a){j(e,[t,n,{x:n.x,y:r},{x:o.x,y:r},o]);for(let i of c)j(e,[t,n,{x:n.x,y:r},{x:i,y:r},{x:i,y:o.y},o])}}},`addHorizontalDepartureOuterTrackCandidates`),H=t(e=>{let t=e.start,n=e.end,r=n?i.get(n):void 0;if(!t||!r)return[];let a=D(e.points??[]);if(a.length<4)return[];let o=a[0],s=a[1],c=[];return S(o,s,Y)?ae(c,o,s,r):x(o,s,Y)&&oe(c,o,s,r),c},`terminalPreservingOuterTrackCandidates`),U=t(e=>{let t=e.start,n=e.end,r=t?i.get(t):void 0,a=n?i.get(n):void 0;if(!r||!a)return[];let s=[];for(let e of o){let t=I(r,e);for(let n of o)s.push(...ie(t,e,I(a,n),n))}return s.push(...H(e)),s},`candidatePathsFor`),W=t(()=>new Map(c.map(e=>[e,Z(d(e))])),`currentSegmentsByEdge`),K=t((e,t,n)=>{let r=new Set;for(let i of c){if(i===e)continue;let a=n.get(i)??Z(d(i));t.some(e=>a.some(t=>w(e,t,.5)>=X))&&r.add(i)}return r},`sharedTrackConflictsFor`),se=t((e,t,n,r)=>{let i=new Set;return U(e).map(e=>G(D(e))).filter(t=>{if(A(e,t))return!1;let n=t.map(e=>`${e.x.toFixed(3)},${e.y.toFixed(3)}`).join(`|`);return i.has(n)||t.length<2?!1:(i.add(n),!0)}).map(i=>{let a=Z(i),o=0;for(let t of c)t!==e&&(o+=f(a,n.get(t)??Z(d(t))));return{candidate:i,candidateSegments:a,crossings:t.count-(r.get(e)??0)+o,bends:E(i,Y),totalBends:E(i),length:C(i)}}).filter(({crossings:e})=>e<=t.count).sort((e,t)=>e.crossings-t.crossings||e.bends-t.bends||e.length-t.length).slice(0,48).map(t=>({path:t.candidate,segments:t.candidateSegments,sharedTrackConflicts:K(e,t.candidateSegments,n),totalBends:t.totalBends,length:t.length}))},`pairCandidatesFor`),ce=t((e,t,n,r,i,a)=>{let o=0;for(let n of e.pairs)(n.first===t||n.second===t||n.first===r||n.second===r)&&(o+=n.count);let s=f(n.segments,i.segments);for(let e of c){if(e===t||e===r)continue;let o=a.get(e)??Z(d(e));s+=f(n.segments,o)+f(i.segments,o)}return e.count-o+s},`pairCrossingCount`),le=t((e,t)=>{for(let n of e.sharedTrackConflicts)if(n!==t)return!1;return!0},`conflictsOnlyWith`),ue=t((e,t)=>e.segments.some(e=>t.segments.some(t=>w(e,t,.5)>=X)),`candidatesShareTrack`),de=t((e,t,n,r)=>le(t,n.edge)&&le(r,e.edge)&&!ue(t,r),`pairCandidatesAreCompatible`),q=t((e,t,n,r,i)=>{let a=ce(e.current,t.edge,n,r.edge,i,e.baseSegments);if(!(a>=e.current.count))return{replacements:new Map([[t.edge,n.path],[r.edge,i.path]]),crossings:a,bends:e.currentBends-(e.baseBendsByEdge.get(t.edge)??0)-(e.baseBendsByEdge.get(r.edge)??0)+n.totalBends+i.totalBends,length:e.currentLength-(e.baseLengthByEdge.get(t.edge)??0)-(e.baseLengthByEdge.get(r.edge)??0)+n.length+i.length}},`scorePairReplacement`),J=t((e,t)=>e.crossings{let i=r;for(let r of t.candidates)for(let a of n.candidates){if(!de(t,r,n,a))continue;let o=q(e,t,r,n,a);o&&J(o,i)&&(i=o)}return i},`bestScoreForOptionPair`),pe=t(e=>{let t=T(),n=O(),r=W(),i=b(e),a=new Map(c.map(e=>[e,E(d(e))])),o=new Map(c.map(e=>[e,C(d(e))])),s=new Map,l=v(e);for(let t of l)for(let n of t){if(s.has(n))continue;let t=se(n,e,r,i);t.length>0&&s.set(n,{edge:n,candidates:t})}let u={replacements:new Map,crossings:e.count,bends:t,length:n},f={current:e,currentBends:t,currentLength:n,baseBendsByEdge:a,baseLengthByEdge:o,baseSegments:r};for(let t of l){let n=new Set(t.filter(t=>e.edgeSet.has(t))),r=t.map(e=>s.get(e)).filter(e=>!!e);for(let e=0;e0?u.replacements:void 0},`bestPairedReplacement`);for(let e=0;e<4;e++){let e=m(),t=e.count;if(t===0)return;let n,r,i=t,a=1/0;for(let o of e.edges){let s=E(d(o),Y);for(let c of U(o)){let l=A(o,c),u=!l&&k(o,c),d=y(e,o,c),f=E(c,Y);l||u||(di||d===i&&f>=a||(n=o,r=c,i=d,a=f))}}if(n&&r){n.points=r;continue}let o=pe(e);if(!o)return;for(let[e,t]of o)e.points=t}}t($e,`resolveRenderedOrthogonalCrossings`);var et=.001,tt=8;function nt(e,n){let{nodeInfoById:r,realNodeRects:i}=R(n),a=[`top`,`bottom`,`left`,`right`],o={top:Math.min(...i.map(e=>e.rect.top))-20,bottom:Math.max(...i.map(e=>e.rect.bottom))+20,left:Math.min(...i.map(e=>e.rect.left))-20,right:Math.max(...i.map(e=>e.rect.right))+20},s=t((e,t,n,r)=>{let i=[],a=ee(e,t,n,r,20,et);return a&&i.push(a),t===r&&i.push(L(e,t,n,o[t])),i},`buildOrthogonalPathCandidates`),c=t((e,t)=>{for(let n=0;n{let i=0,a=T(t,et),o=n.start,s=n.end;for(let t of e){if(t===n||t.isLayoutOnly)continue;let e=t.start,c=t.end;if(!r&&o&&s&&(e===o||e===s||c===o||c===s))continue;let l=t.points;if(!(!l||l.length<2))for(let e of a)for(let t of T(l,et)){if(re(e.a,e.b,t.a,t.b,et,et)){i++;continue}w(e,t,et)>=tt&&i++}}return i},`pathConflictCount`),u=t((e,t)=>{let n=Math.abs(e.y-t.rect.top),r=Math.abs(e.y-t.rect.bottom),i=Math.abs(e.x-t.rect.left),a=Math.abs(e.x-t.rect.right),o=`top`,s=n;return r{let r=d.get(e)??[];r.push({side:t,edgeId:n}),d.set(e,r)},`addFaceClaim`);for(let t of e){if(t.isLayoutOnly)continue;let e=t.points??[];if(e.length<1)continue;let n=t.id??``,i=t.start,a=t.end;if(i){let t=r.get(i);t&&f(i,u(e[0],t),n)}if(a){let t=r.get(a);t&&f(a,u(e[e.length-1],t),n)}}let p=t((e,t,n)=>d.get(e)?.some(e=>e.edgeId!==n&&e.side===t)??!1,`faceIsClaimed`);for(let t of e){if(t.isLayoutOnly)continue;let e=t.points;if(!e||e.length<2)continue;let n=E(e,et);if(n<4)continue;let i=t.start,o=t.end;if(!i||!o)continue;let m=r.get(i),h=r.get(o);if(!m||!h)continue;let g=t.id??``,_=l(e,t,!0),v=l(e,t),y,b=_,x=n;for(let e of a){if(p(i,e,g))continue;let n=I(m,e);for(let r of a){if(p(o,r,g))continue;let a=I(h,r);for(let u of s(n,e,a,r)){if(c(u,[i,o]))continue;let e=E(u,et);if(_>0){let n=l(u,t,!0);if(n>b||n===b&&e>=x)continue;b=n,x=e,y=u;continue}l(u,t)>v||ee.edgeId!==g));let n=d.get(o);n&&d.set(o,n.filter(e=>e.edgeId!==g)),f(i,u(y[0],m),g),f(o,u(y[y.length-1],h),g)}}}t(nt,`simplifyDetouredEdges`);var Q=.001,rt=10,it=7;function at(e,t){let n=t?0:e.length-1,r=t?1:-1,i=e[n],a=e[n+r];if(!i||!a)return;let o=a.x-i.x,s=a.y-i.y;if(!(Math.abs(o)+Math.abs(s)t&&M(e,ot(t)))}t(st,`labelOverlapsOwnMarker`);function ct(e,n){let r=[];for(let t of e){if(t.isLayoutOnly)continue;let e=t.points;if(!(!e||e.length<2))for(let n=0;n{let n=N(t,3);for(let{nodeId:t,rect:r}of i)if(t!==e&&M(n,r))return!0;return!1},`labelOverlapsForeignNode`),s=t((e,t)=>{let n=N(t,3);for(let t of r)if(t.edgeId!==e&&k(t.p1,t.p2,n))return!0;return!1},`labelOverlapsForeignEdge`),c=t((e,t,n)=>o(e,n)||s(t,n),`labelOverlapsAnything`),l=[],u=t(e=>{for(let{id:t,rect:n}of a)if(j(n,e))return t},`findContainingLane`),d=t((e,t)=>l.some(n=>n.labelId!==e&&M(t,n.rect)),`overlapsPlacedLabel`);for(let r of e){if(r.isLayoutOnly)continue;let e=r.labelNodeId;if(!e)continue;let i=n.get(e);if(!i)continue;let f=r.points;if(!f||f.length<2)continue;let p=i.width??0,m=i.height??0;if(p<=0||m<=0)continue;let h=[];for(let e=0;e=Q&&i>=Q||h.push({idx:e,length:r+i,orientation:r>=Q?`horizontal`:`vertical`,midX:(t.x+n.x)/2,midY:(t.y+n.y)/2})}if(h.length===0)continue;let g=h.length>=3?h.filter(e=>e.idx>0&&e.idx0?g:h,v=p>=m?`horizontal`:`vertical`,y=t(e=>[...e].sort((e,t)=>{let n=e.orientation===v;if(n!==(t.orientation===v))return n?-1:1;let r=e.length>=(e.orientation===`horizontal`?p:m)+2;return r===t.length>=(t.orientation===`horizontal`?p:m)+2?t.length-e.length:r?-1:1}),`rankSegments`),b=h[0],x=h[h.length-1],S=[.5,.25,.75,.05,.95,.15,.85,.1,.9],C=t((e,t)=>{let n=f[e.idx],r=f[e.idx+1];return{midX:n.x+(r.x-n.x)*t,midY:n.y+(r.y-n.y)*t}},`anchorAtT`),w=t((e,t,n)=>Math.min(n,Math.max(t,e)),`clamp`),T=t((e,t)=>e.midX>=t.left-Q&&e.midX<=t.right+Q&&e.midY>=t.top-Q&&e.midY<=t.bottom+Q,`pointInsideRectInclusive`),E=t(e=>{let t=P(e.midX,e.midY,p,m),n=u(t);if(n)return{laneId:n,anchor:e,rect:t};let r=a.find(({rect:t})=>T(e,t));if(!r)return;let i=r.rect.left+p/2+1,o=r.rect.right-p/2-1,s=r.rect.top+m/2+1,c=r.rect.bottom-m/2-1;if(i>o||s>c)return;let l={midX:w(e.midX,i,o),midY:w(e.midY,s,c)},d=P(l.midX,l.midY,p,m);return T(e,d)?{laneId:r.id,anchor:l,rect:d}:void 0},`placementForAnchor`),D=t((e,t,n)=>e.orientation===`horizontal`?Math.abs(t.midX-n.x):Math.abs(t.midY-n.y),`distanceAlongSegment`),O=t((e,t)=>{let n=(e.orientation===`horizontal`?p/2:m/2)+12;if(e===b){let r=f[e.idx];if(D(e,t,r)+Q{let n=y(t);for(let t of n)for(let n of S){let i=C(t,n);if(!O(t,i))continue;let a=E(i);if(a&&!st(a.rect,f)&&!d(e,a.rect)&&!c(e,r.id,a.rect))return{laneId:a.laneId,anchor:a.anchor}}},`tryPool`),A=t((t,n,i=!1)=>{let a=y(t);for(let t of a){let a={midX:t.midX,midY:t.midY};if(n&&!O(t,a))continue;let c=E(a);if(c&&!st(c.rect,f)&&!d(e,c.rect)&&!o(e,c.rect)&&(i||!s(r.id,c.rect)))return{laneId:c.laneId,anchor:c.anchor}}},`findLaneContainingFallback`),j=k(_)??(_.lengtht.labelId===e);n>=0?l[n]={labelId:e,rect:t}:l.push({labelId:e,rect:t})}}}t(ct,`anchorLabelsToPolyline`);var lt=1e-6,ut=4,dt=3;function ft(e,t){return e{let s=ft(r,i),c=0,l=t(e=>{if(!e)return;let t=a.get(e);if(!t)return;let n=o===`x`?t.w/2:t.h/2;n>c&&(c=n)},`consider`);l(n.labelNodeId);for(let t of e){if(t===n||t.isLayoutOnly)continue;let e=t.start,r=t.end;!e||!r||ft(e,r)===s&&l(t.labelNodeId)}return c>0?c+dt:0},`labelClearanceFor`);for(let t of e){if(t.isLayoutOnly)continue;let n=t.points;if(!O(n,lt))continue;let a=ne(t,r,lt);if(!a)continue;let{srcId:s,dstId:c,srcInfo:l,dstInfo:u,collinearX:d,collinearY:f}=a;if(d===f)continue;let p,m;if(d){let e=u.cy>l.cy;p={x:l.cx,y:e?l.rect.bottom:l.rect.top},m={x:u.cx,y:e?u.rect.top:u.rect.bottom}}else{let e=u.cx>l.cx;p={x:e?l.rect.right:l.rect.left,y:l.cy},m={x:e?u.rect.left:u.rect.right,y:u.cy}}if(B(p,m,i,[s,c],1))continue;let h=o(t,s,c,d?`x`:`y`),g=h>ut?h:ut,_=[0,g,-g];for(let n of _){let r={...p},a={...m};if(d){if(r.x+=n,a.x+=n,r.x<=l.rect.left||r.x>=l.rect.right||a.x<=u.rect.left||a.x>=u.rect.right)continue}else if(r.y+=n,a.y+=n,r.y<=l.rect.top||r.y>=l.rect.bottom||a.y<=u.rect.top||a.y>=u.rect.bottom)continue;if(!B(r,a,i,[s,c],1)&&!ae(r,a,e,t,{epsilon:lt})){t.points=[r,a];break}}}}t(pt,`straightenCollinearSiblingDetours`);function mt(e,n){let r=.001,{realNodeRects:i,labelNodeRects:a}=z(n.values()),o=t((e,t)=>T(t,r).map(n=>({...n,edge:e,interior:n.index>=1&&n.index<=t.length-3})),`segmentsFor`),s=t(()=>{let t=[];for(let n of e){if(n.isLayoutOnly)continue;let e=n.points;!e||e.length<2||t.push(...o(n,D(e)))}return t},`allSegments`),c=t((e,t)=>e.horizontal&&t.horizontal?C(e.a.x,e.b.x,t.a.x,t.b.x)>=8&&Math.abs(e.a.y-t.a.y)<7:e.vertical&&t.vertical?C(e.a.y,e.b.y,t.a.y,t.b.y)>=8&&Math.abs(e.a.x-t.a.x)<7:!1,`hasCrowdedParallelTrack`),l=t((t,n)=>{let s=t.start,l=t.end,u=o(t,n);if(u.length!==n.length-1)return!1;let d=[s,l].filter(e=>!!e),f=t.labelNodeId?[t.labelNodeId]:[];for(let e of u)if(B(e.a,e.b,i,d,-2)||B(e.a,e.b,a,f,-2))return!1;for(let n of e){if(n===t||n.isLayoutOnly)continue;let e=n.points;if(!(!e||e.length<2)){for(let t of u)for(let i of o(n,D(e)))if(c(t,i)||V(t.a,t.b,i.a,i.b,r))return!1}}return!0},`candidateIsSafe`),u=t((e,t)=>{let n=D(e.edge.points??[]);if(n.length<4||e.index>=n.length-1)return;let r=n.map(e=>({...e}));if(e.horizontal)r[e.index].y+=t,r[e.index+1].y+=t;else if(e.vertical)r[e.index].x+=t,r[e.index+1].x+=t;else return;return o(e.edge,r).length===r.length-1?r:void 0},`shiftedCandidate`),d=t((e,t)=>({x:e.x??(t.left+t.right)/2,y:e.y??(t.top+t.bottom)/2}),`nodeCenter`),f=t(e=>{let t=e.edge,r=D(t.points??[]);if(r.length!==4||e.index!==1)return;let i=t.start?n.get(t.start):void 0,a=t.end?n.get(t.end):void 0,o=i?F(i):void 0,s=a?F(a):void 0,c=r.slice(e.index+2);if(!(!i||!a||!o||!s||c.length===0))return{sourceCenter:d(i,o),targetCenter:d(a,s),sourceRect:o,tail:c}},`sourceDetourContextFor`),p=t((e,t,n,i,a,o)=>{let s=i.y>=n.y,c=s?a.bottom:a.top,l=c+(s?20:-20);if(s&&e.b.y<=l+r||!s&&e.b.y>=l-r)return;let u=e.a.x+t;return D([{x:n.x,y:c},{x:n.x,y:l},{x:u,y:l},{x:u,y:e.b.y},...o],r)},`verticalSourceDetour`),m=t((e,t,n,i,a,o)=>{let s=i.x>=n.x,c=s?a.right:a.left,l=c+(s?20:-20);if(s&&e.b.x<=l+r||!s&&e.b.x>=l-r)return;let u=e.a.y+t;return D([{x:c,y:n.y},{x:l,y:n.y},{x:l,y:u},{x:e.b.x,y:u},...o],r)},`horizontalSourceDetour`),h=t((e,t)=>{let n=f(e);if(n){if(e.vertical)return p(e,t,n.sourceCenter,n.targetCenter,n.sourceRect,n.tail);if(e.horizontal)return m(e,t,n.sourceCenter,n.targetCenter,n.sourceRect,n.tail)}},`sourceDetourCandidate`),g=[-7,7,-14,14,-21,21];for(let e=0;e<12;e++){let e=s(),t=!1;for(let n=0;ne.interior);for(let e of o){for(let n of g){let r=u(e,n);if(r&&l(e.edge,r)){e.edge.points=r,t=!0;break}let i=h(e,n);if(i&&l(e.edge,i)){e.edge.points=i,t=!0;break}}if(t)break}}if(!t)return}}t(mt,`nudgeSharedInteriorSubpaths`);function ht(e,t,n,r){let i=t.x-e.x,a=t.y-e.y,o=r.x-n.x,s=r.y-n.y,c=i*s-a*o;if(Math.abs(c)<1e-10)return!1;let l=n.x-e.x,u=n.y-e.y,d=(l*s-u*o)/c,f=(l*a-u*i)/c,p=.01;return d>p&&d<.99&&f>p&&f<.99}t(ht,`segmentsIntersect`);function gt(t){let n=t.nodes??[],r=t.edges??[],i=[];if(!r.length||!n.length)return i;let a=te(n),o=[];for(let e of r){if(e.isLayoutOnly)continue;let t=e.points;if(!t||t.length<2)continue;let n=e.start,r=e.end,s=e.labelNodeId,c=e.id??`${n}->${r}`;for(let e of a)if(e.nodeId!==n&&e.nodeId!==r&&!(s&&e.nodeId===s)){for(let n=0;n0){let t=i.filter(e=>e.type===`edge-node-overlap`).length,n=i.filter(e=>e.type===`edge-edge-crossing`).length;e.warn(`[SWIMLANE_VALIDATE] ${i.length} issue(s) detected: ${t} edge-node overlap(s), ${n} edge crossing(s)`);for(let t of i)e.warn(`[SWIMLANE_VALIDATE] ${t.type}: ${t.detail}`)}return i}t(gt,`validateSwimlanesLayout`);function _t(e,n){let r=e.nodes??[],i=e.edges??[],a=r.filter(e=>!e.isGroup);if((n===`LR`||n===`RL`)&&a.length>0&&!Re(e,n)||n===`BT`&&a.length>0&&!Le(e))return;for(let e of i){if(e.isLayoutOnly)continue;let t=e.points;!t||t.length<2||(e.points=G(W(t)))}nt(i,r),pt(i,r),He(i,r);let o=new Map;for(let e of r)o.set(String(e.id),e);ct(i,o),q(i,o),Ue(i,o),mt(i,o),Ge(i,o),Ke(i,o),qe(i,o),Xe(i,o);let s=t(()=>{$e(i,o),Ze(i,o),Qe(i,o),ct(i,o),ke(i,o),qe(i,o),ct(i,o),ke(i,o)},`finalizeRenderedEdges`);s(),mt(i,o),s(),Je(i,o),Ye(i,o),Je(i,o),Ye(i,o)}t(_t,`postProcessSwimlaneLayout`);function vt(e){let t=new Map(e.nodeById),n=new Set,r=[];for(let i of e.edges){if(!t.has(i.src)||!t.has(i.dst))continue;let e=`${i.id}:${i.src}->${i.dst}`;n.has(e)||(n.add(e),r.push(i))}return{nodes:[...t.keys()],edges:r,layout:e.layout,nodeById:t}}t(vt,`normalizeGraph`);function yt(e,t){return e.edges.filter(e=>e.dst===t)}t(yt,`incoming`);function bt(e){let t=new Map;for(let n of e.nodes)t.set(n,[]);for(let n of e.edges)t.get(n.src).push(n.dst);return t}t(bt,`buildSuccessorMap`);function xt(e){let t=bt(e);for(let e of t.values())e.sort((e,t)=>e.localeCompare(t));return t}t(xt,`buildSortedSuccessorMap`);function St(e){let t=new Map;for(let n of e.nodes)t.set(n,0);for(let n of e.edges)t.set(n.dst,(t.get(n.dst)??0)+1);return t}t(St,`buildInDegreeMap`);function Ct(e){return[...e.entries()].filter(([,e])=>e===0).map(([e])=>e).sort((e,t)=>e.localeCompare(t))}t(Ct,`sortedZeroInDegreeNodes`);function wt(e,t=()=>!0){let n=new Map,r=new Map;for(let t of e.nodes)n.set(t,[]),r.set(t,[]);for(let i of e.edges)t(i)&&(r.get(i.src).push(i.dst),n.get(i.dst).push(i.src));return{preds:n,succs:r}}t(wt,`buildPredecessorSuccessorMaps`);function Tt(e,t,n,r){let i=0;for(let t of e.nodes)r?.skipGroups&&e.nodeById.get(t)?.isGroup||(i=Math.max(i,n[t]??0));let a=Array.from({length:i+1},()=>[]);for(let i of t)r?.skipGroups&&e.nodeById.get(i)?.isGroup||a[Math.max(0,n[i]??0)].push(i);return a}t(Tt,`buildLayersFromRanks`);function Et(e){let t=St(e),n=Ct(t),r=[],i=xt(e);for(;n.length;){let e=n.shift();r.push(e);for(let r of i.get(e)??[])if(t.set(r,(t.get(r)??0)-1),(t.get(r)??0)===0){let e=0;for(;e{if(i-t<=1)return 0;let a=t+i>>1,o=r(t,a)+r(a,i),s=t,c=a,l=t;for(;s=i||se.dst===t.dst?e.id.localeCompare(t.id):e.dst.localeCompare(t.dst));let i=Object.create(null);for(let e of n.nodes)i[e]=0;let a=[],o=t(e=>{i[e]=1;for(let t of r.get(e)??[]){let e=t.dst;i[e]===0?o(e):i[e]===1&&a.push(t)}i[e]=2},`dfs`),s=St(n),c=[...n.nodes.filter(e=>(s.get(e)??0)===0),...n.nodes.filter(e=>(s.get(e)??0)!==0)];for(let e of c)i[e]===0&&o(e);let l=new Set(a.map(e=>`${e.id}:${e.src}->${e.dst}`)),u=n.edges.map(e=>l.has(`${e.id}:${e.src}->${e.dst}`)?{id:e.id,src:e.dst,dst:e.src,weight:e.weight,ref:e.ref}:e);return{acyclic:{nodes:[...n.nodes],edges:u,layout:n.layout,nodeById:new Map(n.nodeById)},reversed:a}}t(kt,`removeCycles_DFS`);function At(e){let n=new Map,r=t(t=>{if(n.has(t))return n.get(t);let i=e.nodeById.get(t);if(!i)return n.set(t,null),null;let a=i.parentId;if(!a)return n.set(t,null),null;let o=r(a)??a;return n.set(t,o),o},`resolve`);for(let t of e.nodes)r(t);return n}t(At,`buildTopLaneMap`);function jt(e){let t=At(e);return e=>t.get(e)??null}t(jt,`createTopLaneResolver`);function Mt(e){let t=[];for(let n of e.layout.nodes??[])n.isGroup&&!n.parentId&&t.push(n.id);return[...new Set(t)].reverse()}t(Mt,`buildTopLaneOrder`);function Nt(e,t){let n=Mt(e);if(!t||t.length===0)return n;let r=new Set(n),i=new Set,a=[];for(let e of t)!r.has(e)||i.has(e)||(i.add(e),a.push(e));for(let e of n)i.has(e)||a.push(e);return a}t(Nt,`resolveTopLaneOrder`);var Pt={EPSILON:1e-6},Ft={GRAVITY_ITERATIONS:8,MAX_CROSSING_OPTIMIZATION_PASSES:4,DEFAULT_COMPACT_SINGLE_INPUT:!0},It={DEFAULT_LAYER_GAP:100,DEFAULT_NODE_GAP:40};function Lt(e,n){let r=vt(e),i=n?.laneOf??(()=>null),a=n?.rankHint,{preds:o}=wt(r);for(let e of o.values())e.sort((e,t)=>e.localeCompare(t));let s=Et(r)??[...r.nodes].sort((e,t)=>e.localeCompare(t)),c=new Map;for(let[e,t]of s.entries())c.set(t,e);let l=new Map,u=new Map;for(let e of r.nodes)u.set(e,[]);for(let e of s){let t=(o.get(e)??[]).filter(e=>l.has(e));if(t.length>0){let n=Rt(e,t,{laneOf:i,rankHint:a,topoIndex:c});l.set(e,n),u.get(n).push(e)}else l.has(e)||l.set(e,null)}for(let e of r.nodes)l.has(e)||l.set(e,null);let d=new Set;for(let e of r.nodes)(l.get(e)??null)===null&&d.add(e);let f=[...d].sort((e,t)=>{let n=c.get(e)??0,r=c.get(t)??0;return n===r?e.localeCompare(t):n-r}),p=zt(r),m=new Map;for(let[e,t]of p.entries())m.set(e,[...t].sort((e,t)=>e.localeCompare(t)));let h=Bt(m),g=Vt(m),_=new Map;for(let e of r.nodes)_.set(e,[]);for(let e of g)for(let t of e.nodes){let n=_.get(t);n?n.push(e.id):_.set(t,[e.id])}let v=[],y=[],b=new Set,x=t(e=>{if(!b.has(e)){b.add(e),v.push(e);for(let t of u.get(e)??[])x(t);y.push(e)}},`walk`);for(let e of f)x(e);for(let e of s)x(e);return{parent:l,children:u,roots:f,componentOf:h,blocks:g,nodeBlocks:_,adjacency:m,preorder:v,postorder:y,topologicalOrder:s}}t(Lt,`buildDrivingTree`);function Rt(e,t,n){let r=n.laneOf(e);return[...t].sort((e,t)=>{let i=n.laneOf(e),a=n.laneOf(t),o=i!=null&&i===r;if(o!==(a!=null&&a===r))return o?-1:1;let s=n.rankHint?.[e],c=n.rankHint?.[t];if(s!=null&&c!=null&&s!==c)return c-s;let l=n.topoIndex.get(e)??0,u=n.topoIndex.get(t)??0;return l===u?e.localeCompare(t):l-u})[0]}t(Rt,`chooseParent`);function zt(e){let t=new Map;for(let n of e.nodes)t.set(n,new Set);for(let n of e.edges)t.get(n.src).add(n.dst),t.get(n.dst).add(n.src);return t}t(zt,`buildAdjacency`);function Bt(e){let t=new Map,n=0;for(let r of e.keys()){if(t.has(r))continue;let i=[r];for(;i.length>0;){let r=i.pop();if(!t.has(r)){t.set(r,n);for(let n of e.get(r)??[])t.has(n)||i.push(n)}}n++}return t}t(Bt,`assignComponents`);function Vt(e){let n=new Map,r=new Map,i=[],a=[],o=0,s=t((t,c)=>{n.set(t,++o),r.set(t,o);for(let l of e.get(t)??[])l!==c&&(n.has(l)?(n.get(l)??0)<(n.get(t)??0)&&(i.push([t,l]),r.set(t,Math.min(r.get(t)??o,n.get(l)??o))):(i.push([t,l]),s(l,t),r.set(t,Math.min(r.get(t)??o,r.get(l)??o)),(r.get(l)??0)>=(n.get(t)??0)&&a.push(Ht(t,l,i,a.length))))},`visit`);for(let t of e.keys())n.has(t)||s(t,null);return a}t(Vt,`computeBlocks`);function Ht(e,t,n,r){let i=[],a=new Set;for(;n.length>0;){let r=n.pop();if(i.push(r),a.add(r[0]),a.add(r[1]),r[0]===e&&r[1]===t||r[0]===t&&r[1]===e)break}return{id:r,edges:i,nodes:[...a]}}t(Ht,`popBlock`);function Ut(e,n,r){let i=[...e.nodes],a=new Map;for(let[e,t]of i.entries())a.set(t,e);let o=i.length,s=Array(o).fill(-1),c=Array(o).fill(0),l=[],u=new Set;for(let e of i){let t=r.parent.get(e)??null,n=a.get(e);n!=null&&(t??(s[n]=-1,c[n]=0,u.has(e)||(u.add(e),l.push(e))))}for(;l.length>0;){let e=l.shift(),t=a.get(e);if(t==null)continue;let n=r.children.get(e)??[];for(let e of n){if(u.has(e))continue;let n=a.get(e);n!=null&&(s[n]=t,c[n]=c[t]+1,u.add(e),l.push(e))}}for(let e of i){if(u.has(e))continue;let t=a.get(e);t!=null&&(s[t]=-1,c[t]=0,u.add(e))}let d=Math.max(1,Math.ceil(Math.log2(Math.max(1,o)))+1),f=Array.from({length:d},()=>Array(o).fill(-1));for(let e=0;e{if(e===-1||t===-1)return-1;c[e]>t&1&&(e=f[t][e],e===-1))return-1;if(e===t)return e;for(let n=d-1;n>=0;n--){let r=f[n][e],i=f[n][t];r!==-1&&i!==-1&&r!==i&&(e=r,t=i)}return f[0][e]},`lcaIndex`),m=Array.from({length:o},()=>new Map);for(let t of e.edges){let e=t.src,r=t.dst,i=n[e],o=n[r];if(i==null||o==null||(i>o&&([e,r]=[r,e],[i,o]=[o,i]),i==null||o==null||i===o))continue;let s=a.get(e),c=a.get(r);if(s==null||c==null)continue;let l=p(s,c);if(l===-1)continue;let u=m[l];for(let e=i;e{if(t.size!==0)for(let[n,r]of t)e.set(n,(e.get(n)??0)+r)},`mergeInto`),_=new Set,v=t(e=>{let t=a.get(e);_.add(e);let i=t==null?void 0:m[t],o=i?new Map(i):new Map,s=r.children.get(e)??[];for(let t of s){let r=v(t),i=n[e];if(i!=null){let a=h.get(e);a||(a=new Map,h.set(e,a));let o=r.get(i)??0,s=n[t];s!=null&&s>i&&(o+=1),a.set(t,o)}g(o,r)}return o},`dfs`);for(let e of r.roots)_.has(e)||v(e);for(let e of i)_.has(e)||v(e);return h}t(Ut,`computeSubtreeCrossCounts`);function Wt(e,n,r){let i=new Map,a=t(e=>{let t=r[e]??0,o=[...n.get(e)??[]];o.sort(Gt(r));for(let e of o){a(e);let n=i.get(e);n!=null&&(t=Math.min(t,n))}i.set(e,t)},`annotate`);for(let t of e)a(t);return i}t(Wt,`annotateMinimumLayers`);function Gt(e){return(t,n)=>{let r=e[t]??0,i=e[n]??0;return r===i?t.localeCompare(n):r-i}}t(Gt,`compareByRankThenId`);function Kt(e,n,r,i){let a=0;for(let e of n){let t=r[e]??0;t>a&&(a=t)}let o=Array.from({length:a+1},()=>[]),s=new Set,c=t(e=>{if(s.has(e))return;s.add(e);let t=r[e]??0;o[t]||(o[t]=[]),o[t].push(e);for(let t of i(e))c(t)},`emit`);for(let t of e)c(t);for(let e of n)if(!s.has(e)){let t=r[e]??0;o[t]||(o[t]=[]),o[t].push(e),s.add(e)}return o}t(Kt,`emitNodesInTreeOrder`);function qt(e){let t=[];for(let n of e){let e=new Set,r=[];for(let t of n)e.has(t)||(e.add(t),r.push(t));t.push(r)}return t}t(qt,`deduplicateLayers`);function Jt(e,t,n,r){return i=>{let a=e.get(i)??[];if(a.length===0)return[];let o=t[i]??0,s=[],c=[],l=n.get(i);for(let e of a){let t=r.get(e)??o;t>o?s.push({child:e,min:t}):c.push(e)}return s.sort((e,t)=>e.min===t.min?e.child.localeCompare(t.child):e.min-t.min),c.sort((e,t)=>{let n=l?.get(e)??0,i=l?.get(t)??0;if(n!==i)return n-i;let a=r.get(e)??o,s=r.get(t)??o;return a===s?e.localeCompare(t):a-s}),[...s.map(e=>e.child),...c]}}t(Jt,`createChildOrderer`);function Yt(e,t,n){let r=Lt(e,{rankHint:t,laneOf:n}),{children:i,roots:a}=r;for(let t of e.nodes)i.has(t)||i.set(t,[]);let o=Ut(e,t,r),s=[...a].sort(Gt(t)),c=Jt(i,t,o,Wt(s,i,t)),l=Kt(s,e.nodes,t,c);return l=qt(l),l}t(Yt,`buildMultitreeLayerOrder`);function Xt(e,t,n){let r=new Set(e),i=new Set(t),a=Dt(t),o=[];for(let e of n)r.has(e.src)&&i.has(e.dst)&&o.push(a.get(e.dst));return Ot(o)}t(Xt,`countCrossingsBetweenAdjacent`);function Zt(e,t,n){let r=[];for(let e of t){let t=n[e.src],i=n[e.dst];if(t==null||i==null||t===i)continue;let a=e.src,o=e.dst,s=t,c=i;t>i&&(a=e.dst,o=e.src,s=i,c=t);for(let t=s;t(n[t]??0)-(n[e]??0));for(let s of o){let o=n[s]??0;if(o===0)continue;let c=0;for(let e of r.get(s)??[])c=Math.max(c,(n[e]??0)+1);if(c>=o)continue;let l=o;n[s]=c;let u=Zt(Yt(e,n,i),e.edges,n);u(t[e]??0)-(t[n]??0)||e.localeCompare(n));for(let i of r){let r=n(i);if(!r)continue;let a=e.edges.filter(e=>e.src===i);if(a.length===0)continue;let o=!1,s=0;for(let e of a){let t=n(e.dst);t==null||t===r?o=!0:s++}if(s===0||o)continue;let c=0,l=!1;for(let t of e.edges){if(t.dst!==i)continue;let e=n(t.src);e&&(e===r?l=!0:c++)}if(c>0||!l)continue;let u=t[i]??0,d=u+s,f=0;for(let n of e.edges)n.dst===i&&(f=Math.max(f,(t[n.src]??0)+1));let p=Math.max(u,f,d);p!==u&&(t[i]=p)}}t($t,`adjustCrossLaneSources`);function en(e,t){let n=vt(e),r=Et(n)??[...n.nodes].sort(),i=t?.compactSingleInput??!1,a=jt(n),o=Object.create(null);for(let e of r){let r=yt(n,e),s=t?.ignoreCrossLaneEdges?r.filter(t=>{let n=a(t.src),r=a(e);return!n||!r||n===r}):r;if(s.length===0)o[e]=0;else if(i&&s.length===1){let t=s[0].src;a(t)===a(e)?o[e]=(o[t]??0)+1:o[e]=o[t]??0}else{let t=-1/0;for(let e of s)t=Math.max(t,(o[e.src]??0)+1);o[e]=t===-1/0?0:t}}return(t?.optimizeRanksByCrossings??!1)&&(o=Qt(n,o)),t?.ignoreCrossLaneEdges&&$t(n,o),{layers:Yt(n,o,a),rankOf:o,dummy:new Set}}t(en,`assignLayers_LongestPath`);function tn(e,n){let r=vt(e),i={...en(r,{compactSingleInput:n?.compactSingleInput,ignoreCrossLaneEdges:n?.ignoreCrossLaneEdges,optimizeRanksByCrossings:n?.optimizeRanksByCrossings}).rankOf},a=jt(r),{preds:o,succs:s}=wt(r,e=>{if(n?.ignoreCrossLaneEdges){let t=a(e.src),n=a(e.dst);if(t&&n&&t!==n)return!1}return!0}),c=Et(r)??[...r.nodes],l=[...c].reverse(),u=t((e,t)=>{let n=0;for(let t of o.get(e)??[])n=Math.max(n,(i[t]??0)+1);let r=1/0,a=s.get(e)??[];return a.length>0&&(r=Math.min(...a.map(e=>(i[e]??0)-1))),Number.isFinite(r)||(r=Math.max(n,t)),Math.min(Math.max(t,n),r)},`clampFeasible`),d=Ft.GRAVITY_ITERATIONS,f=t(e=>{let t=!1;for(let n of e){let e=o.get(n)??[],r=s.get(n)??[];if(e.length===0&&r.length===0)continue;let a=e.length>0?e.reduce((e,t)=>e+(i[t]??0)+1,0)/e.length:i[n]??0,c=r.length>0?r.reduce((e,t)=>e+(i[t]??0)-1,0)/r.length:i[n]??0,l=Math.round((a+c)/2),d=u(n,l);d!==i[n]&&(i[n]=d,t=!0)}return t},`relaxOrder`);for(let e=0;e0){let n=Math.min(...t.map(e=>(i[e]??0)-1));(i[e]??0)>n&&(i[e]=n)}}return{layers:Tt(r,c,i),rankOf:i,dummy:new Set}}t(tn,`assignLayers_Gravity`);function nn(e){let t=St(e),n=xt(e),r=Ct(t),i=[];for(;r.length>0;){let e=[];for(let a of r){i.push(a);for(let r of n.get(a)??[])t.set(r,(t.get(r)??0)-1),(t.get(r)??0)===0&&e.push(r)}r=e.sort((e,t)=>e.localeCompare(t))}return i.length===e.nodes.length?i:null}t(nn,`topoSortByGenerationIfAcyclic`);function rn(e,n){let r=vt(e),i=n?.direction===`LR`?nn(r)??[...r.nodes].sort():Et(r)??[...r.nodes].sort(),a=jt(r),o=t(e=>a(e)??e,`laneOf`),s=Object.create(null),c=new Map,l=t((e,t)=>n?.ignoreCrossLaneEdges??!0?+(o(e)===o(t)):1,`edgeWeight`);for(let e of i){if(r.nodeById.get(e)?.isGroup)continue;let t=yt(r,e),n=0;if(t.length>0)for(let r of t){let t=r.src,i=s[t]??0;n=Math.max(n,i+l(t,e))}let i=o(e),a=c.get(i)??0,u=Math.max(n,a);s[e]=u,c.set(i,u+1)}return{layers:Tt(r,i,s,{skipGroups:!0}),rankOf:s,dummy:new Set}}t(rn,`assignLayers_LaneAwareCompact`);function an(e,n){let r=vt(n),{rankOf:i}=e,a=e.layers.map(e=>[...e]),o=new Set(e.dummy?[...e.dummy]:[]),s=0,c=new Map(r.nodeById),l=t(e=>{let t=`placeholder-${s++}`,n={id:t,isGroup:!1,isDummy:!0,width:0,height:0};for(c.set(t,n),o.add(t);a.length<=e;)a.push([]);return a[e].push(t),i[t]=e,t},`addDummyAt`),u=[...r.edges].sort((e,t)=>e.id===t.id?e.src===t.src?e.dst.localeCompare(t.dst):e.src.localeCompare(t.src):e.id.localeCompare(t.id)),d=[];for(let e of u){let t=i[e.src]??0,n=i[e.dst]??0;if(n-t<=1){d.push(e);continue}let r=e.src;for(let i=t+1,a=0;i!r.nodes.includes(e))],edges:d,layout:r.layout,nodeById:c};return{layering:{layers:a,rankOf:i,dummy:o},graphWithDummies:f}}t(an,`makeProperLayering`);function on(e){let t=e.length;if(t===0)return 1/0;let n=[...e].sort((e,t)=>e-t);return t%2==1?n[(t-1)/2]:.5*(n[t/2-1]+n[t/2])}t(on,`median`);function sn(e){return e.length===0?1/0:e.reduce((e,t)=>e+t,0)/e.length}t(sn,`barycenter`);function cn(e,t,n,r){let i=new Map;for(let t of e)i.set(t,[]);for(let e of n)r===`down`?t.has(e.src)&&i.has(e.dst)&&i.get(e.dst).push(t.get(e.src)):t.has(e.dst)&&i.has(e.src)&&i.get(e.src).push(t.get(e.dst));return i}t(cn,`neighborPositionsFor`);function ln(e,t,n){let r=n.get(e)??0,i=n.get(t)??0;return r===i?e.localeCompare(t):r-i}t(ln,`currentOrderTieBreak`);function un(e,t,n){let r=new Set(e),i=new Set(t),a=Dt(e),o=Dt(t),s=[];for(let e of n)r.has(e.src)&&i.has(e.dst)&&s.push({u:a.get(e.src),v:o.get(e.dst)});return s.sort((e,t)=>e.u===t.u?e.v-t.v:e.u-t.u),Ot(s.map(e=>e.v))}t(un,`countCrossingsBetweenAdjacent`);function dn(e,t,n){return[...e].sort((e,r)=>{let i=on(t.get(e)??[]),a=on(t.get(r)??[]);return i===a?ln(e,r,n):isFinite(i)?isFinite(a)?i-a:-1:1})}t(dn,`sortByHeuristic`);function fn(e,t,n,r,i,a){let o=Dt(e),s=Dt(t),c=cn(t,o,n,r);if(!i||!a||a.length===0)return dn(t,c,s);let l=new Map;for(let e of t){let t=i(e),n=l.get(t)??[];n.push(e),l.set(t,n)}let u=[];for(let e of a){let t=l.get(e);if(!t||t.length===0)continue;let n=dn(t,c,s);u.push(...n)}let d=l.get(null);if(d&&d.length>0){let e=dn(d,c,s);for(let t of e){let e=sn(c.get(t)??[]),n=u.length;if(isFinite(e)){for(let[t,r]of u.entries())if(es.has(e.src)&&c.has(e.dst)),d=l?r.filter(e=>c.has(e.src)&&l.has(e.dst)):void 0,f=t(t=>{let n=un(e,t,u);return d&&i&&(n+=un(t,i,d)),n},`crossingScore`),p=a?new Map:null;if(a&&p)for(let e of n)p.set(e,a(e));let m=!0,h=f(o);for(;m;){m=!1;for(let e=0;e+1[...e]),i=t.edges,a=jt(t),o=Nt(t,n?.laneOrder);for(let e=0;e<3;e++){for(let e=1;e=0;e--)r[e]=fn(r[e+1],r[e],i,`up`,a,o),r[e]=pn(r[e+1],r[e],i,r[e-1],a)}return{layers:r}}t(mn,`orderLayers`);function hn(e,n,r){let i=r?.layerGap??It.DEFAULT_LAYER_GAP,a=r?.nodeGap??It.DEFAULT_NODE_GAP,o=r?.laneGap??a*2,s=r?.direction??`TB`,c=s===`LR`||s===`RL`,l=e.layers,u=Object.create(null),d=Object.create(null),f=t(e=>n.nodeById.get(e),`getNode`),p=t(e=>f(e)?.width??0,`getWidth`),m=t(e=>f(e)?.height??0,`getHeight`),h=jt(n),g=Nt(n,r?.laneOrder),_=l.map(e=>e.reduce((e,t)=>Math.max(e,m(t)),0)),v=[];if(c)for(let e=0;e+1Math.max(e,p(t)),0),n=l[e+1].reduce((e,t)=>Math.max(e,p(t)),0),r=_[e],a=_[e+1],o=r/2+a/2,s=(t+n)/2,c=Math.max(0,s-o-i);v.push(c)}let y=new Set;for(let e of l)for(let t of e)y.add(h(t));let b=y.has(null),x=g.filter(e=>y.has(e)),S=[...b?[null]:[],...x],C=Object.create(null);for(let e of x)C[e]=0;b&&(C.null=0);for(let e of l){let t=Object.create(null),n=[];for(let r of e){let e=h(r);e===null?n.push(r):(t[e]||=[]).push(r)}for(let[e,n]of Object.entries(t)){let t=n.reduce((e,t)=>e+p(t),0)+a*Math.max(0,n.length-1);C[e]=Math.max(C[e]??0,t)}if(b&&n.length){let e=n.reduce((e,t)=>e+p(t),0)+a*Math.max(0,n.length-1);C.null=Math.max(C.null??0,e)}}let w=new Map;{let e=S.map(e=>(e===null?C.null:C[e])??0),t=-(e.reduce((e,t)=>e+t,0)+o*Math.max(0,S.length-1))/2;for(let n=0;np(e)),r=i-(e.reduce((e,t)=>e+t,0)+a*(t.length-1))/2;for(let[i,o]of t.entries()){let t=e[i];u[o]=r+t/2,d[o]=T+n/2,r+=t+a}}}let o=v[e]??0;T+=n+i+o}let E=new Map;for(let e of n.edges){let t=e.ref.id;E.has(t)||E.set(t,[]),E.get(t).push(e)}for(let[,e]of E){if(e.length===0)continue;let t=e[0].ref,r=t.start,i=t.end;if(r==null||i==null)continue;let a=Math.round(((u[r]??0)+(u[i]??0))/2),o=new Set;for(let t of e)o.add(t.src),o.add(t.dst);for(let e of o)e!==r&&e!==i&&n.nodeById.get(e)?.isDummy&&(u[e]=a)}return{x:u,y:d}}t(hn,`assignCoordinates`);var gn=8;function _n(e){let t=2166136261;for(let n=0;n>>0}t(_n,`hashString`);function vn(e){let t=e>>>0;return()=>{t+=1831565813;let e=t;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296}}t(vn,`mulberry32`);function yn(e,t){let n=[...e],r=vn(t);for(let e=n.length-1;e>0;e--){let t=Math.floor(r()*(e+1));[n[e],n[t]]=[n[t],n[e]]}return n}t(yn,`deterministicShuffle`);function bn(e,t){let n=0;for(let[r,i]of e.entries())n+=Math.abs(r-(t.get(i)??r));return n}t(bn,`sourceDistance`);function xn(e,t){let n=new Map;for(let[t,r]of e.entries())n.set(r,t);let r=0;for(let{a:e,b:i,weight:a}of t){let t=n.get(e),o=n.get(i);t!=null&&o!=null&&(r+=a*Math.abs(t-o))}return r}t(xn,`laneArrangementCost`);function Sn(e){let t=Mt(e);if(t.length<2)return[];let n=new Map(t.map((e,t)=>[e,t])),r=jt(e),i=new Map;for(let t of e.layout.edges??[]){if(t.isLayoutOnly)continue;let a=typeof t.start==`string`?t.start:void 0,o=typeof t.end==`string`?t.end:void 0;if(!a||!o||!e.nodeById.has(a)||!e.nodeById.has(o))continue;let s=r(a),c=r(o);if(!s||!c||s===c)continue;let l=n.get(s),u=n.get(c);if(l==null||u==null)continue;let[d,f]=l<=u?[s,c]:[c,s],p=`${d}\0${f}`,m=i.get(p);m?m.weight++:i.set(p,{a:d,b:f,weight:1})}return[...i.values()]}t(Sn,`buildWeightedLaneEdges`);function Cn(e,t,n){let r=[...e],i=xn(r,t),a=!0,o=0,s=Math.max(1,r.length);for(;a&&oe.a===t.a?e.b.localeCompare(t.b):e.a.localeCompare(t.a)).map(({a:e,b:t,weight:n})=>`${e}:${t}:${n}`).join(`|`);return _n(`${e.join(`|`)}#${r}#${n}`)}t(Tn,`seedForRestart`);function En(e,t={}){let n=Mt(e);if(n.length<2)return n;let r=Sn(e);if(r.length===0)return n;let i=new Map(n.map((e,t)=>[e,t])),a=Cn(n,r,i),o=Math.max(0,t.restarts??gn);for(let e=0;e$&&c*3>=s?o>0?`bottom`:`top`:s>$?a>0?`right`:`left`:n}t(Pn,`chooseOrthogonalSide`);function Fn(e,t){return Math.abs(e.to-t.from)<$||Math.abs(e.to-t.to)<$?e.to:e.from}t(Fn,`sharedLineEndpointCoord`);function In(e,t){return e.orient===`vertical`?{x:e.coord,y:t}:{x:t,y:e.coord}}t(In,`pointOnLine`);function Ln(e,n){let r=e.nodes??[],i=e.edges??[],a=[];for(let e of i)e.isLayoutOnly||a.push({...e,__originalEdge:e});let o=new Map,s=new Map,c=[],l=n===`LR`;for(let e of r)o.set(e.id,e);let u=r.filter(e=>e.isGroup&&!e.parentId);for(let e of u){let n={id:e.id},i=t(e=>{s.set(e.id,n),r.filter(t=>t.parentId===e.id).forEach(i)},`assignLane`);i(e)}let d=r.filter(e=>!e.isGroup&&!e.isEdgeLabel).map(e=>{let t=e.width??10,n=e.height??10,r=e.x??0,i=e.y??0,a=On;return{nodeId:e.id,minX:r-t/2-a,maxX:r+t/2+a,minY:i-n/2-a,maxY:i+n/2+a,visualXHalfExtent:l?n/2+a:t/2+a}}),f=t((e,t,n,r)=>{let i=c.find(n=>n.orientation===e&&Math.abs(n.coord-t)<1);return i||(i={id:`pipe-${e}-${t.toFixed(0)}`,orientation:e,coord:t,spanMin:n,spanMax:r,tracks:[]},c.push(i)),i.spanMin=Math.min(i.spanMin,n),i.spanMax=Math.max(i.spanMax,r),i},`getOrAddPipe`),p=t((e,t)=>{let n=e.width??10,r=e.height??10,i=e.x??0,a=e.y??0;switch(t){case`top`:return{x:i,y:a-r/2};case`bottom`:return{x:i,y:a+r/2};case`left`:return{x:i-n/2,y:a};case`right`:return{x:i+n/2,y:a}}},`portForSide`),m=t((e,t,n)=>p(e,Pn(e,t,n?`bottom`:`top`)),`getOrthogonalPort`),h=[],g=[],_=new Set,v=1e3,y=t((e,t,n)=>{if(h.length===0)return 0;let r=Math.abs(t.y-n.y)<$,i=Math.abs(t.x-n.x)<$;if(!r&&!i)return 0;let a=0;if(r){let r=t.y,i=Math.min(t.x,n.x)-$,o=Math.max(t.x,n.x)+$;if(o<=i)return 0;for(let t of h)t.edgeIndex!==e&&t.orientation===`vertical`&&(t.pipe.coordo||t.from-$<=r&&t.to+$>=r&&(a+=v))}else if(i){let r=t.x,i=Math.min(t.y,n.y)-$,o=Math.max(t.y,n.y)+$;if(o<=i)return 0;for(let t of h)t.edgeIndex!==e&&t.orientation===`horizontal`&&(t.pipe.coordo||t.from-$<=r&&t.to+$>=r&&(a+=v))}return a},`crossingPenalty`),b=a.map((e,t)=>{if(!e.start||!e.end)return{idx:t,crossLane:0,dx:0,dy:0};let n=o.get(e.start),r=o.get(e.end),i=s.get(e.start),a=s.get(e.end);return{idx:t,crossLane:i&&a&&i.id!==a.id?1:0,dx:n&&r?Math.abs((r.x??0)-(n.x??0)):0,dy:n&&r?Math.abs((r.y??0)-(n.y??0)):0}}).sort((e,t)=>{if(e.crossLane!==t.crossLane)return t.crossLane-e.crossLane;let n=e.dx+e.dy,r=t.dx+t.dy;return Math.abs(n-r)>1?n-r:e.idx-t.idx}).map(e=>e.idx),x=t((e,t,n,r)=>{let i=Math.min(e.x,t.x),a=Math.max(e.x,t.x),o=Math.min(e.y,t.y),s=Math.max(e.y,t.y);return!!d.find(c=>n&&c.nodeId===n||r&&c.nodeId===r?!1:Math.abs(e.x-t.x)>$?c.minYe.y&&c.maxX>i&&c.minXe.x&&c.maxY>o&&c.minYPn(e,t,`bottom`),`determineSide`),T=new Map;for(let[e,t]of a.entries()){if(!t.start||!t.end||t.start===t.end||t.points&&t.points.length>0)continue;let n=o.get(t.start),r=o.get(t.end);if(!n||!r)continue;let i=(r.x??0)-(n.x??0),a=(r.y??0)-(n.y??0);T.set(e,{edgeIdx:e,srcId:t.start,dstId:t.end,srcSide:w(n,{x:r.x??0,y:r.y??0}),dstSide:w(r,{x:n.x??0,y:n.y??0}),absDx:Math.abs(i),absDy:Math.abs(a),dxSign:Math.sign(i),dySign:Math.sign(a)})}let E=t(e=>e.srcSide===`top`||e.srcSide===`bottom`?e.absDx===0?1/0:e.absDy/e.absDx:e.absDy===0?1/0:e.absDx/e.absDy,`preferenceStrength`),D=t(e=>e.srcSide===`top`||e.srcSide===`bottom`?e.dxSign>=0?`right`:`left`:e.dySign>=0?`bottom`:`top`,`secondarySide`),O=new Map;for(let e of T.values()){let t=`${e.srcId}:${e.srcSide}`;O.has(t)||O.set(t,[]),O.get(t).push(e)}let k=new Map,A=t((e,t)=>`${e}:${t}`,`loadKey`);for(let e of T.values())k.set(A(e.srcId,e.srcSide),(k.get(A(e.srcId,e.srcSide))??0)+1),k.set(A(e.dstId,e.dstSide),(k.get(A(e.dstId,e.dstSide))??0)+1);for(let e of O.values())if(!(e.length<2)){e.sort((e,t)=>{let n=E(e),r=E(t);return Math.abs(n-r)>1e-9?r-n:e.edgeIdx-t.edgeIdx});for(let t=1;t=i||(k.set(A(n.srcId,n.srcSide),i-1),k.set(A(n.srcId,r),a+1),n.srcSide=r)}}let j=t(e=>{let t=e?.shape;return t===`question`||t===`diamond`},`isDiamondNode`),M=new Map;for(let e of T.values())M.has(e.dstId)||M.set(e.dstId,new Set),M.get(e.dstId).add(e.dstSide);for(let e of T.values()){if(!j(o.get(e.srcId)))continue;let t=M.get(e.srcId);if(!t?.has(e.srcSide))continue;let n=D(e);if(t.has(n)||(k.get(A(e.srcId,n))??0)>0)continue;let r=k.get(A(e.srcId,e.srcSide))??0;k.set(A(e.srcId,e.srcSide),Math.max(0,r-1)),k.set(A(e.srcId,n),1),e.srcSide=n}for(let e of T.values()){let{edgeIdx:t,srcId:n,dstId:r,srcSide:i,dstSide:a}=e,s=o.get(n),c=o.get(r),l=`${n}:${i}:src`,u=i===`top`||i===`bottom`?c.x??0:c.y??0;S.has(l)||S.set(l,[]),S.get(l).push({edgeIdx:t,oppositeCoord:u});let d=`${r}:${a}:dst`,f=a===`top`||a===`bottom`?s.x??0:s.y??0;S.has(d)||S.set(d,[]),S.get(d).push({edgeIdx:t,oppositeCoord:f})}let N=new Map;for(let[e,t]of S){if(t.length<2)continue;t.sort((e,t)=>e.oppositeCoord-t.oppositeCoord);let n=e.split(`:`),r=n.slice(0,-2).join(`:`),i=n[n.length-2],a=n[n.length-1],s=o.get(r);if(!s)continue;let c=i===`left`||i===`right`?s.height??10:s.width??10,l=s.shape,u=l===`question`||l===`diamond`?c*.3:c,d=Math.min(20,Math.max(8,u/(t.length+1))),f=-(d*(t.length-1))/2;for(let[e,n]of t.entries()){let t=f+e*d,r=`${n.edgeIdx}:${a}`;N.set(r,t)}}let P=t(e=>!!a[e]?.labelNodeId,`edgeHasLabelNode`),F=t((e,t)=>e?(S.get(`${e}:${t}:src`)??[]).some(({edgeIdx:e})=>P(e))||(S.get(`${e}:${t}:dst`)??[]).some(({edgeIdx:e})=>P(e)):!1,`faceHasLabelNode`),I=t((e,t,n)=>t===`top`||t===`bottom`?{x:e.x+n,y:e.y}:{x:e.x,y:e.y+n},`applyPortOffset`),ee=t((e,t,n)=>{let r=T.get(e),i={x:n.x??0,y:n.y??0},a={x:t.x??0,y:t.y??0},o=r?.srcSide??w(t,i),s=r?.dstSide??w(n,a),c=r?p(t,r.srcSide):m(t,i,!0),l=r?p(n,r.dstSide):m(n,a,!1),u=N.get(`${e}:src`),d=N.get(`${e}:dst`);return u!==void 0&&(c=I(c,o,u)),d!==void 0&&(l=I(l,s,d)),{pSrcPort:c,pDstPort:l,srcSide:o,dstSide:s}},`portsForEdge`);for(let e of b){let n=a[e];if(g[e]=[],!n.start||!n.end||n.points&&n.points.length>0||n.start===n.end)continue;let r=o.get(n.start),i=o.get(n.end);if(!r||!i)continue;let{pSrcPort:s,pDstPort:u,srcSide:p,dstSide:m}=ee(e,r,i),v={...s},b={...u},w=p===`top`||p===`bottom`,T=m===`top`||m===`bottom`;w?v.y=s.y>(r.y??0)?s.y+Mn:s.y-Mn:v.x=s.x>(r.x??0)?s.x+Mn:s.x-Mn,T?b.y=u.y>(i.y??0)?u.y+Mn:u.y-Mn:b.x=u.x>(i.x??0)?u.x+Mn:u.x-Mn;let E=t((e,t)=>{for(let n of d)if(!t.includes(n.nodeId)&&e.x>n.minX&&e.xn.minY&&e.y{if(i){let i=e.y>(t.y??0);return{x:(n.x??0)>=e.x?r.maxX+kn:r.minX-kn,y:i?r.maxY+An:r.minY-An,leavesPositiveSide:i}}let a=e.x>(t.x??0),o=(n.y??0)>=e.y;return{x:a?r.maxX+kn:r.minX-kn,y:o?r.maxY+An:r.minY-An,leavesPositiveSide:a}},`obstacleDetour`),O=[],k=[n.start,n.end],A=E(v,k);if(A.inside&&A.obstacle){let e=A.obstacle;if(w){let t=D(s,r,i,e,!0);v.x=t.x,v.y=t.y;let n=t.leavesPositiveSide?Math.min(e.minY-2,s.y+Mn):Math.max(e.maxY+2,s.y-Mn);O=[{x:s.x,y:n},{x:t.x,y:n},{x:t.x,y:t.y}]}else{let t=D(s,r,i,e,!1),n=t.leavesPositiveSide?Math.min(e.minX-2,s.x+Mn):Math.max(e.maxX+2,s.x-Mn);v.x=t.x,v.y=t.y,O=[{x:n,y:s.y},{x:n,y:t.y},{x:t.x,y:t.y}]}}let j=[],M=E(b,k);if(M.inside&&M.obstacle){let e=M.obstacle;if(T){let t=D(u,i,r,e,!0);b.x=t.x,b.y=t.y,j=[{x:t.x,y:t.y},{x:u.x,y:t.y}]}else{let t=D(u,i,r,e,!1);b.x=t.x,b.y=t.y,j=[{x:t.x,y:t.y},{x:t.x,y:u.y}]}}if(O.length===0&&j.length===0){let t=kn,r=Math.abs(v.x-b.x)1||c>1,d=C.get(n.start??``)??0,f=C.get(n.end??``)??0,g=o>1&&F(n.start,p)||c>1&&F(n.end,m);if((r||i)&&!a&&(!l||l&&!g&&(o<=1||d<=2)&&(c<=1||f<=2))&&!x(s,u,n.start,n.end)){n.points=[{...s},{...v},{...b},{...u}],_.add(e);let t=i?`horizontal`:`vertical`,r=i?s.y:s.x,a=i?Math.min(s.x,u.x):Math.min(s.y,u.y),o=i?Math.max(s.x,u.x):Math.max(s.y,u.y),c={id:`fast-path-${t}-${r.toFixed(0)}-${e}`,orientation:t,coord:r,spanMin:a,spanMax:o,tracks:[]};h.push({edgeIndex:e,segmentIndex:0,orientation:t,pipe:c,trackIndex:0,from:a,to:o});continue}}v.x=f(`vertical`,v.x,v.y,v.y).coord,b.x=f(`vertical`,b.x,b.y,b.y).coord;let P=Math.min(v.x,b.x)-50,I=Math.max(v.x,b.x)+50,L=Math.min(v.y,b.y)-50,R=Math.max(v.y,b.y)+50;for(let e of d){let t=Math.min(v.x,b.x),n=Math.max(v.x,b.x),r=Math.min(v.y,b.y),i=Math.max(v.y,b.y);e.minXt&&e.minYr&&(P=Math.min(P,e.minX-jn),I=Math.max(I,e.maxX+jn),L=Math.min(L,e.minY-jn),R=Math.max(R,e.maxY+jn))}for(let e of d){if(e.maxXI||e.maxYR)continue;let t=kn;f(`horizontal`,e.minY-t,P,I),f(`horizontal`,e.maxY+t,P,I);let n=An;f(`vertical`,e.minX-n,L,R),f(`vertical`,e.maxX+n,L,R)}f(`horizontal`,v.y,P,I),f(`horizontal`,b.y,P,I);let z=c.filter(e=>e.orientation===`horizontal`&&e.coord>=L&&e.coord<=R),te=c.filter(e=>e.orientation===`vertical`&&e.coord>=P&&e.coord<=I),ne=t((e,t)=>`${e.toFixed(1)},${t.toFixed(1)}`,`getKey`),B=ne(v.x,v.y),re=ne(b.x,b.y),ie=new Map,ae=new Map,V=new Map,oe=new Set,H=[];ie.set(B,0),V.set(B,`n`),H.push({key:B,f:Math.hypot(b.x-v.x,b.y-v.y),pt:v}),oe.add(B);let U=[],W=t((e,t)=>x(e,t,n.start,n.end),`checkSegmentBlocked`),G={x:b.x,y:v.y},K=W(v,G),se=W(G,b),ce=K||se,le={x:v.x,y:b.y},ue=W(v,le),de=W(le,b);if(ce?ue||de||(U=Math.abs(v.x-b.x)<$?[v,b]:[v,le,b]):U=Math.abs(v.y-b.y)<$||Math.abs(v.x-b.x)<$?[v,b]:[v,G,b],U.length===0)for(;H.length>0;){H.sort((e,t)=>e.f-t.f);let t=H.shift();if(oe.delete(t.key),t.key===re){let e=re,t=b;for(U=[t];ae.has(e);){let n=ae.get(e);U.unshift(n),t=n,e=ne(n.x,n.y)}break}let r=t.pt.x,i=t.pt.y,a=te.sort((e,t)=>e.coord-t.coord),o=a.findIndex(e=>Math.abs(e.coord-r)<1),s=z.sort((e,t)=>e.coord-t.coord),c=s.findIndex(e=>Math.abs(e.coord-i)<1),l=[];o>0&&l.push({x:a[o-1].coord,y:i}),o>=0&&o0&&l.push({x:r,y:s[c-1].coord}),c>=0&&ce.nodeId===n.start||e.nodeId===n.end?!1:o===s?e.minXr&&e.maxY>c&&e.minYi&&e.maxX>o&&e.minX10&&x<-5||g<-10&&x>5)&&(m=Math.abs(x)*100),(h>10&&_<-5||h<-10&&_>5)&&(m+=Math.abs(_)*50);let S=0,C=V.get(t.key)??`n`,w=Math.abs(_)>$?`h`:`v`;C!==`n`&&C!==w&&(S=50);let T=f+p+m+S,E=(ie.get(t.key)??1/0)+T,D=Math.abs(b.x-a.x)+Math.abs(b.y-a.y);if(E<(ie.get(u)??1/0)){if(ae.set(u,t.pt),ie.set(u,E),V.set(u,w),!oe.has(u))H.push({key:u,f:E+D,pt:a}),oe.add(u);else{let e=H.findIndex(e=>e.key===u);e!==-1&&(H[e].f=E+D)}}}}if(U.length===0&&(U=[v,{x:v.x,y:b.y},b]),U.length>4){let e=U[0],n=U[U.length-1],r=Math.min(e.x,n.x),i=Math.max(e.x,n.x),a=Math.min(e.y,n.y),o=Math.max(e.y,n.y);for(let e of U)r=Math.min(r,e.x),i=Math.max(i,e.x),a=Math.min(a,e.y),o=Math.max(o,e.y);let s=i>Math.max(e.x,n.x),c=re.minXr&&e.minYa);if(s.length>0){let r=Math.max(e.x,n.x);for(let e of s){let n=(e.minX+e.maxX)/2;if(e.visualXHalfExtent===void 0||isNaN(e.visualXHalfExtent))continue;let i=n+e.visualXHalfExtent+t;r=Math.max(r,i)}isNaN(r)||(i=r)}}if(c){let i=d.filter(r=>r.minXMath.min(e.y,n.y));if(i.length>0){let a=Math.min(e.x,n.x);for(let e of i){let n=(e.minX+e.maxX)/2-e.visualXHalfExtent-t;a=Math.min(a,n)}r=a}}}let u=t(t=>{let r=n.y>e.y,i=d.filter(t=>{let r=Math.min(e.x,n.x)t.minX,i=Math.min(e.y,n.y)t.minY;return r&&i}),a=i;if(l&&i.length>0){let e=i.filter(e=>e.minXt);e.length>0&&(a=e)}if(a.length===0)return n.y;let o=kn;if(r){let e=Math.max(...a.map(e=>e.maxY))+o;if(ee.minY))-o;if(e>n.y+$)return e}return n.y},`findBestReturnY`),f=t(t=>{let r=u(t),i={x:t,y:e.y},a={x:t,y:r},o={x:n.x,y:r},s=W(e,i),c=W(i,a),l=W(a,o),d=r!==n.y&&W(o,n);return!s&&!c&&!l&&!d?Math.abs(r-n.y)<$?[e,i,a,n]:[e,i,a,o,n]:null},`trySimplifyWithDetourX`),p=s&&!c?f(i):c&&!s?f(r):null;p&&(U=p)}let q=[s,...O,...U,...j.reverse(),u];if(q.length>=3){let e=q[q.length-1],t=q[q.length-2],n=q[q.length-3],r=Math.abs(n.y-t.y)<$&&Math.abs(t.y-e.y)<$,i=Math.abs(n.x-t.x)<$&&Math.abs(t.x-e.x)<$;if(r){let r=Math.sign(t.x-n.x),i=Math.sign(e.x-n.x);r!==0&&r===i&&Math.abs(t.x-n.x)>Math.abs(e.x-n.x)&&q.splice(-2,1)}else if(i){let r=Math.sign(t.y-n.y),i=Math.sign(e.y-n.y);r!==0&&r===i&&Math.abs(t.y-n.y)>Math.abs(e.y-n.y)&&q.splice(-2,1)}}let J=[q[0]];for(let e=1;et.x!=r.x>n.x){J.push(n);continue}continue}if(Math.abs(t.x-n.x)<$&&Math.abs(n.x-r.x)<$){if(n.y>t.y!=r.y>n.y){J.push(n);continue}continue}J.push(n)}J.push(q[q.length-1]);for(let t=0;te.from{let i=!r.segments.some(n=>(n.edgeIndex!==t.edgeIndex||n.segmentIndex!==t.segmentIndex)&&L(n,e)),a=!n.segments.some(n=>(n.edgeIndex!==e.edgeIndex||n.segmentIndex!==e.segmentIndex)&&L(n,t));return i&&a?(e.trackIndex=r.index,t.trackIndex=n.index,n.segments=[...n.segments.filter(t=>t.edgeIndex!==e.edgeIndex||t.segmentIndex!==e.segmentIndex),{edgeIndex:t.edgeIndex,segmentIndex:t.segmentIndex,from:t.from,to:t.to}],r.segments=[...r.segments.filter(e=>e.edgeIndex!==t.edgeIndex||e.segmentIndex!==t.segmentIndex),{edgeIndex:e.edgeIndex,segmentIndex:e.segmentIndex,from:e.from,to:e.to}],!0):!1},`trySwapSegmentsAcrossTracks`),z=t(e=>{let t=e.tracks.length;return e.tracks[t]={index:t,coord:e.coord,segments:[]},t},`createNewTrack`),te=t((e,t)=>{let n=e.pipe.tracks[e.trackIndex];n.segments=n.segments.filter(t=>t.edgeIndex!==e.edgeIndex||t.segmentIndex!==e.segmentIndex),e.trackIndex=t,e.pipe.tracks[t].segments.push({edgeIndex:e.edgeIndex,segmentIndex:e.segmentIndex,from:e.from,to:e.to})},`moveSegmentToTrack`),ne=t((e,t)=>{let n=g[e.edgeIndex];for(let r of n){let n=h[r];n.pipe===e.pipe&&te(n,t)}},`moveSegmentChainToTrack`),B=t(e=>{let t=g[e.edgeIndex],n=t.indexOf(h.indexOf(e)),r=[];return n>0&&r.push(h[t[n-1]]),n{if(e.orientation===t.orientation)return!1;let n=e.orientation===`horizontal`?e:t,r=e.orientation===`horizontal`?t:e;return r.pipe.coord>n.from&&r.pipe.coordr.from&&n.pipe.coord{for(let n of e.tracks)if(!n.segments.some(e=>(e.edgeIndex!==t.edgeIndex||e.segmentIndex!==t.segmentIndex)&&L(e,t)))return n.index;return-1},`findAvailableTrack`),ae=t((e,t)=>{if(e.trackIndex===t.trackIndex)return L(e,t);let n=B(e),r=B(t);return n.some(e=>r.some(t=>re(e,t)))},`segmentsConflict`),V=t((e,t,n)=>{if(R(e,t,e.pipe.tracks[e.trackIndex],t.pipe.tracks[t.trackIndex]))return;let r=ie(e.pipe,t);n(t,r===-1?z(e.pipe):r)},`resolveTrackConflict`),oe=t(e=>{let t=0;for(let n=0;n{if(H.has(e))return H.get(e);let t=g[e];if(t.length===0){let t={dest:0,deviation:0,base:0,delta:0};return H.set(e,t),t}let n=h[t[0]].pipe.coord,r=n;for(let e=1;eMath.abs(t-n)?e:t;break}}let i=Math.abs(r-n),a={dest:r,deviation:i,base:n,delta:r-n};return H.set(e,a),a},`getDestInfo`),W=t(()=>{let e=0,n=new Map;for(let[e,t]of a.entries())g[e].length!==0&&t.start&&(n.has(t.start)||n.set(t.start,[]),n.get(t.start).push(e));let r=t(e=>{let t=a[e];if(!t.start||!t.end)return 0;let n=o.get(t.start),r=o.get(t.end);if(!n||!r)return 0;let i=(r.x??0)-(n.x??0),s=(r.y??0)-(n.y??0);return Math.abs(i)+Math.abs(s)},`getEdgeDistance`);for(let t of n.values()){t.sort((e,t)=>{let n=U(e),i=U(t);if(Math.abs(n.deviation-i.deviation)>1)return n.deviation-i.deviation;if(Math.abs(n.dest-i.dest)>1)return n.dest-i.dest;let a=r(e),o=r(t);if(Math.abs(a-o)>1)return o-a;let s=g[e].length,c=g[t].length;if(s!==c)return s-c;if(s===1){let n=g[e][0],r=g[t][0];if(h[n]&&h[r]){let e=h[n],t=h[r],i=Math.abs(e.to-e.from),a=Math.abs(t.to-t.from);if(Math.abs(i-a)>1)return i-a}}return 0});let n=t.map(e=>h[g[e][0]]);e+=oe(n)}return e},`fixSourceHandleCrossings`),G=t(()=>{let e=0,n=new Map;for(let[e,t]of a.entries())g[e].length!==0&&t.end&&(n.has(t.end)||n.set(t.end,[]),n.get(t.end).push(e));for(let r of n.values()){r.sort((e,n)=>{let r=t(e=>{let t=g[e];if(t.length<2)return 0;let n=h[t[t.length-2]];return Math.abs(n.to-n.from)},`getDist`),i=r(e),a=r(n);return Math.abs(i-a)>.1?i-a:e-n});let n=r.map(e=>h[g[e][g[e].length-1]]);e+=oe(n)}return e},`fixTargetHandleCrossings`),K=t(()=>{let e=0;for(let t of c){let n=[];for(let e of t.tracks)for(let t of e.segments){let e=g[t.edgeIndex].find(e=>h[e].segmentIndex===t.segmentIndex);e!==void 0&&n.push(h[e])}n.sort((e,t)=>e.edgeIndex-t.edgeIndex||e.segmentIndex-t.segmentIndex);for(let t=0;t{e.segments.forEach(t=>{n.push({edgeIndex:t.edgeIndex,segmentIndex:t.segmentIndex,trackIndex:e.index,from:t.from,to:t.to})})}),n.sort((e,t)=>e.from-t.from);let r=[];if(n.length>0){let e=[n[0]],t=n[0].to;for(let i=1;ir.add(e.trackIndex));let i=new Map;n.forEach(e=>{let t=U(e.edgeIndex);i.set(e.trackIndex,(i.get(e.trackIndex)??0)+t.delta)});let a=[...r].filter(e=>(i.get(e)??0)<-1),o=[...r].filter(e=>(i.get(e)??0)>1),s=[...r].filter(e=>Math.abs(i.get(e)??0)<=1);a.sort((e,t)=>(i.get(t)??0)-(i.get(e)??0)),o.sort((e,t)=>(i.get(e)??0)-(i.get(t)??0));let c=t((t,r)=>{n.filter(e=>e.trackIndex===t).forEach(t=>{let n=_.has(t.edgeIndex)?e.coord:r;ce.set(`${t.edgeIndex}-${t.segmentIndex}`,n)})},`assignCoord`),l=0;for(let t of a)l++,c(t,e.coord-l*Nn);if(s.length===0&&r.size>0){let e=[...r].sort((e,t)=>Math.abs(i.get(e)??0)-Math.abs(i.get(t)??0))[0],t=a.indexOf(e);t!==-1&&a.splice(t,1);let n=o.indexOf(e);n!==-1&&o.splice(n,1),s.push(e)}let u=0;for(let t of s){if(u===0)c(t,e.coord);else{let n=u%2==1?1:-1,r=Math.ceil(u/2);c(t,e.coord+n*r*Nn*.5)}u++}let d=0;for(let t of o)d++,c(t,e.coord+d*Nn)}}for(let[e,t]of a.entries()){let n=g[e]??[];if(n.length===0)continue;let r=[],{pSrcPort:i,pDstPort:a}=ee(e,o.get(t.start),o.get(t.end)),s=n.map(e=>{let t=h[e],n=ce.get(`${t.edgeIndex}-${t.segmentIndex}`)??t.pipe.coord;return{orient:t.orientation,coord:n,from:t.from,to:t.to}});r.push(i);for(let e=0;e$&&r.push(In(t,i)),c&&o.orient===t.orient){if(Math.abs(t.coord-o.coord)>$){let e=t.orient===`vertical`?(i+o.from)/2:Fn(t,o);r.push(In(t,e),In(o,e))}else(e===0||e===s.length-2)&&r.push(In(t,Fn(t,o)))}else if(c)r.push(In(t,o.coord));else{let e=Math.abs(t.from-i)$||Math.abs(c.y-a.y)>$)&&r.push(a);let l=[];r.length>0&&l.push(r[0]);for(let e=1;e$||Math.abs(t.y-n.y)>$)&&l.push(t)}t.points=l}for(let e of a){let t=e.__originalEdge;t&&e.points&&(t.points=e.points)}e.edges=(e.edges??[]).filter(e=>!e.isLayoutOnly);let le=t((e,t)=>{let n=t.x??0,r=t.y??0,i=t.width??0,a=t.height??0;if(i<=0||a<=0)return e;let o=n-i/2,s=n+i/2,c=r-a/2,l=r+a/2;if(e.xs||e.yl)return e;let u=e.x-o,d=s-e.x,f=e.y-c,p=l-e.y,m=Math.min(u,d,f,p);return m===u?{x:o,y:e.y}:m===d?{x:s,y:e.y}:m===f?{x:e.x,y:c}:{x:e.x,y:l}},`nodeBoundaryClamp`);for(let t of e.edges){let e=t.points;if(!e||e.length<2)continue;let n=t.start,r=t.end,i=n?o.get(n):void 0,a=r?o.get(r):void 0;i&&(e[0]=le(e[0],i)),a&&(e[e.length-1]=le(e[e.length-1],a))}return e}t(Ln,`routeEdgesOrthogonal`);function Rn(e){return e.direction??`TB`}t(Rn,`getSwimlaneDirection`);function zn(e){let t=d(e),n=e.config.flowchart?.nodeSpacing??40,r=e.config.flowchart?.rankSpacing??100,i=e.config.swimlane?.ignoreCrossLaneEdges??!0,a=e.config.swimlane?.optimizeRanksByCrossings??!0,o=e.config.swimlane?.automaticLaneOrdering??!1,s=Rn(e),{ordered:c,coordinates:l}=Dn(t,{nodeGap:n,layerGap:r,ignoreCrossLaneEdges:i,optimizeRanksByCrossings:a,automaticLaneOrdering:o,direction:s});f(t,c,l,{nodeGap:n,layerGap:r});for(let t of e.edges??[])delete t.points;Ln(e,s);for(let t of e.edges??[])(!t.curve||t.curve===`basis`)&&(t.curve=`rounded`);return _t(e,s),gt(e),s}t(zn,`runSwimlaneLayoutCore`);function Bn(e){u(e);let t=m(e);e.nodes=t.nodes,e.edges=t.edges}t(Bn,`prepareSwimlaneLayout`);var Vn=n({prepareLayout:Bn,runLayoutCore:zn,afterPaint:i});export{Vn as render}; \ No newline at end of file diff --git a/www/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js b/www/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js new file mode 100644 index 0000000..710ec65 --- /dev/null +++ b/www/assets/swimlanesDiagram-TC7HE7FX-D2_PSbBF.js @@ -0,0 +1,8 @@ +import"./src-D_iIdUkB.js";import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./chunk-O7XYJQB3-Bce2lzyF.js";import"./chunk-ZIGJFQKS-BJ6myxnF.js";import"./chunk-7PRAP22T-DSs4vaIy.js";import"./chunk-742MDFTN-5mFByRwZ.js";import"./chunk-MBY4JIJT-CGQ6Fu8G.js";import"./chunk-7INBJB4K-BkZ96Hf7.js";import"./chunk-5DYCD2WN-WToj2Jza.js";import"./index-DoQkmpth.js";import"./chunk-GWA4HPMP-C1P4FmAY.js";import"./chunk-XXDRQBXY-C1_eEj17.js";import"./chunk-WEXAMYUT-I3m-hOmT.js";import{r as t,t as n}from"./chunk-7M6MHVWA-ZnPgs1Wx.js";var r=n({styles:e(e=>`${t(e)} + .swimlane.cluster:not([data-color-id]) rect { + stroke: ${e.clusterBorder} !important; + } + [data-look="neo"].cluster rect { + filter: none; + } +`,`getStyles`)});export{r as diagram}; \ No newline at end of file diff --git a/www/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js b/www/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js new file mode 100644 index 0000000..2ceaaf2 --- /dev/null +++ b/www/assets/timeline-definition-EJHVYXUP-Cj4l_LOm.js @@ -0,0 +1,120 @@ +import{m as e,p as t}from"./src-D_iIdUkB.js";import{n,t as r}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{Y as i,a,at as o,b as s,nt as c,o as l,rt as u,x as d}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as f}from"./arc-BJA87daU.js";import{p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{i as m,n as h}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import{y as g}from"./index-DoQkmpth.js";var _=(function(){var e=n(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),t=[6,11,13,14,15,17,19,20,23,24],r=[1,12],i=[1,13],a=[1,14],o=[1,15],s=[1,16],c=[1,19],l=[1,20],u={trace:n(function(){},`trace`),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:`error`,6:`EOF`,7:`timeline`,8:`timeline_lr`,9:`timeline_td`,11:`SPACE`,13:`NEWLINE`,14:`title`,15:`acc_title`,16:`acc_title_value`,17:`acc_descr`,18:`acc_descr_value`,19:`acc_descr_multiline_value`,20:`section`,23:`period`,24:`event`},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:n(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 3:r.setDirection(`LR`);break;case 4:r.setDirection(`TD`);break;case 5:this.$=[];break;case 6:a[s-1].push(a[s]),this.$=a[s-1];break;case 7:case 8:this.$=a[s];break;case 9:case 10:this.$=[];break;case 11:r.getCommonDb().setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 12:this.$=a[s].trim(),r.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=a[s].trim(),r.getCommonDb().setAccDescription(this.$);break;case 15:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 18:r.addTask(a[s],0,``),this.$=a[s];break;case 19:r.addEvent(a[s].substr(2)),this.$=a[s]}},`anonymous`),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},e(t,[2,5],{5:6}),e(t,[2,2]),e(t,[2,3]),e(t,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:r,15:i,17:a,19:o,20:s,21:17,22:18,23:c,24:l},e(t,[2,10],{1:[2,1]}),e(t,[2,6]),{12:21,14:r,15:i,17:a,19:o,20:s,21:17,22:18,23:c,24:l},e(t,[2,8]),e(t,[2,9]),e(t,[2,11]),{16:[1,22]},{18:[1,23]},e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,7]),e(t,[2,12]),e(t,[2,13])],defaultActions:{},parseError:n(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:n(function(e){var t=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}n(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=t.symbols_[e]||e),e}n(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};u.lexer=(function(){return{EOF:1,parseError:n(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:n(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:n(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:n(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:n(function(){return this._more=!0,this},`more`),reject:n(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:n(function(e){this.unput(this.match.slice(e))},`less`),pastInput:n(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:n(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:n(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:n(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:n(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:n(function(){return this.next()||this.lex()},`lex`),begin:n(function(e){this.conditionStack.push(e)},`begin`),popState:n(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:n(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:n(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:n(function(e){this.begin(e)},`pushState`),stateStackSize:n(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:n(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 13;case 3:break;case 4:break;case 5:return 8;case 6:return 9;case 7:return 7;case 8:return 14;case 9:return this.begin(`acc_title`),15;case 10:return this.popState(),`acc_title_value`;case 11:return this.begin(`acc_descr`),17;case 12:return this.popState(),`acc_descr_value`;case 13:this.begin(`acc_descr_multiline`);break;case 14:this.popState();break;case 15:return`acc_descr_multiline_value`;case 16:return 20;case 17:return 24;case 18:return 23;case 19:return 6;case 20:return`INVALID`}},`anonymous`),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:timeline[ \t]+LR\b)/i,/^(?:timeline[ \t]+TD\b)/i,/^(?:timeline\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^:\n]+)/i,/^(?::\s(?:[^:\n]|:(?!\s))+)/i,/^(?:[^#:\n]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[14,15],inclusive:!1},acc_descr:{rules:[12],inclusive:!1},acc_title:{rules:[10],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,13,16,17,18,19,20],inclusive:!0}}}})();function d(){this.yy={}}return n(d,`Parser`),d.prototype=u,u.Parser=d,new d})();_.parser=_;var v=_,y={};r(y,{addEvent:()=>P,addSection:()=>A,addTask:()=>N,addTaskOrg:()=>F,clear:()=>D,default:()=>ee,getCommonDb:()=>E,getDirection:()=>k,getSections:()=>j,getTasks:()=>M,setDirection:()=>O});var b=``,x=0,S=`LR`,C=[],w=[],T=[],E=n(()=>l,`getCommonDb`),D=n(function(){C.length=0,w.length=0,b=``,T.length=0,S=`LR`,a()},`clear`),O=n(function(e){S=e},`setDirection`),k=n(function(){return S},`getDirection`),A=n(function(e){b=e,C.push(e)},`addSection`),j=n(function(){return C},`getSections`),M=n(function(){let e=I(),t=0;for(;!e&&t<100;)e=I(),t++;return w.push(...T),w},`getTasks`),N=n(function(e,t,n){let r={id:x++,section:b,type:b,task:e,score:t||0,events:n?[n]:[]};T.push(r)},`addTask`),P=n(function(e){T.find(e=>e.id===x-1).events.push(e)},`addEvent`),F=n(function(e){let t={section:b,type:b,description:e,task:e,classes:[]};w.push(t)},`addTaskOrg`),I=n(function(){let e=n(function(e){return T[e].processed},`compileTask`),t=!0;for(let[n,r]of T.entries())e(n),t&&=r.processed;return t},`compileTasks`),ee={clear:D,getCommonDb:E,getDirection:k,setDirection:O,addSection:A,getSections:j,getTasks:M,addTask:N,addTaskOrg:F,addEvent:P},L=0,R=n(function(e,t){let n=e.append(`rect`);return n.attr(`x`,t.x),n.attr(`y`,t.y),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`width`,t.width),n.attr(`height`,t.height),n.attr(`rx`,t.rx),n.attr(`ry`,t.ry),t.class!==void 0&&n.attr(`class`,t.class),n},`drawRect`),te=n(function(e,t){let r=e.append(`circle`).attr(`cx`,t.cx).attr(`cy`,t.cy).attr(`class`,`face`).attr(`r`,15).attr(`stroke-width`,2).attr(`overflow`,`visible`),i=e.append(`g`);i.append(`circle`).attr(`cx`,t.cx-5).attr(`cy`,t.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`),i.append(`circle`).attr(`cx`,t.cx+5).attr(`cy`,t.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`);function a(e){let n=f().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,n).attr(`transform`,`translate(`+t.cx+`,`+(t.cy+2)+`)`)}n(a,`smile`);function o(e){let n=f().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,n).attr(`transform`,`translate(`+t.cx+`,`+(t.cy+7)+`)`)}n(o,`sad`);function s(e){e.append(`line`).attr(`class`,`mouth`).attr(`stroke`,2).attr(`x1`,t.cx-5).attr(`y1`,t.cy+7).attr(`x2`,t.cx+5).attr(`y2`,t.cy+7).attr(`class`,`mouth`).attr(`stroke-width`,`1px`).attr(`stroke`,`#666`)}return n(s,`ambivalent`),t.score>3?a(i):t.score<3?o(i):s(i),r},`drawFace`),ne=n(function(e,t){let n=e.append(`circle`);return n.attr(`cx`,t.cx),n.attr(`cy`,t.cy),n.attr(`class`,`actor-`+t.pos),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`r`,t.r),n.class!==void 0&&n.attr(`class`,n.class),t.title!==void 0&&n.append(`title`).text(t.title),n},`drawCircle`),z=n(function(e,t){let n=t.text.replace(//gi,` `),r=e.append(`text`);r.attr(`x`,t.x),r.attr(`y`,t.y),r.attr(`class`,`legend`),r.style(`text-anchor`,t.anchor),t.class!==void 0&&r.attr(`class`,t.class);let i=r.append(`tspan`);return i.attr(`x`,t.x+t.textMargin*2),i.text(n),r},`drawText`),re=n(function(e,t){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}n(r,`genPoints`);let i=e.append(`polygon`);i.attr(`points`,r(t.x,t.y,50,20,7)),i.attr(`class`,`labelBox`),t.y+=t.labelMargin,t.x+=.5*t.labelMargin,z(e,t)},`drawLabel`),ie=n(function(e,t,n){let r=e.append(`g`),i=V();i.x=t.x,i.y=t.y,i.fill=t.fill,i.width=n.width,i.height=n.height,i.class=`journey-section section-type-`+t.num,i.rx=3,i.ry=3,R(r,i),H(n)(t.text,r,i.x,i.y,i.width,i.height,{class:`journey-section section-type-`+t.num},n,t.colour)},`drawSection`),B=-1,ae=n(function(e,t,n,r){let i=t.x+n.width/2,a=e.append(`g`);B++,a.append(`line`).attr(`id`,r+`-task`+B).attr(`x1`,i).attr(`y1`,t.y).attr(`x2`,i).attr(`y2`,450).attr(`class`,`task-line`).attr(`stroke-width`,`1px`).attr(`stroke-dasharray`,`4 2`).attr(`stroke`,`#666`),te(a,{cx:i,cy:300+(5-t.score)*30,score:t.score});let o=V();o.x=t.x,o.y=t.y,o.fill=t.fill,o.width=n.width,o.height=n.height,o.class=`task task-type-`+t.num,o.rx=3,o.ry=3,R(a,o),H(n)(t.task,a,o.x,o.y,o.width,o.height,{class:`task`},n,t.colour)},`drawTask`),oe=n(function(e,t){R(e,{x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,class:`rect`}).lower()},`drawBackgroundRect`),se=n(function(){return{x:0,y:0,fill:void 0,"text-anchor":`start`,width:100,height:100,textMargin:0,rx:0,ry:0}},`getTextObj`),V=n(function(){return{x:0,y:0,width:100,anchor:`start`,height:100,rx:0,ry:0}},`getNoteRect`),H=(function(){function e(e,t,n,r,a,o,s,c){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`font-color`,c).style(`text-anchor`,`middle`).text(e),s)}n(e,`byText`);function t(e,t,n,r,a,o,s,c,l){let{taskFontSize:u,taskFontFamily:d}=c,f=e.split(//gi);for(let e=0;e)/).reverse(),i,a=[],o=1.1,s=e.attr(`y`),c=parseFloat(e.attr(`dy`)),l=e.text(null).append(`tspan`).attr(`x`,0).attr(`y`,s).attr(`dy`,c+`em`);for(let t=0;tn||i===`
    `)&&(a.pop(),l.text(a.join(` `).trim()),a=i===`
    `?[``]:[i],l=e.append(`tspan`).attr(`x`,0).attr(`y`,s).attr(`dy`,o+`em`).text(i))})}n(U,`wrap`);var le=n(function(e,n,r,i,a,o=!1){let{theme:s,look:c}=i,l=s?.includes(`redux`),u=r%(i?.themeVariables?.THEME_COLOR_LIMIT??12)-1,d=e.append(`g`);n.section=u,d.attr(`class`,(n.class?n.class+` `:``)+`timeline-node `+(`section-`+u));let f=d.append(`g`),p=d.append(`g`),m=p.append(`text`).text(n.descr).attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).call(U,n.width).node().getBBox(),h=i.fontSize?.replace?i.fontSize.replace(`px`,``):i.fontSize;if(n.height=m.height+h*1.1*.5+n.padding,n.height=Math.max(n.height,n.maxHeight),n.width+=2*n.padding,p.attr(`transform`,`translate(`+n.width/2+`, `+n.padding/2+`)`),l&&p.attr(`transform`,`translate(${n.width/2}, ${o?n.padding/2+3:n.padding})`),de(f,n,u,a,i),c===`neo`&&(d.attr(`data-look`,`neo`),l)){let n=s.includes(`dark`),r=e.node()?.ownerSVGElement??e.node(),i=t(r),a=i.attr(`id`)??``,o=a?`${a}-drop-shadow`:`drop-shadow`;if(i.select(`#${o}`).empty()){let e=i.select(`defs`);(e.empty()?i.append(`defs`):e).append(`filter`).attr(`id`,o).attr(`height`,`130%`).attr(`width`,`130%`).append(`feDropShadow`).attr(`dx`,`4`).attr(`dy`,`4`).attr(`stdDeviation`,0).attr(`flood-opacity`,n?`0.2`:`0.06`).attr(`flood-color`,n?`#FFFFFF`:`#000000`)}}return n},`drawNode`),ue=n(function(e,t,n){let r=e.append(`g`),i=r.append(`text`).text(t.descr).attr(`dy`,`1em`).attr(`alignment-baseline`,`middle`).attr(`dominant-baseline`,`middle`).attr(`text-anchor`,`middle`).call(U,t.width).node().getBBox(),a=n.fontSize?.replace?n.fontSize.replace(`px`,``):n.fontSize;return r.remove(),i.height+a*1.1*.5+t.padding},`getVirtualNodeHeight`),de=n(function(e,t,n,r,i){let{theme:a}=i,o=a?.includes(`redux`)?0:5,s=o>0?`M0 ${t.height-5} v${-t.height+10} q0,-${o},${o},-${o} h${t.width-10} q${o},0,${o},${o} v${t.height-5} H0 Z`:`M0 ${t.height-5} v${-(t.height-5)} h${t.width} v${t.height} H0 Z`;e.append(`path`).attr(`id`,r+`-node-`+L++).attr(`class`,`node-bkg node-`+t.type).attr(`d`,s),a?.includes(`redux`)||e.append(`line`).attr(`class`,`node-line-`+n).attr(`x1`,0).attr(`y1`,t.height).attr(`x2`,t.width).attr(`y2`,t.height)},`defaultBkg`),W={drawRect:R,drawCircle:ne,drawSection:ie,drawText:z,drawLabel:re,drawTask:ae,drawBackgroundRect:oe,getTextObj:se,getNoteRect:V,initGraphics:ce,drawNode:le,getVirtualNodeHeight:ue},fe=n(function(n,r,a,o){let s=d(),{look:c,theme:l,themeVariables:u}=s,{useGradient:f,gradientStart:p,gradientStop:m}=u,h=s.timeline?.leftMargin??50;e.debug(`timeline`,o.db);let g=s.securityLevel,_;g===`sandbox`&&(_=t(`#i`+r));let v=t(g===`sandbox`?_.nodes()[0].contentDocument.body:`body`).select(`#`+r);v.append(`g`);let y=o.db.getTasks(),b=o.db.getCommonDb().getDiagramTitle();e.debug(`task`,y),W.initGraphics(v,r);let x=o.db.getSections();e.debug(`sections`,x);let S=0,C=0,w=0,T=0,E=50+h,D=50;T=50;let O=0,k=!0;x.forEach(function(t){let n={number:O,descr:t,section:O,width:150,padding:20,maxHeight:S},r=W.getVirtualNodeHeight(v,n,s);e.debug(`sectionHeight before draw`,r),S=Math.max(S,r+20)});let A=0,j=0;e.debug(`tasks.length`,y.length);for(let[t,n]of y.entries()){let r={number:t,descr:n,section:n.section,width:150,padding:20,maxHeight:C},i=W.getVirtualNodeHeight(v,r,s);e.debug(`taskHeight before draw`,i),C=Math.max(C,i+20),A=Math.max(A,n.events.length);let a=0;for(let e of n.events){let t={descr:e,section:n.section,number:n.section,width:150,padding:20,maxHeight:50};a+=W.getVirtualNodeHeight(v,t,s)}n.events.length>0&&(a+=(n.events.length-1)*10),j=Math.max(j,a)}e.debug(`maxSectionHeight before draw`,S),e.debug(`maxTaskHeight before draw`,C),x&&x.length>0?x.forEach(t=>{let n=y.filter(e=>e.section===t),i={number:O,descr:t,section:O,width:200*Math.max(n.length,1)-50,padding:20,maxHeight:S};e.debug(`sectionNode`,i);let a=v.append(`g`),o=W.drawNode(a,i,O,s,r);e.debug(`sectionNode output`,o),a.attr(`transform`,`translate(${E}, ${T})`),D+=S+50,n.length>0&&G(v,n,O,E,D,C,s,A,j,S,!1,r),E+=200*Math.max(n.length,1),D=T,O++}):(k=!1,G(v,y,O,E,D,C,s,A,j,S,!0,r));let M=v.node().getBBox();if(e.debug(`bounds`,M),b&&v.append(`text`).text(b).attr(`x`,c===`neo`?M.x*2+h:M.width/2-h).attr(`font-size`,`4ex`).attr(`font-weight`,`bold`).attr(`y`,20),w=k?S+C+150:C+100,v.append(`g`).attr(`class`,`lineWrapper`).append(`line`).attr(`x1`,h).attr(`y1`,w).attr(`x2`,M.width+3*h).attr(`y2`,w).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#${r}-arrowhead)`),c===`neo`&&f&&l!==`neutral`){let e=v.select(`defs`),t=(e.empty()?v.append(`defs`):e).append(`linearGradient`).attr(`id`,v.attr(`id`)+`-gradient`).attr(`gradientUnits`,`objectBoundingBox`).attr(`x1`,`0%`).attr(`y1`,`0%`).attr(`x2`,`100%`).attr(`y2`,`0%`);t.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,p).attr(`stop-opacity`,1),t.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,m).attr(`stop-opacity`,1)}i(void 0,v,s.timeline?.padding??50,s.timeline?.useMaxWidth??!1)},`draw`),G=n(function(t,n,r,i,a,o,s,c,l,u,d,f){for(let c of n){let n={descr:c.task,section:r,number:r,width:150,padding:20,maxHeight:o};e.debug(`taskNode`,n);let u=t.append(`g`).attr(`class`,`taskWrapper`),p=W.drawNode(u,n,r,s,f).height;if(e.debug(`taskHeight after draw`,p),u.attr(`transform`,`translate(${i}, ${a})`),o=Math.max(o,p),c.events){let e=t.append(`g`).attr(`class`,`lineWrapper`),n=o;a+=100,n+=pe(t,c.events,r,i,a,s,f),a-=100,e.append(`line`).attr(`x1`,i+95).attr(`y1`,a+o).attr(`x2`,i+95).attr(`y2`,a+o+100+l+100).attr(`stroke-width`,2).attr(`stroke`,`black`).attr(`marker-end`,`url(#${f}-arrowhead)`).attr(`stroke-dasharray`,`5,5`)}i+=200,d&&!s.timeline?.disableMulticolor&&r++}a-=10},`drawTasks`),pe=n(function(t,n,r,i,a,o,s){let c=0,l=a;a+=100;for(let l of n){let n={descr:l,section:r,number:r,width:150,padding:20,maxHeight:50};e.debug(`eventNode`,n);let u=t.append(`g`).attr(`class`,`eventWrapper`),d=W.drawNode(u,n,r,o,s,!0).height;c+=d,u.attr(`transform`,`translate(${i}, ${a})`),a=a+10+d}return a=l,c},`drawEvents`),me={setConf:n(()=>{},`setConf`),draw:fe},K=200,q=5,he=K+q*2,J=K+100,ge=J+q*2,Y=10,_e=0,X=20,Z=20,Q=30,$=50,ve=n(function(t,n,r,a){let o=d(),s=o.timeline?.leftMargin??50;e.debug(`timeline`,a.db);let c=g(n);c.append(`g`);let l=a.db.getTasks(),u=a.db.getCommonDb().getDiagramTitle();e.debug(`task`,l),W.initGraphics(c);let f=a.db.getSections();e.debug(`sections`,f);let m=0,h=0,_=50+s,v=50,y=v,b=_,x=he+Z,S=ge+$,C=b+x,w=0,T=f&&f.length>0,E=T?C:_+x,D=Math.max(50,x+S-q*2);f.forEach(function(t){let n={number:w,descr:t,section:w,width:D,padding:q,maxHeight:m},r=W.getVirtualNodeHeight(c,n,o);e.debug(`sectionHeight before draw`,r),m=Math.max(m,r)});let O=0;e.debug(`tasks.length`,l.length);for(let[t,n]of l.entries()){let r={number:t,descr:n,section:n.section,width:K,padding:q,maxHeight:h},i=W.getVirtualNodeHeight(c,r,o);e.debug(`taskHeight before draw`,i),h=Math.max(h,i);let a=0;for(let e of n.events){let t={descr:e,section:n.section,number:n.section,width:J,padding:q,maxHeight:50};a+=W.getVirtualNodeHeight(c,t,o)}n.events.length>0&&(a+=(n.events.length-1)*Y),O=Math.max(O,a)+_e}e.debug(`maxSectionHeight before draw`,m),e.debug(`maxTaskHeight before draw`,h);let k=Math.max(h,O)+Q;T?f.forEach(t=>{let n=l.filter(e=>e.section===t),r={number:w,descr:t,section:w,width:D,padding:q,maxHeight:m};e.debug(`sectionNode`,r);let i=c.append(`g`),a=W.drawNode(i,r,w,o);e.debug(`sectionNode output`,a);let s=E-x;i.attr(`transform`,`translate(${s}, ${v})`);let u=v+a.height+X;n.length>0&&ye(c,n,w,E,u,h,o,k,!1);let d=n.length,f=a.height+X+k*Math.max(d,1)-(d>0?Q*2:0);v+=f,w++}):ye(c,l,w,E,v,h,o,k,!0);let A=c.node()?.getBBox();if(!A)throw Error(`bbox not found`);if(e.debug(`bounds`,A),u){if(c.append(`text`).text(u).attr(`x`,A.width/2-s).attr(`font-size`,`4ex`).attr(`font-weight`,`bold`).attr(`y`,20),A=c.node()?.getBBox(),!A)throw Error(`bbox not found`);e.debug(`bounds after title`,A)}let[j]=p(o.fontSize),M=(j??16)*2,N=(j??16)*.5+20,P=c.append(`g`).attr(`class`,`lineWrapper`);P.append(`line`).attr(`x1`,E).attr(`y1`,y-M).attr(`x2`,E).attr(`y2`,A.y+A.height+N).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#arrowhead)`),P.lower(),i(void 0,c,o.timeline?.padding??50,o.timeline?.useMaxWidth??!1)},`draw`),ye=n(function(t,n,r,i,a,o,s,c,l){for(let u of n){let n={descr:u.task,section:r,number:r,width:K,padding:q,maxHeight:o};e.debug(`taskNode`,n);let d=t.append(`g`).attr(`class`,`taskWrapper`),f=W.drawNode(d,n,r,s),p=f.height;e.debug(`taskHeight after draw`,p);let m=i-Z-f.width;if(d.attr(`transform`,`translate(${m}, ${a})`),o=Math.max(o,p),u.events&&u.events.length>0){let e=a,n=i+$;be(t,u.events,r,i,n,e,s)}a+=c,l&&!s.timeline?.disableMulticolor&&r++}},`drawTasks`),be=n(function(t,n,r,i,a,o,s){let c=o;for(let o of n){let n={descr:o,section:r,number:r,width:J,padding:q,maxHeight:0};e.debug(`eventNode`,n);let l=t.append(`g`).attr(`class`,`eventWrapper`),u=W.drawNode(l,n,r,s).height;l.attr(`transform`,`translate(${a}, ${c})`);let d=t.append(`g`).attr(`class`,`lineWrapper`),f=c+u/2;d.append(`line`).attr(`x1`,i).attr(`y1`,f).attr(`x2`,a).attr(`y2`,f).attr(`stroke-width`,2).attr(`stroke`,`black`).attr(`marker-end`,`url(#arrowhead)`).attr(`stroke-dasharray`,`5,5`),c=c+u+Y}return c-o},`drawEvents`),xe={setConf:n(()=>{},`setConf`),draw:ve},Se=n(e=>{let{theme:t}=s(),n=t?.includes(`dark`),r=m(t,e.borderColorArray),i=e.svgId?.replace(/^#/,``)??``,a=i?`url(#${i}-drop-shadow)`:e.dropShadow??`none`,o=``;for(let t=0;t{let t=``,n=h(e.THEME_COLOR_LIMIT);for(let t=0;t{},`setConf`),draw:n((e,t,n,r)=>(r?.db?.getDirection?.()??`LR`)===`TD`?xe.draw(e,t,n,r):me.draw(e,t,n,r),`draw`)},parser:v,styles:n(e=>{let{theme:t}=s(),n=t?.includes(`redux`),r=t===`neutral`,i=e.svgId?.replace(/^#/,``)??``,a=``;if(e.useGradient&&i&&e.THEME_COLOR_LIMIT&&!r){let t=h(e.THEME_COLOR_LIMIT);for(let n=0;ni?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r=Xe&&(a=De,o=!1,t=new Ee(t));outer:for(;++i-1:!!i&&le(e,t,n)>-1}var st=Math.max;function ct(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:Oe(n);return i<0&&(i=st(r+i,0)),le(e,t,i)}var lt=`[object RegExp]`;function ut(e){return me(e)&&ge(e)==lt}var dt=ue&&ue.isRegExp,ft=dt?oe(dt):ut,pt=`Expected a function`;function mt(e){if(typeof e!=`function`)throw TypeError(pt);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function ht(e,t){if(e==null)return{};var n=ve(Me(e),function(e){return[e]});return t=_e(t),Le(e,n,function(e,n){return t(e,n[0])})}function gt(e,t){return(S(e)?ce:Se)(e,mt(_e(t,3)))}function _t(e,t){var n;return he(e,function(e,r,i){return n=t(e,r,i),!n}),!!n}function vt(e,t,n){var r=S(e)?fe:_t;return n&&Re(e,t,n)&&(t=void 0),r(e,_e(t,3))}function yt(e){return e&&e.length?we(e):[]}function bt(e){console&&console.error&&console.error(`Error: ${e}`)}function xt(e){console&&console.warn&&console.warn(`Warning: ${e}`)}function St(e){let t=new Date().getTime(),n=e();return{time:new Date().getTime()-t,value:n}}function Ct(e){function t(){}t.prototype=e;let n=new t;function r(){return typeof n.bar}return r(),r(),e}function wt(e){return Tt(e)?e.LABEL:e.name}function Tt(e){return O(e.LABEL)&&e.LABEL!==``}var Et=class{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),x(this.definition,t=>{t.accept(e)})}},F=class extends Et{constructor(e){super([]),this.idx=1,A(this,ht(e,e=>e!==void 0))}set definition(e){}get definition(){return this.referencedRule===void 0?[]:this.referencedRule.definition}accept(e){e.visit(this)}},Dt=class extends Et{constructor(e){super(e.definition),this.orgText=``,A(this,ht(e,e=>e!==void 0))}},I=class extends Et{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,A(this,ht(e,e=>e!==void 0))}},L=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},Ot=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},kt=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},R=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},At=class extends Et{constructor(e){super(e.definition),this.idx=1,A(this,ht(e,e=>e!==void 0))}},jt=class extends Et{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,A(this,ht(e,e=>e!==void 0))}},z=class{constructor(e){this.idx=1,A(this,ht(e,e=>e!==void 0))}accept(e){e.visit(this)}};function Mt(e){return D(e,Nt)}function Nt(e){function t(e){return D(e,Nt)}if(e instanceof F){let t={type:`NonTerminal`,name:e.nonTerminalName,idx:e.idx};return O(e.label)&&(t.label=e.label),t}if(e instanceof I)return{type:`Alternative`,definition:t(e.definition)};if(e instanceof L)return{type:`Option`,idx:e.idx,definition:t(e.definition)};if(e instanceof Ot)return{type:`RepetitionMandatory`,idx:e.idx,definition:t(e.definition)};if(e instanceof kt)return{type:`RepetitionMandatoryWithSeparator`,idx:e.idx,separator:Nt(new z({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof At)return{type:`RepetitionWithSeparator`,idx:e.idx,separator:Nt(new z({terminalType:e.separator})),definition:t(e.definition)};if(e instanceof R)return{type:`Repetition`,idx:e.idx,definition:t(e.definition)};if(e instanceof jt)return{type:`Alternation`,idx:e.idx,definition:t(e.definition)};if(e instanceof z){let t={type:`Terminal`,name:e.terminalType.name,label:wt(e.terminalType),idx:e.idx};O(e.label)&&(t.terminalLabel=e.label);let n=e.terminalType.PATTERN;return e.terminalType.PATTERN&&(t.pattern=ft(n)?n.source:n),t}if(e instanceof Dt)return{type:`Rule`,name:e.name,orgText:e.orgText,definition:t(e.definition)};throw Error(`non exhaustive match`)}var Pt=class{visit(e){let t=e;switch(t.constructor){case F:return this.visitNonTerminal(t);case I:return this.visitAlternative(t);case L:return this.visitOption(t);case Ot:return this.visitRepetitionMandatory(t);case kt:return this.visitRepetitionMandatoryWithSeparator(t);case At:return this.visitRepetitionWithSeparator(t);case R:return this.visitRepetition(t);case jt:return this.visitAlternation(t);case z:return this.visitTerminal(t);case Dt:return this.visitRule(t);default:throw Error(`non exhaustive match`)}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}};function Ft(e){return e instanceof I||e instanceof L||e instanceof R||e instanceof Ot||e instanceof kt||e instanceof At||e instanceof z||e instanceof Dt}function It(e,t=[]){return e instanceof L||e instanceof R||e instanceof At?!0:e instanceof jt?vt(e.definition,e=>It(e,t)):e instanceof F&&P(t,e)?!1:e instanceof Et&&(e instanceof F&&t.push(e),nt(e.definition,e=>It(e,t)))}function Lt(e){return e instanceof jt}function Rt(e){if(e instanceof F)return`SUBRULE`;if(e instanceof L)return`OPTION`;if(e instanceof jt)return`OR`;if(e instanceof Ot)return`AT_LEAST_ONE`;if(e instanceof kt)return`AT_LEAST_ONE_SEP`;if(e instanceof At)return`MANY_SEP`;if(e instanceof R)return`MANY`;if(e instanceof z)return`CONSUME`;throw Error(`non exhaustive match`)}var zt=class{walk(e,t=[]){x(e.definition,(n,r)=>{let i=M(e.definition,r+1);if(n instanceof F)this.walkProdRef(n,i,t);else if(n instanceof z)this.walkTerminal(n,i,t);else if(n instanceof I)this.walkFlat(n,i,t);else if(n instanceof L)this.walkOption(n,i,t);else if(n instanceof Ot)this.walkAtLeastOne(n,i,t);else if(n instanceof kt)this.walkAtLeastOneSep(n,i,t);else if(n instanceof At)this.walkManySep(n,i,t);else if(n instanceof R)this.walkMany(n,i,t);else if(n instanceof jt)this.walkOr(n,i,t);else throw Error(`non exhaustive match`)})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){let r=t.concat(n);this.walk(e,r)}walkOption(e,t,n){let r=t.concat(n);this.walk(e,r)}walkAtLeastOne(e,t,n){let r=[new L({definition:e.definition})].concat(t,n);this.walk(e,r)}walkAtLeastOneSep(e,t,n){let r=Bt(e,t,n);this.walk(e,r)}walkMany(e,t,n){let r=[new L({definition:e.definition})].concat(t,n);this.walk(e,r)}walkManySep(e,t,n){let r=Bt(e,t,n);this.walk(e,r)}walkOr(e,t,n){let r=t.concat(n);x(e.definition,e=>{let t=new I({definition:[e]});this.walk(t,r)})}};function Bt(e,t,n){return[new L({definition:[new z({terminalType:e.separator})].concat(e.definition)})].concat(t,n)}function Vt(e){if(e instanceof F)return Vt(e.referencedRule);if(e instanceof z)return Wt(e);if(Ft(e))return Ht(e);if(Lt(e))return Ut(e);throw Error(`non exhaustive match`)}function Ht(e){let t=[],n=e.definition,r=0,i=n.length>r,a,o=!0;for(;i&&o;)a=n[r],o=It(a),t=t.concat(Vt(a)),r+=1,i=n.length>r;return yt(t)}function Ut(e){let t=D(e.definition,e=>Vt(e));return yt(Ne(t))}function Wt(e){return[e.terminalType]}var Gt=`_~IN~_`,Kt=class extends zt{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){let r=Jt(e.referencedRule,e.idx)+this.topProd.name,i=Vt(new I({definition:t.concat(n)}));this.follows[r]=i}};function qt(e){let t={};return x(e,e=>{let n=new Kt(e).startWalking();A(t,n)}),t}function Jt(e,t){return e.name+t+Gt}function B(e){return e.charCodeAt(0)}function Yt(e,t){Array.isArray(e)?e.forEach(function(e){t.push(e)}):t.push(e)}function Xt(e,t){if(e[t]===!0)throw`duplicate flag `+t;e[t],e[t]=!0}function Zt(e){if(e===void 0)throw Error(`Internal Error - Should never get here!`);return!0}function Qt(){throw Error(`Internal Error - Should never get here!`)}function $t(e){return e.type===`Character`}var en=[];for(let e=B(`0`);e<=B(`9`);e++)en.push(e);var tn=[B(`_`)].concat(en);for(let e=B(`a`);e<=B(`z`);e++)tn.push(e);for(let e=B(`A`);e<=B(`Z`);e++)tn.push(e);var nn=[B(` `),B(`\f`),B(` +`),B(`\r`),B(` `),B(`\v`),B(` `),B(`\xA0`),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(` `),B(`\u2028`),B(`\u2029`),B(` `),B(` `),B(` `),B(``)],rn=/[0-9a-fA-F]/,an=/[0-9]/,on=/[1-9]/,sn=class{constructor(){this.idx=0,this.input=``,this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar(`/`);let t=this.disjunction();this.consumeChar(`/`);let n={type:`Flags`,loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case`g`:Xt(n,`global`);break;case`i`:Xt(n,`ignoreCase`);break;case`m`:Xt(n,`multiLine`);break;case`u`:Xt(n,`unicode`);break;case`y`:Xt(n,`sticky`)}if(this.idx!==this.input.length)throw Error(`Redundant input: `+this.input.substring(this.idx));return{type:`Pattern`,flags:n,value:t,loc:this.loc(0)}}disjunction(){let e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()===`|`;)this.consumeChar(`|`),e.push(this.alternative());return{type:`Disjunction`,value:e,loc:this.loc(t)}}alternative(){let e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:`Alternative`,value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let e=this.idx;switch(this.popChar()){case`^`:return{type:`StartAnchor`,loc:this.loc(e)};case`$`:return{type:`EndAnchor`,loc:this.loc(e)};case`\\`:switch(this.popChar()){case`b`:return{type:`WordBoundary`,loc:this.loc(e)};case`B`:return{type:`NonWordBoundary`,loc:this.loc(e)}}throw Error(`Invalid Assertion Escape`);case`(`:this.consumeChar(`?`);let t;switch(this.popChar()){case`=`:t=`Lookahead`;break;case`!`:t=`NegativeLookahead`;break;case`<`:switch(this.popChar()){case`=`:t=`Lookbehind`;break;case`!`:t=`NegativeLookbehind`}}Zt(t);let n=this.disjunction();return this.consumeChar(`)`),{type:t,value:n,loc:this.loc(e)}}return Qt()}quantifier(e=!1){let t,n=this.idx;switch(this.popChar()){case`*`:t={atLeast:0,atMost:1/0};break;case`+`:t={atLeast:1,atMost:1/0};break;case`?`:t={atLeast:0,atMost:1};break;case`{`:let n=this.integerIncludingZero();switch(this.popChar()){case`}`:t={atLeast:n,atMost:n};break;case`,`:let e;this.isDigit()?(e=this.integerIncludingZero(),t={atLeast:n,atMost:e}):t={atLeast:n,atMost:1/0},this.consumeChar(`}`)}if(e===!0&&t===void 0)return;Zt(t)}if((e!==!0||t!==void 0)&&Zt(t))return this.peekChar(0)===`?`?(this.consumeChar(`?`),t.greedy=!1):t.greedy=!0,t.type=`Quantifier`,t.loc=this.loc(n),t}atom(){let e,t=this.idx;switch(this.peekChar()){case`.`:e=this.dotAll();break;case`\\`:e=this.atomEscape();break;case`[`:e=this.characterClass();break;case`(`:e=this.group()}return e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),Zt(e)?(e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e):Qt()}dotAll(){return this.consumeChar(`.`),{type:`Set`,complement:!0,value:[B(` +`),B(`\r`),B(`\u2028`),B(`\u2029`)]}}atomEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`1`:case`2`:case`3`:case`4`:case`5`:case`6`:case`7`:case`8`:case`9`:return this.decimalEscapeAtom();case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:`GroupBackReference`,value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case`d`:e=en;break;case`D`:e=en,t=!0;break;case`s`:e=nn;break;case`S`:e=nn,t=!0;break;case`w`:e=tn;break;case`W`:e=tn,t=!0}return Zt(e)?{type:`Set`,value:e,complement:t}:Qt()}controlEscapeAtom(){let e;switch(this.popChar()){case`f`:e=B(`\f`);break;case`n`:e=B(` +`);break;case`r`:e=B(`\r`);break;case`t`:e=B(` `);break;case`v`:e=B(`\v`)}return Zt(e)?{type:`Character`,value:e}:Qt()}controlLetterEscapeAtom(){this.consumeChar(`c`);let e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error(`Invalid `);return{type:`Character`,value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar(`0`),{type:`Character`,value:B(`\0`)}}hexEscapeSequenceAtom(){return this.consumeChar(`x`),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar(`u`),this.parseHexDigits(4)}identityEscapeAtom(){return{type:`Character`,value:B(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case` +`:case`\r`:case`\u2028`:case`\u2029`:case`\\`:case`]`:throw Error(`TBD`);default:return{type:`Character`,value:B(this.popChar())}}}characterClass(){let e=[],t=!1;for(this.consumeChar(`[`),this.peekChar(0)===`^`&&(this.consumeChar(`^`),t=!0);this.isClassAtom();){let t=this.classAtom();if(t.type,$t(t)&&this.isRangeDash()){this.consumeChar(`-`);let n=this.classAtom();if(n.type,$t(n)){if(n.value=this.input.length)throw Error(`Unexpected end of input`);this.idx++}loc(e){return{begin:e,end:this.idx}}},cn=class{visitChildren(e){for(let t in e){let n=e[t];e.hasOwnProperty(t)&&(n.type===void 0?Array.isArray(n)&&n.forEach(e=>{this.visit(e)},this):this.visit(n))}}visit(e){switch(e.type){case`Pattern`:this.visitPattern(e);break;case`Flags`:this.visitFlags(e);break;case`Disjunction`:this.visitDisjunction(e);break;case`Alternative`:this.visitAlternative(e);break;case`StartAnchor`:this.visitStartAnchor(e);break;case`EndAnchor`:this.visitEndAnchor(e);break;case`WordBoundary`:this.visitWordBoundary(e);break;case`NonWordBoundary`:this.visitNonWordBoundary(e);break;case`Lookahead`:this.visitLookahead(e);break;case`NegativeLookahead`:this.visitNegativeLookahead(e);break;case`Lookbehind`:this.visitLookbehind(e);break;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);break;case`Character`:this.visitCharacter(e);break;case`Set`:this.visitSet(e);break;case`Group`:this.visitGroup(e);break;case`GroupBackReference`:this.visitGroupBackReference(e);break;case`Quantifier`:this.visitQuantifier(e)}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},ln={},un=new sn;function dn(e){let t=e.toString();if(ln.hasOwnProperty(t))return ln[t];{let e=un.pattern(t);return ln[t]=e,e}}function fn(){ln={}}var pn=`Complement Sets are not supported for first char optimization`,mn=`Unable to use "first char" lexer optimizations: +`;function hn(e,t=!1){try{let t=dn(e);return gn(t.value,{},t.flags.ignoreCase)}catch(n){if(n.message===pn)t&&xt(`${mn}\tUnable to optimize: < ${e.toString()} >\n Complement Sets cannot be automatically optimized. + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n=``;t&&(n=` + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),bt(`${mn}\n\tFailed parsing: < ${e.toString()} >\n\tUsing the @chevrotain/regexp-to-ast library\n Please open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}function gn(e,t,n){switch(e.type){case`Disjunction`:for(let r=0;r{if(typeof e==`number`)_n(e,t,n);else{let r=e;if(n===!0)for(let e=r.from;e<=r.to;e++)_n(e,t,n);else{for(let e=r.from;e<=r.to&&e<256;e++)_n(e,t,n);if(r.to>=256){let e=r.from>=256?r.from:256,n=r.to,i=tr(e),a=tr(n);for(let e=i;e<=a;e++)t[e]=e}}}});break;case`Group`:gn(a.value,t,n);break;default:throw Error(`Non Exhaustive Match`)}let o=a.quantifier!==void 0&&a.quantifier.atLeast===0;if(a.type===`Group`&&bn(a)===!1||a.type!==`Group`&&o===!1)break}break;default:throw Error(`non exhaustive match!`)}return y(t)}function _n(e,t,n){let r=tr(e);t[r]=r,n===!0&&vn(e,t)}function vn(e,t){let n=String.fromCharCode(e),r=n.toUpperCase();if(r!==n){let e=tr(r.charCodeAt(0));t[e]=e}else{let e=n.toLowerCase();if(e!==n){let n=tr(e.charCodeAt(0));t[n]=n}}}function yn(e,t){return Fe(e.value,e=>{if(typeof e==`number`)return P(t,e);{let n=e;return Fe(t,e=>n.from<=e&&e<=n.to)!==void 0}})}function bn(e){let t=e.quantifier;return t&&t.atLeast===0?!0:e.value?S(e.value)?nt(e.value,bn):bn(e.value):!1}var xn=class extends cn{constructor(e){super(),this.targetCharCodes=e,this.found=!1}visitChildren(e){if(this.found!==!0){switch(e.type){case`Lookahead`:this.visitLookahead(e);return;case`NegativeLookahead`:this.visitNegativeLookahead(e);return;case`Lookbehind`:this.visitLookbehind(e);return;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);return}super.visitChildren(e)}}visitCharacter(e){P(this.targetCharCodes,e.value)&&(this.found=!0)}visitSet(e){e.complement?yn(e,this.targetCharCodes)===void 0&&(this.found=!0):yn(e,this.targetCharCodes)!==void 0&&(this.found=!0)}};function Sn(e,t){if(t instanceof RegExp){let n=dn(t),r=new xn(e);return r.visit(n),r.found}return Fe(t,t=>P(e,t.charCodeAt(0)))!==void 0}var Cn=`PATTERN`,wn=`defaultMode`;function Tn(e,t){t=je(t,{debug:!1,safeMode:!1,positionTracking:`full`,lineTerminatorCharacters:[`\r`,` +`],tracer:(e,t)=>t()});let n=t.tracer;n(`initCharCodeToOptimizedIndexMap`,()=>{nr()});let r;n(`Reject Lexer.NA`,()=>{r=gt(e,e=>e[Cn]===H.NA)});let i=!1,a;n(`Transform Patterns`,()=>{i=!1,a=D(r,e=>{let t=e[Cn];if(ft(t)){let e=t.source;return e.length===1&&e!==`^`&&e!==`$`&&e!==`.`&&!t.ignoreCase?e:e.length===2&&e[0]===`\\`&&!P([`d`,`D`,`s`,`S`,`t`,`r`,`n`,`t`,`0`,`c`,`b`,`B`,`f`,`v`,`w`,`W`],e[1])?e[1]:Un(t)}if(b(t))return i=!0,{exec:t};if(typeof t==`object`)return i=!0,t;if(typeof t==`string`){if(t.length===1)return t;{let e=t.replace(/[\\^$.*+?()[\]{}|]/g,`\\$&`);return Un(new RegExp(e))}}throw Error(`non exhaustive match`)})});let o,s,c,l,u;n(`misc mapping`,()=>{o=D(r,e=>e.tokenTypeIdx),s=D(r,e=>{let t=e.GROUP;if(t!==H.SKIPPED){if(O(t))return t;if(xe(t))return!1;throw Error(`non exhaustive match`)}}),c=D(r,e=>{let t=e.LONGER_ALT;if(t)return S(t)?D(t,e=>ct(r,e)):[ct(r,t)]}),l=D(r,e=>e.PUSH_MODE),u=D(r,e=>k(e,`POP_MODE`))});let d;n(`Line Terminator Handling`,()=>{let e=Qn(t.lineTerminatorCharacters);d=D(r,e=>!1),t.positionTracking!==`onlyOffset`&&(d=D(r,t=>k(t,`LINE_BREAKS`)?!!t.LINE_BREAKS:Xn(t,e)===!1&&Sn(e,t.PATTERN)))});let f,p,m,h;n(`Misc Mapping #2`,()=>{f=D(r,qn),p=D(a,Jn),m=T(r,(e,t)=>{let n=t.GROUP;return O(n)&&n!==H.SKIPPED&&(e[n]=[]),e},{}),h=D(a,(e,t)=>({pattern:a[t],longerAlt:c[t],canLineTerminator:d[t],isCustom:f[t],short:p[t],group:s[t],push:l[t],pop:u[t],tokenTypeIdx:o[t],tokenType:r[t]}))});let g=!0,ee=[];return t.safeMode||n(`First Char Optimization`,()=>{ee=T(r,(e,n,r)=>{if(typeof n.PATTERN==`string`)$n(e,tr(n.PATTERN.charCodeAt(0)),h[r]);else if(S(n.START_CHARS_HINT)){let t;x(n.START_CHARS_HINT,n=>{let i=tr(typeof n==`string`?n.charCodeAt(0):n);t!==i&&(t=i,$n(e,i,h[r]))})}else if(ft(n.PATTERN)){if(n.PATTERN.unicode)g=!1,t.ensureOptimizations&&bt(`${mn}\tUnable to analyze < ${n.PATTERN.toString()} > pattern.\n The regexp unicode flag is not currently supported by the regexp-to-ast library. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{let i=hn(n.PATTERN,t.ensureOptimizations);C(i)&&(g=!1),x(i,t=>{$n(e,t,h[r])})}}else t.ensureOptimizations&&bt(`${mn}\tTokenType: <${n.name}> is using a custom token pattern without providing parameter.\n This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),g=!1;return e},[])}),{emptyGroups:m,patternIdxToConfig:h,charCodeToPatternIdxToConfig:ee,hasCustom:i,canBeOptimized:g}}function En(e,t){let n=[],r=On(e);n=n.concat(r.errors);let i=kn(r.valid),a=i.valid;return n=n.concat(i.errors),n=n.concat(Dn(a)),n=n.concat(Ln(a)),n=n.concat(Rn(a,t)),n=n.concat(zn(a)),n}function Dn(e){let t=[],n=E(e,e=>ft(e[Cn]));return t=t.concat(jn(n)),t=t.concat(Pn(n)),t=t.concat(Fn(n)),t=t.concat(In(n)),t=t.concat(Mn(n)),t}function On(e){let t=E(e,e=>!k(e,Cn));return{errors:D(t,e=>({message:`Token Type: ->`+e.name+`<- missing static 'PATTERN' property`,type:V.MISSING_PATTERN,tokenTypes:[e]})),valid:Qe(e,t)}}function kn(e){let t=E(e,e=>{let t=e[Cn];return!ft(t)&&!b(t)&&!k(t,`exec`)&&!O(t)});return{errors:D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.`,type:V.INVALID_PATTERN,tokenTypes:[e]})),valid:Qe(e,t)}}var An=/[^\\][$]/;function jn(e){class t extends cn{constructor(){super(...arguments),this.found=!1}visitEndAnchor(e){this.found=!0}}let n=E(e,e=>{let n=e.PATTERN;try{let e=dn(n),r=new t;return r.visit(e),r.found}catch{return An.test(n.source)}});return D(n,e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain end of input anchor '$' + See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:V.EOI_ANCHOR_FOUND,tokenTypes:[e]}))}function Mn(e){let t=E(e,e=>e.PATTERN.test(``));return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' must not match an empty string`,type:V.EMPTY_MATCH_PATTERN,tokenTypes:[e]}))}var Nn=/[^\\[][\^]|^\^/;function Pn(e){class t extends cn{constructor(){super(...arguments),this.found=!1}visitStartAnchor(e){this.found=!0}}let n=E(e,e=>{let n=e.PATTERN;try{let e=dn(n),r=new t;return r.visit(e),r.found}catch{return Nn.test(n.source)}});return D(n,e=>({message:`Unexpected RegExp Anchor Error: + Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain start of input anchor '^' + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:V.SOI_ANCHOR_FOUND,tokenTypes:[e]}))}function Fn(e){let t=E(e,e=>{let t=e[Cn];return t instanceof RegExp&&(t.multiline||t.global)});return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' may NOT contain global('g') or multiline('m')`,type:V.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}))}function In(e){let t=[],n=D(e,n=>T(e,(e,r)=>n.PATTERN.source===r.PATTERN.source&&!P(t,r)&&r.PATTERN!==H.NA?(t.push(r),e.push(r),e):e,[]));n=Ke(n);let r=E(n,e=>e.length>1);return D(r,e=>{let t=D(e,e=>e.name);return{message:`The same RegExp pattern ->${rt(e).PATTERN}<-has been used in all of the following Token Types: ${t.join(`, `)} <-`,type:V.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}})}function Ln(e){let t=E(e,e=>{if(!k(e,`GROUP`))return!1;let t=e.GROUP;return t!==H.SKIPPED&&t!==H.NA&&!O(t)});return D(t,e=>({message:`Token Type: ->`+e.name+`<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String`,type:V.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}))}function Rn(e,t){let n=E(e,e=>e.PUSH_MODE!==void 0&&!P(t,e.PUSH_MODE));return D(n,e=>({message:`Token Type: ->${e.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${e.PUSH_MODE}<-which does not exist`,type:V.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}))}function zn(e){let t=[],n=T(e,(e,t,n)=>{let r=t.PATTERN;return r===H.NA||(O(r)?e.push({str:r,idx:n,tokenType:t}):ft(r)&&Vn(r)&&e.push({str:r.source,idx:n,tokenType:t})),e},[]);return x(e,(e,r)=>{x(n,({str:n,idx:i,tokenType:a})=>{if(r${a.name}<- can never be matched.\nBecause it appears AFTER the Token Type ->${e.name}<-in the lexer's definition.\nSee https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;t.push({message:n,type:V.UNREACHABLE_PATTERN,tokenTypes:[e,a]})}})}),t}function Bn(e,t){if(ft(t)){if(Hn(t))return!1;let n=t.exec(e);return n!==null&&n.index===0}if(b(t))return t(e,0,[],{});if(k(t,`exec`))return t.exec(e,0,[],{});if(typeof t==`string`)return t===e;throw Error(`non exhaustive match`)}function Vn(e){return Fe([`.`,`\\`,`[`,`]`,`|`,`^`,`$`,`(`,`)`,`?`,`*`,`+`,`{`],t=>e.source.indexOf(t)!==-1)===void 0}function Hn(e){return/(\(\?=)|(\(\?!)|(\(\?<=)|(\(\? property in its definition +`,type:V.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),k(e,`modes`)||r.push({message:`A MultiMode Lexer cannot be initialized without a property in its definition +`,type:V.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),k(e,`modes`)&&k(e,`defaultMode`)&&!k(e.modes,e.defaultMode)&&r.push({message:`A MultiMode Lexer cannot be initialized with a ${wn}: <${e.defaultMode}>which does not exist\n`,type:V.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),k(e,`modes`)&&x(e.modes,(e,t)=>{x(e,(n,i)=>{if(xe(n))r.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${t}> at index: <${i}>\n`,type:V.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED});else if(k(n,`LONGER_ALT`)){let i=S(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT];x(i,i=>{!xe(i)&&!P(e,i)&&r.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${i.name}> on token <${n.name}> outside of mode <${t}>\n`,type:V.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})})}})}),r}function Gn(e,t,n){let r=[],i=!1,a=gt(Ke(Ne(y(e.modes))),e=>e[Cn]===H.NA),o=Qn(n);return t&&x(a,e=>{let t=Xn(e,o);if(t!==!1){let n={message:Zn(e,t),type:t.issue,tokenType:e};r.push(n)}else k(e,`LINE_BREAKS`)?e.LINE_BREAKS===!0&&(i=!0):Sn(o,e.PATTERN)&&(i=!0)}),t&&!i&&r.push({message:`Warning: No LINE_BREAKS Found. + This Lexer has been defined to track line and column information, + But none of the Token Types can be identified as matching a line terminator. + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS + for details.`,type:V.NO_LINE_BREAKS_FLAGS}),r}function Kn(e){let t={},n=v(e);return x(n,n=>{let r=e[n];if(S(r))t[n]=[];else throw Error(`non exhaustive match`)}),t}function qn(e){let t=e.PATTERN;if(ft(t))return!1;if(b(t)||k(t,`exec`))return!0;if(O(t))return!1;throw Error(`non exhaustive match`)}function Jn(e){return O(e)&&e.length===1?e.charCodeAt(0):!1}var Yn={test:function(e){let t=e.length;for(let n=this.lastIndex;n Token Type\n\t Root cause: ${t.errMsg}.\n For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(t.issue===V.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. +\tThe problem is in the <${e.name}> Token Type\n For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error(`non exhaustive match`)}function Qn(e){return D(e,e=>O(e)?e.charCodeAt(0):e)}function $n(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}var er=[];function tr(e){return e<256?e:er[e]}function nr(){if(C(er)){er=Array(65536);for(let e=0;e<65536;e++)er[e]=e>255?255+~~(e/255):e}}function rr(e,t){let n=e.tokenTypeIdx;return n===t.tokenTypeIdx||t.isParent===!0&&t.categoryMatchesMap[n]===!0}function ir(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}var ar=1,or={};function sr(e){let t=cr(e);lr(t),dr(t),ur(t),x(t,e=>{e.isParent=e.categoryMatches.length>0})}function cr(e){let t=j(e),n=e,r=!0;for(;r;){n=Ke(Ne(D(n,e=>e.CATEGORIES)));let e=Qe(n,t);t=t.concat(e),C(e)?r=!1:n=e}return t}function lr(e){x(e,e=>{pr(e)||(or[ar]=e,e.tokenTypeIdx=ar++),mr(e)&&!S(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),mr(e)||(e.CATEGORIES=[]),hr(e)||(e.categoryMatches=[]),gr(e)||(e.categoryMatchesMap={})})}function ur(e){x(e,e=>{e.categoryMatches=[],x(e.categoryMatchesMap,(t,n)=>{e.categoryMatches.push(or[n].tokenTypeIdx)})})}function dr(e){x(e,e=>{fr([],e)})}function fr(e,t){x(e,e=>{t.categoryMatchesMap[e.tokenTypeIdx]=!0}),x(t.CATEGORIES,n=>{let r=e.concat(t);P(r,n)||fr(r,n)})}function pr(e){return k(e,`tokenTypeIdx`)}function mr(e){return k(e,`CATEGORIES`)}function hr(e){return k(e,`categoryMatches`)}function gr(e){return k(e,`categoryMatchesMap`)}function _r(e){return k(e,`tokenTypeIdx`)}var vr={buildUnableToPopLexerModeMessage(e){return`Unable to pop Lexer Mode after encountering Token ->${e.image}<- The Mode Stack is empty`},buildUnexpectedCharactersMessage(e,t,n,r,i,a){return`unexpected character: ->${e.charAt(t)}<- at offset: ${t}, skipped ${n} characters.`}},V;(function(e){e[e.MISSING_PATTERN=0]=`MISSING_PATTERN`,e[e.INVALID_PATTERN=1]=`INVALID_PATTERN`,e[e.EOI_ANCHOR_FOUND=2]=`EOI_ANCHOR_FOUND`,e[e.UNSUPPORTED_FLAGS_FOUND=3]=`UNSUPPORTED_FLAGS_FOUND`,e[e.DUPLICATE_PATTERNS_FOUND=4]=`DUPLICATE_PATTERNS_FOUND`,e[e.INVALID_GROUP_TYPE_FOUND=5]=`INVALID_GROUP_TYPE_FOUND`,e[e.PUSH_MODE_DOES_NOT_EXIST=6]=`PUSH_MODE_DOES_NOT_EXIST`,e[e.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]=`MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE`,e[e.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]=`MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY`,e[e.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]=`MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST`,e[e.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]=`LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED`,e[e.SOI_ANCHOR_FOUND=11]=`SOI_ANCHOR_FOUND`,e[e.EMPTY_MATCH_PATTERN=12]=`EMPTY_MATCH_PATTERN`,e[e.NO_LINE_BREAKS_FLAGS=13]=`NO_LINE_BREAKS_FLAGS`,e[e.UNREACHABLE_PATTERN=14]=`UNREACHABLE_PATTERN`,e[e.IDENTIFY_TERMINATOR=15]=`IDENTIFY_TERMINATOR`,e[e.CUSTOM_LINE_BREAK=16]=`CUSTOM_LINE_BREAK`,e[e.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]=`MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE`})(V||={});var yr={deferDefinitionErrorsHandling:!1,positionTracking:`full`,lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` +`,`\r`],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:vr,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(yr);var H=class{constructor(e,t=yr){if(this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(e,t)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=St(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()},typeof t==`boolean`)throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. +a boolean 2nd argument is no longer supported`);this.config=A({},yr,t);let n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof n==`number`&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT(`Lexer Constructor`,()=>{let n,r=!0;this.TRACE_INIT(`Lexer Config handling`,()=>{if(this.config.lineTerminatorsPattern===yr.lineTerminatorsPattern)this.config.lineTerminatorsPattern=Yn;else if(this.config.lineTerminatorCharacters===yr.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error(`"safeMode" and "ensureOptimizations" flags are mutually exclusive.`);this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),S(e)?n={modes:{defaultMode:j(e)},defaultMode:wn}:(r=!1,n=j(e))}),this.config.skipValidations===!1&&(this.TRACE_INIT(`performRuntimeChecks`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(Wn(n,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT(`performWarningRuntimeChecks`,()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(Gn(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),n.modes=n.modes?n.modes:{},x(n.modes,(e,t)=>{n.modes[t]=gt(e,e=>xe(e))});let i=v(n.modes);if(x(n.modes,(e,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,()=>{if(this.modes.push(n),this.config.skipValidations===!1&&this.TRACE_INIT(`validatePatterns`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(En(e,i))}),C(this.lexerDefinitionErrors)){sr(e);let r;this.TRACE_INIT(`analyzeTokenTypes`,()=>{r=Tn(e,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[n]=r.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=r.charCodeToPatternIdxToConfig,this.emptyGroups=A({},this.emptyGroups,r.emptyGroups),this.hasCustom=r.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=r.canBeOptimized}})}),this.defaultMode=n.defaultMode,!C(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){let e=D(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Errors detected in definition of Lexer: +`+e)}x(this.lexerDefinitionWarning,e=>{xt(e.message)}),this.TRACE_INIT(`Choosing sub-methods implementations`,()=>{if(r&&(this.handleModes=w),this.trackStartLines===!1&&(this.computeNewColumn=ye),this.trackEndLines===!1&&(this.updateTokenEndLineColumnLocation=w),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else if(/onlyOffset/i.test(this.config.positionTracking))this.createTokenInstance=this.createOffsetOnlyToken;else throw Error(`Invalid config option: "${this.config.positionTracking}"`);this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)}),this.TRACE_INIT(`Failed Optimization Warnings`,()=>{let e=T(this.canModeBeOptimized,(e,t,n)=>(t===!1&&e.push(n),e),[]);if(t.ensureOptimizations&&!C(e))throw Error(`Lexer Modes: < ${e.join(`, `)} > cannot be optimized.\n Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. + Or inspect the console log for details on how to resolve these issues.`)}),this.TRACE_INIT(`clearRegExpParserCache`,()=>{fn()}),this.TRACE_INIT(`toFastProperties`,()=>{Ct(this)})})}tokenize(e,t=this.defaultMode){if(!C(this.lexerDefinitionErrors)){let e=D(this.lexerDefinitionErrors,e=>e.message).join(`----------------------- +`);throw Error(`Unable to Tokenize because Errors detected in definition of Lexer: +`+e)}return this.tokenizeInternal(e,t)}tokenizeInternal(e,t){let n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,ee=e,te=ee.length,_=0,ne=0,re=this.hasCustom?0:Math.floor(e.length/10),ie=Array(re),ae=[],oe=this.trackStartLines?1:void 0,v=this.trackStartLines?1:void 0,se=Kn(this.emptyGroups),ce=this.trackStartLines,le=this.config.lineTerminatorsPattern,ue=0,de=[],y=[],b=[],fe=[];Object.freeze(fe);let x=!1,S=e=>{if(b.length===1&&e.tokenType.PUSH_MODE===void 0){let t=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);ae.push({offset:e.startOffset,line:e.startLine,column:e.startColumn,length:e.image.length,message:t})}else{b.pop();let e=Ie(b);de=this.patternIdxToConfig[e],y=this.charCodeToPatternIdxToConfig[e],ue=de.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;x=!!(y&&t)}};function pe(e){b.push(e),y=this.charCodeToPatternIdxToConfig[e],de=this.patternIdxToConfig[e],ue=de.length,ue=de.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;x=!!(y&&t)}pe.call(this,t);let me,he=this.config.recoveryEnabled;for(;_s.length){s=a,u=a.length,c=l,me=t;break}}}break}}if(u!==-1){if(d=me.group,d!==void 0&&(s=s===null?e.substring(_,_+u):s,f=me.tokenTypeIdx,p=this.createTokenInstance(s,_,f,me.tokenType,oe,v,u),this.handlePayload(p,c),d===!1?ne=this.addToken(ie,ne,p):se[d].push(p)),ce===!0&&me.canLineTerminator===!0){let t=0,n,r;le.lastIndex=0;do s=s===null?e.substring(_,_+u):s,n=le.test(s),n===!0&&(r=le.lastIndex-1,t++);while(n===!0);t===0?v=this.computeNewColumn(v,u):(oe+=t,v=u-r,this.updateTokenEndLineColumnLocation(p,d,r,t,oe,v,u))}else v=this.computeNewColumn(v,u);_+=u,this.handleModes(me,S,pe,p)}else{let t=_,n=oe,i=v,a=he===!1;for(;a===!1&&_ ${br(e)} <--`:`token of type --> ${e.name} <--`} but found --> '${t.image}' <--`},buildNotAllInputParsedMessage({firstRedundant:e,ruleName:t}){return`Redundant input, expecting EOF but found: `+e.image},buildNoViableAltMessage({expectedPathsPerAlt:e,actual:t,previous:n,customUserDescription:r,ruleName:i}){let a=` +but found: '`+rt(t).image+`'`;if(r)return`Expecting: `+r+a;{let t=T(e,(e,t)=>e.concat(t),[]),n=D(t,e=>`[${D(e,e=>br(e)).join(`, `)}]`);return`Expecting: one of these possible Token sequences:\n${D(n,(e,t)=>` ${t+1}. ${e}`).join(` +`)}`+a}},buildEarlyExitMessage({expectedIterationPaths:e,actual:t,customUserDescription:n,ruleName:r}){let i=` +but found: '`+rt(t).image+`'`;return n?`Expecting: `+n+i:`Expecting: expecting at least one iteration which starts with one of these possible Token sequences::\n <${D(e,e=>`[${D(e,e=>br(e)).join(`,`)}]`).join(` ,`)}>`+i}};Object.freeze(Fr);var Ir={buildRuleNotFoundError(e,t){return`Invalid grammar, reference to a rule which is not defined: ->`+t.nonTerminalName+`<- +inside top level rule: ->`+e.name+`<-`}},Lr={buildDuplicateFoundError(e,t){function n(e){return e instanceof z?e.terminalType.name:e instanceof F?e.nonTerminalName:``}let r=e.name,i=rt(t),a=i.idx,o=Rt(i),s=n(i),c=`->${o}${a>0?a:``}<- ${s?`with argument: ->${s}<-`:``} + appears more than once (${t.length} times) in the top level rule: ->${r}<-. + For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES + `;return c=c.replace(/[ \t]+/g,` `),c=c.replace(/\s\s+/g,` +`),c},buildNamespaceConflictError(e){return`Namespace conflict found in grammar.\nThe grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${e.name}>.\nTo resolve this make sure each Terminal and Non-Terminal names are unique\nThis is easy to accomplish by using the convention that Terminal names start with an uppercase letter\nand Non-Terminal names start with a lower case letter.`},buildAlternationPrefixAmbiguityError(e){let t=D(e.prefixPath,e=>br(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx;return`Ambiguous alternatives: <${e.ambiguityIndices.join(` ,`)}> due to common lookahead prefix\nin inside <${e.topLevelRule.name}> Rule,\n<${t}> may appears as a prefix path in all these alternatives.\nSee: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX\nFor Further details.`},buildAlternationAmbiguityError(e){let t=e.alternation.idx===0?``:e.alternation.idx,n=e.prefixPath.length===0,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(` ,`)}> in inside <${e.topLevelRule.name}> Rule,\n`;if(n)r+=`These alternatives are all empty (match no tokens), making them indistinguishable. +Only the last alternative may be empty. +`;else{let t=D(e.prefixPath,e=>br(e)).join(`, `);r+=`<${t}> may appears as a prefix path in all these alternatives.\n`}return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,r},buildEmptyRepetitionError(e){let t=Rt(e.repetition);return e.repetition.idx!==0&&(t+=e.repetition.idx),`The repetition <${t}> within Rule <${e.topLevelRule.name}> can never consume any tokens.\nThis could lead to an infinite loop.`},buildTokenNameError(e){return`deprecated`},buildEmptyAlternationError(e){return`Ambiguous empty alternative: <${e.emptyChoiceIdx+1}> in inside <${e.topLevelRule.name}> Rule.\nOnly the last alternative may be an empty alternative.`},buildTooManyAlternativesError(e){return`An Alternation cannot have more than 256 alternatives:\n inside <${e.topLevelRule.name}> Rule.\n has ${e.alternation.definition.length+1} alternatives.`},buildLeftRecursionError(e){let t=e.topLevelRule.name;return`Left Recursion found in grammar.\nrule: <${t}> can be invoked from itself (directly or indirectly)\nwithout consuming any Tokens. The grammar path that causes this is: \n ${`${t} --> ${D(e.leftRecursionPath,e=>e.name).concat([t]).join(` --> `)}`}\n To fix this refactor your grammar to remove the left recursion.\nsee: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError(e){return`deprecated`},buildDuplicateRuleNameError(e){let t;return t=e.topLevelRule instanceof Dt?e.topLevelRule.name:e.topLevelRule,`Duplicate definition, rule: ->${t}<- is already defined in the grammar: ->${e.grammarName}<-`}};function Rr(e,t){let n=new zr(e,t);return n.resolveRefs(),n.errors}var zr=class extends Pt{constructor(e,t){super(),this.nameToTopRule=e,this.errMsgProvider=t,this.errors=[]}resolveRefs(){x(y(this.nameToTopRule),e=>{this.currTopLevel=e,e.accept(this)})}visitNonTerminal(e){let t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{let t=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:t,type:G.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}}},Br=class extends zt{constructor(e,t){super(),this.topProd=e,this.path=t,this.possibleTokTypes=[],this.nextProductionName=``,this.nextProductionOccurrence=0,this.found=!1,this.isAtEndOfPath=!1}startWalking(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error(`The path does not start with the walker's top Rule!`);return this.ruleStack=j(this.path.ruleStack).reverse(),this.occurrenceStack=j(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes}walk(e,t=[]){this.found||super.walk(e,t)}walkProdRef(e,t,n){if(e.referencedRule.name===this.nextProductionName&&e.idx===this.nextProductionOccurrence){let r=t.concat(n);this.updateExpectedNext(),this.walk(e.referencedRule,r)}}updateExpectedNext(){C(this.ruleStack)?(this.nextProductionName=``,this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())}},Vr=class extends Br{constructor(e,t){super(e,t),this.path=t,this.nextTerminalName=``,this.nextTerminalOccurrence=0,this.nextTerminalName=this.path.lastTok.name,this.nextTerminalOccurrence=this.path.lastTokOccurrence}walkTerminal(e,t,n){if(this.isAtEndOfPath&&e.terminalType.name===this.nextTerminalName&&e.idx===this.nextTerminalOccurrence&&!this.found){let e=new I({definition:t.concat(n)});this.possibleTokTypes=Vt(e),this.found=!0}}},Hr=class extends zt{constructor(e,t){super(),this.topRule=e,this.occurrence=t,this.result={token:void 0,occurrence:void 0,isEndOfRule:void 0}}startWalking(){return this.walk(this.topRule),this.result}},Ur=class extends Hr{walkMany(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkMany(e,t,n)}},Wr=class extends Hr{walkManySep(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkManySep(e,t,n)}},Gr=class extends Hr{walkAtLeastOne(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOne(e,t,n)}},Kr=class extends Hr{walkAtLeastOneSep(e,t,n){if(e.idx===this.occurrence){let e=rt(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof z&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOneSep(e,t,n)}};function qr(e,t,n=[]){n=j(n);let r=[],i=0;function a(t){return t.concat(M(e,i+1))}function o(e){let i=qr(a(e),t,n);return r.concat(i)}for(;n.length{C(e.definition)===!1&&(r=o(e.definition))}),r;else if(t instanceof z)n.push(t.terminalType);else throw Error(`non exhaustive match`);i++}return r.push({partialPath:n,suffixDef:M(e,i)}),r}function Jr(e,t,n,r){let i=`EXIT_NONE_TERMINAL`,a=[i],o=`EXIT_ALTERNATIVE`,s=!1,c=t.length,l=c-r-1,u=[],d=[];for(d.push({idx:-1,def:e,ruleStack:[],occurrenceStack:[]});!C(d);){let e=d.pop();if(e===o){s&&Ie(d).idx<=l&&d.pop();continue}let r=e.def,f=e.idx,p=e.ruleStack,m=e.occurrenceStack;if(C(r))continue;let h=r[0];if(h===i){let e={idx:f,def:M(r),ruleStack:$e(p),occurrenceStack:$e(m)};d.push(e)}else if(h instanceof z){if(f=0;e--){let t={idx:f,def:h.definition[e].definition.concat(M(r)),ruleStack:p,occurrenceStack:m};d.push(t),d.push(o)}else if(h instanceof I)d.push({idx:f,def:h.definition.concat(M(r)),ruleStack:p,occurrenceStack:m});else if(h instanceof Dt)d.push(Yr(h,f,p,m));else throw Error(`non exhaustive match`)}return u}function Yr(e,t,n,r){let i=j(n);i.push(e.name);let a=j(r);return a.push(1),{idx:t,def:e.definition,ruleStack:i,occurrenceStack:a}}var W;(function(e){e[e.OPTION=0]=`OPTION`,e[e.REPETITION=1]=`REPETITION`,e[e.REPETITION_MANDATORY=2]=`REPETITION_MANDATORY`,e[e.REPETITION_MANDATORY_WITH_SEPARATOR=3]=`REPETITION_MANDATORY_WITH_SEPARATOR`,e[e.REPETITION_WITH_SEPARATOR=4]=`REPETITION_WITH_SEPARATOR`,e[e.ALTERNATION=5]=`ALTERNATION`})(W||={});function Xr(e){if(e instanceof L||e===`Option`)return W.OPTION;if(e instanceof R||e===`Repetition`)return W.REPETITION;if(e instanceof Ot||e===`RepetitionMandatory`)return W.REPETITION_MANDATORY;if(e instanceof kt||e===`RepetitionMandatoryWithSeparator`)return W.REPETITION_MANDATORY_WITH_SEPARATOR;if(e instanceof At||e===`RepetitionWithSeparator`)return W.REPETITION_WITH_SEPARATOR;if(e instanceof jt||e===`Alternation`)return W.ALTERNATION;throw Error(`non exhaustive match`)}function Zr(e,t,n,r,i,a){let o=si(e,t,n);return a(o,r,di(o)?ir:rr,i)}function Qr(e,t,n,r,i,a){let o=ci(e,t,i,n),s=di(o)?ir:rr;return a(o[0],s,r)}function $r(e,t,n,r){let i=e.length,a=nt(e,e=>nt(e,e=>e.length===1));if(t)return function(t){let r=D(t,e=>e.GATE);for(let t=0;tNe(e)),n=T(t,(e,t,n)=>(x(t,t=>{k(e,t.tokenTypeIdx)||(e[t.tokenTypeIdx]=n),x(t.categoryMatches,t=>{k(e,t)||(e[t]=n)})}),e),{});return function(){let e=this.LA(1);return n[e.tokenTypeIdx]}}return function(){for(let t=0;te.length===1),i=e.length;if(r&&!n){let t=Ne(e);if(t.length===1&&C(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}{let e=T(t,(e,t,n)=>(e[t.tokenTypeIdx]=!0,x(t.categoryMatches,t=>{e[t]=!0}),e),[]);return function(){let t=this.LA(1);return e[t.tokenTypeIdx]===!0}}}return function(){nextPath:for(let n=0;nqr([e],1)),r=ri(n.length),i=D(n,e=>{let t={};return x(e,e=>{let n=ii(e.partialPath);x(n,e=>{t[e]=!0})}),t}),a=n;for(let e=1;e<=t;e++){let n=a;a=ri(n.length);for(let o=0;o{let t=ii(e.partialPath);x(t,e=>{i[o][e]=!0})})}}}}return r}function si(e,t,n,r){let i=new ni(e,W.ALTERNATION,r);return t.accept(i),oi(i.result,n)}function ci(e,t,n,r){let i=new ni(e,n);t.accept(i);let a=i.result,o=new ti(t,e,n).startWalking();return oi([new I({definition:a}),new I({definition:o})],r)}function li(e,t){compareOtherPath:for(let n=0;n{let r=t[n];return e===r||r.categoryMatchesMap[e.tokenTypeIdx]})}function di(e){return nt(e,e=>nt(e,e=>nt(e,e=>C(e.categoryMatches))))}function fi(e){let t=e.lookaheadStrategy.validate({rules:e.rules,tokenTypes:e.tokenTypes,grammarName:e.grammarName});return D(t,e=>Object.assign({type:G.CUSTOM_LOOKAHEAD_VALIDATION},e))}function pi(e,t,n,r){let i=N(e,e=>mi(e,n)),a=Ai(e,t,n),o=N(e,e=>Ei(e,n)),s=N(e,t=>vi(t,e,r,n));return i.concat(a,o,s)}function mi(e,t){let n=new _i;e.accept(n);let r=n.allProductions,i=ht(at(r,hi),e=>e.length>1);return D(y(i),n=>{let r=rt(n),i=t.buildDuplicateFoundError(e,n),a=Rt(r),o={message:i,type:G.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:a,occurrence:r.idx},s=gi(r);return s&&(o.parameter=s),o})}function hi(e){return`${Rt(e)}_#_${e.idx}_#_${gi(e)}`}function gi(e){return e instanceof z?e.terminalType.name:e instanceof F?e.nonTerminalName:``}var _i=class extends Pt{constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(e){this.allProductions.push(e)}visitOption(e){this.allProductions.push(e)}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}visitAlternation(e){this.allProductions.push(e)}visitTerminal(e){this.allProductions.push(e)}};function vi(e,t,n,r){let i=[];if(T(t,(t,n)=>n.name===e.name?t+1:t,0)>1){let t=r.buildDuplicateRuleNameError({topLevelRule:e,grammarName:n});i.push({message:t,type:G.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}function yi(e,t,n){let r=[],i;return P(t,e)||(i=`Invalid rule override, rule: ->${e}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:G.INVALID_RULE_OVERRIDE,ruleName:e})),r}function bi(e,t,n,r=[]){let i=[],a=xi(t.definition);if(C(a))return[];{let t=e.name;P(a,e)&&i.push({message:n.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:r}),type:G.LEFT_RECURSION,ruleName:t});let o=N(Qe(a,r.concat([e])),t=>{let i=j(r);return i.push(t),bi(e,t,n,i)});return i.concat(o)}}function xi(e){let t=[];if(C(e))return t;let n=rt(e);if(n instanceof F)t.push(n.referencedRule);else if(n instanceof I||n instanceof L||n instanceof Ot||n instanceof kt||n instanceof At||n instanceof R)t=t.concat(xi(n.definition));else if(n instanceof jt)t=Ne(D(n.definition,e=>xi(e.definition)));else if(!(n instanceof z))throw Error(`non exhaustive match`);let r=It(n),i=e.length>1;if(r&&i){let n=M(e);return t.concat(xi(n))}return t}var Si=class extends Pt{constructor(){super(...arguments),this.alternations=[]}visitAlternation(e){this.alternations.push(e)}};function Ci(e,t){let n=new Si;e.accept(n);let r=n.alternations;return N(r,n=>N($e(n.definition),(r,i)=>{let a=Jr([r],[],rr,1);return C(a)?[{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:G.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}]:[]}))}function wi(e,t,n){let r=new Si;e.accept(r);let i=r.alternations;return i=gt(i,e=>e.ignoreAmbiguities===!0),N(i,r=>{let i=r.idx,a=si(i,e,r.maxLookahead||t,r),o=Oi(a,r,e,n),s=ki(a,r,e,n);return o.concat(s)})}var Ti=class extends Pt{constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}};function Ei(e,t){let n=new Si;e.accept(n);let r=n.alternations;return N(r,n=>n.definition.length>255?[{message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:G.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}]:[])}function Di(e,t,n){let r=[];return x(e,e=>{let i=new Ti;e.accept(i);let a=i.allProductions;x(a,i=>{let a=Xr(i),o=i.maxLookahead||t,s=i.idx,c=ci(s,e,a,o)[0];if(C(Ne(c))){let t=n.buildEmptyRepetitionError({topLevelRule:e,repetition:i});r.push({message:t,type:G.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}})}),r}function Oi(e,t,n,r){let i=[],a=T(e,(n,r,a)=>(t.definition[a].ignoreAmbiguities===!0||x(r,r=>{let o=[a];x(e,(e,n)=>{a!==n&&li(e,r)&&t.definition[n].ignoreAmbiguities!==!0&&o.push(n)}),o.length>1&&!li(i,r)&&(i.push(r),n.push({alts:o,path:r}))}),n),[]);return D(a,e=>{let i=D(e.alts,e=>e+1);return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:G.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:t.idx,alternatives:e.alts}})}function ki(e,t,n,r){let i=T(e,(e,t,n)=>{let r=D(t,e=>({idx:n,path:e}));return e.concat(r)},[]);return Ke(N(i,e=>{if(t.definition[e.idx].ignoreAmbiguities===!0)return[];let a=e.idx,o=e.path,s=E(i,e=>t.definition[e.idx].ignoreAmbiguities!==!0&&e.idx{let i=[e.idx+1,a+1],o=t.idx===0?``:t.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:G.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}})}))}function Ai(e,t,n){let r=[],i=D(t,e=>e.name);return x(e,e=>{let t=e.name;if(P(i,t)){let i=n.buildNamespaceConflictError(e);r.push({message:i,type:G.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}}),r}function ji(e){let t=je(e,{errMsgProvider:Ir}),n={};return x(e.rules,e=>{n[e.name]=e}),Rr(n,t.errMsgProvider)}function Mi(e){return e=je(e,{errMsgProvider:Lr}),pi(e.rules,e.tokenTypes,e.errMsgProvider,e.grammarName)}var Ni=`MismatchedTokenException`,Pi=`NoViableAltException`,Fi=`EarlyExitException`,Ii=`NotAllInputParsedException`,Li=[Ni,Pi,Fi,Ii];Object.freeze(Li);function Ri(e){return P(Li,e.name)}var zi=class extends Error{constructor(e,t){super(e),this.token=t,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}},Bi=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Ni}},Vi=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Pi}},Hi=class extends zi{constructor(e,t){super(e,t),this.name=Ii}},Ui=class extends zi{constructor(e,t,n){super(e,t),this.previousToken=n,this.name=Fi}},Wi={},Gi=`InRuleRecoveryException`,Ki=class extends Error{constructor(e){super(e),this.name=Gi}},qi=class{initRecoverable(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=k(e,`recoveryEnabled`)?e.recoveryEnabled:Fa.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Ji)}getTokenToInsert(e){let t=Nr(e,``,NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t}canTokenTypeBeInsertedInRecovery(e){return!0}canTokenTypeBeDeletedInRecovery(e){return!0}tryInRepetitionRecovery(e,t,n,r){let i=this.findReSyncTokenType(),a=this.exportLexerState(),o=[],s=!1,c=this.LA(1),l=this.LA(1),u=()=>{let e=this.LA(0),t=new Bi(this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:c,previous:e,ruleName:this.getCurrRuleFullName()}),c,this.LA(0));t.resyncedTokens=$e(o),this.SAVE_ERROR(t)};for(;!s;)if(this.tokenMatcher(l,r)){u();return}else if(n.call(this)){u(),e.apply(this,t);return}else this.tokenMatcher(l,i)?s=!0:(l=this.SKIP_TOKEN(),this.addToResyncTokens(l,o));this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(e,t,n){return!(n===!1||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t)))}getFollowsForInRuleRecovery(e,t){let n=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){let e=this.SKIP_TOKEN();return this.consumeToken(),e}throw new Ki(`sad sad panda`)}canPerformInRuleRecovery(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)}canRecoverWithSingleTokenInsertion(e,t){if(!this.canTokenTypeBeInsertedInRecovery(e)||C(t))return!1;let n=this.LA(1);return Fe(t,e=>this.tokenMatcher(n,e))!==void 0}canRecoverWithSingleTokenDeletion(e){return this.canTokenTypeBeDeletedInRecovery(e)?this.tokenMatcher(this.LA(2),e):!1}isInCurrentRuleReSyncSet(e){let t=this.getCurrFollowKey();return P(this.getFollowSetFromFollowKey(t),e)}findReSyncTokenType(){let e=this.flattenFollowSet(),t=this.LA(1),n=2;for(;;){let r=Fe(e,e=>Pr(t,e));if(r!==void 0)return r;t=this.LA(n),n++}}getCurrFollowKey(){if(this.RULE_STACK.length===1)return Wi;let e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){let e=this.RULE_STACK,t=this.RULE_OCCURRENCE_STACK;return D(e,(n,r)=>r===0?Wi:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:t[r],inRule:this.shortRuleNameToFullName(e[r-1])})}flattenFollowSet(){let e=D(this.buildFullFollowKeyStack(),e=>this.getFollowSetFromFollowKey(e));return Ne(e)}getFollowSetFromFollowKey(e){if(e===Wi)return[Mr];let t=e.ruleName+e.idxInCallingRule+Gt+e.inRule;return this.resyncFollows[t]}addToResyncTokens(e,t){return this.tokenMatcher(e,Mr)||t.push(e),t}reSyncTo(e){let t=[],n=this.LA(1);for(;this.tokenMatcher(n,e)===!1;)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,t);return $e(t)}attemptInRepetitionRecovery(e,t,n,r,i,a,o){}getCurrentGrammarPath(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:j(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}}getHumanReadableRuleStack(){return D(this.RULE_STACK,e=>this.shortRuleNameToFullName(e))}};function Ji(e,t,n,r,i,a,o){let s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(c===void 0){let e=this.getCurrRuleFullName(),t=this.getGAstProductions()[e];c=new a(t,i).startWalking(),this.firstAfterRepMap[s]=c}let l=c.token,u=c.occurrence,d=c.isEndOfRule;this.RULE_STACK.length===1&&d&&l===void 0&&(l=Mr,u=1),l!==void 0&&u!==void 0&&this.shouldInRepetitionRecoveryBeTried(l,u,o)&&this.tryInRepetitionRecovery(e,t,n,l)}var Yi=1024,Xi=1280,Zi=1536;function Qi(e,t,n){return n|t|e}var $i=class{constructor(e){this.maxLookahead=e?.maxLookahead??Fa.maxLookahead}validate(e){let t=this.validateNoLeftRecursion(e.rules);if(C(t)){let n=this.validateEmptyOrAlternatives(e.rules),r=this.validateAmbiguousAlternationAlternatives(e.rules,this.maxLookahead),i=this.validateSomeNonEmptyLookaheadPath(e.rules,this.maxLookahead);return[...t,...n,...r,...i]}return t}validateNoLeftRecursion(e){return N(e,e=>bi(e,e,Lr))}validateEmptyOrAlternatives(e){return N(e,e=>Ci(e,Lr))}validateAmbiguousAlternationAlternatives(e,t){return N(e,e=>wi(e,t,Lr))}validateSomeNonEmptyLookaheadPath(e,t){return Di(e,t,Lr)}buildLookaheadForAlternation(e){return Zr(e.prodOccurrence,e.rule,e.maxLookahead,e.hasPredicates,e.dynamicTokensEnabled,$r)}buildLookaheadForOptional(e){return Qr(e.prodOccurrence,e.rule,e.maxLookahead,e.dynamicTokensEnabled,Xr(e.prodType),ei)}},ea=class{initLooksAhead(e){this.dynamicTokensEnabled=k(e,`dynamicTokensEnabled`)?e.dynamicTokensEnabled:Fa.dynamicTokensEnabled,this.maxLookahead=k(e,`maxLookahead`)?e.maxLookahead:Fa.maxLookahead,this.lookaheadStrategy=k(e,`lookaheadStrategy`)?e.lookaheadStrategy:new $i({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(e){x(e,e=>{this.TRACE_INIT(`${e.name} Rule Lookahead`,()=>{let{alternation:t,repetition:n,option:r,repetitionMandatory:i,repetitionMandatoryWithSeparator:a,repetitionWithSeparator:o}=na(e);x(t,t=>{let n=t.idx===0?``:t.idx;this.TRACE_INIT(`${Rt(t)}${n}`,()=>{let n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:t.idx,rule:e,maxLookahead:t.maxLookahead||this.maxLookahead,hasPredicates:t.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=Qi(this.fullRuleNameToShort[e.name],256,t.idx);this.setLaFuncCache(r,n)})}),x(n,t=>{this.computeLookaheadFunc(e,t.idx,768,`Repetition`,t.maxLookahead,Rt(t))}),x(r,t=>{this.computeLookaheadFunc(e,t.idx,512,`Option`,t.maxLookahead,Rt(t))}),x(i,t=>{this.computeLookaheadFunc(e,t.idx,Yi,`RepetitionMandatory`,t.maxLookahead,Rt(t))}),x(a,t=>{this.computeLookaheadFunc(e,t.idx,Zi,`RepetitionMandatoryWithSeparator`,t.maxLookahead,Rt(t))}),x(o,t=>{this.computeLookaheadFunc(e,t.idx,Xi,`RepetitionWithSeparator`,t.maxLookahead,Rt(t))})})})}computeLookaheadFunc(e,t,n,r,i,a){this.TRACE_INIT(`${a}${t===0?``:t}`,()=>{let a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:t,rule:e,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),o=Qi(this.fullRuleNameToShort[e.name],n,t);this.setLaFuncCache(o,a)})}getKeyForAutomaticLookahead(e,t){return Qi(this.getLastExplicitRuleShortName(),e,t)}getLaFuncFromCache(e){return this.lookAheadFuncsCache.get(e)}setLaFuncCache(e,t){this.lookAheadFuncsCache.set(e,t)}},ta=new class extends Pt{constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(e){this.dslMethods.option.push(e)}visitRepetitionWithSeparator(e){this.dslMethods.repetitionWithSeparator.push(e)}visitRepetitionMandatory(e){this.dslMethods.repetitionMandatory.push(e)}visitRepetitionMandatoryWithSeparator(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)}visitRepetition(e){this.dslMethods.repetition.push(e)}visitAlternation(e){this.dslMethods.alternation.push(e)}};function na(e){ta.reset(),e.accept(ta);let t=ta.dslMethods;return ta.reset(),t}function ra(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffsete.msg);throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>:\n\t${t.join(` + +`).replace(/\n/g,` + `)}`)}}},n.prototype.constructor=n,n._RULE_NAMES=t,n}function da(e,t,n){let r=function(){};ca(r,e+`BaseSemanticsWithDefaults`);let i=Object.create(n.prototype);return x(t,e=>{i[e]=la}),r.prototype=i,r.prototype.constructor=r,r}var fa;(function(e){e[e.REDUNDANT_METHOD=0]=`REDUNDANT_METHOD`,e[e.MISSING_METHOD=1]=`MISSING_METHOD`})(fa||={});function pa(e,t){return ma(e,t)}function ma(e,t){let n=E(t,t=>b(e[t])===!1);return Ke(D(n,t=>({msg:`Missing visitor method: <${t}> on ${e.constructor.name} CST Visitor.`,type:fa.MISSING_METHOD,methodName:t})))}var ha=class{initTreeBuilder(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=k(e,`nodeLocationTracking`)?e.nodeLocationTracking:Fa.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=w,this.cstFinallyStateUpdate=w,this.cstPostTerminal=w,this.cstPostNonTerminal=w,this.cstPostRule=w;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ia,this.setNodeLocationFromNode=ia,this.cstPostRule=w,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ra,this.setNodeLocationFromNode=ra,this.cstPostRule=w,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=w,this.setNodeLocationFromNode=w,this.cstPostRule=w,this.setInitialNodeLocation=w;else throw Error(`Invalid config option: "${e.nodeLocationTracking}"`)}setInitialNodeLocationOnlyOffsetRecovery(e){e.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(e){let t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(e){let t={name:e,children:Object.create(null)};this.setInitialNodeLocation(t),this.CST_STACK.push(t)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?(n.endOffset=t.endOffset,n.endLine=t.endLine,n.endColumn=t.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?n.endOffset=t.endOffset:n.startOffset=NaN}cstPostTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];aa(n,t,e),this.setNodeLocationFromToken(n.location,t)}cstPostNonTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];oa(n,t,e),this.setNodeLocationFromNode(n.location,e.location)}getBaseCstVisitorConstructor(){if(xe(this.baseCstVisitorConstructor)){let e=ua(this.className,v(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if(xe(this.baseCstVisitorWithDefaultsConstructor)){let e=da(this.className,v(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-1]}getPreviousExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-2]}getLastExplicitRuleOccurrenceIndex(){let e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]}},ga=class{initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(e){if(this.selfAnalysisDone!==!0)throw Error(`Missing invocation at the end of the Parser's constructor.`);this.reset(),this.tokVector=e,this.tokVectorLength=e.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):Pa}LA(e){let t=this.currIdx+e;return t<0||this.tokVectorLength<=t?Pa:this.tokVector[t]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(e){this.currIdx=e}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},_a=class{ACTION(e){return e.call(this)}consume(e,t,n){return this.consumeInternal(t,e,n)}subrule(e,t,n){return this.subruleInternal(t,e,n)}option(e,t){return this.optionInternal(t,e)}or(e,t){return this.orInternal(t,e)}many(e,t){return this.manyInternal(e,t)}atLeastOne(e,t){return this.atLeastOneInternal(e,t)}CONSUME(e,t){return this.consumeInternal(e,0,t)}CONSUME1(e,t){return this.consumeInternal(e,1,t)}CONSUME2(e,t){return this.consumeInternal(e,2,t)}CONSUME3(e,t){return this.consumeInternal(e,3,t)}CONSUME4(e,t){return this.consumeInternal(e,4,t)}CONSUME5(e,t){return this.consumeInternal(e,5,t)}CONSUME6(e,t){return this.consumeInternal(e,6,t)}CONSUME7(e,t){return this.consumeInternal(e,7,t)}CONSUME8(e,t){return this.consumeInternal(e,8,t)}CONSUME9(e,t){return this.consumeInternal(e,9,t)}SUBRULE(e,t){return this.subruleInternal(e,0,t)}SUBRULE1(e,t){return this.subruleInternal(e,1,t)}SUBRULE2(e,t){return this.subruleInternal(e,2,t)}SUBRULE3(e,t){return this.subruleInternal(e,3,t)}SUBRULE4(e,t){return this.subruleInternal(e,4,t)}SUBRULE5(e,t){return this.subruleInternal(e,5,t)}SUBRULE6(e,t){return this.subruleInternal(e,6,t)}SUBRULE7(e,t){return this.subruleInternal(e,7,t)}SUBRULE8(e,t){return this.subruleInternal(e,8,t)}SUBRULE9(e,t){return this.subruleInternal(e,9,t)}OPTION(e){return this.optionInternal(e,0)}OPTION1(e){return this.optionInternal(e,1)}OPTION2(e){return this.optionInternal(e,2)}OPTION3(e){return this.optionInternal(e,3)}OPTION4(e){return this.optionInternal(e,4)}OPTION5(e){return this.optionInternal(e,5)}OPTION6(e){return this.optionInternal(e,6)}OPTION7(e){return this.optionInternal(e,7)}OPTION8(e){return this.optionInternal(e,8)}OPTION9(e){return this.optionInternal(e,9)}OR(e){return this.orInternal(e,0)}OR1(e){return this.orInternal(e,1)}OR2(e){return this.orInternal(e,2)}OR3(e){return this.orInternal(e,3)}OR4(e){return this.orInternal(e,4)}OR5(e){return this.orInternal(e,5)}OR6(e){return this.orInternal(e,6)}OR7(e){return this.orInternal(e,7)}OR8(e){return this.orInternal(e,8)}OR9(e){return this.orInternal(e,9)}MANY(e){this.manyInternal(0,e)}MANY1(e){this.manyInternal(1,e)}MANY2(e){this.manyInternal(2,e)}MANY3(e){this.manyInternal(3,e)}MANY4(e){this.manyInternal(4,e)}MANY5(e){this.manyInternal(5,e)}MANY6(e){this.manyInternal(6,e)}MANY7(e){this.manyInternal(7,e)}MANY8(e){this.manyInternal(8,e)}MANY9(e){this.manyInternal(9,e)}MANY_SEP(e){this.manySepFirstInternal(0,e)}MANY_SEP1(e){this.manySepFirstInternal(1,e)}MANY_SEP2(e){this.manySepFirstInternal(2,e)}MANY_SEP3(e){this.manySepFirstInternal(3,e)}MANY_SEP4(e){this.manySepFirstInternal(4,e)}MANY_SEP5(e){this.manySepFirstInternal(5,e)}MANY_SEP6(e){this.manySepFirstInternal(6,e)}MANY_SEP7(e){this.manySepFirstInternal(7,e)}MANY_SEP8(e){this.manySepFirstInternal(8,e)}MANY_SEP9(e){this.manySepFirstInternal(9,e)}AT_LEAST_ONE(e){this.atLeastOneInternal(0,e)}AT_LEAST_ONE1(e){return this.atLeastOneInternal(1,e)}AT_LEAST_ONE2(e){this.atLeastOneInternal(2,e)}AT_LEAST_ONE3(e){this.atLeastOneInternal(3,e)}AT_LEAST_ONE4(e){this.atLeastOneInternal(4,e)}AT_LEAST_ONE5(e){this.atLeastOneInternal(5,e)}AT_LEAST_ONE6(e){this.atLeastOneInternal(6,e)}AT_LEAST_ONE7(e){this.atLeastOneInternal(7,e)}AT_LEAST_ONE8(e){this.atLeastOneInternal(8,e)}AT_LEAST_ONE9(e){this.atLeastOneInternal(9,e)}AT_LEAST_ONE_SEP(e){this.atLeastOneSepFirstInternal(0,e)}AT_LEAST_ONE_SEP1(e){this.atLeastOneSepFirstInternal(1,e)}AT_LEAST_ONE_SEP2(e){this.atLeastOneSepFirstInternal(2,e)}AT_LEAST_ONE_SEP3(e){this.atLeastOneSepFirstInternal(3,e)}AT_LEAST_ONE_SEP4(e){this.atLeastOneSepFirstInternal(4,e)}AT_LEAST_ONE_SEP5(e){this.atLeastOneSepFirstInternal(5,e)}AT_LEAST_ONE_SEP6(e){this.atLeastOneSepFirstInternal(6,e)}AT_LEAST_ONE_SEP7(e){this.atLeastOneSepFirstInternal(7,e)}AT_LEAST_ONE_SEP8(e){this.atLeastOneSepFirstInternal(8,e)}AT_LEAST_ONE_SEP9(e){this.atLeastOneSepFirstInternal(9,e)}RULE(e,t,n=Ia){if(P(this.definedRulesNames,e)){let t={message:Lr.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:G.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(t)}this.definedRulesNames.push(e);let r=this.defineRule(e,t,n);return this[e]=r,r}OVERRIDE_RULE(e,t,n=Ia){let r=yi(e,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);let i=this.defineRule(e,t,n);return this[e]=i,i}BACKTRACK(e,t){return function(){this.isBackTrackingStack.push(1);let n=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(Ri(e))return!1;throw e}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return Mt(y(this.gastProductionsCache))}},va=class{initRecognizerEngine(e,t){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=ir,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},k(t,`serializedGrammar`))throw Error(`The Parser's configuration can no longer contain a property. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 + For Further details.`);if(S(e)){if(C(e))throw Error(`A Token Vocabulary cannot be empty. + Note that the first argument for the parser constructor + is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset==`number`)throw Error(`The Parser constructor no longer accepts a token vector as the first argument. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 + For Further details.`)}if(S(e))this.tokensMap=T(e,(e,t)=>(e[t.name]=t,e),{});else if(k(e,`modes`)&&nt(Ne(y(e.modes)),_r)){let t=yt(Ne(y(e.modes)));this.tokensMap=T(t,(e,t)=>(e[t.name]=t,e),{})}else if(Ce(e))this.tokensMap=j(e);else throw Error(` argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition`);this.tokensMap.EOF=Mr;let n=nt(k(e,`modes`)?Ne(y(e.modes)):y(e),e=>C(e.categoryMatches));this.tokenMatcher=n?ir:rr,sr(y(this.tokensMap))}defineRule(e,t,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${e}> may not be defined after the 'performSelfAnalysis' method has been called'\nMake sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);let r=k(n,`resyncEnabled`)?n.resyncEnabled:Ia.resyncEnabled,i=k(n,`recoveryValueFunc`)?n.recoveryValueFunc:Ia.recoveryValueFunc,a=this.ruleShortNameIdx<<12;this.ruleShortNameIdx++,this.shortRuleNameToFull[a]=e,this.fullRuleNameToShort[e]=a;let o;return o=this.outputCst===!0?function(...n){try{this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n);let r=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(r),r}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}}:function(...n){try{return this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n)}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}},Object.assign(o,{ruleName:e,originalGrammarAction:t})}invokeRuleCatch(e,t,n){let r=this.RULE_STACK.length===1,i=t&&!this.isBackTracking()&&this.recoveryEnabled;if(Ri(e)){let t=e;if(i){let r=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(r)){if(t.resyncedTokens=this.reSyncTo(r),this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];return e.recoveredNode=!0,e}return n(e)}if(this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];e.recoveredNode=!0,t.partialCstResult=e}throw t}if(r)return this.moveToTerminatedState(),n(e);throw t}throw e}optionInternal(e,t){let n=this.getKeyForAutomaticLookahead(512,t);return this.optionInternalLogic(e,t,n)}optionInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof e!=`function`){i=e.DEF;let t=e.GATE;if(t!==void 0){let e=r;r=()=>t.call(this)&&e.call(this)}}else i=e;if(r.call(this)===!0)return i.call(this)}atLeastOneInternal(e,t){let n=this.getKeyForAutomaticLookahead(Yi,e);return this.atLeastOneInternalLogic(e,t,n)}atLeastOneInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=()=>e.call(this)&&t.call(this)}}else i=t;if(r.call(this)===!0){let e=this.doSingleRepetition(i);for(;r.call(this)===!0&&e===!0;)e=this.doSingleRepetition(i)}else throw this.raiseEarlyExitException(e,W.REPETITION_MANDATORY,t.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,t],r,Yi,e,Gr)}atLeastOneSepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Zi,e);this.atLeastOneSepFirstInternalLogic(e,t,n)}atLeastOneSepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=()=>this.tokenMatcher(this.LA(1),i);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,Kr],t,Zi,e,Kr)}else throw this.raiseEarlyExitException(e,W.REPETITION_MANDATORY_WITH_SEPARATOR,t.ERR_MSG)}manyInternal(e,t){let n=this.getKeyForAutomaticLookahead(768,e);return this.manyInternalLogic(e,t,n)}manyInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=()=>e.call(this)&&t.call(this)}}else i=t;let a=!0;for(;r.call(this)===!0&&a===!0;)a=this.doSingleRepetition(i);this.attemptInRepetitionRecovery(this.manyInternal,[e,t],r,768,e,Ur,a)}manySepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Xi,e);this.manySepFirstInternalLogic(e,t,n)}manySepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=()=>this.tokenMatcher(this.LA(1),i);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,Wr],t,Xi,e,Wr)}}repetitionSepSecondInternal(e,t,n,r,i){for(;n();)this.CONSUME(t),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,t,n,r,i],n,Zi,e,i)}doSingleRepetition(e){let t=this.getLexerPosition();return e.call(this),this.getLexerPosition()>t}orInternal(e,t){let n=this.getKeyForAutomaticLookahead(256,t),r=S(e)?e:e.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(i!==void 0)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){let e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new Hi(t,e))}}subruleInternal(e,t,n){let r;try{let i=n===void 0?void 0:n.ARGS;return this.subruleIdx=t,r=e.apply(this,i),this.cstPostNonTerminal(r,n!==void 0&&n.LABEL!==void 0?n.LABEL:e.ruleName),r}catch(t){throw this.subruleInternalError(t,n,e.ruleName)}}subruleInternalError(e,t,n){throw Ri(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,t!==void 0&&t.LABEL!==void 0?t.LABEL:n),delete e.partialCstResult),e}consumeInternal(e,t,n){let r;try{let t=this.LA(1);this.tokenMatcher(t,e)===!0?(this.consumeToken(),r=t):this.consumeInternalError(e,t,n)}catch(n){r=this.consumeInternalRecovery(e,t,n)}return this.cstPostTerminal(n!==void 0&&n.LABEL!==void 0?n.LABEL:e.name,r),r}consumeInternalError(e,t,n){let r,i=this.LA(0);throw r=n!==void 0&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new Bi(r,t,i))}consumeInternalRecovery(e,t,n){if(this.recoveryEnabled&&n.name===`MismatchedTokenException`&&!this.isBackTracking()){let r=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,r)}catch(e){throw e.name===`InRuleRecoveryException`?n:e}}throw n}saveRecogState(){let e=this.errors,t=j(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK}}reloadRecogState(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK}ruleInvocationStateUpdate(e,t,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t)}isBackTracking(){return this.isBackTrackingStack.length!==0}getCurrRuleFullName(){let e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]}shortRuleNameToFullName(e){return this.shortRuleNameToFull[e]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),Mr)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},ya=class{initErrorHandler(e){this._errors=[],this.errorMessageProvider=k(e,`errorMessageProvider`)?e.errorMessageProvider:Fa.errorMessageProvider}SAVE_ERROR(e){if(Ri(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:j(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error(`Trying to save an Error which is not a RecognitionException`)}get errors(){return j(this._errors)}set errors(e){this._errors=e}raiseEarlyExitException(e,t,n){let r=this.getCurrRuleFullName(),i=this.getGAstProductions()[r],a=ci(e,i,t,this.maxLookahead)[0],o=[];for(let e=1;e<=this.maxLookahead;e++)o.push(this.LA(e));let s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new Ui(s,this.LA(1),this.LA(0)))}raiseNoAltException(e,t){let n=this.getCurrRuleFullName(),r=this.getGAstProductions()[n],i=si(e,r,this.maxLookahead),a=[];for(let e=1;e<=this.maxLookahead;e++)a.push(this.LA(e));let o=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:o,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new Vi(s,this.LA(1),o))}},ba=class{initContentAssist(){}computeContentAssist(e,t){let n=this.gastProductionsCache[e];if(xe(n))throw Error(`Rule ->${e}<- does not exist in this grammar.`);return Jr([n],t,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(e){let t=rt(e.ruleStack),n=this.getGAstProductions()[t];return new Vr(n,e).startWalking()}},xa={description:`This Object indicates the Parser is during Recording Phase`};Object.freeze(xa);var Sa=!0,Ca=255,wa=U({name:`RECORDING_PHASE_TOKEN`,pattern:H.NA});sr([wa]);var Ta=Nr(wa,`This IToken indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(Ta);var Ea={name:`This CSTNode indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},Da=class{initGastRecorder(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT(`Enable Recording`,()=>{for(let e=0;e<10;e++){let t=e>0?e:``;this[`CONSUME${t}`]=function(t,n){return this.consumeInternalRecord(t,e,n)},this[`SUBRULE${t}`]=function(t,n){return this.subruleInternalRecord(t,e,n)},this[`OPTION${t}`]=function(t){return this.optionInternalRecord(t,e)},this[`OR${t}`]=function(t){return this.orInternalRecord(t,e)},this[`MANY${t}`]=function(t){this.manyInternalRecord(e,t)},this[`MANY_SEP${t}`]=function(t){this.manySepFirstInternalRecord(e,t)},this[`AT_LEAST_ONE${t}`]=function(t){this.atLeastOneInternalRecord(e,t)},this[`AT_LEAST_ONE_SEP${t}`]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}}this.consume=function(e,t,n){return this.consumeInternalRecord(t,e,n)},this.subrule=function(e,t,n){return this.subruleInternalRecord(t,e,n)},this.option=function(e,t){return this.optionInternalRecord(t,e)},this.or=function(e,t){return this.orInternalRecord(t,e)},this.many=function(e,t){this.manyInternalRecord(e,t)},this.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD})}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT(`Deleting Recording methods`,()=>{let e=this;for(let t=0;t<10;t++){let n=t>0?t:``;delete e[`CONSUME${n}`],delete e[`SUBRULE${n}`],delete e[`OPTION${n}`],delete e[`OR${n}`],delete e[`MANY${n}`],delete e[`MANY_SEP${n}`],delete e[`AT_LEAST_ONE${n}`],delete e[`AT_LEAST_ONE_SEP${n}`]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})}ACTION_RECORD(e){}BACKTRACK_RECORD(e,t){return()=>!0}LA_RECORD(e){return Pa}topLevelRuleRecord(e,t){try{let n=new Dt({definition:[],name:e});return n.name=e,this.recordingProdStack.push(n),t.call(this),this.recordingProdStack.pop(),n}catch(e){if(e.KNOWN_RECORDER_ERROR!==!0)try{e.message+=` + This error was thrown during the "grammar recording phase" For more info see: + https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch{throw e}throw e}}optionInternalRecord(e,t){return Oa.call(this,L,e,t)}atLeastOneInternalRecord(e,t){Oa.call(this,Ot,t,e)}atLeastOneSepFirstInternalRecord(e,t){Oa.call(this,kt,t,e,Sa)}manyInternalRecord(e,t){Oa.call(this,R,t,e)}manySepFirstInternalRecord(e,t){Oa.call(this,At,t,e,Sa)}orInternalRecord(e,t){return ka.call(this,e,t)}subruleInternalRecord(e,t,n){if(ja(t),!e||k(e,`ruleName`)===!1){let n=Error(` argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=Ie(this.recordingProdStack),i=e.ruleName,a=new F({idx:t,nonTerminalName:i,label:n?.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?Ea:xa}consumeInternalRecord(e,t,n){if(ja(t),!pr(e)){let n=Error(` argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=Ie(this.recordingProdStack),i=new z({idx:t,terminalType:e,label:n?.LABEL});return r.definition.push(i),Ta}};function Oa(e,t,n,r=!1){ja(n);let i=Ie(this.recordingProdStack),a=b(t)?t:t.DEF,o=new e({definition:[],idx:n});return r&&(o.separator=t.SEP),k(t,`MAX_LOOKAHEAD`)&&(o.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(o),a.call(this),i.definition.push(o),this.recordingProdStack.pop(),xa}function ka(e,t){ja(t);let n=Ie(this.recordingProdStack),r=S(e)===!1,i=r===!1?e:e.DEF,a=new jt({definition:[],idx:t,ignoreAmbiguities:r&&e.IGNORE_AMBIGUITIES===!0});return k(e,`MAX_LOOKAHEAD`)&&(a.maxLookahead=e.MAX_LOOKAHEAD),a.hasPredicates=vt(i,e=>b(e.GATE)),n.definition.push(a),x(i,e=>{let t=new I({definition:[]});a.definition.push(t),k(e,`IGNORE_AMBIGUITIES`)?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:k(e,`GATE`)&&(t.ignoreAmbiguities=!0),this.recordingProdStack.push(t),e.ALT.call(this),this.recordingProdStack.pop()}),xa}function Aa(e){return e===0?``:`${e}`}function ja(e){if(e<0||e>Ca){let t=Error(`Invalid DSL Method idx value: <${e}>\n\tIdx value must be a none negative value smaller than ${Ca+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}var Ma=class{initPerformanceTracer(e){if(k(e,`traceInitPerf`)){let t=e.traceInitPerf,n=typeof t==`number`;this.traceInitMaxIdent=n?t:1/0,this.traceInitPerf=n?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=Fa.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(e,t){if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent <${e}>`);let{time:r,value:i}=St(t),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return t()}};function Na(e,t){t.forEach(t=>{let n=t.prototype;Object.getOwnPropertyNames(n).forEach(r=>{if(r===`constructor`)return;let i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(e.prototype,r,i):e.prototype[r]=t.prototype[r]})})}var Pa=Nr(Mr,``,NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(Pa);var Fa=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:Fr,nodeLocationTracking:`none`,traceInitPerf:!1,skipValidations:!1}),Ia=Object.freeze({recoveryValueFunc:()=>void 0,resyncEnabled:!0}),G;(function(e){e[e.INVALID_RULE_NAME=0]=`INVALID_RULE_NAME`,e[e.DUPLICATE_RULE_NAME=1]=`DUPLICATE_RULE_NAME`,e[e.INVALID_RULE_OVERRIDE=2]=`INVALID_RULE_OVERRIDE`,e[e.DUPLICATE_PRODUCTIONS=3]=`DUPLICATE_PRODUCTIONS`,e[e.UNRESOLVED_SUBRULE_REF=4]=`UNRESOLVED_SUBRULE_REF`,e[e.LEFT_RECURSION=5]=`LEFT_RECURSION`,e[e.NONE_LAST_EMPTY_ALT=6]=`NONE_LAST_EMPTY_ALT`,e[e.AMBIGUOUS_ALTS=7]=`AMBIGUOUS_ALTS`,e[e.CONFLICT_TOKENS_RULES_NAMESPACE=8]=`CONFLICT_TOKENS_RULES_NAMESPACE`,e[e.INVALID_TOKEN_NAME=9]=`INVALID_TOKEN_NAME`,e[e.NO_NON_EMPTY_LOOKAHEAD=10]=`NO_NON_EMPTY_LOOKAHEAD`,e[e.AMBIGUOUS_PREFIX_ALTS=11]=`AMBIGUOUS_PREFIX_ALTS`,e[e.TOO_MANY_ALTS=12]=`TOO_MANY_ALTS`,e[e.CUSTOM_LOOKAHEAD_VALIDATION=13]=`CUSTOM_LOOKAHEAD_VALIDATION`})(G||={});var La=class e{static performSelfAnalysis(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT(`performSelfAnalysis`,()=>{let t;this.selfAnalysisDone=!0;let n=this.className;this.TRACE_INIT(`toFastProps`,()=>{Ct(this)}),this.TRACE_INIT(`Grammar Recording`,()=>{try{this.enableRecording(),x(this.definedRulesNames,e=>{let t=this[e].originalGrammarAction,n;this.TRACE_INIT(`${e} Rule`,()=>{n=this.topLevelRuleRecord(e,t)}),this.gastProductionsCache[e]=n})}finally{this.disableRecording()}});let r=[];if(this.TRACE_INIT(`Grammar Resolving`,()=>{r=ji({rules:y(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(r)}),this.TRACE_INIT(`Grammar Validations`,()=>{if(C(r)&&this.skipValidations===!1){let e=Mi({rules:y(this.gastProductionsCache),tokenTypes:y(this.tokensMap),errMsgProvider:Lr,grammarName:n}),t=fi({lookaheadStrategy:this.lookaheadStrategy,rules:y(this.gastProductionsCache),tokenTypes:y(this.tokensMap),grammarName:n});this.definitionErrors=this.definitionErrors.concat(e,t)}}),C(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT(`computeAllProdsFollows`,()=>{let e=qt(y(this.gastProductionsCache));this.resyncFollows=e}),this.TRACE_INIT(`ComputeLookaheadFunctions`,()=>{var e,t;(t=(e=this.lookaheadStrategy).initialize)==null||t.call(e,{rules:y(this.gastProductionsCache)}),this.preComputeLookaheadFunctions(y(this.gastProductionsCache))})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!C(this.definitionErrors))throw t=D(this.definitionErrors,e=>e.message),Error(`Parser Definition Errors detected:\n ${t.join(` +------------------------------- +`)}`)})}constructor(e,t){this.definitionErrors=[],this.selfAnalysisDone=!1;let n=this;if(n.initErrorHandler(t),n.initLexerAdapter(),n.initLooksAhead(t),n.initRecognizerEngine(e,t),n.initRecoverable(t),n.initTreeBuilder(t),n.initContentAssist(),n.initGastRecorder(t),n.initPerformanceTracer(t),k(t,`ignoredIssues`))throw Error(`The IParserConfig property has been deprecated. + Please use the flag on the relevant DSL method instead. + See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES + For further details.`);this.skipValidations=k(t,`skipValidations`)?t.skipValidations:Fa.skipValidations}};La.DEFER_DEFINITION_ERRORS_HANDLING=!1,Na(La,[qi,ea,ha,ga,va,_a,ya,ba,Da,Ma]);var Ra=class extends La{constructor(e,t=Fa){let n=j(t);n.outputCst=!0,super(e,n)}};function za(e,t){let n=e.lexer.tokenize(t);if(n.errors.length>0){let r=n.errors[0],i=Number.isFinite(r.offset)?r.offset:t.length,a=i+(Number.isFinite(r.length)?r.length:0);throw Error(`Error lexing ${e.diagramType} diagram: ${r.message} at line ${r.line??1}, column ${r.column??1} [${i},${a})`)}e.parser.input=n.tokens;let r=e.entry();if(e.parser.errors.length>0)throw Error(`Error parsing ${e.diagramType} diagram: ${e.parser.errors[0].message}`);e.visit(r)}n(za,`runChevrotainParse`);var K={SOLID_ARROW:0,BACK_ARROW:1,LINE_SOLID:2,CIRCLE_ARROW:3,CROSS_ARROW:4,CIRCLE_ARROW_REVERSED:5,CROSS_ARROW_REVERSED:6},Ba=`LR`,Va=s.usecase,Ha=n(()=>({actors:new Map,useCases:new Map,systemBoundaries:new Map,relationships:[],notes:new Map,jsonNodes:new Map,classDefs:new Map,symbols:new Map,direction:Ba,relationshipCounter:0,noteCounter:0,accTitle:``,accDescription:``,ast:void 0,config:structuredClone(Va)}),`createModel`),Ua=n(e=>{if(!(e.actors instanceof Map)||!(e.useCases instanceof Map)||!(e.systemBoundaries instanceof Map)||!Array.isArray(e.relationships)||!(e.notes instanceof Map)||!(e.jsonNodes instanceof Map)||!(e.classDefs instanceof Map)||!(e.symbols instanceof Map)||![`TB`,`TD`,`BT`,`RL`,`LR`].includes(e.direction)||!Number.isSafeInteger(e.relationshipCounter)||e.relationshipCounter<0||!Number.isSafeInteger(e.noteCounter)||e.noteCounter<0||typeof e.accTitle!=`string`||typeof e.accDescription!=`string`||!e.config)throw Error(`Cannot commit an incomplete usecase model`)},`assertCompleteModel`),q=Ha(),Wa=n(()=>structuredClone(q.config),`getConfig`),Ga=n(()=>q.ast,`getAST`),Ka=n(e=>{let t=structuredClone(e);Ua(t);let n=f(),a=l();try{i(t.accTitle),r(t.accDescription),q=t}catch(e){throw i(n),r(a),e}},`commit`),qa=n(()=>{q=Ha(),a()},`clear`),Ja=n(()=>q.actors,`getActors`),Ya=n(e=>q.actors.get(e),`getActor`),Xa=n(()=>q.useCases,`getUseCases`),Za=n(e=>q.useCases.get(e),`getUseCase`),Qa=n(()=>q.systemBoundaries,`getSystemBoundaries`),$a=n(e=>q.systemBoundaries.get(e),`getSystemBoundary`),eo=n(()=>q.relationships,`getRelationships`),to=n(()=>q.notes,`getNotes`),no=n(e=>q.notes.get(e),`getNote`),ro=n(()=>q.jsonNodes,`getJsonNodes`),io=n(e=>q.jsonNodes.get(e),`getJsonNode`),ao=n(()=>q.classDefs,`getClassDefs`),oo=n(e=>q.classDefs.get(e),`getClassDef`),so=n(()=>q.direction,`getDirection`),co=n(e=>{let t=new Map;for(let n of[`default`,...e]){let e=q.classDefs.get(n);if(e)for(let n of e.styles){let e=n.trim(),r=e.indexOf(`:`),i=(r===-1?e:e.slice(0,r)).trim();i&&t.set(i,e)}}return[...t.values()]},`getCompiledStyles`),lo=n(e=>e.replaceAll(`~`,`~0`).replaceAll(`/`,`~1`),`escapeJsonPointerPart`),uo=n(e=>typeof e==`string`?e:e===null?`null`:String(e),`displayJsonScalar`),fo=n((e,t,r=e=>e)=>{let i=[],a=n((e,t,n)=>{i.push({key:r(e),accessibleKey:r(t),value:r(n)})},`append`),o=n((e,n,r)=>{if(Array.isArray(e)){if(e.length===0){a(n,n,`[]`);return}if(e.every(e=>e===null||[`string`,`number`,`boolean`].includes(typeof e))){for(let[t,r]of e.entries())a(t===0?n:``,n,uo(r));return}for(let[t,i]of e.entries())o(i,`${n}[${t}]`,`${r}/${t}`);return}if(typeof e==`object`&&e){let i=e,s=t[r]??Object.keys(i);if(s.length===0){a(n,n,`{}`);return}for(let e of s){let t=n?`${n}.${e}`:e;o(i[e],t,`${r}/${lo(e)}`)}return}a(n,n,uo(e))},`visit`);return o(e,``,``),i},`flattenJsonRows`),po=n(e=>{switch(e.type){case`hollow`:return`usecaseActorHollow`;case`awesome`:return`usecaseActorAwesome`;case`icon`:return`usecaseActorIcon`;case`normal`:return`usecaseActor`}},`actorShape`),mo=n(e=>e.shape===`ellipse`?e.business?`usecaseBusiness`:`usecaseEllipse`:e.shape,`useCaseShape`),ho=n(e=>{switch(e){case K.SOLID_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_point`};case K.BACK_ARROW:return{arrowTypeStart:`arrow_point`,arrowTypeEnd:`none`};case K.CIRCLE_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_circle`};case K.CROSS_ARROW:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_cross`};case K.CIRCLE_ARROW_REVERSED:return{arrowTypeStart:`arrow_circle`,arrowTypeEnd:`none`};case K.CROSS_ARROW_REVERSED:return{arrowTypeStart:`arrow_cross`,arrowTypeEnd:`none`};case K.LINE_SOLID:return{arrowTypeStart:`none`,arrowTypeEnd:`none`}}},`associationMarkers`),go=n(e=>{switch(e.type){case`include`:case`extend`:return{arrowTypeStart:`none`,arrowTypeEnd:`arrow_point`,pattern:`dotted`,label:e.type,labelType:`text`};case`generalization`:return{arrowTypeStart:`none`,arrowTypeEnd:`extension`,pattern:`solid`};case`association`:return{...ho(e.arrowType),pattern:`solid`,...e.label?{label:e.label}:{},...e.labelType?{labelType:e.labelType}:{}}}},`relationshipVisuals`),_o=n(e=>e.animate||e.animation?[`edge-animation-${e.animation??`fast`}`]:[],`animationClasses`),vo=n((...e)=>e.filter(e=>!!e).join(` `),`classNames`),yo={getConfig:Wa,createModel:Ha,commit:Ka,getAST:Ga,clear:qa,setDiagramTitle:c,getDiagramTitle:u,setAccTitle:i,getAccTitle:f,setAccDescription:r,getAccDescription:l,getActors:Ja,getActor:Ya,getUseCases:Xa,getUseCase:Za,getSystemBoundaries:Qa,getSystemBoundary:$a,getRelationships:eo,getNotes:to,getNote:no,getJsonNodes:ro,getJsonNode:io,getClassDefs:ao,getClassDef:oo,getDirection:so,getData:n(()=>{let e=d(),t={...q.config,...e.usecase},r=n(t=>p(t,e),`sanitize`),i=n(e=>r(q.actors.get(e)?.label??q.useCases.get(e)?.label??q.jsonNodes.get(e)?.id??q.notes.get(e)?.label??e),`endpointLabel`),a=[],o=[],s=0,c=0;for(let t of q.actors.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:po(t),isGroup:!1,padding:10,look:e.look,colorIndex:s++,cssClasses:vo(`default`,`usecase-actor`,`usecase-actor-${t.type}`,t.business&&`usecase-business`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),actorType:t.type,business:t.business,...t.icon?{icon:t.icon}:{},...t.stereotype?{stereotype:r(t.stereotype)}:{},...t.parentId?{parentId:t.parentId}:{}});for(let t of q.useCases.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:mo(t),isGroup:!1,padding:t.shape===`ellipse`?20:10,look:e.look,colorIndex:s++,cssClasses:vo(`default`,`usecase-element`,`usecase-${t.shape}`,t.business&&`usecase-business`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),business:t.business,...t.stereotype?{stereotype:r(t.stereotype)}:{},...t.parentId?{parentId:t.parentId}:{}});for(let t of q.notes.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:`note`,isGroup:!1,padding:10,look:e.look,cssClasses:`default usecase-note`,cssStyles:[],cssCompiledStyles:co([]),noteTarget:t.target,noteTargetLabel:r(q.actors.get(t.target)?.label??q.useCases.get(t.target)?.label??q.jsonNodes.get(t.target)?.id??t.target)});for(let t of q.jsonNodes.values())a.push({id:t.id,label:r(t.id),labelType:`text`,shape:`usecaseJsonTable`,isGroup:!1,padding:10,look:e.look,cssClasses:vo(`default`,`usecase-json-table`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),jsonRows:fo(t.value,t.propertyOrder,r)});for(let t of q.systemBoundaries.values())a.push({id:t.id,label:r(t.label),labelType:t.labelType,shape:`usecaseSystemBoundary`,isGroup:!0,padding:20,look:e.look,colorIndex:c++,cssClasses:vo(`default`,`system-boundary`,`system-boundary-${t.type}`,...t.classes),cssStyles:[...t.styles],cssCompiledStyles:co(t.classes),boundaryType:t.type});for(let t of q.relationships){let{label:n,...a}=go(t);o.push({id:t.id,start:t.source,end:t.target,source:t.source,target:t.target,sourceLabel:i(t.source),targetLabel:i(t.target),type:`edge`,relationshipType:t.type,internal:!1,...a,...n===void 0?{}:{label:r(n)},labelpos:`c`,classes:vo(`default`,`relationship`,`relationship-${t.type}`,...t.classes,..._o(t)),style:[...t.styles],cssCompiledStyles:co(t.classes),animate:t.animate,...t.animation?{animation:t.animation}:{},look:e.look,thickness:`normal`,minlen:t.minlen,isUserDefinedId:t.explicitId})}for(let t of q.notes.values())o.push({id:`${t.id}-edge`,start:t.id,end:t.target,source:t.id,target:t.target,type:`edge`,relationshipType:`note`,sourceLabel:i(t.id),targetLabel:i(t.target),internal:!0,pattern:`dotted`,arrowTypeStart:`none`,arrowTypeEnd:`none`,labelpos:`c`,classes:`default relationship relationship-note`,style:[],cssCompiledStyles:co([]),animate:!1,look:e.look,thickness:`normal`,minlen:1,isUserDefinedId:!1});for(let e of a)e.wrappingWidth??=t.wrappingWidth,!e.isGroup&&!e.shape.startsWith(`usecaseActor`)&&(e.minWidth??=t.minNodeWidth),(e.shape===`usecaseEllipse`||e.shape===`usecaseBusiness`)&&(e.spreadPorts=!0);return{nodes:a,edges:o,config:e,type:`usecase`,layoutAlgorithm:`dagre`,direction:so(),nodeSpacing:t.nodeSpacing,rankSpacing:t.rankSpacing,actorFontSize:t.actorFontSize,actorFontFamily:t.actorFontFamily,actorFontWeight:t.actorFontWeight,usecaseFontSize:t.usecaseFontSize,usecaseFontFamily:t.usecaseFontFamily,usecaseFontWeight:t.usecaseFontWeight,diagramPadding:t.diagramPadding,useMaxWidth:t.useMaxWidth,markers:[`point`,`circle`,`cross`,`extension`]}},`getData`)};function bo(e,t,n){let r=[n];return r.index=t,r.input=e,r}n(bo,`customMatch`);var xo=n((e,t)=>{if(e[t]!==`"`||e[t+1]!=="`")return null;for(let n=t+2;n{if(e[t]!==`%`||e[t+1]!==`%`)return null;for(let n=t-1;n>=0;n--){let t=e[n];if(t===` +`||t===`\r`)break;if(t!==` `&&t!==` `)return null}let n=t+2;for(;n{for(let n=t-1;n>=0;n--){let t=e[n];if(t===` +`||t===`\r`)return!0;if(t!==` `&&t!==` `)return!1}return!0},`isIndentedLineStart`),wo=n((e,t,n)=>{if(!Co(e,t))return null;let r=n.exec(e.slice(t));return r?bo(e,t,r[0]):null},`matchAccessibilityLine`),To=n((e,t)=>{if(!Co(e,t))return null;let n=/^accDescr[\t ]*{/.exec(e.slice(t));if(!n)return null;let r=e.indexOf(`}`,t+n[0].length);return r===-1?null:bo(e,t,e.slice(t,r+1))},`matchAccDescrBlock`),Eo=n((e,t)=>{if(e[t]!==`{`)return null;let n=0,r=!1,i=!1;for(let a=t;a{let n=e.indexOf(`>>`,t);if(n===-1||/[\n\r]/.test(e.slice(t,n)))return null;let r=e.slice(t,n);return r.trim()?bo(e,t,r):null},`matchStereotypeText`),J=U({name:`LABEL_TEXT`,pattern:H.NA}),Oo=U({name:`WORD`,pattern:H.NA,categories:J}),ko=U({name:`NUMBER`,pattern:/(?:\d+\.\d+|\d+|\.\d+)(?:[A-Za-z]+)?/,categories:J}),Y=U({name:`IDENTIFIER`,pattern:/\w+/,longer_alt:ko,categories:Oo}),Ao=U({name:`HWS`,pattern:/[\t ]+/,group:H.SKIPPED}),jo=U({name:`MARKDOWN_STRING`,pattern:xo,start_chars_hint:[`"`],line_breaks:!0}),Mo=U({name:`UNCLOSED_MARKDOWN_STRING`,pattern:/"`[^]*/,line_breaks:!0}),No=U({name:`COMMENT`,pattern:So,start_chars_hint:[`%`],line_breaks:!1}),Po=U({name:`NEWLINE`,pattern:/\r\n|\n|\r/,line_breaks:!0}),Fo=U({name:`ACC_DESCR_BLOCK`,pattern:To,start_chars_hint:[`a`],line_breaks:!0}),Io=/^accTitle[\t ]*:[^\n\r]*/,Lo=/^accDescr[\t ]*:[^\n\r]*/,Ro=U({name:`ACC_TITLE_LINE`,pattern:n((e,t)=>wo(e,t,Io),`pattern`),start_chars_hint:[`a`],line_breaks:!1}),zo=U({name:`ACC_DESCR_LINE`,pattern:n((e,t)=>wo(e,t,Lo),`pattern`),start_chars_hint:[`a`],line_breaks:!1}),Bo=U({name:`JSON_DECLARATION_START`,pattern:/json[\t ]+\w+[\t ]*@[\t ]*(?={)/,push_mode:`jsonBody`}),Vo=U({name:`JSON_OBJECT_LITERAL`,pattern:Eo,start_chars_hint:[`{`],line_breaks:!0,pop_mode:!0}),Ho=U({name:`UNCLOSED_JSON_OBJECT_LITERAL`,pattern:/{[^]*/,line_breaks:!0,pop_mode:!0}),X=n((e,t)=>U({name:e,pattern:t,longer_alt:Y,categories:Oo}),`keyword`),Uo=X(`USECASE`,/usecase-beta/),Wo=X(`ACTOR`,/actor/),Go=X(`SYSTEM_BOUNDARY`,/systemBoundary/),Ko=X(`END`,/end/),qo=X(`DIRECTION`,/direction/),Jo=X(`TD`,/TD/),Yo=X(`TB`,/TB/),Xo=X(`BT`,/BT/),Zo=X(`LR`,/LR/),Qo=X(`RL`,/RL/),$o=X(`NOTE`,/note/),es=X(`FOR`,/for/),ts=X(`JSON`,/json/),ns=X(`CLASS_DEF`,/classDef/),rs=X(`CLASS`,/class/),is=X(`STYLE`,/style/),as=X(`INCLUDE`,/include/i),os=X(`EXTEND`,/extend/i),ss=X(`TRUE`,/true/),cs=X(`FALSE`,/false/),ls=U({name:`GENERALIZATION`,pattern:/--\|>/}),us=U({name:`DEPENDENCY_ARROW`,pattern:/\.\.>/}),ds=U({name:`STEREOTYPE_START`,pattern:/<>/,pop_mode:!0}),ps=U({name:`STEREOTYPE_TEXT`,pattern:Do,line_breaks:!1}),ms=U({name:`UNCLOSED_STEREOTYPE_TEXT`,pattern:/[^\n\r]+/,line_breaks:!1,pop_mode:!0}),hs=U({name:`CLASS_SEPARATOR`,pattern:/:::/}),gs=U({name:`FORWARD_SOLID`,pattern:/--+>/}),_s=U({name:`BACKWARD_SOLID`,pattern:/<--+/}),vs=U({name:`FORWARD_CIRCLE`,pattern:/--o/}),ys=U({name:`BACKWARD_CIRCLE`,pattern:/o--/}),bs=U({name:`FORWARD_CROSS`,pattern:/--x/}),xs=U({name:`BACKWARD_CROSS`,pattern:/x--/}),Z=U({name:`MARKERLESS_SOLID`,pattern:/--+/}),Ss=U({name:`METADATA_START`,pattern:/@{/}),Cs=U({name:`AT`,pattern:/@/,categories:J}),ws=U({name:`LBRACE`,pattern:/{/}),Ts=U({name:`RBRACE`,pattern:/}/}),Es=U({name:`LBRACKET`,pattern:/\[/}),Ds=U({name:`RBRACKET`,pattern:/]/}),Os=U({name:`LPAREN`,pattern:/\(/}),ks=U({name:`RPAREN`,pattern:/\)/}),As=U({name:`COMMA`,pattern:/,/,categories:J}),js=U({name:`COLON`,pattern:/:/,categories:J}),Ms=U({name:`HASH_COLOR`,pattern:/#[\dA-Fa-f]+/,categories:J}),Ns=U({name:`PLAIN_STRING`,pattern:/"[^\n\r"]*"|'[^\n\r']*'/}),Ps=U({name:`CSS_IDENTIFIER`,pattern:/--[A-Z_a-z][\w-]*|[A-Z_a-z]\w*(?:-\w+)+/,categories:J}),Fs=U({name:`CSS_ESCAPED_COMMA`,pattern:/\\,/,categories:J}),Is=U({name:`DASH`,pattern:/-/,categories:J}),Ls=U({name:`DOT`,pattern:/\./,categories:J}),Rs=U({name:`PERCENT`,pattern:/%/,categories:J}),zs=U({name:`CSS_PUNCTUATION`,pattern:/[!#$&*+/=?^_|~]/,categories:J}),Bs=[J,Oo,Ao,jo,Mo,No,Po,Fo,Ro,zo,Bo,Uo,Wo,Go,Ko,qo,Jo,Yo,Xo,Zo,Qo,$o,es,ts,ns,rs,is,as,os,ss,cs,ls,us,ds,hs,gs,_s,vs,ys,bs,xs,Z,Ss,Cs,ws,Ts,Es,Ds,Os,ks,As,js,Ms,Ns,Ps,Y,ko,Fs,Is,Ls,Rs,zs,U({name:`LABEL_PUNCTUATION`,pattern:/[;<>\\`]/,categories:J}),U({name:`LABEL_SYMBOL`,pattern:/[^\t\n\r !-~]+/,categories:J})],Vs={defaultMode:`defaultMode`,modes:{defaultMode:[...Bs],jsonBody:[Vo,Ho],stereotype:[fs,ps,ms]}},Hs=[...Bs,Vo,Ho,fs,ps,ms],Us=new H(Vs),Ws=n(e=>Pr(e,J)||e.tokenType===Ns||e.tokenType===jo,`isLabelToken`),Gs={allowmixing:!0,newpage:!0,package:!0,rectangle:!0,skinparam:!0},Ks=new class extends Ra{static{n(this,`UsecaseParser`)}constructor(){super(Hs,{nodeLocationTracking:`full`}),this.RULE(`start`,()=>{this.CONSUME(Uo),this.SUBRULE(this.lineEnd),this.MANY(()=>this.SUBRULE(this.line))}),this.RULE(`line`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.blankLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.commentLine),`ALT`)},{GATE:n(()=>this.isStatementStart(),`GATE`),ALT:n(()=>this.SUBRULE(this.statement),`ALT`)}])}),this.RULE(`statement`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.accTitleStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.accDescrStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.directionStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.actorStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.systemBoundaryStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.noteStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.jsonStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.classDefStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.classStatement),`ALT`)},{ALT:n(()=>this.SUBRULE(this.styleStatement),`ALT`)},{GATE:n(()=>this.isMetadataAssignment(),`GATE`),ALT:n(()=>this.SUBRULE(this.metadataAssignmentStatement),`ALT`)},{GATE:n(()=>!this.isForbiddenPlantUmlStatement(),`GATE`),ALT:n(()=>this.SUBRULE(this.entityStatement),`ALT`)}])}),this.RULE(`lineEnd`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Po),`ALT`)},{ALT:n(()=>this.CONSUME(Mr),`ALT`)}])}),this.RULE(`blankLine`,()=>{this.CONSUME(Po)}),this.RULE(`commentLine`,()=>{this.CONSUME(No),this.SUBRULE(this.lineEnd)}),this.RULE(`accTitleStatement`,()=>{this.CONSUME(Ro),this.SUBRULE(this.lineEnd)}),this.RULE(`accDescrStatement`,()=>{this.OR([{ALT:n(()=>this.CONSUME(zo),`ALT`)},{ALT:n(()=>this.CONSUME(Fo),`ALT`)}]),this.SUBRULE(this.lineEnd)}),this.RULE(`actorStatement`,()=>{this.CONSUME(Wo),this.SUBRULE(this.actorItem),this.OPTION(()=>{this.OR([{ALT:n(()=>this.AT_LEAST_ONE(()=>{this.CONSUME(As),this.SUBRULE2(this.actorItem)}),`ALT`)},{ALT:n(()=>this.SUBRULE(this.relationTail),`ALT`)}])}),this.SUBRULE(this.lineEnd)}),this.RULE(`actorItem`,()=>{this.SUBRULE(this.actorName),this.OPTION(()=>this.SUBRULE(this.metadata)),this.OPTION2(()=>this.SUBRULE(this.stereotype)),this.OPTION3(()=>this.SUBRULE(this.classSuffix))}),this.RULE(`actorName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`actorDeclarationOnly`,()=>{this.CONSUME(Wo),this.SUBRULE(this.actorItem),this.MANY(()=>{this.CONSUME(As),this.SUBRULE2(this.actorItem)}),this.SUBRULE(this.lineEnd)}),this.RULE(`entityStatement`,()=>{this.SUBRULE(this.entityName),this.OPTION(()=>this.SUBRULE(this.relationTail)),this.SUBRULE(this.lineEnd)}),this.RULE(`entityName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.OR2([{ALT:n(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)},`ALT`)},{ALT:n(()=>{this.CONSUME(Es),this.SUBRULE2(this.nodeLabel),this.CONSUME(Ds)},`ALT`)}])})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}]),this.OPTION2(()=>this.SUBRULE(this.useCaseMetadata)),this.OPTION3(()=>this.SUBRULE(this.stereotype)),this.OPTION4(()=>this.SUBRULE(this.classSuffix))}),this.RULE(`nodeLabel`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)},{ALT:n(()=>this.AT_LEAST_ONE(()=>this.CONSUME(J)),`ALT`)}])}),this.RULE(`useCaseMetadata`,()=>{this.SUBRULE(this.metadata)}),this.RULE(`relationTail`,()=>{this.OPTION({GATE:n(()=>this.LA(1).tokenType===Y&&this.LA(2).tokenType===Cs,`GATE`),DEF:n(()=>{this.CONSUME(Y),this.CONSUME(Cs)},`DEF`)}),this.SUBRULE(this.arrow),this.SUBRULE(this.entityName)}),this.RULE(`arrow`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.semanticRelation),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.markerlessSolidOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardCircleOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardCircleOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.forwardCrossOperator),`ALT`)},{ALT:n(()=>this.SUBRULE(this.backwardCrossOperator),`ALT`)}])}),this.RULE(`forwardSolidOperator`,()=>{this.CONSUME(gs)}),this.RULE(`backwardSolidOperator`,()=>{this.CONSUME(_s),this.OPTION({GATE:n(()=>this.LA(0).image===`<--`&&this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`markerlessSolidOperator`,()=>{this.CONSUME(Z),this.OPTION({GATE:n(()=>this.LA(0).image===`--`&&this.hasLabeledRight([gs,Z,vs,bs]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.OR([{ALT:n(()=>this.CONSUME(gs),`ALT`)},{ALT:n(()=>this.CONSUME2(Z),`ALT`)},{ALT:n(()=>this.CONSUME(vs),`ALT`)},{ALT:n(()=>this.CONSUME(bs),`ALT`)}])},`DEF`)})}),this.RULE(`forwardCircleOperator`,()=>{this.CONSUME(vs)}),this.RULE(`backwardCircleOperator`,()=>{this.CONSUME(ys),this.OPTION({GATE:n(()=>this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`forwardCrossOperator`,()=>{this.CONSUME(bs)}),this.RULE(`backwardCrossOperator`,()=>{this.CONSUME(xs),this.OPTION({GATE:n(()=>this.hasLabeledRight([Z]),`GATE`),DEF:n(()=>{this.SUBRULE(this.edgeLabel),this.CONSUME(Z)},`DEF`)})}),this.RULE(`edgeLabel`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)},{ALT:n(()=>this.AT_LEAST_ONE(()=>this.CONSUME(J)),`ALT`)}])}),this.RULE(`semanticRelation`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(us),this.CONSUME(js),this.OR2([{ALT:n(()=>this.CONSUME(as),`ALT`)},{ALT:n(()=>this.CONSUME(os),`ALT`)}])},`ALT`)},{ALT:n(()=>this.CONSUME(ls),`ALT`)}])}),this.RULE(`metadata`,()=>{this.CONSUME(Ss),this.MANY(()=>this.CONSUME(Po)),this.OPTION(()=>{this.SUBRULE(this.metadataProperty),this.MANY2(()=>{this.SUBRULE(this.metadataSeparator),this.SUBRULE2(this.metadataProperty)}),this.OPTION2(()=>this.CONSUME(As)),this.MANY3(()=>this.CONSUME2(Po))}),this.CONSUME(Ts)}),this.RULE(`metadataProperty`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Y),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)}]),this.CONSUME(js),this.OR2([{ALT:n(()=>this.CONSUME2(Y),`ALT`)},{ALT:n(()=>this.CONSUME2(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(ss),`ALT`)},{ALT:n(()=>this.CONSUME(cs),`ALT`)}])}),this.RULE(`metadataSeparator`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(As),this.MANY(()=>this.CONSUME(Po))},`ALT`)},{ALT:n(()=>{this.AT_LEAST_ONE(()=>this.CONSUME2(Po)),this.OPTION(()=>this.CONSUME2(As)),this.MANY2(()=>this.CONSUME3(Po))},`ALT`)}])}),this.RULE(`systemBoundaryStatement`,()=>{this.CONSUME(Go),this.SUBRULE(this.systemBoundaryName),this.OPTION(()=>this.SUBRULE(this.metadata)),this.OPTION2(()=>this.SUBRULE(this.classSuffix)),this.SUBRULE(this.lineEnd),this.SUBRULE(this.systemBoundaryContent),this.CONSUME(Ko),this.SUBRULE2(this.lineEnd)}),this.RULE(`systemBoundaryName`,()=>{this.OR([{ALT:n(()=>{this.CONSUME(Y),this.OPTION(()=>{this.OR2([{ALT:n(()=>{this.CONSUME(Os),this.SUBRULE(this.nodeLabel),this.CONSUME(ks)},`ALT`)},{ALT:n(()=>{this.CONSUME(Es),this.SUBRULE2(this.nodeLabel),this.CONSUME(Ds)},`ALT`)}])})},`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`systemBoundaryContent`,()=>{this.MANY(()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.blankLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.commentLine),`ALT`)},{ALT:n(()=>this.SUBRULE(this.boundaryElement),`ALT`)}])})}),this.RULE(`boundaryElement`,()=>{this.OR([{ALT:n(()=>this.SUBRULE(this.actorDeclarationOnly),`ALT`)},{ALT:n(()=>{this.SUBRULE(this.entityName),this.SUBRULE(this.lineEnd)},`ALT`)}])}),this.RULE(`metadataAssignmentStatement`,()=>{this.SUBRULE(this.metadataAssignmentTarget),this.SUBRULE(this.metadata),this.SUBRULE(this.lineEnd)}),this.RULE(`metadataAssignmentTarget`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Y),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(jo),`ALT`)}])}),this.RULE(`noteStatement`,()=>{this.CONSUME($o),this.CONSUME(es),this.CONSUME(Y),this.SUBRULE(this.nodeLabel),this.SUBRULE(this.lineEnd)}),this.RULE(`stereotype`,()=>{this.CONSUME(ds),this.CONSUME(ps),this.CONSUME(fs)}),this.RULE(`classSuffix`,()=>{this.CONSUME(hs),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)})}),this.RULE(`jsonStatement`,()=>{this.CONSUME(Bo),this.CONSUME(Vo),this.OPTION(()=>this.SUBRULE(this.classSuffix)),this.SUBRULE(this.lineEnd)}),this.RULE(`directionStatement`,()=>{this.CONSUME(qo),this.OR([{ALT:n(()=>this.CONSUME(Jo),`ALT`)},{ALT:n(()=>this.CONSUME(Yo),`ALT`)},{ALT:n(()=>this.CONSUME(Xo),`ALT`)},{ALT:n(()=>this.CONSUME(Zo),`ALT`)},{ALT:n(()=>this.CONSUME(Qo),`ALT`)}]),this.SUBRULE(this.lineEnd)}),this.RULE(`classDefStatement`,()=>{this.CONSUME(ns),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)}),this.SUBRULE(this.styles),this.SUBRULE(this.lineEnd)}),this.RULE(`classStatement`,()=>{this.CONSUME(rs),this.CONSUME(Y),this.MANY(()=>{this.CONSUME(As),this.CONSUME2(Y)}),this.CONSUME3(Y),this.MANY2(()=>{this.CONSUME2(As),this.CONSUME4(Y)}),this.SUBRULE(this.lineEnd)}),this.RULE(`styleStatement`,()=>{this.CONSUME(is),this.CONSUME(Y),this.SUBRULE(this.styles),this.SUBRULE(this.lineEnd)}),this.RULE(`styles`,()=>{this.SUBRULE(this.styleValue),this.MANY(()=>{this.CONSUME(As),this.SUBRULE2(this.styleValue)})}),this.RULE(`styleValue`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Oo),`ALT`)},{ALT:n(()=>this.CONSUME(Ps),`ALT`)},{ALT:n(()=>{this.CONSUME(Z),this.CONSUME2(Oo)},`ALT`)}]),this.CONSUME(js),this.AT_LEAST_ONE(()=>this.SUBRULE(this.styleComponent))}),this.RULE(`styleComponent`,()=>{this.OR([{ALT:n(()=>this.CONSUME(Oo),`ALT`)},{ALT:n(()=>this.CONSUME(Ns),`ALT`)},{ALT:n(()=>this.CONSUME(ko),`ALT`)},{ALT:n(()=>this.CONSUME(Ms),`ALT`)},{ALT:n(()=>this.CONSUME(Ps),`ALT`)},{ALT:n(()=>this.CONSUME(Fs),`ALT`)},{ALT:n(()=>this.CONSUME(Is),`ALT`)},{ALT:n(()=>this.CONSUME(Ls),`ALT`)},{ALT:n(()=>this.CONSUME(Rs),`ALT`)},{ALT:n(()=>this.CONSUME(zs),`ALT`)},{ALT:n(()=>this.CONSUME(js),`ALT`)},{ALT:n(()=>this.CONSUME(Os),`ALT`)},{ALT:n(()=>this.CONSUME(ks),`ALT`)},{ALT:n(()=>this.CONSUME(Es),`ALT`)},{ALT:n(()=>this.CONSUME(Ds),`ALT`)},{ALT:n(()=>this.CONSUME(ws),`ALT`)},{ALT:n(()=>this.CONSUME(Ts),`ALT`)},{ALT:n(()=>this.CONSUME(Cs),`ALT`)},{ALT:n(()=>this.CONSUME(Z),`ALT`)}])}),this.performSelfAnalysis()}isMetadataAssignment(){let e=this.LA(1).tokenType;return(e===Y||e===Ns||e===jo)&&this.LA(2).tokenType===Ss}isStatementStart(){let e=this.LA(1).tokenType;return e!==Mr&&e!==Po&&e!==No}isForbiddenPlantUmlStatement(){return this.LA(1).tokenType===Y&&Gs[this.LA(1).image.toLowerCase()]===!0}hasLabeledRight(e){if(!Ws(this.LA(1)))return!1;for(let t=2;;t++){let n=this.LA(t);if(e.includes(n.tokenType))return!0;if(!Ws(n))return!1}}},qs=class extends Error{constructor(e,t,n){super(`${e} (line ${t}, column ${n})`),this.line=t,this.column=n,this.name=`UsecaseJsonError`}static{n(this,`UsecaseJsonError`)}},Js=n((e,t,n,r)=>{let i=n,a=r,o=Math.min(Math.max(t,0),e.length);for(let t=0;t{let i=/\bposition (\d+)\b/u.exec(e);if(i)return Js(t,Number.parseInt(i[1],10),n,r);let a=/\bline (\d+) column (\d+)\b/u.exec(e);if(a){let e=Number.parseInt(a[1],10),t=Number.parseInt(a[2],10);return{line:n+e-1,column:e===1?r+t-1:t}}if(/unexpected end|end of json input/iu.test(e))return Js(t,t.length,n,r)},`locationFromErrorMessage`),Q=class extends Error{constructor(e){super(`Invalid JSON token`),this.offset=e}static{n(this,`JsonWalkError`)}},Xs=class{constructor(e){this.text=e,this.offset=0,this.propertyOrder={}}static{n(this,`PropertyOrderCollector`)}collect(){if(this.skipWhitespace(),this.collectValue(``),this.skipWhitespace(),this.offset!==this.text.length)throw new Q(this.offset);return this.propertyOrder}collectValue(e){this.skipWhitespace();let t=this.text[this.offset];if(t===`{`)this.collectObject(e);else if(t===`[`)this.collectArray(e);else if(t===`"`)this.readString(!1);else if(t===`t`)this.consumeLiteral(`true`);else if(t===`f`)this.consumeLiteral(`false`);else if(t===`n`)this.consumeLiteral(`null`);else if(t===`-`||t>=`0`&&t<=`9`)this.consumeNumber();else throw new Q(this.offset)}collectObject(e){this.offset++;let t=[],n=new Set;if(this.propertyOrder[e]=t,this.skipWhitespace(),this.text[this.offset]===`}`){this.offset++;return}for(;this.offset=`1`&&this.text[this.offset]<=`9`)for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++;else throw new Q(this.offset);if(this.text[this.offset]===`.`){if(this.offset++,this.text[this.offset]<`0`||this.text[this.offset]>`9`)throw new Q(this.offset);for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++}if(this.text[this.offset]===`e`||this.text[this.offset]===`E`){if(this.offset++,(this.text[this.offset]===`+`||this.text[this.offset]===`-`)&&this.offset++,this.text[this.offset]<`0`||this.text[this.offset]>`9`)throw new Q(this.offset);for(;this.text[this.offset]>=`0`&&this.text[this.offset]<=`9`;)this.offset++}}skipWhitespace(){for(;this.offset({shape:e.type===`normal`?`actor`:e.type===`hollow`?`actor-hollow`:e.type===`awesome`?`actor-awesome`:`actor-icon`,...e.label===e.id?{}:{label:e.label},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`actor`,actorType:e.type,business:e.business,labelType:e.labelType,...e.icon?{icon:e.icon}:{},...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{}}}),`actorNode`),$s=n(e=>({shape:e.shape,...e.label===e.id?{}:{label:e.label},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`usecase`,useCaseShape:e.shape,business:e.business,labelType:e.labelType,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{}}}),`useCaseNode`),ec=n(e=>({label:e.label,shape:`note`,attrs:{kind:`note`,target:e.target,labelType:e.labelType}}),`noteNode`),tc=n(e=>({label:e.id,shape:`json-table`,...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{kind:`json`,value:e.value,propertyOrder:e.propertyOrder,labelType:`text`}}),`jsonNode`),nc=n(e=>({id:e.id,source:e.source,target:e.target,...e.label?{label:e.label}:{},...e.classes.length?{classes:[...e.classes]}:{},...e.styles.length?{styles:[...e.styles]}:{},attrs:{relationshipType:e.type,arrowType:e.arrowType,minlen:e.minlen,explicitId:e.explicitId,animate:e.animate,...e.animation?{animation:e.animation}:{},...e.labelType?{labelType:e.labelType}:{}}}),`relationshipEdge`),rc=n(e=>({id:`${e.id}-edge`,source:e.id,target:e.target,attrs:{relationshipType:`note`,arrowType:K.LINE_SOLID,pattern:`dotted`,minlen:1,explicitId:!1,animate:!1,internal:!0}}),`noteEdge`),ic=n((e,t,n,r)=>{let i={};for(let t of e.getActors().values())i[t.id]=Qs(t);for(let t of e.getUseCases().values())i[t.id]=$s(t);for(let t of e.getNotes().values())i[t.id]=ec(t);for(let t of e.getJsonNodes().values())i[t.id]=tc(t);let a={};for(let t of e.getSystemBoundaries().values())a[t.id]={...t.label===t.id?{}:{title:t.label},nodes:[...t.members],...t.classes.length?{classes:[...t.classes]}:{},...t.styles.length?{styles:[...t.styles]}:{},attrs:{kind:`systemBoundary`,boundaryType:t.type,labelType:t.labelType}};let o={};for(let t of e.getClassDefs().values())o[t.id]={styles:[...t.styles]};let s=e.getDirection();return{version:1,diagramType:`usecase`,source:t,header:{keyword:`usecase`,direction:s===`TD`?`TB`:s,span:n},...e.getAccTitle()?{accTitle:e.getAccTitle()}:{},...e.getAccDescription()?{accDescr:e.getAccDescription()}:{},nodes:i,edges:[...e.getRelationships().map(nc),...[...e.getNotes().values()].map(rc)],groups:a,classDefs:o,statements:r}},`buildUsecaseGraphAST`),$=n(e=>`line ${e.line}, column ${e.column} [${e.span[0]},${e.span[1]})`,`locationText`),ac=n(e=>e===void 0?``:` (label "${e}")`,`labelSuffix`),oc=n(e=>e.generated?e.label:void 0,`generatedFrom`),sc=n((e,t)=>{for(let n of t)e.includes(n)||e.push(n)},`pushUnique`),cc=class{constructor(e){this.db=e,this.source=``,this.statements=[],this.elements=[],this.boundaries=[],this.jsonDrafts=[],this.relationshipDrafts=[],this.noteDrafts=[],this.metadataAssignments=[],this.classAssignments=[],this.styleAssignments=[],this.classDefinitions=[],this.directions=[],this.model=e.createModel()}static{n(this,`UsecaseModelBuilder`)}reset(e){this.model=this.db.createModel(),this.source=e,this.statements=[],this.elements.length=0,this.boundaries.length=0,this.jsonDrafts.length=0,this.relationshipDrafts.length=0,this.noteDrafts.length=0,this.metadataAssignments.length=0,this.classAssignments.length=0,this.styleAssignments.length=0,this.classDefinitions.length=0,this.directions.length=0}addElement(e){this.elements.push(e)}addBoundary(e){this.boundaries.push(e)}addJson(e){this.jsonDrafts.push(e)}addRelationship(e){this.relationshipDrafts.push(e)}addNote(e){this.noteDrafts.push(e)}addMetadataAssignment(e,t,n,r){this.metadataAssignments.push({target:e,targetLocation:t,metadata:n,statement:r})}addClassDef(e,t){this.classDefinitions.push({ids:e,styles:t})}addClassAssignment(e,t){this.classAssignments.push({targets:e,classes:t})}addStyleAssignment(e,t,n){this.styleAssignments.push({target:e,location:t,styles:n})}setDirection(e){this.directions.push(e===`TD`?`TB`:e)}setAccTitle(e){this.model.accTitle=e}setAccDescription(e){this.model.accDescription=e}setStatements(e){this.statements=e}getActors(){return this.model.actors}getUseCases(){return this.model.useCases}getSystemBoundaries(){return this.model.systemBoundaries}getRelationships(){return this.model.relationships}getNotes(){return this.model.notes}getJsonNodes(){return this.model.jsonNodes}getClassDefs(){return this.model.classDefs}getDirection(){return this.model.direction}getAccTitle(){return this.model.accTitle}getAccDescription(){return this.model.accDescription}finalize(e){let t=new Map,n=new Map,r=new Map,i=new Map;for(let e of this.relationshipDrafts)this.recordFirst(i,e.source.id,e.source.location.span[0]),this.recordFirst(i,e.target.id,e.target.location.span[0]);for(let e of this.elements)this.recordFirst(i,e.id,e.location.span[0]);for(let e of this.boundaries)this.recordFirst(i,e.id,e.location.span[0]);for(let e of this.jsonDrafts)this.recordFirst(i,e.id,e.location.span[0]);let a=[...this.elements.map(e=>({offset:e.location.span[0],type:`element`,value:e})),...this.boundaries.map(e=>({offset:e.location.span[0],type:`boundary`,value:e})),...this.jsonDrafts.map(e=>({offset:e.location.span[0],type:`json`,value:e})),...this.relationshipDrafts.filter(e=>e.explicitId).map(e=>({offset:e.explicitIdLocation.span[0],type:`edge`,value:e}))].sort((e,t)=>e.offset-t.offset);for(let e of a)e.type===`element`?this.collectElement(e.value,t,n):e.type===`boundary`?this.collectBoundary(e.value,t,r):e.type===`json`?this.registerUnique(t,e.value.id,`json`,e.value.location,!1):this.registerUnique(t,e.value.explicitId,`edge`,e.value.explicitIdLocation,!1);this.materializeElements(n,i),this.materializeBoundaries(r,i),this.materializeJson(i);let o=this.materializeRelationships(t,n,i);this.reorderElements(n,i),this.applyMetadataAssignments(t,n,r,o),this.validateAndRefreshElements(n),this.refreshBoundaries(r,n),this.materializeNotes(t),this.applyClassDefinitions(),this.applyClassesAndStyles(t,o),this.model.direction=this.directions.at(-1)??this.model.direction,this.model.symbols=new Map([...t].map(([e,t])=>[e,t.kind]));let s=ic(this,this.source,e,this.statements);return this.model.ast=s,this.db.commit(this.model),s}collectElement(e,t,n){let r=t.get(e.id),i=oc({generated:e.generated,label:e.label.text});r&&r.kind!==e.kind&&this.conflict(`ID '${e.id}' is declared as both ${r.kind} and ${e.kind}`,e.location,r.location,i,oc(r)),r&&(r.generated||e.generated)&&this.conflict(`Generated ID '${e.id}' collides with another declaration`,e.location,r.location,i,oc(r));let a=n.get(e.id);if(!a){let r={kind:e.kind,id:e.id,label:e.label,location:e.location,generated:e.generated,classes:[...e.classes],...e.parentId?{parentId:e.parentId,parentLocation:e.parentLocation}:{},...e.shape?{shape:e.shape}:{},...e.stereotype?{stereotype:e.stereotype,stereotypeLocation:e.location}:{}};this.applyDeclarationMetadata(r,e.metadata),n.set(e.id,r),t.set(e.id,{kind:e.kind,location:e.location,generated:e.generated,label:e.label.text});return}(a.label.text!==e.label.text||a.label.type!==e.label.type)&&this.conflict(`ID '${e.id}' has conflicting labels`,e.location,a.location),e.shape&&a.shape&&e.shape!==a.shape&&this.conflict(`Use case '${e.id}' has conflicting shapes`,e.location,a.location),e.parentId&&a.parentId&&e.parentId!==a.parentId&&this.conflict(`Element '${e.id}' belongs to more than one system boundary`,e.parentLocation??e.location,a.parentLocation??a.location),e.stereotype&&a.stereotype&&e.stereotype!==a.stereotype&&this.conflict(`Element '${e.id}' has conflicting stereotypes`,e.location,a.stereotypeLocation??a.location),a.shape??=e.shape,a.parentId??=e.parentId,a.parentLocation??=e.parentLocation,a.stereotype??=e.stereotype,a.stereotypeLocation??=e.stereotype?e.location:void 0,sc(a.classes,e.classes),this.applyDeclarationMetadata(a,e.metadata)}collectBoundary(e,t,n){let r=t.get(e.id),i=oc({generated:e.generated,label:e.label.text});r&&r.kind!==`boundary`&&this.conflict(`ID '${e.id}' is declared as both ${r.kind} and boundary`,e.location,r.location,i,oc(r)),r&&(r.generated||e.generated)&&this.conflict(`Generated ID '${e.id}' collides with another declaration`,e.location,r.location,i,oc(r));let a=n.get(e.id);if(a){(a.label.text!==e.label.text||a.label.type!==e.label.type)&&this.conflict(`Boundary '${e.id}' has conflicting titles`,e.location,a.location),sc(a.classes,e.classes);return}n.set(e.id,{id:e.id,label:e.label,location:e.location,generated:e.generated,classes:[...e.classes],styles:[],members:[]}),t.set(e.id,{kind:`boundary`,location:e.location,generated:e.generated,label:e.label.text})}materializeElements(e,t){for(let n of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0)))this.setElementModel(n)}materializeBoundaries(e,t){for(let n of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0)))this.model.systemBoundaries.set(n.id,{id:n.id,label:n.label.text,labelType:n.label.type,type:n.type??`rect`,members:[],classes:[...n.classes],styles:[...n.styles]})}materializeJson(e){for(let t of[...this.jsonDrafts].sort((t,n)=>(e.get(t.id)??0)-(e.get(n.id)??0)))this.model.jsonNodes.set(t.id,{id:t.id,value:t.value,propertyOrder:t.propertyOrder,classes:[...t.classes],styles:[]})}materializeRelationships(e,t,n){let r=new Map,i=0;for(let a of this.relationshipDrafts){let o=this.resolveEndpoint(a.source,e,t,n),s=this.resolveEndpoint(a.target,e,t,n);this.validateRelationship(a,o,s,e);let c=a.explicitId??`edge-${i++}`,l={id:c,explicitId:!!a.explicitId,source:a.source.id,target:a.target.id,type:a.type,arrowType:a.arrowType,...a.label?{label:a.label.text,labelType:a.label.type}:{},minlen:a.minlen,classes:[],styles:[],animate:!1};this.model.relationships.push(l),r.set(c,{draft:a,relationship:l})}return this.model.relationshipCounter=i,r}resolveEndpoint(e,t,n,r){if(e.classesOnReference&&!e.declaration)throw Error(`Relationship endpoint '${e.id}' uses ::: without declaring the node at ${$(e.location)}`);let i=t.get(e.id);return i?i.kind:(n.set(e.id,{kind:`usecase`,id:e.id,label:e.label,location:e.location,generated:e.generated,shape:`ellipse`,classes:[]}),t.set(e.id,{kind:`usecase`,location:e.location,generated:e.generated,label:e.label.text}),this.recordFirst(r,e.id,e.location.span[0]),`usecase`)}reorderElements(e,t){let n=new Map(this.model.actors),r=new Map(this.model.useCases);this.model.actors.clear(),this.model.useCases.clear();for(let i of[...e.values()].sort((e,n)=>(t.get(e.id)??0)-(t.get(n.id)??0))){!n.has(i.id)&&!r.has(i.id)&&this.setElementModel(i);let e=n.get(i.id)??this.model.actors.get(i.id),t=r.get(i.id)??this.model.useCases.get(i.id);e?this.model.actors.set(i.id,e):t&&this.model.useCases.set(i.id,t)}}applyMetadataAssignments(e,t,n,r){for(let i of this.metadataAssignments){let a=e.get(i.target);if(!a){let e=this.inferMetadataKind(i.metadata);throw Error(`Metadata target '${i.target}' is unresolved${e?` (metadata implies ${e})`:``} at ${$(i.targetLocation)}`)}if(a.kind===`actor`||a.kind===`usecase`)this.applyStandaloneElementMetadata(t.get(i.target),i.metadata);else if(a.kind===`boundary`){let e=n.get(i.target);for(let t of i.metadata.properties)(t.key!==`type`||t.value!==`rect`&&t.value!==`package`)&&this.invalidMetadata(i.target,a.kind,t),e.type=t.value}else if(a.kind===`edge`){let e=r.get(i.target);if(!e)throw Error(`Metadata target '${i.target}' is not an explicit edge at ${$(i.targetLocation)}`);i.statement.kind=`edgeMetadata`,i.statement.edges=[{id:i.target,span:i.statement.span,idSpan:i.targetLocation.span,...i.statement.metadata?{metadata:i.statement.metadata}:{}}],delete i.statement.nodes;for(let t of i.metadata.properties)t.key===`animate`&&typeof t.value==`boolean`?e.relationship.animate=t.value:t.key===`animation`&&(t.value===`fast`||t.value===`slow`)?(e.relationship.animation=t.value,e.relationship.animate=!0):this.invalidMetadata(i.target,a.kind,t)}else for(let e of i.metadata.properties)this.invalidMetadata(i.target,a.kind,e)}for(let{relationship:e}of r.values())e.animation&&(e.animate=!0)}applyStandaloneElementMetadata(e,t){for(let n of t.properties)e.kind===`actor`?this.applyActorProperty(e,n,!0):n.key===`business`&&typeof n.value==`boolean`?e.business=n.value:this.invalidMetadata(e.id,e.kind,n)}applyDeclarationMetadata(e,t){if(t)for(let n of t.properties)e.kind===`actor`?this.applyActorProperty(e,n,!1):n.key===`business`&&typeof n.value==`boolean`?(e.business!==void 0&&e.business!==n.value&&this.conflict(`Use case '${e.id}' has conflicting business metadata`,n.location,e.location),e.business=n.value):this.invalidMetadata(e.id,e.kind,n)}applyActorProperty(e,t,n){t.key===`type`&&(t.value===`normal`||t.value===`hollow`||t.value===`awesome`)?(!n&&e.actorType!==void 0&&e.actorType!==t.value&&this.conflict(`Actor '${e.id}' has conflicting type metadata`,t.location,e.location),e.actorType=t.value):t.key===`icon`&&typeof t.value==`string`?(!n&&e.icon!==void 0&&e.icon!==t.value&&this.conflict(`Actor '${e.id}' has conflicting icon metadata`,t.location,e.location),e.icon=t.value):t.key===`business`&&typeof t.value==`boolean`?(!n&&e.business!==void 0&&e.business!==t.value&&this.conflict(`Actor '${e.id}' has conflicting business metadata`,t.location,e.location),e.business=t.value):this.invalidMetadata(e.id,e.kind,t)}validateAndRefreshElements(e){for(let t of e.values()){let e=t.icon?`icon`:t.actorType??`normal`;if(t.kind===`actor`){if(t.icon&&t.actorType&&t.actorType!==`normal`)throw Error(`Actor '${t.id}' cannot combine icon with type '${t.actorType}' at ${$(t.location)}`);if(t.business&&(e===`icon`||e===`awesome`))throw Error(`Business actor '${t.id}' must use normal or hollow geometry at ${$(t.location)}`)}else if((t.shape??`ellipse`)===`rect`&&t.business)throw Error(`Rectangular use case '${t.id}' cannot be a business use case at ${$(t.location)}`);this.setElementModel(t)}}refreshBoundaries(e,t){for(let t of e.values())t.members.length=0;for(let t of[...this.elements].sort((e,t)=>e.location.span[0]-t.location.span[0])){if(!t.parentId)continue;let n=e.get(t.parentId);if(!n)throw Error(`Parent boundary '${t.parentId}' for '${t.id}' is unresolved at ${$(t.parentLocation??t.location)}`);n.members.includes(t.id)||n.members.push(t.id)}for(let n of t.values())if(n.parentId&&!e.has(n.parentId))throw Error(`Parent boundary '${n.parentId}' for '${n.id}' is unresolved at ${$(n.parentLocation??n.location)}`);for(let t of e.values()){let e=this.model.systemBoundaries.get(t.id);e.type=t.type??`rect`,e.members=[...t.members],e.classes=[...t.classes],e.styles=[...t.styles]}}materializeNotes(e){let t=0;for(let n of this.noteDrafts){let r=e.get(n.target);if(!r)throw Error(`Note target '${n.target}' is unresolved at ${$(n.targetLocation)}`);r.kind!==`actor`&&r.kind!==`usecase`&&this.conflict(`Note target '${n.target}' must be an actor or use case, not ${r.kind}`,n.targetLocation,r.location);let i=`note-${t++}`;this.model.notes.set(i,{id:i,target:n.target,label:n.label.text,labelType:n.label.type})}this.model.noteCounter=t}applyClassDefinitions(){for(let e of this.classDefinitions)for(let t of e.ids)this.model.classDefs.set(t,{id:t,styles:[...e.styles]})}applyClassesAndStyles(e,t){for(let n of this.classAssignments)for(let r of n.targets)sc(this.getStylable(r.id,e,t,r.location).classes,n.classes);for(let n of this.styleAssignments)this.getStylable(n.target,e,t,n.location).styles.push(...n.styles)}getStylable(e,t,n,r){let i=t.get(e)?.kind,a=i===`actor`?this.model.actors.get(e):i===`usecase`?this.model.useCases.get(e):i===`boundary`?this.model.systemBoundaries.get(e):i===`json`?this.model.jsonNodes.get(e):i===`edge`?n.get(e)?.relationship:void 0;if(!a)throw Error(`Class/style target '${e}' is unresolved or anonymous at ${$(r)}`);return a}validateRelationship(e,t,r,i){let a=n(e=>e===`actor`||e===`usecase`||e===`json`,`allowed`);if(a(t)||this.conflict(`Relationship source '${e.source.id}' cannot be ${t}`,e.source.location,i.get(e.source.id).location),a(r)||this.conflict(`Relationship target '${e.target.id}' cannot be ${r}`,e.target.location,i.get(e.target.id).location),(e.type===`include`||e.type===`extend`)&&(t!==`usecase`||r!==`usecase`))throw Error(`${e.type} relationship requires use-case endpoints at ${$(e.location)}`);if(e.type===`generalization`&&(t!==`actor`&&t!==`usecase`||t!==r))throw Error(`Generalization requires actor-to-actor or use-case-to-use-case endpoints at ${$(e.location)}`);if(e.type===`association`&&(t===`json`||r===`json`)&&![0,1,2].includes(e.arrowType))throw Error(`JSON relationship '${e.source.id}' to '${e.target.id}' permits only point, reversed-point, or markerless solid association at ${$(e.location)}`)}setElementModel(e){if(e.kind===`actor`){let t=e.icon?`icon`:e.actorType??`normal`;this.model.useCases.delete(e.id),this.model.actors.set(e.id,{id:e.id,label:e.label.text,labelType:e.label.type,type:t,...e.icon?{icon:e.icon}:{},business:e.business??!1,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{},classes:[...e.classes],styles:this.model.actors.get(e.id)?.styles??[]})}else this.model.actors.delete(e.id),this.model.useCases.set(e.id,{id:e.id,label:e.label.text,labelType:e.label.type,shape:e.shape??`ellipse`,business:e.business??!1,...e.stereotype?{stereotype:e.stereotype}:{},...e.parentId?{parentId:e.parentId}:{},classes:[...e.classes],styles:this.model.useCases.get(e.id)?.styles??[]})}inferMetadataKind(e){let t=new Set([`actor`,`usecase`,`boundary`,`edge`]);for(let n of e.properties)if(n.key===`icon`)t.clear(),t.add(`actor`);else if(n.key===`animate`||n.key===`animation`)t.clear(),t.add(`edge`);else if(n.key===`type`)t.clear(),n.value===`rect`||n.value===`package`?t.add(`boundary`):(n.value===`normal`||n.value===`hollow`||n.value===`awesome`)&&t.add(`actor`);else if(n.key===`business`)t.delete(`boundary`),t.delete(`edge`);else return;return t.size===1?[...t][0]:void 0}invalidMetadata(e,t,n){throw Error(`Metadata property '${n.key}' is invalid for ${t} '${e}' at ${$(n.location)}`)}registerUnique(e,t,n,r,i){let a=e.get(t);a&&this.conflict(`ID '${t}' is declared more than once (${a.kind} and ${n})`,r,a.location,void 0,oc(a)),e.set(t,{kind:n,location:r,generated:i})}recordFirst(e,t,n){let r=e.get(t);(r===void 0||nthis.visit(e)),r=this.nodes(e,`relationTail`)[0],i=n.map((e,n)=>this.actorOccurrence(t[n],e,!0));for(let e of n)this.builder.addElement(this.actorDraft(e));if(!r)return{kind:`node`,span:[0,0],nodes:i};let a=this.visit(r);a.target.explicitDeclaration&&this.builder.addElement(this.entityDraft(a.target));let o=this.relationshipDraft(n[0],a,this.nodeLocation(r));this.builder.addRelationship(o);let s=o.explicitId??`edge-${this.anonymousEdge++}`;return i.push(this.entityOccurrence(this.nodes(r.children,`entityName`)[0],a.target,a.target.explicitDeclaration)),{kind:`edge`,span:[0,0],nodes:i,edges:[{id:s,span:[0,0],...o.explicitIdLocation?{idSpan:o.explicitIdLocation.span}:{},...o.label?{labelSpan:o.label.span}:{}}]}}actorItem(e){let t=this.visit(this.nodes(e,`actorName`)[0]),n=this.nodes(e,`metadata`)[0],r=this.nodes(e,`stereotype`)[0],i=this.nodes(e,`classSuffix`)[0],a=i?this.visit(i):{classes:[],spans:[]};return{...t,...n?{metadata:this.visit(n)}:{},...r?{stereotype:this.visit(r)}:{},classes:a.classes,classSpans:a.spans}}actorName(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0];if(t){let n=this.nodes(e,`nodeLabel`)[0],r=n?this.visit(n):this.tokenLabel(t);return{id:t.image,label:r,location:this.tokenLocation(t),generated:!1,classes:[],classSpans:[]}}let r=this.tokenLabel(n);return{id:this.generateId(r.text),label:r,location:this.tokenLocation(n),generated:!0,classes:[],classSpans:[]}}actorDeclarationOnly(e){let t=this.nodes(e,`actorItem`),n=t.map(e=>this.visit(e));for(let e of n)this.builder.addElement(this.actorDraft(e));return{kind:`node`,span:[0,0],nodes:n.map((e,n)=>this.actorOccurrence(t[n],e,!0))}}entityStatement(e){let t=this.nodes(e,`entityName`),n=this.visit(t[0]),r=this.nodes(e,`relationTail`)[0];if(!r)return n.explicitDeclaration=!0,n.shape??=`ellipse`,this.builder.addElement(this.entityDraft(n)),{kind:`node`,span:[0,0],nodes:[this.entityOccurrence(t[0],n,!0)]};n.explicitDeclaration&&this.builder.addElement(this.entityDraft(n));let i=this.visit(r);i.target.explicitDeclaration&&this.builder.addElement(this.entityDraft(i.target));let a={source:this.endpoint(n),target:this.endpoint(i.target),location:this.nodeLocation(r),...i.explicitId?{explicitId:i.explicitId,explicitIdLocation:i.explicitIdLocation}:{},...i.arrow};this.builder.addRelationship(a);let o=a.explicitId??`edge-${this.anonymousEdge++}`;return{kind:`edge`,span:[0,0],nodes:[this.entityOccurrence(t[0],n,n.explicitDeclaration),this.entityOccurrence(this.nodes(r.children,`entityName`)[0],i.target,i.target.explicitDeclaration)],edges:[{id:o,span:[0,0],...a.explicitIdLocation?{idSpan:a.explicitIdLocation.span}:{},...a.label?{labelSpan:a.label.span}:{}}]}}entityName(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0],r=this.nodes(e,`nodeLabel`)[0],i=this.nodes(e,`useCaseMetadata`)[0],a=this.nodes(e,`stereotype`)[0],o=this.nodes(e,`classSuffix`)[0],s=o?this.visit(o):{classes:[],spans:[]};if(t){let n=r?this.visit(r):this.tokenLabel(t),o=r?this.tokens(e,`LBRACKET`).length?`rect`:`ellipse`:void 0;return{id:t.image,label:n,location:this.tokenLocation(t),generated:!1,...o?{shape:o}:{},...i?{metadata:this.visit(i)}:{},...a?{stereotype:this.visit(a)}:{},classes:s.classes,classSpans:s.spans,explicitDeclaration:!!(o||i||a)}}let c=this.tokenLabel(n);return{id:this.generateId(c.text),label:c,location:this.tokenLocation(n),generated:!0,...i?{metadata:this.visit(i)}:{},...a?{stereotype:this.visit(a)}:{},classes:s.classes,classSpans:s.spans,explicitDeclaration:!!(i||a)}}nodeLabel(e){let t=this.allTokens(e);if(t.length===1&&(t[0].tokenType.name===`PLAIN_STRING`||t[0].tokenType.name===`MARKDOWN_STRING`))return this.tokenLabel(t[0]);let n=[t[0].startOffset,(t.at(-1).endOffset??t.at(-1).startOffset)+1];return{text:this.source.slice(n[0],n[1]),type:`text`,span:n}}useCaseMetadata(e){return this.visit(this.nodes(e,`metadata`)[0])}relationTail(e){let t=this.tokens(e,`IDENTIFIER`)[0];return{...t?{explicitId:t.image,explicitIdLocation:this.tokenLocation(t)}:{},arrow:this.visit(this.nodes(e,`arrow`)[0]),target:this.visit(this.nodes(e,`entityName`)[0])}}arrow(e){return this.visit(this.firstNode(e,`semanticRelation`,`forwardSolidOperator`,`backwardSolidOperator`,`markerlessSolidOperator`,`forwardCircleOperator`,`backwardCircleOperator`,`forwardCrossOperator`,`backwardCrossOperator`))}edgeLabel(e){return this.nodeLabel(e)}semanticRelation(e){if(this.tokens(e,`GENERALIZATION`).length)return{type:`generalization`,arrowType:K.SOLID_ARROW,minlen:1};let t=this.tokens(e,`INCLUDE`).length?`include`:`extend`,n=this.tokens(e,t===`include`?`INCLUDE`:`EXTEND`)[0];return{type:t,arrowType:K.SOLID_ARROW,label:{text:t,type:`text`,span:this.tokenSpan(n)},minlen:1}}metadata(e){return{properties:this.nodes(e,`metadataProperty`).map(e=>this.visit(e)),location:this.ctxLocation(e)}}metadataProperty(e){let t=this.allTokens(e).filter(e=>e.tokenType.name!==`COLON`),n=t[0],r=t[1],i=r.tokenType.name===`TRUE`||r.tokenType.name!==`FALSE`&&this.decodePlain(r),a=[n.startOffset,(r.endOffset??r.startOffset)+1];return{key:this.decodePlain(n),value:i,span:a,keySpan:this.contentSpan(n),valueSpan:this.contentSpan(r),location:this.tokenLocation(n)}}metadataSeparator(e){}systemBoundaryStatement(e){let t=this.visit(this.nodes(e,`systemBoundaryName`)[0]),n=this.nodes(e,`classSuffix`)[0],r=n?this.visit(n):{classes:[],spans:[]};t.classes=r.classes,this.builder.addBoundary(t);let i=this.parentBoundary;this.parentBoundary={id:t.id,location:t.location};let a=this.nodes(e,`systemBoundaryContent`)[0],o=a?this.visit(a):[];this.parentBoundary=i;let s=this.tokens(e,`END`)[0],c=this.nodes(e,`metadata`)[0],l=c?this.visit(c):void 0,u={kind:`group`,span:[0,0],group:t.id,idSpan:t.location.span,titleSpan:t.label.span,endSpan:this.tokenSpan(s),classSpans:r.spans,...l?{metadata:l.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))}:{},...o.length?{children:o}:{}};return l&&this.builder.addMetadataAssignment(t.id,t.location,l,u),u}systemBoundaryName(e){let t=this.tokens(e,`IDENTIFIER`)[0];if(t){let n=this.nodes(e,`nodeLabel`)[0];return{id:t.image,label:n?this.visit(n):this.tokenLabel(t),location:this.tokenLocation(t),generated:!1,classes:[]}}let n=this.tokens(e,`PLAIN_STRING`)[0]??this.tokens(e,`MARKDOWN_STRING`)[0],r=this.tokenLabel(n);return{id:this.generateId(r.text),label:r,location:this.tokenLocation(n),generated:!0,classes:[]}}systemBoundaryContent(e){return[...this.nodes(e,`blankLine`),...this.nodes(e,`commentLine`),...this.nodes(e,`boundaryElement`)].sort((e,t)=>(e.location?.startOffset??0)-(t.location?.startOffset??0)).map(e=>this.wrap(e,this.visit(e)))}boundaryElement(e){let t=this.nodes(e,`actorDeclarationOnly`)[0];if(t)return this.visit(t);let n=this.nodes(e,`entityName`)[0],r=this.visit(n);return r.explicitDeclaration=!0,r.shape??=`ellipse`,this.builder.addElement(this.entityDraft(r)),{kind:`node`,span:[0,0],nodes:[this.entityOccurrence(n,r,!0)]}}metadataAssignmentStatement(e){let t=this.visit(this.nodes(e,`metadataAssignmentTarget`)[0]),n=this.visit(this.nodes(e,`metadata`)[0]),r={kind:`metadata`,span:[0,0],nodes:[{id:t.id,span:t.location.span,idSpan:t.location.span}],metadata:n.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))};return this.builder.addMetadataAssignment(t.id,t.location,n,r),r}metadataAssignmentTarget(e){let t=this.allTokens(e)[0],n=this.tokenLabel(t);return{id:t.tokenType.name===`IDENTIFIER`?t.image:this.generateId(n.text),location:this.tokenLocation(t)}}noteStatement(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.visit(this.nodes(e,`nodeLabel`)[0]);return this.builder.addNote({target:t.image,targetLocation:this.tokenLocation(t),label:n,location:this.ctxLocation(e)}),{kind:`note`,span:[0,0],ref:`note-${this.anonymousNote++}`,refSpan:n.span,nodes:[{id:t.image,span:this.tokenSpan(t),idSpan:this.tokenSpan(t)}]}}stereotype(e){let t=this.tokens(e,`STEREOTYPE_TEXT`)[0];return{value:t.image.trim(),span:this.tokenSpan(t)}}classSuffix(e){let t=this.tokens(e,`IDENTIFIER`);return{classes:t.map(e=>e.image),spans:t.map(e=>this.tokenSpan(e))}}jsonStatement(e){let t=this.tokens(e,`JSON_DECLARATION_START`)[0],n=this.tokens(e,`JSON_OBJECT_LITERAL`)[0],r=/^json[\t ]+(\w+)/.exec(t.image),i=r[1],a=r[0].length-i.length,o={span:[t.startOffset+a,t.startOffset+a+i.length],line:t.startLine??1,column:(t.startColumn??1)+a},s=Zs(n.image,n.startLine??1,n.startColumn??1),c=this.nodes(e,`classSuffix`)[0],l=c?this.visit(c):{classes:[],spans:[]},u={id:i,value:s.value,propertyOrder:s.propertyOrder,location:o,classes:l.classes};return this.builder.addJson(u),{kind:`json`,span:[0,0],nodes:[{id:i,span:o.span,idSpan:o.span,defines:!0,classSpans:l.spans}],classSpans:l.spans}}directionStatement(e){let t=this.allTokens(e).find(e=>[`TD`,`TB`,`BT`,`RL`,`LR`].includes(e.tokenType.name));return this.builder.setDirection(t.image),{kind:`direction`,span:[0,0]}}classDefStatement(e){let t=this.tokens(e,`IDENTIFIER`),n=this.visit(this.nodes(e,`styles`)[0]);return this.builder.addClassDef(t.map(e=>e.image),n),{kind:`classDef`,span:[0,0],ref:t[0].image,refSpan:this.tokenSpan(t[0])}}classStatement(e){let t=this.tokens(e,`IDENTIFIER`),n=1;for(;n({id:e.image,location:this.tokenLocation(e)})),i=t.slice(n).map(e=>e.image);return this.builder.addClassAssignment(r,i),{kind:`classAssign`,span:[0,0],ref:i[0],refSpan:this.tokenSpan(t[n]),nodes:r.map(({id:e,location:t})=>({id:e,span:t.span,idSpan:t.span}))}}styleStatement(e){let t=this.tokens(e,`IDENTIFIER`)[0],n=this.visit(this.nodes(e,`styles`)[0]);return this.builder.addStyleAssignment(t.image,this.tokenLocation(t),n),{kind:`style`,span:[0,0],nodes:[{id:t.image,span:this.tokenSpan(t),idSpan:this.tokenSpan(t)}]}}styles(e){return this.nodes(e,`styleValue`).map(e=>this.visit(e))}styleValue(e){let t=this.allTokens(e),n=[t[0].startOffset,(t.at(-1).endOffset??t.at(-1).startOffset)+1];return this.source.slice(n[0],n[1]).replaceAll(`\\,`,`,`)}styleComponent(e){return this.allTokens(e).map(e=>e.image).join(``)}forwardSolidOperator(e){let t=this.tokens(e,`FORWARD_SOLID`)[0];return{type:`association`,arrowType:K.SOLID_ARROW,minlen:this.solidMinlen(t)}}backwardSolidOperator(e){let t=this.tokens(e,`BACKWARD_SOLID`)[0],n=this.nodes(e,`edgeLabel`)[0],r=n?this.tokens(e,`MARKERLESS_SOLID`).at(-1):t;return{type:`association`,arrowType:K.BACK_ARROW,minlen:this.solidMinlen(r),...n?{label:this.visit(n)}:{}}}markerlessSolidOperator(e){let t=this.nodes(e,`edgeLabel`)[0],n=this.allTokens(e);if(!t)return{type:`association`,arrowType:K.LINE_SOLID,minlen:this.solidMinlen(this.tokens(e,`MARKERLESS_SOLID`)[0])};let r=n.at(-1),i=r.tokenType.name===`FORWARD_SOLID`?K.SOLID_ARROW:r.tokenType.name===`FORWARD_CIRCLE`?K.CIRCLE_ARROW:r.tokenType.name===`FORWARD_CROSS`?K.CROSS_ARROW:K.LINE_SOLID;return{type:`association`,arrowType:i,label:this.visit(t),minlen:i===K.SOLID_ARROW||i===K.LINE_SOLID?this.solidMinlen(r):1}}forwardCircleOperator(e){return{type:`association`,arrowType:K.CIRCLE_ARROW,minlen:1}}backwardCircleOperator(e){let t=this.nodes(e,`edgeLabel`)[0];return{type:`association`,arrowType:K.CIRCLE_ARROW_REVERSED,minlen:1,...t?{label:this.visit(t)}:{}}}forwardCrossOperator(e){return{type:`association`,arrowType:K.CROSS_ARROW,minlen:1}}backwardCrossOperator(e){let t=this.nodes(e,`edgeLabel`)[0];return{type:`association`,arrowType:K.CROSS_ARROW_REVERSED,minlen:1,...t?{label:this.visit(t)}:{}}}actorDraft(e){return{id:e.id,kind:`actor`,label:e.label,location:e.location,generated:e.generated,...this.parentBoundary?{parentId:this.parentBoundary.id,parentLocation:this.parentBoundary.location}:{},...e.metadata?{metadata:e.metadata}:{},...e.stereotype?{stereotype:e.stereotype.value,stereotypeSpan:e.stereotype.span}:{},classes:e.classes}}entityDraft(e){return{id:e.id,kind:`usecase`,label:e.label,location:e.location,generated:e.generated,...this.parentBoundary?{parentId:this.parentBoundary.id,parentLocation:this.parentBoundary.location}:{},...e.shape?{shape:e.shape}:{},...e.metadata?{metadata:e.metadata}:{},...e.stereotype?{stereotype:e.stereotype.value,stereotypeSpan:e.stereotype.span}:{},classes:e.classes}}endpoint(e,t=e.explicitDeclaration??!0){return{id:e.id,label:e.label,location:e.location,generated:e.generated,declaration:t,classesOnReference:e.classes.length>0}}relationshipDraft(e,t,n){return{source:this.endpoint(e,!0),target:this.endpoint(t.target),location:n,...t.explicitId?{explicitId:t.explicitId,explicitIdLocation:t.explicitIdLocation}:{},...t.arrow}}actorOccurrence(e,t,n){return{id:t.id,span:this.nodeSpan(e),idSpan:t.location.span,labelSpan:t.label.span,...n?{defines:!0}:{},...t.stereotype?{stereotypeSpan:t.stereotype.span}:{},...t.metadata?{metadata:t.metadata.properties.map(({key:e,span:t,keySpan:n,valueSpan:r})=>({key:e,span:t,keySpan:n,valueSpan:r}))}:{},...t.classSpans.length?{classSpans:t.classSpans}:{}}}entityOccurrence(e,t,n){return this.actorOccurrence(e,t,n)}wrap(e,t){if(t.kind===`blank`||t.kind===`comment`)return t;t.span=this.nodeSpan(e);for(let e of t.edges??[])e.span=t.span;return t}tokenLabel(e){let t=e.tokenType.name===`MARKDOWN_STRING`?`markdown`:`text`,n=t===`markdown`?2:+(e.tokenType.name===`PLAIN_STRING`),r=this.tokenSpan(e,n);return{text:this.source.slice(r[0],r[1]),type:t,span:r}}decodePlain(e){return e.tokenType.name===`PLAIN_STRING`?e.image.slice(1,-1):e.image}contentSpan(e){return this.tokenSpan(e,e.tokenType.name===`PLAIN_STRING`?1:e.tokenType.name===`MARKDOWN_STRING`?2:0)}generateId(e){return e.replace(/\W/g,`_`)}solidMinlen(e){return Math.max(1,(e.image.match(/-/g)?.length??2)-1)}nodeLocation(e){let t=this.allTokens(e.children)[0];return{span:this.nodeSpan(e),line:t.startLine??1,column:t.startColumn??1}}ctxLocation(e){let t=this.allTokens(e).filter(e=>e.tokenType.name!==`NEWLINE`&&e.tokenType.name!==`EOF`),n=t[0],r=t.at(-1);return{span:[n.startOffset,Math.min(this.source.length,(r.endOffset??r.startOffset+r.image.length-1)+1)],line:n.startLine??1,column:n.startColumn??1}}tokenLocation(e){let t=e.tokenType.name===`PLAIN_STRING`?1:e.tokenType.name===`MARKDOWN_STRING`?2:0;return{span:this.tokenSpan(e,t),line:e.startLine??1,column:(e.startColumn??1)+t}}nodeSpan(e){let t=this.allTokens(e.children).filter(e=>e.tokenType.name!==`NEWLINE`&&e.tokenType.name!==`EOF`),n=t[0],r=t.at(-1);if(!n||!r)throw Error(`Usecase CST node has no source token`);return[n.startOffset,Math.min(this.source.length,(r.endOffset??r.startOffset+r.image.length-1)+1)]}tokenSpan(e,t=0){return[e.startOffset+t,Math.min(this.source.length,(e.endOffset??e.startOffset+e.image.length-1)+1-t)]}nodes(e,t){return(e[t]??[]).filter(e=>`children`in e)}tokens(e,t){return(e[t]??[]).filter(e=>`tokenTypeIdx`in e)}firstNode(e,...t){for(let n of t){let t=this.nodes(e,n)[0];if(t)return t}throw Error(`Usecase CST is missing one of: ${t.join(`, `)}`)}allTokens(e){let t=[];for(let n of Object.values(e))for(let e of n)`tokenTypeIdx`in e?t.push(e):t.push(...this.allTokens(e.children));return t.sort((e,t)=>e.startOffset-t.startOffset)}},dc={parse:n(async e=>{yo.clear(),Ks.input=[];try{za({diagramType:`usecase`,lexer:Us,parser:Ks,entry:n(()=>Ks.start(),`entry`),visit:n(t=>uc.build(t,e),`visit`)},e)}catch(t){yo.clear();let n=Ks.errors[0];if(n){let{token:r}=n,i=Number.isFinite(r.startOffset)?r.startOffset:e.length,a=typeof r.endOffset==`number`&&Number.isFinite(r.endOffset)?r.endOffset+1:i,o=r.startLine??e.slice(0,i).split(/\r\n|\r|\n/).length,s=Math.max(e.lastIndexOf(` +`,i-1),e.lastIndexOf(`\r`,i-1)),c=r.startColumn??i-s,l=t instanceof Error?t.message:String(t);throw Error(`${l} at line ${o}, column ${c} [${i},${a})`)}throw t}},`parse`)},fc=[`point`,`circle`,`cross`,`extension`],pc={usecaseActor:!0,usecaseActorHollow:!0,usecaseActorAwesome:!0,usecaseActorIcon:!0},mc=n((e,t)=>{let[n,r]=[e,t].map(e=>e.replace(/[^\w-]+/g,`_`).replace(/^_+|_+$/g,``)||`element`);return`usecase-${n}-${r}`},`usecaseDomId`),hc=n(e=>`usecase-${e.replace(/[^\w-]+/g,`_`).replace(/^_+|_+$/g,``)||`element`}`,`usecaseNodeDomId`),gc=n((e,t)=>t===`markdown`?h(e).map(e=>e.map(e=>e.content).join(` `)).join(` +`):e,`getAccessibleLabel`),_c=n(e=>{let t=gc(e.label??e.id,e.labelType);if(pc[e.shape]){let n=e.actorType&&e.actorType!==`normal`?`${e.actorType} `:``;return`${e.business?`business `:``}${n}actor ${t}${e.stereotype?`, stereotype ${e.stereotype}`:``}`}if(e.shape===`note`)return`Note for ${e.noteTargetLabel??e.noteTarget??``}: ${t}`;if(e.shape===`usecaseJsonTable`){let n=(e.jsonRows??[]).map(e=>`${e.accessibleKey}: ${e.value}`).join(`; `);return n?`${t}: ${n}`:t}let n=e.stereotype?`, stereotype ${e.stereotype}`:``;return`${e.business?`business `:``}use case ${t}${n}`},`getUsecaseNodeAccessibleName`),vc=n(e=>`${e.boundaryType} system boundary ${gc(e.label??e.id,e.labelType)}`,`getUsecaseBoundaryAccessibleName`),yc=n(e=>e.relationshipType===`note`?``:`${e.relationshipType===`association`&&e.label?`association ${gc(e.label,e.labelType)}`:e.relationshipType} from ${e.sourceLabel} to ${e.targetLabel}`,`getUsecaseEdgeAccessibleName`),bc=n(e=>e.replace(/&/g,`&`).replace(//g,`>`),`escapePlainLabel`),xc=n(e=>e.replace(/([*[\\\]_`])/g,`\\$1`),`escapeMarkdownMarkers`),Sc=n((e,t)=>{e.diagramId=t,e.markers=[...fc];for(let t of e.nodes){let e=t;if(e.domId=hc(t.id),t.label!==void 0&&t.labelType===`text`&&(t.label=bc(t.label)),t.stereotype&&=bc(t.stereotype),!t.isGroup&&t.shape===`usecaseJsonTable`&&(t.jsonRows=t.jsonRows?.map(e=>({...e,key:bc(e.key),value:bc(e.value)}))),!t.isGroup&&(t.shape===`usecaseEllipse`||t.shape===`rect`)&&t.stereotype){let n=t.label??bc(t.id);t.label=`\xAB${xc(t.stereotype)}\xBB
    ${t.labelType===`text`?xc(n):n}`,t.labelType=`markdown`,e.hasFoldedStereotype=!0,delete t.stereotype}}for(let t of e.edges)t.label!==void 0&&t.labelType===`text`&&(t.label=bc(t.label));return e},`prepareUsecaseLayoutData`),Cc=n((e,n,r)=>{for(let t of n.nodes){let i=typeof t.domId==`string`?t.domId:mc(n.diagramId,t.id),a=e.select(`#${i}`),o=t.isGroup?`boundary`:pc[t.shape]?`actor`:t.shape===`note`?`note`:t.shape===`usecaseJsonTable`?`json`:`usecase`,s=r.nodes.get(t.id)??t.id;if(a.attr(`data-usecase-id`,t.id).attr(`data-usecase-kind`,o).attr(`role`,`img`).attr(`aria-label`,s),!t.isGroup&&(t.shape===`usecaseEllipse`||t.shape===`rect`)&&`hasFoldedStereotype`in t&&t.hasFoldedStereotype===!0){let e=a.node(),t=e?.querySelector(`.nodeLabel`),n=t?.querySelector(`p`)??t,r=n?.firstChild;if(n&&r?.nodeType===3){let e=n.ownerDocument.createElement(`span`);e.className=`usecase-stereotype`,n.insertBefore(e,r),e.appendChild(r)}else e?.querySelector(`.label tspan tspan, .label tspan`)?.classList.add(`usecase-stereotype`)}}let i=new Map(n.edges.map(e=>[e.id,e]));e.selectAll(`path[data-et="edge"]`).each(function(){let e=i.get(this.getAttribute(`data-id`)??``);if(!e)return;let a=t(this);a.attr(`id`,mc(n.diagramId,e.id)).attr(`data-usecase-id`,e.id).attr(`data-usecase-kind`,e.internal?`note-connector`:`relationship`),e.internal?a.attr(`aria-hidden`,`true`):a.attr(`role`,`img`).attr(`aria-label`,r.edges.get(e.id)??e.id)})},`annotateUsecaseElements`),wc=n((e,t)=>{e.style(`--mermaid-usecase-actor-font-size`,`${t.actorFontSize}px`).style(`--mermaid-usecase-actor-font-family`,t.actorFontFamily).style(`--mermaid-usecase-actor-font-weight`,t.actorFontWeight).style(`--mermaid-usecase-font-size`,`${t.usecaseFontSize}px`).style(`--mermaid-usecase-font-family`,t.usecaseFontFamily).style(`--mermaid-usecase-font-weight`,t.usecaseFontWeight)},`applyUsecaseFonts`),Tc={draw:n(async(t,n,r,i)=>{e.info(`Drawing usecase diagram (unified)`,n);let{layout:a}=d(),o=i.db,s=o.getData(),c=new Map(s.nodes.map(e=>[e.id,gc(e.label??e.id,e.labelType)])),l={nodes:new Map(s.nodes.map(e=>[e.id,e.isGroup?vc(e):_c(e.shape===`note`?{...e,noteTargetLabel:c.get(e.noteTarget??``)}:e)])),edges:new Map(s.edges.map(e=>[e.id,yc({...e,sourceLabel:c.get(e.source)??e.sourceLabel,targetLabel:c.get(e.target)??e.targetLabel})]))},u=Ve(n,s.config.securityLevel);s.layoutAlgorithm=re(a),Sc(s,n),wc(u,s),await ne(s,u),Cc(u,s,l);let f=s.diagramPadding;m.insertTitle(u,`usecaseDiagramTitleText`,0,o.getDiagramTitle?.()??``),He(u,f,`usecaseDiagram`,s.useMaxWidth),wc(u,s)},`draw`)},Ec=n(e=>({actorBkg:e.usecaseActorBkg??e.actorBkg??e.mainBkg,actorBorder:e.usecaseActorBorder??e.actorBorder??e.primaryColor,bkg:e.usecaseBkg??e.mainBkg,border:e.usecaseBorder??e.nodeBorder??e.primaryColor,boundaryBkg:e.usecaseBoundaryBkg??e.clusterBkg,boundaryBorder:e.usecaseBoundaryBorder??e.clusterBorder,includeLine:e.usecaseIncludeLine??e.lineColor,extendLine:e.usecaseExtendLine??e.lineColor}),`roleColors`),Dc=n(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!ee(t,r))return``;let i=o().usecase?.colorScheme===`rotate`,a=te(e.look),s=a===`handDrawn`,c=_(n),l=``;for(let e=0;e{let t=Ec(e),n=te(e.look)===`handDrawn`;return` + ${Dc(e)} + & .usecase-actor { + color: ${e.actorTextColor??e.primaryTextColor}; + } + + & .usecase-actor-shape, + & .usecase-actor-hollow, + & .usecase-actor-awesome, + & .usecase-actor-icon { + fill: ${t.actorBkg}; + stroke: ${t.actorBorder}; + stroke-width: 2px; + } +${n?``:` + /* The rule above colours the glyph group and lets its children inherit, which the neo + look breaks: it ships a \`[data-look="neo"].node path { stroke }\` rule that lands on + the glyph's own paths, and a value set directly on a child always beats one inherited + from its parent, whatever the parent rule's specificity. Since neo is the default look, + without this every actor renders in the node border colour rather than the actor + colour the rule above asks for. + + \`.node\` is in the selector to outrank that neo rule rather than tie with it: both + would otherwise be one attribute plus one class plus one element, leaving the winner to + depend on which stylesheet is concatenated last. + + Stroke only: the hollow variant's own \`fill="none"\` has to keep winning. */ + & .node.usecase-actor .usecase-actor-glyph path, + & .node.usecase-actor .usecase-actor-glyph circle { + stroke: ${t.actorBorder}; + } +`} + & .usecase-actor .nodeLabel, + & .actor-label { + color: ${e.actorTextColor??e.primaryTextColor}; + fill: ${e.actorTextColor??e.primaryTextColor}; + font-family: var(--mermaid-usecase-actor-font-family, ${e.fontFamily}); + font-size: var(--mermaid-usecase-actor-font-size, 14px); + font-weight: var(--mermaid-usecase-actor-font-weight, normal); + } + + & .usecase-element ellipse, + & .usecase-element rect, + & .usecase-business ellipse, + & .usecase-business rect { + fill: ${t.bkg}; + stroke: ${t.border}; + stroke-width: 2px; + } +${n?``:` + /* The same interception the actor glyph hits, one element down: neo ships + \`[data-look="neo"].node rect { stroke: nodeBorder }\`, which outranks the plain + \`.usecase-element rect\` above, so a use case written in the \`[Rect]\` form kept the node + border colour while its ellipse siblings took the role colour. An \`\` has no + equivalent neo rule and is already correct; restating it here costs nothing and means + the two forms cannot drift apart again. + + Qualified with \`[data-look]\` *and* \`.node\` to land strictly above that rule rather than + tie with it -- on a tie the later stylesheet would win, which is how neo took this in + the first place. Skipped under handDrawn, where roughjs draws paths and neither element + exists. */ + & [data-look="${te(e.look)}"].node.usecase-element ellipse, + & [data-look="${te(e.look)}"].node.usecase-element rect { + fill: ${t.bkg}; + stroke: ${t.border}; + } + + /* The business marker is a \`\`, so it loses to \`[data-look="neo"].node path\` the same + way. No \`fill\`: the marker is drawn with \`fill="none"\` and has to stay that way. */ + & [data-look="${te(e.look)}"].node.usecase-element .usecase-business-marker { + stroke: ${t.border}; + } +`} + & .usecase-element .nodeLabel, + & .usecase-label { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + font-family: var(--mermaid-usecase-font-family, ${e.fontFamily}); + font-size: var(--mermaid-usecase-font-size, 12px); + font-weight: var(--mermaid-usecase-font-weight, normal); + } + + & .usecase-stereotype, + & .usecase-business-marker { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + stroke: ${t.border}; + } + + & .system-boundary rect.boundary-body, + & .system-boundary rect.boundary-tab, + & .system-boundary-package-tab { + fill: ${t.boundaryBkg}; + stroke: ${t.boundaryBorder}; + stroke-width: 1px; + } + + & .system-boundary-title text { + fill: ${e.titleColor??e.primaryTextColor}; + } + + /* Only the span, never the

    inside it: the renderer puts a user-supplied + 'color' on the span, and that has to stay inheritable by its children. */ + & .system-boundary-title span { + color: ${e.titleColor??e.primaryTextColor}; + } + + & .usecase-note { + fill: ${e.noteBkgColor}; + stroke: ${e.noteBorderColor}; + color: ${e.noteTextColor}; + } + + & .usecase-note .nodeLabel { + color: ${e.noteTextColor}; + fill: ${e.noteTextColor}; + } + + & .usecase-json-table, + & .usecase-json-table rect, + & .usecase-json-cell { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder??e.primaryColor}; + } + + & .usecase-json-title, + & .usecase-json-key, + & .usecase-json-value { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + } + + & .relationship { + fill: none; + stroke: ${e.lineColor}; + } + + & .relationship-include, + & .relationship-extend, + & .relationship-note { + stroke-dasharray: 3; + } + + /* Include and extend are both dashed, which is a weak distinction at small sizes. The + tokens default to \`lineColor\`, so a theme that does not set them is unchanged. */ + & .relationship-include { + stroke: ${t.includeLine}; + } + + & .relationship-extend { + stroke: ${t.extendLine}; + } + + & .relationship.edge-animation-fast, + & .relationship.edge-animation-slow { + stroke-linecap: round; + } + + & .edgeLabel, + & .edgeLabel p { + background-color: ${e.edgeLabelBackground}; + } + + & .labelBkg { + background-color: ${e.edgeLabelBackground}; + padding: 0 2px; + } + + & .edgeLabel .label rect { + fill: ${e.edgeLabelBackground}; + } + + & .relationship-label, + & .edgeLabel { + color: ${e.primaryTextColor}; + fill: ${e.primaryTextColor}; + font-family: ${e.fontFamily}; + font-size: 10px; + font-weight: normal; + } + + & .marker, + & .marker.point, + & .marker.circle, + & .marker.cross { + fill: ${e.lineColor}; + stroke: ${e.lineColor}; + } + + & .marker.extension { + fill: ${e.mainBkg}; + stroke: ${e.lineColor}; + } +`},`getStyles`)};export{Oc as diagram}; \ No newline at end of file diff --git a/www/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js b/www/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js new file mode 100644 index 0000000..90453fc --- /dev/null +++ b/www/assets/vennDiagram-UO4OBE2U-Bq0yqgVW.js @@ -0,0 +1,34 @@ +import{p as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{H as n,U as r,a as i,at as a,b as o,c as s,f as c,it as l,nt as u,q as d,rt as f,v as p,w as m,y as h}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as g}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as _}from"./rough.esm-Dy-Kn_BL.js";import{y as v}from"./index-DoQkmpth.js";var y=(e,t)=>l(e,`a`,-t),b=1e-10;function x(e,t){let n=C(e),r=n.filter(t=>S(t,e)),i=0,a=0,o=[];if(r.length>1){let t=O(r);for(let e=0;et.angle-e.angle);let n=r[r.length-1];for(let t=0;tr.radius*2&&(d=r.radius*2),(l==null||l.width>d)&&(l={circle:r,width:d,p1:s,p2:n,large:d>r.radius,sweep:!0})}l!=null&&(o.push(l),i+=w(l.circle.radius,l.width),n=s)}}else{let t=e[0];for(let n=1;nMath.abs(t.radius-e[r].radius)){n=!0;break}n?i=a=0:(i=t.radius*t.radius*Math.PI,o.push({circle:t,p1:{x:t.x,y:t.y+t.radius},p2:{x:t.x-b,y:t.y+t.radius},width:t.radius*2,large:!0,sweep:!0}))}return a/=2,t&&(t.area=i+a,t.arcArea=i,t.polygonArea=a,t.arcs=o,t.innerPoints=r,t.intersectionPoints=n),i+a}function S(e,t){return t.every(t=>T(e,t)=e+t)return 0;if(n<=Math.abs(e-t))return Math.PI*Math.min(e,t)*Math.min(e,t);let r=e-(n*n-t*t+e*e)/(2*n),i=t-(n*n-e*e+t*t)/(2*n);return w(e,r)+w(t,i)}function D(e,t){let n=T(e,t),r=e.radius,i=t.radius;if(n>=r+i||n<=Math.abs(r-i))return[];let a=(r*r-i*i+n*n)/(2*n),o=Math.sqrt(r*r-a*a),s=e.x+a*(t.x-e.x)/n,c=e.y+a*(t.y-e.y)/n,l=-(t.y-e.y)*(o/n),u=-(t.x-e.x)*(o/n);return[{x:s+l,y:c-u},{x:s-l,y:c+u}]}function O(e){let t={x:0,y:0};for(let n of e)t.x+=n.x,t.y+=n.y;return t.x/=e.length,t.y/=e.length,t}function k(e,t,n,r){r||={};let i=r.maxIterations||100,a=r.tolerance||1e-10,o=e(t),s=e(n),c=n-t;if(o*s>0)throw`Initial bisect points must have opposite signs`;if(o===0)return t;if(s===0)return n;for(let n=0;n=0&&(t=n),Math.abs(c)A(t))}function M(e,t){let n=0;for(let r=0;re.fx-t.fx,_=t.slice(),v=t.slice(),y=t.slice(),b=t.slice();for(let t=0;t{let t=e.slice();return t.fx=e.fx,t.id=e.id,t});e.sort((e,t)=>e.id-t.id),n.history.push({x:m[0].slice(),fx:m[0].fx,simplex:e})}f=0;for(let e=0;e=m[p-1].fx){let n=!1;if(v.fx>t.fx?(F(y,1+u,_,-u,t),y.fx=e(y),y.fx=1)break;for(let t=1;ts+a*i*c||l>=p)f=i;else{if(Math.abs(d)<=-o*c)return i;d*(f-u)>=0&&(f=u),u=i,p=l}return 0}for(let m=0;m<10;++m){if(F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||m&&l>=u)return p(f,i,u);if(Math.abs(d)<=-o*c)return i;if(d>=0)return p(i,f,l);u=l,f=i,i*=2}return i}function R(e,t,n){let r={x:t.slice(),fx:0,fxprime:t.slice()},i={x:t.slice(),fx:0,fxprime:t.slice()},a=t.slice(),o,s,c=1,l;n||={},l=n.maxIterations||t.length*20,r.fx=e(r.x,r.fxprime),o=r.fxprime.slice(),P(o,r.fxprime,-1);for(let t=0;t{let t={};for(let n=0;nE(e,t,r)-n,0,e+t)}function ne(e,t={}){let n=t.distinct,r=e.map(e=>Object.assign({},e));function i(e){return e.join(`;`)}if(n){let e=new Map;for(let t of r)for(let n=0;ne===t?0:ee.sets.length===2).forEach(e=>{let a=n[e.sets[0]],o=n[e.sets[1]],s=z(Math.sqrt(t[a].size/Math.PI),Math.sqrt(t[o].size/Math.PI),e.size);r[a][o]=r[o][a]=s;let c=0;e.size+1e-10>=Math.min(t[a].size,t[o].size)?c=1:e.size<=1e-10&&(c=-1),i[a][o]=i[o][a]=c}),{distances:r,constraints:i}}function ie(e,t,n,r){for(let e=0;e0&&m<=d||f<0&&m>=d||(i+=2*h*h,t[2*a]+=4*h*(o-l),t[2*a+1]+=4*h*(s-u),t[2*c]+=4*h*(l-o),t[2*c+1]+=4*h*(u-s))}}return i}function ae(e,t={}){let n=se(e,t),r=t.lossFunction||B;if(e.length>=8){let i=oe(e,t),a=r(i,e),o=r(n,e);a+1e-8e.map(e=>e/s));let c=(e,t)=>ie(e,t,a,o),l=null;for(let e=0;ee.sets.length===2);for(let t of e){let e=t.weight==null?1:t.weight,n=t.sets[0],a=t.sets[1];t.size+te>=Math.min(r[n].size,r[a].size)&&(e=0),i[n].push({set:a,size:t.size,weight:e}),i[a].push({set:n,size:t.size,weight:e})}let a=[];Object.keys(i).forEach(e=>{let t=0;for(let n=0;ne[t]));let i=r.weight==null?1:r.weight;n+=i*(t-r.size)*(t-r.size)}return n}function ce(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight,a=Math.log((t+1)/(r.size+1));n+=i*a*a}return n}function le(e,t,n){if(n==null?e.sort((e,t)=>t.radius-e.radius):e.sort(n),e.length>0){let t=e[0].x,n=e[0].y;for(let r of e)r.x-=t,r.y-=n}if(e.length===2&&T(e[0],e[1])1){let n=Math.atan2(e[1].x,e[1].y)-t,r=Math.cos(n),i=Math.sin(n);for(let t of e){let e=t.x,n=t.y;t.x=r*e-i*n,t.y=i*e+r*n}}if(e.length>2){let n=Math.atan2(e[2].x,e[2].y)-t;for(;n<0;)n+=2*Math.PI;for(;n>2*Math.PI;)n-=2*Math.PI;if(n>Math.PI){let t=e[1].y/(1e-10+e[1].x);for(let n of e){var r=(n.x+t*n.y)/(1+t*t);n.x=2*r-n.x,n.y=2*r*t-n.y}}}}function ue(e){e.forEach(e=>{e.parent=e});function t(e){return e.parent!==e&&(e.parent=t(e.parent)),e.parent}function n(e,n){let r=t(e);r.parent=t(n)}for(let t=0;t{delete e.parent}),Array.from(r.values())}function V(e){let t=t=>({max:e.reduce((e,n)=>Math.max(e,n[t]+n.radius),-1/0),min:e.reduce((e,n)=>Math.min(e,n[t]-n.radius),1/0)});return{xRange:t(`x`),yRange:t(`y`)}}function de(e,t,n){t??=Math.PI/2;let r=me(e).map(e=>Object.assign({},e)),i=ue(r);for(let e of i){le(e,t,n);let r=V(e);e.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),e.bounds=r}i.sort((e,t)=>t.size-e.size),r=i[0];let a=r.bounds,o=(a.xRange.max-a.xRange.min)/50;function s(e,t,n){if(!e)return;let i=e.bounds,s,c;if(t)s=a.xRange.max-i.xRange.min+o;else{s=a.xRange.max-i.xRange.max;let e=(i.xRange.max-i.xRange.min)/2-(a.xRange.max-a.xRange.min)/2;e<0&&(s+=e)}if(n)c=a.yRange.max-i.yRange.min+o;else{c=a.yRange.max-i.yRange.max;let e=(i.yRange.max-i.yRange.min)/2-(a.yRange.max-a.yRange.min)/2;e<0&&(c+=e)}for(let t of e)t.x+=s,t.y+=c,r.push(t)}let c=1;for(;c({radius:u*e.radius,x:r+d+(e.x-o.min)*u,y:r+f+(e.y-s.min)*u,setid:e.setid})))}function pe(e){let t={};for(let n of e)t[n.setid]=n;return t}function me(e){return Object.keys(e).map(t=>Object.assign(e[t],{setid:t}))}function he(e={}){let t=!1,n=600,r=350,i=15,a=1e3,o=Math.PI/2,s=!0,c=null,l=!0,u=!0,d=null,f=null,p=!1,m=null,h=e&&e.symmetricalTextCentre?e.symmetricalTextCentre:!1,g={},_=e&&e.colourScheme?e.colourScheme:e&&e.colorScheme?e.colorScheme:[`#1f77b4`,`#ff7f0e`,`#2ca02c`,`#d62728`,`#9467bd`,`#8c564b`,`#e377c2`,`#7f7f7f`,`#bcbd22`,`#17becf`],v=0,y=function(e){if(e in g)return g[e];var t=g[e]=_[v];return v+=1,v>=_.length&&(v=0),t},b=ee,x=B;function S(g){let _=g.datum(),v=new Set;_.forEach(e=>{e.size==0&&e.sets.length==1&&v.add(e.sets[0])}),_=_.filter(e=>!e.sets.some(e=>v.has(e)));let S={},C={};if(_.length>0){let e=b(_,{lossFunction:x,distinct:p});s&&(e=de(e,o,f)),S=fe(e,n,r,i,c),C=ve(S,_,h)}let w={};_.forEach(e=>{e.label&&(w[e.sets]=e.label)});function T(e){if(e.sets in w)return w[e.sets];if(e.sets.length==1)return``+e.sets[0]}g.selectAll(`svg`).data([S]).enter().append(`svg`);let E=g.select(`svg`);t?E.attr(`viewBox`,`0 0 ${n} ${r}`):E.attr(`width`,n).attr(`height`,r);let D={},O=!1;E.selectAll(`.venn-area path`).each(function(e){let t=this.getAttribute(`d`);e.sets.length==1&&t&&!p&&(O=!0,D[e.sets[0]]=be(t))});function k(e){return t=>Ce(e.sets.map(e=>{let i=D[e],a=S[e];return i||={x:n/2,y:r/2,radius:1},a||={x:n/2,y:r/2,radius:1},{x:i.x*(1-t)+a.x*t,y:i.y*(1-t)+a.y*t,radius:i.radius*(1-t)+a.radius*t}}),m)}let A=E.selectAll(`.venn-area`).data(_,e=>e.sets),j=A.enter().append(`g`).attr(`class`,e=>`venn-area venn-${e.sets.length==1?`circle`:`intersection`}${e.colour||e.color?` venn-coloured`:``}`).attr(`data-venn-sets`,e=>e.sets.join(`_`)),M=j.append(`path`),N=j.append(`text`).attr(`class`,`label`).text(e=>T(e)).attr(`text-anchor`,`middle`).attr(`dy`,`.35em`).attr(`x`,n/2).attr(`y`,r/2);u&&(M.style(`fill-opacity`,`0`).filter(e=>e.sets.length==1).style(`fill`,e=>e.colour?e.colour:e.color?e.color:y(e.sets)).style(`fill-opacity`,`.25`),N.style(`fill`,t=>t.colour||t.color?`#FFF`:e.textFill?e.textFill:t.sets.length==1?y(t.sets):`#444`));function P(e){return typeof e.transition==`function`?e.transition(`venn`).duration(a):e}let F=g;O&&typeof F.transition==`function`?(F=P(g),F.selectAll(`path`).attrTween(`d`,k)):F.selectAll(`path`).attr(`d`,e=>Ce(e.sets.map(e=>S[e])),m);let I=F.selectAll(`text`).filter(e=>e.sets in C).text(e=>T(e)).attr(`x`,e=>Math.floor(C[e.sets].x)).attr(`y`,e=>Math.floor(C[e.sets].y));l&&(O?`on`in I?I.on(`end`,H(S,T)):I.each(`end`,H(S,T)):I.each(H(S,T)));let L=P(A.exit()).remove();typeof A.transition==`function`&&L.selectAll(`path`).attrTween(`d`,k);let R=L.selectAll(`text`).attr(`x`,n/2).attr(`y`,r/2);return d!==null&&(N.style(`font-size`,`0px`),I.style(`font-size`,d),R.style(`font-size`,`0px`)),{circles:S,textCentres:C,nodes:A,enter:j,update:F,exit:L}}return S.wrap=function(e){return arguments.length?(l=e,S):l},S.useViewBox=function(){return t=!0,S},S.width=function(e){return arguments.length?(n=e,S):n},S.height=function(e){return arguments.length?(r=e,S):r},S.padding=function(e){return arguments.length?(i=e,S):i},S.distinct=function(e){return arguments.length?(p=e,S):p},S.colours=function(e){return arguments.length?(y=e,S):y},S.colors=function(e){return arguments.length?(y=e,S):y},S.fontSize=function(e){return arguments.length?(d=e,S):d},S.round=function(e){return arguments.length?(m=e,S):m},S.duration=function(e){return arguments.length?(a=e,S):a},S.layoutFunction=function(e){return arguments.length?(b=e,S):b},S.normalize=function(e){return arguments.length?(s=e,S):s},S.scaleToFit=function(e){return arguments.length?(c=e,S):c},S.styled=function(e){return arguments.length?(u=e,S):u},S.orientation=function(e){return arguments.length?(o=e,S):o},S.orientationOrder=function(e){return arguments.length?(f=e,S):f},S.lossFunction=function(e){return arguments.length?(x=e==="default"?B:e===`logRatio`?ce:e,S):x},S}function H(e,t){return function(n){let r=this,i=e[n.sets[0]].radius||50,a=t(n)||``,o=a.split(/\s+/).reverse(),s=(a.length+o.length)/3,c=o.pop(),l=[c],u=0,d=1.1;r.textContent=null;let f=[];function p(e){let t=r.ownerDocument.createElementNS(r.namespaceURI,`tspan`);return t.textContent=e,f.push(t),r.append(t),t}let m=p(c);for(;c=o.pop(),c;){l.push(c);let e=l.join(` `);m.textContent=e,e.length>s&&m.getComputedTextLength()>i&&(l.pop(),m.textContent=l.join(` `),l=[c],m=p(c),u++)}let h=.35-u*d/2,g=r.getAttribute(`x`),_=r.getAttribute(`y`);f.forEach((e,t)=>{e.setAttribute(`x`,g),e.setAttribute(`y`,_),e.setAttribute(`dy`,`${h+t*d}em`)})}}function U(e,t,n){let r=t[0].radius-T(t[0],e);for(let n=1;n=a&&(i=r[n],a=o)}let o=I(n=>-1*U({x:n[0],y:n[1]},e,t),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,s={x:n?0:o[0],y:o[1]},c=!0;for(let t of e)if(T(s,t)>t.radius){c=!1;break}for(let e of t)if(T(s,e)e.p1))}function _e(e){let t={},n=Object.keys(e);for(let e of n)t[e]=[];for(let r=0;r0&&console.log(`WARNING: area `+o+` not represented on screen`)}return r}function ye(e,t,n){let r=[];return r.push(` +M`,e,t),r.push(` +m`,-n,0),r.push(` +a`,n,n,0,1,0,n*2,0),r.push(` +a`,n,n,0,1,0,-n*2,0),r.join(` `)}function be(e){let t=e.split(` `);return{x:Number.parseFloat(t[1]),y:Number.parseFloat(t[2]),radius:-Number.parseFloat(t[4])}}function xe(e){if(e.length===0)return[];let t={};return x(e,t),t.arcs}function Se(e,t){if(e.length===0)return`M 0 0`;let n=10**(t||0),r=t==null?e=>e:e=>Math.round(e*n)/n;if(e.length==1){let t=e[0].circle;return ye(r(t.x),r(t.y),r(t.radius))}let i=[` +M`,r(e[0].p2.x),r(e[0].p2.y)];for(let t of e){let e=r(t.circle.radius);i.push(` +A`,e,e,0,+!!t.large,+!!t.sweep,r(t.p1.x),r(t.p1.y))}return i.join(` `)}function Ce(e,t){return Se(xe(e),t)}function we(e,t={}){let{lossFunction:n,layoutFunction:r=ee,normalize:i=!0,orientation:a=Math.PI/2,orientationOrder:o,width:s=600,height:c=350,padding:l=15,scaleToFit:u=!1,symmetricalTextCentre:d=!1,distinct:f,round:p=2}=t,m=r(e,{lossFunction:n==="default"||!n?B:n===`logRatio`?ce:n,distinct:f});i&&(m=de(m,a,o));let h=fe(m,s,c,l,u),g=ve(h,e,d),_=new Map(Object.keys(h).map(e=>[e,{set:e,x:h[e].x,y:h[e].y,radius:h[e].radius}])),v=e.map(e=>{let t=e.sets.map(e=>_.get(e)),n=xe(t);return{circles:t,arcs:n,path:Se(n,p),area:e,has:new Set(e.sets)}});function y(e){let t=``;for(let n of v)n.has.size>e.length&&e.every(e=>n.has.has(e))&&(t+=` `+n.path);return t}return v.map(({circles:e,arcs:t,path:n,area:r})=>({data:r,text:g[r.sets],circles:e,arcs:t,path:n,distinctPath:n+y(r.sets)}))}var W=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[5,8],r=[7,8,11,12,17,19,22,24],i=[1,17],a=[1,18],o=[7,8,11,12,14,15,16,17,19,20,21,22,24,27],s=[1,31],c=[1,39],l=[7,8,11,12,17,19,22,24,27],u=[1,57],d=[1,56],f=[1,58],p=[1,59],m=[1,60],h=[7,8,11,12,16,17,19,20,22,24,27,31,32,33],g={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,optNewlines:4,VENN:5,document:6,EOF:7,NEWLINE:8,line:9,statement:10,TITLE:11,SET:12,identifier:13,BRACKET_LABEL:14,COLON:15,NUMERIC:16,UNION:17,identifierList:18,TEXT:19,IDENTIFIER:20,STRING:21,INDENT_TEXT:22,indentedTextTail:23,STYLE:24,stylesOpt:25,styleField:26,COMMA:27,styleValue:28,valueTokens:29,valueToken:30,HEXCOLOR:31,RGBCOLOR:32,RGBACOLOR:33,$accept:0,$end:1},terminals_:{2:`error`,5:`VENN`,7:`EOF`,8:`NEWLINE`,11:`TITLE`,12:`SET`,14:`BRACKET_LABEL`,15:`COLON`,16:`NUMERIC`,17:`UNION`,19:`TEXT`,20:`IDENTIFIER`,21:`STRING`,22:`INDENT_TEXT`,24:`STYLE`,27:`COMMA`,31:`HEXCOLOR`,32:`RGBCOLOR`,33:`RGBACOLOR`},productions_:[0,[3,4],[4,0],[4,2],[6,0],[6,2],[9,1],[9,1],[10,1],[10,2],[10,3],[10,4],[10,5],[10,2],[10,3],[10,4],[10,5],[10,3],[10,3],[10,3],[10,4],[10,4],[10,2],[10,3],[23,1],[23,1],[23,1],[23,2],[23,2],[25,1],[25,3],[26,3],[28,1],[28,1],[29,1],[29,2],[30,1],[30,1],[30,1],[30,1],[30,1],[18,1],[18,3],[13,1],[13,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:case 3:case 4:this.$=[];break;case 5:a[s-1].push(a[s]),this.$=a[s-1];break;case 6:this.$=[];break;case 7:case 22:case 32:case 36:case 37:case 38:case 39:case 40:this.$=a[s];break;case 8:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 9:r.addSubsetData([a[s]],void 0,void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 10:r.addSubsetData([a[s-1]],a[s],void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 11:r.addSubsetData([a[s-2]],void 0,parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 12:r.addSubsetData([a[s-3]],a[s-2],parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 13:if(a[s].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s]),r.addSubsetData(a[s],void 0,void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 14:if(a[s-1].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-1]),r.addSubsetData(a[s-1],a[s],void 0),r.setIndentMode&&r.setIndentMode(!0);break;case 15:if(a[s-2].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-2]),r.addSubsetData(a[s-2],void 0,parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 16:if(a[s-3].length<2)throw Error(`union requires multiple identifiers`);r.validateUnionIdentifiers&&r.validateUnionIdentifiers(a[s-3]),r.addSubsetData(a[s-3],a[s-2],parseFloat(a[s])),r.setIndentMode&&r.setIndentMode(!0);break;case 17:case 18:case 19:r.addTextData(a[s-1],a[s],void 0);break;case 20:case 21:r.addTextData(a[s-2],a[s-1],a[s]);break;case 23:r.addStyleData(a[s-1],a[s]);break;case 24:case 25:case 26:var c=r.getCurrentSets();if(!c)throw Error(`text requires set`);r.addTextData(c,a[s],void 0);break;case 27:case 28:var c=r.getCurrentSets();if(!c)throw Error(`text requires set`);r.addTextData(c,a[s-1],a[s]);break;case 29:case 41:this.$=[a[s]];break;case 30:case 42:this.$=[...a[s-2],a[s]];break;case 31:this.$=[a[s-2],a[s]];break;case 33:this.$=a[s].join(` `);break;case 34:this.$=[a[s]];break;case 35:a[s-1].push(a[s]),this.$=a[s-1];break;case 43:case 44:this.$=a[s]}},`anonymous`),table:[e(n,[2,2],{3:1,4:2}),{1:[3]},{5:[1,3],8:[1,4]},e(r,[2,4],{6:5}),e(n,[2,3]),{7:[1,6],8:[1,8],9:7,10:9,11:[1,10],12:[1,11],17:[1,12],19:[1,13],22:[1,14],24:[1,15]},{1:[2,1]},e(r,[2,5]),e(r,[2,6]),e(r,[2,7]),e(r,[2,8]),{13:16,20:i,21:a},{13:20,18:19,20:i,21:a},{13:20,18:21,20:i,21:a},{16:[1,25],20:[1,23],21:[1,24],23:22},{13:20,18:26,20:i,21:a},e(r,[2,9],{14:[1,27],15:[1,28]}),e(o,[2,43]),e(o,[2,44]),e(r,[2,13],{14:[1,29],15:[1,30],27:s}),e(o,[2,41]),{16:[1,34],20:[1,32],21:[1,33],27:s},e(r,[2,22]),e(r,[2,24],{14:[1,35]}),e(r,[2,25],{14:[1,36]}),e(r,[2,26]),{20:c,25:37,26:38,27:s},e(r,[2,10],{15:[1,40]}),{16:[1,41]},e(r,[2,14],{15:[1,42]}),{16:[1,43]},{13:44,20:i,21:a},e(r,[2,17],{14:[1,45]}),e(r,[2,18],{14:[1,46]}),e(r,[2,19]),e(r,[2,27]),e(r,[2,28]),e(r,[2,23],{27:[1,47]}),e(l,[2,29]),{15:[1,48]},{16:[1,49]},e(r,[2,11]),{16:[1,50]},e(r,[2,15]),e(o,[2,42]),e(r,[2,20]),e(r,[2,21]),{20:c,26:51},{16:u,20:d,21:[1,53],28:52,29:54,30:55,31:f,32:p,33:m},e(r,[2,12]),e(r,[2,16]),e(l,[2,30]),e(l,[2,31]),e(l,[2,32]),e(l,[2,33],{30:61,16:u,20:d,31:f,32:p,33:m}),e(h,[2,34]),e(h,[2,36]),e(h,[2,37]),e(h,[2,38]),e(h,[2,39]),e(h,[2,40]),e(h,[2,35])],defaultActions:{6:[2,1]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};g.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:break;case 3:if(e.getIndentMode&&e.getIndentMode())return e.consumeIndentText=!0,this.begin(`INITIAL`),22;break;case 4:break;case 5:e.setIndentMode&&e.setIndentMode(!1),this.begin(`INITIAL`),this.unput(t.yytext);break;case 6:return this.begin(`bol`),8;case 7:break;case 8:break;case 9:return 7;case 10:return 11;case 11:return 5;case 12:return 12;case 13:return 17;case 14:if(e.consumeIndentText)e.consumeIndentText=!1;else return 19;break;case 15:return 24;case 16:return t.yytext=t.yytext.slice(2,-2),14;case 17:return t.yytext=t.yytext.slice(1,-1).trim(),14;case 18:return 16;case 19:return 31;case 20:return 33;case 21:return 32;case 22:return 20;case 23:return 21;case 24:return 27;case 25:return 15}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[ \t]+(?=[\n\r]))/i,/^(?:[ \t]+(?=text\b))/i,/^(?:[ \t]+)/i,/^(?:[^ \t\n\r])/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:[ \t]+)/i,/^(?:$)/i,/^(?:title\s[^#\n;]+)/i,/^(?:venn-beta\b)/i,/^(?:set\b)/i,/^(?:union\b)/i,/^(?:text\b)/i,/^(?:style\b)/i,/^(?:\["[^\"]*"\])/i,/^(?:\[[^\]\"]+\])/i,/^(?:[+-]?(\d+(\.\d+)?|\.\d+))/i,/^(?:#[0-9a-fA-F]{3,8})/i,/^(?:rgba\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:rgb\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:[A-Za-z_][A-Za-z0-9\-_]*)/i,/^(?:"[^\"]*")/i,/^(?:,)/i,/^(?::)/i],conditions:{bol:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0},INITIAL:{rules:[0,1,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0}}}})();function _(){this.yy={}}return t(_,`Parser`),_.prototype=g,g.Parser=_,new _})();W.parser=W;var Te=W,G=[],K=[],q=[],J=new Set,Y,X=!1,Ee=t((e,t,n)=>{let r=Q(e).sort(),i=n??10/e.length**2;Y=r,r.length===1&&J.add(r[0]),G.push({sets:r,size:i,label:t?Z(t):void 0})},`addSubsetData`),De=t(()=>G,`getSubsetData`),Z=t(e=>{let t=e.trim();return t.length>=2&&t.startsWith(`"`)&&t.endsWith(`"`)?t.slice(1,-1):t},`normalizeText`),Oe=t(e=>e&&Z(e),`normalizeStyleValue`),ke=t((e,t,n)=>{let r=Z(t);K.push({sets:Q(e).sort(),id:r,label:n?Z(n):void 0})},`addTextData`),Ae=t((e,t)=>{let n=Q(e).sort(),r={};for(let[e,n]of t)r[e]=Oe(n)??n;q.push({targets:n,styles:r})},`addStyleData`),je=t(()=>q,`getStyleData`),Q=t(e=>e.map(e=>Z(e)),`normalizeIdentifierList`),Me=t(e=>{let t=Q(e).filter(e=>!J.has(e));if(t.length>0)throw Error(`unknown set identifier: ${t.join(`, `)}`)},`validateUnionIdentifiers`),Ne=t(()=>K,`getTextData`),Pe=t(()=>Y,`getCurrentSets`),Fe=t(()=>X,`getIndentMode`),Ie=t(e=>{X=e},`setIndentMode`),Le=c.venn;function Re(){return g(Le,o().venn)}t(Re,`getConfig`);var ze={getConfig:Re,clear:t(()=>{i(),G.length=0,K.length=0,q.length=0,J.clear(),Y=void 0,X=!1},`customClear`),setAccTitle:r,getAccTitle:h,setDiagramTitle:d,getDiagramTitle:m,getAccDescription:p,setAccDescription:n,addSubsetData:Ee,getSubsetData:De,addTextData:ke,addStyleData:Ae,validateUnionIdentifiers:Me,getTextData:Ne,getStyleData:je,getCurrentSets:Pe,getIndentMode:Fe,setIndentMode:Ie},Be=t(e=>` + .venn-title { + font-size: 32px; + fill: ${e.vennTitleTextColor}; + font-family: ${e.fontFamily}; + } + + .venn-circle text { + font-size: 48px; + font-family: ${e.fontFamily}; + } + + .venn-intersection text { + font-size: 48px; + fill: ${e.vennSetTextColor}; + font-family: ${e.fontFamily}; + } + + .venn-text-node { + font-family: ${e.fontFamily}; + color: ${e.vennSetTextColor}; + } +`,`getStyles`);function Ve(e){let t=new Map;for(let n of e){let e=n.targets.join(`|`),r=t.get(e);r?Object.assign(r,n.styles):t.set(e,{...n.styles})}return t}t(Ve,`buildStyleByKey`);var He=t((t,n,r,i)=>{let c=i.db,l=c.getConfig?.(),{themeVariables:d,look:p,handDrawnSeed:m}=o(),h=p===`handDrawn`,g=[d.venn1,d.venn2,d.venn3,d.venn4,d.venn5,d.venn6,d.venn7,d.venn8].filter(Boolean),b=c.getDiagramTitle?.(),x=c.getSubsetData(),S=c.getTextData(),C=Ve(c.getStyleData()),w=We(x),T=l?.width??800,E=l?.height??450,D=T/1600,O=b?48*D:0,k=d.primaryTextColor??d.textColor,A=v(n);A.attr(`viewBox`,`0 0 ${T} ${E}`),b&&A.append(`text`).text(b).attr(`class`,`venn-title`).attr(`font-size`,`${32*D}px`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).attr(`x`,`50%`).attr(`y`,32*D).style(`fill`,d.vennTitleTextColor||d.titleColor);let j=e(document.createElement(`div`)),M=he().width(T).height(E-O);j.datum(w).call(M);let N=h?_.svg(j.select(`svg`).node()):void 0,P=we(w,{width:T,height:E-O,padding:l?.padding??15}),F=new Map;for(let e of P){let t=$([...e.data.sets].sort());F.set(t,e)}S.length>0&&Ue(l,F,j,S,D,C);let I=a(d.background||`#f4f4f4`);j.selectAll(`.venn-circle`).each(function(t,n){let r=e(this),i=$([...t.sets].sort()),a=C.get(i),o=g.length>0?g[n%g.length]:void 0,s=a?.fill||o||d.primaryColor;r.classed(`venn-set-${n%8}`,!0);let c=a?.[`fill-opacity`]??.1,l=a?.stroke||s,p=a?.[`stroke-width`]||`${5*D}`;if(h&&N){let e=F.get(i);if(e&&e.circles.length>0){let t=e.circles[0],i=N.circle(t.x,t.y,t.radius*2,{roughness:.7,seed:m,fill:y(s,.7),fillStyle:`hachure`,fillWeight:2,hachureGap:8,hachureAngle:-41+n*60,stroke:l,strokeWidth:parseFloat(String(p))});r.select(`path`).remove(),r.node()?.insertBefore(i,r.select(`text`).node())}}else r.select(`path`).style(`fill`,s).style(`fill-opacity`,c).style(`stroke`,l).style(`stroke-width`,p).style(`stroke-opacity`,.95);let _=a?.color||(I?f(s,30):u(s,30));r.select(`text`).style(`font-size`,`${48*D}px`).style(`fill`,_)}),h&&N?j.selectAll(`.venn-intersection`).each(function(t){let n=e(this),r=$([...t.sets].sort()),i=C.get(r),a=i?.fill;if(a){let e=n.select(`path`),t=e.attr(`d`);if(t){let n=N.path(t,{roughness:.7,seed:m,fill:y(a,.3),fillStyle:`cross-hatch`,fillWeight:2,hachureGap:6,hachureAngle:60,stroke:`none`}),r=e.node();r?.parentNode?.insertBefore(n,r),e.remove()}}else n.select(`path`).style(`fill-opacity`,0);n.select(`text`).style(`font-size`,`${48*D}px`).style(`fill`,i?.color??d.vennSetTextColor??k)}):(j.selectAll(`.venn-intersection text`).style(`font-size`,`${48*D}px`).style(`fill`,e=>{let t=$([...e.sets].sort());return C.get(t)?.color??d.vennSetTextColor??k}),j.selectAll(`.venn-intersection path`).style(`fill-opacity`,e=>{let t=$([...e.sets].sort());return+!!C.get(t)?.fill}).style(`fill`,e=>{let t=$([...e.sets].sort());return C.get(t)?.fill??`transparent`}));let L=A.append(`g`).attr(`transform`,`translate(0, ${O})`),R=j.select(`svg`).node();if(R&&`childNodes`in R)for(let e of[...R.childNodes])L.node()?.appendChild(e);s(A,E,T,l?.useMaxWidth??!0)},`draw`);function $(e){return e.join(`|`)}t($,`stableSetsKey`);function Ue(e,t,n,r,i,a){let o=e?.useDebugLayout??!1,s=n.select(`svg`).append(`g`).attr(`class`,`venn-text-nodes`),c=new Map;for(let e of r){let t=$(e.sets),n=c.get(t);n?n.push(e):c.set(t,[e])}for(let[e,n]of c.entries()){let r=t.get(e);if(!r?.text)continue;let c=r.text.x,l=r.text.y,u=Math.min(...r.circles.map(e=>e.radius)),d=Math.min(...r.circles.map(e=>e.radius-Math.hypot(c-e.x,l-e.y))),f=Number.isFinite(d)?Math.max(0,d):0;f===0&&Number.isFinite(u)&&(f=u*.6);let p=s.append(`g`).attr(`class`,`venn-text-area`).attr(`font-size`,`${40*i}px`);o&&p.append(`circle`).attr(`class`,`venn-text-debug-circle`).attr(`cx`,c).attr(`cy`,l).attr(`r`,f).attr(`fill`,`none`).attr(`stroke`,`purple`).attr(`stroke-width`,1.5*i).attr(`stroke-dasharray`,`${6*i} ${4*i}`);let m=Math.max(80*i,f*2*.95),h=Math.max(60*i,f*2*.95),g=(r.data.label&&r.data.label.length>0?Math.min(32*i,f*.25):0)+(n.length<=2?30*i:0),_=c-m/2,v=l-h/2+g,y=Math.max(1,Math.ceil(Math.sqrt(n.length))),b=Math.max(1,Math.ceil(n.length/y)),x=m/y,S=h/b;for(let[e,t]of n.entries()){let n=e%y,r=Math.floor(e/y),s=_+x*(n+.5),c=v+S*(r+.5);o&&p.append(`rect`).attr(`class`,`venn-text-debug-cell`).attr(`x`,_+x*n).attr(`y`,v+S*r).attr(`width`,x).attr(`height`,S).attr(`fill`,`none`).attr(`stroke`,`teal`).attr(`stroke-width`,1*i).attr(`stroke-dasharray`,`${4*i} ${3*i}`);let l=x*.9,u=S*.9,d=p.append(`foreignObject`).attr(`class`,`venn-text-node-fo`).attr(`width`,l).attr(`height`,u).attr(`x`,s-l/2).attr(`y`,c-u/2).attr(`overflow`,`visible`),f=a.get(t.id)?.color,m=d.append(`xhtml:span`).attr(`class`,`venn-text-node`).style(`display`,`flex`).style(`width`,`100%`).style(`height`,`100%`).style(`white-space`,`normal`).style(`align-items`,`center`).style(`justify-content`,`center`).style(`text-align`,`center`).style(`overflow-wrap`,`normal`).style(`word-break`,`normal`).text(t.label??t.id);f&&m.style(`color`,f)}}}t(Ue,`renderTextNodes`);function We(e){let t=new Set(e.map(e=>[...e.sets].sort().join(`|`))),n=new Map(e.filter(e=>e.sets.length===1&&e.size!==void 0).map(e=>[e.sets[0],e.size])),r=[];for(let i of e){if(i.sets.length<3)continue;let e=[...i.sets].sort();for(let i=0;i0?[...e,...r]:e}t(We,`ensurePairwiseSubsets`);var Ge={parser:Te,db:ze,renderer:{draw:He},styles:Be};export{Ge as diagram}; \ No newline at end of file diff --git a/www/assets/wardley-WFR3VGLG-kIjJw24i.js b/www/assets/wardley-WFR3VGLG-kIjJw24i.js new file mode 100644 index 0000000..55593b0 --- /dev/null +++ b/www/assets/wardley-WFR3VGLG-kIjJw24i.js @@ -0,0 +1 @@ +import"./chunk-FOHPRMQF-DHwB1DNv.js";import{i as e}from"./mermaid-parser.core-CUrDj5TF.js";export{e as createWardleyServices}; \ No newline at end of file diff --git a/www/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js b/www/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js new file mode 100644 index 0000000..2678b0a --- /dev/null +++ b/www/assets/wardleyDiagram-VNRHLVJA-DPtbrmxX.js @@ -0,0 +1,78 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,q as c,v as l,w as u,x as d,y as f}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{i as p}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{y as m}from"./index-DoQkmpth.js";import{n as h}from"./mermaid-parser.core-CUrDj5TF.js";import{t as g}from"./chunk-JWPE2WC7-DVXcaiue.js";var _=t((e,t)=>{let n=e<=1?e*100:e;if(n<0||n>100)throw Error(`${t} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${e}`);return n},`toPercent`),v=t((e,t,n)=>({x:_(t,`${n} evolution`),y:_(e,`${n} visibility`)}),`toCoordinates`),y=t(e=>{if(e){if(e===`+<>`)return`bidirectional`;if(e===`+<`)return`backward`;if(e===`+>`)return`forward`}},`getFlowFromPort`),b=t(e=>{if(!e?.startsWith(`+`))return{};let t=/^\+'([^']*)'/.exec(e)?.[1];return e.includes(`<>`)?{flow:`bidirectional`,label:t}:e.includes(`<`)?{flow:`backward`,label:t}:e.includes(`>`)?{flow:`forward`,label:t}:{label:t}},`extractFlowFromArrow`),x=t((e,t)=>{if(g(e,t),e.size&&t.setSize(e.size.width,e.size.height),e.evolution){let n=e.evolution.stages.map(e=>e.secondName?`${e.name.trim()} / ${e.secondName.trim()}`:e.name.trim()),r=e.evolution.stages.filter(e=>e.boundary!==void 0).map(e=>e.boundary);t.updateAxes({stages:n,stageBoundaries:r})}if(e.anchors.forEach(e=>{let n=v(e.visibility,e.evolution,`Anchor "${e.name}"`);t.addNode(e.name,e.name,n.x,n.y,`anchor`)}),e.components.forEach(e=>{let n=v(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,i=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,a=e.decorator?.strategy;t.addNode(e.name,e.name,n.x,n.y,`component`,r,i,e.inertia,a)}),e.notes.forEach(e=>{let n=v(e.visibility,e.evolution,`Note "${e.text}"`);t.addNote(e.text,n.x,n.y)}),e.pipelines.forEach(e=>{let n=t.getNode(e.parent);if(!n||typeof n.y!=`number`)throw Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);let r=n.y;t.startPipeline(e.parent),e.components.forEach(n=>{let i=`${e.parent}_${n.name}`,a=n.label?(n.label.negX?-1:1)*n.label.offsetX:void 0,o=n.label?(n.label.negY?-1:1)*n.label.offsetY:void 0,s=_(n.evolution,`Pipeline component "${n.name}" evolution`);t.addNode(i,n.name,s,r,`pipeline-component`,a,o),t.addPipelineComponent(e.parent,i)})}),e.links.forEach(e=>{let n=!!e.arrow&&(e.arrow.includes(`-.->`)||e.arrow.includes(`.-.`)),r=y(e.fromPort)??y(e.toPort),{flow:i,label:a}=b(e.arrow);!r&&i&&(r=i);let o=e.linkLabel,s=a??o;t.addLink(t.resolveNodeId(e.from),t.resolveNodeId(e.to),n,s,r)}),e.evolves.forEach(e=>{let n=t.getNode(e.component);if(n?.y!==void 0){let r=_(e.target,`Evolve target for "${e.component}"`);t.addTrend(e.component,r,n.y)}}),e.annotations.length>0){let n=e.annotations[0],r=v(n.x,n.y,`Annotations box`);t.setAnnotationsBox(r.x,r.y)}e.annotation.forEach(e=>{let n=v(e.x,e.y,`Annotation ${e.number}`);t.addAnnotation(e.number,[{x:n.x,y:n.y}],e.text)}),e.accelerators.forEach(e=>{let n=v(e.x,e.y,`Accelerator "${e.name}"`);t.addAccelerator(e.name,n.x,n.y)}),e.deaccelerators.forEach(e=>{let n=v(e.x,e.y,`Deaccelerator "${e.name}"`);t.addDeaccelerator(e.name,n.x,n.y)})},`populateDb`),S={parser:{yy:void 0},parse:t(async t=>{let n=await h(`wardley`,t);e.debug(n);let r=S.parser?.yy;if(!r||typeof r.addNode!=`function`)throw Error(`parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);x(n,r)},`parse`)},C=new class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}static{t(this,`WardleyBuilder`)}addNode(e){let t=this.nodes.get(e.id)??{id:e.id,label:e.label},n={...t,...e,className:e.className??t.className,labelOffsetX:e.labelOffsetX??t.labelOffsetX,labelOffsetY:e.labelOffsetY??t.labelOffsetY};this.nodes.set(e.id,n)}addLink(e){this.links.push(e)}addTrend(e){this.trends.set(e.nodeId,e)}startPipeline(e){this.pipelines.set(e,{nodeId:e,componentIds:[]});let t=this.nodes.get(e);t&&(t.isPipelineParent=!0)}addPipelineComponent(e,t){let n=this.pipelines.get(e);n&&n.componentIds.push(t);let r=this.nodes.get(t);r&&(r.inPipeline=!0)}addAnnotation(e){this.annotations.push(e)}addNote(e){this.notes.push(e)}addAccelerator(e){this.accelerators.push(e)}addDeaccelerator(e){this.deaccelerators.push(e)}setAnnotationsBox(e,t){this.annotationsBox={x:e,y:t}}setAxes(e){this.axes={...this.axes,...e}}setSize(e,t){this.size={width:e,height:t}}getNode(e){return this.nodes.get(e)}resolveNodeId(e){if(this.nodes.has(e))return e;for(let[t,n]of this.nodes)if(n.label===e)return t;return e}build(){let e=[];for(let t of this.nodes.values()){if(typeof t.x!=`number`||typeof t.y!=`number`)throw Error(`Node "${t.label}" is missing coordinates`);e.push(t)}return{nodes:e,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}};function w(){return d()[`wardley-beta`]}t(w,`getConfig`);function T(e,t,n,r,i,a,o,s,c){C.addNode({id:e,label:t,x:n,y:r,className:i,labelOffsetX:a,labelOffsetY:o,inertia:s,sourceStrategy:c})}t(T,`addNode`);function E(e,t,n=!1,r,i){C.addLink({source:e,target:t,dashed:n,label:r,flow:i})}t(E,`addLink`);function D(e,t,n){C.addTrend({nodeId:e,targetX:t,targetY:n})}t(D,`addTrend`);function O(e,t,n){C.addAnnotation({number:e,coordinates:t,text:n})}t(O,`addAnnotation`);function k(e,t,n){C.addNote({text:e,x:t,y:n})}t(k,`addNote`);function A(e,t,n){C.addAccelerator({name:e,x:t,y:n})}t(A,`addAccelerator`);function j(e,t,n){C.addDeaccelerator({name:e,x:t,y:n})}t(j,`addDeaccelerator`);function M(e,t){C.setAnnotationsBox(e,t)}t(M,`setAnnotationsBox`);function N(e,t){C.setSize(e,t)}t(N,`setSize`);function P(e){C.startPipeline(e)}t(P,`startPipeline`);function F(e,t){C.addPipelineComponent(e,t)}t(F,`addPipelineComponent`);function I(e){C.setAxes(e)}t(I,`updateAxes`);function L(e){return C.getNode(e)}t(L,`getNode`);function R(e){return C.resolveNodeId(e)}t(R,`resolveNodeId`);function z(){return C.build()}t(z,`getWardleyData`);function B(){C.clear(),a()}t(B,`clear`);var V={getConfig:w,addNode:T,addLink:E,addTrend:D,addAnnotation:O,addNote:k,addAccelerator:A,addDeaccelerator:j,setAnnotationsBox:M,setSize:N,startPipeline:P,addPipelineComponent:F,updateAxes:I,getNode:L,resolveNodeId:R,getWardleyData:z,clear:B,setAccTitle:i,getAccTitle:f,setDiagramTitle:c,getDiagramTitle:u,getAccDescription:l,setAccDescription:r},H=[`Genesis`,`Custom Built`,`Product`,`Commodity`],U=t(()=>{let{themeVariables:e}=d();return{backgroundColor:e.wardley?.backgroundColor??e.background??`#fff`,axisColor:e.wardley?.axisColor??`#000`,axisTextColor:e.wardley?.axisTextColor??e.primaryTextColor??`#222`,gridColor:e.wardley?.gridColor??`rgba(100, 100, 100, 0.2)`,componentFill:e.wardley?.componentFill??`#fff`,componentStroke:e.wardley?.componentStroke??`#000`,componentLabelColor:e.wardley?.componentLabelColor??e.primaryTextColor??`#222`,linkStroke:e.wardley?.linkStroke??`#000`,evolutionStroke:e.wardley?.evolutionStroke??`#dc3545`,annotationStroke:e.wardley?.annotationStroke??`#000`,annotationTextColor:e.wardley?.annotationTextColor??e.primaryTextColor??`#222`,annotationFill:e.wardley?.annotationFill??e.background??`#fff`}},`getTheme`),W=t(()=>{let e=d()[`wardley-beta`];return{width:e?.width??900,height:e?.height??600,padding:e?.padding??48,nodeRadius:e?.nodeRadius??6,nodeLabelOffset:e?.nodeLabelOffset??8,axisFontSize:e?.axisFontSize??12,labelFontSize:e?.labelFontSize??10,showGrid:e?.showGrid??!1,useMaxWidth:e?.useMaxWidth??!0}},`getConfigValues`),G={parser:S,db:V,renderer:{draw:t((n,r,i,a)=>{e.debug(`Rendering Wardley map +`+n);let o=W(),c=U(),l=o.nodeRadius*1.6,u=a.db,d=u.getWardleyData(),f=u.getDiagramTitle(),p=d.size?.width??o.width,h=d.size?.height??o.height,g=m(r);g.selectAll(`*`).remove(),s(g,h,p,o.useMaxWidth),g.attr(`viewBox`,`0 0 ${p} ${h}`);let _=g.append(`g`).attr(`class`,`wardley-map`),v=g.append(`defs`);v.append(`marker`).attr(`id`,`arrow-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,c.evolutionStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-end-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,c.linkStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-start-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,1).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 z`).attr(`fill`,c.linkStroke).attr(`stroke`,`none`),_.append(`rect`).attr(`class`,`wardley-background`).attr(`width`,p).attr(`height`,h).attr(`fill`,c.backgroundColor);let y=p-o.padding*2,b=h-o.padding*2;f&&_.append(`text`).attr(`class`,`wardley-title`).attr(`x`,p/2).attr(`y`,o.padding/2).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize*1.05).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(f);let x=t(e=>o.padding+e/100*y,`projectX`),S=t(e=>h-o.padding-e/100*b,`projectY`),C=_.append(`g`).attr(`class`,`wardley-axes`);C.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.axisColor).attr(`stroke-width`,1),C.append(`line`).attr(`x1`,o.padding).attr(`x2`,o.padding).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.axisColor).attr(`stroke-width`,1);let w=d.axes.xLabel??`Evolution`,T=d.axes.yLabel??`Visibility`;C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-x`).attr(`x`,o.padding+y/2).attr(`y`,h-o.padding/4).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).text(w),C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-y`).attr(`x`,o.padding/3).attr(`y`,o.padding+b/2).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`transform`,`rotate(-90 ${o.padding/3} ${o.padding+b/2})`).text(T);let E=d.axes.stages&&d.axes.stages.length>0?d.axes.stages:H;if(E.length>0){let e=_.append(`g`).attr(`class`,`wardley-stages`),t=d.axes.stageBoundaries,n=[];if(t&&t.length===E.length){let e=0;t.forEach(t=>{n.push({start:e,end:t}),e=t})}else{let e=1/E.length;E.forEach((t,r)=>{n.push({start:r*e,end:(r+1)*e})})}E.forEach((t,r)=>{let i=n[r],a=o.padding+i.start*y,s=(a+(o.padding+i.end*y))/2;r>0&&e.append(`line`).attr(`x1`,a).attr(`x2`,a).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,`#000`).attr(`stroke-width`,1).attr(`stroke-dasharray`,`5 5`).attr(`opacity`,.8),e.append(`text`).attr(`class`,`wardley-stage-label`).attr(`x`,s).attr(`y`,h-o.padding/1.5).attr(`fill`,c.axisTextColor).attr(`font-size`,o.axisFontSize-2).attr(`text-anchor`,`middle`).text(t)})}if(o.showGrid){let e=_.append(`g`).attr(`class`,`wardley-grid`);for(let t=1;t<4;t++){let n=t/4,r=o.padding+y*n;e.append(`line`).attr(`x1`,r).attr(`x2`,r).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,c.gridColor).attr(`stroke-dasharray`,`2 6`),e.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding-b*n).attr(`y2`,h-o.padding-b*n).attr(`stroke`,c.gridColor).attr(`stroke-dasharray`,`2 6`)}}let D=new Map;if(d.nodes.forEach(e=>{D.set(e.id,{x:x(e.x),y:S(e.y),node:e})}),d.pipelines.length>0){let e=_.append(`g`).attr(`class`,`wardley-pipelines`),t=_.append(`g`).attr(`class`,`wardley-pipeline-links`);d.pipelines.forEach(n=>{if(n.componentIds.length===0)return;let r=n.componentIds.map(e=>({id:e,pos:D.get(e),node:d.nodes.find(t=>t.id===e)})).filter(e=>e.pos&&e.node).sort((e,t)=>e.node.x-t.node.x);for(let e=0;e{let t=D.get(e);t&&(i=Math.min(i,t.x),a=Math.max(a,t.x),s=t.y)}),i!==1/0&&a!==-1/0){let t=o.nodeRadius*4,r=s-t/2,u=D.get(n.nodeId);u&&(u.x=(i+a)/2,u.y=r-l/6),e.append(`rect`).attr(`class`,`wardley-pipeline-box`).attr(`x`,i-15).attr(`y`,r).attr(`width`,a-i+30).attr(`height`,t).attr(`fill`,`none`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}})}let O=_.append(`g`).attr(`class`,`wardley-links`),k=new Map;d.pipelines.forEach(e=>{k.set(e.nodeId,new Set(e.componentIds))});let A=d.links.filter(e=>!(!D.has(e.source)||!D.has(e.target)||k.get(e.target)?.has(e.source)));O.selectAll(`line`).data(A).enter().append(`line`).attr(`class`,e=>`wardley-link${e.dashed?` wardley-link--dashed`:``}`).attr(`x1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.x+i/s*r}).attr(`y1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.y+a/s*r}).attr(`x2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.x+i/s*r}).attr(`y2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.y+a/s*r}).attr(`stroke`,c.linkStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,e=>e.dashed?`6 6`:null).attr(`marker-end`,e=>e.flow===`forward`||e.flow===`bidirectional`?`url(#link-arrow-end-${r})`:null).attr(`marker-start`,e=>e.flow===`backward`||e.flow===`bidirectional`?`url(#link-arrow-start-${r})`:null),O.selectAll(`text`).data(A.filter(e=>e.label)).enter().append(`text`).attr(`class`,`wardley-link-label`).attr(`x`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=n.y-t.y,a=n.x-t.x;return r+i/Math.sqrt(a*a+i*i)*8}).attr(`y`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.y+n.y)/2,i=n.x-t.x,a=n.y-t.y,o=Math.sqrt(i*i+a*a);return r+-i/o*8}).attr(`fill`,c.axisTextColor).attr(`font-size`,o.labelFontSize).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).attr(`transform`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=(t.y+n.y)/2,a=n.x-t.x,o=n.y-t.y,s=Math.sqrt(a*a+o*o),c=o/s,l=-a/s,u=r+c*8,d=i+l*8,f=Math.atan2(o,a)*180/Math.PI;return(f>90||f<-90)&&(f+=180),`rotate(${f} ${u} ${d})`}).text(e=>e.label);let j=_.append(`g`).attr(`class`,`wardley-trends`),M=d.trends.map(e=>{let t=D.get(e.nodeId);if(!t)return null;let n=x(e.targetX),r=S(e.targetY),i=n-t.x,a=r-t.y,s=Math.sqrt(i*i+a*a),c=o.nodeRadius+2;return{origin:t,targetX:n,targetY:r,adjustedX2:s>c?n-i/s*c:n,adjustedY2:s>c?r-a/s*c:r}}).filter(e=>e!==null);j.selectAll(`line`).data(M).enter().append(`line`).attr(`class`,`wardley-trend`).attr(`x1`,e=>e.origin.x).attr(`y1`,e=>e.origin.y).attr(`x2`,e=>e.adjustedX2).attr(`y2`,e=>e.adjustedY2).attr(`stroke`,c.evolutionStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,`4 4`).attr(`marker-end`,`url(#arrow-${r})`);let N=_.append(`g`).attr(`class`,`wardley-nodes`).selectAll(`g`).data(d.nodes).enter().append(`g`).attr(`class`,e=>[`wardley-node`,e.className?`wardley-node--${e.className}`:``].filter(Boolean).join(` `));N.filter(e=>e.sourceStrategy===`outsource`).append(`circle`).attr(`class`,`wardley-outsource-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#666`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`buy`).append(`circle`).attr(`class`,`wardley-buy-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#ccc`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`build`).append(`circle`).attr(`class`,`wardley-build-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#eee`).attr(`stroke`,`#000`).attr(`stroke-width`,1);let P=N.filter(e=>e.sourceStrategy===`market`);P.append(`circle`).attr(`class`,`wardley-market-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>!e.isPipelineParent&&e.sourceStrategy!==`market`&&e.className!==`anchor`).append(`circle`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius).attr(`fill`,c.componentFill).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1);let F=o.nodeRadius*.7,I=o.nodeRadius*1.2;if(P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x).attr(`y1`,e=>D.get(e.id).y-I).attr(`x2`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x).attr(`y2`,e=>D.get(e.id).y-I).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y-I).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,2),N.filter(e=>e.isPipelineParent===!0).append(`rect`).attr(`x`,e=>D.get(e.id).x-l/2).attr(`y`,e=>D.get(e.id).y-l/2).attr(`width`,l).attr(`height`,l).attr(`fill`,c.componentFill).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.inertia===!0).append(`line`).attr(`class`,`wardley-inertia`).attr(`x1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y-n/2}).attr(`x2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y+n/2}).attr(`stroke`,c.componentStroke).attr(`stroke-width`,6),N.append(`text`).attr(`x`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetX===void 0?t.x:t.x+e.labelOffsetX;let n=o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetX===void 0&&(n+=10);let r=e.labelOffsetX??n;return t.x+r}).attr(`y`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetY===void 0?t.y-3:t.y+e.labelOffsetY;let n=-o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetY===void 0&&(n-=10);let r=e.labelOffsetY??n;return t.y+r}).attr(`class`,`wardley-node-label`).attr(`fill`,e=>e.className===`evolved`?c.evolutionStroke:e.className===`anchor`?`#000`:c.componentLabelColor).attr(`font-size`,o.labelFontSize).attr(`font-weight`,e=>e.className===`anchor`?`bold`:`normal`).attr(`text-anchor`,e=>e.className===`anchor`?`middle`:`start`).attr(`dominant-baseline`,e=>e.className===`anchor`?`middle`:`auto`).text(e=>e.label),d.annotations.length>0){let e=_.append(`g`).attr(`class`,`wardley-annotations`);if(d.annotations.forEach(t=>{let n=t.coordinates.map(e=>({x:x(e.x),y:S(e.y)}));if(n.length>1)for(let t=0;t{let r=e.append(`g`).attr(`class`,`wardley-annotation`);r.append(`circle`).attr(`cx`,n.x).attr(`cy`,n.y).attr(`r`,10).attr(`fill`,`white`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5),r.append(`text`).attr(`x`,n.x).attr(`y`,n.y).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.number)})}),d.annotationsBox){let t=x(d.annotationsBox.x),n=S(d.annotationsBox.y),r=e.append(`g`).attr(`class`,`wardley-annotations-box`),i=[...d.annotations].filter(e=>e.text).sort((e,t)=>e.number-t.number),a=[];if(i.forEach((e,i)=>{let o=r.append(`text`).attr(`x`,t+10).attr(`y`,n+10+(i+1)*16).attr(`font-size`,11).attr(`fill`,c.axisTextColor).attr(`text-anchor`,`start`).attr(`dominant-baseline`,`middle`).text(`${e.number}. ${e.text}`);a.push(o)}),a.length>0){let e=0,s=0;a.forEach(t=>{let n=t.node(),r=n.getComputedTextLength();e=Math.max(e,r);let i=n.getBBox();s=Math.max(s,i.height)});let l=e+20+105,u=i.length*16+20+s/2,d=o.padding,f=p-o.padding-l,m=o.padding,g=h-o.padding-u;t=Math.max(d,Math.min(t,f)),n=Math.max(m,Math.min(n,g)),a.forEach((e,r)=>{e.attr(`x`,t+10).attr(`y`,n+10+(r+1)*16)}),r.insert(`rect`,`text`).attr(`x`,t).attr(`y`,n).attr(`width`,l).attr(`height`,u).attr(`fill`,`white`).attr(`stroke`,c.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}}}if(d.notes.length>0){let e=_.append(`g`).attr(`class`,`wardley-notes`);d.notes.forEach(t=>{let n=x(t.x),r=S(t.y);e.append(`text`).attr(`x`,n).attr(`y`,r).attr(`text-anchor`,`start`).attr(`font-size`,11).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.text)})}if(d.accelerators.length>0){let e=_.append(`g`).attr(`class`,`wardley-accelerators`);d.accelerators.forEach(t=>{let n=x(t.x),r=S(t.y),i=` + M ${n} ${r-15} + L ${n+60-20} ${r-15} + L ${n+60-20} ${r-15-8} + L ${n+60} ${r} + L ${n+60-20} ${r+15+8} + L ${n+60-20} ${r+15} + L ${n} ${r+15} + Z + `;e.append(`path`).attr(`d`,i).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),e.append(`text`).attr(`x`,n+30).attr(`y`,r+15+15).attr(`text-anchor`,`middle`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.name)})}if(d.deaccelerators.length>0){let e=_.append(`g`).attr(`class`,`wardley-deaccelerators`);d.deaccelerators.forEach(t=>{let n=x(t.x),r=S(t.y),i=` + M ${n+60} ${r-15} + L ${n+20} ${r-15} + L ${n+20} ${r-15-8} + L ${n} ${r} + L ${n+20} ${r+15+8} + L ${n+20} ${r+15} + L ${n+60} ${r+15} + Z + `;e.append(`path`).attr(`d`,i).attr(`fill`,`white`).attr(`stroke`,c.componentStroke).attr(`stroke-width`,1),e.append(`text`).attr(`x`,n+30).attr(`y`,r+15+15).attr(`text-anchor`,`middle`).attr(`font-size`,10).attr(`fill`,c.axisTextColor).attr(`font-weight`,`bold`).text(t.name)})}},`draw`)},styles:t(({wardley:e}={})=>{let t=n(),r=o(),i=p(t,r.themeVariables),a=p(i.wardley,e);return` + .wardley-background { + fill: ${a.backgroundColor}; + } + .wardley-axes line, .wardley-axes path { + stroke: ${a.axisColor}; + } + .wardley-axis-label { + fill: ${a.axisTextColor}; + } + .wardley-stage-label { + fill: ${a.axisTextColor}; + } + .wardley-grid line { + stroke: ${a.gridColor}; + } + .wardley-node circle { + fill: ${a.componentFill}; + stroke: ${a.componentStroke}; + } + .wardley-node-label { + fill: ${a.componentLabelColor}; + } + .wardley-link { + stroke: ${a.linkStroke}; + } + .wardley-link--dashed { + stroke-dasharray: 4 4; + } + .wardley-link-label { + fill: ${a.axisTextColor}; + } + .wardley-trend line { + stroke: ${a.evolutionStroke}; + } + .wardley-annotation-line { + stroke: ${a.annotationStroke}; + } + .wardley-annotation circle { + fill: ${a.annotationFill}; + stroke: ${a.annotationStroke}; + } + .wardley-annotation text { + fill: ${a.annotationTextColor}; + } + .wardley-annotations-box rect { + fill: ${a.annotationFill}; + stroke: ${a.annotationStroke}; + } + .wardley-annotations-box text { + fill: ${a.annotationTextColor}; + } + .wardley-pipeline-box { + stroke: ${a.componentStroke}; + } + .wardley-notes text { + fill: ${a.axisTextColor}; + } + `},`styles`)};export{G as diagram}; \ No newline at end of file diff --git a/www/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js b/www/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js new file mode 100644 index 0000000..30a667f --- /dev/null +++ b/www/assets/xychartDiagram-PMCCYNJV-BE8PLguK.js @@ -0,0 +1,7 @@ +import{m as e}from"./src-D_iIdUkB.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{D as n,H as r,U as i,a,b as o,c as s,f as c,q as l,v as u,w as d,y as f,z as p}from"./chunk-O7XYJQB3-Bce2lzyF.js";import{t as m}from"./linear-CZ6dxGrP.js";import{t as h}from"./ordinal-BDEzSJ7C.js";import{t as g}from"./init-C-OQMol4.js";import{i as _}from"./chunk-ZIGJFQKS-BJ6myxnF.js";import{t as v}from"./line-gOgo9JIs.js";import"./chunk-742MDFTN-5mFByRwZ.js";import{t as y}from"./chunk-MBY4JIJT-CGQ6Fu8G.js";import{y as b}from"./index-DoQkmpth.js";function x(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,a=Array(i);++rf&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`: +`+h.showPosition()+` +Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};A.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+` +`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;at[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return this.popState(),36;case 3:return this.popState(),36;case 4:return 36;case 5:break;case 6:return 10;case 7:return this.pushState(`acc_title`),19;case 8:return this.popState(),`acc_title_value`;case 9:return this.pushState(`acc_descr`),21;case 10:return this.popState(),`acc_descr_value`;case 11:this.pushState(`acc_descr_multiline`);break;case 12:this.popState();break;case 13:return`acc_descr_multiline_value`;case 14:return 5;case 15:return 5;case 16:return 8;case 17:return this.pushState(`axis_data`),`X_AXIS`;case 18:return this.pushState(`axis_data`),`Y_AXIS`;case 19:return this.pushState(`axis_band_data`),24;case 20:return 33;case 21:return this.pushState(`data`),16;case 22:return this.pushState(`data`),18;case 23:return this.pushState(`data_inner`),24;case 24:return 29;case 25:return this.popState(),26;case 26:this.popState();break;case 27:this.pushState(`string`);break;case 28:this.popState();break;case 29:return`STR`;case 30:return 24;case 31:return 26;case 32:return 44;case 33:return`COLON`;case 34:return 45;case 35:return 28;case 36:return 46;case 37:return 47;case 38:return 49;case 39:return 51;case 40:return 48;case 41:return 42;case 42:return 50;case 43:return 43;case 44:break;case 45:return 37;case 46:return 38}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}}})();function j(){this.yy={}}return t(j,`Parser`),j.prototype=A,A.Parser=j,new j})();C.parser=C;var w=C;function T(e){return e.type===`bar`}t(T,`isBarPlot`);function E(e){return e.type===`band`}t(E,`isBandAxisData`);function D(e){return e.type===`linear`}t(D,`isLinearAxisData`);var O=class{constructor(e){this.parentGroup=e}static{t(this,`TextDimensionCalculatorWithFont`)}getMaxDimension(e,t){if(!this.parentGroup)return{width:e.reduce((e,t)=>Math.max(t.length,e),0)*t,height:t};let n={width:0,height:0},r=this.parentGroup.append(`g`).attr(`visibility`,`hidden`).attr(`font-size`,t);for(let i of e){let e=y(r,1,i),a=e?e.width:i.length*t,o=e?e.height:t;n.width=Math.max(n.width,a),n.height=Math.max(n.height,o)}return r.remove(),n}},k=.7,A=.2,j=class{constructor(e,t,n,r){this.axisConfig=e,this.title=t,this.textDimensionCalculator=n,this.axisThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition=`left`,this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.normalizedLabelRotationInRad=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition=`left`,this.normalizedLabelRotationInRad=this.axisConfig.labelRotation>=-90&&this.axisConfig.labelRotation<=90?this.axisConfig.labelRotation*Math.PI/180:0}static{t(this,`BaseAxis`)}setRange(e){this.range=e,this.axisPosition===`left`||this.axisPosition===`right`?this.boundingRect.height=e[1]-e[0]:this.boundingRect.width=e[1]-e[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(e){this.axisPosition=e,this.setRange(this.range)}getTickDistance(){let e=this.getRange();return Math.abs(e[0]-e[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(e=>e.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){k*this.getTickDistance()>this.outerPadding*2&&(this.outerPadding=Math.floor(k*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(e){let t=e.height;if(this.axisConfig.showAxisLine&&t>this.axisConfig.axisLineWidth&&(t-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let n=this.getLabelDimension(),r=A*e.width;this.outerPadding=Math.min(n.width/2,r);let i=n.height;this.axisPosition===`bottom`&&this.normalizedLabelRotationInRad!==0&&(i=Math.max(i,Math.abs(Math.sin(this.normalizedLabelRotationInRad)*n.width)+Math.abs(Math.cos(this.normalizedLabelRotationInRad)*n.height))),i+=this.axisConfig.labelPadding*2,this.labelTextHeight=n.height,i<=t&&(t-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&t>=this.axisConfig.tickLength&&(this.showTick=!0,t-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let e=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=e.height+this.axisConfig.titlePadding*2;this.titleTextHeight=e.height,n<=t&&(t-=n,this.showTitle=!0)}this.boundingRect.width=e.width,this.boundingRect.height=e.height-t}calculateSpaceIfDrawnVertical(e){let t=e.width;if(this.axisConfig.showAxisLine&&t>this.axisConfig.axisLineWidth&&(t-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let n=this.getLabelDimension(),r=A*e.height;this.outerPadding=Math.min(n.height/2,r);let i=n.width+this.axisConfig.labelPadding*2;i<=t&&(t-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&t>=this.axisConfig.tickLength&&(this.showTick=!0,t-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let e=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=e.height+this.axisConfig.titlePadding*2;this.titleTextHeight=e.height,n<=t&&(t-=n,this.showTitle=!0)}this.boundingRect.width=e.width-t,this.boundingRect.height=e.height}calculateSpace(e){return this.axisPosition===`left`||this.axisPosition===`right`?this.calculateSpaceIfDrawnVertical(e):this.calculateSpaceIfDrawnHorizontally(e),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateOffsetByRotation(e){let t=this.normalizedLabelRotationInRad;return t===0?0:Math.sin(t)*this.getLabelDimension()[e]/2}getDrawableElementsForLeftAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`left-axis`,`axisl-line`],data:[{path:`M ${t},${this.boundingRect.y} L ${t},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`left-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(e),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:`middle`,horizontalPos:`right`}))}),this.showTick){let t=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);e.push({type:`path`,groupTexts:[`left-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${t},${this.getScaleValue(e)} L ${t-this.axisConfig.tickLength},${this.getScaleValue(e)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`left-axis`,`title`],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElementsForBottomAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.y+this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`bottom-axis`,`axis-line`],data:[{path:`M ${this.boundingRect.x},${t} L ${this.boundingRect.x+this.boundingRect.width},${t}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`bottom-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e)+this.calculateOffsetByRotation(`height`),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0)+Math.abs(this.calculateOffsetByRotation(`width`)),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:this.normalizedLabelRotationInRad*180/Math.PI,verticalPos:`top`,horizontalPos:`center`}))}),this.showTick){let t=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);e.push({type:`path`,groupTexts:[`bottom-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${this.getScaleValue(e)},${t} L ${this.getScaleValue(e)},${t+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`bottom-axis`,`title`],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElementsForTopAxis(){let e=[];if(this.showAxisLine){let t=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;e.push({type:`path`,groupTexts:[`top-axis`,`axis-line`],data:[{path:`M ${this.boundingRect.x},${t} L ${this.boundingRect.x+this.boundingRect.width},${t}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&e.push({type:`text`,groupTexts:[`top-axis`,`label`],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+this.axisConfig.titlePadding*2:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}))}),this.showTick){let t=this.boundingRect.y;e.push({type:`path`,groupTexts:[`top-axis`,`ticks`],data:this.getTickValues().map(e=>({path:`M ${this.getScaleValue(e)},${t+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(e)},${t+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&e.push({type:`text`,groupTexts:[`top-axis`,`title`],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:`top`,horizontalPos:`center`}]}),e}getDrawableElements(){if(this.axisPosition===`left`)return this.getDrawableElementsForLeftAxis();if(this.axisPosition===`right`)throw Error(`Drawing of right axis is not implemented`);return this.axisPosition===`bottom`?this.getDrawableElementsForBottomAxis():this.axisPosition===`top`?this.getDrawableElementsForTopAxis():[]}},M=class extends j{static{t(this,`BandAxis`)}constructor(e,t,n,r,i){super(e,r,i,t),this.categories=n,this.scale=S().domain(this.categories).range(this.getRange())}setRange(e){super.setRange(e)}recalculateScale(){this.scale=S().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),e.trace(`BandAxis axis final categories, range: `,this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(e){return this.scale(e)??this.getRange()[0]}},ee=class extends j{static{t(this,`LinearAxis`)}constructor(e,t,n,r,i){super(e,r,i,t),this.domain=n,this.scale=m().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){let e=[...this.domain];this.axisPosition===`left`&&e.reverse(),this.scale=m().domain(e).range(this.getRange())}getScaleValue(e){return this.scale(e)}};function N(e,t,n,r){let i=new O(r);return E(e)?new M(t,n,e.categories,e.title,i):new ee(t,n,[e.min,e.max],e.title,i)}t(N,`getAxis`);var te=class{constructor(e,t,n,r){this.textDimensionCalculator=e,this.chartConfig=t,this.chartData=n,this.chartThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{t(this,`ChartTitle`)}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){let t=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),n=Math.max(t.width,e.width),r=t.height+2*this.chartConfig.titlePadding;return t.width<=n&&t.height<=r&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=n,this.boundingRect.height=r,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){let e=[];return this.showChartTitle&&e.push({groupTexts:[`chart-title`],type:`text`,data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:`middle`,horizontalPos:`center`,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),e}};function P(e,t,n,r){return new te(new O(r),e,t,n)}t(P,`getChartTitleComponent`);var ne=.75,re=.5,ie=.35;function F(e){return{fontSize:e,markerSize:e*ne,markerSpacing:e*ie,itemSpacing:e*re}}t(F,`getLegendLayout`);var ae=class{constructor(e,t,n,r){this.textDimensionCalculator=e,this.chartConfig=t,this.chartData=n,this.chartThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.visiblePlots=[]}static{t(this,`ChartLegend`)}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){if(this.visiblePlots=this.chartConfig.showLegend?this.chartData.plots.filter(e=>e.title):[],this.visiblePlots.length===0)return this.boundingRect.width=0,this.boundingRect.height=0,{width:0,height:0};let{fontSize:t,markerSize:n,markerSpacing:r,itemSpacing:i}=F(this.chartConfig.legendFontSize),a=this.textDimensionCalculator.getMaxDimension(this.visiblePlots.map(e=>e.title),t),o=this.chartConfig.legendPadding*2+n+r+a.width,s=this.chartConfig.legendPadding*2+this.visiblePlots.length*t+(this.visiblePlots.length-1)*i;return o<=e.width&&s<=e.height?(this.boundingRect.width=o,this.boundingRect.height=s):(this.visiblePlots=[],this.boundingRect.width=0,this.boundingRect.height=0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(this.visiblePlots.length===0)return[];let{fontSize:e,markerSize:t,markerSpacing:n,itemSpacing:r}=F(this.chartConfig.legendFontSize),i=e+r,a=this.boundingRect.x+this.chartConfig.legendPadding,o=this.boundingRect.y+this.chartConfig.legendPadding,s=[],c=[];for(let[e,n]of this.visiblePlots.entries())if(T(n))s.push({x:a,y:o+e*i,width:t,height:t,fill:n.fill,strokeFill:n.fill,strokeWidth:0});else{let r=o+e*i+t/2;c.push({path:`M ${a},${r} L ${a+t},${r}`,strokeFill:n.strokeFill,strokeWidth:n.strokeWidth})}return[{groupTexts:[`legend`,`markers`],type:`rect`,data:s},{groupTexts:[`legend`,`markers`],type:`path`,data:c},{groupTexts:[`legend`,`label`],type:`text`,data:this.visiblePlots.map((r,s)=>({text:r.title,x:a+t+n,y:o+s*i+t/2,fill:this.chartThemeConfig.legendTextColor,fontSize:e,rotation:0,verticalPos:`middle`,horizontalPos:`left`}))}]}};function I(e,t,n,r){return new ae(new O(r),e,t,n)}t(I,`getChartLegendComponent`);var oe=class{constructor(e,t,n,r,i){this.plotData=e,this.xAxis=t,this.yAxis=n,this.orientation=r,this.plotIndex=i}static{t(this,`LinePlot`)}getDrawableElement(){let e=this.plotData.data.map(e=>[this.xAxis.getScaleValue(e[0]),this.yAxis.getScaleValue(e[1])]),t;if(t=this.orientation===`horizontal`?v().y(e=>e[0]).x(e=>e[1])(e):v().x(e=>e[0]).y(e=>e[1])(e),!t)return[];let n=[{groupTexts:[`plot`,`line-plot-${this.plotIndex}`],type:`path`,data:[{path:t,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}];if(this.plotData.pointLabels&&this.plotData.pointLabels.length>0){let t=[];for(let[n,[r,i]]of e.entries()){let e=this.plotData.pointLabels[n];e&&(this.orientation===`horizontal`?t.push({x:i+10,y:r,text:e,fill:this.plotData.strokeFill,verticalPos:`middle`,horizontalPos:`left`,fontSize:12,rotation:0}):t.push({x:r,y:i-10,text:e,fill:this.plotData.strokeFill,verticalPos:`middle`,horizontalPos:`center`,fontSize:12,rotation:0}))}t.length>0&&n.push({groupTexts:[`plot`,`line-plot-${this.plotIndex}`,`labels`],type:`text`,data:t})}return n}},se=class{constructor(e,t,n,r,i,a){this.barData=e,this.boundingRect=t,this.xAxis=n,this.yAxis=r,this.orientation=i,this.plotIndex=a}static{t(this,`BarPlot`)}getDrawableElement(){let e=this.barData.data.map(e=>[this.xAxis.getScaleValue(e[0]),this.yAxis.getScaleValue(e[1])]),t=Math.min(this.xAxis.getAxisOuterPadding()*2,this.xAxis.getTickDistance())*.95,n=t/2;return this.orientation===`horizontal`?[{groupTexts:[`plot`,`bar-plot-${this.plotIndex}`],type:`rect`,data:e.map(e=>({x:this.boundingRect.x,y:e[0]-n,height:t,width:e[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:[`plot`,`bar-plot-${this.plotIndex}`],type:`rect`,data:e.map(e=>({x:e[0]-n,y:e[1],width:t,height:this.boundingRect.y+this.boundingRect.height-e[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},ce=class{constructor(e,t,n){this.chartConfig=e,this.chartData=t,this.chartThemeConfig=n,this.boundingRect={x:0,y:0,width:0,height:0}}static{t(this,`BasePlot`)}setAxes(e,t){this.xAxis=e,this.yAxis=t}setBoundingBoxXY(e){this.boundingRect.x=e.x,this.boundingRect.y=e.y}calculateSpace(e){return this.boundingRect.width=e.width,this.boundingRect.height=e.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error(`Axes must be passed to render Plots`);let e=[];for(let[t,n]of this.chartData.plots.entries())switch(n.type){case`line`:{let r=new oe(n,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,t);e.push(...r.getDrawableElement())}break;case`bar`:{let r=new se(n,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,t);e.push(...r.getDrawableElement())}}return e}};function le(e,t,n){return new ce(e,t,n)}t(le,`getPlotComponent`);var ue=class{constructor(e,t,n,r){this.chartConfig=e,this.chartData=t,this.componentStore={title:P(e,t,n,r),plot:le(e,t,n),legend:I(e,t,n,r),xAxis:N(t.xAxis,e.xAxis,{titleColor:n.xAxisTitleColor,labelColor:n.xAxisLabelColor,tickColor:n.xAxisTickColor,axisLineColor:n.xAxisLineColor},r),yAxis:N(t.yAxis,e.yAxis,{titleColor:n.yAxisTitleColor,labelColor:n.yAxisLabelColor,tickColor:n.yAxisTickColor,axisLineColor:n.yAxisLineColor},r)}}static{t(this,`Orchestrator`)}calculateVerticalSpace(){let e=this.chartConfig.width,t=this.chartConfig.height,n=0,r=0,i={width:0,height:0},a=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),o=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),s=this.componentStore.plot.calculateSpace({width:a,height:o});e-=s.width,t-=s.height,s=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:t}),r=s.height,t-=s.height,this.componentStore.xAxis.setAxisPosition(`bottom`),s=this.componentStore.xAxis.calculateSpace({width:e,height:t}),t-=s.height,this.componentStore.yAxis.setAxisPosition(`left`),s=this.componentStore.yAxis.calculateSpace({width:e,height:t}),n=s.width,e-=s.width,i=this.componentStore.legend.calculateSpace({width:e,height:o}),e-=i.width,e>0&&(a+=e,e=0),t>0&&(o+=t,t=0),this.componentStore.plot.calculateSpace({width:a,height:o}),this.componentStore.plot.setBoundingBoxXY({x:n,y:r}),this.componentStore.legend.setBoundingBoxXY({x:n+a,y:r+Math.max((o-i.height)/2,0)}),this.componentStore.xAxis.setRange([n,n+a]),this.componentStore.xAxis.setBoundingBoxXY({x:n,y:r+o}),this.componentStore.yAxis.setRange([r,r+o]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:r}),this.chartData.plots.some(e=>T(e))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let e=this.chartConfig.width,t=this.chartConfig.height,n=0,r=0,i=0,a={width:0,height:0},o=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),s=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),c=this.componentStore.plot.calculateSpace({width:o,height:s});e-=c.width,t-=c.height,c=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:t}),n=c.height,t-=c.height,this.componentStore.xAxis.setAxisPosition(`left`),c=this.componentStore.xAxis.calculateSpace({width:e,height:t}),e-=c.width,r=c.width,this.componentStore.yAxis.setAxisPosition(`top`),c=this.componentStore.yAxis.calculateSpace({width:e,height:t}),t-=c.height,i=n+c.height,a=this.componentStore.legend.calculateSpace({width:e,height:s}),e-=a.width,e>0&&(o+=e,e=0),t>0&&(s+=t,t=0),this.componentStore.plot.calculateSpace({width:o,height:s}),this.componentStore.plot.setBoundingBoxXY({x:r,y:i}),this.componentStore.legend.setBoundingBoxXY({x:r+o,y:i+Math.max((s-a.height)/2,0)}),this.componentStore.yAxis.setRange([r,r+o]),this.componentStore.yAxis.setBoundingBoxXY({x:r,y:n}),this.componentStore.xAxis.setRange([i,i+s]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:i}),this.chartData.plots.some(e=>T(e))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){this.chartConfig.chartOrientation===`horizontal`?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();let e=[];this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis);for(let t of Object.values(this.componentStore))e.push(...t.getDrawableElements());return e}},de=class{static{t(this,`XYChartBuilder`)}static build(e,t,n,r){return new ue(e,t,n,r).getDrawableElement()}},L=0,R,z=K(),B=G(),V=q(),H=B.plotColorPalette.split(`,`).map(e=>e.trim()),U=!1,W=!1;function G(){let e=n(),t=o();return _(e.xyChart,t.themeVariables.xyChart)}t(G,`getChartDefaultThemeConfig`);function K(){let e=o();return _(c.xyChart,e.xyChart)}t(K,`getChartDefaultConfig`);function q(){return{yAxis:{type:`linear`,title:``,min:1/0,max:-1/0},xAxis:{type:`band`,title:``,categories:[]},title:``,plots:[]}}t(q,`getChartDefaultData`);function J(e){let t=o();return p(e.trim(),t)}t(J,`textSanitizer`);function Y(e){R=e}t(Y,`setTmpSVGG`);function fe(e){e===`horizontal`?z.chartOrientation=`horizontal`:z.chartOrientation=`vertical`}t(fe,`setOrientation`);function pe(e){V.xAxis.title=J(e.text)}t(pe,`setXAxisTitle`);function X(e,t){V.xAxis={type:`linear`,title:V.xAxis.title,min:e,max:t},U=!0}t(X,`setXAxisRangeData`);function me(e){V.xAxis={type:`band`,title:V.xAxis.title,categories:e.map(e=>J(e.text))},U=!0}t(me,`setXAxisBand`);function he(e){V.yAxis.title=J(e.text)}t(he,`setYAxisTitle`);function Z(e,t){V.yAxis={type:`linear`,title:V.yAxis.title,min:e,max:t},W=!0}t(Z,`setYAxisRangeData`);function ge(e){let t=Math.min(...e),n=Math.max(...e),r=D(V.yAxis)?V.yAxis.min:1/0,i=D(V.yAxis)?V.yAxis.max:-1/0;V.yAxis={type:`linear`,title:V.yAxis.title,min:Math.min(r,t),max:Math.max(i,n)}}t(ge,`setYAxisRangeFromPlotData`);function Q(e){let t=[];if(e.length===0)return t;if(!U){let t=D(V.xAxis)?V.xAxis.min:1/0,n=D(V.xAxis)?V.xAxis.max:-1/0;X(Math.min(t,1),Math.max(n,e.length))}if(E(V.xAxis)&&e.length>V.xAxis.categories.length&&(e=e.slice(0,V.xAxis.categories.length)),W||ge(e),E(V.xAxis)&&(t=V.xAxis.categories.map((t,n)=>[t,e[n]])),D(V.xAxis)){let n=V.xAxis.min,r=V.xAxis.max;if(e.length===1)t=[[`${n}`,e[0]]];else{let i=(r-n)/(e.length-1);t=e.map((e,t)=>[`${n+t*i}`,e])}}return t}t(Q,`transformDataWithoutCategory`);function $(e){return H[e===0?0:e%H.length]}t($,`getPlotColorFromPalette`);function _e(e,t){let n=t.map(e=>e.value),r=t.map(e=>e.label?J(e.label):``),i=Q(n),a=r.some(e=>e!==``);V.plots.push({type:`line`,title:J(e.text),strokeFill:$(L),strokeWidth:2,data:i,...a?{pointLabels:r}:{}}),L++}t(_e,`setLineData`);function ve(e,t){let n=Q(t.map(e=>e.value));V.plots.push({type:`bar`,title:J(e.text),fill:$(L),data:n}),L++}t(ve,`setBarData`);function ye(){if(V.plots.length===0)throw Error(`No Plot to render, please provide a plot with some data`);return V.title=d(),de.build(z,V,B,R)}t(ye,`getDrawableElem`);function be(){return B}t(be,`getChartThemeConfig`);function xe(){return z}t(xe,`getChartConfig`);function Se(){return V}t(Se,`getXYChartData`);var Ce={parser:w,db:{getDrawableElem:ye,clear:t(function(){a(),L=0,z=K(),V=q(),B=G(),H=B.plotColorPalette.split(`,`).map(e=>e.trim()),U=!1,W=!1},`clear`),setAccTitle:i,getAccTitle:f,setDiagramTitle:l,getDiagramTitle:d,getAccDescription:u,setAccDescription:r,setOrientation:fe,setXAxisTitle:pe,setXAxisRangeData:X,setXAxisBand:me,setYAxisTitle:he,setYAxisRangeData:Z,setLineData:_e,setBarData:ve,setTmpSVGG:Y,getChartThemeConfig:be,getChartConfig:xe,getXYChartData:Se},renderer:{draw:t((n,r,i,a)=>{let o=a.db,c=o.getChartThemeConfig(),l=o.getChartConfig(),u=o.getXYChartData().plots[0].data.map(e=>e[1]);function d(e){return e===`top`?`text-before-edge`:`middle`}t(d,`getDominantBaseLine`);function f(e){return e===`left`?`start`:e===`right`?`end`:`middle`}t(f,`getTextAnchor`);function p(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}t(p,`getTextTransformation`),e.debug(`Rendering xychart chart +`+n);let m=b(r),h=m.append(`g`).attr(`class`,`main`),g=h.append(`rect`).attr(`width`,l.width).attr(`height`,l.height).attr(`class`,`background`);s(m,l.height,l.width,!0),m.attr(`viewBox`,`0 0 ${l.width} ${l.height}`),g.attr(`fill`,c.backgroundColor),o.setTmpSVGG(m.append(`g`).attr(`class`,`mermaid-tmp-group`));let _=o.getDrawableElem(),v={};function y(e){let t=h,n=``;for(let[r]of e.entries()){let i=h;r>0&&v[n]&&(i=v[n]),n+=e[r],t=v[n],t||=v[n]=i.append(`g`).attr(`class`,e[r])}return t}t(y,`getGroup`);for(let e of _){if(e.data.length===0)continue;let n=y(e.groupTexts);switch(e.type){case`rect`:if(n.selectAll(`rect`).data(e.data).enter().append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeFill).attr(`stroke-width`,e=>e.strokeWidth),l.showDataLabel){let r=l.showDataLabelOutsideBar;if(l.chartOrientation===`horizontal`){let i=function(e,t){let{data:n,label:r}=e;return t*r.length*a<=n.width-o};t(i,`fitsHorizontally`);let a=.7,o=10,s=e.data.map((e,t)=>({data:e,label:u[t].toString()})).filter(e=>e.data.width>0&&e.data.height>0),l=s.map(e=>{let{data:t}=e,n=t.height*.7;for(;!i(e,n)&&n>0;)--n;return n}),d=Math.floor(Math.min(...l)),f=t(e=>r?e.data.x+e.data.width+10:e.data.x+e.data.width-10,`determineLabelXPosition`);n.selectAll(`text`).data(s).enter().append(`text`).attr(`x`,f).attr(`y`,e=>e.data.y+e.data.height/2).attr(`text-anchor`,r?`start`:`end`).attr(`dominant-baseline`,`middle`).attr(`fill`,c.dataLabelColor).attr(`font-size`,`${d}px`).text(e=>e.label)}else{let i=function(e,t,n){let{data:r,label:i}=e,a=t*i.length*.7,o=r.x+r.width/2,s=o-a/2,c=o+a/2,l=s>=r.x&&c<=r.x+r.width,u=r.y+n+t<=r.y+r.height;return l&&u};t(i,`fitsInBar`);let a=e.data.map((e,t)=>({data:e,label:u[t].toString()})).filter(e=>e.data.width>0&&e.data.height>0),o=a.map(e=>{let{data:t,label:n}=e,r=t.width/(n.length*.7);for(;!i(e,r,10)&&r>0;)--r;return r}),s=Math.floor(Math.min(...o)),l=t(e=>r?e.data.y-10:e.data.y+10,`determineLabelYPosition`);n.selectAll(`text`).data(a).enter().append(`text`).attr(`x`,e=>e.data.x+e.data.width/2).attr(`y`,l).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,r?`auto`:`hanging`).attr(`fill`,c.dataLabelColor).attr(`font-size`,`${s}px`).text(e=>e.label)}}break;case`text`:n.selectAll(`text`).data(e.data).enter().append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>d(e.verticalPos)).attr(`text-anchor`,e=>f(e.horizontalPos)).attr(`transform`,e=>p(e)).text(e=>e.text);break;case`path`:n.selectAll(`path`).data(e.data).enter().append(`path`).attr(`d`,e=>e.path).attr(`fill`,e=>e.fill?e.fill:`none`).attr(`stroke`,e=>e.strokeFill).attr(`stroke-width`,e=>e.strokeWidth)}}},`draw`)}};export{Ce as diagram}; \ No newline at end of file diff --git a/www/index.html b/www/index.html index c79527a..fa04683 100644 --- a/www/index.html +++ b/www/index.html @@ -4,13 +4,36 @@ - Notes & Code RAG MCP Admin + ContextCortex - - + + + + + + + + + + + + + + + + + +